/* ==========================================================================
   CSS Variables & Reset
   ========================================================================== */
:root {
    --blue-dark: #0A2D8F;
    --blue-light: #0F7BFF;
    --gradient-primary: linear-gradient(135deg, var(--blue-dark), var(--blue-light));
    
    --bg-primary: #FFFFFF;
    --bg-secondary: #F5F7FA;
    --text-main: #0A0A0A;
    --text-muted: #4B5563;
    --border-color: #E5E7EB;
    
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    
    --radius-md: 12px;
    --radius-lg: 24px;
    --radius-full: 9999px;
    
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Dark Mode Theme */
[data-theme="dark"] {
    --bg-primary: #0A0A0A;
    --bg-secondary: #111111;
    --text-main: #F5F7FA;
    --text-muted: #9CA3AF;
    --border-color: #333333;
}

/* Dark Mode  para menu e forms permanecer na mesma cor */

[data-theme="dark"] .header,
[data-theme="dark"] .contact-container {
    --bg-primary: #FFFFFF;
    --bg-secondary: #F5F7FA;
    --text-main: #0A0A0A;
    --text-muted: #4B5563;
    --border-color: #E5E7EB;
    color: var(--text-main);
}

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

html {
    scroll-behavior: smooth;
    font-family: 'Montserrat', sans-serif;
    color: var(--text-main);
    background-color: var(--bg-primary);
}

body {
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

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

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* ==========================================================================
   Typography & Utilities
   ========================================================================== */
h1, h2, h3, h4 {
    color: var(--text-main);
    line-height: 1.2;
}

h1 { font-size: clamp(2.5rem, 5vw, 4rem); font-weight: 800; letter-spacing: -0.05em; }
h2 { font-size: clamp(2rem, 4vw, 2.5rem); font-weight: 700; margin-bottom: 1rem; }
h3 { font-size: 1.25rem; font-weight: 600; margin-bottom: 0.5rem; }

.text-gradient {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.bg-secondary { background-color: var(--bg-secondary); }
.bg-gradient { background: var(--gradient-primary); }
.text-white { color: #FFFFFF; }
.text-center { text-align: center; }
.w-100 { width: 100%; }

.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 4rem auto;
}
.section-header p {
    color: var(--text-muted);
    font-size: 1.125rem;
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.75rem;
    border-radius: var(--radius-full);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    font-size: 1rem;
}

.btn-primary {
    background: var(--gradient-primary);
    color: #FFFFFF;
    box-shadow: var(--shadow-md);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
    opacity: 0.95;
}

.btn-secondary {
    background: transparent;
    color: var(--text-main);
    border: 1px solid var(--border-color);
}
.btn-secondary:hover {
    background: var(--bg-secondary);
    border-color: var(--text-muted);
}

.btn-outline {
    background: transparent;
    color: var(--blue-light);
    border: 1px solid var(--blue-light);
}
.btn-outline:hover {
    background: var(--blue-light);
    color: #FFF;
}

.btn-light {
    background: #FFFFFF;
    color: var(--blue-dark);
}
.btn-light:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}
.btn-sm { padding: 0.5rem 1rem; font-size: 0.875rem; }
.btn-large { padding: 1rem 2.5rem; font-size: 1.125rem; }

/* ==========================================================================
   Header
   ========================================================================== */
.header {
    position: fixed;
    top: 0;
    width: 100%;
    background: var(--bg-primary);
    backdrop-filter: blur(12px);
    z-index: 1000;
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 0;
}
.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.logo {
    font-size: 1.5rem;
    letter-spacing: -1px;
}
.logo img {
    height: 40px;
}
.logo span { color: var(--blue-light); }

.nav-links {
    display: flex;
    gap: 2rem;
}
.nav-links a {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-muted);
    transition: var(--transition);
}
.nav-links a:hover {
    color: var(--blue-light);
}
.nav-actions { display: flex; 
    align-items: center; 
    gap: 1rem; 
}
.icon-btn {
    background: none; 
    border: none; 
    font-size: 1.25rem; 
    cursor: pointer; 
    color: var(--text-main);
}

/* ==========================================================================
   Sections
   ========================================================================== */
section { padding: 6rem 0; }

/* Hero */
.hero {
    padding-top: 10rem;
    padding-bottom: 8rem;
    overflow: hidden;
}
.hero-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}
.hero-content p {
    color: var(--text-muted);
    font-size: 1.125rem;
    margin: 1.5rem 0 2.5rem;
}
.hero-buttons { display: flex; gap: 1rem; }
.hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
}
.hero-image img {
    width: 100%;
    max-width: 560px;
    height: auto;
    max-height: 460px;
    object-fit: contain;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 1rem;
    background: linear-gradient(135deg, rgba(15, 123, 255, 0.08), rgba(10, 45, 143, 0.04));
    transform: perspective(1000px) rotateY(-5deg) translateY(0);
    transition: var(--transition);
}
.hero-image img:hover { transform: perspective(1000px) rotateY(0) translateY(-10px); }

