:root {
  --bg: #f6f9fc;
  --panel: #fff;
  --line: #d9e2ef;
  --text: #102033;
  --muted: #64748b;
  --brand: #2563eb;
  --accent: #2563eb;
  --accent-2: #0f9f78;
  --soft-blue: #eff6ff;
  --soft-green: #ecfdf5;
  --shadow: 0 18px 50px rgba(15, 23, 42, .10);
}

* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  color: var(--text);
  background: var(--bg);
}

.topbar {
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 18px;
  background: rgba(255, 255, 255, .96);
  color: var(--text);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 8px 22px rgba(15, 23, 42, .05);
}
.topbar span { margin-left: 10px; color: var(--muted); font-size: 13px; }
.topbar a { color: #0f172a; text-decoration: none; font-weight: 800; }
.topbar-home-link {
  display: inline-block;
  color: #0f172a;
}
.topbar nav {
  display: flex;
  align-items: center;
  gap: 10px;
}
.topbar .auth-status {
  max-width: 260px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.topbar-button {
  padding: 6px 9px;
  background: #eef6ff;
  color: #1d4ed8;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 700;
}
.topbar-button.is-pulsing {
  animation: progressPulse .75s ease;
}

.queue-flyer {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 80;
  width: 34px;
  height: 26px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: #2563eb;
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  box-shadow: 0 10px 26px rgba(37, 99, 235, .28);
  pointer-events: none;
  transform: translate(var(--from-x), var(--from-y)) translate(-50%, -50%);
  animation: queueFly .82s cubic-bezier(.22, .8, .28, 1) forwards;
}

@keyframes queueFly {
  0% {
    opacity: 0;
    transform: translate(var(--from-x), var(--from-y)) translate(-50%, -50%) scale(.78);
  }
  16% {
    opacity: 1;
  }
  72% {
    opacity: 1;
    transform: translate(var(--to-x), var(--to-y)) translate(-50%, -50%) scale(1);
  }
  100% {
    opacity: 0;
    transform: translate(var(--to-x), var(--to-y)) translate(-50%, -50%) scale(.55);
  }
}

@keyframes progressPulse {
  0%, 100% {
    background: #eef6ff;
    box-shadow: none;
  }
  40% {
    background: #dbeafe;
    box-shadow: 0 0 0 5px rgba(37, 99, 235, .12);
  }
}

.home-page {
  min-height: 100vh;
  background: #f8fafc;
}
.home-topbar {
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 0 clamp(18px, 5vw, 72px);
  background: rgba(255, 255, 255, .94);
  border-bottom: 1px solid #e2e8f0;
}
.home-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #0f172a;
  text-decoration: none;
  font-size: 18px;
  font-weight: 800;
}
.home-brand-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #2563eb;
  color: #fff;
  font-weight: 800;
}
.home-nav {
  display: flex;
  align-items: center;
  gap: 16px;
}
.home-nav a {
  color: #475569;
  text-decoration: none;
  font-size: 14px;
  font-weight: 700;
}
.home-nav a:hover { color: #0f172a; }
.site-topbar {
  gap: 18px;
}
.site-nav {
  flex: 1;
  justify-content: flex-end;
}
.site-menu {
  position: relative;
}
.site-menu summary {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0 10px;
  border-radius: 8px;
  color: #334155;
  font-size: 14px;
  font-weight: 800;
  list-style: none;
  cursor: pointer;
}
.site-menu summary::-webkit-details-marker {
  display: none;
}
.site-menu summary::after {
  content: "";
  width: 7px;
  height: 7px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg) translateY(-2px);
  opacity: .7;
}
.site-menu[open] summary,
.site-menu summary:hover {
  background: #eff6ff;
  color: #1d4ed8;
}
.site-menu-panel {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 30;
  min-width: 220px;
  display: grid;
  gap: 4px;
  padding: 8px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 18px 44px rgba(15, 23, 42, .14);
}
.site-menu:hover .site-menu-panel,
.site-menu:focus-within .site-menu-panel {
  display: grid;
}
.site-menu-panel a {
  display: block;
  padding: 9px 10px;
  border-radius: 6px;
  color: #334155;
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
}
.site-menu-panel a:hover {
  background: #eff6ff;
  color: #1d4ed8;
}
.site-account {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #64748b;
  font-size: 13px;
  font-weight: 800;
}
.site-account span {
  max-width: 220px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.site-account form {
  margin: 0;
}
.site-account a,
.site-account button {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #fff;
  color: #0f172a;
  font: 800 13px Arial, Helvetica, sans-serif;
  text-decoration: none;
  cursor: pointer;
}
.site-account a:hover,
.site-account button:hover {
  border-color: #93c5fd;
  background: #eff6ff;
  color: #1d4ed8;
}
.home-hero {
  min-height: calc(100vh - 64px);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 580px);
  align-items: center;
  gap: clamp(28px, 5vw, 72px);
  padding: clamp(38px, 7vw, 82px) clamp(18px, 5vw, 72px) 36px;
  background:
    linear-gradient(180deg, rgba(239, 246, 255, .95), rgba(248, 250, 252, 1) 76%),
    #f8fafc;
}
.home-hero__copy {
  max-width: 680px;
}
.home-kicker {
  margin: 0 0 10px;
  color: #2563eb;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}
.home-hero h1 {
  max-width: 760px;
  margin: 0;
  color: #0f172a;
  font-size: clamp(38px, 6vw, 68px);
  line-height: 1.02;
  letter-spacing: 0;
}
.home-lede {
  max-width: 620px;
  margin: 22px 0 0;
  color: #475569;
  font-size: 18px;
  line-height: 1.65;
}
.home-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}
.home-button {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 8px;
  text-decoration: none;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
}
.home-button.primary {
  background: #2563eb;
  color: #fff;
  box-shadow: 0 10px 24px rgba(37, 99, 235, .20);
}
.home-button.primary:hover { background: #1d4ed8; }
.home-button.secondary {
  background: #fff;
  color: #0f172a;
  border-color: #cbd5e1;
}
.home-button.secondary:hover:not(:disabled) {
  border-color: #94a3b8;
  background: #f8fafc;
}
.home-button.secondary.danger {
  border-color: #fecaca;
  background: #fee2e2;
  color: #991b1b;
}
.home-button.secondary.danger:hover:not(:disabled) {
  border-color: #fca5a5;
  background: #fecaca;
}
.home-button:disabled {
  opacity: .62;
  cursor: not-allowed;
}
.home-preview {
  overflow: hidden;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}
.home-preview__bar {
  height: 42px;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 0 14px;
  background: #0f172a;
}
.home-preview__bar span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #93c5fd;
}
.home-preview__body {
  display: grid;
  grid-template-columns: 150px 1fr;
  min-height: 360px;
}
.home-preview aside {
  padding: 14px;
  border-right: 1px solid #e2e8f0;
  background: #f8fafc;
}
.home-preview section {
  padding: 24px;
}
.home-preview__select,
.home-preview__item,
.home-preview__title,
.home-preview__line,
.home-preview__answer,
.home-preview__chips span {
  border-radius: 7px;
  background: #e2e8f0;
}
.home-preview__select {
  height: 34px;
  margin-bottom: 10px;
}
.home-preview__select.short { width: 78%; }
.home-preview__item {
  height: 52px;
  margin-top: 12px;
}
.home-preview__item.active {
  background: #dbeafe;
  border: 1px solid #93c5fd;
}
.home-preview__title {
  width: 52%;
  height: 22px;
  margin-bottom: 24px;
  background: #bfdbfe;
}
.home-preview__line {
  width: 62%;
  height: 14px;
  margin: 12px 0;
}
.home-preview__line.wide { width: 86%; }
.home-preview__answer {
  height: 120px;
  margin-top: 26px;
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
}
.home-preview__chips {
  display: flex;
  gap: 10px;
  margin-top: 18px;
}
.home-preview__chips span {
  width: 74px;
  height: 32px;
  background: #dcfce7;
}
.subject-section,
.home-features {
  padding: 56px clamp(18px, 5vw, 72px);
}
.section-head {
  max-width: 760px;
  margin-bottom: 22px;
}
.section-head h2 {
  margin: 0;
  color: #0f172a;
  font-size: 30px;
  letter-spacing: 0;
}
.subject-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.subject-card {
  min-height: 220px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 22px;
  padding: 22px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 8px 28px rgba(15, 23, 42, .06);
}
.subject-card.is-ready {
  border-color: #bfdbfe;
  background: linear-gradient(180deg, #fff, #eff6ff);
}
.subject-card--iepq.is-ready {
  border-color: #99f6e4;
  background: linear-gradient(180deg, #fff, #f0fdfa);
}
.subject-badge {
  display: inline-flex;
  width: fit-content;
  margin-bottom: 12px;
  padding: 5px 8px;
  border-radius: 999px;
  background: #dcfce7;
  color: #047857;
  font-size: 12px;
  font-weight: 800;
}
.muted-badge {
  background: #e2e8f0;
  color: #475569;
}
.iepq-badge {
  background: #ccfbf1;
  color: #0f766e;
}
.subject-card h3 {
  margin: 0 0 10px;
  color: #0f172a;
  font-size: 22px;
  letter-spacing: 0;
}
.subject-card p {
  margin: 0;
  color: #475569;
  line-height: 1.55;
}
.subject-card .home-button {
  align-self: flex-start;
}
.iepq-detail-card {
  display: block;
}
.iepq-detail-card[open] {
  grid-column: 1 / -1;
}
.iepq-detail-card summary {
  min-height: 176px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 18px;
  list-style: none;
  cursor: pointer;
}
.iepq-detail-card summary::-webkit-details-marker {
  display: none;
}
.iepq-detail-card summary > div,
.iepq-detail-card summary p {
  pointer-events: none;
}
.iepq-detail-card .home-button {
  width: fit-content;
}
.iepq-detail-content {
  margin-top: 22px;
  padding-top: 22px;
  border-top: 1px solid #dbeafe;
}
.iepq-detail-content .section-head {
  margin-bottom: 16px;
}
.home-features {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  padding-top: 0;
}
.home-features div {
  padding: 20px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #fff;
}
.home-features strong {
  display: block;
  margin-bottom: 8px;
  color: #0f172a;
}
.home-features p {
  margin: 0;
  color: #475569;
  line-height: 1.55;
}

.subject-hero,
.resource-shell {
  padding: 48px clamp(18px, 5vw, 72px);
}
.subject-hero {
  max-width: 980px;
}
.iepq-hero {
  max-width: none;
  background:
    linear-gradient(120deg, rgba(240, 253, 250, .96), rgba(255, 255, 255, .94)),
    radial-gradient(circle at 82% 18%, rgba(45, 212, 191, .22), transparent 32%);
}
.subject-hero h1 {
  margin: 0;
  color: #0f172a;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.05;
}
.subject-hero p:not(.home-kicker),
.resource-lede {
  max-width: 760px;
  color: #475569;
  font-size: 17px;
  line-height: 1.6;
}
.subject-hub-grid {
  padding: 0 clamp(18px, 5vw, 72px) 56px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.iepq-grid {
  align-items: stretch;
}
.iepq-resources {
  padding: 0 clamp(18px, 5vw, 72px) 72px;
}
.iepq-resources .section-head {
  max-width: 820px;
}
.iepq-resources .section-head p:not(.home-kicker) {
  margin: 10px 0 0;
  color: #475569;
  font-size: 16px;
  line-height: 1.6;
}
.iepq-resource-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.iepq-resource-card {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: start;
  padding: 18px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 8px 26px rgba(15, 23, 42, .05);
}
.iepq-resource-card--featured {
  grid-column: 1 / -1;
  border-color: #99f6e4;
  background: linear-gradient(180deg, #fff, #f0fdfa);
}
.iepq-resource-card h3 {
  margin: 0 0 8px;
  color: #0f172a;
  font-size: 18px;
  letter-spacing: 0;
}
.iepq-resource-card p {
  margin: 0;
  color: #475569;
  line-height: 1.55;
}
.iepq-resource-card small {
  display: block;
  margin-top: 10px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}
.iepq-resource-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  min-width: 190px;
}
.iepq-resource-actions .home-button {
  min-height: 38px;
  padding: 9px 12px;
  font-size: 13px;
}
.iepq-resource-link.subtle {
  flex-basis: 100%;
  color: #0f766e;
  font-size: 12px;
  font-weight: 800;
  text-align: right;
  text-decoration: none;
}
.iepq-resource-link.subtle:hover {
  text-decoration: underline;
}
.iepq-resource-empty {
  grid-column: 1 / -1;
  margin: 0;
  padding: 22px;
  border: 1px dashed #cbd5e1;
  border-radius: 8px;
  color: #64748b;
  background: #fff;
}
.iepq-samples {
  padding-top: 0;
}
.iepq-sample-group {
  margin-top: 18px;
}
.iepq-sample-group > h3 {
  margin: 0 0 12px;
  color: #0f172a;
  font-size: 20px;
  letter-spacing: 0;
}
.iepq-sample-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.iepq-sample-card {
  min-width: 0;
  display: grid;
  gap: 14px;
  align-content: space-between;
  padding: 16px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 6px 20px rgba(15, 23, 42, .045);
}
.iepq-sample-card h3 {
  margin: 0 0 8px;
  color: #0f172a;
  font-size: 17px;
  letter-spacing: 0;
}
.iepq-sample-card p {
  margin: 0;
  color: #475569;
  font-size: 14px;
  line-height: 1.55;
}
.iepq-sample-card small {
  display: block;
  margin-top: 10px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}
.iepq-sample-card .iepq-resource-actions {
  justify-content: flex-start;
  min-width: 0;
}
.iepq-workspace-page {
  background: #f7fbfb;
}
.iepq-workspace-shell {
  max-width: 1180px;
  margin: 0 auto;
  padding: 42px clamp(18px, 5vw, 56px) 72px;
}
.iepq-workspace-hero {
  max-width: 860px;
  margin-bottom: 20px;
}
.iepq-workspace-hero h1 {
  margin: 0;
  color: #0f172a;
  font-size: clamp(34px, 5vw, 54px);
  line-height: 1.06;
  letter-spacing: 0;
}
.iepq-workspace-hero p:not(.home-kicker) {
  max-width: 760px;
  color: #475569;
  font-size: 17px;
  line-height: 1.65;
}
.iepq-project-grid,
.iepq-stage-grid,
.iepq-source-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.iepq-project-card,
.iepq-stage-card,
.iepq-source-card,
.iepq-checklist-card,
.iepq-form-card,
.iepq-guidance-card,
.iepq-empty-state {
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 9px 28px rgba(15, 23, 42, .055);
}
.iepq-project-card,
.iepq-stage-card,
.iepq-source-card {
  display: grid;
  gap: 14px;
  align-content: space-between;
  padding: 18px;
}
.iepq-project-actions,
.iepq-source-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}
.iepq-project-actions form,
.iepq-source-actions form,
.iepq-form-actions form {
  margin: 0;
}
.login-page-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  align-items: start;
}
.student-dashboard-hero {
  background:
    linear-gradient(120deg, rgba(239, 246, 255, .98), rgba(240, 253, 250, .94)),
    radial-gradient(circle at 86% 16%, rgba(45, 212, 191, .18), transparent 34%);
}
.student-dashboard-login {
  margin: 0 0 18px;
}
.student-dashboard-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.student-dashboard-card,
.student-dashboard-section {
  min-width: 0;
  padding: 22px;
  border: 1px solid #dbeafe;
  border-radius: 12px;
  background: rgba(255, 255, 255, .92);
  box-shadow: 0 18px 44px rgba(15, 23, 42, .06);
}
.student-dashboard-card h2,
.student-dashboard-section h2 {
  margin: 0 0 10px;
  color: #0f172a;
  font-size: 26px;
  letter-spacing: 0;
}
.student-dashboard-card p,
.student-dashboard-section p {
  margin: 0;
  color: #475569;
  line-height: 1.55;
}
.student-dashboard-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 18px 0;
}
.student-dashboard-stats div {
  padding: 14px 10px;
  border-radius: 10px;
  background: #f8fafc;
  text-align: center;
}
.student-dashboard-stats strong {
  display: block;
  color: #0f172a;
  font-size: 26px;
}
.student-dashboard-stats span {
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}
.student-dashboard-list {
  display: grid;
  gap: 8px;
  margin: 16px 0;
}
.student-dashboard-row,
.student-dashboard-empty {
  display: grid;
  gap: 4px;
  padding: 12px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #f8fafc;
  color: #0f172a;
  text-decoration: none;
}
.student-dashboard-row:hover {
  border-color: #93c5fd;
  background: #eff6ff;
}
.teacher-student-row {
  grid-template-columns: minmax(0, 1fr) auto auto auto auto;
  align-items: center;
  gap: 10px;
}
.teacher-student-row > a {
  color: inherit;
  text-decoration: none;
}
.assistant-monitor-row {
  grid-template-columns: minmax(0, 1fr) auto auto;
}
.teacher-pending-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  background: #fff7ed;
  color: #c2410c;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}
