body {
    margin: 0;
    padding: 0;
    overflow: hidden;
    background-color: #000;
}

.webgl {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none; /* Prevents canvas from eating touch/click events */
}

/* =========================
   HEADER & NAVIGATION
========================== */

.main-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 25px 50px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 10000;
    font-family: 'Inter', sans-serif;
    box-sizing: border-box;
    pointer-events: auto;
    background: linear-gradient(to bottom, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0) 100%);
}

.header-left, .header-center, .header-right {
    display: flex;
    align-items: center;
    flex: 1;
}

.header-left {
    justify-content: flex-start;
}

.header-center {
    justify-content: center;
}

.header-right {
    justify-content: flex-end;
    gap: 40px;
}

/* --- LANGUAGE PILL --- */
.lang-pill {
    display: flex;
    align-items: center;
    background: rgba(10, 0, 0, 0.4);
    border-radius: 30px;
    padding: 4px;
    gap: 10px;
    backdrop-filter: blur(5px);
}

.lang-btn {
    background: transparent;
    border: none;
    color: #fff;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 1px;
    padding: 8px 18px;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
}

.lang-btn:hover:not(.active) {
    color: rgba(255,255,255,0.7);
}

.lang-btn.active {
    background: #00ffaa;
    color: #fff;
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

/* --- LOGO --- */
.site-logo {
    height: 45px;
    object-fit: contain;
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.2));
    transition: transform 0.4s ease;
    cursor: pointer;
}

.site-logo:hover {
    transform: scale(1.05);
}

/* --- SLIDE INDICATOR --- */
.slide-indicator {
    display: flex;
    align-items: center;
    gap: 12px;
}

.slide-num {
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1px;
}

.slide-bar {
    width: 60px;
    height: 2px;
    background: rgba(255, 255, 255, 0.2);
    position: relative;
}

.slide-progress {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 25%; /* Representa 1/4 */
    background: #fff;
}

/* --- MENU --- */
.nav-menu {
    display: flex;
    gap: 25px;
}

.nav-link {
    color: #fff;
    text-decoration: none;
    font-size: 12px;
    letter-spacing: 1px;
    font-weight: 700;
    transition: all 0.3s ease;
    text-transform: uppercase;
}

.nav-link:hover {
    color: #00ffaa;
}

/* =========================
   TELA DE LOADING
========================== */

.loader-screen {
    position: fixed;
    inset: 0;
    background: radial-gradient(circle at center, #111 0%, #000 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    z-index: 99999;
    transition: opacity 0.8s ease, visibility 0.8s ease;
    font-family: Arial, sans-serif;
}

.loader-screen.hide {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* =========================
   VÍDEO ANIMADO (LOADER)
========================== */
.loader-video {
    width: 220px;
    height: auto;
    object-fit: contain;
    margin-bottom: 15px;
    mix-blend-mode: screen; /* REMOVE O FUNDO PRETO DO VÍDEO */
}

/* =========================
   TEXTO
========================== */

.loading-text {
    margin-top: 40px;
    color: white;
    font-size: 14px;
    letter-spacing: 8px;
    text-transform: uppercase;
    opacity: 0.85;
    animation: blink 1.2s infinite;
}

/* =========================
   BARRA DE PROGRESSO
========================== */

.progress-container {
    width: 260px;
    height: 4px;
    background: rgba(255,255,255,0.08);
    border-radius: 20px;
    overflow: hidden;
    margin-top: 30px;
}

.progress-bar {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, #00ff88, #00ffaa);
    box-shadow: 0 0 15px #00ff88;
    transition: width 0.25s ease;
}

/* =========================
   ANIMAÇÕES
========================== */

@keyframes flamePulse {
    0%, 100% {
        transform: scale(1) rotate(0deg);
    }

    50% {
        transform: scale(1.08) rotate(-2deg);
    }
}

@keyframes floating {
    0%, 100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-12px);
    }
}

