/* Phase 35: per-page visual acceptance corrections on top of the shared Phase 34 style.
   Scoped to public browsing cards. Do NOT style global headers, footers, booking forms,
   payment controls or administrative/operator pages. Booking data remains server-driven. */
body.ui-customer {
  --ms35-radius:16px;
  --ms35-green:#0c654d;
  --ms35-green-dark:#0a4f3d;
  --ms35-cream:#fffaf5;
  --ms35-quiet:#4e6b60;
  --ms35-focus:#ea705c;
}
/* Keep images, card body and action row balanced on different data lengths. */
body.ui-customer :is(.tour-card,.me-card,.ms-stay-property,.destinations-card,.destination-tour-card) {
  display:flex;
  flex-direction:column;
  overflow:hidden;
  border-radius:var(--ms35-radius);
  isolation:isolate;
}
body.ui-customer :is(.tour-card,.me-card,.ms-stay-property,.destinations-card,.destination-tour-card) :is(.tour-media,.me-card-image,.ms-stay-property-image,.destinations-card-image,.destination-tour-image){
  aspect-ratio:1.86;
  height:auto;
  min-height:0;
  flex:0 0 auto;
}
body.ui-customer :is(.tour-card,.me-card,.ms-stay-property,.destinations-card,.destination-tour-card) :is(.tour-media,.me-card-image,.ms-stay-property-image,.destinations-card-image,.destination-tour-image) img{
  width:100%;height:100%;object-fit:cover;
}
/* Stop inherited old template minimum heights producing empty card space. */
body.ui-customer .tour-card .tour-body,
body.ui-customer .me-card .me-card-content,
body.ui-customer .ms-stay-property .ms-stay-property-body,
body.ui-customer .destinations-card .destinations-card-body,
body.ui-customer .destination-tour-card .destination-tour-info{
  min-height:0 !important;
  flex:1 1 auto;
  display:flex;
  flex-direction:column;
  gap:5px;
  padding:7px 11px 10px;
}
/* Readable sans-serif hierarchy at the smaller card size. */
body.ui-customer :is(.tour-card,.me-card,.ms-stay-property,.destinations-card,.destination-tour-card) h3,
body.ui-customer :is(.tour-card,.me-card,.ms-stay-property,.destinations-card,.destination-tour-card) h3 a{
  font-family:'DM Sans',system-ui,sans-serif !important;
  font-style:normal !important;
  font-size:15px !important;
  font-weight:800;
  line-height:1.28;
  letter-spacing:-.015em;
  min-height:0 !important;
  margin:0;
}
body.ui-customer :is(.tour-card,.me-card,.ms-stay-property,.destinations-card,.destination-tour-card) :is(.tour-kicker,.me-card-meta,.ms-stay-location,.destinations-card-region,.destination-tour-meta){
  color:var(--ms35-quiet);
  font-size:11px;
  line-height:1.35;
}
body.ui-customer :is(.tour-card,.me-card,.ms-stay-property,.destinations-card,.destination-tour-card) :is(.marsata-tour-excerpt,.ms-stay-description,.destinations-card-body p,.destination-tour-info p,.me-card-date){
  font-size:11px;
  line-height:1.4;
  color:#52685e;
  display:-webkit-box;
  -webkit-box-orient:vertical;
  -webkit-line-clamp:2;
  overflow:hidden;
  margin:0;
  min-height:0;
}
body.ui-customer .tour-card .tour-body .meta{margin:0;min-height:0;}
body.ui-customer .tour-card .tour-meta-row {font-size:11px;min-height:0;}
body.ui-customer .tour-card .tour-footer,
body.ui-customer .me-card .me-card-bottom,
body.ui-customer .ms-stay-property .ms-stay-property-bottom,
body.ui-customer .destination-tour-card .destination-tour-bottom{
  margin-top:auto;
  min-height:38px;
  padding:5px 7px;
  border-radius:10px;
  display:flex;
  flex-direction:row;
  align-items:center;
  justify-content:space-between;
  gap:6px;
  border:0;
}
body.ui-customer .tour-card .tour-footer,
body.ui-customer .me-card .me-card-bottom,
body.ui-customer .destination-tour-card .destination-tour-bottom{background:#f8eee3;}
body.ui-customer .ms-stay-property .ms-stay-property-bottom{background:#eaf3e9;}
body.ui-customer :is(.tour-card .price,.me-card-price,.ms-stay-property-bottom>div,.destination-tour-bottom>span){
  min-width:0;
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:3px;
  font-variant-numeric:tabular-nums;
}
body.ui-customer .tour-card .price>span:not(.price-range),
body.ui-customer .me-card .me-card-price strong,
body.ui-customer .ms-stay-property .ms-stay-property-bottom strong{
  background:var(--ms35-green);
  color:#fff;
  border:0;
  border-radius:999px;
  font-family:'DM Sans',system-ui,sans-serif;
  font-weight:800;
  font-size:12px;
  line-height:1.2;
  max-width:100%;
  padding:5px 8px;
  white-space:normal;
  overflow-wrap:anywhere;
  word-break:normal;
}
body.ui-customer :is(.tour-card .price small,.me-card-price span,.ms-stay-property-bottom .tiny){font-size:10px;line-height:1.3;}
body.ui-customer .tour-card .tour-actions a,
body.ui-customer .ms-stay-property .ms-stay-property-bottom .button,
body.ui-customer .me-card .me-card-button{
  width:34px;
  height:34px;
  min-width:34px;
  min-height:34px;
  flex:0 0 34px;
  padding:0;
  border-radius:50%;
  background:var(--ms35-green);
  color:#fff;
  display:grid;
  place-items:center;
  border:0;
  box-shadow:0 2px 5px #153e3420;
  text-decoration:none;
}
body.ui-customer .me-card .me-card-button{font-size:0;gap:0;}
body.ui-customer .me-card .me-card-button span{font-size:19px;color:#fff;line-height:1;}
body.ui-customer .ms-stay-property .ms-stay-property-bottom .button{font-size:0;color:transparent;}
body.ui-customer .ms-stay-property .ms-stay-property-bottom .button::after{content:'→';color:#fff;font-size:18px;line-height:1;}
body.ui-customer .ms-stay-property .ms-stay-property-bottom>div{gap:4px;}
/* The disabled/card-empty states are not compact discovery cards and retain their controls. */
body.ui-customer .me-card .me-card-meta>span{display:inline-flex;align-items:center;gap:4px;min-width:0;}
body.ui-customer .me-card .me-card-meta svg{width:13px;height:13px;flex:0 0 13px;color:var(--ms35-green);}
body.ui-customer .me-card .me-card-calendar{z-index:4;}
body.ui-customer .ms-stay-property .ms-stay-fallback{height:100%;display:grid;place-items:center;background:linear-gradient(135deg,#e5f1e9,#c7e3d6);font-size:38px;color:#257058;}
body.ui-customer .ms-stay-property .ms-stay-card-facts span{font-size:10px;line-height:1.25;}
body.ui-customer .ms-stay-property .ms-stay-match-tag{font-size:10px;}
/* Destination cards have no price; show a clear text link and a matching arrow disc. */
body.ui-customer .destinations-card .destinations-card-cta{
  margin-top:auto;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:8px;
  border-radius:10px;
  padding:4px 5px 4px 9px;
  min-height:38px;
  font-size:11px;
  font-weight:750;
  background:#eaf3e9 !important;
  color:var(--ms35-green-dark) !important;
}
body.ui-customer .destinations-card .destinations-card-cta span{
  display:grid;place-items:center;
  flex:0 0 28px;
  width:28px;height:28px;
  border-radius:50%;
  background:var(--ms35-green);
  color:#fff;
  font-size:17px;
}
/* Keep bus result timeline readable; only align action treatment and typography. */
body.ui-customer .mbus .mbus-result-card{font-family:'DM Sans',system-ui,sans-serif;}
body.ui-customer .mbus .mbus-result-card .mbus-btn{font-weight:750;}
/* Explicit keyboard focus; image links and wishlist buttons remain accessible. */
body.ui-customer :is(.tour-card,.me-card,.ms-stay-property,.destinations-card,.destination-tour-card) :is(a,button):focus-visible{
  outline:3px solid var(--ms35-focus);
  outline-offset:2px;
}
@media(max-width:610px){
  body.ui-customer :is(.tour-card,.me-card,.ms-stay-property,.destinations-card,.destination-tour-card) :is(.tour-body,.me-card-content,.ms-stay-property-body,.destinations-card-body,.destination-tour-info){padding:8px 10px 10px;}
  body.ui-customer .tour-card .tour-body h3{font-size:15px !important;}
}
@media(prefers-reduced-motion:reduce){
  body.ui-customer :is(.tour-card,.me-card,.ms-stay-property,.destinations-card,.destination-tour-card):hover{transform:none;}
}
