/* Nexo Local — identidad "Albarán" (aprobada 2026-10-02). Tokens: docs/identidad-visual.md */
@font-face {
  font-family: 'Source Serif 4';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(fonts/SourceSerif4-600-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Source Serif 4';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(fonts/SourceSerif4-600-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Source Sans 3';
  font-style: normal;
  font-weight: 200 900;
  font-display: swap;
  src: url(fonts/SourceSans3-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Source Sans 3';
  font-style: normal;
  font-weight: 200 900;
  font-display: swap;
  src: url(fonts/SourceSans3-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --bg: #F7F4EC;
  --surface: #FFFFFF;
  --surface-alt: #EFEBDF;
  --bg-inverse: #1B2530;
  --text: #1B2530;
  --text-secondary: #4A5563;
  --text-inverse: #F7F4EC;
  --text-inverse-secondary: #B8C0CC;
  --primary: #17456B;
  --primary-hover: #0F3555;
  --on-primary: #FFFFFF;
  --accent: #B5471B;
  --accent-hover: #8F3714;
  --border: #D9D3C5;
  --border-control: #6B7480;
  --focus: #17456B;
  --ok: #1E6B3C;
  --warn: #8A5A00;
  --warn-bg: #FFF3D6;
  --warn-border: #E0B04A;
  --danger: #B3261E;
  --display: "Source Serif 4", Georgia, "Times New Roman", serif;
  --sans: "Source Sans 3", system-ui, "Segoe UI", Roboto, Arial, sans-serif;
  --radius: 8px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 4.5rem; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 1rem/1.65 var(--sans);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { font-family: var(--display); line-height: 1.15; margin: 0 0 .6em; font-weight: 600; letter-spacing: -.01em; }
h1 { font-size: clamp(2rem, 6.2vw, 3.6rem); }
h2 { font-size: clamp(1.6rem, 4.2vw, 2.4rem); }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }
a { color: var(--primary); }
img, svg { max-width: 100%; }

:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }

.skip {
  position: absolute; left: .5rem; top: -4rem; z-index: 100;
  background: var(--primary); color: var(--on-primary); padding: .6rem 1rem; border-radius: 8px; font-weight: 600;
}
.skip:focus { top: .5rem; }

.wrap { width: 100%; max-width: 68rem; margin: 0 auto; padding: 0 1.25rem; }
.narrow { max-width: 44rem; }
.center { text-align: center; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}
.header-row { display: flex; align-items: center; gap: 1rem; min-height: 3.5rem; }
.brand { display: inline-flex; align-items: center; gap: .6rem; color: var(--text); text-decoration: none; font: 600 1.1rem var(--display); }
.brand-mark {
  display: block; flex: none; width: 1.9rem; height: 1.9rem;
}
.nav { display: flex; gap: .25rem; margin-left: auto; }
.nav a { color: var(--text); text-decoration: none; padding: .5rem .7rem; border-radius: 8px; font-size: .95rem; }
.nav a:hover { color: var(--primary); background: var(--surface-alt); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; text-align: center;
  min-height: 2.9rem; padding: .7rem 1.4rem; border-radius: var(--radius); border: 2px solid var(--primary);
  background: var(--primary); color: var(--on-primary); font: 700 1rem var(--sans); text-decoration: none; cursor: pointer;
  transition: background .15s, border-color .15s, transform .15s;
}
.btn:hover { background: var(--primary-hover); border-color: var(--primary-hover); }
.btn:active { transform: translateY(1px); }
.btn-ghost { background: transparent; color: var(--primary); }
.btn-ghost:hover { background: rgba(23, 69, 107, .08); border-color: var(--primary); }
.btn-small { min-height: 2.6rem; padding: .5rem 1rem; font-size: .92rem; }
.cta-row { display: flex; flex-wrap: wrap; gap: .8rem; margin: 1.6rem 0 1rem; }
.cta-row.tight { margin: 1rem 0 .4rem; }

/* Hero */
.hero {
  position: relative; overflow: hidden; padding: clamp(3rem, 9vw, 6.5rem) 0 clamp(2.5rem, 7vw, 4.5rem);
}
.hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .45;
  background-image: linear-gradient(var(--border) 1px, transparent 1px), linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse at 20% 30%, #000 0, transparent 70%);
  mask-image: radial-gradient(ellipse at 20% 30%, #000 0, transparent 70%);
}
.hero-inner { position: relative; max-width: 52rem; margin-left: max(1.25rem, calc((100% - 68rem) / 2)); }
.eyebrow { color: var(--primary); font-weight: 600; font-size: .9rem; letter-spacing: .04em; text-transform: uppercase; }
.lead { font-size: clamp(1.05rem, 2.6vw, 1.25rem); color: var(--text); max-width: 42rem; }
.status-note { color: var(--text-secondary); font-size: .9rem; border-left: 3px solid var(--warn-border); padding-left: .8rem; max-width: 40rem; }

/* Sections */
.section { padding: clamp(2.8rem, 8vw, 5rem) 0; }
.section.alt { background: var(--surface-alt); border-block: 1px solid var(--border); }
.section-sub { color: var(--text-secondary); margin-bottom: 2rem; max-width: 40rem; }

/* Steps */
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); counter-reset: none; }
.steps li { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.3rem; position: relative; }
.steps p { color: var(--text-secondary); margin: 0; }
.step-n {
  display: inline-grid; place-items: center; width: 2rem; height: 2rem; border-radius: 50%;
  border: 2px solid var(--primary); color: var(--primary); font: 700 .95rem var(--sans); margin-bottom: .8rem;
}


