﻿/* ============================================================
   Ironhorde Online -- Game Client Styles
   Uses shared_base.css design tokens (--bg, --primary, --accent, etc.)
   ============================================================ */

/* ── Base Overrides (game page is fullscreen) ── */
html, body {
    width: 100%;
    height: 100%;
    overflow: hidden;
    background: var(--bg);
    font-family: var(--font);
    color: var(--text);
    user-select: none;
}

.hidden { display: none !important; }

body.ih-disconnect-lock #renderCanvas,
body.ih-disconnect-lock #game-hud,
body.ih-disconnect-lock #labels-overlay {
    pointer-events: none !important;
}

body.ih-disconnect-lock > :not(#kick-overlay) {
    pointer-events: none !important;
}

body.ih-disconnect-lock #kick-overlay,
body.ih-disconnect-lock #kick-overlay * {
    pointer-events: auto;
}

/* ── Render Canvas ── */
#renderCanvas {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: 0;
    outline: none;
    touch-action: none;
    cursor: url("/play/images/cursor_game.png") 0 0, default;
}
#renderCanvas.hide-cursor {
    cursor: none !important;
}

/* ── HTML Overlay Labels (crisp vector text over 3D world) ── */
#labels-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    pointer-events: none;
    z-index: 5;
    overflow: hidden;
}

.ih-label {
    position: absolute;
    left: 0;
    top: 0;
    white-space: nowrap;
    text-align: center;
    font-family: var(--font-h);
    line-height: 1.35;
    pointer-events: none;
    will-change: transform;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.ih-label__gm {
    font-size: 1.6em;
    color: #f39c12;
    font-weight: 900;
    text-shadow:
        0 1px 4px rgba(0, 0, 0, 0.9);
    animation: gm-breathe 2.5s ease-in-out infinite;
}
@keyframes gm-breathe {
    0%, 100% {
        font-size: 1.6em;
        text-shadow: 0 1px 4px rgba(0,0,0,0.9);
        opacity: 1;
    }
    50% {
        font-size: 1.7em;
        text-shadow: 0 1px 6px rgba(0,0,0,0.9), 0 0 8px rgba(243,156,18,0.4);
        opacity: 0.9;
    }
}

.ih-label__clan-row {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.ih-label__clan-logo {
    width: 18px;
    height: 18px;
    display: block;
    image-rendering: auto;
    border-radius: 2px;
    flex-shrink: 0;
    object-fit: contain;
    position: absolute;
    right: calc(100% + 5px);
    top: 50%;
    transform: translateY(-50%);
}

.ih-label__clan {
    font-size: 1.45em;
    color: #e74c3c;
    font-weight: 700;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.95);
}

.ih-label__name {
    font-size: 1.38em;
    font-weight: 700;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.95);
}
.ih-label__name-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.32em;
}
.ih-label__relation-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: none;
    background: none;
    font: inherit;
    line-height: 1;
    cursor: help;
    pointer-events: auto;
}
.ih-label__relation-btn--beloved {
    color: #ff6b95;
    text-shadow:
        0 0 6px rgba(255, 107, 149, 0.5),
        0 1px 3px rgba(0, 0, 0, 0.95);
    transition: transform 0.15s ease, filter 0.15s ease;
}
.ih-label__relation-btn--beloved:hover {
    transform: scale(1.12);
    filter: brightness(1.08);
}

.ih-label__bubble {
    max-width: 260px;
    white-space: normal;
    word-wrap: break-word;
    padding: 4px 10px;
    margin-bottom: 2px;
    border-radius: 6px;
    background: rgba(0, 0, 0, 0.8);
    border: 1px solid rgba(108, 92, 231, 0.6);
    color: #E8DEFF;
    font-size: 1.1em;
    font-weight: 700;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
    text-align: center;
}

.ih-label__merchant {
    display: none;
    min-width: 160px;
    max-width: 250px;
    margin-bottom: 4px;
    padding: 7px 8px 8px;
    border: 1px solid rgba(246, 191, 74, 0.55);
    border-radius: 10px;
    background:
        linear-gradient(180deg, rgba(82, 55, 10, 0.95), rgba(42, 24, 8, 0.95)),
        rgba(0, 0, 0, 0.78);
    color: #fff2c2;
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.16),
        0 8px 18px rgba(12, 8, 28, 0.25);
    font-family: var(--font);
    text-align: center;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
    appearance: none;
    cursor: pointer;
    pointer-events: auto;
}

.ih-label__merchant:hover {
    border-color: rgba(255, 223, 92, 0.8);
    filter: brightness(1.05);
}

.ih-label__merchant-title {
    display: block;
    margin-bottom: 6px;
    font-family: var(--font-h);
    font-size: 0.86em;
    font-weight: 800;
    letter-spacing: 0.04em;
    color: #ffe18a;
    text-transform: uppercase;
}

.ih-label__merchant-items {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px;
}

.ih-label__merchant-item {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border: 1px solid rgba(255, 226, 138, 0.42);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(255,255,255,0.12), rgba(0,0,0,0.15));
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.12);
    overflow: visible;
}

.ih-label__merchant-icon,
.ih-label__merchant-icon-fallback {
    width: 30px;
    height: 30px;
    border-radius: 6px;
    display: block;
}

.ih-label__merchant-icon {
    object-fit: cover;
}

.ih-label__merchant-icon-fallback {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(32, 16, 5, 0.92);
    color: #ffe7a1;
    font-size: 1.05em;
    font-weight: 900;
}

.ih-label__merchant-qty {
    position: absolute;
    right: -4px;
    bottom: -4px;
    min-width: 18px;
    padding: 0 5px;
    border-radius: 999px;
    background: #6c5ce7;
    color: #fff;
    font-size: 0.7em;
    font-weight: 800;
    line-height: 18px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.45);
}

.ih-label__merchant-price {
    position: absolute;
    left: 50%;
    top: calc(100% + 2px);
    transform: translateX(-50%);
    padding: 2px 5px;
    border-radius: 999px;
    background: rgba(18, 12, 4, 0.96);
    border: 1px solid rgba(255, 215, 92, 0.5);
    color: #ffd86b;
    font-size: 0.68em;
    font-weight: 900;
    line-height: 1.2;
    white-space: nowrap;
}

.ih-label__merchant-line {
    display: block;
    font-size: 0.68em;
    font-weight: 700;
    line-height: 1.3;
}

.ih-label__mob-name {
    color: #e74c3c;
    font-weight: 700;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9);
}

/* ── Shared Screen Overlay ── */
#loading-screen,
#server-screen,
#character-screen,
#create-screen {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background:
        radial-gradient(ellipse at 20% 50%, rgba(108,92,231,0.03) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 20%, rgba(253,121,168,0.02) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 80%, rgba(108,92,231,0.02) 0%, transparent 50%),
        var(--bg);
}

#loading-screen { z-index: 1000; }
#server-screen  { z-index: 850; }
#character-screen { z-index: 800; }
#create-screen  { z-index: 800; }

/* ── Loading Screen ── */
.loading-content {
    text-align: center;
}

.screen-emblem {
    width: 80px; height: 80px;
    margin: 0 auto 18px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 50%;
    overflow: visible;
    position: relative;
    animation: emblem-float 3s ease-in-out infinite;
}
.screen-emblem::before {
    content: '';
    position: absolute;
    inset: -6px;
    border-radius: 50%;
    border: 2px solid transparent;
    border-top-color: var(--accent);
    border-right-color: rgba(108, 92, 231, 0.3);
    animation: emblem-spin 1.8s linear infinite;
    filter: drop-shadow(0 0 6px var(--accent));
}
.screen-emblem::after {
    content: '';
    position: absolute;
    inset: -12px;
    border-radius: 50%;
    border: 1.5px solid transparent;
    border-bottom-color: var(--accent);
    border-left-color: rgba(108, 92, 231, 0.2);
    animation: emblem-spin 2.8s linear infinite reverse;
    filter: drop-shadow(0 0 4px var(--accent));
}
.screen-emblem img {
    width: 100%; height: 100%; object-fit: contain;
    border-radius: 50%;
    animation: emblem-pulse 2.5s ease-in-out infinite;
    filter: drop-shadow(0 0 10px rgba(108, 92, 231, 0.5));
}

@keyframes emblem-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}
@keyframes emblem-spin {
    to { transform: rotate(360deg); }
}
@keyframes emblem-pulse {
    0%, 100% { filter: drop-shadow(0 0 8px rgba(108, 92, 231, 0.4)); }
    50% { filter: drop-shadow(0 0 18px rgba(108, 92, 231, 0.8)); }
}

.screen-title {
    font-family: var(--font-d);
    font-size: 2rem;
    font-weight: 700;
    color: var(--text);
    letter-spacing: 4px;
    text-transform: uppercase;
    text-align: center;
    margin-bottom: 2px;
}

.screen-title-sm {
    font-size: 1.3rem;
}

.screen-title .logo-accent {
    color: var(--accent);
}

.screen-subtitle {
    font-family: var(--font-h);
    font-size: 0.7rem;
    letter-spacing: 3px;
    color: var(--text-dim);
    text-transform: uppercase;
    text-align: center;
    margin-bottom: 8px;
}

.screen-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 32px;
}

.sd-line {
    width: 50px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    opacity: 0.25;
}

.sd-diamond {
    width: 6px; height: 6px;
    background: var(--accent);
    opacity: 0.35;
    transform: rotate(45deg);
}

.loading-bar-container {
    width: 360px;
    max-width: 80vw;
    height: 4px;
    background: rgba(108,92,231,0.08);
    border-radius: 2px;
    margin: 0 auto 16px;
    overflow: hidden;
    border: 1px solid var(--border);
}

.loading-bar {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, var(--accent-dim), var(--accent), var(--accent-light));
    border-radius: 2px;
    transition: width 0.3s ease;
    box-shadow: 0 0 12px var(--accent-glow);
}

#loading-text {
    font-family: var(--font-h);
    font-size: 0.75rem;
    color: var(--text-dim);
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

/* ── Play Box (login, char select, char create) ── */
.play-box {
    width: 100%;
    max-width: 420px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 44px 40px;
    position: relative;
    z-index: 1;
    overflow: hidden;
}

.play-box::before {
    content: '';
    position: absolute;
    top: -1px; left: 50%; transform: translateX(-50%);
    width: 50%;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    opacity: 0.4;
    border-radius: 2px;
}

.play-box-wide {
    max-width: 500px;
}

/* Ornamental corners */
.box-corner {
    position: absolute;
    width: 24px; height: 24px;
    z-index: 2;
}
.box-corner::before, .box-corner::after {
    content: '';
    position: absolute;
    background: #B86FD6;
    opacity: 0.25;
}
.box-corner-tl { top: 12px; left: 12px; }
.box-corner-tl::before { top: 0; left: 0; width: 24px; height: 1px; }
.box-corner-tl::after { top: 0; left: 0; width: 1px; height: 24px; }
.box-corner-tr { top: 12px; right: 12px; }
.box-corner-tr::before { top: 0; right: 0; width: 24px; height: 1px; }
.box-corner-tr::after { top: 0; right: 0; width: 1px; height: 24px; }
.box-corner-bl { bottom: 12px; left: 12px; }
.box-corner-bl::before { bottom: 0; left: 0; width: 24px; height: 1px; }
.box-corner-bl::after { bottom: 0; left: 0; width: 1px; height: 24px; }
.box-corner-br { bottom: 12px; right: 12px; }
.box-corner-br::before { bottom: 0; right: 0; width: 24px; height: 1px; }
.box-corner-br::after { bottom: 0; right: 0; width: 1px; height: 24px; }

/* ── Form Elements (use shared .input-group, .input-field, .btn from shared_base.css) ── */
.play-box .input-group {
    margin-bottom: 18px;
}

.form-buttons {
    display: flex;
    gap: 10px;
    margin-top: 24px;
}

.form-buttons .btn {
    flex: 1;
    padding: 12px 14px;
    letter-spacing: 2px;
    font-size: 0.85rem;
}

.form-buttons-3 {
    flex-wrap: wrap;
}

.form-buttons-3 .btn:first-child {
    flex: 1 1 100%;
}

.form-section {
    margin-bottom: 18px;
}

.form-section-label {
    display: block;
    font-family: var(--font-h);
    font-size: 0.7rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 8px;
}

.play-box .alert {
    margin-bottom: 16px;
}

/* ── Option Buttons (faction/class) ── */
.option-row {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.option-btn {
    flex: 1;
    min-width: 80px;
    padding: 12px 10px;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: var(--bg-input);
    color: var(--text-dim);
    font-family: var(--font);
    font-size: 0.85rem;
    text-align: center;
    transition: all 0.25s;
    cursor: pointer;
}

.option-btn:hover {
    border-color: var(--border-h);
    color: var(--text);
}

.option-btn.selected {
    border-color: var(--accent);
    background: rgba(108,92,231,0.08);
    color: var(--accent);
    box-shadow: 0 0 12px var(--accent-glow);
}

/* ── Character List ── */
#character-list {
    max-height: 300px;
    overflow-y: auto;
    margin-bottom: 8px;
    padding: 18px;
}

