

:root {
    --thermo-1: #2c5fd6;
    --thermo-2: #28bce0;
    --thermo-3: #b9e35a;
    --thermo-4: #fca130;
    --thermo-5: #d7261e;
    --ease-out-fuerte: cubic-bezier(0.23, 1, 0.32, 1);
}

body.acceso {
    display: block;
    height: auto;
    min-height: 100vh;
    min-height: 100dvh;
    overflow: auto;
    background: var(--background);
}

.acceso-grid {
    display: grid;
    grid-template-columns: minmax(400px, 36%) 1fr;
    min-height: 100vh;
    min-height: 100dvh;
}


.acceso-panel {
    position: relative;
    isolation: isolate;
    display: flex;
    flex-direction: column;
    padding: var(--sp-07) var(--sp-09);
    background: var(--background);
    caret-color: var(--interactive);
}


.acceso-panel::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background:
        radial-gradient(ellipse 70% 42% at 100% 36%, rgb(252 161 48 / 0.17), rgb(252 161 48 / 0) 72%),
        radial-gradient(ellipse 45% 30% at 100% 36%, rgb(215 38 30 / 0.06), rgb(215 38 30 / 0) 70%);
}


.acceso-panel::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background-image:
        linear-gradient(rgb(22 22 22 / 0.06) 1px, transparent 1px),
        linear-gradient(90deg, rgb(22 22 22 / 0.06) 1px, transparent 1px);
    background-size: 48px 48px;
    background-position: right -1px top -1px;
    -webkit-mask-image: radial-gradient(ellipse 62% 40% at 100% 36%, #000 0%, rgb(0 0 0 / 0.5) 45%, transparent 78%);
    mask-image: radial-gradient(ellipse 62% 40% at 100% 36%, #000 0%, rgb(0 0 0 / 0.5) 45%, transparent 78%);
}


@media (prefers-reduced-motion: no-preference) {
    
    .acceso-panel::before {
        animation: amanecer 1400ms var(--ease-out-fuerte) 200ms both,
                   respirar 9s ease-in-out 1.8s infinite alternate;
    }

    .acceso-panel::after {
        animation: amanecer 1800ms var(--ease-out-fuerte) 420ms both;
    }

    .acceso-centro > * {
        animation: llegar 520ms var(--ease-out-fuerte) both;
        animation-delay: calc(var(--i, 0) * 55ms + 80ms);
    }

    .acceso-centro > :nth-child(1) { --i: 0; }
    .acceso-centro > :nth-child(2) { --i: 1; }
    .acceso-centro > :nth-child(3) { --i: 2; }
    .acceso-centro > :nth-child(4) { --i: 3; }
    .acceso-centro > :nth-child(5) { --i: 4; }

    .acceso-form::before {
        animation: horizonte 900ms var(--ease-out-fuerte) 260ms both;
    }

    .acceso-enviar i {
        transition: transform var(--duration-moderate) var(--ease-out-fuerte);
    }
}

@media (prefers-reduced-motion: no-preference) and (hover: hover) and (pointer: fine) {
    .acceso-enviar:hover:not(:disabled) i {
        transform: translateX(4px);
    }
}


.sin-animacion .acceso-panel::before,
.sin-animacion .acceso-panel::after,
.sin-animacion .acceso-centro > *,
.sin-animacion .acceso-form::before {
    animation: none;
}

@keyframes amanecer {
    from { opacity: 0; transform: translateX(6%); }
}

@keyframes respirar {
    to { opacity: 0.72; transform: translateY(-1.5%); }
}

@keyframes llegar {
    from { opacity: 0; transform: translateY(8px); filter: blur(3px); }
}

@keyframes horizonte {
    from { clip-path: inset(0 100% 0 0); }
}

.acceso-marca {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 16px;
    letter-spacing: 0.1px;
    color: var(--text-primary);
}

.acceso-marca .marca-icono {
    display: block;
    height: 28px;
    width: auto;
    flex-shrink: 0;
}

.acceso-marca strong {
    font-weight: 600;
}

.acceso-centro {
    width: 100%;
    max-width: 400px;
    margin: auto 0;
    padding: var(--sp-09) 0;
}

.acceso-titulo {
    font-size: 32px;
    line-height: 1.25;
    font-weight: 400;
    letter-spacing: 0;
    color: var(--text-primary);
}

.acceso-lead {
    margin-top: var(--sp-03);
    color: var(--text-secondary);
    max-width: 44ch;
}

.acceso-centro .notice {
    margin-top: var(--sp-06);
    font-size: 14px;
    line-height: 1.43;
    letter-spacing: 0.16px;
}

.acceso-form {
    position: relative;
    margin-top: var(--sp-07);
    padding-top: var(--sp-06);
    border-top: 1px solid var(--border-subtle);
}


.acceso-form::before {
    content: "";
    position: absolute;
    top: -1px;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, var(--interactive) 0%, var(--thermo-4) 62%, rgb(252 161 48 / 0) 100%);
}

