/* ═══════════════════════════════════════════
   VARIABLES
═══════════════════════════════════════════ */
:root {
  --primary:       #1f6a7f;
  --primary-dark:  #155262;
  --primary-light: #2a8ba5;
  --primary-bg:    #edf7fa;
  --primary-bg2:   #d6edf3;
  --accent:        #e8833a;
  --accent-dark:   #c96c28;
  --white:         #ffffff;
  --gray-50:       #f8fafc;
  --gray-100:      #f1f5f9;
  --gray-200:      #e2e8f0;
  --gray-400:      #94a3b8;
  --gray-600:      #475569;
  --gray-800:      #1e293b;
  --gray-900:      #0f172a;
  --text:          #1a2e35;
  --text-muted:    #4a6572;
  --border:        #cde5ed;
  --radius:        14px;
  --radius-sm:     8px;
  --radius-xs:     6px;
  --shadow-sm:     0 1px 3px rgba(0,0,0,.07), 0 1px 2px rgba(0,0,0,.05);
  --shadow:        0 4px 6px -1px rgba(0,0,0,.07), 0 2px 4px -1px rgba(0,0,0,.04);
  --shadow-md:     0 10px 15px -3px rgba(0,0,0,.08), 0 4px 6px -2px rgba(0,0,0,.04);
  --shadow-lg:     0 20px 25px -5px rgba(0,0,0,.10), 0 10px 10px -5px rgba(0,0,0,.04);
  --font:          'Inter', system-ui, sans-serif;
  --ease:          0.22s ease;
}

/* ═══════════════════════════════════════════
   RESET & BASE
═══════════════════════════════════════════ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 150px; }
body {
  font-family: var(--font);
  color: var(--text);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  background: var(--white);
}
img  { max-width: 100%; display: block; }
a    { text-decoration: none; color: inherit; }
ul   { list-style: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
input, select, textarea { font-family: inherit; font-size: inherit; }
textarea { resize: vertical; }

/* ═══════════════════════════════════════════
   LAYOUT
═══════════════════════════════════════════ */
.container  { max-width: 1200px; margin: 0 auto; padding: 0 28px; }
.section    { padding: 88px 0; }
.section-light   { background: var(--primary-bg); }
.section-primary { background: var(--primary); }

.section-header {
  text-align: center;
  margin-bottom: 60px;
}
.section-header h2 {
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  font-weight: 800;
  letter-spacing: -.02em;
  margin-bottom: 12px;
}
.section-header p {
  font-size: 1.05rem;
  color: var(--text-muted);
  max-width: 540px;
  margin: 0 auto;
}
.section-header-white h2 { color: var(--white); }
.section-header-white p  { color: rgba(255,255,255,.75); }

/* ═══════════════════════════════════════════
   BUTTONS
═══════════════════════════════════════════ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: .95rem;
  line-height: 1;
  transition: all var(--ease);
  white-space: nowrap;
}
.btn-primary {
  background: var(--primary);
  color: var(--white);
}
.btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}
.btn-accent {
  background: var(--accent);
  color: var(--white);
}
.btn-accent:hover {
  background: var(--accent-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}
.btn-ghost {
  background: rgba(255,255,255,.12);
  color: var(--white);
  border: 1.5px solid rgba(255,255,255,.35);
}
.btn-ghost:hover {
  background: rgba(255,255,255,.22);
  border-color: rgba(255,255,255,.6);
}
.btn-lg   { padding: 15px 32px; font-size: 1rem; border-radius: var(--radius); }
.btn-full { width: 100%; }

/* ═══════════════════════════════════════════
   HEADER — Two-tier (logo bar + nav bar)
═══════════════════════════════════════════ */
#site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 200;
  transition: box-shadow var(--ease);
}
#site-header.scrolled { box-shadow: var(--shadow-lg); }

/* ── Barra superior (logo + CTA) ── */
.header-top {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 10px 0;
}
.header-top-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Logo */
.logo { display: flex; align-items: center; }
.logo-img {
  height: 64px;
  width: auto;
  mix-blend-mode: multiply;
}

