/* ========================================
   Product Page Styles
   ======================================== */

.product-main {
    padding-top: 130px;
    padding-bottom: 80px;
}

/* Product Layout */
.product-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    margin-bottom: 80px;
}

/* Product Gallery */
.product-gallery {
    position: sticky;
    top: 130px;
    height: fit-content;
}

.product-main-image {
    position: relative;
    aspect-ratio: 4/3;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    overflow: hidden;
    margin-bottom: 16px;
    cursor: zoom-in;
}

.product-main-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-normal);
}

.product-main-image:hover img {
    transform: scale(1.05);
}

.product-main-image .placeholder-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: var(--text-muted);
}

.product-main-image .placeholder-text .sigma {
    font-size: 4rem;
    color: var(--primary);
    display: block;
    margin-bottom: 12px;
}

.product-watermark {
    position: absolute;
    bottom: 12px;
    left: 12px;
    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 6px;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.product-thumbnails {
    display: flex;
    gap: 12px;
}

.product-thumbnail {
    width: 80px;
    height: 60px;
    background: var(--bg-card);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: border-color var(--transition-fast);
}

.product-thumbnail:hover,
.product-thumbnail.active {
    border-color: var(--primary);
}

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

/* Product Details */
.product-details {
    padding-top: 20px;
}

.product-details .breadcrumbs {
    margin-bottom: 20px;
}

.product-title-main {
    font-size: 2rem;
    margin-bottom: 8px;
}

.product-subtitle-main {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 20px;
}

.product-rating-row {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
}

.product-rating-row .rating {
    display: flex;
    align-items: center;
    gap: 4px;
}

.product-rating-row .star {
    color: #ffc107;
    font-size: 1.25rem;
}

.product-rating-row .rating-text {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.product-rating-row .rating-link {
    color: var(--primary);
    text-decoration: underline;
}

/* Product Price */
.product-price-main {
    display: flex;
    align-items: baseline;
    gap: 16px;
    margin-bottom: 32px;
}

.product-price-main .price-original {
    font-size: 1.5rem;
    color: var(--text-dim);
    text-decoration: line-through;
}

.product-price-main .price {
    font-family: var(--font-mono);
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary);
}

.product-price-main .discount-badge {
    background: var(--sale);
    color: white;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 600;
}

/* What's Included */
.product-includes {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
}

.product-includes h3 {
    font-size: 1rem;
    margin-bottom: 16px;
    color: var(--text-white);
}

.product-includes ul {
    list-style: none;
}

.product-includes li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 8px 0;
    color: var(--text-light);
    font-size: 0.95rem;
}

.product-includes li svg {
    width: 20px;
    height: 20px;
    color: var(--success);
    flex-shrink: 0;
    margin-top: 2px;
}

/* Product Specs */
.product-specs {
    margin-bottom: 32px;
}

.product-specs h3 {
    font-size: 1rem;
    margin-bottom: 16px;
    color: var(--text-white);
}

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

.spec-item {
    display: flex;
    justify-content: space-between;
    padding: 12px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 8px;
}

.spec-item .spec-label {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.spec-item .spec-value {
    color: var(--text-white);
    font-weight: 600;
    font-size: 0.9rem;
}

/* Product Actions */
.product-actions {
    display: flex;
    gap: 16px;
    margin-bottom: 32px;
}

.product-actions .btn {
    flex: 1;
    padding: 18px 24px;
    font-size: 1.1rem;
}

/* Upsell Box */
.product-upsell {
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.1), transparent);
    border: 1px solid var(--primary);
    border-radius: 12px;
    padding: 24px;
    text-align: center;
}

.product-upsell p {
    margin-bottom: 16px;
    color: var(--text-light);
}

.product-upsell strong {
    color: var(--primary);
}

/* Related Products */
.related-products {
    margin-top: 80px;
}

.related-products h2 {
    font-size: 1.5rem;
    margin-bottom: 32px;
}


    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 16px !important;
    width: 100% !important;
}


    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 16px !important;
}


    min-width: 0 !important;
}




    display: block !important;
    max-width: 100% !important;
    width: 100% !important;
    min-width: 0 !important;
}


    aspect-ratio: 4/3;
    height: auto;
}


    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 0.85rem;
    font-weight: 600;
    line-height: 1.3;
    max-height: 2.6em;
}


    padding: 12px;
}


    flex-wrap: wrap;
    gap: 8px;
}

/* Product FAQ */
.product-faq {
    margin-top: 80px;
    max-width: 800px;
}

.product-faq h2 {
    font-size: 1.5rem;
    margin-bottom: 32px;
}

.product-faq .faq-grid {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.product-faq .faq-item {
    border-bottom: 1px solid var(--border-color);
}

.product-faq .faq-question {
    width: 100%;
    padding: 20px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    background: none;
    border: none;
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-light);
    cursor: pointer;
    text-align: left;
    transition: color 0.2s ease;
}

.product-faq .faq-question:hover {
    color: var(--primary);
}

.product-faq .faq-question svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    transition: transform 0.3s ease;
}

.product-faq .faq-item.active .faq-question svg {
    transform: rotate(180deg);
}

.product-faq .faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.product-faq .faq-item.active .faq-answer {
    max-height: 300px;
}

.product-faq .faq-answer p {
    padding-bottom: 20px;
    color: var(--text-muted);
    line-height: 1.7;
    font-size: 0.95rem;
}

