/*
 * Sistema de diseno de las paginas publicas (portada, blog, sectores,
 * herramientas gratis, quienes somos, paginas iman).
 * Sustituye a main.css + landing.css SOLO en esas paginas; el panel de
 * administracion y el login siguen con main.css.
 *
 * Direccion: papel calido + tinta + un acento teja. Tipografia Bricolage
 * Grotesque (titulares) + Inter (texto). Los productos se ensenan tal cual
 * son (capturas reales de las plantillas), sin maquetas inventadas.
 */

:root {
    --paper: #F5F0E6;
    --paper-2: #EDE5D6;
    --paper-3: #E3D8C4;
    --card: #FFFDF8;
    --ink: #16130E;
    --ink-2: #4A443A;
    --ink-3: #6B6357;
    --line: rgba(22, 19, 14, .13);
    --line-2: rgba(22, 19, 14, .22);
    --accent: #C2410C;          /* texto y botones: 5.2:1 con blanco, 4.6:1 sobre papel */
    --accent-deep: #9A3412;
    --accent-bright: #F0643A;   /* solo formas decorativas, nunca texto sobre claro */
    --accent-soft: #F9DCCB;
    --green: #1F4D3A;
    --green-soft: #D8E6DC;
    --night: #16130E;
    --night-2: #221E17;
    --on-night: #F5F0E6;
    --on-night-2: #BDB3A2;

    --font-display: 'Bricolage Grotesque', 'Inter', system-ui, sans-serif;
    --font-body: 'Inter', system-ui, -apple-system, sans-serif;

    --r-sm: 10px;
    --r-md: 16px;
    --r-lg: 24px;
    --r-xl: 36px;
    --shadow-1: 0 1px 2px rgba(22, 19, 14, .06), 0 4px 14px -6px rgba(22, 19, 14, .12);
    --shadow-2: 0 2px 4px rgba(22, 19, 14, .05), 0 22px 48px -20px rgba(22, 19, 14, .35);
    --ease: cubic-bezier(.2, .7, .2, 1);
    --wrap: 1180px;
    --gutter: clamp(16px, 4vw, 32px);
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 84px; }
body.site {
    margin: 0;
    background: var(--paper);
    color: var(--ink);
    font: 400 1.0625rem/1.6 var(--font-body);
    -webkit-font-smoothing: antialiased;
    overflow-x: clip;
}
.site img, .site svg { max-width: 100%; }
.site img { display: block; height: auto; }
/* :where() deja esta regla sin especificidad: los botones que son <a> conservan su color */
:where(.site) a { color: inherit; }
.site :focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
.site h1, .site h2, .site h3, .site h4 {
    font-family: var(--font-display);
    color: inherit;
    margin: 0;
    letter-spacing: -.02em;
    text-wrap: balance;
}
:where(.site) p { margin: 0; text-wrap: pretty; }
.skip-link {
    position: absolute; left: 12px; top: -60px; z-index: 200;
    background: var(--ink); color: var(--paper); padding: .6rem 1rem; border-radius: var(--r-sm);
}
.skip-link:focus { top: 12px; }

.wrap { width: min(var(--wrap), 100% - 2 * var(--gutter)); margin-inline: auto; }
.wrap-narrow { width: min(760px, 100% - 2 * var(--gutter)); margin-inline: auto; }

.s-section { padding-block: clamp(64px, 10vw, 128px); }
.s-section--tight { padding-block: clamp(48px, 7vw, 88px); }
.s-night { background: var(--night); color: var(--on-night); }
.s-paper2 { background: var(--paper-2); }

.eyebrow {
    display: inline-flex; align-items: center; gap: .5rem;
    font: 600 .8125rem/1 var(--font-body);
    letter-spacing: .12em; text-transform: uppercase;
    color: var(--accent);
}
.s-night .eyebrow { color: var(--accent-bright); }
/* Sobre el beige de las secciones alternas el teja no llega a 4.5:1: se usa el tono profundo */
.s-paper2 .eyebrow { color: var(--accent-deep); }
.eyebrow::before { content: ""; width: 22px; height: 2px; background: currentColor; }

.h-display { font-size: clamp(2.6rem, 6.4vw, 5rem); line-height: .98; font-weight: 700; }
.h-1 { font-size: clamp(2.1rem, 4.6vw, 3.5rem); line-height: 1.02; font-weight: 700; }
.h-2 { font-size: clamp(1.5rem, 2.6vw, 2rem); line-height: 1.1; font-weight: 650; }
.lede { font-size: clamp(1.1rem, 1.6vw, 1.3rem); line-height: 1.55; color: var(--ink-2); max-width: 60ch; }
.s-night .lede { color: var(--on-night-2); }
.muted { color: var(--ink-3); }
.s-head { display: grid; gap: 1rem; max-width: 720px; margin-bottom: clamp(32px, 5vw, 56px); }
.s-head--center { margin-inline: auto; text-align: center; justify-items: center; }
.accent-word { color: var(--accent); }
.s-night .accent-word { color: var(--accent-bright); }

