/* responsive.css - Global mobile and tablet styling for B2Premium */

@media (max-width: 992px) {

    /* Navbar & Header */
    nav {
        padding: 15px 30px !important;
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        width: 100% !important;
        z-index: 9999 !important;
    }
    
    body {
        padding-top: 100px !important;
    }

    .hamburger {
        display: flex !important;
        margin-left: 15px;
        z-index: 10000 !important;
    }

    /* Modern Side Drawer Menu for Mobile & Tablet */
    .nav-links {
        display: flex !important;
        flex-direction: column !important;
        position: fixed !important;
        top: 0 !important;
        right: -320px !important;
        /* hidden off-screen */
        width: 300px !important;
        height: 100vh !important;
        background: #0D3E26 !important;
        padding: 80px 25px 30px 25px !important;
        border-top: none !important;
        box-shadow: -10px 0 30px rgba(0, 0, 0, 0.6) !important;
        transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1) !important;
        z-index: 9999 !important;
        justify-content: flex-start !important;
        left: auto !important;
        gap: 0 !important;
        overflow-y: auto !important;
        overscroll-behavior: contain !important;
     align-items: center; }
    
    /* Scrollbar styling for the drawer */
    .nav-links::-webkit-scrollbar { width: 4px; }
    .nav-links::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.2); border-radius: 4px; }

    .nav-links.active {
        right: 0 !important;
    }

    .nav-links li {
        width: 100% !important;
        text-align: left !important;
        margin: 0 !important;
        padding: 12px 0 !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    }

    .nav-links li a {
        display: block !important;
        font-size: 16px !important;
        padding: 5px 0 !important;
    }

    /* Mobile Dropdown Fix */
    .nav-dropdown:hover .dropdown-menu,
    .nav-dropdown.open .dropdown-menu {
        position: relative !important;
        top: 0 !important;
        left: 0 !important;
        right: auto !important;
        margin-top: 10px !important;
        width: 100% !important;
        box-shadow: none !important;
        border: none !important;
        background: rgba(0, 0, 0, 0.2) !important;
        border-radius: 8px !important;
    }

    /* Hero & Banners */
    .hero {
        flex-direction: column !important;
        text-align: center !important;
        padding: 40px 20px !important;
    }

    .hero-text {
        max-width: 100% !important;
    }

    .hero-text h1 {
        font-size: 32px !important;
    }

    .hero-img img,
    .hero-image img {
        max-width: 80% !important;
        margin: 0 auto;
    }

    /* Comprehensive Grids (Products, Categories, Footer, Forms, etc.) */
    .col-grid,
    .bs-grid,
    .tr-grid,
    .blog-grid,
    .products-grid,
    .product-grid,
    .form-grid,
    .faq-grid,
    .ft-grid,
    .stats-grid,
    .intro-grid,
    .sjr-intro-grid,
    .cats-grid,
    .trend-grid,
    .deal-grid,
    .features,
    .grid,
    .grid-container,
    .reviews-layout {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)) !important;
    }

    /* Forms & Containers */
    .container {
        width: 95% !important;
    }

    /* Footer */
    footer {
        padding: 40px 25px 25px !important;
    }

    .footer-content {
        flex-direction: column !important;
        text-align: center !important;
        gap: 30px !important;
    }

    .footer-content>div {
        width: 100% !important;
    }

    .footer-content ul {
        display: flex;
        flex-direction: column;
        align-items: center;
    }
}

