/* ==========================================================================
   FCSM Deck — récompenses : cartes COLORS DUEL, jetons, booster bonus
   ========================================================================== */

/* ---------- Carte COLORS DUEL : cadre arc-en-ciel animé, reflets irisés ---------- */

@property --colors-angle {
    syntax: "<angle>";
    inherits: false;
    initial-value: 0deg;
}

.fcard.is-colors {
    --rc: #b98cff;
    background: conic-gradient(from var(--colors-angle), #ff4d6d, #ffb020, #ffe14d, #4cd964, #34c3ff, #5b6cff, #c04dff, #ff4d6d);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.35), 0 16px 48px -12px rgba(160, 110, 255, 0.6), var(--f-shadow, 0 12px 32px rgba(0, 0, 0, 0.35));
    animation: colors-spin 6s linear infinite;
}
@keyframes colors-spin { to { --colors-angle: 360deg; } }

.fcard.is-colors .fcard__body {
    inset: 1.6cqw;
    border-radius: 0.15cqw;
    background:
        linear-gradient(160deg, rgba(255, 77, 109, 0.14), rgba(52, 195, 255, 0.1) 45%, rgba(192, 77, 255, 0.14)),
        linear-gradient(180deg, #14121f 0%, #0b0a12 100%);
}
.fcard.is-colors .fcard__body::before { inset: 1.2cqw; border-color: rgba(255, 255, 255, 0.28); }
.fcard.is-colors .fcard__name {
    color: #fff;
    text-shadow: 0.25cqw 0.25cqw 0 #ff4d6d, -0.25cqw -0.25cqw 0 #34c3ff;
}
.fcard.is-colors .fcard__stats b { color: #fff; text-shadow: 0 0 3cqw rgba(185, 140, 255, 0.7); }
.fcard.is-colors .fcard__stats { border-top-color: rgba(255, 255, 255, 0.18); }
.fcard.is-colors .fcard__cat { color: #e6dcff; background: rgba(185, 140, 255, 0.16); }
.fcard.is-colors .fcard__rar { color: #fff; background: rgba(255, 255, 255, 0.1); }
.fcard.is-colors .fcard__art { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.3); }
.colors-tag {
    font-style: normal; padding: 0 1.2cqw; border-radius: 0.3cqw;
    color: #120d1c !important;
    background: linear-gradient(90deg, #ff6b88, #ffd24d, #5ee08a, #4cc8ff, #b07cff) !important;
    -webkit-background-clip: border-box !important; background-clip: border-box !important;
}

/* Reflets irisés permanents, qui suivent le pointeur au survol */
.fcard.is-colors .fcard__foil {
    opacity: 0.6;
    background:
        repeating-linear-gradient(115deg, rgba(255, 77, 109, 0.5) 0%, rgba(255, 225, 77, 0.45) 6%, rgba(76, 217, 100, 0.45) 12%, rgba(52, 195, 255, 0.5) 18%, rgba(192, 77, 255, 0.5) 24%, rgba(255, 77, 109, 0.5) 30%),
        repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.1) 0 2px, transparent 2px 6px);
    background-size: 320% 320%, auto;
    background-position: 0% 50%, 0 0;
    mix-blend-mode: color-dodge;
    filter: brightness(0.7) contrast(1.35);
    animation: colors-shimmer 7s ease-in-out infinite alternate;
}
.fcard.is-colors.is-tilting .fcard__foil {
    animation: none; opacity: 0.85;
    background-position: var(--mx) var(--my), 0 0;
}
@keyframes colors-shimmer { to { background-position: 100% 50%, 0 0; } }

.fcard.is-colors.is-locked { animation: none; filter: saturate(0.35) brightness(0.65); }
.fcard.is-colors.is-locked .fcard__foil { animation: none; opacity: 0.2; }

@media (prefers-reduced-motion: reduce) {
    .fcard.is-colors, .fcard.is-colors .fcard__foil { animation: none; }
}

/* Repérage dans la collection, l'admin, la fiche */
.segmented a.segmented__colors { color: #c9a8ff; }
.segmented a.segmented__colors.is-on { background: linear-gradient(90deg, #ff6b88, #ffd24d, #5ee08a, #4cc8ff, #b07cff); color: #120d1c; }
.pill--colors { color: #120d1c !important; background: linear-gradient(90deg, #ff6b88, #ffd24d, #5ee08a, #4cc8ff, #b07cff) !important; }
.badge-colors { background: linear-gradient(90deg, #ff6b88, #ffd24d, #5ee08a, #4cc8ff, #b07cff); color: #120d1c; }

/* ---------- Jetons ---------- */

.token-chip {
    display: inline-flex; align-items: center; gap: 0.35rem; padding: 0.35rem 0.7rem 0.35rem 0.5rem;
    border-radius: 999px; background: rgba(255, 210, 31, 0.1); border: 1px solid rgba(255, 210, 31, 0.3);
    color: var(--yellow); font: 700 0.9rem/1 var(--font-mono, monospace); text-decoration: none; font-variant-numeric: tabular-nums;
}
.token-chip:hover { background: rgba(255, 210, 31, 0.18); color: var(--yellow); }

/* Boutique sur la page Booster */
.shop {
    display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 1.25rem 1.75rem;
    max-width: 920px; margin: clamp(3rem, 7vw, 4.5rem) auto 0; padding: 1.4rem 1.6rem; text-align: left;
    border-radius: 6px; background: var(--surface); border: 1px solid color-mix(in srgb, var(--yellow) 30%, transparent);
}
.shop__coin {
    display: grid; place-items: center; width: 64px; aspect-ratio: 1; border-radius: 50%;
    background: radial-gradient(circle at 35% 30%, #fff2a8, var(--yellow) 45%, #c99a00);
    color: #5a4300; box-shadow: inset 0 -3px 0 rgba(0, 0, 0, 0.2), 0 6px 20px rgba(255, 210, 31, 0.25);
}
.shop__title { margin: 0; font: 800 1.6rem/1 var(--font-display); text-transform: uppercase; }
.shop__desc { margin: 0.45rem 0 0; color: var(--muted); max-width: 52ch; }
.shop__buy { display: grid; justify-items: end; gap: 0.5rem; }
.shop__balance { margin: 0; color: var(--muted); }
.shop__balance b { color: var(--yellow); font: 700 1.2rem/1 var(--font-mono); }
.shop__earn { font-size: 0.9rem; color: var(--yellow); font-weight: 600; }

/* Paquet bonus : la même enveloppe, couleurs inversées */
.pack--bonus .pack__face { background: linear-gradient(170deg, #ffd21f 0%, #f0b800 50%, #b88a00 100%); }
.pack--bonus .pack__stripes { background: repeating-linear-gradient(115deg, transparent 0 34px, rgba(27, 63, 196, 0.9) 34px 46px, transparent 46px 120px); }
.pack--bonus .pack__count { background: var(--ground); color: var(--yellow); }
.pack--bonus .pack__date { color: var(--on-yellow); font-weight: 700; }

/* ---------- Récompense de fin de duel ---------- */

.reward {
    display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 1rem 1.5rem;
    margin-top: 1rem; padding: 1.1rem 1.3rem; border-radius: 6px; background: var(--surface); border: 1px solid var(--line-strong);
}
.reward__coin { width: 52px; font-size: 0; }
.reward__main { margin: 0; font-size: 1.1rem; }
.reward__main b { color: var(--yellow); font-family: var(--font-mono); }
.reward__streak { display: flex; align-items: center; gap: 0.35rem; margin-top: 0.6rem; color: var(--muted); font-size: 0.92rem; }
.streak-pips { display: inline-flex; gap: 4px; margin-right: 0.4rem; }
.streak-pips i { width: 14px; height: 14px; border-radius: 3px; background: var(--surface-2); border: 1px solid var(--line-strong); }
.streak-pips i.is-on { background: linear-gradient(135deg, #ff6b88, #ffd24d, #5ee08a, #4cc8ff, #b07cff); border-color: transparent; }
.reward__colors {
    grid-column: 1 / -1; display: grid; grid-template-columns: 200px minmax(0, 1fr); align-items: center; gap: 1.5rem;
    margin-top: 0.5rem; padding-top: 1.1rem; border-top: 1px solid var(--line);
}
.reward__colors .fcard { --w: 200px; }
.reward__colors h3 { margin: 0; font: 900 clamp(1.8rem, 4vw, 2.6rem)/0.95 var(--font-display); text-transform: uppercase; color: #fff; text-shadow: 2px 2px 0 #ff4d6d, -2px -2px 0 #34c3ff; }
.reward__colors p { margin: 0.6rem 0 0; color: var(--muted); }

@media (max-width: 640px) {
    .shop { grid-template-columns: 1fr; justify-items: start; }
    .shop__buy { justify-items: start; }
    .reward__colors { grid-template-columns: 1fr; justify-items: center; text-align: center; }
}

.arena__wallet { margin-top: 1.5rem; }
.arena__wallet .reward__main a { color: var(--yellow); font-weight: 600; }
