/* Allô website. Same tokens as the app (src/theme/tokens.ts): black screens,
   white buttons, pastels as accents only, Inter, pills, calm eased motion. */

@font-face { font-family: Inter; src: url('fonts/Inter_300Light.ttf') format('truetype'); font-weight: 300; font-display: swap; }
@font-face { font-family: Inter; src: url('fonts/Inter_400Regular.ttf') format('truetype'); font-weight: 400; font-display: swap; }
@font-face { font-family: Inter; src: url('fonts/Inter_600SemiBold.ttf') format('truetype'); font-weight: 600; font-display: swap; }
@font-face { font-family: Inter; src: url('fonts/Inter_800ExtraBold.ttf') format('truetype'); font-weight: 800; font-display: swap; }

:root {
  --bg: #000000;
  --surface: #1c1c1e;
  --surface-sunken: #0e0e0f;
  --avatar: #2c2c2e;
  --hairline: #262626;
  --disabled: #3a3a3c;
  --wave-muted: #636366;
  --text: #f5f5f5;
  --text-secondary: #8e8e93;
  --text-tertiary: #d1d1d6;
  --red: #ff453a;
  --on-text: #000000;
  --peach: #ffc9ae;
  --butter: #ffe9a8;
  --mint: #bfebd3;
  --sky: #bcd9ff;
  --lilac: #d8ccff;
  --rose: #ffc6da;
  --brand: #c9b8ff;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.45, 0, 0.55, 1);
  --slow: 420ms;
  --gutter: 20px;
  color-scheme: dark;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { background: var(--bg); -webkit-text-size-adjust: 100%; }
body {
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
a { color: inherit; }
img { display: block; }

/* One language at a time: <span lang="fr"> / <span lang="en">, switched on <html data-lang>. */
html[data-lang='fr'] [lang='en']:not(html),
html[data-lang='en'] [lang='fr']:not(html) { display: none !important; }

/* ---------- Top bar ---------- */
.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  padding: 0 var(--gutter);
  max-width: 1120px;
  width: 100%;
  margin: 0 auto;
}
.logo { font-weight: 800; font-size: 22px; letter-spacing: -0.04em; text-decoration: none; }
.logo b, .mark { color: var(--brand); font-weight: 800; }
.lang {
  display: inline-flex;
  background: var(--surface);
  border-radius: 999px;
  padding: 3px;
  gap: 2px;
}
.lang button {
  font: 600 13px Inter, sans-serif;
  color: var(--text-secondary);
  background: none;
  border: 0;
  border-radius: 999px;
  padding: 6px 12px;
  cursor: pointer;
  transition: background var(--slow) var(--ease), color var(--slow) var(--ease);
}
.lang button[aria-pressed='true'] { background: var(--text); color: var(--on-text); }

/* ---------- Hero ---------- */
main { flex: 1; display: flex; }
.hero {
  max-width: 1120px;
  width: 100%;
  margin: 0 auto;
  padding: 40px var(--gutter) 72px;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  align-items: center;
  gap: 56px;
}
.copy { display: flex; flex-direction: column; gap: 28px; min-width: 0; }

/* The logo rings, then a voice answers (same story as the app's RingingLogo). */
.ringing { display: inline-flex; flex-direction: column; align-items: flex-start; gap: 6px; }
.ringing .word { font-weight: 800; font-size: 56px; line-height: 1.1; letter-spacing: -0.04em; display: flex; align-items: flex-end; }
.ringing .q { position: relative; display: inline-block; color: var(--brand); transform-origin: 50% 85%; animation: wobble 2.4s var(--ease-in-out) 0.5s infinite; }
.ringing .waves { position: absolute; left: 70%; top: 18%; width: 28px; height: 46px; opacity: 0; animation: waves 2.4s var(--ease) 0.5s infinite; }
.ringing .voice { display: flex; align-items: center; gap: 3px; height: 26px; padding-left: 4px; }
.ringing .voice i {
  width: 3px; height: 26px; border-radius: 2px; background: var(--text);
  transform: scaleY(0.05); opacity: 0;
  animation: grow 700ms var(--ease) forwards, breathe 1.8s var(--ease-in-out) infinite alternate;
  animation-delay: calc(1.3s + var(--i) * 60ms), calc(2.2s + var(--i) * 90ms);
}
@keyframes wobble {
  0%, 28%, 100% { transform: rotate(0); }
  5% { transform: rotate(9deg); }
  13% { transform: rotate(-9deg); }
  21% { transform: rotate(9deg); }
}
@keyframes waves {
  0% { opacity: 0; transform: translateX(0); }
  10% { opacity: 1; }
  37% { opacity: 0; transform: translateX(8px); }
  100% { opacity: 0; }
}
@keyframes grow { to { transform: scaleY(var(--h)); opacity: 1; } }
@keyframes breathe { from { transform: scaleY(var(--h)); } to { transform: scaleY(calc(var(--h) * 0.75)); } }

h1 { font-size: clamp(34px, 5vw, 52px); line-height: 1.05; letter-spacing: -0.035em; font-weight: 800; max-width: 14ch; }
.lead { color: var(--text-secondary); font-size: 17px; max-width: 46ch; }
.lead strong { color: var(--text); font-weight: 600; }

.facts { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; }
.facts li {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--surface); border-radius: 999px; padding: 7px 14px 7px 12px;
  font-size: 13px; font-weight: 600; color: var(--text-tertiary);
}
.facts li::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--dot); }

