/* ═══════════════════════════════════════════════════════════════
   TALK SALUD — Base / Design System
   Navy + Green · Playfair Display + DM Sans
   Custom layer on top of Tailwind (tokens duplicated in tailwind.config)
   ═══════════════════════════════════════════════════════════════ */
:root {
  --navy:       #0A2E52;
  --navy-dark:  #07203A;
  --navy-deep:  #051628;
  --green:      #2ECC9A;
  --green-dark: #25B585;
  --light:      #F4F7FB;
  --text:       #1A1A2E;
  --subtext:    #5A6478;
  --border:     #E2EAF4;
  --max-w: 1200px;
  --font-display: 'Playfair Display', 'Times New Roman', serif;
  --font-body:    'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--text);
  background: #ffffff;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-size: 16px; line-height: 1.55; font-weight: 400;
}
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

.container { width: 100%; max-width: var(--max-w); margin: 0 auto; padding: 0 40px; }
@media (max-width: 768px) { .container { padding: 0 20px; } }

/* ── Section tokens ───────────────────────────────────────────── */
.section { padding: 96px 0; position: relative; }
.section.tight { padding: 64px 0; }
@media (max-width: 768px) {
  .section { padding: 64px 0; }
  .section.tight { padding: 44px 0; }
}
.section.navy { background: var(--navy-dark); color: var(--light); }
.section.navy-gradient {
  background: linear-gradient(135deg, var(--navy-deep) 0%, var(--navy-dark) 60%, var(--navy) 100%);
  color: var(--light);
}
.section.light { background: var(--light); }
.section.white { background: #ffffff; }

/* grid texture */
.grid-tex {
  position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.04) 1px, transparent 1px);
  background-size: 64px 64px;
}

/* glow blobs */
.glow {
  position: absolute; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, rgba(46,204,154,0.18), transparent 65%);
}
.glow.pulse { animation: pulse-slow 6s ease-in-out infinite; }
@keyframes pulse-slow {
  0%, 100% { opacity: 0.7; transform: scale(1); }
  50%      { opacity: 1;   transform: scale(1.08); }
}

/* ── Labels ──────────────────────────────────────────────────── */
.label {
  display: inline-flex; align-items: center; gap: 12px;
  font-family: var(--font-body);
  font-size: 12px; font-weight: 700;
  letter-spacing: 2.5px; text-transform: uppercase;
  color: var(--green-dark);
}
.label::before { content: ""; width: 28px; height: 2px; background: var(--green); border-radius: 2px; }
.section.navy .label, .section.navy-gradient .label { color: var(--green); }
.label.center { justify-content: center; }

/* ── Headings ────────────────────────────────────────────────── */
.h1, .h2, .h3 { font-family: var(--font-display); font-weight: 700; margin: 0; letter-spacing: -0.02em; }
.h1 { font-size: clamp(36px, 5.8vw, 70px); line-height: 1.09; }
.h2 { font-size: clamp(30px, 4.4vw, 52px); line-height: 1.10; }
.h3 { font-size: clamp(22px, 2.6vw, 30px); line-height: 1.20; }
em { font-style: italic; }
.lead { font-size: clamp(15px, 1.4vw, 18px); line-height: 1.7; color: var(--subtext); font-weight: 400; }
.section.navy .lead, .section.navy-gradient .lead { color: rgba(244,247,251,0.65); }
.bar { width: 44px; height: 3px; background: var(--green); border-radius: 2px; margin: 18px 0 22px; }

