/* CSS específico para la sección de eventos - eventos.css */

/* Solo aplicar el fondo al contenedor, no a toda la página */
.eventos-page {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    padding: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: calc(100vh - 200px); /* Ajustar altura para no interferir con header/footer */
}

/* Asegurar que no interfiera con el header existente */
body {
    background: unset !important;
}

.eventos-container {
    max-width: 1200px;
    margin: 0 auto 20px auto;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.eventos-header {
    background: linear-gradient(135deg, #ff6b6b, #ffa726);
    padding: 40px;
    text-align: center;
    color: white;
    position: relative;
    overflow: hidden;
}

.eventos-header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="50" cy="50" r="1" fill="rgba(255,255,255,0.1)"/></svg>') repeat;
    animation: eventos-float 20s infinite linear;
}

@keyframes eventos-float {
    0% { transform: translateX(-50px) translateY(-50px) rotate(0deg); }
    100% { transform: translateX(-50px) translateY(-50px) rotate(360deg); }
}

.eventos-header h1 {
    font-size: 3rem;
    margin-bottom: 10px;
    position: relative;
    z-index: 1;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.eventos-header p {
    font-size: 1.2rem;
    opacity: 0.9;
    position: relative;
    z-index: 1;
}

.eventos-filters {
    padding: 30px;
    background: rgba(248, 249, 250, 0.8);
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
}

.eventos-filter-btn {
    padding: 10px 20px;
    border: 2px solid #667eea;
    background: transparent;
    color: #667eea;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.eventos-filter-btn:hover,
.eventos-filter-btn.active {
    background: #667eea;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.eventos-search-box {
    padding: 10px 20px;
    border: 2px solid #ddd;
    border-radius: 25px;
    outline: none;
    transition: all 0.3s ease;
    min-width: 250px;
}

.eventos-search-box:focus {
    border-color: #667eea;
    box-shadow: 0 0 10px rgba(102, 126, 234, 0.3);
}

.eventos-grid {
    padding: 40px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
}

.eventos-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    cursor: pointer;
    opacity: 0;
    transform: translateY(20px);
    animation: eventos-fadeInUp 0.6s ease forwards;
}

.eventos-card:nth-child(odd) {
    animation-delay: 0.1s;
}

.eventos-card:nth-child(even) {
    animation-delay: 0.2s;
}

@keyframes eventos-fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.eventos-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

/* Estilos actualizados para imágenes */
.eventos-image {
    height: 200px;
    position: relative;
    overflow: hidden;
    background: linear-gradient(45deg, #ff6b6b, #ffa726, #67b26f, #4ecdc4);
    background-size: 400% 400%;
    animation: eventos-gradient 8s ease infinite;
    display: flex;
    align-items: center;
    justify-content: center;
}

.eventos-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.eventos-image img:hover {
    transform: scale(1.05);
}

/* Fallback para iconos cuando no hay imagen */
.eventos-fallback-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    color: white;
    font-size: 3rem;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
}

/* Cuando hay imagen, ocultar el gradiente animado */
.eventos-image:has(img:not([style*="display: none"])) {
    background: none;
    animation: none;
}

@keyframes eventos-gradient {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.eventos-content {
    padding: 25px;
}

.eventos-date {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
    display: inline-block;
    margin-bottom: 15px;
}

.eventos-title {
    font-size: 1.4rem;
    font-weight: bold;
    color: #333;
    margin-bottom: 10px;
    line-height: 1.3;
}

.eventos-type {
    color: #667eea;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 1px;
    margin-bottom: 10px;
}

.eventos-description {
    color: #666;
    line-height: 1.6;
    margin-bottom: 15px;
}

.eventos-stats {
    display: flex;
    gap: 20px;
    padding-top: 15px;
    border-top: 1px solid #eee;
    font-size: 0.9rem;
    color: #888;
}

.eventos-stat {
    display: flex;
    align-items: center;
    gap: 5px;
}

.eventos-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    backdrop-filter: blur(5px);
}

.eventos-modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    border-radius: 20px;
    padding: 40px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}

.eventos-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: #999;
    transition: color 0.3s ease;
}

.eventos-modal-close:hover {
    color: #333;
}

/* Estilos para imágenes en el modal */
.modal-event-image {
    width: 200px;
    height: 200px;
    object-fit: cover;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    margin-bottom: 20px;
}

.eventos-no-events {
    text-align: center;
    padding: 60px;
    color: #888;
    font-size: 1.2rem;
}

@media (max-width: 768px) {
    .eventos-page {
        padding: 10px;
    }
    
    .eventos-container {
        margin: 10px auto;
        border-radius: 15px;
    }
    
    .eventos-header h1 {
        font-size: 2rem;
    }
    
    .eventos-filters {
        padding: 20px;
    }
    
    .eventos-filter-btn {
        padding: 8px 16px;
        font-size: 0.9rem;
    }
    
    .eventos-search-box {
        min-width: 200px;
        width: 100%;
        margin-top: 10px;
    }
    
    .eventos-grid {
        grid-template-columns: 1fr;
        padding: 20px;
        gap: 20px;
    }
    
    .eventos-image {
        height: 150px;
    }
    
    .eventos-fallback-icon {
        font-size: 2rem;
    }
    
    .modal-event-image {
        width: 150px;
        height: 150px;
    }
    
    .eventos-modal-content {
        padding: 30px;
        margin: 20px;
    }
}