/**
 * Estilos tenant CRT
 * @author Aris Mota <aris@parafina.es>
 * @version 2.12.2
 */

:root {
    --font-family-app: 'Cupra', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --bg-main-color: #ffffff;
    --tipografias: #043D4F;
    --tipografias-inactivo: rgba(4, 61, 79, 0.5);
    --separador-bg: rgba(4, 61, 79, 1);
    --itemactivo: rgba(4, 61, 79, 1);
    --separador-text: #ffffff;
    --bs-heading-color:var(--tipografias);
    --icono-cerrar: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" id="Capa_1" x="0px" y="0px" viewBox="0 0 30 25" style="enable-background:new 0 0 30 25;" xml:space="preserve"><path d="M12.8,12.4c-0.2-0.1-0.4-0.2-0.5-0.4c-3-3-6-6-9-9C2.9,2.7,2.7,2.3,2.7,1.8c0-0.6,0.3-1.1,0.9-1.4c0.6-0.3,1.2-0.2,1.7,0.2 c0.1,0.1,0.2,0.2,0.4,0.3c3,3,5.9,5.9,8.9,8.9c0.1,0.1,0.2,0.3,0.3,0.5c0.2-0.2,0.4-0.3,0.5-0.5c3-3,6-6,9-9 c0.4-0.4,0.8-0.6,1.3-0.6c0.6,0,1.1,0.3,1.4,0.9c0.3,0.6,0.2,1.2-0.2,1.7c-0.1,0.2-0.3,0.3-0.4,0.4c-2.9,2.9-5.9,5.9-8.8,8.8 c-0.1,0.1-0.3,0.2-0.5,0.4c0.2,0.2,0.3,0.3,0.4,0.4c3,3,6,6,9,9c0.3,0.3,0.5,0.7,0.6,1.1c0.2,0.7-0.2,1.3-0.8,1.6 c-0.6,0.3-1.3,0.3-1.8-0.2c-0.3-0.3-0.6-0.5-0.8-0.8c-2.8-2.8-5.6-5.6-8.4-8.4c-0.1-0.1-0.2-0.2-0.4-0.4c-0.1,0.1-0.3,0.3-0.4,0.4 c-3,3-6,6-9,9C4.9,24.9,4,25,3.3,24.5c-0.8-0.6-0.9-1.7-0.1-2.5c1.2-1.2,2.4-2.4,3.6-3.7C8.8,16.4,10.7,14.5,12.8,12.4z" fill="%23000000"/></svg>');
}

body,
button,
input,
select,
textarea,
.btn,
.form-control,
.form-select,
.dropdown-menu {
    font-family: var(--font-family-app) !important;
}

body {
    background-color: var(--bg-main-color);
    color: var(--tipografias);
    font-size: 18px;
    font-weight: 300;
    min-height: 100vh;
}

strong {
    font-weight: bold !important;
}

#body-agenda .bloque-agenda .hora-agenda {
    background-color: var(--separador-bg);
    color: var(--separador-text);
    padding-top: 6px !important;
}

.navbar-toggler.collapsed .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%280, 0, 0, 0.75%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
}

#navbarSupportedContent .nav-link {
    color: var(--tipografias);
}

#navbarSupportedContent .nav-link.active {
    color: var(--tipografias);
}

