.rank-escena {
    position: relative;
    min-height: calc(100vh - 4.2rem);
    padding: 1.35rem 1rem 3.5rem;
    background-color: #070605;
    background-image: var(--rank-fondo);
    background-repeat: no-repeat;
    background-position: center top;
    background-size: 100% auto;
}


.rank-escena__arte {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

.rank-escena__tela {
    position: absolute;
    top: -8%;
    width: 28%;
    height: 78%;
    background: linear-gradient(180deg, rgba(92, 12, 16, .15), rgba(140, 18, 22, .55) 40%, rgba(40, 6, 8, .1));
    filter: blur(.2px);
}

.rank-escena__tela--izq {
    left: -6%;
    transform: rotate(8deg);
    clip-path: polygon(18% 0, 78% 0, 100% 100%, 0 100%);
}

.rank-escena__tela--der {
    right: -8%;
    transform: rotate(-10deg);
    clip-path: polygon(8% 0, 90% 0, 100% 100%, 22% 100%);
}

.rank-escena__monte {
    position: absolute;
    top: 0;
    right: -2%;
    width: min(52vw, 620px);
    height: auto;
    opacity: .85;
}

.rank-escena__esgrimista {
    position: absolute;
    left: -1%;
    bottom: 0;
    width: min(26vw, 300px);
    height: auto;
    opacity: .95;
}

.rank-escena__marco {
    position: absolute;
    left: 4%;
    right: 4%;
    bottom: 1.1rem;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(212, 175, 90, .7), transparent);
}

.rank-escena__marco::before,
.rank-escena__marco::after {
    content: "";
    position: absolute;
    bottom: 0;
    width: 72px;
    height: 18px;
    border-bottom: 1px solid rgba(212, 175, 90, .75);
}

.rank-escena__marco::before { left: 0; border-left: 1px solid rgba(212, 175, 90, .75); }
.rank-escena__marco::after { right: 0; border-right: 1px solid rgba(212, 175, 90, .75); }

.rank-escena__contenido {
    position: relative;
    z-index: 1;
    width: min(760px, 100%);
    margin: 0 auto;
}

.rank-escena__hero {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .35rem;
}

.rank-laurel {
    width: 54px;
    height: 108px;
    flex: none;
    color: #d4b36a;
}

.rank-laurel--espejo { transform: scaleX(-1); }

.rank-escena__nombre {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 0;
}

.rank-escena__nombre h1 {
    margin: .15rem 0 0;
    font-family: Cinzel, serif;
    font-size: clamp(2.1rem, 6vw, 3.6rem);
    font-weight: 700;
    letter-spacing: .16em;
    line-height: .95;
    text-transform: uppercase;
    background: linear-gradient(180deg, #fff6d8 0%, #e7c98a 42%, #a67c2d 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.rank-escena__lead {
    margin: .55rem 0 1.35rem;
    text-align: center;
    color: rgba(243, 239, 232, .78);
    font-size: .92rem;
}

.rank-escena__filtros {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: .75rem;
}

.rank-elige { position: relative; }

.rank-elige__btn {
    display: flex;
    align-items: center;
    gap: .7rem;
    width: 100%;
    min-height: 62px;
    padding: .55rem .85rem;
    border: 1px solid rgba(212, 175, 90, .72);
    border-radius: 14px;
    background: linear-gradient(180deg, rgba(22, 18, 14, .92), rgba(8, 7, 6, .92));
    color: #f3efe8;
    text-align: left;
    cursor: pointer;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .03), 0 8px 24px rgba(0, 0, 0, .28);
}

.rank-elige__btn:disabled {
    cursor: default;
    opacity: .72;
}

.rank-elige.is-open .rank-elige__btn,
.rank-elige__btn:hover:not(:disabled) {
    border-color: #e4c27a;
}

.rank-elige__ico {
    display: grid;
    place-items: center;
    width: 1.7rem;
    flex: none;
    color: #e4c27a;
}

.rank-elige__ico svg { width: 1.45rem; height: 1.45rem; }
.rank-elige__ico img,
.rank-elige__menu a img {
    width: 1.85rem;
    height: 1.85rem;
    object-fit: contain;
    mix-blend-mode: screen;
    flex: none;
}

.rank-elige__texto {
    display: flex;
    flex-direction: column;
    min-width: 0;
    flex: 1;
}

