/* Industry overview uses the same palette and fits the available page width. */
.nav-item[data-tab="overview"] span:not(.nav-arrow){white-space:normal;line-height:1.35}
.sectors-layout-active #controls .search-box,.sectors-layout-active #controls>select{display:none}
.sectors-layout-active #controls{justify-content:flex-end}
.sectors-layout-active #controls:before{content:"Từ ngành đến từng mã";margin-right:auto;color:var(--muted);font-size:12px}
#sectors-view{min-width:0;min-height:0}
.sector-layout{display:grid;grid-template-columns:minmax(0,1fr) 300px;gap:12px;min-width:0;min-height:0;height:100%}
.sector-market-panel{min-width:0;min-height:0;display:flex;flex-direction:column;overflow:hidden}
.sector-panel-heading{padding:13px 16px;display:flex;align-items:center;justify-content:space-between;gap:12px;border-bottom:1px solid var(--line)}
.sector-panel-heading h2{font-size:15px;line-height:1.4;margin:0 0 3px;font-weight:650}
.sector-panel-heading>div>span{font-size:11px;color:var(--muted)}
.sector-panel-heading b{font-size:13px;color:var(--accent);margin-left:3px}
.sector-panel-heading .count-badge{font-size:10px;white-space:nowrap}
.sector-table-scroll{overflow:auto;min-width:0;min-height:0;scrollbar-width:thin;scrollbar-gutter:stable;flex:1}
.sector-table{width:100%;min-width:0;max-width:100%;table-layout:fixed;border-collapse:collapse;font-size:12px;white-space:normal}
.sector-col-name{width:27%}.sector-col-score{width:14%}.sector-col-pressure{width:15%}.sector-col-net{width:15%}.sector-col-breadth{width:15%}.sector-col-leaders{width:14%}
.sector-table thead th{position:sticky;top:0;z-index:2;background:var(--soft);color:var(--muted);font-size:10px;line-height:1.35;text-align:right;white-space:normal;font-weight:550;border-bottom:1px solid var(--line);padding:9px 10px;height:40px;min-width:0;max-width:none}
.sector-table thead th:first-child{text-align:left;width:auto;min-width:0;padding-left:16px}
.sector-table tbody th,.sector-table td{position:static;padding:9px 10px;height:51px;min-width:0;text-align:right;border-bottom:1px solid var(--line);vertical-align:middle;overflow-wrap:anywhere}
.sector-table tbody th:first-child{text-align:left;width:auto;min-width:0;max-width:none;font-size:12px;font-weight:600;padding-left:12px}
.sector-table tbody th{background:inherit;color:var(--ink)}
.sector-table tbody tr{cursor:pointer;outline-offset:-3px}
.sector-table tbody tr:hover{background:var(--soft)}
.sector-table tbody tr.is-selected{background:var(--accent-soft)}
.sector-table tbody tr.is-selected th{box-shadow:inset 3px 0 var(--accent)}
.sector-table tbody tr:focus-visible{outline:2px solid var(--accent)}
.sector-table td small{display:block;font-weight:400;font-size:9px;line-height:1.45;color:var(--muted)}
.sector-name-cell{display:flex;align-items:center;gap:7px;line-height:1.3}
.sector-rank{flex:0 0 19px;text-align:center;color:var(--muted);font-size:10px;font-weight:500;font-variant-numeric:tabular-nums}
.sector-name-cell>span:last-child{min-width:0}
.sector-name-cell small{display:block;color:var(--muted);font-weight:400;font-size:9px;line-height:1.4;margin-top:3px}
.sector-score{font-size:15px;font-weight:650;line-height:1.1;white-space:nowrap}
.sector-score small{display:inline!important;font-size:8px!important;margin-left:2px}
.sector-score-track{height:3px;display:block;background:var(--line);border-radius:3px;margin-top:6px;width:58px;max-width:100%;margin-left:auto;overflow:hidden}
.sector-score-track i{height:100%;display:block;background:var(--muted)}
.sector-score-track i.up{background:var(--accent)}.sector-score-track i.down{background:var(--red)}
.sector-unranked{display:block;color:var(--muted);font-size:10px;font-weight:400;line-height:1.5}
.sector-pressure,.sector-net{font-weight:600;font-variant-numeric:tabular-nums}
.sector-breadth{font-weight:650}.sector-breadth>span{font-weight:400;color:var(--muted)}
.sector-leaders>span{font-weight:600;display:inline-block;font-size:10px;margin-left:3px}
.sector-table-footer{display:flex;justify-content:space-between;gap:12px;padding:9px 14px;font-size:9px;color:var(--muted);border-top:1px solid var(--line);line-height:1.5}
.sector-method{border-top:1px solid var(--line);padding:10px 14px;max-height:220px;overflow:auto;flex-shrink:0}
.sector-method summary{align-items:center;gap:8px}.sector-method summary span{font-size:10px;color:var(--muted);font-weight:500}.sector-method summary:after{font-size:15px}
.sector-method p{padding:0;font-size:11px;line-height:1.65;margin:10px 0}.sector-method strong{color:var(--ink);font-weight:600}
.sector-detail{min-height:0;min-width:0;display:flex;flex-direction:column;gap:9px;overflow:auto;scrollbar-width:thin;padding-right:2px}
.sector-detail-card{padding:12px 14px;flex-shrink:0;min-width:0;overflow:hidden}
.sector-detail-heading{display:flex;justify-content:space-between;align-items:center;gap:10px}
.sector-kicker{font-size:9px;color:var(--muted);letter-spacing:.8px;line-height:1.6}
.sector-detail-heading h2{font-size:20px;line-height:1.3;margin:3px 0 0;letter-spacing:-.4px;font-weight:650}
.sector-rank-pill{display:inline-flex;padding:7px 9px;border-radius:8px;background:var(--accent-soft);color:var(--accent);font-size:14px;font-weight:650;flex-shrink:0}
.sector-detail-quality{font-size:10px;color:var(--muted);margin-top:5px;line-height:1.4}
.sector-detail-breadth{display:flex;align-items:center;justify-content:space-between;gap:3px 8px;flex-wrap:wrap;font-size:10px;line-height:1.5;margin-top:8px}.sector-detail-breadth>span{color:var(--muted)}.sector-detail-breadth strong{font-weight:550}.sector-detail-breadth>small{flex:1 1 100%;font-size:9px;text-align:right;color:var(--muted)}
.sector-quality-detail{margin-top:7px}.sector-quality-detail summary{align-items:center;gap:6px}.sector-quality-detail summary span{font-size:9px;font-weight:400;color:var(--muted)}.sector-quality-detail summary:after{font-size:13px}.sector-quality-detail ul{padding:7px 0 0;margin:0;list-style:none;max-height:150px;overflow:auto}.sector-quality-detail li{display:flex;align-items:start;gap:8px;font-size:9px;line-height:1.5;margin:4px 0}.sector-quality-detail li strong{width:34px;flex-shrink:0;font-weight:600}.sector-quality-detail li span{color:var(--muted)}
.sector-total-pair{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:13px}
.sector-total-pair>div+div{padding-left:12px;border-left:1px solid var(--line)}
.sector-total-pair span{display:block;font-size:10px;color:var(--muted);margin-bottom:4px}
.sector-total-pair strong{font-size:20px;font-weight:600;line-height:1.3;white-space:nowrap}
.sector-total-pair small{font-size:10px;font-weight:400;color:var(--muted)}
.sector-open-button{width:100%;padding:9px 12px;border-radius:7px;background:var(--accent);color:var(--surface);font-size:11px;font-weight:600;display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:12px;text-align:left}
.sector-open-button:hover{filter:brightness(1.07)}.sector-open-button:focus-visible,.sector-frame-signals button:focus-visible,.sector-member-list button:focus-visible{outline:2px solid var(--accent);outline-offset:3px}
.sector-card-title{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:10px}
.sector-card-title h3{font-size:13px;font-weight:650;margin:0;line-height:1.4}.sector-card-title>span{font-size:10px;color:var(--muted)}
.sector-tier-head{display:grid;grid-template-columns:74px minmax(0,1fr) 62px;gap:7px;font-size:8px;color:var(--muted);margin-bottom:6px}
.sector-tier-head>span:last-child{text-align:right}.sector-tier-head>span:nth-child(2){white-space:nowrap}
.sector-tier-head i{display:inline-block;width:5px;height:5px;border-radius:50%;margin-right:2px}.sector-tier-head .buy-dot{background:var(--accent)}.sector-tier-head .sell-dot{background:var(--red);margin-left:5px}
.sector-tier{display:grid;grid-template-columns:74px minmax(0,1fr) 62px;align-items:center;gap:7px;min-height:23px;font-size:10px}
.sector-tier>span{color:var(--muted);white-space:nowrap}.sector-tier>strong{text-align:right;font-weight:550;font-variant-numeric:tabular-nums;font-size:10px}
.sector-tier-bars{display:flex;flex-direction:column;gap:3px;min-width:0;background:var(--soft);border-radius:2px}
.sector-tier-bars i{height:4px;display:block;min-width:0;border-radius:2px;opacity:.85}.sector-tier-buy{background:var(--accent)}.sector-tier-sell{background:var(--red)}
.sector-large-summary{display:flex;justify-content:space-between;gap:10px;border-top:1px solid var(--line);padding-top:9px;margin-top:8px;font-size:10px;line-height:1.5;align-items:center}
.sector-large-summary>span{color:var(--ink)}.sector-large-summary small{display:block;font-size:9px;color:var(--muted);font-weight:400}.sector-large-summary strong{font-size:14px;white-space:nowrap}.sector-large-summary strong small{display:inline}
.sector-frame-signals{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:5px}
.sector-frame-signals button{border:1px solid var(--line);border-radius:6px;padding:7px 3px;min-width:0;text-align:center}
.sector-frame-signals button.is-active{background:var(--accent-soft);border-color:var(--accent)}
.sector-frame-signals span{display:block;font-size:9px;color:var(--muted);margin-bottom:5px}.sector-frame-signals strong{display:block;font-size:10px;line-height:1.4;font-weight:600;overflow-wrap:anywhere}
.sector-frame-signals small{display:block;font-size:8px;color:var(--muted);margin-top:4px;line-height:1.4}
.sector-member-list button{width:100%;display:flex;align-items:center;gap:10px;padding:8px 0;border-top:1px solid var(--line);text-align:left}
.sector-member-list button:first-child{border-top:0;padding-top:0}.sector-member-list button>span:first-child{flex:1;min-width:0}.sector-member-list button>span:last-child{color:var(--muted);font-size:12px}
.sector-member-list strong{font-size:12px;font-weight:650}.sector-member-list small{display:block;font-size:9px;color:var(--muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:180px;margin-top:2px}.sector-member-list b{font-size:12px;font-weight:600}
.sector-concentration,.sector-no-members{font-size:10px;color:var(--muted);line-height:1.5;margin:7px 0 0}.sector-concentration{border-top:1px solid var(--line);padding-top:8px}.sector-concentration strong{font-weight:600;color:var(--ink)}
.sector-concentration-label{display:table;border:1px solid var(--line);border-radius:5px;padding:3px 6px;color:var(--gold);font-size:9px;font-weight:600;margin-bottom:5px}
.sector-state{padding:55px 24px;text-align:center;display:flex;flex-direction:column;align-items:center;justify-content:center;min-height:280px;flex:1}
.sector-state h2{font-size:20px;margin:9px 0;line-height:1.4}.sector-state p{font-size:12px;color:var(--muted);line-height:1.7;max-width:420px}.sector-state .sector-open-button{max-width:240px}
.sector-loading-dot{height:9px;width:9px;border-radius:50%;background:var(--accent);box-shadow:0 0 0 6px var(--accent-soft)}
.sector-sr-only{position:absolute!important;clip:rect(0,0,0,0);height:1px;width:1px;overflow:hidden;white-space:nowrap}
html[data-theme="dark"] .sector-open-button{color:#10271d}
@media(min-width:1100px) and (min-height:650px){#sectors-view{flex:1;display:flex;flex-direction:column}.sector-layout{flex:1}.sector-panel-heading,.sector-table-footer{flex-shrink:0}}
@media(min-width:1600px){.sector-layout{grid-template-columns:minmax(0,1fr) 330px;gap:14px}.sector-table tbody th:first-child,.sector-table{font-size:14px}.sector-table td,.sector-table tbody th{height:56px}.sector-table thead th{font-size:11px}.sector-score{font-size:17px}.sector-name-cell small,.sector-table td small{font-size:10px}.sector-leaders>span{font-size:12px}.sector-detail-card{padding:13px 16px}}
@media(max-width:1240px){.sector-layout{grid-template-columns:minmax(0,1fr) 270px;gap:10px}.sector-panel-heading{padding:11px 12px}.sector-table thead th,.sector-table td,.sector-table tbody th{padding-left:6px;padding-right:6px}.sector-table tbody th:first-child{padding-left:7px}.sector-name-cell{gap:4px}.sector-name-cell small{font-size:8px}.sector-rank{flex-basis:14px}.sector-table,.sector-table tbody th:first-child{font-size:11px}.sector-score{font-size:13px}.sector-table-footer{padding:8px 10px}.sector-table-footer>span:last-child{display:none}.sector-detail-card{padding:11px 12px}.sector-tier-head,.sector-tier{grid-template-columns:67px minmax(0,1fr) 56px;gap:6px}.sector-tier,.sector-tier>strong{font-size:9px}.sector-total-pair strong{font-size:18px}}
@media(max-width:1099px){.sector-layout{grid-template-columns:minmax(0,1fr);height:auto}.sector-table-scroll{max-height:640px}.sector-detail{overflow:visible;display:grid;grid-template-columns:1fr 1fr;align-items:start;padding:0}.sector-detail-card{padding:14px 16px}.sector-table,.sector-table tbody th:first-child{font-size:12px}.sector-name-cell small{font-size:9px}.sector-table td,.sector-table tbody th{height:53px}.sector-tier-head,.sector-tier{grid-template-columns:74px minmax(0,1fr) 62px;gap:7px}.sector-tier,.sector-tier>strong{font-size:10px}.sector-total-pair strong{font-size:21px}}
@media(max-width:640px){.sectors-layout-active #controls:before{display:none}.sectors-layout-active #controls{justify-content:initial}.sector-panel-heading{padding:12px}.sector-panel-heading h2{font-size:14px}.sector-panel-heading>div>span{font-size:9px}.sector-panel-heading .count-badge{font-size:8px;padding:6px}.sector-table-scroll{max-height:620px}.sector-table{min-width:0!important;font-size:11px}.sector-col-name{width:34%}.sector-col-score{width:18%}.sector-col-pressure{width:23%}.sector-col-net{width:25%}.sector-col-breadth,.sector-col-leaders{width:0}.sector-table th:nth-child(5),.sector-table td:nth-child(5),.sector-table th:nth-child(6),.sector-table td:nth-child(6){display:none}.sector-table thead th{font-size:9px;padding:8px 5px;line-height:1.5}.sector-table thead th:first-child{padding-left:10px}.sector-table tbody th:first-child{font-size:11px;padding-left:6px}.sector-name-cell{gap:3px}.sector-name-cell small{font-size:8px}.sector-rank{flex-basis:13px;font-size:9px}.sector-table td,.sector-table tbody th{padding:8px 5px;height:55px}.sector-score{font-size:13px}.sector-score small{font-size:7px!important}.sector-score-track{width:42px}.sector-unranked{font-size:9px}.sector-detail{display:flex;overflow:visible}.sector-detail-card{padding:15px 17px}.sector-table-footer{font-size:9px}.sector-method summary span{font-size:10px}.sector-state{padding:40px 20px}.sector-state h2{font-size:18px}}
@media(prefers-reduced-motion:reduce){.sector-layout *{scroll-behavior:auto!important}}
