/* ===== Tokens ===== */
:root {
  --navy: #0A2540;
  --blue-800: #1E3A8A;
  --blue-700: #1D4ED8;
  --blue-600: #2563EB;
  --blue-500: #3B82F6;
  --blue-100: #DBEAFE;
  --blue-50: #F0F6FF;
  --slate-900: #0F172A;
  --slate-600: #475569;
  --slate-400: #94A3B8;
  --slate-200: #E2E8F0;
  --slate-100: #F1F5F9;
  --white: #FFFFFF;
  --font-display: 'Sora', sans-serif;
  --font-body: 'IBM Plex Sans', sans-serif;
  --radius: 14px;
  --container: 1200px;

  /* Theme-aware surface tokens (light default) */
  --bg: #FFFFFF;
  --bg-alt: var(--blue-50);
  --surface: #FFFFFF;
  --border: var(--slate-200);
  --text: var(--slate-900);
  --text-secondary: var(--slate-600);
  --header-bg: #FFFFFF;
  --shadow-color: rgba(15,23,42,.1);
  --link-hover: var(--navy);
}

html[data-theme="dark"] {
  --bg: #0B1220;
  --bg-alt: #101B2D;
  --surface: #141F33;
  --border: #253349;
  --text: #EEF2FA;
  --text-secondary: #9FADC2;
  --header-bg: #0B1220;
  --shadow-color: rgba(0,0,0,.45);
  --link-hover: #93C5FD;
}

/* ===== Reset ===== */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  transition: background-color .2s ease, color .2s ease;
}
h1, h2, h3 { font-family: var(--font-display); margin: 0 0 12px; line-height: 1.2; }
p { margin: 0 0 12px; line-height: 1.6; color: var(--text-secondary); }
img { max-width: 100%; display: block; }
a { color: var(--blue-700); text-decoration: none; }
a:hover { color: var(--link-hover); }
ul { list-style: none; margin: 0; padding: 0; }
button { font-family: inherit; }

.skip-link {
  position: absolute; left: -999px; top: 0;
  background: var(--blue-700); color: #fff; padding: 10px 16px; z-index: 100;
}
.skip-link:focus { left: 12px; top: 12px; }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}
.container-narrow { max-width: 900px; }

/* ===== Buttons ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 12px 22px; border-radius: 9px; font-weight: 700; font-size: 14.5px;
  border: none; cursor: pointer; transition: all .15s ease; white-space: nowrap;
}
.btn-lg { padding: 15px 28px; font-size: 15px; }
.btn-block { width: 100%; padding: 15px; }
.btn-primary { background: var(--blue-700); color: #fff; }
.btn-primary:hover { background: var(--navy); color: #fff; }
.btn-white { background: #fff; color: var(--blue-700); }
.btn-white:hover { background: var(--blue-50); color: var(--blue-700); }
.btn-outline { background: transparent; color: #fff; border: 1.5px solid rgba(255,255,255,.55); }
.btn-outline:hover { border-color: #fff; background: rgba(255,255,255,.08); color: #fff; }

/* ===== Header ===== */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--header-bg); border-bottom: 1px solid var(--border);
  transition: background-color .2s ease, border-color .2s ease;
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 24px; gap: 16px;
}
.logo { display: flex; flex-direction: column; line-height: 1; }
.logo-word { font-family: var(--font-display); font-weight: 800; font-size: 21px; letter-spacing: .3px; color: var(--text); }
.logo-word.on-dark { color: #fff; }
.logo-tag { font-size: 10.5px; letter-spacing: 1.5px; color: var(--blue-600); font-weight: 600; margin-top: 2px; }

.nav-wrap { display: flex; align-items: center; gap: 20px; }
.main-nav { display: flex; align-items: center; gap: 26px; }
.main-nav a { font-size: 14.5px; font-weight: 500; color: var(--text); }
.main-nav a:hover { color: var(--blue-700); }

.header-cta { flex-shrink: 0; }

.header-actions { display: flex; align-items: center; gap: 10px; }

.theme-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: 999px; flex-shrink: 0;
  background: var(--bg-alt); border: 1px solid var(--border); color: var(--text);
  cursor: pointer; transition: background-color .15s ease, border-color .15s ease, transform .15s ease;
}
.theme-toggle:hover { transform: translateY(-1px); border-color: var(--blue-500); }
.theme-toggle svg { width: 18px; height: 18px; }
.theme-toggle .icon-moon { display: none; }
html[data-theme="dark"] .theme-toggle .icon-sun { display: none; }
html[data-theme="dark"] .theme-toggle .icon-moon { display: block; }

