/* =============================================================
   CalcFinanza — Premium Template Styles
   ============================================================= */

/* ── 1. Design tokens ──────────────────────────────────────── */
:root {
  --verde-900: #1b4332;
  --verde-800: #2d6a4f;
  --verde-700: #40916c;
  --verde-600: #52b788;
  --verde-100: #d8f3dc;
  --verde-50: #edf7ef;
  --dorado: #d4a843;
  --dorado-light: #e8c96a;
  --dorado-dark: #b8922e;
  --dorado-glow: rgba(212,168,67,.18);
  --cream: #fdfbf7;
  --white: #ffffff;
  --gray-50: #f7f8fa;
  --gray-100: #f1f3f5;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-400: #9ca3af;
  --gray-500: #6b7280;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --gray-800: #1f2937;
  --gray-900: #111827;
  --blue-50: #eff6ff;
  --blue-100: #dbeafe;
  --blue-600: #2563eb;
  --bg: var(--cream);
  --text: var(--gray-800);
  --accent: var(--verde-900);
  --accent-mid: var(--verde-700);
  --highlight: var(--dorado);
  --sans: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
  --display: "Playfair Display", "Georgia", serif;
  --radius-xl: 24px;
  --radius: 16px;
  --radius-md: 12px;
  --radius-sm: 10px;
  --radius-xs: 6px;
  --shadow-xs: 0 1px 2px rgba(0,0,0,.04);
  --shadow-sm: 0 2px 8px rgba(0,0,0,.05);
  --shadow-md: 0 4px 20px rgba(0,0,0,.07);
  --shadow-lg: 0 12px 40px rgba(0,0,0,.09);
  --shadow-xl: 0 24px 60px rgba(0,0,0,.12);
  --shadow-gold: 0 4px 20px rgba(212,168,67,.25);
  --ease: cubic-bezier(.4,0,.2,1);
  --ease-out: cubic-bezier(.16,1,.3,1);
  --ease-spring: cubic-bezier(.34,1.56,.64,1);
}

/* ── 2. Reset & base ───────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; }
html { -webkit-text-size-adjust: 100%; tab-size: 2; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  [data-reveal] { opacity: 1 !important; transform: none !important; }
}
body {
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
  overscroll-behavior-y: none;
  background: var(--bg);
  color: var(--text);
}
img, svg, video { display: block; max-width: 100%; }
img { height: auto; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
a { color: inherit; text-decoration: none; }
p { text-wrap: pretty; }
h1, h2, h3, h4 { text-wrap: balance; }
::selection { background: var(--dorado); color: var(--white); }
:focus-visible {
  outline: 2px solid var(--dorado);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ── 3. Utilities ──────────────────────────────────────────── */
.skip-link {
  position: fixed; top: -100px; left: 1rem;
  padding: .6rem 1rem; background: var(--accent); color: var(--white);
  z-index: 9999; border-radius: var(--radius-sm); font-weight: 500;
}
.skip-link:focus { top: 1rem; }
.container {
  width: 100%;
  max-width: 1120px;
  margin-inline: auto;
  padding-inline: 1.25rem;
}

/* Section label (small caps pill above h2) */
.section-label {
  display: inline-block;
  padding: 0.3rem 0.85rem;
  background: var(--verde-50);
  color: var(--verde-700);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border-radius: 100px;
  border: 1px solid var(--verde-100);
  margin-bottom: 0.6rem;
}

/* Reveal animation */
[data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .7s var(--ease), transform .7s var(--ease);
}
[data-reveal].revealed {
  opacity: 1;
  transform: translateY(0);
}

