/* ─────────────────────────────────────────────────────────────────────────
   Once in a Weihl — global stylesheet
   Brand palette ported from the former Flutter theme (app_colors.dart /
   clean_cycle_colors.dart). Light/dark via prefers-color-scheme, with an
   explicit [data-theme] override set by the theme toggle in web/app.js.
   ───────────────────────────────────────────────────────────────────────── */

/* Bundled brand fonts — no runtime CDN fetch. */
@font-face {
  font-family: 'Playfair Display';
  src: url('/fonts/PlayfairDisplay-VF.ttf') format('truetype');
  font-weight: 400 900;
  font-display: swap;
}
@font-face {
  font-family: 'Playfair Display';
  src: url('/fonts/PlayfairDisplay-Italic-VF.ttf') format('truetype');
  font-weight: 400 900;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: 'DM Sans';
  src: url('/fonts/DMSans-VF.ttf') format('truetype');
  font-weight: 100 1000;
  font-display: swap;
}
@font-face {
  font-family: 'DM Mono';
  src: url('/fonts/DMMono-Regular.ttf') format('truetype');
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: 'DM Mono';
  src: url('/fonts/DMMono-Medium.ttf') format('truetype');
  font-weight: 500;
  font-display: swap;
}
/* CleanCycle brand fonts: Quicksand (display) + Nunito Sans (body). */
@font-face {
  font-family: 'Quicksand';
  src: url('/fonts/Quicksand-VF.ttf') format('truetype');
  font-weight: 300 700;
  font-display: swap;
}
@font-face {
  font-family: 'Nunito Sans';
  src: url('/fonts/NunitoSans-VF.ttf') format('truetype');
  font-weight: 200 1000;
  font-display: swap;
}

/* ── Palette: studio (Atelier) ──────────────────────────────────────────── */
:root {
  --bg: #f5f0e8;
  --ink: #1a1612;
  --muted: #8a8070;
  --accent: #c4490c;
  --gold: #d4a843;
  --card: #edeae0;
  --border: #c8c2b4;
  --ink-bg: #1a1612;
  --ink-bg-text: #ede8df;

  --serif: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --sans: 'DM Sans', system-ui, -apple-system, sans-serif;
  --mono: 'DM Mono', ui-monospace, monospace;

  --maxw: 1080px;
  --radius: 18px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #13100e;
    --ink: #ede8df;
    --muted: #9a8e7c;
    --accent: #e05a1a;
    --gold: #d4a843;
    --card: #1c1814;
    --border: #2c2620;
    --ink-bg: #0d0b09;
    --ink-bg-text: #ede8df;
  }
}

:root[data-theme='light'] {
  --bg: #f5f0e8;
  --ink: #1a1612;
  --muted: #8a8070;
  --accent: #c4490c;
  --gold: #d4a843;
  --card: #edeae0;
  --border: #c8c2b4;
  --ink-bg: #1a1612;
  --ink-bg-text: #ede8df;
}
:root[data-theme='dark'] {
  --bg: #13100e;
  --ink: #ede8df;
  --muted: #9a8e7c;
  --accent: #e05a1a;
  --gold: #d4a843;
  --card: #1c1814;
  --border: #2c2620;
  --ink-bg: #0d0b09;
  --ink-bg-text: #ede8df;
}

/* ── Palette: CleanCycle (Puls) — scoped to .cc ─────────────────────────── */
.cc {
  --bg: #eef6f0;
  --ink: #0f2a20;
  --muted: #5e7a6e;
  --accent: #12a06e;
  --gold: #4fc79e;
  --card: #ffffff;
  --soft: #e4f1ea;
  --border: #d7e7df;
  --panel: #0c231b;
  --panel-ink: #eaf6f0;
}
@media (prefers-color-scheme: dark) {
  .cc {
    --bg: #0c1a15;
    --ink: #e6f2ec;
    --muted: #7f9c8e;
    --accent: #34c794;
    --gold: #5fd9af;
    --card: #14241d;
    --soft: #10201a;
    --border: #22382e;
    --panel: #06140f;
    --panel-ink: #e6f2ec;
  }
}
:root[data-theme='light'] .cc {
  --bg: #eef6f0; --ink: #0f2a20; --muted: #5e7a6e; --accent: #12a06e; --gold: #4fc79e;
  --card: #ffffff; --soft: #e4f1ea; --border: #d7e7df; --panel: #0c231b; --panel-ink: #eaf6f0;
}
:root[data-theme='dark'] .cc {
  --bg: #0c1a15; --ink: #e6f2ec; --muted: #7f9c8e; --accent: #34c794; --gold: #5fd9af;
  --card: #14241d; --soft: #10201a; --border: #22382e; --panel: #06140f; --panel-ink: #e6f2ec;
}

