/* =========================================================================
   1. CSS VARIABLES & THEME TOKENS 
   (GlobalTruck Industry Design System)
========================================================================= */

:root {
    /* Colors */
    --color-dark: #0D1B2A;           /* Dark Navy */
    --color-dark-faded: rgba(13, 27, 42, 0.4);
    --color-dark-overlay: rgba(13, 27, 42, 0.7);
    --color-brand: #1A3A5C;          /* Deep Blue */
    --color-brand-secondary: #FF7A00; /* Orange Highlight */
    --color-brand-secondary-hover: #E66D00;
    --color-light: #FAFAFA;          /* Light Background */
    --color-light-faded: #F5F5F5;    /* Cards/Alt Background */
    --color-white: #FFFFFF;

    /* Typography */
    --font-heading: 'Inter', sans-serif;
    --font-body: 'DM Sans', sans-serif;
    
    /* Layout & Spacing */
    --container-max-width: 1280px;
    --padding-x: 40px;
    --padding-x-mobile: 24px;
    --section-padding: 100px;
    --section-padding-mobile: 60px;
    --gap-standard: 32px;
    --radius-sm: 4px;
    --radius-md: 6px;
    --radius-lg: 12px;
    
    /* Transitions */
    --transition-fast: 0.2s ease-in-out;
    --transition-smooth: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* =========================================================================
   2. RESET & BASE
========================================================================= */

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-body);
    font-weight: 400;
    line-height: 1.6;
    color: var(--color-dark);
    background-color: var(--color-light);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    color: var(--color-dark);
    line-height: 1.2;
    margin-bottom: 1rem;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color var(--transition-fast);
}

ul {
    list-style: none;
}

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

/* =========================================================================
   3. TYPOGRAPHY
========================================================================= */

h1 { font-size: clamp(3rem, 5vw, 4.5rem); font-weight: 800; letter-spacing: -0.02em; }
h2 { font-size: clamp(2rem, 4vw, 3.25rem); font-weight: 700; letter-spacing: -0.01em; }
h3 { font-size: clamp(1.5rem, 2vw, 2.25rem); font-weight: 600; }
h4 { font-size: clamp(1.25rem, 1.5vw, 1.625rem); font-weight: 600; }

.text-highlight {
    color: var(--color-brand-secondary);
}

.eyebrow {
    font-family: var(--font-heading);
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--color-brand-secondary);
    margin-bottom: 1rem;
    display: inline-block;
}

/* =========================================================================
   4. LAYOUT UTILITIES
========================================================================= */

.container {
    width: 100%;
    max-width: var(--container-max-width);
    margin: 0 auto;
    padding: 0 var(--padding-x);
}

.section-padding {
    padding: var(--section-padding) 0;
}

.bg-dark {
    background-color: var(--color-dark);
    color: var(--color-white);
}

.bg-dark h1, .bg-dark h2, .bg-dark h3, .bg-dark h4 {
    color: var(--color-white);
}

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

.text-center { text-align: center; }
.mx-auto { margin-left: auto; margin-right: auto; }

/* =========================================================================
   5. COMPONENTS
========================================================================= */

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 2rem;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1rem;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
    border: none;
    line-height: 1;
}

.btn-primary {
    background-color: var(--color-brand-secondary);
    color: var(--color-white);
}

.btn-primary:hover {
    background-color: var(--color-brand-secondary-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 122, 0, 0.3);
}

.btn-secondary {
    background-color: transparent;
    color: var(--color-white);
    border: 1px solid rgba(255,255,255,0.3);
}

.btn-secondary:hover {
    background-color: var(--color-white);
    color: var(--color-dark);
}

.btn-large {
    padding: 1.125rem 2.5rem;
    font-size: 1.125rem;
}

.btn-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    color: var(--color-brand-secondary);
    font-family: var(--font-heading);
    text-transform: uppercase;
    font-size: 0.875rem;
    letter-spacing: 0.05em;
    margin-top: 1.5rem;
}

.btn-link:hover {
    gap: 0.75rem;
}

/* =========================================================================
   6. HEADER & NAVIGATION
========================================================================= */

