:root {
    --navy: #0b1526;
    --navy-soft: #1c2c46;
    --cream: #f5e8df;
    --card: #fdf9f5;
    --accent: #e8391f;
    --text: #1a1a1a;
    --text-soft: #55524d;
}

/* Tipografía única del proyecto: Barlow Condensed, en 3 pesos:
   300 Light (texto de cuerpo), 500 Medium (etiquetas/nav/subtítulos)
   y 600 SemiBold (titulares y énfasis). Se importa en _Layout.cshtml. */

html, body {
    width: 100%;
    height: 100%;
}

body {
    margin: 0;
    font-family: 'Barlow Condensed', Arial, sans-serif;
    font-weight: 300;
    font-size: 21px;
    line-height: 1.6;
    color: var(--text);
    background: var(--cream);
}

h1, h2, h3 {
    font-family: 'Barlow Condensed', Arial, sans-serif;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    margin: 0;
}

strong, b {
    font-weight: 600;
}

a {
    color: var(--accent);
}

/* ---------- Header ---------- */
.site-header {
    background: var(--navy);
}

.header-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 30px;
    flex-wrap: wrap;
    gap: 12px;
}

.brand img {
    height: 50px;
    display: block;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 25px;
    font-size: 18px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.main-nav a {
    color: #ffffff;
    text-decoration: none;
}

.main-nav a:hover {
    color: var(--accent);
}

.main-nav .sep {
    color: rgba(255, 255, 255, 0.35);
}

/* Botón hamburguesa: oculto en escritorio, solo visible en móvil (ver media
   query más abajo). Las 3 líneas se transforman en una "X" con .is-open. */
.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 6px;
    width: 40px;
    height: 40px;
    padding: 0;
    margin: 0;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 20;
}
.mt20 {
    margin-top: 20px !important;
}
.pt60 {
    padding-top: 60px !important;
}
.menu-toggle span {
    display: block;
    width: 26px;
    height: 3px;
    border-radius: 2px;
    background: #ffffff;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.menu-toggle.is-open span:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}

.menu-toggle.is-open span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.is-open span:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

/* En la home el header se integra visualmente en el hero: se saca del flujo
   normal y se superpone, sin fondo propio, sobre el canvas del hero. */
body.has-hero .site-header,
body.has-test-hero .site-header,
body.has-photo-hero .site-header {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 10;
    background: transparent;
}

/* ---------- Hero ---------- */
.hero {
    position: relative;
    overflow: hidden;
    box-sizing: border-box;
    /* Color de respaldo mientras carga el canvas (o si JS está desactivado). */
    background: var(--navy);
    min-height: 650px;
    /* padding-top deja hueco para el header, que ahora se superpone encima. */
    padding: 140px 30px 70px;
    display: flex;
    align-items: center;
}

.plexus-canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
    z-index: 0;
}

.hero-inner {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
}

.hero h1 {
    color: #ffffff;
    font-size: 5.1rem;
    max-width: 1100px;
   /* margin-bottom: 26px;*/
}

.hero p {
    color: #d9dee6;
    font-weight: 300;
    font-size: 2.2rem;
    max-width: 760px;
    margin: 0;
}

/* ---------- Hero con foto genérico (Filosofía / Biblioteca) ---------- */
.photo-hero {
    position: relative;
    overflow: hidden;
    box-sizing: border-box;
    background: var(--navy) center / cover no-repeat;
    min-height: 430px;
    padding: 140px 30px 40px;
    display: flex;
    align-items: flex-end;
}

.photo-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(11, 21, 38, 0.15) 0%, rgba(11, 21, 38, 0.85) 100%);
    z-index: 0;
}

.photo-hero-inner {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

.photo-hero h1 {
    color: #ffffff;
    font-size: 5.1rem;
    /*margin-bottom: 10px;*/
}

.photo-hero-subtitle {
    color: #f2e9e2;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    font-size: 2rem;
    margin: 0;
}

.filosofia-hero {
    background-image: url(../images/fondoFilosofia.jpg);
}

.biblioteca-hero {
    background-image: url(../images/fondoBiblioteca.jpg);
}

/* ---------- Acceso miembros: hero con formulario de login ---------- */
.access-hero {
    min-height: 100vh;
    background-image: url(../images/fondoAcceso.jpg);
    background-size: cover;
    background-position: center;
}

.access-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(11, 21, 38, 0.55);
    z-index: 0;
}

