/* ==========================================================================
   APEX INNOVATIONS - ULTRA-MODERN CLEAN DESIGN SYSTEM
   Aesthetic: Minimalist Luxury Tech (Apple / Stripe style)
   Typography: Plus Jakarta Sans
   Palette: Crisp White (#FFFFFF), Slate Alabaster (#F8FAFC), Deep Navy (#0F172A), Cobalt (#2563EB), Gold (#D97706)
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;600&family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800;900&display=swap');

:root {
  /* Surfaces */
  --bg-page: #F8FAFC;
  --bg-white: #FFFFFF;
  --bg-card: #FFFFFF;
  --bg-subtle: #F1F5F9;
  --bg-muted: #E2E8F0;

  /* Typography */
  --text-primary: #0F172A;
  --text-secondary: #475569;
  --text-muted: #64748B;
  --text-white: #FFFFFF;

  /* Brand Accents */
  --color-navy: #0F172A;
  --color-navy-hover: #1E293B;
  --color-blue: #2563EB;
  --color-blue-soft: #EFF6FF;
  --color-blue-border: #BFDBFE;
  
  /* Highlights & Status */
  --color-gold: #B45309;
  --color-gold-text: #92400E;
  --color-gold-bg: #FEF3C7;
  --color-gold-border: #FDE68A;
  
  --color-emerald: #10B981;
  --color-emerald-text: #047857;
  --color-emerald-bg: #ECFDF5;
  --color-emerald-border: #A7F3D0;

  /* Borders & Shadows */
  --border-light: #E2E8F0;
  --border-card: #E5E7EB;
  --border-focus: #2563EB;

  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-card: 0 4px 20px -2px rgba(15, 23, 42, 0.05), 0 1px 3px rgba(15, 23, 42, 0.02);
  --shadow-hover: 0 12px 30px -4px rgba(15, 23, 42, 0.08), 0 2px 6px -1px rgba(15, 23, 42, 0.03);
  --shadow-pill: 0 2px 8px rgba(15, 23, 42, 0.06);

  --font-main: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-pill: 999px;

  --trans-fast: 0.16s ease;
  --trans-smooth: 0.24s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ==========================================================================
   RESET & BASE RULES
   ========================================================================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  background-color: var(--bg-page);
  color: var(--text-primary);
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: var(--font-main);
  background-color: var(--bg-page);
  color: var(--text-primary);
  line-height: 1.5;
  overflow-x: hidden;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* ==========================================================================
   TOP BAR & NAVIGATION
   ========================================================================== */
.top-notice-bar {
  background: #0A1120;
  color: #94A3B8;
  font-size: 0.8rem;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.top-notice-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.top-notice-left {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: #E2E8F0;
  font-weight: 500;
}

.badge-tag-dark {
  background: rgba(37, 99, 235, 0.2);
  color: #60A5FA;
  border: 1px solid rgba(96, 165, 250, 0.3);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 0.15rem 0.5rem;
  border-radius: var(--radius-pill);
}

.top-notice-right {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  font-size: 0.78rem;
}

.top-notice-right a {
  color: #CBD5E1;
  font-weight: 600;
}

.top-notice-right a:hover {
  color: #FFFFFF;
}

/* Main Navbar */
.navbar {
  position: sticky;
  top: 0;
  width: 100%;
  z-index: 100;
  /* Fondo sólido: un backdrop-filter se recalcula en cada cuadro del scroll y lo traba */
  background: #FFFFFF;
  border-bottom: 1px solid var(--border-light);
  box-shadow: var(--shadow-sm);
  transition: all var(--trans-smooth);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 4.5rem;
}

.brand-wrapper {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.brand-logo-img {
  height: 38px;
  width: auto;
  object-fit: contain;
}

/* Segmented Control Bar (Apple / Stripe style Tab Switcher) */
.tab-segmented-control {
  display: flex;
  align-items: center;
  background: #F1F5F9;
  padding: 4px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
  gap: 2px;
}

.tab-btn {
  padding: 0.5rem 1.1rem;
  border-radius: var(--radius-sm);
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--text-secondary);
  transition: all var(--trans-fast);
  white-space: nowrap;
}

.tab-btn:hover {
  color: var(--text-primary);
}

.tab-btn.active {
  background: #FFFFFF;
  color: var(--color-navy);
  box-shadow: var(--shadow-pill);
  font-weight: 700;
}

.tab-btn.highlight-cotizar {
  color: var(--color-blue);
}

.tab-btn.highlight-cotizar.active {
  background: #FFFFFF;
  color: var(--color-blue);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.7rem 1.4rem;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 700;
  transition: all var(--trans-fast);
  text-decoration: none;
  line-height: 1;
  white-space: nowrap;
}

.btn-primary {
  background: var(--color-navy);
  color: #FFFFFF;
  border: 1px solid var(--color-navy);
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.12);
}

.btn-primary:hover {
  background: var(--color-navy-hover);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.18);
}

.btn-primary.active, .btn-primary[data-target-tab="tab-cotizador"].active {
  background: var(--color-blue);
  border-color: var(--color-blue);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.25);
}

.btn-outline {
  background: #FFFFFF;
  color: var(--text-primary);
  border: 1.5px solid var(--border-card);
}

.btn-outline:hover {
  border-color: var(--text-primary);
  background: var(--bg-subtle);
}

.btn-whatsapp {
  background: #047857;
  color: #FFFFFF;
  font-weight: 700;
}

.btn-whatsapp:hover {
  background: #065F46;
  transform: translateY(-1px);
}

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.82rem;
  border-radius: var(--radius-sm);
}

.mobile-toggle {
  display: none;
  flex-direction: column;
  gap: 4px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.4rem;
}

.mobile-toggle span {
  width: 22px;
  height: 2px;
  background-color: var(--text-primary);
  border-radius: 2px;
}

/* ==========================================================================
   VIEW TAB SYSTEM (SPA)
   ========================================================================== */
.view-tab {
  display: none;
}

.view-tab.active {
  display: block;
  animation: tabFadeIn 0.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes tabFadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ==========================================================================
   HERO & PUNCHY SECTIONS
   ========================================================================== */
.hero-clean {
  background: linear-gradient(180deg, #FFFFFF 0%, #F8FAFC 100%);
  padding: 4.5rem 0 3.5rem;
  text-align: center;
  border-bottom: 1px solid var(--border-light);
}

.hero-pill-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--color-blue-soft);
  color: var(--color-blue);
  border: 1px solid var(--color-blue-border);
  padding: 0.35rem 0.95rem;
  border-radius: var(--radius-pill);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  margin-bottom: 1.5rem;
}

.hero-title-punchy {
  font-size: clamp(2.4rem, 4.5vw, 3.8rem);
  font-weight: 900;
  color: var(--text-primary);
  line-height: 1.12;
  letter-spacing: -0.03em;
  max-width: 880px;
  margin: 0 auto 1.2rem;
}

.hero-title-punchy span {
  color: var(--color-blue);
}

.hero-sub-punchy {
  font-size: clamp(1.05rem, 1.8vw, 1.25rem);
  color: var(--text-secondary);
  max-width: 680px;
  margin: 0 auto 2.2rem;
  line-height: 1.6;
}

.hero-btn-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 3.5rem;
}

/* Trust Metric Bar */
.trust-bar-clean {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.2rem;
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  box-shadow: var(--shadow-card);
}

.trust-item-clean {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  border-right: 1px solid var(--border-light);
}

.trust-item-clean:last-child {
  border-right: none;
}

.trust-num-clean {
  font-size: 1.8rem;
  font-weight: 900;
  color: var(--color-navy);
  line-height: 1.1;
  margin-bottom: 0.2rem;
}

.trust-lbl-clean {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
}

/* ==========================================================================
   MODULE CARDS (INICIO TAB)
   ========================================================================== */
.section-clean {
  padding: 4.5rem 0;
}

.section-head-clean {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 3rem;
}

.section-eyebrow {
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--color-blue);
  margin-bottom: 0.5rem;
  display: block;
}

.section-title-clean {
  font-size: clamp(1.9rem, 3.2vw, 2.6rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin-bottom: 0.6rem;
  line-height: 1.2;
}

.section-desc-clean {
  font-size: 1rem;
  color: var(--text-secondary);
}

.three-pillars-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.8rem;
}

.pillar-card-clean {
  background: #FFFFFF;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  padding: 2.2rem;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all var(--trans-smooth);
  cursor: pointer;
  position: relative;
}

.pillar-card-clean:hover {
  transform: translateY(-4px);
  border-color: var(--color-blue);
  box-shadow: var(--shadow-hover);
}

.pillar-icon-svg {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background: var(--color-blue-soft);
  color: var(--color-blue);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.2rem;
}

.pillar-badge-clean {
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text-muted);
  margin-bottom: 0.3rem;
}

.pillar-title-clean {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 0.6rem;
}

.pillar-desc-clean {
  font-size: 0.92rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.pillar-price-pill {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--color-navy);
  margin-bottom: 1.2rem;
}

.pillar-action-link {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--color-blue);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

/* ==========================================================================
   PÁGINAS WEB TAB (CLEAN & ATTRACTIVE)
   ========================================================================== */
.hero-module-banner {
  background: #FFFFFF;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  padding: 3rem;
  box-shadow: var(--shadow-card);
  margin-bottom: 3.5rem;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 2.5rem;
  align-items: center;
}

.hero-mod-title {
  font-size: clamp(2rem, 3.2vw, 2.6rem);
  font-weight: 900;
  color: var(--text-primary);
  line-height: 1.2;
  margin-bottom: 0.8rem;
}

.hero-mod-desc {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.65;
  margin-bottom: 1.8rem;
}

/* Featured Price Card (Slide 5 inspiration) */
.featured-price-box {
  background: #0F172A;
  color: #FFFFFF;
  border-radius: var(--radius-lg);
  padding: 2.2rem;
  text-align: center;
  box-shadow: 0 15px 35px rgba(15, 23, 42, 0.25);
  position: relative;
}

.featured-price-tag {
  background: rgba(255, 255, 255, 0.1);
  color: #38BDF8;
  font-size: 0.74rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 0.25rem 0.8rem;
  border-radius: var(--radius-pill);
  display: inline-block;
  margin-bottom: 1rem;
}

.featured-price-value {
  font-size: 3.4rem;
  font-weight: 900;
  line-height: 1;
  color: #FFFFFF;
  margin-bottom: 0.2rem;
}

.featured-price-lbl {
  font-size: 0.82rem;
  color: #94A3B8;
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 1px;
  margin-bottom: 1.5rem;
}

.featured-pills-row {
  display: flex;
  gap: 0.6rem;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.feat-pill {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 0.4rem 0.8rem;
  border-radius: var(--radius-sm);
  font-size: 0.78rem;
  font-weight: 600;
  color: #E2E8F0;
}

/* Clean Feature List */
.bullets-clean {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  margin-bottom: 1.5rem;
  font-size: 0.92rem;
  color: var(--text-primary);
}

.bullets-clean li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.bullets-clean li svg {
  color: var(--color-blue);
  flex-shrink: 0;
}

/* Bundles Grid (Slide 7) */
.bundles-grid-clean {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-bottom: 3.5rem;
}

.bundle-box-clean {
  background: #FFFFFF;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: var(--shadow-card);
  transition: all var(--trans-fast);
  position: relative;
}

.bundle-box-clean:hover {
  transform: translateY(-4px);
  border-color: var(--color-blue);
  box-shadow: var(--shadow-hover);
}

.bundle-box-clean.featured {
  border: 2px solid var(--color-gold);
  box-shadow: 0 10px 30px rgba(217, 119, 6, 0.12);
}

.badge-gold-top {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--color-gold);
  color: #FFFFFF;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 0.25rem 0.9rem;
  border-radius: var(--radius-pill);
}

.bundle-header-clean {
  margin-bottom: 1.2rem;
}

.bundle-tag-clean {
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--text-muted);
}

.bundle-title-clean {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--text-primary);
  margin: 0.2rem 0 0.8rem;
}