/* Hero facts */
.hero-facts { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .4rem 1.4rem; color: var(--text-secondary); font-size: .95rem; }
.hero-facts li { display: inline-flex; align-items: center; gap: .45rem; }
.hero-facts li::before { content: ""; width: .5rem; height: .5rem; border-radius: 2px; background: var(--primary); flex: none; }

/* Cards (qué hace, confianza) */
.cards { list-style: none; margin: 0; padding: 0; display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr)); }
.cards li { background: var(--surface); border: 1px solid var(--border); border-top: 3px solid var(--primary); border-radius: var(--radius); padding: 1.3rem; }
.cards p { color: var(--text-secondary); margin: 0; }

/* IA: cuatro hechos */
.facts { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; counter-reset: fact; border-top: 1px solid var(--border); }
.facts li { counter-increment: fact; display: grid; align-content: start; grid-template-columns: 2.6rem 1fr; column-gap: 1rem; padding: 1.1rem 0; border-bottom: 1px solid var(--border); }
.facts li::before {
  content: counter(fact); grid-row: span 2; display: inline-grid; place-items: center; width: 2.2rem; height: 2.2rem;
  border-radius: 50%; border: 2px solid var(--primary); color: var(--primary); font: 700 1rem var(--sans);
}
.facts h3 { margin: .2rem 0 .3rem; }
.facts p { color: var(--text-secondary); margin: 0; }
@media (min-width: 52rem) {
  .facts { grid-template-columns: 1fr 1fr; column-gap: 2.5rem; border-top: 0; }
  .facts li:nth-child(-n+2) { border-top: 1px solid var(--border); }
}
.note { color: var(--text-secondary); font-size: .95rem; margin: 1.2rem 0 0; }

/* Demo */
.demo { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: clamp(1rem, 3.5vw, 1.6rem); max-width: 46rem; }
.demo-noscript { color: var(--text-secondary); }
.demo-media { padding: 0; overflow: hidden; }
.demo-video { display: block; width: 100%; height: auto; background: var(--surface); }
.demo-pick { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1.2rem; }
.demo-pick button {
  font: 600 .92rem var(--sans); color: var(--text); background: var(--surface); cursor: pointer;
  border: 1px solid var(--border-control); border-radius: 999px; padding: .45rem .95rem; min-height: 2.6rem;
}
.demo-pick button:hover { border-color: var(--primary); color: var(--primary); }
.demo-pick button[aria-pressed="true"] { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }

.demo-progress { list-style: none; margin: 0 0 1.2rem; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: .35rem; counter-reset: paso; }
.demo-progress li {
  counter-increment: paso; font-size: .8rem; color: var(--text-secondary); text-align: center;
  border-top: 4px solid var(--border); padding-top: .4rem; line-height: 1.3;
}
.demo-progress li::before { content: counter(paso) ". "; }
.demo-progress li.done { border-top-color: var(--primary); }
.demo-progress li[aria-current="step"] { border-top-color: var(--primary); color: var(--text); font-weight: 700; }

.demo-step-h { font-size: 1.2rem; margin-bottom: .4rem; }
.demo-step-h:focus { outline: none; }
.demo-step-h:focus-visible { outline: 3px solid var(--focus); }
.demo-explain { color: var(--text-secondary); margin-bottom: 1rem; }

.mail-card { border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg); margin-bottom: 1.2rem; overflow: hidden; }
.mail-head { margin: 0; padding: .7rem 1rem; border-bottom: 1px solid var(--border); font-size: .88rem; color: var(--text-secondary); display: grid; grid-template-columns: auto 1fr; gap: .1rem .6rem; }
.mail-head dt { font-weight: 600; }
.mail-head dd { margin: 0; overflow-wrap: anywhere; }
.mail-body { margin: 0; padding: .9rem 1rem; white-space: pre-wrap; overflow-wrap: anywhere; font: .95rem/1.55 var(--sans); }

