/*
 * The public about page (`/about.html`, served at `/` to logged-out
 * visitors -- Arch §17 A108). It lives in `public/`, outside the Vite
 * graph, so it cannot import `src/design/tokens.css`: the brand values
 * below are a COPY of that file's. Keep them in sync by hand -- move both
 * or neither, the same rule this repo applies to every value it restates.
 *
 * The two typefaces are self-hosted on purpose. A Google Fonts link would
 * send every visitor's IP to a third party, on a page whose privacy section
 * says there is no third-party tracking.
 */

@font-face {
  font-family: 'Source Serif 4';
  font-style: normal;
  font-display: swap;
  font-weight: 200 900;
  src: url('./fonts/source-serif-4-latin-wght-normal.woff2') format('woff2-variations');
}

@font-face {
  font-family: 'Source Serif 4';
  font-style: italic;
  font-display: swap;
  font-weight: 200 900;
  src: url('./fonts/source-serif-4-latin-wght-italic.woff2') format('woff2-variations');
}

@font-face {
  font-family: 'Geist';
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url('./fonts/geist-latin-wght-normal.woff2') format('woff2-variations');
}

:root {
  color-scheme: light;

  --font-display: 'Source Serif 4', ui-serif, Georgia, 'Iowan Old Style', serif;
  --font-body: 'Geist', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  --font-mono: ui-monospace, 'SF Mono', 'Cascadia Mono', Menlo, Consolas, monospace;

  --color-bg: #f7f4ee;
  --color-surface: #ffffff;
  --color-surface-2: #f0ece2;
  --color-border: #ddd5c4;
  --color-border-strong: #c7bca4;
  --color-ink: #241f18;
  --color-ink-muted: #635a48;
  --color-ink-faint: #726a56;
  --color-accent: #a8461f;
  --color-accent-strong: #832f10;
  --color-accent-soft: #f3ded2;
  --color-accent-ring: rgba(168, 70, 31, 0.35);
  --color-accent-ink: #ffffff;

  --shadow-sm: 0 1px 2px rgba(30, 24, 15, 0.07), 0 1px 1px rgba(30, 24, 15, 0.05);
  --shadow-lg: 0 24px 48px -24px rgba(30, 24, 15, 0.28), 0 4px 12px rgba(30, 24, 15, 0.06);

  --radius-md: 10px;
  --radius-lg: 20px;
  --radius-pill: 999px;
  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);

  --page-max: 70rem;
  --text-max: 40rem;
  --gutter: clamp(1rem, 4vw, 2rem);
}

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --color-bg: #17140f;
    --color-surface: #1f1b14;
    --color-surface-2: #27221a;
    --color-border: #3a3327;
    --color-border-strong: #4d4433;
    --color-ink: #f2ede1;
    --color-ink-muted: #beb29a;
    --color-ink-faint: #8a7f68;
    --color-accent: #e0763f;
    --color-accent-strong: #f2905c;
    --color-accent-soft: #3a2517;
    --color-accent-ring: rgba(224, 118, 63, 0.4);
    --color-accent-ink: #201002;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.35), 0 1px 1px rgba(0, 0, 0, 0.25);
    --shadow-lg: 0 24px 48px -24px rgba(0, 0, 0, 0.7), 0 4px 12px rgba(0, 0, 0, 0.3);
  }
}

/* ---------- Base ---------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.015em;
  margin: 0;
  text-wrap: balance;
}

p {
  margin: 0;
  text-wrap: pretty;
}

a {
  color: var(--color-accent);
  text-underline-offset: 0.18em;
  text-decoration-thickness: 1px;
}

a:hover {
  color: var(--color-accent-strong);
}

:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
  border-radius: 4px;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

/* Anchor targets land below the sticky header, not under it. */
section[id] {
  scroll-margin-top: 4rem;
}

.wrap {
  width: 100%;
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.skip-link {
  position: absolute;
  left: var(--gutter);
  top: -4rem;
  padding: 0.5rem 1rem;
  background: var(--color-ink);
  color: var(--color-bg);
  border-radius: var(--radius-md);
  z-index: 20;
  text-decoration: none;
}

.skip-link:focus {
  top: 1rem;
}

.eyebrow {
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-accent);
}

/* ---------- Buttons ---------- */

.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 2.75rem;
  padding: 0 1.375rem;
  border-radius: var(--radius-pill);
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  transition:
    background-color 160ms var(--ease-out-expo),
    color 160ms var(--ease-out-expo),
    border-color 160ms var(--ease-out-expo),
    transform 160ms var(--ease-out-expo);
}

