.first-responders {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    padding: 20px;
    margin-left: -20px;
    margin-right: -20px;
    background-image: url("../images/first_responders.ba3313c99ce4.jpg");
    background-size: cover;
    background-position: center;
    height: 300px;
    padding: 20px;

}

.text {
    position: absolute;
    color: white;
    background: rgba(0,0,0,0.7);
    width: auto;

    
}

.button-container {
    text-align: center;
}

/* General button styling */
.learn-more{
    display: inline-block;
    width: auto;
    padding: 15px 30px; /* Padding inside the button */
    background-color: white; /* Button background color */
    color: #127a62; /* Text color */
    text-decoration: none; /* Remove underline */
    font-size: 1rem; /* Font size */
    font-weight: bold; /* Make text bold */
    border-radius: 5px; /* Rounded corners */
    border: 2px solid #127a62; /* Border around the button */
    text-align: center; /* Center the text */
    transition: all 0.3s ease; /* Smooth hover effect */
}

/* Button hover effect */
.learn-more:hover {
    background-color: #127a62; /* Green on hover */
    color: #ffffff; /* White text on hover */
    transform: scale(1.05); /* Slightly enlarge the button */
    cursor: pointer; /* Change cursor to pointer */
}


.rotater-container {
    flex: 1;
    max-width: 100%;
    position: relative;
    overflow: hidden;


}

.rotater {
    display: flex;
    transition: transform .8s ease-in-out;
}

.rotater-item {
    max-width: 100%;
    flex: 0 0 100%;
    height: 420px;
    overflow: hidden;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    padding: 20px;
    box-sizing: border-box;
    border-radius: 16px;
}

.rotater-item img {
    width: 100%;
    flex: 1;
    min-height: 0;
    object-fit: cover;
    display: block;
    border-radius: 16px;
}

.rotater-item h3 {
    margin: 0;
    min-height: 2.6em;
    line-height: 1.3;
    text-align: center;
}



/* Carousel Navigation Buttons */
.rotater-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, .5);
    color: white;
    border: none;
    padding: 10px 15px;
    cursor: pointer;
    border-radius: 50%;
    z-index: 2;
}

.rotater-btn:hover {
    background-color: rgba(0, 0, 0, 0.9);
}

.rotater-btn.prev {
    left: 10px;
}

.rotater-btn.next {
    right: 10px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .carousel-text-container {
        flex-direction: column; /* Stack carousel and text vertically */
        height: auto; /* Adjust height for smaller screens */
    }

    .rotater-container,
    .text-container {
        max-width: 100%; /* Take full width on smaller screens */
        flex: none; /* Remove flex shrinking */
        margin-bottom: 20px; /* Add space between sections */
    }
}

.page {
    color: white;
}