@keyframes ringPulse {
    0% {
        transform: scale(0.8);
        opacity: 0.8;
    }

    100% {
        transform: scale(1.3);
        opacity: 0;
    }
}

@keyframes blink {
    0%, 100% {
        opacity: 0.35;
    }

    50% {
        opacity: 1;
    }
}

/* =========================
   FOOTER
========================== */
.main-footer {
    position: fixed;
    bottom: 30px;
    left: 0;
    width: 100%;
    text-align: center;
    z-index: 900;
    pointer-events: none; /* Para não bloquear cliques na tela 3D */
}

.main-footer p {
    color: rgba(255, 255, 255, 0.25);
    font-size: 10px;
    letter-spacing: 3px;
    font-weight: 500;
    font-family: 'Inter', sans-serif;
    margin: 0;
    text-transform: uppercase;
}

/* =========================
   RUBY CARD
========================== */
.ruby-card {
    position: fixed;
    bottom: 40px;
    left: 40px;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 20px;
    display: flex;
    align-items: center;
    padding: 15px 30px 15px 15px;
    gap: 20px;
    z-index: 1000;
    pointer-events: none; /* Para os cliques passarem direto para o canvas */
    box-shadow: 0 15px 35px rgba(0,0,0,0.3);
}

.ruby-img {
    height: 70px;
    object-fit: contain;
    filter: drop-shadow(0 0 15px rgba(255, 0, 50, 0.6));
    animation: floating 4s ease-in-out infinite;
}

.ruby-text {
    color: white;
    font-family: 'Inter', sans-serif;
    font-weight: 800;
    font-size: 12px;
    line-height: 1.5;
    letter-spacing: 0.5px;
    margin: 0;
    text-transform: uppercase;
    text-shadow: 0 2px 5px rgba(0,0,0,0.5);
}

/* =========================
   CUSTOM CURSOR (Nave e Rastro)
========================== */
/* Custom cursor: only on desktop */
body, a, button, .site-logo, .lang-btn {
    cursor: none !important;
}

@media (max-width: 768px), (hover: none) {
    body, a, button, .site-logo, .lang-btn {
        cursor: auto !important;
    }
    .cursor-container,
    .cursor-trail {
        display: none !important;
    }
}

.cursor-container {
    position: fixed;
    top: 0;
    left: 0;
    pointer-events: none;
    z-index: 999999;
}

.cursor-ship {
    position: absolute;
    filter: drop-shadow(0 0 6px #00ff88);
    transition: filter 0.2s;
}

.cursor-ship polygon {
    transition: fill 0.2s;
}

.cursor-ship.hovering polygon {
    fill: #ffffff;
}

.cursor-ship.hovering {
    filter: drop-shadow(0 0 12px #ffffff);
}

.cursor-trail {
    position: fixed;
    width: 4px;
    height: 4px;
    background-color: #00ff88;
    border-radius: 50%;
    pointer-events: none;
    z-index: 999998;
    box-shadow: 0 0 5px #00ff88;
    transition: opacity 0.4s ease-out, transform 0.4s ease-out;
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.8;
}

/* =========================
   SLIDES (PÁGINAS)
========================== */
.slides-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none; /* Deixa cliques passarem pro 3D quando vazio */
    z-index: 500;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: translateY(60px); /* Vem de baixo */
    transition: opacity 0.7s cubic-bezier(0.25, 1, 0.5, 1), transform 0.7s cubic-bezier(0.25, 1, 0.5, 1);
    pointer-events: none;
}

.slide.active {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto; /* Reativa cliques dentro da caixa */
}

/* Conteúdo Fictício (Glassmorphism) */
.slide-content {
    background: rgba(10, 10, 10, 0.2);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    padding: 50px 60px;
    border-radius: 20px;
    text-align: center;
    max-width: 600px;
    color: white;
    font-family: 'Inter', sans-serif;
    box-shadow: 0 30px 60px rgba(0,0,0,0.6);
    transform: scale(0.95);
    transition: transform 0.7s cubic-bezier(0.25, 1, 0.5, 1);
}

.slide.active .slide-content {
    transform: scale(1);
}

.slide-content h1 {
    font-size: 32px;
    font-weight: 800;
    margin-bottom: 20px;
    letter-spacing: 2px;
    color: #fff;
    text-shadow: 0 0 15px rgba(255, 255, 255, 0.2);
}

.slide-content p {
    font-size: 15px;
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.6);
}