.teacher-role-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  background: #ecfdf5;
  color: #047857;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}
.student-dashboard-row span,
.student-dashboard-empty span {
  color: #64748b;
  font-size: 13px;
  font-weight: 700;
}
.student-dashboard-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}
.student-dashboard-section {
  display: grid;
  grid-template-columns: minmax(240px, .8fr) minmax(0, 1.2fr);
  gap: 24px;
  align-items: start;
  margin-top: 18px;
}
.student-profile-form {
  display: grid;
  gap: 14px;
}
.student-profile-form label {
  display: grid;
  gap: 6px;
  color: #334155;
  font-size: 13px;
  font-weight: 800;
}
.student-profile-form input,
.student-profile-form select {
  width: 100%;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #fff;
  color: #0f172a;
  font: 700 15px Arial, Helvetica, sans-serif;
}
.student-profile-form input:disabled {
  background: #f1f5f9;
  color: #64748b;
}
.password-input-wrap {
  position: relative;
}
.password-input-wrap input {
  width: 100%;
  padding-right: 46px !important;
}
.password-toggle {
  position: absolute;
  top: 50%;
  right: 5px;
  width: 36px;
  height: 36px;
  padding: 0;
  transform: translateY(-50%);
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #607089;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
}
.password-toggle:hover,
.password-toggle:focus-visible {
  background: #eaf1ff;
  color: #1d5fd0;
  outline: none;
}
.student-dashboard-stack {
  display: grid;
  gap: 14px;
}
.student-dashboard-note {
  margin: 0;
  color: #64748b;
  font-size: 13px;
  line-height: 1.55;
}
.student-profile-form.compact {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto;
  align-items: end;
  padding: 14px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #f8fafc;
}
.teacher-class-grid {
  display: grid;
  gap: 12px;
}
.teacher-class-card {
  padding: 14px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #fff;
}
.teacher-class-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 12px;
}
.teacher-class-head h3 {
  margin: 0 0 4px;
  color: #0f172a;
  font-size: 18px;
}
.teacher-class-head code {
  padding: 8px 10px;
  border-radius: 8px;
  background: #eff6ff;
  color: #1d4ed8;
  font: 800 13px ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  white-space: nowrap;
}
.teacher-iepq-project-card {
  padding: 16px;
  border: 1px solid #dbeafe;
  border-radius: 12px;
  background: #fff;
}
.teacher-student-summary-grid {
  display: grid;
  gap: 14px;
}
.teacher-student-project-summary {
  display: grid;
  gap: 14px;
  padding: 16px;
  border: 1px solid #dbeafe;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, .05);
}
.teacher-iepq-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.teacher-iepq-metrics div {
  padding: 12px;
  border-radius: 10px;
  background: #f8fafc;
}
.teacher-iepq-metrics strong {
  display: block;
  color: #0f172a;
  font-size: 22px;
}
.teacher-iepq-metrics span {
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}
.teacher-compact-details {
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #f8fafc;
}
.teacher-compact-details summary {
  padding: 11px 12px;
  cursor: pointer;
  color: #1d4ed8;
  font-size: 13px;
  font-weight: 900;
  list-style: none;
}
.teacher-compact-details summary::-webkit-details-marker {
  display: none;
}
.teacher-project-stage-grid {
  display: grid;
  gap: 8px;
  padding: 0 12px 12px;
}
.teacher-project-stage-line {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 9px 10px;
  border-radius: 8px;
  background: #fff;
}
.teacher-project-stage-line span {
  color: #334155;
  font-weight: 800;
}
.teacher-project-stage-line strong {
  color: #1d4ed8;
  font-size: 13px;
}
.student-feedback-list {
  display: grid;
  gap: 10px;
}
.student-feedback-list h3 {
  margin: 0;
  color: #0f172a;
  font-size: 17px;
}
.student-feedback-item {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid #dbeafe;
  border-radius: 10px;
  background: #f8fbff;
  color: inherit;
  text-decoration: none;
}
.student-feedback-item div {
  display: grid;
  gap: 3px;
}
.student-feedback-item span {
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}
.student-feedback-item p {
  margin: 0;
  color: #334155;
  line-height: 1.55;
  white-space: pre-wrap;
}
.teacher-feedback-quote {
  margin: 0;
  padding: 9px 11px;
  border-left: 4px solid #f59e0b;
  border-radius: 8px;
  background: #fffbeb;
  color: #78350f;
  font-size: 13px;
  line-height: 1.45;
}
.teacher-review-columns {
  display: grid;
  gap: 14px;
  margin-top: 16px;
}
.teacher-review-columns h4 {
  margin: 0 0 8px;
  color: #0f172a;
  font-size: 18px;
}
.teacher-review-block,
.teacher-review-row {
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #f8fafc;
}
.teacher-review-block {
  margin-bottom: 8px;
}
.teacher-review-block summary {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 12px;
  cursor: pointer;
  list-style: none;
  color: #0f172a;
  font-weight: 800;
}
.teacher-review-block summary::-webkit-details-marker {
  display: none;
}
.teacher-review-block summary small {
  color: #64748b;
  font-size: 12px;
}
.teacher-review-content {
  display: grid;
  gap: 10px;
  padding: 0 12px 12px;
}
.teacher-readonly-field {
  padding: 10px;
  border-radius: 8px;
  background: #fff;
}
.teacher-readonly-field strong {
  display: block;
  margin-bottom: 5px;
  color: #334155;
  font-size: 12px;
}
.teacher-readonly-field p,
.teacher-review-row p {
  margin: 0;
  color: #475569;
  line-height: 1.55;
  white-space: pre-wrap;
}
.teacher-review-list {
  display: grid;
  gap: 8px;
}
.teacher-review-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, .85fr);
  gap: 12px;
  padding: 12px;
}
.teacher-review-row span {
  display: block;
  margin: 4px 0 7px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}
