/* Main Layout */
.main {
    position: relative;
    z-index: 0;
    padding-top: 110px;
    min-height: calc(100vh - 120px);
}

body {
    background-color: #ffffff;
    background-image: url("/index/assets/mascot_bg.svg");
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.page-title {
    margin-left: 90px;
    margin-bottom: 1rem;
    font-size: 24px;
    position: relative;
}

.page-title::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 40px;
    height: 2px;
    background: linear-gradient(90deg, #F18F01 0%, rgba(241, 143, 1, 0) 100%);
    border-radius: 2px;
}

.section-title {
    text-align: center;
    font-size: 18px;
    font-weight: 900;
}

.events-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 1rem;
    max-width: 1000px;
    margin-left: auto;
    margin-right: auto;
}

/* Event Cards */
.event-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease, opacity 0.5s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 250px;
    position: relative;
}

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

.event-image {
    width: 100%;
    height: 250px;
    overflow: hidden;
    background-color: #f0f0f0;
}

.event-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.event-card:hover .event-image img {
    transform: scale(1.05);
}

/* Partner Logos Strip */
.event-partners {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 16px;
    background: linear-gradient(135deg, #f8f9fa 0%, #eef0f2 100%);
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    gap: 12px;
}

.partners-label {
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: #888;
    font-weight: 600;
    white-space: nowrap;
    flex-shrink: 0;
}

.partners-logos {
    display: flex;
    align-items: center;
    gap: 10px;
}

.partner-logo {
    height: 32px;
    width: auto;
    object-fit: contain;
    filter: grayscale(20%);
    opacity: 0.85;
    transition: opacity 0.3s ease, filter 0.3s ease;
}

.event-card:hover .partner-logo {
    filter: grayscale(0%);
    opacity: 1;
}

.partners-divider {
    width: 1px;
    height: 20px;
    background-color: #ccc;
    flex-shrink: 0;
}

.event-content {
    padding: 0.5rem 1rem;
    display: flex;
    flex-direction: column;
    flex: 1;
    justify-content: space-between;
}

.event-title {
    font-size: 1rem;
    margin-bottom: 0;
}

.event-date {
    margin: 0;
    font-size: 0.9rem;
}

.event-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
}

.apply-btn {
    background-color: #ed2345;
    padding: 0.6rem 1.2rem;
    font-size: 0.9rem;
    border-radius: 6px;
    color: #fff;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
    position: static;
    margin-right: 2px;
}

.apply-btn:hover {
    background-color: #d91f3e;
    transform: translateY(-2px);
}

.apply-btn:active {
    transform: translateY(0);
}

/* ===== Responsive: Tablet ===== */
@media (max-width: 1024px) {
    .main {
        padding-top: 80px;
    }

    .page-title {
        margin-left: 40px;
    }

    .events-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
        max-width: 700px;
    }
}

/* ===== Responsive: Mobile ===== */
@media (max-width: 600px) {
    html, body {
        height: 100vh;
        height: 100dvh;
        overflow: hidden;
        margin: 0;
    }

    .main {
        height: 100vh;
        height: 100dvh;
        padding-top: 64px;
        box-sizing: border-box;
        display: flex;
        flex-direction: column;
        overflow: hidden;
        min-height: unset;
    }

    .container {
        flex: 1;
        display: flex;
        flex-direction: column;
        padding: 14px 16px 16px;
        min-height: 0;
    }

    .page-title {
        margin: 0 0 6px 0;
        font-size: 19px;
        flex-shrink: 0;
    }

    .page-title::after {
        bottom: -3px;
        width: 32px;
    }

    .upcoming-events {
        flex: 1;
        display: flex;
        flex-direction: column;
        min-height: 0;
    }

    .section-title {
        font-size: 15px;
        margin: 0 0 10px 0;
        flex-shrink: 0;
    }

    .events-grid {
        display: flex;
        flex-direction: column;
        flex: 1;
        gap: 0;
        max-width: 100%;
        margin-top: 0;
        min-height: 0;
    }

    .event-card {
        flex: 1;
        min-height: 0;
        border-radius: 14px;
        box-shadow: 0 2px 16px rgba(0, 0, 0, 0.1);
    }

    .event-image {
        flex: 1;
        height: auto;
        min-height: 120px;
        overflow: hidden;
    }

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

    .event-partners {
        flex-direction: row;
        align-items: center;
        padding: 8px 16px;
        gap: 10px;
        flex-shrink: 0;
    }

    .partners-label {
        font-size: 0.6rem;
        letter-spacing: 1px;
    }

    .partner-logo {
        height: 26px;
    }

    .partners-divider {
        height: 16px;
    }

    .event-content {
        padding: 10px 16px 14px;
        flex-shrink: 0;
        flex: unset;
    }

    .event-title {
        font-size: 1rem;
        font-weight: 700;
        margin-bottom: 4px;
    }

    .event-date {
        font-size: 0.85rem;
        color: #666;
    }

    .event-actions {
        padding-top: 8px;
    }

    .apply-btn {
        padding: 11px 24px;
        font-size: 0.9rem;
        border-radius: 10px;
        min-height: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }
}

/* ===== Responsive: Small Mobile ===== */
@media (max-width: 380px) {
    .main {
        padding-top: 56px;
    }

    .container {
        padding: 10px 14px 14px;
    }

    .page-title {
        font-size: 17px;
        margin: 0 0 4px 0;
    }

    .section-title {
        font-size: 14px;
        margin: 0 0 8px 0;
    }

    .event-partners {
        padding: 6px 12px;
        gap: 8px;
    }

    .partner-logo {
        height: 22px;
    }

    .partners-divider {
        height: 14px;
    }

    .partners-logos {
        gap: 7px;
    }

    .event-content {
        padding: 8px 14px 12px;
    }

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

    .event-actions {
        padding-top: 6px;
    }

    .apply-btn {
        padding: 10px 20px;
        min-height: 42px;
        font-size: 0.85rem;
        border-radius: 10px;
    }
}
