/* Full HD and intermediate desktop widths: reserve space for combat actions.
   Above 2560 CSS pixels the established large-screen layout is unchanged. */
@media(min-width:1101px) and (max-width:2560px){
  body:has(>.learned-action-bar:not([hidden])){grid-template-columns:minmax(0,1fr) clamp(300px,22vw,400px)}
  body>.topbar,body>footer{grid-column:1/-1}
  body>.game,body>.game:has(#character-preview){grid-column:1;grid-row:2;max-width:none;margin:0;grid-template-columns:minmax(0,1fr) clamp(170px,13vw,250px);grid-template-rows:minmax(0,64fr) minmax(0,36fr)}
  body>.learned-action-bar{position:relative;grid-column:2;grid-row:2;inset:auto;margin:6px 6px 6px 0;width:auto;height:auto;max-height:none;min-height:0;min-width:0;padding:10px 10px 25px;z-index:5}
  body>.learned-action-bar.window-manipulating{z-index:10000}
  .learned-action-bar>header{flex-wrap:wrap;row-gap:8px}
  .learned-action-bar>header>strong{font-size:18px}
  .learned-action-bar .combat-panel-buttons{margin-left:auto}
  .learned-action-bar .combat-panel-content>small{font-size:11px}
  .learned-action-bar .combat-action-copy strong{font-size:16px;overflow-wrap:anywhere}
  .learned-action-bar .combat-action-use{gap:8px}
  .resource-sidebar>.character{flex:0 0 30%;padding:6px;border-width:8px}
  .resource-sidebar .character-name{gap:6px;margin-top:2px}
  .resource-sidebar .character-name h2{font-size:19px;overflow-wrap:anywhere}
  .resource-sidebar .character-name .portrait{width:28px;height:32px;font-size:22px}
  .resource-sidebar>.orb-dock{container-type:size;gap:6px;padding:6px;justify-content:space-evenly;overflow:hidden}
  .resource-sidebar .resource-orb{--holder-size:clamp(48px,calc((100cqh - 66px)/3),130px);height:calc(var(--holder-size) + 18px)}
  .resource-sidebar .resource-orb .orb-value{font-size:clamp(9px,2.7cqh,12px)}
  .resource-sidebar .resource-orb .orb-glass{overflow:visible;z-index:3}
  .resource-sidebar .resource-orb .orb-value{left:-20px;right:-20px}
  .resource-sidebar .resource-orb .orb-label{font-size:11px;line-height:16px}
  .world:has(.illustrated-scene) #room-caption{font-size:14px;line-height:1.45;max-height:84px;overflow:auto;overscroll-behavior:contain}
  .world:has(.illustrated-scene) .room-heading>.room-conditions{margin-top:6px}
  .room-combatants{gap:clamp(18px,3vw,60px);padding:6px 10px;max-height:200px}
  .room-combatants .npc-card{width:124px;flex-basis:124px}
  .room-combatants .npc-portrait,.room-combatants .npc-portrait-slot{height:82px}
  .illustrated-scene>.illustrated-exits{width:min(520px,100%);height:140px;min-height:140px;grid-template-rows:repeat(3,38px);padding:7px 10px;gap:5px 6px}
  #log{font-size:14px;line-height:1.4}
  .quick-actions{scrollbar-width:thin}.quick-actions button{min-height:30px;font-size:12px;padding:2px 7px}
  body:has(.game.console-only){grid-template-columns:minmax(0,1fr)}
  body>.game.console-only:has(#character-preview){grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,1fr);max-width:1920px;margin:auto}
}
@media(min-width:1101px) and (max-width:1500px){
  .resource-sidebar .character-name .portrait{display:none}
  .learned-action-bar .combat-action-use .skill-icon{width:46px;height:46px}
  .learned-action-bar .combat-action-copy strong{font-size:14px}
  .learned-action-bar .combat-action-copy small{font-size:10px}
  .room-combatants .npc-card{width:108px;flex-basis:108px}
}
@media(min-width:1101px) and (max-width:2560px) and (max-height:850px){
  .room-combatants{max-height:140px}.room-combatants .npc-portrait,.room-combatants .npc-portrait-slot{height:48px}
  .illustrated-scene>.illustrated-exits{height:118px;min-height:118px;grid-template-rows:repeat(3,32px)}
  .world:has(.illustrated-scene) #room-caption{max-height:44px;font-size:12px}
}
