/* Sello — sistema de diseño base. Ver README para la racional de marca. */

/* Oscuro es la identidad por default de Sello — negro casi puro, dorado
   brillante, texto casi blanco: el look "sello de cera premium". El claro
   sigue disponible a mano, vía el botón de tema en la barra de navegación
   (ver public/js/theme-toggle.js), para quien lo prefiera. */
:root {
  --paper: #0c0c0f;
  --surface: #141417;
  --surface-2: #1c1c20;
  --ink: #f7f5f0;
  --ink-soft: #cdc8ba;
  --muted: #8f897a;
  --line: #242327;
  --line-strong: #38363a;

  --brand: #f0b429;
  --brand-strong: #f7cf6b;
  --brand-soft: #3a2c0e;

  --success: #6cd9a0;
  --success-soft: #16261d;
  --warning: #f0a15c;
  --warning-soft: #2e2013;
  --danger: #f08fae;
  --danger-soft: #2e1820;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.5);
  --shadow-md: 0 10px 28px rgba(0, 0, 0, 0.55);
  --radius: 8px;
}

:root[data-theme="light"] {
  --paper: #f7f1e2;
  --surface: #fffcf3;
  --surface-2: #f1e7cd;
  --ink: #14181f;
  --ink-soft: #4a4536;
  --muted: #85795a;
  --line: #e5d8b3;
  --line-strong: #cdb989;

  --brand: #b8862e;
  --brand-strong: #8a6222;
  --brand-soft: #f0e1bb;

  --success: #2f6b4f;
  --success-soft: #dfece3;
  --warning: #b5581c;
  --warning-soft: #f5e2cc;
  --danger: #9c3b5c;
  --danger-soft: #f2dce4;

  --shadow-sm: 0 1px 2px rgba(20, 24, 31, 0.08);
  --shadow-md: 0 4px 16px rgba(20, 24, 31, 0.1);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
}

body {
  font-family: "IBM Plex Sans", system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.55;
}

h1, h2, h3, h4 {
  font-family: "Zilla Slab", Georgia, serif;
  font-weight: 700;
  line-height: 1.15;
  margin: 0;
  text-wrap: balance;
}

p { color: var(--ink-soft); margin: 0 0 1em; }
a { color: var(--brand-strong); text-decoration: none; }
a:hover { text-decoration: underline; }

.mono { font-family: "IBM Plex Mono", monospace; font-variant-numeric: tabular-nums; }

::selection { background: var(--brand); color: #fff; }

/* ---------- Layout shell ---------- */
.shell { max-width: 1120px; margin: 0 auto; padding: 0 1.5rem; }
.shell-narrow { max-width: 760px; margin: 0 auto; padding: 0 1.5rem; }

.topnav {
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}
.topnav-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: "Zilla Slab", serif;
  font-weight: 700;
  font-size: 1.3rem;
  color: var(--ink);
}
.brand .brand-mark {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #14181f;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.brand .brand-mark img {
  width: 128%;
  height: 128%;
  object-fit: cover;
}
.nav-links { display: flex; align-items: center; gap: 1.6rem; }
.nav-links a { color: var(--ink-soft); font-size: 0.94rem; }
.nav-links a:hover { color: var(--ink); text-decoration: none; }
.nav-links a.btn-primary { color: #1a1408; font-weight: 700; }
.nav-links a.btn-primary:hover { color: #1a1408; }

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 34px;
  height: 34px;
  border: none;
  background: transparent;
  padding: 0;
  cursor: pointer;
}
.nav-toggle span { display: block; height: 2px; width: 100%; background: var(--ink); border-radius: 2px; }

.theme-toggle-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--ink);
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
  transition: border-color 0.15s ease, transform 0.1s ease;
}
.theme-toggle-btn:hover { border-color: var(--brand); }
.theme-toggle-btn:active { transform: scale(0.92); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: "IBM Plex Sans", sans-serif;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.62rem 1.15rem;
  border-radius: var(--radius);
  border: 1px solid transparent;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.05s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--brand); color: #1a1408; }