@media (max-width: 768px) {


    /* Login / Signup Forms */
    .form {
        width: 100% !important;
        padding: 30px 20px !important;
    }

    /* Comprehensive Grids - Single column on mobile */
    .col-grid,
    .bs-grid,
    .tr-grid,
    .blog-grid,
    .products-grid,
    .product-grid,
    .form-grid,
    .faq-grid,
    .ft-grid,
    .stats-grid,
    .intro-grid,
    .sjr-intro-grid,
    .cats-grid,
    .trend-grid,
    .deal-grid,
    .features,
    .grid,
    .grid-container,
    .reviews-layout {
        grid-template-columns: 1fr !important;
        gap: 15px !important;
    }

    /* Headings and padding */
    h1 {
        font-size: 28px !important;
    }

    h2 {
        font-size: 24px !important;
    }

    .section-title {
        font-size: 22px !important;
    }

    .section-desc {
        font-size: 14px !important;
    }

    /* Cart page */
    .cart-layout {
        flex-direction: column !important;
    }

    .cart-items,
    .cart-summary {
        width: 100% !important;
    }

    .cart-item {
        flex-direction: column !important;
        text-align: center !important;
    }

    .cart-item img {
        margin-bottom: 10px !important;
    }

    .cart-item-actions {
        justify-content: center !important;
        width: 100% !important;
        margin-top: 10px !important;
    }

    /* Contact page & Enquiry */
    .contact-layout {
        flex-direction: column !important;
    }

    .contact-info,
    .contact-form {
        width: 100% !important;
    }

    .contact-form .form-row {
        flex-direction: column !important;
        gap: 10px !important;
    }

    /* Footer bottom and layout */
    footer {
        padding: 35px 20px 20px !important;
        text-align: center !important;
    }

    .ft-grid {
        grid-template-columns: 1fr 1fr !important;
        gap: 20px !important;
        text-align: left !important;
    }

    .ft-grid > div:nth-child(1),
    .ft-grid > div:nth-child(4) {
        grid-column: span 2 !important;
        text-align: center !important;
    }

    .ft-brand p {
        font-size: 13px !important;
        margin: 10px auto 15px !important;
        max-width: 90% !important;
    }

    footer h5 {
        margin-bottom: 12px !important;
        font-size: 14px !important;
        color: var(--ac) !important;
    }

    footer ul li {
        margin-bottom: 8px !important;
    }

    footer ul li a {
        font-size: 14px !important;
        padding: 4px 0 !important;
        display: inline-block !important;
    }

    .ft-brand-head {
        justify-content: center !important;
    }

    .social-row {
        justify-content: center !important;
        margin-bottom: 10px !important;
    }

    .nl-row {
        flex-direction: column !important;
        gap: 10px !important;
    }

    .nl-row button {
        padding: 12px !important;
        width: 100% !important;
    }

    .pay-chips {
        justify-content: center !important;
        margin-top: 15px !important;
    }

    .ft-bottom {
        flex-direction: column !important;
        text-align: center !important;
        gap: 12px !important;
        margin-top: 15px !important;
        padding-top: 15px !important;
    }
}

@media (max-width: 480px) {

    /* Very small phones */
    nav {
        padding: 10px 15px !important;
    }

    .logo-img {
        height: 40px !important;
    }

    .hero h1 {
        font-size: 24px !important;
    }

    .hero p {
        font-size: 14px !important;
    }

    .btn,
    .button-submit,
    .btn-primary {
        width: 100% !important;
        padding: 12px 20px !important;
        font-size: 14px !important;
    }
}

