/* Reset default styles for consistency across browsers */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Open Sans', sans-serif; /* Default sans-serif; can be adjusted later */
    line-height: 1.6;
    color: #001F3F; /* Dark blue for text */
    background-color: #F5F5F5; /* Off-white background */
}

/* Hero Banner Styles (Landing Page Specific) */
.hero-banner {
    width: 100%;
    height: 100vh; /* Full viewport height */
    background: url('images/hero.jpg') no-repeat center center/cover; /* Hero image as background */
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero-content {
    padding: 20px;
}

.hero-logo {
    max-width: 300px; /* Large logo for landing */
    margin-bottom: 20px;
}

.tagline {
    font-size: 1.5em;
    color: #F5F5F5; /* Off-white for contrast on dark hero */
    margin-bottom: 20px;
}

.cta-button {
    display: inline-block;
    padding: 10px 20px;
    background-color: #007BFF; /* Light blue accent */
    color: #F5F5F5;
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s;
    cursor: pointer; /* For buttons across site */
}

.cta-button:hover {
    background-color: #0056b3; /* Darker blue on hover */
}

/* Page Banner Styles (For non-landing pages like About, Team, etc.) */
.page-banner {
    width: 100%;
    padding: 60px 20px;
    background-color: #001F3F; /* Dark blue background */
    text-align: center;
    color: #F5F5F5;
}

.banner-content h1 {
    font-size: 2.5em;
    margin-bottom: 10px;
}

.banner-content p {
    font-size: 1.2em;
}

/* Navbar Styles (Fixed-top, hidden initially on landing, shrinks on scroll) */
.navbar {
    background-color: #001F3F;
    padding: 10px 20px;
    position: fixed;
    top: 0;
    width: 100%;
    display: flex;
    justify-content: space-between; /* Ensures space for right-aligned elements */
    align-items: center;
    transition: all 0.3s ease; /* Smooth shrink effect via JS */
    z-index: 1000;
}

.navbar-container {
    display: flex;
    align-items: center;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    justify-content: space-between; /* Added to space logo left and hamburger right on mobile */
}

.navbar-logo {
    max-width: 80px; /* Shrunk logo for navbar */
    margin-right: 20px; /* Space from links on desktop */
}

.nav-links {
    list-style: none;
    display: flex;
}

.nav-links li {
    margin-left: 20px;
}

.nav-links a {
    color: #F5F5F5;
    text-decoration: none;
    font-size: 1em;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: #007BFF;
}

.hamburger {
    display: none; /* Hidden on desktop; JS toggles for mobile */
}

.hamburger span {
    display: block;
    width: 30px; /* Increased slightly from 25px for better visibility */
    height: 4px; /* Increased thickness from 3px for prominence */
    background-color: #F5F5F5 !important; /* Explicit off-white with !important to resist dark mode overrides */
    margin: 5px 0;
    transition: all 0.3s;
}

/* Main Section Styles (Alternating text/image, fade-in for JS) */
main {
    padding: 50px 20px; /* Reduced top padding from 60px to match thinner navbar */
    max-width: 1200px;
    margin: 0 auto;
}

.section {
    margin-bottom: 40px;
}

.content-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap; /* Stack on mobile */
    gap: 20px;
}

.text-block, .image-block {
    flex: 1;
    min-width: 300px; /* Prevent too narrow on medium screens */
    padding: 20px;
}

.text-block h2 {
    margin-bottom: 15px;
    color: #001F3F;
}

.text-block p {
    margin-bottom: 15px;
}

.stats-list, .values-list {
    list-style: none;
    padding-left: 20px;
}

.stats-list li, .values-list li {
    margin-bottom: 10px;
    position: relative;
}

.stats-list li:before, .values-list li:before {
    content: "•";
    color: #007BFF;
    position: absolute;
    left: -15px;
}

.section-image {
    max-width: 100%;
    height: auto;
    border-radius: 5px;
}

.highlights-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.highlight-item {
    text-align: center;
}

.highlight-icon {
    max-width: 50px;
    margin-bottom: 10px;
}

/* Accordion Styles (Shared for Team bios and Services details) */
.accordion-toggle {
    background-color: #007BFF;
    color: #F5F5F5;
    border: none;
    padding: 10px 15px;
    width: 100%;
    text-align: left;
    cursor: pointer;
    font-size: 1em;
    border-radius: 5px;
    transition: background-color 0.3s;
    margin-top: 10px;
}

.accordion-toggle:hover {
    background-color: #0056b3;
}

.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease; /* Smooth expand/collapse */
    padding: 0 15px;
}

.accordion-content.active {
    max-height: 500px; /* Adjust based on content; or use auto with JS */
    padding: 15px;
}

