/* ==========================================================================
   CALCULADORA DE ALQUILERES ARGENTINA - ESTILO EDITORIAL Y FINANCIERO
   Diseño sobrio, confiable, institucional y humano para República Argentina.
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. VARIABLES DE DISEÑO & TOKENS EDITORIALES
   -------------------------------------------------------------------------- */
:root {
  /* Paleta Base Cálida y Naval */
  --bg-canvas: #f6f3ee;
  --bg-surface: #faf8f5;
  --bg-surface-elevated: #ffffff;
  --bg-subtle: #f0ebe1;
  --bg-muted: #e7e1d5;

  /* Colores Principales */
  --navy-950: #08111d;
  --navy-900: #0e1c2f;
  --navy-800: #162a45;
  --navy-700: #20395c;
  --navy-600: #2f4e7a;
  
  /* Acento Terracota Editorial */
  --terracotta-900: #7e2d14;
  --terracotta-700: #b5431f;
  --terracotta-600: #c8522c;
  --terracotta-500: #dc633b;
  --terracotta-100: #faece7;
  --terracotta-50: #fdf5f2;

  /* Estados y Acentos Complementarios */
  --forest-800: #1b4b34;
  --forest-700: #276749;
  --forest-100: #e7f4ed;
  --gold-800: #7a5210;
  --gold-700: #9e6914;
  --gold-100: #fdf4e4;

  /* Textos y Contraste */
  --text-main: #0e1c2f;
  --text-body: #2d3748;
  --text-muted: #5a6578;
  --text-light: #7c889b;
  --text-inverse: #ffffff;

  /* Bordes Finos Editoriales */
  --border-subtle: #eae5dc;
  --border-default: #ddd6c9;
  --border-strong: #b8aea0;
  --border-focus: #0e1c2f;

  /* Tipografías */
  --font-serif: 'Newsreader', 'Lora', Georgia, serif;
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'IBM Plex Mono', 'JetBrains Mono', Consolas, monospace;

  /* Espaciados y Radios Sutiles (No burbujas SaaS) */
  --radius-xs: 2px;
  --radius-sm: 4px;
  --radius-md: 6px;
  --radius-lg: 8px;
  --radius-xl: 12px;

  /* Sombras Mínimas y Crisp */
  --shadow-sm: 0 1px 2px rgba(14, 28, 47, 0.04);
  --shadow-md: 0 4px 12px rgba(14, 28, 47, 0.06);
  --shadow-lg: 0 10px 25px rgba(14, 28, 47, 0.09);

  /* Dimensiones */
  --container-max: 1180px;
  --transition-smooth: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

/* --------------------------------------------------------------------------
   2. RESET & BASE STYLES
   -------------------------------------------------------------------------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-canvas);
  color: var(--text-body);
  line-height: 1.6;
  min-height: 100vh;
}

/* Tipografía de Encabezados */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-serif);
  color: var(--navy-900);
  line-height: 1.25;
  font-weight: 600;
  letter-spacing: -0.015em;
}

p {
  margin-bottom: 1rem;
}

p:last-child {
  margin-bottom: 0;
}

a {
  color: var(--navy-900);
  text-decoration: none;
  transition: var(--transition-smooth);
}

a:hover {
  color: var(--terracotta-600);
}

ul, ol {
  list-style: none;
}

button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

.mono {
  font-family: var(--font-mono);
}

.text-terracotta {
  color: var(--terracotta-600) !important;
}

.text-forest {
  color: var(--forest-700) !important;
}

.text-right {
  text-align: right;
}

.text-bold {
  font-weight: 700;
}

/* --------------------------------------------------------------------------
   3. LAYOUT & CONTAINERS
   -------------------------------------------------------------------------- */
