/* Battle-only composition. Source scenery and registered creature poses stay intact. */
body[data-view=battle] .battle-layout { gap:16px; align-items:start; }
body[data-view=battle] .arena.stage-composed {
  --scenery:url('../../assets/rpg/stages/grassland-oblique-v02.png');
  --opponent-height:68px; --team-height:88px;
  height:550px; max-height:none; padding:0; background:#f7f8ef;
  border:1px solid #bdccb5; border-radius:20px; box-shadow:0 4px 0 #c9d2bd;
  isolation:isolate; overflow:hidden;
}
body[data-view=battle] .arena.stage-composed[data-place=water] { --scenery:url('../../assets/rpg/stages/waterfront-oblique-v01.png'); }
body[data-view=battle] .arena.stage-composed[data-place=rock] { --scenery:url('../../assets/rpg/stages/rocky-oblique-v01.png'); }

/* 章ごとの舞台背景（stages-v01・Codex 2026-10-11 納品）。body[data-region] は app.js の render が付ける。第一章・第二章は上の place 別の3枚のまま */
body[data-region="ex-savanna"] { --region-scenery:url('../../assets/rpg/display-v2/stages/stage-ex-savanna-oblique-v01.webp'); }
body[data-region="ex-island"] { --region-scenery:url('../../assets/rpg/display-v2/stages/stage-ex-island-oblique-v01.webp'); }
body[data-region="ex-heights"] { --region-scenery:url('../../assets/rpg/display-v2/stages/stage-ex-heights-oblique-v01.webp'); }
body[data-region="ex-forest-1"] { --region-scenery:url('../../assets/rpg/display-v2/stages/stage-ex-forest-1-oblique-v01.webp'); }
body[data-region="ex-forest-2"] { --region-scenery:url('../../assets/rpg/display-v2/stages/stage-ex-forest-2-oblique-v01.webp'); }
body[data-region="ex-forest-3"] { --region-scenery:url('../../assets/rpg/display-v2/stages/stage-ex-forest-3-oblique-v01.webp'); }
body[data-region="ex-forest-4"] { --region-scenery:url('../../assets/rpg/display-v2/stages/stage-ex-forest-4-oblique-v01.webp'); }
body[data-region="ex-forest-5"] { --region-scenery:url('../../assets/rpg/display-v2/stages/stage-ex-forest-5-oblique-v01.webp'); }
body[data-region="ex-land-1"] { --region-scenery:url('../../assets/rpg/display-v2/stages/stage-ex-land-1-oblique-v01.webp'); }
body[data-region="ex-water-1"] { --region-scenery:url('../../assets/rpg/display-v2/stages/stage-ex-water-1-oblique-v01.webp'); }
body[data-region="ex-water-2"] { --region-scenery:url('../../assets/rpg/display-v2/stages/stage-ex-water-2-oblique-v01.webp'); }
body[data-region="ex-water-3"] { --region-scenery:url('../../assets/rpg/display-v2/stages/stage-ex-water-3-oblique-v01.webp'); }
body[data-region="ex-air-1"] { --region-scenery:url('../../assets/rpg/display-v2/stages/stage-ex-air-1-oblique-v01.webp'); }
body[data-region="ex-air-2"] { --region-scenery:url('../../assets/rpg/display-v2/stages/stage-ex-air-2-oblique-v01.webp'); }
body[data-view=battle][data-region^=ex-] .arena.stage-composed, body[data-view=battle][data-region^=ex-] .arena.stage-composed[data-place] { --scenery:var(--region-scenery); }
body[data-region^=ex-] .story-stage:not(.story-night) { background-image:var(--region-scenery); }
.stage-composed .battle-opponent {
  position:absolute; inset:0 0 auto; height:var(--opponent-height); z-index:4;
  display:grid; grid-template-columns:minmax(112px, .65fr) minmax(0, 1fr);
  gap:18px; align-items:center; padding:9px 16px; background:#f8f9f1;
  border-bottom:1px solid #c6d0b8;
}
.stage-composed .battle-opponent .enemy-hud {
  position:static; width:auto; min-width:0; padding:0; transform:none;
  border:0; background:transparent; border-radius:0; box-shadow:none;
}
.battle-opponent .enemy-hud strong { display:block; font-size:16px; line-height:1.7; }
.battle-opponent .enemy-hud .meter { height:6px; margin:0; }
.battle-opponent .enemy-hud .hptext { font-size:11px; line-height:1.3; margin-top:2px; }
.battle-forecast { position:relative; min-width:0; padding-left:15px; border-left:1px solid #c6d0b8; }
.stage-composed .battle-forecast .intent {
  position:static; display:flex; flex-direction:column; align-items:flex-start;
  gap:2px; padding:0; margin:0; background:none; border:0; border-radius:0;
  font-size:13px; line-height:1.5; color:#40524a; box-shadow:none;
}
.battle-forecast .intent strong { font-size:15px; color:#70492b; }
.stage-composed .battle-forecast .motion-label {
  position:absolute; inset:0; padding:2px 0 2px 15px; background:#f8f9f1;
  border:0; border-radius:0; color:#274a3e; font-size:16px; line-height:1.5;
  display:flex; align-items:center; justify-content:flex-start; box-shadow:none;
}
.battle-forecast .motion-label:empty { display:none; }
.stage-composed .stage-space {
  position:absolute; inset:var(--opponent-height) 0 var(--team-height); height:auto;
  overflow:hidden; isolation:isolate; background:var(--scenery) center 58%/cover no-repeat;
}
.stage-composed .stage-space::before {
  content:''; position:absolute; inset:0; pointer-events:none; z-index:0;
  background:linear-gradient(180deg,#f5fae745,transparent 38%,#173e2420);
}
.stage-composed .stage-actors { z-index:1; }
.stage-composed .enemy-row {
  position:absolute; left:calc(53% - 62px); top:calc(36% - 110px);
  width:124px; height:110px; padding:0; transform:none;
}
.stage-composed .enemy-figure { width:124px; height:110px; }
.stage-composed .field-actor .role { display:none; }
.stage-composed .field-actor.selected-actor .role {
  display:block; position:absolute; top:auto; bottom:-26px; left:50%; transform:translateX(-50%);
  font-size:11px; line-height:1.5; padding:2px 8px; border-radius:12px;
  background:#fff9df; color:#3d573e; border:1px solid #ac914e; white-space:nowrap;
}
.stage-composed .unit-shadow {
  left:8%; width:84%; height:12%; bottom:-3px; opacity:.43; filter:blur(1px);
  background:radial-gradient(ellipse,#223921aa 0%,#2a472b80 32%,#304d3430 62%,transparent 74%);
}
.stage-composed .selected-actor .unit-shadow::after {
  content:''; position:absolute; inset:-3px -5px; border:2px solid #f3d276;
  border-radius:50%; box-shadow:0 0 0 1px #53634455;
}
.stage-composed [data-locomotion=fly] .unit-shadow { opacity:.28; scale:.9; }
.stage-composed [data-locomotion=swim] .unit-shadow {
  height:18%; bottom:-7px; opacity:.7; scale:1;
  background:radial-gradient(ellipse,#b8f2eb88 30%,#78c6d45c 48%,#d9ffff88 53%,transparent 63%);
}
.stage-composed .unit-body>.unit-sprite { filter:drop-shadow(2px 3px 2px #29442230); }
.battle-team {
  position:absolute; inset:auto 0 0; height:var(--team-height); z-index:4;
  display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:7px;
  padding:8px; border-top:1px solid #c6d0b8; background:#edf1e3;
}
.battle-team .team-status {
  min-width:0; min-height:44px; display:block; position:relative; text-align:left;
  border:1px solid #c4d0ba; border-radius:11px; background:#fffdf3;
  color:#25463b; padding:5px 9px; box-shadow:none; font-size:14px; line-height:1.4;
}
.team-status[aria-pressed=true] { border-color:#a98228; background:#fff5ce; box-shadow:inset 0 0 0 1px #ba973e; }
.team-status strong { display:block; font-size:15px; line-height:1.65; white-space:nowrap; }
.team-status .meter { height:5px; margin:2px 0 0; border-width:1px; }
.team-status .hptext { font-size:11px; line-height:1.35; margin-top:2px; }
.team-status .actor-mark { display:block; position:absolute; top:4px; right:5px; font-size:9px; color:#62705e; }
.battle-team .team-status[aria-pressed=true] .actor-mark { color:#705a22; }
body[data-view=battle] .combat-panel { background:#fafbf4; box-shadow:0 4px 0 #d0d7c6; }
body[data-view=battle] .combat-actions button { background:#fffef7; }
body[data-view=battle] .combat-actions button:not(:disabled):hover { background:#f0f4df; }
body[data-view=battle] .combat-actions button:focus-visible,
.battle-team button:focus-visible { outline:3px solid #bc8b28; outline-offset:2px; }
body[data-view=battle] .action-reason { color:#516453; }
body[data-view=battle] .combat-help { margin-top:16px; }
@media(max-width:760px) {
  body[data-view=battle] .arena.stage-composed { height:365px; --opponent-height:52px; --team-height:68px; border-radius:15px; }
  .stage-composed .battle-opponent { grid-template-columns:112px minmax(0,1fr); padding:5px 10px; gap:12px; }
  .battle-opponent .enemy-hud strong { font-size:13px; }
  .stage-composed .battle-forecast .intent { font-size:11px; }
  .battle-forecast .intent strong { font-size:13px; }
  .stage-composed .battle-forecast .motion-label { font-size:14px; }
  .stage-composed .enemy-row { left:calc(53% - 43px); top:calc(36% - 78px); width:86px; height:78px; }
  .stage-composed .enemy-figure { width:86px; height:78px; }
  .stage-composed .field-actor { --unit-size:94px!important; }
  .stage-composed .field-actor:first-child { --unit-size:112px!important; }
  .stage-composed .field-actor.selected-actor .role { bottom:-22px; font-size:10px; }
  .battle-team { padding:6px; gap:5px; }
  .battle-team .team-status { padding:4px 5px; border-radius:9px; }
  .team-status strong { font-size:12px; line-height:1.7; }
  .team-status .actor-mark { top:2px; right:4px; font-size:8px; }
  .team-status .hptext { font-size:10px; }
  body[data-view=battle] .combat-panel { margin-top:9px; }
  body[data-view=battle] .action-reason { font-size:11px; }
  body[data-view=battle] .selected-name strong { font-size:16px; line-height:1.6; }
  body[data-view=battle] .combat-actions { grid-template-columns:repeat(2,minmax(0,1fr)); }
  body[data-view=battle] .combat-actions button { min-height:56px; font-size:16px; line-height:1.25; padding:4px; }
  body[data-view=battle] .combat-actions button>strong { font-size:16px; }
  body[data-view=battle] .combat-actions button>span:last-child { font-size:12px; line-height:1.25; white-space:normal; }
  body[data-view=battle] .combat-top { min-height:40px; }
}
@media(max-height:500px) and (min-width:700px) {
  body[data-view=battle] .arena.stage-composed { height:310px; --opponent-height:49px; --team-height:64px; }
  body[data-view=battle] .battle-layout { gap:10px; }
  .stage-composed .battle-opponent { grid-template-columns:115px minmax(0,1fr); gap:12px; padding:3px 9px; }
  .battle-opponent .enemy-hud strong { font-size:12px; line-height:1.6; }
  .battle-opponent .enemy-hud .hptext { font-size:10px; }
  .battle-forecast .intent strong { font-size:13px; }
  .stage-composed .battle-forecast .intent { font-size:11px; }
  .stage-composed .enemy-row { left:calc(53% - 36px); top:calc(38% - 65px); width:72px; height:65px; }
  .stage-composed .enemy-figure { width:72px; height:65px; }
  .stage-composed .field-actor { --unit-size:68px!important; }
  .stage-composed .field-actor:first-child { --unit-size:89px!important; }
  .stage-composed .field-actor.selected-actor .role { bottom:-18px; font-size:9px; padding:0 5px; }
  .battle-team { gap:5px; padding:5px; }
  .battle-team .team-status { padding:2px 5px; border-radius:8px; }
  .team-status strong { font-size:12px; line-height:1.6; }
  .team-status .actor-mark { display:none; }
  .team-status .hptext { font-size:10px; line-height:1.15; }
  body[data-view=battle] .combat-help { margin-top:8px; }
}

/* ui-v02：相手のつぎの一手の絵 */
.intent{display:flex;align-items:center;gap:6px}.intent-art{width:28px;height:28px;flex:none;filter:drop-shadow(0 1px 1px #0008)}