/* Fondo inmersivo: countdown, login, soporte y agenda (móvil) */
@media screen and (max-width: 550px) {
    html:has(body.body-countdown),
    body.body-countdown,
    html:has(body.body-login),
    body.body-login,
    html:has(body.body-login-soporte),
    body.body-login-soporte,
    html:has(body.body-password-forgot),
    body.body-password-forgot,
    html:has(body.body-password-reset),
    body.body-password-reset,
    html:has(body.body-register),
    body.body-register,
    body.body-agenda,
    body.body-instalar {
        --crt-immersive-bg-color: #000000;
        --crt-immersive-bg-image: url('background.png');
        background-color: var(--crt-immersive-bg-color);
        background-image: var(--crt-immersive-bg-image);
        background-size: cover;
        background-position: center center;
        background-repeat: no-repeat;
        background-attachment: fixed;
        color: #ffffff;
    }

    html:has(body.body-countdown),
    body.body-countdown,
    html:has(body.body-login),
    body.body-login,
    html:has(body.body-login-soporte),
    body.body-login-soporte,
    html:has(body.body-password-forgot),
    body.body-password-forgot,
    html:has(body.body-password-reset),
    body.body-password-reset {
        overflow: hidden !important;
        height: 100%;
        height: 100dvh;
        width: 100%;
        margin: 0;
        overscroll-behavior: none;
        touch-action: none;
    }

    body.body-countdown,
    body.body-login,
    body.body-login-soporte,
    body.body-password-forgot,
    body.body-password-reset {
        position: fixed;
        inset: 0;
    }

    body.body-agenda,
    body.body-instalar {
        --bg-main-color: transparent;
        --tipografias: #ffffff;
        --tipografias-inactivo: rgba(255, 255, 255, 0.55);
        --separador-bg: rgba(255, 255, 255, 0.95);
        --separador-text: #000000;
        --itemactivo: #ffffff;
        --bs-heading-color: #ffffff;
    }

    /* Navbar fijo: misma capa de fondo que el body (evita solapamiento al hacer scroll) */
    body.body-agenda header .navbar.fixed-top {
        background-color: var(--crt-immersive-bg-color, #000000);
        background-image: var(--crt-immersive-bg-image, url('background.png'));
        background-size: cover;
        background-position: center center;
        background-repeat: no-repeat;
        background-attachment: fixed;
        box-shadow: 0 1px 0 rgba(255, 255, 255, 0.06);
    }

    body.body-agenda #navbarSupportedContent.show,
    body.body-agenda #navbarSupportedContent.collapsing {
        background-color: #000000;
    }

    body.body-agenda #navbarSupportedContent .nav-link,
    body.body-agenda #navbarSupportedContent .nav-link.active,
    body.body-agenda .navbar-toggler.collapsed .navbar-toggler-icon {
        color: #ffffff;
    }

    body.body-agenda .navbar-toggler.collapsed .navbar-toggler-icon {
        background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.85%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
    }

    body.body-agenda .navbar-toggler:not(.collapsed) {
        border: 1px solid rgba(255, 255, 255, 0.85) !important;
    }

    body.body-agenda .navbar-toggler:not(.collapsed) .navbar-toggler-icon {
        background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.95%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2.5' d='M6 6l18 18M24 6L6 24'/%3e%3c/svg%3e") !important;
        opacity: 1 !important;
    }

    body.body-agenda #logo {
        filter: brightness(0) invert(1);
    }

    body.body-agenda .control-dia {
        border: 1px solid rgba(255, 255, 255, 0.45);
        color: #ffffff;
    }

    body.body-agenda #control-agenda .control-activo {
        background-color: #ffffff !important;
        border-color: #ffffff;
        color: #000000 !important;
    }

    body.body-agenda #control-agenda .control-activo .h2,
    body.body-agenda #control-agenda .control-activo .h3 {
        color: #000000 !important;
    }

    body.body-agenda .bloque-agenda {
        background-color: rgba(0, 0, 0, 0.35);
        color: #ffffff;
    }

    body.body-agenda .titulo-agenda,
    body.body-agenda .lugar-agenda,
    body.body-agenda .agenda-empty,
    body.body-agenda .agenda-unavailable {
        color: #ffffff !important;
    }

    body.body-agenda .agenda-unavailable {
        font-family: var(--font-family-app);
        font-size: 1rem;
        line-height: 1.55;
        max-width: 28rem;
        margin-left: auto;
        margin-right: auto;
    }

    body.body-agenda #vista-content,
    body.body-agenda #vista-content h1,
    body.body-agenda #vista-content p {
        color: #ffffff;
    }

    body.body-agenda .agenda-page-title {
        font-weight: bold;
        line-height: 1.2;
        margin-bottom: 0.75rem;
        text-transform: uppercase;
    }

    body.body-agenda .agenda-page-title strong {
        font-weight: bold;
    }

    body.body-agenda .agenda-page-title-group {
        display: block;
        font-size: 1em;
        line-height: 1.2;
    }

    body.body-agenda .agenda-page-title-main {
        display: block;
        font-size: 1.75em;
        line-height: 1.1;
        margin-bottom: 0.15em;
    }

    body.body-agenda #body-agenda {
        background-color: transparent;
    }

    body.body-with-footer .app-layout-main > .app-footer {
        position: relative;
        z-index: 5;
        flex-shrink: 0;
        border-top: 1px solid rgba(255, 255, 255, 0.12);
    }

    body.body-countdown #version-moviles,
    body.body-login #version-moviles,
    body.body-login-soporte #version-moviles,
    body.body-password-forgot #version-moviles,
    body.body-password-reset #version-moviles,
    body.body-register #version-moviles {
        display: flex !important;
        flex-direction: column;
        height: 100%;
        height: 100dvh;
        overflow: hidden;
    }

    body.body-countdown #vista,
    body.body-login #vista,
    body.body-login-soporte #vista,
    body.body-password-forgot #vista,
    body.body-password-reset #vista,
    body.body-register #vista {
        display: flex;
        flex: 1;
        align-items: center;
        justify-content: center;
        padding: 0;
        margin: 0;
        max-width: 100%;
        height: 100%;
        overflow: hidden;
    }

    body.body-countdown #vista.container-fluid,
    body.body-login #vista.container-fluid,
    body.body-login-soporte #vista.container-fluid,
    body.body-password-forgot #vista.container-fluid,
    body.body-password-reset #vista.container-fluid,
    body.body-register #vista.container-fluid {
        --bs-gutter-x: 0;
        --bs-gutter-y: 0;
    }

    #countdown-screen {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        width: 100%;
        max-height: 100%;
        padding: 0 1.5rem;
        box-sizing: border-box;
        text-align: center;
        gap: 2.5rem;
    }

    .countdown-logo {
        flex: 0 0 auto;
        max-width: 280px;
        width: 75%;
        margin-bottom: 0;
    }

    .countdown-logo img {
        width: 100%;
        height: auto;
    }

    .countdown-timer {
        flex: 0 0 auto;
        width: 100%;
        max-width: 360px;
    }

    .countdown-digits {
        display: flex;
        align-items: flex-start;
        justify-content: center;
        gap: 0.1em;
    }

    .countdown-col {
        display: flex;
        flex-direction: column;
        align-items: center;
        min-width: 2.4em;
    }

    .countdown-value {
        font-family: var(--font-family-app);
        font-weight: 700;
        font-size: clamp(2.75rem, 12vw, 4.5rem);
        line-height: 1;
        letter-spacing: 0.02em;
        color: #ffffff;
        font-variant-numeric: tabular-nums;
    }

    .countdown-sep {
        font-family: var(--font-family-app);
        font-weight: bold;
        font-size: clamp(2.75rem, 12vw, 4.5rem);
        line-height: 1;
        color: #ffffff;
        padding: 0 0.05em;
        align-self: flex-start;
    }

    .countdown-label {
        margin-top: 0.75rem;
        font-family: var(--font-family-app);
        font-weight: normal;
        font-size: 0.8rem;
        letter-spacing: 0.14em;
        text-transform: uppercase;
        color: #ffffff;
    }
}