/* Services */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}
.service-card {
    background: var(--bg-primary);
    padding: 2rem;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    transition: var(--transition);
}
.service-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--blue-light);
}
.service-card .icon {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 88px;
    margin-bottom: 1.5rem;
}
.service-card .icon img {
    width: 72px;
    height: 72px;
    object-fit: contain;
    display: block;
}
.service-card p { color: var(--text-muted); }

/* Differentials */
.diff-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}
.diff-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-weight: 500;
    padding: 1rem;
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
}
.diff-item span { color: var(--blue-light); font-weight: bold; }

/* Timeline */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}
.timeline::before {
    content: '';
    position: absolute;
    top: 0; left: 24px; height: 100%;
    width: 2px;
    background: var(--border-color);
}
.timeline-item {
    display: flex;
    gap: 2rem;
    margin-bottom: 3rem;
    position: relative;
}
.timeline-dot {
    width: 50px; height: 50px;
    background: var(--gradient-primary);
    color: white;
    border-radius: 50%;
    display: flex; justify-content: center; align-items: center;
    font-weight: bold; z-index: 1; flex-shrink: 0;
}
.timeline-content {
    background: var(--bg-primary);
    padding: 1.5rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    width: 100%;
}
.timeline-content p { color: var(--text-muted); }

/* Projects */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}
.project-card {
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: var(--transition);
}
.project-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.project-img {
    background: linear-gradient(135deg, rgba(15, 123, 255, 0.06), rgba(10, 45, 143, 0.04));
}
.project-img img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    object-position: center;
    display: block;
}
.project-info { padding: 2rem; }
.badge {
    background: rgba(15, 123, 255, 0.1);
    color: var(--blue-light);
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 600;
    display: inline-block;
    margin-bottom: 1rem;
}
.project-info p { margin-bottom: 1.5rem; color: var(--text-muted); }

