@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&family=Righteous&display=swap');

:root {
  --ink: #000000;
  --paper: #ffffff;
  --ash: #5a5a5a;
  --rule: #000000;
  --radius: 10px;
  --display: "Righteous", "Poppins", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --body: "Poppins", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  --serif: Georgia, "Songti SC", "Noto Serif SC", serif;
  --gut: clamp(16px, 4vw, 40px);
}

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

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

body {
  margin: 0;
  overflow-x: clip;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.78;
  font-weight: 400;
  letter-spacing: 0.01em;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3, h4 {
  font-family: var(--display);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -0.01em;
  margin: 0 0 0.5em;
}
p { margin: 0 0 1.05em; }

/* ---------- masthead ---------- */
.masthead {
  position: sticky;
  top: 0;
  z-index: 60;
  background: var(--paper);
  border-bottom: 3px solid var(--rule);
}

.masthead__inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto;
  grid-template-areas: "l b r s";
  align-items: center;
  gap: 12px;
  max-width: 1340px;
  margin: 0 auto;
  padding: 10px clamp(10px, 2.4vw, 26px);
}

.pill-nav--left { grid-area: l; justify-self: start; min-width: 0; }
.pill-nav--right { grid-area: r; justify-self: end; min-width: 0; }

.pill-nav__list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 14px;
  border: 2px solid var(--rule);
  border-radius: 999px;
  font-size: 0.82rem;
  line-height: 1;
  letter-spacing: 0.05em;
  text-decoration: none;
  transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease;
}
.pill:hover,
.pill:focus-visible { background: var(--ink); color: var(--paper); transform: translateY(-1px); }

.brand {
  grid-area: b;
  justify-self: center;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 20px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--paper);
  text-decoration: none;
  font-family: var(--display);
  font-size: clamp(1rem, 1.6vw, 1.24rem);
  letter-spacing: 0.08em;
  white-space: nowrap;
}
.brand__mark { height: 22px; width: auto; filter: invert(1); }

.finder {
  grid-area: s;
  display: flex;
  align-items: center;
  border: 2px solid var(--rule);
  border-radius: 999px;
  overflow: hidden;
  background: var(--paper);
}
.finder__input {
  width: 7.5ch;
  min-width: 0;
  min-height: 40px;
  border: 0;
  padding: 0 12px;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 0.86rem;
}
.finder__btn {
  min-height: 40px;
  min-width: 42px;
  border: 0;
  border-left: 2px solid var(--rule);
  background: var(--ink);
  color: var(--paper);
  font: inherit;
  font-size: 0.86rem;
  cursor: pointer;
}

/* ---------- hero ---------- */
.hero {
  position: relative;
  display: grid;
  grid-template-areas: "copy";
  min-height: calc(100svh - 92px);
  padding: clamp(26px, 6vw, 72px) clamp(16px, 5vw, 64px) clamp(46px, 9vw, 96px);
  border-bottom: 3px solid var(--rule);
  background-color: var(--paper);
  background-image: radial-gradient(var(--ink) 1px, transparent 1.4px);
  background-size: 20px 20px;
  overflow: hidden;
}

.hero__plate {
  grid-area: copy;
  position: absolute;
  inset: 0;
  z-index: 0;
  margin: 0;
}
.hero__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.06);
  will-change: transform;
}
.hero__wash {
  position: absolute;
  inset: 0;
  background: linear-gradient(104deg, rgba(255,255,255,0.96) 0%, rgba(255,255,255,0.87) 42%, rgba(255,255,255,0.38) 74%, rgba(255,255,255,0.1) 100%);
}

.hero__copy {
  grid-area: copy;
  position: relative;
  z-index: 1;
  align-self: start;
  max-width: min(100%, 760px);
}
.hero__kicker {
  display: inline-block;
  margin-bottom: 18px;
  padding-bottom: 10px;
  border-bottom: 3px solid var(--rule);
  font-size: 0.72rem;
  letter-spacing: 0.34em;
  text-transform: uppercase;
}
.hero__title {
  margin: 0;
  font-size: clamp(2.4rem, 8.4vw, 6rem);
  line-height: 0.98;
  word-break: break-word;
}

