/* ================================================================
   BASE
   ================================================================ */
body {
    font-family: 'Inter', sans-serif;
    background: #1e3c72;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #333;
}

/* ================================================================
   LOGIN BACKGROUND SLIDESHOW
   ================================================================ */
.login-bg-slideshow {
    position: fixed;
    inset: 0;
    z-index: -1;
    overflow: hidden;
}

.login-bg-slide {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0;
    transition: opacity 1.5s ease-in-out;
}

.login-bg-slide.active {
    opacity: 1;
}

.login-bg-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg,
            rgba(30, 60, 114, 0.65) 0%,
            rgba(42, 82, 152, 0.50) 100%);
    z-index: 1;
}

/* ================================================================
   LOGIN CARD (vista de acceso)
   ================================================================ */

.zoom-in {
    animation: zoomIn 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes zoomIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.glass-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    padding: 40px;
    width: 100%;
    max-width: 450px;
    transition: transform 0.3s ease;
}

.glass-card:hover {
    transform: translateY(-5px);
}

.form-control {
    border-radius: 10px;
    padding: 12px 20px;
    border: 1px solid #ced4da;
    transition: all 0.3s ease;
}

.form-control:focus {
    box-shadow: 0 0 0 0.25rem rgba(42, 82, 152, 0.25);
    border-color: #2a5298;
}

.btn-primary {
    background-color: #2a5298;
    border: none;
    border-radius: 10px;
    padding: 12px;
    font-weight: 600;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background-color: #1e3c72;
    transform: scale(1.02);
    box-shadow: 0 5px 15px rgba(30, 60, 114, 0.4);
}

.brand-logo {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #2a5298 0%, #1e3c72 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    color: #fff;
    font-size: 32px;
    box-shadow: 0 10px 20px rgba(30, 60, 114, 0.3);
}

/* ================================================================
   VISTA CONFIRMAR ASISTENCIA — LAYOUT GENERAL
   ================================================================ */
.confirmar-page {
    background: #f0f4fc;
    min-height: 100vh;
    width: 100%;
    display: flex;
    align-items: flex-start;
    justify-content: center;
}

/* ================================================================
   HERO BANNER
   ================================================================ */
#hero {
    width: 100%;
    min-height: 260px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    border-radius: 0 0 32px 32px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(30, 60, 114, 0.25);
}

#hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom,
            rgba(30, 60, 114, 0.15) 0%,
            rgba(30, 60, 114, 0.55) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    padding: 40px 24px;
    max-width: 1200px;
    margin: 0 auto;
}

.hero-title {
    font-size: 2.4rem;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
    margin-bottom: 8px;
    line-height: 1.2;
}

.hero-slogan {
    font-size: 1.3rem;
    font-weight: 400;
    color: #fff;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    margin-bottom: 0;
}

.hero-details {
    font-size: .8rem;
    font-weight: 400;
    color: #fff;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    margin-bottom: 0;
}

/* ================================================================
   TARJETA PRINCIPAL DEL EVENTO
   ================================================================ */
.event-card {
    background: #fff;
    border-radius: 24px;
    box-shadow: 0 8px 40px rgba(30, 60, 114, 0.12);
    margin: -40px 24px 32px;
    padding: 0;
    overflow: hidden;
    position: relative;
    z-index: 10;
}

/* ================================================================
   COLUMNA DE IMÁGENES DEL EVENTO
   ================================================================ */
.event-images-col {
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0;
    background: #f7f9ff;
    border-right: 1px solid #e4eaf7;
}

.event-img-item {
    width: 100%;
    aspect-ratio: 4/3;
    object-fit: cover;
    display: block;
    transition: transform 0.35s ease;
}

.event-img-item:hover {
    transform: scale(1.02);
}

/* ================================================================
   COLUMNA DE INFORMACIÓN DEL EVENTO
   ================================================================ */
.event-info-col {
    padding: 36px 36px 28px;
}

.event-titulo {
    font-size: 1.65rem;
    font-weight: 700;
    color: #1e3c72;
    line-height: 1.25;
    margin-bottom: 4px;
}

