/* ==========================================================================
   Relay — stylesheet
   Big type, full-bleed sections, centred composition.
   ========================================================================== */

/* Schibsted Grotesk, self-hosted. One variable file per subset covers every
   weight the site uses, so nothing is fetched from a third party — which
   matters most on the invite pages, where the URL itself is sensitive. */

@font-face {
  font-family: "Schibsted Grotesk";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("fonts/schibsted-grotesk-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Schibsted Grotesk";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("fonts/schibsted-grotesk-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --page:    #FFFFFF;   /* page ground */
  --surface: #FFFFFF;   /* cards, inputs — lifts away from the ground in dark */
  --grey:    #F6F1F5;   /* section alternate, biased toward the brand magenta */
  --grey-2:  #EBE2E9;
  --line:    #E4D9E1;

  --ink:    #12090F;   /* the wordmark's own black */
  --ink-70: #4C4046;
  --ink-45: #776A70;

  /* Straight from the logo's bolt gradient */
  --magenta:        #C611D6;   /* deep stop — the solid accent */
  --magenta-bright: #F63BFF;   /* bright stop */

  /* Derived. White on #C611D6 is 4.72:1 — it passes, but only just, so every
     piece of text on the band is pure white. No tints, no opacity. */
  --magenta-deep: #7E0A8A;   /* hover / pressed */
  --magenta-ink:  #A50FB4;   /* magenta text on paper */
  --magenta-tint: #F9E4FB;   /* pale fill, e.g. a white button's hover */
  --on-band:      #FFFFFF;

  --sans: "Schibsted Grotesk", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --t-sm:   0.9375rem;
  --t-base: 1.0625rem;
  --t-lg:   clamp(1.125rem, 1.6vw, 1.375rem);
  --t-xl:   clamp(1.375rem, 2.2vw, 1.75rem);
  --t-2xl:  clamp(1.875rem, 4.2vw, 3rem);
  --t-3xl:  clamp(2.75rem, 7.5vw, 5.25rem);

  --gut:   clamp(1.25rem, 5vw, 2.5rem);
  --shell: 62rem;
  --wide:  76rem;

  color-scheme: light;
}

/* ---------------------------------------------------------------- dark -- */
/* Three states: an explicit choice stamps data-theme on <html>; with nothing
   stamped the OS preference decides. Only the tokens change. */

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --page:    #12090F;   /* the wordmark's black, as the ground */
    --surface: #211520;
    --grey:    #1B1018;
    --grey-2:  #2A1C26;
    --line:    #31222C;

    --ink:    #F6EFF3;
    --ink-70: #C0B2BA;
    --ink-45: #8F808A;

    --magenta-deep: #9C0CAB;   /* hover goes deeper here too — going brighter
                                  costs contrast against the white label */
    --magenta-ink:  #F63BFF;   /* links take the gradient's bright stop */
    --magenta-tint: #3A1240;

    color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --page:    #12090F;
  --surface: #211520;
  --grey:    #1B1018;
  --grey-2:  #2A1C26;
  --line:    #31222C;

  --ink:    #F6EFF3;
  --ink-70: #C0B2BA;
  --ink-45: #8F808A;

  --magenta-deep: #9C0CAB;
  --magenta-ink:  #F63BFF;
  --magenta-tint: #3A1240;

  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--page);
  color: var(--ink);
  font-family: var(--sans);
  font-size: var(--t-base);
  line-height: 1.5;
  letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { margin: 0; font-weight: 700; letter-spacing: -0.038em; line-height: 1.05; text-wrap: balance; }
p, ul { margin: 0; }

a { color: var(--magenta-ink); text-underline-offset: 0.18em; }
a:hover { color: var(--ink); }
:focus-visible { outline: 2px solid var(--magenta); outline-offset: 3px; border-radius: 3px; }

.shell { width: 100%; max-width: var(--shell); margin-inline: auto; padding-inline: var(--gut); }
.shell.wide { max-width: var(--wide); }

.skip { position: absolute; left: -9999px; }
.skip:focus {
  left: 1rem; top: 1rem; z-index: 60;
  background: var(--magenta); color: #fff; padding: 0.6rem 1rem; border-radius: 6px;
}

/* ------------------------------------------------------------------ nav -- */

.nav {
  position: sticky; top: 0; z-index: 40;
  background: color-mix(in srgb, var(--page) 84%, transparent);
  backdrop-filter: saturate(180%) blur(18px);
  border-bottom: 1px solid var(--line);
}
.nav-inner { display: flex; align-items: center; gap: 2rem; height: 4rem; }
.brand {
  display: inline-flex; align-items: center;
  margin-right: auto;
}
/* The artboard carries padding around the wordmark, so the box is taller than
   the letterforms — sized up to match the weight of the nav links beside it. */
.brand img, .foot-brand img { width: auto; max-width: none; }
.brand img { height: 2.2rem; }
.foot-brand img { height: 1.9rem; }

/* Two wordmark inks, one shown per theme. These have to out-specify the sizing
   rules above, hence scoping each to its container rather than using the bare
   class — .brand img (0,1,1) would otherwise beat .logo-on-dark (0,1,0). */
.brand .logo-on-light, .foot-brand .logo-on-light { display: block; }
.brand .logo-on-dark,  .foot-brand .logo-on-dark  { display: none; }

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .brand .logo-on-light,
  :root:not([data-theme="light"]) .foot-brand .logo-on-light { display: none; }
  :root:not([data-theme="light"]) .brand .logo-on-dark,
  :root:not([data-theme="light"]) .foot-brand .logo-on-dark { display: block; }
}
:root[data-theme="dark"] .brand .logo-on-light,
:root[data-theme="dark"] .foot-brand .logo-on-light { display: none; }
:root[data-theme="dark"] .brand .logo-on-dark,
:root[data-theme="dark"] .foot-brand .logo-on-dark { display: block; }

