/* LaMilla.online — hoja de estilos principal (sin dependencias) */
:root {
  --navy: #0b2a4a;
  --blue: #1c6fd6;
  --blue-dark: #155cb3;
  --green: #2fa84f;
  --green-dark: #23863d;
  --bg: #f4f7fb;
  --surface: #ffffff;
  --surface-2: #eaf0f8;
  --text: #15283f;
  --text-muted: #5b6b80;
  --border: #d9e2ee;
  --focus: #ffb703;
  --danger: #c2410c;
  --danger-bg: #fff4ed;
  --warn-bg: #fff8e1;
  --ok-bg: #edf9f0;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(11, 42, 74, .06), 0 4px 16px rgba(11, 42, 74, .06);
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --container: 1180px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0d1a2b; --surface: #15263b; --surface-2: #1d3047; --text: #e6edf5; --text-muted: #9fb0c4; --border: #2b4160;
    --blue: #6aaaf5; --blue-dark: #5aa0f2; --green: #4cc46b; --danger-bg: #3a1f14; --warn-bg: #3a3012; --ok-bg: #12301b;
    --shadow: 0 1px 2px rgba(0,0,0,.3), 0 4px 16px rgba(0,0,0,.25); color-scheme: dark;
  }
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { animation: none !important; transition: none !important; } }
body { margin: 0; font-family: var(--font); font-size: 16px; line-height: 1.55; color: var(--text); background: var(--bg); }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--blue-dark); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--blue); }
h1, h2, h3, h4 { line-height: 1.2; color: var(--navy); margin: 0 0 .5em; letter-spacing: -.01em; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) h1, :root:not([data-theme="light"]) h2, :root:not([data-theme="light"]) h3, :root:not([data-theme="light"]) h4 { color: #fff; } }
h1 { font-size: clamp(1.6rem, 2.6vw + 1rem, 2.3rem); }
h2 { font-size: clamp(1.25rem, 1.2vw + 1rem, 1.55rem); margin-top: .2em; }
h3 { font-size: 1.15rem; }
.h4 { font-size: 1.05rem; margin-bottom: .75rem; }
p { margin: 0 0 1em; }
.container { width: min(100% - 32px, var(--container)); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--navy); color: #fff; padding: 8px 12px; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }
.muted { color: var(--text-muted); }
.help { color: var(--text-muted); font-size: .9rem; margin: .75rem 0 0; }
.lead { font-size: 1.08rem; color: var(--text-muted); max-width: 70ch; }
.narrow { max-width: 76ch; }
.section { margin: 2.5rem 0; }
.page-head { margin: 1.5rem 0 1.25rem; }

/* Tokens extra: amarillo CTA y WhatsApp */
:root { --glass-heavy: rgba(255,255,255,.96); --yellow: #ffc800; --yellow-dark: #e6b400; --yellow-ink: #1a1a00; --wa: #25d366; --wa-dark: #1ebe5a; --glass: rgba(255,255,255,.78); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --glass: rgba(21,38,59,.82); --glass-heavy: rgba(21,38,59,.97); } }

/* Barra superior */
.topbar { background: var(--navy); color: #d6e0ec; font-size: .85rem; }
.topbar-inner { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 36px; }
.topbar-inner > span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar-wa { color: #fff; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; font-weight: 600; white-space: nowrap; min-height: 36px; }
.topbar-wa svg { color: var(--wa); }

/* Cabecera translúcida (material) */
.site-header { background: var(--glass); -webkit-backdrop-filter: blur(18px) saturate(160%); backdrop-filter: blur(18px) saturate(160%); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 50; }
@media (prefers-reduced-transparency: reduce) { .site-header { background: var(--surface); -webkit-backdrop-filter: none; backdrop-filter: none; } }
.header-inner { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; grid-template-areas: "brand search toggle" "nav nav nav"; align-items: center; gap: 12px; padding: 10px 0; }
.brand { grid-area: brand; display: block; width: 150px; }
.brand img { width: 150px; height: auto; }
.search { grid-area: search; display: flex; min-width: 0; }
.search input { flex: 1; min-width: 0; height: 44px; border: 1px solid var(--border); border-right: 0; border-radius: 12px 0 0 12px; padding: 0 12px; font: inherit; background: var(--surface); color: var(--text); }
.search button { width: 48px; height: 44px; border: 1px solid var(--border); background: var(--navy); color: #fff; border-radius: 0 12px 12px 0; cursor: pointer; display: grid; place-items: center; }
.nav-toggle { grid-area: toggle; width: 44px; height: 44px; border: 1px solid var(--border); background: var(--surface); color: var(--navy); border-radius: 12px; cursor: pointer; display: grid; place-items: center; }
.nav { grid-area: nav; display: none; }
.nav.open { display: block; }
.nav-list { list-style: none; margin: 0; padding: 6px 0 0; display: flex; flex-direction: column; gap: 2px; }
.nav-btn, .nav-link { display: flex; align-items: center; justify-content: space-between; gap: 6px; width: 100%; min-height: 46px; padding: 8px 12px; border: 0; border-radius: 10px; background: none; font: inherit; font-weight: 600; color: var(--text); text-decoration: none; cursor: pointer; text-align: left; transition: background .15s; }
.nav-btn:hover, .nav-link:hover { background: var(--surface-2); color: var(--navy); }
.nav-btn:active, .nav-link:active { transform: scale(.985); }
.nav-accent { color: var(--green-dark); }
.caret { width: 8px; height: 8px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); transition: transform .2s; margin-top: -3px; }
.nav-btn[aria-expanded="true"] .caret { transform: rotate(225deg); margin-top: 3px; }
.mega { display: none; }
.has-mega.open .mega { display: block; }
.mega-grid { display: grid; gap: 14px 24px; grid-template-columns: 1fr; padding: 6px 0 10px; }
.mega-col ul { list-style: none; margin: 0; padding: 0; }
.mega-col li a { display: block; padding: 6px 10px; border-radius: 8px; text-decoration: none; color: var(--text); font-size: .95rem; }
.mega-col li a:hover { background: var(--surface-2); color: var(--blue-dark); }
.mega-title { display: block; font-weight: 700; color: var(--navy); text-decoration: none; padding: 6px 10px; font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; }
.mega-cta { background: var(--surface-2); border-radius: 12px; padding: 8px 6px 12px; }
.mega-cta .btn { margin: 8px 10px 0; }
.mega-cta p { padding: 0 10px; font-size: .9rem; }
@media (min-width: 1100px) {
  .header-inner { grid-template-columns: auto minmax(160px, 1fr) auto; grid-template-areas: "brand search nav"; }
  .brand { width: 170px; } .brand img { width: 170px; }
  .nav { display: block; }
  .nav-toggle { display: none; }
  .search { max-width: 340px; width: 100%; justify-self: end; min-width: 0; }
  .search input { width: 0; }
  .nav-list { flex-direction: row; gap: 2px; padding: 0; }
  .nav-btn, .nav-link { width: auto; min-height: 44px; padding: 8px 12px; font-size: .95rem; }
  .has-mega { position: static; }
  .mega { display: block; position: absolute; left: 0; right: 0; top: 100%; background: var(--glass-heavy); -webkit-backdrop-filter: blur(28px) saturate(160%); backdrop-filter: blur(28px) saturate(160%); border-bottom: 1px solid var(--border); box-shadow: 0 24px 48px -24px rgba(11,42,74,.35); opacity: 0; visibility: hidden; transform: translateY(-6px); transform-origin: top center; transition: opacity .18s ease, transform .22s cubic-bezier(.2,.8,.2,1), visibility 0s linear .22s; z-index: 60; }
  .has-mega:hover .mega, .has-mega.open .mega, .has-mega:focus-within .mega { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
  .mega-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 22px 0 26px; }
  #mega-finanzas .mega-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  @media (prefers-reduced-transparency: reduce) { .mega { background: var(--surface); -webkit-backdrop-filter: none; backdrop-filter: none; } }
  @media (prefers-reduced-motion: reduce) { .mega { transform: none; transition: opacity .15s; } }
}
/* Migas */
.crumbs { font-size: .88rem; margin: 12px auto 0; }
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 4px; padding: 0; margin: 0; }
.crumbs li + li::before { content: "›"; color: var(--text-muted); margin: 0 4px; }
.crumbs a { color: var(--text-muted); }
.crumbs span { color: var(--text); }

/* Layout principal */
.layout-main { display: grid; grid-template-columns: 1fr; gap: 32px; }
@media (min-width: 1024px) { .layout-main { grid-template-columns: minmax(0, 1fr) 300px; } .sidebar { position: sticky; top: 90px; align-self: start; } }
.sidebar .card { margin-top: 16px; }
.two-col { display: grid; gap: 24px; }
@media (min-width: 720px) { .two-col { grid-template-columns: 1fr 1fr; } }

/* Tarjetas */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.cards-grid { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.card-link { display: flex; flex-direction: column; gap: 4px; text-decoration: none; color: var(--text); min-height: 44px; transition: transform .15s, box-shadow .15s; }
.card-link:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(11,42,74,.12); color: var(--navy); }
.card-kicker { font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; color: var(--green-dark); font-weight: 600; }
.pair-card { display: flex; flex-direction: column; gap: 4px; }
.pair-card a { text-decoration: none; }
.chip-list { list-style: none; padding: 0; margin: 0 0 1rem; display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; min-height: 40px; padding: 6px 14px; border-radius: 999px; background: var(--surface); border: 1px solid var(--border); text-decoration: none; color: var(--text); font-size: .93rem; }
.chip:hover { border-color: var(--blue); color: var(--blue-dark); }
.chip-strong { background: var(--navy); color: #fff; border-color: var(--navy); }
.chip-strong:hover { color: #fff; background: var(--blue-dark); }
.link-list { list-style: none; padding: 0; margin: 0; }
.link-list li { padding: 6px 0; border-bottom: 1px solid var(--border); }
.link-list li:last-child { border-bottom: 0; }
.link-list a { text-decoration: none; }

/* Portada tipo directorio */
.hero { display: grid; grid-template-columns: minmax(0, 1fr); gap: 28px; padding: 2.4rem 0 1rem; align-items: center; }
.hero > * { min-width: 0; }
@media (min-width: 900px) { .hero { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); } }
.eyebrow { display: inline-block; background: var(--yellow); color: var(--yellow-ink); font-weight: 700; font-size: .78rem; letter-spacing: .08em; text-transform: uppercase; padding: 4px 10px; border-radius: 999px; margin-bottom: 12px; }
.hero h1 { font-size: clamp(1.9rem, 3.4vw + 1rem, 3rem); line-height: 1.08; letter-spacing: -.02em; }
.hero-search { display: flex; gap: 8px; max-width: 640px; margin-top: 1rem; }
.hero-search input { flex: 1; min-width: 0; height: 52px; border: 1px solid var(--border); border-radius: 12px; padding: 0 14px; font: inherit; font-size: 1.05rem; background: var(--surface); color: var(--text); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.stats { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.stats li { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 16px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 2px; }
.stats strong { font-size: 1.7rem; color: var(--navy); letter-spacing: -.02em; line-height: 1; }
.stats span { color: var(--text-muted); font-size: .88rem; }
.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.section-head h2 { margin: 0; }
.section-head a { font-weight: 600; text-decoration: none; }
.dir-grid { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.dir-card { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 16px; box-shadow: var(--shadow); transition: transform .18s cubic-bezier(.2,.8,.2,1), box-shadow .18s; }
.dir-card:hover { transform: translateY(-2px); box-shadow: 0 12px 30px -12px rgba(11,42,74,.3); }
.dir-card-accent { border-color: var(--yellow); background: linear-gradient(180deg, #fff9df, var(--surface) 60%); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .dir-card-accent { background: linear-gradient(180deg, #3a3012, var(--surface) 60%); } }
.dir-head { display: flex; gap: 12px; align-items: center; text-decoration: none; color: var(--text); margin-bottom: 10px; }
.dir-head strong { display: block; color: var(--navy); font-size: 1.05rem; }
.dir-head small { color: var(--text-muted); }
.dir-icon { width: 46px; height: 46px; border-radius: 12px; background: var(--surface-2); color: var(--blue-dark); display: grid; place-items: center; font-weight: 800; font-size: 1.3rem; flex: none; }
.dir-card-accent .dir-icon { background: var(--yellow); color: var(--yellow-ink); }
.dir-links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.dir-links a { display: inline-flex; align-items: center; min-height: 34px; padding: 4px 10px; border-radius: 999px; background: var(--surface-2); color: var(--text); text-decoration: none; font-size: .88rem; }
.dir-links a:hover { background: var(--blue); color: #fff; }
.dir-links a.more { background: transparent; border: 1px dashed var(--border); color: var(--text-muted); }
.card-go { color: var(--blue-dark); font-weight: 600; font-size: .9rem; margin-top: auto; }
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); counter-reset: s; }
.steps li { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 18px; }
.steps strong { display: block; color: var(--navy); margin: 8px 0 4px; }
.steps p { margin: 0; color: var(--text-muted); font-size: .95rem; }
.step-n { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--yellow); color: var(--yellow-ink); font-weight: 800; }
.why { list-style: none; padding: 0; display: grid; gap: 10px; }
.why li { padding-left: 28px; position: relative; }
.why li::before { content: ""; position: absolute; left: 0; top: .45em; width: 16px; height: 16px; border-radius: 50%; background: var(--green); }
.cta-band { background: var(--navy); color: #fff; padding: 2.5rem 0; margin-top: 3rem; }
.cta-band h2 { color: #fff; margin-bottom: .4rem; }
.cta-band p { color: #c9d6e6; margin: 0; max-width: 60ch; }
.cta-band-inner { display: flex; flex-wrap: wrap; gap: 20px; align-items: center; justify-content: space-between; }
.cta-band-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.big-link { font-size: 1.4rem; font-weight: 700; text-decoration: none; }
.contact-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.wa-float { position: fixed; right: 16px; bottom: 16px; z-index: 55; display: inline-flex; align-items: center; gap: 8px; background: var(--wa); color: #fff; font-weight: 700; padding: 12px 16px; border-radius: 999px; text-decoration: none; box-shadow: 0 10px 24px -8px rgba(37,211,102,.7); transition: transform .15s cubic-bezier(.2,.8,.2,1), background .15s; }
.wa-float:hover { background: var(--wa-dark); color: #fff; transform: translateY(-2px); }
.wa-float:active { transform: scale(.96); }
.wa-float svg { width: 24px; height: 24px; }
@media (max-width: 640px) { .wa-float span { display: none; } .wa-float { padding: 14px; } }

/* Formularios y conversor */
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field label { font-size: .88rem; font-weight: 600; color: var(--text-muted); }
.field input, .field select, .field textarea, .field output { width: 100%; min-height: 48px; border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; font: inherit; font-size: 1.05rem; background: var(--surface); color: var(--text); }
.field textarea { min-height: 96px; resize: vertical; }
.field input[readonly] { background: var(--surface-2); }
.field input:focus, .field select:focus, .field textarea:focus, .search input:focus, .hero-search input:focus, button:focus-visible, a:focus-visible, summary:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.field input[aria-invalid="true"], .field textarea[aria-invalid="true"] { border-color: var(--danger); }
.field-error { color: var(--danger); font-size: .88rem; margin: 0; }
.field-wide { grid-column: 1 / -1; }
.calc-inline { display: flex; align-items: center; font-weight: 700; color: var(--navy); background: var(--surface-2); }
.conv-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; align-items: end; }
.conv-grid > .btn-swap { grid-column: 1 / -1; justify-self: center; }
.conv-grid-fx { grid-template-columns: 1fr; }
@media (min-width: 720px) {
  .conv-grid { grid-template-columns: 1.1fr 1.4fr auto 1.1fr 1.4fr; }
  .conv-grid > .btn-swap { grid-column: auto; }
  .conv-grid-fx { grid-template-columns: repeat(3, 1fr); }
  .conv-grid-fx > .field-wide { grid-column: 1 / -1; }
}
.btn-swap { width: 48px; height: 48px; border-radius: 50%; border: 1px solid var(--border); background: var(--surface-2); color: var(--navy); cursor: pointer; display: grid; place-items: center; transition: background .15s, transform .15s; }
.btn-swap:hover { background: var(--blue); color: #fff; transform: rotate(180deg); }
.btn-swap:active { transform: rotate(180deg) scale(.95); }
.conv-tools { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; margin-top: 14px; }
.conv-equation { margin: 0; font-weight: 600; color: var(--navy); font-size: 1.05rem; }
.conv-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 10px; }
.precision { display: inline-flex; align-items: center; gap: 8px; font-size: .9rem; color: var(--text-muted); }
.precision select { min-height: 40px; border: 1px solid var(--border); border-radius: 8px; padding: 4px 8px; font: inherit; background: var(--surface); color: var(--text); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 8px 18px; border-radius: 12px; font: inherit; font-weight: 700; cursor: pointer; border: 1px solid transparent; text-decoration: none; transition: background .15s, color .15s, transform .12s cubic-bezier(.2,.8,.2,1), box-shadow .15s; }
.btn:active { transform: scale(.97); }
.btn-lg { min-height: 52px; padding: 10px 24px; font-size: 1.05rem; }
.btn-cta { background: var(--yellow); color: var(--yellow-ink); box-shadow: 0 6px 18px -8px rgba(255,200,0,.9); }
.btn-cta:hover { background: var(--yellow-dark); color: var(--yellow-ink); }
.btn-wa { background: var(--wa); color: #fff; }
.btn-wa:hover { background: var(--wa-dark); color: #fff; }
.btn-primary { background: var(--blue); color: #fff; }
.btn-primary:hover { background: var(--blue-dark); color: #fff; }
.btn-ghost { background: var(--surface); color: var(--navy); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--blue); color: var(--blue-dark); }
.btn-ghost.copied { background: var(--ok-bg); border-color: var(--green); color: var(--green-dark); }
.calc-form { display: grid; grid-template-columns: 1fr; gap: 12px; }
@media (min-width: 640px) { .calc-form { grid-template-columns: 1fr 1fr; } }
.calc-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.calc-tabs button { min-height: 40px; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); color: var(--text); font: inherit; cursor: pointer; }
.calc-tabs button[aria-selected="true"] { background: var(--navy); color: #fff; border-color: var(--navy); }
.calc-result, .result-box { margin-top: 14px; padding: 14px 16px; border-radius: 10px; background: var(--surface-2); min-height: 48px; font-size: 1.1rem; }
.calc-result:empty, .result-box:empty { display: none; }
.result-box strong, .calc-result strong { color: var(--navy); font-size: 1.35rem; }
.result-main { font-size: 1.4rem; font-weight: 700; color: var(--navy); display: block; }
.result-sub { color: var(--text-muted); font-size: .95rem; }
.breakdown { display: grid; grid-template-columns: 1fr auto; gap: 4px 16px; margin: 12px 0 0; font-size: .95rem; }
.breakdown:empty { display: none; }
.breakdown dt { color: var(--text-muted); }
.breakdown dd { margin: 0; text-align: right; font-variant-numeric: tabular-nums; }
.breakdown .total { font-weight: 700; color: var(--navy); border-top: 1px solid var(--border); padding-top: 4px; }
.hp { position: absolute; left: -9999px; }

/* Precio cripto */
.price-card { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 16px; background: var(--navy); color: #fff; border-radius: var(--radius); padding: 16px 20px; margin-bottom: 8px; }
.price-card .price-label { width: 100%; font-size: .85rem; opacity: .85; }
.price-card .price-value { font-size: 2rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.price-card .muted { color: #c9d6e6; }
.up { color: var(--green); font-weight: 600; }
.down { color: #ff7a59; font-weight: 600; }
.price-card .up { color: #7ee29a; } .price-card .down { color: #ffb199; }

/* Fuente / avisos */
.source { font-size: .88rem; color: var(--text-muted); margin: 10px 0; }
.source-error { color: var(--danger); }
.attribution { font-size: .8rem; color: var(--text-muted); margin: 0 0 1rem; }
.badge { display: inline-block; padding: 1px 8px; border-radius: 999px; font-size: .78rem; font-weight: 600; }
.badge-warn { background: var(--warn-bg); color: #8a5a00; }
.badge-error { background: var(--danger-bg); color: var(--danger); }
.notice { background: var(--surface-2); border-left: 4px solid var(--blue); border-radius: 8px; padding: 12px 16px; margin: 1.25rem 0; font-size: .95rem; }
.notice p:last-child, .notice ul { margin-bottom: 0; }
.notice-warn { background: var(--warn-bg); border-left-color: #e0a100; }
.notice-ok { background: var(--ok-bg); border-left-color: var(--green); }

/* Contenido */
.prose { max-width: 78ch; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin-bottom: .35em; }
.formula { font-family: var(--mono); background: var(--surface-2); border-radius: 8px; padding: 10px 14px; font-size: .95rem; overflow-x: auto; }
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); }
.table { width: 100%; border-collapse: collapse; font-size: .95rem; font-variant-numeric: tabular-nums; }
.table th, .table td { padding: 9px 12px; border-bottom: 1px solid var(--border); text-align: left; white-space: nowrap; }
.table thead th { background: var(--surface-2); color: var(--navy); font-weight: 600; position: sticky; top: 0; }
.table tbody tr:last-child td { border-bottom: 0; }
.table tbody tr:hover { background: var(--surface-2); }
.matrix th[scope="row"] { font-weight: 600; }
.unit-list { display: grid; gap: 10px; margin: 0; }
.unit-list div { padding: 10px 14px; background: var(--surface); border: 1px solid var(--border); border-radius: 10px; }
.unit-list dt { font-weight: 700; color: var(--navy); }
.unit-list dd { margin: 2px 0 0; font-size: .95rem; }
.faq details { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 0 16px; margin-bottom: 8px; }
.faq summary { cursor: pointer; font-weight: 600; padding: 12px 0; color: var(--navy); list-style: none; display: flex; justify-content: space-between; gap: 8px; min-height: 44px; align-items: center; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.3rem; color: var(--blue); }
.faq details[open] summary::after { content: "–"; }
.faq details p { margin: 0 0 14px; }

/* Publicidad: etiquetado, separado de los controles, sin desplazamiento de contenido */
.ad { margin: 20px auto; text-align: center; }
.ad-label { display: block; font-size: .7rem; text-transform: uppercase; letter-spacing: .1em; color: var(--text-muted); margin-bottom: 4px; }
.ad-placeholder { border: 1px dashed var(--border); border-radius: 8px; color: var(--text-muted); font-size: .85rem; display: grid; place-items: center; background: var(--surface); }
.ad-top .ad-placeholder, .ad-footer .ad-placeholder { min-height: 90px; }
.ad-result .ad-placeholder, .ad-content .ad-placeholder { min-height: 250px; max-width: 728px; margin-inline: auto; }
.ad-sidebar .ad-placeholder { min-height: 600px; }
.ad-top, .ad-footer { width: min(100% - 32px, var(--container)); }
.ad ins.adsbygoogle { min-height: 90px; }
.ad-result ins.adsbygoogle, .ad-content ins.adsbygoogle { min-height: 250px; }
.ad-sidebar ins.adsbygoogle { min-height: 250px; }
@media (max-width: 1023px) { .ad-sidebar { display: none; } }

/* Consentimiento */
.consent { position: fixed; inset-inline: 0; bottom: 0; background: var(--surface); border-top: 1px solid var(--border); box-shadow: 0 -4px 20px rgba(0,0,0,.12); z-index: 60; padding: 14px 0; }
.consent-inner { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; }
.consent p { margin: 0; font-size: .92rem; max-width: 80ch; }
.consent-actions { display: flex; gap: 8px; }

/* Pie */
.site-footer { margin-top: 3rem; background: var(--navy); color: #d6e0ec; padding: 2.5rem 0 1.5rem; }
.site-footer h2 { color: #fff; font-size: 1rem; margin-bottom: .6rem; }
.site-footer a { color: #e8f0fa; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { padding: 3px 0; }
.footer-grid { display: grid; gap: 24px; grid-template-columns: 1fr; font-size: .93rem; }
@media (min-width: 720px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr 1fr; } }
.footer-logo { background: #fff; border-radius: 8px; padding: 6px 10px; margin-bottom: 10px; width: 160px; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.15); margin-top: 1.5rem; padding-top: 1rem; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; font-size: .85rem; }
.footer-bottom p { margin: 0; }
.footer-wa { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; color: #7ee29a !important; text-decoration: none; }
.muted-light { color: #9fb0c4; font-size: .85rem; }
.to-top { color: #c9d6e6; }
.credits a { font-weight: 600; color: #7ee29a; }