.teacher-inline-feedback,
.teacher-inline-feedback-form {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #fff;
}
.teacher-inline-feedback strong {
  color: #1d4ed8;
  font-size: 12px;
}
.teacher-inline-feedback p {
  margin: 0;
  color: #334155;
  line-height: 1.5;
}
.teacher-inline-feedback-form textarea {
  width: 100%;
  resize: vertical;
  padding: 10px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  color: #0f172a;
  font: 700 13px Arial, Helvetica, sans-serif;
}
.teacher-inline-feedback-form .home-button {
  justify-self: start;
}
.teacher-selected-quote {
  display: grid;
  gap: 6px;
  padding: 10px;
  border: 1px solid #fde68a;
  border-radius: 8px;
  background: #fffbeb;
}
.teacher-selected-quote[hidden] {
  display: none;
}
.teacher-selected-quote span {
  color: #92400e;
  font-size: 12px;
  font-weight: 900;
}
.teacher-selected-quote blockquote {
  margin: 0;
  padding-left: 10px;
  border-left: 3px solid #f59e0b;
  color: #78350f;
  font-size: 13px;
  line-height: 1.45;
}
.teacher-selected-quote button {
  justify-self: start;
  border: 0;
  background: transparent;
  color: #1d4ed8;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}
.teacher-selection-comment-button {
  position: absolute;
  z-index: 40;
  padding: 8px 12px;
  border: 1px solid #2563eb;
  border-radius: 999px;
  background: #2563eb;
  color: #fff;
  box-shadow: 0 12px 28px rgba(37, 99, 235, .22);
  font: 900 13px/1 Arial, Helvetica, sans-serif;
  cursor: pointer;
}
.teacher-selection-comment-button[hidden] {
  display: none;
}
.iepq-submit-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  margin: 16px 0;
  padding: 16px;
  border: 1px solid #bfdbfe;
  border-left: 5px solid #2563eb;
  border-radius: 14px;
  background: linear-gradient(135deg, #eff6ff, #ffffff);
  box-shadow: 0 12px 28px rgba(37, 99, 235, .08);
}
.iepq-submit-panel strong {
  display: block;
  color: #0f172a;
  font-size: 18px;
  margin-bottom: 4px;
}
.iepq-submit-panel p {
  margin: 0;
  color: #475569;
  line-height: 1.5;
}
.iepq-submit-panel .iepq-save-note {
  grid-column: 1 / -1;
  margin: 0;
}
.teacher-feedback-panel {
  border-color: #bfdbfe;
  background: #f8fbff;
}
.iepq-review-page {
  max-width: 1480px;
  margin: 0 auto;
}
.iepq-review-page .iepq-workspace-hero {
  display: grid;
  gap: 10px;
  margin: 0 0 14px;
  padding: 22px 26px;
  border: 1px solid #dbeafe;
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(239, 246, 255, .96), rgba(255, 255, 255, .98)),
    radial-gradient(circle at 90% 0%, rgba(191, 219, 254, .45), transparent 30%);
  box-shadow: 0 18px 45px rgba(15, 23, 42, .05);
}
.iepq-review-page .iepq-workspace-hero h1 {
  max-width: 920px;
  margin: 0;
  color: #0f172a;
  font-size: clamp(34px, 4vw, 54px);
  line-height: 1;
  letter-spacing: 0;
}
.iepq-review-page .iepq-workspace-hero p:not(.home-kicker) {
  max-width: 920px;
  color: #475569;
  font-size: 16px;
  line-height: 1.45;
}
.iepq-review-page .home-actions {
  margin-top: 4px;
}
.teacher-review-word-layout {
  display: grid;
  grid-template-columns: minmax(0, 820px) minmax(340px, 420px);
  justify-content: center;
  gap: 28px;
  align-items: start;
  margin: 14px 0 28px;
  max-width: 1320px;
}
.teacher-review-document {
  min-width: 0;
}
.teacher-submitted-work {
  max-width: 820px;
  margin: 0;
  padding: 30px 34px;
  border: 1px solid #dbeafe;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 20px 55px rgba(15, 23, 42, .07);
}
.teacher-submitted-work h2 {
  margin: 0;
  color: #0f172a;
  font-size: 30px;
  font-weight: 900;
  line-height: 1.15;
  letter-spacing: 0;
}
.teacher-submitted-work .student-dashboard-note {
  margin-top: 6px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .01em;
}
.teacher-section-head {
  padding-bottom: 16px;
  border-bottom: 1px solid #e2e8f0;
}
.teacher-stage-field-list {
  display: grid;
  gap: 20px;
  margin-top: 22px;
}
.teacher-submitted-work .teacher-readonly-field {
  padding: 0 0 20px;
  border-bottom: 1px solid #f1f5f9;
  border-radius: 0;
  background: transparent;
}
.teacher-submitted-work .teacher-readonly-field:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}
.teacher-submitted-work .teacher-readonly-field strong {
  display: inline-flex;
  align-items: center;
  max-width: 100%;
  margin: 0 0 10px;
  padding: 5px 10px;
  border-radius: 999px;
  background: #eef6ff;
  color: #1d4ed8;
  font-size: 12px;
  font-weight: 900;
  line-height: 1.25;
}
.teacher-submitted-work .teacher-readonly-field p {
  max-width: 74ch;
  color: #1f2937;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.72;
  letter-spacing: 0;
  text-align: justify;
  text-align-last: left;
  text-justify: inter-word;
  hyphens: auto;
  text-rendering: optimizeLegibility;
  overflow-wrap: anywhere;
}
.teacher-submitted-work .teacher-readonly-field p::first-letter {
  letter-spacing: 0;
}
.teacher-comment-sidebar {
  position: sticky;
  top: 12px;
  max-height: calc(100vh - 24px);
  overflow: auto;
  display: grid;
  gap: 12px;
  padding: 18px;
  border: 1px solid #bfdbfe;
  border-radius: 18px;
  background: linear-gradient(180deg, #f8fbff, #ffffff);
  box-shadow: 0 18px 46px rgba(37, 99, 235, .12);
}
.teacher-sidebar-head {
  display: grid;
  gap: 6px;
  padding-bottom: 8px;
  border-bottom: 1px solid #e2e8f0;
}
.teacher-sidebar-head h2 {
  margin: 0;
  color: #0f172a;
  font-size: 24px;
  font-weight: 900;
  letter-spacing: 0;
}
.teacher-sidebar-head p {
  margin: 0;
  color: #64748b;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.5;
}
.teacher-ai-comment-tool {
  display: grid;
  gap: 10px;
  padding: 13px;
  border: 1px solid #c7d2fe;
  border-radius: 14px;
  background: linear-gradient(180deg, #eef2ff, #ffffff);
  box-shadow: 0 8px 20px rgba(79, 70, 229, .06);
}
.teacher-ai-comment-tool strong {
  display: block;
  color: #1e1b4b;
  font-size: 14px;
  font-weight: 900;
}
.teacher-ai-comment-tool span,
.teacher-ai-comment-tool p {
  display: block;
  margin: 3px 0 0;
  color: #64748b;
  font-size: 12px;
  font-weight: 750;
  line-height: 1.4;
}
.teacher-ai-comment-tool input {
  width: 100%;
  padding: 10px 11px;
  border: 1px solid #c7d2fe;
  border-radius: 10px;
  background: #fff;
  color: #0f172a;
  font: 650 13px/1.3 Arial, Helvetica, sans-serif;
}
.teacher-ai-comment-tool input:focus {
  outline: 3px solid rgba(79, 70, 229, .16);
  border-color: #4f46e5;
}
.teacher-ai-comment-tool .home-button {
  justify-self: start;
}
.teacher-ai-comment-tool p.is-error {
  color: #b91c1c;
}
.teacher-ai-import-tool {
  display: grid;
  gap: 9px;
  padding-top: 10px;
  border-top: 1px solid #dbe4ff;
}
.teacher-ai-import-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.teacher-ai-import-tool textarea {
  width: 100%;
  min-height: 132px;
  resize: vertical;
  padding: 10px 11px;
  border: 1px solid #c7d2fe;
  border-radius: 10px;
  background: #fff;
  color: #0f172a;
  font: 600 12px/1.5 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
}
.teacher-ai-import-tool textarea:focus {
  outline: 3px solid rgba(79, 70, 229, .16);
  border-color: #4f46e5;
}
.teacher-draft-comments,
.teacher-existing-comments {
  display: grid;
  gap: 10px;
}
.teacher-word-comment {
  position: relative;
}
.teacher-comment-card-head {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  justify-content: space-between;
}
.teacher-comment-card-head a {
  flex: 0 0 auto;
  color: #2563eb;
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
}
.teacher-comment-card-head a:hover,
.teacher-inline-quote-link:hover {
  text-decoration: underline;
}
.teacher-comment-card-head a:hover {
  text-decoration: underline;
}
.teacher-word-comment::before {
  content: "";
  position: absolute;
  left: -18px;
  top: 22px;
  width: 18px;
  border-top: 2px solid #bfdbfe;
}
.teacher-existing-comments .student-feedback-item {
  padding: 13px;
  border-color: #dbeafe;
  border-left: 4px solid #60a5fa;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, .04);
}
.teacher-comment-sidebar .student-dashboard-empty {
  padding: 16px;
  border: 1px solid #dbeafe;
  border-radius: 14px;
  background:
    linear-gradient(180deg, #ffffff, #fbfdff);
  box-shadow: 0 8px 20px rgba(15, 23, 42, .035);
}
.teacher-comment-sidebar .student-dashboard-empty strong {
  color: #0f172a;
  font-size: 16px;
  line-height: 1.25;
}
.teacher-comment-sidebar .student-dashboard-empty span {
  margin-top: 5px;
  color: #64748b;
  font-size: 13px;
  line-height: 1.4;
}
.teacher-existing-comments .student-feedback-item.has-quote {
  border-left-color: #f59e0b;
}
.teacher-existing-comments .student-feedback-item:target {
  border-color: #f59e0b;
  box-shadow: 0 0 0 4px rgba(245, 158, 11, .16);
}
.teacher-existing-comments .student-feedback-item.is-active {
  border-color: #7c3aed;
  box-shadow: 0 0 0 4px rgba(124, 58, 237, .18);
}
.teacher-word-comment.has-quote::before {
  border-color: #f59e0b;
}
.teacher-comment-draft {
  padding: 12px;
  border: 1px solid #fde68a;
  border-left: 4px solid #f59e0b;
  border-radius: 10px;
  background: #fffbeb;
}
.teacher-comment-draft.is-accepted {
  border-color: #bfdbfe;
  border-left-color: #2563eb;
  background: #eff6ff;
}
.teacher-comment-draft.is-saved {
  border-color: #bbf7d0;
  border-left-color: #22c55e;
  background: #f0fdf4;
}
.teacher-comment-draft form {
  display: grid;
  gap: 9px;
}
.teacher-comment-label {
  color: #92400e;
  font-size: 12px;
  font-weight: 900;
}
.teacher-comment-draft textarea {
  width: 100%;
  resize: vertical;
  min-height: 82px;
  padding: 10px;
  border: 1px solid #fcd34d;
  border-radius: 8px;
  background: #fff;
  color: #0f172a;
  font: 600 13px/1.5 Arial, Helvetica, sans-serif;
}
.teacher-existing-comment-form {
  display: grid;
  gap: 8px;
}
.teacher-existing-comment-form textarea {
  width: 100%;
  min-height: 94px;
  resize: vertical;
  padding: 10px;
  border: 1px solid #dbeafe;
  border-radius: 9px;
  background: #fff;
  color: #0f172a;
  font: 600 13px/1.5 Arial, Helvetica, sans-serif;
}
.teacher-existing-comment-form textarea:focus,
.teacher-comment-draft textarea:focus {
  outline: 3px solid rgba(37, 99, 235, .18);
  border-color: #2563eb;
}
.teacher-static-comment-body {
  margin: 0;
  padding: 12px;
  border: 1px solid #dbeafe;
  border-radius: 10px;
  background: #fff;
  color: #0f172a;
  font-size: 14px;
  font-weight: 750;
  line-height: 1.55;
  white-space: pre-wrap;
}
.teacher-comment-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.teacher-comment-save-status {
  color: #15803d;
  font-size: 12px;
  font-weight: 900;
}
.teacher-comment-save-status.is-error {
  color: #b91c1c;
}
.teacher-feedback-submit-all {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  padding: 12px;
  border: 1px solid #bfdbfe;
  border-radius: 12px;
  background: #f8fbff;
}
.teacher-feedback-submit-all strong,
.teacher-feedback-submit-all span {
  display: block;
}
.teacher-feedback-submit-all strong {
  color: #0f172a;
  font-size: 13px;
  font-weight: 900;
}
.teacher-feedback-submit-all span {
  margin-top: 3px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
}
.teacher-commentable-text {
  font-size: 15px;
}
.teacher-inline-quote-link {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px dashed rgba(124, 58, 237, .55);
  cursor: pointer;
}
.teacher-inline-quote {
  display: inline;
  padding: 2px 4px;
  border-radius: 5px;
  background: #fef3c7;
  color: inherit;
  box-shadow: 0 0 0 1px rgba(245, 158, 11, .35);
}
.teacher-inline-quote span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 22px;
  height: 20px;
  margin-right: 4px;
  border-radius: 999px;
  background: #f59e0b;
  color: #fff;
  font-size: 11px;
  font-weight: 900;
}
.teacher-inline-quote:target {
  background: #fde68a;
  box-shadow: 0 0 0 3px rgba(245, 158, 11, .28);
}
.teacher-inline-quote.is-active {
  background: #fde68a;
  box-shadow: 0 0 0 4px rgba(245, 158, 11, .32);
}
.teacher-inline-quote.is-ai-draft {
  background: #ede9fe;
  box-shadow: 0 0 0 1px rgba(124, 58, 237, .32);
}
.teacher-inline-quote.is-ai-draft::before {
  content: "AI";
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 22px;
  height: 20px;
  margin-right: 4px;
  border-radius: 999px;
  background: #7c3aed;
  color: #fff;
  font-size: 11px;
  font-weight: 900;
}
.teacher-general-feedback-form {
  margin-top: 4px;
  border-style: dashed;
}
.teacher-comment-sidebar .teacher-general-feedback-form {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px dashed #bfdbfe;
  border-radius: 14px;
  background: rgba(248, 251, 255, .86);
}
.teacher-comment-sidebar .teacher-general-feedback-form textarea {
  width: 100%;
  min-height: 92px;
  padding: 10px 11px;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  background: #fff;
  color: #0f172a;
  font: 600 13px/1.5 Arial, Helvetica, sans-serif;
}
.teacher-comment-sidebar .teacher-general-feedback-form textarea:focus {
  outline: 3px solid rgba(37, 99, 235, .16);
  border-color: #2563eb;
}
.teacher-comment-sidebar .teacher-general-feedback-form .home-button {
  justify-self: start;
  min-height: 42px;
  padding: 10px 16px;
  font-size: 14px;
}
@media (max-width: 980px) {
  .iepq-review-page .iepq-workspace-hero {
    padding: 18px;
    border-radius: 14px;
  }
  .iepq-review-page .iepq-workspace-hero h1 {
    font-size: 34px;
  }
  .teacher-review-word-layout {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .teacher-submitted-work {
    max-width: none;
    padding: 20px;
    border-radius: 14px;
  }
  .teacher-comment-sidebar {
    position: static;
    max-height: none;
  }
  .teacher-word-comment::before {
    display: none;
  }
}
.teacher-review-queue {
  padding: 18px;
  border: 1px solid #dbeafe;
  border-radius: 14px;
  background: #f8fbff;
}
.teacher-submission-list {
  display: grid;
  gap: 10px;
}
.teacher-submission-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 14px;
  border: 1px solid #dbeafe;
  border-radius: 12px;
  background: #fff;
  color: #0f172a;
  text-decoration: none;
}
.teacher-submission-item:hover {
  border-color: #93c5fd;
  box-shadow: 0 10px 24px rgba(37, 99, 235, .12);
}
.teacher-submission-item span {
  display: block;
  margin-top: 4px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}
.teacher-submission-item em {
  justify-self: end;
  padding: 6px 10px;
  border-radius: 999px;
  background: #dbeafe;
  color: #1d4ed8;
  font-style: normal;
  font-size: 12px;
  font-weight: 900;
}
.teacher-submission-item.reviewed {
  border-color: #bbf7d0;
  background: #f0fdf4;
}
.teacher-submission-item.reviewed em {
  background: #dcfce7;
  color: #15803d;
}
.teacher-subject-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 14px;
}
.teacher-subject-card {
  display: grid;
  gap: 14px;
  padding: 16px;
  border: 1px solid #dbeafe;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 14px 30px rgba(37, 99, 235, .08);
}
.teacher-subject-card h3 {
  margin: 8px 0 6px;
  color: #0f172a;
  font-size: 20px;
  letter-spacing: 0;
}
.teacher-subject-card p {
  margin: 0;
  color: #475569;
  line-height: 1.5;
}
.student-dashboard-stats.compact {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
.teacher-system-stats {
  max-width: 720px;
}
.teacher-review-queue-list {
  display: grid;
  gap: 10px;
}
.teacher-review-queue-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  border: 1px solid #dbeafe;
  border-radius: 14px;
  background: #fff;
  color: #0f172a;
  text-decoration: none;
}
.teacher-review-queue-row:hover {
  border-color: #93c5fd;
  box-shadow: 0 14px 28px rgba(37, 99, 235, .10);
}
.teacher-review-queue-row strong,
.teacher-review-queue-row span,
.teacher-review-queue-row small {
  display: block;
}
.teacher-review-queue-row span {
  margin-top: 4px;
  color: #475569;
  font-weight: 750;
}
.teacher-review-queue-row small {
  margin-top: 4px;
  color: #64748b;
  font-weight: 800;
}
.teacher-review-queue-row em {
  padding: 7px 11px;
  border-radius: 999px;
  background: #ffedd5;
  color: #c2410c;
  font-style: normal;
  font-size: 12px;
  font-weight: 900;
}
.teacher-review-queue-row.reviewed em {
  background: #dcfce7;
  color: #15803d;
}
.teacher-review-split {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.teacher-review-split.single {
  grid-template-columns: 1fr;
}
.teacher-stage-review-card {
  display: grid;
  gap: 14px;
}
.teacher-section-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
}
.teacher-stage-field-list {
  display: grid;
  gap: 12px;
}
.teacher-stage-field-review {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid #dbeafe;
  border-radius: 12px;
  background: #f8fbff;
}
.teacher-stage-field-review .teacher-readonly-field {
  border: 1px solid #e2e8f0;
}
.teacher-stage-field-review .teacher-readonly-field:first-child {
  border-color: #bfdbfe;
  background: #fff;
}
.teacher-comment-panel {
  display: grid;
  grid-template-columns: minmax(220px, .36fr) minmax(0, 1fr);
  gap: 18px;
  margin: 18px 0;
  padding: 18px;
  border: 1px solid #bfdbfe;
  border-radius: 14px;
  background: linear-gradient(135deg, #eff6ff 0%, #fff 56%);
}
.teacher-comment-panel h2,
.teacher-comment-panel p {
  margin: 0;
}
.teacher-comment-panel summary {
  display: grid;
  gap: 4px;
  cursor: pointer;
  list-style: none;
}
.teacher-comment-panel summary::-webkit-details-marker {
  display: none;
}
.teacher-comment-panel summary span {
  color: #2563eb;
  font-size: 13px;
  font-weight: 900;
}
.teacher-comment-panel h2 {
  color: #0f172a;
  font-size: 22px;
  letter-spacing: 0;
}
.teacher-comment-panel > p {
  margin-top: 8px;
  color: #475569;
  line-height: 1.5;
}
.student-word-comments:not([open]) {
  cursor: pointer;
}
.student-word-comments:not([open]) .teacher-comment-list,
.student-word-comments:not([open]) > p {
  display: none;
}
.teacher-comment-list {
  display: grid;
  gap: 10px;
}
.teacher-comment-item {
  display: grid;
  gap: 8px;
  padding: 13px 14px;
  border: 1px solid #dbeafe;
  border-left: 4px solid #2563eb;
  border-radius: 10px;
  background: #fff;
}
.teacher-comment-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  color: #64748b;
  font-size: 12px;
  font-weight: 850;
}
.teacher-comment-meta span {
  padding: 4px 8px;
  border-radius: 999px;
  background: #dbeafe;
  color: #1d4ed8;
}
.teacher-comment-meta strong {
  color: #334155;
}
.teacher-comment-meta time {
  color: #64748b;
}
.teacher-comment-item p {
  margin: 0;
  color: #0f172a;
  line-height: 1.6;
  white-space: pre-wrap;
}
.student-linked-comment {
  border-left-color: #f59e0b;
}
.student-comment-quote {
  margin: 0;
  padding: 10px 12px;
  border-left: 4px solid #f59e0b;
  border-radius: 10px;
  background: #fffbeb;
  color: #334155;
  line-height: 1.55;
}
.student-comment-quote mark {
  padding: 2px 4px;
  border-radius: 5px;
  background: #fef3c7;
  color: inherit;
}
.student-feedback-report-link {
  display: block;
  color: inherit;
  text-decoration: none;
}
.student-feedback-report-link:hover {
  border-color: #93c5fd;
  box-shadow: 0 10px 24px rgba(37, 99, 235, .12);
}
.student-feedback-list.compact,
.student-feedback-item.compact {
  gap: 6px;
}
.student-feedback-item.compact {
  padding: 10px;
  background: #fff;
}
.student-archive-list {
  display: grid;
  gap: 10px;
}
.student-archive-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid #dbeafe;
  border-radius: 12px;
  background: #fff;
}
.student-archive-item span {
  display: block;
  margin-top: 4px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}