.campo {
    margin-bottom: var(--sp-06);
}

.campo .input {
    height: 48px;
}


.entrada {
    position: relative;
}

.entrada::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--interactive) 0%, var(--interactive) 30%, var(--thermo-4) 78%, var(--thermo-5) 100%);
    transform: scaleX(0);
    transform-origin: left center;
    pointer-events: none;
    transition: transform var(--duration-slow) var(--ease-out-fuerte);
}

.entrada:focus-within::after {
    transform: scaleX(1);
    transition-duration: 480ms;
}

.entrada .input {
    transition: background-color var(--duration-moderate) var(--ease-standard),
                box-shadow var(--duration-slow) var(--ease-out-fuerte);
}

.entrada .input:focus {
    outline-color: transparent;
    background-color: var(--background);
    box-shadow: inset 0 0 0 1px var(--interactive), 0 8px 20px -10px rgb(15 98 254 / 0.45);
}

.campo .field-label {
    transition: color var(--duration-moderate) var(--ease-standard);
}

.campo:focus-within .field-label {
    color: var(--interactive);
}


.entrada .input:-webkit-autofill {
    -webkit-box-shadow: inset 0 0 0 1000px var(--field);
    -webkit-text-fill-color: var(--text-primary);
}

.entrada .input:-webkit-autofill:focus {
    -webkit-box-shadow: inset 0 0 0 1000px var(--background), inset 0 0 0 1px var(--interactive);
}


.campo.invalido .entrada .input:focus {
    box-shadow: inset 0 0 0 2px var(--support-error);
}

.campo.invalido .entrada::after {
    background: var(--support-error);
    transform: scaleX(1);
}

.campo.invalido .field-label {
    color: var(--support-error);
}

.campo-ayuda:empty {
    display: none;
}

.campo-ayuda {
    margin-top: var(--sp-02);
}

.campo.invalido .input {
    outline-color: var(--support-error);
}

.campo.invalido .campo-ayuda {
    color: var(--support-error);
}

.campo-ayuda.mayus {
    color: #8e6a00;
}


.clave {
    position: relative;
}

.clave .input {
    padding-right: var(--sp-09);
}

.clave-ver {
    position: absolute;
    inset: 0 0 0 auto;
    width: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    transition: color var(--duration-fast) var(--ease-standard);
}

.clave-ver:hover {
    color: var(--text-primary);
}

.clave-ver i {
    font-size: 16px;
}


.casilla {
    display: flex;
    align-items: flex-start;
    gap: var(--sp-03);
    font-size: 14px;
    color: var(--text-primary);
    cursor: pointer;
    user-select: none;
}

.casilla input {
    width: 16px;
    height: 16px;
    margin-top: 2px;
    flex-shrink: 0;
    accent-color: var(--text-primary);
    cursor: pointer;
}

.turnstile-bloque {
    margin-top: var(--sp-05);
    margin-bottom: var(--sp-02);
    min-height: 65px;
    display: flex;
    justify-content: flex-start;
}

.acceso-enviar {
    position: relative;
    overflow: hidden;
    isolation: isolate;
    width: 100%;
    margin-top: var(--sp-07);
    min-height: 64px;
    align-items: flex-start;
    padding-top: var(--sp-05);
}


.acceso-enviar::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background: linear-gradient(105deg, rgb(255 255 255 / 0) 28%, rgb(255 255 255 / 0.3) 46%, rgb(255 236 210 / 0.16) 53%, rgb(255 255 255 / 0) 68%);
    transform: translateX(-110%);
}

@media (prefers-reduced-motion: no-preference) and (hover: hover) and (pointer: fine) {
    .acceso-enviar:hover:not(:disabled)::after {
        transform: translateX(110%);
        transition: transform 900ms cubic-bezier(0.65, 0, 0.35, 1);
    }
}


@media (prefers-reduced-motion: no-preference) {
    .acceso-enviar[aria-busy="true"]::after {
        animation: destello 1100ms var(--ease-standard) infinite;
    }
}

@keyframes destello {
    from { transform: translateX(-110%); }
    to { transform: translateX(110%); }
}

.acceso-enviar[aria-busy="true"],
.acceso-enviar[aria-busy="true"]:disabled {
    background: var(--button-primary-active);
    color: var(--text-on-color);
    cursor: progress;
}

