/**
 * Page profil public — avatar, pseudo, membre depuis, dernier deck.
 * Mobile-first, conteneur 1150px.
 */

.page-userprofile {
    max-width: 1150px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* ─── Header profil ───────────────────────────────────────────── */

.userprofile-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    padding: 1.5rem 0;
    margin-bottom: 1.5rem;
}

.userprofile-avatar-wrap {
    flex-shrink: 0;
}

.userprofile-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--border);
    display: block;
}

.userprofile-avatar--placeholder {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: var(--accent);
    color: #fff;
    font-size: 2rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 3px solid var(--border);
}

.userprofile-username-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin: 0;
}

.userprofile-username {
    font-family: var(--font-title);
    font-size: 1.6rem;
}

.userprofile-badge-me {
    display: inline-block;
    padding: 0.2rem 0.5rem;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--color-gold);
    background: rgba(255, 213, 79, 0.15);
    border: 1px solid var(--color-gold);
    border-radius: var(--radius);
}

.userprofile-member-since {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* ─── Section deck ─────────────────────────────────────────────── */

.userprofile-deck h2 {
    margin: 0 0 1rem;
    font-size: 1.1rem;
    color: var(--text-muted);
}

.userprofile-no-deck {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.userprofile-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 0.75rem;
    perspective: 1200px;
}

/* Cartes du deck public : titre plus compact + pas de bulle "i" */
.userprofile-cards .card-title {
    font-size: clamp(0.9rem, 1.9vw, 1rem);
}

.userprofile-cards .card-type-driver .card-title-first,
.userprofile-cards .card-type-manager .card-title-first {
    font-size: 0.65em;
}

.userprofile-cards .card-type-driver .card-title-last,
.userprofile-cards .card-type-manager .card-title-last {
    font-size: 1.08em;
}

.userprofile-cards .card-btn-effect {
    display: none;
}

/* ─── Responsive ───────────────────────────────────────────────── */

@media (min-width: 480px) {
    .userprofile-header {
        padding: 2rem 0;
        margin-bottom: 2rem;
    }

    .userprofile-avatar,
    .userprofile-avatar--placeholder {
        width: 96px;
        height: 96px;
    }

    .userprofile-avatar--placeholder {
        font-size: 2.5rem;
    }

    .userprofile-username-wrap .userprofile-username {
        font-size: 1.8rem;
    }

    .userprofile-badge-me {
        font-size: 0.75rem;
    }

    .userprofile-deck h2 {
        font-size: 1.2rem;
    }

    .userprofile-cards {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 1rem;
    }
}

@media (min-width: 768px) {
    .page-userprofile {
        padding: 0 1.5rem;
    }

    .userprofile-header {
        padding: 2.5rem 0;
        margin-bottom: 2.5rem;
    }

    .userprofile-avatar,
    .userprofile-avatar--placeholder {
        width: 112px;
        height: 112px;
    }

    .userprofile-avatar--placeholder {
        font-size: 3rem;
    }

    .userprofile-username-wrap .userprofile-username {
        font-size: 2rem;
    }

    .userprofile-badge-me {
        font-size: 0.8rem;
    }

    .userprofile-deck h2 {
        font-size: 1.3rem;
    }

    .userprofile-cards {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 1rem;
    }
}
