/* Leveret Drive — mobile pass.
   Every rule is gated inside a media query: desktop rendering is untouched.
   Loaded from each page's <helmet> and from SiteNav / SiteFooter. */

/* ---------- Global guards ---------- */
@media (max-width: 1024px) {
  /* clip, not hidden: `hidden` would turn body into the scroll container
     and break scroll-position listeners (sticky nav, reveals) */
  html, body { overflow-x: clip; max-width: 100%; }
  /* No decorative grid/flex track may force the page wider than the screen */
  img, svg, video, iframe:not([src*="player.vimeo"]) { max-width: 100%; }
}

/* ---------- Header / nav ---------- */
@media (max-width: 960px) {
  .ld-header { padding-left: clamp(16px, 4vw, 28px) !important; padding-right: clamp(16px, 4vw, 28px) !important; }
  .ld-header nav { gap: 14px !important; }
  .ld-header [data-logo] { height: 48px !important; width: 153px !important; }
  .ld-header [data-navcta] { padding: 0 18px !important; font-size: 13px !important; height: 44px !important; min-height: 44px !important; box-sizing: border-box !important; }
  .ld-burger { width: 44px !important; height: 44px !important; }
  .ld-util { gap: 16px !important; font-size: 12.5px !important; }
  .ld-util a { min-width: 40px; min-height: 40px; align-items: center; justify-content: center; }
  .ld-util a[href^="tel"] { min-width: 0; justify-content: flex-start; }
  .ld-header [data-navcta] { white-space: nowrap; }
}
@media (max-width: 560px) {
  /* On a phone the header's utility row is a phone number, not a social bar */
  .ld-util-phone-label { display: inline !important; }
  .ld-util > div:last-child { display: none !important; }
  .ld-util { justify-content: flex-end !important; font-size: 13px !important; }
  .ld-header [data-logo] { height: 40px !important; width: 128px !important; }
  .ld-header [data-navcta] { padding: 0 13px !important; font-size: 12px !important; letter-spacing: 0.02em !important; height: 40px !important; min-height: 40px !important; }
  .ld-header nav { gap: 10px !important; }
  .ld-burger { width: 40px !important; height: 40px !important; }
}
/* Mobile drawer */
@media (max-width: 960px) {
  .ld-mnav { box-sizing: border-box; max-height: calc(100svh - 96px); overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; box-shadow: 0 26px 60px rgba(0,0,0,0.4); }
  .ld-mnav-sub { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 420ms var(--ease-out); }
  .ld-mnav-sub > div { overflow: hidden; }
  .ld-mnav-group.open .ld-mnav-sub { grid-template-rows: 1fr; }
  .ld-mnav-group.open .ld-mnav-chev { transform: rotate(180deg); }
  .ld-mnav-group.open [data-mnav-toggle] { background: #A18A43 !important; border-color: #A18A43 !important; color: #2D302D !important; }
}

/* ---------- Footer ---------- */
@media (max-width: 640px) {
  .ld-ft-grid { gap: 36px !important; }
  .ld-ft-links { gap: 2px !important; }
  .ld-ft-links a { font-size: 15px !important; padding: 9px 0 !important; }
  .ld-ft-vidgrid { grid-template-columns: 1fr !important; gap: 2px !important; }
  .ld-ft-vidgrid > div { gap: 2px !important; }
  .ld-ft-areas { gap: 0 18px !important; }
  .ld-ft-areas a { font-size: 13.5px !important; padding: 11px 0 !important; }
  .ld-ft button, .ld-ft .ld-btn { min-height: 44px !important; }
  .ld-ft .ld-input { min-height: 44px !important; }
  .ld-ft-bottom { align-items: flex-start !important; gap: 20px !important; }
  .ld-ft-social { gap: 26px !important; font-size: 21px !important; }
  .ld-ft-social a { min-width: 40px; min-height: 40px; display: inline-flex; align-items: center; justify-content: center; text-decoration: none !important; }
  .ld-ft-studio-h ~ p, .ld-ft-studio-h ~ p a { font-size: 15.5px !important; }
  .ld-ft-studio-h ~ p a { min-height: 40px; }
}

/* ---------- Page content ---------- */
@media (max-width: 640px) {
  /* Lift sub-15px reading copy to a comfortable phone size.
     Uppercase eyebrows/labels and icons keep their authored size. */
  p[style*="font-size: 12.5px"]:not([style*="uppercase"]),
  p[style*="font-size: 13px"]:not([style*="uppercase"]),
  p[style*="font-size: 13.5px"]:not([style*="uppercase"]),
  p[style*="font-size: 14px"]:not([style*="uppercase"]),
  p[style*="font-size: 14.5px"]:not([style*="uppercase"]),
  div[style*="font-size: 13px"]:not([style*="uppercase"]):not([aria-hidden]),
  div[style*="font-size: 13.5px"]:not([style*="uppercase"]):not([aria-hidden]),
  div[style*="font-size: 14px"]:not([style*="uppercase"]):not([aria-hidden]),
  div[style*="font-size: 14.5px"]:not([style*="uppercase"]):not([aria-hidden]),
  li[style*="font-size: 13"]:not([style*="uppercase"]),
  li[style*="font-size: 14"]:not([style*="uppercase"]) { font-size: 15.5px !important; }
  /* Standalone inline-flex links become real tap targets */
  a[style*="inline-flex"]:not([aria-label*="home"]) { min-height: 44px; }
  input[type="checkbox"], .ld-check { width: 22px !important; height: 22px !important; }
  /* Big display headlines set with nowrap on desktop must be allowed to wrap */
  .ld-hero-copy h1 { white-space: normal !important; font-size: clamp(2.35rem, 9.4vw, 3rem) !important; }
  .ld-nowrap-mobile-off { white-space: normal !important; }
}

/* ---------- Component tap targets ---------- */
@media (max-width: 640px) {
  a[href*="marketing-agency-"] { min-height: 40px; display: inline-flex; align-items: center; }
  .ld-tlink { min-height: 44px; }
  [data-filter] { min-height: 44px !important; }
  .jr-card [data-jtitle] { font-size: 1.3rem !important; }
}

/* ---------- Stacked split heroes ---------- */
@media (max-width: 880px) {
  /* Once the hero stacks, the form panel no longer needs desktop nav clearance */
  [data-screen-label="Quick contact form"] { min-height: 0 !important; padding-top: clamp(30px, 7vw, 56px) !important; padding-bottom: clamp(44px, 9vw, 76px) !important; }
}

/* ---------- Sticky FAQ heading ---------- */
@media (max-width: 880px) {
  /* Once the column wraps full-width, the sticky heading needs its own
     surface so answers don't scroll through it */
  [data-screen-label="FAQ"] > div > div[style*="position: sticky"] {
    background: var(--surface-page);
    z-index: 3;
    top: 62px !important;
    margin-left: calc(-1 * clamp(20px, 5vw, 80px));
    margin-right: calc(-1 * clamp(20px, 5vw, 80px));
    padding: 14px clamp(20px, 5vw, 80px) 18px;
    box-shadow: 0 10px 18px -12px rgba(45,48,45,0.22);
  }
  /* the "ask us anything" prompt moves below the answers */
  .ld-faq-ask { display: none !important; }
  .ld-faq-ask-m { display: block !important; }
}
