/* General Styles */
body {
    font-family: Arial, sans-serif; /* Ensure font matches style.css */
    background-color: #f9f9f9;
    color: #333;
    margin: 0;
    padding: 0;
}

.pagination {
    margin: 20px 0;
    text-align: center;
}

.pagination a {
    display: inline-block;
    margin: 0 5px;
    padding: 10px 20px;
    background-color: #4D75FF;
    color: white;
    text-decoration: none;
    border-radius: 5px;
}

.pagination a:hover {
    background-color: #0056b3;
}

/* Header Styles */
.header-container {
    background-color: #fff000;
    padding: 10px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 0; /* Remove any default margins */
}

.header-container .logo img {
    height: 50px; /* Adjust the size as needed */
}

.header-container nav {
    flex-grow: 1;
    display: flex;
    justify-content: space-between;
}

.header-container .menu {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
    width: 100%;
    justify-content: space-between;
}

.header-container .left-menu {
    margin-right: auto; /* Pushes all other items to the right */
    padding-left: 20px; /* Adds space between logo and link */
}

.header-container .right-menu {
    margin-left: 20px; /* Add some space between menu items */
}

.header-container .menu li a {
    color: #000; /* Adjust the color to fit your design */
    text-decoration: none;
    font-weight: bold;
}

.header-container .menu li a:hover {
    text-decoration: underline;
}

.header-container .menu li .button {
    background-color: #4D75FF;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    transition: background-color 0.3s;
    text-decoration: none;
}

.header-container .menu li .button:hover {
    background-color: #0056b3;
}

/* Footer Styles */
.footer {
    background-color: #4D75FF;
    color: white;
    text-align: center;
    padding: 10px 0;
    width: 100%;
    margin-top: auto; /* Push footer to the bottom */
}

.footer p {
    margin: 0; /* Remove default margin */
    font-weight: bold; /* Make the text bold */
}

/* General Container and Sidebar Styles */
.container {
    display: flex;
    flex-wrap: nowrap;
    align-items: stretch; /* Ensure both content and sidebar stretch to full height */
    min-height: 100vh; /* Ensure container takes full height of viewport */
}

.content {
    padding: 20px;
    width: 100%;
    box-sizing: border-box;
    text-align: justify; /* Align text to justify */
    order: 1; /* Ensure content is ordered first */
    margin-bottom: 100px; /* Add bottom margin to prevent overlap with footer */
}

/* Yellow Sidebar Styles */
.yellow-sidebar {
    background-color: #fff000;
    padding: 20px;
    width: 30%;
    color: #4D75FF; /* Blue color for the text */
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    order: 2; /* Ensure sidebar is ordered second */
    margin-left: auto; /* Push sidebar to the right */
}

.yellow-sidebar .promotion-ad {
    text-align: center;
}

.yellow-sidebar .promotion-ad h2 {
    font-size: 1.5em;
    margin-bottom: 10px;
}

.yellow-sidebar .promotion-ad ul {
    text-align: left;
    list-style-type: disc;
    padding-left: 20px;
}

.yellow-sidebar .button {
    display: inline-block;
    padding: 10px 20px;
    margin-top: 10px;
    background-color: #4D75FF;
    color: white;
    text-decoration: none;
    border-radius: 5px;
}

.yellow-sidebar .button:hover {
    background-color: #0056b3;
}

/* Responsive Design */
@media screen and (max-width: 768px) {
    .container {
        flex-direction: column;
    }

    .content,
    .yellow-sidebar {
        width: 100%;
        margin: 0;
    }
}

/* Grid Layout for Featured News */
.featured-news-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    margin: 20px auto;
    max-width: 1200px; /* Adjust as needed */
    gap: 20px; /* Add gap between grid items */
}

.featured-news-grid .news-item {
    background-color: #f9f9f9;
    border: 2px dashed #4D75FF;
    width: calc(33.333% - 20px); /* Adjust width to allow space between items */
    box-sizing: border-box;
    padding: 20px;
    display: flex;
    flex-direction: column; /* Ensure content is stacked */
    align-items: center; /* Center items */
}

/* Ensure the image and content are close to each other */
.news-item .news-image {
    margin-bottom: 10px; /* Adjust as needed for spacing */
    width: 100%; /* Full width for image */
}

.news-item img {
    width: 100%; /* Full width for image */
    height: auto;
    display: block;
}

.news-item .news-content {
    flex-grow: 1;
    text-align: center; /* Center text */
    width: 100%; /* Full width for content */
}

.news-item h2 {
    font-size: 1.2em;
    margin: 0 0 10px 0; /* Add bottom margin for spacing */
}

.news-item .excerpt {
    margin: 10px 0; /* Adjust as needed for spacing */
    text-align: left; /* Justify text */
}

.news-item .read-more {
    margin-top: 20px; /* Adjust as needed for spacing */
}

.news-item .read-more a {
    background-color: #4D75FF;
    color: white;
    padding: 10px 20px; /* Adjust padding for button size */
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s;
}

.news-item .read-more a:hover {
    background-color: #0056b3;
}

/* Responsive Design */
@media screen and (max-width: 768px) {
    .featured-news-grid .news-item {
        width: calc(50% - 20px); /* Two items per row on smaller screens */
    }
}

@media screen and (max-width: 480px) {
    .featured-news-grid .news-item {
        width: 100%; /* Full width for smaller screens */
    }
}
