/* Display face for headings/logo only -- user-supplied "Diablo Light"
   (MaGiK, 1997), self-hosted. Covers all 9 lowercase Polish diacritics;
   3 uncommon word-initial capitals (Ą Ę Ń) fall back to C9Serif per
   the browser's normal per-glyph font-stack fallback. */
@font-face {
  font-family: "C9DiabloUI";
  src: url("/assets/fonts/diablo-heading.woff2") format("woff2");
  font-display: swap;
}
/* Nav/label face -- Quicksand (OFL), self-hosted, single weight (600). */
@font-face {
  font-family: "C9Nav";
  src: url("/assets/fonts/quicksand-latin.woff2") format("woff2");
  font-weight: 600;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
  font-display: swap;
}
@font-face {
  font-family: "C9Nav";
  src: url("/assets/fonts/quicksand-latin-ext.woff2") format("woff2");
  font-weight: 600;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
  font-display: swap;
}
/* Body face -- Source Serif 4 (OFL), self-hosted, variable weight. */
@font-face {
  font-family: "C9Serif";
  src: url("/assets/fonts/source-serif-4-latin.woff2") format("woff2");
  font-weight: 200 900;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
  font-display: swap;
}
@font-face {
  font-family: "C9Serif";
  src: url("/assets/fonts/source-serif-4-latin-ext.woff2") format("woff2");
  font-weight: 200 900;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
  font-display: swap;
}

:root {
  color-scheme: dark;
  --void: #020205;
  --night: #05060a;
  --night-2: #080a0f;
  --obsidian: #0b0d12;
  --stone: #11151b;
  --stone-raised: #171b22;
  --iron: #2b3139;
  --iron-bright: #4b535e;
  --bone: #d8d2c5;
  --bone-bright: #f0e9d9;
  --ash: #9297a0;
  --dim: #606772;
  /* Renamed in spirit, not in name, to avoid a much larger rename across
     every selector that already reads --blood/--blood-bright: this is now
     the site's dying-ember accent (eyebrows, the IX seal's glow, trade
     arrows...), not blood. Real danger/death states (.status-bad, .hc,
     .notice-danger, .btn-danger) were already independent hardcoded reds
     and are untouched by this. */
  --blood: #8a4a12;
  --blood-bright: #d9822f;
  --ember: #e46c35;
  --gold: #9f824c;
  --gold-bright: #d5b268;
  --frost: #b6c5d7;
  --poison: #6f986d;
  --line: rgba(184, 195, 208, .13);
  --line-strong: rgba(184, 195, 208, .24);
  --gold-line: rgba(198, 162, 91, .28);
  --blood-line: rgba(217, 130, 47, .42);
  --shadow: 0 28px 85px rgba(0, 0, 0, .76);
  --inset: inset 0 0 0 1px rgba(255, 255, 255, .025);
  --radius: 2px;
}

