/* Тёмная тема главной страницы. ФАЙЛ СОБРАН АВТОМАТИЧЕСКИ: python3 tools/dark-theme.py
   Включается атрибутом html[data-theme="dark"] (его ставит скрипт в <head> app.html:
   «как на устройстве», «тёмная» или «светлая» — кнопка 🌓 в шапке). Ручные правки —
   только в блоке «вручную» в конце tools/dark-theme.py. */

html[data-theme="dark"] {
  --bg: #12161c; --card: #1b2129; --text: #e6eaef; --muted: #8e9aaa; --line: #2c3540;
  --shadow: 0 1px 2px rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.35);
  color-scheme: dark;
}

:where(html[data-theme="dark"]) body { background: #1c2229; }
:where(html[data-theme="dark"]) code { background: #232931; }
:where(html[data-theme="dark"]) .btn.ghost { background: #1c2229; }
:where(html[data-theme="dark"]) .btn.ghost:hover { border-color: #3f454c; background: #1a212e; }
:where(html[data-theme="dark"]) .nav { background: rgba(255,255,255,0.074); }
:where(html[data-theme="dark"]) .hero { background: radial-gradient(900px 400px at 15% -10%, #17253c 0%, rgba(23,37,60,0) 70%),
  radial-gradient(700px 380px at 90% 0%, #233128 0%, rgba(35,49,40,0) 65%); }
:where(html[data-theme="dark"]) .pill { background: #1c2229; }
:where(html[data-theme="dark"]) .lead { color: #b6bec8; }
:where(html[data-theme="dark"]) .mock { background: #1c2229; }
:where(html[data-theme="dark"]) .mock-top { background: #1a212e; }
:where(html[data-theme="dark"]) .mock-top .dot { background: #2c3137; }
:where(html[data-theme="dark"]) .mock-day { background: #1c2229; }
:where(html[data-theme="dark"]) .mock-day.has { background: #142434; }
:where(html[data-theme="dark"]) .mock-dow { background: #20252d; color: #a1aab3; }
:where(html[data-theme="dark"]) .mock-day.other { background: #212529; }
:where(html[data-theme="dark"]) .mock-day.past .mock-chip { background: #223529; color: #94dcb2; }
:where(html[data-theme="dark"]) .mock-day.today { background: #152238; }
:where(html[data-theme="dark"]) .mock-chip { background: #17253c; color: #85bae4; }
:where(html[data-theme="dark"]) .card { background: #1c2229; }
:where(html[data-theme="dark"]) .step { background: #1c2229; }
:where(html[data-theme="dark"]) .how-note { background: #1c2229; color: #b6bec8; }
:where(html[data-theme="dark"]) .plan { background: #1c2229; }
:where(html[data-theme="dark"]) .plan-list li { border-bottom: 1px dashed #33383e; }
:where(html[data-theme="dark"]) .plan-list li.plan-sep { color: #aeb5bf; }
:where(html[data-theme="dark"]) details { background: #1c2229; }
:where(html[data-theme="dark"]) details p { color: #b6bec8; }
:where(html[data-theme="dark"]) .cta .btn.primary { background: #1c2229; }
:where(html[data-theme="dark"]) .cta .btn.primary:hover { background: #162239; }
:where(html[data-theme="dark"]) .auth-card { background: #1c2229; }
:where(html[data-theme="dark"]) .auth-tabs { background: #23282f; }
:where(html[data-theme="dark"]) .auth-tabs button.active { background: #1c2229; }
:where(html[data-theme="dark"]) .field input { background: #1c2229; }
:where(html[data-theme="dark"]) .form-error { color: #d1726b; }
:where(html[data-theme="dark"]) .auth-plan { background: #152538; border: 1px solid #243a55; color: #85bae4; }
:where(html[data-theme="dark"]) .help-toc { background: #1c2229; }
:where(html[data-theme="dark"]) .help-lead { color: #b1b9c8; }
:where(html[data-theme="dark"]) .help-body code { background: #232931; }
:where(html[data-theme="dark"]) .help-sub { color: #acb3c2; }
:where(html[data-theme="dark"]) .help-note { background: #152538; border: 1px solid #243a55; }
:where(html[data-theme="dark"]) .help-note.warn { background: #3a2d16; border-color: #584b31; }
:where(html[data-theme="dark"]) .help-pre { background: #21262d; border: 1px solid #353b42; }
:where(html[data-theme="dark"]) .captcha-btn { background: #1c2229; border: 1px solid #373f49; }
:where(html[data-theme="dark"]) .captcha-btn.picked { background: #16233b; }
:where(html[data-theme="dark"]) .link { color: #4c7bf0; }
:where(html[data-theme="dark"]) .compare-table { background: #1c2229; border: 1px solid #343c45; }
:where(html[data-theme="dark"]) .compare-table th, :where(html[data-theme="dark"]) .compare-table td { border-bottom: 1px solid #33383e; }
:where(html[data-theme="dark"]) .compare-table th { background: #20252d; color: #afb6bf; }
:where(html[data-theme="dark"]) .compare-table tr.us { background: #16233b; }
:where(html[data-theme="dark"]) .compare-table tr.us td { color: #c6d2dd; }
:where(html[data-theme="dark"]) .compare-note { color: #aab1b8; }
:where(html[data-theme="dark"]) .perk { background: #152037; border: 1px solid #28354d; color: #b6bec7; }
:where(html[data-theme="dark"]) .perk b { color: #c6d2dd; }
:where(html[data-theme="dark"]) .legal-gap { color: #d97178; background: #391d1a; }
:where(html[data-theme="dark"]) .legal-warn { background: #371515; border: 1px solid #523430; color: #dc9292; }
:where(html[data-theme="dark"]) .legal-note { background: #152037; border: 1px solid #28354d; }
:where(html[data-theme="dark"]) .legal-check { color: #b6bec7; }
:where(html[data-theme="dark"]) .auth-legal { color: #9ea5af; }
:where(html[data-theme="dark"]) .auth-legal a { color: #9ea5af; }
@media (max-width: 620px) {
  :where(html[data-theme="dark"]) .mock-chip { background: #1b2a47; }
}
:where(html[data-theme="dark"]) .pay-result p { color: #b6bec7; }
:where(html[data-theme="dark"]) .pay-code-box { background: #152037; border: 1px solid #28354d; }
:where(html[data-theme="dark"]) .pay-code-label { color: #b6bec7; }
:where(html[data-theme="dark"]) .pay-code { color: #c6d2dd; background: #1c2229; border: 1px solid #233252; }
:where(html[data-theme="dark"]) .pay-code-hint { color: #aab1b8; }
:where(html[data-theme="dark"]) .gw-promo { background: linear-gradient(120deg, #21163b, #16263b); border: 1px solid #332851; }
:where(html[data-theme="dark"]) .gw-promo:hover { border-color: #3b305d; }
:where(html[data-theme="dark"]) .gw-promo-go { color: var(--brand, #4c7bf0); }
:where(html[data-theme="dark"]) .social-hello { background: #151f36; }
:where(html[data-theme="dark"]) .footer-vk:hover { color: #4c99f0; }

html[data-theme="dark"] { --ink: #e6ebf1; --blue: #4d82ff; --blue-dark: #2f6bff; }
html[data-theme="dark"] .nav { background: rgba(18,22,28,.92); }
:where(html[data-theme="dark"]) body { background: #12161c; color: #e6ebf1; }
html[data-theme="dark"] { color-scheme: dark; }
html[data-theme="dark"] img:not([src$=".svg"]) { filter: brightness(.94); }
html[data-theme="dark"] ::selection { background: rgba(47,107,255,.45); }
.pd-theme-btn { background: transparent; border: 1px solid var(--line); border-radius: 999px; padding: 6px 10px;
  cursor: pointer; font-size: 16px; line-height: 1; color: inherit; }
