/* CONFIGURACIÓN GENERAL Y VARIABLES INTEGRADAS */
:root {
    /* PALETA ADAPTADA Y EQUILIBRADA EN CONTRASTE */
    --color-primary-dark: #050259;  /* Azul Medianoche (Estructuras principales, títulos) */
    --color-accent-yellow: #F2E205; /* Amarillo Vibrante (Medallas, detalles y llamadas secundarias) */
    --color-accent-red: #F20707;    /* Rojo Puro (Botones prioritarios, alertas críticas) */
    --color-soft-purple: #7A6DA6;   /* Lila Grisáceo (Textos auxiliares, bordes fluidos) */
    --color-light-bg: #F2F2F2;      /* Gris Técnico Claro (Lienzo de fondo impecable) */
    
    /* VARIANTES COMPLEMENTARIAS */
    --color-white: #ffffff;
    --color-red-hover: #c90404;
    --color-blue-hover: #0b0785;
    --color-purple-light: #f3f1f7;  /* Variante sutil para fondos de tarjetas */
    --color-blue-light: #eaebf5;

    /* TEXTOS Y ARQUITECTURA */
    --text-main: #020122;           /* Contraste ultra-oscuro para lectura fluida */
    --text-muted: #735849;          /* Lila oscuro para jerarquía secundaria */
    --card-shadow: 0 8px 24px rgba(5, 2, 89, 0.06);
    --font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-family);
    background-color: var(--color-light-bg);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

.container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
}

/* MOTOR DE DESPLAZAMIENTO FLUIDO (JS INSERTS REVEAL) */
.section {
    padding: 60px 0;
    border-bottom: 1px solid #e1e1e1;
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.25, 1, 0.5, 1);
}

.section.reveal {
    opacity: 1;
    transform: translateY(0);
}

.section-title {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 40px;
    color: var(--color-primary-dark);
    position: relative;
    font-weight: 700;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background-color: var(--color-accent-red);
    border-radius: 2px;
}

/* DISPOSICIONES EN REJILLA */
.grid-4 { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 20px; }
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 30px; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 20px; }

/* HERO (ENCABEZADO DE IMPACTO) */
.hero {
    position: relative;
    background: url('images/docentes.jpg') no-repeat center center/cover;
    color: var(--color-white);
    text-align: center;
    padding: 80px 20px;
}

.hero-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(135deg, rgba(5, 2, 89, 0.94), rgba(122, 109, 166, 0.8));
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    margin: 0 auto;
}

.logo-container {
    margin-bottom: 15px;
}

.institution-logo {
    max-height: 110px;
    width: auto;
    filter: drop-shadow(0px 4px 10px rgba(0,0,0,0.4));
}

