/* Ultimate Kami — quiet: warm paper, ink, one grey, and the icon's blue used sparingly. */
:root {
  --paper: #f3f1ec;
  --paper-2: #ebe8e1;
  --ink: #141414;
  --ink-soft: #3d3d3b;
  --grey: #85837d;
  --rule: rgba(20, 20, 20, 0.1);
  --blue: #1f8fe0;

  --f-sans: "Geist", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --f-mono: "Geist Mono", ui-monospace, Menlo, monospace;
  --f-serif: "Newsreader", Georgia, "Times New Roman", serif;

  --gutter: clamp(20px, 5vw, 72px);
  --ease: cubic-bezier(.22, 1, .36, 1);
  color-scheme: light;
}

* { box-sizing: border-box; }
html { overflow-x: clip; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--f-sans);
  font-size: 17px;
  line-height: 1.6;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
::selection { background: var(--ink); color: var(--paper); }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; border-radius: 4px; }

h1, h2 { font-weight: 400; letter-spacing: -0.035em; margin: 0; }
h1 { font-size: clamp(3rem, 6.2vw, 6rem); line-height: 1; }
h2 { font-size: clamp(2.3rem, 4.4vw, 4.2rem); line-height: 1.04; }
em { font-family: var(--f-serif); font-style: italic; font-weight: 300; letter-spacing: -0.01em; }

.kicker {
  font-family: var(--f-mono); font-size: .75rem; letter-spacing: .04em;
  color: var(--grey); margin: 0 0 28px; display: flex; align-items: center; gap: 10px;
}
.kicker::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--blue); }

/* ---------- Nav ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: calc(16px + env(safe-area-inset-top, 0px)) var(--gutter) 16px;
  background: rgba(243, 241, 236, 0.8);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .4s;
}
.nav.scrolled { border-color: var(--rule); }
.nav-mark { display: flex; align-items: center; gap: 10px; font-weight: 500; letter-spacing: -0.01em; }
.nav-mark img { border-radius: 7px; }
.nav-links { display: flex; gap: 32px; font-size: .92rem; color: var(--ink-soft); }
.nav-links a, .nav-store { transition: color .25s; }
.nav-links a:hover, .nav-store:hover { color: var(--blue); }
.nav-store { font-size: .92rem; font-weight: 500; }

/* ---------- App Store badge ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 11px 22px 11px 16px; border-radius: 12px;
  background: var(--ink); color: #fff;
  transition: transform .4s var(--ease), background .3s;
}
.badge:hover { background: #000; transform: translateY(-2px); }
.badge svg { width: 24px; height: 24px; fill: currentColor; flex: none; }
.badge span { display: flex; flex-direction: column; line-height: 1.1; font-size: 1.15rem; font-weight: 500; letter-spacing: -0.01em; }
.badge small { font-size: .66rem; font-weight: 400; letter-spacing: 0; opacity: .85; }

/* ---------- Rotato placeholders ----------
   Each .rotato has data-video="videos/name". script.js swaps in
   videos/name.webm or videos/name.mp4 as soon as one exists. */
.rotato {
  position: relative; aspect-ratio: 9 / 19.5; width: 100%;
  border-radius: 14% / 6.5%;
  background: linear-gradient(165deg, #23272d, #121417);
  border: 7px solid #1b1d20;
  box-shadow: 0 0 0 1px rgba(0,0,0,.08), 0 40px 80px -30px rgba(20,20,20,.35), 0 10px 30px -10px rgba(20,20,20,.2);
  overflow: hidden; display: grid; place-items: center;
}
.rotato::before {
  content: ""; position: absolute; top: 2.6%; left: 50%; translate: -50% 0;
  width: 31%; height: 3.4%; border-radius: 99px; background: #000;
}
.rotato::after {
  content: attr(data-label); position: absolute; left: 0; right: 0; bottom: 6%;
  text-align: center; font-family: var(--f-mono); font-size: .62rem; letter-spacing: .08em;
  color: rgba(255,255,255,.35);
}
.rotato-mark { width: 44%; border-radius: 24%; }
.rotato.has-video { background: none; border: 0; box-shadow: none; border-radius: 0; }
.rotato.has-video::before, .rotato.has-video::after, .rotato.has-video > :not(video) { display: none; }
.rotato video { width: 100%; height: 100%; object-fit: contain; }

/* ---------- Hero ---------- */
.hero { position: relative; height: 230vh; }
.hero-sticky {
  position: sticky; top: 0; height: 100vh; height: 100svh;
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); align-items: center; gap: 2vw;
  padding: 80px var(--gutter) 40px;
}
.hero-sub { font-size: clamp(1.05rem, 1.35vw, 1.2rem); color: var(--ink-soft); max-width: 30em; margin: 32px 0 40px; }
.hero-cta { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }
.cta-note { margin: 0; font-size: .86rem; line-height: 1.35; color: var(--grey); }

