/* ==========================================================================
   VARIÁVEIS GERAIS (TEMA ESCURO PREMIUM)
   ========================================================================== */
:root {
    --bg-color: #030712; /* Fundo extremamente escuro */
    --bg-gradient: radial-gradient(circle at top, #111827 0%, #030712 100%);
    --text-primary: #f9fafb;
    --text-secondary: #9ca3af;
    
    --primary-color: #3b82f6; /* Azul moderno */
    --primary-hover: #2563eb;
    --accent-color: #60a5fa;
    
    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.05);
    --glass-hover: rgba(255, 255, 255, 0.08);
    
    --radius-lg: 24px;
    --radius-md: 16px;
    --radius-sm: 8px;
    
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ==========================================================================
   RESET E CONFIGURAÇÕES BÁSICAS
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Plus Jakarta Sans', sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-color);
    background-image: var(--bg-gradient);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
}

/* Barra de rolagem personalizada */
::-webkit-scrollbar {
    width: 10px;
}
::-webkit-scrollbar-track {
    background: var(--bg-color);
}
::-webkit-scrollbar-thumb {
    background: #374151;
    border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
}

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

ul {
    list-style: none;
}

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

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ==========================================================================
   TIPOGRAFIA
   ========================================================================== */
h1, h2, h3 {
    line-height: 1.2;
    font-weight: 700;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    background: linear-gradient(to right, #ffffff, var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* ==========================================================================
   MENU FIXO (HEADER)
   ========================================================================== */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    transition: var(--transition);
    padding: 20px 0;
}

header.scrolled {
    padding: 15px 0;
    background: rgba(3, 7, 18, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--glass-border);
}

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

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

.logo span {
    color: var(--primary-color);
}

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

.nav-links a {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: var(--transition);
}

.nav-links a:hover {
    color: var(--primary-color);
}

@media (max-width: 768px) {
    .nav-links {
        display: none; 
    }
}

/* ==========================================================================
   HERO SECTION
   ========================================================================== */
.hero {
    /* Altura ajustada para reduzir o espaço entre seções */
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    padding: 160px 0 80px 0;
}

/* Efeito de luz de fundo suave */
.hero::before {
    content: '';
    position: absolute;
    width: 40vw;
    height: 40vw;
    background: var(--primary-color);
    filter: blur(150px);
    opacity: 0.15;
    border-radius: 50%;
    z-index: -1;
}

/* Alteração: Centralização garantida no PC e Celular */
.hero-content {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.hero-greeting {
    display: inline-block;
    padding: 8px 16px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 30px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--accent-color);
    margin-bottom: 24px;
    backdrop-filter: blur(10px);
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    margin-bottom: 24px;
    letter-spacing: -1px;
}

.hero-desc {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 16px 32px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 1rem;
    transition: var(--transition);
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: var(--primary-color);
    color: #ffffff;
    box-shadow: 0 4px 20px rgba(59, 130, 246, 0.4);
}

.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(59, 130, 246, 0.5);
}

/* ==========================================================================
   SOBRE MIM
   ========================================================================== */
.about {
    padding: 40px 0 100px 0; /* Ajuste no padding do topo para aproximar */
    position: relative;
}

.about-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 60px 40px;
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.about-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.about-text {
    font-size: 1.1rem;
    color: var(--text-secondary);
    line-height: 1.8;
}

.about-text strong {
    color: var(--text-primary);
    font-weight: 600;
}

/* Container do botão após o Sobre Mim */
.about-btn-wrapper {
    text-align: center;
    margin-top: 40px;
}

/* ==========================================================================
   PORTFÓLIO E VIDEOS (IFRAME YOUTUBE DIRETO)
   ========================================================================== */
.portfolio {
    padding: 100px 0;
}

.portfolio-category {
    margin-bottom: 80px;
}

.category-title {
    font-size: 1.8rem;
    margin-bottom: 40px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.category-title i {
    color: var(--primary-color);
}

/* ALINHAMENTO ESTRITO PARA COMPUTADOR */
.videos-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    align-items: stretch;
}

.shorts-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr); 
    gap: 24px;
    align-items: stretch;
}

.portfolio-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.portfolio-card:hover {
    transform: translateY(-5px);
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.video-container {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9; 
    overflow: hidden;
    background-color: #000;
    border-bottom: 1px solid var(--glass-border);
}

.video-container.shorts-video {
    aspect-ratio: 9 / 16; 
    border-bottom: none;
}

.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.card-content {
    padding: 24px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    justify-content: center;
    text-align: center;
}

.card-title {
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* ==========================================================================
   SERVIÇOS
   ========================================================================== */
.services {
    padding: 100px 0;
    background: linear-gradient(to bottom, transparent, rgba(59, 130, 246, 0.03), transparent);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
}

.service-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 32px 24px;
    text-align: center;
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-5px);
    background: var(--glass-hover);
    border-color: rgba(59, 130, 246, 0.3);
}

.service-icon {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 16px;
}

.service-title {
    font-size: 1.1rem;
    font-weight: 600;
}

/* ==========================================================================
   SECÇÃO DE PERGUNTAS FREQUENTES (FAQ)
   ========================================================================== */
.faq {
    padding: 100px 0;
    position: relative;
}

