/* ─────────────────────────────────────────
   Caeiro — marketing pages (homepage + plans)
   Warm editorial · pine-green accent · light only
   Logical properties throughout for RTL
   ───────────────────────────────────────── */

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  /* accent + fonts are overridden live by Tweaks */
  --accent: oklch(42% 0.072 153); /* deep pine green */
  --accent-deep: color-mix(in oklab, var(--accent), black 16%);
  --accent-soft: color-mix(in oklab, var(--accent), var(--cream) 86%);
  --accent-line: color-mix(in oklab, var(--accent), transparent 78%);

  --cream: oklch(96.8% 0.013 84);
  --bg: var(--cream);
  --bg-2: oklch(94% 0.018 80);
  --card: oklch(99% 0.006 86);
  --text: oklch(26% 0.02 62);
  --text-2: oklch(45% 0.017 66);
  --text-3: oklch(58% 0.015 70);
  --border: oklch(87.5% 0.016 74);
  --border-sub: oklch(91.5% 0.012 76);

  --font-head: 'Spectral', Georgia, serif;
  --font-body: 'Hanken Grotesk', system-ui, -apple-system, sans-serif;

  --calcada: 0.05; /* Portugal-hint intensity (0–0.14) */

  --maxw: 1080px;
  --maxw-narrow: 720px;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 2px oklch(40% 0.03 70 / 0.06), 0 6px 18px oklch(40% 0.03 70 / 0.06);
  --shadow-md: 0 2px 6px oklch(40% 0.03 70 / 0.07), 0 18px 48px oklch(40% 0.03 70 / 0.1);
}

/* Hebrew: Spectral (head) + Hanken (body) carry NO Hebrew glyphs, so they fall
   back to a system serif — Hebrew should never render serif. Swap the whole
   stack to Rubik (covers Hebrew, sans) for the RTL surface only; Latin keeps
   the editorial Spectral. i18n-site.js sets html[lang] on switch. */
html[lang='he'] {
  --font-head: 'Rubik', system-ui, sans-serif;
  --font-body: 'Rubik', system-ui, sans-serif;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

::selection {
  background: var(--accent-line);
  color: var(--text);
}

h1,
h2,
h3 {
  font-family: var(--font-head);
  font-weight: 600;
  letter-spacing: -0.018em;
  line-height: 1.08;
}

/* ═══════════ calçada-inspired stone lattice ═══════════
   abstract diamond tessellation — no literal imagery */
.calcada {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: var(--calcada);
  background-color: transparent;
  background-image:
    repeating-linear-gradient(45deg, var(--accent) 0 1.2px, transparent 1.2px 22px),
    repeating-linear-gradient(-45deg, var(--accent) 0 1.2px, transparent 1.2px 22px);
  -webkit-mask-image: radial-gradient(120% 90% at 50% 0%, #000 35%, transparent 78%);
  mask-image: radial-gradient(120% 90% at 50% 0%, #000 35%, transparent 78%);
}

/* ═══════════ shell ═══════════ */
.wrap {
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 4vw, 2rem);
}
.wrap-narrow {
  max-width: var(--maxw-narrow);
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 4vw, 2rem);
}

/* ═══════════ nav ═══════════ */
nav {
  position: sticky;
  top: 0;
  z-index: 60;
  background: color-mix(in oklch, var(--cream) 82%, transparent);
  -webkit-backdrop-filter: blur(12px) saturate(1.4);
  backdrop-filter: blur(12px) saturate(1.4);
  border-block-end: 1px solid var(--border-sub);
}
.nav-inner {
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 4vw, 2rem);
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
/* Right-side cluster (language picker + Log in + Start free) as ONE flex
   item, so nav-inner's space-between keeps it pinned opposite the brand
   instead of splitting into three independently-spaced children. */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1.3rem;
  letter-spacing: -0.02em;
  color: var(--text);
}
.brand-mark {
  width: 26px;
  height: 26px;
  border-radius: 7px;
  flex-shrink: 0;
  background: var(--accent);
  display: grid;
  place-items: center;
}
.brand-mark svg {
  display: block;
}

