/* FiscaFlow — página pública. Tipografía del sistema (no carga fuentes externas). */
:root {
  --brand: hsl(162, 72%, 29%);
  --brand-dark: hsl(162, 72%, 22%);
  --navy: hsl(216, 34%, 13%);
  --ink: hsl(216, 30%, 14%);
  --ink-2: hsl(215, 18%, 34%);
  --muted: hsl(215, 14%, 46%);
  --line: hsl(214, 22%, 88%);
  --page: hsl(210, 33%, 98%);
  --surface: #fff;
  --soft: hsl(162, 45%, 95%);
  --warn-bg: hsl(38, 92%, 93%);
  --warn: hsl(34, 88%, 32%);
  --radius: 18px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--page); color: var(--ink);
  font: 16px/1.55 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-text-size-adjust: 100%;
}
img { max-width: 100%; }
a { color: var(--brand-dark); }
h1, h2, h3 { line-height: 1.2; letter-spacing: -0.02em; margin: 0 0 10px; }
h1 { font-size: clamp(28px, 6vw, 46px); font-weight: 800; }
h2 { font-size: clamp(23px, 4.2vw, 32px); font-weight: 800; }
h3 { font-size: 17px; font-weight: 750; }
p { margin: 0 0 10px; }
.wrap { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 18px; }
.narrow { max-width: 780px; }
.center { text-align: center; }
.skip { position: absolute; left: -999px; top: 0; background: #fff; padding: 8px; z-index: 10; }
.skip:focus { left: 8px; }

/* Botones */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border-radius: 999px; padding: 10px 18px; font-weight: 700; font-size: 15px;
  text-decoration: none; border: 2px solid transparent; cursor: pointer; white-space: nowrap;
}
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-dark); }
.btn-secondary { background: #fff; color: var(--ink); border-color: var(--line); }
.btn-secondary:hover { border-color: var(--brand); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); padding: 7px 16px; font-size: 14px; }
.btn-lg { padding: 13px 22px; font-size: 16px; }
.btn-sm { padding: 7px 14px; font-size: 13.5px; }
.cta-row { display: flex; flex-wrap: wrap; gap: 10px; margin: 18px 0 8px; }
.cta-row.center { justify-content: center; }
.fine { font-size: 13px; color: var(--muted); }

