/* ==========================================================================
   主题皮肤：结构样式全部在 common.css，这里只覆盖「变量 + 装饰性规则」。
   切换方式：play.html?style=gold|neon|crimson|ivory|jade
   ========================================================================== */

/* --------------------------------------------------------------------------
   01 鎏金夜宴（默认）
   变量定义在 common.css 的 :root 中，本文件不需要额外覆盖。
   -------------------------------------------------------------------------- */

/* --------------------------------------------------------------------------
   02 霓虹脉冲 NEON：冷色、直角、发光、网格地面
   -------------------------------------------------------------------------- */
html[data-theme="neon"] {
  --accent-1: #eafcff;
  --accent-2: #22e0ff;
  --accent-3: #0fb6d6;
  --accent-4: #0a6d86;
  --accent-rgb: 34, 224, 255;
  --accent-bright: #c9f9ff;
  --glow-rgb: 255, 47, 179;
  --shadow-rgb: 34, 224, 255;
  --grain-rgb: 120, 215, 255;
  --glass-rgb: 120, 220, 255;

  --text: #e8f8ff;
  --muted: rgba(190, 232, 255, .5);
  --text-dim: rgba(190, 232, 255, .62);
  --title-1: #ffffff;
  --hero-1: #ffffff;
  --hero-2: #b6f6ff;
  --hero-3: #22e0ff;
  --hero-4: #ff7ad6;

  --red: #ff2fb3;
  --red-rgb: 255, 47, 179;
  --warn: #ff9ad6;
  --warn-strong: #ffd0ef;
  --warn-gold: #ffd166;
  --ok: #39ffb0;
  --ok-rgb: 57, 255, 176;
  --ok-text: #b5ffe4;

  --bg-0: #10306e;
  --bg-1: #070d24;
  --bg-2: #02030a;
  --bg-solid: #010206;
  --vignette: rgba(0, 0, 0, .72);
  --panel-rgb: 4, 16, 34;
  --panel-solid: #050a15;
  --table-head: #08121f;
  --modal-solid: #050a16;
  --toast-rgb: 6, 16, 28;

  --btn-1: #c9f9ff;
  --btn-2: #22e0ff;
  --btn-3: #0a6d86;
  --btn-ink: #001319;
  --btn2-1: #7bf3ff;
  --btn2-2: #0fb6d6;
  --avatar-1: #e6feff;
  --avatar-2: #22e0ff;
  --avatar-3: #0a6d86;
  --avatar-ink: #001319;

  --radius-slot: 2px;
  --radius-rail: 2px;
  --radius-draw: 2px;
  --radius-panel: 2px;
  --font-display: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --font-num: "SF Mono", ui-monospace, "Roboto Mono", monospace;
}

