/* ---- Figures and page furniture shared by index.html, how-it-works.html and about.html.

   The figures are small drawings built from plain elements: a shelf of products that gets
   audited, a product checked before buying, a 28-day ring, and dot grids for what students
   told us. Each one is a .reveal, so motion.js adds .is-in when it scrolls into view and the
   rules under `.motion .fig.is-in` play once. Transform and opacity only, slow and calm.
   Without JS or with reduced motion the figure simply shows its finished state. */

/* Inner pages reuse the homepage's section rhythm */
.page-hero { padding: 56px 0 8px; }
.page-hero h1 { font-size: clamp(32px, 1rem + 3.4vw, 56px); line-height: 1.08; letter-spacing: -1px; margin: 0 0 16px; max-width: 16em; text-wrap: balance; }
.page-hero .lede { font-size: 19px; max-width: 44ch; margin: 0; }
.home.page section:first-of-type { border-top: 0; }
.home.page .page-hero + section { border-top: 0; }
.more { margin: 24px 0 0; }
.more a::after { content: " \2192"; }
.duo { display: grid; gap: 40px; align-items: center; }
@media (min-width: 860px) {
  .duo { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 72px; }
  .duo.flip > :first-child { order: 2; }
}
.duo p { color: var(--ink-secondary); }
.step-kicker { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 50%; background: var(--oolong); color: var(--on-green); font-size: 14px; font-weight: 700; margin-bottom: 16px; }
.people { list-style: none; margin: 32px 0 0; padding: 0; display: grid; gap: 16px; }
@media (min-width: 720px) { .people { grid-template-columns: 1fr 1fr; gap: 20px; } }
.people li { background: var(--cream-card); border: 1px solid var(--cream-border); border-radius: 16px; padding: 24px; }
.people .role { font-size: 11px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; color: var(--amber); margin: 0 0 8px; }
.people h3 { margin: 0 0 8px; }
.people p { margin: 0; color: var(--ink-secondary); }
.people .links { margin-top: 12px; }
.beliefs { list-style: none; margin: 32px 0 0; padding: 0; display: grid; gap: 20px; max-width: 640px; }
.beliefs li { padding-left: 20px; border-left: 2px solid var(--oolong); }
.beliefs h3 { margin: 0 0 4px; }
.beliefs p { margin: 0; color: var(--ink-secondary); }
.home section.cta-row { text-align: center; }
.cta-row h2 { margin-left: auto; margin-right: auto; }
.cta-row .lede { margin-left: auto; margin-right: auto; }

/* The green band on the homepage */
.home section.band { background: var(--oolong); color: var(--cream); border-top: 0; }
.home section.band + section { border-top: 0; }
.band .eyebrow { color: var(--cream); opacity: 0.7; }
.home .band h2 { font-size: clamp(36px, 1rem + 5vw, 72px); letter-spacing: -1.5px; line-height: 1.02; max-width: 12em; }
.band .lede { color: var(--cream); opacity: 0.86; }

/* ---- Figure frame */
.fig {
  position: relative;
  background: var(--cream-card);
  border: 1px solid var(--cream-border);
  border-radius: 20px;
  padding: 24px 20px 20px;
  max-width: 520px;
  width: 100%;
  margin: 0 auto;
}
.fig-label { font-size: 11px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; color: var(--ink-secondary); margin: 0 0 20px; }
.fig-note { font-size: 13px; color: var(--ink-secondary); margin: 16px 0 0; max-width: none; }
.band .fig { background: none; border: 0; padding: 0; max-width: 720px; margin-top: 48px; }

/* ---- Products. Sizes are in em so a shelf scales with its font-size. Each product has a
   solid drawing and an outline drawing stacked; "ghosting" one cross-fades between them. */