.char-card {
    padding: 14px 18px;
    border: 1px solid var(--border);
    border-radius: 8px;
    margin-bottom: 0;
    flex: 1;
    cursor: pointer;
    transition: all 0.25s;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--bg-input);
    position: relative;
    overflow: hidden;
    isolation: isolate;
}

.char-card:hover {
    border-color: var(--border-h);
    background: rgba(108,92,231,0.04);
}

.char-card.selected {
    border-color: var(--accent);
    background: rgba(108,92,231,0.08);
    box-shadow: 0 0 16px var(--accent-glow) inset;
}

.char-card .char-name {
    font-family: var(--font-h);
    font-size: 1rem;
    font-weight: 600;
    color: var(--accent);
    letter-spacing: 1px;
}

.char-card .char-info {
    font-family: var(--font);
    font-size: 0.75rem;
    color: var(--text-dim);
    margin-top: 2px;
}

.char-card .char-level {
    font-family: var(--font-h);
    font-size: 0.8rem;
    color: var(--text-dim);
    letter-spacing: 1px;
}

.no-chars {
    text-align: center;
    color: var(--text-dim);
    padding: 36px;
    font-family: var(--font-h);
    font-size: 0.85rem;
    letter-spacing: 1px;
    font-style: italic;
}

/* ── Character Select Layout (2-column: list + 3D preview) ── */
.play-box-charselect {
    max-width: 820px;
}

.charselect-layout {
    display: flex;
    gap: 24px;
    margin-bottom: 0;
    min-height: 0;
    height: 280px;
    align-items: stretch;
}

.play-box-charselect .form-buttons {
    margin-top: 44px;
    row-gap: 20px;
}

.charselect-layout__list {
    flex: 1 1 50%;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.charselect-layout__list #character-list {
    flex: 1 1 0;
    overflow-y: auto;
    padding: 0;
    margin-bottom: 0;
    max-height: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.charselect-layout__preview {
    flex: 1 1 50%;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.15);
    overflow: hidden;
}
.charselect-layout__preview--loading::after {
    content: 'Loading preview...';
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-h);
    font-size: 0.9rem;
    letter-spacing: 1.2px;
    color: rgba(255, 255, 255, 0.88);
    background: linear-gradient(180deg, rgba(10, 8, 18, 0.18), rgba(10, 8, 18, 0.36));
    z-index: 2;
}
.charselect-layout__preview--loading #charselect-preview-canvas,
.charselect-layout__preview--loading .charselect-preview-label {
    opacity: 0;
}

#charselect-preview-canvas {
    width: 100%;
    height: 100%;
    min-height: 260px;
    display: block;
    border-radius: 12px;
    outline: none;
    touch-action: none;
    transition: opacity 0.18s ease;
}

.charselect-preview-label {
    position: absolute;
    bottom: 14px;
    left: 50%;
    transform: translateX(-50%);
    font-family: var(--font-h);
    font-size: 1.15rem;
    color: #fff;
    letter-spacing: 1.5px;
    text-shadow: 0 2px 8px rgba(0,0,0,0.8), 0 0 4px rgba(0,0,0,0.5);
    white-space: nowrap;
    pointer-events: none;
    transition: opacity 0.18s ease;
}

@media (max-width: 720px) {
    .play-box-charselect { max-width: 95vw; }
    .charselect-layout {
        flex-direction: column;
        gap: 16px;
        min-height: auto;
    }
    .charselect-layout__preview {
        min-height: 220px;
    }
}

@media (max-width: 480px) {
    .play-box-charselect { max-width: 100vw; }
    .charselect-layout__preview {
        min-height: 180px;
    }
}

/* ── Game HUD ── */
#game-hud {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: 10;
    pointer-events: none;
}

#game-hud > * {
    pointer-events: auto;
}

/* Top-left: player info */
#hud-player-info {
    position: absolute;
    top: 16px; left: 16px;
    width: 220px;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(108, 92, 231, 0.3);
    border-radius: 4px;
    padding: 10px 12px;
}

.player-name {
    font-family: var(--font-h);
    font-size: 16px;
    font-weight: 700;
    color: #e74c3c;
    letter-spacing: 1px;
}

.player-level {
    font-size: 13px;
    color: #E8DEFF;
    font-weight: 600;
    margin-bottom: 6px;
}

.bar-container {
    width: 100%;
    height: 16px;
    background: rgba(0, 0, 0, 0.6);
    border-radius: 3px;
    margin-bottom: 3px;
    overflow: hidden;
    position: relative;
}

.bar {
    height: 100%;
    border-radius: 3px;
    transition: width 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bar span {
    font-size: 10px;
    color: #fff;
    text-shadow: 0 0 3px #000;
    position: absolute;
    left: 0;
    right: 0;
    width: 100%;
    text-align: center;
    z-index: 1;
}

.hp-bar { background: linear-gradient(90deg, #c0392b, #e74c3c); width: 100%; }
.mp-bar { background: linear-gradient(90deg, #2471a3, #3498db); width: 100%; background-image: linear-gradient(90deg, #2471a3, #3498db); }

/* Top-center: target frame */
#hud-target-frame {
    position: absolute;
    top: 16px;
    left: 50%;
    transform: translateX(-50%);
    width: 220px;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(108, 92, 231, 0.3);
    border-radius: 4px;
    padding: 8px 12px;
}

.target-name {
    font-size: 16px;
    font-weight: 600;
    color: #E8DEFF;
    text-align: center;
    line-height: 1.2;
    margin-bottom: 4px;
}

/* Bottom-left: chat */
#hud-chat {
    position: absolute;
    bottom: 120px;
    left: 16px;
    width: 350px;
    height: 210px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

#chat-messages {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 8px;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 4px 4px 0 0;
    font-size: 13px;
    color: #fff;
    line-height: 1.5;
    word-wrap: break-word;
    overflow-wrap: break-word;
    scrollbar-width: thin;
    scrollbar-color: #555 transparent;
}

#chat-input {
    width: 100%;
    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.7);
    border: 1px solid rgba(108, 92, 231, 0.3);
    border-top: none;
    border-radius: 0 0 4px 4px;
    color: #E8DEFF;
    font-size: 12px;
    outline: none;
}

#chat-input:focus {
    border-color: #6C5CE7;
}

/* Bottom-right: combat log */
#hud-combat-log {
    position: absolute;
    bottom: 120px;
    right: 16px;
    width: 300px;
    height: 160px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

#combat-log-messages {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 8px;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 4px;
    font-size: 12px;
    color: #fff;
    line-height: 1.5;
    scrollbar-width: thin;
    scrollbar-color: #555 transparent;
}

/* Bottom-center: skill bar */
#hud-skill-bar {
    position: absolute;
    bottom: 52px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 4px;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(108, 92, 231, 0.3);
    border-radius: 6px;
    padding: 6px;
}

.skill-slot {
    width: 48px;
    height: 48px;
    background-color: rgba(20, 15, 35, 0.8);
    border: 1px solid rgba(108, 92, 231, 0.4);
    border-radius: 4px;
    position: relative;
    cursor: pointer;
    transition: border-color 0.2s;
}

.skill-slot:hover {
    border-color: #6C5CE7;
}

.skill-slot .hotkey {
    position: absolute;
    bottom: 2px;
    right: 4px;
    font-size: 10px;
    color: #A29BFE;
}

/* ── Bottom Action Bar ── */
#hud-bottom-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 48px;
    display: flex;
    align-items: center;
    background: rgba(0, 0, 0, 0.6);
    border-top: 1px solid rgba(108, 92, 231, 0.3);
    z-index: 20;
}
.bottom-bar-left, .bottom-bar-right {
    display: flex;
    gap: 3px;
    padding: 0 10px;
}
.bottom-bar-center {
    flex: 1;
    padding: 0 14px;
}
.bar-action-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: rgba(20, 15, 35, 0.8);
    border: 1px solid rgba(108, 92, 231, 0.3);
    border-radius: 4px;
    padding: 2px 10px;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
    min-width: 54px;
    height: 40px;
    overflow: hidden;
}
.bar-action-btn:hover {
    border-color: #6C5CE7;
    background: rgba(60, 45, 100, 0.6);
}
.bar-btn-icon {
    font-family: var(--font-h);
    font-size: 16px;
    font-weight: 700;
    color: #fff;
    line-height: 1;
    flex-shrink: 0;
}
.bar-btn-label {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.85);
    letter-spacing: 0.5px;
    font-family: var(--font-h);
    margin-top: 1px;
    line-height: 1;
    flex-shrink: 0;
    white-space: nowrap;
}
#exp-bar-container {
    width: 100%;
    height: 22px;
    background: rgba(0, 0, 0, 0.6);
    border-radius: 3px;
    overflow: hidden;
    position: relative;
    border: 1px solid rgba(108, 92, 231, 0.3);
}
#exp-bar-fill {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, #00b894, #55efc4);
    border-radius: 3px;
    transition: width 0.3s ease;
}
#exp-bar-text {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 600;
    color: #fff;
    text-shadow: 0 0 4px #000, 0 0 4px #000, 1px 1px 2px #000;
    pointer-events: none;
    z-index: 2;
}

/* ── Character Panel (slides from left) ── */
#character-panel {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding: 0 16px;
    pointer-events: none;
}
#character-panel .char-panel-inner {
    pointer-events: auto;
    transform: translateX(-110%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    width: 340px;
    height: 80vh;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    box-shadow: 0 8px 30px rgba(0,0,0,0.06);
    overflow: hidden;
    position: relative;
}
#character-panel.open .char-panel-inner {
    transform: translateX(0);
}
#character-panel.hidden { display: none; }

/* ── Commands Panel (slides from right, opened with H) ── */
#commands-panel {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 0 16px;
    pointer-events: none;
}
#commands-panel .cmd-panel-inner {
    pointer-events: auto;
    transform: translateX(110%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    width: 280px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    box-shadow: 0 8px 30px rgba(0,0,0,0.06);
    max-height: 70vh;
    overflow: hidden;
    position: relative;
}
#commands-panel.open .cmd-panel-inner {
    transform: translateX(0);
}
#commands-panel.hidden { display: none; }
#dance-panel {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 0 16px;
    pointer-events: none;
}
#dance-panel .cmd-panel-inner {
    pointer-events: auto;
    transform: translateX(110%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    width: 280px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    box-shadow: 0 8px 30px rgba(0,0,0,0.06);
    max-height: 50vh;
    overflow: hidden;
    position: relative;
}
#dance-panel.open .cmd-panel-inner {
    transform: translateX(0);
}
#dance-panel.hidden { display: none; }
.cmd-panel-body {
    flex: 1;
    overflow-y: auto;
    padding: 12px 16px;
}
.cmd-group {
    margin-bottom: 16px;
}
.cmd-group__title {
    font-family: var(--font-h);
    font-size: 12px;
    font-weight: 600;
    color: #A29BFE;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
    padding-bottom: 4px;
    border-bottom: 1px solid rgba(108, 92, 231, 0.2);
}
.cmd-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 10px 12px;
    background: rgba(108, 92, 231, 0.06);
    border: 1px solid rgba(108, 92, 231, 0.2);
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
    margin-bottom: 6px;
    text-align: left;
}
.cmd-btn:hover {
    background: rgba(108, 92, 231, 0.14);
    border-color: rgba(108, 92, 231, 0.5);
}
.cmd-btn__icon {
    flex-shrink: 0;
}
.cmd-btn__label {
    font-family: var(--font-h);
    font-size: 14px;
    font-weight: 600;
    color: #2D3436;
}
.cmd-btn__desc {
    display: block;
    font-family: var(--font);
    font-size: 11px;
    color: #636E72;
    margin-left: auto;
}

/* ── GM Moderation Card ── */
.gm-mod-card {
    background: var(--bg-card2);
    border: 1px solid rgba(255, 107, 107, 0.25);
    border-radius: 8px;
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.gm-mod-card__row {
    display: flex;
    align-items: center;
    gap: 8px;
}
.gm-mod-card__label {
    font-family: var(--font-h);
    font-size: 11px;
    font-weight: 600;
    color: var(--primary);
    min-width: 66px;
    flex-shrink: 0;
}
.gm-mod-card__input,
.gm-mod-card__select {
    flex: 1;
    padding: 6px 8px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: 4px;
    font-family: var(--font);
    font-size: 12px;
    color: var(--text);
    min-width: 0;
}
.gm-mod-card__input:focus,
.gm-mod-card__select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px var(--accent-glow);
}
.gm-mod-card__btn {
    padding: 7px 0;
    background: #d63031;
    border: none;
    border-radius: 4px;
    color: #fff;
    font-family: var(--font-h);
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s;
}
.gm-mod-card__btn:hover {
    background: #c0392b;
}

