/* ═══════════════════════════════════════════════
   AilinRos Ciudadanía App — CSS UNIFICADO V2 (FIXED)
   ═══════════════════════════════════════════════ */

:root {
    --navy:    #002868;
    --red:     #bf0a30;
    --gold:    #FFD700;
    --green:   #2E7D32;
    --bg:      #f4f6fb;
    --card:    #ffffff;
    --border:  #e8ecf4;
    --text:    #1a1a2e;
    --muted:   #6b7280;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
}

.app-container {
    max-width: 480px;
    margin: 0 auto;
    padding: 16px 16px 40px;
}

/* ── DASHBOARD HEADER ── */
.dashboard-header {
    display: flex; justify-content: space-between; align-items: center;
    background: var(--navy); color: white; padding: 18px 20px;
    border-radius: 20px; margin-bottom: 12px;
}
.user-info { display: flex; align-items: center; gap: 12px; }
.avatar {
    width: 44px; height: 44px; background: var(--red); border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 20px; font-weight: 800;
}
.stats-pills { display: flex; flex-direction: column; gap: 6px; align-items: flex-end; }
.pill {
    background: rgba(255,255,255,.18); border: 1px solid rgba(255,255,255,.25);
    padding: 4px 10px; border-radius: 20px; font-size: 13px; font-weight: 700;
}

/* ── MODAL RECONOCIMIENTO (SISTEMA AISLADO) ── */
.modal-full { 
    display: none; position: fixed; z-index: 10000; 
    left: 0; top: 0; width: 100%; height: 100%; 
    background: rgba(0,0,0,0.9); justify-content: center; align-items: center; 
}

.modal-content-9-16 { 
    position: relative; width: 90vw; max-width: 360px; 
    height: 80vh; max-height: 600px; border-radius: 25px; 
    padding: 30px 20px; text-align: center; color: white; 
    display: flex; flex-direction: column; justify-content: space-between;
    overflow: hidden;
}

.modal-content-9-16.oro { background: linear-gradient(180deg, #002868 0%, #001235 100%); border: 3px solid var(--gold); }

/* Arreglo de la Bandera */
.header-recon .usa-flag { 
    width: 80px !important; /* Tamaño fijo para que no explote */
    height: auto; 
    margin: 0 auto 10px;
    display: block;
}

.brand-line { font-weight: 800; font-size: 1.1rem; margin-bottom: 2px; display: block; }
.web-top { font-size: 0.8rem; opacity: 0.8; display: block; margin-bottom: 15px; }
.e-gigante { font-size: 80px; display: block; margin: 10px 0; }
.n-alumno { font-size: 2rem; font-weight: 900; text-transform: uppercase; margin-bottom: 5px; }
.b-rango { display: inline-block; padding: 6px 20px; background: rgba(255,255,255,0.2); border-radius: 50px; font-weight: bold; }

/* ── BANNER DEL DASHBOARD ── */
.banner-logro {
    display: flex; align-items: center; gap: 12px;
    padding: 15px; border-radius: 16px; margin: 15px 0;
    background: #fff; border: 1.5px solid var(--border);
}
.banner-logro a { color: var(--navy); font-weight: 700; cursor: pointer; text-decoration: underline; }

/* ── GRID DE MÓDULOS ── */
.module-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 15px; }
.module-item {
    background: #fff; border: 1.5px solid var(--border); border-radius: 16px;
    padding: 20px; text-align: center; text-decoration: none; color: var(--text);
    display: flex; flex-direction: column; align-items: center; gap: 8px;
}
.mod-icon { font-size: 30px; display: block; }

/* ── RANKING ── */
.ranking-container { background: var(--navy); color: white; border-radius: 20px; padding: 15px; margin-top: 10px; }
.rank-row { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid rgba(255,255,255,0.1); }

/* ── ESTILOS EXAMEN (PARA QUE NO SE ROMPAN LAS LECCIONES) ── */
.question-card { background: #fff; padding: 20px; border-radius: 20px; border: 1.5px solid var(--border); margin-top: 20px; }
.option { 
    display: block; width: 100%; padding: 12px; margin-bottom: 10px; 
    border-radius: 12px; border: 2px solid var(--border); background: #fff;
    text-align: left; font-weight: 600;
}