/* Encabezado */
.site-header { position: sticky; top: 0; z-index: 5; background: rgba(255, 255, 255, 0.94); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.header-row { display: flex; align-items: center; gap: 14px; min-height: 62px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.brand img { border-radius: 10px; }
.brand span { display: flex; flex-direction: column; line-height: 1.1; }
.brand strong { font-size: 17px; }
.brand small { font-size: 12px; color: var(--muted); }
.site-nav { display: flex; gap: 18px; margin-left: auto; }
.site-nav a { color: var(--ink-2); text-decoration: none; font-size: 14.5px; font-weight: 600; }
.site-nav a:hover { color: var(--brand-dark); }
.data-banner { background: var(--soft); border-bottom: 1px solid hsl(162, 40%, 82%); }
.data-banner-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; padding: 10px 18px; font-size: 14.5px; }

/* Presentación */
.hero { padding: 44px 0 36px; background: linear-gradient(180deg, #fff, var(--page)); }
.hero-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 40px; align-items: center; }
.eyebrow { color: var(--brand-dark); font-weight: 750; font-size: 14px; text-transform: uppercase; letter-spacing: 0.04em; }
.lead { font-size: 18px; color: var(--ink-2); max-width: 36em; }

/* Ejemplo del disponible */
.example { margin: 0; }
.example-card {
  background: linear-gradient(150deg, hsl(216, 40%, 16%), hsl(162, 72%, 22%)); color: #fff;
  border-radius: 22px; padding: 22px; box-shadow: 0 24px 60px rgba(15, 23, 42, 0.25);
}
.example-label { font-size: 14px; font-weight: 700; opacity: 0.9; }
.example-amount { font-size: clamp(34px, 7vw, 44px); font-weight: 800; letter-spacing: -0.02em; margin: 4px 0; font-variant-numeric: tabular-nums; }
.example-period { font-size: 14px; opacity: 0.92; }
.example-breakdown { margin: 14px 0 0; background: rgba(255, 255, 255, 0.1); border-radius: 14px; padding: 10px 12px; font-size: 14px; }
.example-breakdown div { display: flex; justify-content: space-between; gap: 12px; padding: 3px 0; }
.example-breakdown dt { margin: 0; }
.example-breakdown dd { margin: 0; white-space: nowrap; font-variant-numeric: tabular-nums; }
.example-breakdown .total { border-top: 1px solid rgba(255, 255, 255, 0.28); margin-top: 4px; padding-top: 6px; font-weight: 800; }
.example-note { margin-top: 10px; font-size: 13px; opacity: 0.88; }
.example figcaption { text-align: center; font-size: 13px; color: var(--muted); margin-top: 10px; }

/* Secciones */
.section { padding: 52px 0; }
.section.alt { background: #fff; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-lead { color: var(--ink-2); margin-bottom: 18px; }
.steps { list-style: none; margin: 18px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.steps li { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.step-n { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--brand); color: #fff; font-weight: 800; margin-bottom: 10px; }
.steps p, .features p, .privacy p, .compare-card p { color: var(--ink-2); font-size: 15px; }
.features { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.features article, .privacy article { background: var(--page); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.compare { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 14px; }
.compare-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.compare-card.good { border: 2px solid var(--brand); }
.formula { font-weight: 700; color: var(--ink) !important; background: var(--page); border-radius: 10px; padding: 8px 10px; font-size: 14.5px !important; }
.privacy { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-top: 10px; }
.honest { margin-top: 18px; background: var(--warn-bg); color: var(--warn); border-radius: var(--radius); padding: 16px 20px; }
.honest h3 { color: var(--warn); }
.honest ul { margin: 0; padding-left: 20px; }
.honest li { margin: 4px 0; }
details { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 4px 16px; margin: 10px 0; }
summary { cursor: pointer; font-weight: 700; padding: 10px 0; }
details p { color: var(--ink-2); }
.plan { background: var(--page); border: 2px solid var(--brand); border-radius: var(--radius); padding: 20px; margin: 14px 0; }
.plan-head { display: flex; justify-content: space-between; align-items: baseline; }
.plan-price { font-size: 28px; font-weight: 800; }
.brand-section { background: var(--navy); color: #fff; }
.brand-section h2 { color: #fff; }
.brand-section p { color: rgba(255, 255, 255, 0.86); font-size: 17px; }
.help { color: var(--ink-2); margin-top: 14px; }

/* Pie */
.site-footer { background: #fff; border-top: 1px solid var(--line); padding: 22px 0 30px; }
.footer-row { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; font-weight: 700; margin-bottom: 8px; }
.footer-links { display: flex; gap: 16px; }
.footer-links a { color: var(--ink-2); text-decoration: none; font-weight: 600; }

/* Celular */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; gap: 26px; }
  .features, .privacy { grid-template-columns: 1fr 1fr; }
  .steps { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .site-nav { display: none; }
  .header-row { justify-content: space-between; }
  .hero { padding: 26px 0 24px; }
  .lead { font-size: 16.5px; }
  .features, .privacy, .compare { grid-template-columns: 1fr; }
  .section { padding: 38px 0; }
  .cta-row .btn { flex: 1 1 100%; }
}

/* ===================== Blog ===================== */
.post-list { display: flex; flex-direction: column; gap: 14px; }
.post-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.post-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.post-card h3 { margin: 6px 0 8px; font-size: 18px; }
.post-card h3 a { color: var(--ink); text-decoration: none; }
.post-card h3 a:hover { color: var(--brand-dark); text-decoration: underline; }
.post-card p { color: var(--ink-2); font-size: 15px; margin: 0; }
.post-meta { font-size: 13px; color: var(--muted); }
.post-cat { color: var(--brand-dark); font-weight: 700; text-decoration: none; }
.blog-head { padding-bottom: 10px; }
.blog-list-section { padding-top: 10px; }
.blog-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.blog-tabs a { padding: 7px 14px; border-radius: 999px; border: 1px solid var(--line); background: #fff; color: var(--ink); text-decoration: none; font-weight: 600; font-size: 14px; }
.blog-tabs a[aria-current="page"] { background: var(--brand); border-color: var(--brand); color: #fff; }
.blog-pager { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin: 20px 0; font-size: 14px; }
.blog-empty { color: var(--ink-2); background: #fff; border: 1px dashed var(--line); border-radius: var(--radius); padding: 18px; }
.post h1 { margin-top: 6px; }
.crumbs { font-size: 14px; color: var(--muted); }
.crumbs a { color: var(--brand-dark); text-decoration: none; }
.post-hero { width: 100%; border-radius: var(--radius); margin: 16px 0; }
.post-toc { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 12px 16px; margin: 18px 0; font-size: 15px; }
.post-toc ol { margin: 6px 0 0; padding-left: 20px; }
.post-body { font-size: 17px; line-height: 1.7; margin-top: 18px; }
.post-body h2 { margin-top: 28px; font-size: 24px; }
.post-body h3 { margin-top: 22px; }
.post-body ul, .post-body ol { padding-left: 22px; }
.post-body li { margin: 4px 0; }
.post-body blockquote { margin: 16px 0; padding: 10px 16px; border-left: 4px solid var(--brand); background: var(--soft); border-radius: 0 12px 12px 0; }
.post-body img { max-width: 100%; border-radius: 12px; }
.post-body pre { background: var(--navy); color: #fff; padding: 12px; border-radius: 12px; overflow-x: auto; font-size: 14px; }
.post-body code { background: var(--soft); padding: 1px 5px; border-radius: 5px; font-size: 0.92em; }
.post-body pre code { background: none; padding: 0; }
.post-sources { margin-top: 26px; font-size: 14px; }
.post-sources h2 { font-size: 18px; }
.post-sources a { word-break: break-all; }
.post-tags { margin-top: 14px; display: flex; gap: 8px; flex-wrap: wrap; font-size: 13px; color: var(--muted); }
.post-cta { margin: 28px 0; background: var(--navy); color: #fff; border-radius: var(--radius); padding: 18px 20px; display: flex; flex-direction: column; gap: 8px; }
.post-cta span { color: rgba(255, 255, 255, 0.86); }
.post-cta-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.post-cta .btn-secondary { background: transparent; color: #fff; border-color: rgba(255, 255, 255, 0.4); }
.post-related { margin-top: 10px; }
@media (max-width: 900px) { .post-grid { grid-template-columns: 1fr; } }
@media (max-width: 640px) { .post-body { font-size: 16.5px; } }
