/* ========================================================= */
/* ACCESO CLIENTES Y CONTRASEÑA NUEVA · rediseño 2026         */
/* Hoja independiente, con los mismos colores que home.css.  */
/* ========================================================= */

:root {
    --green-dark: #18392b;
    --green: #2f6b4f;
    --green-light: #e9f2ec;
    --cream: #f6f5f0;
    --white: #ffffff;
    --text: #202722;
    --text-body: #4d5850;
    --text-muted: #5a655d;
    --border: #dfe5e0;
    --field: #cdd6cf;
    --error: #9b2c1f;
    --error-bg: #fdf1ef;
    --font-sans: "IBM Plex Sans", Arial, Helvetica, sans-serif;
    --font-mono: "IBM Plex Mono", ui-monospace, Menlo, Consolas, monospace;
}

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

body.acceso {
    min-height: 100vh;
    min-height: 100dvh;
    margin: 0;
    display: flex;
    flex-direction: column;
    background: var(--cream);
    color: var(--text);
    font-family: var(--font-sans);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

.acceso a {
    color: var(--green-dark);
}

.acceso a {
    text-decoration: none;
}

.acceso a:hover {
    color: var(--green);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.acceso-logo:hover,
.acceso-volver:hover {
    text-decoration: none !important;
}

.acceso a:focus-visible,
.acceso button:focus-visible,
.acceso input:focus-visible {
    outline: 3px solid var(--green);
    outline-offset: 2px;
}

/* Cabecera */

.acceso-cabecera {
    flex: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    height: 72px;
    padding: 0 40px;
    background: var(--white);
    border-bottom: 1px solid var(--border);
}

.acceso-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.acceso-logo picture {
    display: block;
}

.acceso-logo img {
    display: block;
    width: auto;
    height: 48px;
}

@media (max-width: 640px) {
    .acceso-logo img {
        height: 38px;
    }
}

.acceso-volver {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 44px;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
}

/* Tarjeta */

.acceso-principal {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 20px;
    padding: 32px 16px 88px;
}

.acceso-tarjeta {
    width: min(100%, 440px);
    display: flex;
    flex-direction: column;
    gap: 24px;
    padding: 40px;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 14px;
    box-shadow: 0 12px 32px rgba(24, 57, 43, 0.06);
}

.acceso-intro {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.acceso-etiqueta {
    align-self: flex-start;
    padding: 5px 11px;
    border-radius: 999px;
    background: var(--green-light);
    color: var(--green);
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.acceso h1 {
    margin: 0;
    color: var(--green-dark);
    font-size: 30px;
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.01em;
}

.acceso-intro p {
    margin: 0;
    color: var(--text-body);
    font-size: 15px;
    line-height: 1.55;
}

/* Formulario */

.acceso-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin: 0;
}

.acceso-form[hidden] {
    display: none;
}

.acceso-campo {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.acceso-campo-cabecera {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
}

.acceso label {
    font-size: 14px;
    font-weight: 600;
}

.acceso-enlace {
    font-size: 13.5px;
    font-weight: 500;
}

.acceso-enlace[aria-disabled="true"] {
    pointer-events: none;
    color: var(--text-muted);
}

.acceso input[type="email"],
.acceso input[type="password"],
.acceso input[type="text"] {
    width: 100%;
    height: 48px;
    padding: 0 14px;
    border: 1px solid var(--field);
    border-radius: 8px;
    background: var(--white);
    color: var(--text);
    font: inherit;
    font-size: 15px;
}

.acceso input::placeholder {
    color: #8a948c;
}

.acceso input:hover {
    border-color: #aebbb1;
}

.acceso-clave {
    position: relative;
    display: flex;
}

.acceso-clave input {
    padding-right: 52px !important;
}

.acceso-ojo {
    position: absolute;
    top: 2px;
    right: 2px;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: var(--text-muted);
    cursor: pointer;
}

.acceso-ojo:hover {
    color: var(--green-dark);
}

.acceso-ojo .ojo-cerrado,
.acceso-ojo[aria-pressed="true"] .ojo-abierto {
    display: none;
}

.acceso-ojo[aria-pressed="true"] .ojo-cerrado {
    display: block;
}

.acceso-boton {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 52px;
    margin-top: 4px;
    border: 0;
    border-radius: 8px;
    background: var(--green-dark);
    color: var(--white);
    font: inherit;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.15s;
}

.acceso-boton:hover {
    background: var(--green);
}

.acceso-boton:disabled {
    background: var(--green);
    cursor: progress;
}

/* Avisos */

.acceso-aviso:empty {
    display: none;
}

.acceso-aviso {
    margin: 0;
    padding: 12px 14px;
    border-radius: 8px;
    background: var(--green-light);
    color: var(--green-dark);
    font-size: 14px;
    line-height: 1.45;
}

.acceso-aviso[data-tipo="error"] {
    background: var(--error-bg);
    color: var(--error);
}

.acceso-ayuda {
    margin: 0;
    color: var(--text-body);
    font-size: 14px;
    text-align: center;
}

.acceso-ayuda a {
    font-weight: 600;
}

/* Selector de idioma (lo añade /i18n/runtime.js) */

.acceso .inadesa-language-floating {
    right: 24px;
    bottom: 24px;
    gap: 8px;
    padding: 0 12px;
    height: 40px;
    margin: 0;
    border-color: var(--border);
    border-radius: 8px;
    background: var(--white);
    box-shadow: none;
    color: var(--text);
    font-family: var(--font-sans);
}

.acceso .inadesa-language select {
    color: var(--text) !important;
    font-family: var(--font-sans) !important;
}

/* Móvil */

@media (max-width: 560px) {
    .acceso-cabecera {
        height: 60px;
        padding: 0 16px;
    }

    .acceso-principal {
        justify-content: flex-start;
        padding: 24px 16px 88px;
    }

    .acceso-tarjeta {
        gap: 22px;
        padding: 28px 22px;
    }

    .acceso h1 {
        font-size: 28px;
    }

    .acceso input[type="email"],
    .acceso input[type="password"],
    .acceso input[type="text"] {
        height: 50px;
        font-size: 16px;
    }

    .acceso-ojo {
        top: 3px;
        right: 3px;
    }

    .acceso .inadesa-language-floating {
        right: 50%;
        bottom: 16px;
        transform: translateX(50%);
    }
}

@media (prefers-reduced-motion: reduce) {
    .acceso-boton {
        transition: none;
    }
}
