/* recalibrate — waitlist + privacy
   Phone first; the two-column desktop layout takes over at 900px.
   The reference mockups are absolutely positioned; this is the responsive
   rebuild of the same composition. */

:root {
  --teal:            #12232A;  /* page background */
  --clay:            #D8A278;  /* button, wordmark, handwriting, first note line */
  --parchment:       #E6DAC4;  /* headline, input text, privacy intro */
  --parchment-soft:  #B5AD9F;  /* body text */
  --small-print:     #8F948C;  /* note under button, footer — lightest allowed */
  --placeholder:     #7E8783;
  --field-border:    #56625F;
  --divider:         #2A3B40;
  --sage:            #9DAA8E;  /* privacy section labels */
}

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

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

body {
  margin: 0;
  background: var(--teal);
  color: var(--parchment);
  font-family: 'Figtree', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}

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

/* Square corners everywhere — no pills, shadows, gradients or icons. */
input, button { border-radius: 0; font-family: inherit; }

a { color: var(--parchment-soft); text-decoration: underline; text-underline-offset: 2px; }
a:focus-visible, input:focus-visible, button:focus-visible {
  outline: 2px solid var(--clay);
  outline-offset: 2px;
}

/* Visually hidden but still read aloud — every field keeps a real label. */
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- shell ---------- */

.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  padding: 16px 20px 0;
}

.masthead { flex: 0 0 auto; }

.wordmark {
  display: inline-block;
  font-weight: 700;
  font-size: 22px;
  letter-spacing: -0.3px;
  color: var(--clay);
  text-decoration: none;
}

.tagline-mark { width: 71px; margin: 3px 0 0 16px; }

.main {
  flex: 1 0 auto;
  display: flex;
  flex-direction: column;
  width: 100%;
  /* Keeps the single-column layout readable on tablets, between the phone
     design and the two-column breakpoint. */
  max-width: 560px;
  margin: 0 auto;
  padding: 0 25px;
}

/* ---------- hero ---------- */

.hero { margin-top: 72px; text-align: center; }

.headline {
  margin: 0;
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-weight: 700;
  /* Must stay on one line. Measured from the font: the headline is 8.27em
     wide at weight 700, so 33px needs 273px — more than a 360px phone has
     after padding. Scales down on narrow screens, caps at the design's 33px
     from about 375px up. nowrap guarantees it regardless. */
  font-size: clamp(20px, calc(11.1vw - 10px), 33px);
  white-space: nowrap;
  line-height: 1.18;
  color: var(--parchment);
}

/* Tucks just under the headline, as in the reference. */
.grow-mark { width: 209px; margin: -4px auto 0; }

/* ---------- note + signature ---------- */

.note { margin-top: 60px; }

.note-lead {
  margin: 0;
  font-size: 14px;
  line-height: 1.6;
  color: var(--clay);
}

.note-body {
  margin: 8px 0 0;
  font-size: 12.5px;
  line-height: 1.45;
  color: var(--parchment-soft);
}

.signature {
  display: flex;
  /* Tops aligned, then the dash is pushed down a measured amount.
     Box-based alignment (centre or bottom) does not work here: the name PNG
     is 194x114 but the letterforms only occupy rows 24-47 — the lower half is
     the long descender on the "f". Centring on the box puts the dash beside
     that tail instead of beside the letters. */
  align-items: flex-start;
  justify-content: flex-end;
  gap: 5px;
  margin-top: 18px;
  padding-right: 20px;
}
.signature-dash {
  width: 13px;
  /* Sits the dash level with the upper body of the letters, chosen by
     rendering the two PNGs together at several offsets rather than by
     formula — box-based alignment cannot work here, see above.
     Larger number moves the dash down. */
  margin-top: 6px;
}
.signature-name { width: 54px; }

/* ---------- form ---------- */

.signup { margin-top: 72px; }

.signup-intro {
  margin: 0 0 12px;
  text-align: center;
  font-size: 10.5px;
  line-height: 1.25;
  color: var(--parchment-soft);
}

.field + .field { margin-top: 8px; }

.field input {
  width: 100%;
  background: transparent;
  border: 1px solid var(--field-border);
  padding: 10px 12px;
  font-size: 14px;
  color: var(--parchment);
}
.field input::placeholder { color: var(--placeholder); opacity: 1; }
.field input:focus { outline: none; border-color: var(--clay); }

.submit {
  width: 100%;
  height: 48px;
  margin-top: 12px;
  background: var(--clay);
  color: var(--teal);
  border: none;
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 2.6px;
  text-transform: uppercase;
  cursor: pointer;
}
.submit[disabled] { opacity: 0.55; cursor: default; }

/* Inline response sits under the button, in the same style as the note. */
.form-message {
  /* Height is reserved so the message appearing doesn't shove the page down.
     Kept tight, because this space is visible even when empty. */
  margin: 6px 0 0;
  min-height: 1.25em;
  text-align: center;
  font-size: 10.5px;
  line-height: 1.4;
  color: var(--parchment-soft);
}
.form-message[data-state='error'] { color: var(--clay); }

.signup-note {
  margin: 2px 0 0;
  text-align: center;
  font-size: 9.5px;
  line-height: 1.35;
  color: var(--small-print);
}