/* ── 4. Typography ─────────────────────────────────────────── */
h1 {
  font-family: var(--display);
  font-size: clamp(2rem, 6vw, 3.5rem);
  font-weight: 800;
  color: var(--white);
  line-height: 1.08;
  letter-spacing: -0.02em;
}
h2 {
  font-family: var(--display);
  font-size: clamp(1.5rem, 4vw, 2.25rem);
  font-weight: 700;
  color: var(--accent);
  line-height: 1.15;
  letter-spacing: -0.01em;
}
h3 {
  font-size: 1.08rem;
  font-weight: 700;
  color: var(--gray-800);
  line-height: 1.3;
}
.text-gold {
  background: linear-gradient(135deg, var(--dorado-light) 0%, var(--dorado) 50%, var(--dorado-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── 5. Header ─────────────────────────────────────────────── */
.site-header {
  background: var(--verde-900);
  color: var(--white);
  padding: 0.75rem 0;
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logo {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  transition: opacity .2s;
}
.logo:hover { opacity: .88; }
.logo-icon {
  width: 34px;
  height: 34px;
  background: linear-gradient(135deg, var(--dorado) 0%, var(--dorado-light) 100%);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.82rem;
  color: var(--verde-900);
  font-weight: 800;
  font-family: var(--sans);
  box-shadow: 0 2px 8px rgba(212,168,67,.3);
}
.logo-text {
  font-family: var(--display);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--white);
}
.logo-gold { color: var(--dorado-light); }
.header-nav {
  display: flex;
  gap: 0.4rem;
  align-items: center;
}
.header-nav a {
  color: rgba(255,255,255,.72);
  font-size: 0.85rem;
  font-weight: 500;
  padding: 0.35rem 0.7rem;
  border-radius: var(--radius-xs);
  transition: color .2s var(--ease), background .2s var(--ease);
}
.header-nav a:hover {
  color: var(--white);
  background: rgba(255,255,255,.08);
}

/* ── 6. Hero ───────────────────────────────────────────────── */
.hero {
  background: linear-gradient(160deg, #0f2a1f 0%, var(--verde-900) 40%, var(--verde-800) 100%);
  padding: 5rem 0 7rem;
  text-align: center;
  color: var(--white);
  position: relative;
  overflow: hidden;
}
.hero-inner { position: relative; z-index: 2; }

/* Floating decorative shapes */
.hero-shape {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}
.hero-shape--1 {
  width: 500px; height: 500px;
  top: -200px; right: -120px;
  background: radial-gradient(circle, rgba(212,168,67,.1) 0%, transparent 65%);
}
.hero-shape--2 {
  width: 350px; height: 350px;
  bottom: -100px; left: -80px;
  background: radial-gradient(circle, rgba(64,145,108,.15) 0%, transparent 65%);
}
.hero-shape--3 {
  width: 200px; height: 200px;
  top: 30%; left: 15%;
  background: radial-gradient(circle, rgba(255,255,255,.04) 0%, transparent 65%);
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 1rem 0.4rem 0.7rem;
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 100px;
  font-size: 0.82rem;
  font-weight: 600;
  color: rgba(255,255,255,.92);
  margin-bottom: 1.5rem;
  backdrop-filter: blur(6px);
}
.hero-badge svg {
  width: 16px; height: 16px;
  color: var(--dorado-light);
  flex-shrink: 0;
}

.hero-subtitle {
  margin: 1rem auto 0;
  font-size: clamp(.95rem, 2.5vw, 1.12rem);
  color: rgba(255,255,255,.78);
  max-width: 560px;
  line-height: 1.65;
}

.trust-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6rem;
  margin-top: 1.75rem;
}
.trust-pill {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 0.95rem;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 500;
  color: rgba(255,255,255,.82);
  backdrop-filter: blur(4px);
}
.trust-pill svg {
  width: 14px; height: 14px;
  color: var(--dorado-light);
  flex-shrink: 0;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 2rem;
  padding: 0.85rem 2rem;
  background: linear-gradient(135deg, var(--dorado) 0%, var(--dorado-dark) 100%);
  color: var(--white);
  font-size: 1rem;
  font-weight: 700;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-gold);
  text-shadow: 0 1px 2px rgba(0,0,0,.12);
  transition: transform .2s var(--ease-spring), box-shadow .3s var(--ease);
}
.hero-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(212,168,67,.35);
}
.hero-cta svg { width: 18px; height: 18px; }

/* Wave divider */
.hero-wave {
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  line-height: 0;
  z-index: 1;
}
.hero-wave svg {
  width: 100%;
  height: auto;
  display: block;
}

/* ── 7. Tool Card ──────────────────────────────────────────── */
.tool-section {
  padding: 3rem 0 2.5rem;
  background: var(--gray-50);
}
.tool-card {
  background: var(--white);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  padding: 0;
  max-width: 940px;
  margin-inline: auto;
  overflow: hidden;
  position: relative;
  border: 1px solid rgba(0,0,0,.04);
}
.tool-card-accent {
  height: 5px;
  background: linear-gradient(90deg, var(--verde-900), var(--verde-700), var(--dorado), var(--dorado-light));
  background-size: 200% 100%;
}
.tool-card-header {
  padding: 1.75rem 2rem 0;
}
.tool-card-header h2 {
  margin-bottom: 0.2rem;
}
.tool-card-header p {
  color: var(--gray-500);
  font-size: 0.92rem;
}
.tool-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.75rem;
  padding: 1.5rem 2rem 2rem;
}
.tool-inputs {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
}
.input-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}
.input-group label {
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--gray-700);
  display: flex;
  align-items: center;
  gap: 0.45rem;
}
.label-icon {
  width: 22px;
  height: 22px;
  background: var(--verde-50);
  border-radius: var(--radius-xs);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.label-icon svg {
  width: 13px;
  height: 13px;
  color: var(--verde-700);
}
.input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}
.input-wrapper input {
  width: 100%;
  padding: 0.8rem 1rem;
  padding-right: 3.2rem;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius-md);
  font-size: 1rem;
  font-family: var(--sans);
  color: var(--gray-800);
  background: var(--white);
  transition: border-color .25s var(--ease), box-shadow .25s var(--ease), background .25s var(--ease);
}
.input-wrapper input:hover { border-color: var(--gray-300); }
.input-wrapper input:focus {
  outline: none;
  border-color: var(--dorado);
  box-shadow: 0 0 0 4px var(--dorado-glow);
  background: #fffef9;
}
.input-suffix {
  position: absolute;
  right: 1rem;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--gray-400);
  pointer-events: none;
  letter-spacing: .02em;
}
.input-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