/* wavy green accent underline */
.u-accent {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 6'><path d='M2 4 Q 30 1 60 3 T 118 3' fill='none' stroke='%232ECC9A' stroke-width='2.5' stroke-linecap='round'/></svg>");
  background-repeat: no-repeat; background-size: 100% 6px; background-position: 0 100%;
  padding-bottom: 6px; color: var(--green);
}
.text-grad {
  background: linear-gradient(135deg, var(--navy) 0%, var(--green) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ── Buttons ─────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 14px 22px; border-radius: 10px;
  font-family: var(--font-body); font-weight: 600; font-size: 15px;
  border: 1.5px solid transparent;
  transition: transform .25s, box-shadow .25s, background .2s, color .2s, border-color .2s;
  cursor: pointer; white-space: nowrap;
}
.btn:hover { transform: translateY(-2px) scale(1.02); }
.btn:active { transform: scale(0.97); }
.btn-green { background: var(--green); color: var(--navy-deep); border-color: var(--green); box-shadow: 0 6px 20px rgba(46,204,154,0.25); }
.btn-green:hover { background: var(--green-dark); border-color: var(--green-dark); box-shadow: 0 12px 28px rgba(46,204,154,0.35); }
.btn-ghost { background: transparent; color: var(--navy); border-color: var(--navy); }
.btn-ghost:hover { background: var(--navy); color: var(--light); }
.btn-ghost-light { background: transparent; color: var(--light); border-color: rgba(244,247,251,0.45); }
.btn-ghost-light:hover { background: var(--light); color: var(--navy); border-color: var(--light); }

/* ── Logo ────────────────────────────────────────────────────── */
.logo { display: inline-flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 700; font-size: 20px; letter-spacing: -0.01em; }
.logo .mark { width: 24px; height: 24px; border-radius: 6px; background: var(--green); display: inline-block; position: relative; overflow: hidden; }
.logo .mark::after { content:""; position:absolute; inset: 6px; border-radius: 3px; border: 2px solid var(--navy-deep); }
.logo .salud { color: var(--green); }

/* ── Header ──────────────────────────────────────────────────── */
header.site {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100; height: 74px;
  display: flex; align-items: center; background: transparent;
  transition: background .3s, backdrop-filter .3s, border-color .3s;
  border-bottom: 1px solid transparent;
}
header.site.scrolled {
  background: rgba(7,32,58,0.96);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border-bottom-color: rgba(255,255,255,0.08);
}
header.site .container { display: flex; align-items: center; justify-content: space-between; width: 100%; }
header.site .logo { color: var(--light); }
header.site nav { display: flex; gap: 28px; }
header.site nav a { color: rgba(255,255,255,0.65); font-size: 14px; font-weight: 500; padding: 6px 0; position: relative; transition: color .2s; }
header.site nav a:hover { color: var(--green); }
header.site nav a.active { color: var(--green); }
header.site nav a.active::after { content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 2px; background: var(--green); border-radius: 2px; }
header.site .btn-green { padding: 9px 16px; font-size: 13px; }

.mobile-burger { display: none; width: 38px; height: 38px; background: transparent; border: none; padding: 0; flex-direction: column; gap: 5px; align-items: center; justify-content: center; }
.mobile-burger span { width: 22px; height: 2px; background: var(--light); border-radius: 1px; transition: transform .25s, opacity .25s; }
.mobile-burger span:nth-child(3) { background: var(--green); }
@media (max-width: 900px) {
  header.site { height: 64px; }
  header.site nav, header.site .header-cta { display: none; }
  .mobile-burger { display: inline-flex; }
}
#mobile-menu {
  display: none; position: fixed; top: 64px; left: 0; right: 0; bottom: 0;
  background: rgba(5,22,40,0.98); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  padding: 28px 20px; z-index: 99; flex-direction: column; gap: 4px; color: var(--light);
}
#mobile-menu.open { display: flex; }
#mobile-menu a { display: flex; align-items: center; justify-content: space-between; padding: 16px 0; border-bottom: 1px solid rgba(255,255,255,0.10); font-size: 18px; font-weight: 600; color: var(--light); }
#mobile-menu a.active { color: var(--green); }
#mobile-menu .btn-green { margin-top: 20px; padding: 14px 18px; }

/* ── Footer ──────────────────────────────────────────────────── */
footer.site { background: var(--navy-deep); color: var(--light); padding: 72px 0 28px; position: relative; }
footer.site .grid-tex { background-image: linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px); background-size: 56px 56px; }
footer.site .row { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 56px; position: relative; }
@media (max-width: 900px) { footer.site .row { grid-template-columns: 1fr; gap: 36px; } footer.site { padding: 56px 0 24px; } }
footer.site .brand .tag { margin: 16px 0 22px; color: rgba(244,247,251,0.6); font-size: 14px; line-height: 1.65; max-width: 380px; }
footer.site .socials { display: flex; gap: 10px; }
footer.site .socials a { width: 40px; height: 40px; border-radius: 10px; background: rgba(255,255,255,0.04); border: 1.5px solid rgba(255,255,255,0.18); display: grid; place-items: center; font-size: 14px; font-weight: 700; letter-spacing: 0.5px; color: var(--light); transition: background .2s, border-color .2s, transform .2s; }
footer.site .socials a:hover { background: rgba(46,204,154,0.18); border-color: var(--green); transform: translateY(-3px); }
footer.site h4 { font-family: var(--font-body); font-size: 11px; font-weight: 700; letter-spacing: 2px; text-transform: uppercase; color: var(--green); margin: 0 0 14px; }
footer.site .col a, footer.site .col span { display: block; padding: 4px 0; color: rgba(244,247,251,0.75); font-size: 14px; transition: color .2s; }
footer.site .col a:hover { color: var(--green); }
footer.site .bottom { margin-top: 56px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,0.10); display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; position: relative; }
footer.site .bottom .copy, footer.site .bottom .legal, footer.site .bottom .dev { font-size: 12px; color: rgba(244,247,251,0.5); }
footer.site .bottom .legal { display: flex; gap: 18px; }
footer.site .bottom .legal a, footer.site .bottom .dev a { color: rgba(244,247,251,0.6); }
footer.site .bottom .legal a:hover, footer.site .bottom .dev a:hover { color: var(--green); }

