:root{
  color-scheme:dark;
  --bg:#06111f;--bg2:#081524;--panel:#0b1727;--panel2:#0e1c2d;--panel3:#101f31;
  --border:#203247;--border2:#2b4058;--text:#f5f8fc;--muted:#8fa2b8;--muted2:#6f849b;
  --green:#38e878;--green2:#15b95d;--red:#ff5361;--purple:#b76cff;--purple2:#793dd5;
  --orange:#ff9f17;--blue:#42a5ff;--cyan:#36d0ff;--shadow:0 18px 50px rgba(0,0,0,.24);
  --sidebar:252px;
}
*{box-sizing:border-box}html{min-height:100%;background:var(--bg)}body{min-width:320px;min-height:100vh;margin:0;background:radial-gradient(circle at 74% -20%,#112b45 0,transparent 35%),linear-gradient(180deg,#06111f 0,#081420 100%);color:var(--text);font-family:Inter,ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif;-webkit-font-smoothing:antialiased}button,input,select{font:inherit}button,a{-webkit-tap-highlight-color:transparent}button{cursor:pointer}.boot{padding:90px 24px;text-align:center;color:var(--muted)}.wrap{width:min(1480px,calc(100% - 48px));margin:0 auto}.positive{color:var(--green)!important}.negative{color:var(--red)!important}.muted{color:var(--muted)}.num{text-align:right;font-variant-numeric:tabular-nums}.center{text-align:center}
.side-nav{position:fixed;z-index:40;left:0;top:0;bottom:0;width:var(--sidebar);display:flex;flex-direction:column;padding:22px 14px 18px;border-right:1px solid #17283a;background:linear-gradient(180deg,#06101d 0,#071421 100%);box-shadow:18px 0 45px rgba(0,0,0,.12)}
.brand{display:flex;align-items:center;gap:13px;padding:4px 8px 26px;color:#fff;text-decoration:none}.brand-mark{position:relative;width:42px;height:42px;display:flex;align-items:flex-end;gap:3px}.brand-mark i{display:block;width:8px;border-radius:2px 2px 0 0;background:linear-gradient(180deg,#55f78a,#19c55f)}.brand-mark i:nth-child(1){height:18px}.brand-mark i:nth-child(2){height:27px}.brand-mark i:nth-child(3){height:36px}.brand-mark b{position:absolute;right:-4px;top:-5px;color:var(--green);font-size:25px}.brand strong{display:block;font-size:22px;letter-spacing:-.03em}.brand small{display:block;margin-top:2px;color:#c3cfdd;font-size:13px}.side-links{display:grid;gap:7px}.side-links a{display:flex;align-items:center;gap:12px;padding:12px 13px;border:1px solid transparent;border-radius:10px;color:#c5d0dd;text-decoration:none;font-weight:650;font-size:14px}.side-links a:hover{background:#0d1d2e}.side-links a.active{border-color:#23553f;background:linear-gradient(90deg,rgba(36,202,104,.13),rgba(32,145,89,.08));color:#fff}.nav-ico{width:24px;color:#8fa6bf;font-size:20px;text-align:center}.side-links a.active .nav-ico{color:var(--green)}
.side-live{margin-top:28px;padding:16px;border:1px solid #46236b;border-radius:12px;background:linear-gradient(145deg,rgba(116,43,174,.24),rgba(34,18,63,.38));box-shadow:inset 0 0 32px rgba(130,57,214,.08)}.side-live-title{display:flex;justify-content:space-between;color:#cf8cff;font-weight:800}.side-live-title span{color:var(--orange)}.side-live p{margin:11px 0 7px;color:#aab7c7;font-size:12px}.side-live b{display:flex;align-items:center;gap:7px;color:var(--green);font-size:12px}.side-live b i,.market-status .dot{width:7px;height:7px;border-radius:50%;background:currentColor;box-shadow:0 0 10px currentColor}.side-foot{margin-top:auto;display:grid;gap:6px;padding:15px;border:1px solid #1b3147;border-radius:12px;background:#091725}.side-foot small{color:var(--muted);font-size:11px}.side-foot strong{font-size:12px}.market-badge{width:max-content;margin-top:6px;padding:4px 8px;border-radius:7px;background:#0c3a27;color:var(--green);font-size:10px;font-weight:800}
.header,main{margin-left:var(--sidebar)}.header{padding-top:18px}.header-inner{padding:0}.topbar{display:flex;align-items:center;justify-content:space-between;min-height:44px;gap:16px}.mobile-brand{display:none}.market-status{display:inline-flex;align-items:center;gap:9px;border:1px solid #174b32;border-radius:999px;padding:7px 13px;background:#092b1e;color:var(--green);font-size:11px;font-weight:800;letter-spacing:.02em}.top-actions{display:flex;align-items:center;gap:15px}.refresh-caption{color:var(--muted);font-size:12px}.refresh-caption b{display:inline-block;min-width:52px;margin-left:5px;color:var(--green);font-variant-numeric:tabular-nums}.refresh-btn{height:40px;display:flex;align-items:center;gap:9px;padding:0 18px;border:1px solid #2a3e55;border-radius:12px;background:#111e2e;color:#fff;font-weight:750}.refresh-btn:hover{border-color:#47617c;background:#15263a}.refresh-btn:disabled{opacity:.55;cursor:wait}.refresh-icon{font-size:19px}
.meta-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));margin-top:14px;border:1px solid var(--border);border-radius:13px;background:linear-gradient(180deg,#0b1726,#091523);overflow:hidden;box-shadow:var(--shadow)}.meta-item{position:relative;display:flex;align-items:center;gap:13px;min-height:96px;padding:17px 20px}.meta-item:not(:last-child):after{content:"";position:absolute;right:0;top:23%;bottom:23%;width:1px;background:#25374a}.meta-icon{display:grid;place-items:center;width:38px;height:38px;border-radius:10px;font-size:24px;font-weight:800;background:#121f30}.meta-item.purple .meta-icon{color:var(--purple)}.meta-item.blue .meta-icon{color:var(--blue)}.meta-item.orange .meta-icon{color:var(--orange)}.meta-item.green .meta-icon{color:var(--green)}.meta-label{margin:0;color:#aab8c8;font-size:10px;text-transform:uppercase;letter-spacing:.055em}.meta-value{margin:6px 0 0;color:#fff;font-size:15px;font-weight:750;font-variant-numeric:tabular-nums}.error-banner{margin-top:12px;border:1px solid #783039;border-radius:10px;padding:10px 12px;background:#2b1018;color:#ff7c86;font-size:12px;font-weight:700}
main{padding-top:16px!important;padding-bottom:44px!important}.panel{border:1px solid var(--border);border-radius:13px;background:linear-gradient(180deg,#0b1828,#091624);box-shadow:var(--shadow)}.overview-main{padding-top:16px!important}.kpis{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}.kpi{position:relative;min-height:132px;padding:18px;border:1px solid var(--border2);border-radius:13px;background:linear-gradient(135deg,#111d30,#0b1725);color:#fff;text-decoration:none;overflow:hidden;transition:.18s ease}.kpi:hover{translate:0 -2px;box-shadow:0 16px 35px rgba(0,0,0,.23)}.kpi:after{content:"";position:absolute;inset:auto -30px -60px auto;width:150px;height:150px;border-radius:50%;filter:blur(18px);opacity:.09;background:currentColor}.kpi-top{display:flex;justify-content:space-between;align-items:center}.kpi small{color:#c6d0dd;font-size:11px;font-weight:800;text-transform:uppercase}.kpi-top i{color:#869bb2;font-style:normal;font-size:12px}.kpi-main{display:flex;align-items:flex-end;justify-content:space-between;gap:12px;margin-top:14px}.kpi strong{font-size:29px;line-height:1;font-variant-numeric:tabular-nums}.kpi-note{display:block;margin-top:12px;font-size:11px;color:#9fb0c1}.kpi-early{border-color:#4b2d71;color:var(--purple);background:linear-gradient(135deg,#16132c,#0c1726)}.kpi-sig4{border-color:#5d2831;color:var(--red);background:linear-gradient(135deg,#26141b,#0c1724)}.kpi-sig3{border-color:#5c421c;color:var(--orange);background:linear-gradient(135deg,#241a0f,#0c1724)}.kpi-sig2{border-color:#195238;color:var(--green);background:linear-gradient(135deg,#10281c,#0b1825)}.spark{display:flex;align-items:flex-end;gap:3px;width:78px;height:34px}.spark i{display:block;width:12px;border:2px solid currentColor;border-width:2px 0 0 0;transform:skewY(-20deg);opacity:.9}.spark i:nth-child(1){height:10px}.spark i:nth-child(2){height:18px}.spark i:nth-child(3){height:13px}.spark i:nth-child(4){height:27px}.spark i:nth-child(5){height:22px}
.group-section{margin-top:13px;padding:14px;border:1px solid var(--border);border-radius:13px;background:linear-gradient(180deg,rgba(12,25,41,.96),rgba(8,20,34,.96));box-shadow:var(--shadow)}.group-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}.group-head h2{margin:0;color:#f7f9fc;font-size:15px}.group-head h2 .section-icon{margin-right:7px;color:var(--purple)}.group-head p{margin:5px 0 0;color:var(--muted);font-size:11px}.group-head a{padding:8px 11px;border:1px solid #2b3f55;border-radius:9px;color:#dce5ef;text-decoration:none;font-size:11px;font-weight:700}.count-badge{display:inline-flex;margin-left:7px;padding:3px 7px;border-radius:999px;background:#25183b;color:#c58cff;font-size:10px;vertical-align:middle}.group-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}.stock-card{position:relative;min-width:0;padding:14px;border:1px solid #293b51;border-radius:11px;background:linear-gradient(145deg,#0f1c2d,#0b1725);cursor:pointer;overflow:hidden;transition:.18s ease}.stock-card:hover{translate:0 -2px;border-color:#405a75;box-shadow:0 14px 30px rgba(0,0,0,.22)}.stock-card.early-card{box-shadow:inset 0 0 30px rgba(139,69,210,.04)}.stock-card.tone4{border-color:#64303a;background:linear-gradient(145deg,#24131c,#0b1725)}.stock-card.tone3{border-color:#22516b;background:linear-gradient(145deg,#102534,#0b1725)}.stock-card.tone2{border-color:#654a21;background:linear-gradient(145deg,#251c10,#0b1725)}.stock-top{display:flex;align-items:flex-start;justify-content:space-between;gap:8px}.stock-name{display:flex;align-items:center;gap:7px}.stock-name b{font-size:17px}.stock-exchange{padding:3px 6px;border:1px solid #34475d;border-radius:6px;background:#122133;color:#aebdcb;font-size:9px}.stock-price{margin:8px 0 0;font-size:15px;font-weight:700}.stock-price span{margin-left:5px}.stock-ma10{margin:5px 0 0;color:#8fa1b6;font-size:10px}.signal-pill{display:inline-grid;place-items:center;min-width:37px;padding:4px 8px;border-radius:7px;font-size:10px;font-weight:900}.sig4{background:#54206a;color:#e5adff}.sig3{background:#1f4d89;color:#80b9ff}.sig2{background:#5e3f0d;color:#ffc057}.sig1{background:#173851;color:#68c8ff}.sig0{background:#1c2b3a;color:#8296aa}.stock-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;margin-top:14px}.stock-grid small{display:block;color:#8295aa;font-size:9px;text-transform:uppercase}.stock-grid b{display:block;margin-top:5px;font-size:12px;font-variant-numeric:tabular-nums}.early-text{color:var(--purple)}.signal-tags{display:flex;gap:5px;overflow:hidden;margin-top:12px}.signal-tag{flex:0 0 auto;padding:3px 6px;border:1px solid #304258;border-radius:6px;background:#111e2e;color:#afbdcb;font-size:8px;font-weight:700}.signal-tag.missed{opacity:.38;text-decoration:line-through}.signal-tag.passed{color:#eef4fa}.missing-note{margin:9px 0 0;color:#ff8e96;font-size:10px}.empty{padding:38px 16px;border:1px dashed #2a4058;border-radius:11px;color:var(--muted);text-align:center;background:#091522}.group-dot{display:inline-block;width:8px;height:8px;margin-right:7px;border-radius:50%;background:currentColor}.group4 .group-head h2{color:#ff7b85}.group3 .group-head h2{color:#ffb04d}.group2 .group-head h2{color:#ffd068}.group1 .group-head h2{color:#70c8ff}
.filters{padding:14px}.search-row{display:grid;grid-template-columns:minmax(0,1fr) auto auto;gap:8px}.search-box{position:relative}.search-icon{position:absolute;left:13px;top:50%;translate:0 -50%;color:#7f93aa;pointer-events:none}#stock-search{width:100%;height:42px;border:1px solid #2c4158;border-radius:9px;padding:0 12px 0 38px;background:#091523;color:#f7f9fb;outline:none;font-size:14px}#stock-search:focus{border-color:#47749b;box-shadow:0 0 0 3px rgba(66,165,255,.08)}.search-btn,.clear-btn{height:42px;padding:0 15px;border:1px solid #2d435a;border-radius:9px;background:#122236;color:#e9f0f7;font-weight:700}.search-btn{border-color:#2f65a2;background:#163d68}.clear-btn{color:#9fb0c0}.filter-block{margin-top:13px}.filter-label{margin:0 0 7px;color:#8294a8;font-size:9px;text-transform:uppercase;letter-spacing:.06em}.chips{display:flex;flex-wrap:wrap;gap:6px}.chip{min-height:30px;padding:5px 10px;border:1px solid #2a3e54;border-radius:8px;background:#0e1c2c;color:#aebdca;font-size:10px;font-weight:700}.chip:hover{border-color:#43617f}.chip.active{border-color:#346a9e;background:#153d64;color:#fff}.result-info{margin:12px 2px 9px;color:#8498ae;font-size:11px}.result-info strong{color:#e9eff6}.desktop-table{overflow:hidden}.table-shell{overflow:auto;max-height:68vh}table{width:100%;border-collapse:collapse;font-size:12px}th,td{padding:11px 9px;border-bottom:1px solid #172a3d;white-space:nowrap}th{position:sticky;top:0;z-index:2;background:#0e1c2c;color:#879bb0;font-size:9px;text-transform:uppercase;letter-spacing:.035em}tbody tr{cursor:pointer}tbody tr:hover{background:#0f2032}.symbol{color:#49adff;font-weight:850}.mobile-list{display:none;gap:10px}.pager{display:flex;justify-content:center;align-items:center;gap:9px;margin-top:14px}.pager button{height:36px;padding:0 12px;border:1px solid #2b4057;border-radius:8px;background:#0e1b2a;color:#dce5ef;font-weight:700}.pager button:disabled{opacity:.35}.pager span{color:#8fa1b4;font-size:11px}.disclaimer{margin:20px 0 0;color:#61778f;font-size:10px;text-align:center}
.dialog-backdrop{position:fixed;inset:0;z-index:100;display:grid;place-items:center;padding:18px;background:rgba(2,8,15,.78);backdrop-filter:blur(6px)}.dialog-backdrop[hidden]{display:none}.dialog{width:min(720px,100%);max-height:88vh;overflow:auto;border:1px solid #30465f;border-radius:14px;background:#081522;box-shadow:0 24px 80px rgba(0,0,0,.5)}.dialog-head{position:sticky;top:0;z-index:2;display:flex;justify-content:space-between;align-items:center;padding:16px 18px;border-bottom:1px solid #20364b;background:#0c1928}.dialog-head h2{margin:0;font-size:19px}.dialog-close{width:36px;height:36px;border:1px solid #2a4057;border-radius:9px;background:#122235;color:#fff;font-size:22px}.dialog-body{padding:16px}.detail-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:9px}.detail{padding:11px;border:1px solid #22374d;border-radius:10px;background:#0d1b2b}.detail small{display:block;color:#7f93a8;font-size:9px}.detail b{display:block;margin-top:6px;font-size:12px}.mobile-bottom{display:none}
@media(max-width:1180px){:root{--sidebar:210px}.group-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.meta-item{padding-inline:14px}.wrap{width:min(100% - 28px,1320px)}}
@media(max-width:900px){.side-nav{display:none}.header,main{margin-left:0}.header{padding-top:12px}.wrap{width:calc(100% - 24px)}.market-status{display:none}.mobile-brand{display:flex;align-items:center;gap:10px}.mobile-brand-mark{display:grid;place-items:center;width:35px;height:35px;border-radius:9px;background:#123b27;color:var(--green);font-size:23px;font-weight:900}.mobile-brand strong{display:block;font-size:17px}.mobile-brand small{display:block;color:#95a6b9;font-size:10px}.meta-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.meta-item:nth-child(2):after{display:none}.meta-item{min-height:82px}.kpis{grid-template-columns:repeat(2,minmax(0,1fr))}.group-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.detail-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:620px){body{padding-bottom:82px;background:linear-gradient(180deg,#06111f,#081421)}.header{padding-top:8px}.wrap{width:calc(100% - 20px)}.topbar{min-height:52px}.refresh-caption{display:none}.refresh-btn{height:38px;padding:0 13px}.meta-grid{margin-top:8px;grid-template-columns:repeat(2,minmax(0,1fr));border-radius:12px}.meta-item{min-height:72px;padding:10px 11px;gap:8px}.meta-item:after{display:none!important}.meta-icon{width:28px;height:28px;font-size:17px}.meta-label{font-size:8px}.meta-value{margin-top:4px;font-size:11px;white-space:normal}.overview-main{padding-top:10px!important}.kpis{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.kpi{min-height:127px;padding:13px}.kpi small{font-size:9px}.kpi strong{font-size:29px}.kpi-note{font-size:9px}.spark{width:53px;height:27px}.group-section{margin-top:10px;padding:10px}.group-head{align-items:flex-start}.group-head h2{font-size:13px}.group-head p{font-size:9px;line-height:1.45}.group-head a{padding:6px 8px;font-size:9px}.group-grid{display:flex;overflow-x:auto;gap:8px;padding-bottom:5px;scroll-snap-type:x proximity;scrollbar-width:none}.group-grid::-webkit-scrollbar{display:none}.stock-card{flex:0 0 76vw;max-width:300px;scroll-snap-align:start;padding:12px}.stock-name b{font-size:16px}.stock-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}.signal-tags{max-width:100%;overflow-x:auto;scrollbar-width:none}.filters{padding:10px}.search-row{grid-template-columns:minmax(0,1fr) auto}.clear-btn{grid-column:1/-1}.chips{flex-wrap:nowrap;overflow-x:auto;padding-bottom:4px;scrollbar-width:none}.chip{flex:0 0 auto}.desktop-table{display:none}.mobile-list{display:grid}.result-info{margin-top:9px}.pager{margin-bottom:6px}.detail-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.dialog-body{padding:12px}.mobile-bottom{position:fixed;z-index:60;left:0;right:0;bottom:0;display:grid;grid-template-columns:repeat(4,1fr);padding:8px 8px max(8px,env(safe-area-inset-bottom));border-top:1px solid #1b3044;background:rgba(6,17,31,.96);backdrop-filter:blur(18px);box-shadow:0 -14px 35px rgba(0,0,0,.32)}.mobile-bottom a,.mobile-bottom button{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;min-height:50px;border:0;background:transparent;color:#8fa2b8;text-decoration:none}.mobile-bottom span{font-size:21px}.mobile-bottom small{font-size:9px}.mobile-bottom .active{color:var(--green)}.mobile-bottom button{color:#c58cff}.mobile-bottom button span{display:grid;place-items:center;width:43px;height:43px;margin-top:-25px;border:1px solid #3d3159;border-radius:15px;background:linear-gradient(145deg,#251d3f,#101c2d);box-shadow:0 0 25px rgba(170,91,255,.18)}.mobile-bottom button small{margin-top:-2px}.side-nav{display:none}}
@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important;transition:none!important}}


/* ============================================================
   v17.1 — layout hotfix + Light/Dark theme
   ============================================================ */
html,body{max-width:100%;overflow-x:hidden}
.header{width:calc(100% - var(--sidebar));margin-left:var(--sidebar)}
.header .wrap{width:min(1480px,calc(100% - 48px));margin-left:auto;margin-right:auto}
main.wrap{width:auto;max-width:1480px;margin-left:calc(var(--sidebar) + 24px);margin-right:24px}
.theme-toggle{height:40px;display:flex;align-items:center;gap:7px;padding:0 12px;border:1px solid #2a3e55;border-radius:12px;background:#0c1a2a;color:#dbe5ef;font-weight:750}
.theme-toggle:hover{border-color:#47617c;background:#12253a}.theme-icon{font-size:17px}.theme-label{font-size:11px}
.group-section{min-width:0;overflow:hidden}.group-grid{min-width:0}.stock-card{max-width:100%}

@media(min-width:1760px){main.wrap{margin-left:calc(var(--sidebar) + (100vw - var(--sidebar) - 1480px)/2);margin-right:auto}}
@media(max-width:1180px) and (min-width:901px){main.wrap{margin-left:calc(var(--sidebar) + 14px);margin-right:14px;max-width:none}.header .wrap{width:calc(100% - 28px)}}
@media(max-width:900px){.header{width:auto;margin-left:0}.header .wrap{width:calc(100% - 24px)}main.wrap{width:auto;max-width:none;margin-left:12px;margin-right:12px}.theme-label{display:none}.theme-toggle{width:40px;padding:0;justify-content:center}}
@media(max-width:620px){
  main.wrap{margin-left:10px;margin-right:10px;padding-bottom:108px!important}
  .header .wrap{width:calc(100% - 20px)}
  .top-actions{gap:7px}.theme-toggle{height:38px;width:38px;border-radius:10px}.refresh-btn{gap:6px}
  .group-section{width:100%}.group-grid{width:100%;max-width:100%;overscroll-behavior-x:contain}
  .stock-card{flex:0 0 calc(100vw - 64px);max-width:330px}
  .stock-grid{column-gap:12px;row-gap:10px}.signal-tags{padding-bottom:2px}
  .mobile-bottom{padding-bottom:max(8px,env(safe-area-inset-bottom))}
}

/* Light theme */
html[data-theme="light"]{color-scheme:light;--bg:#eef3f8;--bg2:#f7f9fc;--panel:#ffffff;--panel2:#f8fafc;--panel3:#f2f6fa;--border:#d8e1ea;--border2:#cbd7e3;--text:#152235;--muted:#65758a;--muted2:#8190a3;--shadow:0 14px 38px rgba(20,42,68,.10)}
html[data-theme="light"] body{background:radial-gradient(circle at 75% -15%,#d9ecff 0,transparent 32%),linear-gradient(180deg,#f7f9fc,#edf3f8);color:var(--text)}
html[data-theme="light"] .side-nav{border-right-color:#dbe4ed;background:linear-gradient(180deg,#ffffff,#f4f7fa);box-shadow:16px 0 35px rgba(44,66,91,.06)}
html[data-theme="light"] .brand{color:#142235}html[data-theme="light"] .brand small{color:#6f8094}
html[data-theme="light"] .side-links a{color:#53657b}html[data-theme="light"] .side-links a:hover{background:#edf3f8}html[data-theme="light"] .side-links a.active{border-color:#a9dfbf;background:linear-gradient(90deg,#e6f8ed,#f3fbf6);color:#183527}
html[data-theme="light"] .side-live{border-color:#ddc9ef;background:linear-gradient(145deg,#f7efff,#f3f0fa);box-shadow:none}html[data-theme="light"] .side-live p{color:#6c7585}
html[data-theme="light"] .side-foot{border-color:#d9e3ed;background:#f7fafc}html[data-theme="light"] .market-badge{background:#dff5e7;color:#128247}
html[data-theme="light"] .market-status{border-color:#b8e4c8;background:#e9f9ef;color:#16894b}
html[data-theme="light"] .refresh-btn,html[data-theme="light"] .theme-toggle{border-color:#d1dce7;background:#fff;color:#203148;box-shadow:0 4px 12px rgba(35,58,83,.05)}
html[data-theme="light"] .refresh-btn:hover,html[data-theme="light"] .theme-toggle:hover{border-color:#aebfd0;background:#f7fafc}
html[data-theme="light"] .meta-grid,html[data-theme="light"] .panel,html[data-theme="light"] .group-section{border-color:#d9e3ed;background:linear-gradient(180deg,#ffffff,#f8fafc);box-shadow:var(--shadow)}
html[data-theme="light"] .meta-item:not(:last-child):after{background:#dbe4ed}html[data-theme="light"] .meta-icon{background:#eef3f8}html[data-theme="light"] .meta-label{color:#708096}html[data-theme="light"] .meta-value{color:#17263a}
html[data-theme="light"] .kpi{border-color:#d5dee8;background:linear-gradient(135deg,#ffffff,#f5f8fb);box-shadow:0 10px 26px rgba(31,52,75,.07)}html[data-theme="light"] .kpi small{color:#596a7f}html[data-theme="light"] .kpi-note{color:#738398}
html[data-theme="light"] .kpi-early{border-color:#d9c4f0;background:linear-gradient(135deg,#faf6ff,#ffffff)}html[data-theme="light"] .kpi-sig4{border-color:#f0c7cc;background:linear-gradient(135deg,#fff5f6,#ffffff)}html[data-theme="light"] .kpi-sig3,html[data-theme="light"] .kpi-sig2{background:linear-gradient(135deg,#fffaf1,#ffffff)}html[data-theme="light"] .kpi-sig2{border-color:#bfe4ce;background:linear-gradient(135deg,#f1fbf5,#ffffff)}
html[data-theme="light"] .group-head h2{color:#1b2a3d}html[data-theme="light"] .group-head p{color:#687a90}html[data-theme="light"] .group-head a{border-color:#d1dce7;color:#34475d;background:#fff}
html[data-theme="light"] .stock-card{border-color:#d5dfe9;background:linear-gradient(145deg,#ffffff,#f7f9fc);box-shadow:0 8px 22px rgba(39,62,87,.06)}html[data-theme="light"] .stock-card.tone4{border-color:#efc4ca;background:linear-gradient(145deg,#fff7f8,#fff)}html[data-theme="light"] .stock-card.tone3{border-color:#bcd9eb;background:linear-gradient(145deg,#f2faff,#fff)}html[data-theme="light"] .stock-card.tone2{border-color:#ecd3a5;background:linear-gradient(145deg,#fffaf2,#fff)}
html[data-theme="light"] .stock-exchange{border-color:#d3dde7;background:#f2f6fa;color:#607289}html[data-theme="light"] .stock-ma10{color:#708196}html[data-theme="light"] .stock-grid small{color:#78899e}html[data-theme="light"] .signal-tag{border-color:#d2dce6;background:#f4f7fa;color:#5d6f84}
html[data-theme="light"] .filters{background:#fff}html[data-theme="light"] #stock-search{border-color:#d1dce7;background:#fff;color:#17263a}html[data-theme="light"] .search-btn{border-color:#3978b8;background:#2870b6;color:#fff}html[data-theme="light"] .clear-btn{border-color:#d1dce7;background:#f7fafc;color:#617389}
html[data-theme="light"] .chip{border-color:#d2dde8;background:#f7fafc;color:#5d7086}html[data-theme="light"] .chip.active{border-color:#72a8d8;background:#e8f3ff;color:#1d5f98}
html[data-theme="light"] .desktop-table{background:#fff}html[data-theme="light"] th{background:#f2f6fa;color:#607188}html[data-theme="light"] th,html[data-theme="light"] td{border-bottom-color:#e4ebf2}html[data-theme="light"] tbody tr:hover{background:#f4f8fb}
html[data-theme="light"] .empty{border-color:#cbd8e4;background:#f8fafc;color:#6c7d91}html[data-theme="light"] .pager button{border-color:#d1dce7;background:#fff;color:#42556c}
html[data-theme="light"] .dialog-backdrop{background:rgba(26,42,59,.42)}html[data-theme="light"] .dialog{border-color:#d2dde8;background:#fff}html[data-theme="light"] .dialog-head{border-bottom-color:#e0e8ef;background:#f7fafc}html[data-theme="light"] .dialog-close{border-color:#d2dde8;background:#fff;color:#283b51}html[data-theme="light"] .detail{border-color:#dbe4ed;background:#f8fafc}html[data-theme="light"] .detail small{color:#77889c}
html[data-theme="light"] .mobile-bottom{border-top-color:#d5dfe8;background:rgba(255,255,255,.96);box-shadow:0 -12px 30px rgba(31,52,74,.10)}html[data-theme="light"] .mobile-bottom a,html[data-theme="light"] .mobile-bottom button{color:#687b91}html[data-theme="light"] .mobile-bottom button span{border-color:#ddc8ef;background:linear-gradient(145deg,#faf5ff,#f1eafa)}
html[data-theme="light"] .mobile-brand-mark{background:#e7f7ed;color:#16894b}html[data-theme="light"] .mobile-brand strong{color:#17263a}html[data-theme="light"] .mobile-brand small{color:#718197}

/* ==========================================================
   v17.2 — RESPONSIVE + READABILITY POLISH
   Fixes:
   - robust desktop content width beside fixed sidebar
   - full-width cards on mobile list page
   - bottom navigation no longer protrudes over content
   - larger, more readable typography across desktop/mobile
   - mobile filter chips wrap instead of clipping off-screen
   ========================================================== */

html,body{overflow-x:hidden}
body{font-size:15px;line-height:1.45}

/* One consistent desktop geometry: content always lives entirely to the right
   of the fixed sidebar, with 24px minimum breathing room on both sides. */
.header{
  width:calc(100% - var(--sidebar));
  margin-left:var(--sidebar);
}
.header .wrap{
  width:min(1480px,calc(100% - 48px));
  margin-left:auto;
  margin-right:auto;
}
main.wrap{
  width:min(1480px,calc(100vw - var(--sidebar) - 48px));
  max-width:1480px;
  margin-left:calc(var(--sidebar) + max(24px,(100vw - var(--sidebar) - 1480px)/2));
  margin-right:auto;
}

/* Readability — desktop/tablet */
.brand strong{font-size:24px}.brand small{font-size:14px}
.side-links a{font-size:15px;line-height:1.25}.side-live p,.side-live b{font-size:13px}.side-foot small{font-size:12px}.side-foot strong{font-size:13px}.market-badge{font-size:11px}
.market-status{font-size:12px}.refresh-caption{font-size:13px}.refresh-btn,.theme-toggle{font-size:14px}
.meta-label{font-size:11px}.meta-value{font-size:17px}.meta-item{min-height:102px}
.kpi small{font-size:12px}.kpi strong{font-size:34px}.kpi-note{font-size:12px;line-height:1.4}
.group-head h2{font-size:17px}.group-head p{font-size:12.5px;line-height:1.5}.group-head a{font-size:12px}.count-badge{font-size:11px}
.stock-name b{font-size:18px}.stock-exchange{font-size:10px}.stock-price{font-size:17px}.stock-ma10{font-size:11.5px;line-height:1.4}.signal-pill{font-size:11px}
.stock-grid small{font-size:10.5px}.stock-grid b{font-size:14px}.signal-tag{font-size:9.5px}.missing-note{font-size:11px}
#stock-search{font-size:15px}.search-btn,.clear-btn{font-size:13px}.filter-label{font-size:10.5px}.chip{font-size:11.5px;min-height:34px;padding:6px 11px}
.result-info{font-size:12.5px}table{font-size:13.5px}th{font-size:10.5px}th,td{padding:12px 10px}.pager span{font-size:12px}.pager button{font-size:13px}.disclaimer{font-size:11.5px}
.detail small{font-size:10.5px}.detail b{font-size:13.5px}.dialog-head h2{font-size:20px}

@media(max-width:1180px) and (min-width:901px){
  main.wrap{
    width:calc(100vw - var(--sidebar) - 48px);
    max-width:none;
    margin-left:calc(var(--sidebar) + 24px);
    margin-right:24px;
  }
  .header .wrap{width:calc(100% - 48px)}
}

@media(max-width:900px){
  .header{width:auto;margin-left:0}
  .header .wrap{width:calc(100% - 24px)}
  main.wrap{width:auto;max-width:none;margin-left:12px;margin-right:12px}
  .mobile-brand strong{font-size:19px}.mobile-brand small{font-size:11px}
}

@media(max-width:620px){
  body{
    font-size:15px;
    padding-bottom:calc(82px + env(safe-area-inset-bottom));
  }
  .header .wrap{width:calc(100% - 20px)}
  main.wrap{
    width:auto;
    margin-left:10px;
    margin-right:10px;
    padding-bottom:calc(92px + env(safe-area-inset-bottom))!important;
  }

  .topbar{gap:8px}.top-actions{gap:6px}
  .mobile-brand{gap:9px}.mobile-brand-mark{width:38px;height:38px}.mobile-brand strong{font-size:19px}.mobile-brand small{font-size:11px}
  .theme-toggle{width:40px;height:40px}.refresh-btn{height:40px;padding:0 12px;font-size:14px}

  .meta-grid{gap:0}.meta-item{min-height:82px;padding:12px 11px;gap:9px}.meta-icon{width:31px;height:31px;font-size:19px}.meta-label{font-size:9.5px;line-height:1.25}.meta-value{font-size:12.5px;line-height:1.35}

  .kpis{gap:9px}.kpi{min-height:138px;padding:14px}.kpi small{font-size:10.5px;line-height:1.3}.kpi strong{font-size:31px}.kpi-note{font-size:10.5px;line-height:1.4}.spark{width:58px;height:29px}

  .group-section{padding:12px}.group-head{gap:9px;margin-bottom:12px}.group-head h2{font-size:16px;line-height:1.3}.group-head p{font-size:11px;line-height:1.5}.group-head a{font-size:10.5px;padding:7px 9px}.count-badge{font-size:10px}

  /* Overview alert cards remain a horizontal carousel by design. */
  .group-grid{display:flex;width:100%;max-width:100%;overflow-x:auto;gap:9px;padding:1px 1px 6px;scroll-padding-left:1px;scroll-snap-type:x proximity;overscroll-behavior-x:contain}
  .group-grid .stock-card{flex:0 0 calc(100vw - 58px);width:auto;max-width:360px;scroll-snap-align:start}

  .stock-card{padding:15px;border-radius:13px}
  .stock-name b{font-size:18px}.stock-exchange{font-size:9.5px}.stock-price{font-size:17px}.stock-ma10{font-size:11px}.signal-pill{font-size:10.5px;min-width:39px}
  .stock-grid{grid-template-columns:repeat(2,minmax(0,1fr));column-gap:14px;row-gap:12px;margin-top:15px}.stock-grid small{font-size:9.5px}.stock-grid b{font-size:13.5px}.signal-tag{font-size:9px;padding:4px 6px}

  .filters{padding:12px;border-radius:13px}.search-row{gap:7px}.search-btn,.clear-btn{font-size:12px}.filter-label{font-size:10px;margin-bottom:8px}
  /* No hidden filter options on phones: wrapping is easier to read/tap than a
     clipped horizontal row. */
  .chips,.sort-chips{flex-wrap:wrap;overflow:visible;padding-bottom:0;gap:7px}.chip{font-size:11.5px;min-height:35px;padding:6px 10px}
  .result-info{font-size:12px;margin-top:11px}

  .desktop-table{display:none}.mobile-list{display:grid;gap:11px;width:100%}
  /* List-page cards use the whole available viewport width. */
  .mobile-list .stock-card{width:100%;max-width:none;min-width:0;flex:none}

  .pager{gap:7px}.pager button{height:38px;font-size:12px}.pager span{font-size:11.5px}
  .detail-grid{gap:8px}.detail{padding:12px}.detail small{font-size:10px}.detail b{font-size:13px}

  /* Bottom nav stays entirely inside its own bar; no raised center icon. */
  .mobile-bottom{
    min-height:68px;
    padding:6px 8px max(6px,env(safe-area-inset-bottom));
  }
  .mobile-bottom a,.mobile-bottom button{min-height:54px;gap:3px}
  .mobile-bottom span{font-size:20px}
  .mobile-bottom small{font-size:10.5px;line-height:1.15}
  .mobile-bottom button span{
    width:34px;height:34px;margin-top:0;border-radius:11px;
    box-shadow:0 0 18px rgba(170,91,255,.12)
  }
  .mobile-bottom button small{margin-top:0}
}

@media(max-width:380px){
  .refresh-btn{width:40px;padding:0;justify-content:center}
  .refresh-btn span:last-child{display:none}
  .meta-item{padding-inline:9px}.meta-value{font-size:11.5px}
  .kpi{padding:12px}.kpi strong{font-size:29px}
  .group-grid .stock-card{flex-basis:calc(100vw - 52px)}
}

/* ==========================================================
   v17.4 — LOCAL COMPANY LOGOS + DATA-FIRST POLISH
   ========================================================== */

/* Auto refresh status */
.refresh-caption{white-space:nowrap}
.refresh-caption b{min-width:58px}
.refresh-caption b.waiting{min-width:170px;color:var(--orange)}
.refresh-caption b.outside{min-width:130px;color:var(--muted)}
.auto-refresh-mobile{display:none}

/* Company logo system: local self-hosted logo -> ticker lettermark fallback */
.company-logo{position:relative;display:inline-grid;place-items:center;flex:0 0 auto;overflow:hidden;border:1px solid #31465c;border-radius:10px;background:#f7fafc;color:#25384d;font-weight:900;letter-spacing:-.03em;box-shadow:0 4px 12px rgba(0,0,0,.16)}
.company-logo-img{position:absolute;inset:0;display:block;width:100%;height:100%;object-fit:contain;background:#fff;padding:3px;opacity:0;visibility:hidden;transition:opacity .12s ease}
.company-logo.has-logo .company-logo-img{opacity:1;visibility:visible}
.company-logo.has-logo .company-logo-fallback{opacity:0;visibility:hidden}
.company-logo-fallback{display:grid;place-items:center;width:100%;height:100%;font-size:10px;line-height:1;transition:opacity .12s ease}
.card-logo{width:38px;height:38px;border-radius:10px}
.card-logo .company-logo-fallback{font-size:10px}
.table-logo{width:27px;height:27px;border-radius:7px;box-shadow:none}
.table-logo .company-logo-fallback{font-size:8px}
.dialog-logo{width:46px;height:46px;border-radius:12px}
.dialog-logo .company-logo-fallback{font-size:11px}
.stock-name-row{display:flex;align-items:center;gap:10px;min-width:0}
.stock-name-row>div{min-width:0}
.table-symbol-cell{display:flex;align-items:center;gap:8px;min-width:86px}
.table-symbol-cell b{color:#49adff;font-size:13.5px}
.dialog-symbol{display:flex;align-items:center;gap:11px;min-width:0}
.dialog-symbol h2{min-width:0}

/* KPI indicators are semantic labels, not decorative fake charts. */
.kpi-semantic{display:grid;place-items:center;min-width:52px;height:34px;padding:0 10px;border:1px solid currentColor;border-radius:999px;background:rgba(255,255,255,.035);font-size:12px;font-weight:900;letter-spacing:.01em;opacity:.82}

/* Slightly stronger data hierarchy */
.stock-price{font-variant-numeric:tabular-nums;letter-spacing:-.01em}
.stock-grid b,.meta-value,.detail b,td.num{font-variant-numeric:tabular-nums}
.desktop-table .symbol{padding-top:8px;padding-bottom:8px}

html[data-theme="light"] .company-logo{border-color:#d2dde8;background:#fff;color:#31465d;box-shadow:0 3px 10px rgba(39,62,87,.08)}
html[data-theme="light"] .kpi-semantic{background:rgba(255,255,255,.72)}

@media(max-width:900px){
  .refresh-caption{font-size:12px}
  .refresh-caption b.waiting{min-width:150px}
}

@media(max-width:620px){
  /* Desktop caption is hidden in the compact topbar; show a dedicated status strip. */
  .auto-refresh-mobile{display:flex;align-items:center;justify-content:center;gap:5px;margin-top:8px;padding:8px 10px;border:1px solid var(--border);border-radius:10px;background:rgba(10,24,39,.76);color:var(--muted);font-size:11.5px;line-height:1.3;text-align:center}
  .auto-refresh-mobile b{color:var(--green);font-variant-numeric:tabular-nums}
  .auto-refresh-mobile b.waiting{color:var(--orange)}
  .auto-refresh-mobile b.outside{color:var(--muted)}
  html[data-theme="light"] .auto-refresh-mobile{background:#fff;border-color:#d6e0e9}

  .card-logo{width:36px;height:36px;border-radius:9px}
  .stock-name-row{gap:9px}
  .stock-name b{font-size:18px}
  .stock-price{font-size:18px}
  .table-logo{width:25px;height:25px}
  .dialog-logo{width:42px;height:42px}
  .kpi-semantic{min-width:46px;height:31px;padding:0 8px;font-size:11px}
}

/* ============================================================
   v18 — Fundamental + Industry views
   ============================================================ */
.page-intro{margin:18px 0 14px;padding:22px 24px;border:1px solid var(--border);border-radius:14px;background:linear-gradient(135deg,rgba(20,56,87,.42),rgba(11,23,39,.96));box-shadow:var(--shadow)}
.page-intro .eyebrow,.dialog-section .eyebrow{display:block;color:var(--green);font-size:9px;font-weight:900;letter-spacing:.12em}.page-intro h1{margin:6px 0 6px;font-size:25px;letter-spacing:-.035em}.page-intro p{max-width:850px;margin:0;color:var(--muted);font-size:12px;line-height:1.6}.fund-main{padding-top:0}
.score-method{padding:18px;margin-bottom:14px}.score-method-head{display:flex;align-items:flex-start;justify-content:space-between;gap:14px}.score-method-head h2{margin:0 0 5px;font-size:16px}.score-method-head p{margin:0;color:var(--muted);font-size:11px;line-height:1.5}.method-total{flex:0 0 auto;padding:7px 10px;border:1px solid #2e6245;border-radius:999px;background:#0b2b1e;color:var(--green);font-size:10px;font-weight:850}.method-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:9px;margin-top:14px}.method-grid>div{padding:12px;border:1px solid var(--border);border-radius:10px;background:var(--panel2)}.method-grid b{display:block;font-size:11px}.method-grid p{margin:6px 0 0;color:var(--muted);font-size:10px;line-height:1.5}.score-rules{margin-top:12px;border-top:1px solid var(--border);padding-top:11px}.score-rules summary{cursor:pointer;color:#b9c9d9;font-size:11px;font-weight:800}.rule-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin-top:10px}.rule-grid p{margin:0;padding:9px;border-radius:8px;background:var(--panel3);color:var(--muted);font-size:10px;line-height:1.5}
.industry-picker{display:flex;gap:8px;overflow-x:auto;padding:2px 0 12px;scrollbar-width:none}.industry-picker::-webkit-scrollbar{display:none}.industry-chip{flex:0 0 auto;display:flex;align-items:center;gap:8px;height:38px;padding:0 11px;border:1px solid var(--border2);border-radius:9px;background:var(--panel2);color:#b7c6d5;font-size:10px;font-weight:800}.industry-chip b{display:grid;place-items:center;min-width:22px;height:22px;padding:0 5px;border-radius:999px;background:#162b3f;color:#8fa7bf;font-size:9px}.industry-chip.active{border-color:#2a7950;background:linear-gradient(90deg,rgba(37,185,102,.16),rgba(18,53,38,.3));color:#fff}.industry-chip.active b{background:#153e2a;color:var(--green)}
.industry-panel{padding:14px}.section-title{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:10px}.section-title h2,.section-title h3{margin:0;font-size:15px}.section-title p{margin:4px 0 0;color:var(--muted);font-size:10px}.fund-table-shell{max-height:64vh}.fund-score{display:inline-flex;align-items:center;justify-content:center;min-width:58px;padding:5px 8px;border:1px solid;border-radius:999px;font-size:10px;font-weight:900;font-variant-numeric:tabular-nums}.score-good{border-color:#2a764d;background:#0d3222;color:var(--green)}.score-mid{border-color:#7a6328;background:#332813;color:#ffc95f}.score-low{border-color:#7c3139;background:#35161a;color:#ff7a85}.score-na{border-color:#405267;background:#152333;color:#91a4b8}
.fund-filters{padding:13px;margin-bottom:10px}.fund-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}.fund-card{min-width:0;padding:13px;border:1px solid var(--border);border-radius:12px;background:linear-gradient(180deg,var(--panel2),var(--panel));cursor:pointer;transition:border-color .15s ease,transform .15s ease}.fund-card:hover{border-color:#385774;transform:translateY(-1px)}.fund-card-top{display:flex;align-items:flex-start;justify-content:space-between;gap:8px}.fund-card-top>div{min-width:0}.fund-card-top span:not(.fund-score){display:block;margin-top:3px;color:var(--muted);font-size:9px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.fund-symbol{color:#4db1ff;font-size:17px}.fund-card-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin-top:12px}.fund-card-grid>div{padding:8px;border-radius:8px;background:var(--panel3)}.fund-card-grid small{display:block;color:var(--muted);font-size:8px}.fund-card-grid b{display:block;margin-top:4px;font-size:11px;font-variant-numeric:tabular-nums}.fund-card-foot{display:flex;justify-content:space-between;gap:8px;margin-top:10px;color:var(--muted2);font-size:8px}.fund-mobile-list{display:none}
.dialog-wide{width:min(920px,100%)}.dialog-symbol{display:flex;align-items:center;gap:10px}.dialog-symbol h2{margin:0}.dialog-symbol small{display:block;margin-top:4px;color:var(--muted);font-size:10px}.dialog-section{padding:0 0 15px;margin-bottom:15px;border-bottom:1px solid var(--border)}.dialog-section:last-child{border-bottom:0;margin-bottom:0}.fund-summary{display:grid;grid-template-columns:210px 1fr;gap:12px;align-items:stretch}.big-score{display:inline-flex;margin-top:6px;padding:7px 10px;border:1px solid;border-radius:10px;font-size:24px;font-weight:950;letter-spacing:-.04em}.fund-summary p{margin:6px 0 0;color:var(--muted);font-size:9px}.fund-kpis{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}.fund-kpis>div{padding:10px;border:1px solid var(--border);border-radius:9px;background:var(--panel2)}.fund-kpis small{display:block;color:var(--muted);font-size:8px}.fund-kpis b{display:block;margin-top:5px;font-size:12px}.analysis-badges{display:flex;flex-wrap:wrap;gap:6px;margin-top:10px}.analysis-badge{padding:5px 8px;border:1px solid var(--border2);border-radius:999px;background:var(--panel3);color:#b8c8d8;font-size:9px;font-weight:750}.score-parts{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px;margin-top:10px}.score-part{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:9px;border:1px solid var(--border);border-radius:9px;background:var(--panel2)}.score-part span{min-width:0}.score-part b{display:block;font-size:9px}.score-part small{display:block;margin-top:3px;color:var(--muted);font-size:8px}.score-part strong{font-size:10px;color:#dbe7f3}.quarter-table{overflow:auto;border:1px solid var(--border);border-radius:10px}.quarter-table table{font-size:10px}.quarter-loading{padding:12px;border:1px dashed var(--border2);border-radius:9px;color:var(--muted);font-size:10px}.bctc-placeholder{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px;border:1px dashed #3d4c5e;border-radius:10px;background:var(--panel2)}.bctc-placeholder h3{margin:0;font-size:12px}.bctc-placeholder p{margin:4px 0 0;color:var(--muted);font-size:9px}.bctc-placeholder button{height:34px;padding:0 11px;border:1px solid var(--border2);border-radius:8px;background:var(--panel3);color:var(--muted);font-size:9px;font-weight:800}
html[data-theme="light"] .page-intro{background:linear-gradient(135deg,#edf7ff,#fff)}html[data-theme="light"] .method-total{background:#e8f7ee;color:#167a46}html[data-theme="light"] .industry-chip b{background:#e9eff5;color:#61758a}html[data-theme="light"] .industry-chip.active{background:#e8f8ee;color:#183527}html[data-theme="light"] .score-good{background:#e8f8ee;color:#137443}html[data-theme="light"] .score-mid{background:#fff5dc;color:#8f6500}html[data-theme="light"] .score-low{background:#ffedef;color:#ad3240}html[data-theme="light"] .score-na{background:#edf2f6;color:#66788b}
@media(max-width:1180px){.method-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.fund-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:900px){.fund-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.fund-summary{grid-template-columns:1fr}.fund-kpis{grid-template-columns:repeat(4,minmax(0,1fr))}}
@media(max-width:620px){.page-intro{margin-top:10px;padding:15px}.page-intro h1{font-size:20px}.page-intro p{font-size:10px}.score-method{padding:12px}.score-method-head{display:block}.method-total{display:inline-flex;margin-top:9px}.method-grid{grid-template-columns:1fr}.rule-grid{grid-template-columns:1fr}.fund-grid{grid-template-columns:1fr}.industry-panel{padding:10px}.industry-panel .desktop-table{display:none}.fund-mobile-list{display:grid}.fund-card{padding:12px}.fund-card-grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:6px}.fund-card-grid>div{padding:7px 5px;text-align:center}.fund-card-grid small{font-size:7px}.fund-card-grid b{font-size:9px}.dialog-wide{max-height:92vh}.fund-kpis{grid-template-columns:repeat(2,minmax(0,1fr))}.score-parts{grid-template-columns:1fr}.bctc-placeholder{display:block}.bctc-placeholder button{margin-top:10px}.quarter-table th,.quarter-table td{padding:8px 7px}.mobile-bottom a span{font-size:19px}.mobile-bottom a small{font-size:8px}}


/* ============================================================
   v18.1 — Readability & learner-friendly fundamental views
   ============================================================ */
.page-intro{padding:24px 26px}
.page-intro .eyebrow,.dialog-section .eyebrow{font-size:11px;letter-spacing:.10em}
.page-intro h1{margin-top:7px;font-size:29px;line-height:1.15}
.page-intro p{max-width:980px;font-size:14px;line-height:1.65}

.score-method{padding:22px;margin-bottom:16px}
.score-method-head h2{font-size:20px;line-height:1.25}
.score-method-head p{max-width:940px;font-size:13.5px;line-height:1.65}
.method-total{padding:8px 12px;font-size:12px}
.method-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-top:16px}
.method-grid>div{padding:15px 16px;border-radius:11px}
.method-grid b{font-size:14px;line-height:1.4}
.method-grid p{font-size:12.5px;line-height:1.7}
.method-grid p strong{color:#eaf4ff}
.term-glossary{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin-top:13px}
.term-glossary>div{padding:12px 14px;border:1px solid var(--border);border-radius:10px;background:rgba(13,31,49,.72)}
.term-glossary b{display:block;font-size:12.5px;color:#dce9f6}
.term-glossary span{display:block;margin-top:4px;color:var(--muted);font-size:12px;line-height:1.55}
.score-rules{margin-top:15px;padding-top:14px}
.score-rules summary{font-size:13.5px;line-height:1.4}
.rule-grid{gap:10px;margin-top:12px}
.rule-grid p{padding:12px 13px;font-size:12.5px;line-height:1.65}
.score-note{margin:13px 0 0;padding:11px 13px;border-left:3px solid #2f7b55;border-radius:7px;background:rgba(26,72,50,.17);color:#aebfd0;font-size:12px;line-height:1.6}

.industry-picker{display:grid;grid-template-columns:repeat(auto-fit,minmax(155px,1fr));gap:8px;overflow:visible;padding:2px 0 14px}
.industry-chip{width:100%;min-height:44px;height:auto;justify-content:space-between;padding:8px 11px;font-size:12px;line-height:1.25;text-align:left}
.industry-chip span{white-space:normal}
.industry-chip b{min-width:auto;height:24px;padding:0 7px;font-size:10px;white-space:nowrap}
.industry-panel{padding:18px}
.section-title{margin-bottom:13px}
.section-title h2,.section-title h3{font-size:18px}
.section-title p{font-size:12.5px;line-height:1.5}

.fundamental-table{min-width:1080px;font-size:14px}
.fundamental-table th,.fundamental-table td{padding:13px 12px;text-align:center;vertical-align:middle}
.fundamental-table th{font-size:11px;line-height:1.25;text-transform:none;letter-spacing:0}
.fundamental-table .symbol{text-align:center}
.fundamental-table .symbol b{font-size:14px}
.th-main{display:block;color:#b7c8d9;font-size:11.5px;font-weight:850;white-space:normal}
.th-sub{display:block;margin-top:3px;color:#71869c;font-size:9.5px;font-weight:600;line-height:1.3;white-space:normal}
.score-coverage{display:block;margin-top:5px;color:#758ba1;font-size:10px;line-height:1.25;white-space:normal}
.industry-name-cell{display:inline-block;max-width:150px;white-space:normal;line-height:1.35}
.fund-score{min-width:66px;padding:6px 9px;font-size:12px}
.freshness-tag{display:inline-flex;align-items:center;justify-content:center;min-width:88px;padding:5px 8px;border:1px solid #31475d;border-radius:999px;background:#122235;color:#b8c7d6;font-size:10.5px;font-weight:750}
.freshness-current{border-color:#275d43;background:#0d2c20;color:#57dfa0}.freshness-lagging{border-color:#735d29;background:#302713;color:#ffd06b}.freshness-stale,.freshness-no_data{border-color:#6a3940;background:#2c171b;color:#ff919a}
.fund-table-shell,.screener-table-shell{max-height:66vh}
.screener-table-panel{padding:14px}

.fund-filters{padding:17px;margin-bottom:13px}
.fund-filters .filter-block{margin-top:15px}
.fund-filters .filter-block:first-child{margin-top:0}
.fund-filters .filter-label{font-size:12.5px;letter-spacing:.035em}
.filter-help{margin:-1px 0 9px;color:#73889e;font-size:11.5px;line-height:1.45}
.fund-filters .chip{min-height:37px;padding:7px 12px;font-size:12px}
.result-info{font-size:13px;line-height:1.55}
.disclaimer{font-size:12px}

.fund-card{padding:15px}
.fund-card-top span:not(.fund-score){font-size:11px}
.fund-symbol{font-size:19px}
.fund-card-grid small{font-size:10px;line-height:1.35}
.fund-card-grid b{font-size:13px}
.fund-card-foot{font-size:10px;line-height:1.4}

.dialog-wide{width:min(1020px,100%)}
.dialog-section{padding-bottom:18px;margin-bottom:18px}
.dialog-symbol small{font-size:12px}
.fund-summary{grid-template-columns:240px 1fr;gap:14px}
.fund-summary p{font-size:11.5px;line-height:1.5}
.fund-kpis>div{padding:12px}
.fund-kpis small{font-size:10.5px;line-height:1.35}
.fund-kpis b{font-size:14px}
.analysis-badge{padding:6px 9px;font-size:11px;line-height:1.35}
.score-parts{gap:9px;margin-top:12px}
.score-part{padding:11px}
.score-part b{font-size:11.5px;line-height:1.35}
.score-part small{font-size:10.5px;line-height:1.4}
.score-part strong{font-size:12px}
.quarter-table table{font-size:12.5px;min-width:760px}
.quarter-table th{font-size:10.5px;text-transform:none}
.quarter-loading{font-size:12px}
.bctc-placeholder h3{font-size:14px}.bctc-placeholder p{font-size:11.5px;line-height:1.5}.bctc-placeholder button{font-size:11px}

html[data-theme="light"] .term-glossary>div{background:#f7fafc}
html[data-theme="light"] .score-note{background:#eef8f2;color:#5a6e62}

@media(max-width:1180px){
  .industry-picker{grid-template-columns:repeat(4,minmax(0,1fr))}
  .fundamental-table{min-width:1040px}
}
@media(max-width:900px){
  .page-intro h1{font-size:26px}.page-intro p{font-size:13.5px}
  .industry-picker{grid-template-columns:repeat(3,minmax(0,1fr))}
  .method-grid{grid-template-columns:1fr 1fr}
  .fund-summary{grid-template-columns:1fr}
}
@media(max-width:620px){
  .page-intro{padding:16px}.page-intro .eyebrow{font-size:9.5px}.page-intro h1{font-size:22px}.page-intro p{font-size:12.5px;line-height:1.55}
  .score-method{padding:14px}.score-method-head h2{font-size:17px}.score-method-head p{font-size:12px}.method-total{font-size:10.5px}
  .method-grid,.term-glossary,.rule-grid{grid-template-columns:1fr}.method-grid b{font-size:13px}.method-grid p,.rule-grid p{font-size:11.5px}.term-glossary span{font-size:11.5px}
  .industry-picker{display:flex;overflow-x:auto;gap:7px;padding-bottom:10px;scrollbar-width:none}.industry-picker::-webkit-scrollbar{display:none}.industry-chip{flex:0 0 auto;width:auto;min-height:39px;font-size:11px}.industry-chip b{font-size:9px}
  .fund-card{padding:13px}.fund-card-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}.fund-card-grid>div{padding:8px 6px;text-align:left}.fund-card-grid small{font-size:9.5px}.fund-card-grid b{font-size:12px}.fund-card-foot{font-size:9.5px}
  .fund-kpis small{font-size:9.5px}.fund-kpis b{font-size:12.5px}.score-part b{font-size:11px}.score-part small{font-size:10px}
  .bctc-placeholder p{font-size:10.5px}
}
