/* v61 (Ren's playtest, Oct 28, 2026): card panel text never cut, full-width battle panel in portrait, upgrade picker rows */
html body .detail .dtxt{max-height:none!important;overflow:visible!important}
html body .detail.docked{height:auto!important}
html body .detail.docked .dhead{flex-wrap:wrap;row-gap:1px}
html body .detail.docked .dhead .dn{white-space:normal!important;overflow:visible!important;text-overflow:clip!important;overflow-wrap:anywhere}
/* portrait battle: the text gets the whole width (the small card copy is dropped), Back/Play stay on the right */
html body:not(.desk):not(.wide) #app.bt>.scr>.tray.staged>#detail.stage{grid-template-columns:minmax(0,1fr) auto!important}
html body:not(.desk):not(.wide) #app.bt #detail.stage>.stc{display:none!important}
html body:not(.desk):not(.wide) #app.bt #detail.stage>.dmain{align-self:stretch;justify-content:center;overflow:hidden}
html body:not(.desk):not(.wide) #app.bt #detail.stage .dtxt{font-size:15px;line-height:1.22}
/* upgrade picker */
#app .uplist{display:flex;flex-direction:column;gap:6px;margin:4px 0 8px}
#app .uprow{display:grid;grid-template-columns:24px minmax(0,1fr);grid-template-rows:auto auto;column-gap:8px;row-gap:1px;align-items:center;width:100%;min-height:50px;margin:0;padding:6px 10px;text-align:left;box-sizing:border-box;
 background:var(--paper,#e8d3a0) center/170px,#e8d3a0;color:#24150a;border:1px solid #3a2208;border-radius:3px;text-shadow:none;font:15px/1.2 'IM Fell English',Georgia,serif;box-shadow:0 2px 3px rgba(0,0,0,.35);cursor:pointer}
#app .uprow.on{outline:3px solid #e8c76a;outline-offset:-1px}
#app .uprow .cost{grid-row:1/3;position:static;width:24px;height:24px;display:flex;align-items:center;justify-content:center;border-radius:50%;font:bold 13px Georgia,serif;color:#2a1608;border:2px solid #3a2208;background:radial-gradient(circle at 35% 30%,#fff0b0,#d3a948 55%,#8a6420);box-sizing:border-box}
#app .uprow .upn{font:17px/1.1 'IM Fell English SC',serif;color:#24150a;overflow-wrap:anywhere}
#app .uprow .upn small{font:14px 'IM Fell English',Georgia,serif;color:#5a3d1c}
#app .uprow .upd{display:flex;flex-wrap:wrap;gap:0 10px;font-size:14px;color:#3a2a14}
#app .upch{white-space:nowrap}
#app .upch em,#app .upnote em{font-style:normal;font-weight:bold;color:#24150a;background:#e8c76a;border-radius:2px;padding:0 3px}
#app #upSlot{position:sticky;bottom:0;z-index:4}
#app .upcmp{margin:6px 0 0;padding:8px;background:#2a1a0e;border:1px solid #e8c76a;border-radius:4px;box-shadow:0 -4px 10px rgba(0,0,0,.5)}
#app .upcards{display:grid;grid-template-columns:minmax(0,1fr) 16px minmax(0,1fr);gap:4px;align-items:stretch}
#app .uparr{align-self:center;text-align:center;color:#e8c76a;font:bold 18px Georgia,serif}
#app .upc{background:var(--paper,#e8d3a0) center/170px,#e8d3a0;color:#24150a;border:1px solid #3a2208;border-radius:3px;padding:5px 7px 7px;min-width:0;display:flex;flex-direction:column;gap:3px}
#app .upc-new{outline:2px solid #e8c76a;outline-offset:-1px}
#app .upl{font:12px 'IM Fell English SC',serif;color:#6b4a22;letter-spacing:.04em}
#app .uphd{display:flex;align-items:center;gap:5px}
#app .uphd .cost{position:static;flex:none;width:22px;height:22px;display:flex;align-items:center;justify-content:center;border-radius:50%;font:bold 13px Georgia,serif;color:#2a1608;border:2px solid #3a2208;background:radial-gradient(circle at 35% 30%,#fff0b0,#d3a948 55%,#8a6420);box-sizing:border-box}
#app .uphd .cost.upnewc{outline:3px solid #e8c76a;background:radial-gradient(circle at 35% 30%,#fff7d0,#f0c84a 55%,#a07a20)}
#app .uphd .dn{font:15px/1.1 'IM Fell English SC',serif;overflow-wrap:anywhere;min-width:0}
#app .uptx{font:14px/1.25 'IM Fell English',Georgia,serif}
#app .uptx b.upnew{background:#e8c76a;color:#24150a;border-radius:2px;padding:0 2px}
#app .uptx b.upold{color:#6b4a22}
#app .upnote{margin:6px 2px 0;font:14px/1.25 'IM Fell English',Georgia,serif;color:#f3e6c4}
#app .upbtns{display:flex;gap:8px;margin-top:8px}
#app .upbtns button{flex:1 1 0;min-height:44px;margin:0}
#app .upbtns #upGo{flex:2 1 0}
@media (max-height:420px){html body.wide #app.bt #detail:not(.empty) .dside>button{min-height:36px!important}}
html body.wide #app.bt #detail:not(.empty) .dhead{flex-wrap:wrap;row-gap:0}
html body.wide #app.bt #detail:not(.empty) .dhead .dn{white-space:normal!important;overflow:visible!important;text-overflow:clip!important;min-width:0;flex:0 1 auto}
/* v62: captain select on phones, every text at least 12px (names, card-count chips, doctrine ranks) */
html body #app .capscr .caps button b{font-size:12px!important;line-height:1.05!important;white-space:normal!important;overflow-wrap:normal;word-break:normal;text-align:center;letter-spacing:-.01em}
html body #app .capscr .chip i{font-size:12px!important;min-width:1.25em;line-height:1.25em;height:auto!important}
html body #app .capscr button.doc small{font-size:12px!important}
html body #app .capscr .caps button{padding-left:2px!important;padding-right:2px!important;min-width:0}
@media (max-width:420px){html body:not(.wide):not(.desk) #app .capscr .caps{grid-template-columns:repeat(5,minmax(min-content,1fr))!important;gap:0 1px!important;padding-left:2px!important;padding-right:2px!important}}
/* v62: run-end stat labels at least 12px */
html body #app .endscr .stats small{font-size:12px!important}
