/* ==========================================================================
   AsistoBot — Estilos
   1. Tokens   2. Base   3. Layout   4. Componentes   5. Secciones
   6. Ilustraciones   7. Páginas legales   8. Responsive   9. Movimiento
   ========================================================================== */

/* 1. Tokens ---------------------------------------------------------------- */
:root {
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 24px;
  --container: 1160px;
  --header-h: 72px;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --wa: #22C55E;
  --wa-hover: #16A34A;
  --wa-text: #052E16;
  --danger: #EF4444;
}

:root,
[data-theme="dark"] {
  --bg: #0F172A;
  --surface: #1E293B;
  --surface-2: #162032;
  --text: #F8FAFC;
  --muted: #94A3B8;
  --accent: #818CF8;
  --accent-soft: rgba(129, 140, 248, .14);
  --border: rgba(148, 163, 184, .16);
  --shadow: 0 20px 50px -20px rgba(0, 0, 0, .6);
  --header-bg: rgba(15, 23, 42, .78);

  --chat-bg: #0B141A;
  --chat-header: #1F2C34;
  --bubble-in: #202C33;
  --bubble-out: #005C4B;
  --bubble-text: #E9EDEF;
  --bubble-meta: #8696A0;
}

[data-theme="light"] {
  --bg: #F8FAFC;
  --surface: #FFFFFF;
  --surface-2: #F1F5F9;
  --text: #0F172A;
  --muted: #64748B;
  --accent: #6366F1;
  --accent-soft: rgba(99, 102, 241, .10);
  --border: rgba(15, 23, 42, .10);
  --shadow: 0 20px 50px -24px rgba(15, 23, 42, .25);
  --header-bg: rgba(248, 250, 252, .82);

  --chat-bg: #EFEAE2;
  --chat-header: #F0F2F5;
  --bubble-in: #FFFFFF;
  --bubble-out: #D9FDD3;
  --bubble-text: #111B21;
  --bubble-meta: #667781;
}

/* 2. Base ------------------------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

/* Transición de tema suave (activada por JS tras el primer render) */
.theme-ready body,
.theme-ready .site-header,
.theme-ready .card,
.theme-ready .trust-item,
.theme-ready .feature-visual,
.theme-ready .faq-item,
.theme-ready .btn,
.theme-ready .icon-btn,
.theme-ready .lang-switch,
.theme-ready .badge,
.theme-ready .wa,
.theme-ready .wa-header,
.theme-ready .bubble,
.theme-ready .calendar,
.theme-ready .site-footer,
.theme-ready .legal-content {
  transition: background-color .35s var(--ease), color .35s var(--ease), border-color .35s var(--ease), box-shadow .35s var(--ease);
}

img, svg { display: block; max-width: 100%; }
h1, h2, h3, p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
button { font: inherit; color: inherit; cursor: pointer; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: 16px; top: -48px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  background: var(--accent);
  color: #fff;
}
.skip-link:focus { top: 12px; }

