/* ====================================================
   FlexQuiz — Styles front-office (neutres)
   ==================================================== */

/* Les jetons de design sont dans fq-tokens.css (chargé sur tout le site). */


/* ── Wrapper principal ──────────────────────────────── */
.fq-quiz-wrapper {
    font-size: var(--fq-font-size, 17px);
    max-width: 720px;
    margin: 0 auto;
    font-family: var(--fq-font);
    color: var(--fq-dark);
}

/* ── En-tête ────────────────────────────────────────── */
.fq-quiz-header {
    background: linear-gradient(135deg, var(--fq-header-from) 0%, var(--fq-header-to) 100%);
    color: var(--fq-white);
    border-radius: var(--fq-radius) var(--fq-radius) 0 0;
    padding: 24px 28px 20px;
}
.fq-quiz-meta {
    display: flex;
    gap: 8px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}
.fq-difficulty-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.fq-difficulty--beginner     { background: var(--fq-success-soft); color: var(--fq-success-ink); }
.fq-difficulty--intermediate { background: var(--fq-warning-soft); color: #92400E; }
.fq-difficulty--expert       { background: var(--fq-danger-soft); color: var(--fq-danger-ink); }
.fq-difficulty--master       { background: #EDE9FE; color: #5B21B6; }
.fq-gate-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    background: rgba(255,215,0,0.2);
    color: var(--fq-yellow);
    border: 1px solid rgba(255,215,0,0.4);
}
.fq-quiz-title {
    font-size: 22px;
    font-weight: 700;
    margin: 0 0 8px;
    color: var(--fq-white);
}
.fq-quiz-description {
    font-size: 14px;
    color: rgba(255,255,255,0.75);
    margin: 0 0 12px;
}

/* ── Timer ──────────────────────────────────────────── */
.fq-timer {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(255,255,255,0.12);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 20px;
    padding: 5px 14px;
    font-size: 16px;
    font-weight: 700;
    color: var(--fq-white);
    margin-top: 8px;
    transition: background 0.3s;
}
.fq-timer--warning { background: rgba(204,0,0,0.6); animation: fq-pulse 1s infinite; }
@keyframes fq-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.6; }
}

/* ── Barre de progression ───────────────────────────── */
.fq-progress-bar-wrapper {
    height: 6px;
    background: var(--fq-border);
    overflow: hidden;
}
.fq-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--fq-primary), var(--fq-accent));
    transition: width 0.4s ease;
    border-radius: 0 3px 3px 0;
}
.fq-progress-text {
    font-size: 14px;
    color: #888;
    text-align: right;
    padding: 4px 12px;
    background: var(--fq-white);
    border-left: 1px solid var(--fq-border);
    border-right: 1px solid var(--fq-border);
}

/* ── Questions ──────────────────────────────────────── */
.fq-questions-container {
    background: var(--fq-white);
    border: 1px solid var(--fq-border);
    border-top: none;
    border-radius: 0 0 var(--fq-radius) var(--fq-radius);
    overflow: hidden;
}
.fq-question-slide {
    display: none;
    padding: 28px;
    animation: fq-fadein 0.3s ease;
}
.fq-question-slide--active { display: block; }
@keyframes fq-fadein {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}
.fq-question-body { margin-bottom: 20px; }
.fq-question-image {
    text-align: center;
    margin-bottom: 16px;
}
.fq-question-image img {
    max-width: 200px;
    border-radius: 8px;
    border: 2px solid var(--fq-border);
}
.fq-question-text {
    font-size: 17px;
    font-weight: 600;
    color: var(--fq-dark);
    margin-bottom: 20px;
    line-height: 1.5;
}
.fq-question-number {
    color: var(--fq-red);
    margin-right: 6px;
}
.fq-multi-hint {
    font-size: 14px;
    color: var(--fq-blue);
    margin-bottom: 12px;
    font-style: italic;
}

