/* FR1ENDS — fr1ends.app
   Palette sampled from the app itself: pure black ground, iOS dark-mode
   surfaces, system blue accent, and the three status colours the app uses to
   describe a member's day. Dark-only, on purpose. */

:root {
  --bg:        #000000;
  --surface:   #1c1c1d;
  --surface-2: #232325;
  --line:      rgba(255, 255, 255, 0.09);
  --line-2:    rgba(255, 255, 255, 0.16);

  --fg:        #ffffff;
  --fg-2:      #98989e;
  --fg-3:      #6c6c72;

  --accent:    #0a84ff;
  --accent-hi: #3d9dff;
  --green:     #30d158;
  --orange:    #ff9f0a;
  --red:       #ff453a;
  --purple:    #bf5af2;

  --wrap:      1120px;
  --radius:    18px;

  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI",
          system-ui, Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hi); }

h1, h2, h3 {
  margin: 0;
  font-weight: 700;
  letter-spacing: -0.028em;
  line-height: 1.08;
}

p { margin: 0; }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: 24px;
}

.quiet { color: var(--fg-2); }

.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;
}

/* ── Top bar ─────────────────────────────────────────────────────── */

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: var(--wrap);
  margin-inline: auto;
  padding: 20px 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--fg);
  font-weight: 700;
  letter-spacing: 0.14em;
  font-size: 15px;
}

.brand-mark {
  border-radius: 7px;
  background: #fff;
}

.topnav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.topnav > a:not(.btn) {
  color: var(--fg-2);
  font-size: 15px;
  padding: 8px 12px;
}
.topnav > a:not(.btn):hover { color: var(--fg); }

/* ── Buttons ─────────────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 24px;
  border-radius: 999px;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.01em;
  border: 1px solid transparent;
  transition: background-color .15s ease, border-color .15s ease, transform .15s ease;
}
.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--accent);
  color: #fff;
}
.btn-primary:hover { background: var(--accent-hi); color: #fff; }

.btn-ghost {
  background: transparent;
  color: var(--fg);
  border-color: var(--line-2);
}
.btn-ghost:hover { background: var(--surface); color: var(--fg); }

.btn-sm { padding: 9px 16px; font-size: 15px; }
.btn-lg { padding: 17px 34px; font-size: 17px; }

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px 6px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--fg);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.01));
  border: 1px solid var(--line-2);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.04) inset;
  transition: border-color .2s ease, background .2s ease, transform .15s ease;
}
.status-pill:hover { border-color: rgba(255, 255, 255, 0.24); background: rgba(255, 255, 255, 0.04); }
.status-pill:active { transform: translateY(1px); }

.status-pill-dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: #f5b400;
  box-shadow: 0 0 8px rgba(245, 180, 0, 0.5);
  animation: status-pill-pulse 1.9s ease-in-out infinite;
}

@keyframes status-pill-pulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(245, 180, 0, 0.55); }
  50%      { opacity: 0.7; box-shadow: 0 0 0 6px rgba(245, 180, 0, 0); }
}

@media (prefers-reduced-motion: reduce) {
  .status-pill-dot { animation: none; }
}

/* ── Hero ────────────────────────────────────────────────────────── */

.hero {
  padding-top: 140px;
  padding-bottom: 160px;
  text-align: center;
}

.hero-copy {
  max-width: 780px;
  margin-inline: auto;
}

.eyebrow {
  color: var(--fg-2);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 22px;
}

.hero h1 {
  font-size: clamp(40px, 6.2vw, 68px);
  font-weight: 800;
  letter-spacing: -0.038em;
}

/* ── "fr1ends" — liquid chrome ───────────────────────────────────────
   The material from Apple's WWDC26 Swift-bird animation, rebuilt in
   CSS: a silver body that breathes down into smoked glass and back,
   crossed by a hard blade of specular light — warm gold on its leading
   edge, electric blue trailing it — blooming against the black.

   Two layers clipped to one word. The base is the material; the blade
   is screened over it so the overlap blows out to white the way the
   bird's belly does. No JavaScript: the page ships with
   `script-src 'none'`, and this never needed any. */

.chrome {
  position: relative;
  display: inline-block;
  isolation: isolate;
  white-space: nowrap;
}