@media (max-width: 900px) {
  .teacher-review-split,
  .teacher-review-row,
  .student-archive-item,
  .teacher-review-queue-row,
  .teacher-comment-panel {
    grid-template-columns: 1fr;
  }
  .teacher-review-queue-row em {
    justify-self: start;
  }
}
.login-page-card h2 {
  margin: 0;
  color: #0f172a;
  font-size: 24px;
  letter-spacing: 0;
}
.login-error {
  background: #fee2e2;
  color: #991b1b;
}
.iepq-project-card h2,
.iepq-stage-card h2,
.iepq-source-card h2,
.iepq-checklist-card h2,
.iepq-empty-state h2 {
  margin: 0 0 8px;
  color: #0f172a;
  font-size: 21px;
  letter-spacing: 0;
}
.iepq-project-card p,
.iepq-stage-card p,
.iepq-source-card p,
.iepq-checklist-card p,
.iepq-empty-state p,
.iepq-guidance-card p {
  margin: 0;
  color: #475569;
  line-height: 1.6;
}
.iepq-stage-card small {
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}
.iepq-source-card small {
  display: block;
  margin-top: 10px;
  color: #64748b;
  font-size: 12px;
  line-height: 1.5;
}
.iepq-source-card a:not(.home-button) {
  display: inline-flex;
  width: fit-content;
  margin-top: 10px;
  color: #0f766e;
  font-size: 13px;
  font-weight: 850;
  text-decoration: none;
}
.iepq-source-card a:not(.home-button):hover {
  text-decoration: underline;
}
.iepq-source-summary {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 18px;
}
.iepq-source-summary div {
  padding: 14px;
  border: 1px solid #ccfbf1;
  border-radius: 8px;
  background: #fff;
}
.iepq-source-summary strong,
.iepq-source-summary span {
  display: block;
}
.iepq-source-summary strong {
  color: #0f172a;
  font-size: 26px;
  line-height: 1;
}
.iepq-source-summary span {
  margin-top: 6px;
  color: #64748b;
  font-size: 12px;
  font-weight: 850;
}
.iepq-stage-progress,
.iepq-overall-progress {
  height: 9px;
  overflow: hidden;
  border-radius: 999px;
  background: #e2e8f0;
}
.iepq-stage-progress span,
.iepq-overall-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #14b8a6, #2563eb);
}
.iepq-overall-progress {
  max-width: 520px;
  margin-top: 14px;
}
.iepq-checklist-card {
  margin: 10px 0 18px;
  padding: 18px;
  border-color: #99f6e4;
  background: linear-gradient(180deg, #fff, #f0fdfa);
}
.iepq-time-card {
  display: grid;
  gap: 12px;
  margin: 10px 0 18px;
  padding: 18px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: linear-gradient(180deg, #fff, #eff6ff);
  box-shadow: 0 10px 30px rgba(37, 99, 235, .08);
}
.iepq-time-card span {
  color: #475569;
  font-size: 13px;
  font-weight: 850;
}
.iepq-time-card strong {
  display: block;
  margin: 4px 0;
  color: #1d4ed8;
  font-size: 34px;
  line-height: 1;
}
.iepq-time-card p,
.iepq-time-card small {
  margin: 0;
  color: #475569;
  line-height: 1.5;
}
.iepq-time-timeline {
  position: relative;
  display: grid;
  gap: 10px;
  margin-top: 4px;
}
.iepq-time-timeline::before {
  content: "";
  position: absolute;
  left: 20px;
  top: 20px;
  bottom: 20px;
  width: 2px;
  background: #bfdbfe;
}
.iepq-time-node {
  position: relative;
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 12px;
  padding: 12px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: rgba(255, 255, 255, .9);
  color: inherit;
  text-decoration: none;
}
.iepq-time-node:hover {
  border-color: #2563eb;
  box-shadow: 0 8px 22px rgba(37, 99, 235, .12);
}
.iepq-time-dot {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  background: #2563eb;
  color: #fff !important;
  font-weight: 900;
}
.iepq-time-node strong {
  margin: 0 0 3px;
  color: #1e3a8a;
  font-size: 16px;
  line-height: 1.2;
}
.iepq-time-node small {
  display: block;
  margin-bottom: 5px;
  color: #2563eb;
  font-weight: 850;
}
.iepq-time-node p {
  color: #475569;
  font-size: 13px;
}
.iepq-plan-summary {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  margin: 12px 0 18px;
}
.iepq-plan-summary div {
  padding: 16px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, .05);
}
.iepq-plan-summary strong {
  display: block;
  color: #1d4ed8;
  font-size: 25px;
  line-height: 1;
}
.iepq-plan-summary span {
  display: block;
  margin-top: 7px;
  color: #64748b;
  font-size: 12px;
  font-weight: 850;
}
.iepq-plan-generator {
  margin: -2px 0 16px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, .045);
}
.iepq-plan-generator > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 16px;
  cursor: pointer;
  list-style: none;
}
.iepq-plan-generator > summary::-webkit-details-marker {
  display: none;
}
.iepq-plan-generator > summary strong {
  display: block;
  color: #0f172a;
  font-size: 15px;
}
.iepq-plan-generator > summary span:not(.iepq-plan-edit-hint) {
  display: block;
  margin-top: 3px;
  color: #64748b;
  font-size: 12px;
  font-weight: 750;
}
.iepq-plan-generator[open] > summary {
  border-bottom: 1px solid #e2e8f0;
}
.iepq-plan-generator form {
  display: grid;
  gap: 12px;
  padding: 14px 16px 16px;
  animation: iepq-expand-in 180ms ease-out both;
}
.iepq-generator-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}
.iepq-generator-grid.compact {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.iepq-plan-generator label {
  display: grid;
  gap: 6px;
}
.iepq-plan-generator label span {
  color: #334155;
  font-size: 12px;
  font-weight: 900;
}
.iepq-plan-generator input,
.iepq-plan-generator select,
.iepq-plan-generator textarea {
  width: 100%;
  padding: 9px 10px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #fff;
  color: #0f172a;
  font: 14px/1.45 Arial, Helvetica, sans-serif;
}
.iepq-generator-focus {
  max-width: 920px;
}
.iepq-plan-generator p {
  margin: 0;
  color: #64748b;
  font-size: 12px;
  line-height: 1.55;
}
.iepq-plan-generator button {
  width: fit-content;
}
.iepq-availability-builder {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #f8fbff;
}
.iepq-availability-head,
.iepq-availability-title,
.iepq-time-slot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.iepq-availability-head strong,
.iepq-availability-title strong {
  display: block;
  color: #0f172a;
  font-size: 14px;
}
.iepq-availability-head span {
  display: block;
  margin-top: 3px;
  color: #64748b;
  font-size: 12px;
  font-weight: 750;
}
.iepq-availability-block {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #fff;
}
.iepq-weekday-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.iepq-weekday-row label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 7px 9px;
  border: 1px solid #dbeafe;
  border-radius: 999px;
  background: #eff6ff;
  color: #1e3a8a;
  font-size: 12px;
  font-weight: 850;
}
.iepq-weekday-row input {
  width: auto;
  margin: 0;
}
.iepq-time-slot-list {
  display: grid;
  gap: 8px;
}
.iepq-time-slot {
  justify-content: flex-start;
  padding: 8px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #f8fafc;
}
.iepq-time-slot label {
  width: min(220px, 100%);
}
@media (max-width: 900px) {
  .iepq-generator-grid,
  .iepq-generator-grid.compact {
    grid-template-columns: 1fr;
  }
  .iepq-availability-head,
  .iepq-availability-title,
  .iepq-time-slot {
    align-items: stretch;
    flex-direction: column;
  }
  .iepq-time-slot label {
    width: 100%;
  }
}
.iepq-plan-nav {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0;
  padding: 10px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: rgba(248, 250, 252, .94);
  backdrop-filter: blur(10px);
}
.iepq-plan-nav a {
  padding: 8px 11px;
  border-radius: 999px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 13px;
  font-weight: 900;
  text-decoration: none;
}
.iepq-plan-nav a:hover {
  background: #dbeafe;
}
.iepq-plan-page-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0 16px;
  padding: 8px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, .04);
}
.iepq-plan-page-tabs a {
  flex: 1 1 170px;
  padding: 11px 12px;
  border-radius: 8px;
  background: #f8fafc;
  color: #334155;
  font-size: 13px;
  font-weight: 900;
  text-align: center;
  text-decoration: none;
}
.iepq-plan-page-tabs a:hover {
  background: #eff6ff;
  color: #1d4ed8;
}
.iepq-plan-page-tabs a.is-active {
  background: #2563eb;
  color: #fff;
  box-shadow: 0 8px 20px rgba(37, 99, 235, .18);
}
.iepq-planning-board {
  position: relative;
  display: grid;
  gap: 14px;
  margin: 18px 0 40px;
}
.iepq-plan-phase {
  position: relative;
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 14px;
}
.iepq-plan-phase::before {
  content: "";
  position: absolute;
  left: 20px;
  top: 44px;
  bottom: -14px;
  width: 2px;
  background: linear-gradient(180deg, #bfdbfe, #dbeafe);
}
.iepq-plan-phase:last-child::before {
  display: none;
}
.iepq-plan-phase-marker {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  margin-top: 8px;
  border: 5px solid #dbeafe;
  border-radius: 999px;
  background: #fff;
  color: #1d4ed8;
  font-size: 16px;
  font-weight: 950;
  box-shadow: 0 10px 22px rgba(37, 99, 235, .12);
}
.iepq-plan-phase-body {
  position: relative;
  min-width: 0;
}
.iepq-plan-phase-summary {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 52px;
  padding: 10px 12px 10px 0;
  border: 0;
  border-bottom: 1px solid transparent;
  border-radius: 0;
  background: transparent;
  cursor: pointer;
  list-style: none;
  transition: border-color 160ms ease, background-color 160ms ease;
  outline: none;
}
.iepq-plan-phase-summary::-webkit-details-marker {
  display: none;
}
.iepq-plan-phase-summary:hover {
  border-bottom-color: #dbeafe;
  background: transparent;
}
.iepq-plan-phase-summary:focus-visible {
  border-bottom-color: #93c5fd;
  box-shadow: 0 8px 22px rgba(37, 99, 235, .08);
}
.iepq-plan-phase-summary h2 {
  margin: 0;
  color: #0f172a;
  font-size: 19px;
  line-height: 1.15;
  letter-spacing: 0;
}
.iepq-plan-phase-summary span {
  display: block;
  margin-top: 3px;
  color: #64748b;
  font-size: 12px;
  font-weight: 850;
}
.iepq-phase-tooltip {
  position: absolute;
  left: 14px;
  top: calc(100% + 8px);
  z-index: 8;
  display: none;
  max-width: min(720px, calc(100vw - 120px));
  padding: 12px 14px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #fff;
  color: #334155;
  box-shadow: 0 16px 38px rgba(15, 23, 42, .14);
  font-size: 13px;
  font-weight: 750;
  line-height: 1.55;
}
.iepq-plan-phase-summary:hover .iepq-phase-tooltip {
  display: block;
}
.iepq-plan-phase-expanded {
  display: grid;
  gap: 8px;
  margin: 4px 0 0 0;
  padding: 8px 0 4px 18px;
  border-left: 2px solid #e0f2fe;
}
.iepq-phase-expanded-note {
  margin: 0;
  color: #475569;
  line-height: 1.6;
}
.iepq-phase-topline {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 12px;
  align-items: center;
  padding: 6px 0 10px 28px;
}
.iepq-phase-topline::before {
  content: "";
  position: absolute;
  left: -28px;
  top: 20px;
  width: 14px;
  height: 14px;
  border: 3px solid #93c5fd;
  border-radius: 999px;
  background: #f8fbff;
  box-shadow: 0 0 0 6px #f8fbff;
}
.iepq-phase-hours-form {
  grid-column: 2;
  grid-row: 1;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px;
  border: 1px solid #dbeafe;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 8px 20px rgba(15, 23, 42, .04);
}
.iepq-phase-hours-form label {
  display: flex;
  align-items: center;
  gap: 6px;
}
.iepq-phase-hours-form label span {
  color: #334155;
  font-size: 12px;
  font-weight: 900;
}
.iepq-phase-hours-form input {
  width: 62px;
  padding: 6px 8px;
  border: 1px solid #cbd5e1;
  border-radius: 999px;
  color: #0f172a;
  font: 13px/1.3 Arial, Helvetica, sans-serif;
}
.iepq-phase-hours-form button {
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
}
.iepq-log-link {
  grid-column: 3;
  grid-row: 1;
  width: fit-content;
  justify-self: end;
  min-height: 34px;
  padding-inline: 12px;
  border-radius: 999px;
}
.iepq-phase-hours {
  color: #1d4ed8;
  font-weight: 900;
  white-space: nowrap;
}
.iepq-plan-phase-body h2,
.iepq-plan-task h3,
.iepq-plan-add-card h3 {
  margin: 0;
  color: #0f172a;
  letter-spacing: 0;
}
.iepq-plan-phase-body p {
  margin: 0;
  color: #475569;
  line-height: 1.6;
}
.iepq-plan-task-list {
  position: relative;
  display: grid;
  gap: 7px;
}
.iepq-plan-add-details {
  position: relative;
  padding-left: 34px;
  border: 0;
  border-radius: 0;
  background: transparent;
}
.iepq-plan-add-details::before {
  content: "+";
  position: absolute;
  left: -35px;
  top: 9px;
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  border: 3px solid #93c5fd;
  border-radius: 999px;
  background: #f8fbff;
  color: #2563eb;
  box-shadow: 0 0 0 7px #f8fbff;
  font-size: 13px;
  font-weight: 950;
}
.iepq-plan-add-details > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 38px;
  padding: 7px 10px;
  border-radius: 999px;
  color: #0f172a;
  font-size: 14px;
  font-weight: 950;
  cursor: pointer;
  list-style: none;
  transition: background-color 160ms ease, color 160ms ease, transform 160ms ease;
}
.iepq-plan-add-details > summary:hover {
  background: #eff6ff;
  color: #1d4ed8;
  transform: translateX(2px);
}
.iepq-plan-add-details > summary::-webkit-details-marker {
  display: none;
}
.iepq-plan-add-details > summary::after {
  content: "Add";
  padding: 3px 9px;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 12px;
}
.iepq-plan-add-details[open] > summary {
  background: #eff6ff;
}
.iepq-plan-task-wrap {
  display: grid;
  gap: 8px;
}
.iepq-plan-subtasks {
  position: relative;
  display: grid;
  gap: 8px;
  margin: -2px 0 2px 32px;
  padding-left: 24px;
}
.iepq-plan-subtasks::before {
  content: "";
  position: absolute;
  left: 0;
  top: -5px;
  bottom: 12px;
  width: 2px;
  border-radius: 999px;
  background: linear-gradient(#bfdbfe, #dbeafe);
}
.iepq-plan-task-wrap.is-depth-1 .iepq-plan-task-summary strong,
.iepq-plan-task-wrap.is-depth-2 .iepq-plan-task-summary strong,
.iepq-plan-task-wrap.is-depth-3 .iepq-plan-task-summary strong,
.iepq-plan-task-wrap.is-depth-4 .iepq-plan-task-summary strong {
  font-size: 14px;
}
.iepq-plan-task {
  position: relative;
  display: grid;
  gap: 8px;
  padding: 0 0 0 34px;
  border: 0;
  border-radius: 0;
  background: transparent;
}
.iepq-plan-task::before {
  content: "";
  position: absolute;
  left: -35px;
  top: 11px;
  width: 18px;
  height: 18px;
  border: 3px solid #93c5fd;
  border-radius: 999px;
  background: #f8fbff;
  box-shadow: 0 0 0 7px #f8fbff;
  transition: border-color 160ms ease, background-color 160ms ease, transform 160ms ease;
}
.iepq-plan-task[open]::before {
  border-color: #2563eb;
  background: #dbeafe;
  transform: scale(1.08);
}
.iepq-plan-task.is-locked::before {
  border-color: #fca5a5;
}
.iepq-plan-add-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 14px 34px rgba(15, 23, 42, .06);
  animation: iepq-expand-in 180ms ease-out both;
}
.iepq-plan-add-details .iepq-plan-add-card {
  margin-top: 8px;
}
.iepq-plan-task.is-required {
  border-color: transparent;
  background: transparent;
}
.iepq-plan-task.is-locked {
  border-color: transparent;
  background: transparent;
}
.iepq-plan-task-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 42px;
  padding: 7px 10px;
  border-radius: 999px;
  cursor: pointer;
  list-style: none;
  transition: background-color 160ms ease, transform 160ms ease;
  outline: none;
}
.iepq-plan-task-summary:hover {
  background: #eff6ff;
  transform: translateX(2px);
}
.iepq-plan-task[open] .iepq-plan-task-summary {
  background: #eff6ff;
}
.iepq-plan-task-summary:focus-visible,
.iepq-plan-add-details > summary:focus-visible {
  box-shadow: 0 0 0 3px rgba(147, 197, 253, .28);
}
.iepq-plan-task-summary::-webkit-details-marker {
  display: none;
}
.iepq-plan-task-summary strong {
  display: block;
  color: #0f172a;
  font-size: 15px;
}
.iepq-plan-task-summary .iepq-task-meta {
  display: block;
  margin-top: 3px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}