/* Login-screen (login móvil, reset/forgot/soporte en desktop) — todos los viewports */
.login-screen {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    max-width: 420px;
    padding: 0 1.5rem 2rem;
    box-sizing: border-box;
    text-align: center;
    gap: 1.75rem;
}

.login-logo {
    flex: 0 0 auto;
    max-width: 200px;
    width: 55%;
    margin: 0 auto;
}

.login-logo img {
    width: 100%;
    height: auto;
}

.login-title {
    font-family: var(--font-family-app);
    font-weight: bold;
    font-size: clamp(1.1rem, 4.5vw, 1.35rem);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #ffffff;
    margin: 0;
}

.login-subtitle {
    font-family: var(--font-family-app);
    font-weight: normal;
    font-size: 0.75rem;
    letter-spacing: 0.28em;
    text-transform: uppercase;
    color: #ffffff;
    margin: 0.5rem 0 0;
}

.login-support-screen .login-headings {
    margin-top: 1.75rem;
}

.login-support-intro {
    letter-spacing: 0.08em;
    line-height: 1.5;
    font-size: 0.85rem;
    text-transform: none;
    color: #ffffff;
}

.login-form {
    text-align: left;
    width: 100%;
}

.login-field {
    margin-bottom: 1.5rem;
}

.login-input {
    display: block;
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid #ffffff;
    border-radius: 0;
    color: #ffffff;
    font-family: var(--font-family-app);
    font-size: 1rem;
    padding: 0.35rem 0;
    outline: none;
    box-shadow: none;
    -webkit-appearance: none;
    appearance: none;
}

.login-input::placeholder {
    color: rgba(255, 255, 255, 0.75);
}

.login-forgot-wrap {
    text-align: right;
    margin: -0.5rem 0 1.25rem;
}

.login-forgot {
    color: #ffffff;
    font-size: 0.8rem;
    text-decoration: underline;
}

.login-error {
    color: #ffb4b4;
    font-size: 0.85rem;
    margin-bottom: 1rem;
}

.login-success {
    color: #b4ffb8;
    font-size: 0.85rem;
    margin-bottom: 1rem;
    line-height: 1.45;
}

.login-input-readonly {
    opacity: 0.85;
    cursor: default;
}

.login-footer-support {
    margin: 1.25rem 0 0;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.85);
}

.login-footer-support-link {
    color: #ffffff;
    text-decoration: underline;
}

.login-submit-link {
    display: inline-block;
    text-decoration: none;
}

.login-support-screen .contact-title {
    font-family: var(--font-family-app);
    font-weight: bold;
    font-size: clamp(1.1rem, 4.5vw, 1.35rem);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #ffffff;
    margin: 0;
    text-align: left;
}

.login-support-screen .contact-intro {
    text-align: left;
}

.login-back-btn {
    margin-top: 0.5rem;
}

.login-submit,
.login-back-btn {
    display: block;
    width: 100%;
    box-sizing: border-box;
    background: transparent;
    border: 1px solid #ffffff;
    color: #ffffff;
    font-family: var(--font-family-app);
    font-weight: bold;
    font-size: 1rem;
    letter-spacing: 0.06em;
    text-transform: none;
    text-align: center;
    text-decoration: none;
    padding: 0.85rem 1rem;
    cursor: pointer;
}

.login-submit:disabled {
    opacity: 0.6;
}

.login-support-contacts {
    text-align: left;
    width: 100%;
}

.login-support-item {
    margin-bottom: 1rem;
}

.login-support-label {
    display: block;
    font-size: 0.75rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    opacity: 0.8;
    margin-bottom: 0.25rem;
}

.login-support-item a {
    color: #ffffff;
    text-decoration: underline;
}

/* Landing registro (asignación contraseña) — todos los viewports */
.register-screen {
    width: 100%;
    max-width: 1140px;
    margin: 0 auto;
    color: #ffffff;
}

.register-header {
    width: 100%;
}

.register-body {
    padding: 2rem 1.25rem 1.5rem;
    max-width: 1140px;
}

.register-title {
    font-family: var(--font-family-app);
    font-weight: 700;
    font-size: clamp(1.25rem, 4vw, 2rem);
    letter-spacing: 0.04em;
    color: #ffffff;
    margin: 0 0 1rem;
}

.register-intro {
    font-family: var(--font-family-app);
    font-size: 0.95rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.9);
    margin: 0 0 2rem;
    max-width: 920px;
}

.register-message {
    margin-bottom: 1.5rem;
}

.register-form {
    width: 100%;
}

.register-fields {
    margin-bottom: 0.5rem;
}

.register-field {
    margin-bottom: 0;
}

.register-input {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid #ffffff;
    color: #ffffff;
    font-family: var(--font-family-app);
    font-size: 1rem;
    padding: 0.35rem 0;
    outline: none;
}

.register-input::placeholder {
    color: rgba(255, 255, 255, 0.75);
}

.register-input-readonly {
    opacity: 0.85;
    cursor: default;
}

.register-error {
    color: #ff6b6b;
    font-size: 0.85rem;
    margin: 0.75rem 0 0;
}

