/* Newsreader, SIL Open Font License. See assets/fonts/OFL.txt.
   Almanac tokens: design system v1.1. Body text stays a system sans. */

@font-face {
  font-family: "Newsreader";
  src: url("assets/fonts/newsreader.woff2") format("woff2");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Newsreader";
  src: url("assets/fonts/newsreader-italic.woff2") format("woff2");
  font-weight: 400 700;
  font-style: italic;
  font-display: swap;
}

:root {
  color-scheme: light;
  --paper: #fbf8f2;
  --grouped: #f3eee4;
  --surface: #ffffff;
  --sheet: #f6f1e7;
  --fill: #efe9dd;
  --fill-strong: #e7e0d2;
  --separator: #e4ddd0;
  --label: #1d1b18;
  --secondary: #6b655c;
  --tertiary: #8f887d;
  --accent: #a3312a;
  --on-accent: #ffffff;
  --accent-text: #a3312a;
  --accent-tint: #f7e6e2;
  --accent-pressed: #8a2822;
  --gold: #8a6a1f;
  --silver: #6e747a;
  --bronze: #9c5a2e;
  --medal-ink: #fbf8f2;
  --success: #2f6b4f;
  --destructive: #b3261e;
  --band: #f3eee4;
  --shadow: 0 22px 50px rgba(29, 27, 24, 0.14);
  --serif: "Newsreader", "Iowan Old Style", Palatino, "Palatino Linotype", Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", system-ui, sans-serif;
  --wrap: 1120px;
  --header: 68px;
}

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --paper: #15130f;
    --grouped: #15130f;
    --surface: #221f1a;
    --sheet: #26221c;
    --fill: #2c2822;
    --fill-strong: #38332b;
    --separator: #3a352d;
    --label: #f3eee4;
    --secondary: #a9a195;
    --tertiary: #7f786d;
    --accent: #f08a78;
    --on-accent: #2a0d08;
    --accent-text: #f08a78;
    --accent-tint: #3a1f1a;
    --accent-pressed: #e07462;
    --gold: #d9b25e;
    --silver: #b8bec4;
    --bronze: #d9905e;
    --medal-ink: #15130f;
    --success: #7fc2a0;
    --destructive: #ff8a80;
    --band: #221f1a;
    --shadow: 0 22px 50px rgba(0, 0, 0, 0.4);
  }
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--label);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.5;
  text-rendering: optimizeLegibility;
}

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

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

:focus-visible {
  outline: 2px solid var(--accent-text);
  outline-offset: 3px;
}

::selection {
  background: var(--accent-tint);
  color: var(--label);
}

.skip {
  position: absolute;
  left: 16px;
  top: -48px;
  z-index: 20;
  background: var(--accent);
  color: var(--on-accent);
  padding: 10px 14px;
  border-radius: 10px;
  text-decoration: none;
  font-weight: 600;
}

.skip:focus { top: 12px; }

.wrap {
  width: min(var(--wrap), calc(100% - 32px));
  margin-inline: auto;
}

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

@media (prefers-reduced-transparency: reduce) {
  .site-header {
    background: var(--paper);
    backdrop-filter: none;
  }
}

.header-bar {
  display: flex;
  align-items: center;
  gap: 20px;
  min-height: var(--header);
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  color: var(--label);
  text-decoration: none;
  border-radius: 10px;
}

.logo-mark { display: block; flex: none; }
.logo-tile { fill: var(--accent); }
.logo-ink { fill: var(--on-accent); }

.logo-word {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.4rem;
  line-height: 1;
  letter-spacing: -0.02em;
}

.nav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

.nav a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 12px;
  border-radius: 10px;
  color: var(--secondary);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 600;
  white-space: nowrap;
  transition: color 0.15s ease, background-color 0.15s ease;
}

.nav a:hover {
  color: var(--label);
  background: var(--fill);
}

/* Buttons. One shape for every style: same height, radius, padding, weight.
   primary = filled accent, secondary = tonal with a hairline, ghost = text only. */
.button {
  --btn-h: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: var(--btn-h);
  padding: 0 22px;
  border: 0;
  border-radius: 12px;
  background: var(--accent);
  color: var(--on-accent);
  box-shadow: none;
  font: 600 1rem/1.1 var(--sans);
  letter-spacing: -0.005em;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  -webkit-tap-highlight-color: transparent;
  transition: background-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease, transform 0.1s ease;
}

.button:hover { background: var(--accent-pressed); color: var(--on-accent); }
.button:active { transform: translateY(1px); }

.button:focus-visible {
  outline: 2px solid var(--accent-text);
  outline-offset: 3px;
}

.button.secondary {
  background: var(--fill);
  color: var(--label);
  box-shadow: inset 0 0 0 1px var(--separator);
}

.button.secondary:hover {
  background: var(--fill-strong);
  color: var(--label);
}

.button.ghost {
  background: transparent;
  color: var(--accent-text);
  padding-inline: 14px;
}