.bundle-price-clean {
  font-size: 2.2rem;
  font-weight: 900;
  color: var(--color-navy);
  line-height: 1;
}

.bundle-price-clean span {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
}

/* Compact Add-ons Grid (Slide 6) */
.addons-grid-clean {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.2rem;
  margin-bottom: 3.5rem;
}

.addon-card-clean {
  background: #FFFFFF;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  padding: 1.4rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: var(--shadow-sm);
  transition: all var(--trans-fast);
}

.addon-card-clean:hover {
  border-color: var(--color-blue);
  transform: translateY(-2px);
  box-shadow: var(--shadow-card);
}

.addon-cat-clean {
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: var(--color-gold);
  margin-bottom: 0.3rem;
}

.addon-name-clean {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 0.4rem;
}

.addon-desc-clean {
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 1rem;
}

.addon-price-clean {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--color-navy);
}

.addon-price-clean span {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
}

/* ==========================================================================
   MARKETING TAB (3 CARDS)
   ========================================================================== */
.mktg-grid-clean {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.8rem;
  margin-bottom: 3rem;
}

.mktg-card-clean {
  background: #FFFFFF;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  padding: 2.2rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: var(--shadow-card);
  position: relative;
  transition: all var(--trans-fast);
}

.mktg-card-clean:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
}

.mktg-card-clean.featured {
  border: 2px solid var(--color-gold);
}

.mktg-plan-badge {
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--text-muted);
}

.mktg-plan-title {
  font-size: 1.7rem;
  font-weight: 800;
  color: var(--text-primary);
  margin: 0.2rem 0 1rem;
}

.mktg-plan-price {
  font-size: 2.6rem;
  font-weight: 900;
  color: var(--color-navy);
  line-height: 1;
}

.mktg-plan-period {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 0.2rem 0 1.5rem;
  display: block;
}

.mktg-note-box {
  background: var(--color-blue-soft);
  border: 1px solid var(--color-blue-border);
  border-radius: var(--radius-md);
  padding: 1.2rem 1.5rem;
  font-size: 0.88rem;
  color: var(--color-navy);
  line-height: 1.6;
}

/* ==========================================================================
   FINANZAS: TABLERO DE EJEMPLO
   ========================================================================== */

.kpi-grid-clean {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.2rem;
  margin-bottom: 1.8rem;
}

.kpi-card-clean {
  background: var(--bg-page);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 1.2rem;
}

.kpi-title-clean {
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.3rem;
}

.kpi-val-clean {
  font-size: 1.7rem;
  font-weight: 900;
  color: var(--color-navy);
  line-height: 1.1;
  margin-bottom: 0.2rem;
}

.kpi-sub-clean {
  font-size: 0.74rem;
  color: var(--color-emerald-text);
  font-weight: 700;
}

/* ==========================================================================
   SOPORTE & EXTRAS TAB (3 COLUMNS & GOOGLE DEVICE)
   ========================================================================== */
.support-cols-clean {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

.support-card-clean {
  background: #FFFFFF;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  padding: 1.8rem;
  box-shadow: var(--shadow-sm);
}

.support-head-clean {
  border-bottom: 1px solid var(--border-light);
  padding-bottom: 0.8rem;
  margin-bottom: 1.2rem;
}

.support-tier-clean {
  font-size: 0.74rem;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--color-gold);
}

.support-name-clean {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--text-primary);
}

.support-list-clean {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.support-item-clean {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.88rem;
  color: var(--text-secondary);
}

.support-item-clean strong {
  font-weight: 800;
  color: var(--color-navy);
}

/* Hardware Card Clean */
.hardware-box-clean {
  background: #FFFFFF;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  box-shadow: var(--shadow-card);
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 2.5rem;
  align-items: center;
}

.hardware-card-photo {
  max-width: 320px;
  margin: 0 auto;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-hover);
  border: 1px solid var(--border-card);
}

/* ==========================================================================
   COTIZADOR TAB (SIMPLE & FAST)
   ========================================================================== */
.calc-layout-clean {
  display: grid;
  grid-template-columns: 1.35fr 0.65fr;
  gap: 2.5rem;
  align-items: start;
}

.calc-section-box {
  background: #FFFFFF;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  padding: 2rem;
  margin-bottom: 1.8rem;
  box-shadow: var(--shadow-sm);
}

.calc-section-head {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.2rem;
  border-bottom: 1px solid var(--border-light);
  padding-bottom: 0.8rem;
}

.step-num-pill {
  width: 26px;
  height: 26px;
  border-radius: var(--radius-pill);
  background: var(--color-navy);
  color: #FFFFFF;
  font-size: 0.78rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}

.calc-section-title {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--text-primary);
}

.calc-grid-clean {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.85rem;
}

.calc-option-clean {
  display: block;
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 1rem 1.2rem;
  cursor: pointer;
  position: relative;
  transition: all var(--trans-fast);
}

.calc-option-clean:hover {
  border-color: var(--border-card);
  background: var(--bg-page);
}

.calc-option-clean.selected {
  border: 2px solid var(--color-blue);
  background: #F8FAFC;
}

.calc-opt-radio {
  position: absolute;
  top: 1rem;
  right: 1rem;
  accent-color: var(--color-blue);
}

.calc-opt-name {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 0.2rem;
  padding-right: 1.5rem;
}

.calc-opt-text {
  font-size: 0.78rem;
  color: var(--text-secondary);
  line-height: 1.4;
  margin-bottom: 0.6rem;
}

.calc-opt-price {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--color-navy);
}

/* Sticky Summary Card */
.calc-summary-sticky {
  background: #0F172A;
  color: #FFFFFF;
  border-radius: var(--radius-lg);
  padding: 2.2rem;
  position: sticky;
  top: 6rem;
  box-shadow: 0 15px 35px rgba(15, 23, 42, 0.25);
}

.summary-head-clean {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.6rem;
  margin-bottom: 1rem;
  padding-bottom: 0.8rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.summary-head-clean h4 {
  font-size: 1.3rem;
  font-weight: 800;
  color: #FFFFFF;
}

.summary-count {
  font-size: 0.74rem;
  font-weight: 700;
  color: #94A3B8;
}

.summary-list-clean {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  margin-bottom: 1.5rem;
}

.summary-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.82rem;
  color: #CBD5E1;
}

.summary-row .price-tag {
  color: #FFFFFF;
  font-weight: 700;
}

.summary-totals-box {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding-top: 1.2rem;
  margin-bottom: 1.5rem;
}

.total-line {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}

.total-lbl {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  color: #94A3B8;
}

.total-val {
  font-size: 1.7rem;
  font-weight: 900;
  color: #38BDF8;
}

.total-val.recurring {
  color: #FBBF24;
  font-size: 1.3rem;
}

.total-line {
  gap: 0.75rem;
}

.total-val {
  white-space: nowrap;
}

/* FAQ Clean */
.faq-wrap-clean {
  max-width: 800px;
  margin: 3.5rem auto 0;
}

.faq-card-clean {
  background: #FFFFFF;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  margin-bottom: 0.8rem;
  overflow: hidden;
}

.faq-trigger-clean {
  width: 100%;
  padding: 1.2rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  text-align: left;
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
  background: none;
}

.faq-trigger-clean:hover {
  color: var(--color-blue);
}

.faq-answer-clean {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--trans-smooth), padding var(--trans-fast);
  padding: 0 1.5rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

.faq-card-clean.active .faq-answer-clean {
  max-height: 300px;
  padding: 0 1.5rem 1.2rem;
}

/* ==========================================================================
   FOOTER CLEAN
   ========================================================================== */
.footer-clean {
  background: #0A1120;
  color: #94A3B8;
  padding: 4rem 0 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-grid-clean {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 2.5rem;
  margin-bottom: 3rem;
}

.footer-title-clean {
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #CBD5E1;
  margin-bottom: 1.2rem;
}

.footer-links-clean {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  font-size: 0.86rem;
}

.footer-links-clean a:hover {
  color: #FFFFFF;
}

.footer-bottom-clean {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 1.8rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.8rem;
  flex-wrap: wrap;
  gap: 1rem;
}

/* Modal */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(4px);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--trans-fast);
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.modal-box-clean {
  background: #FFFFFF;
  border-radius: var(--radius-lg);
  max-width: 520px;
  width: 100%;
  padding: 2.2rem;
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.2);
  position: relative;
}

.modal-close-clean {
  position: absolute;
  top: 1.2rem;
  right: 1.2rem;
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  background: var(--bg-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  color: var(--text-muted);
}

.form-group-clean {
  margin-bottom: 1rem;
}

.form-lbl-clean {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.3rem;
}

.form-inp-clean {
  width: 100%;
  padding: 0.75rem 0.9rem;
  background: #FFFFFF;
  border: 1.5px solid var(--border-card);
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 0.9rem;
}

.form-inp-clean:focus {
  outline: none;
  border-color: var(--color-blue);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

[hidden] {
  display: none !important;
}

/* ==========================================================================
   PAQUETES, AHORRO Y MÓDULOS INCLUIDOS
   ========================================================================== */
.pkg-info-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6rem 2rem;
  background: var(--color-blue-soft);
  border: 1px solid var(--color-blue-border);
  border-radius: var(--radius-md);
  padding: 0.85rem 1.2rem;
  margin: 0 auto 2.5rem;
  max-width: 720px;
  font-size: 0.9rem;
  color: var(--text-primary);
  text-align: center;
}

.bundle-desc-clean {
  font-size: 0.86rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-top: 0.8rem;
}

.pkg-savings {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.3rem 0.8rem;
  background: var(--color-emerald-bg);
  border: 1px solid var(--color-emerald-border);
  border-radius: var(--radius-sm);
  padding: 0.6rem 0.85rem;
  margin-bottom: 1.2rem;
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.pkg-savings s {
  color: var(--text-muted);
}

.pkg-savings strong {
  color: #047857;
  font-weight: 800;
}

.pkg-footnote {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.6;
  margin: -2rem auto 3.5rem;
  max-width: 760px;
}

.addon-included-pill {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  color: var(--color-blue);
  background: var(--color-blue-soft);
  border: 1px solid var(--color-blue-border);
  border-radius: var(--radius-pill);
  padding: 0.15rem 0.55rem;
  margin-bottom: 0.5rem;
}

.addon-included-pill.premium {
  color: var(--color-gold-text);
  background: var(--color-gold-bg);
  border-color: var(--color-gold-border);
}

/* Cotizador: chips, módulos incluidos y deshabilitados */
.calc-save-chip {
  display: inline-block;
  margin-top: 0.5rem;
  font-size: 0.72rem;
  font-weight: 800;
  color: #047857;
  background: var(--color-emerald-bg);
  border: 1px solid var(--color-emerald-border);
  border-radius: var(--radius-pill);
  padding: 0.15rem 0.6rem;
}

.calc-opt-price span {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
}

.calc-optional-tag {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--text-secondary);
  background: var(--bg-subtle);
  border-radius: var(--radius-pill);
  padding: 0.1rem 0.5rem;
  margin-left: 0.4rem;
  vertical-align: middle;
}

.calc-step-note {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 0.9rem;
}

.calc-included-tag {
  display: none;
}

.calc-option-clean.included {
  border: 2px solid var(--color-emerald);
  background: var(--color-emerald-bg);
  cursor: default;
}

.calc-option-clean.included .calc-opt-price {
  text-decoration: line-through;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.calc-option-clean.included .calc-included-tag {
  display: inline-block;
  margin-top: 0.4rem;
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  color: #047857;
}

.calc-option-clean.disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.calc-opt-radio:disabled {
  cursor: not-allowed;
}

/* Resumen agrupado: Sitio web / Módulos extra / Cada mes / Finanzas / Dispositivos / Cupón */
.summary-grupo > ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.summary-grupo + .summary-grupo {
  padding-top: 0.75rem;
  border-top: 1px dashed rgba(255, 255, 255, 0.1);
}

.summary-grupo-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.35rem;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #64748B;
}

.summary-editar {
  background: none;
  border: none;
  padding: 0.1rem 0;
  font-family: inherit;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: none;
  color: #38BDF8;
  cursor: pointer;
}

.summary-editar:hover {
  text-decoration: underline;
}

.summary-row {
  gap: 0.75rem;
}

.summary-row .price-tag {
  flex-shrink: 0;
  white-space: nowrap;
}

.summary-incluye details {
  font-size: 0.76rem;
  color: #94A3B8;
}

.summary-incluye summary {
  cursor: pointer;
  color: #34D399;
  font-weight: 700;
  list-style: none;
}

.summary-incluye summary::-webkit-details-marker {
  display: none;
}

.summary-incluye summary::before {
  content: '▸';
  display: inline-block;
  margin-right: 0.35rem;
  transition: transform var(--trans-fast);
}

.summary-incluye details[open] summary::before {
  transform: rotate(90deg);
}

.summary-incluye ul {
  list-style: none;
  margin: 0.4rem 0 0 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.summary-empty {
  font-size: 0.82rem;
  font-style: italic;
  color: #94A3B8;
}

/* Botón "Siguiente" al pie de cada paso del cotizador */
.calc-next-btn {
  display: flex;
  margin: 1.1rem 0 0 auto;
  background: none;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-pill);
  padding: 0.45rem 1rem;
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--color-blue);
  cursor: pointer;
  transition: all var(--trans-fast);
}