.iepq-plan-summary-right {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}
.iepq-plan-edit-hint {
  display: inline-flex !important;
  align-items: center;
  min-height: 30px;
  margin: 0 !important;
  padding: 0 10px;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  background: #eff6ff;
  color: #1d4ed8 !important;
  font-size: 12px !important;
  font-weight: 900 !important;
}
.iepq-inline-delete-form {
  display: inline-flex;
  margin: 0;
}
.iepq-inline-delete-button {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid #fecaca;
  border-radius: 999px;
  background: #fff1f2;
  color: #be123c;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}
.iepq-inline-delete-button:hover {
  background: #ffe4e6;
}
.iepq-inline-delete-button:disabled {
  cursor: not-allowed;
  opacity: .55;
}
.iepq-breakdown-button,
.iepq-insert-button {
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid #c7d2fe;
  border-radius: 999px;
  background: #eef2ff;
  color: #4338ca;
  font-size: 12px;
  font-weight: 900;
}
.iepq-breakdown-button:hover,
.iepq-insert-button:hover {
  background: #e0e7ff;
}
.iepq-insert-button {
  justify-self: start;
}
.iepq-breakdown-panel,
.iepq-insert-panel {
  margin: 0 14px 12px;
  padding: 0;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #f8fbff;
}
.iepq-insert-panel {
  background: #fbfdff;
}
.iepq-breakdown-panel > summary,
.iepq-insert-panel > summary {
  padding: 10px 12px;
  color: #1d4ed8;
  cursor: pointer;
  font-size: 13px;
  font-weight: 950;
  list-style: none;
}
.iepq-breakdown-panel > summary::-webkit-details-marker,
.iepq-insert-panel > summary::-webkit-details-marker {
  display: none;
}
.iepq-breakdown-panel form,
.iepq-insert-panel form {
  display: grid;
  gap: 10px;
  padding: 0 12px 12px;
}
.iepq-insert-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.iepq-breakdown-panel label,
.iepq-insert-panel label {
  display: grid;
  gap: 6px;
}
.iepq-breakdown-panel label span,
.iepq-insert-panel label span {
  color: #334155;
  font-size: 12px;
  font-weight: 900;
}
.iepq-breakdown-panel textarea,
.iepq-insert-panel textarea,
.iepq-insert-panel input,
.iepq-insert-panel select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  color: #0f172a;
  font: inherit;
  line-height: 1.5;
}
.iepq-breakdown-panel textarea,
.iepq-insert-panel textarea {
  min-height: 92px;
  resize: vertical;
}
.iepq-insert-panel textarea {
  min-height: 62px;
}
.iepq-breakdown-panel p {
  margin: 0;
  color: #64748b;
  font-size: 12px;
  font-weight: 750;
  line-height: 1.5;
}
.iepq-status-label {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 2px 8px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 11px;
  font-weight: 950;
  white-space: nowrap;
}
.iepq-status-label.is-not_started {
  border-color: #cbd5e1;
  background: #f8fafc;
  color: #475569;
}
.iepq-status-label.is-in_progress {
  border-color: #bfdbfe;
  background: #eff6ff;
  color: #1d4ed8;
}
.iepq-status-label.is-done {
  border-color: #bbf7d0;
  background: #f0fdf4;
  color: #15803d;
}
.iepq-status-label.is-delayed {
  border-color: #fed7aa;
  background: #fff7ed;
  color: #c2410c;
}
.iepq-status-label.is-changed {
  border-color: #ddd6fe;
  background: #f5f3ff;
  color: #6d28d9;
}
.iepq-plan-task[open] .iepq-plan-edit-hint {
  background: #dbeafe;
}
.note-chip.is-locked {
  background: #fee2e2;
  color: #991b1b;
}
.iepq-plan-task-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px 0;
  border: 1px solid #dbeafe;
  border-bottom: 0;
  border-radius: 8px 8px 0 0;
  background: #fff;
  animation: iepq-expand-in 180ms ease-out both;
}
.iepq-plan-task-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}
.iepq-plan-task-form {
  display: grid;
  gap: 12px;
  padding: 0 14px 14px;
  border: 1px solid #dbeafe;
  border-top: 0;
  border-radius: 0 0 8px 8px;
  background: #fff;
  box-shadow: 0 14px 34px rgba(15, 23, 42, .06);
  animation: iepq-expand-in 180ms ease-out both;
}
.iepq-plan-task-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}
.iepq-plan-task label,
.iepq-plan-add-card label {
  display: grid;
  gap: 6px;
}
.iepq-plan-task label span,
.iepq-plan-add-card label span {
  color: #334155;
  font-size: 12px;
  font-weight: 900;
}
.iepq-plan-task input,
.iepq-plan-task select,
.iepq-plan-task textarea,
.iepq-plan-add-card input,
.iepq-plan-add-card select,
.iepq-plan-add-card textarea {
  width: 100%;
  padding: 9px 10px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #fff;
  color: #0f172a;
  font: 14px/1.45 Arial, Helvetica, sans-serif;
  letter-spacing: 0;
}
.iepq-plan-task textarea,
.iepq-plan-add-card textarea {
  resize: vertical;
}
.iepq-plan-task input:focus,
.iepq-plan-task select:focus,
.iepq-plan-task textarea:focus,
.iepq-plan-add-card input:focus,
.iepq-plan-add-card select:focus,
.iepq-plan-add-card textarea:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, .12);
  outline: none;
}
.iepq-lock-note {
  margin: 0;
  color: #991b1b;
  font-size: 13px;
  font-weight: 800;
}
.iepq-save-note.is-warning {
  border-color: #fed7aa;
  background: #fff7ed;
  color: #9a3412;
}
.iepq-plan-confirm-card,
.iepq-plan-export-card,
.iepq-plan-compare-card {
  display: grid;
  gap: 12px;
  margin: 12px 0 18px;
  padding: 16px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #f8fbff;
  box-shadow: 0 8px 24px rgba(37, 99, 235, .06);
}
.iepq-plan-confirm-card,
.iepq-plan-export-card {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}
.iepq-plan-confirm-card strong,
.iepq-plan-export-card strong,
.iepq-plan-compare-card h2 {
  margin: 0;
  color: #1e3a8a;
}
.iepq-plan-confirm-card p,
.iepq-plan-export-card p,
.iepq-plan-compare-card p {
  margin: 5px 0 0;
  color: #475569;
  line-height: 1.55;
}
.iepq-plan-export-card form {
  display: flex;
  align-items: flex-end;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}
.iepq-plan-export-card label {
  display: grid;
  gap: 5px;
}
.iepq-plan-export-card label span {
  color: #334155;
  font-size: 12px;
  font-weight: 900;
}
.iepq-plan-export-card select {
  min-width: 140px;
  min-height: 38px;
  padding: 0 10px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #fff;
  color: #0f172a;
  font: inherit;
}
.iepq-plan-compare-card ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.iepq-plan-compare-card li {
  padding: 10px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #fff;
}
.iepq-plan-compare-card li strong,
.iepq-plan-compare-card li span {
  display: block;
}
.iepq-plan-compare-card li span {
  margin-top: 4px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}
.iepq-empty-state {
  grid-column: 1 / -1;
  padding: 24px;
}
.iepq-form-card {
  display: grid;
  gap: 16px;
  max-width: 920px;
  padding: clamp(18px, 3vw, 26px);
}
.iepq-form-card label {
  display: grid;
  gap: 8px;
}
.iepq-form-card label span {
  color: #0f172a;
  font-size: 14px;
  font-weight: 850;
}
.iepq-form-card textarea,
.iepq-form-card input,
.iepq-form-card select {
  width: 100%;
  padding: 11px 12px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #fff;
  color: #0f172a;
  font: 15px/1.55 Arial, Helvetica, sans-serif;
  letter-spacing: 0;
}
.iepq-form-card textarea:focus,
.iepq-form-card input:focus,
.iepq-form-card select:focus {
  border-color: #14b8a6;
  box-shadow: 0 0 0 3px rgba(20, 184, 166, .14);
  outline: none;
}
.iepq-form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.iepq-form-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.iepq-form-section-title {
  margin: 8px 0 0;
  padding-top: 12px;
  border-top: 1px solid #e2e8f0;
  color: #0f172a;
  font-size: 21px;
  letter-spacing: 0;
}
.iepq-decision-box {
  display: grid;
  gap: 14px;
  padding: 16px;
  border: 2px solid #2563eb;
  border-radius: 8px;
  background: #eff6ff;
}
.iepq-decision-box h2 {
  margin: 0 0 5px;
  color: #1e3a8a;
  font-size: 22px;
  letter-spacing: 0;
}
.iepq-decision-box p {
  margin: 0;
  color: #334155;
  line-height: 1.55;
}
.iepq-decision-box > label {
  max-width: 360px;
}
.iepq-decision-box select {
  border-color: #93c5fd;
  font-weight: 850;
}
.iepq-decision-help {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 10px;
}
.iepq-decision-help article {
  padding: 12px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #fff;
}
.iepq-decision-help strong {
  display: block;
  margin-bottom: 5px;
  color: #1d4ed8;
  font-size: 14px;
}
.iepq-decision-help p {
  color: #475569;
  font-size: 13px;
}
.iepq-guidance-card {
  max-width: 920px;
  margin-top: 14px;
  padding: 16px;
  border-color: #99f6e4;
}
.iepq-tool-card {
  display: grid;
  gap: 12px;
  max-width: 920px;
  margin: 0 0 14px;
  padding: 16px;
  border: 1px solid #ccfbf1;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 9px 28px rgba(15, 23, 42, .045);
}
.iepq-tool-card h2 {
  margin: 0 0 6px;
  color: #0f172a;
  font-size: 19px;
  letter-spacing: 0;
}
.iepq-tool-card p {
  margin: 0;
  color: #475569;
  line-height: 1.55;
}
.iepq-lookup-row {
  display: grid;
  grid-template-columns: minmax(120px, .55fr) minmax(220px, 1.45fr) auto;
  gap: 10px;
}
.iepq-dimension-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.iepq-dimension-grid label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 34px;
  padding: 7px 11px;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  background: #eff6ff;
  color: #1e3a8a;
  font-size: 13px;
  font-weight: 800;
}
.iepq-dimension-grid input {
  width: 15px;
  height: 15px;
  accent-color: #2563eb;
}
.iepq-lookup-row input,
.iepq-lookup-row select {
  width: 100%;
  min-height: 42px;
  padding: 9px 10px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  color: #0f172a;
  font: 14px/1.4 Arial, Helvetica, sans-serif;
}
.iepq-tool-message {
  min-height: 18px;
  color: #0f766e;
  font-size: 13px;
  font-weight: 800;
}
.iepq-tool-message.is-warning {
  padding: 9px 11px;
  border: 1px solid #fecaca;
  border-radius: 8px;
  background: #fef2f2;
  color: #b91c1c;
}
.iepq-tool-message.is-error {
  color: #b91c1c;
}
.iepq-quality-metrics {
  display: grid;
  gap: 10px;
  padding: 13px;
  border: 1px solid #fde68a;
  border-radius: 8px;
  background: #fffbeb;
}
.iepq-quality-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}
.iepq-quality-head strong {
  color: #92400e;
  font-size: 15px;
}
.iepq-quality-head span,
.iepq-quality-metrics p {
  margin: 0;
  color: #78716c;
  font-size: 12px;
  line-height: 1.45;
}
.iepq-quality-metrics dl {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 8px;
  margin: 0;
}
.iepq-quality-metrics dl div {
  padding: 9px;
  border: 1px solid #fef3c7;
  border-radius: 8px;
  background: #fff;
}
.iepq-quality-metrics dt {
  margin-bottom: 3px;
  color: #a16207;
  font-size: 12px;
  font-weight: 900;
}
.iepq-quality-metrics dd {
  margin: 0;
  color: #1f2937;
  font-size: 14px;
  font-weight: 800;
  overflow-wrap: anywhere;
}
.iepq-ai-use-card {
  display: grid;
  gap: 14px;
  max-width: 920px;
  margin: 0 0 14px;
  padding: 16px;
  border: 1px solid #c7d2fe;
  border-radius: 8px;
  background: #f8f7ff;
}
.iepq-ai-use-card.compact {
  margin-top: 0;
}
.iepq-ai-use-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.iepq-ai-use-head strong {
  display: block;
  color: #3730a3;
  font-size: 17px;
}
.iepq-ai-use-head p {
  margin: 6px 0 0;
  color: #475569;
  line-height: 1.55;
}
.iepq-strategy-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 12px;
}
.iepq-strategy-grid article {
  padding: 13px;
  border: 1px solid #ddd6fe;
  border-radius: 8px;
  background: #fff;
}
.iepq-strategy-grid h3 {
  margin: 0 0 8px;
  color: #312e81;
  font-size: 15px;
}
.iepq-strategy-grid ul {
  margin: 0;
  padding-left: 19px;
  color: #334155;
  line-height: 1.55;
}
.iepq-strategy-grid p {
  margin: 0 0 10px;
  color: #334155;
  line-height: 1.6;
}
.iepq-suggestion-panel {
  display: grid;
  gap: 12px;
  margin-top: 4px;
  padding: 14px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #f8fbff;
}
.iepq-suggestion-panel[hidden] {
  display: none;
}
.iepq-suggestion-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.iepq-suggestion-head strong {
  display: block;
  color: #1e3a8a;
  font-size: 16px;
}
.iepq-suggestion-head p,
.iepq-suggestion-note {
  margin: 5px 0 0;
  color: #64748b;
  font-size: 13px;
  line-height: 1.5;
}
.iepq-suggestion-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 10px;
}
.iepq-suggestion-item {
  display: grid;
  gap: 10px;
  align-content: space-between;
  padding: 12px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #fff;
}
.iepq-suggestion-item span {
  display: inline-block;
  margin-bottom: 6px;
  color: #2563eb;
  font-size: 13px;
  font-weight: 900;
}
.iepq-suggestion-item p {
  color: #1f2937;
  font-size: 14px;
  line-height: 1.6;
}
.iepq-guidance-card strong {
  display: block;
  margin-bottom: 6px;
  color: #0f766e;
}
.iepq-mid-review-guide {
  border-color: #bfdbfe;
  background: linear-gradient(180deg, #f8fbff 0%, #fff 100%);
}
.iepq-mid-review-guide strong {
  color: #1d4ed8;
}
.iepq-mid-review-guide ul {
  display: grid;
  gap: 7px;
  margin: 12px 0 0;
  padding-left: 19px;
  color: #334155;
  font-size: 14px;
  line-height: 1.5;
}
.iepq-mid-review-guide li::marker {
  color: #2563eb;
}
.iepq-save-note {
  width: fit-content;
  margin: 0 0 14px;
  padding: 8px 12px;
  border-radius: 8px;
  background: #dcfce7;
  color: #047857;
  font-weight: 850;
}
.iepq-login-warning {
  margin: 0 0 18px;
}

.notes-shell,
.note-shell {
  max-width: 1180px;
  margin: 0 auto;
  padding: 48px clamp(18px, 5vw, 72px) 72px;
}
.notes-hero {
  max-width: 760px;
  margin-bottom: 28px;
}
.notes-hero h1 {
  margin: 0;
  color: #0f172a;
  font-size: clamp(34px, 5vw, 56px);
  line-height: 1.08;
}
.notes-hero p:not(.home-kicker) {
  color: #475569;
  font-size: 18px;
  line-height: 1.65;
}
.notes-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.note-card,
.note-empty {
  padding: 24px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: linear-gradient(180deg, #fff, #f8fbff);
  box-shadow: 0 12px 32px rgba(37, 99, 235, .08);
}
.note-card h2 {
  margin: 12px 0 10px;
  color: #0f172a;
  font-size: 24px;
  letter-spacing: 0;
}
.note-card p,
.note-card__meta,
.note-muted {
  color: #475569;
  line-height: 1.6;
}
.note-card__meta {
  margin: 14px 0 18px;
  font-size: 14px;
  font-weight: 700;
}
.note-card__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.note-chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 9px;
  border-radius: 999px;
  background: #dbeafe;
  color: #1d4ed8;
  font-size: 12px;
  font-weight: 800;
}
.notes-page {
  background:
    linear-gradient(180deg, #f8fbff 0, #f6f8fb 280px, #f8fafc 100%);
}
.note-article {
  max-width: 980px;
  margin: 0 auto;
  display: grid;
  gap: 16px;
}
.note-back {
  display: inline-flex;
  width: fit-content;
  margin-bottom: 2px;
  color: #2563eb;
  font-weight: 800;
  text-decoration: none;
}
.note-detail-hero,
.note-body-card,
.note-linked {
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: rgba(255, 255, 255, .96);
  box-shadow: 0 14px 34px rgba(37, 99, 235, .08);
}
.note-detail-hero {
  padding: clamp(22px, 4vw, 34px);
}
.note-detail-hero h1 {
  max-width: 760px;
  margin: 14px 0 10px;
  color: #0f172a;
  font-size: clamp(34px, 5vw, 52px);
  line-height: 1.04;
  letter-spacing: 0;
}
.note-detail-hero p {
  max-width: 720px;
  margin: 0 0 18px;
  color: #475569;
  font-size: 17px;
  line-height: 1.65;
}
.note-body-card {
  padding: clamp(18px, 3.5vw, 34px);
}
.note-body {
  color: #334155;
  font-size: 15px;
  line-height: 1.72;
}
.note-body h1 {
  margin: 12px 0 18px;
  color: #0f172a;
  font-size: clamp(32px, 4.5vw, 48px);
  line-height: 1.08;
  letter-spacing: 0;
}
.note-body h2 {
  margin: 30px 0 14px;
  padding: 11px 14px;
  border-left: 4px solid #2563eb;
  border-radius: 8px;
  background: #eff6ff;
  color: #1e3a8a;
  font-size: 22px;
  letter-spacing: 0;
}
.note-body h2:first-child {
  margin-top: 0;
}
.note-body h3 {
  margin: 22px 0 8px;
  color: #0f172a;
  font-size: 18px;
  letter-spacing: 0;
}
.note-body p {
  margin: 9px 0;
}
.note-body hr {
  height: 1px;
  margin: 24px 0 18px;
  border: 0;
  background: #e2e8f0;
}
.note-body ul {
  margin: 8px 0 20px;
  padding-left: 0;
  list-style: none;
}
.note-body li {
  position: relative;
  margin: 5px 0;
  padding: 4px 0 4px 22px;
}
.note-body li::before {
  content: "";
  position: absolute;
  top: 14px;
  left: 5px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #93c5fd;
}
.note-body strong {
  color: #1e3a8a;
  font-weight: 750;
}
.note-body code {
  padding: 2px 5px;
  border-radius: 5px;
  background: #eff6ff;
  color: #1e3a8a;
  font-size: .94em;
}
.note-body blockquote {
  margin: 12px 0 18px;
  padding: 14px 16px;
  border-left: 4px solid #2563eb;
  background: #f8fbff;
  border-radius: 0 8px 8px 0;
  color: #1e293b;
  font-weight: 750;
}
.note-table-wrap {
  overflow-x: auto;
  margin: 14px 0 24px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, .05);
}
.note-table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
  font-size: 14px;
  line-height: 1.5;
}
.note-table th,
.note-table td {
  padding: 12px 14px;
  border-bottom: 1px solid #e2e8f0;
  text-align: left;
  vertical-align: top;
}
.note-table th {
  background: #eff6ff;
  color: #1e3a8a;
  font-weight: 850;
}
.note-table tr:last-child td {
  border-bottom: 0;
}
.note-body pre {
  overflow-x: auto;
  padding: 14px;
  border-radius: 8px;
  background: #0f172a;
  color: #e2e8f0;
}
.note-linked {
  padding: clamp(18px, 3vw, 24px);
}
.note-linked h2 {
  margin: 0 0 8px;
  color: #0f172a;
  font-size: 21px;
}
.note-linked p {
  margin: 0 0 14px;
  color: #475569;
  line-height: 1.6;
}
.note-practice-cta {
  width: fit-content;
  margin: 4px 0 12px;
}
.note-evidence {
  margin-top: 8px;
}
.note-evidence summary {
  width: fit-content;
  cursor: pointer;
  color: #2563eb;
  font-size: 14px;
  font-weight: 850;
}
.note-question-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}
.note-question-link {
  display: inline-flex;
  padding: 6px 8px;
  border-radius: 8px;
  background: #fff;
  color: #1d4ed8;
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
  box-shadow: inset 0 0 0 1px #bfdbfe;
}