/* Ambient backlight the word floats in. Swells as the blade crosses. */
.chrome::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: -55% -12%;
  background: radial-gradient(56% 54% at 50% 50%,
    rgba(226, 236, 255, 0.26)  0%,
    rgba(150, 186, 255, 0.11) 46%,
    rgba(120, 160, 255, 0)    74%);
  filter: blur(0.28em);
  opacity: 0.2;
  pointer-events: none;
  animation: chrome-halo 8s ease-in-out infinite;
}

/* The duplicate carrying the blade — decorative, hidden from AT. */
.chrome-spec {
  position: absolute;
  inset: 0;
  pointer-events: none;
  -webkit-user-select: none;
  user-select: none;
}

/* Without background-clip the word simply stays white. */
@supports ((background-clip: text) or (-webkit-background-clip: text)) {

  .chrome-base,
  .chrome-spec {
    -webkit-background-clip: text;
    background-clip: text;
    background-repeat: no-repeat;
    background-size: 200% 100%;
    color: transparent;
    -webkit-text-fill-color: transparent;
  }

  /* Body. Silver → white → smoked glass and back, twice per tile, so
     some part of the word is always lit and the whole never goes dark
     at once. The trough (#4c5162) still clears 3:1 on black at this
     size, so every frame stays readable. Drifts on its own 11s clock
     so it never locks into step with the blade. */
  .chrome-base {
    background-image: linear-gradient(100deg,
      #ffffff   0%,
      #f4f6fb   6%,
      #c3c8d6  11%,
      #7d8496  14%,
      #aeb4c4  17%,
      #f0f3f9  22%,
      #ffffff  28%,
      #ffffff  34%,
      #dfe3ee  39%,
      #8f96a8  43%,
      #565d70  46%,
      #9aa1b2  50%,
      #dde1eb  55%,
      #ffffff  62%,
      #ffffff  70%,
      #e8ebf3  75%,
      #a8aebe  80%,
      #767d8f  83%,
      #b6bcca  87%,
      #eef1f7  92%,
      #ffffff 100%);
    background-repeat: repeat;
    animation: chrome-flow 11s linear infinite;
  }

  /* Blade. One hot pass per cycle, then a dark beat before the next —
     the bird's rhythm. The coloured drop-shadows sit behind the glyphs,
     so the dispersion reads as fringing off the highlight rather than
     tinting the metal. */
  .chrome-spec {
    background-image: linear-gradient(100deg,
      rgba(255, 255, 255, 0)      16%,
      rgba(255, 206, 146, 0)      18%,
      rgba(255, 224, 180, 0.40) 21.5%,
      rgba(255, 246, 228, 0.78) 23.5%,
      #ffffff                   24.5%,
      rgba(226, 240, 255, 0.72) 25.5%,
      rgba(128, 182, 255, 0.42)   28%,
      rgba(96, 158, 255, 0)       31%,
      rgba(255, 255, 255, 0)      35%,
      rgba(255, 176,  88, 0)      38%,
      rgba(255, 192, 118, 0.62) 42.5%,
      rgba(255, 232, 198, 0.94)   46%,
      #ffffff                     48%,
      #ffffff                   52.5%,
      rgba(206, 230, 255, 0.95) 54.5%,
      rgba(112, 176, 255, 0.70) 57.5%,
      rgba(70, 140, 255, 0)     61.5%,
      rgba(255, 255, 255, 0)      64%);
    mix-blend-mode: screen;
    filter:
      drop-shadow(-0.022em 0 0.10em rgba(255, 168, 84, 0.55))
      drop-shadow(0.022em 0 0.13em rgba(96, 166, 255, 0.60))
      drop-shadow(0 0 0.32em rgba(190, 218, 255, 0.5))
      drop-shadow(0 0 0.78em rgba(118, 168, 255, 0.28));
    animation: chrome-blade 8s linear infinite;
  }
}

/* background-size is 200%, so a 200% shift is exactly one tile. */
@keyframes chrome-flow {
  from { background-position: 200% 50%; }
  to   { background-position:   0% 50%; }
}

/* Enters off the left, exits off the right; centred at the halo's peak. */
@keyframes chrome-blade {
  from { background-position: 150% 50%; }
  to   { background-position: -50% 50%; }
}

@keyframes chrome-halo {
  0%, 100% { opacity: 0.20; transform: scale(0.92); }
  50%      { opacity: 0.72; transform: scale(1.06); }
}

/* Frozen mid-pass: still chrome, still lit, just not moving. */
@media (prefers-reduced-motion: reduce) {
  .chrome::before { animation: none; opacity: 0.6; }
  .chrome-base    { animation: none; background-position: 110% 50%; }
  .chrome-spec    { animation: none; background-position:  44% 50%; }
}

.lede {
  margin: 22px auto 0;
  font-size: clamp(17px, 2vw, 20px);
  color: var(--fg-2);
  max-width: 52ch;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 34px;
}

.fineprint {
  margin-top: 16px;
  font-size: 14px;
  color: var(--fg-3);
}

.hero-shot { display: flex; justify-content: center; }

/* ── Phone bezel ─────────────────────────────────────────────────── */

.phone {
  --phone-w: 290px;
  position: relative;
  width: var(--phone-w);
  margin: 0;
  padding: 3px;
  border-radius: 42px;
  background:
    linear-gradient(135deg,
      #26262a 0%,
      #16161a 30%,
      #16161a 70%,
      #26262a 100%);
}

.phone-screen {
  position: relative;
  border-radius: 39px;
  overflow: hidden;
  background: #000;
}

.phone-screen img { width: 100%; }

/* ── Problem strip ───────────────────────────────────────────────── */

.strip {
  padding-block: 40px;
}

.strip p {
  max-width: 62ch;
  margin-inline: auto;
  text-align: center;
  font-size: clamp(19px, 2.4vw, 24px);
  line-height: 1.42;
  letter-spacing: -0.02em;
  color: var(--fg-2);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding-block: 40px;
}
.strip strong { color: var(--fg); font-weight: 700; }

/* ── Sections ────────────────────────────────────────────────────── */

.section { padding-block: 80px; }

.section-title {
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 800;
  letter-spacing: -0.035em;
  margin-bottom: 44px;
}

/* ── Steps ───────────────────────────────────────────────────────── */

.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 72px;
}

.step {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

.step:nth-child(even) .step-copy { order: 2; }

.step-num {
  display: block;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin-bottom: 14px;
}

.step h3 {
  font-size: clamp(24px, 3vw, 32px);
  letter-spacing: -0.03em;
}

.step-copy p {
  margin-top: 16px;
  color: var(--fg-2);
  max-width: 44ch;
  font-size: 17px;
}

.step-shot { display: flex; justify-content: center; }

/* The block screen, redrawn — this is the app's copy, not a screenshot. */
.shield-card {
  width: 290px;
  border-radius: 28px;
  border: 1px solid var(--line);
  background: radial-gradient(120% 100% at 50% 0%, #2a2a2e 0%, #141416 70%);
  padding: 44px 28px 28px;
  text-align: center;
}

.shield-emoji { font-size: 56px; line-height: 1; display: block; }

.shield-title {
  margin-top: 24px;
  font-size: 25px;
  font-weight: 800;
  letter-spacing: 0.01em;
  line-height: 1.16;
}

.shield-btn {
  display: block;
  margin-top: 28px;
  padding: 13px;
  border-radius: 999px;
  background: #5478ff; /* the shield's own brand colour */
  color: #fff;
  font-weight: 600;
}

.shield-note {
  margin-top: 20px;
  font-size: 13px;
  color: var(--fg-3);
}

/* ── Split (statuses) ────────────────────────────────────────────── */

.split {
  display: grid;
  grid-template-columns: 1fr 0.8fr;
  gap: 56px;
  align-items: start;
}

.split .section-title { margin-bottom: 20px; }

.lede-2 {
  color: var(--fg-2);
  font-size: 19px;
  max-width: 46ch;
}

.statuses {
  list-style: none;
  margin: 30px 0;
  padding: 22px;
  display: grid;
  gap: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-size: 16px;
}

.dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  display: inline-block;
  margin-right: 12px;
  vertical-align: 1px;
}
.dot-green  { background: var(--green);  }
.dot-orange { background: var(--orange); }
.dot-purple { background: var(--purple); }
.dot-red    { background: var(--red);    }

.split-shot { display: flex; justify-content: center; position: sticky; top: 32px; }

/* ── Feature grid ────────────────────────────────────────────────── */

.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px;
}

.card h3 {
  font-size: 19px;
  letter-spacing: -0.02em;
}

.card p {
  margin-top: 10px;
  color: var(--fg-2);
  font-size: 15.5px;
}

.card-wide { grid-row: span 2; }

.votes {
  width: 100%;
  margin-top: 20px;
  border-collapse: collapse;
  font-size: 15px;
}
.votes th {
  text-align: left;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fg-3);
  padding-bottom: 10px;
}
.votes th:last-child, .votes td:last-child { text-align: right; }
.votes td {
  padding: 9px 0;
  border-top: 1px solid var(--line);
  color: var(--fg-2);
}