.nav-toggle {
  display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 6px;
}
.nav-toggle span { width: 22px; height: 2px; background: var(--text); display: block; }

/* ===== Eyebrow / Section head ===== */
.eyebrow {
  display: inline-block; font-size: 13px; font-weight: 700; letter-spacing: 1.2px;
  color: var(--blue-600); margin-bottom: 10px;
}
.eyebrow-dark {
  padding: 6px 14px; border-radius: 999px; background: rgba(59,130,246,.18);
  border: 1px solid rgba(59,130,246,.4); color: #93C5FD; letter-spacing: .3px; font-size: 12.5px;
}
.eyebrow-light { color: #93C5FD; }

.section-head { max-width: 640px; margin: 0 auto 44px; text-align: center; }
.section-head h2 { font-size: 32px; font-weight: 800; color: var(--text); }
.section-head p { margin-top: 8px; }
.on-dark { color: #fff; }
.on-dark-muted { color: #CBD5E1; max-width: 540px; margin: 0 auto; }

/* ===== Hero ===== */
.hero {
  background: linear-gradient(180deg, var(--navy) 0%, #0D2E52 100%);
  padding: 64px 0 80px;
}
.hero-grid {
  display: grid; grid-template-columns: 1.05fr .95fr; gap: 48px; align-items: center;
}
.hero-copy { display: flex; flex-direction: column; gap: 18px; }
.hero-copy h1 { font-size: 42px; color: #fff; font-weight: 800; max-width: 560px; }
.lead { font-size: 17px; color: #CBD5E1; max-width: 520px; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 6px; }
.hero-badges { display: flex; gap: 24px; flex-wrap: wrap; margin-top: 14px; }
.hero-badges li { font-size: 13.5px; color: #E2E8F0; display: flex; align-items: center; gap: 8px; }
.check { color: #4ADE80; font-weight: 700; }

.hero-media { display: flex; align-items: center; justify-content: center; }

.hero-carousel {
  position: relative; width: 100%; max-width: 380px; aspect-ratio: 3/4; border-radius: 20px;
  overflow: hidden; border: 1px solid rgba(148,163,184,.3); background: #0D2E52;
  box-shadow: 0 24px 48px rgba(0,0,0,.28);
}
.hero-slide {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center;
  opacity: 0; transition: opacity 1.1s ease;
}
.hero-slide.is-active { opacity: 1; }
.hero-carousel-dots {
  position: absolute; bottom: 16px; left: 50%; transform: translateX(-50%);
  display: flex; gap: 8px; z-index: 2;
}
.hero-carousel-dots .dot {
  width: 7px; height: 7px; border-radius: 999px; background: rgba(255,255,255,.45);
  transition: background .2s ease, transform .2s ease;
}
.hero-carousel-dots .dot.is-active { background: #fff; transform: scale(1.3); }

/* ===== Sections ===== */
.section { padding: 72px 0; }
.section-alt { background: var(--bg-alt); transition: background-color .2s ease; }
.section-dark { background: var(--navy); }

.grid { display: grid; gap: 20px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0,1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0,1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0,1fr)); }

/* ===== Cards (why us) ===== */
.card {
  padding: 26px 22px; border-radius: var(--radius); border: 1px solid var(--border);
  background: var(--surface); transition: box-shadow .18s ease, transform .18s ease, background-color .2s ease, border-color .2s ease;
}
.card:hover { box-shadow: 0 12px 28px var(--shadow-color); transform: translateY(-2px); }
.icon-box {
  width: 44px; height: 44px; border-radius: 10px; background: var(--bg-alt);
  display: flex; align-items: center; justify-content: center; margin-bottom: 16px; color: var(--blue-600);
}
.icon-box svg { width: 22px; height: 22px; }
.card h3 { font-size: 16.5px; margin-bottom: 8px; color: var(--text); }
.card p { font-size: 14px; margin: 0; }

/* ===== Solutions ===== */
.solution-card {
  background: var(--surface); border-radius: 16px; border: 1px solid var(--border);
  overflow: hidden; display: flex; flex-direction: column;
  transition: box-shadow .18s ease, transform .18s ease, background-color .2s ease, border-color .2s ease;
}
.solution-card:hover { box-shadow: 0 12px 28px var(--shadow-color); transform: translateY(-2px); }
.solution-bar { height: 6px; }
.bar-blue { background: var(--blue-700); }
.bar-navy { background: var(--navy); }
.bar-light { background: var(--blue-500); }
.solution-body { padding: 28px 26px; display: flex; flex-direction: column; gap: 14px; flex-grow: 1; }
.icon-box-fill { width: 46px; height: 46px; border-radius: 10px; }
.icon-box-fill svg { width: 24px; height: 24px; }
.fill-blue { background: var(--blue-700); }
.fill-navy { background: var(--navy); }
.fill-light { background: var(--blue-500); }
.solution-body h3 { font-size: 19px; color: var(--text); }
.solution-body p { font-size: 14px; margin: 0; }
.tag-list { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; }
.tag-list li { font-size: 13.5px; color: var(--text); padding-left: 16px; position: relative; }
.tag-list li::before { content: "•"; color: var(--blue-600); position: absolute; left: 0; }
.solution-link { margin: 0 26px 24px; font-size: 13.5px; font-weight: 700; }

/* ===== Steps ===== */
.steps { text-align: center; }
.step { display: flex; flex-direction: column; align-items: center; gap: 10px; }
.step-num {
  width: 52px; height: 52px; border-radius: 999px; background: var(--navy); color: #fff;
  font-family: var(--font-display); font-weight: 800; font-size: 18px;
  display: flex; align-items: center; justify-content: center;
}
.step h3 { font-size: 16.5px; margin-top: 4px; color: var(--text); }
.step p { font-size: 14px; max-width: 260px; margin: 0 auto; }

/* ===== Calculator ===== */
.calc-card {
  background: var(--surface); border-radius: 18px; padding: 36px; display: flex; flex-direction: column; gap: 26px;
  max-width: 640px; margin: 0 auto; transition: background-color .2s ease;
}
.calc-label { font-size: 13px; font-weight: 700; color: var(--text-secondary); letter-spacing: .3px; display: block; margin-bottom: 10px; }
.calc-toggle, .calc-presets { display: flex; gap: 10px; flex-wrap: wrap; }
.chip {
  border: 1.5px solid var(--border); background: var(--surface); color: var(--text);
  border-radius: 999px; padding: 10px 16px; font-size: 13.5px; font-weight: 600; cursor: pointer;
  transition: all .15s ease;
}
.chip-toggle { flex: 1; border-radius: 10px; padding: 13px; font-size: 14.5px; font-weight: 700; text-align: center; }
.chip:hover { border-color: var(--blue-500); }
.chip.is-active { background: var(--blue-700); color: #fff; border-color: var(--blue-700); }

.calc-slider-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 12px; }
.calc-slider-value { font-family: var(--font-display); font-size: 26px; font-weight: 800; color: var(--blue-700); }
.calc-slider {
  -webkit-appearance: none; appearance: none; width: 100%; height: 6px; border-radius: 999px;
  background: var(--border); outline: none; cursor: pointer; margin: 4px 0;
}
.calc-slider::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none; width: 22px; height: 22px; border-radius: 999px;
  background: var(--blue-700); border: 3px solid var(--surface); box-shadow: 0 2px 8px rgba(29,78,216,.4); cursor: pointer;
}
.calc-slider::-moz-range-thumb {
  width: 22px; height: 22px; border-radius: 999px; background: var(--blue-700);
  border: 3px solid var(--surface); box-shadow: 0 2px 8px rgba(29,78,216,.4); cursor: pointer;
}
.calc-slider-ticks { display: flex; justify-content: space-between; margin-top: 8px; }
.calc-slider-ticks span { font-size: 12px; color: var(--slate-400); font-weight: 500; }

.calc-results { text-align: center; }
.calc-result { background: var(--bg-alt); border-radius: 12px; padding: 18px; transition: background-color .2s ease; }
.calc-result span { font-size: 12px; font-weight: 700; color: var(--blue-600); letter-spacing: .3px; display: block; }
.calc-result strong { font-family: var(--font-display); font-size: 24px; font-weight: 800; color: var(--text); display: block; margin-top: 6px; }
.calc-result-wide { text-align: center; margin-top: -8px; }

.calc-ahorro-box { background: var(--navy); border-radius: 12px; padding: 22px; text-align: center; }
.calc-ahorro-box span { font-size: 12.5px; font-weight: 700; color: #93C5FD; letter-spacing: .4px; display: block; }
.calc-ahorro-box strong { font-family: var(--font-display); font-size: 36px; font-weight: 800; color: #34D399; display: block; margin-top: 8px; }

.calc-disclaimer { font-size: 12px; color: var(--slate-400); text-align: center; margin: 0; }

/* ===== Testimonials ===== */
.testimonial { background: var(--bg-alt); border-radius: 14px; padding: 26px; margin: 0; transition: background-color .2s ease; }
.stars { color: var(--blue-500); font-size: 18px; letter-spacing: 2px; display: block; margin-bottom: 10px; }
.testimonial p { font-size: 14.5px; color: var(--text); margin: 0 0 12px; }
.testimonial cite { font-size: 13px; font-weight: 700; color: var(--text-secondary); font-style: normal; }

/* ===== FAQ ===== */
.faq-list { display: flex; flex-direction: column; gap: 12px; }
.faq-item { background: var(--surface); border-radius: 12px; border: 1px solid var(--border); overflow: hidden; transition: background-color .2s ease, border-color .2s ease; }
.faq-question {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 20px 24px; background: none; border: none; cursor: pointer; text-align: left;
  font-size: 15px; font-weight: 700; color: var(--text);
}
.faq-icon { font-size: 20px; color: var(--blue-600); flex-shrink: 0; transition: transform .2s ease; }
.faq-item.is-open .faq-icon { transform: rotate(45deg); }
.faq-answer { max-height: 0; overflow: hidden; transition: max-height .25s ease; }
.faq-answer p { padding: 0 24px 20px; font-size: 14px; margin: 0; }
.faq-item.is-open .faq-answer { max-height: 200px; }

/* ===== Final CTA ===== */
.cta-final { padding: 68px 0; background: linear-gradient(120deg, var(--blue-700), var(--navy)); }
.cta-final-inner { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 16px; }
.cta-final h2 { font-size: 30px; color: #fff; }
.cta-final p { color: #DBEAFE; max-width: 480px; }
.cta-final-actions { display: flex; gap: 14px; flex-wrap: wrap; justify-content: center; margin-top: 6px; }

/* ===== Footer ===== */
.site-footer { background: var(--navy); padding: 52px 0 24px; }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1fr; gap: 32px; }
.footer-brand { display: flex; flex-direction: column; gap: 10px; }
.footer-brand p { font-size: 13.5px; color: #94A3B8; max-width: 260px; margin-top: 4px; }
.footer-social { display: flex; gap: 10px; margin-top: 6px; }
.social-link {
  width: 36px; height: 36px; border-radius: 999px; display: flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.15); color: #fff;
  transition: background-color .15s ease, transform .15s ease;
}
.social-link:hover { background: var(--blue-600); color: #fff; transform: translateY(-2px); }
.social-link svg { width: 17px; height: 17px; }
.footer-col { display: flex; flex-direction: column; gap: 10px; }
.footer-title { font-size: 13px; font-weight: 700; color: #fff; margin-bottom: 4px; }
.footer-col a, .footer-col span { font-size: 13.5px; color: #94A3B8; }
.footer-col a:hover { color: #fff; }
.footer-bottom {
  margin-top: 40px; padding-top: 22px; border-top: 1px solid rgba(148,163,184,.18);
  text-align: center; font-size: 12.5px; color: #64748B;
}

/* ===== Responsive ===== */
@media (max-width: 960px) {
  .nav-wrap { display: none; }
  .nav-toggle { display: flex; }
  .site-header.nav-open .nav-wrap {
    display: flex; flex-direction: column; align-items: stretch; position: absolute; top: 100%; left: 0; right: 0;
    background: var(--header-bg); padding: 20px 24px; border-bottom: 1px solid var(--border); gap: 16px; z-index: 40;
  }
  .site-header.nav-open .main-nav { flex-direction: column; gap: 16px; }
  .site-header.nav-open .header-cta { justify-content: center; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-media { order: -1; }
  .hero-copy h1 { font-size: 34px; }
  .grid-4 { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .grid-3 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 640px) {
  .header-inner { padding: 14px 20px; }
  .hero { padding: 44px 0 56px; }
  .hero-copy h1 { font-size: 28px; }
  .section { padding: 52px 0; }
  .section-head h2 { font-size: 26px; }
  .grid-4 { grid-template-columns: 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
  .calc-card { padding: 24px; }
  .footer-grid { grid-template-columns: 1fr; }
  .cta-final h2 { font-size: 25px; }
}
