.facility_section_wrapper {
    position: relative;
    background-color: transparent;
    z-index: 1;
    padding: 60px 40px;
    display: flex;
    align-items: stretch;
    gap: 40px;
    width: 100%;
    border-radius: 30px;
    overflow: visible; /* Allow overflow */
}

.facility_section_wrapper::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    background-color: #3B8CED;
    clip-path: polygon(5% 0, 100% 0, 95% 100%, 0% 100%);
    z-index: -1;
    /* border-radius: 30px; */
}


/* Image wrapper - now a square container without a frame */
.facility_image_wrapper {
    flex: 0 0 auto; /* Allow width to be set explicitly */
    /* width: 350px; /* Fixed width for the square image */
    /* height: 250px; /* Fixed height for the square image */
    display: flex;
    justify-content: center; /* Centered the image within its wrapper */
    align-items: center;
    /* border-radius: 20px; All corners are now curved */
    /*border: 20px solid #ffffff;  Corrected: 20px solid white border */
    overflow: hidden; /* Crucial: Hides parts of the image outside its bounds */
    /* box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08); /* Subtle shadow for the image itself */
    margin-right: 20px; /* Maintains space to the right */
    /* padding-top: 20px;*/ 
    /* background-color: #ffffff; /* Background color of the container */
    animation: slideInLeft 1s ease 0.3s forwards;
    left: 0%;
    margin-left: calc(-5% + 0px);
}

/* Image styling - fits perfectly inside its square wrapper */
.facility_image {
    width: 360px; /* Fixed width for the square image */
    height: 250px; /* Fixed height for the square image */
    object-fit: cover; /* Ensures image covers the area without distortion */
    opacity: 0; /* Hidden by default for animation */
    display: block; /* Remove extra space below image */
    border-color: #ffffff;
    /* border-radius: inherit; Inherit border-radius from wrapper for curved corners */
}

/* Container for text to give it a separate background and shape */
.text-content-wrapper {
    flex: 1; /* Allows text content to take remaining available space */
    display: flex;
    flex-direction: column;
    justify-content: center;
    background-color: #ffffff; /* white background for text section */
    padding: 20px 30px; /* More padding for a better look */
    /* Apply parallelogram clip-path to the content area */
    /* clip-path: polygon(10% 0, 100% 0, 90% 100%, 0% 100%); */
    /* clip-path: polygon(10% 0, 100% 0, 90% 100%, 0% 100%); /* parallelogram*/
    /* clip-path: polygon(0% 0%, 100% 0%, 100% 100%, 0% 100%);
    z-index: 2; /* Ensure it's above the main background */
    animation: slideInRight 1s ease 0.3s forwards;
    opacity: 0; /* Hidden by default for animation */
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08); /* Subtle shadow */
    /*border-radius: 20px;  Applies to all four corners */
    min-width: 350px; /* Adjust based on content needs */
    height: 250px; /* Ensure text container stretches to fill available height */
    margin-left: 20px;
}

/* Head text - customized parallelogram background */
.facility_head_text {
    color: #ffffff; /* Darker color for heading */
    text-transform: uppercase; /* Make heading uppercase as in image */
    letter-spacing: 4px; /* Increased letter spacing */
    text-align: center; /* Center align heading */
    /* Additional styling for the topic's background */
    background-color: #333; /* Light grey background for the topic */
    padding: 15px 20px; /* Padding around the topic text */
    /* Custom clip-path for the topic background - now correctly a parallelogram */
    /* clip-path: polygon(5% 0, 100% 0, 95% 100%, 0% 100%);
    /* border-radius: 10px;  Rounded corners for the topic background */
    /* Use display: block with auto margins for centering and full width behavior for clip-path */
    display: block;
    height: 35px;
    width: 100%; /* Allow background to fit content width */
    /*margin: 0 auto 25px auto;  Center the topic and add bottom margin */
    /*box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1); /* Subtle shadow for topic */
    font-size: large;
    font-weight: bold;
    left: 0%;
    margin-left: calc(-5% + 0px);
    animation: slideInLeft 1s ease 0.3s forwards;
}

/* Body text */
.facility_body_text {
    font-weight: normal;
    color: #000000; /* Slightly lighter color for body text */
    line-height: 1.6; /* Better readability */
    text-align: justify; /* Justify text as in image */
}

/* Animations */
@keyframes slideInLeft {
    0% {
        transform: translateX(-100%);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideInRight {
    0% {
        transform: translateX(100%);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .facility_section_wrapper {
        flex-direction: column; /* Stack elements vertically on small screens */
        padding: 30px 20px;
        clip-path: polygon(0 0, 100% 0, 100% 100%, 0% 100%); /* Revert to rectangle for better mobile display */
        border-radius: 15px; /* Consistent rounded corners for mobile */
        overflow: hidden; /* Hide overflow on mobile */
    }

    .facility_image_wrapper {
        position: relative; /* Revert to relative positioning */
        width: 100%; /* Full width */
        height: auto; /* Allow height to adjust */
        transform: none; /* Remove transform on mobile */
        margin: 0 0 20px 0; /* Add bottom margin */
        clip-path: none; /* Remove clip-path for better mobile display */
        border: none; /* Remove border on mobile */
        border-radius: 10px; /* Consistent rounded corners for mobile */
    }

    .facility_image {
        height: auto; /* Allow image height to adjust on mobile */
        width: 100%; /* Full width */
        clip-path: none; /* Remove clip-path for better mobile display */
        border-radius: 10px; /* Consistent rounded corners for mobile */
        margin-left: 0; /* Remove left margin on mobile */
        min-width: auto; /* Reset min-width on mobile */
    }

    .text-content-wrapper {
        width: 100%; /* Full width */
        clip-path: none; /* Remove clip-path for better mobile display */
        border-radius: 10px; /* Consistent rounded corners for mobile */
        margin-left: 0; /* Remove left margin on mobile */
        min-width: auto; /* Reset min-width on mobile */
    }

    .facility_head_text {
        font-size: 24px;
        letter-spacing: 1px;
        padding: 8px 15px;
        clip-path: none; /* Remove clip-path for better mobile display */
        border-radius: 8px;
        width: auto; /* Allow width to adjust */
    }

    .facility_body_text {
        font-size: 16px;
    }
}