.cta { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  height: 52px; padding: 0 22px; border-radius: 999px;
  font: 600 15px Inter, sans-serif; text-decoration: none; white-space: nowrap;
  transition: transform var(--slow) var(--ease), opacity var(--slow) var(--ease), background var(--slow) var(--ease);
}
.btn svg { width: 20px; height: 20px; flex: none; }
.btn-primary { background: var(--text); color: var(--on-text); }
.btn-primary:hover { transform: translateY(-2px); }
.btn-secondary { background: var(--surface); color: var(--text); }
.btn[aria-disabled='true'] { cursor: default; }
.btn-primary[aria-disabled='true'] { background: var(--surface); color: var(--text-tertiary); }
.btn-primary[aria-disabled='true']:hover { transform: none; }
.btn .soon { font-size: 12px; font-weight: 600; color: var(--text-secondary); }
.fine { color: var(--text-secondary); font-size: 13px; }

/* Store-style buttons: the store's logo, a small line, the store name. */
.btn-store { height: 56px; padding: 0 22px 0 18px; gap: 12px; }
.btn-store .brand { width: 24px; height: 24px; }
.btn-store .stack { display: flex; flex-direction: column; line-height: 1.1; text-align: left; }
.btn-store small { font-size: 11px; font-weight: 400; opacity: 0.75; }
.btn-store .name { font-size: 17px; font-weight: 600; letter-spacing: -0.01em; }
.stack[hidden] { display: none; }

/* Entrance: elements arrive one after the other (fade + short rise). */
.in { opacity: 0; transform: translateY(10px); animation: rise var(--slow) var(--ease) forwards; animation-delay: calc(var(--d, 0) * 90ms + 150ms); }
@keyframes rise { to { opacity: 1; transform: none; } }