@media (prefers-reduced-motion: no-preference) {
    .acceso-enviar[aria-busy="true"] i {
        animation: empujar 600ms var(--ease-standard) infinite alternate;
    }
}

@keyframes empujar {
    to { transform: translateX(4px); }
}

.acceso-nota,
.acceso-alterna {
    margin-top: var(--sp-06);
    font-size: 14px;
    color: var(--text-secondary);
}

.acceso-pie {
    font-size: 12px;
    letter-spacing: 0.32px;
    color: var(--text-helper);
}


.requisitos {
    list-style: none;
    margin: calc(-1 * var(--sp-04)) 0 var(--sp-06);
    display: grid;
    gap: var(--sp-02);
    font-size: 12px;
    letter-spacing: 0.32px;
    color: var(--text-secondary);
}

.requisitos li {
    display: flex;
    align-items: center;
    gap: var(--sp-03);
}

.requisitos i {
    width: 14px;
    font-size: 12px;
    color: var(--text-helper);
}

.requisitos li.cumple {
    color: var(--text-primary);
}

.requisitos li.cumple i {
    color: var(--support-success);
}



.acceso-lateral {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    background-color: var(--shell-bg);
    color: var(--shell-text);
    padding: var(--sp-09) var(--sp-09) var(--sp-07);
    min-height: 0;
}


.acceso-lateral::before,
.acceso-lateral::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    pointer-events: none;
}

.acceso-lateral::before {
    background-image: url("fondo-tierra.jpg");
    background-image: image-set(url("fondo-tierra.webp") type("image/webp"), url("fondo-tierra.jpg") type("image/jpeg"));
    background-size: cover;
    background-position: center top;
    background-repeat: no-repeat;
    transform-origin: 50% 36%;
}

.acceso-lateral::after {
    background: linear-gradient(180deg, rgb(22 22 22 / 0.15) 0%, rgb(22 22 22 / 0.35) 55%, rgb(22 22 22 / 0.88) 100%);
}

@media (prefers-reduced-motion: no-preference) {
    .acceso-lateral::before {
        animation: orbita 40s ease-in-out infinite alternate;
    }
}

@keyframes orbita {
    from { transform: scale(1.02); }
    to { transform: scale(1.09) translate(-1.2%, 0.8%); }
}

.acceso-figura {
    position: sticky;
    top: var(--sp-09);
    height: calc(100dvh - var(--sp-09) - var(--sp-07));
    display: grid;
    grid-template-rows: 1fr auto;
    gap: var(--sp-07);
}

.acceso-mapa {
    min-height: 0;
    display: flex;
    justify-content: center;
}

.mapa-chile {
    width: 100%;
    height: 100%;
}

.mapa-chile path {
    stroke: var(--shell-bg);
    stroke-width: 0.6px;
    stroke-linejoin: round;
    vector-effect: non-scaling-stroke;
}

