:root {
  color-scheme: dark;
  --realm-bg: oklch(0.105 0.025 254);
  --realm-surface: oklch(0.16 0.032 254);
  --realm-surface-raised: oklch(0.205 0.042 252);
  --realm-ink: oklch(0.955 0.018 85);
  --realm-muted: oklch(0.77 0.032 246);
  --realm-line: oklch(0.34 0.052 248);
  --realm-primary: oklch(0.75 0.13 74);
  --realm-primary-strong: oklch(0.67 0.15 65);
  --realm-accent: oklch(0.76 0.115 229);
  --realm-success: oklch(0.72 0.15 151);
  --realm-warning: oklch(0.79 0.14 79);
  --realm-danger: oklch(0.68 0.18 27);
  --realm-radius: 14px;
  --realm-control-radius: 10px;
  --realm-max: 1280px;
  --z-sticky: 20;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  background:
    radial-gradient(circle at 76% -12%, oklch(0.34 0.1 244 / 0.34), transparent 40rem),
    var(--realm-bg);
  color: var(--realm-ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 1rem;
  line-height: 1.55;
  text-rendering: optimizeLegibility;
}

a {
  color: inherit;
}

button,
input {
  font: inherit;
}

button,
a,
input {
  -webkit-tap-highlight-color: transparent;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  color: var(--realm-ink);
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.08;
  text-wrap: balance;
}

h1 {
  max-width: 12ch;
  margin-bottom: 0.7rem;
  color: var(--realm-primary);
  font-size: clamp(3.8rem, 8vw, 5.7rem);
  text-shadow: 0 2px 0 oklch(0.08 0.01 250), 0 0 26px oklch(0.45 0.1 70 / 0.24);
}

h2 {
  margin-bottom: 0.75rem;
  font-size: clamp(2rem, 4vw, 3.1rem);
}

h3 {
  margin-bottom: 0;
  font-size: 1.3rem;
}

p {
  max-width: 70ch;
  color: var(--realm-muted);
  text-wrap: pretty;
}

.skip-link {
  position: fixed;
  z-index: calc(var(--z-sticky) + 1);
  top: 12px;
  left: 12px;
  padding: 10px 14px;
  border-radius: var(--realm-control-radius);
  background: var(--realm-primary);
  color: var(--realm-ink);
  font-weight: 800;
  transform: translateY(-150%);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: sticky;
  z-index: var(--z-sticky);
  top: 0;
  border-bottom: 1px solid oklch(0.34 0.035 248 / 0.72);
  background: oklch(0.105 0.025 254 / 0.96);
  backdrop-filter: blur(10px);
}

.site-header-inner,
.page-shell,
.site-footer {
  width: min(calc(100% - 32px), var(--realm-max));
  margin-inline: auto;
}

.site-header-inner {
  min-height: 66px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.brand-mark {
  width: 38px;
  height: 40px;
  display: grid;
  place-items: center;
  border: 1px solid var(--realm-primary);
  border-radius: 10px 10px 14px 14px;
  background: oklch(0.14 0.03 252);
  color: var(--realm-primary);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.35rem;
  font-weight: 800;
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.12rem;
}

.brand small {
  color: var(--realm-muted);
  font-size: 0.77rem;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 6px;
}

.site-nav a {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  padding-inline: 12px;
  border-radius: 9px;
  color: var(--realm-muted);
  font-size: 0.92rem;
  font-weight: 700;
  text-decoration: none;
}

.site-nav a:hover {
  background: var(--realm-surface);
  color: var(--realm-ink);
}

.site-nav .nav-cta {
  border: 1px solid var(--realm-primary);
  background: var(--realm-primary);
  color: oklch(0.13 0.025 254);
}

.page-shell {
  padding-block: 24px 64px;
}

.realm-hero {
  position: relative;
  min-height: 500px;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(390px, 0.85fr);
  align-items: center;
  gap: clamp(30px, 6vw, 78px);
  overflow: hidden;
  padding: clamp(32px, 5vw, 64px);
  border: 1px solid var(--realm-line);
  border-radius: 16px;
  background:
    linear-gradient(90deg, oklch(0.105 0.03 254 / 0.99) 0%, oklch(0.11 0.033 254 / 0.94) 42%, oklch(0.1 0.03 254 / 0.58) 67%, oklch(0.1 0.03 254 / 0.88) 100%),
    url("/assets/maps/northrend.jpg") 80% 48% / 66% auto no-repeat,
    var(--realm-surface);
}

.realm-hero::after {
  position: absolute;
  inset: 0;
  border: 1px solid oklch(0.75 0.13 74 / 0.18);
  border-radius: inherit;
  content: "";
  pointer-events: none;
}

.realm-copy,
.realm-ledger {
  position: relative;
  z-index: 1;
}

.realm-state-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  color: var(--realm-muted);
  font-size: 0.92rem;
  font-weight: 700;
}

.realm-beacon {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--realm-warning);
}

