/* ===================================================================
   Shikshanova Foundation — Design System
   Palette: deep navy (trust / institutional) + gold (from the logo)
   + crimson for calls to action.
   =================================================================== */
:root {
  --ink: #10243D;           /* deep navy — header, footer, dark sections */
  --ink-soft: #1B3A5C;
  --paper: #F6F8FB;         /* page background */
  --paper-deep: #E9EFF6;
  --gold: #E9A227;          /* primary accent, from the logo */
  --gold-deep: #C8861A;
  --crimson: #C0392B;       /* CTA buttons */
  --crimson-deep: #9E2E22;
  --azure: #1B6AA5;         /* links */
  --text: #1C2630;
  --text-soft: #4A5A6A;
  --line: #D8E2EE;
  --white: #FFFFFF;

  /* legacy aliases so older inline styles keep working */
  --marigold: var(--gold);
  --brick: var(--crimson);
  --teal: var(--azure);

  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Work Sans", system-ui, -apple-system, sans-serif;

  --max-width: 1140px;
  --radius: 8px;
  --shadow: 0 2px 10px rgba(16,36,61,0.06);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--text);
  background: var(--paper);
  line-height: 1.65;
  font-size: 17px;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--azure); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--ink);
  line-height: 1.2;
  margin: 0 0 0.5em;
  font-weight: 600;
}
h1 { font-size: clamp(2.1rem, 5vw, 3.3rem); }
h2 { font-size: clamp(1.55rem, 3.4vw, 2.2rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1em; max-width: 68ch; color: var(--text-soft); }

.container { max-width: var(--max-width); margin: 0 auto; padding: 0 24px; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--gold); color: var(--ink);
  padding: 10px 18px; font-weight: 600; z-index: 200;
}
.skip-link:focus { left: 8px; top: 8px; }

/* ---------- Top utility bar ---------- */
.topbar {
  background: var(--ink-soft);
  color: #D6E2F0;
  font-size: 0.88rem;
}
.topbar-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 8px 24px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 18px;
  flex-wrap: wrap;
}
.topbar a { color: #D6E2F0; font-weight: 500; }
.topbar a:hover { color: var(--gold); text-decoration: none; }
.topbar .btn-donate {
  background: var(--crimson);
  color: var(--white);
  padding: 5px 16px;
  border-radius: 999px;
  font-weight: 600;
}
.topbar .btn-donate:hover { background: var(--crimson-deep); color: var(--white); }
.social-icons { display: flex; gap: 10px; align-items: center; }
.social-icons a {
  width: 28px; height: 28px;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid rgba(255,255,255,0.35);
  border-radius: 50%;
}
.social-icons svg { width: 14px; height: 14px; fill: currentColor; }
@media (max-width: 620px) { .topbar-inner { justify-content: center; gap: 12px; } }

/* ---------- Header / Nav ---------- */
.site-header {
  background: var(--ink);
  color: var(--paper);
  position: sticky; top: 0; z-index: 50;
  border-bottom: 3px solid var(--gold);
}
.nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 24px; max-width: var(--max-width); margin: 0 auto;
}
.brand {
  display: flex; align-items: center; gap: 10px;
  color: var(--paper); font-family: var(--font-display);
  font-size: 1.2rem; font-weight: 600;
}
.brand:hover { text-decoration: none; }
.brand-mark { width: 38px; height: 38px; flex-shrink: 0; border-radius: 50%; object-fit: cover; }