/* ═══════════ buttons ═══════════ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1rem;
  padding-block: 0.85rem;
  padding-inline: 1.4rem;
  border-radius: 99px;
  border: 1px solid transparent;
  cursor: pointer;
  transition:
    transform 0.14s,
    box-shadow 0.18s,
    background 0.18s,
    border-color 0.18s,
    color 0.18s;
  white-space: nowrap;
  line-height: 1;
}
.btn svg {
  display: block;
  flex-shrink: 0;
}
.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow:
    0 1px 2px oklch(0% 0 0 / 0.08),
    0 10px 26px color-mix(in oklab, var(--accent), transparent 72%);
}
.btn-primary:hover {
  background: var(--accent-deep);
  transform: translateY(-1px);
  box-shadow:
    0 2px 4px oklch(0% 0 0 / 0.1),
    0 14px 34px color-mix(in oklab, var(--accent), transparent 64%);
}
.btn-ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}
.btn-ghost:hover {
  border-color: var(--accent);
  color: var(--accent-deep);
  background: color-mix(in oklab, var(--accent), transparent 94%);
}
.btn-sm {
  padding-block: 0.6rem;
  padding-inline: 1.05rem;
  font-size: 0.9rem;
}

/* ═══════════ hero ═══════════ */
.hero {
  position: relative;
  overflow: hidden;
  padding-block: clamp(4rem, 11vw, 8rem) clamp(2.5rem, 6vw, 4rem);
}
.hero .wrap {
  position: relative;
  z-index: 1;
  text-align: center;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-deep);
  background: color-mix(in oklab, var(--accent), var(--cream) 84%);
  border: 1px solid var(--accent-line);
  padding-block: 0.4rem;
  padding-inline: 0.9rem;
  border-radius: 99px;
  margin-block-end: 1.8rem;
}
.eyebrow-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}
.hero h1 {
  font-size: clamp(2.6rem, 7.2vw, 5rem);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.02;
  max-width: 14ch;
  margin-inline: auto;
  text-wrap: balance;
}
.hero h1 em {
  font-style: italic;
  color: var(--accent-deep);
}
.hero-sub {
  margin-block-start: 1.6rem;
  margin-inline: auto;
  max-width: 46ch;
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  color: var(--text-2);
  line-height: 1.6;
  text-wrap: pretty;
}
.hero-cta {
  margin-block-start: 2.4rem;
  display: flex;
  gap: 0.8rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* ═══════════ section heading rhythm ═══════════ */
.sec {
  padding-block: clamp(3.5rem, 8vw, 6.5rem);
  position: relative;
}
.sec-alt {
  background: var(--bg-2);
  border-block: 1px solid var(--border-sub);
}
.kicker {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-deep);
  display: flex;
  align-items: center;
  gap: 0.7rem;
  justify-content: center;
}
.kicker::before,
.kicker::after {
  content: '';
  width: 26px;
  height: 1px;
  background: var(--accent-line);
}
.sec-head {
  text-align: center;
}
.sec-head h2 {
  font-size: clamp(1.8rem, 4vw, 2.7rem);
  margin-block-start: 1rem;
  max-width: 20ch;
  margin-inline: auto;
  text-wrap: balance;
}
.sec-head p {
  margin-block-start: 0.9rem;
  color: var(--text-2);
  font-size: 1.08rem;
  max-width: 48ch;
  margin-inline: auto;
  text-wrap: pretty;
}

/* The chat section gets a warm ground with two soft pine-green glows (the page's
   own accent) behind the product-demo windows, which now share that same green
   (matching the app). It's the browser-frame chrome, not a colour contrast, that
   sets the demo apart from the marketing page — lifts the flat all-beige feel. */
#chat.sec-alt {
  background:
    radial-gradient(
      55% 45% at 88% 6%,
      color-mix(in oklab, var(--accent), transparent 85%),
      transparent 72%
    ),
    radial-gradient(
      52% 42% at 8% 96%,
      color-mix(in oklab, var(--accent), transparent 88%),
      transparent 72%
    ),
    var(--bg-2);
}