body.page-acceso {
    height: 100vh;
    overflow: hidden;
    position: relative;
}

body.page-acceso .site-footer {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
}

.hero .photo-hero-subtitle {
    color: #f2e9e2;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    font-size: 2rem;
    margin: 0;
    max-width: none;
}

.access-login-form {
    display: flex;
    align-items: flex-end;
    gap: 14px;
    flex-wrap: wrap;
    margin-top: 40px;
}

.access-field--login {
    width: 230px;
}

.access-login-form .access-submit-btn {
    background: var(--accent);
    color: #ffffff;
    border: none;
    border-radius: 6px;
    padding: 22px 30px;
    height: 70px;
    box-sizing: border-box;
    font-family: 'Barlow Condensed', Arial, sans-serif;
    font-weight: 600;
    font-size: 1.6rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    cursor: pointer;
}

.access-login-form .access-submit-btn:hover {
    background: #c92c14;
}

.mb20 {
    margin-bottom: 20px !important;
}
/* ---------- Intro / pillars ---------- */
.intro {
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 30px 40px;
}

.intro-quote {
    margin: 0 0 50px;
    position: relative;
    padding-left: 22px;
    font-size: 2.9rem;
    font-weight: 300;
    font-style: normal;
    max-width: 1100px;
    color: #000000;
    line-height: 3.5rem;
}
    .intro-quote::before {
        content: "";
        position: absolute;
        left: 0;
        top: 0.1em;
        bottom: 0.1em;
        width: 5px;
        background: var(--accent);
        border-radius: 10px;
    }

.pillars {
    display: flex;
    justify-content: center;
    gap: 90px;
    flex-wrap: wrap;
    text-align: center;
}
.pillar {
    min-width: 175px;
    display: block;
    color: inherit;
    text-decoration: none;
}

.pillar:hover {
    color: inherit;
    text-decoration: none;
}

.pillar img {
    height: 65px;
    margin-bottom: 14px;
}

.pillar h3 {
    font-size: 3rem;
    font-weight: 600;
    text-transform: none;
    margin-bottom: -5px;
}

.pillar p {
    /* display: inline-block; */
    font-size: 2rem;
    font-weight: 300;
    color: var(--text-soft);
    margin: 0;
    position: relative;
    padding-bottom: 4px;
}
    .pillar p:after {
        content: "";
        width: 36px;
        height: 4px;
        background: var(--accent);
        position: absolute;
        bottom: -5px;
        left: 0;
        right: 0;
        margin: auto;
        border-radius: 10px;
    }
/* ---------- Section titles ---------- */
.headerGroup {
    position: relative;
    margin-bottom:20px;
}

    .headerGroup:before {
        content: "";
        position: absolute;
        left: 0;
        top: 0.1em;
        bottom: 0.1em;
        width: 5px;
        background: var(--accent);
        border-radius: 10px;
    }
.section-title {
    position: relative;
    padding-left: 18px;
    font-size: 3.8rem;
    margin-bottom: -5px;
}

    .section-title::before {
        content: "";
        position: absolute;
        left: 0;
        top: 0.1em;
        bottom: 0.1em;
        width: 5px;
        background: var(--accent);
        border-radius: 10px;
    }

.section-subtitle {
    padding-left: 18px;
    margin: 0 0 0px;
    font-size: 2.3rem;
    font-weight: 500;
    /* letter-spacing: 0.03em; */
    text-transform: uppercase;
    color: #000000;
}
.underline-heading {
    display: inline-block;
    text-transform: none;
    letter-spacing: normal;
    font-weight: 600;
    font-size: 2.5rem;
    /* border-bottom: 2px solid var(--accent); */
    padding-bottom: 6px;
    margin-bottom: 14px;
    position: relative;
}
    .underline-heading:after {
        content: "";
        width: 45px;
        height: 4px;
        background: var(--accent);
        position: absolute;
        bottom: -5px;
        left: 0;
        border-radius: 10px;
    }
