/* ============================================================
   Exegete — Shared Mobile Stylesheet
   Applies responsive fixes across all pages at ≤ 640px
   ============================================================ */

/* ── Hamburger button (hidden on desktop) ── */
.nav-hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  z-index: 1001;
}
.nav-hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: #e2c06e;
  border-radius: 2px;
  transition: all 0.25s ease;
}
.nav-hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-hamburger.open span:nth-child(2) { opacity: 0; }
.nav-hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── Mobile nav drawer ── */
.mobile-nav-drawer {
  display: none;
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(10, 18, 40, 0.98);
  z-index: 1000;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 28px;
  padding: 80px 32px 40px;
}
.mobile-nav-drawer.open { display: flex; }
.mobile-nav-drawer a,
.mobile-nav-drawer button {
  font-family: 'Inter', sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
  color: #c8d4e8;
  text-decoration: none;
  background: none;
  border: none;
  cursor: pointer;
  letter-spacing: 0.04em;
  transition: color 0.2s;
  text-align: center;
}
.mobile-nav-drawer a:hover,
.mobile-nav-drawer button:hover { color: #e2c06e; }
.mobile-nav-drawer .mobile-nav-research {
  background: #c9a84c;
  color: #0f1e3d !important;
  padding: 12px 32px;
  border-radius: 8px;
  font-weight: 700;
}
.mobile-nav-drawer .mobile-nav-divider {
  width: 40px;
  height: 1px;
  background: rgba(201,168,76,0.2);
}
.mobile-nav-close {
  position: absolute;
  top: 20px; right: 24px;
  background: none;
  border: none;
  color: #8a9bbf;
  font-size: 1.6rem;
  cursor: pointer;
  line-height: 1;
}

@media (max-width: 640px) {

  /* ── Nav ── */
  nav {
    padding: 14px 20px !important;
    position: sticky !important;
    top: 0 !important;
    z-index: 999 !important;
  }
  .nav-links,
  #main-nav-links { display: none !important; }
  .nav-hamburger { display: flex !important; }

  /* ── General spacing ── */
  section, .section { padding: 48px 20px !important; }
  h1 { font-size: 2rem !important; line-height: 1.2 !important; }
  h2 { font-size: 1.5rem !important; }

  /* ── Welcome page hero ── */
  .hero { padding: 48px 20px 40px !important; }
  .hero h1 { font-size: 2.2rem !important; }
  .hero p { font-size: 0.95rem !important; }
  .hero-btns { flex-direction: column !important; gap: 12px !important; width: 100% !important; }
  .hero-btns a, .hero-btns button,
  .btn-research-hero { width: 100% !important; text-align: center !important; }
  .scroll-hint { display: none !important; }

  /* ── Welcome page feature/step cards ── */
  .steps-grid, .features-grid, .cards-wrapper,
  .how-grid, .denom-grid {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
  }
  .mockup-wrap, .mockup-phone { display: none !important; }
  .step-content { padding: 0 !important; }

  /* ── How It Works section ── */
  .hiw-step {
    min-height: unset !important;
    padding: 52px 20px !important;
  }
  .hiw-step-inner {
    grid-template-columns: 1fr !important;
    gap: 32px !important;
    direction: ltr !important;
  }
  .hiw-step:nth-child(even) .hiw-step-inner {
    direction: ltr !important;
  }
  .hiw-mockup { display: none !important; }
  .hiw-content h2 { font-size: 1.6rem !important; }
  .hiw-content p { font-size: 0.9rem !important; }
  .hiw-detail { font-size: 0.85rem !important; }
  .step-eyebrow { margin-bottom: 12px !important; }

  /* ── Pricing page ── */
  .cards-wrapper {
    flex-direction: column !important;
    align-items: center !important;
  }
  .plan-card {
    width: 100% !important;
    max-width: 380px !important;
  }
  .comparison-section { display: none !important; }
  .billing-toggle { flex-wrap: wrap !important; gap: 8px !important; justify-content: center !important; }
  .page-header { padding: 40px 20px 32px !important; }
  .page-header h1 { font-size: 2rem !important; }

  /* ── Sermon upload page ── */
  .upload-card, .research-card, .form-card {
    padding: 24px 20px !important;
    margin: 0 16px !important;
  }
  .scripture-tags { flex-wrap: wrap !important; }
  .form-row { flex-direction: column !important; gap: 12px !important; }

  /* ── Research results page ── */
  .results-header {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 12px !important;
    padding: 20px !important;
  }
  .result-header { padding: 16px !important; }
  .result-body { padding: 16px !important; }
  .results-actions { flex-direction: column !important; gap: 10px !important; }
  .results-actions button, .results-actions a {
    width: 100% !important;
    text-align: center !important;
  }

  /* ── Sign in / Sign up ── */
  .auth-card, .signin-card, .signup-card {
    margin: 20px 16px !important;
    padding: 32px 24px !important;
  }
  .auth-wrap { padding: 20px 0 !important; }

  /* ── My Research page ── */
  .history-card, .session-card {
    padding: 20px !important;
  }
  .session-meta { flex-direction: column !important; gap: 6px !important; }
  .scripture-pills { flex-wrap: wrap !important; }

  /* ── Footer ── */
  footer {
    padding: 28px 20px !important;
    text-align: center !important;
  }
  .footer-links {
    flex-wrap: wrap !important;
    justify-content: center !important;
    gap: 16px !important;
  }

  /* ── Modals ── */
  .mv-modal {
    padding: 32px 24px !important;
    border-radius: 16px !important;
  }
  .mv-headline { font-size: 1.4rem !important; }

  /* ── Misc ── */
  .nav-logo span { display: none !important; }
  .eyebrow { font-size: 0.68rem !important; }
}
