/* Focused quality release. Load after the existing portal or Supplies styles.
   Existing theme tokens, document page typography and print styles stay local. */
.document-text-alternative { margin: 20px 0; padding: 16px 20px; border: 1px solid #cfdee5; border-radius: 12px; background: #fff; }
.document-text-alternative > summary { min-height: 44px; display: list-item; cursor: pointer; font-size: 16px; font-weight: 650; line-height: 1.5; padding: 10px 0; }
.document-text-alternative .doc-text { overflow-wrap: anywhere; }
@media screen {
  /* openModal owns this three-part structure. Header/footer occupy their own
     space; only the body scrolls, so neither can cover a focused control. */
  body #dialog[open] {
    display: flex;
    flex-direction: column;
    max-height: calc(100dvh - 24px);
    overflow: hidden;
  }

  #dialog[open] > #dialog-content {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-width: 0;
    min-height: 0;
    max-height: calc(100dvh - 26px);
    overflow: hidden;
  }

  #dialog[open] > #dialog-content > :is(.modal-head, .modal-foot) {
    position: relative;
    flex: 0 0 auto;
    min-width: 0;
    background: #f5fafc;
  }

  #dialog[open] > #dialog-content > .modal-head {
    align-items: flex-start;
  }

  #dialog[open] > #dialog-content > .modal-head > div {
    min-width: 0;
    overflow-wrap: anywhere;
  }

  #dialog[open] > #dialog-content > .modal-head > .btn {
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
  }

  #dialog[open] > #dialog-content > .modal-body {
    flex: 1 1 auto;
    min-width: 0;
    min-height: 0;
    overflow: auto;
    overscroll-behavior: contain;
    scroll-padding-block: 12px;
  }

  #dialog[open] .modal-body :is(button, a, input, select, textarea, summary, [tabindex]) {
    scroll-margin-block: 12px;
  }

  #dialog[open] > #dialog-content > .modal-foot {
    flex-wrap: wrap;
    gap: 8px;
  }

  #dialog[open] > #dialog-content > .modal-foot > .btn {
    flex: 0 1 auto;
    min-width: 44px;
    min-height: 44px;
  }
}

@media screen and (max-width: 560px) {
  /* The earlier mobile stylesheet uses !important padding on these regions. */
  #dialog[open] > #dialog-content > :is(.modal-head, .modal-foot) {
    padding: 12px 16px !important;
  }

  #dialog[open] > #dialog-content > .modal-body {
    padding: 18px 16px !important;
  }

  #dialog[open] > #dialog-content > .modal-head h2 {
    font-size: 20px;
    line-height: 1.35;
  }

  #dialog[open] > #dialog-content > .modal-head p {
    font-size: 13px;
    line-height: 1.5;
    margin-top: 6px;
  }
}

@media screen and (max-width: 680px) {
  /* Carry the existing narrow-screen card composition up to the point where
     two columns force descriptions and action labels down to 11-12px. */
  .shell.portal-workspaces .portal-home .home-workspace-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }

  .shell.portal-workspaces .portal-home .workspace-card,
  .shell.portal-workspaces .portal-home .workspace-card:nth-child(n+4) {
    grid-column: auto;
    padding: 20px;
  }

  .shell.portal-workspaces .portal-home .workspace-card .workspace-card-visual,
  .shell.portal-workspaces .portal-home .workspace-card:last-child .workspace-card-visual {
    position: absolute;
    top: 42px;
    right: 15px;
    width: 86px;
    height: 80px;
    margin: 0;
    pointer-events: none;
  }

  .shell.portal-workspaces .portal-home .workspace-card-top {
    margin-bottom: 20px;
  }

  .shell.portal-workspaces .portal-home .workspace-card h3,
  .shell.portal-workspaces .portal-home .workspace-card:last-child h3 {
    width: calc(100% - 90px);
    min-height: 0;
    font-size: 22px;
    line-height: 1.3;
  }

  .shell.portal-workspaces .portal-home .workspace-card-description,
  .shell.portal-workspaces .portal-home .workspace-card:last-child .workspace-card-description {
    min-height: 0;
    max-width: 52ch;
    font-size: 14px;
    line-height: 1.65;
  }

  .shell.portal-workspaces .portal-home .workspace-card-status,
  .shell.portal-workspaces .portal-home .workspace-card-metric {
    font-size: 12px;
    line-height: 1.6;
  }

  .shell.portal-workspaces .portal-home .workspace-card-number {
    font-size: 11px;
  }

  .shell.portal-workspaces .portal-home .workspace-card-action,
  .shell.portal-workspaces .portal-home .workspace-card-request {
    min-height: 44px;
    font-size: 14px;
    line-height: 1.5;
  }

  .shell.portal-workspaces .portal-home .home-filters button {
    min-height: 44px;
    font-size: 13px;
  }
}

