/* v0.6.1: restrained usability refinements over the approved v0.6.0. */
:where(a,button,select):focus-visible{outline:2px solid #16866e;outline-offset:3px}
.trader-name{border:0;background:transparent;padding:0;font:inherit;font-weight:700;cursor:pointer}
.detail-close-bar{position:sticky;top:0;height:0;z-index:5}.detail-close-bar .detail-close{top:-20px;right:-20px;width:40px;height:40px;box-shadow:0 2px 12px #20382f12}.agent-page #portfolio-dialog>.detail-close-bar{display:none}
.chart-readout{font-variant-numeric:tabular-nums}.chart-readout>span{white-space:nowrap}
.chart-legend .legend-return{display:none}.chart-panel .chart-heading{flex-wrap:wrap;gap:7px}.chart-panel .chart-heading>span{line-height:1.6}
.trader-shortcut,.positions-heading,.chat-message>div{min-width:0}
.account-positions .holding-price{color:#5c7567}.trade-reason{color:#61766b}.trade-sample-note{color:#697c6f}
@media(max-width:800px){
 .workspace-topbar{min-height:60px;height:auto;flex-wrap:wrap;padding-block:10px;gap:8px 12px}.workspace-topbar>a:last-child{min-height:36px;display:flex;align-items:center}
 .dashboard-sidebar>a:not(.brand){min-height:40px;display:inline-flex;align-items:center}
 .periods button,.account-ranges button{min-height:40px;min-width:44px}.detail-close-bar .detail-close{width:44px;height:44px;top:-12px;right:-10px}
 .account-identity{padding-right:35px}.detail-dialog .account-identity h2{font-size:20px}.account-identity .eyebrow{line-height:1.6}
 .portrait-about,.portrait-open span{min-height:40px;display:flex;align-items:center;justify-content:center}
 .zoo-chat .message-meta button{min-height:28px}.zoo-chat .message-meta time{font-size:10px}.zoo-chat .chat-preview-note{font-size:11px}
 .trade-reason{font-size:12px}.compact-trade p{font-size:12px!important}
 .shortcut-identity small{font-size:10px}.shortcut-value b{font-size:13px}.shortcut-value small{font-size:11px}
 .chart-legend{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px 16px;text-align:left}.chart-legend>span{display:flex;align-items:center;gap:6px;font-size:12px}.chart-legend .legend-return{display:inline;margin-left:auto;font-size:12px;font-weight:600;color:var(--series-color)}
 #portfolio-chart .chart-return,#portfolio-chart .return-heading{display:none}#portfolio-chart{min-height:0;aspect-ratio:2/1}.chart-readout{min-height:80px;font-size:11px}.chart-readout>strong{font-size:12px}
 .account-positions li button{gap:10px}.account-positions small{font-size:11px}.account-positions .holding-price{font-size:10px}.account-facts>div{font-size:12px}
}
@media(max-width:360px){.category-allocation{grid-template-columns:1fr!important}.category-allocation svg{max-width:150px;margin:auto}.position-value{max-width:105px}.positions-heading{flex-wrap:wrap}}
@media(prefers-reduced-motion:reduce){html{scroll-behavior:auto!important}*,*::before,*::after{animation-duration:.01ms!important;transition-duration:.01ms!important}}

/* Keep actions clear of scrolling content and compact cards aligned. */
.detail-close-bar{height:36px;margin-top:-20px;margin-bottom:8px;background:#fff}.detail-close-bar .detail-close{top:0;right:-20px}
@media(max-width:800px){.detail-close-bar{height:44px;margin-top:-12px;margin-bottom:6px}.detail-close-bar .detail-close{top:0;right:-10px}}
@media(max-width:480px){.trader-shortcut{display:grid;grid-template-columns:29px minmax(0,1fr);align-content:start;gap:8px;min-height:116px}.shortcut-identity{min-width:0}.shortcut-identity small{font-size:10px;line-height:1.5}.trader-shortcut .shortcut-value{grid-column:1/-1;margin-top:auto;align-self:end}.trader-shortcut img{align-self:start}.trader-shortcut .shortcut-value small span{display:none}}