/* ── Player Right-Click Context Menu ── */
.player-ctx-menu {
    position: fixed;
    z-index: 2000;
    min-width: 180px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
    padding: 4px 0;
    pointer-events: auto;
}
.player-ctx-menu.hidden { display: none; }
.player-ctx-menu__header {
    padding: 8px 12px 6px;
    font-family: var(--font-h);
    font-size: 13px;
    font-weight: 700;
    color: var(--primary);
    border-bottom: 1px solid var(--border);
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.player-ctx-menu__item {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 7px 12px;
    background: none;
    border: none;
    font-family: var(--font);
    font-size: 12px;
    color: var(--text);
    cursor: pointer;
    transition: background 0.15s;
    text-align: left;
}
.player-ctx-menu__item:hover { background: var(--bg2); }
.player-ctx-menu__item--mod { color: #e17055; }
.player-ctx-menu__item--gm { color: #d63031; }
.player-ctx-menu__icon { flex-shrink: 0; }

/* ── Party Panel ── */
.party-panel {
    position: fixed;
    top: 200px;
    right: 16px;
    z-index: 500;
    background: rgba(20, 18, 40, 0.94);
    border: 1px solid rgba(108, 92, 231, 0.35);
    border-radius: 8px;
    min-width: 210px;
    max-width: 240px;
    pointer-events: auto;
    box-shadow: 0 4px 16px rgba(0,0,0,0.5);
}
.party-panel.hidden { display: none; }
.party-panel__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 7px 12px;
    border-bottom: 1px solid rgba(108, 92, 231, 0.25);
    cursor: grab;
    user-select: none;
}
.party-panel__header:active { cursor: grabbing; }
.party-panel__title {
    font-family: var(--font-h, 'Cinzel', serif);
    font-size: 0.82rem;
    color: #a29bfe;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}
.party-panel__leave {
    background: none;
    border: none;
    color: #e17055;
    font-size: 0.85rem;
    cursor: pointer;
    padding: 0 2px;
    line-height: 1;
}
.party-panel__leave:hover { color: #d63031; }
.party-panel__list { padding: 4px 0; }
.party-member {
    display: flex;
    flex-direction: column;
    padding: 5px 10px;
    gap: 3px;
    position: relative;
    border-bottom: 1px solid rgba(255,255,255,0.04);
    transition: background 0.15s;
}
.party-member:last-child { border-bottom: none; }
.party-member--self { background: rgba(108, 92, 231, 0.1); }
.party-member[draggable="true"] { cursor: grab; }
.party-member--dragging { opacity: 0.4; }
.party-member--drag-above { border-top: 2px solid #6c5ce7; }
.party-member--drag-below { border-bottom: 2px solid #6c5ce7; }
.party-member__row {
    display: flex;
    align-items: center;
    gap: 5px;
    min-width: 0;
}
.party-member__num {
    font-family: var(--font-h, 'Cinzel', serif);
    font-size: 0.82rem;
    font-weight: 800;
    flex-shrink: 0;
    width: 16px;
    text-align: center;
    text-shadow: 0 0 6px currentColor;
}
.party-member__crown {
    font-size: 0.72rem;
    flex-shrink: 0;
    line-height: 1;
}
.party-member__name {
    font-family: var(--font-h, 'Cinzel', serif);
    font-size: 0.82rem;
    color: #f0f0f0;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
    min-width: 0;
}
.party-member__level {
    font-size: 0.68rem;
    color: #a0a0a0;
    flex-shrink: 0;
    font-weight: 600;
}
.party-member__class {
    font-size: 0.62rem;
    color: #7c7c8a;
    flex-shrink: 0;
    text-transform: capitalize;
}
.party-member__bars {
    display: flex;
    flex-direction: column;
    gap: 2px;
    width: 100%;
}
.party-member__hp-bar {
    width: 100%;
    height: 5px;
    background: rgba(255,255,255,0.08);
    border-radius: 3px;
    overflow: hidden;
}
.party-member__hp-fill {
    height: 100%;
    background: linear-gradient(90deg, #27ae60, #2ecc71);
    border-radius: 3px;
    transition: width 0.3s;
}
.party-member__mp-bar {
    width: 100%;
    height: 4px;
    background: rgba(255,255,255,0.06);
    border-radius: 2px;
    overflow: hidden;
}
.party-member__mp-fill {
    height: 100%;
    background: linear-gradient(90deg, #2980b9, #3498db);
    border-radius: 2px;
    transition: width 0.3s;
}
.party-member__kick {
    position: absolute;
    right: 6px;
    top: 5px;
    background: none;
    border: none;
    color: #e17055;
    font-size: 0.65rem;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    opacity: 0;
    transition: opacity 0.15s;
}
.party-member:hover .party-member__kick { opacity: 1; }
.party-member__kick:hover { color: #d63031; }

/* ── Party Member Context Menu ── */
.party-member-ctx {
    position: fixed;
    z-index: 2600;
    background: rgba(20, 18, 40, 0.96);
    border: 1px solid rgba(108, 92, 231, 0.4);
    border-radius: 6px;
    padding: 4px 0;
    min-width: 150px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.6);
}
.party-member-ctx__item {
    display: block;
    width: 100%;
    padding: 7px 14px;
    border: none;
    background: none;
    color: var(--text, #e0e0e0);
    font-family: var(--font-h, 'Cinzel', serif);
    font-size: 0.78rem;
    text-align: left;
    cursor: pointer;
}
.party-member-ctx__item:hover { background: rgba(108, 92, 231, 0.15); }
.party-member-ctx__item--danger { color: #e17055; }
.party-member-ctx__item--danger:hover { background: rgba(225, 112, 85, 0.15); }

/* ── Bottom Floating Request / Loot Panels ── */
.party-invite-modal,
.trade-request-modal,
#loot-chest-panel,
.merchant-panel {
    position: fixed;
    left: 50%;
    bottom: 152px;
    transform: translateX(-50%);
    width: auto;
    display: block;
    pointer-events: none;
}
.party-invite-modal,
.trade-request-modal {
    z-index: 1120;
}
.merchant-panel {
    z-index: 1110;
}
#loot-chest-panel {
    z-index: 1100;
}
.party-invite-modal.hidden,
.trade-request-modal.hidden,
#loot-chest-panel.hidden,
.merchant-panel.hidden {
    display: none;
}
.party-invite-modal__card,
.trade-request-modal__card,
.loot-chest__inner,
.merchant-panel__inner {
    pointer-events: auto;
    position: relative;
    width: min(90vw, 208px);
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 13px;
    box-shadow: 0 12px 30px rgba(12, 8, 28, 0.18);
    overflow: hidden;
}
.party-invite-modal__header,
.trade-request-modal__header {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 11px 12px 8px;
    border-bottom: 1px solid var(--border);
    cursor: move;
    user-select: none;
    touch-action: none;
}
.party-invite-modal__header::before,
.trade-request-modal__header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 56%;
    height: 3px;
    background: linear-gradient(90deg, transparent, #B86FD6, transparent);
    opacity: 0.7;
    border-radius: 2px;
}
.party-invite-modal__header h2,
.trade-request-modal__header h2 {
    margin: 0;
    font-family: var(--font-h);
    font-size: 14px;
    font-weight: 700;
    color: #6C5CE7;
}
.party-invite-modal__body,
.trade-request-modal__body {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 10px 12px 12px;
}
.party-invite-modal__text,
.trade-request-modal__text {
    margin: 0;
    color: #2d2347;
    font-family: var(--font);
    font-size: 11px;
    font-weight: 700;
    line-height: 1.35;
    text-align: center;
    text-shadow: 0 1px 0 rgba(255,255,255,0.3);
}
.party-invite-modal__text span,
.trade-request-modal__text span {
    color: #6c5ce7;
    font-weight: 800;
}
.party-invite-modal__actions,
.trade-request-modal__buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
}
.party-invite-modal__btn,
.trade-request-modal__btn {
    min-width: 78px;
    padding: 8px 10px;
    border: none;
    border-radius: 8px;
    color: #fff;
    font-family: var(--font);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.02em;
    cursor: pointer;
    box-shadow: 0 6px 12px rgba(0,0,0,0.14);
    transition: transform 0.15s ease, filter 0.2s ease;
}
.party-invite-modal__btn:hover,
.trade-request-modal__btn:hover {
    transform: translateY(-1px);
    filter: brightness(1.05);
}
.party-invite-modal__btn--accept,
.trade-request-modal__btn--accept {
    background: linear-gradient(180deg, #31bf75, #23955b);
}
.party-invite-modal__btn--decline,
.trade-request-modal__btn--decline {
    background: linear-gradient(180deg, #df5d59, #b93b38);
}

/* ── Merchant Panel ── */
.merchant-panel__inner {
    display: flex;
    flex-direction: column;
    width: min(92vw, 360px);
}

.merchant-panel__header {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 11px 12px 8px;
    border-bottom: 1px solid var(--border);
    cursor: move;
    user-select: none;
    touch-action: none;
}

.merchant-panel__header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 56%;
    height: 3px;
    border-radius: 2px;
    background: linear-gradient(90deg, transparent, #f0b44d, transparent);
    opacity: 0.8;
}

.merchant-panel__header h2 {
    margin: 0;
    font-family: var(--font-h);
    font-size: 14px;
    font-weight: 700;
    color: #b77624;
}

.merchant-panel__body {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 10px 12px 12px;
}

.merchant-panel__status {
    margin: 0;
    color: #3a2b59;
    font-family: var(--font);
    font-size: 11px;
    font-weight: 700;
    line-height: 1.35;
    text-align: center;
    text-shadow: 0 1px 0 rgba(255,255,255,0.26);
}

.merchant-panel__empty {
    padding: 14px 12px;
    border: 1px dashed rgba(184, 118, 36, 0.35);
    border-radius: 10px;
    background: rgba(255, 248, 229, 0.62);
    color: #6a4a1f;
    font-family: var(--font);
    font-size: 11px;
    font-weight: 700;
    line-height: 1.4;
    text-align: center;
}

.merchant-panel__list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 300px;
    overflow-y: auto;
    padding-right: 3px;
}

.merchant-panel__card {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) auto;
    gap: 8px;
    align-items: start;
    padding: 8px;
    border: 1px solid rgba(184, 118, 36, 0.22);
    border-radius: 10px;
    background:
        linear-gradient(180deg, rgba(255, 252, 243, 0.94), rgba(247, 239, 220, 0.98));
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.26);
    cursor: pointer;
    transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.merchant-panel__card:hover {
    transform: translateY(-1px);
    border-color: rgba(184, 118, 36, 0.42);
}

.merchant-panel__card:focus-visible {
    outline: none;
    border-color: rgba(184, 118, 36, 0.56);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.26),
        0 0 0 2px rgba(240, 180, 77, 0.18);
}

.merchant-panel__card--selected {
    border-color: rgba(184, 118, 36, 0.56);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.26),
        0 0 0 1px rgba(240, 180, 77, 0.18);
}

.merchant-panel__icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background:
        linear-gradient(180deg, rgba(255,255,255,0.85), rgba(236, 225, 194, 0.96));
    border: 1px solid rgba(184, 118, 36, 0.22);
    background-position: center;
    background-repeat: no-repeat;
    background-size: contain;
    flex: 0 0 auto;
}

.merchant-panel__meta {
    display: flex;
    flex-direction: column;
    gap: 5px;
    min-width: 0;
}

.merchant-panel__name {
    font-family: var(--font);
    font-size: 11px;
    font-weight: 800;
    color: #2d2347;
    line-height: 1.25;
    word-break: break-word;
}

.merchant-panel__name--common { color: #5e4e85; }
.merchant-panel__name--uncommon { color: #1b8f6d; }
.merchant-panel__name--rare { color: #4b55d6; }
.merchant-panel__name--epic { color: #8c3fd9; }
.merchant-panel__name--legendary { color: #c87a0f; }

.merchant-panel__stock {
    font-family: var(--font);
    font-size: 10px;
    font-weight: 700;
    color: #6a5b84;
}

.merchant-panel__fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px;
}

.merchant-panel__field {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}

.merchant-panel__field label {
    font-family: var(--font);
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.02em;
    color: #7a6334;
    text-transform: uppercase;
}

.merchant-panel__field input {
    width: 100%;
    min-width: 0;
    padding: 6px 7px;
    border: 1px solid rgba(184, 118, 36, 0.25);
    border-radius: 8px;
    background: rgba(255,255,255,0.92);
    color: #2d2347;
    font-family: var(--font);
    font-size: 11px;
    font-weight: 700;
}

.merchant-panel__field input:focus {
    outline: none;
    border-color: rgba(184, 118, 36, 0.65);
    box-shadow: 0 0 0 2px rgba(240, 180, 77, 0.16);
}

.merchant-panel__side {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
}

.merchant-panel__price {
    min-width: 74px;
    padding: 5px 8px;
    border-radius: 999px;
    background: rgba(86, 57, 9, 0.88);
    border: 1px solid rgba(246, 191, 74, 0.38);
    color: #fff1b3;
    font-family: var(--font);
    font-size: 10px;
    font-weight: 800;
    text-align: center;
    white-space: nowrap;
}

.merchant-panel__card-btn,
.merchant-panel__btn {
    padding: 8px 10px;
    border: none;
    border-radius: 8px;
    color: #fff;
    font-family: var(--font);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.02em;
    cursor: pointer;
    box-shadow: 0 6px 12px rgba(0,0,0,0.14);
    transition: transform 0.15s ease, filter 0.2s ease;
}

.merchant-panel__card-btn:hover,
.merchant-panel__btn:hover {
    transform: translateY(-1px);
    filter: brightness(1.05);
}

.merchant-panel__btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    filter: grayscale(0.2);
    box-shadow: none;
    pointer-events: none;
}

.merchant-panel__card-btn--buy,
.merchant-panel__btn--accept {
    background: linear-gradient(180deg, #31bf75, #23955b);
}

.merchant-panel__card-btn--toggle {
    background: linear-gradient(180deg, #c89238, #a56a1f);
}

.merchant-panel__card-btn--remove,
.merchant-panel__btn--decline {
    background: linear-gradient(180deg, #df5d59, #b93b38);
}

.merchant-panel__actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    padding: 0 12px 12px;
}

/* ── Moderation Reason Modal ── */
.mod-reason-modal {
    position: fixed;
    inset: 0;
    z-index: 2500;
    display: flex;
    align-items: center;
    justify-content: center;
}
.mod-reason-modal.hidden { display: none; }
.mod-reason-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.45);
}
.mod-reason-modal__card {
    position: relative;
    width: 340px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.12);
}
.mod-reason-modal__title {
    font-family: var(--font-h);
    font-size: 16px;
    font-weight: 700;
    color: var(--primary);
    margin: 0 0 4px;
}
.mod-reason-modal__target {
    font-family: var(--font);
    font-size: 13px;
    color: var(--text-dim);
    margin: 0 0 12px;
}
.mod-reason-modal__row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
}
.mod-reason-modal__actions {
    display: flex;
    gap: 8px;
    margin-top: 14px;
}
.mod-reason-modal__btn {
    flex: 1;
    padding: 8px 0;
    border: none;
    border-radius: 6px;
    font-family: var(--font-h);
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s;
}
.mod-reason-modal__btn--cancel {
    background: var(--bg2);
    color: var(--text);
}
.mod-reason-modal__btn--cancel:hover { background: var(--border); }
.mod-reason-modal__btn--confirm {
    background: #d63031;
    color: #fff;
}
.mod-reason-modal__btn--confirm:hover { background: #c0392b; }

/* ── Private Message Panel (slides from left) ── */
#pm-panel {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding: 0 16px;
    pointer-events: none;
}
#pm-panel .pm-panel-inner {
    pointer-events: auto;
    transform: translateX(-110%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    width: 340px;
    height: 70vh;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    box-shadow: 0 8px 30px rgba(0,0,0,0.06);
    overflow: hidden;
    position: relative;
}
#pm-panel.open .pm-panel-inner { transform: translateX(0); }
#pm-panel.hidden { display: none; }
/* PM unread badge replaces icon in bottom bar button */
.pm-unread-badge {
    background: #e74c3c;
    color: #fff;
    border-radius: 9px;
    min-width: 18px;
    padding: 0 5px;
    font-family: var(--font);
    font-size: 10px;
    font-weight: 700;
    line-height: 18px;
    text-align: center;
}
.pm-unread-badge.hidden { display: none; }
@keyframes pm-badge-pulse {
    0% { transform: scale(1); }
    30% { transform: scale(1.35); }
    60% { transform: scale(0.95); }
    100% { transform: scale(1); }
}
.pm-unread-badge--pulse { animation: pm-badge-pulse 0.4s ease-out; }
.pm-back-btn {
    background: none;
    border: none;
    color: var(--text);
    font-size: 18px;
    cursor: pointer;
    padding: 0 8px 0 0;
    line-height: 1;
    transition: color 0.2s;
}
.pm-back-btn:hover { color: var(--primary); }
.pm-back-btn.hidden { display: none; }
.pm-panel-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
/* PM muted notice */
.pm-muted-notice {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 20px 16px;
    text-align: center;
    flex-shrink: 0;
}
.pm-muted-notice.hidden { display: none; }
.pm-muted-notice__icon {
    font-size: 32px;
    opacity: 0.6;
}
.pm-muted-notice__text {
    margin: 0;
    color: #e74c3c;
    font-family: var(--font-h);
    font-size: 13px;
    font-weight: 700;
}
.pm-muted-notice__detail {
    margin: 0;
    color: var(--text-dim);
    font-family: var(--font);
    font-size: 11px;
    line-height: 1.4;
}
/* PM panel footer with new conversation button and search dropdown */
.pm-panel-footer {
    flex-shrink: 0;
    padding: 8px 10px;
    border-top: 1px solid var(--border);
    position: relative;
}
.pm-panel-footer.hidden { display: none; }
.pm-new-convo-btn {
    width: 100%;
    padding: 8px 12px;
    background: var(--primary);
    border: none;
    border-radius: 6px;
    color: #fff;
    font-family: var(--font-h);
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s;
}
.pm-new-convo-btn:hover:not(:disabled) { background: #5b4bd5; }
.pm-new-convo-btn:disabled,
.pm-send-btn:disabled,
.pm-search-go-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}
.pm-input:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}
.pm-search-dropdown {
    position: absolute;
    left: 10px;
    right: 10px;
    bottom: 100%;
    margin-bottom: 6px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 8px;
    box-shadow: 0 -4px 12px rgba(0,0,0,0.4);
}
.pm-search-dropdown.hidden { display: none; }
.pm-search-dropdown__row {
    display: flex;
    gap: 6px;
    align-items: center;
}
.pm-search-input {
    flex: 1;
    padding: 6px 8px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: 4px;
    font-family: var(--font);
    font-size: 12px;
    color: var(--text);
    min-width: 0;
}
.pm-search-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px var(--accent-glow);
}
.pm-search-go-btn {
    padding: 6px 12px;
    background: var(--primary);
    border: none;
    border-radius: 4px;
    color: #fff;
    font-family: var(--font-h);
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s;
}
.pm-search-go-btn:hover { background: #5b4bd5; }
.pm-search-close-btn {
    padding: 4px 8px;
    background: none;
    border: 1px solid var(--border);
    border-radius: 4px;
    color: var(--text);
    font-size: 14px;
    cursor: pointer;
    transition: color 0.2s, border-color 0.2s;
}
.pm-search-close-btn:hover {
    color: #e74c3c;
    border-color: #e74c3c;
}
.pm-user-list {
    flex: 1;
    overflow-y: auto;
    padding: 8px 0;
    display: flex;
    flex-direction: column;
}
.pm-user-list.hidden { display: none; }
.pm-user-list__empty {
    text-align: center;
    padding: 32px 12px;
    color: var(--text-muted);
    font-family: var(--font);
    font-size: 13px;
}
.pm-user-list__item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    background: none;
    border: none;
    border-bottom: 1px solid var(--border);
    color: var(--text);
    font-family: var(--font);
    font-size: 13px;
    cursor: pointer;
    text-align: left;
    transition: background 0.15s;
    width: 100%;
}
.pm-user-list__item:hover { background: rgba(108, 92, 231, 0.08); }
.pm-user-list__name {
    flex: 1;
    font-weight: 600;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.pm-user-list__level {
    font-size: 11px;
    color: var(--text-muted);
    font-weight: 400;
    flex-shrink: 0;
}
.pm-user-list__dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--primary);
    flex-shrink: 0;
}
.pm-user-list__status {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}
.pm-user-list__status--online {
    background: #00b894;
}
.pm-user-list__status--offline {
    background: #636e72;
}
.pm-chat-view {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.pm-chat-view.hidden { display: none; }
.pm-messages {
    flex: 1;
    overflow-y: auto;
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-family: var(--font);
    font-size: 12px;
    color: var(--text);
}
.pm-msg { line-height: 1.4; }
.pm-msg--self .pm-msg__sender { color: var(--primary); }
.pm-msg--other .pm-msg__sender { color: #e17055; }
.pm-msg__sender { font-weight: 600; }
.pm-input-row {
    display: flex;
    gap: 6px;
    padding: 8px 10px;
    border-top: 1px solid var(--border);
    position: relative;
    z-index: 2;
}
.pm-input {
    flex: 1;
    padding: 6px 8px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: 4px;
    font-family: var(--font);
    font-size: 12px;
    color: var(--text);
    min-width: 0;
}
.pm-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px var(--accent-glow);
}
.pm-send-btn {
    padding: 6px 12px;
    background: var(--primary);
    border: none;
    border-radius: 4px;
    color: #fff;
    font-family: var(--font-h);
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s;
}
.pm-send-btn:hover { background: #5b4bd5; }

/* ── PM Gift Attachment ── */
.pm-gift-btn {
    flex-shrink: 0;
    width: 30px;
    height: 30px;
    padding: 0;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: 4px;
    color: var(--text);
    font-size: 14px;
    line-height: 1;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}
.pm-gift-btn:hover { border-color: var(--primary); background: var(--bg-card); }
.pm-gift-btn--active { border-color: var(--primary); background: var(--primary); color: #fff; }

.pm-gift-attach {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    background: rgba(108, 92, 231, 0.15);
    border-top: 1px solid var(--border);
    font-size: 11px;
    color: var(--text);
}
.pm-gift-attach.hidden {
    display: flex !important;
    padding: 0;
    border-top: none;
    height: 0;
    overflow: hidden;
}
.pm-gift-attach__items {
    flex: 1;
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    min-width: 0;
    overflow: hidden;
}
.pm-gift-chip {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 2px 6px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: 3px;
    font-size: 10px;
    white-space: nowrap;
    max-width: 140px;
    overflow: hidden;
    text-overflow: ellipsis;
}
.pm-gift-chip--gold { color: #b8860b; }
[data-theme="dark"] .pm-gift-chip--gold { color: #FFEAA7; }
.pm-gift-chip__icon {
    display: inline-block;
    width: 14px;
    height: 14px;
    image-rendering: pixelated;
    flex-shrink: 0;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}
.pm-gift-chip__remove {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 10px;
    cursor: pointer;
    padding: 0 0 0 3px;
    line-height: 1;
}
.pm-gift-chip__remove:hover { color: #e74c3c; }
.pm-gift-attach__remove {
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    padding: 0;
    background: none;
    border: 1px solid var(--border);
    border-radius: 3px;
    color: var(--text-muted);
    font-size: 10px;
    cursor: pointer;
    line-height: 1;
}
.pm-gift-attach__remove:hover { color: #e74c3c; border-color: #e74c3c; }

.pm-gift-picker {
    border-top: 1px solid var(--border);
    background: var(--bg-card);
    max-height: 200px;
    display: flex;
    flex-direction: column;
}
.pm-gift-picker__body {
    overflow-y: auto;
    flex: 1;
    padding: 6px;
}
.pm-gift-items {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(36px, 1fr));
    gap: 4px;
}
.pm-gift-item {
    width: 36px;
    height: 36px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: 4px;
    cursor: pointer;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color 0.15s;
}
.pm-gift-item:hover { border-color: var(--primary); }
.pm-gift-item--selected { border-color: var(--primary); background: rgba(108, 92, 231, 0.25); box-shadow: 0 0 0 1px var(--primary); }
.pm-gift-item img {
    width: 28px;
    height: 28px;
    image-rendering: pixelated;
    pointer-events: none;
}
.pm-gift-item__qty {
    position: absolute;
    bottom: 1px;
    right: 2px;
    font-size: 9px;
    color: #fff;
    text-shadow: 0 0 2px #000, 0 0 2px #000;
    pointer-events: none;
}
.pm-gift-gold-form {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px;
    border-top: 1px solid var(--border);
}
.pm-gift-gold-form__label {
    font-size: 12px;
    color: var(--text-muted);
    white-space: nowrap;
}
.pm-gift-gold-input {
    flex: 1;
    padding: 5px 6px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: 4px;
    font-family: var(--font);
    font-size: 12px;
    color: var(--text);
    min-width: 0;
}
.pm-gift-gold-input:focus { outline: none; border-color: var(--primary); }
.pm-gift-gold-confirm {
    padding: 5px 10px;
    background: var(--primary);
    border: none;
    border-radius: 4px;
    color: #fff;
    font-family: var(--font-h);
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
}
.pm-gift-gold-confirm:hover { background: #5b4bd5; }
/* Gift message in PM chat */
.pm-msg--gift {
    background: rgba(108, 92, 231, 0.1);
    border: 1px solid rgba(108, 92, 231, 0.3);
    border-radius: 6px;
    padding: 6px 8px;
    margin-bottom: 4px;
}
.pm-gift-msg__header {
    font-size: 11px;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 4px;
}
.pm-gift-msg__items {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-bottom: 4px;
}
.pm-gift-msg__item {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 2px 6px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: 3px;
    font-size: 10px;
    color: var(--text);
}
.pm-gift-msg__item-icon {
    width: 16px;
    height: 16px;
    image-rendering: pixelated;
    flex-shrink: 0;
}
.pm-gift-msg__gold {
    font-size: 11px;
    color: #b8860b;
    font-weight: 700;
}
[data-theme="dark"] .pm-gift-msg__gold { color: #FFEAA7; }

.pm-gift-msg__actions {
    display: flex;
    gap: 6px;
    margin-top: 6px;
    align-items: center;
}
.pm-gift-msg__accept {
    padding: 4px 14px;
    font-size: 11px;
    font-weight: 700;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    background: #27ae60;
    color: #fff;
    transition: background 0.15s;
}
.pm-gift-msg__accept:hover { background: #2ecc71; }
.pm-gift-msg__accept:disabled { opacity: 0.6; cursor: default; }
.pm-gift-msg__status {
    font-size: 11px;
    font-weight: 600;
}
.pm-gift-msg__status--pending { color: #e67e22; }
.pm-gift-msg__status--accepted { color: #27ae60; }
[data-theme="dark"] .pm-gift-msg__status--pending { color: #f39c12; }
[data-theme="dark"] .pm-gift-msg__status--accepted { color: #2ecc71; }

/* Gift send confirmation dialog */
.pm-gift-confirm {
    position: absolute;
    inset: 0;
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(2px);
}
.pm-gift-confirm.hidden { display: none; }
.pm-gift-confirm__box {
    background: var(--bg-card);
    border: 2px solid rgba(108, 92, 231, 0.3);
    border-radius: 10px;
    padding: 16px 18px;
    min-width: 220px;
    max-width: 280px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}
.pm-gift-confirm__title {
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--text);
    text-align: center;
}
.pm-gift-confirm__body {
    font-size: 12px;
    color: var(--text);
    margin-bottom: 14px;
    line-height: 1.5;
    background: var(--bg-card2);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 8px 10px;
}
.pm-gift-confirm__item {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 3px 0;
    font-size: 11px;
}
.pm-gift-confirm__item img {
    width: 16px;
    height: 16px;
    image-rendering: pixelated;
    flex-shrink: 0;
}
.pm-gift-confirm__actions {
    display: flex;
    gap: 8px;
    justify-content: center;
}
.pm-gift-confirm__btn {
    padding: 7px 20px;
    font-size: 12px;
    font-weight: 700;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.15s, transform 0.1s;
}
.pm-gift-confirm__btn:active { transform: scale(0.96); }
.pm-gift-confirm__btn--cancel {
    background: var(--bg-card2);
    color: var(--text);
    border: 1px solid var(--border);
}
.pm-gift-confirm__btn--cancel:hover { background: var(--bg2); }
.pm-gift-confirm__btn--send {
    background: #6C5CE7;
    color: #fff;
}
.pm-gift-confirm__btn--send:hover { background: #5a4bd1; }

/* ── Settings Panel (slides from right) ── */
#settings-panel {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 0 16px;
    pointer-events: none;
}
#settings-panel .settings-panel-inner {
    pointer-events: auto;
    transform: translateX(110%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    width: 320px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    box-shadow: 0 8px 30px rgba(0,0,0,0.06);
    max-height: 70vh;
    overflow: hidden;
    position: relative;
}
#settings-panel.open .settings-panel-inner {
    transform: translateX(0);
}
#settings-panel.hidden { display: none; }
.settings-panel-body {
    flex: 1;
    overflow-y: auto;
    padding: 16px 20px 20px;
}
.settings-group {
    margin-bottom: 18px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--border);
}
.settings-group:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}
.settings-save-row {
    padding: 12px 20px 16px;
    text-align: center;
}
.settings-save-btn {
    font-family: var(--font-h);
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    background: var(--primary, #6C5CE7);
    border: none;
    border-radius: 8px;
    padding: 8px 32px;
    cursor: pointer;
    letter-spacing: 0.5px;
    transition: background 0.2s, box-shadow 0.2s;
}
.settings-save-btn:hover {
    background: #5A4BD6;
    box-shadow: 0 2px 8px rgba(108,92,231,0.3);
}
.settings-save-btn:active {
    background: #4A3BC6;
}
.settings-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}
.settings-row:last-child {
    margin-bottom: 0;
}
.settings-label {
    font-family: var(--font-h);
    font-size: 13px;
    font-weight: 600;
    color: #2D3436;
    flex-shrink: 0;
    min-width: 0;
}
/* Toggle switch */
.settings-toggle {
    position: relative;
    width: 42px;
    height: 22px;
    flex-shrink: 0;
}
.settings-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}
.settings-toggle-slider {
    position: absolute;
    inset: 0;
    background: rgba(231, 76, 60, 0.15);
    border: 1px solid rgba(231, 76, 60, 0.4);
    border-radius: 11px;
    cursor: pointer;
    transition: background 0.25s, border-color 0.25s;
}
.settings-toggle-slider::before {
    content: '';
    position: absolute;
    left: 3px;
    top: 3px;
    width: 14px;
    height: 14px;
    background: #e74c3c;
    border-radius: 50%;
    transition: transform 0.25s, background 0.25s;
}
.settings-toggle input:checked + .settings-toggle-slider {
    background: rgba(85, 239, 196, 0.2);
    border-color: rgba(0, 184, 148, 0.5);
}
.settings-toggle input:checked + .settings-toggle-slider::before {
    transform: translateX(20px);
    background: #00b894;
}
/* Volume slider */
.settings-slider {
    flex: 1;
    min-width: 0;
    -webkit-appearance: none;
    appearance: none;
    height: 6px;
    background: rgba(108, 92, 231, 0.12);
    border: 1px solid rgba(108, 92, 231, 0.2);
    border-radius: 3px;
    outline: none;
    cursor: pointer;
}
.settings-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 16px;
    height: 16px;
    background: #E8DEFF;
    border: 2px solid rgba(108, 92, 231, 0.6);
    border-radius: 50%;
    cursor: pointer;
    transition: background 0.15s;
}
.settings-slider::-webkit-slider-thumb:hover {
    background: #6C5CE7;
}
.settings-slider::-moz-range-thumb {
    width: 16px;
    height: 16px;
    background: #E8DEFF;
    border: 2px solid rgba(108, 92, 231, 0.6);
    border-radius: 50%;
    cursor: pointer;
}
.settings-slider-val {
    font-family: var(--font);
    font-size: 12px;
    color: #2D3436;
    font-weight: 600;
    min-width: 40px;
    text-align: right;
    flex-shrink: 0;
}

.char-panel-body {
    flex: 1;
    overflow-y: auto;
    padding: 16px 20px;
}
.char-stat-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid rgba(108, 92, 231, 0.15);
}
.char-stat-label {
    font-family: var(--font-h);
    font-size: 13px;
    color: #636E72;
}
.char-stat-value {
    font-family: var(--font-h);
    font-size: 14px;
    font-weight: 600;
    color: #2D3436;
}

/* ── Character Panel Tabs ── */
.char-panel-tabs {
    display: flex;
    border-bottom: 1px solid rgba(108, 92, 231, 0.3);
    padding: 0 12px;
    gap: 4px;
}
.char-panel-tabs__btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 0;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    font-family: var(--font-h);
    font-size: 13px;
    font-weight: 600;
    color: #A29BFE;
    cursor: pointer;
    transition: color 0.2s, border-color 0.2s;
}
.char-panel-tabs__btn:hover {
    color: #6C5CE7;
}
.char-panel-tabs__btn--active {
    color: #2D3436;
    border-bottom-color: #6C5CE7;
}
.char-panel-tabs__text {
    display: inline-block;
}
.char-panel-tabs__badge {
    flex: 0 0 auto;
}
.char-panel-body--hidden {
    display: none !important;
}

/* ── Clan Tab ── */
.clan-tab__logo-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 16px 0 12px;
    gap: 8px;
}
.clan-tab__logo {
    width: 80px;
    height: 80px;
    border-radius: 8px;
    border: 1px solid rgba(108, 92, 231, 0.3);
    background: rgba(108, 92, 231, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}
.clan-tab__logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.clan-tab__logo-placeholder {
    font-family: var(--font-h);
    font-size: 11px;
    color: #636E72;
}
.clan-tab__upload-btn {
    font-family: var(--font-h);
    font-size: 11px;
    padding: 4px 12px;
    background: rgba(108, 92, 231, 0.15);
    border: 1px solid rgba(108, 92, 231, 0.3);
    border-radius: 4px;
    color: #A29BFE;
    cursor: pointer;
    transition: background 0.2s;
}
.clan-tab__upload-btn:hover {
    background: rgba(108, 92, 231, 0.3);
}
.clan-tab__members {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding-top: 8px;
}
.clan-tab__member {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 0;
    border-bottom: 1px solid rgba(108, 92, 231, 0.1);
    font-family: var(--font-h);
    font-size: 12px;
}
.clan-tab__member-name {
    color: #2D3436;
    font-weight: 600;
}
.clan-tab__member-name--online {
    color: #00b894;
}
.clan-tab__member-name--offline {
    color: #636E72;
}
.clan-tab__member-role {
    font-size: 11px;
    color: #636E72;
}
.clan-tab__member-role--leader {
    color: #6C5CE7;
}
.clan-tab__member-role--assistant {
    color: #A29BFE;
}
.clan-tab__no-clan {
    text-align: center;
    padding: 40px 20px;
    font-family: var(--font-h);
    font-size: 13px;
    color: #636E72;
}

/* ── Relations Tab ── */
.relations-tab {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.relations-tab__card {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 12px;
    border: 1px solid rgba(108, 92, 231, 0.2);
    border-radius: 12px;
    background: rgba(108, 92, 231, 0.05);
}
.relations-tab__card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}
.relations-tab__card-title {
    font-family: var(--font-h);
    font-size: 14px;
    font-weight: 700;
    color: #2D3436;
}
.relations-tab__card-status {
    padding: 3px 9px;
    border-radius: 999px;
    font-family: var(--font-h);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.4px;
    text-transform: uppercase;
}
.relations-tab__card-status--open {
    background: rgba(108, 92, 231, 0.12);
    color: #6C5CE7;
}
.relations-tab__card-status--pending {
    background: rgba(230, 126, 34, 0.14);
    color: #d35400;
}
.relations-tab__card-status--linked {
    background: rgba(0, 184, 148, 0.14);
    color: #008a6e;
}
.relations-tab__target {
    font-family: var(--font-h);
    font-size: 15px;
    font-weight: 700;
    color: #2D3436;
}
.relations-tab__meta {
    font-family: var(--font);
    font-size: 12px;
    line-height: 1.45;
    color: #636E72;
}
.relations-tab__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.relations-tab__request-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    align-items: end;
}
.relations-tab__input-label {
    grid-column: 1 / -1;
    font-family: var(--font-h);
    font-size: 11px;
    font-weight: 700;
    color: #A29BFE;
    letter-spacing: 0.8px;
    text-transform: uppercase;
}
.relations-tab__input {
    min-width: 0;
    height: 38px;
    padding: 0 12px;
    border: 1px solid rgba(108, 92, 231, 0.25);
    border-radius: 9px;
    background: rgba(255,255,255,0.9);
    font-family: var(--font);
    font-size: 13px;
    color: #2D3436;
}
.relations-tab__input:focus {
    outline: none;
    border-color: #6C5CE7;
    box-shadow: 0 0 0 2px rgba(108, 92, 231, 0.12);
}
.relations-tab__input:disabled {
    background: rgba(99, 110, 114, 0.08);
    color: #636E72;
    cursor: not-allowed;
}
.relations-tab__action-btn {
    min-height: 34px;
    padding: 8px 12px;
    border-radius: 9px;
    border: 1px solid transparent;
    font-family: var(--font-h);
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, color 0.2s, opacity 0.2s;
}
.relations-tab__action-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}
.relations-tab__action-btn--primary {
    background: #6C5CE7;
    border-color: #6C5CE7;
    color: #fff;
}
.relations-tab__action-btn--primary:hover:not(:disabled) {
    background: #5b4bd5;
    border-color: #5b4bd5;
}
.relations-tab__action-btn--secondary {
    background: rgba(108, 92, 231, 0.12);
    border-color: rgba(108, 92, 231, 0.2);
    color: #6C5CE7;
}
.relations-tab__action-btn--secondary:hover:not(:disabled) {
    background: rgba(108, 92, 231, 0.2);
}
.relations-tab__action-btn--ghost {
    background: transparent;
    border-color: rgba(108, 92, 231, 0.2);
    color: #636E72;
}
.relations-tab__action-btn--ghost:hover:not(:disabled) {
    border-color: rgba(108, 92, 231, 0.35);
    color: #2D3436;
}
.relations-tab__action-btn--danger {
    background: rgba(214, 48, 49, 0.1);
    border-color: rgba(214, 48, 49, 0.2);
    color: #c0392b;
}
.relations-tab__action-btn--danger:hover:not(:disabled) {
    background: rgba(214, 48, 49, 0.18);
}
.relations-tab__section-label {
    margin-top: 4px;
}
.relations-tab__list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.relations-tab__request {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 12px;
    border: 1px solid rgba(108, 92, 231, 0.16);
    border-radius: 10px;
    background: #fff;
}
.relations-tab__request-content {
    min-width: 0;
    flex: 1;
}
.relations-tab__request-title {
    font-family: var(--font-h);
    font-size: 13px;
    font-weight: 700;
    color: #2D3436;
}
.relations-tab__request-meta {
    margin-top: 4px;
    font-family: var(--font);
    font-size: 12px;
    line-height: 1.4;
    color: #636E72;
}
.relations-tab__request-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 6px;
}
.relations-tab__empty {
    padding: 18px 14px;
    border: 1px dashed rgba(108, 92, 231, 0.2);
    border-radius: 10px;
    font-family: var(--font);
    font-size: 12px;
    color: #636E72;
    text-align: center;
    background: rgba(108, 92, 231, 0.03);
}

/* ── Inventory Panel (slides from right) ── */
#inventory-panel {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 0 16px;
    pointer-events: none;
}
#inventory-panel .inv-panel-inner {
    pointer-events: auto;
    transform: translateX(110%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    width: 340px;
    height: 80vh;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    box-shadow: 0 8px 30px rgba(0,0,0,0.06);
    overflow: hidden;
    position: relative;
}
#inventory-panel.open .inv-panel-inner {
    transform: translateX(0);
}
#inventory-panel.hidden { display: none; }

.inv-panel-body {
    flex: 1;
    overflow-y: auto;
    padding: 12px 16px;
}
.inv-section-label {
    font-family: var(--font-h);
    font-size: 12px;
    font-weight: 700;
    color: #A29BFE;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 8px;
    margin-top: 4px;
}
.inv-equipment {
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: center;
    margin-bottom: 14px;
}
.inv-equip-row {
    display: flex;
    gap: 4px;
    justify-content: center;
}
.inv-equip-slot {
    width: 52px;
    height: 52px;
    background-color: rgba(108, 92, 231, 0.08);
    border: 1px solid rgba(108, 92, 231, 0.25);
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    cursor: pointer;
    transition: border-color 0.2s;
}
.inv-equip-slot:hover {
    border-color: #6C5CE7;
}
.inv-equip-slot.inv-equip-spacer {
    background-color: transparent;
    border-color: transparent;
    cursor: default;
}
.inv-equip-slot.inv-equip-spacer:hover {
    border-color: transparent;
}
.equip-label {
    font-size: 10px;
    color: #636E72;
    font-family: var(--font-h);
    pointer-events: none;
}
.inv-bag {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 4px;
}
.inv-bag-slot {
    width: 100%;
    aspect-ratio: 1;
    background-color: rgba(108, 92, 231, 0.08);
    border: 1px solid rgba(108, 92, 231, 0.2);
    border-radius: 4px;
    cursor: pointer;
    transition: border-color 0.2s;
    background-size: 80% 80%;
    background-position: center;
    background-repeat: no-repeat;
}
.inv-bag-slot:hover {
    border-color: #6C5CE7;
}
.inv-bag-slot--dragging {
    opacity: 0.4;
    border-color: #6C5CE7;
}
.inv-bag-slot--dragover {
    border-color: #4ec9b0;
    background-color: rgba(78, 201, 176, 0.15);
    box-shadow: inset 0 0 8px rgba(78, 201, 176, 0.3);
}
.inv-equip-slot--dragging {
    opacity: 0.4;
}
.inv-equip-slot--dragover {
    border-color: #4ec9b0 !important;
    background-color: rgba(78, 201, 176, 0.15);
    box-shadow: inset 0 0 8px rgba(78, 201, 176, 0.3);
}

/* ── Loot Chest Panel ── */
.loot-chest__inner {
    display: flex;
    flex-direction: column;
    width: min(90vw, 205px);
}
.loot-chest__inner .catalogue-header {
    padding: 11px 12px 8px;
    cursor: move;
    user-select: none;
    touch-action: none;
}
.loot-chest__inner .catalogue-header::before {
    width: 56%;
    height: 3px;
}
.loot-chest__inner .catalogue-header h2 {
    font-size: 14px;
}
.loot-chest__inner .catalogue-close {
    font-size: 16px;
    padding: 2px 4px;
}
.loot-chest__body {
    padding: 9px 10px 11px;
}
.loot-chest__grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 6px;
}
.loot-chest__slot {
    aspect-ratio: 1;
    background: linear-gradient(180deg, rgba(108, 92, 231, 0.1), rgba(63, 46, 117, 0.16));
    border: 1px solid rgba(108, 92, 231, 0.28);
    border-radius: 10px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    transition: border-color 0.2s, background-color 0.2s;
    padding: 6px 6px 8px;
    position: relative;
    gap: 6px;
    min-height: 84px;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.25);
}
.loot-chest__slot:hover {
    border-color: #6C5CE7;
    background-color: rgba(108, 92, 231, 0.18);
}
.loot-chest__slot--coins {
    border-color: rgba(246, 191, 74, 0.45);
    background: linear-gradient(180deg, rgba(246, 191, 74, 0.18), rgba(108, 92, 231, 0.08));
}
.loot-chest__slot-icon {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background-position: center;
    background-repeat: no-repeat;
    background-size: contain;
    flex: 0 0 auto;
    margin-top: 2px;
}
.loot-chest__slot-icon--coins {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    background:
        radial-gradient(circle at 35% 30%, rgba(255, 249, 196, 0.95), rgba(255, 223, 92, 0.9) 38%, rgba(214, 146, 29, 0.95) 72%, rgba(131, 77, 8, 0.98) 100%);
    border: 1px solid rgba(255, 244, 180, 0.75);
    box-shadow:
        inset 0 2px 5px rgba(255, 255, 255, 0.45),
        0 4px 10px rgba(131, 77, 8, 0.35);
}
.loot-chest__coin-glyph {
    font-size: 24px;
    line-height: 1;
    filter: drop-shadow(0 2px 2px rgba(90, 55, 0, 0.25));
}
.loot-chest__slot-name {
    width: 100%;
    margin-top: auto;
    padding: 4px 5px;
    border-radius: 8px;
    border: 1px solid rgba(162, 155, 254, 0.26);
    background: rgba(28, 18, 58, 0.88);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.08),
        0 4px 10px rgba(12, 8, 28, 0.14);
    font-family: var(--font);
    font-size: 10px;
    font-weight: 700;
    color: #fbf8ff;
    text-align: center;
    line-height: 1.3;
    text-shadow: 0 1px 2px rgba(0,0,0,0.45);
    min-height: 0;
}
.loot-chest__slot--coins .loot-chest__slot-name {
    color: #fff1b3;
    font-size: 11px;
    border-color: rgba(246, 191, 74, 0.34);
    background: rgba(86, 57, 9, 0.88);
}
.loot-chest__slot-qty {
    font-family: var(--font);
    font-size: 9px;
    font-weight: 800;
    color: #f3efff;
    position: absolute;
    top: 5px;
    right: 5px;
    background: rgba(30, 18, 61, 0.78);
    border-radius: 999px;
    padding: 1px 5px;
}
.ih-floating-panel--dragging {
    transition: none !important;
}
.loot-chest__slot--common { border-color: rgba(108, 92, 231, 0.25); }
.loot-chest__slot--uncommon { border-color: #4ec9b0; }
.loot-chest__slot--rare { border-color: #6C5CE7; }
.loot-chest__slot--epic { border-color: #a855f7; }
.loot-chest__slot--legendary { border-color: #f59e0b; }

/* ── Chat Bubble above character ── */
.chat-bubble-container {
    position: absolute;
    pointer-events: none;
    z-index: 50;
}
.chat-bubble {
    background: rgba(0, 0, 0, 0.7);
    color: #E8DEFF;
    font-size: 12px;
    padding: 4px 10px;
    border-radius: 8px;
    border: 1px solid rgba(108, 92, 231, 0.3);
    max-width: 200px;
    text-align: center;
    white-space: pre-wrap;
    word-wrap: break-word;
    animation: chatBubbleFade 5s ease forwards;
}
@keyframes chatBubbleFade {
    0% { opacity: 1; }
    80% { opacity: 1; }
    100% { opacity: 0; }
}

/* Skill slot with icon */
.skill-slot .skill-icon {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    line-height: 1;
    color: #fff;
    text-shadow: 0 1px 3px rgba(0,0,0,0.8);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border-radius: 3px;
}
.skill-slot.on-cooldown { opacity: 0.4; }
.skill-slot .skill-qty {
    position: absolute;
    bottom: 1px;
    right: 2px;
    font-size: 11px;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 0 3px #000, 0 0 3px #000;
    pointer-events: none;
    z-index: 2;
    line-height: 1;
}
.skill-slot .cd-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
    color: #fff;
    border-radius: 3px;
}

/* ── Skill Catalogue Overlay ── */
#skill-catalogue {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 0 16px;
    pointer-events: none;
}
#skill-catalogue .catalogue-panel {
    pointer-events: auto;
    transform: translateX(110%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}
#skill-catalogue.open .catalogue-panel {
    transform: translateX(0);
}
#skill-catalogue.hidden { display: none; }

.catalogue-panel {
    width: 620px;
    height: 80vh;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    box-shadow: 0 8px 30px rgba(0,0,0,0.06);
    overflow: hidden;
    position: relative;
}

.catalogue-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px 12px;
    border-bottom: 1px solid var(--border);
    position: relative;
}
.catalogue-header::before {
    content: '';
    position: absolute;
    top: 0; left: 50%; transform: translateX(-50%);
    width: 60%;
    height: 4px;
    background: linear-gradient(90deg, transparent, #B86FD6, transparent);
    opacity: 0.7;
    border-radius: 2px;
}
.catalogue-header h2 {
    margin: 0;
    font-family: var(--font-h);
    font-size: 20px;
    font-weight: 700;
    color: #6C5CE7;
}
.catalogue-close {
    background: none;
    border: none;
    color: #A29BFE;
    font-size: 20px;
    cursor: pointer;
    padding: 4px 8px;
    transition: color 0.2s;
}
.catalogue-close:hover { color: #6C5CE7; }

.catalogue-tabs {
    display: flex;
    gap: 0;
    padding: 0 20px;
    border-bottom: 1px solid var(--border);
}
.cat-tab {
    flex: 1;
    padding: 10px 0;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    color: #A29BFE;
    font-family: var(--font-h);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: color 0.2s, border-color 0.2s;
    text-align: center;
}
.cat-tab:hover { color: #6C5CE7; }
.cat-tab.selected {
    color: #6C5CE7;
    border-bottom-color: #6C5CE7;
}

.catalogue-body {
    flex: 1;
    overflow-y: auto;
    padding: 16px 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.skill-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 14px;
    background: rgba(108, 92, 231, 0.06);
    border: 1px solid rgba(108, 92, 231, 0.2);
    border-radius: 6px;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
    position: relative;
}
.skill-card:hover {
    border-color: rgba(108, 92, 231, 0.5);
    background: rgba(108, 92, 231, 0.14);
}
.skill-card.locked {
    opacity: 0.35;
    cursor: not-allowed;
}
.skill-card .sc-icon {
    width: 44px;
    height: 44px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    flex-shrink: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}
.skill-card .sc-icon.cat-basic    { background-color: rgba(100, 150, 200, 0.25); border: 1px solid rgba(100, 150, 200, 0.4); }
.skill-card .sc-icon.cat-attack   { background-color: rgba(200, 60, 60, 0.25);   border: 1px solid rgba(200, 60, 60, 0.4); }
.skill-card .sc-icon.cat-defense  { background-color: rgba(60, 160, 80, 0.25);   border: 1px solid rgba(60, 160, 80, 0.4); }
.skill-card .sc-icon.cat-ultimate { background-color: rgba(200, 160, 40, 0.25);  border: 1px solid rgba(200, 160, 40, 0.4); }

.skill-card .sc-info { flex: 1; min-width: 0; }
.skill-card .sc-name {
    font-family: var(--font-h);
    font-size: 14px;
    font-weight: 600;
    color: #2D3436;
    margin-bottom: 2px;
}
.skill-card .sc-desc {
    font-size: 11px;
    color: #636E72;
    line-height: 1.4;
}
.skill-card .sc-meta {
    font-size: 10px;
    color: #636E72;
    margin-top: 3px;
}
.skill-card .sc-level-req {
    position: absolute;
    top: 8px;
    right: 12px;
    font-size: 10px;
    font-weight: 600;
    color: #A29BFE;
}
.skill-card.locked .sc-level-req { color: #cc4444; }
.skill-card .sc-equipped-tag {
    font-size: 9px;
    color: #4ec9b0;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.catalogue-footer {
    padding: 10px 20px;
    border-top: 1px solid var(--border);
}
.catalogue-hint {
    font-size: 11px;
    color: #636E72;
    text-align: center;
}

/* Top-right: minimap */
#hud-minimap {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 164px;
    height: 164px;
    text-align: center;
    border: 2px solid rgba(108, 92, 231, 0.4);
    border-radius: 4px;
    box-sizing: border-box;
    overflow: visible;
}

#minimap-canvas {
    width: 100%;
    height: 100%;
    display: block;
    background: rgba(0, 0, 0, 0.5);
}

#minimap-zone-name {
    position: absolute;
    bottom: 4px;
    left: 0;
    right: 0;
    font-family: var(--font-h);
    font-size: 17px;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 0 4px rgba(0,0,0,0.9), 0 1px 2px rgba(0,0,0,0.8);
    pointer-events: auto;
    cursor: pointer;
}
#minimap-zone-name:hover {
    color: #E8DEFF;
}
#minimap-coords {
    position: absolute;
    top: 4px;
    left: 0;
    right: 0;
    text-align: center;
    font-family: 'Courier New', monospace;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.85);
    text-shadow: 0 0 3px rgba(0,0,0,0.9);
    pointer-events: none;
    line-height: 1.2;
}
#minimap-map-selector {
    position: absolute;
    top: 100%;
    margin-top: 4px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(20, 15, 35, 0.95);
    border: 1px solid rgba(108, 92, 231, 0.6);
    border-radius: 4px;
    padding: 4px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    z-index: 10;
}
.minimap-map-btn {
    background: rgba(20, 15, 35, 0.8);
    border: 1px solid rgba(108, 92, 231, 0.3);
    border-radius: 3px;
    color: #fff;
    font-family: var(--font-h);
    font-size: 15px;
    font-weight: 600;
    padding: 4px 12px;
    cursor: pointer;
    white-space: nowrap;
    transition: border-color 0.2s, color 0.2s;
}
.minimap-map-btn:hover {
    border-color: #6C5CE7;
    color: #E8DEFF;
}
.minimap-map-btn.minimap-map-btn--active {
    border-color: #6C5CE7;
    background: rgba(108, 92, 231, 0.15);
    color: #E8DEFF;
    pointer-events: none;
}

