/* DatoBarrio — hoja de estilos única.
   Idea: el aviso de barrio pegado en el muro. Papel blanco, cinta amarilla,
   resaltador amarillo, tinta azul marino y tiras recortables (una por región).
   Sin estilos en línea: la política de seguridad (CSP) del sitio no los permite. */

@font-face {
    font-family: "Archivo";
    src: url("/assets/fonts/archivo-latin-wdth-normal.woff2") format("woff2");
    font-weight: 100 900;
    font-stretch: 62% 125%;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: "Atkinson Hyperlegible Next";
    src: url("/assets/fonts/atkinson-hyperlegible-next-latin-wght-normal.woff2") format("woff2");
    font-weight: 200 800;
    font-style: normal;
    font-display: swap;
}

:root {
    --ink: #0f2a6b;
    --ink-deep: #0a1d4d;
    --text: #16213e;
    --soft: #4a5673;
    --paper: #ffffff;
    --wall: #e8ecf3;
    --wall-2: #d9e0ec;
    --line: #c3cde0;
    --field-line: #66739a;
    --mark: #ffd60a;
    --mark-soft: #fff2a8;
    --copihue: #c4203a;
    --wa: #0e7c3a;
    --wa-deep: #0a6430;
    --ok-bg: #dff3e6;
    --ok-line: #116a3a;
    --warn-bg: #fff4c2;
    --warn-line: #8a6d00;
    --err-bg: #fde3e6;
    --err-line: #b3162c;
    --info-bg: #e3ebff;

    --radius: 4px;
    --focus: var(--ink);
    --font-head: "Archivo", "Arial Narrow", "Helvetica Neue", Arial, sans-serif;
    --font-body: "Atkinson Hyperlegible Next", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --paper-shadow: 0 1px 0 rgba(15, 42, 107, .10), 0 12px 24px -16px rgba(15, 42, 107, .5);
    --flyer-pad: 1.25rem;
    --header-h: 4rem;
}

*,
*::before,
*::after { box-sizing: border-box; }

html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
    scroll-behavior: smooth;
    scroll-padding-top: 5rem;
}

body {
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: var(--wall);
    color: var(--text);
    font-family: var(--font-body);
    font-size: 1.0625rem;
    line-height: 1.6;
    font-weight: 400;
    overflow-wrap: break-word;
}
main { flex: 1 0 auto; }
main:focus { outline: none; }

::selection { background: var(--mark); color: var(--ink-deep); }

img, svg { max-width: 100%; height: auto; }
img { display: block; }
[hidden] { display: none !important; }

h1, h2, h3, h4 {
    margin: 0 0 .5em;
    font-family: var(--font-head);
    font-stretch: 72%;
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -.005em;
    word-spacing: .1em;
    color: var(--ink);
    text-wrap: balance;
}
h1 { font-size: clamp(2.1rem, 1.2rem + 4.6vw, 3.6rem); }
h2 { font-size: clamp(1.6rem, 1.1rem + 2vw, 2.35rem); }
h3, .h3 { font-size: 1.35rem; font-stretch: 85%; font-weight: 700; line-height: 1.15; }
h4, .h4 { font-size: 1.1rem; font-stretch: 90%; font-weight: 700; }
.h3, .h4 { font-family: var(--font-head); color: var(--ink); margin: 0 0 .5em; }

p { margin: 0 0 1em; }
ul, ol { margin: 0 0 1em; padding-left: 1.25rem; }
a { color: var(--ink); text-decoration-thickness: .08em; text-underline-offset: .18em; }
a:hover { text-decoration-thickness: .16em; }
strong { font-weight: 700; }
small, .small { font-size: .9rem; color: var(--soft); }
.meta { color: var(--soft); font-size: .92rem; margin-bottom: .5em; }
.lead { font-size: 1.2rem; line-height: 1.5; max-width: 40rem; color: var(--text); }
.intro { max-width: 40rem; color: var(--soft); }
.center { text-align: center; }
.center .lead { margin-inline: auto; }
.hint { color: var(--soft); font-size: .92rem; margin: 0 0 .5rem; }
.count { color: var(--soft); font-size: .85em; font-variant-numeric: tabular-nums; }
.optional { color: var(--soft); font-weight: 400; font-size: .9em; }

:focus-visible {
    outline: 3px solid var(--focus);
    outline-offset: 2px;
    box-shadow: 0 0 0 6px var(--mark);
    border-radius: 2px;
}
.site-header, .site-footer, .slider, .admin-bar, .plan-card-store { --focus: #ffffff; }
.site-header :focus-visible, .site-footer :focus-visible, .slider :focus-visible,
.admin-bar :focus-visible, .plan-card-store :focus-visible { box-shadow: 0 0 0 6px var(--ink-deep); }

.visually-hidden {
    position: absolute !important;
    width: 1px; height: 1px;
    margin: -1px; padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    white-space: nowrap;
    border: 0;
}
.trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.skip-link {
    position: absolute; left: .5rem; top: -4rem; z-index: 100;
    padding: .7rem 1rem; background: var(--mark); color: var(--ink-deep);
    font-weight: 700; border: 2px solid var(--ink); text-decoration: none;
}
.skip-link:focus { top: .5rem; }

/* ---------- Estructura ---------- */

.wrap { width: 100%; max-width: 70rem; margin-inline: auto; padding-inline: 1.25rem; }
.narrow { max-width: 46rem; }
.narrow-form { max-width: 43rem; }
.section { padding-block: clamp(2rem, 1.2rem + 4vw, 3.75rem); }
.section-flush { padding-top: 1.25rem; }
.section-tint { background: var(--paper); }
.section-head {
    display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between;
    gap: .25rem 1rem; margin-bottom: 1.25rem;
}
.section-head h2 { margin: 0; }
.page-head { padding: 1.5rem 0 .5rem; }
.page-head h1 { margin-bottom: .35em; }
.page-title-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem 1.5rem; margin-bottom: .5rem; }
.page-title-row h1 { margin: 0; font-size: clamp(1.8rem, 1.2rem + 2.5vw, 2.6rem); }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; margin: 1.25rem 0 0; }
.block { margin-block: 2rem; }
.block > h2 { font-size: 1.7rem; }
.inline-form { display: inline; margin: 0; }
.inline-form-block { margin-top: 1rem; }
.plain-list { padding-left: 1.1rem; }

/* ---------- Cabecera y pie ---------- */

