/* ============================================
   FUENTES — Prometo (local, sin cambios)
   ============================================ */
@font-face {
    font-family: 'Prometo';
    src: url('prometo_font/Prometo-Light.ttf') format('truetype');
    font-weight: 300;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Prometo';
    src: url('prometo_font/Prometo.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Prometo';
    src: url('prometo_font/Prometo-Medium.ttf') format('truetype');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Prometo';
    src: url('prometo_font/Prometo-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Prometo';
    src: url('prometo_font/Prometo-BoldItalic.ttf') format('truetype');
    font-weight: 700;
    font-style: italic;
    font-display: swap;
}
@font-face {
    font-family: 'Prometo';
    src: url('prometo_font/Prometo-Black.ttf') format('truetype');
    font-weight: 900;
    font-style: normal;
    font-display: swap;
}

/* ============================================
   MURAL VINOTINTO — Paleta FVF (sin cambios)
     --vino      #47162a  (vinotinto oficial)
     --oro       #b49b57  (oro / divisa)
     --pergamino #ded6bf  (crema de la sala)
     --blanco    #ffffff  (mármol, marcos)
     --noche     #1C1C1C  (estadio de noche)
   ============================================ */

:root {
    /* --- Primitivos --- */
    --vino:        #47162a;
    --vino-oscuro: #2c0d1a;
    --vino-suave:  #6a1f3a;
    --oro:         #b49b57;
    --oro-claro:   #d6be7a;
    --oro-sombra:  #7a6a3a;
    --pergamino:   #ded6bf;
    --pergamino-2: #c9c0a5;
    --blanco:      #ffffff;
    --noche:       #1C1C1C;
    --noche-2:     #2a2426;

    /* --- Texto (jerarquía de 4, sobre fondo claro) --- */
    --ink-1: #2a0f1a;   /* primario — vino muy oscuro */
    --ink-2: #5b2a3e;   /* secundario — vino medio */
    --ink-3: #7a6a3a;   /* terciario — oro apagado */
    --ink-4: #a89968;   /* muted / placeholders */

    /* --- Bordes (progresión) --- */
    --line-1: rgba(71, 22, 42, 0.10);    /* separación estándar */
    --line-2: rgba(71, 22, 42, 0.22);    /* separación fuerte */
    --line-3: rgba(71, 22, 42, 0.40);    /* énfasis */
    --line-oro: #b49b57;                  /* máximo énfasis / foco */
    --line-vino: rgba(71, 22, 42, 0.6);

    /* --- Elevación (sala diurna, vitrina de museo) --- */
    --bg-0: #f3eddc;          /* muro de fondo — pergamino cálido */
    --bg-1: #ebe3cd;          /* contenedor principal */
    --bg-2: #ffffff;          /* tarjetas / paneles */
    --bg-3: #ded6bf;          /* dropdowns, lightbox */
    --bg-control: #f7f1e0;    /* inputs (inset) */

    /* --- Sombras (capas muy sutiles, sobre claro) --- */
    --shadow-1: 0 1px 2px rgba(71, 22, 42, 0.08), 0 2px 8px rgba(71, 22, 42, 0.06);
    --shadow-2: 0 2px 4px rgba(71, 22, 42, 0.10), 0 8px 22px rgba(71, 22, 42, 0.10);
    --shadow-3: 0 4px 8px rgba(71, 22, 42, 0.12), 0 18px 40px rgba(71, 22, 42, 0.15);

    /* --- Radios --- */
    --r-sm: 4px;
    --r-md: 6px;
    --r-lg: 10px;

    /* --- Espaciado (base 4px) --- */
    --s-1: 4px;
    --s-2: 8px;
    --s-3: 12px;
    --s-4: 16px;
    --s-5: 24px;
    --s-6: 32px;
    --s-7: 48px;
    --s-8: 64px;

    /* --- Tipografía (Prometo se mantiene) --- */
    --font-display: 'Prometo', 'Helvetica Neue', Arial, sans-serif;
    --font-body:    'Prometo', 'Helvetica Neue', Arial, sans-serif;
    --font-mono:    'Prometo', 'Courier New', monospace;
}

/* ============================================
   RESET Y BASE
   ============================================ */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html { scroll-behavior: smooth; }

body {
    font-family: var(--font-body);
    background: var(--bg-0);
    color: var(--ink-1);
    line-height: 1.5;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    overflow-x: hidden;
}

img { display: block; max-width: 100%; height: auto; }

button {
    font: inherit;
    cursor: pointer;
    border: none;
    background: none;
    color: inherit;
}

/* ============================================
   TEXTURA DE PAPEL / GRANO
   Capa fija sobre todo el documento.
   ============================================ */
.grain {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 1;
    opacity: 0.35;
    mix-blend-mode: multiply;
    background-image: url("data:image/svg+xml;utf8,<svg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.28  0 0 0 0 0.09  0 0 0 0 0.16  0 0 0 0.55 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
    background-size: 200px 200px;
}

/* ============================================
   FILO / SELLO DE ARCHIVO
   Banda tipográfica arriba y abajo.
   ============================================ */
.archive-strip {
    background: var(--vino-oscuro);
    color: var(--oro-claro);
    border-top: 1px solid var(--oro);
    border-bottom: 1px solid var(--oro);
    overflow: hidden;
    position: relative;
    z-index: 5;
}

.archive-strip--bottom {
    background: var(--vino-oscuro);
    margin-top: var(--s-6);
}

.archive-strip__inner {
    display: flex;
    gap: var(--s-4);
    align-items: center;
    justify-content: center;
    white-space: nowrap;
    padding: 9px 0;
    font-size: 0.68rem;
    letter-spacing: 4px;
    text-transform: uppercase;
    font-weight: 500;
    color: var(--oro-claro);
    animation: strip-marquee 38s linear infinite;
}

.archive-strip__inner span:nth-child(odd) { color: var(--oro-claro); }
.archive-strip__inner span:nth-child(3n)   { color: var(--pergamino); font-weight: 300; }
.archive-strip__inner span:first-child,
.archive-strip__inner span:last-child  { color: var(--oro); font-weight: 700; }

@keyframes strip-marquee {
    from { transform: translateX(0); }
    to   { transform: translateX(-50%); }
}

/* ============================================
   MARCO DE LA SALA (contenedor)
   El mural flota sobre un muro de noche con
   doble moldura dorada — placa de vitrina.
   ============================================ */
.page-wrapper {
    max-width: 1280px;
    margin: var(--s-6) auto var(--s-7);
    padding: var(--s-6) var(--s-5) var(--s-7);
    background: var(--bg-1);
    border: 1px solid var(--line-2);
    border-radius: var(--r-md);
    box-shadow: var(--shadow-2);
    position: relative;
    z-index: 2;
}

/* Filete dorado interior — como un passe-partout */
.page-wrapper::before {
    content: "";
    position: absolute;
    inset: 8px;
    border: 1px solid var(--line-1);
    border-radius: 4px;
    pointer-events: none;
}

/* Filete interior adicional — placa de museo */
.page-wrapper::after {
    content: "";
    position: absolute;
    inset: 14px;
    border: 1px solid var(--line-oro);
    border-radius: 2px;
    pointer-events: none;
    opacity: 0.35;
}

/* ============================================
   CARTEL DE LA SALA (encabezado)
   Inscripción de museo: tipo display, tracking
   ancho, filete oro arriba y abajo.
   Bloque asimétrico de tres columnas:
   [meta izq] — [título] — [meta der]
   ============================================ */
.page-header {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: end;
    gap: var(--s-5);
    margin-bottom: var(--s-6);
    padding: var(--s-6) 0 var(--s-5);
    position: relative;
    border-top: 1px solid var(--line-1);
    border-bottom: 1px solid var(--line-1);
}

.page-header::before,
.page-header::after {
    content: "";
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    height: 1px;
    background: linear-gradient(90deg,
        transparent 0%,
        var(--oro) 35%,
        var(--oro-claro) 50%,
        var(--oro) 65%,
        transparent 100%);
}
.page-header::before { top: -1px;   width: 60%;  opacity: 0.7; }
.page-header::after  { bottom: -1px; width: 40%;  opacity: 0.5; }

.page-header__meta {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 0.62rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--ink-3);
    font-weight: 500;
}
.page-header__meta--left  { text-align: left;  align-items: flex-start; }
.page-header__meta--right { text-align: right; align-items: flex-end; }

.page-header__meta .meta-line { color: var(--ink-4); }
.page-header__meta .meta-value { color: var(--vino); font-weight: 700; }

.page-header__core {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--s-2);
}

.page-eyebrow {
    font-family: var(--font-body);
    font-size: 0.7rem;
    font-weight: 500;
    letter-spacing: 6px;
    text-transform: uppercase;
    color: var(--vino);
    display: inline-flex;
    align-items: center;
    gap: var(--s-3);
}

.eyebrow-mark {
    color: var(--oro);
    font-size: 0.85rem;
    font-weight: 700;
    transform: translateY(-1px);
}

.page-title {
    font-family: var(--font-display);
    line-height: 0.95;
    color: var(--vino);
    text-transform: uppercase;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
    margin: 4px 0 6px;
}

.title-line--1 {
    font-size: clamp(2.4rem, 5.2vw, 3.6rem);
    font-weight: 700;
    letter-spacing: 14px;
    padding-left: 14px; /* compensa letter-spacing visual */
}

.title-line--2 {
    font-size: clamp(1.6rem, 3.4vw, 2.4rem);
    font-weight: 300;
    letter-spacing: 22px;
    padding-left: 22px;
    color: var(--vino-oscuro);
}

.title-line--2 em {
    font-style: italic;
    font-weight: 300;
    letter-spacing: 18px;
    padding-left: 18px;
    color: var(--vino);
}

.page-header__rule {
    display: flex;
    align-items: center;
    gap: var(--s-2);
    margin: var(--s-2) 0 var(--s-1);
}
.rule-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--oro); }
.rule-bar { width: 60px; height: 1px; background: linear-gradient(90deg, transparent, var(--oro), transparent); }
.rule-diamond { color: var(--oro); font-size: 0.55rem; transform: translateY(-1px); }

