/* --- Variáveis Globais --- */
:root {
    /* Paleta High-Tech Dark */
    --bg-dark: #070B14;
    --bg-card: #0F1626;
    --bg-card-hover: #162036;
    --bg-nav: rgba(7, 11, 20, 0.85);
    --bg-footer: #04070d;
    
    --primary: #06b6d4;
    --primary-glow: rgba(6, 182, 212, 0.3);
    
    --secondary: #3b82f6;
    --accent: #22d3ee;

    --text-white: #ffffff;
    --text-light: #94a3b8;
    --border-color: #1e293b;

    --container-max: 1200px;
    --transition-speed: 0.3s;
}

[data-theme="light"] {
    --bg-dark: #f8f9fa;
    --bg-card: #ffffff;
    --bg-card-hover: #f1f5f9;
    --bg-nav: rgba(255, 255, 255, 0.85);
    --bg-footer: #e8eef4;
    
    --primary: #0284c7;
    --primary-glow: rgba(2, 132, 199, 0.2);
    
    --secondary: #2563eb;
    --accent: #0ea5e9;

    --text-white: #0f172a;
    --text-light: #475569;
    --border-color: #cbd5e1;
}

.btn-theme-toggle {
    background: transparent;
    border: none;
    color: var(--text-white);
    font-size: 1.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.4rem;
    border-radius: 50%;
    transition: background var(--transition-speed);
}
.btn-theme-toggle:hover {
    background: var(--bg-card);
}

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

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

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-light);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4 {
    color: var(--text-white);
    font-weight: 600;
    line-height: 1.2;
}

a { text-decoration: none; color: inherit; }
li { list-style: none; }
img { max-width: 100%; height: auto; display: block; }

/* Utilitários */
.container {
    width: 90%;
    max-width: var(--container-max);
    margin: 0 auto;
}
.section-padding { padding: 5rem 0; }
.text-primary { color: var(--primary); }

/* --- Animações --- */
@keyframes float {
    0% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-15px) rotate(2deg); }
    100% { transform: translateY(0px) rotate(0deg); }
}

@keyframes glowPulse {
    0% { box-shadow: 0 0 20px var(--primary-glow); }
    50% { box-shadow: 0 0 40px rgba(6, 182, 212, 0.6); }
    100% { box-shadow: 0 0 20px var(--primary-glow); }
}

/* Classes Intersection Observer */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}
.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}
.delay-1 { transition-delay: 0.2s; }
.delay-2 { transition-delay: 0.4s; }

/* --- Botões --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all var(--transition-speed);
    border: none;
    outline: none;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: var(--text-white);
    box-shadow: 0 4px 15px var(--primary-glow);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(6, 182, 212, 0.5);
    filter: brightness(1.1);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-white);
}
.btn-outline:hover {
    border-color: var(--primary);
    background: rgba(6, 182, 212, 0.1);
}

.btn-ghost {
    background: transparent;
    color: var(--text-light);
}
.btn-ghost:hover {
    color: var(--text-white);
    transform: translateX(4px);
}

/* --- Navbar --- */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: var(--bg-nav);
    backdrop-filter: blur(10px);
    z-index: 1000;
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 0;
    transition: padding 0.3s ease;
}

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

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-white);
    letter-spacing: -0.5px;
}

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

.nav-links a:not(.btn) {
    font-size: 0.95rem;
    font-weight: 400;
    transition: color var(--transition-speed);
    position: relative;
}
.nav-links a:not(.btn):hover {
    color: var(--primary);
}
.nav-links a:not(.btn)::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0%;
    height: 2px;
    background-color: var(--primary);
    transition: width 0.3s ease;
}
.nav-links a:not(.btn):hover::after { width: 100%; }

.mobile-menu-btn {
    display: none;
    background: transparent;
    border: none;
    color: var(--text-white);
    font-size: 1.8rem;
    cursor: pointer;
}

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

/* Canvas Styling */
#heroCanvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}
.hero-container {
    z-index: 1;
    position: relative;
}

/* Glow Background Effect */
.hero::before {
    content: '';
    position: absolute;
    top: -10%;
    left: -10%;
    width: 50vw;
    height: 50vw;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.15) 0%, rgba(0,0,0,0) 70%);
    border-radius: 50%;
    z-index: -1;
}

.hero-container {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 4rem;
    align-items: center;
}

