body { 
    margin: 0;
    font-family: Rubik;
    font-size: 1.4rem;
    color: white;
    }

canvas { 
    display: block;
    z-index: 1;
    }

/* Nav bar */

header {
    position: sticky;
    top: 0;
    z-index: 3;
}

nav {
    position: sticky;
    width: 100%;
    z-index: 3;
    top: 0;
    display: flex;
    align-items: center;
    height: 7rem;
    padding: 0 2em;
    background-color: #2F70FF;
    box-shadow: 0 0.2vw 0.6vw black;
}

/* Title aligned to the left */
nav p {
    margin: 0;
    font-size: 1.8rem;
    z-index: 4; /* Ensure it's on top if overlaps */
    color: white;
}

/* Center the ul absolutely relative to the nav */
nav ul {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
}

/* List items inline */
nav ul li {
    margin: 0 1em;
}

/* Optional: style links */
nav ul li a {
    text-decoration: none;
    color: white;
    padding: 0.4vw 0.8vw;
    border-radius: 0.3vw;
}

nav ul li a:hover{
    background-color: #023299;
    z-index: 2;
}

/* introduction container */

.container_sg{
    display: flex;
    margin: 4vw 10vw;
    padding: 2vw 4vw;
    background-color: #2F70FF;
    box-shadow: 0 0.2vw 0.6vw black;
    justify-content: center;
    align-items: center;
}

    .container_sg p{
        margin-top: 0.5vw;
        color: white;
    }

.about{
    position: absolute;
    z-index: 2;
    display: grid;
    grid-template-rows: repeat(10, 4vh);
    grid-template-columns: repeat(10, 4vw);
}


.threed, .gnomeo, .business_automation, .ai_implementation{
    position: absolute;
    z-index: 2;
    display: none;
    grid-template-rows: repeat(20, 5vh);
    grid-template-columns: repeat(20, 5vw);
}

.about_button_sg{
    color: white;
    margin-top: 1vw;
    padding: 0.4vw 7vw;
    background-color: #2F70FF;
    border-color: white;
    border-style:double;
    border-radius: 0.3vw;

}

.about_button_sg:hover{
    background-color: #023299;
}

/* .container_sg:hover{
    scale: 1.03;
    
    transition-property: all;
    transition-duration: 1s;
    transition-timing-function: ease;
} */

.h1_sg{
    font-size: 2.6rem;
    font-weight: 600;
    margin: 0 0 0.9vw;
}

h2{
    font-size: 2rem;
}

.sg_ticks li{
    margin-top: 0.5vh;
}

#about, #our_services, #contact_us{
    scroll-margin-top: 9vh;
}

#contact_us{
    display: block; 
    height: 120vh; 
    padding-top: 3.5%;
}

#booking-form {
    margin-top: 10%;
    justify-content: center;
}

.form-group {
    margin-bottom: 20px;
}

.form-group input, .form-group textarea{
    width: 100%;
    padding: 0.4vw;
    border-radius: 0.3vw;
    background-color: white;
    color: black;
    box-shadow: none;
}

.error-list {
    list-style: none;
    padding: 0;
    margin-bottom: 0.5vw;
}
.error-list li {
    color: #d93025;
    font-size: 14px;
}
.success-message {
    color: #188038;
    font-size: 16px;
    margin-bottom: 20px;
    text-align: center;
}
.flatpickr-calendar {
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    z-index: 100;
}
.flatpickr-day.selected, .flatpickr-day.selected:hover {
    background-color: #1a73e8;
    border-color: #1a73e8;
}

.message {
    opacity: 0;
    transition: opacity 1s ease, transform 0.5s ease;
    background-color: #188038;
}

.message.show {
    opacity: 1;
}

.message.fade-out {
    opacity: 0;
    transform: translateY(-200%);
}

#our_services_subcontainer{
    display: grid; 
    grid-template-columns: repeat(10, 6vw); 
    grid-template-rows: repeat(11, 5vh);
}

.threed .list-group{
    width: 50%;
    position: fixed;
    margin-top: 2rem;
    grid-row:2; 
    grid-column: 2 / 10;
}

.gnomeo .list-group, .business_automation .list-group, .ai_implementation .list-group{
    width: 43%;
    position: fixed;
    margin-top: 2rem;
    grid-row:2; 
    grid-column: 2 / 10;
}

button{
    font-weight: 300;
}