.realm-beacon.is-online {
  background: var(--realm-success);
  box-shadow: 0 0 0 5px oklch(0.72 0.15 151 / 0.12);
}

.realm-beacon.is-offline {
  background: var(--realm-danger);
}

.realm-copy > p {
  max-width: 59ch;
  margin-bottom: 30px;
  font-size: 1.04rem;
}

.hero-lede strong {
  display: block;
  margin-bottom: 6px;
  color: var(--realm-ink);
  font-size: 1.3rem;
  line-height: 1.3;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.button {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-inline: 18px;
  border: 1px solid transparent;
  border-radius: var(--realm-control-radius);
  cursor: pointer;
  font-weight: 800;
  text-decoration: none;
  transition: background-color 180ms ease-out, border-color 180ms ease-out, color 180ms ease-out, transform 180ms ease-out;
}

.button:hover {
  transform: translateY(-1px);
}

.button-primary {
  background: var(--realm-primary);
  color: oklch(0.14 0.03 254);
}

.button-primary:hover {
  background: var(--realm-primary-strong);
}

.button-secondary {
  border-color: var(--realm-line);
  background: transparent;
  color: var(--realm-ink);
}

.button-secondary:hover {
  border-color: var(--realm-accent);
  background: var(--realm-surface);
}

.realm-ledger {
  overflow: hidden;
  border: 1px solid var(--realm-line);
  border-radius: var(--realm-radius);
  background: oklch(0.135 0.03 254 / 0.96);
}

.connect-command {
  width: max-content;
  max-width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 22px;
  padding: 9px 12px;
  border: 1px solid oklch(0.76 0.115 229 / 0.32);
  border-radius: 9px;
  background: oklch(0.09 0.022 254 / 0.78);
  color: var(--realm-muted);
  font-size: 0.78rem;
}

.connect-command span {
  white-space: nowrap;
}

.connect-command code {
  overflow: hidden;
  color: var(--realm-accent);
  font-size: 0.84rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ledger-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 22px;
  border-bottom: 1px solid var(--realm-line);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.3rem;
  font-weight: 700;
}

.status-badge,
.privacy-note {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding-inline: 10px;
  border-radius: 999px;
  font-family: Inter, ui-sans-serif, system-ui, sans-serif;
  font-size: 0.78rem;
  font-weight: 800;
}

.status-online {
  background: oklch(0.72 0.15 151 / 0.16);
  color: var(--realm-success);
}

.status-offline {
  background: oklch(0.68 0.18 27 / 0.16);
  color: var(--realm-danger);
}

.status-unknown {
  background: oklch(0.73 0.115 232 / 0.12);
  color: var(--realm-accent);
}

.ledger-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 0;
}

.ledger-metrics div {
  min-height: 94px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 20px 22px;
  border-bottom: 1px solid var(--realm-line);
}

.ledger-metrics div:nth-child(odd) {
  border-right: 1px solid var(--realm-line);
}