.hero-stage { position: relative; height: 100%; display: grid; place-items: center; }
.hero-phone { width: clamp(170px, min(19vw, 30vh), 270px); position: relative; z-index: 2; }
.noise { list-style: none; margin: 0; padding: 0; position: absolute; inset: 0; z-index: 1; }
.noise li {
  position: absolute; left: calc(50% + var(--x) * var(--spread, 0.5)); top: calc(50% + var(--y));
  transform: translate(-50%, -50%);
  width: max-content; max-width: 215px; padding: 10px 14px 10px 42px; border-radius: 14px;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(20,20,20,.06);
  box-shadow: 0 8px 24px -12px rgba(20,20,20,.18);
  font-size: .8rem; line-height: 1.3; color: var(--grey);
  will-change: opacity, filter, transform;
}
.noise li::before { content: ""; position: absolute; left: 10px; top: 50%; translate: 0 -50%; width: 22px; height: 22px; border-radius: 6px; background: var(--paper-2); box-shadow: inset 0 0 0 1px rgba(20,20,20,.06); }
.noise li b { font-weight: 500; color: var(--ink-soft); }
.hero-caption {
  position: absolute; left: 0; right: 0; bottom: 0; margin: 0; text-align: center;
  font-family: var(--f-mono); font-size: .75rem; color: var(--grey); height: 1.4em;
}
.hero-caption span { position: absolute; left: 0; right: 0; transition: opacity .6s var(--ease), transform .6s var(--ease); }
.cap-b { opacity: 0; transform: translateY(6px); color: var(--ink); }
.hero.quiet .cap-a { opacity: 0; transform: translateY(-6px); }
.hero.quiet .cap-b { opacity: 1; transform: none; }

/* ---------- Statement ---------- */
.statement { padding: clamp(80px, 14vh, 160px) var(--gutter); }
.statement p {
  margin: 0; max-width: 1120px;
  font-size: clamp(1.7rem, 3.4vw, 3.1rem); line-height: 1.16; letter-spacing: -0.03em;
}
.statement .soft { color: var(--grey); }

/* ---------- Features ---------- */
.features {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 4vw;
  padding: 0 var(--gutter); border-top: 1px solid var(--rule);
}
.features-list { order: -1; padding-block: 12vh 20vh; }
.features-stage { position: sticky; top: 0; height: 100vh; height: 100svh; display: grid; place-items: center; }
.features-phones { display: grid; width: clamp(200px, min(22vw, 36vh), 290px); }
.features-phones .rotato { grid-area: 1 / 1; opacity: 0; transform: translateY(14px); transition: opacity .8s var(--ease), transform 1s var(--ease); }
.features-phones .rotato.on { opacity: 1; transform: none; }
.feature { min-height: 88vh; display: flex; flex-direction: column; justify-content: center; max-width: 30em; }
.feature-n { font-family: var(--f-mono); font-size: .75rem; color: var(--grey); margin: 0 0 24px; }
.feature h2 { margin-bottom: 28px; }
.feature p { margin: 0; color: var(--ink-soft); font-size: 1.08rem; }
.feature { opacity: .28; transition: opacity .8s var(--ease); }
.feature.active, html:not(.js) .feature { opacity: 1; }
.rotato-inline { display: none; }

