/* ADHD Advocacy Georgia
   Plain, dense, information-first. Square corners, ruled sections, red for emphasis.
   Noto Sans + Noto Sans Georgian so both languages share one typeface.
   Accessibility: visible focus ring, 40px+ controls, AA contrast in both themes. */

:root {
  --paper: #ffffff;
  --panel: #f6f2ec;
  --ink: #1d1f22;
  --muted: #565c64;
  --line: #e2dcd2;
  --red: #b5121b;
  --red-ink: #ffffff;
  --red-soft: #f9e9e8;
  --link: #9c1018;
  --ribbon: #f28c28;
  --amber: #7a5000;
  --amber-soft: #fbf1d9;
  --green: #1b6e46;
  --footer-bg: #111315;
  --footer-ink: #d4d6d9;
  --focus: #1a5fb4;
  --font: "Noto Sans", "Noto Sans Georgian", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --wrap: 1100px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #121416;
    --panel: #1b1e21;
    --ink: #ecebe7;
    --muted: #a6abb2;
    --line: #34383d;
    --red: #e5484d;
    --red-ink: #121416;
    --red-soft: #2b1618;
    --link: #ff8f8f;
    --ribbon: #f5a35c;
    --amber: #f0b54a;
    --amber-soft: #2c2311;
    --green: #5fd39a;
    --footer-bg: #0a0b0c;
    --footer-ink: #c9ccd1;
    --focus: #8ab4ff;
  }
}
:root[data-theme="dark"] {
  --paper: #121416;
  --panel: #1b1e21;
  --ink: #ecebe7;
  --muted: #a6abb2;
  --line: #34383d;
  --red: #e5484d;
  --red-ink: #121416;
  --red-soft: #2b1618;
  --link: #ff8f8f;
  --ribbon: #f5a35c;
  --amber: #f0b54a;
  --amber-soft: #2c2311;
  --green: #5fd39a;
  --footer-bg: #0a0b0c;
  --footer-ink: #c9ccd1;
  --focus: #8ab4ff;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 12px; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 18px/1.65 var(--font); }
@media (min-width: 1000px) { body { font-size: 17px; } }
body:lang(ka) { line-height: 1.75; }

a { color: var(--link); text-underline-offset: 2px; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
p { margin: 0 0 .9em; }
ul, ol { margin: 0 0 1em; padding-left: 1.3em; }
li { margin-bottom: .35em; }
b, strong { font-weight: 700; }
h1, h2, h3 { line-height: 1.22; margin: 0; overflow-wrap: break-word; }
h1 { font-size: clamp(1.8rem, 4vw, 2.5rem); font-weight: 700; letter-spacing: -0.01em; }
h2 { font-size: 1.4rem; font-weight: 700; margin: 2em 0 .6em; padding-top: 16px; border-top: 1px solid var(--line); }
h3 { font-size: 1.05rem; font-weight: 700; margin: 1.5em 0 .4em; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 16px; }
@media (min-width: 720px) { .wrap { padding: 0 28px; } }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--paper); padding: 8px 12px; z-index: 30; }
.skip:focus { left: 8px; }

/* Keyboard focus: a clear 3px ring on everything interactive */
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 2px; }
.site-footer :focus-visible { outline-color: #ffd166; }
@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; transition: none !important; animation: none !important; } }

/* ---------- Header ---------- */
.site-header { border-top: 5px solid var(--red); border-bottom: 1px solid var(--line); background: var(--paper); position: relative; z-index: 20; }
.site-header .wrap { display: flex; align-items: center; gap: 14px; min-height: 60px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-weight: 700; line-height: 1.15; margin-right: auto; max-width: 15rem; }
.brand svg { flex: none; display: block; }
.brand span { font-size: 1.05rem; }

