@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&display=swap');

:root {
    --primary-blue: #2c5282;
    --dark-blue: #1e3a8a;
    --bg-color: #f4f7fa;
    --text-main: #333333;
    --card-radius: 12px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-main);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow-x: hidden;
}

/* Wavy Header Background */
.header-wave {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 0;
}
.header-wave svg {
    display: block;
    width: 100%;
    height: 220px;
}

/* Wavy Footer Background */
.footer-wave {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    z-index: 0;
}
.footer-wave svg {
    display: block;
    width: 100%;
    height: 180px;
}

/* Main Content Container */
main {
    flex: 1;
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 80px 20px 40px;
    gap: 40px;
    margin-bottom: 60px; /* space for the footer wave */
}

/* Base Card Style */
.card-link {
    text-decoration: none;
    display: block;
    width: 100%;
    max-width: 700px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-link:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
}

.announcement-card {
    position: relative;
    width: 100%;
    height: 340px;
    border-radius: var(--card-radius);
    overflow: hidden;
    box-shadow: 0 12px 30px rgba(0,0,0,0.1);
    background-color: #fff;
}

.announcement-card img.bg-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
}

.card-link:hover .announcement-card img.bg-image {
    transform: scale(1.05); /* subtle zoom on hover */
}

.card-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 80%;
    background: linear-gradient(to bottom, rgba(0,0,0,0) 0%, rgba(10, 20, 50, 0.9) 100%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 35px;
}

.card-title {
    color: white;
    font-size: 1.5rem;
    font-weight: 500;
    line-height: 1.4;
    margin-bottom: 20px;
    text-shadow: 0 2px 5px rgba(0,0,0,0.4);
}

.glass-btn {
    align-self: flex-start;
    display: inline-block;
    padding: 10px 24px;
    color: white;
    font-size: 0.95rem;
    font-weight: 500;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 6px;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    text-decoration: none;
    transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.card-link:hover .glass-btn {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.8);
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

/* Article Page specific */
.article-container {
    width: 100%;
    max-width: 800px;
    background: white;
    border-radius: var(--card-radius);
    overflow: hidden;
    box-shadow: 0 15px 40px rgba(0,0,0,0.08);
}

.article-header {
    position: relative;
    width: 100%;
    height: 380px;
}

.article-header img.bg-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.article-header .card-overlay {
    padding: 40px;
    justify-content: flex-end;
    background: linear-gradient(to bottom, rgba(0,0,0,0) 0%, rgba(10, 20, 50, 0.9) 100%);
}

.article-header .card-title {
    font-size: 1.8rem;
    margin-bottom: 0;
}

.article-content {
    padding: 45px 50px;
    font-size: 1.1rem;
    line-height: 1.7;
    color: var(--text-main);
}

.article-content p {
    margin-bottom: 20px;
}

.article-content p:last-child {
    margin-bottom: 0;
}

.back-link {
    display: inline-flex;
    align-items: center;
    color: var(--primary-blue);
    text-decoration: none;
    font-weight: 600;
    margin-top: 30px;
    transition: color 0.3s ease;
}

.back-link:hover {
    color: var(--dark-blue);
    text-decoration: underline;
}

/* Footer text */
.footer-text {
    position: absolute;
    bottom: 25px;
    left: 40px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
    z-index: 10;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .announcement-card {
        height: 280px;
    }
    .card-title {
        font-size: 1.25rem;
    }
    .article-header {
        height: 280px;
    }
    .article-header .card-title {
        font-size: 1.4rem;
    }
    .article-content {
        padding: 30px 25px;
    }
    .footer-text {
        left: 20px;
    }
}