.badge {
    background-color: var(--color-accent-yellow);
    color: var(--color-primary-dark);
    padding: 6px 18px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: bold;
    display: inline-block;
    margin-bottom: 20px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.hero h1 {
    font-size: 3.8rem;
    letter-spacing: 1px;
    margin-bottom: 5px;
    font-weight: 800;
    text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
}

.hero h2 {
    font-size: 1.8rem;
    font-weight: 400;
    margin-bottom: 15px;
    color: var(--color-light-bg);
}

.slogan {
    font-style: italic;
    font-size: 1.2rem;
    color: var(--color-purple-light);
    margin-bottom: 35px;
}

/* BOTÓN DE ACCIÓN CORREGIDO */
.btn-primary {
    background-color: var(--color-accent-red);
    color: var(--color-white);
    border: none;
    padding: 15px 32px;
    font-size: 1.05rem;
    font-weight: bold;
    border-radius: 30px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 5px 20px rgba(242, 7, 7, 0.4);
}

.btn-primary:hover {
    background-color: var(--color-red-hover);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(242, 7, 7, 0.5);
}

.hero-info-bar {
    margin-top: 50px;
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
    background: rgba(255, 255, 255, 0.12);
    padding: 18px;
    border-radius: 50px;
    backdrop-filter: blur(8px);
    font-size: 0.95rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* TARJETAS DE OBJETIVOS */
.card {
    background: var(--color-white);
    padding: 25px;
    border-radius: 12px;
    box-shadow: var(--card-shadow);
    text-align: center;
    border: 1px solid #e8e8e8;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(5, 2, 89, 0.1);
}

.icon-box {
    width: 60px;
    height: 60px;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 1.6rem;
}
.icon-box.red { background: #fff0f0; color: var(--color-accent-red); }
.icon-box.blue { background: var(--color-blue-light); color: var(--color-primary-dark); }
.icon-box.purple { background: var(--color-purple-light); color: var(--color-soft-purple); }
.icon-box.yellow { background: #fefce6; color: #b0a402; }

.card h4 { margin-bottom: 10px; font-size: 1.2rem; color: var(--color-primary-dark); }
.card p { font-size: 0.95rem; color: var(--text-muted); }

/* CONTENEDORES DE REQUISITOS */
.card-requisito-container {
    padding: 30px;
    border-radius: 16px;
    box-shadow: var(--card-shadow);
}
.tone-purple { background-color: var(--color-purple-light); border: 1px solid #dcd8eb; }
.tone-blue { background-color: var(--color-blue-light); border: 1px solid #cbcde3; }

.card-requisito-container h4 {
    font-size: 1.4rem;
    margin-bottom: 20px;
    color: var(--color-primary-dark);
}

.elenco-stats {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
}

.stat-box {
    flex: 1;
    color: var(--color-white);
    padding: 20px;
    border-radius: 12px;
    text-align: center;
}
.stat-box.style-blue { background: var(--color-primary-dark); }
.stat-box.style-red { background: var(--color-accent-red); }

.stat-number { font-size: 2.2rem; font-weight: bold; display: block; }
.stat-label { font-size: 0.9rem; opacity: 0.9; }
.note-text { font-size: 0.95rem; color: var(--text-main); }

.doc-list { list-style: none; }
.doc-list li {
    display: flex;
    align-items: center;
    gap: 15px;
    background: var(--color-white);
    padding: 14px 18px;
    border-radius: 8px;
    margin-bottom: 12px;
}

.check-icon { color: #27ae60; font-size: 1.1rem; }
.sub-detail { display: block; font-size: 0.85rem; color: var(--text-muted); }

/* CRONOGRAMA INTEGRADO */
.timeline-container {
    max-width: 600px;
    margin: 0 auto 30px;
    position: relative;
}

.timeline-container::before {
    content: '';
    position: absolute;
    left: 20px; top: 0; width: 3px; height: 100%;
    background: var(--color-soft-purple);
    opacity: 0.4;
}

.timeline-item {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 25px;
    position: relative;
}

.timeline-number {
    width: 44px; height: 44px;
    background: var(--color-primary-dark);
    color: var(--color-white);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-weight: bold; z-index: 2;
    box-shadow: 0 4px 10px rgba(5, 2, 89, 0.2);
    transition: transform 0.3s ease, background-color 0.3s;
}

.timeline-item:hover .timeline-number {
    transform: scale(1.15) rotate(360deg);
    background-color: var(--color-accent-red);
}

.timeline-content {
    background: var(--color-white);
    padding: 18px 22px;
    border-radius: 8px;
    flex: 1;
    box-shadow: var(--card-shadow);
    border-left: 5px solid var(--color-primary-dark);
    transition: border-color 0.3s;
}

.timeline-item:hover .timeline-content {
    border-left-color: var(--color-accent-red);
}

.timeline-content strong { display: block; font-size: 1.1rem; color: var(--color-primary-dark); }
.timeline-content span { font-size: 0.9rem; color: var(--text-muted); }

/* BANNERS INFORMATIVOS */
.alert-banner {
    display: flex;
    gap: 20px;
    padding: 20px;
    border-radius: 12px;
    margin-top: 30px;
    align-items: center;
}
.info-banner { background: var(--color-blue-light); border: 1px solid #b8bcdf; color: var(--color-primary-dark); }
.danger-banner { background: #fff0f0; border: 1px solid #fcc7c7; color: #9c0303; }
.danger-banner ul { margin-left: 20px; margin-top: 8px; font-size: 0.95rem; }
.highlight-text { font-weight: bold; margin-top: 5px; color: var(--color-accent-red); }

/* FILAS DE EVALUACIÓN COHERENTES */
.evaluation-container {
    background: var(--color-white);
    border-radius: 12px;
    box-shadow: var(--card-shadow);
    overflow: hidden;
    margin-bottom: 30px;
    border: 1px solid #e1e1e1;
}

.evaluation-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    border-bottom: 1px solid #f2f2f2;
}

.evaluation-row:last-child { border-bottom: none; }
.eval-text strong { font-size: 1.1rem; color: var(--color-primary-dark); }
.eval-text p { font-size: 0.9rem; color: var(--text-muted); }
.eval-score { font-size: 1.5rem; font-weight: bold; color: var(--color-accent-red); }

/* SECCIÓN PODIO PREMIACIÓN */
.podium {
    align-items: flex-end;
    margin-top: 40px;
}

.card-prize {
    padding: 35px 20px;
    border-radius: 12px;
    color: var(--color-white);
}

.trophy-icon { font-size: 2.8rem; margin-bottom: 10px; display: inline-block; }
.rank-title { font-size: 2.2rem; font-weight: bold; display: block; }

.rank-1 { background: linear-gradient(135deg, var(--color-primary-dark), #0a05b3); order: 2; padding: 55px 20px; border: 2px solid var(--color-white); }
.rank-1 .trophy-icon { color: var(--color-accent-yellow); }
.rank-2 { background: linear-gradient(135deg, var(--color-soft-purple), #ffffff); order: 1; }
.rank-3 { background: linear-gradient(135deg, #534973, #c0c0c0); order: 3; }

.prize-detail { font-size: 0.95rem; margin-top: 10px; opacity: 0.95; }
.footer-note { text-align: center; font-size: 0.95rem; color: var(--text-muted); margin-top: 25px; }

/* PIE DE PÁGINA (ESTILO INSTITUCIONAL NOCTURNO) */
.main-footer {
    background-color: var(--color-primary-dark);
    color: #b3b0d9;
    text-align: center;
    padding: 50px 20px;
    font-size: 0.9rem;
    border-top: 5px solid var(--color-accent-red);
}

.footer-brand { color: var(--color-white); font-size: 1.6rem; font-weight: bold; margin-bottom: 10px; }
.designer { color: var(--color-primary-dark); background-color: var(--color-accent-yellow); display: inline-block; padding: 3px 12px; border-radius: 4px; font-weight: bold; margin: 15px 0; font-size: 0.75rem; letter-spacing: 0.5px; }
.credits { font-size: 0.85rem; opacity: 0.7; }

/* REGLAS DE ANIMACIÓN ADICIONALES */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}
.animate-fade-in { animation: fadeIn 1s cubic-bezier(0.16, 1, 0.3, 1) forwards; }

@keyframes bounceSlow {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}
.animate-bounce-slow { animation: bounceSlow 4s ease-in-out infinite; }

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.1); opacity: 0.8; }
}
.animate-pulse { animation: pulse 2s infinite; }

@keyframes flash {
    0%, 50%, 100% { opacity: 1; }
    25%, 75% { opacity: 0.4; }
}
.animate-flash { animation: flash 3s infinite; }

@keyframes glow {
    0%, 100% { filter: drop-shadow(0 0 4px rgba(242,226,5,0.5)); }
    50% { filter: drop-shadow(0 0 15px rgba(242,226,5,1)); }
}
.dynamic-glow { animation: glow 2s infinite; }

/* RESPONSIVE DESIGN */
@media (max-width: 768px) {
    .hero h1 { font-size: 2.6rem; }
    .hero h2 { font-size: 1.4rem; }
    .hero-info-bar { border-radius: 16px; gap: 15px; }
    .podium { align-items: stretch; gap: 15px; }
    .rank-1 { order: 1; padding: 35px 20px; }
    .rank-2 { order: 2; }
    .rank-3 { order: 3; }
}