.resource-guide {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  width: 100%;
  max-width: 1120px;
  margin: 24px auto 0;
  text-align: left;
}
.resource-guide article {
  padding: 18px 20px;
  border: 1px solid #dbeafe;
  border-left: 4px solid #2563eb;
  border-radius: 8px;
  background: #f8fbff;
  box-shadow: 0 8px 24px rgba(37, 99, 235, 0.06);
  transition: border-color 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}
.resource-guide article:hover {
  border-color: #93c5fd;
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(37, 99, 235, 0.11);
}
.resource-guide strong {
  display: block;
  margin-bottom: 7px;
  color: #1e3a8a;
  font-size: 15px;
}
.resource-guide p {
  margin: 0;
  color: #475569;
  font-size: 14px;
  line-height: 1.6;
}

.resource-shell {
  display: grid;
  gap: 24px;
  width: 100%;
  max-width: 1264px;
  margin: 0 auto;
}
.resource-page .section-head {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  text-align: center;
  animation: resource-rise 420ms ease-out both;
}
.resource-page .section-head h2 {
  max-width: 820px;
  margin: 6px auto 0;
}
.resource-page .resource-lede {
  margin: 12px auto 0;
}
.resource-browser {
  display: grid;
  gap: 12px;
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  animation: resource-rise 480ms 80ms ease-out both;
}
.resource-filter,
.download-toolbar {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  align-items: center;
  gap: 10px;
  padding: 14px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.04);
}
.resource-filter select {
  min-width: 180px;
}
.resource-filter button,
.download-toolbar button {
  padding: 8px 12px;
  background: #2563eb;
  color: #fff;
  font-weight: 800;
}
.download-toolbar label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 9px;
  border-radius: 999px;
  background: #eff6ff;
  color: #1e3a8a;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  transition: background-color 160ms ease, color 160ms ease, transform 160ms ease;
}
.download-toolbar label:hover {
  background: #dbeafe;
  transform: translateY(-1px);
}
.download-toolbar label:has(input:checked) {
  background: #dbeafe;
  color: #1d4ed8;
}
.download-toolbar input {
  width: 15px;
  height: 15px;
  accent-color: #2563eb;
}
.download-toolbar #downloadSelectedFilesBtn {
  background: #047857;
}
.download-toolbar #downloadSelectedFilesBtn:disabled {
  background: #cbd5e1;
}
.resource-message {
  min-height: 20px;
  margin: 0;
  color: #64748b;
  font-size: 13px;
  text-align: left;
}
.resource-message.is-error {
  color: #b91c1c;
}
.paper-download-list {
  display: grid;
  gap: 10px;
}
.paper-download-card {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(0, 2fr);
  gap: 12px;
  align-items: center;
  padding: 14px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.035);
  animation: resource-row-in 320ms ease-out both;
  animation-delay: calc(var(--row-index, 0) * 35ms);
  transition: border-color 170ms ease, box-shadow 170ms ease, transform 170ms ease;
}
.paper-download-card:hover {
  border-color: #bfdbfe;
  box-shadow: 0 9px 24px rgba(37, 99, 235, 0.08);
  transform: translateY(-1px);
}
.paper-download-card strong,
.paper-download-card span {
  display: block;
}
.paper-download-card span {
  margin-top: 4px;
  color: #64748b;
  font-size: 13px;
}
.paper-file-options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.paper-file-options label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 9px;
  border-radius: 6px;
  background: #f8fafc;
  color: #334155;
  font-size: 13px;
  font-weight: 700;
}
.resource-empty {
  padding: 18px;
  border: 1px dashed #cbd5e1;
  border-radius: 8px;
  color: #64748b;
  background: #fff;
}