/* ═══════════ chat demos — faithful to the real Caeiro app, stacked ═══════════
   These panels mimic the product, so they carry the APP's pine-green accent
   (scoped to --d-* here, kept warm-neutral otherwise) — the same green as the
   page's own --accent. It's the browser frame, not a colour contrast, that
   marks them as "the product UI", not more marketing page. */
.demos {
  --d-accent: oklch(53% 0.1 152);
  --d-accent-soft: oklch(53% 0.1 152 / 0.1);
  --d-on-accent: oklch(99% 0.005 75);
  --d-bg: oklch(97% 0.012 75);
  --d-surface: oklch(100% 0 0);
  --d-surface-2: oklch(94.5% 0.014 75);
  --d-border: oklch(89% 0.012 75);
  --d-border-sub: oklch(93% 0.01 75);
  --d-text: oklch(18% 0.02 50);
  --d-text-2: oklch(48% 0.015 50);
  --d-text-3: oklch(64% 0.012 50);

  margin-block-start: 2.4rem;
  display: flex;
  flex-direction: column;
  gap: clamp(2.5rem, 6vw, 4rem);
}
/* Each chat is its own row; rows alternate side (chat left / chat right) with the
   caption opposite, while the screen is wide enough. Stacks below 760px. */
.demo {
  display: flex;
  align-items: center;
  gap: clamp(1.5rem, 5vw, 4rem);
}
.demo:nth-child(odd) {
  flex-direction: row-reverse;
}
.demo-chat {
  flex: 0 0 clamp(360px, 40vw, 460px);
  min-width: 0;
}
.demo-cap {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  text-align: center;
}
.demo-eyebrow {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-deep);
  background: color-mix(in oklab, var(--accent), var(--cream) 84%);
  border: 1px solid var(--accent-line);
  padding: 0.3rem 0.85rem;
  border-radius: 99px;
}
.demo-cap-title {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: clamp(1.4rem, 2.6vw, 2rem);
  color: var(--text);
  letter-spacing: -0.02em;
  line-height: 1.1;
  text-wrap: balance;
}
.demo-cap-sub {
  color: var(--text-2);
  font-size: clamp(0.98rem, 1.4vw, 1.1rem);
  line-height: 1.55;
  max-width: 30ch;
  text-wrap: pretty;
}

/* Private demo: the owner control room — a tab rail beside the chat, inside the
   browser frame (the frame owns the border/shadow, so the shell is bare). */
.app-shell {
  display: flex;
  align-items: stretch;
}
.app-shell .phone {
  border-radius: 0;
  border: 0;
  box-shadow: none;
  flex: 1;
  min-width: 0;
}
.rail {
  width: 72px;
  flex-shrink: 0;
  background: var(--d-accent-soft);
  border-inline-end: 1px solid var(--d-border-sub);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 4px;
  padding: 0.7rem 0.4rem;
}
.rail-tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 0.5rem 0.2rem;
  border-radius: 10px;
  color: var(--d-text-3);
  font-size: 0.6rem;
  font-weight: 600;
}
.rail-tab span {
  line-height: 1;
}
.rail-tab.is-active {
  background: var(--d-surface);
  color: var(--d-accent);
  box-shadow: 0 1px 2px oklch(20% 0.02 50 / 0.08);
}

/* Each demo is a framed panel (border + warm shadow). The private one wraps the
   control rail; the public one is just the chat. No address bar. */
.browser-frame {
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid var(--d-border);
  box-shadow:
    0 12px 38px oklch(45% 0.07 40 / 0.14),
    0 2px 8px oklch(45% 0.05 40 / 0.08);
  background: var(--d-surface-2);
}
.browser-frame .phone {
  border-radius: 0;
  border: 0;
  box-shadow: none;
}

