/* =========================================
   1. RESET E GLOBAIS
   ========================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

html {
    scroll-behavior: smooth;
}

/* --- SISTEMA DE CORES (Variáveis CSS) --- */
:root {
    /* Cor de destaque (Roxo Neon) - Fixa nos dois temas */
    --primary-purple: #9D00FF; 
    --primary-purple-dark: #6b00b0;
    
    /* TEMA PADRÃO (ESCURO) */
    --bg-main: #0a0a0a;           /* Fundo da página */
    --bg-secondary: #121212;      /* Fundo de cards/elementos */
    --text-main: #FFFFFF;         /* Texto principal */
    --text-secondary: #a1a1a1;    /* Texto secundário */
    --border-color: #333333;      /* Bordas sutis */
    --shadow-color: rgba(0,0,0,0.5); 
    --blob-opacity: 0.8;
}

/* TEMA CLARO (Ativado via JS: body.light-mode) */
body.light-mode {
    --bg-main: #f4f4f9;           
    --bg-secondary: #ffffff;      
    --text-main: #1a1a1a;         
    --text-secondary: #555555;    
    --border-color: #e0e0e0;      
    --shadow-color: rgba(157, 0, 255, 0.15); 
    --blob-opacity: 0.9;
}

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    overflow-x: hidden;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* =========================================
   2. HEADER / NAVEGAÇÃO
   ========================================= */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 8%;
    background-color: transparent; 
    position: relative;
    z-index: 100;
}

/* Logo */
.logo {
    font-weight: 700;
    font-size: 1.8rem;
    color: var(--text-main);
    letter-spacing: -1px;
    transition: color 0.3s ease;
}
.logo span {
    color: var(--primary-purple);
    font-size: 2rem;
}

/* Menu */
nav ul {
    display: flex;
    list-style: none;
    gap: 30px;
}

nav ul li a {
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 500;
    transition: color 0.3s;
}

nav ul li a:hover {
    color: var(--primary-purple);
}

/* Estado Ativo (Página Atual) */
nav ul li a.active {
    color: var(--primary-purple);
    font-weight: 700;
}

/* Ações do Header */
.header-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Botão Tema (Sol/Lua) */
#theme-toggle {
    background: var(--bg-secondary);
    border: 2px solid var(--border-color);
    color: var(--text-main);
    width: 45px;
    height: 45px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}
#theme-toggle:hover {
    border-color: var(--primary-purple);
    color: var(--primary-purple);
    transform: rotate(15deg);
}

/* =========================================
   3. BOTÕES (UI KIT)
   ========================================= */
.btn-primary {
    background-color: var(--primary-purple);
    color: white;
    padding: 12px 28px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(157, 0, 255, 0.4);
    transition: all 0.3s ease;
    border: 2px solid var(--primary-purple);
    display: inline-block;
    text-align: center;
}
.btn-primary:hover {
    transform: translateY(-3px);
    background-color: var(--primary-purple-dark);
    box-shadow: 0 8px 25px rgba(157, 0, 255, 0.6);
}

.btn-outline {
    border: 2px solid var(--text-main);
    color: var(--text-main);
    padding: 15px 45px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s;
    display: inline-block;
    text-align: center;
}
.btn-outline:hover {
    background-color: var(--text-main);
    color: var(--bg-main);
}

/* =========================================
   4. HOME PAGE (Hero)
   ========================================= */
.hero {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 60px 8% 20px 8%;
    min-height: 88vh;
    position: relative;
}

.hero-text {
    flex: 1.2;
    max-width: 650px;
    z-index: 2;
}

/* Badge decorativo */
.badge-box {
    display: inline-block;
    padding: 8px;
    margin-bottom: 25px;
    position: relative;
}
.badge-box::before, .badge-box::after {
    content: '';
    position: absolute;
    width: 15px; height: 15px;
    border-color: var(--primary-purple);
    border-style: solid;
}
.badge-box::before { top: 0; left: 0; border-width: 3px 0 0 3px; }
.badge-box::after { bottom: 0; right: 0; border-width: 0 3px 3px 0; }