.page-subtitle {
    font-size: 0.78rem;
    color: var(--ink-2);
    font-weight: 400;
    letter-spacing: 2.4px;
    text-transform: uppercase;
    font-style: italic;
}

/* ============================================
   ANOTACIONES MARGINALES VERTICALES
   Tipografía rotada, como notas de curador.
   ============================================ */
.margin-note {
    position: absolute;
    top: 200px;
    font-size: 0.6rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--ink-3);
    font-weight: 500;
    display: flex;
    flex-direction: column;
    gap: 6px;
    pointer-events: none;
    z-index: 3;
}
.margin-note--left  { left: -42px;  writing-mode: vertical-rl; transform: rotate(180deg); }
.margin-note--right { right: -42px; writing-mode: vertical-rl; }

.margin-note span:first-child {
    color: var(--vino);
    font-weight: 700;
    letter-spacing: 4px;
}

/* ============================================
   RAIL DE ÍNDICE — sobre el mural
   ============================================ */
.index-rail {
    display: flex;
    align-items: center;
    gap: var(--s-3);
    margin: 0 0 var(--s-4);
    font-size: 0.66rem;
    letter-spacing: 4px;
    text-transform: uppercase;
    color: var(--ink-3);
    font-weight: 500;
}
.index-rail__num {
    font-family: var(--font-display);
    font-style: italic;
    font-size: 1rem;
    color: var(--oro-sombra);
    font-weight: 700;
    letter-spacing: 0;
}
.index-rail__label { color: var(--vino); font-weight: 700; }
.index-rail__rule {
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, var(--line-2) 0%, transparent 100%);
}

