/* The Access Grid — shared styles
   Type: Bricolage Grotesque (display) + Atkinson Hyperlegible (body, designed for low-vision readers)
   Colour tokens below; all text pairs meet WCAG AA (most AAA). */

:root {
  --night: #1E1A3D;      /* deep Nairobi night */
  --night-2: #2A2552;
  --amber: #F2A93B;      /* stage light / interpreter spotlight */
  --amber-deep: #8A4F00; /* amber text on light backgrounds */
  --sky: #9FD3E6;        /* cool secondary */
  --mist: #EEECF5;       /* light background */
  --paper: #FFFFFF;
  --ink: #1A1730;
  --ink-soft: #4A4566;
  --line: #CFCBE0;
  --ok: #1F6B4A;
  --wait: #7A4B00;

  --font-display: "Bricolage Grotesque", "Segoe UI", system-ui, sans-serif;
  --font-body: "Atkinson Hyperlegible", "Segoe UI", system-ui, sans-serif;

  --step-0: 1.0625rem;
  --step-1: 1.25rem;
  --step-2: 1.6rem;
  --step-3: clamp(2rem, 4vw, 2.75rem);
  --step-4: clamp(2.6rem, 7vw, 5.25rem);

  --gutter: 16px;
  --max: 1180px;
  --radius: 14px;
}

