/* ============================================================
   GOLDEN WILLOW - Mobile App CSS (Android-style experience)
   ============================================================ */

:root {
  --mob-bottom-bar-h: 64px;
  --mob-header-h: 58px;
  --mob-safe-bottom: env(safe-area-inset-bottom, 0px);
}

/* ════════════════════════════════════════════════════════════
   MOBILE STYLES  (≤ 768px)
   ════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {

  /* ── Body ─────────────────────────────────────────────────── */
  body {
    padding-bottom: calc(var(--mob-bottom-bar-h) + var(--mob-safe-bottom) + 8px);
    -webkit-tap-highlight-color: transparent;
  }

  .container { padding: 0 12px; }

  /* ── Top Announcement Bar ─────────────────────────────────── */
  .top-bar {
    font-size: 0.7rem;
    padding: 5px 0;
  }

  /* ── HEADER ────────────────────────────────────────────────── */
  .site-header { border-bottom: 1px solid var(--border-color); }

  .nav-wrapper {
    height: var(--mob-header-h);
    padding: 0 12px;
    gap: 8px;
  }

  .header-left-group {
    gap: 8px;
  }

  .brand-logo {
    font-size: 0.88rem;
    gap: 6px;
    flex-shrink: 0;
    letter-spacing: 0.5px;
  }

  .brand-logo i { font-size: 1.15rem; }

  /* Show full store name — brand-secondary visible but compact */
  .brand-logo .brand-secondary {
    display: inline;
  }

  /* Hide desktop search bar — replaced by mob-search-bar */
  .header-search { display: none !important; }

  /* Compact header action buttons */
  .header-actions { gap: 6px; }
  .icon-btn { width: 38px; height: 38px; }

  /* Track Order: icon-only pill on mobile */
  .nav-track-link {
    width: 38px; height: 38px;
    padding: 0;
    border-radius: 50%;
    justify-content: center;
    gap: 0;
  }
  .nav-track-link span { display: none; }
  .nav-track-link i { font-size: 1rem; }

  /* ── MOBILE SEARCH BAR ─────────────────────────────────────── */
  .mob-search-bar {
    background: var(--bg-surface);
    border-bottom: 1px solid var(--border-color);
    padding: 8px 12px;
    position: sticky;
    top: var(--mob-header-h);
    z-index: 990;
  }

  .mob-search-bar form {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    width: 100% !important;
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
    height: auto !important;
  }

  .mob-search-input-wrap {
    flex: 1 !important;
    min-width: 0 !important;
    display: flex !important;
    align-items: center !important;
    background: var(--bg-subtle) !important;
    border: 1.5px solid var(--border-color) !important;
    border-radius: 12px !important;
    padding: 0 12px !important;
    height: 42px !important;
    transition: border-color 0.2s ease !important;
    box-sizing: border-box !important;
  }

  .mob-search-input-wrap:focus-within {
    border-color: var(--primary-gold) !important;
  }

  .mob-search-input-wrap .search-icon {
    color: var(--text-muted) !important;
    font-size: 0.9rem !important;
    flex-shrink: 0 !important;
    margin-right: 6px !important;
  }

  .mob-search-bar form input,
  .mob-search-input-wrap input {
    flex: 1 !important;
    width: 100% !important;
    height: 100% !important;
    background: transparent !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    outline: none !important;
    font-size: 0.88rem !important;
    color: var(--text-main) !important;
    padding: 0 !important;
  }

  .mob-search-bar form input::placeholder,
  .mob-search-input-wrap input::placeholder {
    color: var(--text-muted) !important;
    font-size: 0.86rem !important;
    opacity: 0.75 !important;
  }

  .mob-search-submit-btn {
    background: var(--primary-gold) !important;
    color: #000000 !important;
    border: none !important;
    border-radius: 12px !important;
    height: 42px !important;
    padding: 0 16px !important;
    font-size: 0.82rem !important;
    font-weight: 800 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 6px !important;
    cursor: pointer !important;
    flex-shrink: 0 !important;
    box-shadow: 0 3px 10px rgba(212, 175, 55, 0.3) !important;
    white-space: nowrap !important;
  }

  /* ── CATEGORY PILL STRIP ───────────────────────────────────── */
  .category-nav {
    padding: 8px 0;
    position: sticky;
    top: calc(var(--mob-header-h) + 58px);
    z-index: 980;
    background: var(--bg-surface);
  }

  .cat-links {
    gap: 0;
    justify-content: flex-start;
    padding: 0 12px;
    -webkit-overflow-scrolling: touch;
  }

  .cat-links li { flex-shrink: 0; }

  .cat-links a {
    display: inline-block;
    padding: 5px 13px;
    border-radius: 20px;
    font-size: 0.76rem;
    font-weight: 600;
    letter-spacing: 0;
    margin-right: 6px;
    background: var(--bg-subtle);
    border: 1.5px solid var(--border-color);
    color: var(--text-muted);
    white-space: nowrap;
    transition: all 0.18s ease;
  }

  .cat-links a.active,
  .cat-links a:hover {
    background: var(--primary-gold);
    border-color: var(--primary-gold);
    color: #000;
  }

  /* ── SECTION SPACING ─────────────────────────────────────── */
  .section-padding { padding: 20px 0 32px; }

  /* ── PRODUCT GRID — 2-column app layout ──────────────────── */
  #pcardsGrid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 10px !important;
  }

  /* Mobile pcard compact height */
  .pcard > div:first-of-type { /* image area */
    height: 150px !important;
    padding: 10px !important;
  }

  /* Tighter info section */
  .pcard > div:last-child {
    padding: 10px 12px !important;
  }

  /* Title clamp tighter */
  .pcard span[style*="-webkit-line-clamp"] {
    font-size: 0.8rem !important;
    margin-bottom: 6px !important;
  }

  /* Price smaller */
  .pcard [style*="1.1rem"][style*="font-weight:800"] {
    font-size: 0.9rem !important;
  }

  /* Buttons side by side still — reduce padding */
  .pcard [style*="grid-template-columns:1fr 1fr"] a {
    padding: 7px 4px !important;
    font-size: 0.72rem !important;
    border-radius: 8px !important;
    gap: 4px !important;
  }

  /* ── PRODUCTS PAGE — Filter/Sort bar + drawer ────────────── */
  .products-layout {
    grid-template-columns: 1fr !important;
    gap: 0 !important;
  }

  .filter-sidebar { display: none !important; }

  /* Mobile Filter + Sort top bar */
  .mob-filter-sort-bar {
    display: flex !important;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
  }

  .mob-filter-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: var(--bg-subtle);
    border: 1.5px solid var(--border-color);
    border-radius: 10px;
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--text-main);
    cursor: pointer;
    flex-shrink: 0;
    transition: all 0.18s;
  }

  .mob-filter-btn i { color: var(--primary-gold); }

  .mob-sort-select {
    flex: 1;
    padding: 8px 10px;
    background: var(--bg-subtle);
    border: 1.5px solid var(--border-color);
    border-radius: 10px;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-main);
    outline: none;
    cursor: pointer;
  }

  /* Filter drawer overlay */
  .mob-filter-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 1200;
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
  }

  .mob-filter-overlay.open { display: block; }

  /* Filter drawer panel */
  .mob-filter-drawer {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--bg-surface);
    border-radius: 20px 20px 0 0;
    z-index: 1201;
    max-height: 80vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 0 0 calc(var(--mob-bottom-bar-h) + 16px);
    transform: translateY(100%);
    transition: transform 0.32s cubic-bezier(0.32, 0.72, 0, 1);
    box-shadow: 0 -8px 40px rgba(0,0,0,0.25);
  }

  .mob-filter-drawer.open {
    display: block;
    transform: translateY(0);
  }

  .mob-filter-handle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px 12px;
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    background: var(--bg-surface);
    z-index: 2;
    border-radius: 20px 20px 0 0;
  }

  .mob-filter-handle h3 {
    font-size: 1rem;
    font-weight: 700;
  }

  .mob-filter-handle button {
    background: var(--bg-subtle);
    border: none;
    border-radius: 50%;
    width: 30px; height: 30px;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer;
    color: var(--text-muted);
    font-size: 0.9rem;
  }

  .mob-filter-body { padding: 14px 16px; }

  /* ── PRODUCT DETAIL PAGE ─────────────────────────────────── */
  .product-detail-grid {
    grid-template-columns: 1fr !important;
    gap: 0 !important;
  }

  /* Main image smaller on mobile */
  .product-detail-grid img#mainProductViewImg {
    max-height: 280px !important;
  }

  /* Thumbnails scroll horizontally */
  .product-detail-grid > div:first-child > div:last-child {
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
  }

  /* Product h1 smaller */
  .product-detail-grid h1 {
    font-size: 1.3rem !important;
    margin: 6px 0 12px !important;
  }

  /* Price row compact */
  .product-detail-grid [style*="2.2rem"] {
    font-size: 1.5rem !important;
  }

  /* Section padding smaller */
  .product-detail-grid + * { padding-top: 0 !important; }

  /* Quantity + cart buttons: stack on tiny screens */
  .product-detail-grid form > div[style*="flex"] {
    flex-wrap: wrap;
    gap: 10px !important;
  }

  .product-detail-grid form .btn-gold {
    padding: 12px 20px !important;
    font-size: 0.92rem !important;
  }

  /* Sticky buy bar — shown via JS on mobile */
  .mob-sticky-buy { display: none; } /* JS overrides to flex */

  /* ── HOMEPAGE HERO — Amazon App-Style Mobile Offer Banners ── */
  .hero-carousel {
    border-bottom: none !important;
    background: #000 !important;
  }

  .hero-slide {
    padding: 0 !important;
    min-height: 230px !important;
    height: 230px !important;
    position: relative !important;
    overflow: hidden !important;
  }

  .hero-slide .container {
    padding: 0 !important;
    height: 100% !important;
    max-width: 100% !important;
  }

  .hero-content {
    display: block !important;
    position: relative !important;
    height: 100% !important;
    width: 100% !important;
    overflow: hidden !important;
  }

  /* Full-bleed banner background image */
  .hero-image-wrapper {
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: 1 !important;
    text-align: left !important;
  }

  .hero-image-wrapper img {
    width: 100% !important;
    height: 100% !important;
    max-height: 100% !important;
    object-fit: cover !important;
    object-position: center !important;
    border-radius: 0 !important;
    border: none !important;
    box-shadow: none !important;
    filter: brightness(0.68) contrast(1.1) !important;
  }

  /* Gradient Scrim Overlay over image */
  .hero-image-wrapper::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
      180deg,
      rgba(0, 0, 0, 0.2) 0%,
      rgba(0, 0, 0, 0.6) 55%,
      rgba(0, 0, 0, 0.9) 100%
    );
    z-index: 2;
    pointer-events: none;
  }

  /* Banner Text + CTA floating directly on top of image */
  .hero-text {
    position: absolute !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    z-index: 3 !important;
    padding: 14px 16px 18px !important;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.9);
  }

  .hero-text span {
    font-size: 0.65rem !important;
    letter-spacing: 0.8px !important;
    margin-bottom: 3px !important;
    color: var(--primary-gold) !important;
    display: inline-block !important;
  }

  .hero-text h1 {
    font-size: 1.3rem !important;
    line-height: 1.2 !important;
    margin-bottom: 3px !important;
    font-weight: 800 !important;
    color: #ffffff !important;
    text-transform: uppercase;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  .hero-text p {
    font-size: 0.78rem !important;
    color: rgba(255, 255, 255, 0.88) !important;
    margin-bottom: 10px !important;
    line-height: 1.3 !important;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  /* Compact Gold CTA Pill Button on Banner */
  .hero-text div[style*="display:flex"],
  .hero-text div[style*="display: flex"] {
    gap: 0 !important;
  }

  .hero-text .btn-gold {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 7px 16px !important;
    font-size: 0.76rem !important;
    font-weight: 800 !important;
    border-radius: 20px !important;
    letter-spacing: 0.3px !important;
    box-shadow: 0 4px 12px rgba(212, 175, 55, 0.4) !important;
  }

  /* Hide secondary button & prev/next arrows on mobile for clean app look */
  .hero-text .btn-outline,
  .hero-carousel .carousel-btn {
    display: none !important;
  }

  /* Position indicator dots cleanly inside banner at bottom right */
  .carousel-indicators {
    bottom: 8px !important;
    z-index: 10 !important;
  }

  .indicator-dot {
    width: 6px !important;
    height: 6px !important;
    margin: 0 3px !important;
  }

  .indicator-dot.active {
    width: 18px !important;
    border-radius: 4px !important;
  }

  /* ── SECTION HEADINGS ────────────────────────────────────── */
  .section-header {
    margin-bottom: 16px !important;
    flex-wrap: wrap;
    gap: 8px;
  }

  .section-title { font-size: 1.2rem !important; }

  /* ── CATEGORY SHOWCASE SCROLL ────────────────────────────── */
  .cat-card-scroll {
    flex: 0 0 140px !important;
    min-width: 140px !important;
    padding: 16px 10px !important;
  }

  /* ── TRUST BAR — Horizontal Swipe Cards on Mobile ───────────── */
  .trust-bar {
    padding: 16px 0 !important;
    overflow: hidden;
  }

  .trust-grid {
    display: flex !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
    padding: 4px 12px 10px !important;
    gap: 12px !important;
    scrollbar-width: none;
  }

  .trust-grid::-webkit-scrollbar {
    display: none !important;
  }

  .trust-item {
    flex: 0 0 200px !important;
    min-width: 200px !important;
    max-width: 200px !important;
    scroll-snap-align: start;
    background: var(--bg-subtle) !important;
    border: 1px solid var(--border-color) !important;
    border-radius: 14px !important;
    padding: 16px 12px !important;
    text-align: center !important;
    box-sizing: border-box !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04) !important;
  }

  .trust-item i { font-size: 1.6rem !important; margin-bottom: 8px !important; }
  .trust-item h4 { font-size: 0.88rem !important; margin-bottom: 4px !important; }
  .trust-item p { font-size: 0.76rem !important; line-height: 1.35 !important; }

  /* ── CART PAGE ────────────────────────────────────────────── */
  .cart-page-grid {
    grid-template-columns: 1fr !important;
    gap: 14px !important;
  }

  /* Summary col goes below items on mobile */
  .cart-summary-col {
    order: 2;
  }

  /* Cart row item already flexbox — just ensure it wraps nicely */
  .cart-row-item {
    gap: 12px !important;
    padding: 14px !important;
  }

  /* ── CHECKOUT PAGE ────────────────────────────────────────── */
  .checkout-grid { grid-template-columns: 1fr !important; }

  /* ── AUTH PAGES ───────────────────────────────────────────── */
  .auth-page > .container { padding: 0 !important; }
  .auth-page .card {
    border-radius: 0 !important;
    border-left: none !important;
    border-right: none !important;
    box-shadow: none !important;
    margin: 0 !important;
  }

  /* ── FOOTER — hidden on mobile, bottom nav replaces it ───── */
  .site-footer { display: none !important; }

  /* ── DROPDOWN & BACKDROP — high z-index popover card on mobile ── */
  .user-dropdown-backdrop {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    z-index: 99998;
    pointer-events: none;
  }

  .user-dropdown-backdrop.show {
    display: block !important;
    pointer-events: auto !important;
  }

  .user-dropdown-menu {
    position: fixed !important;
    top: calc(var(--mob-header-h) + 6px) !important;
    right: 12px !important;
    left: auto !important;
    bottom: auto !important;
    width: 285px !important;
    max-width: calc(100vw - 24px) !important;
    border-radius: 16px !important;
    padding: 8px 0 12px !important;
    background: var(--bg-surface) !important;
    border: 1px solid var(--border-color) !important;
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.45) !important;
    z-index: 99999 !important;
    max-height: 80vh;
    overflow-y: auto;
  }

  /* ── MOBILE CATEGORY SIDE DRAWER ─────────────────────────── */
  .category-nav {
    display: none !important;
  }

  .desktop-catalog-header {
    display: none !important;
  }

  /* ── COMPACT MOBILE TYPOGRAPHY & SPACING ───────────────── */
  h1, .h1 { font-size: 1.3rem !important; line-height: 1.25 !important; }
  h2, .h2 { font-size: 1.1rem !important; line-height: 1.25 !important; }
  h3, .h3 { font-size: 0.95rem !important; line-height: 1.25 !important; }
  h4, .h4 { font-size: 0.85rem !important; }

  /* ── WHATSAPP BUTTON ─────────────────────────────────────── */
  .whatsapp-float-btn {
    bottom: calc(var(--mob-bottom-bar-h) + 12px) !important;
    right: 14px !important;
  }

  /* ── BOTTOM NAVIGATION BAR ───────────────────────────────── */
  .mob-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: var(--mob-bottom-bar-h);
    background: var(--bg-surface);
    border-top: 1px solid var(--border-color);
    display: flex;
    align-items: stretch;
    z-index: 1100;
    padding-bottom: var(--mob-safe-bottom);
    box-shadow: 0 -3px 16px rgba(0,0,0,0.09);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
  }

  .mob-nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    text-decoration: none;
    color: var(--text-muted);
    font-size: 0.6rem;
    font-weight: 600;
    letter-spacing: 0.3px;
    cursor: pointer;
    border: none;
    background: none;
    padding: 0;
    position: relative;
    transition: color 0.18s ease;
    -webkit-tap-highlight-color: transparent;
  }

  .mob-nav-item i {
    font-size: 1.25rem;
    transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), color 0.18s ease;
  }

  .mob-nav-item.active { color: var(--primary-gold); }
  .mob-nav-item.active i {
    transform: translateY(-2px);
    color: var(--primary-gold);
  }

  /* Cart badge on bottom nav */
  .mob-nav-cart-badge {
    position: absolute;
    top: 5px;
    left: calc(50% + 8px);
    background: var(--primary-gold);
    color: #000;
    font-size: 0.55rem;
    font-weight: 800;
    width: 15px; height: 15px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    border: 1.5px solid var(--bg-surface);
  }

  /* Elevated center Cart button */
  .mob-nav-cart .mob-nav-cart-icon {
    width: 48px; height: 48px;
    background: var(--primary-gold);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    margin-top: -18px;
    box-shadow: 0 4px 16px rgba(212,175,55,0.5);
    border: 3px solid var(--bg-surface);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
  }

  .mob-nav-cart:active .mob-nav-cart-icon {
    transform: scale(0.92);
    box-shadow: 0 2px 8px rgba(212,175,55,0.3);
  }

  /* ── UNIVERSAL FRONTEND PAGE MOBILE FIT FIXES ───────────────────────────── */
  html {
    width: 100% !important;
    max-width: 100% !important;
  }
  body {
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: hidden !important;
    position: relative;
    -webkit-overflow-scrolling: touch;
  }

  /* Responsive Multi-column Form Rows */
  .form-row-2,
  .form-row-3,
  .checkout-wrapper,
  .products-layout,
  .product-detail-grid,
  .cart-page-grid,
  .account-grid,
  .track-search-form,
  .track-meta-grid,
  .success-details-grid,
  div[style*="grid-template-columns: 1fr 1fr"],
  div[style*="grid-template-columns:1fr 1fr"],
  div[style*="grid-template-columns: 1fr 1fr 1fr"],
  div[style*="grid-template-columns:1fr 1fr 1fr"],
  div[style*="grid-template-columns: 1fr 400px"],
  div[style*="grid-template-columns: 1fr 340px"],
  div[style*="grid-template-columns: 1fr 300px"],
  div[style*="grid-template-columns: 320px 1fr"],
  div[style*="grid-template-columns: 260px 1fr"] {
    grid-template-columns: 1fr !important;
    gap: 14px !important;
  }

  /* Sticky sidebar columns static on mobile */
  .filter-sidebar,
  .checkout-wrapper > div:last-child {
    position: static !important;
  }

  /* Track order shipment 4-step progress line on mobile */
  .track-steps-grid,
  div[style*="grid-template-columns: repeat(4, 1fr)"] {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 16px 12px !important;
  }

  /* Success page CTA buttons stack full width */
  .success-cta-btns,
  div[style*="display:flex"][style*="justify-content:center"][style*="flex-wrap:wrap"] {
    flex-direction: column !important;
    width: 100% !important;
    gap: 10px !important;
  }

  .success-cta-btns .btn,
  div[style*="display:flex"][style*="justify-content:center"][style*="flex-wrap:wrap"] .btn {
    width: 100% !important;
    justify-content: center !important;
  }

  /* Prevent container overflow */
  .container {
    width: 100% !important;
    max-width: 100vw !important;
    padding-left: 12px !important;
    padding-right: 12px !important;
    box-sizing: border-box !important;
  }

  /* Ensure card paddings scale gracefully on mobile */
  .card, 
  .checkout-card,
  .auth-page .card,
  div[style*="padding: 36px"],
  div[style*="padding: 28px"],
  div[style*="padding: 32px"],
  div[style*="padding: 40px"] {
    padding: 18px 14px !important;
    border-radius: 12px !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  /* Responsive Cart row items */
  .cart-row-item {
    flex-wrap: wrap !important;
    gap: 10px !important;
    padding: 12px !important;
  }

  /* Flex containers with space-between: wrap nicely */
  div[style*="display: flex"][style*="justify-content: space-between"],
  div[style*="display:flex"][style*="justify-content:space-between"] {
    flex-wrap: wrap !important;
    gap: 10px !important;
  }

  /* Ensure tables scroll smoothly horizontally if needed */
  table {
    display: block !important;
    width: 100% !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
  }

  /* ── MOBILE FORM INPUT CONTROLS (App-Style Inputs) ───────── */
  .form-group {
    margin-bottom: 14px !important;
  }

  .form-group label,
  label {
    display: block !important;
    font-size: 0.82rem !important;
    font-weight: 700 !important;
    color: var(--text-main) !important;
    margin-bottom: 6px !important;
    letter-spacing: 0.2px;
  }

  .form-control, 
  input[type="text"], 
  input[type="email"], 
  input[type="tel"], 
  input[type="number"], 
  input[type="password"], 
  select, 
  textarea {
    width: 100% !important;
    max-width: 100% !important;
    height: 46px;
    padding: 10px 14px !important;
    font-size: 16px !important; /* 16px prevents iOS tap zoom */
    font-weight: 500 !important;
    color: var(--text-main) !important;
    background: var(--bg-surface) !important;
    border: 1.5px solid var(--border-color) !important;
    border-radius: 10px !important;
    transition: all 0.2s ease !important;
    box-sizing: border-box !important;
  }

  textarea.form-control,
  textarea {
    height: auto !important;
    min-height: 90px !important;
  }

  .form-control::placeholder,
  input::placeholder,
  textarea::placeholder {
    color: var(--text-muted) !important;
    font-size: 0.88rem !important;
    opacity: 0.7 !important;
  }

  .form-control:focus,
  input:focus,
  select:focus,
  textarea:focus {
    border-color: var(--primary-gold) !important;
    background: var(--bg-surface) !important;
    box-shadow: 0 0 0 3px var(--primary-gold-light) !important;
    outline: none !important;
  }

  .btn {
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  /* ── PAYMENT OPTIONS ON MOBILE ───────────── */
  .checkout-card {
    padding: 16px 12px !important;
    border-radius: 12px !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
  }

  .checkout-card h2 {
    font-size: 1rem !important;
    margin-bottom: 14px !important;
    padding-bottom: 10px !important;
  }

  .payment-option {
    display: flex !important;
    align-items: flex-start !important;
    gap: 10px !important;
    padding: 12px 10px !important;
    border-radius: 10px !important;
    margin-bottom: 10px !important;
    box-sizing: border-box !important;
    width: 100% !important;
    max-width: 100% !important;
    overflow: hidden !important;
  }

  .payment-radio-circle {
    width: 18px !important;
    height: 18px !important;
    flex-shrink: 0 !important;
    margin-top: 3px !important;
  }

  .payment-icon {
    width: 36px !important;
    height: 36px !important;
    font-size: 1.1rem !important;
    border-radius: 8px !important;
    flex-shrink: 0 !important;
  }

  .payment-label-text {
    flex: 1 !important;
    min-width: 0 !important;
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
  }

  .payment-label-text strong {
    font-size: 0.88rem !important;
    line-height: 1.3 !important;
    margin-bottom: 3px !important;
    display: block !important;
    white-space: normal !important;
    word-break: break-word !important;
  }

  .payment-label-text small {
    font-size: 0.76rem !important;
    line-height: 1.35 !important;
    color: var(--text-muted) !important;
    display: block !important;
    white-space: normal !important;
    word-break: break-word !important;
  }

  .secure-badges {
    gap: 6px !important;
    margin-top: 6px !important;
    flex-wrap: wrap !important;
  }

  .secure-badge {
    font-size: 0.68rem !important;
    padding: 2px 7px !important;
  }

  /* Auth page container margin reset */
  .auth-page .container {
    margin-top: 16px !important;
    margin-bottom: 24px !important;
  }

} /* END @media (max-width: 768px) */

/* ════════════════════════════════════════════════════════════
   HIDE MOBILE-ONLY ELEMENTS ON DESKTOP
   ════════════════════════════════════════════════════════════ */
@media (min-width: 769px) {
  .mob-bottom-nav,
  .mob-search-bar,
  .mob-filter-overlay,
  .mob-filter-drawer,
  .mob-filter-sort-bar,
  .user-dropdown-backdrop,
  .mob-sticky-buy { display: none !important; }
}

/* ════════════════════════════════════════════════════════════
   VERY SMALL PHONES (< 375px)
   ════════════════════════════════════════════════════════════ */
@media (max-width: 374px) {
  .nav-wrapper { padding: 0 10px; }
  .brand-logo { font-size: 0.95rem; }
  .product-thumb { height: 130px !important; }
  .product-title { font-size: 0.75rem !important; }
  .current-price { font-size: 0.88rem !important; }
}