.register-submit-wrap {
    display: flex;
    justify-content: flex-end;
    margin-top: 2rem;
}

.register-submit,
.register-submit-link {
    display: inline-block;
    box-sizing: border-box;
    background: transparent;
    border: 1px solid #ffffff;
    color: #ffffff;
    font-family: var(--font-family-app);
    font-weight: bold;
    font-size: 1rem;
    letter-spacing: 0.06em;
    text-align: center;
    text-decoration: none;
    padding: 0.75rem 2rem;
    cursor: pointer;
    min-width: 140px;
}

.register-submit:disabled {
    opacity: 0.6;
}

/* Footer global (agenda y vistas con header) */
.app-footer {
    background-color: #000000;
    color: #ffffff;
    padding-top: 1rem;
    padding-bottom: calc(2.25rem + env(safe-area-inset-bottom, 0px));
    overflow: visible;
}

.app-footer .container-fluid {
    border-top: none;
    width: 100%;
    max-width: 100%;
    padding-top: 0;
    padding-bottom: 0;
}

.app-footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding-left: 1.25rem;
    padding-right: 1.25rem;
    box-sizing: border-box;
    overflow: visible;
}

.app-footer-logo {
    flex: 0 0 auto;
    width: 44px;
    max-width: 44px;
    line-height: 1;
    overflow: visible;
}

.app-footer-logo img {
    display: block;
    width: 100%;
    height: auto;
    max-height: none;
}

.app-footer-brand {
    flex: 0 1 auto;
    margin: 0;
    font-family: var(--font-family-app);
    font-size: clamp(0.7rem, 2.8vw, 0.9rem);
    font-weight: bold;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #ffffff;
    text-align: right;
}

.register-footer {
    border-top: 1px solid rgba(255, 255, 255, 0.35);
    padding: 1.25rem;
    max-width: 1140px;
}

.register-footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.register-footer-logo {
    flex: 0 0 auto;
    max-width: 48px;
}

.register-footer-logo img {
    width: 100%;
    height: auto;
}

.register-footer-text {
    flex: 1 1 220px;
    margin: 0;
    font-size: 0.75rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.85);
    text-align: left;
}

.register-footer-text a {
    color: #ffffff;
    text-decoration: none;
}

@media screen and (max-width: 550px) {
    html:has(body.body-register),
    body.body-register {
        background-color: #000000;
        background-image: url('background.png');
        background-size: cover;
        background-position: center center;
        background-repeat: no-repeat;
        color: #ffffff;
    }

    body.body-register #version-moviles {
        display: block !important;
    }

    body.body-register #vista {
        display: block;
        height: auto;
        overflow: visible;
    }

    .register-footer-text {
        text-align: left;
    }
}

/* Landing desktop (viewport > 550px) */
@media screen and (min-width: 551px) {
    html,
    body {
        background-color: #000000 !important;
    }

    #version-desktop {
        background-color: #000000;
        color: #ffffff;
        font-family: var(--font-family-app);
    }

    #desk-cta,
    #desk-instr {
        color: #ffffff;
        font-family: var(--font-family-app);
    }

    #desk-cta {
        font-weight: bold;
    }

    #desk-instr {
        font-weight: normal;
    }

    #desk-logo img {
        max-width: min(90vw, 720px);
        width: 100%;
        height: auto;
    }

    /* Countdown / login (sin post-reset): solo móvil; en desktop landing QR. Post-reset: body-login-form */
    body.body-countdown #version-moviles,
    body.body-login:not(.body-login-form) #version-moviles {
        display: none !important;
    }

    body.body-countdown #version-desktop {
        display: flex !important;
        flex-direction: column;
        justify-content: center;
        align-items: center;
    }

    body.body-register #version-desktop,
    body.body-password-forgot #version-desktop,
    body.body-password-reset #version-desktop,
    body.body-login-soporte #version-desktop,
    body.body-login.body-login-form #version-desktop {
        display: none !important;
    }

    body.body-register #version-moviles,
    body.body-password-forgot #version-moviles,
    body.body-password-reset #version-moviles,
    body.body-login-soporte #version-moviles,
    body.body-login.body-login-form #version-moviles {
        display: block !important;
    }

    html:has(body.body-register),
    body.body-register,
    html:has(body.body-password-forgot),
    body.body-password-forgot,
    html:has(body.body-password-reset),
    body.body-password-reset,
    html:has(body.body-login-soporte),
    body.body-login-soporte,
    html:has(body.body-login.body-login-form),
    body.body-login.body-login-form {
        background-color: #000000 !important;
        color: #ffffff;
        min-height: 100vh;
    }

    body.body-register #vista,
    body.body-password-forgot #vista,
    body.body-password-reset #vista,
    body.body-login-soporte #vista,
    body.body-login.body-login-form #vista {
        display: flex;
        flex: none;
        align-items: center;
        justify-content: center;
        height: auto;
        min-height: 100vh;
        overflow: visible;
        max-width: 100%;
        padding: 2rem 0;
        box-sizing: border-box;
    }

    .password-forgot-screen,
    .password-reset-screen,
    .login-support-screen,
    #login-screen.login-screen {
        max-width: 420px;
        width: 100%;
        margin: 0 auto;
        padding: 0 1.5rem 2rem;
    }

    .register-body {
        padding: 2.5rem 1.5rem 2rem;
    }

    .register-footer-text {
        text-align: right;
    }
}

/* Thank you + install post-registro */
body.body-register-done,
body.body-register-install {
    color: #ffffff;
}