.phone {
  background: var(--d-surface);
  border-radius: 18px;
  border: 1px solid var(--d-border);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 440px; /* fixed so the chat scrolls INTERNALLY instead of stretching the panel (header sits above, full-width) */
}
.chat-head {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 0.8rem;
  background: var(--d-surface);
  border-block-end: 1px solid var(--d-border-sub);
}
.chat-head-side {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  min-width: 0;
}
.chat-head-right {
  justify-content: flex-end;
  color: var(--d-text-3);
}
.chat-acct {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  flex-shrink: 0;
  background: var(--d-accent);
  color: var(--d-on-accent);
  display: grid;
  place-items: center;
}
.chat-pill {
  justify-self: center;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 12px;
  border-radius: 999px;
  border: 1px solid var(--d-border);
  background: var(--d-surface);
  color: var(--d-text);
  font-size: 0.8rem;
  font-weight: 600;
  font-family: var(--font-body);
  white-space: nowrap;
}
.chat-pill .pill-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--d-accent);
}
.chat-pill svg {
  opacity: 0.5;
}
.chat-pub {
  justify-self: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
}
.chat-pub-owner {
  font-size: 0.7rem;
  color: var(--d-text-3);
  font-weight: 500;
}

.chat-body {
  flex: 1;
  padding: 1rem 0.9rem 0.6rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  overflow-y: auto;
  background: var(--d-bg);
  scrollbar-width: thin;
}
.chat-day {
  align-self: center;
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--d-text-3);
  background: var(--d-surface);
  padding: 0.2rem 0.7rem;
  border-radius: 99px;
  margin-block: 0.2rem 0.4rem;
  box-shadow: 0 1px 2px oklch(20% 0.02 50 / 0.06);
}

.bubble {
  max-width: 84%;
  padding: 0.55rem 0.8rem 0.45rem;
  border-radius: 16px;
  font-size: 0.92rem;
  line-height: 1.45;
  position: relative;
  animation: pop 0.26s cubic-bezier(0.2, 0.8, 0.3, 1) both;
  word-wrap: break-word;
}
.bubble .meta {
  display: block;
  text-align: end;
  font-size: 0.6rem;
  color: var(--d-text-3);
  margin-block-start: 0.15rem;
}
.bubble.them {
  align-self: flex-start;
  background: var(--d-surface);
  border: 1px solid var(--d-border-sub);
  border-start-start-radius: 5px;
  color: var(--d-text);
  box-shadow: 0 1px 2px oklch(20% 0.02 50 / 0.06);
}
.bubble.me {
  align-self: flex-end;
  background: var(--d-accent);
  border-start-end-radius: 5px;
  color: var(--d-on-accent);
}
.bubble.me .meta {
  color: color-mix(in oklab, var(--d-on-accent), transparent 35%);
}
@keyframes pop {
  from {
    opacity: 0;
    transform: translateY(7px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.typing {
  align-self: flex-start;
  background: var(--d-surface);
  border: 1px solid var(--d-border-sub);
  border-radius: 16px;
  border-start-start-radius: 5px;
  padding: 0.7rem 0.85rem;
  display: inline-flex;
  gap: 4px;
  box-shadow: 0 1px 2px oklch(20% 0.02 50 / 0.06);
}
.typing span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--d-text-3);
  animation: blink 1.1s infinite both;
}
.typing span:nth-child(2) {
  animation-delay: 0.2s;
}
.typing span:nth-child(3) {
  animation-delay: 0.4s;
}
@keyframes blink {
  0%,
  60%,
  100% {
    opacity: 0.25;
    transform: translateY(0);
  }
  30% {
    opacity: 1;
    transform: translateY(-3px);
  }
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  padding: 0.7rem 0.9rem;
  background: var(--d-surface);
  border-block-start: 1px solid var(--d-border-sub);
}
.chip-hint {
  width: 100%;
  font-size: 0.64rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--d-text-3);
  margin-block-end: 0.05rem;
}
.chip {
  font-family: var(--font-body);
  font-size: 0.82rem;
  font-weight: 500;
  padding: 0.42rem 0.8rem;
  border-radius: 99px;
  background: var(--d-bg);
  border: 1px solid var(--d-border);
  color: var(--d-accent);
  cursor: pointer;
  transition:
    background 0.14s,
    transform 0.14s,
    border-color 0.14s;
}
.chip:hover {
  background: var(--d-accent-soft);
  transform: translateY(-1px);
  border-color: var(--d-accent);
}
.chip:disabled {
  opacity: 0.4;
  cursor: default;
  transform: none;
}