/* Logo footer */
.logo-footer {
  display: flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
  margin-bottom: 18px;
}
.logo-footer-mark {
  width: 38px; height: 38px;
  border-radius: 9px;
  background: rgba(255,255,255,.12);
  border: 1.5px solid rgba(255,255,255,.2);
  color: var(--white);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem; font-weight: 800;
  flex-shrink: 0;
}
.logo-footer-name {
  display: block;
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--white);
  line-height: 1.15;
}
.logo-footer-img {
  display: inline-block;
  margin-bottom: 18px;
}
.logo-footer-image {
  height: 48px;
  width: auto;
  opacity: .8;
  transition: opacity .2s;
}
.logo-footer-image:hover { opacity: 1; }

.logo-footer-sub {
  display: block;
  font-size: .7rem;
  color: rgba(255,255,255,.45);
  letter-spacing: .04em;
  text-transform: uppercase;
}

/* ── Barra de navegación (teal) ── */
.header-nav-bar { background: var(--primary); }
.header-nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Nav links */
#main-nav ul { display: flex; align-items: center; }
#main-nav > ul > li { position: relative; }

#main-nav a {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 14px 18px;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .07em;
  color: rgba(255,255,255,.9);
  transition: background var(--ease), color var(--ease);
  white-space: nowrap;
}
#main-nav a:hover,
#main-nav .has-dropdown:hover > a {
  background: rgba(0,0,0,.18);
  color: var(--white);
}

/* Chevron */
.chevron { transition: transform var(--ease); flex-shrink: 0; }
.has-dropdown:hover .chevron { transform: rotate(180deg); }

/* ── Dropdown ── */
.dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  background: var(--white);
  border-top: 3px solid var(--accent);
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
  box-shadow: var(--shadow-lg);
  padding: 6px;
  z-index: 400;
}
.has-dropdown:hover .dropdown,
.has-dropdown:focus-within .dropdown {
  display: block;
}
#main-nav .dropdown a {
  display: flex;
  align-items: center;
  padding: 10px 14px;
  border-radius: var(--radius-xs);
  font-size: .875rem;
  font-weight: 500;
  letter-spacing: 0;
  color: var(--text);
  background: none;
  transition: all var(--ease);
}
#main-nav .dropdown a:hover {
  background: var(--primary-bg);
  color: var(--primary);
  padding-left: 18px;
}

/* ── Hamburger ── */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 10px;
}
.hamburger span {
  display: block;
  width: 22px; height: 2px;
  background: var(--white);
  border-radius: 2px;
  transition: all var(--ease);
}
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ═══════════════════════════════════════════
   HERO
═══════════════════════════════════════════ */
.hero {
  position: relative;
  min-height: 100vh;
  background: linear-gradient(140deg, var(--primary-dark) 0%, var(--primary) 55%, var(--primary-light) 100%);
  display: flex;
  align-items: center;
  padding: 170px 0 90px;
  overflow: hidden;
}
.hero-shapes { position: absolute; inset: 0; pointer-events: none; }
.shape {
  position: absolute;
  border-radius: 50%;
  background: rgba(255,255,255,.05);
}
.shape-1 {
  width: 60vw; height: 60vw;
  max-width: 700px; max-height: 700px;
  top: -20%; right: -8%;
}
.shape-2 {
  width: 30vw; height: 30vw;
  max-width: 350px; max-height: 350px;
  bottom: -10%; left: -5%;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: 72px;
  align-items: center;
}

/* Badge */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255,255,255,.14);
  color: rgba(255,255,255,.9);
  border: 1px solid rgba(255,255,255,.25);
  padding: 6px 14px;
  border-radius: 100px;
  font-size: .78rem;
  font-weight: 500;
  margin-bottom: 24px;
}

.hero h1 {
  font-size: clamp(2.1rem, 4.5vw, 3.1rem);
  font-weight: 800;
  color: var(--white);
  line-height: 1.12;
  letter-spacing: -.03em;
  margin-bottom: 20px;
}
.hero-lead {
  font-size: 1.1rem;
  color: rgba(255,255,255,.82);
  max-width: 520px;
  margin-bottom: 38px;
  line-height: 1.7;
}
.hero-btns {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 52px;
}
.hero-stats {
  display: flex;
  align-items: center;
  gap: 28px;
}
.stat strong {
  display: block;
  font-size: 1.9rem;
  font-weight: 800;
  color: var(--white);
  line-height: 1;
  letter-spacing: -.02em;
}
.stat span {
  font-size: .78rem;
  color: rgba(255,255,255,.65);
  margin-top: 2px;
}
.stat-sep {
  width: 1px; height: 40px;
  background: rgba(255,255,255,.2);
}