.calc-next-btn:hover {
  background: var(--color-blue);
  border-color: var(--color-blue);
  color: #FFFFFF;
}

.calc-section-box,
.calc-summary-sticky {
  scroll-margin-top: 6rem;
}

/* Al llegar a un paso se ilumina un momento para que se note dónde quedaste */
.calc-section-box.paso-llegada {
  animation: pasoLlegada 1.2s ease-out;
}

.calc-summary-sticky.paso-llegada {
  animation: resumenLlegada 1.2s ease-out;
}

@keyframes resumenLlegada {
  0%, 30% { box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.6), 0 15px 35px rgba(15, 23, 42, 0.25); }
  100% { box-shadow: 0 15px 35px rgba(15, 23, 42, 0.25); }
}

@keyframes pasoLlegada {
  0%, 30% { box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.45), var(--shadow-sm); }
  100% { box-shadow: var(--shadow-sm); }
}

/* Escritorio: el resumen te sigue al bajar. La columna se estira a todo el alto
   del cotizador (si mide lo mismo que la tarjeta, sticky no tiene por dónde moverse).
   Si la tarjeta no cabe en la pantalla se desplaza por dentro y los totales y
   botones de pago quedan fijos abajo. */
@media (min-width: 1025px) {
  .calc-summary-col {
    align-self: stretch;
  }
  .calc-summary-sticky {
    max-height: calc(100vh - 7rem);
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
    padding-bottom: 0;
  }
  .summary-footer {
    position: sticky;
    bottom: 0;
    background: #0F172A;
    margin: 0 -2.2rem;
    padding: 0 2.2rem 1.6rem;
    box-shadow: 0 -12px 16px -12px rgba(0, 0, 0, 0.6);
  }
  .calc-pasos-col {
    padding-bottom: var(--espacio-resumen, 0px);
  }
  /* La sugerencia de paquete vive en la parte fija: más compacta para no comerse la lista */
  .summary-footer .upsell-box {
    margin: 0.9rem 0 0.9rem;
    padding: 0.7rem 0.85rem;
    font-size: 0.76rem;
  }
  .summary-footer .btn-upsell {
    margin-top: 0.45rem;
    padding: 0.35rem 0.8rem;
    font-size: 0.76rem;
  }
}

@media (min-width: 1025px) and (max-height: 820px) {
  .savings-phrase {
    display: none;
  }
}

.savings-card {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.22), rgba(16, 185, 129, 0.06));
  border: 1px solid rgba(52, 211, 153, 0.45);
  border-radius: var(--radius-md);
  padding: 1rem 1.1rem;
  margin-bottom: 1.2rem;
}

.savings-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 0.8rem;
  color: #CBD5E1;
  margin-bottom: 0.25rem;
}

.savings-row s {
  color: #94A3B8;
}

.savings-row strong {
  color: #FFFFFF;
}

.savings-amount {
  font-size: 1.15rem;
  white-space: nowrap;
  font-weight: 900;
  color: #34D399;
  margin-top: 0.3rem;
}

.savings-phrase {
  font-size: 0.76rem;
  color: #A7F3D0;
  line-height: 1.45;
  margin-top: 0.35rem;
}

.upsell-box {
  background: rgba(251, 191, 36, 0.1);
  border: 1px dashed rgba(251, 191, 36, 0.55);
  border-radius: var(--radius-md);
  padding: 0.9rem 1rem;
  margin-bottom: 1.2rem;
  font-size: 0.8rem;
  line-height: 1.45;
  color: #FDE68A;
}

.btn-upsell {
  margin-top: 0.6rem;
  background: #FBBF24;
  color: #0F172A;
  font-family: inherit;
  font-size: 0.8rem;
  font-weight: 800;
  border: none;
  border-radius: var(--radius-sm);
  padding: 0.45rem 0.9rem;
  cursor: pointer;
}

.btn-upsell:hover {
  background: #F59E0B;
}

.consumo-note {
  font-size: 0.72rem;
  color: #94A3B8;
  margin: -0.8rem 0 1rem;
}

/* Soporte: cajas fuera de menú y pasarela */
.support-extra-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-bottom: 3.5rem;
}

.support-extra-box {
  background: #FFFFFF;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  padding: 1.8rem;
  box-shadow: var(--shadow-sm);
}

.support-extra-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

.support-extra-text {
  font-size: 0.86rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 0.8rem;
}

.support-extra-price {
  font-size: 1.6rem;
  font-weight: 900;
  color: var(--color-navy);
  margin-bottom: 0.6rem;
}

.support-extra-price span {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
}

.support-extra-warning {
  font-size: 0.8rem;
  color: #B91C1C;
  background: #FEF2F2;
  border: 1px solid #FECACA;
  border-radius: var(--radius-sm);
  padding: 0.55rem 0.75rem;
  line-height: 1.45;
}

.flow-steps {
  list-style: none;
  counter-reset: flow;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.flow-steps li {
  counter-increment: flow;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--color-blue);
  background: var(--color-blue-soft);
  border: 1px solid var(--color-blue-border);
  border-radius: var(--radius-pill);
  padding: 0.3rem 0.75rem;
}

.flow-steps li::before {
  content: counter(flow) ". ";
}

.flow-times {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.2rem;
  font-size: 0.84rem;
  color: var(--text-secondary);
}

.hardware-card-photo img {
  display: block;
  width: 100%;
  height: auto;
}

/* Proceso de Trabajo (4 pasos) */
.steps-grid-clean {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.2rem;
}

/* Responsive */
@media (max-width: 1024px) {
  .hero-module-banner, .hardware-box-clean, .calc-layout-clean {
    grid-template-columns: 1fr;
  }
  .addons-grid-clean, .kpi-grid-clean {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 860px) {
  /* Navbar en dos filas: logo + botón arriba, pestañas abajo */
  .nav-container {
    height: auto;
    flex-wrap: wrap;
    gap: 0.6rem;
    padding-top: 0.6rem;
    padding-bottom: 0.6rem;
  }
  .tab-segmented-control {
    order: 3;
    overflow-x: auto;
    width: 100%;
    scrollbar-width: none;
  }
  .steps-grid-clean {
    grid-template-columns: repeat(2, 1fr);
  }
  .support-extra-grid {
    grid-template-columns: 1fr;
  }
  .three-pillars-grid, .bundles-grid-clean, .mktg-grid-clean, .support-cols-clean {
    grid-template-columns: 1fr;
  }
  .footer-grid-clean {
    grid-template-columns: 1fr 1fr;
  }
  .trust-bar-clean {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }
  .trust-item-clean {
    border-right: none;
  }
}

@media (max-width: 600px) {
  .addons-grid-clean, .kpi-grid-clean, .footer-grid-clean, .trust-bar-clean {
    grid-template-columns: 1fr;
  }
  .top-notice-right {
    display: none;
  }
  .steps-grid-clean {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   MÓVIL: navegación inferior, barra de total y ajustes de legibilidad
   ========================================================================== */
.tab-ico {
  display: none;
}

.calc-mobile-bar {
  display: none;
}

.calc-grid-clean {
  grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr));
}

/* Modal: centrado cuando cabe y desplazable en pantallas bajas (teclado abierto) */
.modal-overlay {
  overflow-y: auto;
  align-items: flex-start;
}

.modal-box-clean {
  margin: auto 0;
}

@media (max-width: 1024px) {
  .calc-mobile-bar.visible {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
    position: fixed;
    left: 0.75rem;
    right: 0.75rem;
    bottom: calc(0.75rem + env(safe-area-inset-bottom));
    z-index: 140;
    background: #0F172A;
    color: #FFFFFF;
    border-radius: var(--radius-md);
    padding: 0.7rem 0.8rem 0.7rem 1rem;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.35);
  }
  .calc-mobile-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
    line-height: 1.2;
  }
  .calc-mobile-lbl {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    color: #CBD5E1;
  }
  .calc-mobile-info strong {
    font-size: 1.15rem;
    font-weight: 900;
    color: #38BDF8;
  }
  .calc-mobile-extra {
    font-size: 0.74rem;
    color: #6EE7B7;
  }
  .calc-mobile-extra:empty {
    display: none;
  }
  .calc-mobile-btn {
    flex-shrink: 0;
    min-height: 44px;
    padding: 0 1rem;
    border: none;
    border-radius: var(--radius-sm);
    background: #FFFFFF;
    color: #0F172A;
    font-family: inherit;
    font-size: 0.85rem;
    font-weight: 800;
    cursor: pointer;
  }
}

@media (max-width: 860px) {
  /* La barra de pestañas pasa a ser una navegación inferior fija con íconos:
     las 5 secciones siempre visibles, sin contenido escondido a la derecha. */
  .navbar {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
  .tab-segmented-control {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 150;
    order: 0;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.15rem;
    width: auto;
    overflow: visible;
    background: rgba(255, 255, 255, 0.98);
    border: none;
    border-top: 1px solid var(--border-light);
    border-radius: 0;
    padding: 0.35rem 0.35rem calc(0.35rem + env(safe-area-inset-bottom));
    box-shadow: 0 -6px 20px rgba(15, 23, 42, 0.08);
  }
  .tab-segmented-control .tab-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.2rem;
    min-height: 52px;
    padding: 0.3rem 0.1rem;
    font-size: 0.72rem;
    font-weight: 600;
    line-height: 1.1;
    white-space: nowrap;
    color: var(--text-secondary);
    background: transparent;
    box-shadow: none;
    border-radius: var(--radius-sm);
  }
  .tab-segmented-control .tab-btn.active {
    color: var(--color-blue);
    background: var(--color-blue-soft);
    box-shadow: none;
    font-weight: 800;
  }
  .tab-ico {
    display: block;
    width: 21px;
    height: 21px;
  }
  .lbl-long {
    display: none;
  }
  body {
    padding-bottom: calc(66px + env(safe-area-inset-bottom));
  }
  .calc-mobile-bar.visible {
    bottom: calc(72px + env(safe-area-inset-bottom));
  }

  /* Botones cómodos para el dedo */
  .btn {
    min-height: 44px;
  }
  .btn-sm {
    min-height: 40px;
  }
  #qty-minus,
  #qty-plus {
    min-width: 40px;
    min-height: 40px;
    font-size: 1.1rem;
  }

  /* Evita el zoom automático de iPhone al escribir */
  .form-inp-clean {
    font-size: 16px;
  }
}

@media (max-width: 600px) {
  .btn {
    white-space: normal;
    text-align: center;
  }
  .container {
    padding: 0 1rem;
  }
  .bundle-box-clean,
  .calc-section-box,
  .hardware-box-clean,
  .support-extra-box {
    padding: 1.4rem;
  }
  .calc-summary-sticky {
    padding: 1.5rem;
  }
  .modal-box-clean {
    padding: 1.6rem 1.3rem;
  }

  /* Tabla de transacciones como tarjetas: nada queda oculto a la derecha */
}