.zone-page {
  background:
    linear-gradient(180deg, #eef6ff 0%, #ffffff 50%, #f8fbff 100%),
    #f8fafc;
}
.zone-shell {
  min-height: calc(100vh - 64px);
  display: grid;
  grid-template-columns: minmax(320px, 400px) minmax(520px, 1fr);
  gap: 18px;
  padding: 24px clamp(16px, 4vw, 56px) 30px;
}
.zone-panel,
.zone-stage {
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: rgba(255, 255, 255, .92);
  box-shadow: 0 18px 48px rgba(15, 23, 42, .08);
}
.zone-panel {
  min-width: 0;
  max-height: calc(100vh - 112px);
  overflow: auto;
  padding: 20px;
}
.zone-panel h1 {
  margin: 0;
  color: #0f172a;
  font-size: 32px;
  line-height: 1.08;
  letter-spacing: 0;
}
.zone-sub {
  margin: 8px 0 16px;
  color: #475569;
  font-size: 13px;
  line-height: 1.6;
}
.zone-callout {
  margin: 0 0 14px;
  padding: 12px;
  border: 1px solid #bfdbfe;
  border-left: 4px solid #2563eb;
  border-radius: 8px;
  background: #eff6ff;
}
.zone-callout strong {
  display: block;
  color: #1e3a8a;
  font-size: 13px;
}
.zone-callout p {
  margin: 5px 0 8px;
  color: #475569;
  font-size: 12px;
  line-height: 1.55;
}
.zone-callout a {
  color: #1d4ed8;
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
}
.langbar {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
}
.zone-lang,
.zone-chip,
.zone-controls button {
  border: 1px solid #d9e2ef;
  border-radius: 8px;
  background: #fff;
  color: #102033;
  font: 800 12px Arial, Helvetica, sans-serif;
  cursor: pointer;
}
.zone-lang {
  flex: 1;
  padding: 8px 10px;
}
.zone-lang.on,
.zone-chip.on,
.zone-controls button.on {
  border-color: #2563eb;
  background: #2563eb;
  color: #fff;
}
.zone-field {
  display: grid;
  gap: 6px;
  margin-bottom: 12px;
  color: #475569;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .04em;
}
.zone-field select,
.zone-field input {
  width: 100%;
  min-height: 36px;
  padding: 7px 9px;
  border: 1px solid #d9e2ef;
  border-radius: 8px;
  background: #fff;
  color: #102033;
  font: 13px Arial, Helvetica, sans-serif;
  letter-spacing: 0;
}
.zone-field select:focus,
.zone-field input:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, .12);
  outline: none;
}
.zone-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.zone-chip {
  padding: 6px 10px;
}
.zone-legend {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid #e2e8f0;
}
.zone-legend h2 {
  margin: 0 0 8px;
  color: #64748b;
  font-size: 11px;
  letter-spacing: .05em;
  text-transform: uppercase;
}
.zone-legend-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
  color: #334155;
  font-size: 12px;
}
.zone-dot {
  width: 11px;
  height: 11px;
  flex: 0 0 11px;
  border: 1px solid rgba(15, 23, 42, .55);
  border-radius: 999px;
}
.zone-legend p,
.zone-count,
.zone-foot {
  color: #64748b;
  font-size: 11px;
  line-height: 1.55;
}
.zone-info {
  min-height: 92px;
  margin-top: 14px;
  padding: 12px;
  border: 1px solid #d9e2ef;
  border-radius: 8px;
  background: #f8fafc;
  color: #334155;
  font-size: 13px;
  line-height: 1.6;
}
.zone-place {
  color: #0f172a;
  font-size: 16px;
  font-weight: 800;
}
.zone-en,
.zone-empty {
  color: #64748b;
  font-size: 12px;
}
.zone-badge {
  display: inline-flex;
  align-items: center;
  margin: 7px 6px 0 0;
  padding: 2px 8px;
  border-radius: 4px;
  color: #fff;
  font-size: 12px;
  font-weight: 800;
}
.zone-paper-code {
  font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  font-weight: 800;
}
.zone-exam-list {
  display: grid;
  gap: 7px;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid #dbeafe;
}
.zone-exam-title {
  color: #1e3a8a;
  font-size: 12px;
  font-weight: 800;
}
.zone-exam-row {
  display: grid;
  grid-template-columns: minmax(82px, 1fr) minmax(110px, 1.2fr);
  gap: 4px 8px;
  align-items: baseline;
  padding: 7px 8px;
  border: 1px solid #e2e8f0;
  border-radius: 7px;
  background: #fff;
}
.zone-exam-row span {
  color: #0f172a;
  font-size: 12px;
  font-weight: 800;
}
.zone-exam-row strong {
  color: #1d4ed8;
  font-size: 12px;
  font-weight: 800;
}
.zone-exam-row strong a {
  color: inherit;
  text-decoration: none;
}
.zone-exam-row strong a:hover {
  text-decoration: underline;
}
.zone-exam-row em {
  grid-column: 1 / -1;
  color: #64748b;
  font-size: 11px;
  font-style: normal;
}
.zone-exam-empty {
  color: #64748b;
  font-size: 12px;
}
.zone-foot a {
  color: #2563eb;
  font-weight: 800;
  text-decoration: none;
}
.zone-stage {
  position: relative;
  min-width: 0;
  min-height: calc(100vh - 112px);
  overflow: hidden;
  background: linear-gradient(180deg, #ffffff, #f8fbff);
}
.zone-stage canvas {
  display: block;
  width: 100%;
  height: 100%;
  cursor: grab;
}
.zone-stage canvas.grabbing {
  cursor: grabbing;
}
.zone-tip {
  position: absolute;
  z-index: 5;
  display: none;
  max-width: 260px;
  padding: 8px 11px;
  border-radius: 8px;
  background: #0f172a;
  color: #fff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, .26);
  font-size: 12px;
  line-height: 1.55;
  pointer-events: none;
}
.zone-sunbox {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 4;
  max-width: min(330px, calc(100% - 28px));
  padding: 8px 11px;
  border: 1px solid rgba(147, 197, 253, .35);
  border-radius: 8px;
  background: rgba(15, 23, 42, .88);
  color: #fff;
  font-size: 11px;
  line-height: 1.55;
}
.zone-sunbox b {
  color: #f59e0b;
}
.zone-controls {
  position: absolute;
  right: 14px;
  bottom: 14px;
  display: flex;
  gap: 8px;
}
.zone-controls button {
  padding: 8px 12px;
}

@media (max-width: 900px) {
  .zone-shell {
    grid-template-columns: 1fr;
  }
  .zone-panel {
    max-height: none;
  }
  .zone-stage {
    min-height: 62vh;
  }
}

@keyframes resource-rise {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes resource-row-in {
  from {
    opacity: 0;
    transform: translateY(7px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 700px) {
  .resource-guide {
    grid-template-columns: 1fr;
  }
  .resource-filter select,
  .resource-filter button {
    width: 100%;
  }
  .download-toolbar {
    justify-content: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  .resource-page .section-head,
  .resource-browser,
  .paper-download-card {
    animation: none;
  }
  .resource-guide article,
  .download-toolbar label,
  .paper-download-card {
    transition: none;
  }
}

.auth-panel {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: start center;
  padding-top: 86px;
  background: rgba(15, 23, 42, .42);
}
.auth-panel[hidden] { display: none; }
.auth-card {
  width: min(420px, calc(100vw - 28px));
  display: grid;
  gap: 12px;
  padding: 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 20px 60px rgba(15, 23, 42, .22);
}
.auth-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.auth-card__head button {
  width: 32px;
  height: 32px;
  padding: 0;
  background: #e5e7eb;
  color: var(--text);
  font-size: 20px;
  line-height: 1;
}
.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.auth-tabs button {
  background: #e5e7eb;
  color: var(--text);
  font-weight: 700;
}
.auth-tabs button.is-on {
  background: var(--accent);
  color: #fff;
}
.auth-card label {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}
.auth-card input {
  width: 100%;
  color: var(--text);
}
.auth-card > button[type="submit"] {
  font-weight: 700;
}
.auth-message {
  min-height: 18px;
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}
.auth-message.is-error { color: #b91c1c; }

.progress-panel {
  position: fixed;
  inset: 0;
  z-index: 45;
  display: flex;
  justify-content: flex-end;
  background: rgba(30, 64, 175, .18);
}
.progress-panel[hidden] { display: none; }
.progress-card {
  width: min(560px, 100vw);
  height: 100vh;
  display: flex;
  flex-direction: column;
  background: #fff;
  border-left: 1px solid var(--line);
  box-shadow: -18px 0 48px rgba(37, 99, 235, .14);
}
.progress-head {
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
}
.progress-head strong { display: block; }
.progress-head button {
  width: 32px;
  height: 32px;
  padding: 0;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 20px;
  line-height: 1;
}
.progress-message {
  min-height: 28px;
  padding: 8px 16px 0;
  color: var(--muted);
  font-size: 12px;
}
.progress-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  padding: 10px 16px;
}
.progress-metrics div {
  min-width: 0;
  padding: 10px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #f8fbff;
}
.progress-metrics span {
  display: block;
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 11px;
}
.progress-metrics strong {
  font-size: 20px;
}
.progress-tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  padding: 0 16px 12px;
  border-bottom: 1px solid var(--line);
}
.progress-tabs button {
  background: #eef6ff;
  color: #1d4ed8;
  font-weight: 700;
}
.progress-tabs button.is-on {
  background: #2563eb;
  color: #fff;
}
.progress-list {
  flex: 1;
  overflow: auto;
}
.progress-item {
  display: block;
  width: 100%;
  padding: 11px 16px;
  text-align: left;
  background: #fff;
  color: var(--text);
  border: 0;
  border-bottom: 1px solid #eef2f7;
  border-radius: 0;
}
.progress-item:hover { background: #f1f5f9; }
.progress-item:focus-visible {
  outline: 2px solid #93c5fd;
  outline-offset: -2px;
}
.progress-item strong { display: block; font-size: 14px; }
.progress-item span,
.progress-item small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}
.progress-empty {
  padding: 18px 16px;
  color: var(--muted);
  font-size: 13px;
}

.report-panel {
  position: fixed;
  inset: 0;
  z-index: 55;
  display: grid;
  place-items: start center;
  padding-top: 90px;
  background: rgba(15, 23, 42, .42);
}
.report-panel[hidden] { display: none; }
.report-card {
  width: min(520px, calc(100vw - 28px));
  display: grid;
  gap: 12px;
  padding: 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 20px 60px rgba(15, 23, 42, .22);
}
.report-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.report-head button {
  width: 32px;
  height: 32px;
  padding: 0;
  background: #e5e7eb;
  color: var(--text);
  font-size: 20px;
  line-height: 1;
}
.report-card label {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}
.report-card textarea {
  min-height: 110px;
  resize: vertical;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  padding: 8px 9px;
  font: inherit;
  color: var(--text);
}
.report-card select {
  color: var(--text);
}
.report-card > button[type="submit"] {
  font-weight: 700;
}
.report-message {
  min-height: 18px;
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}
.report-message.is-error { color: #b91c1c; }

.app-layout {
  height: calc(100vh - 56px);
  display: grid;
  grid-template-columns: minmax(320px, 380px) minmax(0, 1fr);
  gap: 12px;
  padding: 12px;
  transition: grid-template-columns .18s ease;
}

.login-risk-banner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 8px 14px;
  border-bottom: 1px solid #fed7aa;
  background: #fff7ed;
  color: #9a3412;
  font-size: 13px;
}
.login-risk-banner[hidden] {
  display: none;
}
.login-risk-banner strong {
  color: #7c2d12;
}
.login-risk-banner button {
  padding: 5px 9px;
  background: #ea580c;
  color: #fff;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 800;
}
body.filters-collapsed .app-layout {
  grid-template-columns: minmax(0, 1fr);
}

.search-pane,
.practice-pane {
  min-width: 0;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}

.search-pane {
  display: flex;
  flex-direction: column;
}
body.filters-collapsed .search-pane {
  display: none;
}

.pane-head,
.answer-panel-head {
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 12px;
  border-bottom: 1px solid var(--line);
  background: #f8fafc;
}
.pane-head strong,
.answer-panel-head strong {
  color: #0f172a;
  font-size: 13px;
}
.pane-toggle,
.floating-toggle {
  padding: 7px 9px;
  background: #e5e7eb;
  color: var(--text);
  border-radius: 6px;
  font-size: 12px;
  font-weight: 800;
}
.floating-toggle {
  display: none;
  flex: 0 0 auto;
  background: #dbeafe;
  color: #1d4ed8;
}
body.filters-collapsed .filter-open {
  display: inline-flex;
  align-items: center;
}

.search-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  padding: 10px;
  border-bottom: 1px solid var(--line);
}

select, input, button {
  min-width: 0;
  padding: 8px 9px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  font: inherit;
}

.search-form input,
.search-form button { grid-column: 1 / -1; }
.search-form select,
.search-form input,
.search-form button {
  padding: 7px 8px;
  font-size: 13px;
}
.search-check {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 7px;
  color: #475569;
  font-size: 12px;
  font-weight: 750;
}
.search-check input {
  width: 14px;
  height: 14px;
  padding: 0;
  accent-color: #2563eb;
}
button {
  background: var(--brand);
  color: #fff;
  border: 0;
  cursor: pointer;
}
button:disabled { opacity: .5; cursor: not-allowed; }

.result-meta {
  padding: 9px 12px;
  color: var(--muted);
  font-size: 13px;
  border-bottom: 1px solid var(--line);
}

.queue-bar {
  display: grid;
  grid-template-columns: 1fr;
  gap: 7px;
  padding: 9px 12px;
  border-bottom: 1px solid var(--line);
  background: #f8fafc;
}
.queue-bar label {
  display: flex;
  align-items: center;
  gap: 7px;
  color: #475569;
  font-size: 12px;
  font-weight: 700;
}
.queue-bar input {
  width: 15px;
  height: 15px;
}
.queue-bar button {
  padding: 7px 8px;
  background: #eef2ff;
  color: #1d4ed8;
  font-size: 12px;
  font-weight: 800;
}
.queue-bar #addSelectedToQueueBtn {
  background: #2563eb;
  color: #fff;
}
.queue-bar #clearQueueBtn {
  background: #f1f5f9;
  color: #64748b;
}

.result-list {
  overflow: auto;
  flex: 1;
}

.result-row {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  align-items: stretch;
  border-bottom: 1px solid #eef2f7;
  background: #fff;
}
.result-row.is-grouped {
  background: #fbfdff;
}
.result-row.is-queued {
  background: #f8fbff;
}
.result-select {
  justify-self: center;
  align-self: start;
  width: 16px;
  height: 16px;
  margin-top: 13px;
  accent-color: #2563eb;
}

.result-item {
  display: block;
  width: 100%;
  text-align: left;
  padding: 9px 10px;
  background: transparent;
  color: var(--text);
  border: 0;
  border-radius: 0;
}
.result-item:hover,
.result-item.is-active { background: #f1f5f9; }
.result-item strong { display: block; font-size: 13px; }
.result-item em {
  display: inline-block;
  margin-left: 5px;
  color: #b45309;
  font-style: normal;
  font-size: 11px;
}
.muted, .result-item span { color: var(--muted); font-size: 11px; }
.result-item small {
  display: block;
  margin-top: 4px;
  color: #475569;
  font-size: 11px;
  line-height: 1.35;
}

.pager {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding: 10px 12px;
  border-top: 1px solid var(--line);
  background: #f8fafc;
}
.pager button {
  padding: 7px 8px;
  background: #eef2f7;
  color: #475569;
  font-size: 12px;
  font-weight: 700;
}

.practice-pane {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 330px);
  grid-template-rows: auto minmax(0, 1fr);
  transition: grid-template-columns .18s ease;
}
body.tools-collapsed .practice-pane {
  grid-template-columns: minmax(0, 1fr);
}

.question-toolbar {
  min-height: 72px;
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
  padding: 9px 12px;
  border-bottom: 1px solid var(--line);
  grid-column: 1 / -1;
  background: linear-gradient(180deg, #fff, #fbfdff);
}
.back-to-questions {
  display: none;
  flex: 0 0 auto;
  padding: 7px 9px;
  background: #e5e7eb;
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
}
.question-heading {
  min-width: 220px;
  flex: 1 1 420px;
}
.question-heading strong {
  display: block;
  font-size: 15px;
  line-height: 1.25;
  margin-top: 2px;
}
#questionMeta {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 6px;
}
.question-chip {
  display: inline-flex;
  align-items: center;
  min-height: 23px;
  max-width: 100%;
  padding: 3px 7px;
  border: 1px solid #dbeafe;
  border-radius: 999px;
  background: #eff6ff;
  color: #1e3a8a;
  font-size: 11px;
  line-height: 1.25;
  font-weight: 700;
}
.question-chip b {
  margin-right: 5px;
  color: #64748b;
  font-weight: 800;
}
.knowledge-chip {
  border-color: #bbf7d0;
  background: #ecfdf5;
  color: #047857;
  font-weight: 700;
}
.question-nav {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
}
.question-nav button {
  padding: 6px 9px;
  background: #edf5ff;
  color: var(--text);
  border-radius: 6px;
  font-size: 12px;
  font-weight: 800;
}
.question-nav #prevQuestionBtn,
.question-nav #nextQuestionBtn {
  background: #eff6ff;
  color: #1d4ed8;
}
.question-nav #starBtn {
  background: #fff7ed;
  color: #334155;
}
.question-nav #starBtn.is-on {
  background: #f59e0b;
  color: #111827;
}

.question-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  flex-wrap: wrap;
}
.question-actions button {
  padding: 6px 8px;
  color: #1e3a8a;
  background: #eff6ff;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
}
.question-actions button.is-on {
  background: var(--accent);
  color: #fff;
}
.question-actions .mark-scheme-button {
  background: #2563eb;
  color: #fff;
  box-shadow: 0 8px 18px rgba(37, 99, 235, .16);
}
.question-actions .mark-scheme-button:hover:not(:disabled) {
  background: #1d4ed8;
}
#answerPanelToggleBtn {
  background: #ecfdf5;
  color: #047857;
}
body.tools-collapsed #answerPanelToggleBtn {
  background: #eff6ff;
  color: #1d4ed8;
}
.resource-menu {
  position: relative;
}
.resource-menu summary {
  list-style: none;
  padding: 6px 8px;
  color: #047857;
  background: #ecfdf5;
  border-radius: 6px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
}
.resource-menu summary::-webkit-details-marker {
  display: none;
}
.resource-links a {
  display: block;
  padding: 7px 9px;
  color: #334155;
  background: #fff;
  border-radius: 6px;
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}
.resource-menu[open] .resource-links {
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  z-index: 20;
  display: grid;
  gap: 6px;
  min-width: 180px;
  padding: 8px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 12px 30px rgba(15, 23, 42, .14);
}

.question-main {
  min-width: 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: auto;
  grid-column: 1;
  grid-row: 2;
  gap: 14px;
  padding: 14px 0 16px;
  background:
    linear-gradient(180deg, rgba(239, 246, 255, .44), rgba(248, 250, 252, 0) 190px),
    #f8fafc;
}
.question-main.has-ms {
  display: grid;
  grid-template-rows: minmax(300px, 1.08fr) minmax(220px, .92fr);
  overflow: hidden;
}

iframe {
  border: 0;
  width: min(1180px, calc(100% - 36px));
  margin: 0 auto;
  flex: 1 0 58vh;
  min-height: 360px;
  border: 1px solid #dbeafe;
  border-radius: 12px;
  background: #f8fafc;
  box-shadow: 0 12px 34px rgba(15, 23, 42, .06);
}
.question-main.has-ms iframe {
  min-height: 0;
  height: 100%;
}

.answer-panel {
  min-width: 0;
  border-top: 0;
  border-left: 1px solid var(--line);
  padding: 10px 12px;
  max-height: none;
  overflow: auto;
  grid-column: 2;
  grid-row: 2;
  background: #f8fbff;
}
body.tools-collapsed .answer-panel {
  display: none;
}
.answer-panel-head {
  margin: -10px -12px 10px;
}
.study-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 7px;
  margin-bottom: 10px;
}
.study-actions button {
  padding: 7px 9px;
  background: #eef6ff;
  color: #1d4ed8;
  font-size: 13px;
  font-weight: 700;
}
.study-actions button.is-on {
  background: var(--accent);
  color: #fff;
}
.study-actions #wrongBtn.is-on {
  background: #b91c1c;
}
.study-actions #masteredBtn.is-on {
  background: #047857;
}
.study-actions #submitAttemptBtn {
  background: #2563eb;
  color: #fff;
}
.study-actions #reportProblemBtn {
  background: #fff7ed;
  color: #9a3412;
}
.work-status {
  margin: -2px 0 10px;
  color: var(--muted);
  font-size: 12px;
}
.note-box {
  display: grid;
  gap: 5px;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}
.note-box textarea {
  width: 100%;
  resize: vertical;
  min-height: 46px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  padding: 8px 9px;
  font: inherit;
  color: var(--text);
}