.nav-links { display: flex; gap: 22px; list-style: none; margin: 0; padding: 0; }
.nav-links a {
  color: var(--paper); font-weight: 500; font-size: 0.97rem;
  padding-bottom: 4px; border-bottom: 2px solid transparent;
}
.nav-links a:hover, .nav-links a[aria-current="page"] {
  text-decoration: none; border-bottom-color: var(--gold);
}
.nav-toggle {
  display: none; background: none; border: 1px solid var(--paper);
  color: var(--paper); border-radius: var(--radius);
  padding: 6px 10px; font-size: 1rem; cursor: pointer;
}
@media (max-width: 940px) {
  .nav-links {
    position: absolute; top: 100%; left: 0; right: 0;
    background: var(--ink); flex-direction: column; gap: 0;
    display: none; border-bottom: 3px solid var(--gold);
  }
  .nav-links.open { display: flex; }
  .nav-links li { border-top: 1px solid var(--ink-soft); }
  .nav-links a { display: block; padding: 14px 24px; }
  .nav-toggle { display: inline-block; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; padding: 12px 26px;
  border-radius: var(--radius); font-weight: 600;
  font-family: var(--font-body); font-size: 1rem;
  border: 2px solid transparent; cursor: pointer;
}
.btn:hover { text-decoration: none; }
.btn-primary { background: var(--crimson); color: var(--white); }
.btn-primary:hover { background: var(--crimson-deep); color: var(--white); }
.btn-gold { background: var(--gold); color: var(--ink); }
.btn-gold:hover { background: var(--gold-deep); }
.btn-outline { background: transparent; border-color: var(--paper); color: var(--paper); }
.btn-outline:hover { background: rgba(255,255,255,0.12); }
.btn-outline-dark { background: transparent; border-color: var(--ink); color: var(--ink); }
.btn-outline-dark:hover { background: rgba(16,36,61,0.06); }

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(135deg, var(--ink) 0%, var(--ink-soft) 100%);
  color: var(--paper); padding: 72px 0 88px; overflow: hidden;
}
.hero .container {
  display: grid; grid-template-columns: 1.05fr 0.95fr;
  gap: 48px; align-items: center;
}
.hero h1 { color: var(--paper); }
.hero p { color: #D6E2F0; }
.hero-photo {
  border-radius: var(--radius); overflow: hidden;
  border: 3px solid var(--gold);
  box-shadow: 0 18px 44px rgba(0,0,0,0.32);
}
.hero-photo img { width: 100%; height: auto; aspect-ratio: 4/3; object-fit: cover; }
.hero-photo figcaption {
  background: rgba(0,0,0,0.28); color: #D6E2F0;
  font-size: 0.85rem; padding: 10px 14px;
}
.eyebrow-badge {
  display: inline-block; background: rgba(233,162,39,0.15);
  border: 1px solid var(--gold); color: var(--gold);
  padding: 6px 14px; border-radius: 999px;
  font-size: 0.85rem; font-weight: 600; margin-bottom: 18px;
}
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 28px; }
@media (max-width: 940px) { .hero .container { grid-template-columns: 1fr; } }

/* ---------- Sections ---------- */
section { padding: 72px 0; }
.section-alt { background: var(--paper-deep); }
.section-ink { background: var(--ink); color: var(--paper); }
.section-ink h2, .section-ink h3, .section-ink h4 { color: var(--paper); }
.section-ink p { color: #D6E2F0; }
.section-head { max-width: 680px; margin-bottom: 44px; }
.section-head p { margin-bottom: 0; }

/* ---------- Cards / grids ---------- */
.grid { display: grid; gap: 26px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 940px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 720px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }

.card {
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow);
}
.card h3 { margin-bottom: 10px; }
.card p:last-child { margin-bottom: 0; }

.focus-card {
  border-left: 4px solid var(--gold); background: var(--white);
  padding: 22px 24px; border-radius: 0 var(--radius) var(--radius) 0;
  box-shadow: var(--shadow);
}
.focus-card h3 { margin-bottom: 8px; font-size: 1.1rem; }
.focus-card p { margin-bottom: 0; font-size: 0.96rem; }

.icon-card { text-align: left; }
.icon-card .icon-wrap {
  width: 48px; height: 48px; border-radius: 12px;
  background: rgba(233,162,39,0.18); color: var(--gold-deep);
  display: flex; align-items: center; justify-content: center; margin-bottom: 14px;
}
.icon-card .icon-wrap svg { width: 24px; height: 24px; }

/* ---------- Coverage tabs ---------- */
.coverage-tabs { display: flex; gap: 12px; margin-bottom: 28px; flex-wrap: wrap; }
.coverage-tab-btn {
  padding: 10px 22px; border-radius: 999px; border: 2px solid var(--line);
  background: var(--white); color: var(--ink); font-weight: 600;
  cursor: pointer; font-family: var(--font-body); font-size: 0.95rem;
}
.coverage-tab-btn.active { background: var(--ink); border-color: var(--ink); color: var(--white); }
.division-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
@media (max-width: 780px) { .division-grid { grid-template-columns: 1fr; } }
.division-card {
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 16px 20px;
}
.division-card h4 {
  font-family: var(--font-body); color: var(--azure);
  font-size: 1rem; font-weight: 700; margin-bottom: 6px;
}
.division-card p { margin-bottom: 0; font-size: 0.94rem; }
.coverage-panel { display: none; }
.coverage-panel.active { display: block; }