/* ---------- Botones ---------- */
.btn-s {
    display: inline-flex; align-items: center; justify-content: center; gap: .55rem;
    min-height: 52px; padding: 0 1.5rem;
    border-radius: 999px; border: 1.5px solid transparent;
    font: 600 1rem/1 var(--font-body); text-decoration: none; cursor: pointer;
    transition: transform 180ms var(--ease), background 180ms, box-shadow 180ms, border-color 180ms;
}
.btn-s svg { width: 18px; height: 18px; transition: transform 180ms var(--ease); }
.btn-s:hover svg { transform: translateX(3px); }
.btn-s:active { transform: scale(.98); }
.btn-s--primary { background: var(--accent); color: #fff; box-shadow: 0 10px 24px -12px rgba(194, 65, 12, .8); }
.btn-s--primary:hover { background: var(--accent-deep); }
.btn-s--ghost { background: transparent; color: var(--ink); border-color: var(--line-2); }
.btn-s--ghost:hover { border-color: var(--ink); }
.s-night .btn-s--ghost { color: var(--on-night); border-color: rgba(245, 240, 230, .3); }
.s-night .btn-s--ghost:hover { border-color: var(--on-night); }
.btn-s--light { background: var(--paper); color: var(--ink); }
.btn-s--light:hover { background: #fff; }
.btn-s--sm { min-height: 42px; padding: 0 1.1rem; font-size: .9375rem; }
.btn-s--block { width: 100%; }

/* ---------- Navegacion ---------- */
.s-nav {
    position: sticky; top: 0; z-index: 100;
    background: color-mix(in srgb, var(--paper) 86%, transparent);
    backdrop-filter: saturate(1.4) blur(14px);
    -webkit-backdrop-filter: saturate(1.4) blur(14px);
    border-bottom: 1px solid transparent;
    transition: border-color 200ms;
}
.s-nav.is-scrolled { border-bottom-color: var(--line); }
.s-nav__in { display: flex; align-items: center; gap: 1.5rem; min-height: 68px; }
.s-logo {
    display: inline-flex; align-items: center; gap: .55rem;
    font: 700 1.25rem/1 var(--font-display); letter-spacing: -.02em; text-decoration: none; color: var(--ink);
}
.s-logo__mark {
    width: 30px; height: 30px; border-radius: 9px; background: var(--accent);
    display: grid; place-items: center; color: #fff;
}
.s-logo__mark svg { width: 18px; height: 18px; }
.s-logo b { color: var(--accent); font-weight: 700; }
.s-nav__links { display: flex; gap: .25rem; margin: 0 0 0 auto; padding: 0; list-style: none; }
.s-nav__links a {
    display: inline-flex; align-items: center; min-height: 40px; padding: 0 .8rem; border-radius: 999px;
    font-size: .9375rem; font-weight: 500; color: var(--ink-2); text-decoration: none;
}
.s-nav__links a:hover { color: var(--ink); background: var(--paper-2); }
.s-nav__actions { display: flex; align-items: center; gap: .6rem; }
.s-lang { display: inline-flex; border: 1px solid var(--line); border-radius: 999px; padding: 3px; }
.s-lang a {
    min-width: 36px; min-height: 32px; display: grid; place-items: center; border-radius: 999px;
    font-size: .8125rem; font-weight: 600; color: var(--ink-3); text-decoration: none;
}
.s-lang a[aria-current="true"] { background: var(--ink); color: var(--paper); }
.s-nav__toggle {
    display: none; margin-left: auto; width: 44px; height: 44px; border-radius: 12px;
    border: 1px solid var(--line-2); background: transparent; color: var(--ink); cursor: pointer;
}
.s-nav__toggle svg { width: 22px; height: 22px; }
.s-nav__login { font-size: .9375rem; font-weight: 600; text-decoration: none; padding: 0 .6rem; min-height: 40px; display: inline-flex; align-items: center; }

@media (max-width: 960px) {
    .s-nav__toggle { display: grid; place-items: center; }
    .s-nav__links, .s-nav__actions { display: none; }
    .s-nav.is-open .s-nav__panel { display: grid; }
}
.s-nav__panel {
    display: none; gap: .25rem; padding: .5rem var(--gutter) 1.25rem;
    border-top: 1px solid var(--line); background: var(--paper);
}
.s-nav__panel a {
    display: flex; align-items: center; min-height: 48px; padding: 0 .5rem;
    font-weight: 600; text-decoration: none; border-bottom: 1px solid var(--line);
}
.s-nav__panel .btn-s { margin-top: .75rem; border-bottom: 0; }
@media (min-width: 961px) { .s-nav__panel { display: none !important; } }

/* ---------- Hero ---------- */
.s-hero { position: relative; padding-block: clamp(40px, 7vw, 96px) clamp(56px, 8vw, 112px); overflow: clip; }
.s-hero__grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(32px, 5vw, 72px); align-items: center; }
.s-hero__copy { display: grid; gap: 1.5rem; justify-items: start; }
.s-hero__title { font-size: clamp(2.75rem, 6.6vw, 5.4rem); line-height: .95; font-weight: 750; }
.s-hero__title em { font-style: normal; color: var(--accent); }
.s-hero__cta { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; }
.s-hero__note { display: flex; flex-wrap: wrap; gap: .4rem 1.1rem; font-size: .9375rem; color: var(--ink-3); padding: 0; margin: 0; list-style: none; }
.s-hero__note li { display: inline-flex; align-items: center; gap: .4rem; }
.s-hero__note svg { width: 16px; height: 16px; color: var(--green); }

/* Tres moviles reales en abanico sobre un arco de color */
.s-phones { position: relative; aspect-ratio: 1 / 1.02; isolation: isolate; }
.s-phones::before {
    content: ""; position: absolute; inset: 8% 6% 0; z-index: -1;
    border-radius: 999px 999px var(--r-xl) var(--r-xl);
    background:
        radial-gradient(120% 80% at 50% 0%, var(--accent-soft), transparent 70%),
        var(--paper-2);
}
.s-phone {
    position: absolute; width: 44%; aspect-ratio: 375 / 780;
    border-radius: 34px; padding: 7px; background: var(--ink);
    box-shadow: var(--shadow-2);
    transition: transform 500ms var(--ease);
}
.s-phone img { width: 100%; height: 100%; object-fit: cover; object-position: top; border-radius: 28px; }
.s-phone--l { left: 2%; top: 14%; transform: rotate(-8deg); }
.s-phone--c { left: 28%; top: 2%; z-index: 2; width: 46%; }
.s-phone--r { right: 2%; top: 16%; transform: rotate(8deg); }
.s-phones:hover .s-phone--l { transform: rotate(-11deg) translateX(-10px); }
.s-phones:hover .s-phone--r { transform: rotate(11deg) translateX(10px); }
.s-phones__tag {
    position: absolute; z-index: 3; left: 50%; bottom: -2%; transform: translateX(-50%);
    display: inline-flex; align-items: center; gap: .5rem; white-space: nowrap;
    background: var(--card); border: 1px solid var(--line); border-radius: 999px;
    padding: .55rem 1rem; font-size: .875rem; font-weight: 600; box-shadow: var(--shadow-1);
}
.s-phones__tag i { width: 8px; height: 8px; border-radius: 50%; background: #22A35A; box-shadow: 0 0 0 4px #22A35A33; }

@media (max-width: 900px) {
    .s-hero__grid { grid-template-columns: 1fr; }
    .s-phones { max-width: 520px; width: 100%; margin-inline: auto; }
}

/* ---------- Franja de resultados ---------- */
.s-outcomes { display: grid; grid-template-columns: repeat(3, 1fr); border-block: 1px solid var(--line); }
.s-outcome { padding: clamp(24px, 3vw, 36px) clamp(16px, 2.4vw, 32px); display: grid; gap: .6rem; align-content: start; }
.s-outcome + .s-outcome { border-left: 1px solid var(--line); }
.s-outcome__ico { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent-deep); }
.s-outcome__ico svg { width: 22px; height: 22px; }
.s-outcome h3 { font-size: 1.25rem; font-weight: 650; }
.s-outcome p { color: var(--ink-2); font-size: 1rem; }
@media (max-width: 760px) {
    .s-outcomes { grid-template-columns: 1fr; }
    .s-outcome + .s-outcome { border-left: 0; border-top: 1px solid var(--line); }
}

/* ---------- Escaparate de plantillas ---------- */
.s-tpl { display: grid; grid-template-columns: 280px 1fr; gap: clamp(24px, 4vw, 56px); align-items: start; }
.s-tpl__tabs { display: grid; gap: .5rem; position: sticky; top: 96px; }
.s-tpl__tab {
    display: grid; grid-template-columns: 52px 1fr; gap: .9rem; align-items: center; text-align: left;
    padding: .7rem; border-radius: var(--r-md); border: 1.5px solid transparent;
    background: transparent; color: inherit; font: inherit; cursor: pointer;
    transition: background 180ms, border-color 180ms;
}
.s-tpl__tab img { width: 52px; height: 52px; border-radius: 12px; object-fit: cover; }
.s-tpl__tab strong { display: block; font: 650 1.05rem/1.2 var(--font-display); }
.s-tpl__tab span { font-size: .875rem; color: var(--on-night-2); }
.s-tpl__tab:hover { background: rgba(245, 240, 230, .06); }
.s-tpl__tab[aria-selected="true"] { background: rgba(245, 240, 230, .08); border-color: var(--accent-bright); }
.s-tpl__stage { display: grid; grid-template-columns: minmax(0, 300px) 1fr; gap: clamp(20px, 4vw, 48px); align-items: center; }
.s-tpl__phone {
    border-radius: 36px; padding: 8px; background: #000; box-shadow: 0 30px 70px -30px #000;
    aspect-ratio: 375 / 780; overflow: hidden;
}
.s-tpl__phone img { width: 100%; height: 100%; object-fit: cover; object-position: top; border-radius: 29px; }
.s-tpl__panel[hidden] { display: none; }
.s-tpl__info { display: grid; gap: 1rem; }
.s-tpl__info h3 { font-size: clamp(1.6rem, 3vw, 2.4rem); line-height: 1.05; }
.s-tpl__list { margin: 0; padding: 0; list-style: none; display: grid; gap: .55rem; color: var(--on-night-2); }
.s-tpl__list li { display: flex; gap: .6rem; }
.s-tpl__list li::before { content: ""; flex: none; width: 8px; height: 8px; margin-top: .55em; border-radius: 2px; background: var(--accent-bright); }
.s-tpl__photo { border-radius: var(--r-md); overflow: hidden; aspect-ratio: 3 / 2; }
.s-tpl__photo img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 960px) {
    .s-tpl { grid-template-columns: 1fr; }
    .s-tpl__tabs { position: static; grid-template-columns: repeat(2, 1fr); }
    .s-tpl__tab { grid-template-columns: 40px 1fr; }
    .s-tpl__tab img { width: 40px; height: 40px; }
}
@media (max-width: 640px) {
    .s-tpl__stage { grid-template-columns: 1fr; }
    .s-tpl__phone { max-width: 280px; margin-inline: auto; }
    .s-tpl__photo { display: none; }
}