.btn-primary:hover { background: var(--brand-strong); text-decoration: none; }
.btn-ghost { background: transparent; border-color: var(--line-strong); color: var(--ink); }
.btn-ghost:hover { border-color: var(--brand); color: var(--brand-strong); text-decoration: none; }
.btn-danger { background: transparent; border-color: var(--danger); color: var(--danger); }
.btn-danger:hover { background: var(--danger-soft); text-decoration: none; }
.btn-sm { padding: 0.4rem 0.8rem; font-size: 0.85rem; }
.btn[disabled] { opacity: 0.5; cursor: not-allowed; }
.btn-block { width: 100%; }

/* ---------- Cards ---------- */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}
.card-pad { padding: 1.5rem; }

/* ---------- Forms ---------- */
.field { display: flex; flex-direction: column; gap: 0.4rem; margin-bottom: 1.1rem; }
.field label { font-size: 0.85rem; font-weight: 600; color: var(--ink-soft); }
.field input, .field select, .field textarea {
  font-family: inherit;
  font-size: 0.98rem;
  padding: 0.62rem 0.8rem;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: 2px solid var(--brand);
  outline-offset: 1px;
  border-color: var(--brand);
}
.field-hint { font-size: 0.8rem; color: var(--muted); }
.form-card { max-width: 420px; }

.password-requirements {
  list-style: none;
  margin: 0.3rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.22rem;
}
.password-requirements li {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.8rem;
  color: var(--muted);
  transition: color 0.15s ease;
}
.password-requirements li::before {
  content: "○";
  font-size: 0.65rem;
  color: var(--line-strong);
  transition: color 0.15s ease;
}
.password-requirements li.met { color: var(--ink-soft); }
.password-requirements li.met::before {
  content: "✓";
  color: var(--success);
  font-weight: 700;
}

/* ---------- Badges / pills ---------- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
}
.badge-success { background: var(--success-soft); color: var(--success); }
.badge-warning { background: var(--warning-soft); color: var(--warning); }
.badge-danger { background: var(--danger-soft); color: var(--danger); }
.badge-neutral { background: var(--surface-2); color: var(--muted); }

/* ---------- Alerts / banners ---------- */
.alert {
  border: 1px solid var(--line);
  border-left: 3px solid var(--brand);
  background: var(--surface);
  border-radius: var(--radius);
  padding: 0.9rem 1.1rem;
  font-size: 0.92rem;
  color: var(--ink-soft);
}
.alert-warning { border-left-color: var(--warning); }
.alert strong { color: var(--ink); }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }
table { width: 100%; border-collapse: collapse; font-size: 0.9rem; background: var(--surface); }
thead th {
  text-align: left;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  padding: 0.7rem 0.9rem;
  border-bottom: 1px solid var(--line-strong);
  white-space: nowrap;
}
tbody td { padding: 0.7rem 0.9rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
tbody tr:last-child td { border-bottom: none; }

/* ---------- Stat tiles (dashboard) ---------- */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.stat-tile { background: var(--surface); padding: 1.1rem 1.3rem; }
.stat-tile .stat-label { font-family: "IBM Plex Mono", monospace; font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted); }
.stat-tile .stat-value { font-family: "IBM Plex Mono", monospace; font-size: 1.9rem; font-weight: 600; margin-top: 0.2rem; }

/* ---------- Landing hero ---------- */
.hero { padding: 5rem 0 4rem; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 3rem; align-items: center; }
.hero-eyebrow {
  font-family: "IBM Plex Mono", monospace;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  font-size: 0.78rem;
  color: var(--brand-strong);
  display: inline-block;
  margin-bottom: 1.1rem;
}
.hero h1 { font-size: clamp(2.4rem, 5.5vw, 3.6rem); max-width: 16ch; }
.hero p.lead { font-size: 1.15rem; max-width: 52ch; margin-top: 1.1rem; }
.hero-actions { display: flex; gap: 0.9rem; margin-top: 2rem; flex-wrap: wrap; }
.hero-footnote { font-size: 0.85rem; color: var(--muted); margin-top: 1.1rem; margin-bottom: 0; }

