/* =============================================================
   sorare.css — Le Panda Enragé (page /sorare uniquement)
   ============================================================= */

:root {
    --success: #121212; --loader: #000000;
    --shadow: 0 4px 20px rgba(0,0,0,0.03);
    --shadow-hover: 0 12px 40px rgba(0,0,0,0.08);
}
[data-theme="dark"] {
    --success: #ffffff; --loader: #ffffff;
}

/* (Le body{display:flex;flex-direction:column;min-height:100vh} de la
   version d'origine a été supprimé ici : shared.css le fournit déjà
   intégralement — c'était une redéclaration à l'identique, sans aucun
   effet propre.) */

main { padding: 50px 2% 40px; width: 100%; max-width: 1400px; margin: 0 auto; flex: 1; }
.section-container { display: flex; flex-direction: column; align-items: center; width: 100%; }
.section-title { font-family: var(--title-font); font-size: clamp(2.2rem, 6vw, 3.5rem); font-weight: 700; text-align: center; margin-bottom: 20px; }
.section-intro { max-width: 850px; text-align: center; color: var(--sub); font-size: 1.15rem; line-height: 1.7; margin-bottom: 45px; }

.tabs-nav { display: flex; justify-content: center; gap: 12px; margin-bottom: 35px; flex-wrap: wrap; }
.tab-btn {
    background: var(--glass); border: 1px solid var(--border); color: var(--sub);
    padding: 12px 28px; border-radius: 50px; cursor: pointer; transition: 0.3s;
    font-size: 0.75rem; font-weight: 600; text-transform: uppercase; letter-spacing: 1px;
}
.tab-btn.active { background: var(--text); color: var(--bg); border-color: var(--text); }
.tab-pane { display: none; width: 100%; animation: fadeIn 0.5s ease; }
.tab-pane.active { display: block; }

.integration-container { display: flex; flex-direction: column; width: 100%; position: relative; }
.controls-bar { display: flex; justify-content: flex-end; gap: 10px; margin-bottom: 12px; flex-wrap: wrap; }
.control-btn {
    background: var(--glass); color: var(--text); border: 1px solid var(--border);
    padding: 8px 16px; border-radius: 8px; cursor: pointer; font-size: 0.7rem; font-weight: 600;
    display: flex; align-items: center; gap: 8px; transition: 0.3s; text-transform: uppercase; text-decoration: none;
}
.control-btn:hover { background: var(--text); color: var(--bg); }

.iframe-wrapper { position: relative; width: 100%; height: 80vh; border-radius: 16px; overflow: hidden; border: 1px solid var(--border); background: var(--card-bg); }
.tool-iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: none; z-index: 2; opacity: 0; transition: opacity 0.5s ease; }
.tool-iframe.loaded { opacity: 1; }

.iframe-loader {
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    display: flex; flex-direction: column; align-items: center; gap: 15px; color: var(--sub); font-size: 0.8rem;
}
.spinner { width: 30px; height: 30px; border: 2px solid var(--border); border-top-color: var(--loader); border-radius: 50%; animation: spin 0.8s linear infinite; }

.integration-container.fullscreen { position: fixed; inset: 0; width: 100%; height: 100vh; z-index: 10001; background: var(--bg); padding: 15px; }
.integration-container.fullscreen .iframe-wrapper { flex: 1; height: calc(100% - 60px); border-radius: 8px; }

.premium-visual-card {
    background: var(--card-bg); border: 1px solid var(--border); border-radius: 24px;
    padding: 3.5rem 2rem; transition: 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    text-align: center; width: 100%; max-width: 1100px; margin: 0 auto 30px auto;
    box-shadow: var(--shadow); text-decoration: none; color: inherit; display: block;
}
.premium-visual-card:hover { transform: translateY(-8px); border-color: var(--text); box-shadow: var(--shadow-hover); }

.card-icon-box { font-size: 3.5rem; margin-bottom: 20px; }

/* .card-content était utilisé dans le HTML (carte "Mon Club Sorare")
   sans qu'aucune règle ne le cible jamais : le titre s'affichait donc
   en gras par défaut du navigateur, sans la police ni la taille
   prévues ailleurs sur le site. Corrigé ici. */
.card-content h3 { font-family: var(--title-font); font-size: 1.8rem; margin-bottom: 15px; }

/* Remplace le style="font-family:...;font-size:2rem" inline du titre
   de la carte offre (structure différente de index.php : pas de
   wrapper .card-content ici, donc pas de règle .card-content h2/h3
   possible — d'où cette classe dédiée). */
.referral-title { font-family: var(--title-font); font-size: 2rem; margin-bottom: 15px; }

.btn-action {
    display: inline-block; padding: 14px 40px; background: var(--text); color: var(--bg);
    border-radius: 50px; font-weight: 600; font-size: 0.9rem; text-transform: uppercase;
    margin-top: 25px; transition: 0.3s; border: none; cursor: pointer; text-decoration: none;
}
.btn-success { background: var(--success); color: var(--bg); width: 100%; max-width: 350px; }
.btn-success:hover { filter: brightness(1.2); transform: scale(1.02); }

@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
@keyframes spin { to { transform: rotate(360deg); } }

/* Loader en attente (avant 1er clic) — spinner remplacé par une icône */
.iframe-loader.pending .spinner { display: none; }
.iframe-loader.pending::before {
    content: '\f0a9'; /* fa-circle-arrow-right */
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 1.4rem;
    margin-right: 10px;
    color: var(--sub);
}
.iframe-loader.pending { color: var(--sub); font-size: 0.9rem; }

/* ── Notice connexion Sorare (proéminente) ── */
.login-notice {
    display: flex; align-items: center; gap: 10px; justify-content: center;
    background: var(--glass); border: 1px solid var(--border);
    border-radius: 10px; padding: 12px 20px;
    text-align: left; font-size: 0.82rem; color: var(--sub);
    max-width: 850px; width: 100%; margin: -20px auto 35px auto;
}
.login-notice i { color: var(--gold); font-size: 1rem; flex-shrink: 0; }

/* ── Consent gate iframe (bloque le chargement jusqu'au consentement) ── */
.iframe-consent-gate {
    position: absolute; inset: 0; display: flex; flex-direction: column;
    align-items: center; justify-content: center; gap: 14px;
    background: var(--card-bg); text-align: center; padding: 30px; z-index: 5;
}
.iframe-consent-gate p { font-size: 0.82rem; color: var(--sub); max-width: 400px; line-height: 1.6; margin: 0; }
.iframe-consent-gate .gate-title { font-size: 0.95rem; font-weight: 600; color: var(--text); }
.consent-load-btn {
    padding: 10px 24px; background: var(--text); color: var(--bg);
    border: none; border-radius: 50px; font-size: 0.72rem; font-weight: 600;
    text-transform: uppercase; letter-spacing: 1px; cursor: pointer; transition: 0.3s;
}
.consent-load-btn:hover { opacity: 0.8; }
.tool-iframe.consent-hidden { display: none; }

@media (max-width: 768px) {
    .section-title { font-size: 2.2rem; }
    .btn-text { display: none; }
    .controls-bar { justify-content: center; }
}