.site-header {
    background: var(--ink);
    color: #fff;
    border-bottom: 4px solid var(--mark);
}
.site-header-bar {
    display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
    gap: .5rem 1rem; min-height: var(--header-h); padding-block: .5rem;
}
.brand { display: inline-flex; align-items: center; gap: .6rem; color: #fff; text-decoration: none; }
.brand:hover { text-decoration: none; }
.brand-name {
    font-family: var(--font-head); font-stretch: 72%; font-weight: 800; word-spacing: .05em;
    font-size: 1.7rem; line-height: 1; letter-spacing: .005em;
}
.logo-mark { flex: none; }
.site-nav { display: flex; flex-wrap: wrap; align-items: center; gap: .25rem 1.25rem; }
.site-nav a:not(.btn) { color: #fff; font-weight: 500; text-decoration: none; padding: .45rem 0; }
.site-nav a:not(.btn):hover { text-decoration: underline; text-decoration-thickness: .12em; text-underline-offset: .22em; }
.site-nav .link-button { color: #fff; padding: .45rem 0; }
.nav-extra { display: none; }

.site-footer { background: var(--ink-deep); color: #dbe3f7; margin-top: 3rem; }
.site-footer a { color: #fff; }
.footer-grid { display: grid; gap: 2rem; padding-block: 2.5rem 1.5rem; }
.footer-about p { max-width: 28rem; margin-top: 1rem; color: #c9d4f0; }
.footer-title { font-size: 1.1rem; color: var(--mark); margin-bottom: .6rem; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: .45rem; }
.footer-base { padding-bottom: 1.5rem; font-size: .92rem; color: #b9c5e6; }
.footer-base p { margin: 0; padding-top: 1rem; border-top: 1px solid rgba(255, 255, 255, .2); }

@media (min-width: 46rem) {
    .nav-extra { display: inline; }
    .footer-grid { grid-template-columns: 2fr 1fr 1fr; }
}

/* ---------- Botones ---------- */

.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
    min-height: 2.9rem; padding: .45rem 1.15rem;
    font: inherit; font-weight: 700; font-size: 1rem; line-height: 1.2; text-align: center; text-decoration: none;
    color: var(--ink); background: var(--paper);
    border: 2px solid var(--ink); border-radius: var(--radius);
    cursor: pointer;
    transition: background-color .12s, transform .08s;
}
.btn:hover { background: var(--mark-soft); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--mark); color: var(--ink-deep); }
.btn-primary:hover { background: #ffe54d; }
.btn-whatsapp { background: var(--wa); border-color: var(--wa-deep); color: #fff; }
.btn-whatsapp:hover { background: var(--wa-deep); }
.btn-danger { color: var(--err-line); border-color: var(--err-line); background: var(--paper); }
.btn-danger:hover { background: var(--err-bg); }
.btn-small { min-height: 2.5rem; padding: .3rem .85rem; font-size: .95rem; }
.btn-large { min-height: 3.3rem; padding: .6rem 1.5rem; font-size: 1.1rem; }
.btn-block { display: flex; width: 100%; }
.btn[disabled], .btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.site-header .btn { border-color: var(--mark); }
.link-button {
    display: inline; padding: 0; margin: 0; border: 0; background: none;
    font: inherit; color: inherit; text-decoration: underline; text-underline-offset: .18em; cursor: pointer;
}
.danger-link { color: var(--err-line); }
.icon-button {
    display: inline-flex; align-items: center; justify-content: center; min-width: 2.5rem; height: 2.5rem; padding: 0 .8rem;
    font: inherit; font-weight: 600; font-size: .95rem; color: #fff; background: transparent;
    border: 2px solid rgba(255, 255, 255, .7); border-radius: var(--radius); cursor: pointer;
}
.icon-button:hover { background: rgba(255, 255, 255, .14); }

/* ---------- Avisos ---------- */

.notice {
    display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem 1.25rem;
    margin: 0 0 1.25rem; padding: .9rem 1.1rem;
    background: var(--info-bg); color: var(--text);
    border: 2px solid var(--ink); border-left-width: 8px; border-radius: var(--radius);
}
.notice > div, .notice > span { flex: 1 1 18rem; }
.notice form { margin: 0; }
.notice-warn { background: var(--warn-bg); border-color: var(--warn-line); }
.notice-ok { background: var(--ok-bg); border-color: var(--ok-line); }
.notice-error { background: var(--err-bg); border-color: var(--err-line); }

.flashes { background: var(--wall); padding-top: 1rem; }
.flash {
    margin: 0 0 .75rem; padding: .85rem 1.1rem; font-weight: 500;
    background: var(--info-bg); border: 2px solid var(--ink); border-left-width: 8px; border-radius: var(--radius);
}
.flash-success { background: var(--ok-bg); border-color: var(--ok-line); }
.flash-error { background: var(--err-bg); border-color: var(--err-line); }
.flash-warning { background: var(--warn-bg); border-color: var(--warn-line); }

.notice-page { background: var(--paper); padding: clamp(1.5rem, 1rem + 3vw, 2.75rem); box-shadow: var(--paper-shadow); border-top: 6px solid var(--mark); }
.notice-code { font-family: var(--font-head); font-stretch: 62%; font-weight: 900; font-size: clamp(4rem, 3rem + 8vw, 7.5rem); line-height: .85; color: var(--copihue); margin: 0 0 .5rem; }
.debug { overflow-x: auto; padding: 1rem; background: var(--wall); border: 1px dashed var(--field-line); font-size: .85rem; }

/* ---------- Etiquetas ---------- */

.pill {
    display: inline-block; margin: 0; padding: .1rem .7rem;
    font-family: var(--font-body); font-size: .82rem; font-weight: 700; line-height: 1.5; letter-spacing: 0;
    background: var(--wall-2); color: var(--ink-deep); border-radius: 999px; vertical-align: middle;
}
.pill-featured { background: var(--mark); color: var(--ink-deep); }
.badge {
    display: inline-block; padding: .05rem .55rem; font-family: var(--font-body); font-size: .8rem; font-weight: 700; line-height: 1.6;
    background: var(--wall-2); color: var(--ink-deep); border-radius: 3px; vertical-align: middle; white-space: nowrap;
}
.badge-featured { background: var(--mark); }
.badge-store, .badge-admin { background: var(--ink); color: #fff; }
.badge-free { background: var(--ok-bg); color: #0b4d29; }
.badge-expiring { background: #ffe0b0; color: #6b3a00; }
.badge-expired { background: var(--wall-2); color: var(--soft); }
.badge-suspended { background: var(--err-bg); color: var(--err-line); }
.badge-draft { background: var(--wall-2); color: var(--soft); }

.chips { display: flex; flex-wrap: wrap; gap: .5rem; margin: 0 0 1.25rem; padding: 0; list-style: none; }
.chip {
    display: inline-flex; align-items: center; gap: .35rem; min-height: 2.4rem; padding: .2rem .85rem;
    font-weight: 500; font-size: .95rem; color: var(--ink); text-decoration: none;
    background: var(--paper); border: 2px solid var(--line); border-radius: 999px;
}
.chip:hover { border-color: var(--ink); background: var(--mark-soft); }
.chip[aria-current] { background: var(--ink); color: #fff; border-color: var(--ink); }

/* ---------- Aviso de barrio: papel, cinta y tiras recortables ---------- */

.hero { padding: 2rem 0 1.25rem; }
.flyer {
    position: relative;
    background: var(--paper);
    padding: 2.25rem var(--flyer-pad) 0;
    box-shadow: var(--paper-shadow);
    border-radius: 2px;
}
.tape {
    position: absolute; top: -.85rem; width: 7.5rem; height: 1.9rem;
    background: rgba(255, 214, 10, .82);
    box-shadow: 0 1px 2px rgba(15, 42, 107, .25);
    background-image: repeating-linear-gradient(90deg, transparent 0 6px, rgba(255, 255, 255, .22) 6px 7px);
}
.tape-left { left: 8%; transform: rotate(-4deg); }
.tape-right { right: 8%; transform: rotate(3deg); }
.flyer-main { padding-bottom: 1.5rem; }
.flyer-title {
    margin: 0 0 .35em; max-width: 13ch;
    font-size: clamp(2.7rem, 1.4rem + 7.5vw, 5.4rem); font-stretch: 66%; font-weight: 800; line-height: .92; letter-spacing: -.01em;
}
.flyer-lead { font-size: 1.2rem; max-width: 34rem; margin-bottom: 1.5rem; }
.flyer-note { margin: 1rem 0 0; color: var(--soft); font-size: .95rem; }

/* Las tiras: una por región (portada) o por medio de contacto (ficha). */
.tabs { margin-inline: calc(var(--flyer-pad) * -1); border-top: 2px dashed var(--ink); }
.tabs-caption {
    margin: 0; padding: .6rem var(--flyer-pad) .15rem;
    font-family: var(--font-head); font-stretch: 80%; font-weight: 700; font-size: 1rem; color: var(--soft);
}
.tabs > ul, ul.tabs {
    display: flex; margin: 0; padding: 0; list-style: none;
    overflow-x: auto; scroll-snap-type: x proximity; scrollbar-width: thin;
}
ul.tabs { margin-inline: calc(var(--flyer-pad) * -1); }
.tabs li { flex: 1 0 3.6rem; scroll-snap-align: start; border-right: 2px dashed var(--ink); }
.tabs li:last-child { border-right: 0; }
.tab {
    display: flex; flex-direction: column; align-items: center; justify-content: space-between; gap: .6rem;
    height: 100%; min-height: 10.5rem; padding: .85rem .2rem;
    color: var(--ink); text-decoration: none;
}
.tab-name {
    writing-mode: vertical-rl; transform: rotate(180deg); white-space: nowrap;
    font-family: var(--font-head); font-stretch: 78%; font-weight: 700; font-size: 1.1rem; line-height: 1.1;
}
.tab-count {
    min-width: 1.7rem; padding: 0 .35rem; text-align: center;
    font-size: .8rem; font-weight: 700; line-height: 1.5; font-variant-numeric: tabular-nums;
    background: var(--mark); color: var(--ink-deep); border-radius: 999px;
}
.tab:hover { background: var(--mark); }
.tab:hover .tab-count { background: var(--paper); }
.tabs-contact li { flex: 0 1 6rem; min-width: 3.4rem; }
.tabs-contact .tab { min-height: 7.5rem; }
.tabs-contact .tab-name { font-size: 1.05rem; }

@keyframes strip-in {
    from { opacity: 0; transform: translateY(-.6rem); }
    to { opacity: 1; transform: none; }
}
.tabs > ul > li { animation: strip-in .45s ease-out both; }
.tabs > ul > li:nth-child(2) { animation-delay: .04s; }
.tabs > ul > li:nth-child(3) { animation-delay: .08s; }
.tabs > ul > li:nth-child(4) { animation-delay: .12s; }
.tabs > ul > li:nth-child(5) { animation-delay: .16s; }
.tabs > ul > li:nth-child(6) { animation-delay: .2s; }
.tabs > ul > li:nth-child(7) { animation-delay: .24s; }
.tabs > ul > li:nth-child(8) { animation-delay: .28s; }
.tabs > ul > li:nth-child(9) { animation-delay: .32s; }
.tabs > ul > li:nth-child(10) { animation-delay: .36s; }
.tabs > ul > li:nth-child(11) { animation-delay: .4s; }
.tabs > ul > li:nth-child(12) { animation-delay: .44s; }
.tabs > ul > li:nth-child(13) { animation-delay: .48s; }
.tabs > ul > li:nth-child(14) { animation-delay: .52s; }
.tabs > ul > li:nth-child(15) { animation-delay: .56s; }
.tabs > ul > li:nth-child(16) { animation-delay: .6s; }

@media (min-width: 46rem) {
    :root { --flyer-pad: 2.25rem; }
    .hero { padding-top: 2.75rem; }
    .flyer { padding-top: 2.75rem; }
}

/* ---------- Buscador ---------- */

.search { display: grid; gap: .85rem; }
.search-field label { display: block; margin-bottom: .25rem; font-weight: 700; font-size: .95rem; color: var(--ink); }
.search-submit { display: flex; align-items: flex-end; }
.search-submit .btn { width: 100%; }
.search-bar { margin-bottom: 1.5rem; padding: 1rem; background: var(--paper); box-shadow: var(--paper-shadow); border-top: 4px solid var(--mark); }
@media (min-width: 52rem) {
    .search { grid-template-columns: minmax(0, 2fr) minmax(0, 1.2fr) minmax(0, 1.2fr) auto; align-items: end; gap: 1rem; }
    .search-submit .btn { width: auto; min-width: 7rem; }
}
.hero .search .btn { min-height: 3rem; }

/* ---------- Formularios ---------- */

.field { margin: 0 0 1.25rem; }
.field > label, .field > label.check { display: block; margin-bottom: .3rem; font-weight: 700; color: var(--ink-deep); }
.input, .select, textarea.input {
    display: block; width: 100%; min-height: 3rem; padding: .55rem .8rem;
    font: inherit; color: var(--text); background: var(--paper);
    border: 2px solid var(--field-line); border-radius: var(--radius);
    appearance: none; -webkit-appearance: none;
}
.select {
    padding-right: 2.4rem;
    background-image: linear-gradient(45deg, transparent 50%, var(--ink) 50%), linear-gradient(135deg, var(--ink) 50%, transparent 50%);
    background-position: calc(100% - 1.15rem) 52%, calc(100% - .8rem) 52%;
    background-size: .35rem .35rem;
    background-repeat: no-repeat;
}
textarea.input { min-height: 7rem; resize: vertical; line-height: 1.5; }
.input:hover, .select:hover { border-color: var(--ink); }
.input:focus, .select:focus { border-color: var(--ink); outline: 3px solid var(--mark); outline-offset: 0; box-shadow: none; }
.input::placeholder { color: #7a86a3; opacity: 1; }
.input-file { padding: .6rem .7rem; }
.input-file::file-selector-button {
    margin-right: .8rem; padding: .35rem .8rem; font: inherit; font-weight: 700; color: var(--ink);
    background: var(--wall); border: 2px solid var(--ink); border-radius: var(--radius); cursor: pointer;
}
.input[readonly] { background: var(--wall); }
.input-prefixed { display: flex; align-items: stretch; }
.prefix {
    display: flex; align-items: center; padding: 0 .85rem; font-weight: 700; color: var(--ink);
    background: var(--wall); border: 2px solid var(--field-line); border-right: 0; border-radius: var(--radius) 0 0 var(--radius);
}
.input-prefixed .input { border-radius: 0 var(--radius) var(--radius) 0; }
.has-error .input, .has-error .select { border-color: var(--err-line); background: #fffafb; }
.error { margin: .35rem 0 0; color: var(--err-line); font-weight: 700; font-size: .95rem; }
.char-count { margin: .25rem 0 0; font-size: .85rem; color: var(--soft); text-align: right; font-variant-numeric: tabular-nums; }
.select-pair { display: grid; gap: .5rem; }
@media (min-width: 40rem) { .select-pair { grid-template-columns: 1fr 1fr; } }
.check { display: flex; align-items: flex-start; gap: .65rem; font-weight: 500; cursor: pointer; }
.check input { flex: none; width: 1.4rem; height: 1.4rem; margin: .1rem 0 0; accent-color: var(--ink); }
.check-list { list-style: none; padding: 0; margin: 0 0 1.25rem; }
.check-list li { position: relative; padding: .25rem 0 .25rem 1.9rem; }
.check-list li::before {
    content: ""; position: absolute; left: 0; top: .45rem; width: 1.2rem; height: 1.2rem;
    background: var(--mark); border-radius: 3px;
}
.check-list li::after {
    content: ""; position: absolute; left: .4rem; top: .55rem; width: .35rem; height: .65rem;
    border: solid var(--ink-deep); border-width: 0 2.5px 2.5px 0; transform: rotate(40deg);
}

fieldset { margin: 0; padding: 0; border: 0; min-width: 0; }
legend { float: left; width: 100%; padding: 0; margin: 0 0 .75rem; font-family: var(--font-head); font-stretch: 78%; font-weight: 800; font-size: 1.5rem; line-height: 1.1; color: var(--ink); }
legend + * { clear: both; }
.fieldset-lead { margin: -.25rem 0 1rem; color: var(--soft); }
.panel-form fieldset { margin-bottom: 1.25rem; padding: 1.25rem; background: var(--paper); box-shadow: var(--paper-shadow); border-top: 4px solid var(--ink); }
.product-form { margin-top: 1rem; }
.product-form .field:last-of-type { margin-bottom: 1rem; }
.form-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin: 1.5rem 0; }
.form-page { max-width: 34rem; margin: 0 auto; padding: clamp(1.25rem, 1rem + 2vw, 2.25rem); background: var(--paper); box-shadow: var(--paper-shadow); border-top: 6px solid var(--mark); }
.form-page h1 { font-size: clamp(1.9rem, 1.4rem + 2.2vw, 2.6rem); }
.form-links, .form-foot { font-size: .95rem; }
.form-foot { margin: 1.5rem 0 0; padding-top: 1rem; border-top: 2px dashed var(--line); text-align: center; }
.stack-form .field { margin-bottom: .85rem; }
.stack-form .check { margin: .25rem 0 1rem; }
.admin-card form + form, .admin-card .btn + form, .admin-card p + form { margin-top: .85rem; }
.filter-bar { display: flex; flex-wrap: wrap; align-items: flex-end; gap: .75rem 1rem; margin-bottom: 1.25rem; }
.filter-bar .field { margin: 0; flex: 1 1 14rem; max-width: 22rem; }
.image-current { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem; margin-bottom: .75rem; }
.image-current img { width: 6rem; height: 6rem; object-fit: cover; border: 2px solid var(--line); border-radius: var(--radius); }
.image-current.is-wide img { width: 15rem; max-width: 100%; height: auto; aspect-ratio: 8 / 3; }
.copy-box { display: flex; gap: .5rem; align-items: center; margin-bottom: .75rem; }
.copy-box .input { min-height: 2.5rem; font-size: .9rem; }

/* ---------- Pasos del asistente ---------- */

.steps ol { display: flex; flex-wrap: wrap; gap: .5rem .35rem; margin: 1rem 0 0; padding: 0; list-style: none; }
.step { display: flex; align-items: center; }
.step + .step::before { content: ""; width: 1.25rem; height: 2px; margin-right: .35rem; background: var(--field-line); }
.step a, .step-link {
    display: inline-flex; align-items: center; gap: .5rem; min-height: 2.5rem; padding: .2rem .8rem .2rem .3rem;
    color: var(--ink); text-decoration: none; font-weight: 600; font-size: .95rem;
    background: var(--paper); border: 2px solid var(--line); border-radius: 999px;
}
.step a:hover { border-color: var(--ink); }
.step-num {
    position: relative; display: inline-flex; align-items: center; justify-content: center; flex: none;
    width: 1.8rem; height: 1.8rem; font-weight: 800; font-size: .9rem; color: var(--ink);
    background: var(--wall-2); border-radius: 50%;
}
.step.is-current a, .step.is-current .step-link { border-color: var(--ink); background: var(--mark-soft); }
.step.is-current .step-num { background: var(--ink); color: #fff; }
.step.is-done .step-num { background: var(--ink); color: #fff; }
.step-num-done::after {
    content: ""; width: .3rem; height: .6rem; margin-top: -.1rem;
    border: solid #fff; border-width: 0 2.5px 2.5px 0; transform: rotate(40deg);
}
.step-intro { margin-bottom: 1.5rem; }
.step-intro h2 { font-size: 1.8rem; }
@media (max-width: 40rem) {
    .step:not(.is-current) .step-label {
        position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap;
    }
    .step:not(.is-current) a, .step:not(.is-current) .step-link { padding-right: .3rem; }
}

/* ---------- Portada: slider ---------- */

.slider { background: var(--ink); color: #fff; padding: 2rem 0 2.25rem; }
.slider-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem 1rem; margin-bottom: 1rem; }
.slider-head h2 { margin: 0; color: #fff; }
.slider-controls { display: flex; gap: .5rem; }
.slider-track {
    display: flex; gap: 1rem; margin: 0; padding: 0 0 .5rem; list-style: none;
    overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: thin; scrollbar-color: var(--mark) transparent;
    overscroll-behavior-x: contain;
}
.slide {
    flex: 0 0 92%; scroll-snap-align: start;
    display: grid; grid-template-columns: 1fr;
    background: var(--paper); color: var(--text); border-top: 6px solid var(--mark);
}
.slide-media {
    display: flex; align-items: center; justify-content: center; aspect-ratio: 16 / 8; overflow: hidden;
    background: var(--wall-2); text-decoration: none;
}
.slide-media img { width: 100%; height: 100%; object-fit: cover; }
.slide-logo-bg { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; background: var(--wall); }
.slide-logo-bg img { width: auto; height: 80%; max-width: 80%; object-fit: contain; }
.slide-initial {
    display: flex; align-items: center; justify-content: center; width: 100%; height: 100%;
    font-family: var(--font-head); font-stretch: 62%; font-weight: 900; font-size: 7rem; line-height: 1; color: var(--ink); background: var(--mark);
}
.slide-body { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; padding: 1.25rem; }
.slide-title { font-size: clamp(1.7rem, 1.2rem + 2vw, 2.4rem); margin: .35rem 0 .25rem; }
.slide-title a { color: var(--ink); text-decoration: none; }
.slide-title a:hover { text-decoration: underline; }
.slide-meta { margin: 0 0 .5rem; color: var(--soft); font-size: .95rem; }
.slide-summary { margin: 0 0 1rem; max-width: 34rem; }
.slide-actions { display: flex; flex-wrap: wrap; gap: .6rem; margin: 0; }
.slide-promo { background: var(--mark); border-top-color: var(--paper); }
.slide-promo .pill { background: var(--ink); color: #fff; }
.slide-promo .slide-title { color: var(--ink-deep); }
.slide-promo .btn-primary { background: var(--ink); color: #fff; border-color: var(--ink); }
.slide-promo .btn-primary:hover { background: var(--ink-deep); }
@media (min-width: 52rem) {
    .slide { flex-basis: min(86%, 56rem); grid-template-columns: 1.1fr 1fr; min-height: 20rem; }
    .slide-media { aspect-ratio: auto; }
    .slide-body { padding: 2rem; }
    .slide-promo { grid-template-columns: 1fr; }
    .slide-promo .slide-body { max-width: 40rem; }
}

/* ---------- Listados ---------- */

.listing-list { display: grid; gap: .75rem; }
.listing {
    display: grid; grid-template-columns: 4.5rem 1fr; gap: .75rem 1rem; align-items: start;
    padding: .9rem; background: var(--paper); border: 2px solid var(--line); border-left: 8px solid var(--line); border-radius: var(--radius);
}
.listing:hover { border-color: var(--ink); border-left-color: var(--ink); }
.listing.is-featured { border-left-color: var(--mark); background: #fffdf0; }
.listing.is-featured:hover { border-left-color: var(--mark); }
.listing-media {
    display: flex; align-items: center; justify-content: center; width: 4.5rem; height: 4.5rem; overflow: hidden;
    background: var(--wall); border-radius: var(--radius); text-decoration: none;
}
.listing-media img { width: 100%; height: 100%; object-fit: cover; }
.listing-initial { font-family: var(--font-head); font-stretch: 70%; font-weight: 800; font-size: 2.2rem; color: var(--ink); }
.listing-title { margin: 0 0 .15rem; font-size: 1.35rem; font-stretch: 85%; }
.listing-title a { color: var(--ink); text-decoration: none; }
.listing-title a:hover { text-decoration: underline; }
.listing-meta { margin: 0 0 .35rem; color: var(--soft); font-size: .93rem; }
.listing-summary { margin: 0; }
.listing-actions { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: .5rem; }
@media (min-width: 46rem) {
    .listing { grid-template-columns: 4.5rem 1fr auto; align-items: center; }
    .listing-actions { grid-column: auto; flex-direction: column; align-items: stretch; min-width: 8.5rem; }
}
.result-count { margin: 0 0 1rem; color: var(--soft); font-weight: 500; }
.empty { padding: 2rem 1.25rem; text-align: center; background: var(--paper); border: 2px dashed var(--field-line); border-radius: var(--radius); }
.empty h2 { font-size: 1.7rem; }
.empty .actions { justify-content: center; }
.empty-big { padding-block: 3rem; }

.comuna-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(12.5rem, 1fr)); gap: .5rem; margin: 0 0 1rem; padding: 0; list-style: none; }
.comuna-grid a {
    display: flex; align-items: center; justify-content: space-between; gap: .5rem; min-height: 2.9rem; padding: .35rem .85rem;
    color: var(--ink); font-weight: 600; text-decoration: none; background: var(--paper); border: 2px solid var(--line); border-radius: var(--radius);
}
.comuna-grid a:hover { border-color: var(--ink); background: var(--mark-soft); }
.comuna-grid .is-empty a { font-weight: 400; color: var(--soft); background: transparent; }
.comuna-grid .count { background: var(--mark); color: var(--ink-deep); padding: 0 .45rem; border-radius: 999px; font-weight: 700; }

.pager { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: .75rem; margin: 2rem 0 0; }
.pager ul { display: flex; gap: .35rem; margin: 0; padding: 0; list-style: none; }
.pager li a, .pager li span, .pager-step {
    display: inline-flex; align-items: center; justify-content: center; min-width: 2.6rem; min-height: 2.6rem; padding: 0 .7rem;
    color: var(--ink); font-weight: 700; text-decoration: none; background: var(--paper); border: 2px solid var(--line); border-radius: var(--radius);
}
.pager li a:hover, .pager-step:hover { border-color: var(--ink); background: var(--mark-soft); }
.pager li span[aria-current] { background: var(--ink); border-color: var(--ink); color: #fff; }
.pager .gap { min-width: 1.5rem; border: 0; background: none; color: var(--soft); }

.crumbs { margin-bottom: 1rem; font-size: .92rem; }
.crumbs ol { display: flex; flex-wrap: wrap; gap: .15rem .4rem; margin: 0; padding: 0; list-style: none; }
.crumbs li + li::before { content: "/"; margin-right: .4rem; color: var(--field-line); }
.crumbs a { color: var(--soft); }
.crumbs [aria-current] { color: var(--text); font-weight: 600; }

/* ---------- Rubros en la portada ---------- */

.sector-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr)); gap: 1.75rem 2rem; }
.sector h3 { margin-bottom: .6rem; padding-bottom: .35rem; border-bottom: 4px solid var(--mark); }
.sector h3 a { color: var(--ink); text-decoration: none; }
.sector h3 a:hover { text-decoration: underline; }
.sector ul { margin: 0; padding: 0; list-style: none; }
.sector li { display: flex; align-items: baseline; justify-content: space-between; gap: .75rem; padding: .3rem 0; border-bottom: 1px dotted var(--field-line); }
.sector li a { color: var(--text); text-decoration: none; }
.sector li a:hover { color: var(--ink); text-decoration: underline; }

/* ---------- Banner Transbank ---------- */

.tbk-banner { background: var(--paper); border-block: 2px dashed var(--ink); }
.tbk-banner-inner { display: flex; flex-wrap: wrap; align-items: center; gap: .85rem 1.5rem; padding-block: 1.1rem; }
.tbk-logo { flex: none; height: 2.25rem; width: auto; }
.tbk-text { flex: 1 1 22rem; margin: 0; font-size: .98rem; }
.tbk-text strong { color: var(--ink); }
.tbk-link { flex: none; font-weight: 700; }

/* ---------- Bloque para dueños y planes ---------- */

.owners { display: grid; gap: 2rem; align-items: center; }
.owners-copy h2 { max-width: 20ch; }
.owners-steps { margin: 1.25rem 0 0; padding: 0; list-style: none; counter-reset: paso; }
.owners-steps li { position: relative; margin-bottom: .85rem; padding-left: 3rem; counter-increment: paso; }
.owners-steps li::before {
    content: counter(paso); position: absolute; left: 0; top: -.1rem; display: flex; align-items: center; justify-content: center;
    width: 2.1rem; height: 2.1rem; font-family: var(--font-head); font-weight: 800; color: var(--ink-deep); background: var(--mark); border-radius: 50%;
}
.owners-offer { padding: 1.5rem; background: var(--paper); box-shadow: var(--paper-shadow); border-top: 6px solid var(--mark); }
.mini-plans { margin: 0 0 .5rem; padding: 0; list-style: none; }
.mini-plans li { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; padding: .65rem 0; border-bottom: 2px dashed var(--line); }
.mini-plan-name { font-family: var(--font-head); font-stretch: 80%; font-weight: 700; font-size: 1.3rem; color: var(--ink); }
.mini-plan-price { font-family: var(--font-head); font-stretch: 80%; font-weight: 800; font-size: 1.5rem; color: var(--ink-deep); }
.mini-plan-price small { font-family: var(--font-body); font-weight: 400; font-size: .85rem; }
.price-note { margin: .5rem 0 1rem; font-size: .9rem; color: var(--soft); }
@media (min-width: 52rem) { .owners { grid-template-columns: 1.2fr 1fr; gap: 3.5rem; } }

.plan-grid { display: grid; gap: 1.5rem; margin-top: .5rem; }
@media (min-width: 52rem) { .plan-grid { grid-template-columns: repeat(3, 1fr); align-items: stretch; } }
.plan-card {
    position: relative; display: flex; flex-direction: column; padding: 1.5rem;
    background: var(--paper); box-shadow: var(--paper-shadow); border-top: 6px solid var(--ink);
}
.plan-card > form, .plan-card > .btn { margin-top: auto; }
.plan-card h2 { font-size: 2rem; margin-bottom: .15em; }
.plan-card-featured { border-top-color: var(--mark); outline: 3px solid var(--mark); outline-offset: -3px; }
.plan-flag { position: absolute; top: -.8rem; right: 1rem; box-shadow: 0 1px 2px rgba(15, 42, 107, .3); }
.plan-card.is-current { box-shadow: 0 0 0 3px var(--ink), var(--paper-shadow); }
.plan-price { margin: 0; line-height: 1.1; }
.plan-amount { font-family: var(--font-head); font-stretch: 70%; font-weight: 800; font-size: 3.2rem; color: var(--ink-deep); font-variant-numeric: tabular-nums; }
.plan-iva { font-weight: 700; color: var(--soft); }
.plan-sub { margin: .1rem 0 1.1rem; color: var(--soft); font-size: .95rem; }
.plan-state { margin: 0 0 .75rem; padding: .5rem .75rem; font-weight: 700; font-size: .95rem; background: var(--wall); border-radius: var(--radius); }
.plan-foot { margin-top: 1rem; }
.plan-card .small { margin-top: 0; }

.plan-card-store { background: var(--ink); color: #fff; border-top-color: var(--copihue); }
.plan-card-store h2, .plan-card-store .plan-amount { color: #fff; }
.plan-card-store .plan-iva, .plan-card-store .plan-sub, .plan-card-store .small { color: #c9d4f0; }
.plan-card-store .plan-state { background: rgba(255, 255, 255, .14); }
.plan-card-store .btn-primary { border-color: var(--mark); }
.plan-card-store.is-current { box-shadow: 0 0 0 3px var(--mark), var(--paper-shadow); }
.plan-card-store .check-list li::after { border-color: var(--ink-deep); }

.checklist { margin-bottom: 1.5rem; padding: 1.1rem 1.25rem; background: var(--paper); border: 2px solid var(--ink); border-left-width: 8px; border-radius: var(--radius); }
.checklist h2 { font-size: 1.4rem; }
.checklist ul { margin-bottom: .5rem; }
.danger-zone { padding: 1.25rem; background: var(--paper); border: 2px dashed var(--err-line); }
.danger-zone h2 { color: var(--err-line); }
.danger-zone { margin: 2rem 0 1.5rem; }
.facts { margin: 0 0 1.75rem; }
.facts > div { display: grid; grid-template-columns: minmax(8rem, 12rem) 1fr; gap: .15rem 1rem; padding: .55rem 0; border-bottom: 1px solid var(--line); }
.facts dt { font-weight: 700; color: var(--ink); }
.facts dd { margin: 0; overflow-wrap: anywhere; }
@media (max-width: 34rem) { .facts > div { grid-template-columns: 1fr; } }
.back-link { display: inline-block; margin-bottom: .75rem; }
.faq dt { margin-top: 1.25rem; font-weight: 700; color: var(--ink); }
.faq dd { margin: .25rem 0 0; }

/* ---------- Página de un negocio ---------- */

.preview-bar { position: sticky; top: 0; z-index: 20; background: var(--mark); color: var(--ink-deep); border-bottom: 3px solid var(--ink); }
.preview-bar .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem 1rem; padding-block: .5rem; }
.preview-bar p { margin: 0; }
.business-cover { max-height: 22rem; overflow: hidden; background: var(--wall-2); }
.business-cover img { width: 100%; max-height: 22rem; object-fit: cover; }
.business-head { padding-bottom: 1rem; }
.business-head .crumbs { margin-top: 1.25rem; }
.business-title { display: flex; flex-wrap: wrap; align-items: center; gap: 1.1rem 1.5rem; }
.business-title h1 { margin-bottom: .2em; }
.business-title > div { flex: 1 1 18rem; min-width: 0; }
.business-logo {
    flex: none; width: 5.5rem; height: 5.5rem; object-fit: cover; background: var(--paper);
    border: 3px solid var(--paper); box-shadow: var(--paper-shadow); border-radius: var(--radius);
}
.business-logo-initial {
    display: flex; align-items: center; justify-content: center;
    font-family: var(--font-head); font-stretch: 70%; font-weight: 800; font-size: 3rem; color: var(--ink); background: var(--mark);
}
.business-meta { margin: 0 0 .5rem; color: var(--soft); }
.business-title .lead { margin-bottom: 0; }
.business-grid { display: grid; gap: 1.75rem; align-items: start; padding-block: 1rem 2rem; }
.business-aside { order: -1; }
.business-main .block:first-child { margin-top: 0; }
.prose { max-width: 42rem; }
.prose p { margin-bottom: 1em; }
.prose h2, .prose h3 { margin-top: 1.75em; }
.legal { font-size: 1rem; }
.legal h2 { font-size: 1.5rem; }
.legal-draft { margin-top: 1rem; }
@media (min-width: 58rem) {
    .business-grid { grid-template-columns: minmax(0, 1fr) 22.5rem; gap: 2.5rem; padding-top: 1.5rem; }
    .business-aside { order: 0; position: sticky; top: 1.25rem; }
    .business-logo { width: 6.5rem; height: 6.5rem; }
}
.flyer-contact { padding-top: 1.9rem; }
.flyer-contact .flyer-title { max-width: none; margin-bottom: .6em; font-size: 2.3rem; }
.flyer-contact .tape { width: 5.5rem; height: 1.6rem; }
.flyer-contact .flyer-main { padding-bottom: 1.25rem; }
.contact-line { margin: .85rem 0 0; }
.contact-address { padding-top: .85rem; border-top: 1px dashed var(--line); }
.claim-note { margin-top: 1.25rem; padding: .85rem 1rem; font-size: .93rem; background: var(--paper); border: 2px dashed var(--field-line); border-radius: var(--radius); }

.product-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(13.5rem, 1fr)); gap: 1rem; margin: 0; padding: 0; list-style: none; }
.product { display: flex; flex-direction: column; background: var(--paper); border: 2px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.product-img { width: 100%; aspect-ratio: 1; object-fit: cover; background: var(--wall); }
.product-img-empty { background: repeating-linear-gradient(135deg, var(--wall) 0 10px, var(--wall-2) 10px 20px); }
.product-body { display: flex; flex-direction: column; flex: 1; gap: .35rem; padding: .9rem; }
.product-body h3 { margin: 0; font-size: 1.2rem; }
.product-price { align-self: flex-start; margin: 0; font-family: var(--font-head); font-stretch: 80%; font-weight: 800; font-size: 1.45rem; line-height: 1.2; color: var(--ink-deep); background: linear-gradient(transparent 55%, var(--mark) 55%); font-variant-numeric: tabular-nums; }
.product-desc { margin: 0 0 .5rem; font-size: .96rem; }
.product-body .btn { width: 100%; margin-top: auto; }
.product-body .btn + .btn { margin-top: .5rem; }
.product-body .product-desc + .btn { margin-top: auto; }

/* ---------- Panel del usuario ---------- */

.panel-list { margin: 0 0 1.25rem; padding: 0; list-style: none; display: grid; gap: .85rem; }
.panel-item { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem 1.5rem; padding: 1.1rem 1.25rem; background: var(--paper); box-shadow: var(--paper-shadow); border-left: 8px solid var(--ink); }
.panel-item-main { flex: 1 1 18rem; min-width: 0; }
.panel-item-main h2 { margin-bottom: .2em; }
.panel-item-main .meta { margin-bottom: .2em; }
.panel-item-actions { display: flex; flex-wrap: wrap; gap: .5rem; }

.product-admin { margin: 0 0 1.5rem; padding: 0; list-style: none; display: grid; gap: .6rem; }
.product-admin-item { background: var(--paper); border: 2px solid var(--line); border-radius: var(--radius); }
.product-admin-item.is-hidden { opacity: .7; }
.product-admin-item summary { display: flex; align-items: center; gap: .85rem; padding: .6rem .8rem; cursor: pointer; list-style: none; }
.product-admin-item summary::-webkit-details-marker { display: none; }
.product-admin-item summary img, .thumb-empty { flex: none; width: 3.5rem; height: 3.5rem; object-fit: cover; border-radius: var(--radius); }
.thumb-empty { background: repeating-linear-gradient(135deg, var(--wall) 0 8px, var(--wall-2) 8px 16px); }
.summary-text { display: flex; flex: 1; flex-direction: column; min-width: 0; }
.summary-action { flex: none; font-weight: 700; color: var(--ink); text-decoration: underline; text-underline-offset: .18em; }
.product-admin-item[open] { border-color: var(--ink); }
.product-admin-body { padding: 0 1rem 1rem; border-top: 2px dashed var(--line); }
.add-product { margin: 1.5rem 0; padding: 1.25rem; background: var(--paper); border: 2px dashed var(--ink); border-radius: var(--radius); }
.add-product h3 { font-size: 1.5rem; }

.receipt { margin: 1.5rem 0; padding: 0; }
.receipt div { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .25rem 1rem; padding: .55rem 0; border-bottom: 1px dashed var(--field-line); }
.receipt dt { color: var(--soft); }
.receipt dd { margin: 0; font-weight: 700; text-align: right; }
.result { border-top-width: 8px; }
.result-ok { border-top-color: var(--ok-line); }
.result-bad { border-top-color: var(--err-line); }
.result-warn { border-top-color: var(--warn-line); }
.claim-card { margin: 1.5rem 0; padding: 1rem 1.25rem; background: var(--wall); border: 2px dashed var(--ink); border-radius: var(--radius); }
.claim-card h2 { margin-bottom: .2em; }

.requirements { margin: 0 0 1.5rem; padding: 0; list-style: none; }
.requirements li { display: flex; gap: .75rem; padding: .5rem 0; border-bottom: 1px dashed var(--line); }
.req-mark { flex: none; width: 1.6rem; height: 1.6rem; display: inline-flex; align-items: center; justify-content: center; font-weight: 800; border-radius: 50%; }
.requirements .is-ok .req-mark { background: var(--ok-bg); color: var(--ok-line); }
.requirements .is-bad .req-mark { background: var(--err-bg); color: var(--err-line); }
.requirements .is-warn .req-mark { background: var(--warn-bg); color: var(--warn-line); }

/* ---------- Tablas y administración ---------- */

.table-wrap { overflow-x: auto; margin-bottom: 1rem; background: var(--paper); border: 2px solid var(--line); border-radius: var(--radius); }
.table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.table th, .table td { padding: .6rem .8rem; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.table th { white-space: nowrap; font-size: .85rem; color: var(--ink-deep); background: var(--wall); }
.table tr:last-child td { border-bottom: 0; }
.table .row-alert td, .row-alert td { background: var(--warn-bg); }
.table td .copy-box { margin: 0; min-width: 14rem; }

body.admin { background: var(--wall); font-size: 1rem; }
.admin-bar { background: var(--ink-deep); color: #fff; border-bottom: 4px solid var(--mark); }
.admin-bar-inner { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1.5rem; padding-block: .6rem; }
.brand-admin .brand-name { font-size: 1.4rem; }
.admin-tag { font-family: var(--font-body); font-stretch: 100%; font-weight: 500; font-size: .85rem; color: var(--mark); }
.admin-nav { display: flex; flex-wrap: wrap; gap: .15rem 1.1rem; flex: 1 1 auto; }
.admin-nav a { padding: .4rem 0; color: #fff; text-decoration: none; border-bottom: 3px solid transparent; }
.admin-nav a:hover { border-bottom-color: rgba(255, 255, 255, .5); }
.admin-nav a[aria-current] { border-bottom-color: var(--mark); font-weight: 700; }
.admin-bar-end { display: flex; align-items: center; gap: 1rem; margin-left: auto; }
.admin-bar-end a, .admin-bar-end .link-button { color: #fff; }
.admin-main { padding-block: 1.75rem 3rem; }
.admin-main h1 { font-size: clamp(1.8rem, 1.2rem + 2.4vw, 2.6rem); }
.admin-main h2 { font-size: 1.6rem; margin-top: 2rem; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(10.5rem, 1fr)); gap: .85rem; margin-bottom: 1rem; }
.stat-grid-wide { grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr)); }
.stat { display: flex; flex-direction: column; gap: .15rem; padding: 1rem; color: var(--text); text-decoration: none; background: var(--paper); border-left: 6px solid var(--ink); box-shadow: var(--paper-shadow); }
a.stat:hover { border-left-color: var(--mark); }
.stat-n { font-family: var(--font-head); font-stretch: 72%; font-weight: 800; font-size: 2.2rem; line-height: 1; color: var(--ink-deep); font-variant-numeric: tabular-nums; }
.stat-label { font-size: .92rem; color: var(--soft); }
.admin-grid { display: grid; gap: 1rem; margin: 1.25rem 0 .5rem; }
@media (min-width: 52rem) { .admin-grid { grid-template-columns: 1fr 1fr; align-items: start; } }
.admin-card { margin-bottom: 1rem; padding: 1.25rem; background: var(--paper); box-shadow: var(--paper-shadow); border-top: 4px solid var(--ink); }
.admin-grid .admin-card { margin-bottom: 0; }
.admin-card .h3 { margin-top: 0; }
.admin-card details { margin-top: 1rem; }
.admin-card summary { cursor: pointer; font-weight: 700; }
.rubro-list { padding-top: .75rem; }
.rubro-list .h4 { margin: 1rem 0 .15rem; }
.rec-list { margin: 0; padding: 0; list-style: none; display: grid; gap: .85rem; }
.rec { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem 1.5rem; padding: 1.1rem 1.25rem; background: var(--paper); box-shadow: var(--paper-shadow); border-left: 8px solid var(--mark); }
.rec-main { flex: 1 1 22rem; min-width: 0; }
.rec-main p { margin-bottom: .4em; }
.rec-note { padding: .5rem .8rem; background: var(--wall); border-left: 4px solid var(--field-line); }
.rec-actions { display: flex; flex-direction: column; gap: .4rem; min-width: 10rem; }
.rec-actions form { margin: 0; }
.rec-actions .btn { width: 100%; }

/* ---------- Resultados (visitas y clics) ---------- */

.stat-delta { margin-top: .35rem; font-size: .85rem; color: var(--soft); }
.chart { margin: 0 0 1rem; padding: 1rem 1rem .75rem; background: var(--paper); box-shadow: var(--paper-shadow); }
.chart-svg { display: block; width: 100%; height: auto; }
.chart-grid { stroke: var(--wall-2); stroke-width: 1; }
.chart-base { stroke: var(--field-line); stroke-width: 1; }
.chart-bar { fill: var(--ink); }
.chart-hit { fill: transparent; }
.chart-hit:hover { fill: rgba(15, 42, 107, .08); }
.chart-axis { display: flex; justify-content: space-between; margin: .35rem 0 .6rem; font-size: .85rem; color: var(--soft); font-variant-numeric: tabular-nums; }
.chart figcaption { margin: 0; }
.chart-table { margin-bottom: 1.5rem; }
.chart-table summary { cursor: pointer; font-weight: 700; margin-bottom: .75rem; }
.share-row { display: flex; flex-wrap: wrap; gap: .6rem; margin-bottom: 1.5rem; max-width: 40rem; }
.share-input { flex: 1 1 16rem; min-width: 0; }
.panel-results { font-weight: 700; color: var(--ink); }

/* ---------- Pantallas angostas ---------- */

@media (max-width: 30rem) {
    .site-header-bar { justify-content: center; }
    .brand-name { font-size: 1.55rem; }
    .btn-large { width: 100%; }
    .form-actions .btn { flex: 1 1 100%; }
    .notice .btn, .panel-item-actions .btn { flex: 1 1 auto; }
    .tape { width: 5.5rem; }
}

/* ---------- Preferencias de movimiento ---------- */

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation: none !important; transition: none !important; }
}
