/* Perfil de usuario */
.pf-hero { display: flex; align-items: center; gap: 1.4rem; flex-wrap: wrap; padding: 1.6rem; margin-bottom: 1.4rem; background: linear-gradient(135deg, var(--surface-2), var(--surface)); border: 1px solid var(--border-strong); border-radius: var(--radius); }
.pf-avatar-btn { position: relative; padding: 0; border: 0; border-radius: 50%; background: none; cursor: pointer; flex: none; }
.pf-avatar { display: block; width: 112px; height: 112px; border-radius: 50%; object-fit: cover; border: 3px solid var(--border-accent); box-shadow: 0 6px 22px rgba(0, 0, 0, .5); }
.pf-avatar-edit { position: absolute; left: 50%; bottom: -6px; transform: translateX(-50%); padding: .15rem .7rem; border-radius: 999px; background: var(--accent); color: #0b0805; font-size: var(--fs-xs); font-weight: 800; }
.pf-avatar-btn:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
.pf-id { flex: 1 1 260px; min-width: 0; }
.pf-id h1 { font-family: var(--font-display); font-weight: 400; font-size: var(--fs-h1); margin: 0 0 .5rem; color: var(--text-strong); }
.pf-badges { display: flex; gap: .5rem; flex-wrap: wrap; }

.pf-card { padding: 1.5rem; margin-bottom: 1.4rem; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.pf-card h2, .pf-h2, .pf-h3 { font-family: var(--font-display); font-weight: 400; color: var(--text-strong); margin: 0 0 .7rem; }
.pf-h2 { font-size: var(--fs-h2); margin-bottom: .3rem; }
.pf-h3 { font-size: var(--fs-h3); }
h1.pf-h3 { font-size: var(--fs-h1); } /* /amigos y /notificaciones: el título de la página es un h1 */
.pf-sub { font-size: 1rem; margin: 1.2rem 0 .5rem; color: var(--muted); font-weight: 700; }
.pf-lead { margin: 0 0 1rem; }
.pf-ok { border-color: rgba(127, 176, 105, .45); background: linear-gradient(180deg, var(--ok-dim), var(--surface) 70%); }
.pf-ban { border-color: rgba(155, 58, 58, .55); background: linear-gradient(180deg, var(--danger-dim), var(--surface) 70%); }
.pf-addr { display: flex; align-items: center; gap: .7rem; flex-wrap: wrap; padding: .7rem .8rem; margin: .8rem 0; background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-sm); max-width: 480px; }
.pf-addr code { flex: 1; font-size: var(--fs-lg); background: transparent; padding: 0; overflow-wrap: anywhere; }

.pf-ways { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.2rem; margin-bottom: 1.4rem; }
.pf-way { display: flex; flex-direction: column; gap: .6rem; padding: 1.5rem; border-radius: var(--radius); border: 1px solid var(--border); background: var(--surface); }
.pf-way h3 { font-family: var(--font-display); font-weight: 400; font-size: 1.4rem; margin: 0; color: var(--text-strong); }
.pf-way p { margin: 0; }
.pf-way-auto { border-color: rgba(127, 176, 105, .55); background: linear-gradient(170deg, rgba(127, 176, 105, .1), var(--surface) 55%); }
.pf-way-manual { border-style: dashed; border-color: var(--border-strong); }
.pf-way .btn { align-self: flex-start; }
.pf-tag { align-self: flex-start; padding: .2rem .7rem; border-radius: 999px; font-size: var(--fs-xs); font-weight: 800; border: 1px solid; }
.pf-tag-auto { color: #bfe3b2; border-color: rgba(127, 176, 105, .6); }
.pf-tag-manual { color: var(--warn); border-color: rgba(217, 164, 65, .55); }
.pf-form { display: grid; gap: .2rem; }
.pf-ids { list-style: none; display: grid; gap: .5rem; padding: 0; margin: 0 0 1rem; }
.pf-ids li { display: flex; align-items: center; gap: .8rem; flex-wrap: wrap; padding: .55rem .8rem; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius-sm); }
.pf-ids li > span:first-child { min-width: 6.5rem; font-weight: 700; color: var(--muted); }
.pf-ids .inline { margin-left: auto; }
.pf-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.2rem; align-items: start; }
.pf-dl { display: grid; grid-template-columns: auto 1fr; gap: .5rem 1.2rem; margin: 0; }
.pf-dl dt { color: var(--muted); }
.pf-dl dd { margin: 0; }


@media (max-width: 800px) { .pf-ways { grid-template-columns: 1fr; } .pf-actions { width: 100%; } }

