/* ═══════════════════════════════════════════════════════════════
   Helvecraft v15 — Editorial dark, Swiss-Luxury
   Anthropic typography × Resend layout × minimal premium
   ═══════════════════════════════════════════════════════════════ */

:root {
  /* Palette — black, white, one premium gold */
  --bg:          #0A0A0A;
  --bg-elev:     #131313;
  --bg-card:     #1A1A1A;
  --ink:         #F5F5F5;
  --ink-soft:    #B0B0B0;
  --ink-mute:    #8A8A8A;
  --rule:        rgba(255, 255, 255, 0.07);
  --rule-strong: rgba(255, 255, 255, 0.16);
  --accent:      #C9A961;
  --accent-dim:  rgba(201, 169, 97, 0.16);
  /* Vidima brand — SEPARATE identity, never mix with Helvecraft accent */
  --vidima-brand:      #8B1538;  /* canonical granate, light bg */
  --vidima-brand-dark: #c64a72;  /* lighter granate for dark bg */
  --vidima-brand-dim:  rgba(198, 74, 114, 0.18);
  --vidima-paper:      #F6F4EF;  /* Vidima cream bg — only inside the Vidima card */
  /* Cloqora brand — SEPARATE identity (emerald), never mix with Helvecraft accent */
  --cloqora-brand:      #10b981;  /* emerald, light bg */
  --cloqora-brand-dark: #4edea3;  /* emerald-400 for dark bg */
  --cloqora-brand-dim:  rgba(78, 222, 163, 0.16);
  --status-active: #6EE787;
  --status-soon:   #6E6E6E;
  --status-beta:   #4edea3;

  --f-serif: 'Instrument Serif', 'EB Garamond', Georgia, serif;
  --f-sans:  'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  --f-mono:  'JetBrains Mono', ui-monospace, 'SF Mono', Consolas, monospace;

  --container:  1240px;
  --container-narrow: 880px;
  --r-sm: 4px;
  --r-md: 8px;
  --r-lg: 14px;

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);

  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--f-sans);
  font-size: 16px;
  line-height: 1.65;
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
::selection { background: var(--accent); color: var(--bg); }

.skip {
  position: absolute; top: -50px; left: 16px;
  background: var(--ink); color: var(--bg); padding: 8px 16px;
  font-family: var(--f-mono); font-size: 12px;
  border-radius: var(--r-sm);
}
.skip:focus { top: 12px; outline: 2px solid var(--accent); }

.container { max-width: var(--container); margin: 0 auto; padding: 0 32px; }
.container--narrow { max-width: var(--container-narrow); }
@media (max-width: 640px) { .container { padding: 0 20px; } }

h1, h2, h3, h4 {
  font-family: var(--f-serif);
  font-weight: 400;
  letter-spacing: -0.022em;
  line-height: 1.05;
  margin: 0;
  color: var(--ink);
}
h1 { font-size: clamp(3.25rem, 8vw, 6rem); line-height: 0.98; }
h2 { font-size: clamp(2.25rem, 4.5vw, 3.5rem); }
h3 { font-size: clamp(1.5rem, 2.4vw, 2rem); line-height: 1.15; }
h4 { font-size: 1.2rem; line-height: 1.3; }
em, .em { font-style: italic; color: var(--accent); }
p { margin: 0; color: var(--ink-soft); }
p + p { margin-top: 1.1em; }
.lede { font-size: clamp(1.05rem, 1.6vw, 1.25rem); line-height: 1.55; color: var(--ink-soft); max-width: 60ch; }

.kicker {
  display: inline-block;
  font-family: var(--f-mono); font-size: 11px; font-weight: 500;
  letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--ink-mute); margin-bottom: 18px;
}
.kicker__num { color: var(--accent); font-weight: 600; margin-right: 8px; }

a { color: var(--accent); text-decoration: none; transition: color 0.15s; }
a:hover { color: var(--ink); }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px; }

/* ─── Header ─── */
.header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(10, 10, 10, 0.78);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--rule);
}
.header__inner {
  max-width: var(--container); margin: 0 auto;
  padding: 18px 32px;
  display: flex; align-items: center; justify-content: space-between; gap: 32px;
}
@media (max-width: 640px) { .header__inner { padding: 16px 20px; } }

.brand {
  display: inline-flex; align-items: center; gap: 12px;
  text-decoration: none; color: var(--ink);
  font-family: var(--f-serif); font-size: 1.35rem; letter-spacing: -0.012em;
}
.brand__mark { width: 26px; height: 26px; flex: none; color: currentColor; }
.brand__word { line-height: 1; }