.chat-foot {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 0.9rem;
  background: var(--d-surface);
  border-block-start: 1px solid var(--d-border-sub);
}
.chat-foot .composer-add {
  color: var(--d-text-3);
  flex-shrink: 0;
  display: grid;
  place-items: center;
}
.chat-foot .fake-input {
  flex: 1;
  height: 38px;
  border-radius: 99px;
  background: var(--d-bg);
  border: 1px solid var(--d-border-sub);
  display: flex;
  align-items: center;
  padding-inline: 0.9rem;
  color: var(--d-text-3);
  font-size: 0.84rem;
}
.chat-foot .send {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--d-accent);
  color: var(--d-on-accent);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.chat-replay {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--d-text-3);
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 600;
}
.chat-replay:hover {
  color: var(--d-accent);
}

/* ═══════════ manifesto / credo ═══════════ */
.credo {
  background: var(--text);
  color: var(--cream);
  position: relative;
  overflow: hidden;
}
.credo .calcada {
  opacity: calc(var(--calcada) * 2.2);
  background-image:
    repeating-linear-gradient(45deg, var(--cream) 0 1.2px, transparent 1.2px 22px),
    repeating-linear-gradient(-45deg, var(--cream) 0 1.2px, transparent 1.2px 22px);
}
.credo .wrap-narrow {
  position: relative;
  z-index: 1;
}
.credo .kicker {
  color: color-mix(in oklab, var(--accent), white 38%);
  justify-content: flex-start;
}
.credo .kicker::after {
  display: none;
}
.credo h2 {
  font-size: clamp(2rem, 5vw, 3.1rem);
  margin-block: 1.1rem 2.6rem;
  max-width: 18ch;
}
.credo-block {
  margin-block-end: 2.3rem;
  max-width: 60ch;
}
.credo-block:last-child {
  margin-block-end: 0;
}
.credo-lead {
  font-family: var(--font-head);
  font-size: clamp(1.3rem, 2.6vw, 1.7rem);
  font-weight: 500;
  line-height: 1.32;
  color: var(--cream);
  letter-spacing: -0.01em;
  text-wrap: balance;
}
.credo-lead em {
  font-style: italic;
  color: color-mix(in oklab, var(--accent), white 42%);
}
.credo-body {
  margin-block-start: 0.7rem;
  font-size: 1.06rem;
  line-height: 1.7;
  color: color-mix(in oklab, var(--cream), transparent 28%);
  text-wrap: pretty;
}
.credo-body em {
  font-style: normal;
  color: var(--cream);
  font-weight: 500;
}
.credo-rule {
  height: 1px;
  background: color-mix(in oklab, var(--cream), transparent 86%);
  margin-block: 2.3rem;
  max-width: 60ch;
}

/* ═══════════ benefits ═══════════ */
.benefits {
  margin-block-start: 2.8rem;
  display: flex;
  flex-direction: column;
  gap: 0;
  max-width: 760px;
  margin-inline: auto;
}
.benefit {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  padding-block: 1.5rem;
  border-block-end: 1px solid var(--border);
}
.benefit:first-child {
  border-block-start: 1px solid var(--border);
}
.benefit-ico {
  width: 50px;
  height: 50px;
  border-radius: 13px;
  flex-shrink: 0;
  background: var(--accent-soft);
  border: 1px solid var(--accent-line);
  color: var(--accent-deep);
  display: grid;
  place-items: center;
}
.benefit-ico svg {
  display: block;
}
.benefit-txt {
  font-size: clamp(1.05rem, 2vw, 1.3rem);
  font-family: var(--font-head);
  font-weight: 500;
  letter-spacing: -0.01em;
  line-height: 1.3;
  text-wrap: pretty;
}
.benefit-txt em {
  font-style: italic;
  color: var(--accent-deep);
}

