/* 
 * SHURJOMART - Responsive Stylesheet (Tablet & Mobile)
 */

/* ===================================================
   MOBILE TOPBAR & BOTTOM NAV (Base definitions)
   =================================================== */
.mob-topbar {
  display: none;
}

.mob-bottom-nav {
  display: none;
}

/* ===================================================
   TABLET RESPONSIVENESS (<= 991px)
   =================================================== */
@media (max-width: 991px) {
  .hero-banner {
    aspect-ratio: 16 / 9;
    height: auto;
  }
  
  .banner-pair {
    grid-template-columns: repeat(2, 1fr);
  }

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

  .prod-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 30px;
  }
}

/* ===================================================
   MOBILE PHONES (<= 768px)
   =================================================== */
@media (max-width: 768px) {
  body {
    padding-bottom: 65px; /* space for bottom nav */
  }

  .container {
    padding: 0 12px;
  }

  /* Switch Headers */
  #site-header {
    display: none !important;
  }

  .mob-topbar {
    display: flex !important;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    background: #023d77;
    padding: 8px 12px;
    position: sticky;
    top: 0;
    z-index: 200;
    width: 100%;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  }

  .mob-logo {
    font-size: 19px;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: 0.04em;
    white-space: nowrap;
    flex-shrink: 0;
    text-decoration: none;
    display: flex;
    align-items: center;
  }

  .mob-logo img {
    max-height: 32px;
    width: auto;
  }

  .mob-logo span {
    color: #fe7805;
  }

  .mob-search-box {
    flex: 1;
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    padding: 6px 10px;
    gap: 6px;
    cursor: pointer;
    min-width: 0;
    color: #ffffff;
  }

  .mob-search-box svg {
    width: 15px;
    height: 15px;
    flex-shrink: 0;
    opacity: 0.8;
  }

  .mob-search-box span {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.75);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .mob-topbar-icons {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
  }

  .mob-topbar-icons a {
    color: #ffffff;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .mob-topbar-icons svg {
    width: 20px;
    height: 20px;
  }

  .mob-cart-badge {
    position: absolute;
    top: -5px;
    right: -6px;
    background: #fe7805;
    color: #ffffff;
    font-size: 9px;
    font-weight: 700;
    min-width: 15px;
    height: 15px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  /* Hero Slider Mobile */
  .hero-banner {
    aspect-ratio: 16 / 9;
    height: auto;
    border-radius: 8px;
    margin: 8px auto 16px auto;
  }

  .hero-caption {
    padding: 10px 14px;
    bottom: 10px;
    left: 10px;
    max-width: 85%;
    border-radius: 6px;
  }

  .hero-caption h2 {
    font-size: 15px;
    margin-bottom: 2px;
  }

  .hero-caption p {
    font-size: 11px;
    display: none; /* keep clean on tiny screens */
  }

  .hero-arrow {
    width: 30px;
    height: 30px;
    font-size: 12px;
  }

  /* Categories Scroll */
  .sec-head {
    margin: 20px 0 10px 0;
  }

  .sec-head h3 {
    font-size: 16px;
  }

  .cat-circle {
    width: 58px;
    height: 58px;
  }

  .cat-item {
    width: calc(20% - 10px) !important;
    max-width: calc(20% - 10px) !important;
  }

  .cat-label {
    font-size: 11px;
    max-width: 100%;
    word-break: break-word;
  }

  /* Flash Sale */
  .flash-header {
    padding: 8px 12px;
  }

  .flash-title {
    font-size: 13px;
  }

  .flash-scroll-outer {
    padding: 10px;
  }

  .flash-card {
    width: 125px;
  }

  /* Promo Banners */
  .banner-pair {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    margin-bottom: 20px;
  }

  .banner-card {
    height: 110px;
    border-radius: 6px;
  }

  .banner-overlay {
    padding: 8px 10px;
    font-size: 12px;
  }

  /* Trust Badges */
  .trust-strip {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    padding: 12px;
    margin-bottom: 20px;
  }

  .trust-item {
    font-size: 11.5px;
    gap: 6px;
    justify-content: flex-start;
  }

  .trust-item svg {
    width: 18px;
    height: 18px;
  }

  /* Product Grid Mobile (2 Columns) */
  .prod-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-bottom: 25px;
  }

  .prod-info {
    padding: 8px;
  }

  .prod-title {
    font-size: 12.5px;
    min-height: 32px;
  }

  .prod-price {
    font-size: 13.5px;
  }

  .prod-btn {
    width: calc(100% - 16px);
    margin: 4px 8px 8px 8px;
    padding: 8px;
    font-size: 11.5px;
  }

  /* Newsletter Mobile */
  .newsletter-mob {
    padding: 25px 15px;
    margin-bottom: 25px;
    border-radius: 8px;
  }

  .newsletter-mob h3 {
    font-size: 18px;
  }

  .newsletter-mob form {
    flex-direction: column;
    gap: 8px;
  }

  .newsletter-mob button {
    width: 100%;
    padding: 10px;
  }

  /* Footer */
  footer {
    padding: 35px 0 20px 0;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 24px;
    margin-bottom: 25px;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 8px;
    text-align: center;
  }

  /* Mobile Bottom Navigation Bar */
  .bottom-nav {
    display: block !important;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #ffffff;
    border-top: 1px solid #e2e8f0;
    z-index: 900;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.06);
  }

  .bottom-nav-inner {
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 6px 0;
  }

  .bnav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #64748b;
    font-size: 10.5px;
    font-weight: 600;
    text-decoration: none;
    position: relative;
    padding: 2px 12px;
    transition: color 0.15s;
  }

  .bnav-item.active, .bnav-item:hover {
    color: #023d77;
  }

  .bnav-item svg {
    width: 20px;
    height: 20px;
    margin-bottom: 2px;
    stroke: currentColor;
  }

  .bnav-badge {
    position: absolute;
    top: -3px;
    right: 14px;
    background: #fe7805;
    color: #ffffff;
    font-size: 9px;
    font-weight: 700;
    min-width: 15px;
    height: 15px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 3px;
  }

  /* Floating Chat Widget on Mobile (Above Bottom Bar) */
  .live-chat-widget, #landing-chat-widget-wrapper {
    bottom: 75px !important;
    right: 15px !important;
  }

  /* Full Width Account Page on Mobile (Zero Side Gap) */
  body.woocommerce-account .container,
  body.woocommerce-account main,
  body.woocommerce-account .site-main,
  body.woocommerce-account .woocommerce {
    padding-left: 4px !important;
    padding-right: 4px !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  /* Ultra-Compact Mobile Account Dashboard (Zero Long Scrolling) */
  .woocommerce-account .woocommerce {
    flex-direction: column !important;
    gap: 10px !important;
    margin-top: 5px !important;
  }

  .shurjo-account-user-card {
    padding: 10px 12px !important;
    margin-bottom: 8px !important;
    border-radius: 8px !important;
  }
  .shurjo-account-avatar img {
    width: 36px !important;
    height: 36px !important;
  }
  .shurjo-account-user-info h4 {
    font-size: 14px !important;
  }
  .shurjo-account-user-info p {
    font-size: 11.5px !important;
  }

  /* Grid/Wrap Menu Pill Bar on Mobile (No Scrollbar - 1 2 3 on Row 1, 4 5 on Row 2) */
  .woocommerce-account .woocommerce-MyAccount-navigation {
    flex: 1 1 100% !important;
    max-width: 100% !important;
    width: 100% !important;
    overflow: visible !important;
    padding-bottom: 0 !important;
  }
  .shurjo-account-nav ul {
    display: flex !important;
    flex-wrap: wrap !important;
    flex-direction: row !important;
    gap: 6px !important;
    width: 100% !important;
  }
  .shurjo-account-nav li {
    flex: 1 1 calc(33.333% - 6px) !important;
    min-width: max-content !important;
  }
  .shurjo-account-nav li a {
    padding: 8px 6px !important;
    font-size: 12px !important;
    text-align: center !important;
    justify-content: center !important;
    white-space: nowrap !important;
    border-radius: 8px !important;
  }

  .woocommerce-account .woocommerce-MyAccount-content {
    padding: 14px 10px !important;
    border-radius: 8px !important;
  }

  .shurjo-dashboard-welcome-banner {
    padding: 10px 12px !important;
    margin-bottom: 12px !important;
  }
  .shurjo-dashboard-welcome-banner h2 {
    font-size: 14.5px !important;
  }

  .shurjo-dashboard-actions-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 10px !important;
  }
  .shurjo-dash-card {
    padding: 12px 10px !important;
    border-radius: 8px !important;
  }
  .shurjo-dash-card .dash-card-icon {
    font-size: 22px !important;
    margin-bottom: 4px !important;
  }
  .shurjo-dash-card h3 {
    font-size: 13px !important;
  }
  .shurjo-dash-card p {
    display: none !important; /* Hide long paragraph on phone to prevent scrolling */
  }

  /* Mobile Cart Drawer & Bottom Nav Positioning (Keep bottom nav visible) */
  .bottom-nav {
    z-index: 10001 !important;
  }
  .cart-drawer {
    width: 100% !important;
    max-width: 100% !important;
    bottom: 56px !important;
    height: calc(100% - 56px) !important;
    z-index: 9999 !important;
  }
  .cart-drawer-footer {
    padding: 12px 16px !important;
  }
  .shurjo-dash-card .dash-card-link {
    font-size: 11.5px !important;
  }
}

