/* ClaimTrack Core 4.2.57 — Fase 1 reference dashboard.
 *
 * This layer restores the operational Fase 1 composition without changing the
 * shared sidebar, topbar, footer, or any Fase 2–4 layout. */

html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1:not(.ct-stop-loss-dashboard) .ct-ref-kpi-grid{
  grid-template-columns:repeat(5,minmax(0,1fr))!important;
}

@media (min-width:1201px){
  html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1:not(.ct-stop-loss-dashboard) .ct-ref-top-grid{
    grid-template-columns:repeat(4,minmax(0,1fr))!important;
    grid-template-rows:minmax(0,1fr) minmax(0,1fr)!important;
    grid-auto-rows:auto!important;
  }
  html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1:not(.ct-stop-loss-dashboard) .ct-position-full-card{
    grid-column:1 / span 2!important;
    grid-row:1 / span 2!important;
  }
  html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1:not(.ct-stop-loss-dashboard) .ct-phase1-uker-rank{
    grid-column:3!important;
    grid-row:1!important;
  }
  html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1:not(.ct-stop-loss-dashboard) .ct-phase1-uker-donut{
    grid-column:4!important;
    grid-row:1!important;
  }
  html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1:not(.ct-stop-loss-dashboard) .ct-phase1-area-donut--reference{
    grid-column:1!important;
    grid-row:2!important;
  }
  html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1:not(.ct-stop-loss-dashboard) .ct-phase1-product-donut{
    grid-column:2!important;
    grid-row:2!important;
  }
  html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1:not(.ct-stop-loss-dashboard) .ct-phase1-image-stack{
    display:grid!important;
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    grid-column:3 / span 2!important;
    grid-row:2!important;
    gap:10px!important;
    height:100%!important;
    min-height:0!important;
    padding-top:0!important;
  }
  html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1:not(.ct-stop-loss-dashboard) .ct-phase1-image-stack .ct-phase1-visual-card{
    width:100%!important;
    height:100%!important;
    min-height:0!important;
    aspect-ratio:auto!important;
  }
}

html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1:not(.ct-stop-loss-dashboard) .ct-phase1-area-donut--reference,
html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1:not(.ct-stop-loss-dashboard) .ct-phase1-product-donut{
  display:flex!important;
  min-width:0!important;
  flex-direction:column!important;
}
html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1:not(.ct-stop-loss-dashboard) .ct-phase1-area-donut--reference > h2,
html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1:not(.ct-stop-loss-dashboard) .ct-phase1-product-donut > h2{
  min-height:18px!important;
  margin:0 0 8px 5px!important;
}
html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1:not(.ct-stop-loss-dashboard) .ct-phase1-area-donut--reference > .ct-ref-chart-card,
html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1:not(.ct-stop-loss-dashboard) .ct-phase1-product-donut > .ct-ref-chart-card{
  flex:1 1 auto!important;
  min-height:0!important;
}

html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1 .ct-ref-nominative-filter-grid{
  grid-template-columns:repeat(2,minmax(0,1fr))!important;
}
html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1 .ct-phase1-filter-block .ct-ref-nominative-filter-fields{
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
}

@media (max-width:1200px){
  html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1:not(.ct-stop-loss-dashboard) .ct-ref-kpi-grid{
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
  }
  html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1:not(.ct-stop-loss-dashboard) .ct-position-full-card{
    grid-column:1 / span 2!important;
  }
  html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1:not(.ct-stop-loss-dashboard) .ct-phase1-image-stack{
    grid-column:1 / -1!important;
  }
}

@media (max-width:700px){
  html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1:not(.ct-stop-loss-dashboard) .ct-ref-kpi-grid,
  html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1 .ct-ref-nominative-filter-grid{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
  }
  html body .ct-app.ct-view-claim-phase[data-ct-phase-code="KDP"] .ct-ref-phase--1 .ct-phase1-filter-block .ct-ref-nominative-filter-fields{
    grid-template-columns:1fr!important;
  }
}
