/* ---------- Perfil: tarjeta del jugador ---------- */
.player-card { position: relative; overflow: hidden; border-radius: 24px; padding: 18px 18px 20px; color: #f2f5f9; text-align: center;
  background: radial-gradient(120% 80% at 50% 0%, color-mix(in srgb, var(--t2) 28%, transparent), transparent 60%),
    radial-gradient(90% 70% at 100% 100%, rgba(var(--accent-rgb), .22), transparent 60%),
    linear-gradient(160deg, #161b24 0%, #0a0d12 70%);
  border: 1px solid color-mix(in srgb, var(--t2) 45%, transparent);
  box-shadow: 0 18px 40px rgba(0, 0, 0, .35), inset 0 1px 0 rgba(255, 255, 255, .06); }
.player-card::before { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .06;
  background: repeating-linear-gradient(135deg, #fff 0 1px, transparent 1px 14px); }
.player-card .pc-glow { position: absolute; left: 50%; top: 70px; width: 260px; height: 260px; transform: translateX(-50%); border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--t1) 30%, transparent), transparent 65%); pointer-events: none; }
.pc-top { position: relative; display: flex; justify-content: space-between; align-items: center; }
.pc-member { font-size: .78rem; color: #a7afbd; display: inline-flex; align-items: center; gap: 6px; }
.pc-set { color: #c9d1dc; }
.pc-main { position: relative; display: inline-block; margin: 6px auto 8px; }
.pc-avatar { border: 0; padding: 4px; border-radius: 50%; cursor: zoom-in;
  background: conic-gradient(from 210deg, var(--t0), var(--t1), var(--t2), var(--t1), var(--t0)); }
.pc-avatar .avatar { box-shadow: 0 0 0 3px #0d1117; }
.pc-ins { position: absolute; right: -26px; bottom: -14px; }
.pc-name { position: relative; font-size: 1.9rem; letter-spacing: -.02em; margin-top: 6px; }
.pc-rank { position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px; margin-top: 4px; }
.pc-rankname { font-weight: 800; font-size: 1.05rem; background: linear-gradient(90deg, var(--t1), var(--t2), var(--t1)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.pc-level { font-size: .8rem; color: #a7afbd; letter-spacing: .04em; text-transform: uppercase; font-weight: 700; }
.pc-progress { position: relative; text-align: left; margin: 14px 0 12px; }
.pc-progress .muted { color: #a7afbd; }
.pc-progress .bar { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .08); }
.pc-stats { position: relative; display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.pc-stats > div, .pc-stats > a, .pc-stats > button { display: flex; flex-direction: column; gap: 2px; padding: 10px 6px; border-radius: 14px; background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .06); }
.pc-stats b { font-size: 1.35rem; font-variant-numeric: tabular-nums; }
.pc-stats span { font-size: .72rem; color: #a7afbd; }
.pc-edit { position: relative; margin-top: 12px; background: rgba(255, 255, 255, .06); border-color: rgba(255, 255, 255, .12); color: #f2f5f9; }
.player-card.legend { border-color: rgba(255, 200, 80, .6); }

/* ---------- Perfil: estadísticas visuales ---------- */
.rings { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.ring-stat { position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px; text-align: center; }
.ring-stat svg, .card .ring-stat svg { display: block; width: 76px !important; height: 76px !important; flex: none; }
.ring-bg { fill: none; stroke: var(--surface-2); stroke-width: 8; }
.ring-fg { fill: none; stroke: var(--accent); stroke-width: 8; stroke-linecap: round; transition: stroke-dasharray .8s ease; }
.ring-val { position: absolute; top: 22px; left: 0; right: 0; display: flex; flex-direction: column; align-items: center; line-height: 1; }
.ring-val b { font-size: 1.1rem; }
.ring-val span { font-size: .66rem; color: var(--muted); }
.big-num-stat { justify-content: center; }
.big-num-stat > b { font-size: 1.6rem; color: var(--accent-text); margin: 18px 0 8px; }
.mini-bars { display: grid; grid-template-columns: repeat(8, 1fr); gap: 6px; align-items: end; height: 90px; margin: 6px 0 6px; }
.mb-title { margin: 16px 0 0; }
.mb-col { height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 4px; }
.mb-col i { display: block; width: 70%; min-height: 3px; border-radius: 6px 6px 3px 3px; background: rgba(var(--accent-rgb), .35); }
.mb-col.cur i { background: linear-gradient(180deg, var(--accent), var(--accent-2)); }
.mb-v { font-size: .7rem; font-weight: 700; color: var(--text-2); }
.mb-l { font-size: .62rem; color: var(--muted); }
.pstat-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 8px; margin-top: 10px; }
.pstat-row > div { display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; column-gap: 8px; align-items: center; padding: 10px; border-radius: 12px; background: var(--surface-2); min-width: 0; }
.pstat-row svg { grid-row: span 2; width: 20px; height: 20px; color: var(--accent-text); }
.pstat-row b { font-size: 1rem; }
.pstat-row span { font-size: .72rem; color: var(--muted); }

/* ---------- Perfil: expositor de medallas y retos Xtreme ---------- */
.medal-shelf { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 10px; }
.shelf-medal { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 6px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface-2); color: var(--text); font: inherit; cursor: pointer; text-align: center; }
.shelf-medal .sm-ic { width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; background: var(--bg-2); border: 2px solid var(--line); }
.shelf-medal .sm-ic svg { width: 24px; height: 24px; }
.shelf-medal .sm-name { font-size: .72rem; font-weight: 700; line-height: 1.2; }
.shelf-medal.got .sm-ic { color: #2a1600; background: radial-gradient(circle at 35% 30%, #fff1b8, #ffd36b 45%, #c48a00); border-color: #ffe08a; box-shadow: 0 4px 14px rgba(255, 196, 0, .25); }
.shelf-medal.got.r-rara .sm-ic, .medal-detail.got.r-rara .sm-ic { background: radial-gradient(circle at 35% 30%, #e3edff, #82b1ff 45%, #2962ff); border-color: #b3cfff; color: #04163d; box-shadow: 0 4px 14px rgba(41, 98, 255, .3); }
.shelf-medal.got.r-poco_comun .sm-ic, .medal-detail.got.r-poco_comun .sm-ic { background: radial-gradient(circle at 35% 30%, #e0ffef, #69f0ae 45%, #00a152); border-color: #b9f6ca; color: #00301a; box-shadow: 0 4px 14px rgba(0, 200, 83, .25); }
.shelf-medal.got.r-comun .sm-ic, .medal-detail.got.r-comun .sm-ic { background: radial-gradient(circle at 35% 30%, #ffffff, #cfd6e2 45%, #7d8798); border-color: #e3e8f0; color: #1b2230; box-shadow: none; }
.shelf-medal.got.r-epica .sm-ic, .medal-detail.got.r-epica .sm-ic { background: radial-gradient(circle at 35% 30%, #f6e3ff, #d77bff 45%, #8e1fe0); border-color: #ebc2ff; color: #2a0640; box-shadow: 0 4px 14px rgba(156, 39, 255, .3); }
.shelf-medal.got.r-legendaria .sm-ic, .medal-detail.got.r-legendaria .sm-ic { background: radial-gradient(circle at 35% 30%, #fffbe6, #ffd36b 45%, #c48a00); border-color: #ffe08a; color: #2a1600; box-shadow: 0 0 18px rgba(255, 196, 0, .45); }
.shelf-medal.locked { opacity: .5; }
.xtreme { border-style: dashed; }
.xtreme .shelf-medal { cursor: default; }
.medal-detail { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; }
.medal-detail .sm-ic { width: 84px; height: 84px; border-radius: 50%; display: grid; place-items: center; background: var(--bg-2); border: 2px solid var(--line); }
.medal-detail .sm-ic svg { width: 42px; height: 42px; }
.medal-detail.got .sm-ic { color: #2a1600; background: radial-gradient(circle at 35% 30%, #fff1b8, #ffd36b 45%, #c48a00); border-color: #ffe08a; }

/* ---------- Perfil: formularios compactos ---------- */
.compact-form h2 { display: flex; align-items: center; gap: 8px; font-size: 1.1rem; }
.compact-form h2 svg { color: var(--accent-text); }
.crow { display: grid; grid-template-columns: 32px 88px 1fr; align-items: center; gap: 8px; padding: 6px 0; border-bottom: 1px solid var(--line); }
.crow-ic { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; background: rgba(var(--accent-rgb), .1); color: var(--accent-text); }
.crow-ic svg { width: 17px; height: 17px; }
.crow-l { font-size: .82rem; font-weight: 700; color: var(--text-2); }
.crow .field { gap: 0; }
.crow .field > label { display: none; }
.crow .input.sm, .crow select.input { height: 38px; }
.seg.sm label span { padding: 6px 8px; font-size: .82rem; }
.cgrid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.cbox { display: flex; flex-direction: column; gap: 6px; padding: 10px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line); }
.cbox > span:first-child { display: flex; align-items: center; gap: 6px; font-size: .76rem; font-weight: 700; color: var(--text-2); }
.cbox > span:first-child svg { width: 15px; height: 15px; color: var(--accent-text); }
.cin { display: flex; align-items: center; gap: 6px; }
.cin .input { height: 36px; background: var(--surface); }
.cin em { font-style: normal; font-size: .78rem; color: var(--muted); }
.cbox.info b { font-size: 1.3rem; }
.ranks-card summary { list-style: none; cursor: pointer; }
.ranks-card summary::-webkit-details-marker { display: none; }
.ranks-card[open] summary svg { transform: rotate(180deg); }
/* Iconos de las cifras de la tarjeta (mancuerna, racha, medalla) */
.pc-stats > div, .pc-stats > a, .pc-stats > button { align-items: center; text-align: center; }
.pc-stats > .pcs-link { color: inherit; font: inherit; text-decoration: none; cursor: pointer; transition: background .15s; }
.pc-stats > .pcs-link:hover, .pc-stats > .pcs-link:active { background: rgba(255, 255, 255, .1); }
.pc-stats .pcs-ic { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; margin-bottom: 2px; color: var(--accent); background: rgba(var(--accent-rgb), .14); }
.pc-stats .pcs-ic svg { width: 16px; height: 16px; }
.pc-stats .pcs-ic.fire { color: #ff8a3d; background: rgba(255, 138, 61, .15); }
.pc-stats .pcs-ic.gold { color: #ffd36b; background: rgba(255, 211, 107, .15); }
/* Fila con selector ancho (p. ej. Sexo con tres opciones): el selector ocupa toda la fila bajo la etiqueta */
.crow.wide { grid-template-columns: 32px 1fr; }
.crow.wide > .seg { grid-column: 1 / -1; }
.crow .seg.sm span { white-space: nowrap; }
/* IMC: barra con extremos rojos y centro verde (punto ideal) */
.bmi-box { padding: 12px; border-radius: 14px; background: var(--surface-2); border: 1px solid var(--line); }
.bmi-head { display: flex; align-items: center; gap: 8px; }
.bmi-title { display: flex; align-items: center; gap: 6px; font-size: .8rem; font-weight: 700; color: var(--text-2); margin-right: auto; }
.bmi-title svg { width: 15px; height: 15px; color: var(--accent-text); }
.bmi-val { font-size: 1.3rem; font-variant-numeric: tabular-nums; }
.bmi-help { width: 24px; height: 24px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); color: var(--text-2); font-weight: 800; font-size: .8rem; display: grid; place-items: center; flex: none; }
.bmi-tag { font-size: .72rem; font-weight: 700; padding: 3px 8px; border-radius: 999px; white-space: nowrap; }
.bmi-tag.ok { color: #12b76a; background: rgba(18, 183, 106, .15); }
.bmi-tag.low, .bmi-tag.high { color: #f79009; background: rgba(247, 144, 9, .15); }
.bmi-tag.obese { color: #f04438; background: rgba(240, 68, 56, .15); }
.bmi-bar { position: relative; height: 12px; margin: 14px 0 6px; border-radius: 999px;
  background: linear-gradient(90deg, #f04438 0%, #f79009 18%, #12b76a 38%, #12b76a 62%, #f79009 82%, #f04438 100%); }
.bmi-ideal { position: absolute; left: 50%; top: -3px; bottom: -3px; width: 2px; margin-left: -1px; background: rgba(255, 255, 255, .85); border-radius: 2px; }
.bmi-mark { position: absolute; top: 50%; width: 20px; height: 20px; margin: -10px 0 0 -10px; border-radius: 50%; background: #fff; border: 4px solid #12b76a; box-shadow: 0 2px 8px rgba(0, 0, 0, .35); transition: left .5s cubic-bezier(.2, .8, .2, 1); }
.bmi-mark.low, .bmi-mark.high { border-color: #f79009; }
.bmi-mark.obese { border-color: #f04438; }
.bmi-scale { display: grid; grid-template-columns: 25% 50% 15% 10%; font-size: .62rem; color: var(--muted); }
.bmi-scale span { text-align: center; white-space: nowrap; }
.bmi-scale span:first-child { text-align: left; }
.bmi-scale span:last-child { text-align: right; }
.bmi-you.ok { border-color: rgba(18, 183, 106, .5); }
.bmi-you.low, .bmi-you.high { border-color: rgba(247, 144, 9, .5); }
.bmi-you.obese { border-color: rgba(240, 68, 56, .5); }
@media (prefers-reduced-motion: reduce) { .bmi-mark { transition: none; } }
/* Etiquetas de la escala del IMC colocadas en su zona (la última, un poco más abajo para no pisarse) */
.bmi-scale { position: relative; display: block; height: 26px; }
.bmi-scale span { position: absolute; top: 0; }
.bmi-scale span:nth-child(1) { left: 0; }
.bmi-scale span:nth-child(2) { left: 50%; transform: translateX(-50%); }
.bmi-scale span:nth-child(3) { left: 82.5%; transform: translateX(-50%); }
.bmi-scale span:nth-child(4) { right: 0; top: 12px; }
/* Guardar del perfil: oculto sin cambios; «Actualizado» después de guardar */
.save-btn[hidden] { display: none !important; }
.save-btn.done { opacity: 1; background: rgba(var(--accent-rgb), .14); color: var(--accent); border-color: transparent; cursor: default; }
.birth-field.compact label { font-size: .8rem; color: var(--muted); }
.birth-field.compact select { min-height: 38px; }

/* Mis sugerencias: modo selección */
.sug-bar { display: flex; align-items: center; gap: 10px; padding: 8px 10px; margin-bottom: 8px; border-radius: 12px; background: var(--surface-2); }
.sug-bar[hidden] { display: none; }
#my-sugs .sug-item { cursor: default; }
#my-sugs.selecting .sug-item { cursor: pointer; border-radius: 12px; }
#my-sugs .sug-item.on { background: rgba(var(--accent-rgb), .08); }
.sug-check { width: 20px; height: 20px; margin-top: 8px; accent-color: var(--accent); flex: none; }


/* v1.19: expositor por categorías */
.medal-shelf-cats { display: grid; gap: 14px; }
.msc-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; margin-bottom: 8px; font-size: .78rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--text-2); }