.badge {
    display: inline-block;
    padding: 0.4rem 1rem;
    background: rgba(34, 211, 238, 0.1);
    color: var(--accent);
    border: 1px solid rgba(34, 211, 238, 0.2);
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.hero h1 {
    font-size: 4rem;
    margin-bottom: 1.5rem;
}
.hero h1 span {
    background: linear-gradient(to right, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.hero p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    max-width: 90%;
}
.hero-buttons {
    display: flex;
    gap: 1rem;
}

/* Visual Placeholder no Hero */
.hero-visual {
    position: relative;
    height: 400px;
    display: flex;
    justify-content: center;
    align-items: center;
}
.visual-sphere {
    width: 250px;
    height: 250px;
    border-radius: 50%;
    background: conic-gradient(from 180deg at 50% 50%, var(--primary), var(--secondary), transparent, var(--bg-dark));
    animation: float 6s ease-in-out infinite, glowPulse 4s infinite alternate;
    filter: blur(2px);
    position: absolute;
}
.visual-card {
    background: var(--bg-card);
    opacity: 0.85;
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 1rem 1.5rem;
    border-radius: 12px;
    color: var(--text-white);
    display: flex;
    align-items: center;
    gap: 0.8rem;
    position: absolute;
    font-weight: 600;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    z-index: 2;
}
.visual-card i {
    font-size: 1.5rem;
    color: var(--primary);
}
.visual-card.floating {
    top: 20%;
    left: 10%;
    animation: float 5s ease-in-out infinite;
}
.visual-card.floating.delay {
    top: 60%;
    right: 5%;
    animation-delay: -2s;
}

/* --- Títulos GERAIS --- */
.section-header {
    text-align: center;
    margin-bottom: 4rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}
.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

/* --- Serviços --- */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.service-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    padding: 3rem 2rem;
    border-radius: 16px;
    transition: all var(--transition-speed);
}
.service-card:hover {
    background: var(--bg-card-hover);
    transform: translateY(-10px);
    border-color: var(--primary);
}

.icon-box {
    width: 60px;
    height: 60px;
    background: rgba(6, 182, 212, 0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}
.service-card p {
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
}
.service-list {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}
.service-list li {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-white);
}
.service-list i { color: var(--primary); }

/* --- Portfólio --- */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}
.portfolio-item {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    height: 300px;
    cursor: pointer;
}
.portfolio-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}
.portfolio-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 2rem;
    opacity: 0;
    transition: opacity 0.3s ease;
}
.portfolio-item:hover img {
    transform: scale(1.05);
}
.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
}
.portfolio-overlay span {
    color: var(--primary);
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

/* --- Sobre --- */
.about {
    background-color: var(--bg-card);
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}
.about-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}
.about-text h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
}
.about-text p {
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}
.about-stats {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}
.stat-box {
    background: var(--bg-dark);
    padding: 2rem;
    border-radius: 12px;
    border-left: 4px solid var(--secondary);
}
.stat-box.accent {
    border-left-color: var(--primary);
}
.stat-box h3 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}
.stat-box p { margin: 0; font-size: 0.9rem; }

/* --- Contato --- */
.contact-container {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 4rem;
}
.contact-info h2 {
    font-size: 3rem;
    margin-bottom: 1rem;
    line-height: 1.1;
}
.contact-info p {
    margin-bottom: 3rem;
}
.contact-details {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}
.detail-item {
    display: flex;
    align-items: center;
    gap: 1rem;
}
.detail-item .icon {
    width: 50px;
    height: 50px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: var(--primary);
}
.detail-item span { display: block; font-size: 0.85rem; color: var(--text-light); }
.detail-item strong { color: var(--text-white); font-size: 1.1rem; }

/* Formulário */
.contact-form {
    background: var(--bg-card);
    padding: 3rem;
    border-radius: 20px;
    border: 1px solid var(--border-color);
}
.form-group {
    margin-bottom: 1.5rem;
}
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}
label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-white);
    font-size: 0.9rem;
    font-weight: 600;
}
input, select, textarea {
    width: 100%;
    padding: 1rem;
    background: var(--bg-dark);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-white);
    font-family: inherit;
    font-size: 1rem;
    transition: border-color var(--transition-speed);
}
input::placeholder, textarea::placeholder {
    color: var(--text-light);
    opacity: 0.6;
}
input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.1);
}
.submit-btn { width: 100%; margin-top: 1rem; }

/* --- Footer --- */
.footer {
    background: var(--bg-footer);
    padding: 4rem 0 2rem;
    border-top: 1px solid var(--border-color);
}
.footer-content {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}
.footer-brand p {
    margin-top: 1rem;
    max-width: 300px;
    font-size: 0.9rem;
}
.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
    font-size: 0.85rem;
}
.social-links {
    display: flex;
    gap: 1rem;
}
.social-links a {
    width: 40px;
    height: 40px;
    background: var(--bg-card);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 1.2rem;
    transition: all var(--transition-speed);
}
.social-links a:hover {
    background: var(--primary);
    color: var(--text-white);
    transform: translateY(-3px);
}

/* --- Reponsividade (Media Queries) --- */

@media (max-width: 992px) {
    .hero-container, .about-container, .contact-container {
        grid-template-columns: 1fr;
    }
    .hero { text-align: center; }
    .hero h1 { font-size: 3rem; }
    .hero p { margin: 0 auto 2rem; }
    .hero-buttons { justify-content: center; }
    .hero-visual { display: none; }
}

@media (max-width: 768px) {
    .nav-links {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: var(--bg-card);
        padding: 2rem;
        border-bottom: 1px solid var(--border-color);
        clip-path: polygon(0 0, 100% 0, 100% 0, 0 0);
        transition: clip-path 0.4s ease-in-out;
    }
    .nav-links.active {
        clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
    }
    .mobile-menu-btn { display: block; }
    
    .form-row { grid-template-columns: 1fr; }
    .contact-form { padding: 1.5rem; }
    
    .footer-bottom {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
}
