/* Dark theme. Switched on with <html data-theme="dark">; loaded after style.css. */
html[data-theme="dark"] {
  color-scheme: dark;
  --navy: #BBD2FF;        /* used for headings and links in light mode, so it turns light here */
  --navy-deep: #060D1C;
  --ink: #E8EEFA;
  --muted: #A6B4CF;
  --line: #233250;
  --line-strong: #34486B;
  --soft: #0F1829;
  --green: #3FD2A2;
  --gold: #3E86FF;
  --accent: #3E86FF;
  --d-bg: #0A101D;
  --d-surface: #111A2D;
  --d-surface2: #162239;
  --d-band: #0E2A5C;
}
html[data-theme="dark"] body { background: var(--d-bg); color: var(--ink); }

/* surfaces that are white in light mode */
html[data-theme="dark"] :is(.dc, .dk, .dc-tier, .sum-card, .tk, .pd-main, .pd-buy, .cart-empty, .setup-card, .process-card, .feature,
  .chip, .back-pill, .acct-menu, .ak-st, .doc-sec, .input, select.input, .btn-outline, .pg, .legal-card, .faq details, .login-card,
  .stat, .card, .panel, .modal, .pd-cart, .cap-box, .auth-card, .reset-card) {
  background: var(--d-surface); color: var(--ink); border-color: var(--line);
}
html[data-theme="dark"] :is(.dc-head, .tk-stub, .shop-filters, th, .section-soft, .notice-info, code, .pd-pill, .promo-tag, .setup-ic, .ak-dot) {
  background: var(--d-surface2); color: var(--ink); border-color: var(--line);
}
html[data-theme="dark"] .section-soft { background: #0D1526; }
html[data-theme="dark"] .acct-av { background: var(--d-surface2); color: var(--ink); }
html[data-theme="dark"] .btn-gold { background: var(--accent); color: #fff; }
html[data-theme="dark"] .btn-outline:hover { background: var(--d-surface2); }
html[data-theme="dark"] .input::placeholder { color: #7686A6; }

/* things that must stay dark navy even though they use var(--navy) for their background */
html[data-theme="dark"] :is(.band, .cta-box, .login-side) { background: var(--d-band); color: #fff; }
html[data-theme="dark"] .site-footer { background: #060D1C; }
html[data-theme="dark"] :is(.chip.on, .pg.on, .tk-days, .legal-tabs a.on, .ap-n, .ap-chips input:checked + span, .su-steps li.on, .pager-links a.cur, .btn-primary) {
  background: #1D4FA8; border-color: #1D4FA8; color: #fff;
}
html[data-theme="dark"] .acct-menu a, html[data-theme="dark"] .acct-menu button { color: var(--ink); }
html[data-theme="dark"] .acct-menu a:hover { background: var(--d-surface2); }

/* status colours */
html[data-theme="dark"] .badge-paid, html[data-theme="dark"] .pd-pill.ok { background: #0F3A2E; color: #7BE6C0; }
html[data-theme="dark"] .notice-warn { background: #3A2F12; color: #F5D98A; border-color: #6B5A22; }
html[data-theme="dark"] .su-steps li.done { background: #0F3A2E; color: #7BE6C0; }
html[data-theme="dark"] .cap-bar { background: #1E2C47; }
html[data-theme="dark"] .cap-box.cap-full .cap-bar { background: #4A3A12; }
html[data-theme="dark"] .mc-loader { background: var(--d-bg); }
html[data-theme="dark"] .mc-loader-bar { background: #14333A; }
html[data-theme="dark"] .mc-loader-txt { color: #9FB0CC; }
html[data-theme="dark"] .mc-loader-logo { filter: brightness(1.15); }
html[data-theme="dark"] img.logo-full { filter: none; }
html[data-theme="dark"] hr { border-color: var(--line); }
html[data-theme="dark"] main :is(p, li, td, dd, small, label) a:not(.btn) { color: #A9C4F5; }
html[data-theme="dark"] main :is(p, li, td, dd, small, label) a:not(.btn):hover { color: #fff; }
html[data-theme="dark"] .site-footer a { color: #B8C6E4; }
html[data-theme="dark"] .pd-facts > div { background: var(--d-surface2); border-color: var(--line); }
html[data-theme="dark"] :is(.promo-price, .tk-stock.ok, .wl-in, .id-ok) { color: #5CE0B3 !important; }
html[data-theme="dark"] .tk-stock.out, html[data-theme="dark"] .wl-out { color: #FF8F86; }
html[data-theme="dark"] .promo-tag { background: #0F3A2E; color: #7BE6C0; }
html[data-theme="dark"] :is(.ak-st.ok, .id-drop) { background: var(--d-surface2); border-color: var(--line-strong); }
html[data-theme="dark"] .qty-presets .qp{background:var(--d-surface);color:var(--ink);border-color:var(--line-strong)}
html[data-theme="dark"] .qty-presets .qp.on{background:#1D4FA8;border-color:#1D4FA8;color:#fff}

/* notification bell */
html[data-theme="dark"] .bell-panel{background:#111A2D;color:#E8EEFA;border-color:#233250}
html[data-theme="dark"] .bell-hd,html[data-theme="dark"] .bell-list li{border-color:#233250}
html[data-theme="dark"] .bell-list li.un{background:#15223B}
html[data-theme="dark"] .bell-tx span{color:#A6B4CF}html[data-theme="dark"] .bell-ft{background:#0F1829;color:#A6B4CF}
html[data-theme="dark"] .bell-ic.ok{background:#0F3A2E}html[data-theme="dark"] .bell-ic.top{background:#16305E}html[data-theme="dark"] .bell-ic.warn{background:#4A3A12}
html[data-theme="dark"] .bell-hd button{color:#7DB0FF}
html[data-theme="dark"] .bell-row:hover{background:#192741}html[data-theme="dark"] .bell-ft a{color:#7DB0FF}html[data-theme="dark"] .bell-empty{color:#A6B4CF}html[data-theme="dark"] .bell-ic.info{background:#1E2C47;color:#A6B4CF}html[data-theme="dark"] .bell-page{border-color:#233250}

/* public / legal pages and small bars */
html[data-theme="dark"] .legal-doc { background: var(--d-surface); color: var(--ink); border-color: var(--line); }
html[data-theme="dark"] :is(.legal-intro, .cp-cta) { background: var(--d-surface2); color: var(--ink); border-color: var(--line); }
html[data-theme="dark"] .legal-doc :is(p, li, td) { color: var(--ink); }
html[data-theme="dark"] .legal-doc a:not(.btn) { color: #A9C4F5; }
html[data-theme="dark"] .cp-cta p { color: #A6B4CF; }
html[data-theme="dark"] .visitor-bar { background: #3A2F12; color: #F5D98A; border-color: #6B5A22; }
html[data-theme="dark"] .visitor-bar a { color: #FFE9A8; }
html[data-theme="dark"] .login-lang .lang-sw { border-color: var(--line-strong); }
html[data-theme="dark"] .login-lang .lang-sw a { color: #A6B4CF; }
html[data-theme="dark"] .login-lang .lang-sw a.on { background: #1D4FA8; color: #fff; }

/* saved items + trust strip */
html[data-theme="dark"] .heart { background: var(--d-surface); color: #8FA0BF; border-color: var(--line-strong); }
html[data-theme="dark"] .heart.on { background: #3A1B22; color: #FF7A82; border-color: #6B2D37; }
html[data-theme="dark"] .heart.on svg { fill: #FF7A82; }
html[data-theme="dark"] .trust-strip { background: var(--d-surface); border-color: var(--line); }
html[data-theme="dark"] .trust-strip svg { color: var(--green); }
html[data-theme="dark"] .trust-strip a { color: #A9C4F5; }
html[data-theme="dark"] .sh-panel{background:#101A30;color:#E8EEFA;border-color:#2A3B5C;box-shadow:0 18px 40px rgba(0,0,0,.5)}
html[data-theme="dark"] .sh-row a,html[data-theme="dark"] .sh-row button{background:#16233F;color:#BFD4FF;border-color:#2A3B5C}
html[data-theme="dark"] .sh-row a:hover,html[data-theme="dark"] .sh-row button:hover{background:#1D2E50}
html[data-theme="dark"] .sh-ok{color:#5FD3A0}
html[data-theme="dark"] .rv-h{color:#9FB2D3}
html[data-theme="dark"] .rv-item{background:#101A30;border-color:#2A3B5C;color:#E8EEFA}
html[data-theme="dark"] .rv-item:hover{background:#16233F}
html[data-theme="dark"] .rv-price{color:#8FB8FF}
html[data-theme="dark"] .rv-price em{color:#FF9A8F}
html[data-theme="dark"] .tabbar { background: #0E1830; border-top-color: #2A3B5C; box-shadow: 0 -6px 20px rgba(0,0,0,.5); }
html[data-theme="dark"] .tabbar a, html[data-theme="dark"] .tabbar button { color: #9FB2D3; }
html[data-theme="dark"] .tabbar a[aria-current="page"] { color: #fff; }
html[data-theme="dark"] .tab-fab, html[data-theme="dark"] .tab-badge { border-color: #0E1830; }

html[data-theme="dark"] .acct-list a{background:#161b26;border-color:#2a3142;color:#e6eaf2}
html[data-theme="dark"] .acct-list a:hover{border-color:#4f8bff}
html[data-theme="dark"] .acct-list .ic{background:#1d2a48;color:#7fb0ff}
html[data-theme="dark"] .acct-list .ic.t-green{background:#16332b;color:#5fd3a8}
html[data-theme="dark"] .acct-list .ic.t-rose{background:#3a1d28;color:#ff8aa8}
html[data-theme="dark"] .acct-list .ic.t-amber{background:#3a2c14;color:#f2b04c}
html[data-theme="dark"] .acct-list .ic.t-slate{background:#222a3a;color:#aab3c5}
html[data-theme="dark"] .acct-h{color:#9aa4b8}
html[data-theme="dark"] .acct-out button{background:#2a1a20;border-color:#5a2a37;color:#ff9db1}
html[data-theme="dark"] .table-cards tr{background:#161b26;border-color:#2a3142}

html[data-theme="dark"] .codes-card{background:#161b26;border-color:#2a3142}
html[data-theme="dark"] .codes-head{background:#1b2232;border-color:#2a3142}
html[data-theme="dark"] .codes-head h2{color:#e8eefa}
html[data-theme="dark"] .codes-head h2 span{background:#26304a;color:#b9c6e4}
html[data-theme="dark"] .code-val{color:#e8eefa;border-color:#2a3142;background:repeating-linear-gradient(#161b26 0,#161b26 32px,#1b2232 32px,#1b2232 64px)}
html[data-theme="dark"] .paid-banner{background:#12261f;border-color:#1f4a3b;border-left-color:#2fbf92}
html[data-theme="dark"] .paid-banner b{color:#7fe0bd}
html[data-theme="dark"] .paid-banner small{color:#9cc9b8}
html[data-theme="dark"] .paid-act .btn{background:#161b26}
html[data-theme="dark"] .od-sum,html[data-theme="dark"] .od-pay,html[data-theme="dark"] .od-state{background:#161b26;border-color:#2a3142;color:#e6eaf2}
html[data-theme="dark"] .od-sum{border-top-color:#4f8bff}
html[data-theme="dark"] .od-items,html[data-theme="dark"] .od-total{border-color:#2a3142}
html[data-theme="dark"] .od-items b,html[data-theme="dark"] .od-items span,html[data-theme="dark"] .od-total dt{color:#e6eaf2}
html[data-theme="dark"] .od-total dd,html[data-theme="dark"] .od-sum-h b{color:#8fb8ff}
html[data-theme="dark"] .od-items small,html[data-theme="dark"] .od-tot dt{color:#9aa4b8}
html[data-theme="dark"] .od-instr{background:#1b2232;border-color:#2a3142}
html[data-theme="dark"] .pay-timer{background:#2a2412;border-color:#5a4a1c;color:#f3e2b0}
html[data-theme="dark"] .pay-timer small{color:#c9b98a}
html[data-theme="dark"] .tabbar-guest { background: #0F1B33; border-top-color: #263A5E; }
html[data-theme="dark"] .dh-actions .btn-outline { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.34); color: #fff; }
html[data-theme="dark"] .dh-actions .btn-outline:hover { background: rgba(255,255,255,.16); }
@media (max-width:700px){
  html[data-theme="dark"] .sum-range .btn{background:#2F7BFF;border-color:#2F7BFF;color:#fff}
  html[data-theme="dark"] .sum-range .input{background:#0B1530;border-color:#2A3B5C}
}
html[data-theme="dark"] .apply-form { background: var(--d-surface); border-color: var(--line); box-shadow: none; }
html[data-theme="dark"] .apply-form .vis { background: var(--d-surface2); border-color: #2A3B5C; }
html[data-theme="dark"] .apply-form label, html[data-theme="dark"] .apply-form .vis-t b { color: var(--ink); }
html[data-theme="dark"] .apply-form .muted, html[data-theme="dark"] .apply-form .vis-t small { color: #9FB2D3; }
html[data-theme="dark"] .ap-pending { background: #3A2E10; border-color: #6B5316; color: #F6DFA6; }
html[data-theme="dark"] .ap-rejected { background: #3A1A1A; border-color: #7A2E2E; color: #F5B8B4; }
/* v23ac: remaining surfaces that stayed white in dark mode */
html[data-theme="dark"] .id-card { background: var(--d-surface); border-color: var(--line); }
html[data-theme="dark"] .id-intro h2, html[data-theme="dark"] .id-body h3 { color: var(--ink); }
html[data-theme="dark"] .id-intro p, html[data-theme="dark"] .id-body > p, html[data-theme="dark"] .id-drop small, html[data-theme="dark"] .id-foot { color: #9FB2D3; }
html[data-theme="dark"] .id-tile span, html[data-theme="dark"] .id-drop, html[data-theme="dark"] .id-opt, html[data-theme="dark"] .id-wait { background: var(--d-surface2); border-color: #2A3B5C; color: var(--ink); }
html[data-theme="dark"] .id-bad { background: #3A1A1A; border-color: #7A2E2E; color: #F5B8B4; }
html[data-theme="dark"] .id-num { background: #2F7BFF; color: #fff; }
html[data-theme="dark"] .id-card.done .id-num { background: #0F7B4F; }
html[data-theme="dark"] .id-docs legend, html[data-theme="dark"] .id-card label, html[data-theme="dark"] .id-card b, html[data-theme="dark"] .id-consent span { color: var(--ink); }
html[data-theme="dark"] .id-card a { color: #8DB8FF; }
html[data-theme="dark"] .id-ok { color: #4FD3A1 !important; }
html[data-theme="dark"] .legal-n { background: #1E3A6E; color: #fff; }
html[data-theme="dark"] .acct-big { background: #fff; color: #0A2E73; }
html[data-theme="dark"] .acct-list a em { color: #7F93B5; }
html[data-theme="dark"] .cp-cta { background: var(--d-surface); border-color: var(--line); }
html[data-theme="dark"] .cp-cta span { color: #9FB2D3; }
html[data-theme="dark"] .doc-nav a { background: #1E3A6E; color: #fff; }
html[data-theme="dark"] .su-steps li { background: var(--d-surface2); color: #9FB2D3; }
html[data-theme="dark"] .su-steps li.on { background: #2F7BFF; color: #fff; }
html[data-theme="dark"] .su-steps li.done { background: #12372B; color: #4FD3A1; }
html[data-theme="dark"] .notice-ok { background: #10301F; border-color: #1F6B45; color: #BFEBD3; }
html[data-theme="dark"] .notice-ok a { color: #8DE0B5; }
html[data-theme="dark"] .cart-empty svg { filter: brightness(1.9) saturate(.9); }
html[data-theme="dark"] .nt-empty-ic { background: #1B2A47; color: #7DB0FF; }
html[data-theme="dark"] .nt-empty p { color: #9FB0CC; }
html[data-theme="dark"] .ak-st a { background: #1B2A47; color: #8DB8FF; }
html[data-theme="dark"] .btn-google { background: #F1F5FB; color: #1F2937; border-color: #fff; }
html[data-theme="dark"] .btn-google:hover { background: #EAF0FA; }
html[data-theme="dark"] .or-line { color: #9FB0CC; }
html[data-theme="dark"] .or-line::before, html[data-theme="dark"] .or-line::after { background: #26385C; }

/* v23al */
html[data-theme="dark"] :is(.rvw-sum, .rvw-card, .rvw-kpis > div, .rvw-box) { background: var(--d-surface); border-color: var(--line); }
html[data-theme="dark"] .rvw-prog, html[data-theme="dark"] .rvw-prog::-webkit-progress-bar { background: #1B2A47; }
html[data-theme="dark"] .rvw-st i, html[data-theme="dark"] .rvw-pick label { color: #3A4C70; }
html[data-theme="dark"] .rvw-pick input:checked ~ label, html[data-theme="dark"] .rvw-pick label:hover, html[data-theme="dark"] .rvw-pick label:hover ~ label { color: #F5A400; }
html[data-theme="dark"] .bdg-hot { background: #4A2410; color: #FFC499; }
html[data-theme="dark"] .bdg-fast { background: #0F2D55; color: #A9D2FF; }
html[data-theme="dark"] .bdg-low { background: #4A3A0A; color: #FFE08A; }
html[data-theme="dark"] .bdg-promo { background: #0F3A2E; color: #7BE6C0; }
html[data-theme="dark"] .hp-item { background: var(--d-surface); color: var(--ink); }

/* live sales chart */
html[data-theme="dark"] .tl-b { background: var(--d-surface2); color: var(--ink); }
html[data-theme="dark"] .tl-b.on { background: #1D4FA8; border-color: #1D4FA8; color: #fff; }
html[data-theme="dark"] .tl-tip { background: #060D1C; color: #fff; }
html[data-theme="dark"] .nt-page .nt-note{border-color:#233250}
html[data-theme="dark"] .lang-dd .ld-menu { background: #16233D; color: #E6EDF8; border-color: #2A3B5E; box-shadow: 0 12px 32px rgba(0,0,0,.5); }
html[data-theme="dark"] .lang-dd .ld-menu a:hover { background: #1E2F52; }
html[data-theme="dark"] .lang-dd .ld-menu a.on { background: #1D4FA8; color: #FFFFFF; }
html[data-theme="dark"] .lang-dd .ld-cd, html[data-theme="dark"] .lang-dd .ld-hd { color: #9FB0CC; }
html[data-theme="dark"] .lang-dd .ld-ok { color: #A8C8FF; }
html[data-theme="dark"] .login-lang .lang-dd > summary { border-color: var(--line-strong); background: transparent; color: #A6B4CF; }
html[data-theme="dark"] .news-banner{background:#13264A;border-color:#27427A;color:#E8EEFA}
html[data-theme="dark"] .news-ic{background:#0B1630;color:#8DB4FF}
html[data-theme="dark"] .news-tx span,html[data-theme="dark"] .news-x,html[data-theme="dark"] .check small,html[data-theme="dark"] .acct-news .tx small{color:#A9B7D3}
html[data-theme="dark"] .acct-news{background:#111A2D;border-color:#233250;color:#E8EEFA}
html[data-theme="dark"] .news-ask{background:#2A2312;border-color:#5C4A17;color:#F3EBD3}
html[data-theme="dark"] .news-ask .news-tx span{color:#D9C98F}

/* v23bx-19: Discord board status card */
html[data-theme="dark"] .dc-pill{background:#243047;color:#B8C6DC}
html[data-theme="dark"] .dc-pill.ok{background:#12372D;color:#7FDDBB}
html[data-theme="dark"] :is(.dc-tile,.dc-empty){background:#1B2740}
html[data-theme="dark"] .dc-tile span,html[data-theme="dark"] .dc-empty,html[data-theme="dark"] .dc-note{color:#B8C6DC}
html[data-theme="dark"] .dc-tile b,html[data-theme="dark"] .dc-empty b{color:#F1F5FB}
html[data-theme="dark"] .dc-tile i{color:#93A3BD}
html[data-theme="dark"] .dc-tile.ok{background:#12372D}html[data-theme="dark"] .dc-tile.ok :is(span,b){color:#7FDDBB}
html[data-theme="dark"] .dc-tile.bad{background:#40201F}html[data-theme="dark"] .dc-tile.bad :is(span,b){color:#FF9D95}
html[data-theme="dark"] .btn.dc-danger,html[data-theme="dark"] .btn.dc-danger:hover{color:#FF9D95;border-color:#6B3430}

/* v23bx-20: closed-for-now notice */
html[data-theme="dark"] .gate-card { background: #151E2E; border-color: #2A3850; }
html[data-theme="dark"] .gate-icon { background: #3A2E10; color: #F2C766; }
html[data-theme="dark"] .gate-msg { color: #B6C3D9; }
html[data-theme="dark"] .gate-wait { background: #1F2D45; color: #CFE0FF; }
html[data-theme="dark"] .gate-help { border-color: #2A3850; color: #93A4C0; }
html[data-theme="dark"] .seg span { border-color: #2A3850; background: #151E2E; color: #B6C3D9; }
html[data-theme="dark"] .seg input:checked + span { border-color: #5B9BFF; background: #1B2D4D; color: #CFE0FF; }
html[data-theme="dark"] .dc-pill.bad { background: #3A1A17; color: #FFB4AA; }
html[data-theme="dark"] .dc-pill.warn { background: #3A2E10; color: #F2C766; }
html[data-theme="dark"] .card-body .gate-note { background: #1A2536; color: #93A4C0; }

/* v23bx-21: Contact us page */
html[data-theme="dark"] .ct-card { background: #151E2E; border-color: #2A3850; }
html[data-theme="dark"] .ct-lead { color: #B6C3D9; }
html[data-theme="dark"] .ct-what { color: #93A4C0; }
html[data-theme="dark"] .ct-ic { background: #1B2D4D; color: #8DB8FF; }
html[data-theme="dark"] body:has(> .band + .gate) { background: #0E1522; }
html[data-theme="dark"] .gate-q { color: #CFE0FF; }
html[data-theme="dark"] .gate-cl { color: #93A4C0; }
html[data-theme="dark"] .gate-contacts a { color: #8FB6FF; }
html[data-theme="dark"] .contact-list .cl-l { color: #93A4C0; }
html[data-theme="dark"] .login-help .lh-q { color: #CFE0FF; }

html[data-theme="dark"] .rp, html[data-theme="dark"] .rp-code { background: #151E2E; border-color: #2A3850; }
html[data-theme="dark"] .rp-late { background: #151E2E; }
html[data-theme="dark"] .rp-t b, html[data-theme="dark"] .rp-lbl, html[data-theme="dark"] .rp-late-h b, html[data-theme="dark"] .rp-code code { color: #E6EEFB; }
html[data-theme="dark"] .rp-t small, html[data-theme="dark"] .rp-sel, html[data-theme="dark"] .rp-code small, html[data-theme="dark"] .rp-late-h p { color: #93A4C0; }
html[data-theme="dark"] .rp-ic { background: #1B2D4D; color: #8DB8FF; }
html[data-theme="dark"] .rp-chip span { background: #151E2E; border-color: #2A3850; color: #CFE0FF; }
html[data-theme="dark"] .rp-chip input:checked + span { background: #1F6BF2; border-color: #1F6BF2; color: #FFFFFF; }
html[data-theme="dark"] .rp-code:has(input:checked) { background: #1A2A47; border-color: #4C86F0; }
html[data-theme="dark"] .rp-link, html[data-theme="dark"] .rp-mail { color: #8FB6FF; }
html[data-theme="dark"] .rp-note { background: #3A2E10; color: #F2C766; }
html[data-theme="dark"] .rp-hint { color: #F2C766; }
