/*
 * =============================================
 *  RESPONSIVE.CSS — Authentic Art & Gallery
 *  Covers all pages at every breakpoint.
 *  Loaded last so it can override page-specific
 *  CSS without !important spam.
 * =============================================
 */

/* ============================================================
   SMALL DESKTOP / NARROW VIEWPORT  ≤ 1080px
   ============================================================ */
@media (max-width: 1080px) {
  /* Nav: hide Instagram text, tighten gaps */
  .nav { padding: 18px var(--pad); }
  .nav-social { display: none; }
  .nav-links { gap: 20px; font-size: .88rem; }

  /* Footer: 2-col */
  .footer-top { grid-template-columns: 1fr 1fr; gap: 28px; }
}

/* ============================================================
   TABLET  ≤ 820px
   ============================================================ */
@media (max-width: 820px) {

  /* ---- Global spacing ---- */
  section { padding: clamp(50px, 8vw, 90px) 0; }

  /* ---- Nav ---- */
  .nav { padding: 16px var(--pad); }
  .nav-links,
  .nav-social,
  header.nav .switches { display: none; }
  .nav-burger { display: flex; }

  /* ---- Hero ---- */
  .hero { padding-top: 90px; padding-bottom: 100px; min-height: 90svh; }
  .hero-strip {
    grid-template-columns: 1fr;
    text-align: left;
    gap: 18px;
    padding-top: 20px;
  }
  .hero-title { font-size: clamp(2.8rem, 10vw, 5.5rem); }
  .hero-ghost-word { font-size: clamp(3rem, 14vw, 7rem); }
  .scroll-indicator { bottom: 16px; }

  /* ---- Runband ---- */
  .runband { min-height: 60vh; }
  .next-run-pill { position: static; margin-top: 30px; justify-content: space-between; }

  /* ---- Services teaser grid ---- */
  .teaser-grid { grid-template-columns: 1fr; }
  .teaser-card { min-height: 280px; }

  /* ---- Testimonials ---- */
  .testi-grid { grid-template-columns: 1fr 1fr; }
  .testi-head { flex-direction: column; align-items: flex-start; gap: 10px; }
  .testi-head p { max-width: 100%; }

  /* ---- Halisi section ---- */
  .halisi-section { padding: clamp(60px, 10vw, 100px) 0; }
  .halisi-logo-mark { font-size: clamp(5rem, 20vw, 10rem); }
  .halisi-title { font-size: clamp(2.2rem, 7vw, 3.6rem); }

  /* ---- Footer ---- */
  .footer-top { grid-template-columns: 1fr; gap: 22px; align-items: start; }
  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  .footer-links {
    flex-direction: column;
    gap: 10px;
  }

  /* ---- About ---- */
  .about-grid { grid-template-columns: 1fr; gap: 24px; }
  .about-photos { grid-template-columns: 1fr; }
  .find-run-cta { flex-direction: column; align-items: flex-start; gap: 12px; }

  /* ---- Values grid ---- */
  .values-grid { grid-template-columns: 1fr; }

  /* ---- Services page stat bar ---- */
  .stat-bar { flex-direction: column; gap: 12px; }
  .stat-bar .line-mid { display: none; }
  .cities-grid { grid-template-columns: 1fr 1fr; }

  /* ---- Service detail ---- */
  .run-body { grid-template-columns: 1fr; gap: 36px; }
  .info-card { position: static; }
  .run-hero h1 { font-size: clamp(2.6rem, 9vw, 5rem); }

  /* ---- Shop ---- */
  .shop-feature { grid-template-columns: 1fr; }
  .products-row { grid-template-columns: 1fr 1fr; }
  .gear-photos { grid-template-columns: 1fr; }

  /* ---- History stats ---- */
  .history-stats { grid-template-columns: 1fr 1fr; }

  /* ---- Portfolio schedule ---- */
  .schedule-row { grid-template-columns: 1fr 1fr; row-gap: 8px; }
  .schedule-row .sr-btn { grid-column: 1 / 3; justify-self: start; margin-top: 8px; }

  /* ---- Other runs ---- */
  .other-runs .row { grid-template-columns: 1fr 1fr; }
}

/* ============================================================
   PHABLET / LARGE PHONE  ≤ 620px
   ============================================================ */