/* ═══════════ you're the agent ═══════════ */
.agent {
  text-align: center;
}
.agent .wrap-narrow {
  position: relative;
  z-index: 1;
}
.agent h2 {
  font-size: clamp(2.1rem, 5.5vw, 3.4rem);
  max-width: 16ch;
  margin-inline: auto;
}
.agent h2 em {
  font-style: italic;
  color: var(--accent-deep);
}
.agent-line {
  margin-block-start: 1.6rem;
  font-size: clamp(1.15rem, 2.2vw, 1.4rem);
  color: var(--text-2);
  line-height: 1.5;
  max-width: 40ch;
  margin-inline: auto;
  text-wrap: balance;
}
.agent-craft {
  margin-block-start: 1.4rem;
  font-family: var(--font-head);
  font-style: italic;
  font-size: clamp(1.2rem, 2.4vw, 1.55rem);
  color: var(--text);
}

/* ═══════════ closing CTA ═══════════ */
.close-cta {
  text-align: center;
}
.close-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 22px;
  box-shadow: var(--shadow-md);
  padding: clamp(2.4rem, 5vw, 3.6rem) clamp(1.6rem, 4vw, 3rem);
  max-width: 640px;
  margin-inline: auto;
  position: relative;
  overflow: hidden;
}
.close-card .calcada {
  opacity: calc(var(--calcada) * 1.3);
}
.close-card > * {
  position: relative;
  z-index: 1;
}
.close-card h2 {
  font-size: clamp(1.9rem, 4.5vw, 2.8rem);
  max-width: 16ch;
  margin-inline: auto;
}
.close-card p {
  margin-block: 1rem 0;
  color: var(--text-2);
  font-size: 1.08rem;
  max-width: 42ch;
  margin-inline: auto;
  line-height: 1.6;
  text-wrap: pretty;
}
.close-card .btn {
  margin-block-start: 2rem;
}
.close-meta {
  margin-block-start: 1.1rem;
  font-size: 0.86rem;
  color: var(--text-3);
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

/* ═══════════ footer ═══════════ */
footer {
  border-block-start: 1px solid var(--border-sub);
  padding-block: 2.2rem;
  margin-block-start: 0;
}
.foot-inner {
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 4vw, 2rem);
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
  justify-content: space-between;
}
.foot-brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--text);
}
.foot-brand .brand-mark {
  width: 22px;
  height: 22px;
  border-radius: 6px;
}
.foot-links {
  display: flex;
  gap: 1.4rem;
  font-size: 0.92rem;
  color: var(--text-2);
}
.foot-links a {
  transition: color 0.13s;
}
.foot-links a:hover {
  color: var(--accent-deep);
}
.foot-copy {
  width: 100%;
  font-size: 0.82rem;
  color: var(--text-3);
  margin-block-start: 0.4rem;
}

/* ═══════════ responsive ═══════════ */
/* Below ~760px there's no room for chat + caption side by side, so each row stacks:
   caption above its chat, centered (reset the row-reverse alternation too). */
@media (max-width: 760px) {
  .demo,
  .demo:nth-child(odd) {
    flex-direction: column;
    gap: 0.7rem;
  }
  .demo-chat {
    flex: none;
    width: 100%;
    max-width: 460px;
    margin-inline: auto;
  }
  .demo-cap {
    flex: none;
  }
}
/* Mobile (most homepage visitors): the rail becomes a bottom tab bar like the real
   app, and the browser frame drops the desktop traffic-light dots (mobile browsers
   show only a URL). */
@media (max-width: 560px) {
  .app-shell {
    flex-direction: column-reverse;
  }
  .rail {
    width: 100%;
    flex-direction: row;
    align-items: stretch;
    border-inline-end: 0;
    border-block-start: 1px solid var(--d-border-sub);
    padding: 0.4rem 0.3rem;
  }
  .rail-tab {
    flex: 1;
    padding: 0.4rem 0.2rem;
  }
}
@media (max-width: 640px) {
  body {
    font-size: 16px;
  }
  .hero-cta .btn {
    width: 100%;
  }
  .benefit {
    gap: 0.9rem;
    padding-block: 1.2rem;
  }
  .benefit-ico {
    width: 44px;
    height: 44px;
  }
  .foot-inner {
    flex-direction: column;
    align-items: flex-start;
  }
}
/* Narrow phones: brand + lang picker + Log in + Start free is tight in a
   fixed 64px nav row. Collapse "Log in" to icon-only (label stays in the DOM
   for a11y via aria-label, just visually hidden) rather than let it wrap. */
