/* VCTH 11.1.8 · ROUND 1 STABLE
   Four regressions only: mobile nav, Marga search visual shell, centred result
   canvas and compact Trustindex placement. Loaded after every historical VCTF
   layer so old CSS cannot win by accident. */

/* 1 · MOBILE NAV: the button and panel remain usable even when an inherited
   layer leaves aria-hidden/display in a contradictory state. */
@media (max-width:900px){
  body.vcth-star-safe .vmon-menu-button{
    position:relative!important;z-index:100050!important;display:inline-flex!important;
    align-items:center!important;justify-content:center!important;visibility:visible!important;
    pointer-events:auto!important;opacity:1!important
  }
  body.vcth-star-safe #vmon-nav{
    position:fixed!important;z-index:100040!important;top:0!important;right:0!important;
    bottom:0!important;left:auto!important;width:min(88vw,390px)!important;max-width:390px!important;
    height:100dvh!important;max-height:100dvh!important;margin:0!important;padding:88px 20px 28px!important;
    overflow-y:auto!important;overscroll-behavior:contain!important;background:#fff!important;
    box-shadow:-24px 0 60px rgba(6,24,46,.20)!important;transform:translateX(105%)!important;
    transition:transform .22s ease!important;visibility:hidden!important;opacity:1!important;
    pointer-events:none!important
  }
  body.vcth-star-safe.vmon-nav-open #vmon-nav,
  body.vcth-star-safe #vmon-nav[data-vcth-mobile-open="1"]{
    display:block!important;transform:translateX(0)!important;visibility:visible!important;
    pointer-events:auto!important
  }
  body.vcth-star-safe.vmon-nav-open{overflow:hidden!important}
  body.vcth-star-safe #vmon-nav>ul{display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:2px!important;width:100%!important}
  body.vcth-star-safe #vmon-nav>ul>li{display:block!important;width:100%!important}
  body.vcth-star-safe #vmon-nav>ul>li>a,
  body.vcth-star-safe #vmon-nav .vmon-nav__trigger>a{display:flex!important;width:100%!important;min-height:48px!important;align-items:center!important;color:#06182e!important}
  body.vcth-star-safe #vmon-nav .sub-menu,
  body.vcth-star-safe #vmon-nav .vmon-submenu{position:static!important;width:100%!important;min-width:0!important;max-width:none!important;box-shadow:none!important;border-radius:12px!important}
  body.vcth-star-safe #vmon-nav li:not(.is-open)>.sub-menu,
  body.vcth-star-safe #vmon-nav li:not(.is-open)>.vmon-submenu{display:none!important}
  body.vcth-star-safe #vmon-nav li.is-open>.sub-menu,
  body.vcth-star-safe #vmon-nav li.is-open>.vmon-submenu{display:block!important}
}

/* 2 · SEARCH: restore the compact two-card visual system that was already
   approved. The real Marga form and values stay untouched. */
