/* Sail Earth's founding page (decision 58; docs/09 §5.2). The brand's colours (src/brand.ts) and the teasers' face. */
@font-face {
  font-family: "Michroma";
  src: url("fonts/michroma/michroma.ttf") format("truetype");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Instrument Sans";
  src: url("fonts/instrument-sans/instrument-sans-latin.woff2") format("woff2");
  font-weight: 400 700;
  font-display: swap;
}

:root {
  --ink: #0b1a24;
  --ink-2: #102633;
  --paper: #f4f1ea;
  --mist: #b9c6cc;
  --accent: #ffb35c;
  --sea: #1d4e63;
  --line: rgb(244 241 234 / 0.16);
  --gutter: max(16px, 5vw);
  --display: "Michroma", "Segoe UI", system-ui, sans-serif;
  --text: "Instrument Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}
html {
  background: var(--ink);
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  background: var(--ink);
  color: var(--paper);
  font: 400 1.0625rem / 1.55 var(--text);
  text-rendering: optimizeLegibility;
}
a {
  color: inherit;
  text-underline-offset: 0.18em;
  text-decoration-thickness: 1px;
}
a:hover {
  color: var(--accent);
}
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
.nowrap {
  white-space: nowrap;
}
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* ── the masthead: the wordmark over the footage ───────────────────────────────────────────── */
.masthead {
  position: absolute;
  inset: 0 0 auto;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 20px var(--gutter);
}
.wordmark {
  font: 400 1rem / 1 var(--display);
  letter-spacing: 0.04em;
  text-decoration: none;
}
.masthead a.skip {
  font-size: 0.95rem;
  opacity: 0.85;
}

/* ── the hero: the sim's own footage, full bleed ───────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  align-items: end;
  overflow: hidden;
  isolation: isolate;
}
.hero picture,
.hero video {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
}
.hero picture img,
.hero video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 40%;
}
.hero video {
  opacity: 0;
  transition: opacity 0.8s ease;
}
.hero video.playing {
  opacity: 1;
}
/* the scrim: the sky stays clear, the words sit on the darkened sea */
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(to bottom, rgb(11 26 36 / 0.55), rgb(11 26 36 / 0) 22%),
    linear-gradient(to top, var(--ink) 0%, rgb(11 26 36 / 0.86) 30%, rgb(11 26 36 / 0.35) 58%, rgb(11 26 36 / 0) 78%);
}
.hero-body {
  display: grid;
  grid-template-columns: minmax(0, 44rem);
  align-items: end;
  padding: 0 var(--gutter) clamp(28px, 6vh, 64px);
}
h1 {
  margin: 0 0 1.1rem;
  font: 400 clamp(2rem, 5.6vw, 4.6rem) / 1.08 var(--display);
  letter-spacing: -0.01em;
  text-wrap: balance;
  text-shadow: 0 2px 24px rgb(0 0 0 / 0.35);
}
.lede {
  margin: 0 0 1.6rem;
  max-width: 34rem;
  font-size: clamp(1.05rem, 2.2vw, 1.25rem);
  color: var(--paper);
  opacity: 0.92;
}
/* ── the signup ────────────────────────────────────────────────────────────────────────────── */
.join {
  max-width: 34rem;
}
.join label.field {
  display: block;
  margin-bottom: 0.4rem;
  font-size: 0.95rem;
  color: var(--mist);
}
.join .row {
  display: flex;
  gap: 10px;
}
.join input[type="email"] {
  flex: 1 1 auto;
  min-width: 0;
  height: 52px;
  padding: 0 16px;
  border: 1px solid rgb(244 241 234 / 0.32);
  border-radius: 10px;
  background: rgb(11 26 36 / 0.55);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  color: var(--paper);
  font: inherit;
  font-size: 1.0625rem;
}
.join input[type="email"]::placeholder {
  color: rgb(244 241 234 / 0.5);
}
.join input[type="email"][aria-invalid="true"] {
  border-color: var(--accent);
}
.join button {
  flex: 0 0 auto;
  height: 52px;
  padding: 0 22px;
  border: 0;
  border-radius: 10px;
  background: var(--accent);
  color: var(--ink);
  font: 600 1.0625rem / 1 var(--text);
  cursor: pointer;
  transition:
    background 0.15s ease,
    transform 0.15s ease;
}
.join button:hover {
  background: #ffc27a;
}
.join button:active {
  transform: translateY(1px);
}
.join button[disabled] {
  opacity: 0.7;
  cursor: progress;
}
.consent {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  align-items: start;
  margin-top: 14px;
  font-size: 0.95rem;
  line-height: 1.45;
  color: var(--mist);
}
.consent input {
  width: 20px;
  height: 20px;
  margin: 1px 0 0;
  accent-color: var(--accent);
}
.honey {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.status {
  min-height: 1.5em;
  margin: 12px 0 0;
  font-size: 0.95rem;
  color: var(--accent);
}
.done {
  max-width: 34rem;
  padding: 18px 20px;
  border-left: 3px solid var(--accent);
  background: rgb(11 26 36 / 0.6);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}
.done h2 {
  margin: 0 0 0.35rem;
  font: 400 1.15rem / 1.3 var(--display);
}
.done p {
  margin: 0;
  color: var(--mist);
}

/* ── the offer ─────────────────────────────────────────────────────────────────────────────── */
.offer {
  padding: clamp(64px, 12vw, 140px) var(--gutter) clamp(40px, 7vw, 80px);
}
.offer-line {
  max-width: 22ch;
  margin: 0 0 1.4rem;
  font: 400 clamp(1.6rem, 4.4vw, 3.4rem) / 1.15 var(--display);
  letter-spacing: -0.01em;
  text-wrap: balance;
}
.offer-note {
  max-width: 38rem;
  margin: 0;
  font-size: clamp(1.05rem, 2vw, 1.2rem);
  color: var(--mist);
}

/* ── free or pro ───────────────────────────────────────────────────────────────────────────── */
.tiers {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 0 var(--gutter);
  border-top: 1px solid var(--line);
}
.tier {
  padding: 36px 40px 44px 0;
}
.tier + .tier {
  padding: 36px 0 44px 40px;
  border-left: 1px solid var(--line);
}
.tier h2 {
  margin: 0 0 0.3rem;
  font: 400 1.35rem / 1.2 var(--display);
}
.tier .price {
  margin: 0 0 1.2rem;
  color: var(--mist);
}
.tier ul {
  margin: 0;
  padding: 0;
  list-style: none;
}
.tier li {
  position: relative;
  max-width: 34rem;
  padding: 0.55rem 0 0.55rem 1.4rem;
  border-top: 1px solid var(--line);
}
.tier li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 1.1rem;
  width: 0.55rem;
  height: 1px;
  background: var(--accent);
}

