/* Market overview and stock controls share normal document flow. */
.r4-stock-plot{min-width:0;display:flex;flex-direction:column;gap:0;align-self:start}
.desktop-v4 .r2-chart-with-context .r4-stock-plot #real-candle{height:var(--stock-plot-height,360px)!important;min-height:var(--stock-plot-height,360px)!important;margin:0!important;width:100%!important;min-width:0!important}
.r4-stock-legend{display:flex;flex-wrap:wrap;align-items:center;gap:8px 15px;padding:10px 0 8px;border-bottom:1px solid #e5eaf1;color:var(--mm-muted);font-size:11px;line-height:1.5;position:static}
.r4-stock-legend>span{display:inline-flex;align-items:center;gap:6px;white-space:nowrap}.r4-stock-legend i{display:inline-block;width:18px;height:3px;background:#62738b;flex:0 0 auto}.r4-stock-legend .r4-candle-key{height:10px;width:13px;background:linear-gradient(145deg,#e0443a 50%,#2f6fe0 50%);border-radius:2px}.r4-stock-legend .r4-close-key{border:1px solid #63758a;background:var(--mm-surface);border-radius:50%;height:6px;width:6px}.r4-stock-legend .r4-volume-key{height:10px;width:12px;background:#8aa5b9}
.r4-stock-plot #candle-quality{font-size:10px;line-height:1.5;margin:8px 0;color:var(--mm-muted)}
.r4-stock-plot .r4-stock-actions{position:static!important;display:flex!important;flex-wrap:wrap;align-items:center;gap:10px 18px;margin:8px 0 0!important;padding:0!important;clear:both;min-height:42px}
.r4-stock-actions>a{position:static!important;transform:none!important;margin:0!important;max-width:100%;line-height:1.5;font-size:12px;white-space:normal}.r4-stock-actions>a.btn{padding:11px 14px!important;min-height:42px;display:inline-flex;align-items:center}
.desktop-v4 .r4-market-focus{display:grid;grid-template-columns:minmax(0,1.8fr) minmax(300px,1fr);gap:16px;align-items:start;margin:0 0 18px;grid-column:1/-1}
.desktop-v4 .r4-market-focus #real-heatmap{grid-column:auto!important;min-width:0;padding:16px!important;margin:0!important;min-height:0!important}
.desktop-v4 #real-heatmap>.live-panel-title{display:flex;align-items:center;flex-wrap:wrap;justify-content:space-between;gap:8px!important;padding:0!important;margin:0 0 8px!important}
.desktop-v4 #real-heatmap .live-panel-title h2{font-size:17px!important}
.desktop-v4 #real-heatmap .compact-tabs{display:flex;align-items:center;gap:2px;flex-wrap:wrap;padding:2px;min-height:0}
.desktop-v4 #real-heatmap .compact-tabs button{font-size:10px!important;padding:5px 8px!important;min-height:26px!important;line-height:1.4!important}
.desktop-v4 #real-heatmap .heat-tools{display:flex;flex-wrap:wrap;align-items:center;gap:6px!important;margin:0 0 6px!important}
.desktop-v4 #real-heatmap .heat-legend{font-size:9px!important;gap:5px!important}.desktop-v4 #real-heatmap .heat-legend i{width:9px;height:9px}
.desktop-v4 #real-heatmap #heat-size-basis{font-size:10px!important;line-height:1.4;margin:0!important}
.desktop-v4 #real-heatmap .r2-sector-filter{padding:6px 0!important;gap:8px;font-size:10px;align-items:center;flex-direction:row;justify-content:space-between}
.desktop-v4 #real-heatmap .r2-sector-filter select{font-size:11px;min-height:28px;height:28px;padding:3px 8px;max-width:170px}.desktop-v4 #real-heatmap .r2-sector-filter>span{font-size:10px}
#real-heat-grid.r3-heat-map{height:var(--heat-map-height,300px)!important;min-height:var(--heat-map-height,300px)!important}
.r3-heat-sector h4{font-size:10px}.r3-heat-tile>span{font-size:13px}.r3-heat-tile>b{font-size:16px}.r3-heat-tile>small{font-size:10px}
/* Numeric cards size to their text; Japanese glyphs must never flex-shrink. */
#real-heat-grid.r3-heat-values{grid-template-columns:repeat(5,minmax(0,1fr));grid-auto-rows:minmax(86px,auto)!important;gap:3px!important}
.desktop-v4 #real-heat-grid.r3-heat-values .r3-heat-tile{display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:18px minmax(32px,auto) 20px;align-content:stretch;justify-items:stretch;gap:2px;padding:8px;overflow:visible}
.desktop-v4 #real-heat-grid.r3-heat-values .r3-heat-tile>span{font-size:13px;line-height:18px;height:auto;white-space:nowrap}
.desktop-v4 #real-heat-grid.r3-heat-values .r3-heat-tile>small{display:block;align-self:center;width:100%;max-width:100%;height:auto;min-height:0;font-size:11px!important;line-height:1.45!important;white-space:normal;overflow:visible;overflow-wrap:anywhere;word-break:keep-all;text-overflow:clip}
.desktop-v4 #real-heat-grid.r3-heat-values .r3-heat-tile>b{font-size:14px;line-height:20px;height:auto;white-space:nowrap}
.r4-heat-pages{position:static!important;inset:auto!important;width:auto;transform:none;padding:0;border:0;background:transparent;display:flex;align-items:center;justify-content:flex-end;gap:12px;font-size:11px;margin-top:8px}.r4-heat-pages[hidden]{display:none}.r4-heat-pages button{border:1px solid #d6dfea;background:#fff;color:#263c53;border-radius:6px;padding:5px 10px;cursor:pointer}.r4-heat-pages button:disabled{opacity:.4;cursor:default}
.r4-market-focus #r2-market-summary{min-width:0;margin:0}.r4-market-focus .r2-summary{padding:18px;margin:0;border-radius:14px}.r4-market-focus .r2-summary h2{font-size:18px;line-height:1.5;margin:7px 0 12px}.r4-market-focus .r2-summary ol{display:grid;grid-template-columns:1fr;gap:9px;margin:0 0 10px}.r4-market-focus .r2-summary li{padding-left:10px}.r4-market-focus .r2-summary li>span{font-size:11px}.r4-market-focus .r2-summary li p{font-size:12px;line-height:1.65;margin:3px 0}.r4-market-focus .r2-summary>.r2-stock-chips{display:none}.r4-market-focus .r2-summary>small{font-size:9px;line-height:1.4}.r4-market-focus #r2-market-summary>.actions{gap:10px;margin:10px 0;display:flex;flex-wrap:wrap}.r4-market-focus .actions>.btn{font-size:11px;padding:9px 12px;min-height:34px}.r4-market-focus .actions>.text-link{font-size:11px}.r4-market-focus .r2-hold-impact{font-size:11px;margin:8px 0}
.desktop-v4 .live-workspace>.v4-ticker{margin-bottom:0;gap:6px}.desktop-v4 .live-workspace>.v4-ticker>a{padding:7px 9px!important;display:grid;grid-template-columns:minmax(0,1fr) auto;gap:2px 4px}.desktop-v4 .live-workspace>.v4-ticker span,.desktop-v4 .live-workspace>.v4-ticker small{grid-column:1/-1}.desktop-v4 .live-workspace>.v4-ticker strong{font-size:15px}.desktop-v4 .live-workspace>.v4-ticker b{font-size:10px;margin-left:0;align-self:center}.desktop-v4 .r4-market-delay{font-size:10px;line-height:1.5;margin:4px 0 10px;padding:0;background:transparent;color:#705121}
@media(max-width:1100px){.desktop-v4 .r4-market-focus{grid-template-columns:1fr}.r4-market-focus .r2-summary ol{grid-template-columns:repeat(3,minmax(0,1fr))}.r4-market-focus .r2-summary{padding:16px}}
@media(max-width:760px){.desktop-v4 .r4-market-focus{gap:14px}.desktop-v4 .r4-market-focus #real-heatmap{padding:12px!important}.desktop-v4 #real-heatmap .r2-sector-filter{flex-wrap:wrap}.desktop-v4 #real-heatmap .heat-tools{gap:7px!important}.desktop-v4 #real-heatmap .compact-tabs button{font-size:10px!important;padding:5px 7px!important}.r4-market-focus .r2-summary ol{grid-template-columns:1fr}.desktop-v4 .live-workspace>.v4-ticker{grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:4px}.desktop-v4 .live-workspace>.v4-ticker>a{padding:6px!important;display:block!important}.desktop-v4 .live-workspace>.v4-ticker strong{font-size:12px!important}.desktop-v4 .live-workspace>.v4-ticker span{font-size:8px}.desktop-v4 .live-workspace>.v4-ticker b{font-size:9px!important;margin-left:3px}.desktop-v4 .live-workspace>.v4-ticker small{font-size:8px}#real-heat-grid.r3-heat-values{grid-template-columns:repeat(3,minmax(0,1fr));grid-auto-rows:minmax(79px,auto)!important}.r4-stock-actions>a.btn{font-size:11px}.r4-stock-legend{font-size:10px;gap:8px 10px}.r4-stock-plot #candle-quality{font-size:9px}.r4-market-focus #r2-market-summary>.actions{margin:8px 0}}
.desktop-v4 #real-heatmap .compact-tabs{margin:0!important}
@media(max-width:760px){
.desktop-v4 .live-workspace>.v4-ticker>a>span,.desktop-v4 .live-workspace>.v4-ticker>a>strong,.desktop-v4 .live-workspace>.v4-ticker>a>b,.desktop-v4 .live-workspace>.v4-ticker>a>small{display:block!important;white-space:nowrap;max-width:none;line-height:1.45}
.desktop-v4 .live-workspace>.v4-ticker>a>strong{font-size:12px!important}.desktop-v4 .live-workspace>.v4-ticker>a>b{margin:0!important}
.desktop-v4 #real-heatmap>.live-panel-title{gap:5px!important;flex-wrap:nowrap!important}.desktop-v4 #real-heatmap .live-panel-title h2{font-size:15px!important;white-space:nowrap}.desktop-v4 #real-heatmap .live-panel-title .compact-tabs{flex-wrap:nowrap!important;gap:0}
.desktop-v4 #real-heatmap .live-panel-title .compact-tabs button{font-size:9px!important;padding:4px 5px!important;min-height:24px!important;white-space:nowrap}
.desktop-v4 #real-heatmap .heat-tools{gap:3px!important;justify-content:flex-end}.desktop-v4 #real-heatmap .heat-legend{margin-right:auto!important;gap:4px!important}.desktop-v4 #real-heatmap #heat-size-basis{font-size:9px!important}
.desktop-v4 #real-heatmap .r2-sector-filter{padding:4px 0!important}.desktop-v4 #real-heatmap .r2-sector-filter select{height:24px;min-height:24px;padding:2px 6px}

}
.r4-market-focus .r2-summary li p{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:3;overflow:hidden}
#real-heatmap{scroll-margin-top:140px}@media(max-width:760px){#real-heatmap{scroll-margin-top:115px}}
.r4-stock-plot .r4-stock-actions>a{width:auto!important;flex:0 1 auto;display:inline-flex!important;align-items:center;min-height:42px}
.r3-heat-tile.is-code-only b,.r3-heat-tile.is-code-only small{display:none!important}.r3-heat-tile.is-code-only span{font-size:9px;max-width:100%;white-space:nowrap;text-overflow:ellipsis;overflow:hidden}.r3-heat-tile.is-tiny b{max-width:100%;white-space:nowrap}
.r4-ticker-loading{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:6px;margin-bottom:24px}.r4-ticker-loading i{height:80px;background:var(--mm-soft);border-radius:10px}.r4-loading-status{font-size:12px;color:var(--mm-muted);margin:4px 0 10px}
.r4-map-placeholder{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));grid-template-rows:repeat(2,1fr);gap:4px;height:clamp(200px,calc(100vh - 520px),300px);border-radius:8px;overflow:hidden}.r4-map-placeholder i{background:var(--mm-soft)}.r4-map-placeholder i:nth-child(3n){background:#d6dfe9}.r4-heat-loading p{font-size:12px;color:#536278;margin:8px 0}.r4-early-map{padding:16px;min-height:0}.r4-early-map h2{font-size:17px;margin:6px 0 80px}
.r4-summary-loading{border-radius:14px;background:var(--mm-soft);padding:18px;min-height:360px;box-sizing:border-box}.r4-summary-loading p{font-size:13px;color:#6c4a26}.r4-summary-loading i{display:block;height:13px;background:#e9cba3;border-radius:5px;margin:18px 0}.r4-summary-loading i:nth-child(3n){width:65%;margin-bottom:32px}
@media(prefers-reduced-motion:no-preference){.r4-map-placeholder,.r4-summary-loading>div,.r4-ticker-loading{animation:r4-loading-pulse 1.4s ease-in-out infinite alternate}@keyframes r4-loading-pulse{from{opacity:.6}to{opacity:1}}}
@media(max-width:760px){.r4-ticker-loading{grid-template-columns:repeat(4,minmax(0,1fr));margin-bottom:20px}.r4-ticker-loading i{height:68px}.r4-map-placeholder{grid-template-columns:repeat(3,minmax(0,1fr));grid-template-rows:repeat(4,1fr);height:225px}.r4-early-map h2{margin-bottom:72px}.r4-summary-loading{min-height:300px}}
@media(max-width:760px){
.desktop-v4 #real-heat-grid.r3-heat-values .r3-heat-tile{grid-template-rows:16px minmax(29px,auto) 18px;padding:6px}
.desktop-v4 #real-heat-grid.r3-heat-values .r3-heat-tile>span{font-size:11px;line-height:16px}
.desktop-v4 #real-heat-grid.r3-heat-values .r3-heat-tile>small{font-size:10px!important}
.desktop-v4 #real-heat-grid.r3-heat-values .r3-heat-tile>b{font-size:13px;line-height:18px}
}

/* Keep article discovery compact and leave complete articles in the reader. */
.desktop-v4 #real-insight-list .insight-cover{height:160px;aspect-ratio:auto}
.r5-insight-pagination{display:flex;justify-content:space-between;align-items:center;gap:12px;margin:14px 0;color:var(--mm-muted);font-size:12px}
.r5-insight-pagination>div{display:flex;gap:8px}.r5-insight-pagination button{background:var(--mm-surface);border:1px solid #d6dfea;border-radius:8px;color:var(--mm-ink);padding:7px 12px}.r5-insight-pagination button:disabled{opacity:.4}
#real-insight-categories{scroll-margin-top:140px}
.r5-home-summary{padding:0;list-style:none;margin:12px 0;display:grid;gap:12px}.r5-home-summary li{display:grid;gap:3px}.r5-home-summary b{font-size:11px;color:#8b3b13}.r5-home-summary span{font-size:13px;line-height:1.7;color:var(--mm-ink)}
@media(max-width:760px){.desktop-v4 #real-insight-list .insight-cover{height:130px}.r5-insight-pagination{font-size:11px;gap:6px}.r5-insight-pagination button{padding:7px 9px}#real-insight-categories{scroll-margin-top:110px}}

@media(max-width:760px){.desktop-v4 #live-sort{flex:none!important;height:40px!important;min-height:40px!important;max-height:40px!important}}

/* Saved member analysis remains dated and compact. */
.r5-saved-report details{margin-top:14px}.r5-saved-report summary{cursor:pointer;color:#9e3c0b;font-weight:700}.r5-saved-report time{font-size:12px;color:var(--mm-muted)}.r5-saved-risks{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.r5-saved-risks article{min-width:0;padding:14px;border-radius:12px}.r5-saved-risks p{font-size:13px;line-height:1.65}.r5-saved-risks span{float:right;font-weight:700}.r5-saved-report .member-doc-block{padding:8px 0}.r5-saved-report .member-doc-block h4{font-size:13px;color:var(--mm-muted);margin:6px 0}@media(max-width:700px){.r5-saved-risks{grid-template-columns:1fr}.r5-saved-report .live-panel-title{align-items:flex-start;flex-wrap:wrap}}