html.large-text { font-size: 118%; }
html.high-contrast {
  --mist: #FFFFFF; --ink: #000000; --ink-soft: #1A1A1A; --line: #000000;
  --night: #000000; --night-2: #111111; --sky: #FFFFFF; --amber: #FFD000;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--mist);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: 1.6;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; height: auto; }
a { color: inherit; text-underline-offset: 3px; }
p, li { max-width: 68ch; }

:focus-visible { outline: 3px solid var(--amber); outline-offset: 3px; border-radius: 4px; }
.on-light :focus-visible, main :focus-visible { outline-color: #6A3FD0; }

.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  background: var(--amber); color: var(--night); padding: 10px 16px;
  font-weight: 700; border-radius: 8px; text-decoration: none;
}
.skip-link:focus { top: 12px; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

.wrap { width: min(var(--max), 100% - 2 * var(--gutter)); margin-inline: auto; }

h1, h2, h3 { font-family: var(--font-display); line-height: 1.08; letter-spacing: -0.015em; margin: 0 0 0.5em; }
h1 { font-size: var(--step-4); font-weight: 800; }
h2 { font-size: var(--step-3); font-weight: 750; }
h3 { font-size: var(--step-1); font-weight: 700; line-height: 1.25; }
.lede { font-size: var(--step-1); color: var(--ink-soft); max-width: 60ch; }

/* ---------- Header ---------- */
.site-header { background: var(--night); color: #fff; position: sticky; top: 0; z-index: 50; }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--font-display); font-weight: 800; font-size: 1.15rem; }
.brand img { width: 36px; height: 36px; }
.nav-toggle {
  display: none; background: transparent; color: #fff; border: 2px solid var(--sky);
  border-radius: 10px; padding: 8px 14px; font: inherit; font-weight: 700; cursor: pointer;
}
.primary-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 4px; flex-wrap: wrap; }
.primary-nav a {
  display: block; padding: 8px 11px; border-radius: 8px; text-decoration: none; font-weight: 700; font-size: 0.95rem;
}
.primary-nav a:hover { background: var(--night-2); }
.primary-nav a[aria-current="page"] { background: var(--amber); color: var(--night); }

.display-tools { display: flex; gap: 6px; }
.tool-btn {
  background: transparent; color: #fff; border: 1.5px solid #6E679C; border-radius: 8px;
  padding: 6px 10px; font: inherit; font-size: 0.85rem; font-weight: 700; cursor: pointer;
}
.tool-btn[aria-pressed="true"] { background: var(--sky); color: var(--night); border-color: var(--sky); }

@media (max-width: 1060px) {
  .nav-toggle { display: inline-block; }
  .site-header .wrap { flex-wrap: wrap; }
  .primary-nav { display: none; width: 100%; padding-bottom: 14px; }
  .primary-nav.open { display: block; }
  .primary-nav ul { flex-direction: column; }
  .primary-nav a { padding: 12px; font-size: 1.05rem; }
  .display-tools { margin-top: 10px; }
}

/* ---------- Hero (home) ---------- */
.hero { position: relative; color: #fff; background: var(--night); overflow: hidden; }
.hero-media { position: absolute; inset: 0; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; }
.hero-media::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(30,26,61,.96) 0%, rgba(30,26,61,.82) 45%, rgba(30,26,61,.35) 100%);
}
.hero .wrap { position: relative; padding: clamp(72px, 12vw, 150px) 0 clamp(64px, 10vw, 120px); }
.hero-kicker { color: var(--sky); font-weight: 700; margin: 0 0 18px; font-size: var(--step-1); }
.rotator { min-height: calc(var(--step-4) * 2.2); }
.rotator [data-line] { margin: 0; max-width: 14ch; font-family: var(--font-display); font-size: var(--step-4); font-weight: 800; line-height: 1.04; letter-spacing: -0.02em; }
.rotator [hidden] { display: none; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; align-items: center; }
.hero .lede { color: #E4E1F2; margin-top: 18px; }

.btn {
  display: inline-block; padding: 14px 22px; border-radius: 999px; font-weight: 700;
  text-decoration: none; border: 2px solid transparent; font-size: 1rem; cursor: pointer; font-family: inherit;
}
.btn-amber { background: var(--amber); color: var(--night); }
.btn-amber:hover { background: #FFC266; }
.btn-ghost { border-color: #fff; color: #fff; background: transparent; }
.btn-ghost:hover { background: rgba(255,255,255,.12); }
.btn-dark { background: var(--night); color: #fff; }
.pause-btn {
  background: rgba(0,0,0,.35); color: #fff; border: 1.5px solid #B9B4D8; border-radius: 999px;
  padding: 8px 14px; font: inherit; font-size: .9rem; cursor: pointer;
}

/* ---------- Page header (inner pages) ---------- */
.page-head { background: var(--night); color: #fff; position: relative; overflow: hidden; }
.page-head .wrap { padding: clamp(56px, 9vw, 110px) 0 clamp(44px, 7vw, 80px); position: relative; display: grid; gap: 28px; }
.page-head .lede { color: #E4E1F2; }
.page-head h1 { font-size: clamp(2.4rem, 6vw, 4.4rem); max-width: 18ch; }
.step-label { color: var(--sky); font-weight: 700; margin: 0; }
.page-head.with-photo { min-height: 420px; }
.page-head.with-photo .ph-media { position: absolute; inset: 0; }
.page-head.with-photo .ph-media img { width: 100%; height: 100%; object-fit: cover; }
.page-head.with-photo .ph-media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(30,26,61,.95), rgba(30,26,61,.6)); }

/* ---------- Sections ---------- */
section.block { padding: clamp(56px, 8vw, 104px) 0; }
section.block.tight { padding-top: 0; }
.block.dark { background: var(--night); color: #fff; }
.block.dark .lede, .block.dark p { color: #E4E1F2; }
.block.white { background: var(--paper); }

.split { display: grid; grid-template-columns: 1fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
@media (min-width: 860px) {
  .split { grid-template-columns: 1.05fr .95fr; }
  .split.flip > :first-child { order: 2; }
}

/* Photos: big, offset, cropped — echoing 1% for the Planet's full-bleed story panels */
figure { margin: 0; }
.photo { position: relative; }
.photo img { border-radius: var(--radius); width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.photo.tall img { aspect-ratio: 4 / 5; }
.photo.offset::before {
  content: ""; position: absolute; inset: 18px -18px -18px 18px; border-radius: var(--radius);
  background: var(--amber); z-index: -1;
}
.photo figcaption, .credit { font-size: .8rem; color: var(--ink-soft); margin-top: 10px; }
.block.dark .photo figcaption, .page-head .credit, .hero .credit { color: #C9C4E3; }
.hero .credit { position: absolute; right: var(--gutter); bottom: 10px; font-size: .75rem; z-index: 2; margin: 0; }

.full-bleed { position: relative; min-height: 460px; display: grid; align-items: end; color: #fff; }
.full-bleed img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.full-bleed::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(30,26,61,.95) 10%, rgba(30,26,61,.2) 70%); }
.full-bleed .wrap { position: relative; z-index: 1; padding: 64px 0 40px; }
.full-bleed blockquote { margin: 0; font-family: var(--font-display); font-size: var(--step-3); font-weight: 700; line-height: 1.15; max-width: 22ch; }
.full-bleed .credit { color: #C9C4E3; }

/* ---------- The grid motif: 3 venues x 3 nights ---------- */
.night-grid { display: grid; grid-template-columns: auto repeat(3, 1fr); gap: 10px; max-width: 560px; }
.night-grid .gl { font-weight: 700; font-size: .9rem; align-self: center; color: var(--sky); }
.night-grid .gh { font-weight: 700; font-size: .9rem; text-align: center; color: var(--sky); }
.night-grid .cell {
  aspect-ratio: 1; border-radius: 12px; border: 2px solid var(--sky); display: grid; place-items: center;
  font-family: var(--font-display); font-weight: 800; font-size: 1.3rem; color: var(--sky);
}
.night-grid .cell.lit { background: var(--amber); border-color: var(--amber); color: var(--night); }

/* ---------- Stats ---------- */
.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px 20px; margin-top: 36px; }
@media (min-width: 860px) { .stats { grid-template-columns: repeat(4, 1fr); } }
.stat-num { font-family: var(--font-display); font-weight: 800; font-size: clamp(3rem, 7vw, 4.75rem); line-height: 1; color: var(--amber); display: block; }
.stat-label { display: block; margin-top: 8px; font-weight: 700; max-width: 22ch; }

/* ---------- Numbered steps (a real sequence) ---------- */
.steps { list-style: none; padding: 0; margin: 40px 0 0; display: grid; gap: 18px; counter-reset: s; }
@media (min-width: 860px) { .steps.four { grid-template-columns: repeat(4, 1fr); } }
.steps li { counter-increment: s; background: var(--paper); border-radius: var(--radius); padding: 26px 24px; border-top: 6px solid var(--amber); }
.steps li::before {
  content: counter(s); font-family: var(--font-display); font-weight: 800; font-size: 2.4rem; color: var(--night); display: block; line-height: 1; margin-bottom: 10px;
}
.block.dark .steps li { background: var(--night-2); }
.block.dark .steps li::before { color: var(--amber); }

/* ---------- Plan components (non-sequence: no numbers) ---------- */
.components { display: grid; gap: 0; margin-top: 32px; border-top: 2px solid var(--ink); }
.component { display: grid; grid-template-columns: 1fr; gap: 10px 32px; padding: 30px 0; border-bottom: 1px solid var(--line); }
@media (min-width: 860px) { .component { grid-template-columns: 300px 1fr; } }
.component h3 { font-size: var(--step-2); margin: 0; }
.component p { margin: 0 0 10px; }
.tag { display: inline-block; font-size: .85rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: #E2DEF2; color: var(--ink); margin: 4px 6px 0 0; }

/* ---------- Partners ---------- */
.partner-list { display: grid; gap: 20px; margin-top: 32px; }
@media (min-width: 860px) { .partner-list { grid-template-columns: repeat(3, 1fr); } }
.partner { background: var(--paper); border-radius: var(--radius); padding: 28px; border: 1px solid var(--line); display: flex; flex-direction: column; gap: 10px; }
.partner h3 { margin: 0; }
.status { align-self: flex-start; font-weight: 700; font-size: .85rem; padding: 4px 12px; border-radius: 999px; }
.status.discussion { background: #FFE8C2; color: var(--wait); }
.status.confirmed { background: #CFEBDD; color: var(--ok); }
.status.open { background: #E2DEF2; color: var(--ink); }

/* ---------- Timeline ---------- */
.timeline { list-style: none; margin: 36px 0 0; padding: 0; position: relative; }
.timeline::before { content: ""; position: absolute; left: 11px; top: 6px; bottom: 6px; width: 3px; background: var(--amber); }
.timeline li { position: relative; padding: 0 0 36px 48px; }
.timeline li::before { content: ""; position: absolute; left: 0; top: 4px; width: 25px; height: 25px; border-radius: 7px; background: var(--night); border: 3px solid var(--amber); }
.timeline .when { font-family: var(--font-display); font-weight: 800; font-size: var(--step-2); display: block; }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; margin-top: 28px; border-radius: var(--radius); background: var(--paper); border: 1px solid var(--line); }
table { border-collapse: collapse; width: 100%; min-width: 560px; }
caption { text-align: left; padding: 18px 20px 6px; font-weight: 700; font-family: var(--font-display); font-size: var(--step-1); }
th, td { text-align: left; padding: 12px 20px; border-bottom: 1px solid var(--line); vertical-align: top; }
thead th { font-size: .9rem; color: var(--ink-soft); }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
tfoot th, tfoot td { font-weight: 800; border-bottom: 0; font-size: 1.1rem; }
.bar { display: block; height: 8px; border-radius: 4px; background: var(--amber); margin-top: 6px; }

.range { display: grid; gap: 18px; margin-top: 32px; }
@media (min-width: 860px) { .range { grid-template-columns: repeat(3, 1fr); } }
.range-card { border-radius: var(--radius); padding: 26px; background: var(--night-2); color: #fff; }
.range-card .amt { font-family: var(--font-display); font-weight: 800; font-size: 2.6rem; color: var(--amber); display: block; line-height: 1.1; }
.range-card p { color: #E4E1F2; margin: 8px 0 0; }

/* ---------- Content roadmap ---------- */
.formats { display: grid; gap: 20px; margin-top: 32px; }
@media (min-width: 860px) { .formats { grid-template-columns: repeat(3, 1fr); } }
.format { border-radius: var(--radius); background: var(--paper); padding: 28px; border: 1px solid var(--line); }
.format .where { font-weight: 700; color: var(--amber-deep); margin: 0 0 6px; }
.episodes { display: grid; gap: 16px; margin-top: 28px; }
.episode { display: grid; grid-template-columns: 1fr; gap: 8px 28px; background: var(--paper); border-radius: var(--radius); padding: 24px; border-left: 6px solid var(--amber); }
@media (min-width: 860px) { .episode { grid-template-columns: 220px 1fr; } }
.episode .phase { font-family: var(--font-display); font-weight: 800; font-size: 1.2rem; }
.episode .phase small { display: block; font-family: var(--font-body); font-weight: 400; color: var(--ink-soft); font-size: .9rem; }
.episode ul { margin: 6px 0 0; padding-left: 1.2em; }

.checklist { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 12px; }
.checklist li { padding-left: 34px; position: relative; }
.checklist li::before { content: ""; position: absolute; left: 0; top: 3px; width: 20px; height: 20px; border-radius: 5px; background: var(--amber); }

.note {
  background: #FFF4DF; border-left: 6px solid var(--amber); border-radius: 10px; padding: 18px 22px; margin-top: 28px; color: var(--ink);
}
.note p { margin: 0; }

.video-slot {
  aspect-ratio: 16 / 9; border-radius: var(--radius); background: var(--night-2); color: #fff; border: 2px dashed var(--sky);
  display: grid; place-items: center; text-align: center; padding: 24px;
}
.video-slot p { margin: 0 auto; color: #E4E1F2; }

/* ---------- Guided next-page strip ---------- */
.next-page { background: var(--amber); color: var(--night); }
.next-page .wrap { display: flex; flex-wrap: wrap; gap: 18px; justify-content: space-between; align-items: center; padding: 44px 0; }
.next-page p { margin: 0; font-weight: 700; }
.next-page a.next-link { font-family: var(--font-display); font-weight: 800; font-size: var(--step-3); text-decoration: none; }
.next-page a.next-link:hover { text-decoration: underline; }
.progress { display: flex; gap: 6px; margin-top: 8px; }
.progress span { width: 26px; height: 8px; border-radius: 4px; background: rgba(30,26,61,.25); }
.progress span.done { background: var(--night); }

/* ---------- Footer ---------- */
.site-footer { background: var(--night); color: #E4E1F2; padding: 64px 0 36px; }
.footer-big { font-family: var(--font-display); font-weight: 800; font-size: clamp(2rem, 5vw, 3.4rem); color: #fff; line-height: 1.1; margin: 0 0 40px; }
.footer-big .who { color: var(--amber); display: inline-block; }
.footer-cols { display: grid; gap: 28px; grid-template-columns: 1fr; }
@media (min-width: 760px) { .footer-cols { grid-template-columns: repeat(3, 1fr); } }
.site-footer h2 { font-size: 1.1rem; color: #fff; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.site-footer a { color: #E4E1F2; }
.fineprint { border-top: 1px solid #3E3870; margin-top: 40px; padding-top: 20px; font-size: .85rem; }

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

/* Refinements */
.photo img { background: var(--night-2); }
@media (max-width: 859px) {
  .photo.offset::before { inset: 12px 0 -12px 12px; }
  .photo.offset { margin-right: 12px; }
}
@media (min-width: 1061px) and (max-width: 1240px) {
  .primary-nav a { padding: 8px 8px; font-size: .9rem; }
}
.primary-nav { align-items: center; gap: 14px; }
@media (min-width: 1061px) { .primary-nav { display: flex; } }
@media (max-width: 1060px) { .primary-nav.open { display: flex; flex-direction: column; align-items: stretch; } }
@media (max-width: 600px) {
  table { min-width: 0; }
  th, td { padding: 10px 12px; }
  td[aria-hidden="true"], thead th:last-child, tfoot td:last-child { display: none; }
}

/* Video placeholder poster */
.video-poster .vp-frame { position: relative; border-radius: var(--radius); overflow: hidden; background: var(--night-2); aspect-ratio: 16 / 9; }
.video-poster img { width: 100%; height: 100%; object-fit: cover; }
.vp-overlay { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 12px; color: #fff;
  background: linear-gradient(0deg, rgba(30,26,61,.85), rgba(30,26,61,.35)); }
.vp-play { width: 76px; height: 76px; border-radius: 50%; background: var(--amber); color: var(--night); display: grid; place-items: center; }
.vp-label { font-family: var(--font-display); font-weight: 800; font-size: var(--step-1); }
.vp-badge { position: absolute; top: 14px; left: 14px; background: var(--amber); color: var(--night); font-weight: 700; font-size: .85rem; padding: 4px 12px; border-radius: 999px; }
.video-poster figcaption { font-size: .85rem; color: var(--ink-soft); margin-top: 10px; }
.btn-outline { border-color: var(--night); color: var(--night); background: transparent; }
.btn-outline:hover { background: rgba(30,26,61,.08); }
