:root{color-scheme:light;--ink:#24363c;--paper:#f5f0e4;--cream:#e9dfca;--line:#c6bda9;--red:#893d31;--blue:#345a6c}*{box-sizing:border-box}body{margin:0;color:var(--ink);background:#e9e3d6;font:16px/1.5 Georgia,'Times New Roman',serif}header,main{max-width:1400px;margin:auto;padding:24px 32px}header{padding-bottom:0}.masthead{display:flex;align-items:center;justify-content:space-between;border-bottom:2px solid var(--ink);padding-bottom:20px}.eyebrow{font:11px/1.4 system-ui,sans-serif;letter-spacing:2px;font-weight:700}h1{font-size:52px;line-height:1;margin:10px 0}header p{margin:8px 0 0;color:#66716e}.edition{border:1px solid var(--line);padding:14px 20px;text-align:center;font-size:20px;letter-spacing:4px}.edition span,.edition small{display:block}.edition small{font:9px system-ui;letter-spacing:1px;margin-top:8px}nav{display:flex;gap:12px;align-items:center;flex-wrap:wrap;padding:16px 0}nav label{font:12px system-ui;display:flex;align-items:center;gap:8px}button,select,input{font:13px system-ui;border:1px solid #b6b3a5;background:var(--paper);color:var(--ink);border-radius:3px;padding:10px 12px}button{cursor:pointer}button:hover{background:white;border-color:#687b7e}button:focus-visible,summary:focus-visible{outline:3px solid #bf8d32;outline-offset:3px}button:disabled{opacity:.45;cursor:default}input[type=number]{width:68px}input[type=checkbox]{accent-color:var(--blue)}main{padding-top:0}.flightline{border-top:1px solid var(--line);display:flex;justify-content:space-between;gap:15px;padding:15px 0;font:12px system-ui}#turn{font-weight:700;letter-spacing:1px}#flightState{color:#5c6869}.cockpits{display:grid;grid-template-columns:1fr 1fr;gap:24px}.cockpits.single{max-width:850px;margin:auto;grid-template-columns:1fr}.pilot{background:var(--paper);border:1px solid var(--line);box-shadow:0 4px 16px #24363c0a}.pilot header{padding:14px 18px;display:flex;justify-content:space-between;align-items:center;border-bottom:1px solid var(--line)}.pilot h2{margin:0;font-size:22px}.pilot .side{font:10px system-ui;letter-spacing:1px;color:#6d7065}.page-badge{border:1px solid var(--line);padding:5px 10px;font:12px system-ui}.cockpit-image{overflow:hidden;background:white;position:relative}.cockpit-image img{display:block;width:100%;height:auto}.cockpit-image.contrast img{filter:contrast(1.6)}.view-tools{display:flex;align-items:center;justify-content:space-between;padding:8px 16px;border-top:1px solid var(--line);gap:8px}.view-tools button{padding:5px 8px;font-size:11px}.view-tools label{font:11px system-ui;display:flex;gap:5px;align-items:center}.maneuvers{padding:0 15px 16px}.move-group{margin-top:14px}.move-group h3{font:10px system-ui;letter-spacing:2px;text-transform:uppercase;margin:0 0 7px;display:flex;align-items:center;gap:10px}.move-group h3:after{content:'';height:1px;flex:1;background:var(--line)}.move-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:6px}.move{padding:5px 2px 7px;display:flex;align-items:center;flex-direction:column;gap:3px;background:#fffdf7;min-height:102px}.move img{width:42px;height:42px;object-fit:contain;mix-blend-mode:multiply}.move .name{font:10px/1.2 system-ui;text-align:center;min-height:24px;display:flex;align-items:center;justify-content:center}.move .index{font:9px system-ui;color:#7c817b}.move.locked{background:#d7e2dc;border-color:#345a6c}.locked-label{padding:22px;color:#61726f;text-align:center}.damage{border-top:1px solid var(--line);padding:12px 15px;font:11px system-ui;display:flex;flex-wrap:wrap;gap:5px;align-items:center}.damage strong{margin-right:auto}.damage button{font-size:10px;padding:5px 7px}.report{background:#dbe3dc;border-left:3px solid var(--blue);padding:14px 20px;margin-top:24px}.report h2{font:11px system-ui;text-transform:uppercase;letter-spacing:1px;margin:0 0 8px}.report p{margin:0;font-size:14px}.log,#guide{margin-top:22px;border-top:1px solid var(--line);padding-top:12px}summary{cursor:pointer;font:13px system-ui}.log li{font:13px/1.5 system-ui;margin-bottom:10px}.manual-grid{display:grid;grid-template-columns:1fr 1fr;gap:32px;font-size:14px}.manual-grid h2{font-size:20px}.fine{font:11px/1.5 system-ui;color:#6d756e}.handoff-card{max-width:700px;margin:50px auto;padding:60px 30px;text-align:center;background:var(--paper);border:1px solid var(--line)}.handoff-card h2{font-size:30px}.primary{background:var(--blue);color:white;border-color:var(--blue)}.primary:hover{background:#244552;color:white}.lost{padding:20px}.lost button{margin:8px}.standby{padding:50px 25px;text-align:center;align-self:start;border:1px dashed var(--line)}dialog{max-width:1000px;width:95vw;max-height:95vh;border:1px solid var(--line);background:var(--paper);padding:16px}dialog::backdrop{background:#12262acc}dialog img{display:block;width:100%;height:auto}.close{float:right}dialog h2{font-size:20px;margin:5px 0 14px}[hidden]{display:none!important}@media(max-width:850px){header,main{padding-left:15px;padding-right:15px}.cockpits{grid-template-columns:1fr}.edition{display:none}h1{font-size:42px}.flightline{flex-direction:column;gap:6px}.manual-grid{grid-template-columns:1fr;gap:8px}}@media(min-width:1200px){.cockpits.single .move-grid{grid-template-columns:repeat(8,minmax(0,1fr))}}@media(prefers-reduced-motion:no-preference){.pilot{animation:appear .2s ease-out}@keyframes appear{from{opacity:.5}to{opacity:1}}}
/* Viewport-sized flight desk: the play surface never grows with the log. */
html,body{height:100%;height:100dvh;overflow:hidden}body{display:flex;flex-direction:column}body>header{width:100%;max-width:1800px;margin:0 auto;padding:10px 18px 4px;display:flex;gap:22px;align-items:center;flex-shrink:0}.masthead{border:0;padding:0;flex-shrink:0}.masthead h1{font-size:27px;margin:0;white-space:nowrap}.masthead p,.masthead .eyebrow,.edition{display:none}nav{padding:0;gap:8px;flex:1}nav label{font-size:11px}nav button,nav select,nav input{padding:7px 8px;font-size:11px}main{max-width:1800px;width:100%;margin:0 auto;padding:0 18px 12px;flex:1;min-height:0;display:flex;flex-direction:column}.flightline{flex-shrink:0;padding:8px 0;font-size:11px;align-items:center;min-height:32px;flex-direction:row}#flightState{text-align:right}.cockpits,.cockpits.single{flex:1;min-height:0;max-width:none;width:100%;margin:0;gap:14px;grid-template-columns:repeat(2,minmax(0,1fr));align-items:stretch}.cockpits.single{grid-template-columns:minmax(0,1fr)}.pilot{min-height:0;min-width:0;overflow:hidden;display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:auto minmax(0,1fr) auto minmax(0,1.3fr) auto}.pilot header{grid-area:1/1;padding:7px 12px;width:100%;max-width:none;margin:0;min-height:43px}.pilot h2{font-size:18px}.pilot .side{font-size:8px}.page-badge{font-size:10px;padding:3px 7px}.cockpit-image{grid-area:2/1;min-height:0;min-width:0;display:flex;align-items:center;justify-content:center;background:#fff;overflow:hidden}.paper-crop{overflow:hidden;flex:none;max-width:100%;position:relative}.paper-crop img{width:100%;height:auto;display:block}.view-tools{grid-area:3/1;padding:4px 10px;min-height:29px}.view-tools button,.view-tools label{font-size:10px}.view-tools button{padding:3px 6px}.maneuvers{grid-area:4/1;padding:5px 9px 7px;min-height:0;display:flex;flex-direction:column;gap:5px}.move-group{margin:0;min-height:0;flex:1;display:grid;grid-template-rows:auto minmax(0,1fr)}.move-group h3{font-size:9px;letter-spacing:1px;line-height:12px;margin:0 0 3px}.move-grid,.cockpits.single .move-grid{grid-template-columns:repeat(5,minmax(0,1fr));grid-template-rows:repeat(2,minmax(0,1fr));gap:4px;min-height:0}.move{min-height:0;min-width:0;padding:2px 2px 3px;gap:1px;justify-content:center;overflow:hidden}.move img{width:clamp(17px,3.6dvh,32px);height:clamp(17px,3.6dvh,32px);flex-shrink:1;min-height:0}.move .name{font-size:9px;line-height:1.1;min-height:0;flex-shrink:0}.move .index{display:none}.damage{grid-area:5/1;padding:5px 9px;gap:4px;min-height:31px;font-size:10px}.damage button{font-size:9px;padding:3px 5px}.maneuvers>.fine{display:none}.cockpits.single .pilot{grid-template-columns:minmax(0,1.2fr) minmax(280px,1fr);grid-template-rows:auto minmax(0,1fr) auto auto}.cockpits.single .pilot header{grid-area:1/1/2/3}.cockpits.single .cockpit-image{grid-area:2/1}.cockpits.single .view-tools{grid-area:3/1}.cockpits.single .maneuvers{grid-area:2/2/4/3;border-left:1px solid var(--line);padding:10px;gap:10px}.cockpits.single .damage{grid-area:4/1/5/3}.cockpits.single .move img{width:clamp(20px,5dvh,42px);height:clamp(20px,5dvh,42px)}.cockpits.single .move .name{font-size:10px}.cockpits.single .move{padding:3px}.cockpits.single .move-group h3{font-size:10px;line-height:15px;margin-bottom:5px}.lost,.locked-label{grid-area:4/1;min-height:0;align-self:center}.cockpits.single .lost,.cockpits.single .locked-label{grid-area:2/2/4/3}.lost{padding:12px;font-size:13px}#handoff{flex:1;min-height:0;display:grid;place-items:center}.handoff-card{margin:0;padding:25px;max-width:700px}.handoff-card h2{font-size:26px;margin:10px 0}.report{margin:16px 0}.log,#guide{margin:14px 0}.manual-grid{display:block}dialog{max-height:94dvh;overflow:auto}#infoDialog{max-width:900px;padding:20px}#infoContents{clear:both;padding-top:10px}#infoContents summary{font-size:16px}#infoContents .manual-grid{display:grid;grid-template-columns:1fr 1fr;gap:22px}#infoContents .report{display:block}#scanDialog img{width:100%;height:auto}
@media(max-width:1000px){body>header{gap:12px;padding:8px 12px 4px}.masthead h1{font-size:22px}main{padding:0 12px 8px}nav{gap:5px}nav label{gap:4px}nav button,nav select,nav input{font-size:10px;padding:6px}nav input[type=number]{width:52px}#mode{max-width:180px}.cockpits{gap:9px}}
@media(max-width:680px){body>header{align-items:flex-start}.masthead h1{font-size:18px;padding-top:5px}nav{gap:4px}.browse{order:2}.flightline{font-size:10px;gap:6px}#flightState{max-width:65%}.cockpits.single .pilot{grid-template-columns:minmax(0,1fr);grid-template-rows:auto minmax(0,1fr) auto minmax(0,1.3fr) auto}.cockpits.single .pilot header{grid-area:1/1}.cockpits.single .cockpit-image{grid-area:2/1}.cockpits.single .view-tools{grid-area:3/1}.cockpits.single .maneuvers{grid-area:4/1;border-left:0;gap:4px;padding:4px 8px}.cockpits.single .damage{grid-area:5/1}.cockpits.single .move img{width:clamp(16px,3.5dvh,29px);height:clamp(16px,3.5dvh,29px)}.cockpits.single .move .name{font-size:9px}.cockpits.single .move-group h3{font-size:9px;line-height:11px;margin-bottom:2px}.cockpits.single .lost,.cockpits.single .locked-label{grid-area:4/1}.cockpits:not(.single) .move .name{display:none}.cockpits:not(.single) .pilot h2{font-size:13px}.cockpits:not(.single) .damage strong{width:100%}.cockpits:not(.single) .view-tools label{font-size:8px}#infoContents .manual-grid{grid-template-columns:1fr}}
@media(max-height:650px){.move img{width:20px;height:20px}.cockpits.single .move img{width:26px;height:26px}.move .name,.cockpits.single .move .name{font-size:9px}.cockpits.single .maneuvers{gap:5px;padding:5px 8px}.pilot header{min-height:35px}.pilot h2{font-size:16px}.damage{padding:3px 8px;min-height:26px}.flightline{padding:4px 0;min-height:26px}.view-tools{min-height:25px}.move-group h3{margin-bottom:1px;line-height:10px}.cockpits.single .move-group h3{line-height:12px;margin-bottom:2px}}
/* Optional computer cockpit; it stays inside the artwork, clear of maneuvers. */
.opponent-panel{position:absolute;right:10px;bottom:10px;z-index:2;background:var(--paper);border:1px solid #6d7977;border-radius:5px;box-shadow:0 4px 18px #102e4066;overflow:hidden;max-width:calc(100% - 20px)}.opponent-heading{display:flex;align-items:center;gap:4px;padding:4px 5px 4px 8px;background:#263f4a;color:#f5f0e4;min-height:29px}.opponent-heading span{font:9px/1.3 system-ui;letter-spacing:.6px;flex:1}.opponent-heading button{font:15px/1 system-ui;padding:2px 5px;min-width:23px;background:#eee7d7;border:0;color:#1b343d}.opponent-crop{width:100%;overflow:hidden;background:white}.opponent-crop img{display:block;width:100%;height:auto}.view-tools:has(#opponentToggle){justify-content:flex-start;flex-wrap:wrap}.view-tools:has(#opponentToggle)>label{margin-left:auto}#opponentToggle[aria-pressed=true]{background:#d6e2dc;border-color:#345a6c}.opponent-panel.enlarged{box-shadow:0 5px 25px #102e4088}@media(max-width:680px){.opponent-heading span{font-size:8px;letter-spacing:0}.opponent-heading{padding-left:5px;gap:2px}}
.damage-board{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;flex-shrink:0;margin:0 0 8px}.damage-card{border:1px solid var(--line);border-left:4px solid var(--blue);background:var(--paper);padding:5px 10px;display:grid;grid-template-columns:minmax(0,1fr) auto;column-gap:10px;align-items:center}.damage-card.german{border-left-color:var(--red)}.damage-title{grid-column:1/3;display:flex;justify-content:space-between;gap:6px;font:10px/1.4 system-ui}.damage-title strong{font-size:9px;letter-spacing:.5px}.damage-card progress{width:100%;height:7px;accent-color:var(--red);margin:3px 0;appearance:none;border:0;border-radius:3px;overflow:hidden;background:#d8d3c5}.damage-card progress::-moz-progress-bar{background:var(--red)}.damage-card progress::-webkit-progress-bar{background:#d8d3c5}.damage-card progress::-webkit-progress-value{background:var(--red)}.damage-detail{font:9px system-ui;color:#63716b;white-space:nowrap}.combat-note{font:10px/1.35 system-ui;padding:6px 10px;min-height:31px}.damage-card:has(progress[value="6"]){background:#ecd7d0}.damage-card:has(progress[value="6"]) .damage-detail{color:#893d31;font-weight:bold}@media(max-width:680px){.damage-board{gap:6px;margin-bottom:5px}.damage-card{padding:4px 6px;grid-template-columns:minmax(0,1fr)}.damage-title{grid-column:1;flex-wrap:wrap;gap:0 6px}.damage-detail{font-size:8px}.damage-title strong{font-size:8px}.damage-title span{font-size:9px}.damage-card progress{margin:2px 0}.combat-note{font-size:9px}}@media(max-height:650px){.damage-card{padding:3px 8px}.damage-board{margin-bottom:5px}.damage-detail{font-size:8px}.combat-note{padding:3px 8px;min-height:24px}}
.move{position:relative}.direction-tag{position:absolute;top:2px;right:4px;font:7px/1 system-ui;font-weight:700;letter-spacing:.3px;color:#53645e;pointer-events:none}.move[data-direction="left"]{border-left:3px solid #56778a}.move[data-direction="straight"]{border-left:3px solid #8a815c}.move[data-direction="right"]{border-left:3px solid #986653}.move img{margin-top:7px}.combat-note{font-weight:500}@media(max-height:650px){.direction-tag{font-size:6px;top:1px;right:2px}.move img,.cockpits.single .move img{margin-top:5px;width:22px;height:22px}}@media(max-width:680px){.direction-tag{font-size:6px;right:2px}.move img{margin-top:6px}}
/* Three direction subsections per speed, following the book's strip order. */
.direction-sections{display:grid;gap:8px;min-height:0}.direction-section{min-width:0;min-height:0;display:grid;grid-template-rows:auto minmax(0,1fr)}.direction-section+.direction-section{border-left:1px solid var(--line);padding-left:7px}.direction-section h4{font:10px/1.2 system-ui;font-weight:600;letter-spacing:.5px;text-align:center;margin:0 0 6px;color:#54645f}.direction-moves{display:grid;gap:4px;min-height:0;min-width:0}.direction-moves .move{border-left-width:1px;padding:5px 2px;gap:5px;justify-content:center}.direction-moves .move img,.cockpits.single .direction-moves .move img{margin-top:0;width:34px;max-width:calc(100% - 2px);height:34px;object-fit:contain}.direction-moves .move .name{font-size:9px;line-height:1.2;overflow-wrap:anywhere;min-width:0;max-width:100%}.direction-tag{display:none}@media(max-width:1100px){.direction-sections{gap:4px}.direction-section+.direction-section{padding-left:3px}.direction-section h4{font-size:9px;letter-spacing:0;margin-bottom:4px}.direction-moves{gap:3px}.direction-moves .move{gap:3px;padding:3px 1px}.direction-moves .move img,.cockpits.single .direction-moves .move img{width:27px;height:27px}.direction-moves .move .name,.cockpits.single .direction-moves .move .name{font-size:8px}}@media(max-height:650px){.direction-section h4{font-size:9px;margin-bottom:3px}.direction-moves .move img,.cockpits.single .direction-moves .move img{width:23px;height:23px}.direction-moves .move{gap:2px}}@media(max-width:680px){.direction-section h4{font-size:8px}.direction-moves .move img,.cockpits.single .direction-moves .move img{width:23px;height:23px}.direction-moves .move .name{font-size:7px}.cockpits:not(.single) .direction-moves .move .name{display:none}}
/* Compact maneuver rows: button height follows the symbol and name. */
.direction-moves{align-items:start;align-content:start}.direction-moves .move{height:74px;min-height:0;padding:4px 2px;gap:3px;justify-content:center}.direction-moves .move img,.cockpits.single .direction-moves .move img{width:30px;height:30px;flex-shrink:0}.direction-moves .move .name{font-size:9px;line-height:1.1}.direction-section{grid-template-rows:auto auto;align-content:start}.move-group{flex:0 0 auto;grid-template-rows:auto auto}.maneuvers,.cockpits.single .maneuvers{justify-content:flex-start;gap:12px}.move-group h3,.cockpits.single .move-group h3{margin-bottom:4px}.direction-section h4{margin-bottom:4px}@media(max-width:1100px){.direction-moves .move{height:76px;padding:3px 1px;gap:2px}.direction-moves .move img,.cockpits.single .direction-moves .move img{width:25px;height:25px}.direction-moves .move .name,.cockpits.single .direction-moves .move .name{font-size:8px}.maneuvers,.cockpits.single .maneuvers{gap:8px}}@media(max-height:700px){.direction-moves .move{height:57px;padding:2px 1px;gap:2px}.direction-moves .move img,.cockpits.single .direction-moves .move img{width:22px;height:22px}.direction-moves .move .name,.cockpits.single .direction-moves .move .name{font-size:8px}.maneuvers,.cockpits.single .maneuvers{gap:5px}.move-group h3,.cockpits.single .move-group h3{line-height:11px;margin-bottom:2px}.direction-section h4{line-height:10px;margin-bottom:2px}}@media(max-width:680px){.direction-moves .move{height:62px}.cockpits:not(.single) .direction-moves .move{height:40px}}

.maneuver-map{flex:1;min-height:0;display:grid;grid-template-columns:minmax(0,1.2fr) minmax(340px,1fr);gap:16px}.map-view{background:var(--paper);border:1px solid var(--line);min-width:0;min-height:0;display:flex;flex-direction:column}.map-view>header{padding:10px 16px;display:flex;align-items:center;justify-content:space-between;flex-shrink:0;width:100%;max-width:none;margin:0;border-bottom:1px solid var(--line)}.map-view h2{margin:0;font-size:22px}.map-view .side{font:9px system-ui;letter-spacing:1px;color:#68776e}.map-canvas{flex:1;min-height:0;min-width:0;display:grid;place-items:center;background:#e9ede3}.map-svg{width:100%;height:100%;max-height:100%;display:block}.map-axis{font:9px system-ui;letter-spacing:1px;fill:#68776e}.map-legend{display:flex;gap:22px;justify-content:center;flex-shrink:0;font:11px system-ui;padding:8px 12px;border-top:1px solid var(--line)}.map-legend span{display:flex;align-items:center;gap:6px}.start-key{font-size:24px;color:#747c72}.end-key{font-size:22px;color:#285f72;transform:rotate(-90deg)}.map-footnote{margin:0;padding:0 16px 10px;font:10px/1.4 system-ui;color:#69756e;flex-shrink:0}.map-controls{min-width:0;min-height:0;display:flex;flex-direction:column;background:var(--paper);border:1px solid var(--line);padding:12px}.map-result{flex-shrink:0;min-height:80px;padding:0 3px 10px;border-bottom:1px solid var(--line);margin-bottom:12px}.map-result h2{font-size:21px;margin:0 0 5px}.map-result p{font:12px/1.4 system-ui;margin:4px 0}.map-explanation{color:#285f72}.map-controls .maneuvers{padding:0;border:0;flex:1;min-height:0;gap:12px;justify-content:flex-start;grid-area:auto}.map-selected{background:#d2e5df!important;border:2px solid #285f72!important;box-shadow:0 0 0 1px #285f72}.map-controls .direction-moves .move{height:70px}@media(max-width:1000px){.maneuver-map{grid-template-columns:minmax(0,1fr) minmax(320px,1fr);gap:10px}.map-controls{padding:8px}.map-result p{font-size:10px}.map-result h2{font-size:18px}.map-controls .direction-moves .move{height:64px}.map-controls .maneuvers{gap:9px}.map-legend{font-size:9px;gap:8px}}@media(max-height:700px){.map-controls .direction-moves .move{height:48px}.map-controls .maneuvers{gap:5px}.map-result{min-height:0;margin-bottom:7px;padding-bottom:5px}.map-result h2{font-size:17px}.map-result p{font-size:10px}.map-view>header{padding:6px 12px}.map-view h2{font-size:18px}.map-footnote{font-size:9px}.map-legend{padding:4px 8px}}@media(max-width:680px){.maneuver-map{grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,1fr) minmax(0,1fr);gap:6px}.map-view>header{padding:4px 8px}.map-view h2{font-size:15px}.map-view .side,.map-footnote{display:none}.map-legend{padding:2px 6px;font-size:8px}.map-controls{padding:6px}.map-result{min-height:0;padding-bottom:3px;margin-bottom:4px}.map-result h2{font-size:14px}.map-result p{font-size:9px;margin:1px 0}.map-controls .direction-moves .move{height:40px}.map-controls .direction-moves .name{display:none}.map-controls .direction-section h4{font-size:8px}.map-controls .maneuvers{gap:3px}.map-explanation{display:none}}
.enemy-movement{font:700 clamp(12px,1.15vw,20px)/1.25 system-ui;color:#254f58;background:#d7e7d8;border:1px solid #8aa998;border-left:4px solid #356e65;padding:7px 14px;border-radius:3px;margin:0 16px;text-align:center;letter-spacing:.2px}.enemy-movement span{font-weight:700}.pilot header:has(.enemy-movement){gap:8px;flex-wrap:wrap}.pilot header:has(.enemy-movement)>div:first-child{margin-right:auto}.pilot header:has(.enemy-movement)>.page-badge{margin-left:auto}@media(max-width:850px){.enemy-movement{font-size:12px;padding:5px 8px;margin:0 5px}}@media(max-width:500px){.enemy-movement{order:3;flex:1 0 100%;margin:0;font-size:13px;padding:4px 8px}}@media(max-height:650px){.enemy-movement{padding:4px 10px;font-size:12px}}
.map-legend .legend-arrow{width:25px;height:25px;flex-shrink:0;display:block}
/* Align the unboxed hint to the cockpit's actual grid column. */
.pilot header:has(.enemy-movement){display:grid;grid-template-columns:minmax(0,1fr) auto;grid-template-rows:auto auto;row-gap:3px;column-gap:8px}.pilot header:has(.enemy-movement)>div:first-child{grid-area:1/1;margin:0}.pilot header:has(.enemy-movement)>.page-badge{grid-area:1/2;justify-self:end;align-self:start;margin:0}.pilot header .enemy-movement{grid-area:2/1/3/3;justify-self:stretch;align-self:center;order:initial;flex:initial;margin:0;padding:2px 0;background:transparent;border:0;border-radius:0;box-shadow:none;color:#254f58;text-align:center;font:700 clamp(15px,1.2vw,22px)/1.2 system-ui;letter-spacing:.1px}.pilot header .enemy-movement.tailed{color:#a52f28}.cockpits.single .pilot header:has(.enemy-movement){grid-template-columns:subgrid}.cockpits.single .pilot header .enemy-movement{grid-area:2/1/3/2}@media(max-width:680px){.cockpits.single .pilot header:has(.enemy-movement){grid-template-columns:minmax(0,1fr) auto}.cockpits.single .pilot header .enemy-movement{grid-area:2/1/3/3}.pilot header .enemy-movement{font-size:15px}}@media(max-height:650px){.pilot header .enemy-movement{padding:1px 0;font-size:14px}}

#flightMapButton{display:block;margin:12px 0}#flightMapDialog{width:min(1100px,94vw);max-height:94vh;box-sizing:border-box}#flightMapDialog::backdrop{background:#122c36aa}.flight-map-controls{display:flex;align-items:center;gap:18px;flex-wrap:wrap}.flight-map-controls label{display:flex;align-items:center;gap:8px}.flight-map-canvas{height:min(62vh,650px);background:#eef0e7;border:1px solid #c6c0ad;margin-top:14px}.flight-map-canvas svg{width:100%;height:100%}.flight-map-key{display:flex;gap:24px;flex-wrap:wrap}

#infoDialog .info-actions{display:flex;justify-content:flex-end;align-items:center;gap:12px;margin-bottom:24px}#infoDialog .info-actions #flightMapButton{margin:0;display:inline-block}#infoDialog .info-actions .close{float:none;margin:0}#infoDialog .info-actions #flightMapButton[hidden]{display:none}

.flight-map-perspectives{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;margin:16px 0}.flight-map-perspectives section{min-width:0}.flight-map-perspectives h3{margin:0 0 8px;font-size:16px}.flight-map-photo{overflow:hidden;background:white}.flight-map-photo img{display:block;width:100%;height:auto}@media(max-width:650px){.flight-map-perspectives{grid-template-columns:1fr}}

#flightMapDialog{width:96vw;max-width:1800px;height:94dvh;max-height:94dvh;padding:16px;overflow:hidden}
#flightMapDialog[open]{display:flex;flex-direction:column;gap:8px}
#flightMapDialog>form{flex:none;margin:0;align-self:flex-end}#flightMapDialog>form .close{margin:0;float:none}
#flightMapDialog>h2{flex:none;margin:0;font-size:22px}
#flightMapBody{flex:1;min-height:0;display:flex;flex-direction:column;gap:10px}
.flight-map-controls{flex:none;gap:8px 16px;font-size:13px}.flight-map-controls select{max-width:240px}
.flight-map-stage{flex:1;min-height:0;display:grid;grid-template-columns:minmax(0,1fr);gap:14px}
.flight-map-stage.with-images{grid-template-columns:minmax(0,1fr) minmax(0,1.4fr) minmax(0,1fr)}
.flight-map-stage .flight-map-canvas{height:auto;min-height:0;margin:0;overflow:hidden}
.flight-map-perspective{min-width:0;min-height:0;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:8px}
.flight-map-perspective h3{margin:0;font-size:clamp(11px,1.1vw,16px);text-align:center}
.flight-map-perspective .flight-map-photo{width:min(100%,calc((100dvh - 280px)*var(--photo-ratio)));flex:none}
.flight-map-key{flex:none;margin:0;font-size:13px;justify-content:center}.flight-map-summary{flex:none;margin:0;font-size:14px;line-height:1.35}
@media(max-height:650px){#flightMapDialog{padding:10px;gap:4px}#flightMapBody{gap:6px}.flight-map-controls{font-size:11px;gap:4px 10px}.flight-map-controls select{padding:3px}.flight-map-summary,.flight-map-key{font-size:11px}.flight-map-perspective .flight-map-photo{width:min(100%,calc((100dvh - 230px)*var(--photo-ratio)))}}

.flight-map-photo.contrast img{filter:contrast(1.6)}

.flight-map-summary,#reportText,.log li{color:#000}.log-allied{color:#285f92}.log-german{color:#b44032}

/* Cockpit status: clue above damage, centered over the cockpit image. */
.pilot header:has(.encounter-status){display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:start;min-height:78px}
.cockpits.single .pilot header:has(.encounter-status){grid-template-columns:subgrid}
.pilot header:has(.encounter-status)>div:first-child{grid-area:1/1;align-self:start;z-index:1;justify-self:start}
.pilot header:has(.encounter-status)>.page-badge{grid-area:1/2;justify-self:end}
.pilot header .encounter-status{grid-area:1/1;display:flex;flex-direction:column;align-items:center;gap:5px;min-height:49px;padding-top:0;text-align:center;pointer-events:none}
.pilot header .encounter-status .enemy-movement{margin:0;padding:0;min-height:24px;font-size:clamp(15px,1.2vw,22px)}
.encounter-hits{display:block;color:#111;font:700 clamp(13px,1vw,18px)/1.3 system-ui}
.flight-map-stepper{display:flex;align-items:center;gap:7px}.flight-map-stepper button{padding:5px 11px;font-size:20px;line-height:1}.flight-map-stepper button:disabled{opacity:.35}
@media(max-width:900px){.pilot header .encounter-status{padding-top:28px}.pilot header:has(.encounter-status){min-height:104px}}

/* Reserve the upper hint row even when only damage is shown. */
.pilot header .encounter-status{display:grid;grid-template-rows:26px minmax(24px,auto);gap:5px;justify-items:center;align-items:center}
.pilot header .encounter-status .enemy-movement{grid-row:1;grid-column:1}
.pilot header .encounter-status .encounter-hits{grid-row:2;grid-column:1}
.encounter-hits .damage-amount{color:#b44032}

/* Override legacy banner placement within the two-row status container. */
.cockpits.single .pilot header .encounter-status > .enemy-movement,
.pilot header .encounter-status > .enemy-movement{grid-area:1 / 1 / 2 / 2;align-self:center;justify-self:center}
.cockpits.single .pilot header .encounter-status > .encounter-hits,
.pilot header .encounter-status > .encounter-hits{grid-area:2 / 1 / 3 / 2;align-self:center;justify-self:center}

.direction-moves .move .name{word-break:normal;overflow-wrap:normal;hyphens:auto;-webkit-hyphens:auto}

.direction-moves .move .name .maneuver-label-line{display:block;line-height:1.2}

/* The label container must stack its lines, rather than lay them out as flex columns. */
.direction-moves .move .name{display:block;width:100%;text-align:center}
.direction-moves .move .name > .maneuver-label-line{display:block;width:100%;text-align:center}

.flight-settings{display:flex;align-items:center;gap:10px;flex-wrap:wrap;padding:4px 0 8px;font:12px system-ui}.flight-settings label{display:flex;align-items:center;gap:8px}.flight-settings select,.flight-settings button{padding:5px 8px}.flight-settings #rulesSummary{color:#49616a;font-size:11px}.flight-options-dialog,.pilot-roster-dialog{width:min(880px,94vw);max-height:90dvh;overflow:auto;background:var(--paper);color:var(--ink);border:1px solid var(--line);padding:22px}.flight-options-dialog h2,.pilot-roster-dialog h2{margin:0 0 12px}.flight-options-dialog p,.pilot-roster-dialog p{font:14px/1.45 system-ui}.flight-options-dialog label,.pilot-roster-dialog label{display:flex;flex-direction:column;gap:5px;font:13px/1.4 system-ui;margin:8px 0}.option-fields,.setup-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.option-fields strong{grid-column:1/-1}.dialog-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:18px}.phase-note{border-left:3px solid var(--blue);padding:8px 12px;background:#e4eae1}.advanced-damage-card{border:1px solid var(--line);border-left:4px solid var(--blue);padding:7px 10px;background:var(--paper);font:11px/1.4 system-ui}.advanced-damage-card.german{border-left-color:var(--red)}.advanced-damage-card>div:first-child{display:flex;justify-content:space-between;gap:10px}.area-damage{display:flex;gap:12px;flex-wrap:wrap;margin:3px 0;text-transform:capitalize}.aircraft-state{color:#4b6168}.basic-pilot-name{grid-column:1/-1;font:10px system-ui;color:#4b6168}.dac-reference{display:block;width:100%;max-height:230px;object-fit:contain;margin:10px 0;background:white}.dac-picker{display:grid;grid-template-columns:repeat(var(--dac-columns),minmax(0,1fr));gap:3px}.dac-picker button{padding:5px 2px;font:12px system-ui}.dac-picker small{display:block;font-size:10px}.dac-picker button[aria-pressed=true]{background:#d0e1e8;outline:2px solid var(--blue)}.shot-allocation{border-top:1px solid var(--line);padding:8px 0}.roster-list{padding-left:16px;max-height:200px;overflow:auto;font:12px/1.4 system-ui}.roster-list p{font-size:11px}.pilot-roster-dialog textarea{width:100%;font:12px/1.4 monospace}.pilot-roster-dialog input{min-width:0}.advanced-flight .combat-note{min-height:38px}.advanced-flight .pilot h2{font-size:19px}@media(max-width:680px){.option-fields,.setup-grid{grid-template-columns:1fr}.flight-settings #rulesSummary{display:none}.advanced-damage-card>div:first-child{flex-direction:column;gap:2px}.area-damage{gap:5px}.dac-picker button{font-size:10px}.flight-options-dialog,.pilot-roster-dialog{padding:12px}}

.condition-button{font:10px system-ui;padding:2px 5px}

.training-rule-notes{margin-top:8px;font:11px/1.35 system-ui}.training-rule-notes p{font-size:11px}.training-rule-notes summary{cursor:pointer;color:#285f72}

.dac-allocation-reference{display:block;width:100%;max-height:170px;object-fit:contain;background:white}.flight-options-dialog .impact-empty-check{flex-direction:row;align-items:center;gap:7px}

/* Keep navigation independent of the variable-length rule description. */
body>header{display:grid;grid-template-columns:max-content minmax(0,1fr);column-gap:22px;row-gap:6px;align-items:start}
body>header>.masthead{grid-area:1/1;align-self:center}
body>header>nav{grid-area:1/2;min-width:0;align-self:start}
body>header>.flight-settings{grid-area:2/1/3/3;min-width:0;width:100%;padding:0 0 4px}
.flight-settings #rulesSummary{min-width:0;flex:1}
@media(max-width:680px){body>header{grid-template-columns:minmax(0,1fr);gap:5px}body>header>.masthead{grid-area:1/1}body>header>nav{grid-area:2/1}body>header>.flight-settings{grid-area:3/1}}

/* Turn actions stay in the cockpit page, directly below the maneuver buttons. */
.advanced-flight .advanced-controls{grid-area:2/2/4/3;min-height:0;min-width:0;display:flex;flex-direction:column;overflow:hidden;background:var(--paper);border-left:1px solid var(--line)}
.advanced-flight .advanced-controls>.maneuvers{grid-area:auto;flex:0 0 auto;min-height:0;height:auto;border:0;padding-bottom:6px}
#flightActionMount{min-height:0;display:flex;flex:1;flex-direction:column}
.turn-actions{min-height:0;overflow:auto;overscroll-behavior:contain;padding:10px 12px;border-top:1px solid var(--line);font:12px/1.35 system-ui;color:var(--ink);background:#f9f5eb}
.turn-actions[hidden]{display:none}
.turn-actions h2{font:700 17px/1.2 Georgia,serif;margin:0 0 8px}.turn-actions h3{font:700 13px/1.3 system-ui;margin:6px 0}
.turn-actions p{font:12px/1.35 system-ui;margin:5px 0 8px}.turn-actions .phase-note{padding:6px 8px;margin:0 0 8px}
.turn-actions label{display:flex;flex-direction:column;gap:3px;font:12px/1.3 system-ui;margin:4px 0}.turn-actions select,.turn-actions button{font-size:12px;padding:5px 8px}
.turn-actions .option-fields{gap:5px 12px}.turn-actions .option-fields strong{font:700 13px/1.3 system-ui}
.turn-actions .dialog-actions{margin-top:7px}.turn-actions .dac-reference{max-height:135px}.turn-actions .dac-allocation-reference{max-height:120px}
.turn-actions .dac-picker{gap:2px}.turn-actions .dac-picker button{font-size:10px;padding:3px 1px}.turn-actions .dac-picker small{font-size:9px}
.turn-actions .impact-empty-check{flex-direction:row;align-items:center;gap:7px}.turn-actions .fine{font-size:10px}
@media(max-width:680px){.advanced-flight .advanced-controls{grid-area:auto;max-height:55dvh}.turn-actions{padding:8px}.turn-actions .option-fields{grid-template-columns:repeat(2,minmax(0,1fr))}}

.turn-actions:has(#commitPlan){display:grid;grid-template-columns:minmax(0,1fr) auto;gap:4px 10px;padding:7px 10px}
.turn-actions:has(#commitPlan)>h2{grid-column:1/-1;margin:0;font-size:16px;line-height:1.2}
.turn-actions:has(#commitPlan)>.phase-note{grid-column:1/-1;font-size:10px;line-height:1.3;padding:4px 6px;margin:0}
.turn-actions:has(#commitPlan)>.option-fields{grid-column:1/-1;gap:3px 10px}
.turn-actions:has(#commitPlan) .option-fields label{font-size:10px;margin:0;gap:2px}
.turn-actions:has(#commitPlan) select{font-size:11px;padding:3px 6px}
.turn-actions:has(#commitPlan) .option-fields strong{font-size:11px;line-height:1.2}
.turn-actions:has(#commitPlan)>p:not(.phase-note){grid-column:1;font-size:10px;line-height:1.2;margin:0;align-self:center}
.turn-actions:has(#commitPlan)>.dialog-actions{grid-column:2;margin:0;gap:5px;align-self:end}
.turn-actions:has(#commitPlan) .dialog-actions button{font-size:11px;padding:4px 7px;white-space:nowrap}

.area-damage{align-items:flex-start;gap:8px 15px;margin:5px 0}.health-area{display:grid;gap:3px;min-width:72px}.health-caption{display:flex;align-items:baseline;justify-content:space-between;gap:7px;font:10px/1.2 system-ui;text-transform:capitalize}.health-caption strong{white-space:nowrap;font-size:10px}.health-track{width:calc(var(--capacity)*clamp(7px,.8vw,12px));height:7px;background:#d7d2c5;border-radius:2px;overflow:hidden}.health-fill{display:block;height:100%;background:#285f92;transition:width .15s ease}.advanced-damage-card.german .health-fill{background:#b44032}
.pilot-card-list{list-style:none;padding:0;max-height:230px;display:grid;gap:7px}.pilot-card-list li{margin:0}.pilot-card{display:flex;flex-direction:column;gap:4px;text-align:left;width:100%;padding:9px 10px}.pilot-card-heading{display:flex;justify-content:space-between;gap:8px;width:100%}.pilot-card-heading>span{font-size:11px;color:#285f72}.pilot-card[aria-pressed="true"]{border:2px solid #285f72;background:#dce9e7;padding:8px 9px}.pilot-card-ability{font-size:11px;line-height:1.4}.roster-reset-tools{display:flex;gap:8px;margin:10px 0}.danger-button{color:#9c3429;border-color:#b77c72}#rosterResetConfirm{padding:10px;border:1px solid #b77c72;background:#f2e0d9;margin:10px 0}#rosterResetConfirm button{margin-right:6px}

/* Damage tracks: gray total capacity, red damage taken, stacked by section. */
.advanced-damage-card .area-damage{display:flex;flex-direction:column;align-items:flex-start;gap:4px;margin:6px 0}
.advanced-damage-card .health-area{display:grid;grid-template-columns:58px auto 84px;gap:8px;align-items:center;min-width:0}
.health-section-name{font:10px/1.2 system-ui;text-transform:capitalize}
.advanced-damage-card .health-track{height:8px;border-radius:2px;background:#d8d3c5}
.advanced-damage-card .health-fill,.advanced-damage-card.german .health-fill{background:#893d31}
.health-damage-value{font:10px/1.2 system-ui;white-space:nowrap}
@media(max-width:680px){.advanced-damage-card .health-area{grid-template-columns:46px auto 64px;gap:5px}.health-damage-value,.health-section-name{font-size:9px}}

.advanced-damage-card .health-area{grid-template-columns:58px calc(13*clamp(7px,.8vw,12px)) 84px}
@media(max-width:680px){.advanced-damage-card .health-area{grid-template-columns:46px calc(13*7px) 64px}}

/* Leave room for stacked damage sections and on-page planning controls. */
.advanced-flight .pilot header:has(.encounter-status){min-height:64px}
.advanced-flight .pilot header .encounter-status{grid-template-rows:20px 20px;gap:3px;min-height:43px}
.advanced-flight .pilot header .encounter-status .enemy-movement{min-height:0;font-size:16px;line-height:20px}
.advanced-flight .encounter-hits{font-size:13px;line-height:18px}

/* Damage labels and values use fixed columns; track starts never depend on digit width. */
.advanced-damage-card .aircraft-card-body{display:grid;grid-template-columns:max-content minmax(0,1fr);gap:14px;align-items:start;margin-top:6px}
.advanced-damage-card .aircraft-card-body .area-damage{margin:0;gap:5px}
.advanced-damage-card .health-area{grid-template-columns:58px 40px calc(13*clamp(7px,.8vw,12px));gap:7px}
.advanced-damage-card .health-damage-value{font-variant-numeric:tabular-nums;text-align:right;text-transform:none;font-weight:400}
.aircraft-details{min-width:0;font:10px/1.3 system-ui;color:#36515c;display:grid;gap:1px}
.aircraft-details strong{font-weight:600}.aircraft-details .condition-clear{color:#68716b}
.aircraft-effect-details{font:10px/1.4 system-ui}.aircraft-effect-details summary{cursor:pointer}.aircraft-effect-details ul{margin:4px 0;padding-left:16px;max-height:90px;overflow:auto}
@media(max-width:900px){.advanced-damage-card .aircraft-card-body{gap:9px}.advanced-damage-card .health-area{grid-template-columns:48px 34px calc(13*7px);gap:5px}.aircraft-details{font-size:9px}}
@media(max-width:680px){.advanced-damage-card .aircraft-card-body{grid-template-columns:minmax(0,1fr)}.advanced-damage-card .health-area{grid-template-columns:46px 34px calc(13*7px);gap:5px}}

/* Compact, aligned damage and ammunition columns. */
.advanced-damage-card .health-area,.advanced-damage-card .ammo-area{display:grid;grid-template-columns:42px 32px calc(13*clamp(7px,.8vw,12px));gap:4px;align-items:center}
.gun-status{display:grid;gap:3px;margin-top:8px;padding-top:5px;border-top:1px solid var(--line)}
.ammo-track{height:8px;border-radius:2px;overflow:hidden;background:#d8d3c5}
.ammo-fill{display:block;height:100%;background:#292c2e;transition:width .15s ease}
.gun-note{font:9px/1.3 system-ui;max-width:240px}
@media(max-width:900px){.advanced-damage-card .health-area,.advanced-damage-card .ammo-area{grid-template-columns:40px 30px calc(13*7px)}}

.skirmish-pilot-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:5px;margin-bottom:12px}
.skirmish-pilot-options .pilot-card{padding:7px;font-size:11px;min-height:42px}
.pilot-benefits{font:12px/1.45 system-ui;padding:10px;background:#e8ece2;border-left:3px solid #365d6b;margin-top:10px}
.pilot-benefits p{font:inherit;margin:8px 0 0}.pilot-benefits .fine{font-size:10px}
#pilotRosterDialog input[readonly]{background:#e4dfd3;color:#50616a}
@media(max-width:680px){.skirmish-pilot-options{grid-template-columns:repeat(2,minmax(0,1fr))}}

.flightline:has(#altitudeStrip:not([hidden])){display:grid;grid-template-columns:minmax(0,1fr) 462px minmax(0,1fr);gap:10px;align-items:center}
.flightline:has(#altitudeStrip:not([hidden])) #turn{grid-column:1;grid-row:1;min-width:0}
.flightline:has(#altitudeStrip:not([hidden])) #flightState{grid-column:3;grid-row:1;min-width:0;text-align:right;overflow-wrap:anywhere}
#altitudeStrip{grid-column:2;grid-row:1;display:grid;grid-template-columns:146px 146px 146px;gap:12px;align-items:center;white-space:nowrap;font:700 13px/1.4 system-ui;font-variant-numeric:tabular-nums;text-align:left}
#altitudeStrip[hidden]{display:none}
.altitude-allied{color:#1e66a6}.altitude-german{color:#b8392b}
.altitude-difference{display:grid;grid-template-columns:25px 65px 44px;gap:4px;align-items:center}
@media(max-width:1100px){.flightline:has(#altitudeStrip:not([hidden])){grid-template-columns:minmax(0,1fr) minmax(0,1fr)}.flightline:has(#altitudeStrip:not([hidden])) #flightState{grid-column:2}#altitudeStrip{grid-column:1/-1;grid-row:2;justify-self:center}}
@media(max-width:520px){#altitudeStrip{font-size:10px;grid-template-columns:110px 110px 110px;gap:4px}.altitude-difference{grid-template-columns:20px 48px 34px;gap:2px}}

.turn-actions:has(#commitPlan)>.maneuver-rule-note{max-height:36px;overflow:auto;overscroll-behavior:contain}

.altitude-difference{color:#000}

.difference-range.range-far .range-word{color:#b8392b}

/* Reserve room for spare-drum counts without shifting ammunition tracks. */
.advanced-damage-card .ammo-area{grid-template-columns:42px 54px calc(13*clamp(7px,.8vw,12px))}
@media(max-width:900px){.advanced-damage-card .ammo-area{grid-template-columns:40px 50px calc(13*7px)}}

.advanced-damage-card .ammo-area{grid-template-columns:84px 54px calc(13*clamp(7px,.8vw,12px))}
@media(max-width:900px){.advanced-damage-card .ammo-area{grid-template-columns:76px 50px calc(13*7px)}}

/* Keep the range beside its number within the fixed difference slot. */
.altitude-difference{display:flex;gap:4px;white-space:nowrap}

/* Weapon names and game categories share a fixed label column. */
.advanced-damage-card .ammo-area{grid-template-columns:148px 54px calc(13*clamp(7px,.8vw,12px))}
.ammo-area .health-section-name{white-space:nowrap;text-transform:none}
@media(max-width:900px){.advanced-damage-card .ammo-area{grid-template-columns:132px 50px calc(13*7px)}.ammo-area .health-section-name{font-size:9px}}

.gun-shot-fields{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:8px 12px}.gun-shot-fields label{min-width:0}.gun-shot-fields select{width:100%}

.shot-breakdown{font-variant-numeric:tabular-nums}.turn-actions .shot-breakdown p{margin:4px 0}.shot-conditions{font-weight:600;color:#893d31}

.plan-inclination{display:flex;flex-direction:column;gap:2px;font:10px/1.3 system-ui}
.plan-pitch-buttons{display:flex;gap:4px;flex-wrap:wrap}
.turn-actions:has(#commitPlan) .plan-pitch-buttons button{font-size:11px;line-height:1.2;padding:4px 9px}
.plan-pitch-buttons button[aria-pressed="true"]{background:#345a6c;border-color:#345a6c;color:white}
.fixed-plan-amount{display:flex;align-items:center;min-height:24px;font:600 12px/1.3 system-ui}

/* Firing replaces maneuver controls, leaving room for the matching gun tables. */
.advanced-flight .advanced-controls:has(.turn-actions[data-phase="shoot"]:not([hidden]))>.maneuvers{display:none}
.turn-actions[data-phase="shoot"]{flex:1;border-top:0}
.gun-chart-list{display:grid;grid-template-columns:repeat(auto-fit,minmax(250px,1fr));gap:12px;margin-top:14px}
.gun-chart{min-width:0;border:1px solid var(--line);background:#f5f0e4;padding:7px}
.turn-actions .gun-chart h3{font-size:12px;margin:0 0 5px}
.gun-chart table{width:100%;table-layout:fixed;border-collapse:collapse;font:10px/1.25 system-ui;font-variant-numeric:tabular-nums}
.gun-chart caption{text-align:right;font-size:9px;padding-bottom:4px}
.gun-chart .ammo-column{width:30px}.gun-chart .burst-column{width:56px}
.gun-chart th,.gun-chart td{padding:6px 1px;text-align:center;border:1px solid #c6bda9}
.gun-chart thead{background:#ded8c8}.gun-chart tbody th{font-weight:500;text-align:left;padding-left:4px}
.gun-chart.selected-gun{border-color:#345a6c}.gun-chart .selected-burst{background:#d7e4e5;font-weight:700}
.turn-actions .gun-chart-key{font-size:10px;margin-top:8px}
@media(max-height:800px){.gun-chart th,.gun-chart td{padding:4px 1px}.gun-chart-list{margin-top:10px}}

.damage-distribution{font-weight:600}.gun-chart .rolled-cell{background:#345a6c;color:#fff;font-weight:700;box-shadow:inset 0 0 0 1px #345a6c}

.maneuver-rule-note .firing-restriction{color:#b8392b;font-weight:600}

/* Every ammo point has the same width; spare drums are tracked separately. */
.advanced-damage-card{--ammo-unit:clamp(3.6px,.5vw,6px)}
.advanced-damage-card .ammo-area{grid-template-columns:148px 54px calc(25*var(--ammo-unit))}
.ammo-track{width:calc(var(--ammo-capacity)*var(--ammo-unit))}
@media(max-width:900px){.advanced-damage-card{--ammo-unit:3.6px}.advanced-damage-card .ammo-area{grid-template-columns:132px 50px calc(25*var(--ammo-unit))}}

.hangar-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:18px}
.hangar-aircraft{min-width:0;border:1px solid var(--line);border-left:4px solid #345a6c;padding:12px;background:#f5f0e4}
.hangar-aircraft.german{border-left-color:#893d31}
.hangar-aircraft .hangar-side{margin:0 0 8px;font:700 16px/1.2 Georgia,serif;color:#1e66a6}
.hangar-aircraft.german .hangar-side{color:#b8392b}
.hangar-aircraft>label{display:flex;flex-direction:column;gap:4px;font:12px/1.3 system-ui}
.hangar-aircraft select{width:100%;padding:7px 9px;font-size:12px}
.hangar-stat-group{margin-top:12px}.hangar-stat-group h3{margin:0 0 5px;font:700 12px/1.3 system-ui}
.hangar-stat-group dl{margin:0;font:12px/1.4 system-ui;font-variant-numeric:tabular-nums}
.hangar-capacities{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:3px 14px}
.hangar-capacities>div,.hangar-performance>div{display:flex;justify-content:space-between;gap:12px}
.hangar-stat-group dt,.hangar-stat-group dd{margin:0}.hangar-stat-group dd{font-weight:600;text-align:right}
.hangar-performance>div{padding:3px 0;border-bottom:1px solid #ded8c8}.hangar-performance dt{flex-shrink:0}
.hangar-weapon{display:grid;gap:2px;font:11px/1.4 system-ui;margin-top:6px}
.hangar-intro{margin:0 0 14px}.hangar-art-note{margin:12px 0 0}
@media(max-width:680px){.hangar-grid{grid-template-columns:minmax(0,1fr)}}

.pilot-roster-dialog:has(.hangar-grid){max-height:94dvh;padding:18px}
.pilot-roster-dialog:has(.hangar-grid) h2{margin-bottom:8px}
.pilot-roster-dialog .hangar-intro{font-size:12px;margin:0 0 10px}
.pilot-roster-dialog .hangar-art-note{font-size:11px;line-height:1.3;margin:10px 0 0}
.pilot-roster-dialog:has(.hangar-grid)>.dialog-actions{margin-top:12px}

.plan-altitude-caption{display:flex;align-items:center;justify-content:space-between;gap:8px;min-height:13px}
.plan-dive-warning{color:#b8392b;font:600 9px/1.3 system-ui;white-space:nowrap}
@media(max-width:680px){.plan-altitude-caption{flex-wrap:wrap}.plan-dive-warning{white-space:normal}}

.pilot-roster-dialog:has(.hangar-grid){width:min(1100px,96vw)}
.hangar-aircraft{--hangar-hp-unit:12px;--hangar-ammo-unit:6px}
.hangar-stat-group .hangar-capacities{display:grid;grid-template-columns:minmax(0,1fr);gap:5px}
.hangar-stat-group .hangar-capacities>div{display:grid;grid-template-columns:58px 40px 156px;gap:7px;align-items:center}
.hangar-stat-group .hangar-hp-value{font-weight:400}
.hangar-health-track{width:calc(var(--capacity)*var(--hangar-hp-unit));height:8px;border-radius:2px;background:#d8d3c5}
.hangar-weapon{display:grid;grid-template-columns:148px 54px 150px;gap:4px;align-items:center;margin-top:6px;font-variant-numeric:tabular-nums}
.hangar-weapon strong{font-size:10px;font-weight:400;white-space:nowrap}
.hangar-ammo-value{text-align:right;font-size:10px;white-space:nowrap}
.hangar-ammo-track{width:calc(var(--ammo-capacity)*var(--hangar-ammo-unit));height:8px;background:#d8d3c5;border-radius:2px;overflow:hidden}
.hangar-ammo-track>span{display:block;width:100%;height:100%;background:#292c2e}
@media(max-width:900px){.hangar-aircraft{--hangar-hp-unit:9px;--hangar-ammo-unit:4px}.hangar-stat-group .hangar-capacities>div{grid-template-columns:54px 34px 117px;gap:5px}.hangar-weapon{grid-template-columns:132px 46px 100px}.hangar-weapon strong{font-size:9px}}

.hangar-stat-group .hangar-capacities>div{justify-content:start}
.hangar-stat-group:has(.hangar-weapon){min-height:62px}

/* Names above capacity-only values and scaled bars in the Hangar. */
.pilot-roster-dialog:has(.hangar-grid){width:min(1250px,96vw);max-width:1250px}
.hangar-aircraft>div[id^="hangarStats"]{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.15fr);column-gap:20px;align-items:start}
.hangar-aircraft>div[id^="hangarStats"]>.hangar-stat-group:nth-child(1){grid-area:1/1}
.hangar-aircraft>div[id^="hangarStats"]>.hangar-stat-group:nth-child(2){grid-area:2/1;min-height:0}
.hangar-aircraft>div[id^="hangarStats"]>.hangar-stat-group:nth-child(3){grid-area:1/2/3/3}
.hangar-stat-group .hangar-capacities{gap:9px}
.hangar-stat-group .hangar-capacities>div{grid-template-columns:40px 156px;column-gap:7px;row-gap:3px;justify-content:start}
.hangar-capacities dt{grid-column:1/-1}
.hangar-stat-group .hangar-hp-value{grid-column:1;text-align:right}
.hangar-health-track{grid-column:2}
.hangar-weapon{grid-template-columns:40px 150px;column-gap:7px;row-gap:3px;margin-top:9px}
.hangar-weapon strong{grid-column:1/-1}
.hangar-ammo-value{grid-column:1}.hangar-ammo-track{grid-column:2}
@media(max-width:1100px){.hangar-aircraft>div[id^="hangarStats"]{display:block}.hangar-stat-group .hangar-capacities>div{grid-template-columns:40px 117px}.hangar-weapon{grid-template-columns:40px 100px}}

.advanced-controls:has(.turn-actions[data-phase="recovery"]:not([hidden]))>.recovery-status{display:none}
.turn-actions[data-phase="recovery"]{flex:1;border-top:0}
.turn-actions[data-phase="recovery"] .option-fields{margin:12px 0}
.turn-actions[data-phase="recovery"] .plan-inclination{font-size:12px;gap:5px}
/* Planning never changes maneuver dimensions; compact sizing depends only on viewport height. */
.advanced-flight .advanced-controls{--flight-move-height:74px;--flight-symbol-size:30px;--flight-name-size:9px}
.advanced-flight .advanced-controls>.maneuvers{gap:5px}
.advanced-flight .advanced-controls .direction-moves .move{height:var(--flight-move-height)}
.advanced-flight .advanced-controls .direction-moves .move img{width:var(--flight-symbol-size);height:var(--flight-symbol-size)}
.advanced-flight .advanced-controls .direction-moves .move .name{font-size:var(--flight-name-size);line-height:1.1}
.advanced-flight .advanced-controls .move-group{margin-top:0}
.advanced-flight .advanced-controls .move-group h3{margin:0 0 3px}
.advanced-flight .advanced-controls .direction-section h4{margin:0 0 3px;font-size:9px;line-height:1.2}
.turn-actions:has(#commitPlan){margin-top:8px}
@media(max-height:850px){.advanced-flight .advanced-controls{--flight-move-height:54px;--flight-symbol-size:26px;--flight-name-size:8.5px}}
@media(max-height:700px){.advanced-flight .advanced-controls{--flight-move-height:48px;--flight-symbol-size:22px;--flight-name-size:8px}}

/* Top-layer altitude list opens upward and is never clipped by the controls panel. */
#altitudePicker{margin:0;padding:3px;border:1px solid #8d938d;border-radius:3px;background:#f5f0e4;color:var(--ink);overflow-y:auto;box-shadow:0 4px 16px #0004;overscroll-behavior:contain;font:12px/1.3 system-ui}
#altitudePicker::backdrop{background:transparent;pointer-events:none}
#altitudePicker button{display:block;width:100%;border:0;border-radius:0;background:transparent;text-align:left;padding:6px 9px;font-size:12px}
#altitudePicker button[aria-selected="true"]{background:#d7e4e5;font-weight:700}
#altitudePicker button:hover,#altitudePicker button:focus-visible{background:#345a6c;color:#fff;outline:none}
.plan-altitude-control>.plan-altitude-caption,.search-altitude-control>.search-altitude-caption{order:2}
.plan-altitude-control>select,.plan-altitude-control>.fixed-plan-amount,.search-altitude-control>select,.search-altitude-control>strong{order:1}

/* Duplicate altitude reference at the foot of the maneuver area. */
.advanced-flight .combat-note{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,1fr);padding:0;gap:0;align-items:center}
.advanced-flight .combat-note-message{padding:5px 12px;font-size:10px}
#lowerAltitudePanel{padding:4px 10px;border-left:1px solid var(--line);min-width:0}
.altitude-range-reference{display:flex;justify-content:space-between;gap:4px;flex-wrap:wrap;font:9px/1.3 system-ui;color:#000;margin-bottom:4px;font-variant-numeric:tabular-nums}
#lowerAltitudeStrip{display:grid;grid-template-columns:146px 146px 146px;gap:12px;justify-content:center;font:700 12px/1.4 system-ui;font-variant-numeric:tabular-nums;white-space:nowrap}
@media(max-width:1100px){#lowerAltitudeStrip{grid-template-columns:120px 132px 120px;gap:4px;font-size:10px}}
@media(max-width:680px){.advanced-flight .combat-note{grid-template-columns:minmax(0,1fr)}#lowerAltitudePanel{border-left:0;border-top:1px solid var(--line)}#lowerAltitudeStrip{grid-template-columns:110px 110px 110px;gap:4px;font-size:10px}}
@media(max-height:850px){.turn-actions:has(#commitPlan){padding-top:3px;padding-bottom:3px;gap:2px 10px}.turn-actions:has(#commitPlan)>h2{font-size:14px}}

.gun-chart-group{margin-top:14px}.gun-chart-group+.gun-chart-group{padding-top:12px;border-top:1px solid var(--line)}.turn-actions .chart-side-heading{font-size:12px;margin:0 0 6px}.gun-chart-group .gun-chart-list{margin-top:0}

/* Basic damage bars use the full card width; remaining HP is not repeated. */
.damage-card{grid-template-columns:minmax(0,1fr)}
.damage-card .damage-title,.damage-card progress,.damage-card .damage-detail,.damage-card .basic-pilot-name{grid-column:1/-1}
/* Campaign saves and preparation */
.campaign-dialog{width:min(1320px,96vw);max-height:94vh;box-sizing:border-box;padding:24px;overflow:auto;}
.campaign-heading{display:flex;align-items:center;justify-content:space-between;gap:16px}.campaign-heading h2{margin:0}.campaign-dialog h3{margin:12px 0}.campaign-dialog p{line-height:1.45}
.squadron-slots{display:grid;grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:12px}.squadron-slot{border:1px solid #c5bca7;padding:14px;min-width:0}.slot-tools{display:flex;flex-wrap:wrap;gap:6px;margin:12px 0}.slot-tools label{width:100%}.campaign-dialog label{display:block}.campaign-dialog select,.campaign-dialog input:not([type=checkbox]){max-width:100%;box-sizing:border-box}.campaign-option-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin:18px 0}.campaign-dialog .campaign-option{display:flex;gap:10px;padding:12px;border:1px solid #c5bca7}.campaign-option input{flex:none;align-self:flex-start;margin-top:4px}.campaign-option small{display:block;margin-top:4px;line-height:1.4}.campaign-option:has(input:disabled){opacity:.55}.campaign-sides{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:22px}.campaign-sides>section{min-width:0;border:1px solid #c5bca7;padding:14px}.campaign-pilot-choices{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;margin-bottom:12px}.campaign-pilot-choices button{white-space:normal;text-align:left}.campaign-pilot-choices small{display:block}.campaign-pilot-choices [aria-pressed=true]{background:#d8e5e1;border:2px solid #355b69;color:#143d4c;opacity:1}.campaign-aircraft-stats{font-size:12px;margin-top:14px}.campaign-aircraft-stats .hangar-stat-columns{display:block}.campaign-pilot-record{border-top:1px solid #c5bca7;padding:12px 0}.campaign-start-values,.campaign-dashboard-actions{display:flex;flex-wrap:wrap;align-items:center;gap:12px;margin:14px 0}.campaign-debrief{border-left:3px solid #355b69;padding:6px 14px;background:#dce3db}#campaignError{color:#a62f26}#campaignError:empty{display:none}#campaignImportText{width:100%;box-sizing:border-box}#slotConfirmation:not(:empty){background:#e5ddd0;padding:14px;margin-top:16px}#campaignStatus{padding:7px 10px;border-top:1px solid #c5bca7;font-size:12px}#campaignStatus button{padding:4px 8px;min-height:0;margin-left:8px}.campaign-flight-details{font-weight:600;margin-top:4px}
@media(max-width:700px){.campaign-sides,.campaign-option-grid{grid-template-columns:1fr}.campaign-dialog{padding:14px}.campaign-heading{align-items:flex-start}}
.campaign-dialog{max-width:1320px}.campaign-aircraft-stats{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:10px 18px}.campaign-aircraft-stats>.hangar-stat-group:nth-child(1){grid-area:1/1}.campaign-aircraft-stats>.hangar-stat-group:nth-child(2){grid-area:2/1}.campaign-aircraft-stats>.hangar-stat-group:nth-child(3){grid-area:1/2/3/3}.campaign-aircraft-stats .hangar-capacities,.campaign-aircraft-stats .hangar-weapon{--hangar-hp-unit:10px;--hangar-ammo-unit:5px}.turn-actions h2.firing-restriction{color:#b8392b}
@media(max-width:800px){.campaign-aircraft-stats{display:block}}
/* Locked movement is replaced by pursuit/firing controls, without shrinking buttons. */
.advanced-flight .advanced-controls:has(.turn-actions[data-phase="pursuit"]:not([hidden]))>.maneuvers,.advanced-flight .advanced-controls:has(.turn-actions[data-phase="aim"]:not([hidden]))>.maneuvers,.advanced-flight .advanced-controls:has(.turn-actions[data-phase="allocation"]:not([hidden]))>.maneuvers{display:none}
.turn-actions[data-phase="pursuit"],.turn-actions[data-phase="aim"],.turn-actions[data-phase="allocation"]{flex:1;border-top:0}
.campaign-active #campaignStatus{font:11px/20px system-ui;padding:3px 8px}.campaign-active #campaignStatus button{font-size:11px;padding:2px 7px;line-height:18px}.campaign-active .advanced-flight .pilot header:has(.encounter-status:empty){min-height:36px}.campaign-active .pilot header .encounter-status:empty{display:none;min-height:0;padding:0}
.campaign-aircraft-choices{display:flex;flex-wrap:wrap;gap:6px;margin-bottom:14px}.campaign-aircraft-choices button{text-align:left;white-space:normal}.campaign-aircraft-choices small{display:block;font-size:11px}.campaign-aircraft-choices [aria-pressed=true]{background:#d8e5e1;border-color:#355b69}.unknown-squadron{display:flex;flex-direction:column;justify-content:center;text-align:center;background:#e9e5da;color:#4b5658}
.campaign-creation-selectors{display:flex;align-items:center;flex-wrap:wrap;gap:12px 20px}.campaign-dialog .campaign-creation-selectors label{display:flex;align-items:center;gap:8px}

/* Keep locked checkboxes gray; emphasize the enabled campaign options. */
.campaign-dialog .campaign-options-readonly .campaign-option:has(input:checked){opacity:1}
.campaign-options-readonly input[type=checkbox]:checked{opacity:.55}
.campaign-options-readonly .campaign-option:has(input:checked)>span{color:#000}
/* Squadron desk replaces the cockpit between campaign missions. */
#campaignHome[hidden]{display:none!important}#campaignHome{flex:1;min-height:0;display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,1fr);gap:12px}
.campaign-overview #cockpits,.campaign-overview #maneuverMap,.campaign-overview #handoff,.campaign-overview #altitudeStrip,.campaign-overview #turnReport{display:none!important}
.campaign-overview .log,.campaign-overview #guide{display:none}.campaign-overview #campaignStatus{flex-shrink:0}
.campaign-date-panel,.campaign-mission-panel{min-width:0;min-height:0;border:1px solid var(--line);background:var(--paper);padding:24px;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center}
.campaign-date-panel>h2{font-size:clamp(30px,4.2vw,64px);line-height:1.1;margin:0 0 26px}.campaign-record{margin:0;font:20px/1.8 system-ui;font-variant-numeric:tabular-nums}.campaign-record>div{display:flex;justify-content:center;gap:12px}.campaign-record dt,.campaign-record dd{margin:0}.campaign-record dd{font-weight:700;min-width:2ch;text-align:left}.campaign-mission-panel>h2{font-size:28px;margin:0 0 12px}.campaign-mission-panel>.primary{font-size:18px;padding:16px 24px;margin:18px 0}.campaign-home-actions{display:flex;justify-content:center;flex-wrap:wrap;gap:8px;margin-top:14px}
.campaign-summary-card{height:var(--campaign-card-height,128px);background:var(--paper);border:1px solid var(--line);border-left:5px solid #345a6c;padding:9px 12px;overflow:hidden;min-width:0}.campaign-summary-card.german{border-left-color:#893d31}.campaign-summary-card>h3{font:700 11px/1.3 system-ui;margin:0 0 6px}.campaign-summary-columns{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:12px;font:11px/1.4 system-ui}.campaign-summary-columns>div{min-width:0}.campaign-summary-columns ul{list-style:none;padding:0;margin:2px 0 0}.campaign-summary-columns li{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.campaign-summary-columns p{margin:2px 0 0}.classified-squadron{height:calc(100% - 22px);display:grid;place-content:center;font:700 clamp(18px,2vw,30px)/1.2 system-ui;letter-spacing:4px;color:#555b58}
#playModeMenu{margin:0;padding:4px;border:1px solid #b6b3a5;background:var(--paper);border-radius:3px;overflow:auto;box-shadow:0 5px 16px #0003}#playModeMenu button{display:block;width:100%;border:0;border-radius:0;text-align:left;padding:8px 10px;font-size:13px;background:transparent}#playModeMenu button[aria-selected=true]{background:#dbd7ca}#playModeMenu button:hover,#playModeMenu button:focus-visible{background:#345a6c;color:#fff;outline:0}
@media(max-height:750px){.campaign-date-panel,.campaign-mission-panel{padding:14px}.campaign-date-panel>h2{margin-bottom:14px}.campaign-record{font-size:17px}.campaign-mission-panel>.primary{margin:10px 0}}@media(max-width:700px){#campaignHome{grid-template-columns:1fr;grid-template-rows:1fr 1fr;gap:6px}.campaign-date-panel>h2{font-size:28px;margin-bottom:8px}.campaign-record{font-size:14px;line-height:1.5}.campaign-mission-panel>h2{font-size:18px}.campaign-mission-panel>.primary{padding:8px 14px;font-size:14px}.campaign-summary-columns{font-size:9px;gap:5px}}

/* One row per aircraft, including duplicate airframes. */
.campaign-summary-card{min-height:calc(52px + var(--summary-row-count,4)*12px)}
.campaign-summary-columns li{line-height:12px}

/* Campaign record uses the same serif typeface as the season heading. */
.campaign-record{font-family:Georgia,'Times New Roman',serif;font-weight:400}
.campaign-record dd{font-weight:400}
.opponent-aircraft-selection{display:flex;flex-direction:column;gap:4px;margin:10px 0;font:13px/1.4 system-ui}.opponent-aircraft-selection small{color:#586566}

.campaign-result-actions{display:flex;justify-content:center;margin-top:20px}.campaign-result-actions button{font-size:14px;padding:10px 18px}

/* Shared aircraft details in Skirmish, Campaign Hangar and mission preparation. */
.gun-chart-list{grid-template-columns:minmax(0,1fr)}
.hangar-aircraft>div[id^="hangarStats"]>.hangar-stat-group:nth-child(3),.campaign-aircraft-stats>.hangar-stat-group:nth-child(3){grid-area:1/2}
.hangar-gun-charts{grid-area:2/2;min-width:0;margin-top:12px}
.hangar-gun-charts>h3{font:700 12px/1.3 system-ui;margin:0 0 8px}
.hangar-gun-charts .gun-chart h3{font:700 11px/1.3 system-ui;margin:0 0 6px}
.hangar-gun-charts .gun-chart-list{margin-top:0}
.hangar-gun-charts .gun-chart-key{font:10px/1.4 system-ui;margin:7px 0 0}
.pilot-roster-dialog:has(.hangar-grid){width:min(1320px,96vw);max-width:1320px}
@media(max-width:1100px){.hangar-aircraft>div[id^="hangarStats"]{display:grid}}
@media(max-width:800px){.hangar-aircraft>div[id^="hangarStats"]{display:block}}

.campaign-pilot-choice{border:1px solid #c5bca7;min-width:0}
.campaign-pilot-choice:has([aria-pressed=true]){background:#d8e5e1;border-color:#355b69}
.campaign-pilot-choice>button{width:100%;height:auto;border:0!important;background:transparent!important}
.campaign-dialog .campaign-pilot-choice .rookie-school{padding:0 10px 9px;font:12px/1.4 system-ui}
.rookie-school select{display:block;width:100%;margin-top:4px}
.replacement-choice{margin:16px 0;padding:12px;border:1px solid #c5bca7;text-align:left}
.replacement-choice h3{margin-top:0}

.aircraft-card-body .aircraft-details{display:flex;flex-direction:column;align-self:stretch}
.fuel-status{margin-top:auto;padding-top:8px;min-width:0;width:100%}
.fuel-label{display:flex;justify-content:space-between;gap:8px;font-variant-numeric:tabular-nums;margin-bottom:4px}
.fuel-track{height:8px;background:#d8d3c5;border-radius:2px;overflow:hidden;width:100%}
.fuel-fill{display:block;height:100%;background:#807247;transition:width .15s ease}
.fuel-empty .fuel-label{color:#b8392b}

.campaign-pilot-public{padding:10px;font:12px/1.4 system-ui}
.campaign-pilot-public strong,.campaign-pilot-public small{display:block}
.advanced-damage-card{--fuel-unit:clamp(.55px,.1vw,1.6px)}
.fuel-track{width:calc(var(--fuel-capacity)*var(--fuel-unit));max-width:100%}
@media(max-width:1100px){.advanced-damage-card{--fuel-unit:.55px}}

.campaign-option .option-criteria{font:600 11px/1.4 system-ui;margin-top:3px}

.damage-board.with-relative-position{grid-template-columns:minmax(0,1fr) 154px minmax(0,1fr)}
.relative-position{position:relative;display:flex;align-items:center;justify-content:center;background:transparent;border:0;min-width:0}
.relative-position .map-svg{width:100%;height:150px;display:block;transform:scale(1.025)}
.relative-position-toggle{margin-left:auto}
@media(max-width:1100px){.damage-board.with-relative-position{grid-template-columns:minmax(0,1fr) 120px minmax(0,1fr)}.relative-position .map-svg{height:120px}.with-relative-position .aircraft-card-body{grid-template-columns:1fr}.with-relative-position .aircraft-details{margin-top:5px}}

.relative-position .map-svg polygon{stroke:#45494b}

.relative-position .relative-grid-shadow polygon{fill:#45494b;stroke:#45494b}

/* Center the altitude columns; keep the difference label anchored as values grow. */
#altitudeStrip>span:first-child,#altitudeStrip>span:last-child,#lowerAltitudeStrip>span:first-child,#lowerAltitudeStrip>span:last-child{text-align:center}
#altitudeStrip .altitude-difference,#lowerAltitudeStrip .altitude-difference{justify-self:center;width:122px;justify-content:flex-start}
@media(max-width:1100px){#lowerAltitudeStrip .altitude-difference{width:100px}}
@media(max-width:520px){#altitudeStrip .altitude-difference{width:100px}}

/* The campaign ground strip occupies the unused right half of the cockpit header. */
.campaign-active #cockpits .pilot header:has(.ground-map){position:relative;min-height:72px}
.ground-map{position:absolute;left:55%;right:90px;top:5px;bottom:5px;display:flex;align-items:center;min-width:0}
.ground-map svg{width:100%;height:100%;overflow:visible;font:10px system-ui;fill:#343b3d}
.ground-map .ground-west{fill:#1e66a6;font-weight:700}.ground-map .ground-east{fill:#b8392b;font-weight:700}.ground-map .ground-position{font-weight:700}
@media(max-width:1100px){.campaign-active #cockpits .pilot header:has(.ground-map){min-height:122px}.ground-map{left:12px;right:12px;top:auto;height:56px;bottom:4px}}

/* Keep Basic data compact without reducing the relative-position grid. */
.damage-board.with-relative-position:has(>.damage-card){align-items:center}
.damage-board>.damage-card{min-width:0;align-content:start}
.damage-board>.damage-card progress{min-width:0;max-width:100%}

#advancedRulesNotice{width:min(460px,calc(100vw - 32px));padding:24px}#advancedRulesNotice h2{margin:0 0 12px}#advancedRulesNotice p{font:14px/1.5 system-ui;margin:0}