.site-container {
  width: 100%;
  max-width: var(--container-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

/* --------------------------------------------------------------------------
   4. TOP BAR: MOCKUP CONTROLLER (Desktop vs Mobile Preview)
   -------------------------------------------------------------------------- */
.mockup-control-bar {
  background-color: var(--navy-950);
  color: #ffffff;
  padding: 0.6rem 1.25rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

.mockup-control-inner {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.mockup-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #cbd5e1;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  background-color: #22c55e;
  border-radius: 50%;
  box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.3);
  animation: pulseAnim 2s infinite;
}

@keyframes pulseAnim {
  0% { transform: scale(0.95); opacity: 0.8; }
  50% { transform: scale(1.15); opacity: 1; }
  100% { transform: scale(0.95); opacity: 0.8; }
}

.mockup-view-toggles {
  display: flex;
  background-color: rgba(255, 255, 255, 0.1);
  padding: 3px;
  border-radius: var(--radius-md);
  gap: 2px;
}

.view-btn {
  background: transparent;
  border: none;
  color: #94a3b8;
  padding: 0.35rem 0.85rem;
  font-size: 0.8rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.view-btn:hover {
  color: #ffffff;
  background-color: rgba(255, 255, 255, 0.05);
}

.view-btn.active {
  background-color: #ffffff;
  color: var(--navy-950);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.mockup-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.quick-action-btn {
  background-color: transparent;
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #e2e8f0;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.quick-action-btn:hover {
  background-color: rgba(255, 255, 255, 0.15);
  border-color: #ffffff;
  color: #ffffff;
}

/* --------------------------------------------------------------------------
   5. VIEWPORT MOCKUP WRAPPER (Desktop / Mobile Mode)
   -------------------------------------------------------------------------- */
.app-viewport-wrapper {
  width: 100%;
  transition: padding 0.3s ease;
}

.site-canvas {
  width: 100%;
  background-color: var(--bg-surface);
  min-height: 100vh;
  position: relative;
  transition: width 0.3s cubic-bezier(0.16, 1, 0.3, 1), transform 0.3s ease, box-shadow 0.3s ease;
}

/* Estado Modo Móvil Simulado (390px iPhone Frame) */
.app-viewport-wrapper.mode-mobile {
  padding: 2.5rem 1rem;
  background-color: #1e293b;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  min-height: calc(100vh - 45px);
}

.app-viewport-wrapper.mode-mobile .site-canvas {
  max-width: 390px;
  width: 390px;
  border: 11px solid #0f172a;
  border-radius: 46px;
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(255, 255, 255, 0.1);
  overflow-x: hidden;
  overflow-y: auto;
  max-height: 844px;
}

.phone-status-bar {
  display: none;
  background-color: var(--navy-950);
  color: #ffffff;
  padding: 0.45rem 1.25rem 0.25rem;
  font-size: 0.75rem;
  font-weight: 600;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 999;
}

.app-viewport-wrapper.mode-mobile .phone-status-bar {
  display: flex;
}

.phone-notch {
  width: 100px;
  height: 16px;
  background-color: #0f172a;
  border-radius: 12px;
}

.phone-icons {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

/* Modo Dual Lado a Lado */
.app-viewport-wrapper.mode-dual {
  padding: 2rem;
  background-color: #111827;
  display: flex;
  justify-content: center;
  gap: 2.5rem;
  flex-wrap: wrap;
}

.app-viewport-wrapper.mode-dual .site-canvas {
  max-width: 820px;
  flex: 1 1 700px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

/* --------------------------------------------------------------------------
   6. HEADER & TICKER
   -------------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--border-default, #ddd6c9);
  background-color: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition: box-shadow 0.25s ease, border-color 0.25s ease;
}

.site-header.is-scrolled {
  box-shadow: 0 4px 20px rgba(14, 28, 47, 0.08);
  border-bottom-color: rgba(221, 214, 201, 0.6);
}

/* Ticker Bar Oficial */
.indices-ticker-bar {
  background-color: var(--navy-950, #08111d);
  color: #ffffff;
  font-size: 0.72rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  padding: 0.4rem 0;
  line-height: 1.2;
}

.ticker-flex {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
}

.ticker-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  font-size: 0.68rem;
  flex-shrink: 0;
}

.badge-live {
  background-color: var(--terracotta-600, #c8522c);
  color: #ffffff;
  padding: 0.15rem 0.45rem;
  border-radius: 2px;
  font-size: 0.5625rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.ticker-source {
  color: #94a3b8;
  font-weight: 500;
}

.ticker-items {
  display: flex;
  align-items: center;
  gap: 1rem;
  overflow-x: auto;
  white-space: nowrap;
  scrollbar-width: none;
}

.ticker-items::-webkit-scrollbar {
  display: none;
}

.ticker-item {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.72rem;
}

.ticker-name {
  color: #94a3b8;
}

.ticker-val {
  color: #ffffff;
  font-family: var(--font-mono, monospace);
  font-weight: 700;
}

.ticker-change.up {
  color: #34d399;
  font-size: 0.7rem;
  font-weight: 600;
}

.ticker-tag, .ticker-pill {
  font-size: 0.65rem;
  background-color: rgba(255, 255, 255, 0.12);
  padding: 0.1rem 0.4rem;
  border-radius: 2px;
  color: #e2e8f0;
}

.ticker-divider {
  width: 1px;
  height: 12px;
  background-color: rgba(255, 255, 255, 0.15);
  flex-shrink: 0;
}

.ticker-date {
  font-size: 0.68rem;
  color: #64748b;
  white-space: nowrap;
  flex-shrink: 0;
}

/* Barra de Navegación Principal */
.main-nav-bar {
  padding: 0.75rem 0;
}

.nav-flex {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
}

.brand-identity {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  flex-shrink: 0;
}

.brand-identity:hover {
  text-decoration: none;
}

.brand-monogram {
  width: 38px;
  height: 38px;
  background-color: var(--navy-900, #0e1c2f);
  color: #ffffff;
  font-family: var(--font-serif, Georgia, serif);
  font-weight: 700;
  font-size: 1.05rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  border-left: 3.5px solid var(--terracotta-600, #c8522c);
  transition: background-color 0.2s ease;
  letter-spacing: 0.02em;
  flex-shrink: 0;
}

.brand-identity:hover .brand-monogram {
  background-color: var(--navy-800, #162a45);
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.brand-title {
  font-family: var(--font-serif, Georgia, serif);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--navy-900, #0e1c2f);
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.brand-sub {
  font-size: 0.625rem;
  color: var(--text-muted, #5a6578);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  line-height: 1;
}

.primary-nav .nav-list {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--navy-800, #162a45);
  padding: 0.45rem 0.75rem;
  border-radius: 4px;
  position: relative;
  text-decoration: none;
  white-space: nowrap;
  letter-spacing: 0.01em;
  transition: color 0.2s ease, background-color 0.2s ease;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 2px;
  left: 0.75rem;
  right: 0.75rem;
  height: 2px;
  background-color: var(--terracotta-600, #c8522c);
  border-radius: 1px;
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-link:hover {
  color: var(--terracotta-600, #c8522c);
  background-color: rgba(200, 82, 44, 0.06);
}

.nav-link:hover::after, .nav-link.active::after {
  transform: scaleX(1);
}

.nav-link.active {
  color: var(--terracotta-600, #c8522c);
  background-color: rgba(200, 82, 44, 0.08);
}

.header-cta-group {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}

.header-cta-group .btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background-color: var(--terracotta-600, #c8522c);
  color: #ffffff;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.45rem 0.9rem;
  border-radius: 4px;
  text-decoration: none;
  letter-spacing: 0.02em;
  white-space: nowrap;
  box-shadow: 0 1px 3px rgba(200, 82, 44, 0.2);
  transition: background-color 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
}

.header-cta-group .btn-secondary:hover {
  background-color: var(--terracotta-700, #b5431f);
  color: #ffffff;
  transform: translateY(-1px);
  box-shadow: 0 3px 8px rgba(200, 82, 44, 0.3);
}

.header-cta-icon {
  flex-shrink: 0;
  opacity: 0.9;
}

.mobile-menu-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--border-default, #ddd6c9);
  padding: 0.45rem 0.55rem;
  border-radius: 4px;
  cursor: pointer;
  flex-direction: column;
  gap: 4px;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.mobile-menu-toggle:hover {
  border-color: var(--border-strong, #b8aea0);
  background-color: rgba(14, 28, 47, 0.04);
}

.mobile-menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  background-color: var(--navy-900, #0e1c2f);
  transition: transform 0.2s ease;
}

/* Mobile Drawer */
.mobile-nav-drawer {
  display: none;
  background-color: #ffffff;
  border-top: 1px solid var(--border-default, #ddd6c9);
  padding: 0.75rem 1.5rem 1.25rem;
  box-shadow: 0 16px 40px rgba(14, 28, 47, 0.1);
}

.mobile-nav-drawer.open {
  display: block;
}

.mobile-nav-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.mobile-nav-link {
  display: block;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--navy-900, #0e1c2f);
  padding: 0.8rem 0;
  border-bottom: 1px solid var(--border-subtle, #eae5dc);
  text-decoration: none;
  transition: color 0.2s ease, padding-left 0.2s ease;
}

.mobile-nav-link:hover {
  color: var(--terracotta-600, #c8522c);
  padding-left: 0.5rem;
}

.mobile-nav-link:last-child {
  border-bottom: none;
}

.mobile-drawer-footer {
  margin-top: 1.25rem;
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* --------------------------------------------------------------------------
   7. HERO SECTION (EDITORIAL STYLE)
   -------------------------------------------------------------------------- */
.hero-section {
  padding: 3rem 0 2.5rem;
  border-bottom: 1px solid var(--border-default);
  background-color: var(--bg-surface);
}

.hero-layout {
  display: grid;
  grid-template-columns: 1.45fr 1fr;
  gap: 2.75rem;
  align-items: center;
}

.hero-editorial-meta {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--terracotta-700);
  text-transform: uppercase;
  margin-bottom: 0.85rem;
}

.meta-separator {
  color: var(--border-strong);
}

.hero-heading {
  font-size: 2.6rem;
  line-height: 1.15;
  color: var(--navy-900);
  margin-bottom: 1.15rem;
}

.hero-lead {
  font-size: 1.08rem;
  line-height: 1.6;
  color: var(--text-body);
  margin-bottom: 1.75rem;
}

.hero-lead strong {
  color: var(--navy-900);
}

.hero-badges-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
}

.trust-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background-color: var(--bg-subtle);
  border: 1px solid var(--border-default);
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--navy-800);
}

.trust-badge svg {
  color: var(--terracotta-600);
}

/* Tarjeta Lateral de Hero */
.hero-sidebar-card {
  background-color: var(--bg-surface-elevated);
  border: 1px solid var(--border-default);
  border-top: 4px solid var(--navy-900);
  padding: 1.6rem;
  box-shadow: var(--shadow-sm);
}

.card-header-subtle {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.75rem;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 0.5rem;
}

.card-kicker {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--navy-700);
}

.card-stamp {
  font-size: 0.65rem;
  font-weight: 800;
  background-color: var(--navy-900);
  color: #ffffff;
  padding: 0.1rem 0.4rem;
  border-radius: var(--radius-xs);
}

.card-stat-main {
  margin-bottom: 1.25rem;
}

.stat-number {
  font-family: var(--font-mono);
  font-size: 2.25rem;
  font-weight: 700;
  color: var(--navy-900);
  line-height: 1.1;
}

.stat-caption {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
}

.stat-list {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  margin-bottom: 1.5rem;
  font-size: 0.84rem;
  border-top: 1px solid var(--border-subtle);
  padding-top: 0.85rem;
}

.stat-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--text-body);
}

.stat-list li strong {
  font-family: var(--font-mono);
}

/* --------------------------------------------------------------------------
   8. CALCULATOR SECTION (MAIN FOCUS)
   -------------------------------------------------------------------------- */
.calculator-section {
  padding: 3.5rem 0;
  background-color: var(--bg-canvas);
}

.section-title-wrap {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 2.5rem;
}

.section-kicker {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--terracotta-700);
  margin-bottom: 0.4rem;
}

.section-title {
  font-size: 2.15rem;
  color: var(--navy-900);
  margin-bottom: 0.65rem;
}

.section-intro {
  font-size: 0.96rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.calculator-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.95fr;
  gap: 2rem;
  align-items: start;
}

/* Tarjetas Base de la Calculadora */
.calc-card {
  background-color: var(--bg-surface-elevated);
  border: 1px solid var(--border-default);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
}

.form-card {
  border-top: 3px solid var(--navy-900);
}

.result-card {
  border-top: 3px solid var(--terracotta-600);
  background-color: var(--bg-surface);
}

.card-topline {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border-subtle);
}

.card-legend {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--navy-800);
}

.highlight-tag {
  color: var(--terracotta-700);
}

.status-indicator {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--forest-700);
}

.dot-valid {
  width: 7px;
  height: 7px;
  background-color: var(--forest-700);
  border-radius: 50%;
}

.btn-text-link {
  background: none;
  border: none;
  font-size: 0.75rem;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
}

.btn-text-link:hover {
  color: var(--terracotta-600);
}

/* Campos de Formulario */
.form-group {
  margin-bottom: 1.5rem;
}

.label-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 0.45rem;
}

.form-label {
  font-size: 0.88rem;
  color: var(--navy-900);
}

.form-label .required {
  color: var(--terracotta-600);
}

.label-hint {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.link-explanation {
  font-size: 0.72rem;
  color: var(--navy-700);
  text-decoration: underline;
}

/* Input Form Controls */
.form-control {
  width: 100%;
  padding: 0.65rem 0.85rem;
  background-color: #ffffff;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  color: var(--navy-900);
  font-size: 0.95rem;
  transition: var(--transition-smooth);
}

.form-control:focus {
  outline: none;
  border-color: var(--navy-900);
  box-shadow: 0 0 0 2px rgba(14, 28, 47, 0.12);
}

.form-control-lg {
  padding: 0.75rem 1rem;
  font-size: 1.25rem;
}

.input-currency-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.currency-prefix {
  position: absolute;
  left: 1rem;
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--navy-800);
  pointer-events: none;
}

.input-currency-wrapper .form-control {
  padding-left: 2.2rem;
  font-family: var(--font-mono);
}

.preset-pills-row {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 0.6rem;
  flex-wrap: wrap;
}

.preset-label {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.pill-btn {
  background-color: var(--bg-subtle);
  border: 1px solid var(--border-default);
  padding: 0.2rem 0.55rem;
  font-size: 0.75rem;
  font-family: var(--font-mono);
  border-radius: var(--radius-xs);
  cursor: pointer;
  transition: var(--transition-smooth);
}

.pill-btn:hover {
  background-color: var(--border-default);
}

.pill-btn.active {
  background-color: var(--navy-900);
  color: #ffffff;
  border-color: var(--navy-900);
}

.select-wrapper {
  position: relative;
}

.select-control {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%230e1c2f' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.85rem center;
  padding-right: 2.2rem;
  cursor: pointer;
}

.field-subtext {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.4rem;
}

/* Grilla de Frecuencia */
.frequency-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.65rem;
}

.freq-option {
  position: relative;
  cursor: pointer;
}

.freq-option input {
  position: absolute;
  opacity: 0;
}

.freq-box {
  display: flex;
  flex-direction: column;
  padding: 0.65rem 0.85rem;
  border: 1px solid var(--border-strong);
  background-color: #ffffff;
  border-radius: var(--radius-sm);
  transition: var(--transition-smooth);
}

.freq-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--navy-900);
}

.freq-sub {
  font-size: 0.68rem;
  color: var(--text-muted);
  margin-top: 0.15rem;
}

.freq-option input:checked + .freq-box {
  border-color: var(--navy-900);
  background-color: #f7fafc;
  box-shadow: inset 0 0 0 1px var(--navy-900);
}

.freq-option input:focus + .freq-box {
  box-shadow: 0 0 0 2px rgba(14, 28, 47, 0.15);
}

/* 2 Columnas de Fecha */
.form-row-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.date-helper {
  font-size: 0.7rem;
  color: var(--text-muted);
  display: block;
  margin-top: 0.25rem;
}

.preset-dates-bar {
  background-color: var(--bg-subtle);
  border: 1px solid var(--border-default);
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-sm);
  margin-bottom: 1.75rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.preset-title {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--navy-900);
}

.preset-buttons-group {
  display: flex;
  gap: 0.35rem;
  flex-wrap: wrap;
}

.btn-chip {
  background-color: #ffffff;
  border: 1px solid var(--border-strong);
  font-size: 0.72rem;
  padding: 0.2rem 0.5rem;
  border-radius: var(--radius-xs);
  cursor: pointer;
  font-weight: 600;
  transition: var(--transition-smooth);
}

.btn-chip:hover {
  background-color: var(--border-subtle);
}

.btn-chip.active {
  background-color: var(--navy-900);
  color: #ffffff;
  border-color: var(--navy-900);
}

/* Botones Principales */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-weight: 600;
  font-size: 0.9rem;
  padding: 0.65rem 1.25rem;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
  transition: var(--transition-smooth);
  text-decoration: none;
}

.btn-primary {
  background-color: var(--navy-900);
  color: #ffffff;
  border-color: var(--navy-900);
}

.btn-primary:hover {
  background-color: var(--navy-800);
  color: #ffffff;
  box-shadow: var(--shadow-md);
}

.btn-secondary {
  background-color: var(--terracotta-600);
  color: #ffffff;
  border-color: var(--terracotta-600);
}

.btn-secondary:hover {
  background-color: var(--terracotta-700);
  color: #ffffff;
}

.btn-outline {
  background-color: transparent;
  border-color: var(--navy-900);
  color: var(--navy-900);
}

.btn-outline:hover {
  background-color: var(--navy-900);
  color: #ffffff;
}

.btn-sm {
  padding: 0.35rem 0.75rem;
  font-size: 0.8rem;
}

.btn-lg {
  padding: 0.85rem 1.5rem;
  font-size: 1.05rem;
}

.btn-block {
  width: 100%;
}

.btn-calculate {
  width: 100%;
}

/* --------------------------------------------------------------------------
   9. CALCULATION RESULT CARD STYLES
   -------------------------------------------------------------------------- */
.result-hero-box {
  background-color: #ffffff;
  border: 1px solid var(--border-default);
  padding: 1.5rem;
  text-align: center;
  margin-bottom: 1.25rem;
  position: relative;
}

.result-label {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-bottom: 0.35rem;
}

.result-main-value {
  font-family: var(--font-mono);
  font-size: 2.35rem;
  font-weight: 700;
  color: var(--navy-900);
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.result-sub-detail {
  font-size: 0.82rem;
  color: var(--text-body);
  margin-top: 0.45rem;
}

.result-metrics-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
  margin-bottom: 1.25rem;
}

.metric-cell {
  background-color: #ffffff;
  border: 1px solid var(--border-default);
  padding: 0.85rem 1rem;
}

.metric-label {
  font-size: 0.72rem;
  color: var(--text-muted);
  display: block;
  margin-bottom: 0.2rem;
}

.metric-value-accent {
  font-family: var(--font-mono);
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--terracotta-600);
  line-height: 1.1;
}

.metric-value-nominal {
  font-family: var(--font-mono);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--navy-900);
  line-height: 1.1;
}

.metric-note {
  font-size: 0.68rem;
  color: var(--text-light);
  display: block;
  margin-top: 0.25rem;
}

/* Desglose Técnico */
.result-technical-breakdown {
  background-color: var(--bg-surface-elevated);
  border: 1px solid var(--border-default);
  padding: 1.15rem;
  margin-bottom: 1.5rem;
}

.breakdown-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.75rem;
  padding-bottom: 0.4rem;
  border-bottom: 1px solid var(--border-subtle);
}

.breakdown-title {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--navy-900);
}

.breakdown-source {
  font-size: 0.68rem;
  background-color: var(--bg-subtle);
  padding: 0.1rem 0.35rem;
  border-radius: var(--radius-xs);
  font-weight: 600;
}

.technical-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
  margin-bottom: 0.85rem;
}

.technical-table td {
  padding: 0.35rem 0;
  border-bottom: 1px dashed var(--border-subtle);
}

.formula-box {
  background-color: var(--bg-canvas);
  border-left: 3px solid var(--navy-900);
  padding: 0.6rem 0.75rem;
  font-size: 0.78rem;
}

.formula-title {
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-bottom: 0.2rem;
}

.formula-code {
  font-family: var(--font-mono);
  color: var(--navy-900);
  display: block;
  word-break: break-all;
  font-size: 0.8rem;
}

.result-actions-block {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.secondary-actions-row {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
}

.btn-link-action {
  background: none;
  border: none;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--navy-800);
  cursor: pointer;
  padding: 0.35rem 0;
  transition: var(--transition-smooth);
}

.btn-link-action:hover {
  color: var(--terracotta-600);
  text-decoration: underline;
}

/* --------------------------------------------------------------------------
   10. RENTAL TIMELINE SECTION (CRONOGRAMA)
   -------------------------------------------------------------------------- */
.timeline-section {
  padding: 3.5rem 0;
  border-top: 1px solid var(--border-default);
  background-color: var(--bg-surface);
}

.timeline-card {
  background-color: var(--bg-surface-elevated);
  border: 1px solid var(--border-default);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
}

.timeline-meta-bar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  background-color: var(--bg-subtle);
  border: 1px solid var(--border-default);
  padding: 0.85rem 1.25rem;
  margin-bottom: 2rem;
  font-size: 0.82rem;
}

.timeline-meta-item {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.timeline-meta-item span {
  color: var(--text-muted);
  font-size: 0.72rem;
}

.timeline-meta-item strong {
  color: var(--navy-900);
}

.timeline-flow {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  padding-left: 2rem;
  border-left: 2px solid var(--border-default);
  margin-left: 0.75rem;
  margin-bottom: 2rem;
}

.timeline-node {
  position: relative;
}

.timeline-node::before {
  content: '';
  position: absolute;
  left: -2.45rem;
  top: 0.35rem;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background-color: #ffffff;
  border: 3px solid var(--border-strong);
}

.timeline-node.status-past::before {
  background-color: var(--forest-700);
  border-color: var(--forest-700);
}

.timeline-node.status-current::before {
  background-color: var(--terracotta-600);
  border-color: var(--terracotta-600);
  box-shadow: 0 0 0 3px rgba(200, 82, 44, 0.2);
}

.timeline-node.status-future::before {
  background-color: #ffffff;
  border-color: var(--navy-600);
}

.timeline-node-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-default);
  padding: 1rem 1.25rem;
  display: grid;
  grid-template-columns: 1.2fr 1fr 1.2fr 1fr;
  align-items: center;
  gap: 1rem;
}

.timeline-node.status-current .timeline-node-card {
  border-left: 4px solid var(--terracotta-600);
  background-color: #ffffff;
}

.tl-period-title {
  font-weight: 700;
  color: var(--navy-900);
  font-size: 0.9rem;
}

.tl-period-date {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.tl-amount-box {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--navy-900);
}

.tl-status-pill {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: var(--radius-xs);
  text-align: center;
}

.pill-past {
  background-color: var(--forest-100);
  color: var(--forest-700);
}

.pill-current {
  background-color: var(--terracotta-100);
  color: var(--terracotta-700);
}

.pill-future {
  background-color: var(--bg-subtle);
  color: var(--text-muted);
}

.timeline-note-footer {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  font-size: 0.78rem;
  color: var(--text-muted);
  background-color: var(--bg-canvas);
  padding: 0.85rem 1rem;
  border-radius: var(--radius-sm);
  line-height: 1.45;
}

.timeline-note-footer svg {
  flex-shrink: 0;
  margin-top: 0.1rem;
}

/* --------------------------------------------------------------------------
   11. INDEX INFORMATION GUIDE (TABS & FICHA TÉCNICA)
   -------------------------------------------------------------------------- */
.indices-guide-section {
  padding: 3.5rem 0;
  background-color: var(--bg-canvas);
}

.indices-tabs-nav {
  display: flex;
  gap: 0.5rem;
  border-bottom: 1px solid var(--border-strong);
  margin-bottom: 1.5rem;
  overflow-x: auto;
}

.tab-btn {
  background: transparent;
  border: none;
  padding: 0.75rem 1.25rem;
  font-size: 0.88rem;
  color: var(--text-muted);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  white-space: nowrap;
  transition: var(--transition-smooth);
}

.tab-btn:hover {
  color: var(--navy-900);
}

.tab-btn.active {
  color: var(--navy-900);
  border-bottom-color: var(--terracotta-600);
  font-weight: 700;
}

.indices-tabs-content {
  background-color: var(--bg-surface-elevated);
  border: 1px solid var(--border-default);
  padding: 2.25rem;
}

.tab-pane {
  display: none;
}

.tab-pane.active {
  display: block;
}

.guide-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 2.5rem;
}