/* 3. Layout ---------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: 24px;
}
.container--narrow { max-width: 820px; }

.section { padding-block: clamp(64px, 9vw, 112px); }
.section--tight { padding-block: clamp(32px, 5vw, 56px); }
.section--alt { background: var(--surface-2); }

.section-head {
  max-width: 760px;
  margin: 0 auto clamp(40px, 5vw, 64px);
  text-align: center;
}

.section-title {
  font-size: clamp(1.75rem, 3.6vw, 2.6rem);
  line-height: 1.2;
  letter-spacing: -.02em;
  font-weight: 800;
}

.eyebrow {
  display: inline-block;
  margin-bottom: 12px;
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent);
}

/* 4. Componentes ----------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  border: 2px solid transparent;
  border-radius: 999px;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  white-space: nowrap;
  transition: transform .2s var(--ease), background-color .2s, border-color .2s, box-shadow .2s;
}
.btn:hover { text-decoration: none; transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn--sm { padding: 9px 16px; font-size: .9rem; }
.btn--lg { padding: 15px 26px; font-size: 1.02rem; }

.btn--wa {
  background: var(--wa);
  color: var(--wa-text);
  box-shadow: 0 10px 30px -10px rgba(34, 197, 94, .6);
}
.btn--wa:hover { background: var(--wa-hover); color: #fff; }

.btn--outline {
  border-color: var(--accent);
  color: var(--accent);
  background: transparent;
}
.btn--outline:hover { background: var(--accent-soft); }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border: 1px solid var(--accent);
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: .85rem;
  font-weight: 600;
}

.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 40px; height: 40px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  color: var(--text);
}
.icon-btn:hover { border-color: var(--accent); color: var(--accent); }

.icon {
  width: 20px; height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
[data-theme="dark"] .icon-moon,
[data-theme="light"] .icon-sun { display: none; }

.lang-switch {
  display: inline-flex;
  padding: 3px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
}
.lang-btn {
  min-width: 38px;
  padding: 6px 8px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--muted);
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .04em;
  transition: background-color .2s, color .2s;
}
.lang-btn:hover { color: var(--text); }
.lang-btn[aria-pressed="true"] { background: var(--accent); color: #fff; }

.card {
  padding: 28px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow);
}
.card h3 { margin-bottom: 10px; font-size: 1.15rem; line-height: 1.35; }
.card p { color: var(--muted); }

/* 5. Secciones ------------------------------------------------------------- */

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  background: var(--header-bg);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid transparent;
}
.site-header.is-scrolled { border-bottom-color: var(--border); box-shadow: 0 8px 24px -18px rgba(0, 0, 0, .5); }

.header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  height: 100%;
}

.brand { display: inline-flex; flex-shrink: 0; }
.brand .logo { height: 34px; width: auto; }
[data-theme="dark"] .logo--on-light,
[data-theme="light"] .logo--on-dark { display: none; }

.nav {
  display: flex;
  align-items: center;
  gap: 28px;
  margin-left: auto;
}
.nav-links { display: flex; gap: 26px; }
.nav-links a {
  color: var(--muted);
  font-weight: 600;
  font-size: .95rem;
  transition: color .2s;
}
.nav-links a:hover { color: var(--text); text-decoration: none; }

.header-tools { display: flex; align-items: center; gap: 10px; }
.menu-toggle { display: none; }

/* Hero */
.hero {
  position: relative;
  padding-block: clamp(48px, 7vw, 96px) clamp(56px, 8vw, 104px);
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: -40% -10% auto auto;
  width: 70vw; height: 70vw;
  max-width: 900px; max-height: 900px;
  background: radial-gradient(circle, var(--accent-soft) 0%, transparent 65%);
  pointer-events: none;
}

.hero-grid {
  position: relative;
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  align-items: center;
  gap: clamp(40px, 6vw, 80px);
}

.hero-title {
  margin-top: 22px;
  font-size: clamp(2.1rem, 4.8vw, 3.6rem);
  line-height: 1.08;
  letter-spacing: -.03em;
  font-weight: 800;
}
.text-gradient {
  background: linear-gradient(100deg, var(--accent) 0%, #22C55E 110%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-subtitle {
  margin-top: 22px;
  max-width: 560px;
  font-size: clamp(1.02rem, 1.5vw, 1.15rem);
  color: var(--muted);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 34px;
}

.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
}
.hero-glow {
  position: absolute;
  inset: 15% 10%;
  z-index: -1;
  background: radial-gradient(circle, rgba(34, 197, 94, .25), transparent 70%);
  filter: blur(40px);
}

