/* General Styles */
@font-face {
    font-family: 'Gilmer';
    src: url('/fonts/gilmer-light.otf') format('otf');
    font-weight: normal;
    font-style: normal;
}

html {
    scroll-behavior: smooth;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Gilmer', sans-serif;
    color: white;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

body {
    overflow-x: hidden;
}

html, body {
    overflow-x: hidden; /* Disable horizontal scrolling */
    width: 100%; /* Ensure the body stays within the viewport */
}

/* Header Section */
.header {
    min-height: 100vh;
    width: 100%;
    background-image: linear-gradient(to right, rgba(0,0,0,0.5), rgba(0,0,0,0.9)), url("../Images/backgroundIm.png");
    background-position: center;
    background-size: contain;
    position: relative;
    text-align: center;
    font-family: 'Lucida Sans', 'Lucida Sans Regular', 'Lucida Grande', 'Lucida Sans Unicode', Geneva, Verdana, sans-serif;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.text-box {
    display: flex;
    flex-direction: row;
    gap: 300px;
    text-align: left;
    margin-left: 10px;
    overflow: hidden; /* Prevent content overflow during animation */
}

.text-box h1 {
    font-size: 48px;
    margin-bottom: 20px;
}

.text-box p {
    font-size: large;
    margin-bottom: 20px;
    margin-left: 10px;
}

/* Animations */
.description {
    opacity: 0;
    transform: translateX(-80px);
    transition: opacity 1s ease-out, transform 1s ease-out;
}

.description.animate {
    opacity: 1;
    transform: translateY(0);
}

.description span {
    font-size: 62px;
}

.infoBox {
    background-color: rgba(0, 0, 0, 0.4);
    border-radius: 10px;
    width: 90%; 
    max-width: 750px; 
    display: flex;
    flex-direction: column; 
    align-items: center;
    justify-content: center;
    gap: 10px; 
    padding: 10px; 
    opacity: 0;
    transform: translateY(-60px);
    transition: opacity 1s ease-out, transform 1s ease-out;
}

/* Animation class */
.infoBox.animate {
    opacity: 1;
    transform: translateY(0);
}

/* Contact and Service Sections */
.contactBox {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
}

.contactBox p {
    font-size: larger;
    font-family: 'Trebuchet MS', 'Lucida Sans Unicode', 'Lucida Grande', 'Lucida Sans', Arial, sans-serif;
}

.workingHours {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.tooltip {
    visibility: hidden;
    background-color: #555;
    color: #fff;
    text-align: center;
    border-radius: 5px;
    padding: 5px 10px;
    position: absolute;
    z-index: 1;
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none; /* Ensure the tooltip does not capture mouse events */
}

.tooltip::after {
    content: "";
    position: absolute;
    top: 100%;
    left: 50%;
    margin-left: -5px;
    border-width: 5px;
    border-style: solid;
    border-color: #555 transparent transparent transparent;
}

.show-tooltip {
    visibility: visible;
    opacity: 1;
}

.googleMapIframe {
    width: 650px;
    height: 400px;
    margin-bottom: 50px;
}

/* Service Section */
.service {
    min-height: 100vh;
    padding: 80px 40px;
    background: linear-gradient(#abababcd 5%, #fff 20%, #ffffff 90%);
    color: white;
    text-align: center;
}

.service h1 {
    font-size: 62px;
    margin-bottom: 40px;
}

.serviceDiv {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
    gap: 40px;
    overflow: hidden;
}

.sBoxes {
    background-size: cover;
    height: 600px;
    width: 360px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: left;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    perspective: 1000px; 
}

.sBoxesInner {
    position: relative;
    width: 80%;
    height: 80%;
    text-align: center;
    transition: transform 0.8s;
    transform-style: preserve-3d;
}

.sBoxesFront, .sBoxesBack {
    position: absolute;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden; /* Safari */
    backface-visibility: hidden;
}

.sBoxesFront {
    background-image: linear-gradient(#4c9f70cd, #3ec8b1b9), url("../Images/mainBG.jpg");
}

.sBoxesBack {
    transform: rotateY(180deg);
    background: linear-gradient(#4c9f70cd, #3ec8b1b9);
    justify-content: center;
    align-items: center;
}

.sBoxesBack p {
    text-align: left !important;
}

.sBoxes.flip .sBoxesInner {
    transform: rotateY(-180deg);
}

.sBoxesA {
    opacity: 0;
    transform: translateY(150px);
    transition: opacity 1s ease-out, transform 1s ease-out;
}

.sBoxes.animate {
    opacity: 1;
    transform: translateY(0);
}

.sBoxes h2 {
    margin: 1rem; /* Adjusted to rem for better scaling */
    z-index: 2;
}

.sBoxes:hover {
    opacity: 0.9;
    transform: scale(1.05);
}

.sBoxes h3 {
    opacity: 0;
    position: absolute;
    bottom: 2rem; /* Adjusted to rem for better scaling */
    left: 2rem; /* Adjusted to rem for better scaling */
    font-size: 1.2rem; /* Adjusted to rem for better scaling */
    transition: opacity 0.3s ease-in-out;
}

.sBoxes:hover h3 {
    opacity: 1;
}

.sBoxes p {
    margin: 1rem;
    margin-top: 2rem; /* Adjusted to rem for better scaling */
    text-align: left;
    font-size: 1.2rem; /* Adjusted to rem for better scaling */
}

/* Contact Section */
.contactDiv {
    min-height: 50vh;
    padding: 80px 40px;
    background-color: #4c9f70;
    color: white;
    text-align: center;
}

.contactCol {
    display: flex;
    flex-direction: row;
    gap: 10px;
    margin-top: 40px;
    font-size: larger;
}

/* For Us Section */
.forusDiv {
    position: relative;
    min-height: 50vh;
    display: flex;
    width: 100%;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    gap: 100px;
    background: linear-gradient(to right, #2d6143 66%, #fff 75%);
    text-align: left;
    padding-left: 15px;
    box-sizing: border-box;
    line-height: 30px;
    border: 2px solid white;
    border-radius: 5px;
}

.forusDiv img {
    left: 0;
    width: 100%;
    height: 100%;
    max-width: 450px;
}

.forusDiv p {
    font-size: larger;
    color: white;
    text-align: justify;
    margin-right: 20px;
}

/* Footer */
#copiedText {
    opacity: 0;
}

footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-direction: column;
    min-height: 50vh;
    background: linear-gradient(white 10%, #387d56 20%, #2d6143 90%);
    padding-top: 200px;
}

.fDiv {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 200px;
    flex-wrap: wrap;
    flex-direction: row;
}

footer iframe {
    border: 5px solid rgb(255, 255, 255);
    border-radius: 10px;
}

.footerContactDiv {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 300px;
    gap: 20px;
    font-size: larger;
    background-color: rgba(128, 128, 128, 0.385);
    border-radius: 5px;
    padding: 10px;
}

footer img {
    transition: opacity 0.3s ease-in-out;
}

footer img:hover {
    opacity: 0.7;
}

.socialMediaDiv {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    background-color: #333;
    width: 100%;
    gap: 10px;
    padding: 5px;
}

/* Media Queries */
@media (max-width: 1200px) {
    .text-box {
        flex-direction: column;
        gap: 100px;
    }
    .text-box h1 {
        font-size: 32px;
        margin-bottom: 20px;
    }    
    .infoBox {
        min-width: 90%;
        padding: 10px;
        flex-direction: column;
    } 
    .footerContactDiv {
        display: none !important;
    }
    .forusDiv {
        flex-direction: column;
        text-align: center;
        background: #2d6143;
        padding-left: 0px;
        border: 0px;
    }
    .forusDiv p {
        font-size: medium;
        margin-left: 5px;
        margin-bottom: 0px;
    }
    .serviceDiv {
        flex-direction: column;
        align-items: center;
        gap: 20px;
    }
    .contactCol {
        flex-direction: column;
    }
    .googleMapIframe {
        width: 100%;
        height: auto;
    }
    .nav-links {
        background: #4C9F70;
    }
    .sBoxes {
        height: 400px;
        width: 100%;
    }
    
    .sBoxesInner {
        width: 90%;
        height: 90%;
    }
    
    .sBoxes h2 {
        margin: 1rem;
        font-size: 1.5rem;
    }
    
    .sBoxes h3 {
        bottom: 1rem;
        left: 1rem;
        font-size: 1rem;
    }
    
    .sBoxes p {
        margin: 1rem;
        margin-top: 1.5rem;
        font-size: 1rem;
    }    
}