.event-slogan {
    font-size: 1.05rem;
    font-weight: 400;
    color: #5a7abf;
    margin-bottom: 20px;
}

.event-detalles {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 24px;
    padding: 16px 20px;
    background: #f4f7ff;
    border-radius: 14px;
    border-left: 4px solid #2a5298;
}

.event-detalle-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 0.9rem;
    color: #374151;
}

.event-detalle-item i {
    color: #2a5298;
    font-size: 1rem;
    margin-top: 2px;
    flex-shrink: 0;
}

.event-detalle-item span {
    line-height: 1.5;
}

/* ================================================================
   FIELDSET — MODIFICAR NOMBRE
   ================================================================ */
.nombre-fieldset {
    border: 1.5px solid #d1daf5;
    border-radius: 14px;
    padding: 20px 20px 12px;
    margin-top: 8px;
    background: #f8faff;
}

.nombre-fieldset legend {
    font-size: 0.85rem;
    font-weight: 600;
    color: #2a5298;
    padding: 0 8px;
    width: auto;
}

.nombre-fieldset label {
    font-size: 0.82rem;
    font-weight: 600;
    color: #4b5563;
    margin-bottom: 4px;
}

.nombre-fieldset .form-control {
    padding: 9px 14px;
    font-size: 0.9rem;
}

/* ================================================================
   SELFIE — ÓVALO CLICKEABLE
   ================================================================ */
.selfie-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 4px 0 20px;
}

.selfie-label {
    font-size: 0.88rem;
    font-weight: 600;
    color: #2a5298;
    margin-bottom: 10px;
    letter-spacing: 0.3px;
}

.selfie-oval-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    user-select: none;
}

.selfie-oval {
    position: relative;
    width: 130px;
    height: 160px;
    border-radius: 50%;
    overflow: visible;
    transition: transform 0.25s ease;
}

.selfie-oval-container:hover .selfie-oval {
    transform: scale(1.06);
}

