/* ==========================================================================
   AyurSphere — site styles
   Built on css/tokens.css. Sections: base · type · layout · header · buttons ·
   spectrum rule · hero & mastheads · stats · cards & tags · steps · quotes ·
   episodes & player · forms · accordion · tabs & toggles · tables · charts ·
   timeline · team · CTA band · footer · motion · utilities
   Colour discipline: spectrum hues appear only as rules, tags, badges, episode
   grounds, programme mastheads, chart series and hover states. Never as a
   surface elsewhere (brand book section 17, 80 / 15 / 5).
   ========================================================================== */

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--body-size);
  line-height: 1.7;
  color: var(--ink);
  background: var(--bone);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
body.nav-open { overflow: hidden; }
img, svg, video { max-width: 100%; height: auto; display: block; }
[id] { scroll-margin-top: calc(var(--header-h) + var(--s3)); }
:focus-visible { outline: var(--focus-ring); outline-offset: var(--focus-offset); }
::selection { background: var(--ink); color: var(--bone); }

a { color: var(--azure); text-decoration: none; }
a:hover { text-decoration: underline; }
.prose a, p a { text-decoration: underline; text-underline-offset: 0.15em; }
strong, b { font-weight: 700; }
em { font-style: normal; font-weight: 700; }  /* bold for emphasis, never italic */
hr { border: 0; border-top: 1px solid var(--line); margin: var(--s5) 0; }
fieldset { border: 0; padding: 0; margin: 0; min-width: 0; min-inline-size: 0; }
legend { padding: 0; }

.skip-link {
  position: absolute; left: var(--s3); top: -100px;
  padding: var(--s2) var(--s3); background: var(--ink); color: var(--bone);
  border-radius: var(--radius); z-index: 100; font-weight: 700;
}
.skip-link:focus { top: var(--s3); }
.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- Type scale (section 20) ---------- */
h1, h2, h3, h4, .display, .h1, .h2, .h3 { margin: 0 0 var(--s3); font-weight: 700; color: var(--ink); text-wrap: balance; }
.display { font-size: var(--display-size); line-height: 0.92; font-weight: 800; letter-spacing: -0.03em; }
h1, .h1 { font-size: var(--h1-size); line-height: 1.1; letter-spacing: -0.02em; }
h2, .h2 { font-size: var(--h2-size); line-height: 1.2; letter-spacing: -0.01em; }
h3, .h3 { font-size: 20px; line-height: 1.3; }
h4 { font-size: 16px; line-height: 1.5; }
p { margin: 0 0 var(--s3); }
p:last-child { margin-bottom: 0; }
.lead { font-size: var(--lead-size); line-height: 1.55; color: var(--ink); }
.caption { font-size: var(--caption-size); line-height: 1.5; color: var(--slate); }
.muted { color: var(--slate); }
.stone { color: var(--slate); }   /* Stone fails 4.5:1 as text; kept as an alias for Slate */
.label {
  display: inline-block; font-size: var(--label-size); line-height: 1.2; font-weight: 700;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--slate);
}
.label--ink { color: var(--ink); }
.label--bone { color: var(--bone); }
.measure { max-width: 62ch; }   /* 50–75 characters per line */
.measure-narrow { max-width: 48ch; }
.num { font-variant-numeric: tabular-nums; }
ul.list, ol.list { margin: 0 0 var(--s3); padding-left: 1.2em; }
ul.list li, ol.list li { margin-bottom: var(--s2); }
.list--plain { list-style: none; padding: 0; margin: 0; }

/* ---------- Layout (section 31) ---------- */
.container { width: 100%; max-width: calc(var(--max) + 2 * var(--gutter)); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding: var(--s6) 0; }
.section--tight { padding: var(--s5) 0; }
.section--flush-top { padding-top: 0; }
.section--white { background: var(--white); }
.section--rule-top { border-top: 1px solid var(--line); }
.grid { display: grid; gap: var(--gutter); }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.grid-split { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: start; }
.grid-split--even { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: center; }
.grid-sidebar { grid-template-columns: minmax(0, 8fr) minmax(0, 4fr); align-items: start; }
.gap-lg { gap: var(--s5); }
.stack > * + * { margin-top: var(--s3); }
.stack-lg > * + * { margin-top: var(--s4); }
.section-head { margin-bottom: var(--s5); }
.section-head .lead { margin-top: var(--s2); }
.section-head--row { display: flex; justify-content: space-between; align-items: end; gap: var(--s4); flex-wrap: wrap; }
.sticky { position: sticky; top: calc(var(--header-h) + var(--s4)); }

@media (max-width: 1024px) {
  .grid-4, .grid-5 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-sidebar { grid-template-columns: 1fr; }
}
@media (max-width: 800px) {
  .section { padding: var(--s5) 0; }
  .grid-3, .grid-split, .grid-split--even, .grid-2--charts { grid-template-columns: 1fr; }
  .sticky { position: static; }
}
@media (max-width: 560px) {
  .container { padding: 0 var(--margin-mobile); }
  .grid-2, .grid-4, .grid-5 { grid-template-columns: 1fr; }
}