/* ---------- stage / rail / prose ---------- */
.stage {
  display: grid;
  grid-template-columns: minmax(0, 236px) minmax(0, 1fr);
  grid-template-areas: "rail prose";
  gap: clamp(20px, 3.6vw, 52px);
  max-width: 1220px;
  margin: 0 auto;
  padding: clamp(26px, 4.4vw, 64px) var(--gut);
  align-items: start;
}

.rail {
  grid-area: rail;
  align-self: start;
  position: sticky;
  top: 104px;
  padding: 16px 14px 18px;
  border: 2px solid var(--rule);
  border-radius: var(--radius);
  background: var(--paper);
}

.eyebrow {
  display: block;
  margin-bottom: 6px;
  font-size: 0.68rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ash);
}

.rail__title {
  margin: 0 0 14px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--rule);
  font-size: 1.02rem;
}

.rail__list {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: rail;
}
.rail__list li { counter-increment: rail; }
.rail__link {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 40px;
  padding: 6px 4px;
  border-bottom: 1px dashed #cfcfcf;
  font-size: 0.92rem;
  text-decoration: none;
}
.rail__link::before {
  content: counter(rail, decimal-leading-zero);
  min-width: 2ch;
  font-family: var(--display);
  font-size: 0.76rem;
  color: var(--ash);
}
.rail__link:hover,
.rail__link:focus-visible { background: var(--ink); color: var(--paper); }

.prose { grid-area: prose; min-width: 0; }

.prose > section {
  margin: 0 0 clamp(18px, 2.6vw, 30px);
  padding: clamp(18px, 2.6vw, 34px);
  border: 2px solid var(--rule);
  border-radius: var(--radius);
  background: var(--paper);
  scroll-margin-top: 112px;
}
.prose > section:nth-child(even) { margin-left: clamp(0px, 2.4vw, 40px); }
.prose > section:nth-child(3n+1) { margin-right: clamp(0px, 2vw, 34px); }

.prose > section:first-child > p:first-of-type::first-letter {
  float: left;
  padding: 0.08em 0.14em 0 0;
  font-family: var(--display);
  font-size: 3.4em;
  line-height: 0.8;
}

.prose small {
  display: block;
  margin-bottom: 8px;
  font-size: 0.68rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ash);
}

.prose h2 { font-size: clamp(1.4rem, 3.4vw, 2rem); margin: 0 0 0.55em; }
.prose h3 { font-size: clamp(1.12rem, 2.4vw, 1.34rem); margin: 1.5em 0 0.5em; }
.prose p:last-child { margin-bottom: 0; }
.prose ul,
.prose ol { margin: 0 0 1.1em; padding-left: 1.2em; }
.prose li { margin-bottom: 0.4em; }
.prose a { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; }
.prose strong { font-weight: 600; }
.prose hr { margin: 1.8em 0; border: 0; border-top: 2px solid var(--rule); }

.prose figure {
  margin: 1.4em 0;
  border: 2px solid var(--rule);
  border-radius: var(--radius);
  overflow: hidden;
}
.prose figcaption {
  padding: 10px 14px;
  border-top: 2px solid var(--rule);
  font-family: var(--serif);
  font-size: 0.86rem;
  color: var(--ash);
}

.prose blockquote {
  margin: 1.6em 0;
  padding: 0.1em 0 0.1em 1.1em;
  border-left: 6px solid var(--rule);
  font-family: var(--serif);
  font-size: 1.12rem;
  line-height: 1.62;
}
.prose blockquote p:last-child { margin-bottom: 0; }

