
:root{
    --bvpa-blue:#174f8c;
    --bvpa-green:#13856a;
    --bvpa-orange:#ff8a3d;
    --bvpa-ink:#17352e;
    --bvpa-white:#ffffff;
}

*{box-sizing:border-box}

body.dashboard-page{
    min-height:100vh;
    margin:0;
    font-family:Arial,Helvetica,sans-serif;
    background:
        radial-gradient(circle at 12% 10%,rgba(255,255,255,.18),transparent 22%),
        radial-gradient(circle at 88% 18%,rgba(255,255,255,.12),transparent 18%),
        linear-gradient(150deg,var(--bvpa-blue),var(--bvpa-green) 55%,var(--bvpa-orange) 145%);
    color:var(--bvpa-ink);
}

.mobile-game-shell{
    width:min(780px,calc(100% - 24px));
    margin:0 auto;
    padding:22px 0 38px;
}

.game-welcome{
    display:flex;
    justify-content:space-between;
    align-items:flex-start;
    gap:16px;
    color:#fff;
    margin-bottom:18px;
}

.game-welcome h1{
    font-size:clamp(30px,7vw,48px);
    margin:0 0 6px;
    line-height:1;
}

.game-welcome p{
    margin:0;
    color:rgba(255,255,255,.85);
}

.welcome-badge{
    display:inline-block;
    margin:0 0 12px!important;
    padding:7px 12px;
    border-radius:999px;
    background:rgba(255,255,255,.16);
    border:1px solid rgba(255,255,255,.24);
    font-weight:900;
}

.logout-button{
    color:#fff;
    text-decoration:none;
    background:rgba(255,255,255,.14);
    border:1px solid rgba(255,255,255,.24);
    padding:9px 12px;
    border-radius:999px;
    font-size:13px;
    font-weight:800;
}

.game-stats{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:12px;
}

.game-stat{
    background:rgba(255,255,255,.96);
    padding:18px;
    border-radius:22px;
    text-align:center;
    box-shadow:0 14px 35px rgba(7,35,43,.22);
}

.game-stat .icon{
    font-size:34px;
    margin-bottom:5px;
}

.game-stat strong{
    display:block;
    font-size:30px;
    line-height:1;
    color:var(--bvpa-ink);
}

.game-stat small{
    display:block;
    margin-top:6px;
    color:#73827d;
    font-weight:800;
}