.nav { display: flex; gap: 36px; align-items: center; }
@media (max-width: 720px) { .nav { gap: 22px; } .nav__link--hide-mobile { display: none; } }
.nav__link {
  font-family: var(--f-mono); font-size: 11px; font-weight: 500;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--ink-soft); text-decoration: none;
  position: relative; padding: 4px 0;
  transition: color 0.15s;
}
.nav__link:hover, .nav__link.is-active { color: var(--ink); }
.nav__link.is-active::after {
  content: ''; position: absolute; bottom: -3px; left: 0; right: 0;
  height: 1px; background: var(--accent);
}
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

/* ─── Section ─── */
section { padding: 96px 0; border-top: 1px solid var(--rule); position: relative; }
section.hero { padding-top: 120px; padding-bottom: 96px; border-top: none; }
@media (max-width: 720px) { section { padding: 64px 0; } section.hero { padding-top: 80px; padding-bottom: 64px; } }

.section-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 32px; margin-bottom: 56px; flex-wrap: wrap;
}
.section-head__main { max-width: 40ch; }
.section-head__aside { max-width: 40ch; }
@media (max-width: 720px) { .section-head { margin-bottom: 40px; } }

/* ─── CTA ─── */
.cta {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 16px 28px;
  font-family: var(--f-mono); font-size: 12px; font-weight: 500;
  letter-spacing: 0.14em; text-transform: uppercase;
  background: var(--accent); color: #0A0A0A;
  border: 1px solid var(--accent); border-radius: var(--r-sm);
  text-decoration: none; cursor: pointer;
  transition: background 0.18s var(--ease-out), color 0.18s, border-color 0.18s, transform 0.18s;
  white-space: nowrap;
}
.cta:hover { background: var(--ink); color: var(--bg); border-color: var(--ink); transform: translateY(-1px); }
.cta:active { transform: translateY(0); }
.cta--ghost { background: transparent; color: var(--ink); border-color: var(--rule-strong); }
.cta--ghost:hover { background: rgba(255,255,255,0.04); border-color: var(--ink); color: var(--ink); }
.cta__arrow { transition: transform 0.18s var(--ease-out); }
.cta:hover .cta__arrow { transform: translate(2px, -2px); }

/* ─── Cards ─── */
.card {
  background: var(--bg-card); border: 1px solid var(--rule);
  border-radius: var(--r-lg); padding: 32px;
  transition: border-color 0.2s, background 0.2s, transform 0.2s var(--ease-out);
  display: flex; flex-direction: column;
}
.card:hover { border-color: color-mix(in srgb, var(--gold, #C9A86A) 35%, var(--rule-strong)); background: #1F1F1F; box-shadow: 0 18px 44px -26px rgba(0,0,0,.55); }
.card--link { text-decoration: none; color: inherit; cursor: pointer; }
.card--link:hover { transform: translateY(-3px); }
.card__top { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 28px; }
.card__icon {
  width: 48px; height: 48px; border-radius: var(--r-md);
  background: var(--accent-dim); color: var(--accent);
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--f-serif); font-size: 1.7rem; flex: none;
}
.card__icon--vidima { font-style: normal; background: var(--vidima-brand-dim); color: var(--vidima-brand-dark); }
.card__icon--image { padding: 0; overflow: hidden; background: transparent; }
.card__icon--image img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; display: block; }
.card__name { font-family: var(--f-serif); font-size: 1.65rem; margin: 0 0 4px; line-height: 1.1; }
.card__version { font-family: var(--f-mono); font-size: 11px; color: var(--ink-mute); letter-spacing: 0.1em; }
.card__desc { color: var(--ink-soft); margin: 16px 0 24px; font-size: 0.95rem; line-height: 1.55; flex: 1; }
.card__bottom { display: flex; justify-content: space-between; align-items: center; padding-top: 20px; border-top: 1px solid var(--rule); gap: 16px; }
.card__meta { font-family: var(--f-mono); font-size: 11px; color: var(--ink-mute); letter-spacing: 0.05em; }
.card__meta--price { color: var(--accent); font-weight: 500; font-size: 12px; letter-spacing: 0.06em; }

/* Status pills */
.status {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--f-mono); font-size: 10px; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--ink-mute);
}
.status::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--status-soon); display: inline-block; }
.status--active { color: var(--status-active); }
.status--active::before { background: var(--status-active); box-shadow: 0 0 8px rgba(110, 231, 135, 0.5); }
.status--beta { color: var(--status-beta); }
.status--beta::before { background: var(--status-beta); box-shadow: 0 0 8px rgba(78, 222, 163, 0.45); }

/* Link arrow */
.link-arrow {
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--accent); font-family: var(--f-mono); font-size: 12px;
  letter-spacing: 0.1em; text-transform: uppercase; font-weight: 500;
  transition: gap 0.15s;
}
.link-arrow:hover { gap: 12px; }
.link-arrow svg { transition: transform 0.18s var(--ease-out); }
.link-arrow:hover svg { transform: translate(3px, -3px); }

