/* ============================================================
   TrustHer — Design System (single source of truth)
   Locked to the policy-report design language.
   Import this everywhere. Do not redefine tokens locally.
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,500;0,600;0,700;1,500;1,600&family=DM+Sans:wght@400;500;600;700&display=swap');

:root{
  /* — Color: ink & surface — */
  --ink:#1F1D2B;              /* primary text */
  --ink-2:#3A3746;            /* secondary text */
  --muted:#6B6878;            /* tertiary / labels */
  --paper:#FBFAF8;            /* page background */
  --white:#FFFFFF;            /* card surface */
  --cream:#F4EEE9;            /* subtle fill / info boxes */

  /* — Color: lines — */
  --line:rgba(31,29,43,.12);
  --line-strong:rgba(31,29,43,.22);

  /* — Color: brand & semantic — */
  --rose:#D94F8B;            /* signature / primary action */
  --rose-soft:#E7B6BA;       /* rose tints, provisional borders */
  --violet:#5B4FD1;          /* national-scope accent */
  --lavender:#DCD0DF;
  --green:#4F7A54;           /* established / success */
  --amber:#B7791F;           /* estimate / work-in-progress */

  /* — Elevation — */
  --shadow:0 1px 2px rgba(31,29,43,.04), 0 8px 24px rgba(31,29,43,.06);

  /* — Type families — */
  /* Primary Latin faces first, then Noto as the universal script fallback.
     Playfair/DM Sans render Latin; any glyph they lack (Arabic, CJK, Cyrillic,
     Devanagari …) falls through to Noto. Per-locale Noto subsets are loaded
     only for the active language, so the base page stays light. */
  --serif:'Playfair Display','Noto Serif',Georgia,serif;   /* display headings */
  --sans:'DM Sans','Noto Sans',system-ui,sans-serif;       /* body */
  --mono:'DM Sans','Noto Sans',system-ui,sans-serif;       /* labels (uppercase, letter-spaced) */

  /* — Type scale — */
  --fs-eyebrow:12px;
  --fs-body:16px;
  --fs-h4:18px;
  --fs-h3:22px;
  --fs-h2:26px;
  --lh-body:1.6;
  --lh-heading:1.12;

  /* — Radius scale — */
  --r-sm:8px;
  --r-md:12px;
  --r-lg:14px;
  --r-xl:16px;
  --r-pill:999px;

  /* — Spacing (4pt base) — */
  --sp-1:4px; --sp-2:8px; --sp-3:12px; --sp-4:16px;
  --sp-6:24px; --sp-8:32px; --sp-12:48px; --sp-16:64px;

  /* — Layout — */
  --wrap:1160px;
  --header-h:96px;           /* canonical header height — reserved before hydration */
}

/* ── Base ─────────────────────────────────────────────────── */
*{box-sizing:border-box}
body{
  margin:0;
  font-family:var(--sans);
  color:var(--ink);
  background:var(--paper);
  font-size:var(--fs-body);
  line-height:var(--lh-body);
  -webkit-font-smoothing:antialiased;
}
h1,h2,h3,h4{font-family:var(--serif);font-weight:600;line-height:var(--lh-heading);letter-spacing:-.01em}

/* ── Shared primitives ────────────────────────────────────── */
.th-wrap{max-width:var(--wrap);margin:0 auto;padding:0 var(--sp-8)}
.th-mono{font-family:var(--mono)}
.th-eyebrow{
  font-family:var(--mono);font-size:var(--fs-eyebrow);font-weight:600;
  letter-spacing:.18em;text-transform:uppercase;color:var(--rose);
}
.th-btn{
  display:inline-flex;align-items:center;gap:8px;
  font-family:var(--sans);font-size:14px;font-weight:600;
  color:#fff;background:var(--rose);
  border:none;border-radius:var(--r-pill);padding:11px 20px;
  text-decoration:none;cursor:pointer;transition:filter .16s ease,transform .16s ease;
}
.th-btn:hover{filter:brightness(1.05);transform:translateY(-1px)}
.th-btn--ghost{background:transparent;color:var(--ink);border:1px solid var(--line-strong)}
.th-btn--ghost:hover{background:var(--cream);filter:none}

.th-card{
  background:var(--white);border:1px solid var(--line);
  border-radius:var(--r-xl);padding:var(--sp-6);box-shadow:var(--shadow);
}

/* National-scope fence: regulation/school-policy is per-country (doctrine §6) */
.th-national{border-left:3px solid var(--violet)}

/* Estimate / confidence pills (doctrine §8) */
.th-est{
  display:inline-block;font-family:var(--mono);font-size:10.5px;letter-spacing:.06em;
  text-transform:uppercase;color:var(--amber);
  border:1px solid rgba(183,121,31,.5);border-radius:var(--r-pill);padding:2px 9px;
}

/* ─── Canonical site header (one nav for every page) ─── */
.th-top{position:sticky;top:0;z-index:50;background:rgba(251,250,248,.9);
  backdrop-filter:blur(10px);border-bottom:1px solid var(--line);min-height:var(--header-h)}
/* header spans the full viewport width (edge-to-edge), not the centered --wrap column */
.th-top .th-top__inner{max-width:none;padding-left:clamp(16px,4vw,40px);padding-right:clamp(16px,4vw,40px)}
/* Header height is FIXED at --header-h and independent of the logo. To make the
   wordmark bigger, only raise --logo-h (up to --header-h); the auto margins keep
   it vertically centred within the same bar so the header never grows taller.
   Do not add header padding to enlarge the logo. */