.primary-nav { display: none; gap: 20px; font-size: .93rem; }
.primary-nav a { color: var(--ink); text-decoration: none; padding: 18px 0 16px; border-bottom: 3px solid transparent; white-space: nowrap; }
.primary-nav a:hover, .primary-nav a[aria-current="page"] { border-bottom-color: var(--red); }
@media (min-width: 1120px) { .primary-nav { display: flex; } }
.site-header .wrap { max-width: 1280px; }
:lang(ka) .brand { max-width: 16rem; flex-shrink: 0; }
@media (max-width: 560px) { :lang(ka) .brand { flex-shrink: 1; } }
@media (max-width: 1239px) { :lang(ka) .primary-nav { display: none; } }
@media (max-width: 420px) {
  .site-header .wrap { gap: 6px; }
  .brand { gap: 7px; min-width: 0; }
  .brand svg { width: 22px; height: 33px; }
  .brand span, :lang(ka) .brand span { font-size: .88rem; }
  .lang-switch { padding: 8px; }
}

.lang-switch { font-size: .9rem; font-weight: 700; color: var(--ink); text-decoration: none; border: 1px solid var(--ink); padding: 8px 12px; min-height: 40px; display: inline-flex; align-items: center; white-space: nowrap; }
.lang-switch:hover { background: var(--ink); color: var(--paper); }

.btn { display: inline-block; padding: 10px 16px; font-weight: 700; font-size: .95rem; text-decoration: none; white-space: nowrap; border: 2px solid transparent; line-height: 1.2; border-radius: 2px; }
.btn-red { background: var(--red); color: var(--red-ink); }
.btn-red:hover { filter: brightness(1.08); }
.btn-outline { border-color: var(--ink); color: var(--ink); }
.btn-outline:hover { background: var(--ink); color: var(--paper); }
.site-header .btn { padding: 7px 12px; font-size: .9rem; }
@media (max-width: 560px) { .site-header .btn-red { display: none; } .brand { font-size: .95rem; } }