.hero-seal { display: flex; flex-direction: column; align-items: center; gap: 1rem; text-align: center; }
.hero-seal-frame {
  width: 260px; height: 260px; border-radius: 50%;
  background: #14181f;
  box-shadow: var(--shadow-md), 0 22px 50px -20px rgba(20, 24, 31, 0.45);
  overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  transition: transform 0.35s cubic-bezier(0.16, 0.84, 0.44, 1);
  opacity: 0;
}
.hero-seal-frame img { width: 128%; height: 128%; object-fit: cover; }
.hero-seal:hover .hero-seal-frame { transform: rotate(-4deg) scale(1.03); }
.hero-seal-caption { font-size: 0.82rem; color: var(--muted); max-width: 22ch; }

/* Al entrar en pantalla, el sello "estampa" — cae y se asienta como si
   recién lo hubieran presionado sobre el lacre. Después queda un brillo
   tenue y lento, como cera todavía tibia. */
.hero-seal.in-view .hero-seal-frame {
  animation: seal-stamp 0.85s cubic-bezier(0.34, 1.56, 0.64, 1) 0.15s forwards,
    seal-glow 4.5s ease-in-out 1.1s infinite;
}
@keyframes seal-stamp {
  0% { opacity: 0; transform: scale(1.6) rotate(-18deg); }
  55% { opacity: 1; transform: scale(0.94) rotate(3deg); }
  100% { opacity: 1; transform: scale(1) rotate(0deg); }
}
@keyframes seal-glow {
  0%, 100% { box-shadow: var(--shadow-md), 0 22px 50px -20px rgba(20, 24, 31, 0.45), 0 0 0 0 rgba(184, 134, 46, 0); }
  50% { box-shadow: var(--shadow-md), 0 22px 50px -20px rgba(20, 24, 31, 0.45), 0 0 26px 6px rgba(184, 134, 46, 0.28); }
}

.section { padding: 3.5rem 0; }
.section-title { font-size: 1.8rem; margin-bottom: 0.6rem; }
.section-lead { max-width: 60ch; margin-bottom: 2.2rem; }

.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.2rem; }
.feature-card { padding: 1.4rem; transition: transform 0.2s ease, box-shadow 0.2s ease; }
.feature-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.feature-card .feature-icon {
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--brand-soft); color: var(--brand-strong);
  display: flex; align-items: center; justify-content: center;
  font-family: "Zilla Slab", serif; font-weight: 700; margin-bottom: 0.9rem;
}
.feature-card h3 { font-size: 1.1rem; margin-bottom: 0.4rem; }
.feature-card p { font-size: 0.92rem; margin: 0; }

.pricing-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.2rem; }
.pricing-card { padding: 1.6rem; display: flex; flex-direction: column; gap: 0.9rem; transition: transform 0.2s ease, box-shadow 0.2s ease; }
.pricing-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.pricing-card.featured { border-color: var(--brand); box-shadow: var(--shadow-md); }
.pricing-card.recommended {
  position: relative;
  border-color: var(--success);
  box-shadow: 0 0 0 3px var(--success-soft), var(--shadow-md);
}
.pricing-card.recommended::before {
  content: "Recomendado para vos";
  position: absolute;
  top: -0.7rem;
  left: 1.2rem;
  background: var(--success);
  color: var(--surface);
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.68rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
}

.calc-box { margin-bottom: 1.6rem; }
.calc-box input[type="number"] {
  width: 100%;
  padding: 0.6rem 0.8rem;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--surface);
  font-size: 1rem;
}
.pricing-card .price { font-family: "IBM Plex Mono", monospace; font-size: 2rem; font-weight: 600; }
.pricing-card .price span { font-size: 0.9rem; color: var(--muted); font-weight: 400; }
.pricing-card ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.5rem; font-size: 0.88rem; color: var(--ink-soft); }
.pricing-card ul li::before { content: "✓ "; color: var(--success); font-weight: 700; }