/* ==========================================================================
   ÁREA DE CLIENTES: enlace "Mi cuenta" y barra "Tu propuesta está lista"
   ========================================================================== */
.nav-account-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.86rem;
  font-weight: 700;
  color: var(--text-secondary);
  padding: 0.45rem 0.6rem;
  border-radius: var(--radius-sm);
  white-space: nowrap;
}

.nav-account-link:hover {
  color: var(--color-blue);
}

.nav-account-link svg {
  width: 18px;
  height: 18px;
}

/* Barra fija inferior con texto en carrusel (la crea js/portal/comun.js) */
.proposal-ticker {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 160;
  display: flex;
  align-items: center;
  gap: 1rem;
  height: 54px;
  padding: 0 1rem 0 1.25rem;
  padding-bottom: env(safe-area-inset-bottom);
  background: linear-gradient(90deg, #0F172A 0%, #1E3A8A 100%);
  color: #FFFFFF;
  box-shadow: 0 -8px 24px rgba(15, 23, 42, 0.25);
  overflow: hidden;
}

.ticker-badge {
  flex-shrink: 0;
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: var(--color-gold-bg);
  color: var(--color-gold-text);
  padding: 0.3rem 0.7rem;
  border-radius: var(--radius-pill);
}

.ticker-track {
  flex: 1;
  min-width: 0;
  display: flex;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
}

/* Dos copias idénticas que se desplazan juntas: el ciclo no tiene saltos */
.ticker-run {
  display: flex;
  flex-shrink: 0;
  animation: ticker-scroll 26s linear infinite;
}

.ticker-item {
  white-space: nowrap;
  font-size: 0.95rem;
  font-weight: 600;
  padding-right: 2.2rem;
}

.ticker-item::before {
  content: '●';
  color: #FBBF24;
  font-size: 0.55rem;
  vertical-align: middle;
  margin-right: 2.2rem;
}

.ticker-cta {
  flex-shrink: 0;
  background: #FFFFFF;
  color: #0F172A;
  font-size: 0.85rem;
  font-weight: 800;
  padding: 0.55rem 0.95rem;
  border-radius: var(--radius-sm);
  white-space: nowrap;
}

.proposal-ticker:hover .ticker-run,
.proposal-ticker:focus-visible .ticker-run {
  animation-play-state: paused;
}

.proposal-ticker:focus-visible {
  outline: 3px solid #FBBF24;
  outline-offset: -3px;
}

body.has-ticker {
  padding-bottom: 54px;
}

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

@media (prefers-reduced-motion: reduce) {
  .ticker-run {
    animation: none;
  }
  .ticker-run + .ticker-run {
    display: none;
  }
}

@media (max-width: 860px) {
  .nav-account-link span {
    display: none;
  }
  .nav-account-link svg {
    width: 22px;
    height: 22px;
  }

  /* En móvil la barra se apoya justo encima de la navegación inferior */
  .proposal-ticker {
    bottom: calc(66px + env(safe-area-inset-bottom));
    height: 46px;
    padding: 0 0.6rem 0 0.8rem;
    gap: 0.6rem;
  }
  .ticker-badge {
    font-size: 0;
    padding: 0.3rem 0.45rem;
  }
  .ticker-badge::before {
    content: '📄';
    font-size: 0.9rem;
  }
  .ticker-item {
    font-size: 0.86rem;
  }
  .ticker-cta {
    font-size: 0.78rem;
    padding: 0.45rem 0.7rem;
  }
  body.has-ticker {
    padding-bottom: calc(66px + 46px + env(safe-area-inset-bottom));
  }
  /* En el cotizador manda la barra del total */
  .calc-mobile-bar.visible ~ .proposal-ticker {
    display: none;
  }

  /* Área de clientes: no hay navegación inferior */
  body.portal .proposal-ticker {
    bottom: 0;
    height: calc(52px + env(safe-area-inset-bottom));
    padding-bottom: env(safe-area-inset-bottom);
  }
  body.portal.has-ticker {
    padding-bottom: calc(52px + env(safe-area-inset-bottom));
  }
}

/* Barra superior en celular: logo, "Mi cuenta" y "Cotizar" en un solo renglón */
@media (max-width: 600px) {
  .navbar .brand-logo-img {
    height: 30px;
  }
  .nav-container > div[style] {
    gap: 0.35rem !important;
  }
  .nav-account-link {
    padding: 0.35rem;
  }
  .nav-container .btn-sm {
    padding: 0.5rem 0.8rem;
    font-size: 0.8rem;
  }
}

@media (max-width: 380px) {
  .navbar .brand-logo-img {
    height: 25px;
  }
  .nav-container .btn-sm {
    padding: 0.5rem 0.65rem;
  }
}

/* ==========================================================================
   INICIO SIMPLE + ANIMACIONES DE ENTRADA
   ========================================================================== */

/* Título que entra palabra por palabra (solo CSS: no depende de JavaScript) */
.hero-palabras {
  font-size: clamp(2rem, 8.4vw, 3.8rem);
}

.hero-palabras .w {
  display: inline-block;
  color: inherit;
  animation: subir-palabra 0.8s cubic-bezier(0.16, 1, 0.3, 1) both;
  animation-delay: calc(var(--i) * 80ms + 100ms);
}

/* Frase destacada: azul con un subrayado de marcador que se dibuja al final */
.hero-destacado .w {
  position: relative;
  z-index: 0;
  color: var(--color-blue);
}

.hero-destacado .w::after {
  content: '';
  position: absolute;
  left: -0.04em;
  right: -0.04em;
  bottom: 0.1em;
  height: 0.26em;
  z-index: -1;
  border-radius: 0.12em;
  background: rgba(37, 99, 235, 0.16);
  transform: scaleX(0);
  transform-origin: left center;
  animation: marcar 0.7s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  animation-delay: calc(var(--i) * 90ms + 750ms);
}

/* Subtítulo, botones y franja de confianza entran en cascada después del título */
.entra {
  animation: aparecer 0.8s cubic-bezier(0.16, 1, 0.3, 1) both;
  animation-delay: calc(var(--d) * 80ms + 100ms);
}

@keyframes subir-palabra {
  /* Solo opacidad y movimiento: un desenfoque animado traba los celulares */
  from { opacity: 0; transform: translateY(0.55em); }
  to { opacity: 1; transform: none; }
}

@keyframes aparecer {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}

@keyframes marcar {
  to { transform: scaleX(1); }
}

/* Aparición suave al bajar (la clase la pone js/app.js → initRevelar) */
[data-revelar].por-revelar {
  opacity: 0;
  transform: translateY(26px);
}

[data-revelar].por-revelar.revelado {
  opacity: 1;
  transform: none;
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
  transition-delay: calc(var(--i, 0) * 90ms);
}

/* Tres ventajas bajo los botones del inicio */
.ventajas {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  max-width: 820px;
  margin: 0 auto;
  text-align: left;
}

.ventaja {
  border-radius: 18px;
  padding: 1.4rem 1.2rem;
}

.ventaja-azul { background: #E0ECFF; }
.ventaja-verde { background: #DCFCE7; }
.ventaja-oro { background: #FEF3C7; }

.ventaja-emoji {
  font-size: 2rem;
  line-height: 1;
}

.ventaja-tit {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-primary);
  margin: 0.6rem 0 0.3rem;
}

.ventaja-txt {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.45;
  margin: 0;
}

/* ¿Qué necesitas? */
.seccion-servicios {
  scroll-margin-top: 5.5rem;
}

.servicio-card:focus-visible {
  outline: 3px solid var(--color-blue);
  outline-offset: 3px;
}

.servicio-precio {
  font-size: 1.75rem;
  font-weight: 900;
  color: var(--color-navy);
  line-height: 1.1;
  margin: 1.3rem 0 0.9rem;
}

.servicio-precio span {
  display: block;
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: 0.2rem;
}

.servicio-precio small {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
}

.servicio-gold .pillar-icon-svg { background: #FEF3C7; color: #D97706; }
.servicio-gold .pillar-action-link { color: var(--color-gold); }
.servicio-gold:hover { border-color: var(--color-gold); }
.servicio-verde .pillar-icon-svg { background: #ECFDF5; color: #10B981; }
.servicio-verde .pillar-action-link { color: var(--color-emerald-text); }
.servicio-verde:hover { border-color: var(--color-emerald); }

/* Así de fácil */
.seccion-blanca {
  background: #FFFFFF;
  border-top: 1px solid var(--border-light);
  border-bottom: 1px solid var(--border-light);
}

.pasos-simples {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.2rem;
}

.pasos-simples li {
  background: var(--bg-page);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  padding: 1.5rem;
}

.paso-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 50%;
  background: var(--color-navy);
  color: #FFFFFF;
  font-weight: 900;
  margin-bottom: 0.8rem;
}

.pasos-simples h3 {
  font-size: 1.02rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 0.3rem;
}

.pasos-simples p {
  font-size: 0.88rem;
  color: var(--text-secondary);
}

.pasos-pago {
  text-align: center;
  margin-top: 1.8rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.pasos-pago strong {
  color: var(--text-primary);
}

/* Cierre */
.cta-final {
  background: linear-gradient(135deg, #0F172A 0%, #1E3A8A 100%);
  color: #FFFFFF;
  border-radius: var(--radius-lg);
  padding: 3rem 2rem;
  text-align: center;
  box-shadow: var(--shadow-hover);
}

.cta-final h2 {
  font-size: clamp(1.7rem, 3.5vw, 2.4rem);
  font-weight: 900;
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
}

.cta-final p {
  color: #CBD5E1;
  margin-bottom: 1.8rem;
}

.cta-final .hero-btn-row {
  margin-bottom: 0;
}

.cta-final .btn-primary {
  background: #FFFFFF;
  color: var(--color-navy);
  border-color: #FFFFFF;
}

/* Paquetes: 3 beneficios simples + "Ver todo lo que incluye" */
.beneficios {
  list-style: none;
  display: grid;
  gap: 0.55rem;
  margin: 1.1rem 0 1rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
}

.beneficios li {
  position: relative;
  padding-left: 1.7rem;
}

.beneficios li::before {
  content: '✓';
  position: absolute;
  left: 0;
  top: 0.1em;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 1.2rem;
  height: 1.2rem;
  border-radius: 50%;
  background: var(--color-emerald-bg);
  color: var(--color-emerald-text);
  font-size: 0.72rem;
  font-weight: 900;
}

.pkg-detalle {
  border-top: 1px dashed var(--border-card);
  padding-top: 0.7rem;
  margin-bottom: 1.2rem;
}

.pkg-detalle summary {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  cursor: pointer;
  list-style: none;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--color-blue);
  min-height: 32px;
}

.pkg-detalle summary::-webkit-details-marker {
  display: none;
}

.pkg-detalle summary::after {
  content: '▾';
  transition: transform var(--trans-fast);
}

.pkg-detalle[open] summary::after {
  transform: rotate(180deg);
}

.pkg-detalle .bullets-clean {
  margin-top: 0.6rem;
}

/* Finanzas: tablero de ejemplo, fijo y simple */
.tablero-ejemplo {
  position: relative;
  background: #FFFFFF;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  padding: 2.6rem 1.5rem 1.5rem;
  box-shadow: var(--shadow-card);
}

.tablero-aviso {
  position: absolute;
  top: 0.9rem;
  right: 1rem;
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  background: var(--bg-subtle);
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-pill);
}

.tablero-3 {
  grid-template-columns: repeat(3, 1fr);
  margin-bottom: 0;
}

@media (max-width: 860px) {
  .pasos-simples {
    grid-template-columns: repeat(2, 1fr);
  }
  .tablero-3 {
    grid-template-columns: 1fr;
  }
  .ventajas {
    grid-template-columns: 1fr;
    gap: 0.7rem;
    max-width: 480px;
  }
  .ventaja {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    padding: 1rem 1.1rem;
  }
  .ventaja-emoji {
    font-size: 1.7rem;
  }
  .ventaja-tit {
    font-size: 1rem;
    margin: 0 0 0.15rem;
  }
}

@media (max-width: 600px) {
  .pasos-simples {
    grid-template-columns: 1fr;
  }
  .cta-final {
    padding: 2.2rem 1.3rem;
  }
  .servicio-precio {
    font-size: 1.55rem;
  }
}

/* Sin animaciones para quien lo pidió en su sistema: todo visible de inmediato */
@media (prefers-reduced-motion: reduce) {
  .hero-palabras .w,
  .entra {
    animation: none;
  }
  .hero-destacado .w::after {
    animation: none;
    transform: scaleX(1);
  }
  [data-revelar].por-revelar {
    opacity: 1;
    transform: none;
  }
}

/* Solo para lectores de pantalla */
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ==========================================================================
   COTIZADOR: CUPÓN Y BOTONES DE PAGO (tarjeta oscura del resumen)
   ========================================================================== */
.summary-row.descuento {
  color: #6EE7B7;
}

.summary-row.descuento .price-tag {
  color: #34D399;
}

.calc-cupon {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding-top: 1.1rem;
  margin-bottom: 1.3rem;
}

.calc-cupon-lbl {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
  color: #CBD5E1;
  margin-bottom: 0.5rem;
}

.calc-cupon-row {
  display: flex;
  gap: 0.5rem;
}

.calc-cupon.con-cupon .calc-cupon-toggle,
.calc-cupon.con-cupon .calc-cupon-row,
.calc-cupon-row[hidden] {
  display: none;
}

.calc-cupon-toggle {
  background: none;
  border: none;
  padding: 0;
  margin-bottom: 0.5rem;
  font-family: inherit;
  font-size: 0.8rem;
  font-weight: 700;
  color: #CBD5E1;
  text-decoration: underline dotted;
  text-underline-offset: 3px;
  cursor: pointer;
}

.calc-cupon-input {
  flex: 1;
  width: 0; /* sin esto el campo no se encoge y ensancha la tarjeta en pantallas angostas */
  min-width: 0;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-sm);
  color: #FFFFFF;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.65rem 0.8rem;
}

.calc-cupon-input::placeholder {
  color: #64748B;
  font-weight: 500;
  letter-spacing: normal;
  text-transform: none;
}

.calc-cupon-input:focus {
  outline: 2px solid #38BDF8;
  outline-offset: 1px;
  border-color: transparent;
}

.calc-cupon-btn {
  flex-shrink: 0;
  background: #FFFFFF;
  color: var(--color-navy);
  border: none;
  border-radius: var(--radius-sm);
  font: inherit;
  font-size: 0.85rem;
  font-weight: 800;
  padding: 0 1rem;
  cursor: pointer;
  transition: background var(--trans-fast);
}

.calc-cupon-btn:hover {
  background: #E2E8F0;
}

.calc-cupon-btn:disabled {
  opacity: 0.6;
  cursor: wait;
}

.calc-cupon-activo {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  background: rgba(16, 185, 129, 0.14);
  border: 1px dashed rgba(52, 211, 153, 0.6);
  border-radius: var(--radius-sm);
  padding: 0.6rem 0.8rem;
}

.calc-cupon-activo[hidden] {
  display: none;
}

.calc-cupon-chip {
  font-size: 0.82rem;
  font-weight: 700;
  color: #A7F3D0;
  overflow-wrap: anywhere;
}

.calc-cupon-chip::before {
  content: '🏷️ ';
}

.calc-cupon-quitar {
  flex-shrink: 0;
  background: none;
  border: none;
  color: #CBD5E1;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  text-decoration: underline;
  cursor: pointer;
  padding: 0.2rem;
}

.calc-cupon-msg {
  font-size: 0.78rem;
  margin-top: 0.5rem;
  color: #94A3B8;
}

.calc-cupon-msg:empty {
  display: none;
}

.calc-cupon-msg[data-tipo="error"] { color: #FCA5A5; }
.calc-cupon-msg[data-tipo="ok"] { color: #6EE7B7; }
.calc-cupon-msg[data-tipo="nota"] { color: #FDE68A; }

.calc-acciones {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

.calc-pagar-btn,
.calc-asesor-btn {
  width: 100%;
  padding: 0.9rem 1rem;
  font-size: 1rem;
}

.calc-pagar-btn {
  font-weight: 800;
  color: var(--color-navy);
  background: linear-gradient(135deg, #FBBF24 0%, #F59E0B 100%);
  border: none;
  box-shadow: 0 10px 24px -10px rgba(245, 158, 11, 0.8);
}

.calc-pagar-btn:hover:not(:disabled) {
  color: var(--color-navy);
  transform: translateY(-1px);
  box-shadow: 0 14px 28px -10px rgba(245, 158, 11, 0.9);
}

.calc-pagar-btn:disabled {
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.5);
  box-shadow: none;
  cursor: not-allowed;
}

.calc-pago-msg {
  font-size: 0.8rem;
  line-height: 1.5;
  color: #FDE68A;
  background: rgba(251, 191, 36, 0.1);
  border: 1px solid rgba(251, 191, 36, 0.3);
  border-radius: var(--radius-sm);
  padding: 0.6rem 0.8rem;
}

.calc-pago-msg[data-tipo="ok"] {
  color: #A7F3D0;
  background: rgba(16, 185, 129, 0.12);
  border-color: rgba(16, 185, 129, 0.4);
}

.calc-pago-msg a {
  color: inherit;
  font-weight: 700;
  text-decoration: underline;
}

/* Pagar todo o anticipo del 50% */
.calc-anticipo {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  border: 0;
  padding: 0;
  margin: 0;
}

.calc-anticipo[hidden] { display: none; }

.calc-anticipo-opc {
  position: relative;
  cursor: pointer;
}

.calc-anticipo-opc input {
  position: absolute;
  opacity: 0;
}

.calc-anticipo-opc span {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  height: 100%;
  padding: 0.55rem 0.7rem;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-sm);
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.85rem;
  transition: border-color 0.2s, background 0.2s;
}

.calc-anticipo-opc small {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.6);
}

.calc-anticipo-opc .calc-anticipo-hoy {
  font-size: 0.8rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.85);
}

/* Desglose de cada opción: proyecto, 1er mes y lo que queda pendiente */
.calc-anticipo-opc .calc-anticipo-det {
  display: flex;
  flex-direction: column;
  margin-top: 0.2rem;
  padding: 0;
  border: 0;
  font-size: 0.7rem;
  line-height: 1.35;
  color: rgba(255, 255, 255, 0.55);
}

.calc-anticipo-opc .calc-anticipo-det span {
  display: block;
  padding: 0;
  border: 0;
  font-size: inherit;
  color: inherit;
}

.calc-anticipo-opc .calc-anticipo-det .resto {
  color: #FDE68A;
}

.calc-anticipo-nota {
  margin: -0.2rem 0 0;
  font-size: 0.7rem;
  line-height: 1.4;
  color: #94A3B8;
}

.calc-anticipo-opc input:checked + span {
  border-color: #FBBF24;
  background: rgba(251, 191, 36, 0.12);
  color: #fff;
}

.calc-anticipo-opc input:focus-visible + span {
  outline: 2px solid #FBBF24;
  outline-offset: 2px;
}

/* ==========================================================================
   ASISTENTE DE PREGUNTAS FRECUENTES (js/bot.js)
   Fijo abajo a la derecha; --bot-offset lo calcula el JS para no tapar la
   navegación inferior del celular ni las barras fijas.
   ========================================================================== */
.apex-bot {
  --bot-offset: 0px;
  --bot-margen: 20px;
  position: fixed;
  right: var(--bot-margen);
  bottom: calc(var(--bot-offset) + var(--bot-margen));
  z-index: 180;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.75rem;
  pointer-events: none;
  font-family: var(--font-main);
}

.apex-bot > * {
  pointer-events: auto;
}

.bot-lanzador {
  position: relative;
  width: 62px;
  height: 62px;
  border-radius: 50%;
  border: none;
  display: grid;
  place-items: center;
  color: #FFFFFF;
  background: linear-gradient(135deg, #1E3A8A 0%, #0F172A 100%);
  box-shadow: 0 12px 28px -6px rgba(15, 23, 42, 0.55);
  cursor: pointer;
  transition: transform var(--trans-smooth), box-shadow var(--trans-smooth);
}

.bot-lanzador:hover {
  transform: translateY(-2px) scale(1.04);
}

.bot-lanzador:focus-visible {
  outline: 3px solid #38BDF8;
  outline-offset: 4px;
}

.bot-lanzador svg {
  grid-area: 1 / 1;
  transition: opacity 0.2s ease, transform 0.25s ease;
}

.bot-ico-cerrar {
  opacity: 0;
  transform: rotate(-90deg);
}

.apex-bot.abierto .bot-ico-chat {
  opacity: 0;
  transform: rotate(90deg);
}

.apex-bot.abierto .bot-ico-cerrar {
  opacity: 1;
  transform: none;
}

/* Punto "en línea": en la esquina del botón, con un pulso suave */
.bot-en-linea {
  position: absolute;
  top: -1px;
  right: -1px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #22C55E;
  border: 3px solid #FFFFFF;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.3);
}

.bot-en-linea::after {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  border: 2px solid #22C55E;
  animation: bot-pulso 2.4s ease-out infinite;
}

@keyframes bot-pulso {
  0% { transform: scale(1); opacity: 0.7; }
  70%, 100% { transform: scale(1.9); opacity: 0; }
}

.apex-bot.abierto .bot-en-linea {
  display: none;
}

/* Mini salto de bienvenida */
.bot-lanzador.saltando {
  animation: bot-salto 0.9s cubic-bezier(0.28, 0.84, 0.42, 1);
}

@keyframes bot-salto {
  0% { transform: translateY(0) scale(1, 1); }
  18% { transform: translateY(0) scale(1.12, 0.88); }
  42% { transform: translateY(-22px) scale(0.94, 1.08); }
  62% { transform: translateY(0) scale(1.08, 0.92); }
  76% { transform: translateY(-6px) scale(0.98, 1.02); }
  100% { transform: translateY(0) scale(1, 1); }
}

/* Burbuja "¡Hola! ¿Te ayudo?" */
.bot-burbuja {
  position: relative;
  max-width: 220px;
  background: #FFFFFF;
  color: var(--text-primary);
  font-size: 0.92rem;
  font-weight: 700;
  padding: 0.7rem 1rem;
  border-radius: 16px;
  box-shadow: 0 12px 30px -8px rgba(15, 23, 42, 0.3);
  border: 1px solid var(--border-light);
  margin-right: 4px;
  white-space: nowrap;
  cursor: pointer;
  opacity: 0;
  transform: translateY(8px) scale(0.9);
  transform-origin: bottom right;
  visibility: hidden;
  transition: opacity 0.3s ease, transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.3s;
}

/* Colita que apunta al centro del botón */
.bot-burbuja::after {
  content: '';
  position: absolute;
  right: 22px;
  bottom: -7px;
  width: 14px;
  height: 14px;
  background: #FFFFFF;
  border-right: 1px solid var(--border-light);
  border-bottom: 1px solid var(--border-light);
  border-bottom-right-radius: 3px;
  transform: rotate(45deg);
}

.bot-burbuja.visible {
  opacity: 1;
  transform: none;
  visibility: visible;
}

.apex-bot.abierto .bot-burbuja {
  display: none;
}

/* Panel */
.bot-panel {
  width: min(370px, calc(100vw - 2 * var(--bot-margen)));
  height: min(560px, calc(100vh - var(--bot-offset) - 150px));
  height: min(560px, calc(100dvh - var(--bot-offset) - 150px));
  display: flex;
  flex-direction: column;
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: 20px;
  box-shadow: 0 24px 60px -12px rgba(15, 23, 42, 0.35);
  overflow: hidden;
  transform-origin: bottom right;
  animation: bot-abrir 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.bot-panel[hidden] {
  display: none;
}

@keyframes bot-abrir {
  from { opacity: 0; transform: translateY(12px) scale(0.96); }
  to { opacity: 1; transform: none; }
}

.bot-head {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.9rem 0.9rem 0.9rem 1.1rem;
  color: #FFFFFF;
  background: linear-gradient(135deg, #0F172A 0%, #1E3A8A 100%);
}

.bot-head img {
  flex-shrink: 0;
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.3));
}

.bot-head div {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}

.bot-head strong {
  font-size: 1rem;
}

.bot-head span {
  font-size: 0.76rem;
  color: #BFDBFE;
}

.bot-punto {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22C55E;
  margin-right: 0.25rem;
  vertical-align: 1px;
}

.bot-cerrar {
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  color: #FFFFFF;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}

.bot-cerrar:hover {
  background: rgba(255, 255, 255, 0.2);
}

.bot-mensajes {
  flex: 1;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  background: var(--bg-page);
}

.bot-mensajes:focus {
  outline: none;
}

.bot-msg {
  max-width: 88%;
  font-size: 0.88rem;
  line-height: 1.5;
  padding: 0.65rem 0.85rem;
  border-radius: 14px;
  overflow-wrap: anywhere;
  animation: bot-msg 0.25s ease both;
}

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

.bot-msg.bot {
  align-self: flex-start;
  background: #FFFFFF;
  color: var(--text-primary);
  border: 1px solid var(--border-light);
  border-bottom-left-radius: 4px;
}

.bot-msg.usuario {
  align-self: flex-end;
  background: var(--color-blue);
  color: #FFFFFF;
  border-bottom-right-radius: 4px;
}

.bot-msg ul {
  margin: 0.4rem 0;
  padding-left: 0;
  list-style: none;
}

.bot-msg li {
  margin: 0.2rem 0;
}

.bot-msg small {
  color: var(--text-muted);
  font-size: 0.76rem;
}

.bot-acciones {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.6rem;
}

.bot-accion {
  display: inline-block;
  font: inherit;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--color-blue);
  background: var(--color-blue-soft);
  border: 1px solid var(--color-blue-border);
  border-radius: var(--radius-pill);
  padding: 0.4rem 0.8rem;
  text-decoration: none;
  cursor: pointer;
}

.bot-accion:hover {
  background: #DBEAFE;
}

.bot-accion.whatsapp {
  color: #FFFFFF;
  background: #047857;
  border-color: #047857;
}

.bot-accion.whatsapp:hover {
  background: #065F46;
}

/* Tres puntos de "escribiendo…" */
.bot-escribiendo {
  display: flex;
  gap: 4px;
  padding: 0.8rem 0.9rem;
}

.bot-escribiendo span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #94A3B8;
  animation: bot-punto 1s ease-in-out infinite;
}

.bot-escribiendo span:nth-child(2) { animation-delay: 0.15s; }
.bot-escribiendo span:nth-child(3) { animation-delay: 0.3s; }

@keyframes bot-punto {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.5; }
  30% { transform: translateY(-4px); opacity: 1; }
}

/* Preguntas para tocar */
.bot-chips {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.4rem;
  margin-top: 0.2rem;
}

.bot-chips-titulo {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.bot-chip {
  max-width: 92%;
  text-align: right;
  font: inherit;
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--color-blue);
  background: #FFFFFF;
  border: 1.5px solid var(--color-blue-border);
  border-radius: 14px;
  padding: 0.5rem 0.8rem;
  cursor: pointer;
  transition: background var(--trans-fast), border-color var(--trans-fast);
}

.bot-chip:hover {
  background: var(--color-blue-soft);
  border-color: var(--color-blue);
}

.bot-chip-mas {
  color: var(--text-secondary);
  border-style: dashed;
  border-color: var(--border-light);
}

.bot-form {
  display: flex;
  gap: 0.5rem;
  padding: 0.7rem;
  border-top: 1px solid var(--border-light);
  background: #FFFFFF;
}

.bot-input {
  flex: 1;
  min-width: 0;
  font: inherit;
  font-size: 16px; /* 16px evita que el iPhone haga zoom al escribir */
  border: 1px solid var(--border-light);
  border-radius: var(--radius-pill);
  padding: 0.6rem 1rem;
  background: var(--bg-page);
  color: var(--text-primary);
}

.bot-input:focus {
  outline: 2px solid var(--color-blue);
  outline-offset: 0;
  background: #FFFFFF;
}

.bot-enviar {
  flex-shrink: 0;
  width: 42px;
  height: 42px;
  border: none;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #FFFFFF;
  background: var(--color-blue);
  cursor: pointer;
}

.bot-enviar:hover {
  background: #1D4ED8;
}

@media (max-width: 600px) {
  .apex-bot {
    --bot-margen: 14px;
  }
  .bot-lanzador {
    width: 56px;
    height: 56px;
  }
  .bot-burbuja::after {
    right: 19px;
  }
  .bot-panel {
    width: calc(100vw - 2 * var(--bot-margen));
  }
}

@media (prefers-reduced-motion: reduce) {
  .bot-lanzador.saltando,
  .bot-en-linea::after,
  .bot-panel,
  .bot-msg,
  .bot-escribiendo span {
    animation: none;
  }
  .bot-burbuja,
  .bot-lanzador,
  .bot-lanzador svg {
    transition: none;
  }
}

/* Asistente: sugerencias compactas, planes y lista de todas las preguntas
   ========================================================================== */
.bot-panel {
  position: relative;
}

.bot-chips.compactas {
  flex-direction: row;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 0.35rem;
  margin-top: 0;
}

.bot-chips.compactas .bot-chips-titulo {
  width: 100%;
  margin-bottom: 0.1rem;
}

.bot-chips.compactas .bot-chip {
  max-width: 100%;
  text-align: left;
  font-size: 0.78rem;
  padding: 0.35rem 0.7rem;
  border-radius: var(--radius-pill);
  border-width: 1px;
}

.bot-lista {
  margin: 0.45rem 0 0.55rem;
}

.bot-msg .bot-lista li {
  margin: 0.15rem 0;
}

.bot-lista-titulo {
  font-weight: 700;
  color: var(--text-secondary);
}

.bot-cobro {
  font-size: 0.74rem;
  color: var(--text-muted);
  white-space: nowrap;
}

.bot-plan {
  margin-top: 0.55rem;
  padding: 0.55rem 0.7rem;
  border-radius: 10px;
  background: var(--bg-page);
  border: 1px solid var(--border-light);
}

.bot-plan.recomendado {
  border-color: var(--color-gold-border);
  background: #FFFBEB;
}

.bot-plan .bot-lista {
  margin: 0.3rem 0 0;
  font-size: 0.82rem;
}

.bot-etiqueta {
  display: inline-block;
  font-size: 0.66rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-gold-text);
  background: var(--color-gold-bg);
  border-radius: var(--radius-pill);
  padding: 0.05rem 0.45rem;
  vertical-align: 1px;
}

.bot-parte {
  margin-bottom: 0.2rem;
  color: var(--color-blue);
}

.bot-separador {
  border: none;
  border-top: 1px dashed var(--border-light);
  margin: 0.7rem 0;
}

/* Botón de "todas las preguntas" junto al campo */
.bot-menu {
  flex-shrink: 0;
  width: 42px;
  height: 42px;
  border: 1px solid var(--border-light);
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--color-navy);
  background: #FFFFFF;
  cursor: pointer;
}

.bot-menu:hover,
.bot-menu[aria-expanded="true"] {
  background: var(--color-blue-soft);
  border-color: var(--color-blue-border);
  color: var(--color-blue);
}

/* Lista de todas las preguntas: se abre encima de la conversación */
.bot-hoja {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  top: 64px;
  display: flex;
  flex-direction: column;
  background: #FFFFFF;
  z-index: 2;
  animation: bot-hoja 0.22s ease both;
}

.bot-hoja[hidden] {
  display: none;
}

@keyframes bot-hoja {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}

.bot-hoja-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.8rem 0.9rem 0.6rem 1.1rem;
  border-bottom: 1px solid var(--border-light);
}

