.writing-review-workspace{--review-ink:#142033;--review-muted:#526174;--review-line:#dce3ea;--review-paper:#fff;color:var(--review-ink);max-width:1400px;margin:auto}
.writing-review-workspace .review-toolbar{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:12px;margin-bottom:20px}
.writing-review-workspace .review-actions{display:flex;flex-wrap:wrap;gap:8px;align-items:center}
.writing-review-workspace .review-context{color:var(--review-muted);margin:4px 0 16px}
.writing-review-workspace .review-grid{display:grid;grid-template-columns:minmax(0,1fr) 340px;gap:24px;align-items:start}
.writing-review-workspace .review-paper{background:var(--review-paper);border:1px solid var(--review-line);border-radius:4px;padding:clamp(20px,4vw,48px);min-width:0;overflow-wrap:anywhere}
.writing-review-workspace .review-paper h2{font-size:1.4rem;line-height:1.4;margin:0 0 28px;color:var(--review-ink)}
.writing-review-workspace .review-paper .writing-document-rendered,.writing-review-workspace .review-plain-text{font:1.05rem/1.85 Georgia,serif;color:var(--review-ink)}
.writing-font-arial{font-family:Arial,sans-serif}
.writing-font-helvetica{font-family:Helvetica,Arial,sans-serif}
.writing-font-verdana{font-family:Verdana,sans-serif}
.writing-font-georgia{font-family:Georgia,serif}
.writing-font-times-new-roman{font-family:"Times New Roman",serif}
.writing-font-courier-new{font-family:"Courier New",Courier,monospace}
.writing-review-workspace .review-plain-text{white-space:pre-wrap}.writing-review-workspace .writing-document-paragraph{min-height:1.85em}
.writing-review-workspace .review-panel{background:var(--review-paper);border:1px solid var(--review-line);border-radius:12px;padding:22px;min-width:0}
.writing-review-workspace .review-panel h2{font-size:1.15rem;margin:0 0 12px;color:var(--review-ink)}
.writing-review-workspace .review-panel h3{font-size:1rem;margin:18px 0 8px;color:var(--review-ink)}
.writing-review-workspace .review-label{display:block;font-weight:600;margin:16px 0 6px;color:var(--review-ink)}
.writing-review-workspace textarea,.writing-review-workspace input,.writing-review-workspace select{font:inherit;background:#fff!important;color:var(--review-ink)!important;border:1px solid #98a7b8!important;border-radius:7px;padding:10px;width:100%;max-width:100%}
.writing-review-workspace textarea{min-height:180px;resize:vertical}.writing-review-workspace input[type=number]{max-width:150px}
.writing-review-workspace .review-state{display:inline-block;color:#145b51;background:#e7f3f0;border-radius:5px;padding:4px 9px;margin-bottom:14px;font-size:.85rem}
.writing-review-workspace .review-help{color:var(--review-muted);font-size:.9rem;line-height:1.55}
.writing-review-workspace .review-status{margin-top:12px;min-height:1.5em;white-space:pre-wrap;overflow-wrap:anywhere}
.writing-review-workspace .review-status[data-error=true]{color:#a51d2d}.writing-review-workspace .review-feedback-text{white-space:pre-wrap;overflow-wrap:anywhere}
.writing-review-workspace .review-section{border-top:1px solid var(--review-line);padding-top:16px;margin-top:20px}
.writing-review-workspace details>summary{cursor:pointer;min-height:44px;padding:10px 0;color:var(--review-ink)}
.writing-review-workspace .btn{min-height:44px;display:inline-flex;align-items:center;justify-content:center;white-space:normal}
.writing-review-workspace .btn-primary{background:#0f766e!important;border-color:#0f766e!important;color:#fff!important}
.writing-review-workspace a{color:#173f6b!important}.writing-review-workspace .btn-outline-secondary{background:#fff!important;border:1px solid #98a7b8!important;color:#173f6b!important}
.writing-review-workspace :is(.review-back-button,.review-continue-button){border-radius:8px;min-width:12rem;font-weight:600}
.writing-review-workspace .review-feedback-link{background:#e8f4f1!important;border:2px solid #a6cdc7!important;color:#0f766e!important;border-radius:8px;font-weight:600}
.writing-review-workspace .review-feedback-link:is(:hover,:focus-visible){background:#d4ebe6!important;border-color:#0f766e!important;color:#0c655f!important}
.writing-review-workspace :focus-visible{outline:3px solid #007eac!important;outline-offset:3px}
.writing-review-workspace .review-history-list{list-style:none;padding:0;margin:0}.writing-review-workspace .review-history-list li{padding:10px 0;border-bottom:1px solid var(--review-line)}
@media(max-width:1050px){.writing-review-workspace .review-grid{grid-template-columns:minmax(0,1fr) 300px;gap:16px}}
@media(max-width:800px){.writing-review-workspace .review-grid{grid-template-columns:1fr}.writing-review-workspace .review-panel{padding:20px}.writing-review-workspace .review-paper{padding:24px}}
.writing-review-workspace #passage-document{font:1.05rem/1.85 Georgia,serif;white-space:normal;overflow-wrap:anywhere}
.writing-review-workspace #passage-document [data-segment-start]{white-space:pre-wrap}
.writing-review-workspace .passage-highlight{background:#fff0b0;color:inherit;border-bottom:2px solid #aa7500;cursor:pointer;padding:0}
.writing-review-workspace .passage-comment-card{padding:14px 0;border-bottom:1px solid var(--review-line);scroll-margin-top:24px}
.writing-review-workspace .passage-comment-card h3{margin:0 0 8px}
.writing-review-workspace .passage-comment-card .btn{margin:4px 4px 0 0;font-size:.85rem}
.writing-review-workspace #passage-comments blockquote{border-left:3px solid #c5a553;padding:8px 12px;margin:12px 0;white-space:pre-wrap;overflow-wrap:anywhere;font-size:.9rem;background:#fffaf0}
.writing-review-workspace #passage-comment-text{min-height:100px}
.writing-review-workspace #passage-keyboard-text{min-height:220px;font:1rem/1.7 Georgia,serif}
.writing-review-workspace #passage-overlap button{display:block;margin:6px 0}
.writing-review-workspace .passage-break-comment{font: .8rem system-ui;min-height:30px;margin-left:6px}

.review-release-dialog{max-width:min(30rem,calc(100vw - 2rem));padding:24px;border:1px solid #d8e3e7;border-radius:14px;color:#173f6b;background:#fff;box-shadow:0 18px 48px #173f6b26}
.review-release-dialog::backdrop{background:rgb(23 42 60 / 35%)}
.review-release-dialog h2{font-size:1.4rem;font-weight:300;margin:0 0 12px}
.review-release-dialog p{line-height:1.6;margin-bottom:20px}
.review-release-dialog .review-actions{display:flex;gap:10px;flex-wrap:wrap}
.assignment-conversation{margin:24px auto;max-width:880px;padding:24px;border:1px solid #d8e3e7;border-radius:14px;background:#fff;color:#173f6b}
.student-feedback-stack { display:flex; flex-direction:column; gap:20px; min-width:0; }
.student-comment-popover { position:fixed; z-index:2000; width:min(340px,calc(100vw - 24px)); box-sizing:border-box; padding:18px; border:2px solid #779eaf; border-left:5px solid #c58b20; border-radius:12px; background:white; color:#173f6b; box-shadow:0 10px 35px #173f6b33; }
.student-comment-popover h3 { font-size:1.05rem; margin:0 0 12px; }
.student-comment-popover { max-height:calc(100vh - 24px); overflow:auto; }
.student-comment-popover p { white-space:pre-wrap; overflow-wrap:anywhere; }
.workspace-shell .student-comment-popover button { background:#e8f4f1!important; color:#0f766e!important; -webkit-text-fill-color:#0f766e; border:1px solid #8eb9b4; border-radius:6px; padding:8px 14px; }
.student-feedback-workspace #teacher-feedback > .assignment-conversation { border:0!important; border-top:1px solid #b8cada!important; border-radius:0!important; box-shadow:none!important; padding:16px 0 0!important; margin-top:18px!important; }
.student-feedback-workspace #teacher-feedback .conversation-header { display:none; }
.student-feedback-workspace #teacher-feedback-heading { color:#173f6b; font-weight:600; padding-left:12px; border-left:5px solid #c58b20; }
.revision-teacher-panel { padding:18px; border:2px solid #779eaf; border-radius:16px; background:white; color:#173f6b; margin-bottom:20px; }
.revision-teacher-panel h2 { font-size:1.25rem; font-weight:600; }
.workspace-shell .essay-workspace-grid:has(.revision-teacher-panel) { grid-template-columns:minmax(0,2fr) minmax(360px,1fr); }
@media(max-width:850px){.workspace-shell .essay-workspace-grid:has(.revision-teacher-panel){grid-template-columns:minmax(0,1fr);}}
.workspace-shell #mainContent .revision-teacher-panel a { color:#173f6b!important; }
.revision-teacher-panel .review-grade-summary { display:flex; justify-content:space-between; gap:12px; padding:12px; background:#fff8df; border:1px solid #e2be65; border-radius:8px; }
.revision-teacher-panel .review-feedback-callout { padding:14px; border-left:4px solid #c58b20; background:#edf6f4; margin:14px 0; }
.revision-teacher-panel .assignment-conversation { margin:16px 0 0; padding:12px; }
.revision-teacher-panel blockquote { border-left:4px solid #c58b20; padding-left:12px; background:#fff8df; }
.student-feedback-stack .assignment-conversation { margin:0; max-width:none; width:100%; box-sizing:border-box; }
.student-feedback-workspace .review-version-picker { color:#173f6b; border:1px solid #b8cada; border-radius:8px; padding:10px 14px; background:#edf3f9; }
.student-feedback-workspace #passage-review-history { width:100%; min-width:0; }
.student-feedback-workspace #teacher-feedback { scroll-margin-top:100px; }
.student-feedback-stack .conversation-compose { margin:12px 0 0; padding:16px; }
.student-feedback-stack .conversation-header { padding:12px 16px; background:#edf3f9; }
.student-feedback-stack .conversation-note { margin:14px 0; }
.student-feedback-stack .conversation-actions .btn { font-size:.85rem; padding:6px 10px; }
.student-feedback-workspace [hidden] { display:none!important; }
.workspace-shell .student-feedback-stack .assignment-conversation { margin-top:0!important; }
.workspace-shell .student-feedback-stack .conversation-compose textarea { min-height:110px; height:110px; }
.student-feedback-stack .conversation-compose summary { color:#173f6b; cursor:pointer; margin:12px 0; font-size:.9rem; }
.workspace-shell #mainContent .student-feedback-workspace .passage-comment-card .btn { background:#e8f4f1!important; color:#0f766e!important; border:1px solid #8eb9b4; border-radius:8px; }
.workspace-shell #mainContent .student-feedback-workspace .passage-comment-card .btn:is(:hover,:focus-visible) { background:#0f766e!important; color:#fff!important; }
.assignment-conversation h2,.assignment-conversation h3{font-weight:300}
.assignment-conversation h2{font-size:1.4rem}
.assignment-conversation h3{font-size:1rem;margin:0 0 4px}
.assignment-conversation .review-actions{display:flex;gap:10px;flex-wrap:wrap;margin:14px 0}
.assignment-conversation .review-label{display:block;margin:14px 0 6px}
.assignment-conversation textarea,.assignment-conversation select{display:block;box-sizing:border-box;width:100%;padding:10px;border:1px solid #b7cad4;border-radius:8px;background:#fff;color:#173f6b;font:inherit}
.assignment-conversation :focus-visible{outline:2px solid #0f766e;outline-offset:3px}
.assignment-conversation .conversation-history{max-height:420px;overflow:auto;overflow-wrap:anywhere;scrollbar-gutter:stable}
.assignment-conversation .conversation-message{padding:16px 4px;border-bottom:1px solid #d8e3e7}
.assignment-conversation .conversation-message p,.assignment-conversation blockquote{white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.6}
.assignment-conversation time,.assignment-conversation .review-help{font-size:.875rem;color:#526878}
.assignment-conversation [data-error=true]{color:#9b352d}
@media(max-width:600px){.assignment-conversation{padding:18px;max-width:100%}}
.workspace-shell .review-paper { border: 2px solid #779eaf; box-shadow: 0 5px 15px rgba(23,63,107,.07); }
.workspace-shell .review-panel { border: 2px solid #168078; border-top-width: 4px; }
.workspace-shell .review-progress { color: #173f6b; font-size: .9rem; }
.workspace-shell .review-advance-actions { border-top: 1px solid #cfdee4; margin-top: 1rem; padding-top: 1rem; }
.workspace-shell .review-advance-actions .review-help { margin-top: .5rem; }
.workspace-shell .review-passage-section { margin: 1rem 0; padding: .7rem 0; border-top: 1px solid #cfdee4; border-bottom: 1px solid #cfdee4; }
@media (min-width: 1100px) { .workspace-shell .review-grid { grid-template-columns: minmax(0, 1.45fr) minmax(360px, 1fr); } }

/* Submitted-writing actions and feedback cards use the shared Coach palette. */
.writing-review-workspace .writing-export-menu { position:relative; flex:none; }
.writing-review-workspace .writing-export-menu > summary { padding:8px 14px; border:1px solid #9bb5c1; border-radius:9px; background:#edf3f9; color:#173f6b; font-size:.9rem; font-weight:600; }
.writing-export-options { position:absolute; right:0; top:100%; margin-top:6px; min-width:210px; padding:6px; background:white; border:1px solid #9bb5c1; border-radius:10px; box-shadow:0 8px 22px #173f6b20; z-index:20; }
.writing-export-options a { display:block; padding:10px 12px; border-radius:6px; text-decoration:none; }
.writing-export-options a:hover,.writing-export-options a:focus-visible { background:#edf3f9; color:#173f6b!important; }
.assignment-conversation .conversation-header { border-left:5px solid #c58b1a; }
.assignment-conversation .conversation-compose { background:#edf3f9!important; border-color:#b8cada!important; }
.assignment-conversation #conversation-status,.assignment-conversation #conversation-empty { margin:14px 22px; }
.writing-review-workspace .review-secondary-toolbar {
  align-items: center;
  padding: 12px 0 16px;
  border-top: 1px solid #d8e3e7;
  border-bottom: 1px solid #d8e3e7;
}
.writing-review-workspace .review-downloads {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px;
}
.writing-review-workspace .review-download-label {
  color: #0f766e;
  font-size: .76rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  margin-right: 2px;
}
.writing-review-workspace .review-download-button {
  min-height: 42px;
  padding: 8px 13px;
  border-radius: 9px;
  border: 2px solid #9bb5c1 !important;
  background: #f5f9fb !important;
  color: #173f6b !important;
  font-weight: 600;
  text-decoration: none !important;
  transition: background-color .15s ease, border-color .15s ease, transform .15s ease;
}
.writing-review-workspace .review-download-button:hover,
.writing-review-workspace .review-download-button:focus-visible {
  background: #e7f1f5 !important;
  border-color: #173f6b !important;
  color: #173f6b !important;
  transform: translateY(-1px);
}
.writing-review-workspace .review-download-button--docx {
  border-color: #a6cdc7 !important;
  background: #e8f4f1 !important;
  color: #0f766e !important;
}
.writing-review-workspace .review-download-button--docx:hover,
.writing-review-workspace .review-download-button--docx:focus-visible {
  border-color: #0f766e !important;
  background: #d4ebe6 !important;
  color: #0c655f !important;
}
.writing-review-workspace .review-panel-heading {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 14px;
}
.writing-review-workspace .review-panel-eyebrow,
.assignment-conversation .review-panel-eyebrow {
  margin: 0 0 5px;
  color: #0f766e;
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .1em;
  line-height: 1.2;
  text-transform: uppercase;
}
.writing-review-workspace .review-panel-heading h2 {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 0 !important;
}
.writing-review-workspace .review-feedback-callout {
  margin: 14px 0 16px;
  padding: 14px 16px;
  border: 1px solid #a6cdc7;
  border-left: 5px solid #c58b1a;
  border-radius: 10px;
  background: #f3faf8;
}
.writing-review-workspace .review-feedback-callout-label {
  margin: 0 0 6px;
  color: #0f766e;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.writing-review-workspace .review-feedback-callout .review-feedback-text {
  margin: 0;
  line-height: 1.65;
}
.writing-review-workspace .review-grade-summary {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin: 0 0 14px;
  padding: 10px 13px;
  border: 1px solid #e4c675;
  border-radius: 9px;
  background: #fff8df;
  color: #173f6b;
}
.writing-review-workspace .review-grade-summary span {
  font-size: .84rem;
  font-weight: 600;
}
.writing-review-workspace .review-grade-summary strong {
  color: #173f6b;
  font-size: 1.2rem;
}
.writing-review-workspace .review-release-meta {
  margin: 0 0 8px;
  padding-top: 10px;
  border-top: 1px solid #d8e3e7;
}
.writing-review-workspace .review-empty-state {
  margin: 10px 0 16px;
  padding: 14px 16px;
  border: 1px dashed #a6cdc7;
  border-radius: 10px;
  background: #f7fbfa;
}
.writing-review-workspace .review-empty-state p { margin: 0; line-height: 1.55; }
.writing-review-workspace .review-section {
  margin-top: 16px;
  padding: 0;
  border: 1px solid #d2e0e4;
  border-radius: 10px;
  background: #f8fbfc;
  overflow: hidden;
}
.writing-review-workspace .review-section > summary {
  min-height: 0;
  padding: 12px 14px;
  color: #173f6b;
  font-weight: 600;
}
.writing-review-workspace .review-section > summary:hover { background: #edf5f6; }
.writing-review-workspace .review-section > :not(summary) { margin-left: 14px; margin-right: 14px; }

/* The conversation is a separate, full-width card below the paper and feedback. */
.assignment-conversation.review-panel {
  max-width: 1000px;
  margin: 28px auto 0;
  padding: 0;
  border: 2px solid #168078;
  border-top-width: 4px;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 7px 20px rgba(23,63,107,.08);
  overflow: hidden;
}
.assignment-conversation .conversation-header {
  padding: 18px 22px 14px;
  border-bottom: 1px solid #d8e3e7;
  background: linear-gradient(110deg, #f1f8f7 0%, #fff 75%);
}
.assignment-conversation .conversation-header h2 {
  margin: 0;
  color: #142033;
  font-size: 1.4rem;
  font-weight: 300;
}
.assignment-conversation .conversation-intro {
  margin: 18px 22px 3px;
  color: #173f6b;
  font-weight: 600;
  line-height: 1.5;
}
.assignment-conversation #conversation-recipient,
.assignment-conversation .conversation-note {
  margin-left: 22px;
  margin-right: 22px;
}
.assignment-conversation .conversation-actions {
  margin: 14px 22px;
}
.assignment-conversation .btn {
  min-height: 42px;
  border-radius: 8px;
  font-weight: 600;
}
.assignment-conversation .btn-primary {
  border-color: #0f766e !important;
  background: #0f766e !important;
  color: #fff !important;
}
.assignment-conversation .btn-outline-secondary {
  border: 2px solid #a6cdc7 !important;
  background: #e8f4f1 !important;
  color: #0f766e !important;
}
.assignment-conversation .btn-outline-secondary:hover,
.assignment-conversation .btn-outline-secondary:focus-visible {
  border-color: #0f766e !important;
  background: #d4ebe6 !important;
  color: #0c655f !important;
}
.assignment-conversation .conversation-history {
  max-height: 420px;
  margin: 0 22px;
  padding: 0 14px;
  border: 1px solid #d2e0e4;
  border-radius: 10px;
  background: #f8fbfc;
}
.assignment-conversation .conversation-message {
  padding: 16px 4px;
  border-bottom: 1px solid #d8e3e7;
}
.assignment-conversation .conversation-message:last-child { border-bottom: 0; }
.assignment-conversation .conversation-message h3 {
  display: inline;
  margin: 0 8px 0 0;
  color: #173f6b;
  font-weight: 700;
}
.assignment-conversation .conversation-message time {
  color: #526878;
  font-size: .82rem;
}
.assignment-conversation .conversation-message p {
  margin: 8px 0 6px;
}
.assignment-conversation .conversation-message a {
  display: inline-flex;
  padding: 5px 9px;
  border: 1px solid #a6cdc7;
  border-radius: 7px;
  background: #e8f4f1;
  color: #0f766e !important;
  font-size: .88rem;
  font-weight: 600;
  text-decoration: none;
}
.assignment-conversation .conversation-compose {
  margin: 18px 22px 22px;
  padding: 16px;
  border: 1px solid #cfdee4;
  border-radius: 10px;
  background: #f5f9fa;
}
.assignment-conversation .conversation-compose .review-label { margin-top: 12px; }
.assignment-conversation .conversation-compose .review-actions { margin: 14px 0 0; }
.assignment-conversation #conversation-uncertain,
.assignment-conversation #conversation-rejected {
  margin: 14px 22px;
  padding: 12px 14px;
  border: 1px solid #e4c675;
  border-radius: 9px;
  background: #fff8df;
}
@media(max-width:800px){
  .writing-review-workspace .review-downloads { width: 100%; justify-content: flex-start; }
  .writing-review-workspace .review-download-label { width: 100%; }
}
@media(max-width:600px){
  .assignment-conversation.review-panel { margin-top: 20px; }
  .assignment-conversation .conversation-header { padding: 16px 18px 13px; }
  .assignment-conversation .conversation-intro,
  .assignment-conversation #conversation-recipient,
  .assignment-conversation .conversation-note,
  .assignment-conversation .conversation-actions,
  .assignment-conversation .conversation-history,
  .assignment-conversation .conversation-compose,
  .assignment-conversation #conversation-uncertain,
  .assignment-conversation #conversation-rejected { margin-left: 18px; margin-right: 18px; }
}

/* Revision comments are display overlays, separate from saved editor formats. */
::highlight(teacher-comments) { background:#fff0ad; color:#173f6b; }
.workspace-shell .draft-comment-bar { display:flex; gap:.5rem; flex-wrap:wrap; padding:.5rem 1rem; background:#fffaf0; }
.workspace-shell .draft-comment-bar:empty { display:none; }
.workspace-shell .draft-comment-bar button { color:#173f6b; background:#fff7df; border:1px solid #c58b20; border-radius:8px; padding:.35rem .65rem; font-size:.85rem; }
.workspace-shell .draft-comment-bubble { position:fixed; z-index:1100; box-sizing:border-box; max-height:calc(100vh - 24px); overflow:auto; background:white; border:2px solid #c58b20; border-radius:14px; padding:1rem; box-shadow:0 8px 28px #173f6b30; color:#173f6b; }
.workspace-shell .draft-comment-bubble h3 { font-size:1rem; font-weight:700; display:inline-block; margin:0 1rem .75rem 0; }
.workspace-shell .draft-comment-bubble blockquote { border-left:3px solid #c58b20; background:#fff7df; padding:.6rem; margin:.6rem 0; font-size:.9rem; }
.workspace-shell .draft-comment-bubble button { color:white; background:#0f766e; border:0; border-radius:8px; padding:.45rem .8rem; }
.workspace-shell .draft-comment-bubble label { display:block; font-size:.9rem; }
.workspace-shell .draft-comment-bubble textarea { width:100%; box-sizing:border-box; border:1px solid #8baabc; border-radius:8px; padding:.6rem; margin:.4rem 0; }
.workspace-shell .draft-comment-bubble article { border-top:1px solid #d8e3e7; padding:.5rem 0; }
.workspace-shell .revision-teacher-panel .conversation-header { display:block; padding:0; }
.workspace-shell .revision-teacher-panel .conversation-header h2 { font-size:1.05rem; font-weight:700; }
.workspace-shell .revision-teacher-panel .conversation-history { margin:.7rem 0; padding:0; border:0; background:white; }
.workspace-shell .revision-teacher-panel .conversation-compose { margin:.7rem 0; }
.workspace-shell .revision-teacher-panel .conversation-actions { margin:0; }
.workspace-shell .revision-teacher-panel .conversation-compose > details { display:none; }
.workspace-shell .teacher-support-card { margin:1rem 0; padding:1.2rem; border:2px solid #8baabc; border-top:4px solid #c58b20; border-radius:14px; background:white; color:#173f6b; }
.workspace-shell .teacher-support-card h2 { font-size:1.2rem; font-weight:700; }
.workspace-shell .teacher-support-card button { padding:.5rem .8rem; border:1px solid #0f766e; border-radius:8px; background:#e8f4f1; color:#173f6b; }
.workspace-shell .teacher-support-card small { display:block; color:#58677a; margin:.5rem 0; }
.workspace-shell .teacher-support-finding, .workspace-shell .revision-comment-status { padding:1rem; margin:1rem 0; border-radius:10px; background:#edf3f9; }
.workspace-shell .teacher-support-finding h3 {font-size:1rem;font-weight:700;}
.workspace-shell .teacher-support-card blockquote { border-left:3px solid #c58b20; background:#fff7df; padding:.7rem; margin:.7rem 0; white-space:pre-wrap; }
.workspace-shell .support-review-link { display:block; margin-top:.8rem; color:#173f6b; }
.workspace-shell .revision-comparison-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:1rem; }
.workspace-shell .revision-source-text { white-space:pre-wrap; color:#223349; line-height:1.7; }
@media(max-width:850px){.workspace-shell .revision-comparison-grid {grid-template-columns:1fr;}}
.workspace-shell .revision-source-text mark { background:#fff0ad; color:#173f6b; }
.workspace-shell .revision-comparison-grid > :nth-child(2) .revision-source-text mark {background:#dff2e3;}
.workspace-shell #mainContent .revision-evidence-page .review-actions {display:flex;flex-wrap:wrap;gap:10px;margin:14px 0;}
.workspace-shell #mainContent .revision-evidence-page :is(.btn,button) {background:#e8f4f1!important;color:#0f766e!important;-webkit-text-fill-color:#0f766e;border:1px solid #8eb9b4!important;border-radius:8px;padding:.55rem .85rem;font-weight:600;}
.workspace-shell #mainContent .revision-evidence-page [data-support-request] {background:#0f766e!important;color:#fff!important;-webkit-text-fill-color:#fff;border-color:#0f766e!important;}
.workspace-shell #mainContent .revision-evidence-page :is(.btn,button):is(:hover,:focus-visible):not(:disabled) {background:#0c655f!important;color:#fff!important;-webkit-text-fill-color:#fff;border-color:#0c655f!important;}
.workspace-shell #mainContent .revision-evidence-page :is(.btn,button):focus-visible {outline:3px solid #c58b20;outline-offset:3px;}
.workspace-shell #mainContent .revision-evidence-page button:disabled {opacity:1;background:#edf3f9!important;color:#526174!important;-webkit-text-fill-color:#526174;border-color:#b8cada!important;cursor:not-allowed;}
.revision-evidence-page .support-status:empty {display:none;}
.teacher-support-card .support-preferences-link {display:block;width:fit-content;margin:10px 0;color:#0f766e!important;-webkit-text-fill-color:#0f766e;text-decoration:underline;}
.teacher-support-card .support-preferences-link:focus-visible {outline:3px solid #c58b20;outline-offset:3px;}

/* Teacher grading workspace: make the review context and student queue easy to scan. */
.workspace-shell #mainContent .teacher-grading-workspace .review-header {padding:14px 18px;gap:14px;margin-top:14px;}
.workspace-shell #mainContent .teacher-grading-workspace .review-header h1 {font-size:1.45rem;}
.workspace-shell #mainContent .teacher-grading-workspace .review-student-navigation {padding:7px;}
.workspace-shell #mainContent .teacher-grading-workspace .review-header-meta {font-size:.8rem;}
.workspace-shell #mainContent .teacher-grading-workspace .btn-outline-secondary {background:#e8f4f1!important;border:1px solid #8eb9b4!important;color:#0f766e!important;-webkit-text-fill-color:#0f766e;font-weight:600;border-radius:9px;}
.workspace-shell #mainContent .teacher-grading-workspace .btn-outline-secondary:is(:hover,:focus-visible),
.workspace-shell #mainContent .teacher-grading-workspace .review-back-link:is(:hover,:focus-visible) {background:#0f766e!important;color:#fff!important;-webkit-text-fill-color:#fff;border-color:#0f766e!important;}
.workspace-shell #mainContent .teacher-grading-workspace .btn-primary {color:#fff!important;-webkit-text-fill-color:#fff;background:#173f6b!important;border-color:#173f6b!important;}
.teacher-grading-sidebar {display:flex;flex-direction:column;gap:18px;min-width:0;}
.teacher-grade-pair {display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.3fr);gap:12px;margin-bottom:22px;align-items:start;}
.teacher-grade-entry,.teacher-coach-estimate {padding:8px 10px;border:1px solid #dabc66;border-radius:10px;background:#fff8df;min-width:0;}
.teacher-coach-estimate {background:#edf3f9;border-color:#b8cada;}
.teacher-grading-workspace .teacher-grade-pair .review-label,.teacher-grading-workspace .teacher-grade-pair h3 {margin:0 0 4px;font-weight:700;font-size:.95rem;color:#173f6b;line-height:1.3;}
.teacher-grade-pair p {font-size:.85rem;margin:6px 0;}
.teacher-grading-workspace #review-state[hidden],.teacher-inline-comment-store {display:none!important;}
.teacher-grading-sidebar .assignment-conversation.review-panel {margin:0;max-width:none;width:100%;}
.teacher-grading-sidebar .conversation-header h2 {font-size:1.15rem;font-weight:650;}
.teacher-grading-sidebar .conversation-compose {margin:12px;padding:12px;}
.teacher-grading-sidebar .conversation-compose textarea {min-height:85px;}
.teacher-grading-sidebar .conversation-actions:has(>button[hidden]:first-child):has(>button[hidden]:last-child) {display:none;}
.teacher-grading-workspace .teacher-support-card {border:0;box-shadow:none;padding:0;margin:12px;}
.teacher-grading-workspace #review-feedback #review-heading {font-weight:650;color:#173f6b;font-size:1.25rem;}
.teacher-grading-workspace #review-feedback .review-status:empty {display:none;}
.teacher-comment-popover {position:fixed;z-index:1200;width:350px;max-width:calc(100vw - 24px);max-height:calc(100vh - 100px);overflow:auto;padding:16px;background:white;color:#173f6b;border:2px solid #c58b20;border-radius:12px;box-shadow:0 8px 30px #173f6b33;}
.teacher-comment-popover h3 {font-size:1rem;font-weight:700;display:inline-block;margin:0 12px 12px 0;}
.workspace-shell .teacher-comment-popover button,.workspace-shell .teacher-selection-comment {background:#0f766e!important;color:#fff!important;-webkit-text-fill-color:#fff;border:1px solid #0f766e;border-radius:8px;padding:7px 12px;margin:4px;font-weight:600;}
.teacher-selection-comment {position:fixed;z-index:1190;}
.teacher-selection-comment[hidden] {display:none;}
.teacher-comment-popover blockquote {margin:10px 0;padding:10px;background:#fff8df;border-left:3px solid #c58b20;white-space:pre-wrap;}
.teacher-comment-popover p {white-space:pre-wrap;overflow-wrap:anywhere;}
.teacher-comment-popover textarea {width:100%;min-height:100px;box-sizing:border-box;padding:10px;border:1px solid #8baabc;border-radius:8px;}
.teacher-comment-popover #passage-composer > .review-help,.teacher-comment-popover #passage-use-selection,.teacher-comment-popover .passage-keyboard-selector {display:none;}
@media(max-width:600px){.teacher-grade-pair{grid-template-columns:1fr;}}
.workspace-shell .app-header.review-page-header { display: none; }
.workspace-shell .writing-review-workspace .review-header {
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  gap: 22px;
  margin: 0 0 18px;
  padding: 20px 22px;
  border: 2px solid #168078;
  border-top: 5px solid #c58b20;
  border-radius: 16px;
  background: linear-gradient(110deg, #f8fbfb 0%, #fff 62%, #edf3f9 100%);
  box-shadow: 0 8px 24px rgba(23, 63, 107, .08);
}
.workspace-shell .writing-review-workspace .review-header-main {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  min-width: 0;
}
.workspace-shell .writing-review-workspace .review-back-link {
  flex: none;
  align-self: flex-start;
  margin-top: 2px;
  padding: 8px 11px;
  border: 1px solid #a6cdc7;
  border-radius: 9px;
  background: #e8f4f1;
  color: #0f766e !important;
  font-weight: 700;
  text-decoration: none;
}
.workspace-shell .writing-review-workspace .review-back-link:hover,
.workspace-shell .writing-review-workspace .review-back-link:focus-visible {
  background: #d4ebe6;
  border-color: #0f766e;
  color: #0c655f !important;
}
.workspace-shell .writing-review-workspace .review-header-copy { min-width: 0; }
.workspace-shell .writing-review-workspace .review-eyebrow,
.workspace-shell .writing-review-workspace .review-tools-label {
  margin: 0 0 5px;
  color: #0f766e;
  font-size: .75rem;
  font-weight: 800;
  letter-spacing: .11em;
  line-height: 1.2;
  text-transform: uppercase;
}
.workspace-shell .writing-review-workspace .review-header-copy h1 {
  margin: 0;
  color: #173f6b;
  font-size: clamp(1.35rem, 2.4vw, 2rem);
  font-weight: 650;
  line-height: 1.18;
  overflow-wrap: anywhere;
}
.workspace-shell .writing-review-workspace .review-assignment-title {
  margin: 5px 0 0;
  color: #334f6c;
  font-size: 1.08rem;
  font-weight: 600;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.workspace-shell .writing-review-workspace .review-header-meta {
  margin: 7px 0 0;
  color: #526878;
  font-size: .88rem;
  line-height: 1.4;
}
.workspace-shell .writing-review-workspace .review-student-navigation {
  flex: 0 1 340px;
  min-width: 260px;
  align-self: center;
  padding: 11px;
  border: 1px solid #b8cada;
  border-radius: 12px;
  background: rgba(237, 243, 249, .82);
}
.workspace-shell .writing-review-workspace .review-student-position {
  margin: 0 0 8px;
  color: #173f6b;
  font-size: .82rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-align: center;
  text-transform: uppercase;
}
.workspace-shell .writing-review-workspace .review-student-nav-controls {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.workspace-shell .writing-review-workspace .review-student-nav-button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
  min-height: 50px;
  padding: 8px 10px;
  border: 1px solid #a6cdc7;
  border-radius: 9px;
  background: #fff;
  color: #173f6b !important;
  text-decoration: none;
  transition: background-color .15s ease, border-color .15s ease, transform .15s ease;
}
.workspace-shell .writing-review-workspace .review-student-nav-button:hover,
.workspace-shell .writing-review-workspace .review-student-nav-button:focus-visible {
  border-color: #0f766e;
  background: #e8f4f1;
  color: #0c655f !important;
  transform: translateY(-1px);
}
.workspace-shell .writing-review-workspace .review-student-nav-button--next {
  border-color: #0f766e;
  background: #0f766e;
  color: #fff !important;
}
.workspace-shell .writing-review-workspace .review-student-nav-button--next:hover,
.workspace-shell .writing-review-workspace .review-student-nav-button--next:focus-visible {
  border-color: #0c655f;
  background: #0c655f;
  color: #fff !important;
}
.workspace-shell .writing-review-workspace .review-student-nav-button.is-disabled {
  cursor: default;
  opacity: .62;
}
.workspace-shell .writing-review-workspace .review-student-nav-button span:not(.review-student-nav-arrow) {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.workspace-shell .writing-review-workspace .review-student-nav-button small {
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .06em;
  line-height: 1.2;
  text-transform: uppercase;
}
.workspace-shell .writing-review-workspace .review-student-nav-button strong {
  overflow: hidden;
  font-size: .82rem;
  font-weight: 700;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.workspace-shell .writing-review-workspace .review-student-nav-arrow {
  flex: none;
  font-size: 1.35rem;
  line-height: 1;
}
.workspace-shell .writing-review-workspace .review-secondary-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px 18px;
  margin: 0 0 18px;
  padding: 12px 14px;
  border: 1px solid #cfdee4;
  border-radius: 12px;
  background: #fff;
}
.workspace-shell .writing-review-workspace .review-toolbar-group {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.workspace-shell .writing-review-workspace .review-toolbar-group--secondary { justify-content: flex-end; }
.workspace-shell .writing-review-workspace .review-toolbar-group .review-tools-label { margin: 0 5px 0 0; }
.workspace-shell .writing-review-workspace .review-secondary-toolbar .btn {
  min-height: 38px;
  padding: 7px 12px;
  font-size: .88rem;
}
.workspace-shell .writing-review-workspace .review-paper {
  min-height: 560px;
  border-radius: 14px;
  background: #fff;
}
.workspace-shell .writing-review-workspace .review-paper h2 {
  color: #173f6b;
  font-size: 1.5rem;
  font-weight: 550;
}
.workspace-shell .writing-review-workspace .review-panel {
  border-radius: 14px;
  box-shadow: 0 7px 20px rgba(23, 63, 107, .07);
}
.workspace-shell .writing-review-workspace .review-panel > #review-heading {
  color: #173f6b;
  font-size: 1.35rem;
  font-weight: 650;
}
.workspace-shell .writing-review-workspace .review-panel > #review-heading .context-help-trigger { margin-left: 4px; }
@media (max-width: 900px) {
  .workspace-shell .writing-review-workspace .review-header { flex-direction: column; }
  .workspace-shell .writing-review-workspace .review-student-navigation { flex: none; width: 100%; max-width: none; }
}
@media (max-width: 600px) {
  .workspace-shell .writing-review-workspace .review-header { padding: 16px; }
  .workspace-shell .writing-review-workspace .review-header-main { flex-direction: column; gap: 10px; }
  .workspace-shell .writing-review-workspace .review-student-nav-controls { grid-template-columns: 1fr; }
  .workspace-shell .writing-review-workspace .review-secondary-toolbar { align-items: stretch; flex-direction: column; }
  .workspace-shell .writing-review-workspace .review-toolbar-group--secondary { justify-content: flex-start; }
}

#mainContent .teacher-grading-workspace .teacher-grade-pair {align-items:stretch;}
#mainContent .teacher-grading-workspace .teacher-grade-pair > div {height:100%;box-sizing:border-box;}
#mainContent .teacher-grading-workspace .teacher-grade-value-row {display:flex;align-items:center;gap:8px;min-width:0;}
#mainContent .teacher-grading-workspace .teacher-grade-entry :is(input,select) {width:5rem;min-width:0;flex:0 1 5rem;height:34px;min-height:34px;padding:4px 7px;margin:0;border:1px solid #a9c3d4;border-radius:6px;background:white;color:#173f6b;}
#mainContent .teacher-grading-workspace .teacher-grade-entry select {width:100%;flex:1;}
#mainContent .teacher-grading-workspace .teacher-grade-scale {font-size:.75rem;line-height:1.25;color:#526878;overflow-wrap:anywhere;}
#mainContent .teacher-grading-workspace .teacher-grade-entry:has(select) .teacher-grade-value-row {flex-wrap:wrap;}

/* Keep the review queue compact so the writing stays close to its context. */
.workspace-shell #mainContent .teacher-grading-workspace .review-header {padding:8px 14px;gap:12px;}
.workspace-shell #mainContent .teacher-grading-workspace .review-header-copy {display:flex;flex-wrap:wrap;align-items:baseline;column-gap:10px;row-gap:3px;}
.workspace-shell #mainContent .teacher-grading-workspace .review-eyebrow {margin:0;font-size:.7rem;}
.workspace-shell #mainContent .teacher-grading-workspace .review-header-copy h1 {flex:1;font-size:1.3rem;}
.workspace-shell #mainContent .teacher-grading-workspace .review-assignment-title {flex-basis:100%;margin:0;font-size:.95rem;}
.workspace-shell #mainContent .teacher-grading-workspace .review-header-meta {flex-basis:100%;margin:0;font-size:.75rem;}
.workspace-shell #mainContent .teacher-grading-workspace .review-student-navigation {padding:6px;}
.workspace-shell #mainContent .teacher-grading-workspace .review-student-position {margin-bottom:4px;font-size:.7rem;}
.workspace-shell #mainContent .teacher-grading-workspace .review-student-nav-button {min-height:40px;padding:5px 8px;}