.hello-badge {
    font-weight: 600;
    color: var(--primary-purple);
    padding: 5px 15px;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.hero-text h1 {
    font-size: 4rem;
    line-height: 1.1;
    margin-bottom: 25px;
    color: var(--text-main);
    transition: color 0.3s ease;
}

.highlight {
    color: var(--primary-purple);
    position: relative;
    display: inline-block;
}

/* Sublinhado estilizado no nome */
.highlight::after {
    content: '';
    position: absolute;
    bottom: 5px; left: 0;
    width: 100%; height: 12px;
    background-color: var(--primary-purple);
    opacity: 0.3;
    z-index: -1;
}

.hero-text p {
    color: var(--text-secondary);
    margin-bottom: 40px;
    font-size: 1.2rem;
    line-height: 1.7;
    max-width: 90%;
    transition: color 0.3s ease;
}

.cta-buttons {
    display: flex;
    gap: 20px;
}

.btn-primary.big { padding: 15px 45px; font-size: 1.1rem; }

/* Arte Abstrata (Direita) */
.hero-visual-container {
    flex: 1;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    position: relative;
    height: 500px;
}

.abstract-composition {
    position: relative;
    width: 500px;
    height: 500px;
}

.purple-blob-main {
    position: absolute;
    width: 480px;
    height: 450px;
    background: linear-gradient(135deg, var(--primary-purple) 0%, var(--primary-purple-dark) 100%);
    border-radius: 63% 37% 54% 46% / 55% 48% 52% 45%;
    z-index: 1;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    opacity: var(--blob-opacity);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 20px 50px rgba(157, 0, 255, 0.3);
    animation: blobMorph 6s ease-in-out infinite alternate;
}

@keyframes blobMorph {
    from { border-radius: 63% 37% 54% 46% / 55% 48% 52% 45%; }
    to { border-radius: 40% 60% 60% 40% / 45% 55% 45% 55%; }
}

.play-icon-abstract {
    width: 0; height: 0; 
    border-top: 60px solid transparent;
    border-bottom: 60px solid transparent;
    border-left: 100px solid rgba(255, 255, 255, 0.8);
    margin-left: 20px;
    filter: drop-shadow(0 0 15px rgba(255,255,255,0.5));
}

.wave-decoration {
    position: absolute;
    border: 3px solid var(--primary-purple);
    border-radius: 50%;
    opacity: 0.2;
    z-index: 0;
}
.wave-1 { width: 550px; height: 550px; top: -20px; right: -30px; border-color: var(--text-main); }
.wave-2 { width: 300px; height: 300px; bottom: 50px; left: 50px; opacity: 0.1; }

.floating-tag {
    position: absolute;
    background: var(--bg-secondary);
    border: 2px solid var(--primary-purple);
    padding: 14px 28px;
    border-radius: 40px;
    box-shadow: 0 10px 30px var(--shadow-color);
    font-weight: 700;
    color: var(--text-main);
    z-index: 3;
    font-size: 0.95rem;
}
.tag-top-left { top: 10%; left: 0; background-color: var(--primary-purple); color: white; border: none; transform: rotate(-5deg); }
.tag-bottom-right { bottom: 15%; right: 0; transform: rotate(5deg); }

/* =========================================
   5. SERVIÇOS PAGE
   ========================================= */
.services-section {
    padding: 120px 8% 80px 8%;
    min-height: 100vh;
}

.section-header {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 60px auto;
}

.section-header h1 {
    font-size: 3rem;
    margin: 15px 0;
    color: var(--text-main);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 60px;
}

.service-card {
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 40px 30px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.service-card:hover {
    transform: translateY(-10px);
    border-color: var(--primary-purple);
    box-shadow: 0 15px 40px rgba(157, 0, 255, 0.15);
}

.service-card.highlight-card { border-top: 4px solid var(--primary-purple); }

.icon-box {
    width: 60px; height: 60px;
    background: rgba(157, 0, 255, 0.1);
    border-radius: 15px;
    display: flex; align-items: center; justify-content: center;
    margin-bottom: 25px;
    color: var(--primary-purple);
}
.icon-box svg { width: 30px; height: 30px; }

.service-card h3 { font-size: 1.5rem; color: var(--text-main); margin-bottom: 15px; }
.service-card p { color: var(--text-secondary); font-size: 0.95rem; line-height: 1.6; margin-bottom: 25px; }

.service-features {
    list-style: none;
    border-top: 1px solid var(--border-color);
    padding-top: 20px;
}
.service-features li {
    color: var(--text-main);
    font-size: 0.9rem;
    margin-bottom: 10px;
    display: flex; align-items: center; gap: 10px;
}
.service-features li::before { content: '✓'; color: var(--primary-purple); font-weight: bold; }

.cta-center { text-align: center; }

/* =========================================
   6. PORTFÓLIO PAGE
   ========================================= */
.portfolio-section {
    padding: 120px 8% 80px 8%;
    min-height: 100vh;
}

/* Filtros */
.portfolio-filters {
    display: flex; justify-content: center;
    gap: 15px; margin-bottom: 50px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 10px 25px;
    border: 2px solid var(--border-color);
    background: transparent;
    color: var(--text-secondary);
    border-radius: 30px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    font-size: 0.95rem;
}

.filter-btn:hover, .filter-btn.active {
    background-color: var(--primary-purple);
    border-color: var(--primary-purple);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(157, 0, 255, 0.3);
}

/* Grade de Projetos */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

.project-item {
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    cursor: pointer;
    background-color: var(--bg-secondary);
    aspect-ratio: 16 / 9;
    transition: transform 0.3s ease, opacity 0.3s ease;
    border: 1px solid var(--border-color);
}

.project-item:hover {
    transform: scale(1.02);
    border-color: var(--primary-purple);
}

.project-thumb img {
    width: 100%; height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.project-item:hover .project-thumb img { transform: scale(1.1); }

/* Overlay (Hover Efeito) */
.overlay {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(10, 10, 10, 0.85);
    display: flex; flex-direction: column;
    justify-content: center; align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    text-align: center;
    padding: 20px;
}

.project-item:hover .overlay { opacity: 1; }

.play-btn {
    width: 50px; height: 50px;
    background-color: var(--primary-purple);
    color: white;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.2rem;
    margin-bottom: 15px;
    box-shadow: 0 0 20px rgba(157, 0, 255, 0.6);
    transform: scale(0);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.project-item:hover .play-btn { transform: scale(1); }

.overlay h4 {
    color: white; font-size: 1.2rem; margin-bottom: 5px;
    transform: translateY(20px); transition: transform 0.3s ease;
}
.overlay span {
    color: var(--primary-purple); font-size: 0.9rem; font-weight: 600;
    transform: translateY(20px); transition: transform 0.3s ease 0.1s;
}
.project-item:hover .overlay h4, .project-item:hover .overlay span { transform: translateY(0); }

/* Modal (Lightbox) */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0; top: 0;
    width: 100%; height: 100%;
    background-color: rgba(0,0,0,0.95);
    justify-content: center; align-items: center;
    backdrop-filter: blur(5px);
}

.modal-content {
    position: relative;
    width: 90%; max-width: 900px;
    aspect-ratio: 16 / 9;
    background: black;
    box-shadow: 0 0 30px rgba(157, 0, 255, 0.3);
    border-radius: 10px;
    overflow: hidden;
    animation: zoomIn 0.3s ease;
}

@keyframes zoomIn {
    from { transform: scale(0.8); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.modal-content iframe { width: 100%; height: 100%; }

.close-modal {
    position: absolute;
    top: -40px; right: 0;
    color: white; font-size: 40px; font-weight: bold;
    cursor: pointer;
    transition: color 0.3s;
}
.close-modal:hover { color: var(--primary-purple); }

/* =========================================
   7. RESPONSIVIDADE (MOBILE & TABLETS)
   ========================================= */
@media (max-width: 950px) {
    
    /* Header e Navegação */
    header {
        flex-wrap: wrap;
        gap: 20px;
        padding: 15px 5%;
        background-color: var(--bg-main);
        border-bottom: 1px solid var(--border-color);
    }
    .logo { font-size: 1.5rem; }
    .header-btn { display: none; } /* Esconde contato no header */

    nav {
        order: 3;
        width: 100%;
        margin-top: 10px;
    }
    nav ul {
        justify-content: center;
        gap: 15px;
        flex-wrap: wrap;
    }
    nav ul li a {
        padding: 8px 12px;
        font-size: 0.9rem;
        background-color: var(--bg-secondary);
        border-radius: 20px;
        display: block;
    }

    /* HOME (Mobile) */
    .hero {
        display: block; /* Remove flexbox */
        text-align: center;
        padding: 80px 5% 60px 5%;
        min-height: auto;
    }
    .hero-visual-container { display: none; } /* Remove Arte Abstrata */
    .hero-text { width: 100%; max-width: 100%; }
    .badge-box { margin-bottom: 20px; }
    .hero-text h1 { font-size: 2.8rem; line-height: 1.2; }
    .hero-text p { font-size: 1.1rem; margin-bottom: 40px; }
    
    .cta-buttons {
        flex-direction: column;
        gap: 15px;
        width: 100%;
    }
    .btn-primary.big, .btn-outline { width: 100%; padding: 16px 0; }

    /* SERVIÇOS (Mobile) */
    .services-section { padding: 40px 5% 60px 5%; }
    .section-header h1 { font-size: 2.2rem; }
    .services-grid { grid-template-columns: 1fr; gap: 20px; }
    .service-card { padding: 30px 20px; }

    /* PORTFÓLIO (Mobile) */
    .portfolio-grid { grid-template-columns: 1fr; }
    .portfolio-filters { gap: 10px; }
    .filter-btn { padding: 8px 15px; font-size: 0.85rem; }
    .modal-content { width: 95%; }
    .close-modal { top: -50px; right: 10px; }
}