/* Product Gallery */
.product-gallery {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 16px;
    margin-bottom: 24px;
}

.gallery-main {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 16px;
    height: 400px;
    background: #000;
}



.gallery-main .swiper {
    height: 100%;
}

.gallery-main .swiper-slide {
    display: flex;
    align-items: center;
    justify-content: center;
}

.gallery-main .swiper-slide a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    cursor: zoom-in;
}

.gallery-main .swiper-slide img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: opacity 0.3s ease;
}

.gallery-main .swiper-slide a:hover img {
    opacity: 0.9;
}

.gallery-thumbs {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 8px;
}

.gallery-thumbs::-webkit-scrollbar {
    height: 6px;
}

.gallery-thumbs::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.gallery-thumbs::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 10px;
}

.gallery-thumb {
    flex: 0 0 80px;
    height: 80px;
    position: relative;
    cursor: pointer;
    border-radius: 4px;
    overflow: hidden;
}

.gallery-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity 0.2s ease;
}

.gallery-thumb.active {
    border: 2px solid var(--primary-color);
}

.gallery-thumb:hover img {
    opacity: 0.8;
}

/* Product Header */
.product-header {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 16px;
    margin-bottom: 24px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.price-section {
    flex: 1;
    display: flex;
    justify-content: space-between;
}

.price {
    font-size: 28px;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
}

.price-meta {
    display: flex;
    gap: 16px;
    align-items: center;
}

.sponsored-badge {
    background: #e3f2fd;
    color: #1976d2;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
}

.date {
    color: #666;
    font-size: 14px;
}

.action-buttons {
    display: flex;
    gap: 8px;
}

.share-btn,
.favorite-btn {
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 8px;
    background: #f8f9fa;
    color: #666;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.share-btn:hover,
.favorite-btn:hover {
    background: #e9ecef;
    color: var(--primary-color);
}

/* Seller Card */
.seller-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 16px;
    margin-bottom: 24px;
}

.seller-profile {
    display: flex;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid #eee;
}

.seller-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    overflow: hidden;
    margin-right: 12px;
}

.seller-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.seller-details {
    flex: 1;
}

.seller-name {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin: 0 0 4px;
}

.seller-meta {
    color: #666;
    font-size: 13px;
    margin: 0;
}

.seller-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.seller-actions button {
    width: 100%;
    padding: 12px;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 14px;
}

.follow-btn {
    background: #f8f9fa;
    color: #333;
}

.follow-btn:hover {
    background: #e9ecef;
}

.message-btn {
    background: var(--primary-color);
    color: white;
}

.message-btn:hover {
    opacity: 0.9;
}

.phone-btn {
    background: #4caf50;
    color: white;
}

.phone-btn:hover {
    opacity: 0.9;
}

/* Safety Tips */
.safety-tips {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 16px;
}

.safety-tips h3 {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin-bottom: 16px;
}

.safety-tips ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.safety-tips li {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: #f8f9fa;
    border-radius: 8px;
    margin-bottom: 8px;
    font-size: 13px;
    color: #444;
}

.safety-tips li:last-child {
    margin-bottom: 0;
}

.safety-tips li i {
    color: var(--primary-color);
    font-size: 16px;
}

/* Product Specs */
.product-specs {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 16px;
    margin-bottom: 24px;
}

.product-specs h2 {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 16px;
}

.specs-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.spec-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.spec-label {
    color: #666;
    font-size: 13px;
}

.spec-value {
    color: #333;
    font-weight: 500;
    font-size: 14px;
}

/* Product Description */
.product-description {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 16px;
    margin-bottom: 24px;
}

.product-description h2 {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 16px;
}

.description-content {
    color: #444;
    line-height: 1.6;
    font-size: 14px;
}

/* Similar Products */
.similar-products {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 16px;
}

.similar-products h2 {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 16px;
}

.similar-products-slider {
    overflow: hidden;
}

.similar-products-slider .swiper-pagination {
    bottom: 0 !important;
    position: relative !important;
    padding-top: 10px !important;
}

.similar-products-slider .swiper-pagination-bullet {
    background: var(--primary-color) !important;
}

.product-card {
    display: block;
    text-decoration: none;
    color: inherit;
    border: 1px solid #eee;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.2s ease;
    height: 100%;
}

.product-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.product-image {
    aspect-ratio: 16/9;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-info {
    padding: 12px;
}

.product-price {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
}

.product-title {
    font-size: 14px;
    color: #444;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-location {
    font-size: 12px;
    color: #666;
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.product-location i {
    color: var(--primary-color);
    font-size: 12px;
}

.product-date {
    font-size: 12px;
    color: #666;
}

/* Swiper Navigation */
.swiper-button-next,
.swiper-button-prev {
    width: 48px !important;
    height: 48px !important;
    background: rgba(0, 0, 0, 0.5) !important;
    backdrop-filter: blur(4px) !important;
    border-radius: 50% !important;
    transition: all 0.3s ease !important;
}

.swiper-button-next:hover,
.swiper-button-prev:hover {
    background: rgba(0, 0, 0, 0.7) !important;
}

.swiper-button-next:after,
.swiper-button-prev:after {
    font-size: 18px !important;
    color: #fff !important;
    font-weight: bold !important;
}

.swiper-button-next {
    right: 16px;
}

.swiper-button-prev {
    left: 16px;
}

.swiper-pagination-bullet {
    width: 6px;
    height: 6px;
    background: rgba(255, 255, 255, 0.5);
}

.swiper-pagination-bullet-active {
    background: #fff;
}

/* Main Content Layout */
.main-content {
    background: #f8f9fa;
    min-height: calc(100vh - 60px);
    padding: 24px 0;
}

/* Responsive Design */
@media (max-width: 992px) {
    .gallery-main {
        height: 300px;
    }

    .specs-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {

    .product-gallery,
    .product-header,
    .seller-card,
    .product-specs,
    .product-description,
    .similar-products,
    .safety-tips {
        padding: 12px;
        margin-bottom: 16px;
        border-radius: 8px;
    }

    .gallery-main {
        height: 250px;
    }

    .price {
        font-size: 24px;
    }

    .price-section {
        justify-content: space-between;
        flex-direction: column;
    }

    .price-meta {
        align-items: flex-start;
        gap: 8px;
    }

    .gallery-thumb {
        flex: 0 0 60px;
        height: 60px;
    }

    

    .product-header {
        flex-direction: column;
        gap: 16px;
    }

    .action-buttons {
        width: 100%;
        justify-content: flex-end;
    }

    .seller-actions {
        flex-direction: row;
        flex-wrap: wrap;
    }

    .seller-actions button {
        flex: 1;
        min-width: 120px;
    }

    .swiper-button-next,
    .swiper-button-prev {
        width: 36px;
        height: 36px;
    }

    .swiper-button-next:after,
    .swiper-button-prev:after {
        font-size: 14px;
    }
}

/* Fancybox Customization */
.fancybox__toolbar {
    --f-button-width: 40px;
    --f-button-height: 40px;
    --f-button-border-radius: 8px;
}

.fancybox__toolbar__items {
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    border-radius: 12px;
    padding: 4px;
}

.fancybox__toolbar__items button {
    color: #fff !important;
}

.fancybox__toolbar__items button:hover {
    background-color: rgba(255, 255, 255, 0.1) !important;
}

.fancybox__backdrop {
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(8px);
}