/* ============================================================
   TFG* Tech for Good — Homepage blocks (redesign, 30 Sep 2026)
   Layers on tokens.css + main.css + marks.css. Sections keep main.css's rhythm:
   one section per viewport, snap on scroll, content centred.
   ============================================================ */

.one-line {
  margin: 0;
  font-size: clamp(15px, 1.5vw, 19px);
  line-height: 1.6;
  color: var(--color-body);
  max-width: 560px;
}

/* The accent line is inline-block so its box is the line box, not the taller
   glyph box that a line-height of 1 leaves hanging over the lede. */
.hero--horizon .hero-title .accent-italic { display: block; }

/* ============================================================
   HERO (A4, final): trimmed copy, ridge under the page, no strip
   ============================================================ */
/* The ridge sits in normal flow under the copy, so it can never overlap it. The
   copy takes all the leftover height and centres in it, so the ridge rests on
   the bottom edge of the section at every screen size. */
.hero--horizon .hero-inner { flex: 1 0 auto; justify-content: center; padding-top: clamp(72px, 10vw, 140px); padding-bottom: clamp(28px, 4vw, 56px); }
.hero--horizon .ridge-wrap { margin-bottom: -2px; }

/* ============================================================
   WORK (B3, final): one case per screen, working slider, logos
   ============================================================ */
.spread-slider { border: var(--border-heavy); background: var(--color-bg); }
.spread {
  flex: none;
  width: 100%;
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  background: var(--color-bg);
}
.spread-shot {
  display: block;
  position: relative;
  margin: 0;
  overflow: hidden;
  border-right: var(--border-heavy);
  background: var(--color-bg-alt);
  min-height: clamp(260px, 30vw, 420px);
}
.spread-shot img { display: block; width: 100%; height: 100%; object-fit: cover; }
.spread-body {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: clamp(24px, 3.5vw, 48px);
}
.spread-stat {
  font-family: var(--font-serif);
  font-weight: 300;
  font-size: clamp(30px, 3.8vw, 50px);
  line-height: 1.05;
  letter-spacing: -.015em;
  text-wrap: pretty;
}
.spread-stat .accent-italic { font-style: italic; color: var(--color-accent); }
.spread .case-tags { margin-top: auto; }
.spread-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  background: var(--color-bg-alt);
  border: var(--border-heavy);
  border-top: 0;
}
@media (max-width: 811px) {
  .spread { grid-template-columns: 1fr; }
  .spread-shot { border-right: 0; border-bottom: var(--border-heavy); min-height: 0; aspect-ratio: 4 / 3; }
}

/* --- Case images (W1): TFG × client lockup on cream ---
   The frame is the image slot. It is a flex column so a lockup centres in it. */
.frame {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 18px;
  padding: 24px;
  text-align: center;
}
.frame--cream { background: var(--color-bg); }
.lockup { display: flex; flex-direction: column; align-items: center; gap: 18px; }
.lockup-tfg {
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: clamp(18px, 2.1vw, 28px);
  letter-spacing: -.01em;
  color: var(--color-ink);
}
.lockup-x {
  font-family: var(--font-serif);
  font-size: clamp(22px, 2.6vw, 34px);
  color: var(--color-accent);
  line-height: 1;
}
.lockup-logos { display: flex; align-items: center; gap: clamp(18px, 2.4vw, 32px); flex-wrap: wrap; justify-content: center; }
.lockup-logos img { display: block; height: clamp(26px, 3vw, 40px); width: auto; }
.lockup-logos .is-myntra { height: clamp(40px, 4.6vw, 62px); }
.lockup-logos .is-cult { height: clamp(30px, 3.4vw, 46px); }
.lockup-logos .is-mano { height: clamp(52px, 6vw, 80px); border-radius: 22%; }
.lockup-logos .is-iitg { height: clamp(56px, 6.5vw, 88px); }
.lockup-name--sm { font-size: clamp(24px, 2.8vw, 38px); }
.lockup-name {
  font-family: var(--font-serif);
  font-size: clamp(30px, 3.8vw, 52px);
  line-height: 1;
  letter-spacing: -.015em;
  color: var(--color-ink);
}
.lockup-sub {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: .18em;
  color: var(--color-muted);
  text-transform: uppercase;
}
/* ============================================================
   FOUNDERS (C2): three boxes, outward and inward
   ============================================================ */