.menu > summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; min-height: 40px; border: 1px solid var(--ink); font-size: .9rem; font-weight: 700; user-select: none; }
.menu > summary::-webkit-details-marker { display: none; }
.menu > summary .bars { width: 16px; height: 2px; background: var(--ink); box-shadow: 0 -5px 0 var(--ink), 0 5px 0 var(--ink); }
.menu[open] > summary { background: var(--panel); }
@media (max-width: 560px) { .menu-label { display: none; } .menu > summary { padding: 9px 12px; min-width: 44px; min-height: 44px; justify-content: center; } }
.menu-panel { position: absolute; left: 0; right: 0; top: 100%; background: var(--paper); border-bottom: 2px solid var(--ink); }
.menu-panel .wrap { display: grid; gap: 4px 32px; grid-template-columns: 1fr; padding-top: 8px; padding-bottom: 20px; align-items: start; }
@media (min-width: 640px) { .menu-panel .wrap { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .menu-panel .wrap { grid-template-columns: repeat(4, 1fr); } }
.menu-group h2 { font-size: .82rem; font-weight: 700; color: var(--muted); border: 0; padding: 0; margin: 14px 0 2px; }
.menu-group h2::before { display: none; }
.menu-panel a { display: block; padding: 11px 0; text-decoration: none; color: var(--ink); border-bottom: 1px solid var(--line); font-weight: 700; }
.menu-panel a:hover { color: var(--link); text-decoration: underline; }
.menu-panel a[aria-current="page"] { color: var(--link); box-shadow: inset 3px 0 0 var(--red); padding-left: 10px; }

/* Light/dark toggle: an icon button in the header; on very narrow phones it moves into the menu */
.theme-toggle { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-width: 40px; min-height: 40px; padding: 0 12px; background: none; border: 1px solid var(--ink); color: var(--ink); font: inherit; font-size: .9rem; font-weight: 700; cursor: pointer; }
.theme-toggle:hover { background: var(--panel); }
.theme-toggle svg { width: 18px; height: 18px; flex: none; }
.theme-toggle .icon-sun, .theme-toggle[data-mode="dark"] .icon-moon { display: none; }
.theme-toggle[data-mode="dark"] .icon-sun { display: block; }
.header-theme { padding: 0; width: 40px; flex: none; }
.menu-panel .menu-tools { display: none; padding-top: 12px; padding-bottom: 0; }
@media (max-width: 560px) { .header-theme { width: 44px; min-height: 44px; } }
@media (max-width: 420px) { .header-theme { width: 40px; } }
/* exactly one toggle is visible: the header one from 360px up, the menu one below */
@media (max-width: 359px) { .header-theme { display: none; } .menu-panel .menu-tools { display: block; } }

.alert-strip { background: var(--amber-soft); border-bottom: 1px solid var(--line); }
.alert-strip .wrap { padding-top: 10px; padding-bottom: 10px; font-size: .95rem; }
.alert-strip b { color: var(--amber); }

/* ---------- Page heads ---------- */
.page-head { padding: 24px 0 8px; }
@media (min-width: 720px) { .page-head { padding: 36px 0 8px; } }
.crumbs { font-size: .85rem; color: var(--muted); margin-bottom: 8px; }
.crumbs a { color: var(--muted); }
.lede { font-size: 1.12rem; color: var(--muted); max-width: 46rem; margin: 12px 0 0; }
.updated { font-size: .82rem; color: var(--muted); margin: 14px 0 0; }

.keypoints { background: var(--panel); border-left: 4px solid var(--red); border-radius: 0 4px 4px 0; padding: 16px 20px 6px; margin-top: 22px; max-width: 50rem; }
.keypoints h2 { font-size: .95rem; border: 0; padding: 0; margin: 0 0 6px; }
.keypoints ul { margin-bottom: 10px; }

/* ---------- Body layout ---------- */
.page-body { padding-top: 0; padding-bottom: 56px; }
.with-toc { display: grid; grid-template-columns: 1fr; gap: 0 44px; }
@media (min-width: 1000px) { .with-toc { grid-template-columns: 210px minmax(0, 1fr); } }
.toc { font-size: .9rem; margin-top: 30px; }
.toc h2 { font-size: .9rem; border-top: 1px solid var(--line); margin: 0 0 6px; padding-top: 10px; }
.toc ol { list-style: none; padding: 0; margin: 0; }
.toc li { margin: 0; border-bottom: 1px solid var(--line); }
.toc a { display: block; padding: 6px 0; color: var(--ink); text-decoration: none; }
.toc a:hover { color: var(--link); text-decoration: underline; }
@media (min-width: 1000px) { .toc nav { position: sticky; top: 16px; } }
@media (max-width: 999px) { .toc ol { columns: 2; column-gap: 18px; font-size: .86rem; } .toc li { break-inside: avoid; } }

.prose { max-width: 46rem; }

/* ---------- Components ---------- */
.callout { padding: 14px 18px; margin: 1.3em 0; background: var(--panel); border-left: 4px solid var(--muted); border-radius: 0 4px 4px 0; }
.callout p:last-child, .callout ul:last-child { margin-bottom: 0; }
.callout.important { background: var(--red-soft); border-left-color: var(--red); }
.callout.status { background: var(--amber-soft); border-left-color: var(--amber); }
.callout-title { font-weight: 700; display: block; margin-bottom: 3px; }

/* Facts row */
.facts { display: grid; grid-template-columns: 1fr 1fr; margin: 26px 0 0; border-top: 1px solid var(--line); }
@media (min-width: 860px) { .facts { grid-template-columns: repeat(4, 1fr); } }
.fact { padding: 12px 14px 14px 0; border-bottom: 1px solid var(--line); }
@media (min-width: 860px) { .fact { border-bottom: 0; padding-right: 18px; } .fact + .fact { border-left: 1px solid var(--line); padding-left: 18px; } }
.fact b { display: block; font-size: 1.85rem; line-height: 1.1; color: var(--red); margin-bottom: 4px; }
.fact span { font-size: .88rem; color: var(--muted); display: block; line-height: 1.45; }

/* Home */
.home-head { padding: 28px 0 8px; }
@media (min-width: 720px) { .home-head { padding: 40px 0 8px; } }
.home-head h1 { max-width: 26ch; }
:lang(ka) .home-head h1 { max-width: 32ch; }
:lang(ka) h1 { font-size: clamp(1.6rem, 3.4vw, 2.15rem); }
:lang(ka) h2 { font-size: 1.25rem; }
.home-head .actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.section { padding: 8px 0 8px; }
.section-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 20px; border-top: 1px solid var(--line); margin-top: 40px; padding-top: 16px; }
.section-head h2 { border: 0; padding: 0; margin: 0; }
.section-head a { font-size: .92rem; }

