/*
 * Edusentia Enterprise | Phase 9 Report Card Workspace
 * Native modal dialog with accessible section tabs and compact, persistent
 * report actions. All existing assessment and authorisation logic is reused.
 */
.eds-enterprise-ui dialog.eds-report-dialog {
  box-sizing:border-box;
  width:min(1180px,calc(100vw - 36px));
  height:min(920px,calc(100dvh - 32px));
  max-height:calc(100dvh - 32px);
  max-width:none;
  margin:auto;
  padding:0;
  border:1px solid #ccdbee;
  border-radius:20px;
  background:#f6f9fd;
  color:#193452;
  box-shadow:0 38px 110px rgba(2,23,55,.38);
  overflow:hidden;
}
.eds-enterprise-ui dialog.eds-report-dialog::backdrop{
  background:rgba(4,18,46,.72);
  backdrop-filter:blur(5px);
}
.eds-report-shell {
  height:100%;
  min-height:0;
  display:flex;
  flex-direction:column;
}
.eds-report-shell-head {
  flex:0 0 auto;
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:20px;
  padding:15px 22px;
  background:linear-gradient(110deg,#09265e 0%,#124482 60%,#145d90 100%);
  color:#fff;
}
.eds-report-brand{
  min-width:0;
  display:flex;
  align-items:center;
  gap:13px;
}
.eds-report-brand img{
  width:46px;
  height:46px;
  flex:0 0 46px;
  padding:4px;
  object-fit:contain;
  background:#fff;
  border-radius:12px;
  box-shadow:0 5px 16px rgba(4,24,60,.2);
}
.eds-report-brand h2{
  margin:0;
  font-size:18px;
  line-height:1.25;
  font-weight:850;
  color:#fff;
}
.eds-report-brand p{
  margin:3px 0 0;
  font-size:12px;
  color:#d6eafa;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  max-width:min(680px,65vw);
}
.eds-report-close{
  flex:0 0 auto;
  border:1px solid rgba(255,255,255,.4);
  background:rgba(255,255,255,.13);
  color:#fff;
  border-radius:10px;
  display:inline-flex;
  gap:7px;
  align-items:center;
  justify-content:center;
  min-height:40px;
  padding:7px 13px;
  cursor:pointer;
  font-size:13px;
  font-weight:750;
}
.eds-report-close span:first-child{font-size:21px;line-height:1}
.eds-report-close:hover{background:rgba(255,255,255,.23)}
.eds-report-close:focus-visible,
.eds-report-tab:focus-visible{
  outline:3px solid #75d6c6;
  outline-offset:2px;
}
.eds-report-workspace{
  min-height:0;
  flex:1;
  display:flex;
  flex-direction:column;
  background:#fff;
}
.eds-report-workspace > .eds-report-student-heading{
  flex:0 0 auto;
  border-bottom:1px solid #e2eaf5;
  padding:14px 22px;
  gap:12px;
}
.eds-report-student-heading .cell-main{
  min-width:0;
  flex:1 1 230px;
}
.eds-report-student-heading .cell-copy h3{
  font-size:17px;
  color:#12365e;
}
.eds-report-student-heading .cell-copy p{
  white-space:normal;
  line-height:1.5;
}
.eds-report-student-heading .page-actions{
  margin-left:auto;
  display:flex;
  gap:7px;
  flex-wrap:wrap;
  align-items:center;
}
.eds-report-student-heading .page-actions .button{
  min-height:36px;
}
.eds-report-metrics{
  flex:0 0 auto;
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:10px;
  padding:12px 20px 9px;
  background:#f6f9fd;
}
.eds-report-metric{
  min-width:0;
  display:flex;
  flex-direction:column;
  gap:3px;
  padding:10px 14px;
  border:1px solid #dce6f2;
  border-radius:12px;
  background:#fff;
}
.eds-report-metric-label{
  color:#647995;
  font-size:11px;
  font-weight:750;
  letter-spacing:.025em;
}
.eds-report-metric strong{
  color:#153966;
  font-size:18px;
  font-weight:850;
  line-height:1.3;
  text-transform:capitalize;
}
.eds-report-metric small{
  color:#8090a4;
  font-size:10px;
}
.eds-report-tabs{
  flex:0 0 auto;
  display:flex;
  gap:5px;
  align-items:end;
  overflow-x:auto;
  scrollbar-width:thin;
  padding:10px 20px 0;
  border-bottom:1px solid #dce5f0;
  background:#fff;
}
.eds-report-tab{
  position:relative;
  flex:0 0 auto;
  border:0;
  border-bottom:3px solid transparent;
  border-radius:9px 9px 0 0;
  padding:11px 15px 10px;
  background:transparent;
  color:#56708f;
  font:inherit;
  font-size:13px;
  font-weight:750;
  cursor:pointer;
  white-space:nowrap;
}
.eds-report-tab:hover{background:#eff5fc;color:#184b87}
.eds-report-tab[aria-selected="true"]{
  background:#edf5ff;
  border-bottom-color:#147fc4;
  color:#0b4384;
}
.eds-report-tab-count{
  display:inline-block;
  margin-left:7px;
  padding:2px 6px;
  border-radius:16px;
  background:#dfebf9;
  color:#214b7a;
  font-size:10px;
  vertical-align:middle;
}
.eds-report-workspace > .eds-report-body{
  flex:1 1 auto;
  min-height:0;
  padding:0;
  overflow:hidden;
}
.eds-report-menu-form{
  display:flex!important;
  flex-direction:column;
  gap:0!important;
  height:100%;
  min-height:0;
  margin:0;
}
.eds-report-pane{
  flex:1 1 auto;
  min-height:0;
  overflow-y:auto;
  overscroll-behavior:contain;
  padding:20px 22px 26px;
  scroll-padding-top:18px;
  scrollbar-width:thin;
}
.eds-report-pane[hidden]{display:none!important}
.eds-report-pane .form-grid{gap:14px 18px}
.eds-report-pane .form-grid > .field{
  border:1px solid #e1e9f2;
  border-radius:12px;
  padding:10px 12px;
  background:#fff;
}
.eds-report-pane .form-grid > .field > span:first-child{
  color:#35516f;
  font-weight:750;
}
.eds-report-pane .form-grid .field input,
.eds-report-pane .form-grid .field textarea{
  min-width:0;
  width:100%;
}
.eds-report-pane .form-grid > p.muted {
  grid-column:1/-1;
  line-height:1.55;
  font-size:12px;
}
.eds-report-pane .table-wrap{
  max-width:100%;
  margin-top:12px;
  border:1px solid #dce6f2;
  border-radius:12px;
  overflow-x:auto;
  overflow-y:visible;
}
.eds-report-pane .table-wrap table{min-width:760px}
.eds-report-pane .panel.pad{margin:0 0 14px}
.eds-report-actions-footer{
  flex:0 0 auto;
  padding:12px 20px;
  background:#fff;
  border-top:1px solid #dce6f2;
  box-shadow:0 -7px 25px rgba(30,65,112,.05);
}
.eds-report-actions-footer .eds-report-action-buttons{
  display:flex;
  justify-content:flex-end;
  align-items:center;
  gap:8px;
  flex-wrap:wrap;
  margin:0;
}
.eds-report-actions-footer .form-message:not(.hidden){
  display:block;
  margin:0 0 9px;
  max-height:90px;
  overflow:auto;
}
.eds-report-actions-footer .button{
  min-height:39px;
  font-size:12px;
}
@media(max-width:780px){
  .eds-enterprise-ui dialog.eds-report-dialog{
    width:calc(100vw - 16px);
    height:calc(100dvh - 16px);
    max-height:calc(100dvh - 16px);
    border-radius:15px;
  }
  .eds-report-shell-head{padding:12px 15px}
  .eds-report-brand img{height:39px;width:39px;flex-basis:39px}
  .eds-report-brand h2{font-size:15px}
  .eds-report-brand p{max-width:55vw;font-size:11px}
  .eds-report-workspace > .eds-report-student-heading{padding:10px 15px}
  .eds-report-metrics{grid-template-columns:repeat(2,minmax(0,1fr));gap:7px;padding:9px 12px}
  .eds-report-metric{padding:7px 10px}
  .eds-report-metric strong{font-size:15px}
  .eds-report-metric small{display:none}
  .eds-report-tabs{padding:5px 10px 0}
  .eds-report-tab{padding:10px 12px;font-size:12px}
  .eds-report-pane{padding:14px 13px}
  .eds-report-actions-footer{padding:10px 12px}
}
@media(max-width:450px){
  .eds-report-close{width:38px;min-width:38px;padding:5px}
  .eds-report-close-caption{display:none}
  .eds-report-student-heading .page-actions{
    flex:1 1 100%;
    overflow-x:auto;
    flex-wrap:nowrap;
    max-width:100%;
  }
  .eds-report-student-heading .page-actions > *{flex:0 0 auto}
  .eds-report-actions-footer .eds-report-action-buttons{
    justify-content:flex-start;
    flex-wrap:nowrap;
    overflow-x:auto;
    padding-bottom:4px;
    scrollbar-width:thin;
  }
  .eds-report-actions-footer .button{flex:0 0 auto}
}
@media(prefers-reduced-motion:reduce){
  .eds-report-dialog *{scroll-behavior:auto!important}
}
@media print{
  .eds-enterprise-ui dialog.eds-report-dialog{position:static;height:auto;max-height:none;box-shadow:none}
  .eds-report-shell-head,.eds-report-tabs,.eds-report-actions-footer{display:none!important}
  .eds-report-pane{overflow:visible}
}