/* Hero form card */
.hero-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 34px;
  box-shadow: var(--shadow-lg);
}
.hero-card-head {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 6px;
}
.hero-card-sub {
  font-size: .85rem;
  color: var(--text-muted);
  margin-bottom: 22px;
  line-height: 1.5;
}

/* Quick form */
.quick-form {
  display: flex;
  flex-direction: column;
  gap: 11px;
}
.quick-form input,
.quick-form select {
  width: 100%;
  padding: 12px 15px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: .9rem;
  color: var(--text);
  background: var(--white);
  transition: border-color var(--ease), box-shadow var(--ease);
}
.quick-form input::placeholder { color: var(--gray-400); }
.quick-form input:focus,
.quick-form select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(31,106,127,.12);
}
.form-legal {
  font-size: .73rem;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.5;
}
.form-legal a { color: var(--primary); text-decoration: underline; }

/* Success state */
.form-success {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 14px;
  padding: 28px 16px;
}
.form-success p {
  font-weight: 600;
  color: var(--primary);
  font-size: .95rem;
  line-height: 1.5;
}
.hidden { display: none !important; }

/* ═══════════════════════════════════════════
   SERVICES TABS
═══════════════════════════════════════════ */
.tabs-wrap { }
.tab-nav {
  display: flex;
  gap: 6px;
  margin-bottom: 44px;
  background: var(--white);
  border-radius: var(--radius);
  padding: 6px;
  width: fit-content;
  box-shadow: var(--shadow);
}
.tab-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 22px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: .9rem;
  color: var(--text-muted);
  transition: all var(--ease);
}
.tab-btn:hover { color: var(--primary); background: var(--primary-bg); }
.tab-btn.active { background: var(--primary); color: var(--white); }

.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* Service cards grid */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
  gap: 22px;
}
.service-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 28px;
  border: 1.5px solid var(--border);
  transition: all var(--ease);
  display: flex;
  flex-direction: column;
}
.service-card:hover {
  border-color: var(--primary);
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}
.service-icon {
  width: 50px; height: 50px;
  border-radius: var(--radius-sm);
  background: var(--primary-bg);
  display: flex; align-items: center; justify-content: center;
  color: var(--primary);
  margin-bottom: 18px;
}
.service-icon svg { width: 24px; height: 24px; }
.service-card h3 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 8px;
  letter-spacing: -.01em;
}
.service-card p {
  font-size: .875rem;
  color: var(--text-muted);
  line-height: 1.65;
  flex: 1;
  margin-bottom: 18px;
}
.card-cta {
  font-size: .85rem;
  font-weight: 600;
  color: var(--primary);
  transition: color var(--ease);
  margin-top: auto;
}
.card-cta:hover { color: var(--primary-dark); }

/* ═══════════════════════════════════════════
   STEPS (CÓMO TRABAJAMOS)
═══════════════════════════════════════════ */
.steps {
  display: flex;
  align-items: center;
  gap: 8px;
}
.step {
  flex: 1;
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 36px 28px;
  text-align: center;
  transition: box-shadow var(--ease);
}
.step:hover { box-shadow: var(--shadow-md); }
.step-num {
  font-size: 2.8rem;
  font-weight: 800;
  color: var(--primary-bg2);
  line-height: 1;
  margin-bottom: 16px;
  letter-spacing: -.04em;
}
.step h3 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 10px;
}
.step p {
  font-size: .875rem;
  color: var(--text-muted);
  line-height: 1.65;
}
.step-arrow {
  color: var(--primary-bg2);
  flex-shrink: 0;
  display: flex;
  align-items: center;
}

/* ═══════════════════════════════════════════
   FEATURES (POR QUÉ NOSOTROS)
═══════════════════════════════════════════ */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 40px;
}
.feature { text-align: center; }
.feature-icon {
  width: 68px; height: 68px;
  border-radius: 50%;
  background: rgba(255,255,255,.14);
  border: 1.5px solid rgba(255,255,255,.2);
  display: flex; align-items: center; justify-content: center;
  color: var(--white);
  margin: 0 auto 20px;
}
.feature-icon svg { width: 28px; height: 28px; }
.feature h3 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 10px;
}
.feature p {
  font-size: .875rem;
  color: rgba(255,255,255,.7);
  line-height: 1.65;
  max-width: 240px;
  margin: 0 auto;
}