/* Error */
.tool-error {
  color: #b91c1c;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.6rem 0.85rem;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: var(--radius-sm);
  text-align: center;
}

/* CTA Button */
.btn-calculate {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  width: 100%;
  padding: 0.95rem 1.5rem;
  background: linear-gradient(135deg, var(--dorado) 0%, var(--dorado-dark) 100%);
  color: var(--white);
  font-size: 1.05rem;
  font-weight: 700;
  border-radius: var(--radius-md);
  margin-top: 0.25rem;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-gold), inset 0 1px 0 rgba(255,255,255,.15);
  text-shadow: 0 1px 2px rgba(0,0,0,.1);
  transition: transform .2s var(--ease-spring), box-shadow .3s var(--ease);
}
.btn-calculate::before {
  content: "";
  position: absolute;
  top: 0; left: -100%; width: 100%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.18), transparent);
  transition: left .6s var(--ease);
}
.btn-calculate:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(212,168,67,.35), inset 0 1px 0 rgba(255,255,255,.2);
}
.btn-calculate:hover::before { left: 100%; }
.btn-calculate:active { transform: translateY(0); }
.btn-calculate svg { width: 18px; height: 18px; }

/* ── 8. Results ────────────────────────────────────────────── */
.results-panel {
  display: none;
  flex-direction: column;
  gap: 1.5rem;
}
.results-panel.is-visible { display: flex; }
.results-summary {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.85rem;
}
.result-card {
  padding: 1.15rem 1.25rem;
  border-radius: var(--radius);
  background: var(--gray-50);
  border: 1px solid var(--gray-200);
  display: flex;
  align-items: center;
  gap: 0.85rem;
  transition: transform .3s var(--ease-spring), box-shadow .3s var(--ease);
}
.result-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}
.result-icon {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-md);
  background: var(--verde-50);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.result-icon svg {
  width: 20px; height: 20px;
  color: var(--verde-700);
}
.result-card.highlight {
  background: linear-gradient(135deg, var(--verde-900) 0%, var(--verde-800) 100%);
  color: var(--white);
  border-color: transparent;
  box-shadow: 0 4px 24px rgba(27,67,50,.2);
}
.result-card.highlight .result-icon {
  background: rgba(255,255,255,.12);
}
.result-card.highlight .result-icon svg { color: var(--dorado-light); }
.result-card.highlight:hover {
  box-shadow: 0 8px 32px rgba(27,67,50,.28);
}
.result-label {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  opacity: .6;
}
.result-value {
  font-size: 1.5rem;
  font-weight: 800;
  font-family: var(--display);
  line-height: 1.2;
  margin-top: 0.1rem;
}
.result-card.highlight .result-value { color: var(--dorado-light); }
.result-sub {
  font-size: 0.72rem;
  opacity: .5;
  margin-top: 0.1rem;
}