.spine-grid { --spine-grid-gap: clamp(16px, 2.5vw, 28px); display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--spine-grid-gap); }
.spine-card { border: var(--border-heavy); background: var(--color-bg); display: flex; flex-direction: column; }
.spine-head {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: clamp(16px, 2vw, 24px);
  border-bottom: 1px solid var(--border-ink-25);
}
.spine-head img {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center 22%;
  border: 1.5px solid var(--color-ink);
}
.spine-head .person-head { flex: 1; }
.spine-head .person-name { font-size: clamp(22px, 2.2vw, 28px); }
/* Paired rows: column 1 outward, column 3 inward, one shared row per pair.
   The axis is drawn once down the middle; markers sit at each row's top,
   so the orange and white squares are always level with each other. */
.spine {
  --spine-gap: clamp(18px, 2.2vw, 30px);
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1px 1fr;
  gap: 14px var(--spine-gap);
  align-items: start;
  padding: clamp(18px, 2.4vw, 28px) clamp(16px, 2vw, 24px);
}
.spine::before {
  content: "";
  position: absolute;
  left: 50%;
  top: clamp(18px, 2.4vw, 28px);
  bottom: clamp(18px, 2.4vw, 28px);
  width: 1px;
  background: var(--color-ink);
  transform: translateX(-.5px);
}
.spine-label {
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--color-muted);
  margin-bottom: 4px;
}
.spine-label--out { grid-column: 1; text-align: right; color: var(--color-accent); }
.spine-label--in { grid-column: 3; }
.spine-item { position: relative; font-size: 14px; line-height: 1.5; color: var(--color-body); min-width: 0; }
.spine-item--out { grid-column: 1; text-align: right; }
.spine-item--in { grid-column: 3; }
/* Row marker: one square centred on the axis, orange on the outward half,
   cream on the inward half. Axis x = outward item's right edge + gap + 0.5px. */
.spine--marked .spine-item--out::before {
  content: "";
  position: absolute;
  top: 5px;
  right: calc(-1 * var(--spine-gap) - 6px);
  width: 11px;
  height: 11px;
  box-sizing: border-box;
  border: 1.5px solid var(--color-ink);
  background: linear-gradient(90deg, var(--color-accent) 0 50%, var(--color-bg) 50% 100%);
  z-index: 1;
}
.spine-card .person-quote {
  margin: auto 0 0;
  padding: clamp(14px, 2vw, 20px) clamp(16px, 2vw, 24px);
  border-top: 1px solid var(--border-ink-20);
}
/* Three cards: a row of three on wide screens, two with the third centred
   below on tablets, one column on phones. */
@media (max-width: 1139px) {
  .spine-grid { grid-template-columns: 1fr 1fr; }
  .spine-card:last-child:nth-child(odd) { grid-column: 1 / -1; justify-self: center; width: calc(50% - var(--spine-grid-gap) / 2); }
}
@media (max-width: 811px) {
  .spine-grid { grid-template-columns: 1fr; }
  .spine-card:last-child:nth-child(odd) { grid-column: auto; justify-self: stretch; width: auto; }
}

/* ============================================================
   OFFERINGS (D1): one question, three answers
   ============================================================ */
.go { font-family: var(--font-mono); font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: var(--color-accent); }
/* The work heading row ends with the door to /labs/; the slider also ends on a Labs slide. */
.work-more { white-space: nowrap; }
.spread--lab .lockup { gap: 10px; }

/* D1a · three cards, hairline frame, hover fills orange.
   Hierarchy: name > tag/icon/number > one line > chips or facts > quote. */