dt {
  color: var(--realm-muted);
  font-size: 0.82rem;
  font-weight: 700;
}

dd {
  margin: 0;
  font-variant-numeric: tabular-nums;
}

.ledger-metrics dd {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.65rem;
  font-weight: 700;
}

.rate-line {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
  padding: 17px 22px;
  color: var(--realm-muted);
  font-size: 0.85rem;
}

.rate-line strong {
  color: var(--realm-primary);
}

.assistive-status {
  min-height: 1px;
  margin: 0;
  padding: 0 22px 18px;
  font-size: 0.82rem;
}

.world-section,
.player-section,
.account-section {
  scroll-margin-top: 92px;
}

.world-section {
  padding-block: 58px 66px;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 20px;
}

.section-heading p {
  margin-bottom: 0;
}

.privacy-note {
  flex: 0 0 auto;
  border: 1px solid var(--realm-line);
  color: var(--realm-muted);
}

.section-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.live-toggle {
  min-height: 30px;
  padding-inline: 10px;
  border: 1px solid var(--realm-line);
  border-radius: 999px;
  background: transparent;
  color: var(--realm-muted);
  cursor: pointer;
  font-size: 0.78rem;
  font-weight: 800;
}

.live-toggle:hover,
.live-toggle[aria-pressed="true"] {
  border-color: var(--realm-accent);
  color: var(--realm-ink);
}

.world-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 16px;
}

.world-map-shell {
  overflow: hidden;
  border: 1px solid var(--realm-line);
  border-radius: var(--realm-radius);
  background: oklch(0.135 0.03 254);
}

.map-toolbar {
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--realm-line);
}

.map-tabs {
  min-width: 0;
  display: flex;
  gap: 4px;
  overflow-x: auto;
}

.map-tabs button,
.map-zoom button {
  min-height: 42px;
  border: 1px solid transparent;
  border-radius: 9px;
  background: transparent;
  color: var(--realm-muted);
  cursor: pointer;
  font-size: 0.82rem;
  font-weight: 800;
}

.map-tabs button {
  flex: 0 0 auto;
  padding-inline: 12px;
}

.map-tabs button:hover,
.map-tabs button[aria-selected="true"] {
  background: var(--realm-surface-raised);
  color: var(--realm-ink);
}

.map-tabs button[aria-selected="true"] {
  border-color: oklch(0.67 0.14 46 / 0.72);
  color: var(--realm-primary);
}

.map-tabs button:focus-visible,
.map-zoom button:focus-visible,
.map-node:focus-visible {
  outline: 3px solid var(--realm-accent);
  outline-offset: 2px;
}

.map-zoom {
  flex: 0 0 auto;
  display: grid;
  grid-template-columns: 42px minmax(86px, auto) 42px;
  align-items: center;
  border: 1px solid var(--realm-line);
  border-radius: 10px;
}

.map-zoom button {
  width: 42px;
  padding: 0;
  color: var(--realm-ink);
  font-size: 1.25rem;
}

.map-zoom button:disabled {
  cursor: not-allowed;
  opacity: 0.35;
}

.map-zoom output {
  padding-inline: 8px;
  color: var(--realm-muted);
  font-size: 0.75rem;
  font-weight: 800;
  text-align: center;
}

.map-canvas {
  position: relative;
  min-height: 0;
  aspect-ratio: 966 / 732;
  overflow: hidden;
  background-color: oklch(0.105 0.025 247);
  background-image: radial-gradient(ellipse at 52% 46%, oklch(0.34 0.07 235 / 0.4), transparent 60%);
  isolation: isolate;
}

.map-canvas.map-outland {
  aspect-ratio: 966 / 695;
}

.map-canvas.map-kalimdor {
  background-color: oklch(0.115 0.032 150);
}

.map-canvas.map-outland {
  background-color: oklch(0.115 0.035 305);
}

.map-canvas.map-northrend {
  background-color: oklch(0.12 0.033 235);
}