/* ═══════════════════════════════════════════
   CONTACT SECTION
═══════════════════════════════════════════ */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 72px;
  align-items: start;
}
.contact-info h2 {
  font-size: clamp(1.5rem, 2.5vw, 2rem);
  font-weight: 800;
  letter-spacing: -.02em;
  margin-bottom: 14px;
}
.contact-info > p {
  color: var(--text-muted);
  margin-bottom: 36px;
  line-height: 1.7;
}
.contact-details {
  display: flex;
  flex-direction: column;
  gap: 22px;
  margin-bottom: 32px;
}
.contact-details li {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}
.contact-icon {
  width: 42px; height: 42px;
  border-radius: var(--radius-sm);
  background: var(--primary-bg);
  display: flex; align-items: center; justify-content: center;
  color: var(--primary);
  flex-shrink: 0;
}
.contact-icon svg { width: 20px; height: 20px; }
.contact-details span {
  display: block;
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--text-muted);
  font-weight: 600;
  margin-bottom: 3px;
}
.contact-details a {
  font-size: .95rem;
  font-weight: 600;
  color: var(--primary);
  transition: color var(--ease);
}
.contact-details a:hover { color: var(--primary-dark); }
.trust-note {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .8rem;
  color: var(--text-muted);
  padding: 12px 16px;
  background: var(--primary-bg);
  border-radius: var(--radius-sm);
  border-left: 3px solid var(--primary);
}
.trust-note svg { color: var(--primary); flex-shrink: 0; }

/* Contact form */
.contact-form-wrap {
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 40px;
  box-shadow: var(--shadow);
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 16px;
}
.form-group label {
  font-size: .83rem;
  font-weight: 600;
  color: var(--text);
}
.form-group input,
.form-group select,
.form-group textarea {
  padding: 11px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: .9rem;
  color: var(--text);
  background: var(--white);
  transition: border-color var(--ease), box-shadow var(--ease);
}
.form-group input::placeholder,
.form-group textarea::placeholder { color: var(--gray-400); }
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(31,106,127,.12);
}
.form-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 22px;
}
.form-check input[type="checkbox"] {
  accent-color: var(--primary);
  width: 16px; height: 16px;
  margin-top: 2px;
  flex-shrink: 0;
}
.form-check label {
  font-size: .83rem;
  color: var(--text-muted);
  line-height: 1.5;
}
.form-check a { color: var(--primary); text-decoration: underline; }

/* ═══════════════════════════════════════════
   FOOTER
═══════════════════════════════════════════ */
footer {
  background: var(--gray-900);
  color: rgba(255,255,255,.6);
  padding: 64px 0 0;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 52px;
  padding-bottom: 52px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.footer-brand .logo { margin-bottom: 18px; }
.footer-brand p {
  font-size: .83rem;
  color: rgba(255,255,255,.45);
  line-height: 1.7;
  max-width: 280px;
}
.footer-col h4 {
  font-size: .75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .07em;
  color: rgba(255,255,255,.85);
  margin-bottom: 16px;
}
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col a {
  font-size: .875rem;
  color: rgba(255,255,255,.5);
  transition: color var(--ease);
}
.footer-col a:hover { color: var(--white); }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 22px 0;
  font-size: .78rem;
  color: rgba(255,255,255,.35);
  flex-wrap: wrap;
  gap: 12px;
}
.footer-links { display: flex; gap: 24px; flex-wrap: wrap; }
.footer-links a { color: rgba(255,255,255,.35); transition: color var(--ease); }
.footer-links a:hover { color: rgba(255,255,255,.75); }

/* ═══════════════════════════════════════════
   FRANJA ASEGURADORAS
═══════════════════════════════════════════ */
.insurers-strip {
  background: var(--white);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 32px 0;
  overflow: hidden;
}
.insurers-label {
  text-align: center;
  font-size: .75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--gray-400);
  margin-bottom: 24px;
}
.insurers-track-wrap {
  overflow: hidden;
  mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
  -webkit-mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
}
.insurers-track {
  display: flex;
  align-items: center;
  gap: 0;
  width: max-content;
  animation: scroll-logos 30s linear infinite;
}
.insurers-track:hover { animation-play-state: paused; }

@keyframes scroll-logos {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

.ins-logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 170px;
  height: 64px;
  padding: 10px 24px;
  border-right: 1.5px solid var(--border);
  flex-shrink: 0;
  opacity: .8;
  transition: opacity .35s;
  box-sizing: border-box;
}
.ins-logo:hover { opacity: 1; }
.ins-logo img {
  max-width: 118px;
  max-height: 38px;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
}

