/* ========================================
   LANDING PAGE MANIPULADORA - CSS
   Demonstração de Dark UX Patterns
   ======================================== */

/* ========================================
   VARIÁVEIS E RESET
   ======================================== */

:root {
    --color-blood-red: #dc2626;
    --color-dark-red: #7f1d1d;
    --color-black: #000000;
    --color-gray-dark: #111827;
    --color-gray-medium: #1f2937;
    --color-gray-light: #374151;
    --shadow-glow-red: 0 0 20px rgba(220, 38, 38, 0.5);
    --shadow-glow-yellow: 0 0 20px rgba(234, 179, 8, 0.3);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--color-black);
    color: #f3f4f6;
    overflow-x: hidden;
    line-height: 1.6;
}

/* ========================================
   EFEITO DE RUÍDO/GRÃO (NOISE)
   ======================================== */

.noise-bg {
    background-image: 
        repeating-linear-gradient(
            0deg,
            transparent,
            transparent 2px,
            rgba(255, 255, 255, 0.03) 2px,
            rgba(255, 255, 255, 0.03) 4px
        );
    pointer-events: none;
}

.noise-bg::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.05'/%3E%3C/svg%3E");
    opacity: 0.4;
    mix-blend-mode: overlay;
    pointer-events: none;
}

/* ========================================
   EFEITO GLITCH NO TEXTO
   ======================================== */

.glitch-wrapper {
    position: relative;
}

.glitch {
    position: relative;
    text-shadow: 
        0.02em 0 0 rgba(255, 0, 0, 0.75),
        -0.02em -0.02em 0 rgba(0, 255, 255, 0.75),
        0.02em 0.02em 0 rgba(255, 255, 0, 0.75);
    animation: glitch-anim 2s infinite;
}

.glitch-2 {
    position: relative;
    animation: glitch-anim-2 3s infinite;
}

@keyframes glitch-anim {
    0%, 100% {
        text-shadow: 
            0.02em 0 0 rgba(255, 0, 0, 0.75),
            -0.02em -0.02em 0 rgba(0, 255, 255, 0.75),
            0.02em 0.02em 0 rgba(255, 255, 0, 0.75);
    }
    25% {
        text-shadow: 
            0.04em 0.02em 0 rgba(255, 0, 0, 0.75),
            -0.04em -0.04em 0 rgba(0, 255, 255, 0.75),
            0.04em 0.04em 0 rgba(255, 255, 0, 0.75);
    }
    50% {
        text-shadow: 
            -0.02em 0.04em 0 rgba(255, 0, 0, 0.75),
            0.02em -0.02em 0 rgba(0, 255, 255, 0.75),
            -0.04em 0.02em 0 rgba(255, 255, 0, 0.75);
    }
    75% {
        text-shadow: 
            0.03em -0.03em 0 rgba(255, 0, 0, 0.75),
            -0.03em 0.03em 0 rgba(0, 255, 255, 0.75),
            0.01em -0.01em 0 rgba(255, 255, 0, 0.75);
    }
}

@keyframes glitch-anim-2 {
    0%, 100% {
        transform: translateX(0);
    }
    20% {
        transform: translateX(-2px);
    }
    40% {
        transform: translateX(2px);
    }
    60% {
        transform: translateX(-2px);
    }
    80% {
        transform: translateX(2px);
    }
}

/* ========================================
   ANIMAÇÃO DE PISCAR (OLHOS)
   ======================================== */

@keyframes blink {
    0%, 49%, 51%, 100% {
        opacity: 0.2;
    }
    50% {
        opacity: 0.8;
    }
}

@keyframes blink-delay {
    0%, 100% {
        opacity: 0.2;
    }
    33% {
        opacity: 0.8;
    }
    66% {
        opacity: 0.2;
    }
}

.animate-blink {
    animation: blink 4s ease-in-out infinite;
}

.animate-blink-delay {
    animation: blink-delay 5s ease-in-out infinite 1s;
}

/* ========================================
   SOMBRAS INTENSAS E DRAMÁTICAS
   ======================================== */

.shadow-dark {
    box-shadow: 
        0 4px 6px rgba(0, 0, 0, 0.5),
        0 10px 20px rgba(220, 38, 38, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.shadow-text {
    text-shadow: 
        0 0 10px rgba(220, 38, 38, 0.5),
        0 0 20px rgba(220, 38, 38, 0.3),
        0 2px 4px rgba(0, 0, 0, 0.8);
}

/* ========================================
   BOTÕES CTA MANIPULADORES
   ======================================== */

.cta-button {
    position: relative;
    overflow: hidden;
    box-shadow: 
        0 4px 14px rgba(220, 38, 38, 0.4),
        0 10px 30px rgba(220, 38, 38, 0.2);
    transition: all 0.3s ease;
}

.cta-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.2),
        transparent
    );
    transition: left 0.5s;
}

.cta-button:hover::before {
    left: 100%;
}

.cta-button:hover {
    box-shadow: 
        0 6px 20px rgba(220, 38, 38, 0.6),
        0 15px 40px rgba(220, 38, 38, 0.3);
    transform: translateY(-2px) scale(1.05);
}

.cta-button:active {
    transform: translateY(0) scale(1.02);
}

/* Animação de pulso no botão */
@keyframes pulse-button {
    0%, 100% {
        box-shadow: 
            0 4px 14px rgba(220, 38, 38, 0.4),
            0 10px 30px rgba(220, 38, 38, 0.2);
    }
    50% {
        box-shadow: 
            0 4px 14px rgba(220, 38, 38, 0.6),
            0 10px 30px rgba(220, 38, 38, 0.4);
    }
}

.animate-pulse-button {
    animation: pulse-button 2s ease-in-out infinite;
}

