/*
  DFT component library seed.

  These classes are intentionally higher-level than Tailwind utilities: they are reusable
  product components and layout primitives extracted from the transcript review redesign.
  Legacy transcript/topbar selectors are included as aliases so pages can migrate gradually.
*/

:root {
  --dft-c-surface: #ffffff;
  --dft-c-surface-subtle: #fbfdff;
  --dft-c-bg: #f7f9fc;
  --dft-c-border: #e7ebf3;
  --dft-c-border-soft: #edf1f7;
  --dft-c-border-control: #e2e8f2;
  --dft-c-text: #263245;
  --dft-c-text-strong: #1d2738;
  --dft-c-text-muted: #74809a;
  --dft-c-control-text: #506079;
  --dft-c-accent: #2f70ff;
  --dft-c-accent-line: #4a86ff;
  --dft-c-flow-current: #f4ad10;
  --dft-c-success: #168a57;
  --dft-c-danger: #c24133;
  --dft-c-warning: #f4ad10;
  --dft-c-radius-panel: 8px;
  --dft-c-radius-control: 6px;
  --dft-c-shadow-hairline: 0 1px 2px rgba(15, 23, 42, 0.02);
  --dft-c-font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  --dft-c-review-panel-height: max(520px, calc(100dvh - 248px));
}

:where(.dft-c-page-flow, .dft-transcript-flow-shell) {
  display: grid;
  gap: 16px;
}

:where(.dft-c-page-header, .dft-transcript-flow-shell .mock-toets-header) {
  align-items: start;
  padding: 0;
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

:where(.dft-c-page-header__title, .dft-transcript-flow-shell .mock-toets-header__title) {
  width: 100%;
  max-width: 100%;
}

:where(.dft-c-page-title, .dft-transcript-flow-shell h1) {
  font-size: 22px;
  line-height: 1.12;
  font-weight: 800;
  letter-spacing: 0;
  white-space: normal;
  max-width: 100%;
}

:where(.dft-c-page-subtitle, .dft-transcript-flow-shell .mock-muted) {
  margin-top: 5px;
  font-size: 12px;
  color: var(--dft-c-text-muted);
  white-space: normal;
  overflow-wrap: anywhere;
}

:where(.dft-c-context-card, .dft-test-context-card) {
  min-height: 43px;
  border: 1px solid var(--dft-c-border);
  border-radius: var(--dft-c-radius-panel);
  background: var(--dft-c-surface);
  box-shadow: var(--dft-c-shadow-hairline);
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 14px;
}

:where(.dft-c-context-card__icon, .dft-test-context-card__icon) {
  width: 26px;
  height: 26px;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--dft-c-accent);
  background: #edf4ff;
  border: 1px solid #d8e6ff;
}

:where(.dft-c-context-card__copy, .dft-test-context-card__copy) {
  display: grid;
  gap: 2px;
  min-width: 0;
}

:where(.dft-c-context-card__label, .dft-test-context-card__label) {
  color: var(--dft-c-text-muted);
  font-size: 10px;
  font-weight: 780;
  line-height: 1;
}

:where(.dft-c-context-card__title, .dft-test-context-card__title) {
  color: var(--dft-c-text-strong);
  text-decoration: none;
  font-size: 12px;
  font-weight: 780;
  line-height: 1.15;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

:where(.dft-c-integrated-progress, .mock-transcription-progress) {
  --phase-v1: #7aa7ff;
  --phase-v2: #2f70ff;
  --phase-students: #18a66b;
  --phase-answers: #e6a318;
  display: grid;
  gap: 3px;
  min-height: 0;
  margin: 6px 0 0;
  padding: 5px 8px 4px;
  border: 1px solid var(--dft-c-border);
  border-radius: var(--dft-c-radius-panel);
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--dft-c-shadow-hairline);
}

:where(.dft-c-integrated-progress__meta, .mock-transcription-progress__meta) {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 11px;
}