/* ---------- Quiénes somos ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 2.5rem;
  align-items: center;
}
.about-card { display: flex; flex-direction: column; gap: 1.4rem; border-left: 3px solid var(--brand); }
.about-card-quote {
  font-family: "Zilla Slab", serif;
  font-size: 1.15rem;
  font-style: italic;
  color: var(--ink);
  line-height: 1.45;
  margin: 0;
}
.about-card-signature { display: flex; flex-direction: column; gap: 0.15rem; }
.about-card-signature strong { font-size: 0.98rem; color: var(--ink); }
.about-card-signature span { font-size: 0.85rem; color: var(--muted); }

/* ---------- Comparación "sin Sello / con Sello" ---------- */
.compare-section { padding-top: 1rem; }
.compare-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.4rem; }
.compare-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 1.6rem; }
.compare-card ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.75rem; font-size: 0.94rem; }
.compare-card--before { background: var(--surface-2); opacity: 0.85; }
.compare-card--before ul li { color: var(--ink-soft); }
.compare-card--before ul li::before { content: "✕ "; color: var(--muted); font-weight: 700; }
.compare-card--after {
  background: linear-gradient(165deg, var(--surface) 55%, var(--brand-soft) 160%);
  border: 2px solid var(--brand);
  box-shadow: var(--shadow-md), 0 0 0 4px var(--brand-soft);
}
.compare-card--after ul li { color: var(--ink); font-weight: 600; }
.compare-card--after ul li::before { content: "✓ "; color: var(--success); font-weight: 700; font-size: 1.1em; }
.compare-tag {
  display: inline-block; font-family: "IBM Plex Mono", monospace; font-size: 0.72rem;
  text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted);
  margin-bottom: 1rem;
}
.compare-tag--brand {
  background: var(--brand);
  color: var(--surface);
  padding: 0.3rem 0.75rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.74rem;
}

/* ---------- Animación "el mail sale de la PC y llega (o no)" ---------- */
.mail-journey { display: block; width: 100%; height: auto; margin-top: 1.2rem; }

.mail-fly-bad { animation: mail-fly-bad 4.5s ease-in-out infinite; }
@keyframes mail-fly-bad {
  0%   { transform: translate(0, 0) rotate(0deg) scale(1); opacity: 0; }
  6%   { opacity: 1; }
  40%  { transform: translate(70px, -16px) rotate(-12deg) scale(1); opacity: 1; }
  70%  { transform: translate(130px, 18px) rotate(18deg) scale(0.9); opacity: 0.85; }
  85%  { transform: translate(170px, 48px) rotate(38deg) scale(0.5); opacity: 0; }
  100% { transform: translate(0, 0) rotate(0deg) scale(1); opacity: 0; }
}
.mail-marker-bad { animation: mail-marker-pulse 2.6s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }

.mail-fly-good { animation: mail-fly-good 4.5s ease-in-out infinite; }
@keyframes mail-fly-good {
  0%   { transform: translate(0, 0) scale(1); opacity: 0; }
  6%   { opacity: 1; }
  50%  { transform: translate(98px, -3px) scale(1.18); opacity: 1; }
  55%  { transform: translate(102px, 0) scale(1); opacity: 1; }
  82%  { transform: translate(192px, 0) scale(1); opacity: 1; }
  92%  { transform: translate(192px, 0) scale(1); opacity: 0; }
  100% { transform: translate(0, 0) scale(1); opacity: 0; }
}
.mail-marker-seal { animation: mail-marker-pulse 4.5s ease-in-out infinite; animation-delay: 2.2s; transform-box: fill-box; transform-origin: center; }
.mail-marker-good { animation: mail-marker-pulse 4.5s ease-in-out infinite; animation-delay: 3.6s; transform-box: fill-box; transform-origin: center; }
@keyframes mail-marker-pulse {
  0%, 80%, 100% { transform: scale(1); }
  90% { transform: scale(1.18); }
}
/* ---------- Cómo se conecta ---------- */
.connect-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.4rem; }
.connect-card { padding: 1.6rem; transition: transform 0.2s ease, box-shadow 0.2s ease; }
.connect-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.connect-step {
  display: inline-block; font-family: "IBM Plex Mono", monospace; font-size: 0.72rem;
  text-transform: uppercase; letter-spacing: 0.05em; color: var(--brand-strong);
  background: var(--brand-soft); padding: 0.2rem 0.55rem; border-radius: 999px;
  margin-bottom: 0.9rem;
}
.connect-card h3 { font-size: 1.15rem; margin-bottom: 0.5rem; }
.connect-card p { font-size: 0.92rem; margin: 0; }
.connect-card code { background: var(--surface-2); padding: 0.1rem 0.4rem; border-radius: 4px; font-size: 0.85em; }