.th-top__inner{display:flex;align-items:center;justify-content:space-between;height:var(--header-h);padding-block:0;gap:24px}
.th-brand{display:flex;align-items:center;height:100%;text-decoration:none}
.th-brand img{--logo-h:90px;width:auto;height:var(--logo-h);max-height:var(--header-h)}
/* nav is right-aligned: pushed to the right side of the header, sitting just
   left of the actions cluster (language switch + CTA). margin-left:auto claims
   the free space after the brand so the links group on the right. */
.th-nav{display:flex;gap:24px;margin-left:auto;align-items:center;padding-bottom:2px}
.th-nav a{font-family:var(--sans);font-size:14px;font-weight:500;color:var(--ink-2);
  text-decoration:none;padding:6px 0;border-bottom:2px solid transparent;
  transition:color .15s,border-color .15s}
.th-nav a:hover{color:var(--ink);border-color:var(--rose)}
.th-nav a.is-active{color:var(--ink);border-color:var(--rose)}
/* CTA that lives inside the nav — shown only inside the mobile dropdown */
.th-nav__cta{display:none}
/* hamburger toggle — hidden on desktop, revealed ≤940px */
.th-nav-toggle{display:none;flex-direction:column;justify-content:center;gap:5px;
  width:44px;height:44px;padding:11px;margin:-2px -8px -2px 0;background:none;border:0;cursor:pointer}
.th-nav-toggle span{display:block;width:22px;height:2px;border-radius:2px;background:var(--ink);
  transition:transform .2s ease,opacity .2s ease}
.th-nav-toggle[aria-expanded="true"] span:nth-child(1){transform:translateY(7px) rotate(45deg)}
.th-nav-toggle[aria-expanded="true"] span:nth-child(2){opacity:0}
.th-nav-toggle[aria-expanded="true"] span:nth-child(3){transform:translateY(-7px) rotate(-45deg)}
@media(max-width:940px){
  .th-nav-toggle{display:flex}
  .th-top__cta{display:none}                 /* primary CTA moves into the dropdown */
  .th-nav{display:none;position:absolute;top:100%;left:0;right:0;flex-direction:column;
    align-items:stretch;gap:0;margin:0;padding:6px 0 10px;background:var(--paper);
    border-top:1px solid var(--line);border-bottom:1px solid var(--line);
    box-shadow:0 14px 26px rgba(31,29,43,.10)}
  .th-top--open .th-nav{display:flex}
  .th-nav a{font-size:16px;padding:13px clamp(16px,4vw,40px);border-bottom:0}
  .th-nav a:hover,.th-nav a.is-active{border-color:transparent;color:var(--ink)}
  .th-nav__cta{display:inline-flex;margin:8px clamp(16px,4vw,40px) 4px;
    justify-content:center;font-size:15px}
}
/* right-side cluster: language switch + primary CTA */
.th-top__actions{display:flex;align-items:center;gap:18px}
.th-lang{display:inline-flex;align-items:center;gap:2px;font-family:var(--sans);font-size:12px;
  font-weight:600;letter-spacing:.04em}
.th-lang a{color:var(--muted);text-decoration:none;padding:2px 5px;border-radius:6px;
  transition:color .15s,background .15s}
.th-lang a:hover{color:var(--ink)}
.th-lang a+a{border-left:1px solid var(--line);border-radius:0 6px 6px 0}
.th-lang a:first-child{border-radius:6px 0 0 6px}
html[lang="no"] .th-lang [data-lang="no"],
html[lang="en"] .th-lang [data-lang="en"]{color:var(--ink);background:var(--cream)}

/* jurisdiction switch — national-scope documents (doctrine §6), violet-fenced.
   Swaps between per-country documents (e.g. policy-no ↔ policy-us). This is
   NOT a language toggle: each national document is authored in its own language. */
.th-juris{display:inline-flex;align-items:center;font-family:var(--sans);font-size:12px;
  font-weight:600;letter-spacing:.03em;border:1px solid var(--violet);border-radius:8px;overflow:hidden}
.th-juris a{color:var(--violet);text-decoration:none;padding:4px 10px;line-height:1.2;
  transition:color .15s,background .15s}
.th-juris a+a{border-left:1px solid var(--violet)}
.th-juris a:hover{background:rgba(91,79,209,.09)}
.th-juris a.is-active{background:var(--violet);color:#fff}

/* ─── Canonical site footer (one footer for every page) ─── */
.th-ftr{background:var(--ink);color:rgba(255,255,255,.7);padding:56px 0 64px}
.th-ftr__inner{display:flex;justify-content:space-between;gap:24px;flex-wrap:wrap;align-items:flex-start}
.th-ftr__brand{max-width:360px}
.th-ftr__tag{margin-top:16px;font-size:14px;line-height:1.6}
.th-ftr__cols{display:flex;gap:56px;flex-wrap:wrap}
.th-ftr__col b{color:#fff;font-family:var(--sans);font-size:12px;letter-spacing:.1em;
  text-transform:uppercase;display:block;margin-bottom:12px}
.th-ftr__col a{display:block;color:rgba(255,255,255,.7);text-decoration:none;font-size:14px;padding:4px 0}
.th-ftr__col a:hover{color:#fff}
.th-ftr__fine{margin-top:36px;padding-top:20px;border-top:1px solid rgba(255,255,255,.12);
  font-size:13px;line-height:1.6;color:rgba(255,255,255,.55);max-width:70ch}