/* ========================================
   ANIMAÇÃO DE PULSO LENTO
   ======================================== */

@keyframes pulse-slow {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

.animate-pulse-slow {
    animation: pulse-slow 3s ease-in-out infinite;
}

/* ========================================
   ANIMAÇÃO DE FADE IN
   ======================================== */

@keyframes fade-in {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fade-in 0.6s ease-out forwards;
}

/* ========================================
   QUIZ - ESTILOS ESPECÍFICOS
   ======================================== */

.quiz-option {
    cursor: pointer;
    position: relative;
    transition: all 0.3s ease;
}

.quiz-option:hover {
    transform: translateX(10px);
    box-shadow: 
        0 4px 20px rgba(220, 38, 38, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.quiz-option:active {
    transform: translateX(10px) scale(0.98);
}

.question-container {
    animation: fade-in 0.5s ease-out;
}

/* ========================================
   COUNTDOWN E TIMERS
   ======================================== */

#countdown, #urgencyTimer {
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.05em;
    text-shadow: 
        0 0 10px rgba(220, 38, 38, 0.6),
        0 0 20px rgba(220, 38, 38, 0.4);
}

/* ========================================
   CARDS E CONTAINERS
   ======================================== */

.hover\:scale-102:hover {
    transform: scale(1.02);
}

/* Efeito de brilho vermelho ao passar o mouse */
.border-red-900:hover {
    box-shadow: 
        0 0 20px rgba(220, 38, 38, 0.3),
        inset 0 1px 0 rgba(220, 38, 38, 0.1);
}

/* ========================================
   SCROLLBAR PERSONALIZADA (SOMBRIA)
   ======================================== */

::-webkit-scrollbar {
    width: 12px;
}

::-webkit-scrollbar-track {
    background: var(--color-black);
    border-left: 1px solid var(--color-gray-dark);
}

::-webkit-scrollbar-thumb {
    background: var(--color-gray-medium);
    border-radius: 6px;
    border: 2px solid var(--color-black);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--color-blood-red);
    box-shadow: 0 0 10px rgba(220, 38, 38, 0.5);
}

/* Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: var(--color-gray-medium) var(--color-black);
}

/* ========================================
   EFEITOS DE HOVER EM ÍCONES
   ======================================== */

i.fas, i.far, i.fab {
    transition: all 0.3s ease;
}

.fa-eye:hover,
.fa-search:hover,
.fa-exclamation-triangle:hover {
    transform: scale(1.1);
    filter: drop-shadow(0 0 10px rgba(220, 38, 38, 0.6));
}

/* ========================================
   RESPONSIVE - MOBILE FIRST
   ======================================== */

@media (max-width: 768px) {
    .glitch,
    .glitch-2 {
        font-size: 2rem;
        line-height: 1.2;
    }
    
    .cta-button {
        width: 100%;
        padding: 1rem 1.5rem;
        font-size: 0.95rem;
    }
    
    #countdown,
    #urgencyTimer {
        font-size: 1.75rem;
    }
    
    section {
        padding: 2.5rem 1rem;
    }
    
    /* Melhor espaçamento mobile */
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    /* Texto mais legível no mobile */
    p, li {
        line-height: 1.6;
    }
    
    /* Botões com melhor área de toque */
    button, .quiz-option {
        min-height: 44px;
    }
}

@media (max-width: 480px) {
    .glitch,
    .glitch-2 {
        font-size: 1.75rem;
    }
    
    section {
        padding: 2rem 0.75rem;
    }
    
    .cta-button {
        font-size: 0.875rem;
        padding: 0.875rem 1.25rem;
    }
}

/* ========================================
   OVERLAY DE AVISO
   ======================================== */

#warningOverlay {
    backdrop-filter: blur(10px);
    z-index: 9999;
}

/* ========================================
   ANIMAÇÕES DE ENTRADA
   ======================================== */

@keyframes slide-up {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slide-down {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========================================
   ESTADOS DE LOADING (PARA INTERAÇÕES)
   ======================================== */

.loading {
    position: relative;
    pointer-events: none;
    opacity: 0.6;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ========================================
   EFEITOS DE FOCO (ACESSIBILIDADE)
   ======================================== */

button:focus,
a:focus {
    outline: 2px solid rgba(220, 38, 38, 0.5);
    outline-offset: 2px;
}

/* ========================================
   ANIMAÇÕES DE APARIÇÃO PARA SEÇÕES
   ======================================== */

section {
    opacity: 0;
    animation: fade-in 1s ease-out forwards;
}

section:nth-child(1) { animation-delay: 0s; }
section:nth-child(2) { animation-delay: 0.2s; }
section:nth-child(3) { animation-delay: 0.4s; }
section:nth-child(4) { animation-delay: 0.6s; }

/* ========================================
   DEPOIMENTOS (FAKE TESTIMONIALS)
   ======================================== */

.bg-gray-900:hover {
    transform: translateY(-5px);
    transition: transform 0.3s ease;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

/* ========================================
   PREVENÇÃO DE SELEÇÃO EM ELEMENTOS CRÍTICOS
   ======================================== */

.no-select {
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

/* ========================================
   EFEITO DE SCANLINE (OPCIONAL)
   ======================================== */

body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        0deg,
        rgba(0, 0, 0, 0.15),
        rgba(0, 0, 0, 0.15) 1px,
        transparent 1px,
        transparent 2px
    );
    pointer-events: none;
    z-index: 9998;
    opacity: 0.1;
}

/* ========================================
   PERFORMANCE E OTIMIZAÇÃO
   ======================================== */

* {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img, video {
    max-width: 100%;
    height: auto;
}

/* Otimização de animações */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