/* ─── Grid ─── */
.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 900px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }

/* ─── Feature row ─── */
.feature-row { display: grid; grid-template-columns: 1fr 1.4fr; gap: 64px; align-items: center; }
@media (max-width: 900px) { .feature-row { grid-template-columns: 1fr; gap: 40px; } }
.feature-row__visual {
  aspect-ratio: 4/3; background: var(--bg-elev);
  border: 1px solid var(--rule); border-radius: var(--r-lg);
  display: flex; align-items: center; justify-content: center;
  position: relative; overflow: hidden;
}

/* ─── Stats line ─── */
.stats-line {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 0;
  border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule);
}
.stat { padding: 32px 24px; border-right: 1px solid var(--rule); }
.stat:last-child { border-right: none; }
.stat__num { font-family: var(--f-serif); font-size: 2.75rem; line-height: 1; color: var(--ink); letter-spacing: -0.02em; margin-bottom: 8px; }
.stat__num em { color: var(--accent); }
.stat__lbl { font-family: var(--f-mono); font-size: 10px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--ink-mute); }
@media (max-width: 900px) { .stats-line { grid-template-columns: repeat(2, 1fr); } .stat:nth-child(2) { border-right: none; } .stat:nth-child(1), .stat:nth-child(2) { border-bottom: 1px solid var(--rule); } }
@media (max-width: 480px) { .stats-line { grid-template-columns: 1fr; } .stat { border-right: none; border-bottom: 1px solid var(--rule); } .stat:last-child { border-bottom: none; } }

/* ─── Footer ─── */
.footer { border-top: 1px solid var(--rule); padding: 72px 0 40px; }
.footer__top {
  display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 48px; padding-bottom: 48px; border-bottom: 1px solid var(--rule);
}
@media (max-width: 900px) { .footer__top { grid-template-columns: repeat(2, 1fr); gap: 40px; } }
@media (max-width: 480px) { .footer__top { grid-template-columns: 1fr; } }
.footer__brand-block .brand { margin-bottom: 16px; }
.footer__about { color: var(--ink-mute); font-size: 0.92rem; line-height: 1.55; max-width: 32ch; }
.footer__col h4 { font-family: var(--f-mono); font-size: 10px; font-weight: 500; letter-spacing: 0.18em; text-transform: uppercase; color: var(--ink-mute); margin: 0 0 18px; }
.footer__col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.footer__col a { color: var(--ink-soft); font-size: 0.92rem; text-decoration: none; }
.footer__col a:hover { color: var(--ink); }
.footer__bottom {
  display: flex; justify-content: space-between; align-items: center;
  padding-top: 32px; gap: 24px; flex-wrap: wrap;
  font-family: var(--f-mono); font-size: 10px; letter-spacing: 0.15em;
  text-transform: uppercase; color: var(--ink-mute);
}
.footer__legal {
  flex-basis: 100%; text-align: center; opacity: 0.65;
  letter-spacing: 0.12em;
}

/* ─── Loader (H staircase only) ─── */
/* Solo existe con JS: sin JS (crawler, lector) el contenido queda visible. */
html:not(.js) .loader { display: none; }
.loader {
  position: fixed; inset: 0; z-index: 1000;
  background: var(--bg);
  display: flex; align-items: center; justify-content: center;
  pointer-events: none;
}
body.is-pre-loader { overflow: hidden; }
.loader__mark { width: 112px; height: 112px; color: var(--ink); display: block; overflow: visible; }
.loader__step, .loader__stem { opacity: 0; transform-box: fill-box; transform-origin: center; }

/* Reveal animations */
html.js [data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out); }
html.js [data-reveal].is-visible { opacity: 1; transform: none; }
html.js [data-reveal-stagger] > * { opacity: 0; transform: translateY(20px); transition: opacity 0.6s var(--ease-out), transform 0.6s var(--ease-out); }
[data-reveal-stagger].is-visible > *:nth-child(1) { transition-delay: 0s; }
[data-reveal-stagger].is-visible > *:nth-child(2) { transition-delay: 0.08s; }
[data-reveal-stagger].is-visible > *:nth-child(3) { transition-delay: 0.16s; }
[data-reveal-stagger].is-visible > *:nth-child(4) { transition-delay: 0.24s; }
[data-reveal-stagger].is-visible > *:nth-child(5) { transition-delay: 0.32s; }
[data-reveal-stagger].is-visible > *:nth-child(6) { transition-delay: 0.4s; }
html.js [data-reveal-stagger].is-visible > * { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  [data-reveal], [data-reveal-stagger] > * { opacity: 1; transform: none; transition: none; }
  .loader__step, .loader__stem { opacity: 1; }
}