/* ═══════════════════════════════════════════
   TRUST BADGES + REVIEWS CTA
═══════════════════════════════════════════ */
.trust-badges {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 56px;
}
.trust-badge {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow .2s, transform .2s;
}
.trust-badge:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.trust-badge-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: var(--primary-bg);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.trust-badge-icon svg {
  width: 20px;
  height: 20px;
}
.trust-badge-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.trust-badge-body strong {
  font-size: .9rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.3;
}
.trust-badge-body span {
  font-size: .78rem;
  color: var(--text-muted);
  line-height: 1.4;
}
.newcorred-label {
  color: var(--primary);
  font-style: italic;
  font-weight: 800;
  letter-spacing: -.01em;
}

/* Google Reviews CTA */
.reviews-cta {
  background: linear-gradient(135deg, var(--primary-bg) 0%, var(--primary-bg2) 100%);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 48px 40px;
  text-align: center;
  max-width: 640px;
  margin: 0 auto;
}
.reviews-stars {
  display: flex;
  justify-content: center;
  gap: 4px;
  margin-bottom: 16px;
  color: #f59e0b;
}
.reviews-stars svg {
  width: 24px;
  height: 24px;
}
.reviews-cta h3 {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 10px;
  letter-spacing: -.02em;
}
.reviews-cta p {
  font-size: .95rem;
  color: var(--text-muted);
  line-height: 1.65;
  margin-bottom: 24px;
  max-width: 460px;
  margin-left: auto;
  margin-right: auto;
}
.reviews-btn {
  gap: 8px;
}

@media (max-width: 900px) {
  .trust-badges { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 540px) {
  .trust-badges { grid-template-columns: 1fr; }
  .reviews-cta { padding: 32px 20px; }
}

/* ═══════════════════════════════════════════
   WHATSAPP FLOTANTE
═══════════════════════════════════════════ */
.whatsapp-fab {
  position: fixed;
  bottom: 28px;
  right: 28px;
  z-index: 999;
  width: 58px;
  height: 58px;
  background: #25d366;
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(37,211,102,.45);
  transition: transform .2s ease, box-shadow .2s ease;
  text-decoration: none;
}
.whatsapp-fab:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 28px rgba(37,211,102,.6);
}
@media (max-width: 768px) {
  .whatsapp-fab { bottom: 20px; right: 16px; width: 52px; height: 52px; }
  .whatsapp-fab svg { width: 24px; height: 24px; }
}

/* ═══════════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════════ */
@media (max-width: 1024px) {
  .hero-grid { grid-template-columns: 1fr 380px; gap: 48px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 36px; }
}

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-card { max-width: 480px; }
  .contact-grid { grid-template-columns: 1fr; gap: 44px; }
}

@media (max-width: 768px) {
  #main-nav { display: none; }
  .hamburger { display: flex; }
  .header-top .btn { display: none; }

  #main-nav.open {
    display: block;
    position: absolute;
    top: 100%; left: 0; right: 0;
    background: var(--primary-dark);
    border-top: 1px solid rgba(255,255,255,.1);
    padding: 8px 0 16px;
    box-shadow: var(--shadow-lg);
    max-height: 80vh;
    overflow-y: auto;
  }
  #main-nav.open ul  { flex-direction: column; gap: 0; }
  #main-nav.open a   { padding: 12px 22px; font-size: .9rem; }

  /* Dropdown móvil */
  #main-nav.open .dropdown {
    display: none;
    position: static;
    box-shadow: none;
    border: none;
    border-top: none;
    border-radius: 0;
    background: rgba(0,0,0,.2);
    padding: 4px 0 4px 16px;
    margin: 0;
  }
  #main-nav.open .dropdown a { font-size: .85rem; color: rgba(255,255,255,.8); padding: 10px 22px; }
  #main-nav.open .dropdown a:hover { background: rgba(255,255,255,.1); color: white; padding-left: 26px; }
  #main-nav.open .has-dropdown.open-mobile .dropdown { display: block; }
  #main-nav.open .has-dropdown.open-mobile .chevron  { transform: rotate(180deg); }

  .hero { padding: 110px 0 64px; min-height: auto; }
  .hero-btns { flex-direction: column; gap: 10px; }
  .hero-btns .btn { text-align: center; }

  .steps { flex-direction: column; gap: 0; }
  .step  { border-radius: 0; border-bottom-width: 0; }
  .step:first-child { border-radius: var(--radius) var(--radius) 0 0; }
  .step:last-child  { border-radius: 0 0 var(--radius) var(--radius); border-bottom-width: 1.5px; }
  .step-arrow { transform: rotate(90deg); padding: 4px 0; }

  .tab-nav { flex-wrap: wrap; width: 100%; }
  .tab-btn { flex: 1; justify-content: center; }

  .form-row { grid-template-columns: 1fr; gap: 0; }
  .contact-form-wrap { padding: 28px 22px; }
}

