/* CSS Variables - Sottelli Inspired Light Theme */
:root {
    --bg-main: #ffffff;
    --bg-alt: #f4f6f9;

    /* Vibrant Accents */
    --accent-cyan: #2B548E;
    --accent-magenta: #F28522;

    /* Glassmorphism */
    --glass-bg: rgba(255, 255, 255, 0.8);
    --glass-border: rgba(0, 0, 0, 0.05);

    /* Text */
    --text-main: #111420;
    --text-muted: #4a5568;

    /* Theme specific gradients/elements */
    --hero-overlay: linear-gradient(90deg, rgba(255, 255, 255, 1) 0%, rgba(255, 255, 255, 0.7) 50%, transparent 100%);
    --hero-subtitle-color: #000000;
    --hero-subtitle-shadow: 0 0 15px rgba(255, 255, 255, 1), 0 0 30px rgba(255, 255, 255, 0.9);
    
    --btn-glass-text: var(--accent-cyan);
    --btn-glass-hover-text: #ffffff;

    /* Typography */
    --font-heading: 'Space Grotesk', sans-serif;
    --font-body: 'Outfit', sans-serif;
}

[data-theme="dark"] {
    --bg-main: #0b0f19;
    --bg-alt: #05050A;

    /* Glassmorphism */
    --glass-bg: rgba(20, 25, 40, 0.7);
    --glass-border: rgba(255, 255, 255, 0.05);

    /* Text */
    --text-main: #f8f9fa;
    --text-muted: #9aa4b5;

    /* Theme specific gradients/elements */
    --hero-overlay: linear-gradient(90deg, rgba(11, 15, 25, 0.98) 0%, rgba(11, 15, 25, 0.75) 55%, transparent 100%);
    --hero-subtitle-color: var(--text-main);
    --hero-subtitle-shadow: 0 4px 15px rgba(0, 0, 0, 0.9);
    
    --btn-glass-text: var(--text-main);
    --btn-glass-hover-text: #000000;
}

/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    /* Compensa a altura da navbar fixa para links âncora */
    scroll-padding-top: 100px;
}

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    transition: background-color 0.4s ease, color 0.4s ease;
}

/* Typography Tools */
h1,
h2,
h3,
h4,
.logo {
    font-family: var(--font-heading);
    font-weight: 700;
}

/* Used for the logo span */
.neon-text-cyan {
    color: var(--accent-cyan);
}

.neon-text-magenta {
    color: var(--accent-magenta);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Glassmorphism / Card Classes */
.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.08);
    /* Soft deep shadow */
    border-radius: 16px;
    position: relative;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.glass-panel:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.12);
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    padding: 1.5rem 0;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    background: rgba(17, 20, 32, 0.9); /* Fundo escuro padrão para contrastar com o logo */
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .navbar {
    background: rgba(5, 5, 10, 0.95);
}

/* Logo original sem alterações */
.logo-img {
    filter: none !important;
}

.navbar.scrolled {
    padding: 0.8rem 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.nav-container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.5rem;
}

/* Grupo direito: toggle de tema + hamburguer (sempre visíveis) */
.nav-controls {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    flex-shrink: 0;
}