/* Minimap expand button */
#minimap-expand-btn {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 24px;
    height: 24px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(20, 15, 35, 0.8);
    border: 1px solid rgba(108, 92, 231, 0.6);
    border-radius: 3px;
    color: #fff;
    cursor: pointer;
    z-index: 2;
    pointer-events: auto;
    transition: border-color 0.2s, background 0.2s;
}
#minimap-expand-btn:hover {
    border-color: #6C5CE7;
    background: rgba(108, 92, 231, 0.4);
}

/* Big map overlay */
#bigmap-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 200;
}
#bigmap-overlay.hidden {
    display: none;
}
#bigmap-container {
    position: relative;
    background: rgba(20, 15, 35, 0.95);
    border: 2px solid rgba(108, 92, 231, 0.6);
    border-radius: 6px;
    padding: 0;
    box-shadow: 0 0 40px rgba(108, 92, 231, 0.25);
    overflow: hidden;
}
#bigmap-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 10px;
    background: rgba(108, 92, 231, 0.15);
    border-bottom: 1px solid rgba(108, 92, 231, 0.3);
}
#bigmap-zone-label {
    font-family: var(--font-h);
    font-size: 18px;
    font-weight: 700;
    color: #E8DEFF;
    text-shadow: 0 0 4px rgba(0,0,0,0.6);
}
#bigmap-close-btn {
    background: none;
    border: 1px solid rgba(108, 92, 231, 0.4);
    border-radius: 3px;
    color: #fff;
    font-size: 18px;
    width: 26px;
    height: 26px;
    line-height: 24px;
    text-align: center;
    cursor: pointer;
    padding: 0;
    transition: border-color 0.2s, background 0.2s;
}
#bigmap-close-btn:hover {
    border-color: #FF7675;
    background: rgba(255, 118, 117, 0.15);
    color: #FF7675;
}
#bigmap-zoom-controls {
    display: flex;
    gap: 4px;
}
#bigmap-zoom-in-btn,
#bigmap-zoom-out-btn {
    background: rgba(20, 15, 35, 0.6);
    border: 1px solid rgba(108, 92, 231, 0.4);
    border-radius: 3px;
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    width: 26px;
    height: 26px;
    line-height: 24px;
    text-align: center;
    cursor: pointer;
    padding: 0;
    transition: border-color 0.2s, background 0.2s;
}
#bigmap-zoom-in-btn:hover,
#bigmap-zoom-out-btn:hover {
    border-color: #6C5CE7;
    background: rgba(108, 92, 231, 0.25);
}
#bigmap-canvas {
    display: block;
    width: 512px;
    height: 512px;
    cursor: crosshair;
}
#bigmap-hint {
    text-align: center;
    font-family: var(--font-b);
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
    padding: 4px 0 6px;
}

