/* Papergold — Midnight Gold, reworked.
   Warm near-black base, cream type, a single gold accent. Self-hosted fonts,
   no build step. Glass is FLAT: frosted blur + subtle tint + soft shadow —
   no specular sheen, no bright inner-frame. Bricolage Grotesque for display,
   Inter for body/UI. All motion respects prefers-reduced-motion. */

@font-face {
  font-family: "Bricolage";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("bricolage.woff2") format("woff2");
}
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("inter.woff2") format("woff2");
}

:root {
  --bg:        #141109;
  --bg-2:      #100d07;
  --ink:       #f1e8d6;
  --ink-soft:  #d0c3a6;
  --muted:     #a89d85;
  --muted-2:   #7a715e;
  --gold-1:    #f3d98a;
  --gold-2:    #d4af37;
  --gold-3:    #e3c463;
  --gold-deep: #191307;
  --line:      rgba(240,220,150,.10);
  --hair:      rgba(240,220,150,.16);
  --glass:     rgba(38,32,22,.55);
  --glass-2:   rgba(46,39,26,.62);
  --glass-brd: rgba(240,220,150,.13);
  --shadow:    0 22px 54px rgba(8,6,2,.5);
  --shadow-sm: 0 10px 28px rgba(8,6,2,.42);
  --maxw:      1120px;
  --display: "Bricolage", "Inter", system-ui, sans-serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

/* warm gold aurora — soft ambient depth behind the whole page */
body::before {
  content: "";
  position: fixed; inset: -25% -10% auto -10%; height: 100vh; z-index: 0; pointer-events: none;
  background:
    radial-gradient(52% 46% at 82% 2%, rgba(212,175,55,.22), transparent 68%),
    radial-gradient(44% 40% at 8% 4%, rgba(227,196,99,.10), transparent 70%);
}
/* fine grain overlay — breaks digital flatness (fixed, non-interactive) */
body::after {
  content: "";
  position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: .04;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
}

a { color: var(--gold-3); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; position: relative; z-index: 1; }

h1, h2, h3, .display { font-family: var(--display); font-weight: 700; }

.gold-text {
  background: linear-gradient(96deg, #fff4d6, var(--gold-3) 52%, #c69433);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

.eyebrow {
  font-size: 12px; letter-spacing: .18em; text-transform: uppercase;
  color: var(--gold-3); font-weight: 600; font-family: var(--sans);
}

/* skip link (a11y) */
.skip { position: absolute; left: -999px; top: 8px; z-index: 100; }
.skip:focus {
  left: 16px; padding: 10px 14px; border-radius: 10px;
  background: var(--gold-1); color: var(--gold-deep); font-weight: 600;
}

/* focus ring — keyboard only */
:focus-visible { outline: 2px solid var(--gold-2); outline-offset: 3px; border-radius: 6px; }

/* ---------- flat glass primitive ---------- */
.glass {
  background: var(--glass);
  -webkit-backdrop-filter: blur(22px) saturate(135%);
  backdrop-filter: blur(22px) saturate(135%);
  border: 1px solid var(--glass-brd);
  box-shadow: var(--shadow);
}

/* ---------- buttons / pills ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 20px; border-radius: 999px; font-size: 14px; font-weight: 600;
  font-family: var(--sans); cursor: pointer; border: 1px solid transparent;
  transition: transform .16s ease, filter .16s ease, border-color .16s ease, color .16s ease, background-color .16s ease;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px) scale(.985); }
.btn-gold { background: linear-gradient(96deg, var(--gold-1), var(--gold-2)); color: var(--gold-deep); }
.btn-gold:hover { filter: brightness(1.06); transform: translateY(-1px); }
.btn-ghost { border-color: var(--glass-brd); color: var(--ink); }
.btn-ghost:hover { border-color: var(--gold-2); color: var(--gold-1); }

/* ---------- nav ---------- */
.nav { position: fixed; top: 14px; left: 0; right: 0; z-index: 50; display: flex; justify-content: center; padding: 0 16px; }
.navbar {
  display: flex; align-items: center; gap: 18px;
  padding: 8px 8px 8px 16px; border-radius: 999px; max-width: calc(100% - 8px);
  box-shadow: var(--shadow-sm);
}
.navbar .brand { display: flex; align-items: center; gap: 9px; font-weight: 700; letter-spacing: .1px; color: var(--ink); font-family: var(--display); }
.navbar .brand img { width: 26px; height: 26px; border-radius: 7px; display: block; }
.nav-links { display: flex; gap: 6px; margin-right: 4px; }
.nav-links a { color: var(--muted); font-size: 14px; padding: 6px 10px; border-radius: 999px; transition: color .15s ease, background-color .15s ease; }
.nav-links a:hover { color: var(--ink); text-decoration: none; background: rgba(240,220,150,.06); }
.nav .btn { padding: 9px 16px; font-size: 13px; }
@media (max-width: 640px) { .nav-links { display: none; } .nav .btn-ghost { display: none; } }

/* ---------- hero ---------- */
.hero { padding: 152px 0 88px; }
.hero .wrap { display: grid; grid-template-columns: 1.05fr .95fr; gap: 44px; align-items: center; }
.brand-lockup { display: inline-flex; align-items: center; gap: 10px; margin-bottom: 20px; }
.brand-lockup img { width: 30px; height: 30px; border-radius: 8px; display: block; }
.brand-lockup span { font-size: 15px; font-weight: 600; letter-spacing: .02em; color: var(--ink-soft); }
.hero h1 { font-size: clamp(38px, 5vw, 56px); line-height: 1.02; letter-spacing: -.03em; text-wrap: balance; }
.hero .lead { color: var(--ink-soft); font-size: clamp(17px, 2vw, 20px); line-height: 1.5; margin: 22px 0 30px; max-width: 30ch; }
.hero-note { margin-top: 16px; color: var(--muted-2); font-size: 13px; }
.store-badges { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.store-badges a { display: inline-flex; transition: transform .16s ease, opacity .16s ease; border-radius: 10px; }
.store-badges a:hover { transform: translateY(-2px); opacity: .92; text-decoration: none; }
.store-badge { height: 48px; width: auto; display: block; }
.store-badge-play { height: 56px; }

/* hero visual: fanned real cards behind a scanning phone + floating chips */
.hero-visual { position: relative; min-height: 460px; display: flex; align-items: center; justify-content: center; }
.cardfan { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
.fan {
  position: absolute; top: 50%; left: 50%; width: 168px; border-radius: 12px; display: block;
  box-shadow: 0 18px 44px rgba(0,0,0,.5); filter: saturate(.96);
}
.fan-l { transform: translate(-118%, -58%) rotate(-15deg); }
.fan-r { transform: translate(18%, -46%) rotate(14deg); }
.device {
  position: relative; z-index: 1; width: 262px;
  border-radius: 38px; padding: 11px; overflow: hidden; background: var(--glass-2);
}
/* screen aspect = the raw iPhone capture (1206×2622) so clips/shots fit exactly, no crop */
.device .screen { width: 100%; aspect-ratio: 1206 / 2622; border-radius: 28px; overflow: hidden; background: #0d0b07; position: relative; }
.device img, .device video { width: 100%; height: 100%; object-fit: cover; display: block; }
.chip-float { position: absolute; z-index: 2; padding: 11px 15px; border-radius: 15px; box-shadow: var(--shadow-sm); }
.value-chip { left: 2%; bottom: 12%; }
.value-chip .lab { font-size: 10px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.value-chip .val { font-size: 22px; font-weight: 700; font-family: var(--display); font-variant-numeric: tabular-nums; }
.toast-chip { right: 0; top: 14%; display: flex; align-items: center; gap: 9px; font-size: 13px; color: var(--ink-soft); }
.toast-chip .dot { width: 20px; height: 20px; border-radius: 999px; display: grid; place-items: center; background: linear-gradient(96deg, var(--gold-1), var(--gold-2)); color: var(--gold-deep); }
.toast-chip .dot svg { width: 12px; height: 12px; }

@media (max-width: 860px) {
  .hero .wrap { grid-template-columns: 1fr; gap: 12px; }
  .hero-visual { min-height: 400px; margin-top: 8px; }
  .cardfan, .toast-chip { display: none; }
}

/* ---------- proof strip ---------- */
.proof { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.proof .wrap { display: flex; flex-wrap: wrap; gap: 12px 40px; align-items: center; justify-content: center; padding-top: 22px; padding-bottom: 22px; }
.proof span { display: inline-flex; align-items: center; gap: 9px; color: var(--muted); font-size: 14px; }
.proof span svg { width: 17px; height: 17px; color: var(--gold-3); flex: none; }

/* ---------- section scaffolding ---------- */
.sec { padding: 84px 0 76px; }
.sec-head { max-width: 40ch; margin-bottom: 8px; }
.sec-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.sec-head h2 { font-size: clamp(26px, 3.4vw, 38px); line-height: 1.05; letter-spacing: -.02em; margin-top: 12px; text-wrap: balance; }

/* ---------- feature rows ---------- */
.feat { padding: 60px 0; }
.feat + .feat, .feat-wide + .feat, .feat-dual + .feat { border-top: 1px solid var(--line); }
.feat .wrap { display: grid; grid-template-columns: 1fr 1fr; gap: 52px; align-items: center; }
.feat.flip .fcopy { order: 2; }
.feat h2 { font-size: clamp(27px, 3.6vw, 40px); line-height: 1.06; letter-spacing: -.02em; margin: 14px 0 12px; text-wrap: balance; }
.feat p { color: var(--ink-soft); font-size: 17px; line-height: 1.6; max-width: 38ch; }
.feat .fkicker { color: var(--gold-3); font-weight: 600; font-size: 13px; letter-spacing: .04em; }
.fmedia { display: flex; justify-content: center; }
@media (max-width: 860px) {
  .feat .wrap { grid-template-columns: 1fr; gap: 32px; }
  .feat.flip .fcopy { order: 0; }
}

/* wide/centered feature (value) — breaks the zigzag; sits right under the
   proof strip, which already draws the separating hairline */
.feat-wide { text-align: center; }
.feat-wide .sec-head { margin: 0 auto; }
.feat-wide .stage { position: relative; margin: 40px auto 0; width: 100%; max-width: 620px; min-height: 420px; display: flex; align-items: center; justify-content: center; }
.stat-chip { position: absolute; z-index: 2; padding: 12px 16px; border-radius: 15px; text-align: left; box-shadow: var(--shadow-sm); animation: float 6s ease-in-out infinite; }
.stat-chip .lab { font-size: 10px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.stat-chip .val { font-size: 20px; font-weight: 700; font-family: var(--display); font-variant-numeric: tabular-nums; margin-top: 2px; }
.stat-chip .val.up { color: var(--gold-1); }
.stat-a { left: 2%; top: 14%; animation-delay: -1s; }
.stat-b { right: 0; top: 40%; animation-delay: -3s; }
.stat-c { left: 6%; bottom: 12%; animation-delay: -2s; }
@keyframes float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-9px); } }
@media (max-width: 640px) { .stat-b { right: -2%; } .stat-a, .stat-c { left: -2%; } }

/* dual-phone feature (trades) — breaks the zigzag */
.feat-dual { border-top: 1px solid var(--line); }
.feat-dual .wrap { display: grid; grid-template-columns: 1fr 1fr; gap: 52px; align-items: center; }
.dualstage { position: relative; display: flex; justify-content: center; align-items: center; min-height: 400px; }
.dualstage .phone { width: 190px; }
.dualstage .phone.d1 { transform: rotate(-7deg) translateX(14%); z-index: 1; }
.dualstage .phone.d2 { transform: rotate(7deg) translateX(-14%); z-index: 2; }
.trade-arrow { position: absolute; z-index: 3; left: 50%; top: 50%; transform: translate(-50%,-50%);
  width: 46px; height: 46px; border-radius: 999px; display: grid; place-items: center;
  background: linear-gradient(96deg, var(--gold-1), var(--gold-2)); color: var(--gold-deep); box-shadow: var(--shadow-sm); }
.trade-arrow svg { width: 22px; height: 22px; }
@media (max-width: 860px) { .feat-dual .wrap { grid-template-columns: 1fr; gap: 32px; } }
@media (max-width: 420px) { .dualstage .phone { width: 150px; } }

/* full-width band feature (life tracker) — dark finale, breaks the zigzag */
.feat-band { border-top: 1px solid var(--line); background: var(--bg-2); }
.feat-band .wrap { text-align: center; padding-top: 78px; padding-bottom: 78px; }
.feat-band h2 { font-size: clamp(27px, 3.6vw, 40px); letter-spacing: -.02em; margin: 12px auto; text-wrap: balance; }
.feat-band p { color: var(--ink-soft); max-width: 46ch; margin: 0 auto 34px; }

/* ---------- media frames (each holds a per-feature video slot) ---------- */
.phone { position: relative; width: 100%; max-width: 258px; margin: 0 auto; border-radius: 38px; padding: 11px; overflow: hidden; background: var(--glass-2); }
.phone .screen { position: relative; width: 100%; aspect-ratio: 1206 / 2622; border-radius: 28px; overflow: hidden; background: #0d0b07; display: grid; place-items: center; }

.frame-web { position: relative; width: 100%; max-width: 560px; margin: 0 auto; border-radius: 16px; padding: 0; overflow: hidden; background: var(--glass-2); }
.frame-web .bar { display: flex; align-items: center; gap: 6px; padding: 11px 14px; border-bottom: 1px solid var(--line); }
.frame-web .bar i { width: 9px; height: 9px; border-radius: 999px; background: rgba(240,220,150,.22); display: block; }
.frame-web .bar .url { margin-left: 10px; font-size: 11px; color: var(--muted-2); }
.frame-web .screen { position: relative; aspect-ratio: 16/10; border-radius: 0; overflow: hidden; background: #0d0b07; display: grid; place-items: center; }

.frame-phone-tall { position: relative; width: 100%; max-width: 300px; margin: 0 auto; border-radius: 42px; padding: 12px; overflow: hidden; background: var(--glass-2); }
.frame-phone-tall .screen { position: relative; width: 100%; aspect-ratio: 1206 / 2622; border-radius: 32px; overflow: hidden; background: #0d0b07; display: grid; place-items: center; }

/* video + placeholder shared across all frames */
.screen video, .screen > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.poster { position: absolute; inset: 0; background: radial-gradient(120% 90% at 30% 18%, #2a2416, #12100a); }
.play {
  position: relative; width: 54px; height: 54px; border-radius: 999px; display: grid; place-items: center;
  color: var(--gold-deep); background: linear-gradient(96deg, var(--gold-1), var(--gold-2));
  box-shadow: 0 10px 30px rgba(212,175,55,.30); transition: transform .18s ease;
}
.play svg { width: 20px; height: 20px; margin-left: 2px; }
.vlabel { position: absolute; left: 0; right: 0; bottom: 12px; text-align: center; font-size: 11px; letter-spacing: .04em; color: var(--muted-2); z-index: 1; }

/* ---------- "everything else" bento ---------- */
.more { border-top: 1px solid var(--line); }
.more .sec-head { text-align: center; margin: 0 auto 36px; }
.bento { display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; }
.tile {
  border-radius: 18px; padding: 22px; position: relative;
  background: var(--glass); border: 1px solid var(--glass-brd);
  box-shadow: var(--shadow-sm);
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
  grid-column: span 2;
}
.tile:hover { transform: translateY(-3px); border-color: rgba(240,212,136,.4); box-shadow: var(--shadow); }
.tile .ico { display: inline-flex; color: var(--gold-3); }
.tile .ico svg { width: 24px; height: 24px; display: block; }
.tile h3 { font-size: 17px; margin: 14px 0 5px; color: var(--gold-1); font-weight: 700; }
.tile p { color: var(--ink-soft); font-size: 14px; line-height: 1.5; }
/* rhythm: first tile is a wide feature; a tinted accent tile for variation */
.tile.wide { grid-column: span 3; }
.tile.tall  { grid-row: span 2; }
.tile.accent {
  background:
    linear-gradient(158deg, rgba(240,212,136,.16), rgba(184,134,47,.03) 62%),
    var(--glass);
  border-color: rgba(240,212,136,.26);
}
@media (max-width: 860px) { .bento { grid-template-columns: repeat(4, 1fr); } .tile, .tile.wide { grid-column: span 2; } }
@media (max-width: 520px) { .bento { grid-template-columns: 1fr; } .tile, .tile.wide { grid-column: span 1; } .tile.tall { grid-row: span 1; } }

/* ---------- closing CTA ---------- */
.cta { padding: 96px 0 48px; text-align: center; }
.cta .panel { border-radius: 26px; padding: 52px 28px; max-width: 660px; margin: 0 auto; }
.cta h2 { font-size: clamp(27px, 3.4vw, 40px); letter-spacing: -.02em; }
.cta p { color: var(--ink-soft); margin: 14px auto 28px; max-width: 42ch; }
.cta .store-badges { justify-content: center; }
.cta .fineprint { margin-top: 18px; color: var(--muted-2); font-size: 13px; }

/* ---------- footer ---------- */
.footer { padding: 48px 0 60px; color: var(--muted-2); font-size: 14px; border-top: 1px solid var(--line); }
.footer .wrap { display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; align-items: flex-start; }
.footer .brand { color: var(--ink-soft); font-weight: 700; font-family: var(--display); margin-bottom: 6px; font-size: 17px; }
.footer a { color: var(--muted); }
.footer a:hover { color: var(--gold-1); }
.foot-links { display: flex; gap: 18px; flex-wrap: wrap; }
.attribution { margin-top: 20px; color: #5f5947; font-size: 12.5px; max-width: 62ch; line-height: 1.5; }

/* ---------- legal pages ---------- */
.legal { padding: 132px 0 80px; }
.legal .wrap { max-width: 820px; }
.legal h1 { font-size: clamp(28px, 4vw, 40px); margin: 0 0 6px; letter-spacing: -.02em; }
.legal h2 { font-size: 21px; margin: 34px 0 10px; color: var(--gold-3); letter-spacing: -.01em; }
.legal h3 { font-size: 17px; margin: 22px 0 8px; }
.legal p, .legal li { color: var(--ink-soft); font-size: 16px; }
.legal a { word-break: break-word; }
.legal .updated { color: var(--muted-2); font-size: 14px; }
.legal .placeholder-note { border: 1px dashed #6b5a24; background: #221d11; border-radius: 10px; padding: 12px 14px; color: var(--gold-3); font-size: 14px; }
.legal .wrap > [data-lang] { display: block !important; }
.legal .wrap > [data-lang="en"] { margin-top: 40px; border-top: 1px solid var(--line); padding-top: 8px; }

/* ---------- scroll reveal (with stagger via --i) ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s cubic-bezier(.16,1,.3,1), transform .7s cubic-bezier(.16,1,.3,1); transition-delay: calc(var(--i, 0) * 70ms); }
.reveal.in-view { opacity: 1; transform: none; }

/* ---------- accessibility fallbacks ---------- */
@media (prefers-reduced-transparency: reduce) {
  .glass, .device, .phone, .frame-web, .frame-phone-tall, .chip-float, .stat-chip, .tile { background: #221d15; -webkit-backdrop-filter: none; backdrop-filter: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .stat-chip { animation: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .store-badges a:hover, .btn:hover, .tile:hover { transform: none; }
}
