/* Vector Seguros: hoja de estilos del sitio.
   Paleta y formas derivadas del logo: azules del isotipo, azul noche de su fondo
   y la silueta de sus alas (esquinas alternas muy redondeadas). */
:root {
    --ink: #0d1530;
    --ink-2: #47536f;
    --line: #dbe2f0;
    --paper: #ffffff;
    --tint: #f3f6fd;
    --night: #030b30;
    --brand: #0b1f4d;
    --accent: #2343e6;
    --accent-dark: #1a31b4;
    --sky: #5db6fa;
    --ok: #067647;
    --bad: #b42318;
    --radius: 6px;
    --wrap: 1120px;
    --wing: linear-gradient(90deg, #213bfd, #4589f8 55%, #5db6fa);
    --dusk: radial-gradient(90% 120% at 88% 100%, rgba(93, 182, 250, .38), transparent 60%),
            linear-gradient(118deg, #030b30 0%, #08195a 46%, #1a36bd 100%);
}

html { scroll-behavior: smooth; }
[id] { scroll-margin-top: 76px; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: 'Schibsted Grotesk', system-ui, sans-serif; font-size: 17px; line-height: 1.6; display: flex; flex-direction: column; min-height: 100vh; min-height: 100dvh; }
main { flex: 1 0 auto; }
h1, h2, h3 { margin: 0; line-height: 1.15; letter-spacing: -.015em; font-weight: 700; text-wrap: balance; }
h1 { font-size: clamp(34px, 5vw, 56px); }
h2 { font-size: clamp(26px, 3vw, 36px); }
h3 { font-size: 19px; }
p { margin: 0; }
a { color: inherit; }
:focus-visible { outline: 3px solid #1d4ed8; outline-offset: 2px; }
.wrap { width: min(var(--wrap), 100% - 40px); margin-inline: auto; }
.narrow { max-width: 720px; }
.lead { font-size: 19px; color: var(--ink-2); max-width: 54ch; }
.muted { color: var(--ink-2); }
.small { font-size: 14px; }
.link { color: var(--brand); font-weight: 500; text-decoration: underline; text-underline-offset: 3px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 12px; top: 12px; z-index: 50; background: #fff; padding: 8px 14px; }

/* Cabecera */
.site-header { position: sticky; top: 0; z-index: 20; border-bottom: 1px solid var(--line); background: var(--paper); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 68px; flex-wrap: wrap; }
.brand { display: inline-flex; flex: none; max-width: 100%; text-decoration: none; }
.brand img { display: block; width: auto; height: 44px; max-width: 100%; }
.site-header .brand img { height: 36px; }
.site-nav { display: flex; align-items: center; gap: 28px; font-size: 16px; }
.site-nav a { text-decoration: none; padding: 6px 0; border-bottom: 2px solid transparent; }
.site-nav a:hover { border-color: var(--line); }
.site-nav a[aria-current="page"] { border-color: var(--accent); }
.site-nav .btn { padding: 8px 16px; border: 1px solid var(--ink); }
.menu-toggle { display: none; background: none; border: 1px solid var(--line); border-radius: var(--radius); padding: 6px 14px; font: inherit; font-size: 15px; }

/* Botones */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 10px 22px; border: 1px solid transparent; border-radius: 4px 16px 4px 16px; font: inherit; font-size: 16px; font-weight: 500; text-decoration: none; cursor: pointer; transition: background-color .2s, border-color .2s; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-dark); }
.btn-dark { background: var(--accent); color: #fff; }
.btn-dark:hover { background: var(--accent-dark); }
.btn-ghost { border-color: rgba(255, 255, 255, .45); color: #fff; }
.btn-ghost:hover { background: rgba(255, 255, 255, .1); border-color: #fff; }
.button-row { display: flex; flex-wrap: wrap; gap: 12px; }
.btn-line { background: transparent; border-color: var(--ink); color: var(--ink); }
.btn-line:hover { background: var(--tint); }
.btn[disabled] { opacity: .6; cursor: wait; }
.btn-block { width: 100%; }

/* Campos */
.field { display: flex; flex-direction: column; gap: 6px; font-size: 15px; font-weight: 500; }
.input, .field input, .field select, .field textarea { width: 100%; min-height: 48px; padding: 10px 14px; border: 1px solid #98a2b3; border-radius: var(--radius); background-color: #fff; color: var(--ink); font: inherit; font-size: 16px; font-weight: 400; }
.field input:focus, .field select:focus, .field textarea:focus, .input:focus { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(11, 31, 77, .18); outline: none; }
.field input:disabled { background: var(--tint); color: var(--ink-2); }
.field-error { color: var(--bad); font-weight: 400; font-size: 14px; }
.form { display: grid; gap: 18px; }
.cols { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.span-2 { grid-column: 1 / -1; }

/* Patente */
.plate-form { display: flex; flex-wrap: wrap; align-items: stretch; gap: 12px; }
.plate { display: flex; flex-direction: column; width: 260px; padding: 6px 10px 4px; background: #fff; border: 3px solid var(--ink); border-radius: 10px; color: var(--ink); }
.plate:focus-within { box-shadow: 0 0 0 3px #93b4ff; }
.plate input { width: 100%; border: 0; padding: 0; background: transparent; text-align: center; text-transform: uppercase; font: inherit; font-size: 40px; font-weight: 700; letter-spacing: .12em; line-height: 1.2; color: var(--ink); box-shadow: none; outline: none; }
.plate input:focus { box-shadow: none; outline: none; }
.plate input::placeholder { color: #c3c8d1; }
.plate small { text-align: center; font-size: 11px; font-weight: 700; letter-spacing: .35em; }
.plate-form .btn { min-width: 150px; }

/* Formas de marca */
.photo { margin: 0; }
.photo img { display: block; width: 100%; height: 100%; object-fit: cover; }
.petal img { border-radius: 6px 120px 6px 120px; }
.petal-sm { border-radius: 8px 48px 8px 48px; }
.photo figcaption { margin-top: 12px; font-size: 14px; color: var(--ink-2); text-align: right; }

/* Superficies oscuras */
.on-dark { color: #fff; }
.on-dark .lead, .on-dark .muted { color: #cfdcff; }
.on-dark .link { color: #fff; }
.on-dark :focus-visible { outline-color: #9fd4ff; }
.on-dark .btn-primary { background: #fff; color: var(--brand); }
.on-dark .btn-primary:hover { background: #dcebff; }

/* Portada */
.hero-main, .page-head { position: relative; overflow: hidden; isolation: isolate; background: var(--dusk); }
/* El isotipo, ampliado, como marca de agua */
.hero-main::after, .page-head::after { content: ""; position: absolute; z-index: -1; pointer-events: none; background: url('../images/vector-isotipo-dark.svg') no-repeat center / contain; }
.hero-main::after { width: 760px; height: 655px; right: -150px; bottom: -190px; opacity: .13; }
.hero-main .wrap { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 72px); align-items: start; padding-block: clamp(48px, 8vw, 112px); }
/* El título arranca a la misma altura en todas las cabeceras, sin importar cuánto contenido lleve debajo. */
.hero-main .stack { padding-top: clamp(0px, calc(8vw - 70px), 45px); }
.hero-main h1 { font-size: clamp(38px, 5.4vw, 64px); }
.hero-main .stack { gap: 24px; }
.hero-alt { margin-top: -8px; }
.hero-main .photo img { aspect-ratio: 4 / 3; object-position: 40% 20%; box-shadow: 0 40px 70px -30px rgba(0, 5, 40, .75); }

.how { border-bottom: 1px solid var(--line); }
.how ol { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(20px, 4vw, 48px); margin: 0; padding: 40px 0 44px; list-style: none; counter-reset: paso; }
.how li { counter-increment: paso; display: grid; grid-template-columns: 44px 1fr; column-gap: 14px; align-content: start; }
.how li::before { content: counter(paso); grid-row: span 2; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 3px 18px 3px 18px; background: var(--accent); color: #fff; font-weight: 700; }
.how p { grid-column: 2; font-size: 15px; color: var(--ink-2); line-height: 1.5; }

.duo { display: grid; grid-template-columns: 5fr 7fr; gap: clamp(32px, 7vw, 96px); align-items: center; }
.soap-photo img { aspect-ratio: 4 / 5; max-height: 500px; object-position: 55% 30%; }
.title-lg { font-size: clamp(32px, 4.4vw, 52px); }
.panel { padding: clamp(22px, 3.5vw, 40px); background: #fff; border: 1px solid var(--line); box-shadow: 0 30px 60px -40px rgba(11, 31, 77, .35); }

.section { padding-block: clamp(48px, 7vw, 96px); }
.section-tint { background: linear-gradient(160deg, #eef3fe 0%, #f7f9fe 55%, #eaf4fe 100%); }
.split { display: grid; grid-template-columns: 5fr 7fr; gap: clamp(32px, 6vw, 80px); align-items: start; }
.split > .stack { position: sticky; top: 98px; }
.stack { display: grid; gap: 16px; justify-items: start; align-content: start; }

/* Tablas y listas */
.table { width: 100%; border-collapse: collapse; background: var(--wing) top / 100% 3px no-repeat; }
.table th, .table td { padding: 14px 0; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; font-weight: 400; }
.table thead th { font-size: 14px; font-weight: 700; }
.table td:last-child, .table thead th:last-child { text-align: right; font-weight: 700; white-space: nowrap; padding-left: 16px; }
.data { margin: 0; padding-top: 3px; background: var(--wing) top / 100% 3px no-repeat; }
.data div { display: grid; grid-template-columns: minmax(120px, 1fr) 2fr; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.data dt { color: var(--ink-2); }
.data dd { margin: 0; font-weight: 500; overflow-wrap: anywhere; }
.data .total dd { font-size: 24px; font-weight: 700; }

/* Páginas interiores */
.page-head { padding-block: clamp(36px, 5vw, 68px); }
.page-head::after { width: 380px; height: 328px; right: -60px; bottom: -110px; opacity: .14; }
.page-head .wrap { display: grid; gap: 14px; justify-items: start; }
.page-head h1 { font-size: clamp(30px, 4vw, 44px); }


.section-title { margin-bottom: 32px; }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 20px; margin: 0; padding: 0; list-style: none; }
.card { display: grid; gap: 8px; align-content: start; padding: 28px 24px; background: #fff; border: 1px solid var(--line); box-shadow: 0 30px 60px -48px rgba(11, 31, 77, .45); overflow-wrap: anywhere; }
.card::before { content: ""; width: 32px; height: 14px; margin-bottom: 6px; border-radius: 2px 10px 2px 10px; background: var(--wing); }
.card .price { font-size: 26px; font-weight: 700; color: var(--accent); }

.contact { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px 48px; }
.contact .stack { justify-items: start; }

/* Flujos de compra */
main:has(.flow) { background: linear-gradient(160deg, #e8effe 0%, #f7f9fe 55%, #e4f1fe 100%); }
.flow { padding-bottom: clamp(48px, 7vw, 88px); }
.flow-card { position: relative; z-index: 1; margin-top: -32px; padding: clamp(24px, 4vw, 44px); background: #fff; border: 1px solid var(--line); border-radius: 8px 56px 8px 56px; box-shadow: 0 30px 70px -40px rgba(11, 31, 77, .4); }

/* Lista de precios del SOAP: cada tarjeta lleva a cotizar */
.price-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px 32px; margin-bottom: 32px; }
.price-head .section-title { margin-bottom: 8px; }
.validity { display: inline-flex; align-items: center; flex-wrap: wrap; gap: 0 6px; padding: 8px 16px; border: 1px solid var(--line); border-radius: 4px 16px 4px 16px; background: #fff; font-size: 14px; color: var(--ink-2); }
.validity strong { color: var(--ink); }
.price-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin: 0; padding: 0; list-style: none; }
.price-grid li { display: flex; }
.price-card { flex: 1; display: flex; flex-direction: column; align-items: flex-start; gap: 18px; padding: 22px; border: 1px solid var(--line); border-radius: 6px 32px 6px 32px; background: #fff; color: var(--ink); text-decoration: none; box-shadow: 0 1px 2px rgba(11, 31, 77, .05); }
.price-card:hover, .price-card:focus-visible { border-color: var(--accent); box-shadow: 0 24px 40px -26px rgba(11, 31, 77, .45); }
.price-icon { display: grid; place-items: center; width: 68px; height: 52px; border-radius: 4px 18px 4px 18px; background: var(--tint); color: var(--brand); }
.price-card:hover .price-icon, .price-card:focus-visible .price-icon { background: var(--accent); color: #fff; }
.price-info { display: block; overflow-wrap: anywhere; }
.price-info h3 { font-size: 18px; }
.price-info p { margin-top: 6px; font-size: 14px; line-height: 1.45; color: var(--ink-2); }
.price-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; align-self: stretch; gap: 6px 12px; margin-top: auto; padding-top: 16px; border-top: 1px solid var(--line); }
.price-foot strong { font-size: 26px; line-height: 1.2; letter-spacing: -.02em; }
.price-foot strong.pending { font-size: 18px; color: var(--ink-2); }
.price-go { font-size: 15px; font-weight: 500; color: var(--accent); white-space: nowrap; }
@media (max-width: 980px) { .price-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
/* En el celular cada tipo es una fila: se comparan sin tanto desplazamiento */
@media (max-width: 600px) {
    .validity { padding: 0; border: 0; background: none; font-size: 13px; }
    .price-head { gap: 8px; margin-bottom: 20px; }
    .price-grid { grid-template-columns: minmax(0, 1fr); gap: 10px; }
    .price-card { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 16px; border-radius: 6px 24px 6px 24px; }
    .price-icon { width: 52px; height: 44px; }
    .price-icon svg { width: 36px; height: auto; }
    .price-info h3 { font-size: 16px; }
    .price-info p { margin-top: 2px; font-size: 13px; }
    .price-foot { flex-direction: column; align-items: flex-end; align-self: center; gap: 2px; margin: 0; padding: 0; border: 0; }
    .price-foot strong { font-size: 19px; }
    .price-foot strong.pending { font-size: 14px; }
    .price-go { font-size: 13px; }
}

/* Tipos de garantía: mismas tarjetas, con la etapa de la licitación como línea de tiempo */
a.validity { text-decoration: none; color: var(--accent); font-weight: 500; }
a.validity:hover { border-color: var(--accent); }
.guarantee-grid li { flex-direction: column; }
.stage { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-2); }
.stage::before { content: ""; flex: none; width: 11px; height: 11px; border: 3px solid var(--accent); border-radius: 50%; background: #fff; }
.stage::after { content: ""; flex: 1; min-width: 12px; height: 2px; background: var(--line); }
.guarantee-grid .price-info p { font-size: 15px; line-height: 1.55; }
.guarantee-grid .price-foot { justify-content: flex-start; }
@media (max-width: 600px) {
    .guarantee-grid { gap: 20px; }
    .guarantee-grid .stage { margin-bottom: 8px; }
    .guarantee-grid .price-card { grid-template-columns: 52px minmax(0, 1fr); align-items: start; }
    .guarantee-grid .price-foot { grid-column: 2; align-items: flex-start; }
    .guarantee-grid .price-go { font-size: 14px; }
}

/* Texto legal */
.legal-text ol { margin: 0; padding: 0; list-style: none; counter-reset: clausula; }
.legal-text li { counter-increment: clausula; margin-top: 28px; padding-top: 28px; border-top: 1px solid var(--line); }
.legal-text li :is(h2, h3) { margin-bottom: 10px; font-size: 20px; }
.legal-text li :is(h2, h3)::before { content: counter(clausula) ". "; }
.legal-text p { white-space: pre-line; overflow-wrap: anywhere; }

/* Ventana emergente: cabecera y pie fijos, el texto se desplaza al centro */
.modal { width: min(720px, 100% - 32px); max-width: 100%; max-height: min(82vh, 760px); max-height: min(82dvh, 760px); margin: auto; padding: 0; border: 0; border-radius: 8px 40px 8px 40px; background: #fff; color: var(--ink); overflow: hidden; box-shadow: 0 40px 90px -30px rgba(0, 5, 40, .6); }
.modal[open] { display: flex; flex-direction: column; }
.modal::backdrop { background: rgba(3, 11, 48, .62); }
.modal > header { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 22px 28px 16px; border-bottom: 1px solid var(--line); }
.modal > header h2 { font-size: 24px; }
.modal-close { width: 40px; height: 40px; border: 1px solid var(--line); border-radius: 4px 14px 4px 14px; background: none; color: inherit; font: inherit; font-size: 24px; line-height: 1; cursor: pointer; }
.modal-close:hover { background: var(--tint); }
.modal-body { flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 20px 28px 28px; font-size: 16px; }
.modal-body li :is(h2, h3) { font-size: 18px; }
/* El foco del texto se marca en la línea bajo el título, sin recuadro. */
.modal-body:focus-visible { outline: none; }
.modal:has(.modal-body:focus-visible) > header { border-bottom-color: var(--accent); }
.modal > footer { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 28px; border-top: 1px solid var(--line); }
html:has(.modal[open]) { overflow: hidden; scrollbar-gutter: stable; }
/* En el celular ocupa casi toda la pantalla y nace desde abajo */
@media (max-width: 680px) {
    .modal { width: 100%; max-height: 92vh; max-height: 92dvh; margin: auto 0 0; border-radius: 22px 22px 0 0; }
    .modal > header, .modal-body, .modal > footer { padding-inline: 20px; }
}

/* Asistente por pasos */
.flow-card { scroll-margin-top: 86px; }
.step-title:focus { outline: none; }
.optional { color: var(--ink-2); font-weight: 400; }
.field-help { color: var(--ink-2); font-size: 14px; font-weight: 400; line-height: 1.4; }
.field [aria-invalid="true"] { border-color: var(--bad); box-shadow: 0 0 0 1px var(--bad); }
.choices[aria-invalid="true"] .choice { border-color: var(--bad); }
.hint { margin-top: 28px; padding: 16px 20px; border-radius: 4px 20px 4px 20px; background: var(--tint); font-size: 15px; }
.hint ul { margin: 6px 0 0; padding-left: 18px; list-style: disc; color: var(--ink-2); }
.quote { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 16px; margin: 24px 0; padding: 18px 22px; border-radius: 4px 24px 4px 24px; background: var(--tint); }
.quote strong { font-size: 28px; color: var(--accent); }
.quote p { flex-basis: 100%; }
.summary { margin-bottom: 28px; }
.summary header { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.link-button { padding: 4px 0; border: 0; background: none; color: var(--accent); font: inherit; font-size: 15px; font-weight: 500; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.plate-chip { display: flex; flex-wrap: wrap; align-items: baseline; gap: 12px; margin: -8px 0 20px; }
.btn[disabled]:not([wire\:loading]) { cursor: not-allowed; }
.stepper { display: flex; gap: 6px; margin: 0 0 32px; padding: 0; list-style: none; }
.stepper li { position: relative; flex: 1; padding-top: 14px; font-size: 14px; color: var(--ink-2); line-height: 1.3; }
.stepper li::before, .stepper li::after { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 4px; background: var(--line); }
.stepper li::after { background: var(--accent); transform: scaleX(0); transform-origin: left; }
.stepper li.done::after { background: var(--brand); transform: none; }
.stepper li.current { color: var(--ink); font-weight: 700; }
.stepper li.current::after { transform: none; }
@media (forced-colors: active) { .stepper li.done::after, .stepper li.current::after { background: Highlight; } }
.step-title { margin-bottom: 20px; font-size: 24px; }
.actions { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--line); }
.actions > div { display: flex; flex-wrap: wrap; gap: 12px; margin-left: auto; }
.choices { display: grid; gap: 10px; margin: 0 0 28px; padding: 0; border: 0; }
.choices legend { margin-bottom: 8px; font-weight: 700; }
.choice { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border: 1px solid #98a2b3; border-radius: var(--radius); cursor: pointer; }
.choice:has(input:checked) { border-color: var(--brand); box-shadow: inset 0 0 0 1px var(--brand); }
.choice input { color: var(--brand); }
.loading { margin-top: 16px; color: var(--ink-2); }

/* Avisos */
.notice { padding: 14px 16px; margin-bottom: 20px; border-left: 4px solid var(--brand); background: var(--tint); }
.notice-error { border-color: var(--bad); background: #fef3f2; color: #7a271a; }
.notice-ok { border-color: var(--ok); background: #ecfdf3; color: #054f31; }
.notice ul { margin: 6px 0 0; padding-left: 18px; list-style: disc; }

/* Acceso */
main:has(> .auth) { padding: clamp(28px, 6vw, 80px) 0; background: linear-gradient(160deg, #e8effe 0%, #f7f9fe 55%, #e4f1fe 100%); }
.auth { width: min(480px, 100% - 28px); margin-inline: auto; padding: clamp(24px, 4vw, 44px); background: #fff; border: 1px solid var(--line); border-radius: 8px 56px 8px 56px; box-shadow: 0 30px 70px -40px rgba(11, 31, 77, .4); }
.auth h1 { font-size: 32px; margin-bottom: 8px; }
.auth > p { margin-bottom: 28px; color: var(--ink-2); }
.auth-wide { width: min(680px, 100% - 28px); }
.auth-links { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-top: 24px; font-size: 15px; }

/* Pie */
.site-footer { position: relative; overflow: hidden; isolation: isolate; background: var(--night); font-size: 15px; }
.site-footer::before { content: ""; position: absolute; top: 0; right: 0; left: 0; height: 3px; background: var(--wing); }
.site-footer::after { content: ""; position: absolute; z-index: -1; right: -110px; bottom: -150px; width: 520px; height: 450px; pointer-events: none; opacity: .06; background: url('../images/vector-isotipo-dark.svg') no-repeat center / contain; }
.site-footer .muted { color: #b9c6ea; }
.footer-cta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px 40px; margin-top: 56px; padding: 32px 40px; border: 1px solid rgba(255, 255, 255, .13); border-radius: 8px 48px 8px 48px; background: var(--dusk); }
.footer-cta h2 { margin-bottom: 6px; font-size: clamp(22px, 2.4vw, 28px); }
.footer-main { display: grid; grid-template-columns: minmax(0, 1.9fr) repeat(3, minmax(0, 1fr)); gap: 40px 32px; padding-block: 56px 48px; }
.site-footer .about { display: grid; gap: 14px; justify-items: start; align-content: start; }
.footer-contact { display: inline-flex; align-items: center; gap: 12px; max-width: 100%; margin-top: 6px; padding: 10px 18px 10px 14px; border: 1px solid rgba(255, 255, 255, .16); border-radius: 5px 18px 5px 18px; font-weight: 500; text-decoration: none; overflow-wrap: anywhere; }
.footer-contact:hover { border-color: rgba(255, 255, 255, .5); background: rgba(255, 255, 255, .06); }
.footer-contact svg { flex: none; color: #8fc4ff; }
.footer-contact span { display: block; min-width: 0; line-height: 1.35; }
.footer-contact small { display: block; font-size: 12px; font-weight: 400; color: #9fadd6; }
.footer-main h2 { margin-bottom: 18px; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: #8f9fcd; }
.footer-main ul { margin: 0; padding: 0; list-style: none; }
.footer-main li { margin-bottom: 12px; }
.footer-main li a, .site-footer .legal a { color: #d5ddf5; text-decoration: none; }
.footer-main li a:hover, .site-footer .legal a:hover { color: #fff; text-decoration: underline; text-underline-offset: 4px; }
.site-footer .legal { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px; padding-block: 22px 28px; border-top: 1px solid rgba(255, 255, 255, .12); color: #9fadd6; font-size: 14px; }
.site-footer .legal div { display: flex; flex-wrap: wrap; gap: 10px 28px; }

@media (max-width: 860px) {
    .hero-main .wrap, .duo, .split { grid-template-columns: 1fr; }
    .hero-main .stack { padding-top: 0; }
    .how ol { grid-template-columns: 1fr; padding-block: 28px; }
    .soap-photo { order: 2; }
    .split > .stack { position: static; }
    .soap-photo img { aspect-ratio: 4 / 3; max-height: none; }
    .petal img { border-radius: 6px 64px 6px 64px; }
    .flow-card { border-radius: 8px 36px 8px 36px; }
    .footer-main { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .site-footer .about { grid-column: 1 / -1; }
}

/* El menú se pliega antes que el resto: más angosto no cabe en una fila. */
@media (max-width: 760px) {
    .menu-toggle { display: block; }
    .site-nav { display: none; width: 100%; flex-direction: column; align-items: stretch; gap: 4px; padding-bottom: 16px; }
    .site-nav.open { display: flex; }
    .site-nav .btn { margin-top: 8px; }
}

@media (max-width: 680px) {
    .site-header .brand img { height: 34px; }
    .footer-cta { margin-top: 36px; padding: 24px 20px; border-radius: 8px 32px 8px 32px; }
    .footer-cta .button-row { width: 100%; }
    .footer-main { grid-template-columns: repeat(2, minmax(0, 1fr)); padding-block: 40px 32px; }
    .cols { grid-template-columns: 1fr; }
    .button-row { flex-direction: column; align-self: stretch; }
    .plate-form { flex-direction: column; width: 100%; }
    .plate { width: 100%; }
    .stepper li span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
    .stepper li { height: 6px; padding: 0; }
    .stepper li::before, .stepper li::after { height: 6px; }
    .stepper-now { display: block !important; }
    .actions .btn { flex: 1; }
    .actions > div { width: 100%; }
}
.stepper-now { display: none; margin: -20px 0 24px; font-weight: 700; }

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

/* Mi cuenta (clientes) */
main:has(> .account) { background: var(--tint); }
.page-head.account-head { padding-bottom: 0; }
.page-head.account-head .wrap { display: block; justify-items: stretch; padding-bottom: 0; }
.account-title { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.account-title p { margin-top: 4px; overflow-wrap: anywhere; }
.account-title form { margin: 0; }
.account-tabs { display: flex; gap: 4px; margin-top: 28px; }
.account-tabs a { padding: 11px 18px; border-radius: 6px 18px 0 0; color: #cfdcff; text-decoration: none; font-weight: 500; }
.account-tabs a:hover { background: rgba(255, 255, 255, .08); color: #fff; }
.account-tabs a[aria-current="page"] { background: var(--tint); color: var(--ink); }
.account-body { padding-block: 36px 72px; }
.account-body .notice { margin-bottom: 20px; }
.account-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 20px; }
.account-card { padding: 24px; background: #fff; border: 1px solid var(--line); border-radius: 8px 28px 8px 28px; }
.account-card h3 { font-size: 18px; }
.account-empty { text-align: center; padding: 48px 24px; }
.account-empty p { margin-top: 8px; }
.purchases { display: grid; gap: 14px; margin: 0; padding: 0; list-style: none; }
.purchase { display: grid; grid-template-columns: minmax(0, 1fr) 340px 160px; gap: 20px; align-items: center; }
.purchase-main { overflow-wrap: anywhere; }
.purchase > dl { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px 18px; margin: 0; font-size: 15px; }
.purchase-detail { grid-column: 1 / -1; padding-top: 14px; border-top: 1px solid var(--line); }
.purchase-detail summary { width: max-content; color: var(--accent); font-size: 15px; font-weight: 500; cursor: pointer; }
.purchase-groups { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); gap: 24px 32px; margin-top: 20px; }
.purchase-groups h4 { margin: 0 0 8px; font-size: 15px; }
.purchase-groups dl { margin: 0; font-size: 15px; }
.purchase-groups dl > div { display: grid; grid-template-columns: 130px minmax(0, 1fr); gap: 10px; padding: 7px 0; border-bottom: 1px solid var(--line); }
.purchase-groups dd { white-space: pre-line; overflow-wrap: anywhere; }
.purchase dt { font-size: 13px; color: var(--ink-2); }
.purchase dd { margin: 0; font-weight: 500; }
.purchase > dl dd { white-space: nowrap; }
.purchase-end { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
.state { padding: 3px 11px; border-radius: 20px; background: #eef1f8; color: var(--ink-2); font-size: 13px; font-weight: 700; }
.state-ok { background: #e7f8ee; color: #05603a; }
.state-warn { background: #fff4d6; color: #7a4d00; }
.account-verify { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px; margin-top: 24px; }
.account-forms { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 20px; align-items: start; }
.account-forms h2 { margin-bottom: 4px; }
.account-forms .account-card > p.muted { margin-bottom: 20px; overflow-wrap: anywhere; }
.account-forms .form { grid-template-columns: minmax(0, 1fr); }
@media (max-width: 980px) {
    .purchase { grid-template-columns: minmax(0, 1fr); gap: 14px; }
    .purchase-end { flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: space-between; }
    .account-forms { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 420px) { .purchase-groups dl > div { grid-template-columns: minmax(0, 1fr); gap: 0; } .purchase > dl { grid-template-columns: repeat(2, auto); } }

/* Movimiento: corto, una sola vez y apagado para quien pide reducirlo. */
.site-header.scrolled { box-shadow: 0 12px 28px -20px rgba(11, 31, 77, .45); }

@media (prefers-reduced-motion: no-preference) {
    :root { --ease: cubic-bezier(.2, .7, .2, 1); }

    /* Fundido entre páginas, con la cabecera quieta (donde el navegador lo soporte) */
    @view-transition { navigation: auto; }
    .site-header { view-transition-name: cabecera; transition: box-shadow .25s; }

    /* Portadas */
    .hero-main .stack > * { animation: entra .25s var(--ease) backwards; }
    .hero-main .stack > :nth-child(2) { animation-delay: .03s; }
    .hero-main .stack > :nth-child(3) { animation-delay: .06s; }
    .hero-main .stack > :nth-child(4) { animation-delay: .09s; }
    .hero-main .photo { animation: entra .25s var(--ease) backwards; }

    /* Pasos de compra */
    .step-panel { animation: entra-lado .2s var(--ease) backwards; }
    .stepper li::after { transition: transform .45s var(--ease), background-color .45s; }

    /* Detalles */
    .btn { transition: background-color .2s, border-color .2s, transform .12s; }
    .btn:active:not([disabled]) { transform: scale(.97); }
    .site-nav.open { animation: entra-menu .22s var(--ease); }
    .purchase-detail[open] > :not(summary) { animation: entra .3s var(--ease) backwards; }
    .price-card { transition: transform .2s var(--ease), box-shadow .2s, border-color .2s; }
    .price-card:hover { transform: translateY(-3px); }
    .price-icon { transition: background-color .2s, color .2s; }
    .modal[open] { animation: entra .28s var(--ease); }
    .modal[open]::backdrop { animation: aparece .28s; }
    .wsp-boton { transition: transform .2s var(--ease), box-shadow .2s; }
    .wsp-boton:hover { transform: scale(1.06); }
    .wsp-ficha:popover-open { animation: entra .22s var(--ease); }
}
@media (prefers-reduced-motion: no-preference) and (max-width: 680px) {
    .modal[open] { animation-name: sube; }
}

@keyframes entra { from { opacity: 0; transform: translateY(14px); } }
@keyframes entra-lado { from { opacity: 0; transform: translateX(18px); } }
@keyframes aparece { from { opacity: 0; } }
@keyframes sube { from { transform: translateY(100%); } }
@keyframes entra-menu { from { opacity: 0; transform: translateY(-8px); } }

/* Botón flotante de WhatsApp: siempre abajo a la derecha */
html { scroll-padding-bottom: 96px; }
.wsp-boton { position: fixed; z-index: 30; right: 20px; bottom: calc(20px + env(safe-area-inset-bottom)); display: grid; place-items: center; width: 58px; height: 58px; padding: 0; border: 0; border-radius: 50%; background: #25d366; color: #fff; cursor: pointer; box-shadow: 0 14px 30px -10px rgba(3, 11, 48, .5); }
.wsp-boton:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
/* El display solo al abrir: cerrada, el navegador la oculta. */
.wsp-ficha { position: fixed; inset: auto 20px calc(90px + env(safe-area-inset-bottom)) auto; width: min(320px, 100% - 40px); margin: 0; padding: 22px; border: 1px solid var(--line); border-radius: 8px 28px 8px 28px; background: #fff; color: var(--ink); box-shadow: 0 30px 60px -24px rgba(3, 11, 48, .45); }
.wsp-ficha:popover-open { display: grid; gap: 14px; }
.wsp-ficha header { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.wsp-ficha h2 { margin: 0; font-size: 19px; }
.wsp-ficha p { margin: 0; font-size: 15px; line-height: 1.45; }
.wsp-cerrar { flex: none; width: 32px; height: 32px; margin: -6px -6px 0 0; border: 0; border-radius: 8px; background: none; color: inherit; font: inherit; font-size: 22px; line-height: 1; cursor: pointer; }
.wsp-cerrar:hover { background: var(--tint); }
.wsp-numero { display: block; padding: 12px 16px; border-radius: 5px 16px 5px 16px; background: var(--tint); color: var(--ink); font-size: 22px; font-weight: 700; text-align: center; text-decoration: none; font-variant-numeric: tabular-nums; }
.wsp-numero:hover { text-decoration: underline; text-underline-offset: 4px; }
.wsp-abrir { display: flex; align-items: center; justify-content: center; gap: 10px; background: #25d366; border-color: #25d366; color: #05240f; }
.wsp-abrir:hover { background: #1fbd5a; border-color: #1fbd5a; color: #05240f; }
/* El pie deja sitio para que el botón no tape sus últimos enlaces. */
@media (max-width: 1280px) { .site-footer { padding-bottom: 84px; } }
@media print { .wsp-boton, .wsp-ficha { display: none !important; } }

/* Enlaces que abren WhatsApp: el ícono avisa a dónde llevan */
.icono-wsp { flex: none; vertical-align: -3px; }
a.validity:has(.icono-wsp) { flex-wrap: nowrap; gap: 10px; }
a.validity .icono-wsp { color: #128c4b; }
.btn-chat { display: inline-flex; align-items: center; gap: 10px; }