/* Prompts Grid */
.prompts-grid {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 10px;
    width: 100%;
}

.prompt-card {
    background: rgba(20, 20, 20, 0.4);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 25px;
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    text-align: left;
    transition: all 0.4s ease;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    position: relative;
    overflow: hidden;
}

.prompt-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(0,255,170,0.05) 0%, transparent 60%);
    opacity: 0;
    transition: opacity 0.5s;
    pointer-events: none;
}

.prompt-card:hover::before {
    opacity: 1;
}

.prompt-card:hover {
    transform: translateY(-5px);
    border-color: rgba(0,255,170,0.4);
    box-shadow: 0 15px 40px rgba(0,0,0,0.6), 0 0 20px rgba(0, 255, 170, 0.1);
}

.prompt-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.prompt-header h3 {
    font-size: 18px;
    font-weight: 600;
    color: #fff;
    margin: 0;
}

.copy-btn {
    background: transparent;
    color: #00ffaa;
    border: 1px solid #00ffaa;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
}

.copy-btn:hover {
    background: #00ffaa;
    color: #000;
    box-shadow: 0 5px 15px rgba(0, 255, 170, 0.4);
}

.copy-btn.copied {
    background: #fff;
    color: #000;
    border-color: #fff;
}

.prompt-body {
    background: rgba(0, 0, 0, 0.5);
    border: 1px dashed rgba(255, 255, 255, 0.2);
    padding: 15px;
    border-radius: 12px;
}

.prompt-text {
    font-size: 13px !important;
    line-height: 1.6 !important;
    color: rgba(255, 255, 255, 0.8) !important;
    margin: 0 !important;
    font-family: monospace;
    word-break: break-all;
}

/* Vídeo de Fundo dos Slides */
.bg-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -2;
    opacity: 1; /* Totalmente opaco para esconder a imagem de fundo do Home (WebGL) */
    pointer-events: none;
}

/* Camada escura por cima do vídeo para não ofuscar o texto */
#slide-budgets::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6); /* Escurece o vídeo */
    z-index: -1;
    pointer-events: none;
}

/* =========================
   FORMULÁRIO DE ORÇAMENTO
========================== */
.budget-content {
    max-width: 450px;
    padding: 40px;
}

.budget-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 25px;
    margin-bottom: 25px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 12px 15px;
    border-radius: 8px;
    color: white;
    font-family: 'Inter', sans-serif;
    font-size: 13px;
    outline: none;
    transition: border-color 0.3s;
    box-sizing: border-box;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.form-group select option {
    background: #111;
    color: white;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: #00ffaa;
}

.submit-btn {
    background: #00ffaa;
    color: #000;
    border: none;
    padding: 14px;
    border-radius: 8px;
    font-weight: 800;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 255, 170, 0.4);
}

.contact-info {
    text-align: left;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 20px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
    line-height: 1.8;
}

.contact-info p {
    margin: 5px 0;
}

.contact-info a {
    color: #00ffaa;
    text-decoration: none;
    font-weight: 600;
    transition: opacity 0.3s;
}

.contact-info a:hover {
    opacity: 0.8;
}

/* WhatsApp Floating Button */
.whatsapp-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 58px;
    height: 58px;
    background: #25D366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.5), 0 0 0 0 rgba(37, 211, 102, 0.4);
    z-index: 9999998;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    animation: whatsapp-pulse 2.5s infinite;
    text-decoration: none;
    pointer-events: auto;
}

.whatsapp-btn svg {
    width: 30px;
    height: 30px;
}