.logo {
    font-size: 1.5rem;
    text-decoration: none;
    color: var(--text-main);
    letter-spacing: -0.5px;
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.logo-img {
    height: 50px;
    width: auto;
    object-fit: contain;
}

.nav-links {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 1.2rem;
}

.nav-links a {
    text-decoration: none;
    color: #ffffff;
    font-weight: 600;
    transition: color 0.3s ease;
    white-space: nowrap;
}

.theme-toggle {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #ffffff;
    cursor: pointer;
    font-size: 1.2rem;
    padding: 0.6rem;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.3s ease;
}

.theme-toggle svg {
    stroke: #ffffff; /* Garante que os ícones SVG sejam brancos */
}

[data-theme="dark"] .theme-toggle {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
}

.theme-toggle:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

.nav-links a:hover {
    color: var(--accent-magenta);
}

/* Buttons */
.btn-primary {
    background: linear-gradient(135deg, var(--accent-cyan), var(--accent-magenta));
    color: #fff !important;
    padding: 0.7rem 1.5rem;
    border-radius: 8px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: none;
    cursor: pointer;
    box-shadow: 0 8px 20px rgba(247, 37, 133, 0.2);
    transition: all 0.3s ease;
    white-space: nowrap;
}

.btn-primary:hover {
    transform: scale(1.05);
    box-shadow: 0 12px 25px rgba(247, 37, 133, 0.3);
}

.btn-glass {
    display: inline-block;
    background: var(--bg-main);
    border: 1px solid var(--accent-cyan);
    color: var(--btn-glass-text);
    padding: 1rem 2rem;
    border-radius: 8px;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn-glass:hover {
    background: var(--accent-cyan);
    color: var(--btn-glass-hover-text);
    box-shadow: 0 8px 20px rgba(43, 84, 142, 0.3);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding-top: 80px;
    overflow: hidden;
    background-image: url('../assets/images/bg-hero.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
}

.hero-bg-overlay {
    position: absolute;
    inset: 0;
    /* Clean white gradient on the left side */
    background: var(--hero-overlay);
    z-index: 1;
    transition: background 0.4s ease;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
}

.hero-title {
    font-size: clamp(3rem, 5vw, 5rem);
    line-height: 1.1;
    margin-bottom: 1.2rem;
    color: var(--text-main);
    letter-spacing: -1px;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--hero-subtitle-color);
    margin-bottom: 2.5rem;
    max-width: 600px;
    font-weight: 500;
    text-shadow: var(--hero-subtitle-shadow);
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
}

.mouse {
    width: 30px;
    height: 50px;
    border: 2px solid var(--text-muted);
    border-radius: 15px;
    display: flex;
    justify-content: center;
    padding-top: 10px;
}

.wheel {
    width: 4px;
    height: 8px;
    background: var(--accent-cyan);
    border-radius: 2px;
    animation: scroll 1.5s infinite;
}

@keyframes scroll {
    0% {
        transform: translateY(0);
        opacity: 1;
    }

    100% {
        transform: translateY(15px);
        opacity: 0;
    }
}

/* Sections */
section {
    padding: 6rem 0;
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--text-main);
    letter-spacing: -0.5px;
}

.center {
    text-align: center;
    margin-bottom: 4rem;
}

/* Section Backgrounds */
.section-light {
    background-color: var(--bg-main);
    transition: background-color 0.4s ease;
}

.section-alt {
    background-color: var(--bg-alt);
    transition: background-color 0.4s ease;
}

/* About Section */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-text {
    padding: 3rem;
    background: var(--glass-bg);
    transition: background 0.4s ease;
}

.about-text p {
    margin-bottom: 1.5rem;
    color: var(--text-muted);
    font-size: 1.1rem;
}

.about-visual {
    display: flex;
    justify-content: center;
    align-items: center;
}

.cyber-circle {
    width: 300px;
    height: 300px;
    border: 2px dashed var(--accent-cyan);
    border-radius: 50%;
    position: relative;
    animation: spin 20s linear infinite;
    display: flex;
    justify-content: center;
    align-items: center;
}

.circle-inner {
    width: 200px;
    height: 200px;
    border: 2px solid var(--accent-magenta);
    border-radius: 50%;
    animation: spin 15s linear infinite reverse;
}

.circle-glow {
    position: absolute;
    width: 100px;
    height: 100px;
    background: radial-gradient(circle, rgba(0, 180, 216, 0.1) 0%, transparent 70%);
    border-radius: 50%;
}

@keyframes spin {
    100% {
        transform: rotate(360deg);
    }
}

/* Services */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.service-card {
    padding: 2.5rem 2rem;
    text-align: left;
    background: var(--glass-bg);
    transition: background 0.4s ease;
}

.service-icon {
    font-size: 3rem;
    margin-bottom: 1.5rem;
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-main);
}

.service-card p {
    color: var(--text-muted);
}

/* Differentials */
.differentials-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.diff-stats {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

.stat-item {
    padding: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    border-left: 4px solid var(--accent-cyan);
    background: var(--glass-bg);
    transition: background 0.4s ease;
}

.stat-item:nth-child(2) {
    border-left-color: var(--accent-magenta);
}

.stat-number {
    font-size: 3.5rem;
    line-height: 1;
    margin-bottom: 0.5rem;
    color: var(--text-main);
    letter-spacing: -2px;
}

.stat-item:nth-child(1) .stat-number {
    color: var(--accent-cyan);
}

.stat-item:nth-child(2) .stat-number {
    color: var(--accent-magenta);
}

.stat-item:nth-child(3) .stat-number {
    color: var(--accent-cyan);
}

.stat-item p {
    color: var(--text-muted);
    font-weight: 600;
}

.diff-list {
    list-style: none;
    margin-top: 2rem;
}

.diff-list li {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    padding-left: 2rem;
    position: relative;
    color: var(--text-muted);
}

.diff-list li::before {
    content: '▶';
    position: absolute;
    left: 0;
    color: var(--accent-cyan);
    font-size: 0.8rem;
    top: 5px;
}

/* Footer */
.footer {
    border-top: 1px solid var(--glass-border);
    border-radius: 0;
    padding-top: 4rem;
    background: var(--bg-alt);
    box-shadow: none;
}

.footer .logo-img {
    height: 120px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    padding-bottom: 3rem;
}

.footer-brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.footer-brand p {
    margin-top: 1rem;
    color: var(--text-muted);
}

.contact-form {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.glass-input {
    flex: 1;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    padding: 0.8rem 1rem;
    border-radius: 8px;
    color: var(--text-main);
    outline: none;
    transition: border-color 0.3s ease;
}

.glass-input:focus {
    border-color: var(--accent-cyan);
}

.footer-bottom {
    text-align: center;
    padding: 1.5rem;
    border-top: 1px solid var(--glass-border);
    color: var(--text-muted);
}

/* ========================================
   MOBILE MENU — Hamburguer Button
   ======================================== */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 44px;
    height: 44px;
    cursor: pointer;
    background: transparent;
    border: none;
    padding: 0.25rem;
    z-index: 1100;
    border-radius: 8px;
    transition: background 0.2s ease;
}

.mobile-menu-btn:hover {
    background: rgba(255, 255, 255, 0.08);
}

.mobile-menu-btn span {
    display: block;
    width: 26px;
    height: 2px;
    background: #ffffff; /* Sempre branco para contrastar com a navbar escura */
    border-radius: 2px;
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1),
                opacity   0.25s ease,
                width     0.25s ease;
    transform-origin: center;
}

