/* ============================================================
   THRIVE STEAM   mobile.css
   ONLY applies at max-width: 768px and below.
   Desktop styles are completely untouched.
   ============================================================ */

/* ── HAMBURGER BUTTON ── */
.nav__hamburger {
  display: none;
}

@media (max-width: 768px) {

  /* ── NAV ── */
  .nav {
    padding: 14px 5vw;
  }
  .nav.scrolled {
    padding: 12px 5vw;
  }
  .nav__links {
    display: none; /* hidden - replaced by drawer */
  }
  .nav__cta {
    display: none; /* hidden on mobile - CTA is in drawer */
  }
  .nav__hamburger {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 44px;
    height: 44px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    border-radius: var(--r-sm);
    z-index: 300;
    transition: background .2s;
  }
  .nav__hamburger:hover { background: var(--c-ink-10); }
  .nav__hamburger span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--c-ink);
    border-radius: 2px;
    transition: transform .3s ease, opacity .3s ease;
    transform-origin: center;
  }
  /* X state when open */
  .nav__hamburger.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav__hamburger.is-open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
  .nav__hamburger.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  /* ── MOBILE DRAWER ── */
  .nav__drawer {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: var(--c-paper);
    z-index: 250;
    display: flex;
    flex-direction: column;
    padding: 80px 8vw 48px;
    transform: translateX(100%);
    transition: transform .35s cubic-bezier(.4,0,.2,1);
    overflow-y: auto;
  }
  .nav__drawer.is-open {
    transform: translateX(0);
  }
  .nav__drawer-links {
    display: flex;
    flex-direction: column;
    gap: 0;
    flex: 1;
  }
  .nav__drawer-links a {
    font-family: var(--f-heading);
    font-size: 1.7rem;
    font-weight: 500;
    color: var(--c-ink);
    padding: 16px 0;
    border-bottom: 1px solid var(--c-ink-10);
    display: block;
    transition: color .2s, padding-left .2s;
  }
  .nav__drawer-links a:first-child { border-top: 1px solid var(--c-ink-10); }
  .nav__drawer-links a:hover { color: var(--c-sky); padding-left: 8px; }
  .nav__drawer-cta {
    margin-top: 32px;
    font-family: var(--f-ui);
    font-size: 1rem; font-weight: 500;
    background: var(--c-ink); color: var(--c-paper);
    padding: 16px 24px; border-radius: var(--r-pill);
    text-align: center; display: block;
    border: none; cursor: pointer;
  }

  /* ── HERO ── */
  .hero {
    padding: 100px 5vw 48px;
  }
  .hero__title {
    font-size: clamp(2.2rem, 9vw, 3rem);
    letter-spacing: -.5px;
    margin-bottom: 16px;
  }
  .hero__body {
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 24px;
  }
  .hero__actions {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }
  .hero__actions .btn {
    justify-content: center;
    padding: 16px 24px;
    font-size: .95rem;
  }
  .hero__meta {
    gap: 20px;
    margin-top: 28px;
    padding-top: 20px;
  }
  .hero__meta-item .n { font-size: 1.4rem; }
  .hero__meta-item .l { font-size: .6rem; }
  .hero__meta-sep { display: none; }

  /* ── TICKER ── */
  .ticker { padding: 10px 0; }
  .ticker__item { font-size: .68rem; padding: 0 18px; }

  /* ── SECTIONS ── */
  .section {
    padding: 48px 5vw;
  }
  .section__header {
    margin-bottom: 32px;
  }
  .section__title {
    font-size: clamp(1.65rem, 7vw, 2.2rem);
    line-height: 1.18;
  }
  .section__sub {
    font-size: .95rem;
    line-height: 1.68;
  }
  .section__label {
    font-size: .65rem;
    letter-spacing: 1.8px;
  }

  /* ── WHY GRID (fixes section not showing on mobile) ── */
  .why__grid {
    display: flex;
    flex-direction: column;
    grid-template-columns: none;
    gap: 24px;
  }
  .about__aside {
    display: flex;
    flex-direction: column;
    grid-template-columns: none;
    width: 100%;
    max-width: 100%;
    gap: 12px;
  }
  .about__fact {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }

  /* ── STEAM STRIP ── */
  .steam-strip {
    display: flex;
    flex-direction: column;
    margin-top: 32px;
    border-radius: var(--r-md);
    gap: 2px;
    width: 100%;
    max-width: 100%;
  }
  .steam-pillar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    padding: 14px 16px;
    gap: 12px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
  .sp-letter {
    font-size: 1.4rem;
    flex: 0 0 auto;
  }
  .sp-word {
    font-size: .65rem;
    letter-spacing: 1px;
    flex: 0 0 auto;
  }
  .sp-desc {
    display: block;
    opacity: 1;
    visibility: visible;
    max-height: none;
    font-size: .8rem;
    margin-top: 4px;
    flex: 0 0 100%;
    width: 100%;
  }

  /* ── WHY / ABOUT FACTS ── */
  .why__prose p { font-size: .97rem; }
  .about__fact-num { font-size: 1.9rem; }
  .about__fact h4 { font-size: .9rem; }
  .about__fact p { font-size: .82rem; }

  /* Safety net: prevent any leftover desktop grid widths from
     pushing content off-screen and getting clipped */
  .why, .section, .section__header, section {
    max-width: 100%;
    overflow-x: hidden;
  }

  /* ── HOW WE WORK ── */
  .rhythm__step {
    padding: 20px;
  }
  .rhythm__step-num { font-size: 2rem; }
  .rhythm__step-title { font-size: 1.15rem; }
  .rhythm__step p { font-size: .92rem; }

  .how__list {
    grid-template-columns: 1fr;
    border-top: none;
  }
  .how__item {
    padding: 20px 0;
    border-right: none;
    border-top: 1px solid var(--c-ink-10);
  }
  .how__item:nth-child(3n) { border-right: none; }
  .how__item h3 { font-size: .97rem; }
  .how__item p { font-size: .9rem; }

  /* ── MATERIALS ── */
  .mat-card { padding: 20px; }
  .mat-card h3 { font-size: 1rem; }
  .mat-card p { font-size: .88rem; }

  /* ── T-WORKS ── */
  .tworks__banner {
    font-size: .68rem;
    letter-spacing: 1px;
    padding: 12px 5vw;
  }
  .tworks__prose p { font-size: .94rem; }
  .tw-feat { padding: 14px; gap: 12px; }
  .tw-feat h4 { font-size: .9rem; }
  .tw-feat p { font-size: .82rem; }

  /* ── LIBRARY ── */
  .library__prose p { font-size: .94rem; }
  .library__visual {
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }
  .library__count { grid-column: span 3; padding: 16px; }
  .library__count .num { font-size: 2rem; }

  .book-themes__heading { font-size: 1.25rem; }
  .book-theme-card { padding: 16px; }
  .book-theme-card__title { font-size: .92rem; }
  .book-theme-card p:last-child { font-size: .84rem; }

  /* ── THEMES GRID ── */
  .themes__grid {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }
  .theme-card__body { padding: 12px; }
  .theme-card__name { font-size: .92rem; }
  .theme-card__sub { font-size: .7rem; }

  /* ── FOR PARENTS ── */
  .parents {
    padding: 56px 5vw 48px;
  }
  .parents__title {
    font-size: clamp(1.7rem, 8vw, 2.6rem);
    margin-bottom: 16px;
  }
  .parents__lead {
    font-size: .97rem;
    margin-bottom: 24px;
  }
  .parents__point {
    padding: 14px 16px;
    gap: 12px;
  }
  .parents__point-text { font-size: .93rem; }
  .parents__conclusion { font-size: .93rem; }
  .parents__actions {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }
  .parents__actions .btn {
    justify-content: center;
    padding: 16px 24px;
  }

  /* ── TEAM ── */
  .team__row {
    grid-template-columns: 100px 1fr;
    gap: 16px;
    padding: 28px 0;
  }
  .team__photo-img {
    aspect-ratio: 3/4;
    max-width: 100px;
  }
  .team__name { font-size: 1.2rem; }
  .team__desc { font-size: .9rem; line-height: 1.65; }
  .team__credential { font-size: .68rem; padding: 4px 10px; }

  /* ── GALLERY ── */
  .gallery__grid {
    grid-template-columns: 1fr 1fr;
    grid-auto-rows: 130px;
    gap: 6px;
  }
  .gc--wide { grid-column: span 2; }
  .gc--tall { grid-row: span 1; }
  .gallery__cell-caption {
    opacity: 1; /* always visible on mobile, no hover */
    font-size: .65rem;
    padding: 18px 10px 8px;
  }

  /* ── FAQ ── */
  .faq__q { font-size: .95rem; padding: 18px 0; }
  .faq__a { font-size: .93rem; padding-right: 0; padding-bottom: 18px; }

  /* ── CONTACT ── */
  .contact { padding: 48px 5vw 36px; }
  .contact__left h2 { font-size: clamp(1.8rem, 8vw, 2.6rem); }
  .contact__left p { font-size: .94rem; }
  .contact__item { font-size: .9rem; padding: 12px 14px; }

  /* ── FOOTER ── */
  .footer__links { gap: var(--s-3); }
  .footer__links a { font-size: .72rem; }
}

/* ── SMALL PHONES (390px and under) ── */
@media (max-width: 420px) {
  .hero { padding: 90px 5vw 40px; }
  .hero__title { font-size: clamp(2rem, 10vw, 2.6rem); }

  .themes__grid { grid-template-columns: 1fr; gap: 10px; }
  .theme-card__image { aspect-ratio: 16/9; }

  .team__row { grid-template-columns: 80px 1fr; gap: 12px; }
  .team__photo-img { max-width: 80px; }
  .team__name { font-size: 1.1rem; }

  .library__visual { grid-template-columns: repeat(2, 1fr); }
  .library__count { grid-column: span 2; }

  .book-themes__grid { grid-template-columns: 1fr; }

  .gallery__grid { grid-auto-rows: 110px; }

  .section { padding: 40px 5vw; }
  .section__title { font-size: clamp(1.5rem, 9vw, 2rem); }

  .parents { padding: 48px 5vw 40px; }
  .parents__title { font-size: clamp(1.6rem, 9vw, 2.2rem); }
}

  .hero__value { font-size: .72rem; margin-top: 12px; }