.whatsapp-btn:hover {
    transform: scale(1.12);
    box-shadow: 0 6px 30px rgba(37, 211, 102, 0.7), 0 0 0 0 rgba(37, 211, 102, 0);
    animation: none;
}

@keyframes whatsapp-pulse {
    0%   { box-shadow: 0 4px 20px rgba(37, 211, 102, 0.5), 0 0 0 0 rgba(37, 211, 102, 0.4); }
    70%  { box-shadow: 0 4px 20px rgba(37, 211, 102, 0.5), 0 0 0 14px rgba(37, 211, 102, 0); }
    100% { box-shadow: 0 4px 20px rgba(37, 211, 102, 0.5), 0 0 0 0 rgba(37, 211, 102, 0); }
}

/* =========================
   HAMBURGER BUTTON
========================== */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 1100;
}

.hamburger span {
    display: block;
    width: 24px;
    height: 2px;
    background: #fff;
    border-radius: 2px;
    transition: all 0.35s cubic-bezier(0.25, 1, 0.5, 1);
    transform-origin: center;
}

.hamburger.open span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}
.hamburger.open span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}
.hamburger.open span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* =========================
   MOBILE MENU OVERLAY
========================== */
.mobile-menu-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 99000;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 40px;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-20px);
    transition: opacity 0.4s ease, transform 0.4s ease;
}

.mobile-menu-overlay.open {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

.mobile-menu-close {
    position: absolute;
    top: 28px;
    right: 28px;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    line-height: 1;
    transition: color 0.3s;
}

.mobile-menu-close:hover {
    color: #00ffaa;
}

.mobile-nav {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
}

.mobile-nav-link {
    color: #fff;
    text-decoration: none;
    font-size: 28px;
    font-weight: 700;
    letter-spacing: 4px;
    font-family: 'Inter', sans-serif;
    text-transform: uppercase;
    transition: color 0.3s ease, transform 0.3s ease;
}

.mobile-nav-link:hover,
.mobile-nav-link.active {
    color: #00ffaa;
    transform: scale(1.05);
}

.mobile-lang-pill {
    display: flex;
    align-items: center;
    background: rgba(255,255,255,0.08);
    border-radius: 30px;
    padding: 4px;
    gap: 8px;
}

/* =========================
   RESPONSIVE: MOBILE
========================== */
@media (max-width: 768px) {

    .main-header {
        padding: 18px 22px;
        pointer-events: auto !important;
    }

    /* Esconde nav desktop e indicador */
    .nav-menu,
    .slide-indicator {
        display: none;
    }

    /* Mostra hamburger */
    .hamburger {
        display: flex;
        pointer-events: auto !important;
        touch-action: manipulation;
        -webkit-tap-highlight-color: transparent;
    }

    .lang-btn,
    .lang-pill,
    .header-left {
        pointer-events: auto !important;
        touch-action: manipulation;
        -webkit-tap-highlight-color: transparent;
    }

    .site-logo {
        height: 34px;
    }

    .lang-pill {
        gap: 6px;
    }

    .lang-btn {
        font-size: 11px;
        padding: 6px 12px;
    }

    /* Slide content mais compacto */
    .slide-content {
        padding: 28px 22px !important;
        max-width: 90vw !important;
    }

    .slide-content h1 {
        font-size: 20px !important;
    }

    .slide-content p {
        font-size: 13px !important;
    }

    /* Budget form */
    .budget-content {
        padding: 20px !important;
        max-width: 92vw !important;
    }

    .budget-content h1 {
        font-size: 18px !important;
    }

    /* Ruby card menor */
    .ruby-card {
        padding: 10px 18px 10px 10px;
        gap: 12px;
    }

    .ruby-img {
        height: 50px;
    }

    .ruby-text {
        font-size: 10px;
    }
}

/* Mobile overlay always tappable */
.mobile-menu-overlay,
.mobile-menu-overlay * {
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

.mobile-menu-close,
.mobile-nav-link,
.hamburger {
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}