.bot-hoja-head strong {
  font-size: 0.95rem;
  color: var(--text-primary);
}

.bot-hoja-cerrar {
  width: 34px;
  height: 34px;
  border: none;
  border-radius: 50%;
  background: var(--bg-subtle);
  color: var(--text-secondary);
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
}

.bot-hoja-lista {
  flex: 1;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 0.4rem 0.8rem 1rem;
}

.bot-hoja-grupo {
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin: 0.8rem 0.3rem 0.35rem;
}

.bot-hoja-item {
  display: block;
  width: 100%;
  text-align: left;
  font: inherit;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--text-primary);
  background: none;
  border: none;
  border-radius: 10px;
  padding: 0.55rem 0.6rem;
  cursor: pointer;
}

.bot-hoja-item:hover,
.bot-hoja-item:focus-visible {
  background: var(--color-blue-soft);
  color: var(--color-blue);
}

@media (prefers-reduced-motion: reduce) {
  .bot-hoja {
    animation: none;
  }
}

/* Asistente: pasos numerados y sugerencias armadas (giro, presupuesto) */
.bot-msg .bot-pasos {
  margin: 0.45rem 0 0.2rem;
  padding-left: 1.2rem;
  list-style: decimal;
}

.bot-msg .bot-pasos li {
  margin: 0.3rem 0;
}