.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 1.5rem 0;
    transition: background-color var(--transition-fast), padding var(--transition-fast);
}

.header.scrolled {
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 1rem 0;
    box-shadow: 0 4px 24px rgba(0,0,0,0.1);
}

.header.scrolled .nav-link {
    color: var(--color-dark);
}

.header.scrolled .nav-link:hover, .header.scrolled .nav-link.active {
    color: var(--color-brand-secondary);
}

.header.scrolled .mobile-menu-toggle {
    color: var(--color-dark);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: inline-flex;
    align-items: center;
}

.logo-img {
    height: 55px;
    width: auto;
    object-fit: contain;
}

.nav {
    display: flex;
    align-items: center;
    gap: 2.5rem;
}

.nav-list {
    display: flex;
    gap: 2rem;
}

.nav-link {
    color: rgba(255,255,255,0.8);
    font-weight: 500;
    position: relative;
}

.nav-link:hover, .nav-link.active {
    color: var(--color-white);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--color-brand-secondary);
    transition: width var(--transition-fast);
}

.nav-link:hover::after {
    width: 100%;
}

.mobile-menu-toggle {
    display: none;
    background: transparent;
    border: none;
    color: var(--color-white);
    cursor: pointer;
}

/* =========================================================================
   7. HERO SECTION
========================================================================= */

.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 80px; 
    overflow: hidden;
}

.hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -2;
    transform: scale(1.15); /* Zoom to hide possible text/watermark inside video */
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(13, 27, 42, 0.45);
    z-index: -1;
}

.hero-container {
    max-width: 900px;
    margin: 0; /* Left aligned */
    color: var(--color-white);
}

.hero-title {
    color: var(--color-white);
    margin-bottom: 1.5rem;
}

.hero-subtitle {
    font-size: clamp(1.125rem, 2vw, 1.25rem);
    color: rgba(255,255,255,0.7);
    margin-bottom: 3rem;
    max-width: 600px;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* =========================================================================
   8. STATS SECTION
========================================================================= */

.stats {
    padding: 60px 0;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
}

.stat-item {
    border-left: 2px solid var(--color-brand-secondary);
    padding-left: 1.5rem;
}

.stat-number {
    font-size: 3rem;
    margin-bottom: 0.25rem;
    color: var(--color-white);
}

.stat-label {
    font-family: var(--font-heading);
    font-weight: 500;
    font-size: 1rem;
    color: rgba(255,255,255,0.6);
}

/* =========================================================================
   9. ABOUT SECTION
========================================================================= */

.about-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.section-description {
    font-size: 1.125rem;
    color: #4a5568;
    margin-bottom: 1.5rem;
    max-width: 800px;
}

.bg-dark .section-description {
    color: rgba(255,255,255,0.7);
}

.about-pillars {
    margin-top: 2rem;
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.about-pillars li {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-weight: 600;
    font-family: var(--font-heading);
    color: var(--color-dark);
}

.about-pillars li svg {
    color: var(--color-brand-secondary);
    width: 24px;
    height: 24px;
}

.about-image-wrapper {
    position: relative;
    border-radius: var(--radius-lg);
}

.about-image {
    width: 100%;
    padding-bottom: 120%; /* 5:6 aspect ratio */
    background-image: url('../assets/images/about_engineering.png');
    background-size: cover;
    background-position: center;
    border-radius: var(--radius-md);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.experience-badge {
    position: absolute;
    bottom: -2rem;
    left: -2rem;
    background-color: var(--color-dark);
    color: var(--color-white);
    padding: 2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    border-radius: var(--radius-md);
    border-left: 4px solid var(--color-brand-secondary);
}

.experience-badge .years {
    font-family: var(--font-heading);
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1;
    color: var(--color-brand-secondary);
}

.experience-badge .text {
    font-weight: 600;
    line-height: 1.2;
    font-family: var(--font-heading);
}

/* =========================================================================
   10. SERVICES SECTION
========================================================================= */

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--gap-standard);
    margin-top: 4rem;
}

.service-card {
    background: var(--color-white);
    padding: 3rem 2.5rem;
    border-radius: var(--radius-md);
    box-shadow: 0 4px 20px rgba(0,0,0,0.03);
    transition: transform var(--transition-smooth), box-shadow var(--transition-smooth);
    border: 1px solid rgba(0,0,0,0.04);
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.08);
}