/* Quick answers */
.qa { display: grid; grid-template-columns: 1fr; gap: 0 36px; margin-top: 8px; }
@media (min-width: 820px) { .qa { grid-template-columns: 1fr 1fr; } }
.qa-item { border-bottom: 1px solid var(--line); padding: 14px 0; }
.qa-item h3 { margin: 0 0 4px; font-size: 1.02rem; }
.qa-item p { margin: 0 0 4px; }
.qa-item a.more { font-size: .9rem; font-weight: 700; }

/* Where to start (home) */
.tasks { display: grid; grid-template-columns: 1fr; gap: 12px; margin-top: 12px; }
@media (min-width: 720px) { .tasks { grid-template-columns: 1fr 1fr; } }
.task { display: block; padding: 16px 18px; border: 1px solid var(--line); border-radius: 4px; background: var(--panel); color: var(--ink); text-decoration: none; }
.task:hover { border-color: var(--red); }
.task strong { display: block; font-size: 1.08rem; margin-bottom: 3px; }
.task span { display: block; color: var(--muted); font-size: .95rem; line-height: 1.5; }
.task strong::after { content: " →"; content: " →" / ""; color: var(--red); }
.plain-list { list-style: none; padding: 0; margin: 10px 0 0; }
.plain-list li { padding: 10px 0 10px 22px; border-bottom: 1px solid var(--line); margin: 0; position: relative; }
.plain-list li::before { content: ""; position: absolute; left: 4px; top: 1.05em; width: 8px; height: 8px; background: var(--red); border-radius: 50%; }

/* Numbered asks */
.asks { counter-reset: ask; list-style: none; padding: 0; margin: 8px 0 0; }
.asks > li { counter-increment: ask; position: relative; padding: 14px 0 14px 48px; border-bottom: 1px solid var(--line); margin: 0; }
.asks > li::before { content: counter(ask); position: absolute; left: 0; top: 14px; width: 30px; height: 30px; background: var(--red); color: var(--red-ink); display: grid; place-items: center; font-weight: 700; font-size: .9rem; }
.asks h3 { margin: 0 0 4px; font-size: 1.02rem; }
.asks p { margin: 0 0 .45em; color: var(--muted); font-size: .96rem; }
.asks p:last-child { margin-bottom: 0; }

/* News */
.news-list { list-style: none; padding: 0; margin: 8px 0 0; }
.news-item { border-bottom: 1px solid var(--line); padding: 16px 0; margin: 0; }
.news-meta { font-size: .84rem; color: var(--muted); margin-bottom: 4px; }
.news-meta .tag { font-weight: 700; color: var(--ink); }
.news-meta .tag.georgia { color: var(--red); }
.news-item h3 { margin: 0 0 6px; font-size: 1.08rem; }
.news-item p { margin: 0 0 .55em; }

/* Tables */
.table-wrap { margin: 1.1em 0; }
table.data { width: 100%; border-collapse: collapse; font-size: .93rem; line-height: 1.45; }
.data th, .data td { text-align: left; vertical-align: top; padding: 9px 10px; border-bottom: 1px solid var(--line); }
.data thead th { font-size: .85rem; color: var(--muted); border-bottom: 2px solid var(--ink); }
.data tbody th { font-weight: 700; }
.data .ge { background: var(--red-soft); }
.data thead th.ge { color: var(--red); }
.mark { display: inline-block; width: 1.3em; font-weight: 700; }
.yes .mark { color: var(--green); }
.part .mark { color: var(--amber); }
.no .mark { color: var(--red); }
.unk .mark { color: var(--muted); }
.table-key { font-size: .84rem; color: var(--muted); }
@media (max-width: 760px) {
  .data, .data tbody, .data tr, .data th, .data td { display: block; width: 100%; }
  .data thead { display: none; }
  .data tr { border-top: 2px solid var(--ink); margin-bottom: 14px; }
  .data tbody th { border-bottom: 1px solid var(--line); padding-left: 0; }
  .data td { border-bottom: 1px solid var(--line); padding: 7px 10px; }
  .data td::before { content: attr(data-label); display: block; font-size: .8rem; font-weight: 700; color: var(--muted); }
}

dl.terms dt { font-weight: 700; margin-top: 1em; }
dl.terms dd { margin: .2em 0 0; }