/* Trust banner */
.trust {
  border-block: 1px solid var(--border);
  background: var(--surface-2);
  padding-block: 36px;
}
.trust-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.trust-item {
  padding: 22px 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.trust-item h3 { font-size: 1.05rem; line-height: 1.35; }
.trust-item p { margin-top: 6px; color: var(--muted); font-size: .94rem; }

/* Problema */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.card--problem { border-top: 3px solid var(--danger); }

/* Solución */
.features { display: grid; gap: clamp(56px, 7vw, 96px); }
.feature {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: clamp(32px, 6vw, 80px);
}
.feature--reverse .feature-copy { order: 2; }

.step {
  display: inline-grid;
  place-items: center;
  width: 44px; height: 44px;
  margin-bottom: 18px;
  border-radius: 12px;
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 800;
}
.feature h3 {
  font-size: clamp(1.35rem, 2.4vw, 1.75rem);
  line-height: 1.25;
  letter-spacing: -.01em;
}
.feature p { margin-top: 14px; color: var(--muted); font-size: 1.05rem; max-width: 480px; }

.feature-visual {
  display: grid;
  place-items: center;
  min-height: 300px;
  padding: clamp(24px, 4vw, 40px);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 80% 10%, var(--accent-soft), transparent 55%),
    var(--surface);
  box-shadow: var(--shadow);
}

/* Banner demo */
.demo-banner {
  position: relative;
  overflow: hidden;
  padding: clamp(40px, 6vw, 72px) clamp(24px, 5vw, 64px);
  border: 1px solid var(--accent);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 0% 0%, rgba(34, 197, 94, .18), transparent 50%),
    radial-gradient(circle at 100% 100%, var(--accent-soft), transparent 55%),
    var(--surface);
  text-align: center;
}
.demo-banner h2 {
  font-size: clamp(1.6rem, 3.4vw, 2.4rem);
  line-height: 1.2;
  letter-spacing: -.02em;
  font-weight: 800;
}
.demo-banner p {
  max-width: 560px;
  margin: 14px auto 30px;
  color: var(--muted);
  font-size: 1.08rem;
}

/* FAQ */
.faq { display: grid; gap: 14px; }
.faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.faq-item[open] { border-color: var(--accent); }
.faq-item summary {
  position: relative;
  padding: 20px 56px 20px 24px;
  font-weight: 700;
  font-size: 1.04rem;
  cursor: pointer;
  list-style: none;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "";
  position: absolute;
  right: 24px; top: 50%;
  width: 10px; height: 10px;
  border-right: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  transform: translateY(-70%) rotate(45deg);
  transition: transform .25s var(--ease);
}
.faq-item[open] summary::after { transform: translateY(-30%) rotate(-135deg); }
.faq-item p { padding: 0 24px 22px; color: var(--muted); }
.faq-item[open] p { animation: faq-in .3s var(--ease); }

@keyframes faq-in {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: none; }
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  background: var(--surface-2);
  padding-top: 64px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 40px;
}
.footer-brand .logo { height: 36px; }
.footer-brand p { margin-top: 16px; max-width: 300px; color: var(--muted); font-size: .95rem; }
.footer-col h3 {
  margin-bottom: 16px;
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.footer-col ul { display: grid; gap: 10px; color: var(--muted); font-size: .95rem; }
.footer-col a { color: var(--muted); }
.footer-col a:hover { color: var(--accent); }
.footer-col .label { color: var(--text); font-weight: 600; }

.footer-bottom {
  margin-top: 48px;
  padding-block: 24px;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: .88rem;
  text-align: center;
}

/* 6. Ilustraciones (mockups en HTML/CSS) ----------------------------------- */
.phone {
  position: relative;
  width: min(340px, 100%);
  padding: 12px;
  border-radius: 44px;
  background: linear-gradient(145deg, #334155, #0B1220);
  box-shadow: 0 40px 80px -30px rgba(0, 0, 0, .55), inset 0 0 0 2px rgba(255, 255, 255, .06);
}
.phone-notch {
  position: absolute;
  top: 20px; left: 50%;
  z-index: 2;
  width: 96px; height: 24px;
  border-radius: 999px;
  background: #020617;
  transform: translateX(-50%);
}
.phone .wa {
  display: flex;
  flex-direction: column;
  height: 600px;
  border-radius: 34px;
  overflow: hidden;
}

.wa {
  background-color: var(--chat-bg);
  background-image: radial-gradient(rgba(127, 127, 127, .09) 1px, transparent 1px);
  background-size: 14px 14px;
  color: var(--bubble-text);
  font-size: .86rem;
  line-height: 1.4;
}
.wa-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 46px 16px 12px;
  background: var(--chat-header);
}
.wa-avatar {
  display: grid;
  place-items: center;
  width: 36px; height: 36px;
  border-radius: 50%;
  background: #F8FAFC;
  overflow: hidden;
}
.wa-contact { display: grid; line-height: 1.25; }
.wa-contact small { color: var(--wa); font-size: .74rem; }

.wa-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 10px;
  padding: 18px 14px;
  overflow: hidden;
}