/* ---------- Bento de funciones ---------- */
.s-bento { display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; }
.s-card {
    background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg);
    padding: clamp(20px, 2.4vw, 30px); display: grid; gap: .7rem; align-content: start;
}
.s-card h3 { font-size: 1.3rem; font-weight: 650; }
.s-card p { color: var(--ink-2); font-size: 1rem; }
.s-card__ico { width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center; background: var(--paper-2); color: var(--ink); }
.s-card__ico svg { width: 24px; height: 24px; }
.s-card--wide { grid-column: span 3; }
.s-card--third { grid-column: span 2; }
.s-card--feature { background: var(--green); color: #fff; border-color: transparent; }
.s-card--feature p { color: #D8E6DC; }
.s-card--feature .s-card__ico { background: rgba(255, 255, 255, .12); color: #fff; }
.s-card--accent { background: var(--accent-soft); border-color: transparent; }
.s-card--accent .s-card__ico { background: #fff; color: var(--accent-deep); }
.s-stamps { display: flex; flex-wrap: wrap; gap: 8px; margin-top: .4rem; }
.s-stamps span {
    width: 34px; height: 34px; border-radius: 50%; border: 2px dashed rgba(255, 255, 255, .45);
    display: grid; place-items: center; font-size: .9rem;
}
.s-stamps span.on { border-style: solid; border-color: #fff; background: rgba(255, 255, 255, .14); }
.s-push {
    display: grid; grid-template-columns: 38px 1fr; gap: .7rem; align-items: center;
    margin-top: .4rem; padding: .75rem; border-radius: 14px; background: #fff; box-shadow: var(--shadow-1);
}
.s-push b { display: block; font-size: .875rem; }
.s-push small { font-size: .8125rem; color: var(--ink-3); }
.s-push i { width: 38px; height: 38px; border-radius: 10px; background: var(--accent); display: grid; place-items: center; color: #fff; font-style: normal; }
.s-push i svg { width: 20px; height: 20px; }
@media (max-width: 900px) {
    .s-bento { grid-template-columns: repeat(2, 1fr); }
    .s-card--wide, .s-card--third { grid-column: span 2; }
}
@media (min-width: 560px) and (max-width: 900px) {
    .s-card--third { grid-column: span 1; }
}

/* ---------- Pasos ---------- */
.s-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(16px, 3vw, 40px); counter-reset: st; margin: 0; padding: 0; list-style: none; }
.s-step { counter-increment: st; display: grid; gap: .6rem; padding-top: 1.25rem; border-top: 2px solid var(--ink); }
.s-step::before { content: "0" counter(st); font: 700 clamp(2.6rem, 5vw, 4rem)/1 var(--font-display); color: var(--accent); letter-spacing: -.04em; }
.s-step h3 { font-size: 1.35rem; }
.s-step p { color: var(--ink-2); }
@media (max-width: 760px) { .s-steps { grid-template-columns: 1fr; } }

/* ---------- Precios ---------- */
.s-pricing { display: grid; grid-template-columns: repeat(2, minmax(0, 420px)); gap: 18px; justify-content: center; }
.s-plan {
    position: relative; display: grid; gap: 1.1rem; align-content: start;
    padding: clamp(24px, 3vw, 36px); border-radius: var(--r-lg);
    background: var(--card); border: 1px solid var(--line);
}
.s-plan--featured { background: var(--night); color: var(--on-night); border-color: var(--night); }
.s-plan__badge {
    position: absolute; top: -13px; right: 24px; padding: .35rem .8rem; border-radius: 999px;
    background: var(--accent); color: #fff; font-size: .8125rem; font-weight: 700;
}
.s-plan h3 { font-size: 1.35rem; }
.s-plan__price { display: flex; align-items: baseline; gap: .4rem; }
.s-plan__price strong { font: 750 clamp(2.8rem, 5vw, 3.6rem)/1 var(--font-display); letter-spacing: -.04em; }
.s-plan__price span { color: var(--ink-3); }
.s-plan--featured .s-plan__price span, .s-plan--featured .s-plan__note { color: var(--on-night-2); }
.s-plan__note { font-size: .9375rem; color: var(--ink-3); }
.s-plan ul { margin: 0; padding: 0; list-style: none; display: grid; gap: .6rem; }
.s-plan li { display: flex; gap: .6rem; }
.s-plan li svg { flex: none; width: 20px; height: 20px; margin-top: 2px; color: var(--green); }
.s-plan--featured li svg { color: var(--accent-bright); }
.s-plan__intro { font-weight: 600; font-size: .9375rem; }
@media (max-width: 760px) { .s-pricing { grid-template-columns: 1fr; } }

/* ---------- Tabla comparativa ---------- */
.s-table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--card); }
.s-table { width: 100%; border-collapse: collapse; min-width: 680px; font-size: .9688rem; }
.s-table th, .s-table td { padding: 1rem 1.1rem; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.s-table thead th { font: 650 .8125rem/1.2 var(--font-body); letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); background: var(--paper); }
.s-table tbody th { font-weight: 600; color: var(--ink-2); width: 22%; }
.s-table tr:last-child th, .s-table tr:last-child td { border-bottom: 0; }
.s-table .is-us { background: color-mix(in srgb, var(--accent-soft) 45%, transparent); font-weight: 650; color: var(--ink); }
.s-table thead .is-us { color: var(--accent-deep); background: var(--accent-soft); }
.s-footnote { font-size: .875rem; color: var(--ink-3); margin-top: 1rem; }
.s-footnote a { color: var(--ink-2); }

/* ---------- Calculadora ---------- */
.s-calc { display: grid; grid-template-columns: 1fr 1fr; border-radius: var(--r-lg); overflow: hidden; border: 1px solid var(--line); background: var(--card); }
.s-calc__form { padding: clamp(24px, 3vw, 36px); display: grid; gap: 1.1rem; align-content: start; }
.s-calc__out { padding: clamp(24px, 3vw, 36px); background: var(--night); color: var(--on-night); display: grid; gap: .9rem; align-content: center; }
.s-calc__out .big { font: 750 clamp(2rem, 4vw, 2.8rem)/1 var(--font-display); letter-spacing: -.03em; }
.s-calc__out .big--bad { color: #FFB199; }
.s-calc__out .big--good { color: #B7E3C5; }
.s-calc__out small { color: var(--on-night-2); }
.s-calc__out a { color: var(--on-night); }
@media (max-width: 760px) { .s-calc { grid-template-columns: 1fr; } }

/* ---------- Formularios ---------- */
.s-field { display: grid; gap: .4rem; }
.s-field label { font-size: .9375rem; font-weight: 600; }
.s-input {
    width: 100%; min-height: 50px; padding: .7rem .9rem;
    border: 1.5px solid var(--line-2); border-radius: 12px;
    background: #fff; color: var(--ink); font: 400 1rem var(--font-body);
}
textarea.s-input { min-height: 120px; resize: vertical; }
.s-input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }

/* ---------- Sectores con foto ---------- */
.s-sectors { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.s-sector {
    position: relative; isolation: isolate; overflow: hidden; border-radius: var(--r-md);
    aspect-ratio: 4 / 3.2; display: flex; align-items: flex-end; padding: 1rem;
    text-decoration: none; color: #fff; background: var(--night-2);
}
.site .s-sector { color: #fff; }
.s-sector img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transition: transform 600ms var(--ease); }
.s-sector::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, transparent 35%, rgba(22, 19, 14, .85)); }
.s-sector:hover img { transform: scale(1.05); }
.s-sector span { font: 650 1.1rem/1.15 var(--font-display); display: flex; justify-content: space-between; width: 100%; align-items: center; gap: .5rem; }
.s-sector span svg { width: 18px; height: 18px; flex: none; }
@media (max-width: 960px) { .s-sectors { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 640px) { .s-sectors { grid-template-columns: repeat(2, 1fr); } .s-sector span { font-size: 1rem; } }

/* ---------- FAQ ---------- */
.s-faq { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(24px, 5vw, 72px); align-items: start; }
.s-faq__list { border-top: 1px solid var(--line); }
.s-faq details { border-bottom: 1px solid var(--line); }
.s-faq summary {
    list-style: none; cursor: pointer; display: flex; justify-content: space-between; gap: 1rem; align-items: center;
    padding: 1.15rem 0; font: 600 1.0625rem/1.4 var(--font-body);
}
.s-faq summary::-webkit-details-marker { display: none; }
.s-faq summary::after {
    content: ""; flex: none; width: 28px; height: 28px; border-radius: 50%;
    background: var(--paper-2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2316130E' stroke-width='2.2' stroke-linecap='round'%3E%3Cpath d='M12 6v12M6 12h12'/%3E%3C/svg%3E") center / 14px no-repeat;
    transition: transform 220ms var(--ease);
}
.s-faq details[open] summary::after { transform: rotate(45deg); }
.s-faq details p { padding: 0 2.5rem 1.25rem 0; color: var(--ink-2); }
@media (min-width: 861px) { .s-faq__head { position: sticky; top: 96px; } }
@media (max-width: 860px) { .s-faq { grid-template-columns: 1fr; } }

/* ---------- CTA final ---------- */
.s-cta {
    position: relative; overflow: hidden; border-radius: var(--r-xl);
    background: var(--accent); color: #fff;
    padding: clamp(40px, 7vw, 88px) clamp(24px, 6vw, 72px);
    display: grid; grid-template-columns: 1.3fr auto; gap: 2rem; align-items: center;
}
.s-cta::after {
    content: ""; position: absolute; right: -80px; top: -80px; width: 320px; height: 320px; border-radius: 50%;
    border: 40px solid rgba(255, 255, 255, .12); pointer-events: none;
}
.s-cta h2 { font-size: clamp(2rem, 4.4vw, 3.4rem); line-height: 1; }
.s-cta p { color: #fff; margin-top: .8rem; max-width: 52ch; }
@media (max-width: 760px) { .s-cta { grid-template-columns: 1fr; } }

/* ---------- Pie ---------- */
.s-footer { background: var(--night); color: var(--on-night-2); padding-block: clamp(48px, 7vw, 80px) 32px; font-size: .9375rem; }
.s-footer a { color: var(--on-night-2); text-decoration: none; }
.s-footer a:hover { color: var(--on-night); }
.s-footer__top { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 2rem; }
.s-footer .s-logo { color: var(--on-night); }
.s-footer__brand p { margin-top: 1rem; max-width: 34ch; }
.s-footer h2 { font: 600 .8125rem/1 var(--font-body); letter-spacing: .1em; text-transform: uppercase; color: var(--on-night); margin-bottom: 1rem; }
.s-footer ul { margin: 0; padding: 0; list-style: none; display: grid; gap: .55rem; }
.s-footer button.linklike { background: none; border: 0; padding: 0; color: var(--on-night-2); font: inherit; cursor: pointer; text-align: left; }
.s-footer button.linklike:hover { color: var(--on-night); }
.s-footer__bottom { margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid rgba(245, 240, 230, .12); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem; font-size: .875rem; }
@media (max-width: 860px) { .s-footer__top { grid-template-columns: 1fr 1fr; } .s-footer__brand { grid-column: 1 / -1; } }

/* ---------- Modales (compatibles con assets/js/main.js: .modal-overlay.active) ---------- */
.site .modal-overlay {
    position: fixed; inset: 0; z-index: 300;
    display: flex; align-items: center; justify-content: center;
    padding: 16px;
    background: rgba(22, 19, 14, .55);
    opacity: 0; visibility: hidden; transition: opacity 200ms, visibility 200ms;
    overscroll-behavior: contain;
}
.site .modal-overlay.active { opacity: 1; visibility: visible; }
.site .modal {
    width: min(560px, 100%);
    max-height: calc(100vh - 32px);
    max-height: calc(100dvh - 32px);
    overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch;
    background: var(--card); color: var(--ink); border-radius: var(--r-lg);
    padding: 0 clamp(20px, 3vw, 32px) clamp(20px, 3vw, 32px); box-shadow: var(--shadow-2);
    transform: translateY(12px); transition: transform 250ms var(--ease);
}
.site .modal-overlay.active .modal { transform: none; }
.site .modal-header {
    display: flex; justify-content: space-between; align-items: center; gap: 1rem;
    position: sticky; top: 0; z-index: 1; background: var(--card);
    padding: clamp(20px, 3vw, 32px) 0 1rem;
}
.site .modal-header h3 { font-size: 1.4rem; }
.site .modal-close { width: 44px; height: 44px; flex: none; border-radius: 50%; border: 0; background: var(--paper-2); font-size: 1.5rem; line-height: 1; cursor: pointer; color: var(--ink); }
.site .modal .form-group { display: grid; gap: .4rem; margin-bottom: 1rem; }
.site .modal .form-label { font-weight: 600; font-size: .9375rem; }
.site .modal .form-input { width: 100%; min-height: 48px; padding: .7rem .9rem; border: 1.5px solid var(--line-2); border-radius: 12px; font: 400 1rem var(--font-body); background: #fff; color: var(--ink); }
.site .modal textarea.form-input { min-height: 120px; }
.site .modal .btn { min-height: 52px; border-radius: 999px; border: 0; background: var(--accent); color: #fff; font: 600 1rem var(--font-body); cursor: pointer; }
.site .modal p { color: var(--ink-2); margin-bottom: .9rem; }
.site .alert { background: var(--ink); color: var(--paper); }
@media (max-width: 560px) {
    .site .modal-overlay { align-items: flex-end; padding: 0; }
    .site .modal { border-radius: var(--r-lg) var(--r-lg) 0 0; max-height: 92dvh; width: 100%; padding-bottom: max(24px, env(safe-area-inset-bottom)); }
}

/* ---------- Prosa (blog, paginas de contenido) ---------- */
.prose { font-size: 1.125rem; line-height: 1.75; color: var(--ink); }
.prose > * + *,
.prose > div > * + * { margin-top: 1.15em; } /* los articulos antiguos vienen envueltos en un <div> */
.prose h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); line-height: 1.15; margin-top: 2em; }
.prose h3 { font-size: 1.35rem; margin-top: 1.6em; }
.prose a { color: var(--accent); text-underline-offset: 3px; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li + li { margin-top: .4em; }
.prose blockquote { margin: 1.6em 0; padding: 1rem 1.25rem; border-left: 4px solid var(--accent); background: var(--card); border-radius: 0 var(--r-sm) var(--r-sm) 0; color: var(--ink-2); }
.prose table { width: 100%; border-collapse: collapse; font-size: 1rem; display: block; overflow-x: auto; }
.prose th, .prose td { border-bottom: 1px solid var(--line); padding: .6rem .7rem; text-align: left; }
.prose img { border-radius: var(--r-md); }
.prose figure { margin: 2.2em 0; }
.prose figure img { display: block; width: 100%; height: auto; }
.prose figcaption { margin-top: .6rem; font-size: .9375rem; line-height: 1.5; color: var(--ink-2); }
.prose strong { font-weight: 650; }

/* ---------- Tarjetas de articulo ---------- */
.s-posts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px 20px; }
.s-post { display: grid; gap: .8rem; text-decoration: none; align-content: start; }
.s-post__img { aspect-ratio: 16 / 10; border-radius: var(--r-md); overflow: hidden; background: var(--paper-2); }
.s-post__img img { width: 100%; height: 100%; object-fit: cover; transition: transform 500ms var(--ease); }
.s-post:hover .s-post__img img { transform: scale(1.04); }
.s-post h3 { font-size: 1.25rem; line-height: 1.2; }
.s-post p { color: var(--ink-2); font-size: .98rem; }
.s-post__meta { font-size: .8125rem; color: var(--ink-3); font-weight: 500; }
.s-post--lead { grid-column: span 3; grid-template-columns: 1.3fr 1fr; gap: clamp(20px, 3vw, 40px); align-items: center; }
.s-post--lead h3 { font-size: clamp(1.6rem, 3vw, 2.3rem); }
@media (max-width: 900px) { .s-posts { grid-template-columns: repeat(2, 1fr); } .s-post--lead { grid-column: span 2; grid-template-columns: 1fr; } }
@media (max-width: 600px) { .s-posts { grid-template-columns: 1fr; } .s-post--lead { grid-column: auto; } }

/* ---------- Migas ---------- */
.s-crumbs { display: flex; flex-wrap: wrap; gap: .4rem; font-size: .875rem; color: var(--ink-3); margin: 0 0 1rem; padding: 0; list-style: none; }
.s-crumbs li + li::before { content: "/"; margin-right: .4rem; opacity: .6; }
.s-crumbs a { text-decoration: none; }
.s-crumbs a:hover { color: var(--ink); }

/* ---------- Respuesta directa (AEO): bloque citable ---------- */
.s-answer {
    border: 1px solid var(--line); border-left: 4px solid var(--green); border-radius: 0 var(--r-md) var(--r-md) 0;
    background: var(--card); padding: 1.1rem 1.25rem; display: grid; gap: .4rem;
}
.s-answer strong { font-size: .8125rem; letter-spacing: .08em; text-transform: uppercase; color: var(--green); }
.s-answer p { color: var(--ink); }

/* ---------- Movimiento ---------- */
@keyframes s-rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
.s-rise > * { animation: s-rise 700ms var(--ease) both; }
.s-rise > *:nth-child(2) { animation-delay: 80ms; }
.s-rise > *:nth-child(3) { animation-delay: 160ms; }
.s-rise > *:nth-child(4) { animation-delay: 240ms; }
.s-rise > *:nth-child(5) { animation-delay: 320ms; }
@keyframes s-phone-in { from { opacity: 0; translate: 0 28px; } to { opacity: 1; translate: 0 0; } }
.s-phones .s-phone { animation: s-phone-in 900ms var(--ease) both; }
.s-phones .s-phone--c { animation-delay: 120ms; }
.s-phones .s-phone--r { animation-delay: 240ms; }
@supports (animation-timeline: view()) {
    .reveal { animation: s-rise linear both; animation-timeline: view(); animation-range: entry 0% entry 30%; }
}
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .site *, .site *::before, .site *::after { animation: none !important; transition: none !important; }
}

/* ---------- Paginas de sector ---------- */
.s-sector-hero { position: relative; aspect-ratio: 1 / 1; }
.s-sector-hero__photo { position: absolute; inset: 0 18% 12% 0; border-radius: var(--r-xl); overflow: hidden; box-shadow: var(--shadow-2); }
.s-sector-hero__photo img { width: 100%; height: 100%; object-fit: cover; }
.s-sector-hero__phone {
    position: absolute; right: 0; bottom: 0; width: 42%; aspect-ratio: 375 / 780;
    border-radius: 30px; padding: 6px; background: var(--ink); box-shadow: var(--shadow-2);
}
.s-sector-hero__phone img { width: 100%; height: 100%; object-fit: cover; object-position: top; border-radius: 25px; }
@media (max-width: 900px) { .s-sector-hero { max-width: 520px; width: 100%; margin-inline: auto; } }
.s-split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 5vw, 72px); align-items: center; }
@media (max-width: 860px) { .s-split { grid-template-columns: 1fr; } }
.s-chips { display: flex; flex-wrap: wrap; gap: .5rem; }
.s-chips a {
    display: inline-flex; align-items: center; min-height: 40px; padding: 0 1rem; border-radius: 999px;
    border: 1px solid var(--line-2); text-decoration: none; font-size: .9375rem; font-weight: 500; color: var(--ink-2);
}
.s-chips a:hover { border-color: var(--ink); color: var(--ink); }

/* ---------- Utilidades ---------- */
.site [hidden] { display: none !important; }
.s-stack { display: grid; gap: 1.1rem; }

/* ---------- Herramientas gratis ---------- */
.s-tools { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.s-tool { text-decoration: none; transition: transform 200ms var(--ease), box-shadow 200ms; }
.s-tool:hover { transform: translateY(-3px); box-shadow: var(--shadow-2); }
.s-tool__go { display: inline-flex; align-items: center; gap: .4rem; font-weight: 600; color: var(--accent); margin-top: .4rem; }
.s-tool__go svg { width: 18px; height: 18px; }
@media (max-width: 760px) { .s-tools { grid-template-columns: 1fr; } }
.s-tool-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0; border-radius: var(--r-lg); overflow: hidden; border: 1px solid var(--line); background: var(--card); }
.s-tool-grid > * { padding: clamp(24px, 3vw, 36px); }
.s-tool-grid__out { background: var(--paper-2); display: grid; place-items: center; gap: 1rem; }
@media (max-width: 860px) { .s-tool-grid { grid-template-columns: 1fr; } }
.s-seg { display: inline-flex; flex-wrap: wrap; gap: .4rem; }
.s-seg button {
    min-height: 40px; padding: 0 .9rem; border-radius: 999px; border: 1.5px solid var(--line-2);
    background: transparent; font: 600 .875rem var(--font-body); color: var(--ink-2); cursor: pointer;
}
.s-seg button[aria-pressed="true"] { background: var(--ink); color: var(--paper); border-color: var(--ink); }

/* Tarjeta imprimible del QR de resenas */
.s-qrcard {
    width: min(100%, 340px); aspect-ratio: 105 / 148; background: #fff; color: var(--ink);
    border-radius: 18px; box-shadow: var(--shadow-2); padding: 26px 24px;
    display: grid; grid-template-rows: auto 1fr auto; gap: 14px; text-align: center;
}
.s-qrcard__title { font: 700 1.5rem/1.05 var(--font-display); letter-spacing: -.02em; }
.s-qrcard__stars { color: var(--accent); letter-spacing: .15em; font-size: 1.1rem; }
.s-qrcard__qr { display: grid; place-items: center; }
.s-qrcard__qr svg, .s-qrcard__qr img { width: 100%; max-width: 210px; height: auto; }
.s-qrcard__name { font: 600 .95rem var(--font-body); color: var(--ink-2); }
@media print {
    body.site > *:not(main), .s-nav, .s-footer, .s-no-print { display: none !important; }
    body.site { background: #fff; }
    .s-qrcard { box-shadow: none; border: 1px solid #ddd; width: 105mm; margin: 0 auto; }
}

/* Mensajes para clientes */
.s-msgs { display: grid; gap: 14px; }
.s-msg { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-md); padding: 1.1rem 1.2rem; display: grid; gap: .6rem; }
.s-msg__head { display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.s-msg__head h3 { font-size: 1.05rem; }
.s-msg__text { white-space: pre-wrap; font-size: 1rem; line-height: 1.55; color: var(--ink); background: var(--paper); border-radius: 12px; padding: .9rem 1rem; }
.s-copy {
    min-height: 40px; padding: 0 1rem; border-radius: 999px; border: 1.5px solid var(--line-2); background: #fff;
    font: 600 .875rem var(--font-body); cursor: pointer; color: var(--ink); flex: none;
}
.s-copy.is-done { background: var(--green); color: #fff; border-color: var(--green); }
