/* ============================================================
   estilos.css — Sistema de Voto Electrónico
   PeruvianHosting.Net
   Estilos compartidos para: index.php, bienvenida.php,
   votacion.php, confirmar.php
   ============================================================ */

/* ============================================================
   1. VARIABLES CSS GLOBALES
   ============================================================ */
:root {
    --brand-color: #2563EB; /* Sobreescrito dinámicamente por PHP en cada página */
    --brand-dark:  color-mix(in srgb, var(--brand-color), black 20%);
    --brand-light: color-mix(in srgb, var(--brand-color), white 85%);

    --surface-glass:        rgba(255, 255, 255, 0.85);
    --surface-glass-border: rgba(255, 255, 255, 0.60);

    --text-main:      #1e293b;
    --text-secondary: #64748b;

    --success: #10b981;
    --danger:  #ef4444;
    --mark-color: #059669;

    --border-color: #cbd5e1;

    --shadow-soft:   0 10px 40px -10px rgba(0,0,0,0.10);
    --shadow-glass:  0 8px  32px  0   rgba(31,38,135,0.15);
    --shadow-card:   0 4px  6px  -1px rgba(0,0,0,0.10),
                     0 2px  4px  -1px rgba(0,0,0,0.06);
    --shadow-selected: 0 20px 25px -5px rgba(0,0,0,0.10),
                       0 10px 10px -5px rgba(0,0,0,0.04);
}

/* ============================================================
   2. RESET / BASE
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }

body {
    font-family: 'Poppins', 'Segoe UI', system-ui, sans-serif;
    background: linear-gradient(135deg, #f0f4ff 0%, #e2e8f0 100%);
    min-height: 100vh;
    color: var(--text-main);
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    position: relative;
    margin: 0;
    padding: 0;
}

/* ============================================================
   3. FONDO ANIMADO (compartido por todas las páginas)
   ============================================================ */
body::before {
    content: '';
    position: fixed;
    top: -50%; left: -50%;
    width: 200%; height: 200%;
    background:
        radial-gradient(circle, var(--brand-light) 10%, transparent 20%),
        radial-gradient(circle, rgba(255,255,255,0.8) 10%, transparent 20%);
    background-size: 30px 30px;
    opacity: 0.6;
    z-index: -1;
    animation: moveBackground 60s linear infinite;
}

body::after {
    content: '';
    position: fixed;
    width: 80vw; height: 80vw;
    top: -20vw; right: -10vw;
    background: radial-gradient(circle, var(--brand-color) 0%, transparent 70%);
    opacity: 0.1;
    border-radius: 50%;
    z-index: -1;
    filter: blur(60px);
}

@keyframes moveBackground {
    0%   { transform: translate(0,    0   ); }
    100% { transform: translate(50px, 50px); }
}

/* ============================================================
   4. ANIMACIONES GLOBALES
   ============================================================ */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0);    }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0);    }
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(40px); }
    to   { opacity: 1; transform: translateY(0);    }
}

@keyframes scaleIn {
    from { transform: scale(0.9); opacity: 0; }
    to   { transform: scale(1);   opacity: 1; }
}

/* ============================================================
   5. TARJETA GLASS (index.php · bienvenida.php)
   ============================================================ */
.card {
    background: var(--surface-glass);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--surface-glass-border);
    border-radius: 24px;
    padding: 2.5rem;
    box-shadow: var(--shadow-glass);
    width: 100%;
    max-width: 600px;
    position: relative;
    overflow: hidden;
    animation: fadeUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 6px;
    background: linear-gradient(90deg, var(--brand-color), #8b5cf6);
}

/* ============================================================
   6. CABECERA / HEADER SECTION (index.php · bienvenida.php)
   ============================================================ */
.header-section {
    text-align: center;
    margin-bottom: 2rem;
}

.logo-img {
    height: 70px;
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 4px 6px rgba(0,0,0,0.1));
    transition: transform 0.3s;
}
.logo-img:hover { transform: scale(1.05); }