@media (max-width: 420px) {
  .nav-actions {
    gap: 0.4rem;
  }
  .nav-login span {
    display: none;
  }
  .nav-login {
    padding-inline: 0.65rem;
  }
}

/* RTL: directional glyphs flip; layout already uses logical props */
[dir='rtl'] .hero-cta,
[dir='rtl'] .foot-inner {
  /* logical props handle the rest */
}

/* centered kicker variant (agent section) */
.kicker-center {
  margin-block-end: 0.4rem;
}

/* ═══════════ language switcher ═══════════ */
.lang-pick {
  position: relative;
  display: inline-flex;
  margin-inline-end: 0.5rem;
}
.lang-pick-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-2);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 99px;
  padding: 0.32rem 0.7rem;
  cursor: pointer;
  line-height: 1;
  transition:
    border-color 0.13s,
    color 0.13s;
}
.lang-pick-btn:hover {
  border-color: var(--accent);
  color: var(--accent-deep);
}
.lang-pick-btn svg {
  opacity: 0.55;
}
.lang-menu {
  position: absolute;
  top: calc(100% + 6px);
  inset-inline-end: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow-md);
  padding: 4px;
  z-index: 80;
  min-width: 96px;
}
.lang-menu[hidden] {
  display: none;
}
.lang-opt {
  font-family: var(--font-body);
  font-size: 0.84rem;
  font-weight: 500;
  color: var(--text-2);
  background: none;
  border: 0;
  border-radius: 8px;
  padding: 0.45rem 0.7rem;
  cursor: pointer;
  text-align: start;
  line-height: 1.3;
  transition:
    color 0.12s,
    background 0.12s;
}
.lang-opt:hover {
  background: color-mix(in oklab, var(--accent), transparent 92%);
  color: var(--text);
}
.lang-opt[aria-pressed='true'] {
  color: var(--accent-deep);
  font-weight: 700;
  background: color-mix(in oklab, var(--accent), var(--cream) 88%);
}

/* ═══════════ signup CTA — email-capture overlay (row 35) ═══════════
   Shared by business.html + plans.html; built + wired by signup-cta.js. Only
   shown while SIGNUP_OPEN is off — mirrors the branded-404 email-capture form
   (server/error-pages.js), just styled with this page's own tokens. */
.signup-cta-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 200;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  background: color-mix(in oklab, var(--text), transparent 58%);
}
.signup-cta-overlay.is-open {
  display: flex;
}
.signup-cta-card {
  width: 100%;
  max-width: 380px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  padding: 1.75rem;
  text-align: center;
  position: relative;
}
.signup-cta-close {
  position: absolute;
  top: 0.7rem;
  inset-inline-end: 0.7rem;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-2);
  font-size: 1.2rem;
  line-height: 1;
  cursor: pointer;
}
.signup-cta-close:hover {
  border-color: var(--accent);
  color: var(--accent-deep);
}
.signup-cta-title {
  font-size: 1.2rem;
  margin-block-end: 0.4rem;
}
.signup-cta-sub {
  color: var(--text-2);
  font-size: 0.94rem;
  margin-block-end: 1.1rem;
}
.signup-cta-form {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.signup-cta-input {
  width: 100%;
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--text);
  background: var(--cream);
  border: 1px solid var(--border);
  border-radius: 99px;
  padding: 0.7rem 1rem;
}
.signup-cta-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-line);
}
/* Row 38: business-only optional message — same field chrome as the email
   input, just a taller box with left-aligned text and no pill radius. */
.signup-cta-textarea {
  width: 100%;
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--text);
  background: var(--cream);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.65rem 1rem;
  resize: vertical;
  text-align: start;
}
.signup-cta-textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-line);
}
.signup-cta-textarea[hidden] {
  display: none;
}
.signup-cta-done {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--accent-deep);
}