.button.ghost:hover {
  background: var(--accent-tint);
  color: var(--accent-text);
}

.button-sm {
  --btn-h: 40px;
  padding: 0 16px;
  border-radius: 10px;
  font-size: 0.92rem;
}

.header-join { margin-left: 8px; }

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(240px, 0.85fr);
  gap: 40px 48px;
  align-items: center;
  padding: 56px 0 24px;
}

.overline {
  margin: 0 0 12px;
  font-size: 0.72rem;
  font-weight: 650;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-text);
}

h1,
h2,
.deck,
.share-card h3 {
  font-family: var(--serif);
  font-weight: 560;
  letter-spacing: -0.03em;
  font-optical-sizing: auto;
}

h1 {
  margin: 0;
  font-size: clamp(3.4rem, 8vw, 5.6rem);
  line-height: 0.94;
}

.deck {
  margin: 16px 0 0;
  font-style: italic;
  font-weight: 500;
  font-size: clamp(1.35rem, 2.5vw, 1.85rem);
  line-height: 1.25;
  color: var(--secondary);
}

.lead {
  margin: 18px 0 0;
  max-width: 40rem;
  color: var(--label);
  font-size: 1.08rem;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 28px;
}

@media (max-width: 520px) {
  .actions { display: grid; grid-template-columns: 1fr; gap: 10px; }
  .actions .button { width: 100%; }
  .form-row .button { flex: 1 1 100%; }
}

.aside-note {
  margin: 14px 0 0;
  color: var(--secondary);
  font-size: 0.92rem;
}

section { padding: 72px 0; }

section h2 {
  margin: 0 0 12px;
  font-size: clamp(2rem, 4vw, 2.75rem);
  line-height: 1.05;
}

.section-copy {
  margin: 0;
  max-width: 40rem;
  color: var(--secondary);
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 28px;
}

.step {
  background: var(--surface);
  border-radius: 16px;
  padding: 20px 20px 22px;
  box-shadow: inset 0 0 0 1px var(--separator);
}

.step-num {
  display: block;
  font-family: var(--serif);
  font-weight: 560;
  font-size: 1.8rem;
  letter-spacing: -0.03em;
  color: var(--accent-text);
}

.step h3 {
  margin: 4px 0 8px;
  font-size: 1.05rem;
  font-family: var(--sans);
  letter-spacing: 0;
}

.step p {
  margin: 0;
  color: var(--secondary);
  font-size: 0.98rem;
}

.phone-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: flex-start;
  gap: 28px 36px;
  margin-top: 40px;
}

.shot { margin: 0; }

.phone-row .shot { width: min(280px, 100%); }
.phone-row .phone { width: 100%; }

.shot figcaption {
  margin: 12px auto 0;
  max-width: 28ch;
  text-align: center;
  color: var(--secondary);
  font-size: 0.82rem;
  line-height: 1.35;
}

.phone {
  width: min(260px, 100%);
  padding: 8px;
  border-radius: 36px;
  background: #1c1a17;
  box-shadow: 0 0 0 1px #3a342c, var(--shadow);
}

.phone img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 28px;
  background: #fbf8f2;
}

.hero-visual { display: flex; justify-content: center; }

.band {
  background: var(--band);
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 320px);
  gap: 40px 56px;
  align-items: center;
}

.split.reverse { grid-template-columns: minmax(240px, 320px) minmax(0, 1fr); }

.split .phone { margin-inline: auto; }

.crumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 0;
  margin: 22px 0 0;
  padding: 0;
  list-style: none;
}

.crumbs li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.crumbs li + li::before {
  content: "›";
  color: var(--tertiary);
  font-weight: 500;
}

.crumbs li.no-sep { margin-left: 8px; }
.crumbs li.no-sep::before { content: none; }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  background: var(--fill);
  color: var(--label);
  font-size: 0.95rem;
  font-weight: 650;
}

.chip.is-current {
  background: var(--accent);
  color: var(--on-accent);
}

.chip.is-ghost {
  background: transparent;
  color: var(--secondary);
  box-shadow: inset 0 0 0 1.5px var(--tertiary);
}

.chip svg { display: block; }

.share-layout {
  display: grid;
  grid-template-columns: 240px minmax(0, 420px);
  gap: 28px 40px;
  align-items: start;
  justify-content: center;
  margin-top: 36px;
}

.format-label {
  margin: 0 0 10px;
  font-size: 0.72rem;
  font-weight: 650;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-text);
}

.story-frame img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 22px;
  box-shadow: var(--shadow);
  background: #fbf8f2;
}

/* Share cards stay on paper in both appearances. That is the default card. */
.share-card {
  background: #fbf8f2;
  color: #1d1b18;
  border: 1px solid #e4ddd0;
  border-radius: 22px;
  padding: 22px 22px 18px;
  box-shadow: var(--shadow);
}