.register-install-body {
    text-align: center;
}

.register-install-login-wrap {
    display: flex;
    justify-content: center;
    margin: 2rem 0;
}

.register-install-login {
    text-decoration: none;
    min-width: 220px;
}

@media screen and (min-width: 551px) {
    .register-install-login-wrap {
        display: none;
    }
}

.register-install-qr {
    max-width: 240px;
    margin: 0 auto 2rem;
}

.register-install-subtitle {
    color: #ffffff;
    font-family: var(--font-family-app);
    font-size: 1.15rem;
    font-weight: bold;
    margin: 0 0 1.25rem;
    text-align: left;
}

.register-install-tabs {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.register-install-tab {
    flex: 1;
    background: transparent;
    border: 1px solid #ffffff;
    color: #ffffff;
    font-family: var(--font-family-app);
    font-size: 0.9rem;
    padding: 0.65rem 1rem;
    cursor: pointer;
}

.register-install-tab.is-active {
    background: #ffffff;
    color: #000000;
}

.register-install-panels {
    margin-bottom: 2rem;
}

.register-install-panel {
    display: none;
    text-align: left;
}

.register-install-panel.is-active {
    display: block;
}

.register-install-platform-label {
    font-family: var(--font-family-app);
    font-size: 1rem;
    font-weight: bold;
    margin: 0 0 0.5rem;
}

.register-install-platform-intro,
.register-install-platform-done {
    font-family: var(--font-family-app);
    font-size: 0.85rem;
    line-height: 1.5;
    margin: 0 0 1rem;
    color: rgba(255, 255, 255, 0.92);
}

.register-install-platform-done {
    margin-top: 1.25rem;
    margin-bottom: 0;
    font-weight: 500;
}

.register-install-steps {
    --register-install-step-count: 5;
}

.register-install-steps-nums {
    display: grid;
    grid-template-columns: repeat(var(--register-install-step-count), minmax(0, 1fr));
    align-items: center;
    gap: 0;
    margin: 0 0 1rem;
    position: relative;
    padding: 0 0.25rem;
}

.register-install-steps-nums::before {
    content: '';
    position: absolute;
    left: calc(50% / var(--register-install-step-count));
    right: calc(50% / var(--register-install-step-count));
    top: 50%;
    border-top: 1px dashed rgba(255, 255, 255, 0.85);
    z-index: 0;
    pointer-events: none;
}

.register-install-step-num {
    position: relative;
    z-index: 1;
    justify-self: center;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border: 1px solid #ffffff;
    border-radius: 50%;
    font-family: var(--font-family-app);
    font-size: 0.85rem;
    font-weight: bold;
    line-height: 1;
    background-color: #000000;
}

.register-install-steps-grid {
    display: grid;
    grid-template-columns: repeat(var(--register-install-step-count), minmax(0, 1fr));
    gap: 0.75rem;
    align-items: start;
}

.register-install-step {
    text-align: center;
    min-width: 0;
}

.register-install-step-trigger {
    display: block;
    width: 100%;
    max-width: 120px;
    margin: 0 auto 0.5rem;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, 0.45);
    background: transparent;
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.register-install-step-trigger:hover,
.register-install-step-trigger:focus {
    border-color: #ffffff;
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.25);
    outline: none;
}

.register-install-step-img {
    display: block;
    width: 100%;
    max-width: 120px;
    max-height: 220px;
    height: auto;
    margin: 0 auto;
    object-fit: contain;
    pointer-events: none;
}

.register-install-step-caption {
    font-family: var(--font-family-app);
    font-size: 0.72rem;
    line-height: 1.4;
    margin: 0;
    text-align: center;
    color: #ffffff;
}

.register-install-step--has-img .register-install-step-caption {
    cursor: pointer;
}

@media screen and (max-width: 767px) {
    .register-install-steps {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 0.5rem;
    }

    .register-install-steps-nums,
    .register-install-steps-grid {
        min-width: min(100%, calc(var(--register-install-step-count) * 118px));
    }

    .register-install-step-img {
        max-width: 100px;
        max-height: 200px;
    }

    .register-install-step-caption {
        font-size: 0.65rem;
        line-height: 1.35;
    }
}

/* Galería pasos instalación (lightbox) */
body.register-install-lightbox-open {
    overflow: hidden;
}

.register-install-lightbox {
    position: fixed;
    inset: 0;
    z-index: 10060;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem;
}

.register-install-lightbox[hidden] {
    display: none !important;
}

.register-install-lightbox-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.92);
}

.register-install-lightbox-dialog {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: min(520px, 98vw);
    max-height: 100%;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    color: #ffffff;
    font-family: var(--font-family-app);
}

.register-install-lightbox-close {
    position: absolute;
    top: -0.25rem;
    right: 0;
    border: none;
    background: transparent;
    color: #ffffff;
    font-size: 2rem;
    line-height: 1;
    padding: 0.25rem 0.5rem;
    cursor: pointer;
    z-index: 2;
}

.register-install-lightbox-title {
    margin: 0 2rem 0.25rem 0;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.register-install-lightbox-counter {
    margin: 0 0 1rem;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.75);
}

.register-install-lightbox-stage {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    flex: 1 1 auto;
    min-height: 0;
}

