/**
 * Single Product Page Styles - Responsive Version
 * ToyParadis Theme - WooCommerce Product Details
 * 
 * @package ToyParadis
 * @since 1.5.4
 * 
 * Breakpoints:
 * - Mobile: < 576px
 * - Tablet: 576px - 991px
 * - Desktop: > 991px
 */

/* ========================================
   1. Container & Layout
   ======================================== */

.product-detail-page {
    padding: 30px 15px;
    max-width: 1400px;
    margin: 0 auto;
    background: #f8f9fa;
}

.product-detail-container {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

/* Product Main Content - Responsive Grid */
.product-main-content {
    display: grid;
    grid-template-columns: 45% 55%;
    gap: 50px;
    padding: 50px;
    align-items: start;
}

/* ========================================
   2. Product Gallery
   ======================================== */

.product-gallery-wrapper {
    position: relative;
    width: 100%;
    background: #fff;
}

.woocommerce-product-gallery {
    position: relative;
    margin: 0;
}

.woocommerce-product-gallery__wrapper {
    margin: 0;
    padding: 0;
}

.woocommerce-product-gallery__image {
    width: 100%;
    margin: 0 0 15px 0;
    position: relative;
}

.woocommerce-product-gallery__image img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    border: 1px solid #e8e8e8;
    transition: transform 0.3s ease;
    display: block;
}

.woocommerce-product-gallery__image:hover img {
    transform: scale(1.02);
}