.rank-elige__texto small {
    color: rgba(228, 194, 122, .78);
    font-size: .62rem;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.rank-elige__texto strong {
    overflow: hidden;
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rank-elige__caret {
    width: .55rem;
    height: .55rem;
    border-right: 2px solid rgba(243, 239, 232, .75);
    border-bottom: 2px solid rgba(243, 239, 232, .75);
    transform: rotate(45deg) translateY(-2px);
    flex: none;
}

.rank-elige.is-open .rank-elige__caret { transform: rotate(225deg) translateY(-2px); }

.rank-elige__menu {
    position: absolute;
    z-index: 5;
    top: calc(100% + .4rem);
    left: 0;
    right: 0;
    max-height: 280px;
    overflow: auto;
    padding: .35rem;
    border: 1px solid rgba(212, 175, 90, .65);
    border-radius: 12px;
    background: #120e0c;
    box-shadow: 0 16px 40px rgba(0, 0, 0, .45);
}

.rank-elige__menu[hidden] { display: none; }

.rank-elige__q {
    width: 100%;
    margin-bottom: .35rem;
    padding: .45rem .6rem;
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 8px;
    background: #0c0b0a;
    color: #f3efe8;
    font: inherit;
    font-size: .85rem;
}

.rank-elige__menu a {
    display: flex;
    align-items: center;
    gap: .55rem;
    padding: .45rem .7rem;
    border-radius: 8px;
    color: #f3efe8;
    font-weight: 650;
    text-decoration: none;
}

.rank-elige__menu a:hover,
.rank-elige__menu a.is-active { background: #9b1c1c; }

.rank-elige__vacio {
    margin: .35rem .5rem;
    color: rgba(243, 239, 232, .55);
    font-size: .82rem;
}

.rank-escena__aviso {
    margin: 1.2rem 0 0;
    text-align: center;
    color: rgba(243, 239, 232, .68);
}

.rank-lista { margin-top: 1rem; }

.rank-fila {
    display: grid;
    grid-template-columns: auto auto minmax(0, 1fr);
    align-items: center;
    gap: .8rem;
    margin-top: .55rem;
    padding: .62rem .8rem .62rem .7rem;
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 16px;
    background: linear-gradient(90deg, #161311 0%, #0d0b0a 100%);
    color: inherit;
    text-decoration: none;
}

.rank-fila--1 {
    border-color: rgba(212, 175, 90, .9);
    background: linear-gradient(90deg, #4a3914 0%, #231b0d 48%, #1a140c 100%);
    box-shadow: 0 0 0 1px rgba(228, 194, 122, .18), 0 10px 28px rgba(0, 0, 0, .35);
}

.rank-fila--2 {
    border-color: rgba(196, 198, 204, .38);
    background: linear-gradient(90deg, #2c2d31 0%, #141416 62%);
}

.rank-fila--3 {
    border-color: rgba(184, 112, 58, .62);
    background: linear-gradient(90deg, #3d2614 0%, #16110e 62%);
}

.rank-medalla {
    display: grid;
    place-items: center;
    width: 2.15rem;
    height: 2.15rem;
    border-radius: 50%;
    border: 2px solid rgba(228, 194, 122, .28);
    background:
        radial-gradient(circle at 35% 28%, rgba(255, 255, 255, .16), transparent 42%),
        #1a1714;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .12), 0 2px 6px rgba(0, 0, 0, .35);
    color: #f3efe8;
    font-family: Cinzel, serif;
    font-size: .95rem;
    font-weight: 700;
    line-height: 1;
}

.rank-medalla--1 {
    border-color: #f0d48a;
    color: #3d2a08;
    background:
        radial-gradient(circle at 32% 28%, #fff6d4, #e8c56a 46%, #a67c2d 78%);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .65), 0 0 0 3px rgba(228, 194, 122, .18);
}

.rank-medalla--2 {
    border-color: #ece8e2;
    color: #2a2724;
    background:
        radial-gradient(circle at 32% 28%, #ffffff, #d5d0c8 48%, #8d8882 80%);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .7), 0 0 0 3px rgba(210, 208, 204, .16);
}

.rank-medalla--3 {
    border-color: #e0b48a;
    color: #3a2010;
    background:
        radial-gradient(circle at 32% 28%, #f8d7b8, #c47a45 50%, #7a431c 82%);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45), 0 0 0 3px rgba(196, 122, 69, .18);
}

.rank-fila__foto {
    display: grid;
    place-items: center;
    width: 2.55rem;
    height: 2.55rem;
    overflow: hidden;
    border: 2px solid rgba(228, 194, 122, .35);
    border-radius: 50%;
    background: radial-gradient(circle at 50% 35%, #3a3836, #121110 70%);
    color: rgba(243, 239, 232, .7);
}

.rank-fila--1 .rank-fila__foto { border-color: #e4c27a; }
.rank-fila--2 .rank-fila__foto { border-color: #c9c6c1; }
.rank-fila--3 .rank-fila__foto { border-color: #c47a45; }

.rank-fila__foto img,
.rank-fila__foto svg { width: 100%; height: 100%; object-fit: cover; }

.rank-fila__foto svg { width: 68%; height: 68%; }

.rank-fila__texto { min-width: 0; }

.rank-fila__texto strong {
    display: block;
    overflow: hidden;
    font-size: 1.02rem;
    font-weight: 800;
    letter-spacing: .01em;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rank-fila--1 .rank-fila__texto strong { color: #f0d48a; }

.rank-fila__texto small {
    display: block;
    overflow: hidden;
    margin-top: .12rem;
    color: rgba(243, 239, 232, .62);
    font-size: .75rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

@media (max-width: 720px) {
    .rank-escena { padding-top: 1.4rem; }
    .rank-laurel { width: 36px; height: 78px; }
    .rank-escena__esgrimista,
    .rank-escena__monte { opacity: .35; }
    .rank-escena__filtros { grid-template-columns: 1fr; }
    .rank-fila { gap: .55rem; padding-right: .6rem; }
}