.pill:active {
  transform: translateY(1px);
}

.pill-primary {
  background: var(--color-accent);
  color: var(--color-accent-ink);
  border: 1px solid var(--color-accent);
}

.pill-primary:hover {
  background: var(--color-accent-strong);
  border-color: var(--color-accent-strong);
  color: var(--color-accent-ink);
}

.pill-secondary {
  background: transparent;
  color: var(--color-ink);
  border: 1px solid var(--color-border-strong);
}

.pill-secondary:hover {
  border-color: var(--color-ink);
  color: var(--color-ink);
}

.pill-small {
  min-height: 2.25rem;
  padding: 0 1rem;
  font-size: 0.875rem;
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: color-mix(in srgb, var(--color-bg) 88%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid transparent;
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4rem;
}

.wordmark {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--color-ink);
  text-decoration: none;
}

.wordmark:hover {
  color: var(--color-ink);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.site-nav a:not(.pill) {
  color: var(--color-ink-muted);
  font-size: 0.9375rem;
  text-decoration: none;
}

.site-nav a:not(.pill):hover {
  color: var(--color-ink);
}

.wordmark,
.site-nav a {
  white-space: nowrap;
}

/* Five header items fit from about 56rem up. Below that the two section
   anchors drop first, then Features at 40rem. */
@media (max-width: 56rem) {
  .site-nav .nav-optional-wide {
    display: none;
  }
}

@media (max-width: 40rem) {
  .site-nav {
    gap: 1rem;
  }
  .site-nav .nav-optional {
    display: none;
  }
}

/* A phone has room for the wordmark and one pill. The hero's own "Already
   have an invite? Sign in" line sits directly below, so nothing is lost. */
@media (max-width: 26rem) {
  .site-nav .nav-signin {
    display: none;
  }
}

/* At 320px even the wordmark plus one pill overflows; the hero's own
   primary button is the first thing below the header. */
@media (max-width: 21.5rem) {
  .site-nav .pill {
    display: none;
  }
}

/* ---------- Hero ---------- */

.hero {
  padding: clamp(3.5rem, 10vw, 7rem) 0 0;
  text-align: center;
}

.hero .eyebrow {
  display: inline-block;
  padding: 0.3rem 0.8rem;
  border-radius: var(--radius-pill);
  background: var(--color-accent-soft);
  letter-spacing: 0.06em;
}

.hero h1 {
  margin-top: 1.5rem;
  font-size: clamp(3rem, 9vw, 5.75rem);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1;
}

.hero-sub {
  max-width: 34rem;
  margin: 1.5rem auto 0;
  font-size: clamp(1.125rem, 2.2vw, 1.3125rem);
  line-height: 1.5;
  color: var(--color-ink-muted);
}

.hero-actions {
  margin-top: 2.25rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.875rem;
}

.hero-signin {
  font-size: 0.9375rem;
  color: var(--color-ink-faint);
}

.hero-figure {
  margin: clamp(3rem, 8vw, 5rem) 0 0;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--color-border);
  background: #f4eee3;
  box-shadow: var(--shadow-lg);
}

.hero-figure img {
  width: 100%;
  aspect-ratio: 2048 / 880;
  object-fit: cover;
}

/* Three short facts under the hero buttons. Plain text with a terracotta
   dot, not badges: they are claims to read, not controls. */
.hero-points {
  list-style: none;
  margin: 2.25rem auto 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.625rem 1.75rem;
  max-width: 62rem;
  font-size: 0.9375rem;
  color: var(--color-ink-muted);
}