/* Top-right: performance stats (below minimap) */
#hud-perf-stats {
    position: absolute;
    top: 186px;
    right: 16px;
    width: 194px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 4px 6px;
    background: rgba(20, 15, 35, 0.7);
    border: 1px solid rgba(108, 92, 231, 0.3);
    border-radius: 3px;
    box-sizing: border-box;
    font-family: 'Courier New', monospace;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.7);
    pointer-events: none;
}
#hud-perf-stats.hidden { display: none; }
.perf-stats__item {
    display: flex;
    align-items: center;
    gap: 4px;
}
.perf-stats__item.hidden { display: none; }
.perf-stats__label {
    width: 42px;
    flex-shrink: 0;
    color: rgba(255, 255, 255, 0.5);
}
.perf-stats__value {
    width: 40px;
    text-align: right;
    flex-shrink: 0;
}
.perf-stats__graph {
    flex: 1;
    height: 24px;
    border-radius: 2px;
    background: rgba(255, 255, 255, 0.05);
}
.perf-stats__graph.hidden { display: none; }

/* Settings sub-options for perf stats */
.settings-sub {
    padding-left: 12px;
    border-left: 2px solid rgba(108, 92, 231, 0.3);
    margin-top: 6px;
}
.settings-sub.hidden { display: none; }
.settings-row--perf {
    gap: 8px;
}
.settings-sub-note {
    margin-top: 6px;
    color: rgba(255, 255, 255, 0.62);
    font-size: 11px;
    line-height: 1.35;
}
.settings-row--perf .settings-label {
    min-width: 70px;
}
.settings-select {
    background: var(--bg-input, #fff);
    border: 1px solid var(--border, rgba(108,92,231,0.12));
    border-radius: 6px;
    color: #2D3436;
    font-family: var(--font-h);
    font-size: 11px;
    font-weight: 600;
    padding: 2px 6px;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='5' viewBox='0 0 8 5'%3E%3Cpath d='M0 0l4 5 4-5z' fill='%236C5CE7'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 4px center;
    padding-right: 16px;
    line-height: 1.3;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.settings-select:hover {
    border-color: var(--border-h, rgba(108,92,231,0.35));
}
.settings-select:focus {
    outline: none;
    border-color: var(--primary, #6C5CE7);
    box-shadow: 0 0 0 2px rgba(108,92,231,0.15);
}
.settings-select option {
    background: #fff;
    color: #2D3436;
}

/* ── Skillbar Page Navigation ── */
#hud-skillbar-pages {
    position: absolute;
    bottom: 118px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}
.skillbar-page-btn {
    width: 32px;
    height: 22px;
    background: rgba(20, 15, 35, 0.8);
    border: 1px solid rgba(108, 92, 231, 0.3);
    border-radius: 3px;
    color: #A29BFE;
    font-family: var(--font-h);
    font-size: 10px;
    font-weight: 600;
    cursor: pointer;
    transition: border-color 0.2s, color 0.2s, background 0.2s;
    padding: 0;
}
.skillbar-page-btn:hover {
    border-color: #6C5CE7;
    color: #6C5CE7;
}
.skillbar-page-btn.active {
    border-color: #6C5CE7;
    background: rgba(108, 92, 231, 0.4);
    color: #E8DEFF;
    text-shadow: 0 0 4px rgba(108, 92, 231, 0.6);
}
#skillbar-page-label {
    display: none;
}

/* ── Exit Confirmation Dialog ── */
#exit-dialog {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
}
.exit-dialog__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
}
.exit-dialog__box {
    position: relative;
    width: 360px;
    max-width: 90vw;
    background: linear-gradient(180deg, rgba(240,230,255,0.95) 0%, rgba(232,222,255,0.92) 100%);
    border: 1px solid rgba(108, 92, 231, 0.4);
    border-radius: 8px;
    padding: 32px 28px 24px;
    text-align: center;
    box-shadow: 0 8px 40px rgba(108,92,231,0.15);
}
.exit-dialog__title {
    font-family: var(--font-h);
    font-size: 18px;
    font-weight: 700;
    color: #6C5CE7;
    margin-bottom: 10px;
    letter-spacing: 1px;
}
.exit-dialog__text {
    font-size: 13px;
    color: #A29BFE;
    margin-bottom: 22px;
}
.exit-dialog__buttons {
    display: flex;
    gap: 10px;
    justify-content: center;
}
.exit-dialog__buttons .btn {
    flex: 1;
    padding: 12px;
    font-family: var(--font-h);
    letter-spacing: 1.5px;
    font-size: 0.8rem;
}