.origin-col {
    display: flex;
    flex-direction: column;
}
/* ---------- Cards ---------- */
.card {
    background: var(--card);
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(11, 21, 38, 0.06);
    overflow: hidden;
    border: 5px solid white;
    flex: 1;
}

.card-photo {
    width: 100%;
    height: 285px;
    display: block;
    object-fit: cover;
    object-position: bottom;
}

.card-body {
    padding: 26px 28px 30px;
}

    .card-body h3 {
        font-size: 2.2rem;
        font-weight: 600;
        text-transform: none;
        margin: 0 0 10px;
    }

    .card-body p {
        font-size: 2rem;
        margin: 0 0 16px;
        color: var(--text-soft);
    }

.card-body p:last-child {
    margin-bottom: 0;
}

/* ---------- Grid de comparativa (3 columnas) ---------- */
.comparativos {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 30px 60px;
}

.comparativos-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.comparativos-grid .card-photo {
    height: 190px;
}

.comparativos-grid .card-body p {
    font-size: 1.8rem;
}

/* ---------- Origin / confidentiality two-column ---------- */
.origin-grid {
    max-width: 1200px;
    margin: 0 auto;
    padding: 30px 30px 60px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

/* ---------- Estudio actual ---------- */
.estudio {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 30px 20px;
}

.estudio-card {
    display: flex;
    align-items: stretch;
}

.estudio-photo {
    width: 320px;
    flex: 0 0 320px;
    object-fit: cover;
}

.estudio-body {
    padding: 30px 34px;
    flex: 1;
}

.estudio-body p {
    font-size: 2rem;
    color: var(--text-soft);
    margin: 0 0 20px;
}

.token-note {
    position: relative;
    border-top: 1px solid var(--accent);
    border-bottom: 1px solid var(--accent);
    padding: 16px 34px;
    margin: 0 0 22px;
    text-align: center;
    font-size: 1.55rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: var(--text);
}

.token-note::before,
.token-note::after {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-family: Georgia, serif;
    font-size: 1.6rem;
    color: var(--text);
}

.token-note::before {
    content: "[";
    left: 6px;
}

.token-note::after {
    content: "]";
    right: 6px;
}

.token-form {
    display: flex;
    gap: 14px;
    margin: 0 0 22px;
    flex-wrap: wrap;
}

.token-form input {
    flex: 1;
    min-width: 180px;
    max-width: 320px;
    padding: 13px 18px;
    border: 1px solid #e6b6ac;
    border-radius: 6px;
    background: var(--cream);
    font-family: 'Barlow Condensed', Arial, sans-serif;
    font-size: 1.8rem;
}

.token-form button {
    background: var(--accent);
    color: #ffffff;
    border: none;
    border-radius: 6px;
    padding: 13px 26px;
    font-family: 'Barlow Condensed', Arial, sans-serif;
    font-weight: 600;
    font-size: 1.55rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    cursor: pointer;
}

.token-form button:hover {
    background: #c92c14;
}

.fine-print {
    font-size: 1.6rem;
    color: var(--text-soft);
    margin: 0;
}

.fine-print a {
    font-weight: 600;
    text-decoration: underline;
}

/* ---------- Press ("Se habla de...") ---------- */
.press {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 30px 20px;
}

.press-card {
    background: var(--card);
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(11, 21, 38, 0.06);
    padding: 26px 30px;
    margin-bottom: 22px;
}
    .press-card:last-child {
        margin-bottom: 0px;
    }
.press-card p {
    font-size: 2rem;
    color: var(--text-soft);
    margin: 0 0 14px;
}

.press-card p:last-child {
    margin-bottom: 0;
}

.press-card a {
    font-weight: 600;
    text-decoration: underline;
}

/* ---------- Último informe (home) ---------- */
.informe {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 30px 20px;
}

.informe-card {
    border: 5px solid white;
}

.informe-body {
    padding: 34px 40px 38px;
}

.informe-kicker {
    display: block;
    font-size: 1.5rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 10px;
}

.informe-body p {
    font-size: 2rem;
    color: var(--text-soft);
    margin: 0 0 22px;
}

.informe-stat {
    border-top: 1px solid var(--accent);
    border-bottom: 1px solid var(--accent);
    padding: 16px 34px;
    margin: 0 0 22px;
    text-align: center;
    font-size: 1.8rem;
    color: var(--text);
}

.informe-stat strong {
    color: var(--accent);
}

.informe-btn {
    display: inline-block;
    background: var(--accent);
    color: #ffffff;
    border: none;
    border-radius: 6px;
    padding: 13px 30px;
    font-family: 'Barlow Condensed', Arial, sans-serif;
    font-weight: 600;
    font-size: 1.55rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    text-decoration: none;
}

.informe-btn:hover {
    background: #c92c14;
}

/* ---------- Biblioteca: referencias con viñeta ---------- */
.biblio-list {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 30px 20px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.biblio-list.pb70 {
    padding-bottom: 70px;
}

.biblio-item {
    display: flex;
    align-items: flex-start;
    gap: 18px;
    background: var(--card);
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(11, 21, 38, 0.06);
    padding: 24px 30px;
}

.biblio-item .dot {
    flex: none;
    width: 14px;
    height: 14px;
    margin-top: 9px;
    border-radius: 50%;
    background: var(--accent);
}

.biblio-item--locked .dot {
    background: #000000;
}

.biblio-item p {
    font-size: 2rem;
    color: var(--text-soft);
    margin: 0;
}

/* Lista de viñetas compacta, para usar dentro de una tarjeta (ej. estudio-body) */
.dot-list {
    list-style: none;
    margin: 14px 0 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.dot-list li {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.6rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--text);
}

.dot-list li .dot {
    width: 12px;
    height: 12px;
    flex: none;
    border-radius: 50%;
    background: var(--accent);
}

.dot-list li.locked .dot {
    background: #000000;
}

/* ---------- Legal ---------- */
.legal-page {
    max-width: 900px;
    margin: 0 auto;
    padding: 60px 30px 90px;
}

.legal-inner p {
    font-size: 1.8rem;
    color: var(--text-soft);
}

.legal-inner .press {
    max-width: none;
    padding: 0;
    margin-top: 10px;
}

.legal-inner .press-card p {
    font-size: 1.8rem;
}

/* ---------- Footer ---------- */
.site-footer {
    background: var(--navy);
}

.footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    column-gap: 12px;
    padding: 26px 30px;
}

.footer-brand {
    justify-self: start;
    display: inline-flex;
}

.footer-logo {
    height: 24px;
    display: block;
}

.footer-copy {
    grid-column: 2;
    justify-self: center;
    text-align: center;
    margin: 0;
    font-size: 1.15rem;
    font-weight: 300;
    color: #b9c0cb;
    white-space: nowrap;
}

.footer-copy a {
    color: #b9c0cb;
}

.footer-copy a:hover {
    color: var(--accent);
}

/* ---------- Modal: solicitud de acceso ---------- */
.modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(11, 21, 38, 0.75);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-overlay.is-open {
    display: flex;
}

.access-modal {
    position: relative;
    background: var(--card);
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
    max-width: 850px;
    width: 100%;
    padding: 40px 40px 34px;
    box-sizing: border-box;
}

.modal-close {
    position: absolute;
    top: 10px;
    right: 16px;
    background: none;
    border: none;
    font-size: 2.6rem;
    line-height: 1;
    color: var(--text-soft);
    cursor: pointer;
    padding: 4px;
}

.modal-close:hover {
    color: var(--accent);
}

.access-modal .underline-heading {
    font-size: 2.5rem;
    margin-bottom: 20px;
}

.access-modal-text {
    font-size: 2rem;
    color: var(--text-soft);
    margin: 0 0 26px;
}

.access-form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 11px 11px;
}