/* ---------- footer ---------- */

.site-footer {
  flex: 0 0 auto;
  margin-top: 72px;
  padding: 0 4px;
}
.site-footer hr {
  margin: 0;
  border: 0;
  border-top: 1px solid var(--divider);
}
.site-footer p {
  margin: 0;
  padding: 16px 0 28px;
  text-align: center;
  font-size: 11px;
  line-height: 1.4;
  letter-spacing: 0.2px;
  color: var(--small-print);
}

/* ---------- privacy ---------- */

.prose { max-width: 640px; margin: 0 auto; width: 100%; }

.prose h1 {
  margin: 72px 0 0;
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-weight: 300;
  font-size: 33px;
  line-height: 1.18;
  color: var(--parchment);
}
.prose .intro {
  margin: 14px 0 0;
  font-size: 14px;
  line-height: 1.6;
  color: var(--parchment);
}
.prose h2 {
  margin: 30px 0 0;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 2.2px;
  text-transform: uppercase;
  color: var(--sage);
}
.prose h2:first-of-type { margin-top: 36px; }
.prose p {
  margin: 10px 0 0;
  font-size: 13px;
  line-height: 1.65;
  color: var(--parchment-soft);
}
.prose .updated { margin-top: 22px; font-size: 11px; color: var(--small-print); }
.prose a { color: var(--parchment); }

/* Confirmation page. Short enough that top-aligning strands it above a lot
   of empty space, so the block is centred in the viewport instead. */
.main--centred { justify-content: center; }
.main--centred .confirm h1 { margin-top: 0; }

.confirm h1 { margin-top: 96px; font-weight: 700; }
.confirm p { font-size: 14px; }
.confirm .intro { color: var(--clay); }
.confirm .signature {
  justify-content: flex-start;
  padding: 0;
  margin-top: 36px;
}

/* The brand name is clay wherever surrounding text is another colour. */
.brand { color: var(--clay); }

/* ---------- desktop ---------- */

/* 1024px, not 900px: at 900 the two-column grid leaves the left column just
   188px, which is too narrow for the headline at any size. */
@media (min-width: 1024px) {
  .page { padding: 40px 64px 0; }

  .wordmark { font-size: 26px; }
  .tagline-mark { width: 88px; margin-left: 18px; }

  .main {
    display: grid;
    max-width: 1312px;
    grid-template-columns: minmax(0, 1fr) 440px;
    column-gap: 80px;
    align-items: start;
    max-width: 1312px;
    width: 100%;
    margin: 0 auto;      /* stay centred in wide windows rather than stretch */
    padding: 0 96px;
  }

  .hero { margin-top: 160px; text-align: left; }
  /* Same constraint: at 58px the headline is 480px wide, but the left grid
     column is only 388px at a 1100px viewport. */
  .headline { font-size: clamp(30px, 3.6vw, 58px); line-height: 1.12; }
  .grow-mark { width: 340px; margin: -10px 0 0 30px; }

  .note { margin-top: 56px; max-width: 460px; }
  .note-lead { font-size: 18px; }
  .note-body { margin-top: 10px; font-size: 15px; line-height: 1.65; }

  .signature {
    /* Anchored to the right of the note block, not indented from the left.
       A fixed padding-left of 272px (taken from the 1440px mockup) needed
       376px of column, but between 900px and ~1090px viewport the left
       column is only 188-288px wide — so the signature overflowed and the
       dash broke away from the name. Right-anchoring reproduces the
       reference position at full width and degrades instead of breaking.
       76px is the reference gap from the note's right edge. */
    justify-content: flex-end;
    gap: 6px;                 /* matches the reference: dash ends 6px before the name */
    margin-top: 10px;
    padding: 0 76px 0 0;
  }
  .signature-dash {
    width: 18px;
    /* Same position, scaled: the name renders 47px tall here vs 31.7px. */
    margin-top: 9px;
  }
  .signature-name { width: 80px; }

  /* Form sits in the right column, aligned with the headline. */
  .signup { grid-column: 2; grid-row: 1 / span 3; margin-top: 226px; }
  .signup-intro { font-size: 14px; line-height: 1.4; margin-bottom: 16px; }
  .field input { padding: 14px 16px; font-size: 15px; }
  .field + .field { margin-top: 14px; }
  .submit { height: 54px; margin-top: 20px; font-size: 13px; letter-spacing: 3px; }
  .form-message { font-size: 12px; }
  .signup-note { font-size: 11px; margin-top: 3px; }

  .site-footer { margin-top: 120px; }
  .site-footer p { font-size: 12px; padding-top: 20px; }

  .prose h1 { font-size: 44px; }
  .confirm h1 { margin-top: 120px; }
  .main--centred .confirm h1 { margin-top: 0; }
  .confirm p { font-size: 15px; }
  .confirm .signature { justify-content: flex-start; padding: 0; margin-top: 44px; }
  .prose .intro { font-size: 15px; }
  .prose p { font-size: 14px; }
}

/* Honour a reduced-motion preference — nothing here animates, but the
   button's opacity change is the one transition a user might notice. */
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}