.title-primary {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--brand-color), #1e293b);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    line-height: 1.2;
    margin-bottom: 0.5rem;
}

.title-secondary {
    font-size: 1rem;
    color: var(--text-secondary);
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

/* ============================================================
   7. WRAPPER CENTRADO (index.php · bienvenida.php)
   ============================================================ */
.wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    width: 100%;
}

/* ============================================================
   8. HEADER STICKY GLASS (votacion.php · confirmar.php)
   ============================================================ */
.top-bar {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255,255,255,0.5);
    position: sticky;
    top: 0;
    z-index: 50;
    padding: 0.75rem 1.5rem;
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
}

.header-content {
    max-width: 1000px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.brand { display: flex; align-items: center; gap: 0.75rem; }

.brand-logo {
    width: 45px; height: 45px;
    border-radius: 10px;
    background: white;
    padding: 3px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    justify-content: center;
}
.brand-logo img { width: 100%; height: 100%; object-fit: contain; }

.brand-text h1 {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--brand-dark);
    line-height: 1.1;
    margin: 0;
}
.brand-text span { font-size: 0.8rem; color: #64748b; font-weight: 500; }

.elector-pill {
    background: rgba(255,255,255,0.9);
    border: 1px solid #e2e8f0;
    padding: 0.35rem 0.85rem;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 0.85rem;
    color: #334155;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

/* ============================================================
   9. BOTONES COMPARTIDOS
   ============================================================ */
.btn {
    padding: 1.2rem 1.5rem;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1rem;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    font-family: 'Montserrat', sans-serif;
    text-transform: uppercase;
    text-decoration: none;
}

.btn-primary {
    background: linear-gradient(135deg, var(--success), #059669);
    color: white;
    box-shadow: 0 8px 20px -5px rgba(16,185,129,0.4);
}
.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 25px -5px rgba(16,185,129,0.5);
}

.btn-cancel {
    background: transparent;
    color: var(--danger);
    border: 2px solid #fecaca;
}
.btn-cancel:hover {
    background: #fef2f2;
    border-color: var(--danger);
    transform: translateY(-3px);
}

.btn-secondary {
    background: transparent;
    color: var(--text-secondary);
    border: 2px solid #cbd5e1;
}
.btn-secondary:hover {
    border-color: var(--danger);
    color: var(--danger);
    background: #fef2f2;
}

/* Botón submit grande (index.php) */
.btn-submit {
    width: 100%;
    padding: 1.1rem;
    background: linear-gradient(135deg, var(--success), #059669);
    color: white;
    border: none;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    box-shadow: 0 4px 15px rgba(16,185,129,0.3);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-family: 'Montserrat', sans-serif;
}
.btn-submit:hover:not(:disabled) {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(16,185,129,0.4);
    filter: brightness(1.1);
}
.btn-submit:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    background: #94a3b8;
}

/* Botones de acción flotante (confirmar.php) */
.btn-action {
    padding: 1rem 2rem;
    border-radius: 50px;
    font-weight: 800;
    font-size: 1.1rem;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    font-family: 'Montserrat', sans-serif;
    text-transform: uppercase;
    text-decoration: none;
}
.btn-confirm {
    background: linear-gradient(135deg, var(--success), #059669);
    color: white;
    box-shadow: 0 8px 20px rgba(16,185,129,0.3);
}
.btn-confirm:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 30px rgba(16,185,129,0.4);
}

/* Botón votar (votacion.php) */
.btn-vote {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    border: none;
    padding: 1rem 3.5rem;
    font-family: 'Montserrat', sans-serif;
    font-size: 1.2rem;
    font-weight: 800;
    border-radius: 50px;
    cursor: pointer;
    box-shadow: 0 8px 20px rgba(16,185,129,0.4);
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}
.btn-vote:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 12px 30px rgba(16,185,129,0.5);
}

/* ============================================================
   10. MODALES COMPARTIDOS
   ============================================================ */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(8px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
}
.modal-overlay.show {
    opacity: 1;
    pointer-events: auto;
}

/* Variante siempre visible (bienvenida.php / confirmar.php cuando hay error) */
.modal-overlay-visible {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(8px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-box {
    background: white;
    border-radius: 24px;
    padding: 2.5rem;
    width: 90%;
    max-width: 480px;
    text-align: center;
    transform: scale(0.95);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    animation: scaleIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.modal-overlay.show .modal-box { transform: scale(1); }

.modal-box-danger  { border-top: 6px solid var(--danger);  }
.modal-box-success { border-top: 6px solid var(--success); }

.icon-circle {
    width: 80px; height: 80px;
    border-radius: 50%;
    margin: 0 auto 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
}
.icon-success { background: #ecfdf5; color: var(--success); }
.icon-error   { background: #fef2f2; color: var(--danger);  }

/* Ícono pequeño (bienvenida.php) */
.modal-icon {
    width: 70px; height: 70px;
    background: #fef2f2;
    color: var(--danger);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    margin: 0 auto 1.5rem;
}

/* Botón salir en modal (confirmar.php) */
.btn-modal-exit {
    display: block;
    width: 100%;
    margin-top: 1.5rem;
    padding: 0.8rem;
    border-radius: 12px;
    background: #f1f5f9;
    color: #64748b;
    text-align: center;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}
.btn-modal-exit:hover { background: #e2e8f0; color: #475569; }

/* ============================================================
   11. FOOTER (compartido por todas las páginas)
   ============================================================ */
footer {
    background: #1e293b;
    color: #94a3b8;
    padding: 0.8rem;
    font-size: 0.9rem;
    text-align: center;
    margin-top: auto;
    position: relative;
    z-index: 10;
}

.footer-content {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.footer-link {
    color: white;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s;
}
.footer-link:hover { color: var(--brand-color); }

.socials { display: flex; gap: 1rem; }
.socials a {
    color: white;
    background: rgba(255,255,255,0.1);
    width: 36px; height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s;
    text-decoration: none;
}
.socials a:hover {
    background: var(--brand-color);
    transform: translateY(-3px);
}

/* ============================================================
   12. FORMULARIO DE LOGIN (index.php)
   ============================================================ */
.form-group { margin-bottom: 1.5rem; }

.input-label {
    display: block;
    margin-bottom: 0.75rem;
    font-weight: 600;
    color: var(--text-main);
    font-size: 1rem;
    text-align: center;
}

.input-code {
    width: 100%;
    padding: 1rem;
    font-family: 'Roboto Mono', monospace;
    font-size: 2rem;
    text-align: center;
    letter-spacing: 0.5rem;
    text-transform: uppercase;
    border: 2px solid #e2e8f0;
    border-radius: 16px;
    background: rgba(255,255,255,0.9);
    color: var(--text-main);
    font-weight: 700;
    transition: all 0.3s ease;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.05);
}
.input-code:focus {
    outline: none;
    border-color: var(--brand-color);
    box-shadow: 0 0 0 4px var(--brand-light);
    transform: translateY(-2px);
}
.input-code::placeholder {
    color: #cbd5e1;
    letter-spacing: 0.2rem;
    font-size: 1.5rem;
}

/* Alerta de estado (index.php) */
.status-alert {
    background: rgba(255,255,255,0.9);
    border-left: 4px solid var(--brand-color);
    padding: 1rem 1.25rem;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    color: var(--text-main);
    font-size: 0.95rem;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}
.status-alert i {
    color: var(--brand-color);
    font-size: 1.25rem;
    margin-top: 2px;
}

/* Contador regresivo (index.php) */
.timer-card {
    background: rgba(255,255,255,0.6);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 1.5rem;
    text-align: center;
    border: 1px solid rgba(255,255,255,0.5);
    animation: fadeUp 0.8s cubic-bezier(0.2,0.8,0.2,1) 0.2s backwards;
}

.countdown-grid {
    display: flex;
    justify-content: center;
    gap: 0.8rem;
    margin-top: 1rem;
}

.time-box {
    background: white;
    padding: 0.8rem 0.5rem;
    border-radius: 12px;
    min-width: 65px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.time-val {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--brand-color);
    font-family: 'Roboto Mono', monospace;
    line-height: 1;
}

.time-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    color: var(--text-secondary);
    margin-top: 0.3rem;
    font-weight: 600;
}

/* ============================================================
   13. BIENVENIDA — Verificación de identidad (bienvenida.php)
   ============================================================ */
.identity-check-title {
    text-align: center;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--brand-color);
    font-weight: 700;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    opacity: 0.9;
}
.identity-check-title::before,
.identity-check-title::after {
    content: '';
    height: 2px;
    width: 20px;
    background-color: var(--brand-color);
    opacity: 0.3;
    border-radius: 2px;
}

/* Tarjeta de perfil (bienvenida.php) */
.profile-card {
    background: white;
    border-radius: 20px;
    padding: 2rem;
    box-shadow: 0 10px 30px -5px rgba(0,0,0,0.05);
    border: 1px solid rgba(226,232,240,0.8);
    margin-bottom: 2rem;
    position: relative;
    overflow: hidden;
}
.profile-card::after {
    content: '';
    position: absolute;
    top: 0; right: 0;
    width: 150px; height: 150px;
    background: linear-gradient(135deg, var(--brand-light), transparent);
    border-radius: 0 0 0 100%;
    opacity: 0.5;
}

.profile-header {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 2rem;
    position: relative;
    z-index: 1;
}

.avatar-circle {
    width: 80px; height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--brand-color), #6366f1);
    color: white;
    font-size: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 20px -5px rgba(37,99,235,0.4);
    border: 4px solid white;
}

.profile-welcome h3 {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-secondary);
    font-weight: 700;
    margin-bottom: 0.2rem;
}

.profile-name {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--text-main);
    line-height: 1.2;
}

.details-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    position: relative;
    z-index: 1;
}

.detail-item {
    background: #f8fafc;
    padding: 1rem;
    border-radius: 12px;
    border-left: 3px solid var(--brand-color);
    transition: transform 0.2s;
}
.detail-item:hover { transform: translateY(-2px); background: #f1f5f9; }

.detail-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    color: var(--text-secondary);
    font-weight: 600;
    margin-bottom: 0.25rem;
    display: block;
}

.detail-value {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-main);
    font-family: 'Roboto Mono', monospace;
}

