/* Contuhijo Core VMON4.0 · Marga reservation hardening.
   Scope is URL/body-class specific. Never hides or removes travellers (adults,
   children or any future traveller type); it only normalises layout. */
body.cth-marga-reservation{background:var(--md-paper,#f6f8fc)}
body.cth-marga-reservation .content.colibri-page-content{background:var(--md-paper,#f6f8fc)!important}
body.cth-marga-reservation .md-template{width:min(calc(100% - 36px),1240px)!important;max-width:1240px!important;margin:0 auto!important;padding:42px 0 84px!important;box-sizing:border-box!important}
body.cth-marga-reservation .md-template :where(.h-row-container,.h-row,.h-column,.h-column-container,.h-column__inner,.h-column__content){min-width:0!important;box-sizing:border-box!important}
body.cth-marga-reservation .md-template :where(input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),select,textarea){max-width:100%!important;box-sizing:border-box!important}
body.cth-marga-reservation .md-template img{max-width:100%!important;height:auto!important;object-fit:contain!important}

/* Reservation forms often arrive with desktop Colibri widths and floats. */
body.cth-marga-reservation .md-template form,
body.cth-marga-reservation .md-template form>div,
body.cth-marga-reservation .md-template :where(.control-group,.form-group,.form-row){max-width:100%!important;min-width:0!important;box-sizing:border-box!important}
body.cth-marga-reservation .md-template :where(.h-row,.row){gap:clamp(10px,1.5vw,18px)!important;align-items:flex-start!important}
body.cth-marga-reservation .md-template :where(label,.md-label){position:static!important;float:none!important;max-width:100%!important;line-height:1.25!important}
body.cth-marga-reservation .md-template :where(button,.md-btn,input[type="button"],input[type="submit"]){min-height:42px!important;box-sizing:border-box!important}

/* Quantity steppers: keep minus / value / plus together instead of allowing
   legacy images/icons to overlap labels or neighbouring fields. */
body.cth-marga-reservation .md-template :where(.input-group,.md-counter,.counter,.quantity,.cantidad,.pasajeros,.viajeros){min-width:0!important;box-sizing:border-box!important}
body.cth-marga-reservation .md-template :where(.input-group,.md-counter,.counter,.quantity) img{width:22px!important;height:22px!important;max-width:22px!important;max-height:22px!important;margin:0!important}
body.cth-marga-reservation .md-template :where(.input-group,.md-counter,.counter,.quantity) :where(button,.md-btn,input[type="button"]){position:static!important;float:none!important;flex:0 0 auto!important;margin:0!important}

/* Identification fields should form a deliberate grid on desktop rather than
   a narrow column stranded on the left. We only target form groups/columns. */
@media(min-width:768px){
  body.cth-marga-reservation .md-template form :where(.h-row,.row){width:100%!important;max-width:100%!important}
  body.cth-marga-reservation .md-template form [class*="h-col-"]{min-width:0!important}
}

@media(max-width:767px){
  body.cth-marga-reservation .md-template{width:min(calc(100% - 20px),1240px)!important;padding:24px 0 56px!important}
  body.cth-marga-reservation .md-template :where(.h-row,.row){display:block!important;margin-left:0!important;margin-right:0!important}
  body.cth-marga-reservation .md-template form [class*="h-col-"],
  body.cth-marga-reservation .md-template form [class*="col-"]{display:block!important;float:none!important;width:100%!important;max-width:100%!important;min-width:0!important;flex:0 0 100%!important;padding-left:0!important;padding-right:0!important;margin:0 0 12px!important}
  body.cth-marga-reservation .md-template :where(input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),select,textarea){width:100%!important;max-width:100%!important;min-width:0!important;font-size:16px!important}
  body.cth-marga-reservation .md-template :where(input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),select){min-height:46px!important}
  body.cth-marga-reservation .md-template textarea{min-height:130px!important}
  body.cth-marga-reservation .md-template :where(input[type="checkbox"],input[type="radio"]){width:auto!important;min-width:0!important;min-height:0!important}
  body.cth-marga-reservation .md-template :where(.input-group,.md-counter,.counter,.quantity){display:inline-flex!important;align-items:center!important;gap:6px!important;width:auto!important;max-width:100%!important;vertical-align:middle!important}
  body.cth-marga-reservation .md-template :where(.input-group,.md-counter,.counter,.quantity) :where(button,.md-btn,input[type="button"]){width:42px!important;min-width:42px!important;max-width:42px!important;height:42px!important;min-height:42px!important;padding:0!important;display:grid!important;place-items:center!important}
  body.cth-marga-reservation .md-template :where(img,svg){max-width:100%!important}
}