:root[data-theme="light"] .brand .logo-on-light,
:root[data-theme="light"] .foot-brand .logo-on-light { display: block; }
:root[data-theme="light"] .brand .logo-on-dark,
:root[data-theme="light"] .foot-brand .logo-on-dark { display: none; }

/* ---------------------------------------------------------- theme toggle -- */

.theme-toggle {
  flex: none;
  width: 2.25rem;
  height: 2.25rem;
  margin-left: 0.5rem;
  display: grid;
  place-items: center;
  color: var(--ink-70);
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 999px;
  cursor: pointer;
  transition: color 120ms ease, border-color 120ms ease;
}
.theme-toggle:hover { color: var(--ink); border-color: var(--ink-45); }
.theme-toggle svg { display: block; }

/* The icon shows the theme you'd switch to: a moon while you're in light. */
.theme-toggle .i-light { display: none; }
.theme-toggle .i-dark  { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .i-light { display: block; }
  :root:not([data-theme="light"]) .theme-toggle .i-dark  { display: none; }
}
:root[data-theme="dark"] .theme-toggle .i-light { display: block; }
:root[data-theme="dark"] .theme-toggle .i-dark  { display: none; }
:root[data-theme="light"] .theme-toggle .i-light { display: none; }
:root[data-theme="light"] .theme-toggle .i-dark  { display: block; }
.nav-links { display: flex; gap: 1.75rem; font-size: var(--t-base); }
.nav-links a { color: var(--ink-70); text-decoration: none; }
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--ink); }
@media (max-width: 40rem) { .nav-links { display: none; } }
@media (max-width: 40rem) { .nav-inner { gap: 0; } .theme-toggle { margin-left: auto; } }

/* -------------------------------------------------------------- sections -- */

