        /* 기본 스타일 설정 */
        :root {
            --bg-color: #121212;
            --sidebar-bg: #1e1e1e;
            --panel-bg: #252525;
            --text-main: #e0e0e0;
            --text-sub: #a0a0a0;
            --accent: #FFD700; /* 골드 */
            --good: #00FF7F;   /* 초록 (더 좋은 스탯) */
            --border: #333;
            --item-hover: #333;
            --item-selected: #444;
        }

        body {
            margin: 0;
            padding: 0;
            font-family: 'Suit', 'Pretendard', sans-serif;
            background-color: var(--bg-color);
            color: var(--text-main);
            height: 100vh;
            overflow: hidden;
            display: flex;
        }

        /* 1. 왼쪽 사이드바 (장비 목록 - 이미지 그리드) */
        .sidebar {
            width: 340px; /* 4열을 위해 너비 약간 조정 */
            background-color: var(--sidebar-bg);
            border-right: 1px solid var(--border);
            overflow-y: auto;
            display: flex;
            flex-direction: column;
            flex-shrink: 0;
        }

        .set-group {
            margin-bottom: 10px;
        }

        .set-header {
            padding: 10px 15px;
            background-color: #2a2a2a;
            font-weight: bold;
            font-size: 0.85rem;
            color: var(--text-sub);
            position: sticky;
            top: 0;
            z-index: 10;
            border-bottom: 1px solid #333;
        }

        /* 아이템 그리드 컨테이너 (4열) */
        .item-grid {
            display: grid;
            grid-template-columns: repeat(4, 1fr);
            gap: 8px;
            padding: 10px;
        }

        .item-row {
            aspect-ratio: 1 / 1;
            cursor: pointer;
            position: relative;
            border-radius: 6px;
            overflow: hidden;
            transition: transform 0.1s, opacity 0.3s, border-color 0.2s;
            background-color: #000;
            border: 2px solid transparent;
        }

        .item-row:hover {
            transform: scale(1.05);
            z-index: 1;
            border-color: #666;
        }

        .item-row.active {
            border-color: var(--accent);
            box-shadow: 0 0 10px rgba(255, 215, 0, 0.2);
        }

        /* 필터링 스타일 */
        .item-row.dimmed {
            opacity: 0.1;
            filter: grayscale(100%);
            pointer-events: none;
        }

        /* 개선점 4: 수치가 더 높을 때 초록색 강조 */
        .item-row.exceed {
            border-color: var(--good);
            box-shadow: 0 0 8px rgba(0, 255, 127, 0.4);
        }

        .item-thumb {
            width: 100%;
            height: 100%;
            object-fit: cover;
            display: block;
        }

        /* 2. 중앙 (장비 이미지) */
        .main-view {
            flex-grow: 1;
            display: flex;
            justify-content: center;
            align-items: center;
            background: radial-gradient(circle at center, #2a2a2a 0%, #121212 100%);
            position: relative;
            overflow: hidden;
        }

        .large-image-container {
            text-align: center;
            padding: 20px;
        }

        .large-image {
            max-width: 400px;
            max-height: 400px;
            width: 100%;
            height: auto;
            filter: drop-shadow(0 0 20px rgba(0,0,0,0.7));
            transition: transform 0.3s;
        }
        
        .img-placeholder {
            width: 200px;
            height: 200px;
            background: #333;
            display: flex;
            align-items: center;
            justify-content: center;
            color: #666;
            border-radius: 10px;
            margin: auto;
        }

        /* 3. 오른쪽 (스탯 정보) */
        .info-panel {
            width: 350px;
            background-color: var(--panel-bg);
            border-left: 1px solid var(--border);
            padding: 40px 30px;
            display: flex;
            flex-direction: column;
            box-shadow: -5px 0 15px rgba(0,0,0,0.3);
            overflow-y: auto;
        }

        .info-title {
            font-size: 1.5rem;
            margin-bottom: 10px;
            color: #fff;
            border-bottom: 2px solid var(--accent);
            padding-bottom: 15px;
            word-break: keep-all;
        }

        .info-set-name {
            font-size: 0.9rem;
            color: var(--accent);
            margin-bottom: 20px;
        }

        .stat-box {
            display: flex;
            flex-direction: column;
            gap: 15px;
        }

        .stat-row {
            background-color: #333;
            padding: 15px;
            border-radius: 8px;
            display: flex;
            justify-content: space-between;
            align-items: center;
            cursor: pointer;
            transition: transform 0.2s, background 0.2s;
            border: 1px solid transparent;
        }

        .stat-row:hover {
            transform: translateX(-5px);
            background-color: #3d3d3d;
            border-color: #666;
        }

        /* 활성화된 필터 표시 */
        .stat-row.active-filter {
            background-color: rgba(255, 215, 0, 0.15);
            border-color: var(--accent);
        }

        .stat-label { font-size: 0.95rem; color: #ccc; }
        .stat-value { font-size: 1.1rem; font-weight: bold; color: #fff; }

        .filter-info {
            margin-top: 20px;
            padding: 10px;
            border-radius: 5px;
            font-size: 0.85rem;
            background: rgba(0,0,0,0.2);
            min-height: 20px;
            color: var(--accent);
        }

        .legend {
            display: flex;
            gap: 10px;
            font-size: 0.75rem;
            margin-top: 5px;
            color: #888;
        }
        .legend span { display: flex; align-items: center; gap: 4px; }
        .dot { width: 8px; height: 8px; border-radius: 50%; }

        .filter-reset-btn {
            margin-top: 20px;
            padding: 12px;
            background-color: #444;
            color: white;
            border: none;
            border-radius: 5px;
            cursor: pointer;
            text-align: center;
            display: none;
            width: 100%;
        }
        .filter-reset-btn:hover { background-color: #555; }

        /* 개선점 2: 모바일 반응형 */
        @media (max-width: 768px) {
            body {
                flex-direction: column;
                overflow-y: auto; /* 전체 스크롤 허용 */
                height: auto;
            }

            /* 순서 변경: 이미지(1) -> 스탯(2) -> 목록(3) */
            .main-view {
                order: 1;
                height: 300px; /* 이미지 영역 높이 고정 */
                flex-grow: 0;
                background: #1a1a1a;
            }
            .large-image { max-height: 250px; }

            .info-panel {
                order: 2;
                width: 100%;
                box-sizing: border-box; /* 패딩 포함 */
                border-left: none;
                border-bottom: 1px solid var(--border);
                padding: 20px;
                height: auto;
            }

            .sidebar {
                order: 3;
                width: 100%;
                border-right: none;
                height: auto; /* 내용만큼 늘어남 */
                max-height: 500px; /* 너무 길어지지 않게 제한 */
            }

            .item-grid {
                grid-template-columns: repeat(4, 1fr);
            }
        }
        
        @media (max-width: 480px) {
             .item-grid { grid-template-columns: repeat(4, 1fr); }
        }

        /* 스크롤바 커스텀 */
        ::-webkit-scrollbar { width: 6px; }
        ::-webkit-scrollbar-track { background: #1e1e1e; }
        ::-webkit-scrollbar-thumb { background: #444; border-radius: 3px; }