/* ---------- Timeline ---------- */
.timeline {
  position: relative; margin-left: 12px;
  padding-left: 28px; border-left: 3px solid var(--gold);
}
.timeline-item { position: relative; padding-bottom: 34px; }
.timeline-item:last-child { padding-bottom: 0; }
.timeline-item::before {
  content: ""; position: absolute; left: -35px; top: 4px;
  width: 14px; height: 14px; background: var(--crimson);
  border-radius: 50%; border: 3px solid var(--paper);
}
.timeline-date { font-weight: 700; color: var(--crimson); display: block; margin-bottom: 4px; }

/* ---------- Stats ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.stat-num { font-family: var(--font-display); font-size: 2.3rem; color: var(--gold); display: block; }
.stat-label { color: #D6E2F0; font-size: 0.92rem; }
.stats-note { margin-top: 26px; font-size: 0.85rem; color: #9FB4CA; }
@media (max-width: 780px) { .stats { grid-template-columns: repeat(2, 1fr); } }

/* ---------- Team ---------- */
.team-card { text-align: left; }
.team-photo {
  width: 100%; aspect-ratio: 1; border-radius: var(--radius);
  margin-bottom: 16px; overflow: hidden; background: var(--paper-deep);
}
.team-role { color: var(--crimson); font-weight: 600; font-size: 0.9rem; margin-bottom: 6px; }

/* ---------- Photos ---------- */
.photo-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.photo-strip img {
  width: 100%; height: auto; aspect-ratio: 4/3; object-fit: cover;
  border-radius: var(--radius); border: 1px solid var(--line);
}
@media (max-width: 780px) {
  .photo-strip { grid-template-columns: 1fr 1fr; }
  .photo-strip figure:last-child { display: none; }
}

.gallery-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
@media (max-width: 880px) { .gallery-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .gallery-grid { grid-template-columns: 1fr; } }
.gallery-item {
  margin: 0; background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow);
}
.gallery-item button { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; }
.gallery-item img { width: 100%; height: auto; aspect-ratio: 4/3; object-fit: cover; }
.gallery-item figcaption { padding: 14px 16px; font-size: 0.92rem; color: var(--text-soft); }

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed; inset: 0; background: rgba(8,18,31,0.94);
  display: none; align-items: center; justify-content: center;
  padding: 24px; z-index: 300;
}
.lightbox.open { display: flex; }
.lightbox img {
  width: auto; max-width: min(1000px, 94vw); max-height: 82vh;
  border-radius: var(--radius); border: 2px solid var(--gold);
}
.lightbox-caption {
  position: absolute; bottom: 26px; left: 0; right: 0;
  text-align: center; color: #D6E2F0; font-size: 0.95rem; padding: 0 24px;
}
.lightbox-close {
  position: absolute; top: 18px; right: 22px; background: none;
  border: 1px solid var(--paper); color: var(--paper);
  border-radius: var(--radius); font-size: 1.4rem; line-height: 1;
  padding: 6px 12px; cursor: pointer;
}

/* ---------- Blog / stories ---------- */
.post-card { display: flex; flex-direction: column; gap: 10px; }
.post-meta { font-size: 0.85rem; color: var(--azure); font-weight: 600; }
.post-card h3 { margin-bottom: 0; }
.post-card h3 a { color: var(--ink); }

.story-card { display: grid; grid-template-columns: 120px 1fr; gap: 20px; align-items: start; }
.story-initials {
  width: 120px; height: 120px; border-radius: 50%;
  background: var(--ink); color: var(--gold);
  font-family: var(--font-display); font-size: 2.2rem;
  display: flex; align-items: center; justify-content: center;
}
@media (max-width: 560px) { .story-card { grid-template-columns: 1fr; } }

/* ---------- Careers ---------- */
.job-card { display: grid; grid-template-columns: 1fr auto; gap: 20px; align-items: center; }
.job-meta { list-style: none; padding: 0; margin: 10px 0 0; display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: 0.92rem; color: var(--text-soft); }
.job-meta li strong { color: var(--ink); }
@media (max-width: 700px) { .job-card { grid-template-columns: 1fr; } }

/* ---------- Resources / documents ---------- */
.doc-list { list-style: none; padding: 0; margin: 0; }
.doc-list li {
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 16px 20px; margin-bottom: 12px;
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
}
.doc-list strong { color: var(--ink); }
.doc-status { font-size: 0.88rem; color: var(--text-soft); }