.register-install-lightbox-figure {
    flex: 1 1 auto;
    margin: 0;
    min-width: 0;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

.register-install-lightbox-img {
    display: block;
    width: auto;
    max-width: min(400px, 90vw);
    max-height: min(82vh, 860px);
    height: auto;
    margin: 0 auto;
    object-fit: contain;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.register-install-lightbox-caption {
    display: block;
    margin: 1rem 0 0;
    font-size: 1rem;
    line-height: 1.6;
    text-align: left;
    max-width: min(420px, 92vw);
    margin-left: auto;
    margin-right: auto;
    color: #ffffff;
}

.register-install-lightbox-nav {
    flex: 0 0 auto;
    align-self: center;
    width: 2.5rem;
    height: 2.5rem;
    border: 1px solid #ffffff;
    background: transparent;
    color: #ffffff;
    font-size: 1.75rem;
    line-height: 1;
    padding: 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.register-install-lightbox-nav:disabled {
    opacity: 0.35;
    cursor: default;
}

.register-install-lightbox-nav:not(:disabled):hover,
.register-install-lightbox-nav:not(:disabled):focus {
    background: #ffffff;
    color: #000000;
    outline: none;
}

@media screen and (max-width: 550px) {
    html:has(body.body-register-done),
    body.body-register-done,
    html:has(body.body-register-install),
    body.body-register-install {
        background-color: #000000;
        background-image: url('background.png');
        background-size: cover;
        background-position: center center;
        background-repeat: no-repeat;
    }

    body.body-register-done #version-moviles,
    body.body-register-install #version-moviles {
        display: block !important;
    }

    body.body-register-done #vista,
    body.body-register-install #vista {
        display: block;
        height: auto;
        overflow: visible;
    }
}

@media screen and (min-width: 551px) {
    body.body-register-done #version-desktop,
    body.body-register-install #version-desktop {
        display: none !important;
    }

    body.body-register-done #version-moviles,
    body.body-register-install #version-moviles {
        display: block !important;
    }

    html:has(body.body-register-done),
    body.body-register-done,
    html:has(body.body-register-install),
    body.body-register-install {
        background-color: #000000 !important;
        min-height: 100vh;
    }

    body.body-register-done #vista,
    body.body-register-install #vista {
        display: block;
        flex: none;
        height: auto;
        overflow: visible;
        max-width: 100%;
        padding: 0;
    }
}

/* Modal instalación PWA (móvil) */
body.crt-pwa-install-open {
    overflow: hidden;
}

.crt-pwa-install-overlay {
    position: fixed;
    inset: 0;
    z-index: 10050;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.25rem;
}

.crt-pwa-install-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
}

.crt-pwa-install-card {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 340px;
    background: #ffffff;
    color: #000000;
    border-radius: 12px;
    padding: 1.75rem 1.5rem 1.5rem;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
    font-family: var(--font-family-app);
    text-align: center;
}

.crt-pwa-install-app-icon {
    display: block;
    width: 72px;
    height: 72px;
    margin: 0 auto 1rem;
    border-radius: 16px;
    object-fit: contain;
}

.crt-pwa-install-close {
    position: absolute;
    top: 0.5rem;
    right: 0.65rem;
    border: none;
    background: transparent;
    color: #000000;
    font-size: 1.5rem;
    line-height: 1;
    padding: 0.25rem 0.5rem;
    cursor: pointer;
}

.crt-pwa-install-title {
    font-size: 1.35rem;
    font-weight: bold;
    margin: 0 0 0.65rem;
    letter-spacing: 0.04em;
}

.crt-pwa-install-subtitle {
    font-size: 0.9rem;
    line-height: 1.45;
    margin: 0 0 1rem;
    color: #333333;
}

.crt-pwa-install-line {
    font-size: 0.95rem;
    line-height: 1.5;
    margin: 0 0 1rem;
}

.crt-pwa-install-note {
    font-size: 0.85rem;
    line-height: 1.4;
    margin: 0 0 0.85rem;
    color: #555555;
    font-style: italic;
}

.crt-pwa-install-steps {
    text-align: left;
    margin: 0 0 1.25rem;
    padding-left: 1.25rem;
    font-size: 0.9rem;
    line-height: 1.45;
}

.crt-pwa-install-steps li {
    margin-bottom: 0.45rem;
}

.crt-pwa-install-steps li:last-child {
    margin-bottom: 0;
}

.crt-pwa-install-actions {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.crt-pwa-install-btn {
    display: block;
    width: 100%;
    box-sizing: border-box;
    font-family: var(--font-family-app);
    font-weight: bold;
    font-size: 0.95rem;
    letter-spacing: 0.05em;
    padding: 0.75rem 1rem;
    cursor: pointer;
    border-radius: 0;
}

.crt-pwa-install-btn-primary {
    background: #000000;
    border: 1px solid #000000;
    color: #ffffff;
}

.crt-pwa-install-btn-secondary {
    background: transparent;
    border: 1px solid #000000;
    color: #000000;
}

.crt-pwa-install-btn-dismiss {
    background: transparent;
    border: 1px solid rgba(0, 0, 0, 0.35);
    color: #000000;
}

/* Vista instalación (?tipo=instalar) — diseño coherente con modal PWA */
.instalar-guide {
    display: flex;
    justify-content: center;
    padding: 0.5rem 0 1.5rem;
}

.instalar-guide-card {
    width: 100%;
    max-width: 400px;
    background: #ffffff;
    color: #000000;
    border-radius: 12px;
    padding: 1.75rem 1.5rem 1.5rem;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.12);
    font-family: var(--font-family-app);
    text-align: center;
}

.instalar-guide-title {
    font-size: 1.35rem;
    font-weight: bold;
    margin: 0 0 0.65rem;
    letter-spacing: 0.04em;
}

