/* Find Yahweh — Mobile layout (loads last, wins cascade) */

@media (max-width: 968px) {
  :root {
    --pad-x: 0.75rem;
    --pad-section: 2.5rem;
    --header-offset: 3.5rem;
    --gap-md: 1rem;
  }

  html {
    font-size: 15px;
    overflow-x: hidden;
  }

  body {
    overflow-x: hidden;
    min-width: 0;
    width: 100%;
  }

  .container {
    width: 100% !important;
    max-width: 100% !important;
    padding-inline: var(--pad-x) !important;
    margin-inline: auto;
  }

  /* HERO */
  .hero {
    display: block !important;
    min-height: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    padding-top: calc(var(--header-offset) + env(safe-area-inset-top, 0px));
    padding-bottom: calc(1.25rem + env(safe-area-inset-bottom, 0px));
    padding-inline: 0;
  }

  .hero__content.container {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    width: 100% !important;
    max-width: 100% !important;
    /* container class already adds pad-x — do NOT double-pad */
  }

  .hero__eyebrow {
    font-size: 0.52rem;
    letter-spacing: 0.07em;
    margin-bottom: 0.65rem;
  }

  .hero__title {
    margin-bottom: 0.65rem;
  }

  .hero__title-hebrew {
    font-size: 0.78rem;
    letter-spacing: 0.05em;
    margin-bottom: 0.4rem;
  }

  .hero__title-main {
    font-size: clamp(1.35rem, 10vw, 2.25rem) !important;
    letter-spacing: 0.02em !important;
    line-height: 1.15;
    word-break: break-word;
  }

  .hero__subtitle {
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 0.85rem;
    padding-inline: 0;
    min-height: 2rem;
    width: 100%;
    max-width: 100%;
  }

  .hero__verse,
  .hero__ancient {
    width: 100% !important;
    max-width: 100% !important;
    margin-inline: 0 !important;
    padding: 0.75rem !important;
    box-sizing: border-box;
  }

  .hero__verse blockquote {
    font-size: 0.85rem;
    line-height: 1.5;
  }

  .hero__ancient-hebrew {
    font-size: 0.72rem;
    letter-spacing: 0.04em;
    line-height: 1.55;
  }

  .hero__ancient-text {
    font-size: 0.8rem;
    line-height: 1.5;
  }

  .hero__scroll {
    display: none !important;
  }

  /* Journey nav — bleed to screen edges */
  .hero-journey {
    width: calc(100% + 2 * var(--pad-x));
    max-width: none;
    margin-inline: calc(-1 * var(--pad-x));
    margin-bottom: 0.85rem;
    overflow: hidden;
  }

  .hero-journey__track {
    display: flex !important;
    flex-wrap: nowrap !important;
    justify-content: flex-start !important;
    align-items: center;
    gap: 0.3rem;
    padding: 0.5rem var(--pad-x);
    border-radius: 0 !important;
    border-left: none !important;
    border-right: none !important;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .hero-journey__track::-webkit-scrollbar {
    display: none;
  }

  .hero-journey__line {
    display: none !important;
  }

  .hero-journey__link {
    flex: 0 0 auto;
    flex-direction: row;
    gap: 0.3rem;
    padding: 0.4rem 0.55rem;
    min-height: 38px;
  }

  .hero-journey__link svg {
    width: 16px;
    height: 16px;
  }

  .hero-journey__link span {
    font-size: 0.48rem;
    letter-spacing: 0.06em;
  }

  /* Buttons full width */
  .hero__actions {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 0.5rem !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
  }

  .hero__actions .btn {
    display: flex !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box;
    justify-content: center;
    align-items: center;
    padding: 0.8rem 0.65rem !important;
    font-size: 0.6rem !important;
    letter-spacing: 0.08em !important;
    min-height: 44px;
  }

  /* WELCOME MODAL — full screen */
  .welcome-modal {
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
    height: 100dvh !important;
    max-height: 100dvh !important;
    padding: 0 !important;
    overflow: hidden !important;
  }

  .welcome-modal__card {
    flex: 1 1 auto !important;
    width: 100% !important;
    max-width: 100% !important;
    min-height: 100dvh !important;
    max-height: 100dvh !important;
    margin: 0 !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
  }

  .welcome-modal__scroll {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding:
      calc(0.85rem + env(safe-area-inset-top, 0px))
      var(--pad-x)
      calc(0.85rem + env(safe-area-inset-bottom, 0px));
  }

  .welcome-modal__eyebrow {
    letter-spacing: 0.1em;
    font-size: 0.5rem;
  }

  .welcome-modal__hebrew {
    font-size: clamp(1.4rem, 9vw, 2rem);
    letter-spacing: 0.08em;
  }

  .welcome-modal__title {
    font-size: clamp(1rem, 4.5vw, 1.3rem);
  }

  .welcome-modal__desc {
    font-size: 0.82rem;
  }

  .welcome-modal__btn {
    width: 100%;
    min-height: 46px;
    padding: 0.7rem 0.75rem;
  }

  .welcome-modal__btn strong {
    font-size: 0.72rem;
  }

  .welcome-modal__btn small {
    font-size: 0.62rem;
  }

  .voice-select,
  .voice-preview-btn,
  .welcome-modal__skip {
    width: 100%;
  }

  /* Sections */
  .section {
    padding-block: var(--pad-section);
    width: 100%;
    overflow-x: hidden;
  }

  .section__title {
    font-size: clamp(1.2rem, 5vw, 1.65rem);
  }

  .section__label {
    font-size: 0.58rem;
    letter-spacing: 0.12em;
  }

  .lead {
    font-size: 0.92rem;
  }

  .scripture-quote {
    font-size: 0.95rem;
    padding: 0.75rem;
  }

  /* Grids */
  .content-grid,
  .messiah-content,
  .yahweh-showcase,
  .bible-grid,
  .trinity-grid,
  .creed-container,
  .footer__top,
  .commandments-great__grid,
  .commandments-eternal,
  .sources-grid,
  .facts-grid,
  .gospel-flow,
  .wisdom-grid,
  .faith-grid,
  .living-grid,
  .commandments-grid,
  .prayer-types,
  .stats-orbit,
  .aramaic-name__grid {
    grid-template-columns: 1fr !important;
    gap: var(--gap-md) !important;
  }

  .yahweh-image__frame {
    max-width: 100%;
  }

  /* Header */
  .nav__logo-text {
    font-size: 0.75rem;
  }

  .audio-toggle {
    width: 40px;
    height: 40px;
  }

  /* Docks */
  .experience-bar {
    left: 0.5rem;
    bottom: calc(0.65rem + env(safe-area-inset-bottom, 0px));
    top: auto;
    transform: none;
    flex-direction: row;
  }

  .experience-bar__btn span {
    display: none;
  }

  body.reader-active .experience-bar,
  body:has(.reader-player.active) .experience-bar {
    bottom: calc(5.75rem + env(safe-area-inset-bottom, 0px));
  }

  .reader-player__inner {
    display: flex;
    flex-direction: column;
    padding: 0.6rem var(--pad-x) calc(0.6rem + env(safe-area-inset-bottom, 0px));
    gap: 0.45rem;
  }

  .reader-player__progress-wrap {
    width: 100%;
    order: 2;
  }

  .reader-player__controls {
    justify-content: center;
    order: 3;
  }

  .reader-player__hint {
    display: none;
  }

  .back-to-top {
    bottom: calc(0.65rem + env(safe-area-inset-bottom, 0px));
    right: 0.65rem;
    width: 42px;
    height: 42px;
  }

  body.reader-active .back-to-top,
  body:has(.reader-player.active) .back-to-top {
    bottom: calc(5.75rem + env(safe-area-inset-bottom, 0px));
  }

  .summary-panel {
    padding: 0;
    align-items: flex-end;
  }

  .summary-panel__modal {
    width: 100%;
    max-width: 100%;
    max-height: 94dvh;
    border-radius: 0.75rem 0.75rem 0 0;
  }

  .summary-panel__actions {
    flex-direction: column;
  }

  .summary-panel__actions .btn {
    width: 100%;
  }
}

@media (max-width: 380px) {
  :root {
    --pad-x: 0.6rem;
  }

  html {
    font-size: 14px;
  }

  .hero__title-main {
    font-size: clamp(1.25rem, 11vw, 1.65rem) !important;
  }

  .nav__logo-text {
    display: none;
  }

  .hero__actions .btn {
    font-size: 0.55rem !important;
  }
}
