/* Reset default styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
.heading2{
    margin-top: 1rem;
}
/* Main container */
.news-container {
    max-width: 1200px;
    margin: 1rem auto;
    padding: 20px;
    font-family: 'Roboto Condensed', sans-serif;
    color: #333;
}

/* Hero section */
.news-hero, .heading2 {
    margin-top: 1rem;
    text-align: center;
    margin-bottom: 40px;
}

.news-hero h1 {
    font-family: 'Oswald', sans-serif;
    font-size: 2.5rem;
    color: #2e7d32;
    animation: fadeIn 1s ease-in-out;
}

/* Image slider */
.news-slider {
    position: relative;
    max-width: 100%;
    margin-bottom: 40px;
    overflow: hidden;
}

.news-slider-inner {
    display: flex;
    transition: transform 0.5s ease-in-out;
    width: 100%;
}

.news-slide-img {
    width: 100%;
    max-width: 600px;
    height: auto;
    object-fit: cover;
    cursor: pointer;
    flex: 0 0 auto;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.news-slide-img:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2), 0 4px 4px rgba(0, 0, 0, 0.1);
}

.news-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: #fff;
    border: none;
    padding: 10px;
    font-size: 1.5rem;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.news-nav-btn:hover {
    background-color: rgba(0, 0, 0, 0.7);
    transform: translateY(-50%) scale(1.1);
}

.news-nav-btn:focus {
    outline: 2px solid #4caf50;
    outline-offset: 2px;
}

.news-prev {
    left: 10px;
}

.news-next {
    right: 10px;
}

/* Fullscreen overlay */
.news-fullscreen {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    justify-content: center;
    align-items: center;
    animation: fadeInOut 0.5s ease-in-out;
}

.news-fullscreen-img {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

.news-close-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 2rem;
    color: #fff;
    cursor: pointer;
    transition: color 0.3s ease, transform 0.3s ease;
}

.news-close-btn:hover {
    color: #4caf50;
    transform: scale(1.2);
}

.news-close-btn:focus {
    outline: 2px solid #4caf50;
    outline-offset: 2px;
}

/* News grid */
.news-grid {
    width: 75%;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(700px, 1fr));
    gap: 20px;
    /* margin-bottom: 40px; */
    margin: 1rem auto;

}

.news-card {
    background: #f5f5f5;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2), 0 6px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.25), 0 8px 8px rgba(0, 0, 0, 0.15);
}

.news-card:nth-child(1) {
    animation: slideIn 0.5s ease-in-out;
}

.news-card:nth-child(2) {
    animation: slideIn 0.6s ease-in-out;
}

.news-card:nth-child(3) {
    animation: slideIn 0.7s ease-in-out;
}

.news-card:nth-child(4) {
    animation: slideIn 0.8s ease-in-out;
}

.news-card:nth-child(5) {
    animation: slideIn 0.9s ease-in-out;
}

.news-card-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
}

.news-card h2 {
    /* font-family: 'Playfair Display', serif; */
    font-size: 1.1rem;
    color: #1b5e20;
    flex: 1;
    margin: 0;
}

.news-btn {
    display: inline-flex;
    align-items: center;
    background-color: #4caf50;
    color: #fff;
    text-decoration: none;
    padding: 10px 20px;
    border-radius: 5px;
    font-size: 1rem;
    font-family: 'Roboto Condensed', sans-serif;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2), 0 2px 2px rgba(0, 0, 0, 0.1);
    transition: background-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
    white-space: nowrap;
}

.news-btn:hover {
    background-color: #388e3c;
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.25), 0 3px 3px rgba(0, 0, 0, 0.15);
    animation: pulse 0.6s ease-in-out;
}

.news-btn:focus {
    outline: 2px solid #1b5e20;
    outline-offset: 2px;
}

.news-btn i {
    margin-left: 8px;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }

    100% {
        transform: scale(1);
    }
}

@keyframes fadeInOut {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* Responsive design */
@media (max-width: 800px) {
    .news-hero h1 {
        font-size: 2rem;
        animation-duration: 0.8s;
    }

    .news-grid {
        grid-template-columns: 1fr;
    }

    .news-card {
        padding: 15px;
        box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15), 0 4px 4px rgba(0, 0, 0, 0.1);
    }

    .news-card:hover {
        box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2), 0 6px 6px rgba(0, 0, 0, 0.1);
    }

    .news-card-content {
        flex-direction: row;
        gap: 10px;
    }

    .news-card h2 {
        font-size: 1.4rem;
    }

    .news-slide-img {
        max-width: 400px;
    }

    .news-btn {
        padding: 8px 16px;
        font-size: 0.9rem;
        box-shadow: 0 3px 6px rgba(0, 0, 0, 0.15), 0 2px 2px rgba(0, 0, 0, 0.1);
    }

    .news-btn:hover {
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2), 0 2px 2px rgba(0, 0, 0, 0.1);
    }
}

@media (max-width: 480px) {
    .news-hero h1 {
        font-size: 1.8rem;
        animation-duration: 0.6s;
    }
.heading2{
    font-size: 1.3rem;
}
    .news-grid {
        width: 100%;
    }

    .news-card-content {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .news-card h2 {
        font-size: 1.2rem;
        text-align: center;
    }

    .news-btn {
        padding: 8px 16px;
        font-size: 0.9rem;
        justify-content: center;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    }

    .news-btn:hover {
        box-shadow: 0 3px 6px rgba(0, 0, 0, 0.15), 0 2px 2px rgba(0, 0, 0, 0.1);
        animation: none;
    }

    .news-slide-img {
        max-width: 300px;
    }

    .news-nav-btn {
        font-size: 1.2rem;
        padding: 8px;
    }

    .news-card {
        box-shadow: 0 6px 12px rgba(0, 0, 0, 0.1), 0 3px 3px rgba(0, 0, 0, 0.05);
    }

    .news-card:hover {
        box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15), 0 4px 4px rgba(0, 0, 0, 0.1);
    }
}