﻿/* ============================================================
   SJCO — CAMPUS EVENTS PAGE (MSI PREMIUM STYLE)
   File: /css/campuslife-events.css
   Author: SmartSchoolCore
============================================================ */

/* ------------------------------------------------------------
   COLOR VARIABLES
------------------------------------------------------------ */
:root {
    --sjco-green: #0c3a23;
    --sjco-green-light: #e8f2eb;
    --gold-soft: #eac341;
    --gold-pale: #f7e7a3;
    --white: #fff;
    --text-dark: #1f1f1f;
    --text-light: #666;
}


/* ============================================================
   HERO SECTION
============================================================ */
.events-hero {
    position: relative;
    width: 100%;
    height: 420px;
    overflow: hidden;
    display: flex;
    align-items: center;
    background: #000;
}

.events-hero-bg {
    position: absolute;
    inset: 0;
    background: url('/images/slide2.jpg') center/cover no-repeat;
    filter: brightness(0.55);
    z-index: 1;
}

/* MSI gradient overlay */
.events-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient( to right, rgba(12, 58, 35, 0.85), rgba(12, 58, 35, 0.35) );
    z-index: 2;
}

.events-hero-content {
    position: relative;
    z-index: 3;
    max-width: 700px;
    padding-left: 60px;
    color: var(--white);
}

.events-title {
    font-size: 3.2rem;
    font-weight: 800;
    margin-bottom: 10px;
}

.events-subtitle {
    font-size: 1.35rem;
    opacity: 0.9;
}

.events-desc {
    margin-top: 15px;
    font-size: 1.15rem;
    line-height: 1.6;
    max-width: 550px;
}


/* ============================================================
   MAIN SECTION
============================================================ */
.msi-section {
    padding: 60px 20px;
    max-width: 1300px;
    margin: 0 auto;
}

.msi-section-title {
    font-size: 2.4rem;
    font-weight: 800;
    color: var(--sjco-green);
    text-align: center;
    margin-bottom: 40px;
}


/* ============================================================
   EVENTS GRID — PREMIUM MSI STYLE
============================================================ */
.events-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 28px;
    margin-top: 20px;
}

.event-card {
    background: var(--white);
    border-radius: 14px;
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 10px 22px rgba(0,0,0,0.14);
    transition: 0.25s ease;
    border: 1px solid #eaeaea;
}

    .event-card:hover {
        transform: translateY(-6px);
        box-shadow: 0 16px 35px rgba(0,0,0,0.18);
    }

.event-image {
    width: 100%;
    height: 170px;
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
}

.event-info {
    padding: 20px;
    text-align: center;
}

    .event-info h3 {
        font-size: 1.35rem;
        font-weight: 700;
        color: var(--sjco-green);
        margin-bottom: 8px;
    }

.event-date {
    font-size: 0.95rem;
    color: var(--gold-soft);
    font-weight: 600;
    margin-bottom: 10px;
}

.event-summary {
    font-size: 1rem;
    color: var(--text-light);
    line-height: 1.5;
}


/* ============================================================
   MODAL VIEWER
============================================================ */
.event-modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.75);
    backdrop-filter: blur(4px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 25px;
}

.event-modal {
    background: var(--white);
    border-radius: 14px;
    max-width: 850px;
    width: 100%;
    overflow: hidden;
    animation: modalFadeIn 0.35s ease;
    box-shadow: 0 15px 40px rgba(0,0,0,0.28);
}

.modal-cover {
    width: 100%;
    height: 320px;
    object-fit: cover;
}

.modal-body {
    padding: 25px 30px 35px;
}

    .modal-body h2 {
        font-size: 2rem;
        font-weight: 800;
        margin-bottom: 10px;
        color: var(--sjco-green);
    }

.modal-date {
    font-size: 1rem;
    font-weight: 600;
    color: var(--gold-soft);
    margin-bottom: 15px;
}

.modal-desc {
    font-size: 1.07rem;
    color: var(--text-dark);
    line-height: 1.7;
    margin-bottom: 25px;
}

.modal-close {
    padding: 10px 24px;
    background: var(--sjco-green);
    color: var(--white);
    border-radius: 6px;
    border: none;
    cursor: pointer;
    font-weight: 600;
    transition: 0.2s ease;
}

    .modal-close:hover {
        background: #094021;
    }


/* ============================================================
   ANIMATIONS
============================================================ */
@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.97);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}


/* ============================================================
   RESPONSIVE
============================================================ */
@media (max-width: 992px) {
    .events-title {
        font-size: 2.6rem;
    }

    .modal-cover {
        height: 240px;
    }
}

@media (max-width: 768px) {
    .events-hero {
        height: 360px;
        text-align: center;
        justify-content: center;
    }

    .events-hero-content {
        padding-left: 0;
        padding: 0 20px;
    }

    .events-title {
        font-size: 2.2rem;
    }

    .events-subtitle {
        font-size: 1.1rem;
    }
}

@media (max-width: 480px) {
    .events-grid {
        grid-template-columns: 1fr;
    }
}
