@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@100;200;300;400;500;600&display=swap');

*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    text-decoration: none;
    border: none;
    outline: none;
    font-family: 'Poppins', sans-serif;
}

html{
    font-size: 62.5%;
}

body{
    width: 100%;
    height: 100vh;
    overflow-x: hidden;
    background-color: #FFFFFF;
    color: #0d142a;
}

header {
    margin-top: 0px;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1rem 9%;
    background-color: #FFFFFF; /* changed from transparent to white */
    box-shadow: 0 2px 10px rgba(0,0,0,0.1); /* optional subtle shadow */
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;
}


.logo img{
    height: 80px;     /* adjust logo size */
    width: auto;
    object-fit: contain;
}

.logo:hover{
    transform: scale(1.1);
}

nav a{
    font-size: 1.8rem;
    color: #0d142a;
    margin-left: 4rem;
    font-weight: 500;
    transition: 0.3s ease;
    border-bottom: 3px solid transparent;
}

nav a:hover,
nav a.active{
    color: #0d142a;
    border-bottom: 3px solid #0d142a;
}

@media(max-width:995px){
    nav{
        position: absolute;
        display: none;
        top: 0;
        right: 0;
        width: 40%;
        border-left: 3px solid #0d142a;
        border-bottom: 3px solid #0d142a;
        border-bottom-left-radius: 2rem;
        padding: 1rem solid;
        background-color: #FFFFFF;
        border-top: 0.1rem solid #257c9d;
    }

    nav.active{
        display: block;
    }

    nav a{
        display: block;
        font-size: 2rem;
        margin: 3rem 0;
    }

    nav a:hover,
    nav a.active{
        padding: 1rem;
        border-radius: 0.5rem;
        border-bottom: 0.5rem solid #b74b4b;
    }
}

section{
    min-height: 100vh;
    padding: 5rem 9% 5rem;
}

.home{
    padding: 5rem 9rem 5rem;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 3rem;
    background-color: #FFFFFF;
}

.home, .section {
    scroll-margin-top: 100px; /* ensures smooth scroll doesn’t hide titles */
}


.home .home-content h1{
    font-size: 6rem;
    font-weight: 700;
    line-height: 1.3;
}

span{
    color: #0d142a;
}

.home-content h3{
    font-size: 4rem;
    margin-bottom: 1rem;
    font-weight: 700;
}

.home-content p{
    font-size: 1.6rem;
}

.home-img{
    border-radius: 0;
}

.home-img img{
    position: relative;
    width: 32vw;
    border-radius: 0;
    box-shadow: 0 0 25px solid #b74b4b;
    cursor: pointer;
    transition: 0.2s linear;
}

.home-img img:hover{
    font-size: 1.8rem;
    font-weight: 500;
}

.social-icons a{
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 4rem;
    height: 4rem;
    background-color: transparent;
    border: 0.2rem solid #0d142a;
    font-size: 2rem;
    border-radius: 50%;
    margin: 3rem 1.5rem 3rem 0;
    transition: 0.3s ease;
    color: #0d142a;
}

.social-icons a:hover{
    color: white;
    transform: scale(1.3) translateY(-5px);
    background-color: #0d142a;
    box-shadow: 0  0 25px #0d142a;
}

.btn{
    display: inline-block;
    padding: 1rem 2.8rem;
    background-color: white;
    border-radius: 4rem;
    font-size: 1.6rem;
    color: #0d142a;
    letter-spacing: 0.3rem;
    font-weight: 600;
    border: 2px solid #0d142a;
    transition: 0.3s ease;
    cursor: pointer;
}

.btn:hover{
    transform: scale3d(1.03);
    background-color: #0d142a;
    color: #FFFFFF;
    box-shadow: 0 0 25px #0d142a;
}

.typing-text{
    font-size: 34px;
    font-weight: 600;
    min-width: 280px;
}

.typing-text span{
    position: relative;
}

.typing-text span::before{
    content: "software Developer";
    color: #257c9d;
    animation: words 20s infinite;
}

.typing-text span::after{
    content: "";
    background-color: #FFFFFF;
    position: absolute;
    width: calc(100% + 8px);
    height: 100%;
    border-left: 3px solid #FFFFFF;
    right: -8;
    animation: cursor 0.6s infinite;
}

@keyframes cursor{
    to{
        border-left: 3px solid #257c9d;
    }
}

@keyframes words{
    0%, 20%{
        content: "Trucking";
    }
    21%, 40%{
        content: "Logistics";
    }
    41%, 60%{
        content: "Safety";
    }
    61%, 80%{
        content: "Dedication";
    }
    81%, 100%{
        content: "Satisfaction";
    }
}

@media (max-width: 1000px){
    .home{
        gap: 4rem;
    }
}

@media(max-width:995px){
    .home{
        flex-direction: column;
        margin: 5rem 4rem;
    }

    .home .home-content h3{
        font-size: 2.5rem;
    }

    .home-content h1{
        font-size: 5rem;
    }

    .home-img img{
        width: 70vw;
        margin-top: 4rem;
    }
}
.section {
    padding: 4rem 9%;
    min-height: auto;
    background-color: #f8f8f8; /* light gray for alternating look */
    color: #0d142a;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    gap: 2rem;
}

.section:nth-of-type(even) {
    background-color: #ffffff; /* alternate section colors for contrast */
}

