/* ============================================================================
   Drag(*)nBall Z: Fighter's Edition — SAGA THEME
   Late-90s anime/game-site presentation layered over the existing components.
   Gameplay ANSI colors and selectable client themes remain authoritative inside
   .play; this file reshapes the public site, forms, catalogs and dialog chrome.
   ========================================================================== */

:root {
  color-scheme: light;
  --bg:        #173d77;
  --bg-win:    #f7edcf;
  --bg-pane:   #fffaf0;
  --bg-bar:    #f6cf67;
  --bg-raise:  #ffe4a0;
  --bg-well:   #fffdf5;
  --line:      #d2b878;
  --line-hot:  #233b67;
  --line-lock: #14294e;
  --green:     #117d68;
  --green-dim: #3b927f;
  --amber:     #8d3d0c;
  --orange:    #ef7517;
  --orange-dk: #b83f16;
  --gold:      #954b05;
  --red:       #c52e32;
  --fg:        #101a31;
  --fg-dim:    #343a49;
  --fg-faint:  #555b66;
  --race-saiyan: #d95b17;
  --race-human: #334155;
  --race-halfbreed: #b85a12;
  --race-namekian: #278538;
  --race-android: #187894;
  --race-icer: #4769bd;
  --race-demon: #c52e32;
  --race-kaio: #7146a8;
  --race-genie: #a86b00;
  --race-spirit: #5262aa;
  --race-alien: #54891f;
  --race-yardratian: #ad3d86;
  --race-immortal: #9b6a00;
  --race-bioandroid: #16805b;
  --rank-2: #64748b;
  --glow:      0 3px 0 rgba(117,45,14,.17);
  --glow-grn:  0 2px 0 rgba(10,76,65,.14);
  --glow-red:  0 2px 0 rgba(133,20,25,.16);
  --tick:      #d2b878;
  --tick-hot:  #ef7517;
  --hd-tick:   #ffd15a;
  --lock:      #ef7517;
  --lock-wash: rgba(239,117,23,.09);
  --mono: 'Share Tech Mono', ui-monospace, 'Cascadia Code', monospace;
  --ui: 'Rajdhani', system-ui, sans-serif;
}