/* ---------- Header (section 33): sticky 64 px, white, 1 px rule ---------- */
.header {
  position: sticky; top: 0; z-index: 50;
  height: var(--header-h); background: var(--white);
  border-bottom: 1px solid var(--line);
}
.header__inner { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: var(--s4); }
.lockup { display: inline-flex; align-items: center; gap: 12px; color: var(--ink); text-decoration: none; }
.lockup:hover { text-decoration: none; }
.lockup__mark { width: 32px; height: 32px; flex: none; }
/* Interim live-text wordmark until the official lockup artwork arrives (CONTENT-TODO.md, Logo). No tracking adjustment: brand book section 08. */
.lockup__word { font-size: 22px; line-height: 1; font-weight: 300; white-space: nowrap; }
.lockup__word b { font-weight: 800; }
.lockup__desc { display: none; font-size: var(--caption-size); color: var(--slate); margin-left: 12px; padding-left: 12px; border-left: 1px solid var(--line); }   /* 12 px clears the mark's clearspace (x ≈ 10.7 px at 32 px) before the divider */
@media (min-width: 1180px) { .lockup__desc { display: inline; } }
.lockup--lg .lockup__mark { width: 48px; height: 48px; }
.lockup--lg .lockup__word { font-size: 30px; }

.nav__list { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: var(--s4); }
.nav__list a:not(.btn) { color: var(--ink); font-weight: 500; padding: var(--s2) 0; border-bottom: 2px solid transparent; }
.nav__list a:not(.btn):hover { text-decoration: none; border-color: var(--azure); }
.nav__list a[aria-current="page"] { font-weight: 700; border-color: var(--ink); }
.nav__cta { margin-left: var(--s2); }
.nav__cta .btn { height: 40px; padding: 0 20px; }
.nav-toggle {
  display: none; width: 44px; height: 44px; padding: 0; border: 0; background: none; cursor: pointer;
  flex-direction: column; justify-content: center; align-items: center; gap: var(--s1); border-radius: var(--radius);
}
.nav-toggle__bar { width: 22px; height: 2px; background: var(--ink); transition: transform var(--dur-ui) var(--ease), opacity var(--dur-ui) var(--ease); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 920px) {
  /* Off-canvas nav only when JavaScript is running (js/main.js adds .js and toggles .is-open) */
  .js .nav-toggle { display: flex; }
  .js .nav {
    position: fixed; top: var(--header-h); right: 0; bottom: 0; left: 0;
    background: var(--white); padding: var(--s4) var(--gutter) var(--s5);
    transform: translateX(100%); visibility: hidden;
    transition: transform var(--dur-ui) var(--ease), visibility 0s linear var(--dur-ui);
    overflow-y: auto;
  }
  .js .nav.is-open { transform: none; visibility: visible; transition: transform var(--dur-ui) var(--ease); }
  .js .nav__list { flex-direction: column; align-items: stretch; gap: 0; }
  .js .nav__list li { border-bottom: 1px solid var(--line); }
  .js .nav__list a:not(.btn) { display: block; padding: var(--s3) 0; font-size: 20px; border-bottom: 0; }
  .js .nav__list a[aria-current="page"] { border-left: 3px solid var(--ink); padding-left: var(--s3); }
  .js .nav__cta { margin: var(--s4) 0 0; border-bottom: 0 !important; }
  .js .nav__cta .btn { width: 100%; height: var(--control-h); }

  /* No-JavaScript fallback: the six links wrap in a row under the lockup */
  html:not(.js) .header { height: auto; }
  html:not(.js) .header__inner { height: auto; flex-wrap: wrap; align-items: center; padding-block: 12px; row-gap: var(--s2); }
  html:not(.js) .nav { width: 100%; }
  html:not(.js) .nav__list { flex-wrap: wrap; gap: var(--s2) var(--s3); }
  html:not(.js) .nav__cta { margin-left: 0; }
}

/* ---------- Buttons (section 32): 48 px; Ink primary, outline secondary, underline tertiary.
   Spectrum hues appear on hover only. Hover fills obey the contrast matrix:
   --hover / --hover-text are set per pillar scope. Default is Lime with Ink text. ---------- */
