/* ── Feuille de style du système de Bonus (Speed & Auto Click) ── */

.bonus-container {
    display: flex;
    gap: 12px;
    margin: 8px 0 14px;
    width: 100%;
    justify-content: space-between;
    box-sizing: border-box;
}

.bonus-btn {
    position: relative;
    flex: 1;
    height: 52px;
    border: none;
    border-radius: 14px;
    overflow: hidden;
    cursor: pointer;
    background: transparent;
    padding: 0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    transition: transform 0.15s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    -webkit-tap-highlight-color: transparent;
}

/* Effets tactiles et hover */
@media (hover: hover) and (pointer: fine) {
    .bonus-btn:hover:not(:disabled) {
        transform: translateY(-2px);
    }
}

.bonus-btn:active:not(:disabled),
.bonus-btn.btn-tap {
    transform: scale(0.96) translateY(0);
}

.bonus-btn:disabled {
    cursor: not-allowed;
}

/* Couches de rendu communes */
.bonus-btn__state {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: garetbook, Arial, Helvetica, sans-serif;
    font-size: 0.82rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-radius: 14px;
    box-sizing: border-box;
}

/* Version désactivée / en cooldown (Noir & Blanc) */
.bonus-btn__state--grayscale {
    background: rgba(11, 21, 36, 0.75) !important;
    color: #4b5563 !important;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    filter: grayscale(1);
    z-index: 1;
}

.bonus-btn__state--grayscale .bonus-timer {
    font-size: 0.75rem;
    font-family: monospace;
    background: rgba(0, 0, 0, 0.3);
    padding: 2px 6px;
    border-radius: 4px;
    color: #9ca3af;
}

/* Version colorée active (superposée) */
.bonus-btn__state--color {
    z-index: 2;
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
    clip-path: inset(calc(100% - var(--cooldown-pct, 100%)) 0 0 0);
    box-shadow: inset 0 2px 8px rgba(255, 255, 255, 0.2);
}

/* Gradients spécifiques pour la version couleur */
.bonus-btn--speed .bonus-btn__state--color {
    background: linear-gradient(135deg, #f59e0b 0%, #e11d48 100%);
    --glow-color: rgba(245, 158, 11, 0.4);
}

.bonus-btn--autoclick .bonus-btn__state--color {
    background: linear-gradient(135deg, #06b6d4 0%, #3b82f6 100%);
    --glow-color: rgba(6, 182, 212, 0.4);
}

/* Icônes de bonus */
.bonus-icon {
    font-size: 1.1rem;
    display: inline-block;
    transition: transform 0.3s ease;
}

/* Animation lors de l'activation du bonus (effet actif) */
.bonus-btn--active {
    animation: pulse-glow 1.5s infinite ease-in-out;
}

.bonus-btn--active .bonus-icon {
    animation: spin-pulse 1s infinite linear;
}

@keyframes pulse-glow {
    0% {
        box-shadow: 0 0 8px var(--glow-color), 0 4px 15px rgba(0, 0, 0, 0.3);
        transform: scale(1);
    }
    50% {
        box-shadow: 0 0 20px var(--glow-color), 0 4px 15px rgba(0, 0, 0, 0.3);
        transform: scale(1.02);
    }
    100% {
        box-shadow: 0 0 8px var(--glow-color), 0 4px 15px rgba(0, 0, 0, 0.3);
        transform: scale(1);
    }
}

@keyframes spin-pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}