/* Zoom Trigger */
.woocommerce-product-gallery__trigger {
    position: absolute;
    top: 15px;
    right: 15px;
    z-index: 10;
    width: 45px;
    height: 45px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid #ddd;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.woocommerce-product-gallery__trigger:hover {
    background: #fff;
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Sale Badge */
.onsale {
    position: absolute;
    top: 15px;
    left: 15px;
    z-index: 10;
    background: linear-gradient(135deg, #FF3E6C 0%, #E91E63 100%);
    color: #fff;
    padding: 10px 18px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 12px rgba(255, 62, 108, 0.3);
}

/* ========================================
   3. Product Summary / Info
   ======================================== */

.summary.entry-summary {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

/* Product Title */
.product_title {
    font-size: 36px;
    font-weight: 800;
    line-height: 1.2;
    margin: 0;
    color: #1a1a1a;
    letter-spacing: -0.5px;
}

/* Product Rating */
.woocommerce-product-rating {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.star-rating {
    color: #FFC107;
    font-size: 16px;
}

.woocommerce-review-link {
    color: #666;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.woocommerce-review-link:hover {
    color: #003DA5;
    text-decoration: underline;
}

/* Product Price */
.price {
    font-size: 40px;
    font-weight: 800;
    color: #003DA5;
    margin: 0;
    line-height: 1;
}

.price del {
    font-size: 28px;
    color: #999;
    margin-right: 15px;
    opacity: 0.6;
    font-weight: 400;
}

.price ins {
    text-decoration: none;
    color: #FF3E6C;
}

/* Short Description */
.woocommerce-product-details__short-description {
    font-size: 16px;
    line-height: 1.7;
    color: #555;
    margin: 0;
}

.woocommerce-product-details__short-description p {
    margin: 0 0 10px 0;
}

/* Stock Status */
.stock {
    display: inline-flex;
    align-items: center;
    padding: 10px 20px;
    border-radius: 25px;
    font-size: 15px;
    font-weight: 600;
    margin: 0;
}

.stock.in-stock {
    background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 100%);
    color: #2e7d32;
}

.stock.out-of-stock {
    background: linear-gradient(135deg, #ffebee 0%, #ffcdd2 100%);
    color: #c62828;
}

/* ========================================
   4. Add to Cart Section
   ======================================== */

.cart {
    display: flex;
    align-items: center;
    gap: 20px;
    margin: 0;
    padding: 30px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 12px;
    border: 2px solid #e0e0e0;
}

/* Quantity Selector */
.quantity {
    display: flex;
    align-items: center;
    border: 2px solid #d0d0d0;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
    height: 55px;
}

.quantity label {
    display: none;
}

.quantity input.qty {
    width: 80px;
    height: 100%;
    text-align: center;
    border: none;
    font-size: 20px;
    font-weight: 700;
    padding: 0 15px;
    color: #333;
}

.quantity input.qty:focus {
    outline: none;
}

/* Add to Cart Button */
.single_add_to_cart_button {
    flex: 1;
    min-width: 220px;
    height: 55px;
    background: linear-gradient(135deg, #00B853 0%, #00A047 100%) !important;
    color: #fff !important;
    border: none !important;
    border-radius: 28px !important;
    font-size: 18px !important;
    font-weight: 700 !important;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0 40px !important;
    box-shadow: 0 4px 15px rgba(0, 184, 83, 0.3);
}

.single_add_to_cart_button:hover {
    background: linear-gradient(135deg, #009645 0%, #008238 100%) !important;
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 184, 83, 0.4);
}

.single_add_to_cart_button:active {
    transform: translateY(-1px);
}

.single_add_to_cart_button.disabled,
.single_add_to_cart_button:disabled {
    background: #ccc !important;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none !important;
}

/* ========================================
   5. Product Variations
   ======================================== */

.variations {
    margin: 0;
    width: 100%;
}

.variations tbody {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.variations tr {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.variations label {
    font-weight: 700;
    font-size: 16px;
    color: #333;
}

.variations select {
    width: 100%;
    height: 50px;
    padding: 0 20px;
    border: 2px solid #d0d0d0;
    border-radius: 8px;
    font-size: 16px;
    background: #fff;
    cursor: pointer;
    transition: border-color 0.3s ease;
}

.variations select:focus {
    outline: none;
    border-color: #003DA5;
}

.reset_variations {
    font-size: 14px;
    color: #666;
    text-decoration: none;
    margin-top: 10px;
    display: inline-block;
}

.reset_variations:hover {
    color: #003DA5;
    text-decoration: underline;
}

/* ========================================
   6. Product Meta
   ======================================== */

.product_meta {
    font-size: 15px;
    line-height: 2;
    color: #666;
    padding: 25px 0 0;
    border-top: 2px solid #f0f0f0;
    margin: 0;
}

.product_meta > span {
    display: block;
    margin: 8px 0;
}

.product_meta a {
    color: #003DA5;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.product_meta a:hover {
    color: #0056b3;
    text-decoration: underline;
}

/* ========================================
   7. Product Tabs
   ======================================== */

.product-additional-content {
    padding: 50px;
    border-top: 2px solid #f0f0f0;
}

.woocommerce-tabs {
    margin: 0;
}

.woocommerce-tabs ul.tabs {
    list-style: none;
    padding: 0;
    margin: 0 0 40px 0;
    display: flex;
    gap: 5px;
    border-bottom: 3px solid #f0f0f0;
    flex-wrap: wrap;
}

.woocommerce-tabs ul.tabs li {
    margin: 0;
    padding: 0;
}

.woocommerce-tabs ul.tabs li a {
    display: block;
    padding: 18px 35px;
    color: #666;
    text-decoration: none;
    font-weight: 700;
    font-size: 16px;
    border-bottom: 3px solid transparent;
    transition: all 0.3s ease;
    background: transparent;
    border-radius: 8px 8px 0 0;
}

.woocommerce-tabs ul.tabs li.active a {
    color: #003DA5;
    border-bottom-color: #003DA5;
    background: #f8f9fa;
}

.woocommerce-tabs ul.tabs li a:hover {
    color: #003DA5;
    background: #f8f9fa;
}

.woocommerce-tabs .panel {
    padding: 30px 0;
    line-height: 1.8;
    color: #555;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.woocommerce-tabs .panel h2 {
    font-size: 26px;
    font-weight: 800;
    margin: 0 0 25px 0;
    color: #1a1a1a;
}

/* ========================================
   8. Reviews
   ======================================== */

#reviews .commentlist {
    list-style: none;
    padding: 0;
    margin: 30px 0;
}

#reviews .comment {
    border-bottom: 1px solid #f0f0f0;
    padding: 25px 0;
}

#reviews .comment_container {
    display: flex;
    gap: 20px;
}

#reviews .avatar {
    border-radius: 50%;
    flex-shrink: 0;
}

#reviews .comment-text {
    flex: 1;
}

#reviews .star-rating {
    margin-bottom: 12px;
}

#reviews .woocommerce-review__author {
    font-weight: 700;
    font-size: 17px;
    margin: 0 0 5px 0;
    color: #333;
}

#reviews .woocommerce-review__published-date {
    color: #999;
    font-size: 14px;
    margin-bottom: 12px;
    display: block;
}

#reviews .description {
    color: #555;
    line-height: 1.7;
}

/* ========================================
   9. Related Products
   ======================================== */

.related.products,
.upsells.products {
    margin-top: 60px;
}