.guide-badge-row {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.85rem;
}

.tag-navy {
  background-color: var(--navy-900);
  color: #ffffff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: var(--radius-xs);
}

.tag-neutral {
  background-color: var(--bg-subtle);
  color: var(--text-body);
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.15rem 0.5rem;
  border-radius: var(--radius-xs);
  border: 1px solid var(--border-default);
}

.tag-terracotta {
  background-color: var(--terracotta-100);
  color: var(--terracotta-700);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: var(--radius-xs);
}

.guide-heading {
  font-size: 1.55rem;
  color: var(--navy-900);
  margin-bottom: 1rem;
}

.guide-checklist {
  margin: 1.25rem 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.guide-checklist li {
  position: relative;
  padding-left: 1.5rem;
  font-size: 0.9rem;
}

.guide-checklist li::before {
  content: '■';
  position: absolute;
  left: 0;
  color: var(--terracotta-600);
  font-size: 0.75rem;
  top: 0.1rem;
}

.guide-pro-con-box {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  background-color: var(--bg-surface);
  border: 1px solid var(--border-default);
  padding: 1rem;
  margin-top: 1.5rem;
  font-size: 0.82rem;
}

.col-title {
  display: block;
  font-weight: 700;
  margin-bottom: 0.35rem;
}

/* Sidebar Ficha Técnica */
.sidebar-box {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-default);
  padding: 1.5rem;
}

