/* ════════════════════════════════════════════════════════════════════════
   APP MODE: the phone layout.

   Everything here sits inside max-width:720px (the same breakpoint the tab bar
   uses), so desktop and tablet never see it. The aim is an app, not a long
   web page: long card grids become swipeable rails, long copy folds behind
   "Read more", course pages get a sticky section switcher, and the four
   floating buttons collapse into one "Talk" tab. Nothing is removed from the
   HTML, so search engines still read the whole page.

   Paired with assets/js/app-mobile.js, which adds the rail dots, folds, the
   section chips and the Talk / More sheets. Without JS the rails still swipe.
   ════════════════════════════════════════════════════════════════════════ */

@media (max-width: 720px) {

  /* Full-bleed rails use 100vw, which can round a pixel past the screen */
  html.app-on, html.app-on body { overflow-x: clip; }

  /* ── Rhythm: app screens are denser than web pages ─────────────────── */
  .section { padding: 40px 0; }
  .section-heading { margin-bottom: 20px; }
  .section-heading h2, .section h2 { font-size: clamp(26px, 7.4vw, 32px); line-height: 1.12; }
  .section-heading p { font-size: 15px; }
  .hero { min-height: 0; }
  .hero-inner { padding: 28px 18px 18px; }
  .hero h1 { font-size: clamp(30px, 8.6vw, 38px); }
  .hero .eyebrow { font-size: 11px; }

  /* ── Rails: long card grids become horizontal swipe lists ──────────── */
  .why-grid,
  .ttc-grid,
  .course-grid,
  .steps-grid,
  .post-grid,
  .cert-assurance,
  .bjy-fee-cards,
  .course-gallery,
  .special-sessions-grid,
  .exc-grid,
  .apply-steps,
  .intl-grid,
  .dl-plan,
  #sec-accommodation [data-lb-group="Accommodation"],
  .app-rail {
    display: flex !important;
    flex-wrap: nowrap !important;
    grid-template-columns: none !important;
    gap: 12px !important;
    overflow-x: auto;
    overflow-y: hidden;
    overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: 16px;
    width: 100vw !important;
    max-width: none !important;
    margin-left: calc(50% - 50vw) !important;
    margin-right: calc(50% - 50vw) !important;
    padding: 4px 16px 14px !important;
    box-sizing: border-box;
    max-height: none !important;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .why-grid::-webkit-scrollbar,
  .ttc-grid::-webkit-scrollbar,
  .course-grid::-webkit-scrollbar,
  .steps-grid::-webkit-scrollbar,
  .post-grid::-webkit-scrollbar,
  .cert-assurance::-webkit-scrollbar,
  .bjy-fee-cards::-webkit-scrollbar,
  .course-gallery::-webkit-scrollbar,
  .special-sessions-grid::-webkit-scrollbar,
  .exc-grid::-webkit-scrollbar,
  .apply-steps::-webkit-scrollbar,
  .intl-grid::-webkit-scrollbar,
  .dl-plan::-webkit-scrollbar,
  #sec-accommodation [data-lb-group="Accommodation"]::-webkit-scrollbar,
  .app-rail::-webkit-scrollbar { display: none; }

  .why-grid > *,
  .ttc-grid > *,
  .course-grid > *,
  .steps-grid > *,
  .post-grid > *,
  .cert-assurance > *,
  .bjy-fee-cards > *,
  .special-sessions-grid > *,
  .exc-grid > *,
  .apply-steps > *,
  .intl-grid > *,
  .dl-plan > *,
  .app-rail > * {
    flex: 0 0 84% !important;
    max-width: 84% !important;
    min-width: 0;
    margin: 0 !important;
    scroll-snap-align: start;
  }
  /* Short cards: show more of the next one so the swipe is obvious */
  .why-grid > *, .steps-grid > *, .apply-steps > *, .intl-grid > * {
    flex-basis: 72% !important; max-width: 72% !important;
  }
  /* The "show all countries" toggle means nothing once the grid is a rail */
  .intl-grid--collapsed > * { display: block !important; }
  .intl-more-wrap { display: none !important; }

  /* Photo rails: fixed-height frames so the rail doesn't jump */
  .course-gallery > *,
  #sec-accommodation [data-lb-group="Accommodation"] > * {
    flex: 0 0 78% !important;
    max-width: 78% !important;
    height: 230px !important;
    margin: 0 !important;
    scroll-snap-align: start;
    border-radius: 14px;
    overflow: hidden;
    grid-column: auto !important; grid-row: auto !important;
  }
  .course-gallery > * img,
  #sec-accommodation [data-lb-group="Accommodation"] > * img {
    width: 100% !important; height: 100% !important; object-fit: cover;
  }

  /* Rail position dots (added by app-mobile.js) */
  .app-dots {
    display: flex; justify-content: center; gap: 6px;
    margin: 2px 0 6px; pointer-events: none;
  }
  .app-dots span {
    width: 6px; height: 6px; border-radius: 99px;
    background: color-mix(in srgb, var(--maroon) 25%, transparent);
    transition: width .2s, background .2s;
  }
  .app-dots span.on { width: 18px; background: var(--maroon); }
  .app-rail-count {
    display: block; text-align: right; margin: -4px 0 6px;
    font-size: 12px; font-weight: 600; color: var(--muted);
  }

  /* ── Folds: long copy collapses behind "Read more" ─────────────────── */
  .app-fold {
    position: relative;
    max-height: var(--fold-h, 300px);
    overflow: hidden;
  }
  .app-fold::after {
    content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 90px;
    background: linear-gradient(to bottom, transparent, var(--fold-bg, var(--cream)));
    pointer-events: none;
  }
  .app-fold.is-open { max-height: none; }
  .app-fold.is-open::after { display: none; }
  .app-fold-btn {
    display: inline-flex; align-items: center; gap: 6px;
    margin: 10px 0 4px; padding: 9px 16px;
    border: 1px solid var(--border); border-radius: 99px;
    background: var(--white); color: var(--maroon-dark);
    font: 600 14px/1 var(--sans); cursor: pointer;
  }
  .app-fold-btn svg { transition: transform .2s; }
  .app-fold-btn[aria-expanded="true"] svg { transform: rotate(180deg); }

  /* ── Course page: sticky section chips replace the floating menu ───── */
  .app-chips {
    position: sticky; top: var(--app-head, 68px); z-index: 45;
    display: flex; gap: 8px; overflow-x: auto;
    padding: 10px 16px;
    background: rgba(253, 249, 245, .97);
    backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    scrollbar-width: none;
  }
  .app-chips::-webkit-scrollbar { display: none; }
  .app-chips a {
    flex: 0 0 auto; padding: 8px 14px; border-radius: 99px;
    border: 1px solid var(--border); background: var(--white);
    color: var(--ink); font: 600 13px/1 var(--sans); text-decoration: none;
    white-space: nowrap;
  }
  .app-chips a.on { background: var(--maroon-dark); border-color: var(--maroon-dark); color: #fff; }
  body.has-app-chips .page-toc { display: none !important; }
  body.has-app-chips [id^="sec-"] { scroll-margin-top: calc(var(--app-head, 68px) + 58px); }

  /* Course cards inside rails: a teaser, the full story is one tap away */
  .course-grid .cc-summary {
    display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
  }
  .course-grid .cc-points li:nth-child(n+4) { display: none; }
  .ttc-card .ov-body { display: -webkit-box; -webkit-line-clamp: 6; -webkit-box-orient: vertical; overflow: hidden; }

  /* Long lists: first five, then "See all" (app-mobile.js) */
  .app-cut > *:nth-child(n+6):not(.app-fold-btn) { display: none !important; }

  /* Newsletter: the email box grew to ~140px tall when the row stacked */
  .nl-row { flex-direction: column; }
  .nl-row input[type="email"] { flex: 0 0 auto !important; height: 48px; }
  .nl-btn { width: 100%; }

  /* ── Homepage batches: first three rows, "See all" reveals the rest ── */
  .batch-table-wrap.app-short > .batch-row:nth-of-type(n+4) { display: none; }

  /* ── Footer: link columns become tap-to-open rows ──────────────────── */
  .footer-inner > div:not(.footer-brand) { border-top: 1px solid rgba(255,255,255,.12); }
  .footer-inner > div:not(.footer-brand) > h3 {
    display: flex; justify-content: space-between; align-items: center;
    margin: 0; padding: 14px 0; cursor: pointer;
  }
  .footer-inner > div:not(.footer-brand) > h3::after {
    content: "+"; font: 400 22px/1 var(--sans); opacity: .7;
  }
  .footer-inner > div.is-open > h3::after { content: "–"; }
  .footer-inner > div:not(.footer-brand) > ul { display: none; padding-bottom: 12px; }
  .footer-inner > div.is-open > ul { display: block; }
  .footer-inner { gap: 0 !important; }
  .footer-brand { padding-bottom: 18px; }
  .footer-brand p { font-size: 14px; }

  /* ── One floating thing, not four ───────────────────────────────────── */
  html.app-on .wa-widget,
  html.app-on .share-fab,
  html.app-on .oyc-launch,
  html.app-on .oyc-launch-label,
  html.app-on .oyc-tab,
  html.app-on .oyc-invite { display: none !important; }
  /* The chat panel still opens full-screen from the Talk tab */
  html.app-on .oyc { left: 0; right: 0; bottom: 0; }

  /* ── Tab bar: Home · Courses · [Talk] · Reviews · More ─────────────── */
  html.app-on .mobile-tabbar { height: calc(62px + env(safe-area-inset-bottom, 0px)); }
  html.app-on .tabbar-item { flex: 1 1 0; min-width: 0; font-size: 10.5px; position: relative; background: none; border: 0; font-family: var(--sans); cursor: pointer; }
  html.app-on .tabbar-item--talk { color: var(--maroon-dark); }
  html.app-on .tabbar-item--talk .talk-bubble {
    width: 46px; height: 30px; border-radius: 99px;
    display: grid; place-items: center;
    background: var(--maroon-dark); color: #fff;
  }
  html.app-on .tabbar-item--talk .talk-bubble svg { opacity: 1; }
  html.app-on .tabbar-item .app-dot {
    position: absolute; top: 4px; right: calc(50% - 20px);
    width: 9px; height: 9px; border-radius: 50%;
    background: #25d366; box-shadow: 0 0 0 2px var(--cream);
  }
  html.app-on .tabbar-item--talk .app-dot { top: 3px; right: calc(50% - 26px); }

  /* ── Course page booking bar: price + Book + WhatsApp, one strip ───── */
  html.app-on .mobile-book-bar { padding: 10px 14px; gap: 10px; }
  html.app-on .mobile-book-bar .mbb-price { min-width: 0; flex: 1 1 auto; }
  html.app-on .mobile-book-bar .mbb-btn { flex: 0 0 auto; padding-inline: 16px; white-space: nowrap; }
  /* Labelled Live chat button (opens the website chat, not WhatsApp) */
  html.app-on .mobile-book-bar .mbb-wa {
    flex: 0 0 auto; min-width: 64px; height: 48px; padding: 4px 8px; border-radius: 12px;
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
    background: #fff; color: var(--maroon-dark); border: 0; cursor: pointer; font-family: var(--sans);
  }
  html.app-on .mobile-book-bar .mbb-wa-ico { position: relative; display: grid; place-items: center; }
  html.app-on .mobile-book-bar .mbb-wa svg { width: 20px; height: 20px; }
  html.app-on .mobile-book-bar .mbb-wa-dot {
    position: absolute; top: -2px; right: -4px; width: 8px; height: 8px; border-radius: 50%;
    background: #25d366; box-shadow: 0 0 0 2px #fff;
  }
  html.app-on .mobile-book-bar .mbb-wa-lbl { font: 700 10.5px/1 var(--sans); letter-spacing: .01em; color: var(--maroon-dark); }
  /* Narrow phones: give the batch picker room to show the whole date */
  @media (max-width: 390px) {
    html.app-on .mobile-book-bar { padding-inline: 10px; gap: 7px; }
    html.app-on .mobile-book-bar .mbb-btn { padding-inline: 11px !important; }
    html.app-on .mobile-book-bar .mbb-wa { min-width: 54px; padding-inline: 5px; }
    html.app-on .mobile-book-bar .mbb-label { letter-spacing: .04em; white-space: nowrap; }
  }

  /* ── Bottom sheets (Talk / More / Install) ──────────────────────────── */
  .app-sheet-scrim {
    position: fixed; inset: 0; z-index: 990;
    background: rgba(24,10,0,.42);
    opacity: 0; pointer-events: none; transition: opacity .2s;
  }
  .app-sheet {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 991;
    max-height: 86vh; overflow-y: auto;
    background: var(--cream); color: var(--ink);
    border-radius: 22px 22px 0 0;
    padding: 10px 18px calc(22px + env(safe-area-inset-bottom, 0px));
    transform: translateY(105%); transition: transform .26s cubic-bezier(.2,.8,.2,1);
    box-shadow: 0 -10px 40px rgba(0,0,0,.2);
  }
  .app-sheet.is-open { transform: none; }
  .app-sheet.is-open + .app-sheet-scrim, .app-sheet-scrim.is-open { opacity: 1; pointer-events: auto; }
  .app-sheet-grip { width: 40px; height: 4px; border-radius: 4px; background: var(--border); margin: 0 auto 14px; }
  .app-sheet h3 { font-size: 22px; margin: 0 0 4px; }
  .app-sheet .app-sheet-sub { margin: 0 0 14px; color: var(--muted); font-size: 14px; }
  .app-sheet-list { display: grid; gap: 8px; }
  .app-sheet-list a, .app-sheet-list button {
    display: flex; align-items: center; gap: 14px; width: 100%;
    padding: 13px 14px; border-radius: 14px;
    background: var(--white); border: 1px solid var(--border);
    color: var(--ink); text-decoration: none; text-align: left;
    font: 600 15px/1.25 var(--sans); cursor: pointer;
  }
  .app-sheet-list small { display: block; font-weight: 400; font-size: 12.5px; color: var(--muted); margin-top: 2px; }
  .app-sheet-list .ico {
    flex: 0 0 40px; width: 40px; height: 40px; border-radius: 12px;
    display: grid; place-items: center; font-size: 19px;
    background: var(--light-bg); color: var(--maroon-dark);
  }
  .app-sheet-list .ico--wa { background: #25d366; color: #fff; }
  .app-sheet-list .ico svg { width: 20px; height: 20px; }
  .app-sheet-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
  .app-sheet-grid a, .app-sheet-grid button {
    display: flex; flex-direction: column; align-items: center; gap: 6px;
    padding: 14px 6px; border-radius: 14px;
    background: var(--white); border: 1px solid var(--border);
    color: var(--ink); text-decoration: none;
    font: 600 12.5px/1.2 var(--sans); text-align: center; cursor: pointer;
  }
  .app-sheet-grid .ico { font-size: 22px; line-height: 1; }
  .app-sheet-section { margin: 18px 0 8px; font: 700 11px/1 var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
  .app-install-card {
    display: flex; align-items: center; gap: 12px; margin-top: 16px;
    padding: 14px; border-radius: 16px;
    background: var(--maroon-dark); color: #fff;
  }
  .app-install-card img { width: 44px; height: 44px; border-radius: 12px; background: #fff; }
  .app-install-card strong { display: block; font-size: 15px; color: #fff; }
  .app-install-card span { font-size: 12.5px; opacity: .85; color: #fff; }
  .app-install-card button {
    margin-left: auto; padding: 9px 14px; border-radius: 99px; border: 0;
    background: #fff; color: var(--maroon-dark); font: 700 13px/1 var(--sans); cursor: pointer;
  }
  .app-ios-steps { margin: 6px 0 0; padding-left: 20px; font-size: 15px; line-height: 1.7; }
}

/* ════════════════════════════════════════════════════════════════════════
   APP MODE, part 2: the rest of the site (about, retreats, reviews, contact,
   blog, FAQs, shop, guides and policies). Same rules as above: rails for
   card grids, folds/clamps for long copy, tap-to-open for long lists.
   Rail selectors here are mirrored in RAILS2 in app-mobile.js.
   ════════════════════════════════════════════════════════════════════════ */
@media (max-width: 720px) {

  /* ── More rails ─────────────────────────────────────────────────────── */
  .teacher-detail-grid, .teacher-grid, .cert-detail-grid, .values-grid,
  .testimonial-grid, .rt-itin, .rt-steps, .review-grid, .vr-grid,
  .calendly-cards, .arrival-grid, .post-sidebar {
    display: flex !important; flex-wrap: nowrap !important; flex-direction: row !important;
    grid-template-columns: none !important;
    gap: 12px !important;
    overflow-x: auto; overflow-y: hidden;
    overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory; scroll-padding-inline: 16px;
    width: 100vw !important; max-width: none !important;
    margin-left: calc(50% - 50vw) !important; margin-right: calc(50% - 50vw) !important;
    padding: 4px 16px 14px !important; box-sizing: border-box;
    align-items: stretch;
    scrollbar-width: none; -webkit-overflow-scrolling: touch;
  }
  .teacher-detail-grid::-webkit-scrollbar, .teacher-grid::-webkit-scrollbar, .cert-detail-grid::-webkit-scrollbar,
  .values-grid::-webkit-scrollbar, .testimonial-grid::-webkit-scrollbar, .rt-itin::-webkit-scrollbar,
  .rt-steps::-webkit-scrollbar, .review-grid::-webkit-scrollbar, .vr-grid::-webkit-scrollbar,
  .calendly-cards::-webkit-scrollbar, .arrival-grid::-webkit-scrollbar, .post-sidebar::-webkit-scrollbar { display: none; }

  .teacher-detail-grid > *, .teacher-grid > *, .cert-detail-grid > *, .values-grid > *,
  .testimonial-grid > *, .rt-itin > *, .rt-steps > *, .review-grid > *,
  .calendly-cards > *, .arrival-grid > *, .post-sidebar > * {
    flex: 0 0 84% !important; max-width: 84% !important; min-width: 0;
    margin: 0 !important; scroll-snap-align: start;
    grid-column: auto !important; grid-row: auto !important;
  }
  .values-grid > *, .rt-steps > * { flex-basis: 74% !important; max-width: 74% !important; }
  /* Video shorts are portrait: show one and a half so the swipe is obvious */
  .vr-grid > * { flex: 0 0 62% !important; max-width: 62% !important; margin: 0 !important; scroll-snap-align: start; }
  .vr-grid:not(.vr-grid--shorts) > * { flex-basis: 84% !important; max-width: 84% !important; }
  .post-sidebar { position: static !important; top: auto !important; }

  /* Retreat itinerary: each day is a card in the rail, not a timeline */
  .rt-itin > .rt-itin-day {
    display: flex !important; flex-direction: column !important;
    background: var(--white); border: 1px solid var(--border); border-radius: 16px;
    overflow: hidden; padding: 0 !important;
  }
  .rt-itin-day .rt-itin-marker { display: none !important; }
  .rt-itin-day .rt-itin-media { order: -1; width: 100% !important; height: 170px; margin: 0 !important; }
  .rt-itin-day .rt-itin-media img { width: 100%; height: 100%; object-fit: cover; border-radius: 0 !important; }
  .rt-itin-day .rt-itin-body { padding: 14px 16px 16px !important; }
  .rt-itin-day .rt-itin-daylabel {
    display: inline-block; margin-bottom: 6px; padding: 4px 10px; border-radius: 99px;
    background: var(--light-bg); color: var(--maroon-dark); font: 700 11.5px/1.2 var(--sans);
  }

  /* Cards with long bios / quotes: a few lines, "more" opens the rest */
  .app-clamp { max-height: calc(var(--clamp, 5) * 1.6em); overflow: hidden; line-height: 1.6;
    -webkit-mask-image: linear-gradient(#000 60%, transparent); mask-image: linear-gradient(#000 60%, transparent); }
  .app-clamp.is-open { max-height: none; -webkit-mask-image: none; mask-image: none; }
  .app-clamp-btn {
    display: inline-block; margin-top: 6px; padding: 0; border: 0; background: none;
    color: var(--maroon-dark); font: 600 13.5px/1.3 var(--sans); cursor: pointer; text-decoration: underline;
    text-underline-offset: 3px;
  }
  .teacher-detail-img { height: 260px; overflow: hidden; }
  .teacher-detail-img img { width: 100%; height: 100%; object-fit: cover; object-position: top; }

  /* ── Two-up grids: small tiles that read fine side by side ──────────── */
  .about-stats-grid, .contact-cards, .climate-grid {
    display: grid !important; grid-template-columns: 1fr 1fr !important; gap: 10px !important;
  }
  .about-stats-grid > *:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .contact-cards > *, .climate-grid > *, .about-stats-grid > * { min-width: 0; padding: 14px 12px !important; }
  .contact-cards { margin-top: 20px !important; }
  .contact-cards > * { font-size: 13px; word-break: break-word; }

  /* ── Shop: two products per row, like any store app ──────────────────── */
  .product-grid { display: grid !important; grid-template-columns: 1fr 1fr !important; gap: 10px !important; }
  .product-card { border-radius: 14px; overflow: hidden; min-width: 0; display: flex; flex-direction: column; }
  .product-card > img { width: 100%; height: auto !important; aspect-ratio: 1 / 1; object-fit: cover; }
  .product-card .product-body { padding: 10px !important; display: flex; flex-direction: column; gap: 4px; flex: 1; }
  .product-card .eyebrow { font-size: 9.5px; }
  .product-card h3 { font-size: 14.5px !important; line-height: 1.25; margin: 0 !important; }
  .product-card .product-body > p { font-size: 12.5px; margin: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .product-card .price-row { display: block !important; margin: 4px 0 0 !important; }
  .product-card .price-row strong { font-size: 15px; display: block; }
  .product-card .price-row span { font-size: 11px; }
  .product-card .card-actions { margin-top: auto !important; padding-top: 8px; display: flex; flex-direction: column-reverse !important; gap: 6px; align-items: stretch !important; }
  .product-card .card-actions .btn { width: 100%; padding: 9px 8px; font-size: 12.5px; }
  .product-card .card-actions .text-link { font-size: 12px; text-align: center; }
  .product-card .card-actions > span:empty { display: none; }

  /* ── FAQ hub: search on top, topics as tap-to-open rows ──────────────── */
  .faq-page-layout { display: block !important; }
  .faq-cat-nav {
    position: sticky !important; top: var(--app-head, 68px) !important; z-index: 40;
    max-height: none !important; overflow: visible !important;
    margin: 0 -16px 14px; padding: 10px 16px !important;
    background: rgba(253, 249, 245, .97); border-bottom: 1px solid var(--border);
  }
  .faq-cat-nav > h3, .faq-cat-nav > ul { display: none !important; }
  .faq-cat-block { margin: 0 0 10px !important; border: 1px solid var(--border); border-radius: 14px; background: var(--white); overflow: hidden; }
  .faq-cat-block > h3 {
    display: flex; align-items: center; justify-content: space-between; gap: 10px;
    margin: 0 !important; padding: 15px 16px; cursor: pointer; font-size: 17px;
  }
  .faq-cat-block > h3 .app-count { margin-left: auto; font: 600 12px/1 var(--sans); color: var(--muted); }
  .faq-cat-block > h3::after { content: ""; width: 9px; height: 9px; border-right: 2px solid var(--maroon); border-bottom: 2px solid var(--maroon); transform: rotate(45deg); margin: -4px 4px 0 0; transition: transform .2s; }
  .faq-cat-block.is-open > h3::after { transform: rotate(-135deg); margin-top: 4px; }
  .faq-cat-block > .faq-list { display: none !important; padding: 0 12px 12px; }
  .faq-cat-block.is-open > .faq-list, body.app-faq-search .faq-cat-block > .faq-list { display: flex !important; }
  .faq-group-title { margin: 22px 0 10px !important; }

  /* ── Guides & policies: each heading opens its own section ───────────── */
  .app-acc { border: 1px solid var(--border); border-radius: 14px; background: var(--white); margin: 0 0 10px; overflow: hidden; }
  .app-acc > .app-acc-head {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    width: 100%; margin: 0 !important; padding: 15px 16px; cursor: pointer;
    font-size: 18px !important; line-height: 1.3;
  }
  .app-acc > .app-acc-head::after { content: ""; flex: 0 0 9px; height: 9px; border-right: 2px solid var(--maroon); border-bottom: 2px solid var(--maroon); transform: rotate(45deg); margin-top: -4px; transition: transform .2s; }
  .app-acc.is-open > .app-acc-head::after { transform: rotate(-135deg); margin-top: 4px; }
  .app-acc > .app-acc-body { display: none; padding: 0 16px 14px; }
  .app-acc.is-open > .app-acc-body { display: block; }

  /* ── Blog posts: a reading progress line under the header ────────────── */
  .app-progress {
    position: fixed; left: 0; top: var(--app-head, 68px); z-index: 60;
    height: 3px; width: 100%; transform-origin: 0 50%; transform: scaleX(0);
    background: var(--maroon);
  }
  .post-body img { border-radius: 12px; }

  /* FAQ topic rows: the count must never wrap under the title */
  .faq-cat-block > h3 { font-size: 17px !important; line-height: 1.3 !important; }
  .faq-cat-block > h3 .app-count { flex: 0 0 auto; white-space: nowrap; }

  /* Hard-coded two-column layouts (e.g. /contact arrival + stay) stack on phones */
  main [style*="grid-template-columns:1fr 1fr"],
  main [style*="grid-template-columns: 1fr 1fr"] { grid-template-columns: 1fr !important; gap: 28px !important; }

  /* Contact tiles: two-up, so the values must be small enough to fit */
  .contact-cards > a strong { font-size: 15px !important; line-height: 1.3; overflow-wrap: anywhere; }
  .contact-cards > a span { font-size: 11px; }

  /* Footer newsletter: keep the same side gutter as the rest of the page */
  .site-footer .nl-signup { width: min(100% - 32px, var(--container)); }

  /* Retreat schedules: styles.css hides the timeline dot on phones, which
     dropped the activity text into the dot's 14px column. Two columns now. */
  .schedule-grid { gap: 0 !important; }
  .schedule-block { display: grid !important; grid-template-columns: 76px minmax(0, 1fr) !important; gap: 12px !important; }
  .schedule-block > .sched-dot { display: none !important; }

  /* "Read more" pills inside grid layouts must not stretch full width */
  .app-fold-btn { justify-self: start; align-self: flex-start; width: auto; }
}

/* ── Installed app (standalone PWA): no browser chrome to make room for ─ */
@media (display-mode: standalone) {
  .top-strip, .tpl-c .c-announce { display: none !important; }
  .tpl-c .c-header { padding-top: env(safe-area-inset-top, 0px); }
  .site-header { padding-top: env(safe-area-inset-top, 0px); }
}

/* ── Native feel: compact bar, back link, touch feedback, page transitions ─ */
@media (max-width: 720px) {
  /* One-line promo bar and a 56px app bar instead of a 68px web header */
  .tpl-c .c-announce { font-size: 12px; }
  .tpl-c .c-announce a { padding: 6px 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .tpl-c .c-bar { min-height: 56px; padding-block: 6px; gap: 6px; }
  .tpl-c .c-brand { gap: 8px; }
  .tpl-c .c-brand img { width: 38px; height: 38px; }
  .tpl-c .c-brand b { font-size: 15px; }
  .tpl-c .c-brand i { font-size: 9.5px; letter-spacing: .1em; }
  .tpl-c .c-brand small { display: none; }
  .tpl-c .c-login { min-height: 38px; padding: 8px 11px; box-shadow: none; }

  /* Breadcrumb trail → "‹ Parent" back link (built by app-mobile.js) */
  html.app-on .tpl-c nav[aria-label="Breadcrumb"] { display: none; }
  .app-back {
    display: inline-flex; align-items: center; gap: 2px; max-width: 100%;
    margin: 10px 0 2px -4px; padding: 6px 10px 6px 4px; border-radius: 999px;
    font: 600 14px/1.2 var(--c-sans, Inter, sans-serif); color: var(--c-saffron-d, #b84a10); text-decoration: none;
  }
  .app-back span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .tpl-c .cl-hero--page + .app-back { margin-left: 12px; }

  /* Touch: no grey flash, a soft press instead of hover */
  html.app-on { -webkit-tap-highlight-color: transparent; -webkit-text-size-adjust: 100%; }
  html.app-on a, html.app-on button, html.app-on summary { touch-action: manipulation; }
  .mobile-tabbar, .tpl-c .c-header, .app-chips { -webkit-user-select: none; user-select: none; }
  .c-btn, .btn, .tpl-c .c-login, .app-back, .mobile-tabbar a, .mobile-tabbar button,
  .course-card, .c-card, .cl-card { transition: transform .12s ease, opacity .12s ease; }
  .c-btn:active, .btn:active, .tpl-c .c-login:active, .app-back:active,
  .mobile-tabbar a:active, .mobile-tabbar button:active { transform: scale(.96); opacity: .85; }
  .course-card:active, .c-card:active, .cl-card:active { transform: scale(.985); }

  /* Page changes cross-fade like app screens; header and tab bar stay put */
  @view-transition { navigation: auto; }
  .tpl-c .c-header { view-transition-name: app-top; }
  .mobile-tabbar { view-transition-name: app-tabs; }
  ::view-transition-old(root), ::view-transition-new(root) { animation-duration: .18s; }
}
@media (max-width: 720px) and (prefers-reduced-motion: reduce) {
  @view-transition { navigation: none; }
}

/* App-only pieces never show on larger screens, even after a resize */
@media (min-width: 721px) {
  .app-chips, .app-dots, .app-rail-count, .app-fold-btn,
  .app-sheet, .app-sheet-scrim, .mbb-wa, .tabbar-item--talk, .tabbar-item--more,
  .app-clamp-btn, .app-progress, .app-bookbar, .app-back { display: none !important; }
  .app-clamp { max-height: none !important; -webkit-mask-image: none !important; mask-image: none !important; }
  .app-acc-body { display: block !important; }
  .app-fold { max-height: none !important; }
  .app-fold::after { display: none !important; }
}
