/* Відкриті сторінки питань (baza/, tools/build-seo.js). Кольори й шрифти — ті самі, що в застосунку (app/app.css). */
@font-face { font-family: Onest; font-weight: 400 800; font-display: swap; src: url(/fonts/onest-cyr.woff2) format('woff2'); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: Onest; font-weight: 400 800; font-display: swap; src: url(/fonts/onest-lat.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: Unbounded; font-weight: 500 800; font-display: swap; src: url(/fonts/unbounded-cyr.woff2) format('woff2'); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: Unbounded; font-weight: 500 800; font-display: swap; src: url(/fonts/unbounded-lat.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
  --cobalt: #2446d8; --cobalt-edge: #1a32a3; --cobalt-soft: #e6ebff;
  --mint: #3dd6a0; --mint-edge: #1fa87a; --mint-soft: #dcf8ee; --mint-ink: #0b6e4f;
  --bg: #f4f6fb; --card: #fff; --ink: #141a38; --ink-2: #5a6285; --line: #e3e7f2;
  --display: Unbounded, 'Segoe UI', system-ui, sans-serif;
  --text: Onest, 'Segoe UI', system-ui, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --cobalt: #5b7bff; --cobalt-edge: #3452d6; --cobalt-soft: #1f2a66;
    --mint: #36c893; --mint-edge: #1f8f68; --mint-soft: #123d33; --mint-ink: #7ff0c6;
    --bg: #0e1330; --card: #182048; --ink: #eef1ff; --ink-2: #a3aacc; --line: #28305e;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 17px/1.55 var(--text); }
a { color: var(--cobalt); }
:focus-visible { outline: 3px solid #ffc933; outline-offset: 2px; }
.i { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
h1, h2 { font-family: var(--display); font-weight: 700; letter-spacing: -.01em; margin: 0; }
.wrap { max-width: 720px; margin: 0 auto; padding: 0 16px; }

/* шапка */
.top { position: sticky; top: 0; z-index: 2; background: var(--bg); border-bottom: 2px solid var(--line); }
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 10px; padding-bottom: 10px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-family: var(--display); font-weight: 700; font-size: 14px; line-height: 1.1; }
.mark { width: 36px; height: 36px; border-radius: 11px; background: var(--cobalt); color: #fff; display: grid; place-items: center; box-shadow: 0 3px 0 var(--cobalt-edge); }
.mark .i { width: 22px; height: 22px; }
.tg { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 999px; border: 2px solid var(--line); background: var(--card); color: var(--ink); font-weight: 700; font-size: 14px; text-decoration: none; }
.tg .i { width: 18px; height: 18px; color: var(--cobalt); }

main { padding-top: 14px; padding-bottom: 40px; }
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 6px; margin: 4px 0 16px; font-size: 14px; font-weight: 600; }
.crumbs a { color: var(--ink-2); text-decoration: none; }
.crumbs a:hover { color: var(--cobalt); text-decoration: underline; }
.crumbs .i { width: 14px; height: 14px; color: var(--ink-2); }

/* вступ */
.hero { margin: 8px 0 22px; }
main > .hero:first-child { margin-top: 20px; }
.hero h1 { font-size: clamp(24px, 6vw, 34px); line-height: 1.15; }
.lead { margin: 12px 0 0; color: var(--ink-2); max-width: 60ch; }
.rm-big { margin: 0 0 6px; font-family: var(--display); font-weight: 800; font-size: 15px; color: var(--cobalt); }

/* розділи на головній */
.secs { list-style: none; margin: 0 0 28px; padding: 0; display: grid; gap: 10px; }
.secs a { display: flex; align-items: center; gap: 14px; padding: 16px; border-radius: 16px; background: var(--card); border: 2px solid var(--line); color: var(--ink); text-decoration: none; }
.secs a:hover { border-color: var(--cobalt); }
.secs .rm { width: 48px; flex: none; font-family: var(--display); font-weight: 800; font-size: 16px; color: var(--cobalt); }
.secs .t { flex: 1; min-width: 0; display: grid; }
.secs b { font-size: 17px; }
.secs small { color: var(--ink-2); font-size: 14px; }
.secs .i { color: var(--ink-2); }

/* список питань розділу */
.sub { font-size: 16px; margin: 26px 0 10px; }
.qs, .more ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.qs a, .more a:not(.all) { display: flex; gap: 12px; padding: 10px 12px; border-radius: 12px; color: var(--ink); text-decoration: none; font-size: 15px; line-height: 1.4; background: var(--card); border: 2px solid transparent; }
.qs a:hover, .more a:not(.all):hover { border-color: var(--line); }
.qs .n, .more .n { width: 34px; flex: none; text-align: right; font-family: var(--display); font-weight: 700; font-size: 12px; line-height: 21px; color: var(--ink-2); }

/* питання: правильна відповідь — головне на сторінці */
.q { background: var(--card); border: 2px solid var(--line); border-radius: 20px; padding: 20px 18px; }
.q .meta { margin: 0 0 10px; font-family: var(--display); font-weight: 800; font-size: 14px; color: var(--cobalt); }
.q .meta span { margin-left: 8px; font-family: var(--text); font-weight: 600; color: var(--ink-2); }
.q h1 { font-family: var(--text); font-weight: 700; font-size: clamp(20px, 5vw, 24px); line-height: 1.35; letter-spacing: 0; }
.multi { margin: 10px 0 0; font-size: 14px; font-weight: 700; color: var(--ink-2); }
.opts { list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 8px; }
.opts li { display: flex; gap: 12px; align-items: flex-start; padding: 10px 12px; border-radius: 14px; color: var(--ink-2); font-size: 16px; line-height: 1.45; }
.opts .k { width: 22px; flex: none; text-align: center; font-family: var(--display); font-size: 12px; font-weight: 700; line-height: 23px; }
.opts li.ok { padding: 14px 14px; background: var(--mint-soft); color: var(--mint-ink); font-weight: 700; font-size: 18px; box-shadow: inset 0 0 0 2px var(--mint); }
.opts li.ok .i { width: 24px; height: 24px; stroke-width: 3; margin-top: 1px; }
.ex { margin-top: 20px; padding-top: 16px; border-top: 2px solid var(--line); }
.ex h2 { font-size: 15px; margin-bottom: 8px; }
.ex div { font-size: 16px; color: var(--ink); max-width: 68ch; }

/* заклик у Telegram */
.cta { margin: 22px 0; padding: 20px 18px; border-radius: 20px; background: var(--cobalt); color: #fff; }
.cta h2 { font-size: 19px; }
.cta p { margin: 8px 0 16px; color: rgba(255, 255, 255, .86); font-size: 15px; max-width: 58ch; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 50px; padding: 12px 20px; border-radius: 16px; background: #fff; color: var(--cobalt-edge); font-family: var(--display); font-weight: 700; font-size: 15px; text-decoration: none; box-shadow: 0 4px 0 rgba(10, 20, 80, .35); }
.btn:active { transform: translateY(3px); box-shadow: 0 1px 0 rgba(10, 20, 80, .35); }
@media (prefers-color-scheme: dark) { .cta { background: var(--cobalt-soft); } .btn { color: #1f2a66; } }

/* сусідні й ще питання */
.pn { display: flex; justify-content: space-between; gap: 12px; margin: 0 0 26px; }
.pn a { display: inline-flex; align-items: center; gap: 6px; padding: 10px 14px; border-radius: 12px; background: var(--card); border: 2px solid var(--line); color: var(--ink); font-weight: 700; font-size: 15px; text-decoration: none; }
.more h2 { font-size: 16px; margin-bottom: 10px; }
.all { display: inline-block; margin-top: 12px; font-weight: 700; }

.foot { border-top: 2px solid var(--line); padding: 18px 0 28px; font-size: 13px; color: var(--ink-2); }
.foot p { margin: 0 0 8px; max-width: 70ch; }
.foot .links { display: flex; flex-wrap: wrap; gap: 4px 16px; }
.foot a { color: var(--ink-2); }

/* платні питання: місце для відповіді (baza.js) */
.q h1 img, .opts img { display: block; max-width: 100%; height: auto; margin: 10px 0; border-radius: 8px; background: #fff; }
.reveal { margin-top: 16px; padding: 16px; border-radius: 16px; border: 2px dashed var(--mint-edge); }
.rv-t { margin: 0; font-family: var(--display); font-weight: 700; font-size: 15px; }
.rv-s { margin: 6px 0 14px; color: var(--ink-2); font-size: 15px; max-width: 58ch; }
.reveal.done, .reveal.limit { border-style: solid; }
.reveal.done { border-color: var(--mint); background: var(--mint-soft); }
.reveal.done .rv-t { color: var(--mint-ink); }
.reveal.limit { border-color: var(--line); }
.reveal.done .rv-s, .reveal.limit .rv-s { margin-bottom: 0; }
.reveal a { font-weight: 700; }
.btn.pri { background: var(--cobalt); color: #fff; box-shadow: 0 4px 0 var(--cobalt-edge); border: 0; cursor: pointer; }
.btn.pri:active { box-shadow: 0 1px 0 var(--cobalt-edge); }
.btn.pri:disabled { opacity: .7; cursor: default; transform: none; }
@media (prefers-color-scheme: dark) { .btn.pri { color: #fff; } }