.related.products h2,
.upsells.products h2 {
    font-size: 32px;
    font-weight: 800;
    margin: 0 0 35px 0;
    color: #1a1a1a;
    letter-spacing: -0.5px;
}

.related.products .products,
.upsells.products .products {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}

/* ========================================
   10. Tablet Responsive (576px - 991px)
   ======================================== */

@media (max-width: 991px) {
    .product-detail-page {
        padding: 20px 15px;
    }
    
    .product-main-content {
        grid-template-columns: 1fr;
        gap: 40px;
        padding: 40px 30px;
    }
    
    .product_title {
        font-size: 30px;
    }
    
    .price {
        font-size: 36px;
    }
    
    .product-additional-content {
        padding: 40px 30px;
    }
    
    .related.products .products,
    .upsells.products .products {
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
        gap: 25px;
    }
}

/* ========================================
   11. Mobile Responsive (< 576px)
   ======================================== */

@media (max-width: 575px) {
    .product-detail-page {
        padding: 15px 10px;
        background: #fff;
    }
    
    .product-detail-container {
        border-radius: 0;
        box-shadow: none;
    }
    
    .product-main-content {
        grid-template-columns: 1fr;
        gap: 30px;
        padding: 25px 20px;
    }
    
    /* Gallery */
    .woocommerce-product-gallery__image img {
        border-radius: 8px;
    }
    
    .woocommerce-product-gallery__trigger {
        width: 40px;
        height: 40px;
        top: 10px;
        right: 10px;
    }
    
    .onsale {
        top: 10px;
        left: 10px;
        padding: 8px 15px;
        font-size: 12px;
    }
    
    /* Product Info */
    .product_title {
        font-size: 24px;
        letter-spacing: -0.3px;
    }
    
    .price {
        font-size: 32px;
    }
    
    .price del {
        font-size: 22px;
        display: block;
        margin: 0 0 5px 0;
    }
    
    .woocommerce-product-details__short-description {
        font-size: 15px;
    }
    
    /* Cart Section */
    .cart {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
        padding: 20px;
    }
    
    .quantity {
        width: 100%;
        justify-content: center;
    }
    
    .quantity input.qty {
        width: 100px;
    }
    
    .single_add_to_cart_button {
        width: 100%;
        min-width: 0;
        font-size: 16px !important;
    }
    
    /* Variations */
    .variations select {
        height: 45px;
        font-size: 15px;
    }
    
    /* Tabs */
    .product-additional-content {
        padding: 30px 20px;
    }
    
    .woocommerce-tabs ul.tabs {
        flex-direction: column;
        border-bottom: none;
        gap: 0;
        margin-bottom: 30px;
    }
    
    .woocommerce-tabs ul.tabs li {
        width: 100%;
    }
    
    .woocommerce-tabs ul.tabs li a {
        padding: 15px 20px;
        border-bottom: 1px solid #e0e0e0;
        border-left: 4px solid transparent;
        border-radius: 0;
    }
    
    .woocommerce-tabs ul.tabs li.active a {
        border-left-color: #003DA5;
        border-bottom-color: #e0e0e0;
        background: #f8f9fa;
    }
    
    .woocommerce-tabs .panel {
        padding: 20px 0;
    }
    
    .woocommerce-tabs .panel h2 {
        font-size: 22px;
    }
    
    /* Reviews */
    #reviews .comment_container {
        flex-direction: column;
        gap: 15px;
    }
    
    #reviews .avatar {
        width: 50px;
        height: 50px;
    }
    
    /* Related Products */
    .related.products,
    .upsells.products {
        margin-top: 40px;
    }
    
    .related.products h2,
    .upsells.products h2 {
        font-size: 24px;
        margin-bottom: 25px;
    }
    
    .related.products .products,
    .upsells.products .products {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
}

/* ========================================
   12. Extra Small Mobile (< 375px)
   ======================================== */

@media (max-width: 374px) {
    .product_title {
        font-size: 20px;
    }
    
    .price {
        font-size: 28px;
    }
    
    .related.products .products,
    .upsells.products .products {
        grid-template-columns: 1fr;
    }
    
    .woocommerce-tabs ul.tabs li a {
        padding: 12px 15px;
        font-size: 15px;
    }
}

/* ========================================
   13. Large Desktop (> 1400px)
   ======================================== */

@media (min-width: 1400px) {
    .product-detail-page {
        padding: 50px 30px;
    }
    
    .product-main-content {
        padding: 60px;
        gap: 70px;
    }
    
    .product_title {
        font-size: 40px;
    }
    
    .price {
        font-size: 44px;
    }
}