.selfie-oval-inner {
    width: 130px;
    height: 160px;
    border-radius: 50%;
    overflow: hidden;
    background: linear-gradient(145deg, #e8edf8, #c8d4ef);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 1;
    box-shadow: 0 4px 20px rgba(42, 82, 152, 0.18);
}

.selfie-ring {
    position: absolute;
    inset: -5px;
    border-radius: 50%;
    background: conic-gradient(#2a5298, #6a9fd8, #1e3c72, #2a5298);
    z-index: 0;
    animation: girar-anillo 3s linear infinite;
}

@keyframes girar-anillo {
    to {
        transform: rotate(360deg);
    }
}

.selfie-oval.capturado .selfie-ring {
    background: conic-gradient(#28a745, #6fcf97, #155724, #28a745);
}

.selfie-icon {
    font-size: 3rem;
    color: #2a5298;
    opacity: 0.7;
}

.selfie-thumbnail {
    width: 130px;
    height: 160px;
    object-fit: cover;
    border-radius: 50%;
}

.selfie-click-hint {
    font-size: 0.78rem;
    color: #6c757d;
    font-weight: 500;
    letter-spacing: 0.2px;
}

.selfie-status {
    font-size: 0.82rem;
    margin-top: 4px;
}

/* ================================================================
   MODAL — CÁMARA
   ================================================================ */
.modal-backdrop {
    z-index: 9 !important;
}

.camara-modal-content {
    border: none;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

.camara-modal-header {
    background: linear-gradient(135deg, #1e3c72, #2a5298);
    color: #fff;
    border-bottom: none;
    padding: 16px 20px;
}

.camara-modal-body {
    background: #0d1117;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    overflow: hidden;
    /* evita que elementos internos desborden hacia el footer */
}

.camara-modal-footer {
    background: #161b22;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    justify-content: center;
    gap: 12px;
    padding: 14px 20px;
    position: relative;
    /* crea contexto de apilamiento propio */
    z-index: 1;
    /* asegura que los botones queden sobre cualquier desbordamiento */
}

.camara-instruccion {
    color: #c9d1d9;
    font-size: 0.88rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
}

.camara-viewport-wrapper {
    position: relative;
    display: inline-flex;
    justify-content: center;
    pointer-events: none;
    /* el stream + canvas no deben interceptar clics */
}

.camara-oval-frame {
    position: relative;
    width: 300px;
    height: 360px;
    border-radius: 50%;
    overflow: hidden;
    background: #000;
    box-shadow: 0 0 0 4px rgba(42, 82, 152, 0.6), 0 0 30px rgba(42, 82, 152, 0.3);
}

#camara-video {
    position: absolute;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scaleX(-1);
    border-radius: 50%;
}

#camara-canvas-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transform: scaleX(-1);
    pointer-events: none;
    border-radius: 50%;
}

.face-guide-oval {
    position: absolute;
    inset: 8px;
    border-radius: 50%;
    border: 2.5px dashed rgba(255, 255, 255, 0.35);
    pointer-events: none;
    transition: border-color 0.4s, box-shadow 0.4s;
}

.face-guide-oval.detectado {
    border-color: #28a745;
    border-style: solid;
    box-shadow: 0 0 20px rgba(40, 167, 69, 0.5);
    animation: pulso-verde 1s ease-in-out infinite alternate;
}

@keyframes pulso-verde {
    from {
        box-shadow: 0 0 10px rgba(40, 167, 69, 0.4);
    }

    to {
        box-shadow: 0 0 28px rgba(40, 167, 69, 0.8);
    }
}

/* ---- Estado detector ---- */
.camara-detector-estado {
    font-size: 0.85rem;
    font-weight: 600;
    padding: 6px 18px;
    border-radius: 20px;
    transition: background 0.3s, color 0.3s;
}

.estado-iniciando {
    background: rgba(255, 255, 255, 0.07);
    color: #8b949e;
}

.estado-buscando {
    background: rgba(255, 193, 7, 0.15);
    color: #ffc107;
}

.estado-detectado {
    background: rgba(40, 167, 69, 0.20);
    color: #28a745;
}

.estado-multiple {
    background: rgba(220, 53, 69, 0.20);
    color: #dc3545;
}

.estado-error {
    background: rgba(220, 53, 69, 0.15);
    color: #dc3545;
}

/* ---- Botón capturar ---- */
#btn-capturar {
    border-radius: 10px;
    padding: 10px 28px;
    font-weight: 600;
    letter-spacing: 0.3px;
    transition: all 0.25s;
}

#btn-capturar:not(:disabled):hover {
    transform: scale(1.04);
    box-shadow: 0 6px 18px rgba(40, 167, 69, 0.4);
}

/* ================================================================
   CONSULTA DE CÉDULA — estados del div #datosDeCedula
   ================================================================ */
#datosDeCedula {
    width: 100%;
}

.cedula-cargando {
    display: flex;
    align-items: center;
    padding: 10px 14px;
    font-size: 0.87rem;
    color: #6c757d;
    background: #f4f7ff;
    border-radius: 10px;
    border: 1px dashed #c1d0f0;
    animation: fadeIn 0.25s ease;
}

.cedula-error {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 14px;
    font-size: 0.85rem;
    color: #856404;
    background: #fff9e6;
    border-radius: 10px;
    border: 1px solid #fce8a0;
    animation: fadeIn 0.25s ease;
}

