/* ==========================================================================
   GO-LATIN 2.0 — JUGADORES (J1: catálogo /jugadoresfc; J2: perfil /jugador/{id})
   Solo ecosistema FC. Clases de página .gl-jg-* bajo [data-gl="fc"].

   KIT DE CARTA FIFA: reproduce la base de allplayers.css/jugadoresfc.css sin cargarlas
   (esas hojas redefinen :root y reglas globales). Todo va dentro de :where(...) para
   limitarlo al ecosistema FC SIN subir la especificidad: así las 15 hojas de rareza
   ([data-rarity="X"] .card-root, .fx-*, ...) siguen ganando exactamente igual que hoy.
   Las clases internas de la carta se conservan porque son el contrato de esas hojas.
   ========================================================================== */

/* ---------- Kit de carta: contenedor ---------- */
:where([data-gl="fc"]) .gl-jg-card-shell {
    --fc-border: rgba(255, 255, 255, 0.1);
    --fc-accent: #31ed8c;
    --fc-text-muted: #b0b3b8;
    position: relative;
    min-width: 0;
}

:where([data-gl="fc"] .gl-jg-card-shell) .fn-item-container {
    position: relative;
    width: 100%;
    max-width: 270px;
    margin: 0 auto;
    transition: transform 0.22s ease, filter 0.22s ease;
}

:where([data-gl="fc"] .gl-jg-card-shell) .fn-rarity-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    z-index: 0;
    width: 120%;
    height: 110%;
    background: radial-gradient(ellipse at center, var(--glow-color) 0%, transparent 60%);
    opacity: 0.35;
    pointer-events: none;
    transform: translate(-50%, -50%);
}

:where([data-gl="fc"]) .gl-jg-card {
    position: relative;
    z-index: 1;
    display: block;
    width: 100%;
    aspect-ratio: 2 / 3;
    color: inherit;
    text-decoration: none;
    cursor: pointer;
    perspective: 1000px;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

:where([data-gl="fc"]) .gl-jg-card:focus-visible {
    outline: 2px solid var(--gl-cyan, #00e5ff);
    outline-offset: 4px;
    border-radius: 10px;
}

/* ---------- Kit de carta: capas base (misma especificidad que allplayers.css) ---------- */
:where([data-gl="fc"] .gl-jg-card-shell) .card-root {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    border: 1px solid var(--fc-border);
    border-radius: 8px;
    background-color: #070a12;
    box-shadow: 0 15px 35px -5px rgba(0, 0, 0, 0.8);
    transform: rotateX(var(--rot-x, 0deg)) rotateY(var(--rot-y, 0deg)) scale3d(1, 1, 1) !important;
    transition: transform 0.15s ease-out, box-shadow 0.3s ease-out, border-color 0.3s !important;
    will-change: transform;
}

:where([data-gl="fc"] .gl-jg-card-shell) .card-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
    background: linear-gradient(180deg, #2a2d35 0%, #16181d 100%);
    background-position: center;
    background-size: cover !important;
}

:where([data-gl="fc"] .gl-jg-card-shell) .card-overlay {
    position: absolute;
    inset: 0;
    z-index: 15 !important;
    background-position: calc(var(--pointer-x, 50%) * 2.5) calc(var(--pointer-y, 50%) * 2.5) !important;
    background-size: 250% 250% !important;
    mix-blend-mode: color-dodge !important;
    opacity: var(--opacity, 0) !important;
    pointer-events: none;
    transition: opacity 0.3s ease !important;
}

:where([data-gl="fc"] .gl-jg-card-shell) .card-player-img {
    position: absolute;
    top: 10%;
    left: 50%;
    z-index: 2;
    width: 80%;
    height: 45%;
    object-fit: contain;
    filter: drop-shadow(0 5px 10px rgba(0, 0, 0, 0.5));
    transform: translateX(-50%);
    transition: transform 0.3s ease;
}

:where([data-gl="fc"] .gl-jg-card-shell) .card-rating-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 30;
    display: grid;
    justify-items: center;
    gap: 0.2rem;
}

:where([data-gl="fc"] .gl-jg-card-shell) .rating-pos {
    display: block;
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
}

:where([data-gl="fc"] .gl-jg-card-shell) .card-icons {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 30;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

:where([data-gl="fc"] .gl-jg-card-shell) .card-icon-img {
    width: 24px;
    height: 24px;
    object-fit: contain;
    filter: drop-shadow(0 2px 2px rgba(0, 0, 0, 0.8));
}

:where([data-gl="fc"] .gl-jg-card-shell) .card-info {
    position: absolute;
    bottom: 0;
    left: 0;
    z-index: 30;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    width: 100%;
    height: 36%;
    padding: 14px;
    background: linear-gradient(0deg, rgba(5, 5, 8, 0.98) 10%, rgba(5, 5, 8, 0.92) 74%, transparent 100%);
    transition: height 0.24s ease, padding 0.24s ease;
}

:where([data-gl="fc"] .gl-jg-card-shell) .card-name {
    margin-bottom: 0.2rem;
    overflow: hidden;
    color: #fff;
    font-family: 'Poppins', sans-serif;
    font-size: 1.05rem;
    font-weight: 900;
    letter-spacing: 0.5px;
    text-align: center;
    text-overflow: ellipsis;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8);
    text-transform: uppercase;
    white-space: nowrap;
}

:where([data-gl="fc"] .gl-jg-card-shell) .card-stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5px 15px;
    width: 100%;
    padding-top: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

:where([data-gl="fc"] .gl-jg-card-shell) .card-stat-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.68rem;
}

:where([data-gl="fc"] .gl-jg-card-shell) .stat-lbl {
    color: var(--fc-text-muted);
    font-weight: 500;
    text-transform: uppercase;
}

:where([data-gl="fc"] .gl-jg-card-shell) .stat-val {
    color: #fff;
    font-weight: 700;
}

