.part-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    padding: 20px;
    box-sizing: border-box;
}

.part-modal-overlay.active {
    display: flex;
}

@media (max-width: 800px) {
    .part-modal-overlay {
        padding: 0px;
    }
}

.part-modal-content {
    background-color: white;
    padding: 2.5rem;
    border-radius: 0.75rem;
    width: 100%;
    max-width: 900px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
}

.part-modal-close-btn {
    position: absolute;
    top: 1rem;
    right: 1rem;
    font-size: 2rem;
    color: #6b7280;
    background: none;
    border: none;
    cursor: pointer;
    line-height: 1;
    z-index: 10;
}

.part-modal-loader {
    text-align: center;
    padding: 4rem;
    font-size: 1.2rem;
}

.part-modal-body {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2.5rem;
    visibility: hidden;
}

.part-modal-body.loaded {
    visibility: visible;
}

@media (min-width: 768px) {
    .part-modal-body {
        grid-template-columns: 1fr 1.2fr;
    }
}

.part-modal-gallery .main-image img {
    width: 100%;
    height: auto;
    aspect-ratio: 1/1;
    object-fit: contain;
    border-radius: 0.5rem;
}

.part-modal-gallery-content {
    margin-top: 1.5rem;
    border-top: 1px solid #f3f4f6;
    padding-top: 1.5rem;
}

.part-modal-details .part-title {
    font-size: 1.875rem;
    font-weight: 700;
    color: #1f2937;
    margin: 0 0 1rem 0;
}

.part-modal-price {
    font-size: 1.75rem;
    font-weight: 600;
    color: #111827;
    margin: 1rem 0;
}

.part-modal-meta-table {
    font-family: 'Inter', sans-serif;
    margin-top: 1.5rem;
    width: 100%;
    border-collapse: collapse;
}

.part-modal-meta-table tr {
    border-bottom: 1px solid #f3f4f6;
}

.part-modal-meta-table td {
    padding: 0.75rem 0.5rem;
    font-size: 0.95rem;
}

.part-modal-meta-table td:first-child {
    font-weight: 500;
    color: #6b7280;
}

.part-modal-meta-table td:last-child {
    font-weight: 600;
    color: #1f2937;
    text-align: right;
    max-width: 220px;
}

/* Gallery Thumbnails */
.part-modal-thumbnail-grid {
    /* display: grid;
                            grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
                            gap: 0.75rem; */
    margin-top: 1rem;
}

.part-modal-thumbnail-grid img {
    width: auto;
    height: 180px;
    object-fit: cover;
    border-radius: 0.375rem;
    cursor: pointer;
    transition: opacity 0.2s ease;
}

.part-modal-thumbnail-grid img:hover {
    opacity: 0.8;
}

/* Viewer (Lightbox) Styles */
.part-viewer-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 2000;
}

.part-viewer-overlay.active {
    display: flex;
}

.part-viewer-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
}

.part-viewer-content img {
    display: block;
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
}

.part-viewer-close,
.part-viewer-nav {
    position: absolute;
    background: rgba(0, 0, 0, 0.3);
    color: white;
    border: none;
    cursor: pointer;
    z-index: 2001;
    font-size: 1.5rem;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.part-viewer-close:hover,
.part-viewer-nav:hover {
    background: rgba(0, 0, 0, 0.6);
}

.part-viewer-close {
    top: 10px;
    right: 10px;
}

.part-viewer-nav {
    top: 50%;
    transform: translateY(-50%);
}

.part-viewer-prev {
    left: 10px;
}

.part-viewer-next {
    right: 10px;
}