/* ISC_R30 isc-inl-layout-base-8.css: moved unchanged from templates/layout/base.html (inline block 8), 2026-11-07 */

@media (max-width:800px){
  :root{
    --m-gutter:16px; --m-s1:4px; --m-s2:8px; --m-s3:12px; --m-s4:16px; --m-s5:24px; --m-s6:32px;
    --m-tap:44px; --m-radius:12px;
    --m-h1:clamp(30px,8.4vw,40px); --m-h2:clamp(24px,6.6vw,30px); --m-h3:clamp(20px,5.4vw,24px);
    --m-title:17px; --m-body:16px; --m-label:12px; --m-btn:15px;
  }
  @media (min-width:414px){ :root{ --m-gutter:20px; --m-title:18px; } }

  /* ---------- 1. HEADER: hamburger | logo | search | cart ----------
     Root cause of the icon-on-logo collision: every header child was
     absolutely positioned, and #isc-search-btn resolved against
     .header-logo (position:relative). Replaced with one flex row and
     explicit order, so the four controls can no longer overlap. */
  html body #isc-header-root .header,
  .header{
    display:flex!important; flex-direction:row!important; align-items:center!important;
    gap:var(--m-s1)!important; min-height:56px!important; height:56px!important;
    padding:0 var(--m-s2)!important; position:relative!important;
  }
  .header .mobileMenu-toggle{
    order:1!important; position:static!important; transform:none!important;
    flex:0 0 var(--m-tap)!important; width:var(--m-tap)!important; height:var(--m-tap)!important;
    left:auto!important; top:auto!important; margin:0!important;
  }
  html body #isc-header-root .header-logo,
  .header .header-logo{
    order:2!important; position:static!important; flex:1 1 auto!important;
    min-width:0!important; height:auto!important; min-height:0!important;
    padding:0!important; margin:0!important; background:none!important;
    backdrop-filter:none!important; display:flex!important;
    align-items:center!important; justify-content:center!important;
  }
  html body #isc-header-root .header-logo .header-logo-image{
    max-height:32px!important; height:32px!important; width:auto!important;
  }
  .header .header-logo-text{font-size:14px!important}
  #isc-search-btn{
    order:3!important; position:static!important; transform:none!important;
    right:auto!important; top:auto!important; margin:0!important;
    flex:0 0 var(--m-tap)!important; width:var(--m-tap)!important; height:var(--m-tap)!important;
    min-width:var(--m-tap)!important; min-height:var(--m-tap)!important;
    border-radius:999px!important; background:rgba(255,255,255,.06)!important;
    border:1px solid rgba(255,255,255,.14)!important; padding:0!important;
  }
  #isc-search-btn svg{width:19px!important;height:19px!important;stroke:#FAF8F2!important}
  .header .navUser{
    order:4!important; position:static!important; transform:none!important;
    right:auto!important; top:auto!important; flex:0 0 auto!important;
    max-width:none!important; width:auto!important; margin:0!important;
  }
  .header .navUser-item--cart .navUser-action{min-width:var(--m-tap)!important;min-height:var(--m-tap)!important;padding:0 6px!important}
  /* the drawer is a sibling of the row, never a flex column in it */
  .header .navPages-container{order:5!important;position:absolute!important;top:100%!important;left:0!important;right:0!important}

  /* ---------- 2. TYPE SCALE ---------- */
  .page h1, .isc-cat-hero h1, .isc-home-hero h1{font-size:var(--m-h1)!important;line-height:1.1!important;letter-spacing:-.02em!important;margin:0 0 var(--m-s3)!important}
  .page h2, .isc-home-section h2, .isc-cat-guide__intro h2{font-size:var(--m-h2)!important;line-height:1.15!important;margin:0 0 var(--m-s3)!important}
  .page h3, .isc-cat-guide__item h3{font-size:var(--m-h3)!important;line-height:1.2!important;margin:0 0 var(--m-s2)!important}
  .page p, .isc-cat-hero p, .isc-cat-guide__intro p{font-size:var(--m-body)!important;line-height:1.55!important}
  .isc-cat-guide__label, .card-text--brand, .card-text--system{font-size:var(--m-label)!important;letter-spacing:.14em!important}

  /* ---------- 3. SECTION RHYTHM (kill desktop-sized vertical space) ---------- */
  .isc-cat-hero--has-image, .isc-cat-hero--no-image{min-height:0!important;padding:var(--m-s5) var(--m-gutter)!important}
  .isc-cat-guide{padding:var(--m-s5) var(--m-gutter)!important;gap:var(--m-s4)!important}
  .isc-subcats{padding:var(--m-s3) var(--m-gutter)!important}
  .isc-compat-jump{padding:var(--m-s4) var(--m-gutter)!important}
  .isc-home-section{padding:var(--m-s5) var(--m-gutter)!important}
  .isc-home-series, .isc-home-audience{padding:var(--m-s5) var(--m-s4)!important;border-radius:var(--m-radius)!important}
  .page-content, .page-content--centered{padding-left:var(--m-gutter)!important;padding-right:var(--m-gutter)!important}

  /* ---------- 4. CONTROLS ---------- */
  .button, .button--primary, .form-input, .form-select, input[type=text], input[type=email],
  input[type=tel], input[type=number], input[type=search], select, textarea{
    min-height:var(--m-tap)!important; font-size:16px!important; border-radius:10px!important;
  }
  .button, .button--primary{padding:0 var(--m-s4)!important;font-size:var(--m-btn)!important;display:inline-flex!important;align-items:center!important;justify-content:center!important}

  /* ---------- 5. PRODUCT CARDS ----------
     Root cause of the dead space: .productGrid stretches every card to the
     tallest in the row (default align-items:stretch) while .card is
     height:100% flex-column, so shorter cards padded out ~42px of empty
     body. Nothing is hidden — cards simply size to their own content now. */
  .productGrid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:var(--m-s4) var(--m-s3)!important;align-items:start!important;padding-left:0!important;padding-right:0!important;margin-left:0!important;margin-right:0!important}
  .productGrid .product{height:auto!important}
  .productGrid .product .card{height:auto!important;min-height:0!important;display:flex!important;flex-direction:column!important}
  .productGrid .product .card-figure{aspect-ratio:4/3!important;flex:0 0 auto!important;margin:0!important}
  .productGrid .product .card-figure img, .productGrid .product .card-image{width:100%!important;height:100%!important;object-fit:cover!important}
  .productGrid .product .card-body{flex:0 0 auto!important;padding:var(--m-s3) var(--m-s3) var(--m-s4)!important;gap:var(--m-s1)!important;display:flex!important;flex-direction:column!important}
  /* the 2-line reservation was an artificial minimum — clamp without it */
  .productGrid .product .card-title a{font-size:var(--m-title)!important;line-height:1.25!important;min-height:0!important;-webkit-line-clamp:2!important}
  .productGrid .product .card-text--price{font-size:16px!important;margin:var(--m-s1) 0 0!important}
  .productGrid .product .card-figcaption{display:none!important} /* hover UI is meaningless on touch */

  /* ---------- 6. STICKY BOTTOM BAR ----------
     Was 65px tall while the body reserved 128px (63px of dead screen), and
     "Request Custom Quote" wrapped onto two lines at 15px uppercase. */
  :root{--isc-bar-clear:calc(60px + env(safe-area-inset-bottom))!important}
  body{padding-bottom:var(--isc-bar-clear)!important}
  .isc-mobile-bar{padding:6px var(--m-s3) calc(6px + env(safe-area-inset-bottom))!important;gap:var(--m-s2)!important;grid-template-columns:1fr 1.35fr!important}
  .isc-mobile-bar__btn{min-height:42px!important;font-size:13px!important;letter-spacing:.04em!important;gap:6px!important;white-space:nowrap!important}
  .isc-mobile-bar__btn svg{width:16px!important;height:16px!important}
  .isc-mobile-bar__btn--quote .isc-mobile-bar__txt{display:none!important}
  .isc-mobile-bar__btn--quote .isc-mobile-bar__txt--short{display:inline!important}

  /* ---------- 6b. PELICAN FINDER / SIZE FINDER ----------
     Measured at 375px BEFORE: the whole .isc-sel module rendered 191px wide
     at x=92 (its parent constrained it), so the three L/W/H inputs were 47px
     each and every label wrapped onto two lines ("LENGTH" / "IN"). Widening
     the module is the actual fix — the label wrapping resolves itself once
     the fields have room. Inputs also go to 16px so iOS stops zooming on
     focus, and to a 44px target. */
  .isc-sel{max-width:none!important;width:auto!important;margin:0 0 var(--m-s5)!important;padding:0 var(--m-gutter)!important;display:block!important;float:none!important}
  .isc-sel__grid{display:grid!important;grid-template-columns:1fr!important;gap:var(--m-s4)!important;width:auto!important}
  /* flatten: panels become sections separated by rule + space, not boxes */
  .isc-sel__p{width:auto!important;min-width:0!important;background:none!important;border:0!important;border-radius:0!important;padding:0!important;box-shadow:none!important}
  .isc-sel__p--hero{border-left:0!important}
  .isc-sel__p + .isc-sel__p{border-top:1px solid var(--isc-line,#e3ded4)!important;padding-top:var(--m-s4)!important}
  .isc-sel__h{font-size:var(--m-h3)!important;line-height:1.2!important;margin:0 0 var(--m-s1)!important}
  .isc-sel__s{font-size:14px!important;margin:0 0 var(--m-s3)!important}
  /* Length | Width | Height — three even fields across the card */
  .isc-sel__dims{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:var(--m-s2)!important;margin:0 0 var(--m-s3)!important}
  .isc-sel__dims label{min-width:0!important;flex:none!important}
  .isc-sel__dims span,.isc-sel__fl span{font-size:11px!important;letter-spacing:.04em!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;margin:0 0 var(--m-s1)!important}
  .isc-sel input{font-size:16px!important;min-height:var(--m-tap)!important;padding:0 10px!important;border-radius:10px!important}
  .isc-sel__btn{width:100%!important;min-height:var(--m-tap)!important;font-size:15px!important;padding:0 var(--m-s4)!important;border-radius:10px!important;display:inline-flex!important;align-items:center!important;justify-content:center!important}
  /* four compact family tiles, 2x2 */
  .isc-sel__fams{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:var(--m-s2)!important;margin-top:var(--m-s3)!important}
  .isc-sel__fam{padding:var(--m-s3) var(--m-s3)!important;border-radius:10px!important;min-height:var(--m-tap)!important;display:flex!important;flex-direction:column!important;justify-content:center!important}
  .isc-sel__fam b{font-size:14px!important}
  .isc-sel__fam i{font-size:11px!important;line-height:1.3!important}
  .isc-sel__res{padding:var(--m-s4) 0 0!important;background:none!important;border:0!important;border-top:1px solid var(--isc-line,#e3ded4)!important;border-radius:0!important;margin-top:var(--m-s4)!important}
  .isc-sel__row{padding:var(--m-s3) 0!important;gap:var(--m-s3)!important}

  /* ---------- 5b. SEARCHANISE PRODUCT CARDS (the real catalog cards) ----------
     MEASURED @390px BEFORE: card 498-514px tall = ~60% of the viewport, of
     which the image was only 170px. Cause: `.snize-thumbnail-wrapper` is a
     full-width **square** (350x350), so landscape case photos leave ~180px of
     dead white INSIDE the image area — this is the "huge blank region between
     image and product info". Fixing the wrapper's shape is the root cause fix;
     nothing is hidden or pulled up with negative margins.
     A fixed image band also gives every product the same image presentation,
     so a long rifle case and a small accessory case produce equal-height
     cards (Josh #3). */
  #snize_results .snize-product .snize-thumbnail-wrapper,.snize-product .snize-thumbnail-wrapper{
    height:auto!important; aspect-ratio:3/2!important; max-height:210px!important;
    display:flex!important; align-items:center!important; justify-content:center!important;
    overflow:hidden!important; padding:0!important; background:#fff!important;
  }
  #snize_results .snize-product .snize-thumbnail,.snize-product .snize-thumbnail{
    height:100%!important; width:100%!important; display:flex!important;
    align-items:center!important; justify-content:center!important; padding:0!important;
  }
  /* contain, not cover: these are product photos on white — cropping a case is worse
     than a little side letterboxing, and contain removes the vertical dead band. */
  #snize_results .snize-product .snize-thumbnail img,#snize_results .snize-product .snize-thumbnail-wrapper img,.snize-product .snize-thumbnail img{
    width:auto!important; height:auto!important; max-width:100%!important; max-height:100%!important;
    object-fit:contain!important; position:static!important;
  }
  .snize-product{margin:0 0 var(--m-s4)!important}
  #snize_results .snize-product .snize-overhidden,.snize-product .snize-overhidden{padding-top:var(--m-s2)!important}
  /* predictable long-title treatment: 2 lines, clamped, no reserved minimum */
  #snize_results .snize-product .snize-title,.snize-product .snize-title{
    min-height:0!important; font-size:16px!important; line-height:1.3!important;
    display:-webkit-box!important; -webkit-line-clamp:2!important; -webkit-box-orient:vertical!important;
    overflow:hidden!important; margin:0 0 var(--m-s1)!important;
  }
  .snize-product .snize-price-list{padding-top:var(--m-s1)!important}
  .snize-product .snize-buttons{margin-top:var(--m-s2)!important}
  .snize-product .snize-buttons a,.snize-product .snize-buttons button{min-height:var(--m-tap)!important;font-size:14px!important}

  /* ---------- 6c. PELICAN IA: remove the duplicated family strip ----------
     MEASURED: on /pelican-cases/ the `.isc-subcat-tile` chips link to
     /protector-cases/, /storm-cases/, /vault-cases/, /air-cases/ — the SAME
     four destinations as the finder's "Shop by family" tiles, and they render
     ~110px ABOVE it. That is two versions of one navigation path.
     `:has()` scopes this to pages that actually carry the finder, so ordinary
     categories (/camera/ etc., where the chips are the only browse-by-type and
     duplicate nothing) keep theirs untouched. On browsers without :has() the
     page simply keeps today's behaviour — no breakage. */
  .isc-cat-page:has(.isc-sel__fams) .isc-subcats{display:none!important}
  /* hero: trim the lead-in so the finder starts higher up the first screens */
  .isc-cat-hero--no-image{padding-top:var(--m-s4)!important;padding-bottom:var(--m-s3)!important}
  .isc-cat-hero .isc-cat-intro-more{min-height:var(--m-tap)!important;font-size:13px!important}

  /* ---------- 6d. CATALOG PAGE ORDER: search first ----------
     MEASURED on /camera/ @390: the script-injected `.isc-qw-guide` (519px,
     and it carries its OWN search field) is inserted between the hero and the
     results, which pushed the real catalog search down to y=1204 — below the
     fold on every phone. Three discovery tools stacked, with the primary one
     last. `.isc-cat-page` becomes a flex column on mobile purely so the
     existing blocks can be ordered; nothing is moved in the DOM, so desktop
     and the injected scripts are unaffected. */
  .isc-cat-page{display:flex!important;flex-direction:column!important}
  .isc-cat-page > *{order:5}
  .isc-cat-page > .isc-cat-hero{order:1}
  .isc-cat-page > .isc-mcat{order:2}
  .isc-cat-page > .isc-subcats{order:3}
  .isc-cat-page > .isc-qw-guide,.isc-cat-page > [data-isc-qw="cat-guide"]{order:4}
  .isc-cat-page > .isc-searchanise-category{order:6}
  .isc-cat-page > .isc-native-fallback{order:7}
  .isc-cat-page > .isc-cat-fullguide{order:8}
  .isc-cat-page > .isc-below-results{order:9}
  /* the injected guide carries a duplicate mini search — one search per page */
  .isc-qw-guide .isc-qw-minisearch,[data-isc-qw="cat-guide"] .isc-qw-minisearch{display:none!important}
  .isc-qw-guide,[data-isc-qw="cat-guide"]{padding:var(--m-s4)!important;gap:var(--m-s3)!important;margin:0 var(--m-gutter) var(--m-s4)!important}

  /* ---------- 6e. CASE DIMENSIONS BLOCK (PDP) ---------- */
  .isc-case-dims{margin:var(--m-s4) 0!important;padding:var(--m-s4) 0!important;border-top:1px solid var(--isc-line,#e3ded4)!important;border-bottom:1px solid var(--isc-line,#e3ded4)!important}
  .isc-case-dims__title{font-size:var(--m-h3)!important;margin:0 0 var(--m-s3)!important;line-height:1.2!important}
  .isc-case-dims__grid{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:var(--m-s3)!important;margin:0!important}
  .isc-case-dims__item dt{font-family:var(--isc-font-mono,monospace)!important;font-size:10.5px!important;letter-spacing:.16em!important;text-transform:uppercase!important;color:var(--isc-gold,#B8862E)!important;margin:0 0 4px!important}
  .isc-case-dims__item dd{margin:0!important;font-size:15px!important;font-weight:600!important;line-height:1.3!important;color:var(--isc-ink,#0E1B2C)!important}
  .isc-case-dims__item--key dd{font-size:16px!important}
  .isc-case-dims__note{margin:var(--m-s3) 0 0!important;font-size:12.5px!important;line-height:1.45!important;color:var(--isc-ink-soft,#54616F)!important}
  @media (max-width:380px){ .isc-case-dims__grid{grid-template-columns:repeat(2,minmax(0,1fr))!important} }

  /* ---------- 7. FLATTEN NESTED CARDS / BORDERS ----------
     Separate with whitespace + headings; keep navy panels for emphasis only. */
  .isc-cat-guide__item{background:none!important;border:0!important;padding:0 0 var(--m-s4)!important;min-height:0!important;border-radius:0!important}
  .isc-cat-guide__item + .isc-cat-guide__item{border-top:1px solid var(--isc-line)!important;padding-top:var(--m-s4)!important}
  .isc-cat-guide{border-bottom:1px solid var(--isc-line)!important}
}
/* the short sticky-bar label must never appear on desktop */
@media (min-width:801px){ .isc-mobile-bar__txt--short{display:none!important} }
