#tank-tree:has(.radial-tree-content){inset:0;border:0;border-radius:0;background:#283039a6;padding:12px 18px;color:white;backdrop-filter:blur(1px)}
#tank-tree:has(.radial-tree-content) header{padding-bottom:6px}#tank-tree:has(.radial-tree-content) h2{font-size:18px}
#tree-content.radial-tree-content{max-height:none;gap:6px;align-items:center;overflow:hidden;min-height:0}
.radial-toolbar{display:flex;gap:8px;align-items:center;flex-shrink:0;flex-wrap:wrap;justify-content:center}.radial-toolbar span{font-size:12px}.radial-toolbar button,.radial-detail button{border:1px solid #a3cbd4;border-radius:6px;background:#eaf7fa;color:#254653;padding:7px 14px;cursor:pointer}.radial-toolbar button[aria-pressed=true]{background:#69d9ef;box-shadow:0 0 0 2px #fff8}
.radial-wheel{flex:1;min-height:0;width:100%;overflow:visible}.radial-node{cursor:pointer;outline:none}.radial-node path,.radial-node circle{stroke:#69756e;stroke-width:4;vector-effect:non-scaling-stroke;transition:filter .12s}.radial-node:hover path,.radial-node:focus path,.radial-node:hover circle,.radial-node:focus circle{filter:brightness(1.2);stroke:#fff;stroke-width:3}.radial-node.current path,.radial-node.current circle{stroke:#fff;stroke-width:4}.radial-node.selected path,.radial-node.selected circle{stroke:#ffcb43;stroke-width:4}
.radial-detail{display:flex;align-items:center;justify-content:center;gap:10px;flex-shrink:0;min-height:64px;background:#172934bb;border:1px solid #b9dbdf55;border-radius:8px;padding:0 12px;font-size:13px;max-width:95%}.radial-detail canvas{width:64px;height:58px;flex-shrink:0}.radial-detail button[hidden]{display:none}
@media(max-width:600px){.radial-toolbar span{width:100%;text-align:center}.radial-detail{font-size:11px}.radial-detail button{padding:6px}.radial-node path,.radial-node circle{stroke-width:2}}

#tree-content.fleet-tree-content{display:block;overflow:auto;padding:16px!important}
#tree-content .fleet-tree-hint{font-size:12px;line-height:1.6;margin-bottom:6px}
#tree-content .fleet-tree-live{position:sticky;top:0;z-index:2;background:#f5f2e9;border:1px solid #b7c8c0;padding:8px 12px;margin:0 0 12px;font-size:12px;color:#394e5f}
#tree-content .fleet-tree-start{display:flex;gap:16px;align-items:center;margin:12px 0}
#tree-content .fleet-tree-start .fleet-tree-node{flex:0 0 232px}
#tree-content .fleet-tree-start p{font-size:13px;line-height:1.7}
#tree-content .fleet-tree-headings,#tree-content .fleet-tree-row{display:grid;grid-template-columns:160px repeat(3,232px);gap:22px;min-width:922px;align-items:start}
#tree-content .fleet-tree-headings{padding:12px 0 8px;font-size:12px;border-bottom:1px solid #9eafa7}
#tree-content .fleet-tree-row{padding:12px 0;border-bottom:1px solid #b7c8c0}
#tree-content .fleet-tree-label{grid-column:auto;font-size:13px;align-self:start;padding-top:28px;display:block}
#tree-content .fleet-tree-label small{display:block;font-size:11px;line-height:1.6;margin-top:8px;font-weight:400}
#tree-content .fleet-tree-stage{display:flex;flex-direction:column;gap:12px;position:relative;min-width:0}
#tree-content .fleet-tree-stage:before{content:'→';position:absolute;left:-20px;top:80px;color:#597968;font-size:20px}
#tree-content .fleet-tree-branch{position:relative;min-width:0}
#tree-content .fleet-tree-parent{display:block;font-size:10px;line-height:1.5;min-height:20px;color:#526a5d}
#tree-content .fleet-tree-node{width:232px;min-height:194px;padding:6px;border:1px solid #9aafa3;background:#f5f2e9;border-radius:5px;font-size:12px;text-align:center;cursor:pointer}
#tree-content .fleet-tree-node canvas{width:220px;height:132px;margin:0 auto}
#tree-content .fleet-tree-node small{font-size:10px;line-height:1.5;margin-top:4px}
#tree-content .fleet-tree-node.current{border:2px solid #46795d;background:#deeadf}
#tree-content .fleet-tree-node.selected{outline:3px solid #bd8f33;outline-offset:-3px}
#tree-content .fleet-tree-node:focus-visible,#tree-content .fleet-tree-zoom:focus-visible{outline:3px solid #3a87b0;outline-offset:2px}
#tree-content .fleet-tree-state{font-weight:650;color:#394e5f}
#tree-content .fleet-tree-detail{display:flex;align-items:center;gap:16px;background:#e5ece5;border:1px solid #9aafa3;border-radius:5px;padding:10px;max-width:900px}
#tree-content .fleet-tree-detail>canvas{width:360px;height:256px;flex:0 0 360px;object-fit:contain}
#tree-content .fleet-tree-detail p{font-size:12px;line-height:1.7}
#tree-content .fleet-tree-detail strong{font-size:14px}
#tree-content .fleet-tree-zoom{border:1px solid #8eaaa0;background:#f5f2e9;color:#394e5f;border-radius:4px;padding:8px 12px;cursor:pointer;margin-right:8px}
#tree-content .fleet-tree-action{display:inline-block;margin:8px 0}
#tree-content .fleet-tree-branch.special .fleet-tree-node{border-style:dashed}
@media(max-width:650px){#tree-content .fleet-tree-detail{display:block;min-width:0}#tree-content .fleet-tree-detail>canvas{display:block;width:min(100%,360px);height:auto;margin:auto}#tree-content .fleet-tree-start{align-items:start}#tree-content .fleet-tree-start p{font-size:11px}#tree-content .fleet-tree-start .fleet-tree-node{flex-basis:232px}}
#tree-content .selected-tree-headings{display:grid;grid-template-columns:1fr 1fr 2fr;gap:18px;min-width:760px;margin:16px 0 8px;font-size:12px}
#tree-content .selected-tree-branch{display:grid;grid-template-columns:1fr 3fr;gap:18px;min-width:760px;padding:14px 0;border-top:1px solid #b7c8c0}
#tree-content .selected-tree-entry{align-self:center}
#tree-content .selected-tree-specialties{display:grid;gap:12px}
#tree-content .selected-tree-specialty{display:grid;grid-template-columns:1fr 2fr;gap:18px;align-items:center}
#tree-content .selected-tree-finals{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
#tree-content .selected-tree-branch .fleet-tree-node{width:100%}
@media(max-width:600px){#tree-content .selected-tree-headings{display:none}#tree-content .selected-tree-branch{min-width:0;grid-template-columns:minmax(0,1fr);gap:10px}#tree-content .selected-tree-entry{width:232px;margin:auto}#tree-content .selected-tree-specialty{grid-template-columns:minmax(0,1fr);gap:8px}#tree-content .selected-tree-specialty>.fleet-tree-node{width:232px;margin:auto}#tree-content .selected-tree-finals{grid-template-columns:232px;justify-content:center;gap:8px}}

/* CV original26 route: shared battle tokens; legacy and selected22 layouts remain separate. */
body #tank-tree:has(.cv-tree-content){inset:18px;background:var(--ui-surface);border:1px solid var(--ui-border);border-radius:4px;color:var(--ui-text);box-shadow:none;padding:12px}
body #tank-tree:has(.cv-tree-content)>header{padding-bottom:8px;border-color:var(--ui-divider)}
body #tank-tree:has(.cv-tree-content) h2{color:var(--ui-text);font-size:16px}
body #tank-tree:has(.cv-tree-content) #tree-close{background:var(--ui-recess);color:var(--ui-text);border-radius:4px}
#tree-content.fleet-tree-content.cv-tree-content{display:flex;flex-direction:column;gap:8px;min-height:0;padding:8px 0 0!important;overflow:hidden}
.cv-tree-toolbar{display:flex;align-items:center;justify-content:space-between;gap:8px;flex-shrink:0;font-size:11px;color:var(--ui-muted)}
.cv-tree-toolbar button,.cv-tree-selection button{border:1px solid var(--ui-line);border-radius:4px;padding:7px 10px;background:var(--ui-recess);color:var(--ui-text);font-size:12px}
.cv-tree-views{display:flex;gap:6px}.cv-tree-views button[aria-pressed=true]{border-color:var(--ui-accent);background:var(--ui-raised)}
.cv-tree-path{flex-shrink:0;font-size:11px;line-height:1.5;color:var(--ui-muted);overflow-wrap:anywhere}
.cv-tree-grid{display:block;min-height:0;overflow-y:auto;overflow-x:hidden;padding:2px;scrollbar-width:thin}
.cv-vessel{position:relative;display:flex;flex-direction:column;align-items:center;justify-content:center;min-width:0;min-height:128px;padding:3px;border:1px solid var(--ui-line);border-radius:4px;background:var(--ui-recess);color:var(--ui-text);text-shadow:none}
.cv-vessel canvas{display:block;width:220px;max-width:100%;height:92px;object-fit:contain}
.cv-vessel strong{max-width:100%;font-size:11px;line-height:1.4;font-weight:600;overflow-wrap:anywhere}
.cv-vessel small{font-size:10px;line-height:1.3;color:var(--ui-muted)}
.cv-vessel.current{border-color:var(--ui-text)}.cv-vessel.selected{outline:2px solid var(--ui-accent);outline-offset:-2px}.cv-vessel.available small{color:var(--ui-accent)}
.cv-vessel:focus-visible,.cv-tree-toolbar button:focus-visible,.cv-tree-selection button:focus-visible{outline:2px solid var(--ui-accent);outline-offset:-2px}
.cv-tree-selection{display:flex;align-items:center;justify-content:space-between;gap:10px;min-height:54px;flex-shrink:0;padding:8px 0 0;border-top:1px solid var(--ui-divider);font-size:12px}
.cv-tree-selection strong,.cv-tree-selection small{display:block;line-height:1.5}.cv-tree-selection small{color:var(--ui-muted);font-size:11px}.cv-tree-selection .fleet-tree-action{margin:0;flex-shrink:0;background:var(--ui-accent);color:var(--ui-recess)}
@media(max-width:800px){body #tank-tree:has(.cv-tree-content){padding:10px}}
@media(max-width:480px){.cv-tree-selection{align-items:center}.cv-tree-path{font-size:10px}}

/* Read the actual family/stage graph; large overviews scroll rather than shrinking vessels. */
body #tank-tree:has(.cv-route){inset:18px auto auto 18px;width:min(760px,calc(100vw - 36px));height:auto!important;max-height:calc(100dvh - 36px)}
#tree-content.cv-route{flex:0 1 auto}
.cv-route-children{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
.cv-tree-current{margin:0 0 8px}.cv-tree-current>.cv-vessel{display:flex;flex-direction:row;justify-content:flex-start;gap:12px;min-height:100px;width:100%;padding-right:12px}.cv-tree-current>.cv-vessel canvas{flex-shrink:0}.cv-tree-current>.cv-vessel small{margin-left:auto}
.cv-all-headings,.cv-family-row{display:grid;grid-template-columns:120px minmax(0,1fr) minmax(0,1fr) minmax(0,2fr);gap:8px}
.cv-all-headings{position:sticky;top:0;z-index:2;padding:6px 0;background:var(--ui-surface);font-size:11px;color:var(--ui-muted)}
.cv-family-row{padding:8px 0;border-top:1px solid var(--ui-divider);align-items:start}.cv-family-label{font-size:12px;padding:12px 4px;line-height:1.5;font-weight:650}.cv-family-stage{display:flex;flex-direction:column;gap:8px;min-width:0}.cv-family-stage>.cv-vessel{width:100%}.cv-family-stage.cv-stage-2{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}.cv-stage-label{display:none}
@media(max-width:900px){.cv-all-headings{display:none}.cv-family-row{grid-template-columns:minmax(0,1fr);gap:6px}.cv-family-label{padding:4px}.cv-family-stage{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.cv-stage-label{display:block;grid-column:1/-1;font-size:11px;color:var(--ui-muted)}.cv-family-stage.cv-stage-2>.cv-stage-label{grid-column:1/-1}}
@media(max-width:800px){body #tank-tree:has(.cv-route){inset:12px auto auto 12px!important;width:min(760px,calc(100vw - 24px))!important;max-height:calc(100dvh - 24px)}}
@media(max-width:480px){.cv-route-children{grid-template-columns:repeat(2,minmax(0,1fr))}.cv-tree-current>.cv-vessel{gap:6px}.cv-tree-current>.cv-vessel canvas{width:150px;height:63px}.cv-tree-current>.cv-vessel{min-height:72px}.cv-vessel canvas{width:150px;height:auto;aspect-ratio:55/23}.cv-tree-current>.cv-vessel small{font-size:9px}body #tank-tree:has(.cv-route){inset:12px auto auto 12px;width:calc(100vw - 24px);max-height:calc(100dvh - 24px)}}

/* DA: installed loadout is the comparison cue; availability remains separate. */
.cv-vessel .vessel-loadout{max-width:100%;padding:1px 7px;font-size:11px;line-height:1.4;color:var(--ui-text);white-space:normal;overflow-wrap:anywhere}
.cv-vessel.available .vessel-loadout{color:var(--ui-text)}
.cv-tree-selection>div{min-width:0}
.cv-tree-selection .vessel-difference{color:var(--ui-accent);font-variant-numeric:tabular-nums}
/* The breadcrumb already names the owner; leave the short viewport for actual choices. */
@media(max-height:480px){.cv-route .cv-tree-current{display:none}}
