/* =============================================================================
   Carolina Vivanco · Kinesióloga — styles.css
   Archetype: 04 Glassmorphism Modern, adaptado a salud/kinesiología.
   Paleta cálida verde-jade + coral sobre crema, pensada para buena
   legibilidad en público adulto mayor (tipografía y contrastes generosos).
   ============================================================================= */

/* =============================================================
   1. Tokens
   ============================================================= */
:root {
  --bg:        #f4f8fb;
  --bg-paper:  #ffffff;
  --glass:     rgba(255,255,255,0.66);
  --glass-2:   rgba(255,255,255,0.4);
  --glass-brd: rgba(255,255,255,0.6);
  --ink:       #1b2733;
  --ink-soft:  #3d4c59;
  --ink-mute:  #6b7a86;
  --accent:    #2f9bd6;   /* azul celeste — color principal, confianza y calma */
  --accent-2:  #ee8a63;   /* apricot cálido — toque humano, uso muy puntual */
  --accent-soft: #e4f2fa;
  --line:      rgba(27,39,51,0.11);
  --shadow:    0 30px 60px -30px rgba(15,35,50,0.28);
  --shadow-sm: 0 12px 30px -18px rgba(15,35,50,0.28);
  --radius:    22px;
  --radius-sm: 14px;
  --ease-out:  cubic-bezier(0.16, 1, 0.3, 1);
  --ease-soft: cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);
  --nav-h: 64px;
  --font-display: "Fraunces", "Iowan Old Style", Georgia, serif;
  --font-body:    "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono:    "Space Grotesk", "Inter", sans-serif;
}

@property --mesh-a { syntax: '<angle>'; inherits: false; initial-value: 0deg; }

/* =============================================================
   2. Reset & base
   ============================================================= */
*, *::before, *::after { box-sizing: border-box; margin: 0; }
html {
  -webkit-text-size-adjust: 100%;
  tab-size: 2;
  scroll-behavior: smooth;
  overflow-x: clip;
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.7;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
  overscroll-behavior-y: none;
}
img, svg, video { display: block; max-width: 100%; }
img { height: auto; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
a { color: inherit; text-decoration: none; }
p { text-wrap: pretty; }
ul { list-style: none; padding: 0; }
h1, h2, h3, h4 {
  text-wrap: balance; line-height: 1.05; letter-spacing: -0.01em;
  font-family: var(--font-display); font-weight: 560;
  font-variation-settings: "opsz" 40, "SOFT" 0;
}
h1 em, h2 em, h3 em, .hero-title em, .section-title em {
  font-style: italic; font-weight: 460;
  font-variation-settings: "opsz" 60, "SOFT" 30;
}
h3, h4 { font-variation-settings: "opsz" 18; font-weight: 620; }
@keyframes breatheWeight {
  0%, 100% { font-variation-settings: "opsz" 60, "SOFT" 20, "wght" 420; }
  50%      { font-variation-settings: "opsz" 60, "SOFT" 55, "wght" 480; }
}
.breathe { display: inline-block; animation: breatheWeight 7s ease-in-out infinite; }
.eyebrow, .pill, .hero-kicker { font-family: var(--font-mono); letter-spacing: .06em; }
::selection { background: var(--accent); color: #fff; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

.skip-link {
  position: fixed; top: -100px; left: 1rem;
  padding: .7rem 1.2rem; background: var(--ink); color: #fff;
  z-index: 9999; border-radius: 10px; font-weight: 600;
  transition: top .3s var(--ease-out);
}
.skip-link:focus { top: 1rem; }

/* =============================================================
   3. Utilities
   ============================================================= */
.container { width: min(1180px, 92%); margin-inline: auto; }
.container-narrow { width: min(760px, 92%); margin-inline: auto; }
.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 { position: relative; padding: clamp(4.5rem, 9vw, 8rem) 0; }
.section-head { max-width: 640px; margin-bottom: clamp(2.5rem, 5vw, 4rem); }
.section-head.center { margin-inline: auto; text-align: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: .5rem;
  font-size: .85rem; font-weight: 700; letter-spacing: .04em;
  color: var(--accent); text-transform: uppercase; margin-bottom: 1rem;
}
.eyebrow::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--accent-2); display: inline-block; }
.section-title { font-size: clamp(1.9rem, 3.6vw, 2.8rem); margin-bottom: .9rem; }
.section-sub { color: var(--ink-soft); font-size: 1.08rem; max-width: 56ch; }
.section-head.center .section-sub { margin-inline: auto; }