:root { --hover: var(--lime); --hover-text: var(--ink); }
.scope-health  { --hover: var(--teal);   --hover-text: var(--ink);   --pillar: var(--teal);   --pillar-2: var(--azure);   --pillar-text: var(--ink); }
.scope-wealth  { --hover: var(--amber);  --hover-text: var(--ink);   --pillar: var(--amber);  --pillar-2: var(--coral);   --pillar-text: var(--ink); }
.scope-society { --hover: var(--violet); --hover-text: var(--white); --pillar: var(--violet); --pillar-2: var(--magenta); --pillar-text: var(--white); }
.scope-org     { --hover: var(--lime);   --hover-text: var(--ink);   --pillar: var(--green);  --pillar-2: var(--lime);    --pillar-text: var(--ink); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--s2);
  height: var(--control-h); padding: 0 var(--s4); max-width: 100%;
  font: inherit; font-weight: 700; font-size: 16px; line-height: 1; white-space: nowrap;
  border: 1px solid transparent; border-radius: var(--radius); cursor: pointer;
  text-decoration: none; transition: background-color var(--dur-ui) var(--ease), color var(--dur-ui) var(--ease), border-color var(--dur-ui) var(--ease);
}
.btn:hover { text-decoration: none; }
.btn--primary { background: var(--ink); color: var(--white); border-color: var(--ink); }
.btn--primary:hover { background: var(--hover); color: var(--hover-text); border-color: var(--hover); }
.btn--secondary { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn--secondary:hover { border-color: var(--hover); box-shadow: inset 0 0 0 1px var(--hover); }
.btn--tertiary {
  height: auto; padding: 0; border: 0; border-radius: 0; background: none; color: var(--ink);
  white-space: normal; text-align: left; justify-content: flex-start; align-items: baseline; line-height: 1.4;
  text-decoration: underline; text-underline-offset: 0.2em; text-decoration-thickness: 1px;
}
.btn--tertiary:hover { text-decoration-thickness: 2px; text-decoration-color: var(--hover); }
.btn--tertiary::after { content: "\2192"; font-weight: 400; }
.btn--inverse { background: var(--white); color: var(--ink); border-color: var(--white); }
.btn--inverse:hover { background: var(--hover); color: var(--hover-text); border-color: var(--hover); }
.btn--inverse-outline { background: transparent; color: var(--bone); border-color: var(--bone); }
.btn--inverse-outline:hover { box-shadow: inset 0 0 0 1px var(--hover); border-color: var(--hover); }
.btn--block { width: 100%; }
.btn[disabled], .btn[aria-disabled="true"] { background: var(--line); color: var(--stone); border-color: var(--line); cursor: not-allowed; }
.btn-row { display: flex; flex-wrap: wrap; gap: var(--s3); align-items: center; }

/* ---------- Spectrum rule (section 33): 6 px, full bleed, ONCE per page, closing the hero.
   Hard stops between the eight hues — no blending. ---------- */
.spectrum-rule {
  height: var(--spectrum-rule-h); width: 100%;
  background: linear-gradient(90deg,
    var(--teal) 0 12.5%, var(--azure) 12.5% 25%, var(--violet) 25% 37.5%, var(--magenta) 37.5% 50%,
    var(--coral) 50% 62.5%, var(--amber) 62.5% 75%, var(--lime) 75% 87.5%, var(--green) 87.5% 100%);
}

/* ---------- Hero and mastheads ---------- */
.hero { padding: var(--s6) 0 var(--s5); }
.hero__grid { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 6fr); gap: var(--s5); align-items: center; }
.hero .display { margin: var(--s3) 0 var(--s4); }
.hero .lead { margin-bottom: var(--s4); }
.hero__media { border-radius: var(--radius); overflow: hidden; }
.hero__media img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
@media (max-width: 900px) { .hero { padding: var(--s5) 0; } .hero__grid { grid-template-columns: 1fr; gap: var(--s4); } }

.masthead { padding: var(--s5) 0 var(--s5); }
.masthead .h1, .masthead h1 { margin-top: var(--s3); }
.masthead .lead { max-width: 62ch; }
.masthead--pillar { background: var(--pillar); color: var(--pillar-text); }
.masthead--pillar h1, .masthead--pillar .lead, .masthead--pillar .label { color: var(--pillar-text); }
.masthead--pillar .btn--primary:hover { background: var(--white); color: var(--ink); border-color: var(--white); }
.masthead--pillar .btn--secondary:hover { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.masthead--pillar .btn--tertiary:hover { text-decoration-color: var(--ink); }
/* Azure measures 1.25:1 on Teal, so on a pillar masthead the focus ring takes the masthead's text colour (Ink 5.2:1 on Teal, white 6.5:1 on Violet) — WCAG 1.4.11 */
.masthead--pillar :focus-visible { outline-color: var(--pillar-text, var(--ink)); }
.masthead--ink { background: var(--ink); color: var(--bone); }
.masthead--ink h1, .masthead--ink .lead { color: var(--white); }
.masthead--ink .label { color: var(--bone); }
.masthead__grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--s5); align-items: center; }
.masthead__media { border-radius: var(--radius); overflow: hidden; }
.masthead__media img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
@media (max-width: 900px) { .masthead__grid { grid-template-columns: 1fr; gap: var(--s4); } }

/* ---------- Statistics (section 26, 33): 3 px pillar rule, dated source ---------- */
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--s4); }
.stats--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.stat { border-top: 3px solid var(--stat-color, var(--ink)); padding-top: var(--s3); }
.stat--health { --stat-color: var(--teal); }
.stat--azure { --stat-color: var(--azure); }
.stat--wealth { --stat-color: var(--amber); }
.stat--coral { --stat-color: var(--coral); }
.stat--society { --stat-color: var(--violet); }
.stat--magenta { --stat-color: var(--magenta); }
.stat--org { --stat-color: var(--green); }
.stat--lime { --stat-color: var(--lime); }
.stat__value { font-size: clamp(36px, 4vw, 48px); line-height: 1; font-weight: 800; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; margin-bottom: var(--s2); }
.stat__label { color: var(--slate); }
.stat--lg .stat__value { font-size: clamp(56px, 8vw, 96px); }
.stat-source { margin-top: var(--s4); font-size: var(--caption-size); color: var(--slate); }
.masthead--ink .stat__label, .cta-band .stat__label { color: var(--line); }
.masthead--ink .stat-source { color: var(--bone); }
@media (max-width: 900px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px) { .stats, .stats--2 { grid-template-columns: 1fr; } }