.prose table { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
.prose th,
.prose td { padding: 8px; border-bottom: 1px solid #cccccc; text-align: left; }

/* ---------- colophon ---------- */
.colophon {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: clamp(18px, 3vw, 44px);
  margin-top: clamp(24px, 4vw, 56px);
  padding: clamp(28px, 5vw, 64px) var(--gut) 0;
  border-top: 3px solid var(--rule);
  background: var(--ink);
  color: var(--paper);
}
.colophon > section {
  padding-top: 16px;
  border-top: 2px solid rgba(255, 255, 255, 0.35);
}
.colophon .eyebrow { color: rgba(255, 255, 255, 0.62); }
.colophon__title { font-size: clamp(1.2rem, 2.4vw, 1.6rem); margin: 0 0 10px; }
.colophon__desc { max-width: 44ch; font-size: 0.92rem; color: rgba(255, 255, 255, 0.78); }
.colophon__form { grid-column: 1 / -1; }

.colophon__base {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: clamp(18px, 3vw, 32px);
  padding: 18px 0;
  border-top: 2px solid rgba(255, 255, 255, 0.35);
}
.colophon__copy { margin: 0; font-size: 0.82rem; letter-spacing: 0.16em; }
.colophon__top {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 16px;
  border: 2px solid rgba(255, 255, 255, 0.6);
  border-radius: 999px;
  font-size: 0.82rem;
  text-decoration: none;
}
.colophon__top:hover,
.colophon__top:focus-visible { background: var(--paper); color: var(--ink); }

.linklist {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 2px 14px;
  margin: 0;
}
.linklist dt {
  padding-top: 10px;
  font-family: var(--display);
  font-size: 0.76rem;
  color: rgba(255, 255, 255, 0.5);
}
.linklist dd { margin: 0; }
.linklist a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 2px 4px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  font-size: 0.94rem;
  text-decoration: none;
}
.linklist a:hover,
.linklist a:focus-visible { background: var(--paper); color: var(--ink); border-radius: 6px; }

.signup { max-width: 440px; }
.signup__label {
  display: block;
  margin-bottom: 6px;
  font-size: 0.74rem;
  letter-spacing: 0.24em;
  color: rgba(255, 255, 255, 0.62);
}
.signup__row { display: flex; gap: 8px; }
.signup__input {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 46px;
  padding: 0 16px;
  border: 2px solid var(--paper);
  border-radius: 999px;
  background: transparent;
  color: var(--paper);
  font: inherit;
  font-size: 0.92rem;
}
.signup__input:focus-visible { outline: 2px solid var(--paper); outline-offset: 2px; }
.signup__btn {
  min-height: 46px;
  padding: 0 22px;
  border: 2px solid var(--paper);
  border-radius: 999px;
  background: var(--paper);
  color: var(--ink);
  font: inherit;
  font-size: 0.9rem;
  cursor: pointer;
}
.signup__btn:hover { background: transparent; color: var(--paper); }

/* ---------- motion ---------- */
.js .reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}
.js .reveal.is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .hero__img { transform: none !important; }
  .pill, .signup__btn, .colophon__top { transition: none; }
}

/* ---------- responsive ---------- */
@media (max-width: 960px) {
  .stage {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "rail" "prose";
  }
  .rail { position: static; }
  .prose > section:nth-child(n) { margin-left: 0; margin-right: 0; }
  .colophon { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 880px) {
  body { font-size: 16.5px; }
  .masthead { position: static; }
  .masthead__inner {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "b" "l" "r" "s";
    justify-items: center;
    gap: 8px;
    padding-bottom: 12px;
  }
  .pill-nav--left,
  .pill-nav--right { justify-self: center; }
  .pill-nav__list { justify-content: center; }
  .hero { min-height: auto; padding-bottom: clamp(52px, 13vw, 96px); }
  .hero__copy { max-width: 100%; }
  .hero__title { font-size: clamp(2.2rem, 10.5vw, 3.5rem); }
  .prose > section { scroll-margin-top: 16px; }
  .colophon__base { flex-direction: column; }
}

button[aria-expanded]{min-width:44px;min-height:44px}