.hero-points li {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.hero-points li::before {
  content: '';
  width: 0.4rem;
  height: 0.4rem;
  border-radius: 50%;
  background: var(--color-accent);
  flex: none;
}

/* Stacked on a phone, the three lines read better as one left-aligned
   column than as three centred lines of different widths. */
@media (max-width: 40rem) {
  .hero-points {
    flex-direction: column;
    align-items: flex-start;
    width: fit-content;
    text-align: left;
  }
  .hero-points li {
    align-items: flex-start;
  }
  .hero-points li::before {
    margin-top: 0.6rem;
  }
}

/* ---------- Sections ---------- */

.section {
  padding: clamp(4.5rem, 11vw, 8rem) 0 0;
}

.section-head {
  display: grid;
  gap: 0.75rem;
  margin-bottom: clamp(2rem, 5vw, 3rem);
}

.section-head h2 {
  font-size: clamp(2rem, 4.5vw, 2.75rem);
}

/* Why I built this: an editorial two-column, label left, story right. */
.story {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.25rem;
}

.story-text {
  font-family: var(--font-display);
  font-size: clamp(1.375rem, 2.6vw, 1.75rem);
  line-height: 1.45;
  font-weight: 400;
  letter-spacing: -0.005em;
  max-width: 44rem;
}

.story-text em {
  font-style: italic;
  color: var(--color-accent);
}

@media (min-width: 52rem) {
  .story {
    grid-template-columns: 14rem minmax(0, 1fr);
    gap: 3rem;
  }
  .story .eyebrow {
    padding-top: 0.6rem;
  }
}

/* Who it's for: shares the story's label-left layout. */
.audience-text {
  font-family: var(--font-display);
  font-size: clamp(1.375rem, 2.6vw, 1.75rem);
  line-height: 1.4;
  max-width: 40rem;
}

.audience-goals {
  list-style: none;
  margin: 1.5rem 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0.75rem;
}

.audience-goals li {
  padding: 1rem 1.25rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-surface);
  color: var(--color-ink-muted);
}

.audience-goals strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.1875rem;
  font-weight: 600;
  color: var(--color-ink);
}

@media (min-width: 40rem) {
  .audience-goals {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* What it does: numbered groups of feature cards. */
.feature-group + .feature-group {
  margin-top: clamp(2.75rem, 7vw, 4.5rem);
}

.feature-group-head {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.feature-group-head h3 {
  font-size: clamp(1.5rem, 3vw, 1.875rem);
}

.features {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1rem;
}

/* Shipped features read as an editorial list under hairlines, like the steps
   and rules below, so the boxed cards are left to the unbuilt ones. */
.feature {
  border-top: 1px solid var(--color-border);
  padding-top: 1.125rem;
}

.feature h4 {
  font-size: 1.25rem;
  line-height: 1.25;
}

.feature p {
  margin-top: 0.5rem;
  color: var(--color-ink-muted);
  font-size: 0.96875rem;
}

/* Not built yet: quieter card, dashed border, and a tag that says so in
   words, so the colour is never the only signal. */
.feature-soon {
  border: 1px dashed var(--color-border-strong);
  border-radius: var(--radius-md);
  padding: 1.25rem 1.5rem 1.375rem;
}

.tag-soon {
  display: inline-block;
  margin-bottom: 0.75rem;
  padding: 0.15rem 0.6rem;
  border: 1px solid var(--color-accent);
  border-radius: var(--radius-pill);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-accent);
}

@media (min-width: 46rem) {
  .features {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 2rem 2.5rem;
  }
}

/* Wide screens: the group's number and title hold a left column while you
   read its features on the right. */
@media (min-width: 62rem) {
  .feature-group {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 2.6fr);
    column-gap: 3rem;
    align-items: start;
  }
  .feature-group-head {
    position: sticky;
    top: 5.5rem;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 0;
    padding-top: 1.125rem;
    border-top: 1px solid var(--color-border-strong);
  }
  .feature-group .shot-inline {
    grid-column: 1 / -1;
  }
}

/* How it works: numbered rows, heading left, text right. */
.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--color-border);
}

.step {
  display: grid;
  grid-template-columns: 3rem minmax(0, 1fr);
  column-gap: 1rem;
  row-gap: 0.5rem;
  padding: 1.75rem 0;
  border-bottom: 1px solid var(--color-border);
}

.step-num {
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 500;
  color: var(--color-accent);
  font-variant-numeric: tabular-nums;
  padding-top: 0.2rem;
}

.step h3 {
  font-size: clamp(1.3125rem, 2.4vw, 1.5rem);
}

.step p {
  grid-column: 2;
  color: var(--color-ink-muted);
  max-width: var(--text-max);
}

@media (min-width: 52rem) {
  .step {
    grid-template-columns: 4rem minmax(0, 1fr) minmax(0, 1.35fr);
    column-gap: 2rem;
    padding: 2.25rem 0;
  }
  .step p {
    grid-column: 3;
    grid-row: 1;
  }
}

/* The real product, in a quiet browser frame. */
.shot {
  margin: clamp(2.5rem, 6vw, 4rem) auto 0;
  max-width: 56rem;
}

/* A screenshot sitting inside a feature group, below its cards. */
.shot-inline {
  margin-top: clamp(1.75rem, 4vw, 2.5rem);
}

.shot-frame {
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
  background: var(--color-surface);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.shot-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 2.5rem;
  border-bottom: 1px solid var(--color-border);
  background: var(--color-surface-2);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--color-ink-faint);
}