.bubble {
  position: relative;
  display: grid;
  gap: 6px;
  max-width: 85%;
  padding: 8px 10px 6px;
  border-radius: 12px;
  box-shadow: 0 1px 1px rgba(0, 0, 0, .12);
}
.bubble time {
  justify-self: end;
  color: var(--bubble-meta);
  font-size: .68rem;
}
.bubble--in { align-self: flex-start; background: var(--bubble-in); border-top-left-radius: 4px; }
.bubble--out { align-self: flex-end; background: var(--bubble-out); border-top-right-radius: 4px; }
.bubble--confirm { box-shadow: 0 0 0 1.5px var(--wa), 0 8px 20px -10px rgba(34, 197, 94, .7); }

.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  padding: 4px 10px;
  border: 1px solid var(--wa);
  border-radius: 999px;
  color: var(--wa);
  font-size: .76rem;
  font-weight: 700;
}
.chip--active { background: var(--wa); color: var(--wa-text); }

.wa-input {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 0 10px 14px;
  padding: 10px 8px 10px 16px;
  border-radius: 999px;
  background: var(--bubble-in);
  color: var(--bubble-meta);
}
.wa-send {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--wa);
}

/* Mini chats de la sección Solución */
.mini-chat {
  display: grid;
  gap: 10px;
  width: min(320px, 100%);
  padding: 18px;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.mini-chat .bubble { max-width: 100%; }

.catalog-list {
  display: grid;
  gap: 6px;
  margin-top: 4px;
}
.catalog-list li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 10px;
  border-radius: 8px;
  background: rgba(127, 127, 127, .1);
}
.catalog-list b { color: var(--wa); }
.catalog-cta {
  padding-top: 8px;
  border-top: 1px solid rgba(127, 127, 127, .2);
  color: #53BDEB;
  font-weight: 600;
  text-align: center;
}

.sync {
  display: grid;
  grid-template-columns: auto auto 1fr;
  align-items: center;
  gap: 12px;
  width: 100%;
}
.sync-chat { width: 160px; padding: 12px; }
.sync-chat .bubble { font-size: .78rem; }
.sync-arrow svg {
  width: 40px;
  fill: none;
  stroke: var(--accent);
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.calendar {
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg);
  font-size: .72rem;
}
.calendar-days {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  margin-bottom: 8px;
  color: var(--muted);
  font-weight: 700;
  text-align: center;
}
.calendar-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  grid-template-rows: repeat(5, 30px);
  gap: 4px;
  background-image: linear-gradient(var(--border) 1px, transparent 1px);
  background-size: 100% 34px;
}
.slot {
  grid-column: var(--c);
  grid-row: var(--r);
  border-radius: 6px;
}
.slot--busy { background: rgba(148, 163, 184, .22); }
.slot--new {
  display: grid;
  place-items: center;
  padding: 2px;
  background: var(--accent);
  color: #fff;
  font-size: .6rem;
  font-weight: 700;
  line-height: 1.1;
  text-align: center;
  box-shadow: 0 6px 16px -6px var(--accent);
}

.reminder-label {
  justify-self: center;
  padding: 3px 10px;
  border-radius: 8px;
  background: var(--bubble-in);
  color: var(--bubble-meta);
  font-size: .72rem;
  font-weight: 600;
}
.reply-btns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin-top: 4px;
}
.reply-btn {
  padding: 8px;
  border-radius: 8px;
  background: rgba(127, 127, 127, .12);
  color: #53BDEB;
  font-weight: 700;
  text-align: center;
}
.reply-btn:first-child { background: var(--wa); color: var(--wa-text); }