/* ---------- Cards, tags, badges ---------- */
.card {
  background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: var(--s4); display: flex; flex-direction: column; gap: var(--s3);
}
.card--rule { border-top: 3px solid var(--card-color, var(--ink)); }
.card--health { --card-color: var(--teal); }
.card--wealth { --card-color: var(--amber); }
.card--society { --card-color: var(--violet); }
.card--org { --card-color: var(--green); }
.card--flat { box-shadow: none; border: 1px solid var(--line); }
.card--bone { background: var(--bone); box-shadow: none; }
.card--ink { background: var(--ink); color: var(--bone); }
.card--ink h2, .card--ink h3, .card--ink .h3 { color: var(--white); }
.card__media { margin: calc(-1 * var(--s4)) calc(-1 * var(--s4)) 0; border-radius: var(--radius) var(--radius) 0 0; overflow: hidden; }
.card__media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.card__media--square img { aspect-ratio: 1 / 1; }
.card h3 { margin-bottom: 0; }
.card p { margin: 0; }
.card h3 + .caption { margin-top: calc(var(--s2) - var(--s3)); }   /* a caption directly under the heading sits 8 px below it, not a full card gap */
.card__figure { font-size: 28px; font-weight: 800; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.card__foot { margin-top: auto; padding-top: var(--s2); }
.card-link { color: inherit; text-decoration: none; }
.card-link:hover { text-decoration: none; }
.card-link:hover h3 { text-decoration: underline; text-underline-offset: 0.15em; }

.tag {
  display: inline-block; padding: var(--s1) 12px; border-radius: var(--radius-pill); white-space: nowrap;
  font-size: var(--label-size); line-height: 1.2; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase;
  background: var(--line); color: var(--ink);
}
.tag--health { background: var(--teal); color: var(--ink); }
/* No Azure tag: Azure is never a text ground below 24 px (tokens.css contrast table). Use .tag--outline if an Azure-coded tag is needed. */
.tag--wealth { background: var(--amber); color: var(--ink); }
.tag--society { background: var(--violet); color: var(--white); }
.tag--magenta { background: var(--magenta); color: var(--white); }
.tag--org { background: var(--lime); color: var(--ink); }
.tag--ink { background: var(--ink); color: var(--bone); }
.tag--outline { background: transparent; border: 1px solid var(--line); }
.tag-row { display: flex; flex-wrap: wrap; gap: var(--s2); }

.badge { width: 40px; height: 40px; flex: none; }
.badge--lg { width: 64px; height: 64px; }
.card__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s3); }

.feature { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 6fr); gap: var(--s5); align-items: center; }
.feature--reverse > :first-child { order: 2; }
.feature__media { border-radius: var(--radius); overflow: hidden; }
.feature__media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.feature__media--wide img { aspect-ratio: 16 / 9; }
@media (max-width: 900px) { .feature { grid-template-columns: 1fr; gap: var(--s4); } .feature--reverse > :first-child { order: 0; } }

/* Placeholder block for image slots not yet filled */
.ph {
  aspect-ratio: var(--ar, 4 / 3); background: var(--bone); border: 1px solid var(--stone);
  border-radius: var(--radius); display: grid; place-items: center; text-align: center;
  color: var(--stone); font-size: var(--caption-size); padding: var(--s3);
}
.ph--wide { --ar: 16 / 9; }
.ph--square { --ar: 1 / 1; }

/* ---------- Steps ---------- */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--s4); counter-reset: step; }
.steps--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.steps--stack { grid-template-columns: 1fr; }
.step { counter-increment: step; border-top: 3px solid var(--step-color, var(--pillar, var(--ink))); padding-top: var(--s3); }
.step__num { display: block; font-size: 28px; font-weight: 800; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; margin-bottom: var(--s2); }
.step__num::before { content: counter(step, decimal-leading-zero); }
.step h3 { margin-bottom: var(--s2); }
.step p { margin: 0; color: var(--slate); }
.steps--compact { grid-template-columns: 1fr; gap: var(--s3); }
.steps--compact .step { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: var(--s3); border-top: 0; padding-top: 0; }
.steps--compact .step__num { font-size: 18px; margin: 0; padding-top: 2px; color: var(--pillar, var(--ink)); }
.steps--compact h3 { font-size: 18px; }
@media (max-width: 900px) { .steps:not(.steps--compact), .steps--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .steps:not(.steps--compact), .steps--3 { grid-template-columns: 1fr; } }

/* ---------- Quotes ---------- */
.quote { margin: 0; border-left: 3px solid var(--quote-color, var(--pillar, var(--ink))); padding-left: var(--s4); }
.quote__text { font-size: var(--lead-size); line-height: 1.55; font-weight: 500; margin: 0 0 var(--s3); }
.quote__cite { font-style: normal; font-size: var(--caption-size); color: var(--slate); }
.quote__cite b { color: var(--ink); }
.quote--lg .quote__text { font-size: var(--h2-size); line-height: 1.3; font-weight: 700; letter-spacing: -0.01em; }

