/*
 * WebXtent v0.8.126 — Developments tablet viewport / gallery-dock correction.
 *
 * Removes the historical 860px minimum that creates vertical page travel on
 * shorter tablet viewports, keeps the immersive Developments scene inside the
 * usable viewport, and prevents the legacy idle-dock state from pushing the
 * gallery/navigation controls below the visible tablet canvas.
 */

@media (min-width:768px) and (max-width:1024px){
  body.wxt-scene-developments{
    height:100svh!important;
    min-height:100svh!important;
    max-height:100svh!important;
    overflow:hidden!important;
    overscroll-behavior:none!important;
  }

  body.wxt-scene-developments .wxt-developments-showcase-main,
  body.wxt-scene-developments .wxt-development-showcase,
  body.wxt-scene-developments .wxt-development-showcase__shell,
  body.wxt-scene-developments .wxt-development-showcase__frame{
    height:100svh!important;
    min-height:0!important;
    max-height:100svh!important;
    overflow:hidden!important;
  }

  body.wxt-scene-developments .wxt-development-showcase__hero{
    height:100svh!important;
    min-height:100svh!important;
    max-height:100svh!important;
    margin:0!important;
    overflow:hidden!important;
  }

  /* Lift the complete gallery/navigation tray away from the browser edge so
   * controls remain visually attached to the gallery on both portrait and
   * landscape tablets. */
  body.wxt-scene-developments .wxt-development-showcase__project-carousel{
    bottom:max(clamp(34px,4.5svh,52px),calc(env(safe-area-inset-bottom,0px) + 18px))!important;
    z-index:30!important;
    visibility:visible!important;
  }

  /* Tablet navigation must remain reachable in every automatic/manual gallery
   * state. Manual collapse may hide only the thumbnail rail; never the control bar. */
  body.wxt-scene-developments .wxt-development-showcase.is-gallery-idle .wxt-development-showcase__project-carousel,
  body.wxt-scene-developments .wxt-development-showcase.is-gallery-active .wxt-development-showcase__project-carousel,
  body.wxt-scene-developments .wxt-development-showcase.is-gallery-manual-collapsed .wxt-development-showcase__project-carousel,
  body.wxt-scene-developments .wxt-development-showcase.is-gallery-manual-collapsed.is-gallery-idle .wxt-development-showcase__project-carousel,
  body.wxt-scene-developments .wxt-development-showcase.is-gallery-manual-collapsed.is-gallery-active .wxt-development-showcase__project-carousel{
    transform:translate3d(0,0,0)!important;
    opacity:1!important;
    visibility:visible!important;
    pointer-events:auto!important;
  }

  body.wxt-scene-developments .wxt-development-showcase__project-carousel-bar{
    opacity:1!important;
    visibility:visible!important;
    pointer-events:auto!important;
  }

  body.wxt-scene-developments .wxt-development-project-wheel__dock,
  body.wxt-scene-developments .wxt-development-gallery-visibility-toggle{
    visibility:visible!important;
    pointer-events:auto!important;
  }

  /* v0.8.172: iPad/tablet now mirrors desktop auto-docking after the
   * configured idle delay. Keep the 62px control header visible and collapse
   * the thumbnail rail below it without changing the approved tray position. */
  body.wxt-scene-developments .wxt-development-showcase.is-gallery-idle .wxt-development-showcase__project-carousel{
    transform:translate3d(0,calc(100% - 62px),0)!important;
    opacity:1!important;
    visibility:visible!important;
    pointer-events:auto!important;
  }

  body.wxt-scene-developments .wxt-development-showcase.is-gallery-idle .wxt-development-showcase__project-track{
    opacity:.18!important;
    pointer-events:none!important;
  }

  body.wxt-scene-developments .wxt-development-project-wheel__dock{
    align-self:center!important;
    transform:translate3d(0,-2px,0)!important;
  }

  /* Manual collapse remains an explicit user action and stays functional.
   * Only the thumbnail rail collapses; its later tablet minimum-height must not
   * leave a stranded box or take the control row with it. */
  body.wxt-scene-developments .wxt-development-showcase.is-gallery-manual-collapsed .wxt-development-project-wheel__dock{
    transform:translate3d(0,-2px,0)!important;
  }

  body.wxt-scene-developments .wxt-development-showcase.is-gallery-manual-collapsed .wxt-development-showcase__project-track{
    height:0!important;
    min-height:0!important;
    max-height:0!important;
    margin:0!important;
    padding-top:0!important;
    padding-bottom:0!important;
    opacity:0!important;
    visibility:hidden!important;
    overflow:hidden!important;
    pointer-events:none!important;
  }
}

/* Extra-short tablet browser windows need a little more breathing room. */
@media (min-width:768px) and (max-width:1024px) and (max-height:760px){
  body.wxt-scene-developments .wxt-development-showcase__project-carousel{
    bottom:24px!important;
  }

  body.wxt-scene-developments .wxt-development-showcase__project-track{
    min-height:148px!important;
  }

  body.wxt-scene-developments .wxt-development-showcase button.wxt-development-stack-card{
    min-height:146px!important;
    height:146px!important;
  }
}