/* ── the close ─────────────────────────────────────────────────────────────────────────────── */
.close {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
  margin: clamp(48px, 8vw, 96px) var(--gutter) 0;
  padding: 32px 0;
  border-top: 1px solid var(--line);
}
.close p {
  margin: 0;
  font: 400 clamp(1.15rem, 2.6vw, 1.6rem) / 1.3 var(--display);
}
.close a.button {
  display: inline-flex;
  align-items: center;
  height: 52px;
  padding: 0 22px;
  border-radius: 10px;
  background: var(--accent);
  color: var(--ink);
  font-weight: 600;
  text-decoration: none;
}
footer.site {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1.6rem;
  padding: 24px var(--gutter) 40px;
  font-size: 0.9rem;
  color: var(--mist);
}

/* ── the privacy notice ────────────────────────────────────────────────────────────────────── */
.notice {
  max-width: 44rem;
  padding: 96px var(--gutter) 48px;
}
.notice h1 {
  font-size: clamp(1.8rem, 4.6vw, 2.8rem);
  text-shadow: none;
}
.notice h2 {
  margin: 2.2rem 0 0.6rem;
  font: 400 1.15rem / 1.3 var(--display);
}
.notice p,
.notice li {
  color: #dfe3e2;
}
.notice .version {
  color: var(--mist);
}
@media (max-width: 760px) {
  .join .row {
    flex-direction: column;
  }
  .join button {
    width: 100%;
  }
  .tiers {
    grid-template-columns: minmax(0, 1fr);
  }
  .tier,
  .tier + .tier {
    padding: 32px 0 36px;
    border-left: 0;
  }
  .tier + .tier {
    border-top: 1px solid var(--line);
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero video {
    transition: none;
  }
}

/* ── the form's small print, the bot check, the offer's fine print ─────────────────────────── */
.notice-link {
  margin: 10px 0 0 30px;
  font-size: 0.9rem;
  color: var(--mist);
}
.turnstile:not(:empty) {
  margin-top: 14px;
}
.offer-fine {
  max-width: 38rem;
  margin: 1rem 0 0;
  font-size: 0.95rem;
  color: var(--mist);
  opacity: 0.85;
}
.storage {
  width: 100%;
  margin: 0.8rem 0 0;
  border-collapse: collapse;
  font-size: 0.95rem;
}
.storage th,
.storage td {
  padding: 0.55rem 0.8rem 0.55rem 0;
  border-top: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
  color: #dfe3e2;
}
.storage th {
  font-weight: 600;
  color: var(--paper);
}
@media (max-width: 760px) {
  .storage,
  .storage tbody,
  .storage tr,
  .storage td {
    display: block;
  }
  .storage thead {
    display: none;
  }
  .storage tr {
    padding: 0.6rem 0;
    border-top: 1px solid var(--line);
  }
  .storage td {
    padding: 0.15rem 0;
    border: 0;
  }
  .storage td::before {
    content: attr(data-h) ": ";
    font-weight: 600;
    color: var(--paper);
  }
}