.pill {
  display: inline-block;
  padding: 3px 11px;
  border-radius: 999px;
  background: rgba(10, 132, 255, 0.16);
  color: var(--accent-hi);
  font-weight: 600;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}

/* ── Closer ──────────────────────────────────────────────────────── */

.closer {
  text-align: center;
  padding-block: 100px 110px;
}

.closer h2 {
  font-size: clamp(32px, 5vw, 52px);
  font-weight: 800;
  letter-spacing: -0.04em;
}

.closer p {
  margin-top: 16px;
  color: var(--fg-2);
  font-size: 18px;
}

/* ── Footer ──────────────────────────────────────────────────────── */

.footer {
  border-top: 1px solid var(--line);
  padding-block: 32px;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
  font-size: 13px;
}

.footer-meta {
  color: var(--fg-3);
  font-size: 14px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* ── Responsive ──────────────────────────────────────────────────── */

@media (max-width: 940px) {
  .step,
  .split {
    grid-template-columns: 1fr;
    gap: 44px;
  }
  .hero { padding-top: 88px; padding-bottom: 112px; }
  .step:nth-child(even) .step-copy { order: 0; }
  .split-shot { position: static; order: -1; }
  .grid { grid-template-columns: repeat(2, 1fr); }
  .card-wide { grid-row: auto; grid-column: span 2; }
  .section { padding-block: 60px; }
}

@media (max-width: 640px) {
  body { font-size: 16px; }
  .topnav > a:not(.btn) { display: none; }
  .grid { grid-template-columns: 1fr; }
  .card-wide { grid-column: auto; }
  .cta-row .btn { flex: 1 1 100%; }
  .phone { --phone-w: min(270px, 78vw); }
  .shield-card { width: min(270px, 78vw); }
  .closer { padding-block: 72px 80px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}

/* ── Policy documents (/privacy, /terms) ─────────────────────────────
   Long-form prose pages. Same ground and type as the landing page, but a
   single measured column instead of a layout — these are read, not scanned.
   No JS, no webfonts, no third-party anything on these pages: the Privacy
   Policy states the product has no analytics or tracking, and the pages
   that make that claim must not contradict it. */

.doc {
  max-width: 760px;
  padding-block: 56px 96px;
}

.doc h1 {
  font-size: clamp(32px, 5vw, 46px);
  font-weight: 800;
  letter-spacing: -0.04em;
}

.doc-date {
  margin-top: 14px;
  color: var(--fg-3);
  font-size: 14px;
  letter-spacing: 0.01em;
}

.doc h2 {
  font-size: clamp(20px, 2.6vw, 24px);
  font-weight: 700;
  letter-spacing: -0.025em;
  margin-top: 52px;
  padding-top: 26px;
  border-top: 1px solid var(--line);
}

.doc h2 + p,
.doc h2 + ul,
.doc h2 + ol { margin-top: 16px; }

.doc p {
  margin-top: 18px;
  color: var(--fg-2);
  font-size: 17px;
  line-height: 1.62;
}

.doc p strong { color: var(--fg); font-weight: 650; }

.doc ul,
.doc ol {
  margin: 18px 0 0;
  padding-left: 26px;
  color: var(--fg-2);
  font-size: 17px;
  line-height: 1.62;
}

.doc li { margin-top: 10px; }
.doc li::marker { color: var(--fg-3); }
.doc ol > li::marker { font-variant-numeric: tabular-nums; }

.doc a { text-decoration: underline; text-underline-offset: 2px; }

/* The policy nav marks which of the two documents you are reading. */
.topnav-doc > a[aria-current="page"] { color: var(--fg); }

@media (max-width: 640px) {
  .doc { padding-block: 36px 72px; }
  .doc h2 { margin-top: 40px; padding-top: 22px; }
  .doc p,
  .doc ul,
  .doc ol { font-size: 16px; }
  /* The landing page hides its nav link on mobile; the policy nav is the only
     way between the two documents, so it stays. */
  .topnav-doc > a:not(.btn) { display: inline-block; }
}