.service-icon {
    width: 64px;
    height: 64px;
    background-color: rgba(255, 122, 0, 0.1);
    color: var(--color-brand-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
    margin-bottom: 1.5rem;
}

.service-icon svg {
    width: 32px;
    height: 32px;
    stroke-width: 1.5;
}

.service-title {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.service-desc {
    color: #4a5568;
}

/* =========================================================================
   11. PROJECTS SECTION
========================================================================= */

.projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--gap-standard);
    margin-top: 3rem;
}

.project-card {
    background: var(--color-white);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.03);
    transition: transform var(--transition-smooth);
}

.project-card:hover {
    transform: translateY(-6px);
}

.project-card:hover .project-img {
    transform: scale(1.05);
}

.project-img {
    width: 100%;
    padding-bottom: 60%;
    background-size: cover;
    background-position: center;
    transition: transform var(--transition-smooth);
}

.bg-img-1 { background-image: url('https://images.unsplash.com/photo-1542289139-44585ecb37e8?auto=format&fit=crop&q=80&w=800'); }
.bg-img-2 { background-image: url('https://images.unsplash.com/photo-1620986799042-4f7380956b6b?auto=format&fit=crop&q=80&w=800'); }
.bg-img-3 { background-image: url('https://images.unsplash.com/photo-1454165804606-c3d57bc86b40?auto=format&fit=crop&q=80&w=800'); }

.project-content {
    padding: 2.5rem;
    position: relative;
    background: var(--color-white);
    z-index: 2;
}

.project-title {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
}

.project-desc {
    color: #4a5568;
    font-size: 0.95rem;
}

/* =========================================================================
   12. CTA BOTTOM SECTION
========================================================================= */

.cta-bottom {
    position: relative;
    padding: 100px 0;
    overflow: hidden;
}

.cta-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: linear-gradient(rgba(13, 27, 42, 0.85), rgba(13, 27, 42, 0.95)), url('https://images.unsplash.com/photo-1587293852726-70cdb56c2866?auto=format&fit=crop&q=80&w=2000');
    background-size: cover;
    background-position: center;
    z-index: -1;
}

.cta-container {
    max-width: 800px;
}

.cta-title {
    color: var(--color-white);
    font-size: clamp(2.5rem, 4vw, 3.5rem);
    margin-bottom: 1.5rem;
}

.cta-desc {
    color: rgba(255,255,255,0.7);
    font-size: 1.25rem;
    margin-bottom: 2.5rem;
}

.cta-actions {
    display: inline-flex;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
}

/* =========================================================================
   13. FOOTER
========================================================================= */

.footer {
    padding: 80px 0 40px;
    border-top: 1px solid rgba(255,255,255,0.05);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1.5fr;
    gap: 4rem;
    margin-bottom: 4rem;
}

.footer-logo {
    display: inline-block;
    margin-bottom: 1.5rem;
}

.footer-logo img {
    filter: brightness(0) invert(1);
}

.footer-text {
    color: rgba(255,255,255,0.6);
    max-width: 400px;
}

.footer-title {
    font-size: 1.125rem;
    margin-bottom: 1.5rem;
}

.footer-links ul {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: rgba(255,255,255,0.6);
    transition: color var(--transition-fast);
}

.footer-links a:hover {
    color: var(--color-brand-secondary);
}

.footer-contact li {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: rgba(255,255,255,0.6);
    margin-bottom: 1rem;
}

.footer-contact li svg {
    color: var(--color-brand-secondary);
    width: 20px;
    height: 20px;
}

.footer-bottom {
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: rgba(255,255,255,0.4);
    font-size: 0.875rem;
}

/* =========================================================================
   14. ANIMATIONS & RESPONSIVE
========================================================================= */

.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

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

@media (max-width: 1024px) {
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .about-container { grid-template-columns: 1fr; gap: 3rem; }
    .services-grid, .projects-grid { grid-template-columns: repeat(2, 1fr); }
    .experience-badge { bottom: 0; left: 0; padding: 1.5rem; }
}