/* ─── Utilities ─── */
.text-mute { color: var(--ink-mute); }
.text-soft { color: var(--ink-soft); }
.text-accent { color: var(--accent); }
.font-mono { font-family: var(--f-mono); }
.font-serif { font-family: var(--f-serif); }
.mt-2 { margin-top: 16px; } .mt-4 { margin-top: 32px; } .mt-6 { margin-top: 48px; } .mt-8 { margin-top: 64px; }
.mb-2 { margin-bottom: 16px; } .mb-4 { margin-bottom: 32px; } .mb-6 { margin-bottom: 48px; }
hr { border: 0; border-top: 1px solid var(--rule); margin: 0; }

/* ─── Pricing card (vidima page) ─── */
.price-card {
  max-width: 480px; margin: 0;
  background: var(--bg-card); border: 1px solid var(--rule-strong); border-radius: var(--r-lg);
  padding: 48px 40px; position: relative; text-align: left;
}
.price-card__badge {
  position: absolute; top: -10px; left: 32px; transform: none;
  background: var(--accent); color: var(--bg);
  font-family: var(--f-mono); font-size: 10px; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase;
  padding: 6px 14px; border-radius: 999px; white-space: nowrap;
}
.price-card__price { font-family: var(--f-serif); font-size: 4.5rem; line-height: 1; letter-spacing: -0.03em; margin: 8px 0 12px; }
.price-card__price-cur { font-size: 1.5rem; color: var(--ink-mute); vertical-align: super; margin-right: 6px; }
.price-card__desc { color: var(--ink-soft); font-size: 0.95rem; line-height: 1.55; margin: 0 0 28px; }
.price-card__list { list-style: none; margin: 0 0 32px; padding: 0; }
.price-card__list li { padding: 12px 0; border-bottom: 1px solid var(--rule); font-size: 0.95rem; color: var(--ink-soft); display: flex; align-items: center; gap: 12px; }
.price-card__list li:last-child { border-bottom: none; }
.price-card__list svg { color: var(--accent); flex: none; width: 16px; height: 16px; }
.price-card .cta { width: 100%; justify-content: center; }

/* ─── Manifesto block (studio page) ─── */
.manifesto {
  font-family: var(--f-serif); font-size: clamp(1.5rem, 3vw, 2.25rem);
  line-height: 1.3; letter-spacing: -0.015em; color: var(--ink);
  max-width: 28ch;
}
.manifesto em { color: var(--accent); }

/* ─── Lang switcher dropdown ─── */
.lang-switch { position: relative; display: inline-flex; }
.lang-current {
  cursor: pointer; background: transparent; border: 1px solid var(--rule-strong);
  border-radius: var(--r-sm); padding: 6px 10px;
  font-family: var(--f-mono); font-size: 11px; font-weight: 500;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--ink-soft);
  display: inline-flex; align-items: center; gap: 6px;
  transition: border-color 0.15s, color 0.15s;
}
.lang-current:hover { border-color: var(--ink); color: var(--ink); }
.lang-current-caret { font-size: 9px; opacity: 0.6; transition: transform 0.15s; }
.lang-switch.open .lang-current-caret { transform: rotate(180deg); }
.lang-menu {
  position: absolute; top: calc(100% + 6px); right: 0;
  background: var(--bg-card); border: 1px solid var(--rule-strong);
  border-radius: var(--r-sm); padding: 4px; min-width: 170px;
  box-shadow: 0 12px 32px rgba(0,0,0,0.6);
  display: none; z-index: 60;
}
.lang-switch.open .lang-menu { display: block; animation: hvFadeDown 0.15s ease-out; }
@keyframes hvFadeDown { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.lang-menu-item {
  cursor: pointer; display: block; width: 100%; text-align: left;
  padding: 8px 12px; border: none; background: none;
  font-family: var(--f-mono); font-size: 11px; letter-spacing: 0.05em;
  color: var(--ink-soft); border-radius: var(--r-sm); transition: background 0.1s, color 0.1s;
}
.lang-menu-item:hover { background: rgba(255,255,255,0.05); color: var(--ink); }
.lang-menu-item[aria-current="true"] { background: var(--accent); color: var(--bg); }
@media (max-width: 720px) {
  .lang-menu { right: 0; min-width: 140px; }
  .lang-current { padding: 6px 8px; }
}

/* ════════════════ AI Chat widget ════════════════ */
.chat-fab {
  position: fixed; bottom: 24px; right: 24px; z-index: 80;
  width: 56px; height: 56px;
  background: var(--accent); color: var(--bg);
  border: 1px solid var(--accent); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(201, 169, 97, 0.3);
  transition: transform 0.2s var(--ease-out), box-shadow 0.2s;
}
.chat-fab:hover { transform: scale(1.05); box-shadow: 0 12px 32px rgba(201, 169, 97, 0.45); }
.chat-fab svg { width: 24px; height: 24px; }
.chat-fab.hidden { display: none; }

.chat-panel {
  position: fixed; bottom: 24px; right: 24px; z-index: 81;
  width: 400px; max-width: calc(100vw - 48px);
  height: 600px; max-height: calc(100vh - 100px);
  background: var(--bg-card); border: 1px solid var(--rule-strong);
  border-radius: var(--r-lg);
  display: none; flex-direction: column;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.6);
  overflow: hidden;
}
.chat-panel.open { display: flex; animation: chatIn 0.25s var(--ease-out); }
@keyframes chatIn { from { opacity: 0; transform: translateY(20px) scale(0.98); } to { opacity: 1; transform: none; } }

