/* Waziha Shop — refreshed storefront theme (loaded after main.css).
   Colors follow the admin "store theme color" (--primary-color). */
:root {
    --wz-primary: var(--primary-color, #57005F);
    --wz-accent: #FF6500;
    --wz-price: #c24d00;
    --wz-ink: #1f1023;
    --wz-muted: #5b4a60;
    --wz-line: #ece4ee;
    --wz-soft: color-mix(in srgb, var(--wz-primary) 8%, #fff);
    --wz-radius: 16px;
}

/* ---------- Product cards on every listing page ---------- */
.main_product_inner {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}
@media (min-width: 768px) { .main_product_inner { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 992px) { .main_product_inner { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 1200px) { .main_product_inner { grid-template-columns: repeat(5, minmax(0, 1fr)); } }

.main_product_inner .product_item,
.product_slider .product_item {
    width: auto !important;
    margin: 0 !important;
    float: none !important;
    border: 1px solid var(--wz-line);
    border-radius: var(--wz-radius);
    overflow: hidden;
    background: #fff;
    display: flex;
    flex-direction: column;
    position: relative;
    box-shadow: none;
    transition: box-shadow .2s, transform .2s;
}
.main_product_inner .product_item:hover { box-shadow: 0 8px 24px rgba(40, 10, 50, .08); transform: translateY(-2px); }
.main_product_inner .product_item_inner { flex: 1; display: flex; flex-direction: column; border: 0 !important; }
.main_product_inner .pro_img img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; display: block; background: #f7f2f9; }
.main_product_inner .pro_des { padding: 10px 10px 4px; text-align: left; }
.main_product_inner .pro_name a {
    font-size: 14px; font-weight: 600; line-height: 1.35; color: var(--wz-ink);
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 38px; height: auto;
}
.main_product_inner .pro_price p { margin: 6px 0 0; font-size: 17px; font-weight: 700; color: var(--wz-price); }
.main_product_inner .pro_price del { font-size: 13px; color: #6e5f72; font-weight: 500; margin-right: 4px; }
.main_product_inner .pro_btn { padding: 8px 10px 10px; position: static !important; opacity: 1 !important; visibility: visible !important; }
.main_product_inner .pro_btn form { margin: 0; }
.main_product_inner .pro_btn button,
.main_product_inner .pro_btn .wz-card-choose,
.wzh-grid .pro_btn .wz-card-choose {
    display: flex; align-items: center; justify-content: center; width: 100%; height: 40px;
    border: 0; border-radius: 10px; background: var(--wz-primary); color: #fff; font-size: 15px; font-weight: 700; text-decoration: none;
}
.main_product_inner .sale-badge { position: absolute; top: 8px; left: 8px; z-index: 2; }
.custom_paginate { display: flex; justify-content: center; margin: 20px 0; }
.custom_paginate .page-link { border-radius: 10px !important; margin: 0 3px; color: var(--wz-primary); }
.custom_paginate .page-item.active .page-link { background: var(--wz-primary); border-color: var(--wz-primary); color: #fff; }

/* ---------- Header polish ---------- */
.main-header input[type="search"], .main-header input[type="text"],
.mobile-header input[type="search"], .mobile-header input[type="text"] { border-radius: 12px; }

/* ---------- Product details ---------- */
.main-details-page .details-price { font-size: 26px !important; font-weight: 800; color: var(--wz-price) !important; margin-bottom: 6px; }
.main-details-page .details-price del { font-size: 16px; color: #6e5f72; font-weight: 500; margin-left: 8px; }
.main-details-page .product-cart .name { font-size: 21px; font-weight: 700; line-height: 1.35; color: var(--wz-ink); }
.wz-save { display: inline-block; background: var(--wz-soft); color: var(--wz-primary); font-weight: 700; font-size: 14px; padding: 3px 10px; border-radius: 8px; margin-bottom: 12px; }
.wz-trust { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 4px 0 14px; }
.wz-trust > div { display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center; padding: 10px 6px; border-radius: 12px; background: var(--wz-soft); font-size: 12.5px; font-weight: 600; line-height: 1.3; color: var(--wz-ink); }
.wz-trust svg { color: var(--wz-primary); }
.main-details-page .order_now_btn { background: var(--wz-primary) !important; border-color: var(--wz-primary) !important; border-radius: 14px !important; height: 54px; font-size: 19px !important; font-weight: 700; }
.wz-delivery { border: 1px solid var(--wz-line); border-radius: 14px; padding: 12px 14px; margin: 10px 0 16px; display: flex; flex-direction: column; gap: 8px; }
.wz-delivery-title { font-weight: 700; font-size: 16px; }
.wz-delivery-row { display: flex; justify-content: space-between; font-size: 15px; }
.wz-delivery-note { font-size: 13px; color: var(--wz-muted); }
.details_slider .dimage_item img { border-radius: var(--wz-radius); }
.description-nav-wrapper .nav-tabs .tab-link.active { color: var(--wz-primary); border-bottom: 2px solid var(--wz-primary); }

/* Mobile sticky order bar */
.wz-sticky { display: none; }
@media (max-width: 767.98px) {
    .wz-sticky {
        display: flex; gap: 10px; align-items: center; position: fixed; left: 0; right: 0; bottom: 0; z-index: 1030;
        padding: 10px 14px calc(10px + env(safe-area-inset-bottom)); background: #fff;
        border-top: 1px solid var(--wz-line); box-shadow: 0 -6px 20px rgba(40, 10, 50, .08);
    }
    body:has(.wz-sticky) { padding-bottom: 78px; }
    body:has(.wz-sticky) .scrolltop { bottom: 90px; }
    .wz-sticky-icon { width: 52px; height: 52px; flex-shrink: 0; border-radius: 14px; display: inline-flex; align-items: center; justify-content: center; }
    .wz-sticky-icon.is-wa { background: #e8f6ee; color: #0e7a3e; }
    .wz-sticky-icon.is-call { background: #fff0e6; color: #c24d00; }
    .wz-sticky-order { flex: 1; height: 52px; border: 0; border-radius: 14px; background: var(--wz-primary); color: #fff; font-size: 17px; font-weight: 700; }
}

/* ---------- Footer ---------- */
.wz-footer { background: #2b0030; color: #eadcef; padding: 32px 0 0; margin-top: 28px; }
.wz-footer a { color: #fff; text-decoration: none; }
.wz-footer a:hover { color: #ffd2b8; }
.wz-footer-grid { display: grid; grid-template-columns: 1fr; gap: 24px; }
@media (min-width: 768px) { .wz-footer-grid { grid-template-columns: 1.4fr 1fr 1fr 1fr; } }
.wz-footer-logo img { max-height: 44px; width: auto; }
.wz-footer-tag { margin: 10px 0 8px; font-size: 15px; color: #fff; }
.wz-footer-trust { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 4px; font-size: 13.5px; }
.wz-footer-trust li::before { content: "✓ "; color: #ffb38a; font-weight: 700; }
.wz-footer-title { font-size: 16px; font-weight: 700; color: #fff; margin: 0 0 10px; }
.wz-footer-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; font-size: 14.5px; }
.wz-footer-phone { font-size: 18px; font-weight: 700; }
.wz-footer-social { list-style: none; padding: 0; margin: 0; display: flex; gap: 10px; flex-wrap: wrap; }
.wz-footer-social a { width: 42px; height: 42px; border-radius: 12px; background: rgba(255, 255, 255, .1); display: inline-flex; align-items: center; justify-content: center; font-size: 18px; }
.wz-footer-bottom { border-top: 1px solid rgba(255, 255, 255, .12); margin-top: 26px; padding: 14px 0 18px; font-size: 13px; }
.wz-footer-bottom .container { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px; }
.wz-footer-bottom p { margin: 0; }
.wz-footer-credit { color: #bfa9c7; }
.wz-footer-credit a { color: #bfa9c7; }
.main-details-page .details_right a.btn{border-radius:14px;padding:12px 0 !important;font-weight:600}

/* Order success: keep the admin "success page text" readable and in brand style */
.wzs-custom, .wzs-custom * { font-size: 14.5px !important; line-height: 1.55 !important; color: #5b4a60 !important; font-weight: 500 !important; margin: 2px 0 !important; text-align: center; }
.wzs-check svg { width: 44px !important; height: 44px !important; }
.wz-footer-bottom p, .wz-footer-bottom p * { color: #d9c8e0 !important; }

/* Compact product card: name and price sit together, button stays at the bottom */
.main_product_inner .product_item, .wzh-grid .product_item { padding: 0 !important; }
.main_product_inner .product_item_inner, .wzh-grid .product_item_inner { display: flex; flex-direction: column; flex: 1; }
.main_product_inner .pro_des, .wzh-grid .pro_des { flex: 1; padding: 10px 10px 0 !important; text-align: center; }
.main_product_inner .pro_name, .wzh-grid .pro_name { padding: 0 !important; margin: 0 !important; height: auto !important; min-height: 0 !important; }
.main_product_inner .pro_name a, .wzh-grid .pro_name a { min-height: 0 !important; height: auto !important; margin: 0 !important; line-height: 1.35 !important; }
.main_product_inner .pro_price, .wzh-grid .pro_price { margin: 6px 0 0 !important; padding: 0 !important; height: auto !important; }
.main_product_inner .pro_price p, .wzh-grid .pro_price p { margin: 0 !important; line-height: 1.3 !important; }
.main_product_inner .pro_btn, .wzh-grid .pro_btn { padding: 10px !important; margin-top: auto; }

/* Mobile header: small search icon beside the cart; search box opens on tap */
@media (max-width: 991.98px) {
    .wz-mbag { display: flex !important; align-items: center; gap: 6px; }
    .wz-msearch-btn { width: 40px; height: 40px; border: 0; border-radius: 12px; background: var(--wz-soft); color: var(--wz-primary); display: inline-flex; align-items: center; justify-content: center; padding: 0; }
    .wz-msearch { display: none !important; }
    .wz-msearch.is-open { display: block !important; }
}

/* Show the whole product photo (no cropping) */
.main_product_inner .pro_img, .wzh-grid .pro_img, .product_slider .pro_img { background: #fff; }
.main_product_inner .pro_img img, .wzh-grid .pro_img img, .product_slider .pro_img img {
    width: 100% !important; height: auto !important; aspect-ratio: 1 / 1; object-fit: contain !important; background: #fff !important;
}
/* Home banner: full image, natural height */
.wzh-hero img { aspect-ratio: auto !important; height: auto !important; object-fit: contain !important; }

/* ---------- Category bar: single scrollable row of chips + "সব ক্যাটাগরি" mega menu ---------- */
.wz-catnav { background: #fff; border-bottom: 1px solid var(--wz-line); box-shadow: 0 2px 10px rgba(40, 10, 50, .04); }
.wz-catnav-inner { display: flex; align-items: center; gap: 12px; padding-top: 8px; padding-bottom: 8px; }
.wz-allcat { position: relative; flex-shrink: 0; }
.wz-allcat-btn { display: inline-flex; align-items: center; gap: 8px; height: 42px; padding: 0 16px; border: 0; border-radius: 12px; background: var(--wz-primary); color: #fff; font-weight: 700; font-size: 15px; white-space: nowrap; }
.wz-allcat-panel { display: none; position: absolute; top: calc(100% + 8px); left: 0; z-index: 1050; width: min(880px, 92vw); max-height: 70vh; overflow: auto; background: #fff; border: 1px solid var(--wz-line); border-radius: 16px; box-shadow: 0 18px 50px rgba(40, 10, 50, .14); padding: 18px; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 14px 18px; }
.wz-allcat.is-open .wz-allcat-panel { display: grid; }
.wz-allcat-col { display: flex; flex-direction: column; gap: 4px; }
.wz-allcat-head { font-weight: 700; color: var(--wz-ink); font-size: 15px; padding: 4px 0; text-decoration: none; }
.wz-allcat-head:hover, .wz-allcat-sub:hover { color: var(--wz-primary); }
.wz-allcat-sub { color: var(--wz-muted); font-size: 14px; text-decoration: none; padding: 2px 0; }
.wz-chips-wrap { position: relative; flex: 1; min-width: 0; }
.wz-chips { list-style: none; margin: 0; padding: 2px; display: flex; gap: 8px; overflow-x: auto; scroll-behavior: smooth; scrollbar-width: none; }
.wz-chips::-webkit-scrollbar { display: none; }
.wz-chip { display: inline-flex; align-items: center; gap: 8px; height: 42px; padding: 0 14px 0 5px; border: 1.5px solid var(--wz-line); border-radius: 999px; background: #fff; color: var(--wz-ink); font-size: 14.5px; font-weight: 600; white-space: nowrap; text-decoration: none; transition: border-color .15s, background .15s, color .15s; }
.wz-chip:hover { border-color: var(--wz-primary); color: var(--wz-primary); }
.wz-chip.is-active { background: var(--wz-primary); border-color: var(--wz-primary); color: #fff; }
.wz-chip-img { width: 32px; height: 32px; border-radius: 50%; overflow: hidden; background: var(--wz-soft); flex-shrink: 0; }
.wz-chip-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.wz-chips-arrow { position: absolute; top: 50%; transform: translateY(-50%); z-index: 2; width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--wz-line); background: #fff; color: var(--wz-primary); font-size: 22px; line-height: 1; display: none; align-items: center; justify-content: center; box-shadow: 0 4px 12px rgba(40, 10, 50, .12); }
.wz-chips-arrow.is-left { left: -4px; }
.wz-chips-arrow.is-right { right: -4px; }
.wz-chips-wrap.can-left .is-left, .wz-chips-wrap.can-right .is-right { display: inline-flex; }
.wz-chips-wrap.can-left::before, .wz-chips-wrap.can-right::after { content: ""; position: absolute; top: 0; bottom: 0; width: 40px; pointer-events: none; z-index: 1; }
.wz-chips-wrap.can-left::before { left: 0; background: linear-gradient(90deg, #fff, rgba(255,255,255,0)); }
.wz-chips-wrap.can-right::after { right: 0; background: linear-gradient(270deg, #fff, rgba(255,255,255,0)); }
@media (max-width: 991.98px) { .wz-catnav { display: none; } }

.wz-footer-logo { display: inline-block; background: #fff; border-radius: 12px; padding: 6px 12px; }

/* Desktop already has the category bar in the header; show the home category row only on mobile */
@media (min-width: 992px) { .wzh-cats-section { display: none !important; } }

/* ---------- Card image: always show the full square image (no bottom crop) ---------- */
.pro_img { height: auto !important; max-height: none !important; min-height: 0 !important; }
.pro_img > a { display: block; height: auto !important; }
.main_product_inner .pro_img img, .wzh-grid .pro_img img, .product_slider .pro_img img, .pro_img img {
    width: 100% !important; height: auto !important; max-height: none !important; aspect-ratio: 1 / 1; object-fit: contain !important;
}
@media (max-width: 575.98px) {
    .main_product_inner, .wzh-grid { gap: 8px !important; }
}
