/*
 * Edusentia Enterprise | Phase 3: leadership and teaching operations.
 * SBA-quality presentation for Principal, Class Teacher, Subject Teacher,
 * Teacher Planning Library and assigned academic/attendance views.
 * Strictly presentation-only. No permissions, grading, API or PDF changes.
 */
.eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .stat-grid,
.eds-enterprise-ui #content:has(> .eds-teacher-dashboard-head) .stat-grid{
  gap:clamp(11px,1.5vw,16px);
  margin-bottom:17px;
}
.eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .stat-card,
.eds-enterprise-ui #content:has(> .eds-teacher-dashboard-head) .stat-card{
  min-height:113px;
  border-color:#d7e5f3;
  background:linear-gradient(145deg,#fff 0%,#fafdff 100%);
}
.eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .stat-card strong,
.eds-enterprise-ui #content:has(> .eds-teacher-dashboard-head) .stat-card strong{
  font-size:clamp(22px,2vw,29px);
  line-height:1.2;
  color:#123f74;
}
.eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .grid.two,
.eds-enterprise-ui #content:has(> .eds-teacher-dashboard-head) .grid.two{
  gap:clamp(12px,1.5vw,19px);
}
.eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .panel,
.eds-enterprise-ui #content:has(> .eds-teacher-dashboard-head) .panel{
  min-width:0;
  border-color:#dae7f3;
}
.eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .metric-row,
.eds-enterprise-ui #content:has(> .eds-teacher-dashboard-head) .metric-row{
  gap:9px;
}
.eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .metric,
.eds-enterprise-ui #content:has(> .eds-teacher-dashboard-head) .metric{
  background:linear-gradient(165deg,#f5f9ff,#fff);
  border:1px solid #e0eaf6;
  border-radius:11px;
  min-width:0;
  padding:13px;
}
.eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .metric strong,
.eds-enterprise-ui #content:has(> .eds-teacher-dashboard-head) .metric strong{
  color:#15467a;
  font-variant-numeric:tabular-nums;
}
.eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .bar-list,
.eds-enterprise-ui #content:has(> .eds-teacher-dashboard-head) .bar-list{
  gap:15px;
}
.eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .bar-item,
.eds-enterprise-ui #content:has(> .eds-teacher-dashboard-head) .bar-item{
  min-width:0;
}
.eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .bar-item label,
.eds-enterprise-ui #content:has(> .eds-teacher-dashboard-head) .bar-item label{
  color:#405b78;
  font-size:12px;
  line-height:1.4;
  overflow-wrap:anywhere;
}
.eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .progress,
.eds-enterprise-ui #content:has(> .eds-teacher-dashboard-head) .progress{
  background:#e4edfa;
  margin-top:15px;
}
.eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .progress>span,
.eds-enterprise-ui #content:has(> .eds-teacher-dashboard-head) .progress>span{
  background:linear-gradient(100deg,#105ed2,#00a777);
}
.eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .signature-panel{
  overflow:hidden;
}
.eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .signature-preview-wrap{
  border:1px dashed #b9d0e9;
  border-radius:14px;
  background:linear-gradient(145deg,#f6faff,#fff);
  min-height:155px;
  display:grid;
  place-items:center;
}
.eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .signature-empty{
  color:#617b98;
  font-size:12px;
  line-height:1.55;
}
.eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .signature-layout{
  gap:clamp(14px,2vw,23px);
  align-items:center;
}
.eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .signature-panel .form-stack{
  min-width:0;
}
.eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .signature-panel input[type="file"]{
  max-width:100%;
}

/* Keep the verified Teacher Library navigation contract and identity. The
   section tabs show which operation is active; keyboard focus remains visible. */
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-workspace-tabs{
  background:#f4f8fe;
  border:1px solid #dce8f5;
  border-radius:14px;
  margin:2px 0 21px;
  padding:7px;
  box-shadow:0 3px 13px rgba(26,67,122,.035);
  scroll-padding-inline:9px;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-workspace-tab{
  min-height:44px;
  border-radius:10px;
  color:#365777;
  background:transparent;
  font-size:13px;
  font-weight:750;
  padding:10px 15px;
  transition:background 180ms ease,border-color 180ms ease,color 180ms ease;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-workspace-tab:hover{
  background:#e7f1ff;
  border-color:#c7daf0;
  color:#13477f;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-workspace-tab[aria-selected="true"]{
  background:linear-gradient(130deg,#103d83,#1067bb);
  color:#fff;
  border-color:#0d5195;
  box-shadow:0 6px 14px rgba(15,66,135,.18);
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-workspace-tab:focus-visible{
  outline:3px solid #f3ae4c;
  outline-offset:1px;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-library-welcome{
  background:linear-gradient(145deg,#f0f7ff,#fff 76%);
  border:1px solid #cddff2;
  border-radius:17px;
  padding:clamp(19px,2.3vw,28px);
  box-shadow:0 9px 24px rgba(10,51,104,.06);
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-library-welcome>h4{
  color:#103a73;
  font-size:clamp(18px,1.75vw,22px);
  line-height:1.3;
  margin:0 0 8px;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-library-welcome>p{
  max-width:850px;
  color:#506b87;
  font-size:13px;
  line-height:1.65;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-library-metrics{
  gap:clamp(9px,1.2vw,14px);
  margin:19px 0 15px;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-library-metric{
  min-width:0;
  background:#fff;
  border:1px solid #dce8f4;
  border-radius:14px;
  padding:clamp(13px,1.5vw,19px);
  min-height:108px;
  box-shadow:0 6px 18px rgba(18,60,107,.045);
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-library-metric strong{
  font-size:clamp(23px,2.2vw,32px);
  color:#104f94;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-library-metric span{
  color:#254b75;
  font-size:12px;
  font-weight:800;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-library-metric small{
  color:#698199;
  font-size:11px;
  line-height:1.5;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-library-shortcuts{
  gap:9px;
  margin-top:18px;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) :is(.teacher-library-day-grid,.teacher-library-week-fields){
  gap:clamp(9px,1.3vw,15px);
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-library-check{
  background:#f8fbff;
  border:1px solid #cfdeef;
  border-radius:11px;
  color:#315674;
  font-size:12px;
  font-weight:750;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-library-check:has(input:checked){
  background:#eaf5ff;
  border-color:#76aedb;
  color:#154774;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-library-check:has(input:focus-visible){
  outline:3px solid #73b4ef;
  outline-offset:2px;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-library-week-fields .field,
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-library-lesson-fields .field{
  min-width:0;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) :is(.teacher-library-week-fields,.teacher-library-lesson-fields) textarea{
  border:1px solid #cbddef;
  background:#fff;
  border-radius:11px;
  color:#173b63;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-library-template{
  background:linear-gradient(145deg,#f7fbff,#fff);
  border:1px solid #d8e7f5;
  border-radius:13px;
  box-shadow:0 3px 13px rgba(16,66,112,.035);
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-library-template strong{
  color:#1a426e;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .panel.pad>h4,
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .panel-header h4{
  color:#153e6c;
  font-weight:850;
  letter-spacing:-.015em;
  line-height:1.4;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .panel.pad:not(.teacher-library-welcome){
  border:1px solid #dce8f4;
  border-radius:15px;
  background:#fff;
  box-shadow:0 6px 21px rgba(13,51,101,.04);
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .panel.pad .table-wrap{
  max-width:100%;
  overflow:auto;
  border:1px solid #e0e9f4;
  border-radius:11px;
  scrollbar-width:thin;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .panel.pad .table-wrap>table th{
  background:#f1f6fd;
  color:#345978;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .panel.pad .table-wrap>table td{
  line-height:1.55;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .panel.pad .table-wrap>table td:last-child .button-row{
  display:flex;
  flex-wrap:wrap;
  gap:7px;
  min-width:0;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .panel.pad details{
  border-radius:10px;
  border:1px solid #e3ebf5;
  background:#f9fbfe;
  padding:10px;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .panel.pad details>summary{
  font-weight:750;
  color:#235481;
  cursor:pointer;
}
.eds-enterprise-ui #content:has(.teacher-workspace-tabs) .panel.pad details>summary:focus-visible{
  outline:2px solid #105ed2;
  outline-offset:3px;
}

/* Actual teacher detail/attendance workflows, provided by the canonical
   Class/Subject Teacher registrar. All buttons keep the original handlers. */
.eds-enterprise-ui #content .teacher-profile-layout>.panel{
  border:1px solid #dbe7f4;
  border-radius:16px;
  min-width:0;
}
.eds-enterprise-ui #content .teacher-profile-hero{
  background:linear-gradient(115deg,#edf6ff,#fff);
  border:1px solid #d9e7f7;
  border-radius:14px;
  padding:16px;
  gap:15px;
}
.eds-enterprise-ui #content .teacher-profile-hero h3{
  color:#153e70;
}
.eds-enterprise-ui #content .profile-detail-grid>div,
.eds-enterprise-ui #content .teacher-profile-layout .verify-field{
  border:1px solid #e0ebf6;
  border-radius:11px;
  background:#f7fbff;
}
.eds-enterprise-ui #content .attendance-live-summary{
  gap:8px;
  padding:11px 0;
}
.eds-enterprise-ui #content .attendance-summary-chip{
  border:1px solid #dce8f4;
  border-radius:999px;
  padding:8px 12px;
  font-weight:750;
}
.eds-enterprise-ui #content .attendance-student-card{
  border:1px solid #dbe8f5;
  border-radius:15px;
  box-shadow:0 6px 18px rgba(16,55,99,.045);
  background:#fff;
}
.eds-enterprise-ui #content .attendance-status-button{
  border-radius:9px;
  min-height:40px;
}
.eds-enterprise-ui #content .attendance-status-button:focus-visible,
.eds-enterprise-ui #content .attendance-sticky-save .button:focus-visible{
  outline:3px solid #105ed2;
  outline-offset:2px;
}
.eds-enterprise-ui #content .attendance-sticky-save{
  border-radius:13px;
  border:1px solid #cbdff1;
  background:#f7fbff;
  box-shadow:0 7px 23px rgba(14,60,113,.08);
  gap:12px;
}
.eds-enterprise-ui #content .attendance-sticky-save strong{
  color:#1b4373;
}
@media(max-width:800px){
  .eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .metric-row,
  .eds-enterprise-ui #content:has(> .eds-teacher-dashboard-head) .metric-row{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
}
@media(max-width:620px){
  .eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .signature-layout{
    display:grid;
    grid-template-columns:1fr;
  }
  .eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .page-actions,
  .eds-enterprise-ui #content:has(> .eds-teacher-dashboard-head) .page-actions{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:8px;
  }
  .eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .page-actions .button,
  .eds-enterprise-ui #content:has(> .eds-teacher-dashboard-head) .page-actions .button{
    min-width:0;
    width:100%;
    white-space:normal;
    text-align:center;
    line-height:1.35;
  }
  .eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-workspace-tabs{
    border-radius:11px;
    margin:0 0 16px;
    padding:5px;
  }
  .eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-workspace-tab{
    font-size:12px;
    min-height:42px;
    padding:9px 12px;
  }
  .eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-library-metric{
    min-height:96px;
  }
  .eds-enterprise-ui #content .attendance-sticky-save{
    flex-wrap:wrap;
    gap:9px;
  }
  .eds-enterprise-ui #content .attendance-sticky-save .button{
    min-width:0;
  }
}
@media(max-width:390px){
  .eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .page-actions,
  .eds-enterprise-ui #content:has(> .eds-teacher-dashboard-head) .page-actions{
    grid-template-columns:1fr;
  }
}
@media(prefers-reduced-motion:reduce){
  .eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-workspace-tab,
  .eds-enterprise-ui #content .attendance-status-button{transition:none}
}
@media(forced-colors:active){
  .eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-workspace-tab[aria-selected="true"]{
    background:Highlight;
    color:HighlightText;
    border-color:HighlightText;
  }
}
@media print{
  .eds-enterprise-ui #content:has(.teacher-workspace-tabs) .teacher-library-metric,
  .eds-enterprise-ui #content:has(.teacher-workspace-tabs) .panel.pad,
  .eds-enterprise-ui #content:has(> .eds-principal-dashboard-head) .panel{
    box-shadow:none;
  }
}