.q0 { fill: #525252; background: #525252; }
.q1 { fill: var(--thermo-1); background: var(--thermo-1); }
.q2 { fill: var(--thermo-2); background: var(--thermo-2); }
.q3 { fill: var(--thermo-3); background: var(--thermo-3); }
.q4 { fill: var(--thermo-4); background: var(--thermo-4); }
.q5 { fill: var(--thermo-5); background: var(--thermo-5); }


@media (prefers-reduced-motion: no-preference) {
    .mapa-chile path {
        animation: pintar 520ms var(--ease-out-fuerte) both;
        animation-delay: calc(var(--t) * 160ms + var(--d) * 900ms);
    }
}


.sin-animacion .mapa-chile path {
    animation: none;
}

@keyframes pintar {
    from { opacity: 0; }
}

.acceso-leyenda {
    max-width: 640px;
}

.ley-titulo {
    font-size: 14px;
    font-weight: 600;
    color: var(--shell-text-strong);
}

.ley-escala {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: var(--sp-03) var(--sp-06);
    margin-top: var(--sp-04);
    font-size: 12px;
    letter-spacing: 0.32px;
}

.ley-escala li {
    display: flex;
    align-items: center;
    gap: var(--sp-03);
    white-space: nowrap;
}

.ley-muestra {
    width: 12px;
    height: 12px;
}

.ley-fuente {
    margin-top: var(--sp-04);
    font-size: 12px;
    line-height: 1.33;
    letter-spacing: 0.32px;
    color: #a8a8a8;
    max-width: 72ch;
}


@media (max-width: 960px) {
    .acceso-grid {
        grid-template-columns: 1fr;
    }

    .acceso-panel {
        padding: var(--sp-06) var(--sp-05);
        min-height: 100dvh;
    }

    .acceso-centro {
        max-width: none;
    }

    .acceso-lateral {
        padding: var(--sp-07) var(--sp-05);
    }

    
    .acceso-panel::before {
        background:
            radial-gradient(ellipse 90% 28% at 50% 100%, rgb(252 161 48 / 0.17), rgb(252 161 48 / 0) 72%),
            radial-gradient(ellipse 60% 18% at 50% 100%, rgb(215 38 30 / 0.06), rgb(215 38 30 / 0) 70%);
    }

    .acceso-panel::after {
        background-position: center bottom;
        -webkit-mask-image: radial-gradient(ellipse 90% 26% at 50% 100%, #000 0%, rgb(0 0 0 / 0.5) 45%, transparent 78%);
        mask-image: radial-gradient(ellipse 90% 26% at 50% 100%, #000 0%, rgb(0 0 0 / 0.5) 45%, transparent 78%);
    }

    .acceso-figura {
        position: static;
        height: auto;
    }

    .acceso-mapa {
        height: min(110vw, 640px);
    }
}



.suscripcion-paso {
    margin-bottom: var(--sp-04);
    font-size: 12px;
    letter-spacing: 0.32px;
    color: var(--text-secondary);
}

.suscripcion-precio {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: var(--sp-03);
    margin-top: var(--sp-06);
    color: var(--text-secondary);
    font-size: 14px;
}

.suscripcion-precio .cifra {
    font-size: 32px;
    line-height: 1.25;
    color: var(--text-primary);
    font-variant-numeric: tabular-nums;
}

.suscripcion-subtitulo {
    margin-top: var(--sp-07);
    font-size: 14px;
    font-weight: 600;
    line-height: 1.29;
    letter-spacing: 0.16px;
    color: var(--text-primary);
}

.suscripcion-lista {
    list-style: none;
    margin-top: var(--sp-04);
    display: grid;
    gap: var(--sp-04);
    font-size: 14px;
    line-height: 1.43;
    letter-spacing: 0.16px;
    color: var(--text-primary);
}

.suscripcion-lista li {
    display: grid;
    grid-template-columns: 16px 1fr;
    gap: var(--sp-03);
}

.suscripcion-lista i {
    margin-top: 3px;
    font-size: 12px;
    color: var(--interactive);
}

.suscripcion-condiciones {
    margin-top: var(--sp-03);
    padding-left: var(--sp-05);
    display: grid;
    gap: var(--sp-02);
    font-size: 14px;
    line-height: 1.43;
    letter-spacing: 0.16px;
    color: var(--text-secondary);
}

.campo .opcional {
    color: var(--text-helper);
}


.suscripcion-resumen {
    margin-top: var(--sp-07);
    border-top: 1px solid var(--border-subtle);
}

.suscripcion-resumen div {
    display: flex;
    justify-content: space-between;
    gap: var(--sp-05);
    padding: var(--sp-04) 0;
    border-bottom: 1px solid var(--border-subtle);
    font-size: 14px;
    letter-spacing: 0.16px;
}

.suscripcion-resumen dt {
    color: var(--text-secondary);
}

.suscripcion-resumen dd {
    color: var(--text-primary);
    text-align: right;
    overflow-wrap: anywhere;
}

.suscripcion-resumen .suscripcion-total dt,
.suscripcion-resumen .suscripcion-total dd {
    color: var(--text-primary);
    font-weight: 600;
}

.suscripcion-resumen .suscripcion-total dd {
    font-size: 20px;
    font-weight: 400;
    font-variant-numeric: tabular-nums;
}

a.acceso-enviar {
    display: flex;
    justify-content: space-between;
    text-decoration: none;
}


.codigo-correo {
    color: var(--text-primary);
    font-weight: 500;
    overflow-wrap: anywhere;
}


.input.codigo-entrada {
    height: 56px;
    font-family: var(--font-mono);
    font-size: 28px;
    letter-spacing: 0.4em;
    font-variant-numeric: tabular-nums;
    text-align: center;
    padding-left: 0.4em; 
}

.input.codigo-entrada::placeholder {
    letter-spacing: 0.4em;
}

.codigo-acciones {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: var(--sp-03) var(--sp-06);
    margin-top: var(--sp-06);
}

.codigo-enlace {
    appearance: none;
    background: none;
    border: 0;
    padding: var(--sp-02) 0;
    font: inherit;
    font-size: 14px;
    color: var(--link-primary, var(--interactive));
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 3px;
    -webkit-tap-highlight-color: transparent;
}

@media (hover: hover) and (pointer: fine) {
    .codigo-enlace:hover {
        color: var(--text-primary);
    }
}

.codigo-enlace:focus-visible {
    outline: 2px solid var(--focus);
    outline-offset: 2px;
}
