/* Basic Reset and Global Styles */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    background-color: #f4f4f4;
    color: #333;
}

.container {
    max-width: 1100px;
    margin: auto;
    overflow: hidden;
    padding: 0 20px;
}

h1, h2, h3 {
    font-family: 'Oswald', sans-serif;
    font-weight: 500;
}

h1 { font-size: 2.5em; }
h2 { font-size: 2em; margin-bottom: 20px; }
h3 { font-size: 1.5em; margin-bottom: 10px; }

/* Header and Navigation */
header {
    background: #004d40; /* Dark Teal */
    color: #fff;
    padding: 1rem 0;
    text-align: center;
}

header .tagline {
    font-size: 1.2em;
    margin-bottom: 15px;
}

header nav ul {
    list-style: none;
    display: flex;
    justify-content: center;
}

header nav ul li {
    margin: 0 15px;
}

header nav ul li a {
    color: #fff;
    text-decoration: none;
    font-weight: 700;
    transition: color 0.3s ease;
}

header nav ul li a:hover {
    color: #92b0ac; /* Lighter shade for hover */
}

/* Hero Section */
.hero {
    /* Change 'banner.jpg' to your image file name */
    background: url('../images/Banner.jpg') no-repeat center center/cover;
    height: 60vh;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #fff;
    text-align: center;
    position: relative;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* This semi-transparent overlay makes the text easier to read */
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1;
}

.hero .container {
    position: relative;
    z-index: 2;
}

.hero h2 {
    font-size: 3em;
    margin-bottom: 10px;
}

.hero p {
    font-size: 1.2em;
    margin-bottom: 20px;
}

.btn {
    display: inline-block;
    background: #e65100; /* Orange */
    color: #fff;
    padding: 12px 25px;
    text-decoration: none;
    border-radius: 5px;
    font-weight: 700;
    transition: background-color 0.3s ease;
}

.btn:hover {
    background: #bf360c; /* Darker orange */
}

/* Section Styles */
section {
    padding: 60px 0;
    text-align: center;
}

section:nth-of-type(odd) {
    background-color: #fcfcfc;
}


/* --- MODIFIED: ABOUT US LAYOUT (Image Below Text) --- */
.about-content {
    display: flex;
    flex-direction: column; /* NEW: Forces stacking vertically */
    align-items: center; /* Centers the block within the container */
    gap: 30px;
    text-align: left;
    margin-top: 30px; 
}
.about-text {
    flex: none; /* Removed flex sizing */
    width: 100%; /* Ensures text block uses full available width */
}
.about-image {
    flex: none; /* Removed flex sizing */
    width: 100%; /* Ensures image block uses full available width for centering */
    text-align: center;
}
.about-image img {
    /* Keep existing styles */
    max-width: 400px; /* Optional: Sets a max size for the image on desktop */
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    margin-top: 10px;
}
/* --- END MODIFIED ABOUT US LAYOUT --- */
/* --- END ABOUT US LAYOUT --- */

/* Services Section */
.service-list {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 30px;
}

.service-item {
    background: #fff;
    padding: 20px;
    border: 1px solid #ddd;
    border-radius: 8px;
    flex: 1 1 200px;
    text-align: left;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.service-item ul {
    list-style: none;
    padding-left: 0;
}

.service-item li {
    padding: 5px 0;
}

/* --- ADDED: REVIEWS SECTION --- */
.reviews-section {
    background-color: #e8f5e9; /* Light background for contrast */
}
.review-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 30px;
}
.review-box {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    text-align: left;
}
.review-box i {
    color: gold;
    margin-right: 5px;
}
.review-source {
    font-weight: 700;
    color: #004d40;
    margin-top: 10px;
    display: block;
}
/* --- END REVIEWS SECTION --- */


/* Contact Form */
.contact-section form {
    max-width: 600px;
    margin: 20px auto;
    display: flex;
    flex-direction: column;
    text-align: left;
}

.contact-section label {
    margin-top: 10px;
    font-weight: 700;
}

.contact-section input, .contact-section textarea {
    width: 100%;
    padding: 10px;
    margin-top: 5px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.contact-section .btn {
    margin-top: 20px;
    width: 100%;
    border: none;
    cursor: pointer;
}

/* Footer */
footer {
    background: #333;
    color: #fff;
    text-align: center;
    padding: 20px 0;
}

/* --- Our Work Page Specific Styles --- */

.work-section {
    background-color: #fff;
    padding: 60px 0;
    text-align: center;
}

.work-section .intro-text {
    max-width: 800px;
    margin: 0 auto 40px;
    font-size: 1.1em;
}

.job-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.job-item {
    background: #f9f9f9;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.job-item:hover {
    transform: translateY(-5px);
}

.job-item img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    display: block;
}