/* ---------- Podcast: show tile, episode tiles, player (section 38) ---------- */
.show-tile {
  aspect-ratio: 1 / 1; background: var(--ink); color: var(--white); border-radius: var(--radius);
  display: flex; flex-direction: column; justify-content: space-between; padding: 9%; position: relative; overflow: hidden;
  container-type: inline-size;
}
.show-tile__mark { width: 18%; }
.show-tile__title { font-size: clamp(22px, 3.2vw, 36px); line-height: 1.05; font-weight: 300; letter-spacing: -0.02em; margin: 0; color: var(--white); }
/* Size the title by the tile's own width so "Conversations" never clips in the four-up grid */
@supports (font-size: 1cqi) { .show-tile__title { font-size: clamp(18px, 12cqi, 36px); } }
.show-tile__title b { font-weight: 800; display: block; }
.show-tile__desc { font-size: var(--caption-size); color: var(--bone); margin-top: var(--s2); }
.show-tile .spectrum-rule--tile { position: absolute; left: 0; right: 0; bottom: 0; height: 4%; }
.show-tile--sm { padding: 24px; }

.episodes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s4); }
.episodes--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1024px) { .episodes, .episodes--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .episodes, .episodes--4 { grid-template-columns: 1fr; } }
.episode { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; display: flex; flex-direction: column; }
.episode__ground { padding: var(--s4); min-height: 200px; display: flex; flex-direction: column; justify-content: space-between; gap: var(--s4); background: var(--ep-bg, var(--ink)); color: var(--ep-text, var(--white)); }
.episode--health { --ep-bg: var(--teal); --ep-text: var(--ink); }
.episode--wealth { --ep-bg: var(--amber); --ep-text: var(--ink); }
.episode--society { --ep-bg: var(--violet); --ep-text: var(--white); }
.episode--org { --ep-bg: var(--lime); --ep-text: var(--ink); }
.episode--ink { --ep-bg: var(--ink); --ep-text: var(--white); }
.episode__ground .label { color: inherit; }
.episode__title { font-size: 22px; line-height: 1.2; font-weight: 700; margin: 0; color: inherit; letter-spacing: -0.01em; }
.episode__meta { padding: var(--s3) var(--s4); display: flex; flex-wrap: wrap; align-items: center; gap: var(--s2) var(--s3); font-size: var(--caption-size); color: var(--slate); }
.episode__meta .dot::before { content: "\00B7"; margin-right: var(--s3); }
.episode__actions { margin-left: auto; display: flex; align-items: center; gap: var(--s3); }
/* 44 px tap box without changing the meta row's visual height (negative margin absorbs the extra) */
.episode__actions button, .episode__actions a { font: inherit; font-size: var(--caption-size); font-weight: 700; color: var(--ink); background: none; border: 0; padding: 0; cursor: pointer; text-decoration: underline; text-underline-offset: 0.15em; display: inline-flex; align-items: center; min-height: 44px; margin: -10px 0; }
.episode[hidden] { display: none; }

.player { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--s4); display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: var(--s3) var(--s4); align-items: center; }
.player__play { width: var(--control-h); height: var(--control-h); border-radius: var(--radius); border: 0; background: var(--ink); color: var(--white); cursor: pointer; display: grid; place-items: center; transition: background-color var(--dur-ui) var(--ease); }
.player__play:hover { background: var(--hover); color: var(--hover-text); }
.player__play svg { width: 20px; height: 20px; fill: currentColor; }
.player__play .icon-pause { display: none; }
.player__play.is-playing .icon-play { display: none; }
.player__play.is-playing .icon-pause { display: block; }
.player__label { font-size: var(--caption-size); color: var(--slate); }
.player__title { font-weight: 700; font-size: 18px; line-height: 1.3; margin: 2px 0 var(--s2); }
.player__scrub { -webkit-appearance: none; appearance: none; width: 100%; height: 4px; border-radius: 2px; background: linear-gradient(90deg, var(--ink) 0 var(--p, 0%), var(--line) var(--p, 0%) 100%); cursor: pointer; margin: var(--s2) 0; }
.player__scrub::-webkit-slider-thumb { -webkit-appearance: none; width: 16px; height: 16px; border-radius: 50%; background: var(--ink); border: 0; }
.player__scrub::-moz-range-thumb { width: 16px; height: 16px; border-radius: 50%; background: var(--ink); border: 0; }
.player__scrub::-moz-range-track { height: 4px; background: transparent; }
.player__time { display: flex; justify-content: space-between; font-size: var(--caption-size); color: var(--slate); font-variant-numeric: tabular-nums; }
.player__side { display: flex; flex-direction: column; gap: var(--s2); align-items: stretch; }
.player__side .btn { height: var(--control-h); padding: 0 var(--s3); font-size: 14px; }
.player__note { grid-column: 1 / -1; font-size: var(--caption-size); color: var(--slate); border-top: 1px solid var(--line); padding-top: var(--s2); }
@media (max-width: 640px) { .player { grid-template-columns: auto minmax(0, 1fr); } .player__side { grid-column: 1 / -1; flex-direction: row; } }

