/* 保持原有样式不变 */
.carousel-container {
    max-width: 600px;
    margin: 0;
    padding: 0;
}

.main-carousel {
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    margin-bottom: 1rem;
    position: relative;
    cursor: zoom-in;
}

.zoom-indicator {
    position: absolute;
    bottom: 15px;
    right: 15px;
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.main-carousel:hover .zoom-indicator {
    opacity: 1;
}

.carousel-item img {
    width: 100%;
    max-height: 600px;
    object-fit: cover;
}

.thumbnail-carousel {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    overflow-x: auto;
    padding: 0.5rem 0;
    scrollbar-width: thin;
}

.thumbnail-item {
    width: 70px;
    height: 70px;
    cursor: pointer;
    overflow: hidden;
    opacity: 0.7;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.thumbnail-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.thumbnail-item.active {
    opacity: 1;
    border: 2px solid #007bff;
    transform: scale(1.05);
}

.thumbnail-item:hover img {
    transform: scale(1.1);
}

/* 修复的模态框样式 */
.zoom-modal {
    z-index: 1060 !important;
    /* 确保模态框在最上层 */
}

.zoom-modal .modal-dialog {
    max-width: 90%;
    max-height: 90vh;
    margin: 1.75rem auto;
}

.zoom-modal .modal-content {
    background-color: rgba(0, 0, 0, 0.9);
    border: none;
    border-radius: 0;
    position: relative;
    /* 关键：确保关闭按钮相对模态框定位 */
}

.zoom-modal .modal-body {
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    max-height: 80vh;
}

.zoom-modal .modal-body img {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
}

/* 修复的关闭按钮样式 */
.zoom-close-btn {
    position: absolute;
    top: 20px;
    right: 30px;
    color: white;
    font-size: 3rem;
    opacity: 1;
    z-index: 10;
    background: none;
    border: none;
    cursor: pointer;
    transition: color 0.3s ease;
}

.zoom-close-btn:hover {
    color: #ddd;
    text-decoration: none;
}

@media (max-width: 768px) {
    .carousel-item img {
        height: 300px;
    }

    .thumbnail-item {
        width: 80px;
        height: 60px;
    }

    .zoom-close-btn {
        font-size: 2rem;
    }
}

/* 增加行分隔线和内边距 */
.product-details .d-flex {
    padding: 8px 0;
    border-bottom: 1px solid #eee;
}

.product-details .d-flex:last-child {
    border-bottom: none;
    /* 最后一行去掉下划线 */
}

/* 确保小屏幕下标签和内容对齐 */
@media (max-width: 767px) {
    .product-details .d-flex {
        margin-bottom: 8px;
    }
}

.blog-item{
    box-shadow: 0px 0px 5px rgba(0, 0, 0, 0.2);
}

.blog-item:hover{
    box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.5);
}