@media (max-width: 580px) {
  .container { padding: 0 18px; }
  .section { padding: 60px 0; }
  .hero-stats { gap: 18px; }
  .stat strong { font-size: 1.6rem; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .footer-bottom { flex-direction: column; text-align: center; }
  .footer-links { justify-content: center; }
  .features-grid { grid-template-columns: 1fr 1fr; gap: 28px; }
}

@media (max-width: 360px) {
  .features-grid { grid-template-columns: 1fr; }
  .hero-stats { flex-wrap: wrap; }
  .stat-sep { display: none; }
}


/* ═══════════════════════════════════════════
   MODAL
═══════════════════════════════════════════ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}
.modal-overlay.open {
  opacity: 1;
  pointer-events: all;
}
.modal {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  max-width: 560px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  transform: translateY(20px) scale(0.97);
  transition: transform 0.25s ease;
  position: relative;
}
.modal-overlay.open .modal {
  transform: translateY(0) scale(1);
}

/* Botón cerrar */
.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--gray-100);
  color: var(--gray-600);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--ease), color var(--ease);
  z-index: 2;
}
.modal-close:hover {
  background: var(--gray-200);
  color: var(--gray-900);
}

/* Cabecera del modal */
.modal-header {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
  padding: 40px 32px 32px;
  border-radius: var(--radius) var(--radius) 0 0;
  color: var(--white);
}
.modal-icon {
  width: 56px;
  height: 56px;
  background: rgba(255,255,255,.15);
  border: 1.5px solid rgba(255,255,255,.25);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  color: var(--white);
}
.modal-icon svg { width: 26px; height: 26px; }
.modal-title {
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -.02em;
  margin-bottom: 6px;
  color: var(--white);
}
.modal-subtitle {
  font-size: .95rem;
  color: rgba(255,255,255,.78);
  line-height: 1.5;
}

/* Cuerpo del modal */
.modal-body {
  padding: 28px 32px;
  flex: 1;
}
.modal-body h4 {
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 14px;
}
.modal-coverages {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.modal-coverages li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: .92rem;
  color: var(--text);
  line-height: 1.45;
}
.modal-coverages li::before {
  content: '';
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  margin-top: 1px;
  background: var(--primary-bg);
  border-radius: 50%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231f6a7f' stroke-width='2.5'%3E%3Cpath d='M20 6L9 17l-5-5'/%3E%3C/svg%3E");
  background-size: 12px;
  background-repeat: no-repeat;
  background-position: center;
}
.modal-note {
  margin-top: 20px;
  padding: 14px 16px;
  background: var(--primary-bg);
  border-left: 3px solid var(--primary);
  border-radius: 0 var(--radius-xs) var(--radius-xs) 0;
  font-size: .85rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Pie del modal */
.modal-footer {
  padding: 20px 32px 28px;
  border-top: 1px solid var(--border);
}
.modal-cta {
  display: block;
  text-align: center;
  width: 100%;
  font-size: 1rem;
  padding: 14px 24px;
}

/* Responsive */
@media (max-width: 560px) {
  .modal-header { padding: 32px 22px 24px; }
  .modal-body   { padding: 22px 22px; }
  .modal-footer { padding: 18px 22px 24px; }
  .modal-title  { font-size: 1.2rem; }
}


/* ═══════════════════════════════════════════
   SECTORES
═══════════════════════════════════════════ */
.sectores-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.sector-card {
  background: var(--white);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 32px 28px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  transition: box-shadow var(--ease), transform var(--ease);
}
.sector-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}