.box-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--navy-900);
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--border-default);
  padding-bottom: 0.5rem;
}

.data-definition-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.65rem;
  font-size: 0.84rem;
  margin-bottom: 1.25rem;
}

.data-definition-list dt {
  color: var(--text-muted);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.data-definition-list dd {
  font-weight: 600;
  color: var(--navy-900);
  margin-bottom: 0.4rem;
}

/* --------------------------------------------------------------------------
   12. HOW IT WORKS SECTION (PASO A PASO)
   -------------------------------------------------------------------------- */
.how-it-works-section {
  padding: 3.5rem 0;
  border-top: 1px solid var(--border-default);
  background-color: var(--bg-surface);
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}

.step-card {
  background-color: var(--bg-surface-elevated);
  border: 1px solid var(--border-default);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
}

.step-card.highlight-step {
  border-top: 3px solid var(--terracotta-600);
  background-color: #ffffff;
}

.step-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.step-number {
  font-family: var(--font-serif);
  font-size: 2rem;
  font-weight: 700;
  color: var(--border-strong);
  line-height: 1;
}

.step-badge {
  font-size: 0.68rem;
  font-weight: 700;
  background-color: var(--bg-subtle);
  padding: 0.15rem 0.45rem;
  border-radius: var(--radius-xs);
  color: var(--navy-800);
}

.step-badge-accent {
  font-size: 0.68rem;
  font-weight: 800;
  background-color: var(--terracotta-600);
  color: #ffffff;
  padding: 0.15rem 0.45rem;
  border-radius: var(--radius-xs);
}

.step-title {
  font-size: 1.15rem;
  color: var(--navy-900);
  margin-bottom: 0.65rem;
}

.step-desc {
  font-size: 0.84rem;
  color: var(--text-body);
  line-height: 1.5;
  margin-bottom: 1.25rem;
  flex-grow: 1;
}

.step-example {
  background-color: var(--bg-canvas);
  border: 1px solid var(--border-subtle);
  padding: 0.65rem 0.8rem;
  font-size: 0.78rem;
}

.ex-label {
  display: block;
  font-size: 0.68rem;
  color: var(--text-muted);
  margin-bottom: 0.15rem;
}

/* --------------------------------------------------------------------------
   13. FAQ SECTION (ACORDEÓN)
   -------------------------------------------------------------------------- */
.faq-section {
  padding: 3.5rem 0;
  background-color: var(--bg-canvas);
  border-top: 1px solid var(--border-default);
}

.faq-accordion-wrap {
  max-width: 840px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.faq-item {
  background-color: var(--bg-surface-elevated);
  border: 1px solid var(--border-default);
}

.faq-question {
  width: 100%;
  background: transparent;
  border: none;
  padding: 1.25rem 1.5rem;
  text-align: left;
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--navy-900);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.faq-icon {
  font-family: var(--font-sans);
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--terracotta-600);
  transition: transform 0.2s ease;
}

.faq-question[aria-expanded="true"] .faq-icon {
  transform: rotate(45deg);
}

.faq-answer {
  padding: 0 1.5rem 1.35rem;
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--text-body);
  border-top: 1px solid var(--border-subtle);
  padding-top: 1rem;
  display: none;
}

.faq-question[aria-expanded="true"] + .faq-answer {
  display: block;
}

.faq-answer ul {
  margin: 0.75rem 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.faq-answer li {
  position: relative;
  padding-left: 1.25rem;
}

.faq-answer li::before {
  content: '•';
  position: absolute;
  left: 0;
  color: var(--navy-900);
  font-size: 1.2rem;
  line-height: 1;
}

/* --------------------------------------------------------------------------
   14. FOOTER INSTITUCIONAL
   -------------------------------------------------------------------------- */
.site-footer {
  background-color: var(--navy-950);
  color: #cbd5e1;
  padding: 4rem 0 2rem;
  border-top: 4px solid var(--terracotta-600);
}

.footer-top-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1.2fr;
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-brand-col .brand-title {
  color: #ffffff;
}

.footer-brand-col .brand-sub {
  color: #94a3b8;
}

.footer-desc {
  font-size: 0.84rem;
  line-height: 1.6;
  color: #94a3b8;
  margin: 1rem 0 1.25rem;
}

.footer-badges {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.footer-tag {
  background-color: rgba(255, 255, 255, 0.08);
  color: #e2e8f0;
  font-size: 0.7rem;
  padding: 0.2rem 0.5rem;
  border-radius: var(--radius-xs);
}

.footer-col-title {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #ffffff;
  margin-bottom: 1.15rem;
}

.footer-list {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  font-size: 0.84rem;
}

.footer-list a {
  color: #94a3b8;
}

.footer-list a:hover {
  color: #ffffff;
}

.footer-note-text {
  font-size: 0.8rem;
  line-height: 1.5;
  color: #94a3b8;
}

.footer-bottom-bar {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.78rem;
  color: #64748b;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-bottom-links {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.footer-bottom-links a {
  color: #94a3b8;
}

.footer-bottom-links a:hover {
  color: #ffffff;
}

.btn-text-muted {
  background: none;
  border: none;
  color: #94a3b8;
  font-size: 0.78rem;
  cursor: pointer;
}

.btn-text-muted:hover {
  color: #ffffff;
}

/* --------------------------------------------------------------------------
   15. MODAL & TOAST STYLES
   -------------------------------------------------------------------------- */
.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(14, 28, 47, 0.65);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  padding: 1rem;
}

.modal-backdrop.open {
  display: flex;
}

.modal-dialog {
  background-color: #ffffff;
  width: 100%;
  max-width: 600px;
  border: 1px solid var(--border-default);
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
}

.modal-header {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border-default);
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  background-color: var(--bg-surface);
}

.modal-kicker {
  font-size: 0.7rem;
  font-weight: 800;
  color: var(--terracotta-700);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.modal-title {
  font-size: 1.35rem;
  color: var(--navy-900);
  margin-top: 0.15rem;
}

.btn-close-modal {
  background: none;
  border: none;
  font-size: 1.75rem;
  line-height: 1;
  color: var(--text-muted);
  cursor: pointer;
}

.modal-body {
  padding: 1.5rem;
}

.modal-intro {
  font-size: 0.85rem;
  color: var(--text-body);
  margin-bottom: 1rem;
}

.modal-recipient-selector {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: 1rem;
  background-color: var(--bg-canvas);
  padding: 0.75rem;
  border: 1px solid var(--border-subtle);
}

.modal-radio {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.82rem;
  cursor: pointer;
}

.text-preview-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-strong);
  padding: 1rem;
  max-height: 240px;
  overflow-y: auto;
}

.notification-text {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  line-height: 1.5;
  color: var(--navy-900);
  white-space: pre-wrap;
  word-break: break-word;
}

.modal-footer {
  padding: 1rem 1.5rem;
  background-color: var(--bg-surface);
  border-top: 1px solid var(--border-default);
  display: flex;
  justify-content: flex-end;
  gap: 0.75rem;
}

/* Toast Notification */
.toast-notification {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  background-color: var(--navy-950);
  color: #ffffff;
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-sm);
  border-left: 4px solid var(--terracotta-600);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.88rem;
  font-weight: 600;
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
  transition: all 0.3s ease;
  z-index: 3000;
}

.toast-notification.show {
  opacity: 1;
  transform: translateY(0);
}

/* --------------------------------------------------------------------------
   16. MEDIA QUERIES & RESPONSIVIDAD REAL
   -------------------------------------------------------------------------- */