/* Contenedor de acciones (bienvenida.php) */
.actions-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.info-note {
    text-align: center;
    margin-top: 1.5rem;
    font-size: 0.85rem;
    color: #94a3b8;
}

/* ============================================================
   14. CONFIRMAR — Tarjeta de confirmación (confirmar.php)
   ============================================================ */
.confirm-card {
    background: rgba(255,255,255,0.9);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    padding: 0.5rem 2.5rem 2rem 2.5rem;
    box-shadow: 0 20px 60px -10px rgba(0,0,0,0.15);
    border: 1px solid rgba(255,255,255,0.8);
    position: relative;
    animation: slideUp 0.6s cubic-bezier(0.2,0.8,0.2,1);
}

.card-title { text-align: center; }
.card-title h2 {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--brand-color);
    margin-bottom: 0.5rem;
}
.card-title p { color: var(--text-secondary); font-size: 1rem; }

/* Lista seleccionada */
.selected-party {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 0.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px dashed #e2e8f0;
}

.party-logo-lg {
    width: 80px; height: 80px;
    object-fit: contain;
    background: white;
    padding: 5px;
    border-radius: 12px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.party-name-lg {
    font-family: 'Oswald', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--text-main);
    line-height: 1;
}

/* Líder */
.leader-box {
    background: linear-gradient(to right, #ffffff, var(--brand-light));
    border-left: 5px solid var(--brand-color);
    border-radius: 12px;
    padding: 0.5rem 1.5rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
}

.leader-img {
    width: 80px; height: 80px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid white;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.leader-info h3 {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 0.2rem;
}

.role-badge {
    background: var(--brand-color);
    color: white;
    padding: 0.2rem 0.8rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

/* Equipo de trabajo — 2 columnas */
.team-label {
    font-size: 0.8rem;
    font-weight: 700;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.5rem;
    display: block;
}

.team-split-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
    align-items: start;
}

.team-column {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.member-card {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 0.4rem 0.6rem;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    transition: transform 0.2s;
    overflow: hidden;
}

.member-number {
    width: 28px; height: 28px;
    border-radius: 50%;
    background: #f1f5f9;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--brand-color);
    font-weight: 800;
    font-size: 0.9rem;
    flex-shrink: 0;
    border: 1px solid #e2e8f0;
}

.member-details {
    flex: 1;
    overflow: hidden;
    min-width: 0;
}
.member-details h4 {
    font-size: 0.9rem;
    font-weight: 600;
    color: #334155;
    line-height: 1.1;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.member-role {
    font-size: 0.7rem;
    color: var(--brand-color);
    font-weight: 700;
    text-transform: uppercase;
    display: block;
    margin-bottom: 1px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Voto en blanco (confirmar.php) */
.white-vote-box {
    text-align: center;
    padding: 3rem;
    background: #f8fafc;
    border: 2px dashed #cbd5e1;
    border-radius: 20px;
}
.white-vote-icon { font-size: 4rem; color: #cbd5e1; margin-bottom: 1rem; }

/* Barra flotante inferior (confirmar.php / votacion.php) */
.bottom-action {
    position: fixed;
    bottom: 0; left: 0;
    width: 100%;
    background: rgba(255,255,255,0.9);
    backdrop-filter: blur(16px);
    padding: 1.25rem;
    border-top: 1px solid rgba(255,255,255,0.8);
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    box-shadow: 0 -4px 30px rgba(0,0,0,0.1);
    z-index: 100;
}

/* Variante votacion.php (oculta hasta selección) */
.bottom-action-hidden {
    transform: translateY(120%);
    transition: transform 0.4s ease;
}
.bottom-action-hidden.visible { transform: translateY(0); }

/* ============================================================
   15. CÉDULA DE SUFRAGIO (votacion.php)
   ============================================================ */
.main-container {
    position: relative;
    z-index: 1;
    max-width: 900px;
    margin: 1.5rem auto;
    padding: 0 1rem;
}

.instruction { text-align: center; animation: fadeIn 0.8s ease; }
.instruction h2 {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--brand-dark);
    margin-bottom: 0.25rem;
}
.instruction p { font-size: 1rem; color: #64748b; }

.ballot-container { display: flex; flex-direction: column; gap: 0.3rem; }

.option-card {
    display: block;
    position: relative;
    cursor: pointer;
    transition: transform 0.2s cubic-bezier(0.34,1.56,0.64,1);
    -webkit-tap-highlight-color: transparent;
}
.option-card:hover { transform: scale(1.01); }
.option-card input[type="radio"] { display: none; }

.card-inner {
    display: grid;
    grid-template-columns: 1fr 140px 140px;
    background: rgba(255,255,255,0.7);
    backdrop-filter: blur(10px);
    border: 2px solid var(--border-color);
    border-radius: 16px;
    overflow: hidden;
    min-height: 10px;
    box-shadow: var(--shadow-card);
    transition: all 0.3s ease;
}

.option-card input:checked + .card-inner {
    border-color: var(--mark-color);
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(5,150,105,0.2), var(--shadow-selected);
    transform: translateY(-2px);
}

.section-info {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    border-right: 1px dashed var(--border-color);
}

.section-box {
    position: relative;
    border-right: 1px dashed var(--border-color);
    background: rgba(248,250,252,0.5);
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
}
.section-box:last-child { border-right: none; }
.option-card input:checked + .card-inner .section-box { background: #fff; }

.party-name {
    font-family: 'Oswald', sans-serif;
    font-size: 1.25rem;
    font-weight: 700;
    text-transform: uppercase;
    color: #0f172a;
    line-height: 1.1;
    margin-bottom: 0.5rem;
}

.candidate-name {
    font-size: 0.95rem;
    color: #64748b;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.img-wrapper {
    width: 100%; height: 100%;
    max-height: 110px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.img-fit {
    width: 100%; height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1));
    transition: opacity 0.3s;
}

.placeholder-icon { font-size: 4.5rem; color: #cbd5e1; }

/* Marca ✗ al seleccionar */
.x-mark {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%) scale(0) rotate(-45deg);
    font-size: 7rem;
    line-height: 0;
    font-weight: 900;
    pointer-events: none;
    z-index: 10;
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.175,0.885,0.32,1.275);
    color: #059669;
    text-shadow:
        2px  2px  0 #fff, -1px -1px 0 #fff,
        1px -1px  0 #fff, -1px  1px 0 #fff,
        0 0 10px rgba(255,255,255,0.8);
}
.option-card input:checked + .card-inner .x-mark {
    transform: translate(-50%, -50%) scale(1) rotate(0deg);
    opacity: 1;
}
.option-card input:checked + .card-inner .img-fit { opacity: 0.7; }

/* Voto en blanco (votacion.php) */
.voto-blanco .card-inner { border-style: dashed; background: rgba(255,255,255,0.5); }
.voto-blanco .party-name { color: #475569; font-style: italic; }

/* ============================================================
   16. GRID LAYOUT (index.php)
   ============================================================ */
.grid-container {
    display: grid;
    gap: 2rem;
    width: 100%;
    grid-template-columns: minmax(0, 1fr);
    align-items: center;
    justify-items: center;
}

/* ============================================================
   17. WRAPPER PARA CONFIRMAR Y VOTACION
   ============================================================ */
.wrapper-confirm {
    max-width: 900px;
    margin: 2rem auto;
    padding: 0 1rem;
    animation: slideUp 0.6s cubic-bezier(0.2,0.8,0.2,1);
}

/* ============================================================
   18. RESPONSIVE
   ============================================================ */
@media (min-width: 768px) {
    .footer-content {
        flex-direction: row;
        justify-content: space-between;
    }
    .title-primary { font-size: 1.75rem; }
}

@media (min-width: 1024px) {
    .grid-container.has-sidebar {
        grid-template-columns: 1.2fr 0.8fr;
    }
}

@media (max-width: 768px) {
    /* Header */
    .header-content  { flex-direction: column; gap: 0.5rem; }
    .brand-text h1   { font-size: 1rem; }
    .elector-pill    { font-size: 0.75rem; padding: 0.2rem 0.6rem; }

    /* Bienvenida */
    .card            { padding: 1.5rem; }
    .profile-header  { flex-direction: column; text-align: center; gap: 1rem; }
    .details-grid    { grid-template-columns: 1fr; gap: 0.8rem; }
    .actions-container { grid-template-columns: 1fr; gap: 1rem; }
    .actions-container form { order: 1; }
    .actions-container a    { order: 2; }
    .btn             { width: 100%; }

    /* Confirmar */
    .selected-party  { flex-direction: column; gap: 0.5rem; text-align: center; }
    .leader-box      { flex-direction: column; text-align: center; gap: 1rem; }
    .team-split-container { grid-template-columns: 1fr; }
    .bottom-action   { flex-direction: column-reverse; padding: 1rem; gap: 1rem; }
    .btn-action      { width: 100%; justify-content: center; }

    /* Votacion */
    .card-inner {
        grid-template-columns: 1fr 1fr;
        grid-template-rows: auto 140px;
    }
    .section-info {
        grid-column: 1 / -1;
        border-right: none;
        border-bottom: 1px dashed var(--border-color);
        padding: 1rem;
        text-align: center;
    }
    .candidate-name  { justify-content: center; }
    .section-box     { height: 100%; }
    .section-box:nth-child(2) { border-right: 1px dashed var(--border-color); }
    .btn-vote        { width: 100%; justify-content: center; padding: 1rem; font-size: 1.1rem; }
    .x-mark          { font-size: 5rem; }
}