/* Keep Balat's painted head in its own space between the deck and the fan. */
#play-screen .ll-match .ll-scenery img {object-position:24% center;opacity:.36}
#play-screen .ll-match .ll-match-body {
  isolation:isolate;
  display:grid;
  grid-template-columns:minmax(0,36%) minmax(0,1fr);
  align-items:center;
  overflow:hidden;
}
.ll-balat-scene {
  position:absolute;inset:0;z-index:-1;overflow:hidden;pointer-events:none;
  container-type:size;
  background:
    radial-gradient(ellipse at 55% 34%,#93602b6b,transparent 54%),
    linear-gradient(100deg,#0a1714ad,#171b1300 56%,#13211b63);
}
.ll-balat-portrait {
  position:absolute;display:block;
  width:min(58vw,119cqh,900px);max-width:none;height:auto;
  left:56%;top:2%;transform:translateX(-50%);
  mask-image:linear-gradient(90deg,transparent,#000 21%,#000 78%,transparent),
             linear-gradient(0deg,transparent,#000 22%,#000 96%,transparent);
  mask-composite:intersect;
}
#play-screen .ll-match .ll-match-copy {grid-column:1;grid-row:1;justify-self:start;max-width:555px}
#play-screen .ll-match .ll-fan {grid-column:2;grid-row:1;align-self:end;justify-self:end;width:min(29vw,49cqh,442px);margin:0 0 min(4vh,34px)}
@media (max-width:730px) and (orientation:portrait) {
  #play-screen .ll-match .ll-match-body {
    --portrait-band:clamp(103px,23dvh,240px);
    grid-template-columns:1fr;grid-template-rows:var(--portrait-band) auto;align-content:start;
    padding:0 max(12px,env(safe-area-inset-left)) 8px;gap:0;overflow:auto;
  }
  #play-screen .ll-match .ll-balat-scene {inset:0 0 auto;height:calc(var(--portrait-band) + 30px)}
  #play-screen .ll-match .ll-balat-portrait {width:min(100vw,190cqh);top:0;left:46%}
  #play-screen .ll-match .ll-match-copy {grid-row:2;justify-self:center;width:min(100%,500px);padding:clamp(12px,2dvh,25px)}
  #play-screen .ll-match .ll-fan {display:block;grid-column:1;grid-row:1;justify-self:end;align-self:end;width:clamp(65px,20vw,138px);margin:0 2% 8px}
  #play-screen .ll-match .ll-deck-options {display:flex;flex-wrap:nowrap;overflow-x:auto}
  #play-screen .ll-match .ll-deck-tile {flex:0 0 auto}
}
@media (orientation:landscape) and (max-height:595px) {
  #play-screen .ll-screen.ll-match {display:flex;flex-direction:column}
  #play-screen .ll-screen.ll-match .ll-match-body {display:grid;grid-template-columns:49% 1fr;grid-template-rows:minmax(0,1fr);flex:1;min-height:0;width:100%;padding:3px max(12px,env(safe-area-inset-left));overflow:hidden}
  #play-screen .ll-match .ll-match-copy {display:block;max-height:100%;overflow:auto;align-self:center;grid-row:1;padding:9px 13px}
  #play-screen .ll-match .ll-balat-portrait {left:73%;width:min(64vw,150cqh);top:.5%}
  #play-screen .ll-match .ll-fan {display:none}
  #play-screen .ll-match .ll-dock {display:block;width:100%;max-width:none;padding:3px max(12px,env(safe-area-inset-left));flex:none}
  #play-screen .ll-match .ll-dock h3 {display:none}
  #play-screen .ll-match .ll-deck-options {display:flex;flex-direction:row;flex-wrap:nowrap;overflow:auto}
}
#play-screen .db-ward {display:block;color:#eee1b5;font:600 10px/1.2 var(--rh-reading,system-ui);letter-spacing:.045em}
#play-screen .db-shell .db-end.db-end-cue {outline:1px solid #f3d293;outline-offset:2px;color:#fff2c9;box-shadow:0 0 12px #d6aa5a60}
#play-screen .cp-ward-note {color:#ecdaae;font-size:.9em}
#play-screen .ll-history .ll-history-sheet {color:var(--rh-glass-text,#e7e6d6)}
#play-screen .ll-history .ll-history-sheet :is(h2,h3,summary,strong) {color:var(--rh-glass-title,#ffe5b1)}
#play-screen .cl-dialog[data-surface="glass"] :is(.cl-mythic-choices,.cl-log-entry,.cl-checkout,.cl-subtle,.cl-prefs) {color:#e3e8db}
#play-screen .cl-dialog[data-surface="glass"] :is(.cl-log-entry summary,.cl-ledger h3,.cl-checkout dd) {color:#ffe6b7}
#play-screen .cl-dialog[data-surface="glass"] :is(.cl-log-entry time,.cl-log-pack small) {color:#ced5c8}
#play-screen .cl-shell .cl-dialog:has(.cl-mythic-choices,.cl-ledger,.cl-log-entry) {inline-size:min(44rem,calc(100% - 28px))}
#play-screen .cl-shell .cl-dialog[data-surface="glass"] {--cl-muted:var(--rh-instrument-muted);--cl-ink:var(--rh-instrument-ink);--cl-gold:var(--rh-instrument-gold)}
#play-screen .cl-shell .cl-dialog[data-surface="glass"] .cl-mythic-choices h3 {color:var(--rh-instrument-gold)}
@media (max-width:360px) and (orientation:portrait) {
  #play-screen .ll-match .ll-balat-portrait {width:min(91vw,168cqh);top:0;left:45%}
}