/* ---- Rediseño del perfil (v22.11) ---- */
.pf-handle { margin: 0 0 .15rem; font-weight: 700; color: var(--accent); letter-spacing: .02em; }
.pf-sub-id { margin: -.25rem 0 .6rem; font-size: var(--fs-sm); }
.pf-country { display: inline-flex; align-items: center; gap: .35rem; }
.pf-actions { display: flex; gap: .6rem; flex-wrap: wrap; align-items: center; }
.pf-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 1.4rem; align-items: start; }
.pf-nav { position: sticky; top: 92px; display: flex; flex-direction: column; gap: .15rem; padding: .6rem; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.pf-nav a { padding: .55rem .8rem; border-radius: var(--radius-sm); color: var(--muted); text-decoration: none; font-weight: 600; }
.pf-nav a:hover, .pf-nav a:focus-visible { background: var(--surface-2); color: var(--text-strong); }
.pf-main { min-width: 0; }
.pf-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .8rem; margin: 0; }
.pf-stats > div { padding: .8rem 1rem; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius-sm); }
.pf-stats dt { font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .06em; color: var(--muted-dark); margin-bottom: .25rem; }
.pf-stats dd { margin: 0; font-size: 1.25rem; font-weight: 700; color: var(--text-strong); overflow-wrap: anywhere; }
.pf-stats dd small { display: block; font-size: var(--fs-xs); font-weight: 400; }
.pf-switches { gap: .7rem; }
.pf-switch { display: flex; align-items: flex-start; gap: .7rem; cursor: pointer; }
.pf-switch input { flex: none; width: 1.15rem; height: 1.15rem; margin-top: .15rem; accent-color: var(--accent); }
.pf-public { max-width: 820px; margin: 0 auto; }
.pf-hero-public { margin-top: 0; }
@media (max-width: 900px) {
  .pf-layout { grid-template-columns: 1fr; }
  .pf-nav { position: static; flex-direction: row; flex-wrap: wrap; }
}
/* Ajustes de la cuenta: la sección abierta queda marcada en el menú lateral */
.pf-nav a.is-active { background: var(--accent-dim); color: var(--accent-hover); box-shadow: inset 3px 0 0 var(--accent); }
@media (max-width: 900px) { .pf-nav a.is-active { box-shadow: none; } }
/* ---- Perfil: una sola plantilla para dueño, staff y visitante (responsive) ---- */
.pf-viewbar { display: flex; align-items: center; justify-content: space-between; gap: .8rem 1rem; flex-wrap: wrap; padding: .7rem 1rem; margin-bottom: 1rem; background: var(--accent-dim); border: 1px solid rgba(201, 151, 75, .35); border-radius: var(--radius-sm); font-size: var(--fs-sm); }
.pf-viewbar.is-preview { background: var(--surface-2); border-style: dashed; border-color: var(--border-strong); }
.pf-viewbar.is-staff { background: rgba(127, 176, 105, .1); border-color: rgba(127, 176, 105, .4); }
.vis-chip { display: inline-block; margin-left: .4rem; padding: .05rem .55rem; border-radius: 999px; font-size: var(--fs-2xs); font-weight: 700; vertical-align: middle; white-space: nowrap; }
.vis-chip.is-public { color: #bfe3b2; background: rgba(127, 176, 105, .14); border: 1px solid rgba(127, 176, 105, .45); }
.vis-chip.is-private { color: var(--warn); background: rgba(217, 164, 65, .12); border: 1px solid rgba(217, 164, 65, .45); }
.pf-private { border-style: dashed; border-color: rgba(217, 164, 65, .4); }
.pf-dl-wide { grid-template-columns: minmax(7.5rem, max-content) minmax(0, 1fr); }
.pf-dl dd { min-width: 0; overflow-wrap: anywhere; }
.pf-grid { grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); }
.pf-grid-private { margin-bottom: 0; }
@media (max-width: 560px) {
  .pf-hero { padding: 1.2rem; justify-content: center; text-align: center; }
  .pf-id { flex-basis: 100%; }
  .pf-badges, .pf-actions { justify-content: center; }
  .pf-actions { width: 100%; }
  .pf-actions .btn { flex: 1 1 auto; }
  .pf-dl-wide { grid-template-columns: 1fr; gap: .15rem 0; }
  .pf-dl-wide dt { margin-top: .6rem; font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .05em; }
  .pf-viewbar { flex-direction: column; align-items: stretch; }
  .pf-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
/* ---- Perfil estilo red social ---- */
.tone-gold { --tone: var(--tone-gold); }
.tone-red { --tone: var(--tone-red); }
.tone-orange { --tone: #e08a3c; }
.tone-green { --tone: var(--tone-green); }
.tone-teal { --tone: #4fb3a8; }
.tone-blue { --tone: #5b8fd6; }
.tone-purple { --tone: #9b72d6; }
.tone-slate { --tone: #9aa0a8; }
.tone-rose { --tone: #d6638f; }
.tone-ice { --tone: #82c4e6; }
.bar-h0 { height: 0%; }
.bar-h1 { height: 5%; }
.bar-h2 { height: 10%; }
.bar-h3 { height: 15%; }
.bar-h4 { height: 20%; }
.bar-h5 { height: 25%; }
.bar-h6 { height: 30%; }
.bar-h7 { height: 35%; }
.bar-h8 { height: 40%; }
.bar-h9 { height: 45%; }
.bar-h10 { height: 50%; }
.bar-h11 { height: 55%; }
.bar-h12 { height: 60%; }
.bar-h13 { height: 65%; }
.bar-h14 { height: 70%; }
.bar-h15 { height: 75%; }
.bar-h16 { height: 80%; }
.bar-h17 { height: 85%; }
.bar-h18 { height: 90%; }
.bar-h19 { height: 95%; }
.bar-h20 { height: 100%; }
.ico { flex: none; vertical-align: middle; }
.ico-inline { margin-right: .35rem; color: var(--accent); }
.sp { max-width: 1040px; margin: 0 auto; }
.sp-top { position: relative; overflow: hidden; margin-bottom: 1.2rem; background: var(--surface); border: 1px solid var(--border-strong); border-radius: var(--radius-lg); }
.sp-cover { height: 168px; background: linear-gradient(180deg, rgba(15, 11, 9, .15), rgba(15, 11, 9, .75)), url("/site/banner") center 35% / cover no-repeat; border-bottom: 1px solid var(--border); }
.sp-headrow { display: flex; align-items: flex-end; gap: 1.2rem; flex-wrap: wrap; padding: 0 1.5rem; margin-top: -68px; }
.sp-avatar { display: block; flex: none; width: 136px; height: 136px; border-radius: 50%; object-fit: cover; background: var(--surface); border: 4px solid var(--surface); box-shadow: 0 0 0 2px var(--border-accent), 0 10px 26px rgba(0, 0, 0, .55); }
.sp-id { flex: 1 1 260px; min-width: 0; padding-bottom: .4rem; }
.sp-id h1 { margin: 0; font-family: var(--font-title); font-weight: 400; font-size: clamp(1.25rem, 6.2cqw, calc(var(--fs-h1) * .85)); color: var(--text-strong); line-height: 1.15; letter-spacing: .03em; -webkit-text-stroke: .03em currentColor; text-transform: uppercase; }
.sp-handle { margin: .15rem 0 .6rem; font-weight: 700; color: var(--accent); letter-spacing: .02em; }
.sp-actions { display: flex; gap: .6rem; flex-wrap: wrap; padding-bottom: .5rem; }
.sp-ico { display: grid; place-items: center; flex: none; width: 48px; height: 48px; border-radius: var(--radius-lg); color: var(--tone, var(--accent)); background: rgba(255, 255, 255, .04); border: 1px solid color-mix(in srgb, var(--tone, var(--accent)) 55%, transparent); box-shadow: inset 0 0 14px color-mix(in srgb, var(--tone, var(--accent)) 18%, transparent); }
.sp-stat-t { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.sp-stat-t strong { font-size: var(--fs-lg); color: var(--text-strong); overflow-wrap: anywhere; }
.sp-stat-t small { font-size: var(--fs-xs); }
.sp-k { font-size: var(--fs-2xs); text-transform: uppercase; letter-spacing: .07em; color: var(--muted-dark); }
.sp-body { display: grid; grid-template-columns: minmax(0, 340px) minmax(0, 1fr); gap: 1.2rem; align-items: start; }
.sp-side, .sp-main { display: grid; gap: 1.2rem; min-width: 0; }
.sp-side .pf-card, .sp-main .pf-card { margin-bottom: 0; }
.act-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: .7rem; list-style: none; margin: 0 0 .4rem; padding: 0; }
.act-tiles li { display: flex; flex-direction: column; gap: .2rem; padding: .7rem .85rem; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius-sm); }
.act-tiles strong { font-size: var(--fs-lg); color: var(--text-strong); }
.act-chart { display: grid; grid-template-columns: repeat(14, minmax(0, 1fr)); gap: .3rem; align-items: end; height: 150px; list-style: none; margin: .4rem 0 .6rem; padding: .6rem .5rem .2rem; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius-sm); }
.act-day { display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: .3rem; height: 100%; min-width: 0; }
.act-bar { display: block; width: 100%; max-width: 22px; min-height: 3px; border-radius: 4px 4px 0 0; background: var(--border-strong); }
.act-day.has .act-bar { background: linear-gradient(180deg, var(--accent-hover), var(--accent)); }
.act-day:not(.has) .act-bar { height: 3px; }
.act-lbl { font-size: var(--fs-2xs); color: var(--muted-dark); }
.act-sessions { list-style: none; margin: 0; padding: 0; display: grid; gap: .4rem; }
.act-sessions li { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding: .5rem .8rem; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius-sm); }
@media (max-width: 860px) {
  .sp-body { grid-template-columns: 1fr; }
  .sp-cover { height: 130px; }
}
@media (max-width: 560px) {
  .sp-headrow { justify-content: center; text-align: center; padding: 0 1rem; margin-top: -60px; }
  .sp-avatar { width: 112px; height: 112px; }
  .sp-id { flex-basis: 100%; }
  .sp-id .pf-badges, .sp-actions { justify-content: center; }
  .sp-actions { width: 100%; }
  .sp-actions .btn { flex: 1 1 auto; }
  .act-chart { height: 120px; gap: .15rem; padding: .5rem .3rem .2rem; }
  .act-lbl { font-size: var(--fs-2xs); }
}
/* Selector de icono y color del clan (ajustes) */
.pick-set { border: 0; margin: 0 0 1.1rem; padding: 0; min-width: 0; }
.pick-set legend { padding: 0; margin-bottom: .5rem; font-weight: 700; color: var(--muted); }
.pick-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(86px, 1fr)); gap: .6rem; }
.pick { position: relative; display: flex; flex-direction: column; align-items: center; gap: .35rem; padding: .6rem .3rem; text-align: center; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius-sm); cursor: pointer; }
.pick input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.pick:hover { border-color: var(--border-strong); }
.pick:has(input:checked) { border-color: var(--accent); background: var(--accent-dim); }
.pick:has(input:focus-visible) { outline: 2px solid var(--accent-hover); outline-offset: 2px; }
.pick-box { display: grid; place-items: center; width: 46px; height: 46px; border-radius: var(--radius); color: var(--tone, var(--accent)); border: 1px solid var(--border-strong); }
.pick-sw { width: 34px; height: 34px; border-radius: 50%; background: var(--tone, var(--accent)); box-shadow: 0 0 0 2px var(--surface), 0 0 0 3px var(--border-strong); }
.pick-n { font-size: var(--fs-xs); color: var(--muted); }
@supports not (color: color-mix(in srgb, red 50%, blue)) { .sp-ico { border: 1px solid var(--border-strong); } }
/* Emblemas de los dioses (medallones con transparencia): sin la caja del icono genérico */
.sp-ico.sp-ico-img { width: 56px; height: 56px; background: none; border: 0; box-shadow: none; }
.god-img { display: block; width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 2px 4px rgba(0, 0, 0, .55)); }
/* ---- Portada, marcos del staff y muro de comentarios ---- */
.sp-cover { position: relative; }
.sp-cover-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.sp-cover::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(15, 11, 9, .1), rgba(15, 11, 9, .72)); pointer-events: none; }
.sp-cover-tools { position: absolute; top: .8rem; right: .8rem; z-index: 2; display: flex; gap: .5rem; flex-wrap: wrap; justify-content: flex-end; }
.sp-cover-tools .btn { background: rgba(15, 11, 9, .72); backdrop-filter: blur(3px); }