.transcript { background: var(--white); border: 1px solid var(--line); border-top: 0; border-radius: 0 0 var(--radius) var(--radius); padding: var(--s4); }
.transcript[hidden] { display: none; }
/* The transcript is plain content without JavaScript; with it, js/podcast.js collapses the panel and toggles data-open */
.js .transcript:not([data-open="true"]) { display: none; }
.transcript h3 { margin: 0; }
.transcript__line { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: var(--s3); padding: var(--s2) 0; border-bottom: 1px solid var(--line); }
.transcript__line:last-child { border-bottom: 0; }
.transcript__time { font-size: var(--caption-size); color: var(--slate); font-variant-numeric: tabular-nums; padding-top: 3px; }
.transcript__speaker { font-weight: 700; margin-right: var(--s2); }

.subscribe { display: flex; flex-wrap: wrap; gap: var(--s2); }

/* ---------- Forms (section 32) ---------- */
.form { display: grid; gap: var(--s4); }
.form__row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s4); }
@media (max-width: 560px) { .form__row { grid-template-columns: 1fr; } }
.field { display: flex; flex-direction: column; gap: var(--s2); }
.field__label { font-size: var(--caption-size); font-weight: 700; color: var(--ink); }
.field__label .optional { font-weight: 400; color: var(--slate); }
.field > legend.field__label { margin-bottom: var(--s2); }   /* a rendered legend is not a flex item, so the .field gap does not reach it */
.field__help { font-size: var(--caption-size); color: var(--slate); }
.input, .select, .textarea {
  width: 100%; font: inherit; font-size: 16px; color: var(--ink); background: var(--white);
  border: 1px solid var(--slate); border-radius: var(--radius); padding: 0 12px; height: var(--control-h);
  transition: border-color var(--dur-ui) var(--ease);
}
/* Field borders use Slate, not Line: Line on White is 1.35:1 and fails WCAG 1.4.11 (3:1) for control boundaries */
.input:hover, .select:hover, .textarea:hover { border-color: var(--ink); }
.input:focus-visible, .select:focus-visible, .textarea:focus-visible { border-color: var(--ink); }
.textarea { height: auto; min-height: 128px; padding: 12px; resize: vertical; line-height: 1.5; }
.select { appearance: none; -webkit-appearance: none; padding-right: 40px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' fill='none' stroke='%232F3238' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; }
.input-group { display: flex; align-items: stretch; }
.input-group__prefix { display: flex; align-items: center; padding: 0 12px; border: 1px solid var(--slate); border-right: 0; border-radius: var(--radius) 0 0 var(--radius); background: var(--bone); color: var(--slate); font-weight: 700; }
.input-group .input { border-radius: 0 var(--radius) var(--radius) 0; }
.field.is-invalid .input, .field.is-invalid .select, .field.is-invalid .textarea { border: 2px solid var(--magenta); padding-left: 11px; }
.field__error { display: none; font-size: var(--caption-size); color: var(--magenta); font-weight: 700; }
.field.is-invalid .field__error { display: block; }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: var(--caption-size); line-height: 1.5; }
.check input { width: 20px; height: 20px; margin: 2px 0 0; flex: none; accent-color: var(--ink); }
.check-group { display: grid; gap: var(--s2); }
.check-group .check { font-size: 16px; }
.form__actions { display: flex; flex-wrap: wrap; gap: var(--s3); align-items: center; }
.form__note { font-size: var(--caption-size); color: var(--slate); }
.form-success { background: var(--white); border-left: 3px solid var(--green); border-radius: 0 var(--radius) var(--radius) 0; box-shadow: var(--shadow); padding: var(--s4); }
.form-success[hidden] { display: none; }
.form-success h3 { margin-bottom: var(--s2); }
.notice { background: var(--white); border: 1px solid var(--line); border-left: 3px solid var(--ink); border-radius: 0 var(--radius) var(--radius) 0; padding: var(--s3) var(--s4); font-size: var(--caption-size); color: var(--slate); }
.notice--amber { border-left-color: var(--amber); }
.notice[hidden] { display: none; }

/* ---------- Accordion ---------- */
.accordion { border-top: 1px solid var(--line); }
.accordion__item { border-bottom: 1px solid var(--line); }
.accordion__item summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: var(--s3); padding: var(--s3) 0; font-weight: 700; font-size: 18px; line-height: 1.3; }
.accordion__item summary::-webkit-details-marker { display: none; }
.accordion__item summary::after { content: "+"; font-weight: 400; font-size: 24px; line-height: 1; color: var(--stone); flex: none; transition: transform var(--dur-ui) var(--ease); }
.accordion__item[open] summary::after { content: "\2212"; }
.accordion__item summary:hover { color: var(--ink); }
.accordion__body { padding: 0 0 var(--s4); max-width: 70ch; color: var(--slate); }
.accordion__body p:last-child { margin: 0; }