.doors { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--border-contact-35); border: 1px solid var(--border-contact-35); }
.door {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: clamp(20px, 2.4vw, 30px);
  background: var(--color-ink);
  color: var(--color-dark-text);
  transition: background .2s;
}
.door-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.door-ico { width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; color: var(--color-accent); }
.door-ico svg { width: 32px; height: 32px; display: block; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.door-tag { text-transform: uppercase; white-space: nowrap; }
.door-title {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(24px, 2.4vw, 32px);
  line-height: 1.1;
  letter-spacing: -.015em;
  color: var(--color-dark-serif);
  text-wrap: pretty;
}
.door-line { font-size: clamp(14px, 1.3vw, 15.5px); line-height: 1.6; color: var(--color-dark-muted); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips--dark .badge { text-transform: uppercase; color: var(--color-dark-text); border-color: var(--border-contact-35); }
/* Hover: the card's outline turns orange, like the tag's outline. Drawn
   with an inset ring so the hairline grid does not shift. */
.door:hover { opacity: 1; box-shadow: 0 0 0 1.5px var(--color-accent); z-index: 1; }
@media (max-width: 900px) { .doors { grid-template-columns: 1fr; } }
@media (max-width: 400px) { .door-top { flex-wrap: wrap; } .door-tag { white-space: normal; } }

/* ============================================================
   PROCESS (E2, final): the calendar
   ============================================================ */
.calendar { grid-template-columns: repeat(4, 1fr); }
.calendar .stat-n { font-size: clamp(34px, 5vw, 72px); line-height: .95; }
.calendar .stat-n small { font-family: var(--font-mono); font-size: 10px; letter-spacing: .16em; display: block; margin-bottom: 8px; color: var(--color-accent); text-transform: uppercase; }
.calendar .step-title { font-size: clamp(17px, 1.6vw, 21px); }
.calendar .stat-cell { position: relative; gap: 10px; }
.calendar .stat-cell:last-child { background: var(--color-ink); color: var(--color-dark-serif); }
/* Moon phases, one per week: new, crescent, half, and a full orange moon on the ink cell */
.phase { position: absolute; top: 20px; right: 20px; width: 22px; height: 22px; fill: none; stroke: var(--color-ink); stroke-width: 1.5; }
.phase .phase-fill { fill: var(--color-ink); stroke: none; }
.phase--full circle { fill: var(--color-accent); stroke: var(--color-accent); }
@media (max-width: 720px) { .phase { top: 14px; right: 14px; width: 18px; height: 18px; } }
.calendar .stat-cell:last-child .stat-label { color: var(--color-dark-muted); }
@media (max-width: 720px) { .calendar { grid-template-columns: repeat(2, 1fr); } }

/* ============================================================
   VOICES: one card per voice, auto-advancing. Minimal: hairline frame,
   readable serif, the role at full contrast.
   ============================================================ */
.voice-slider { border: 1px solid var(--border-contact-35); background: var(--color-ink); }
.voice-card {
  flex: none;
  width: 100%;
  min-width: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: clamp(22px, 3vw, 36px);
  padding: clamp(26px, 3.5vw, 52px) clamp(22px, 4vw, 64px);
  background: var(--color-ink);
}
.voice-text {
  margin: 0;
  max-width: 860px;
  font-family: var(--font-serif);
  font-weight: 300;
  font-size: clamp(19px, 2vw, 27px);
  line-height: 1.45;
  color: var(--color-dark-serif);
  text-wrap: pretty;
}
.voice-who { display: flex; align-items: center; gap: 30px; }
.voice-photo { flex: none; width: 56px; height: 56px; border-radius: 50%; object-fit: cover; border: 1.5px solid var(--color-accent); background: var(--color-bg); }
.voice-meta { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.voice-name { font-family: var(--font-sans); font-weight: 600; font-size: 15px; color: var(--color-dark-text); }
.voice-role { font-family: var(--font-sans); font-size: 14px; line-height: 1.5; color: var(--color-dark-text); opacity: .85; }
.voice-nav { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; border: 1px solid var(--border-contact-35); border-top: 0; background: var(--color-ink); }
.voice-nav .slider-dot::before { border-color: var(--color-dark-text); }
.voice-nav .slider-arrow { background: var(--color-ink); color: var(--color-dark-text); border: 1px solid var(--border-contact-35); }
.voice-nav .slider-arrow--next { background: var(--color-accent); color: var(--color-ink); border-color: var(--color-accent); }

/* ============================================================
   One section per screen on shorter laptops (900px and 800px tall):
   the hero, work, founders and contact sections trim their vertical
   rhythm so they fit the viewport instead of running a few lines over.
   ============================================================ */
@media (min-width: 812px) and (max-height: 920px) {
  .hero--horizon .hero-inner { padding-top: clamp(56px, 7vw, 96px); padding-bottom: 24px; gap: clamp(16px, 2vw, 24px); }
  .work-inner { padding-top: clamp(32px, 4vw, 52px); padding-bottom: clamp(24px, 3vw, 36px); }
  .work .section-head { margin-bottom: clamp(16px, 2.5vw, 28px); }
}
@media (min-width: 812px) and (max-height: 820px) {
  .hero--horizon .hero-title { font-size: clamp(40px, 6.6vw, 84px); }
  .spread-shot { min-height: clamp(240px, 26vw, 360px); }
  .spread-body { padding: clamp(18px, 2.4vw, 32px); gap: 12px; }
  .spread-stat { font-size: clamp(26px, 3vw, 40px); }
  .work-inner { padding-top: clamp(28px, 3.5vw, 40px); padding-bottom: 20px; }
  .work .section-head { margin-bottom: 14px; }
  .spread-nav { padding: 8px 12px; }
  .work .marquee-group { padding: 12px 16px; }
  .who-inner { padding-top: clamp(28px, 4vw, 48px); padding-bottom: clamp(28px, 4vw, 48px); }
  .who .section-head { margin-bottom: 10px; }
}

/* ============================================================
   Nature marks (1 Oct 2026): dawn sun, two-arc moon, circle row markers,
   testimonial ripples. The ridge, contact moon and footer are shared with
   the sub-pages in marks.css.
   ============================================================ */

/* Draw on arrival: the line is one stroke, then the fill settles in. The hero
   runs on load (CSS only, so it also works without JS). Contact waits for
   .is-drawn, which elements.js adds when the section scrolls into view. */
/* The dash is 4 path lengths, not 1: the ridge is stretched sideways with a
   non-scaling stroke, and Chrome then measures the dash short on wide screens
   (72% of the line at 2000px), which left the right end undrawn. The spare
   length is never seen; the longer run just makes the visible draw take about
   a second on common screens and the rest of the time passes unseen. */
.ridge-wrap--hero .ridge-line { stroke-dasharray: 4; stroke-dashoffset: 4; animation: ridgeDraw 2.8s cubic-bezier(.65, 0, .35, 1) .2s forwards; }
.ridge-wrap--hero .ridge-fill { opacity: 0; animation: ridgeFill .8s ease-out 1.4s forwards; }

/* ---------- Hero: the sun rises on the eastern slope ---------- */
.sun {
  position: absolute;
  left: 74%;
  bottom: calc(var(--ridge-h) * .26 + 10px);
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--color-accent);
  opacity: 0;
  transform: translateY(14px);
  animation: sunRise 1.2s cubic-bezier(.2, .7, .3, 1) 1.5s forwards;
}
@media (max-width: 640px) { .sun { left: 70%; bottom: calc(var(--ridge-h) * .56 + 12px); width: 11px; height: 11px; } }

/* ---------- Manifesto: a full moon behind the words ---------- */
.manifesto--moon { position: relative; overflow: hidden; }
.manifesto--moon .manifesto-inner { position: relative; z-index: 1; }
.fullmoon {
  position: absolute; left: 50%; top: 50%;
  width: clamp(240px, 34vw, 400px); aspect-ratio: 1;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  border: 1.5px solid rgba(239, 233, 219, .26);
}

/* ---------- Voices: ripples from the portrait ---------- */
.voice-photo-wrap { position: relative; flex: none; width: 56px; height: 56px; }
.voice-photo-wrap::before, .voice-photo-wrap::after {
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  border: 1px solid rgba(253, 246, 236, .35);
  animation: ripple 6s ease-out infinite;
}
.voice-photo-wrap::after { animation-delay: 3s; }
@keyframes ripple { 0% { transform: scale(1); opacity: .9; } 100% { transform: scale(1.75); opacity: 0; } }

/* ---------- Reduced motion: final states, no movement ---------- */
@media (prefers-reduced-motion: reduce) {
  .sun, .voice-photo-wrap::before, .voice-photo-wrap::after { animation: none !important; }
  .sun { opacity: 1 !important; transform: none !important; }
  .voice-photo-wrap::before { transform: scale(1.3); opacity: .5; }
  .voice-photo-wrap::after { display: none; }
}

/* ---------- HERO sun treatments ---------- */
/* H1 · Dawn: the disc sits before the ridge svgs in the DOM, so the ridge fill hides its lower half */
.ridge-wrap--dawn { overflow: hidden; }
.ridge-wrap--dawn .horizon { position: relative; z-index: 1; }
.ridge-wrap--dawn .sun--dawn {
  z-index: 0;
  left: 66%;
  bottom: calc(var(--ridge-h) * .33 - 20px);
  width: 40px; height: 40px;
  transform: translateY(24px);
  animation: sunRise 1.6s cubic-bezier(.2, .7, .3, 1) 1.5s forwards;
}
@media (max-width: 640px) { .ridge-wrap--dawn .sun--dawn { left: 62%; bottom: calc(var(--ridge-h) * .56 - 15px); width: 30px; height: 30px; } }
/* ---------- FOUNDERS glyph and marker treatments ---------- */
.spine--circle .spine-label { display: block; }
.spine--circle .spine-label--out { text-align: right; }
.spine--circle .spine-item--out::before { border-radius: 50%; width: 12px; height: 12px; right: calc(-1 * var(--spine-gap) - 6.5px); top: 4px; }
.spine-head:hover .person-name { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }

/* ---------- OFFERINGS: static cards vs the one link ---------- */
/* The first two cards are not links: same orange outline on hover, nothing on click. */
.door--static { cursor: default; }
.door .chips { margin-top: 2px; }
.door-foot { margin-top: auto; padding-top: 14px; border-top: 1px solid var(--border-contact-35); }

/* Manifesto: two arcs of a moon so large only its sides remain */
.fullmoon--arcs { width: clamp(1100px, 150vh, 2000px); border-color: rgba(239, 233, 219, .24); }
/* Phones: a smaller ring so the two arcs still enter the screen at the corners */
@media (max-width: 640px) { .fullmoon--arcs { width: 160vw; } }

/* ============================================================
   RESPONSIVE PASS (Oct 2026): header, display type, phones
   ============================================================ */
/* Phone nav scroller: the last link fades out at the edge so a clipped row
   reads as "more this way", and trailing room lets the final link scroll
   fully clear of the fade. */
@media (max-width: 640px) {
  .site-header .site-nav {
    padding-right: 32px;
    -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 32px), transparent);
    mask-image: linear-gradient(to right, #000 calc(100% - 32px), transparent);
  }
}
/* Long navs (homepage, studio): between 641 and 720px the links no longer fit
   beside the logo and button and wrapped to a stray second line. Keep the
   phone header (nav on its own full-width row) through this band instead. */
@media (min-width: 641px) and (max-width: 720px) {
  :root:has(.site-header--long) { --header-h: 98px; }
  .site-header--long { flex-wrap: wrap; gap: 10px 16px; padding: 12px 16px; }
  .site-header--long .logo { order: 1; }
  .site-header--long .btn-header { order: 2; margin-left: auto; }
  .site-header--long .site-nav { order: 3; flex-basis: 100%; flex-wrap: nowrap; justify-content: flex-start; gap: 22px; }
  .site-header--long .site-nav a { padding: 8px 0; white-space: nowrap; }
  .site-header--long .site-nav a::before { top: -8px; bottom: -8px; }
}
/* Display headings break into even lines, never a single last word. */
.hero--horizon .hero-title,
.section-head h2,
.manifesto h2,
.contact h2 { text-wrap: balance; }
.voice-text { text-wrap: pretty; }
/* Chrome will not balance across a <br>, so the accent line after one is
   its own block and balances on its own. */
.manifesto h2 .accent-italic { display: block; }
/* Smallest phones: the hero headline steps down so each short line
   ("Fellow Seekers.", "Products that started") stays on one line. */
@media (max-width: 400px) {
  .hero--horizon .hero-title { font-size: clamp(36px, 12.2vw, 46px); }
}