.bot-msg .bot-sugerido li {
  margin: 0.5rem 0;
  padding: 0.45rem 0.6rem;
  border-radius: 10px;
  background: var(--bg-page);
  border: 1px solid var(--border-light);
}

.bot-msg .bot-sugerido small {
  display: block;
  margin-top: 0.15rem;
  line-height: 1.4;
}

/* ==========================================================================
   INICIO QUE CUENTA UNA HISTORIA
   Celular de ejemplo (sticky en computadora) + 3 pasos: giro → nombre → su
   página. El contenido del celular lo pinta js/historia.js.
   ========================================================================== */
.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;
}

.historia {
  padding: 3.5rem 0 4.5rem;
  text-align: left;
  background: linear-gradient(180deg, #FFFFFF 0%, #F1F6FF 100%);
}

.historia-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  grid-template-areas:
    "texto cel"
    "pasos cel";
  column-gap: 3.5rem;
  align-items: start;
}

.historia-texto {
  grid-area: texto;
  padding-top: 1.5rem;
}

.historia .hero-palabras {
  font-size: clamp(2.1rem, 4.2vw, 3.4rem);
  text-align: left;
  max-width: none;
  margin: 0 0 1.2rem;
}

.historia .hero-sub-punchy {
  margin: 0 0 2rem;
  max-width: 560px;
}

.historia .hero-btn-row {
  justify-content: flex-start;
  margin-bottom: 3rem;
}

/* ---- El celular ---- */
.cel-zona {
  grid-area: cel;
  position: sticky;
  top: 6.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 1rem;
}