.section h2 {
    font-size: 4rem;
    margin-bottom: 1rem;
    font-weight: 700;
    color: #0d142a;
}

.section p {
    font-size: 1.6rem;
    line-height: 1.6;
}

/* Add spacing after header so content is not hidden behind fixed nav */
body {
    scroll-behavior: smooth;
}

.home, .section {
    scroll-margin-top: 120px; /* compensate for fixed header */
}

/* SERVICES SECTION BOXES */
.service-container {
    display: flex;
    justify-content: space-between;
    gap: 2rem;
    margin-top: 1rem;
    flex-wrap: wrap; /* responsive */
}

.service-box {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: #257c9d;
    background-color: #f0f4f8; /* light gray box */
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
    flex: 1 1 30%; /* 3 boxes in a row, flexible */
    transition: transform 0.3s ease, background-color 0.3s ease, box-shadow 0.3s ease;
}

.service-box h2 {
    font-size: 3rem;
    color: #0d142a; /* accent color */
    margin-bottom: 1rem;
}

.service-box p {
    font-size: 1.5rem;
    color: #0d142a;
    line-height: 1.6;
}

/* HOVER EFFECT */
.service-box:hover {
    color: white;
    transform: translateY(-10px);
    background-color: #257c9d; /* change to accent color */
    color: white;
    box-shadow: 0 12px 25px rgba(37,124,157,0.3);
}

.service-box:hover h2,
.service-box:hover p {
    color: #FFFFFF; /* make text white on hover */
}

/* RESPONSIVE */
@media (max-width: 900px) {
    .service-container {
        flex-direction: column;
        gap: 2rem;
    }
}



/* SAFETY SECTION */
.safety-section {
    padding-top: 30rem;
    background-color: #FFFFFF;
    min-height: auto;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
    gap: 3rem;
    padding-top: 20rem;
}

.safety-content {
    display: flex;
    align-items: center;
    gap: 4rem;
    flex-wrap: wrap;
}

.safety-text {
    flex: 1 1 45%;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease;
}

.safety-img {
    flex: 1 1 25%;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease;
}

.safety-img img {
    width: 100%;
    border-radius: 1rem;
}

/* Animate when in viewport */
.safety-section.visible .safety-text,
.safety-section.visible .safety-img {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive */
@media (max-width: 900px) {
    .safety-content {
        flex-direction: column;
        gap: 2rem;
    }
    .safety-text, .safety-img {
        flex: 1 1 100%;
    }
}

/* Floating animation */
@keyframes float {
    0% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-15px); /* move up by 15px */
    }
    100% {
        transform: translateY(0);
    }
}

.safety-img img {
    width: 100%;
    border-radius: 1rem;
    animation: float 4s ease-in-out infinite; /* slow continuous floating */
}

/* Safety Section Lists */
.safety-text ul {
    font-size: 1.6rem; /* same as paragraphs */
    line-height: 1.8;  /* spacing between items */
    margin-left: 2rem; /* indent the list */
    margin-bottom: 1rem;
    list-style-type: disc; /* standard bullets */
    color: #0d142a; /* make sure text is dark */
}

.safety-text ul li {
    margin-bottom: 0.5rem; /* space between list items */
}



/* CONTACT SECTION */
.contact-section {
    padding-top: 20rem;
    background-color: #f8f8f8;
    min-height: auto;
}

.contact-container {
    display: flex;
    justify-content: space-between;
    gap: 4rem;
    flex-wrap: wrap;
    align-items: flex-start;
}

.contact-info {
    flex: 1 1 40%;
    font-size: 1.6rem;
    line-height: 2;
    color: #0d142a;
}

.contact-info p {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.contact-info i {
    color: #257c9d; /* accent color for icons */
    font-size: 2rem;
}

/* Contact Form */
.contact-form {
    flex: 1 1 50%;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-form input,
.contact-form textarea {
    padding: 1rem 1.5rem;
    font-size: 1.6rem;
    border: 2px solid #ccc;
    border-radius: 0.8rem;
    transition: all 0.3s ease;
    width: 100%;
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: #257c9d;
    box-shadow: 0 0 10px rgba(37,124,157,0.2);
    outline: none;
}

.contact-form button {
    align-self: flex-start;
    padding: 1rem 3rem;
    font-size: 1.6rem;
    border-radius: 4rem;
    border: 2px solid #257c9d;
    background-color: #257c9d;
    color: #fff;
    cursor: pointer;
    transition: all 0.3s ease;
}

.contact-form button:hover {
    background-color: #fff;
    color: #257c9d;
    transform: scale(1.05);
    box-shadow: 0 0 15px rgba(37,124,157,0.3);
}

/* Responsive */
@media(max-width:900px) {
    .contact-container {
        flex-direction: column;
        gap: 3rem;
    }
}


/* Common fade-up animation */
.section {
    opacity: 0;
    transform: translateY(20px);
    transition: all 1s ease;
}

.section.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Optional: pop effect */
.section.pop {
    transform: scale(0.95) translateY(30px);
    transition: all 0.8s ease-out;
}

.section.pop.visible {
    transform: scale(1) translateY(0);
    opacity: 1;
}

/* Contact button animation when Contact section is visible */
.btn-contact-animate {
    animation: bounce 1s ease infinite;
    box-shadow: 0 0 25px #257c9d;
}

/* Bounce animation */
@keyframes bounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}