/* ---------- Details ---------- */
.details { padding: clamp(100px, 16vh, 180px) var(--gutter); border-top: 1px solid var(--rule); }
.details-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 4vw; margin: 72px 0 0; }
.details-grid div { border-top: 1px solid var(--rule); padding: 22px 0 44px; }
.details-grid dt { font-weight: 500; margin-bottom: 6px; }
.details-grid dd { margin: 0; color: var(--grey); max-width: 24em; }

/* ---------- Origin ---------- */
.origin { padding: clamp(100px, 16vh, 180px) var(--gutter); background: var(--paper-2); text-align: center; }
.origin .kicker { justify-content: center; }
.origin blockquote {
  margin: 0 auto; max-width: 980px;
  font-family: var(--f-serif); font-style: italic; font-weight: 300;
  font-size: clamp(1.8rem, 3.6vw, 3.2rem); line-height: 1.2; letter-spacing: -0.015em;
}

/* ---------- Price ---------- */
.price {
  padding: clamp(100px, 16vh, 180px) var(--gutter);
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 4vw; align-items: start;
}
.price-table { margin: 0; border-top: 1px solid var(--ink); }
.price-table div { display: flex; justify-content: space-between; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--rule); }
.price-table dt { color: var(--ink-soft); }
.price-table dd { margin: 0; font-family: var(--f-mono); font-size: .88rem; color: var(--grey); align-self: center; }
.price-table .price-main { padding: 26px 0; }
.price-table .price-main dt { font-size: 1.3rem; color: var(--ink); font-weight: 500; }
.price-table .price-main dd { font-family: var(--f-sans); font-size: 1.3rem; color: var(--ink); }

/* ---------- Privacy ---------- */
.privacy { padding: clamp(100px, 16vh, 180px) var(--gutter); border-top: 1px solid var(--rule); }
.privacy > p:last-child { margin: 32px 0 0; max-width: 32em; color: var(--ink-soft); font-size: 1.1rem; }

/* ---------- Close ---------- */
.close { padding: clamp(110px, 18vh, 200px) var(--gutter); text-align: center; background: var(--paper-2); }
.close-icon { margin: 0 auto 40px; border-radius: 22px; box-shadow: 0 20px 40px -20px rgba(20,20,20,.4); }
.close h2 { margin-bottom: 44px; }

.footer {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px;
  padding: 28px var(--gutter) calc(28px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--rule); font-size: .82rem; color: var(--grey);
}
.footer p { margin: 0; }

/* ---------- Reveal ---------- */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity 1.1s var(--ease), transform 1.1s var(--ease); }
.js .reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal, .feature { opacity: 1; transform: none; transition: none; }
  .noise li { transition: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .nav-links { display: none; }
  .hero { height: 190vh; }
  .hero-sticky { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); padding-top: 92px; padding-bottom: 12px; gap: 0; }
  .hero-sub { margin: 18px 0 22px; font-size: 1rem; }
  .hero-cta { gap: 16px; }
  .hero-phone { width: min(36vw, 19vh); }
  .noise { --spread: 0.4; }
  .noise li { max-width: 138px; font-size: .64rem; padding: 7px 10px 7px 30px; border-radius: 11px; }
  .noise li::before { left: 7px; width: 16px; height: 16px; border-radius: 5px; }
  .noise li:nth-child(n+7) { display: none; }

  .features { grid-template-columns: minmax(0, 1fr); }
  .features-stage { display: none; }
  .features-list { padding-block: 40px; }
  .feature { min-height: 0; padding-block: 56px; opacity: 1; }
  .rotato-inline { display: grid; width: min(230px, 62vw); margin: 44px auto 0; }

  .details-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .price { grid-template-columns: minmax(0, 1fr); gap: 48px; }
}
@media (max-width: 520px) {
  body { font-size: 16px; }
  .details-grid { grid-template-columns: minmax(0, 1fr); }
  .details-grid div { padding-bottom: 28px; }
}