/* ============================================
   CONTENEDOR DEL MURAL
   ============================================ */
.mural-container {
    position: relative;
    padding: var(--s-4) 0 var(--s-6);
}

.mural-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    grid-auto-rows: 60px;
    gap: 14px;
    position: relative;
}

/* ============================================
   PANELES (placas de la vitrina)
   Cada panel es un marco con filete dorado
   interior, fondo de terciopelo vino y sombra
   de cuadro colgado. Ahora con:
   - etiqueta de placa N°xx
   - etiqueta de categoría (PRENDA / SECUENCIA / SEDE)
   - marco doble en jerseys
   ============================================ */
.panel {
    position: relative;
    margin: 0;
    overflow: hidden;
    border-radius: var(--r-md);
    background: var(--bg-2);
    border: 1px solid var(--line-2);
    box-shadow: var(--shadow-1);
    cursor: pointer;
    transition:
        transform 0.45s cubic-bezier(.2,.7,.3,1),
        box-shadow 0.45s ease,
        border-color 0.35s ease,
        z-index 0s 0.25s;
    z-index: 1;
}

.panel::after {
    /* filete dorado interior fino, en todo panel */
    content: "";
    position: absolute;
    inset: 5px;
    border: 1px solid var(--line-oro);
    border-radius: 3px;
    pointer-events: none;
    opacity: 0.45;
    transition: opacity 0.4s ease;
    z-index: 3;
}