/* ── Account Kicked Overlay ── */
#kick-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(16, 10, 34, 0.82);
    backdrop-filter: blur(12px);
}
.kick-overlay__inner {
    width: min(420px, 100%);
    text-align: center;
    padding: 34px 30px 28px;
    background: linear-gradient(180deg, rgba(255,255,255,0.98) 0%, rgba(240,230,255,0.96) 100%);
    border: 3px solid var(--secondary);
    border-radius: var(--radius);
    box-shadow:
        0 18px 50px rgba(25, 12, 56, 0.38),
        0 0 0 1px rgba(255,255,255,0.35) inset;
}
.kick-overlay__icon {
    font-size: 48px;
    color: var(--red);
    margin-bottom: 14px;
}
.kick-overlay__title {
    font-family: var(--font-display);
    font-size: clamp(24px, 4vw, 34px);
    font-weight: 400;
    color: var(--primary);
    margin-bottom: 12px;
    letter-spacing: 1.5px;
    text-transform: uppercase;
}
.kick-overlay__text {
    margin: 0;
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
    line-height: 1.6;
}
.kick-overlay__actions {
    margin-top: 24px;
}
.kick-overlay__actions .btn {
    width: 100%;
}

/* ── Panel Resize Handle ── */
/* Resize handle - corner grip inside the panel */
.panel-resize-handle {
    position: absolute;
    width: 16px;
    height: 16px;
    cursor: nwse-resize;
    z-index: 5;
    opacity: 0.6;
    background:
        linear-gradient(135deg, transparent 30%, rgba(255, 255, 255, 0.7) 30%, rgba(255, 255, 255, 0.7) 40%, transparent 40%,
        transparent 50%, rgba(255, 255, 255, 0.7) 50%, rgba(255, 255, 255, 0.7) 60%, transparent 60%,
        transparent 70%, rgba(255, 255, 255, 0.7) 70%, rgba(255, 255, 255, 0.7) 80%, transparent 80%);
}
#hud-chat .panel-resize-handle {
    top: 0;
    right: 2px;
    transform: rotate(-90deg);
}
#hud-combat-log .panel-resize-handle {
    top: 0;
    left: 2px;
    cursor: nesw-resize;
    transform: scaleX(-1) rotate(-90deg);
}
.panel-resize-handle:hover,
.panel-resize-handle:active {
    opacity: 1;
}