/* Chart area */
.chart-area {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.85rem;
  padding: 1.5rem;
  background: var(--gray-50);
  border-radius: var(--radius);
  border: 1px solid var(--gray-100);
}
.chart-title {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--gray-600);
  text-align: center;
}
#donutChart {
  max-width: 240px;
  max-height: 240px;
}
.chart-legend {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  flex-wrap: wrap;
}
.legend-item {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.82rem;
  color: var(--gray-600);
}
.legend-dot {
  width: 12px;
  height: 12px;
  border-radius: 4px;
  flex-shrink: 0;
}
.legend-dot--capital { background: var(--verde-900); }
.legend-dot--interest { background: var(--dorado); }

/* ── 9. Amortization Table ─────────────────────────────────── */
.table-section {
  padding: 2.5rem 0;
}
.table-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: .75rem;
  margin-bottom: 1rem;
}
.table-header h2 { margin: 0; }
.btn-print {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.55rem 1.1rem;
  background: var(--accent);
  color: var(--white);
  font-size: 0.84rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  transition: background .2s var(--ease), transform .15s var(--ease-spring);
  box-shadow: var(--shadow-xs);
}
.btn-print:hover { background: var(--verde-800); transform: translateY(-1px); }
.btn-print svg { width: 16px; height: 16px; }
.table-controls {
  display: flex;
  align-items: center;
  gap: .75rem;
  margin-bottom: .85rem;
  flex-wrap: wrap;
}
.table-toggle {
  display: inline-flex;
  background: var(--gray-100);
  border-radius: var(--radius-sm);
  padding: 3px;
}
.table-toggle button {
  padding: 0.45rem 0.95rem;
  font-size: .82rem;
  font-weight: 600;
  color: var(--gray-500);
  background: transparent;
  border-radius: 7px;
  transition: all .25s var(--ease);
}
.table-toggle button.active {
  background: var(--accent);
  color: var(--white);
  box-shadow: var(--shadow-sm);
}
.table-scroll {
  overflow-x: auto;
  border-radius: var(--radius);
  border: 1px solid var(--gray-200);
  box-shadow: var(--shadow-sm);
}
.amort-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .85rem;
}
.amort-table thead {
  background: linear-gradient(135deg, var(--verde-900), var(--verde-800));
  color: var(--white);
  position: sticky;
  top: 0;
  z-index: 2;
}
.amort-table th {
  padding: .75rem .7rem;
  text-align: right;
  font-weight: 600;
  font-size: .74rem;
  text-transform: uppercase;
  letter-spacing: .05em;
  white-space: nowrap;
}
.amort-table th:first-child { text-align: center; }
.amort-table td {
  padding: .6rem .7rem;
  text-align: right;
  border-bottom: 1px solid var(--gray-100);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.amort-table td:first-child {
  text-align: center;
  font-weight: 700;
  color: var(--accent);
}
.amort-table tbody tr:hover { background: var(--verde-50); }
.amort-table tbody tr:nth-child(even) { background: var(--gray-50); }
.amort-table tbody tr:nth-child(even):hover { background: var(--verde-50); }
.table-info {
  margin-top: .85rem;
  font-size: .8rem;
  color: var(--gray-500);
  text-align: center;
}
.table-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .65rem;
  margin-top: .85rem;
}
.btn-page {
  padding: .45rem .85rem;
  font-size: .82rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  background: var(--gray-100);
  color: var(--gray-700);
  transition: all .2s var(--ease);
}
.btn-page:hover { background: var(--gray-200); transform: translateY(-1px); }
.btn-page:disabled { opacity: .35; cursor: not-allowed; transform: none; }
.page-info { font-size: .82rem; color: var(--gray-500); font-weight: 500; }

/* ── 10. Ad slots ──────────────────────────────────────────── */
.ad-slot {
  min-height: 90px;
  border: 2px dashed var(--gray-200);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gray-300);
  font-size: .72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .1em;
  margin: 2rem auto;
  max-width: 728px;
  background: var(--gray-50);
}
.ad-slot--leaderboard { min-height: 100px; }

