/* Reset */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html,
body {
    height: 100%;
}

:root {
    --primary-blue: #1e3a8a;
    --secondary-blue: #1e3a8a;
    --light-blue: #dbeafe;
    --white: #ffffff;
    --light-gray: #f8fafc;
    --text-gray: #64748b;
    --border-gray: #e2e8f0;
    --shadow-sm: 0 4px 6px rgba(30, 58, 138, 0.1);
    --shadow-md: 0 10px 15px rgba(30, 58, 138, 0.1);
    --shadow-lg: 0 20px 25px rgba(30, 58, 138, 0.1),
        0 10px 10px rgba(30, 58, 138, 0.04);
}

body {
    font-family: "Inter", "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #1e293b;
    background: linear-gradient(135deg,
            var(--light-blue) 0%,
            var(--white) 50%,
            var(--light-blue) 100%);
    display: flex;
    flex-direction: column;
}

.container {
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    padding: 1rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* Header */
.header {
    background: var(--white);
    border-radius: 24px;
    padding: 3rem 2rem;
    margin-bottom: 2rem;
    border: 1px solid var(--border-gray);
    box-shadow: var(--shadow-lg);
    position: relative;
    overflow: hidden;
}

/* Línea superior decorativa */
.header::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-blue), var(--secondary-blue));
}

/* Contenedor de contenido */
.header-content {
    display: flex;
    align-items: center;
    justify-content: center;
    /* <- centra el bloque como fila */
    gap: 2rem;
    flex-wrap: wrap;
    text-align: left;
}


/* Texto del header */
.header-text {
    flex: 0 0 auto;
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: left;
}


.header-text h1 {
    font-size: clamp(2rem, 4vw, 3rem);
    color: var(--primary-blue);
    font-weight: 800;
    margin-bottom: 0.5rem;
}

.header-text .subtitle {
    font-size: 1.3rem;
    color: var(--secondary-blue);
    font-weight: 600;
    margin-bottom: 1rem;
}

.header-text p {
    max-width: 600px;
    font-size: 1rem;
    color: var(--black);
}

/* Card del logo */
.logo-card {
    background: var(--primary-blue);
    padding: 1rem;
    border-radius: 20px;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    max-width: 250px;
    flex: 0 0 auto;
    margin: 0;
}

/* Imagen del logo */
.logo-img {
    width: 100%;
    height: auto;
    border-radius: 15px;
    object-fit: cover;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    justify-content: center;
}

/* Responsive */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        text-align: center;
    }

    .header-text {
        flex: 1 1 100%;
    }

    .logo-card {
        margin-bottom: 1.5rem;
    }
}


/* Info Cards */
.info-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 1.3rem 0;
}

.info-card {
    background: var(--white);
    border-radius: 16px;
    padding: 2rem 1.5rem;
    text-align: center;
    transition: all 0.3s ease;
    border: 2px solid transparent;

}


.info-card:hover {
    background: var(--white);
    border-color: var(--light-blue);
    transform: translateY(-3px);
    box-shadow: var(--shadow-sm);
}

.info-icon {
    width: 50px;
    height: 50px;
    background: var(--primary-blue);
    color: var(--white);
    border-radius: 12px;
    margin: 0 auto 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
}

.info-card h3 {
    color: var(--primary-blue);
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.info-card p {
    font-size: 0.95rem;
    color: var(--text-black);
    line-height: 1.5;
}

.calendar-section {
    text-align: center;
    margin-top: 3rem;
    margin-bottom: 2rem;
}

.calendar-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-blue);
    margin-bottom: 0.5rem;
}

.calendar-subtitle {
    font-size: 1rem;
    color: var(--text-gray);
    margin-bottom: 1.5rem;
}

.calendar-container iframe {
    width: 100%;
    height: 700px;
    border: none;
}

/* Contenedor general */
.calendar-container {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    /* 2 columnas fijas */
    gap: 2rem;
    width: 100%;
    max-width: 1900px;
    /* Ancho máximo controlado */
    margin: 2rem auto;
    /* Centrado */
    padding: 0 1rem;
    /* Espacio lateral en pantallas pequeñas */
}

/* Estilo específico cuando hay un solo calendario */
.calendar-container.single {
    display: flex;
    justify-content: center;
}

.calendar-container.single .calendar-wrapper {
    max-width: 900px;
    width: 100%;
}

/* Cada calendario */
.calendar-wrapper {
    background: var(--white);
    padding: 1rem;
    border-top: 4px solid var(--primary-blue);
    border-radius: 10px;
    box-shadow: var(--shadow-sm);
}

/* Iframe */
.calendar-wrapper iframe {
    width: 100%;
    height: 600px;
    /* Menos scroll vertical */
    border: none;
    border-radius: 8px;
}

/* Responsive: en móviles, 1 calendario por fila */
@media (max-width: 992px) {
    .calendar-container {
        grid-template-columns: 1fr;
        /* Una columna */
    }

    .calendar-wrapper iframe {
        height: 600px;
        /* Ajustar altura en móvil */
    }
}


/* FORMULARIO DE AGREGAR CALENDARIO */
#formulario-calendario {
    background-color: var(--white);
    padding: 1.5rem;
    margin-top: 2rem;
    border-radius: 10px;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
}

#formulario-calendario input {
    width: 100%;
    max-width: 600px;
    padding: 0.75rem;
    border-radius: 8px;
    border: 1px solid #ccc;
    font-size: 1rem;
}

#formulario-calendario button {
    background-color: var(--primary-blue);
    color: var(--white);
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

#formulario-calendario button:hover {
    background-color: #003366;
}

/* SEPARACIÓN ENTRE BLOQUES */
.separador {
    height: 3rem;
}



/* Responsive */
@media (max-width: 768px) {
    .container {
        padding: 0.5rem;
    }

    .header,
    .calendar-section {
        padding: 2rem 1.5rem;
    }

    .calendar-container iframe {
        height: 500px;
    }

    .nav ul {
        flex-direction: column;
        gap: 0.5rem;
    }

    .cta-button {
        width: 100%;
        margin: 0.5rem 0;
    }

    .contact-info {
        flex-direction: column;
        gap: 1rem;
    }

    .university-logo {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
    }

    /* Estilos para el botón de exportación */
    .export-container {
        text-align: center;
        margin: 20px 0;
    }

    .export-button {
        background-color: #2c7be5;
        color: white;
        border: none;
        padding: 12px 24px;
        border-radius: 6px;
        font-size: 16px;
        cursor: pointer;
        transition: all 0.3s;
        display: inline-flex;
        align-items: center;
        gap: 8px;
    }

    .export-button:hover {
        background-color: #1a68d1;
        transform: translateY(-2px);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    }

    .export-button i {
        font-size: 18px;
    }

    .export-note {
        color: #666;
        font-size: 14px;
        margin-top: 8px;
    }


}