.instalar-guide-subtitle {
    font-size: 0.9rem;
    line-height: 1.45;
    margin: 0 0 1.25rem;
    color: #333333;
}

.instalar-guide-other {
    font-size: 0.9rem;
    line-height: 1.5;
    margin: 0 0 1.25rem;
    color: #333333;
    text-align: left;
}

.instalar-guide-tabs {
    display: flex;
    gap: 0.5rem;
    margin: 0 0 1rem;
}

.instalar-guide-tab {
    flex: 1;
    font-family: var(--font-family-app);
    font-size: 0.85rem;
    font-weight: bold;
    letter-spacing: 0.04em;
    padding: 0.55rem 0.75rem;
    border: 1px solid rgba(0, 0, 0, 0.25);
    background: #ffffff;
    color: #000000;
    cursor: pointer;
}

.instalar-guide-tab.is-active {
    background: #000000;
    border-color: #000000;
    color: #ffffff;
}

.instalar-guide-platform {
    text-align: left;
}

.instalar-guide-line {
    font-size: 0.95rem;
    line-height: 1.5;
    margin: 0 0 1rem;
}

.instalar-guide-note {
    font-size: 0.85rem;
    line-height: 1.4;
    margin: 0 0 0.85rem;
    color: #555555;
    font-style: italic;
}

.instalar-guide-steps {
    margin: 0 0 1.25rem;
}

.instalar-guide-done {
    font-size: 0.9rem;
    line-height: 1.45;
    margin: 0;
    font-weight: bold;
    color: #333333;
}

.instalar-guide-actions {
    margin-top: 1.25rem;
}

/* Vista instalar en móvil — mismo look que Ranking / FAQ / Contact (sin card blanca) */
@media screen and (max-width: 550px) {
    .instalar-guide {
        display: block;
        color: #ffffff;
        padding: 0 0 calc(2rem + env(safe-area-inset-bottom, 0px));
    }

    .instalar-guide-card {
        max-width: none;
        background: transparent;
        color: #ffffff;
        border-radius: 0;
        padding: 0;
        box-shadow: none;
        text-align: left;
    }

    #vista-content.instalar-guide .instalar-guide-title {
        display: block;
        margin: 0 0 0.75rem;
        font-family: var(--font-family-app);
        font-weight: bold;
        font-size: calc(20px * 1.75) !important;
        line-height: 1.1;
        text-transform: uppercase;
        color: #ffffff !important;
        letter-spacing: normal;
    }

    .instalar-guide-subtitle,
    .instalar-guide-line,
    .instalar-guide-other,
    .instalar-guide-done,
    .instalar-guide-steps,
    .instalar-guide-steps li {
        color: #ffffff;
    }

    .instalar-guide-subtitle,
    .instalar-guide-line,
    .instalar-guide-other {
        font-size: 0.95rem;
        line-height: 1.45;
    }

    .instalar-guide-note {
        color: rgba(255, 255, 255, 0.85);
    }

    .instalar-guide-done {
        font-weight: bold;
        color: #ffffff;
    }

    .instalar-guide-tab {
        border: 1px solid rgba(255, 255, 255, 0.45);
        background: transparent;
        color: #ffffff;
    }

    .instalar-guide-tab.is-active {
        background: #ffffff;
        border-color: #ffffff;
        color: #000000;
    }
}

/* Títulos Ranking / User Question / FAQ / Contact — igual que .agenda-page-title-main (sin tocar Agenda) */
#vista-content .ranking-title,
#vista-content .uq-title,
#vista-content .faq-title,
#vista-content .contact-title {
    display: block;
    margin: 0 0 0.75rem;
    font-family: var(--font-family-app);
    font-weight: bold;
    font-size: calc(20px * 1.75) !important;
    line-height: 1.1;
    text-transform: uppercase;
    color: #ffffff !important;
}

/* Ranking */
.ranking-view {
    color: #ffffff;
    padding-bottom: 1.5rem;
}

.ranking-user-status {
    margin: 0 0 1.25rem;
    font-family: var(--font-family-app);
    font-size: 0.95rem;
    font-weight: normal;
    color: #ffffff;
}

.ranking-empty,
.ranking-unavailable {
    color: rgba(255, 255, 255, 0.75);
    margin: 0;
    font-family: var(--font-family-app);
    font-size: 0.95rem;
    line-height: 1.55;
}

.ranking-list {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.ranking-item.is-me .ranking-item-name {
    outline: 1px solid rgba(255, 255, 255, 0.45);
    outline-offset: -1px;
}

.ranking-item-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    background: #ffffff;
    color: #000000;
    padding: 0.45rem 0.75rem;
    min-height: 2.25rem;
}

.ranking-item-rank {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    min-width: 0;
}

