/* ===========================
   Events Page Styles
   =========================== */

/* Events Sections */
.events-section {
    padding: 5rem 5%;
    background: #faf8f5;
}

.events-section:first-of-type {
    padding-top: calc(7rem + 60px);
}

@media (min-width: 821px) {
    .events-section:first-of-type {
        padding-top: calc(10rem + 60px);
    }
}

.events-section-past {
    background: white;
}

.events-section-inner {
    max-width: 1200px;
    margin: 0 auto;
}

.events-section h2 {
    text-align: center;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    font-size: 2.2rem;
}

.events-section h2::after {
    content: '';
    display: block;
    width: 100px;
    height: 3px;
    background: var(--secondary-color);
    margin: 1.5rem auto 0;
}

.events-section-subtitle {
    text-align: center;
    color: #666;
    margin-bottom: 4rem;
    font-size: 1.15rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

/* Events List — full-width vertical stack */
.events-list {
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

/* Event Card — stacked (image on top, content below) */
.event-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 16px rgba(0,0,0,0.07);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-bottom: 3px solid var(--secondary-color);
    display: flex;
    flex-direction: column;
}

.event-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 28px rgba(0,0,0,0.1);
}

/* Card Image — full-width on top */
.event-card-image {
    width: 100%;
    aspect-ratio: 1;
    overflow: hidden;
    background: linear-gradient(145deg, #e8dcc8 0%, #c8b896 50%, #d4c8a8 100%);
}

.event-card-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.event-card-image .image-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
}

/* Card Body */
.event-card-body {
    padding: 1.5rem 2rem 2rem;
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
}

.event-date {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    color: var(--primary-color);
    font-weight: 600;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.event-title {
    font-family: var(--font-title);
    font-size: 1.35rem;
    color: var(--neutral-dark);
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

.event-description {
    font-size: 0.95rem;
    line-height: 1.7;
    color: #525252;
    margin-bottom: 0.75rem;
    flex-grow: 1;
}

.event-description p {
    margin-bottom: 0.75rem;
}

.event-description ul {
    margin: 0.5rem 0 0.75rem;
    padding-left: 1.25rem;
    list-style: disc;
}

.event-description li {
    margin-bottom: 0.35rem;
    line-height: 1.5;
}

.event-description h4 {
    font-family: var(--font-title);
    font-size: 0.95rem;
    color: var(--neutral-dark);
    margin: 0.75rem 0 0.35rem;
}

.event-description em {
    font-style: italic;
}

.event-description strong {
    font-weight: 700;
    color: var(--neutral-dark);
}

.event-location {
    font-size: 0.85rem;
    color: #777;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

/* Event Tags */
.event-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-bottom: 1rem;
}

.event-tag {
    display: inline-block;
    padding: 0.2rem 0.7rem;
    border-radius: 4px;
    font-size: 0.75rem;
    color: var(--primary-color);
    font-weight: 500;
    font-style: italic;
    background: rgba(0, 164, 81, 0.08);
}

/* RSVP Button */
.event-rsvp {
    display: inline-block;
    padding: 0.75rem 2rem;
    background: var(--accent1);
    color: var(--neutral-dark);
    text-decoration: none;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.25s ease;
    text-align: center;
    margin-top: auto;
    align-self: flex-start;
}

.event-rsvp:hover {
    background: #c69500;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

/* Past event card — muted RSVP */
.event-card.past-event .event-rsvp {
    background: #ccc;
    color: #666;
    pointer-events: none;
}

/* Loading State */
.events-loading {
    text-align: center;
    padding: 4rem 1rem;
    color: var(--secondary-color);
    font-size: 1.1rem;
    font-weight: 500;
}

/* Error State */
.events-error {
    text-align: center;
    padding: 3rem 1rem;
    color: #c0392b;
    font-size: 1rem;
}

/* Empty State */
.events-empty {
    text-align: center;
    padding: 3rem 1rem;
    color: #888;
    font-size: 1rem;
    font-style: italic;
}

/* Scroll Reveal */
.reveal-on-scroll {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.reveal-on-scroll.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* ===========================
   Responsive
   =========================== */

@media (max-width: 820px) {
    .events-section {
        padding: 3rem 5%;
    }

    .events-list {
        gap: 1.5rem;
    }

    .event-card-body {
        padding: 1.25rem 1.25rem 1.5rem;
    }

    .event-title {
        font-size: 1.15rem;
    }

    .event-rsvp {
        width: 100%;
        text-align: center;
    }
}