@media screen and (max-width: 767px) {
  /* Supplies has no body class. These attributes are in its current static
     document and mounted workspace, and do not match the main portal. */
  html[data-stockroom-theme] .workspace[data-supply-workspace] > .topbar {
    height: auto;
    min-height: calc(62px + env(safe-area-inset-top));
    flex-wrap: wrap;
    gap: 8px;
    padding-top: max(8px, env(safe-area-inset-top));
    padding-bottom: 8px;
  }

  html[data-stockroom-theme] .workspace[data-supply-workspace] > .topbar .breadcrumb {
    flex: 1 1 180px;
    min-width: 0;
    overflow: visible;
  }

  html[data-stockroom-theme] .workspace[data-supply-workspace] > .topbar .top-actions {
    flex: 0 1 auto;
    flex-wrap: wrap;
    justify-content: flex-end;
    min-width: 0;
    max-width: 100%;
    gap: 8px;
  }

  html[data-stockroom-theme] .workspace[data-supply-workspace] > .topbar .top-actions :is(.icon-button, .notification-button, .command-trigger, .motion-toggle),
  html[data-stockroom-theme] .workspace[data-supply-workspace] > .topbar [data-slot="sidebar-trigger"] {
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
  }

  html[data-stockroom-theme] .workspace[data-supply-workspace] .mobile-work-nav button {
    min-height: 44px;
  }

  /* Allow room for the toolbar's two rows when keyboard focus scrolls. */
  html[data-stockroom-theme] .workspace[data-supply-workspace] .page-content :is(button, a, input, select, textarea, [tabindex]) {
    scroll-margin-top: calc(124px + env(safe-area-inset-top));
  }
}

@media screen and (max-width: 560px) {
  html[data-stockroom-theme] .workspace[data-supply-workspace] > .topbar .top-actions {
    flex-basis: 100%;
    justify-content: flex-start;
  }
}

@media screen {
  /* Display the complete source image at the lesson's available width.
     Image artwork and narration remain unchanged. */
  .lms .lms-lesson-image {
    max-height: none;
    height: auto;
  }

  /* The existing slide-text alternative can reflow independently of the
     source image. Keep it readable at desktop and narrow-screen widths. */
  .lms .lms-slide-text .lms-lesson-text {
    font-size: 18px;
    line-height: 1.7;
    overflow-wrap: anywhere;
  }

  .lms .lms-slide-text > summary {
    font-size: 18px;
    line-height: 1.5;
    min-height: 44px;
  }
}

/* Private pages are rendered from the same PDF as Download PDF. These rules
   style the viewer chrome and paper; they never restyle document contents. */