.chat-header {
  padding: 18px 20px; border-bottom: 1px solid var(--rule);
  display: flex; align-items: center; justify-content: space-between;
  flex: none; background: var(--bg-elev);
}
.chat-header-info { display: flex; flex-direction: column; gap: 4px; }
.chat-title {
  font-family: var(--f-serif); font-size: 1.25rem; line-height: 1;
  color: var(--ink); letter-spacing: -0.012em;
}
.chat-subtitle {
  font-family: var(--f-mono); font-size: 10px; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--ink-mute);
}
.chat-close {
  background: none; border: none; color: var(--ink-soft);
  cursor: pointer; font-size: 24px; line-height: 1;
  padding: 4px 8px; border-radius: var(--r-sm);
  transition: color 0.15s, background 0.15s;
}
.chat-close:hover { color: var(--ink); background: rgba(255, 255, 255, 0.05); }

.chat-messages {
  flex: 1 1 auto; padding: 20px; overflow-y: auto;
  display: flex; flex-direction: column; gap: 14px;
  background: var(--bg-card);
}
.chat-messages::-webkit-scrollbar { width: 6px; }
.chat-messages::-webkit-scrollbar-thumb { background: var(--rule-strong); border-radius: 3px; }

.chat-msg {
  max-width: 88%; padding: 11px 15px;
  border-radius: 12px; font-size: 14px; line-height: 1.55;
  word-wrap: break-word; white-space: pre-wrap;
  animation: msgIn 0.2s var(--ease-out);
}
@keyframes msgIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
.chat-msg--user {
  align-self: flex-end; background: var(--accent); color: var(--bg);
  border-bottom-right-radius: 4px;
}
.chat-msg--assistant {
  align-self: flex-start; background: rgba(255, 255, 255, 0.05);
  color: var(--ink); border: 1px solid var(--rule);
  border-bottom-left-radius: 4px;
}
.chat-msg--assistant em { color: var(--accent); font-style: italic; }
.chat-msg--assistant strong { color: var(--ink); font-weight: 500; }
.chat-msg--assistant a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }

.chat-typing { display: inline-flex; gap: 4px; padding: 4px 0; align-items: center; }
.chat-typing span {
  width: 6px; height: 6px; border-radius: 50%; background: var(--ink-mute);
  animation: typingDot 1.2s infinite ease-in-out;
}
.chat-typing span:nth-child(2) { animation-delay: 0.15s; }
.chat-typing span:nth-child(3) { animation-delay: 0.3s; }
@keyframes typingDot { 0%, 100% { opacity: 0.3; transform: translateY(0); } 50% { opacity: 1; transform: translateY(-2px); } }

.chat-input-area {
  padding: 14px 18px 16px; border-top: 1px solid var(--rule);
  flex: none; background: var(--bg-elev);
}
.chat-input-row { display: flex; gap: 8px; align-items: flex-end; }
.chat-input {
  flex: 1; background: var(--bg-card); border: 1px solid var(--rule);
  border-radius: var(--r-sm); padding: 10px 12px;
  font-family: var(--f-sans); font-size: 14px; color: var(--ink);
  resize: none; min-height: 40px; max-height: 120px;
  line-height: 1.4;
  transition: border-color 0.15s;
}
.chat-input:focus { outline: none; border-color: var(--accent); }
.chat-input::placeholder { color: var(--ink-mute); }
.chat-send {
  background: var(--accent); color: var(--bg); border: none;
  border-radius: var(--r-sm); padding: 10px 14px;
  cursor: pointer; flex: none;
  font-family: var(--f-mono); font-size: 11px; font-weight: 500;
  letter-spacing: 0.14em; text-transform: uppercase;
  transition: background 0.15s, opacity 0.15s;
}
.chat-send:hover:not(:disabled) { background: var(--ink); color: var(--bg); }
.chat-send:disabled { opacity: 0.5; cursor: not-allowed; }