.job-details {
    padding: 20px;
    text-align: left;
}

.job-details h3 {
    margin-top: 0;
    font-size: 1.5em;
    color: #004d40;
}

.job-details .location {
    font-style: italic;
    color: #666;
    margin-top: 5px;
}

/* --- Social Media Links Styles --- */
.social-links {
    margin-top: 15px;
    display: flex;
    justify-content: center;
    gap: 20px;
}

.social-links a {
    color: #fff;
    font-size: 24px;
    transition: color 0.3s ease;
}

.social-links a:hover {
    color: #e65100; /* Orange color from your button style */
}

/* --- Blog --- */

aside {
    flex: 1; /* Sidebar takes up less space */
    background-color: #fff;
    padding: 20px;
    border-radius: 5px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.05);
    height: fit-content; /* Stops sidebar from stretching full height */
}
.post-preview {
    background-color: #fff;
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 5px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.05);
}
.post-preview h2 a {
    color: #007bff;
    text-decoration: none;
}
.post-meta {
    font-size: 0.9em;
    color: #777;
    margin-bottom: 10px;
}

.blogcontainer {
    max-width: 900px;
    margin: 20px auto;
    padding: 0 20px;
    display: flex; /* Flexbox for main content and sidebar */
    gap: 30px;
}
main {
    flex: 3; /* Main content takes up more space */
}

/* --- Carousel Styles for Image Gallery --- */

.carousel-container {
    width: 100%;
    height: 300px; 
    position: relative;
    overflow: hidden; 
    margin-bottom: 0;
}

.carousel-track {
    display: flex;
    height: 100%;
    transition: transform 0.4s ease-in-out; 
}

.slide {
    flex: 0 0 100%; 
    max-width: 100%;
}

.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: #fff;
    border: none;
    padding: 10px 15px;
    font-size: 18px;
    cursor: pointer;
    z-index: 10;
    transition: background-color 0.3s;
}

.arrow:hover {
    background: rgba(230, 81, 0, 0.8);
}

.prev-btn { 
    left: 10px; 
    border-radius: 4px 0 0 4px;
}
.next-btn { 
    right: 10px; 
    border-radius: 0 4px 4px 0;
}

/* ========================================================== */
/* MOBILE RESPONSIVENESS (MAX-WIDTH: 768px)         */
/* ========================================================== */

@media screen and (max-width: 768px) {
    
    /* Global Adjustments */
    section {
        padding: 40px 0;
    }
    
    h1 { font-size: 2em; }
    h2 { font-size: 1.8em; margin-bottom: 15px; }
    h3 { font-size: 1.3em; }

    /* Header & Navigation */
    header .tagline {
        font-size: 1em;
        margin-bottom: 10px;
    }

    header nav ul {
        /* Changes horizontal flex to stacked flex */
        flex-direction: column;
        align-items: center;
    }
    
    header nav ul li {
        margin: 5px 0;
    }

    /* Hero Section */
    .hero {
        height: 50vh; /* Reduces height on mobile */
    }

    .hero h2 {
        font-size: 2em;
        line-height: 1.2;
    }
    
    .hero p {
        font-size: 1em;
    }


    
    /* Services Section */
    .service-list {
        /* Makes all service items stack vertically */
        flex-direction: column;
        gap: 15px;
    }

    .service-item {
        flex: 1 1 100%;
    }
    
    /* Reviews Grid - Stacks review boxes vertically */
    .review-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    /* Work Gallery */
    .job-gallery {
        /* Changes to a single column layout */
        grid-template-columns: 1fr;
        gap: 20px;
    }

    /* Blog Layout */
    .blogcontainer {
        flex-direction: column; /* Stacks main content and sidebar */
        gap: 20px;
        margin-top: 10px;
    }
    
    aside {
        order: 1; /* Puts the sidebar at the top */
    }
    
    main {
        order: 2;
    }

    /* Footer */
    footer p, footer a {
        font-size: 0.9em;
    }

    .social-links {
        margin-top: 10px;
        gap: 15px;
    }
}