/* v0.8.151 — iPad 10/11-inch landscape dock ownership.
 * Modern iPads can expose ~1180–1194 CSS px in landscape, so width-only
 * <=1024 tablet rules misclassify them as desktop. Restrict this extension to
 * touch/coarse-pointer devices so ordinary laptops keep desktop behaviour. */
@media (min-width:1025px) and (max-width:1194px) and (hover:none) and (pointer:coarse){
  /* v0.8.153: landscape iPad is still an immersive, non-scrolling Developments
   * canvas. v0.8.151 extended only the dock ownership, leaving the document
   * itself free to move before the vertical project gesture completed. */
  body.wxt-scene-developments{
    height:100svh!important;
    min-height:100svh!important;
    max-height:100svh!important;
    overflow:hidden!important;
    overscroll-behavior:none!important;
  }

  body.wxt-scene-developments .wxt-developments-showcase-main,
  body.wxt-scene-developments .wxt-development-showcase,
  body.wxt-scene-developments .wxt-development-showcase__shell,
  body.wxt-scene-developments .wxt-development-showcase__frame{
    height:100svh!important;
    min-height:0!important;
    max-height:100svh!important;
    overflow:hidden!important;
  }

  body.wxt-scene-developments .wxt-development-showcase__hero{
    height:100svh!important;
    min-height:100svh!important;
    max-height:100svh!important;
    margin:0!important;
    overflow:hidden!important;
  }

  body.wxt-scene-developments .wxt-development-showcase__project-carousel{
    bottom:max(clamp(28px,4svh,46px),calc(env(safe-area-inset-bottom,0px) + 18px))!important;
    transform:translate3d(0,0,0)!important;
    opacity:1!important;
    visibility:visible!important;
    pointer-events:auto!important;
    z-index:30!important;
    overflow:visible!important;
  }

  body.wxt-scene-developments .wxt-development-showcase.is-gallery-idle .wxt-development-showcase__project-carousel,
  body.wxt-scene-developments .wxt-development-showcase.is-gallery-active .wxt-development-showcase__project-carousel,
  body.wxt-scene-developments .wxt-development-showcase.is-gallery-manual-collapsed .wxt-development-showcase__project-carousel,
  body.wxt-scene-developments .wxt-development-showcase.is-gallery-manual-collapsed.is-gallery-idle .wxt-development-showcase__project-carousel,
  body.wxt-scene-developments .wxt-development-showcase.is-gallery-manual-collapsed.is-gallery-active .wxt-development-showcase__project-carousel{
    transform:translate3d(0,0,0)!important;
    opacity:1!important;
    visibility:visible!important;
    pointer-events:auto!important;
  }

  body.wxt-scene-developments .wxt-development-showcase__project-carousel-bar,
  body.wxt-scene-developments .wxt-development-project-wheel__dock,
  body.wxt-scene-developments .wxt-development-gallery-visibility-toggle{
    opacity:1!important;
    visibility:visible!important;
    pointer-events:auto!important;
  }

  /* v0.8.172: landscape iPad uses the same idle-collapse geometry as
   * desktop while preserving the tablet-specific bottom/safe-area placement. */
  body.wxt-scene-developments .wxt-development-showcase.is-gallery-idle .wxt-development-showcase__project-carousel{
    transform:translate3d(0,calc(100% - 62px),0)!important;
    opacity:1!important;
    visibility:visible!important;
    pointer-events:auto!important;
  }

  body.wxt-scene-developments .wxt-development-showcase.is-gallery-idle .wxt-development-showcase__project-track{
    opacity:.18!important;
    pointer-events:none!important;
  }

  body.wxt-scene-developments .wxt-development-showcase.is-gallery-manual-collapsed .wxt-development-showcase__project-track{
    height:0!important;
    min-height:0!important;
    max-height:0!important;
    margin:0!important;
    padding-top:0!important;
    padding-bottom:0!important;
    opacity:0!important;
    visibility:hidden!important;
    overflow:hidden!important;
    pointer-events:none!important;
  }
}


/* v0.8.154 — route-scoped iPad visual-viewport lock.
 * The JS runtime adds this class only while the Developments scene owns an iPad
 * touch viewport. Lock both html and body so Safari cannot expose document
 * travel or the pull-to-refresh rubber-band behind the immersive canvas. */
html.wxt-developments-ipad-viewport,
html.wxt-developments-ipad-viewport body.wxt-scene-developments{
  width:100%;
  height:100%;
  min-height:100%;
  max-height:100%;
  overflow:hidden!important;
  overscroll-behavior:none!important;
}

html.wxt-developments-ipad-viewport body.wxt-scene-developments{
  position:fixed!important;
  inset:0!important;
  margin:0!important;
}
