/* CSS Variables for Theme */
:root {
    --primary-color: #007bff; /* A professional blue */
    --secondary-color: #6c757d; /* A subtle grey */
    --text-color: #333;
    --background-color: #fff;
    --section-bg-color: #f8f9fa; /* Light grey for alternate sections */
    --card-background: #fff;
    --border-color: #dee2e6;
    --header-height: 60px;

    /* Dark Theme Variables */
    --dark-text-color: #e9ecef;
    --dark-background-color: #212529;
    --dark-section-bg-color: #343a40;
    --dark-card-background: #454d55;
    --dark-border-color: #495057;
}

/* Theme Toggle */
body.dark-theme {
    --text-color: var(--dark-text-color);
    --background-color: var(--dark-background-color);
    --section-bg-color: var(--dark-section-bg-color);
    --card-background: var(--dark-card-background);
    --border-color: var(--dark-border-color);
    color: var(--text-color);
    background-color: var(--background-color);
}

body.dark-theme header {
    background-color: var(--dark-section-bg-color);
    border-bottom-color: var(--dark-border-color);
}

body.dark-theme header nav a {
    color: var(--dark-text-color);
}

body.dark-theme .section {
    background-color: var(--background-color);
}

body.dark-theme .section.bg-light {
    background-color: var(--dark-section-bg-color);
}

body.dark-theme .testimonial-item,
body.dark-theme .blog-articles article {
    background-color: var(--dark-card-background);
    border-color: var(--dark-border-color);
}

body.dark-theme .contact-form,
body.dark-theme .contact-info {
     background-color: var(--dark-card-background);
    border-color: var(--dark-border-color);
}

body.dark-theme .contact-form input,
body.dark-theme .contact-form textarea {
    background-color: #6c757d; /* A slightly lighter dark for inputs */
    color: var(--dark-text-color);
    border-color: var(--dark-border-color);
}
body.dark-theme .contact-form input::placeholder,
body.dark-theme .contact-form textarea::placeholder {
    color: rgba(var(--dark-text-color), 0.7);
}


body.dark-theme footer {
     background-color: var(--dark-section-bg-color);
     border-top-color: var(--dark-border-color);
     color: var(--dark-text-color);
}

body.dark-theme footer a {
    color: var(--primary-color); /* Keep primary for links */
}


/* Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--background-color);
    scroll-behavior: smooth; /* Smooth scrolling */
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

img {
    max-width: 100%;
    height: auto;
}

a {
    color: var(--primary-color);
    text-decoration: none;
}

a:hover {
    opacity: 0.8;
}

ul {
    list-style: none;
}

/* Header */
header {
    background: var(--background-color);
    color: var(--text-color);
    padding: 10px 0;
    position: sticky; /* Fixed header */
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    border-bottom: 1px solid var(--border-color);
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap; /* Allow wrapping on small screens */
}

header .logo img {
    height: auto;
    width: 150px; /* Increased logo size */
}

header nav ul {
    display: flex;
    gap: 20px;
}

header nav a {
    color: var(--text-color);
    font-weight: bold;
    padding: 5px 0;
    position: relative;
}

header nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    transition: width 0.3s ease-in-out;
}

header nav a:hover::after {
    width: 100%;
}

#theme-toggle {
    background: none;
    border: none;
    font-size: 1.5em;
    cursor: pointer;
    padding: 5px;
}

/* Hero Section */
.hero {
    background: var(--section-bg-color); /* Use a background color */
    padding: 60px 0;
    display: flex;
    align-items: center;
    min-height: calc(100vh - var(--header-height)); /* Full height minus header */
}

.hero .container {
    display: flex;
    align-items: center;
    gap: 40px;
    flex-wrap: wrap; /* Allow wrapping */
}

.hero-content {
    flex: 1;
    min-width: 300px; /* Ensure it doesn't get too small */
}

.hero-content h1 {
    font-size: 2.5em;
    margin-bottom: 20px;
    color: var(--primary-color);
}

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