/* ---------- Phone ---------- */
.stage { display: flex; justify-content: center; }
.phone {
  position: relative; width: 300px; height: 620px; border-radius: 52px;
  background: var(--bg); border: 1px solid var(--hairline);
  box-shadow: 0 0 0 10px var(--surface-sunken), 0 40px 120px -40px rgba(201, 184, 255, 0.25);
  overflow: hidden;
}
.island { position: absolute; top: 12px; left: 50%; width: 92px; height: 28px; margin-left: -46px; background: #000; border-radius: 999px; z-index: 5; box-shadow: 0 0 0 1px var(--hairline); }
.status { position: absolute; top: 18px; left: 30px; right: 30px; display: flex; justify-content: space-between; font-size: 13px; font-weight: 600; z-index: 4; }
.scene { position: absolute; inset: 0; padding: 64px 18px 18px; opacity: 0; transition: opacity 600ms var(--ease-in-out); }
.phone[data-scene='ping'] .s-ping,
.phone[data-scene='record'] .s-record,
.phone[data-scene='feed'] .s-feed { opacity: 1; }

/* Scene 1: the ping arrives on the lock screen. */
.s-ping { display: flex; flex-direction: column; align-items: center; }
.clock { margin-top: 36px; font-weight: 300; font-size: 76px; letter-spacing: -0.03em; line-height: 1; font-variant-numeric: tabular-nums; }
.date { color: var(--text-secondary); font-size: 14px; margin-top: 8px; }
.notif {
  margin-top: 40px; width: 100%; background: rgba(28, 28, 30, 0.92); border-radius: 22px; padding: 12px 14px;
  display: grid; grid-template-columns: 38px 1fr; gap: 4px 12px; align-items: center;
  opacity: 0; transform: translateY(-24px) scale(0.98);
  transition: opacity 600ms var(--ease), transform 600ms var(--ease);
}
.phone.notified .notif { opacity: 1; transform: none; }
.notif img { width: 38px; height: 38px; border-radius: 9px; grid-row: span 2; }
.notif .head { display: flex; justify-content: space-between; font-size: 14px; font-weight: 600; }
.notif .head span { color: var(--text-secondary); font-weight: 400; font-size: 12px; }
.notif p { font-size: 13px; line-height: 1.35; color: var(--text-tertiary); }

/* Scene 2: recording. */
.s-record { display: flex; flex-direction: column; align-items: center; text-align: center; }
.mini-logo { font-weight: 800; font-size: 18px; letter-spacing: -0.04em; }
.s-record .timer { margin-top: 56px; font-weight: 300; font-size: 84px; line-height: 1; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.s-record .hint { color: var(--text-secondary); font-size: 13px; margin-top: 10px; }
.live { margin-top: 52px; display: flex; gap: 3px; align-items: center; height: 56px; }
.live i { width: 3px; height: 4px; border-radius: 2px; background: var(--disabled); transition: height 180ms var(--ease), background 180ms var(--ease); }
.live i.on { background: var(--text); }
.rec { margin-top: auto; margin-bottom: 28px; width: 84px; height: 84px; border-radius: 50%; border: 4px solid var(--text); display: grid; place-items: center; }
.rec i { width: 56px; height: 56px; border-radius: 50%; background: var(--red); animation: pulse 1.6s var(--ease-in-out) infinite alternate; }
@keyframes pulse { to { transform: scale(0.9); } }

/* Scene 3: friends' blips, unlocked. */
.s-feed { display: flex; flex-direction: column; gap: 14px; }
.s-feed .mini-logo { text-align: center; margin-bottom: 6px; }
.post { display: grid; grid-template-columns: 36px minmax(0, 1fr); gap: 6px 10px; }
.post > * { min-width: 0; }
.av { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; font-weight: 600; font-size: 14px; color: var(--on-text); grid-row: span 3; }
.who { display: flex; justify-content: space-between; font-size: 14px; font-weight: 600; }
.who span { color: var(--text-secondary); font-weight: 400; font-size: 12px; }
.note { font-size: 13px; color: var(--text-tertiary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pill { height: 40px; background: var(--surface); border-radius: 999px; display: flex; align-items: center; gap: 10px; padding: 0 12px 0 5px; }
.play { width: 30px; height: 30px; border-radius: 50%; background: var(--text); display: grid; place-items: center; flex: none; }
.play svg { width: 12px; height: 12px; }
.wave { flex: 1; display: flex; align-items: center; gap: 2px; height: 22px; overflow: hidden; }
.wave i { width: 2px; border-radius: 1px; background: var(--wave-muted); flex: none; }
.wave i.played { background: var(--text); }
.dur { font-size: 12px; color: var(--text-secondary); font-variant-numeric: tabular-nums; }
.chips { display: flex; gap: 6px; }
.chip { height: 24px; border-radius: 999px; background: var(--surface); display: inline-flex; align-items: center; gap: 5px; padding: 0 9px 0 4px; font-size: 11px; color: var(--text-secondary); }
.chip .av { width: 16px; height: 16px; font-size: 9px; grid-row: auto; }

/* The floating tab bar, with the Record key. */
.tabs {
  position: absolute; left: 14px; right: 14px; bottom: 16px; height: 56px; border-radius: 999px;
  background: rgba(28, 28, 30, 0.94); border: 1px solid var(--hairline);
  display: flex; align-items: center; justify-content: space-around; padding: 0 10px;
}
.tabs svg { width: 20px; height: 20px; stroke: var(--text-secondary); fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.tabs .home svg { stroke: var(--text); }
.key { width: 46px; height: 36px; border-radius: 11px; background: var(--text); display: grid; place-items: center; position: relative; }
.key svg { stroke: var(--on-text); }
.key .check { position: absolute; top: -5px; right: -5px; width: 16px; height: 16px; border-radius: 50%; background: var(--mint); border: 2px solid var(--bg); }

/* ---------- Invite page (/add/<username>) ---------- */
.invite { max-width: 460px; width: 100%; margin: 0 auto; padding: 32px var(--gutter) 64px; display: flex; flex-direction: column; gap: 32px; justify-content: center; }
.invite-card { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px; }
.invite-av { width: 96px; height: 96px; border-radius: 50%; display: grid; place-items: center; font-size: 38px; font-weight: 600; color: var(--on-text); background: var(--lilac); margin-bottom: 8px; box-shadow: 0 0 0 4px var(--bg), 0 0 0 5px var(--hairline); }
.invite-small { color: var(--text-secondary); font-weight: 600; font-size: 14px; }
.invite-name { font-size: 34px; max-width: none; word-break: break-all; }
.invite .lead { font-size: 15px; }
.invite-actions { display: flex; flex-direction: column; gap: 12px; text-align: center; }
.invite-btn { width: 100%; justify-content: center; }
.invite-actions .fine strong { color: var(--text); font-weight: 600; }

/* ---------- Footer ---------- */
footer {
  max-width: 1120px; width: 100%; margin: 0 auto; padding: 28px var(--gutter) 36px;
  border-top: 1px solid var(--hairline);
  display: flex; flex-wrap: wrap; gap: 16px 28px; justify-content: space-between; align-items: center;
  color: var(--text-secondary); font-size: 13px;
}
footer nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }
footer a { text-decoration: none; transition: color var(--slow) var(--ease); }
footer a:hover { color: var(--text); }

/* ---------- Legal pages ---------- */
.doc { max-width: 720px; width: 100%; margin: 0 auto; padding: 24px var(--gutter) 80px; }
.doc h1 { font-size: 34px; max-width: none; margin-bottom: 8px; }
.doc h2 { font-size: 18px; letter-spacing: -0.02em; margin: 36px 0 10px; }
.doc p, .doc li { color: var(--text-tertiary); margin-bottom: 10px; }
.doc ul { padding-left: 20px; }
.doc .updated { color: var(--text-secondary); font-size: 13px; margin-bottom: 28px; }
.doc table { width: 100%; border-collapse: collapse; font-size: 14px; margin: 12px 0 20px; }
.doc th, .doc td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--hairline); vertical-align: top; color: var(--text-tertiary); }
.doc th { color: var(--text); font-weight: 600; }
.doc a { color: var(--text); }
.doc .back { display: inline-block; color: var(--text-secondary); text-decoration: none; margin-bottom: 24px; font-size: 14px; }

/* ---------- Small screens ---------- */
@media (max-width: 880px) {
  .hero { grid-template-columns: minmax(0, 1fr); gap: 48px; padding-top: 16px; text-align: left; }
  .stage { order: 2; }
  .ringing .word { font-size: 48px; }
}
@media (max-width: 380px) {
  .phone { transform: scale(0.9); transform-origin: top center; margin-bottom: -60px; }
  .btn { width: 100%; justify-content: center; }
}

/* Reduce motion: everything still, final state shown. */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .in { opacity: 1; transform: none; }
  .ringing .voice i { opacity: 1; transform: scaleY(var(--h)); }
}

/* Fields still to fill in before publishing (scripts/site/deploy.sh refuses while any remain). */
mark.todo { background: var(--butter); color: var(--on-text); border-radius: 4px; padding: 0 4px; }