/* ── Inventory Quantity Badge ── */
.inv-qty {
    position: absolute;
    bottom: 1px;
    right: 2px;
    font-size: 9px;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 0 3px #000, 0 1px 2px #000;
    pointer-events: none;
}
.inv-bag-slot {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ── Active Buffs HUD ── */
#buffs-hud {
    position: fixed;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 900;
    display: flex;
    gap: 6px;
    pointer-events: auto;
    cursor: move;
    background: rgba(10, 8, 18, 0.75);
    border: 1px solid rgba(108, 92, 231, 0.35);
    border-radius: 6px;
    padding: 5px 7px;
}
#buffs-hud:empty {
    display: none;
}
.buff-icon {
    width: 48px;
    height: 58px;
    background-color: rgba(25, 18, 40, 0.9);
    border: 1px solid rgba(108, 92, 231, 0.5);
    border-radius: 5px;
    position: relative;
    cursor: default;
}
.buff-icon__remove {
    display: none;
    position: absolute;
    top: -6px;
    right: -6px;
    width: 16px;
    height: 16px;
    background: rgba(180, 40, 40, 0.9);
    border: 1px solid rgba(220, 80, 80, 0.7);
    border-radius: 50%;
    color: #fff;
    font-size: 10px;
    line-height: 14px;
    text-align: center;
    cursor: pointer;
    z-index: 2;
}
.buff-icon:hover .buff-icon__remove {
    display: block;
}
.buff-icon__svg {
    position: absolute;
    top: 5px;
    left: 5px;
    right: 5px;
    bottom: 15px;
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
    border-radius: 3px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}