.chat-disclaimer {
  font-family: var(--f-mono); font-size: 9px; letter-spacing: 0.12em;
  color: var(--ink-mute); margin-top: 10px; text-align: center;
  text-transform: uppercase;
}

@media (max-width: 480px) {
  .chat-panel { right: 12px; left: 12px; bottom: 12px; width: auto; height: calc(100vh - 80px); max-height: none; }
  .chat-fab { right: 16px; bottom: 16px; width: 52px; height: 52px; }
}

/* ════════ v17.1 — Visual cohesion fixes ════════ */

/* When section-head has NO aside, expand main to fill */
.section-head:not(:has(.section-head__aside)) .section-head__main,
.section-head--full .section-head__main { max-width: none; }

/* Pricing section in /vidima/ — center the whole block for visual harmony */
.price-section { text-align: center; }
.price-section .section-head { justify-content: center; }
.price-section .section-head__main { text-align: left; max-width: 480px; margin: 0 auto; }
.price-section .price-card { margin: 0 auto; }
.price-section .price-card__badge { left: 50%; transform: translateX(-50%); }

/* Vidima hero h1 — reinforce visual weight */
.page-vidima .hero h1 {
  font-size: clamp(4.5rem, 11vw, 8.5rem);
  letter-spacing: -0.03em;
  line-height: 0.95;
}

/* Tighten the gap between title and lede across all heroes for a more
   editorial feel (less floaty) */
.hero h1 + .lede { margin-top: 2rem; }

/* Generic alignment cohesion: kicker + h2 always start on same x-axis */
.section-head__main .kicker { display: inline-block; }

/* Stats-line — give it a kicker label above for clarity */
.stats-line__caption {
  font-family: var(--f-mono); font-size: 10px; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--ink-mute);
  margin-bottom: 24px; display: block;
}

/* ════════════════ Chat rating overlay ════════════════ */
.chat-panel.chat-panel--rating .chat-messages,
.chat-panel.chat-panel--rating .chat-input-area { display: none; }
.chat-rating {
  display: none; flex: 1; padding: 32px 24px;
  flex-direction: column; align-items: center; justify-content: center;
  text-align: center; gap: 18px;
}
.chat-panel--rating .chat-rating { display: flex; }
.chat-rating-title {
  font-family: var(--f-serif); font-size: 1.5rem; line-height: 1.15;
  color: var(--ink); letter-spacing: -0.015em; max-width: 24ch;
}
.chat-rating-subtitle {
  font-family: var(--f-mono); font-size: 10px; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--ink-mute);
}
.chat-stars {
  display: flex; gap: 6px; margin: 4px 0;
}
.chat-star {
  background: none; border: none; cursor: pointer;
  font-size: 32px; line-height: 1; padding: 4px 6px;
  color: var(--rule-strong);
  transition: color 0.15s, transform 0.15s var(--ease-out);
}
.chat-star:hover, .chat-star.is-hover, .chat-star.is-active { color: var(--accent); }
.chat-star.is-active { transform: scale(1.08); }
.chat-rating-comment {
  width: 100%; max-width: 320px;
  background: var(--bg-card); border: 1px solid var(--rule);
  border-radius: var(--r-sm); padding: 10px 12px;
  font-family: var(--f-sans); font-size: 13px; color: var(--ink);
  resize: none; min-height: 60px; max-height: 100px;
}
.chat-rating-comment:focus { outline: none; border-color: var(--accent); }
.chat-rating-actions { display: flex; gap: 8px; }
.chat-rating-thanks {
  font-family: var(--f-serif); font-size: 1.2rem; color: var(--ink);
  animation: thanksIn 0.4s var(--ease-out);
}
@keyframes thanksIn { from { opacity: 0; transform: scale(0.95); } to { opacity: 1; transform: none; } }

/* ============================================
   HAMBURGER — Unicode chars for iOS Safari
   ============================================ */
.hamburger {
  display: none;
  background: transparent;
  -webkit-appearance: none;
  appearance: none;
  border: none;
  cursor: pointer;
  padding: 0;
  width: 44px;
  height: 44px;
  color: #F5F5F5;
  font-size: 26px;
  line-height: 44px;
  text-align: center;
  z-index: 210;
}
.hamburger .hb-open,
.hamburger .hb-close {
  display: inline-block;
  color: #F5F5F5;
  font-weight: normal;
  pointer-events: none;
}
.hamburger .hb-close { display: none; }
.hamburger.is-open .hb-open { display: none; }
.hamburger.is-open .hb-close { display: inline-block; }
@media (max-width: 640px) {
  .hamburger { display: inline-block; }
}