.access-field {
    background: var(--navy);
    border: 2.5px solid var(--accent);
    border-radius: 6px;
    padding: 5px 15px 5px;
    height: 70px;
}

    .access-field label {
        display: block;
        font-size: 1.5rem;
        font-weight: 500;
        letter-spacing: 0.05em;
        text-transform: uppercase;
        color: rgba(255, 255, 255, 0.75);
        margin-bottom: 0px;
    }

.access-field input {
    width: 100%;
    box-sizing: border-box;
    border: none;
    background: transparent;
    color: #ffffff;
    font-family: 'Barlow Condensed', Arial, sans-serif;
    font-size: 1.7rem;
    padding: 0;
    outline: none;
}

.access-field input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

/* El <select> del género se pinta como los <input> del formulario: caja transparente dentro del
   recuadro de .access-field, sin borde propio. La flecha nativa se quita para que no rompa la
   estetica, y las <option> llevan fondo explicito porque el desplegable lo pinta el sistema y, sin
   el, saldria texto blanco sobre blanco. */
.access-field select {
    width: 100%;
    box-sizing: border-box;
    border: none;
    background: transparent;
    color: #ffffff;
    font-family: 'Barlow Condensed', Arial, sans-serif;
    font-size: 1.7rem;
    padding: 0;
    outline: none;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
}