/* ── 11. Features section ──────────────────────────────────── */
.features-section {
  padding: 4.5rem 0;
  background: var(--white);
}
.features-section h2 {
  margin-bottom: 2.25rem;
}
.features-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}
.feature-card {
  padding: 2rem 1.5rem;
  background: var(--white);
  border-radius: var(--radius-xl);
  border: 1px solid var(--gray-200);
  text-align: center;
  transition: transform .35s var(--ease-spring), box-shadow .35s var(--ease), border-color .35s var(--ease);
}
.feature-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: transparent;
}
.feature-icon {
  width: 64px;
  height: 64px;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.15rem;
}
.feature-icon svg { width: 28px; height: 28px; }
.feature-icon--green {
  background: linear-gradient(135deg, var(--verde-50), var(--verde-100));
  color: var(--verde-700);
}
.feature-icon--gold {
  background: linear-gradient(135deg, #fef9ee, #fdf0d5);
  color: var(--dorado-dark);
}
.feature-icon--blue {
  background: linear-gradient(135deg, var(--blue-50), var(--blue-100));
  color: var(--blue-600);
}
.feature-card h3 {
  margin-bottom: 0.5rem;
  font-size: 1.1rem;
}
.feature-card p {
  font-size: .9rem;
  color: var(--gray-500);
  line-height: 1.6;
  max-width: 300px;
  margin-inline: auto;
}

/* ── 12. Steps section ─────────────────────────────────────── */
.steps-section {
  padding: 4.5rem 0;
  background: var(--gray-50);
}
.steps-section h2 { margin-bottom: 2rem; }
.steps-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}
.step-card {
  display: flex;
  gap: 1.15rem;
  align-items: flex-start;
  padding: 1.5rem;
  background: var(--white);
  border-radius: var(--radius);
  border: 1px solid var(--gray-200);
  transition: transform .3s var(--ease-spring), box-shadow .3s var(--ease);
}
.step-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}
.step-number {
  width: 48px;
  height: 48px;
  flex-shrink: 0;
  background: linear-gradient(135deg, var(--verde-900), var(--verde-800));
  color: var(--dorado-light);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.2rem;
  box-shadow: 0 4px 12px rgba(27,67,50,.2);
}
.step-card h3 { margin-bottom: .3rem; }
.step-card p { font-size: .9rem; color: var(--gray-500); line-height: 1.55; }

/* ── 13. Content sections ──────────────────────────────────── */
.content-section {
  padding: 4rem 0;
}
.content-section + .content-section {
  border-top: 1px solid var(--gray-200);
}
.content-section h2 { margin-bottom: 1.5rem; }
.seo-content {
  max-width: 720px;
  line-height: 1.8;
  color: var(--gray-600);
}
.seo-content p { margin-bottom: 1.15rem; }
.seo-content p:last-child { margin-bottom: 0; }

/* FAQ */
.faq-list {
  display: flex;
  flex-direction: column;
  gap: .65rem;
  max-width: 720px;
}
.faq-item {
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--white);
  transition: border-color .25s var(--ease), box-shadow .25s var(--ease);
}
.faq-item:hover {
  border-color: var(--gray-300);
}
.faq-item[open] {
  border-color: var(--dorado);
  box-shadow: 0 2px 16px rgba(212,168,67,.1);
}
.faq-item summary {
  padding: 1.15rem 1.35rem;
  font-weight: 600;
  font-size: .95rem;
  color: var(--gray-800);
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  transition: background .2s var(--ease), color .2s var(--ease);
}
.faq-item summary:hover { background: var(--gray-50); }
.faq-item[open] summary { color: var(--accent); }
.faq-item summary::after {
  content: "+";
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--dorado);
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: rgba(212,168,67,.08);
  border-radius: 50%;
  transition: transform .3s var(--ease-spring), background .2s var(--ease);
}
.faq-item[open] summary::after {
  content: "\2212";
  background: rgba(212,168,67,.15);
  transform: rotate(180deg);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-answer {
  padding: 0 1.35rem 1.25rem;
  font-size: .9rem;
  color: var(--gray-500);
  line-height: 1.7;
}

/* Disclaimer */
.disclaimer {
  margin: 2.5rem 0 .5rem;
  padding: 1.25rem 1.5rem;
  background: linear-gradient(135deg, #fef9ee, #fef6e0);
  border: 1px solid #f0dfa3;
  border-radius: var(--radius);
  font-size: .82rem;
  color: var(--gray-600);
  line-height: 1.6;
  display: flex;
  gap: .75rem;
  align-items: flex-start;
}
.disclaimer svg {
  width: 20px; height: 20px;
  flex-shrink: 0;
  color: var(--dorado-dark);
  margin-top: 1px;
}

/* ── 14. CTA Banner ────────────────────────────────────────── */
.cta-banner {
  background: linear-gradient(135deg, var(--verde-900) 0%, var(--verde-800) 100%);
  padding: 3.5rem 0;
  position: relative;
  overflow: hidden;
}
.cta-banner::before {
  content: "";
  position: absolute;
  top: -50%; right: -10%;
  width: 400px; height: 400px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(212,168,67,.1) 0%, transparent 65%);
  pointer-events: none;
}
.cta-banner-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 1.5rem;
  position: relative;
  z-index: 1;
}
.cta-banner-text h2 {
  color: var(--white);
  margin-bottom: .5rem;
}
.cta-banner-text p {
  color: rgba(255,255,255,.72);
  font-size: .95rem;
}
.btn-cta {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .85rem 2rem;
  background: linear-gradient(135deg, var(--dorado), var(--dorado-dark));
  color: var(--white);
  font-size: 1rem;
  font-weight: 700;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-gold);
  text-shadow: 0 1px 2px rgba(0,0,0,.12);
  transition: transform .2s var(--ease-spring), box-shadow .3s var(--ease);
}
.btn-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(212,168,67,.35);
}
.btn-cta svg { width: 18px; height: 18px; }