/* ── Reveal on scroll ────────────────────────────────────────── */
.reveal { opacity: 0; transform: translateY(32px); transition: opacity .7s cubic-bezier(.16,1,.3,1), transform .7s cubic-bezier(.16,1,.3,1); }
.reveal.in { opacity: 1; transform: none; }
.reveal[data-delay="1"] { transition-delay: .08s; }
.reveal[data-delay="2"] { transition-delay: .16s; }
.reveal[data-delay="3"] { transition-delay: .24s; }
.reveal[data-delay="4"] { transition-delay: .32s; }
.reveal[data-delay="5"] { transition-delay: .40s; }

/* ── HERO (shared across pages) ──────────────────────────────── */
.hero {
  position: relative; min-height: 100vh; min-height: 100svh;
  display: flex; align-items: center; color: var(--light);
  overflow: hidden; padding: 120px 0 80px;
}
.hero-bg { position: absolute; inset: 0; overflow: hidden; }
.hero-image {
  position: absolute; inset: 0;
  background:
    radial-gradient(60% 80% at 70% 30%, rgba(46,204,154,0.10), transparent 60%),
    linear-gradient(135deg, var(--navy-deep) 0%, var(--navy-dark) 50%, var(--navy) 100%);
}
.hero-image::before {
  content: ""; position: absolute; inset: 0;
  background-image:
    repeating-linear-gradient(135deg, rgba(255,255,255,0.025) 0 1px, transparent 1px 14px),
    repeating-linear-gradient(45deg, rgba(255,255,255,0.018) 0 1px, transparent 1px 14px);
}
.hero-overlay {
  position: absolute; inset: 0;
  background:
    linear-gradient(135deg, rgba(7,32,58,0.72) 0%, rgba(10,46,82,0.61) 50%, rgba(13,59,110,0.50) 100%),
    radial-gradient(ellipse at center, transparent 30%, rgba(5,22,40,0.6) 100%);
}
.hero-grid {
  position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(rgba(255,255,255,0.018) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.018) 1px, transparent 1px);
  background-size: 64px 64px;
}
.hero-glow { position: absolute; top: 8%; right: 4%; width: 520px; height: 520px; border-radius: 50%; background: radial-gradient(circle, rgba(46,204,154,0.18), transparent 68%); animation: pulse-slow 6s ease-in-out infinite; }
.hero-content { position: relative; z-index: 10; width: 100%; }
.hero-label { display: inline-block; color: var(--green); font-size: 12px; font-weight: 700; letter-spacing: 2.5px; text-transform: uppercase; margin-bottom: 18px; }
.hero-headline { color: var(--light); margin: 0 0 22px; letter-spacing: -0.02em; }
.hero-headline em { color: var(--green); font-style: italic; }
.hero-sub { font-size: clamp(16px, 1.5vw, 19px); font-weight: 300; line-height: 1.75; color: rgba(255,255,255,0.62); max-width: 620px; margin: 0 0 36px; }
.hero-ctas { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 28px; }
.hero-trust { display: flex; gap: 24px; flex-wrap: wrap; font-size: 13px; color: rgba(255,255,255,0.55); font-weight: 400; }
.hero-trust li { display: inline-flex; align-items: center; gap: 8px; }
.hero-trust .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green); }
@media (max-width: 768px) {
  .hero { padding: 100px 0 56px; }
  .hero-sub { font-size: 15px; line-height: 1.65; }
  .hero-glow { width: 320px; height: 320px; top: 4%; right: -10%; }
}

/* ── Meteors ────────────────────────────────────────────── */
.meteor-container {
  position: absolute;
  inset: 0;
  overflow: hidden;
  z-index: 1; /* Below overlay and content */
  pointer-events: none;
}

