/* Minimal, site-wide persistent study bar. No modal overlay when collapsed. */
#toefl-study-supervisor,
#toefl-study-supervisor *,
.toefl-study-drawer,
.toefl-study-drawer * {box-sizing:border-box}
#toefl-study-supervisor {
  position:sticky !important;top:0;left:0;right:0;z-index:2147482000;
  width:100%;height:64px;min-height:64px;
  display:flex;align-items:center;gap:16px;
  margin:0;padding:8px clamp(12px,2.2vw,30px);
  font-family:"Segoe UI","Microsoft YaHei",system-ui,sans-serif;
  font-size:13px;line-height:1.3;letter-spacing:normal;
  color:#172f38;background:#fff;border:0;border-bottom:1px solid #cbd6dc;
  box-shadow:0 2px 8px rgba(33,49,58,.04);
}
#toefl-study-supervisor .toefl-study-identity {
  display:flex;align-items:baseline;flex-wrap:wrap;column-gap:8px;row-gap:2px;
  flex:0 1 245px;min-width:120px;
}
#toefl-study-supervisor .toefl-study-brand{font-size:15px;font-weight:750;color:#153a45}
#toefl-study-supervisor .toefl-study-day{font-size:11px;color:#687b83;white-space:nowrap}
#toefl-study-supervisor .toefl-study-middle{min-width:150px;flex:1;max-width:500px}
#toefl-study-supervisor .toefl-study-measure{display:flex;align-items:baseline;justify-content:space-between;gap:8px;margin-bottom:6px;font-variant-numeric:tabular-nums}
#toefl-study-supervisor .toefl-study-number{font-family:Consolas,"Courier New",monospace;font-size:20px;color:#143d46;font-weight:800;white-space:nowrap;letter-spacing:.025em;font-variant-numeric:tabular-nums;transition:color .15s ease}
#toefl-study-supervisor .toefl-study-timer-status{font-size:11px;font-weight:750;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:#7b858f}
#toefl-study-supervisor[data-timer="running"] .toefl-study-number,
#toefl-study-supervisor[data-timer="running"] .toefl-study-timer-status{color:#167548}
#toefl-study-supervisor[data-timer="paused"] .toefl-study-number,
#toefl-study-supervisor[data-timer="paused"] .toefl-study-timer-status,
#toefl-study-supervisor[data-timer="disconnected"] .toefl-study-number,
#toefl-study-supervisor[data-timer="disconnected"] .toefl-study-timer-status{color:#b42332}
#toefl-study-supervisor[data-timer="pending"] .toefl-study-number{color:#6f7c85}
#toefl-study-supervisor .toefl-study-target{font-size:12px;color:#72818a;white-space:nowrap}
#toefl-study-supervisor .toefl-study-track{width:100%;height:5px;border-radius:8px;background:#e7edee;overflow:hidden}
#toefl-study-supervisor .toefl-study-track-fill{width:0;height:100%;background:#146a66;transition:width .5s ease}
#toefl-study-supervisor .toefl-study-stats{display:flex;min-width:180px;flex:0 1 310px;flex-direction:column;gap:1px}
#toefl-study-supervisor .toefl-study-hint{font-size:11px;color:#29454b;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#toefl-study-supervisor .toefl-study-todo{font-size:11px;color:#6d818b;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#toefl-study-supervisor[data-state="behind"] .toefl-study-hint{color:#a85820}
#toefl-study-supervisor[data-state="behind"] .toefl-study-track-fill{background:#c58b3f}
#toefl-study-supervisor[data-state="done"] .toefl-study-track-fill{background:#2e8b58}
#toefl-study-supervisor .toefl-study-actions{flex:0 0 auto}
#toefl-study-supervisor .toefl-study-toggle{
  display:inline-flex;align-items:center;justify-content:center;
  font:600 12px/1.2 "Segoe UI","Microsoft YaHei",sans-serif;
  padding:10px 13px;min-height:37px;background:#f5f7f8;border:1px solid #c9d7dd;
  border-radius:8px;color:#204953;white-space:nowrap;cursor:pointer;
}
#toefl-study-supervisor .toefl-study-toggle:hover{background:#eaf1f2}
.toefl-study-drawer[hidden]{display:none!important}
.toefl-study-drawer{
  position:fixed;z-index:2147482001;top:72px;right:12px;width:min(440px,calc(100vw - 24px));
  max-height:min(78vh,750px);overflow-y:auto;overscroll-behavior:contain;
  padding:17px 18px 20px;color:#24363b;background:#fff;
  border:1px solid #cbd6db;border-radius:13px;
  box-shadow:0 16px 50px rgba(18,37,43,.18);
  font:13px/1.5 "Segoe UI","Microsoft YaHei",system-ui,sans-serif;
}
.toefl-study-drawer .toefl-study-drawer-head{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-bottom:12px}
.toefl-study-drawer .toefl-study-drawer-head strong{font-size:17px;color:#223b42}
.toefl-study-drawer .toefl-study-drawer-head small{display:block;font-size:11px;color:#758b90;margin-top:2px}
.toefl-study-drawer .toefl-study-close{border:0;background:#f0f3f4;border-radius:7px;width:32px;height:32px;color:#586f76;font-size:23px;line-height:1;cursor:pointer}
.toefl-study-drawer .toefl-study-drawer-summary{display:grid;grid-template-columns:1fr 1fr;gap:6px;margin:5px 0 15px}
.toefl-study-drawer .toefl-study-drawer-summary>div{background:#f5f8f8;border:1px solid #edf1f3;border-radius:7px;padding:11px 9px;text-align:center;font-size:12px;color:#24525b}
.toefl-study-drawer .toefl-study-drawer-summary>div:last-child{grid-column:1/-1}
.toefl-study-drawer .toefl-study-panel{margin:0 0 15px;padding:0 0 13px;border-bottom:1px solid #e5ecef}
.toefl-study-drawer .toefl-study-panel h3{font-size:14px;line-height:1.3;font-weight:700;margin:0 0 9px;color:#1c3b43}
.toefl-study-drawer .toefl-study-panel p{margin:5px 0;font-size:12px;color:#5e7580}
.toefl-study-drawer .toefl-study-panel .toefl-study-note{color:#8a633e}
.toefl-study-drawer .toefl-study-blocks{display:grid;gap:5px;margin-top:12px}
.toefl-study-drawer .toefl-study-block{display:grid;grid-template-columns:105px 1fr auto;gap:7px;align-items:center;padding:8px;background:#f7f9fa;border-radius:6px;font-size:11px}
.toefl-study-drawer .toefl-study-block strong{font-weight:650;font-size:12px}
.toefl-study-drawer .toefl-study-target-row{display:flex;justify-content:space-between;gap:9px;padding:8px 2px;border-bottom:1px dashed #e7ebed;font-size:12px}
.toefl-study-drawer .toefl-study-target-row strong{color:#295761;font-variant-numeric:tabular-nums}
.toefl-study-drawer .toefl-study-muted{font-size:11px;line-height:1.65;color:#77878b}
.toefl-study-drawer .toefl-study-link{display:block;text-align:center;text-decoration:none;background:#eaf1f2;border-radius:8px;padding:10px;color:#19535d;font-weight:650}
@media(max-width:850px){
 #toefl-study-supervisor{gap:10px;height:58px;min-height:58px;padding:7px 12px}
 #toefl-study-supervisor .toefl-study-identity{display:none}
 #toefl-study-supervisor .toefl-study-stats{min-width:100px;flex-basis:190px}
 #toefl-study-supervisor .toefl-study-middle{min-width:120px}
 #toefl-study-supervisor .toefl-study-number{font-size:17px}
 #toefl-study-supervisor .toefl-study-toggle{padding:9px;font-size:11px}
 .toefl-study-drawer{top:66px}
}
@media(max-width:510px){
 #toefl-study-supervisor{gap:7px;padding:6px 8px}
 #toefl-study-supervisor .toefl-study-middle{min-width:133px;flex-grow:1}
 #toefl-study-supervisor .toefl-study-number{font-size:15px}
 #toefl-study-supervisor .toefl-study-target{font-size:10px}
 #toefl-study-supervisor .toefl-study-stats{min-width:66px;flex:0 1 110px}
 #toefl-study-supervisor .toefl-study-hint{font-size:10px}
 #toefl-study-supervisor .toefl-study-todo{display:none}
 #toefl-study-supervisor .toefl-study-toggle{font-size:10px;padding:8px 5px;min-height:33px}
 .toefl-study-drawer{right:6px;width:calc(100vw - 12px);top:64px;padding:13px}
 .toefl-study-drawer .toefl-study-block{grid-template-columns:94px 1fr auto;gap:4px}
}
/* Existing dashboard/sidebar needs its own sticky offset beneath the tutor. */
.toefl-study-enabled .sidebar{top:64px;height:calc(100vh - 64px)}
@media(max-width:850px){.toefl-study-enabled .sidebar{top:58px;height:calc(100vh - 58px)}}
/* Exam question panes must fit after the always-visible 64px study bar. */
.toefl-study-enabled .exam{min-height:calc(100vh - 64px)}
.toefl-study-enabled .exam-body{max-height:calc(100vh - 225px)}
@media(max-width:850px){
 .toefl-study-enabled .exam{min-height:calc(100vh - 58px)}
 .toefl-study-enabled .exam-body{max-height:calc(100vh - 219px)}
}
