/* Reset y estilos base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
}

.contenedor {
    max-width: 1400px;
    margin: 0 auto;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Encabezado */
.encabezado {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 3rem 2rem;
    text-align: center;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.encabezado h1 {
    font-size: 3rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 0.5rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.subtitulo {
    font-size: 1.2rem;
    color: #5a6c7d;
    font-weight: 300;
    max-width: 600px;
    margin: 0 auto;
}

/* Contenido principal */
.contenido-principal {
    flex: 1;
    padding: 3rem 2rem;
}

/* Grid de módulos */
.grid-modulos {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    max-width: 800px;
    margin: 0 auto;
}

/* Tarjetas de módulos */
.tarjeta-modulo {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 1.5rem;
    text-align: center;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    display: block;
}

.tarjeta-modulo::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.tarjeta-modulo:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
}

.tarjeta-modulo:hover::before {
    opacity: 1;
}

/* Iconos de módulos */
.icono-modulo {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    display: block;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
    transition: transform 0.3s ease;
}

.tarjeta-modulo:hover .icono-modulo {
    transform: scale(1.1) rotate(5deg);
}

/* Títulos de módulos */
.tarjeta-modulo h2 {
    font-size: 1.3rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 0.5rem;
    position: relative;
    z-index: 1;
}

/* Descripción corta */
.tarjeta-modulo p {
    font-size: 0.9rem;
    color: #e74c3c;
    font-weight: 600;
    margin-bottom: 0;
    position: relative;
    z-index: 1;
}


/* Colores específicos para cada módulo */
.tarjeta-modulo:nth-child(1) {
    border-top: 3px solid #e74c3c;
}

.tarjeta-modulo:nth-child(1) p {
    color: #e74c3c;
}

.tarjeta-modulo:nth-child(2) {
    border-top: 3px solid #f39c12;
}

.tarjeta-modulo:nth-child(2) p {
    color: #f39c12;
}

.tarjeta-modulo:nth-child(3) {
    border-top: 3px solid #27ae60;
}

.tarjeta-modulo:nth-child(3) p {
    color: #27ae60;
}

.tarjeta-modulo:nth-child(4) {
    border-top: 3px solid #9b59b6;
}

.tarjeta-modulo:nth-child(4) p {
    color: #9b59b6;
}

/* Pie de página */
.pie-pagina {
    background: rgba(44, 62, 80, 0.95);
    backdrop-filter: blur(10px);
    color: white;
    padding: 2rem;
    text-align: center;
    margin-top: auto;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.pie-pagina p {
    font-size: 0.9rem;
    opacity: 0.8;
}

/* Animaciones */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.tarjeta-modulo {
    animation: fadeInUp 0.6s ease-out;
}

.tarjeta-modulo:nth-child(1) { animation-delay: 0.1s; }
.tarjeta-modulo:nth-child(2) { animation-delay: 0.2s; }
.tarjeta-modulo:nth-child(3) { animation-delay: 0.3s; }
.tarjeta-modulo:nth-child(4) { animation-delay: 0.4s; }

/* Responsive */
@media (max-width: 768px) {
    .encabezado {
        padding: 2rem 1rem;
    }
    
    .encabezado h1 {
        font-size: 2.2rem;
    }
    
    .subtitulo {
        font-size: 1rem;
    }
    
    .contenido-principal {
        padding: 2rem 1rem;
    }
    
    .grid-modulos {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
    
    .tarjeta-modulo {
        padding: 1.2rem;
    }
    
    .icono-modulo {
        font-size: 2rem;
    }
    
    .tarjeta-modulo h2 {
        font-size: 1.1rem;
    }
}

@media (max-width: 480px) {
    .encabezado h1 {
        font-size: 1.8rem;
    }
    
    .grid-modulos {
        grid-template-columns: 1fr;
    }
    
    .tarjeta-modulo {
        padding: 1rem;
    }
    
    .icono-modulo {
        font-size: 2rem;
    }
    
    .tarjeta-modulo h2 {
        font-size: 1rem;
    }
    
    .tarjeta-modulo p {
        font-size: 0.8rem;
    }
}