@media (max-width: 1024px) {
  .hero-layout {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .calculator-grid {
    grid-template-columns: 1fr;
  }

  .steps-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-top-grid {
    grid-template-columns: 1fr 1fr;
  }

  .guide-grid {
    grid-template-columns: 1fr;
  }

  .timeline-meta-bar {
    grid-template-columns: 1fr 1fr;
  }

  .timeline-node-card {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .primary-nav, .hide-sm {
    display: none;
  }

  .mobile-menu-toggle {
    display: flex;
  }

  .hero-heading {
    font-size: 2.1rem;
  }

  .steps-grid {
    grid-template-columns: 1fr;
  }

  .form-row-2col {
    grid-template-columns: 1fr;
  }

  .frequency-grid {
    grid-template-columns: 1fr;
  }

  .footer-top-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .guide-pro-con-box {
    grid-template-columns: 1fr;
  }

  .timeline-meta-bar {
    grid-template-columns: 1fr;
  }

  .timeline-node-card {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }

  .mockup-badge span:last-child {
    display: none;
  }
}

/* --------------------------------------------------------------------------
   17. ESTILOS DE IMPRESIÓN (CERTIFICADO OFICIAL)
   -------------------------------------------------------------------------- */
@media print {
  .mockup-control-bar,
  .site-header,
  .hero-section,
  .form-card,
  .timeline-section,
  .indices-guide-section,
  .how-it-works-section,
  .faq-section,
  .site-footer,
  .result-actions-block,
  .modal-backdrop,
  .toast-notification {
    display: none !important;
  }

  body, .site-canvas, .app-viewport-wrapper {
    background: #ffffff !important;
    padding: 0 !important;
    margin: 0 !important;
  }

  .calculator-section {
    padding: 0 !important;
  }

  .calculator-grid {
    display: block !important;
  }

  .result-card {
    border: 2px solid #000000 !important;
    padding: 2cm !important;
  }

  .result-hero-box {
    border: 1px solid #000000 !important;
  }
}

/* ==========================================================================
   18. NEW CONTENT SECTIONS — HOMEPAGE CONTENT LAYOUT
   ========================================================================== */

/* --------------------------------------------------------------------------
   18.1 CONTENT SECTION BASE
   -------------------------------------------------------------------------- */
.content-section {
  padding: 4.5rem 0;
}

.content-section--alt {
  background-color: var(--bg-subtle);
}

.content-two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
  margin-top: 2rem;
}

.content-text-block {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.content-text-block p {
  font-size: 0.95rem;
  line-height: 1.72;
  color: var(--text-body);
}

/* --------------------------------------------------------------------------
   18.2 HERO / INTRO ENHANCEMENTS
   -------------------------------------------------------------------------- */
.intro-benefits-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin-top: 1.75rem;
}

.intro-benefit-card {
  background: var(--bg-surface-elevated, #ffffff);
  border: 1px solid var(--border-subtle, #e2e8f0);
  border-radius: var(--radius-lg, 12px);
  padding: 1.25rem 1.15rem;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.25s ease;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03), 0 1px 2px rgba(0, 0, 0, 0.02);
}

.intro-benefit-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--terracotta-600, #c25e3e), var(--terracotta-500, #ea580c));
  opacity: 0;
  transform: scaleX(0.2);
  transform-origin: left center;
  transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
}

.intro-benefit-card:hover::before {
  opacity: 1;
  transform: scaleX(1);
}

.intro-benefit-card:hover {
  border-color: rgba(194, 94, 62, 0.35);
  box-shadow: 0 10px 22px -4px rgba(15, 23, 42, 0.08), 0 4px 6px -2px rgba(15, 23, 42, 0.03);
  transform: translateY(-3px);
}

.benefit-icon {
  width: 40px;
  height: 40px;
  background-color: var(--terracotta-50, #fff7ed);
  border: 1px solid rgba(234, 88, 12, 0.12);
  border-radius: var(--radius-md, 10px);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.85rem;
  color: var(--terracotta-600, #c25e3e);
  transition: transform 0.25s ease, background-color 0.25s ease;
  flex-shrink: 0;
}

.benefit-icon svg {
  width: 20px;
  height: 20px;
}

.intro-benefit-card:hover .benefit-icon {
  transform: scale(1.06);
  background-color: #ffedd5;
  color: var(--terracotta-700, #9c4228);
}

.benefit-title {
  font-family: var(--font-sans);
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--navy-900, #0f172a);
  margin-bottom: 0.4rem;
  line-height: 1.35;
  letter-spacing: -0.01em;
}

.intro-benefit-card p {
  font-size: 0.82rem;
  line-height: 1.5;
  color: var(--text-muted, #64748b);
  margin: 0;
}

/* --------------------------------------------------------------------------
   18.3 WHAT IS THE RENTAL CALCULATOR (DEFINITION BLOCK)
   -------------------------------------------------------------------------- */
.what-is-calc-section {
  margin-top: 2.25rem;
  margin-bottom: 1.5rem;
}

.what-is-calc-card {
  background: var(--bg-surface-elevated, #ffffff);
  border: 1px solid var(--border-subtle, #e2e8f0);
  border-left: 4px solid var(--terracotta-600, #c25e3e);
  border-radius: var(--radius-lg, 12px);
  padding: 1.75rem 2rem;
  box-shadow: 0 2px 8px -2px rgba(15, 23, 42, 0.04), 0 1px 3px rgba(15, 23, 42, 0.02);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.what-is-calc-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px -4px rgba(15, 23, 42, 0.07);
}

.what-is-calc-title {
  font-family: var(--font-sans);
  font-size: 1.38rem;
  font-weight: 700;
  color: var(--navy-900, #0f172a);
  margin-bottom: 0.65rem;
  line-height: 1.3;
  letter-spacing: -0.015em;
}

.what-is-calc-desc {
  font-size: 0.98rem;
  line-height: 1.65;
  color: #475569;
  margin: 0;
}

@media (max-width: 640px) {
  .what-is-calc-card {
    padding: 1.25rem 1.15rem;
  }

  .what-is-calc-title {
    font-size: 1.2rem;
  }

  .what-is-calc-desc {
    font-size: 0.9rem;
    line-height: 1.55;
  }
}

/* Components Bar */
.intro-components-bar {
  margin-top: 2.5rem;
  padding: 1.25rem 1.5rem;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.components-label {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--navy-900);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.component-tags {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.component-tag {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-muted);
  background: var(--bg-subtle);
  padding: 0.3rem 0.75rem;
  border-radius: 100px;
  border: 1px solid var(--border-subtle);
}

/* --------------------------------------------------------------------------
   18.3 INTERACTIVE PIE CHART / DONUT
   -------------------------------------------------------------------------- */
.interactive-diagram {
  padding: 1.25rem;
}

.donut-chart-container {
  position: relative;
  width: 180px;
  height: 180px;
  margin: 0 auto 1rem;
}

.donut-svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.donut-center-label {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
}

.donut-total {
  display: block;
  font-family: var(--font-mono);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--navy-900);
}

.donut-subtitle {
  display: block;
  font-size: 0.68rem;
  color: var(--text-muted);
  margin-top: 0.15rem;
}

.donut-legend {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  font-size: 0.78rem;
}

.legend-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.3rem 0.5rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background 0.2s;
}

.legend-row:hover {
  background: var(--bg-subtle);
}

.legend-row-left {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.legend-color {
  width: 12px;
  height: 12px;
  border-radius: 3px;
  flex-shrink: 0;
}

.legend-row-right {
  font-family: var(--font-mono);
  font-weight: 600;
  color: var(--navy-900);
}

/* --------------------------------------------------------------------------
   18.4 FORMULA DISPLAY CARDS
   -------------------------------------------------------------------------- */
.formula-display-card {
  background: var(--navy-900);
  color: #ffffff;
  padding: 1rem 1.5rem;
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.formula-label {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.6);
}

.formula-expression {
  font-family: var(--font-mono);
  font-size: 0.92rem;
  color: #ffffff;
  background: transparent;
  padding: 0;
}

/* --------------------------------------------------------------------------
   18.5 DATA MINI CARDS (City Prices)
   -------------------------------------------------------------------------- */
.data-cards-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.75rem;
}

.data-mini-card {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 0.85rem;
  text-align: center;
  transition: var(--transition-smooth);
}

.data-mini-card:hover {
  border-color: var(--terracotta-500);
  box-shadow: var(--shadow-sm);
}

.data-city {
  display: block;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin-bottom: 0.3rem;
}

.data-value {
  font-family: var(--font-mono);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--terracotta-600);
}

/* --------------------------------------------------------------------------
   18.6 INTERACTIVE WIDGET CARDS
   -------------------------------------------------------------------------- */
.interactive-widget-card {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  position: sticky;
  top: 80px;
}

.widget-header {
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: var(--bg-subtle);
}

.widget-badge {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-inverse);
  background: var(--terracotta-600);
  padding: 0.2rem 0.5rem;
  border-radius: var(--radius-xs);
}

.widget-title {
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--navy-900);
}

/* --------------------------------------------------------------------------
   18.7 RENT ESTIMATOR WIDGET (Sliders)
   -------------------------------------------------------------------------- */
.estimator-widget {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.slider-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.slider-label-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.slider-label-row label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-body);
}

.slider-output {
  font-family: var(--font-mono);
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--terracotta-600);
  background: var(--terracotta-50);
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-sm);
}

.styled-range {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 6px;
  background: var(--bg-muted);
  border-radius: 3px;
  outline: none;
  cursor: pointer;
}

.styled-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 22px;
  height: 22px;
  background: var(--terracotta-600);
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(200, 82, 44, 0.35);
  transition: transform 0.15s ease;
}

.styled-range::-webkit-slider-thumb:hover {
  transform: scale(1.15);
}

.styled-range::-moz-range-thumb {
  width: 22px;
  height: 22px;
  background: var(--terracotta-600);
  border-radius: 50%;
  cursor: pointer;
  border: none;
  box-shadow: 0 2px 6px rgba(200, 82, 44, 0.35);
}

.range-limits {
  display: flex;
  justify-content: space-between;
  font-size: 0.7rem;
  color: var(--text-light);
}

.estimator-result-box {
  background: var(--navy-900);
  color: #ffffff;
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.estimator-result-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.estimator-result-row.sub {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding-top: 0.6rem;
}

.result-label-sm {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.7);
}

.result-value-lg {
  font-family: var(--font-mono);
  font-size: 1.35rem;
  font-weight: 700;
  color: #ffffff;
}

.result-value-md {
  font-family: var(--font-mono);
  font-size: 1rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.8);
}

/* --------------------------------------------------------------------------
   18.8 COST BREAKDOWN GRID
   -------------------------------------------------------------------------- */
.costs-breakdown-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin-top: 2rem;
}

.cost-card {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  transition: var(--transition-smooth);
  position: relative;
}

.cost-card:hover {
  border-color: var(--border-strong);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.cost-card--rent {
  border-color: var(--terracotta-500);
  border-width: 2px;
}

.cost-card--deposit {
  grid-column: span 2;
}

.cost-card-icon {
  width: 48px;
  height: 48px;
  background: var(--bg-subtle);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--navy-700);
  margin-bottom: 1rem;
}

