/* AMBA WORLD v111. Focused adjustments ONLY to the nine approved scenes. */

/* 1. Yue's retry: show more of AMBA and Yue, without changing dialogue/actions. */
#guilinRoot #guilinDialog > .guilin-panel.guilin-retry-card .guilin-hero-art{
  height:clamp(208px,42dvh,355px)!important;
  padding:0!important;
  background:#394b69!important;
}
#guilinRoot #guilinDialog > .guilin-panel.guilin-retry-card .guilin-hero-art img{
  width:100%!important;height:100%!important;
  object-fit:cover!important;object-position:center 43%!important;
}
@media(orientation:landscape) and (max-height:560px){
 #guilinRoot #guilinDialog > .guilin-panel.guilin-retry-card .guilin-hero-art{
  height:clamp(150px,40dvh,230px)!important;
 }
}

/* 2. Jade reward: one uniform SMALLER sprite box for all five AMBA poses.
   No changes to Lian, pendant, transfer sequence or caption. */
#guilinRoot #guilinReward.gcin-jade-mode .gcin-stage > .gcin-actor.amba{
  left:11%!important;bottom:3%!important;
  width:35%!important;height:70%!important;
  max-width:none!important;object-fit:contain!important;object-position:left bottom!important;
}
@media(orientation:portrait) and (max-width:820px){
 #guilinRoot #guilinReward.gcin-jade-mode .gcin-stage > .gcin-actor.amba{
  left:5%!important;bottom:3%!important;width:42%!important;height:69%!important;
 }
}

/* 3. Singapore destination entry in landscape: less unused cream space. */
@media(orientation:landscape){
 #singaporeRoot #sg-modal > .sg-modal-card.country-start .sg-stage{
  height:clamp(165px,37dvh,300px)!important;
 }
 #singaporeRoot #sg-modal > .sg-modal-card.country-start .sg-caption{
  padding:8px 15px 9px!important;
 }
 #singaporeRoot #sg-modal > .sg-modal-card.country-start .sg-actions{
  margin:6px 2px 0!important;
 }
}
/* 4. Singapore destination portrait: bring AMBA, cart and Vibey higher
   and closer together without substituting/repainting the supplied art. */
@media(orientation:portrait){
 #singaporeRoot #sg-modal > .sg-modal-card.country-start .sg-stage{
  height:clamp(195px,34dvh,315px)!important;
 }
 #singaporeRoot #sg-modal > .sg-modal-card.country-start .sg-stage .sg-cine-amba{
  bottom:12%!important;width:18%!important;max-height:62%!important;
 }
 #singaporeRoot #sg-modal > .sg-modal-card.country-start .sg-stage .cart-peek{
  bottom:11%!important;width:33%!important;max-height:70%!important;
 }
}

/* 5. New Mission baton artwork: give dialogue and buttons their own space.
   Does not touch the finished handover or any other Singapore cinematic. */
#singaporeRoot #sg-modal > .sg-modal-card.mission-card .sg-stage{
  height:clamp(165px,29dvh,255px)!important;
  aspect-ratio:auto!important;
}
#singaporeRoot #sg-modal > .sg-modal-card.mission-card .sg-stage .sg-v78-handover-panel{
  height:94%!important;max-width:96%!important;bottom:1%!important;
}
#singaporeRoot #sg-modal > .sg-modal-card.mission-card .sg-caption{
  padding:10px 15px 12px!important;
}
@media(orientation:landscape){
 #singaporeRoot #sg-modal > .sg-modal-card.mission-card .sg-cinematic{
  display:grid!important;grid-template-columns:minmax(0,57%) minmax(0,43%)!important;
  align-items:stretch!important;
 }
 #singaporeRoot #sg-modal > .sg-modal-card.mission-card .sg-stage{
  grid-column:1!important;grid-row:1!important;height:clamp(155px,47dvh,246px)!important;
 }
 #singaporeRoot #sg-modal > .sg-modal-card.mission-card .sg-caption{
  grid-column:2!important;grid-row:1!important;
  display:flex!important;flex-direction:column!important;justify-content:center!important;
  align-items:flex-start!important;border-top:0!important;border-left:1px solid #d8af82!important;
 }
 #singaporeRoot #sg-modal > .sg-modal-card.mission-card .sg-caption p{
  font-size:clamp(12px,1.25vw,16px)!important;line-height:1.33!important;
 }
}
@media(orientation:portrait){
 #singaporeRoot #sg-modal > .sg-modal-card.mission-card .sg-stage{
  height:clamp(165px,29dvh,245px)!important;
 }
}

/* 6. 10-second sprint: less cropped gate and Vibey, tidy copy. */
#singaporeRoot #sg-modal > .sg-modal-card.rush-intro .sg-stage .sg-scene-art{
  object-fit:contain!important;object-position:center!important;
  background:linear-gradient(145deg,#7c69ae,#dfa5c8)!important;
}
#singaporeRoot #sg-modal > .sg-modal-card.rush-intro .sg-caption{
  padding:8px 13px 10px!important;
}
#singaporeRoot #sg-modal > .sg-modal-card.rush-intro .sg-caption p{
  line-height:1.32!important;
}

/* 7. Retry: pill must NOT stretch across the right column. */
#singaporeRoot #sg-modal > .sg-modal-card.rush-retry .sg-caption{
  align-items:flex-start!important;justify-content:center!important;gap:8px!important;
  padding:16px 17px!important;
}
#singaporeRoot #sg-modal > .sg-modal-card.rush-retry .sg-name{
  width:max-content!important;max-width:100%!important;
  flex:0 0 auto!important;align-self:flex-start!important;
  margin:0 0 4px!important;
}
#singaporeRoot #sg-modal > .sg-modal-card.rush-retry .sg-caption p{
  width:100%!important;line-height:1.36!important;
}

/* 8. During the active victory cinematic the HUD has no purpose.
   Re-enable automatically when the existing victory phase ends. */
#singaporeRoot.sg-v91-victory-cinematic > :is(.sg-top,.sg-quest,.sg-mobile,.amba-mini-hud,.sg-hint){
  visibility:hidden!important;pointer-events:none!important;
}

/* 9. Landscape victory card: keep more of both characters' faces and
   slightly reduce the weight of the ivory text area. */
@media(orientation:landscape){
 #singaporeRoot #sg-modal > .sg-modal-card.victory-card .sg-stage{
  height:clamp(170px,44dvh,275px)!important;
 }
 #singaporeRoot #sg-modal > .sg-modal-card.victory-card .sg-stage .sg-scene-art{
  object-position:center 23%!important;
 }
 #singaporeRoot #sg-modal > .sg-modal-card.victory-card .sg-caption{
  padding:6px 12px 8px!important;
 }
 #singaporeRoot #sg-modal > .sg-modal-card.victory-card .sg-actions{
  margin-top:7px!important;
 }
}