/* ── 15. Footer ────────────────────────────────────────────── */
.site-footer {
  background: #0c1f16;
  color: rgba(255,255,255,.7);
  padding: 3.5rem 0 0;
  font-size: .85rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  padding-bottom: 2.5rem;
}
.footer-brand {
  max-width: 300px;
}
.footer-logo {
  display: flex;
  align-items: center;
  gap: .55rem;
  margin-bottom: .75rem;
}
.footer-logo .logo-icon {
  width: 32px;
  height: 32px;
  font-size: .78rem;
}
.footer-logo .logo-text {
  font-size: 1.2rem;
}
.footer-tagline {
  font-size: .84rem;
  line-height: 1.55;
  color: rgba(255,255,255,.5);
}
.footer-col {
  display: flex;
  flex-direction: column;
  gap: .6rem;
}
.footer-col h4 {
  font-size: .78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: rgba(255,255,255,.4);
  margin-bottom: .1rem;
}
.footer-col a {
  color: rgba(255,255,255,.6);
  font-size: .84rem;
  transition: color .2s var(--ease);
}
.footer-col a:hover { color: var(--dorado-light); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.08);
  padding: 1.25rem 0;
  text-align: center;
}
.footer-bottom p {
  font-size: .76rem;
  color: rgba(255,255,255,.35);
}

/* ── 16. Responsive ────────────────────────────────────────── */
@media (min-width: 540px) {
  .results-summary { grid-template-columns: repeat(3, 1fr); }
  .features-grid { grid-template-columns: repeat(3, 1fr); }
  .steps-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-grid { grid-template-columns: 1.5fr 1fr 1fr; }
}

@media (min-width: 720px) {
  .tool-grid {
    grid-template-columns: 1fr 1fr;
    gap: 2.25rem;
  }
  .tool-card-header {
    padding: 2rem 2.5rem 0;
  }
  .tool-grid {
    padding: 1.75rem 2.5rem 2.5rem;
  }
  .cta-banner-inner {
    flex-direction: row;
    text-align: left;
    justify-content: space-between;
  }
}

@media (min-width: 960px) {
  .container { padding-inline: 2rem; }
  .hero { padding: 6rem 0 8rem; }
}

/* ── 17. Print ─────────────────────────────────────────────── */
@media print {
  .site-header, .hero, .ad-slot, .btn-print,
  .btn-calculate, .table-controls, .table-nav,
  .features-section, .steps-section, .content-section,
  .cta-banner, .site-footer, .trust-row,
  .disclaimer, .tool-inputs, .chart-area,
  .tool-card-accent, .tool-card-header,
  .hero-cta, .hero-badge { display: none !important; }

  .tool-section { padding: 0; background: none; }
  .tool-card { box-shadow: none; padding: 0; border: none; border-radius: 0; }
  .results-panel { display: flex !important; }
  .results-summary { display: grid !important; grid-template-columns: repeat(3,1fr); }
  .result-icon { display: none; }

  .table-section { padding: .5rem 0; }
  .table-scroll { border: none; overflow: visible; box-shadow: none; }
  .amort-table { font-size: .7rem; }
  .amort-table th { padding: .35rem .3rem; }
  .amort-table td { padding: .25rem .3rem; }

  @page { size: A4; margin: 1.5cm; }
  body::before {
    content: "CalcFinanza \2014  Tabla de amortizaci\00F3n";
    display: block;
    font-size: 14pt;
    font-weight: bold;
    margin-bottom: 8pt;
    color: #1b4332;
  }
}