:where(.dft-c-integrated-progress__title, .mock-transcription-progress__title) {
  color: var(--dft-c-text-muted);
  font-size: 9px;
  font-weight: 790;
  line-height: 1;
  text-transform: uppercase;
}

:where(.dft-c-integrated-progress__pct, .mock-transcription-progress__pct) {
  color: var(--dft-c-text-strong);
  font-size: 10px;
  font-weight: 840;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

:where(.dft-c-phase-progress, .mock-transcription-progress__phasebar) {
  display: flex;
  align-items: start;
  gap: 3px;
  min-width: 0;
}

:where(.dft-c-phase-progress__phase, .mock-transcription-progress__phase) {
  flex: max(1, var(--phase-weight)) 1 0;
  min-width: 42px;
  display: grid;
  grid-template-rows: 5px 4px 10px;
  gap: 1px;
  color: var(--dft-c-text-muted);
  overflow: hidden;
}

:where(.dft-c-phase-progress__track, .mock-transcription-progress__track) {
  height: 5px;
  border-radius: 999px;
  background: #eef3f9;
  border: 1px solid #e0e7f1;
  overflow: hidden;
}

:where(.dft-c-phase-progress__fill, .mock-transcription-progress__fill) {
  display: block;
  width: var(--phase-fill);
  height: 100%;
  border-radius: inherit;
  background: var(--phase-color, var(--dft-c-accent));
  transition: width 420ms ease;
}

:where(.dft-c-phase-progress__bracket, .mock-transcription-progress__bracket) {
  height: 4px;
  margin: 0 2px;
  border-right: 1px solid #d7e0ec;
  border-bottom: 1px solid #d7e0ec;
  border-left: 1px solid #d7e0ec;
  border-radius: 0 0 4px 4px;
}

:where(.dft-c-phase-progress__label, .mock-transcription-progress__phaseLabel) {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  min-width: 0;
  font-size: 8.5px;
  font-weight: 760;
  line-height: 1;
  white-space: nowrap;
}

:where(.dft-c-phase-progress__label span, .mock-transcription-progress__phaseLabel span) {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

:where(.dft-c-phase-progress__label strong, .mock-transcription-progress__phaseLabel strong) {
  flex: 0 0 auto;
  color: var(--dft-c-text-strong);
  font-weight: 820;
  font-variant-numeric: tabular-nums;
}

:where(.dft-c-phase-progress__phase--v1, .mock-transcription-progress__phase--v1) {
  --phase-color: var(--phase-v1);
}

:where(.dft-c-phase-progress__phase--v2, .mock-transcription-progress__phase--v2) {
  --phase-color: var(--phase-v2);
}

:where(.dft-c-phase-progress__phase--students, .mock-transcription-progress__phase--students) {
  --phase-color: var(--phase-students);
}

:where(.dft-c-phase-progress__phase--answers, .mock-transcription-progress__phase--answers) {
  --phase-color: var(--phase-answers);
}

:where(.dft-c-phase-progress__phase.is-idle, .mock-transcription-progress__phase.is-idle) {
  opacity: 0.72;
}

:where(.dft-c-phase-progress__phase.is-todo, .mock-transcription-progress__phase.is-todo) {
  opacity: 0.82;
}

:where(.dft-c-phase-progress__phase.is-running .dft-c-phase-progress__track, .mock-transcription-progress__phase.is-running .mock-transcription-progress__track) {
  box-shadow: 0 0 0 2px rgba(47, 112, 255, 0.08);
}

:where(.dft-c-integrated-progress__legend, .mock-transcription-progress__legend) {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  color: var(--dft-c-text-muted);
  font-size: 8.5px;
  font-weight: 700;
  line-height: 1.1;
}

:where(.mock-transcription-progress__sep) {
  color: #a5afbf;
  font-weight: 900;
}

:where(.mock-transcription-progress__legacybar) {
  display: none;
}

:where(.dft-c-flow-tabs, .mock-flowtabs) {
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  display: flex;
  align-items: stretch;
  justify-content: center;
  gap: clamp(15px, 2.55vw, 36px);
  flex-wrap: nowrap;
  position: relative;
  min-width: 0;
}

:where(.dft-c-flow-tabs__tab, .mock-flowtabs__tab) {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 56px;
  padding: 0 0 2px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #68758d;
  font-size: 11px;
  font-weight: 720;
  line-height: 1;
  text-decoration: none;
  position: relative;
  white-space: nowrap;
  box-shadow: inset 0 0 0 transparent;
  transform: none;
}

:where(.dft-c-flow-tabs__tab, .mock-flowtabs__tab)::after {
  content: "";
  position: absolute;
  left: -10px;
  right: -10px;
  bottom: 0;
  height: 2px;
  border-radius: 2px 2px 0 0;
  background: transparent;
  z-index: 2;
}

:where(.dft-c-flow-tabs__tab.is-active, .mock-flowtabs__tab.is-active) {
  color: #22314a;
  font-weight: 780;
  background: transparent;
  border: 0;
  transform: none;
  box-shadow: inset 0 -2px 0 var(--dft-c-flow-current);
}

:where(.dft-c-flow-tabs__tab.is-active, .mock-flowtabs__tab.is-active)::after {
  background: var(--dft-c-flow-current);
}

:where(.dft-c-step-status, .mock-flowtabs__status) {
  width: 14px;
  height: 14px;
  border-radius: 999px;
  font-size: 8.5px;
  font-weight: 820;
  box-shadow: none;
}

:where(.dft-c-step-status--done, .mock-flowtabs__status--done) {
  color: #ffffff;
  border-color: #f0aa10;
  background: var(--dft-c-warning);
}

:where(.dft-c-step-status--idle, .mock-flowtabs__status--idle) {
  color: #7a8497;
  border: 1px solid #e2e7ef;
  background: #f7f9fc;
}

:where(.dft-c-flow-tabs__tab.is-active .dft-c-step-status--idle, .mock-flowtabs__tab.is-active .mock-flowtabs__status--idle) {
  color: #ffffff;
  border-color: #f0aa10;
  background: var(--dft-c-flow-current);
}

:where(.dft-c-step-status--running, .mock-flowtabs__status--running) {
  color: #f3ad10;
  border-color: color-mix(in srgb, #f3ad10 28%, #ffffff);
  background: #fff9e8;
}

:where(.dft-c-step-status__number, .mock-flowtabs__status-number) {
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

:where(.dft-c-step-status__spinner, .mock-flowtabs__status-spinner) {
  width: 8px;
  height: 8px;
}

:where(.dft-c-flow-tabs__label, .mock-flowtabs__label) {
  line-height: 1;
}

:where(.dft-c-topbar-flow, .mock-topbar__flow) {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  justify-content: center;
  align-self: stretch;
}

:where(.dft-c-account-menu) {
  position: relative;
}

:where(.dft-c-account-summary, .teacher-account-menu__summary) {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

:where(.dft-c-avatar, .teacher-account-menu__avatar) {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #0d1b35;
  color: #ffffff;
  font-weight: 800;
  line-height: 1;
}

:where(.dft-c-account-summary__identity, .teacher-account-menu__identity) {
  min-width: 0;
  display: grid;
  gap: 1px;
}

:where(.dft-c-account-summary__name, .teacher-account-menu__name) {
  color: var(--dft-c-text);
  font-weight: 760;
  line-height: 1.1;
}

:where(.dft-c-account-summary__meta, .teacher-account-menu__email, .teacher-account-menu__mode) {
  color: #728098;
  line-height: 1.1;
}

:where(.dft-c-review-workspace, .dft-transcription-redesign.mock-card) {
  --dft-review-panel-height: var(--dft-c-review-panel-height);
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  padding: 0;
}

:where(.dft-c-review-row, .dft-transcription-redesign .mock-transcription-row) {
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.98fr);
  gap: 8px;
  align-items: stretch;
  min-height: var(--dft-review-panel-height);
}

:where(.dft-c-review-panel, .dft-transcription-redesign .mock-transcription-io__cell--photo, .dft-transcription-redesign .mock-transcription-io__cell--transcript) {
  height: var(--dft-review-panel-height);
  min-height: var(--dft-review-panel-height);
  max-height: none;
  align-self: start;
  border: 1px solid var(--dft-c-border);
  border-radius: var(--dft-c-radius-panel);
  background: var(--dft-c-surface);
  overflow: hidden;
  box-shadow: var(--dft-c-shadow-hairline);
}

:where(.dft-c-panel-header, .dft-review-panel__header) {
  height: 45px;
  padding: 9px 14px 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

:where(.dft-c-panel-header--media, .dft-review-panel__header--photo) {
  position: relative;
  justify-content: flex-start;
}

:where(.dft-c-panel-title, .dft-review-panel__title) {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #27364f;
  font-size: 11px;
  font-weight: 760;
  line-height: 1;
  white-space: nowrap;
}

:where(.dft-c-panel-title__icon, .dft-review-panel__icon) {
  color: var(--dft-c-accent);
  font-size: 14px;
}

:where(.dft-c-page-controls, .dft-page-controls) {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--dft-c-control-text);
  font-size: 11px;
  font-weight: 720;
}

:where(.dft-c-icon-button, .dft-icon-button) {
  width: 24px;
  height: 24px;
  border-radius: var(--dft-c-radius-control);
  border: 1px solid var(--dft-c-border-control);
  background: var(--dft-c-surface);
  color: var(--dft-c-control-text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  line-height: 1;
  cursor: pointer;
}

:where(.dft-c-icon-button:hover, .dft-c-icon-button:focus-visible, .dft-icon-button:hover, .dft-icon-button:focus-visible) {
  border-color: #bfd4ff;
  color: var(--dft-c-accent);
  outline: none;
}

:where(.dft-c-control-pill, .dft-page-controls__pager, .dft-page-controls__count, .dft-page-controls__zoom) {
  height: 24px;
  min-width: 62px;
  border: 1px solid var(--dft-c-border-control);
  border-radius: var(--dft-c-radius-control);
  background: var(--dft-c-surface);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 8px;
  font-variant-numeric: tabular-nums;
}

:where(.dft-c-control-pill--pager, .dft-page-controls__pager) {
  min-width: 108px;
  border-radius: 7px;
  overflow: hidden;
  padding: 0;
}

:where(.dft-c-control-pill--zoom, .dft-page-controls__zoom) {
  min-width: 76px;
  padding: 0;
}

:where(.dft-c-document-viewer, .dft-photo-viewer) {
  height: calc(100% - 72px);
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 12px;
  padding: 0 12px 0 9px;
}

:where(.dft-c-document-viewer__thumbs, .dft-photo-viewer__thumbs) {
  min-width: 0;
  overflow: auto;
  padding: 12px 0 6px;
  display: grid;
  gap: 8px;
  align-content: start;
  scrollbar-width: none;
}

:where(.dft-c-document-viewer__thumbs, .dft-photo-viewer__thumbs)::-webkit-scrollbar {
  width: 0;
  height: 0;
}

:where(.dft-c-document-viewer__thumb-count, .dft-photo-viewer__thumb-count) {
  color: #7b879d;
  font-size: 10px;
  font-weight: 760;
  line-height: 1;
  padding-left: 1px;
}

:where(.dft-c-page-thumb, .dft-page-thumb) {
  width: 56px;
  display: grid;
  gap: 3px;
  justify-items: center;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  border-radius: 0;
  color: #73809a;
  font-size: 10px;
  font-weight: 780;
  cursor: pointer;
}

:where(.dft-c-page-thumb img, .dft-page-thumb img) {
  width: 54px;
  min-width: 54px;
  max-width: none;
  height: 70px;
  object-fit: contain;
  object-position: top center;
  border: 1px solid var(--dft-c-border);
  border-radius: 5px;
  background: var(--dft-c-surface);
  padding: 1px;
}

:where(.dft-c-page-thumb.is-active img, .dft-page-thumb.is-active img) {
  border-color: var(--dft-c-accent);
  box-shadow: 0 0 0 2px var(--dft-c-accent);
}

:where(.dft-c-page-thumb.is-active, .dft-page-thumb.is-active) {
  color: var(--dft-c-accent);
}

:where(.dft-c-document-viewer__stage, .dft-photo-viewer__stage) {
  min-height: 0;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  overflow: hidden;
  border: 1px solid var(--dft-c-border-soft);
  border-radius: var(--dft-c-radius-panel);
  background: var(--dft-c-surface-subtle);
  padding: 9px;
}

:where(.dft-c-document-viewer__hint, .dft-photo-viewer__hint) {
  height: 27px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #8a95a8;
  font-size: 10px;
  line-height: 1;
}

:where(.dft-c-button-group, .dft-transcript-actions) {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

:where(.dft-c-button, .dft-panel-button) {
  height: 26px;
  border: 1px solid #e3e8f1;
  border-radius: var(--dft-c-radius-control);
  background: var(--dft-c-surface);
  color: #27364f;
  padding: 0 9px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 10.5px;
  font-weight: 740;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
}

:where(.dft-c-button:hover, .dft-c-button:focus-visible, .dft-panel-button:hover, .dft-panel-button:focus-visible) {
  border-color: #bfd4ff;
  color: var(--dft-c-accent);
  outline: none;
}

:where(.dft-c-skeleton, .dft-skeleton) {
  display: grid;
  gap: 10px;
  padding: 16px;
  border: 1px solid var(--dft-c-border);
  border-radius: var(--dft-c-radius-panel);
  background: var(--dft-c-surface);
}

:where(.dft-c-skeleton__line, .dft-skeleton__line) {
  height: 12px;
  border-radius: 999px;
  background: linear-gradient(90deg, #eef2f7 0%, #f8fafc 50%, #eef2f7 100%);
  background-size: 220% 100%;
}

:where(.dft-c-skeleton__line--short, .dft-skeleton__line--short) {
  width: 36%;
}

:where(.dft-c-skeleton__line--medium, .dft-skeleton__line--medium) {
  width: 62%;
}

:where(.dft-c-skeleton__line--full, .dft-skeleton__line--full) {
  width: 100%;
}

:where(.dft-c-meta-bar, .dft-transcript-meta) {
  height: 32px;
  padding: 0 14px 8px;
  border-bottom: 1px solid var(--dft-c-border-soft);
  display: flex;
  align-items: center;
  gap: 18px;
  color: #45536b;
  font-size: 9.5px;
  line-height: 1;
  white-space: nowrap;
  overflow: visible;
}

:where(.dft-c-meta-bar strong, .dft-c-field__label, .dft-transcript-meta strong, .dft-transcript-meta__student span) {
  color: #66728a;
  font-weight: 760;
}

:where(.dft-c-field__status, .dft-transcript-meta__student-status) {
  color: #66728a;
  font-size: 9px;
  font-weight: 760;
  white-space: nowrap;
}

:where(.dft-c-field__status[data-state="saved"], .dft-transcript-meta__student-status[data-state="saved"]) {
  color: var(--dft-c-success);
}

:where(.dft-c-field__status[data-state="error"], .dft-transcript-meta__student-status[data-state="error"]) {
  color: var(--dft-c-danger);
}

:where(.dft-c-field--inline, .dft-transcript-meta__student) {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
  margin: 0;
  font-size: 9.5px;
  font-weight: 700;
  line-height: 1;
}

:where(.dft-c-select, .dft-transcript-meta select) {
  position: relative;
  z-index: 2;
  height: 20px;
  min-height: 20px;
  min-width: 116px;
  max-width: 132px;
  appearance: none;
  border: 1px solid #dfe7f2;
  border-radius: 5px;
  background:
    linear-gradient(45deg, transparent 50%, #6e7b90 50%) calc(100% - 11px) 8px / 5px 5px no-repeat,
    linear-gradient(135deg, #6e7b90 50%, transparent 50%) calc(100% - 8px) 8px / 5px 5px no-repeat,
    var(--dft-c-surface);
  color: #27364f;
  font-size: 9.5px;
  font-weight: 700;
  line-height: 18px;
  padding: 0 21px 0 8px;
  margin: 0;
}

:where(.dft-c-readable-transcript, .dft-transcript-plain-view) {
  display: grid;
  gap: 2px;
  align-content: start;
  min-height: 100%;
}

:where(.dft-c-readable-transcript__line, .dft-transcript-plain-view__line) {
  white-space: normal;
  overflow-wrap: anywhere;
  color: var(--dft-c-text);
  line-height: 1.22;
}

:where(.dft-c-readable-transcript__line > .mock-transcriptbox__line, .dft-c-readable-transcript__line > .mock-transcriptbox__warn, .dft-c-readable-transcript__line > .mock-transcriptbox__h, .dft-transcript-plain-view__line > .mock-transcriptbox__line, .dft-transcript-plain-view__line > .mock-transcriptbox__warn, .dft-transcript-plain-view__line > .mock-transcriptbox__h) {
  margin-top: 0;
  line-height: inherit;
  white-space: normal;
}

:where(.dft-c-question-chip, .dft-transcript-plain-view__question, .dft-transcript-question-pill) {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: max-content;
  justify-self: start;
  min-height: 16px;
  padding: 0 7px;
  border-radius: 999px;
  background: #edf5ff;
  color: #2472ff;
  font-family: var(--font-sans, inherit);
  font-size: 9px;
  font-weight: 800;
  line-height: 1;
  box-shadow: none;
}

:where(.dft-c-question-marker-select, .dft-transcript-inline-marker select) {
  display: none;
  height: 18px;
  min-height: 18px;
  min-width: 86px;
  max-width: 118px;
  border-color: #cfe0ff;
  background-color: #f7fbff;
  color: var(--dft-c-accent);
  font-size: 9px;
  font-weight: 820;
}

:where([data-question-split-editing="1"], [data-transcript-editing="1"]) :where(.dft-transcript-inline-marker) {
  position: relative;
}

:where([data-question-split-editing="1"], [data-transcript-editing="1"]) :where(.dft-transcript-inline-marker [data-inline-question-marker-label]) {
  display: inline;
}

:where([data-question-split-editing="1"], [data-transcript-editing="1"]) :where(.dft-transcript-inline-marker select) {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  min-width: 0;
  max-width: none;
  opacity: 0;
  cursor: pointer;
}

:where([data-transcript-wysiwyg-editor] [contenteditable]) {
  cursor: text;
  caret-color: var(--dft-c-accent);
}

:where([data-transcript-wysiwyg-editor] [contenteditable]:focus-visible) {
  outline: none;
}

:where(.dft-c-inline-editor, .mock-transcript-editor-panel--inline) {
  min-height: 100%;
  padding: 0;
  color: var(--dft-c-text);
}

:where(.dft-c-inline-insert, .mock-transcript-editor-marker-insert) {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 8px;
  padding: 7px;
  border: 1px dashed #cfe0ff;
  border-radius: var(--dft-c-radius-control);
  background: #f7fbff;
}

:where(.dft-c-inline-insert[hidden], .mock-transcript-editor-marker-insert[hidden]) {
  display: none;
}

:where(.dft-c-transcript-pane, .dft-transcription-redesign .mock-transcription-io__cell--transcript .mock-transcriptbox) {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  border: 0;
  border-radius: 0;
  padding: 10px 14px 16px;
  background: var(--dft-c-surface);
  background-image: none;
  color: var(--dft-c-text);
  font-family: var(--dft-c-font-mono);
  font-size: 9.5px;
  line-height: 1.28;
}

:where(.dft-c-markdown-pane .mock-transcriptbox__line--md-table, .dft-transcription-redesign .dft-transcript-plain-view .mock-transcriptbox__line--md-table) {
  border: 1px solid #eef2f7;
  border-radius: 5px;
  background: var(--dft-c-surface-subtle);
  overflow: hidden;
}

:where(.dft-c-markdown-pane .mock-md-cell, .dft-transcription-redesign .dft-transcript-plain-view .mock-md-cell) {
  border-color: #edf2f7;
  padding: 2px 6px;
}

:where(.dft-c-markdown-pane table, .dft-transcription-redesign .dft-transcript-plain-view table) {
  width: 100%;
  border-collapse: collapse;
  margin: 4px 0 7px;
  font-variant-numeric: tabular-nums;
}

:where(.dft-c-markdown-pane th, .dft-c-markdown-pane td, .dft-transcription-redesign .dft-transcript-plain-view th, .dft-transcription-redesign .dft-transcript-plain-view td) {
  border: 1px solid #edf2f7;
  padding: 3px 6px;
  text-align: left;
  vertical-align: top;
  background: var(--dft-c-surface-subtle);
}

:where(.dft-c-markdown-pane th, .dft-transcription-redesign .dft-transcript-plain-view th) {
  font-weight: 800;
}

:where(.dft-c-markdown-pane p, .dft-transcription-redesign .dft-transcript-plain-view p) {
  margin: 0 0 2px;
}

:where(.dft-c-markdown-pane .katex, .dft-c-markdown-pane .katex-size, .dft-transcription-redesign .dft-transcript-plain-view .katex, .dft-transcription-redesign .dft-transcript-plain-view .katex-size) {
  font-size: 1em;
}

:where(.dft-c-markdown-pane .katex-display, .dft-transcription-redesign .dft-transcript-plain-view .katex-display) {
  margin: 2px 0;
  overflow-x: auto;
  overflow-y: hidden;
}

@media (max-width: 980px) {
  :where(.dft-c-topbar-flow, .mock-topbar__flow),
  :where(.dft-c-flow-tabs, .mock-flowtabs) {
    justify-content: flex-start;
  }

  :where(.dft-c-topbar-flow, .mock-topbar__flow) {
    overflow-x: auto;
  }

  :where(.dft-c-control-pill--zoom, .dft-page-controls__zoom) {
    display: none;
  }
}

@media (max-width: 760px) {
  :where(.dft-c-review-workspace, .dft-transcription-redesign.mock-card) {
    --dft-review-panel-height: max(520px, calc(100dvh - 180px));
  }

  :where(.dft-c-page-flow, .dft-transcript-flow-shell) {
    gap: 10px;
  }

  :where(.dft-c-page-title, .dft-transcript-flow-shell h1) {
    font-size: 20px;
    line-height: 1.12;
    overflow-wrap: anywhere;
  }

  :where(.dft-c-context-card, .dft-test-context-card) {
    padding: 8px 10px;
  }

  :where(.dft-c-context-card__title, .dft-test-context-card__title) {
    white-space: normal;
  }

  :where(.dft-c-phase-progress__label, .mock-transcription-progress__phaseLabel) {
    justify-content: center;
  }

  :where(.dft-c-phase-progress__label span, .mock-transcription-progress__phaseLabel span) {
    display: none;
  }

  :where(.dft-c-panel-header, .dft-review-panel__header) {
    padding: 8px 9px;
    gap: 7px;
  }

  :where(.dft-c-panel-title, .dft-review-panel__title) {
    gap: 6px;
    font-size: 11px;
  }

  :where(.dft-c-document-viewer, .dft-photo-viewer) {
    grid-template-columns: 52px minmax(0, 1fr);
    gap: 8px;
    padding: 0 8px 0 7px;
  }

  :where(.dft-c-document-viewer__thumb-count, .dft-photo-viewer__thumb-count) {
    font-size: 9px;
  }

  :where(.dft-c-page-thumb, .dft-page-thumb) {
    width: 48px;
  }

  :where(.dft-c-page-thumb img, .dft-page-thumb img) {
    width: 44px;
    min-width: 44px;
    height: 58px;
  }

  :where(.dft-c-button-group, .dft-transcript-actions) {
    gap: 5px;
  }

  :where(.dft-c-meta-bar, .dft-transcript-meta) {
    gap: 9px;
    overflow-x: auto;
  }
}
