/* ============================================
   INVENTORY MODAL STYLES
   ============================================ */

/* Inventory Modal 전용 스타일 */
/* RPG Modal 공통 스타일은 modal-common.css에 정의되어 있습니다 */

/* Inventory Modal 타이틀 스타일 (margin, padding 추가) */
.inventory-modal-wrapper .card.rpg-modal .modal-title {
    margin: 0;
    padding: 0;
    line-height: 1.2;
}

/* Inventory Layout */
.inventory-modal-wrapper .card {
    position: relative;
    overflow: hidden !important;
    display: flex;
    flex-direction: column;
    max-height: 85vh;
}

.inventory-modal-wrapper .inv-header {
    flex-shrink: 0;
}

.inventory-modal-wrapper .inv-container {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 5px;
}

#inv-close-btn {
    flex-shrink: 0;
    z-index: 30;
    width: 100%;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #333;
    cursor: pointer;
}

@media (max-height: 420px) {
    #inv-close-btn {
        position: fixed;
        right: 16px;
        bottom: 18px;
        width: auto;
        max-width: 120px;
    }
    .inventory-modal-wrapper .card {
        padding-bottom: 80px;
    }
}

.inv-header {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px;
    border-bottom: 1px solid #333;
    margin-bottom: 10px;
    text-align: center;
}

.inv-container {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.inv-player {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.inv-slot {
    width: 60px;
    height: 60px;
    background: #222;
    border: 2px dashed #444;
    border-radius: 8px;
    margin: 5px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 15px;
}

.inv-body {
    display: flex;
    align-items: center;
    gap: 12px;
}

.inv-head {
    display: flex;
    justify-content: center;
    width: 100%;
}

.inv-torso {
    width: 56px;
    height: 80px;
    background: #333;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.inv-body .inv-slot {
    width: 56px;
    height: 56px;
    margin: 0;
}

.inv-legs {
    display: flex;
}

.inv-section-title {
    width: 100%;
    text-align: left;
    font-size: 14px;
    font-weight: bold;
    color: rgba(255, 214, 120, 0.98);
    text-shadow:
        0 2px 0 rgba(60, 40, 10, 0.9),
        0 10px 24px rgba(0, 0, 0, 0.6);
    margin-top: 16px;
    margin-bottom: 8px;
}

.inv-storage {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.inv-items {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
    gap: 10px;
    background: #222;
    padding: 10px;
    border-radius: 8px;
    min-height: 80px;
}

.inv-capacity {
    text-align: right;
    font-size: 12px;
    color: #888;
    margin-top: 5px;
}

.inv-relics {
    display: flex;
    flex-direction: column;
    gap: 8px;
    background: #222;
    padding: 10px;
    border-radius: 8px;
    margin-top: 10px;
}

.inv-item {
    width: 60px;
    height: 60px;
    background: #333;
    border: 1px solid #555;
    border-radius: 8px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 15px;
    cursor: pointer;
}

#inv-item-detail {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: calc(100% - 40px);
    background: #2a2a2a;
    border: 1px solid var(--primary);
    border-radius: 12px;
    padding: 15px;
    z-index: 10;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
    text-align: left;
}

#detail-header {
    display: flex;
    align-items: center;
    gap: 10px;
    border-bottom: 1px solid #444;
    padding-bottom: 10px;
    margin-bottom: 10px;
}

#detail-icon {
    font-size: 15px;
}

#detail-name {
    font-size: 14px;
    font-weight: bold;
    flex-grow: 1;
}

#detail-close {
    background: none;
    border: none;
    color: #888;
    font-size: 15px;
    cursor: pointer;
}

#detail-desc {
    font-size: 14px;
    color: #ccc;
    margin-bottom: 15px;
}

#detail-actions button {
    width: 100%;
    padding: 10px;
    font-size: 15px;
}

.relic-item {
    background: #333;
    border: 1px solid #555;
    border-radius: 6px;
    padding: 8px 12px;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 10px;
}