/* The slate capture runs three cards deep. Two say it, so it is cropped
   just under the second card rather than asking for a scroll and a half. */
.shot-crop img {
  aspect-ratio: 1800 / 1514;
  object-fit: cover;
  object-position: top;
}

.shot figcaption {
  margin-top: 1rem;
  text-align: center;
  font-size: 0.9375rem;
  color: var(--color-ink-faint);
}

/* Privacy band. */
.privacy-card {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  background: var(--color-surface);
  padding: clamp(1.75rem, 5vw, 3.5rem);
  box-shadow: var(--shadow-sm);
}

.privacy-card > h2 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  max-width: 32rem;
}

.privacy-lede {
  margin-top: 1rem;
  max-width: var(--text-max);
  color: var(--color-ink-muted);
  font-size: 1.125rem;
}

.promises {
  margin-top: clamp(2rem, 5vw, 3rem);
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.75rem;
}

.promise {
  padding-top: 1.25rem;
  border-top: 1px solid var(--color-border);
}

.promise h3 {
  font-size: 1.1875rem;
  line-height: 1.25;
}

.promise p {
  margin-top: 0.5rem;
  color: var(--color-ink-muted);
  font-size: 0.96875rem;
}

.privacy-more {
  margin-top: 2rem;
  font-size: 0.9375rem;
}

@media (min-width: 52rem) {
  .promises {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 2.5rem;
  }
}

/* Built on a few rules: reuses .promise outside the privacy card. */
.rules {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.75rem;
}

@media (min-width: 40rem) {
  .rules {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 2rem 2.5rem;
  }
}

@media (min-width: 62rem) {
  .rules {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

/* FAQ: native <details>, so it opens with or without JavaScript. */
.faq {
  max-width: 48rem;
  border-top: 1px solid var(--color-border);
}

.faq details {
  border-bottom: 1px solid var(--color-border);
}

.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 0;
  cursor: pointer;
  list-style: none;
  font-family: var(--font-display);
  font-size: 1.1875rem;
  font-weight: 600;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: '+';
  flex: none;
  font-family: var(--font-body);
  font-size: 1.5rem;
  font-weight: 400;
  line-height: 1;
  color: var(--color-accent);
  transition: transform 200ms var(--ease-out-expo);
}

.faq details[open] summary::after {
  transform: rotate(45deg);
}

.faq details p {
  padding: 0 0 1.375rem;
  max-width: var(--text-max);
  color: var(--color-ink-muted);
}

@media (prefers-reduced-motion: reduce) {
  .faq summary::after {
    transition: none;
  }
}

/* How it's built. */
.facts {
  margin: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  border-top: 1px solid var(--color-border);
}

.fact {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0.25rem;
  padding: 1.25rem 0;
  border-bottom: 1px solid var(--color-border);
}

.fact dt {
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  letter-spacing: 0.02em;
  color: var(--color-ink-faint);
  padding-top: 0.2rem;
}

.fact dd {
  margin: 0;
  max-width: var(--text-max);
}

@media (min-width: 52rem) {
  .fact {
    grid-template-columns: 14rem minmax(0, 1fr);
    gap: 3rem;
  }
}

/* Closing. */
.closing {
  padding: clamp(5rem, 12vw, 9rem) 0 clamp(4rem, 10vw, 7rem);
  text-align: center;
}

.closing h2 {
  font-size: clamp(2.25rem, 5.5vw, 3.5rem);
  letter-spacing: -0.025em;
}

.closing p {
  max-width: 32rem;
  margin: 1.25rem auto 0;
  color: var(--color-ink-muted);
  font-size: 1.125rem;
}

.closing-actions {
  margin-top: 2.25rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
}

/* Footer. */
.site-footer {
  border-top: 1px solid var(--color-border);
}

.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 1.75rem;
  padding-bottom: 2.25rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.footer-links a {
  color: var(--color-ink-muted);
  font-size: 0.9375rem;
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--color-ink);
}

/* ---------- Reveal on scroll ----------
 * Progressive: content is visible by default. The inline script adds
 * `.js-reveal` to <html> only when IntersectionObserver exists and the
 * visitor has not asked for reduced motion, so crawlers, no-JS visitors
 * and reduced-motion visitors always see everything at once. */
.js-reveal [data-reveal] {
  opacity: 0;
  transform: translateY(14px);
  transition:
    opacity 700ms var(--ease-out-expo),
    transform 700ms var(--ease-out-expo);
}

.js-reveal [data-reveal].is-visible {
  opacity: 1;
  transform: none;
}