/* ════════ PRODUCT DETAIL MODAL ════════ */
.prod-modal-overlay {
  display: none; position: fixed; inset: 0; z-index: 9999;
  background: rgba(5,20,12,0.72); backdrop-filter: blur(6px);
  justify-content: center; align-items: center; padding: 20px;
}
.prod-modal-overlay.open { display: flex; animation: fadeInOverlay .25s ease; }
@keyframes fadeInOverlay { from { opacity:0; } to { opacity:1; } }
.prod-modal {
  background: #fff; border-radius: 20px; max-width: 880px; width: 100%;
  max-height: 90vh; overflow-y: auto; display: grid;
  grid-template-columns: 1fr 1fr; gap: 0; position: relative;
  box-shadow: 0 30px 80px rgba(0,0,0,0.35);
  animation: slideUpModal .35s cubic-bezier(.16,1,.3,1);
}
@keyframes slideUpModal { from { opacity:0; transform: translateY(40px) scale(.96); } to { opacity:1; transform: none; } }
.modal-img-wrap {
  background: linear-gradient(135deg,#f0faf4,#e8f5ee);
  border-radius: 20px 0 0 20px; display: flex;
  align-items: center; justify-content: center; padding: 30px;
  overflow: hidden; position: relative; min-height: 340px;
}
.modal-img-wrap img {
  width: 100%; max-height: 340px; object-fit: contain;
  transition: transform .5s cubic-bezier(.16,1,.3,1);
}
.modal-img-wrap:hover img { transform: scale(1.08); }
.modal-body { padding: 36px 32px; display: flex; flex-direction: column; gap: 12px; }
.modal-badge {
  display: inline-block; background: var(--red); color: #fff;
  font-size: 11px; font-weight: 800; padding: 4px 12px;
  border-radius: 20px; letter-spacing: 0.5px; width: fit-content;
}
.modal-badge.gold { background: var(--ac); color: var(--gd); }
.modal-title { font-size: 22px; font-weight: 900; color: var(--gd); line-height: 1.3; }
.modal-weight { font-size: 12px; font-weight: 700; color: var(--tl); text-transform: uppercase; letter-spacing: 1px; }
.modal-stars { color: var(--ac); font-size: 16px; }
.modal-desc { font-size: 14px; color: var(--tm); line-height: 1.7; }
.modal-price { display: flex; align-items: baseline; gap: 10px; margin-top: 4px; }
.modal-price .mpn { font-size: 28px; font-weight: 900; color: var(--gd); }
.modal-price .mpw { font-size: 15px; color: var(--tl); text-decoration: line-through; }
.modal-price .msave { font-size: 13px; font-weight: 800; color: #27ae60; background: #eafaf1; padding: 3px 10px; border-radius: 20px; }

/* ── QTY + ADD ── */
.modal-cart-row { display: flex; align-items: center; gap: 12px; margin-top: 8px; flex-wrap: wrap; }
.qty-box {
  display: flex; align-items: center; border: 2px solid var(--gl);
  border-radius: 10px; overflow: hidden;
}
.qty-btn {
  background: var(--gd); color: #fff; border: none; width: 38px; height: 42px;
  font-size: 20px; font-weight: 700; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background .2s;
}
.qty-btn:hover { background: var(--gl); }
.qty-num {
  width: 46px; text-align: center; font-size: 16px; font-weight: 800;
  color: var(--gd); border: none; outline: none; background: #fff;
}
.modal-add-btn {
  flex: 1; background: var(--ac); color: var(--gd); border: none;
  border-radius: 10px; padding: 12px 20px; font-size: 14px; font-weight: 800;
  cursor: pointer; text-transform: uppercase; letter-spacing: .5px;
  transition: all .2s; min-width: 140px;
}
.modal-add-btn:hover { background: var(--ach); transform: translateY(-1px); }
.modal-add-btn.added { background: #27ae60; color: #fff; }

.modal-close {
  position: absolute; top: 16px; right: 16px; width: 36px; height: 36px;
  background: rgba(0,0,0,0.1); border: none; border-radius: 50%;
  font-size: 18px; cursor: pointer; display: flex; align-items: center;
  justify-content: center; color: #555; transition: all .2s; z-index: 10;
}
.modal-close:hover { background: var(--red); color: #fff; transform: rotate(90deg); }

@media (max-width: 680px) {
  .prod-modal { grid-template-columns: 1fr; }
  .modal-img-wrap { border-radius: 20px 20px 0 0; min-height: 220px; }
  .modal-body { padding: 24px 20px; }
  .modal-title { font-size: 18px; }
}

/* ════════ CARD IMAGE ZOOM (cursor follow) ════════ */
.prod-card { cursor: pointer; position: relative; }
.prod-img-wrap {
  overflow: hidden; border-radius: 12px; margin-bottom: 14px;
  position: relative; background: #f9f9f9;
}
.prod-img-wrap img {
  width: 100%; height: 210px; object-fit: contain; display: block;
  transition: transform .5s cubic-bezier(.16,1,.3,1), filter .4s;
  padding: 10px;
}
.prod-card:hover .prod-img-wrap img {
  transform: scale(1.12);
  filter: brightness(1.04);
}

/* ════════ INLINE CART QTY (cards) ════════ */
.card-qty-row {
  display: flex; align-items: center; gap: 8px; margin-top: 8px;
  animation: fadeInUp .3s ease;
}
.cqty-box { display: flex; align-items: center; border: 2px solid var(--gl); border-radius: 8px; overflow: hidden; }
.cqty-btn {
  background: var(--gd); color: #fff; border: none;
  width: 32px; height: 36px; font-size: 18px; font-weight: 700;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  transition: background .2s;
}
.cqty-btn:hover { background: var(--gl); }
.cqty-num { width: 36px; text-align: center; font-size: 14px; font-weight: 800; color: var(--gd); border: none; outline: none; background: #fff; }
.cqty-add {
  flex: 1; background: #27ae60; color: #fff; border: none; border-radius: 8px;
  padding: 8px 10px; font-size: 12px; font-weight: 800; cursor: pointer;
  text-transform: uppercase; letter-spacing: .3px; transition: all .2s;
}
.cqty-add:hover { background: #219150; }

/* ════════ DROPDOWN HOVER STABILITY BRIDGE ════════ */
/* Keeps the invisible gap between the nav link and the dropdown hoverable,
   so the menu doesn't disappear while moving the cursor down to it. */
.nav-dropdown {
  position: relative !important;
}
.dropdown-menu::before {
  content: '' !important;
  position: absolute !important;
  top: -25px !important;
  left: 0 !important;
  right: 0 !important;
  height: 25px !important;
  background: transparent !important;
  z-index: -1 !important;
}

/* NOTE: The old duplicate ".dropdown-menu" base styling block that used to
   live here (display:none/block based) has been removed. It was fighting
   with the opacity/visibility based dropdown styles already defined in
   all_product.css, which caused the menu to render open/misplaced on
   desktop. The mobile-specific override above (inside the
   @media (max-width: 992px) block) is all that's needed for the drawer view;
   desktop dropdown styling is fully owned by all_product.css. */