/* ==========================================================
   NEXUS MU Season 3 - AAA Cyber-Medieval Design System
   ========================================================== */

/* Variables de Color e Identidad */
:root {
    --color-cyan-neon: #66FCF1;
    --color-cyan-glow: rgba(102, 252, 241, 0.45);
    --color-gold-matte: #C5A059;
    --color-gold-glow: rgba(197, 160, 89, 0.4);
    --color-crimson: #FF3B30;
    --color-crimson-glow: rgba(255, 59, 48, 0.55);
    --bg-dark: #0b0c10;
    --bg-card: #0f121d;
}

body {
    background-color: var(--bg-dark);
    color: #c5c6c7;
    background-image: 
        radial-gradient(circle at 50% 0%, rgba(102, 252, 241, 0.06), transparent 50%),
        radial-gradient(circle at 100% 60%, rgba(20, 30, 55, 0.25), transparent 40%),
        radial-gradient(circle at 0% 80%, rgba(197, 160, 89, 0.04), transparent 45%);
    background-attachment: fixed;
    overflow-x: hidden;
}

/* Scrollbar estilizada */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
::-webkit-scrollbar-track {
    background: #06070a;
}
::-webkit-scrollbar-thumb {
    background: #1f293d;
    border-radius: 4px;
    border: 1px solid rgba(102, 252, 241, 0.15);
}
::-webkit-scrollbar-thumb:hover {
    background: #66FCF1;
    box-shadow: 0 0 10px var(--color-cyan-glow);
}

/* ==========================================================
   1. HEADER ÉPICO CINEMATOGRÁFICO (SITE-HEADER)
   ========================================================== */