.map-artboard {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 97%;
  aspect-ratio: 966 / 732;
  transform: translate(-50%, -50%);
}

.map-outland .map-artboard {
  aspect-ratio: 966 / 695;
}

.map-coast {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border: 1px solid oklch(0.73 0.115 232 / 0.18);
  border-radius: 12px;
  background-position: center;
  background-repeat: no-repeat;
  background-size: 100% 100%;
  box-shadow: inset 0 0 8px oklch(0.73 0.115 232 / 0.11);
  filter: saturate(0.96) contrast(1.05) brightness(0.82);
  opacity: 0.94;
  pointer-events: none;
}

.map-coast::after {
  position: absolute;
  inset: 0;
  content: "";
}

.map-kingdoms .map-coast {
  background-image: url("/assets/maps/azeroth.jpg");
}

.map-kingdoms .map-coast::after {
  background: linear-gradient(90deg, oklch(0.05 0 0 / 0.62) 0 50%, transparent 50% 100%);
}

.map-kalimdor .map-coast {
  background-image: url("/assets/maps/azeroth.jpg");
}

.map-kalimdor .map-coast::after {
  background: linear-gradient(90deg, transparent 0 50%, oklch(0.05 0 0 / 0.62) 50% 100%);
}

.map-outland .map-coast {
  background-image: url("/assets/maps/outland.jpg");
}

.map-northrend .map-coast {
  background-image: url("/assets/maps/northrend.jpg");
}

.map-plot {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.map-region {
  fill: oklch(0.65 0.09 232 / 0.025);
  stroke: oklch(0.73 0.115 232 / 0.17);
  stroke-width: 0.18;
  vector-effect: non-scaling-stroke;
}

.map-region-group.population-1 .map-region { fill: oklch(0.65 0.09 232 / 0.08); }
.map-region-group.population-2 .map-region { fill: oklch(0.65 0.09 232 / 0.13); }
.map-region-group.population-3 .map-region { fill: oklch(0.65 0.09 232 / 0.19); }
.map-region-group.population-4 .map-region { fill: oklch(0.65 0.09 232 / 0.26); }

.map-region-label {
  color: oklch(0.91 0.025 235);
  fill: currentColor;
  font-family: Inter, ui-sans-serif, system-ui, sans-serif;
  font-size: 1.45px;
  font-weight: 800;
  opacity: 0;
  pointer-events: none;
  paint-order: stroke;
  stroke: oklch(0.08 0.018 247 / 0.9);
  stroke-width: 0.35px;
  stroke-linejoin: round;
}

.map-canvas[data-zoom="2"] .map-region-group.has-population .map-region-label,
.map-canvas[data-zoom="3"] .map-region-group.has-population .map-region-label {
  opacity: 0.78;
}

.map-node {
  cursor: pointer;
}

.map-node-ring {
  stroke: oklch(0.9 0.02 245 / 0.7);
  stroke-width: 0.28;
  vector-effect: non-scaling-stroke;
  transition: r 160ms ease-out, stroke 160ms ease-out;
}

.map-cluster:hover .map-node-ring,
.map-cluster:focus-visible .map-node-ring {
  r: 4;
  stroke: var(--realm-primary);
}

.map-cluster.is-alliance .map-node-ring {
  fill: oklch(0.56 0.15 250 / 0.92);
}

.map-cluster.is-horde .map-node-ring {
  fill: oklch(0.51 0.16 27 / 0.92);
}

.map-cluster.is-mixed .map-node-ring {
  fill: oklch(0.53 0.08 297 / 0.94);
}

.map-cluster-count {
  fill: oklch(0.98 0 0);
  font-family: Inter, ui-sans-serif, system-ui, sans-serif;
  font-size: 2.15px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
  pointer-events: none;
}

.map-bot-hit {
  fill: transparent;
}

.map-bot-dot {
  stroke: oklch(0.96 0 0);
  stroke-width: 0.32;
  vector-effect: non-scaling-stroke;
  transition: r 160ms ease-out, stroke 160ms ease-out;
}

.map-bot:hover .map-bot-dot,
.map-bot:focus-visible .map-bot-dot {
  r: 1.65;
  stroke: var(--realm-primary);
}

.map-bot.is-alliance .map-bot-dot,
.legend-alliance {
  fill: oklch(0.59 0.17 250);
  background: oklch(0.59 0.17 250);
}

.map-bot.is-horde .map-bot-dot,
.legend-horde {
  fill: oklch(0.55 0.18 27);
  background: oklch(0.55 0.18 27);
}

.map-node:focus-visible {
  outline: none;
}

.map-state {
  position: absolute;
  z-index: 4;
  top: 50%;
  left: 50%;
  width: min(360px, calc(100% - 48px));
  display: grid;
  gap: 5px;
  padding: 18px;
  border-radius: 10px;
  background: oklch(0.09 0 0 / 0.9);
  text-align: center;
  transform: translate(-50%, -50%);
}

.map-state[hidden] {
  display: none;
}

.map-state span {
  color: var(--realm-muted);
  font-size: 0.82rem;
}

.map-compass {
  position: absolute;
  right: 18px;
  bottom: 18px;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid oklch(0.73 0.115 232 / 0.38);
  border-radius: 50%;
  background: oklch(0.09 0 0 / 0.78);
  color: var(--realm-primary);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 0.75rem;
  font-weight: 800;
}

.map-footer {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 12px 16px;
  border-top: 1px solid var(--realm-line);
}

.map-legend {
  flex: 0 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  color: var(--realm-muted);
  font-size: 0.72rem;
  font-weight: 700;
}

.map-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.map-legend i {
  width: 9px;
  height: 9px;
  display: inline-block;
  border-radius: 50%;
}

.legend-cluster {
  border: 1px solid oklch(0.9 0.02 245 / 0.75);
  background: oklch(0.53 0.08 297);
}

.map-inspector {
  margin: 0;
  font-size: 0.77rem;
  text-align: right;
}

.map-inspector strong {
  color: var(--realm-ink);
}

.zone-ledger {
  border: 1px solid var(--realm-line);
  border-radius: var(--realm-radius);
  background: oklch(0.135 0.03 254);
}

.zone-ledger-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 17px 18px;
  border-bottom: 1px solid var(--realm-line);
}