.sector-card-header {
  display: flex;
  align-items: center;
  gap: 16px;
}
.sector-icon {
  width: 52px; height: 52px;
  border-radius: 12px;
  background: var(--primary-bg);
  border: 1.5px solid var(--primary-bg2);
  display: flex; align-items: center; justify-content: center;
  color: var(--primary);
  flex-shrink: 0;
}
.sector-icon svg { width: 24px; height: 24px; }

.sector-card h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.3;
}

.sector-desc {
  font-size: .92rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.sector-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 9px;
  flex: 1;
}
.sector-list li {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  font-size: .875rem;
  color: var(--text);
  line-height: 1.45;
}
.sector-list li::before {
  content: '';
  flex-shrink: 0;
  width: 18px; height: 18px;
  margin-top: 1px;
  background: var(--primary-bg);
  border-radius: 50%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231f6a7f' stroke-width='2.5'%3E%3Cpath d='M20 6L9 17l-5-5'/%3E%3C/svg%3E");
  background-size: 11px;
  background-repeat: no-repeat;
  background-position: center;
}

.sector-cta {
  align-self: flex-start;
  font-size: .875rem;
  padding: 10px 20px;
}

@media (max-width: 900px) {
  .sectores-grid { grid-template-columns: 1fr; }
}


/* Redes sociales footer */
.footer-social {
  display: flex;
  gap: 10px;
  margin-top: 8px;
}
.social-btn {
  width: 36px; height: 36px;
  border-radius: 8px;
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,255,255,.15);
  color: rgba(255,255,255,.7);
  display: flex; align-items: center; justify-content: center;
  transition: background var(--ease), color var(--ease);
}
.social-btn:hover {
  background: rgba(255,255,255,.2);
  color: var(--white);
}


/* ═══════════════════════════════════════════
   MAPA DE CONTACTO
═══════════════════════════════════════════ */
.contact-map {
  margin-top: 24px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}
.contact-map iframe {
  display: block;
}


/* ═══════════════════════════════════════════
   BOTÓN WHATSAPP FLOTANTE
═══════════════════════════════════════════ */
.whatsapp-btn {
  position: fixed;
  bottom: 28px;
  right: 28px;
  z-index: 500;
  width: 58px;
  height: 58px;
  background: #25D366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(37,211,102,.45);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  color: #fff;
}
.whatsapp-btn svg {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
}
.whatsapp-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 22px rgba(37,211,102,.55);
}

/* Tooltip */
.whatsapp-tooltip {
  position: absolute;
  right: 70px;
  background: var(--gray-900);
  color: #fff;
  font-size: .8rem;
  font-weight: 600;
  white-space: nowrap;
  padding: 7px 13px;
  border-radius: var(--radius-xs);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}
.whatsapp-tooltip::after {
  content: '';
  position: absolute;
  left: 100%;
  top: 50%;
  transform: translateY(-50%);
  border: 6px solid transparent;
  border-left-color: var(--gray-900);
}
.whatsapp-btn:hover .whatsapp-tooltip {
  opacity: 1;
}

/* Animación de entrada */
@keyframes wa-bounce {
  0%   { transform: scale(0); opacity: 0; }
  70%  { transform: scale(1.15); }
  100% { transform: scale(1); opacity: 1; }
}
.whatsapp-btn {
  animation: wa-bounce 0.5s ease 1.5s both;
}


/* ═══════════════════════════════════════════
   CHAT WIDGET
═══════════════════════════════════════════ */
#chat-widget {
  position: fixed;
  bottom: 28px;
  left: 28px;
  z-index: 600;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

/* Botón toggle */
.chat-toggle {
  width: 58px; height: 58px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 16px rgba(31,106,127,.45);
  transition: transform .2s ease, box-shadow .2s ease;
  position: relative;
  animation: wa-bounce .5s ease 2s both;
  border: none; cursor: pointer;
}
.chat-toggle svg { width: 26px; height: 26px; }
.chat-toggle:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 22px rgba(31,106,127,.55);
}
.chat-badge {
  position: absolute; top: -4px; right: -4px;
  width: 20px; height: 20px;
  background: var(--accent);
  border-radius: 50%;
  font-size: .7rem; font-weight: 700; color: #fff;
  display: flex; align-items: center; justify-content: center;
  border: 2px solid #fff;
  animation: pulse-badge 1.5s infinite;
}
@keyframes pulse-badge {
  0%,100% { transform: scale(1); }
  50%      { transform: scale(1.2); }
}