.panel img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    transition: transform 0.6s cubic-bezier(.2,.7,.3,1), filter 0.4s ease;
    background: #f7f1e0;
    padding: 12px 10px 14px;
}

.panel:hover,
.panel.is-highlight {
    transform: translateY(-4px);
    border-color: var(--line-oro);
    box-shadow:
        var(--shadow-2),
        0 0 0 1px var(--oro);
    z-index: 20;
    transition:
        transform 0.45s cubic-bezier(.2,.7,.3,1),
        box-shadow 0.45s ease,
        border-color 0.35s ease,
        z-index 0s;
}
.panel:hover::after,
.panel.is-highlight::after { opacity: 1; }

.panel:hover img,
.panel.is-highlight img {
    transform: scale(1.04);
}

.panel.is-dimmed {
    opacity: 0.30;
    filter: grayscale(60%);
}

/* Etiqueta de placa: N° 01 en la esquina superior izq */
.plate-number {
    position: absolute;
    top: 6px;
    left: 6px;
    z-index: 4;
    font-family: var(--font-display);
    font-size: 0.55rem;
    letter-spacing: 1.8px;
    color: var(--vino);
    background: var(--pergamino);
    padding: 3px 6px 2px;
    border: 1px solid var(--line-oro);
    border-radius: 2px;
    text-transform: uppercase;
    font-weight: 700;
    box-shadow: 0 1px 0 rgba(71, 22, 42, 0.08);
    transition: background 0.35s ease, color 0.35s ease;
}

.panel:hover .plate-number,
.panel.is-highlight .plate-number {
    background: var(--vino);
    color: var(--oro-claro);
    border-color: var(--oro);
}

/* Etiqueta de categoría: PRENDA, SECUENCIA, SEDE */
.plate-tag {
    position: absolute;
    top: 6px;
    right: 6px;
    z-index: 4;
    font-family: var(--font-display);
    font-size: 0.5rem;
    letter-spacing: 2.5px;
    color: var(--pergamino);
    background: var(--vino-oscuro);
    padding: 3px 6px 2px;
    text-transform: uppercase;
    font-weight: 700;
    transition: background 0.35s ease, color 0.35s ease;
}
.plate-tag--alt {
    background: var(--oro);
    color: var(--vino-oscuro);
}

.panel:hover .plate-tag,
.panel.is-highlight .plate-tag {
    background: var(--oro);
    color: var(--vino-oscuro);
}
.panel:hover .plate-tag--alt,
.panel.is-highlight .plate-tag--alt {
    background: var(--vino-oscuro);
    color: var(--oro);
}