:where([data-gl="fc"] .gl-jg-card-shell) .stat-val.is-green { color: #21e985; }
:where([data-gl="fc"] .gl-jg-card-shell) .stat-val.is-cyan { color: #0dcaf0; }
:where([data-gl="fc"] .gl-jg-card-shell) .stat-val.is-yellow { color: #fcee0a; }
:where([data-gl="fc"] .gl-jg-card-shell) .stat-val.is-red { color: #ff4d6d; }

:where([data-gl="fc"] .gl-jg-card-shell) .fut-market-value {
    margin-top: 0.45rem;
    color: #fcee0a;
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-align: center;
    text-shadow: 0 0 14px rgba(252, 238, 10, 0.35);
}

:where([data-gl="fc"] .gl-jg-card-shell) .gl-jg-card__footer {
    overflow: hidden;
    color: #9ba8c5;
    font-size: 0.64rem;
    font-weight: 900;
    text-align: center;
    text-overflow: ellipsis;
    text-transform: uppercase;
    white-space: nowrap;
}

:where([data-gl="fc"] .gl-jg-card-shell, [data-gl="fc"] .pj-player-panel) .fx-layer {
    position: absolute;
    inset: 0;
    z-index: 20;
    border-radius: 8px;
    mix-blend-mode: screen;
    opacity: var(--opacity, 0) !important;
    pointer-events: none;
    transition: opacity 0.3s ease !important;
}

:where([data-gl="fc"] .gl-jg-card-shell) .card-border {
    position: absolute;
    inset: 0;
    z-index: 50;
    border: 2px solid rgba(255, 255, 255, 0.5);
    border-radius: 8px;
    opacity: calc(var(--opacity, 0) * 0.6);
    pointer-events: none;
    transition: opacity 0.3s;
}

/* Nivel por valor de mercado (ICON, GOAT, ELITE, PRO, ROOKIE, LOSER) */
:where([data-gl="fc"] .gl-jg-card-shell) .gl-jg-card__tier {
    --tier-rgb: 168, 178, 198;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 56px;
    padding: 0.34rem 0.5rem;
    border: 1px solid rgba(var(--tier-rgb), 0.62);
    border-radius: 8px;
    background:
        linear-gradient(135deg, rgba(var(--tier-rgb), 0.24), rgba(2, 7, 16, 0.76)),
        radial-gradient(circle at 0 0, rgba(var(--tier-rgb), 0.28), transparent 52%);
    color: #fff;
    font-size: 0.72rem;
    font-weight: 900;
    line-height: 1;
    text-transform: uppercase;
    box-shadow: 0 0 16px rgba(var(--tier-rgb), 0.24), inset 0 0 10px rgba(255, 255, 255, 0.045);
}

:where([data-gl="fc"] .gl-jg-card-shell) .gl-jg-tier--icon { --tier-rgb: 252, 238, 10; }
:where([data-gl="fc"] .gl-jg-card-shell) .gl-jg-tier--goat { --tier-rgb: 255, 255, 255; }
:where([data-gl="fc"] .gl-jg-card-shell) .gl-jg-tier--elite { --tier-rgb: 0, 229, 255; }
:where([data-gl="fc"] .gl-jg-card-shell) .gl-jg-tier--pro { --tier-rgb: 255, 99, 31; }
:where([data-gl="fc"] .gl-jg-card-shell) .gl-jg-tier--rookie { --tier-rgb: 33, 255, 134; }
:where([data-gl="fc"] .gl-jg-card-shell) .gl-jg-tier--loser { --tier-rgb: 168, 178, 198; }

/* ---------- Kit de carta: rarezas base que vivían en allplayers.css ---------- */
:where([data-gl="fc"]) [data-rarity="Common"] .card-root { border-color: #64748b; }
:where([data-gl="fc"]) [data-rarity="Common"] .card-bg { background-image: url("https://img.freepik.com/foto-gratis/textura-fondo-gris-oscuro_1253-15.jpg"); background-size: cover; }
:where([data-gl="fc"]) [data-rarity="Bronze"] .card-root { border-color: #7c2d12; }
:where([data-gl="fc"]) [data-rarity="Bronze"] .card-bg { background-image: url('../../images/Cards/bronce.png'); background-size: cover; }
:where([data-gl="fc"]) [data-rarity="Silver"] .card-root { border-color: #94a3b8; }
:where([data-gl="fc"]) [data-rarity="Silver"] .card-bg { background-image: url('../../images/Cards/plata.png'); background-size: cover; }
:where([data-gl="fc"]) [data-rarity="Gold"] .card-root { border-color: #ca8a04; }
:where([data-gl="fc"]) [data-rarity="Gold"] .card-bg { background-image: url('../../images/Cards/oro.png'); background-size: cover; }
:where([data-gl="fc"]) [data-rarity="Rare"] .card-root { border-color: #06b6d4; }
:where([data-gl="fc"]) [data-rarity="Rare"] .card-bg { background-image: url('../../images/Cards/rare.png'); background-size: cover; }
:where([data-gl="fc"]) [data-rarity="TimeWarp"] .card-root { border-color: #a855f7; }
:where([data-gl="fc"]) [data-rarity="TimeWarp"] .card-bg { background-image: url('../../images/Cards/TimeWarp.png'); background-size: cover; }
:where([data-gl="fc"]) [data-rarity="TOTW"] .card-root { border-color: #ca8a04; background: #000; }
:where([data-gl="fc"]) [data-rarity="TOTW"] .card-bg { background-image: url('../../images/Cards/towt.png'); background-size: cover; }

:where([data-gl="fc"]) [data-rarity="Common"] .fx-silver { display: block; mix-blend-mode: overlay; opacity: calc(var(--opacity, 0) * 0.5); }
:where([data-gl="fc"]) [data-rarity="Bronze"] .fx-inferno { display: block; mix-blend-mode: color-dodge; background: repeating-linear-gradient(calc(var(--pointer-num-x) * 3deg), transparent, rgba(255, 100, 0, 0.4) 10px, transparent 20px), radial-gradient(circle at var(--pointer-x) var(--pointer-y), rgba(255, 150, 0, 0.6), transparent 50%); }
:where([data-gl="fc"]) [data-rarity="Silver"] .fx-silver { display: block; mix-blend-mode: hard-light; background: linear-gradient(160deg, transparent 40%, rgba(255, 255, 255, 0.4) 45%, rgba(255, 255, 255, 0.9) 50%, rgba(255, 255, 255, 0.4) 55%, transparent 60%); background-size: 300% 300%; background-position: var(--pointer-x) var(--pointer-y); }
:where([data-gl="fc"]) [data-rarity="Gold"] .fx-gold { display: block; mix-blend-mode: overlay; background: repeating-linear-gradient(calc(var(--pointer-num-x) * 3deg), transparent, rgba(255, 215, 0, 0.4) 10px, transparent 20px), radial-gradient(circle at var(--pointer-x) var(--pointer-y), rgba(255, 215, 0, 0.6), transparent 50%); }
:where([data-gl="fc"]) [data-rarity="Rare"] .fx-water { display: block; mix-blend-mode: overlay; background: repeating-radial-gradient(circle at var(--pointer-x) var(--pointer-y), rgba(0, 255, 255, 0.2) 0%, rgba(0, 100, 255, 0.3) 5%, transparent 10%, rgba(0, 255, 255, 0.1) 15%); }
:where([data-gl="fc"]) [data-rarity="TimeWarp"] .fx-bubble { display: block; mix-blend-mode: screen; background: radial-gradient(circle at var(--pointer-x) var(--pointer-y), rgba(139, 92, 246, 0.7), transparent 35%), radial-gradient(circle at calc(100% - var(--pointer-x)) calc(100% - var(--pointer-y)), rgba(76, 29, 149, 0.7), transparent 35%); }
:where([data-gl="fc"]) [data-rarity="TOTW"] .fx-rainbow { display: block; mix-blend-mode: color-dodge; background: linear-gradient(135deg, #ff9a9e 0%, #fecfef 20%, #a18cd1 40%, #fbc2eb 60%, #8fd3f4 80%, #ff9a9e 100%); background-size: 300% 300%; background-position: var(--pointer-x) var(--pointer-y); filter: brightness(1.1) contrast(1.1); opacity: calc(var(--opacity, 0) * 0.9); }
:where([data-gl="fc"]) [data-rarity="TOTW"] .card-border { border-color: #facc15; }

/* ---------- Kit de carta: variante de catálogo (datos al pasar el mouse) ---------- */
:where([data-gl="fc"]) .gl-jg-card-shell--grid .gl-jg-card__stats {
    max-height: 0;
    overflow: hidden;
    padding-top: 0;
    border-top-color: transparent;
    opacity: 0;
    transform: translateY(8px);
    transition: max-height 0.24s ease, opacity 0.24s ease, transform 0.24s ease, padding 0.24s ease;
}

/* Nombre, valor y pie nunca se comprimen (en cartas pequeñas se recortaban) */
:where([data-gl="fc"] .gl-jg-card-shell) :is(.card-name, .fut-market-value, .gl-jg-card__footer) {
    flex-shrink: 0;
}

:where([data-gl="fc"]) .gl-jg-card-shell--grid:hover .fn-item-container,
:where([data-gl="fc"]) .gl-jg-card-shell--grid:focus-within .fn-item-container {
    filter: drop-shadow(0 0 22px rgba(0, 229, 255, 0.2));
    transform: translateY(-8px);
}

:where([data-gl="fc"]) .gl-jg-card-shell--grid:hover {
    z-index: 30;
}

:where([data-gl="fc"]) .gl-jg-card-shell--grid .gl-jg-card:hover .card-info,
:where([data-gl="fc"]) .gl-jg-card-shell--grid .gl-jg-card:focus-visible .card-info {
    height: 60%;
}

:where([data-gl="fc"]) .gl-jg-card-shell--grid .gl-jg-card:hover .gl-jg-card__stats,
:where([data-gl="fc"]) .gl-jg-card-shell--grid .gl-jg-card:focus-visible .gl-jg-card__stats {
    max-height: 130px;
    padding-top: 8px;
    border-top-color: rgba(255, 255, 255, 0.1);
    opacity: 1;
    transform: translateY(0);
}

:where([data-gl="fc"]) .gl-jg-card-shell--grid .gl-jg-card:hover .card-root {
    border-color: var(--fc-accent);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
    transform: rotateX(var(--rot-x, 0deg)) rotateY(var(--rot-y, 0deg)) scale3d(1.08, 1.08, 1.08) !important;
}

:where([data-gl="fc"]) .gl-jg-card-shell--grid .gl-jg-card:hover .card-player-img {
    transform: translateX(-50%) scale(1.08);
}

/* En pantallas táctiles no hay hover: los datos se muestran siempre (sin inclinación) */
@media (hover: none) {
    :where([data-gl="fc"]) .gl-jg-card-shell--grid .card-info {
        height: 58%;
    }

    :where([data-gl="fc"]) .gl-jg-card-shell--grid .gl-jg-card__stats {
        max-height: 130px;
        padding-top: 8px;
        border-top-color: rgba(255, 255, 255, 0.1);
        opacity: 1;
        transform: none;
    }
}

/* Borde de rareza al pasar el mouse (mismo color que la vista clásica) */
:where([data-gl="fc"]) .gl-jg-card[data-rarity="Common"]:hover .card-root { border-color: #64748b; }
:where([data-gl="fc"]) .gl-jg-card[data-rarity="Bronze"]:hover .card-root { border-color: #7c2d12; }
:where([data-gl="fc"]) .gl-jg-card[data-rarity="Silver"]:hover .card-root { border-color: #94a3b8; }
:where([data-gl="fc"]) .gl-jg-card[data-rarity="Gold"]:hover .card-root { border-color: #ca8a04; }
:where([data-gl="fc"]) .gl-jg-card[data-rarity="Rare"]:hover .card-root { border-color: #06b6d4; }
:where([data-gl="fc"]) .gl-jg-card[data-rarity="Epic"]:hover .card-root { border-color: #d946ef; }
:where([data-gl="fc"]) .gl-jg-card[data-rarity="VMax"]:hover .card-root { border-color: #dc2626; }
:where([data-gl="fc"]) .gl-jg-card[data-rarity="Radiant"]:hover .card-root { border-color: #cbd5e1; }
:where([data-gl="fc"]) .gl-jg-card[data-rarity="Infinity"]:hover .card-root { border-color: #fde047; }
:where([data-gl="fc"]) .gl-jg-card[data-rarity="RegularHolo"]:hover .card-root { border-color: #93c5fd; }
:where([data-gl="fc"]) .gl-jg-card[data-rarity="SecretRare"]:hover .card-root { border-color: #fbbf24; }
:where([data-gl="fc"]) .gl-jg-card[data-rarity="Legend"]:hover .card-root { border-color: #fbbf24; }
:where([data-gl="fc"]) .gl-jg-card[data-rarity="Rainbow"]:hover .card-root { border-color: #f472b6; }
:where([data-gl="fc"]) .gl-jg-card[data-rarity="Ruby"]:hover .card-root { border-color: #ff4500; }
:where([data-gl="fc"]) .gl-jg-card[data-rarity="Esmeralda"]:hover .card-root { border-color: #10b981; }
:where([data-gl="fc"]) .gl-jg-card[data-rarity="Zafiro"]:hover .card-root { border-color: #d946ef; }
:where([data-gl="fc"]) .gl-jg-card[data-rarity="Topacio"]:hover .card-root { border-color: #38bdf8; }
:where([data-gl="fc"]) .gl-jg-card[data-rarity="Glitch"]:hover .card-root { border-color: #00ffff; }

@media (prefers-reduced-motion: reduce) {
    :where([data-gl="fc"]) .gl-jg-card-shell .fn-item-container,
    :where([data-gl="fc"]) .gl-jg-card-shell .card-player-img {
        transition: none;
        transform: none !important;
    }
}

/* ==========================================================================
   PÁGINA — CATÁLOGO (J1)
   ========================================================================== */
[data-gl="fc"] .gl-jg-page {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: var(--gl-space-6);
    padding-block: var(--gl-space-6) var(--gl-space-8);
}

[data-gl="fc"] .gl-jg-toolbar {
    display: grid;
    grid-template-columns: minmax(220px, 1.5fr) repeat(4, minmax(0, 1fr));
    align-items: end;
    gap: var(--gl-space-3);
}

[data-gl="fc"] .gl-jg-toolbar .gl-jg-search {
    width: 100%;
    margin: 0;
}

[data-gl="fc"] .gl-jg-toolbar .gl-jg-search input {
    min-height: 42px;
    border-radius: var(--gl-radius-md);
}

[data-gl="fc"] .gl-jg-toolbar .gl-tn-select {
    min-width: 0;
    max-width: none;
}

[data-gl="fc"] .gl-jg-toolbar .gl-tn-select select {
    width: 100%;
    min-width: 0;
    text-overflow: ellipsis;
}

[data-gl="fc"] .gl-jg-segment {
    grid-column: 1 / -1;
    display: inline-flex;
    justify-self: start;
    padding: 0.25rem;
    border: 1px solid var(--gl-border-strong);
    border-radius: var(--gl-radius-pill);
    background: var(--gl-bg-inset);
}

[data-gl="fc"] .gl-jg-segment button {
    min-height: 34px;
    padding: 0.3rem 0.95rem;
    border: 0;
    border-radius: var(--gl-radius-pill);
    background: transparent;
    color: var(--gl-text-secondary);
    font-size: var(--gl-text-sm);
    font-weight: var(--gl-weight-bold);
    cursor: pointer;
}

[data-gl="fc"] .gl-jg-segment button:focus-visible {
    outline: 2px solid var(--gl-cyan);
    outline-offset: 2px;
}

[data-gl="fc"] .gl-jg-segment button.is-active {
    background: rgba(var(--gl-cyan-rgb), 0.16);
    color: var(--gl-cyan);
}

[data-gl="fc"] .gl-jg-results {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--gl-space-2);
}

[data-gl="fc"] .gl-jg-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    align-items: start;
    gap: 2.2rem 1.15rem;
    padding-top: var(--gl-space-2);
}

[data-gl="fc"] .gl-jg-skeleton {
    aspect-ratio: 2 / 3;
    border-radius: 10px;
}

/* Paginación numerada */
[data-gl="fc"] .gl-jg-pagination {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: var(--gl-space-2);
}

[data-gl="fc"] .gl-jg-pagination__page {
    min-width: 38px;
    min-height: 38px;
    padding: 0 0.6rem;
    border: 1px solid var(--gl-border-strong);
    border-radius: var(--gl-radius-md);
    background: var(--gl-bg-inset);
    color: var(--gl-text-secondary);
    font-family: var(--gl-font-stats);
    font-weight: var(--gl-weight-black);
    cursor: pointer;
}

[data-gl="fc"] .gl-jg-pagination__page:hover {
    border-color: var(--gl-border-accent);
    color: var(--gl-text);
}

[data-gl="fc"] .gl-jg-pagination__page:focus-visible {
    outline: 2px solid var(--gl-cyan);
    outline-offset: 2px;
}

[data-gl="fc"] .gl-jg-pagination__page.is-active {
    border-color: var(--gl-cyan);
    background: rgba(var(--gl-cyan-rgb), 0.16);
    color: var(--gl-cyan);
}

[data-gl="fc"] .gl-jg-pagination__gap {
    color: var(--gl-text-dim);
}

[data-gl="fc"] .gl-jg-pagination__info {
    flex-basis: 100%;
    color: var(--gl-text-muted);
    font-size: var(--gl-text-xs);
    font-weight: var(--gl-weight-bold);
    text-align: center;
    text-transform: uppercase;
}

/* ---------- Responsive catálogo ---------- */
@media (max-width: 1180px) {
    [data-gl="fc"] .gl-jg-toolbar {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    [data-gl="fc"] .gl-jg-toolbar .gl-jg-search {
        grid-column: 1 / -1;
    }

    [data-gl="fc"] .gl-jg-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (max-width: 980px) {
    [data-gl="fc"] .gl-jg-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 720px) {
    [data-gl="fc"] .gl-jg-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 1.6rem 0.8rem;
    }

    [data-gl="fc"] .gl-jg-segment {
        display: flex;
        justify-self: stretch;
    }

    [data-gl="fc"] .gl-jg-segment button {
        flex: 1 1 0;
        padding-inline: 0.4rem;
    }
}

@media (max-width: 480px) {
    [data-gl="fc"] .gl-jg-page {
        gap: var(--gl-space-5);
    }

    [data-gl="fc"] .gl-jg-toolbar {
        gap: var(--gl-space-2);
    }

    :where([data-gl="fc"] .gl-jg-card-shell) .card-name {
        font-size: 0.85rem;
    }

    :where([data-gl="fc"] .gl-jg-card-shell) .card-info {
        padding: 8px;
    }

    /* En carta pequeña el panel crece lo necesario para que quepa todo */
    :where([data-gl="fc"]) .gl-jg-card-shell--grid .gl-jg-card .card-info {
        height: auto;
        min-height: 36%;
    }

    :where([data-gl="fc"] .gl-jg-card-shell) .card-stats-grid {
        gap: 3px 8px;
    }

    :where([data-gl="fc"] .gl-jg-card-shell) .card-stat-row {
        font-size: 0.6rem;
    }

    :where([data-gl="fc"] .gl-jg-card-shell) .gl-jg-card__tier {
        min-width: 44px;
        padding: 0.26rem 0.4rem;
        font-size: 0.6rem;
    }

    :where([data-gl="fc"] .gl-jg-card-shell) .card-icon-img {
        width: 20px;
        height: 20px;
    }

    :where([data-gl="fc"] .gl-jg-card-shell) .fut-market-value {
        font-size: 0.85rem;
    }
}


/* ==========================================================================
   J2 — PERFIL DE JUGADOR (/jugador/{id})
   ========================================================================== */

/* ---------- Kit de carta: variante grande del perfil (datos siempre visibles) ---------- */
:where([data-gl="fc"]) .gl-jg-card-shell--hero .fn-item-container {
    max-width: 320px;
}

:where([data-gl="fc"]) .gl-jg-card-shell--hero .card-info {
    height: auto;
    min-height: 44%;
    padding: 16px 18px 18px;
}

:where([data-gl="fc"]) .gl-jg-card-shell--hero .card-name {
    font-size: 1.35rem;
}

:where([data-gl="fc"]) .gl-jg-card-shell--hero .card-stat-row {
    font-size: 0.82rem;
}

:where([data-gl="fc"]) .gl-jg-card-shell--hero .card-icon-img {
    width: 30px;
    height: 30px;
}

:where([data-gl="fc"]) .gl-jg-card-shell--hero .gl-jg-card:hover .card-root {
    transform: rotateX(var(--rot-x, 0deg)) rotateY(var(--rot-y, 0deg)) scale3d(1.04, 1.04, 1.04) !important;
}

:where([data-gl="fc"] .gl-jg-card-shell) .gl-jg-card__subtitle {
    flex-shrink: 0;
    margin-bottom: 10px;
    overflow: hidden;
    color: #00e5ff;
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 2px;
    text-align: center;
    text-overflow: ellipsis;
    text-transform: uppercase;
    white-space: nowrap;
}

/* Calificación FIFA en la carta grande */
:where([data-gl="fc"] .gl-jg-card-shell) .gl-jg-tier--rating {
    --tier-rgb: 0, 229, 255;
    min-width: 58px;
    padding: 0.4rem 0.55rem;
    background: rgba(2, 7, 16, 0.82);
    color: #00e5ff;
    font-size: 1.45rem;
    text-shadow: 0 0 10px rgba(0, 229, 255, 0.45);
}

/* La posición bajo la calificación también necesita fondo sobre skins claras */
:where([data-gl="fc"]) .gl-jg-card-shell--hero .rating-pos {
    padding: 0.1rem 0.4rem;
    border-radius: 4px;
    background: rgba(2, 7, 16, 0.72);
}

/* ---------- Kit de carta: coleccionable (200px, proporción 5:7) ---------- */
:where([data-gl="fc"]) .gl-jg-card-shell--collectible {
    display: grid;
    justify-items: center;
    gap: var(--gl-space-2);
}

:where([data-gl="fc"]) .gl-jg-card-shell--collectible .fn-item-container {
    max-width: 200px;
}

:where([data-gl="fc"]) .gl-jg-card--collectible {
    aspect-ratio: 5 / 7;
}

:where([data-gl="fc"]) .gl-jg-card-shell--collectible .card-root {
    border-radius: 12px;
}

:where([data-gl="fc"]) .gl-jg-card-shell--collectible .gl-jg-card:hover .card-root {
    transform: rotateX(var(--rot-x, 0deg)) rotateY(var(--rot-y, 0deg)) scale3d(1.05, 1.05, 1.05) !important;
}

:where([data-gl="fc"]) .gl-jg-card-shell--collectible.is-missing .fn-item-container {
    filter: grayscale(100%) opacity(0.6);
    transition: filter 0.3s ease;
}

:where([data-gl="fc"]) .gl-jg-card-shell--collectible.is-missing:hover .fn-item-container {
    filter: grayscale(80%) opacity(0.9);
}

[data-gl="fc"] .gl-jg-cc__head {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 10;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.35rem;
    width: 100%;
    padding: 0.5rem;
}

[data-gl="fc"] .gl-jg-cc__title {
    display: grid;
    gap: 0.25rem;
    min-width: 0;
    max-width: 75%;
}

[data-gl="fc"] .gl-jg-cc__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
}

[data-gl="fc"] .gl-jg-cc__tag {
    padding: 2px 4px;
    border: 1px solid currentColor;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    font-family: 'Poppins', sans-serif;
    font-size: 0.6rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    line-height: 1.2;
    text-transform: uppercase;
}

[data-gl="fc"] .gl-jg-cc__tag.is-dark {
    background: rgba(0, 0, 0, 0.6);
}

[data-gl="fc"] [data-rarity="TOTW"] .gl-jg-cc__tag {
    border-color: transparent;
    background: #facc15;
    color: #000;
}

[data-gl="fc"] .gl-jg-cc__name {
    margin: 0;
    overflow: hidden;
    color: #fff;
    font-size: 1.2rem;
    font-weight: var(--gl-weight-heavy);
    line-height: 1.1;
    text-overflow: ellipsis;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
    text-transform: uppercase;
    white-space: nowrap;
}

[data-gl="fc"] .gl-jg-cc__name.is-team {
    display: -webkit-box;
    font-size: 1rem;
    line-height: 1;
    white-space: normal;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

[data-gl="fc"] .gl-jg-cc__club {
    flex-shrink: 0;
    width: 35px;
    height: 35px;
    object-fit: contain;
    filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.8));
}

[data-gl="fc"] .gl-jg-cc__art {
    position: absolute;
    top: 15%;
    right: 0;
    bottom: 35%;
    left: 0;
    z-index: 9;
}

[data-gl="fc"] .gl-jg-cc__art img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center bottom;
    filter: drop-shadow(0 10px 15px rgba(0, 0, 0, 0.7));
}

[data-gl="fc"] .gl-jg-cc__art.is-team {
    display: flex;
    align-items: center;
    justify-content: center;
}

[data-gl="fc"] .gl-jg-cc__art.is-team img {
    width: 65%;
    height: 65%;
    object-position: center;
}

[data-gl="fc"] .gl-jg-cc__info {
    position: absolute;
    bottom: 0;
    left: 0;
    z-index: 10;
    display: grid;
    justify-items: center;
    gap: 0.15rem;
    width: 100%;
    padding: 1.4rem 0.5rem 0.55rem;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.95) 40%, rgba(0, 0, 0, 0.6) 80%, transparent 100%);
    color: #fff;
    text-align: center;
}

[data-gl="fc"] .gl-jg-cc__label {
    color: var(--gl-text-muted);
    font-size: 0.55rem;
    font-weight: var(--gl-weight-bold);
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

[data-gl="fc"] .gl-jg-cc__expansion {
    width: 100%;
    padding-bottom: 0.25rem;
    overflow: hidden;
    border-bottom: 1px solid rgba(255, 255, 255, 0.18);
    color: var(--gl-yellow);
    font-size: 0.68rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

[data-gl="fc"] .gl-jg-cc__country {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding-top: 0.15rem;
    font-size: 0.65rem;
    font-weight: var(--gl-weight-bold);
}

[data-gl="fc"] .gl-jg-cc__country img {
    width: 16px;
    height: 11px;
    object-fit: cover;
    border-radius: 2px;
}

[data-gl="fc"] .gl-jg-cc__lock {
    position: absolute;
    top: 50%;
    left: 50%;
    z-index: 12;
    color: #fff;
    font-size: 3rem;
    opacity: 0.8;
    text-shadow: 0 0 10px #000;
    transform: translate(-50%, -50%);
}

[data-gl="fc"] .gl-jg-cc__badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.25rem 0.8rem;
    border: 1px solid var(--gl-border-strong);
    border-radius: var(--gl-radius-pill);
    background: rgba(0, 0, 0, 0.5);
    color: var(--gl-text-muted);
    font-size: var(--gl-text-xs);
    font-weight: var(--gl-weight-bold);
    text-transform: uppercase;
}

[data-gl="fc"] .gl-jg-cc__badge.is-owned {
    border-color: var(--gl-cyan);
    background: rgba(var(--gl-cyan-rgb), 0.16);
    color: #fff;
}

[data-gl="fc"] .gl-jg-cc__badge.is-owned i {
    color: var(--gl-cyan);
}

/* ---------- Cabecera del perfil (JgHero) ---------- */
[data-gl="fc"] .gl-jg-hero {
    display: grid;
    grid-template-columns: minmax(240px, 300px) minmax(0, 1fr);
    align-items: center;
    gap: clamp(1.25rem, 3vw, 2.5rem);
    padding: clamp(1.25rem, 3vw, 2.25rem);
}

[data-gl="fc"] .gl-jg-hero__card {
    min-width: 0;
}

[data-gl="fc"] .gl-jg-hero__info {
    display: grid;
    align-content: center;
    gap: var(--gl-space-4);
    min-width: 0;
}

[data-gl="fc"] .gl-jg-hero__top {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--gl-space-3);
}

[data-gl="fc"] .gl-jg-hero__name {
    margin: 0;
    color: var(--gl-cyan);
    font-family: var(--gl-font-display);
    font-size: clamp(1.9rem, 4.5vw, 3.2rem);
    font-style: italic;
    font-weight: var(--gl-weight-black);
    line-height: 1;
    overflow-wrap: anywhere;
    text-shadow: 0 0 24px rgba(var(--gl-cyan-rgb), 0.28);
    text-transform: uppercase;
}

[data-gl="fc"] .gl-jg-hero__tag {
    margin-top: calc(var(--gl-space-2) * -1);
    color: var(--gl-text-secondary);
    font-size: var(--gl-text-sm);
    font-weight: var(--gl-weight-bold);
    letter-spacing: var(--gl-tracking-wide);
    text-transform: uppercase;
}

[data-gl="fc"] .gl-jg-hero__chips {
    display: flex;
    flex-wrap: wrap;
    gap: var(--gl-space-2);
    margin: 0;
    padding: 0;
    list-style: none;
}

[data-gl="fc"] .gl-jg-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    min-height: 34px;
    padding: 0.35rem 0.8rem;
    border: 1px solid var(--gl-border-strong);
    border-radius: var(--gl-radius-sm);
    background: var(--gl-bg-inset);
    color: var(--gl-text);
    font-size: var(--gl-text-sm);
    font-weight: var(--gl-weight-bold);
    text-decoration: none;
}

[data-gl="fc"] .gl-jg-chip img {
    width: 20px;
    height: 20px;
    object-fit: contain;
    border-radius: 3px;
}

[data-gl="fc"] .gl-jg-chip i {
    color: var(--gl-cyan);
}

[data-gl="fc"] .gl-jg-chip.is-accent {
    border-color: var(--gl-cyan);
    background: var(--gl-cyan);
    color: var(--gl-text-on-accent);
    box-shadow: 0 0 12px rgba(var(--gl-cyan-rgb), 0.35);
}

[data-gl="fc"] .gl-jg-chip.is-link {
    transition: border-color var(--gl-duration-fast) var(--gl-ease-out), color var(--gl-duration-fast) var(--gl-ease-out);
}

[data-gl="fc"] .gl-jg-chip.is-link:hover,
[data-gl="fc"] .gl-jg-chip.is-link:focus-visible {
    border-color: var(--gl-cyan);
    color: var(--gl-cyan);
}

[data-gl="fc"] .gl-jg-chip.is-muted {
    color: var(--gl-text-muted);
}

[data-gl="fc"] .gl-jg-chip.is-creator {
    border-color: rgba(255, 255, 255, 0.3);
    background: linear-gradient(135deg, rgba(var(--gl-magenta-rgb), 0.75), rgba(var(--gl-cyan-rgb), 0.75));
}

[data-gl="fc"] .gl-jg-chip.is-creator i {
    color: #fff;
}

[data-gl="fc"] .gl-jg-hero__kpis {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 150px;
    gap: var(--gl-space-2);
}

[data-gl="fc"] .gl-jg-hero__kpis .gl-cl-kpis {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

[data-gl="fc"] .gl-jg-hero__trophies {
    display: grid;
    place-content: center;
    justify-items: center;
    gap: 0.15rem;
    padding: 0.6rem;
    border: 1px solid rgba(var(--gl-yellow-rgb), 0.6);
    border-radius: var(--gl-radius-md);
    background: linear-gradient(135deg, rgba(var(--gl-yellow-rgb), 0.2), rgba(var(--gl-yellow-rgb), 0.05));
    color: var(--gl-yellow);
    font-weight: var(--gl-weight-heavy);
    text-transform: uppercase;
    cursor: pointer;
    transition: box-shadow var(--gl-duration-fast) var(--gl-ease-out), background var(--gl-duration-fast) var(--gl-ease-out);
}

[data-gl="fc"] .gl-jg-hero__trophies i {
    font-size: 1.4rem;
}

[data-gl="fc"] .gl-jg-hero__trophies small {
    color: var(--gl-text-muted);
    font-size: var(--gl-text-xs);
    font-weight: var(--gl-weight-bold);
    text-transform: none;
}

[data-gl="fc"] .gl-jg-hero__trophies:hover,
[data-gl="fc"] .gl-jg-hero__trophies:focus-visible {
    background: rgba(var(--gl-yellow-rgb), 0.24);
    box-shadow: var(--gl-glow-yellow);
}

[data-gl="fc"] .gl-jg-hero__trophies:focus-visible {
    outline: 2px solid var(--gl-yellow);
    outline-offset: 2px;
}

/* ---------- Carrera (JgCareerTable) ---------- */
[data-gl="fc"] .gl-jg-career {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: var(--gl-space-3);
}

[data-gl="fc"] .gl-jg-career .gl-table-wrap {
    overflow-x: auto;
}

[data-gl="fc"] .gl-jg-career .gl-cl-subhead:not(:first-child) {
    margin-top: var(--gl-space-4);
}

[data-gl="fc"] .gl-jg-career__table .is-green { color: var(--gl-success); }
[data-gl="fc"] .gl-jg-career__table .is-cyan { color: var(--gl-cyan); }
[data-gl="fc"] .gl-jg-career__table .is-yellow { color: var(--gl-yellow); }
[data-gl="fc"] .gl-jg-career__table .is-red { color: var(--gl-danger); }

[data-gl="fc"] .gl-jg-career__table th:nth-child(n + 2) {
    width: 64px;
}

[data-gl="fc"] .gl-jg-career__club {
    display: flex;
    align-items: center;
    gap: var(--gl-space-3);
    min-width: 0;
    color: var(--gl-text);
    text-decoration: none;
    transition: color var(--gl-duration-fast) var(--gl-ease-out), transform var(--gl-duration-fast) var(--gl-ease-out);
}

[data-gl="fc"] .gl-jg-career__club img {
    flex-shrink: 0;
    width: 30px;
    height: 30px;
    padding: 3px;
    object-fit: contain;
    border-radius: 50%;
    background: #fff;
}

[data-gl="fc"] .gl-jg-career__club strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

[data-gl="fc"] .gl-jg-career__club:hover,
[data-gl="fc"] .gl-jg-career__club:focus-visible {
    color: var(--gl-cyan);
    transform: translateX(4px);
}

[data-gl="fc"] .gl-jg-career.is-elite .gl-jg-career__club:hover,
[data-gl="fc"] .gl-jg-career.is-elite .gl-jg-career__club:focus-visible {
    color: var(--gl-success);
}

[data-gl="fc"] .gl-jg-career.is-elite .gl-cl-subhead i {
    color: var(--gl-success);
}

[data-gl="fc"] .gl-jg-career__tournament {
    display: inline-block;
    max-width: 100%;
    padding: 0.35rem 0.75rem;
    overflow: hidden;
    border: 1px solid var(--gl-border-strong);
    border-radius: var(--gl-radius-sm);
    background: var(--gl-bg-inset);
    color: var(--gl-text);
    font-size: var(--gl-text-sm);
    font-weight: var(--gl-weight-bold);
    letter-spacing: 0.04em;
    text-overflow: ellipsis;
    vertical-align: middle;
    white-space: nowrap;
}

/* ---------- Galería de cartas (JgCardGallery) ---------- */
[data-gl="fc"] .gl-jg-gallery__head {
    flex-wrap: wrap;
}

[data-gl="fc"] .gl-jg-gallery__desc {
    margin: 0.35rem 0 0;
    color: var(--gl-text-secondary);
    font-size: var(--gl-text-sm);
}

[data-gl="fc"] .gl-jg-gallery__desc .is-green { color: var(--gl-success); }
[data-gl="fc"] .gl-jg-gallery__desc .is-red { color: var(--gl-danger); }

[data-gl="fc"] .gl-jg-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
    gap: var(--gl-space-6) var(--gl-space-4);
    padding-top: var(--gl-space-2);
}

/* ---------- Palmarés (JgAwards) ---------- */
[data-gl="fc"] .gl-jg-awards {
    display: grid;
    gap: var(--gl-space-3);
}

[data-gl="fc"] .gl-jg-awards + .gl-jg-awards {
    margin-top: var(--gl-space-6);
}

[data-gl="fc"] .gl-jg-awards__title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--gl-border);
    color: var(--gl-cyan);
    font-size: var(--gl-text-sm);
    font-weight: var(--gl-weight-heavy);
    letter-spacing: var(--gl-tracking-wide);
    text-transform: uppercase;
}

[data-gl="fc"] .gl-jg-awards__title.is-gold {
    color: var(--gl-yellow);
}

[data-gl="fc"] .gl-jg-awards__title small {
    color: var(--gl-text-muted);
}

[data-gl="fc"] .gl-jg-awards__grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: var(--gl-space-3);
    margin: 0;
    padding: 0;
    list-style: none;
}

[data-gl="fc"] .gl-jg-award {
    display: grid;
    justify-items: center;
    align-content: start;
    gap: 0.35rem;
    padding: var(--gl-space-4) var(--gl-space-3);
    border: 1px solid rgba(var(--gl-cyan-rgb), 0.28);
    border-radius: var(--gl-radius-md);
    background: radial-gradient(circle at 50% 0, rgba(var(--gl-cyan-rgb), 0.16), transparent 65%), var(--gl-bg-inset);
    text-align: center;
}

[data-gl="fc"] .gl-jg-award.is-gold {
    border-color: rgba(var(--gl-yellow-rgb), 0.3);
    background: radial-gradient(circle at 50% 0, rgba(var(--gl-yellow-rgb), 0.16), transparent 65%), var(--gl-bg-inset);
}

[data-gl="fc"] .gl-jg-award > img {
    width: 64px;
    height: 64px;
    object-fit: contain;
    filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.5));
}

[data-gl="fc"] .gl-jg-award strong {
    color: var(--gl-text);
    font-size: var(--gl-text-sm);
    text-transform: uppercase;
}

[data-gl="fc"] .gl-jg-award > span:not(.gl-badge):not(.gl-jg-award__club) {
    color: var(--gl-text-muted);
    font-size: var(--gl-text-xs);
}

[data-gl="fc"] .gl-jg-award__club {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    max-width: 100%;
    margin-top: 0.3rem;
    padding: 0.3rem 0.5rem;
    border: 1px solid var(--gl-border);
    border-radius: var(--gl-radius-sm);
    color: var(--gl-text-secondary);
    font-size: var(--gl-text-xs);
}

[data-gl="fc"] .gl-jg-award__club img {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    object-fit: contain;
    border-radius: 50%;
}

[data-gl="fc"] .gl-jg-award__club span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ---------- Carga del perfil ---------- */
[data-gl="fc"] .gl-jg-profile-loading {
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr);
    gap: var(--gl-space-4);
}

[data-gl="fc"] .gl-jg-profile-loading__card {
    aspect-ratio: 2 / 3;
}

[data-gl="fc"] .gl-jg-profile-loading__info {
    min-height: 240px;
}

[data-gl="fc"] .gl-jg-profile-loading .gl-tn-loading__tabs,
[data-gl="fc"] .gl-jg-profile-loading .gl-tn-loading__main {
    grid-column: 1 / -1;
}

/* ---------- Responsivo (perfil) ---------- */
@media (max-width: 1100px) {
    [data-gl="fc"] .gl-jg-hero__kpis {
        grid-template-columns: minmax(0, 1fr);
    }

    [data-gl="fc"] .gl-jg-hero__trophies {
        grid-auto-flow: column;
        align-items: center;
        gap: 0.5rem;
    }
}

@media (max-width: 767px) {
    [data-gl="fc"] .gl-jg-hero {
        grid-template-columns: minmax(0, 1fr);
        justify-items: center;
        text-align: center;
    }

    [data-gl="fc"] .gl-jg-hero__card {
        width: min(100%, 280px);
    }

    [data-gl="fc"] .gl-jg-hero__info {
        justify-items: center;
        width: 100%;
    }

    [data-gl="fc"] .gl-jg-hero__top {
        flex-direction: column-reverse;
        width: 100%;
    }

    [data-gl="fc"] .gl-jg-hero__top .gl-btn {
        align-self: flex-end;
    }

    [data-gl="fc"] .gl-jg-hero__chips,
    [data-gl="fc"] .gl-jg-hero .gl-cl-socials {
        justify-content: center;
    }

    [data-gl="fc"] .gl-jg-hero__kpis {
        width: 100%;
    }

    [data-gl="fc"] .gl-jg-hero__kpis .gl-cl-kpis {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        text-align: left;
    }

    [data-gl="fc"] .gl-jg-career__table {
        table-layout: auto;
    }

    [data-gl="fc"] .gl-jg-career__table th:nth-child(n + 2) {
        width: 1%;
        white-space: nowrap;
    }

    /* En tabla automática el recorte con "..." necesita un ancho máximo */
    [data-gl="fc"] .gl-jg-career__club strong {
        max-width: 42vw;
    }

    [data-gl="fc"] .gl-jg-career__tournament {
        max-width: 50vw;
    }

    [data-gl="fc"] .gl-jg-profile-loading {
        grid-template-columns: minmax(0, 1fr);
    }

    [data-gl="fc"] .gl-jg-profile-loading__card {
        width: min(100%, 280px);
        justify-self: center;
    }
}

@media (max-width: 520px) {
    [data-gl="fc"] .gl-jg-hide-sm {
        display: none;
    }

    [data-gl="fc"] .gl-table.gl-jg-career__table tbody td,
    [data-gl="fc"] .gl-table.gl-jg-career__table thead th {
        padding: 0.55rem 0.4rem;
    }

    [data-gl="fc"] .gl-jg-career__club {
        gap: var(--gl-space-2);
    }

    [data-gl="fc"] .gl-jg-hero__kpis .gl-cl-kpis {
        grid-template-columns: minmax(0, 1fr);
    }

    [data-gl="fc"] .gl-jg-gallery {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: var(--gl-space-4) var(--gl-space-2);
    }

    [data-gl="fc"] .gl-jg-cc__name {
        font-size: 0.95rem;
    }

    [data-gl="fc"] .gl-jg-cc__club {
        width: 26px;
        height: 26px;
    }

    [data-gl="fc"] .gl-jg-cc__badge {
        padding: 0.2rem 0.55rem;
        font-size: 0.62rem;
    }

    [data-gl="fc"] .gl-jg-cc__lock {
        font-size: 2.2rem;
    }

    [data-gl="fc"] .gl-jg-awards__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

[data-gl="fc"] .gl-jg-award .gl-badge {
    max-width: 100%;
    height: auto;
    line-height: 1.3;
    text-align: center;
    white-space: normal;
}

/* ---------- Base de jugadores (/todos-los-jugadores): misma carta del catálogo + insignia TOP ---------- */
[data-gl="fc"] .gl-aj-toolbar { display: grid; gap: var(--gl-space-3); }
[data-gl="fc"] .gl-aj-slot { position: relative; --tone: var(--gl-cyan-rgb); }
[data-gl="fc"] .gl-aj-page.is-elite .gl-aj-slot { --tone: var(--gl-magenta-rgb); }
[data-gl="fc"] .gl-aj-slot.is-gold { --tone: var(--gl-gold-rgb); }
[data-gl="fc"] .gl-aj-slot.is-silver { --tone: var(--gl-silver-rgb); }
[data-gl="fc"] .gl-aj-slot.is-bronze { --tone: var(--gl-bronze-rgb); }

[data-gl="fc"] .gl-aj-rank {
    position: absolute;
    top: -10px;
    left: 50%;
    z-index: 5;
    padding: 0.15rem 0.7rem;
    border: 1px solid rgba(var(--tone), 0.8);
    border-radius: var(--gl-radius-pill);
    background: rgba(5, 7, 13, 0.92);
    color: rgb(var(--tone));
    font-family: var(--gl-font-stats);
    font-size: var(--gl-text-xs);
    font-weight: var(--gl-weight-black);
    letter-spacing: 1px;
    white-space: nowrap;
    box-shadow: 0 0 12px rgba(var(--tone), 0.35);
    transform: translateX(-50%);
    pointer-events: none;
}

[data-gl="fc"] .gl-aj-slot.is-gold .gl-aj-rank,
[data-gl="fc"] .gl-aj-slot.is-silver .gl-aj-rank,
[data-gl="fc"] .gl-aj-slot.is-bronze .gl-aj-rank { background: rgb(var(--tone)); color: #0b0c10; }
