/*
  Duel style for the site's frame (08.11.2026): header, chat column, phone bar,
  menus, sheets, modals and toasts, on every page.

  Lukas, after the games went Duel (parts/duel-games.css): "der chat, header usw
  passt jetzt nicht dazu" -> "Ganze Seite". So the frame drops the winter dress
  (frosted glass, icicles, string lights, snow on the rain box, falling snow)
  and takes Duel's flat navy: header #0c102b with a hairline, chat #121731,
  wells #181e3c, keys #343c64, the primary blue #4558ff. The Santa hat on the
  avatar and the snowman by the logo stay as the one small winter greeting.

  Linked from index.html after the theme and duel-games.css. Every rule starts
  with :root:not(#dd) so it beats the theme's html.theme-winter rules without
  !important; !important only where the theme or frame.css use it themselves.
  Off switch: remove the <link> in index.html.
*/

/* ---------- the palette, inside the frame ---------- */
:root:not(#dd) :is(#v2-header, #v2-chat, #v2-bottom, .v2-menu, .v2-sheet-card, .v2-modal-card, .v2-toast) {
  --g900: #0c102b;
  --g800: #0c102b;
  --g700: #121731;
  --g600: #161b38;
  --g500: #181e3c;
  --g400: #1f2546;
  --g300: #2a3156;
  --g200: #343c64;
  --g100: #3d4570;
  --g50: #47507c;
  --t1: #e8eaf4;
  --t2: #a4aac6;
  --t3: #8d94bb;
  --t4: #8088b0;
  --t5: #767faa;
  --t6: #8d94bb;
  --t7: #767faa;
  --purple: #4558ff;
  --purple-600: #5e6eff;
  --purple-700: #4558ff;
  --purple-300: #8f9bff;
  --green: #20d095;
  --green-400: #6de8bf;
  --red: #e8305e;
  --red-400: #ff5c85;
  --rim: #1f2546;
  --rim-2: #343c64;
  --glow: transparent;
}

/* The ground: the winter sky stays behind the pages (Lukas: "das mit dem overlay beim runterscrollen hat gepasst");
   game pages lay Duel's navy over it (duel-games.css #page). */