.cel-zona::before {
  content: '';
  position: absolute;
  z-index: 0;
  width: 340px;
  height: 340px;
  top: 45%;
  left: 50%;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: radial-gradient(circle, var(--cel-suave, #BFDBFE) 0%, transparent 70%);
  transition: background 0.6s;
}

.cel {
  position: relative;
  z-index: 1;
  width: 270px;
  height: 540px;
  padding: 11px;
  background: #0F172A;
  border-radius: 42px;
  box-shadow: 0 34px 70px -10px rgba(15, 23, 42, 0.35), inset 0 0 0 2px #334155;
  animation: cel-flotar 6s ease-in-out infinite;
  will-change: transform;
}

.cel::before {
  content: '';
  position: absolute;
  z-index: 3;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  width: 78px;
  height: 20px;
  border-radius: 12px;
  background: #0F172A;
}

.cel-pantalla {
  --cel-color: #C2410C;
  --cel-suave: #FFEDD5;
  position: relative;
  height: 100%;
  overflow: hidden;
  border-radius: 32px;
  background: #F8FAFC;
}

.cel-sitio {
  display: flex;
  flex-direction: column;
  height: 100%;
  transition: opacity 0.45s ease, transform 0.45s ease;
}

.cel-sitio.cambiando {
  opacity: 0;
  transform: translateY(12px) scale(0.98);
}

.cel-top {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 2.6rem 1.1rem 0.7rem;
  background: var(--cel-color);
  color: #FFFFFF;
  font-weight: 800;
  font-size: 0.9rem;
  transition: background 0.4s;
}

.cel-logo {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.25);
  font-size: 0.95rem;
}

.cel-nombre {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cel-banner {
  padding: 0.3rem 1.1rem 1.3rem;
  background: var(--cel-color);
  color: #FFFFFF;
  border-radius: 0 0 22px 22px;
  transition: background 0.4s;
}

.cel-banner b {
  display: block;
  font-size: 1.2rem;
  line-height: 1.2;
  margin-bottom: 0.2rem;
}

.cel-banner span {
  font-size: 0.74rem;
  opacity: 0.9;
}

.cel-items {
  flex: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.6rem;
  align-content: start;
  padding: 1rem 0.9rem;
}

.cel-item {
  padding: 0.6rem;
  background: #FFFFFF;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.06);
}

.cel-item .e {
  display: grid;
  place-items: center;
  height: 58px;
  margin-bottom: 0.4rem;
  border-radius: 8px;
  background: var(--cel-suave);
  font-size: 1.8rem;
  transition: background 0.4s;
}

.cel-item .n {
  font-size: 0.72rem;
  font-weight: 700;
  color: #0F172A;
}

.cel-item .p {
  font-size: 0.7rem;
  color: #475569;
}

.cel-cta {
  margin: 0 0.9rem 1.1rem;
  padding: 0.75rem;
  border-radius: 12px;
  background: #25D366;
  color: #FFFFFF;
  font-weight: 800;
  font-size: 0.8rem;
  text-align: center;
}

.cel-cta.tarjeta {
  background: var(--cel-color);
}

.cel-cap {
  position: relative;
  z-index: 1;
  margin-top: 1.2rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  text-align: center;
}

@keyframes cel-flotar {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

/* ---- Los 3 pasos ---- */
.historia-pasos {
  grid-area: pasos;
  list-style: none;
  display: grid;
  gap: 1rem;
  margin: 0;
  padding: 0;
}

.h-paso {
  display: flex;
  gap: 1rem;
  padding: 1.4rem;
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: 20px;
  box-shadow: var(--shadow-card);
  scroll-margin-top: 6.5rem;
  transition: border-color 0.3s, box-shadow 0.3s;
}

.h-num {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 50%;
  background: var(--color-navy);
  color: #FFFFFF;
  font-weight: 900;
  transition: background 0.3s;
}

.h-paso.hecho .h-num {
  background: var(--color-emerald);
  font-size: 0;
}

.h-paso.hecho .h-num::after {
  content: '✓';
  font-size: 1rem;
}

.h-cuerpo {
  flex: 1;
  min-width: 0;
}

.h-tit {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-primary);
  margin: 0.25rem 0 0.2rem;
}

.h-txt {
  font-size: 0.92rem;
  color: var(--text-secondary);
  margin: 0 0 1rem;
}

.giros {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.55rem;
}

.giro {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.2rem;
  padding: 0.75rem 0.4rem;
  background: #FFFFFF;
  border: 2px solid var(--border-light);
  border-radius: 14px;
  font: 700 0.85rem var(--font-main);
  color: var(--text-primary);
  cursor: pointer;
  transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.giro span {
  font-size: 1.6rem;
  line-height: 1.2;
  transition: transform 0.3s;
}

.giro:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
}

.giro:hover span {
  transform: scale(1.15) rotate(-6deg);
}

.giro[aria-pressed="true"] {
  border-color: var(--color-blue);
  background: var(--color-blue-soft);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.giro:focus-visible,
.color:focus-visible {
  outline: 3px solid var(--color-blue);
  outline-offset: 2px;
}

.h-input {
  width: 100%;
  padding: 0.8rem 1rem;
  border: 2px solid var(--border-light);
  border-radius: 12px;
  font: 600 1rem var(--font-main);
  color: var(--text-primary);
  background: #FFFFFF;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.h-input:focus {
  outline: none;
  border-color: var(--color-blue);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.colores {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 0.85rem;
}

.color {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 3px solid #FFFFFF;
  background: var(--c);
  box-shadow: 0 0 0 1px var(--border-light);
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.color[data-color=""] {
  background: conic-gradient(#C2410C, #0E7490, #BE185D, #7C3AED, #C2410C);
}

.color:hover {
  transform: scale(1.1);
}

.color[aria-pressed="true"] {
  box-shadow: 0 0 0 2px var(--text-primary);
}

/* Paso 3: su recomendación */
.h-paso.listo {
  border-color: var(--color-blue-border);
  box-shadow: 0 16px 36px -12px rgba(37, 99, 235, 0.25);
}

.h-reco {
  animation: aparecer 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

.h-reco-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 0.6rem 1rem;
  margin-bottom: 0.4rem;
}

.h-reco-head small {
  display: block;
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: var(--color-blue);
}

.h-precio b {
  display: block;
  font-size: 1.5rem;
  font-weight: 900;
  line-height: 1.1;
  color: var(--text-primary);
}

.h-precio span {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.h-lista {
  list-style: none;
  display: grid;
  gap: 0.45rem;
  margin: 0.9rem 0 1.2rem;
  padding: 0;
}

.h-lista li {
  display: flex;
  gap: 0.55rem;
  align-items: flex-start;
  font-size: 0.92rem;
  color: var(--text-secondary);
}

.h-lista li::before {
  content: '✓';
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  margin-top: 1px;
  border-radius: 50%;
  background: var(--color-emerald);
  color: #FFFFFF;
  font-size: 0.7rem;
  font-weight: 900;
}

.h-tip {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin: -0.4rem 0 1.1rem;
}

.h-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

/* ---- "Así de fácil": línea que se llena al bajar ---- */
.ventajas + .pasos-simples {
  margin-top: 2.5rem;
}

.pasos-linea {
  position: relative;
  padding-top: 1.4rem;
}

.pasos-linea::before,
.pasos-linea::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 6px;
  border-radius: 6px;
  background: var(--bg-muted);
}

.pasos-linea::after {
  background: linear-gradient(90deg, #2563EB, #10B981);
  transform: scaleX(var(--avance, 0));
  transform-origin: left center;
  transition: transform 0.2s linear;
}

.pasos-linea .paso-num {
  transition: background 0.3s, transform 0.3s;
}

.pasos-linea li.alcanzado .paso-num {
  background: var(--color-blue);
  transform: scale(1.08);
}

/* ---- Celular y tableta ---- */
@media (max-width: 860px) {
  .historia {
    padding: 2.5rem 0 3rem;
  }
  .historia-grid {
    grid-template-columns: 1fr;
    grid-template-areas:
      "texto"
      "cel"
      "pasos";
  }
  .historia-texto {
    padding-top: 0;
    text-align: center;
  }
  .historia .hero-palabras {
    font-size: clamp(2rem, 8.4vw, 3rem);
    text-align: center;
  }
  .historia .hero-sub-punchy {
    margin: 0 auto 1.6rem;
  }
  .historia .hero-btn-row {
    justify-content: center;
    margin-bottom: 1.5rem;
  }
  .cel-zona {
    position: static;
    padding: 0.8rem 0 0.4rem;
  }
  .cel {
    width: 240px;
    height: 480px;
  }
  /* En celular: paso 1 → celular → pasos 2 y 3, así ven el cambio justo abajo de donde tocan */
  .historia-grid {
    row-gap: 1rem;
  }
  .historia-pasos {
    display: contents;
  }
  .historia-texto { order: 1; }
  #paso-giro { order: 2; }
  .cel-zona { order: 3; }
  #paso-nombre { order: 4; }
  #paso-tuya { order: 5; }
  .h-paso {
    width: 100%;
    max-width: 560px;
    margin: 0 auto;
  }
}

@media (max-width: 600px) {
  .h-paso {
    padding: 1.1rem;
    gap: 0.8rem;
  }
  .h-num {
    width: 1.9rem;
    height: 1.9rem;
    font-size: 0.9rem;
  }
  .giro {
    font-size: 0.78rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cel,
  .h-reco {
    animation: none;
  }
  .cel-sitio,
  .giro,
  .giro span,
  .pasos-linea::after {
    transition: none;
  }
}

/* ---- Inicio en dos pantallas, en el mismo lugar (js/historia.js pone las clases; sin JS
   se ve todo como lista):
   1) .cerrada: el mensaje, los botones y el celular.
   2) .abierta: "Pruébalo con tu negocio" cambia el mensaje por los pasos, uno a la vez y
      grandes, junto al celular. "← Volver" regresa al mensaje. ---- */
.historia.cerrada .historia-grid,
.historia.abierta .historia-grid {
  align-items: center;
  min-height: calc(100vh - 12rem);
}
.historia.cerrada .historia-grid {
  grid-template-areas: "texto cel";
}
.historia.cerrada .historia-pasos {
  display: none;
}
.historia.cerrada .hero-btn-row {
  margin-bottom: 0;
}
.historia.abierta .historia-grid {
  grid-template-areas: "pasos cel";
}
.historia.abierta .historia-texto {
  display: none;
}
.historia.cerrada .cel-zona,
.historia.abierta .cel-zona {
  position: relative;
  top: 0;
}
.historia.abierta .historia-pasos {
  grid-template-columns: minmax(0, 1fr);
  gap: 1.1rem;
  align-self: center;
}
.historia.abierta .h-paso:not(.actual) {
  display: none;
}

/* Paso ya completado: solo la palomita en su círculo */
.historia.abierta .h-paso.hecho .h-num {
  font-size: 0;
}

/* Barra de arriba: "← Volver" y 1 · 2 · 3 */
.h-nav {
  display: none;
}
.historia.abierta .h-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.8rem;
}
.h-volver {
  padding: 0.4rem 0;
  border: 0;
  background: none;
  font: 700 0.92rem var(--font-main);
  color: var(--text-secondary);
  cursor: pointer;
  transition: color 0.2s;
}
.h-volver:hover {
  color: var(--color-blue);
}
.h-puntos {
  display: flex;
  gap: 0.4rem;
}
.h-punto {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.35rem 0.8rem 0.35rem 0.35rem;
  border: 1px solid var(--border-light);
  border-radius: 999px;
  background: #FFFFFF;
  font: 700 0.8rem var(--font-main);
  color: var(--text-secondary);
  cursor: pointer;
  transition: border-color 0.25s, background 0.25s, color 0.25s;
}
.h-punto span {
  display: grid;
  place-items: center;
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 50%;
  background: var(--border-light);
  color: var(--text-primary);
  font-size: 0.75rem;
  transition: background 0.25s, color 0.25s;
}
.h-punto[aria-current="step"] {
  border-color: var(--color-blue);
  background: var(--color-blue-soft);
  color: var(--color-blue);
}
.h-punto[aria-current="step"] span {
  background: var(--color-blue);
  color: #FFFFFF;
}
.h-punto.hecho span {
  background: var(--color-emerald);
  color: #FFFFFF;
}

/* El paso, grande como el mensaje del inicio */
.historia.abierta .h-paso {
  padding: 2.2rem;
  gap: 1.3rem;
  border-radius: 24px;
}
.historia.abierta .h-num {
  width: 2.8rem;
  height: 2.8rem;
  font-size: 1.15rem;
}
.historia.abierta .h-tit {
  font-size: clamp(1.6rem, 2.6vw, 2.2rem);
  line-height: 1.15;
  margin-bottom: 0.45rem;
}
.historia.abierta .h-txt {
  font-size: 1.05rem;
  margin-bottom: 1.4rem;
}
.historia.abierta .giros {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.8rem;
}
.historia.abierta .giro {
  padding: 1.1rem 0.5rem;
  font-size: 1rem;
}
.historia.abierta .giro span {
  font-size: 2.2rem;
}
.historia.abierta .h-input {
  padding: 1rem 1.1rem;
  font-size: 1.1rem;
}

/* Cada paso entra suave al llegar a él */
.h-paso.aparece {
  animation: h-paso-entra 0.55s cubic-bezier(0.16, 1, 0.3, 1) both;
}
@keyframes h-paso-entra {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: none; }
}

/* "Ver mi recomendación" en el paso 2 (por si no eligen color) */
.h-continuar {
  display: inline-flex;
  margin-top: 1.2rem;
  padding: 0.6rem 1.2rem;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-pill);
  background: #FFFFFF;
  font-family: inherit;
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--color-blue);
  cursor: pointer;
  transition: all var(--trans-fast);
}
.h-continuar:hover {
  background: var(--color-blue);
  border-color: var(--color-blue);
  color: #FFFFFF;
}

/* Botón "Pruébalo con tu negocio": un saltito, un aro que se expande y la flecha que baja */
.btn-llamativo {
  position: relative;
  animation: llamativo-salto 2.6s ease-in-out infinite;
}
.btn-llamativo::after {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: inherit;
  border: 2px solid var(--color-blue, #2563EB);
  opacity: 0;
  pointer-events: none;
  animation: llamativo-aro 2.6s ease-out infinite;
}
.btn-llamativo .flecha {
  display: inline-block;
  animation: llamativo-flecha 1.3s ease-in-out infinite;
}

@keyframes llamativo-salto {
  0%, 70%, 100% { transform: none; }
  78% { transform: translateY(-3px) scale(1.04); }
  86% { transform: none; }
  92% { transform: translateY(-1px); }
}
@keyframes llamativo-aro {
  0% { opacity: 0.7; transform: scale(1); }
  60%, 100% { opacity: 0; transform: scale(1.12, 1.5); }
}
@keyframes llamativo-flecha {
  0%, 100% { transform: none; }
  50% { transform: translateY(3px); }
}

@media (max-width: 860px) {
  .historia.cerrada .historia-grid,
  .historia.abierta .historia-grid {
    min-height: 0;
  }
  .historia.cerrada .historia-grid {
    grid-template-areas:
      "texto"
      "cel";
  }
  /* En celular: el paso arriba y el celular (un poco más chico) abajo */
  .historia.abierta .historia-grid {
    grid-template-areas:
      "pasos"
      "cel";
  }
  .historia.abierta .historia-pasos {
    display: grid;
    order: 1;
    width: 100%;
    max-width: 560px;
    margin: 0 auto;
  }
  .historia.abierta .cel-zona {
    order: 2;
    padding-top: 0.2rem;
  }
  .historia.abierta .cel {
    transform: scale(0.6);
    transform-origin: top center;
    margin-bottom: -192px;
    animation: none;
  }
  .historia.abierta .h-paso {
    padding: 1.4rem;
    gap: 0.9rem;
  }
  .h-punto {
    padding: 0.3rem;
    font-size: 0;
  }
  .h-punto span {
    font-size: 0.75rem;
  }
}

@media (max-width: 600px) {
  .historia.abierta .h-tit {
    font-size: 1.45rem;
  }
  .historia.abierta .h-num {
    width: 2.2rem;
    height: 2.2rem;
    font-size: 0.95rem;
  }
  .historia.abierta .giro {
    padding: 0.85rem 0.3rem;
    font-size: 0.85rem;
  }
  .historia.abierta .giro span {
    font-size: 1.7rem;
  }
  .historia.abierta .h-paso {
    padding: 1.2rem;
    gap: 0.8rem;
  }
  .historia.abierta .h-txt {
    font-size: 0.98rem;
    margin-bottom: 1.1rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .btn-llamativo,
  .btn-llamativo::after,
  .btn-llamativo .flecha,
  .h-paso.aparece {
    animation: none;
  }
}

/* ---- "Cómo trabajamos" como pantalla fija (js/historia.js pone .pin): la sección es más
   alta que la pantalla y su contenido se queda quieto (sticky) mientras se llena la línea.
   Al completarse (.completo) hay confeti y pasa a la pantalla final. ---- */
.trabajo.pin {
  height: 280vh;
  padding: 0;
}
.trabajo.pin .trabajo-escena {
  position: sticky;
  top: var(--alto-barra, 72px);
  height: calc(100vh - var(--alto-barra, 72px));
  height: calc(100svh - var(--alto-barra, 72px));
  display: flex;
  align-items: center;
  overflow: hidden;
}
.trabajo.pin .trabajo-escena > .container {
  width: 100%;
}
.trabajo.pin .section-head-clean {
  margin-bottom: 2rem;
}
.trabajo-pista {
  display: none;
}
.trabajo.pin .trabajo-pista {
  display: block;
  margin: 1.1rem 0 0;
  text-align: center;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-muted);
  transition: opacity 0.3s;
}
.trabajo-pista span {
  display: inline-block;
  animation: llamativo-flecha 1.3s ease-in-out infinite;
}
.trabajo.completo .trabajo-pista {
  opacity: 0;
}

/* Los pasos se encienden conforme avanza la línea */
.trabajo.pin .pasos-linea::after {
  transition: transform 0.12s linear, box-shadow 0.4s;
}
.trabajo.pin .pasos-linea li {
  transition: border-color 0.35s, transform 0.35s, box-shadow 0.35s, background 0.35s;
}
.trabajo.pin .pasos-linea li.alcanzado {
  border-color: var(--color-blue-border);
  background: #FFFFFF;
  transform: translateY(-4px);
  box-shadow: 0 14px 30px -14px rgba(37, 99, 235, 0.35);
}
.trabajo.completo .pasos-linea::after {
  box-shadow: 0 0 18px rgba(16, 185, 129, 0.65);
}
.trabajo.completo .pasos-linea li .paso-num {
  background: var(--color-emerald);
}
.trabajo.completo .pasos-linea {
  animation: linea-festejo 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes linea-festejo {
  0%, 100% { transform: none; }
  40% { transform: scale(1.025); }
}

/* Confeti: sale del centro de la pantalla */
.trabajo-confeti {
  position: absolute;
  left: 50%;
  top: 55%;
  width: 0;
  height: 0;
  z-index: 3;
  pointer-events: none;
}
.trabajo-confeti i {
  position: absolute;
  width: 10px;
  height: 14px;
  border-radius: 2px;
  background: var(--c);
  opacity: 0;
}
.trabajo-confeti.activo i {
  animation: confeti var(--t) cubic-bezier(0.15, 0.7, 0.3, 1) forwards;
}
@keyframes confeti {
  0% { opacity: 1; transform: translate(0, 0) rotate(0deg) scale(0.6); }
  75% { opacity: 1; }
  100% { opacity: 0; transform: translate(var(--x), calc(var(--y) + 160px)) rotate(var(--r)) scale(1); }
}

/* Pantalla final: todo lo que hacemos + ¿Listo para empezar? */
.seccion-servicios {
  min-height: calc(100vh - 72px);
  display: flex;
  align-items: center;
}
.seccion-servicios > .container {
  width: 100%;
}
.seccion-servicios.section-clean {
  padding: 2rem 0;
}
.seccion-servicios .section-head-clean {
  margin-bottom: 1.6rem;
}
.seccion-servicios .three-pillars-grid {
  gap: 1.2rem;
}
.seccion-servicios .pillar-card-clean {
  padding: 1.5rem 1.6rem;
}
.seccion-servicios .pillar-icon-svg {
  margin-bottom: 0.8rem;
}
.seccion-servicios .pillar-title-clean {
  font-size: 1.25rem;
  margin-bottom: 0.4rem;
}
.seccion-servicios .pillar-desc-clean {
  margin-bottom: 0.6rem;
}
.seccion-servicios .servicio-precio {
  font-size: 1.5rem;
  margin: 0.6rem 0 0.5rem;
}
/* El cierre como franja: texto a la izquierda y botones a la derecha */
.seccion-servicios .cta-final {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  margin-top: 1.4rem;
  padding: 1.6rem 2rem;
  text-align: left;
}
.seccion-servicios .cta-final h2 {
  font-size: clamp(1.4rem, 2.4vw, 1.9rem);
  margin-bottom: 0.25rem;
}
.seccion-servicios .cta-final p {
  margin-bottom: 0;
}
.seccion-servicios .cta-final .hero-btn-row {
  flex-shrink: 0;
  justify-content: flex-end;
}

@media (max-width: 860px) {
  /* En celular, la pantalla fija en versión compacta para que quepa completa */
  .trabajo.pin .trabajo-escena {
    height: calc(100vh - var(--alto-barra, 60px) - 64px);
    height: calc(100svh - var(--alto-barra, 60px) - 64px);
  }
  .trabajo.pin .section-head-clean {
    margin-bottom: 1rem;
  }
  .trabajo.pin .ventajas {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.5rem;
    max-width: none;
  }
  .trabajo.pin .ventaja {
    display: block;
    padding: 0.7rem 0.4rem;
    text-align: center;
  }
  .trabajo.pin .ventaja-emoji {
    font-size: 1.5rem;
  }
  .trabajo.pin .ventaja-tit {
    font-size: 0.85rem;
    margin: 0.3rem 0 0;
  }
  .trabajo.pin .ventaja-txt {
    display: none;
  }
  .trabajo.pin .ventajas + .pasos-simples {
    margin-top: 1.3rem;
  }
  .trabajo.pin .pasos-simples {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.6rem;
  }
  .trabajo.pin .pasos-simples li {
    padding: 0.8rem;
  }
  .trabajo.pin .paso-num {
    width: 1.8rem;
    height: 1.8rem;
    margin-bottom: 0.4rem;
    font-size: 0.85rem;
  }
  .trabajo.pin .pasos-simples h3 {
    font-size: 0.9rem;
  }
  .trabajo.pin .pasos-simples p {
    font-size: 0.78rem;
  }
  .trabajo.pin .pasos-pago {
    margin-top: 0.9rem;
    font-size: 0.8rem;
  }
  .seccion-servicios {
    min-height: 0;
  }
  .seccion-servicios .cta-final {
    flex-direction: column;
    text-align: center;
    padding: 1.8rem 1.3rem;
  }
  .seccion-servicios .cta-final .hero-btn-row {
    justify-content: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  .trabajo-pista span,
  .trabajo.completo .pasos-linea {
    animation: none;
  }
}

/* Cotizador en laptops de pantalla baja: la parte fija del resumen (sugerencia, totales y
   pago) se compacta para que la lista de servicios conserve espacio. */
@media (min-width: 1025px) and (max-height: 820px) {
  .calc-summary-sticky {
    padding-top: 1.4rem;
  }
  .summary-head-clean {
    margin-bottom: 0.7rem;
    padding-bottom: 0.6rem;
  }
  .summary-footer {
    padding-bottom: 1.1rem;
  }
  .summary-footer .upsell-box {
    margin: 0.7rem 0;
    padding: 0.55rem 0.75rem;
    font-size: 0.72rem;
  }
  .summary-footer .btn-upsell {
    margin-top: 0.35rem;
    padding: 0.3rem 0.7rem;
    font-size: 0.72rem;
  }
  .summary-totals-box {
    padding-top: 0.7rem;
    margin-bottom: 0.7rem;
  }
  .total-line {
    margin-bottom: 0.15rem;
  }
  .total-val {
    font-size: 1.35rem;
  }
  .total-val.recurring {
    font-size: 1.1rem;
  }
  .summary-footer .consumo-note {
    font-size: 0.68rem;
    margin: -0.4rem 0 0.6rem;
  }
  /* Pagar y asesor lado a lado */
  .calc-acciones {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
  }
  .calc-acciones > .calc-anticipo,
  .calc-acciones > .calc-anticipo-nota,
  .calc-acciones > .calc-pago-msg {
    grid-column: 1 / -1;
  }
  .calc-pagar-btn,
  .calc-asesor-btn {
    padding: 0.65rem 0.5rem;
    font-size: 0.86rem;
  }
}
