/* ---------- tokens (the only source of color / radius / motion) ---------- */
:root {
  --bg: #F7F5EF;
  --ink: #141414;
  --ink-soft: #5C5C5C;        /* AA 5.8:1 on bone, use on --bg only */
  --ink-on-pastel: #3D3D3D;   /* AA 7:1+ on the pastel blocks */
  --berri: #6464D1;
  --berri-press: #5757C4;
  --sen-dark: #1D1D52;
  --sen-light: #E5E5FE;
  --block-salmon: #FAC7BE;
  --block-lilac: #CDCDF9;
  --block-yellow: #FFD386;
  --block-blue: #B7D9F8;
  --block-green: #B7DFBA;
  --wa-user: #D9FDD3;
  --wa-user-ink: #10261B;
  --wa-head: #fbf8f3;
  --r-card: 20px;
  --r-pill: 999px;
  --r-bubble: 16px; /* WhatsApp-artifact bubbles only */
  --shadow-soft: 0 24px 48px -16px rgba(29, 29, 82, 0.22);
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
  --pad-x: clamp(18px, 4vw, 56px);
}

* { margin: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: "Rethink Sans", system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; }
h1, h2, h3 { font-weight: 800; letter-spacing: -0.03em; line-height: 1.04; }
:focus-visible { outline: 3px solid var(--berri); outline-offset: 3px; border-radius: 4px; }
.btn:focus-visible, .manifesto :focus-visible { outline-color: var(--ink); }
.manifesto a:focus-visible, .manifesto button:focus-visible { outline-color: #fff; }

/* ---------- reveal system: visible by default, JS opts elements in ---------- */
.r { opacity: 1; transform: none; }
.js .r.pre { opacity: 0; transform: translateY(16px); }
.js .r.in { opacity: 1; transform: none; transition: opacity 0.6s var(--ease-out), transform 0.6s var(--ease-out); transition-delay: var(--rd, 0s); }
.b-r { opacity: 1; transform: none; }
.js .chat.armed .b-r { opacity: 0; transform: translateY(10px) scale(0.97); }
.js .chat.play .b-r { opacity: 1; transform: none; transition: opacity 0.45s var(--ease-out), transform 0.45s var(--ease-out); transition-delay: var(--bd, 0s); }

/* ---------- nav (fixed; the hero wordmark morphs into .brand; condenses into a pill on scroll) ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 12px var(--pad-x); min-height: 64px;
  border-radius: var(--r-pill);
  /* hidden at the top of the page; only the pill appears on scroll (all widths) */
  opacity: 0; visibility: hidden; transform: translateY(-12px);
  transition: background-color 0.25s ease, box-shadow 0.25s ease,
    top 0.25s var(--ease-out), left 0.25s var(--ease-out), right 0.25s var(--ease-out),
    padding 0.25s var(--ease-out), opacity 0.25s ease,
    transform 0.25s var(--ease-out), visibility 0s linear 0.25s;
}
.nav.pill {
  top: 10px;
  /* half the viewport wide, centered; never narrower than the content needs (~640px) */
  left: max(14px, min(25vw, 50vw - 320px));
  right: max(14px, min(25vw, 50vw - 320px));
  padding: 8px 20px;
  background: rgba(247, 245, 239, 0.7); backdrop-filter: blur(10px);
  box-shadow: var(--shadow-soft);
  opacity: 1; visibility: visible; transform: none;
  transition: background-color 0.25s ease, box-shadow 0.25s ease,
    top 0.25s var(--ease-out), left 0.25s var(--ease-out), right 0.25s var(--ease-out),
    padding 0.25s var(--ease-out), opacity 0.25s ease,
    transform 0.25s var(--ease-out), visibility 0s;
}
.brand img { height: 20px; width: auto; display: block; }
section[id], .hero { scroll-margin-top: 88px; }
.nav-links { display: flex; gap: 12px; }
@media (min-width: 981px) {
  .nav-links { position: absolute; left: 50%; transform: translateX(-50%); }
}
.nav .btn span { display: block; max-width: 170px; white-space: nowrap; overflow: hidden; transition: max-width 0.25s var(--ease-out), opacity 0.2s ease; }
.nav.pill .btn span { max-width: 0; opacity: 0; }
.nav.pill .btn { padding: 12px; gap: 0; }
.nav-links a { font-size: 15px; font-weight: 700; color: var(--ink); text-decoration: none; padding: 12px 8px; }
.nav-links a:hover { color: var(--berri-press); }
.nav-right { display: flex; align-items: center; gap: 10px; }
.lang {
  font-size: 14px; font-weight: 600; color: var(--ink-soft); letter-spacing: 0.02em;
  background: none; border: 0; padding: 13px 10px; cursor: pointer; font-family: inherit;
  white-space: nowrap;
}
.lang strong { color: var(--ink); }
.lang:hover strong { color: var(--berri-press); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--berri); color: #fff;
  border-radius: var(--r-pill); padding: 12px 22px;
  font-weight: 700; font-size: 15px; text-decoration: none;
  white-space: nowrap;
  transition: transform 0.16s var(--ease-out), background-color 0.16s ease,
    padding 0.25s var(--ease-out), gap 0.25s var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .btn:hover { background: var(--berri-press); }
  .btn:hover .btn-orb { transform: translate(2px, -1px) scale(1.05); }
}
.btn:active { transform: scale(0.97); }
.btn .wa { width: 18px; height: 18px; flex: none; }
.btn.big { padding: 16px 12px 16px 30px; font-size: 18px; }
.btn-orb {
  display: grid; place-items: center; width: 38px; height: 38px; margin-left: 8px;
  border-radius: var(--r-pill); background: rgba(255, 255, 255, 0.16);
  font-size: 18px; transition: transform 0.16s var(--ease-out);
}
.btn-orb .wa { width: 20px; height: 20px; flex: none; }
.btn.giant { padding: 20px 38px; font-size: 21px; }
.btn.giant .wa { width: 24px; height: 24px; }
.ghost {
  font-size: 16px; font-weight: 700; color: var(--ink); text-decoration: none;
  border-bottom: 2px solid var(--ink); padding: 11px 2px 9px;
}
.ghost:hover { color: var(--berri-press); border-color: var(--berri-press); }