/* Panel con stack vertical de imágenes (FOTO5) */
.panel-stack {
    padding: 0;
    background: var(--bg-2);
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.panel-stack .plate-number,
.panel-stack .plate-tag { z-index: 5; }

.stack-item {
    flex: 1;
    width: 100%;
    min-height: 0;
    background-position: center;
    background-size: contain;
    background-repeat: no-repeat;
    background-color: #f7f1e0;
}

/* Panel tipo jersey: marco de madera dorada interior */
.panel-jersey {
    background:
        linear-gradient(180deg, #f7f1e0 0%, #ebe3cd 100%);
    border: 1px solid var(--line-oro);
    box-shadow:
        inset 0 0 0 1px rgba(180, 155, 87, 0.35),
        var(--shadow-1);
}
.panel-jersey::before {
    content: "";
    position: absolute;
    inset: 8px;
    border: 1px solid rgba(180, 155, 87, 0.55);
    border-radius: 2px;
    pointer-events: none;
    z-index: 3;
}
.panel-jersey::after {
    inset: 12px;
    border-color: var(--line-oro);
    opacity: 0.7;
}
.panel-jersey img {
    background: transparent;
    padding: 22px 16px 24px;
}

/* ============================================
   POSICIONAMIENTO DE LOS PANELES (MOSAICO)
   Mismas posiciones que el diseño original.
   ============================================ */
.panel-1   { grid-column: 1 / span 3;  grid-row: 1 / span 3; }
.panel-2   { grid-column: 4 / span 3;  grid-row: 1 / span 3; }
.panel-3   { grid-column: 7 / span 4;  grid-row: 1 / span 5; }
.panel-4   { grid-column: 11 / span 2; grid-row: 1 / span 3; }
.panel-5   { grid-column: 1 / span 2;  grid-row: 4 / span 7; }
.panel-6   { grid-column: 3 / span 4;  grid-row: 4 / span 5; }
.panel-7   { grid-column: 7 / span 2;  grid-row: 6 / span 3; }
.panel-8   { grid-column: 7 / span 2;  grid-row: 9 / span 3; }
.panel-9   { grid-column: 11 / span 2; grid-row: 4 / span 3; }
.panel-10  { grid-column: 11 / span 2; grid-row: 7 / span 5; }
.panel-11  { grid-column: 3 / span 4;  grid-row: 9 / span 3; }

.panel-extra-1 { grid-column: 9 / span 2; grid-row: 6 / span 1; display: none; }
.panel-extra-stack {
    /* Placas 13-16: una sola columna-stack que ocupa las
       mismas 5 filas (6 a 11) que ocupaban las 4 placas
       individuales. Mismo diseño que la placa N° 05. */
    grid-column: 9 / span 2;
    grid-row: 6 / span 6;
}

/* ============================================
   PIE EDITORIAL DEL ARCHIVO
   ============================================ */
.archive-footer {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: var(--s-4);
    margin-top: var(--s-6);
    padding: var(--s-4) 0 0;
    border-top: 1px solid var(--line-1);
    font-size: 0.62rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--ink-3);
    font-weight: 500;
}
.archive-footer__col--left  { text-align: left;  }
.archive-footer__col--right { text-align: right; }
.archive-footer__col--center { text-align: center; }

.footer-key { color: var(--ink-4); margin-right: 6px; }
.footer-val { color: var(--vino); font-weight: 700; }
.footer-ornament { color: var(--oro); font-size: 1.1rem; }

/* ============================================
   LIGHTBOX — vitrina ampliada (sobre claro)
   ============================================ */
.lightbox {
    position: fixed;
    inset: 0;
    background: rgba(28, 28, 28, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--s-5);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    z-index: 1000;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.lightbox.is-open {
    opacity: 1;
    visibility: visible;
}

.lightbox-content {
    max-width: 96vw;
    max-height: 92vh;
    display: flex;
    flex-direction: row;
    align-items: stretch;
    justify-content: center;
    gap: var(--s-5);
    transform: scale(0.94);
    transition: transform 0.4s cubic-bezier(.2,.7,.3,1);
}

.lightbox.is-open .lightbox-content {
    transform: scale(1);
}

.lightbox-frame {
    position: relative;
    padding: 10px;
    background: var(--pergamino);
    border: 1px solid var(--line-oro);
    box-shadow: var(--shadow-3);
    flex: 0 1 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    max-height: 88vh;
}
.lightbox-frame::before {
    content: "";
    position: absolute;
    inset: 4px;
    border: 1px solid var(--line-oro);
    pointer-events: none;
    opacity: 0.6;
}
.lightbox-plate {
    position: absolute;
    top: -14px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--vino-oscuro);
    color: var(--oro-claro);
    font-family: var(--font-display);
    font-size: 0.65rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    padding: 4px 14px;
    z-index: 2;
    font-weight: 700;
}

.lightbox-content img {
    max-width: 52vw;
    max-height: 84vh;
    object-fit: contain;
    display: block;
    background: #f7f1e0;
}

.lightbox-content figcaption {
    text-align: left;
    width: 420px;
    max-width: 42vw;
    padding: var(--s-3) var(--s-3) var(--s-3) 0;
    color: var(--pergamino);
    flex: 0 0 420px;
    max-height: 86vh;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--oro) transparent;
}
.lightbox-content figcaption::-webkit-scrollbar { width: 6px; }
.lightbox-content figcaption::-webkit-scrollbar-track { background: transparent; }
.lightbox-content figcaption::-webkit-scrollbar-thumb {
    background: var(--line-oro);
    border-radius: 3px;
}

.lightbox-eyebrow {
    font-size: 0.62rem;
    letter-spacing: 4px;
    text-transform: uppercase;
    color: var(--oro);
    font-weight: 700;
    margin-bottom: 8px;
}

