/* Styles de base */
.hero-events {
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)),
                url('../img/event-hero.jpg');
    background-size: cover;
    background-position: center;
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    margin-top: 80px;
}

.hero-content h1 {
    font-size: 3rem;
    margin-bottom: 20px;
    text-transform: uppercase;
}

.hero-content p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto;
}

.events-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
    margin: 40px 0;
}

.event-card {
    background-color: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.event-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

.event-image {
    height: 200px;
    background-size: cover;
    background-position: center;
    position: relative;
}

.event-date {
    position: absolute;
    top: 15px;
    left: 15px;
    background-color: var(--orange-color);
    color: white;
    padding: 5px 10px;
    border-radius: 5px;
    font-weight: bold;
}

.event-category {
    position: absolute;
    bottom: 15px;
    right: 15px;
    background-color: var(--green-color);
    color: white;
    padding: 5px 10px;
    border-radius: 5px;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.8rem;
}

.event-content {
    padding: 20px;
}

.event-content h3 {
    font-size: 1.4rem;
    margin-bottom: 15px;
    color: var(--black-blue-color);
}

.event-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 15px;
    color: var(--gray-color);
    font-size: 0.9rem;
}

.event-meta i {
    margin-right: 5px;
    color: var(--orange-color);
}

.event-content p {
    margin-bottom: 20px;
    line-height: 1.6;
    color: var(--gray-dark-color);
}

.event-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.btn-event {
    padding: 8px 20px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
    flex: 1;
    text-align: center;
}

.btn-event {
    background-color: var(--gray-light-color);
    color: var(--black-blue-color);
    border: 1px solid #ddd;
}

.btn-event:hover {
    background-color: #e0e0e0;
}

.btn-register {
    background-color: var(--orange-color);
    color: white;
    border: none;
}

.btn-register:hover {
    background-color: var(--green-color);
}

.event-expired {
  position: absolute;
  top: 15px;
  right: 15px;
  background-color: red;
  color: white;
  padding: 5px 10px;
  border-radius: 5px;
  font-weight: bold;
  font-size: 0.8rem;
  text-transform: uppercase;
  z-index: 1;
}

/* Responsive */
@media (max-width: 768px) {
    .hero-events {
        height: 300px;
        margin-top: 60px;
    }

    .hero-content h1 {
        font-size: 2rem;
    }

    .events-grid {
        grid-template-columns: 1fr;
    }

    .event-actions {
        flex-direction: column;
    }

    .newsletter-form {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .hero-events {
        height: 250px;
    }

    .hero-content h1 {
        font-size: 1.8rem;
    }

}


/* Animation pour le chargement des événements */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.event-card {
    animation: fadeIn 0.5s ease forwards;
    opacity: 0;
}

/* Délais d'animation pour chaque carte */
.event-card:nth-child(1) { animation-delay: 0.1s; }
.event-card:nth-child(2) { animation-delay: 0.2s; }
.event-card:nth-child(3) { animation-delay: 0.3s; }
.event-card:nth-child(4) { animation-delay: 0.4s; }
.event-card:nth-child(5) { animation-delay: 0.5s; }
.event-card:nth-child(6) { animation-delay: 0.6s; }