/* ---------- floating WhatsApp button: icon by default, expands in the pricing section ---------- */
.wa-fab {
  position: fixed; right: clamp(16px, 2.6vw, 30px); bottom: clamp(16px, 2.6vw, 30px);
  z-index: 60; display: inline-flex; align-items: center;
  height: 60px; border-radius: var(--r-pill);
  background: var(--berri); color: #fff; text-decoration: none;
  box-shadow: 0 14px 30px -8px rgba(29, 29, 82, 0.55);
  opacity: 0; transform: translateY(14px) scale(0.9); pointer-events: none;
  transition: opacity 0.3s var(--ease-out), transform 0.3s var(--ease-out);
}
.wa-fab.show { opacity: 1; transform: none; pointer-events: auto; }
.wa-fab-ico { flex: none; display: grid; place-items: center; width: 60px; height: 60px; }
.wa-fab-ico .wa { width: 28px; height: 28px; }
.wa-fab-label {
  white-space: nowrap; font-weight: 700; font-size: 16px;
  max-width: 0; opacity: 0; overflow: hidden;
  transition: max-width 0.35s var(--ease-out), opacity 0.25s ease, padding 0.35s var(--ease-out);
}
.wa-fab.expanded .wa-fab-label { max-width: 260px; opacity: 1; padding-right: 24px; }
@media (hover: hover) and (pointer: fine) { .wa-fab:hover { background: var(--berri-press); } }
.wa-fab:active { transform: scale(0.97); }

/* ---------- scene: one pinned frame; scroll progress drives everything (app.js) ---------- */
.scene { position: relative; height: 200vh; }
.scene-anchor { position: absolute; top: 96vh; left: 0; width: 1px; height: 1px; }
.scene-frame {
  position: sticky; top: 0; height: 100vh; overflow: hidden;
  isolation: isolate; background: var(--bg);
}
.scene-shader {
  position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0;
  display: block; background: var(--block-green); pointer-events: none;
}
.scene-wordmark { position: absolute; top: 70px; left: 2vw; width: 96vw; height: auto; z-index: 3; transform-origin: left top; }
/* headline + button, at the bottom of the frame, flanking the phone (fade out on scroll) */
.deck {
  position: absolute; left: 0; right: 0; bottom: 5vh; z-index: 3;
  display: flex; align-items: flex-end; justify-content: space-between; gap: 32px;
  padding: 0 var(--pad-x);
}
h1 { font-size: clamp(2rem, 3.6vw, 3.3rem); max-width: 22ch; }
.deck-left p { margin-top: 14px; font-size: 19px; color: var(--ink-on-pastel); max-width: 34ch; font-weight: 500; line-height: 1.45; }
.cta-cluster { display: flex; align-items: center; gap: 22px; flex-shrink: 0; }
.js .photo-card img { will-change: transform; }