.lightbox-content figcaption h2 {
    font-family: var(--font-display);
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: 2px;
    line-height: 1.2;
    color: var(--oro-claro);
    text-transform: uppercase;
    margin-bottom: 12px;
}

.lightbox-content figcaption p {
    font-size: 0.88rem;
    color: var(--pergamino);
    line-height: 1.65;
    font-weight: 300;
    text-align: justify;
    hyphens: auto;
}

.lightbox-close {
    position: absolute;
    top: 18px;
    right: 28px;
    font-size: 1.6rem;
    color: var(--oro-claro);
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(28, 13, 26, 0.6);
    border: 1px solid var(--oro);
    transition: background 0.25s ease, transform 0.4s ease, border-color 0.25s ease;
    line-height: 1;
}

.lightbox-close:hover {
    background: var(--vino);
    border-color: var(--oro-claro);
    transform: rotate(90deg);
    color: var(--oro-claro);
}

/* Navegación de lightbox (secuencias) */
.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 2.4rem;
    color: var(--oro-claro);
    width: 52px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(28, 13, 26, 0.6);
    border: 1px solid var(--oro);
    transition: background 0.25s ease, transform 0.3s ease, border-color 0.25s ease;
    line-height: 1;
    z-index: 1001;
    font-family: var(--font-display);
}
.lightbox-nav--prev { left: 24px; }
.lightbox-nav--next { right: 24px; }
.lightbox-nav:hover {
    background: var(--vino);
    border-color: var(--oro-claro);
    color: var(--oro-claro);
}
.lightbox-nav--prev:hover { transform: translateY(-50%) translateX(-3px); }
.lightbox-nav--next:hover { transform: translateY(-50%) translateX(3px); }
.lightbox-nav[hidden] { display: none; }

.lightbox-counter {
    position: absolute;
    bottom: -14px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--vino-oscuro);
    color: var(--oro-claro);
    font-family: var(--font-display);
    font-size: 0.65rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    padding: 4px 14px;
    z-index: 2;
    font-weight: 700;
    border: 1px solid var(--oro);
    border-radius: 2px;
}
.lightbox-counter[hidden] { display: none; }

/* ============================================
   ANIMACIONES — entrada cinematográfica
   ============================================ */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(18px); }
    to   { opacity: 1; transform: translateY(0); }
}

@keyframes header-rise {
    from { opacity: 0; transform: translateY(8px); letter-spacing: 4px; }
    to   { opacity: 1; transform: translateY(0);  letter-spacing: 14px; }
}

.page-header { animation: fadeUp 0.7s ease both; }
.page-header__meta--left  { animation: fadeUp 0.6s ease 0.1s both; }
.page-header__meta--right { animation: fadeUp 0.6s ease 0.1s both; }
.title-line--1 { animation: header-rise 0.9s cubic-bezier(.2,.7,.3,1) 0.15s both; }
.title-line--2 { animation: fadeUp 0.7s ease 0.35s both; }
.page-header__rule { animation: fadeUp 0.6s ease 0.5s both; }
.page-subtitle { animation: fadeUp 0.6s ease 0.6s both; }

.index-rail { animation: fadeUp 0.6s ease 0.7s both; }
.archive-footer { animation: fadeUp 0.6s ease 1.1s both; }

.panel {
    animation: fadeUp 0.7s ease both;
}
.panel-1  { animation-delay: 0.20s; }
.panel-2  { animation-delay: 0.25s; }
.panel-3  { animation-delay: 0.30s; }
.panel-4  { animation-delay: 0.35s; }
.panel-5  { animation-delay: 0.40s; }
.panel-6  { animation-delay: 0.45s; }
.panel-7  { animation-delay: 0.50s; }
.panel-8  { animation-delay: 0.55s; }
.panel-9  { animation-delay: 0.60s; }
.panel-10 { animation-delay: 0.65s; }

.panel-extra-1 { animation-delay: 0.70s; }
.panel-extra-stack { animation-delay: 0.75s; }

/* ============================================
   FOCUS — accesibilidad
   ============================================ */
:focus-visible {
    outline: 2px solid var(--vino);
    outline-offset: 3px;
    border-radius: 4px;
}

.panel:focus-visible {
    outline: 2px solid var(--vino);
    outline-offset: 4px;
}