.access-field select option {
    background: var(--navy);
    color: #ffffff;
}

.access-check {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    color: var(--text);
}

    .access-check input[type="checkbox"] {
        width: 20px;
        height: 20px;
        flex: none;
        accent-color: var(--accent);
        margin: 0;
    }

    .access-check label {
        font-weight: 500;
        margin: 0;
        font-size: 1.5rem;
    }

.access-check a {
    text-decoration: underline;
    font-weight: 600;
}

.access-submit {
    grid-column: 1 / -1;
    display: flex;
    justify-content: flex-end;
    margin-top: 6px;
}

.access-submit button {
    background: var(--accent);
    color: #ffffff;
    border: none;
    border-radius: 6px;
    padding: 14px 30px;
    font-family: 'Barlow Condensed', Arial, sans-serif;
    font-weight: 600;
    font-size: 1.6rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    cursor: pointer;
}

.access-submit button:hover {
    background: #c92c14;
}

.access-submit button:disabled {
    opacity: 0.6;
    cursor: default;
}

/* Aviso de la portada cuando /test devuelve a alguien por un código que no vale. Mismo tamaño
   que el de /test: dos frases no necesitan los 850px de la caja del formulario. */
.acceso-modal {
    max-width: 520px;
    padding: 34px 34px 28px;
}

.acceso-modal .underline-heading {
    margin-top: 0;
}

.acceso-modal .access-submit {
    margin-top: 20px;
}

/* Aviso de /test cuando se pulsa Siguiente sin contestar. Reutiliza .access-modal y sólo
   corrige lo que no encaja: aquella caja mide 850px porque aloja un formulario de seis campos,
   y aquí sobra ancho para dos frases. */
.test-aviso-modal {
    max-width: 520px;
    padding: 34px 34px 28px;
}

.test-aviso-modal .underline-heading {
    margin-top: 0;
}

.test-aviso-modal .access-submit {
    margin-top: 20px;
}

/* Error por campo: lo rellena el JS con lo que devuelve el servidor. Ocupa sitio sólo cuando hay
   algo que decir (sin la clase queda display:none), para que el formulario no baile al validarse. */
.access-err {
    display: none;
    margin: 4px 0 0;
    font-size: 1.35rem;
    line-height: 1.3;
    color: #e0341a;
}

.access-err.is-visible {
    display: block;
}

/* Aviso general del formulario: "Enviando…", el acuse de recibo o el fallo de red. */
.access-aviso {
    display: none;
    grid-column: 1 / -1;
    margin: 4px 0 0;
    font-size: 1.45rem;
    line-height: 1.4;
}

.access-aviso.is-visible {
    display: block;
}

.access-aviso.is-ok {
    color: #1e7a3c;
}

.access-aviso.is-err {
    color: #e0341a;
}

/* ---------- Test de Divergencia (cuestionario) ---------- */
.test-hero {
    position: relative;
    overflow: hidden;
    box-sizing: border-box;
    background: var(--navy) url(../images/fondoTest.jpg) center / cover no-repeat;
    min-height: 430px;
    padding: 140px 30px 40px;
    display: flex;
    align-items: flex-end;
}

.test-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(11, 21, 38, 0.15) 0%, rgba(11, 21, 38, 0.85) 100%);
    z-index: 0;
}

.test-hero-inner {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

.test-hero h1 {
    color: #ffffff;
    font-size: 5.1rem;
    margin-bottom: 12px;
}

.test-hero p {
    color: #f2e9e2;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    font-size: 2.2rem;
    line-height: 1.5;
    margin: 0;
}

/* ---------- Barra de estado del test ---------- */
.test-status {
    background: #000000;
}

.test-status-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 1px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
}

