/* ==========================================================================
   goepic.surf · Website 2.0 page styles
   Built on css/epic-web.css (tokens + components, Epic Blue only).
   iPhone first; desktop layout from 1024 px.
   Scroll storytelling uses CSS scroll-driven animations, with a static
   fallback (@supports) and prefers-reduced-motion.
   ========================================================================== */

:root { color-scheme: dark; }
html { background: #002136; -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: #002136; }
.site { --pad: clamp(24px, 6.7vw, 96px); --head-h: 0px; min-height: 100vh; }
.site a { color: inherit; }
.site img, .site video { display: block; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 20; padding: 10px 16px; border-radius: 999px; background: var(--cta-bg); color: var(--cta-ink) !important; font: 600 15px/20px var(--font-sans); text-decoration: none; }
.skip:focus { top: 12px; }

.content { position: relative; z-index: 1; background: #002d56 radial-gradient(120% 900px at 20% 0%, #1466ad 0%, #0054a3 30%, #002d56 75%) no-repeat; }

/* ---------- type helpers ---------- */
.h-display { margin: 0; font: 600 clamp(34px, 3.9vw, 56px)/1.06 var(--font-sans); letter-spacing: -0.025em; color: rgba(255,255,255,.95); }
.lede { margin: 0; font: 400 clamp(16px, 1.35vw, 19px)/1.47 var(--font-sans); color: rgba(255,255,255,.7); }
.muted { color: rgba(255,255,255,.5); }

/* ---------- 1. intro: spiral grows into the ground ---------- */
.intro { position: fixed; inset: 0; z-index: 30; display: grid; place-items: center; background: #002d56; pointer-events: none; animation: intro-out .8s 1.25s ease both; }
.intro img { width: 96px; height: 96px; border-radius: 22.37%; animation: spiral 1.9s cubic-bezier(.7,0,.2,1) both; }
@keyframes spiral { 0% { transform: scale(.3) rotate(-120deg); opacity: 0 } 35%, 55% { transform: none; opacity: 1 } 100% { transform: scale(16) rotate(40deg); opacity: 0 } }
@keyframes intro-out { to { opacity: 0; visibility: hidden } }
.load { display: block; animation: load-up .9s cubic-bezier(.22,.9,.3,1) both; }
@keyframes load-up { from { transform: translateY(110%) } to { transform: none } }
.fade { animation: fade 1s ease both; }
@keyframes fade { from { opacity: 0; transform: translateY(24px) } to { opacity: 1; transform: none } }

/* ---------- header ---------- */
.head { position: absolute; left: 0; right: 0; top: 0; z-index: 10; display: flex; justify-content: space-between; align-items: center; gap: 24px; padding: 14px 20px; }
.head .ep-logo { font-size: 17px; }
.head .ep-logo img { width: 28px; height: 28px; }
.head > nav { display: none; }
.head-actions { display: flex; align-items: center; gap: 8px; }
/* language menu: a small globe + code; the list opens under it (plain <details>, works without JS) */
.lang-menu { position: relative; }
.lang-menu summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 10px; border-radius: 999px; font: 500 13px/1 var(--font-sans); color: rgba(255,255,255,.7); }
.lang-menu summary::-webkit-details-marker { display: none; }
.lang-menu summary:hover, .lang-menu[open] summary { color: rgba(255,255,255,.95); background: rgba(255,255,255,.08); }
.lang-menu summary svg { width: 16px; height: 16px; flex: none; }
.lang-menu .head-langs, .head .lang-menu nav { position: absolute; right: 0; top: calc(100% + 8px); z-index: 20; display: flex; flex-direction: column; min-width: 168px; padding: 6px; border-radius: 16px; background: rgba(0,33,54,.94); -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px); box-shadow: 0 0 0 1px rgba(255,255,255,.1), 0 20px 40px -16px rgba(0,10,30,.7); gap: 0; font: 400 15px/20px var(--font-sans); }
.head .lang-menu nav a { display: flex; align-items: center; min-height: 40px; padding: 0 12px; border-radius: 10px; color: rgba(255,255,255,.78); text-decoration: none; }
.head .lang-menu nav a:hover { background: rgba(255,255,255,.08); color: rgba(255,255,255,.95); }
.head .lang-menu nav a[aria-current] { color: var(--accent); font-weight: 600; }
.lang-menu summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.head .ep-btn { min-width: 0; min-height: 36px; padding: 7px 16px; font-size: 14px; }
.head .ep-btn--primary { display: none; }

/* ---------- 2. hero ---------- */
.hero { position: relative; min-height: 100svh; padding: 92px 24px 56px; display: flex; flex-direction: column; gap: 18px; overflow: hidden; box-sizing: border-box; }
.hero-copy { display: flex; flex-direction: column; gap: 18px; }
.hero h1 { margin: 0; font: 600 clamp(42px, 11.8vw, 84px)/1.02 var(--font-sans); letter-spacing: -0.03em; color: rgba(255,255,255,.95); }
.hero h1 > span { display: block; overflow: hidden; padding-bottom: .04em; }
.hero .lede { max-width: 30ch; color: rgba(255,255,255,.75); font-size: clamp(17px, 1.5vw, 21px); }
.store-row { display: flex; align-items: center; gap: 14px; }
.store-row small { font: 400 13px/17px var(--font-sans); color: rgba(255,255,255,.55); }
.hero .ep-store { height: 48px; }
.stats { display: none; }
.hero-art { position: relative; margin-top: 18px; padding-bottom: 28px; display: flex; justify-content: center; }
.hero-phone { animation: hero-exit linear both; animation-timeline: view(); animation-range: exit 0% exit 100%; }
@keyframes hero-exit { to { transform: translateY(-120px) scale(.82); opacity: .2 } }
/* iPhone: the whole phone, with the tide widget over its top right and the banner over its lower part */
.hero-float { position: absolute; z-index: 2; }
.hero-float img { width: 100%; height: auto; }
.float-widget { right: max(-8px, calc(50% - 205px)); width: min(196px, 54%);
  /* bottom edge on the app's hours row (48.4% down the screen): 8px frame + 0.484 × 454px screen */
  top: 228px; translate: 0 -100%; }
.float-widget img { border-radius: 16px; box-shadow: 0 20px 40px -18px rgba(0,10,30,.7); }
.float-banner { left: max(-8px, calc(50% - 172px)); bottom: 70px; width: min(344px, calc(100% + 16px)); }
.float-banner img { filter: drop-shadow(0 18px 30px rgba(0,10,30,.55)); }

/* phones (pure CSS frames around real screenshots) */
.phone { position: relative; box-sizing: border-box; padding: 8px; border-radius: 42px; background: #000; box-shadow: 0 0 0 1px rgba(255,255,255,.07); flex: none; }
/* side buttons, solid black like the device frames in the App Store screenshots: action + volume (left), side button (right) */
.phone::before, .phone::after { content: ""; position: absolute; width: 3px; background: #000; }
.phone::before { left: -3px; top: 17%; height: 30%; border-radius: 2px 0 0 2px; background: linear-gradient(#000 0 14%, transparent 14% 30%, #000 30% 60%, transparent 60% 68%, #000 68% 98%, transparent 98%); }
.phone::after { right: -3px; top: 27%; height: 15%; border-radius: 0 2px 2px 0; }
.phone-screen { position: relative; height: 100%; border-radius: 35px; overflow: hidden; background: #002d56; }
.phone-screen > img, .phone-screen > video, .fill { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.island { position: absolute; top: 9px; left: 50%; width: 32%; height: 22px; transform: translateX(-50%); border-radius: 12px; background: #000; z-index: 3; }
.hero .phone { width: 230px; height: 470px; }

/* ---------- 3. words light up ---------- */
.why { height: 180svh; view-timeline: --why y; }
.why-pin { position: sticky; top: 0; height: 100svh; display: flex; align-items: center; justify-content: center; padding: 0 24px; box-sizing: border-box; }
.why p { margin: 0; max-width: 1100px; overflow-wrap: break-word; font: 600 clamp(36px, 5vw, 72px)/1.1 var(--font-sans); letter-spacing: -0.025em; }
.w { color: rgba(255,255,255,.92); animation: word linear both; animation-timeline: --why; }
.w--ideal { animation-name: word-ideal; color: var(--ideal); }
@keyframes word { from { color: rgba(255,255,255,.16) } to { color: rgba(255,255,255,.92) } }
@keyframes word-ideal { from { color: rgba(255,255,255,.16) } to { color: #99e819 } }

/* line reveals */
.line { display: block; overflow: hidden; view-timeline: --line y; padding-bottom: .06em; }
.line > span { display: block; animation: line-up linear both; animation-timeline: --line; animation-range: entry 20% entry 90%; }
@keyframes line-up { from { transform: translateY(105%); opacity: 0 } to { transform: none; opacity: 1 } }
.reveal { animation: reveal linear both; animation-timeline: view(); animation-range: entry 0% entry 70%; }
@keyframes reveal { from { opacity: 0; transform: translateY(40px) } to { opacity: 1; transform: none } }

/* ---------- 4. sticky phone story ---------- */
.story { height: 660svh; view-timeline: --story y; }
.stage { --ph-h: clamp(330px, calc(100svh - 310px), 500px); position: sticky; top: 0; height: 100svh; box-sizing: border-box; display: flex; flex-direction: column; align-items: center; padding: 52px 24px 28px; gap: 20px; max-width: 520px; margin: 0 auto; }
.stage-copy { display: contents; }   /* iPhone: progress, phone, then the caption */
.stage-head { order: 0; width: 100%; display: flex; flex-direction: column; gap: 10px; }
.stage-art { order: 1; }
.caps { order: 2; }
.stage-head h2 { margin: 0; color: rgba(255,255,255,.6); }
.progress { display: block; width: 100%; height: 3px; border-radius: 3px; background: rgba(255,255,255,.12); overflow: hidden; }
.progress > span { display: block; height: 100%; background: var(--accent); transform-origin: left; animation: progress linear both; animation-timeline: --story; animation-range: contain 0% contain 100%; }
@keyframes progress { from { transform: scaleX(0) } to { transform: none } }
.stage-art { position: relative; width: 100%; height: var(--ph-h); display: flex; justify-content: center; }
.story .phone { height: var(--ph-h); aspect-ratio: 236 / 500; border-radius: calc(var(--ph-h) * .088); }
.story .phone-screen { border-radius: calc(var(--ph-h) * .072); background: #002d56 radial-gradient(120% 60% at 20% 0%, #0f3968 0%, #002d56 60%); }
.scr, .cap { opacity: 0; animation: step linear both; animation-timeline: --story; }
.scr { position: absolute; inset: 0; }
.scr--first, .cap--first { opacity: 1; animation-name: step-first; }
.scr--last, .cap--last { animation-name: step-last; }
@keyframes step { 0% { opacity: 0; transform: translateY(18px) } 18%, 82% { opacity: 1; transform: none } 100% { opacity: 0; transform: translateY(-18px) } }
@keyframes step-first { 0%, 82% { opacity: 1; transform: none } 100% { opacity: 0; transform: translateY(-18px) } }
@keyframes step-last { 0% { opacity: 0; transform: translateY(18px) } 18%, 100% { opacity: 1; transform: none } }
.wipe { animation: wipe linear both; animation-timeline: --story; }
@keyframes wipe { from { clip-path: inset(0 100% 0 0) } to { clip-path: inset(0 0 0 0) } }
.drop { position: absolute; left: 1.8%; width: 96.4%; top: 7.5%; height: auto; z-index: 2; filter: drop-shadow(0 8px 14px rgba(0,10,30,.35)); animation: drop linear both; animation-timeline: --story; animation-range: contain 51% contain 58%; }
@keyframes drop { from { transform: translateY(-140%); opacity: 0 } to { transform: none; opacity: 1 } }
.pop { animation: pop linear both; animation-timeline: --story; }
@keyframes pop { from { transform: scale(.8); opacity: 0 } to { transform: none; opacity: 1 } }
.swap-out { animation: swap-out linear both; animation-timeline: --story; animation-range: contain 75% contain 79%; }
@keyframes swap-out { to { opacity: 0; transform: translateY(-12px) } }
.swap-in { opacity: 0; animation: swap-in linear both; animation-timeline: --story; animation-range: contain 76% contain 80%; }
@keyframes swap-in { from { opacity: 0; transform: translateY(14px) } to { opacity: 1; transform: none } }
.home { background: #010a3a; }   /* under the real iOS home screen (wallpaper + dock) while it loads */
.widgets { position: absolute; inset: 0; padding: 20% 4.5% 3%; display: flex; flex-direction: column; gap: 9px; }
.widgets img { width: 100%; height: auto; }
.widgets .pair { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.phone-move { animation: aside linear both; animation-timeline: --story; animation-range: contain 83% contain 92%; }
@keyframes aside { to { transform: translateX(-24%) scale(.8); opacity: .35 } }
.watch { position: absolute; right: 2%; top: 30%; width: 150px; aspect-ratio: 150 / 182; box-sizing: border-box; padding: 11px; border-radius: 38px; background: #000; box-shadow: 0 0 0 1px rgba(255,255,255,.07); animation: watch linear both; animation-timeline: --story; animation-range: contain 83% contain 92%; }
.watch > div { position: relative; height: 100%; border-radius: 28px; overflow: hidden; background: #000; }
/* digital crown and side button, solid black */
.watch::before, .watch::after { content: ""; position: absolute; background: #000; box-shadow: 0 0 0 1px rgba(255,255,255,.07); }
.watch::after { right: -6px; top: 24%; width: 7px; height: 17%; border-radius: 0 4px 4px 0; }
.watch::before { right: -4px; top: 52%; width: 5px; height: 20%; border-radius: 0 3px 3px 0; }
@keyframes watch { from { transform: translateX(160px); opacity: 0 } to { transform: none; opacity: 1 } }
.caps { position: relative; width: 100%; height: 96px; margin: 0; padding: 0; list-style: none; }
.cap { position: absolute; inset: 0; }
.cap h3 { margin: 0; font: 500 26px/32px var(--font-sans); letter-spacing: -.01em; color: rgba(255,255,255,.92); }
.cap p { margin: 6px 0 0; font: 400 16px/22px var(--font-sans); color: rgba(255,255,255,.72); }

/* ---------- 5. landscape bands (10-day chart, wave map) ---------- */
.band { padding: 96px 24px 24px; display: flex; flex-direction: column; align-items: center; gap: 32px; }
.band-copy { text-align: center; display: flex; flex-direction: column; gap: 14px; align-items: center; }
.band-copy .lede { max-width: 46ch; }
.landscape { width: min(1060px, 100%); box-sizing: border-box; padding: clamp(5px, .76vw, 11px); border-radius: clamp(22px, 4vw, 58px); background: #000; box-shadow: 0 0 0 1px rgba(255,255,255,.07), 0 50px 100px -40px rgba(0,10,30,.6); }
.landscape > div { position: relative; aspect-ratio: 1800 / 828; border-radius: clamp(17px, 3.33vw, 48px); overflow: hidden; background: #0a3a66; }
.chart-band { view-timeline: --chart y; }
.chart-wipe { animation: wipe linear both; animation-timeline: --chart; animation-range: cover 15% cover 55%; }
.ghost { opacity: .2; }

/* ---------- 6. use cases ---------- */
.uses { padding: 72px 0 32px; display: flex; flex-direction: column; gap: 24px; }
.uses .h-display { padding: 0 24px; }
.cards { display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 24px 8px; scrollbar-width: none; }
.cards::-webkit-scrollbar { display: none; }
.card { flex: 0 0 min(290px, 78vw); box-sizing: border-box; scroll-snap-align: center; display: flex; flex-direction: column; gap: 12px; background: rgba(0,0,0,.2); animation: card linear both; animation-timeline: view(inline); animation-range: entry 0% entry 100%; }
@keyframes card { from { transform: scale(.9); opacity: .35 } to { transform: none; opacity: 1 } }
.card .t-label { color: var(--accent); }
.card h3 { margin: 0; font: 600 20px/25px var(--font-sans); color: rgba(255,255,255,.92); }
.card p { margin: 0; font: 400 15px/21px var(--font-sans); color: rgba(255,255,255,.72); }
.swipe-hint { margin: 0; padding: 0 24px; font: 400 13px/18px var(--font-sans); color: rgba(255,255,255,.5); }

/* ---------- 7. pricing ---------- */
.price { padding: 56px 24px; display: flex; flex-direction: column; gap: 28px; }
.plans { display: grid; gap: 16px; }
.plan { box-sizing: border-box; padding: 28px; display: flex; flex-direction: column; gap: 18px; border-radius: 20px; background: rgba(0,0,0,.2); }
.plan--premium { background: linear-gradient(170deg, #0f3968 0%, #002d56 100%); box-shadow: inset 0 0 0 1px rgba(127,254,130,.4); }
.plan--premium .t-label { color: var(--accent); }
.plan .amount { font: 300 48px/1 var(--font-sans); color: rgba(255,255,255,.92); }
.plan .amount small { font-size: 20px; color: rgba(255,255,255,.5); }
.plan .amount-block { display: flex; flex-direction: column; gap: 8px; }
.plan .per-month { font: 400 15px/20px var(--font-sans); color: rgba(255,255,255,.6); }
.plan ul { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 10px; font: 400 16px/23px var(--font-sans); color: rgba(255,255,255,.8); }
.plan li::before { content: "✓"; display: inline-block; width: 1.4em; color: var(--accent); }
.plan li.no::before { content: "·"; color: rgba(255,255,255,.5); }
.plan .note { margin: 0; font: 400 14px/20px var(--font-sans); color: rgba(255,255,255,.6); }

/* ---------- 8. FAQ ---------- */
.faq { padding: 40px 24px 56px; display: flex; flex-direction: column; gap: 20px; }
.faq details { border-top: 1px solid rgba(255,255,255,.12); }
.faq details:last-child { border-bottom: 1px solid rgba(255,255,255,.12); }
.faq summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 56px; padding: 12px 0; font: 600 16px/21px var(--font-sans); color: rgba(255,255,255,.9); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font: 300 26px/1 var(--font-sans); color: rgba(255,255,255,.5); transition: transform .4s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin: 0; padding: 0 0 18px; font: 400 15px/22px var(--font-sans); color: rgba(255,255,255,.7); }
.faq summary:focus-visible, .site a:focus-visible, .site button:focus-visible, .site input:focus-visible, .site textarea:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 8px; }

/* ---------- 9. call to action ---------- */
.get { padding: 24px 24px 72px; }
.get-box { padding: 28px 24px; display: flex; flex-direction: column; gap: 16px; border-radius: 28px; background: linear-gradient(170deg, #0f3968 0%, #002d56 100%); box-shadow: inset 0 0 0 1px rgba(127,254,130,.3); }
.get-box h2 { margin: 0; font: 600 clamp(30px, 3.4vw, 48px)/1.06 var(--font-sans); letter-spacing: -0.025em; color: rgba(255,255,255,.95); }
.get-box .ep-btn { width: 100%; }
.get-box .small { margin: 0; font: 400 13px/18px var(--font-sans); color: rgba(255,255,255,.6); text-align: center; }
.get-box .lede { display: none; }
.get-box .ep-flame { width: 40px; height: 40px; }
.get-box .ep-flame svg { width: 20px; height: 20px; }

/* ---------- 10. contact + newsletter ---------- */
.talk { padding: 24px 24px 96px; display: grid; gap: 40px; }
.talk h2 { margin: 0; font: 600 28px/1.1 var(--font-sans); letter-spacing: -0.02em; color: rgba(255,255,255,.95); }
.talk .lede { margin-top: 8px; font-size: 16px; }
.form { display: flex; flex-direction: column; gap: 12px; margin-top: 20px; }
.field { width: 100%; box-sizing: border-box; min-height: 48px; padding: 12px 16px; border: 0; border-radius: 14px; background: rgba(0,0,0,.22); box-shadow: inset 0 0 0 1px rgba(255,255,255,.12); color: rgba(255,255,255,.92); font: 400 16px/22px var(--font-sans); }
.field::placeholder { color: rgba(255,255,255,.45); }
textarea.field { min-height: 120px; resize: vertical; }
.form .ep-btn { align-self: flex-start; border: 0; cursor: pointer; }
.form-status { margin: 0; font: 400 15px/21px var(--font-sans); color: rgba(255,255,255,.75); }
.form-status[data-kind="ok"] { color: var(--accent); }
.form-status[data-kind="error"] { color: #ffb199; }
.hp { position: absolute; left: -5000px; }

/* ---------- 11. curtain footer ---------- */
.foot { position: sticky; bottom: 0; z-index: 0; min-height: 100svh; box-sizing: border-box; display: flex; flex-direction: column; justify-content: flex-end; gap: 28px; padding: 0 24px 40px; background: #002136 radial-gradient(90% 60% at 50% 100%, #0f3968 0%, #002136 70%); }
.foot-big { display: flex; flex-direction: column-reverse; gap: 28px; }
.foot-big img { width: 120px; height: 120px; border-radius: 22.37%; }
.foot-big p { margin: 0; font: 600 clamp(64px, 11.7vw, 168px)/.9 var(--font-sans); letter-spacing: -0.045em; color: rgba(255,255,255,.92); }
.foot-row { display: flex; flex-direction: column; align-items: flex-start; gap: 22px; }
.foot nav { display: flex; flex-wrap: wrap; gap: 8px 22px; font: 400 15px/22px var(--font-sans); }
.foot nav a { color: rgba(255,255,255,.7); text-decoration: none; min-height: 44px; display: inline-flex; align-items: center; }
.foot nav a:hover { color: rgba(255,255,255,.92); }
.legal { margin: 0; font: 400 12px/16px var(--font-sans); color: rgba(255,255,255,.45); }
.langs { display: flex; flex-wrap: wrap; gap: 2px 18px; font: 400 14px/20px var(--font-sans); }
.langs a { color: rgba(255,255,255,.55); text-decoration: none; min-height: 44px; display: inline-flex; align-items: center; }
.langs a:hover { color: rgba(255,255,255,.9); }
.langs a[aria-current] { color: rgba(255,255,255,.92); font-weight: 600; }

/* ---------- legal pages (Privacy, Terms, Data deletion) ---------- */
.page { background: #002d56 radial-gradient(120% 700px at 20% 0%, #1466ad 0%, #0054a3 30%, #002d56 75%) no-repeat; }
.page .head { position: sticky; background: rgba(0,45,86,.7); -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px); border-bottom: 1px solid rgba(255,255,255,.08); }
.legal-doc { padding: 40px 24px 80px; }
.legal-doc article { max-width: 720px; margin: 0 auto; font: 400 17px/1.6 var(--font-sans); color: rgba(255,255,255,.78); overflow-wrap: break-word; }
.legal-doc h1 { margin: 0 0 28px; font: 600 clamp(36px, 6vw, 56px)/1.05 var(--font-sans); letter-spacing: -0.025em; color: rgba(255,255,255,.95); }
.legal-doc h2 { margin: 44px 0 12px; padding-top: 24px; border-top: 1px solid rgba(255,255,255,.12); font: 600 22px/1.25 var(--font-sans); color: rgba(255,255,255,.92); }
.legal-doc h3 { margin: 28px 0 8px; font: 600 18px/1.3 var(--font-sans); color: rgba(255,255,255,.9); }
.legal-doc p { margin: 0 0 14px; }
.legal-doc .updated { margin: -16px 0 28px; font-size: 14px; color: rgba(255,255,255,.5); }
.legal-doc ul { margin: 0 0 16px; padding-left: 1.2em; list-style: disc; }
.legal-doc li { margin: 0 0 8px; }
.legal-doc li::marker { color: var(--accent); }
.legal-doc strong { color: rgba(255,255,255,.92); font-weight: 600; }
.legal-doc article a { color: var(--link); text-underline-offset: 3px; }
.page-foot { display: flex; flex-direction: column; gap: 14px; padding: 32px 24px 48px; border-top: 1px solid rgba(255,255,255,.12); background: #002136; }
.page-foot nav { display: flex; flex-wrap: wrap; gap: 4px 22px; font: 400 15px/22px var(--font-sans); }
.page-foot nav a { color: rgba(255,255,255,.7); text-decoration: none; min-height: 44px; display: inline-flex; align-items: center; }

/* ---------- 404 ---------- */
.lost { min-height: calc(100svh - 220px); box-sizing: border-box; display: flex; flex-direction: column; justify-content: center; gap: 18px; padding: 64px 24px; max-width: 720px; margin: 0 auto; }
.lost-code { margin: 0; font: 600 clamp(96px, 22vw, 200px)/.9 var(--font-sans); letter-spacing: -0.05em; color: transparent; background: linear-gradient(170deg, #7ffe82 0%, #00d5ff 100%); -webkit-background-clip: text; background-clip: text; }
.lost h1 { margin: 0; font: 600 clamp(32px, 5vw, 52px)/1.05 var(--font-sans); letter-spacing: -0.025em; color: rgba(255,255,255,.95); }
.lost .lede { max-width: 40ch; }
.lost-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 10px; }

/* ---------- Japanese and Chinese ---------- */
/* break Japanese at phrase boundaries where the browser can (Chrome 119+); keep CJK punctuation off line starts */
:lang(ja) { word-break: auto-phrase; line-break: strict; }
:lang(zh) { line-break: strict; }
:lang(ja) h1, :lang(ja) h2, :lang(zh) h1, :lang(zh) h2 { text-wrap: balance; letter-spacing: 0; }

/* ---------- tablet: centre the iPhone layout ---------- */
@media (min-width: 640px) and (max-width: 1023px) {
  .hero, .uses .h-display, .price, .faq, .get, .talk { padding-left: max(24px, calc(50% - 300px)); padding-right: max(24px, calc(50% - 300px)); }
}

/* ---------- desktop ---------- */
@media (min-width: 1024px) {
  /* content is at most 1280 px wide and centred: on large displays the copy stays next to the phone */
  .site { --head-h: 72px; --pad: max(clamp(24px, 6.7vw, 96px), calc(50% - 640px)); }
  .head { position: sticky; height: var(--head-h); box-sizing: border-box; padding: 0 var(--pad); background: rgba(0,45,86,.55); -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px); border-bottom: 1px solid rgba(255,255,255,.08); }
  .head .ep-logo { font-size: 19px; }
  .head .ep-logo img { width: 32px; height: 32px; }
  .head > nav { display: flex; gap: 32px; font: 500 15px/20px var(--font-sans); }
  .head > nav a { color: rgba(255,255,255,.75); text-decoration: none; }
  .head > nav a:hover { color: rgba(255,255,255,.95); }
  .head .ep-btn--secondary { display: none; }
  .head .ep-btn--primary { display: inline-flex; min-height: 40px; padding: 8px 20px; font-size: 15px; }

  .hero { min-height: 0; height: max(100svh, 760px); padding-bottom: 0; margin-top: calc(-1 * var(--head-h)); padding: var(--head-h) var(--pad) 0; display: grid; grid-template-columns: 1.05fr 1fr; align-items: center; gap: 40px; }
  .hero-copy { gap: 26px; }
  .hero h1 { font-size: clamp(64px, 5.85vw, 84px); line-height: 1; letter-spacing: -0.035em; }
  .store-row { gap: 22px; }
  .store-row small { font-size: 14px; line-height: 20px; color: rgba(255,255,255,.6); }
  .hero .ep-store { height: auto; }
  .stats { display: flex; gap: 28px; padding-top: 18px; border-top: 1px solid rgba(255,255,255,.12); font: 400 14px/20px var(--font-sans); color: rgba(255,255,255,.6); }
  .stats b { display: block; font: 400 26px/1.2 var(--font-sans); color: rgba(255,255,255,.92); }
  .hero-art { margin: 0; padding: 0; height: min(760px, calc(100svh - 100px)); align-items: center; }
  .hero .phone { zoom: 1.32; }
  /* phone is 620px tall (×1.32), centred: hours row = top + 10.6px + 0.484 × 599px */
  .float-widget { right: -10px; top: calc(50% - 9.6px); width: 320px; }
  .float-widget img { border-radius: 22px; box-shadow: 0 30px 60px -24px rgba(0,10,30,.6); }
  .float-banner { left: -40px; bottom: 14%; width: 340px; }
  .float-banner img { filter: drop-shadow(0 24px 40px rgba(0,10,30,.55)); }

  .why { height: 190svh; }
  .why-pin { padding: 0 120px; }
  .why p { text-align: center; }

  .story { height: 670svh; }
  .stage { --ph-h: min(680px, calc(100svh - var(--head-h) - 60px)); top: var(--head-h); height: calc(100svh - var(--head-h)); max-width: none; display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: auto; align-items: center; gap: 40px; padding: 0 var(--pad); }
  .stage-copy { display: flex; flex-direction: column; gap: 28px; }
  .stage-art, .caps { order: 0; }
  .stage-head .progress { width: 360px; }
  .stage-art { height: var(--ph-h); }
  .phone-move { animation: none; }
  .watch { right: 0; top: auto; bottom: 8%; width: 180px; padding: 13px; border-radius: 46px; }
  .watch > div { border-radius: 34px; }
  .caps { height: auto; display: flex; flex-direction: column; gap: 22px; }
  .cap { position: static; opacity: .3; padding-left: 20px; border-left: 2px solid rgba(255,255,255,.12); animation-name: dx-cap; }
  .cap h3 { font: 600 30px/1.15 var(--font-sans); letter-spacing: -.015em; color: rgba(255,255,255,.95); }
  .cap p { max-width: 40ch; font: 400 18px/26px var(--font-sans); color: rgba(255,255,255,.75); }
  .cap--first { opacity: 1; animation-name: dx-cap-first; }
  .cap--last { animation-name: dx-cap-last; }
  @keyframes dx-cap { 0% { opacity: .3; border-left-color: rgba(255,255,255,.12) } 18%, 82% { opacity: 1; border-left-color: #7ffe82 } 100% { opacity: .3; border-left-color: rgba(255,255,255,.12) } }
  @keyframes dx-cap-first { 0%, 82% { opacity: 1; border-left-color: #7ffe82 } 100% { opacity: .3; border-left-color: rgba(255,255,255,.12) } }
  @keyframes dx-cap-last { 0% { opacity: .3; border-left-color: rgba(255,255,255,.12) } 18%, 100% { opacity: 1; border-left-color: #7ffe82 } }

  .band { padding: 140px var(--pad) 40px; gap: 36px; }
  .band + .band { padding-top: 120px; }

  .uses { padding: 120px var(--pad) 60px; gap: 40px; }
  .uses .h-display { padding: 0; }
  .cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; overflow: visible; padding: 0; }
  .card { padding: 32px; gap: 14px; animation: reveal linear both; animation-timeline: view(); animation-range: entry 0% entry 70%; }
  .card h3 { font: 500 28px/34px var(--font-sans); letter-spacing: -.01em; }
  .card p { font-size: 17px; line-height: 25px; }
  .swipe-hint { display: none; }

  .price { padding: 80px var(--pad); gap: 40px; }
  .plans { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
  .plan { padding: 36px; gap: 20px; }
  .plan .amount { font-size: 56px; }
  .plan .amount small { font-size: 22px; }
  .plan ul { font-size: 17px; line-height: 24px; gap: 12px; }

  .faq { padding: 80px var(--pad); display: grid; grid-template-columns: 1fr 1.6fr; gap: 64px; align-items: start; }

  .get { padding: 40px var(--pad) 100px; }
  .get-box { padding: 64px; flex-direction: row; align-items: center; justify-content: space-between; gap: 40px; border-radius: 32px; }
  .get-box > div { display: flex; flex-direction: column; gap: 16px; }
  .get-box .lede { display: block; }
  .get-box .ep-flame { width: 48px; height: 48px; }
  .get-box .ep-flame svg { width: 22px; height: 22px; }
  .get-box .cta { display: flex; flex-direction: column; align-items: center; gap: 12px; flex: none; }
  .get-box .ep-btn { width: auto; }

  .legal-doc { padding: 72px var(--pad) 120px; }
  .page-foot { flex-direction: row; align-items: center; justify-content: space-between; padding: 32px var(--pad) 48px; }
  .talk { padding: 40px var(--pad) 140px; grid-template-columns: 1.4fr 1fr; gap: 64px; }

  .foot { padding: 0 var(--pad) 56px; gap: 40px; }
  .foot-big { flex-direction: row; align-items: flex-end; justify-content: space-between; gap: 40px; }
  .foot-big img { width: 220px; height: 220px; }
  .foot-row { flex-direction: row; align-items: center; justify-content: space-between; gap: 32px; padding-top: 28px; border-top: 1px solid rgba(255,255,255,.12); }
}

/* ---------- no scroll-driven animations: show everything, stacked ---------- */
@supports not (animation-timeline: view()) {
  .w, .line > span, .reveal, .hero-phone, .card, .drop, .pop, .phone-move, .watch, .progress > span, .wipe, .chart-wipe, .swap-out, .swap-in, .scr, .cap { animation: none !important; }
  .swap-in, .scr:not(.scr--first) { display: none; }
  .why { height: auto; }
  .why-pin { position: relative; height: auto; padding-block: 96px; }
  .story { height: auto; }
  .stage { position: relative; top: 0; height: auto; padding-block: 64px; }
  .watch { display: none; }
  .caps { height: auto; display: flex; flex-direction: column; gap: 18px; }
  .cap { position: static; opacity: 1; }
}

/* ---------- reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .site *, .site *::before { animation: none !important; transition: none !important; }
  .intro { display: none; }
  .swap-in, .scr:not(.scr--first) { display: none; }
  .why { height: auto; }
  .why-pin { position: relative; height: auto; padding-block: 96px; }
  .story { height: auto; }
  .stage { position: relative; top: 0; height: auto; padding-block: 64px; }
  .watch { display: none; }
  .caps { height: auto; display: flex; flex-direction: column; gap: 18px; }
  .cap { position: static; opacity: 1; }
  .w { color: rgba(255,255,255,.92); }
  .w--ideal { color: var(--ideal); }
}