.zone-ledger-heading span {
  color: var(--realm-muted);
  font-size: 0.78rem;
}

.zone-list {
  display: grid;
  padding: 5px 18px 12px;
}

.zone-row {
  padding-block: 11px;
  border-bottom: 1px solid oklch(0.34 0.035 248 / 0.56);
}

.zone-row:last-child {
  border-bottom: 0;
}

.zone-row-heading,
.zone-population {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.zone-row-heading {
  margin-bottom: 10px;
}

.zone-row-heading span,
.zone-population span {
  color: var(--realm-muted);
  font-size: 0.8rem;
}

.zone-progress {
  width: 100%;
  height: 7px;
  display: block;
  overflow: hidden;
  border: 0;
  border-radius: 999px;
  background: var(--realm-surface-raised);
  appearance: none;
}

.zone-progress::-webkit-progress-bar {
  background: var(--realm-surface-raised);
}

.zone-progress::-webkit-progress-value {
  border-radius: 999px;
  background: var(--realm-accent);
}

.zone-progress::-moz-progress-bar {
  border-radius: 999px;
  background: var(--realm-accent);
}

.zone-skeleton {
  min-height: 72px;
  margin-top: 10px;
  border-radius: 10px;
  background: linear-gradient(90deg, var(--realm-surface-raised), oklch(0.27 0.03 248), var(--realm-surface-raised));
  background-size: 200% 100%;
  animation: loading-sheen 1.5s ease-in-out infinite;
}

@keyframes loading-sheen {
  to {
    background-position: -200% 0;
  }
}

.state-message {
  padding: 18px 0;
  color: var(--realm-muted);
}

.state-message strong {
  display: block;
  margin-bottom: 5px;
  color: var(--realm-ink);
}

.player-section {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(360px, 1.1fr);
  gap: clamp(28px, 5vw, 64px);
  align-items: center;
  padding-block: 64px;
  border-top: 1px solid var(--realm-line);
}

.player-search-copy > p {
  margin-bottom: 28px;
}

.search-form,
.account-form,
.account-form label {
  display: grid;
  gap: 9px;
}

.search-form > label,
.account-form label span {
  color: var(--realm-ink);
  font-size: 0.88rem;
  font-weight: 800;
}

.search-control {
  display: flex;
  gap: 10px;
}

input {
  width: 100%;
  min-height: 48px;
  padding-inline: 14px;
  border: 1px solid var(--realm-line);
  border-radius: var(--realm-control-radius);
  outline: 0;
  background: oklch(0.115 0.012 255);
  color: var(--realm-ink);
}

input::placeholder {
  color: oklch(0.67 0.022 246);
}

input:hover {
  border-color: oklch(0.48 0.05 244);
}

input:focus-visible,
.button:focus-visible,
.live-toggle:focus-visible,
.site-nav a:focus-visible,
.brand:focus-visible {
  outline: 3px solid var(--realm-accent);
  outline-offset: 3px;
}

.character-result {
  min-height: 260px;
  display: grid;
  align-content: center;
  padding: 30px;
  border: 1px solid var(--realm-line);
  border-radius: var(--realm-radius);
  background: var(--realm-surface);
}

.empty-emblem {
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  margin-bottom: 18px;
  border: 1px solid var(--realm-line);
  border-radius: 50%;
  color: var(--realm-primary);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.6rem;
}

.character-result p {
  margin-bottom: 0;
}

.character-heading {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}

.character-heading p {
  margin: 6px 0 0;
}

.character-level {
  flex: 0 0 auto;
  color: var(--realm-primary);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.4rem;
  font-weight: 700;
}

.character-details {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 0;
  border-top: 1px solid var(--realm-line);
}

.character-details div {
  padding: 15px 0;
  border-bottom: 1px solid var(--realm-line);
}

.character-details div:nth-child(odd) {
  padding-right: 18px;
}

.character-details div:nth-child(even) {
  padding-left: 18px;
  border-left: 1px solid var(--realm-line);
}

.character-details dd {
  margin-top: 4px;
  font-weight: 700;
}

.account-section {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(430px, 1.2fr);
  gap: clamp(32px, 6vw, 72px);
  padding: clamp(28px, 5vw, 52px);
  border: 1px solid oklch(0.67 0.14 46 / 0.58);
  border-radius: var(--realm-radius);
  background:
    linear-gradient(115deg, oklch(0.15 0.04 58) 0 42%, oklch(0.13 0.03 254) 76%),
    var(--realm-surface);
}

.account-copy {
  display: grid;
  align-content: start;
  gap: 22px;
}

.account-seal {
  width: max-content;
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  padding-inline: 12px;
  border: 1px solid var(--realm-primary);
  border-radius: 999px;
  color: var(--realm-primary);
  font-size: 0.82rem;
  font-weight: 800;
}

.account-copy h2 {
  font-size: clamp(2rem, 4vw, 2.8rem);
}

.account-form {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-content: start;
  gap: 16px;
}

.account-form label:first-child {
  grid-column: 1 / -1;
}

.account-form .button,
.form-message {
  grid-column: 1 / -1;
}

.form-message {
  min-height: 1.5em;
  margin: 0;
  font-size: 0.82rem;
}

.form-message.is-error {
  color: var(--realm-danger);
}

.form-message.is-success {
  color: var(--realm-success);
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding-block: 28px 42px;
  border-top: 1px solid var(--realm-line);
  color: var(--realm-muted);
  font-size: 0.82rem;
}

@media (max-width: 900px) {
  .realm-hero,
  .world-layout,
  .player-section,
  .account-section {
    grid-template-columns: 1fr;
  }

  .realm-hero {
    min-height: 0;
    background:
      linear-gradient(180deg, oklch(0.105 0.03 254 / 0.68) 0%, oklch(0.105 0.03 254 / 0.97) 43%, oklch(0.105 0.03 254) 100%),
      url("/assets/maps/northrend.jpg") 68% 0 / 100% auto no-repeat,
      var(--realm-surface);
  }

  .zone-ledger {
    min-height: 420px;
  }

  .account-section {
    padding: 30px;
  }
}

@media (max-width: 680px) {
  .site-header-inner {
    min-height: 60px;
    align-items: center;
    flex-direction: row;
    padding-block: 8px;
  }

  .site-nav {
    width: auto;
    margin-left: auto;
  }

  .site-nav a:not(.nav-cta) {
    display: none;
  }

  .site-nav .nav-cta {
    min-height: 38px;
    padding-inline: 11px;
    font-size: 0.8rem;
  }

  .page-shell {
    padding-top: 12px;
  }

  .world-section,
  .player-section {
    padding-block: 42px;
  }

  .realm-hero {
    gap: 26px;
    padding: 24px 18px 18px;
  }

  .realm-copy > p {
    margin-bottom: 22px;
    font-size: 0.95rem;
  }

  .hero-lede strong {
    font-size: 1.08rem;
  }

  .connect-command {
    width: 100%;
  }

  .section-heading,
  .map-footer,
  .site-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .privacy-note {
    white-space: normal;
  }

  .section-actions {
    align-items: flex-start;
    flex-direction: column;
  }

  .map-tabs {
    width: 100%;
  }

  .map-toolbar {
    align-items: center;
    flex-direction: column;
  }

  .map-zoom {
    align-self: stretch;
    grid-template-columns: 42px 1fr 42px;
  }

  .map-inspector {
    text-align: left;
  }

  .search-control,
  .hero-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .account-section {
    padding: 22px;
  }

  .account-form {
    grid-template-columns: 1fr;
  }

  .account-form label,
  .account-form label:first-child,
  .account-form .button,
  .form-message {
    grid-column: 1;
  }

  .zone-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 16px;
  }

  .zone-ledger {
    min-height: 0;
  }

  .zone-row:nth-last-child(-n + 2) {
    border-bottom: 0;
  }
}