.hero-buttons .btn {
    display: inline-block;
    padding: 12px 25px;
    border-radius: 5px;
    text-align: center;
    margin-right: 15px;
    transition: background-color 0.3s ease;
}

.hero-buttons .btn.primary {
    background-color: var(--primary-color);
    color: #fff;
    border: 1px solid var(--primary-color);
}

.hero-buttons .btn.primary:hover {
    background-color: #0056b3;
}

.hero-buttons .btn.secondary {
    background-color: transparent;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
}

.hero-buttons .btn.secondary:hover {
    background-color: var(--primary-color);
    color: #fff;
}

.hero-image {
    flex: 1;
    min-width: 300px;
    text-align: center;
}

.hero-image img {
     max-height: 400px; /* Decreased hero image size */
     width: auto;
}


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

.section.bg-light {
    background-color: var(--section-bg-color);
}

.section-icon {
    width: 48px; /* Adjusted section icon size */
    height: auto;
    margin-bottom: 20px;
}

.section h2 {
    font-size: 2em;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.section p {
    font-size: 1.1em;
    margin-bottom: 30px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* About Section */
.about-highlights {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 30px;
    margin-top: 40px;
}

.highlight-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.1em;
    color: var(--text-color);
}

.about-highlights img {
    width: 32px; /* Adjusted icon size within about section */
    height: auto;
}

/* Inline icons for text */
.inline-icon {
    vertical-align: middle; /* Align icons with text */
    width: 24px; /* Decreased size as requested */
    height: auto;
    margin-right: 5px; /* Add a little space after the icon */
}


/* Services & Advantages Sections */
#servicos ul, #vantagens ul {
    list-style: none;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    text-align: left;
    max-width: 900px;
    margin: 30px auto 0 auto;
}

#servicos ul li, #vantagens ul li {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 1.1em;
}

#servicos ul li img, #vantagens ul li img {
    width: 32px; /* Adjusted icon size in lists */
    height: auto;
}

/* Steps Section */
.steps-list {
    list-style: none;
    padding: 0;
    max-width: 700px;
    margin: 40px auto 0 auto;
    text-align: left;
    position: relative;
}

.steps-list::before {
    content: '';
    position: absolute;
    top: 0;
    left: 25px; /* Adjust based on step-number size */
    width: 2px;
    height: 100%;
    background: var(--primary-color);
    z-index: 1;
}


.steps-list li {
    display: flex;
    align-items: flex-start; /* Align items to the top */
    margin-bottom: 40px;
    position: relative;
    z-index: 2;
    gap: 20px; /* Space between number and content */
}

.step-number {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 50px; /* Circle size */
    height: 50px; /* Circle size */
    background: var(--primary-color);
    color: #fff;
    border-radius: 50%;
    font-size: 1.5em;
    font-weight: bold;
    flex-shrink: 0; /* Prevent shrinking */
    box-shadow: 0 0 0 5px var(--background-color); /* Create a gap from the line */
}

body.dark-theme .step-number {
    box-shadow: 0 0 0 5px var(--dark-background-color);
}

.step-content h3 {
    font-size: 1.3em;
    margin-bottom: 5px;
    color: var(--primary-color);
}

.step-content p {
     margin: 0; /* Remove default paragraph margin */
     max-width: none; /* Remove max-width restriction */
     text-align: left;
}


/* Testimonials Section */
.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.testimonial-item {
    background: var(--card-background);
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    text-align: left;
    border: 1px solid var(--border-color);
}

.testimonial-item p {
    font-style: italic;
    margin-bottom: 15px;
    max-width: none; /* Remove max-width */
}

.testimonial-item cite {
    display: block;
    font-weight: bold;
    color: var(--secondary-color);
    text-align: right;
}