html[data-theme="neon"] .bg-base {
  background:
    radial-gradient(80% 60% at 12% 0%, #1a4b9e 0%, transparent 58%),
    radial-gradient(70% 55% at 92% 8%, #4d0b45 0%, transparent 55%),
    linear-gradient(170deg, #060b1e 0%, #030614 55%, #010206 100%);
}
html[data-theme="neon"] .bg-glow {
  background: conic-gradient(from 90deg,
    rgba(34, 224, 255, .16), transparent 24%,
    rgba(255, 47, 179, .16) 48%, transparent 72%,
    rgba(123, 107, 255, .16) 86%, transparent 100%);
  filter: blur(70px);
}
html[data-theme="neon"] .bg-grain { opacity: .1; }
html[data-theme="neon"] .bg-vignette {
  background: radial-gradient(closest-side at 50% 42%, transparent 40%, rgba(0, 0, 0, .78) 100%);
}

/* 网格地面 + 扫描线（模板里只在 neon 主题渲染这两个元素） */
.grid-floor {
  position: fixed; left: -25%; right: -25%; bottom: -4vh; height: 42vh;
  z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(34, 224, 255, .3) 1px, transparent 1px),
    linear-gradient(90deg, rgba(34, 224, 255, .3) 1px, transparent 1px);
  background-size: 100% 46px, 62px 100%;
  transform: perspective(620px) rotateX(64deg);
  transform-origin: bottom center;
  -webkit-mask-image: linear-gradient(transparent 8%, #000 65%);
  mask-image: linear-gradient(transparent 8%, #000 65%);
  opacity: .72;
}
.scanlines {
  position: fixed; inset: 0; z-index: 1; pointer-events: none;
  background: repeating-linear-gradient(180deg, rgba(255, 255, 255, .04) 0 1px, transparent 1px 4px);
  mix-blend-mode: overlay; opacity: .5;
}

html[data-theme="neon"] .frame-line { border-color: rgba(34, 224, 255, .22); }
html[data-theme="neon"] .frame-line.inner { border-color: rgba(34, 224, 255, .1); }
html[data-theme="neon"] .corner::before {
  border-color: rgba(34, 224, 255, .8);
  box-shadow: 0 0 14px rgba(34, 224, 255, .55);
}
html[data-theme="neon"] .brand-text h1 {
  background: linear-gradient(96deg, #8ef4ff 0%, #22e0ff 40%, #ff2fb3 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  letter-spacing: .22em;
}
html[data-theme="neon"] .brand-text p { color: rgba(142, 244, 255, .5); letter-spacing: .5em; }
html[data-theme="neon"] .brand-mark {
  border-radius: 2px; border-color: rgba(34, 224, 255, .6); color: #8ef4ff;
  box-shadow: 0 0 22px rgba(34, 224, 255, .28), inset 0 0 16px rgba(34, 224, 255, .12);
}
html[data-theme="neon"] .icon-btn { border-radius: 2px; border-color: rgba(34, 224, 255, .28); color: #8ef4ff; }
html[data-theme="neon"] .conn { border-radius: 2px; border-color: rgba(34, 224, 255, .25); }
html[data-theme="neon"] .stage::before {
  background: radial-gradient(closest-side, rgba(34, 224, 255, .16), transparent 72%);
}
html[data-theme="neon"] .prize-name {
  filter: drop-shadow(0 0 46px rgba(34, 224, 255, .4));
  letter-spacing: .1em;
}
html[data-theme="neon"] .tag { color: #8ef4ff; border-color: rgba(34, 224, 255, .4); background: rgba(34, 224, 255, .08); }
html[data-theme="neon"] .fact-v { color: #c9f9ff; text-shadow: 0 0 26px rgba(34, 224, 255, .45); }
html[data-theme="neon"] kbd { border-color: rgba(34, 224, 255, .5); color: #c9f9ff; background: rgba(34, 224, 255, .1); }

html[data-theme="neon"] .slot {
  background: linear-gradient(180deg, rgba(34, 224, 255, .075), rgba(34, 224, 255, .012));
  border-color: rgba(34, 224, 255, .22);
}
html[data-theme="neon"] .slot.revealed {
  border-color: rgba(34, 224, 255, .8);
  background: linear-gradient(180deg, rgba(34, 224, 255, .14), rgba(34, 224, 255, .02));
  box-shadow: 0 0 52px rgba(34, 224, 255, .28), inset 0 0 36px rgba(34, 224, 255, .1);
}
html[data-theme="neon"] .roller-name { color: #c9f9ff; text-shadow: 0 0 32px rgba(34, 224, 255, .5); }
html[data-theme="neon"] .w-name { color: #eafcff; text-shadow: 0 0 30px rgba(34, 224, 255, .65); }
html[data-theme="neon"] .w-dept { color: rgba(190, 232, 255, .55); }
html[data-theme="neon"] .avatar {
  border-radius: 2px;
  background: linear-gradient(150deg, #d6feff, #22e0ff 55%, #0a6d86);
  box-shadow: 0 0 0 1px rgba(34, 224, 255, .4), 0 0 30px rgba(34, 224, 255, .35);
}

html[data-theme="neon"] .rail {
  background: linear-gradient(180deg, rgba(4, 16, 34, .78), rgba(3, 8, 18, .45));
  border-color: rgba(34, 224, 255, .2);
}
html[data-theme="neon"] .rail-title { color: rgba(142, 244, 255, .55); }
html[data-theme="neon"] .rail-item { border-radius: 2px; border-color: rgba(34, 224, 255, .12); }
html[data-theme="neon"] .rail-item.active {
  border-color: rgba(34, 224, 255, .65);
  background: rgba(34, 224, 255, .08);
  box-shadow: 0 0 30px rgba(34, 224, 255, .18), inset 0 0 20px rgba(34, 224, 255, .06);
}
html[data-theme="neon"] .rail-name { color: #b6f6ff; }
html[data-theme="neon"] .bar { background: rgba(34, 224, 255, .12); height: 3px; }
html[data-theme="neon"] .bar i { background: linear-gradient(90deg, #0fb6d6, #22e0ff); box-shadow: 0 0 12px rgba(34, 224, 255, .6); }

html[data-theme="neon"] .btn { border-radius: 2px; border-color: rgba(34, 224, 255, .25); }
html[data-theme="neon"] .btn:hover:not(:disabled) { border-color: rgba(34, 224, 255, .7); background: rgba(34, 224, 255, .1); color: #c9f9ff; }
html[data-theme="neon"] .btn.gold { background: linear-gradient(100deg, #22e0ff, #7b6bff); color: #00121a; }
html[data-theme="neon"] .draw-btn {
  border-radius: 0;
  clip-path: polygon(16px 0, 100% 0, 100% calc(100% - 16px), calc(100% - 16px) 100%, 0 100%, 0 16px);
  background: linear-gradient(100deg, #22e0ff 0%, #7b6bff 52%, #ff2fb3 100%);
  color: #00121a;
  letter-spacing: .28em;
  box-shadow: 0 14px 48px rgba(34, 224, 255, .45), inset 0 1px 0 rgba(255, 255, 255, .45);
}
html[data-theme="neon"] .draw-btn.armed { animation: none; box-shadow: 0 14px 48px rgba(34, 224, 255, .45), 0 0 0 1px rgba(34, 224, 255, .4), inset 0 1px 0 rgba(255, 255, 255, .45); }
html[data-theme="neon"] .draw-btn::after { background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .85), transparent); }

html[data-theme="neon"] .drawer { border-left-color: rgba(34, 224, 255, .3); }
html[data-theme="neon"] .tab.active { border-bottom-color: #22e0ff; color: #c9f9ff; }
html[data-theme="neon"] .input, html[data-theme="neon"] .cell-input { border-radius: 2px; }
html[data-theme="neon"] .input:focus { border-color: rgba(34, 224, 255, .65); background: rgba(34, 224, 255, .08); }
html[data-theme="neon"] .track { border-radius: 2px; }
html[data-theme="neon"] .track i { border-radius: 1px; }
html[data-theme="neon"] .track.on { background: linear-gradient(90deg, #0fb6d6, #22e0ff); }
html[data-theme="neon"] .ov-card { border-color: rgba(34, 224, 255, .4); box-shadow: 0 30px 90px rgba(0, 0, 0, .7), 0 0 60px rgba(34, 224, 255, .12); }
html[data-theme="neon"] .toast { border-color: rgba(34, 224, 255, .35); }

/* --------------------------------------------------------------------------
   03 国潮红金 CRIMSON：大红底 + 亮金 + 圆润卡片
   -------------------------------------------------------------------------- */
html[data-theme="crimson"] {
  --accent-1: #fff2c8;
  --accent-2: #ffd66b;
  --accent-3: #e0a63c;
  --accent-4: #8a5a10;
  --accent-rgb: 255, 214, 107;
  --accent-bright: #ffe9a3;
  --glow-rgb: 255, 214, 107;
  --shadow-rgb: 255, 190, 80;
  --grain-rgb: 255, 235, 190;
  --glass-rgb: 255, 235, 190;

  --text: #fff4e2;
  --muted: rgba(255, 240, 220, .6);
  --text-dim: rgba(255, 240, 220, .68);
  --title-1: #fffbe9;
  --hero-1: #fffaea;
  --hero-2: #ffe9a8;
  --hero-3: #ffc94f;
  --hero-4: #fff4cf;

  --red: #ff5a63;
  --red-rgb: 255, 90, 99;
  --warn: #ffb9a6;
  --warn-strong: #ffdccd;
  --warn-gold: #ffe3ae;

  --bg-0: #c0142c;
  --bg-1: #870c1d;
  --bg-2: #4a0510;
  --bg-solid: #3a030c;
  --vignette: rgba(40, 0, 6, .6);
  --panel-rgb: 120, 14, 30;
  --panel-solid: #56070f;
  --table-head: #6d0a16;
  --modal-solid: #4d060e;
  --toast-rgb: 74, 6, 16;

  --btn-1: #fff0bb;
  --btn-2: #ffd66b;
  --btn-3: #d99a2b;
  --btn-ink: #4a1a02;
  --btn2-1: #ffe9a8;
  --btn2-2: #f2b942;
  --avatar-1: #fff6d8;
  --avatar-2: #ffd66b;
  --avatar-3: #a86a12;
  --avatar-ink: #47180a;

  --radius-slot: clamp(16px, 1.6vw, 26px);
  --radius-rail: 24px;
  --radius-panel: 22px;
  --font-display: "Songti SC", "STSong", "Source Han Serif SC", serif;
}

html[data-theme="crimson"] .bg-base {
  background:
    radial-gradient(120% 95% at 50% -6%, #f4263f 0%, #cf1a31 30%, #8f1022 64%, #4a0510 100%);
}
html[data-theme="crimson"] .bg-glow {
  background: conic-gradient(from 30deg,
    rgba(255, 214, 107, .22), transparent 26%,
    rgba(255, 240, 200, .12) 48%, transparent 72%,
    rgba(255, 214, 107, .22));
  filter: blur(56px); opacity: .85;
}
html[data-theme="crimson"] .bg-grain {
  opacity: .26;
  background-image:
    radial-gradient(rgba(255, 214, 107, .55) 1px, transparent 1px),
    radial-gradient(rgba(255, 255, 255, .35) 1px, transparent 1px);
  background-size: 22px 22px, 11px 11px;
  background-position: 0 0, 6px 6px;
}
html[data-theme="crimson"] .bg-vignette {
  background: radial-gradient(closest-side at 50% 42%, transparent 60%, rgba(58, 3, 12, .62) 100%);
}
html[data-theme="crimson"] .frame-line { border-color: rgba(255, 214, 107, .38); }
html[data-theme="crimson"] .frame-line.inner { border-color: rgba(255, 214, 107, .16); }
html[data-theme="crimson"] .corner::before {
  border-color: rgba(255, 214, 107, .8);
  box-shadow: 0 0 18px rgba(255, 214, 107, .35);
}
html[data-theme="crimson"] .brand-text h1 {
  background: linear-gradient(180deg, #fffdf2, #ffd66b 58%, #e8a52e);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  font-weight: 700;
}
html[data-theme="crimson"] .brand-mark {
  border-color: rgba(255, 214, 107, .7);
  background: radial-gradient(circle at 35% 30%, rgba(255, 236, 180, .3), rgba(255, 214, 107, .06));
  box-shadow: 0 0 26px rgba(255, 214, 107, .3);
}
html[data-theme="crimson"] .slot {
  border-color: rgba(255, 214, 107, .28);
  background: linear-gradient(180deg, rgba(255, 236, 190, .1), rgba(255, 214, 107, .03));
}
html[data-theme="crimson"] .slot.revealed {
  border-color: rgba(255, 226, 150, .9);
  background: linear-gradient(180deg, rgba(255, 226, 150, .2), rgba(255, 120, 90, .06));
  box-shadow: 0 0 0 1px rgba(255, 240, 200, .18) inset, 0 0 56px rgba(255, 214, 107, .26);
}
html[data-theme="crimson"] .w-name { color: #fff8e4; text-shadow: 0 2px 26px rgba(255, 190, 80, .55); }
html[data-theme="crimson"] .avatar {
  background: radial-gradient(circle at 34% 28%, #fffbe8, #ffd66b 52%, #b7791a);
  box-shadow: 0 0 0 3px rgba(255, 240, 200, .25), 0 10px 30px rgba(70, 4, 12, .5);
}
html[data-theme="crimson"] .rail {
  background: linear-gradient(180deg, rgba(130, 16, 32, .72), rgba(80, 8, 18, .5));
  border-color: rgba(255, 214, 107, .3);
}
html[data-theme="crimson"] .rail-item.active {
  border-color: rgba(255, 226, 150, .75);
  background: rgba(255, 214, 107, .14);
  box-shadow: 0 0 30px rgba(255, 214, 107, .2);
}
html[data-theme="crimson"] .prize-name {
  filter: drop-shadow(0 6px 40px rgba(255, 190, 80, .4));
  font-weight: 700;
}
html[data-theme="crimson"] .draw-btn {
  background: linear-gradient(180deg, #fff4c8 0%, #ffd66b 45%, #e09a24 100%);
  box-shadow: 0 16px 48px rgba(255, 170, 50, .45), inset 0 2px 0 rgba(255, 255, 255, .85);
}
html[data-theme="crimson"] .toast { background: rgba(74, 6, 16, .94); }

/* --------------------------------------------------------------------------
   04 素白雅致 IVORY：浅底、深墨、细金线、极简
   -------------------------------------------------------------------------- */
html[data-theme="ivory"] {
  --accent-1: #241c12;
  --accent-2: #a8843f;
  --accent-3: #8a6a2f;
  --accent-4: #5c4520;
  --accent-rgb: 154, 123, 63;
  --accent-bright: #3a2c18;
  --glow-rgb: 214, 190, 140;
  --shadow-rgb: 120, 96, 50;
  --grain-rgb: 90, 70, 40;
  --glass-rgb: 40, 30, 15;

  --text: #221b14;
  --muted: rgba(34, 27, 20, .5);
  --text-dim: rgba(34, 27, 20, .6);
  --title-1: #2b2114;
  --hero-1: #1f1810;
  --hero-2: #7d5c26;
  --hero-3: #3c2d17;
  --hero-4: #a8843f;

  --red: #b03a3a;
  --red-rgb: 176, 58, 58;
  --warn: #9d2f33;
  --warn-strong: #7a1f22;
  --warn-gold: #8a6a2f;
  --ok: #2f7a52;
  --ok-rgb: 47, 122, 82;
  --ok-text: #1f5c3d;

  --bg-0: #fdfaf3;
  --bg-1: #f5eee1;
  --bg-2: #e9dfcd;
  --bg-solid: #f4eee3;
  --vignette: rgba(74, 56, 30, .16);
  --shadow-strong: rgba(60, 45, 25, .18);
  --shadow-soft: rgba(60, 45, 25, .12);
  --mask: rgba(30, 22, 12, .45);
  --mask-strong: rgba(30, 22, 12, .6);
  --panel-rgb: 255, 252, 244;
  --panel-solid: #fffdf8;
  --table-head: #efe4d0;
  --modal-solid: #fffdf8;
  --toast-rgb: 255, 250, 240;

  --btn-1: #3a2d1b;
  --btn-2: #241c12;
  --btn-3: #120d08;
  --btn-ink: #f8f1de;
  --btn2-1: #c9a75f;
  --btn2-2: #a8843f;
  --avatar-1: #3a2d1b;
  --avatar-2: #241c12;
  --avatar-3: #0f0b07;
  --avatar-ink: #f8f1de;

  --radius-slot: 6px;
  --radius-rail: 10px;
  --radius-panel: 12px;
  --font-display: "Songti SC", "STSong", "Source Han Serif SC", serif;
}

html[data-theme="ivory"] .bg-base {
  background:
    radial-gradient(120% 90% at 50% -10%, #fffdf7 0%, #f7f0e3 38%, #efe5d4 70%, #e6dac6 100%);
}
html[data-theme="ivory"] .bg-glow {
  background: conic-gradient(from 0deg,
    rgba(214, 190, 140, .28), transparent 28%,
    rgba(176, 140, 84, .18) 55%, transparent 78%,
    rgba(214, 190, 140, .28));
  filter: blur(70px); opacity: .5;
}
html[data-theme="ivory"] .bg-grain { opacity: .1; }
html[data-theme="ivory"] .bg-vignette {
  background: radial-gradient(closest-side at 50% 45%, transparent 52%, rgba(90, 70, 40, .18) 100%);
}
html[data-theme="ivory"] .frame-line { border-color: rgba(120, 96, 50, .28); }
html[data-theme="ivory"] .frame-line.inner { border-color: rgba(120, 96, 50, .14); }
html[data-theme="ivory"] .corner::before { border-color: rgba(120, 96, 50, .45); }

html[data-theme="ivory"] .brand-mark {
  border-color: rgba(120, 96, 50, .4);
  background: radial-gradient(circle at 35% 30%, rgba(200, 176, 120, .22), rgba(200, 176, 120, .04));
  box-shadow: none;
  color: #8a6a2f;
}
html[data-theme="ivory"] .icon-btn {
  background: rgba(255, 255, 255, .55);
  border-color: rgba(120, 96, 50, .25);
  color: #6b5326;
}
html[data-theme="ivory"] .icon-btn:hover { background: #fff; border-color: rgba(120, 96, 50, .5); }
html[data-theme="ivory"] .conn { background: rgba(255, 255, 255, .5); border-color: rgba(120, 96, 50, .25); color: #6b5326; }
html[data-theme="ivory"] .clock { color: rgba(34, 27, 20, .55); }

html[data-theme="ivory"] .stage::before {
  background: radial-gradient(closest-side, rgba(214, 190, 140, .3), transparent 72%);
}
html[data-theme="ivory"] .tag {
  color: #7a5f2a; border-color: rgba(120, 96, 50, .35); background: rgba(255, 255, 255, .7);
}
html[data-theme="ivory"] .tag.dim { color: rgba(34, 27, 20, .5); background: transparent; }
html[data-theme="ivory"] .prize-name { filter: drop-shadow(0 6px 24px rgba(150, 120, 70, .18)); }
html[data-theme="ivory"] .fact-k { color: rgba(34, 27, 20, .5); }
html[data-theme="ivory"] .idle-hint { color: rgba(34, 27, 20, .55); }
html[data-theme="ivory"] kbd { border-color: rgba(120, 96, 50, .4); background: #fff; color: #5c4520; }

html[data-theme="ivory"] .slot {
  background: linear-gradient(180deg, #fffdf8, #f8f0e2);
  border-color: rgba(120, 96, 50, .2);
  box-shadow: 0 8px 26px rgba(80, 60, 30, .08);
}
html[data-theme="ivory"] .slot.revealed {
  border-color: rgba(120, 96, 50, .55);
  background: linear-gradient(180deg, #fffefb, #fbf3e6);
  box-shadow: 0 16px 46px rgba(80, 60, 30, .16), inset 0 0 0 1px rgba(255, 255, 255, .8);
}
html[data-theme="ivory"] .slot::after {
  background: linear-gradient(115deg, transparent 32%, rgba(255, 255, 255, .9) 48%, transparent 62%);
}
html[data-theme="ivory"] .roller-name { color: #3a2c18; text-shadow: none; }
html[data-theme="ivory"] .w-name { color: #241c12; text-shadow: none; }
html[data-theme="ivory"] .w-dept { color: rgba(34, 27, 20, .55); }
html[data-theme="ivory"] .w-star { color: #a8843f; }
html[data-theme="ivory"] .avatar {
  background: radial-gradient(circle at 34% 28%, #4a3a22, #241c12 58%, #0d0906);
  color: #f8f1de;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, .85), 0 8px 20px rgba(60, 45, 25, .25);
}

html[data-theme="ivory"] .rail {
  background: rgba(255, 253, 247, .82);
  border-color: rgba(120, 96, 50, .22);
  box-shadow: 0 18px 50px rgba(80, 60, 30, .1);
}
html[data-theme="ivory"] .rail-item { background: rgba(255, 255, 255, .5); }
html[data-theme="ivory"] .rail-item:hover { background: rgba(255, 255, 255, .9); }
html[data-theme="ivory"] .rail-item.active {
  border-color: rgba(120, 96, 50, .5);
  background: rgba(212, 190, 145, .2);
  box-shadow: 0 0 24px rgba(150, 120, 70, .12);
}
html[data-theme="ivory"] .rail-name { color: #2a2118; }
html[data-theme="ivory"] .rail-num { color: rgba(34, 27, 20, .5); }
html[data-theme="ivory"] .bar { background: rgba(34, 27, 20, .1); }
html[data-theme="ivory"] .bar i { background: linear-gradient(90deg, #c9a75f, #8a6a2f); }
html[data-theme="ivory"] .rail-foot { color: rgba(34, 27, 20, .5); border-top-color: rgba(120, 96, 50, .2); }

html[data-theme="ivory"] .btn {
  background: rgba(255, 255, 255, .7);
  border-color: rgba(120, 96, 50, .28);
  color: #2a2118;
}
html[data-theme="ivory"] .btn:hover:not(:disabled) { background: #fff; border-color: rgba(120, 96, 50, .55); color: #120d08; }
html[data-theme="ivory"] .btn.gold { background: linear-gradient(180deg, #d3b473, #a8843f); color: #241c12; border-color: transparent; }
html[data-theme="ivory"] .draw-btn {
  background: linear-gradient(180deg, #3a2d1b, #16100a);
  color: #f9f2e0;
  box-shadow: 0 16px 44px rgba(60, 45, 25, .28), inset 0 1px 0 rgba(255, 255, 255, .18);
}
html[data-theme="ivory"] .draw-btn.armed { animation: none; box-shadow: 0 16px 44px rgba(60, 45, 25, .3), 0 0 0 1px rgba(120, 96, 50, .35); }
html[data-theme="ivory"] .draw-btn::after { background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .18), transparent); }

html[data-theme="ivory"] .demo-banner {
  background: rgba(255, 252, 244, .95);
  border-color: rgba(120, 96, 50, .35);
  color: #6b5326;
}
html[data-theme="ivory"] .demo-banner button { color: #5c4520; }

html[data-theme="ivory"] .drawer {
  background: #fdfaf4;
  border-left-color: rgba(120, 96, 50, .25);
  box-shadow: -30px 0 80px rgba(60, 45, 25, .2);
}
html[data-theme="ivory"] .drawer-head { border-bottom-color: rgba(120, 96, 50, .18); }
html[data-theme="ivory"] .drawer-head h2 { color: #2a2118; }
html[data-theme="ivory"] .tabs { border-bottom-color: rgba(120, 96, 50, .18); }
html[data-theme="ivory"] .tab { color: rgba(34, 27, 20, .55); }
html[data-theme="ivory"] .tab.active { color: #241c12; border-bottom-color: #a8843f; }
html[data-theme="ivory"] .input, html[data-theme="ivory"] .cell-input {
  background: rgba(255, 255, 255, .8);
  border-color: rgba(120, 96, 50, .22);
  color: #241c12;
}
html[data-theme="ivory"] .input:focus { border-color: rgba(120, 96, 50, .55); background: #fff; }
html[data-theme="ivory"] .table-wrap { background: rgba(255, 255, 255, .6); border-color: rgba(120, 96, 50, .2); }
html[data-theme="ivory"] table.table thead th { background: #f3e9d6; color: rgba(34, 27, 20, .55); border-bottom-color: rgba(120, 96, 50, .2); }
html[data-theme="ivory"] table.table td { border-bottom-color: rgba(120, 96, 50, .1); }
html[data-theme="ivory"] table.table tbody tr:hover { background: rgba(212, 190, 145, .16); }
html[data-theme="ivory"] .pill { border-color: rgba(120, 96, 50, .25); color: rgba(34, 27, 20, .5); }
html[data-theme="ivory"] .pill.ok { color: #4a3413; border-color: rgba(120, 96, 50, .5); background: rgba(212, 190, 145, .3); }
html[data-theme="ivory"] .mini { border-color: rgba(120, 96, 50, .25); color: rgba(34, 27, 20, .55); }
html[data-theme="ivory"] .mini:hover { color: #241c12; border-color: rgba(120, 96, 50, .5); }
html[data-theme="ivory"] .prize-editor, html[data-theme="ivory"] .record { border-color: rgba(120, 96, 50, .2); background: rgba(255, 255, 255, .55); }
html[data-theme="ivory"] .chip { background: rgba(212, 190, 145, .25); border-color: rgba(120, 96, 50, .25); color: #241c12; }
html[data-theme="ivory"] .switch { border-bottom-color: rgba(120, 96, 50, .15); }
html[data-theme="ivory"] .track { background: rgba(34, 27, 20, .14); border-color: rgba(120, 96, 50, .2); }
html[data-theme="ivory"] .track i { background: #fffdf8; }
html[data-theme="ivory"] .track.on { background: linear-gradient(90deg, #a8843f, #d3b473); }
html[data-theme="ivory"] .notice { color: rgba(34, 27, 20, .5); }
html[data-theme="ivory"] .notice code { color: #5c4520; background: rgba(212, 190, 145, .25); }

html[data-theme="ivory"] .ov-card { background: #fffdf8; border-color: rgba(120, 96, 50, .3); box-shadow: 0 30px 80px rgba(60, 45, 25, .25); }
html[data-theme="ivory"] .ov-body textarea { background: #fff; border-color: rgba(120, 96, 50, .25); color: #241c12; }
html[data-theme="ivory"] .ov-preview { border-color: rgba(120, 96, 50, .2); }
html[data-theme="ivory"] .ov-preview th { color: rgba(34, 27, 20, .5); }
html[data-theme="ivory"] .toast { background: rgba(255, 252, 244, .96); border-color: rgba(120, 96, 50, .3); color: #241c12; box-shadow: 0 12px 36px rgba(60, 45, 25, .18); }
html[data-theme="ivory"] .toast.success { color: #1f5c3d; border-color: rgba(var(--ok-rgb), .5); }
html[data-theme="ivory"] .toast.error { color: #9d2f33; border-color: rgba(var(--red-rgb), .5); }
html[data-theme="ivory"] .toast.warn { color: #7a5f2a; border-color: rgba(120, 96, 50, .45); }

/* --------------------------------------------------------------------------
   05 青玉竹影 JADE：深青底 + 竹青金，清冷
   -------------------------------------------------------------------------- */
html[data-theme="jade"] {
  --accent-1: #eafff7;
  --accent-2: #8fe8c9;
  --accent-3: #49b79a;
  --accent-4: #1f6b58;
  --accent-rgb: 143, 232, 201;
  --accent-bright: #c6fbe8;
  --glow-rgb: 143, 232, 201;
  --shadow-rgb: 143, 232, 201;
  --grain-rgb: 200, 255, 235;
  --glass-rgb: 160, 255, 220;

  --text: #eafaf4;
  --muted: rgba(226, 250, 242, .55);
  --text-dim: rgba(226, 250, 242, .65);
  --title-1: #f4fffb;
  --hero-1: #f4fffb;
  --hero-2: #c6fbe8;
  --hero-3: #6fd9b8;
  --hero-4: #ffe9a8;

  --red: #ff7a6b;
  --red-rgb: 255, 122, 107;
  --warn: #ffc3b8;
  --warn-strong: #ffdccd;
  --warn-gold: #ffe3ae;

  --bg-0: #14524a;
  --bg-1: #0a2a25;
  --bg-2: #04120f;
  --bg-solid: #030b09;
  --vignette: rgba(0, 10, 8, .68);
  --panel-rgb: 10, 40, 34;
  --panel-solid: #071712;
  --table-head: #0a211b;
  --modal-solid: #07150f;
  --toast-rgb: 6, 26, 21;

  --btn-1: #d9fff0;
  --btn-2: #8fe8c9;
  --btn-3: #3f9c83;
  --btn-ink: #04231b;
  --btn2-1: #b6ffe6;
  --btn2-2: #5fd3b1;
  --avatar-1: #eafff7;
  --avatar-2: #8fe8c9;
  --avatar-3: #2c7f68;
  --avatar-ink: #04231b;

  --radius-slot: clamp(14px, 1.3vw, 20px);
  --radius-rail: 16px;
  --font-display: "Songti SC", "STSong", "Source Han Serif SC", serif;
}

html[data-theme="jade"] .bg-base {
  background:
    radial-gradient(100% 80% at 50% -10%, #1c6b5c 0%, #0d3a33 38%, #06201c 70%, #030b09 100%);
}
html[data-theme="jade"] .bg-glow {
  background: conic-gradient(from 200deg,
    rgba(143, 232, 201, .16), transparent 30%,
    rgba(255, 233, 168, .1) 55%, transparent 80%,
    rgba(143, 232, 201, .16));
  filter: blur(60px);
}
html[data-theme="jade"] .bg-grain { opacity: .14; }
html[data-theme="jade"] .bg-vignette {
  background: radial-gradient(closest-side at 50% 42%, transparent 44%, rgba(0, 12, 9, .78) 100%);
}
html[data-theme="jade"] .frame-line { border-color: rgba(143, 232, 201, .25); }
html[data-theme="jade"] .frame-line.inner { border-color: rgba(143, 232, 201, .1); }
html[data-theme="jade"] .corner::before { border-color: rgba(143, 232, 201, .6); box-shadow: 0 0 16px rgba(143, 232, 201, .3); }
html[data-theme="jade"] .brand-text h1 {
  background: linear-gradient(180deg, #f6fffc, #8fe8c9 58%, #3f9c83);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
html[data-theme="jade"] .brand-mark { border-color: rgba(143, 232, 201, .55); color: #c6fbe8; }
html[data-theme="jade"] .slot {
  background: linear-gradient(180deg, rgba(143, 232, 201, .08), rgba(143, 232, 201, .012));
  border-color: rgba(143, 232, 201, .22);
}
html[data-theme="jade"] .slot.revealed {
  border-color: rgba(143, 232, 201, .8);
  background: linear-gradient(180deg, rgba(143, 232, 201, .16), rgba(143, 232, 201, .03));
  box-shadow: 0 0 48px rgba(143, 232, 201, .24), inset 0 0 32px rgba(143, 232, 201, .08);
}
html[data-theme="jade"] .w-name { color: #f2fffa; text-shadow: 0 0 30px rgba(143, 232, 201, .5); }
html[data-theme="jade"] .avatar {
  background: radial-gradient(circle at 34% 28%, #f2fffa, #8fe8c9 55%, #2c7f68);
  color: #04231b;
}
html[data-theme="jade"] .rail {
  background: linear-gradient(180deg, rgba(10, 40, 34, .7), rgba(4, 18, 15, .4));
  border-color: rgba(143, 232, 201, .22);
}
html[data-theme="jade"] .rail-item.active {
  border-color: rgba(143, 232, 201, .65);
  background: rgba(143, 232, 201, .1);
  box-shadow: 0 0 28px rgba(143, 232, 201, .18);
}
html[data-theme="jade"] .draw-btn {
  background: linear-gradient(180deg, #eafdf6 0%, #8fe8c9 45%, #3f9c83 100%);
  color: #04231b;
  box-shadow: 0 14px 44px rgba(143, 232, 201, .3), inset 0 1px 0 rgba(255, 255, 255, .8);
}
html[data-theme="jade"] .drawer { border-left-color: rgba(143, 232, 201, .25); }
html[data-theme="jade"] .tab.active { border-bottom-color: #8fe8c9; }