/* ============================================
   FOOTER — horizontal compact on mobile (<=640)
   Brand spans top row, 3 cols sit horizontally below
   ============================================ */
@media (max-width: 640px) {
  .footer__top {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    grid-auto-rows: auto !important;
    text-align: center !important;
    gap: 28px 12px !important;
    padding-top: 32px;
    padding-bottom: 24px;
  }
  .footer__brand-block {
    grid-column: 1 / -1 !important;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
  }
  .footer__about {
    max-width: 320px;
    margin-left: auto;
    margin-right: auto;
    font-size: 13px;
    line-height: 1.5;
  }
  .footer__col {
    text-align: center;
    padding: 0;
  }
  .footer__col h4 {
    font-size: 10px;
    letter-spacing: 0.16em;
    margin: 0 0 8px;
    color: var(--ink-mute);
  }
  .footer__col ul { padding: 0; margin: 0; list-style: none; }
  .footer__col li { font-size: 12px; margin: 4px 0; line-height: 1.3; }
  .footer__col a { font-size: 12px; }
  .footer__bottom {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: wrap !important;
    justify-content: center !important;
    align-items: center !important;
    text-align: center !important;
    gap: 6px 16px !important;
    font-size: 10.5px;
    padding-top: 16px;
    padding-bottom: 16px;
  }
}

/* ============================================
   NAV DRAWER — slide-from-right on mobile (<=640)
   Converts .nav (inline horizontal links) into
   a side panel hidden offscreen until hamburger
   adds .is-open class
   ============================================ */