@media (max-width: 620px) {

  /* ---- Global ---- */
  :root { --pad: 18px; }
  section { padding: clamp(40px, 8vw, 70px) 0; }

  /* ---- Nav ---- */
  .nav { padding: 14px var(--pad); }

  /* ---- Hero ---- */
  .hero { padding-top: 80px; padding-bottom: 80px; }
  .hero-title { font-size: clamp(2.4rem, 11vw, 4.2rem); }
  .hero-ghost-word { font-size: clamp(2.4rem, 15vw, 5rem); top: 8%; }
  .hero-cta-row { margin-top: 24px; }

  /* ---- Testimonials: single column ---- */
  .testi-grid { grid-template-columns: 1fr; }
  .testi-card { padding: 28px 22px; }

  /* ---- Halisi ---- */
  .halisi-logo-mark { font-size: clamp(4rem, 22vw, 8rem); }
  .halisi-title { font-size: clamp(1.9rem, 8vw, 2.8rem); }
  .halisi-tags { gap: 8px; }
  .halisi-btn { width: 100%; justify-content: center; }

  /* ---- Services grid: single col ---- */
  .cities-grid { grid-template-columns: 1fr; }
  .city-card { min-height: 340px; padding: 38px 24px; }

  /* ---- Services hero on services.html ---- */
  .runs-hero { padding-top: 100px; }

  /* ---- Service detail ---- */
  .run-hero { padding-top: 100px; min-height: 60vh; }
  .run-hero h1 { font-size: clamp(2.2rem, 9vw, 3.8rem); }
  .run-badge { font-size: .78rem; padding: 8px 14px; }
  .run-hero .badges { gap: 8px; }
  .info-card { padding: 24px 18px; }
  .quote-list { grid-template-columns: 1fr; }
  .quote-banner { flex-direction: column; align-items: flex-start; }
  .other-runs .row { grid-template-columns: 1fr; }

  /* ---- Shop ---- */
  .products-row { grid-template-columns: 1fr; }
  .shop-hero h1 { font-size: clamp(2.2rem, 9vw, 3.4rem); }
  .cat-card h3 { font-size: clamp(2.4rem, 8vw, 3.8rem); }

  /* ---- About ---- */
  .about-hero { padding-top: 100px; }
  .photo-block { aspect-ratio: 4/3; }
  .value-card { padding: 28px 20px; }

  /* ---- Signup row ---- */
  .signup-row { flex-direction: column; }
  .signup-row input,
  .signup-row button { width: 100%; }
  .signup-row button { padding: 14px; }

  /* ---- Footer ---- */
  footer { padding: 44px 0 24px; }
  .footer-links a { word-break: break-all; }

  /* ---- Buttons ---- */
  .btn { padding: 14px 26px; font-size: .88rem; }

  /* ---- History ---- */
  .history-hero { padding-top: 100px; min-height: 50vh; }
  .history-hero h1 { font-size: clamp(2.4rem, 9vw, 4.4rem); }
  .history-stats { grid-template-columns: 1fr 1fr; }

  /* ---- Runband ---- */
  .runband { min-height: 50vh; }
  .runband .ghost { font-size: clamp(2rem, 7vw, 3.5rem); }
  .runband .solid { font-size: clamp(2.2rem, 8vw, 4rem); }
}

/* ============================================================
   SMALL PHONE  ≤ 480px
   ============================================================ */
@media (max-width: 480px) {

  /* ---- Tighter root padding ---- */
  :root { --pad: 14px; }

  /* ---- Nav brand logo ---- */
  .brand img { height: 24px; }

  /* ---- Hero ---- */
  .hero-title { font-size: clamp(2rem, 12vw, 3.4rem); line-height: 1.0; }
  .hero-ghost-word {
    font-size: clamp(2rem, 16vw, 4rem);
    -webkit-text-stroke: 0.5px var(--line);
  }

  /* ---- Halisi ---- */
  .halisi-logo-mark { font-size: clamp(3.5rem, 24vw, 7rem); }
  .halisi-inner { gap: 16px; }
  .halisi-title { font-size: clamp(1.6rem, 9vw, 2.4rem); }
  .halisi-badge { font-size: .68rem; padding: 5px 14px; }

  /* ---- Testimonials ---- */
  .testi-card { padding: 24px 16px; }
  .testi-head h2 { font-size: clamp(1.7rem, 6vw, 2.2rem); }

  /* ---- Service cards ---- */
  .city-card { padding: 30px 18px; min-height: 300px; }
  .city-card h3 { font-size: clamp(1.6rem, 6vw, 2.2rem); }

  /* ---- Price table: force horizontal scroll ---- */
  .price-table-wrap { -webkit-overflow-scrolling: touch; border: 1px solid var(--line); }

  /* ---- Stat bar ---- */
  .stat-bar { margin-top: 40px; }

  /* ---- History timeline ---- */
  .timeline::before { left: 16px; }
  .tl-item { grid-template-columns: 1fr; gap: 10px; padding: 30px 0; }
  .tl-dot { left: 12px; top: 4px; }
  .tl-year { padding-left: 34px; font-size: 1.3rem; }
  .tl-content h3 { font-size: clamp(1.2rem, 5vw, 1.6rem); }
  .history-stats { grid-template-columns: 1fr; }

  /* ---- Portfolio calendar ---- */
  .cal-item { width: min(300px, 85vw); padding: 20px 22px; }

  /* ---- Footer ---- */
  .footer-bottom { font-size: .78rem; }

  /* ---- Other runs: always single col ---- */
  .other-runs .row { grid-template-columns: 1fr; }

  /* ---- Mobile drawer improvements ---- */
  .mobile-drawer nav a { font-size: 1.6rem; }
}

/* ============================================================
   UTILITY: prevent body scroll when drawer is open
   ============================================================ */
body.drawer-open { overflow: hidden; }

/* ============================================================
   TOUCH: disable 3D tilt on mobile (handled in JS but backup)
   ============================================================ */
@media (hover: none) {
  .teaser-card,
  .testi-card,
  .halisi-inner {
    transform: none !important;
  }
}
