/* ===== CARD ENHANCEMENTS - UI/UX IMPROVEMENTS ===== */

/* ===== 1. GRADIENTS DINÂMICOS ===== */
.raspinha-card {
    background: linear-gradient(145deg, #1e1e1e 0%, #2a2a2a 100%);
    background-size: 200% 200%;
    animation: gradientShift 3s ease infinite;
    position: relative;
    overflow: hidden;
}

/* Gradientes específicos por categoria */
.raspinha-card[data-category="dinheiro"] {
    background: linear-gradient(135deg, #05DB00, #05DB00, #05DB00);
    background-size: 200% 200%;
    animation: gradientShift 3s ease infinite;
}

.raspinha-card[data-category="produtos"] {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed, #6d28d9);
    background-size: 200% 200%;
    animation: gradientShift 3s ease infinite;
}

@keyframes gradientShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

/* ===== 2. PARTÍCULAS DE FUNDO ===== */
.raspinha-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 20% 30%, rgba(5, 219, 0, 0.1) 2px, transparent 2px),
        radial-gradient(circle at 80% 70%, rgba(5, 219, 0, 0.1) 2px, transparent 2px),
        radial-gradient(circle at 40% 80%, rgba(5, 219, 0, 0.08) 1px, transparent 1px),
        radial-gradient(circle at 90% 20%, rgba(5, 219, 0, 0.08) 1px, transparent 1px);
    background-size: 100px 100px, 80px 80px, 60px 60px, 120px 120px;
    animation: particleFloat 8s ease-in-out infinite;
    pointer-events: none;
    z-index: 1;
}

@keyframes particleFloat {
    0%, 100% { 
        transform: translateY(0px) translateX(0px);
        opacity: 0.3;
    }
    25% { 
        transform: translateY(-10px) translateX(5px);
        opacity: 0.6;
    }
    50% { 
        transform: translateY(-5px) translateX(-5px);
        opacity: 0.4;
    }
    75% { 
        transform: translateY(5px) translateX(10px);
        opacity: 0.7;
    }
}

