/* ==========================================================
   SolidSupply — Mobile App UI
   Full app-like experience for screens <= 768px
   2-column layout throughout for app feel
   ========================================================== */

@media (max-width: 768px) {

  /* === GLOBAL APP BODY === */
  body {
    background: #f0f2f5;
    padding-bottom: 68px;
  }

  /* === HEADER — dark app bar === */
  .topbar { display: none !important; }

  .site-header {
    background: var(--ss-dark) !important;
    box-shadow: 0 2px 12px rgba(0,0,0,0.25) !important;
  }

  .header-main { padding: 0.55rem 0; }

  .site-logo-text { color: #fff; font-size: 1.2rem; }
  .site-logo-text:hover { color: #fff; }
  .logo-mark { background: var(--ss-orange); }

  .cart-link {
    background: rgba(255,255,255,0.1) !important;
    color: #fff !important;
  }
  .cart-link:hover { background: rgba(255,255,255,0.18) !important; color: #fff !important; }

  .menu-toggle { background: rgba(255,255,255,0.1) !important; }

  /* === HERO — compact === */
  .hero { padding: 1.5rem 0 0; }
  .hero-inner {
    grid-template-columns: 1fr !important;
    gap: 0;
    padding-bottom: 1.25rem;
  }
  .hero-visual { display: none !important; }

  .hero-eyebrow { font-size: 0.78rem; padding: 0.3rem 0.75rem; margin-bottom: 1rem; }

  .hero-title {
    font-size: 1.9rem !important;
    margin-bottom: 0.6rem;
    line-height: 1.1;
  }
  .hero-subtitle {
    font-size: 0.92rem !important;
    margin-bottom: 1.25rem;
    max-width: 100%;
  }

  /* Buttons — full width, tall touch targets */
  .hero-actions {
    flex-direction: column;
    gap: 0.65rem;
    margin-bottom: 1.5rem;
  }
  .hero-actions .btn {
    width: 100% !important;
    justify-content: center;
    padding: 1rem 1.5rem !important;
    border-radius: 14px !important;
    font-size: 1rem !important;
    min-height: 52px;
  }

  /* Stats — 3-column grid inside hero */
  .hero-stats {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 0 !important;
    padding-top: 1.25rem;
    text-align: center;
  }
  .stat-divider { display: none !important; }
  .stat-num { font-size: 1.5rem !important; }
  .stat-label { font-size: 0.72rem !important; }

  /* Search bar full width */
  .hero-search-row { padding: 0 0 1.5rem; }
  .hero-search-wrap { justify-content: center !important; }
  .ss-search-form { width: 100% !important; }
  .ss-search-input {
    font-size: 0.95rem !important;
    padding: 0.875rem 3rem 0.875rem 1.2rem !important;
    border-radius: 14px !important;
  }

  /* Marquee — slightly smaller */
  .marquee-track { font-size: 0.88rem; }

  /* === SECTIONS — tighter spacing === */
  .section { padding: 1.5rem 0 !important; }
  .container { padding: 0 0.875rem !important; }
  .section-head { margin-bottom: 1.25rem !important; }
  .section-title { font-size: 1.4rem !important; }
  .section-desc { font-size: 0.88rem !important; }
  .section-label { font-size: 0.75rem !important; margin-bottom: 0.35rem !important; }
  .section-link { font-size: 0.88rem; }
  .section-head-row { gap: 0.75rem !important; align-items: center !important; }

  /* === CATEGORIES — 2 col app grid === */
  .section-categories { background: #f0f2f5 !important; }

  .categories-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 0.75rem !important;
  }
  .cat-card {
    border-radius: 16px !important;
    border: none !important;
    box-shadow: 0 2px 10px rgba(0,0,0,0.07) !important;
    background: #fff !important;
  }
  .cat-card:hover {
    transform: translateY(-2px) !important;
  }
  .cat-card-img { aspect-ratio: 4/3; }
  .cat-card-body { padding: 0.7rem 0.9rem 0.9rem !important; gap: 0.5rem !important; }
  .cat-card-name { font-size: 0.95rem !important; }
  .cat-card-count { font-size: 0.75rem !important; }
  .cat-card-num { font-size: 0.85rem !important; top: 0.75rem !important; left: 0.75rem !important; }
  .cat-card-arrow { font-size: 1.1rem !important; }

  /* === PRODUCTS — 2 col === */
  .section-products { background: #f0f2f5 !important; }

  .products-wrap .products,
  .wc-page .products {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 0.75rem !important;
  }
  .products-wrap .product,
  .wc-page ul.products li.product {
    padding: 0.75rem !important;
    border-radius: 16px !important;
    border: none !important;
    box-shadow: 0 2px 10px rgba(0,0,0,0.07) !important;
    background: #fff !important;
  }
  .products-wrap .product:hover,
  .wc-page ul.products li.product:hover {
    transform: translateY(-2px) !important;
  }
  .products-wrap .product img,
  .wc-page ul.products li.product img {
    border-radius: 12px !important;
    margin-bottom: 0.65rem !important;
  }
  .products-wrap .product .woocommerce-loop-product__title,
  .wc-page ul.products li.product .woocommerce-loop-product__title {
    font-size: 0.88rem !important;
    margin-bottom: 0.25rem !important;
    line-height: 1.35 !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
  }
  .products-wrap .product .price,
  .wc-page ul.products li.product .price {
    font-size: 0.95rem !important;
    margin-bottom: 0.65rem !important;
  }
  .products-wrap .button,
  .wc-page .button,
  .wc-page .add_to_cart_button {
    width: 100% !important;
    padding: 0.55rem 0.5rem !important;
    font-size: 0.82rem !important;
    border-radius: 10px !important;
    text-align: center !important;
    justify-content: center !important;
  }

  /* === WHY CHOOSE US — 2 col === */
  .section-why { background: #f0f2f5 !important; }

  .why-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 0.75rem !important;
  }
  .why-card {
    padding: 1.25rem 1rem !important;
    border: none !important;
    border-radius: 16px !important;
    box-shadow: 0 2px 10px rgba(0,0,0,0.07) !important;
    background: #fff !important;
  }
  .why-card::before { height: 3px !important; }
  .why-icon {
    width: 46px !important; height: 46px !important;
    margin-bottom: 0.9rem !important;
    border-radius: 12px !important;
  }
  .why-title { font-size: 1rem !important; margin-bottom: 0.35rem !important; }
  .why-text { font-size: 0.83rem !important; }

  /* === HOW IT WORKS — 2 col === */
  .section-how { background: #f0f2f5 !important; }

  .how-steps {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 0.75rem !important;
  }
  .how-step-arrow { display: none !important; }
  .how-step {
    padding: 1.25rem 1rem !important;
    border-radius: 16px !important;
    background: #fff !important;
    border: none !important;
    box-shadow: 0 2px 10px rgba(0,0,0,0.07) !important;
  }
  .how-step--wa {
    background: linear-gradient(135deg, #f0fff6 0%, #fff 100%) !important;
    box-shadow: 0 2px 10px rgba(37,211,102,0.12) !important;
  }
  .how-step-num { font-size: 2.5rem !important; margin-bottom: 0.5rem !important; }
  .how-step-title { font-size: 0.95rem !important; margin-bottom: 0.35rem !important; }
  .how-step-text { font-size: 0.82rem !important; }
  .how-step-wa-link { font-size: 0.8rem !important; margin-top: 0.9rem !important; }

  /* === CTA === */
  .section-cta { padding: 1.5rem 0 !important; }
  .cta-box {
    grid-template-columns: 1fr !important;
    padding: 1.75rem 1.25rem !important;
    border-radius: 18px !important;
    text-align: center !important;
    gap: 1.25rem !important;
  }
  .cta-title { font-size: 1.2rem !important; }
  .cta-desc { font-size: 0.88rem !important; }
  .cta-action { justify-content: center !important; }
  .btn-cta-wa { min-width: 220px; justify-content: center !important; }

  /* === FOOTER === */
  .site-footer { padding: 2rem 0 1.5rem; }
  .footer-grid { grid-template-columns: 1fr 1fr !important; gap: 1.5rem 1rem !important; }
  .footer-tagline { font-size: 0.875rem; max-width: 100%; }
  .footer-widget-title { font-size: 0.88rem; margin-bottom: 0.9rem; }
  .footer-links a, .footer-address, .footer-hours { font-size: 0.83rem; }
  .footer-bottom { flex-direction: column; text-align: center; gap: 0.6rem; }
  .footer-bottom-menu { gap: 0.85rem; flex-wrap: wrap; justify-content: center; }
  .footer-copy { font-size: 0.8rem; }

  /* === FLOATING WA — move up above bottom nav === */
  .floating-wa {
    bottom: 80px !important;
    right: 1rem !important;
    padding: 0.8rem !important;
    border-radius: 50% !important;
    box-shadow: 0 4px 16px rgba(37,211,102,0.45) !important;
  }
  .floating-wa-label { display: none !important; }

  /* === BOTTOM NAV BAR === */
  .ss-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 500;
    background: #fff;
    border-top: 1px solid rgba(0,0,0,0.09);
    display: flex !important;
    align-items: stretch;
    height: 60px;
    box-shadow: 0 -4px 20px rgba(0,0,0,0.1);
    padding: 0 0.25rem;
    padding-bottom: env(safe-area-inset-bottom, 0px);
  }

  .ss-bottom-nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    color: #6b7280;
    text-decoration: none;
    font-family: var(--ss-font-display);
    font-weight: 600;
    font-size: 0.63rem;
    padding: 0.3rem 0.25rem;
    border-radius: 10px;
    transition: color 0.18s;
    -webkit-tap-highlight-color: transparent;
    letter-spacing: 0.01em;
    position: relative;
  }
  .ss-bottom-nav-item:hover { color: var(--ss-orange); text-decoration: none; }
  .ss-bottom-nav-item.ss-nav-active { color: var(--ss-orange); }
  .ss-bottom-nav-item svg { flex-shrink: 0; display: block; }

  /* WhatsApp center item — pill highlight */
  .ss-bottom-nav-wa {
    flex: 1.2;
    color: #fff !important;
    background: #25d366;
    border-radius: 14px;
    margin: 0.35rem 0.2rem;
    box-shadow: 0 4px 12px rgba(37,211,102,0.4);
    gap: 2px;
    font-size: 0.6rem;
  }
  .ss-bottom-nav-wa:hover { background: #1da851 !important; color: #fff !important; }

}

/* Hide bottom nav on desktop */
@media (min-width: 769px) {
  .ss-bottom-nav { display: none !important; }
}
