/*
 * doorsuper.com (#101): the homepage, the privacy policy and the SMS terms. Built on the
 * Owner Screen's tokens (tokens.css), so the site and the app are one look: Figtree, harbor
 * blue, the off-white page. Same-origin only, like everything under the strict policy.
 */

.site {
  --page-x: clamp(16px, 4.5vw, 64px);
  --page-max: 1440px;
  --head-h: 72px;
  --field: light-dark(#1f5a96, #13304d);
  --on-field: light-dark(#ffffff, #e9ebee);
  --on-field-muted: light-dark(#d4e3f3, #b5c8dc);
  --pick: light-dark(rgb(255 255 255 / 0.14), rgb(255 255 255 / 0.08));
  --ease-out: cubic-bezier(0.2, 0.7, 0.2, 1);
  margin: 0;
  background: var(--color-bg);
  color: var(--color-ink);
  font-family: var(--font-ui);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
.site *, .site *::before, .site *::after { box-sizing: border-box; }
.site :where(h1, h2, h3, p, ul, figure) { margin: 0; }
.site img { display: block; max-width: 100%; height: auto; }
.site a { color: var(--color-link); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
.site :focus-visible { outline: var(--focus-width, 3px) solid var(--color-focus); outline-offset: 3px; border-radius: 4px; }
.site main:focus { outline: none; }
.site-skip { position: absolute; left: -999px; top: 8px; z-index: 30; padding: 10px 16px; background: var(--color-surface); color: var(--color-ink); border-radius: 10px; }
.site-skip:focus { left: 8px; }

/* The frame: one pair of equal outer margins at every width. */
.stage, .who, .faq, .site-foot, .doc { width: min(var(--page-max), 100% - 2 * var(--page-x)); margin-inline: auto; }
.site-head, .try, .join { padding-inline: max(var(--page-x), (100% - var(--page-max)) / 2); }

/* Header */
.site-head { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 24px; height: var(--head-h); background: var(--color-bg); }
.site-mark, .site a.site-mark { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; color: var(--color-ink); text-decoration: none; font-weight: 700; font-size: 22px; letter-spacing: -0.01em; }
.site-glyph { width: 26px; height: 26px; flex: none; color: var(--color-primary); fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.site-glyph .is-fill { fill: currentColor; stroke: none; }
.site-nav { display: flex; align-items: center; gap: clamp(16px, 2.2vw, 32px); white-space: nowrap; }
.site-nav a:not(.site-btn) { color: var(--color-ink); text-decoration: none; font-weight: 500; font-size: 17px; }
.site-nav a:not(.site-btn):hover { color: var(--color-link); }

.site-btn, .site a.site-btn { display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: 0 26px; border: 0; border-radius: 12px; background: var(--color-primary); color: var(--color-on-primary); font: 600 17px/1 var(--font-ui); text-decoration: none; cursor: pointer; transition: background var(--motion-fast, 120ms) ease, transform var(--motion-fast, 120ms) ease; }
.site-btn:hover { background: var(--color-primary-hover); }
.site-btn:active { transform: translateY(1px); }
.site-btn.is-small, .site a.site-btn.is-small { min-height: 42px; padding: 0 18px; font-size: 15px; }
.site-btn[disabled] { opacity: 0.6; cursor: progress; }
.site-link { font-weight: 600; }

/* The split stage: what DoorSuper does on the left, its own screen held on the right. */
.stage { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); column-gap: clamp(40px, 5vw, 96px); }
.beat { display: flex; flex-direction: column; justify-content: center; gap: 24px; min-height: calc(100svh - var(--head-h)); padding-block: 72px; }
.beat.is-hero { padding-block: 24px 72px; }
.beat-title { font-size: clamp(34px, 3.3vw, 52px); line-height: 1.06; letter-spacing: -0.022em; font-weight: 700; text-wrap: balance; }
.beat-lede { font-size: 21px; line-height: 1.45; max-width: 34em; }
.beat-points { display: grid; gap: 14px; padding: 0; list-style: none; max-width: 34em; }
.beat-points li { position: relative; padding-left: 28px; }
.beat-points li::before { content: ""; position: absolute; left: 0; top: 0.42em; width: 12px; height: 15px; border: 2px solid var(--color-primary); border-bottom-width: 3px; border-radius: 3px 3px 0 0; }
.beat-shot { display: none; }
.beat-shot picture, .stage-shot picture { display: block; padding: clamp(8px, 0.9vw, 14px); border-radius: 20px; background: var(--color-sunk); }
.beat-shot img, .stage-shot img { border-radius: 12px; }
.beat-shot figcaption, .stage-caption { margin-top: 12px; color: var(--color-muted); font-size: 15px; }

.hero-card { display: grid; gap: 28px; padding: clamp(24px, 2.8vw, 44px); border-radius: 22px; background: var(--color-surface); }
.hero-doors { display: flex; align-items: end; gap: 7px; height: 64px; }
.hero-doors i { flex: 1; height: 100%; border-radius: 7px 7px 0 0; background: var(--color-primary); transform-origin: bottom; }
.hero-doors i:nth-child(3n) { height: 82%; }
.hero-doors i:nth-child(4n+2) { height: 91%; }
.hero-doors i.is-owed { background: var(--color-owed); }
.hero-doors i.is-open { background: transparent; outline: 2.5px solid var(--color-primary); outline-offset: -2.5px; }
.hero-title { font-size: clamp(40px, 4.3vw, 62px); line-height: 1.02; letter-spacing: -0.032em; font-weight: 700; text-wrap: balance; }
.hero-lede { font-size: 21px; line-height: 1.45; max-width: 30em; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 28px; }

.stage-screen { position: sticky; top: calc(var(--head-h) + 24px); align-self: start; height: calc(100svh - var(--head-h) - 48px); display: flex; flex-direction: column; justify-content: center; }
.stage-frame { display: grid; }
.stage-shot { grid-area: 1 / 1; align-self: center; opacity: 0; transition: opacity 900ms ease, transform 900ms var(--ease-out); transform: translateY(12px); }
.stage-shot.is-on { opacity: 1; transform: none; }
.stage-shot img { width: 100%; max-height: calc(100svh - var(--head-h) - 110px); object-fit: contain; object-position: top left; }

/* Try a text: the one break in the split, a whole field of the harbor blue. */
.try { display: grid; gap: 48px; padding-block: clamp(72px, 9vw, 128px); background: var(--field); color: var(--on-field); }
.try-head { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); column-gap: clamp(40px, 5vw, 96px); align-items: end; }
.try-title { font-size: clamp(34px, 3.3vw, 52px); line-height: 1.06; letter-spacing: -0.022em; font-weight: 700; text-wrap: balance; }
.try-lede { font-size: 21px; color: var(--on-field-muted); max-width: 30em; }
.try-body { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); column-gap: clamp(40px, 5vw, 96px); align-items: start; }
.try-picks { display: none; gap: 14px; }
.js .try-picks { display: grid; }
.try-pick { padding: 20px 24px; border: 0; border-radius: 20px 20px 20px 6px; background: var(--pick); color: var(--on-field); font: 500 21px/1.35 var(--font-ui); text-align: left; cursor: pointer; transition: background 200ms ease, color 200ms ease, transform 200ms var(--ease-out); }
.try-pick:hover { transform: translateX(4px); }
.try-pick[aria-selected="true"] { background: var(--on-field); color: light-dark(#173f69, #13304d); }
.try-pick:focus-visible { outline-color: var(--on-field); }
.try-results { display: grid; gap: 20px; }
.try-said { display: grid; gap: 10px; padding: clamp(24px, 2.6vw, 40px); border-radius: 22px; background: var(--color-surface); color: var(--color-ink); }
.js .try-said[hidden] { display: none; }
.js .try-said.is-fresh .bubble.is-out, .js .try-said.is-fresh .try-home { animation: rise 600ms var(--ease-out) both; }
.js .try-said.is-fresh .try-home { animation-delay: 380ms; }
.js .try-said.is-fresh .bubble.is-out { animation-delay: 160ms; }
.try-from { color: var(--color-muted); font-size: 15px; font-weight: 600; }
.try-from.is-out { justify-self: end; margin-top: 8px; }
.bubble { max-width: 80%; padding: 14px 18px; border-radius: 18px; font-size: 18px; line-height: 1.45; }
.bubble.is-in { justify-self: start; background: var(--color-sunk); border-bottom-left-radius: 6px; }
.bubble.is-out { justify-self: end; border: 1.5px solid var(--color-primary); border-bottom-right-radius: 6px; }
.try-home { display: grid; gap: 8px; margin-top: 20px; padding: 22px 24px; border-radius: 16px; background: var(--color-bg); border: 1.5px solid var(--color-rule-strong); } /* taste-skill-ignore: drawn as the Owner Screen's own card */
.try-home.is-reported { background: var(--color-reported-soft); border: 1.5px dashed var(--color-reported); }
.try-home.is-urgent { border-color: var(--color-urgent); }
.try-home-label { color: var(--color-muted); font-size: 15px; font-weight: 600; }
.try-home.is-urgent .try-home-label { color: var(--color-urgent); }
.try-home-title { font-size: 21px; font-weight: 600; line-height: 1.3; }
.try-home-note { color: var(--color-muted); }
.try-home-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 6px; }
.chip { display: inline-flex; align-items: center; min-height: 44px; padding: 0 18px; border-radius: 10px; border: 1px solid var(--color-control-edge); background: var(--color-surface); font-weight: 600; } /* taste-skill-ignore: the Owner Screen's own buttons */
.chip.is-primary { border-color: var(--color-primary); color: var(--color-primary); }

/* Who it's for, and the letter. */
.who { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); column-gap: clamp(40px, 5vw, 96px); padding-block: clamp(80px, 10vw, 144px); }
.who-facts { display: grid; align-content: start; gap: 20px; font-size: 18px; }
.who-title { font-size: clamp(34px, 3.3vw, 52px); line-height: 1.06; letter-spacing: -0.022em; font-weight: 700; text-wrap: balance; margin-bottom: 8px; }
.letter { display: grid; gap: 22px; max-width: 560px; justify-self: end; width: 100%; padding: clamp(28px, 3vw, 48px); border-radius: 22px; background: var(--color-surface); font-size: 21px; line-height: 1.6; }
.letter-sign { font-weight: 700; }

/* Questions, answered as reading text. */
.faq { display: grid; gap: 40px; padding-block: 0 clamp(80px, 10vw, 144px); }
.faq-title { font-size: clamp(34px, 3.3vw, 52px); line-height: 1.06; letter-spacing: -0.022em; font-weight: 700; }
.faq-list { columns: 2; column-gap: clamp(40px, 5vw, 96px); font-size: 18px; }
.faq-list p { break-inside: avoid; margin-bottom: 26px; }
.faq-list strong { font-weight: 700; }

/* The waitlist. */
.join { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); column-gap: clamp(40px, 5vw, 96px); row-gap: 40px; padding-block: clamp(72px, 9vw, 128px); background: var(--color-sunk); scroll-margin-top: var(--head-h); }
.join-copy { display: grid; align-content: start; gap: 20px; }
.join-title { font-size: clamp(34px, 3.3vw, 52px); line-height: 1.06; letter-spacing: -0.022em; font-weight: 700; }
.join-lede { font-size: 21px; line-height: 1.45; }
.join-fine { color: var(--color-muted); }
.join-form { display: grid; grid-template-columns: 1fr 1fr; gap: 20px 24px; padding: clamp(24px, 3vw, 44px); border-radius: 22px; background: var(--color-surface); }
.field { display: grid; gap: 8px; font-weight: 600; font-size: 15px; }
.field.is-wide, .join-msg, .join-actions { grid-column: 1 / -1; }
.field input, .field select, .field textarea { width: 100%; min-height: 52px; padding: 12px 14px; border: 1px solid var(--color-control-edge); border-radius: 10px; background: var(--color-input); color: var(--color-ink); font: 400 17px/1.4 var(--font-ui); }
.field textarea { resize: vertical; min-height: 96px; }
.field input::placeholder, .field textarea::placeholder { color: var(--color-muted); }
.field.is-trap { position: absolute; width: 0; height: 0; overflow: hidden; opacity: 0; pointer-events: none; }
.join-actions { display: flex; }
.join-msg { display: none; padding: 16px 18px; border-radius: 12px; font-weight: 600; }
.join-msg:target, .join-msg.is-shown { display: block; }
.join-msg.is-joined { background: var(--color-accent-soft); color: var(--color-ink); }
.join-msg.is-error, .join-msg.is-busy, .join-msg.is-live { background: var(--color-owed-soft); color: var(--color-ink); }
.join-msg.is-live:not([hidden]) { display: block; }
.join-form.is-done .field, .join-form.is-done .join-actions { display: none; }

/* Footer: what DoorSuper texts and for whom (Twilio reads this), and the menu. */
.site-foot { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); column-gap: clamp(40px, 5vw, 96px); row-gap: 32px; padding-block: 64px 56px; }
.foot-about { display: grid; gap: 16px; max-width: 40em; color: var(--color-muted); font-size: 15px; }
.foot-nav { display: grid; align-content: start; justify-items: start; gap: 6px; justify-self: end; }
.foot-nav a { display: inline-flex; align-items: center; min-height: 40px; color: var(--color-ink); font-weight: 500; text-decoration: none; }
.foot-nav a:hover { color: var(--color-link); text-decoration: underline; }

/* The privacy policy and the SMS terms: reading pages, one column, a real heading scale. */
.doc { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); column-gap: clamp(40px, 5vw, 96px); padding-block: clamp(48px, 6vw, 96px); }
.doc-head { display: grid; align-content: start; gap: 16px; }
.doc-head h1 { font-size: clamp(40px, 4.3vw, 62px); line-height: 1.02; letter-spacing: -0.032em; font-weight: 700; text-wrap: balance; }
.doc-head p { color: var(--color-muted); font-size: 21px; }
.doc-body { display: grid; gap: 18px; max-width: 42em; font-size: 18px; line-height: 1.6; }
.doc-body h2 { margin-top: 28px; font-size: 28px; line-height: 1.2; letter-spacing: -0.014em; font-weight: 700; }
.doc-body h2:first-child { margin-top: 0; }
.doc-body ul { display: grid; gap: 10px; margin: 0; padding-left: 1.2em; }
.doc-body .doc-lead { font-size: 21px; line-height: 1.5; }