/* ── Réponses ───────────────────────────────────────── */
.fq-answers {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.fq-answer-label {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    border: 2px solid var(--fq-border);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    background: var(--fq-white);
    font-size: 15px;
    color: var(--fq-dark);
}
.fq-answer-label:hover {
    border-color: var(--fq-red);
    background: #FFF5F5;
    transform: translateX(3px);
}
.fq-answer-label.fq-answer--selected {
    border-color: var(--fq-blue);
    background: #EFF6FF;
}
.fq-answer-label.fq-answer--correct {
    border-color: var(--fq-green);
    background: var(--fq-success-soft);
    pointer-events: none;
}
.fq-answer-label.fq-answer--incorrect {
    border-color: var(--fq-error);
    background: var(--fq-danger-soft);
    pointer-events: none;
}
.fq-answer-label.fq-answer--disabled {
    pointer-events: none;
    opacity: 0.7;
}
.fq-answer-input { display: none; }
.fq-answer-marker {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--fq-gray);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
    flex-shrink: 0;
    transition: background 0.2s;
}
.fq-answer--selected  .fq-answer-marker { background: var(--fq-blue);  color: var(--fq-white); }
.fq-answer--correct   .fq-answer-marker { background: var(--fq-green); color: var(--fq-white); }
.fq-answer--incorrect .fq-answer-marker { background: var(--fq-error); color: var(--fq-white); }