.cedula-result-card {
    background: linear-gradient(135deg, #f0f7ff 0%, #e8f0fd 100%);
    border: 1.5px solid #c8d8f8;
    border-radius: 12px;
    padding: 12px 16px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    animation: slideInUp 0.3s ease;
    box-shadow: 0 2px 12px rgba(42, 82, 152, 0.08);
}

.cedula-result-nombre {
    font-size: 0.95rem;
    font-weight: 700;
    color: #1e3c72;
    border-bottom: 1px solid #d1daf5;
    padding-bottom: 8px;
    margin-bottom: 2px;
}

.cedula-detalle-item {
    display: flex;
    gap: 6px;
    font-size: 0.82rem;
    line-height: 1.4;
}

.cedula-detalle-label {
    font-weight: 600;
    color: #2a5298;
    white-space: nowrap;
    flex-shrink: 0;
}

.cedula-detalle-valor {
    color: #374151;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ================================================================
   FOOTER — SITE FOOTER
   ================================================================ */
.site-footer {
    position: relative;
    background: linear-gradient(160deg, #0f1f45 0%, #1a3264 45%, #0e1b3a 100%);
    color: #c5d5f0;
    padding: 0;
    margin-top: 40px;
    overflow: hidden;
}

/* Brillo decorativo superior */
.footer-glow-top {
    height: 3px;
    background: linear-gradient(90deg,
            transparent 0%,
            #4a7dd4 20%,
            #6fa3e8 50%,
            #4a7dd4 80%,
            transparent 100%);
    width: 100%;
}

.footer-body {
    padding: 48px 40px 40px;
}

/* ---- Columnas ---- */
.footer-col {
    display: flex;
    flex-direction: column;
}

.footer-col--center {
    align-items: center;
    text-align: center;
}

.footer-col--right {
    align-items: flex-end;
    text-align: right;
}

/* ---- Marca / Evento ---- */
.footer-brand {
    display: flex;
    align-items: flex-start;
    gap: 14px;
}

.footer-brand-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: linear-gradient(135deg, #2a5298, #4a7dd4);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    color: #fff;
    box-shadow: 0 4px 16px rgba(42, 82, 152, 0.45);
}

.footer-evento-nombre {
    font-size: 1rem;
    font-weight: 700;
    color: #e8f0ff;
    margin: 0 0 4px;
    line-height: 1.3;
}

.footer-evento-slogan {
    font-size: 0.8rem;
    color: #7a9dd0;
    margin: 0;
    font-style: italic;
}

/* ---- Títulos de sección ---- */
.footer-section-title {
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: #7a9dd0;
    margin-bottom: 18px;
}

/* ---- Redes sociales ---- */
.footer-social-links {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
}

.footer-social-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    font-size: 1.15rem;
    color: #c5d5f0;
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.10);
    text-decoration: none;
    transition: transform 0.25s ease, background 0.25s ease, box-shadow 0.25s ease, color 0.25s ease;
}

.footer-social-btn:hover {
    transform: translateY(-4px) scale(1.08);
    color: #fff;
}

.footer-social-btn--facebook:hover {
    background: #1877f2;
    box-shadow: 0 6px 18px rgba(24, 119, 242, 0.45);
}

.footer-social-btn--x:hover {
    background: #000;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.55);
}

.footer-social-btn--instagram:hover {
    background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
    box-shadow: 0 6px 18px rgba(220, 39, 67, 0.45);
}

.footer-social-btn--tiktok:hover {
    background: #010101;
    box-shadow: 0 6px 18px rgba(105, 201, 208, 0.4);
}

.footer-social-btn:not([class*="--"]):hover {
    background: #2a5298;
    box-shadow: 0 6px 18px rgba(42, 82, 152, 0.45);
}

/* ---- Contacto ---- */
.footer-contact-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: flex-end;
}

.footer-contact-list li {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.88rem;
    color: #b8ccee;
}

.footer-contact-list li i {
    font-size: 0.95rem;
    color: #4a7dd4;
    flex-shrink: 0;
}

.footer-contact-list a {
    color: #b8ccee;
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-contact-list a:hover {
    color: #fff;
    text-decoration: underline;
}

/* ---- Copyright ---- */
.footer-copyright {
    border-top: 1px solid rgba(255, 255, 255, 0.07);
    padding: 16px 40px;
    text-align: center;
    font-size: 0.78rem;
    color: #5a7aaa;
    background: rgba(0, 0, 0, 0.2);
}

/* ---- Responsive ---- */
@media (max-width: 768px) {
    .footer-body {
        padding: 36px 20px 28px;
    }

    .footer-col--center,
    .footer-col--right {
        align-items: flex-start;
        text-align: left;
    }

    .footer-contact-list {
        align-items: flex-start;
    }

    .footer-copyright {
        padding: 14px 20px;
    }
}