/* Cromo theme: polished chrome, near-black graphite and hot red, to match the Era Clash logo.
   theme.js re-tones every existing colour at runtime (gold → chrome, wine → red, dark panels → graphite);
   this file holds the design tokens and the hand-tuned spots. Everything is scoped to html[data-theme="cromo"]. */

/* picker swatch (shown in every theme) */
.theme-cromo .theme-swatch {
  background:
    radial-gradient(circle at 50% 55%, rgb(255 40 56 / .85), transparent 38%),
    linear-gradient(160deg, #f4f6f9 0%, #9aa2ae 32%, #2a2d33 50%, #c8ced6 70%, #6c737e 100%);
  box-shadow: inset 0 0 0 2px #e3e7ec, inset 0 0 0 4px #1a1b1f, 0 0 12px -2px rgb(255 30 50 / .6);
}

html[data-theme="cromo"]:not(.theme-ready) body { opacity: 0; }
html[data-theme="cromo"] body { transition: opacity .25s ease; }

html[data-theme="cromo"] {
  color-scheme: dark;
  --cr-black: #08080a;
  --cr-graphite: #141519;
  --cr-graphite-2: #1d1f24;
  --cr-chrome: #c9cfd8;
  --cr-chrome-hi: #f3f5f8;
  --cr-chrome-lo: #7d8591;
  --cr-red: #ff2338;
  --cr-red-deep: #a80f1f;
  --cr-red-glow: rgb(255 35 56 / .55);
  --cr-chrome-grad: linear-gradient(180deg, #ffffff 0%, #d7dce3 22%, #8c939e 48%, #e9ecf0 62%, #a9b0ba 82%, #f6f7f9 100%);

  --ec-ink-0: #08080a;
  --ec-ink-1: #101114;
  --ec-ink-2: #17181c;
  --ec-ink-3: #202228;
  --ec-wine: #7a0c18;
  --ec-wine-hi: #c4142a;
  --ec-gold-hi: #eef1f5;
  --ec-gold: #c9cfd8;
  --ec-gold-lo: #8a919c;
  --ec-text: #f1f3f6;
  --ec-text-2: #c2c7cf;
  --ec-text-3: #8d939d;
  --ec-right: #3ccf6a;
  --ec-wrong: #ff3347;
  --ec-line: rgb(201 207 216 / .16);
  --ec-line-2: rgb(201 207 216 / .3);
  --ec-line-3: rgb(201 207 216 / .55);
  --ec-glass: linear-gradient(180deg, rgb(32 34 40 / .92), rgb(14 15 18 / .92));
  --ec-glass-fill: rgb(20 21 25 / .9);
  --ec-shadow-1: inset 0 1px 0 rgb(255 255 255 / .08), 0 1px 0 rgb(0 0 0 / .6), 0 12px 30px -16px rgb(0 0 0 / .8);
  --ec-shadow-2: inset 0 1px 0 rgb(255 255 255 / .1), 0 1px 0 rgb(0 0 0 / .7), 0 24px 56px -22px rgb(0 0 0 / .9);
  --ec-glow-gold: 0 0 0 1px rgb(255 35 56 / .6), 0 10px 30px -10px var(--cr-red-glow);
  --ui-ink: #f1f3f6;
  --ui-field: rgb(10 10 12 / .85);
  --ui-field-border: rgb(201 207 216 / .35);
  --menu-ink: #0e0f12;
  --menu-text: #f1f3f6;
  --menu-muted: #9aa1ab;
  --menu-accent: #ff4152;
  --who-cream: #16171b;
  --who-cream-ink: #f1f3f6;
  --who-screen: #0c0d10;
  --em-glass: rgb(14 15 18 / .86);
  --em-glass-hi: rgb(24 26 31 / .94);
  --em-edge: rgb(201 207 216 / .28);
  --arena-background: radial-gradient(ellipse at 46% 43%, #2a0d12, #111215 60%, #060607 92%);
  --arena-panel: linear-gradient(145deg, #1d1f24, #0e0f12);
  --arena-gold: #c9cfd8;
  --arena-text: #f1f3f6;
  scrollbar-color: #5b616b transparent;
}

/* ------------------------------------------------------------- the backdrop: black, with a red core like the logo's globe */
html[data-theme="cromo"],
html[data-theme="cromo"] body { background-color: var(--cr-black) !important; color: #f1f3f6; }
html[data-theme="cromo"] body.roman-menu { background: transparent !important; }
html[data-theme="cromo"] body.roman-menu::before,
html[data-theme="cromo"] body.roman-menu.home-view::before {
  display: block !important; animation: none !important; transform: none !important; opacity: 1 !important;
  background:
    radial-gradient(70vmax 45vmax at 50% 108%, rgb(200 16 34 / .34), transparent 64%),
    radial-gradient(60vmax 40vmax at 50% -18%, rgb(255 255 255 / .07), transparent 60%),
    repeating-linear-gradient(115deg, rgb(255 255 255 / .012) 0 2px, transparent 2px 6px),
    linear-gradient(180deg, #111216, #070708 70%) !important;
}
html[data-theme="cromo"] body.roman-menu::after,
html[data-theme="cromo"] body.roman-menu.home-view::after { opacity: .35 !important; }
html[data-theme="cromo"] .ec-cursor-light { background: radial-gradient(circle, rgb(255 35 56 / .1), transparent 62%); }

/* ------------------------------------------------------------- header & footer: black slab, chrome rail over a red glow */
html[data-theme="cromo"] body > header {
  background: linear-gradient(180deg, #1b1c21, #0b0b0d) !important;
  -webkit-backdrop-filter: none !important; backdrop-filter: none !important;
  border-bottom: 0 !important;
  box-shadow: 0 1px 0 #f3f5f8, 0 2px 0 #7d8591, 0 3px 0 var(--cr-red), 0 10px 28px -6px var(--cr-red-glow) !important;
}
html[data-theme="cromo"] body > footer {
  background: linear-gradient(0deg, #1b1c21, #0b0b0d) !important;
  border-top: 0 !important;
  box-shadow: 0 -1px 0 #f3f5f8, 0 -2px 0 #7d8591, 0 -3px 0 var(--cr-red), 0 -10px 28px -10px var(--cr-red-glow) !important;
  color: #aab0ba !important;
}
html[data-theme="cromo"] :is(.wordmark, .footer-logo) { filter: drop-shadow(0 0 10px rgb(255 35 56 / .45)); }

/* ------------------------------------------------------------- headings: polished chrome lettering with a red edge */
html[data-theme="cromo"] body.roman-menu main h1 {
  background: var(--cr-chrome-grad) !important;
  -webkit-background-clip: text !important; background-clip: text !important; color: transparent !important;
  filter: drop-shadow(0 1px 0 #3a0a10) drop-shadow(0 0 14px rgb(255 35 56 / .35));
}
html[data-theme="cromo"] body.roman-menu main :is(h2, h3) { color: #f1f3f6 !important; }
html[data-theme="cromo"] :is(.roman-eyebrow, .ec-eyebrow) { color: #ff4152 !important; }
html[data-theme="cromo"] body.roman-menu main > .roman-page > header:first-of-type::after,
html[data-theme="cromo"] .settings-head::after {
  content: ""; display: block; height: 2px; margin: 14px auto 0; max-width: 300px;
  background: linear-gradient(90deg, transparent, #c9cfd8 20%, var(--cr-red) 50%, #c9cfd8 80%, transparent);
  box-shadow: 0 0 12px var(--cr-red-glow);
}

/* ------------------------------------------------------------- buttons: chrome bar, black lettering, red glow */
html[data-theme="cromo"] .hub-arena-cta .is-primary,
html[data-theme="cromo"] :is(.roman-primary, .primary, button.primary) {
  background: var(--cr-chrome-grad) !important;
  color: #121317 !important; border-color: #5a0a14 !important;
  box-shadow: inset 0 1px 0 #fff, 0 0 0 1px #2a0a0e, 0 0 0 2px rgb(255 35 56 / .7), 0 8px 22px -8px var(--cr-red-glow) !important;
  text-shadow: 0 1px 0 rgb(255 255 255 / .6) !important;
}
html[data-theme="cromo"] .hub-arena-cta .is-primary * { color: #121317 !important; }
html[data-theme="cromo"] :is(.roman-primary, .primary, button.primary):hover {
  box-shadow: inset 0 1px 0 #fff, 0 0 0 1px #2a0a0e, 0 0 0 2px var(--cr-red), 0 10px 30px -6px rgb(255 35 56 / .75) !important;
}
html[data-theme="cromo"] .hub-arena { border: 1px solid #7d8591 !important; box-shadow: 0 0 0 1px #000, 0 0 0 3px #c9cfd8, 0 0 34px -8px var(--cr-red-glow) !important; }
html[data-theme="cromo"] .hub-arena .hub-eyebrow { color: #ff4152 !important; }
html[data-theme="cromo"] .lx { --gold: #d7dce3; --gold-2: #9aa1ab; }

/* home dailies: graphite plates with a chrome rim */
html[data-theme="cromo"] .hub-daily {
  border: 1px solid rgb(201 207 216 / .35) !important;
  background: linear-gradient(180deg, #1d1f24, #0f1013) !important;
  box-shadow: inset 0 1px 0 rgb(255 255 255 / .08), 0 16px 32px -22px #000 !important;
}
html[data-theme="cromo"] .hub-daily:hover { box-shadow: inset 0 1px 0 rgb(255 255 255 / .1), 0 0 0 1px var(--cr-red), 0 14px 32px -14px var(--cr-red-glow) !important; }
html[data-theme="cromo"] .hub-daily-kicker { color: #ff4152 !important; }
html[data-theme="cromo"] .hub-daily-go { background: var(--cr-chrome-grad) !important; color: #121317 !important; }

/* loading screen quote panel */
html[data-theme="cromo"] .loading-quote figcaption {
  border: 1px solid #7d8591 !important;
  background: linear-gradient(180deg, rgb(29 31 36 / .94), rgb(12 12 15 / .94)) !important;
  box-shadow: 0 0 0 1px #000, 0 0 0 3px #c9cfd8, 0 0 40px -10px var(--cr-red-glow) !important;
}
html[data-theme="cromo"] .loading-quote figcaption p { color: #ff4152 !important; }

/* inputs */
html[data-theme="cromo"] :is(input:not([type=checkbox]):not([type=radio]):not([type=range]), textarea, select) {
  background-color: #0b0b0e !important; color: #f1f3f6 !important; border-color: rgb(201 207 216 / .35) !important;
}
html[data-theme="cromo"] :is(input, textarea, select):focus-visible { outline-color: var(--cr-red) !important; }
html[data-theme="cromo"] ::selection { background: rgb(255 35 56 / .45); color: #fff; }
html[data-theme="cromo"] dialog::backdrop { background: rgb(0 0 0 / .72); }

/* menu icon tiles: chrome coins */
html[data-theme="cromo"] body.roman-menu > header nav :is(#offline-options, #learn-options, #online-options) button::before,
html[data-theme="cromo"] body.roman-menu > header nav .nav-group-title::before {
  background: var(--ic) center / 22px 22px no-repeat, radial-gradient(circle at 35% 30%, #3a3d44, #16171b 70%) !important;
  border-color: #9aa1ab !important;
}

/* theme picker in the Cromo look */
html[data-theme="cromo"] .theme-option { border-color: rgb(201 207 216 / .28); background: #121317; color: #f1f3f6; }
html[data-theme="cromo"] .theme-option[aria-checked="true"] { border-color: var(--cr-red); box-shadow: 0 0 0 1px var(--cr-red), 0 8px 26px -10px var(--cr-red-glow); }