.share-brand {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  color: #a3312a;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
}

.share-card h3 {
  margin: 14px 0 0;
  font-size: 2.5rem;
  line-height: 0.95;
  color: #1d1b18;
}

.share-sub {
  margin: 8px 0 16px;
  font-family: var(--serif);
  font-style: italic;
  font-weight: 500;
  font-size: 1.25rem;
  color: #6b655c;
}

.share-card ol {
  list-style: none;
  margin: 0;
  padding: 0;
}

.share-card li {
  display: grid;
  grid-template-columns: 36px 1fr;
  gap: 12px;
  align-items: center;
  min-height: 48px;
  border-top: 1px solid #e4ddd0;
  font-weight: 650;
}

.rank {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.15rem;
  font-variant-numeric: lining-nums;
}

.rank.medal {
  border-radius: 8px;
  color: #fbf8f2;
}

.rank.gold { background: #8a6a1f; }
.rank.silver { background: #6e747a; }
.rank.bronze { background: #9c5a2e; }

.rank.plain {
  color: #6b655c;
  font-size: 1.35rem;
}

.share-more,
.share-foot {
  color: #6b655c;
  font-size: 0.85rem;
}

.share-more { margin: 12px 0 18px; }

.share-foot {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin: 0;
  padding-top: 12px;
  border-top: 1px solid #e4ddd0;
}

.share-foot strong {
  color: #1d1b18;
  font-size: 0.95rem;
}

.waitlist {
  padding-bottom: 88px;
}

.waitlist-card {
  max-width: 40rem;
  margin-top: 8px;
  padding: 24px;
  border-radius: 22px;
  background: var(--sheet);
  box-shadow: inset 0 0 0 1px var(--separator);
}

.field-label {
  display: block;
  margin-bottom: 8px;
  font-size: 0.82rem;
  font-weight: 650;
}

.form-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

input[type="email"] {
  flex: 1 1 220px;
  min-width: 0;
  min-height: 48px;
  padding: 0 14px;
  border: 0;
  border-radius: 12px;
  background: var(--fill);
  color: var(--label);
  font: inherit;
}

input::placeholder { color: var(--tertiary); }

.button:disabled,
.button[aria-disabled="true"] {
  background: var(--fill);
  color: var(--tertiary);
  box-shadow: inset 0 0 0 1px var(--separator);
  cursor: default;
  transform: none;
}

.form-status {
  min-height: 1.5em;
  margin: 12px 0 0;
  font-size: 0.98rem;
}

.form-status.is-ok { color: var(--success); }
.form-status.is-err { color: var(--destructive); }

.fine {
  margin: 10px 0 0;
  color: var(--secondary);
  font-size: 0.88rem;
}

.fine a { color: var(--accent-text); }

.hp {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.site-footer {
  border-top: 1px solid var(--separator);
  padding: 28px 0 48px;
  color: var(--secondary);
  font-size: 0.92rem;
}

.footer-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  align-items: baseline;
  justify-content: space-between;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
}

.footer-links a { color: var(--accent-text); font-weight: 600; }

.footer-links a[aria-current="page"] { text-decoration: none; color: var(--label); }

.legal {
  padding: 40px 0 72px;
}

.prose { max-width: 42rem; }

.prose h1 {
  font-size: clamp(2.6rem, 6vw, 3.8rem);
  line-height: 0.98;
}

.prose h2 {
  margin: 2rem 0 0.4rem;
  font-family: var(--serif);
  font-weight: 560;
  font-size: 1.55rem;
  letter-spacing: -0.02em;
}

.prose p,
.prose li { color: var(--label); }

.prose ul { padding-left: 1.2rem; }

.prose a { color: var(--accent-text); }

.updated {
  margin-top: 8px;
  color: var(--secondary);
  font-size: 0.92rem;
}

.draft {
  margin: 20px 0;
  padding: 12px 16px;
  border-radius: 12px;
  background: var(--accent-tint);
  color: var(--label);
}

.draft strong { color: var(--accent-text); }

:target { scroll-margin-top: calc(var(--header) + 12px); }

@media (max-width: 860px) {
  .hero,
  .split,
  .split.reverse,
  .steps,
  .share-layout {
    grid-template-columns: 1fr;
  }

  .header-bar { flex-wrap: wrap; gap: 4px 12px; padding: 10px 0 6px; }
  .logo { order: 1; }
  .header-join { order: 2; margin-left: auto; }
  .nav {
    order: 3;
    width: calc(100% + 24px);
    margin: 0 -12px;
    flex-wrap: nowrap;
    gap: 0;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .nav::-webkit-scrollbar { display: none; }

  .hero { padding-top: 32px; }
  .hero-visual { justify-content: flex-start; }
  section { padding: 56px 0; }
}

@media print {
  .site-header,
  .skip,
  .actions,
  .waitlist-card { display: none; }
  body { background: #fff; color: #000; }
  a { color: #000; }
}