.shelf {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 0.5em;
  font-size: clamp(11px, 3.5vw, 17px);
  border-bottom: 2px solid var(--ink);
  padding: 0 0.4em;
}
.prod { position: relative; flex: none; display: block; }
.prod .solid, .prod .line { display: flex; flex-direction: column; align-items: center; }
.prod .line { position: absolute; inset: 0; opacity: 0; }
.prod i { display: block; box-sizing: border-box; }
.prod .solid i { background: var(--c, var(--oolong)); }
.prod .line i { border: 2px solid var(--ink-secondary); }
.prod .body { position: relative; }
.prod .solid .body::after { content: ""; position: absolute; left: 18%; right: 18%; top: 36%; height: 26%; border-radius: 2px; background: var(--cream); opacity: 0.8; }
.prod.plain .solid .body::after { display: none; }
.prod.jar .cap { width: 3.3em; height: 0.75em; border-radius: 0.25em 0.25em 0.08em 0.08em; }
.prod.jar .body { width: 3.1em; height: 2.3em; border-radius: 0.3em 0.3em 0.6em 0.6em; margin-top: 0.08em; }
.prod.bottle .cap { width: 0.95em; height: 1.05em; border-radius: 0.2em 0.2em 0 0; }
.prod.bottle .body { width: 2.1em; height: 4.6em; border-radius: 0.7em 0.7em 0.35em 0.35em; }
.prod.dropper .cap { width: 0.7em; height: 1.5em; border-radius: 0.35em 0.35em 0 0; }
.prod.dropper .body { width: 1.6em; height: 3.6em; border-radius: 0.5em 0.5em 0.3em 0.3em; }
.prod.tube .solid, .prod.tube .line { flex-direction: column-reverse; }
.prod.tube .cap { width: 1.3em; height: 0.8em; border-radius: 0 0 0.2em 0.2em; }
.prod.tube .body { width: 2em; height: 4.2em; border-radius: 0.15em 0.15em 0.5em 0.5em; }
.prod.ghost .solid { opacity: 0; }
.prod.ghost .line { opacity: 1; }
.band .shelf { border-bottom-color: var(--cream); }
.band .prod .line i { border-color: var(--cream); }
.band .prod .line { opacity: 0; }
.band .prod.ghost .line { opacity: 0.45; }

/* ---- 1. The audit: keep, watch or change */
.fig-shelf .shelf { padding-top: 2.4em; position: relative; }
.fig-shelf .slot { position: relative; display: flex; flex-direction: column; align-items: center; }
.verdict { font-size: 10px; font-weight: 700; letter-spacing: 0.8px; text-transform: uppercase; margin-bottom: 8px; white-space: nowrap; }
.verdict.keep { color: var(--oolong); }
.verdict.watch { color: var(--amber); }
.verdict.change { color: var(--ink-secondary); }
.sweep { position: absolute; left: 0; right: 0; top: 0; bottom: 0; border-left: 2px solid var(--amber); opacity: 0; pointer-events: none; }
.motion .fig-shelf:not(.is-in) .verdict { opacity: 0; transform: translateY(6px); }
.motion .fig-shelf:not(.is-in) .prod.ghost .solid { opacity: 1; }
.motion .fig-shelf:not(.is-in) .prod.ghost .line { opacity: 0; }
.motion .fig-shelf .verdict { transition: opacity 0.7s ease calc(var(--i) * 0.6s + 0.7s), transform 0.7s ease calc(var(--i) * 0.6s + 0.7s); }
.motion .fig-shelf .prod .solid, .motion .fig-shelf .prod .line { transition: opacity 0.9s ease calc(var(--i) * 0.6s + 0.9s); }
.motion .fig-shelf.is-in .sweep { animation: fig-sweep 4.4s cubic-bezier(0.4, 0, 0.6, 1) 0.4s both; }
@keyframes fig-sweep {
  0% { opacity: 0; transform: translateX(0); }
  8%, 90% { opacity: 0.55; }
  100% { opacity: 0; transform: translateX(100%); }
}

/* ---- 2. Check before you buy */
.fig-check { padding-top: 20px; }
.check-top { position: relative; height: 150px; display: flex; align-items: center; justify-content: center; }
.check-chips { position: absolute; left: 0; right: 0; top: 0; height: 30px; }
.chip { position: absolute; left: 50%; top: 0; transform: translateX(-50%); font-size: 12px; font-weight: 700; letter-spacing: 0.6px; text-transform: uppercase; white-space: nowrap; }
.chip.ask { color: var(--amber); opacity: 0; }
.chip.answer { color: var(--ink); }
.candidate { position: relative; font-size: clamp(13px, 3.8vw, 18px); margin-top: 28px; }
.candidate .halo { position: absolute; left: 50%; top: 50%; width: 6.4em; height: 6.4em; margin: -3.2em 0 0 -3.2em; border-radius: 50%; border: 2px dashed var(--amber); opacity: 0; }
.fig-check .shelf .gap { width: 3.3em; height: 3em; border: 2px dashed var(--cream-border); border-bottom: 0; border-radius: 0.4em 0.4em 0 0; }
.motion .fig-check:not(.is-in) .chip.answer { opacity: 0; }
.motion .fig-check:not(.is-in) .candidate { opacity: 0; transform: translateY(-10px); }
.motion .fig-check:not(.is-in) .candidate .prod .solid { opacity: 1; }
.motion .fig-check:not(.is-in) .candidate .prod .line { opacity: 0; }
.motion .fig-check .candidate { transition: opacity 0.9s ease 0.3s, transform 1s ease 0.3s; }
.motion .fig-check .candidate .prod .solid, .motion .fig-check .candidate .prod .line { transition: opacity 1s ease 3.6s; }
.motion .fig-check .chip.answer { transition: opacity 0.9s ease 3.6s; }
.motion .fig-check.is-in .chip.ask { animation: fig-ask 3.4s ease 0.9s both; }
.motion .fig-check.is-in .halo { animation: fig-ask 3.4s ease 0.7s both; }
@keyframes fig-ask { 0% { opacity: 0; } 22%, 78% { opacity: 1; } 100% { opacity: 0; } }