/* Contenedor principal del header */
.site-header {
    background: linear-gradient(to bottom, #0d0e16 0%, #0b0c10 100%);
    border-bottom: 1px solid rgba(197, 160, 89, 0.35);
}

/* Imagen de arte de fondo: usa mu-trio-battle.jpg a baja opacidad */
.header-art-backdrop {
    position: absolute;
    inset: 0;
    background-image: url('/static/img/mu-trio-battle.jpg');
    background-size: cover;
    background-position: center 20%;
    opacity: 0.18;
    filter: saturate(0.6) sepia(0.3) brightness(0.7);
    z-index: 0;
}

/* Viñeta oscura para que el texto sea legible */
.header-art-vignette {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(to bottom, rgba(11,12,16,0.82) 0%, rgba(11,12,16,0.55) 40%, rgba(11,12,16,0.88) 100%),
        radial-gradient(ellipse at center, transparent 30%, rgba(11,12,16,0.75) 100%);
    z-index: 0;
}

/* Líneas ornamentales horizontales doradas */
.header-ornament-line {
    width: 100%;
    max-width: 520px;
    height: 1px;
    background: linear-gradient(to right,
        transparent 0%,
        rgba(197,160,89,0.25) 15%,
        rgba(248,181,0,0.8) 40%,
        rgba(252,234,187,1) 50%,
        rgba(248,181,0,0.8) 60%,
        rgba(197,160,89,0.25) 85%,
        transparent 100%);
    position: relative;
}
/* Diamante central en la línea */
.header-ornament-line::before {
    content: '◆';
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    font-size: 0.55rem;
    color: #F8B500;
    text-shadow: 0 0 8px rgba(248,181,0,0.9);
    background: #0b0c10;
    padding: 0 4px;
    line-height: 1;
}

/* Emblema / Escudo central */
.header-emblem {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    background: radial-gradient(circle, rgba(197,160,89,0.15) 0%, transparent 70%);
    border: 1.5px solid rgba(197,160,89,0.45);
    border-radius: 50%;
    box-shadow:
        0 0 20px rgba(197,160,89,0.25),
        inset 0 0 15px rgba(197,160,89,0.08);
}

/* Título principal NEXUS MU en el header */
.header-logo-title {
    font-family: 'Cinzel Decorative', 'Cinzel', serif;
    font-weight: 900;
    font-size: clamp(2.2rem, 6vw, 3.8rem);
    letter-spacing: 0.18em;
    text-transform: uppercase;
    background: linear-gradient(135deg,
        #FCEABB 0%,
        #F8B500 25%,
        #FFFFFF 48%,
        #F8B500 72%,
        #C5A059 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: none;
    filter: drop-shadow(0 0 18px rgba(248,181,0,0.55));
    line-height: 1.1;
    margin-bottom: 0.35rem;
}

/* Subtítulo debajo del logo */
.header-logo-subtitle {
    font-family: 'Cinzel', serif;
    font-weight: 600;
    font-size: clamp(0.65rem, 1.8vw, 0.85rem);
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: rgba(197,160,89,0.85);
    text-shadow: 0 0 12px rgba(197,160,89,0.4);
}

/* Pills de información del servidor */
.header-pill {
    display: inline-flex;
    align-items: center;
    background: rgba(11, 12, 20, 0.75);
    border: 1px solid rgba(197,160,89,0.3);
    border-radius: 999px;
    padding: 0.3rem 0.85rem;
    font-family: 'PT Sans', sans-serif;
    font-size: 0.72rem;
    color: rgba(200,195,185,0.9);
    backdrop-filter: blur(6px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.4), inset 0 1px 0 rgba(255,255,255,0.04);
    transition: border-color 0.25s ease;
}
.header-pill:hover {
    border-color: rgba(248,181,0,0.55);
}

/* Botones de autenticación del header */
.header-auth-btn {
    display: inline-flex;
    align-items: center;
    padding: 0.4rem 0.9rem;
    font-family: 'Cinzel', serif;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(197,160,89,0.9);
    background: transparent;
    border: 1px solid rgba(197,160,89,0.4);
    border-radius: 0.35rem;
    cursor: pointer;
    transition: all 0.25s ease;
}
.header-auth-btn:hover {
    color: #fff;
    border-color: rgba(248,181,0,0.8);
    background: rgba(248,181,0,0.08);
}

.header-auth-btn-primary {
    display: inline-flex;
    align-items: center;
    padding: 0.4rem 1rem;
    font-family: 'Cinzel', serif;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #0b0c10;
    background: linear-gradient(135deg, #F8B500 0%, #C5A059 100%);
    border: none;
    border-radius: 0.35rem;
    cursor: pointer;
    box-shadow: 0 0 14px rgba(248,181,0,0.4), 0 2px 6px rgba(0,0,0,0.5);
    transition: all 0.25s ease;
}
.header-auth-btn-primary:hover {
    background: linear-gradient(135deg, #FCEABB 0%, #F8B500 100%);
    box-shadow: 0 0 22px rgba(248,181,0,0.65), 0 4px 10px rgba(0,0,0,0.5);
    transform: translateY(-1px);
}

/* Barra de navegación inferior del header */
.site-nav {
    background: rgba(7, 9, 18, 0.96);
    border-top: 1px solid rgba(197,160,89,0.25);
    border-bottom: 1px solid rgba(197,160,89,0.12);
    backdrop-filter: blur(10px);
}

/* ==========================================================
   2. NAVEGACIÓN (MICRO-INTERACCIONES)
   ========================================================== */

.nav-btn {
    position: relative;
    padding: 0.65rem 1.15rem;
    color: var(--color-gold-matte);
    font-family: 'Cinzel', serif;
    font-weight: 700;
    font-size: 0.8rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    background: transparent;
    border: none;
    cursor: pointer;
    transition: color 0.12s ease, text-shadow 0.12s ease;
    will-change: color, text-shadow;
}

.nav-btn:active,
.header-auth-btn:active,
.header-auth-btn-primary:active,
.webshop-cat:active,
.webshop-trait:active,
.btn:active,
button:active {
    transform: scale(0.96) !important;
    transition: transform 0.04s ease !important;
}

/* Línea cian neón que nace del centro hacia los lados */
.nav-btn::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--color-cyan-neon);
    box-shadow: 0 0 8px var(--color-cyan-neon), 0 0 16px var(--color-cyan-glow);
    transition: width 0.15s cubic-bezier(0.2, 0.8, 0.2, 1), left 0.15s cubic-bezier(0.2, 0.8, 0.2, 1);
    transform: translateX(-50%);
    will-change: width, left;
}

.nav-btn:hover {
    color: #ffffff;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.8), 0 0 20px var(--color-cyan-glow);
}

.nav-btn:hover::after,
.nav-btn.active::after {
    width: 85%;
}

.nav-btn.active {
    color: #ffffff;
    text-shadow: 0 0 12px var(--color-cyan-glow);
    background: linear-gradient(180deg, transparent, rgba(102, 252, 241, 0.05));
}

/* Indicadores Circulares de Estado (Panel Arriba a la Derecha) */
.status-indicator-online {
    background-color: var(--color-cyan-neon);
    box-shadow: 0 0 10px var(--color-cyan-neon), 0 0 20px var(--color-cyan-glow);
    animation: statusPulseCyan 2s infinite ease-in-out;
}

.status-indicator-offline {
    background-color: var(--color-crimson);
    box-shadow: 0 0 10px var(--color-crimson), 0 0 18px var(--color-crimson-glow);
}

@keyframes statusPulseCyan {
    0%, 100% {
        opacity: 1;
        box-shadow: 0 0 10px var(--color-cyan-neon), 0 0 20px var(--color-cyan-glow);
    }
    50% {
        opacity: 0.55;
        box-shadow: 0 0 5px var(--color-cyan-neon), 0 0 10px var(--color-cyan-glow);
    }
}

/* Cajas de Estadísticas de Alta Fidelidad (1500x, 50%, 400) */
.stat-mini-box {
    background: rgba(4, 6, 12, 0.88);
    border: 1px solid rgba(102, 252, 241, 0.18);
    border-radius: 0.5rem;
    padding: 0.35rem 0.5rem;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), 0 4px 10px rgba(0, 0, 0, 0.5);
    transition: border-color 0.25s ease, transform 0.25s ease;
}

.stat-mini-box:hover {
    border-color: rgba(102, 252, 241, 0.45);
    transform: translateY(-1px);
}

/* ==========================================================
   2. HERO SECTION / BANNER PRINCIPAL (DARK FANTASY MEDIEVAL)
   ========================================================== */

.hero-medieval-banner,
.hero-cyber-banner {
    position: relative;
    border-radius: 0.375rem; /* Borde severo de forja y pergamino */
    background-color: #0b0d14;
    border: 1px solid rgba(197, 160, 89, 0.45);
    box-shadow: 0 20px 50px -10px rgba(0, 0, 0, 0.95), 
                inset 0 0 0 1px rgba(197, 160, 89, 0.15), 
                inset 0 1px 0 rgba(252, 234, 187, 0.25), 
                0 0 35px rgba(197, 160, 89, 0.1);
    overflow: hidden;
}

/* Capa de imagen artística con animación sutil de respiración y vida */
.hero-art-backdrop {
    position: absolute;
    inset: 0;
    background-image: url('/static/img/hero-grandmaster.png');
    background-size: cover;
    background-position: right 18% center;
    background-repeat: no-repeat;
    animation: heroArtBreathe 16s infinite alternate ease-in-out;
    transform-origin: center right;
    will-change: transform;
    opacity: 0.92;
    z-index: 1;
}

@keyframes heroArtBreathe {
    0% {
        transform: scale(1) translateY(0);
    }
    100% {
        transform: scale(1.04) translateY(-6px);
    }
}

/* Gradientes cinemáticos de viñeteado e iluminación */
.hero-art-overlay {
    position: absolute;
    inset: 0;
    background: 
        linear-gradient(90deg, #090b10 0%, rgba(9, 11, 16, 0.95) 35%, rgba(9, 11, 16, 0.65) 60%, rgba(9, 11, 16, 0.35) 85%, rgba(9, 11, 16, 0.8) 100%),
        linear-gradient(180deg, rgba(9, 11, 16, 0.85) 0%, transparent 25%, transparent 75%, #090b10 100%),
        radial-gradient(circle at 25% 15%, rgba(197, 160, 89, 0.12) 0%, transparent 50%);
    pointer-events: none;
    z-index: 2;
}

/* Pulso de magia arcana en la esfera y báculo del mago */
.hero-arcane-pulse {
    position: absolute;
    right: 22%;
    top: 30%;
    width: 260px;
    height: 260px;
    background: radial-gradient(circle, rgba(102, 252, 241, 0.32) 0%, rgba(59, 130, 246, 0.14) 45%, transparent 70%);
    border-radius: 50%;
    filter: blur(20px);
    animation: arcanePulse 3.5s infinite ease-in-out;
    pointer-events: none;
    z-index: 3;
}

@keyframes arcanePulse {
    0%, 100% {
        opacity: 0.55;
        transform: scale(0.92);
    }
    50% {
        opacity: 1;
        transform: scale(1.12);
    }
}

/* Marco interior de herrería forjada */
.hero-medieval-banner::before,
.hero-cyber-banner::before {
    content: '';
    position: absolute;
    inset: 5px;
    border: 1px solid rgba(197, 160, 89, 0.22);
    border-radius: 0.25rem;
    pointer-events: none;
    z-index: 10;
}

/* Título de Gloria Eterna - Cinzel 900 con degradado de metal bruñido y oro imperial */
.hero-title-medieval,
.hero-title-orbitron {
    font-family: 'Cinzel', 'Cinzel Decorative', Georgia, serif;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    line-height: 1.18;
    background: linear-gradient(180deg, #FFFFFF 0%, #FCEABB 25%, #F8B500 70%, #A47918 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.95))
            drop-shadow(0 0 16px rgba(248, 181, 0, 0.35))
            drop-shadow(0 0 35px rgba(197, 160, 89, 0.2));
}

/* Texto Secundario Equilibrado (Sans-serif limpia al 75% de opacidad) */
.text-secondary-balanced {
    font-family: 'PT Sans', 'Inter', sans-serif;
    color: #d1d5db;
    opacity: 0.75;
}

/* Botón CTA Primario con destello Shimmer dorado */
.btn-cta-shimmer {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #F8B500 0%, #D49000 50%, #9B6700 100%);
    color: #0b0c10;
    font-family: 'Cinzel', serif;
    font-weight: 900;
    letter-spacing: 0.12em;
    border-radius: 0.375rem;
    border: 1px solid rgba(252, 234, 187, 0.6);
    box-shadow: 0 0 18px rgba(248, 181, 0, 0.35), 0 8px 20px -4px rgba(0, 0, 0, 0.8);
    transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
    will-change: transform, box-shadow;
}

.btn-cta-shimmer::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -150%;
    width: 60%;
    height: 200%;
    background: linear-gradient(
        115deg,
        transparent,
        rgba(255, 255, 255, 0.65) 50%,
        transparent
    );
    transform: rotate(25deg);
    animation: ctaShimmerSweeper 3s infinite cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none;
}

@keyframes ctaShimmerSweeper {
    0% {
        left: -150%;
    }
    30%, 100% {
        left: 200%;
    }
}

.btn-cta-shimmer:hover {
    transform: scale(1.03);
    box-shadow: 0 0 28px rgba(248, 181, 0, 0.65), 0 0 45px rgba(212, 144, 0, 0.4);
}

/* Botón Secundario (Crear Cuenta) */
.btn-cta-secondary {
    position: relative;
    background: rgba(16, 18, 26, 0.9);
    color: #FCEABB;
    border: 1px solid rgba(197, 160, 89, 0.45);
    border-radius: 0.375rem;
    font-family: 'Cinzel', serif;
    font-weight: 700;
    letter-spacing: 0.12em;
    transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1), 
                box-shadow 0.25s cubic-bezier(0.2, 0.8, 0.2, 1),
                border-color 0.25s ease,
                background 0.25s ease;
    will-change: transform, box-shadow;
}

.btn-cta-secondary:hover {
    transform: scale(1.03);
    border-color: #FCEABB;
    color: #FFFFFF;
    box-shadow: 0 0 20px rgba(197, 160, 89, 0.35);
    background: rgba(26, 30, 44, 0.95);
}

/* ==========================================================
   3. TARJETAS INFERIORES Y EVENTOS (ESTILO FORJA Y GREMIO)
   ========================================================== */

.cyber-card,
.medieval-card {
    background: linear-gradient(180deg, #11141e 0%, #090b10 100%);
    border: 1px solid rgba(197, 160, 89, 0.22);
    border-top: 2px solid rgba(197, 160, 89, 0.4);
    border-radius: 0.375rem; /* Borde severo rústico */
    position: relative;
    overflow: hidden;
    box-shadow: 0 14px 30px -8px rgba(0, 0, 0, 0.85), inset 0 1px 0 rgba(255, 255, 255, 0.03);
    transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1), 
                box-shadow 0.3s cubic-bezier(0.2, 0.8, 0.2, 1), 
                border-color 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
    will-change: transform, box-shadow, border-color;
}

.cyber-card:hover,
.medieval-card:hover {
    transform: translateY(-4px);
    border-color: rgba(197, 160, 89, 0.55);
    border-top-color: #FCEABB;
    box-shadow: 0 -3px 20px rgba(197, 160, 89, 0.25), 
                0 18px 36px -8px rgba(0, 0, 0, 0.95);
}

/* Títulos internos de tarjetas en Cinzel 600 */
.card-title-medieval {
    font-family: 'Cinzel', serif;
    font-weight: 600;
    font-size: 0.875rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #F3E5AB;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8), 0 0 12px rgba(197, 160, 89, 0.25);
}

/* Escudo Medieval Flotante del Clan Defensor (Fuego & Asedio) */
.floating-crest-badge {
    position: relative;
    width: 72px;
    height: 72px;
    margin: 0.5rem auto;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(217, 119, 6, 0.22) 0%, rgba(180, 83, 9, 0.1) 45%, rgba(12, 14, 20, 0.95) 80%);
    border: 1px solid rgba(197, 160, 89, 0.5);
    box-shadow: 0 0 20px rgba(245, 158, 11, 0.25), 0 0 40px rgba(185, 28, 28, 0.15), inset 0 0 15px rgba(217, 119, 6, 0.18);
    transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.3s ease;
    will-change: transform, box-shadow;
}

.cyber-card:hover .floating-crest-badge,
.medieval-card:hover .floating-crest-badge {
    transform: scale(1.08);
    box-shadow: 0 0 28px rgba(245, 158, 11, 0.5), 0 0 55px rgba(220, 38, 38, 0.28), inset 0 0 20px rgba(217, 119, 6, 0.28);
}

/* Pulso de Urgencia para el Asedio del Domingo */
.siege-urgent-pulse {
    animation: siegePulseActive 1.6s infinite ease-in-out;
}

@keyframes siegePulseActive {
    0%, 100% {
        opacity: 1;
        color: #FF5A5F;
        text-shadow: 0 0 12px rgba(255, 90, 95, 0.9), 0 0 24px rgba(255, 90, 95, 0.45);
        transform: scale(1);
    }
    50% {
        opacity: 0.7;
        color: #FFA39E;
        text-shadow: 0 0 4px rgba(255, 90, 95, 0.4);
        transform: scale(0.98);
    }
}

/* Rankings & Tabs Generales */
.rank-type-btn.active {
    background: linear-gradient(135deg, #00C4CC 0%, #0088EE 100%);
    color: #040814;
    font-weight: 800;
    box-shadow: 0 0 15px rgba(102, 252, 241, 0.3);
}

.class-filter-btn.active {
    background-color: rgba(102, 252, 241, 0.15);
    color: #ffffff;
    border-color: var(--color-cyan-neon);
    box-shadow: 0 0 10px rgba(102, 252, 241, 0.25);
}

/* Insignias de Clase */
.badge-dw, .badge-sm, .badge-gm {
    background-color: rgba(59, 130, 246, 0.15);
    color: #93c5fd;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.badge-dk, .badge-bk, .badge-bm {
    background-color: rgba(239, 68, 68, 0.15);
    color: #fca5a5;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.badge-fe, .badge-me, .badge-he {
    background-color: rgba(16, 185, 129, 0.15);
    color: #6ee7b7;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.badge-mg, .badge-dm {
    background-color: rgba(168, 85, 247, 0.15);
    color: #d8b4fe;
    border: 1px solid rgba(168, 85, 247, 0.3);
}

.badge-dl, .badge-le {
    background-color: rgba(197, 160, 89, 0.15);
    color: #fcd34d;
    border: 1px solid rgba(197, 160, 89, 0.3);
}

/* ==========================================================
   4. CAPAS ARTÍSTICAS DE ALTA RESOLUCIÓN EN TARJETAS
   ========================================================== */

.card-art-layer {
    position: absolute;
    inset: 0;
    opacity: 0.14;
    transition: opacity 0.5s cubic-bezier(0.2, 0.8, 0.2, 1), transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
    pointer-events: none;
    will-change: opacity, transform;
}

.card-bg-citadel {
    background-image: url('/static/img/castle-citadel.jpg');
    background-size: cover;
    background-position: center 30%;
}

.card-bg-trio {
    background-image: url('/static/img/mu-trio-battle.jpg');
    background-size: cover;
    background-position: center 25%;
}

.card-bg-elf {
    background-image: url('/static/img/hero-elf-4k.jpg');
    background-size: cover;
    background-position: center 25%;
}

.cyber-card:hover .card-art-layer,
.medieval-card:hover .card-art-layer {
    opacity: 0.32;
    transform: scale(1.06);
}

/* Banner de Descargas Cinemático */
.descargas-hero-banner {
    position: relative;
    border-radius: 0.375rem;
    border: 1px solid rgba(197, 160, 89, 0.45);
    background-color: #0b0d14;
    overflow: hidden;
    box-shadow: 0 16px 40px -10px rgba(0, 0, 0, 0.9);
}

.descargas-hero-backdrop {
    position: absolute;
    inset: 0;
    background-image: url('/static/img/hero-elf-4k.jpg');
    background-size: cover;
    background-position: center 20%;
    opacity: 0.32;
    transition: transform 12s ease-in-out;
    will-change: transform;
}

.descargas-hero-banner:hover .descargas-hero-backdrop {
    transform: scale(1.04);
}

/* Vitrina de Clases Legendarias (Showcase) */
.class-showcase-card {
    position: relative;
    border-radius: 0.375rem;
    border: 1px solid rgba(197, 160, 89, 0.25);
    background: #0d0f17;
    overflow: hidden;
    transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1), 
                box-shadow 0.3s ease, 
                border-color 0.3s ease;
    will-change: transform, box-shadow;
}

.class-showcase-card:hover {
    transform: translateY(-5px);
    border-color: rgba(197, 160, 89, 0.65);
    box-shadow: 0 16px 35px -8px rgba(0, 0, 0, 0.95), 0 0 22px rgba(197, 160, 89, 0.22);
}

/* Grilla de la tienda: 8 columnas, igual que el NPC de resets. */
.shop-window {
    display: grid;
    gap: 3px;
    width: max-content;
    padding: 10px;
    background: #07080d;
    border: 1px solid rgba(197, 160, 89, 0.45);
    box-shadow: inset 0 0 24px rgba(0, 0, 0, 0.65);
}

.shop-slot {
    position: relative;
    background: rgba(18, 20, 30, 0.92);
    border: 1px solid rgba(197, 160, 89, 0.18);
    min-width: 0;
    min-height: 0;
}

.shop-item {
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    padding: 2px;
}

.shop-item img {
    width: auto;
    height: auto;
    max-width: 88%;
    max-height: 88%;
}

.shop-count {
    position: absolute;
    right: 3px;
    bottom: 1px;
    font-size: 10px;
    font-weight: 800;
    color: #f6e3a4;
    text-shadow: 0 1px 2px #000;
}

.shop-exc { border-color: #22c55e; box-shadow: inset 0 0 8px rgba(34, 197, 94, 0.35); }
.shop-ancient { border-color: #eab308; }
.shop-luck { border-color: #38bdf8; }

/* Catálogo del mundo, misma composición que una webshop. */
.webshop {
    background: #120e0c;
    border: 1px solid #5a3e22;
    box-shadow: 0 0 0 1px #1a120e, 0 18px 40px rgba(0, 0, 0, 0.45);
}

.webshop-title {
    text-align: center;
    color: #e6b34d;
    font-family: Cinzel, serif;
    letter-spacing: 0.28em;
    font-size: 1.05rem;
    padding: 0.85rem 1rem 0.7rem;
    border-bottom: 1px solid #3a2818;
}

.webshop-body {
    display: grid;
    grid-template-columns: 190px 1fr;
    min-height: 36rem;
}

.webshop-side {
    border-right: 1px solid #3a2818;
    padding: 0.75rem 0.55rem;
    background: #0e0b09;
}

.webshop-side-label {
    color: #e6b34d;
    font-size: 0.68rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    margin: 0 0.35rem 0.45rem;
}

.webshop-cat {
    display: flex;
    justify-content: space-between;
    width: 100%;
    text-align: left;
    color: #d7c4a3;
    font-size: 0.75rem;
    padding: 0.28rem 0.45rem;
    border-radius: 2px;
}

.webshop-cat span { color: #8a7352; }

.webshop-cat.is-active,
.webshop-cat:hover {
    background: #2a1c12;
    color: #f3d48a;
}

.webshop-main { padding: 0.85rem 0.9rem 1rem; }

.webshop-filters {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    margin-bottom: 0.75rem;
}

.webshop-traits {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}

.webshop-trait {
    background: #0b0908;
    color: #d7c4a3;
    border: 1px solid #4a3422;
    padding: 0.28rem 0.65rem;
    font-size: 0.72rem;
    letter-spacing: 0.04em;
}

.webshop-trait.is-active,
.webshop-trait:hover {
    background: #2a1c12;
    color: #f3d48a;
    border-color: #e6b34d;
}

.webshop-search {
    display: flex;
    gap: 0.4rem;
}

.webshop-search input {
    flex: 1;
    background: #0b0908;
    border: 1px solid #4a3422;
    color: #f5efe4;
    border-radius: 2px;
    padding: 0.4rem 0.6rem;
    font-size: 0.8rem;
}

.webshop-search button,
.webshop-page {
    background: #2a1c12;
    color: #f3d48a;
    border: 1px solid #6b4b28;
    padding: 0.35rem 0.7rem;
    font-size: 0.72rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.webshop-list {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.webshop-row {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr) auto;
    gap: 0.7rem;
    align-items: center;
    width: 100%;
    text-align: left;
    padding: 0.28rem 0.55rem;
    background: #0e0b09;
    border: 1px solid #3a2a1c;
    min-width: 0;
}

.webshop-row:hover {
    border-color: #6a4a28;
    background: #16110e;
}

.webshop-row-text {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    min-width: 0;
}

.item-sprite {
    max-width: 9rem;
    max-height: 9rem;
    object-fit: contain;
}

.webshop-name {
    color: #e6b34d;
    font-size: 0.84rem;
    font-weight: 600;
    line-height: 1.2;
    text-align: left;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-shadow: 0 1px 0 #000;
}

.webshop-art {
    position: relative;
    width: 52px;
    height: 52px;
    background: radial-gradient(ellipse at center, #1a120c 0%, #070605 68%);
    border: 1px solid #6a4a28;
    box-shadow: inset 0 0 0 1px #140e09;
    overflow: hidden;
}

.webshop-art img {
    position: absolute;
    inset: 4%;
    width: 92%;
    height: 92%;
    max-width: 92%;
    max-height: 92%;
    object-fit: contain;
    image-rendering: auto;
}

.webshop-copies {
    color: #b7a48c;
    font-size: 0.72rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.webshop-count {
    min-width: 2rem;
    padding: 0.15rem 0.5rem;
    text-align: center;
    color: #f6e3a4;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    border: 1px solid #6a4a28;
    background: #1a120c;
}

.webshop-row.is-exc .webshop-name { color: #4ade80; }
.webshop-row.is-ancient .webshop-name { color: #facc15; }
.webshop-row.is-luck .webshop-name { color: #7dd3fc; }

.webshop-empty {
    color: #e6b34d;
    font-size: 0.8rem;
    margin-bottom: 0.6rem;
}

.webshop-pager {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.85rem;
    color: #b7a48c;
    font-size: 0.72rem;
}

.webshop-pages { display: flex; gap: 0.25rem; flex-wrap: wrap; }
.webshop-page.is-active { background: #e6b34d; color: #1a120c; }

.webshop-detail {
    margin-bottom: 0.8rem;
    background: #0e0b09;
    border: 1px solid #5a3e22;
    padding: 0.9rem;
}

.webshop-attr-label {
    margin: 0.7rem 0 0.25rem;
    color: #e6b34d;
    font-size: 0.68rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.webshop-attrs {
    list-style: none;
    margin: 0 0 0.6rem;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.18rem;
}

.webshop-attrs li {
    font-size: 0.8rem;
    color: #d7c4a3;
}

.webshop-attrs .is-excellent { color: #4ade80; }
.webshop-attrs .is-ancient { color: #facc15; }
.webshop-attrs .is-luck,
.webshop-attrs .is-skill { color: #7dd3fc; }
.webshop-attrs .is-option,
.webshop-attrs .is-harmony { color: #f6e3a4; }

@media (max-width: 900px) {
    .webshop-body { grid-template-columns: 1fr; }
    .webshop-side { border-right: 0; border-bottom: 1px solid #3a2818; }
}