.band { padding-block: clamp(3.5rem, 9vw, 7rem); }
.band.grey { background: var(--grey); }
.band.magenta { background: var(--magenta); color: var(--on-band); }
.band.magenta h2, .band.magenta h3 { color: #fff; }

.mid { text-align: center; }
.mid h1, .mid h2 { font-size: var(--t-2xl); max-width: 17ch; margin-inline: auto; }
.mid .sub {
  margin-top: 1.1rem;
  font-size: var(--t-lg);
  color: var(--ink-70);
  max-width: 46ch;
  margin-inline: auto;
  letter-spacing: -0.016em;
}
.band.magenta .sub { color: var(--on-band); }

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

.hero { padding-block: clamp(3rem, 7vw, 5.5rem) clamp(2.5rem, 5vw, 4rem); text-align: center; }
.eyebrow {
  font-size: var(--t-sm);
  font-weight: 600;
  color: var(--magenta-ink);
  letter-spacing: -0.01em;
}
.hero h1 {
  margin-top: 0.9rem;
  font-size: var(--t-3xl);
  letter-spacing: -0.05em;
  line-height: 0.98;
}
.hero .sub {
  margin: 1.35rem auto 0;
  max-width: 40ch;
  font-size: var(--t-lg);
  color: var(--ink-70);
  letter-spacing: -0.016em;
}

/* -------------------------------------------------------------- waitlist -- */

.signup { margin: 2rem auto 0; max-width: 25rem; }
.field-row { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.field-row input[type="email"] {
  flex: 1 1 11rem; min-width: 0;
  font: inherit; font-size: var(--t-sm);
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.75rem 1.1rem;
}
.field-row input[type="email"]::placeholder { color: var(--ink-45); }
.field-row input[type="email"]:focus-visible { border-color: var(--magenta); }

.btn {
  font: inherit; font-size: var(--t-sm); font-weight: 600;
  color: #fff; background: var(--magenta);
  border: 1px solid var(--magenta);
  border-radius: 999px;
  padding: 0.75rem 1.5rem;
  cursor: pointer;
  transition: background 130ms ease;
}
.btn:hover { background: var(--magenta-deep); border-color: var(--magenta-deep); }
.btn[disabled] { opacity: 0.5; cursor: default; }

.band.magenta .field-row input[type="email"] { border-color: transparent; }
.band.magenta .btn { background: #fff; color: var(--magenta-deep); border-color: #fff; }
.band.magenta .btn:hover { background: var(--magenta-tint); border-color: var(--magenta-tint); }

.signup-note { margin-top: 0.9rem; font-size: var(--t-sm); color: var(--ink-45); }
.signup-note a { color: var(--ink-45); }
.band.magenta .signup-note { color: var(--on-band); }
.band.magenta .signup-note a { color: var(--on-band); }
.form-status { margin-top: 0.8rem; font-size: var(--t-sm); color: var(--magenta-ink); }
.form-status[data-state="error"] { color: #B3382A; }
.band.magenta .form-status, .band.magenta .form-status[data-state="error"] { color: #fff; }
.form-status:empty { display: none; }

/* Past this width a single centred column leaves the page looking empty either
   side, so the hero becomes two columns: copy left, device right. Declared after
   the waitlist rules above, which it needs to override. */
@media (min-width: 72rem) {
  .hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: clamp(3rem, 6vw, 6rem);
    align-items: center;
    text-align: left;
    padding-block: clamp(3rem, 6vw, 5rem);
  }
  .hero h1 { max-width: 11ch; }
  .hero .sub { margin-inline: 0; max-width: 36ch; }
  .hero .signup { margin-left: 0; margin-right: 0; }
  .hero .hero-shot { margin-top: 0; }
}


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

.hero-shot {
  position: relative;
  margin: clamp(2.5rem, 6vw, 4rem) auto 0;
  width: clamp(15rem, 22vw, 21rem);
}

/* The simulator doesn't draw the Dynamic Island, so it's overlaid here rather
   than burned into the capture — it stays right if the screenshots change.
   Proportions are the real device's: a 125x37pt pill, 11pt down, on a 402pt
   wide screen. It's black in both themes because it is on a real phone, which
   is why it disappears against the dark capture — same as it does in life. */
.hero-island {
  position: absolute;
  top: 1.63%;
  left: 50%;
  transform: translateX(-50%);
  width: 31.1%;
  aspect-ratio: 125 / 37;
  background: #000;
  border-radius: 999px;
  pointer-events: none;
}
.hero-shot img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 2.25rem;
  box-shadow: 0 2px 4px rgba(18, 9, 15, 0.10), 0 32px 64px -28px rgba(18, 9, 15, 0.5);
}

/* A capture per theme. Container-scoped for the same reason as the wordmark:
   .hero-shot img is (0,1,1) and would beat a bare .on-dark (0,1,0). */
.hero-shot .on-light { display: block; }
.hero-shot .on-dark  { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .hero-shot .on-light { display: none; }
  :root:not([data-theme="light"]) .hero-shot .on-dark  { display: block; }
}
:root[data-theme="dark"] .hero-shot .on-light { display: none; }
:root[data-theme="dark"] .hero-shot .on-dark  { display: block; }
:root[data-theme="light"] .hero-shot .on-light { display: block; }
:root[data-theme="light"] .hero-shot .on-dark  { display: none; }

/* ------------------------------------------------------------- features -- */

.tiles {
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(1rem, 2vw, 1.5rem);
}
@media (max-width: 46rem) { .tiles { grid-template-columns: minmax(0, 1fr); } }

.tile {
  background: var(--surface);
  border-radius: 1.25rem;
  padding: clamp(1.5rem, 3vw, 2rem);
}
.tile h3 { font-size: var(--t-xl); letter-spacing: -0.032em; }
.tile p { margin-top: 0.5rem; color: var(--ink-70); font-size: var(--t-base); max-width: 36ch; }

/* ------------------------------------------------------------- the lists -- */

.cols {
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(2rem, 5vw, 4rem);
  text-align: left;
}
@media (max-width: 44rem) { .cols { grid-template-columns: minmax(0, 1fr); } }

.cols h3 {
  font-size: var(--t-base);
  font-weight: 600;
  letter-spacing: -0.02em;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.28);
}
.cols ul { list-style: none; padding: 0; }
.cols li {
  padding: 0.85rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
  font-size: var(--t-base);
  color: var(--on-band);
}
/* the recessed column is set apart by its heading, not by opacity —
   anything less than pure white drops under 4.5:1 on this ground */

/* --------------------------------------------------------------- points -- */

.points {
  margin-top: clamp(2.25rem, 4.5vw, 3rem);
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(1.5rem, 3vw, 2.5rem);
  text-align: left;
}
@media (max-width: 56rem) { .points { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 32rem) { .points { grid-template-columns: minmax(0, 1fr); } }
.point h3 { font-size: var(--t-base); font-weight: 600; letter-spacing: -0.022em; }
.point p { margin-top: 0.4rem; font-size: var(--t-sm); color: var(--ink-70); }

/* ------------------------------------------------------- unavailable -- */
/* A control that isn't a control yet — reads as a button, isn't clickable. */

.btn-off {
  display: inline-block;
  margin-top: 1.75rem;
  font-size: var(--t-sm);
  font-weight: 600;
  color: var(--ink-45);
  background: var(--grey);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.75rem 1.5rem;
}
.band.grey .btn-off { background: var(--page); }

.status-note { margin-top: 1.25rem; font-size: var(--t-sm); color: var(--ink-45); }

/* -------------------------------------------------------------- invite -- */
/* /add/<handle> — a deep-link landing page, so it's one decision and nothing
   else competing for attention. */

.invite { padding-block: clamp(4rem, 12vw, 8rem); }
.invite h1 {
  font-size: clamp(2.25rem, 5.5vw, 3.5rem);
  letter-spacing: -0.04em;
  max-width: 16ch;
  margin-inline: auto;
}
.invite h1 .handle { color: var(--magenta-ink); }
.invite .sub { margin-top: 1.25rem; max-width: 38ch; }

.invite-actions {
  margin-top: 2.25rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}
.invite-actions .btn { min-width: 15rem; text-decoration: none; }

.btn-quiet {
  font-size: var(--t-sm);
  font-weight: 600;
  color: var(--magenta-ink);
  text-decoration: none;
  padding: 0.5rem 1rem;
}
.btn-quiet:hover { color: var(--ink); }

.invite-warn {
  margin: 1.75rem auto 0;
  max-width: 34ch;
  font-size: var(--t-sm);
  color: var(--ink-70);
  background: var(--grey);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.9rem 1.1rem;
}

.invite-note { margin-top: 2rem; font-size: var(--t-sm); color: var(--ink-45); }
.invite-note a { color: var(--ink-45); }

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

.foot { border-top: 1px solid var(--line); }
.foot-inner {
  padding-block: 2rem 2.5rem;
  display: flex; flex-wrap: wrap; gap: 1rem 2rem; align-items: baseline;
  font-size: var(--t-sm);
}
.foot-brand { display: flex; align-items: center; margin-right: auto; }
.foot-brand img { display: block; width: auto; height: 1.5rem; }
.foot-links { display: flex; flex-wrap: wrap; gap: 1.25rem; }
.foot-links a { color: var(--ink-70); text-decoration: none; }
.foot-links a:hover { color: var(--ink); }

/* ------------------------------------------------------- document pages -- */

.doc { padding-block: clamp(2.5rem, 5vw, 4rem) clamp(3rem, 6vw, 4.5rem); }
.doc-head { border-bottom: 1px solid var(--line); padding-bottom: 1.75rem; }
.doc-head h1 { font-size: var(--t-2xl); max-width: 18ch; margin-top: 0.5rem; }
.doc-lede { margin-top: 1rem; max-width: 52ch; color: var(--ink-70); font-size: var(--t-lg); letter-spacing: -0.016em; }
.doc-head .lbl { font-size: var(--t-sm); font-weight: 600; color: var(--magenta-ink); }

.doc-section {
  display: grid;
  grid-template-columns: 11rem minmax(0, 1fr);
  gap: 0 clamp(1.5rem, 4vw, 3rem);
  border-bottom: 1px solid var(--line);
  padding-block: 1.9rem;
}
@media (max-width: 44rem) { .doc-section { grid-template-columns: minmax(0, 1fr); gap: 0.7rem; } }
.doc-section h2 { font-size: var(--t-base); font-weight: 600; letter-spacing: -0.022em; }
.doc-section > div { max-width: 58ch; }
.doc-section p { color: var(--ink-70); font-size: var(--t-sm); }
.doc-section p + p { margin-top: 0.75rem; }
.doc-section strong { color: var(--ink); font-weight: 600; }

.doc-list { padding: 0; list-style: none; display: grid; gap: 0.5rem; }
.doc-list li { color: var(--ink-70); font-size: var(--t-sm); padding-left: 1rem; position: relative; }
.doc-list li::before { content: "\2013"; position: absolute; left: 0; color: var(--magenta); }
.doc-list b { color: var(--ink); font-weight: 600; }
.doc-section p + .doc-list { margin-top: 0.75rem; }

.kv { margin: 0.85rem 0 0; font-size: var(--t-sm); border-top: 1px solid var(--line); }
.kv div {
  display: grid; grid-template-columns: 8rem minmax(0, 1fr); gap: 1rem;
  padding: 0.55rem 0; border-bottom: 1px solid var(--line);
}
.kv dt { font-weight: 600; color: var(--ink-45); }
.kv dd { margin: 0; color: var(--ink); }
@media (max-width: 32rem) { .kv div { grid-template-columns: minmax(0, 1fr); gap: 0.15rem; } }

.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  cursor: pointer; list-style: none;
  padding-block: 0.9rem;
  display: flex; gap: 1rem; align-items: baseline;
  font-size: var(--t-sm); font-weight: 600;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; margin-left: auto; color: var(--magenta); font-weight: 400; flex: none; }
.faq details[open] summary::after { content: "\2013"; }
.faq summary:hover { color: var(--magenta-ink); }
.faq .answer { padding-bottom: 1rem; color: var(--ink-70); font-size: var(--t-sm); max-width: 58ch; }
.faq .answer p + p { margin-top: 0.7rem; }
