/* ===== Reveal celebration (cartes obtenues, échange, ouverture de pack) ===== */
.reveal-overlay {
    position: fixed; inset: 0; z-index: 10000;
    background:
        radial-gradient(circle at 50% 40%, rgba(255,200,0,0.18) 0%, rgba(255,200,0,0) 50%),
        #050505;
    display: none; align-items: center; justify-content: center;
    padding: 16px; overflow: hidden;
}
.reveal-overlay.show { display: flex; animation: revealFadeIn .4s ease-out; }
@keyframes revealFadeIn { from { opacity: 0; } to { opacity: 1; } }

.reveal-fireworks-canvas { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }

.reveal-stage {
    position: relative; z-index: 2; text-align: center; max-width: 460px; width: 100%;
    display: flex; flex-direction: column; align-items: center; gap: 14px;
}
.reveal-headline {
    font-size: 2rem; font-weight: 800; margin: 0;
    background: linear-gradient(90deg, #FFC800, #FF9500, #FFC800);
    -webkit-background-clip: text; background-clip: text; color: transparent;
    text-shadow: 0 2px 20px rgba(255,200,0,0.4);
    animation: revealHeadlinePop .6s cubic-bezier(.34,1.56,.64,1) both;
}
@keyframes revealHeadlinePop { from { opacity: 0; transform: translateY(-15px) scale(.9);} to { opacity: 1; transform: none; } }
.reveal-sub { color: #d8d8d8; margin: -8px 0 0; font-size: .95rem; min-height: 1.4em; }
.reveal-counter { color: #888; font-size: .8rem; letter-spacing: 2px; text-transform: uppercase; }

/* 3D flipper */
.reveal-flipper {
    width: 240px; aspect-ratio: 2/3;
    perspective: 1200px;
    margin: 4px auto;
}
.reveal-flipper-inner {
    position: relative; width: 100%; height: 100%;
    transform-style: preserve-3d;
    transform: rotateY(0deg);
    transition: transform 1.1s cubic-bezier(.4,0,.2,1);
    box-shadow: 0 25px 60px rgba(0,0,0,0.6), 0 0 50px rgba(255,200,0,0.25);
    border-radius: 16px;
}
.reveal-flipper.flipped .reveal-flipper-inner { transform: rotateY(180deg); }
.reveal-flipper.flipped .reveal-flipper-inner { animation: revealCardWobble 1.2s ease-out 1.1s; }
@keyframes revealCardWobble {
    0%   { transform: rotateY(180deg) scale(1); }
    25%  { transform: rotateY(180deg) scale(1.05); }
    50%  { transform: rotateY(180deg) scale(0.98); }
    100% { transform: rotateY(180deg) scale(1); }
}
.reveal-card-back, .reveal-card-front {
    position: absolute; inset: 0;
    backface-visibility: hidden; -webkit-backface-visibility: hidden;
    border-radius: 16px; overflow: hidden;
}
.reveal-card-back {
    background: linear-gradient(135deg, #FFC800 0%, #FF9500 50%, #b38600 100%);
    display: flex; align-items: center; justify-content: center; flex-direction: column;
    color: #1a1a1a;
    border: 2px solid rgba(0,0,0,0.2);
}
.reveal-card-back-pattern {
    position: absolute; inset: 0;
    background-image:
        repeating-linear-gradient(45deg, rgba(0,0,0,0.08) 0 2px, transparent 2px 14px),
        repeating-linear-gradient(-45deg, rgba(255,255,255,0.08) 0 2px, transparent 2px 14px);
}
.reveal-card-back-logo { font-size: 3.6rem; z-index: 1; margin-bottom: 6px; }
.reveal-card-back-label {
    font-weight: 800; letter-spacing: 3px; font-size: .85rem; text-transform: uppercase; z-index: 1;
}
.reveal-card-front { transform: rotateY(180deg); }
.reveal-card-front .card-front {
    position: relative; width: 100%; height: 100%; border-radius: 16px;
}

.reveal-actions { display: flex; gap: 10px; align-items: center; justify-content: center; flex-wrap: wrap; }
.reveal-btn {
    margin-top: 8px;
    padding: 12px 28px; border: none; border-radius: 100px; cursor: pointer;
    background: linear-gradient(135deg, #FFC800, #FF9500); color: #0a0a0a;
    font-weight: 700; font-size: 1rem;
    box-shadow: 0 8px 20px rgba(255,200,0,0.4);
    transition: transform .15s ease, box-shadow .15s ease, opacity .25s ease;
    opacity: 0; pointer-events: none;
}
.reveal-btn.visible { opacity: 1; pointer-events: auto; }
.reveal-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 26px rgba(255,200,0,0.55); }
.reveal-btn-secondary {
    background: transparent; color: #d8d8d8;
    border: 1px solid rgba(255,255,255,0.18); box-shadow: none;
}
.reveal-btn-secondary:hover { background: rgba(255,255,255,0.06); transform: none; }

@media (max-width: 540px) {
    .reveal-flipper { width: 70vw; max-width: 260px; }
    .reveal-headline { font-size: 1.5rem; }
}