body.vcth-star-safe .vmon-marga--search form.cth-vctf45-search-form,
body.vcth-star-safe .vmon-marga--search form.cth-vctf44-search-form,
body.vcth-star-safe .vmon-marga--search form.md-template{
  width:100%!important;max-width:none!important;margin:0!important;padding:0!important;
  border:0!important;border-radius:0!important;background:transparent!important;
  box-shadow:none!important;overflow:visible!important
}
body.vcth-star-safe .vmon-marga--search form.cth-vctf45-search-form>.cth-vctf45-query-row,
body.vcth-star-safe .vmon-marga--search form.cth-vctf44-search-form>.d-flex:first-of-type,
body.vcth-star-safe .vmon-marga--search form.md-template>.d-flex:first-of-type{
  display:grid!important;grid-template-columns:minmax(0,1fr) 64px!important;gap:0!important;
  width:100%!important;max-width:none!important;margin:0 0 18px!important;padding:18px!important;
  border:1px solid rgba(8,45,89,.09)!important;border-radius:20px!important;background:#fff!important;
  color:#06182e!important;box-shadow:0 14px 38px rgba(6,24,46,.07)!important;box-sizing:border-box!important
}
body.vcth-star-safe .vmon-marga--search form.cth-vctf45-search-form>.cth-vctf45-filter-row,
body.vcth-star-safe .vmon-marga--search form.cth-vctf44-search-form>.d-flex:not(:first-of-type),
body.vcth-star-safe .vmon-marga--search form.md-template>.d-flex:not(:first-of-type){
  display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr)) minmax(190px,.72fr)!important;
  gap:12px!important;align-items:end!important;width:100%!important;max-width:none!important;
  margin:0!important;padding:20px!important;border:1px solid rgba(8,45,89,.09)!important;
  border-radius:20px!important;background:#fff!important;color:#06182e!important;
  box-shadow:0 14px 38px rgba(6,24,46,.07)!important;box-sizing:border-box!important;overflow:visible!important
}
body.vcth-star-safe .vmon-marga--search .md-label,
body.vcth-star-safe .vmon-marga--search label.md-label{display:block!important;margin:0 0 7px!important;color:#082d59!important;opacity:1!important;font-size:.78rem!important;font-weight:950!important}
body.vcth-star-safe .vmon-marga--search .md-search-field{
  width:100%!important;min-width:0!important;height:52px!important;min-height:52px!important;
  padding:0 16px!important;border:1px solid rgba(8,45,89,.15)!important;border-right:0!important;
  border-radius:13px 0 0 13px!important;background:#fff!important;color:#06182e!important;
  box-shadow:none!important;outline:0!important
}
body.vcth-star-safe .vmon-marga--search .cth-vctf45-query-row>.md-search-submit,
body.vcth-star-safe .vmon-marga--search form>.d-flex:first-of-type>.md-search-submit{
  width:64px!important;min-width:64px!important;height:52px!important;min-height:52px!important;margin:0!important;
  border:0!important;border-radius:0 13px 13px 0!important;background:linear-gradient(135deg,#075aa8,#159fe3)!important;
  color:#fff!important;box-shadow:none!important
}
body.vcth-star-safe .vmon-marga--search :where(.select2-container,.cth-vctf43-multi,.cth-vctf44-multi,.cth-vctf45-multi){width:100%!important;max-width:100%!important;min-width:0!important}
body.vcth-star-safe .vmon-marga--search :where(.select2-selection--multiple,.select2-selection--single,.cth-vctf43-multi__button,.cth-vctf44-multi__button,.cth-vctf45-multi__button){
  display:flex!important;align-items:center!important;width:100%!important;min-height:50px!important;height:50px!important;
  padding:0 13px!important;border:1px solid rgba(8,45,89,.15)!important;border-radius:12px!important;
  background:#f8fbff!important;color:#06182e!important;box-shadow:none!important;opacity:1!important
}
body.vcth-star-safe .vmon-marga--search .md-control{min-width:0!important;max-width:none!important;width:auto!important;margin:0!important;padding:0!important;overflow:visible!important}
body.vcth-star-safe .vmon-marga--search .md-btn.w-100,
body.vcth-star-safe .vmon-marga--search .cth-vctf45-filter-row :where(.md-search-submit,.md-btn,button[type="submit"]),
body.vcth-star-safe .vmon-marga--search form>.d-flex:not(:first-of-type) :where(.md-search-submit,.md-btn,button[type="submit"]){
  display:flex!important;align-items:center!important;justify-content:center!important;gap:8px!important;
  width:100%!important;min-height:50px!important;height:50px!important;margin:0!important;padding:0 18px!important;
  border:0!important;border-radius:12px!important;background:linear-gradient(135deg,#075aa8,#159fe3)!important;
  color:#fff!important;font-size:.96rem!important;font-weight:950!important;line-height:1!important;box-shadow:none!important
}

/* The section itself should frame the tool, not leave an ocean of blank space. */
body.vcth-star-safe .vctf-search-section{padding-top:clamp(46px,6vw,76px)!important;padding-bottom:clamp(52px,7vw,84px)!important;background:#f3f7fb!important}
body.vcth-star-safe .vctf-search-section .vmon-section-head{margin-bottom:24px!important}
body.vcth-star-safe .vctf-search-section .vmon-section-head h2{font-size:clamp(2.35rem,5vw,5rem)!important;line-height:.9!important;max-width:10ch!important}

/* 3 · RESULTS: all search/hub result canvases are centred and own the full
   available width. This kills the recurring historical half-column bug. */
body.vcth-star-safe.vmon-search-route :where(#content,#main,.content.colibri-page-content,.cth-vctf58-search-ancestor){
  width:100%!important;max-width:none!important;min-width:0!important;float:none!important;
  flex:0 0 100%!important;margin-left:auto!important;margin-right:auto!important;box-sizing:border-box!important
}
body.vcth-star-safe.vmon-search-route #buscador,
body.vcth-star-safe.vmon-search-route .vmon381-search-results,
body.vcth-star-safe.vmon-search-route .cth-vctf45-search-results-canvas{
  width:min(calc(100% - 40px),1240px)!important;max-width:1240px!important;min-width:0!important;
  margin-left:auto!important;margin-right:auto!important;float:none!important;box-sizing:border-box!important
}
body.vcth-star-safe.vmon-search-route #buscador :where(.h-row,.d-flex):has(>.travel-card),
body.vcth-star-safe.vmon-search-route #buscador :where(.h-row,.d-flex):has(>.md-trip-card){
  width:100%!important;max-width:none!important;margin-left:auto!important;margin-right:auto!important;justify-content:center!important
}

/* 4 · Trustindex compact widgets must stay compact; never allow a review wall
   to inherit the dimensions of the Home banner. */
body.vcth-star-safe .vcth-footer-trustindex{width:100%!important;max-width:305px!important;overflow:hidden!important}
body.vcth-star-safe .vcth-footer-trustindex :where(.ti-widget,.ti-widget-container,iframe){width:100%!important;max-width:305px!important;min-width:0!important}
body.vcth-star-safe .vcth-trip-trustindex{width:100%!important;max-width:320px!important;overflow:hidden!important}
body.vcth-star-safe .vcth-trip-trustindex :where(.ti-widget,.ti-widget-container,iframe){width:100%!important;max-width:320px!important;min-width:0!important}

@media(max-width:900px){
  body.vcth-star-safe .vmon-marga--search form.cth-vctf45-search-form>.cth-vctf45-filter-row,
  body.vcth-star-safe .vmon-marga--search form.cth-vctf44-search-form>.d-flex:not(:first-of-type),
  body.vcth-star-safe .vmon-marga--search form.md-template>.d-flex:not(:first-of-type){grid-template-columns:repeat(2,minmax(0,1fr))!important}
}
@media(max-width:620px){
  body.vcth-star-safe .vmon-marga--search form.cth-vctf45-search-form>.cth-vctf45-query-row,
  body.vcth-star-safe .vmon-marga--search form.cth-vctf44-search-form>.d-flex:first-of-type,
  body.vcth-star-safe .vmon-marga--search form.md-template>.d-flex:first-of-type{padding:12px!important;grid-template-columns:minmax(0,1fr) 56px!important}
  body.vcth-star-safe .vmon-marga--search form.cth-vctf45-search-form>.cth-vctf45-filter-row,
  body.vcth-star-safe .vmon-marga--search form.cth-vctf44-search-form>.d-flex:not(:first-of-type),
  body.vcth-star-safe .vmon-marga--search form.md-template>.d-flex:not(:first-of-type){grid-template-columns:1fr!important;padding:14px!important}
  body.vcth-star-safe.vmon-search-route #buscador,
  body.vcth-star-safe.vmon-search-route .vmon381-search-results,
  body.vcth-star-safe.vmon-search-route .cth-vctf45-search-results-canvas{width:min(calc(100% - 20px),1240px)!important}
}