* { box-sizing: border-box; }
html { min-height: 100%; background: var(--void); scroll-behavior: smooth; }
body {
  min-height: 100vh;
  margin: 0;
  color: var(--bone);
  font-family: "C9Serif", Georgia, "Times New Roman", serif;
  background:
    radial-gradient(circle at 50% -8%, rgba(120, 6, 12, .18), transparent 30rem),
    linear-gradient(rgba(2, 3, 6, .88), rgba(2, 3, 5, .98)),
    url("/assets/black-stone.svg") center top / 420px 420px repeat,
    var(--void);
  overflow-x: hidden;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    linear-gradient(90deg, transparent 49.8%, rgba(155, 172, 190, .025) 50%, transparent 50.2%),
    linear-gradient(transparent 49.8%, rgba(155, 172, 190, .02) 50%, transparent 50.2%);
  background-size: 108px 108px;
  mask-image: radial-gradient(circle at 50% 25%, #000 0, transparent 76%);
}
body::after {
  content: "IX";
  position: fixed;
  z-index: -3;
  inset: auto auto 8vh 50%;
  transform: translateX(-50%);
  color: transparent;
  -webkit-text-stroke: 1px rgba(184, 195, 208, .018);
  font-size: min(53vw, 760px);
  font-weight: 700;
  letter-spacing: -.1em;
  pointer-events: none;
}

.sanctuary-backdrop {
  position: fixed;
  z-index: -4;
  inset: 0 0 auto;
  height: min(76vh, 850px);
  background-image:
    linear-gradient(to bottom, rgba(2, 2, 5, .18), rgba(2, 3, 6, .72) 58%, var(--void) 100%),
    radial-gradient(circle at 50% 35%, transparent 0, rgba(2, 3, 6, .18) 26%, rgba(2, 3, 6, .78) 80%),
    url("/operator-assets/fan/portal-hero.webp"),
    url("/operator-assets/fan/portal-hero.png"),
    url("/assets/sanctuary-gate.svg");
  background-position: center, center, center 26%, center 26%, center 18%;
  background-repeat: no-repeat;
  background-size: cover, cover, cover, cover, cover;
  filter: saturate(.72) contrast(1.16) brightness(.63);
  opacity: .92;
}
.sanctuary-vignette {
  position: fixed;
  z-index: -2;
  inset: 0;
  pointer-events: none;
  box-shadow: inset 0 0 190px 58px rgba(0, 0, 0, .9);
  background: linear-gradient(90deg, rgba(0,0,0,.7), transparent 22%, transparent 78%, rgba(0,0,0,.7));
}

::selection { background: rgba(145, 17, 23, .75); color: #fff; }
a { color: var(--gold-bright); text-decoration: none; }
a:hover { color: #fff0c0; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
img { max-width: 100%; }
code, pre, .code { font-family: Consolas, "Cascadia Mono", monospace; }

.shell { width: min(1420px, calc(100% - 40px)); margin-inline: auto; }
.page-main { min-height: calc(100vh - 190px); }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.account-hidden { display: none !important; }
.muted { color: var(--dim); line-height: 1.65; }

/* Header */
.topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid rgba(176, 188, 202, .12);
  background:
    linear-gradient(180deg, rgba(9, 11, 16, .97), rgba(2, 3, 6, .94)),
    url("/assets/black-stone.svg") center / 360px repeat;
  box-shadow: 0 16px 40px rgba(0,0,0,.5);
  backdrop-filter: blur(18px);
}
.topbar::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -1px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--blood) 22%, var(--gold) 50%, var(--blood) 78%, transparent);
  opacity: .45;
}
.topbar-inner { min-height: 78px; display: flex; align-items: center; gap: 22px; }
.brand { display: inline-flex; align-items: center; gap: 13px; color: var(--bone); flex: none; }
.brand-mark {
  position: relative; width: 50px; height: 50px; display: grid; place-items: center;
  clip-path: polygon(50% 0, 87% 14%, 100% 50%, 87% 86%, 50% 100%, 13% 86%, 0 50%, 13% 14%);
  border: 1px solid var(--iron-bright);
  background: radial-gradient(circle at 50% 43%, #4c090d 0, #16070a 38%, #080a0e 69%);
  box-shadow: inset 0 0 24px rgba(195, 35, 42, .32), 0 0 24px rgba(0,0,0,.8);
}
.brand-mark::before, .brand-mark::after {
  content: ""; position: absolute; inset: 7px; border: 1px solid rgba(206, 169, 91, .35); transform: rotate(45deg);
}
.brand-mark::after { inset: 15px; transform: none; border-color: rgba(200, 39, 46, .55); }
.brand-nine { position: relative; z-index: 1; color: var(--gold-bright); font-size: 29px; text-shadow: 0 0 14px var(--blood-bright); }
.brand-copy strong { display: block; color: var(--bone-bright); font-size: 20px; letter-spacing: .14em; text-transform: uppercase; }
.brand-copy span { display: block; color: var(--dim); font: 10px/1.5 Arial, sans-serif; letter-spacing: .22em; text-transform: uppercase; }
.nav { display: flex; align-items: center; gap: 1px; margin-left: auto; }
.nav a, .nav-more summary {
  display: block; padding: 13px 9px; color: var(--ash); border-bottom: 1px solid transparent;
  font: 600 11px/1 "C9Nav", Arial, sans-serif; letter-spacing: .1em; text-transform: uppercase; white-space: nowrap;
}
.nav a:hover, .nav a.active, .nav-more[open] > summary {
  color: var(--gold-bright); border-color: var(--blood-bright); background: rgba(116, 9, 15, .14);
}
.nav-more { position: relative; }
.nav-more summary { list-style: none; cursor: pointer; }
.nav-more summary::-webkit-details-marker { display: none; }
.nav-more summary::after { content: " ▾"; color: var(--dim); }
.nav-menu {
  position: absolute; top: 44px; right: 0; min-width: 220px; padding: 7px;
  border: 1px solid var(--line-strong); background: rgba(4, 6, 10, .985); box-shadow: var(--shadow);
}
.nav-menu::before { content: ""; position: absolute; inset: 4px; border: 1px solid rgba(255,255,255,.025); pointer-events: none; }
.nav-menu a { position: relative; padding: 13px 14px; border: 0; }
.header-tools { display: flex; align-items: center; gap: 10px; }
.language-switch {
  display: flex; align-items: center; gap: 5px; padding: 7px 9px; border: 1px solid var(--line);
  background: rgba(3,5,8,.7); font: 10px Arial, sans-serif;
}
.language-switch a { color: var(--dim); }
.language-switch a.active { color: var(--gold-bright); }
.language-switch span { color: #313741; }
.season-pill { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border: 1px solid var(--line); color: var(--ash); font: 10px Arial, sans-serif; white-space: nowrap; }
.live-dot { width: 7px; height: 7px; border-radius: 50%; background: #6ba671; box-shadow: 0 0 11px #6ba671; }

/* Typography and hero */
h1, h2, h3, h4, .brand-copy strong {
  font-family: "C9DiabloUI", Georgia, "Times New Roman", serif;
  color: #e5e7e7; font-weight: 500; letter-spacing: .015em;
  text-shadow: 0 5px 30px rgba(0,0,0,.95);
}
.eyebrow, .kicker { color: var(--blood-bright); font: 700 10px/1.3 Arial, sans-serif; letter-spacing: .23em; text-transform: uppercase; }
.hero { padding: 72px 0 42px; text-align: center; }
.compact-hero { padding-top: 64px; }
.hero h1 { margin: 13px 0 16px; font-size: clamp(44px, 6.7vw, 84px); line-height: .96; letter-spacing: .015em; }
.hero p { max-width: 830px; margin: 0 auto; color: var(--ash); font-size: 17px; line-height: 1.75; }
.hero-home {
  min-height: 650px; display: grid; grid-template-columns: minmax(0, 1.04fr) minmax(420px, .96fr);
  align-items: center; gap: 54px; padding: 72px 0 55px; text-align: left;
}
.hero-home h1 { margin: 14px 0 18px; font-size: clamp(52px, 6.4vw, 94px); line-height: .91; }
.hero-home h1 span { display: block; margin-top: 17px; color: var(--gold-bright); font-size: .31em; letter-spacing: .23em; text-transform: uppercase; }
.hero-home p { margin-inline: 0; max-width: 700px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.rune-divider { display: flex; align-items: center; gap: 14px; width: min(560px, 90%); margin: 31px auto 0; }
.hero-home .rune-divider { margin-left: 0; }
.rune-divider::before, .rune-divider::after { content: ""; height: 1px; flex: 1; background: linear-gradient(90deg, transparent, var(--gold-line)); }
.rune-divider::after { transform: rotate(180deg); }
.rune-divider span { width: 9px; height: 9px; border: 1px solid var(--gold); transform: rotate(45deg); box-shadow: 0 0 13px rgba(190,151,78,.28); }
.hero-oath { display: flex; flex-wrap: wrap; gap: 7px 18px; margin-top: 20px; color: var(--dim); font: 9px Arial, sans-serif; letter-spacing: .12em; text-transform: uppercase; }
.hero-oath span::before { content: "✦"; margin-right: 7px; color: var(--blood-bright); }
.hero-art { min-height: 510px; display: grid; place-items: center; }
.hero-art-frame {
  position: relative; width: min(100%, 590px); aspect-ratio: 4 / 5;
  border: 1px solid rgba(187, 199, 211, .2);
  background-image:
    linear-gradient(to top, rgba(3,4,7,.96), transparent 45%),
    radial-gradient(circle at 50% 43%, rgba(147, 15, 22, .05), rgba(2,3,6,.38) 50%, rgba(2,3,6,.9) 100%),
    url("/operator-assets/fan/portal-hero.webp"),
    url("/operator-assets/fan/portal-hero.png"),
    url("/assets/sanctuary-gate.svg");
  background-position: center; background-repeat: no-repeat; background-size: cover;
  box-shadow: inset 0 0 100px rgba(0,0,0,.84), 0 38px 90px rgba(0,0,0,.86);
  clip-path: polygon(7% 0, 93% 0, 100% 7%, 100% 93%, 93% 100%, 7% 100%, 0 93%, 0 7%);
}
.hero-art-frame::before, .hero-art-frame::after { content: ""; position: absolute; inset: 6px; border: 1px solid rgba(198,162,91,.19); pointer-events: none; }
.hero-art-frame::after { inset: 13px; border-color: rgba(168,181,195,.08); }
.hero-art-title { position: absolute; z-index: 1; bottom: 20px; left: 0; right: 0; text-align: center; color: var(--dim); font: 9px Arial,sans-serif; letter-spacing: .27em; text-transform: uppercase; }

/* Panels and cards. The public pages use one restrained Circle of Nine
   frame language; repeated tiles keep a lighter hairline so dense lists
   remain readable without turning every element into a heavy box. */
.panel { position: relative; margin-bottom: 56px; }
.status-card, .content-card, .news-card, .zone-card, .trade-card, .grail-progress-card {
  position: relative; border: 1px solid var(--line); border-radius: var(--radius);
  background: rgba(255, 255, 255, .014);
}
.panel-head { position: relative; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 18px; padding-bottom: 20px; border-bottom: 1px solid var(--line); }
.panel-head h2 { margin: 0; font-size: 26px; }
.panel-head p { margin: 6px 0 0; color: var(--dim); font: 12px/1.55 Arial,sans-serif; }
.panel-body { position: relative; z-index: 1; padding-top: 24px; }
.panel-rule { border: 0; border-top: 1px solid var(--line); margin: 20px 0; }
.section-title { display: flex; align-items: end; justify-content: space-between; gap: 22px; margin: 54px 0 18px; }
.section-title h2 { margin: 6px 0 0; font-size: 34px; }
.section-title p { max-width: 650px; margin: 0; color: var(--dim); line-height: 1.65; }
.grid-2 { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 18px; }
.content-grid, .news-grid, .trust-grid, .clan-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 15px; }
.content-card, .news-card, .zone-card { padding: 23px; }
.content-card h3, .news-card h3, .zone-card h3 { margin: 10px 0 9px; font-size: 23px; }
.content-card p, .news-card p, .zone-card p { margin: 0; color: var(--ash); line-height: 1.67; }
.news-card.featured { grid-column: span 2; background: radial-gradient(circle at 84% 0, rgba(136,14,21,.22), transparent 20rem), linear-gradient(145deg,rgba(22,26,34,.96),rgba(4,6,10,.98)); }
.news-card time { display: block; margin-top: 18px; color: var(--dim); font: 10px Arial,sans-serif; }
.news-chronicle { margin: 0 auto 110px; max-width: 980px; }
.news-chronicle-entry { display: grid; gap: 38px; grid-template-columns: 175px minmax(0,1fr); position: relative; }
.news-chronicle-rail { border-right: 1px solid rgba(201,150,75,.22); min-height: 260px; padding: 7px 34px 45px 0; position: relative; text-align: right; }
.news-chronicle-rail > span { background: #9e321a; border: 4px solid #120b08; box-shadow: 0 0 0 1px rgba(224,111,48,.56),0 0 18px rgba(226,82,32,.28); height: 11px; position: absolute; right: -6px; top: 9px; transform: rotate(45deg); width: 11px; }
.news-chronicle-rail time { color: #7f766c; font: 600 9px/1.55 "C9Nav",Arial,sans-serif; letter-spacing: .08em; }
.news-chronicle-content { border-bottom: 1px solid rgba(201,150,75,.14); padding: 0 0 48px; }
.news-chronicle-entry + .news-chronicle-entry .news-chronicle-content { padding-top: 8px; }
.news-chronicle-content h2 { color: #e7dccd; font: 400 clamp(29px,3.5vw,43px)/1.12 "C9Serif",Georgia,serif; margin: 13px 0 15px; }
.news-chronicle-content .news-lead { color: #b1a598; font: italic 17px/1.65 "C9Serif",Georgia,serif; margin: 0 0 24px; }
.news-chronicle-content .news-body { color: #8e857b; line-height: 1.75; max-width: 760px; }
.news-chronicle-content small { color: #665f57; display: block; font: 600 8px/1.4 "C9Nav",Arial,sans-serif; letter-spacing: .12em; margin-top: 24px; text-transform: uppercase; }
.news-chronicle-entry.latest .news-chronicle-content { background: linear-gradient(90deg,rgba(108,30,16,.12),transparent); padding-left: 24px; }
.news-body { white-space: pre-wrap; }
.zone-row { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 15px; }
.zone-card { border-left: 2px solid var(--blood); }
.zone-card .zone-time { display: block; margin-top: 15px; color: var(--gold-bright); }
.status-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 13px; margin-bottom: 20px; }
.status-card { min-height: 92px; display: flex; align-items: center; gap: 15px; padding: 18px 20px; }
.status-icon { flex: none; width: 42px; height: 42px; display: grid; place-items: center; border: 1px solid var(--line-strong); background: #07090d; color: var(--gold); transform: rotate(45deg); }
.status-icon span { transform: rotate(-45deg); font-size: 13px; }
.status-copy small { display: block; color: var(--dim); font: 9px Arial,sans-serif; letter-spacing: .16em; text-transform: uppercase; }
.status-copy strong { display: block; margin-top: 5px; color: var(--bone); font-size: 16px; }
.status-copy > span { display: block; margin-top: 4px; color: var(--dim); font: 10px Arial,sans-serif; }
.status-ok { color: #7db482 !important; }
.status-bad { color: #df6764 !important; }

/* Forms and controls */
.btn {
  min-height: 42px; padding: 11px 16px; border: 1px solid var(--line-strong); border-radius: var(--radius);
  background: linear-gradient(#11161e,#080b10); color: var(--bone); font: 10px Arial,sans-serif; letter-spacing: .12em; text-transform: uppercase;
  transition: border-color .16s, color .16s, background .16s, transform .08s;
}
.btn:hover { border-color: var(--gold); color: #fff; background: linear-gradient(#1a2029,#0b0f15); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .4; cursor: not-allowed; }
.btn-primary { border-color: #7c171d; background: linear-gradient(#83171e,#43090e); color: #f1d9c3; box-shadow: inset 0 0 18px rgba(255,88,67,.08); }
.btn-primary:hover { border-color: #d44a4d; background: linear-gradient(#a32028,#570c12); }
.btn-ghost { background: rgba(4,6,9,.42); }
.btn-danger { border-color: #85262a; color: #f0a2a2; }
.field {
  width: 100%; min-height: 44px; padding: 11px 13px; border: 1px solid var(--line-strong); border-radius: 0;
  outline: none; background: rgba(3,5,8,.92); color: var(--bone); font-family: Arial,sans-serif;
}
.field:focus { border-color: var(--gold); box-shadow: 0 0 0 2px rgba(177,142,75,.08), inset 0 0 20px rgba(0,0,0,.45); }
.field::placeholder { color: #505761; }
select.field { color-scheme: dark; }
textarea.field { resize: vertical; }
.form-row label { display: block; margin-bottom: 7px; color: var(--dim); font: 9px Arial,sans-serif; letter-spacing: .13em; text-transform: uppercase; }
.form-actions { display: flex; align-items: center; gap: 8px; }
.form-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 10px; }
.toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.toolbar .search { flex: 1 1 340px; }
.check-row { display: block; margin: 12px 0; color: var(--ash); font: 11px Arial,sans-serif; }
.notice { position: relative; margin: 16px 0; padding: 13px 15px; border: 1px solid var(--line); background: rgba(5,8,13,.9); color: var(--ash); font: 12px/1.65 Arial,sans-serif; }
.notice-danger { border-color: rgba(209,45,50,.55); color: #eba1a2; }
.empty { padding: 30px; text-align: center; color: var(--dim); font: 12px/1.7 Arial,sans-serif; }
.empty strong { display: block; margin-bottom: 6px; color: var(--bone); font: 20px Georgia,serif; }
.skeleton { min-height: 18px; border-radius: 2px; background: linear-gradient(100deg,#0b1017 25%,#171f29 39%,#0b1017 53%); background-size: 300% 100%; animation: skeleton 1.7s infinite; }
@keyframes skeleton { to { background-position-x: -300%; } }
.output { max-height: 430px; overflow: auto; padding: 14px; border: 1px solid var(--line); background: #020407; color: #a8b1bc; font-size: 11px; line-height: 1.55; }
.text-link { display: inline-block; margin-top: 17px; color: var(--gold-bright); font: 10px Arial,sans-serif; letter-spacing: .13em; text-transform: uppercase; }

/* Home */
.home-feature-grid { display: grid; grid-template-columns: minmax(0,1.1fr) minmax(360px,.9fr); gap: 16px; margin-top: 22px; }
.gem-panel { overflow: hidden; }
.gem-shrine { min-height: 410px; display: grid; place-items: center; align-content: center; overflow: hidden; }
.gem-shrine::before { content: ""; position: absolute; width: 390px; height: 390px; border-radius: 50%; background: radial-gradient(circle,rgba(156,15,22,.21),transparent 64%); filter: blur(8px); }
.lobby-gem { position: relative; z-index: 1; width: min(290px,78vw); padding: 0; border: 0; background: transparent; filter: drop-shadow(0 35px 38px #000); transition: transform .12s, filter .25s; }
.lobby-gem:hover { transform: translateY(-4px); filter: drop-shadow(0 35px 38px #000) drop-shadow(0 0 17px rgba(193,30,37,.36)); }
.lobby-gem:active { transform: translateY(3px) scale(.985); }
.lobby-gem img { display: block; width: 100%; }
.lobby-gem.perfect { filter: drop-shadow(0 35px 38px #000) drop-shadow(0 0 34px rgba(255,65,65,.8)) saturate(1.35); }
.gem-state { position: relative; z-index: 1; margin-top: -30px; text-align: center; color: var(--dim); font: 10px Arial,sans-serif; letter-spacing: .12em; text-transform: uppercase; }
.gem-state strong { display: block; margin-bottom: 6px; color: var(--gold-bright); font-size: 14px; }
.realm-manifesto .panel-body { min-height: 410px; display: flex; flex-direction: column; justify-content: center; }
.realm-manifesto p { color: var(--ash); font-size: 17px; line-height: 1.8; }
.nine-seal { position: relative; width: 158px; height: 158px; display: grid; place-items: center; margin: 22px auto 9px; clip-path: polygon(50% 0,86% 14%,100% 50%,86% 86%,50% 100%,14% 86%,0 50%,14% 14%); border: 1px solid var(--gold-line); background: radial-gradient(circle,#48080d,#12070a 44%,#06080c 72%); box-shadow: inset 0 0 34px rgba(186,29,36,.25),0 20px 40px rgba(0,0,0,.7); }
.nine-seal::before, .nine-seal::after { content: ""; position: absolute; inset: 23px; border: 1px solid rgba(197,160,83,.34); transform: rotate(45deg); }
.nine-seal::after { inset: 40px; transform: none; border-color: rgba(193,35,42,.52); }
.nine-seal span { position: absolute; top: 27px; color: var(--gold); font: 9px Arial,sans-serif; letter-spacing: .22em; }
.nine-seal strong { position: relative; z-index: 1; color: #d9c89c; font-size: 46px; text-shadow: 0 0 18px var(--blood-bright); }
.item-spotlight { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 13px; }
.item-spotlight-card { display: flex; align-items: center; gap: 16px; padding: 18px; }
.item-spotlight-card .item-tile { flex: none; }
.item-spotlight-card h3 { margin: 2px 0 5px; font-size: 19px; }
.item-spotlight-card p { margin: 0; color: var(--dim); font: 11px/1.5 Arial,sans-serif; }

/* Ladder */
.track-builder { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 10px; margin-bottom: 15px; }
.segment { display: flex; }
.segment button { flex: 1; min-height: 43px; border: 1px solid var(--line); background: #04070b; color: var(--ash); }
.segment button.active { border-color: var(--gold); color: var(--gold-bright); background: linear-gradient(#181a20,#0b0c11); box-shadow: inset 0 -2px var(--blood); }
.ladder-toolbar { display: grid; grid-template-columns: minmax(300px,1fr) minmax(170px,.32fr) minmax(150px,.24fr); }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 14px 16px; border-bottom: 1px solid var(--line); text-align: left; }
th { color: var(--dim); font: 9px Arial,sans-serif; letter-spacing: .14em; text-transform: uppercase; }
tbody tr:hover { background: rgba(133,16,22,.07); }
.rank, .level { color: var(--gold-bright); }
.char-name { display: block; color: var(--bone-bright); font-size: 16px; }
.char-sub { display: block; margin-top: 4px; color: var(--dim); font: 10px Arial,sans-serif; }
.dead { opacity: .58; }
.hc { color: #e16a69; }
.delta-up { color: #73b77b; }
.delta-down { color: #db6664; }
.delta-flat { color: var(--dim); }
.source-strip, .pagination { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 20px; border-top: 1px solid var(--line); color: var(--dim); font: 11px Arial,sans-serif; }
.pagination { justify-content: center; }

/* Armory */
.armory-search-form {
  display: grid;
  grid-template-columns: minmax(420px, 3.6fr) minmax(235px, .9fr) auto;
  align-items: end;
  gap: 12px;
}
.armory-name-field { min-width: 0; }
.armory-name { min-height: 50px; font-size: 18px; letter-spacing: .03em; }
.armory-track-field { width: min(100%, 320px); justify-self: end; }
.armory-track { min-height: 50px; font-size: 12px; }
.armory-submit { min-height: 50px; white-space: nowrap; }
.trust-grid { margin-bottom: 40px; }
.trust-number { position: absolute; top: 13px; right: 17px; color: rgba(201,165,88,.16); font-size: 54px; }
.character-stat-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 13px; margin-bottom: 18px; }
.armory-section-nav {
  align-items: center; background: rgba(3,3,5,.94); border: 1px solid rgba(201,150,75,.2); box-shadow: 0 12px 32px rgba(0,0,0,.42);
  display: flex; gap: 2px; margin: 0 0 18px; overflow-x: auto; padding: 5px; position: sticky; scrollbar-width: thin; top: 88px; z-index: 90;
}
.armory-section-nav a { color: #9d9488; flex: none; font: 600 9px/1 "C9Nav",Arial,sans-serif; letter-spacing: .11em; padding: 12px 14px; text-transform: uppercase; }
.armory-section-nav a:hover, .armory-section-nav a:focus-visible { background: rgba(201,150,75,.09); color: #f0e4d3; outline: none; }
.armory-anchor { scroll-margin-top: 145px; }
.armory-bonuses-panel .text-link { margin-top: 0; }
.key-bonus-grid { display: grid; gap: 1px; grid-template-columns: repeat(3,minmax(0,1fr)); background: rgba(201,150,75,.14); }
.key-bonus { align-items: center; background: linear-gradient(145deg,rgba(8,9,12,.98),rgba(2,3,5,.98)); display: grid; gap: 15px; grid-template-columns: 42px minmax(0,1fr); min-height: 78px; padding: 13px 16px; }
.key-bonus-rune { align-items: center; aspect-ratio: 1; background: radial-gradient(circle,#35070b,#09090c 68%); border: 1px solid rgba(201,150,75,.38); color: #ddc386; display: flex; font: 700 9px/1 "C9Nav",Arial,sans-serif; justify-content: center; letter-spacing: .06em; transform: rotate(45deg); }
.key-bonus-rune b { transform: rotate(-45deg); }
.key-bonus > div { display: grid; gap: 5px; min-width: 0; }
.key-bonus small { color: #8f8890; font: 600 8px/1.35 "C9Nav",Arial,sans-serif; letter-spacing: .08em; text-transform: uppercase; }
.key-bonus strong { color: #ece0cf; font: 400 21px/1 "C9Serif",Georgia,serif; }
.key-bonus.is-zero { filter: saturate(.25); opacity: .5; }
.weapon-set-legend { color: #8f8890; font: 600 9px/1 "C9Nav",Arial,sans-serif; letter-spacing: .08em; text-transform: uppercase; }
.weapon-set-switch { display:flex; align-items:center; border:1px solid rgba(151,108,48,.28); background:rgba(0,0,0,.35); }
.weapon-set-tab { min-height:34px; padding:0 13px; border:0; border-left:1px solid rgba(151,108,48,.2); background:transparent; color:#77727a; font:600 9px/1 "C9Nav",Arial,sans-serif; letter-spacing:.08em; text-transform:uppercase; cursor:pointer; }
.weapon-set-tab:first-child { border-left:0; }
.weapon-set-tab b { margin-right:5px; color:#a78a58; }
.weapon-set-tab:hover,.weapon-set-tab:focus-visible { color:#e2d5c3; outline:0; }
.weapon-set-tab.active { color:#f0e4d3; background:linear-gradient(180deg,rgba(116,46,19,.48),rgba(58,22,10,.28)); box-shadow:inset 0 -2px #b84824; }
.armory-layout { display: grid; grid-template-columns: minmax(570px,1.15fr) minmax(360px,.85fr); gap: 18px; align-items: start; }
.armory-left-stack { display: grid; gap: 18px; min-width: 0; }
.armory-left-stack .panel { margin-bottom: 0; }
.paperdoll { min-height: 490px; background: radial-gradient(circle at 50% 40%, rgba(170,85,20,.13), transparent 28rem), linear-gradient(rgba(2,4,7,.35),rgba(2,4,7,.82)), url("/assets/paperdoll-runes.svg") center / cover no-repeat; }
/* Character sheet: several logically-distinct readouts (rank, attributes,
   skills, mercenary) composed as one panel with lightweight internal
   dividers, instead of each getting its own full bordered card -- the
   repeated big-header-plus-card pattern was the main source of the
   "mishmash" feel reported live against this exact page. */
.sheet-block { padding-bottom: 18px; margin-bottom: 18px; border-bottom: 1px solid var(--line); }
.sheet-block:last-child { padding-bottom: 0; margin-bottom: 0; border-bottom: none; }
.sheet-block h3 { margin: 0 0 12px; font: 700 11px/1 Arial,sans-serif; letter-spacing: .12em; text-transform: uppercase; color: var(--gold-bright); }
.sheet-block .chart { display: block; }
.sheet-block #mercenaryStatus { margin: 0 0 10px; color: var(--dim); font-size: 13px; }
.sheet-note { margin: 10px 0 0; color: var(--dim); font: 11px/1.4 Arial,sans-serif; }
.character-page .panel-head { padding: 16px 20px; }
.character-page .panel-head h2 { font-size: 15px; letter-spacing: .06em; text-transform: uppercase; }
.character-page .panel-body { padding: 18px 20px; }
.character-page .panel { margin-bottom: 18px; }
.equipment-grid {
  min-height: 450px; display: grid; grid-template-columns: repeat(5,1fr); grid-template-rows: repeat(5,78px); gap: 8px;
  grid-template-areas:
    ".      .          head    .           ."
    ".      .          amulet  .           ."
    "weapon .          armor   .           shield"
    "weapon .          armor   .           shield"
    "gloves ring-left  belt    ring-right  boots";
}
.slot-head { grid-area: head; }
.slot-amulet { grid-area: amulet; }
.slot-weapon { grid-area: weapon; }
.slot-armor { grid-area: armor; }
.slot-shield { grid-area: shield; }
.slot-gloves { grid-area: gloves; }
.slot-ring-left { grid-area: ring-left; }
.slot-belt { grid-area: belt; }
.slot-ring-right { grid-area: ring-right; }
.slot-boots { grid-area: boots; }
.item-slot { min-width: 54px; min-height: 62px; display: grid; place-items: center; border: 1px solid rgba(135,147,160,.2); background: rgba(2,4,7,.72); box-shadow: inset 0 0 17px rgba(0,0,0,.78); }
.item-slot-inner { width: 100%; height: 100%; display: grid; place-items: center; border: 0; background: transparent; padding: 3px; }
.item-slot-inner img { max-width: 90%; max-height: 90%; image-rendering: pixelated; filter: drop-shadow(0 8px 6px #000); }
.item-slot-inner span { color: var(--dim); font-size: 11px; }
.item-grid, .account-items { display: flex; flex-wrap: wrap; gap: 8px; min-height: 74px; }
.item-tile { position: relative; width: 72px; min-height: 72px; display: grid; place-items: center; border: 1px solid rgba(139,152,166,.22); background: radial-gradient(circle,#10161e,#030508 72%); color: var(--gold-bright); box-shadow: inset 0 0 18px rgba(0,0,0,.75); }
.item-tile:hover, .item-tile:focus { border-color: var(--gold); outline: none; }
.item-tile img { max-width: 58px; max-height: 58px; image-rendering: pixelated; filter: drop-shadow(0 7px 5px #000); }
.item-tooltip { position: fixed; z-index: 300; min-width: 280px; max-width: 420px; max-height: calc(100vh - 32px); overflow-y: auto; padding: 16px 18px; border: 1px solid rgba(113,123,145,.74); background: radial-gradient(circle at 50% 0,rgba(24,30,46,.2),transparent 48%),rgba(0,1,4,.985); color: #f5f4f0; box-shadow: 0 20px 65px #000, inset 0 0 35px rgba(45,58,78,.15); pointer-events: none; font: 13px/1.38 Arial,sans-serif; text-align: center; }
.item-tooltip[hidden] { display: none; }
.item-tooltip h3 { margin: 0 0 3px; font: 600 16px/1.25 Arial,sans-serif; text-shadow: 0 1px #000; }
.item-tooltip .item-base { color: #d4d4d6; }
.item-tooltip .item-title-block { margin-bottom: 7px; }
.item-tooltip .item-socket-sequence { color: #bca574; font-weight: 600; letter-spacing: .01em; text-shadow: 0 1px #000; }
.item-tooltip .item-socket-sequence.contents { color: #8ea2ff; font-weight: 400; }
.item-tooltip .item-rule { height: 1px; margin: 9px 0; background: #2e3440; }
.item-tooltip .item-base-stats { color: #f2f2ef; }
.item-tooltip .item-stat { color: #718cff; text-shadow: 0 0 7px rgba(91,112,255,.12); }
.item-tooltip .item-stat.blue { color: #718cff; }
.item-tooltip .item-stat.red { color: #e05b59; }
.item-tooltip .item-stat.green { color: #43ca66; }
.item-tooltip .item-stat.gold { color: #d7bb77; }
.item-tooltip .item-stat.gray { color: #8f939a; }
.item-tooltip .item-stat.white { color: #f2f2ef; }
.item-tooltip .item-requirement { color: #f2f2f2; }
.item-tooltip .item-unidentified { color: #e65e5b; }
.item-tooltip .item-ethereal { color: #aeb3bd; }
.item-tooltip .item-guid { margin-top: 9px; color: #555e69; font-size: 9px; }
.item-sockets { border-bottom: 1px solid rgba(92,101,121,.3); border-top: 1px solid rgba(92,101,121,.3); margin: 9px 0; padding: 8px 0; }
.item-sockets-label { color: #696f7b; font: 600 8px/1 "C9Nav",Arial,sans-serif; letter-spacing: .13em; margin-bottom: 7px; text-transform: uppercase; }
.item-socket-list { display: flex; flex-wrap: wrap; gap: 5px; justify-content: center; }
.item-socket { align-items: center; background: rgba(14,17,24,.92); border: 1px solid rgba(117,126,145,.3); display: inline-flex; gap: 5px; min-height: 27px; padding: 4px 8px; }
.item-socket img { height: 20px; image-rendering: pixelated; object-fit: contain; width: 20px; }
.item-socket b { font: 600 11px/1 Arial,sans-serif; }
.quality-unique { color: #cbb178 !important; }
.quality-set { color: #49c864 !important; }
.quality-rare { color: #f0dc55 !important; }
.quality-magic { color: #748cff !important; }
.quality-crafted { color: #dd7d3f !important; }
.quality-rune { color: #d8d8d8 !important; }
.quality-runeword { color: #d8bd7c !important; }
.socket-rune { color: #d8c798 !important; }
.socket-gem { color: #8ad7ef !important; }
.socket-jewel { color: #c88ee8 !important; }
.chart { display:block; width:100%; min-height:300px; overflow:visible; }
.chart text { fill:var(--dim); font:10px "C9Nav",Arial,sans-serif; }
.gridline { stroke:rgba(160,175,194,.11); stroke-dasharray:3 5; }
.chart-axis,.chart-tick { stroke:rgba(196,143,43,.32); }
.chart-date-label { fill:#9e9489!important; font-size:9px!important; letter-spacing:.04em; }
.chart-y-label { fill:#877d72!important; font-size:9px!important; }
.rankarea { fill:url(#xpArea); }
.rankline { fill:none; stroke:var(--gold-bright); stroke-linecap:round; stroke-linejoin:round; stroke-width:2.4; }
.point { fill:#9e2c22; stroke:#e2ad50; stroke-width:1.2; transition:r .16s ease; }
.point:hover,.point-current { fill:#e0a747; r:5px; }
.character-progress-panel { margin-bottom: 18px; }
.character-progress-body { display: grid; gap: 18px; }
.xp-stat-grid { display: grid; gap: 1px; grid-template-columns: repeat(5,minmax(0,1fr)); background: var(--line); }
.xp-stat { background: rgba(3,5,8,.92); display: grid; gap: 8px; min-height: 82px; padding: 16px 18px; }
.xp-stat small { color: var(--dim); font: 600 9px/1.3 "C9Nav",Arial,sans-serif; letter-spacing: .1em; text-transform: uppercase; }
.xp-stat strong { color: #ddd2c3; font: 400 20px/1.2 "C9Serif",Georgia,serif; }
.xp-progress-track { height: 8px; }
.xp-progress-stack { display:grid; gap:13px; }
.xp-progress-row { display:grid; gap:7px; }
.xp-progress-meta { display:flex; align-items:center; justify-content:space-between; gap:16px; color:var(--dim); font:600 9px/1.2 "C9Nav",Arial,sans-serif; letter-spacing:.08em; text-transform:uppercase; }
.xp-progress-meta strong { color:var(--paper); font-weight:600; text-align:right; }
.xp-chart-shell { border:1px solid rgba(196,143,43,.18); background:radial-gradient(circle at 72% 16%,rgba(139,52,24,.10),transparent 38%),linear-gradient(180deg,rgba(10,8,8,.84),rgba(3,4,6,.94)); padding:10px 12px 2px; }
.character-progress-body .chart { min-height:260px; }

.storage-layout { align-items: start; display: grid; gap: 18px; grid-template-columns: minmax(330px,.75fr) minmax(500px,1.25fr); }
.inventory-side-stack { display: grid; gap: 18px; }
.storage-layout .inventory-side-stack { grid-template-columns: repeat(2,minmax(0,1fr)); }
.inventory-side-stack .panel { margin-bottom: 0; }
.d2-container-wrap { overflow-x: auto; }
.d2-item-container {
  --cell: 44px;
  background-color: #05080d;
  background-image:
    linear-gradient(rgba(131,143,157,.18) 1px,transparent 1px),
    linear-gradient(90deg,rgba(131,143,157,.18) 1px,transparent 1px),
    radial-gradient(circle at 50% 42%,rgba(40,58,74,.28),transparent 70%);
  background-size: var(--cell) var(--cell),var(--cell) var(--cell),100% 100%;
  border: 3px ridge rgba(111,102,86,.52);
  box-shadow: inset 0 0 25px #000,0 8px 25px rgba(0,0,0,.3);
  display: grid;
  grid-auto-flow: row dense;
  grid-auto-rows: var(--cell);
  grid-template-columns: repeat(var(--cols),var(--cell));
  height: calc(var(--rows) * var(--cell) + 6px);
  margin: 0 auto;
  padding: 3px;
  position: relative;
  width: calc(var(--cols) * var(--cell) + 6px);
}
.d2-grid-item.item-tile {
  height: auto;
  min-height: 0;
  overflow: hidden;
  padding: 2px;
  width: auto;
  z-index: 1;
}
.d2-grid-item.item-tile img { max-height: 94%; max-width: 94%; }
.d2-container-empty { align-items: center; color: #625c55; display: flex; font: italic 12px/1.4 "C9Serif",Georgia,serif; grid-column: 1 / -1; grid-row: 1 / -1; justify-content: center; padding: 12px; text-align: center; }

/* Grail */
.grail-search-form { display: grid; grid-template-columns: minmax(250px,1.6fr) minmax(210px,1fr) minmax(180px,.75fr) auto; align-items: end; gap: 12px; }
.grail-summary-grid { display: grid; grid-template-columns: minmax(320px,.8fr) minmax(0,1.2fr); gap: 16px; }
.grail-progress-card { min-height: 220px; display: flex; flex-direction: column; justify-content: center; padding: 28px; text-align: center; }
.grail-progress-card strong { display: block; margin: 10px 0; color: var(--gold-bright); font-size: 58px; font-weight: 500; }
.progress-track { height: 11px; overflow: hidden; border: 1px solid var(--line); background: #020407; }
.progress-track span { display: block; height: 100%; width: 0; background: linear-gradient(90deg,#671016,#c32a31,#d3ad63); transition: width .35s; }
.grail-proof .panel-body { min-height: 220px; display: flex; flex-direction: column; justify-content: center; }
.grail-proof h3 { margin: 9px 0; font-size: 27px; }
.grail-proof p { color: var(--ash); line-height: 1.7; }
.grail-toolbar { display: grid; grid-template-columns: minmax(260px,1fr) minmax(170px,.28fr); gap: 10px; }
.grail-grid { display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); gap: 1px; padding: 1px; background: var(--line); }
.grail-item { min-height: 118px; position: relative; display: grid; grid-template-columns: 72px 1fr; align-items: center; gap: 11px; padding: 13px; background: #05080d; }
.grail-item.missing { opacity: .42; filter: grayscale(.85); }
.grail-item.found::before { content: "✓"; position: absolute; right: 9px; top: 7px; color: #71b17a; }
.grail-item h3 { margin: 0 0 4px; font: 15px/1.25 Arial,sans-serif; text-shadow: none; }
.grail-item p { margin: 0; color: var(--dim); font: 10px/1.45 Arial,sans-serif; }
.grail-item .grail-find-line { color: #9f978b; margin-top: 5px; }
.grail-item .grail-find-origin { color: #7d715f; margin-top: 2px; }
.grail-ranking-panel { margin: 16px 0; }
.grail-leaderboard { display: grid; }
.grail-rank-row { align-items: center; border-top: 1px solid rgba(201,150,75,.12); display: grid; gap: 18px; grid-template-columns: 54px minmax(170px,.72fr) minmax(240px,1.28fr) 82px; min-height: 76px; padding: 12px 24px; }
.grail-rank-row:hover { background: rgba(201,150,75,.045); }
.grail-rank-row > b { color: #c4914a; font: 400 22px/1 "C9Serif",Georgia,serif; }
.grail-rank-row.grail-rank-podium > b { color: var(--gold-bright); text-shadow: 0 0 14px rgba(211,173,99,.22); }
.grail-rank-player { display: grid; gap: 4px; min-width: 0; }
.grail-rank-row strong { color: #dfd4c5; font: 400 17px/1.2 "C9Serif",Georgia,serif; }
.grail-rank-row small { color: #6f675f; font: 9px/1.3 "C9Nav",Arial,sans-serif; }
.grail-rank-progress { display: grid; gap: 7px; min-width: 0; }
.grail-rank-progress-track { background: #020304; border: 1px solid rgba(201,150,75,.2); box-shadow: inset 0 0 9px rgba(0,0,0,.9); display: block; height: 10px; overflow: hidden; }
.grail-rank-progress-track > i { background: linear-gradient(90deg,#5d0e13,#b3282d 58%,#d1a65d); box-shadow: 0 0 12px rgba(190,44,48,.32); display: block; height: 100%; min-width: 2px; transition: width .45s ease; }
.grail-rank-row.is-complete .grail-rank-progress-track > i { background: linear-gradient(90deg,#78602e,#d4ae5e,#f0d99b); box-shadow: 0 0 13px rgba(224,192,125,.38); }
.grail-rank-progress > small { letter-spacing: .06em; text-transform: uppercase; }
.grail-rank-row em { color: #c8a86f; font: normal 600 12px/1 "C9Nav",Arial,sans-serif; text-align: right; }

/* Achievements */
.achievement-toolbar { align-items: end; display: grid; gap: 18px; grid-template-columns: minmax(220px,360px) minmax(260px,1fr); }
.achievement-toolbar label { color: var(--dim); display: grid; font: 600 9px/1 "C9Nav",Arial,sans-serif; gap: 8px; letter-spacing: .12em; text-transform: uppercase; }
.achievement-toolbar form label > span { display: grid; gap: 8px; grid-template-columns: minmax(0,1fr) auto; }
.achievement-profile { align-items: center; background: radial-gradient(circle at 7% 50%,rgba(133,28,19,.2),transparent 15rem),#050505; border-top: 1px solid rgba(201,150,75,.16); display: grid; gap: 28px; grid-template-columns: minmax(0,1fr) minmax(260px,.7fr); margin: 22px -22px -22px; padding: 21px 24px; }
.achievement-profile[hidden] { display: none; }
.achievement-profile > div:first-child { align-items: center; display: grid; gap: 15px; grid-template-columns: 48px minmax(0,1fr); }
.achievement-profile > div:first-child > span { align-items: center; background: radial-gradient(circle,#5a1515,#100707); border: 1px solid rgba(205,139,67,.48); clip-path: polygon(50% 0,100% 50%,50% 100%,0 50%); color: #e4b86c; display: flex; font: 18px/1 "C9Serif",Georgia,serif; height: 46px; justify-content: center; width: 46px; }
.achievement-profile small { color: #756a5d; font: 600 8px/1.35 "C9Nav",Arial,sans-serif; letter-spacing: .1em; text-transform: uppercase; }
.achievement-profile strong { color: #e4d7c6; display: block; font: 24px/1.1 "C9Serif",Georgia,serif; margin-top: 5px; }
.achievement-profile p { color: #8d8377; font-size: 11px; margin: 5px 0 0; }
.achievement-profile-progress { display: grid; gap: 7px; text-align: right; }
.achievement-profile-progress > b { color: #d3a659; font: 24px/1 "C9Serif",Georgia,serif; }
.achievement-profile-progress > span { background: #020202; border: 1px solid rgba(201,150,75,.22); display: block; height: 9px; overflow: hidden; }
.achievement-profile-progress > span i { background: linear-gradient(90deg,#6d1215,#b92d26,#d8ad5f); box-shadow: 0 0 12px rgba(185,45,38,.35); display: block; height: 100%; min-width: 2px; }
.achievement-layout { align-items: start; display: grid; gap: 16px; grid-template-columns: repeat(2,minmax(0,1fr)); }
.achievement-leaderboard,.achievement-recent { display: grid; }
.achievement-rank-row,.achievement-recent-row { align-items: center; border-top: 1px solid rgba(201,150,75,.12); display: grid; gap: 15px; min-height: 68px; padding: 11px 22px; }
.achievement-rank-row { background: transparent; border: 0; border-top: 1px solid rgba(201,150,75,.12); color: inherit; cursor: pointer; grid-template-columns: 48px minmax(0,1fr) auto; text-align: left; width: 100%; }
.achievement-rank-row:hover { background: rgba(201,150,75,.045); }
.achievement-rank-row.is-podium > b { color: #edbd70; text-shadow: 0 0 12px rgba(211,157,69,.28); }
.achievement-rank-row > b { color: #c8934b; font: 400 22px/1 "C9Serif",Georgia,serif; }
.achievement-rank-row > span,.achievement-recent-row > div { display: grid; gap: 4px; }
.achievement-rank-row strong,.achievement-recent-row strong { color: #ded3c4; font: 400 17px/1.2 "C9Serif",Georgia,serif; }
.achievement-rank-row small,.achievement-recent-row p { color: #706860; font: 9px/1.4 "C9Nav",Arial,sans-serif; margin: 0; }
.achievement-rank-row em { color: #d0a45f; display: grid; font: normal 600 11px/1 "C9Nav",Arial,sans-serif; gap: 5px; text-align: right; }
.achievement-rank-row em small { font-size: 7px; }
.achievement-rank-row > span > i { background: #020202; border: 1px solid rgba(201,150,75,.16); display: block; height: 6px; margin-top: 3px; overflow: hidden; width: min(220px,100%); }
.achievement-rank-row > span > i u { background: linear-gradient(90deg,#711217,#c1392c,#d4a557); display: block; height: 100%; min-width: 2px; text-decoration: none; }
.achievement-recent-row { grid-template-columns: 40px minmax(0,1fr) auto; }
.achievement-recent-row > b { color: #77b47c; font: 600 11px/1 "C9Nav",Arial,sans-serif; }
.achievement-medal { align-items: center; border: 1px solid rgba(201,150,75,.35); color: #c7974d; display: flex; font: 11px/1 "C9Serif",Georgia,serif; height: 31px; justify-content: center; transform: rotate(45deg); width: 31px; }
.achievement-book-panel { margin-bottom: 70px; }
.achievement-book { display: grid; gap: 1px; grid-template-columns: repeat(2,minmax(0,1fr)); }
.achievement-group { background: rgba(3,5,8,.86); border: 1px solid rgba(201,150,75,.12); padding: 24px; }
.achievement-group h3 { align-items: center; color: #c6954f; display: flex; font: 600 10px/1 "C9Nav",Arial,sans-serif; justify-content: space-between; letter-spacing: .16em; margin: 0 0 18px; text-transform: uppercase; }
.achievement-group h3 small { color: #5d554c; font-size: 8px; }
.achievement-group > div { display: grid; gap: 8px; }
.achievement-card { align-items: center; background: rgba(10,10,11,.7); border: 1px solid rgba(201,150,75,.1); display: grid; gap: 13px; grid-template-columns: 48px 1fr; min-height: 70px; padding: 10px 13px; }
.achievement-card > span { align-items: center; background: radial-gradient(circle,#542015,#160a08); border: 1px solid #78422c; color: #efbd6e; display: flex; font: 600 11px/1 "C9Nav",Arial,sans-serif; height: 38px; justify-content: center; width: 38px; }
.achievement-card strong { color: #dcd1c2; font: 400 16px/1.2 "C9Serif",Georgia,serif; }
.achievement-card p { color: #6f675e; font-size: 11px; line-height: 1.45; margin: 4px 0 0; }
.achievement-card div > small { color: #554e47; display: block; font: 8px/1.4 "C9Nav",Arial,sans-serif; margin-top: 7px; }
.achievement-card.is-earned { background: linear-gradient(100deg,rgba(66,79,42,.2),rgba(10,10,11,.74)); border-color: rgba(142,173,91,.3); }
.achievement-card.is-earned > span { background: radial-gradient(circle,#415829,#101607); border-color: #75904b; color: #cde394; }
.achievement-card.is-earned strong { color: #edf1d4; }
.achievement-card.is-locked { filter: saturate(.5); opacity: .55; }

/* Trade */
.trade-filter-grid { grid-template-columns: minmax(220px,.6fr) minmax(360px,2fr) auto; }
.trade-page-grid { display: grid; grid-template-columns: minmax(0,1.55fr) minmax(340px,.72fr); gap: 18px; align-items: start; }
.trade-list { display: grid; gap: 13px; }
.trade-card { padding: 21px; }
.trade-card > header, .trade-card > footer { position: relative; z-index: 1; display: flex; align-items: start; justify-content: space-between; gap: 16px; }
.trade-card h2 { margin: 6px 0 0; font-size: 24px; }
.trade-card time { color: var(--dim); font: 10px Arial,sans-serif; }
.trade-card > p { position: relative; z-index: 1; color: var(--ash); line-height: 1.6; }
.trade-card > footer { margin-top: 16px; padding-top: 13px; border-top: 1px solid var(--line); color: var(--ash); font: 11px Arial,sans-serif; }
.trade-card > footer strong { color: var(--gold-bright); }
.trade-sides { position: relative; z-index: 1; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 14px; padding: 13px; border: 1px solid var(--line); background: #030507; }
.trade-sides small { display: block; margin-bottom: 8px; color: var(--dim); font: 9px Arial,sans-serif; letter-spacing: .16em; }
.trade-arrow { color: var(--blood-bright); font-size: 22px; }
.trade-item-row, .trade-owned-items { display: flex; flex-wrap: wrap; gap: 7px; }
.trade-item { display: grid; justify-items: center; gap: 4px; max-width: 90px; color: var(--ash); font: 9px Arial,sans-serif; text-align: center; }
.trade-item .item-tile { width: 64px; min-height: 64px; }
.trade-item.selectable { position: relative; padding: 5px; border: 1px solid transparent; }
.trade-item.selectable:has(input:checked) { border-color: var(--gold); background: rgba(181,144,72,.08); }
.trade-item.selectable > input { position: absolute; z-index: 2; top: 7px; left: 7px; accent-color: var(--blood-bright); }
.trade-owned-items { max-height: 330px; overflow: auto; padding: 10px; border: 1px solid var(--line); background: #020407; }
.trade-wants { display: flex; flex-wrap: wrap; gap: 6px; }
.trade-wants span { padding: 7px 9px; border: 1px solid var(--line); color: var(--bone); font: 11px Arial,sans-serif; }
.trade-cancel { position: relative; z-index: 1; margin-top: 12px; }

/* Clans, runners and lore */
.wide-search-form { display: grid; grid-template-columns: minmax(320px,1fr) auto; gap: 10px; }
.clan-card { min-height: 250px; display: flex; flex-direction: column; }
.clan-card .clan-tag { color: var(--gold-bright); font-size: 22px; letter-spacing: .12em; }
.clan-card footer { margin-top: auto; padding: 14px 0 0; border: 0; display: flex; align-items: center; justify-content: space-between; }
.clan-card footer span { color: var(--dim); }
.clan-roster { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 1px; padding: 1px; background: var(--line); }
.clan-member { min-height: 110px; padding: 16px; background: #05080d; }
.clan-member h3 { margin: 7px 0 4px; font-size: 19px; }
.clan-member p { margin: 0; color: var(--dim); font: 10px Arial,sans-serif; }
.lore-band { position: relative; display: grid; grid-template-columns: 150px minmax(0,1fr); gap: 28px; align-items: center; margin: 48px 0 10px; padding: 28px 30px; border: 1px solid var(--gold-line); background: radial-gradient(circle at 9% 50%,rgba(133,11,20,.24),transparent 17rem),linear-gradient(120deg,rgba(14,18,25,.97),rgba(3,5,8,.99)); box-shadow: var(--shadow); overflow: hidden; }
.lore-band::after { content: "CIRCLE OF NINE"; position: absolute; right: -16px; bottom: -17px; color: rgba(218,224,230,.025); font-size: 55px; letter-spacing: .16em; white-space: nowrap; }
.lore-band h2 { position: relative; margin: 8px 0 10px; font-size: 31px; }
.lore-band p { position: relative; max-width: 900px; margin: 0 0 12px; color: var(--ash); line-height: 1.7; }
.lore-sigil, .con-sigil-large { position: relative; display: grid; place-items: center; border: 1px solid rgba(201,163,87,.42); background: radial-gradient(circle,#4a080d 0,#13090d 37%,#070a0f 68%); clip-path: polygon(50% 0,86% 14%,100% 50%,86% 86%,50% 100%,14% 86%,0 50%,14% 14%); box-shadow: inset 0 0 25px rgba(218,40,46,.28),0 0 30px rgba(0,0,0,.7); }
.lore-sigil { width: 126px; height: 126px; }
.lore-sigil::before, .lore-sigil::after, .con-sigil-large::before, .con-sigil-large::after { content: ""; position: absolute; inset: 17px; border: 1px solid rgba(201,163,87,.32); transform: rotate(45deg); }
.lore-sigil::after, .con-sigil-large::after { inset: 29px; border-color: rgba(210,42,48,.52); transform: none; }
.lore-sigil span { position: absolute; top: 23px; color: var(--gold-bright); font: 9px Arial,sans-serif; letter-spacing: .22em; }
.lore-sigil strong { position: relative; z-index: 1; color: #d9c79e; font-size: 42px; }
.runner-records { display: grid; gap: 10px; }
.runner-quickstart { overflow: hidden; }
.runner-quickstart .panel-head { align-items: center; background: radial-gradient(circle at 86% 0,rgba(150,25,17,.21),transparent 25rem); }
.runner-quickstart .panel-head h2 { margin-top: 8px; }
.runner-command { border: 1px solid rgba(201,150,75,.32); color: var(--gold-bright); font-size: 17px; padding: 15px 20px; white-space: nowrap; }
.runner-steps { background: var(--line); display: grid; gap: 1px; grid-template-columns: repeat(3,minmax(0,1fr)); padding: 1px; }
.runner-steps article { align-items: start; background: linear-gradient(140deg,#090b0f,#040507); display: grid; gap: 15px; grid-template-columns: 42px 1fr; min-height: 132px; padding: 21px; }
.runner-steps article > span { color: rgba(201,150,75,.48); font: 30px/1 "C9Serif",Georgia,serif; }
.runner-steps strong { color: var(--bone); font: 18px/1.25 "C9Serif",Georgia,serif; }
.runner-steps p { color: var(--ash); line-height: 1.55; margin: 8px 0 0; }
.runner-rules { align-items: center; display: flex; flex-wrap: wrap; gap: 8px; padding: 16px 20px; }
.runner-rules span,.runner-policy span { border: 1px solid rgba(201,150,75,.17); color: #a49a8d; font: 9px/1 Arial,sans-serif; letter-spacing: .08em; padding: 7px 9px; text-transform: uppercase; }
.runner-rules a { color: var(--gold-bright); font-size: 11px; margin-left: auto; }
.runner-rules a + a { margin-left: 8px; }
.runner-category-list { display: grid; gap: 10px; }
.runner-category { border: 1px solid var(--line); display: grid; gap: 10px; padding: 15px; }
.runner-category small { color: var(--dim); font: 9px Arial,sans-serif; letter-spacing: .12em; text-transform: uppercase; }
.runner-category strong { color: var(--bone); display: block; font: 18px/1.25 "C9Serif",Georgia,serif; margin-top: 5px; }
.runner-category p { color: var(--ash); line-height: 1.55; margin: 0; }
.runner-policy { display: flex; flex-wrap: wrap; gap: 6px; }
.runner-leaderboard { border: 1px solid var(--line); background: #04070b; }
.runner-leaderboard > header { align-items: center; border-bottom: 1px solid var(--line); display: flex; gap: 15px; justify-content: space-between; padding: 15px; }
.runner-leaderboard h3 { color: var(--bone); font-size: 18px; margin: 5px 0 0; }
.runner-leaderboard > header > span { color: var(--gold-bright); font: 22px/1 "C9Serif",Georgia,serif; }
.runner-leaderboard > article { align-items: center; border-bottom: 1px solid rgba(201,150,75,.08); display: grid; gap: 10px; grid-template-columns: 30px minmax(90px,1fr) minmax(100px,.8fr) auto minmax(130px,1.2fr); padding: 11px 14px; }
.runner-leaderboard > article:last-child { border-bottom: 0; }
.runner-leaderboard > article > b { color: #6e645c; }
.runner-leaderboard > article > a { color: var(--bone); }
.runner-leaderboard > article > small { color: var(--dim); }
.runner-leaderboard > article > strong { color: var(--gold-bright); font-family: "C9Serif",Georgia,serif; }
.runner-empty-record { color: var(--dim); padding: 18px 15px; }
.runner-splits { display: flex; flex-wrap: wrap; gap: 5px; }
.runner-splits span { background: rgba(201,150,75,.05); border: 1px solid rgba(201,150,75,.14); color: #8e857b; font: 9px/1.25 Arial,sans-serif; padding: 5px 7px; white-space: nowrap; }
.runner-splits b { color: #baa36f; font-weight: normal; margin-left: 4px; }
.runner-status { border: 1px solid rgba(201,150,75,.18); color: var(--ash); display: inline-block; font: 9px/1 Arial,sans-serif; padding: 7px 8px; text-transform: uppercase; white-space: nowrap; }
.runner-status.status-finished { border-color: rgba(80,156,101,.34); color: #83b98a; }
.runner-status.status-running { border-color: rgba(213,161,73,.36); color: var(--gold-bright); }
.runner-status.status-invalidated { border-color: rgba(172,42,42,.42); color: #c97972; }
.runner-no-splits { color: var(--dim); }

@media (max-width: 840px) {
  .runner-steps { grid-template-columns: 1fr; }
  .runner-quickstart .panel-head { align-items: start; display: grid; gap: 18px; }
  .runner-command { justify-self: start; }
  .runner-leaderboard > article { grid-template-columns: 28px minmax(100px,1fr) auto; }
  .runner-leaderboard > article > small,.runner-leaderboard > article > .runner-splits { grid-column: 2 / -1; }
}

@media (max-width: 620px) {
  .runner-rules a { margin-left: 0; width: 100%; }
  .runner-rules a + a { margin-left: 0; }
}

/* Command center and reusable Diablo-style framing. The double line is kept
   on major groups only; repeating it on every tiny statistic makes the site
   feel like a spreadsheet rather than an in-game panel. */
.framed-panel {
  position: relative;
  border: 1px solid rgba(183,137,62,.24);
  background:
    linear-gradient(135deg,rgba(201,149,68,.12) 0 1px,transparent 1px) 0 0/14px 14px no-repeat,
    radial-gradient(circle at 88% 0,rgba(108,17,14,.12),transparent 26rem),
    rgba(5,5,6,.82);
  box-shadow: inset 0 0 0 3px rgba(0,0,0,.72),0 16px 42px rgba(0,0,0,.22);
}
.framed-panel::before,.framed-panel::after { content:""; position:absolute; pointer-events:none; width:11px; height:11px; border-color:rgba(196,146,63,.48); }
.framed-panel::before { inset:5px auto auto 5px; border-left:1px solid; border-top:1px solid; }
.framed-panel::after { inset:auto 5px 5px auto; border-right:1px solid; border-bottom:1px solid; }
.admin-command-center .page-main { max-width:1480px; }
.admin-command-center .shell { width:min(1480px,calc(100% - 44px)); }
.admin-hero { padding-top:46px; padding-bottom:38px; }
.admin-hero h1 { font-size:clamp(40px,5vw,74px); }
.admin-section-nav { position:sticky; top:82px; z-index:31; display:flex; gap:6px; margin:0 0 28px; padding:8px; overflow-x:auto; border:1px solid rgba(191,142,64,.18); background:rgba(3,3,4,.92); backdrop-filter:blur(14px); box-shadow:0 12px 28px rgba(0,0,0,.28); }
.admin-section-nav a { flex:0 0 auto; padding:10px 16px; color:#9d9284; font:600 10px/1 "C9Nav",Arial,sans-serif; letter-spacing:.09em; text-transform:uppercase; }
.admin-section-nav a:hover,.admin-section-nav a:focus-visible { color:#eee1ce; background:rgba(145,38,24,.16); }
.admin-session-bar { display:grid; grid-template-columns:auto 1fr auto; align-items:center; gap:20px; margin-bottom:52px; padding:14px 18px; }
.admin-session-bar > div:first-child { display:grid; grid-template-columns:auto auto; align-items:center; column-gap:9px; }
.admin-session-bar small { grid-column:2; color:#766d63; font-size:9px; letter-spacing:.12em; text-transform:uppercase; }
.status-dot { width:8px; height:8px; border-radius:50%; background:#5c5c5c; box-shadow:0 0 10px currentColor; }
.status-dot.online { color:#45c676; background:currentColor; }
.admin-inline-notice { color:#8f857a; font:11px/1.55 Arial,sans-serif; }
.admin-inline-notice.is-bad,.admin-error { color:#dc685d; }
.admin-section { scroll-margin-top:150px; margin:0 0 76px; }
.admin-section-heading { display:flex; justify-content:space-between; align-items:end; gap:24px; margin-bottom:22px; padding-bottom:17px; border-bottom:1px solid rgba(183,137,62,.16); }
.admin-section-heading h2 { margin:5px 0 0; font-size:clamp(28px,3vw,46px); }
.admin-section-heading p { max-width:750px; margin:7px 0 0; color:#82786e; font:12px/1.6 Arial,sans-serif; }
.admin-metric-grid { display:grid; grid-template-columns:repeat(6,minmax(0,1fr)); gap:10px; margin-bottom:16px; }
.admin-metric { min-height:98px; display:flex; flex-direction:column; justify-content:space-between; padding:17px; border:1px solid rgba(174,131,58,.17); background:linear-gradient(145deg,rgba(107,22,17,.09),rgba(3,3,4,.76)); }
.admin-metric span { color:#756c62; font:9px/1.35 "C9Nav",Arial,sans-serif; letter-spacing:.08em; text-transform:uppercase; }
.admin-metric strong { color:#e4d5bf; font:32px/1 Georgia,serif; }
.admin-two-column,.admin-season-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; }
.admin-card { padding:22px; min-width:0; }
.admin-card > header { display:flex; justify-content:space-between; align-items:flex-start; gap:15px; margin-bottom:18px; padding-bottom:14px; border-bottom:1px solid rgba(184,136,59,.13); }
.admin-card > header h3 { margin:0; color:#ded1bd; font-size:20px; }
.admin-card > header p { margin:5px 0 0; color:#7f766c; font:11px/1.55 Arial,sans-serif; }
.admin-span-full { grid-column:1/-1; }
.admin-quick-links { display:grid; gap:8px; }
.admin-quick-links a { display:flex; justify-content:space-between; align-items:center; padding:14px 15px; border:1px solid rgba(174,131,58,.14); color:#a99d8e; background:rgba(255,255,255,.012); }
.admin-quick-links a:hover { color:#f0deca; border-color:rgba(190,87,50,.45); }
.admin-readable-list { min-width:0; }
.admin-readable-row { display:flex; justify-content:space-between; align-items:center; gap:16px; padding:10px 0; border-bottom:1px solid rgba(255,255,255,.045); color:#7f766d; font:11px/1.45 Arial,sans-serif; }
.admin-readable-row:last-child { border-bottom:0; }
.admin-readable-row > strong { color:#cfc2af; font-weight:500; text-align:right; }
.admin-readable-nested { align-items:flex-start; }
.admin-readable-nested > div { max-width:72%; display:flex; flex-wrap:wrap; justify-content:flex-end; gap:5px; }
.admin-readable-nested .admin-readable-list { width:100%; }
.admin-chip { display:inline-flex; padding:5px 7px; border:1px solid rgba(151,117,61,.16); color:#958b7e; background:rgba(255,255,255,.018); }
.admin-badge { display:inline-flex; align-items:center; min-height:22px; padding:4px 8px; border:1px solid rgba(166,133,75,.2); color:#b4a793; font:600 9px/1 Arial,sans-serif; letter-spacing:.06em; text-transform:uppercase; }
.admin-badge.is-good { color:#65c986; border-color:rgba(62,181,103,.32); background:rgba(30,110,59,.08); }
.admin-badge.is-bad { color:#e27065; border-color:rgba(190,54,45,.34); background:rgba(118,18,15,.1); }
.admin-step { flex:0 0 34px; width:34px; height:34px; display:grid; place-items:center; border:1px solid rgba(192,143,63,.35); color:#c7994d; font:18px/1 Georgia,serif; transform:rotate(45deg); }
.admin-step + div { flex:1; }
.admin-step::first-letter { transform:rotate(-45deg); }
.admin-danger-card { border-color:rgba(166,53,38,.35); }
.admin-form-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; }
.admin-form-grid label,.admin-form-stack label { display:grid; gap:7px; color:#8d8277; font:9px/1.3 "C9Nav",Arial,sans-serif; letter-spacing:.08em; text-transform:uppercase; }
.admin-form-wide { grid-column:1/-1; }
.admin-form-stack { display:grid; gap:12px; margin-top:18px; }
.admin-form-inline { display:flex; gap:8px; margin-top:9px; }
.admin-form-inline .field { flex:1; }
.admin-safety { display:grid; gap:4px; padding:13px 14px; margin-bottom:11px; border-left:2px solid #a53a2f; color:#ae9f90; background:rgba(126,25,18,.08); }
.admin-safety.is-ready { border-color:#429d62; background:rgba(34,111,62,.07); }
.admin-safety strong { color:#d8cab6; }
.admin-safety span { font-size:10px; }
.admin-season-list { display:grid; gap:8px; }
.admin-season-row { display:flex; justify-content:space-between; align-items:center; gap:18px; padding:14px; border:1px solid rgba(165,125,58,.14); }
.admin-season-row > div:first-child { display:grid; grid-template-columns:auto auto; align-items:center; gap:6px 10px; }
.admin-season-row strong,.admin-season-row p { grid-column:1/-1; }
.admin-season-row p { margin:0; color:#766d64; font:10px Arial,sans-serif; }
.admin-service-row { padding:13px 0; border-bottom:1px solid rgba(255,255,255,.05); }
.admin-service-row:last-child { border:0; }
.admin-service-row > div { display:flex; align-items:center; justify-content:space-between; gap:12px; }
.admin-service-row p { margin:7px 0; color:#93887c; font:11px/1.5 Arial,sans-serif; }
.admin-service-row small { color:#70675f; }
.admin-service-row > button { margin-top:10px; }
.admin-card details { margin-top:17px; border-top:1px solid rgba(181,135,58,.13); padding-top:14px; }
.admin-card summary,.admin-details > summary { cursor:pointer; color:#aa9e8d; font:600 10px/1.3 "C9Nav",Arial,sans-serif; letter-spacing:.08em; text-transform:uppercase; }
.admin-card details[open] summary { margin-bottom:14px; }
.admin-data-table table { width:100%; border-collapse:collapse; font:11px/1.45 Arial,sans-serif; }
.admin-data-table th { padding:10px; color:#7f756b; text-align:left; font-size:9px; text-transform:uppercase; letter-spacing:.08em; border-bottom:1px solid rgba(180,134,59,.18); }
.admin-data-table td { max-width:380px; padding:11px 10px; color:#a89d8f; vertical-align:top; border-bottom:1px solid rgba(255,255,255,.045); overflow-wrap:anywhere; }
.admin-table-scroll { overflow:auto; }
.admin-timeline { display:grid; gap:0; margin-top:17px; }
.admin-timeline-entry { position:relative; display:grid; grid-template-columns:12px 1fr; gap:13px; padding:0 0 19px; }
.admin-timeline-entry i { width:9px; height:9px; margin-top:4px; border:1px solid #a07738; transform:rotate(45deg); }
.admin-timeline-entry i.good { border-color:#54b977; background:rgba(60,173,97,.25); }
.admin-timeline-entry i.bad { border-color:#d45247; background:rgba(166,41,32,.25); }
.admin-timeline-entry::before { content:""; position:absolute; left:4px; top:15px; bottom:0; width:1px; background:rgba(169,128,58,.15); }
.admin-timeline-entry:last-child::before { display:none; }
.admin-timeline-entry small { display:block; color:#6f665e; font:9px Arial,sans-serif; }
.admin-timeline-entry strong { display:block; margin:4px 0; color:#cfc2af; }
.admin-timeline-entry p { margin:0; color:#847a70; font:11px/1.5 Arial,sans-serif; }
.admin-timeline-entry details { margin-top:9px; }
.admin-diff { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; padding:10px 0; }
.admin-diff > div { padding:10px; border:1px solid rgba(155,116,51,.13); }
.admin-details { margin-bottom:10px; padding:17px 19px; }
.admin-details > summary { display:flex; align-items:center; justify-content:space-between; gap:14px; }
.admin-details[open] > summary { margin-bottom:18px; padding-bottom:14px; border-bottom:1px solid rgba(183,137,62,.13); }
.admin-empty { color:#70675f; font:italic 12px/1.6 Georgia,serif; }
.admin-error { font:11px/1.5 Arial,sans-serif; }

@media (max-width:1100px) {
  .admin-metric-grid { grid-template-columns:repeat(3,minmax(0,1fr)); }
  .admin-section-nav { top:72px; }
}
@media (max-width:780px) {
  .admin-command-center .shell { width:min(100% - 22px,1480px); }
  .admin-session-bar { grid-template-columns:1fr auto; }
  .admin-session-bar .admin-inline-notice { grid-column:1/-1; grid-row:2; }
  .admin-two-column,.admin-season-grid { grid-template-columns:1fr; }
  .admin-span-full { grid-column:auto; }
  .admin-metric-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .admin-section-heading { align-items:flex-start; }
  .admin-form-grid,.admin-diff { grid-template-columns:1fr; }
  .admin-form-wide { grid-column:auto; }
  .admin-season-row { align-items:flex-start; flex-direction:column; }
  .notification-control { grid-template-columns:1fr; }
}
@media (max-width:480px) {
  .admin-metric-grid { grid-template-columns:1fr 1fr; }
  .admin-card { padding:17px; }
  .admin-section-nav { top:63px; margin-inline:-11px; }
  .admin-readable-nested { display:block; }
  .admin-readable-nested > div { max-width:none; justify-content:flex-start; margin-top:7px; }
}

/* Content, breakpoints, about, download */
.changelog-entry { position: relative; padding: 23px 4px 26px; border-bottom: 1px solid var(--line); }
.changelog-entry:last-child { border-bottom: 0; }
.changelog-entry h3 { margin: 8px 0 10px; font-size: 23px; }
.changelog-entry time { color: var(--dim); font: 10px Arial,sans-serif; }
.breakpoint-toolbar { display: grid; grid-template-columns: minmax(190px,.6fr) minmax(150px,.35fr) minmax(300px,1fr); gap: 10px; }
.breakpoint-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 14px; }
.breakpoint-card { position: relative; padding: 20px; border: 1px solid var(--line); background: linear-gradient(145deg,rgba(17,21,28,.95),rgba(4,6,10,.98)); box-shadow: var(--shadow); }
.breakpoint-card h3 { margin: 9px 0 13px; font-size: 22px; }
.breakpoint-card p { color: var(--dim); line-height: 1.6; }
.bp-row { display: flex; flex-wrap: wrap; gap: 7px; }
.bp-pill { padding: 8px 9px; border: 1px solid var(--line); background: #030508; color: var(--gold-bright); font: 11px Arial,sans-serif; }
.bp-pill span { color: var(--ash); }
.bot-command-card { border-left: 2px solid var(--blood); }
.con-origin { display: grid; grid-template-columns: minmax(260px,.5fr) minmax(0,1.5fr); gap: 24px; align-items: center; }
.con-sigil-large { width: min(330px,80vw); height: min(330px,80vw); margin: auto; }
.con-sigil-large span { position: absolute; top: 55px; color: var(--gold); font: 12px Arial,sans-serif; letter-spacing: .3em; }
.con-sigil-large strong { position: relative; z-index: 1; color: #dac99c; font-size: 88px; text-shadow: 0 0 25px var(--blood-bright); }
.con-sigil-large small { position: absolute; bottom: 55px; color: var(--dim); font: 9px Arial,sans-serif; letter-spacing: .34em; }
.lore-copy p { color: var(--ash); font-size: 16px; line-height: 1.82; }
.lore-copy p:first-of-type::first-letter {
  float: left; margin: 4px 10px -6px 0; padding: 2px 4px 0;
  font-family: "C9DiabloUI", Georgia, serif; font-size: 64px; line-height: .8;
  color: var(--gold-bright); text-shadow: 0 0 22px rgba(217,130,47,.5);
}
.nine-principles { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 1px; background: var(--line); padding: 1px; }
.nine-principles div { min-height: 100px; display: flex; align-items: center; gap: 15px; padding: 16px; background: #05080d; }
.nine-principles b { color: var(--gold-bright); font-size: 28px; font-weight: 400; }
.nine-principles span { color: var(--ash); }
.download-layout { display: grid; grid-template-columns: minmax(0,1.2fr) minmax(360px,.8fr); gap: 18px; align-items: start; }
.download-steps { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 13px; }
.installer-placeholder { display: flex; align-items: center; gap: 18px; margin-top: 17px; padding: 20px; border: 1px dashed var(--line-strong); color: var(--dim); }
.installer-placeholder > span { width: 65px; height: 65px; display: grid; place-items: center; border: 1px solid var(--blood-line); color: var(--blood-bright); font: 13px Arial,sans-serif; }
.installer-placeholder strong { color: var(--bone); }
.installer-placeholder p { margin: 5px 0 0; line-height: 1.6; }
.release-card { display: grid; grid-template-columns: 1fr auto; gap: 12px; padding: 14px; border: 1px solid var(--line); background: #04070b; }
.release-actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 15px 0; }
.onboarding-section { margin: 64px 0 28px; }
.onboarding-section > .section-heading { display: flex; justify-content: space-between; gap: 28px; align-items: end; }
.onboarding-section > .section-heading h2 { margin: 10px 0 0; font-size: 34px; }
.onboarding-section > .section-heading > p { max-width: 520px; margin: 0; color: var(--ash); line-height: 1.65; }
.onboarding-roadmap { display: grid; gap: 1px; margin-top: 24px; padding: 1px; background: var(--line); }
.onboarding-step { display: grid; grid-template-columns: 70px minmax(0,1fr); gap: 20px; align-items: start; padding: 23px 26px; background: linear-gradient(110deg,#080b10,#040609); }
.onboarding-step > b { color: var(--gold-bright); font: 28px/1 "C9DiabloUI",Georgia,serif; }
.onboarding-step h3 { margin: 0 0 7px; font-size: 22px; }
.onboarding-step p { margin: 0; color: var(--ash); line-height: 1.68; }
.onboarding-step .text-link { display: inline-block; margin-top: 9px; }
.onboarding-legal { margin: 24px 0 70px; }
.command-surfaces { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 14px; margin-bottom: 18px; }
.command-surface { margin-bottom: 0; }
.command-surface h2 { margin: 10px 0; font-size: 28px; }
.command-surface p { color: var(--ash); line-height: 1.67; }
.command-guide-panel { margin-top: 18px; }
.command-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 1px; padding: 1px; background: var(--line); }
.command-grid article { min-height: 135px; padding: 18px; background: #04070b; }
.command-grid code { display: inline-block; color: var(--gold-bright); font-size: 13px; overflow-wrap: anywhere; }
.command-grid p { margin: 10px 0 0; color: var(--ash); line-height: 1.58; }
.compact-command-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }

/* Account/admin */
.auth-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 18px; }
.account-character { margin-bottom: 13px; padding: 18px; border: 1px solid var(--line); background: linear-gradient(145deg,rgba(14,18,24,.95),rgba(3,5,8,.98)); box-shadow: var(--shadow); }
.account-character-head { display: flex; justify-content: space-between; gap: 16px; align-items: start; }
.account-character h3 { margin: 6px 0; font-size: 23px; }
.account-character p { margin: 0; color: var(--dim); }
.status-badge { padding: 6px 8px; border: 1px solid var(--line); color: var(--dim); font: 9px Arial,sans-serif; letter-spacing: .1em; text-transform: uppercase; }
.status-badge.ok { color: #7eb684; border-color: rgba(91,157,98,.35); }
.playersForm { display: grid; grid-template-columns: minmax(180px,.7fr) minmax(160px,.5fr) auto; gap: 10px; align-items: end; margin-top: 16px; padding-top: 15px; border-top: 1px solid var(--line); }
.operation-box { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.operation-box summary { color: var(--gold-bright); cursor: pointer; font: 10px Arial,sans-serif; letter-spacing: .1em; text-transform: uppercase; }
.operation-box form { display: grid; grid-template-columns: 1.4fr 1fr auto; gap: 8px; margin-top: 12px; }
.stat-list { display: grid; gap: 9px; }
.stat { padding: 12px 14px; border: 1px solid var(--line); background: #04070b; }
.stat small { display: block; color: var(--dim); font: 9px Arial,sans-serif; letter-spacing: .12em; text-transform: uppercase; }
.stat strong { display: block; margin-top: 5px; }
.stat-grid-compact { grid-template-columns: repeat(3,1fr); }
.admin-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 16px; }
.admin-grid .panel { margin-bottom: 0; }
.admin-page .page-main { max-width: 1650px; }
.admin-page .shell { width: min(1650px,calc(100% - 36px)); }

/* Effects */
.toast-stack { position: fixed; z-index: 500; right: 18px; bottom: 18px; display: grid; gap: 9px; max-width: min(390px,calc(100vw - 36px)); }
.toast { padding: 15px 17px; border: 1px solid var(--gold-line); background: rgba(4,6,9,.97); box-shadow: var(--shadow); }
.toast strong { display: block; color: var(--gold-bright); }
.toast small { display: block; margin-top: 5px; color: var(--ash); line-height: 1.5; }
.rune-rain { position: fixed; z-index: 450; inset: 0; pointer-events: none; overflow: hidden; }
.falling-rune { position: absolute; top: -40px; color: rgba(205,166,88,.65); font-size: 24px; animation: rune-fall linear both; }
.portal-flash { position: fixed; z-index: 440; inset: 0; pointer-events: none; background: radial-gradient(ellipse at 50% 55%,transparent 0 7%,rgba(157,14,22,.65) 8%,transparent 24%); animation: portal 2.3s both; }
.screen-flicker { animation: flicker .7s both; }
.perfect-aura .sanctuary-backdrop { filter: saturate(.9) contrast(1.2) brightness(.68); }
@keyframes rune-fall { to { transform: translateY(calc(100vh + 90px)) rotate(560deg); opacity: 0; } }
@keyframes portal { 0%,100% { opacity:0 } 25%,70% { opacity:1 } }
@keyframes flicker { 0%,30%,60%,100% { filter:none } 15%,45%,80% { filter:brightness(.48) contrast(1.45) } }

/* Footer */
.site-footer { display: flex; justify-content: space-between; gap: 24px; margin-top: 58px; padding: 43px 0 58px; border-top: 1px solid rgba(164,178,194,.09); color: #545b65; font: 10px/1.65 Arial,sans-serif; }
.site-footer strong { color: #777e87; letter-spacing: .12em; text-transform: uppercase; }
.site-footer p { max-width: 810px; margin: 5px 0; }
.footer-links { display: flex; flex-wrap: wrap; align-content: start; justify-content: end; gap: 10px 16px; }
.footer-links a { color: #737a83; }

/* Responsive */
@media (max-width: 1280px) {
  .nav a, .nav-more summary { padding-inline: 7px; font-size: 9px; }
  .season-pill { display: none; }
  .grail-grid { grid-template-columns: repeat(4,minmax(0,1fr)); }
  .item-spotlight { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 1080px) {
  .topbar-inner { flex-wrap: wrap; padding: 10px 0; }
  .nav { order: 3; width: 100%; margin-left: 0; overflow-x: auto; }
  .header-tools { margin-left: auto; }
  .hero-home { grid-template-columns: 1fr .72fr; min-height: 590px; }
  .hero-art { min-height: 430px; }
  .armory-layout, .trade-page-grid, .download-layout { grid-template-columns: 1fr; }
  .content-grid, .news-grid, .trust-grid, .clan-grid, .breakpoint-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .news-card.featured { grid-column: auto; }
  .grail-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
  .clan-roster { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 840px) {
  .hero-home { grid-template-columns: 1fr; text-align: center; }
  .hero-home .rune-divider, .hero-home p { margin-inline: auto; }
  .hero-actions, .hero-oath { justify-content: center; }
  .hero-art { min-height: 460px; }
  .hero-art-frame { width: min(500px,92vw); }
  .status-grid, .character-stat-grid, .home-feature-grid, .grid-2, .auth-grid, .admin-grid, .grail-summary-grid, .con-origin { grid-template-columns: 1fr; }
  .command-surfaces, .command-grid { grid-template-columns: 1fr; }
  .status-card { min-height: 82px; }
  .armory-search-form { grid-template-columns: minmax(0,1fr) minmax(215px,.45fr); }
  .armory-submit { grid-column: 1 / -1; }
  .armory-track-field { width: 100%; }
  .grail-search-form { grid-template-columns: 1fr 1fr; }
  .grail-search-form .btn { grid-column: 1 / -1; }
  .track-builder { grid-template-columns: 1fr; }
  .ladder-toolbar, .breakpoint-toolbar { grid-template-columns: 1fr 1fr; }
  .ladder-toolbar .search, .breakpoint-toolbar input { grid-column: 1 / -1; }
  .trade-filter-grid { grid-template-columns: 1fr; }
  .trade-search-action { align-self: end; }
  .nine-principles { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .lore-band { grid-template-columns: 1fr; text-align: center; }
  .lore-sigil { margin: auto; }
}
@media (max-width: 620px) {
  .shell { width: min(100% - 18px,1420px); }
  .brand-copy span { display: none; }
  .brand-copy strong { font-size: 17px; }
  .brand-mark { width: 45px; height: 45px; }
  .header-tools { gap: 5px; }
  .nav a, .nav-more summary { padding: 10px 8px; font-size: 9px; }
  .hero, .compact-hero { padding-top: 48px; }
  .hero h1, .hero-home h1 { font-size: 43px; }
  .hero p, .hero-home p { font-size: 15px; }
  .hero-art { min-height: 380px; }
  .content-grid, .news-grid, .trust-grid, .clan-grid, .breakpoint-grid, .item-spotlight, .zone-row, .download-steps, .clan-roster, .nine-principles { grid-template-columns: 1fr; }
  .onboarding-section > .section-heading { display: block; }
  .onboarding-section > .section-heading > p { margin-top: 12px; }
  .onboarding-step { grid-template-columns: 48px minmax(0,1fr); padding: 19px; }
  .panel-head, .panel-body { padding: 17px; }
  .section-title { display: block; }
  .section-title .btn { margin-top: 14px; }
  .armory-search-form, .grail-search-form, .ladder-toolbar, .breakpoint-toolbar, .wide-search-form { grid-template-columns: 1fr; }
  .armory-submit, .grail-search-form .btn, .ladder-toolbar .search, .breakpoint-toolbar input { grid-column: auto; }
  .armory-track-field { justify-self: stretch; }
  .grail-grid { grid-template-columns: 1fr; }
  .grail-item { grid-template-columns: 62px 1fr; }
  .grail-rank-row { gap: 9px 12px; grid-template-columns: 38px minmax(0,1fr) 62px; padding: 12px 14px; }
  .grail-rank-row > b { grid-column: 1; grid-row: 1; }
  .grail-rank-player { grid-column: 2; grid-row: 1; }
  .grail-rank-row > em { grid-column: 3; grid-row: 1; }
  .grail-rank-progress { grid-column: 2 / -1; grid-row: 2; }
  .trade-sides { grid-template-columns: 1fr; }
  .trade-arrow { transform: rotate(90deg); text-align: center; }
  .trade-card > header, .trade-card > footer, .account-character-head, .site-footer { display: block; }
  .trade-card time { display: block; margin-top: 8px; }
  .toolbar { flex-direction: column; align-items: stretch; }
  .toolbar .search { flex-basis: auto; }
  .paperdoll { min-height: 520px; padding: 8px; }
  .equipment-grid { min-height: 350px; grid-template-rows: repeat(5,60px); gap: 5px; }
  .item-slot { min-width: 42px; min-height: 48px; }
  .item-tooltip { left: 8px !important; right: 8px !important; bottom: 8px !important; top: auto !important; min-width: 0; max-width: none; }
  .playersForm, .operation-box form { grid-template-columns: 1fr; }
  th, td { padding: 12px 9px; }
  .hide-mobile { display: none; }
  .source-strip { display: block; }
  .source-strip span { display: block; margin-top: 4px; }
  .footer-links { justify-content: start; margin-top: 17px; }
}

/* ========================================================================== 
   C9Realm 0.5.5 - Obsidian Lobby / Lord of Terror visual system
   ========================================================================== */
:root {
  --hell-black: #010102;
  --hell-ink: #050507;
  --hell-stone: #0b0b0e;
  --hell-stone-raised: #121216;
  --hell-rim: #343036;
  --hell-rim-bright: #595057;
  --hell-red: #7e090d;
  --hell-red-bright: #d22429;
  --hell-gold: #b49355;
  --hell-gold-bright: #e0c07d;
  /* The Horadric Archive: ambient mood is dying embers/candlelight, not
     fresh blood -- --hell-red stays reserved for real danger/death states
     (hardcore, rejected, errors) so red keeps meaning something specific. */
  --hell-ember: #b5651d;
  --hell-ember-bright: #e08a3c;
}

body {
  background:
    radial-gradient(circle at 50% 0, rgba(180, 90, 20, .2), transparent 31rem),
    radial-gradient(circle at 12% 37%, rgba(140, 70, 15, .1), transparent 30rem),
    linear-gradient(rgba(1, 1, 2, .92), rgba(1, 1, 2, .995)),
    url("/assets/black-stone.svg") center top / 360px repeat,
    var(--hell-black);
}
.sanctuary-backdrop {
  height: min(88vh, 940px);
  background-image:
    linear-gradient(to bottom, rgba(0,0,1,.12), rgba(1,1,2,.52) 52%, var(--hell-black) 96%),
    radial-gradient(ellipse at 50% 31%, transparent 0, rgba(0,0,1,.12) 25%, rgba(0,0,1,.82) 84%),
    url("/operator-assets/fan/portal-hero.webp"),
    url("/operator-assets/fan/portal-hero.png"),
    url("/assets/sanctuary-gate.svg");
  background-position: center, center, center 24%, center 24%, center 12%;
  background-size: cover, cover, cover, cover, cover;
  filter: saturate(.82) contrast(1.25) brightness(.52);
  opacity: .98;
}
.sanctuary-vignette {
  box-shadow: inset 0 0 250px 84px rgba(0,0,0,.96);
  background:
    linear-gradient(90deg, rgba(0,0,0,.9), transparent 23%, transparent 77%, rgba(0,0,0,.9)),
    linear-gradient(to bottom, transparent 42%, rgba(0,0,0,.62) 78%, rgba(0,0,0,.96));
}

/* Two-tier lobby header */
.obsidian-header.topbar {
  position: sticky;
  top: 0;
  z-index: 110;
  border: 0;
  background: transparent;
  box-shadow: 0 22px 55px rgba(0,0,0,.72);
  backdrop-filter: none;
}
.obsidian-header.topbar::after { display: none; }
.header-crown {
  position: relative;
  border-bottom: 1px solid rgba(137, 20, 25, .32);
  background:
    linear-gradient(180deg, rgba(7,7,10,.985), rgba(1,1,3,.97)),
    url("/assets/black-stone.svg") center / 330px repeat;
  box-shadow: inset 0 -1px rgba(203, 163, 88, .09);
}
.header-crown::before,
.header-crown::after {
  content: "";
  position: absolute;
  bottom: -1px;
  width: 28%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(192, 28, 34, .7));
}
.header-crown::before { left: 0; }
.header-crown::after { right: 0; transform: scaleX(-1); }
.topbar-inner { min-height: 66px; gap: 18px; }
.brand-mark { width: 44px; height: 44px; background: radial-gradient(circle at 50% 43%, #65080d 0, #190407 38%, #050507 72%); }
.brand-nine { font-size: 26px; }
.brand-copy strong { font-size: 19px; letter-spacing: .17em; }
.brand-copy span { color: #686169; font-size: 9px; letter-spacing: .18em; }
.header-tools { margin-left: auto; }
.header-shortcut {
  padding: 8px 9px;
  color: #857c78;
  font: 9px/1 Arial,sans-serif;
  letter-spacing: .14em;
  text-transform: uppercase;
  border-bottom: 1px solid transparent;
}
.header-shortcut:hover { color: var(--hell-gold-bright); border-bottom-color: var(--hell-red-bright); }
.language-switch,
.season-pill {
  border-color: rgba(113,106,111,.22);
  background: rgba(1,1,3,.76);
}

.realm-menu-shell {
  position: relative;
  z-index: 2;
  margin-top: -1px;
  padding: 0 24px 10px;
}
.realm-menu {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0,1fr) 92px minmax(0,1fr);
  align-items: stretch;
  width: min(1180px, 100%);
  min-height: 58px;
  margin: 0 auto;
  padding: 5px 8px;
  border: 1px solid #302b30;
  border-top-color: #4a4148;
  background:
    linear-gradient(180deg, rgba(31,27,31,.99), rgba(6,6,8,.995) 58%, rgba(2,2,3,.995)),
    url("/assets/black-stone.svg") center / 280px repeat;
  box-shadow:
    inset 0 1px rgba(255,255,255,.035),
    inset 0 -2px 9px rgba(0,0,0,.95),
    0 14px 34px rgba(0,0,0,.8);
  clip-path: polygon(14px 0, calc(100% - 14px) 0, 100% 13px, 100% calc(100% - 9px), calc(100% - 11px) 100%, 11px 100%, 0 calc(100% - 9px), 0 13px);
}
.realm-menu::before,
.realm-menu::after {
  content: "";
  position: absolute;
  top: 8px;
  bottom: 8px;
  width: 42px;
  pointer-events: none;
  opacity: .65;
}
.realm-menu::before { left: 8px; border-left: 1px solid rgba(199,161,84,.26); border-top: 1px solid rgba(199,161,84,.18); }
.realm-menu::after { right: 8px; border-right: 1px solid rgba(199,161,84,.26); border-bottom: 1px solid rgba(199,161,84,.18); }
.realm-menu-wing {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(4,minmax(0,1fr));
  align-items: stretch;
}
.realm-menu-wing > a,
.realm-menu-wing > .nav-more > summary {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 48px;
  padding: 10px 12px;
  border: 0;
  border-right: 1px solid rgba(108,100,106,.17);
  color: #a49a92;
  background:
    linear-gradient(180deg, rgba(31,28,31,.58), rgba(5,5,7,.28));
  font: 600 11px/1 "C9Nav", Arial, sans-serif;
  letter-spacing: .1em;
  text-align: center;
  text-transform: uppercase;
  text-shadow: 0 2px 4px #000;
  white-space: nowrap;
  transition: color .18s, background .18s, box-shadow .18s;
}
.realm-menu-right > a:first-child { border-left: 1px solid rgba(108,100,106,.17); }
.realm-menu-wing > a::after,
.realm-menu-wing > .nav-more > summary::before {
  content: "";
  position: absolute;
  left: 20%;
  right: 20%;
  bottom: 4px;
  height: 1px;
  opacity: 0;
  background: linear-gradient(90deg, transparent, var(--hell-ember-bright), transparent);
  box-shadow: 0 0 9px var(--hell-ember-bright);
  transition: opacity .18s;
}
.realm-menu-wing > a:hover,
.realm-menu-wing > a.active,
.realm-menu-wing > .nav-more[open] > summary {
  color: var(--hell-gold-bright);
  border-bottom: 0;
  background: radial-gradient(ellipse at 50% 100%, rgba(190,100,30,.28), transparent 68%), linear-gradient(180deg, rgba(45,38,41,.66), rgba(8,7,9,.45));
  box-shadow: inset 0 0 17px rgba(180,90,20,.12);
}
.realm-menu-wing > a:hover::after,
.realm-menu-wing > a.active::after,
.realm-menu-wing > .nav-more[open] > summary::before { opacity: 1; }
.realm-menu .nav-more { position: relative; min-width: 0; }
.realm-menu .nav-more summary { list-style: none; cursor: pointer; }
.realm-menu .nav-more summary::-webkit-details-marker { display: none; }
.realm-menu .nav-more summary::after { content: " ▾"; color: #62585c; }
.realm-menu .nav-menu {
  top: calc(100% + 9px);
  right: -5px;
  min-width: 245px;
  padding: 7px;
  border: 1px solid #423b40;
  background: rgba(3,3,5,.992);
  box-shadow: 0 28px 70px #000;
}
.realm-menu .nav-menu a {
  display: block;
  min-height: 0;
  padding: 13px 15px;
  border: 0;
  border-bottom: 1px solid rgba(104,96,101,.13);
  background: transparent;
  color: #9d948e;
  font: 10px/1.2 Arial,sans-serif;
  letter-spacing: .12em;
  text-align: left;
  text-transform: uppercase;
}
.realm-menu .nav-menu a:hover { color: var(--hell-gold-bright); background: rgba(180,90,20,.18); }

.realm-menu-gem-slot {
  position: relative;
  z-index: 5;
  display: grid;
  place-items: center;
  min-height: 48px;
  margin: -16px 4px -12px;
}
.gem-socket {
  position: absolute;
  width: 84px;
  height: 84px;
  border: 1px solid #493f45;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 45%, #181316 0 26%, #060608 52%, #010102 72%),
    conic-gradient(from 0deg, #201b1f, #09090b, #31272c, #08080a, #201b1f);
  box-shadow:
    inset 0 0 0 5px #070709,
    inset 0 0 22px #000,
    0 12px 26px rgba(0,0,0,.9),
    0 0 0 1px rgba(181,143,74,.11);
}
.gem-socket::before,
.gem-socket::after {
  content: "";
  position: absolute;
  inset: 8px;
  border: 1px solid rgba(189,150,79,.16);
  transform: rotate(45deg);
}
.gem-socket::after { inset: 18px; border-color: rgba(169,24,29,.29); transform: none; }
.menu-lobby-gem.lobby-gem {
  position: relative;
  z-index: 2;
  width: 54px;
  padding: 0;
  border: 0;
  background: transparent;
  filter: drop-shadow(0 8px 8px #000) drop-shadow(0 0 4px rgba(168,20,25,.28));
  transition: transform .11s, filter .2s;
}
.menu-lobby-gem.lobby-gem:hover { transform: translateY(-2px) scale(1.04); filter: drop-shadow(0 9px 8px #000) drop-shadow(0 0 12px rgba(210,36,41,.48)); }
.menu-lobby-gem.lobby-gem:active { transform: translateY(2px) scale(.96); }
.menu-lobby-gem.lobby-gem img { display: block; width: 100%; }
.menu-lobby-gem.lobby-gem.perfect { filter: drop-shadow(0 9px 8px #000) drop-shadow(0 0 17px rgba(255,65,65,.86)) saturate(1.35); }
.realm-gem-state.gem-state {
  position: absolute;
  top: calc(100% + 11px);
  left: 50%;
  width: 240px;
  margin: 0;
  padding: 9px 11px;
  transform: translate(-50%, -5px);
  opacity: 0;
  visibility: hidden;
  border: 1px solid #3b3438;
  background: rgba(2,2,3,.98);
  box-shadow: 0 15px 35px #000;
  color: #746b69;
  pointer-events: none;
  transition: opacity .15s, transform .15s, visibility .15s;
}
.realm-gem-state.gem-state strong { margin: 0 0 4px; color: var(--hell-gold-bright); font-size: 12px; }
.realm-menu-gem-slot:hover .realm-gem-state,
.realm-menu-gem-slot:focus-within .realm-gem-state { opacity: 1; visibility: visible; transform: translate(-50%, 0); }

/* Sanctuary hero: one coherent lobby scene instead of a generic two-column card */
.hero-home {
  position: relative;
  isolation: isolate;
  min-height: 620px;
  display: grid;
  grid-template-columns: minmax(0,1fr);
  place-items: center;
  gap: 0;
  margin: 0 calc((100vw - min(1420px, calc(100vw - 40px))) / -2);
  padding: 92px max(24px, calc((100vw - min(1420px, calc(100vw - 40px))) / 2)) 108px;
  overflow: hidden;
  text-align: center;
}
.hero-home::before {
  content: "";
  position: absolute;
  z-index: -3;
  inset: 0;
  background-image:
    linear-gradient(to top, #010102 0, rgba(1,1,2,.78) 22%, rgba(1,1,2,.2) 58%, rgba(1,1,2,.6) 100%),
    radial-gradient(ellipse at 50% 40%, transparent 0 19%, rgba(0,0,0,.28) 50%, rgba(0,0,0,.86) 100%),
    url("/operator-assets/fan/portal-hero.webp"),
    url("/operator-assets/fan/portal-hero.png"),
    url("/assets/sanctuary-gate.svg");
  background-position: center, center, center 32%, center 32%, center 24%;
  background-repeat: no-repeat;
  background-size: cover;
  filter: saturate(.84) contrast(1.24) brightness(.68);
}
.hero-home::after {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 24px max(18px, calc((100vw - 1360px) / 2));
  border: 1px solid rgba(184,143,73,.15);
  clip-path: polygon(20px 0, calc(100% - 20px) 0, 100% 20px, 100% calc(100% - 20px), calc(100% - 20px) 100%, 20px 100%, 0 calc(100% - 20px), 0 20px);
  box-shadow: inset 0 0 100px rgba(0,0,0,.55);
  pointer-events: none;
}
.hero-inner-frame {
  position: absolute;
  z-index: -1;
  inset: 33px max(27px, calc((100vw - 1340px) / 2));
  border: 1px solid rgba(135,128,126,.07);
  pointer-events: none;
}
.hero-copy { width: min(920px,100%); text-align: center; }
.hero-home h1 { margin: 12px 0 21px; font-size: clamp(57px,7.2vw,108px); line-height: .84; letter-spacing: .01em; }
.hero-home h1 span { margin-top: 24px; color: var(--hell-gold-bright); font-size: .23em; letter-spacing: .29em; }
.hero-home p { max-width: 760px; margin-inline: auto; color: #aaa29c; font-size: 18px; text-shadow: 0 3px 12px #000; }
.hero-home .hero-actions { justify-content: center; margin-top: 30px; }
.hero-home .rune-divider { margin-inline: auto; }
.hero-home .hero-oath { justify-content: center; color: #756c6b; }
.hero-crest {
  position: relative;
  width: 122px;
  height: 122px;
  display: grid;
  place-items: center;
  margin: 0 auto 25px;
  border: 1px solid rgba(194,153,77,.35);
  background: radial-gradient(circle, rgba(160,80,20,.84), rgba(30,15,5,.92) 42%, rgba(2,2,3,.92) 72%);
  clip-path: polygon(50% 0,86% 14%,100% 50%,86% 86%,50% 100%,14% 86%,0 50%,14% 14%);
  box-shadow: inset 0 0 31px rgba(210,120,40,.28), 0 18px 45px #000, 0 0 28px rgba(170,85,20,.28);
}
.hero-crest::before,
.hero-crest::after { content: ""; position: absolute; inset: 17px; border: 1px solid rgba(214,174,93,.27); transform: rotate(45deg); }
.hero-crest::after { inset: 32px; transform: none; border-color: rgba(211,35,41,.46); }
.hero-crest strong { position: relative; z-index: 2; color: #e1ce9f; font-size: 42px; text-shadow: 0 0 18px var(--hell-red-bright); }
.hero-crest span,
.hero-crest small { position: absolute; z-index: 2; left: 0; right: 0; color: #9c8253; font: 8px Arial,sans-serif; letter-spacing: .18em; text-transform: uppercase; }
.hero-crest span { top: 20px; }
.hero-crest small { bottom: 19px; }

.btn {
  border-color: #353137;
  background: linear-gradient(180deg,#1a181c,#070709 62%,#030304);
  color: #c6bdb4;
  box-shadow: inset 0 1px rgba(255,255,255,.025), inset 0 -6px 13px rgba(0,0,0,.6);
  clip-path: polygon(7px 0,calc(100% - 7px) 0,100% 7px,100% calc(100% - 7px),calc(100% - 7px) 100%,7px 100%,0 calc(100% - 7px),0 7px);
}
.btn:hover { border-color: #6c5653; color: #f0dcae; background: linear-gradient(180deg,#2a2225,#0b080a 66%,#040304); }
.btn-primary { border-color: #711117; background: linear-gradient(180deg,#86131a,#40070c 62%,#170205); color: #f0d0b4; box-shadow: inset 0 1px rgba(255,214,177,.09), inset 0 -10px 20px rgba(0,0,0,.55), 0 0 18px rgba(121,5,10,.18); }
.btn-primary:hover { border-color: #cb3237; background: linear-gradient(180deg,#a51c23,#53090f 62%,#1e0306); }

.home-page .realm-status-grid {
  position: relative;
  z-index: 4;
  grid-template-columns: repeat(3,minmax(0,1fr));
  gap: 0;
  width: min(1120px,calc(100% - 28px));
  margin: -42px auto 30px;
  padding: 7px;
  border: 1px solid #342f34;
  background: linear-gradient(180deg,#181519,#050507 55%,#020203);
  box-shadow: 0 20px 52px rgba(0,0,0,.86), inset 0 1px rgba(255,255,255,.025);
  clip-path: polygon(12px 0,calc(100% - 12px) 0,100% 12px,100% calc(100% - 12px),calc(100% - 12px) 100%,12px 100%,0 calc(100% - 12px),0 12px);
}
.home-page .realm-status-grid .status-card {
  min-height: 88px;
  border: 0;
  border-right: 1px solid rgba(105,95,101,.18);
  background: radial-gradient(circle at 20% 50%,rgba(170,85,20,.12),transparent 58%),linear-gradient(180deg,rgba(18,16,19,.75),rgba(3,3,5,.72));
  box-shadow: none;
}
.home-page .realm-status-grid .status-card:last-child { border-right: 0; }
.home-page .realm-status-grid .status-card::after { inset: 4px; }
.status-icon { border-color: rgba(169,139,81,.27); background: #050507; color: var(--hell-gold); }

.home-lore-band {
  grid-template-columns: 140px minmax(0,1fr) minmax(250px,.48fr);
  margin-top: 34px;
  border-color: rgba(173,135,68,.23);
  background:
    radial-gradient(circle at 8% 50%,rgba(180,90,20,.22),transparent 20rem),
    linear-gradient(115deg,rgba(13,12,15,.98),rgba(2,2,3,.995));
  clip-path: polygon(12px 0,calc(100% - 12px) 0,100% 12px,100% calc(100% - 12px),calc(100% - 12px) 100%,12px 100%,0 calc(100% - 12px),0 12px);
}
.realm-tenets { position: relative; display: grid; gap: 1px; border: 1px solid rgba(108,99,104,.18); background: rgba(108,99,104,.15); }
.realm-tenets span { display: flex; align-items: center; gap: 13px; min-height: 54px; padding: 11px 13px; background: rgba(3,3,5,.9); color: #8f8580; font: 10px/1.35 Arial,sans-serif; letter-spacing: .08em; text-transform: uppercase; }
.realm-tenets b { min-width: 24px; color: var(--hell-gold-bright); font: 18px Georgia,serif; }

.status-card,
.content-card,
.news-card,
.zone-card,
.trade-card,
.grail-progress-card {
  border-color: rgba(109,100,105,.2);
  background: rgba(255,255,255,.01);
}
.panel-head { border-bottom-color: rgba(108,99,104,.16); }
.section-title h2 { color: #ded7cf; }

/* Armory search proportions: character name dominates, track remains compact. */
.armory-search-form { grid-template-columns: minmax(520px,1fr) 260px 178px; }
.armory-track-field { width: 260px; max-width: 260px; justify-self: end; }
.armory-submit { width: 178px; }

@media (max-width: 1180px) {
  .header-shortcut { display: none; }
  .realm-menu { grid-template-columns: minmax(0,1fr) 82px minmax(0,1fr); }
  .realm-menu-wing > a,
  .realm-menu-wing > .nav-more > summary { padding-inline: 7px; font-size: 9px; letter-spacing: .1em; }
  .gem-socket { width: 76px; height: 76px; }
  .menu-lobby-gem.lobby-gem { width: 49px; }
  .home-lore-band { grid-template-columns: 120px minmax(0,1fr); }
  .home-lore-band .realm-tenets { grid-column: 1 / -1; grid-template-columns: repeat(3,minmax(0,1fr)); }
}

@media (max-width: 900px) {
  .topbar-inner { min-height: 60px; flex-wrap: nowrap; padding: 7px 0; }
  .season-pill { display: none; }
  .realm-menu-shell { width: 100%; padding-inline: 0; overflow-x: auto; scrollbar-width: thin; }
  .realm-menu { width: 900px; min-width: 900px; margin-inline: 8px; }
  .hero-home { min-height: 570px; margin-inline: -9px; padding-inline: 22px; }
  .hero-home::after { inset-inline: 15px; }
  .hero-inner-frame { inset-inline: 23px; }
  .home-page .realm-status-grid { grid-template-columns: 1fr; width: min(680px,calc(100% - 16px)); }
  .home-page .realm-status-grid .status-card { border-right: 0; border-bottom: 1px solid rgba(105,95,101,.18); }
  .home-page .realm-status-grid .status-card:last-child { border-bottom: 0; }
  .armory-search-form { grid-template-columns: minmax(0,1fr) 240px; }
  .armory-track-field { width: 240px; max-width: 240px; }
  .armory-submit { grid-column: 1 / -1; width: 100%; }
}

@media (max-width: 620px) {
  .brand-copy span { display: none; }
  .header-tools { gap: 4px; }
  .language-switch { padding: 7px; }
  .realm-menu { width: 780px; min-width: 780px; grid-template-columns: minmax(0,1fr) 74px minmax(0,1fr); }
  .realm-menu-wing > a,
  .realm-menu-wing > .nav-more > summary { min-height: 45px; font-size: 8px; }
  .realm-menu-gem-slot { margin-top: -11px; }
  .gem-socket { width: 68px; height: 68px; }
  .menu-lobby-gem.lobby-gem { width: 44px; }
  .hero-home { min-height: 530px; padding-top: 66px; padding-bottom: 88px; }
  .hero-home h1 { font-size: 48px; }
  .hero-home h1 span { font-size: .25em; letter-spacing: .22em; }
  .hero-home p { font-size: 15px; }
  .hero-crest { width: 100px; height: 100px; }
  .hero-crest strong { font-size: 34px; }
  .home-lore-band { grid-template-columns: 1fr; text-align: center; padding: 22px 18px; }
  .home-lore-band .lore-sigil { margin-inline: auto; }
  .home-lore-band .realm-tenets { grid-column: auto; grid-template-columns: 1fr; text-align: left; }
  .armory-search-form { grid-template-columns: 1fr; }
  .armory-track-field,
  .armory-submit { width: 100%; max-width: none; justify-self: stretch; grid-column: auto; }
}


/* Optional operator-supplied lobby gem crop. Missing local files naturally
   fall through to the bundled, original C9Realm SVG. */
.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0,0,0,0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}
.lobby-gem-art {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  background-image:
    url("/operator-assets/fan/lobby-gem.webp"),
    url("/operator-assets/fan/lobby-gem.png"),
    url("/assets/lobby-gem.svg");
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
}

/* ========================================================================== 
   C9Realm 0.5.8 - Sanctuary lobby, protected control plane and unclipped menu
   ========================================================================== */
.sanctuary-backdrop {
  background-image:
    linear-gradient(to bottom, rgba(0,0,1,.08), rgba(1,1,2,.6) 55%, var(--hell-black) 96%),
    radial-gradient(ellipse at 50% 24%, rgba(150,75,15,.16), rgba(0,0,0,.28) 36%, rgba(0,0,1,.9) 84%),
    url("/assets/sanctuary-gate.svg");
  background-position: center, center, center top;
  background-repeat: no-repeat;
  background-size: cover, cover, cover;
  filter: saturate(.72) contrast(1.24) brightness(.43);
}
.operator-hero-enabled .sanctuary-backdrop {
  background-image:
    linear-gradient(to bottom, rgba(0,0,1,.44), rgba(1,1,2,.78) 58%, var(--hell-black) 96%),
    radial-gradient(ellipse at 50% 28%, transparent, rgba(0,0,1,.74) 76%),
    url("/operator-assets/fan/portal-hero.webp"),
    url("/operator-assets/fan/portal-hero.png"),
    url("/assets/sanctuary-gate.svg");
  background-position: center, center, center 28%, center 28%, center top;
  background-size: cover, cover, min(1180px,88vw) auto, min(1180px,88vw) auto, cover;
}

.realm-menu-shell,
.realm-menu,
.realm-menu-wing,
.realm-menu .nav-more { overflow: visible; }
.realm-menu {
  clip-path: none;
  border-radius: 2px;
}
.realm-menu::before,
.realm-menu::after { z-index: 0; }
.realm-menu .nav-more { z-index: 40; }
.realm-menu .nav-menu {
  z-index: 150;
  display: none;
  visibility: hidden;
  opacity: 0;
  transform: translateY(-5px);
  transition: opacity .14s ease, transform .14s ease;
}
.realm-menu .nav-more[open] .nav-menu {
  display: block;
  visibility: visible;
  opacity: 1;
  transform: translateY(0);
}
.realm-menu .nav-menu::after {
  content: "";
  position: absolute;
  right: 25px;
  top: -6px;
  width: 10px;
  height: 10px;
  border-left: 1px solid #423b40;
  border-top: 1px solid #423b40;
  background: #050507;
  transform: rotate(45deg);
}

/* The front page behaves like a compact realm lobby instead of a marketing hero. */
.home-page .page-main { padding-top: 18px; }
.d2-lobby-frame {
  position: relative;
  display: grid;
  grid-template-columns: minmax(245px,.72fr) minmax(470px,1.55fr) minmax(245px,.72fr);
  min-height: 610px;
  border: 1px solid #332e32;
  border-top-color: #57494f;
  background:
    linear-gradient(90deg, rgba(2,2,3,.98), rgba(4,3,5,.78) 22%, rgba(4,3,5,.38) 50%, rgba(4,3,5,.78) 78%, rgba(2,2,3,.98)),
    url("/assets/sanctuary-gate.svg") center 22% / cover no-repeat,
    #030304;
  box-shadow: inset 0 0 0 5px #050507, inset 0 0 120px rgba(0,0,0,.86), 0 28px 90px #000;
  isolation: isolate;
}
.d2-lobby-frame::before,
.d2-lobby-frame::after {
  content: "";
  position: absolute;
  z-index: 5;
  pointer-events: none;
  inset: 11px;
  border: 1px solid rgba(161,128,70,.13);
}
.d2-lobby-frame::after {
  inset: 19px;
  border-color: rgba(107,96,101,.1);
  box-shadow: inset 0 0 80px rgba(0,0,0,.44);
}
.operator-hero-enabled .d2-lobby-frame {
  background:
    linear-gradient(90deg, rgba(2,2,3,.985), rgba(3,3,4,.82) 24%, rgba(2,2,3,.42) 50%, rgba(3,3,4,.82) 76%, rgba(2,2,3,.985)),
    linear-gradient(to bottom, rgba(0,0,0,.3), rgba(0,0,0,.76)),
    url("/operator-assets/fan/portal-hero.webp") center 32% / min(1050px,74vw) auto no-repeat,
    url("/operator-assets/fan/portal-hero.png") center 32% / min(1050px,74vw) auto no-repeat,
    url("/assets/sanctuary-gate.svg") center / cover no-repeat,
    #030304;
}
.d2-lobby-scene {
  position: relative;
  z-index: 3;
  display: flex;
  min-width: 0;
  padding: 82px 36px 64px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  text-align: center;
  background:
    radial-gradient(ellipse at 50% 46%, rgba(180,90,20,.18), transparent 31%),
    linear-gradient(90deg, rgba(0,0,0,.5), transparent 18%, transparent 82%, rgba(0,0,0,.5));
}
.lobby-arch {
  position: absolute;
  z-index: -1;
  inset: 34px 17px 24px;
  border: 1px solid rgba(139,111,63,.12);
  border-radius: 48% 48% 0 0 / 21% 21% 0 0;
  box-shadow: inset 0 0 80px rgba(0,0,0,.76), 0 0 50px rgba(0,0,0,.7);
}
.lobby-arch::before,
.lobby-arch::after {
  content: "";
  position: absolute;
  top: 15%;
  bottom: 4%;
  width: 24%;
  border: 1px solid rgba(115,98,75,.08);
  background: linear-gradient(90deg, rgba(0,0,0,.55), transparent);
}
.lobby-arch::before { left: 4%; }
.lobby-arch::after { right: 4%; transform: scaleX(-1); }
.lobby-realm-seal {
  width: 112px;
  height: 128px;
  display: grid;
  place-items: center;
  margin-bottom: 26px;
  color: #cfb77e;
  background: radial-gradient(circle at 50% 42%, #5a070c 0, #190306 37%, #030304 72%);
  border: 1px solid rgba(190,145,67,.36);
  clip-path: polygon(50% 0,88% 18%,100% 62%,76% 100%,24% 100%,0 62%,12% 18%);
  box-shadow: inset 0 0 34px rgba(210,30,36,.25), 0 20px 45px #000;
}
.lobby-realm-seal strong { font: 44px/1 Georgia,serif; text-shadow: 0 0 18px #a10c13; }
.lobby-realm-seal small,
.lobby-realm-seal span { position: absolute; font: 7px Arial,sans-serif; letter-spacing: .2em; text-transform: uppercase; color: #9d8352; }
.lobby-realm-seal small { margin-top: -73px; }
.lobby-realm-seal span { margin-top: 72px; }
.d2-lobby-scene h1 {
  margin: 9px 0 17px;
  color: #e1ddd5;
  font-size: clamp(42px,5vw,72px);
  line-height: .92;
  letter-spacing: .025em;
  text-shadow: 0 5px 22px #000, 0 0 34px rgba(190,95,20,.28);
}
.d2-lobby-scene h1 span { display: block; margin-top: 14px; color: var(--hell-gold-bright); font-size: .35em; letter-spacing: .28em; text-transform: uppercase; }
.d2-lobby-scene > p { max-width: 650px; margin: 0; color: #99918c; font-size: 16px; }
.lobby-command-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 9px; margin-top: 27px; }
.lobby-mode-strip { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 10px; margin-top: 33px; color: #746b68; font: 9px Arial,sans-serif; letter-spacing: .12em; text-transform: uppercase; }
.lobby-mode-strip i { width: 4px; height: 4px; border: 1px solid #85652e; transform: rotate(45deg); }
.d2-lobby-chronicle,
.d2-lobby-console {
  position: relative;
  z-index: 6;
  min-width: 0;
  margin: 34px 0;
  padding: 18px;
  border-top: 1px solid rgba(98,88,92,.23);
  border-bottom: 1px solid rgba(98,88,92,.23);
  background: linear-gradient(180deg, rgba(11,10,12,.94), rgba(2,2,3,.97));
  box-shadow: inset 0 0 40px rgba(0,0,0,.55);
}
.d2-lobby-chronicle { border-right: 1px solid rgba(103,92,97,.19); }
.d2-lobby-console { border-left: 1px solid rgba(103,92,97,.19); }
.lobby-panel-title {
  display: flex;
  min-height: 34px;
  margin-bottom: 11px;
  padding-bottom: 10px;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(125,111,116,.17);
  color: #c2aa72;
  font: 9px Arial,sans-serif;
  letter-spacing: .16em;
  text-transform: uppercase;
}
.lobby-panel-title a { color: #7f7772; }
.lobby-panel-title a:hover { color: var(--hell-gold-bright); }
.lobby-news-feed { display: grid; gap: 7px; }
.lobby-news-feed .news-card {
  min-height: 0;
  padding: 14px 12px;
  border-color: rgba(102,92,96,.15);
  background: rgba(2,2,3,.68);
  box-shadow: none;
}
.lobby-news-feed .news-card h3 { margin: 5px 0 7px; font-size: 15px; }
.lobby-news-feed .news-card p { margin: 0 0 7px; font-size: 12px; line-height: 1.55; }
.lobby-news-feed .news-card time { font-size: 9px; }
.lobby-realm-row { display: grid; grid-template-columns: 44px minmax(0,1fr); gap: 11px; padding: 15px 0; border-bottom: 1px solid rgba(109,99,103,.13); }
.realm-rune { width: 40px; height: 40px; display: grid; place-items: center; border: 1px solid rgba(170,134,69,.24); background: #040405; color: #b6904e; font: 19px Georgia,serif; }
.lobby-realm-row small,
.lobby-realm-row strong,
.lobby-realm-row em { display: block; }
.lobby-realm-row small { color: #a78a55; font: 9px Arial,sans-serif; letter-spacing: .13em; text-transform: uppercase; }
.lobby-realm-row strong { margin-top: 5px; color: #aaa19b; font-size: 12px; }
.lobby-realm-row em { margin-top: 5px; color: #625c5a; font: normal 9px Arial,sans-serif; }
.lobby-quick-links { margin-top: 14px; }
.lobby-quick-links a { display: flex; justify-content: space-between; padding: 10px 3px; border-bottom: 1px solid rgba(97,89,92,.12); color: #8c817b; font: 9px Arial,sans-serif; letter-spacing: .11em; text-transform: uppercase; }
.lobby-quick-links a:hover { color: #e0c07d; padding-left: 7px; }

/* Operator login is deliberately sparse: no dashboard names leak before auth. */
.admin-gate {
  width: min(520px,100%);
  margin: 76px auto 120px;
  padding: 42px 44px;
  border: 1px solid #3a3337;
  background: radial-gradient(circle at 50% 0, rgba(180,90,20,.19), transparent 18rem), linear-gradient(180deg,#111014,#030304);
  box-shadow: inset 0 0 0 5px #050507, inset 0 0 70px rgba(0,0,0,.68), 0 32px 90px #000;
  text-align: center;
}
.admin-gate-sigil { width: 76px; height: 76px; display: grid; place-items: center; margin: 0 auto 22px; border: 1px solid rgba(186,142,66,.35); background: radial-gradient(circle,#6c090e,#130306 46%,#020203 72%); clip-path: polygon(50% 0,90% 25%,90% 75%,50% 100%,10% 75%,10% 25%); color: #d6bd81; font: 28px Georgia,serif; }
.admin-gate h1 { margin: 10px 0 15px; font-size: 42px; }
.admin-gate > p { color: #8e8580; }
.admin-login-form { display: grid; gap: 14px; margin: 27px 0 19px; text-align: left; }
.admin-login-form label { color: #9c9188; font: 10px Arial,sans-serif; letter-spacing: .11em; text-transform: uppercase; }
.admin-login-form .field { width: 100%; margin-top: 7px; }
.admin-login-form .btn { width: 100%; margin-top: 3px; }
.btn-danger { border-color: #6d1419; color: #d7a6a4; }

@media (max-width: 1120px) {
  .d2-lobby-frame { grid-template-columns: minmax(220px,.72fr) minmax(430px,1.35fr); }
  .d2-lobby-console { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 0 20px; margin-top: 0; }
  .d2-lobby-console .lobby-panel-title,
  .d2-lobby-console .lobby-quick-links { grid-column: 1 / -1; }
  .d2-lobby-console .lobby-quick-links { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 8px; }
}
@media (max-width: 820px) {
  .d2-lobby-frame { grid-template-columns: 1fr; }
  .d2-lobby-scene { grid-row: 1; min-height: 500px; padding-inline: 22px; }
  .d2-lobby-chronicle { grid-row: 2; margin: 0; border-right: 0; }
  .d2-lobby-console { grid-row: 3; margin: 0; }
  .realm-menu-shell { overflow-y: visible; }
  .realm-menu .nav-menu { position: fixed; top: 118px; right: 12px; left: auto; }
}
@media (max-width: 560px) {
  .d2-lobby-console { grid-template-columns: 1fr; }
  .d2-lobby-console .lobby-quick-links { grid-template-columns: 1fr 1fr; }
  .d2-lobby-scene h1 { font-size: 42px; }
  .admin-gate { margin-top: 38px; padding: 31px 22px; }
}

/* Shared Pandemonium shell. The front page introduced this visual language;
   every native portal route now uses the same crown, navigation and footer. */
.shared-realm-header {
  align-items: center;
  background: linear-gradient(180deg, rgba(5,5,5,.98), rgba(5,5,5,.88));
  border-bottom: 1px solid rgba(201,150,75,.18);
  box-shadow: 0 18px 48px rgba(0,0,0,.48);
  display: grid;
  grid-template-columns: minmax(225px,1fr) auto minmax(280px,1fr);
  height: 88px;
  inset: 0 0 auto;
  padding: 0 clamp(22px,4.5vw,76px);
  position: sticky;
  top: 0;
  z-index: 120;
}
.home-page .shared-realm-header { position: fixed; }
.shared-realm-header::after {
  background: linear-gradient(90deg,transparent,#e25220,transparent);
  bottom: -1px;
  content: "";
  height: 1px;
  left: 14%;
  opacity: .62;
  position: absolute;
  width: 72%;
}
.landing-brand { align-items: center; display: inline-flex; gap: 14px; grid-column: 1; justify-self: start; }
.landing-brand-mark {
  align-items: center;
  background: radial-gradient(circle at 50% 40%,#8a2d17 0,#35100b 45%,#100807 75%);
  border: 1px solid rgba(220,126,61,.65);
  clip-path: polygon(50% 0,88% 22%,96% 69%,50% 100%,4% 69%,12% 22%);
  color: #f4c26e;
  display: flex;
  font: 17px/1 "C9Serif",Georgia,serif;
  height: 50px;
  justify-content: center;
  text-shadow: 0 0 12px #f04416;
  width: 44px;
}
.landing-brand-copy { display: grid; gap: 5px; }
.landing-brand-copy strong { color: #ded2c2; font: 500 14px/1 "C9Serif",Georgia,serif; letter-spacing: .25em; }
.landing-brand-copy small { color: #81796d; font: 600 8px/1 "C9Nav",Arial,sans-serif; letter-spacing: .26em; }
.shared-realm-header .landing-nav.realm-menu {
  align-items: stretch;
  background: transparent;
  border: 0;
  box-shadow: none;
  display: grid;
  gap: 0;
  grid-template-columns: 340px 160px 340px;
  height: 88px;
  left: 50%;
  margin: 0;
  min-height: 0;
  padding: 0;
  position: absolute;
  transform: translateX(-50%);
  width: 840px;
}
.shared-realm-header .landing-nav.realm-menu::before,
.shared-realm-header .landing-nav.realm-menu::after { content: none; }
.shared-realm-header .realm-menu-wing > a,
.shared-realm-header .landing-nav-more > summary {
  align-items: center;
  background: transparent;
  border: 0;
  color: #a69e93;
  display: flex;
  font: 600 10px/1 "C9Nav",Arial,sans-serif;
  height: 88px;
  letter-spacing: .15em;
  padding: 0 17px;
  position: relative;
  text-transform: uppercase;
  transition: color .25s ease;
}
.shared-realm-header .realm-menu-wing > a:hover,
.shared-realm-header .realm-menu-wing > a.active,
.shared-realm-header .landing-nav-more[open] > summary { background: transparent; border: 0; color: #eee4d5; }
.shared-realm-header .realm-menu-wing > a.active::after {
  background: #e25220;
  bottom: 0;
  box-shadow: 0 0 12px #e25220;
  content: "";
  height: 2px;
  left: 17px;
  position: absolute;
  right: 17px;
}
.landing-nav-more { position: relative; }
.landing-nav-more > summary { cursor: pointer; list-style: none; }
.landing-nav-more > summary::-webkit-details-marker { display: none; }
.landing-nav-more > summary::after { color: #7b6b56; content: "  ▾"; margin-left: 6px; }
.shared-realm-header .landing-nav-more .nav-menu { top: 72px; right: 0; }
.shared-realm-header .landing-nav-more .nav-menu a { color: #a69e93; height: auto; padding: 13px 15px; }
.shared-realm-header .landing-nav-more .nav-menu a:hover { color: #d6ad6e; }
.shared-realm-header .landing-header-actions { align-items: center; display: flex; gap: 13px; grid-column: 3; justify-self: end; min-width: 0; }
.shared-realm-header .landing-realm-status { align-items: center; color: #9e988e; display: flex; font: 600 8px/1 "C9Nav",Arial,sans-serif; gap: 8px; letter-spacing: .13em; max-width: 175px; text-transform: uppercase; }
.shared-realm-header .landing-realm-status strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.shared-realm-header .landing-realm-status i { background: #6fd78d; border-radius: 50%; box-shadow: 0 0 10px #6fd78d; flex: none; height: 6px; width: 6px; }
.shared-realm-header .landing-language { align-items: center; color: #676158; display: flex; font: 600 8px/1 "C9Nav",Arial,sans-serif; gap: 5px; }
.shared-realm-header .landing-language a { color: #676158; }
.shared-realm-header .landing-language a.active,
.shared-realm-header .landing-language a:hover { color: #c9964b; }
.shared-realm-header .landing-header-download { border: 1px solid rgba(201,150,75,.36); color: #d8c5aa; font: 600 9px/1 "C9Nav",Arial,sans-serif; letter-spacing: .18em; padding: 12px 16px; text-transform: uppercase; transition: .25s ease; white-space: nowrap; }
.shared-realm-header .landing-header-download:hover { background: rgba(201,150,75,.1); border-color: #c9964b; color: #fff; }
.shared-realm-header .landing-header-discord {
  align-items: center;
  background: linear-gradient(135deg,rgba(76,83,153,.12),rgba(9,8,13,.28));
  border: 1px solid rgba(126,134,211,.28);
  color: #b8b9d8;
  display: inline-flex;
  font: 600 8px/1 "C9Nav",Arial,sans-serif;
  gap: 7px;
  letter-spacing: .12em;
  padding: 10px 11px;
  text-transform: uppercase;
  transition: background .25s,border-color .25s,color .25s;
  white-space: nowrap;
}
.shared-realm-header .landing-header-discord span { color: #858cd6; font-size: 12px; }
.shared-realm-header .landing-header-discord:hover { background: rgba(88,96,180,.2); border-color: rgba(148,155,235,.58); color: #eeeefa; }
.header-account{position:relative;z-index:150}
.header-account-toggle{position:relative;display:flex;align-items:center;gap:8px;min-height:40px;padding:5px 9px 5px 6px;border:1px solid rgba(201,150,75,.22);background:linear-gradient(135deg,rgba(42,22,15,.38),rgba(6,6,7,.7));color:#bfb2a1;cursor:pointer;text-align:left;transition:border-color .2s,background .2s}
.header-account-toggle:hover,.header-account.is-open .header-account-toggle{border-color:rgba(210,151,67,.55);background:linear-gradient(135deg,rgba(85,35,22,.38),rgba(8,7,7,.88))}
.header-account-toggle>span:nth-child(2){display:grid;gap:3px;min-width:0}
.header-account-toggle small{color:#6f675e;font:600 6px/1 "C9Nav",Arial,sans-serif;letter-spacing:.15em}
.header-account-toggle b{display:block;max-width:86px;overflow:hidden;color:#d6c8b6;font:600 8px/1 "C9Nav",Arial,sans-serif;letter-spacing:.08em;text-overflow:ellipsis;white-space:nowrap}
.header-account-avatar{position:relative;display:grid;place-items:center;width:28px;height:28px;flex:none;border:1px solid rgba(201,150,75,.28);border-radius:50%;background:radial-gradient(circle at 50% 35%,rgba(178,74,39,.28),rgba(8,7,7,.9))}
.header-account-avatar::before{content:"";width:7px;height:7px;margin-top:-6px;border:1px solid #b69b78;border-radius:50%}
.header-account-avatar::after{content:"";position:absolute;bottom:5px;width:13px;height:7px;border:1px solid #b69b78;border-bottom:0;border-radius:9px 9px 0 0}
.header-account-presence{position:absolute;right:-4px;top:-4px;width:7px;height:7px;border:2px solid #090808;border-radius:50%;background:#665f57}
.header-account-presence.is-online{background:#68ca7d;box-shadow:0 0 8px rgba(104,202,125,.8)}
.header-account-panel{position:absolute;right:0;top:calc(100% + 15px);width:min(390px,calc(100vw - 28px));max-height:calc(100vh - 112px);overflow:auto;border:1px solid rgba(201,150,75,.31);background:radial-gradient(circle at 84% 0,rgba(116,34,22,.16),transparent 35%),rgba(5,5,6,.985);box-shadow:0 26px 70px rgba(0,0,0,.82),inset 0 0 0 3px rgba(201,150,75,.025);color:#a99f93}
.header-account-panel::before,.header-account-panel::after{content:"";position:sticky;z-index:2;display:block;pointer-events:none}
.header-account-panel::before{top:0;height:5px;border-top:1px solid rgba(226,82,32,.46);background:linear-gradient(90deg,transparent,rgba(226,82,32,.55),transparent)}
.header-account-panel>div:not(.header-account-notice){padding:21px}
.header-account-panel header>span,.header-member-head>div>span{color:#b37046;font:600 7px/1 "C9Nav",Arial,sans-serif;letter-spacing:.17em}
.header-account-panel header>strong,.header-member-head strong{display:block;margin-top:7px;color:#ded1bf;font:24px/1.1 "C9Serif",Georgia,serif}
.header-account-panel header p{margin:7px 0 0;color:#756e66;font:10px/1.55 Arial,sans-serif}
.header-account-notice{margin:10px 15px 0;padding:9px 11px;border:1px solid rgba(81,145,92,.22);background:rgba(43,96,54,.09);color:#83b88c;font-size:10px}
.header-account-notice.is-bad{border-color:rgba(176,66,45,.35);background:rgba(116,31,20,.13);color:#cf806d}
.header-login-form{display:grid;gap:11px;margin-top:18px}
.header-login-form label,.header-quick-settings>label:first-child{display:grid;gap:6px;color:#81786e;font:600 7px/1 "C9Nav",Arial,sans-serif;letter-spacing:.12em;text-transform:uppercase}
.header-login-form .field,.header-quick-settings .field{min-height:38px;padding:9px 11px}
.header-account-links{display:flex;justify-content:space-between;gap:14px;margin-top:13px;padding-top:12px;border-top:1px solid rgba(201,150,75,.12)}
.header-account-links a{color:#987b55;font:8px/1.35 "C9Nav",Arial,sans-serif;letter-spacing:.07em;text-transform:uppercase}
.header-account-links a:hover{color:#d2aa70}
.header-member-head{display:grid;grid-template-columns:52px minmax(0,1fr);gap:14px;align-items:center}
.header-member-sigil{display:grid;place-items:center;width:50px;height:50px;border:1px solid rgba(201,150,75,.31);clip-path:polygon(50% 0,100% 50%,50% 100%,0 50%);color:#e1bd79;font:22px/1 "C9Serif",Georgia,serif;background:radial-gradient(circle,rgba(137,42,24,.25),rgba(5,5,6,.9))}
.header-member-head strong{font-size:21px}
.header-account-shortcuts{display:grid;grid-template-columns:1fr 1fr;gap:1px;margin:18px 0;background:rgba(201,150,75,.13);border:1px solid rgba(201,150,75,.13)}
.header-account-shortcuts a{display:flex;align-items:center;justify-content:center;gap:7px;min-height:42px;background:#080707;color:#a99170;font:600 8px/1 "C9Nav",Arial,sans-serif;letter-spacing:.09em;text-transform:uppercase}
.header-account-shortcuts a:hover{background:#120b08;color:#e0c08c}
.header-account-shortcuts span{display:grid;place-items:center;min-width:18px;height:18px;padding:0 4px;border-radius:9px;background:#211713;color:#a58d70;font:700 8px Arial,sans-serif}
.header-account-shortcuts span.has-unread{background:#9e3a27;color:#f8ded5;box-shadow:0 0 9px rgba(158,58,39,.45)}
.header-friends{padding:14px 0;border-block:1px solid rgba(201,150,75,.12)}
.header-friends>div:first-child{display:flex;align-items:baseline;justify-content:space-between;gap:12px;margin-bottom:10px}
.header-friends>div:first-child strong{color:#c9b9a3;font:600 9px/1 "C9Nav",Arial,sans-serif;letter-spacing:.09em;text-transform:uppercase}
.header-friends>div:first-child small{color:#6e675f;font-size:8px}
.header-friend-list{display:grid;max-height:205px;overflow:auto}
.header-friend{display:grid;grid-template-columns:auto minmax(0,1fr);gap:9px;align-items:center;padding:8px;border-bottom:1px solid rgba(201,150,75,.08)}
.header-friend:hover{background:rgba(201,150,75,.045)}
.header-friend>i{width:7px;height:7px;border-radius:50%;background:#514b46}
.header-friend.is-online>i{background:#67c87b;box-shadow:0 0 8px rgba(103,200,123,.6)}
.header-friend strong{display:block;color:#bfb2a2;font-size:10px}
.header-friend small{display:block;margin-top:3px;color:#716a62;font-size:8px}
.header-friends-empty{margin:0;padding:12px;color:#6f675e;font:italic 11px/1.5 Georgia,serif;text-align:center}
.header-quick-settings{display:grid;gap:10px;padding-top:15px}
.header-quick-settings .check-row{margin:0;color:#8f867c;font-size:9px}
.header-quick-settings .btn{width:100%}
.header-logout{width:100%;margin-top:12px;padding:10px;border:0;border-top:1px solid rgba(201,150,75,.1);background:transparent;color:#765e52;cursor:pointer;font:600 7px/1 "C9Nav",Arial,sans-serif;letter-spacing:.13em;text-transform:uppercase}
.header-logout:hover{color:#c56b55}
.shared-realm-header .landing-menu-gem.realm-menu-gem-slot {
  align-self: center;
  display: grid;
  margin: 0 8px;
  min-height: 64px;
  place-items: center;
  width: 54px;
}
.shared-realm-header > .landing-menu-gem.realm-menu-gem-slot {
  left: 50%;
  margin: 0;
  position: absolute;
  top: 12px;
  transform: translateX(-50%);
}
.shared-realm-header .realm-menu-gem-spacer {
  display: block;
  grid-column: 2;
  width: 160px;
}
.shared-realm-header .realm-menu-wing { align-items: stretch; display: flex; min-width: 0; }
.shared-realm-header .realm-menu-wing-left { grid-column: 1; justify-content: flex-end; }
.shared-realm-header .realm-menu-wing-right { grid-column: 3; justify-content: flex-start; }
.shared-realm-header .landing-menu-gem.realm-menu-gem-slot::before {
  border: 1px solid rgba(201,150,75,.2);
  border-radius: 50%;
  box-shadow: inset 0 0 16px #000,0 0 18px rgba(170,35,20,.12);
  content: "";
  height: 47px;
  position: absolute;
  transform: rotate(45deg);
  width: 47px;
}
.shared-realm-header .landing-menu-gem .menu-lobby-gem.lobby-gem { width: 38px; }
.shared-realm-header .landing-menu-gem .realm-gem-state { top: calc(100% + 28px); }
.landing-mobile-menu { display: none; }

body:not(.home-page) {
  --bone: #d9cec0;
  --bone-bright: #f0e5d6;
  --ash: #9b9185;
  --dim: #6f685f;
  --line: rgba(201,150,75,.14);
  --line-strong: rgba(201,150,75,.26);
  --gold-line: rgba(201,150,75,.28);
  background: #060606;
}
body:not(.home-page)::before { display: none; }
body:not(.home-page)::after { color: transparent; -webkit-text-stroke-color: rgba(201,150,75,.025); }
body:not(.home-page) .sanctuary-backdrop {
  background-image:
    linear-gradient(180deg,rgba(5,5,5,.18),rgba(6,6,6,.86) 66%,#060606 100%),
    linear-gradient(90deg,rgba(5,5,5,.74),rgba(5,5,5,.15) 35%,rgba(5,5,5,.24) 68%,rgba(5,5,5,.78)),
    url("/assets/pandemonium-fortress.png");
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  filter: saturate(.68) contrast(1.14) brightness(.5);
  height: min(78vh,780px);
  opacity: .72;
}
body:not(.home-page) .sanctuary-vignette { background: linear-gradient(90deg,rgba(0,0,0,.72),transparent 24%,transparent 76%,rgba(0,0,0,.72)); box-shadow: inset 0 0 180px 50px rgba(0,0,0,.86); }
body:not(.home-page) .page-main { width: min(1220px,calc(100% - 48px)); }
body:not(.home-page) .hero { min-height: 390px; padding: 86px 0 58px; position: relative; }
body:not(.home-page) .hero h1 { color: #eee4d5; font-size: clamp(48px,6.4vw,84px); letter-spacing: .035em; }
body:not(.home-page) .hero p { color: #b1a69a; }
body:not(.home-page) .eyebrow,
body:not(.home-page) .kicker { color: #dc713a; }
body:not(.home-page) .panel-head { border-color: rgba(201,150,75,.18); }
body:not(.home-page):not(.admin-page):not(.admin-login-page) .hero::before {
  border: 1px solid rgba(201,150,75,.15);
  box-shadow: inset 0 0 70px rgba(63,24,13,.1);
  content: "";
  inset: 28px 0 20px;
  pointer-events: none;
  position: absolute;
}
body:not(.home-page):not(.admin-page):not(.admin-login-page) .panel {
  background: linear-gradient(145deg,rgba(25,14,10,.34),rgba(5,5,5,.5));
  border: 1px solid rgba(201,150,75,.16);
  box-shadow: inset 0 0 55px rgba(0,0,0,.22),0 18px 50px rgba(0,0,0,.16);
  padding: 22px;
}
body:not(.home-page):not(.admin-page):not(.admin-login-page).character-page .panel { padding: 0; }
body:not(.home-page) .status-card,
body:not(.home-page) .content-card,
body:not(.home-page) .news-card,
body:not(.home-page) .zone-card,
body:not(.home-page) .trade-card,
body:not(.home-page) .grail-progress-card { background: linear-gradient(145deg,rgba(30,17,12,.42),rgba(7,7,7,.72)); border-color: rgba(201,150,75,.18); }
body:not(.home-page) .btn-primary { background: linear-gradient(180deg,#a5351c,#68170f); border-color: #d3572e; color: #fff2df; }
body:not(.home-page) .btn-primary:hover { background: linear-gradient(180deg,#bb4323,#7b1d12); border-color: #ef7543; }

/* A single reusable corner ornament keeps the homepage, public subpages
   and Discord banner visually related without obscuring their content. */
.realm-frame { position: relative; }
.realm-frame::after,
body:not(.home-page):not(.admin-page):not(.admin-login-page) .panel::after,
body:not(.home-page) .status-card::after,
body:not(.home-page) .content-card::after,
body:not(.home-page) .news-card::after,
body:not(.home-page) .zone-card::after,
body:not(.home-page) .trade-card::after,
body:not(.home-page) .grail-progress-card::after {
  background:
    linear-gradient(90deg,rgba(222,170,82,.72) 0 12px,transparent 12px) left top/28px 1px no-repeat,
    linear-gradient(180deg,rgba(222,170,82,.72) 0 12px,transparent 12px) left top/1px 28px no-repeat,
    linear-gradient(270deg,rgba(222,170,82,.72) 0 12px,transparent 12px) right top/28px 1px no-repeat,
    linear-gradient(180deg,rgba(222,170,82,.72) 0 12px,transparent 12px) right top/1px 28px no-repeat,
    linear-gradient(90deg,rgba(222,170,82,.52) 0 12px,transparent 12px) left bottom/28px 1px no-repeat,
    linear-gradient(0deg,rgba(222,170,82,.52) 0 12px,transparent 12px) left bottom/1px 28px no-repeat,
    linear-gradient(270deg,rgba(222,170,82,.52) 0 12px,transparent 12px) right bottom/28px 1px no-repeat,
    linear-gradient(0deg,rgba(222,170,82,.52) 0 12px,transparent 12px) right bottom/1px 28px no-repeat;
  content: "";
  inset: 5px;
  pointer-events: none;
  position: absolute;
  z-index: 5;
}

.home-page .landing-button-discord {
  background: linear-gradient(180deg,rgba(74,79,148,.48),rgba(31,31,66,.58));
  border: 1px solid rgba(139,146,222,.48);
  color: #e2e2f5;
}
.home-page .landing-button-discord:hover { background: linear-gradient(180deg,rgba(91,98,183,.6),rgba(42,42,86,.68)); border-color: #9399e0; }
.home-page .landing-button-discord b { color: #adb1ea; font-size: 14px; margin-left: 12px; }

.realm-community-wrap { margin: 64px auto 0; max-width: 1270px; padding: 0 24px; }
.realm-community-banner {
  align-items: center;
  background:
    radial-gradient(circle at 4% 50%,rgba(93,99,189,.18),transparent 28%),
    linear-gradient(135deg,rgba(29,21,20,.92),rgba(7,7,9,.96));
  border: 1px solid rgba(201,150,75,.2);
  box-shadow: inset 0 0 55px rgba(0,0,0,.26),0 24px 60px rgba(0,0,0,.24);
  color: #d9cec0;
  display: grid;
  gap: 22px;
  grid-template-columns: auto minmax(0,1fr) auto;
  min-height: 132px;
  padding: 26px 32px;
  transition: border-color .25s,transform .25s;
}
.realm-community-banner:hover { border-color: rgba(145,152,226,.5); transform: translateY(-2px); }
.realm-community-sigil {
  align-items: center;
  background: radial-gradient(circle,rgba(107,114,214,.22),rgba(5,5,7,.84));
  border: 1px solid rgba(136,143,219,.38);
  color: #9da3e6;
  display: flex;
  font-size: 21px;
  height: 58px;
  justify-content: center;
  transform: rotate(45deg);
  width: 58px;
}
.realm-community-sigil::first-letter { transform: rotate(-45deg); }
.realm-community-copy { display: grid; gap: 5px; min-width: 0; }
.realm-community-copy small { color: #9288c8; font: 600 8px/1.4 "C9Nav",Arial,sans-serif; letter-spacing: .18em; }
.realm-community-copy strong { color: #eadfd0; font: 400 27px/1.15 "C9Serif",Georgia,serif; }
.realm-community-copy em { color: #8e857b; font: normal 12px/1.55 Arial,sans-serif; }
.realm-community-action { border-left: 1px solid rgba(201,150,75,.18); color: #cfc4b4; font: 600 9px/1 "C9Nav",Arial,sans-serif; letter-spacing: .2em; padding: 14px 3px 14px 28px; }
.realm-community-action span { color: #989ee0; font-size: 15px; margin-left: 12px; }
.realm-community-wrap + .shared-realm-footer { margin-top: 26px; }

.shared-realm-footer {
  align-items: center;
  border-top: 1px solid rgba(201,150,75,.13);
  color: #6c655d;
  display: grid;
  font: 600 9px/1.6 "C9Nav",Arial,sans-serif;
  gap: 40px;
  grid-template-columns: 1fr 1.4fr 1fr;
  margin: 70px auto 0;
  max-width: 1280px;
  min-height: 190px;
  padding: 35px 34px;
}
.home-page .shared-realm-footer { margin-top: 0; }
.shared-realm-footer .landing-footer-brand .landing-brand-mark { height: 42px; width: 38px; }
.shared-realm-footer .landing-footer-brand .landing-brand-copy strong { color: #b7aa99; font-size: 11px; }
.shared-realm-footer p { margin: 4px 0; text-align: center; }
.shared-realm-footer nav { align-items: center; display: flex; flex-wrap: wrap; gap: 18px; justify-content: flex-end; }
.shared-realm-footer nav a { color: #8f8579; }
.shared-realm-footer nav a:hover { color: #c9964b; }
.shared-realm-footer nav span { color: #8c7350; }

.operator-list { display: grid; gap: 12px; margin-bottom: 18px; }
.operator-card {
  align-items: end;
  background: linear-gradient(135deg,rgba(28,17,12,.58),rgba(5,5,5,.7));
  border: 1px solid rgba(201,150,75,.17);
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(190px,1.25fr) repeat(4,minmax(120px,.7fr)) auto;
  padding: 14px 16px;
}
.operator-card > div { display: grid; gap: 5px; }
.operator-card small { color: #7f756a; font-size: 10px; }
.operator-card strong { color: #ddd0bd; }
.operator-card span { color: #9e9488; font-size: 11px; }
.operator-form { display: grid; gap: 10px; grid-template-columns: repeat(5,minmax(130px,1fr)) auto; }

.notification-control-list { display: grid; gap: 12px; }
.notification-control {
  align-items: center;
  background: linear-gradient(135deg,rgba(28,17,12,.58),rgba(5,5,5,.7));
  border: 1px solid rgba(201,150,75,.17);
  display: grid;
  gap: 14px;
  grid-template-columns: minmax(220px,1.5fr) repeat(3,minmax(130px,.7fr));
  padding: 16px 18px;
}
.notification-control-copy strong { color: #ded3c4; display: block; font: 600 13px/1.4 "C9Nav",Arial,sans-serif; letter-spacing: .06em; }
.notification-control-copy small { color: #837b71; display: block; margin-top: 5px; }
.notification-control label { color: #9e9488; font-size: 11px; }
.notification-control select { margin-top: 6px; min-width: 0; width: 100%; }
.notification-control .route-metric { color: #746b61; font-size: 10px; line-height: 1.55; }
.notification-control .check-row { margin: 0; }
.notification-control[aria-disabled="true"] { opacity: .58; }

@media (max-width: 900px) {
  .operator-card, .operator-form { grid-template-columns: 1fr 1fr; }
  .notification-control { grid-template-columns: 1fr 1fr; }
  .notification-control-copy { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  .operator-card, .operator-form { grid-template-columns: 1fr; }
  .notification-control { grid-template-columns: 1fr; }
  .notification-control-copy { grid-column: auto; }
}

@media (max-width: 1700px) {
  .shared-realm-header .landing-realm-status { display: none; }
}
@media (max-width: 1500px) {
  .shared-realm-header .landing-header-discord { display: none; }
  .shared-realm-header .landing-nav.realm-menu { grid-template-columns: 320px 160px 320px; width: 800px; }
}
@media (max-width: 1360px) {
  .shared-realm-header { grid-template-columns: minmax(210px,1fr) auto minmax(175px,1fr); padding-inline: 26px; }
  .shared-realm-header .landing-nav.realm-menu { grid-template-columns: 290px 150px 290px; width: 730px; }
  .shared-realm-header .realm-menu-gem-spacer { width: 150px; }
  .shared-realm-header .realm-menu-wing > a,
  .shared-realm-header .landing-nav-more > summary { padding-inline: 10px; }
}
@media (max-width: 1100px) {
  .shared-realm-header { grid-template-columns: 1fr auto; }
  /* Match the specificity of the desktop `.landing-nav.realm-menu` rule.
     Otherwise the wide navigation stays above the mobile summary and steals
     taps from the hamburger at narrow widths. */
  .shared-realm-header .landing-nav.realm-menu { display: none; }
  .shared-realm-header > .landing-menu-gem.realm-menu-gem-slot { display: none; }
  .shared-realm-header .landing-header-actions { margin-right: 58px; }
  .shared-realm-header .landing-mobile-menu { display: block; position: absolute; right: 24px; top: 25px; }
  .shared-realm-header .landing-mobile-menu summary { cursor: pointer; display: grid; gap: 5px; list-style: none; padding: 10px; }
  .shared-realm-header .landing-mobile-menu summary::-webkit-details-marker { display: none; }
  .shared-realm-header .landing-mobile-menu summary span { background: #c7b79f; height: 1px; width: 24px; }
  .shared-realm-header .landing-mobile-menu nav { background: rgba(6,6,6,.99); border: 1px solid rgba(201,150,75,.22); box-shadow: 0 20px 50px #000; display: grid; margin: 0; min-width: 240px; padding: 10px; position: absolute; right: 0; top: 48px; }
  .shared-realm-header .landing-mobile-menu nav a { border: 0; border-bottom: 1px solid rgba(201,150,75,.12); color: #a8a094; font: 600 9px/1 "C9Nav",Arial,sans-serif; letter-spacing: .16em; padding: 15px; text-transform: uppercase; }
}
@media (max-width: 800px) {
  .shared-realm-header { height: 74px; padding: 0 18px; }
  .armory-section-nav { top: 74px; }
  .shared-realm-header .landing-brand-copy strong { font-size: 11px; }
  .shared-realm-header .landing-brand-copy small { font-size: 6px; }
  .shared-realm-header .landing-brand-mark { height: 43px; width: 38px; }
  .shared-realm-header .landing-header-actions {
    display: flex;
    grid-column: 2;
    justify-self: end;
    margin-right: 52px;
  }
  .shared-realm-header .landing-header-actions > :not(.header-account) { display: none; }
  .shared-realm-header .header-account-toggle {
    justify-content: center;
    min-height: 40px;
    padding: 5px;
    width: 40px;
  }
  .shared-realm-header .header-account-toggle > span:nth-child(2) { display: none; }
  .shared-realm-header .header-account-panel {
    left: 12px;
    max-height: calc(100vh - 86px);
    position: fixed;
    right: 12px;
    top: 74px;
    width: auto;
  }
  .shared-realm-header .landing-mobile-menu { right: 13px; top: 18px; }
  body:not(.home-page) .page-main { width: min(100% - 24px,1220px); }
  body:not(.home-page) .hero { min-height: 330px; padding-top: 64px; }
  body:not(.home-page):not(.admin-page):not(.admin-login-page) .hero::before { inset: 18px 0 12px; }
  body:not(.home-page):not(.admin-page):not(.admin-login-page) .panel { padding: 16px; }
  body:not(.home-page):not(.admin-page):not(.admin-login-page).character-page .panel { padding: 0; }
  .realm-community-wrap { margin-top: 46px; padding: 0 12px; }
  .realm-community-banner { gap: 18px; padding: 24px; }
  .realm-community-copy strong { font-size: 23px; }
  .shared-realm-footer { grid-template-columns: 1fr; justify-items: center; padding: 52px 24px; text-align: center; }
  .shared-realm-footer nav { justify-content: center; }
  .shared-realm-footer .landing-footer-brand { justify-self: center; }
}
@media (max-width: 620px) {
  .realm-community-banner { grid-template-columns: auto minmax(0,1fr); }
  .realm-community-sigil { height: 46px; width: 46px; }
  .realm-community-action { border-left: 0; border-top: 1px solid rgba(201,150,75,.18); grid-column: 1 / -1; padding: 17px 0 0; text-align: right; }
}
@media (max-width: 1080px) {
  .storage-layout { grid-template-columns: minmax(300px,.75fr) minmax(430px,1.25fr); }
}
@media (max-width: 760px) {
  .key-bonus-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .xp-stat-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .storage-layout { grid-template-columns: 1fr; }
  .storage-layout .inventory-side-stack { grid-template-columns: 1fr; }
  .d2-item-container { --cell: 38px; }
}
@media (max-width: 480px) {
  .key-bonus-grid { grid-template-columns: 1fr; }
  .xp-stat-grid { grid-template-columns: 1fr; }
  .d2-item-container { --cell: 31px; }
}
@media (max-width: 560px) {
  .news-chronicle-entry { gap: 16px; grid-template-columns: 1fr; }
  .news-chronicle-rail { border-bottom: 1px solid rgba(201,150,75,.15); border-right: 0; min-height: 0; padding: 0 0 12px 24px; text-align: left; }
  .news-chronicle-rail > span { left: 1px; right: auto; top: 1px; }
  .news-chronicle-content { padding-bottom: 40px; }
  .news-chronicle-entry.latest .news-chronicle-content { padding-left: 14px; }
}

/* Public season chronicle. */
.season-countdown-panel { display:flex; justify-content:space-between; align-items:center; gap:32px; margin:-16px 0 44px; padding:24px 28px; }
.season-countdown-panel > div:first-child span,.season-detail-hero > span { color:#c46c43; font:600 9px/1 "C9Nav",Arial,sans-serif; letter-spacing:.14em; text-transform:uppercase; }
.season-countdown-panel h2 { margin:6px 0; font-size:30px; }
.season-countdown-panel p { margin:0; color:#80766b; font-size:11px; }
.season-clock { display:grid; grid-template-columns:repeat(4,minmax(64px,1fr)); gap:6px; }
.season-clock b { min-width:68px; display:grid; place-items:center; padding:10px; border:1px solid rgba(186,138,61,.18); color:#e0caa8; font:27px/1 Georgia,serif; }
.season-clock small { margin-top:5px; color:#746a60; font:8px/1 "C9Nav",Arial,sans-serif; letter-spacing:.08em; text-transform:uppercase; }
.season-archive-layout { display:grid; grid-template-columns:minmax(270px,.72fr) minmax(0,2fr); gap:18px; align-items:start; margin-bottom:70px; }
.season-archive-layout > * { min-width:0; max-width:100%; width:100%; }
.season-archive-layout aside { position:sticky; top:112px; }
.season-archive-list { display:grid; gap:8px; }
.season-archive-card { display:grid; gap:6px; padding:15px 16px; border:1px solid rgba(173,129,57,.14); color:#8d8377; background:rgba(4,4,5,.68); }
.season-archive-card:hover,.season-archive-card.active { border-color:rgba(191,77,44,.52); background:linear-gradient(110deg,rgba(113,24,17,.14),rgba(4,4,5,.8)); }
.season-archive-card > span { color:#a96843; font:600 8px/1 "C9Nav",Arial,sans-serif; letter-spacing:.1em; text-transform:uppercase; }
.season-archive-card strong { color:#d3c4b0; font:18px/1.25 Georgia,serif; }
.season-archive-card small,.season-archive-card div { color:#6e665e; font:9px/1.5 Arial,sans-serif; }
.season-archive-card div b { color:#a99b88; }
.season-archive-detail { box-sizing:border-box; min-height:480px; padding:28px; width:100%; }
.season-detail-hero { padding-bottom:23px; border-bottom:1px solid rgba(184,137,60,.18); }
.season-detail-hero h2 { margin:8px 0; font-size:clamp(32px,4vw,58px); }
.season-detail-hero > p { color:#82786d; }
.season-detail-hero blockquote { margin:16px 0 0; padding:12px 16px; border-left:1px solid #9b502f; color:#a59684; font:italic 14px/1.65 Georgia,serif; }
.season-detail-metrics { display:grid; grid-template-columns:repeat(3,1fr); gap:9px; margin:18px 0 32px; }
.season-detail-metrics > div { display:grid; gap:7px; padding:14px; border:1px solid rgba(174,130,57,.13); }
.season-detail-metrics small { color:#776d62; font:8px "C9Nav",Arial,sans-serif; letter-spacing:.1em; }
.season-detail-metrics strong { color:#d7c7b0; font:28px Georgia,serif; }
.season-archive-detail section { margin-top:34px; }
.season-archive-detail section h3 { margin-bottom:13px; padding-bottom:9px; border-bottom:1px solid rgba(174,130,57,.15); }
.season-empty { color:#70675e; font:italic 13px Georgia,serif; }
.season-table-more { margin-top:10px; border-top:1px solid rgba(174,130,57,.12); }
.season-table-more summary { cursor:pointer; padding:12px 4px; color:#a96843; font:600 9px/1.4 "C9Nav",Arial,sans-serif; letter-spacing:.1em; text-transform:uppercase; }
.season-table-more summary:hover,.season-table-more[open] summary { color:#d9b47a; }
.season-table-more .table-scroll { margin-top:3px; }
.season-archive-detail .table-scroll { max-width:100%; overflow-x:auto; }
@media (max-width:850px) {
  .season-countdown-panel { align-items:flex-start; flex-direction:column; }
  .season-archive-layout { grid-template-columns:minmax(0,1fr); width:100%; }
  .season-archive-layout aside { position:static; }
}
@media (max-width:520px) {
  body:not(.home-page) .hero h1 { font-size:clamp(34px,11vw,43px); overflow-wrap:anywhere; }
  .season-clock { width:100%; grid-template-columns:repeat(4,1fr); }
  .season-clock b { min-width:0; font-size:20px; }
  .season-archive-detail { padding:18px; }
  .season-detail-metrics { grid-template-columns:1fr; }
}

/* Inserted runes/gems use their real game sprites, composited like the in-game Armory. */
.item-art { position:relative; width:100%; height:100%; display:grid; place-items:center; }
.item-art > img { max-width:100%; max-height:100%; object-fit:contain; image-rendering:auto; }
.item-socket-overlay { position:absolute; left:50%; top:53%; z-index:2; display:grid; grid-template-columns:repeat(2,26px); place-items:center; gap:0; opacity:0; visibility:hidden; transform:translate(-50%,-50%) scale(.9); transition:opacity .12s ease,transform .12s ease,visibility .12s; pointer-events:none; filter:drop-shadow(0 1px 2px #000) drop-shadow(0 0 1px #000); }
[data-item]:hover .item-socket-overlay,[data-item]:focus .item-socket-overlay,[data-item]:focus-visible .item-socket-overlay { opacity:1; visibility:visible; transform:translate(-50%,-50%) scale(1); }
.item-socket-overlay.sockets-1 { grid-template-columns:28px; }
.item-socket-overlay.sockets-2 { grid-template-columns:28px; }
.item-socket-overlay.sockets-3 { grid-template-columns:24px; }
.item-socket-overlay.sockets-4,.item-socket-overlay.sockets-5,.item-socket-overlay.sockets-6 { grid-template-columns:repeat(2,26px); }
.item-socket-overlay.sockets-5 img:nth-child(3) { grid-column:1 / -1; }
.item-socket-overlay img { width:26px; height:26px; max-width:none; max-height:none; object-fit:contain; image-rendering:auto; }
.item-socket-overlay.sockets-1 img,.item-socket-overlay.sockets-2 img { width:28px; height:28px; }
.item-socket-overlay.sockets-3 img { width:24px; height:24px; }
.item-slot-inner > .item-art,.item-tile > .item-art { min-width:0; min-height:0; }

/* Server-confirmed combat counters on the public character sheet. */
.combat-stat-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:1px;background:var(--line);border:1px solid var(--line)}
.combat-stat-grid .xp-stat{border:0;background:linear-gradient(145deg,rgba(17,12,10,.98),rgba(7,6,6,.98))}
.combat-rank-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(118px,1fr));gap:1px;margin-top:16px;background:var(--line);border:1px solid var(--line)}
.combat-rank-card{position:relative;display:grid;gap:7px;min-height:70px;padding:13px 15px;background:linear-gradient(145deg,rgba(14,11,10,.98),rgba(6,6,7,.98));overflow:hidden}
.combat-rank-card::before{content:"";position:absolute;inset:0 auto 0 0;width:2px;background:rgba(173,173,173,.35)}
.combat-rank-card small,.combat-rank-badge{color:var(--dim);font:600 8px/1.2 var(--sans);letter-spacing:.11em;text-transform:uppercase}
.combat-rank-card strong{color:var(--paper);font:500 21px/1 var(--serif)}
.combat-rank-card.rank-champion::before,.combat-rank-badge.rank-champion{color:#5d91d8;background:#5d91d8}
.combat-rank-card.rank-unique::before,.combat-rank-card.rank-superunique::before,.combat-rank-badge.rank-unique,.combat-rank-badge.rank-superunique{color:#c9a84f;background:#c9a84f}
.combat-rank-card.rank-minion::before,.combat-rank-badge.rank-minion{color:#b18443;background:#b18443}
.combat-rank-card.rank-boss::before,.combat-rank-badge.rank-boss{color:#b94735;background:#b94735}
.combat-ranked-name{display:grid!important;gap:4px!important}
.combat-rank-badge{display:inline-flex;width:max-content;padding:3px 5px;color:#090807!important;border-radius:2px}
.combat-list-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:28px;margin-top:28px}
.combat-list-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:12px}
.combat-list-heading h3{margin:0;color:var(--gold);font:600 11px/1.2 var(--sans);letter-spacing:.16em;text-transform:uppercase}
.combat-list-heading p{max-width:720px;margin:6px 0 0;color:var(--dim);font-size:12px}
.combat-more{flex:0 0 auto;border:1px solid rgba(196,143,43,.35);background:rgba(12,9,8,.82);padding:7px 11px;color:var(--gold);cursor:pointer;font:600 8px/1 var(--sans);letter-spacing:.12em;text-transform:uppercase}
.combat-more:hover{border-color:var(--gold);color:var(--paper)}
.combat-boss-section{margin-top:28px;padding:18px;border:1px solid rgba(185,71,53,.28);background:radial-gradient(circle at 82% 0,rgba(152,49,33,.10),transparent 36%),rgba(8,7,7,.72)}
.combat-boss-list{grid-template-columns:repeat(auto-fit,minmax(230px,1fr));gap:1px}
.combat-ranked-list{display:grid;gap:1px;background:var(--line);border:1px solid var(--line)}
.combat-ranked-row{display:flex;align-items:center;justify-content:space-between;gap:16px;min-height:48px;padding:10px 14px;background:rgba(8,7,7,.96)}
.combat-ranked-row span{display:flex;align-items:center;gap:12px;color:var(--text)}
.combat-ranked-row span b{display:grid;place-items:center;width:24px;height:24px;border:1px solid rgba(196,143,43,.32);color:var(--gold);font:600 10px/1 var(--sans);transform:rotate(45deg)}
.combat-ranked-row strong{color:var(--paper);font:600 15px/1 var(--serif)}
.combat-list-empty{padding:18px;color:var(--dim);font-size:12px;background:rgba(8,7,7,.96)}
@media(max-width:760px){.combat-stat-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.combat-list-grid{grid-template-columns:1fr}.combat-list-heading{align-items:center}.xp-chart-shell{padding-inline:2px}}
@media(max-width:560px){.combat-rank-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}

/* Player account hub: realm identity, friends, messages and security. */
.auth-reset{margin-top:20px;padding-top:17px;border-top:1px solid var(--line)}
.auth-reset summary{width:max-content;color:var(--gold);cursor:pointer;font:600 9px/1.2 var(--sans);letter-spacing:.12em;text-transform:uppercase}
.auth-reset form{margin-top:16px}
.account-profile-shell{display:grid;grid-template-columns:180px minmax(0,1fr);margin-bottom:18px;overflow:hidden}
.account-profile-sigil{position:relative;display:grid;place-content:center;min-height:100%;padding:28px;text-align:center;background:radial-gradient(circle at 50% 48%,rgba(157,37,25,.28),transparent 43%),linear-gradient(145deg,#120a08,#050505);border-right:1px solid rgba(201,150,75,.2)}
.account-profile-sigil::before{content:"";position:absolute;inset:38px;transform:rotate(45deg);border:1px solid rgba(201,150,75,.25);box-shadow:inset 0 0 24px rgba(157,37,25,.14)}
.account-profile-sigil span,.account-profile-sigil small{position:relative;color:#b78345;font:600 8px/1 var(--sans);letter-spacing:.18em}
.account-profile-sigil strong{position:relative;margin:7px 0 5px;color:var(--paper);font:42px/.8 var(--serif)}
.account-profile-main{min-width:0}
.account-profile-main .panel-head{border-bottom:1px solid var(--line)}
.account-realm-links{display:flex;flex-wrap:wrap;gap:8px;margin-bottom:20px}
.realm-link-chip{display:grid;gap:3px;padding:9px 12px;border:1px solid rgba(201,150,75,.2);background:rgba(12,8,7,.72)}
.realm-link-chip small{color:var(--dim);font:600 7px/1 var(--sans);letter-spacing:.12em;text-transform:uppercase}
.realm-link-chip strong,.realm-link-chip b{color:var(--bone);font-size:12px}
.profile-form{display:grid;gap:14px}
.profile-fields{grid-template-columns:repeat(2,minmax(0,1fr))}
.profile-privacy{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1px;background:var(--line);border:1px solid var(--line)}
.profile-privacy .check-row{min-height:50px;margin:0;padding:11px 13px;background:rgba(6,6,7,.98);color:var(--ash);font-size:11px;line-height:1.45}
.account-social-grid{display:grid;grid-template-columns:minmax(280px,.72fr) minmax(0,1.55fr);gap:18px;align-items:start;margin-bottom:18px}
.account-social-grid .panel,.account-security-grid .panel{margin-bottom:0}
.realm-friend-list{display:grid;gap:7px;max-height:595px;overflow:auto}
.realm-friend{display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:11px;align-items:center;padding:11px 12px;border:1px solid rgba(201,150,75,.13);background:linear-gradient(110deg,rgba(19,12,9,.76),rgba(5,5,6,.92))}
.friend-presence{width:9px;height:9px;border-radius:50%;background:#4c4540;box-shadow:0 0 0 4px rgba(76,69,64,.08)}
.realm-friend.online .friend-presence,.realm-friend.is-online .friend-presence{background:#67c97d;box-shadow:0 0 0 4px rgba(74,184,96,.1),0 0 12px rgba(74,184,96,.42)}
.realm-friend strong{display:block;color:var(--bone);font-size:12px}
.realm-friend small{display:block;margin-top:4px;color:var(--dim);font-size:9px;line-height:1.4}
.realm-friend em{display:block;margin-top:4px;color:#887d71;font:normal 9px/1.4 Arial,sans-serif}
.friend-message{min-width:38px;padding:8px;border:1px solid rgba(201,150,75,.2);background:transparent;color:var(--gold);cursor:pointer;font:600 8px/1 var(--sans);letter-spacing:.08em;text-transform:uppercase}
.friend-message:hover{border-color:var(--gold);color:var(--paper)}
.friend-web-state{color:#aa8d62!important}
.realm-command-hint{margin:15px 0 0;color:var(--dim);font-size:10px}
.realm-command-hint code{color:#b78b4a}
.message-new-form{margin-bottom:18px;padding-bottom:18px;border-bottom:1px solid var(--line)}
.message-recipient-grid{grid-template-columns:minmax(180px,1fr) minmax(180px,1fr);align-items:end}
.message-trade-context{min-height:42px;padding:11px 13px;border:1px solid rgba(68,121,170,.26);background:rgba(33,71,105,.09);color:#91b3d2;font-size:10px;line-height:1.5}
.message-hub{display:grid;grid-template-columns:230px minmax(0,1fr);min-height:430px;border:1px solid var(--line);background:#040506}
.conversation-list{max-height:520px;overflow:auto;border-right:1px solid var(--line)}
.conversation-card{display:grid;gap:5px;width:100%;padding:13px 14px;border:0;border-bottom:1px solid var(--line);background:rgba(8,7,7,.96);color:var(--ash);cursor:pointer;text-align:left}
.conversation-card:hover,.conversation-card.active,.conversation-card.is-active{background:linear-gradient(105deg,rgba(111,29,20,.25),rgba(8,7,7,.98));box-shadow:inset 2px 0 #a7472e}
.conversation-card strong{color:var(--bone);font:600 11px/1.35 var(--sans)}
.conversation-card small{color:var(--dim);font-size:9px;line-height:1.4}
.conversation-card em{max-width:100%;color:#746b62;font:normal 9px/1.35 Arial,sans-serif;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.conversation-card b{display:grid;place-items:center;position:absolute;right:10px;top:10px;min-width:17px;height:17px;padding:0 4px;border-radius:10px;background:#9c3828;color:#f4ddd4;font:700 8px Arial,sans-serif}
.conversation-card{position:relative}
.conversation-card.unread strong::after{content:"";display:inline-block;width:6px;height:6px;margin-left:7px;border-radius:50%;background:#bd4b31;box-shadow:0 0 8px rgba(189,75,49,.58)}
.conversation-thread{display:grid;grid-template-rows:auto minmax(0,1fr) auto;min-width:0;min-height:430px}
.conversation-heading{display:flex;justify-content:space-between;gap:10px;min-height:54px;padding:13px 16px;border-bottom:1px solid var(--line)}
.conversation-heading strong{color:var(--bone);font:600 12px var(--sans)}
.conversation-heading small{color:var(--dim);font-size:9px}
.conversation-messages{display:flex;flex-direction:column;gap:9px;min-height:275px;max-height:390px;padding:16px;overflow:auto;background:radial-gradient(circle at 50% 0,rgba(122,56,30,.08),transparent 42%)}
.portal-message{align-self:flex-start;width:min(78%,580px);padding:10px 12px;border:1px solid rgba(201,150,75,.13);background:#0d0b0a}
.portal-message.mine{align-self:flex-end;border-color:rgba(167,71,46,.32);background:linear-gradient(135deg,rgba(80,25,18,.35),rgba(11,8,7,.97))}
.portal-message strong{color:var(--gold);font:600 9px var(--sans);letter-spacing:.07em}
.portal-message p{margin:6px 0;color:var(--text);font-size:12px;line-height:1.55;white-space:pre-wrap;overflow-wrap:anywhere}
.portal-message time{display:block;color:var(--dim);font-size:8px;text-align:right}
.message-reply{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:8px;padding:11px;border-top:1px solid var(--line)}
.message-reply textarea{min-height:48px;resize:vertical}
.account-security-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px;margin:0 0 18px}
.active-session-list{display:grid;gap:8px}
.active-session{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:12px;align-items:center;padding:12px 13px;border:1px solid rgba(201,150,75,.13);background:rgba(7,7,8,.94)}
.active-session strong{display:block;color:var(--bone);font-size:11px}
.active-session small{display:block;margin-top:4px;color:var(--dim);font-size:9px;line-height:1.45}
.active-session.current{border-color:rgba(87,154,101,.3);box-shadow:inset 2px 0 #5b9868}
.trade-card-actions{position:relative;z-index:1;display:flex;flex-wrap:wrap;gap:8px;margin-top:13px}
.trade-contact{display:inline-flex;align-items:center;justify-content:center}
.trade-reputation{display:inline-flex;align-items:center;margin-left:8px;padding:3px 6px;border:1px solid rgba(201,150,75,.18);color:#c59a56;font:600 8px/1 var(--sans);letter-spacing:.04em;white-space:nowrap}
.admin-trade-disputes{display:grid;grid-template-columns:repeat(auto-fit,minmax(310px,1fr));gap:10px}
.admin-trade-dispute{padding:15px;border:1px solid rgba(193,76,52,.24);background:radial-gradient(circle at 100% 0,rgba(145,39,25,.12),transparent 44%),rgba(7,6,6,.96)}
.admin-trade-dispute>header{display:flex;justify-content:space-between;gap:14px}
.admin-trade-dispute>header div{display:grid;gap:5px}
.admin-trade-dispute>header span,.admin-trade-dispute>header small{color:var(--dim);font-size:8px}
.admin-trade-dispute>header strong{color:var(--bone);font:17px/1.15 var(--serif)}
.admin-trade-parties{display:grid;grid-template-columns:1fr auto 1fr;gap:9px;align-items:center;margin-top:13px;padding:10px;border-block:1px solid rgba(201,150,75,.1);color:#aa9679;font-size:10px;text-align:center}
.admin-trade-parties b{color:#a44a35}
.admin-trade-dispute blockquote{min-height:58px;margin:12px 0;padding:11px;border-left:2px solid rgba(193,76,52,.42);background:rgba(85,25,17,.08);color:#a89e92;font:italic 11px/1.55 Georgia,serif}
.admin-trade-proof{display:flex;flex-wrap:wrap;gap:6px}
.admin-trade-proof span{padding:5px 7px;border:1px solid rgba(201,150,75,.12);color:#81776c;font:600 7px/1 var(--sans);letter-spacing:.07em;text-transform:uppercase}
.admin-trade-dispute>footer{display:flex;flex-wrap:wrap;gap:8px;margin-top:13px}
.admin-content-columns{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:1px;border:1px solid rgba(201,150,75,.13);background:rgba(201,150,75,.13)}
.admin-content-columns>section{min-width:0;padding:18px;background:radial-gradient(circle at 95% 0,rgba(123,44,25,.08),transparent 30%),rgba(5,5,6,.98)}
.admin-content-title{display:flex;align-items:center;justify-content:space-between;gap:14px;margin-bottom:15px;padding-bottom:13px;border-bottom:1px solid rgba(201,150,75,.12)}
.admin-content-title span{color:#a6633e;font:600 7px/1 var(--sans);letter-spacing:.16em}
.admin-content-title h4{margin:6px 0 0;color:var(--bone);font:22px/1 var(--serif)}
.admin-content-form{display:grid;gap:13px}
.admin-content-form .admin-form-grid{gap:10px}
.admin-content-form label{display:grid;gap:6px;color:#81786e;font:600 7px/1.25 var(--sans);letter-spacing:.09em;text-transform:uppercase}
.admin-content-form .check-row{display:flex;margin:0;padding:11px;border:1px solid rgba(201,150,75,.12);background:rgba(13,9,8,.7);color:#95897b;font-size:9px;line-height:1.45;text-transform:none}
.content-markdown{font-family:Consolas,"Courier New",monospace;font-size:11px;line-height:1.55;resize:vertical}
.admin-content-preview{min-height:150px;margin-top:18px;padding:18px;border:1px solid rgba(201,150,75,.16);background:radial-gradient(circle at 80% 0,rgba(121,41,23,.13),transparent 38%),#080707}
.admin-content-preview>span{color:#a86640;font:600 7px/1 var(--sans);letter-spacing:.14em;text-transform:uppercase}
.admin-content-preview h4{margin:9px 0 11px;color:#e2d6c7;font:25px/1.14 var(--serif)}
.admin-content-preview .admin-content-lead{color:#b2a18e;font:italic 13px/1.55 var(--serif)}
.admin-content-preview>div{color:#8f857a;font-size:11px;line-height:1.65}
.admin-content-preview>div p{margin:8px 0}
.admin-content-list{display:grid;gap:1px;max-height:390px;margin-top:14px;border:1px solid rgba(201,150,75,.11);background:rgba(201,150,75,.11);overflow:auto}
.admin-content-row{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:12px;align-items:center;padding:12px;background:#080707}
.admin-content-row>div{display:grid;gap:5px;min-width:0}
.admin-content-row>div>span{display:flex;align-items:center;gap:7px}
.admin-content-row>div>span b{color:#a9824c;font:600 7px/1 var(--sans);letter-spacing:.08em;text-transform:uppercase}
.admin-content-row strong{overflow:hidden;color:#c9bcaa;font-size:11px;text-overflow:ellipsis;white-space:nowrap}
.admin-content-row small{color:#6f675e;font-size:8px}
.admin-inner-grid{margin-top:15px}
.admin-inner-grid>div{padding:14px;border:1px solid rgba(201,150,75,.1);background:#070707}
.admin-inner-grid h4{margin:0 0 12px;color:#a98557;font:600 8px/1 var(--sans);letter-spacing:.13em;text-transform:uppercase}
.account-settlements-panel{margin-bottom:18px}
.trade-settlement-list{display:grid;gap:11px}
.trade-settlement-card{position:relative;padding:16px;border:1px solid rgba(201,150,75,.14);background:radial-gradient(circle at 88% 0,rgba(109,37,24,.10),transparent 36%),linear-gradient(135deg,rgba(16,11,9,.96),rgba(5,5,6,.98));overflow:hidden}
.trade-settlement-card::before{content:"";position:absolute;inset:0 auto 0 0;width:2px;background:#8b6337}
.trade-settlement-card.status-completed::before{background:#5d9c6b;box-shadow:0 0 12px rgba(93,156,107,.45)}
.trade-settlement-card.status-disputed::before{background:#c14c34;box-shadow:0 0 12px rgba(193,76,52,.48)}
.trade-settlement-card.status-cancelled::before,.trade-settlement-card.status-expired::before{background:#5d5650}
.trade-settlement-card>header{display:flex;justify-content:space-between;gap:18px;padding-bottom:13px;border-bottom:1px solid rgba(201,150,75,.11)}
.trade-settlement-card>header span{color:#987246;font:600 8px/1 var(--sans);letter-spacing:.12em;text-transform:uppercase}
.trade-settlement-card>header h3{margin:6px 0 5px;color:var(--bone);font:21px/1.15 var(--serif)}
.trade-settlement-card>header p{margin:0;color:var(--dim);font-size:9px}
.trade-settlement-card>header>b{align-self:flex-start;padding:7px 9px;border:1px solid rgba(201,150,75,.18);color:#b79565;font:600 8px/1 var(--sans);letter-spacing:.09em;text-transform:uppercase;white-space:nowrap}
.status-completed>header>b{border-color:rgba(93,156,107,.3);color:#76b785}
.status-disputed>header>b{border-color:rgba(193,76,52,.34);color:#d77d69}
.settlement-checks{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1px;margin-top:12px;border:1px solid rgba(201,150,75,.10);background:rgba(201,150,75,.10)}
.settlement-checks span{min-height:38px;padding:12px;background:#080707;color:#756d64;font:600 8px/1.3 var(--sans);letter-spacing:.06em;text-transform:uppercase}
.settlement-checks .done,.settlement-checks .proof-verified,.settlement-checks .proof-not_required{color:#72ae7d;background:rgba(42,86,49,.14)}
.settlement-checks .proof-mismatch{color:#d57660;background:rgba(107,29,20,.18)}
.trade-settlement-actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:13px}
.settlement-feedback{margin:14px 0 0;padding-top:12px;border-top:1px solid rgba(201,150,75,.1);color:#b59a70;font-size:10px}
.settlement-feedback-form{display:grid;grid-template-columns:auto minmax(180px,1fr) auto;gap:9px;align-items:end;margin-top:14px;padding-top:13px;border-top:1px solid rgba(201,150,75,.1)}
.settlement-feedback-form label{display:grid;gap:6px;color:#81786e;font:600 7px/1 var(--sans);letter-spacing:.1em;text-transform:uppercase}
@media(max-width:980px){.account-social-grid{grid-template-columns:1fr}.realm-friend-list{max-height:340px}.profile-privacy{grid-template-columns:1fr}}
@media(max-width:1100px){.admin-content-columns{grid-template-columns:1fr}}
@media(max-width:760px){.account-profile-shell{grid-template-columns:1fr}.account-profile-sigil{min-height:150px;border-right:0;border-bottom:1px solid rgba(201,150,75,.2)}.account-profile-sigil::before{inset:35px calc(50% - 40px)}.profile-fields,.account-security-grid{grid-template-columns:1fr}.message-hub{grid-template-columns:1fr}.conversation-list{display:flex;max-height:150px;border-right:0;border-bottom:1px solid var(--line);overflow:auto}.conversation-card{min-width:185px;border-right:1px solid var(--line);border-bottom:0}.settlement-checks{grid-template-columns:1fr}.settlement-feedback-form{grid-template-columns:1fr}.trade-settlement-card>header{align-items:flex-start;flex-direction:column}}
@media(max-width:520px){.message-recipient-grid{grid-template-columns:1fr}.portal-message{width:92%}.message-reply{grid-template-columns:1fr}.account-profile-main .panel-head{align-items:flex-start;flex-direction:column}.realm-friend{grid-template-columns:auto minmax(0,1fr)}}
@media(max-width:850px){.achievement-toolbar,.achievement-profile,.achievement-layout,.achievement-book{grid-template-columns:1fr}.achievement-profile-progress{text-align:left}.achievement-book{gap:10px}}
@media(max-width:520px){.achievement-toolbar form label>span{grid-template-columns:1fr}.achievement-profile{margin-inline:-12px;padding-inline:15px}.achievement-rank-row{grid-template-columns:36px minmax(0,1fr)}.achievement-rank-row>em{grid-column:2;text-align:left}.achievement-group{padding:15px}.achievement-card{grid-template-columns:42px minmax(0,1fr)}}