/* ---------- header ---------- */
:root:not(#dd) #v2-header {
  background: #0c102b;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  border-bottom: 1px solid #181e3c;
  box-shadow: none;
}
:root:not(#dd) #v2-header::after { content: none; display: none; } /* icicles */
:root:not(#dd) .hd-word b { background: none; -webkit-background-clip: border-box; background-clip: border-box; color: #fff; }
:root:not(#dd) .hd-word span { color: #fff; }
:root:not(#dd) .hd-logo img { filter: none; }
:root:not(#dd) #v2-header :is(.hd-btn-text, .hd-bal-amt) { box-shadow: none !important; text-shadow: none; }
/* the nav entries are keys (Lukas 08.11.2026: "die button noch buttiger machen, dass man sieht dass ein button ist"):
   a raised face with the 3D edge, lighter under the pointer, the current page on the lighter key */
:root:not(#dd) .hd-link {
  height: 40px; padding: 0 16px 3px; border-radius: 10px; color: #c3c8e2; background: #1f2546;
  text-transform: none; letter-spacing: 0; font-size: 15px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .1), inset 0 -3px 0 rgba(0, 0, 0, .35) !important;
  transition: background-color .15s, color .15s, transform .1s;
}
:root:not(#dd) .hd-link:hover { color: #fff; background: #2a3156; }
:root:not(#dd) .hd-link.on { color: #fff; background: #343c64; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .14), inset 0 -3px 0 rgba(0, 0, 0, .35) !important; }
:root:not(#dd) :is(.hd-link, .hd-race):active { transform: translateY(1px); box-shadow: inset 0 2px 0 rgba(0, 0, 0, .3) !important; }
:root:not(#dd) .hd-link .hd-ico { color: #8f9bff; }
:root:not(#dd) .hd-link[data-nav="games"].on .hd-ico { color: #8f9bff; }
:root:not(#dd) .hd-race { padding-bottom: 3px; border-radius: 10px; background: #1f2546; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .1), inset 0 -3px 0 rgba(0, 0, 0, .35) !important; }
:root:not(#dd) .hd-race:hover { background: #2a3156; }
:root:not(#dd) .hd-race.on { background: #343c64; }
:root:not(#dd) .hd-btn-text { color: #a4aac6; text-transform: none; letter-spacing: 0; font-size: 14px; }
:root:not(#dd) .hd-btn-text:hover { color: #fff; }
:root:not(#dd) :is(.hd-btn-primary, .si-submit:not(.si-submit--alt)) {
  background: #4558ff; color: #fff; text-shadow: none; filter: none;
  text-transform: none; letter-spacing: 0; font-size: 14px; font-weight: 700;
}
:root:not(#dd) :is(.hd-btn-primary, .si-submit:not(.si-submit--alt)):hover:not(:disabled) { background: #5e6eff; }
:root:not(#dd) .si-submit:disabled { color: rgba(255, 255, 255, .6); background: #343c64; }
:root:not(#dd) .hd-bal { background: #181e3c; border: 0; }
:root:not(#dd) .hd-wallet { background: #4558ff; text-transform: none; letter-spacing: 0; font-size: 14px; }
:root:not(#dd) .hd-wallet:hover { background: #5e6eff; }

/* ---------- chat column ---------- */
:root:not(#dd) #v2-chat {
  background: #121731;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  border-right: 0;
  box-shadow: none;
}
:root:not(#dd) #v2-chat::before, :root:not(#dd) #v2-chat::after { content: none; display: none; } /* string of lights */
:root:not(#dd) .ch-rain { background: #181e3c; border-color: transparent; box-shadow: none; overflow: hidden; }
:root:not(#dd) .ch-rain::before { opacity: .06; }
:root:not(#dd) .ch-rain::after { content: none; display: none; } /* snow cap */
:root:not(#dd) .ch-input { background: #181e3c; box-shadow: none; border: 0; }
:root:not(#dd) .ch-input:focus-within { box-shadow: inset 0 0 0 2px #343c64; }
:root:not(#dd) .ch-send { background: #4558ff; }
:root:not(#dd) .ch-dot { background: #20d095; }
:root:not(#dd) #v2-chat :is(.v3-panel, .v3-tile, .v3-well) { box-shadow: none !important; }
:root:not(#dd) .v2-fab { background: #181e3c; color: #8a93c4; border-color: #262e56; box-shadow: 0 6px 18px rgba(3, 6, 24, .45); }
:root:not(#dd) .v2-fab:hover { background: #20284e; color: #fff; }

/* ---------- phone bar ---------- */
:root:not(#dd) #v2-bottom { background: #0c102b; border-top: 1px solid #181e3c; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; }

/* ---------- menus, sheets, modals, toasts: flat cards ---------- */
:root:not(#dd) :is(.v2-menu, .v2-sheet-card) {
  background: #121731;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  border: 1px solid #1f2546;
}
:root:not(#dd) .v2-menu { box-shadow: 0 16px 36px rgba(3, 6, 24, .6); }
/* menu entries are keys on their own, with room between them (Lukas 08.11.2026: "das hier muss auch noch so abstand und so sein");
   the extra 3px at the foot centres the label on the face above the dark 3D edge */
:root:not(#dd) :is(.v2-menu .v2-menu-item:not(.off), .v2-menu-item--tile:not(.off)) {
  padding: 8px 10px 11px; border-radius: 10px; background: #1f2546; color: #c3c8e2; text-transform: none; letter-spacing: 0;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08), inset 0 -3px 0 rgba(0, 0, 0, .35);
}
:root:not(#dd) :is(.v2-menu .v2-menu-item:not(.off):hover, .v2-menu .v2-menu-item.on, .v2-menu-item--tile:not(.off):hover) { background: #2a3156; color: #fff; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .1), inset 0 -3px 0 rgba(0, 0, 0, .35); }
:root:not(#dd) .v2-menu .v2-menu-item.on { background: #343c64; }
:root:not(#dd) .v2-menu .v2-menu-item:not(.off):active { transform: translateY(1px); box-shadow: inset 0 2px 0 rgba(0, 0, 0, .3); }
:root:not(#dd) .v2-menu .v2-menu-ico { box-shadow: none; background: #181e3c; color: #8f9bff; }
:root:not(#dd) .v2-menu-item + .v2-menu-item, :root:not(#dd) .v2-menu-row + .v2-menu-row { margin-top: 6px; }
:root:not(#dd) .v2-menu-grid { gap: 6px; }
:root:not(#dd) .v2-menu-grid :is(.v2-menu-item + .v2-menu-item, .v2-menu-row + .v2-menu-row) { margin-top: 0; }
:root:not(#dd) .v2-menu--games { gap: 12px; padding: 10px; }
:root:not(#dd) .v2-menu-sec + .v2-menu-sec { padding-top: 12px; border-top-color: #1f2546; }
:root:not(#dd) .v2-menu-row .v2-menu-pin { top: calc(50% - 1.5px); }
:root:not(#dd) .v2-menu-sec-h { color: #767faa; letter-spacing: 0; text-transform: none; font-size: 12px; padding: 2px 4px 8px; }
:root:not(#dd) .v2-menu-sec-h::before { content: none; display: none; }
:root:not(#dd) :is(.v2-modal-scrim, .v2-sheet-scrim) { background: rgba(5, 8, 26, .7); -webkit-backdrop-filter: none; backdrop-filter: none; }
:root:not(#dd) .v2-modal-card { background: #121731; border: 1px solid #1f2546; box-shadow: 0 24px 56px rgba(3, 6, 24, .7); }
:root:not(#dd) .si-input { background: #181e3c; border-color: transparent; }
:root:not(#dd) .si-input:focus { border-color: #343c64; box-shadow: none; }
:root:not(#dd) :is(.si-tabs, .wl-tabs) button.on { background: #343c64; color: #fff; box-shadow: none; }
:root:not(#dd) .v2-toast { background: #181e3c; -webkit-backdrop-filter: none; backdrop-filter: none; border: 1px solid #1f2546; box-shadow: 0 12px 28px rgba(3, 6, 24, .6); }
:root:not(#dd) :is(input[type="text"], input[type="number"], input[type="search"], input[type="email"], input[type="password"], textarea, select):focus { box-shadow: none; }

/* ======================================================================
   The rest of the winter dress, everywhere (Lukas 08.11.2026: "Ja, angleichen")
   ====================================================================== */

/* snow caps on cards, tiles, panels and the rain box */
:root:not(#dd) :is(.pg-home .h-og, .pg-home .h-slot, .pg-home .h-top-tile, .pg-home .h-top-main, .pg-home .h-about, .ch-rain, .gs-panel, .gs-stage, .v2-game-panel)::after { content: none; display: none; }
/* the covers clip their corners again and get their hover zoom back */
:root:not(#dd) .pg-home :is(.h-og, .h-slot) { overflow: hidden; }
:root:not(#dd) .pg-home .h-og-cover { clip-path: none; }
:root:not(#dd) .pg-home .h-og--cover:hover .h-og-cover { transform: scale(1.04); }
:root:not(#dd) .pg-home .h-og-text { border-radius: 0; }
:root:not(#dd) .pg-home .h-slot img { border-radius: 0; }

/* home: flat Duel cards instead of frosted ones */
:root:not(#dd) .pg-home {
  --g900: #0c102b; --g800: #0c102b; --g700: #121731; --g600: #161b38; --g500: #181e3c; --g400: #1f2546;
  --g300: #2a3156; --g200: #343c64; --g100: #3d4570; --g50: #47507c;
  --t2: #a4aac6; --t3: #8d94bb; --t4: #8088b0; --t5: #767faa; --t6: #8d94bb; --t7: #767faa;
  --purple: #4558ff; --purple-600: #5e6eff; --purple-700: #4558ff; --purple-300: #8f9bff;
}
:root:not(#dd) .pg-home .h-top-main { border-color: transparent; background: radial-gradient(70% 130% at 88% 100%, rgba(69, 88, 255, .22), transparent 72%), #121731; box-shadow: none; }
:root:not(#dd) .pg-home .h-top-title { background: none; -webkit-background-clip: border-box; background-clip: border-box; color: #fff; }
:root:not(#dd) .pg-home .h-top-legit { color: #6de8bf; }
:root:not(#dd) .pg-home .h-top-tile { border-color: transparent; background: radial-gradient(110% 70% at 50% 100%, color-mix(in srgb, var(--ac) 22%, transparent), transparent 76%), #121731; box-shadow: none; }
:root:not(#dd) .pg-home .h-top-tile:hover { border-color: transparent; box-shadow: none; transform: translateY(-3px); }
:root:not(#dd) .pg-home .h-top-chip { box-shadow: none; }
:root:not(#dd) .pg-home .h-mq-card { --tint: #4558ff; }
:root:not(#dd) .pg-home :is(.h-mq-card, .h-slot, .h-pin) { box-shadow: none; }
:root:not(#dd) .pg-home :is(.h-mq-card, .h-slot):hover { transform: translateY(-4px); box-shadow: none; }
:root:not(#dd) .pg-home .h-sec-t { background: none; -webkit-background-clip: border-box; background-clip: border-box; color: #fff; filter: none; }
:root:not(#dd) .pg-home .h-sec-t::before, :root:not(#dd) .pg-home .h-sec-t::after { content: none; display: none; } /* snowflakes */
:root:not(#dd) .pg-home .h-about { border-color: transparent; background: #121731; }
:root:not(#dd) .pg-home .h-lv-tabs { background: #181e3c; box-shadow: none; }
:root:not(#dd) .pg-home .h-lv-tab.is-on { background: #343c64; box-shadow: none; }
:root:not(#dd) :is(.pg-home .h-top-btn--main, .pg-home .h-btn--purple) { background: #4558ff; color: #fff; text-shadow: none; }
:root:not(#dd) :is(.pg-home .h-top-btn--main, .pg-home .h-btn--purple):hover:not(:disabled) { background: #5e6eff; }
:root:not(#dd) .pg-home :is(.v3-panel, .v3-tile) { box-shadow: none !important; }

/* the info pages' heroes: a soft blue glow instead of the snow field */
:root:not(#dd) :is(.pg-help .hp-hero, .pg-rewards .rw-hero, .pg-levels .lv-hero, .pg-legal .lg-head, .pg-media .md-hero, .pg-provably-fair .pf-hero, .pg-how-it-works .hw-hero, .pg-affiliates .af-hero, .pg-affiliate-info .ai-hero) {
  background: radial-gradient(60% 55% at 50% 100%, rgba(69, 88, 255, .2), transparent 100%), #121731;
}
:root:not(#dd) :is(.pg-help .hp-hero, .pg-rewards .rw-hero, .pg-levels .lv-hero, .pg-media .md-hero, .pg-provably-fair .pf-hero, .pg-how-it-works .hw-hero, .pg-affiliates .af-hero, .pg-affiliate-info .ai-hero, .pg-legal .lg-head)::before { background: none; }
:root:not(#dd) :is(.v3-panel, .v3-tile) { box-shadow: none; }

/* sign-in dialog: our diamond on Duel navy instead of the snowflake picture */
:root:not(#dd) .si-art {
  background:
    no-repeat center 38% / 96px 96px url("/brand/diamond.svg"),
    radial-gradient(60% 45% at 50% 38%, rgba(69, 88, 255, .35), transparent 70%),
    linear-gradient(180deg, #181e3c, #0c102b);
}

/* footer: the winter footer stays (snowdrift, village picture), see themes/winter.css */

/* phone bar: the active tab in white, no glow */
:root:not(#dd) :is(.bn-btn.on, .bn-btn.open) { color: #fff; text-shadow: none; }

/* leftovers of the ice palette */
:root:not(#dd) { --hr-violet: #4558ff; }
:root:not(#dd) .hr-mark { background: linear-gradient(135deg, #2133dc, #121731); }
:root:not(#dd) .v2-cur-chk { color: #8f9bff; }
:root:not(#dd) .pg-leaderboard .lb-you.is-ranked { background: rgba(69, 88, 255, .12); }
:root:not(#dd) .pg-rewards .t-epic { --tier-glow: rgba(69, 88, 255, .35); }

/* ---------- 3D keys (Lukas 08.11.2026: "die 3d knoepfe haben gepasst"): the frame.css bevel, without winter's frost rim ---------- */
:root:not(#dd) :is(.hd-btn-primary, .hd-wallet, .si-submit:not(.si-submit--alt), .ch-send, .pg-home .h-top-btn--main, .pg-home .h-btn--purple, .pg-home .h-btn, .v3-key) {
  box-shadow: inset 0 2px 0 rgba(255, 255, 255, .24), inset 0 -3px 0 rgba(0, 0, 0, .32) !important;
}
:root:not(#dd) :is(.hd-btn-primary, .hd-wallet, .si-submit:not(.si-submit--alt), .ch-send, .pg-home .h-top-btn--main, .pg-home .h-btn--purple, .pg-home .h-btn, .v3-key):active:not(:disabled) {
  box-shadow: inset 0 2px 0 rgba(0, 0, 0, .28) !important;
  transform: translateY(1px);
}
:root:not(#dd) .v3-key-soft { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .1), inset 0 -2px 0 rgba(0, 0, 0, .38) !important; }

/* ---------- chat messages: each one on its own tile (Lukas 08.11.2026: "zwischen nachricht erkennt man da irgendwie nix")
   The same box as the highroller and level cards (.ch-msg--hr / --card: 8px in, 10px corners),
   so plain and special messages line up; a message that names the reader keeps its tint and bar. */
:root:not(#dd) .ch-list { padding-top: 8px; }
:root:not(#dd) .ch-msg:not(.ch-msg--card):not(.ch-msg--hr):not(.ch-msg--promo) {
  margin: 0 8px 6px;
  padding: 8px;
  border-radius: 10px;
  background: #181e3c;
  transition: background-color .15s;
}
:root:not(#dd) .ch-msg:not(.ch-msg--card):not(.ch-msg--hr):not(.ch-msg--promo):hover { background: #1f2546; }
:root:not(#dd) .ch-msg.ch-msg--ping:not(.ch-msg--card):not(.ch-msg--hr) { background: color-mix(in srgb, #4558ff 18%, #181e3c); box-shadow: inset 3px 0 0 #8f9bff; }
:root:not(#dd) .ch-msg--sys:not(.ch-msg--card) { background: color-mix(in srgb, #ff9900 7%, #181e3c); }

/* No page scrollbar on the right (Lukas 09.11.2026: "da rechts scrollbar weg").
   Only the viewport's own bar is hidden; scrolling still works, and inner lists
   (chat, menus) keep their thin bars because scrollbar-width does not inherit
   and html::-webkit-scrollbar targets only the root scroller. */
:root:not(#dd) { scrollbar-width: none; }
:root:not(#dd)::-webkit-scrollbar { width: 0; height: 0; display: none; }

/* ---------- chat messages as banded rows (24.11.2026, the donutsurge pass in our colours):
   still one message per row you can tell apart (08.11.: "zwischen nachricht erkennt man da
   irgendwie nix"), but rows of a list instead of a stack of tiles - every other one on a light
   band, 6px corners, 2px between them. Pings, system lines and the special cards keep theirs. */
:root:not(#dd) .ch-list { padding: 6px 0 4px; }
:root:not(#dd) .ch-msg:not(.ch-msg--card):not(.ch-msg--hr):not(.ch-msg--promo) {
  margin: 0 6px 2px; padding: 8px 10px; border-radius: 6px; background: transparent;
}
:root:not(#dd) .ch-msg:not(.ch-msg--card):not(.ch-msg--hr):not(.ch-msg--promo):nth-child(odd) { background: var(--ds-band); }
:root:not(#dd) .ch-msg:not(.ch-msg--card):not(.ch-msg--hr):not(.ch-msg--promo):hover { background: #1f2546; }
:root:not(#dd) .ch-msg.ch-msg--ping:not(.ch-msg--card):not(.ch-msg--hr) { background: color-mix(in srgb, #4558ff 18%, #121731); }
:root:not(#dd) .ch-msg--sys:not(.ch-msg--card) { background: color-mix(in srgb, #ff9900 7%, #121731); }
:root:not(#dd) .ch-rain { background: var(--ds-lit); box-shadow: var(--ds-edge); border-radius: 8px; }
:root:not(#dd) .ch-input { background: var(--ds-well); box-shadow: var(--ds-edge-well); border-radius: 6px; }
:root:not(#dd) .ch-input:focus-within { box-shadow: inset 0 0 0 1px #4a5590; }
