/* Armería (armeria.php, armeria-personaje.php). Escaparate con fondo de raza, silueta y casillas; pestañas debajo. */
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.armory-search { max-width: 720px; padding-top: 60px; padding-bottom: 80px; }
.armory-search h1 { color: var(--text-bright); font-size: 2rem; margin-bottom: 8px; }
.armory-hint { color: var(--text-muted); margin-bottom: 16px; }
.armory-error { color: #fecaca; background: rgba(220, 38, 38, 0.15); border: 1px solid rgba(220, 38, 38, 0.4);
  border-radius: var(--radius-sm); padding: 10px 12px; margin: 14px 0; }
.armory-form { display: flex; gap: 10px; }
.armory-form input { flex: 1; min-width: 0; font: inherit; color: var(--text-bright); background: var(--bg-dark);
  border: 1px solid var(--border-subtle); border-radius: var(--radius-full); padding: 10px 16px; }
.armory-form input:focus { outline: 2px solid var(--gold-primary); outline-offset: 1px; }
.armory-form button { font: inherit; font-weight: 600; color: var(--stone-950); background: var(--gold-primary); border: 0;
  border-radius: var(--radius-full); padding: 10px 22px; cursor: var(--cursor-hand); }
.armory-results { list-style: none; padding: 0; margin-top: 20px; display: grid; gap: 8px; }
.armory-results a { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 12px 16px;
  background: var(--bg-surface); border: 1px solid var(--border-subtle); border-radius: var(--radius-md); color: var(--text-main); }
.armory-results a:hover { border-color: var(--gold-primary); }
.armory-results strong { color: var(--gold-light); }
.armory-results span { color: var(--text-muted); }

.armory-hero { position: relative; isolation: isolate; padding: 28px 0 32px; background: var(--bg-deep); }
/* Fondo de raza oscurecido y desenfocado: la ilustración tiene mucho detalle y se comería la silueta. */
/* Sin overflow:hidden en el héroe (cortaría las fichas de objeto): solo se recorta el fondo. */
.armory-hero::before { content: ""; position: absolute; inset: 0; z-index: -1; clip-path: inset(0);
  background: var(--race-bg, none) center 30% / cover no-repeat; filter: blur(4px) brightness(.38) saturate(.85); }
.armory-hero::after { content: ""; position: absolute; inset: 0; z-index: -1;
  background: radial-gradient(ellipse at 50% 45%, transparent 0%, rgba(12,10,9,.35) 55%, var(--bg-dark) 100%); }
.armory-back a { color: var(--text-muted); font-size: .9rem; }
.armory-name { text-align: center; margin: 6px 0 22px; text-shadow: var(--text-shadow); }
.armory-name h1 { color: var(--gold-light); font-size: clamp(1.8rem, 5vw, 2.6rem); line-height: 1.1; }
.armory-name h1 small { color: var(--text-bright); font-size: .5em; font-weight: 500; }
.armory-name p { color: var(--text-main); }
.armory-showcase { display: grid; grid-template-columns: auto 1fr auto; gap: 16px; align-items: center; max-width: 760px; margin: 0 auto; }
.slots { display: grid; gap: 8px; }
.slots.weapons { grid-auto-flow: column; justify-content: center; margin-top: 18px; }
.silhouette { display: flex; justify-content: center; }
.silhouette svg { height: clamp(200px, 45vw, 380px); fill: rgba(245,245,244,.07); stroke: rgba(248,183,0,.55);
  stroke-width: 1.2; filter: drop-shadow(0 0 14px rgba(248,183,0,.25)); }

.slot { position: relative; width: 64px; height: 64px; border-radius: var(--radius-sm); border: 2px solid var(--border-subtle);
  background: rgba(12,10,9,.75); display: flex; align-items: center; justify-content: center; text-align: center;
  font-size: .62rem; color: var(--text-dim); line-height: 1.1; }