/* Hamburguer → X animation */
.mobile-menu-btn.open span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}
.mobile-menu-btn.open span:nth-child(2) {
    opacity: 0;
    width: 0;
}
.mobile-menu-btn.open span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

@media (min-width: 993px) {
    .nav-links {
        transform: none !important;
    }
}

/* ========================================
   MOBILE MENU — Overlay
   ======================================== */
.mobile-overlay {
    display: none;
    position: fixed;
    inset: 0;
    /* Sem backdrop-filter: evita blur acumulado com o drawer */
    background: rgba(0, 0, 0, 0.6);
    z-index: 1050;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.mobile-overlay.visible {
    opacity: 1;
}

/* ========================================
   MOBILE MENU — Responsive Rules
   ======================================== */
@media (max-width: 992px) {
    .mobile-menu-btn { display: flex; }

    /* Drawer usando Grid para forçar o empilhamento vertical absoluto */
    #navLinks {
        display: grid !important;
        grid-template-columns: 1fr !important;
        grid-auto-rows: min-content !important;
        position: fixed !important;
        top: 0 !important;
        right: 0 !important;
        bottom: 0 !important;
        width: 280px !important;
        height: 100dvh !important;
        background: #0b0f19 !important;
        border-left: 1px solid rgba(255, 255, 255, 0.1);
        padding: 80px 0 40px !important;
        z-index: 10000 !important;
        transform: translateX(100%);
        transition: transform 0.3s ease;
        overflow-y: auto !important;
        list-style: none !important;
    }

    #navLinks.open { transform: translateX(0) !important; }

    #navLinks li {
        display: block !important;
        width: 100% !important;
        height: auto !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    }

    #navLinks a {
        display: block !important;
        padding: 1.2rem 1.5rem !important;
        font-size: 1.1rem !important;
        color: #fff !important;
        text-align: left !important;
        text-decoration: none !important;
    }

    #navLinks a.btn-primary {
        background: linear-gradient(135deg, var(--accent-cyan), var(--accent-magenta));
        margin: 20px 15px !important;
        text-align: center !important;
        border-radius: 8px;
    }

    /* Ajustes gerais */
    .about-grid, .differentials-grid, .footer-grid { grid-template-columns: 1fr; }
    .hero-title { font-size: 2.2rem; }
}

@media (max-width: 480px) {
    .hero-title { font-size: 2rem; }
    .section-title { font-size: 1.8rem; }
    .stat-number { font-size: 2.5rem; }
    .about-text { padding: 1.5rem; }
    .container { padding: 0 1rem; }
}

@media (max-width: 992px) and (orientation: portrait) {
    .logo-img {
        height: 100px;
        width: 100px;
        object-fit: contain;
    }
    .navbar { padding: 0.5rem 0; }
}

@media (max-width: 992px) and (orientation: landscape) {
    #navLinks {
        display: block !important; /* Mais estável para scroll nativo */
        padding-top: 3rem !important;
        padding-bottom: 6rem !important;
        overflow-y: auto !important;
        -webkit-overflow-scrolling: touch !important;
        height: 100% !important;
        max-height: 100dvh !important;
    }
    #navLinks li {
        display: block !important;
        width: 100% !important;
        min-height: 45px !important;
    }
    #navLinks a { 
        padding: 0.8rem 2rem !important;
        font-size: 1rem !important;
    }
    .logo-img { height: 32px; }
    .navbar { overflow: visible !important; }
}

/* Garante que a scrollbar apareça no mobile se necessário */
#navLinks::-webkit-scrollbar {
    width: 4px;
}
#navLinks::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
}

/* Intersection Observer Animations */
[data-observe] {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

[data-observe].in-view {
    opacity: 1;
    transform: translateY(0);
}
