/* The landing page (roadmap 7.55), on top of /style.css — which brings the
 * app's palette, the light/dark/device switch and the base type. Copied to
 * public/site/site.css by tools/website/build.mjs.
 *
 * The hero is the store listing's feature graphic made live (the user, 1 Nov
 * 2026): its lime gradient in both themes, yellow glows drifting, and its row of
 * streak stones lighting one by one like a streak growing, then fading and
 * starting again. CSS only (the page's one script is the phone's tilt, below).
 * Under reduced motion it all stands still. */

body.landing {
  padding: 0;
}

/* --- one image per theme ------------------------------------------------------
 * Specific enough to beat `.phone .screen { display: block }` below: with both
 * shown, the light and dark shots stacked in every phone. */

.phone .screen.only-light {
  display: none;
}

@media (prefers-color-scheme: light) {
  .phone .screen.only-dark {
    display: none;
  }

  .phone .screen.only-light {
    display: block;
  }
}

:root:has(#theme-light:checked) .phone .screen.only-dark,
:root:has(#theme-dark:checked) .phone .screen.only-light {
  display: none;
}

:root:has(#theme-light:checked) .phone .screen.only-light,
:root:has(#theme-dark:checked) .phone .screen.only-dark {
  display: block;
}

/* --- the hero ----------------------------------------------------------------- */

.hero {
  --ink: #0c0c0a;
  --lime: #c8ff3d;
  --sun: #ffd426;

  position: relative;
  overflow: hidden;
  isolation: isolate;
  color: var(--ink);
  background: linear-gradient(100deg, #c8ff3d 0%, #9be22e 55%, #c8ff3d 100%);
  padding: 0 16px 72px;
}

.glows,
.stones {
  position: absolute;
  z-index: -1;
  pointer-events: none;
}

.glows {
  inset: 0;
}

.glows b {
  position: absolute;
  width: 720px;
  height: 560px;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(255, 212, 38, 0.6), rgba(255, 212, 38, 0));
  will-change: transform;
}

.glows b:nth-child(1) {
  left: -12%;
  top: -10%;
  animation: drift-a 26s ease-in-out infinite alternate;
}

.glows b:nth-child(2) {
  left: 30%;
  top: 40%;
  animation: drift-b 32s ease-in-out infinite alternate;
}

.glows b:nth-child(3) {
  right: -14%;
  top: -6%;
  animation: drift-c 38s ease-in-out infinite alternate;
}

@keyframes drift-a {
  to {
    transform: translate(220px, 140px) scale(1.15);
  }
}

@keyframes drift-b {
  to {
    transform: translate(-260px, -120px) scale(0.85);
  }
}

@keyframes drift-c {
  to {
    transform: translate(-160px, 220px) scale(1.2);
  }
}

/* The listing's field of stones, faint and still, with one row through it that
 * lights up: 18 stones, 0.4 s apart, a 16 s cycle — lit by ~7 s, held, then
 * fading in the same order from ~9 s, all dark before the first relights. */
.stones {
  left: 0;
  right: 0;
  bottom: 36px;
  height: 260px;
  display: flex;
  align-items: center;
  gap: 32px;
  padding-left: 40px;
  background-image: radial-gradient(circle, rgba(12, 12, 10, 0.14) 7px, transparent 8px);
  background-size: 54px 54px;
  background-position: 13px 0;
  transform: skewY(-9deg);
  transform-origin: left;
  -webkit-mask-image: linear-gradient(180deg, transparent, #000 30%, #000 70%, transparent);
  mask-image: linear-gradient(180deg, transparent, #000 30%, #000 70%, transparent);
}

.stones i {
  flex: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(12, 12, 10, 0.2);
  animation: stone 16s linear infinite;
  animation-delay: calc(var(--i) * 0.4s);
}

@keyframes stone {
  0% {
    background: rgba(12, 12, 10, 0.2);
    box-shadow: none;
    transform: scale(1);
  }

  3% {
    background: var(--sun);
    box-shadow: 0 0 0 4px rgba(255, 212, 38, 0.35), 0 0 18px rgba(255, 212, 38, 0.9);
    transform: scale(1.3);
  }

  6%,
  55% {
    background: var(--sun);
    box-shadow: 0 0 12px rgba(255, 212, 38, 0.7);
    transform: scale(1);
  }

  60%,
  100% {
    background: rgba(12, 12, 10, 0.2);
    box-shadow: none;
    transform: scale(1);
  }
}

.bar {
  max-width: 1080px;
  margin: 0 auto;
  padding: 24px 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 16px;
}

/* The wordmark is painted in the theme's action colour elsewhere; on lime it
 * is ink. */
.hero .wordmark {
  height: 34px;
  background: var(--ink);
}

.hero .brand:focus-visible,
.hero .play:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
}

.hero-body {
  max-width: 1080px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 48px;
  align-items: center;
  padding-top: 24px;
}

/* One line per line of the headline, in every language: the type is sized to
 * the column (a container) by the longest line's character count, ~0.6 em a
 * character in a heavy face, capped at 4.6 rem. */
.pitch {
  container-type: inline-size;
}

.hero h1 {
  font-size: min(4.6rem, calc(100cqi * 1.75 / var(--chars, 18)));
  font-weight: 800;
  line-height: 1.04;
  letter-spacing: -0.035em;
  margin: 0 0 16px;
}

.hero h1 .line {
  display: block;
  white-space: nowrap;
}

.hero .sub {
  font-size: clamp(1.1rem, 2.2vw, 1.4rem);
  margin: 0 0 32px;
  color: rgba(12, 12, 10, 0.78);
}

.play {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 15px 26px 15px 20px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--lime);
  font-weight: 700;
  font-size: 1.05rem;
  text-decoration: none;
  box-shadow: 0 10px 24px rgba(12, 12, 10, 0.25);
  transition: transform 0.15s, box-shadow 0.15s;
}

.play:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(12, 12, 10, 0.3);
}

.hero .note {
  margin: 14px 0 0;
  font-size: 0.92rem;
  color: rgba(12, 12, 10, 0.68);
}

/* --- phones ------------------------------------------------------------------- */

/* The frame is a lit graphite rim, not black: on the dark theme's near-black
 * page a black bezel vanished into it (the user, 1 Nov 2026). A hairline
 * outside it keeps the edge on any background. */
.phone {
  background: linear-gradient(150deg, #5a5850 0%, #2a2924 22%, #1c1b17 55%, #3a3832 100%);
  border-radius: 34px;
  padding: 7px;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.14),
    0 1px 0 1px rgba(255, 255, 255, 0.1) inset,
    0 24px 50px rgba(12, 12, 10, 0.3);
}

.phone .screen {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 9 / 20;
  object-fit: cover;
  border-radius: 26px;
  background: #0c0c0a;
}

/* The phone in 3D: see "the hero phone in 3D" below. */
.hero-phone {
  width: min(280px, 64vw);
  justify-self: center;
  perspective: 1400px;
}

.hero-phone .still {
  display: none;
}

@media (min-width: 820px) {
  .hero {
    padding-bottom: 96px;
  }

  .hero-body {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 64px;
  }

  .hero-phone {
    width: 290px;
    margin-right: 24px;
  }
}

/* --- below the hero ------------------------------------------------------------- */

.landing main {
  max-width: 1080px;
  padding: 0 16px;
}

.landing h2 {
  font-size: clamp(1.5rem, 3.2vw, 2rem);
  letter-spacing: -0.02em;
  margin: 72px 0 24px;
}

.points ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 16px;
}