.game-play{
    display:flex;
    align-items:center;
    justify-content:center;
    gap:15px;
    width:100%;
    min-height:92px;
    margin:18px 0;
    padding:16px;
    border-radius:25px;
    color:#fff;
    text-decoration:none;
    background:linear-gradient(145deg,#ff9d4c,#f26929);
    box-shadow:0 16px 35px rgba(111,50,18,.32);
    animation:playPulse 2s ease-in-out infinite;
}

.game-play .play-icon{
    font-size:42px;
}

.game-play small{
    display:block;
    opacity:.85;
    font-weight:800;
    letter-spacing:.08em;
}

.game-play strong{
    display:block;
    font-size:23px;
    margin-top:3px;
}

.mystery-preview{
    display:flex;
    align-items:center;
    gap:15px;
    padding:16px;
    margin-bottom:16px;
    border-radius:22px;
    color:#fff;
    background:rgba(255,255,255,.14);
    border:1px solid rgba(255,255,255,.24);
    backdrop-filter:blur(10px);
}

.mystery-preview .mini-bubble{
    width:64px;
    height:64px;
    min-width:64px;
    display:grid;
    place-items:center;
    border-radius:50%;
    font-size:34px;
    background:radial-gradient(circle at 35% 25%,#fff,rgba(126,226,255,.35) 28%,rgba(142,95,255,.3));
    border:2px solid rgba(255,255,255,.55);
    box-shadow:0 0 22px rgba(102,214,255,.38);
}

.mystery-preview strong{
    font-size:19px;
}

.mystery-preview p{
    margin:4px 0 0;
    color:rgba(255,255,255,.82);
}

.game-actions{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:12px;
}

.game-action{
    display:flex;
    flex-direction:column;
    align-items:center;
    gap:7px;
    padding:17px;
    border-radius:19px;
    background:rgba(255,255,255,.15);
    border:1px solid rgba(255,255,255,.25);
    color:#fff;
    text-decoration:none;
    text-align:center;
    font-weight:900;
    backdrop-filter:blur(10px);
}

.game-action span{
    font-size:28px;
}

@keyframes playPulse{
    50%{transform:translateY(-3px) scale(1.015)}
}

@media(min-width:680px){
    .game-stats{grid-template-columns:repeat(4,minmax(0,1fr))}
    .game-actions{grid-template-columns:repeat(4,minmax(0,1fr))}
}

@media(max-width:520px){
    .game-welcome{display:block}
    .logout-button{display:inline-block;margin-top:12px}
}

/* Module Inviter */
.invite-page .mobile-game-shell{max-width:820px}.invite-hero,.share-card,.how-card,.invite-history{background:rgba(255,255,255,.97);border-radius:24px;padding:22px;box-shadow:0 15px 38px rgba(7,35,43,.2);margin-bottom:14px}.invite-hero{display:flex;align-items:center;gap:18px}.invite-reward-icon{width:86px;height:86px;min-width:86px;display:grid;place-items:center;border-radius:25px;background:linear-gradient(145deg,#fff3c7,#ffc75f);font-size:47px}.invite-kicker{font-size:12px;font-weight:900;color:#13856a;letter-spacing:.1em}.invite-hero h2,.share-card h2,.how-card h2,.invite-history h2{margin:5px 0 8px}.invite-hero p,.share-card p{margin:0;color:#6a7a75;line-height:1.55}.invite-stats{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-bottom:14px}.share-row{display:grid;grid-template-columns:1fr auto;gap:9px;margin-top:16px}.share-row .share-input{width:100%;min-width:0;padding:14px;border:2px solid #dce8e3;border-radius:14px;font-size:15px}.share-row button{border:0;border-radius:14px;padding:0 18px;background:#13856a;color:#fff;font-weight:900;cursor:pointer}.copy-status{min-height:22px!important;margin-top:7px!important;color:#13856a!important;font-weight:800}.share-buttons{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:9px;margin-top:8px}.share-button{display:block;padding:13px 9px;border-radius:14px;color:#fff;text-decoration:none;text-align:center;font-weight:900}.share-button.whatsapp{background:#1e9b58}.share-button.telegram{background:#278ac0}.share-button.email{background:#7355a8}.invite-steps{list-style:none;padding:0;margin:15px 0;display:grid;gap:11px}.invite-steps li{display:flex;align-items:center;gap:12px;padding:12px;background:#f3f8f5;border-radius:14px}.invite-steps li>b{width:34px;height:34px;min-width:34px;display:grid;place-items:center;border-radius:10px;background:#13856a;color:#fff}.anti-abuse{margin:0;padding:12px;border-radius:13px;background:#fff7df;color:#795b13;font-size:14px;line-height:1.45}.empty-invites{text-align:center;color:#6a7a75;padding:18px}.empty-invites span{font-size:44px}.invite-list{display:grid;gap:9px}.invite-list article{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:11px;padding:12px;border-radius:15px;background:#f3f8f5}.invite-avatar{width:42px;height:42px;display:grid;place-items:center;border-radius:13px;background:#174f8c;color:#fff;font-weight:900}.invite-list small{display:block;color:#6a7a75;margin-top:3px}.invite-list article>b{color:#13856a}@media(max-width:580px){.invite-hero{align-items:flex-start}.invite-reward-icon{width:65px;height:65px;min-width:65px;font-size:36px}.share-row{grid-template-columns:1fr}.share-row button{padding:13px}.share-buttons{grid-template-columns:1fr}.invite-stats{grid-template-columns:1fr 1fr}}

.invite-dashboard-banner{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:14px;margin:0 0 16px;padding:16px;border-radius:20px;background:linear-gradient(145deg,#fff6cc,#ffd478);color:#4d3b0c;text-decoration:none;box-shadow:0 12px 28px rgba(80,53,4,.2)}.invite-dashboard-banner>span{font-size:36px}.invite-dashboard-banner strong{display:block;font-size:18px}.invite-dashboard-banner small{display:block;margin-top:4px;line-height:1.4}.invite-dashboard-banner>b{white-space:nowrap}@media(max-width:560px){.invite-dashboard-banner{grid-template-columns:auto 1fr}.invite-dashboard-banner>b{grid-column:2}}


/* Nouveau barème : 7 carottes = 1 semaine ; 1 diamant = 14 carottes */
.reward-rule{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:14px;margin:0 0 16px;padding:17px;border-radius:22px;background:rgba(255,255,255,.97);box-shadow:0 14px 35px rgba(7,35,43,.2)}
.reward-rule-icon{width:60px;height:60px;display:grid;place-items:center;border-radius:18px;background:#fff1c8;font-size:32px}
.reward-rule strong{display:block;font-size:18px}.reward-rule p{margin:5px 0;color:#5f706a}.reward-rule small{display:block;color:#7355a8;font-weight:800}
.reward-rule a{padding:11px 15px;border-radius:13px;background:#13856a;color:#fff;text-decoration:none;font-weight:900}
.exchange-message{padding:15px 17px;margin-bottom:14px;border-radius:17px;font-weight:900}.exchange-message.success{background:#dbf5e6;color:#126942}.exchange-message.error{background:#ffe2de;color:#a33126}
.exchange-balance{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-bottom:14px}
.exchange-rule-card{padding:20px;border-radius:22px;background:linear-gradient(145deg,#fff5c8,#ffd878);box-shadow:0 14px 35px rgba(75,51,5,.2);margin-bottom:14px;text-align:center}
.exchange-rule-card span{font-size:12px;font-weight:900;letter-spacing:.1em;color:#755607}.exchange-rule-card h2{margin:8px 0 5px;font-size:27px}.exchange-rule-card p{margin:0}
.exchange-options{display:grid;gap:13px}.exchange-option{padding:21px;border-radius:23px;background:rgba(255,255,255,.97);box-shadow:0 14px 35px rgba(7,35,43,.2);text-align:center}
.exchange-option.diamond{background:linear-gradient(145deg,#f8f5ff,#e9e2ff)}.exchange-option.premium{background:linear-gradient(145deg,#effcff,#d9f6ff)}
.exchange-visual{font-size:28px;font-weight:900}.exchange-visual b{margin:0 8px;color:#13856a}.exchange-option h2{margin:10px 0 6px}.exchange-option p{margin:0 auto 15px;max-width:510px;color:#667772;line-height:1.5}
.exchange-option button{width:100%;max-width:330px;border:0;border-radius:15px;padding:14px 17px;background:#13856a;color:#fff;font-size:16px;font-weight:900;cursor:pointer}
.exchange-option button:disabled{background:#b8c4c0;cursor:not-allowed}.exchange-warning{text-align:center;color:#fff;font-size:14px;font-weight:800}
@media(max-width:620px){.reward-rule{grid-template-columns:auto 1fr}.reward-rule a{grid-column:1/-1;text-align:center}.exchange-balance{grid-template-columns:1fr 1fr}.exchange-balance .game-stat:last-child{grid-column:1/-1}}


/* Échange stratégique + loterie mensuelle */
.lottery-hero{display:grid;grid-template-columns:auto 1fr;gap:16px;align-items:center;margin-bottom:14px;padding:21px;border-radius:24px;background:linear-gradient(145deg,#fff4c7,#ffd877);box-shadow:0 15px 36px rgba(67,44,4,.22)}
.lottery-icon{width:76px;height:76px;display:grid;place-items:center;border-radius:23px;background:rgba(255,255,255,.72);font-size:42px}
.lottery-hero span{font-size:12px;letter-spacing:.1em;font-weight:900;color:#795a08}.lottery-hero h2{margin:5px 0;font-size:27px}.lottery-hero p{margin:0 0 8px;line-height:1.45}.lottery-hero strong{color:#644a05}
.strategy-note{display:grid;grid-template-columns:auto 1fr;gap:14px;padding:18px;margin-bottom:14px;border-radius:22px;background:rgba(255,255,255,.96);box-shadow:0 14px 35px rgba(7,35,43,.2)}
.strategy-note>div:first-child{font-size:38px}.strategy-note h2{margin:0 0 7px}.strategy-note p{margin:5px 0;color:#5d6e68;line-height:1.5}
.reward-levels{padding:19px;margin-bottom:14px;border-radius:23px;background:rgba(255,255,255,.94);box-shadow:0 14px 35px rgba(7,35,43,.2)}
.reward-levels h2{margin:0 0 14px;text-align:center}
.reward-level-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}
.reward-level{padding:14px 8px;text-align:center;border:2px solid #dfe8e4;border-radius:17px;background:#f6f9f8;opacity:.72}
.reward-level.available{border-color:#35a974;background:#e5f7ed;opacity:1}.reward-level span{display:block;font-size:25px}.reward-level strong{display:block;margin:5px 0;font-size:15px}.reward-level p{margin:0;font-weight:900}.reward-level small{display:block;margin:4px 0;color:#6d7d77}.reward-level b{display:inline-block;padding:4px 7px;border-radius:999px;background:#e3e9e6;font-size:11px}.reward-level.available b{background:#13856a;color:#fff}
.exchange-form{display:grid;gap:10px;max-width:360px;margin:0 auto}.exchange-form label{text-align:left;font-weight:900}.exchange-form select{width:100%;padding:13px;border:2px solid #dce6e2;border-radius:14px;background:#fff;font-size:16px}
.lottery-rules{margin-top:14px;padding:20px;border-radius:22px;background:rgba(8,31,42,.78);color:#fff;border:1px solid rgba(255,255,255,.18)}
.lottery-rules h2{margin:0 0 10px}.lottery-rules ul{margin:0;padding-left:21px}.lottery-rules li{margin:7px 0}.lottery-rules p{margin:14px 0 0;color:rgba(255,255,255,.75);font-size:14px;line-height:1.45}
@media(max-width:680px){.reward-level-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.lottery-hero{grid-template-columns:1fr;text-align:center}.lottery-icon{margin:auto}}


/* Module Mes gains */
.gains-wallet{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-bottom:14px}
.wallet-card{display:flex;align-items:center;gap:13px;min-height:110px;padding:17px;border-radius:23px;background:rgba(255,255,255,.97);box-shadow:0 14px 35px rgba(7,35,43,.2)}
.wallet-card.carrot{background:linear-gradient(145deg,#fff8eb,#ffe2b6)}
.wallet-card.diamond{background:linear-gradient(145deg,#f8f5ff,#e7defe)}
.wallet-card.week{background:linear-gradient(145deg,#effcff,#d8f5ff)}
.wallet-icon{width:54px;height:54px;min-width:54px;display:grid;place-items:center;border-radius:17px;background:rgba(255,255,255,.74);font-size:31px}
.wallet-card small,.wallet-card span{display:block}.wallet-card small{font-weight:900;color:#677771}.wallet-card strong{display:block;font-size:31px;line-height:1;margin:4px 0;color:#17352e}.wallet-card span{font-size:12px;font-weight:800;color:#7a8984}
.gains-progress-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:13px;margin-bottom:14px}
.progress-card{padding:20px;border-radius:23px;background:rgba(255,255,255,.97);box-shadow:0 14px 35px rgba(7,35,43,.2)}
.progress-card.lottery{background:linear-gradient(145deg,#fff7cf,#ffe08a)}
.progress-heading{display:flex;justify-content:space-between;align-items:flex-start;gap:10px}.progress-heading span{font-size:11px;letter-spacing:.08em;font-weight:900;color:#13856a}.progress-heading h2{margin:5px 0 0}.progress-heading b{padding:7px 10px;border-radius:999px;background:#eaf5f0;color:#13856a}
.game-progress{height:13px;margin:16px 0 11px;border-radius:999px;background:#e2ebe7;overflow:hidden}.game-progress i{display:block;height:100%;border-radius:inherit;background:linear-gradient(90deg,#22a670,#61d99f);transition:width .5s ease}.game-progress.diamond-progress i{background:linear-gradient(90deg,#7c5ed2,#b496ff)}
.progress-card p{margin:0 0 11px;color:#5f706a;line-height:1.45}.progress-card>a{display:inline-flex;padding:9px 12px;border-radius:12px;background:#13856a;color:#fff;text-decoration:none;font-weight:900}.progress-card>small{display:block;color:#6d580b;font-weight:800;line-height:1.4}
.history-panel{padding:20px;border-radius:24px;background:rgba(255,255,255,.97);box-shadow:0 16px 40px rgba(7,35,43,.23)}
.history-header{display:flex;justify-content:space-between;align-items:flex-start;gap:16px}.history-header span{font-size:11px;letter-spacing:.09em;font-weight:900;color:#13856a}.history-header h2{margin:5px 0 0}.history-stats{text-align:right}.history-stats b,.history-stats small{display:block}.history-stats small{margin-top:4px;color:#74837e}
.history-filters{display:flex;gap:7px;margin:17px 0;overflow-x:auto;padding-bottom:4px}.history-filters button{flex:0 0 auto;border:0;border-radius:999px;padding:9px 13px;background:#edf3f0;color:#52635d;font-weight:900;cursor:pointer}.history-filters button.active{background:#13856a;color:#fff}
.modern-history-list{display:grid;gap:9px}.history-entry{display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:13px;padding:13px;border:1px solid #e1e9e5;border-radius:17px;background:#fff}.history-entry[hidden]{display:none}
.history-entry-icon{width:45px;height:45px;display:grid;place-items:center;border-radius:14px;background:#edf6f2;font-size:25px}.history-entry.diamond .history-entry-icon{background:#eee8ff}.history-entry.week .history-entry-icon{background:#e2f7ff}.history-entry.exchange .history-entry-icon{background:#f1f1f1}
.history-entry-copy strong,.history-entry-copy small{display:block}.history-entry-copy strong{line-height:1.3}.history-entry-copy small{margin-top:4px;color:#83908c}
.history-entry-amount{font-weight:900;text-align:right;white-space:nowrap}.history-entry-amount.positive{color:#13856a}.history-entry-amount.negative{color:#b24b3d}
.empty-gains{text-align:center;padding:34px 12px}.empty-gains>div{font-size:54px}.empty-gains h2{margin:8px 0}.empty-gains p{color:#687973}.empty-gains a{display:inline-flex;margin-top:7px;padding:12px 16px;border-radius:14px;background:#f47b31;color:#fff;text-decoration:none;font-weight:900}
.no-filter-result{text-align:center;padding:25px;color:#73827d;font-weight:800}
.gains-reminder{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:14px;margin-top:14px;padding:18px;border-radius:22px;background:rgba(8,31,42,.78);color:#fff;border:1px solid rgba(255,255,255,.18)}.gains-reminder>div:first-child{font-size:35px}.gains-reminder strong{font-size:18px}.gains-reminder p{margin:5px 0 0;color:rgba(255,255,255,.78);line-height:1.4}.gains-reminder a{padding:11px 14px;border-radius:13px;background:#ffd86e;color:#4c3900;text-decoration:none;font-weight:900}
@media(max-width:720px){.gains-wallet{grid-template-columns:1fr}.gains-progress-grid{grid-template-columns:1fr}.gains-reminder{grid-template-columns:auto 1fr}.gains-reminder a{grid-column:1/-1;text-align:center}.history-header{display:block}.history-stats{text-align:left;margin-top:9px}}
@media(max-width:480px){.history-entry{grid-template-columns:auto minmax(0,1fr)}.history-entry-amount{grid-column:2;text-align:left}.history-panel{padding:15px}}


/* =========================================================
   VERSION FOND CLAIR — meilleure lisibilité
   ========================================================= */
:root{
    --bvpa-page-blue:#dff4ff;
    --bvpa-page-green:#e8f8ef;
    --bvpa-page-orange:#fff0e4;
    --bvpa-dark-text:#183c38;
}

body.dashboard-page{
    background:
        radial-gradient(circle at 12% 8%,rgba(255,255,255,.95),transparent 27%),
        radial-gradient(circle at 88% 12%,rgba(255,220,145,.5),transparent 24%),
        linear-gradient(150deg,var(--bvpa-page-blue),var(--bvpa-page-green) 56%,var(--bvpa-page-orange));
    color:var(--bvpa-dark-text);
}

.game-welcome{
    color:var(--bvpa-dark-text);
}

.game-welcome p{
    color:#4f6f69;
}

.welcome-badge{
    color:#145d51;
    background:rgba(255,255,255,.78);
    border-color:rgba(19,133,106,.18);
    box-shadow:0 7px 18px rgba(29,91,81,.09);
}

.logout-button{
    color:#145d51;
    background:rgba(255,255,255,.82);
    border-color:rgba(19,133,106,.22);
    box-shadow:0 7px 18px rgba(29,91,81,.08);
}

.mystery-preview{
    color:var(--bvpa-dark-text);
    background:rgba(255,255,255,.78);
    border-color:rgba(19,133,106,.16);
    box-shadow:0 12px 28px rgba(38,93,83,.12);
}

.mystery-preview p{
    color:#5a716d;
}

.game-action{
    color:var(--bvpa-dark-text);
    background:rgba(255,255,255,.83);
    border-color:rgba(19,133,106,.15);
    box-shadow:0 10px 24px rgba(38,93,83,.1);
}

.game-action:hover,
.game-action:focus{
    transform:translateY(-2px);
    background:#fff;
    border-color:rgba(19,133,106,.32);
}

.exchange-warning{
    color:#46645e;
}

.lottery-rules{
    color:var(--bvpa-dark-text);
    background:rgba(255,255,255,.88);
    border-color:rgba(19,133,106,.16);
    box-shadow:0 14px 34px rgba(38,93,83,.12);
}

.lottery-rules p{
    color:#617570;
}

.gains-reminder{
    color:var(--bvpa-dark-text);
    background:rgba(255,255,255,.88);
    border-color:rgba(19,133,106,.16);
    box-shadow:0 14px 34px rgba(38,93,83,.12);
}

.gains-reminder p{
    color:#617570;
}

.regulation-banner{
    display:grid;
    grid-template-columns:auto 1fr auto;
    align-items:center;
    gap:14px;
    margin:0 0 14px;
    padding:17px;
    border-radius:21px;
    color:#26443e;
    text-decoration:none;
    background:linear-gradient(145deg,#ffffff,#effaf5);
    border:1px solid rgba(19,133,106,.18);
    box-shadow:0 13px 31px rgba(38,93,83,.13);
}

.regulation-banner-icon{
    width:53px;
    height:53px;
    display:grid;
    place-items:center;
    border-radius:16px;
    background:#e5f5ed;
    font-size:29px;
}

.regulation-banner strong,
.regulation-banner small{
    display:block;
}

.regulation-banner strong{
    font-size:17px;
}

.regulation-banner small{
    margin-top:4px;
    color:#657a75;
    line-height:1.4;
}

.regulation-banner b{
    color:#13856a;
    white-space:nowrap;
}

.regulation-action{
    background:linear-gradient(145deg,#fff9df,#fff1b8);
}

.gains-reminder-links{
    display:grid;
    gap:7px;
}

.gains-reminder-links a{
    display:block;
    padding:10px 13px;
    border-radius:12px;
    background:#ffd86e;
    color:#4c3900;
    text-decoration:none;
    text-align:center;
    font-weight:900;
}

.gains-reminder-links a.secondary{
    background:#e4f4ed;
    color:#145d51;
}

@media(min-width:680px){
    .game-actions{
        grid-template-columns:repeat(5,minmax(0,1fr));
    }
}

@media(max-width:560px){
    .regulation-banner{
        grid-template-columns:auto 1fr;
    }

    .regulation-banner b{
        grid-column:2;
    }
}


/* =========================================================
   MODULE INVITER HARMONISÉ — VERSION CLAIRE
   ========================================================= */
.invite-page .mobile-game-shell{
    max-width:900px;
}

.invite-page .invite-hero,
.invite-page .share-card,
.invite-page .how-card,
.invite-page .invite-history,
.invite-progress-card{
    background:rgba(255,255,255,.9);
    border:1px solid rgba(19,133,106,.14);
    box-shadow:0 14px 34px rgba(38,93,83,.12);
}

.invite-page .invite-hero{
    background:linear-gradient(145deg,#ffffff,#fff6df);
}

.invite-page .invite-hero h2,
.invite-page .share-card h2,
.invite-page .how-card h2,
.invite-page .invite-history h2{
    color:#183c38;
}

.invite-page .invite-hero p,
.invite-page .share-card p,
.invite-page .how-card p,
.invite-page .invite-history p{
    color:#5e746f;
}

.invite-page .invite-reward-icon{
    background:linear-gradient(145deg,#fff8d9,#ffd979);
    box-shadow:inset 0 0 0 1px rgba(167,119,0,.08);
}

.invite-stats{
    gap:12px;
}

.invite-stat-card{
    display:flex;
    align-items:center;
    gap:14px;
    min-height:112px;
    padding:18px;
    border-radius:22px;
    background:linear-gradient(145deg,#ffffff,#eff9f4);
    border:1px solid rgba(19,133,106,.13);
    box-shadow:0 12px 28px rgba(38,93,83,.1);
}

.invite-stat-card.carrot{
    background:linear-gradient(145deg,#fffaf0,#ffe4bb);
}

.invite-stat-icon{
    width:55px;
    height:55px;
    min-width:55px;
    display:grid;
    place-items:center;
    border-radius:17px;
    background:rgba(255,255,255,.78);
    font-size:31px;
}

.invite-stat-card small,
.invite-stat-card span{
    display:block;
}

.invite-stat-card small{
    color:#647974;
    font-weight:900;
}

.invite-stat-card strong{
    display:block;
    margin:4px 0;
    color:#183c38;
    font-size:31px;
    line-height:1;
}

.invite-stat-card span{
    color:#7a8b86;
    font-size:12px;
    font-weight:800;
}

.invite-progress-card{
    margin-bottom:14px;
    padding:20px;
    border-radius:23px;
}

.invite-progress-heading{
    display:flex;
    justify-content:space-between;
    align-items:flex-start;
    gap:12px;
}

.invite-progress-heading span,
.section-kicker{
    display:inline-block;
    color:#13856a;
    font-size:11px;
    font-weight:900;
    letter-spacing:.09em;
}

.invite-progress-heading h2{
    margin:5px 0 0;
    color:#183c38;
    font-size:20px;
}

.invite-progress-heading b{
    padding:7px 10px;
    border-radius:999px;
    background:#e6f5ee;
    color:#13856a;
    white-space:nowrap;
}

.invite-progress-card p{
    margin:0;
    color:#5e746f;
    line-height:1.48;
}

.invite-page .share-input{
    color:#24443e;
    background:#fff;
    border-color:#d7e8e1;
    box-shadow:inset 0 1px 3px rgba(38,93,83,.05);
}

.invite-page .share-row button{
    background:linear-gradient(145deg,#159174,#11745f);
    box-shadow:0 8px 18px rgba(19,133,106,.22);
}

.invite-page .share-row button:hover,
.invite-page .share-row button:focus{
    filter:brightness(1.05);
    transform:translateY(-1px);
}

.invite-page .share-button{
    box-shadow:0 8px 18px rgba(38,93,83,.13);
    transition:transform .18s ease,filter .18s ease;
}

.invite-page .share-button:hover,
.invite-page .share-button:focus{
    transform:translateY(-2px);
    filter:brightness(1.04);
}

.invite-page .invite-steps li{
    background:#f3faf7;
    border:1px solid #e1eee8;
}

.invite-page .invite-steps li>b{
    background:linear-gradient(145deg,#159174,#11745f);
}

.invite-page .anti-abuse{
    background:#fff7df;
    border:1px solid #f5e3aa;
}

.invite-page .invite-list article{
    background:#f7fbf9;
    border:1px solid #e1eee8;
}

.invite-page .invite-avatar{
    background:linear-gradient(145deg,#208e78,#126857);
}

.invite-page .empty-invites{
    padding:28px 16px;
    border-radius:17px;
    background:#f7fbf9;
    border:1px dashed #cfe3da;
}

@media(max-width:580px){
    .invite-stats{
        grid-template-columns:1fr;
    }

    .invite-progress-heading{
        display:block;
    }

    .invite-progress-heading b{
        display:inline-block;
        margin-top:10px;
    }

    .invite-page .invite-hero{
        display:block;
    }

    .invite-page .invite-reward-icon{
        margin-bottom:14px;
    }
}


/* =========================================================
   PÈRE LÉON — MASCOTTE DU MODULE INVITER
   ========================================================= */
.pere-leon-panel{
    position:relative;
    display:grid;
    grid-template-columns:130px minmax(0,1fr);
    gap:20px;
    align-items:center;
    margin-bottom:14px;
    padding:22px;
    overflow:hidden;
    border-radius:25px;
    color:#24433e;
    background:
        radial-gradient(circle at 90% 15%,rgba(255,216,110,.55),transparent 28%),
        linear-gradient(145deg,#ffffff,#edf9f3);
    border:1px solid rgba(19,133,106,.16);
    box-shadow:0 14px 34px rgba(38,93,83,.12);
}

.pere-leon-panel::after{
    content:"";
    position:absolute;
    right:-35px;
    bottom:-45px;
    width:145px;
    height:145px;
    border-radius:50%;
    background:rgba(244,123,49,.09);
}

.pere-leon-avatar{
    position:relative;
    width:118px;
    height:118px;
    display:grid;
    place-items:center;
    border-radius:32px;
    background:linear-gradient(145deg,#fff8dc,#ffd77d);
    box-shadow:
        inset 0 0 0 1px rgba(139,95,0,.08),
        0 11px 26px rgba(115,82,13,.14);
}

.pere-leon-face{
    font-size:67px;
    line-height:1;
    transform:translateY(5px);
}

.pere-leon-hat{
    position:absolute;
    top:-16px;
    left:28px;
    z-index:2;
    font-size:45px;
    transform:rotate(-8deg);
}

.pere-leon-coin{
    position:absolute;
    right:-9px;
    bottom:5px;
    width:42px;
    height:42px;
    display:grid;
    place-items:center;
    border-radius:50%;
    background:#fff7cc;
    box-shadow:0 6px 15px rgba(121,88,15,.2);
    font-size:24px;
}

.pere-leon-message{
    position:relative;
    z-index:1;
}

.pere-leon-message h2{
    margin:6px 0 8px;
    color:#183c38;
    font-size:clamp(21px,4vw,29px);
    line-height:1.16;
}

.pere-leon-message p{
    margin:0;
    max-width:670px;
    color:#59716b;
    line-height:1.55;
}

.pere-leon-tip{
    display:grid;
    grid-template-columns:auto 1fr;
    gap:13px;
    align-items:center;
    margin:0 0 14px;
    padding:15px 17px;
    border-radius:18px;
    background:#fff8df;
    border:1px solid #f0dfa3;
    box-shadow:0 10px 24px rgba(110,83,16,.08);
}

.pere-leon-tip-icon{
    width:46px;
    height:46px;
    display:grid;
    place-items:center;
    border-radius:15px;
    background:#fff;
    font-size:28px;
}

.pere-leon-tip p{
    margin:0;
    color:#67551e;
    line-height:1.45;
}

@media(max-width:620px){
    .pere-leon-panel{
        grid-template-columns:82px minmax(0,1fr);
        gap:14px;
        padding:17px;
    }

    .pere-leon-avatar{
        width:78px;
        height:78px;
        border-radius:23px;
    }

    .pere-leon-face{
        font-size:46px;
    }

    .pere-leon-hat{
        top:-12px;
        left:16px;
        font-size:32px;
    }

    .pere-leon-coin{
        right:-7px;
        bottom:0;
        width:31px;
        height:31px;
        font-size:18px;
    }

    .pere-leon-message h2{
        font-size:19px;
    }
}

@media(max-width:430px){
    .pere-leon-panel{
        grid-template-columns:1fr;
        text-align:center;
    }

    .pere-leon-avatar{
        margin:0 auto;
    }

    .pere-leon-tip{
        align-items:flex-start;
    }
}


.pere-leon-avatar.official{
    width:150px;
    height:150px;
    border-radius:28px;
    overflow:hidden;
    background:#fff;
    padding:6px;
    box-shadow:0 14px 30px rgba(0,0,0,.18);
}
.pere-leon-avatar.official img{
    width:100%;
    height:100%;
    object-fit:cover;
    border-radius:22px;
    display:block;
}
@media(max-width:620px){
.pere-leon-avatar.official{width:95px;height:95px;}
}


/* =========================================================
   PÈRE LÉON — PRÉSENCE SUR LES MODULES PRINCIPAUX
   ========================================================= */
.leon-module-card{
    position:relative;
    display:grid;
    grid-template-columns:145px minmax(0,1fr);
    gap:20px;
    align-items:center;
    margin:0 0 15px;
    padding:21px;
    overflow:hidden;
    border-radius:25px;
    color:#24433e;
    background:
        radial-gradient(circle at 92% 12%,rgba(255,216,110,.52),transparent 27%),
        linear-gradient(145deg,rgba(255,255,255,.98),rgba(238,249,244,.98));
    border:1px solid rgba(19,133,106,.16);
    box-shadow:0 14px 34px rgba(38,93,83,.12);
}

.leon-module-card::after{
    content:"";
    position:absolute;
    right:-50px;
    bottom:-65px;
    width:180px;
    height:180px;
    border-radius:50%;
    background:rgba(244,123,49,.08);
    pointer-events:none;
}

.leon-module-image{
    position:relative;
    z-index:1;
    width:140px;
    height:140px;
    padding:5px;
    overflow:hidden;
    border-radius:28px;
    background:#fff;
    box-shadow:0 13px 28px rgba(26,58,50,.18);
}

.leon-module-image img{
    display:block;
    width:100%;
    height:100%;
    object-fit:cover;
    border-radius:23px;
}

.leon-module-content{
    position:relative;
    z-index:1;
}

.leon-module-content h2{
    margin:6px 0 8px;
    color:#183c38;
    font-size:clamp(21px,4vw,30px);
    line-height:1.15;
}

.leon-module-content p{
    margin:0;
    max-width:690px;
    color:#5a716c;
    line-height:1.55;
}

.leon-module-actions{
    display:flex;
    flex-wrap:wrap;
    gap:9px;
    margin-top:14px;
}

.leon-module-actions a{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    min-height:42px;
    padding:10px 14px;
    border-radius:13px;
    color:#fff;
    background:linear-gradient(145deg,#159174,#11745f);
    text-decoration:none;
    font-size:13px;
    font-weight:900;
    box-shadow:0 8px 18px rgba(19,133,106,.2);
}

.leon-module-actions a.secondary{
    color:#5c4300;
    background:linear-gradient(145deg,#ffe793,#ffd25d);
    box-shadow:0 8px 18px rgba(177,125,10,.16);
}

.leon-dashboard-card{
    background:
        radial-gradient(circle at 92% 12%,rgba(255,216,110,.58),transparent 28%),
        linear-gradient(145deg,#ffffff,#eaf8ff);
}

.leon-gains-card{
    background:
        radial-gradient(circle at 92% 12%,rgba(255,170,90,.25),transparent 28%),
        linear-gradient(145deg,#ffffff,#fff6e9);
}

.leon-exchange-card{
    background:
        radial-gradient(circle at 92% 12%,rgba(180,150,255,.22),transparent 28%),
        linear-gradient(145deg,#ffffff,#f3efff);
}

@media(max-width:650px){
    .leon-module-card{
        grid-template-columns:94px minmax(0,1fr);
        gap:14px;
        padding:17px;
    }

    .leon-module-image{
        width:90px;
        height:90px;
        border-radius:21px;
    }

    .leon-module-image img{
        border-radius:17px;
    }

    .leon-module-content h2{
        font-size:20px;
    }
}

@media(max-width:440px){
    .leon-module-card{
        grid-template-columns:1fr;
        text-align:center;
    }

    .leon-module-image{
        width:116px;
        height:116px;
        margin:0 auto;
    }

    .leon-module-actions{
        justify-content:center;
    }

    .leon-module-actions a{
        flex:1 1 100%;
    }
}


/* =========================================================
   CORRECTIFS MES GAINS + INVITER — v16
   ========================================================= */

/* Empêche tout débordement horizontal dans les modules */
.gains-page .mobile-game-shell,
.invite-page .mobile-game-shell{
    width:min(900px,100%);
    min-width:0;
    overflow:visible;
}

.gains-page section,
.gains-page article,
.invite-page section,
.invite-page article,
.invite-page div{
    min-width:0;
}

/* MES GAINS : grille stable et sans décalage */
.gains-page .gains-wallet{
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:12px;
    width:100%;
    margin:0 0 14px;
}

.gains-page .wallet-card{
    width:100%;
    min-width:0;
}

.gains-page .gains-progress-grid{
    width:100%;
}

.gains-page .history-panel,
.gains-page .gains-reminder,
.gains-page .leon-module-card{
    width:100%;
}

/* INVITER : l'image reste strictement dans sa colonne */
.invite-page .pere-leon-panel{
    display:grid;
    grid-template-columns:116px minmax(0,1fr);
    gap:18px;
    align-items:center;
    width:100%;
    padding:19px;
    overflow:hidden;
}

.invite-page .pere-leon-avatar.official{
    width:110px;
    height:110px;
    max-width:100%;
    margin:0;
    padding:4px;
    justify-self:start;
    flex:none;
}

.invite-page .pere-leon-avatar.official img{
    width:100%;
    height:100%;
    object-fit:cover;
    object-position:center;
}

.invite-page .pere-leon-message{
    width:100%;
    min-width:0;
}

.invite-page .pere-leon-message h2,
.invite-page .pere-leon-message p{
    max-width:100%;
    overflow-wrap:anywhere;
}

@media(max-width:720px){
    .gains-page .gains-wallet{
        grid-template-columns:1fr;
    }

    .gains-page .leon-module-card{
        grid-template-columns:90px minmax(0,1fr);
    }

    .gains-page .leon-module-image{
        width:86px;
        height:86px;
    }
}

@media(max-width:620px){
    .invite-page .pere-leon-panel{
        grid-template-columns:78px minmax(0,1fr);
        gap:12px;
        padding:15px;
        text-align:left;
    }

    .invite-page .pere-leon-avatar.official{
        width:74px;
        height:74px;
        justify-self:start;
        margin:0;
        border-radius:19px;
    }

    .invite-page .pere-leon-avatar.official img{
        border-radius:15px;
    }

    .invite-page .pere-leon-message h2{
        margin-top:4px;
        font-size:18px;
        line-height:1.2;
    }

    .invite-page .pere-leon-message p{
        font-size:14px;
        line-height:1.45;
    }
}

@media(max-width:430px){
    .invite-page .pere-leon-panel{
        grid-template-columns:1fr;
        text-align:center;
    }

    .invite-page .pere-leon-avatar.official{
        width:100px;
        height:100px;
        margin:0 auto;
        justify-self:center;
    }

    .invite-page .pere-leon-message{
        text-align:center;
    }

    .gains-page .leon-module-card{
        grid-template-columns:1fr;
        text-align:center;
    }

    .gains-page .leon-module-image{
        width:105px;
        height:105px;
        margin:0 auto;
    }
}


/* =========================================================
   LECTEUR MUSICAL BVPAQUIZ
   ========================================================= */
.bvpa-music{
    position:fixed;
    right:15px;
    bottom:15px;
    z-index:1000;
    display:flex;
    align-items:center;
    gap:8px;
    padding:7px;
    border-radius:18px;
    background:rgba(255,255,255,.94);
    border:1px solid rgba(19,133,106,.18);
    box-shadow:0 12px 30px rgba(25,70,62,.2);
    backdrop-filter:blur(9px);
}

.bvpa-music-toggle{
    display:flex;
    align-items:center;
    gap:7px;
    min-height:44px;
    padding:9px 12px;
    border:0;
    border-radius:13px;
    color:#17483f;
    background:#e9f7f0;
    cursor:pointer;
    font-weight:900;
}

.bvpa-music.is-playing .bvpa-music-toggle{
    color:#5c4200;
    background:linear-gradient(145deg,#ffe899,#ffd25e);
}

.bvpa-music-icon{
    font-size:20px;
}

.bvpa-music-volume{
    display:flex;
    align-items:center;
    gap:6px;
}

.bvpa-music-volume label{
    position:absolute;
    width:1px;
    height:1px;
    overflow:hidden;
    clip:rect(0,0,0,0);
}

.bvpa-music-volume input{
    width:82px;
    accent-color:#13856a;
    cursor:pointer;
}

@media(max-width:520px){
    .bvpa-music{
        right:9px;
        bottom:9px;
        padding:5px;
    }

    .bvpa-music-label{
        display:none;
    }

    .bvpa-music-toggle{
        width:43px;
        min-height:43px;
        justify-content:center;
        padding:7px;
    }

    .bvpa-music-volume input{
        width:62px;
    }
}

@media(prefers-reduced-motion:reduce){
    .bvpa-music *{
        transition:none !important;
        animation:none !important;
    }
}