/* Ventana de chat */
.chat-window {
  width: 340px;
  max-height: 520px;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  display: flex; flex-direction: column;
  overflow: hidden;
  position: absolute;
  bottom: 70px; left: 0;
  transform: scale(.92) translateY(12px);
  opacity: 0; pointer-events: none;
  transition: transform .25s ease, opacity .25s ease;
  transform-origin: bottom left;
}
.chat-window.open {
  transform: scale(1) translateY(0);
  opacity: 1; pointer-events: all;
}

/* Header */
.chat-header {
  background: linear-gradient(135deg, var(--primary-dark), var(--primary));
  padding: 14px 16px;
  display: flex; align-items: center; justify-content: space-between;
  flex-shrink: 0;
}
.chat-agent-info { display: flex; align-items: center; gap: 10px; }
.chat-avatar {
  width: 38px; height: 38px; border-radius: 50%;
  background: rgba(255,255,255,.2);
  border: 2px solid rgba(255,255,255,.35);
  color: #fff; font-weight: 800; font-size: .95rem;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.chat-agent-name  { font-size: .875rem; font-weight: 700; color: #fff; }
.chat-agent-status { font-size: .72rem; color: rgba(255,255,255,.75); display: flex; align-items: center; gap: 4px; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: #4ade80; display: inline-block; }
.chat-x {
  background: rgba(255,255,255,.15); border: none; cursor: pointer;
  color: rgba(255,255,255,.85); width: 28px; height: 28px;
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  transition: background var(--ease);
}
.chat-x:hover { background: rgba(255,255,255,.28); }

/* Mensajes */
.chat-messages {
  flex: 1; overflow-y: auto;
  padding: 16px 14px;
  display: flex; flex-direction: column; gap: 10px;
  scroll-behavior: smooth;
}
.chat-messages::-webkit-scrollbar { width: 4px; }
.chat-messages::-webkit-scrollbar-thumb { background: var(--gray-200); border-radius: 4px; }

.chat-msg { display: flex; }
.chat-msg--bot  { justify-content: flex-start; }
.chat-msg--user { justify-content: flex-end; }

.chat-bubble {
  max-width: 82%;
  padding: 9px 13px;
  border-radius: 16px;
  font-size: .875rem;
  line-height: 1.5;
}
.chat-msg--bot  .chat-bubble {
  background: var(--primary-bg);
  color: var(--text);
  border-bottom-left-radius: 4px;
}
.chat-msg--user .chat-bubble {
  background: var(--primary);
  color: #fff;
  border-bottom-right-radius: 4px;
}

/* Typing indicator */
.chat-typing .chat-bubble {
  display: flex; align-items: center; gap: 4px;
  padding: 12px 16px;
}
.chat-typing .chat-bubble span {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--primary);
  opacity: .4;
  animation: typing-dot 1.2s infinite;
}
.chat-typing .chat-bubble span:nth-child(2) { animation-delay: .2s; }
.chat-typing .chat-bubble span:nth-child(3) { animation-delay: .4s; }
@keyframes typing-dot {
  0%,60%,100% { opacity: .4; transform: translateY(0); }
  30%         { opacity: 1;  transform: translateY(-4px); }
}

/* Quick replies */
.chat-quick-replies {
  padding: 6px 12px 8px;
  display: flex; flex-wrap: wrap; gap: 6px;
  flex-shrink: 0;
}
.chat-qr-btn {
  background: #fff;
  border: 1.5px solid var(--primary);
  color: var(--primary);
  border-radius: 100px;
  padding: 5px 13px;
  font-size: .78rem; font-weight: 600;
  cursor: pointer;
  transition: background var(--ease), color var(--ease);
  white-space: nowrap;
}
.chat-qr-btn:hover {
  background: var(--primary); color: #fff;
}

/* Input */
.chat-input-bar {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 12px;
  border-top: 1px solid var(--border);
  flex-shrink: 0;
}
#chat-input {
  flex: 1; border: 1.5px solid var(--border);
  border-radius: 100px; padding: 8px 14px;
  font-size: .875rem; outline: none;
  transition: border-color var(--ease);
}
#chat-input:focus { border-color: var(--primary); }
.chat-send {
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--primary); color: #fff;
  border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  transition: background var(--ease);
}
.chat-send:hover { background: var(--primary-dark); }

/* Responsive */
@media (max-width: 400px) {
  #chat-widget { left: 12px; bottom: 12px; }
  .chat-window { width: calc(100vw - 24px); }
}