@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes door-up { from { transform: scaleY(0.15); } to { transform: none; } }

@media (prefers-reduced-motion: no-preference) {
  .hero-doors i { animation: door-up 900ms var(--ease-out) both; }
  .hero-doors i:nth-child(2) { animation-delay: 40ms; } .hero-doors i:nth-child(3) { animation-delay: 80ms; }
  .hero-doors i:nth-child(4) { animation-delay: 120ms; } .hero-doors i:nth-child(5) { animation-delay: 160ms; }
  .hero-doors i:nth-child(6) { animation-delay: 200ms; } .hero-doors i:nth-child(7) { animation-delay: 240ms; }
  .hero-doors i:nth-child(8) { animation-delay: 280ms; } .hero-doors i:nth-child(9) { animation-delay: 320ms; }
  .hero-doors i:nth-child(10) { animation-delay: 360ms; } .hero-doors i:nth-child(11) { animation-delay: 400ms; }
  .hero-doors i:nth-child(12) { animation-delay: 440ms; }
  .js .rv { opacity: 0; transform: translateY(22px); transition: opacity 800ms ease, transform 800ms var(--ease-out); }
  .js .rv.is-in { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  .stage-shot, .try-pick { transition: none; }
  .js .try-said.is-fresh .bubble.is-out, .js .try-said.is-fresh .try-home { animation: none; }
}

/* Below a desktop: one column, each beat carries its own screen. */
@media (max-width: 1000px) {
  .stage, .try-head, .try-body, .who, .join, .site-foot, .doc { grid-template-columns: minmax(0, 1fr); }
  .stage-screen { display: none; }
  .beat { min-height: 0; padding-block: 56px; }
  .beat.is-hero { padding-block: 16px 40px; }
  .beat-shot { display: block; margin-top: 12px; }
  .try-head, .try-body { row-gap: 24px; }
  .letter { justify-self: start; margin-top: 40px; }
  .foot-nav { justify-self: start; }
  .doc-head { margin-bottom: 32px; }
}
/* The full header nav needs about 900px; below that keep only sign-in and the waitlist button. */
@media (max-width: 900px) {
  .site-nav a:not(.site-btn):not(.is-keep) { display: none; }
}
@media (max-width: 720px) {
  .faq-list { columns: 1; }
  .join-form { grid-template-columns: minmax(0, 1fr); }
  .bubble { max-width: 92%; }
  .hero-doors { height: 48px; gap: 5px; }
}
@media (max-width: 480px) {
  .site-nav a.is-keep { display: none; }
}