.cost-card--rent .cost-card-icon {
  background: var(--terracotta-50);
  color: var(--terracotta-600);
}

.cost-card-title {
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--navy-900);
  margin-bottom: 0.35rem;
}

.cost-card-amount {
  font-family: var(--font-mono);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--terracotta-600);
  margin-bottom: 0.85rem;
}

.cost-card-desc {
  font-size: 0.82rem;
  line-height: 1.6;
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.cost-card-annual {
  border-top: 1px solid var(--border-subtle);
  padding-top: 0.85rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.82rem;
}

.cost-card-annual span {
  color: var(--text-muted);
}

.cost-card-annual strong {
  font-family: var(--font-mono);
  color: var(--navy-900);
}

/* --------------------------------------------------------------------------
   18.9 STACKED BAR CHART
   -------------------------------------------------------------------------- */
.stacked-cost-visual {
  margin-top: 3rem;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 2rem;
}

.visual-subtitle {
  font-family: var(--font-sans);
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--navy-900);
  margin-bottom: 1.5rem;
}

.stacked-bar-container {
  margin-bottom: 1rem;
}

.stacked-bar {
  display: flex;
  height: 52px;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.stacked-segment {
  display: flex;
  align-items: center;
  justify-content: center;
  transition: filter 0.2s, flex 0.5s ease;
  cursor: pointer;
  position: relative;
}

.stacked-segment:hover {
  filter: brightness(1.1);
}

.stacked-segment::after {
  content: attr(data-label);
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--navy-900);
  color: #ffffff;
  padding: 0.3rem 0.65rem;
  border-radius: var(--radius-sm);
  font-size: 0.72rem;
  font-weight: 600;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
  z-index: 10;
}

.stacked-segment:hover::after {
  opacity: 1;
}

.seg-text {
  font-size: 0.72rem;
  font-weight: 700;
  color: #ffffff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.seg-rent {
  background: linear-gradient(135deg, var(--terracotta-600), var(--terracotta-500));
}

.seg-community {
  background: var(--navy-700);
}

.seg-ibi {
  background: var(--gold-700);
}

.seg-utilities {
  background: var(--forest-700);
}

.stacked-total-label {
  text-align: right;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 0.6rem;
}

.stacked-total-label strong {
  font-family: var(--font-mono);
  color: var(--navy-900);
}

.stacked-legend {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 2px;
  flex-shrink: 0;
}

.dot-rent { background: var(--terracotta-600); }
.dot-community { background: var(--navy-700); }
.dot-ibi { background: var(--gold-700); }
.dot-utilities { background: var(--forest-700); }

/* --------------------------------------------------------------------------
   18.10 BUDGET GAUGE WIDGET
   -------------------------------------------------------------------------- */
.gauge-widget {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.gauge-input-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.gauge-input-group label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-body);
}

.gauge-visual-container {
  display: flex;
  justify-content: center;
}

.gauge-svg {
  width: 200px;
  height: 130px;
}

#gaugeNeedle {
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.gauge-result-box {
  text-align: center;
  padding: 1rem;
  border-radius: var(--radius-lg);
  transition: background 0.3s;
}

.gauge-result-box.status-ok {
  background: var(--forest-100);
}

.gauge-result-box.status-warning {
  background: var(--gold-100);
}

.gauge-result-box.status-danger {
  background: var(--terracotta-100);
}

.gauge-pct {
  font-family: var(--font-mono);
  font-size: 2rem;
  font-weight: 700;
  color: var(--navy-900);
}

.gauge-verdict {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--navy-900);
  margin-top: 0.25rem;
}

.gauge-detail {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 0.3rem;
}

/* --------------------------------------------------------------------------
   18.11 BUDGET TABLE
   -------------------------------------------------------------------------- */
.budget-examples-table {
  margin-top: 0.5rem;
}

.mini-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}

.mini-table th {
  background: var(--navy-900);
  color: #ffffff;
  padding: 0.65rem 0.85rem;
  text-align: left;
  font-weight: 600;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.mini-table th:first-child {
  border-radius: var(--radius-md) 0 0 0;
}

.mini-table th:last-child {
  border-radius: 0 var(--radius-md) 0 0;
}

.mini-table td {
  padding: 0.6rem 0.85rem;
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-body);
}

.mini-table tbody tr:hover {
  background: var(--bg-subtle);
}

.mini-table tbody tr:last-child td:first-child {
  border-radius: 0 0 0 var(--radius-md);
}

.mini-table tbody tr:last-child td:last-child {
  border-radius: 0 0 var(--radius-md) 0;
}

/* --------------------------------------------------------------------------
   18.12 UPDATE RULES GRID (Topes de Subida)
   -------------------------------------------------------------------------- */
.update-rules-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.85rem;
  margin-top: 0.5rem;
}

.rule-card {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1rem;
  text-align: center;
  transition: var(--transition-smooth);
}

.rule-card:hover {
  border-color: var(--border-strong);
}

.rule-card--active {
  border-color: var(--terracotta-500);
  background: var(--terracotta-50);
}

.rule-year {
  display: block;
  font-family: var(--font-mono);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--navy-900);
}

.rule-limit {
  display: block;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--terracotta-600);
  margin-top: 0.3rem;
}

.rule-desc {
  display: block;
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
}

/* --------------------------------------------------------------------------
   18.13 IPC TIMELINE WIDGET
   -------------------------------------------------------------------------- */
.ipc-timeline-widget {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.timeline-input-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  justify-content: space-between;
}

.timeline-input-row label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-body);
  white-space: nowrap;
}

.form-control-sm {
  padding: 0.4rem 0.6rem;
  font-size: 0.85rem;
  width: 100px;
  text-align: right;
}

.timeline-bars-container {
  display: flex;
  align-items: flex-end;
  gap: 0.65rem;
  height: 160px;
  padding: 0.5rem 0;
}

.timeline-bar-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  height: 100%;
  justify-content: flex-end;
}

.timeline-bar {
  width: 100%;
  min-height: 20px;
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
  transition: height 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  position: relative;
}

.timeline-bar:hover {
  filter: brightness(1.12);
}

.timeline-bar-value {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--navy-900);
}

.timeline-bar-year {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-muted);
}

.timeline-summary {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  color: var(--text-body);
  border-top: 1px solid var(--border-subtle);
  padding-top: 1rem;
}

.timeline-summary strong {
  font-family: var(--font-mono);
  color: var(--terracotta-600);
}

/* --------------------------------------------------------------------------
   18.14 EXAMPLES GRID
   -------------------------------------------------------------------------- */
.examples-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 2rem;
}

.example-card {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  overflow: hidden;
  transition: var(--transition-smooth);
}

.example-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px);
}

.example-header {
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  background: var(--bg-subtle);
  border-bottom: 1px solid var(--border-subtle);
}

.example-number {
  font-family: var(--font-mono);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--terracotta-600);
  line-height: 1;
}

.example-meta {
  flex: 1;
}

.example-title {
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--navy-900);
  margin-bottom: 0.25rem;
}

.example-tag {
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  background: var(--bg-surface-elevated);
  padding: 0.15rem 0.5rem;
  border-radius: 100px;
}

.example-body {
  padding: 1.25rem 1.5rem;
}

.example-step {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.45rem 0;
  font-size: 0.85rem;
}

.example-step .step-label {
  color: var(--text-muted);
}

.example-step .step-value {
  font-family: var(--font-mono);
  font-weight: 600;
  color: var(--navy-900);
  text-align: right;
}

.example-step.highlight {
  background: var(--terracotta-50);
  margin: 0.3rem -1.5rem;
  padding: 0.65rem 1.5rem;
  border-radius: 0;
}

.example-step.highlight .step-value {
  color: var(--terracotta-700);
}

.example-step.total {
  border-top: 2px solid var(--navy-900);
  margin-top: 0.3rem;
  padding-top: 0.7rem;
}

.example-step.total .step-label {
  font-weight: 700;
  color: var(--navy-900);
}

.example-divider {
  height: 1px;
  background: var(--border-subtle);
  margin: 0.5rem 0;
}

.example-annual {
  margin-top: 1rem;
  padding: 0.85rem;
  background: var(--navy-900);
  color: #ffffff;
  border-radius: var(--radius-md);
  font-size: 0.82rem;
  text-align: center;
}

.example-annual strong {
  font-family: var(--font-mono);
}

/* --------------------------------------------------------------------------
   18.15 COMPARISON TABLE
   -------------------------------------------------------------------------- */
.comparison-filters {
  display: flex;
  gap: 0.5rem;
  margin-top: 1.5rem;
  margin-bottom: 1.5rem;
}

.filter-btn {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-default);
  padding: 0.55rem 1.25rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-body);
  border-radius: 100px;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.filter-btn:hover {
  border-color: var(--terracotta-500);
  color: var(--terracotta-600);
}

.filter-btn.active {
  background: var(--navy-900);
  color: #ffffff;
  border-color: var(--navy-900);
}

.comparison-table-wrapper {
  overflow-x: auto;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-default);
  box-shadow: var(--shadow-sm);
}

.comparison-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.comparison-table thead th {
  background: var(--navy-900);
  color: #ffffff;
  padding: 0.85rem 1.15rem;
  text-align: left;
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  position: relative;
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
}

.comparison-table thead th.sortable:hover {
  background: var(--navy-800);
}

.comparison-table thead th.sortable::after {
  content: '↕';
  margin-left: 0.4rem;
  font-size: 0.7rem;
  opacity: 0.5;
}

.comparison-table tbody td {
  padding: 0.75rem 1.15rem;
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-surface-elevated);
}

.comparison-table tbody tr:hover td {
  background: var(--bg-subtle);
}

.comparison-table tbody td:first-child {
  font-weight: 700;
  color: var(--navy-900);
}