/* 7. Páginas legales ------------------------------------------------------- */
.site-footer--compact { padding-top: 0; }
.site-footer--compact .footer-bottom { margin-top: 0; border-top: 0; }

.legal {
  min-height: calc(100vh - var(--header-h) - 72px);
  padding-block: clamp(48px, 7vw, 88px);
}
.legal-back { display: inline-block; margin-bottom: 24px; font-weight: 600; }
.legal-content {
  padding: clamp(28px, 5vw, 56px);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
}
.legal-content h1 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  line-height: 1.2;
  letter-spacing: -.02em;
}
.legal-meta { margin-top: 8px; color: var(--muted); font-size: .92rem; }
.legal-body { margin-top: 32px; display: grid; gap: 16px; }
.legal-body:empty { min-height: 160px; }
.legal-body h2 { margin-top: 16px; font-size: 1.25rem; letter-spacing: -.01em; }
.legal-body p, .legal-body li { color: var(--muted); }
.legal-body ul {
  display: grid;
  gap: 10px;
  padding-left: 1.25em;
  list-style: disc;
}
.legal-body li::marker { color: var(--accent); }
.legal-body strong { color: var(--text); font-weight: 700; }
.legal-body a { font-weight: 600; }
.legal-body code {
  font-size: .88em;
  padding: .12em .4em;
  border-radius: 6px;
  background: var(--surface-2);
  color: var(--text);
}

/* Páginas legales no tienen nav; mantienen idioma y tema a la derecha */
body:has(main.legal) .header-tools { margin-left: auto; }

/* 8. Responsive ------------------------------------------------------------ */
@media (max-width: 1080px) {
  .nav-links { gap: 18px; }
  .nav { gap: 18px; }
}

@media (max-width: 960px) {
  .menu-toggle { display: inline-grid; }
  .header-tools { margin-left: auto; }

  .nav {
    position: absolute;
    top: var(--header-h);
    left: 0; right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
    margin: 0;
    padding: 20px 24px 28px;
    border-bottom: 1px solid var(--border);
    background: var(--bg);
    box-shadow: 0 24px 40px -24px rgba(0, 0, 0, .5);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity .2s, transform .2s var(--ease), visibility .2s;
  }
  .site-header.is-open .nav { opacity: 1; visibility: visible; transform: none; }
  .nav-links { flex-direction: column; gap: 4px; }
  .nav-links a { display: block; padding: 10px 0; font-size: 1.05rem; }
  .nav-cta { width: 100%; }

  .hero-grid { grid-template-columns: 1fr; text-align: center; }
  .hero-copy { display: flex; flex-direction: column; align-items: center; }
  .hero-actions { justify-content: center; }

  .trust-grid,
  .cards-grid { grid-template-columns: 1fr; }

  .feature { grid-template-columns: 1fr; }
  .feature--reverse .feature-copy { order: 0; }

  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 560px) {
  .container { padding-inline: 16px; }
  .brand .logo { height: 28px; }
  .header-inner { gap: 12px; }
  .header-tools { gap: 6px; }

  .hero-actions { flex-direction: column; width: 100%; }
  .hero-actions .btn { width: 100%; white-space: normal; }
  .demo-banner .btn { width: 100%; white-space: normal; }

  .phone .wa { height: 540px; }

  .sync { grid-template-columns: 1fr; justify-items: center; }
  .sync-chat { width: 100%; }
  .sync-arrow { transform: rotate(90deg); }
  .calendar { width: 100%; }

  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
}

/* 9. Movimiento ------------------------------------------------------------ */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .6s var(--ease), transform .6s var(--ease);
}
.js [data-reveal].is-visible { opacity: 1; transform: none; }

.msg-anim {
  animation: msg-in .5s var(--ease) both;
  animation-delay: calc(var(--d) * .6s + .3s);
}
@keyframes msg-in {
  from { opacity: 0; transform: translateY(10px) scale(.97); }
  to { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-delay: 0s !important;
    transition-duration: .01ms !important;
  }
  .js [data-reveal] { opacity: 1; transform: none; }
}