@media (max-width: 640px) {
  /* CRITICAL: remove backdrop-filter on mobile — it creates a containing block
     for position:fixed children, trapping the drawer inside the header bounds.
     Also raise header z-index ABOVE the backdrop so drawer (inside header
     stacking context) receives clicks instead of the backdrop. */
  .header {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    background: rgba(10, 10, 10, 0.95) !important;
    z-index: 220 !important;
  }
  .hamburger {
    position: relative !important;
    z-index: 250 !important;
  }
  .nav {
    position: fixed !important;
    top: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    left: auto !important;
    width: 86% !important;
    max-width: 320px !important;
    background: #131313 !important;
    border-left: 1px solid rgba(255,255,255,0.16) !important;
    flex-direction: column !important;
    justify-content: flex-start !important;
    align-items: stretch !important;
    gap: 0 !important;
    padding: 76px 0 24px !important;
    transform: translateX(100%) !important;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
    z-index: 200 !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
    display: flex !important;
  }
  .nav.is-open {
    transform: translateX(0) !important;
  }
  .nav .nav__link,
  .nav__link {
    display: block !important;
    font-family: var(--f-sans, system-ui, sans-serif) !important;
    font-size: 1rem !important;
    font-weight: 500 !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
    color: var(--ink, #F5F5F5) !important;
    padding: 16px 24px !important;
    border-bottom: 1px solid var(--rule, rgba(255,255,255,0.07)) !important;
    width: 100% !important;
    text-align: left !important;
  }
  .nav .nav__link--hide-mobile,
  .nav__link--hide-mobile {
    display: block !important;
  }
  .nav .nav__link.is-active::after,
  .nav__link.is-active::after {
    display: none !important;
  }
  .nav .lang-switch,
  .lang-switch {
    margin: 20px 24px 0 !important;
    width: calc(100% - 48px) !important;
    position: relative !important;
  }
  .nav .lang-current,
  .lang-current {
    display: flex !important;
    width: 100% !important;
    justify-content: space-between !important;
    align-items: center !important;
    padding: 14px 16px !important;
    font-family: var(--f-mono, monospace) !important;
    font-size: 0.85rem !important;
    background: var(--bg-card, #1A1A1A) !important;
    border: 1px solid var(--rule, rgba(255,255,255,0.07)) !important;
    border-radius: var(--r-sm, 4px) !important;
    color: var(--ink, #F5F5F5) !important;
  }
  .nav .lang-menu,
  .lang-menu {
    position: static !important;
    transform: none !important;
    box-shadow: none !important;
    margin-top: 8px !important;
    min-width: 0 !important;
    width: 100% !important;
    background: var(--bg-card, #1A1A1A) !important;
    border: 1px solid var(--rule, rgba(255,255,255,0.07)) !important;
    border-radius: var(--r-sm, 4px) !important;
    overflow: hidden;
  }
  .nav .lang-menu-item,
  .lang-menu-item {
    width: 100% !important;
    text-align: left !important;
    padding: 12px 16px !important;
    font-size: 0.9rem !important;
    background: transparent !important;
    border: none !important;
    color: var(--ink, #F5F5F5) !important;
    cursor: pointer !important;
  }
  .nav .lang-menu-item + .lang-menu-item,
  .lang-menu-item + .lang-menu-item {
    border-top: 1px solid var(--rule, rgba(255,255,255,0.07)) !important;
  }

  /* JS-injected backdrop div (no pseudo-element to avoid click conflicts) */
  .nav-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    z-index: 180;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  }
  body.nav-open .nav-backdrop {
    opacity: 1;
    pointer-events: auto;
  }
  body.nav-open {
    overflow: hidden;
  }
}

/* ════════════════════════════════════════════════════════════════
   v18 — Redesign: hero H watermark, product card previews, tiles,
   line icons, reassurance notes, reveal refinements
   ════════════════════════════════════════════════════════════════ */

/* ─── Hero — stroke-drawn H watermark (home) ─── */
section.hero { overflow: hidden; }
section.hero > .container { position: relative; z-index: 1; }
.hero-mark {
  position: absolute; top: 50%; right: 4%;
  transform: translateY(-52%);
  width: min(34vw, 420px); height: auto;
  color: var(--accent); opacity: 0.15;
  pointer-events: none; z-index: 0;
}
.hero-mark path { fill: none; stroke: currentColor; stroke-width: 1.5; vector-effect: non-scaling-stroke; }
html.js .hero-mark path {
  stroke-dasharray: 1; stroke-dashoffset: 1;
  animation: hvDraw 3s var(--ease-out) 0.5s forwards;
}
@keyframes hvDraw { to { stroke-dashoffset: 0; } }
@media (max-width: 720px) { .hero-mark { display: none; } }
@media (prefers-reduced-motion: reduce) {
  html.js .hero-mark path { animation: none; stroke-dashoffset: 0; }
}

/* ─── Product card mini-preview — typographic, brand-scoped ─── */
.card__preview {
  display: flex; align-items: center; gap: 22px;
  min-height: 96px; padding: 20px 24px;
  border-radius: var(--r-md); margin-bottom: 24px;
}
.card__preview-v {
  font-family: var(--f-serif); font-style: normal;
  font-size: 3.4rem; line-height: 0.85; flex: none;
}
.card__preview-doc { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.card__preview-tag {
  font-family: var(--f-mono); font-size: 9px; font-weight: 500;
  letter-spacing: 0.2em; text-transform: uppercase;
}
.card__preview-line { display: block; height: 1px; width: 100%; }
.card__preview-line--70 { width: 70%; }
.card__preview-line--45 { width: 45%; }
/* Vidima — cream + granate, ONLY inside the Vidima card */
.card__preview--vidima { background: var(--vidima-paper); }
.card__preview--vidima .card__preview-v { color: var(--vidima-brand); }
.card__preview--vidima .card__preview-tag { color: var(--vidima-brand); }
.card__preview--vidima .card__preview-line { background: var(--vidima-brand); opacity: 0.22; }
/* Cloqora — editorial silhouette, subdued */
.card__preview--cloqora { background: var(--bg-elev); border: 1px solid var(--rule); }
.card__preview--cloqora .card__preview-tag { color: var(--cloqora-brand-dark); }
.card__preview--cloqora .card__preview-line { background: var(--ink-soft); opacity: 0.28; }
.card__preview--cloqora .card__preview-line--erased {
  background: none; height: 0; opacity: 0.55;
  border-top: 1px dashed var(--ink-mute);
}

/* ─── Tile — hairline panel for principle blocks / contact columns ─── */
.tile {
  background: var(--bg-card); border: 1px solid var(--rule);
  border-radius: var(--r-lg); padding: 32px 28px;
}

/* ─── Line icons (stroke only, gold) ─── */
.li-icon { width: 26px; height: 26px; color: var(--accent); display: block; margin-bottom: 16px; flex: none; }
.li-icon--sm { width: 16px; height: 16px; margin-bottom: 0; }

/* ─── Vidima teaser — final CTA section ─── */
.vidima-final { text-align: center; }
.vidima-final .lede { margin-left: auto; margin-right: auto; }
.vidima-final .cta { padding: 20px 40px; font-size: 13px; }
.cta-trust {
  margin-top: 20px;
  font-family: var(--f-mono); font-size: 10px; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--ink-mute);
}

/* ─── Contact — reassurance note ─── */
.reply-note {
  display: inline-flex; align-items: center; gap: 10px;
  margin-top: 20px;
  font-family: var(--f-mono); font-size: 10.5px; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--accent);
}

/* ─── Reveal refinement — stagger covers up to 8 children ─── */
[data-reveal-stagger].is-visible > *:nth-child(7) { transition-delay: 0.48s; }
[data-reveal-stagger].is-visible > *:nth-child(8) { transition-delay: 0.56s; }
