/* LF-SITE-001B — Market Intelligence runtime polish
   Presentation-only refinements from Matt's runtime recordings.
   No data, routing, calculation, scenario, news, quote, or interaction logic changes. */

:root{--ep-tool-subnav-height:34px}

/* Shared tool switcher: keep it useful, but give more vertical room back to the apps. */
.ep30-tool-subnav{
  min-height:34px!important;
  height:34px!important;
  padding:4px var(--ep31-pad)!important;
  gap:3px!important;
  align-items:center!important;
}
.ep30-tool-subnav-label{font-size:8px!important;margin-right:8px!important}
.ep30-tool-subnav a{padding:5px 9px!important;font-size:10px!important;line-height:1.1!important}

/* All tools begin immediately beneath the anchored global chrome. */
body[data-page="radar"] .radar-page,
body[data-page="market-weather"] .mw21-site,
body[data-page="strategy-lab"] .sl-app,
body[data-page="personal-dashboard"] .app-shell,
body[data-page="market-explainer"] .app{
  padding-top:calc(var(--ep-news-height) + var(--ep-nav-height) + var(--ep-tool-subnav-height))!important;
}

/* GLOBAL RADAR — preserve the 24/52/24 concept, reduce vertical bulk only. */
@media(min-width:1161px){
  body[data-page="radar"] .radar-page{padding-bottom:28px!important}
  body[data-page="radar"] .radar-heading-row{margin:10px 0 13px!important}
  body[data-page="radar"] .radar-heading-row h1{font-size:clamp(39px,2.8vw,52px)!important;margin:5px 0!important}
  body[data-page="radar"] .radar-frame-top{min-height:56px!important;padding:8px 17px!important}
  body[data-page="radar"] .radar-columns{min-height:530px!important}
  body[data-page="radar"] .radar-story,
  body[data-page="radar"] .radar-explainer{padding:15px 16px 13px!important}
  body[data-page="radar"] .radar-filters{margin:10px 0 9px!important}
  body[data-page="radar"] .radar-news-list{max-height:430px!important;gap:5px!important}
  body[data-page="radar"] .radar-news-item{min-height:69px!important;grid-template-columns:66px minmax(0,1fr)!important;padding:6px!important}
  body[data-page="radar"] .radar-news-thumb{width:66px!important;height:56px!important}
  body[data-page="radar"] .radar-globe-toolbar{min-height:40px!important;padding:8px 15px 6px!important}
  body[data-page="radar"] .radar-globe-wrap{min-height:400px!important}
}

/* MY MARKET DASHBOARD — rebalance the workstation and reduce admin-console bulk. */
@media(min-width:1181px){
  body[data-page="personal-dashboard"] .hero{height:138px!important;margin-bottom:8px!important}
  body[data-page="personal-dashboard"] .hero-copy{padding-top:16px!important}
  body[data-page="personal-dashboard"] .hero-callout{top:18px!important;height:102px!important}
  body[data-page="personal-dashboard"] .market-strip{height:78px!important;margin-left:30px!important;margin-right:30px!important}
  body[data-page="personal-dashboard"] .market-tile{padding:9px 13px!important}
  body[data-page="personal-dashboard"] .dashboard-shell{
    margin:10px 30px 16px!important;
    padding:13px!important;
    gap:13px!important;
    min-height:548px!important;
    grid-template-columns:minmax(0,30fr) minmax(0,43fr) minmax(0,27fr)!important;
  }
  body[data-page="personal-dashboard"] .watchlist-panel{min-height:0!important;padding:14px 15px!important}
  body[data-page="personal-dashboard"] .center-column{grid-template-rows:minmax(0,1fr) 202px!important;gap:13px!important}
  body[data-page="personal-dashboard"] .right-column{grid-template-rows:232px minmax(0,1fr)!important;gap:13px!important}
  body[data-page="personal-dashboard"] .lower-center-grid{gap:13px!important}
  body[data-page="personal-dashboard"] .performance-card{padding:14px 18px 13px!important}
  body[data-page="personal-dashboard"] .coverage-card,
  body[data-page="personal-dashboard"] .movers-card{padding-top:11px!important;padding-bottom:11px!important}
  body[data-page="personal-dashboard"] .coverage-list article{padding:7px 0!important}
}

/* AI MARKET EXPLAINER — utility/search remains, but no longer reads as another navigation bar. */
body[data-page="market-explainer"] .explainer-tools{
  height:42px!important;
  margin:8px 24px 0!important;
  padding:0!important;
  gap:9px!important;
  justify-content:flex-end!important;
  border:0!important;
  background:transparent!important;
}
body[data-page="market-explainer"] .explainer-tools .search{
  margin-left:0!important;
  width:min(360px,48vw)!important;
  height:34px!important;
  border-radius:9px!important;
  background:rgba(7,35,29,.72)!important;
  backdrop-filter:blur(8px);
}
body[data-page="market-explainer"] .explainer-tools .utility{font-size:18px!important;opacity:.78}
body[data-page="market-explainer"] .explainer-tools .avatar{padding:7px!important;font-size:10px!important}
body[data-page="market-explainer"] .hero{height:120px!important;padding-top:17px!important;padding-bottom:17px!important}
body[data-page="market-explainer"] .filters{height:48px!important;margin-top:0!important}
body[data-page="market-explainer"] .workspace{margin-top:0!important}
body[data-page="market-explainer"] .feed{height:calc(100vh - 228px)!important;min-height:610px!important}

/* STRATEGY LAB — spacing alignment only. Locked logic and application geometry stay intact. */
body[data-page="strategy-lab"] .sl-app .app-shell{padding-top:10px!important}
body[data-page="strategy-lab"] .sl-app .hero{margin-bottom:9px!important}

/* MARKET WEATHER — only align the top edge with the shared family chrome. */
body[data-page="market-weather"] .mw21-intro{margin-top:0!important}

@media(max-width:760px){
  :root{--ep-tool-subnav-height:38px}
  .ep30-tool-subnav{height:38px!important;min-height:38px!important;padding:4px 12px!important;justify-content:flex-start!important;overflow-x:auto!important}
  .ep30-tool-subnav-label{display:none!important}
  .ep30-tool-subnav a{padding:6px 9px!important}
  body[data-page="radar"] .radar-page,
  body[data-page="market-weather"] .mw21-site,
  body[data-page="strategy-lab"] .sl-app,
  body[data-page="personal-dashboard"] .app-shell,
  body[data-page="market-explainer"] .app{padding-top:calc(27px + 68px + var(--ep-tool-subnav-height))!important}
  body[data-page="market-explainer"] .explainer-tools{height:40px!important;margin:6px 14px 0!important}
  body[data-page="market-explainer"] .explainer-tools .search{width:auto!important;min-width:0!important;flex:1!important}
  body[data-page="market-explainer"] .explainer-tools .utility{display:none!important}
  body[data-page="market-explainer"] .hero{height:auto!important;min-height:118px!important}
}
