:root {
    --primary-color: #0046B5;
    --secondary-color: #0056b3;
    --text-color: #1a1a1a;
    --background-color: #ffffff;
    --light-gray: #f8f9fa;
    --border-color: #e5e7eb;
    --header-height: 80px;

    /* Gradientes */
    --gradient-primary: linear-gradient(135deg, #0072E5 0%, #3399FF 100%);
}

/* Ajuste para el scroll suave */
html {
    scroll-behavior: smooth;
}

/* Ajustes para compensar la altura del header fijo */
#inicio, 
#cursos, 
#actividades, 
#proyectos, 
#contacto {
    scroll-margin-top: var(--header-height);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    overflow-x: hidden;
    width: 100%;
}

/* Contenedores principales */
.container, 
.header-container, 
.footer-content,
.footer-bottom,
.info-grid,
.courses-grid {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
    width: 100%;
}

/* Header */
header {
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    background-color: var(--background-color);
    height: var(--header-height);
}

.header-container {
    height: var(--header-height);
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: box-shadow 0.3s ease;
}

.header-shadow {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

/* Logo */
.logo-container {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo {
    height: 45px;
}

.logo-text {
    font-size: 1.8rem;
    font-weight: 600;
}

.logo-text strong {
    color: var(--primary-color);
}

/* Navegación */
nav {
    text-align: left;
}

nav ul {
    display: flex;
    list-style: none;
}

nav a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: all 0.3s ease;
}

nav a:hover,
nav a.active {
    color: var(--primary-color);
    background-color: rgba(0, 70, 181, 0.1);
}

/* Menú hamburguesa */
.menu-toggle {
    display: none;
    border: none;
    background: none;
    cursor: pointer;
    padding: 5px;
}

.hamburger {
    width: 25px;
    height: 3px;
    background-color: var(--primary-color);
    position: relative;
    transition: all 0.3s ease;
}

.hamburger::before,
.hamburger::after {
    content: '';
    position: absolute;
    width: 25px;
    height: 3px;
    background-color: var(--primary-color);
    transition: all 0.3s ease;
}

.hamburger::before {
    transform: translateY(-8px);
}

.hamburger::after {
    transform: translateY(8px);
}

/* Botón de acceso móvil */
.mobile-access-btn {
    display: none;
    background: none;
    border: none;
    color: var(--primary-color);
    font-size: 1.4rem;
    padding: 0.4rem;
    cursor: pointer;
}

/* Auth Buttons y Dropdown */
.auth-buttons {
    display: flex;
    gap: 1rem;
}

.auth-buttons .dropdown {
    position: relative;
}

.servicios-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: var(--primary-color);
    padding: 0.5rem 1rem;
    border: 2px solid var(--primary-color);
    border-radius: 4px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.servicios-btn i {
    font-size: 1rem;
}

.servicios-btn .fa-chevron-down {
    font-size: 0.8rem;
    margin-left: 0.3rem;
    transition: transform 0.3s ease;
}

.dropdown:hover .fa-chevron-down {
    transform: rotate(180deg);
}

.dropdown-menu {
    position: absolute;
    top: calc(100% + 5px);
    right: 0;
    background-color: white;
    min-width: 200px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    border-radius: 4px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    z-index: 1000;
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu li {
    display: block;
}

.dropdown-menu a {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    color: var(--text-color);
    text-decoration: none;
    transition: all 0.3s ease;
}

.dropdown-menu a i {
    width: 20px;
    text-align: center;
    color: var(--primary-color);
}

.dropdown-menu a:hover {
    background-color: rgba(0, 70, 181, 0.1);
    color: var(--primary-color);
}

/* Botones de Login y Register */
.btn-login,
.btn-register {
    padding: 0.5rem 1.5rem;
    border-radius: 4px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-login {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-register {
    background-color: var(--primary-color);
    color: white;
    border: none;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    width: calc(100% - 3rem);
}

.info-item {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1rem;
}

.info-icon {
    width: 60px;
    height: 60px;
    background-color: rgba(0, 70, 181, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.info-icon i {
    font-size: 1.75rem;
    color: var(--primary-color);
}

/* Info Content */
.info-content {
    flex-grow: 1;
}

.info-content h3 {
    font-size: 1.1rem;
    color: var(--text-color);
    margin-bottom: 0.25rem;
    font-weight: 600;
}

.info-content p {
    font-size: 1rem;
    color: var(--primary-color);
    font-weight: 500;
}

.info-item:not(:last-child)::after {
    content: '';
    position: absolute;
    right: -1rem;
    top: 50%;
    transform: translateY(-50%);
    height: 50px;
    width: 1px;
    background-color: var(--border-color);
}

/* Courses Section */
.courses-section {
    padding: 6rem 4rem;
    background-color: #f8f9fa;
    overflow: hidden;
}

.courses-grid {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 4rem;
    align-items: center;
}

.courses-title h2 {
    font-size: 2.5rem;
    line-height: 1.1;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 2rem;
}

/* Slider Controls */
.slider-controls {
    display: flex;
    gap: 1rem;
}

.prev-btn,
.next-btn {
    width: 50px;
    height: 50px;
    border: none;
    border-radius: 50%;
    background: var(--primary-color);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.prev-btn:hover,
.next-btn:hover {
    background: var(--secondary-color);
    transform: scale(1.1);
}

/* Courses Slider */
.courses-slider {
    width: 100%;
    overflow: hidden;
}

.slider-container {
    display: flex;
    gap: 2rem;
    transition: transform 0.5s ease;
}

/* Course Cards */
.course-card {
    min-width: 300px;
    background: white;
    border-radius: 20px;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    position: relative;
    transition: all 0.3s ease;
}

.course-card:hover {
    transform: translateY(-10px);
}

.year-number {
    font-size: 6rem;
    font-weight: 800;
    color: rgba(0, 70, 181, 0.1);
    position: absolute;
    top: 1rem;
    right: 1rem;
    line-height: 1;
}

.course-content {
    position: relative;
    z-index: 1;
}

.course-content h3 {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.course-content h4 {
    font-size: 1.2rem;
    color: var(--text-color);
    margin-bottom: 1rem;
}

.course-content p {
    color: #666;
    margin-bottom: 2rem;
    line-height: 1.6;
}

/* Botones y enlaces */
.enroll-btn {
    font-size: 0.8rem;
    display: inline-block;
    padding: 0.8rem 1rem;
    background: var(--primary-color);                                  
    color: white;
    text-decoration: none;
    border-radius: 20px;
    font-weight: 100;
    transition: all 0.3s ease;
}

.enroll-btn:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
}

.servicios-btn {
    border-radius: 10px;
    color: white;
    font-size: 0.8rem;
    text-decoration: none;
    padding: 0.3rem 0.8rem;
    background: var(--secondary-color);
}

/* Main Section Layout */
.main-section {
    width: 90%;
    max-width: 1400px;
    margin: 2rem auto;
    display: flex;
    gap: 2rem;
    padding: 0 1rem;
}

/* News Section */
.news-section {
    flex: 3;
    background-color: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(2, 1fr);
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.news-item {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.news-item img {
    width: 100%;
    height: 180px;
    object-fit: cover;
}

.news-item h3 {
    padding: 1rem 1rem 0.5rem;
    font-size: 1.1rem;
    color: #333;
}

.news-item time {
    padding: 0 1rem;
    color: #666;
    font-size: 0.9rem;
}

.news-item .description {
    padding: 0.5rem 1rem 1rem;
    font-size: 0.9rem;
    color: #555;
    flex-grow: 1;
}

/* Events Section */
.events-section {
    flex: 1;
    background-color: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.events-grid {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1.5rem;
}

.event-item {
    padding: 1rem;
    border-bottom: 1px solid #eee;
}

.event-item:last-child {
    border-bottom: none;
}

.event-item time {
    display: block;
    font-weight: bold;
    color: #2196F3;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.event-item h3 {
    font-size: 1rem;
    color: #333;
    margin-bottom: 0.3rem;
}

.event-item p {
    font-size: 0.9rem;
    color: #666;
}

/* Titles */
h2 {
    color: #333;
    font-size: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #2196F3;
    margin-bottom: 1rem;
}

/* Footer */
footer {
    background-color: var(--text-color);
    color: white;
    padding: 5rem 0 2rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-logo {
    height: 40px;
    margin-bottom: 1rem;
}

.footer-info p {
    opacity: 0.8;
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    text-decoration: none;
    transition: all 0.3s ease;
}

.footer-links {
    padding-left: 30px;
}

.footer-links ul {
    list-style: none;
    padding-top: 20px;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-links a {
    color: #fff;
    text-decoration: none;
    opacity: 0.8;
    transition: all 0.3s ease;
    display: block;
    padding: 5px 0;
}

.footer-links a:hover {
    opacity: 1;
    color: var(--primary-color);
    transform: translateX(5px);
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1rem;
}

.contact-form .btn-primary {
    justify-content: center; /* Centra el texto horizontalmente */
}

.contact-form input,
.contact-form textarea {
    padding: 0.8rem;
    border-radius: 6px;
    border: none;
    background-color: rgba(255,255,255,0.1);
    color: white;
}

.contact-form textarea {
    height: 100px;
    resize: vertical;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
}

/* Buttons */
.btn-primary {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 0.8rem 2rem;
    border-radius: 6px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
}

.btn-secondary {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    padding: 0.8rem 2rem;
    border-radius: 6px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

/* Hover Effects */
.btn-primary:hover,
.btn-register:hover {
    background-color: var(--secondary-color);
    transform: translateY(-2px);
}

.btn-secondary:hover,
.btn-login:hover {
    background-color: rgba(0, 70, 181, 0.1);
}

.news-card:hover {
    transform: translateY(-5px);
    transition: transform 0.3s ease;
}

/*.social-links a:hover {
    color: var(--primary-color);
} */

.social-links a:hover {
    background-color: var(--primary-color);
    transform: translateY(-3px);
}

/* Responsive Design */
@media (max-width: 1200px) {
    .news-grid {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    /* Header ajustes para móvil */
    :root {
        --header-height: 60px;
    }

    /* Ocultar carousel y banner en móvil */
    
    .info-banner {
        display: none;
    }

    /* Ajustar espaciado para la primera sección visible */
    .courses-section {
        padding-top: 2rem;
        margin-top: var(--header-height);
    }

    .header-container {
        display: grid;
        grid-template-columns: auto 1fr auto;
        align-items: center;
        padding: 0 1rem;
        height: var(--header-height);
    }

    .logo-container {
        justify-self: center;
    }

    .logo {
        display: none;
    }

    .logo-text {
        font-size: 1.2rem;
    }

    nav {
        position: fixed;
        top: var(--header-height);
        left: -100%;
        width: 100%;
        height: calc(100vh - var(--header-height));
        background: var(--background-color);
        padding: 1rem;
        transition: all 0.3s ease;
        z-index: 999;
    }

    nav.active {
        left: 0;
    }

    nav ul {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
    }

    nav ul li {
        width: 100%;
    }

    nav ul li a {
        display: block;
        padding: 1rem;
        text-align: left;
        border-bottom: 1px solid var(--border-color);
    }

    .menu-toggle {
        display: block;
    }

    .mobile-access-btn {
        display: block;
        justify-self: end;
    }

    .auth-buttons .btn-register,
    .auth-buttons .dropdown {
        display: none;
    }

    /* Ajustes de layout para móvil */
    .main-section {
        flex-direction: column;
        width: 95%;
        gap: 1.5rem;
    }

    .news-section,
    .events-section {
        width: 100%;
    }

    .news-grid {
        grid-template-columns: 1fr;
    }

    .courses-grid {
        grid-template-columns: 1fr;
    }

    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .social-links {
        justify-content: center;
    }

    /* Estado activo del menú hamburguesa */
    .menu-toggle.active .hamburger {
        background-color: transparent;
    }

    .menu-toggle.active .hamburger::before {
        transform: rotate(45deg) translateY(0);
    }

    .menu-toggle.active .hamburger::after {
        transform: rotate(-45deg) translateY(0);
    }
}

@media (max-width: 480px) {
    .main-section {
        padding: 0 0.5rem;
    }

    .news-section,
    .events-section {
        padding: 1rem;
    }
}

/* Animaciones */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Clases de animación */
.animate {
    opacity: 0;
}

.animate.fade-in-up {
    animation: fadeInUp 0.6s ease-out forwards;
}

.animate.fade-in-left {
    animation: fadeInLeft 0.6s ease-out forwards;
}

.animate.scale-in {
    animation: scaleIn 0.6s ease-out forwards;
}

/* Delays */
.delay-1 { animation-delay: 0.2s; }
.delay-2 { animation-delay: 0.4s; }
.delay-3 { animation-delay: 0.6s; }

/* Preferencia de usuario para reducir movimiento */
@media (prefers-reduced-motion: reduce) {
    * {
        animation: none !important;
        transition: none !important;
    }
}

/* Utilidades */
.scroll-lock {
    overflow: hidden;
}


/* Media Query para dispositivos móviles */
@media (max-width: 768px) {
    .footer-links {
        text-align: center;
    }

    .footer-links ul {
        flex-direction: row;
        justify-content: center;
        flex-wrap: wrap;
        gap: 20px;
    }

    .footer-links a {
        padding: 5px 10px;
    }

    .footer-links a:hover {
        transform: translateY(-2px);
    }
}