.av-img { display: block; border-radius: 50%; object-fit: cover; background: var(--surface); }
.av-lg { flex: none; position: relative; display: block; border-radius: 50%; }
.av-lg.av-plain .av-img { border: 4px solid var(--surface); box-shadow: 0 0 0 2px var(--border-accent), 0 10px 26px rgba(0, 0, 0, .55); }
.av-sm.av-plain { display: block; flex: none; }
.av-sm.av-plain .av-img { border: 2px solid var(--border-strong); }
.av-frame { position: relative; display: inline-block; flex: none; border-radius: 50%; }
.av-frame.av-lg { padding: 7px; }
.av-frame.av-sm { padding: 3px; }
.av-frame .av-img { border: 3px solid #120c08; }
.av-frame.av-sm .av-img { border-width: 2px; }
.frame-admin { background: conic-gradient(from 20deg, #f6dc8a, #b07a1c, #fff2b8, #8a5a12, #f6dc8a); box-shadow: 0 0 0 2px #2d1d07, 0 0 24px rgba(224, 180, 74, .55), 0 10px 26px rgba(0, 0, 0, .55); }
.frame-mod { background: conic-gradient(from 20deg, #dfe6ef, #6a788c, #f3f6fa, #4a5668, #dfe6ef); box-shadow: 0 0 0 2px #151c26, 0 0 20px rgba(130, 165, 210, .45), 0 10px 26px rgba(0, 0, 0, .5); }
/* adorno superior (rombo) y medalla del rol */
.av-frame::before { content: ""; position: absolute; left: 50%; top: -9px; z-index: 1; width: 16px; height: 16px; transform: translateX(-50%) rotate(45deg); border: 2px solid #2d1d07; }
.frame-admin::before { background: linear-gradient(135deg, #fff2b8, #b07a1c); }
.frame-mod::before { background: linear-gradient(135deg, #f3f6fa, #4a5668); border-color: #151c26; }
.av-frame.av-sm::before { top: -5px; width: 9px; height: 9px; border-width: 1px; }
.av-medal { position: absolute; right: -4px; bottom: -4px; z-index: 2; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: #150e08; border: 2px solid currentColor; }
.frame-admin .av-medal { color: #f0cd6a; }
.frame-mod .av-medal { color: #c4d2e4; }
.av-frame.av-sm .av-medal { width: 20px; height: 20px; border-width: 1px; right: -3px; bottom: -3px; }
.badge-role { display: inline-flex; align-items: center; gap: .3rem; font-weight: 800; }
.badge-frame-admin { color: #f6dc8a; background: linear-gradient(180deg, rgba(176, 122, 28, .38), rgba(60, 40, 10, .65)); border: 1px solid #b07a1c; }
.badge-frame-mod { color: #dfe6ef; background: linear-gradient(180deg, rgba(106, 120, 140, .42), rgba(30, 38, 50, .75)); border: 1px solid #6a788c; }

.wall-count { font-size: var(--fs-sm); }
.wall-form textarea { width: 100%; min-height: 72px; resize: vertical; }
.wall-form-row { display: flex; align-items: center; gap: .6rem .8rem; flex-wrap: wrap; margin-top: .5rem; }
.wall-counter { margin-right: auto; }
.wall-err { flex: 1 1 200px; order: 3; min-width: 0; color: var(--danger-text); font-size: var(--fs-sm); }
.wall-why { margin: 0 0 .5rem; }
.wall-list, .wc-replies { list-style: none; margin: 0; padding: 0; display: grid; gap: .8rem; }
.wall-list { margin-top: 1rem; }
.wall-list[aria-busy="true"] { opacity: .65; transition: opacity .15s ease; }
.wc { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: .75rem; padding: .85rem; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius); scroll-margin-top: 6rem; }
.wc-reply { background: var(--surface); padding: .65rem .75rem; }
.wc-main { min-width: 0; }
.wc-head { display: flex; align-items: center; gap: .3rem .6rem; flex-wrap: wrap; }
.wc-name { font-weight: 700; color: var(--accent); text-decoration: none; }
.wc-name:hover { text-decoration: underline; }
.wc-clan { display: inline-flex; align-items: center; gap: .3rem; font-size: var(--fs-xs); color: var(--tone, var(--muted)); }
.wc-time { margin-left: auto; font-size: var(--fs-xs); }
.wc-body { margin: .35rem 0 .2rem; overflow-wrap: anywhere; }
.wc-actions { display: flex; gap: 1rem; }
.wc-btn { padding: .2rem 0; min-height: 32px; background: none; border: 0; color: var(--muted); font: inherit; font-size: var(--fs-xs); font-weight: 700; cursor: pointer; }
.wc-btn:hover, .wc-btn:focus-visible { color: var(--accent-hover); }
.wc-del:hover, .wc-del:focus-visible { color: var(--danger-text); }
.wc-replies { margin-top: .7rem; padding-left: .8rem; border-left: 2px solid var(--border); }
.wc-replies:empty { display: none; }
.wc-fold, .wc-empty, .wc-replyform { list-style: none; }
.wc-empty { padding: 1rem; text-align: center; }
.wc[hidden] { display: none; }
.wall-pager { display: flex; align-items: center; justify-content: center; gap: .35rem; flex-wrap: wrap; margin-top: 1rem; }
.pg { min-width: 40px; height: 40px; padding: 0 .6rem; background: var(--surface-2); border: 1px solid var(--border-strong); border-radius: var(--radius); color: var(--text); font: inherit; cursor: pointer; }
.pg:hover:not(:disabled) { border-color: var(--accent); }
.pg.is-cur { background: var(--accent-dim); border-color: var(--accent); color: var(--accent-hover); font-weight: 800; }
.pg:disabled { opacity: .4; cursor: default; }
.pg-gap { color: var(--muted); }
.pg-info { display: none; padding: 0 .5rem; color: var(--muted); font-size: var(--fs-sm); }
@media (max-width: 559px) { .pg-n, .pg-gap { display: none; } .pg-info { display: inline; } .wc { padding: .7rem; gap: .6rem; } }

@media (max-width: 560px) { .sp-headrow .av-lg .av-img { width: 112px; height: 112px; } .av-medal { width: 28px; height: 28px; } }

/* Muro: denunciar / bloquear y lista de bloqueos */
.wc-panel { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; margin-top: .5rem; padding: .6rem; border: 1px solid var(--border-strong); border-radius: var(--radius); background: rgba(0, 0, 0, .25); }
.wc-panel select, .wc-panel input { min-width: 0; flex: 1 1 160px; }
.pf-blocks { list-style: none; margin: .5rem 0; padding: 0; display: grid; gap: .4rem; }
.pf-blocks li { display: flex; justify-content: space-between; align-items: center; gap: .6rem; flex-wrap: wrap; }
/* Página de notificaciones */
.np-filters { display: flex; gap: .5rem; flex-wrap: wrap; margin: .8rem 0; }
.np-filter { padding: .4rem .9rem; border: 1px solid var(--border-strong); border-radius: 999px; color: var(--text); text-decoration: none; }
.np-filter.is-cur { background: var(--accent-dim); border-color: var(--accent); color: var(--text-strong); }
.np-bar { display: flex; justify-content: space-between; align-items: center; gap: .6rem; flex-wrap: wrap; padding: .5rem 0; }
.np-bulk, .np-row-actions { display: inline-flex; gap: .35rem; flex-wrap: wrap; }
.np-list { list-style: none; margin: 0; padding: 0; border: 1px solid var(--border-strong); border-radius: var(--radius); overflow: hidden; }
.np-item { display: flex; align-items: center; gap: .7rem; padding: .7rem .8rem; border-bottom: 1px solid var(--border); }
.np-item:last-child { border-bottom: 0; }
.np-item.unread { background: var(--accent-dim); }
.np-item.unread .np-title { font-weight: 600; color: var(--text-strong); }
.np-main { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: .15rem; }
.np-title { color: var(--text); overflow-wrap: anywhere; }
.np-type { color: var(--accent); }
.np-global { display: flex; gap: .5rem; flex-wrap: wrap; margin-top: 1rem; }
.np-empty { padding: 1rem 0; }
a.pg { display: inline-flex; align-items: center; justify-content: center; text-decoration: none; }
.pg.is-cur { border-color: var(--accent); background: var(--accent-dim); }
@media (max-width: 600px) { .np-item { flex-wrap: wrap; } .np-row-actions { width: 100%; padding-left: 1.7rem; } }

/* Diálogo «Integrantes del clan» y distintivo de clan clicable */
.sp-stat-btn { width: 100%; font: inherit; color: inherit; text-align: left; cursor: pointer; transition: border-color .18s ease, background-color .18s ease; }
.sp-stat-btn:hover, .sp-stat-btn:focus-visible { border-color: var(--accent); background: var(--surface-2); }
.sp-stat-btn:focus-visible { outline: 2px solid var(--accent-hover); outline-offset: 2px; }
/* Tarjeta del clan: el nombre ocupa todo el ancho (se parte por palabras, nunca por letras); rango en pastilla y acción debajo */
.sp-stat-btn .sp-stat-t { flex: 1; }
.sp-clan-name { overflow-wrap: break-word; word-break: normal; hyphens: manual; line-height: 1.2; }
.sp-clan-meta { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem .6rem; margin-top: .4rem; }
.sp-rank { padding: .08rem .5rem; border: 1px solid var(--border-accent); border-radius: 4px; background: var(--accent-dim); color: var(--accent-hover); font-size: var(--fs-2xs); font-weight: 700; letter-spacing: .03em; }
.sp-stat-go { display: inline-flex; align-items: center; gap: .25rem; color: var(--accent-hover); font-size: var(--fs-xs); font-weight: 600; white-space: nowrap; }
.sp-stat-go::after { content: ""; width: 6px; height: 6px; border-top: 2px solid currentColor; border-right: 2px solid currentColor; transform: rotate(45deg); transition: transform .18s ease; }
.sp-stat-btn:hover .sp-stat-go::after, .sp-stat-btn:focus-visible .sp-stat-go::after { transform: translateX(3px) rotate(45deg); }
@media (prefers-reduced-motion: reduce) { .sp-stat-go::after { transition: none; } }
.wc-clan { font: inherit; font-size: var(--fs-xs); border: 0; background: none; padding: 0; cursor: pointer; text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 3px; }
.wc-clan:hover, .wc-clan:focus-visible { text-decoration-color: currentColor; }
.cm-box { max-width: 640px; padding: 0; overflow: hidden; display: flex; flex-direction: column; max-height: min(86dvh, 720px); }
.cm-head { display: flex; align-items: center; gap: .9rem; padding: 1.25rem 1.4rem 1rem; border-bottom: 1px solid var(--border); }
.cm-ico { display: grid; place-items: center; flex: none; width: 52px; height: 52px; border-radius: var(--radius-lg); color: var(--tone, var(--accent)); background: rgba(255, 255, 255, .04); border: 1px solid var(--border-strong); }
.cm-head h2 { margin: 0; font: 400 1.5rem/1.2 var(--font-title); letter-spacing: .03em; -webkit-text-stroke: .03em currentColor; text-transform: uppercase; color: var(--text-strong); overflow-wrap: anywhere; }
.cm-head p { margin: .1rem 0 0; font-size: var(--fs-sm); color: var(--muted); }
.cm-list { list-style: none; margin: 0; padding: .5rem; overflow-y: auto; overscroll-behavior: contain; }
.cm-item + .cm-item { margin-top: .15rem; }
.cm-row { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto auto; align-items: center; gap: .8rem; padding: .55rem .75rem; border-radius: var(--radius); color: inherit; text-decoration: none; }
a.cm-row:hover, a.cm-row:focus-visible { background: var(--surface-2); }
a.cm-row:focus-visible { outline: 2px solid var(--accent-hover); outline-offset: -2px; }
.cm-av { display: grid; place-items: center; width: 44px; height: 44px; }
.cm-av-none { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--surface-3); border: 1px dashed var(--border-strong); color: var(--muted); font-weight: 700; }
.cm-main { display: grid; min-width: 0; line-height: 1.25; }
.cm-name { font: 400 1.1rem/1.25 var(--font-title); letter-spacing: .03em; -webkit-text-stroke: .02em currentColor; color: var(--text-strong); overflow-wrap: anywhere; }
.cm-user { font-size: var(--fs-xs); overflow-wrap: anywhere; }
.cm-lvl { display: grid; text-align: right; line-height: 1.2; }
.cm-lvl .sp-k { font-size: var(--fs-2xs); text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.cm-rank { min-width: 4.8rem; padding: .2rem .6rem; border: 1px solid var(--border-strong); border-radius: 999px; text-align: center; font-size: var(--fs-xs); font-weight: 700; color: var(--muted); }
.cm-rank.is-leader { color: var(--accent-hover); border-color: rgba(201, 151, 75, .55); background: var(--accent-dim); }
.cm-empty { padding: 1.5rem 1rem; text-align: center; }
.cm-foot { margin: 0; padding: .75rem 1.4rem 1.1rem; border-top: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; font-size: var(--fs-xs); }
@media (max-width: 520px) {
  .cm-row { grid-template-columns: 40px minmax(0, 1fr) auto; }
  .cm-rank { grid-column: 2 / -1; justify-self: start; min-width: 0; }
  .cm-lvl { text-align: right; }
}
.sp-stats > li { display: flex; min-width: 0; }
.sp-stats > li > .sp-stat { flex: 1; }
.cm-item a.cm-row, .cm-item .cm-row { text-decoration: none; }
.cm-row .cm-name, .cm-row .cm-lvl strong { text-decoration: none; }

/* Logo propio del clan: rellena el recuadro del icono (sin fondo ni borde) */
.clan-logo { display: block; width: 100%; height: 100%; object-fit: cover; border-radius: inherit; }
.sp-ico:has(.clan-logo), .cm-ico:has(.clan-logo) { padding: 0; overflow: hidden; background: none; box-shadow: none; }
.wc-clan .clan-logo { width: 18px; height: 18px; border-radius: 4px; }
.cm-ico:has(.clan-logo) { width: 60px; height: 60px; }
.clan-pickrow { display: flex; flex-wrap: wrap; align-items: flex-end; gap: .8rem; margin-bottom: 1rem; }
.clan-pickrow .field { flex: 1 1 14rem; margin: 0; }
.clan-logo-row { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.25rem; margin: .4rem 0 1.4rem; padding: 1rem; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius-lg); }
.clan-logo-row .clan-logo-prev { width: 88px; height: 88px; border-radius: 16px; }
.clan-logo-row .clan-logo-prev svg { width: 40px; height: 40px; }
.clan-logo-txt { display: flex; flex-direction: column; align-items: flex-start; gap: .4rem; flex: 1 1 16rem; min-width: 0; }.clan-logo-prev:has(.clan-logo) > svg { display: none; }

/* ---------- Columna lateral del perfil: cada dato como «etiqueta arriba, valor debajo», con separadores (se lee igual de estrecha o ancha) ---------- */
.sp-body { margin-bottom: 1.8rem; }
.sp-side .pf-dl, .sp-side .pf-dl-wide { grid-template-columns: minmax(0, 1fr); gap: 0; }
.sp-side .pf-dl dt { margin: 0; padding: .8rem 0 .2rem; border-top: 1px solid var(--border); font-size: var(--fs-2xs); font-weight: 600; text-transform: uppercase; letter-spacing: .07em; color: var(--muted-dark); }
.sp-side .pf-dl dt:first-child { padding-top: 0; border-top: 0; }
.sp-side .pf-dl dd { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem .55rem; padding-bottom: .1rem; color: var(--text); }
.sp-side .pf-dl dd .vis-chip { margin-left: 0; }
.sp-side .pf-dl dd small { flex-basis: 100%; }
.sp-side .pf-dl dd code { font-size: var(--fs-sm); }
.sp-side .pf-dl dd abbr { color: var(--muted); font-size: var(--fs-xs); }
.sp-side .pf-private > .muted.small { margin: 0 0 1rem; }

/* Amigos: cabecera, aviso y botón con aire; el botón no ocupa todo el ancho */
.fr-box { display: flex; flex-direction: column; align-items: flex-start; }
.fr-box .fr-box-top { width: 100%; }
.fr-box > p { margin: 0 0 1rem; }
.fr-box .fr-chips { margin-bottom: 1rem; }

/* Muro: contador a la izquierda y «Publicar» a la derecha (el hueco del mensaje de error solo existe cuando hay error) */
.wall-err:empty { display: none; }
.wall-form-row .btn { margin-left: auto; }

/* Historial: las cifras de las cuatro casillas quedan alineadas abajo aunque una etiqueta ocupe dos líneas */
.act-tiles li { justify-content: space-between; gap: .45rem; }
.act-tiles .sp-k { line-height: 1.3; }

/* =====================================================================
   DIÁLOGO DEL CLAN: más grande, con el logo en la cabecera (pulsable para verlo a tamaño completo)
   ===================================================================== */
.cm-box { max-width: min(860px, 100%); max-height: min(92dvh, 880px); background: linear-gradient(180deg, #2a2017 0%, #1b140e 100%); border-color: var(--border-strong); border-radius: var(--radius); }
.cm-head { gap: clamp(1rem, 2.5vw, 1.6rem); padding: clamp(1.1rem, 3vw, 1.75rem) clamp(1.1rem, 3vw, 1.9rem); position: relative; }
.cm-head::after { content: ""; position: absolute; left: clamp(1.1rem, 3vw, 1.9rem); bottom: -1px; width: 64px; height: 3px; background: var(--accent); border-radius: 3px 3px 0 0; }
.cm-head-t { min-width: 0; }
.cm-head h2 { font-family: var(--font-title); font-weight: 400; font-size: clamp(1.5rem, 1.2vw + 1.1rem, 2.1rem); line-height: 1.15; letter-spacing: .03em; }
.cm-head p { margin: .3rem 0 0; font-size: var(--fs-md); }
.cm-head .cm-hint { margin-top: .5rem; }
.cm-ico { width: clamp(84px, 14vw, 128px); height: clamp(84px, 14vw, 128px); border-radius: 16px; box-shadow: inset 0 0 22px rgba(0, 0, 0, .35); }
.cm-ico svg { width: 52%; height: 52%; }
.cm-ico:has(.clan-logo), .cm-ico.has-logo { width: clamp(84px, 14vw, 128px); height: clamp(84px, 14vw, 128px); border: 1px solid var(--border-accent); background: #120d09; }
.cm-logo-btn { position: relative; display: block; width: 100%; height: 100%; padding: 0; border: 0; border-radius: inherit; background: none; cursor: zoom-in; overflow: hidden; }
.cm-logo-btn::after { content: ""; position: absolute; right: 6px; bottom: 6px; width: 24px; height: 24px; border-radius: 50%; background: rgba(15, 11, 9, .78) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23e8b86b' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='6'/%3E%3Cpath d='m20 20-4-4M11 8v6M8 11h6'/%3E%3C/svg%3E") center / 15px no-repeat; opacity: 0; transition: opacity .18s ease; }
.cm-logo-btn:hover::after, .cm-logo-btn:focus-visible::after { opacity: 1; }
.cm-logo-btn:focus-visible { outline: 2px solid var(--accent-hover); outline-offset: 2px; }
.cm-logo-btn .clan-logo { transition: transform .25s ease; }
.cm-logo-btn:hover .clan-logo { transform: scale(1.05); }
.cm-list { padding: .6rem clamp(.6rem, 2vw, 1rem); }
.cm-row { grid-template-columns: 48px minmax(0, 1fr) auto auto; gap: clamp(.7rem, 2vw, 1.1rem); padding: .7rem .9rem; }
.cm-name { font-size: var(--fs-lg); }
.cm-rank { min-width: 5.4rem; }
.cm-foot { padding: .9rem clamp(1.1rem, 3vw, 1.9rem) 1.2rem; font-size: var(--fs-sm); }

/* Visor del logo a tamaño completo */
.cm-lightbox { position: fixed; inset: 0; z-index: 1100; display: grid; place-items: center; padding: clamp(1rem, 4vw, 2.5rem); background: rgba(8, 5, 3, .9); cursor: zoom-out; animation: cm-fade .18s ease; }
.cm-lightbox[hidden] { display: none; }
.cm-lb-fig { position: relative; display: grid; gap: .9rem; justify-items: center; margin: 0; padding: clamp(.7rem, 2vw, 1.1rem); background: linear-gradient(180deg, #2a2017, #15100c); border: 1px solid var(--border-strong); border-radius: var(--radius); box-shadow: 0 28px 70px rgba(0, 0, 0, .7), 0 0 90px rgba(201, 151, 75, .14); cursor: default; }
.cm-lb-fig::before, .cm-lb-fig::after { content: ""; position: absolute; width: 28px; height: 28px; border: 2px solid var(--accent); pointer-events: none; }
.cm-lb-fig::before { top: -7px; left: -7px; border-right: 0; border-bottom: 0; }
.cm-lb-fig::after { bottom: -7px; right: -7px; border-left: 0; border-top: 0; }
.cm-lb-img { display: block; width: min(76vmin, 560px); height: min(76vmin, 560px); object-fit: contain; border-radius: 4px; background: #0a0705; }
.cm-lb-cap { font-family: var(--font-display); font-size: clamp(1.2rem, 1vw + 1rem, 1.6rem); color: var(--text-strong); text-align: center; overflow-wrap: anywhere; }
.cm-lb-close { position: absolute; top: clamp(.6rem, 2vw, 1.2rem); right: clamp(.6rem, 2vw, 1.2rem); display: grid; place-items: center; width: 46px; height: 46px; padding: 0; border: 1px solid var(--border-strong); border-radius: 50%; background: rgba(28, 22, 16, .9); color: var(--text-strong); font-size: 1.7rem; line-height: 1; cursor: pointer; transition: var(--transition); }
.cm-lb-close:hover { border-color: var(--accent); color: var(--accent-hover); }
.cm-lb-close:focus-visible { outline: 2px solid var(--accent-hover); outline-offset: 2px; }
@keyframes cm-fade { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .cm-lightbox { animation: none; } .cm-logo-btn .clan-logo { transition: none; } }
@media (max-width: 560px) {
  .cm-head { align-items: flex-start; }
  .cm-row { grid-template-columns: 44px minmax(0, 1fr) auto; }
}
.cm-foot-btns { display: inline-flex; flex-wrap: wrap; gap: .5rem; }
.cm-foot-btns [hidden] { display: none; }


/* =====================================================================
   Cabecera del perfil: a la izquierda la situación en el servidor (whitelist / baneado / pendiente);
   a la derecha, en una columna aparte, si está en línea o desconectado y las acciones
   ===================================================================== */
.sp-right { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: .6rem 1rem; margin-left: auto; padding-bottom: .5rem; }
.sp-right .sp-actions { padding-bottom: 0; justify-content: flex-end; }
.sp-live { display: inline-flex; align-items: center; gap: .55rem; min-height: 36px; padding: .35rem .95rem; border: 1px solid var(--border-strong); border-radius: 999px; background: rgba(0, 0, 0, .28); color: var(--muted); font-size: var(--fs-xs); font-weight: 800; letter-spacing: .07em; white-space: nowrap; }
.sp-live i { position: relative; flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--muted-dark); }
.sp-live.is-on { color: #c9e8bb; border-color: rgba(127, 176, 105, .6); background: var(--ok-dim); }
.sp-live.is-on i { background: var(--ok); box-shadow: 0 0 0 3px rgba(127, 176, 105, .22); }
.sp-live.is-on i::after { content: ""; position: absolute; inset: 0; border-radius: 50%; background: rgba(127, 176, 105, .6); animation: sp-live-ping 2s ease-out infinite; }
.sp-live.is-off i { background: transparent; border: 2px solid var(--muted-dark); }
@keyframes sp-live-ping { 0% { transform: scale(1); opacity: .7; } 70%, 100% { transform: scale(2.6); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .sp-live.is-on i::after { animation: none; } }
@media (max-width: 700px) {
  .sp-right { width: 100%; margin-left: 0; flex-direction: column; justify-content: center; }
  .sp-right .sp-actions { width: 100%; justify-content: center; }
}

/* Avatar de la cabecera pulsable: se abre en grande en el visor (assets/lightbox.js) */
.av-zoom { display: inline-block; flex: none; padding: 0; margin: 0; border: 0; border-radius: 50%; background: none; color: inherit; cursor: zoom-in; line-height: 0; }
.av-zoom .av-img { transition: filter .18s ease, transform .25s ease; }
.av-zoom:hover .av-img, .av-zoom:focus-visible .av-img { filter: brightness(1.12); }
.av-zoom:focus-visible { outline: 3px solid var(--accent-hover); outline-offset: 4px; }
html.lb-open { overflow: hidden; }
.cm-lb-img.lb-sq { width: min(80vmin, 512px); height: min(80vmin, 512px); object-fit: cover; }
@media (prefers-reduced-motion: reduce) { .av-zoom .av-img { transition: none; } }

/* =====================================================================
   Cabecera del perfil: solo el AVATAR monta sobre la portada. El nombre, el usuario, las insignias y los botones empiezan justo debajo del
   borde del banner (antes quedaban dentro de los 68 px que se solapan y la portada los tapaba). La fila va por encima de la portada.
   ===================================================================== */
.sp-headrow { position: relative; z-index: 1; align-items: flex-start; }
.sp-id { align-self: flex-start; margin-top: 78px; padding-bottom: .5rem; }
.sp-right { align-self: flex-start; margin-top: 78px; padding-bottom: .5rem; }
.sp-id h1 { overflow-wrap: anywhere; }
.sp { width: 100%; }
.sp-top { container-type: inline-size; }
/* Cuando la cabecera es estrecha, los botones bajan a su propia línea: sin el desplazamiento (si no, dejarían un hueco) */
@container (max-width: 959px) {
  .sp-right { margin-top: 0; flex: 1 1 100%; justify-content: flex-end; padding-bottom: .9rem; }
}
@media (max-width: 560px) {
  /* En móvil el nombre ya baja bajo el avatar: no hace falta el desplazamiento */
  .sp-headrow { align-items: center; }
  .sp-id, .sp-right { margin-top: 0; }
}

/* =====================================================================
   Perfil v22.18 (jugador.php): las cinco estadísticas en una sola fila, pestañas en la columna principal y nombre ajustable.
   Misma estructura de siempre (cabecera · columna lateral · columna principal); lo privado y lo de staff pasan a pestañas junto al Muro.
   Adaptativo por contenedor: .sp es el contenedor «sp» (el ancho de la página, no el del viewport); .sp-top conserva el suyo.
   ===================================================================== */
.sp { container: sp / inline-size; }

/* ---------- Estadísticas: tarjetas en una sola fila; Nivel y Religión al ancho de su contenido ---------- */
.sp-stats { display: flex; flex-wrap: wrap; gap: .7rem; list-style: none; margin: 1.1rem 0 0; padding: 1rem clamp(1rem, 2.4cqw, 1.5rem) 1.2rem; border-top: 1px solid var(--border); background: linear-gradient(180deg, var(--surface-2), var(--surface)); }
.sp-stats > li { display: flex; flex: 1 1 11rem; min-width: 0; }
.sp-stats > li.is-s { flex: 0 0 auto; }
.sp-stats > li.is-l { flex: 1.5 1 14rem; }
.sp-stat { display: flex; align-items: center; gap: .8rem; flex: 1; min-width: 0; padding: .7rem .95rem; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.sp-stats .sp-ico { width: 42px; height: 42px; border-radius: var(--radius); }
.sp-stats .sp-ico.sp-ico-img { width: 46px; height: 46px; }
.sp-stat-t .sp-k { display: flex; flex-wrap: wrap; align-items: center; gap: .15rem .4rem; }
.sp-val { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 .55rem; }   /* Muertes: total y PvP · PvE en la misma línea */
.sp-val small { font-size: var(--fs-xs); }
/* Clan: botón con una flecha al final en lugar de una tercera línea «Ver integrantes» (todas las tarjetas miden lo mismo de alto) */
.sp-stat-btn .sp-stat-t { flex: 1 1 auto; }
.sp-stat-go { flex: none; margin-left: auto; }
@container sp (max-width: 860px) {   /* 3 + 2 */
  .sp-stats > li, .sp-stats > li.is-s, .sp-stats > li.is-l { flex: 1 1 30%; }
}
@container sp (max-width: 520px) {   /* 2 columnas con el icono sobre el texto; el clan, a todo el ancho y en horizontal */
  .sp-stats > li, .sp-stats > li.is-s { flex: 1 1 calc(50% - .35rem); }
  .sp-stats > li.is-l { flex-basis: 100%; }
  .sp-stat { flex-direction: column; align-items: flex-start; gap: .5rem; }
  .sp-stats > li.is-l .sp-stat { flex-direction: row; align-items: center; gap: .8rem; }
}

/* ---------- Nombre: una letra más pequeña cuanto más largo y 2 líneas como máximo (el nombre completo está en el title) ---------- */
.sp-id { min-width: 0; }
.sp-id h1 { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden; overflow-wrap: anywhere; text-wrap: balance; }
.sp-id h1.is-long { font-size: clamp(1.2rem, 3.6cqw, 1.6rem); }   /* Crom es ancha: los umbrales de longitud bajan un escalón */
.sp-id h1.is-xlong { font-size: clamp(1rem, 2.9cqw, 1.3rem); line-height: 1.2; }

/* ---------- Cuerpo: lateral + principal según el ancho de la página ---------- */
.sp-body { grid-template-columns: minmax(0, 1fr); margin-bottom: 1.8rem; }
@container sp (min-width: 861px) { .sp-body { grid-template-columns: minmax(0, 340px) minmax(0, 1fr); } }
.sp .pf-card { padding: clamp(1rem, 2.6cqw, 1.5rem); }
.act-sessions { grid-template-columns: repeat(auto-fit, minmax(min(15rem, 100%), 1fr)); }   /* sesiones en dos columnas cuando hay ancho */

/* ---------- Pestañas de la columna principal (Muro · Historial · Privado · Staff). Sin JavaScript no hay barra y se ven todas seguidas ---------- */
.sp-tabs { display: flex; gap: .3rem; padding: .35rem; overflow-x: auto; background: rgba(0, 0, 0, .25); border: 1px solid var(--border); border-radius: var(--radius-lg); }
.sp:not(.is-js) .sp-tabs { display: none; }
.sp-tab { flex: 1 1 auto; padding: .6rem 1.1rem; border: 1px solid transparent; border-radius: var(--radius); background: none; color: var(--muted); font: inherit; font-weight: 700; white-space: nowrap; cursor: pointer; transition: color .18s ease, background-color .18s ease, border-color .18s ease; }
.sp-tab:hover { background: rgba(255, 255, 255, .05); color: var(--text-strong); }
.sp-tab[aria-selected="true"] { color: var(--text-strong); border-color: rgba(201, 151, 75, .6); background: linear-gradient(180deg, rgba(201, 151, 75, .2), var(--surface)); }
.sp-tab:focus-visible { outline: 2px solid var(--accent-hover); outline-offset: 2px; }
.sp-pane { display: grid; gap: 1.2rem; min-width: 0; }
.sp-pane[hidden] { display: none; }
.sp-pane .pf-card { margin-bottom: 0; }
.sp-duo { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(20rem, 100%), 1fr)); gap: 1.2rem; align-items: start; }
.sp-duo .pf-card { margin-bottom: 0; }
.sp-pane .pf-dl-wide { grid-template-columns: minmax(5rem, 7rem) minmax(0, 1fr); gap: .6rem 1rem; }   /* la etiqueta puede partirse en dos líneas: el valor (correo, IP) conserva el ancho */
.sp-pane .pf-dl dd { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem .55rem; }
.sp-pane .pf-dl dd .vis-chip { margin-left: 0; }
.sp-pane .pf-dl dd small { flex-basis: 100%; }
.sp-pane .pf-dl dd code { font-size: var(--fs-sm); }
.sp-pane .pf-private > .muted.small { margin: 0 0 1rem; }
@container sp (max-width: 520px) {
  .sp-tab { padding: .55rem .35rem; font-size: var(--fs-sm); }
  .sp-pane .pf-dl-wide { grid-template-columns: minmax(0, 1fr); gap: 0; }   /* etiqueta sobre el valor */
  .sp-pane .pf-dl dt { margin-top: .7rem; }
  .sp-pane .pf-dl dt:first-child { margin-top: 0; }
}
@media (prefers-reduced-motion: reduce) { .sp-tab { transition: none; } }

/* ---------- Pie ---------- */
.sp-foot { max-width: 78ch; margin: 0 0 1.4rem; line-height: 1.5; }