.buff-icon__svg svg {
    width: 100%;
    height: 100%;
    display: block;
}
.buff-icon__timer {
    position: absolute;
    bottom: 1px;
    left: 0;
    right: 0;
    text-align: center;
    font-size: 10px;
    color: #ccc;
    font-family: var(--font);
    white-space: nowrap;
    line-height: 1;
}
.buff-icon--expiring {
    border-color: #cc4444;
    animation: buff-pulse 1s ease-in-out infinite;
}
@keyframes buff-pulse {
    0%, 100% { box-shadow: 0 0 4px rgba(204, 68, 68, 0.3); }
    50% { box-shadow: 0 0 10px rgba(204, 68, 68, 0.7); }
}

/* ── Tooltip ── */
.ih-tooltip {
    position: fixed;
    z-index: 99999;
    pointer-events: none;
    min-width: 180px;
    max-width: 300px;
    padding: 10px 14px;
    background: rgba(15, 10, 25, 0.95);
    border: 1px solid rgba(108, 92, 231, 0.5);
    border-radius: 6px;
    box-shadow: 0 0 12px rgba(108, 92, 231, 0.25);
    font-family: var(--font);
    font-size: 13px;
    color: #ddd;
    line-height: 1.45;
}
.ih-tooltip__name {
    font-size: 15px;
    font-weight: 700;
    margin-bottom: 2px;
}
.ih-tooltip__rarity {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 4px;
}
.ih-tooltip__type {
    font-size: 12px;
    color: #999;
    margin-bottom: 6px;
}
.ih-tooltip__stat {
    font-size: 12px;
    color: #ccc;
    margin: 2px 0;
}
.ih-tooltip__val {
    color: #5f5;
    font-weight: 600;
}
.ih-tooltip__heart {
    color: #ff7aa2;
    font-weight: 700;
}
.ih-tooltip__desc {
    font-size: 11px;
    color: #aaa;
    font-style: italic;
    margin-top: 6px;
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 6px;
}

/* ── Scrollbar styling ── */
::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #555; border-radius: 3px; }

/* ── Responsive ── */
@media (max-width: 768px) {
    .screen-title { font-size: 1.4rem; }
    .screen-title-sm { font-size: 1.1rem; }
    .loading-bar-container { width: 240px; }
    .play-box { padding: 28px 22px; }
    .play-box-wide { max-width: 95vw; }
    #hud-chat { width: 260px; height: 160px; }
    #hud-combat-log { width: 220px; height: 120px; }
    .skill-slot { width: 40px; height: 40px; }
    .hotkey { font-size: 0.55rem; }
    #hud-skill-bar { gap: 3px; }
    .option-btn { min-width: 70px; padding: 10px 6px; font-size: 0.8rem; }
    #buffs-hud { transform: translateX(-50%) scale(0.85); }
    #hud-target-frame { transform: translateX(-50%) scale(0.9); }
    #hud-player-info { transform: scale(0.9); transform-origin: top left; }
    .party-invite-modal,
    .trade-request-modal,
    #loot-chest-panel,
    .merchant-panel {
        bottom: 150px;
    }
    .party-invite-modal__card,
    .trade-request-modal__card,
    .loot-chest__inner {
        width: min(92vw, 198px);
    }
    .merchant-panel__inner {
        width: min(94vw, 338px);
    }
}

@media (max-width: 480px) {
    #hud-chat { width: 180px; height: 120px; font-size: 0.7rem; bottom: 100px; }
    #hud-combat-log { width: 160px; height: 100px; font-size: 0.65rem; bottom: 100px; }
    .skill-slot { width: 32px; height: 32px; }
    .hotkey { font-size: 0.5rem; }
    #hud-skill-bar { gap: 2px; bottom: 40px; }
    #hud-bottom-bar { height: 36px; }
    #hud-bottom-bar .bar-action-btn { width: 32px; height: 32px; font-size: 0.65rem; }
    #buffs-hud { transform: translateX(-50%) scale(0.7); }
    #hud-target-frame { transform: translateX(-50%) scale(0.8); }
    #hud-player-info { transform: scale(0.8); transform-origin: top left; }
    #exp-bar-container { height: 14px; }
    .play-box { padding: 16px 12px; }
    .play-box-wide { max-width: 100vw; }
    .party-invite-modal,
    .trade-request-modal,
    #loot-chest-panel,
    .merchant-panel {
        bottom: 148px;
    }
    .party-invite-modal__card,
    .trade-request-modal__card,
    .loot-chest__inner {
        width: min(94vw, 188px);
    }
    .merchant-panel__inner {
        width: min(95vw, 318px);
    }
    .party-invite-modal__body,
    .trade-request-modal__body,
    .loot-chest__body,
    .merchant-panel__body {
        padding-left: 9px;
        padding-right: 9px;
    }
    .party-invite-modal__text,
    .trade-request-modal__text,
    .loot-chest__slot-name,
    .merchant-panel__status {
        font-size: 10px;
    }
    .merchant-panel__card {
        grid-template-columns: 38px minmax(0, 1fr);
    }
    .merchant-panel__side {
        grid-column: 1 / -1;
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
    .loot-chest__slot {
        min-height: 80px;
        padding: 5px 5px 7px;
    }
    .loot-chest__slot-icon {
        width: 34px;
        height: 34px;
    }
    .loot-chest__slot-icon--coins {
        width: 38px;
        height: 38px;
    }
}

/* ── Server Selection Cards ── */
#server-list {
    max-height: 300px;
    overflow-y: auto;
    margin-bottom: 8px;
    padding: 18px;
}

.server-card {
    padding: 16px 20px;
    border: 1px solid var(--border);
    border-radius: 8px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: all 0.25s;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--bg-input);
    position: relative;
    overflow: hidden;
    isolation: isolate;
}

.server-card:hover {
    border-color: var(--border-h);
    background: rgba(108,92,231,0.04);
}

.server-card.selected {
    border-color: var(--accent);
    background: rgba(108,92,231,0.08);
    box-shadow: 0 0 16px var(--accent-glow) inset;
}

.server-card .server-name {
    font-family: var(--font-h);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--accent);
    letter-spacing: 1.5px;
}

.server-card .server-info {
    font-family: var(--font);
    font-size: 0.75rem;
    color: var(--text-dim);
    margin-top: 2px;
}

.server-card .server-status {
    font-family: var(--font-h);
    font-size: 0.7rem;
    color: #4ec94b;
    letter-spacing: 1px;
    text-transform: uppercase;
}

/* ── Character Slot Cards (3 slots with empty) ── */
.char-slot-empty {
    padding: 14px 18px;
    border: 1px dashed rgba(108, 92, 231, 0.3);
    border-radius: 8px;
    margin-bottom: 8px;
    text-align: center;
    color: var(--text-dim);
    font-family: var(--font-h);
    font-size: 0.85rem;
    letter-spacing: 1px;
    opacity: 0.5;
}

/* ── Clan info in character card ── */
.char-card .char-clan {
    font-size: 0.7rem;
    color: #e74c3c;
    margin-top: 1px;
}

.form-buttons-3 .btn:nth-child(2),
.form-buttons-3 .btn:nth-child(3),
.form-buttons-3 .btn:nth-child(4) {
    flex: 1 1 auto;
}

/* ── Trade Window ── */
.trade-window {
    position: fixed;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    z-index: 800;
    pointer-events: auto;
}
.trade-window.hidden { display: none; }
.trade-window__inner {
    position: relative;
    background: var(--bg-dark, #1a1a2e);
    border: 1px solid var(--border, rgba(108, 92, 231, 0.3));
    border-radius: 10px;
    width: 580px;
    max-height: 90vh;
    overflow-y: auto;
}
.trade-window__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    border-bottom: 1px solid rgba(108, 92, 231, 0.2);
}
.trade-window__header h2 {
    color: var(--text, #e0e0e0);
    font-family: var(--font-h, 'Cinzel', serif);
    font-size: 1rem;
    margin: 0;
}
.trade-window__body {
    display: flex;
    padding: 12px;
    gap: 0;
}
.trade-window__side {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.trade-window__side-label {
    color: var(--text-dim, #aaa);
    font-family: var(--font-h, 'Cinzel', serif);
    font-size: 0.8rem;
    text-align: center;
    letter-spacing: 1px;
}
.trade-window__divider {
    width: 1px;
    background: rgba(108, 92, 231, 0.25);
    margin: 0 10px;
}
.trade-window__grid {
    display: grid;
    grid-template-columns: repeat(5, 42px);
    grid-template-rows: repeat(2, 42px);
    gap: 3px;
    justify-content: center;
}
.trade-window__grid .trade-slot {
    width: 42px;
    height: 42px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(108, 92, 231, 0.2);
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    cursor: pointer;
}
.trade-window__grid .trade-slot img {
    width: 34px;
    height: 34px;
    object-fit: contain;
    pointer-events: none;
}
.trade-window__grid .trade-slot .trade-slot__remove {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    color: #e74c3c;
    background: rgba(0, 0, 0, 0.55);
    border-radius: 4px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.15s;
}
.trade-window__side--self .trade-slot:not([data-item-uuid=""]):hover .trade-slot__remove {
    opacity: 1;
}
.trade-window__side--self .trade-slot.trade-slot--dragover {
    border-color: #6c5ce7;
    background: rgba(108, 92, 231, 0.15);
}
.trade-window__grid .trade-slot.trade-slot--disabled {
    opacity: 0.2;
    cursor: not-allowed;
    pointer-events: none;
    background: rgba(255, 255, 255, 0.02);
}
.trade-window__grid .trade-slot .trade-slot__qty {
    position: absolute;
    bottom: 1px;
    right: 2px;
    font-size: 0.6rem;
    color: #fff;
    text-shadow: 0 0 3px #000;
}
.trade-window__gold-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 4px 0;
}
.trade-window__gold-label {
    color: var(--text-dim, #aaa);
    font-size: 0.8rem;
    font-family: var(--font-h, 'Cinzel', serif);
}
.trade-window__gold-input {
    width: 80px;
    padding: 3px 6px;
    border: 1px solid rgba(108, 92, 231, 0.3);
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.06);
    color: #e0e0e0;
    font-size: 0.8rem;
    text-align: center;
}
.trade-window__gold-val {
    color: #6C5CE7;
    font-weight: 600;
    font-size: 0.85rem;
}
.trade-window__confirm-btn {
    padding: 6px 16px;
    border: none;
    border-radius: 6px;
    background: #6c5ce7;
    color: #fff;
    font-family: var(--font-h, 'Cinzel', serif);
    font-size: 0.8rem;
    cursor: pointer;
    transition: background 0.2s;
    align-self: center;
}
.trade-window__confirm-btn:hover { background: #7d6ef0; }
.trade-window__confirm-btn.trade-window__confirm-btn--confirmed {
    background: #27ae60;
    cursor: default;
}
.trade-window__partner-status {
    text-align: center;
    font-size: 0.75rem;
    color: var(--text-dim, #aaa);
    font-family: var(--font-h, 'Cinzel', serif);
}
.trade-window__partner-status.trade-window__partner-status--confirmed {
    color: #27ae60;
}
.trade-window__bag {
    padding: 8px 12px 12px;
    border-top: 1px solid rgba(108, 92, 231, 0.2);
}
.trade-window__bag-label {
    color: var(--text-dim, #aaa);
    font-family: var(--font-h, 'Cinzel', serif);
    font-size: 0.75rem;
    margin-bottom: 6px;
    text-align: center;
    letter-spacing: 1px;
}
.trade-window__bag-grid {
    display: grid;
    grid-template-columns: repeat(6, 42px);
    gap: 3px;
    justify-content: center;
}
.trade-window__bag-grid .trade-bag-slot {
    width: 42px;
    height: 42px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(108, 92, 231, 0.15);
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    cursor: pointer;
}
.trade-window__bag-grid .trade-bag-slot.trade-bag-slot--untradable {
    opacity: 0.35;
    cursor: not-allowed;
}
.trade-window__bag-grid .trade-bag-slot img {
    width: 34px;
    height: 34px;
    object-fit: contain;
    pointer-events: none;
}
.trade-window__bag-grid .trade-bag-slot .trade-bag-slot__qty {
    position: absolute;
    bottom: 1px;
    right: 2px;
    font-size: 0.6rem;
    color: #fff;
    text-shadow: 0 0 3px #000;
}

/* PUS rarity color */
.rarity--pus { color: #95a5a6; }