/* ============================================
   RESPONSIVE — TABLET
   ============================================ */
@media (max-width: 900px) {
    .archive-strip__inner { font-size: 0.6rem; letter-spacing: 3px; }

    .page-header {
        grid-template-columns: 1fr;
        text-align: center;
        gap: var(--s-3);
    }
    .page-header__meta--left,
    .page-header__meta--right {
        align-items: center;
        text-align: center;
    }
    .page-header__core { order: -1; }

    .margin-note { display: none; }

    /* En tablet apilamos todo en una columna para que cada imagen
       quede una debajo de la otra, sin superposiciones. */
    .mural-grid {
        display: flex;
        flex-direction: column;
        gap: 10px;
    }

    .panel,
    .panel-1, .panel-2, .panel-3, .panel-4, .panel-5,
    .panel-6, .panel-7, .panel-8, .panel-9, .panel-10, .panel-11,
    .panel-extra-1, .panel-extra-stack {
        grid-column: auto;
        grid-row: auto;
        width: 100%;
        height: auto;
        aspect-ratio: 4 / 3;
    }

    .panel img {
        width: 100%;
        height: 100%;
        object-fit: contain;
        padding: 14px;
    }

    .panel-jersey { aspect-ratio: 3 / 4; }

    .panel-stack {
        aspect-ratio: auto;
        display: flex;
        flex-direction: column;
        gap: 2px;
        height: auto;
    }
    .panel-stack .stack-item {
        width: 100%;
        aspect-ratio: 4 / 3;
        background-size: contain;
    }
}

/* ============================================
   RESPONSIVE — MÓVIL
   ============================================ */
@media (max-width: 600px) {
    .page-wrapper { padding: var(--s-4) var(--s-2) var(--s-5); margin: var(--s-3) auto; }

    .title-line--1 { letter-spacing: 8px;  padding-left: 8px; }
    .title-line--2 { letter-spacing: 10px; padding-left: 10px; }
    .title-line--2 em { letter-spacing: 8px; padding-left: 8px; }

    /* En móvil mostramos cada panel como una "secuencia 1": la imagen
       ocupa todo el ancho con object-fit: contain, y el panel crece
       según la proporción natural de la imagen (aspect-ratio). */
    .mural-grid {
        display: flex;
        flex-direction: column;
        gap: var(--s-3);
    }

    .panel,
    .panel-1, .panel-2, .panel-3, .panel-4, .panel-5,
    .panel-6, .panel-7, .panel-8, .panel-9, .panel-10, .panel-11,
    .panel-extra-1, .panel-extra-stack {
        grid-column: auto;
        grid-row: auto;
        width: 100%;
        flex: 0 0 auto;
        height: auto;
        aspect-ratio: 4 / 3;
    }

    /* Imágenes a todo el ancho, contenidas, como los stack-item de secuencia 1 */
    .panel img {
        width: 100%;
        height: 100%;
        object-fit: contain;
        padding: 14px;
    }

    /* Jerseys: más altos para mantener proporción */
    .panel-jersey { aspect-ratio: 3 / 4; }

    /* Secuencias (panel-stack): imagenes apiladas en columna, ancho completo */
    .panel-stack {
        aspect-ratio: auto;
        display: flex;
        flex-direction: column;
        gap: 2px;
        height: auto;
    }
    .panel-stack .stack-item {
        width: 100%;
        aspect-ratio: 4 / 3;
        background-size: contain;
    }

    .archive-footer {
        grid-template-columns: 1fr;
        text-align: center;
        gap: var(--s-2);
    }
    .archive-footer__col--left,
    .archive-footer__col--right { text-align: center; }
    .archive-footer__col--center { order: -1; }

    .lightbox-content {
        flex-direction: column;
        gap: var(--s-3);
        max-height: 94vh;
    }
    .lightbox-content img {
        max-width: 90vw;
        max-height: 45vh;
    }
    .lightbox-content figcaption {
        text-align: left;
        max-width: 92vw;
        width: 92vw;
        flex: 0 1 auto;
        max-height: 42vh;
        padding: 0 var(--s-2);
    }
    .lightbox-content figcaption h2 { font-size: 1.15rem; letter-spacing: 1.5px; }
    .lightbox-content figcaption p  { font-size: 0.85rem; text-align: left; }
}