/* Stats */
.stats { padding: 4rem 0; }
.stats-grid {
    display: grid; grid-template-columns: repeat(4, 1fr); gap: 2rem; text-align: center;
}
.stats-grid h3 { font-size: 3rem; font-weight: 800; margin-bottom: 0.5rem; color: #FFF; }
.stats-grid span { font-size: 1rem; font-weight: 500; opacity: 0.9; }

/* Testimonials */
.carousel {
    display: flex;
    gap: 2rem;
    overflow-x: auto;
    padding: 1rem 0 2rem 0;
    scrollbar-width: none; /* Firefox */
}
.carousel::-webkit-scrollbar { display: none; } /* Chrome */
.testimo-card {
    min-width: 300px;
    background: var(--bg-secondary);
    padding: 2rem;
    border-radius: var(--radius-lg);
    flex: 1;
}
.stars { color: #F59E0B; margin-bottom: 1rem; font-size: 1.25rem; }
.testimo-card p { font-style: italic; margin-bottom: 1rem; color: var(--text-muted); }

/* FAQ */
.faq-list { max-width: 800px; margin: 0 auto; }
.faq-item {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    margin-bottom: 1rem;
    overflow: hidden;
}
.faq-item summary {
    padding: 1.5rem;
    font-weight: 600;
    cursor: pointer;
    list-style: none; /* Remove seta padrão */
    display: flex; justify-content: space-between;
}
.faq-item summary::after { content: '+'; color: var(--blue-light); font-size: 1.5rem; font-weight: 400;}
.faq-item[open] summary::after { content: '−'; }
.faq-item p { padding: 0 1.5rem 1.5rem; color: var(--text-muted); }

/* Contato Form */
.contact-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    background: var(--bg-secondary);
    padding: 4rem;
    border-radius: var(--radius-lg);
}
.contact-links { margin-top: 2rem; display: flex; flex-direction: column; gap: 1rem; }
.contact-links li {
    margin-bottom: 0;
    color: var(--text-muted);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}
.contact-links li img {
    width: 24px;
    height: 24px;
    object-fit: contain;
    flex-shrink: 0;
}
.form { display: flex; flex-direction: column; gap: 1.5rem; }
.form-group { display: flex; flex-direction: column; gap: 0.5rem; }
.form-group label { font-size: 0.875rem; font-weight: 600; }
.form-group input {
    padding: 1rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: var(--bg-primary);
    color: var(--text-main);
    font-family: inherit;
    outline: none;
    transition: var(--transition);
}
.form-group input:focus { border-color: var(--blue-light); box-shadow: 0 0 0 3px rgba(15, 123, 255, 0.2); }

/* ==========================================================================
   Estilo do Pop-up de Sucesso
   ========================================================================== */
.custom-modal {
    display: none; /* Oculto por padrão */
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    z-index: 9999;
    justify-content: center;
    align-items: center;
}

/* Classe adicionada via JavaScript para exibir o modal */
.custom-modal.show {
    display: flex;
    animation: fadeIn 0.3s ease-out;
}

.custom-modal .modal-content {
    background: var(--bg-primary, #ffffff);
    padding: 2.5rem;
    border-radius: var(--radius-lg, 16px);
    text-align: center;
    max-width: 400px;
    width: 90%;
    box-shadow: var(--shadow-lg, 0 10px 25px rgba(0,0,0,0.2));
    border: 1px solid var(--border-color, #eee);
}

.modal-icon {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    animation: bounceIn 0.6s ease-out;
}

.custom-modal h3 {
    margin-bottom: 0.5rem;
    font-size: 1.5rem;
}

.custom-modal p {
    color: var(--text-muted, #555);
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes bounceIn {
    0% { transform: scale(0); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

/* Footer */
.footer { padding: 4rem 0 2rem; border-top: 1px solid var(--border-color); }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 2rem; margin-bottom: 3rem;}
.footer-brand p { color: var(--text-muted); margin-top: 1rem; }
.footer h4 { margin-bottom: 1.5rem; font-size: 1.125rem; }
.footer ul li { margin-bottom: 0.75rem; }
.footer ul a { color: var(--text-muted); transition: var(--transition); }
.footer ul a:hover { color: var(--blue-light); }
.footer-contact p { color: var(--text-muted); margin-bottom: 0.5rem; }
.socials { display: flex; gap: 1rem; margin-top: 1rem; }
.socials a {
    width: 44px; height: 44px;
    display: flex; justify-content: center; align-items: center;
    background: linear-gradient(135deg, rgba(15, 123, 255, 0.12), rgba(10, 45, 143, 0.08));
    border: 1px solid rgba(15, 123, 255, 0.18);
    border-radius: 50%;
    color: var(--blue-light);
    font-weight: bold;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}
.socials a img {
    width: 22px;
    height: 22px;
    object-fit: contain;
    display: block;
}
.socials a:hover {
    background: var(--gradient-primary);
    color: #FFF;
    transform: translateY(-3px) scale(1.05);
    box-shadow: var(--shadow-lg);
}
.footer-bottom { padding-top: 2rem; border-top: 1px solid var(--border-color); color: var(--text-muted); font-size: 0.875rem; }

/* Floating WhatsApp */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: #25d366;
    color: #FFF;
    border-radius: 50%;
    width: 60px; height: 60px;
    display: flex; justify-content: center; align-items: center;
    box-shadow: var(--shadow-lg);
    z-index: 9999;
    transition: var(--transition);
    animation: pulse 2s infinite;
}
.whatsapp-float:hover { transform: scale(1.1); background-color: #1ebe57; }

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.5); }
    70% { box-shadow: 0 0 0 15px rgba(37, 211, 102, 0); }
    100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

/* Animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}
.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* Responsividade */
@media (max-width: 992px) {
    .hero-container, .contact-container { grid-template-columns: 1fr; gap: 3rem;}
    .hero-content { text-align: center; }
    .hero-buttons { justify-content: center; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .nav-links { display: none; } /* Em um cenário real, adicionar menu hamburger aqui */
}
@media (max-width: 768px) {
    .stats-grid { grid-template-columns: 1fr 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
    .hero-buttons { flex-direction: column; }
    .contact-container { padding: 2rem; }
}
@media (max-width: 510px) {
    .logo img {
        width: 80%;
        height: auto;
    }
}