/* ---------- Para quién es ---------- */
.persona-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.2rem; }
.persona-card { padding: 1.4rem; transition: transform 0.2s ease, box-shadow 0.2s ease; }
.persona-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.persona-card h3 { font-size: 1.05rem; margin-bottom: 0.5rem; }
.persona-card p { font-size: 0.9rem; margin: 0; }

/* ---------- CTA final ---------- */
.cta-band { background: var(--brand-soft); }
.cta-band-inner { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; flex-wrap: wrap; }
.cta-band h2 { font-size: 1.6rem; max-width: 30ch; }

/* ---------- Highlighted phrases ---------- */
.highlight {
  color: var(--brand-strong);
  font-weight: 700;
  background-image: linear-gradient(to top, var(--brand-soft) 38%, transparent 38%);
  padding: 0 0.06em;
}

/* ---------- Marquee strip ---------- */
.marquee-strip {
  overflow: hidden;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--surface-2);
  padding: 0.75rem 0;
}
.marquee-track {
  display: flex;
  width: max-content;
  gap: 2.75rem;
  animation: marquee-scroll 26s linear infinite;
}
.marquee-strip:hover .marquee-track { animation-play-state: paused; }
.marquee-item {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.8rem;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
  white-space: nowrap;
}
.marquee-item::before { content: "✓"; color: var(--success); font-weight: 700; }
@keyframes marquee-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ---------- Trust / pilot slots ---------- */
.trust-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 1rem; margin-top: 1.3rem; }
.trust-slot {
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  padding: 1.5rem 1rem;
  text-align: center;
  color: var(--muted);
  font-size: 0.85rem;
  background: var(--surface);
  transition: border-color 0.2s ease, color 0.2s ease;
}
.trust-slot:hover { border-color: var(--brand); color: var(--brand-strong); }

/* ---------- Scroll reveal ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.55s ease, transform 0.55s ease; }
.reveal.in-view { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
  .reveal { transition: none; opacity: 1; transform: none; }
  .hero-seal:hover .hero-seal-frame { transform: none; }
  .marquee-track { animation: none; }
  .hero-seal-frame { animation: none !important; opacity: 1; transform: none; }
  .mail-fly-bad { animation: none !important; opacity: 1 !important; transform: translate(170px, 20px) rotate(20deg) !important; }
  .mail-fly-good { animation: none !important; opacity: 1 !important; transform: translate(192px, 0) !important; }
  .mail-marker-bad, .mail-marker-seal, .mail-marker-good { animation: none !important; }
}

/* ---------- Rampa de warmup ("empezá antes") ---------- */
.ramp-card { padding: 1.8rem 1.6rem 1.4rem; }
.ramp-chart { display: flex; align-items: flex-end; gap: 0.5rem; height: 130px; }
.ramp-bar {
  flex: 1;
  height: var(--h);
  min-height: 6px;
  background: var(--brand-soft);
  border: 1px solid var(--line-strong);
  border-bottom: none;
  border-radius: 4px 4px 0 0;
  position: relative;
  display: flex;
  justify-content: center;
  transition: transform 0.2s ease;
}
.ramp-bar:hover { transform: scaleY(1.03); }
.ramp-bar--steady { background: var(--brand); border-color: var(--brand-strong); }
.ramp-value {
  position: absolute;
  top: -1.35rem;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.72rem;
  color: var(--ink-soft);
  white-space: nowrap;
}
.ramp-bar--steady .ramp-value { color: var(--brand-strong); font-weight: 700; }
.ramp-days { display: flex; gap: 0.5rem; margin-top: 0.5rem; }
.ramp-days span { flex: 1; text-align: center; font-family: "IBM Plex Mono", monospace; font-size: 0.7rem; color: var(--muted); }