.variation-up {
  color: var(--terracotta-700);
  font-weight: 600;
}

.variation-down {
  color: var(--forest-700);
  font-weight: 600;
}

.comparison-source-note {
  margin-top: 1.25rem;
  font-size: 0.78rem;
  color: var(--text-light);
  line-height: 1.6;
}

/* --------------------------------------------------------------------------
   18.16 FAQ ACCORDION (updated styles)
   -------------------------------------------------------------------------- */
.faq-accordion-wrap {
  margin-top: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.faq-item {
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: var(--transition-smooth);
  background: var(--bg-surface-elevated);
}

.faq-item:hover {
  border-color: var(--border-strong);
}

.faq-item.active {
  border-color: var(--terracotta-500);
  box-shadow: var(--shadow-md);
}

.faq-question {
  width: 100%;
  background: transparent;
  border: none;
  padding: 1.15rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  text-align: left;
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--navy-900);
  gap: 1rem;
  transition: background 0.2s;
}

.faq-question:hover {
  background: var(--bg-subtle);
}

.faq-icon {
  font-size: 1.3rem;
  font-weight: 300;
  color: var(--terracotta-600);
  transition: transform 0.3s ease;
  flex-shrink: 0;
  width: 24px;
  text-align: center;
}

.faq-item.active .faq-icon {
  transform: rotate(45deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.16, 1, 0.3, 1), padding 0.3s;
  padding: 0 1.5rem;
}

.faq-item.active .faq-answer {
  max-height: 600px;
  padding: 0 1.5rem 1.25rem;
}

.faq-answer p {
  font-size: 0.88rem;
  line-height: 1.72;
  color: var(--text-body);
}

/* ==========================================================================
   19. RESPONSIVE — CONTENT SECTIONS
   ========================================================================== */
@media (max-width: 1024px) {
  .intro-benefits-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .content-two-col {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .interactive-widget-card {
    position: static;
  }

  .costs-breakdown-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .cost-card--deposit {
    grid-column: span 1;
  }

  .examples-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .content-section {
    padding: 3rem 0;
  }

  .intro-benefits-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .intro-components-bar {
    flex-direction: column;
    align-items: flex-start;
  }

  .data-cards-row {
    grid-template-columns: repeat(2, 1fr);
  }

  .costs-breakdown-grid {
    grid-template-columns: 1fr;
  }

  .update-rules-grid {
    grid-template-columns: 1fr;
  }

  .comparison-filters {
    flex-wrap: wrap;
  }

  .stacked-legend {
    flex-direction: column;
    gap: 0.5rem;
  }

  .timeline-input-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.4rem;
  }

  .form-control-sm {
    width: 100%;
  }

  .timeline-summary {
    flex-direction: column;
    gap: 0.4rem;
  }

  .hero-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .data-cards-row {
    grid-template-columns: 1fr 1fr;
  }

  .mini-table {
    font-size: 0.78rem;
  }

  .mini-table th,
  .mini-table td {
    padding: 0.45rem 0.5rem;
  }

  .example-step {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.15rem;
  }

  .example-step .step-value {
    text-align: left;
  }
}

/* ==========================================================================
   20. NEW INTERACTIVE ELEMENTS — HOMEPAGE
   ========================================================================== */

/* --------------------------------------------------------------------------
   20.1 HERO SUB TEXT
   -------------------------------------------------------------------------- */
.hero-sub-text {
  font-size: 0.92rem;
  line-height: 1.72;
  color: var(--text-body);
  margin-top: 0.5rem;
}

/* --------------------------------------------------------------------------
   20.2 HOW FLOW DIAGRAM
   -------------------------------------------------------------------------- */
.how-flow-diagram {
  margin-top: 3rem;
  padding: 2.5rem;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  overflow: hidden;
}

.flow-diagram-title {
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--navy-900);
  margin-bottom: 2rem;
  text-align: center;
}

.flow-steps-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.flow-step-item {
  flex: 0 1 160px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 1.25rem 1rem;
  background: var(--bg-canvas);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  transition: var(--transition-smooth);
}

.flow-step-item:hover {
  border-color: var(--border-strong);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.flow-step-item--result {
  border-color: var(--terracotta-500);
  background: var(--terracotta-50);
}

.flow-step-icon {
  width: 52px;
  height: 52px;
  background: var(--bg-subtle);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--navy-700);
  margin-bottom: 0.75rem;
  transition: var(--transition-smooth);
}

.flow-step-item--result .flow-step-icon {
  background: var(--terracotta-600);
  color: #ffffff;
}

.flow-step-item:hover .flow-step-icon {
  transform: scale(1.08);
}

.flow-step-label {
  font-family: var(--font-sans);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--navy-900);
  margin-bottom: 0.25rem;
}

.flow-step-desc {
  font-size: 0.72rem;
  color: var(--text-muted);
  line-height: 1.4;
}

.flow-connector {
  display: flex;
  align-items: center;
  color: var(--border-strong);
  flex-shrink: 0;
}

/* --------------------------------------------------------------------------
   20.3 PRICE FACTORS VISUAL
   -------------------------------------------------------------------------- */
.price-factors-visual {
  margin-top: 2rem;
  padding: 1.5rem;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
}

.factor-bars-container {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
  margin-top: 1rem;
}

.factor-bar-item {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.factor-bar-label {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.factor-name {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--navy-900);
}

.factor-impact {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
}

.factor-bar-track {
  height: 10px;
  background: var(--bg-muted);
  border-radius: 5px;
  overflow: hidden;
}

.factor-bar-fill {
  height: 100%;
  border-radius: 5px;
  transition: width 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.factor-bar--high {
  background: linear-gradient(90deg, var(--terracotta-600), var(--terracotta-500));
}

.factor-bar--medium {
  background: linear-gradient(90deg, var(--navy-700), var(--navy-600));
}

/* --------------------------------------------------------------------------
   20.4 INTERACTIVE COST CALCULATOR
   -------------------------------------------------------------------------- */
.interactive-cost-calc {
  margin-top: 3rem;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-md);
}

.cost-calc-header {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  gap: 1rem;
  background: var(--bg-subtle);
}

.cost-calc-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  padding: 1.5rem;
}

.cost-calc-rent-input {
  margin-bottom: 1.25rem;
}

.cost-calc-rent-input label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-body);
  margin-bottom: 0.4rem;
}

.input-currency-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.currency-prefix {
  position: absolute;
  left: 0.85rem;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-muted);
  pointer-events: none;
}

.input-currency-wrapper .form-control {
  padding-left: 2rem;
}

.cost-toggle-list {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.cost-toggle-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 0.85rem;
  background: var(--bg-canvas);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: var(--transition-smooth);
}

.cost-toggle-item:hover {
  border-color: var(--border-strong);
}

.cost-toggle-item input[type="checkbox"] {
  display: none;
}

.toggle-switch {
  width: 36px;
  height: 20px;
  background: var(--bg-muted);
  border-radius: 10px;
  position: relative;
  flex-shrink: 0;
  transition: background 0.25s ease;
}

.toggle-switch::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  background: #ffffff;
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(0,0,0,0.2);
  transition: transform 0.25s ease;
}

.cost-toggle-item input:checked + .toggle-switch {
  background: var(--terracotta-600);
}

.cost-toggle-item input:checked + .toggle-switch::after {
  transform: translateX(16px);
}

.toggle-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-body);
  flex: 1;
}

.toggle-amount {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--terracotta-600);
  flex-shrink: 0;
}