.meteor {
  position: absolute;
  width: 2px;
  height: 2px;
  background-color: rgba(255, 255, 255, 0.8);
  border-radius: 9999px;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.1);
  transform: rotate(215deg);
  animation: meteor-effect linear infinite;
  opacity: 0;
}

.meteor::before {
  content: "";
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 50px;
  height: 1px;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.8), transparent);
}

@keyframes meteor-effect {
  0% {
    transform: rotate(215deg) translateX(0);
    opacity: 1;
  }
  70% {
    opacity: 1;
  }
  100% {
    transform: rotate(215deg) translateX(-1500px);
    opacity: 0;
  }
}

/* pill (hero badge) */
.pill {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-body); font-size: 12px; font-weight: 700;
  letter-spacing: 1.5px; text-transform: uppercase;
  padding: 7px 14px; border-radius: 999px;
  background: rgba(46,204,154,0.12); color: var(--green); border: 1.5px solid rgba(46,204,154,0.5);
}

/* image placeholder */
.img-ph {
  position: relative; overflow: hidden;
  background:
    repeating-linear-gradient(135deg, rgba(10,46,82,0.08) 0 1px, transparent 1px 12px),
    repeating-linear-gradient(45deg, rgba(10,46,82,0.06) 0 1px, transparent 1px 12px),
    linear-gradient(135deg, #dde5ef, #f4f7fb);
  border: 1.5px solid var(--border);
  display: flex; align-items: center; justify-content: center;
}
.img-ph .ph-tag {
  background: #fff; padding: 5px 14px; border-radius: 999px; border: 1.5px solid var(--border);
  color: var(--navy); font-family: 'DM Mono', ui-monospace, monospace; font-size: 12px; letter-spacing: 0.5px;
}

/* ── Floating WhatsApp Button ────────────────────────────────── */
.whatsapp-float {
  position: fixed;
  bottom: 28px;
  right: 28px;
  z-index: 999;
  display: flex;
  align-items: center;
  gap: 0;
  cursor: pointer;
  text-decoration: none;
}
.whatsapp-float .wa-btn {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: #25D366;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow:
    0 4px 14px rgba(37, 211, 102, 0.4),
    0 2px 6px rgba(0, 0, 0, 0.15);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1),
              box-shadow 0.3s ease;
  position: relative;
  flex-shrink: 0;
}
.whatsapp-float .wa-btn svg {
  width: 32px;
  height: 32px;
  fill: #fff;
}
/* Pulse ring animation */
.whatsapp-float .wa-btn::before {
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 2px solid rgba(37, 211, 102, 0.5);
  animation: wa-pulse 2.5s ease-in-out infinite;
}
@keyframes wa-pulse {
  0%, 100% { transform: scale(1); opacity: 0.6; }
  50%      { transform: scale(1.18); opacity: 0; }
}

/* Tooltip label */
.whatsapp-float .wa-tooltip {
  position: absolute;
  right: 72px;
  white-space: nowrap;
  background: #fff;
  color: var(--navy-deep, #051628);
  font-family: var(--font-body, 'DM Sans', sans-serif);
  font-size: 13px;
  font-weight: 600;
  padding: 8px 16px;
  border-radius: 10px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
  opacity: 0;
  transform: translateX(8px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  pointer-events: none;
}
.whatsapp-float .wa-tooltip::after {
  content: "";
  position: absolute;
  right: -6px;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-top: 6px solid transparent;
  border-bottom: 6px solid transparent;
  border-left: 6px solid #fff;
}

/* Hover effects */
.whatsapp-float:hover .wa-btn {
  transform: scale(1.1);
  box-shadow:
    0 6px 22px rgba(37, 211, 102, 0.5),
    0 3px 10px rgba(0, 0, 0, 0.18);
}
.whatsapp-float:hover .wa-btn::before {
  animation: none;
  opacity: 0;
}
.whatsapp-float:hover .wa-tooltip {
  opacity: 1;
  transform: translateX(0);
}
.whatsapp-float:active .wa-btn {
  transform: scale(0.95);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .whatsapp-float {
    bottom: 20px;
    right: 20px;
  }
  .whatsapp-float .wa-btn {
    width: 54px;
    height: 54px;
  }
  .whatsapp-float .wa-btn svg {
    width: 28px;
    height: 28px;
  }
  .whatsapp-float .wa-tooltip {
    display: none;
  }
}