.checklist { list-style: none; padding: 0; }
.checklist > li { position: relative; padding-left: 28px; }
.checklist > li::before { content: ""; position: absolute; left: 2px; top: .38em; width: 13px; height: 13px; border: 2px solid var(--red); }

.resource-list { list-style: none; padding: 0; margin: 0 0 1.2em; }
.resource-list li { border-bottom: 1px solid var(--line); padding: 10px 0; margin: 0; }
.resource-list a { font-weight: 700; }
.resource-list span { display: block; color: var(--muted); font-size: .92rem; }

/* FAQ: expandable questions */
.faq-toggle { font: inherit; font-size: .92rem; font-weight: 700; color: var(--link); background: none; border: 1px solid currentColor; padding: 8px 12px; min-height: 40px; cursor: pointer; margin-top: 28px; }
.faq-toggle:hover { background: var(--panel); }
.faq { border-bottom: 1px solid var(--line); }
.faq > summary { list-style: none; cursor: pointer; display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 14px 0; }
.faq > summary::-webkit-details-marker { display: none; }
.faq > summary h3 { margin: 0; font-size: 1.05rem; line-height: 1.4; }
.faq > summary:hover h3 { color: var(--link); }
.faq > summary::after { content: ""; flex: none; width: 9px; height: 9px; margin: .4em 4px 0 0; border-right: 2px solid var(--red); border-bottom: 2px solid var(--red); transform: rotate(45deg); transition: transform .15s; }
.faq[open] > summary::after { transform: rotate(-135deg); margin-top: .65em; }
.faq-answer { padding: 0 0 16px; }
.faq-answer p:last-child { margin-bottom: 0; }

/* Citations + sources */
sup.cite { line-height: 0; font-size: .7em; white-space: nowrap; color: var(--muted); }
sup.cite a { text-decoration: none; padding: 0 1px; color: var(--muted); }
sup.cite a:hover { color: var(--link); }
.sources { margin-top: 2.6em; }
.sources h2 { font-size: 1rem; margin: 0 0 .6em; }
.sources ol { font-size: .86rem; line-height: 1.5; color: var(--muted); padding-left: 1.8em; }
.sources li { overflow-wrap: anywhere; margin-bottom: .4em; }
.sources li:target { background: var(--amber-soft); }

/* ---------- Footer ---------- */
.site-footer { background: var(--footer-bg); color: var(--footer-ink); font-size: .9rem; margin-top: 24px; }
.site-footer a { color: #ffffff; text-decoration: underline; text-decoration-color: #6b7178; text-underline-offset: 3px; }
.site-footer a:hover { text-decoration-color: currentColor; }
.site-footer a[aria-current="page"] { font-weight: 700; }
.footer-grid { display: grid; gap: 24px; grid-template-columns: 1fr; padding-top: 36px; padding-bottom: 24px; }
@media (min-width: 760px) { .footer-grid { grid-template-columns: repeat(4, 1fr); } }
.footer-grid h2 { font-size: .9rem; color: #9aa0a8; border: 0; padding: 0; margin: 0 0 8px; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-grid li { margin-bottom: 8px; }
.footer-brand { display: flex; gap: 10px; align-items: flex-start; }
.footer-brand p { margin: 0 0 .5em; }
.footer-bottom { border-top: 1px solid #2c3036; padding-top: 14px; padding-bottom: 28px; font-size: .82rem; color: #9aa0a8; display: flex; flex-wrap: wrap; gap: 10px 24px; justify-content: space-between; align-items: center; }
.footer-meta { max-width: 52rem; }
.footer-meta p { margin: 0 0 .45em; }

@media (forced-colors: active) {
  .keypoints, .callout, .task { border: 1px solid CanvasText; }
  .menu > summary .bars { background: CanvasText; box-shadow: 0 -5px 0 CanvasText, 0 5px 0 CanvasText; }
}

/* ---------- Print: keep the content, drop the chrome ---------- */
@media print {
  .site-header, .alert-strip, .toc, .site-footer, .skip, .actions, .faq-toggle { display: none !important; }
  .faq > summary::after { display: none; }
  body { font-size: 11pt; color: #000; background: #fff; }
  a { color: #000; }
  .keypoints, .callout { border-left-width: 3px; background: none; }
}