/* ---------- Tabs and toggles ---------- */
.tabs { display: flex; flex-wrap: wrap; gap: var(--s4); border-bottom: 1px solid var(--line); }   /* no overflow clipping, so the focus ring stays visible */
.tab { font: inherit; font-weight: 700; color: var(--slate); background: none; border: 0; border-bottom: 2px solid transparent; padding: 12px 0; margin-bottom: -1px; cursor: pointer; white-space: nowrap; }
.tab:hover { color: var(--ink); }
.tab[aria-pressed="true"] { color: var(--ink); border-color: var(--ink); }

.toggle { display: inline-flex; flex-wrap: wrap; max-width: 100%; padding: 4px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); }
.toggle__btn { font: inherit; font-weight: 700; font-size: 14px; height: 40px; padding: 0 16px; border: 0; border-radius: var(--radius); background: transparent; color: var(--slate); cursor: pointer; white-space: nowrap; transition: background-color var(--dur-ui) var(--ease), color var(--dur-ui) var(--ease); }
.toggle__btn:hover { color: var(--ink); }
.toggle__btn[aria-pressed="true"] { background: var(--ink); color: var(--white); }
.toggle-row { display: flex; flex-wrap: wrap; gap: var(--s3); align-items: center; justify-content: space-between; }
@media (max-width: 420px) { .toggle__btn { padding: 0 8px; } }   /* four currency pills fit the 240 px card at 320 px */

/* Donation amount tiles */
.amounts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s3); }
.amount { font: inherit; text-align: left; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--s3); cursor: pointer; display: flex; flex-direction: column; gap: 4px; transition: border-color var(--dur-ui) var(--ease); }
.amount:hover { border-color: var(--stone); }
.amount[aria-pressed="true"] { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.amount__value { font-size: 24px; font-weight: 800; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.amount__value small { font-size: 14px; font-weight: 500; color: var(--slate); letter-spacing: 0; }
.amount__impact { font-size: var(--caption-size); color: var(--slate); }
.amount--featured { border-color: var(--ink); }
@media (max-width: 360px) { .amounts { grid-template-columns: 1fr; } }   /* keeps "₹15,000 a month" on one line in the tile */

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.table th { text-align: left; font-size: var(--label-size); font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: var(--slate); padding: 0 var(--s3) var(--s2) 0; border-bottom: 1px solid var(--ink); }
.table td { padding: 12px var(--s3) 12px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.table th.r, .table td.r { text-align: right; padding-right: 0; }
.table tr.is-focus td { font-weight: 700; }
.table caption { caption-side: bottom; text-align: left; font-size: var(--caption-size); color: var(--slate); padding-top: var(--s2); }

/* ---------- Charts (section 26): one hue per series, Ink for the focus, Line gridlines ---------- */
.chart { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--s4); }
.chart h3 { margin-bottom: var(--s3); }
.chart svg { width: 100%; height: auto; }
.chart__grid line { stroke: var(--line); stroke-width: 1; }
/* SVG type scales with the 480-unit viewBox: 15 / 16 units render at about 13 / 14 px at the 420 px minimum width and 17 / 18 px at desktop */
.chart__scroll svg { min-width: 420px; }
.chart__axis text { font-family: var(--font); font-size: 15px; fill: var(--slate); }
.chart__value { font-family: var(--font); font-size: 16px; font-weight: 700; fill: var(--ink); }
.chart__note { margin-top: var(--s3); font-size: var(--caption-size); color: var(--slate); }
.bar-stack { display: flex; height: 24px; border-radius: var(--radius); overflow: hidden; }
.bar-stack span { display: block; height: 100%; }
.legend { display: flex; flex-wrap: wrap; gap: var(--s3) var(--s4); margin-top: var(--s3); font-size: var(--caption-size); color: var(--slate); list-style: none; padding: 0; }
.legend li { display: flex; align-items: center; gap: var(--s2); }
.legend i { width: 12px; height: 12px; border-radius: 2px; display: inline-block; background: var(--legend-color, var(--ink)); }
.legend b { color: var(--ink); font-variant-numeric: tabular-nums; }

/* ---------- Timeline ---------- */
.timeline { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--s4); }
.timeline li { border-top: 3px solid var(--tl-color, var(--ink)); padding-top: var(--s3); }
.timeline__year { font-size: 28px; font-weight: 800; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.timeline h3 { margin: var(--s1) 0 var(--s2); font-size: 18px; }
.timeline p { margin: 0; color: var(--slate); }
.timeline--5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
@media (max-width: 1024px) { .timeline--5 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 900px) { .timeline, .timeline--5 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px) { .timeline, .timeline--5 { grid-template-columns: 1fr; } }

/* ---------- Brand explainer (about page) ---------- */
.mark-display { width: min(280px, 60%); margin: 0 auto; }
.pairs { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s3); }
.pairs li { display: flex; align-items: center; gap: var(--s3); padding: var(--s2) 0; border-bottom: 1px solid var(--line); }
.pairs li:last-child { border-bottom: 0; }
.pairs b { min-width: 8em; }
.pairs span { color: var(--slate); font-size: var(--caption-size); }

/* ---------- Team ---------- */
.person { display: flex; flex-direction: column; gap: var(--s2); }
.person img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; border-radius: var(--radius); }
.person__name { font-weight: 700; margin: var(--s2) 0 0; }
.person__role { font-size: var(--caption-size); color: var(--slate); }
.person__bio { font-size: var(--caption-size); color: var(--slate); }