.product-faq .faq-answer ul {
    padding-bottom: 20px;
    padding-left: 1.5rem;
    color: var(--text-muted);
    line-height: 1.7;
}

/* Lightbox */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-normal);
}

.lightbox.active {
    opacity: 1;
    visibility: visible;
}

.lightbox-content {
    max-width: 90vw;
    max-height: 90vh;
}

.lightbox-content img {
    max-width: 100%;
    max-height: 90vh;
    border-radius: 8px;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 50%;
    color: var(--text-light);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.lightbox-close:hover {
    background: var(--primary);
    color: var(--bg-dark);
}

/* Responsive */
@media (max-width: 1200px) {

        grid-template-columns: repeat(4, 1fr) !important;
        gap: 12px !important;
    }
}

@media (max-width: 992px) {
    .product-layout {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .product-gallery {
        position: static;
    }


        grid-template-columns: repeat(4, 1fr) !important;
        gap: 10px !important;
    }


        font-size: 0.75rem;
    }


        padding: 8px;
    }
}

@media (max-width: 768px) {
    .product-main {
        padding-top: 110px;
    }

    .product-title-main {
        font-size: 1.5rem;
    }

    .product-price-main .price {
        font-size: 2rem;
    }

    .product-actions {
        flex-direction: column;
    }

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


        grid-template-columns: repeat(2, 1fr) !important;
        gap: 12px !important;
    }
}
/* Related Products - Complete Rewrite */
.related-products {
    margin-top: 80px;
    overflow: hidden;
}

.related-products h2 {
    font-size: 1.5rem;
    margin-bottom: 32px;
}

#relatedProducts,
.related-grid {
    display: flex !important;
    flex-wrap: nowrap !important;
    gap: 16px !important;
    width: 100% !important;
    overflow-x: auto;
}

#relatedProducts > *,
.related-grid > * {
    flex: 0 0 calc(25% - 12px) !important;
    max-width: calc(25% - 12px) !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
}

#relatedProducts .product-card,
.related-grid .product-card {
    display: flex !important;
    flex-direction: column !important;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
}

#relatedProducts .product-image,
.related-grid .product-image {
    aspect-ratio: 4/3;
    width: 100%;
    overflow: hidden;
    background: var(--bg-dark);
}

#relatedProducts .product-image img,
.related-grid .product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

#relatedProducts .product-info,
.related-grid .product-info {
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

#relatedProducts .product-category,
.related-grid .product-category {
    font-size: 0.65rem;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

#relatedProducts .product-title,
.related-grid .product-title {
    font-size: 0.8rem !important;
    font-weight: 600;
    line-height: 1.2 !important;
    margin: 0 !important;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    max-height: 2.4em;
    color: var(--text-white);
}

#relatedProducts .product-meta,
.related-grid .product-meta {
    font-size: 0.7rem;
    color: var(--text-muted);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#relatedProducts .product-footer,
.related-grid .product-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    margin-top: auto;
}

#relatedProducts .product-price .price,
.related-grid .product-price .price {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--primary);
}

#relatedProducts .btn-sm,
.related-grid .btn-sm {
    padding: 6px 10px;
    font-size: 0.7rem;
}

/* Mobile: 2 columns */
@media (max-width: 768px) {
    #relatedProducts > *,
    .related-grid > * {
        flex: 0 0 calc(50% - 8px) !important;
        max-width: calc(50% - 8px) !important;
    }
}
/* Related Products - Complete Rewrite */
.related-products {
    margin-top: 80px;
    overflow: hidden;
}

.related-products h2 {
    font-size: 1.5rem;
    margin-bottom: 32px;
}

#relatedProducts,
.related-grid {
    display: flex !important;
    flex-wrap: nowrap !important;
    gap: 16px !important;
    width: 100% !important;
    overflow-x: auto;
}

#relatedProducts > *,
.related-grid > * {
    flex: 0 0 calc(25% - 12px) !important;
    max-width: calc(25% - 12px) !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
}

#relatedProducts .product-card,
.related-grid .product-card {
    display: flex !important;
    flex-direction: column !important;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
}

#relatedProducts .product-image,
.related-grid .product-image {
    aspect-ratio: 4/3;
    width: 100%;
    overflow: hidden;
    background: var(--bg-dark);
}

#relatedProducts .product-image img,
.related-grid .product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

#relatedProducts .product-info,
.related-grid .product-info {
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

#relatedProducts .product-category,
.related-grid .product-category {
    font-size: 0.65rem;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

#relatedProducts .product-title,
.related-grid .product-title {
    font-size: 0.8rem !important;
    font-weight: 600;
    line-height: 1.2 !important;
    margin: 0 !important;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    max-height: 2.4em;
    color: var(--text-white);
}

#relatedProducts .product-meta,
.related-grid .product-meta {
    font-size: 0.7rem;
    color: var(--text-muted);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#relatedProducts .product-footer,
.related-grid .product-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    margin-top: auto;
}

#relatedProducts .product-price .price,
.related-grid .product-price .price {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--primary);
}

#relatedProducts .btn-sm,
.related-grid .btn-sm {
    padding: 6px 10px;
    font-size: 0.7rem;
}

/* Mobile: 2 columns */
@media (max-width: 768px) {
    #relatedProducts > *,
    .related-grid > * {
        flex: 0 0 calc(50% - 8px) !important;
        max-width: calc(50% - 8px) !important;
    }
}