@media (min-width: 760px) {
  .points ul {
    grid-template-columns: repeat(3, 1fr);
  }
}

.point {
  margin: 0;
  padding: 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.point-icon {
  display: inline-flex;
  color: var(--action);
}

.point h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin: 12px 0 6px;
}

.point p {
  margin: 0;
  color: var(--muted);
}

/* Eight screens (the listing's seven and the grid), sideways, each under its own
 * caption. */
.strip {
  display: flex;
  gap: 28px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: 4px 4px 24px;
  margin: 0 -4px;
  scrollbar-color: var(--border) transparent;
}

.strip:focus-visible {
  outline: 2px solid var(--action);
  outline-offset: 2px;
  border-radius: 8px;
}

.shot {
  flex: 0 0 236px;
  margin: 0;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.shot figcaption {
  font-size: 0.95rem;
  line-height: 1.45;
  color: var(--muted);
  min-height: 5.8em;
}

.shot figcaption strong {
  display: block;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
}

.shot em {
  font-style: normal;
  color: var(--action);
}

.shot .phone {
  box-shadow: 0 16px 34px rgba(12, 12, 10, 0.22);
}

/* --- footer --------------------------------------------------------------------- */

.site-footer {
  max-width: 1080px;
  margin: 72px auto 0;
  padding: 24px 16px 56px;
}

.site-footer ul {
  list-style: none;
  padding: 0;
  margin: 0 0 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px 20px;
}

.site-footer li {
  margin: 0;
}

.languages a {
  color: var(--muted);
  text-decoration: none;
}

.languages a:hover {
  color: var(--text);
}

.languages a[aria-current] {
  color: var(--text);
  font-weight: 700;
}

.site-footer p {
  margin: 16px 0 0;
}

/* --- reduced motion: everything stands still; half the streak shown lit ---------- */

@media (prefers-reduced-motion: reduce) {
  .glows b,
  .stones i {
    animation: none;
  }

  .stones i:nth-child(-n + 11) {
    background: var(--sun);
  }

  .play {
    transition: none;
  }

  .hero-phone .motion {
    display: none;
  }

  .hero-phone .still {
    display: block;
  }
}

/* --- free and Plus (7.55, "keep it honest") ------------------------------------- */

.plan-grid {
  display: grid;
  gap: 16px;
}

@media (min-width: 760px) {
  .plan-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.plan {
  padding: 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
}

/* Plus wears the app's chip: the outlined lime pill. */
.plan-plus {
  border-color: var(--action);
}

.plan h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0 0 6px;
}

.chip {
  display: inline-block;
  padding: 1px 12px;
  border: 2px solid var(--action);
  border-radius: 999px;
  color: var(--action);
  font-size: 1rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.plan-lead {
  margin: 0 0 14px;
  color: var(--muted);
}

.plan ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.plan li {
  position: relative;
  padding-left: 28px;
  margin-bottom: 8px;
}

/* A check, drawn: the app's done mark. */
.plan li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 0.45em;
  width: 11px;
  height: 6px;
  border-left: 2px solid var(--action);
  border-bottom: 2px solid var(--action);
  transform: rotate(-45deg);
}

.plan-note {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}

/* --- the hero phone in 3D (the user, 1 Nov 2026) ------------------------------------
 * The face (screen and bezel) on a stack of 14 graphite slabs, 1 px apart in
 * depth, so the edge shows with its rounded corners as the phone turns; two
 * keys on the side. It sways slowly and turns toward the mouse (the inline
 * script sets --ry and --rx). Reduced motion: still, no turn. */

.p3d-sway {
  transform-style: preserve-3d;
  animation: p3d-sway 11s ease-in-out infinite alternate;
}

@keyframes p3d-sway {
  from {
    transform: rotateY(-4deg) translateY(4px);
  }

  to {
    transform: rotateY(5deg) translateY(-6px);
  }
}

.p3d-body {
  --ry: -18deg;
  --rx: 6deg;

  position: relative;
  transform-style: preserve-3d;
  transform: rotateX(var(--rx)) rotateY(var(--ry)) rotateZ(3deg);
  transition: transform 0.25s cubic-bezier(0.2, 0.7, 0.2, 1);
}



.p3d-face {
  position: relative;
  transform: translateZ(1px);
}

/* The face's sheen: light from the upper left. */
.p3d-face::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(125deg, rgba(255, 255, 255, 0.16) 0%, rgba(255, 255, 255, 0) 38%);
  pointer-events: none;
}