/* ===== 3. EFEITOS DE PROFUNDIDADE ===== */
.raspinha-card {
    transform: translateY(0) scale(1);
    box-shadow: 
        0 4px 12px rgba(0, 0, 0, 0.1),
        0 2px 4px rgba(5, 219, 0, 0.05);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.raspinha-card:hover {
    transform: translateY(-12px) scale(1.02);
    box-shadow: 
        0 25px 50px rgba(0, 0, 0, 0.3),
        0 15px 30px rgba(5, 219, 0, 0.2),
        0 0 0 1px rgba(5, 219, 0, 0.3);
    border-color: rgba(5, 219, 0, 0.4);
}

/* ===== 4. BOTÃO JOGAR APRIMORADO ===== */
.play-btn {
    background: linear-gradient(135deg, #05DB00, #05DB00);
    background-size: 200% 200%;
    animation: gradientShift 3s ease infinite;
    color: #ffffff;
    text-decoration: none;
    padding: 0.75rem 1.5rem;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 
        0 4px 15px rgba(5, 219, 0, 0.3),
        0 2px 4px rgba(0, 0, 0, 0.1);
    white-space: nowrap;
    position: relative;
    overflow: hidden;
    transform: scale(1);
}

.play-btn::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 ease;
}

.play-btn:hover {
    background: linear-gradient(135deg, #05DB00, #05DB00);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 
        0 8px 25px rgba(5, 219, 0, 0.4),
        0 4px 8px rgba(0, 0, 0, 0.2);
    color: #ffffff;
}

.play-btn:hover::before {
    left: 100%;
}

.play-btn:active {
    transform: translateY(-1px) scale(0.98);
    box-shadow: 
        0 4px 15px rgba(5, 219, 0, 0.3),
        0 2px 4px rgba(0, 0, 0, 0.1);
}

/* ===== 5. BADGES ANIMADOS ===== */
.category-badge {
    position: absolute;
    top: 0.75rem;
    left: 0.75rem;
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    backdrop-filter: blur(20px);
    z-index: 2;
    transition: all 0.3s ease;
    animation: badgePulse 2s ease-in-out infinite;
}

.category-badge.dinheiro {
    background: linear-gradient(135deg, #05DB00, #05DB00);
    color: #ffffff;
    box-shadow: 
        0 4px 15px rgba(5, 219, 0, 0.3),
        0 0 0 1px rgba(5, 219, 0, 0.2);
}

.category-badge.produtos {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
    color: #ffffff;
    box-shadow: 
        0 4px 15px rgba(139, 92, 246, 0.3),
        0 0 0 1px rgba(139, 92, 246, 0.2);
}

@keyframes badgePulse {
    0%, 100% { 
        transform: scale(1);
        box-shadow: 0 4px 15px rgba(5, 219, 0, 0.3);
    }
    50% { 
        transform: scale(1.05);
        box-shadow: 0 6px 20px rgba(5, 219, 0, 0.4);
    }
}

/* ===== 6. PREÇO DESTACADO ===== */
.card-price {
    display: flex;
    align-items: baseline;
    gap: 0.25rem;
    position: relative;
}

.price-label {
    color: #05DB00;
    font-size: 0.9rem;
    font-weight: 600;
    animation: priceGlow 2s ease-in-out infinite;
}

.price-value {
    color: #05DB00;
    font-size: 1.25rem;
    font-weight: 800;
    text-shadow: 0 0 10px rgba(5, 219, 0, 0.3);
    animation: priceGlow 2s ease-in-out infinite 0.5s;
}

@keyframes priceGlow {
    0%, 100% { 
        text-shadow: 0 0 10px rgba(5, 219, 0, 0.3);
    }
    50% { 
        text-shadow: 0 0 20px rgba(5, 219, 0, 0.6);
    }
}

/* ===== 7. TÍTULO E DESCRIÇÃO MELHORADOS ===== */
.card-title {
    color: #ffffff;
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0 0 0.5rem 0;
    line-height: 1.3;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
}

.raspinha-card:hover .card-title {
    text-shadow: 0 4px 8px rgba(0, 0, 0, 0.4);
    transform: translateY(-1px);
}

.card-description {
    color: #9ca3af;
    font-size: 0.9rem;
    margin: 0 0 1.5rem 0;
    line-height: 1.4;
    transition: all 0.3s ease;
}

.raspinha-card:hover .card-description {
    color: #d1d5db;
}

/* ===== 8. BANNER MELHORADO ===== */
.card-banner {
    position: relative;
    height: 150px;
    overflow: hidden;
    background: linear-gradient(135deg, #2a2a2a, #1a1a1a);
    transition: all 0.4s ease;
}

.banner-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
    filter: brightness(0.9);
}

.raspinha-card:hover .banner-image {
    transform: scale(1.1);
    filter: brightness(1.1);
}

/* ===== 9. IMAGEM VISÍVEL SEM OVERLAY ===== */
.play-overlay {
    display: none; /* Remove o overlay para mostrar a imagem completa */
}

.play-button {
    display: none; /* Remove o botão de play do overlay */
}

/* ===== 10. EFEITOS DE CLIQUE ===== */
.raspinha-card:active {
    transform: translateY(-8px) scale(0.98);
    transition: all 0.1s ease;
}

.play-btn:active {
    transform: translateY(-1px) scale(0.95);
    transition: all 0.1s ease;
}

/* ===== 11. RESPONSIVIDADE MELHORADA ===== */
@media (max-width: 768px) {
    .raspinha-card:hover {
        transform: translateY(-8px) scale(1.01);
    }
    
    .play-btn:hover {
        transform: translateY(-2px) scale(1.03);
    }
    
    .category-badge {
        font-size: 0.7rem;
        padding: 0.2rem 0.6rem;
    }
}

@media (max-width: 480px) {
    .raspinha-card:hover {
        transform: translateY(-6px) scale(1.005);
    }
    
    .play-btn {
        padding: 0.6rem 1.2rem;
        font-size: 0.85rem;
    }
}

/* ===== 12. ANIMAÇÕES DE ENTRADA ===== */
.raspinha-card {
    animation: cardEntrance 0.6s ease-out;
}

@keyframes cardEntrance {
    0% {
        opacity: 0;
        transform: translateY(30px) scale(0.9);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* ===== 13. EFEITO DE BRILHO NO HOVER ===== */
.raspinha-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.6s ease;
    pointer-events: none;
    z-index: 2;
}

.raspinha-card:hover::after {
    left: 100%;
}

/* ===== 14. ESTADOS DE CARREGAMENTO ===== */
.raspinha-card.loading {
    animation: cardLoading 1.5s ease-in-out infinite;
}

@keyframes cardLoading {
    0%, 100% { 
        opacity: 1;
        transform: translateY(0);
    }
    50% { 
        opacity: 0.7;
        transform: translateY(-5px);
    }
}

/* ===== 15. ELEMENTOS DE CONFIANÇA ===== */
.card-trust-elements {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.trust-badge {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.25rem 0.5rem;
    background: rgba(5, 219, 0, 0.1);
    border: 1px solid rgba(5, 219, 0, 0.2);
    border-radius: 8px;
    font-size: 0.7rem;
    color: #05DB00;
    font-weight: 500;
    transition: all 0.3s ease;
    animation: trustBadgeGlow 3s ease-in-out infinite;
}

.trust-badge i {
    font-size: 0.8rem;
    animation: trustIconPulse 2s ease-in-out infinite;
}

.raspinha-card:hover .trust-badge {
    background: rgba(5, 219, 0, 0.15);
    border-color: rgba(5, 219, 0, 0.3);
    transform: translateY(-1px);
}

@keyframes trustBadgeGlow {
    0%, 100% { 
        box-shadow: 0 0 5px rgba(5, 219, 0, 0.1);
    }
    50% { 
        box-shadow: 0 0 10px rgba(5, 219, 0, 0.2);
    }
}

@keyframes trustIconPulse {
    0%, 100% { 
        transform: scale(1);
    }
    50% { 
        transform: scale(1.1);
    }
}

/* ===== 16. BOTÃO JOGAR COM ÍCONE ===== */
.play-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, #05DB00, #05DB00);
    background-size: 200% 200%;
    animation: gradientShift 3s ease infinite;
    color: #ffffff;
    text-decoration: none;
    padding: 0.75rem 1.5rem;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 
        0 4px 15px rgba(5, 219, 0, 0.3),
        0 2px 4px rgba(0, 0, 0, 0.1);
    white-space: nowrap;
    position: relative;
    overflow: hidden;
    transform: scale(1);
}

.play-btn i {
    font-size: 1rem;
    transition: transform 0.3s ease;
}

.play-btn:hover i {
    transform: scale(1.2);
}

/* ===== 17. EFEITO RIPPLE ===== */
@keyframes ripple {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

/* ===== 18. EFEITO DE FOCO PARA ACESSIBILIDADE ===== */
.raspinha-card:focus-within {
    outline: 2px solid #05DB00;
    outline-offset: 2px;
}

.play-btn:focus {
    outline: 2px solid #ffffff;
    outline-offset: 2px;
}

/* ===== 19. OVERRIDES – ESTILO DE REFERÊNCIA (sem alterar conteúdo) ===== */
/* Paleta e tokens simples */
:root {
    --rg-primary: #05DB00;
    --rg-primary-900: #05DB00;
    --rg-amber: #f59e0b;
    --rg-surface: #0f1316;
    --rg-border: rgba(255, 255, 255, 0.08);
    --rg-border-strong: rgba(5, 219, 0, 0.55);
}

/* Card base com gradiente-to-top sutil e borda inferior destacada */
.raspinha-card {
    background:
        linear-gradient(to top, rgba(5, 219, 0, 0.06) 0%, rgba(5, 219, 0, 0.06) 45%, rgba(0,0,0,0) 45%) ,
        linear-gradient(180deg, #1b1d20 0%, #121315 100%);
    border: 1px solid var(--rg-border);
    border-radius: 16px;
    box-shadow: inset 0 -2px 0 rgba(5, 219, 0, 0.35);
}

.raspinha-card:hover {
    box-shadow: inset 0 -2px 0 var(--rg-primary), 0 20px 40px rgba(0,0,0,0.35);
    border-color: rgba(255, 255, 255, 0.12);
}

/* Mantém o mesmo estilo para qualquer categoria, priorizando o visual de referência */
.raspinha-card[data-category="dinheiro"],
.raspinha-card[data-category="produtos"] {
    background:
        linear-gradient(to top, rgba(5, 219, 0, 0.06) 0%, rgba(5, 219, 0, 0.06) 45%, rgba(0,0,0,0) 45%) ,
        linear-gradient(180deg, #1b1d20 0%, #121315 100%);
}

/* Banner com proporção 5/1 como no exemplo */
.card-banner {
    height: auto;
    aspect-ratio: 5 / 1;
    overflow: hidden;
    border-radius: 12px 12px 0 0;
    position: relative;
}

.banner-image {
    width: 100%;
    height: 100%;
    object-fit: contain; /* Mostra a imagem completa sem cortar */
    object-position: center; /* Centraliza a imagem */
    display: block;
    background: linear-gradient(135deg, #1a1a1a, #0a0a0a); /* Fundo escuro para preencher espaços vazios */
    padding: 0.5rem; /* Pequeno padding para não colar nas bordas */
}

/* Título e subtítulo (descrição) no estilo do exemplo */
.card-title {
    font-weight: 700;
}

.card-description {
    color: var(--rg-amber);
    text-transform: uppercase;
    font-weight: 500;
    opacity: 0.9;
    letter-spacing: 0.02em;
    font-size: 0.75rem;
    margin-bottom: 1rem;
}

/* Footer alinhando botão + pill de preço como no exemplo */
.card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Botão principal – verde sólido, micro-interações de active/hover */
.play-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    height: 40px;
    padding: 0 10px;
    background: var(--rg-primary);
    color: #0a0a0a;
    border-radius: 10px;
    box-shadow: 0 2px 6px rgba(5, 219, 0, 0.35);
    transform: translateZ(0) scale(1);
}

.play-btn:hover {
    background: color-mix(in srgb, var(--rg-primary) 90%, #0a0a0a);
    color: #0a0a0a;
}

.play-btn:active {
    transform: scale(0.95);
}

.play-btn i {
    color: #0a0a0a;
}

/* Pill de preço – escuro, com destaque no símbolo R$ em verde */
.card-price {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--rg-border);
    color: #ffffff;
    border-radius: 10px;
    padding: 0.375rem 0.5rem;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    height: 36px;
}

.card-price .price-label { color: var(--rg-primary); }
.card-price .price-value { color: #ffffff; font-weight: 700; font-size: 0.82rem; }

/* Ajustes sutis de ícones e links secundários (se existirem) */
.view-prizes-link { 
    display: inline-flex; align-items: center; gap: 0.375rem; 
    color: #cbd5e1; font-weight: 600; font-size: 0.8rem; opacity: 0.9;
}
.view-prizes-link:hover { color: var(--rg-primary); transform: translateY(-1px); }