.slot img { width: 100%; height: 100%; border-radius: 6px; object-fit: cover; }
.slot:focus { outline: 2px solid var(--gold-primary); outline-offset: 2px; }
.slot.r-poor { border-color: #9ca3af; } .slot.r-common { border-color: #e7e5e4; }
.slot.r-uncommon { border-color: #34d399; } .slot.r-rare { border-color: #60a5fa; }
.r-poor { color: #9ca3af; } .r-common { color: #f5f5f4; } .r-uncommon { color: #34d399; } .r-rare { color: #60a5fa; }
.tip { display: none; position: absolute; z-index: 20; left: calc(100% + 10px); top: 0; width: 220px; text-align: left;
  background: #0c0a09; border: 1px solid var(--border-subtle); border-radius: var(--radius-sm); padding: 10px;
  box-shadow: var(--shadow-card); font-size: .82rem; color: var(--text-main); }
.slots:last-child .tip, .armory-showcase > .slots:last-child .tip { left: auto; right: calc(100% + 10px); }
.slot:hover .tip, .slot:focus .tip { display: block; }
.weapons .tip { top: auto; bottom: 0; }  /* las armas, abajo del todo: la ficha abre hacia arriba */
.tip strong { display: block; font-size: .95rem; }
.tip em { display: block; font-style: normal; color: var(--text-muted); font-size: .78rem; }
.tip ul { list-style: none; padding: 0; margin: 6px 0; color: var(--life-green); }
.tip .broken { color: #f87171; }

.armory-tabs { padding-top: 10px; padding-bottom: 80px; }
.armory-tabs > input { position: absolute; opacity: 0; pointer-events: none; }
.tab-labels { display: flex; gap: 18px; flex-wrap: wrap; border-bottom: 1px solid var(--border-subtle); margin-bottom: 18px; }
.tab-labels label { padding: 10px 2px; color: var(--text-muted); cursor: var(--cursor-hand); border-bottom: 2px solid transparent; }
.tab { display: none; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
#tab-summary:checked ~ .tab-summary, #tab-achievements:checked ~ .tab-achievements, #tab-reputation:checked ~ .tab-reputation,
#tab-pvp:checked ~ .tab-pvp, #tab-talents:checked ~ .tab-talents { display: grid; }
#tab-summary:checked ~ .tab-labels label[for="tab-summary"], #tab-achievements:checked ~ .tab-labels label[for="tab-achievements"],
#tab-reputation:checked ~ .tab-labels label[for="tab-reputation"], #tab-pvp:checked ~ .tab-labels label[for="tab-pvp"],
#tab-talents:checked ~ .tab-labels label[for="tab-talents"] { color: var(--gold-light); border-bottom-color: var(--gold-light); }
.armory-tabs > input:focus-visible ~ .tab-labels { outline: 1px dashed var(--gold-primary); }
.box { background: var(--bg-surface); border: 1px solid var(--border-subtle); border-radius: var(--radius-lg); padding: 18px; }
.box h2 { color: var(--gold-light); font-size: 1.05rem; margin-bottom: 10px; }
.box .stats, .box .list { list-style: none; padding: 0; display: grid; gap: 6px; }
.box .stats li, .box .list li { display: flex; justify-content: space-between; gap: 10px; color: var(--text-main); }
.box .stats b { color: var(--text-bright); }
.box time, .box em { color: var(--text-dim); font-style: normal; }
.box .secrets { margin-top: 12px; color: var(--text-muted); }
.box a { color: var(--gold-light); }

@media (max-width: 640px) {
  .armory-showcase { grid-template-columns: 1fr 1fr; }
  .silhouette { grid-column: 1 / -1; grid-row: 1; }
  .armory-showcase { gap: 12px; }
  .slots { grid-template-columns: repeat(3, 46px); justify-content: center; gap: 6px; }
  .slot { width: 46px; height: 46px; font-size: .5rem; }
  .slots.weapons { grid-auto-flow: row; }
  /* Móvil: la ficha del objeto tocado, fija abajo a todo el ancho (no cabe junto a casillas de 46 px). */
  .tip, .slots:last-child .tip, .armory-showcase > .slots:last-child .tip, .weapons .tip {
    position: fixed; left: 16px; right: 16px; bottom: 16px; top: auto; width: auto; transform: none; }
}