/* CleanCycle uses Quicksand (display) + Nunito Sans (body); labels stay DM Mono. */
.cc { --serif: 'Quicksand', system-ui, sans-serif; --sans: 'Nunito Sans', system-ui, sans-serif; font-family: var(--sans); }

/* CleanCycle status accents (device states) — layered on top of the .cc vars. */
.cc { --coral: #f2765b; --sun: #e2a12e; --sky: #4c9bd6; --light: #4fc79e; }
@media (prefers-color-scheme: dark) {
  .cc { --coral: #f2876b; --sun: #e9be5a; --sky: #6fb4e6; --light: #5fd9af; }
}
:root[data-theme='light'] .cc { --coral: #f2765b; --sun: #e2a12e; --sky: #4c9bd6; --light: #4fc79e; }
:root[data-theme='dark'] .cc { --coral: #f2876b; --sun: #e9be5a; --sky: #6fb4e6; --light: #5fd9af; }

/* ── Reset & base ───────────────────────────────────────────────────────── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  transition: background 0.3s ease, color 0.3s ease;
}

.cc { background: var(--bg); color: var(--ink); }

h1, h2, h3 { font-family: var(--serif); line-height: 1.1; font-weight: 700; }

a { color: inherit; text-decoration: none; }

img { max-width: 100%; display: block; }

.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

.eyebrow {
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}

.section { padding: 96px 0; }
.section__title { font-size: clamp(1.8rem, 4vw, 2.8rem); margin-bottom: 16px; }
.section__title--italic { font-style: italic; }
.section__sub { color: var(--muted); font-size: 1.1rem; max-width: 60ch; margin-bottom: 40px; }
.section--ink .eyebrow { color: var(--gold); }
/* Centered section header (how / faq / get / more, as in the Puls design). */
.section--center { text-align: center; }
.section--center .section__sub { margin-left: auto; margin-right: auto; }

/* ── Nav ────────────────────────────────────────────────────────────────── */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.nav__inner { max-width: var(--maxw); margin: 0 auto; padding: 14px 24px;
  display: flex; align-items: center; justify-content: space-between; }
.nav__brand { font-family: var(--serif); font-weight: 700; font-size: 1.15rem; }
.nav__brand--cc { display: inline-flex; align-items: center; gap: 10px; }
.nav__brand--home { display: inline-flex; align-items: center; gap: 10px; font-style: italic; }
.nav__logo { width: 30px; height: 30px; border-radius: 8px; display: block;
  box-shadow: 0 6px 16px -4px color-mix(in srgb, var(--accent) 55%, transparent); }
/* Studio "W" monogram: dark rounded square with a rust circle outline. */
.logo-mark { position: relative; width: 30px; height: 30px; border-radius: 7px; flex: none;
  background: var(--ink-bg); color: var(--ink-bg-text); display: grid; place-items: center;
  font-family: var(--serif); font-style: italic; font-weight: 700; font-size: 14px; }
.logo-mark::before { content: ''; position: absolute; inset: 5px; border: 1.4px solid var(--accent); border-radius: 50%; }
.nav__links { display: flex; align-items: center; gap: 22px; }
.nav__links a:not(.btn) { color: var(--muted); font-family: var(--mono); font-size: 0.82rem; letter-spacing: 0.03em; transition: color 0.2s; }
.nav__links a:not(.btn):hover { color: var(--ink); }
/* CleanCycle nav links use Quicksand. */
.cc .nav__links a:not(.btn) { font-family: var(--serif); font-size: 0.92rem; letter-spacing: 0; }
/* Primary CTA in the nav keeps its own (white-on-accent) colour. */
.nav__links .btn--primary { color: #fff; }
.theme-toggle {
  background: none; border: 1px solid var(--border); color: var(--ink);
  width: 34px; height: 34px; border-radius: 50%; cursor: pointer; font-size: 1rem;
}
.nav__lang {
  font-family: var(--mono); font-size: 0.8rem; letter-spacing: 0.08em;
  border: 1px solid var(--border); border-radius: 999px; padding: 4px 10px;
}

/* ── Buttons ────────────────────────────────────────────────────────────── */
.btn {
  display: inline-block; padding: 13px 26px; border-radius: 999px;
  font-family: var(--mono); font-weight: 500; font-size: 0.85rem; letter-spacing: 0.02em;
  cursor: pointer; border: 1px solid transparent;
  transition: transform 0.15s ease, opacity 0.2s ease;
}
.btn:hover { transform: translateY(-2px); }
/* CleanCycle buttons use Quicksand bold, not DM Mono. */
.cc .btn { font-family: var(--serif); font-weight: 700; font-size: 0.98rem; letter-spacing: 0; }
.btn--primary { background: var(--accent); color: #fff; }
.btn--ghost { background: transparent; border-color: var(--border); color: var(--ink); }
.btn--sm { padding: 8px 16px; font-size: 0.9rem; }
.btn--lg { padding: 16px 34px; font-size: 1.05rem; }

/* ── Hero ───────────────────────────────────────────────────────────────── */
.hero { padding: 120px 0 80px; }
/* Left-aligned at every width, as in the Atelier design (the old Flutter hero
   used CrossAxisAlignment.start on narrow screens too). */
.hero__title { font-size: clamp(2.6rem, 7vw, 5rem); margin-bottom: 20px; }
.hero__sub { color: var(--muted); font-size: 1.2rem; margin: 0 0 32px; max-width: 60ch; }
.hero__cta { display: flex; gap: 14px; flex-wrap: wrap; }
/* Eyebrow pill with pulsing dot (as in the Atelier hero). */
.hero__eyebrow { display: inline-flex; align-items: center; gap: 8px; text-transform: none;
  letter-spacing: 0.06em; border: 1px solid var(--border); border-radius: 999px; padding: 6px 14px; }
.hero__eyebrow::before { content: ''; width: 8px; height: 8px; border-radius: 50%; flex: none;
  background: var(--accent); animation: pulse-dot 2s ease-in-out infinite; }
@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 45%, transparent); }
  50% { box-shadow: 0 0 0 6px transparent; }
}

.cc-hero { padding: 130px 0 90px; text-align: center; }
.cc-hero__inner { max-width: 760px; }
.cc-hero__title { font-size: clamp(2.6rem, 7vw, 4.6rem); margin: 18px 0 20px; }
.cc-hero__em { color: var(--accent); }
.cc-hero__sub { color: var(--muted); font-size: 1.2rem; margin: 0 auto 34px; max-width: 55ch; }
.badge {
  display: inline-block; font-family: var(--mono); font-size: 0.8rem; letter-spacing: 0.12em;
  padding: 6px 14px; border-radius: 999px; background: var(--soft, var(--card));
  color: var(--accent); border: 1px solid var(--border);
}

/* ── Marquee ────────────────────────────────────────────────────────────── */
.marquee { overflow: hidden; background: var(--ink-bg); color: var(--ink-bg-text); padding: 18px 0; }
.marquee__track { display: flex; gap: 40px; width: max-content; animation: marquee 32s linear infinite; }
.marquee__item { font-family: var(--serif); font-style: italic; font-size: 1rem; white-space: nowrap; opacity: 0.85; }
.marquee__item::after { content: '✦'; margin-left: 40px; color: var(--accent); font-style: normal; font-size: 0.7rem; vertical-align: middle; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ── Apps grid (studio) ─────────────────────────────────────────────────── */
.app-grid { display: grid; gap: 28px; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.app-card {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 32px;
}
.app-card__head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.app-card__head h3 { font-size: 1.5rem; }
.tag { font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.08em; color: var(--muted); text-transform: uppercase; }
.app-card__desc { color: var(--muted); margin-bottom: 18px; }
.feature-list { list-style: none; margin-bottom: 20px; }
.feature-list li { position: relative; padding-left: 22px; margin-bottom: 8px; font-size: 0.95rem; }
.feature-list li::before { content: '✦'; position: absolute; left: 0; color: var(--accent); font-size: 0.8rem; }
.app-card__foot { display: flex; align-items: center; justify-content: space-between; gap: 12px;
  border-top: 1px solid var(--border); padding-top: 16px; }
.status { font-family: var(--mono); font-size: 0.78rem; color: var(--muted); }
.link-arrow { color: var(--accent); font-weight: 600; }

/* ── About ──────────────────────────────────────────────────────────────── */
.section--ink { background: var(--ink-bg); color: var(--ink-bg-text); position: relative; overflow: hidden; }
.section--ink .section__title { color: var(--ink-bg-text); }
/* Decorative circles bleeding out of the top-right corner (Atelier design):
   a solid rust outline and a dashed gold one. */
.about-deco { position: absolute; top: -120px; right: -120px; width: 420px; height: 420px; pointer-events: none; }
.about-deco::before { content: ''; position: absolute; inset: 0; border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent); }
.about-deco::after { content: ''; position: absolute; inset: 120px 0 0 120px; border-radius: 50%;
  border: 1px dashed color-mix(in srgb, var(--gold) 26%, transparent); }
.about { display: grid; grid-template-columns: 1.6fr 1fr; gap: 80px; align-items: start; position: relative; }
.about__text p { color: color-mix(in srgb, var(--ink-bg-text) 82%, transparent); margin-bottom: 14px; }
.about__stats { display: grid; gap: 34px; align-content: start; }
.stat { display: flex; flex-direction: column; }
.stat__value { font-family: var(--serif); font-size: 2.4rem; color: var(--gold); }
.section--ink .stat__value { font-style: italic; }
.stat__label { font-family: var(--mono); font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase; opacity: 0.8; }
/* About stats per the Atelier design: rust left border, large cream italic
   value, plain mono label. */
.about__stats .stat { border-left: 2px solid var(--accent); padding-left: 20px; }
.about__stats .stat__value { color: var(--ink-bg-text); font-size: clamp(2.75rem, 5vw, 3.75rem); line-height: 1; }
.about__stats .stat__label { text-transform: none; letter-spacing: 0.03em; opacity: 0.6; }

/* ── Contact ────────────────────────────────────────────────────────────── */
.contact { text-align: center; max-width: 640px; margin: 0 auto; }
.contact__sub { color: var(--muted); margin-bottom: 40px; }
.contact__divider { display: flex; align-items: center; gap: 18px; max-width: 320px; margin: 30px auto; }
.contact__rule { flex: 1; height: 1px; background: var(--border); }
.contact__or { font-family: var(--mono); font-size: 0.8rem; color: var(--muted); letter-spacing: 0.08em; }
.email-chip { display: inline-flex; align-items: center; gap: 8px; font-family: var(--mono); font-size: 0.85rem;
  color: var(--muted); border: 1px solid var(--border); border-radius: 999px; padding: 10px 18px; background: var(--card);
  transition: color 0.2s, border-color 0.2s; }
.email-chip:hover { color: var(--ink); border-color: var(--accent); }

/* ── CleanCycle: cards / steps / shots / faq / store ────────────────────── */
.section--soft { background: var(--soft, var(--card)); }
.section--panel { background: var(--panel, var(--ink-bg)); color: var(--panel-ink, var(--ink-bg-text)); }
.section--panel .section__title { color: var(--panel-ink, var(--ink-bg-text)); }
.section--panel .section__sub { color: color-mix(in srgb, var(--panel-ink) 78%, transparent); }

.prose { max-width: 68ch; font-size: 1.15rem; color: var(--muted); }

.card-grid { display: grid; gap: 24px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.card { position: relative; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; }
.card__soon { position: absolute; top: 16px; right: 16px; font-family: var(--mono); font-size: 0.68rem;
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent);
  background: var(--soft, var(--card)); border: 1px solid var(--border); border-radius: 999px; padding: 4px 10px; }
.card__icon { font-size: 2rem; display: block; margin-bottom: 12px; }
.card h3 { font-size: 1.25rem; margin-bottom: 8px; }
.card p { color: var(--muted); font-size: 0.98rem; }

.steps { list-style: none; counter-reset: step; display: grid; gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.step { counter-increment: step; background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 28px; position: relative; }
.step::before { content: counter(step); font-family: var(--serif); font-size: 2rem; color: var(--accent);
  display: block; margin-bottom: 10px; }
.step h3 { font-size: 1.2rem; margin-bottom: 6px; }
.step p { color: var(--muted); }

.shots-wrap { text-align: center; }
.shots-wrap .section__sub { margin-left: auto; margin-right: auto; }
.themes-shot { width: 100%; max-width: 680px; height: auto; margin: 8px auto 0; display: block;
  border-radius: 14px; filter: drop-shadow(0 20px 44px rgba(12, 60, 42, 0.28)); }

/* Full-width brand-green band with three quick stats (below the takt wave). */
.ribbon { background: var(--accent); color: #fff; padding: 17px 0; }
.ribbon__inner { display: flex; justify-content: center; align-items: center; gap: 16px 56px; flex-wrap: wrap; }
.ribbon__stat { display: inline-flex; align-items: center; gap: 11px; }
.ribbon__value { font-family: var(--serif); font-weight: 700; font-size: 1.7rem; }
.ribbon__label { font-family: var(--sans); font-size: 0.85rem; font-weight: 600; line-height: 1.25; max-width: 150px; opacity: 0.92; }

/* Thin reading-progress bar at the very top (CSS scroll-driven animation;
   browsers without support simply never show it). */
.scroll-progress { position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 60;
  background: var(--accent); transform-origin: 0 50%; transform: scaleX(0); }
@supports (animation-timeline: scroll()) {
  .scroll-progress { animation: scroll-progress linear both; animation-timeline: scroll(root); }
}
@keyframes scroll-progress { from { transform: scaleX(0); } to { transform: scaleX(1); } }

.stat-row { display: flex; gap: 48px; flex-wrap: wrap; }
.stat-row .stat__value { color: var(--gold); }

/* Privacy panel: text + stats beside the Family Sync screenshot. */
.privacy { display: grid; grid-template-columns: 1fr; gap: 40px; align-items: center; }
@media (min-width: 900px) { .privacy { grid-template-columns: 1fr 300px; gap: 56px; } }
.privacy__main .stat-row { margin-top: 28px; }
.privacy__phone { display: flex; justify-content: center; }

.faq { max-width: 760px; margin: 0 auto; text-align: left; }
.faq__item { border-bottom: 1px solid var(--border); padding: 6px 0; }
.faq__item summary { cursor: pointer; font-weight: 600; padding: 16px 0; list-style: none; font-size: 1.05rem; }
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after { content: '+'; float: right; color: var(--accent); font-size: 1.3rem; }
.faq__item[open] summary::after { content: '−'; }
.faq__item p { color: var(--muted); padding: 0 0 18px; }

/* Store chips per the Puls design: translucent pill on the dark panel,
   brand logo left, two-line label right. */
.store-badges { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
/* On the dark CleanCycle panel the chip inks in panel-ink; on the light studio
   app cards --panel-ink is unset and it falls back to the page ink. */
.store-badge { --badge-ink: var(--panel-ink, var(--ink));
  display: inline-flex; align-items: center; gap: 11px; color: var(--badge-ink);
  background: color-mix(in srgb, var(--badge-ink) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--badge-ink) 22%, transparent);
  padding: 13px 24px; border-radius: 100px; transition: transform 0.15s ease, background 0.15s ease; }
.store-badge:hover { transform: translateY(-2px);
  background: color-mix(in srgb, var(--badge-ink) 18%, transparent); }
.store-badge[hidden] { display: none; }
.store-badges--card { justify-content: flex-start; margin-bottom: 20px; }
.store-badge__icon { width: 23px; height: 23px; flex: none; }
.store-badge__text { display: flex; flex-direction: column; align-items: flex-start; text-align: left; }
.store-badge__note { font-family: var(--mono); font-size: 0.63rem; letter-spacing: 0.03em;
  text-transform: uppercase; opacity: 0.7; }
.store-badge__name { font-family: var(--serif); font-weight: 700; font-size: 1rem; line-height: 1.15; }

/* ── Footer ─────────────────────────────────────────────────────────────── */
.footer { border-top: 1px solid var(--border); padding: 32px 0; }
.footer__inner { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap;
  font-family: var(--mono); font-size: 0.82rem; letter-spacing: 0.02em; color: var(--muted); }
.footer__inner a:hover { color: var(--accent); }

/* ── Hero orbit graphic (studio) ────────────────────────────────────────── */
.hero__inner { max-width: var(--maxw); display: grid; grid-template-columns: 1fr; gap: 36px; align-items: center; }
.hero__art { display: none; }
@media (min-width: 900px) {
  .hero__inner { grid-template-columns: 1.05fr 0.95fr; }
  .hero__art { display: block; }
}

/* Brand wordmark hero title: "Once / in a / Weihl." */
.wordmark { display: flex; flex-direction: column; align-items: flex-start; font-family: var(--serif);
  font-style: italic; font-weight: 700; line-height: 0.9; letter-spacing: -1px; margin-bottom: 20px; }
.wordmark__1 { color: var(--ink); font-size: clamp(3.4rem, 8vw, 6.75rem); }
.wordmark__2 { color: var(--muted); font-weight: 600; font-size: clamp(2rem, 4.8vw, 4rem); padding-left: 0.12em; }
.wordmark__3 { color: var(--accent); font-size: clamp(3.4rem, 8vw, 6.75rem); }
.wordmark__dot { color: var(--gold); }

.orbit { position: relative; justify-self: center; width: min(380px, 82vw); aspect-ratio: 1; }
.orbit__svg { width: 100%; height: 100%; display: block; }
.orbit__disc { fill: var(--gold); opacity: 0.09; }
.orbit__ring { fill: none; stroke: var(--accent); stroke-opacity: 0.22; stroke-width: 1.5; }
.orbit__ticks { fill: none; stroke: var(--accent); stroke-opacity: 0.32; stroke-width: 2; stroke-linecap: round; stroke-dasharray: 1.5 16; }
.orbit__dot { fill: var(--accent); }
.orbit__dash { fill: none; stroke: var(--gold); stroke-opacity: 0.5; stroke-width: 1.5; stroke-dasharray: 9 13; }
.orbit__arc { fill: none; stroke: var(--accent); stroke-opacity: 0.65; stroke-width: 2.5; stroke-linecap: round;
  stroke-dasharray: 34 670; transform-box: fill-box; transform-origin: center; transform: rotate(38deg); }
.orbit__center { fill: var(--card); stroke: var(--border); stroke-width: 1.5; }
.orbit__outer { transform-box: fill-box; transform-origin: center; animation: spin 30s linear infinite; }
.orbit__mid { transform-box: fill-box; transform-origin: center; animation: spin-rev 22s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes spin-rev { to { transform: rotate(-360deg); } }
.orbit__text { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; pointer-events: none; }
.orbit__line { font-family: var(--serif); font-style: italic; font-weight: 700; font-size: 1.25rem; line-height: 1.3; color: var(--ink); }
.orbit__line--accent { color: var(--accent); }

/* ── Phone mockups ──────────────────────────────────────────────────────── */
.phone { width: 200px; max-width: 58vw; aspect-ratio: 200 / 410; background: var(--card); border: 1px solid var(--border);
  border-radius: 32px; padding: 8px; box-shadow: 0 20px 44px -24px rgba(0, 0, 0, 0.35); position: relative; flex: none; }
.phone::before { content: ''; position: absolute; top: 7px; left: 50%; transform: translateX(-50%);
  width: 42px; height: 5px; border-radius: 5px; background: var(--border); z-index: 2; }
.phone__screen { position: relative; width: 100%; height: 100%; border-radius: 24px; overflow: hidden; background: var(--bg); }
.phone__screen img { width: 100%; height: 100%; object-fit: cover; object-position: top center; display: block; }

/* Screenshots that already ship with their own device frame — shown directly,
   no extra CSS bezel. They carry an opaque light background out to the edges,
   so we clip to the frame's own corner radius (~31px in the 480px-wide asset)
   to drop the square corners; drop-shadow then follows the rounded shape. */
.device-shot { width: 210px; max-width: 60vw; height: auto; display: block;
  border-radius: 15px; filter: drop-shadow(0 22px 42px rgba(0, 0, 0, 0.28)); }

/* Foxtrove stylised in-app mock (studio palette: rust + petrol + gold). */
.phone__screen.fx { padding: 16px 12px; display: flex; flex-direction: column; gap: 9px; }
.fx-total { background: color-mix(in srgb, var(--accent) 8%, transparent); border-radius: 8px; padding: 10px 12px; display: flex; flex-direction: column; gap: 4px; }
.fx-bar { border-radius: 3px; }
.fx-bar--sm { width: 42%; height: 6px; background: var(--border); }
.fx-bar--lg { width: 66%; height: 14px; background: color-mix(in srgb, var(--accent) 55%, transparent); }
.fx-row { display: flex; align-items: center; gap: 12px; padding: 2px 4px; }
.fx-donut { width: 46px; height: 46px; border-radius: 50%; flex: none;
  background: conic-gradient(var(--accent) 0 40%, #2a6f7e 40% 74%, var(--gold) 74% 100%);
  -webkit-mask: radial-gradient(circle at center, transparent 0 12px, #000 12px);
  mask: radial-gradient(circle at center, transparent 0 12px, #000 12px); }
.fx-legend { display: flex; flex-direction: column; gap: 6px; flex: 1; }
.fx-leg { height: 6px; border-radius: 3px; background: var(--border); }
.fx-leg:nth-child(1) { width: 72%; } .fx-leg:nth-child(2) { width: 56%; } .fx-leg:nth-child(3) { width: 40%; }
.fx-tile { display: flex; align-items: center; gap: 8px; background: var(--card); border-radius: 7px; padding: 8px; }
.fx-tile__icon { width: 12px; height: 16px; border-radius: 2px; background: rgba(42, 111, 126, 0.35); flex: none; }
.fx-tile__line { height: 6px; border-radius: 3px; background: var(--border); flex: 1; }
.fx-tile__amt { width: 34px; height: 8px; border-radius: 3px; background: color-mix(in srgb, var(--accent) 50%, transparent); flex: none; }

/* ── App cards with a preview (studio) ──────────────────────────────────── */
.app-grid { grid-template-columns: 1fr; max-width: 920px; margin: 0 auto; }
.apps__head { display: flex; align-items: baseline; gap: 18px; margin-bottom: 44px; }
.apps__index { font-family: var(--mono); font-size: 0.85rem; color: var(--accent); }
.apps__head .section__title { margin-bottom: 0; }
.apps__rule { flex: 1; height: 1px; background: var(--border); align-self: center; }
.platforms { display: flex; flex-wrap: wrap; gap: 10px; margin: 4px 0 20px; }
.platform { display: inline-flex; align-items: center; gap: 7px; font-family: var(--mono); font-size: 0.72rem;
  color: var(--muted); border: 1px solid var(--border); border-radius: 999px; padding: 5px 12px; }
.platform[hidden] { display: none; }
/* Collapse the pill row entirely once every platform is ready. */
.platforms:not(:has(.platform:not([hidden]))) { display: none; }
.platform__dot { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); flex: none; }
.platform.is-ready .platform__dot { background: #4db88a; }
.platform.is-testing .platform__dot { background: var(--accent); }
.platform.is-brewing .platform__dot { background: var(--gold); }
.platform.is-planned .platform__dot { background: var(--muted); }
.app-card { padding: 0; overflow: hidden; display: grid; grid-template-columns: 1fr; }
.app-card__media { display: flex; align-items: center; justify-content: center; padding: 34px 24px;
  background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 8%, var(--card)), var(--card)); }
.app-card__body { padding: 28px 32px 32px; }
@media (min-width: 720px) {
  .app-card { grid-template-columns: 300px 1fr; align-items: stretch; }
  .app-card__media { padding: 40px 24px; }
  .app-card__body { padding: 40px 40px 40px 12px; align-self: center; }
}

/* ── Takt wave (CleanCycle timeline animation) ──────────────────────────── */
.takt-section { padding: 32px 0 76px; }
.takt__head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.takt__label { font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.1em; color: var(--muted); }
.takt__label--now { color: var(--accent); }
.takt__wave { position: relative; width: 100%; height: clamp(190px, 26vw, 300px); overflow: visible; }
.takt__svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.takt__line { fill: none; stroke: var(--border); stroke-width: 3; vector-effect: non-scaling-stroke; }
.takt__travel { fill: none; stroke: var(--accent); stroke-width: 3.5; stroke-linecap: round; vector-effect: non-scaling-stroke;
  stroke-dasharray: 70 930; animation: takt-travel 6s linear infinite; }
@keyframes takt-travel { from { stroke-dashoffset: 0; } to { stroke-dashoffset: -1000; } }
.takt__now { stroke: var(--accent); stroke-opacity: 0.3; stroke-width: 2; stroke-dasharray: 4 6; vector-effect: non-scaling-stroke; }
.takt__beat { position: absolute; width: 22px; height: 22px; display: grid; place-items: center; transform: translate(-50%, -50%); }
.takt__beat.is-overdue { --beat: var(--coral); }
.takt__beat.is-today { --beat: var(--accent); }
.takt__beat.is-soon { --beat: var(--sun); }
.takt__beat.is-ok { --beat: var(--light); }
.takt__dot { width: 15px; height: 15px; border-radius: 50%; background: var(--beat); border: 3px solid var(--bg); box-sizing: content-box; }
.takt__beat.is-active .takt__dot { width: 18px; height: 18px; animation: takt-pulse 1.8s ease-in-out infinite; }
@keyframes takt-pulse {
  0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--beat) 55%, transparent); }
  70%, 100% { box-shadow: 0 0 0 13px transparent; }
}
.takt__tip { position: absolute; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 1px; width: max-content; }
.takt__tip--above { bottom: calc(100% + 5px); }
.takt__tip--below { top: calc(100% + 5px); }
.takt__emoji { font-size: 19px; line-height: 1; }
.takt__due { font-family: var(--mono); font-size: 10px; font-weight: 500; color: var(--muted); }

/* ── Device tracks (CleanCycle) ─────────────────────────────────────────── */
.tracks { display: grid; grid-template-columns: 1fr; gap: 40px; align-items: center; }
@media (min-width: 900px) { .tracks { grid-template-columns: 1fr 300px; gap: 56px; } }
.tracks__card { margin-top: 30px; background: var(--card); border: 1px solid var(--border); border-radius: 20px; padding: 6px 20px; }
.tracks__phone { display: flex; justify-content: center; }
.track { display: grid; grid-template-columns: 44px 1fr auto; grid-template-areas: 'icon meta chip' 'bar bar bar';
  gap: 8px 16px; align-items: center; padding: 16px 4px; }
.track + .track { border-top: 1px solid var(--border); }
.track.is-overdue { --beat: var(--coral); }
.track.is-today { --beat: var(--accent); }
.track.is-soon { --beat: var(--sun); }
.track.is-ok { --beat: var(--light); }
.track__icon { grid-area: icon; width: 44px; height: 44px; border-radius: 14px; background: var(--soft); display: grid; place-items: center; font-size: 22px; }
.track__meta { grid-area: meta; display: flex; flex-direction: column; min-width: 0; }
.track__name { font-family: var(--serif); font-weight: 700; font-size: 0.98rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.track__every { font-family: var(--mono); font-size: 0.7rem; color: var(--muted); }
.track__chip { grid-area: chip; font-size: 0.68rem; font-weight: 800; color: #fff; padding: 4px 11px; border-radius: 100px;
  background: var(--beat, var(--accent)); white-space: nowrap; }
.track__bar { grid-area: bar; position: relative; height: 8px; border-radius: 5px; background: var(--soft); margin-top: 4px; }
.track__fill { position: absolute; left: 0; top: 0; height: 100%; border-radius: 5px; background: color-mix(in srgb, var(--beat) 35%, transparent); }
.track__dot { position: absolute; top: 50%; width: 16px; height: 16px; border-radius: 50%; background: var(--beat);
  border: 3px solid var(--card); transform: translate(-50%, -50%); box-shadow: 0 4px 10px color-mix(in srgb, var(--beat) 55%, transparent); }
@media (min-width: 640px) {
  .track { grid-template-columns: 44px 172px 1fr auto; grid-template-areas: 'icon meta bar chip'; }
  .track__bar { margin-top: 0; }
}

/* ── Responsive ─────────────────────────────────────────────────────────── */
@media (max-width: 760px) {
  .section { padding: 64px 0; }
  .about { grid-template-columns: 1fr; gap: 60px; }
  .nav__links { gap: 14px; }
  /* Keep the language toggle reachable on mobile; only hide the in-page anchors. */
  .nav__links a:not(.btn):not(.nav__lang) { display: none; }
  /* The "Get it" CTA is redundant on mobile (the hero button covers it). */
  .nav__cta { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; scroll-behavior: auto !important; transition: none !important; }
}