.cost-result-visual {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.cost-result-bar-container {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.cost-result-bar-row {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.cost-bar-label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  width: 80px;
  flex-shrink: 0;
  text-align: right;
}

.cost-bar-track {
  flex: 1;
  height: 24px;
  background: var(--bg-muted);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.cost-bar-fill {
  height: 100%;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  padding-left: 0.5rem;
  transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.cost-bar-fill span {
  font-size: 0.68rem;
  font-weight: 700;
  color: #ffffff;
  white-space: nowrap;
}

.cost-bar--rent { background: linear-gradient(90deg, var(--terracotta-600), var(--terracotta-500)); }
.cost-bar--comunidad { background: var(--navy-700); }
.cost-bar--ibi { background: var(--gold-700); }
.cost-bar--suministros { background: var(--forest-700); }
.cost-bar--seguro { background: #8b5cf6; }

.cost-result-total,
.cost-result-annual {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.85rem 1rem;
  background: var(--navy-900);
  border-radius: var(--radius-md);
  color: #ffffff;
}

.cost-result-annual {
  background: var(--bg-subtle);
  color: var(--navy-900);
}

.cost-result-label {
  font-size: 0.82rem;
}

.cost-result-value {
  font-family: var(--font-mono);
  font-size: 1.35rem;
  font-weight: 700;
}

.cost-result-value-sm {
  font-family: var(--font-mono);
  font-size: 1rem;
  font-weight: 700;
  color: var(--terracotta-600);
}

/* --------------------------------------------------------------------------
   20.5 INCOME VS RENT VISUAL
   -------------------------------------------------------------------------- */
.income-rent-visual {
  margin-top: 2rem;
  padding: 1.5rem;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
}

.income-bar-track {
  display: flex;
  height: 48px;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  margin-top: 1rem;
}

.income-bar-segment {
  display: flex;
  align-items: center;
  justify-content: center;
  transition: filter 0.2s, flex 0.5s ease;
  cursor: pointer;
  position: relative;
}

.income-bar-segment:hover {
  filter: brightness(1.1);
}

.income-bar-text {
  font-size: 0.72rem;
  font-weight: 700;
  color: #ffffff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  white-space: nowrap;
}

.income-bar--rent { background: linear-gradient(135deg, var(--terracotta-600), var(--terracotta-500)); }
.income-bar--expenses { background: var(--navy-700); }
.income-bar--savings { background: var(--forest-700); }
.income-bar--other { background: var(--gold-700); }

.income-bar-labels {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-top: 1rem;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.income-bar-labels span {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

/* --------------------------------------------------------------------------
   20.6 RENT UPDATE FLOW DIAGRAM
   -------------------------------------------------------------------------- */
.rent-update-flow {
  margin-bottom: 2.5rem;
  padding: 2rem;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
}

.update-flow-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1.5rem;
  flex-wrap: wrap;
}

.update-flow-step {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 1rem 1.25rem;
  background: var(--bg-canvas);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  min-width: 140px;
  transition: var(--transition-smooth);
}

.update-flow-step:hover {
  border-color: var(--border-strong);
  box-shadow: var(--shadow-sm);
}

.update-flow-step--result {
  border-color: var(--terracotta-500);
  background: var(--terracotta-50);
}

.update-flow-number {
  width: 32px;
  height: 32px;
  background: var(--navy-900);
  color: #ffffff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 700;
  flex-shrink: 0;
}

.update-flow-step--result .update-flow-number {
  background: var(--terracotta-600);
}

.update-flow-content {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.update-flow-content strong {
  font-size: 0.82rem;
  color: var(--navy-900);
}

.update-flow-value {
  font-family: var(--font-mono);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--terracotta-600);
}

.update-flow-value.mono {
  font-size: 0.88rem;
}

.update-flow-arrow {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

/* --------------------------------------------------------------------------
   20.7 CITY BARS CHART
   -------------------------------------------------------------------------- */
.city-bars-chart {
  margin-bottom: 2.5rem;
  padding: 2rem;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
}

.city-bars-container {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  margin-top: 1.5rem;
}

.city-bar-row {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.city-bar-name {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--navy-900);
  width: 90px;
  flex-shrink: 0;
  text-align: right;
}

.city-bar-track {
  flex: 1;
  height: 32px;
  background: var(--bg-muted);
  border-radius: var(--radius-sm);
  overflow: hidden;
  position: relative;
}

.city-bar-fill {
  height: 100%;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  padding: 0 0.75rem;
  justify-content: flex-end;
  transition: width 1s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
}

.city-bar-fill:hover {
  filter: brightness(1.12);
}

.city-bar-fill span {
  font-size: 0.72rem;
  font-weight: 700;
  color: #ffffff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  white-space: nowrap;
}

.city-bar-value {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--navy-900);
  width: 70px;
  flex-shrink: 0;
}

.city-bars-source {
  margin-top: 1rem;
  font-size: 0.72rem;
  color: var(--text-light);
}

/* --------------------------------------------------------------------------
   20.8 RESPONSIVE — NEW ELEMENTS
   -------------------------------------------------------------------------- */
@media (max-width: 1024px) {
  .cost-calc-body {
    grid-template-columns: 1fr;
  }

  .update-flow-steps {
    flex-direction: column;
  }

  .update-flow-arrow {
    transform: rotate(90deg);
  }
}

@media (max-width: 768px) {
  .how-flow-diagram {
    padding: 1.5rem;
  }

  .flow-steps-row {
    flex-direction: column;
    gap: 0.75rem;
  }

  .flow-connector {
    transform: rotate(90deg);
  }

  .flow-step-item {
    flex: 1 1 100%;
    max-width: 240px;
  }

  .city-bar-name {
    width: 65px;
    font-size: 0.75rem;
  }

  .city-bar-value {
    width: 55px;
    font-size: 0.75rem;
  }

  .income-bar-track {
    height: 36px;
  }

  .income-bar-labels {
    flex-direction: column;
    gap: 0.4rem;
  }

  .rent-update-flow {
    padding: 1.25rem;
  }
}

/* --------------------------------------------------------------------------
   21. TOOLS SHOWCASE SECTION — CALCULATOR CARDS GRID
   -------------------------------------------------------------------------- */
.tools-showcase-section {
  padding: 4.5rem 0;
  background-color: var(--bg-canvas);
  border-top: 1px solid var(--border-default);
}

/* ==========================================================================
   HERRAMIENTAS MASTER PANEL — ICON & TITLE MINIMAL SUITE
   ========================================================================== */

.tools-master-panel {
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: 24px;
  box-shadow: 0 20px 45px -15px rgba(15, 23, 42, 0.07),
              0 1px 3px rgba(0, 0, 0, 0.04);
  padding: 2.5rem 2.25rem 2.5rem;
  position: relative;
  overflow: hidden;
}

.tools-master-panel::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #4f46e5 0%, #059669 35%, #c8522c 70%, #7c3aed 100%);
}

.tools-master-header {
  padding-bottom: 1.5rem;
  border-bottom: 1px solid #e2e8f0;
  margin-bottom: 1.75rem;
}

.tools-master-title {
  font-family: var(--font-serif);
  font-size: 1.85rem;
  font-weight: 700;
  color: var(--navy-900);
  line-height: 1.25;
  margin: 0 0 0.4rem;
  letter-spacing: -0.02em;
}

.tools-master-subtitle {
  font-size: 0.92rem;
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0;
}

/* Minimal Rows: 4 in row 1, 3 in row 2 */
.tools-minimal-row {
  display: grid;
  gap: 1rem;
}

.tools-minimal-row--4 {
  grid-template-columns: repeat(4, 1fr);
  margin-bottom: 1rem;
}

.tools-minimal-row--3 {
  grid-template-columns: repeat(3, 1fr);
}

/* Minimal Tool Card (Only Icon + Name + Arrow) */
.tool-minimal-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 1.1rem 1.2rem;
  display: flex;
  align-items: center;
  gap: 0.95rem;
  text-decoration: none;
  color: var(--navy-900);
  box-shadow: 0 2px 4px rgba(15, 23, 42, 0.02);
  transition: transform 0.22s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow 0.22s cubic-bezier(0.16, 1, 0.3, 1),
              border-color 0.22s ease;
  position: relative;
  overflow: hidden;
}

.tool-minimal-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 22px -4px rgba(15, 23, 42, 0.09);
  color: var(--navy-900);
}

.tool-minimal-card--icl:hover { border-color: rgba(79, 70, 229, 0.45); }
.tool-minimal-card--ipc:hover { border-color: rgba(5, 150, 105, 0.45); }
.tool-minimal-card--ripte:hover { border-color: rgba(217, 119, 6, 0.45); }
.tool-minimal-card--aumento:hover { border-color: rgba(200, 82, 44, 0.45); }
.tool-minimal-card--ley:hover { border-color: rgba(37, 99, 235, 0.45); }
.tool-minimal-card--dolares:hover { border-color: rgba(22, 163, 74, 0.45); }
.tool-minimal-card--comercial:hover { border-color: rgba(124, 58, 237, 0.45); }

.tool-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.22s ease;
  flex-shrink: 0;
}

.tool-minimal-card:hover .tool-icon {
  transform: scale(1.1);
}

.tool-icon--icl {
  background: #eef2ff;
  color: #4338ca;
  border: 1px solid rgba(67, 56, 202, 0.15);
}

.tool-icon--ipc {
  background: #ecfdf5;
  color: #059669;
  border: 1px solid rgba(5, 150, 105, 0.15);
}

.tool-icon--ripte {
  background: #fef3c7;
  color: #b45309;
  border: 1px solid rgba(180, 83, 9, 0.15);
}

.tool-icon--aumento {
  background: var(--terracotta-50);
  color: var(--terracotta-600);
  border: 1px solid rgba(200, 82, 44, 0.15);
}

.tool-icon--ley {
  background: #eff6ff;
  color: #1d4ed8;
  border: 1px solid rgba(29, 78, 216, 0.15);
}

.tool-icon--dolares {
  background: #f0fdf4;
  color: #15803d;
  border: 1px solid rgba(21, 128, 61, 0.15);
}

.tool-icon--comercial {
  background: #f5f3ff;
  color: #7c3aed;
  border: 1px solid rgba(124, 58, 237, 0.15);
}

.tool-title {
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--navy-900);
  line-height: 1.3;
  margin: 0;
  flex-grow: 1;
}

.tool-arrow {
  font-size: 1.1rem;
  font-weight: 700;
  color: #94a3b8;
  transition: transform 0.22s ease, color 0.22s ease;
  flex-shrink: 0;
}

.tool-minimal-card:hover .tool-arrow {
  transform: translateX(4px);
  color: var(--terracotta-600);
}

/* Responsive Minimal Master Panel */
@media (max-width: 1100px) {
  .tools-minimal-row--4,
  .tools-minimal-row--3 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .tools-master-panel {
    padding: 1.5rem 1.1rem;
    border-radius: 18px;
  }
  .tools-master-title {
    font-size: 1.45rem;
  }
  .tools-minimal-row--4,
  .tools-minimal-row--3 {
    grid-template-columns: 1fr;
  }
  .tool-minimal-card {
    padding: 1rem 1rem;
  }
}

/* --------------------------------------------------------------------------
   LANGUAGE PICKER
   -------------------------------------------------------------------------- */
.language-picker-wrap {
  display: inline-flex;
  align-items: center;
}

.lang-select {
  appearance: none;
  -webkit-appearance: none;
  background-color: var(--bg-surface, #faf8f5);
  border: 1px solid var(--border-default, #ddd6c9);
  color: var(--text-main, #0e1c2f);
  font-family: var(--font-sans, sans-serif);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.35rem 1.6rem 0.35rem 0.65rem;
  border-radius: 4px;
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath fill='none' stroke='%230e1c2f' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round' d='M1 1l4 4 4-4'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.5rem center;
  background-size: 8px 5px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.lang-select:hover,
.lang-select:focus {
  outline: none;
  border-color: var(--navy-900, #0e1c2f);
  box-shadow: 0 0 0 2px rgba(14, 28, 47, 0.08);
}