/* ---------- chat bubbles (the product artifact) ---------- */
.chat { display: flex; flex-direction: column; gap: 10px; }
.hero-chat { position: absolute; left: 5vw; bottom: 6vh; max-width: 380px; transform: rotate(-1.2deg); }
.bubble {
  border-radius: var(--r-bubble); padding: 12px 16px;
  font-size: 16px; line-height: 1.4; font-weight: 500;
  box-shadow: var(--shadow-soft);
}
.bubble.user { background: var(--wa-user); color: var(--wa-user-ink); border-bottom-right-radius: 4px; align-self: flex-end; }
.bubble.memmu { background: #FFFFFF; color: var(--ink); border-bottom-left-radius: 4px; align-self: flex-start; }
.bubble .meta { display: block; margin-top: 4px; font-size: 12.5px; color: rgba(20, 20, 20, 0.66); text-align: right; font-weight: 600; }
.bubble.user .meta { color: rgba(16, 38, 27, 0.72); }
.chat-day { align-self: center; background: rgba(20, 20, 20, 0.08); color: #4F4F4F; border-radius: var(--r-pill); padding: 4px 14px; font-size: 13px; font-weight: 700; }
.chat-aside { font-size: 15px; font-weight: 600; color: var(--ink-on-pastel); padding: 4px 6px 0; font-style: italic; }
.chat-surface { background: var(--sen-light); border-radius: var(--r-card); padding: 22px; }

/* demo chat: typed + looped by JS (.live); base state stays fully visible without JS */
.js .demo-chat.live .dm { opacity: 0; transform: translateY(10px) scale(0.97); transition: opacity 0.4s var(--ease-out), transform 0.4s var(--ease-out); }
.js .demo-chat.live .dm.show { opacity: 1; transform: none; }
.typing { display: inline-flex; gap: 5px; align-items: center; min-height: 20px; }
.typing i { width: 7px; height: 7px; border-radius: var(--r-pill); background: rgba(20, 20, 20, 0.4); animation: dot 1s ease-in-out infinite; }
.typing i:nth-child(2) { animation-delay: 0.16s; }
.typing i:nth-child(3) { animation-delay: 0.32s; }
@keyframes dot { 0%, 60%, 100% { opacity: 0.35; transform: none; } 30% { opacity: 1; transform: translateY(-3px); } }

/* ---------- the phone: centered in the frame; scroll translates it up (app.js) ---------- */
.phone-stage {
  position: absolute; z-index: 40;
  left: 50%; top: 50%; transform: translate(-50%, -50%);
  width: min(330px, 80vw); will-change: transform;
}
.phone {
  position: relative;
  background: #0f0f14; border-radius: 48px; padding: 10px;
  box-shadow: 0 44px 90px -30px rgba(29, 29, 82, 0.55), 0 0 0 2px rgba(0, 0, 0, 0.25);
}
/* fixed phone-shaped screen; the chat fills it and auto-scrolls (JS) so it always looks full */
.phone-screen {
  aspect-ratio: 320 / 696; border-radius: 40px; overflow: hidden;
  display: flex; flex-direction: column;
  background: #d7cfc3 url("assets/img/wa-bg.png") center / cover;
}
/* WhatsApp header */
.phone-topbar { flex: none; display: flex; align-items: center; gap: 8px; padding: 10px 10px 8px; background: var(--wa-head); }
.wa-back { width: 22px; height: 22px; color: #0b141a; flex: none; }
.phone-topbar .phone-ava { width: 35px; height: 35px; border-radius: 50%; object-fit: cover; flex: none; padding: 0; background: none; }
.wa-who { display: flex; flex-direction: column; line-height: 1.12; margin-right: auto; min-width: 0; }
.wa-name { font-weight: 700; font-size: 14.5px; color: #0b141a; }
.wa-online { font-size: 11px; color: #667781; font-weight: 500; }
.wa-acts { display: inline-flex; align-items: center; gap: 15px; }
.wa-acts svg { width: 19px; height: 19px; color: #0b141a; fill: #0b141a; flex: none; }
/* chat over the wallpaper */
.phone .demo-chat { flex: 1; min-height: 0; overflow: hidden; background: transparent; padding: 9px 7px; gap: 2px; }
.phone .bubble {
  position: relative; max-width: 82%;
  font-size: 13.5px; line-height: 1.34; font-weight: 400; color: #111b21;
  padding: 5px 8px 6px; border-radius: 8px;
  box-shadow: 0 1px 0.6px rgba(11, 20, 26, 0.15);
}
.phone .bubble.memmu { background: #fff; border-top-left-radius: 0; }
.phone .bubble.user { background: var(--wa-user); border-top-right-radius: 0; }
.phone .bubble.memmu::after { content: ""; position: absolute; top: 0; left: -7px; width: 7px; height: 12px; background: #fff; clip-path: polygon(0 0, 100% 0, 100% 100%); }
.phone .bubble.user::after { content: ""; position: absolute; top: 0; right: -7px; width: 7px; height: 12px; background: var(--wa-user); clip-path: polygon(0 0, 100% 0, 0 100%); }
.phone .bubble .meta { float: right; margin: 5px 0 -1px 10px; font-size: 10px; font-weight: 500; color: #667781; white-space: nowrap; }
.phone .bubble.user .meta { color: rgba(11, 20, 26, 0.45); }
.phone .wa-tick { width: 15px; height: 10px; margin-left: 2px; vertical-align: -1.5px; color: #53bdeb; }
.phone .typing { padding: 9px 11px; }
.phone .chat-day { align-self: center; margin: 6px auto; background: rgba(240, 233, 224, 0.92); color: #54656f; border-radius: 8px; padding: 4px 11px; font-size: 11px; font-weight: 600; box-shadow: 0 1px 0.6px rgba(11, 20, 26, 0.1); }
/* WhatsApp input bar */
.phone-input { flex: none; display: flex; align-items: center; gap: 6px; padding: 6px 7px 8px; }
.wa-inbar { flex: 1; display: flex; align-items: center; gap: 7px; background: #fff; border-radius: 22px; padding: 7px 11px; box-shadow: 0 1px 1px rgba(11, 20, 26, 0.12); min-width: 0; }
.wa-inbar .wa-i { width: 19px; height: 19px; color: #8696a0; flex: none; }
.wa-ph { flex: 1; color: #8696a0; font-size: 13px; min-width: 0; }
.wa-mic { flex: none; width: 38px; height: 38px; border-radius: 50%; background: #00a884; display: grid; place-items: center; }
.wa-mic svg { width: 18px; height: 18px; color: #fff; fill: #fff; }

/* steps: to the RIGHT of the phone, vertically centered; fade in on scroll (app.js) */
.how-copy { position: absolute; z-index: 5; right: clamp(20px, 5vw, 80px); top: 50%; transform: translateY(-50%); width: min(38%, 400px); opacity: 0; }

/* stream: the chat's own words glide along a curve into the phone; fades in with the steps */
.stream { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 2; pointer-events: none; overflow: hidden; opacity: 0; }
.stream text { font: 600 19px "Rethink Sans", system-ui, sans-serif; fill: rgba(20, 20, 20, 0.42); }
.steps { list-style: none; counter-reset: step; display: flex; flex-direction: column; gap: 32px; }
.steps li { counter-increment: step; max-width: 44ch; }
.steps h3 { font-size: 22px; display: flex; align-items: baseline; gap: 14px; }
.steps h3::before {
  content: counter(step);
  display: grid; place-items: center; flex: none;
  width: 34px; height: 34px; border-radius: var(--r-pill);
  background: var(--berri); color: #fff; font-size: 16px; letter-spacing: 0;
  transform: translateY(-2px);
}
.steps p { margin-top: 10px; color: var(--ink-on-pastel); font-weight: 500; padding-left: 48px; }

/* ---------- mood blocks ---------- */
.block { padding: 8vh var(--pad-x); color: var(--ink); }
.block-salmon { background: var(--block-salmon); }
.block-blue { background: var(--block-blue); }
.block-yellow { background: var(--block-yellow); }
.block h2 { font-size: clamp(2.6rem, 5vw, 4.4rem); }
.block-sub { margin-top: 16px; font-size: 19px; line-height: 1.5; color: var(--ink-on-pastel); font-weight: 500; max-width: 46ch; }
.block-sub.center { margin-left: auto; margin-right: auto; }
.center { text-align: center; }
.block-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 5vw, 80px); align-items: center; }
.block-grid.flip .block-rail { order: 2; justify-self: start; text-align: left; }
.block-grid.flip .card-chat, .block-grid.flip .block-photo { order: 1; }
/* one photo per audience block, in place of the chat */
.block-photo { width: 100%; max-width: 560px; aspect-ratio: 4 / 3; border-radius: var(--r-card); overflow: hidden; box-shadow: var(--shadow-soft); margin: 0; }
.block-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.block-grid .block-photo { justify-self: end; }
.block-grid.flip .block-photo { justify-self: start; }
.speaks { list-style: none; padding: 0; margin-top: 28px; display: flex; flex-wrap: wrap; gap: 10px; }
.speaks li {
  border: 2px solid var(--ink); border-radius: var(--r-pill);
  padding: 8px 16px; font-size: 15px; font-weight: 700;
}
.card-chat { max-width: 460px; width: 100%; }
.block-grid.trio { margin-top: 7vh; grid-template-columns: 5fr 6fr; align-items: center; }
/* sticky stack: the audience blocks pin below the nav and pile over each other while scrolling.
   All widths; disabled only on very short viewports (landscape phones) where a pinned card
   taller than the screen would hide its own content. The tall card (lostuyos) stays LAST:
   the last card releases and scrolls through, so its full content is always reachable. */
@media (min-height: 640px) {
  .stack .block {
    position: sticky; top: 88px;
    min-height: calc(78vh - 176px);
    display: grid; align-content: center;
    margin: 0 clamp(10px, 1.5vw, 22px) 8vh;
    padding: 6vh var(--pad-x);
    border-radius: var(--r-card);
    box-shadow: var(--shadow-soft);
  }
  /* "Precio" is the final visible element in the stack: it pins and rises over the last card,
     giving that card room to pin up to the top (covering the card before it) */
  .stack .pricing { position: sticky; top: 88px; z-index: 2; background: var(--bg); min-height: calc(100vh - 88px); display: flex; flex-direction: column; justify-content: center; }
}
@media (max-width: 720px) and (min-height: 640px) {
  .stack .block { top: 78px; padding: 6vh 18px; margin: 0 10px 8vh; }
}

/* centered CTA button under "Habla tu idioma" */
.speak-cta { display: flex; justify-content: center; margin-top: 7vh; }
.photo-card { border-radius: var(--r-card); overflow: hidden; box-shadow: var(--shadow-soft); transform: rotate(-1.4deg); aspect-ratio: 5 / 4; }
.photo-card img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 10% 64%; }
.trio-right { display: flex; flex-direction: column; gap: 26px; }
.privacy { font-size: 15.5px; font-weight: 600; color: var(--ink-on-pastel); max-width: 48ch; }

/* ---------- manifesto ---------- */
.manifesto { display: none; background: var(--berri); color: #fff; padding: 14vh var(--pad-x); }
.manifesto-grid { display: grid; grid-template-columns: 7fr 5fr; gap: clamp(32px, 5vw, 80px); align-items: center; }
.manifesto-line {
  font-size: clamp(2.2rem, 4.4vw, 4rem); font-weight: 800;
  letter-spacing: -0.03em; line-height: 1.12; max-width: 24ch;
}
.pill-note { display: inline-block; border: 3px solid #fff; border-radius: var(--r-pill); padding: 0 0.3em 0.08em; line-height: 1; }
.nowrap { white-space: nowrap; }
.manifesto-side { display: flex; flex-direction: column; align-items: flex-start; gap: 26px; }
.manifesto-proof { list-style: none; padding: 0; display: flex; flex-direction: column; gap: 16px; }
.manifesto-proof li { font-size: 18px; font-weight: 600; color: #fff; }
.manifesto-proof li::before { content: ""; display: inline-block; width: 9px; height: 9px; border-radius: var(--r-pill); background: var(--sen-light); margin-right: 12px; transform: translateY(-2px); }
.btn.inverse { background: #fff; color: var(--berri-press); padding: 15px 26px; font-size: 16px; }
@media (hover: hover) and (pointer: fine) { .btn.inverse:hover { background: var(--sen-light); } }
.btn.on-berri { background: #fff; color: var(--berri-press); }
@media (hover: hover) and (pointer: fine) { .btn.on-berri:hover { background: var(--sen-light); } }

/* ---------- pricing (sticky cover over the last card) ---------- */
#habla { display: none; } /* kept in the DOM, superseded by the pricing section */
.pricing { padding: 12vh 0; }
.pricing-inner { width: 100%; max-width: 700px; margin: 0 auto; padding: 0 var(--pad-x); text-align: center; }
.eyebrow { font-size: 13px; font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase; color: var(--berri); }
.pricing h2 { font-size: clamp(2.2rem, 4.6vw, 3.4rem); margin-top: 14px; }
.pricing .block-sub { color: var(--ink-soft); }

.pricing-card {
  margin: 5vh auto 0; max-width: 620px;
  background: #fff; border: 1px solid rgba(29, 29, 82, 0.06);
  border-radius: var(--r-card); box-shadow: var(--shadow-soft);
  padding: clamp(30px, 4vw, 46px) clamp(22px, 4vw, 42px);
}
.dial { display: flex; align-items: center; justify-content: center; gap: clamp(12px, 2.6vw, 26px); }
.dial-end { flex: 0 0 auto; display: flex; flex-direction: column; align-items: center; }
.dial-price { font-size: clamp(1.55rem, 3.4vw, 2.3rem); font-weight: 800; letter-spacing: -0.02em; color: var(--ink); line-height: 1; }
.dial-price.accent { color: var(--berri); }
.dial-per { font-size: 12.5px; font-weight: 600; color: var(--ink-soft); margin-top: 5px; }
.dial-tag { font-size: 11px; font-weight: 700; letter-spacing: 0.06em; color: var(--ink-soft); margin-top: 9px; text-transform: uppercase; }

.dial-track { position: relative; flex: 1 1 auto; height: 8px; max-width: 230px; border-radius: var(--r-pill); background: var(--sen-light); }
.dial-fill { position: absolute; left: 0; top: 0; height: 100%; width: 58%; border-radius: var(--r-pill); background: var(--berri); }
.dial-knob {
  position: absolute; top: 50%; left: 58%; transform: translate(-50%, -50%);
  display: flex; align-items: center; gap: 6px;
  background: var(--berri); color: #fff;
  padding: 6px 12px 6px 8px; border-radius: var(--r-pill);
  box-shadow: 0 8px 18px -5px rgba(29, 29, 82, 0.5); white-space: nowrap;
}
.dial-knob-label { font-size: 12.5px; font-weight: 700; }
.dial-dots { display: inline-flex; }
.dial-dots i { width: 13px; height: 13px; border-radius: 50%; background: var(--sen-light); border: 2px solid var(--berri); display: block; box-sizing: border-box; }
.dial-dots i + i { margin-left: -6px; }

.pricing-mech { margin-top: clamp(26px, 3.5vw, 36px); font-size: 14.5px; line-height: 1.55; font-weight: 500; color: var(--ink-soft); max-width: 44ch; margin-left: auto; margin-right: auto; }
.pricing-reassure { margin-top: 4vh; font-size: 15px; font-weight: 600; color: var(--ink); }

@media (prefers-reduced-motion: no-preference) {
  .dial-knob { animation: knobDrift 6.5s var(--ease-in-out) infinite; }
  .dial-fill { animation: fillDrift 6.5s var(--ease-in-out) infinite; }
}
@keyframes knobDrift { 0%, 100% { left: 40%; } 50% { left: 66%; } }
@keyframes fillDrift { 0%, 100% { width: 40%; } 50% { width: 66%; } }

@media (max-width: 560px) {
  .dial { gap: 8px; }
  .dial-track { max-width: none; }
  .dial-price { font-size: 1.5rem; }
}

/* ---------- speak marquee ---------- */
.speak { padding: 14vh 0 12vh; }
.speak h2 { font-size: clamp(2.2rem, 4.6vw, 4rem); }
.speak .block-sub { color: var(--ink-soft); }
.marquee { margin-top: 6vh; display: flex; flex-direction: column; gap: 16px; overflow: hidden; }
.marquee-row { display: flex; overflow: hidden; }
.marquee-track { display: flex; flex: none; gap: 14px; padding-right: 14px; animation: slide 46s linear infinite; }
.marquee-row.reverse .marquee-track { animation-direction: reverse; animation-duration: 58s; }
.marquee-track span {
  flex: none; border: 2px solid var(--ink); border-radius: var(--r-pill);
  padding: 10px 22px; font-size: 16.5px; font-weight: 700; color: var(--ink);
}
@keyframes slide { from { transform: translateX(0); } to { transform: translateX(-100%); } }

/* ---------- faq ---------- */
/* ---------- FAQ (rendered inside a modal, opened from the menu) ---------- */
.faq-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 40px; align-items: start; }
.faq-grid details { border-bottom: 2px solid rgba(20, 20, 20, 0.16); padding: 4px 0 14px; }
.faq-grid summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 18px;
  font-size: 19px; font-weight: 700; padding: 12px 0 6px;
}
.faq-grid summary::-webkit-details-marker { display: none; }
.cross { font-size: 24px; font-weight: 600; color: var(--berri); transition: transform 0.2s var(--ease-out); }
.faq-grid details[open] .cross { transform: rotate(45deg); }
.faq-grid details p { color: var(--ink-soft); font-weight: 500; max-width: 58ch; padding: 4px 36px 8px 0; }

.faq-modal[open] {
  display: flex; flex-direction: column;
  position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); margin: 0;
}
.faq-modal {
  width: min(900px, 92vw); max-height: 86vh;
  border: none; padding: 0; border-radius: 24px;
  background: #fff; color: var(--ink); box-shadow: var(--shadow-soft); overflow: hidden;
}
.faq-modal::backdrop { background: rgba(20, 20, 30, 0.55); }
.faq-modal-head {
  flex: none; display: flex; align-items: center; justify-content: space-between; gap: 20px;
  padding: clamp(22px, 3vw, 34px) clamp(22px, 4vw, 44px) clamp(14px, 2vw, 20px);
  border-bottom: 2px solid rgba(20, 20, 20, 0.08);
}
.faq-modal-head h2 { font-size: clamp(1.6rem, 3.2vw, 2.4rem); }
.faq-modal-close {
  flex: none; width: 44px; height: 44px; border-radius: var(--r-pill); border: none;
  background: var(--sen-light); color: var(--berri-press); font-size: 26px; line-height: 1;
  cursor: pointer; display: grid; place-items: center; transition: background-color 0.16s ease;
}
.faq-modal-close:hover { background: var(--block-lilac); }
.faq-modal-body { flex: 1 1 auto; min-height: 0; overflow-y: auto; padding: clamp(18px, 3vw, 30px) clamp(22px, 4vw, 44px) clamp(24px, 4vw, 44px); }
.js .faq-modal .r.pre { opacity: 1; transform: none; } /* modal content is always visible (no scroll-reveal) */
html.modal-open { overflow: hidden; }

/* ---------- final CTA (compact berri card after pricing) ---------- */
.final-cta { padding: 7vh clamp(10px, 1.5vw, 22px) 9vh; }
.final-cta-card {
  background: var(--berri); color: #fff;
  border-radius: var(--r-card); box-shadow: var(--shadow-soft);
  padding: clamp(28px, 3.4vw, 44px) var(--pad-x);
  display: flex; align-items: center; justify-content: space-between; gap: clamp(20px, 4vw, 52px);
}
.final-cta-card h2 { font-size: clamp(1.7rem, 3vw, 2.7rem); font-weight: 800; letter-spacing: -0.02em; line-height: 1.05; }
@media (max-width: 720px) {
  .final-cta { padding: 6vh 10px 8vh; }
  .final-cta-card { padding: 34px 18px; }
}
@media (max-width: 640px) {
  .final-cta-card { flex-direction: column; align-items: flex-start; gap: 24px; }
  .final-cta-card .btn { width: 100%; justify-content: center; }
}

/* ---------- footer ---------- */
.footer { background: var(--block-green); padding: 4vh 0 22px; position: relative; overflow: hidden; isolation: isolate; }
/* dithered green shader sits behind the footer content (painted by app.js WebGL) */
.foot-shader { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; display: block; background: var(--block-green); pointer-events: none; }
.foot-top, .foot-mark, .foot-meta { position: relative; z-index: 1; }
.foot-top {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; flex-wrap: wrap;
  margin: 0 var(--pad-x) 5vh; padding: 0;
}
.foot-tagline { font-size: 17px; font-weight: 600; color: var(--ink-on-pastel); max-width: 34ch; line-height: 1.45; }
.foot-links { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.foot-links a { font-size: 15px; font-weight: 700; color: var(--ink); text-decoration: none; border-bottom: 2px solid rgba(20, 20, 20, 0.35); padding: 10px 2px 8px; }
.foot-links a:hover { color: var(--berri-press); border-color: var(--berri-press); }
.foot-mark { display: block; width: 96vw; margin-left: 2vw; height: auto; }
.foot-meta {
  display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap;
  padding: 18px var(--pad-x) 0; font-size: 14px; font-weight: 600; color: var(--ink-on-pastel);
}
.foot-meta a { color: var(--ink); font-weight: 700; text-decoration: none; border-bottom: 2px solid rgba(20, 20, 20, 0.35); padding: 8px 2px 6px; }
.foot-meta a:hover { color: var(--berri-press); border-color: var(--berri-press); }

/* ---------- responsive ---------- */
@media (max-width: 860px) {
  /* mobile: the scene becomes a static stacked collage — no pinning, no scroll-scrub.
     (the JS scene driver disables itself below 861px and clears its inline styles) */
  .scene { height: auto; }
  /* padding-top (not a child margin) so the green starts at the very top with no white gap */
  .scene-frame { position: static; height: auto; min-height: 0; overflow: visible; padding: 5vh 0 0; }
  .scene-wordmark { position: relative; z-index: 3; left: auto; top: auto; width: 92vw; margin: 0 auto; display: block; }
  .deck {
    position: relative; z-index: 3; display: block; text-align: center; opacity: 1 !important;
    left: auto; right: auto; bottom: auto; margin: 13vh auto 0; padding: 0 24px; max-width: 560px;
  }
  h1 { font-size: clamp(2rem, 8vw, 2.9rem); max-width: none; }
  .deck-left p { margin: 14px auto 0; max-width: 42ch; }
  .cta-cluster { justify-content: center; margin-top: 28px; }
  /* phone: pushed well down so only ~half peeks, and lower on the screen */
  .phone-stage {
    position: relative; z-index: 40; transform: none !important; opacity: 1 !important;
    width: min(296px, 74vw); margin: 18vh auto 0; left: auto; top: auto;
  }
  /* steps: their OWN light (bone) section — full-bleed band, content centered */
  .how-copy {
    position: relative; z-index: 5; transform: none !important; opacity: 1 !important;
    width: 100%; max-width: none; margin: 8vh 0 0; right: auto; top: auto;
    background: var(--bg); padding: 10vh 24px 12vh;
  }
  .steps { max-width: 400px; margin: 0 auto; }
  .stream { opacity: 1 !important; }
  .stream text { font-size: 15px; }
}
@media (max-width: 900px) {
  .block-grid, .block-grid.trio { grid-template-columns: 1fr; }
  .block-grid.flip .block-rail { order: 1; justify-self: start; text-align: left; }
  .block-grid.flip .block-rail .speaks { justify-content: flex-start; }
  .block-grid.flip .card-chat, .block-grid.flip .block-photo { order: 2; }
  /* photo goes full-width below the rail when stacked */
  .block-grid .block-photo, .block-grid.flip .block-photo { justify-self: stretch; max-width: none; margin-top: 6vh; }
  .faq-grid { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .nav { padding: 14px 18px; }
  .nav-links { display: none; }
  .deck-left p { font-size: 17px; }
  .btn.big { padding: 14px 10px 14px 24px; font-size: 16.5px; }
  .block { padding: 9vh 18px; }
  .manifesto { padding: 11vh 18px; }
  .manifesto-grid { grid-template-columns: 1fr; gap: 6vh; }
  .manifesto-line { font-size: clamp(1.9rem, 8vw, 2.4rem); }
  .speak { padding: 10vh 0 9vh; }
  .speak h2, .speak .block-sub { padding: 0 18px; }
  .footer { padding-top: 4vh; }
  .foot-top { margin-left: 18px; margin-right: 18px; }
  .foot-meta { padding: 16px 18px 0; }
}

/* ---------- reduced motion: gentler, never broken ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .r.pre, .js .chat.armed .b-r { opacity: 1; transform: none; }
  .js .demo-chat.live .dm { opacity: 1; transform: none; }
  .typing i { animation: none; }
  .stream { display: none; }
  .marquee-track { animation: none; }
  .marquee-row { flex-wrap: wrap; gap: 10px; padding: 0 var(--pad-x); }
  .marquee-track { flex-wrap: wrap; }
  .marquee-track[aria-hidden="true"] { display: none; }
  .btn, .btn-orb, .cross, .nav, .nav.pill, .nav .btn span, .wa-fab, .wa-fab-label { transition: none; }
}
