/* Announcements Heading */
.announcements-title {
    color: #fbfdff;
    font-size: 16px;
    font-family: 'Grobold', 'Arial Black', sans-serif;
    font-weight: 400;
    text-transform: uppercase;
    text-align: center;          /* ← changed */
    margin: 0 auto 30px;         /* ← changed (centers the pill block) */
    letter-spacing: 2px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.523);
    background-color: rgba(103, 182, 252, 0.973);
    padding: 12px 15px;
    border-radius: 50px;
    width: fit-content;
    box-shadow:
        0 4px 10px rgba(0, 0, 0, 0.219),
        inset 0 -4px 0 rgba(10, 60, 120, 0.55);
}

/* Horizontal Scroll Container */
.news-container {
    display: flex;
    gap: 20px;
    overflow-x: auto; /* Allows horizontal scrolling if cards exceed width */
    padding: 10px 5px 30px 5px;
    align-items: stretch;
}

/* Hide scrollbar for a cleaner look (optional) */
.news-container::-webkit-scrollbar {
    height: 8px;
}
.news-container::-webkit-scrollbar-thumb {
    background: #555;
    border-radius: 4px;
}

/* Individual News Card */
.news-card {
    background-color: #212121; /* Dark grey similar to screenshot */
    border: 1px solid #333;
    border-radius: 4px;
    width: 280px;
    min-width: 280px;
    display: flex;
    flex-direction: column;
    position: relative;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.6);
    transition: transform 0.2s ease-in-out;
}

.news-card:hover {
    transform: translateY(-5px);
}

/* Top Image Section */
.news-card-image {
    position: relative;
    background-color: #111;
    padding: 30px 0;
    text-align: center;
    border-bottom: 2px solid #b83b3b; /* Accent border */
}

.news-icon {
    width: 100px;
    height: 100px;
    border-radius: 20px; /* Squircle shape */
    border: 2px solid #555;
    box-shadow: 0 4px 8px rgba(0,0,0,0.8);
    object-fit: cover;
}

/* The red 'NEWS' bubble overlapping the bottom */
.news-badge-main {
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(to bottom, #d62828, #9a031e);
    color: #fff;
    padding: 4px 20px;
    font-size: 16px;
    font-weight: 900;
    border-radius: 20px;
    border: 2px solid #fff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.8);
    letter-spacing: 1px;
}

/* Content Area */
.news-card-content {
    padding: 30px 15px 15px 15px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

/* Date and Tag Row */
.news-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.news-date {
    color: #999;
    font-size: 11px;
    text-transform: uppercase;
}

.news-tag {
    background-color: #d35400; /* Orange badge */
    color: #fff;
    padding: 2px 8px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: bold;
    text-transform: uppercase;
}

/* Title Styling */
.news-title {
    color: #ffffff;
    font-size: 15px;
    font-weight: bold;
    margin: 0 0 10px 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Text Body Truncation */
.news-excerpt p {
    color: #aaaaaa;
    font-size: 12px;
    line-height: 1.5;
    margin: 0 0 15px 0;
    
    /* Truncate text to 4 lines */
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-excerpt {
    flex-grow: 1;
}

/* Footer (Author & Read More) */
.news-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    padding-top: 10px;
    border-top: 1px solid #333;
}

.news-author {
    color: #ccc;
}

.author-name {
    color: #e74c3c; 
    font-weight: bold;
}

.news-read-more {
    color: #fff;
    text-decoration: underline;
    font-weight: bold;
    transition: color 0.2s;
}

.news-read-more:hover {
    color: #e74c3c;
}

.news-empty {
    color: #6ca8f8;
    text-shadow: 0px 2px 1.6px rgba(19, 29, 46, 0.114);
    font-family: 'Informb', sans-serif;
    font-size: 16px;
    text-align: center;
    font-weight: 600;
}

.announcements-page-section {
    position: relative;
    width: 100%;
    min-height: 540px;
    margin: 0 auto;
    padding: 42px 30px;
    box-sizing: border-box;
}

.announcements-page-section .announcements-title {
    margin: 0 auto 170px;
}

.announcements-page-section .news-container {
    justify-content: center;
    width: min(1180px, 100%);
    margin: 0 auto;
}

.announcements-page-section .news-empty {
    width: 100%;
    margin-left: auto;
    margin-right: auto;
}

@media (max-width: 700px) {
    .announcements-page-section {
        min-height: 420px;
        padding: 34px 18px;
    }

    .announcements-page-section .announcements-title {
        margin-bottom: 100px;
    }
}