/* ---------- Snippet de código ---------- */
/* El bloque de código queda oscuro a propósito en los dos temas (estilo
   terminal, como Stripe/Postmark), no es un tema roto. */
.code-card {
  --code-bg: #1b212a;
  --code-ink: #e8e2c8;
  --code-tab-active-ink: #f0e6c9;
  padding: 0;
  overflow: hidden;
}
.code-tabs { display: flex; gap: 0.2rem; padding: 0.6rem 0.6rem 0; background: var(--surface-2); }
.code-tab {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.78rem;
  padding: 0.5rem 1rem;
  border: none;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  border-radius: 6px 6px 0 0;
}
.code-tab.active { background: var(--code-bg); color: var(--code-tab-active-ink); }
.code-block {
  margin: 0;
  padding: 1.3rem 1.5rem;
  background: var(--code-bg);
  color: var(--code-ink);
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.84rem;
  line-height: 1.65;
  overflow-x: auto;
}
.code-block code { color: inherit; background: none; padding: 0; }
.code-hint { padding: 1rem 1.5rem 1.3rem; margin: 0; }
.code-hint code { background: var(--surface-2); padding: 0.1rem 0.4rem; border-radius: 4px; font-size: 0.85em; }

@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-seal { order: -1; }
  .hero-seal-frame { width: 190px; height: 190px; }
  .about-grid { grid-template-columns: 1fr; }
}

@media (max-width: 680px) {
  .topnav { position: relative; }
  .nav-toggle { display: flex; }
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--surface);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-md);
    padding: 0.5rem 1.5rem 1.1rem;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 0.65rem 0; }
  .nav-links .btn { margin-top: 0.5rem; text-align: center; }

  .cta-band-inner { text-align: center; justify-content: center; }
  .cta-band h2 { max-width: none; }

  .ramp-chart { height: 110px; gap: 0.3rem; }
  .ramp-value { font-size: 0.62rem; top: -1.15rem; }
  .ramp-days span { font-size: 0.62rem; }
  .code-block { font-size: 0.76rem; padding: 1.1rem 1.1rem; }
}

footer.site-footer {
  border-top: 1px solid var(--line);
  padding: 2rem 0;
  color: var(--muted);
  font-size: 0.85rem;
}

/* ---------- App shell ---------- */
.app-body { display: flex; min-height: calc(100vh - 64px); }
.app-sidebar {
  width: 220px;
  flex-shrink: 0;
  border-right: 1px solid var(--line);
  background: var(--surface);
  padding: 1.5rem 1rem;
}
.app-sidebar a {
  display: block;
  padding: 0.55rem 0.8rem;
  border-radius: var(--radius);
  color: var(--ink-soft);
  font-size: 0.92rem;
  font-weight: 500;
  margin-bottom: 0.2rem;
}
.app-sidebar a:hover { background: var(--surface-2); text-decoration: none; color: var(--ink); }
.app-sidebar a.active { background: var(--brand-soft); color: var(--brand-strong); }
.app-main { flex: 1; padding: 2rem; max-width: 980px; }
.app-main h1 { font-size: 1.7rem; margin-bottom: 0.3rem; }
.page-lead { margin-bottom: 1.8rem; }

.row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.stack { display: flex; flex-direction: column; gap: 1.2rem; }
.inline-form { display: flex; gap: 0.7rem; align-items: flex-end; flex-wrap: wrap; }
.inline-form .field { margin-bottom: 0; min-width: 200px; }

.empty-state { text-align: center; padding: 3rem 1rem; color: var(--muted); }

@media (max-width: 760px) {
  .app-body { flex-direction: column; }
  .app-sidebar { width: 100%; border-right: none; border-bottom: 1px solid var(--line); display: flex; overflow-x: auto; gap: 0.3rem; padding: 0.8rem; }
  .app-sidebar a { white-space: nowrap; margin-bottom: 0; }
  .app-main { padding: 1.4rem; }
}
