/* v1.0.118 — readable Reports balance and resilient intelligence panel. */
.workspace.reports-mode .module-content{overflow:visible}
.reports-command{width:min(100%,1560px);margin:0 auto;gap:14px}

/* Keep the compact hierarchy, but restore comfortable reading scale. */
.reports-command .operational-intelligence>header{
  grid-template-columns:minmax(220px,.8fr) minmax(460px,1.45fr) minmax(210px,.65fr);
  min-height:78px;
  padding:12px 16px;
  gap:20px;
}
.intelligence-heading span{font-size:8px!important}
.intelligence-heading h3{margin:4px 0 2px!important;font-size:18px!important}
.intelligence-heading p{font-size:9px!important}
.reports-command .intelligence-period{gap:8px}
.reports-command .intelligence-period label span{margin-bottom:4px;font-size:8px}
.reports-command .intelligence-period input,
.reports-command .intelligence-period button{height:36px;font-size:9px}
.reports-command .intelligence-period button{padding-inline:13px}
.reports-command .intelligence-state{min-height:48px;padding:9px 10px 9px 38px}
.reports-command .intelligence-state>i{left:15px;top:20px;width:8px;height:8px}
.reports-command .intelligence-state small{font-size:7px}
.reports-command .intelligence-state b{margin-top:4px;font-size:10px;line-height:1.35}
.reports-command .intelligence-metric{min-height:78px;padding:12px 14px}
.reports-command .intelligence-metric small{color:#9bb4c1;font-size:8px}
.reports-command .intelligence-metric b{margin:6px 0 4px;font-size:22px}
.reports-command .intelligence-metric span{color:#b1c5ce;font-size:8px}
.reports-command .intelligence-metric:after{right:10px;bottom:9px;font-size:6px;opacity:.85}
.intelligence-sources>summary{min-height:39px;padding:9px 14px;font-size:9px}
.intelligence-sources>summary span,.intelligence-sources>summary b{font-size:8px}
.intelligence-sources>summary i{font-size:8px}
.reports-command .intelligence-source-bar{padding:10px 13px}
.reports-command .intelligence-source-bar a{font-size:8px}

/* The report toolbar is compact but no longer microscopic. */
.report-register-toolbar{
  grid-template-columns:minmax(190px,.65fr) minmax(520px,1.65fr) minmax(150px,.5fr);
  min-height:76px;
  padding:12px 16px;
  gap:20px;
}
.report-register-toolbar>div:first-child>span{font-size:8px}
.report-register-toolbar h3{font-size:18px}
.report-register-toolbar p{display:block;margin:3px 0 0;font-size:9px}
.report-counts{min-height:44px;background:#f8fafb}
.report-count{min-width:96px;gap:9px;padding:8px 11px}
.report-count small{color:#4e6a79;font-size:8px;font-weight:800}
.report-count b{font-size:17px}
.report-register-state{font-size:9px}
.reports-command .report-board>header{min-height:54px;padding:10px 14px}
.reports-command .report-board>header span{font-size:8px}
.reports-command .report-board>header h3{margin-top:2px;font-size:13px}
.reports-command .report-board>header>b{min-width:30px;height:30px;font-size:11px}
.reports-command .report-board>div{padding:8px}
.reports-command .report-command-group>header{padding:9px 12px;font-size:9px}
.reports-command .report-command-row{min-height:90px;padding:12px;gap:14px}
.reports-command .report-command-main small,.reports-command .report-period small{font-size:8px}
.reports-command .report-command-main>b{font-size:13px}
.reports-command .report-command-main>span,.reports-command .report-period em{font-size:9px}
.reports-command .report-period b{font-size:12px}
.reports-command .report-command-control em{font-size:9px}
.reports-command .report-command-control small{font-size:8px;line-height:1.35}

/* Fixed, readable detail panel with a footer that can never escape its width. */
.intelligence-detail-panel[open]{width:min(520px,100vw);box-sizing:border-box}
.intelligence-detail-panel,
.intelligence-detail-panel *{box-sizing:border-box}
.intelligence-detail-shell>header{padding:18px 20px}
.intelligence-detail-shell>header small{color:#7ff1e5;font-size:9px}
.intelligence-detail-shell>header h2{font-size:21px}
.intelligence-detail-close{flex:0 0 38px;width:38px;height:38px}
.intelligence-detail-body{gap:13px!important;padding:17px 20px!important;background:#f4f7f9}
.intelligence-detail-context{padding:11px 13px;border-left-width:3px;background:#e3f1f2}
.intelligence-detail-context b{color:#173b50;font-size:12px}
.intelligence-detail-context span{color:#526f7f;font-size:10px}
.intelligence-detail-summary{border-color:#c5d4dc;box-shadow:0 4px 12px rgba(9,39,57,.05)}
.intelligence-detail-summary>div{min-height:45px!important;padding:10px 12px!important}
.intelligence-detail-summary small{color:#31586c!important;font-size:9px!important;font-weight:800!important;letter-spacing:.03em}
.intelligence-detail-summary b{color:#082f47!important;font-size:14px!important}
.intelligence-detail-note{margin:0!important;padding:11px 13px;color:#38596a!important;background:#e7f1f3;font-size:10px!important;line-height:1.55!important}
.intelligence-detail-actions{
  display:grid!important;
  grid-template-columns:minmax(0,1fr) auto;
  gap:10px!important;
  width:100%;
  padding:14px 20px!important;
  overflow:hidden;
}
.intelligence-detail-actions a,
.intelligence-detail-actions button{display:flex;align-items:center;justify-content:center;width:auto;min-width:0;max-width:100%;margin:0;white-space:nowrap}
.intelligence-detail-actions button{min-width:82px}

@media(max-width:1280px){
  .reports-command{width:100%}
  .reports-command .operational-intelligence>header{grid-template-columns:minmax(190px,.75fr) minmax(420px,1.7fr)}
  .reports-command .intelligence-state{display:none}
  .report-register-toolbar{grid-template-columns:minmax(170px,.6fr) minmax(480px,1.7fr)}
  .report-register-state{display:none}
}
@media(max-width:980px){
  .reports-command .operational-intelligence>header{grid-template-columns:1fr}
  .reports-command .intelligence-period{grid-template-columns:1fr 1fr auto auto}
  .reports-command .intelligence-metrics{grid-template-columns:repeat(3,minmax(0,1fr))}
  .report-register-toolbar{grid-template-columns:1fr}
  .report-counts{width:100%}
  .report-count{flex:1;min-width:0}
}
@media(max-width:680px){
  .reports-command .intelligence-period{grid-template-columns:1fr 1fr}
  .reports-command .intelligence-metrics{grid-template-columns:1fr 1fr}
  .report-counts{display:grid;grid-template-columns:1fr 1fr}
  .report-count{min-height:40px}
  .intelligence-detail-panel[open]{width:100vw}
  .intelligence-detail-actions{grid-template-columns:1fr}
  .intelligence-detail-actions button{width:100%}
}