@media (max-width: 430px) {
  .site-header-inner,
  .page-shell,
  .site-footer {
    width: min(calc(100% - 24px), var(--realm-max));
  }

  h1 {
    font-size: 3.35rem;
  }

  .brand small {
    font-size: 0.71rem;
  }

  .character-details {
    grid-template-columns: 1fr;
  }

  .ledger-metrics div {
    min-height: 82px;
    padding: 14px;
  }

  .ledger-metrics dd {
    font-size: 1.35rem;
  }

  .ledger-heading,
  .rate-line {
    padding-inline: 14px;
  }

  .connect-command {
    align-items: flex-start;
    flex-direction: column;
    gap: 3px;
  }

  .zone-list {
    grid-template-columns: 1fr;
  }

  .zone-row:nth-last-child(2) {
    border-bottom: 1px solid oklch(0.34 0.035 248 / 0.56);
  }

  .character-details div:nth-child(odd),
  .character-details div:nth-child(even) {
    padding-inline: 0;
    border-left: 0;
  }

  .map-toolbar {
    padding-inline: 8px;
  }

  .map-tabs {
    gap: 0;
  }

  .map-tabs button {
    padding-inline: 6px;
    font-size: 0.68rem;
  }

  .map-node-ring {
    r: 4.2px;
  }

  .map-region-label {
    font-size: 3.2px;
  }

  .map-footer {
    padding: 14px;
  }
}

@media (pointer: coarse) {
  .map-bot-hit {
    r: 4.8px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