.pill { display: inline-flex; align-items: center; gap: .4rem; padding: .4rem .9rem; border-radius: 999px; background: var(--accent-soft); color: var(--accent); font-size: .82rem; font-weight: 700; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .55rem;
  padding: 1rem 1.7rem; border-radius: 999px; font-weight: 700; font-size: 1rem;
  transition: transform .35s var(--ease-out), box-shadow .35s var(--ease-out), background .3s var(--ease-out);
  white-space: nowrap;
}
.btn-primary { background: linear-gradient(120deg, var(--accent), #1c7fb0); color: #fff; box-shadow: 0 16px 32px -14px rgba(47,155,214,0.55); }
.btn-primary:hover { transform: translateY(-3px); box-shadow: 0 22px 40px -14px rgba(47,155,214,0.65); }
.btn-secondary { background: var(--glass); border: 1px solid var(--glass-brd); backdrop-filter: blur(16px); color: var(--ink); }
@supports not (backdrop-filter: blur(1px)) { .btn-secondary { background: rgba(255,255,255,0.85); } }
.btn-secondary:hover { transform: translateY(-3px); background: rgba(255,255,255,0.85); }
.btn-whats { background: #25D366; color: #fff; box-shadow: 0 16px 32px -16px rgba(37,211,102,.7); }
.btn-whats:hover { transform: translateY(-3px); }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .6; pointer-events: none; }

/* Glass card base */
.glass {
  background: rgba(255,255,255,0.72);
  border: 1px solid var(--glass-brd);
  border-radius: var(--radius);
}
@supports (backdrop-filter: blur(1px)) {
  .glass { background: var(--glass); backdrop-filter: blur(22px) saturate(160%); -webkit-backdrop-filter: blur(22px) saturate(160%); }
}

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .8s var(--ease-out), transform .8s var(--ease-out); }
.reveal.is-visible { opacity: 1; transform: none; }
.reveal-stagger > * { transition-delay: calc(var(--i, 0) * 90ms); }

/* =============================================================
   4. Nav
   ============================================================= */
.nav {
  position: fixed; top: 12px; left: 50%; transform: translateX(-50%); z-index: 500;
  width: min(1180px, 92%);
  display: flex; align-items: center; justify-content: space-between;
  padding: .45rem .6rem .45rem 1rem; border-radius: 999px;
  background: rgba(255,255,255,0.55); border: 1px solid var(--glass-brd);
  transition: background .3s var(--ease-out), box-shadow .3s var(--ease-out);
}
@supports (backdrop-filter: blur(1px)) { .nav { backdrop-filter: blur(18px) saturate(160%); } }
.nav.is-scrolled { background: rgba(255,255,255,0.86); box-shadow: var(--shadow-sm); }
.nav-brand { display: flex; align-items: center; gap: .55rem; font-size: 1.02rem; }
.nav-brand .logo-mark { width: 30px; height: 30px; flex-shrink: 0; }
.nav-brand span { font-family: var(--font-display); font-style: italic; font-weight: 560; letter-spacing: -.01em; }
.nav-brand small { display: block; font-family: var(--font-mono); font-style: normal; font-weight: 500; font-size: .6rem; letter-spacing: .07em; text-transform: uppercase; color: var(--ink-mute); }
.nav-links { display: none; align-items: center; gap: 1.7rem; }
.nav-links a { font-weight: 600; font-size: .88rem; position: relative; padding: .3rem 0; }
.nav-links a::after {
  content: ""; position: absolute; left: 0; right: 100%; bottom: -2px; height: 2px; background: var(--accent);
  transition: right .35s var(--ease-out);
}
.nav-links a:hover::after { right: 0; }
.nav-cta { display: none; }
.nav-cta.btn { padding: .6rem 1.25rem; font-size: .85rem; }
.nav-toggle {
  display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%;
  background: var(--accent-soft); color: var(--accent);
}
@media (min-width: 960px) {
  .nav-links, .nav-cta { display: inline-flex; }
  .nav-toggle { display: none; }
}

.mobile-menu {
  position: fixed; inset: 0; z-index: 600; background: rgba(243,246,243,0.98);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1.6rem;
  opacity: 0; pointer-events: none; transition: opacity .35s var(--ease-out);
}
.mobile-menu.is-open { opacity: 1; pointer-events: auto; }
.mobile-menu a { font-size: 1.5rem; font-weight: 800; }
.mobile-menu .btn { margin-top: 1rem; }
.mobile-close { position: absolute; top: 24px; right: 24px; width: 48px; height: 48px; border-radius: 50%; background: var(--glass); display: grid; place-items: center; }

/* =============================================================
   5. Hero
   ============================================================= */
.hero {
  position: relative; min-height: 100svh; display: flex; align-items: center;
  padding-top: calc(var(--nav-h) + 1rem);
  padding-bottom: clamp(1.4rem, 4vw, 3rem);
  overflow: clip;
}
.hero-mesh {
  position: absolute; inset: -10%; z-index: -2;
  background:
    radial-gradient(42% 46% at 18% 20%, rgba(47,155,214,0.26) 0%, transparent 62%),
    radial-gradient(46% 50% at 82% 85%, rgba(47,155,214,0.16) 0%, transparent 65%),
    radial-gradient(30% 30% at 88% 15%, rgba(238,138,99,0.12) 0%, transparent 65%),
    var(--bg);
  filter: blur(50px) saturate(120%);
  animation: meshDrift 26s ease-in-out infinite;
}
@keyframes meshDrift {
  0%, 100% { transform: scale(1) rotate(0deg); }
  50% { transform: scale(1.15) rotate(8deg); }
}
.hero-grid {
  display: grid; grid-template-columns: 1fr; gap: 2.2rem; align-items: center;
}
@media (min-width: 960px) { .hero-grid { grid-template-columns: 1fr 0.92fr; gap: 2.5rem; } }

.hero-kicker { display: inline-flex; align-items: center; gap: .5rem; padding: .5rem 1rem; border-radius: 999px; margin-bottom: 1.2rem; font-weight: 700; font-size: .85rem; color: var(--accent); }
.hero-title { font-size: clamp(2.1rem, 4vw, 3.15rem); max-width: 33ch; line-height: 1.12; }
.hero-title .accent { color: var(--accent); }
.hero-title .accent-2 { color: var(--accent-2); }
.hero-sub { margin-top: .9rem; font-size: 1.1rem; color: var(--ink-soft); max-width: 46ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .9rem; margin-top: 1.4rem; }
.hero-trust { display: flex; flex-wrap: wrap; gap: 1.4rem; margin-top: 1.5rem; }
.hero-trust-item { display: flex; align-items: center; gap: .7rem; }
.hero-trust-item .num { font-family: var(--font-mono); font-weight: 600; font-size: 1.6rem; color: var(--ink); }
.hero-trust-item small { display: block; color: var(--ink-mute); font-size: .82rem; max-width: 14ch; }

.hero-visual { position: relative; }
.hero-card {
  position: relative; padding: 1.3rem; box-shadow: var(--shadow);
  animation: floatY 7s ease-in-out infinite;
}
@keyframes floatY { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-14px); } }
.hero-illustration { display: block; width: 100%; height: auto; aspect-ratio: 1/1; max-height: 44svh; border-radius: 16px; overflow: hidden; object-fit: cover; background: linear-gradient(160deg, #e4f2fa, #f4f8fb); }
.hero-badge {
  position: absolute; padding: .9rem 1.1rem; border-radius: 16px; box-shadow: var(--shadow-sm);
  display: flex; align-items: center; gap: .7rem; animation: floatY 6s ease-in-out infinite;
}
.hero-badge.b1 { top: -6%; right: -8%; animation-delay: .3s; }
.hero-badge.b2 { bottom: -5%; left: -7%; animation-delay: 1.6s; animation-duration: 7.5s; }
.hero-badge .ico { width: 34px; height: 34px; border-radius: 10px; background: var(--accent-soft); display: grid; place-items: center; color: var(--accent); flex-shrink: 0; }
.hero-badge .ico.ico-2 { background: rgba(238,138,99,0.16); color: var(--accent-2); }
.hero-badge strong { display: block; font-size: .95rem; }
.hero-badge span { font-size: .78rem; color: var(--ink-mute); }

.hero-float-shape {
  position: absolute; width: 44px; height: 44px; border-radius: 50%;
  display: grid; place-items: center; color: var(--accent); box-shadow: var(--shadow-sm);
  animation: floatDrift 8s ease-in-out infinite;
}
.hero-float-shape.s1 { top: 8%; left: -5%; color: var(--accent-2); animation-delay: .8s; }
.hero-float-shape.s2 { bottom: 20%; right: -4%; animation-duration: 9.5s; animation-delay: 2.1s; }
@keyframes floatDrift {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  50% { transform: translate(6px, -16px) rotate(8deg); }
}
@media (max-width: 959px) {
  .hero-float-shape { display: none; }
  .hero-badge.b1 { right: -3%; }
  .hero-badge.b2 { left: -3%; }
}

@media (prefers-reduced-motion: reduce) {
  .hero-card, .hero-badge, .hero-float-shape { animation: none; }
}

/* =============================================================
   6. Diferenciador / sobre Carolina
   ============================================================= */
.about { position: relative; }
.about-grid { display: grid; grid-template-columns: 1fr; gap: 3rem; align-items: center; }
@media (min-width: 960px) { .about-grid { grid-template-columns: 1.08fr .92fr; gap: 4rem; } }
.about-visual { position: relative; }
.about-illustration { display: block; width: 100%; height: auto; border-radius: var(--radius); aspect-ratio: 1/1; object-fit: cover; background: linear-gradient(150deg, #e4f2fa, #fbeee4); box-shadow: var(--shadow); overflow: hidden; }
.about-pillars { display: grid; gap: 1.1rem; margin-top: 2rem; }
.about-pillar { display: flex; gap: 1rem; align-items: flex-start; }
.about-pillar .ico { width: 46px; height: 46px; border-radius: 12px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; flex-shrink: 0; }
.about-pillar h3 { font-size: 1.05rem; margin-bottom: .25rem; }
.about-pillar p { color: var(--ink-soft); font-size: .98rem; }

/* =============================================================
   7. Servicios
   ============================================================= */
.services-banner { max-width: 1000px; margin: 0 auto 3.4rem; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.services-banner img { display: block; width: 100%; height: auto; aspect-ratio: 1600/583; object-fit: cover; }
.services-grid { display: grid; grid-template-columns: 1fr; gap: 1.4rem; }
@media (min-width: 720px) { .services-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1280px) { .services-grid { grid-template-columns: repeat(4, 1fr); } }
.service-card {
  padding: 2rem 1.7rem; display: flex; flex-direction: column; gap: 1.1rem;
  transition: transform .45s var(--ease-out), box-shadow .45s var(--ease-out);
}
.service-card:hover { box-shadow: var(--shadow); }
.testi-card:hover, .process-card:hover { box-shadow: var(--shadow); }
.service-card, .testi-card, .process-card { transition: box-shadow .45s var(--ease-out), transform .15s var(--ease-out); }
.service-card .ico {
  width: 58px; height: 58px; border-radius: 16px; display: grid; place-items: center;
  background: linear-gradient(135deg, var(--accent-soft), #fff);
  color: var(--accent);
}
.service-card h3 { font-size: 1.2rem; display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; }
.service-card p { color: var(--ink-soft); font-size: .97rem; }
.service-tag { font-family: var(--font-mono); font-size: .68rem; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--accent-2); }

/* =============================================================
   9. Proceso
   ============================================================= */
.process-layout { display: grid; grid-template-columns: 1fr; gap: 2rem; align-items: stretch; }
@media (min-width: 960px) { .process-layout { grid-template-columns: .85fr 1.15fr; gap: 2.6rem; } }
.process-visual { position: relative; }
.process-illustration { display: block; width: 100%; height: 100%; min-height: 320px; object-fit: cover; border-radius: var(--radius); box-shadow: var(--shadow); }
.process-grid { display: grid; grid-template-columns: 1fr; gap: 1.4rem; counter-reset: step; }
@media (min-width: 600px) { .process-grid { grid-template-columns: repeat(2, 1fr); } }
.process-card { padding: 1.8rem; position: relative; }
.process-card .n { font-family: var(--font-mono); font-weight: 600; font-size: 2.2rem; color: var(--accent-soft); -webkit-text-stroke: 1.5px var(--accent); line-height: 1; margin-bottom: 1rem; }
.process-card h3 { font-size: 1.05rem; margin-bottom: .4rem; }
.process-card p { font-size: .92rem; color: var(--ink-soft); }

/* =============================================================
   10. Testimonios
   ============================================================= */
.testi-note { display: inline-flex; margin-bottom: 2rem; }
.testi-grid { display: grid; grid-template-columns: 1fr; gap: 1.4rem; }
@media (min-width: 860px) { .testi-grid { grid-template-columns: repeat(3, 1fr); } }
.testi-card { padding: 1.8rem; display: flex; flex-direction: column; gap: 1.1rem; }
.testi-quote { font-size: 1.06rem; color: var(--ink-soft); position: relative; font-family: var(--font-display); font-style: italic; font-weight: 420; }
.testi-quote::before { content: "\201C"; font-family: var(--font-display); font-style: normal; font-size: 2.8rem; color: var(--accent-2); line-height: 0; display: block; margin-bottom: .3rem; }
.testi-person { display: flex; align-items: center; gap: .8rem; margin-top: auto; }
.testi-avatar { width: 60px; height: 60px; border-radius: 50%; object-fit: cover; display: block; flex-shrink: 0; }
.testi-person strong { display: block; font-size: .94rem; }
.testi-person span { font-size: .8rem; color: var(--ink-mute); }
.testi-demo-tag { font-size: .74rem; font-style: italic; color: var(--ink-mute); display: inline-block; margin-top: .1rem; }

/* =============================================================
   11. FAQ
   ============================================================= */
.faq-list { display: grid; gap: 1rem; max-width: 780px; }
.faq-item { padding: 0; overflow: hidden; }
.faq-q {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 1.3rem 1.6rem; text-align: left; font-weight: 700; font-size: 1rem;
}
.faq-q .plus { width: 28px; height: 28px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; flex-shrink: 0; transition: transform .4s var(--ease-out); font-size: 1.1rem; }
.faq-item[data-open="true"] .plus { transform: rotate(135deg); }
.faq-a { max-height: 0; overflow: hidden; transition: max-height .45s var(--ease-out); }
.faq-a-inner { padding: 0 1.6rem 1.4rem; color: var(--ink-soft); font-size: .96rem; }

/* =============================================================
   12. Contacto
   ============================================================= */
.contact-grid { display: grid; grid-template-columns: 1fr; gap: 2.6rem; }
@media (min-width: 960px) { .contact-grid { grid-template-columns: 1fr 1fr; } }
.contact-card { padding: clamp(1.8rem, 4vw, 2.6rem); }
.contact-list { display: grid; gap: 1.1rem; margin-top: 1.6rem; }
.contact-row { display: flex; align-items: center; gap: 1rem; }
.contact-row .ico { width: 48px; height: 48px; border-radius: 12px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; flex-shrink: 0; }
.contact-row strong { display: block; font-size: 1.02rem; }
.contact-row span { font-size: .88rem; color: var(--ink-mute); }
.contact-form { display: grid; gap: 1rem; }
.contact-form .field { display: grid; gap: .4rem; }
.contact-form label { font-size: .9rem; font-weight: 700; }
.contact-form input, .contact-form textarea {
  padding: .9rem 1.1rem; border-radius: 12px; border: 1px solid var(--line); background: rgba(255,255,255,0.85); font: inherit;
}
.contact-form textarea { min-height: 110px; resize: vertical; }
.contact-form input:focus, .contact-form textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.form-msg { font-size: .88rem; margin-top: .4rem; display: none; }
.form-msg.is-visible { display: block; }
.form-msg.ok { color: var(--accent); }
.form-msg.err { color: #c0392b; }

/* =============================================================
   13. CTA final
   ============================================================= */
.cta-final { position: relative; overflow: clip; }
.cta-final-inner { padding: clamp(3rem, 7vw, 5rem); text-align: center; box-shadow: var(--shadow); position: relative; }
.cta-final .section-title { max-width: 20ch; margin-inline: auto; }
.cta-final-actions { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: center; margin-top: 2rem; }

/* =============================================================
   14. Footer
   ============================================================= */
.footer { padding: 3.5rem 0 2rem; border-top: 1px solid var(--line); }
.footer-grid { display: grid; grid-template-columns: 1fr; gap: 2.4rem; }
@media (min-width: 860px) { .footer-grid { grid-template-columns: 1.3fr .8fr .8fr; } }
.footer-brand { display: flex; align-items: center; gap: .7rem; font-weight: 800; margin-bottom: .8rem; }
.footer-brand .logo-mark { width: 34px; height: 34px; }
.footer p { color: var(--ink-mute); font-size: .92rem; max-width: 40ch; }
.footer h4 { font-size: .92rem; margin-bottom: 1rem; }
.footer-links { display: grid; gap: .6rem; }
.footer-links a { font-size: .92rem; color: var(--ink-soft); }
.footer-links a:hover { color: var(--accent); }
.footer-bottom { margin-top: 2.6rem; padding-top: 1.6rem; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between; font-size: .82rem; color: var(--ink-mute); }
.footer-disclaimer { max-width: 70ch; }

/* =============================================================
   15. Chat widget (asistente IA "Kiné")
   ============================================================= */
.chat-launcher {
  position: fixed; right: 20px; bottom: 20px; z-index: 700;
  width: 62px; height: 62px; border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), #1c7fb0);
  color: #fff; display: grid; place-items: center; box-shadow: 0 18px 36px -14px rgba(47,155,214,0.5);
  transition: transform .35s var(--ease-bounce);
}
.chat-launcher:hover { transform: scale(1.08); }
.chat-launcher .dot { position: absolute; top: 8px; right: 8px; width: 12px; height: 12px; border-radius: 50%; background: var(--accent-2); border: 2px solid #fff; }
.chat-panel {
  position: fixed; right: 20px; bottom: 96px; z-index: 700; width: min(360px, calc(100vw - 40px));
  height: min(520px, calc(100vh - 160px)); border-radius: 22px; overflow: hidden;
  display: flex; flex-direction: column; box-shadow: var(--shadow);
  transform: translateY(16px) scale(.97); opacity: 0; pointer-events: none;
  transition: transform .35s var(--ease-out), opacity .3s var(--ease-out);
  background: rgba(255,255,255,0.94); border: 1px solid var(--glass-brd);
}
@supports (backdrop-filter: blur(1px)) { .chat-panel { backdrop-filter: blur(20px); } }
.chat-panel.is-open { transform: none; opacity: 1; pointer-events: auto; }
.chat-head { padding: 1rem 1.2rem; background: linear-gradient(120deg, var(--accent), #1c7fb0); color: #fff; display: flex; align-items: center; gap: .7rem; }
.chat-head .av { width: 34px; height: 34px; border-radius: 50%; background: rgba(255,255,255,0.25); display: grid; place-items: center; flex-shrink: 0; }
.chat-head strong { display: block; font-size: .95rem; }
.chat-head span { font-size: .74rem; opacity: .85; }
.chat-close { margin-left: auto; width: 30px; height: 30px; border-radius: 50%; background: rgba(255,255,255,0.2); color: #fff; display: grid; place-items: center; }
.chat-body { flex: 1; overflow-y: auto; padding: 1rem 1.1rem; display: flex; flex-direction: column; gap: .7rem; }
.chat-msg { max-width: 85%; padding: .7rem .95rem; border-radius: 14px; font-size: .92rem; line-height: 1.5; }
.chat-msg.bot { background: var(--accent-soft); color: var(--ink); align-self: flex-start; border-bottom-left-radius: 4px; }
.chat-msg.user { background: var(--accent); color: #fff; align-self: flex-end; border-bottom-right-radius: 4px; }
.chat-suggestions { display: flex; flex-wrap: wrap; gap: .5rem; padding: 0 1.1rem .8rem; }
.chat-chip { font-size: .78rem; padding: .4rem .8rem; border-radius: 999px; background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.chat-typing { display: flex; gap: 4px; padding: .5rem .2rem; }
.chat-typing span { width: 6px; height: 6px; border-radius: 50%; background: var(--ink-mute); animation: typingBounce 1.1s infinite ease-in-out; }
.chat-typing span:nth-child(2) { animation-delay: .15s; } .chat-typing span:nth-child(3) { animation-delay: .3s; }
@keyframes typingBounce { 0%, 60%, 100% { transform: translateY(0); opacity: .5; } 30% { transform: translateY(-5px); opacity: 1; } }
.chat-foot { padding: .8rem; border-top: 1px solid var(--line); display: flex; gap: .6rem; }
.chat-foot input { flex: 1; padding: .8rem 1rem; border-radius: 999px; border: 1px solid var(--line); font: inherit; background: #fff; }
.chat-foot input:focus { outline: none; border-color: var(--accent); }
.chat-send { width: 42px; height: 42px; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; flex-shrink: 0; }

/* =============================================================
   16. Decorative SVG illustration helpers
   ============================================================= */
.blob-decor { position: absolute; z-index: -1; filter: blur(2px); opacity: .8; pointer-events: none; }
.icon-24 { width: 24px; height: 24px; }
.icon-28 { width: 28px; height: 28px; }

/* =============================================================
   16.5 Marquee ticker (editorial, movimiento continuo)
   ============================================================= */
.marquee {
  position: relative; overflow: hidden; padding: .8rem 0;
  border-block: 1px solid var(--line);
}
.marquee-track {
  display: flex; align-items: center; gap: 1.4rem; width: max-content;
  animation: marqueeScroll 136s linear infinite;
  font-family: var(--font-mono); font-weight: 500; font-size: .82rem;
  letter-spacing: .08em; text-transform: uppercase; color: var(--ink-mute);
  white-space: nowrap;
}
.marquee-track .dot { color: var(--accent); font-size: .5rem; opacity: .6; }
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes marqueeScroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* =============================================================
   16.6 Tilt 3D + halo con el cursor (tarjetas), solo puntero fino
   ============================================================= */
.service-card, .testi-card, .process-card, .hero-card {
  --mx: 50%; --my: 50%;
  position: relative; transform-style: preserve-3d; will-change: transform;
}
.service-card::before, .testi-card::before, .process-card::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; z-index: -1;
  background: radial-gradient(220px circle at var(--mx) var(--my), rgba(47,155,214,0.16), transparent 70%);
  opacity: 0; transition: opacity .4s var(--ease-out); pointer-events: none;
}
.service-card:hover::before, .testi-card:hover::before, .process-card:hover::before { opacity: 1; }

/* =============================================================
   16.7 Botón primario con brillo al pasar el cursor (más discreto)
   ============================================================= */
.btn-primary { position: relative; overflow: hidden; }
.btn-primary::after {
  content: ""; position: absolute; top: 0; left: -60%; width: 40%; height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,.5), transparent);
  transform: skewX(-20deg); transition: left .7s var(--ease-out);
}
.btn-primary:hover::after { left: 130%; }

/* =============================================================
   17. Responsive tuning
   ============================================================= */
@media (max-width: 539px) {
  .hero-badge { display: none; }
  .nav { top: 10px; width: 94%; padding: .4rem .4rem .4rem .85rem; }
}

/* =============================================================
   18. Reduced motion — only truly intrusive effects
   ============================================================= */
@media (prefers-reduced-motion: reduce) {
  .hero-mesh { animation: none; }
  .chat-typing span { animation: none; opacity: .7; }
}