/* ── Feedback ───────────────────────────────────────── */
.fq-feedback {
    margin-top: 16px;
    padding: 14px 16px;
    border-radius: 8px;
    font-size: 14px;
    animation: fq-fadein 0.2s ease;
}
.fq-feedback--correct   { background: var(--fq-success-soft); border: 1px solid #A7F3D0; }
.fq-feedback--incorrect { background: var(--fq-danger-soft); border: 1px solid #FECACA; }
.fq-feedback-result {
    font-weight: 700;
    font-size: 15px;
    margin-bottom: 6px;
}
.fq-feedback-explanation { color: #444; line-height: 1.5; }

/* ── Actions ────────────────────────────────────────── */
.fq-question-actions {
    padding: 0 28px 28px;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}
.fq-btn-validate {
    background: var(--fq-red);
    color: var(--fq-white);
    border: none;
    border-radius: 8px;
    padding: 12px 28px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
}
.fq-btn-validate:hover { background: var(--fq-primary-strong); transform: translateY(-1px); }
.fq-btn-validate--next {
    background: var(--fq-blue);
}
.fq-btn-validate--next:hover { background: #1F5F9E; }
.fq-btn-validate--finish {
    background: var(--fq-green);
}
.fq-btn-validate--finish:hover { background: #1E8A4A; }
.fq-btn-validate:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

/* ── Score live ─────────────────────────────────────── */
.fq-live-score {
    text-align: center;
    font-size: 14px;
    color: #777;
    margin-top: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}
.fq-live-score strong { font-size: 18px; color: var(--fq-dark); }

/* ── Résultats ──────────────────────────────────────── */
.fq-results-wrapper {
    background: var(--fq-white);
    border: 1px solid var(--fq-border);
    border-radius: var(--fq-radius);
    padding: 40px 32px;
    text-align: center;
    animation: fq-fadein 0.4s ease;
}
.fq-results-header { margin-bottom: 24px; }
.fq-results-emoji { font-size: 56px; margin-bottom: 12px; }
.fq-results-header h2 { font-size: 26px; color: var(--fq-dark); margin: 0; }

.fq-score-display {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 28px;
    margin-bottom: 20px;
}
.fq-score-circle {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--fq-primary), var(--fq-primary-strong));
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--fq-white);
    box-shadow: var(--fq-shadow);
}
.fq-score-percent { font-size: 28px; font-weight: 800; line-height: 1; }
.fq-score-label   { font-size: 15px; opacity: 0.85; text-transform: uppercase; letter-spacing: 0.5px; }
.fq-score-details { display: flex; flex-direction: column; gap: 12px; text-align: left; }
.fq-score-points, .fq-score-time { display: flex; flex-direction: column; }
.fq-score-points strong, .fq-score-time strong { font-size: 22px; color: var(--fq-dark); }
.fq-score-points span, .fq-score-time span { font-size: 14px; color: #888; }

.fq-result-badge {
    display: inline-block;
    padding: 8px 20px;
    border-radius: 20px;
    font-size: 15px;
    font-weight: 700;
    margin-bottom: 20px;
}
.fq-badge--master       { background: #EDE9FE; color: #5B21B6; }
.fq-badge--expert       { background: var(--fq-danger-soft); color: var(--fq-danger-ink); }
.fq-badge--intermediate { background: var(--fq-warning-soft); color: #92400E; }
.fq-badge--beginner     { background: var(--fq-success-soft); color: var(--fq-success-ink); }
.fq-badge--rookie       { background: var(--fq-gray); color: #555; }

/* Résultat quiz de palier */
.fq-gate-result {
    padding: 16px 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-size: 14px;
}
.fq-gate-result--pass { background: var(--fq-success-soft); border: 1px solid #A7F3D0; color: var(--fq-success-ink); }
.fq-gate-result--fail { background: var(--fq-danger-soft); border: 1px solid #FECACA; color: var(--fq-danger-ink); }
.fq-gate-icon { font-size: 24px; display: block; margin-bottom: 8px; }
.fq-gate-result p { margin: 6px 0 0; }

/* Barre de score */
.fq-score-bar-wrapper {
    height: 8px;
    background: var(--fq-border);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 28px;
}
.fq-score-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--fq-primary), var(--fq-accent));
    border-radius: 4px;
    transition: width 0.8s ease;
}

/* Boutons résultats */
.fq-results-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}
.fq-btn-restart, .fq-btn-home, .fq-btn-login {
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s;
    border: 2px solid transparent;
}
.fq-btn-restart {
    background: var(--fq-red);
    color: var(--fq-white);
    border: none;
}
.fq-btn-restart:hover { background: var(--fq-primary-strong); }
.fq-btn-home {
    background: var(--fq-white);
    color: var(--fq-dark);
    border-color: var(--fq-border);
}
.fq-btn-home:hover { border-color: var(--fq-dark); }
.fq-btn-login {
    background: var(--fq-blue);
    color: var(--fq-white);
}
.fq-btn-login:hover { background: #1F5F9E; color: var(--fq-white); }

/* ── Feedback timeout ──────────────────────────────── */
.fq-feedback--timeout {
    background: #FFF3CD;
    border: 1px solid #FFE083;
}

/* ── Anti-cheat overlay ─────────────────────────────── */
.fq-cheat-overlay {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 32px;
    background: #0a0a1a;
    border-radius: var(--fq-radius);
    text-align: center;
    min-height: 320px;
    animation: fq-fadein 0.4s ease;
}
.fq-missingno-sprite {
    image-rendering: pixelated;
    image-rendering: crisp-edges;
    margin-bottom: 20px;
    animation: fq-glitch 0.8s steps(2) infinite;
}
.fq-missingno-sprite svg {
    width: 128px;
    height: 112px;
}
@keyframes fq-glitch {
    0%   { transform: translate(0,0); filter: hue-rotate(0deg); }
    25%  { transform: translate(-3px, 1px); filter: hue-rotate(90deg); }
    50%  { transform: translate(3px, -1px); filter: hue-rotate(180deg); }
    75%  { transform: translate(-1px, 2px); filter: hue-rotate(270deg); }
    100% { transform: translate(0,0); filter: hue-rotate(360deg); }
}
.fq-cheat-title {
    font-size: 36px;
    font-weight: 900;
    color: #FF00FF;
    letter-spacing: 8px;
    text-shadow: 2px 2px #000, -2px -2px #888;
    margin: 0 0 16px;
    animation: fq-glitch 1.2s steps(3) infinite;
}
.fq-cheat-msg {
    font-size: 16px;
    font-weight: 700;
    color: var(--fq-danger);
    margin: 0 0 8px;
}
.fq-cheat-sub {
    font-size: 15px;
    color: #888;
    margin: 0 0 28px;
    max-width: 360px;
}
.fq-btn-reload {
    background: var(--fq-primary);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 12px 28px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s;
}
.fq-btn-reload:hover { background: var(--fq-primary-strong); }

/* ── Messages d'erreur ──────────────────────────────── */
.fq-error {
    background: var(--fq-danger-soft);
    border: 1px solid #FECACA;
    color: var(--fq-danger-ink);
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 14px;
}

/* ── Grille Answer Set (ex : une grille d'icônes cliquables) ─────────── */
.fq-answers--grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    flex-direction: unset; /* annule le flex-direction: column hérité */
}
.fq-answer-label--type {
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 6px;
    min-height: 80px;
    text-align: center;
    border-radius: 10px;
    border-width: 2px;
    transition: all 0.15s ease;
}
.fq-answer-label--type:hover {
    transform: translateY(-2px);
    border-color: var(--fq-red);
    background: #FFF5F5;
}
.fq-answer-label--type.fq-answer--selected {
    border-color: var(--fq-blue);
    background: #EFF6FF;
    transform: translateY(-2px);
}
.fq-answer-label--type.fq-answer--correct {
    border-color: var(--fq-green);
    background: var(--fq-success-soft);
    transform: none;
}
.fq-answer-label--type.fq-answer--incorrect {
    border-color: var(--fq-error);
    background: var(--fq-danger-soft);
    transform: none;
}
.fq-answer-label--type.fq-answer--disabled {
    opacity: 0.65;
    pointer-events: none;
}
.fq-type-icon {
    width: 36px;
    height: 36px;
    object-fit: contain;
    display: block;
}
.fq-answer-label--type .fq-answer-text {
    font-size: 15px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    line-height: 1.2;
}

/* ── Timer par question ──────────────────────────────── */
.fq-question-timer {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: var(--fq-gray);
    border: 1px solid var(--fq-border);
    border-radius: 16px;
    padding: 4px 12px;
    font-size: 15px;
    font-weight: 600;
    color: var(--fq-dark);
    margin-bottom: 12px;
}
.fq-question-timer .fq-qtimer-display { font-weight: 800; color: var(--fq-red); }
.fq-qtimer--critical { background: var(--fq-danger-soft); border-color: var(--fq-error); animation: fq-pulse 0.6s infinite; }

/* ── Responsive ─────────────────────────────────────── */
@media (max-width: 600px) {
    .fq-quiz-header { padding: 18px; }
    .fq-quiz-title  { font-size: 18px; }
    .fq-question-slide { padding: 18px; }
    .fq-question-actions { padding: 0 18px 18px; }
    .fq-question-text { font-size: 15px; }
    .fq-answer-label { font-size: 14px; padding: 12px 14px; }
    .fq-score-display { flex-direction: column; }
    .fq-results-wrapper { padding: 28px 18px; }
    .fq-answers--grid { grid-template-columns: repeat(3, 1fr); gap: 6px; }
    .fq-answer-label--type { min-height: 70px; padding: 8px 4px; }
    .fq-type-icon { width: 28px; height: 28px; }
    .fq-answer-label--type .fq-answer-text { font-size: 14px; }
}

/* ── Quiz verrouillé ────────────────────────────────── */
.fq-quiz-locked {
    max-width: 720px;
    margin: 0 auto;
    padding: 48px 32px;
    text-align: center;
    background: var(--fq-white);
    border: 2px solid var(--fq-border);
    border-radius: var(--fq-radius);
    font-family: var(--fq-font);
    color: var(--fq-dark);
}
.fq-locked-icon {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}
.fq-locked-icon svg {
    width: 56px;
    height: 56px;
    color: #9CA3AF;
}
.fq-locked-title {
    font-size: 22px;
    font-weight: 800;
    color: var(--fq-dark);
    margin: 0 0 8px;
}
.fq-locked-subtitle {
    font-size: 15px;
    color: var(--fq-ink-soft);
    margin: 0 0 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
}
.fq-locked-message {
    font-size: 15px;
    color: #374151;
    max-width: 420px;
    margin: 0 auto 12px;
    line-height: 1.6;
}
.fq-locked-hint {
    font-size: 15px;
    color: #9CA3AF;
    margin: 0 auto 24px;
}
@media (max-width: 600px) {
    .fq-quiz-locked { padding: 36px 20px; }
    .fq-locked-title { font-size: 18px; }
}

/* ── Bannière de déverrouillage ─────────────────────── */
.fq-unlock-banner {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    background: var(--fq-success-soft);
    border: 1px solid #6EE7B7;
    border-radius: 8px;
    padding: 14px 18px;
    margin: 16px 0;
    text-align: left;
}
.fq-unlock-banner--theme {
    background: #EDE9FE;
    border-color: #C4B5FD;
}
.fq-unlock-icon {
    flex-shrink: 0;
    color: #059669;
}
.fq-unlock-banner--theme .fq-unlock-icon { color: #7C3AED; }
.fq-unlock-banner strong {
    display: block;
    font-size: 15px;
    color: var(--fq-success-ink);
    margin-bottom: 2px;
}
.fq-unlock-banner--theme strong { color: #4C1D95; }
.fq-unlock-banner p {
    font-size: 15px;
    color: #374151;
    margin: 2px 0 0;
}

/* ── Vue progression thèmes ([fq_themes]) ──────────── */
.fq-themes-wrapper {
    max-width: 720px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 20px;
    font-family: var(--fq-font);
}
.fq-theme-card {
    background: var(--fq-white);
    border: 1px solid var(--fq-border);
    border-radius: var(--fq-radius);
    overflow: hidden;
}
.fq-theme-header {
    background: linear-gradient(135deg, var(--fq-header-from) 0%, var(--fq-header-to) 100%);
    color: var(--fq-white);
    padding: 16px 20px;
}
.fq-theme-name {
    font-size: 18px;
    font-weight: 800;
    margin: 0 0 4px;
}
.fq-theme-description {
    font-size: 15px;
    opacity: 0.8;
    margin: 0;
}
.fq-theme-quizzes {
    display: flex;
    flex-direction: column;
}
.fq-theme-quiz-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
    border-bottom: 1px solid var(--fq-border);
    transition: background 0.15s;
}
.fq-theme-quiz-item:last-child { border-bottom: none; }
.fq-theme-quiz--open { background: var(--fq-white); }
.fq-theme-quiz--locked { background: #F9FAFB; opacity: 0.8; }
.fq-theme-quiz--gate { border-left: 3px solid #7C3AED; }
.fq-theme-quiz-icon {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.fq-theme-quiz--open .fq-theme-quiz-icon svg { color: var(--fq-green); }
.fq-theme-quiz--locked .fq-theme-quiz-icon svg { color: #9CA3AF; }
.fq-theme-quiz-icon svg { width: 22px; height: 22px; }
.fq-theme-quiz-info {
    flex: 1;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}
.fq-theme-quiz-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--fq-dark);
    width: 100%;
}
.fq-gate-badge-sm {
    display: inline-block;
    padding: 2px 8px;
    background: #EDE9FE;
    color: #5B21B6;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 700;
}
.fq-theme-quiz-cta {
    flex-shrink: 0;
    margin-left: auto;
}
.fq-theme-quiz-cta--locked {
    font-size: 14px;
    color: #9CA3AF;
    font-weight: 600;
    cursor: not-allowed;
}
.fq-themes-guest-hint {
    text-align: center;
    font-size: 14px;
    color: var(--fq-ink-soft);
    padding: 16px;
    background: var(--fq-gray);
    border-radius: var(--fq-radius);
}
.fq-themes-guest-hint a { color: var(--fq-blue); text-decoration: underline; }
@media (max-width: 600px) {
    .fq-theme-quiz-item { padding: 12px 14px; gap: 10px; }
    .fq-theme-quiz-title { font-size: 15px; }
}

/* ── Coming soon (Phase B shortcodes) ──────────────── */
.fq-coming-soon {
    max-width: 720px;
    margin: 0 auto;
    padding: 40px 24px;
    text-align: center;
    background: var(--fq-gray);
    border: 1px dashed var(--fq-border);
    border-radius: var(--fq-radius);
    font-family: var(--fq-font);
}
.fq-coming-soon__title {
    font-size: 17px;
    font-weight: 700;
    color: var(--fq-dark);
    margin: 0 0 6px;
}
.fq-coming-soon__sub {
    font-size: 14px;
    color: var(--fq-ink-soft);
    margin: 0;
}

.fq-theme-quiz-cta--no-page {
    font-size: 15px;
    color: #F59E0B;
    font-weight: 600;
    cursor: help;
    border-bottom: 1px dashed #F59E0B;
}

/* ════════════════════════════════════════════════════════════════════════
   Profil joueur  [fq_profile]
   ════════════════════════════════════════════════════════════════════════ */
.fq-profile { max-width: 760px; margin: 0 auto; }
.fq-profile--guest { text-align: center; padding: 2rem 1rem; }
.fq-profile__header {
    display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
    gap: .75rem; padding-bottom: 1rem; border-bottom: 2px solid #eee; margin-bottom: 1.25rem;
}
.fq-profile__name { margin: 0; font-size: 1.55em; }
.fq-profile__level { display: flex; align-items: center; gap: .6rem; }
.fq-profile__level-badge {
    background: #6366F1; color: #fff; padding: .25rem .7rem; border-radius: 999px;
    font-weight: 700; font-size: .85em;
}
.fq-profile__xp { color: #555; font-weight: 600; }
.fq-profile__stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: .75rem; margin-bottom: 1.5rem; }
.fq-stat {
    background: #f7f7fb; border-radius: 12px; padding: 1rem .5rem; text-align: center;
}
.fq-stat__value { display: block; font-size: 1.65em; font-weight: 800; color: #4338CA; }
.fq-stat__label { display: block; font-size: .8em; color: #666; margin-top: .2em; }
.fq-profile__section-title { font-size: 1.1em; margin: 1.55em 0 .6em; }
.fq-profile__themes { list-style: none; padding: 0; margin: 0; }
.fq-profile__theme {
    display: flex; align-items: center; gap: .6rem; padding: .5rem .25rem;
    border-bottom: 1px solid #f0f0f0;
}
.fq-profile__theme-name { flex: 1; font-weight: 600; }
.fq-profile__theme-status { font-size: .78em; padding: .15em .55em; border-radius: 999px; background: #eee; color: #555; }
.fq-status--completed { background: #DCFCE7; color: #166534; }
.fq-status--in_progress { background: #FEF9C3; color: #854D0E; }
.fq-profile__theme-score { font-weight: 700; color: #4338CA; min-width: 3rem; text-align: right; }
.fq-profile__history { width: 100%; border-collapse: collapse; margin-top: .4rem; }
.fq-profile__history th, .fq-profile__history td {
    text-align: left; padding: .5em .4em; border-bottom: 1px solid #f0f0f0; font-size: .9em;
}
.fq-result-pass { color: #166534; font-weight: 700; }
.fq-result-fail { color: #9CA3AF; }
.fq-profile__empty, .fq-leaderboard__empty { color: #777; font-style: italic; padding: 1rem 0; }

/* ════════════════════════════════════════════════════════════════════════
   Classement  [fq_leaderboard]
   ════════════════════════════════════════════════════════════════════════ */
.fq-leaderboard { max-width: 640px; margin: 0 auto; }
.fq-leaderboard__title { font-size: 1.45em; margin-bottom: .8em; }
.fq-leaderboard__table { width: 100%; border-collapse: collapse; }
.fq-leaderboard__table th, .fq-leaderboard__table td {
    padding: .55rem .5rem; border-bottom: 1px solid #eee; text-align: left;
}
.fq-leaderboard__table th { font-size: .8em; text-transform: uppercase; letter-spacing: .03em; color: #888; }
.fq-lb-rank { width: 2.5rem; font-weight: 700; }
.fq-lb-points, .fq-lb-passed { text-align: right; font-weight: 700; color: #4338CA; }
.fq-lb-row--me { background: #EEF2FF; }
.fq-lb-you { color: #6366F1; font-size: .8em; margin-left: .3em; }