/* Team Page Styles */
.team-section {
    margin-bottom: 40px;
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.team-card {
    background-color: #FFFFFF; /* White for contrast on off-white body */
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    padding: 20px;
    text-align: center;
}

.employee-photo {
    max-width: 150px;
    height: auto;
    border-radius: 50%; /* Circular photos for modern feel */
    margin-bottom: 15px;
}

.employee-name {
    font-size: 1.2em;
    margin-bottom: 5px;
}

.employee-role {
    font-size: 1em;
    color: #666; /* Gray for subtlety */
    margin-bottom: 10px;
}

/* Services Page Styles */
.services-section {
    margin-bottom: 40px;
}

.service-item {
    margin-bottom: 30px;
    border-bottom: 1px solid #ddd; /* Separator between services */
    padding-bottom: 20px;
}

.testimonials-section {
    margin-bottom: 40px;
    text-align: center;
}

.testimonials-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.testimonial {
    background-color: #FFFFFF;
    border-radius: 5px;
    padding: 20px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    font-style: italic;
}

.testimonial cite {
    display: block;
    margin-top: 10px;
    font-style: normal;
    color: #666;
}

.clients-section {
    margin-bottom: 40px;
    text-align: center;
}

.clients-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
}

.client-logo {
    max-width: 150px;
    height: auto;
}

/* Blog Page Styles */
.blog-section {
    margin-bottom: 40px;
}

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

.blog-post {
    background-color: #FFFFFF;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.post-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.post-title {
    font-size: 1.2em;
    padding: 15px 15px 0;
}

.post-date {
    font-size: 0.9em;
    color: #666;
    padding: 0 15px;
}

.post-excerpt {
    padding: 0 15px 15px;
    font-size: 1em;
}

.read-more {
    display: block;
    padding: 10px;
    background-color: #007BFF;
    color: #F5F5F5;
    text-align: center;
    text-decoration: none;
    transition: background-color 0.3s;
}

.read-more:hover {
    background-color: #0056b3;
}

/* Contact Page Styles */
.contact-section {
    margin-bottom: 40px;
}

.contact-wrapper {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
}

.contact-form {
    flex: 2;
    min-width: 300px;
}

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

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1em;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: #007BFF;
    outline: none;
}

/* Error style for JS validation */
.form-group.error input,
.form-group.error textarea {
    border-color: #FF0000; /* Red for errors */
}

.contact-info {
    flex: 1;
    min-width: 250px;
    padding: 20px;
    background-color: #FFFFFF;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.contact-info h2 {
    margin-bottom: 15px;
}

/* Fade-in animation (triggered by JS) */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Footer Styles */
footer {
    background-color: #001F3F;
    color: #F5F5F5;
    text-align: center;
    padding: 20px;
    position: relative;
}

.footer-links {
    list-style: none;
    margin-top: 10px;
}

.footer-links li {
    display: inline;
    margin: 0 10px;
}

.footer-links a {
    color: #F5F5F5;
    text-decoration: none;
}

.footer-links a:hover {
    color: #007BFF;
}

.back-to-top {
    background-color: #007BFF;
    color: #F5F5F5;
    border: none;
    padding: 10px;
    border-radius: 50%;
    cursor: pointer;
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: none; /* Hidden initially; JS shows on scroll */
    transition: opacity 0.3s;
}

.back-to-top:hover {
    background-color: #0056b3;
}

/* Responsive Design */
@media (max-width: 768px) {
    .navbar {
        flex-direction: row; /* Changed from column to row for better logo/hamburger alignment */
        padding: 10px;
        justify-content: center; /* Center content horizontally */
    }

    .navbar-container {
        justify-content: space-between; /* Logo left, hamburger right */
        align-items: center;
    }

    .nav-links {
        display: none; /* Hidden by default on mobile; JS toggles */
        width: 100%;
        flex-direction: column;
        text-align: center;
    }

    .nav-links.active {
        display: flex;
    }

    .nav-links li {
        margin: 10px 0;
    }

    .hamburger {
        display: block; /* Visible on mobile */
        order: 1; /* Ensures it's positioned after logo in flex */
    }

    .navbar-logo {
        margin-right: 0; /* Remove right margin on mobile for better spacing */
    }
    .content-wrapper {
        flex-direction: column;
    }

    .text-block, .image-block {
        flex: 100%;
    }

    .hero-banner {
        height: 80vh;
    }

    .hero-logo {
        max-width: 200px;
    }

    .page-banner {
        padding: 40px 20px; /* Adjusted padding from 60px to 40px for mobile */
    }

    .team-grid, .blog-grid, .clients-grid {
        grid-template-columns: 1fr; /* Stack on mobile */
    }

    .contact-wrapper {
        flex-direction: column;
    }

    .testimonials-list {
        flex-direction: column;
    }

    /* New: Add padding to offset navbar on mobile */
    .page-banner {
        padding-top: calc(60px + 10px); /* Offset by navbar height (approx 60px with logo) + extra 10px buffer */
    }
}