.ranking-top-label {
    font-family: var(--font-family-app);
    font-weight: bold;
    font-size: 0.95rem;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.ranking-item-points {
    font-family: var(--font-family-app);
    font-weight: bold;
    font-size: 0.95rem;
    white-space: nowrap;
}

.ranking-item-name {
    background: #000000;
    color: #ffffff;
    padding: 0.65rem 0.75rem;
    font-family: var(--font-family-app);
    font-weight: bold;
    font-size: clamp(1rem, 3.5vw, 1.35rem);
    line-height: 1.2;
    border: 1px solid #ffffff;
    border-top: none;
}

.ranking-trend {
    display: inline-flex;
    align-items: center;
    gap: 0.15rem;
    font-weight: bold;
    font-size: 0.9rem;
    line-height: 1;
}

.ranking-trend-up {
    color: #1a9b3c;
}

.ranking-trend-down {
    color: #d62828;
}

.ranking-trend-neutral {
    color: #666666;
}

.ranking-trend-delta {
    font-size: 0.75rem;
}

/* User Question */
.uq-view {
    color: #ffffff;
    padding-bottom: 1.5rem;
}

.uq-intro {
    margin: 0 0 1.5rem;
    font-family: var(--font-family-app);
    font-size: 0.95rem;
    font-weight: normal;
    color: #ffffff;
    line-height: 1.45;
}

.uq-submit-block {
    margin-bottom: 1.75rem;
}

.uq-submit-divider {
    margin: 0 0 1rem;
    border: 0;
    border-top: 1px solid #ffffff;
    opacity: 1;
}

.uq-submit-row {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.uq-input {
    width: 100%;
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.65);
    background: transparent;
    color: #ffffff;
    font-family: var(--font-family-app);
    font-size: 1rem;
    padding: 0.35rem 0;
    outline: none;
}

.uq-input::placeholder {
    color: rgba(255, 255, 255, 0.55);
}

.uq-submit-btn {
    align-self: flex-end;
    background: #ffffff;
    color: #000000;
    border: none;
    font-family: var(--font-family-app);
    font-weight: 700;
    font-size: 0.95rem;
    padding: 0.55rem 1rem;
    cursor: pointer;
}

.uq-submit-btn:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

.uq-success {
    margin: 0.85rem 0 0;
    color: #ffffff;
    font-family: var(--font-family-app);
    font-size: 0.9rem;
    line-height: 1.4;
}

.uq-error {
    margin: 0.85rem 0 0;
    color: #ff8a8a;
    font-family: var(--font-family-app);
    font-size: 0.9rem;
}

.uq-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.uq-item {
    border-radius: 4px;
    overflow: hidden;
}

.uq-item-question {
    width: 100%;
    display: flex;
    align-items: flex-start;
    gap: 0.35rem;
    text-align: left;
    background: #ffffff;
    color: #000000;
    border: none;
    padding: 0.75rem;
    font-family: var(--font-family-app);
    font-weight: 700;
    font-size: clamp(0.95rem, 3.2vw, 1.1rem);
    line-height: 1.3;
    cursor: pointer;
}

.uq-item-number {
    flex-shrink: 0;
}

.uq-item-text {
    flex: 1;
    min-width: 0;
}

.uq-item-answer {
    background: #000000;
    color: #ffffff;
    border: 1px solid #ffffff;
    border-top: none;
    padding: 0.75rem;
    font-family: var(--font-family-app);
    font-size: 0.95rem;
    line-height: 1.45;
}

.uq-item.is-open .uq-item-question {
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
}

/* FAQ */
.faq-view {
    color: #ffffff;
    padding-bottom: 1.5rem;
}

.faq-intro {
    margin: 0 0 1.5rem;
    font-family: var(--font-family-app);
    font-size: 0.95rem;
    font-weight: normal;
    color: #ffffff;
    line-height: 1.45;
}

.faq-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.faq-item {
    border-radius: 8px;
    overflow: hidden;
}

.faq-item-question {
    width: 100%;
    display: flex;
    align-items: flex-start;
    gap: 0.35rem;
    text-align: left;
    background: #ffffff;
    color: #000000;
    border: none;
    padding: 0.75rem;
    font-family: var(--font-family-app);
    font-weight: 700;
    font-size: clamp(0.95rem, 3.2vw, 1.1rem);
    line-height: 1.3;
    cursor: pointer;
}

.faq-item-number {
    flex-shrink: 0;
}

.faq-item-text {
    flex: 1;
    min-width: 0;
}

.faq-item-answer {
    background: #000000;
    color: #ffffff;
    border: 1px solid #ffffff;
    border-top: none;
    padding: 0.75rem;
    font-family: var(--font-family-app);
    font-size: 0.95rem;
    line-height: 1.45;
}

.faq-item.is-open .faq-item-question {
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
}

/* Emergency Contact */
.contact-view {
    color: #ffffff;
    padding-bottom: 1.5rem;
}

.contact-intro {
    margin: 0 0 1.5rem;
    font-family: var(--font-family-app);
    font-size: 0.95rem;
    font-weight: normal;
    color: #ffffff;
    line-height: 1.45;
}

.contact-bar {
    display: block;
    width: 100%;
    margin: 0 0 1.25rem;
    padding: 0.75rem;
    background: #ffffff;
    color: #000000;
    font-family: var(--font-family-app);
    font-weight: 700;
    font-size: clamp(0.95rem, 3.2vw, 1.1rem);
    letter-spacing: 0.02em;
    text-transform: uppercase;
    line-height: 1.3;
}

.contact-list {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.contact-item-phone {
    margin: 0 0 0.35rem;
    font-family: var(--font-family-app);
    font-size: 0.95rem;
    font-weight: normal;
    color: #ffffff;
    line-height: 1.45;
}

.contact-item-phone a {
    color: #ffffff;
    text-decoration: none;
}

.contact-item-email {
    margin: 0;
    font-family: var(--font-family-app);
    font-size: 0.95rem;
    line-height: 1.45;
}

.contact-item-email a {
    color: #ffffff;
    text-decoration: underline;
}

.contact-list-footer {
    margin: 1.5rem 0 0;
    font-family: var(--font-family-app);
    font-size: 0.95rem;
    line-height: 1.45;
}

.contact-list-footer a {
    color: #ffffff;
    text-decoration: underline;
}