@media (max-width: 768px) {
    :root {
        --padding-x: var(--padding-x-mobile);
        --section-padding: var(--section-padding-mobile);
    }
    
    .mobile-menu-toggle { display: block; }

    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        height: 100vh;
        background-color: var(--color-dark);
        flex-direction: column;
        justify-content: center;
        transition: right 0.3s ease-in-out;
        z-index: -1;
    }

    .nav.open { right: 0; }

    .nav-list {
        flex-direction: column;
        align-items: center;
        gap: 2rem;
        font-size: 1.5rem;
    }

    .hero-bg { background-attachment: scroll; }
    
    .services-grid, .projects-grid { grid-template-columns: 1fr; }
    
    .footer-grid { grid-template-columns: 1fr; gap: 2.5rem; }
    
    .footer-bottom { flex-direction: column; gap: 1rem; text-align: center; }
}

/* =========================================================================
   15. REESTRUTURACAO CUSTOM (COPY ENHANCEMENTS)
========================================================================= */

/* Hero Social Proof */
.hero-social-proof {
    margin-top: 2rem;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.8);
    background: rgba(0,0,0,0.3);
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-sm);
    display: inline-block;
    border-left: 3px solid var(--color-brand-secondary);
}

.hero-social-proof strong {
    color: var(--color-white);
    margin-right: 0.5rem;
}

/* Services 4 Grid */
.services-grid-4 {
    grid-template-columns: repeat(2, 1fr) !important;
}

@media(max-width: 768px) {
    .services-grid-4 {
        grid-template-columns: 1fr !important;
    }
}

/* Tabela Comparativa */
.table-container {
    overflow-x: auto;
    margin-top: 3rem;
}

.comparison-table {
    width: 100%;
    margin: 0 auto;
    border-collapse: collapse;
    background: var(--color-white);
    border-radius: var(--radius-md);
    overflow: hidden;
    color: var(--color-dark);
}

.comparison-table th, .comparison-table td {
    padding: 1.5rem;
    text-align: left;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.comparison-table th {
    background: var(--color-light-faded);
    font-family: var(--font-heading);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.875rem;
    letter-spacing: 0.05em;
}

.comparison-table th.highlight, .comparison-table td.highlight {
    background: rgba(255, 122, 0, 0.05);
    color: var(--color-dark);
}

/* Formulario CTA */
.cta-form-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    max-width: 1000px;
    margin: 0 auto;
}

.cta-form-wrapper {
    background: var(--color-white);
    padding: 2.5rem;
    border-radius: var(--radius-md);
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
}

.form-group {
    margin-bottom: 1.25rem;
}

.lead-form input, .lead-form select, .lead-form textarea {
    width: 100%;
    padding: 1rem 1.25rem;
    border: 1px solid rgba(0,0,0,0.1);
    border-radius: var(--radius-sm);
    font-family: var(--font-body);
    font-size: 1rem;
    color: var(--color-dark);
    background: var(--color-light-faded);
    transition: border-color var(--transition-fast);
}

.lead-form input:focus, .lead-form select:focus, .lead-form textarea:focus {
    outline: none;
    border-color: var(--color-brand-secondary);
}

.w-100 {
    width: 100%;
}

@media(max-width: 900px) {
    .cta-form-container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
    }
}

/* =========================================================================
   16. WHATSAPP FLOATING BUTTON
========================================================================= */

.whatsapp-float {
    position: fixed;
    width: 60px;
    height: 60px;
    bottom: 30px;
    right: 30px;
    background-color: #25D366;
    color: #FFF;
    border-radius: 50px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
}

.whatsapp-float svg {
    width: 35px;
    height: 35px;
    fill: currentColor;
}

.whatsapp-float:hover {
    background-color: #1ebe57;
    color: #FFF;
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 6px 16px rgba(37, 211, 102, 0.4);
}

@keyframes pulse-wa {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7); }
    70% { transform: scale(1.05); box-shadow: 0 0 0 15px rgba(37, 211, 102, 0); }
    100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

.whatsapp-float {
    animation: pulse-wa 2s infinite;
}

.whatsapp-float:hover {
    animation: none;
}
