/* Replay keeps arithmetic inside the arena and camps visible during the march. */
.battle-board #battle-reveal.replay-host{
 position:absolute;z-index:12;left:50%;top:50%;right:auto;bottom:auto;
 width:min(690px,calc(100% - 24px));height:min(330px,calc(100% - 20px));
 transform:translate(-50%,-50%);padding:0;border:0;border-radius:0;
 background:none;box-shadow:none;pointer-events:none;color:#24412d;
}
.battle-board #battle-reveal.replay-host[hidden]{display:none}
.replay-host .battle-replay{
 height:100%;max-height:100%;padding:12px 16px;border:1px solid #baa36d;
 border-radius:11px;background:linear-gradient(140deg,#fff5dd,#e7d8b4);
 box-shadow:0 9px 30px #08211770;display:flex;flex-direction:column;color:#263e2d;
 overflow:hidden;--replay-progress:inherit;
}
.replay-host .replay-heading{display:flex;align-items:center;gap:10px;min-height:23px;padding:0;margin:0;flex-shrink:0}
.replay-host .replay-heading>span{font-size:9px;font-weight:800;color:#896d36;border:1px solid #ac925552;padding:3px 7px;border-radius:4px;white-space:nowrap}
.replay-host .replay-heading>b{font-size:15px;color:#23432e;line-height:1.25}
.replay-host .replay-progress{height:3px;min-height:3px;background:#b4a17138;border-radius:5px;margin:7px 0 10px;overflow:hidden;flex-shrink:0}
.replay-host .replay-progress>span{height:100%;display:block;width:var(--replay-progress,0%);background:#5e7547;border-radius:5px;transition:none}
.replay-host :is(.replay-reveal,.replay-calculation,.replay-motion,.replay-assault,.replay-result){display:none;min-height:0}
.replay-host[data-phase="reveal"] .replay-reveal{display:block}
.replay-host[data-phase="calculation"] .replay-calculation{display:block}
.replay-host:is([data-phase="charge"],[data-phase="impact"]) .replay-motion{display:block}
.replay-host[data-phase="assault"] .replay-assault{display:block}
.replay-host[data-phase="result"] .replay-result{display:block}
.replay-host :is(.replay-reveal,.replay-calculation,.replay-assault,.replay-result){overflow:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#a18a55 transparent;pointer-events:auto}
.replay-host .replay-teams{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px;min-width:0}
.replay-host .replay-team{min-width:0;padding:0 0 0 12px;border-left:3px solid #98764c}
.replay-host .replay-team.own{border-color:#5f8153}
.replay-host .replay-team>div{margin:0}
.replay-host .replay-team small{letter-spacing:0;font-weight:600}
.replay-host .replay-team-heading{display:flex;flex-direction:column;gap:3px;min-width:0;margin:0 0 7px}
.replay-host .replay-team-heading>small{font-size:8px;font-weight:800;letter-spacing:1px;color:#907957}
.replay-host .replay-team-heading>b{font-size:16px;color:#253e2b;line-height:1.15;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.replay-host .replay-portrait{display:block;width:60px;height:60px;border-radius:50%;overflow:hidden;border:2px solid #a68851;background:#233e2b;margin:0 0 6px;box-shadow:0 3px 8px #6a583e26}
.replay-host .replay-portrait>svg{display:block;width:100%;height:100%}
.replay-host .replay-portrait.placeholder{font-size:30px;line-height:56px;text-align:center;color:#e9d6a5}
.replay-host .replay-troops{display:block;font-size:27px;color:#284a32;font-variant-numeric:tabular-nums;line-height:1.1}
.replay-host .replay-troops small{font-size:10px;color:#8b7556;font-weight:600}
.replay-host .replay-boost{display:block;font-size:9px;color:#8b6c41;margin-top:5px}
.replay-host .replay-commitment{margin-top:7px!important;padding-top:5px;border-top:1px solid #b7a27250}
.replay-host .replay-commitment>div{display:flex;justify-content:space-between;gap:7px;font-size:10px;line-height:1.45;color:#79674b}
.replay-host .replay-commitment b{font-variant-numeric:tabular-nums;color:#375539;white-space:nowrap}
.replay-host[data-phase="reveal"][data-detail="opponent"] .replay-reveal .own{opacity:.38}
.replay-host :is(.replay-base-step,.replay-power-step,.replay-multiply-step,.replay-attack-step,.replay-final-step){display:none}
.replay-host[data-detail="base"] .replay-base-step{display:block}
.replay-host[data-detail="effects"] .replay-power-step{display:block}
.replay-host[data-detail="multiply"] .replay-multiply-step{display:block}
.replay-host[data-detail="attack-effects"] .replay-attack-step{display:block}
.replay-host[data-detail="final"] .replay-final-step{display:block}
.replay-host .replay-stage-label{font-size:9px;font-weight:800;color:#846e44;line-height:1.25;margin-bottom:6px!important}
.replay-host .replay-stage-note{font-size:11px;line-height:1.5;color:#7b6c50;margin:12px 0 0}
.replay-host .replay-adjustment{
 display:flex;align-items:baseline;justify-content:space-between;gap:8px;
 padding:3px 0;font-size:11px;color:#77664d;line-height:1.25;margin:0;
}
.replay-host .replay-adjustment>span,.replay-host .replay-adjustment>dt{font-size:inherit;color:inherit;min-width:0}
.replay-host .replay-adjustment>b,.replay-host .replay-adjustment>dd{margin:0;white-space:nowrap;font-size:13px;font-weight:800;font-variant-numeric:tabular-nums;color:#355339}
.replay-host .replay-adjustment.negative>b{color:#a05c3c}
.replay-host .replay-adjustment.positive>b{color:#56723e}
.replay-host .replay-effect{padding:4px 5px;margin:1px -5px;border-radius:4px;align-items:center;transition:background .15s}
.replay-host .replay-effect>span>small{display:block;font-size:9px;line-height:1.2;color:#8c7754;margin-top:1px;overflow-wrap:anywhere}
.replay-host .replay-effect[data-applied="false"][data-active="false"]{opacity:.43}
.replay-host .replay-effect[data-active="true"]{background:#c9b57448;box-shadow:inset 3px 0 #a17b38}
.replay-host .replay-effect.negative[data-active="true"]{background:#d4977940;box-shadow:inset 3px 0 #ae6241}
.replay-host .replay-effect[data-applied="true"]{opacity:1}
.replay-host .replay-total{
 display:flex;justify-content:space-between;align-items:baseline;gap:8px;
 border-top:1px solid #baa37861;padding-top:6px;margin:6px 0 0;
}
.replay-host .replay-total>dt{font-size:10px;color:#786746}
.replay-host .replay-total>dd{font-size:25px;font-weight:850;color:#284b32;line-height:1.05;margin:0;white-space:nowrap;font-variant-numeric:tabular-nums}
.replay-host .replay-total.attack{display:block;margin-top:8px}
.replay-host .replay-total.attack>dt{font-size:10px;color:#806b48;margin-bottom:4px}
.replay-host .replay-total.attack>dd{font-size:30px}
.replay-host .replay-controls{margin-top:5px!important;display:flex;flex-wrap:wrap;gap:3px}
.replay-host .replay-control{font-size:8px;padding:2px 4px;border:1px solid #b5946761;border-radius:3px;color:#936344}
.replay-host .replay-control-source{display:block;flex-basis:100%;font-size:8px;color:#8c6443;line-height:1.35}
.replay-host .replay-equation{display:flex;align-items:center;gap:13px;padding-top:9px;color:#325438;font-variant-numeric:tabular-nums}
.replay-host .replay-equation>b{font-size:28px;line-height:1}
.replay-host .replay-equation>i{font-size:23px;font-style:normal;color:#9c835a}
.replay-host .replay-equation-label{font-size:10px;color:#8b7653;margin:7px 0 16px!important}
.replay-host .replay-product{font-size:32px;font-weight:850;color:#284b31;white-space:nowrap;font-variant-numeric:tabular-nums}
.replay-host .replay-boost-note{display:block;font-size:9px;line-height:1.4;color:#9a7348;margin-top:10px}
.replay-host .replay-comparison{display:none;font-size:10px;line-height:1.4;color:#826b45;margin:10px 0 0;padding-top:7px;border-top:1px solid #b9a16a40}
.replay-host[data-detail="final"] .replay-comparison{display:block}
.battle-board #battle-reveal.replay-host:is([data-phase="charge"],[data-phase="impact"]){height:auto;top:50%;transform:translate(-50%,-50%);width:min(490px,calc(100% - 24px))}
.replay-host:is([data-phase="charge"],[data-phase="impact"],[data-phase="assault"]) .battle-replay{padding:8px 12px;background:#183021f2;border-color:#b69c5a70;box-shadow:0 3px 15px #0003;color:#edd6a4}
.replay-host:is([data-phase="charge"],[data-phase="impact"],[data-phase="assault"]) .replay-heading>b{color:#f3dfb5;font-size:12px}
.replay-host:is([data-phase="charge"],[data-phase="impact"],[data-phase="assault"]) .replay-heading>span{color:#d0b777;border-color:#b5965861}
.replay-host:is([data-phase="charge"],[data-phase="impact"],[data-phase="assault"]) .replay-progress{margin:5px 0}
.replay-host .replay-motion-numbers{display:grid;grid-template-columns:1fr 1fr;gap:14px;font-size:9px;line-height:1.3}
.replay-host .replay-motion-numbers>span{display:flex;align-items:center;justify-content:space-between;gap:5px;min-width:0}
.replay-host .replay-motion-numbers b{font-size:13px;white-space:nowrap;color:#f6df9a;font-variant-numeric:tabular-nums}
.battle-board #battle-reveal.replay-host[data-phase="assault"]{height:auto;max-height:calc(100% - 100px);top:50%;width:min(480px,calc(100% - 24px));transform:translate(-50%,-50%)}
.replay-host .replay-assault .replay-team{padding-left:0;border:0}
.replay-host .replay-assault-target{font-size:11px;color:#e5cc99;line-height:1.3}
.replay-host .replay-damage-formula{display:flex;flex-wrap:wrap;gap:2px 7px;margin-top:4px!important;font-size:9px;color:#bcbd96;line-height:1.3}
.replay-host .replay-damage-formula>b{color:#eed38c}
.replay-host .replay-assault-loss{display:flex;justify-content:space-between;align-items:baseline;font-size:10px;margin-top:5px!important;color:#d6c8a6}
.replay-host .replay-assault-loss>b{font-size:22px;color:#f0c486;font-variant-numeric:tabular-nums}
.replay-host .replay-assault-health{font-size:14px;color:#e3d5ad;font-variant-numeric:tabular-nums;text-align:center;line-height:1.2}
.replay-host .replay-assault-health>b{color:#ffdda0}
.replay-host .replay-assault-health>small,.replay-host .replay-assault .replay-team>small{font-size:8px;color:#ccb891}
.replay-host .replay-verdict{font-size:15px;font-weight:850;color:#416036;line-height:1.2;margin:0 0 9px}
.replay-host .replay-result .replay-team-heading{margin-bottom:5px}
.replay-host .replay-damage-build{display:flex!important;flex-wrap:wrap;gap:3px 8px;font-size:9px;line-height:1.3;color:#8d7855;margin-bottom:4px!important}
.replay-host .replay-total.damage>dd{font-size:28px;color:#995737}
.replay-host .replay-camp-summary{padding-top:6px;margin-top:6px!important;border-top:1px solid #baa37850}
.replay-host .replay-camp-summary>span:first-child{font-size:9px;color:#7d6b4b}
.replay-host .replay-camp-equation{display:flex;align-items:baseline;gap:6px;font-size:15px;line-height:1.3;color:#3f5a3b;font-variant-numeric:tabular-nums}
.replay-host .replay-camp-equation>i{font-style:normal;color:#9a7750;font-size:12px}
.replay-host .replay-camp-bar{display:block;height:4px;background:#ba9f7b38;border-radius:4px;overflow:hidden;margin-top:3px}
.replay-host .replay-camp-bar>i{display:block;height:100%;background:#65804b}
.replay-host .replay-after{display:flex!important;flex-wrap:wrap;gap:3px 9px;margin-top:7px!important;font-size:10px;line-height:1.35;color:#827353}
.replay-host .replay-after b{font-size:11px;color:#405638}
.replay-host .replay-result-note{font-size:9px;color:#917657;line-height:1.25;margin:8px 0 0}
@media(max-width:760px){
 .battle-board #battle-reveal.replay-host{width:calc(100% - 16px);height:calc(100% - 14px);max-height:260px}
 .replay-host .battle-replay{padding:7px 10px;border-radius:8px}
 .replay-host .replay-heading{gap:7px;min-height:17px}
 .replay-host .replay-heading>span{font-size:7px;padding:2px 5px}
 .replay-host .replay-heading>b{font-size:11px}
 .replay-host .replay-progress{height:2px;min-height:2px;margin:5px 0 6px}
 .replay-host .replay-teams{gap:10px}
 .replay-host .replay-team{padding-left:7px;border-left-width:2px}
 .replay-host .replay-team>.replay-team-heading{gap:2px;margin-bottom:5px}
 .replay-host .replay-team-heading>small{font-size:6px;letter-spacing:.6px}
 .replay-host .replay-team-heading>b{font-size:12px}
 .replay-host .replay-portrait{width:39px;height:39px;margin-bottom:4px}
 .replay-host .replay-portrait.placeholder{font-size:23px;line-height:35px}
 .replay-host .replay-troops{font-size:22px}
 .replay-host .replay-troops small{font-size:7px}
 .replay-host .replay-boost{font-size:7px;margin-top:3px}
 .replay-host .replay-commitment{margin-top:4px!important;padding-top:3px}
 .replay-host .replay-commitment>div{font-size:8px;line-height:1.4}
 .replay-host .replay-stage-label{font-size:7px;margin-bottom:4px!important}
 .replay-host .replay-stage-note{font-size:9px;margin-top:9px}
 .replay-host .replay-adjustment{font-size:8px;gap:5px;padding:2px 0;line-height:1.2}
 .replay-host .replay-adjustment>b,.replay-host .replay-adjustment>dd{font-size:10px}
 .replay-host .replay-effect{padding:3px 4px;margin-left:-4px;margin-right:-4px}
 .replay-host .replay-effect>span>small{font-size:7px}
 .replay-host .replay-total{margin-top:4px;padding-top:4px}
 .replay-host .replay-total>dt{font-size:8px}
 .replay-host .replay-total>dd{font-size:20px}
 .replay-host .replay-total.attack{margin-top:5px}
 .replay-host .replay-total.attack>dt{font-size:8px}
 .replay-host .replay-total.attack>dd{font-size:24px}
 .replay-host .replay-control{font-size:6px;padding:1px 3px}
 .replay-host .replay-control-source{font-size:6px}
 .replay-host .replay-equation{gap:8px;padding-top:7px}
 .replay-host .replay-equation>b{font-size:23px}
 .replay-host .replay-equation>i{font-size:18px}
 .replay-host .replay-equation-label{font-size:7px;line-height:1.3;margin:6px 0 12px!important}
 .replay-host .replay-product{font-size:25px}
 .replay-host .replay-boost-note{font-size:7px;line-height:1.3;margin-top:7px}
 .replay-host .replay-comparison{font-size:8px;line-height:1.35;margin-top:7px;padding-top:4px}
 .battle-board #battle-reveal.replay-host:is([data-phase="charge"],[data-phase="impact"]){width:calc(100% - 20px);height:auto}
 .replay-host:is([data-phase="charge"],[data-phase="impact"],[data-phase="assault"]) .battle-replay{padding:6px 9px}
 .replay-host:is([data-phase="charge"],[data-phase="impact"],[data-phase="assault"]) .replay-heading>b{font-size:10px}
 .replay-host .replay-motion-numbers{font-size:7px;gap:9px}
 .replay-host .replay-motion-numbers b{font-size:10px}
 .battle-board #battle-reveal.replay-host[data-phase="assault"]{width:calc(100% - 20px);max-height:calc(100% - 84px);height:auto}
 .replay-host .replay-assault-target{font-size:9px}
 .replay-host .replay-damage-formula{font-size:7px;gap:2px 5px}
 .replay-host .replay-assault-loss{font-size:8px;margin-top:3px!important}
 .replay-host .replay-assault-loss>b{font-size:19px}
 .replay-host .replay-assault-health{font-size:12px}
 .replay-host .replay-assault-health>small,.replay-host .replay-assault .replay-team>small{font-size:7px}
 .replay-host .replay-verdict{font-size:11px;margin-bottom:6px}
 .replay-host .replay-damage-build{font-size:7px;gap:2px 5px;margin-bottom:3px!important}
 .replay-host .replay-total.damage>dd{font-size:23px}
 .replay-host .replay-camp-summary{padding-top:4px;margin-top:4px!important}
 .replay-host .replay-camp-summary>span:first-child{font-size:7px}
 .replay-host .replay-camp-equation{gap:4px;font-size:12px}
 .replay-host .replay-camp-equation>i{font-size:9px}
 .replay-host .replay-camp-bar{height:3px;margin-top:2px}
 .replay-host .replay-after{font-size:7px;gap:2px 5px;margin-top:4px!important}
 .replay-host .replay-after b{font-size:8px}
 .replay-host .replay-result-note{font-size:7px;line-height:1.2;margin-top:5px}
}
@media(prefers-reduced-motion:reduce){.replay-host *{animation:none!important;transition:none!important}}

/* Replay teams follow the battlefield: opponent above, player below. */
.battle-board #battle-reveal.replay-host{
 width:min(790px,calc(100% - 20px));height:min(330px,calc(100% - 14px));
}
/* Revealed choices need space for the complete name and all five reserve values. */
.battle-board #battle-reveal.replay-host:is([data-phase="reveal"],[data-phase="calculation"],[data-phase="result"]){
 height:min(330px,max(224px,calc(100% - 14px)));max-height:calc(100dvh - 100px);
}
.battle-board #battle-reveal.replay-host[data-phase="result"]{height:min(330px,max(280px,calc(100% - 14px)))}
.battle-board>.arena.battlefield:has(#battle-reveal:not([hidden]):is([data-phase="reveal"],[data-phase="calculation"],[data-phase="result"])){overflow:visible}
.replay-host .battle-replay{padding:8px 12px}
.replay-host .replay-heading{min-height:20px}
.replay-host .replay-heading>b{font-size:13px}
.replay-host .replay-progress{margin:5px 0 7px}
.replay-host[data-phase="reveal"] .replay-reveal,
.replay-host[data-phase="calculation"] .replay-calculation,
.replay-host[data-phase="result"] .replay-result{
 display:flex;flex-direction:column;flex:1;min-height:0;overflow:hidden;
}
.replay-host .replay-teams{
 grid-template-columns:minmax(0,1fr);grid-template-rows:repeat(2,minmax(0,1fr));
 gap:7px;flex:1;min-height:0;height:100%;
}
.replay-host :is(.replay-reveal,.replay-calculation,.replay-result) .replay-team{
 display:grid;grid-template-columns:112px minmax(0,1fr);gap:12px;
 align-items:center;height:100%;min-height:0;padding:5px 8px;
 border-left:3px solid #a26c47;border-bottom:1px solid #b79f6955;
 background:#fff8e740;border-radius:5px;overflow:hidden;
}
.replay-host :is(.replay-reveal,.replay-calculation,.replay-result) .replay-team.own{
 border-left-color:#5b8050;border-bottom-color:#73915c55;background:#e4ead135;
}
.replay-host .replay-team>.replay-team-heading{
 align-self:center;margin:0;gap:3px;min-width:0;
}
.replay-host .replay-team-heading>b{white-space:normal;overflow-wrap:anywhere;line-height:1.2;font-size:14px}
.replay-host .replay-team-heading>small{font-size:8px;letter-spacing:.5px}
.replay-host .replay-team-work,.replay-host .replay-reveal-work,.replay-host .replay-result-work{
 min-width:0;min-height:0;height:100%;overflow:auto;overscroll-behavior:contain;scrollbar-width:thin;
}
.replay-host .replay-team-work{overflow:hidden}
.replay-host .replay-stage-label{display:none}
.replay-host[data-detail="base"] .replay-base-step{
 display:grid;grid-template-columns:94px minmax(0,1fr);grid-template-rows:minmax(0,1fr) auto;
 align-items:center;gap:2px 12px;height:100%;min-height:0;
}
.replay-host .replay-base-step>.replay-total{grid-column:1;grid-row:1;display:flex;flex-direction:column;align-items:flex-start;border:0;padding:0;margin:0;gap:2px}
.replay-host .replay-base-step>.replay-stage-note{grid-column:2;grid-row:1;font-size:11px;line-height:1.3;margin:0}
.replay-host .replay-base-step>.replay-controls{grid-column:1/-1;grid-row:2}
.replay-host[data-detail="effects"] .replay-power-step,
.replay-host[data-detail="attack-effects"] .replay-attack-step{
 display:grid;grid-template-columns:64px minmax(0,1fr) 128px;
 grid-template-rows:minmax(0,1fr) auto;gap:0 10px;align-items:center;height:100%;min-height:0;
}
.replay-host[data-detail="attack-effects"] .replay-attack-step{grid-template-columns:90px minmax(0,1fr) 128px}
.replay-host :is(.replay-power-step,.replay-attack-step)>.replay-adjustment{
 grid-column:1;grid-row:1;display:flex;flex-direction:column;align-items:flex-start;gap:3px;min-width:0;
}
.replay-host :is(.replay-power-step,.replay-attack-step)>.replay-adjustment>b{font-size:17px;max-width:100%;overflow-wrap:anywhere;white-space:normal}
.replay-host .replay-attack-step>.replay-adjustment>b{font-size:15px;white-space:nowrap;overflow-wrap:normal}
.replay-host .replay-effect-list{
 grid-column:2;grid-row:1;position:relative;min-height:0;max-height:100%;height:100%;
 overflow:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#a18a55 transparent;padding:0 5px;
}
.replay-host .replay-no-effects{display:block;font-size:10px;line-height:1.3;color:#95856a;padding:5px 3px}
.replay-host .replay-effect{margin:0 0 3px;padding:3px 6px;min-height:31px}
.replay-host .replay-effect>span{font-size:11px}
.replay-host .replay-effect>span>small{font-size:9px}
.replay-host .replay-effect>b{font-size:16px}
.replay-host :is(.replay-power-step,.replay-attack-step)>.replay-total{
 grid-column:3;grid-row:1;display:flex;flex-direction:column;align-items:flex-end;
 border:0;border-left:1px solid #b79f6959;padding:3px 0 3px 8px;margin:0;gap:4px;min-width:0;
}
.replay-host :is(.replay-power-step,.replay-attack-step)>.replay-total>dt{
 text-align:right;font-size:9px;line-height:1.2;margin:0;white-space:normal;
}
.replay-host .replay-power-step>.replay-total>dd{font-size:27px}
.replay-host .replay-attack-step>.replay-total>dd{font-size:24px}
.replay-host .replay-power-step>.replay-controls{grid-column:1/-1;grid-row:2;margin-top:2px!important}
.replay-host .replay-controls{overflow:auto;max-height:19px;gap:2px;flex-wrap:nowrap;align-items:center}
.replay-host .replay-control{white-space:nowrap;font-size:7px;padding:1px 3px}
.replay-host .replay-control-source{font-size:7px;flex-basis:auto;white-space:nowrap}
.replay-host[data-detail="multiply"] .replay-multiply-step{
 display:grid;grid-template-columns:max-content minmax(0,1fr);grid-template-rows:minmax(0,1fr) auto;
 gap:0 7px;align-items:center;height:100%;min-height:0;
}
.replay-host .replay-multiply-step>.replay-equation{grid-column:1;grid-row:1;padding:0;gap:8px;white-space:nowrap}
.replay-host .replay-multiply-step>.replay-equation>b{font-size:25px}
.replay-host .replay-multiply-step>.replay-equation>i{font-size:21px}
.replay-host .replay-multiply-step>.replay-product{grid-column:2;grid-row:1;justify-self:end;font-size:29px}
.replay-host .replay-multiply-step>.replay-equation-label{grid-column:1/-1;grid-row:2;font-size:9px;line-height:1.15;margin:0!important}
.replay-host .replay-multiply-step>.replay-boost-note{grid-column:1/-1;grid-row:3;font-size:8px;line-height:1.1;margin:2px 0 0}
.replay-host[data-detail="final"] .replay-final-step{
 display:grid;grid-template-columns:repeat(3,minmax(0,1fr)) minmax(104px,1.2fr);
 gap:6px;align-items:center;height:100%;min-height:0;
}
.replay-host .replay-final-step>.replay-adjustment{display:flex;flex-direction:column;align-items:flex-start;gap:3px}
.replay-host .replay-final-step>.replay-adjustment>span{font-size:9px}
.replay-host .replay-final-step>.replay-adjustment>b{font-size:15px}
.replay-host .replay-final-step>.replay-total.attack{
 border:0;border-left:1px solid #b79f6959;padding:0 0 0 9px;margin:0;min-width:0;
}
.replay-host .replay-final-step>.replay-total.attack>dd{font-size:25px}
.replay-host .replay-final-step>.replay-total.attack>dt{font-size:9px}
.replay-host .replay-comparison{
 flex-shrink:0;font-size:9px;line-height:1.2;padding-top:4px;margin:4px 0 0;
}
.replay-host .replay-reveal .replay-team{grid-template-columns:140px minmax(0,1fr)}
.replay-host .replay-reveal-identity{min-width:0;display:flex;flex-direction:row;align-items:center;gap:8px}
.replay-host .replay-reveal-identity>.replay-portrait{width:38px;height:38px;flex:none;margin:0}
.replay-host .replay-reveal-identity>.replay-team-heading{min-width:0;margin:0}
.replay-host .replay-reveal-work{display:grid;grid-template-columns:minmax(0,1fr) max-content;grid-auto-rows:max-content;align-content:safe center;gap:3px 8px}
.replay-host .replay-reveal-work>.replay-troops{grid-column:1;grid-row:1;font-size:25px;white-space:nowrap}
.replay-host .replay-reveal-work>.replay-boost{grid-column:2;grid-row:1;align-self:center;font-size:9px;margin:0}
.replay-host .replay-commitment{
 grid-column:1/-1;grid-row:2;display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:5px;
 margin-top:2px!important;padding-top:3px;border-color:#b7a27240;
}
.replay-host .replay-commitment>div{min-width:0;flex-direction:column;justify-content:flex-start;gap:2px;font-size:9px;line-height:1.25;overflow-wrap:anywhere}
.replay-host .replay-commitment b{font-size:12px}
.replay-host .replay-result-work{display:grid;grid-template-columns:minmax(0,1fr) minmax(118px,1fr);align-content:start;gap:3px 10px}
.replay-host .replay-result-damage{grid-column:1;grid-row:1;display:grid;grid-template-columns:1fr 1fr;gap:7px;align-items:center}
.replay-host .replay-result-damage>.replay-adjustment,.replay-host .replay-result-damage>.replay-total.damage{
 display:flex;flex-direction:column;align-items:flex-start;border:0;padding:0;margin:0;gap:3px;
}
.replay-host .replay-result-damage dt{font-size:9px;white-space:normal}
.replay-host .replay-result-damage .replay-adjustment>dd{font-size:19px}
.replay-host .replay-result-damage .replay-total.damage>dd{font-size:25px}
.replay-host .replay-result-work>.replay-camp-summary{grid-column:2;grid-row:1;align-self:center;padding:0;margin:0!important;border:0}
.replay-host .replay-result-work>.replay-camp-summary>.replay-camp-equation{white-space:nowrap;font-size:16px;gap:5px}
.replay-host .replay-result-work>.replay-damage-build{grid-column:1/-1;grid-row:2;margin:0!important;font-size:8px;gap:2px 7px}
.replay-host .replay-result-work>.replay-after{grid-column:1/-1;grid-row:3;margin:0!important;font-size:8px;gap:2px 8px}
.replay-host .replay-result-work>.replay-after b{font-size:9px}
.replay-host .replay-verdict{flex-shrink:0;font-size:11px;line-height:1.1;margin:0 0 4px}
.replay-host .replay-result-note{flex-shrink:0;font-size:8px;line-height:1.15;margin:3px 0 0}
.replay-host .replay-motion-numbers{grid-template-columns:1fr;gap:3px}
@media(max-width:760px){
 .battle-board #battle-reveal.replay-host{width:calc(100% - 14px);height:calc(100% - 12px);max-height:260px}
 .battle-board #battle-reveal.replay-host:is([data-phase="reveal"],[data-phase="calculation"],[data-phase="result"]){height:min(300px,max(260px,calc(100% - 12px)));max-height:calc(100dvh - 100px)}
 .replay-host .battle-replay{padding:6px 8px}
 .replay-host .replay-heading{min-height:16px}
 .replay-host .replay-heading>b{font-size:10px}
 .replay-host .replay-heading>span{font-size:7px;padding:2px 4px}
 .replay-host .replay-progress{margin:4px 0 5px}
 .replay-host .replay-teams{gap:5px}
 .replay-host :is(.replay-reveal,.replay-calculation,.replay-result) .replay-team{
  grid-template-columns:69px minmax(0,1fr);gap:7px;padding:3px 4px;border-left-width:2px;
 }
 .replay-host .replay-reveal .replay-team{grid-template-columns:69px minmax(0,1fr)}
 .replay-host .replay-team-heading>b{font-size:11px;line-height:1.25}
 .replay-host .replay-team-heading>small{font-size:6px;letter-spacing:.3px}
 .replay-host .replay-team>.replay-team-heading{gap:3px}
 .replay-host[data-detail="base"] .replay-base-step{grid-template-columns:54px minmax(0,1fr);gap:2px 8px}
 .replay-host .replay-base-step>.replay-stage-note{font-size:8px;line-height:1.25}
 .replay-host .replay-base-step>.replay-total>dt{font-size:8px}
 .replay-host .replay-base-step>.replay-total>dd{font-size:22px}
 .replay-host[data-detail="effects"] .replay-power-step,
 .replay-host[data-detail="attack-effects"] .replay-attack-step{grid-template-columns:42px minmax(0,1fr) 83px;gap:0 5px}
 .replay-host[data-detail="attack-effects"] .replay-attack-step{grid-template-columns:64px minmax(0,1fr) 86px}
 .replay-host .replay-attack-step>.replay-adjustment>b{font-size:12px;white-space:nowrap;overflow-wrap:normal}
 .replay-host :is(.replay-power-step,.replay-attack-step)>.replay-adjustment{gap:2px}
 .replay-host :is(.replay-power-step,.replay-attack-step)>.replay-adjustment>span{font-size:7px}
 .replay-host :is(.replay-power-step,.replay-attack-step)>.replay-adjustment>b{font-size:13px}
 .replay-host .replay-effect-list{padding:0 2px}
 .replay-host .replay-no-effects{font-size:8px;line-height:1.25;padding:3px 2px}
 .replay-host .replay-effect{padding:3px 4px;min-height:31px;margin-bottom:2px;gap:4px}
 .replay-host .replay-effect>span{font-size:9px;line-height:1.15}
 .replay-host .replay-effect>span>small{font-size:7px;line-height:1.1}
 .replay-host .replay-effect>b{font-size:13px}
 .replay-host :is(.replay-power-step,.replay-attack-step)>.replay-total{padding-left:5px;gap:3px}
 .replay-host :is(.replay-power-step,.replay-attack-step)>.replay-total>dt{font-size:7px;line-height:1.15}
 .replay-host .replay-power-step>.replay-total>dd{font-size:23px}
 .replay-host .replay-attack-step>.replay-total>dd{font-size:17px}
 .replay-host .replay-controls{max-height:15px}
 .replay-host .replay-control,.replay-host .replay-control-source{font-size:6px}
 .replay-host .replay-multiply-step>.replay-equation{gap:4px}
 .replay-host .replay-multiply-step>.replay-equation>b{font-size:17px}
 .replay-host .replay-multiply-step>.replay-equation>i{font-size:15px}
 .replay-host .replay-multiply-step>.replay-product{font-size:19px}
 .replay-host .replay-multiply-step>.replay-equation-label{font-size:7px}
 .replay-host .replay-multiply-step>.replay-boost-note{font-size:6.5px}
 .replay-host[data-detail="final"] .replay-final-step{grid-template-columns:repeat(3,minmax(0,1fr)) minmax(90px,1.2fr);gap:3px}
 .replay-host .replay-final-step>.replay-adjustment{gap:2px}
 .replay-host .replay-final-step>.replay-adjustment>span{font-size:6.5px;line-height:1.15}
 .replay-host .replay-final-step>.replay-adjustment>b{font-size:10px}
 .replay-host .replay-final-step>.replay-total.attack{padding-left:5px}
 .replay-host .replay-final-step>.replay-total.attack>dt{font-size:7px}
 .replay-host .replay-final-step>.replay-total.attack>dd{font-size:18px}
 .replay-host .replay-comparison{font-size:7px;margin-top:3px;padding-top:3px}
 .replay-host .replay-reveal-identity{flex-direction:column;align-items:flex-start;gap:4px}
 .replay-host .replay-reveal-identity>.replay-portrait{width:31px;height:31px}
 .replay-host .replay-reveal-work{grid-template-columns:minmax(0,1fr);gap:2px}
 .replay-host .replay-reveal-work>.replay-troops{font-size:21px}
 .replay-host .replay-reveal-work>.replay-troops>small{font-size:7px}
 .replay-host .replay-reveal-work>.replay-boost{grid-column:1;grid-row:2;font-size:8px;line-height:1.25}
 .replay-host .replay-commitment{grid-row:3;grid-template-columns:repeat(3,minmax(0,1fr));gap:3px 6px;padding-top:2px;margin-top:1px!important}
 .replay-host .replay-commitment>div{font-size:8px;line-height:1.25;gap:2px}
 .replay-host .replay-commitment b{font-size:11px}
 .replay-host .replay-result-work{grid-template-columns:minmax(0,1fr) minmax(103px,1fr);gap:3px 6px}
 .replay-host .replay-result-damage{gap:5px}
 .replay-host .replay-result-damage dt{font-size:6.5px;line-height:1.1}
 .replay-host .replay-result-damage .replay-adjustment>dd{font-size:15px}
 .replay-host .replay-result-damage .replay-total.damage>dd{font-size:21px}
 .replay-host .replay-result-work>.replay-camp-summary>span:first-child{font-size:7px}
 .replay-host .replay-result-work>.replay-camp-summary>.replay-camp-equation{font-size:12px;gap:3px}
 .replay-host .replay-result-work>.replay-damage-build{font-size:6.5px;gap:2px 5px}
 .replay-host .replay-result-work>.replay-after{font-size:6.5px}
 .replay-host .replay-result-work>.replay-after b{font-size:7px}
 .replay-host .replay-verdict{font-size:9px;margin-bottom:3px}
 .replay-host .replay-result-note{font-size:6.5px;line-height:1.15}
}

/* Free troops join the army; only the extra troops and boost spend the reserve. */
.replay-host .replay-deployment{
 display:flex;flex-wrap:wrap;align-items:baseline;gap:3px 6px;
 color:#776446;font-size:10px;line-height:1.3;white-space:normal;
}
.replay-host .replay-troops>.replay-deployment{margin-top:4px;font-size:9px}
.replay-host .replay-deployment>span{white-space:nowrap}
.replay-host .replay-deployment b{font-size:inherit;color:#355339;font-variant-numeric:tabular-nums}
.replay-host .replay-deployment>i{font-size:inherit;font-style:normal;color:#957f57}
.replay-host .replay-commitment.has-base-troops{grid-template-columns:repeat(6,minmax(0,1fr))}
.replay-host .replay-multiply-step:has(>.replay-deployment)>.replay-deployment{grid-column:1/-1;grid-row:2}
.replay-host .replay-multiply-step:has(>.replay-deployment)>.replay-equation-label{grid-row:3}
.replay-host .replay-multiply-step:has(>.replay-deployment)>.replay-boost-note{grid-row:4}
@media(max-width:760px){
 .replay-host .replay-deployment{font-size:8px;gap:2px 4px}
 .replay-host .replay-troops>.replay-deployment{font-size:8px;margin-top:3px}
 .replay-host .replay-commitment.has-base-troops{grid-template-columns:repeat(3,minmax(0,1fr))}
}