.extract { margin: 0 0 1rem; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.extract div { display: grid; grid-template-columns: 6.5rem 1fr; gap: .8rem; padding: .6rem 1rem; border-bottom: 1px solid var(--border); }
.extract div:last-child { border-bottom: 0; }
.extract dt { color: var(--text-secondary); font-size: .9rem; font-weight: 600; }
.extract dd { margin: 0; overflow-wrap: anywhere; }
.chips { display: flex; flex-wrap: wrap; gap: .5rem; margin: 0 0 .5rem; padding: 0; list-style: none; }
.chip { display: inline-flex; align-items: center; gap: .35rem; font-size: .9rem; font-weight: 600; padding: .25rem .7rem; border-radius: 999px; border: 1px solid var(--border-control); background: var(--surface); color: var(--text); }
.chip-alta { color: var(--danger); border-color: var(--danger); background: #FDECEA; }
.chip-media { color: var(--warn); border-color: var(--warn-border); background: var(--warn-bg); }
.chip-baja { color: var(--text-secondary); background: var(--surface-alt); border-color: var(--border); }
.chip-ok { color: var(--ok); border-color: var(--ok); background: #E8F3EC; }
.why { color: var(--text-secondary); font-size: .92rem; margin-bottom: 1.2rem; }

.demo label { display: block; font-size: .9rem; font-weight: 600; color: var(--text-secondary); margin-bottom: .35rem; }
.wa-bubble { background: var(--surface-alt); border: 1px solid var(--border); border-radius: var(--radius) var(--radius) var(--radius) 2px; padding: .8rem 1rem; white-space: pre-wrap; overflow-wrap: anywhere; margin-bottom: 1rem; }
.demo-after { color: var(--text-secondary); font-size: .95rem; }

/* Formularios */
input, select, textarea {
  width: 100%; font: inherit; color: var(--text); background: var(--surface);
  border: 1px solid var(--border-control); border-radius: 8px; padding: .7rem .8rem; min-height: 2.9rem;
}
textarea { resize: vertical; line-height: 1.55; }
input:focus-visible, select:focus-visible, textarea:focus-visible { border-color: var(--focus); }
.contact-form { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: clamp(1rem, 4vw, 1.8rem); }
.form-grid { display: grid; gap: 1rem; grid-template-columns: 1fr; margin-bottom: 1.2rem; }
@media (min-width: 40rem) { .form-grid { grid-template-columns: 1fr 1fr; } .field-wide { grid-column: 1 / -1; } }
.contact-form label { display: block; font-weight: 600; margin-bottom: .35rem; }
.optional { font-weight: 400; color: var(--text-secondary); }
.hint { color: var(--text-secondary); font-size: .88rem; margin: .3rem 0 0; }
.field [aria-invalid="true"] { border-color: var(--danger); border-width: 2px; }
.form-error { color: var(--danger); border: 1px solid var(--danger); border-left-width: 4px; background: #FDECEA; padding: .6rem .9rem; border-radius: 8px; }
.form-error[hidden] { display: none; }
.form-status { min-height: 1.4rem; margin: .8rem 0; color: var(--ok); }
.privacy-note { color: var(--text-secondary); font-size: .88rem; margin: 0; }
.alt-contact { margin-top: 1.4rem; overflow-wrap: anywhere; }

/* Offer */
.offer { display: grid; gap: 1.5rem; grid-template-columns: 1fr; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: clamp(1.2rem, 4vw, 2rem); }
@media (min-width: 52rem) { .offer { grid-template-columns: 1fr 1.2fr; } }
.price { font: 600 1.2rem var(--display); margin-bottom: .3rem; }
.price span { font-size: clamp(2.6rem, 8vw, 3.8rem); color: var(--accent); }
.after { border-top: 1px solid var(--border); padding-top: 1rem; }
.list-price { color: var(--text-secondary); font-size: .95rem; border-top: 1px solid var(--border); padding-top: 1rem; margin-bottom: 0; }
.offer-lists h3 { font-family: var(--sans); font-size: .85rem; text-transform: uppercase; letter-spacing: .06em; color: var(--text-secondary); margin: 0 0 .5rem; }
.offer-lists ul { margin: 0 0 1.2rem; padding-left: 1.2rem; }
.offer-lists li { margin-bottom: .3rem; }
.offer-note { color: var(--text-secondary); margin: 1.2rem 0; max-width: 42rem; }

/* FAQ */
details { border-bottom: 1px solid var(--border); padding: .2rem 0; }
summary { cursor: pointer; font-weight: 600; padding: .9rem 0; list-style: none; display: flex; justify-content: space-between; gap: 1rem; align-items: center; min-height: 2.9rem; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; color: var(--primary); font-size: 1.4rem; line-height: 1; }
details[open] summary::after { content: "\2212"; }
details p { color: var(--text-secondary); padding-bottom: .8rem; margin: 0; }

/* Footer */
.site-footer { border-top: 1px solid var(--bg-inverse); padding: 1.5rem 0 2.5rem; background: var(--bg-inverse); color: var(--text-inverse-secondary); font-size: .9rem; }
.footer-row { display: flex; flex-wrap: wrap; gap: .4rem 2rem; }
.site-footer p { margin: 0; overflow-wrap: anywhere; }
.site-footer a { color: var(--text-inverse); }

/* Página legal */
.legal { padding: clamp(2rem, 6vw, 3.5rem) 0; }
.legal h1 { font-size: clamp(1.8rem, 5vw, 2.6rem); }
.legal h2 { font-size: 1.35rem; margin-top: 2rem; }
.legal dl { display: grid; grid-template-columns: 1fr; gap: .2rem; margin: 0 0 1rem; }
@media (min-width: 40rem) { .legal dl { grid-template-columns: 11rem 1fr; gap: .5rem 1rem; } }
.legal dt { font-weight: 600; }
.legal dd { margin: 0 0 .6rem; overflow-wrap: anywhere; }
.legal ul { padding-left: 1.2rem; }
.hueco { background: var(--warn-bg); border: 1px dashed var(--warn); color: var(--warn); padding: 0 .35rem; border-radius: 4px; font-weight: 600; }
.draft-banner { background: var(--warn-bg); border: 1px solid var(--warn-border); border-left: 4px solid var(--warn); color: var(--text); padding: .8rem 1rem; border-radius: 8px; margin-bottom: 1.5rem; }

/* Mobile */
@media (max-width: 40rem) {
  .hero-inner { margin-left: 0; }
  .nav { display: none; }
  .header-row { justify-content: space-between; }
  .btn-small { margin-left: auto; }
  .cta-row .btn { width: 100%; }
  .demo .btn, .contact-form .btn { width: 100%; }
  .extract div { grid-template-columns: 1fr; gap: .1rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn { transition: none; }
}

@media print {
  .site-header, .skip, .demo, .contact-form, .cta-row { display: none; }
  .section.alt { background: none; }
  body { background: #fff; }
}
