/* ===== PRODUCT PAGE CSS — MOBILE FIXED ===== */

* { box-sizing: border-box; }

.flipkart-product {
    max-width: 1450px;
    margin: 40px auto;
    display: grid;
    grid-template-columns: 48% 52%;
    gap: 40px;
    padding: 0 25px;
}

.left-side {
    position: sticky;
    top: 30px;
}

.product-image-box {
    background: #fff;
    padding: 30px;
    border-radius: 18px;
    position: relative;
}

.main-product-image {
    width: 100%;
    height: 720px;
    object-fit: contain;
}

.other-images {
    position: absolute;
    left: -110px;
    top: 120px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.small-image {
    width: 90px;
    height: 90px;
    padding: 8px;
    background: #fff;
    border-radius: 18px;
    border: 1px solid #eee;
    object-fit: contain;
    cursor: pointer;
}

.small-image:hover {
    border: 2px solid #2563eb;
}

.right-side {
    background: #fff;
    padding: 45px;
}

.product-title {
    font-size: 48px;
    font-weight: 800;
    line-height: 60px;
    color: #111827;
    margin-bottom: 20px;
}

.rating-box {
    display: inline-block;
    background: #22c55e;
    color: #fff;
    padding: 8px 16px;
    border-radius: 10px;
    margin-bottom: 20px;
}

.price {
    font-size: 56px;
    font-weight: 800;
    color: #2563eb;
    margin: 20px 0;
}

.offer-box {
    background: #eef4ff;
    padding: 24px;
    border-radius: 14px;
    margin-top: 30px;
    margin-bottom: 25px;
}

.offer-box p {
    margin: 12px 0;
}

.button-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin-top: 30px;
}

.cart-btn {
    height: 58px;
    background: #2563eb;
    color: #fff;
    border: none;
    border-radius: 10px;
    font-weight: 700;
    cursor: pointer;
    font-size: 16px;
}

.buy-btn {
    height: 58px;
    background: #000;
    color: #fff;
    border: none;
    border-radius: 10px;
    font-weight: 700;
    cursor: pointer;
    font-size: 16px;
}

.spec-box,
.description-box {
    background: #fff;
    padding: 30px;
    border: 1px solid #eee;
    border-radius: 16px;
    margin-top: 20px;
    line-height: 34px;
}

.section-title {
    font-size: 30px;
    font-weight: 800;
    margin-top: 50px;
    margin-bottom: 20px;
}

.related-products {
    padding: 80px 0;
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
}

.related-card {
    background: #fff;
    border-radius: 16px;
    padding: 20px;
    transition: .3s;
    text-decoration: none;
    color: #111;
    display: block;
}

.related-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 6px 20px rgba(0,0,0,.1);
}

.related-card img {
    height: 220px;
    width: 100%;
    object-fit: contain;
}

/* =========================
TABLET
========================= */
@media (max-width: 1200px) {
    .other-images {
        left: -80px;
    }
    .related-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* =========================
MOBILE
========================= */
@media (max-width: 768px) {

    .flipkart-product {
        grid-template-columns: 1fr;
        gap: 0;
        margin: 0;
        padding: 0;
    }

    .left-side {
        position: static;
    }

    .product-image-box {
        padding: 15px;
        border-radius: 0;
        border-bottom: 1px solid #eee;
    }

    .main-product-image {
        height: 280px;
    }

    .other-images {
        position: relative;
        left: 0;
        top: 0;
        flex-direction: row;
        margin-top: 12px;
        gap: 10px;
        overflow-x: auto;
        scrollbar-width: none;
    }

    .other-images::-webkit-scrollbar { display: none; }

    .small-image {
        width: 65px;
        height: 65px;
        flex-shrink: 0;
        border-radius: 10px;
    }

    .right-side {
        padding: 16px;
        border-radius: 0;
    }

    .product-title {
        font-size: 18px;
        line-height: 26px;
        margin-bottom: 12px;
    }

    .price {
        font-size: 28px;
        margin: 12px 0;
    }

    .offer-box {
        padding: 14px;
        margin-top: 14px;
        margin-bottom: 14px;
        border-radius: 10px;
    }

    .offer-box p {
        font-size: 13px;
        margin: 8px 0;
    }

    .button-group {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
        margin-top: 16px;
    }

    .cart-btn,
    .buy-btn {
        height: 46px;
        font-size: 14px;
        border-radius: 8px;
    }

    .spec-box,
    .description-box {
        padding: 16px;
        margin-top: 12px;
        line-height: 26px;
        font-size: 13px;
    }

    .section-title {
        font-size: 18px;
        margin-top: 20px;
        margin-bottom: 12px;
    }

    .related-products {
        padding: 20px 10px;
    }

    .related-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .related-card {
        padding: 12px 8px;
        border-radius: 12px;
    }

    .related-card img {
        height: 130px;
    }
}

/* =========================
BEST SELLING — MOBILE FIX
========================= */
@media (max-width: 768px) {
    .best-selling-section {
        padding: 20px 10px;
        overflow: hidden;
    }

    .best-selling-products {
        display: flex !important;
        flex-direction: row !important;
        overflow-x: auto !important;
        overflow-y: hidden !important;
        gap: 10px !important;
        padding-bottom: 10px !important;
        scroll-snap-type: x mandatory !important;
        -webkit-overflow-scrolling: touch !important;
        scrollbar-width: none !important;
        width: 100% !important;
        max-width: 100% !important;
    }

    .best-selling-products::-webkit-scrollbar { display: none; }

    .best-card {
        min-width: 140px !important;
        max-width: 140px !important;
        flex-shrink: 0 !important;
        scroll-snap-align: start !important;
    }
}
/* ================================
   MOBILE FIXED BOTTOM BUTTONS
================================ */

/* Image panel ke andar ke action buttons mobile par hide karo */
@media(max-width:768px){
    .action-btns {
        display: none;
    }
}

/* Fixed bottom bar sirf mobile par dikhega */
.mobile-bottom-bar {
    display: none;
}

@media(max-width:768px){
    .mobile-bottom-bar {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        z-index: 999;
        background: #fff;
        padding: 10px 12px;
        gap: 10px;
        box-shadow: 0 -2px 10px rgba(0,0,0,0.15);
    }

    .mobile-bottom-bar a {
        flex: 1;
        text-decoration: none;
    }

    .mobile-bottom-bar .btn-cart-mob {
        width: 100%;
        padding: 14px;
        border: none;
        border-radius: 24px;
        font-size: 15px;
        font-weight: 700;
        cursor: pointer;
        background: #ffa41c;
        color: #111;
    }

    .mobile-bottom-bar .btn-buy-mob {
        width: 100%;
        padding: 14px;
        border: none;
        border-radius: 24px;
        font-size: 15px;
        font-weight: 700;
        cursor: pointer;
        background: #ff9500;
        color: #111;
    }

    /* Bottom bar ki height ke liye page ke neeche space */
    .product-page {
        padding-bottom: 80px !important;
    }
}