/* ---- 3. Twenty-eight days */
.fig-ring { display: flex; flex-direction: column; align-items: center; }
.ring { --size: min(44vw, 250px); position: relative; width: var(--size); height: var(--size); margin: 34px 52px; }
.ring .day {
  position: absolute; left: 50%; top: 50%;
  width: 8px; height: 8px; margin: -4px 0 0 -4px;
  border-radius: 50%;
  background: var(--oolong);
  transform: rotate(calc(var(--i) * 12.857deg)) translateY(calc(var(--size) / -2));
}
.ring .day.week { width: 14px; height: 14px; margin: -7px 0 0 -7px; }
.ring .day.last { width: 20px; height: 20px; margin: -10px 0 0 -10px; background: var(--amber); }
.ring-mid { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.ring-mid strong { font-size: clamp(40px, 12vw, 56px); line-height: 1; letter-spacing: -2px; }
.ring-mid span { font-size: 13px; color: var(--ink-secondary); margin-top: 4px; }
.ring-tag { position: absolute; font-size: 10px; font-weight: 700; letter-spacing: 0.8px; text-transform: uppercase; color: var(--ink-secondary); white-space: nowrap; }
.ring-tag.d7 { left: 100%; top: 50%; transform: translate(14px, -50%); }
.ring-tag.d14 { left: 50%; top: 100%; transform: translate(-50%, 14px); }
.ring-tag.d21 { right: 100%; top: 50%; transform: translate(-14px, -50%); }
.ring-tag.d28 { left: 50%; bottom: 100%; transform: translate(-50%, -18px); color: var(--amber); }
.motion .fig-ring:not(.is-in) .day { opacity: 0.18; }
.motion .fig-ring .day { transition: opacity 0.7s ease calc(var(--i) * 110ms + 400ms); }
.motion .fig-ring:not(.is-in) .ring-tag { opacity: 0; }
.motion .fig-ring .ring-tag { transition: opacity 0.8s ease var(--d, 0s); }

/* ---- 4. What 80 students told us */
.stats { display: grid; gap: 20px; margin-top: 40px; }
@media (min-width: 760px) { .stats { grid-template-columns: 1fr 1fr; gap: 24px; } }
.stats .fig { max-width: none; margin: 0; padding: 24px; }
.stat-num { font-size: clamp(34px, 1rem + 3vw, 52px); font-weight: 700; letter-spacing: -1px; line-height: 1; margin: 0 0 8px; }
.stat-num small { font-size: 0.45em; font-weight: 600; letter-spacing: 0; color: var(--ink-secondary); margin-left: 6px; }
.stat-text { margin: 0 0 20px; color: var(--ink-secondary); max-width: 30ch; }
.dots { display: grid; grid-template-columns: repeat(16, 1fr); gap: 5px; max-width: 420px; }
.dots i { display: block; aspect-ratio: 1; border-radius: 50%; background: var(--cream-border); }
.dots i.on { background: var(--dot, var(--oolong)); }
.motion .fig-dots:not(.is-in) .dots i.on { opacity: 0; }
.motion .fig-dots .dots i.on { transition: opacity 0.6s ease calc(var(--i) * 28ms + 300ms); }
.sample-note { font-size: 13px; color: var(--ink-secondary); margin: 20px 0 0; }

/* ---- 5. The band: a full shelf thins to the two you need */
.fig-thin .shelf { font-size: clamp(9px, 2.9vw, 20px); }
.fig-thin .prod .solid i { background: var(--c, var(--cream)); }
.motion .fig-thin:not(.is-in) .prod.ghost .solid { opacity: 1; }
.motion .fig-thin:not(.is-in) .prod.ghost .line { opacity: 0; }
.motion .fig-thin .prod .solid, .motion .fig-thin .prod .line { transition: opacity 1.1s ease calc(var(--i) * 0.28s + 1s); }
.thin-note { font-size: 13px; color: var(--cream); opacity: 0.7; margin: 16px 0 0; }
.motion .fig-thin:not(.is-in) .thin-note { opacity: 0; }
.motion .fig-thin .thin-note { transition: opacity 1s ease 3.6s; }

/* Promises: three cards, reusing .points */
.promises { margin-top: 32px; }
