/* ============================================
   WIZCART DESIGN SYSTEM — RESPONSIVE
   Mobile-first responsive overrides
   ============================================ */

/* ── Small phones (< 480px) ── */
@media (max-width: 479px) {
  h1 { font-size: var(--wz-fs-2xl); }
  h2 { font-size: var(--wz-fs-xl); }
  h3 { font-size: var(--wz-fs-lg); }

  .wz-container { padding: 0 var(--wz-space-3); }
  .wz-section { padding: var(--wz-space-8) 0; }

  .wz-grid-2,
  .wz-grid-3,
  .wz-grid-4 {
    grid-template-columns: 1fr;
  }

  .wz-footer-grid {
    grid-template-columns: 1fr;
    gap: var(--wz-space-6);
  }

  .wz-btn-lg {
    padding: var(--wz-space-3) var(--wz-space-6);
    font-size: var(--wz-fs-sm);
    width: 100%;
  }
}

/* ── Phones (< 768px) ── */
@media (max-width: 767px) {
  .wz-hamburger { display: flex; }

  .wz-nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: var(--wz-primary);
    flex-direction: column;
    align-items: flex-start;
    padding: var(--wz-space-16) var(--wz-space-6) var(--wz-space-6);
    gap: var(--wz-space-1);
    transition: right var(--wz-transition-base);
    z-index: var(--wz-z-fixed);
    overflow-y: auto;
    box-shadow: -4px 0 20px rgba(0, 0, 0, 0.3);
  }

  .wz-nav-links.active { right: 0; }

  .wz-nav-links a {
    width: 100%;
    padding: var(--wz-space-3) var(--wz-space-4);
    font-size: var(--wz-fs-base);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  }

  .wz-nav-search { display: none; }

  .wz-nav-search-mobile {
    display: block;
    width: 100%;
    padding: var(--wz-space-3) 0;
  }

  .wz-nav-search-mobile input {
    width: 100%;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: var(--wz-white);
    padding: var(--wz-space-3) var(--wz-space-4);
    border-radius: var(--wz-radius-md);
    font-size: var(--wz-fs-sm);
  }

  .wz-footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: var(--wz-space-6);
  }

  .wz-grid-2 { grid-template-columns: 1fr; }
  .wz-grid-3 { grid-template-columns: repeat(2, 1fr); }
  .wz-grid-4 { grid-template-columns: repeat(2, 1fr); }

  .hide-mobile { display: none !important; }
  .show-mobile { display: block !important; }
  .show-mobile-flex { display: flex !important; }

  .wz-table-wrap { margin: 0 calc(-1 * var(--wz-space-4)); width: calc(100% + var(--wz-space-8)); }
}

/* ── Tablets (768px - 1023px) ── */
@media (min-width: 768px) and (max-width: 1023px) {
  .wz-grid-4 { grid-template-columns: repeat(3, 1fr); }
  .wz-footer-grid { grid-template-columns: repeat(3, 1fr); }
  .hide-tablet { display: none !important; }
}

/* ── Desktop (≥ 768px) ── */
@media (min-width: 768px) {
  .show-mobile { display: none !important; }
  .show-mobile-flex { display: none !important; }
  .wz-nav-search-mobile { display: none !important; }
}

/* ── Large Desktop (≥ 1200px) ── */
@media (min-width: 1200px) {
  .wz-grid-4 { grid-template-columns: repeat(4, 1fr); }
}

/* ── No Horizontal Scroll (global safety) ── */
html, body {
  max-width: 100vw;
  overflow-x: hidden;
}

/* ── Touch-friendly targets ── */
@media (pointer: coarse) {
  .wz-btn { min-height: 44px; }
  .wz-form-control { min-height: 44px; font-size: 16px; }
  .wz-nav-links a { min-height: 44px; display: flex; align-items: center; }
}

/* ── Print ── */
@media print {
  .wz-navbar,
  .wz-footer,
  .wz-goto-top,
  .wz-toast,
  .wz-hamburger { display: none !important; }
  body { background: white; color: black; }
}