.faq-list {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.faq-item {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: var(--transition);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.faq-item:hover {
    background: var(--glass-hover);
    border-color: rgba(255, 255, 255, 0.1);
}

.faq-question {
    padding: 24px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    user-select: none;
    gap: 20px;
}

.faq-question h3 {
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--text-primary);
    transition: color 0.3s ease;
}

.faq-toggle {
    position: relative;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), background-color 0.3s ease, border-color 0.3s ease;
}

.faq-icon-line {
    position: relative;
    width: 12px;
    height: 2px;
    background-color: var(--text-primary);
    display: block;
    transition: background-color 0.3s ease;
}

.faq-icon-line::before {
    content: '';
    position: absolute;
    width: 2px;
    height: 12px;
    background-color: var(--text-primary);
    left: 5px;
    top: -5px;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s ease;
}

.faq-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.faq-answer {
    padding: 0 30px 24px 30px;
}

.faq-answer p {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.7;
}

/* CORREÇÃO DE BUG: Classe alterada de '.active' para '.faq-open' 
   para não entrar em conflito com a animação de scroll reveal 
*/
.faq-item.faq-open {
    border-color: rgba(59, 130, 246, 0.3);
    background: rgba(255, 255, 255, 0.05);
}

.faq-item.faq-open .faq-question h3 {
    color: var(--primary-color);
}

.faq-item.faq-open .faq-toggle {
    transform: rotate(180deg);
    border-color: rgba(59, 130, 246, 0.4);
    background: rgba(59, 130, 246, 0.1);
}

.faq-item.faq-open .faq-icon-line {
    background-color: var(--primary-color);
}

.faq-item.faq-open .faq-icon-line::before {
    transform: scaleY(0); 
    opacity: 0;
}

/* ==========================================================================
   CONTATO
   ========================================================================== */
.contact {
    padding: 120px 0;
    text-align: center;
}

.contact-box {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 80px 40px;
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
}

.contact-box::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at center, rgba(37, 211, 102, 0.1) 0%, transparent 50%);
    z-index: 0;
    pointer-events: none;
}

.contact-content {
    position: relative;
    z-index: 1;
}

.contact-title {
    font-size: 2.5rem;
    margin-bottom: 16px;
}

.contact-desc {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 40px;
}

/* BOTÃO DO WHATSAPP */
.btn-whatsapp {
    background: #25D366; 
    color: #ffffff;
    font-size: 1.2rem;
    padding: 20px 40px;
    border-radius: 50px;
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.3);
    position: relative;
    overflow: hidden;
    will-change: transform, box-shadow;
    animation: pulseWhatsApp 10s infinite cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-whatsapp:hover {
    background: #1ebc5a;
    transform: translateY(-4px) scale(1.03);
    box-shadow: 0 8px 30px rgba(37, 211, 102, 0.5);
}

.btn-whatsapp:active {
    transform: scale(0.96) translateY(-1px);
    box-shadow: 0 3px 10px rgba(37, 211, 102, 0.3);
    transition: transform 0.1s ease;
}

@keyframes pulseWhatsApp {
    0%, 94%, 100% {
        box-shadow: 0 4px 20px rgba(37, 211, 102, 0.3);
        transform: scale(1);
    }
    97% {
        box-shadow: 0 4px 25px rgba(37, 211, 102, 0.6);
        transform: scale(1.03);
    }
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
footer {
    text-align: center;
    padding: 30px 0;
    border-top: 1px solid var(--glass-border);
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* ==========================================================================
   BOTÃO VOLTAR AO TOPO
   ========================================================================== */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
    font-size: 1.5rem;
    cursor: pointer;
    backdrop-filter: blur(10px);
    transition: var(--transition);
    opacity: 0;
    visibility: hidden;
    z-index: 999;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    transform: translateY(-5px);
}

/* ==========================================================================
   ANIMAÇÕES (SCROLL REVEAL)
   ========================================================================== */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* ==========================================================================
   RESPONSIVIDADE ALINHAMENTO
   ========================================================================== */
/* Tablet */
@media (max-width: 992px) {
    .shorts-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Celular */
@media (max-width: 768px) {
    .videos-grid {
        grid-template-columns: 1fr;
    }
    .shorts-grid {
        grid-template-columns: repeat(2, 1fr); 
        gap: 16px;
    }
    .contact-box {
        padding: 40px 20px;
    }
    .faq-question {
        padding: 20px;
    }
    .faq-answer {
        padding: 0 20px 20px 20px;
    }
    .btn-whatsapp {
        width: 100%;
        padding: 16px 20px;
        font-size: 1.1rem;
    }
    .btn-whatsapp:hover {
        transform: none;
    }
    .btn-whatsapp:active {
        transform: scale(0.95);
    }
    @keyframes pulseWhatsApp {
        0%, 94%, 100% {
            box-shadow: 0 4px 20px rgba(37, 211, 102, 0.3);
            transform: scale(1);
        }
        97% {
            box-shadow: 0 4px 25px rgba(37, 211, 102, 0.5);
            transform: scale(1.02);
        }
    }
}

/* Celular Pequeno */
@media (max-width: 480px) {
    .shorts-grid {
        grid-template-columns: 1fr; 
    }
}