/* For Small Desktop devices */
@media (max-width: 1250px){
    body{
        font-size: 1.4rem;
        overflow-wrap: break-word;
    }

    nav{
        height: 4rem;
        text-align: center;
    }

    nav p{
        font-size: 1.4rem;
    }

    .h1_sg{
        font-size: 2.5rem;
    }

    h2{
        font-size: 1.6rem;
    }

    #our_services_subcontainer{
        display: grid; 
        grid-template-columns: repeat(10, 6vw); 
        grid-template-rows: repeat(11, 6vh);
    }
}

/* For Tablet Devices */
@media (max-width: 1125px){
    body{
        font-size: 1.1rem;
        overflow-wrap: break-word;
    }

    nav{
        height: 3.3rem;
        text-align: center;
    }

    nav p{
        font-size: 1.1rem;
        margin-right: 10vw;
    }

    .h1_sg{
        font-size: 2.2rem;
    }

    h2{
        font-size: 1.25rem;
    }

    #our_services_subcontainer{
        display: grid; 
        grid-template-columns: repeat(10, 6vw); 
        grid-template-rows: repeat(11, 6vh);
    }

}

@media (max-width: 1000px){
    #first_img{
        display: none;
    }

    #second_section_sg{
        text-align: center;
    }

    #second_section_sg button{
        width: 100%;
    }

    .previous_work_button{
        display: none;
    }
}

/* For Small Tablet Devices */
@media (max-width: 780px) or (max-height: 800px){
    body{
        font-size: 0.95rem;
        overflow-wrap: break-word;
    }

    nav{
        height: 2.75rem;
        text-align: center;
    }

    nav p{
        font-size: 0.95rem;
    }

    .h1_sg{
        font-size: 2rem;
    }

    h2{
        font-size: 1.15rem;
    }

    #our_services_subcontainer{
        display: grid; 
        grid-template-columns: repeat(10, 6vw); 
        grid-template-rows: repeat(11, 7.2vh);
    }
}

@media (max-height: 600px){
    #contact_us{
        height: 130vh;
    }
}

@media (max-width: 670px){
    body{
        font-size: 0.9rem;
        overflow-wrap: break-word;
    }

    nav{
        height: 2.65rem;
        text-align: center;
    }

    nav p, nav li{
        font-size: 0.9rem;
    }

    .h1_sg{
        font-size: 1.8rem;
    }

    h2{
        font-size: 1.05rem;
    }

    #our_services_subcontainer{
        display: grid; 
        grid-template-columns: repeat(10, 6vw); 
        grid-template-rows: repeat(11, 7.2vh);
    }
}

@media (max-width: 570px){
    body{
        font-size: 0.8rem;
        overflow-wrap: break-word;
    }

    nav{
        height: 2.6rem;
        text-align: center;
    }

    nav p, nav li{
        font-size: 0.8rem;
    }

    .h1_sg{
        font-size: 1.7rem;
    }

    h2{
        font-size: 1.0rem;
    }

    #our_services_subcontainer{
        display: grid; 
        grid-template-columns: repeat(10, 6vw); 
        grid-template-rows: repeat(11, 7.2vh);
    }
}

/* For Mobile Devices */
@media (max-width: 500px) or (max-height: 500px){
    body{
        font-size: 0.8rem;
    }

    nav{
        height: 2.5rem;;
    }

    nav p{
        font-size: 0.8rem;
    }

    nav ul {
        position: absolute;
        left: 80%;
        transform: translateX(-80%);
        display: flex;
        list-style: none;
        margin: 0;
        padding: 0;
    }

    .h1_sg{
        font-size: 1.6rem;
    }

    h2{
        font-size: 1rem;
    }

    #our_services_subcontainer{
        display: grid; 
        grid-template-columns: repeat(10, 6vw); 
        grid-template-rows: repeat(11, 7.2vh);
    }

    #contact_us{
        height: 110vh;
    }

}

/* For Small Mobile Devices */
@media (max-width: 425px) or (max-height: 425px){
    body{
        font-size: 0.7rem;
    }

    nav{
        height: 2.5rem;;
    }

    nav p{
        font-size: 0.7rem;
    }

    .h1_sg{
        font-size: 1.4rem;
    }

    h2{
        font-size: 0.9rem;
    }

    #our_services_subcontainer{
        display: grid; 
        grid-template-columns: repeat(10, 6vw); 
        grid-template-rows: repeat(11, 7.2vh);
    }

}

/* For Extra Small Mobile Devices */
@media (max-width: 400px){


    nav p{
        display: none;
    }

    nav ul {
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
        display: flex;
        list-style: none;
        margin: 0;
        padding: 0;
    }

}

@media screen and (orientation: landscape) and (max-width: 1024px){
    #contact_us{
        height: 200vh;
    }
}