.document-preview {
  min-width: 0;
  color: #17334a;
  font-size: 14px;
  line-height: 1.55;
}
.document-preview [hidden] { display: none !important; }
.document-preview-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; padding: 16px; border: 1px solid #d7e3e9; border-radius: 12px; background: #f5fafc; }
.document-preview-heading { display: grid; flex: 1 1 220px; min-width: 0; gap: 3px; }
.document-preview-heading strong { overflow-wrap: anywhere; font-size: 16px; line-height: 1.5; }
.document-preview-heading > span { color: #52697b; font-size: 13px; }
.document-preview-downloads, .document-preview-controls, .document-preview-zoom-controls { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; min-width: 0; }
.document-preview-downloads { flex: 0 1 auto; }
.document-preview-controls { flex-basis: 100%; gap: 12px 18px; padding-top: 12px; border-top: 1px solid #d7e3e9; }
.document-preview .btn { min-height: 44px; font-size: 13px; white-space: normal; }
.document-preview .btn[aria-pressed="true"] { color: #075c56; background: #e7f6f2; border-color: #79afa8; }
.document-preview-page-label { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin: 0; font-size: 13px; }
.document-preview-page-label > span { color: #52697b; }
.document-preview .document-preview-page-select { width: auto; max-width: 100%; min-height: 44px; margin: 0; font-size: 14px; }
.document-preview-zoom-status { min-width: 55px; color: #52697b; font-size: 13px; font-variant-numeric: tabular-nums; }
.document-preview-page-status { color: #52697b; font-size: 13px; }
.document-preview-page-status:empty { display: none; }
.document-preview .document-preview-reading-note { margin: 14px 0; color: #52697b; font-size: 13px; line-height: 1.6; }
.document-preview-pages { width: 100%; max-width: 100%; min-width: 0; padding: 16px; border: 1px solid #d7e3e9; border-radius: 12px; background: #eaf0f4; overflow-x: auto; overscroll-behavior-x: contain; scroll-padding: 12px; }
.document-preview-page { width: 100%; max-width: 1000px; min-width: 0; margin: 0 auto 24px; border: 1px solid #ccd9e2; border-radius: 3px; background: #fff; box-shadow: 0 4px 14px #183a5012; scroll-margin-block: 12px; }
.document-preview-page:last-child { margin-bottom: 0; }
.document-preview-page-caption { padding: 9px 12px; border-bottom: 1px solid #e0e8ee; color: #52697b; background: #f9fbfc; font-size: 12px; font-variant-numeric: tabular-nums; }
.document-preview .document-preview-page-image { display: block; width: 100%; max-width: none; height: auto; margin: 0; padding: 0; border: 0; border-radius: 0; object-fit: contain; background: #fff; }
.document-preview-zoom-125 .document-preview-page { width: 125%; max-width: none; margin-inline: 0; }
.document-preview-zoom-150 .document-preview-page { width: 150%; max-width: none; margin-inline: 0; }
.document-preview-zoom-200 .document-preview-page { width: 200%; max-width: none; margin-inline: 0; }
.document-preview :is(button, a, select, figure):focus-visible { outline: 3px solid #087f9a; outline-offset: 3px; }
.document-preview-loading { display: flex; align-items: center; justify-content: center; gap: 13px; min-height: 160px; padding: 24px; color: #52697b; }
.document-preview-spinner { display: inline-block; flex: none; width: 24px; height: 24px; border: 3px solid #cbdfe4; border-top-color: #087c75; border-radius: 50%; animation: document-preview-spin 1s linear infinite; }
.document-preview-message { padding: 20px; margin-bottom: 14px; border: 1px solid #d7e3e9; border-radius: 12px; background: #f5fafc; }
.document-preview-message strong { display: block; font-size: 16px; }
.document-preview-message p { margin: 8px 0 0; color: #52697b; line-height: 1.65; }
.document-preview-error { border-color: #e3c7c9; background: #fff7f7; }
.document-preview-page-error { padding: 24px; min-height: 160px; }
.document-preview-page-error p { margin: 0 0 12px; color: #8f2f38; }
@keyframes document-preview-spin { to { transform: rotate(360deg); } }
@media (max-width: 560px) {
  .document-preview-toolbar { padding: 12px; gap: 12px; }
  .document-preview-downloads { width: 100%; }
  .document-preview-downloads > .btn { flex: 1 1 120px; }
  .document-preview-controls { align-items: flex-start; flex-direction: column; }
  .document-preview .document-preview-page-select { font-size: 16px; }
  .document-preview-pages { padding: 8px; }
  .document-preview-page { margin-bottom: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  .document-preview-spinner { animation: none; border-right-color: #087c75; }
}
@media print {
  .document-preview-toolbar, .document-preview-reading-note { display: none; }
  .document-preview-pages { padding: 0; border: 0; overflow: visible; background: #fff; }
  .document-preview .document-preview-page { width: 100%; max-width: none; margin: 0; border: 0; box-shadow: none; break-after: page; break-inside: avoid; }
  .document-preview .document-preview-page:last-child { break-after: auto; }
}

/* Enlarging a lesson changes layout only; narration stays in the same DOM. */
@media screen {
.lms .lms-player-view-controls { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.lms .lms-player-view-controls > .btn { min-height: 44px; }
.lms .lms-player-view-help { margin: 10px 0 0; font-size: 14px; line-height: 1.6; }
.lms .lms-player-view-help[hidden] { display: none; }
.lms .lms-player-layout.lms-player-expanded { display: grid; grid-template-columns: minmax(0, 1fr); }
.lms .lms-player-expanded > .lms-lesson { width: 100%; min-width: 0; padding: 20px; }
.lms .lms-player-expanded > .lms-narration { position: static; order: 0; width: 100%; max-height: none; overflow: visible; }
.lms .lms-player-expanded .lms-lesson-image { max-height: none; }
@media (max-width: 560px) {
  .lms .lms-player-expanded > .lms-lesson { padding: 12px; }
  .lms .lms-player-view-help { font-size: 13px; }
}
}

/* BEGIN VERIFIED LMS BRANDING */
/* Only exact-hash images receive these wrappers. All rectangles were inspected
   as branding-only; percentages follow the image's natural aspect ratio. */
.lms .lms-brand-plate { display: none; }
@media screen {
  .lms .lms-branded-slide { position: relative; width: 100%; min-width: 0; padding: 0; border: 0; margin: 20px 0 0; overflow: hidden; border-radius: 12px; }
  .lms .lms-branded-slide > .lms-lesson-image { display: block; width: 100%; max-width: none; height: auto; max-height: none; margin: 0; padding: 0; border: 0; border-radius: 0; object-fit: contain; }
  .lms .lms-brand-plate { position: absolute; box-sizing: border-box; padding: 0; border: 0; margin: 0; overflow: hidden; background: #fff; pointer-events: none; user-select: none; align-items: center; justify-content: center; }
  .lms .lms-brand-plate.lms-brand-ready { display: flex; }
  .lms .lms-brand-plate > .lms-brand-logo { display: block; width: 100%; height: 100%; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; border-radius: 0; object-fit: contain; pointer-events: none; }
  .lms .lms-brand-region-0 { left: 89.33593750%; top: 81.04166667%; width: 8.63281250%; height: 15.34722222%; }
  .lms .lms-brand-region-1 { left: 85.93750000%; top: 84.72222222%; width: 12.10937500%; height: 13.54166667%; }
  .lms .lms-brand-region-2 { left: 85.97108245%; top: 84.72222222%; width: 12.11410707%; height: 13.54166667%; }
  .lms .lms-brand-region-3 { left: 92.57812500%; top: 1.66666667%; width: 5.46875000%; height: 11.66666667%; }
  .lms .lms-brand-region-4 { left: 2.18750000%; top: 93.47222222%; width: 3.00781250%; height: 4.58333333%; }
  .lms .lms-brand-region-5 { left: 92.42187500%; top: 86.52777778%; width: 4.84375000%; height: 8.61111111%; }
  .lms .lms-brand-region-6 { left: 43.75000000%; top: 8.33333333%; width: 12.50000000%; height: 19.44444444%; }
  .lms .lms-brand-region-7 { left: 91.40625000%; top: 86.45833333%; width: 5.85937500%; height: 13.40277778%; }
}
/* END VERIFIED LMS BRANDING */

/* BEGIN SOURCE TEXT TAKEAWAYS */
/* These four native-text slides use document flow so teaching text and footer
   cannot overlap when the viewport narrows or the user enlarges text. */
@media screen {
  .lms .lms-readable-slide { box-sizing: border-box; width: 100%; min-width: 0; margin: 20px 0; padding: 24px 28px; border: 1px solid #244f76; border-radius: 12px; background: #123e68; color: #fff; font-size: 18px; line-height: 1.7; overflow-wrap: anywhere; }
  .lms .lms-readable-points { margin: 0; padding: 0 0 0 1.3em; list-style: disc outside; }
  .lms .lms-readable-points > li { margin: 0 0 16px; padding-left: 5px; font-size: 18px; line-height: 1.7; }
  .lms .lms-readable-points > li:last-child { margin-bottom: 0; }
  .lms .lms-readable-points > li::marker { color: #b6e8ff; }
  .lms .lms-readable-footer { position: static; margin: 24px 0 0; padding: 20px 0 0; border-top: 1px solid #6c90b0; color: #fff; font-size: 18px; line-height: 1.7; }
  .lms .lms-readable-footer > p { margin: 0; font-size: 18px; line-height: 1.7; }
  .lms .lms-readable-footer > p + p { margin-top: 10px; }
  .lms .lms-readable-source { margin: 16px 0; min-width: 0; }
  .lms .lms-readable-source > summary { padding: 10px 0; color: #24546a; font-size: 18px; line-height: 1.7; cursor: pointer; }
  .lms .lms-readable-source > summary:focus-visible { outline: 3px solid #087f9a; outline-offset: 3px; }
  .lms .lms-readable-source > .lms-lesson-image { width: 100%; height: auto; max-height: none; }
  @media (max-width: 560px) {
    .lms .lms-readable-slide { padding: 18px 16px; }
  }
}
/* END SOURCE TEXT TAKEAWAYS */

/* Training evidence follows the workspace's responsive card layout. */
.learning-records .section-head { flex-wrap: wrap; gap: 16px; }
.learning-record-list { display: grid; gap: 16px; }
.learning-record { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 20px; padding: 20px; border: 1px solid #cedee7; border-radius: 12px; background: #fff; }
.learning-record-body { flex: 1 1 260px; min-width: 0; overflow-wrap: anywhere; }
.learning-record h3 { margin: 0 0 8px; font-size: 20px; line-height: 1.4; }
.learning-record p { margin: 6px 0; }
.learning-record > .btn { white-space: normal; text-align: center; }
.learning-records-compact { margin-top: 24px; }
@media (max-width: 560px) { .learning-record { padding: 16px; } .learning-record > .btn { width: 100%; } }

/* BEGIN LAUNCH WORKSPACE QUALITY */
/* Working controls only: PDF pages, approved document text and lesson artwork
   retain their existing rules above. No font or asset request is introduced. */
@media screen {
  .shell.portal-workspaces {
    --quality-secondary: #52697b;
    --quality-ink: #17334a;
    --quality-soft: #f5fafc;
    --quality-line: #cfdee5;
    font-size: 16px;
    line-height: 1.55;
  }

  .shell.portal-workspaces:not([data-workspace="home"]) .page-head.workspace-page-header {
    min-height: 0;
    padding: 24px;
    gap: 20px;
    border-radius: 16px;
    margin-bottom: 24px;
    background: #102f42;
    box-shadow: none;
    overflow: visible;
    flex-wrap: wrap;
  }

  .shell.portal-workspaces:not([data-workspace="home"]) .workspace-page-header::before,
  .shell.portal-workspaces:not([data-workspace="home"]) .workspace-page-header::after,
  .shell.portal-workspaces:not([data-workspace="home"]) .workspace-header-art {
    display: none;
  }

  .shell.portal-workspaces:not([data-workspace="home"]) .page-head.workspace-page-header :is(h1,.workspace-title) {
    font-size: clamp(26px, 2.4vw, 32px);
    line-height: 1.25;
  }

  .shell.portal-workspaces:not([data-workspace="home"]) .page-head.workspace-page-header :is(p,.workspace-description) {
    font-size: 16px;
    line-height: 1.55;
    margin-top: 8px;
  }

  .shell.portal-workspaces:not([data-workspace="home"]) .workspace-intro-actions {
    gap: 8px;
    min-width: 0;
  }

  .shell.portal-workspaces .main :is(.btn,.category,.tabs-local button,.luminous-filter-chip) {
    min-height: 44px;
    font-size: 14px;
    line-height: 1.5;
  }

  .shell.portal-workspaces .main :is(.doc-meta,.stat-label,.list-heading,.course-facts,.course-result-summary,.luminous-filter-summary) {
    color: var(--quality-secondary);
    font-size: 14px;
    line-height: 1.55;
  }

  .shell.portal-workspaces .main .badge {
    font-size: 13px;
    line-height: 1.45;
    padding: 4px 8px;
  }

  .shell.portal-workspaces:not([data-workspace="home"]) .stats {
    gap: 12px;
    margin-bottom: 24px;
  }

  .shell.portal-workspaces:not([data-workspace="home"]) .stat {
    padding: 16px;
    gap: 12px;
  }

  .shell.portal-workspaces .portal-home .workspace-card-description { font-size: 14px; line-height: 1.6; }
  .shell.portal-workspaces .portal-home :is(.workspace-card-status,.workspace-card-metric,.home-data-note,.home-footer) { font-size: 13px; line-height: 1.55; }
  .shell.portal-workspaces .portal-home :is(.workspace-card-action,.workspace-card-request) { font-size: 14px; }

  /* Role lookup: compact counts remain labelled; all copy has natural height. */
  .shell.portal-workspaces[data-workspace="onboarding"] .hiring-library-intro { margin: 20px 0; gap: 16px; }
  .shell.portal-workspaces[data-workspace="onboarding"] .hiring-library-intro h2 { font-size: 24px; line-height: 1.35; }
  .shell.portal-workspaces[data-workspace="onboarding"] .hiring-role-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
    gap: 12px;
  }
  .shell.portal-workspaces[data-workspace="onboarding"] .hiring-role-card { padding: 16px; border-top-width: 2px; border-radius: 12px; box-shadow: none; }
  .shell.portal-workspaces[data-workspace="onboarding"] .hiring-role-card h4 { margin: 12px 0 8px; font-size: 19px; line-height: 1.35; }
  .shell.portal-workspaces[data-workspace="onboarding"] .hiring-role-code { font-size: 12px; color: var(--quality-secondary); }
  .shell.portal-workspaces[data-workspace="onboarding"] .hiring-role-card > p { font-size: 14px; line-height: 1.55; margin-bottom: 8px; }
  .shell.portal-workspaces[data-workspace="onboarding"] .hiring-document-counts {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin: auto 0 12px;
    padding-top: 8px;
  }
  .shell.portal-workspaces[data-workspace="onboarding"] .hiring-document-counts > div { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; padding: 8px 0; border-bottom: 0; border-top: 1px solid var(--quality-line); min-width: 0; }
  .shell.portal-workspaces[data-workspace="onboarding"] .hiring-document-counts dt { font-size: 13px; line-height: 1.5; overflow-wrap: anywhere; }
  .shell.portal-workspaces[data-workspace="onboarding"] .hiring-document-counts dd { font-size: 18px; line-height: 1.3; }
  .shell.portal-workspaces[data-workspace="onboarding"] .hiring-teaching-count { font-size: 13px; gap: 6px; }
  .shell.portal-workspaces[data-workspace="onboarding"] .hiring-department-heading { flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
  .shell.portal-workspaces[data-workspace="onboarding"] .hiring-department-group { margin-bottom: 24px; }

  /* Selected-source capability is one readable value rather than repeated
     disabled options. Group/condition/legacy warnings remain in document flow. */
  #dialog .packet-review .hiring-review-filters { gap: 12px; margin: 16px 0 12px; }
  #dialog .packet-review .hiring-review-document-list { gap: 10px; }
  #dialog .packet-review .hiring-document-option { padding: 14px 16px; border-radius: 10px; }
  #dialog .packet-review .hiring-document-select { min-height: 44px; gap: 12px; }
  #dialog .packet-review .hiring-document-select strong { font-size: 16px; line-height: 1.5; }
  #dialog .packet-review :is(.hiring-document-meta,.hiring-document-context,.upload-hint,.packet-action-help) { font-size: 14px; line-height: 1.55; color: #52697b; }
  #dialog .packet-review :is(.hiring-document-context,.packet-action-help) { margin: 8px 0 0; }
  #dialog .packet-review .hiring-document-tags { margin-top: 8px; gap: 6px; }
  #dialog .packet-review .hiring-document-controls { gap: 12px; margin-top: 12px; align-items: start; }
  #dialog .packet-review .hiring-document-controls > div { min-width: 0; }
  #dialog .packet-review .hiring-document-controls label { margin-top: 0; font-size: 14px; line-height: 1.5; }
  #dialog .packet-review .hiring-required-label { min-height: 44px; }
  #dialog .packet-review .packet-action-value {
    display: flex;
    align-items: center;
    min-height: 44px;
    padding: 10px 12px;
    border: 1px solid #cfdee5;
    border-radius: 8px;
    background: #f5fafc;
    color: #17334a;
    font-size: 14px;
    line-height: 1.5;
    overflow-wrap: anywhere;
    margin: 0;
  }
  #dialog .packet-review .hiring-document-warning { font-size: 14px; line-height: 1.55; padding: 10px 12px; margin-top: 10px; }
  #dialog .packet-review .hiring-reference-plan { padding: 12px 16px; margin: 16px 0; }
  #dialog .packet-review .hiring-reference-plan summary { min-height: 44px; padding: 8px 0; line-height: 1.5; }
  #dialog .packet-review .hiring-packet-approval { padding-top: 16px; border-top: 1px solid #cfdee5; }
  #dialog .packet-review-state {
    min-height: 144px;
    padding: 24px;
    border: 1px solid #cfdee5;
    border-radius: 12px;
    background: #f5fafc;
    color: #17334a;
    font-size: 16px;
    line-height: 1.55;
    overflow-wrap: anywhere;
  }
  #dialog .packet-review-state[role="alert"] { border-color: #e3c7c9; background: #fff7f7; }
  #dialog .packet-review-state .btn { margin-top: 16px; min-height: 44px; }

  /* The stockroom bundle explicitly clears input and wrapper outlines.
     An inset wrapper ring survives its clipped count-cell boundaries. */
  html[data-stockroom-theme="light"] { --quality-count-focus: #075da2; }
  html[data-stockroom-theme="dark"] { --quality-count-focus: #85e0e8; }
  html[data-stockroom-theme] .count-input-form .count-number:focus-within {
    outline: 3px solid var(--quality-count-focus);
    outline-offset: -3px;
    border-radius: 6px;
  }
}

@media screen and (max-width: 700px) {
  #dialog .packet-review .hiring-document-controls { grid-template-columns: minmax(0, 1fr); gap: 10px; }
}
@media screen and (max-width: 560px) {
  .shell.portal-workspaces:not([data-workspace="home"]) .page-head.workspace-page-header { padding: 20px 16px; gap: 16px; }
  .shell.portal-workspaces[data-workspace="onboarding"] .hiring-role-grid { grid-template-columns: minmax(0, 1fr); }
  .shell.portal-workspaces[data-workspace="onboarding"] .hiring-role-card { padding: 16px; }
  #dialog .packet-review .hiring-document-option { padding: 12px; }
  #dialog .packet-review-state { padding: 18px 16px; }
}
@media screen and (forced-colors: active) {
  html[data-stockroom-theme] .count-input-form .count-number:focus-within { outline-color: Highlight; }
}
/* END LAUNCH WORKSPACE QUALITY */