.test-user {
    display: flex;
    align-items: center;
    gap: 14px;
    flex: none;
}

.test-progress-group {
    display: flex;
    align-items: self-end;
    gap: 24px;
    flex: none;
}

.test-user-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1.5px solid #ffffff;
    flex: none;
}

.test-user-info {
    display: flex;
    flex-direction: column;
    line-height: 1.25;
}

    .test-user-info strong {
        color: #ffffff;
        font-size: 2.5rem;
        font-weight: 600;
        text-transform: uppercase;
    }

.test-user-info span {
    color: var(--accent);
    font-size: 1.7rem;
    font-weight: 600;
    text-transform: uppercase;
}

.test-cod {
    flex: none;
    color: #ffffff;
    font-size: 1.7rem;
    font-weight: 500;
    letter-spacing: 0.02em;
    white-space: nowrap;
    margin-bottom: -5px;
}
.test-progress {
    flex: none;
    width: 420px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.test-progress-marks {
    position: relative;
    height: 20px;
    font-size: 1.5rem;
    font-weight: 600;
    color: #ffffff;
}

.test-progress-marks span {
    position: absolute;
    top: 0;
    left: 0;
    white-space: nowrap;
    transform: translateX(-50%);
}

.test-progress-marks span[data-mark="1"] {
    left: 25%;
}

.test-progress-marks span[data-mark="2"] {
    left: 50%;
}

.test-progress-marks span[data-mark="3"] {
    left: 75%;
}

.test-progress-marks span[data-mark="4"] {
    left: 100%;
    transform: translateX(-100%);
}

.test-progress-marks span.is-done {
    color: var(--accent);
}

.test-progress-track {
    position: relative;
    height: 10px;
    border-radius: 999px;
    background: #262626;
    overflow: hidden;
}

.test-progress-fill {
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    width: 0%;
    background: var(--accent);
    border-radius: 999px;
    transition: width 0.4s ease;
}

/* ---------- Cuerpo del test ---------- */
.test-body {
    padding: 40px 30px 80px;
}

.test-container {
    max-width: 1200px;
    margin: 0 auto;
}

.test-viewport {
    position: relative;
    overflow: hidden;
}

.test-step {
    display: none;
}

.test-step.is-active {
    display: block;
}

.test-question {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 26px;
}

.test-question-number {
    flex: none;
    font-size: 3.4rem;
    font-weight: 600;
    line-height: 1;
    color: var(--accent);
    margin-top: 2px;
}

.test-question-body {
    flex: 1;
    min-width: 0;
}

.test-question .section-title {
    margin-bottom: 5px;
    padding-left:0px;
}

.test-question .section-title::before {
    display: none;
}

.test-question-lead {
    font-size: 2.2rem;
    font-weight: 600;
    color: var(--text);
    margin: 0;
    max-width: 1100px;
}

.test-card {
    background: var(--card);
    border-radius: 18px;
    box-shadow: 0 10px 30px rgba(11, 21, 38, 0.08);
    display: flex;
    align-items: stretch;
    overflow: hidden;
    border: 5px solid white;
}

.test-options {
    flex: 1;
    padding: 32px 36px;
}
    .test-options h3 {
        font-size: 2rem;
        font-weight: 600;
        text-transform: uppercase;
        margin: 0 0 20px;
    }

.test-option {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    padding: 18px 0;
    border-bottom: 1px solid rgba(26, 26, 26, 0.12);
    cursor: pointer;
}

.test-option:last-child {
    border-bottom: none;
    padding-bottom: 4px;
}

.test-option input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.test-radio {
    flex: none;
    width: 32px;
    height: 32px;
    margin-top: 2px;
    border-radius: 50%;
    border: 2px solid #cfc6bd;
    background: #ffffff;
    box-sizing: border-box;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.test-option input:checked + .test-radio {
    background: var(--accent);
    border-color: var(--accent);
}

.test-option-text {
    line-height: 1.4;
    font-size: 2rem;
    color: var(--text-soft);
    font-weight: 300;
}

.test-cta {
    flex: none;
    width: 150px;
    margin: 14px;
    border: none;
    border-radius: 14px;
    background: #000000;
    color: #ffffff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    cursor: pointer;
    font-family: 'Barlow Condensed', Arial, sans-serif;
}
    .test-cta span {
        font-size: 2rem;
        font-weight: 600;
        text-transform: uppercase;
        letter-spacing: 0.03em;
    }

.test-cta svg {
    color: var(--accent);
}

.test-cta:hover svg {
    color: #ff5b3f;
}

/* ---------- Pantalla de carga ---------- */
.test-loading-card {
    background: linear-gradient(135deg, var(--navy) 0%, var(--navy-soft) 100%);
    border-radius: 18px;
    box-shadow: 0 10px 30px rgba(11, 21, 38, 0.12);
    padding: 60px 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 26px;
    min-height: 260px;
}

.test-loading-card p {
    color: #ffffff;
    font-size: 1.6rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    margin: 0;
}

/* Loader de 3 anillos en perspectiva 3D (adaptado de
   https://codepen.io/martinvd/pen/xbQJom). */
.test-spinner {
    position: relative;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    perspective: 800px;
}

.test-spinner-ring {
    position: absolute;
    box-sizing: border-box;
    width: 100%;
    height: 100%;
    border-radius: 50%;
}

.test-spinner-ring.one {
    left: 0%;
    top: 0%;
    animation: test-rotate-one 1s linear infinite;
    border-bottom: 3px solid #efeffa;
}

.test-spinner-ring.two {
    right: 0%;
    top: 0%;
    animation: test-rotate-two 1s linear infinite;
    border-right: 3px solid #efeffa;
}

.test-spinner-ring.three {
    right: 0%;
    bottom: 0%;
    animation: test-rotate-three 1s linear infinite;
    border-top: 3px solid #efeffa;
}

@keyframes test-rotate-one {
    0% { transform: rotateX(35deg) rotateY(-45deg) rotateZ(0deg); }
    100% { transform: rotateX(35deg) rotateY(-45deg) rotateZ(360deg); }
}

@keyframes test-rotate-two {
    0% { transform: rotateX(50deg) rotateY(10deg) rotateZ(0deg); }
    100% { transform: rotateX(50deg) rotateY(10deg) rotateZ(360deg); }
}

@keyframes test-rotate-three {
    0% { transform: rotateX(35deg) rotateY(55deg) rotateZ(0deg); }
    100% { transform: rotateX(35deg) rotateY(55deg) rotateZ(360deg); }
}

/* ---------- Resultado ---------- */
.test-result-card {
    display: block;
    padding: 40px 44px 34px;
}

.test-result-card .underline-heading {
    font-size: 3rem;
    margin-bottom: 22px;
}

.test-result-grid {
    display: grid;
    grid-template-columns: 1.6fr 1fr;
    gap: 40px;
}

.test-result-text {
    border-right: 1px solid rgba(26, 26, 26, 0.15);
    padding-right: 30px;
}

.test-result-meta {
    font-size: 1.6rem;
    margin: 0 0 4px;
}

.test-result-text p {
    font-size: 2rem;
    color: var(--text-soft);
    margin: 0 0 16px;
}

.test-result-text p:last-child {
    margin-bottom: 0;
}

.accent {
    color: var(--accent);
}

.test-result-chart {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 26px;
}

.test-pie {
    --pct: 0;
    width: 220px;
    height: 220px;
    border-radius: 50%;
    background: conic-gradient(var(--accent) 0% calc(var(--pct) * 1%), #000000 calc(var(--pct) * 1%) 100%);
    border: 1px solid #000000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.test-pie span {
    color: #ffffff;
    font-size: 2.6rem;
    font-weight: 600;
}

.test-pie span small {
    font-size: 1.6rem;
}

.test-download,
.test-download:hover,
.test-download:focus,
.test-download:visited {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    background: var(--accent);
    color: #ffffff;
    border: none;
    border-radius: 8px;
    padding: 14px 20px;
    font-family: 'Barlow Condensed', Arial, sans-serif;
    font-weight: 600;
    font-size: 1.4rem;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    text-decoration: none;
    cursor: pointer;
}

.test-pdf-icon {
    flex: none;
    background: #ffffff;
    color: var(--accent);
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    border-radius: 4px;
    padding: 4px 6px;
}

.test-divider {
    border: none;
    border-top: 1px solid rgba(26, 26, 26, 0.15);
    margin: 30px 0;
}

.test-result-report {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
}
p.test-result-meta {
    text-transform: uppercase;
    font-size: 2.5rem;
    margin-bottom: 0;
}

    .test-result-report h3 {
        font-size: 2rem;
        font-weight: 600;
        text-transform: none;
        margin: 0 0 8px;
    }

.test-result-report p {
    font-size: 2rem;
    color: var(--text-soft);
    margin: 0;
    max-width: 640px;
}

.test-result-report .test-download {
    width: auto;
    flex: none;
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
    .hero {
        min-height: 480px;
        padding: 120px 24px 60px;
    }

    .origin-grid {
        grid-template-columns: 1fr;
    }

    .estudio-card {
        flex-direction: column;
    }

    .estudio-photo {
        width: 100%;
        flex: none;
        height: 220px;
    }

    .pillars {
        gap: 50px;
    }

    .hero h1 {
        font-size: 3.2rem;
    }

    .hero p {
        font-size: 1.5rem;
    }

    .photo-hero {
        min-height: 320px;
        padding: 120px 24px 40px;
    }

    .access-hero {
        min-height: 100vh;
    }

    .photo-hero h1 {
        font-size: 3.2rem;
    }

    .photo-hero-subtitle {
        font-size: 1.5rem;
    }

    .comparativos-grid {
        grid-template-columns: 1fr;
    }

    .access-login-form {
        flex-direction: column;
        align-items: stretch;
    }

    .access-field--login {
        width: auto;
    }

    .intro-quote {
        font-size: 1.8rem;
    }

    .section-title {
        font-size: 2.8rem;
    }

    .test-question-number {
        font-size: 2.4rem;
    }

    .test-question-lead {
        font-size: 1.8rem;
    }

    .access-form {
        grid-template-columns: 1fr;
    }

    .access-modal {
        padding: 30px 24px 26px;
    }

    .test-status-inner {
        flex-wrap: wrap;
        row-gap: 14px;
        padding: 15px 15px;
    }

    .test-progress-group {
        flex: 1 1 100%;
    }

    .test-progress {
        width: auto;
        flex: 1;
    }

    .test-card {
        flex-direction: column;
    }

    .test-cta {
        width: auto;
        flex-direction: row;
        height: 75px;
    }

    .test-result-grid {
        grid-template-columns: 1fr;
    }

    .test-result-text {
        border-right: none;
        padding-right: 0;
        margin-bottom: 20px;
    }

    .test-result-report {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (max-width: 600px) {
    .header-inner {
        position: relative;
    }

    .menu-toggle {
        display: flex;
    }

    /* El menú se convierte en un panel desplegable bajo el header. Por
       defecto oculto (opacity/visibility) para que no haya parpadeo antes
       de que cargue el JS; mobile-menu.js alterna la clase .is-open. */
    .main-nav {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        align-items: flex-start;
        gap: 18px;
        margin: 0;
        padding: 22px 30px 28px;
        background: var(--navy);
        box-shadow: 0 18px 30px rgba(0, 0, 0, 0.25);
        opacity: 0;
        visibility: hidden;
        transform: translateY(-12px);
        transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
    }

    .main-nav.is-open {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

    .main-nav .sep {
        display: none;
    }

    .footer-inner {
        grid-template-columns: 1fr;
        row-gap: 12px;
    }

    .footer-brand {
        justify-self: center;
    }

    .footer-copy {
        grid-column: 1;
        white-space: normal;
    }
}

/* Botón de confirmación de la baja (/baja?g=...). Mismo aspecto que el del formulario de
   solicitud de la portada: es la misma clase de acción —un envío— y no había motivo para que
   se viera distinto. Va en su propio bloque porque aquí el botón está suelto en el hero, sin
   la rejilla de .access-submit. */
.baja-form {
    margin: 18px 0 10px;
}

.baja-form button {
    background: var(--accent);
    color: #ffffff;
    border: none;
    border-radius: 6px;
    padding: 14px 30px;
    font-family: 'Barlow Condensed', Arial, sans-serif;
    font-weight: 600;
    font-size: 1.6rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    cursor: pointer;
}

.baja-form button:hover {
    background: #c92c14;
}