/* Blog Section */
.blog-articles {
     display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.blog-articles article {
    background: var(--card-background);
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    text-align: left;
    border: 1px solid var(--border-color);
}

.blog-articles h3 {
    font-size: 1.2em;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.blog-articles p {
    font-size: 1em;
    margin-bottom: 15px;
     max-width: none; /* Remove max-width */
}

.blog-articles .read-more {
    display: inline-block;
    color: var(--primary-color);
    font-weight: bold;
}

/* Contact Section */
.contact-content {
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
    text-align: left;
    margin-top: 40px;
}

.contact-form {
    flex: 2; /* Takes more space */
    min-width: 300px;
    background: var(--card-background);
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
     border: 1px solid var(--border-color);
}

.contact-info {
    flex: 1; /* Takes less space */
     min-width: 250px;
     background: var(--card-background);
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
     border: 1px solid var(--border-color);
}

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

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

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    font-size: 1em;
     background-color: var(--background-color);
    color: var(--text-color);
}

.contact-info h3 {
    font-size: 1.3em;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.contact-info p,
.contact-info address {
    margin-bottom: 15px;
    font-size: 1.1em;
    line-height: 1.8;
}

.contact-info a {
    color: var(--text-color); /* Match text color */
}

.contact-info a:hover {
    color: var(--primary-color); /* Hover with primary color */
}


/* Footer */
footer {
    background: var(--section-bg-color);
    color: var(--text-color);
    padding: 30px 0;
    text-align: center;
    border-top: 1px solid var(--border-color);
}

footer .container {
    display: flex;
    flex-direction: column; /* Stack items vertically */
    align-items: center;
    gap: 20px;
}

.footer-info p,
.footer-info address {
    margin-bottom: 10px;
    font-size: 0.9em;
}

.footer-info a {
    color: var(--text-color); /* Match text color */
}

.footer-info a:hover {
     color: var(--primary-color); /* Hover with primary color */
}


.footer-links a {
    margin: 0 10px;
    font-size: 0.9em;
}

.social-icons img {
    width: 32px; /* Adjusted social icon size */
    height: auto;
    margin: 0 5px;
}


/* Responsiveness */
@media (max-width: 768px) {
    header .container {
        flex-direction: column;
        gap: 15px;
    }

    header nav ul {
        justify-content: center;
        gap: 15px;
    }

    .hero .container {
        flex-direction: column-reverse; /* Image on top on small screens */
        text-align: center;
    }

    .hero-buttons {
        justify-content: center;
        display: flex; /* Use flexbox for buttons */
        flex-wrap: wrap; /* Allow buttons to wrap */
        gap: 10px; /* Add space between wrapped buttons */
    }

     .hero-buttons .btn {
         margin-right: 0; /* Remove margin for flex gap */
     }


    .section h2 {
        font-size: 1.8em;
    }

    #servicos ul, #vantagens ul {
        grid-template-columns: 1fr; /* Stack items */
        text-align: center;
    }

    #servicos ul li, #vantagens ul li {
        justify-content: center;
    }

     .steps-list::before {
        left: 50%; /* Center line */
        transform: translateX(-50%);
     }

     .steps-list li {
         flex-direction: column; /* Stack number and content */
         align-items: center;
         text-align: center;
     }

     .step-number {
        margin-bottom: 10px; /* Space below the number */
        box-shadow: 0 0 0 5px var(--background-color); /* Ensure gap around centered line */
     }

      body.dark-theme .step-number {
            box-shadow: 0 0 0 5px var(--dark-background-color);
        }


     .step-content h3,
     .step-content p {
         text-align: center; /* Center text content */
     }


    .testimonials-grid,
    .blog-articles {
        grid-template-columns: 1fr; /* Stack items */
    }

     .testimonial-item,
     .blog-articles article {
         text-align: center; /* Center content */
     }

     .testimonial-item cite {
         text-align: center; /* Center cite */
     }


    .contact-content {
        flex-direction: column; /* Stack contact form and info */
    }

    .contact-form,
    .contact-info {
        min-width: auto; /* Remove min-width restriction */
        width: 100%;
    }

    footer .container {
        gap: 15px;
    }
     .social-icons {
         margin-top: 10px; /* Add space above social icons */
     }
}