/* Estilos adicionais e variações para o tema BeiraJovem */

/* Variação de botão com ícone (para uso futuro) */
.link-button.has-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.link-button .icon {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

.link-button.loading {
    pointer-events: none;
    opacity: 0.7;
}

.link-button.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: white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Estilos para modo escuro (caso necessário) */
@media (prefers-color-scheme: dark) {
    .link-button {
        background: rgba(0,0,0,0.3);
        border-color: rgba(255,255,255,0.3);
    }
    
    .link-button:hover {
        background: rgba(0,0,0,0.5);
    }
}

/* Animação de entrada para os botões */
.links-container .link-button {
    opacity: 0;
    transform: translateY(20px);
    animation: slideUpBounce 0.8s ease forwards;
}

.links-container .link-button:nth-child(1) { animation-delay: 0.1s; }
.links-container .link-button:nth-child(2) { animation-delay: 0.2s; }
.links-container .link-button:nth-child(3) { animation-delay: 0.3s; }
.links-container .link-button:nth-child(4) { animation-delay: 0.4s; }
.links-container .link-button:nth-child(5) { animation-delay: 0.5s; }
.links-container .link-button:nth-child(6) { animation-delay: 0.6s; }
.links-container .link-button:nth-child(7) { animation-delay: 0.7s; }
.links-container .link-button:nth-child(8) { animation-delay: 0.8s; }
.links-container .link-button:nth-child(9) { animation-delay: 0.9s; }
.links-container .link-button:nth-child(10) { animation-delay: 1.0s; }

@keyframes slideUpBounce {
    0% {
        opacity: 0;
        transform: translateY(30px) scale(0.9);
    }
    60% {
        opacity: 1;
        transform: translateY(-5px) scale(1.02);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Animação da logo */
.logo-container img {
    animation: logoFloat 6s ease-in-out infinite;
}

@keyframes logoFloat {
    0%, 100% {
        transform: translateY(0px) scale(1);
    }
    50% {
        transform: translateY(-10px) scale(1.05);
    }
}

/* Animação do título */
.linktree-title {
    animation: titlePulse 4s ease-in-out infinite;
}

@keyframes titlePulse {
    0%, 100% {
        text-shadow: 0 4px 8px rgba(0,0,0,0.3);
        transform: scale(1);
    }
    50% {
        text-shadow: 0 6px 12px rgba(0,0,0,0.4), 0 0 20px rgba(255,255,255,0.1);
        transform: scale(1.02);
    }
}

/* Efeito de hover mais dinâmico */
.link-button {
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.link-button:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 15px 35px rgba(0,0,0,0.3);
}

/* Animação de clique */
.link-button:active {
    transform: translateY(-2px) scale(1.02);
    transition: all 0.1s ease;
}

/* Partículas flutuantes (opcional) */
.linktree-container::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(2px 2px at 20px 30px, rgba(255,255,255,0.1), transparent),
        radial-gradient(2px 2px at 40px 70px, rgba(255,255,255,0.1), transparent),
        radial-gradient(1px 1px at 90px 40px, rgba(255,255,255,0.1), transparent),
        radial-gradient(1px 1px at 130px 80px, rgba(255,255,255,0.1), transparent),
        radial-gradient(2px 2px at 160px 30px, rgba(255,255,255,0.1), transparent);
    background-repeat: repeat;
    background-size: 200px 100px;
    animation: sparkle 20s linear infinite;
    pointer-events: none;
    z-index: 1;
}

@keyframes sparkle {
    from {
        transform: translateX(0);
    }
    to {
        transform: translateX(200px);
    }
}

/* Melhor suporte para telas muito pequenas */
@media (max-width: 320px) {
    .linktree-title {
        font-size: 1.5rem;
    }
    
    .logo-container img {
        max-width: 100px;
    }
    
    .link-button {
        padding: 0.8rem 1rem;
        font-size: 1rem;
    }
    
    .links-container {
        max-width: 280px;
    }
}

/* Estilos para impressão (caso necessário) */
@media print {
    body {
        background: white !important;
        color: black !important;
    }
    
    .link-button {
        background: white !important;
        border: 2px solid black !important;
        color: black !important;
    }
    
    .link-button::before {
        display: none;
    }
}

/* Acessibilidade: High contrast mode */
@media (prefers-contrast: high) {
    .link-button {
        background: rgba(255,255,255,0.9);
        color: black;
        border: 2px solid black;
    }
    
    .link-button:hover {
        background: black;
        color: white;
    }
}

/* Reduce motion para usuários com preferência - MAS MANTÉM ANIMAÇÃO DO FUNDO */
@media (prefers-reduced-motion: reduce) {
    /* Reduz apenas animações dos elementos, NÃO do fundo */
    .logo-container img,
    .linktree-title,
    .link-button,
    .linktree-container::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    /* MANTÉM a animação do gradiente de fundo */
    body {
        animation: gradientShift 8s ease infinite !important;
    }
}
