/* Otimizações adicionais para SEO e performance */

/* Lazy loading para imagens */
.lazy-image {
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

.lazy-image.loaded {
    opacity: 1;
}

/* Melhorias de acessibilidade */
:focus {
    outline: 3px solid var(--primary-color);
    outline-offset: 3px;
}

.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background-color: #000;
    color: #fff;
    padding: 8px;
    z-index: 1001;
    transition: top 0.3s;
    font-weight: bold;
  }
  
  .skip-link:focus {
    top: 0;
  }

/* Melhorias de performance */
@media print {
    .header, .footer, .courses-button, .copy-button, .final-cta {
        display: none;
    }
}

/* Otimizações para dispositivos de alta resolução */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .hero, .final-cta {
        background-image: url('imagens/pattern-2x.svg');
    }
}

/* Suporte para modo escuro */
@media (prefers-color-scheme: dark) {
    :root {
        --light-bg: #1a1a1a;
        --light-text: #f0f0f0;
        --text-color: #e0e0e0;
        --dark-bg: #000;
        --border-color: #333;
    }
    
    body {
        color: var(--light-text);
        background-color: var(--dark-bg);
    }
    
    .header, .footer {
        background-color: #111;
    }
    
    .feature-item, .step-item, .coupon-card {
        background-color: #222;
        color: var(--light-text);
    }
    
    .conclusion-box {
        background-color: rgba(11, 164, 174, 0.2);
    }
    
    .coupon-code, .final-coupon-code {
        background-color: rgba(11, 164, 174, 0.2);
    }
    
    .intro-text, .footer-disclaimer, .footer-copyright {
        color: #aaa;
    }
}

/* Animações sutis */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.hero h1, .hero .subtitle, .coupon-card, .step-item, .feature-item {
    animation: fadeIn 0.6s ease-out forwards;
}

.hero .subtitle {
    animation-delay: 0.2s;
}

.coupon-card {
    animation-delay: 0.4s;
}

.step-item:nth-child(1) { animation-delay: 0.2s; }
.step-item:nth-child(2) { animation-delay: 0.3s; }
.step-item:nth-child(3) { animation-delay: 0.4s; }
.step-item:nth-child(4) { animation-delay: 0.5s; }
.step-item:nth-child(5) { animation-delay: 0.6s; }

.feature-item:nth-child(1) { animation-delay: 0.2s; }
.feature-item:nth-child(2) { animation-delay: 0.3s; }
.feature-item:nth-child(3) { animation-delay: 0.4s; }
.feature-item:nth-child(4) { animation-delay: 0.5s; }
.feature-item:nth-child(5) { animation-delay: 0.6s; }
.feature-item:nth-child(6) { animation-delay: 0.7s; }
.feature-item:nth-child(7) { animation-delay: 0.8s; }
.feature-item:nth-child(8) { animation-delay: 0.9s; }

/* Notificação de cópia de cupom */
.copy-notification {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background-color: var(--success-color);
    color: white;
    padding: 12px 24px;
    border-radius: var(--border-radius);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 1000;
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
    display: flex;
    align-items: center;
    gap: 10px;
}

.copy-notification.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

.copy-notification span {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background-color: white;
    color: var(--success-color);
    border-radius: 50%;
    font-weight: bold;
}