.slab {
  position: absolute;
  inset: 0;
  border-radius: 34px;
  background: linear-gradient(150deg, #4a4840, #24231e 45%, #2f2d27);
  transform: translateZ(calc(var(--k) * -1px));
}

/* The back plate, darker, carries the shadow. */
.slab:last-of-type {
  background: #141310;
  box-shadow: 0 30px 60px rgba(12, 12, 10, 0.4);
}

.key {
  position: absolute;
  right: -3px;
  width: 5px;
  border-radius: 3px;
  background: linear-gradient(90deg, #5c5a52, #2c2b26);
  transform: translateZ(-7px);
}

.key-power {
  top: 22%;
  height: 54px;
}

.key-volume {
  top: 36%;
  height: 92px;
}

@media (prefers-reduced-motion: reduce) {
  .p3d-sway {
    animation: none;
  }

  .p3d-body {
    transition: none;
  }
}

/* --- generated by build.mjs ------------------------------------------------ */

.stones i:nth-child(1) {
  --i: 0;
}

.stones i:nth-child(2) {
  --i: 1;
}

.stones i:nth-child(3) {
  --i: 2;
}

.stones i:nth-child(4) {
  --i: 3;
}

.stones i:nth-child(5) {
  --i: 4;
}

.stones i:nth-child(6) {
  --i: 5;
}

.stones i:nth-child(7) {
  --i: 6;
}

.stones i:nth-child(8) {
  --i: 7;
}

.stones i:nth-child(9) {
  --i: 8;
}

.stones i:nth-child(10) {
  --i: 9;
}

.stones i:nth-child(11) {
  --i: 10;
}

.stones i:nth-child(12) {
  --i: 11;
}

.stones i:nth-child(13) {
  --i: 12;
}

.stones i:nth-child(14) {
  --i: 13;
}

.stones i:nth-child(15) {
  --i: 14;
}

.stones i:nth-child(16) {
  --i: 15;
}

.stones i:nth-child(17) {
  --i: 16;
}

.stones i:nth-child(18) {
  --i: 17;
}

.slab:nth-child(1) {
  --k: 1;
}

.slab:nth-child(2) {
  --k: 2;
}

.slab:nth-child(3) {
  --k: 3;
}

.slab:nth-child(4) {
  --k: 4;
}

.slab:nth-child(5) {
  --k: 5;
}

.slab:nth-child(6) {
  --k: 6;
}

.slab:nth-child(7) {
  --k: 7;
}

.slab:nth-child(8) {
  --k: 8;
}

.slab:nth-child(9) {
  --k: 9;
}

.slab:nth-child(10) {
  --k: 10;
}

.slab:nth-child(11) {
  --k: 11;
}

.slab:nth-child(12) {
  --k: 12;
}

.slab:nth-child(13) {
  --k: 13;
}

.slab:nth-child(14) {
  --k: 14;
}

.chars-10 {
  --chars: 10;
}

.chars-11 {
  --chars: 11;
}

.chars-12 {
  --chars: 12;
}

.chars-13 {
  --chars: 13;
}

.chars-14 {
  --chars: 14;
}

.chars-15 {
  --chars: 15;
}

.chars-16 {
  --chars: 16;
}

.chars-17 {
  --chars: 17;
}

.chars-18 {
  --chars: 18;
}

.chars-19 {
  --chars: 19;
}

.chars-20 {
  --chars: 20;
}

.chars-21 {
  --chars: 21;
}

.chars-22 {
  --chars: 22;
}

.chars-23 {
  --chars: 23;
}

.chars-24 {
  --chars: 24;
}

.chars-25 {
  --chars: 25;
}

.chars-26 {
  --chars: 26;
}

.chars-27 {
  --chars: 27;
}

.chars-28 {
  --chars: 28;
}

.chars-29 {
  --chars: 29;
}

.chars-30 {
  --chars: 30;
}

.chars-31 {
  --chars: 31;
}

.chars-32 {
  --chars: 32;
}

.chars-33 {
  --chars: 33;
}

.chars-34 {
  --chars: 34;
}

.chars-35 {
  --chars: 35;
}

.chars-36 {
  --chars: 36;
}

.chars-37 {
  --chars: 37;
}

.chars-38 {
  --chars: 38;
}

.chars-39 {
  --chars: 39;
}

.chars-40 {
  --chars: 40;
}
