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

body {
    font-family: Arial, sans-serif;
    background-color: white;
    color: black;
    display: flex;
    flex-direction: column;
    min-height: 100vh; /* Ensures footer stays at the bottom */
}


/* Header Styles */
header.navbar {
    background-color: #2C8C84;
    padding: 20px 0;
    text-align: center;
    position: relative; /* Change this from fixed to relative */
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 100; /* Keeps it above other content */
}

header .logo img {
    width: 150px;
    height: auto;
    cursor: pointer;
}

/* News Section Styles */
.news-section {
    padding: 80px 20px 40px; /* Added padding at top to avoid overlap with fixed header */
    text-align: center;
    flex-grow: 1; /* Allows content to grow and push footer down */
    margin-top: 120px; /* Added margin-top for header space */
}

.news-section h2 {
    font-size: 2.5rem;
    color: #2C8C84;
    margin-bottom: 40px;
}

.news-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
}

.news-item {
    background-color: white;
    border: 1px solid #ddd;
    border-radius: 10px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.news-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.news-item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.news-content {
    padding: 15px;
    text-align: left;
}

.news-content h3 {
    font-size: 1.5rem;
    color: #2C8C84;
    margin-bottom: 15px;
}

.news-content p {
    font-size: 1rem;
    color: black;
    margin-bottom: 15px;
}

.read-more {
    font-size: 1rem;
    color: #2C8C84;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

.read-more:hover {
    color: #D84B16;
}

/* Footer Styles */
footer {
    background-color: #2C8C84;
    color: white;
    text-align: center;
    padding: 30px 0;
    width: 100%;
    position: relative;
    margin-top: auto; /* Keeps footer at the bottom */
}

footer .social-icons {
    margin-bottom: 20px;
}

footer .social-icons a {
    color: white;
    margin: 0 10px;
    font-size: 25px;
    transition: color 0.3s ease;
}

footer .social-icons a:hover {
    color: #D84B16;
}

footer p {
    font-size: 1rem;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .news-container {
        grid-template-columns: 1fr;
    }
    
    .news-section h2 {
        font-size: 2rem;
    }

    .news-item img {
        height: 150px;
    }
}

@media (max-width: 480px) {
    .news-content h3 {
        font-size: 1.2rem;
    }
    
    .news-content p {
        font-size: 0.9rem;
    }
    
    .read-more {
        font-size: 0.9rem;
    }
}