/* ---------- Definition rows (at a glance) ---------- */
.kv { list-style: none; margin: 0; padding: 0; }
.kv li { display: flex; justify-content: space-between; gap: var(--s3); padding: 12px 0; border-bottom: 1px solid var(--line); }
.kv li:last-child { border-bottom: 0; }
.kv span:first-child { color: var(--slate); }
.kv span:last-child { font-weight: 700; font-variant-numeric: tabular-nums; text-align: right; min-width: 0; overflow-wrap: anywhere; }
/* Stacked variant for narrow cards holding long values (bank details) */
.kv--stack li { flex-direction: column; align-items: flex-start; gap: 2px; }
.kv--stack span:last-child { text-align: left; }

/* ---------- Media figures ---------- */
.figure { margin: 0; }
.figure img { width: 100%; border-radius: var(--radius); object-fit: cover; }
.figure--43 img { aspect-ratio: 4 / 3; }
.figure--169 img { aspect-ratio: 16 / 9; }
.figure--11 img { aspect-ratio: 1 / 1; }
.figure figcaption { margin-top: var(--s2); font-size: var(--caption-size); color: var(--slate); }

/* ---------- Decorative petal motif (section 24): never behind text ---------- */
.motif { position: absolute; pointer-events: none; user-select: none; }
.has-motif { position: relative; overflow: hidden; }

/* ---------- CTA band (Ink ground) ---------- */
.cta-band { background: var(--ink); color: var(--bone); padding: var(--s6) 0; }
.cta-band h2 { color: var(--white); }
.cta-band .lead { color: var(--line); }
.cta-band__grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--s5); align-items: center; position: relative; }
.cta-band .btn-row { margin-top: var(--s4); }
.cta-band__motif { right: -6%; top: 50%; transform: translateY(-50%); width: 34%; max-width: 480px; }
@media (max-width: 900px) { .cta-band__motif { display: none; } }
@media (max-width: 800px) { .cta-band { padding: var(--s5) 0; } .cta-band__grid { grid-template-columns: 1fr; gap: var(--s4); } }

/* ---------- Footer ---------- */
.footer { background: var(--white); border-top: 1px solid var(--line); padding: var(--s5) 0 var(--s4); font-size: var(--caption-size); }
.footer__grid { display: grid; grid-template-columns: minmax(0, 4fr) repeat(4, minmax(0, 2fr)); gap: var(--s4); }
.footer__brand p { margin-top: var(--s3); color: var(--slate); max-width: 34ch; }
.footer__desc { display: block; margin-top: var(--s2); color: var(--slate); }
.footer h3 { font-size: var(--label-size); letter-spacing: 0.16em; text-transform: uppercase; color: var(--slate); margin-bottom: var(--s3); }
.footer ul { list-style: none; margin: 0; padding: 0; }
.footer li { margin-bottom: var(--s2); }
.footer a { color: var(--ink); }
.footer address { font-style: normal; color: var(--slate); line-height: 1.6; }
.footer__legal { margin-top: var(--s5); padding-top: var(--s3); border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--s2) var(--s4); color: var(--slate); }
@media (max-width: 1024px) { .footer__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .footer__brand { grid-column: 1 / -1; } }
@media (max-width: 480px) { .footer__grid { grid-template-columns: 1fr; } }

/* ---------- Motion (section 37): enter from below, 400 ms, one animated element per view ---------- */
.js .reveal { opacity: 0; transform: translateY(16px); transition: opacity var(--dur-enter) var(--ease), transform var(--dur-enter) var(--ease); }
.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .js .reveal { transform: none; transition: opacity var(--dur-enter) linear; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; }
}

/* ---------- Utilities ---------- */
.mt-0 { margin-top: 0 !important; } .mb-0 { margin-bottom: 0 !important; }
.mt-2 { margin-top: var(--s2); } .mt-3 { margin-top: var(--s3); } .mt-4 { margin-top: var(--s4); } .mt-5 { margin-top: var(--s5); }
.mb-2 { margin-bottom: var(--s2); } .mb-3 { margin-bottom: var(--s3); } .mb-4 { margin-bottom: var(--s4); } .mb-5 { margin-bottom: var(--s5); }
.flex { display: flex; gap: var(--s3); align-items: center; flex-wrap: wrap; }
.between { justify-content: space-between; }
.center { text-align: center; }
.w-100 { width: 100%; }
[hidden] { display: none !important; }

@media print {
  .header, .nav-toggle, .cta-band, .skip-link { display: none; }
  body { background: #fff; }
  /* Sections not yet scrolled into view would otherwise print blank */
  .js .reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
}

/* ---------- Long-form pages (privacy, accessibility) ---------- */
.prose { max-width: 68ch; }
.prose h2 { font-size: 22px; margin-top: var(--s5); }
.prose h2:first-child { margin-top: 0; }
.prose ul, .prose ol { margin: 0 0 var(--s3); padding-left: 1.2em; }
.prose li { margin-bottom: var(--s2); }
.prose .caption { margin-top: var(--s4); }