/* ---------- FAQ ---------- */
.faq details {
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 16px 20px; margin-bottom: 12px;
}
.faq summary { font-weight: 600; color: var(--ink); cursor: pointer; }
.faq p { margin: 12px 0 0; }

/* ---------- Newsletter ---------- */
.newsletter-form { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 18px; }
.newsletter-form input {
  flex: 1 1 260px; padding: 12px 14px; border-radius: var(--radius);
  border: 1px solid var(--line); font-family: var(--font-body); font-size: 1rem;
}

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; }
@media (max-width: 880px) { .contact-grid { grid-template-columns: 1fr; } }
.field { margin-bottom: 20px; }
.field label { display: block; font-weight: 600; margin-bottom: 6px; color: var(--ink); }
.field input, .field textarea, .field select {
  width: 100%; padding: 12px 14px; border: 1px solid var(--line);
  border-radius: var(--radius); font-family: var(--font-body);
  font-size: 1rem; background: var(--white);
}
.field textarea { resize: vertical; min-height: 130px; }
.info-row { display: flex; gap: 14px; margin-bottom: 24px; align-items: flex-start; }
.info-icon { width: 24px; height: 24px; flex-shrink: 0; color: var(--crimson); margin-top: 3px; }
.info-row strong { display: block; color: var(--ink); margin-bottom: 2px; }
.info-row p { margin-bottom: 0; font-size: 0.97rem; }

/* ---------- Tables ---------- */
.reg-table {
  width: 100%; border-collapse: collapse; background: var(--white);
  border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
}
.reg-table th, .reg-table td {
  text-align: left; padding: 12px 16px;
  border-bottom: 1px solid var(--line); font-size: 0.95rem;
}
.reg-table th { width: 42%; color: var(--ink); font-weight: 600; background: var(--paper-deep); }
.reg-table tr:last-child th, .reg-table tr:last-child td { border-bottom: none; }
@media (max-width: 620px) {
  .reg-table th, .reg-table td { display: block; width: 100%; }
  .reg-table th { border-bottom: none; padding-bottom: 2px; }
}

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: #AFC2D6; padding: 56px 0 28px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 36px; margin-bottom: 36px; }
.site-footer h4 { color: var(--paper); font-family: var(--font-body); font-size: 1rem; margin-bottom: 14px; }
.site-footer a { color: #AFC2D6; }
.site-footer a:hover { color: var(--gold); }
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: 8px; font-size: 0.95rem; }
.footer-logo { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.footer-logo img { width: 46px; height: 46px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.footer-logo span { font-family: var(--font-display); color: var(--paper); font-size: 1.12rem; font-weight: 600; }
.footer-note {
  border-top: 1px solid var(--ink-soft); padding-top: 20px;
  font-size: 0.82rem; color: #8FA5BC; max-width: 90ch;
}
.footer-bottom {
  border-top: 1px solid var(--ink-soft); padding-top: 20px; margin-top: 20px;
  font-size: 0.85rem; display: flex; justify-content: space-between;
  flex-wrap: wrap; gap: 10px;
}
@media (max-width: 940px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 620px) { .footer-grid { grid-template-columns: 1fr; } }

/* ---------- Page header ---------- */
.page-header {
  background: linear-gradient(135deg, var(--ink) 0%, var(--ink-soft) 100%);
  color: var(--paper); padding: 56px 0; border-bottom: 3px solid var(--gold);
}
.page-header h1 { color: var(--paper); }
.page-header p { color: #D6E2F0; margin-bottom: 0; }

.prose { max-width: 72ch; }
.prose h2 { margin-top: 1.6em; }
.prose h2:first-child { margin-top: 0; }

/* ---------- Cookie banner ---------- */
.cookie-banner {
  position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 150;
  background: var(--white); border: 1px solid var(--line);
  border-left: 5px solid var(--gold); border-radius: var(--radius);
  box-shadow: 0 10px 30px rgba(16,36,61,0.18);
  padding: 18px 22px; display: none;
  gap: 18px; align-items: center; justify-content: space-between; flex-wrap: wrap;
  max-width: 920px; margin: 0 auto;
}
.cookie-banner.show { display: flex; }
.cookie-banner p { margin: 0; font-size: 0.92rem; max-width: 62ch; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; animation: none !important; }
}