.mark-scheme-dock {
  width: min(980px, calc(100% - 36px));
  margin: 0 auto 22px;
  overflow: auto;
}
.mark-scheme-dock:empty {
  display: none;
}
.question-main.has-ms .mark-scheme-dock {
  width: min(980px, calc(100% - 36px));
  height: 100%;
  margin-bottom: 0;
}
.ms-panel {
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  padding: 12px;
  background: #f8fbff;
  box-shadow: 0 12px 30px rgba(15, 23, 42, .08);
  color: #1f2937;
  font-size: 13px;
  line-height: 1.48;
}
.ms-panel h2 {
  margin: 0 0 7px;
  color: #0f172a;
  font-size: 15px;
}
.ms-group {
  display: grid;
  gap: 12px;
}
.ms-group > h2 {
  margin: 0;
  color: #0f172a;
  font-size: 15px;
}
.ms-group-part {
  display: grid;
  gap: 8px;
}
.ms-group-part > h3 {
  margin: 0;
  color: #334155;
  font-size: 13px;
}
.ms-group-part .ms-panel {
  box-shadow: none;
}
.ms-source {
  color: var(--muted);
  font-size: 11px;
  margin-bottom: 9px;
}
.ms-panel img {
  display: block;
  max-width: min(100%, 760px);
  max-height: 52vh;
  height: auto;
  margin: 8px auto;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  object-fit: contain;
}
.ms-panel-text {
  display: grid;
  gap: 12px;
}
.ms-text-section {
  display: grid;
  gap: 8px;
}
.ms-text-section h3 {
  margin: 0;
  font-size: 13px;
}
.ms-text-section ul {
  margin: 0;
  padding-left: 20px;
}
.ms-text-section li {
  margin: 4px 0;
}
.ms-code-grid {
  display: grid;
  gap: 10px;
}
.ms-code-card {
  overflow: hidden;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  background: #0f172a;
}
.ms-code-card:not([open]) {
  background: #f8fafc;
}
.ms-code-title {
  padding: 7px 10px;
  border-bottom: 1px solid #334155;
  color: #e2e8f0;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}
.ms-code-card:not([open]) .ms-code-title {
  border-bottom: 0;
  color: var(--text);
}
.ms-code {
  margin: 0;
  overflow-x: auto;
  padding: 10px;
  color: #e5e7eb;
  font: 12px/1.45 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  white-space: pre;
}

@media(max-width: 1180px) {
  .app-layout {
    grid-template-columns: minmax(280px, 330px) minmax(0, 1fr);
  }
  .practice-pane {
    grid-template-columns: minmax(0, 1fr) minmax(250px, 300px);
  }
  .question-toolbar {
    align-items: flex-start;
    flex-wrap: wrap;
  }
  .question-actions {
    flex: 1 1 100%;
  }
}

@media(max-width: 900px) {
  .home-topbar {
    height: auto;
    min-height: 60px;
    align-items: flex-start;
    flex-direction: column;
    padding-top: 14px;
    padding-bottom: 14px;
  }
  .home-nav {
    width: 100%;
    justify-content: space-between;
  }
  .site-nav {
    justify-content: flex-start;
    overflow-x: auto;
  }
  .site-menu {
    position: static;
  }
  .site-menu-panel {
    left: 18px;
    right: 18px;
    min-width: 0;
  }
  .site-account {
    width: 100%;
    justify-content: space-between;
  }
  .home-hero {
    min-height: auto;
    grid-template-columns: 1fr;
    padding-top: 34px;
  }
  .home-hero h1 {
    font-size: 38px;
  }
  .home-lede {
    font-size: 16px;
  }
  .home-preview {
    max-width: 620px;
  }
  .subject-grid,
  .home-features,
  .notes-grid,
  .iepq-resource-grid,
  .iepq-sample-grid,
  .iepq-project-grid,
  .iepq-stage-grid,
  .iepq-source-grid,
  .iepq-source-summary,
  .iepq-plan-summary,
  .iepq-generator-grid,
  .iepq-plan-task-grid,
  .iepq-insert-grid,
  .iepq-form-row,
  .iepq-lookup-row,
  .login-page-grid,
  .student-dashboard-grid,
  .student-dashboard-section {
    grid-template-columns: 1fr;
  }
  .student-dashboard-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .iepq-plan-phase {
    grid-template-columns: 38px 1fr;
    gap: 10px;
  }
  .iepq-plan-phase::before {
    left: 19px;
  }
  .iepq-plan-phase-marker {
    width: 38px;
    height: 38px;
    font-size: 16px;
  }
  .iepq-plan-task-head {
    align-items: stretch;
    flex-direction: column;
  }
  .iepq-phase-topline,
  .iepq-phase-hours-form {
    grid-template-columns: 1fr;
    align-items: stretch;
  }
  .iepq-phase-hours-form {
    display: grid;
  }
  .iepq-phase-hours-form input {
    width: 100%;
  }
  .iepq-resource-card {
    grid-template-columns: 1fr;
  }
  .iepq-resource-actions {
    justify-content: flex-start;
    min-width: 0;
  }
  .iepq-resource-link.subtle {
    text-align: left;
  }
  .note-article {
    gap: 12px;
  }
  .subject-hub-grid {
    grid-template-columns: 1fr;
  }
  .paper-download-card {
    grid-template-columns: 1fr;
  }
  .login-risk-banner {
    align-items: flex-start;
    flex-direction: column;
  }
  .home-features {
    padding-top: 0;
  }
  .app-layout {
    height: auto;
    grid-template-columns: 1fr;
  }
  body.filters-collapsed .app-layout {
    grid-template-columns: 1fr;
  }
  .search-pane {
    min-height: 50vh;
  }
  .practice-pane {
    height: auto;
    min-height: 75vh;
    grid-template-columns: 1fr;
    grid-template-rows: auto minmax(420px, 1fr) auto;
  }
  .question-toolbar {
    align-items: flex-start;
    flex-wrap: wrap;
  }
  .question-heading {
    flex-basis: 100%;
    order: 2;
  }
  .question-nav {
    order: 3;
  }
  .question-actions {
    order: 4;
    justify-content: flex-start;
  }
  .question-main {
    grid-column: 1;
    grid-row: 2;
  }
  iframe {
    flex-basis: 420px;
    min-height: 420px;
  }
  .mark-scheme-dock {
    width: min(760px, calc(100% - 24px));
    margin-bottom: 16px;
  }
  .answer-panel {
    grid-column: 1;
    grid-row: 3;
    border-left: 0;
    border-top: 1px solid var(--line);
    max-height: 34vh;
  }
  .study-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .progress-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  body.mobile-practice-mode {
    overflow: hidden;
  }
  body.mobile-practice-mode .app-layout {
    display: block;
    padding: 0;
  }
  body.mobile-practice-mode .search-pane {
    display: none;
  }
  body.mobile-practice-mode .practice-pane {
    display: grid;
    height: calc(100dvh - 56px);
    min-height: 0;
    grid-template-rows: auto minmax(0, 1fr) auto;
    border: 0;
    border-radius: 0;
  }
  body.mobile-practice-mode iframe {
    flex-basis: auto;
    min-height: 0;
  }
  body.mobile-practice-mode .question-main {
    min-height: 0;
  }
  body.mobile-practice-mode .answer-panel {
    max-height: 32vh;
  }
  body.mobile-practice-mode .back-to-questions {
    display: inline-flex;
    align-items: center;
    gap: 6px;
  }
}

@media(max-width: 560px) {
  .home-brand {
    font-size: 17px;
  }
  .home-nav {
    gap: 10px;
  }
  .home-hero {
    padding-left: 16px;
    padding-right: 16px;
  }
  .home-hero h1 {
    font-size: 32px;
    line-height: 1.08;
  }
  .home-actions {
    display: grid;
  }
  .home-button {
    width: 100%;
  }
  .home-preview__body {
    grid-template-columns: 112px 1fr;
    min-height: 280px;
  }
  .home-preview aside,
  .home-preview section {
    padding: 12px;
  }
  .home-preview__answer {
    height: 86px;
  }
  .subject-section,
  .home-features,
  .notes-shell,
  .note-shell {
    padding-left: 16px;
    padding-right: 16px;
  }
  .note-body {
    font-size: 15px;
  }
  .note-body h2 {
    font-size: 19px;
  }
  .note-detail-hero,
  .note-body-card,
  .note-linked {
    box-shadow: 0 8px 24px rgba(37, 99, 235, .07);
  }
  .topbar {
    height: auto;
    min-height: 56px;
    flex-wrap: wrap;
    gap: 8px;
    padding: 10px 12px;
  }
  .topbar nav {
    width: 100%;
    justify-content: flex-start;
    overflow-x: auto;
  }
  .app-layout {
    padding: 8px;
  }
  .question-toolbar {
    gap: 8px;
    padding: 9px;
  }
  .question-nav,
  .question-actions {
    width: 100%;
  }
  .question-nav {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .question-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .question-actions .mark-scheme-button {
    grid-column: 1 / -1;
  }
  .resource-menu {
    grid-column: 1 / -1;
  }
  .resource-menu summary {
    text-align: center;
  }
  .resource-menu[open] .resource-links {
    left: 0;
    right: auto;
    width: min(100%, 260px);
  }
  .mark-scheme-dock {
    width: calc(100% - 16px);
  }
  .ms-panel {
    padding: 12px;
  }
  .study-actions {
    grid-template-columns: 1fr;
  }
  body.mobile-practice-mode .practice-pane {
    height: calc(100dvh - 76px);
  }
}

@keyframes iepq-expand-in {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.iepq-outline-context {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 18px;
  margin: 18px 0;
  align-items: stretch;
}
.iepq-outline-context > div,
.iepq-outline-context > aside,
.iepq-outline-builder,
.iepq-outline-guidance,
.iepq-outline-sample-row {
  border: 1px solid #dbeafe;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(37, 99, 235, .06);
}
.iepq-outline-context > div,
.iepq-outline-context > aside {
  padding: 18px;
}
.iepq-outline-context h2,
.iepq-outline-guidance h2 {
  margin: 0 0 10px;
  color: #0f172a;
}
.iepq-outline-context p,
.iepq-outline-context span,
.iepq-outline-guidance li {
  color: #475569;
  font-weight: 700;
  line-height: 1.55;
}
.iepq-outline-context aside {
  display: grid;
  align-content: center;
  gap: 8px;
  border-left: 4px solid #2563eb;
}
.iepq-outline-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 18px;
  align-items: start;
}
.iepq-outline-builder {
  padding: 18px;
}
.iepq-outline-toolbar,
.iepq-outline-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.iepq-outline-toolbar h2 {
  margin: 0;
}
.iepq-outline-section {
  display: grid;
  gap: 13px;
  margin-top: 14px;
  padding: 16px;
  border: 1px solid #e2e8f0;
  border-left: 4px solid #60a5fa;
  border-radius: 14px;
  background: #f8fbff;
}
.iepq-outline-section-head strong {
  color: #1d4ed8;
}
.iepq-outline-section label,
.iepq-outline-builder label {
  display: grid;
  gap: 6px;
  color: #334155;
  font-size: 13px;
  font-weight: 900;
}
.iepq-outline-section input,
.iepq-outline-section textarea,
.iepq-outline-section select {
  width: 100%;
  padding: 10px 11px;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  background: #fff;
  color: #0f172a;
  font: 650 14px/1.45 Arial, Helvetica, sans-serif;
}
.iepq-outline-section textarea {
  resize: vertical;
}
.iepq-outline-grid-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.iepq-outline-grid-fields.compact {
  grid-template-columns: minmax(0, .7fr) minmax(0, .5fr);
}
.iepq-outline-guidance {
  position: sticky;
  top: 86px;
  display: grid;
  gap: 16px;
  padding: 18px;
}
.iepq-outline-guidance ul {
  margin: 0;
  padding-left: 18px;
}
.iepq-outline-generator {
  display: grid;
  gap: 16px;
  border-color: #bfdbfe;
  background: linear-gradient(180deg, #fff, #f8fbff);
}
.iepq-outline-status-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}
.iepq-outline-status-grid article {
  display: grid;
  gap: 6px;
  padding: 12px;
  border: 1px solid #dbeafe;
  border-radius: 12px;
  background: #fff;
}
.iepq-outline-status-grid span {
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}
.iepq-outline-status-grid strong {
  color: #0f172a;
  font-size: 14px;
  line-height: 1.35;
}
.iepq-outline-sample {
  display: grid;
  gap: 14px;
}
.iepq-outline-sample-row {
  padding: 16px;
}
.iepq-outline-sample-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.iepq-outline-sample-row h3 {
  margin: 0 0 8px;
  color: #1d4ed8;
}
.iepq-outline-sample-row p {
  margin: 7px 0 0;
  color: #334155;
  line-height: 1.55;
}
.iepq-outline-sample-subsections {
  display: grid;
  gap: 10px;
  margin-top: 10px;
}
.iepq-outline-sample-subsection {
  padding: 11px 13px;
  border: 1px solid #bfdbfe;
  border-left: 4px solid #2563eb;
  border-radius: 12px;
  background: #f8fbff;
}
.iepq-outline-sample-subsection h4 {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin: 0 0 8px;
  color: #0f172a;
  font-size: 16px;
  line-height: 1.35;
}
.iepq-outline-sample-subsection strong {
  display: block;
  margin-bottom: 5px;
  color: #1d4ed8;
  font-size: 14px;
  font-weight: 900;
  line-height: 1.3;
}
.iepq-outline-sample-subsection p {
  margin: 0;
  color: #334155;
  font-size: 14px;
  line-height: 1.62;
}
.iepq-outline-purpose {
  color: #64748b;
  font-size: 14px;
}
.iepq-outline-decision {
  margin-top: 10px;
  padding: 10px 12px;
  border-left: 4px solid #93c5fd;
  border-radius: 10px;
  background: #eff6ff;
}
.iepq-outline-decision p {
  color: #1e3a8a;
  font-size: 13px;
}
.iepq-outline-lang-toggle {
  display: inline-flex;
  gap: 6px;
  padding: 5px;
  margin-top: 18px;
  border: 1px solid rgba(255, 255, 255, .3);
  border-radius: 999px;
  background: rgba(255, 255, 255, .16);
}
.iepq-outline-lang-toggle button {
  border: 0;
  border-radius: 999px;
  padding: 8px 13px;
  background: transparent;
  color: rgba(255, 255, 255, .86);
  font-weight: 800;
  cursor: pointer;
}
.iepq-outline-lang-toggle button.is-active {
  background: #fff;
  color: #2563eb;
}
.iepq-outline-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin: 10px 0;
}
.iepq-outline-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 9px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 12px;
  font-weight: 850;
  line-height: 1.2;
  white-space: nowrap;
}
.iepq-outline-badge.planned {
  color: #2563eb;
  background: #eff6ff;
  border-color: #bfdbfe;
}
.iepq-outline-badge.confirmed {
  color: #0f766e;
  background: #ecfdf5;
  border-color: #99f6e4;
}
.iepq-outline-badge.tentative {
  color: #b45309;
  background: #fffbeb;
  border-color: #fde68a;
}
.iepq-outline-badge.verify {
  color: #7c3aed;
  background: #f5f3ff;
  border-color: #ddd6fe;
}
.iepq-outline-badge.optional {
  color: #475569;
  background: #f1f5f9;
  border-color: #cbd5e1;
}
.iepq-outline-badge.risk {
  color: #b91c1c;
  background: #fef2f2;
  border-color: #fecaca;
}
@media (max-width: 900px) {
  .iepq-outline-context,
  .iepq-outline-layout,
  .iepq-outline-status-grid,
  .iepq-outline-grid-fields,
  .iepq-outline-grid-fields.compact {
    grid-template-columns: 1fr;
  }
  .iepq-outline-guidance {
    position: static;
  }
}