html { background: #102b59; }
body {
  color: var(--fg);
  font-family: var(--ui);
  font-size: clamp(16px, 1.05vw + .45vh, 18px);
  font-weight: 600;
  background: linear-gradient(155deg, #367ec3 0%, #215a9c 45%, #142e62 100%);
}
body::before {
  content: ''; position: fixed; inset: 0; pointer-events: none;
  background:
    radial-gradient(ellipse at 12% 92%, rgba(255,255,255,.16) 0 7%, transparent 7.3%),
    radial-gradient(ellipse at 26% 96%, rgba(255,255,255,.12) 0 10%, transparent 10.3%);
}
::selection { background: #f7ad28; color: #18213b; }
:focus-visible { outline: 3px solid #f2a01f; outline-offset: 2px; }

/* Fine print dots instead of CRT scanlines. */
.crt {
  opacity: .38;
  background:
    radial-gradient(circle, rgba(17,35,68,.16) .55px, transparent .7px) 0 0 / 5px 5px,
    radial-gradient(130% 115% at 50% 45%, transparent 72%, rgba(8,21,48,.22) 100%);
  mix-blend-mode: multiply;
}

* { scrollbar-color: #d1872d #f4e7c2; }
*::-webkit-scrollbar-thumb { background: #d1872d; border-color: #f7edcf; border-radius: 8px; }
*::-webkit-scrollbar-track { background: #f4e7c2; }

/* ---- shared shell -------------------------------------------------------- */
#app {
  border: 4px solid #14294e;
  border-radius: 15px;
  background: var(--bg-win);
  box-shadow: 0 0 0 2px #f4a124, 0 16px 44px rgba(4,15,40,.48), inset 0 0 0 1px rgba(255,255,255,.75);
}
#app.boot { color: #173d77; background: #fff4d6; }
.boot-line { font-family: var(--ui); font-size: 1.05rem; font-weight: 700; letter-spacing: .08em; }
.boot-line::after { display: none; }

.titlebar {
  min-height: 3.1rem; gap: .75rem; padding: .4rem .85rem;
  color: #fff;
  background:
    linear-gradient(100deg, rgba(255,255,255,.2), transparent 25%),
    linear-gradient(180deg, #ffad29 0%, #ef7417 68%, #d14a18 100%);
  border-bottom: 3px solid #14294e;
}
.dragon-mark {
  display: grid; place-items: center; flex: 0 0 auto;
  width: 2rem; height: 2rem; border-radius: 50%;
  color: #b62a24; background: radial-gradient(circle at 35% 30%, #ffe67b 0 12%, #ffbd24 38%, #f07816 100%);
  border: 2px solid #8f2918; box-shadow: inset -3px -4px 0 rgba(132,37,14,.18), 0 2px 0 rgba(73,24,18,.25);
  font-size: .8rem; text-shadow: none;
}
.titlebar .title {
  color: #fff8d8; font-family: 'Anton', var(--ui); font-size: 1.08rem;
  letter-spacing: .055em; text-transform: uppercase;
  text-shadow: 2px 2px 0 #1a3262, -1px -1px 0 #1a3262;
}
.titlebar .title b { color: #ffe04e; font-weight: 400; text-shadow: 2px 2px 0 #9e2e1e; }
.titlebar .title .db { color: #fff; }
.titlebar .stat { color: #fff2c7; font-family: var(--ui); font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.titlebar .stat b { color: #fff; font-weight: 700; }

.menubar {
  gap: .3rem; padding: .5rem .65rem;
  background:
    linear-gradient(180deg, rgba(255,255,255,.55), transparent 45%),
    #f4d275;
  border-bottom: 3px solid #233b67;
  box-shadow: inset 0 -1px 0 rgba(255,255,255,.7);
}
.tab {
  min-height: 2.15rem; padding: .35rem .78rem;
  color: #233b67; font-family: var(--ui); font-size: .86rem; font-weight: 700;
  letter-spacing: .055em; text-transform: uppercase;
  border: 2px solid transparent; border-radius: 999px;
  transition: transform 100ms ease, background 100ms ease, color 100ms ease, border-color 100ms ease;
}
.tab .br { display: none; }
.nav-caret { margin-left: .22rem; font-size: .72em; }
.tab:hover { color: #fff; background: #2f5d9c; border-color: #14294e; transform: translateY(-1px); }
.tab.active {
  color: #fff9dc; background: #244d88; border-color: #14294e;
  text-shadow: none; box-shadow: inset 0 -3px 0 #112b54, 0 2px 0 rgba(20,41,78,.24);
}
.tab.active::after { display: none; }
.tab.tab-play { color: #fff; background: #dc4b20; border-color: #8f2918; box-shadow: inset 0 -3px 0 #982817; }
.tab.tab-play:hover { color: #17233c; background: #ffb529; text-shadow: none; }
.tab.tab-discord { color: #fff; background: #5865f2; border-color: #353f9b; }
.tab.tab-logout:hover, .tab.tab-admin:hover { color: #fff; background: var(--red); border-color: #861d25; }
.tab.tab-char { color: #173d77; background: rgba(255,255,255,.42); border-color: rgba(35,59,103,.28); }
.spacer-tab { border: 0; background: transparent; }

.navmenu, .charmenu {
  padding: .45rem; gap: .15rem; border: 3px solid #14294e; border-radius: 10px;
  background: #fff4d6;
  box-shadow: 5px 6px 0 rgba(20,41,78,.28), 0 16px 34px rgba(9,23,54,.28);
}
.navmenu-item, .charmenu-item {
  color: #293954; font-family: var(--ui); font-weight: 700; letter-spacing: .035em;
  border-radius: 6px; padding: .48rem .75rem;
}
.navmenu-item:hover, .charmenu-item:hover { color: #fff; background: #2f5d9c; box-shadow: none; }
.navmenu-item.current { color: #fff; background: #e86c1c; }
.navmenu-item.current::before { content: '★ '; color: #ffe56b; }
.navmenu-item.item-admin:hover { background: var(--red); color: #fff; }
.navbadge { color: #fff; border-radius: 999px; background: #d93929; }

.term-body { grid-template-rows: 1fr; background: var(--bg-win); }
.cmdline, .scan-sweep { display: none !important; }
.viewport {
  padding: clamp(.75rem, 1.6vw, 1.25rem);
  background:
    linear-gradient(135deg, rgba(39,79,139,.035) 25%, transparent 25%) 0 0 / 24px 24px,
    linear-gradient(315deg, rgba(239,117,23,.035) 25%, transparent 25%) 0 0 / 24px 24px,
    #f7edcf;
}
.pane { animation: saga-page-in 150ms ease-out both; }
@keyframes saga-page-in { from { opacity: .45; transform: translateY(3px); } to { opacity: 1; transform: none; } }

/* ---- panels and typography ---------------------------------------------- */
.box, .home-section, .home-links, .card, .adm-card, .adm-sc-card, .dbz-bl-block {
  border: 2px solid #233b67;
  border-radius: 10px;
  background: #fffaf0;
  box-shadow: 3px 4px 0 rgba(35,59,103,.12);
}
.box::before, .box::after, .modal-win::before { display: none; }
.box > .box-hd {
  min-height: 2.6rem; padding: .5rem .8rem;
  color: #fff; font-family: var(--ui); font-size: .88rem; font-weight: 700;
  letter-spacing: .105em;
  border-bottom: 2px solid #14294e;
  border-radius: 7px 7px 0 0;
  background: linear-gradient(180deg, #3568a8, #234d88);
}
.box > .box-hd::before { content: '★'; color: #ffd351; margin-right: .25rem; }
.box-hd .hd-r { color: #ffeb9e; font-family: var(--ui); font-weight: 700; }
.view-intro, .muted { color: #343a49; }
.view-intro { font-size: 1rem; line-height: 1.6; }
.faint { color: #555b66; }
a { color: #a73f18; font-weight: 600; }
a:hover { color: #e15e15; }
.ascii { color: #b83f16; text-shadow: none; }

.btn, .plg-btn {
  min-height: 2.35rem; padding: .46rem 1rem;
  color: #fff; background: linear-gradient(180deg, #ff9d26, #e56518);
  border: 2px solid #993019; border-radius: 999px;
  box-shadow: inset 0 -3px 0 rgba(119,38,18,.25), 0 2px 0 rgba(43,44,63,.14);
  font-family: var(--ui); font-weight: 700; letter-spacing: .055em; text-transform: uppercase;
}
.btn::before, .btn::after { content: none; }
.btn:hover, .plg-btn:hover, .plg-btn.primary:hover {
  color: #17233c; background: linear-gradient(180deg, #ffe36a, #f3ad24);
  border-color: #9f4b13; box-shadow: inset 0 -3px 0 rgba(141,75,15,.18), 0 3px 0 rgba(43,44,63,.14);
}
.btn.scan { color: #fff; background: linear-gradient(180deg, #3979b8, #25568f); border-color: #153765; }
.btn.scan:hover { color: #17233c; background: #ffd353; border-color: #9f4b13; }
.btn.ghost, .plg-btn.ghost { color: #233b67; background: #fff4d6; border-color: #233b67; box-shadow: none; }
.btn.ghost:hover, .plg-btn.ghost:hover { color: #fff; background: #2f5d9c; border-color: #14294e; }
.btn.danger, .plg-btn.danger { color: #fff; background: #c83a35; border-color: #7d1d25; }
.btn:disabled { filter: grayscale(.5); opacity: .48; }

.field > label, .adm-flab, .plg-lab { color: #244d88; font-family: var(--ui); font-weight: 700; }
.field > label::before { content: none; }
.inp, .plg-inp {
  color: #17233c; background: #fffef8;
  border: 2px solid #8b794f; border-radius: 7px;
  font-family: var(--ui); font-weight: 600; caret-color: #d54d19;
  box-shadow: inset 0 2px 4px rgba(78,57,23,.07);
}
.inp:focus, .plg-inp:focus {
  border-color: #e46b18; box-shadow: 0 0 0 3px rgba(244,153,34,.2), inset 0 2px 4px rgba(78,57,23,.05);
}
.inp::placeholder, .plg-inp::placeholder { color: #89857a; }
input[type="checkbox"], input[type="radio"] { accent-color: #e46b18; }
.badge, .tag, .cli .tag, .el-tag {
  border-radius: 999px; background: #f4e6bd; border-color: #bca66e; color: #4f5360;
}

/* ---- home page ----------------------------------------------------------- */
.home-page { max-width: 1240px; }
.box.hero {
  overflow: hidden; border: 3px solid #14294e; border-radius: 15px;
  background:
    repeating-conic-gradient(from -8deg at 84% 50%, rgba(255,255,255,.11) 0deg 4deg, transparent 4deg 12deg),
    linear-gradient(125deg, #1f4e91 0%, #286ab0 52%, #df4d1c 100%);
  box-shadow: 6px 7px 0 rgba(20,41,78,.2);
}
.hero-bd { min-height: 25rem; display: flex; align-items: center; padding: clamp(1.65rem, 4vw, 3.8rem); }
.hero-bd::after {
  content: '★'; position: absolute; right: clamp(-2rem, 1vw, 2rem); top: 50%;
  display: grid; place-items: center; width: clamp(12rem, 24vw, 20rem); aspect-ratio: 1;
  transform: translateY(-50%) rotate(-10deg); border-radius: 50%;
  color: #b72825; font-size: clamp(3rem, 7vw, 5rem);
  background: radial-gradient(circle at 34% 28%, #ffe876 0 6%, #ffbd2d 30%, #ef7318 70%, #b93619 100%);
  border: 5px solid rgba(102,28,22,.68); box-shadow: inset -18px -22px 0 rgba(112,28,16,.14), 10px 14px 0 rgba(9,31,68,.22);
  opacity: .94;
}
.hero-l { max-width: min(61%, 47rem); }
.hero-kicker, .home-eyebrow { color: #c4471a; font-family: var(--ui); font-weight: 700; }
.hero .hero-kicker { color: #ffde67; }
.hero-word {
  color: #fff9db; font-family: 'Anton', var(--ui); line-height: .96;
  text-shadow: 4px 4px 0 #14294e, -2px -2px 0 #14294e, 2px -2px 0 #14294e, -2px 2px 0 #14294e;
}
.hero-word .star { color: #ffd13e; }
.hero-sub { color: #ffd75d; font-weight: 700; text-shadow: 2px 2px 0 rgba(20,41,78,.7); }
.hero-copy { color: #fdf7df; font-size: 1.08rem; font-weight: 600; text-shadow: 1px 1px 0 rgba(15,33,70,.45); }
.hstat { padding: .48rem .72rem; border-radius: 7px; background: rgba(12,36,79,.55); border: 1px solid rgba(255,224,116,.5); }
.hstat-k { color: #ffe998; font-family: var(--ui); font-weight: 700; }
.hstat-v { color: #fff; text-shadow: none; }
.hstat-v .sfx { color: #ffe06b; }
.home-section, .home-links { box-shadow: 3px 4px 0 rgba(35,59,103,.12); }
.home-section-hd h2, .home-online-hd h2 { color: #1b315d; font-family: 'Anton', var(--ui); font-weight: 400; letter-spacing: .02em; }
.home-step > b {
  width: 2.2rem; height: 2.2rem; display: grid; place-items: center; margin-bottom: .55rem;
  color: #fff; background: #e4661b; border: 2px solid #9d3218; border-radius: 50%;
  font-family: var(--ui); font-size: .8rem;
}
.home-step h3 { color: #1d3e75; font-weight: 700; }
.home-step p, .home-link small { color: #3d4351; font-size: .92rem; line-height: 1.55; }
.home-link { border-color: #d2b878; }
.home-link:hover { background: #ffe6a1; box-shadow: inset 5px 0 0 #e96b19; }
.home-link b { color: #1d3e75; font-size: 1rem; font-weight: 700; }
.home-link i, .home-who-link { color: #c64a17; }

/* ---- tables, cards and catalogs ----------------------------------------- */
.cli-wrap, .who-wrap {
  border: 2px solid #8d7540; border-radius: 8px; background: #fffdf5;
}
.cli, .who, .cmdtable, .planet-grid, .kv { font-size: max(.92em, 15px); }
.cli th, .who th { font-size: max(.78em, 12px); }
.legendbar, .ency-hero-d, .ency-card-bd, .skl-desc, .skl-how, .gd-p, .gd-help { line-height: 1.55; }
.legendbar { color: #4a5060; font-size: max(.86em, 14px); }
.cli thead th {
  color: #fff0b5; background: #244d88; border-bottom: 2px solid #14294e;
  font-family: var(--ui); font-weight: 700;
}
.cli thead th.primary { color: #ffd554; }
.cli th, .cli td, .who th, .who td { border-color: #dccb9f; }
.cli tbody tr:nth-child(even), .who tbody tr:nth-child(even) { background: rgba(244,210,117,.13); }
.cli tbody tr:hover, .who tbody tr:hover, .menu-list a:hover, .adm-card:hover, .mail-row:hover,
.ed-list .ed-reg:hover, .ed-entry-list .ed-entry:hover, .ed-pal-list .ed-pal:hover {
  background: #ffe4a0; box-shadow: inset 5px 0 0 #ed741b;
}
.cli td.name::before, .cli td.name::after, .who td.name::before, .who td.name::after { content: none; }
.cli .name, .who td.name, .card .cname { color: #a83e18; font-weight: 700; }
.cli .pos, .cli .pl, .who td.pl { color: #087665; }
.cli .grp th { background: #ead7a5; color: #233b67; font-weight: 700; }
.card, .adm-card { border-color: #8d7540; }
.card.card-on { border-color: #16806d; box-shadow: inset 0 4px 0 #16806d, 3px 4px 0 rgba(35,59,103,.12); }

/* Fighter colors originate in the dark MUD palette. Give them a dark anime
   nameplate on light pages so pale race/form colors never disappear. */
.who td.name .name-link, .cli td.name .name-link, .who-color-chip {
  display: inline-flex; align-items: center; max-width: 100%;
  padding: .14rem .45rem; border: 1px solid #14294e; border-radius: 5px;
  background: #203b6a; color: #fff; font-weight: 700;
  margin: 0; text-shadow: 0 1px 1px #000; overflow: hidden; text-overflow: ellipsis;
}
.who td.name .dot { color: #16806d; text-shadow: none; }
.home-online .who { font-size: 1rem; line-height: 1.45; }
.home-online .who th { font-size: .76rem; }
.home-online .who td { padding-top: .38rem; padding-bottom: .38rem; }
.home-online .who td.status { color: #2f3747; font-family: var(--ui); font-weight: 700; }
.pane-who .cli td { padding-top: .42rem; padding-bottom: .42rem; }
.pane-who .who-status { color: #343a49; font-family: var(--ui); font-weight: 700; }
.pane-who .st-fight { color: #a9232b; }
.pane-who .st-afk { color: #555b66; }
.pane-who .st-train { color: #8d3d0c; }
.lb-tab, .adm-tab, .dsr-acttab, .ed-tool {
  color: #233b67; background: #fff4d6; border: 2px solid #233b67; border-radius: 999px;
  font-family: var(--ui); font-weight: 700;
}
.lb-tab:hover, .adm-tab:hover, .dsr-acttab:hover, .ed-tool:hover { color: #fff; background: #2f5d9c; border-color: #14294e; }
.lb-tab.on, .adm-tab.active, .dsr-acttab.active, .ed-tool.active { color: #fff; background: #e4661b; border-color: #993019; text-shadow: none; }

.ency-hero {
  border: 2px solid #233b67; border-left: 9px solid #e4661b; border-radius: 9px;
  background: #fff4d6; box-shadow: 3px 4px 0 rgba(35,59,103,.12);
}
.ency-hero-t { color: #1b3c73; font-family: 'Anton', var(--ui); font-weight: 400; }
.ency-card, .skl-item, .itm-card { border-radius: 9px; }
.ency-tipbar, .ency-filter { background: #f5e3b4; border-color: #bca66e; }

/* ---- modals and popovers ------------------------------------------------- */
.modal-backdrop { background: rgba(10,27,61,.72); backdrop-filter: blur(5px); }
.modal-win {
  color-scheme: light; color: #17233c;
  border: 3px solid #14294e; border-radius: 13px; background: #fffaf0;
  box-shadow: 0 0 0 2px #f4a124, 8px 12px 0 rgba(12,30,68,.28), 0 28px 60px rgba(4,14,36,.38);
}
.modal-win::after { background: none; }
.modal-bar {
  color: #fff; min-height: 3rem; border-bottom: 3px solid #14294e;
  background: linear-gradient(180deg, #3568a8, #244d88); box-shadow: none;
}
.modal-dot { width: 1rem; height: 1rem; color: #b62a24; background: #ffb928; border: 2px solid #8f2918; box-shadow: none; }
.modal-title { color: #fff4c3; font-family: var(--ui); font-size: .92rem; }
.modal-x { color: #fff; border: 2px solid rgba(255,255,255,.5); background: rgba(255,255,255,.1); }
.modal-bd { scrollbar-color: #d1872d #f4e7c2; }
.modal-bd::-webkit-scrollbar-track { background: #f4e7c2; }
.modal-bd::-webkit-scrollbar-thumb { background: #d1872d; }
.modal-sec { color: #a13f18; font-weight: 700; border-color: #d2b878; }
.modal-sec::before { background: #e4661b; box-shadow: none; }
.mention-pop, .el-pop, .el-menu, .uih-cmp, .uih-namemenu, .uih-ac {
  color-scheme: dark;
  --fg: #f7f6ec; --fg-dim: #cbd5e2; --fg-faint: #9eb0c5;
  --bg-raise: #244f7d; --line: #355d87; --line-hot: #557ca1;
  --green: #59dbb2; --amber: #ffca53; --gold: #ffd052;
  color: var(--fg); background: linear-gradient(155deg, #173e73, #0a1c36 72%);
  border: 3px solid #ef8a22; border-radius: 9px;
  box-shadow: 0 0 0 2px #14294e, 5px 7px 0 rgba(20,41,78,.3), 0 14px 32px rgba(7,23,55,.42);
}
.uih-cmp, .uih-namemenu, .uih-ac { border: 2px solid #ef8a22; background: linear-gradient(155deg, #173e73, #0a1c36 72%); }
.mention-pop .mention-name, .el-pop .el-name, .el-menu .el-menu-nm { color: #ffd052; }
.el-pop .el-card .el-sub, .el-pop .el-row .el-k, .el-pop .el-desc { color: #aebdd0; }
.el-pop .el-row .el-v { color: #f2f5fa; }
.el-menu .el-menu-it { color: #cbd5e2; }
.el-menu .el-menu-it:hover { background: #244f7d; color: #fff; }
.el-menu .el-menu-it b { color: #ffca53; }

/* ---- admin/editor stays practical but no longer looks like a shell ------- */
.pane-admin { --lock: #c52e32; --lock-wash: rgba(197,46,50,.08); }
.adm-tabbar { border-color: #bca66e; }
.adm-search::before { content: '⌕'; color: #a65010; font-size: 1.2rem; }
.tog { border: 2px solid #8d7540; border-radius: 7px; background: #fff4d6; }
.adm-sc-card, .adm-report, .adm-change, .dsr-char, .dbz-bl-block { background: #fffaf0; border-color: #bca66e; }
.ed-canvas-wrap { border: 3px solid #14294e; border-radius: 8px; }

/* ---- the actual game remains a high-contrast game client ----------------- */
.play {
  color-scheme: dark;
  --bg: #07152a; --bg-win: #0b1c36; --bg-pane: #0d2342; --bg-bar: #173e73;
  --bg-raise: #1b416d; --bg-well: #061225;
  --line: #294969; --line-hot: #3c668e; --line-lock: #678caf;
  --green: #56d6ae; --green-dim: #258b75; --amber: #ffbe55;
  --orange: #ef7517; --orange-dk: #a83c17; --gold: #ffd052; --red: #ff6268;
  --fg: #f7f6ec; --fg-dim: #c3ccda; --fg-faint: #8799b0;
  --term-bg: #061225; --term-fg: #f7f6ec; --term-dim: #9eacc1; --term-accent: #ffb52d;
  --lock-wash: rgba(255,181,45,.07);
  border: 3px solid #14294e; border-radius: 10px;
  background: #061225;
  box-shadow: 0 0 0 2px #d9751c, inset 0 0 0 1px rgba(255,255,255,.04);
  font-family: var(--mono);
}
.play::before { display: none; }
.play .btn { font-family: var(--mono); }
.viewport:has(> .pane-play) { background: #102b59; }

/* Blue Capsule-Corp framing with orange saga accents. The stream itself stays
   nearly black/navy so every ANSI color retains its combat contrast. */
.play .play-bar {
  min-height: 2.75rem; color: #dce5f2;
  border-bottom: 3px solid #0a1c38;
  background: linear-gradient(180deg, #2e67a5, #1d477e);
  box-shadow: inset 0 1px rgba(255,255,255,.13);
}
.play .play-bar .lamp { border-radius: 50%; border: 1px solid rgba(255,255,255,.45); }
.play .play-bar.connected .lamp { background: #58ddb4; box-shadow: 0 0 8px #58ddb4; }
.play .play-bar .x {
  min-height: 1.9rem; display: inline-flex; align-items: center;
  color: #f8edce; background: #102a51; border: 1px solid #7392b2; border-radius: 999px;
  font-family: var(--ui); font-weight: 700; text-transform: uppercase; letter-spacing: .055em;
}
.play .play-bar .x:hover, .play .play-bar .x.mode.on, .play .play-bar .x.mode.on:hover {
  color: #17233c; background: #ffbc32; border-color: #8f3a16; box-shadow: inset 0 -2px rgba(136,51,18,.22);
}
.play .play-out {
  color: #f7f6ec;
  background:
    radial-gradient(circle at 50% 120%, color-mix(in srgb, var(--term-accent, #ffb52d) 7%, transparent), transparent 48%),
    linear-gradient(180deg, color-mix(in srgb, var(--term-bg, #061225) 90%, #183c68), var(--term-bg, #061225) 75%);
  text-shadow: 0 1px 1px rgba(0,0,0,.9);
}
.play .play-out .tline { font-weight: 500; }
.play .play-rail {
  border-color: #355d87; background: linear-gradient(180deg, #10294c, #091b33);
  font-size: clamp(16px, 1.18vw, 18px);
}
.play .pr-card {
  overflow: hidden; border: 2px solid #365f8b; border-radius: 8px;
  background: #091a31; box-shadow: 0 4px 12px rgba(0,0,0,.2);
}
.play .pr-map, .play .pr-gridwrap {
  background: #020507;
}
.play.full-client .play-rail > .pr-map {
  background: #020507;
}
.play .pr-map .pr-grid, .play .pr-map .pr-canvas {
  filter: none;
}
.play .pr-card::before { display: none; }
.play .pr-hd {
  min-height: 2rem; align-items: center; padding: .35rem .62rem;
  color: #dfe8f3; background: linear-gradient(180deg, #285d99, #1c477d);
  border-bottom: 2px solid #0d2446; font-family: var(--ui); font-size: max(.78em, 13px); font-weight: 700;
}
.play .pr-hd .t { color: #ffcf53; font-weight: 700; }
.play .pr-hd .sub { color: #c7d4e3; }
.play .pr-status, .play .pr-maploc { background: #10294b; }
.play .env-read i { color: #a9bad0; font-size: max(.72em, 11px); }
.play .env-read b { color: #f1f5fa; font-size: max(1em, 15px); }
.play .env-read.env-planet b { color: #ffd052; text-shadow: 0 1px #000; }
.play .pr-maploc { min-height: 1.8rem; font-size: max(.74em, 12px); }
.play .pr-maploc .t { color: #ffca53; }
.play .pr-rownums { color: #a8b8cb; background: #0d2342; }

.play .play-in {
  min-height: 3.4rem; border-top: 3px solid #dc681b;
  background: linear-gradient(180deg, #183d6b, #0d2443);
  box-shadow: 0 -8px 20px rgba(0,0,0,.24), inset 0 1px rgba(255,255,255,.07);
}
.play .play-in-label { color: #ffd052; font-family: var(--ui); font-size: max(.7em, 12px); font-weight: 700; }
.play .play-in .ps { color: #ffbd36; filter: none; }
.play .play-command-input, .play .play-command-password {
  color: #fff; border: 2px solid #547da3;
  background: #061326; box-shadow: inset 4px 0 0 #ef7517, inset 0 2px 8px rgba(0,0,0,.35);
  font-size: max(16px, .98em);
}
.play .play-command-input:focus, .play .play-command-password:focus {
  border-color: #ffbd36; background: #081a31;
  box-shadow: 0 0 0 3px rgba(255,181,45,.13), inset 4px 0 0 #ffb52d;
}
.play .play-command-input:empty::before { color: #9eacc1; opacity: 1; }
.play .play-in-hint { color: #b6c3d3; font-size: max(.62em, 11px); opacity: 1; }
.play .play-macros { background: #0d2443; border-color: #355d87; }
.play .play-macros button, .play .pr-ctab, .play .pr-compass button {
  color: #f3e9cc; background: #173861; border: 1px solid #4f769b; border-radius: 6px;
}
.play .play-macros button:hover, .play .pr-ctab:hover, .play .pr-ctab.on, .play .pr-compass button:hover {
  color: #17233c; background: #ffba31; border-color: #9a3a17;
}
.play.full-client > .play-out {
  border-color: rgba(255,184,53,.24); border-bottom: 0;
  background:
    linear-gradient(180deg, rgba(5,16,34,.38), rgba(3,10,23,.64)),
    radial-gradient(circle at 50% 100%, rgba(239,117,23,.09), transparent 56%);
}
.play.full-client > .play-macros { background: rgba(10,28,53,.96); }
.play.full-client > .play-in {
  border-color: rgba(255,184,53,.3);
  background: linear-gradient(180deg, rgba(25,61,105,.98), rgba(8,25,48,.99));
}

/* Floating spectate is appended to <body>, not inside .play. Re-establish the
   complete dark-client token set here so the light public-site theme cannot
   recolor its map labels, gauges, or ANSI-adjacent status text. */
.snoop-pop {
  color-scheme: dark;
  --bg: #07152a; --bg-win: #0b1c36; --bg-pane: #0d2342; --bg-bar: #173e73;
  --bg-raise: #1b416d; --bg-well: #061225;
  --line: #294969; --line-hot: #3c668e; --line-lock: #678caf;
  --green: #56d6ae; --green-dim: #258b75; --amber: #ffbe55;
  --gold: #ffd052; --red: #ff6268; --fg: #f7f6ec; --fg-dim: #c3ccda; --fg-faint: #93a5bc;
  --term-bg: #061225; --term-fg: #f7f6ec; --term-dim: #9eacc1; --term-accent: #ffb52d;
  color: var(--fg); border: 3px solid #ef8a22;
  background: linear-gradient(155deg, #102a4c, #07162b);
  box-shadow: 0 0 0 2px #14294e, 7px 10px 0 rgba(10,27,61,.28), 0 25px 65px rgba(0,0,0,.55);
}
.snoop-pop .snoop-head { color: #fff2bd; background: linear-gradient(180deg, #306aa7, #204e85); border-bottom: 2px solid #0a1c38; }
.snoop-pop .snoop-title { color: #fff2bd; }
.snoop-pop .snoop-grid { color: #f7f6ec; background: #02070f; }
.snoop-pop .snoop-stat, .snoop-pop .snoop-foot { color: #e4eaf1; background: #0b203c; border-color: #365f87; }
.snoop-pop .snoop-track { background: #041126; border-color: #557ca1; }

/* Options and command search read like game menus, not terminal utilities. */
.play .play-drawer {
  font-size: max(var(--uih-size, 16px), 16px); color: #f3f5f8;
  background: #0c213f; border: 2px solid #ef8a22; border-right: 0;
  box-shadow: -10px 0 28px rgba(0,0,0,.48);
}
.play .play-drawer::before { display: none; }
.play .pd-tabs { background: #1f4d84; border-bottom: 2px solid #07182f; }
.play .pd-tab, .play .pd-btn {
  color: #f7eed4; background: #173861; border: 1px solid #7291ae; border-radius: 999px;
  font-family: var(--ui); font-size: max(.76em, 12px); font-weight: 700;
}
.play .pd-tab:hover, .play .pd-tab.on, .play .pd-btn:hover { color: #17233c; background: #ffbd36; border-color: #9a3a17; }
.play .pd-body { font-size: max(.94em, 15px); line-height: 1.5; }
.play .pd-h { color: #ffca53; font-size: max(.8em, 13px); }
.play .pd-lbl, .play .pd-note, .play .pd-foot { color: #aebdd0; font-size: max(.78em, 12px); }
.play .pd-help, .play .pd-check { color: #d2dae5; font-size: max(.88em, 14px); }
.play .pd-in, .play .pd-select, .play .pal-in {
  color: #fff; background: #061326; border: 1px solid #557ca1; border-radius: 5px; font-size: max(.9em, 14px);
}
.play .pal-card { border: 3px solid #ef8a22; border-radius: 9px; background: #0c213f; }
.play .pal-item { font-size: max(.9em, 14px); }
.play .pal-item.sel { background: #244f7d; box-shadow: inset 4px 0 #ffb52d; }
.play .pal-item .pal-name { color: #ffd052; }

/* Structured in-game popups share the same blue/orange shell. */
.uih-pop {
  color-scheme: dark;
  --bg-win: #0b1c36; --bg-pane: #0d2342; --bg-bar: #173e73; --bg-well: #07162b;
  --bg-raise: #1b416d; --line: #294969; --line-hot: #426d94; --line-lock: #7295b3;
  --green: #58d8af; --green-dim: #258b75; --amber: #ffbf58; --orange: #ef7517;
  --gold: #ffd052; --red: #ff6268; --fg: #f7f6ec; --fg-dim: #c6cfdd; --fg-faint: #96a7bb;
  font-family: var(--ui); font-size: max(var(--uih-size, 16px), 16px); font-weight: 600; line-height: 1.45;
  border: 3px solid #ef8a22; border-radius: 11px;
  background: linear-gradient(155deg, #102a4c, #08182f);
  box-shadow: 0 0 0 2px #112b53, 7px 10px 0 rgba(10,27,61,.28), 0 25px 65px rgba(0,0,0,.55);
}
.uih-pop::before { display: none; }
.uih-head {
  min-height: 3rem; background: linear-gradient(180deg, #306aa7, #204e85);
  border-bottom: 3px solid #0a1c38; box-shadow: none;
  font-size: max(.82em, 13px);
}
.uih-led { width: 1rem; height: 1rem; background: #ffb72d; border: 2px solid #9a3519; box-shadow: none; }
.uih-title { color: #fff2bd; text-shadow: 0 1px #10254a; }
.uih-top { background: #102846; border-color: #365f87; }
.uih-footblock, .uih-pager { background: #0b203c; }
.uih-search, .uih-select, .uih-date, .uih-qty { color: #fff; background: #061326; border-color: #567da1; }
.uih-search:focus-within, .uih-select:focus, .uih-date:focus { border-color: #ffbd36; box-shadow: 0 0 0 3px rgba(255,181,45,.12); }
.uih-title, .uih-item-name, .uih-tr, .uih-mail-row, .uih-skill-card, .uih-quest-row { font-weight: 600; }
.uih-wallet, .uih-search-in, .uih-select, .uih-count, .uih-legend, .uih-page-btn,
.uih-page-n, .uih-drow, .uih-item-desc, .uih-chg-body, .uih-mail-when, .uih-mail-field label,
.uih-help-usage, .uih-hint, .uih-foot, .uih-copy { font-size: max(.78em, 12px); }
.uih-chip, .uih-badge, .uih-mini, .uih-btn, .uih-sec, .uih-inv-h, .uih-score-lbl,
.uih-skill-lvl, .uih-skill-exp, .uih-quest-status { font-size: max(.72em, 11.5px); }
.uih-chip, .uih-page-btn, .uih-btn, .uih-mini { border-radius: 6px; }
.uih-chip.on, .uih-btn.buy, .uih-mini, .uih-step.on, button.uih-race.on {
  color: #17233c; background: #ffbd36; border-color: #9a3a17; box-shadow: none;
}
.uih-table { border-color: #365f87; background: #07162b; }
.uih-tr.head { color: #ffe5a0; background: #173d6d; }
.uih-tr:not(.head):nth-child(odd) { background: rgba(44,91,142,.12); }
.uih-tr:not(.head):hover { background: #183b64; box-shadow: inset 3px 0 #ffb52d; }
.uih-item, .uih-mail-row, .uih-inv-eqrow, .uih-score-stat, .uih-skill-card, .uih-quest-row {
  border-color: #345d84; background: #0a1d37; box-shadow: none;
}
.uih-item:hover, .uih-mail-row:hover, .uih-inv-eqrow:hover, .uih-score-stat:hover,
.uih-skill-card:hover, .uih-quest-row:hover { border-color: #e38a28; background: #102c4d; }
.uih-hist-row { border-color: #345d84; border-left-color: #65bfff; background: #0a1d37; }
.uih-hist-row:hover { border-color: #527da4; border-left-color: #ffb52d; background: #102c4d; }
.uih-sec::before, .uih-inv-h::before { background: #ffb52d; box-shadow: none; }
.uih-scroll, .uih-footblock, .uih-sell, .uih-chips, .uih-ac { scrollbar-color: #c77d29 #07162b; }

/* Pregame is still Dragon Ball, but warmer and less like a green scanner. */
.play-view[data-plg='pregame'] .plg-overlay {
  color-scheme: dark;
  --green: #ffb52d; --green-dim: #c86b1b; --gold: #ffd15a; --amber: #ffbd55;
  --fg: #f5f7ff; --fg-dim: #b8c5da; --fg-faint: #8293ad;
  --bg-pane: #101f3b; --bg-bar: #19345f; --bg-well: #09162f; --bg-raise: #19365d;
  --line: #293c61; --line-hot: #46628d; --line-lock: #ef9a25;
  background:
    repeating-conic-gradient(from 0deg at 85% 15%, rgba(255,255,255,.07) 0deg 4deg, transparent 4deg 13deg),
    radial-gradient(circle at 85% 15%, #f5a326 0 7rem, transparent 7.1rem),
    linear-gradient(145deg, #173e78, #0d1d3e 70%);
}
.plg-logo { color: #fff9dc; text-shadow: 3px 3px 0 #132a55; }
.plg-card { border: 3px solid #ef9a25; border-radius: 12px; background: rgba(13,28,58,.96); }
.plg-card-hd::before { content: '★'; color: #ffd154; }
.plg-charcard, .plg-racecard { border-radius: 9px; }
.play-view[data-plg='pregame'] .plg-lab {
  color: #ffe18a; font-size: max(.72rem, 12px); text-shadow: 0 1px 1px #07152d;
}

/* One-use Dragon Radar CAPTCHA. The transparent buttons align to the seven
   rendered balls but reveal no star-count metadata in the page DOM. */
.plg-captcha {
  position: relative; padding: .65rem; border: 2px solid #ef8a22; border-radius: 10px;
  background: #081a35; box-shadow: inset 0 0 0 2px rgba(45,97,151,.48);
}
.plg-captcha[hidden] { display: none; }
.plg-cap-hd { display: flex; align-items: center; justify-content: space-between; gap: .7rem; margin-bottom: .35rem; }
.plg-cap-hd b { color: #ffd052; font-family: var(--ui); font-size: .78rem; letter-spacing: .12em; }
.plg-cap-refresh {
  color: #d4deeb; background: #173e73; border: 1px solid #557ca1; border-radius: 5px;
  padding: .2rem .5rem; font: 700 .65rem/1.2 var(--ui); cursor: pointer;
}
.plg-cap-refresh:hover { color: #17233c; background: #ffbd36; border-color: #9a3a17; }
.plg-cap-prompt { color: #f3f6fa; font-size: max(.8rem, 13px); margin-bottom: .45rem; }
.plg-cap-stage { position: relative; width: 100%; aspect-ratio: 410 / 180; overflow: hidden; border-radius: 8px; }
.plg-cap-stage > img { display: block; width: 100%; height: 100%; user-select: none; }
.plg-cap-hit {
  position: absolute; width: 15%; aspect-ratio: 1; transform: translate(-50%, -50%);
  border: 2px solid transparent; border-radius: 50%; background: transparent; cursor: crosshair;
}
.plg-cap-hit:hover, .plg-cap-hit:focus-visible { border-color: rgba(255,255,255,.82); box-shadow: 0 0 0 3px rgba(255,189,54,.35); }
.plg-cap-hit.picked { border-color: #6fe9f0; background: rgba(111,233,240,.16); box-shadow: 0 0 12px rgba(111,233,240,.65); }
.plg-cap-foot { min-height: 1.15rem; margin-top: .35rem; color: #afbed1; font-size: .7rem; letter-spacing: .06em; }
.plg-captcha.complete .plg-cap-picked { color: #6fe9f0; font-weight: 700; }
.plg-cap-trap { position: fixed !important; left: -10000px !important; width: 1px !important; height: 1px !important; opacity: 0 !important; pointer-events: none !important; }

/* Character select: bold anime game-menu cards. Race colors remain useful
   accents, while the surface and labels own the contrast. */
.plg-overlay[data-view='select'] .plg-sel-t {
  color: #fff4c3; font-family: 'Anton', var(--ui); font-size: 1.35rem;
  letter-spacing: .05em; text-shadow: 2px 2px 0 #14294e;
}
.plg-overlay[data-view='select'] .plg-sel-s { color: #cad5e5; font-size: max(.8rem, 13px); }
.plg-overlay[data-view='select'] .plg-grid { gap: 1rem; }
.plg-overlay[data-view='select'] .plg-charcard {
  color: #f8f3df; padding: 0; overflow: hidden;
  border: 3px solid #ef8a22;
  background: linear-gradient(155deg, #285d99, #173a6b 62%, #10294d);
  box-shadow: 0 0 0 2px #102a50, 5px 7px 0 rgba(5,17,41,.32), 0 16px 30px rgba(2,10,27,.3);
}
.plg-overlay[data-view='select'] .plg-charcard:hover,
.plg-overlay[data-view='select'] .plg-charcard:focus-visible {
  transform: translateY(-3px); border-color: #ffd052;
  box-shadow: 0 0 0 3px #14294e, 6px 9px 0 rgba(5,17,41,.34), 0 20px 38px rgba(2,10,27,.42);
}
.plg-overlay[data-view='select'] .plg-card-aura { left: auto; right: -3.5rem; top: -4.5rem; opacity: .16; }
.plg-overlay[data-view='select'] .plg-chead {
  min-height: 4.2rem; margin: 0; padding: .8rem .9rem .7rem;
  border-bottom: 2px solid rgba(255,208,82,.48);
  background: linear-gradient(90deg, rgba(8,28,61,.58), rgba(8,28,61,.08));
}
.plg-overlay[data-view='select'] .plg-emblem {
  color: #fff; border: 2px solid #ffd052; background: #10294d;
  box-shadow: inset 0 0 0 3px rgba(239,138,34,.35), 0 3px 0 rgba(4,14,34,.4);
}
.plg-overlay[data-view='select'] .plg-emblem *,
.plg-overlay[data-view='select'] .plg-cname,
.plg-overlay[data-view='select'] .plg-cname * {
  font-weight: 800; text-shadow: 0 1px 1px #000, 0 0 4px #06152d;
}
.plg-overlay[data-view='select'] .plg-cname { font-size: 1.2rem; }
.plg-overlay[data-view='select'] .plg-badge {
  color: #fff1bf; border-color: #ffca53; background: rgba(7,24,53,.7); font-weight: 700;
}
.plg-overlay[data-view='select'] .plg-crows {
  gap: .22rem; margin: .7rem .85rem .2rem; padding: .65rem .75rem;
  border: 1px solid #537ba3; border-radius: 7px; background: rgba(5,20,46,.66);
}
.plg-overlay[data-view='select'] .plg-crow { color: #d7e0eb; font-size: max(.87rem, 14px); }
.plg-overlay[data-view='select'] .plg-crow b,
.plg-overlay[data-view='select'] .plg-crow span:last-child {
  color: #fff; font-weight: 700; text-shadow: 0 1px 1px #06152d;
}
.plg-overlay[data-view='select'] .plg-ck { color: #ffcf61; font-family: var(--ui); font-weight: 700; }
.plg-overlay[data-view='select'] .plg-pl { color: #6fe9f0 !important; }
.plg-overlay[data-view='select'] .plg-charcard > .plg-btn {
  width: auto; margin: .72rem .85rem .85rem; border: 2px solid #8e3218;
  border-radius: 7px; color: #17233c; background: linear-gradient(180deg, #ffd75c, #f29a24);
  box-shadow: 0 3px 0 #8e3218; font-family: var(--ui); font-weight: 800;
}
.plg-overlay[data-view='select'] .plg-charcard > .plg-btn:hover {
  background: linear-gradient(180deg, #fff09a, #ffb631); box-shadow: 0 4px 0 #8e3218;
}

/* ---- compact/mobile ------------------------------------------------------ */
@media (max-width: 700px) {
  #app { --app-margin: 0px; border-width: 0; border-radius: 0; box-shadow: none; }
  .titlebar { min-height: 2.75rem; border-bottom-width: 2px; }
  .dragon-mark { width: 1.7rem; height: 1.7rem; }
  .menubar { padding: .38rem; gap: .2rem; border-bottom-width: 2px; }
  .tab { padding: .35rem .6rem; font-size: .78rem; }
  .viewport { padding: .65rem; }
  .hero-bd { min-height: 0; padding-bottom: 11rem; }
  .hero-l { max-width: 100%; }
  .hero-bd::after { width: 10rem; right: 50%; top: auto; bottom: -1.2rem; transform: translateX(50%) rotate(-9deg); }
  .hero-word { font-size: clamp(2.25rem, 13vw, 3.3rem); }
  .hero-sub { letter-spacing: .22em; }
  .box, .home-section, .home-links { border-radius: 8px; box-shadow: 2px 3px 0 rgba(35,59,103,.1); }
  .cli th:first-child, .cli td:first-child, .cli td[colspan] { background: #fffdf5; }
}

@media (prefers-reduced-motion: reduce) {
  .pane { animation: none; }
  .tab:hover { transform: none; }
}

/* ============================================================================
   DARK SAGA — late-90s Dragon Ball home-video / game-menu palette.
   Keep the orange-and-gold identity, but move every public working surface onto
   ink-blue cards so long-form text, catalogs and admin tools are comfortable at
   night. The game renderer keeps its own darker token set above.
   ========================================================================== */
:root {
  color-scheme: dark;
  --bg: #071426; --bg-win: #0b1b32; --bg-pane: #102743; --bg-bar: #17375d;
  --bg-raise: #1b4168; --bg-well: #071529;
  --line: #294c70; --line-hot: #4d759a; --line-lock: #f09a2b;
  --green: #63d6b2; --green-dim: #35977e;
  --amber: #ffc45b; --gold: #ffd45f; --red: #ff676b;
  --fg: #f5f1e3; --fg-dim: #c8d1de; --fg-faint: #94a6bc;
  /* The first saga skin used ink-dark race colors for cream pages. These are
     luminous MUD-channel equivalents with sufficient contrast on the dark site. */
  --race-saiyan: #ff9a2e; --race-human: #f3f6fb; --race-halfbreed: #ffbd63;
  --race-namekian: #65eb77; --race-android: #61d9ed; --race-icer: #9cc0ff;
  --race-demon: #ff6a6f; --race-kaio: #bd9aff; --race-genie: #ffd66f;
  --race-spirit: #d3d9ff; --race-alien: #a7eb6a; --race-yardratian: #ff95d9;
  --race-immortal: #ffe98b; --race-bioandroid: #55d29a; --rank-2: #d6e0f2;
  --race-mutant: #77e6c8; --race-saibaman: #9ae263; --race-arlian: #e6a2ff;
  --race-shinjin: #c9abff; --race-god: #ffe477; --race-makyan: #67dfb6;
  --race-kanassan: #8bcfff; --race-diety: #ffeb91; --race-deity: #ffeb91;
  --race-angel: #bcefff;
  --tick: #31577d; --tick-hot: #ef8b27; --lock: #ef8b27;
  --lock-wash: rgba(239,139,39,.1);
}
html { background: #040b18; }
body {
  color: var(--fg);
  background:
    radial-gradient(circle at 88% 8%, rgba(239,117,23,.18), transparent 23rem),
    radial-gradient(circle at 8% 92%, rgba(45,99,161,.22), transparent 28rem),
    linear-gradient(150deg, #0d2a50 0%, #08182e 48%, #040b18 100%);
}
body::before {
  opacity: .42;
  background:
    radial-gradient(circle, rgba(255,210,94,.12) .65px, transparent .8px) 0 0 / 7px 7px,
    radial-gradient(ellipse at 82% 7%, rgba(240,125,27,.12), transparent 30rem);
}
* { scrollbar-color: #b96f24 #071529; }
*::-webkit-scrollbar-thumb { background: #b96f24; border-color: #071529; }
*::-webkit-scrollbar-track { background: #071529; }

#app {
  background: #0a1a30; border-color: #040b18;
  box-shadow: 0 0 0 2px #e78222, 0 18px 50px rgba(0,0,0,.62), inset 0 0 0 1px rgba(112,153,194,.16);
}
#app.boot { color: #ffe19a; background: #0b1b32; }
.menubar {
  background: linear-gradient(180deg, #1b416d, #102b4e); border-bottom-color: #040b18;
  box-shadow: inset 0 1px rgba(255,255,255,.07), inset 0 -2px rgba(239,117,23,.18);
}
.tab { color: #d9e1eb; }
.tab:hover { color: #17233c; background: #ffd052; border-color: #9c3a18; }
.tab.active { color: #fff4c3; background: #d85d1a; border-color: #7f2518; box-shadow: inset 0 -3px #8d2c18; }
.tab.tab-char { color: #fff0bd; background: #173e6b; border-color: #537ca4; }
.navmenu, .charmenu {
  color: var(--fg); background: #0c203b; border-color: #ef8a22;
  box-shadow: 0 0 0 2px #07152a, 5px 7px 0 rgba(0,0,0,.32), 0 18px 40px rgba(0,0,0,.55);
}
.navmenu-item, .charmenu-item { color: #d9e2ee; }

.term-body { background: #08182d; }
.viewport {
  background:
    linear-gradient(135deg, rgba(61,105,153,.045) 25%, transparent 25%) 0 0 / 24px 24px,
    linear-gradient(315deg, rgba(239,117,23,.04) 25%, transparent 25%) 0 0 / 24px 24px,
    #0a1a30;
}
.box, .home-section, .home-links, .card, .adm-card, .adm-sc-card, .dbz-bl-block {
  color: var(--fg); border-color: #365f88; background: linear-gradient(155deg, #102743, #0b1c34);
  box-shadow: 3px 4px 0 rgba(0,0,0,.28), inset 0 1px rgba(255,255,255,.035);
}
.box > .box-hd { background: linear-gradient(180deg, #285b94, #193e70); border-bottom-color: #061326; }
.view-intro, .muted { color: #c8d1de; }
.faint { color: #9babc0; }
a { color: #ffb643; }
a:hover { color: #ffe078; }
.ascii { color: #ff9a38; }

.field > label, .adm-flab { color: #ffd06a; }
.inp, .plg-inp, textarea.inp, select.inp {
  color: #f8f5eb; background: #061326; border-color: #4d7396; caret-color: #ffc45b;
  box-shadow: inset 0 2px 5px rgba(0,0,0,.3);
}
.inp::placeholder, .plg-inp::placeholder { color: #8497ae; }
.btn.ghost, .plg-btn.ghost { color: #e7edf5; background: #132f52; border-color: #6383a1; }
.badge, .tag, .cli .tag, .el-tag { color: #d5deea; background: #142f50; border-color: #52769a; }

.home-section-hd h2, .home-online-hd h2, .home-step h3, .home-link b, .ency-hero-t { color: #ffe09a; }
.home-step p, .home-link small, .home-online .who td.status, .pane-who .who-status { color: #bdc9d8; }
.home-link { border-color: #315777; }
.home-link:hover { background: #173b62; box-shadow: inset 5px 0 #ef8a22; }
.home-link i, .home-who-link { color: #ffad3e; }

.cli-wrap, .who-wrap { border-color: #3d6384; background: #07162b; }
.legendbar { color: #b8c5d5; }
.cli th, .cli td, .who th, .who td { border-color: #294764; }
.cli tbody tr:nth-child(even), .who tbody tr:nth-child(even) { background: rgba(39,82,126,.16); }
.cli tbody tr:hover, .who tbody tr:hover, .menu-list a:hover, .adm-card:hover, .mail-row:hover,
.ed-list .ed-reg:hover, .ed-entry-list .ed-entry:hover, .ed-pal-list .ed-pal:hover {
  background: #173b62; box-shadow: inset 5px 0 #ef8a22;
}
.cli .name, .who td.name, .card .cname { color: #ffb84a; }
.cli .pos, .cli .pl, .who td.pl { color: #76dfc0; }
.cli .grp th { color: #ffe09a; background: #17385f; }
.card, .adm-card { border-color: #365f88; }
.lb-tab, .adm-tab, .dsr-acttab, .ed-tool { color: #dce5ef; background: #102b4b; border-color: #52769a; }
.ency-hero { color: var(--fg); background: #102743; border-color: #365f88; border-left-color: #ef8a22; }
.ency-tipbar, .ency-filter { color: #d3dce7; background: #102b4b; border-color: #3f668a; }

.modal-backdrop { background: rgba(1,6,15,.82); }
.modal-win {
  color-scheme: dark; color: var(--fg); border-color: #ef8a22; background: #0b1c34;
  box-shadow: 0 0 0 2px #07152a, 8px 12px 0 rgba(0,0,0,.32), 0 28px 70px rgba(0,0,0,.68);
}
.modal-bd { scrollbar-color: #b96f24 #071529; }
.modal-bd::-webkit-scrollbar-track { background: #071529; }
.modal-sec { color: #ffd06a; border-color: #365b7d; }
.adm-tabbar { border-color: #365b7d; }
.tog, .adm-sc-card, .adm-report, .adm-change, .dsr-char, .dbz-bl-block {
  color: var(--fg); background: #0d223d; border-color: #365f88;
}

/* Hover cards are fast-reading game tooltips: labels gold, values near-white,
   descriptions cool-gray. Explicit colors prevent a public-page token or ANSI
   item name from lowering the contrast of its stat rows. */
.mention-pop, .el-pop, .el-menu {
  color: #f8f5eb; background: linear-gradient(155deg, #102e54, #07162b 76%);
  border-color: #ef8a22; box-shadow: 0 0 0 2px #061326, 6px 8px 0 rgba(0,0,0,.3), 0 18px 45px rgba(0,0,0,.68);
}
.el-pop { min-width: 17rem; padding: .72rem .8rem; font-size: max(.88rem, 14px); }
.el-card .el-hd { border-bottom-color: #42698c; padding-bottom: .45rem; margin-bottom: .5rem; }
.el-card .el-name, .el-card .el-name * { font-weight: 800; text-shadow: 0 1px 2px #000, 0 0 5px rgba(255,190,72,.22); }
.el-card .el-sub { color: #c4d0df; font-size: max(.78em, 12px); font-weight: 700; }
.el-row { line-height: 1.65; }
.el-row .el-k { color: #ffd06a; font-weight: 700; }
.el-row .el-v { color: #f8f5eb; font-weight: 650; }
.el-desc, .el-card .el-scan { color: #bac7d7; }
.el-tag { background: #102b49; font-weight: 750; }
.el-menu .el-menu-it { color: #dbe4ee; }

/* LEADERBOARDS — race-channel rails and an arcade-tournament podium. */
.lb-tabs { gap: .45rem; padding: .35rem; border: 1px solid #315a82; background: #07172b; }
.lb-tab { border-radius: 5px; font-weight: 800; }
.lb-table { border-collapse: separate; border-spacing: 0 .28rem; padding: .18rem .35rem .4rem; }
.lb-table thead th { top: -.18rem; border-bottom: 2px solid #ef8a22; background: #122f51; }
.lb-table tbody tr { --race-c: #6e8fad; background: #0a1c33; }
.lb-table tbody td {
  padding-top: .48rem; padding-bottom: .48rem; border-top: 1px solid #274968;
  border-bottom: 1px solid #274968;
}
.lb-table tbody td:first-child { border-left: 4px solid var(--race-c); border-radius: 6px 0 0 6px; }
.lb-table tbody td:last-child { border-right: 1px solid #274968; border-radius: 0 6px 6px 0; }
.lb-table .lb-rank {
  display: inline-grid; place-items: center; min-width: 2.55rem; padding: .12rem .34rem;
  color: #aebdd0; border: 1px solid #3e6284; border-radius: 999px; background: #071426;
  font-family: var(--ui); font-weight: 800; letter-spacing: .03em;
}
.lb-table .lb-podium-1 .lb-rank { color: #2b1b04; border-color: #ffe083; background: linear-gradient(#ffe57c,#d99a25); box-shadow: 0 0 14px rgba(255,202,68,.25); }
.lb-table .lb-podium-2 .lb-rank { color: #172337; border-color: #eef4ff; background: linear-gradient(#f2f6ff,#aebdd4); }
.lb-table .lb-podium-3 .lb-rank { color: #28150d; border-color: #e8aa7b; background: linear-gradient(#e9ad7d,#ad633e); }
.lb-table tr.lb-podium-1 { background: linear-gradient(90deg, rgba(255,194,55,.16), #0b2038 32%, #0a1c33); }
.lb-table tr.lb-podium-2 { background: linear-gradient(90deg, rgba(201,215,236,.12), #0b2038 32%, #0a1c33); }
.lb-table tr.lb-podium-3 { background: linear-gradient(90deg, rgba(215,135,78,.12), #0b2038 32%, #0a1c33); }
.lb-table tr.lb-row:hover { background: #163655; box-shadow: inset 6px 0 var(--race-c); }
.lb-table td.name .lb-name {
  color: #f7f5ec; background: #07172b; border-color: var(--race-c);
  box-shadow: inset 3px 0 var(--race-c), 0 2px 7px rgba(0,0,0,.24);
}
.lb-table td.name .lb-name:hover { background: #102f50; border-bottom-color: #ffd05a; }
.lb-table td.race-tick { box-shadow: inset 3px 0 var(--race-c); }
.lb-table td.race-tick .race-c { color: var(--race-c); font-weight: 800; text-shadow: 0 1px #000; }
.lb-table td.pl { color: #f5f1e3; font-weight: 700; }
.lb-table .pl-sfx { color: #ffc45b; }

@media (max-width: 700px) {
  .cli th:first-child, .cli td:first-child, .cli td[colspan] { background: #07162b; }
  .lb-table { border-spacing: 0 .2rem; padding-inline: .15rem; }
  .lb-table tbody td { padding-top: .38rem; padding-bottom: .38rem; }
  .lb-table .lb-rank { min-width: 2.15rem; padding-inline: .2rem; }
}
