/* Entry, setup, people and learning components. No application behaviour changes. */
.journey-login {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, .92fr);
  align-items: start;
  gap: clamp(32px, 6vw, 88px);
  max-width: 1040px;
  margin: 36px auto 56px;
}
.journey-login .login-panel { padding: 24px 0; }
.journey-login .login-panel h1 { font-size: clamp(28px, 3.3vw, 38px); letter-spacing: -.04em; }
.journey-login .login-panel form { margin-top: 28px; }
.journey-login .login-panel form > p { margin-bottom: 20px; }
.journey-login .login-panel .helptext { max-width: 100%; }
.login-links, .journey-links { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 24px; }
.login-links { margin-top: 16px; }
.login-links a, .journey-links a { display: inline-flex; align-items: center; min-height: 44px; }
.journey-login .login-story {
  background: var(--navy, #101b35);
  color: #fff;
  border: 1px solid var(--navy, #101b35);
  border-radius: 16px;
  padding: clamp(28px, 4vw, 40px);
}
.journey-login .login-story h2 { color: #fff; font-size: clamp(28px, 3vw, 38px); line-height: 1.15; letter-spacing: -.04em; margin: 24px 0; }
.journey-login .login-story > p, .journey-login .login-story .eyebrow { color: #c8d6e3; }
.login-value-list { list-style: none; margin: 32px 0; padding: 0; }
.login-value-list li { padding: 18px 0; border-top: 1px solid #344159; }
.login-value-list strong, .login-value-list span { display: block; }
.login-value-list strong { font-size: 15px; margin-bottom: 4px; }
.login-value-list span { font-size: 14px; color: #c8d6e3; }
.journey-login .login-story .login-story-note { font-size: 13px; margin-bottom: 0; }

/* The seven saved setup stages stay authoritative; optional detail unfolds nearby. */
.setup-progress { max-width: 800px; margin-bottom: 24px; border: 1px solid var(--line, #dfe5e9); border-radius: 12px; background: #fff; }
.setup-progress > summary { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; padding: 16px 20px; min-height: 56px; font-size: 14px; }
.setup-progress > summary > span:first-child { color: var(--muted, #536276); font-size: 13px; font-weight: 500; }
.setup-progress-hint { margin-left: auto; color: var(--green, #007474); font-size: 13px; }
.setup-progress-hint::after { content: ' +'; }
.setup-progress[open] .setup-progress-hint::after { content: ' −'; }
.setup-progress .setup-stage-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; counter-reset: stage; list-style: none; padding: 0 20px 12px; margin: 0; }
.setup-progress .setup-stage-list li { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--line, #dfe5e9); border-radius: 8px; background: #fafbfc; font-size: 13px; font-weight: 400; color: var(--muted, #536276); }
.setup-progress .setup-stage-list li::before { content: none; }
.setup-step-number { display: grid; place-items: center; width: 24px; height: 24px; flex: 0 0 24px; background: #f0f3f5; border-radius: 50%; font-size: 12px; font-variant-numeric: tabular-nums; font-weight: 650; }
[aria-current="step"] > .setup-step-number { background: #007474; color: #fff; }
.setup-progress .setup-stage-list [aria-current="step"] { color: #005b60; background: #e8f4f2; border-color: #91bdb9; font-weight: 650; }
.setup-progress > p { margin: 0; padding: 0 20px 18px; font-size: 13px; }
.setup-form > h2 { margin-bottom: 12px; }
.setup-form form > div:not(.button-row):not(.notice), .journey-form form > div:not(.button-row):not(.notice):not(.form-grid):not(.table-wrap) { margin-bottom: 20px; }
.setup-form form label, .journey-form form > div > label { display: block; font-weight: 600; margin-bottom: 8px; }
.setup-form li { margin-bottom: 10px; }
.setup-review-row { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; border-bottom: 1px solid var(--line, #dfe5e9); padding: 16px 0; }
.setup-review-row .button { margin-left: auto; }
.setup-resume { display: flex; align-items: center; justify-content: space-between; gap: 16px; background: #edf6f4; border: 1px solid #c8ded9; padding: 20px; border-radius: 12px; margin: 0 0 24px; }
.setup-resume p { margin: 4px 0 0; color: var(--muted, #536276); }
.settings-directory .card > h2 { margin-bottom: 12px; }
.settings-directory .card > a { display: flex; align-items: center; min-height: 44px; }
.settings-counts .metric, .team-activation .metric { padding: 12px 16px; }
.settings-counts .metric strong, .team-activation .metric strong { font-size: 26px; margin: 4px 0 0; }
.team-activation > p { color: var(--muted, #536276); font-size: 13px; margin-bottom: 0; max-width: 1000px; }
.team-activation .metrics { margin-bottom: 16px; }
.staff-actions { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
.staff-actions > a { min-height: 40px; display: inline-flex; align-items: center; }
.staff-access-actions { border-top: 1px solid var(--line, #dfe5e9); width: 100%; margin-top: 6px; }
.staff-access-actions > summary { font-size: 13px; min-height: 44px; }
.staff-access-actions p { font-size: 13px; margin-bottom: 4px; max-width: 260px; }
.staff-access-actions form { margin: 0; }
.danger-action { color: #a02f2b; }
.authenticator-qr { display: block; width: min(240px, 100%); height: auto; margin: 24px 0; }
.journey-form { width: min(100%, 800px); overflow-wrap: anywhere; }
.journey-form > p:last-child { margin-bottom: 0; }
.journey-form code { overflow-wrap: anywhere; }
.journey-form label:has(input[type="checkbox"]) { display: flex; align-items: flex-start; gap: 12px; }

/* Original files, processing and approved revisions are distinct facts. */
.library-tools { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.library-tools .tabs { margin: 0; }
.library-tools .tabs a[aria-current="page"] { background: #e8f4f2; border-color: #8bb8b4; color: #005b60; font-weight: 650; text-decoration: none; }
.library-limit { font-size: 13px; margin: 20px 0 0; }
.library-tools details { max-width: 680px; }
.library-tools details > summary { font-size: 13px; min-height: 44px; }
.library-tools details > p { font-size: 13px; color: var(--muted, #536276); margin: 8px 0; }
.library-table .document-name { min-width: 0; }
.library-table .document-name strong, .library-table .document-name small { overflow-wrap: anywhere; }
.library-table .file-icon { display: grid; place-items: center; width: 36px; height: 40px; background: #eef2f5; border-radius: 8px; color: #536276; flex-shrink: 0; font-size: 22px; }
.library-table td > small { display: block; margin-top: 4px; color: var(--muted, #536276); }
.document-facts { display: flex; flex-wrap: wrap; gap: 8px 24px; margin: 0 0 24px; padding: 16px 0; border-block: 1px solid var(--line, #dfe5e9); }
.document-facts > div { min-width: 140px; }
.document-facts dt { font-size: 12px; color: var(--muted, #536276); }
.document-facts dd { margin: 4px 0 0; font-weight: 600; }
.document-layout .source-panel details { border-top: 1px solid var(--line, #dfe5e9); margin-top: 16px; }
.document-layout .extraction-source { color: var(--muted, #536276); background: #f3f5f7; }
.document-layout .pdf-placeholder { background: #f3f5f7; }
.document-layout .pdf-placeholder > span { color: #657389; }
.document-layout .line-items { min-width: 0; }
.document-layout .line-items input { width: 100%; min-width: 0; }
.document-layout .line-items input[type="checkbox"] { width: 22px; min-width: 22px; }

/* Learning uses the same hierarchy as everyday work, including print output. */
.learning-intro { padding: 22px 24px; background: #edf5f3; border: 1px solid #cfdfdc; border-radius: 12px; }
.learning-intro p:last-child { margin-bottom: 0; }
.learning-search { display: grid; grid-template-columns: minmax(180px, 2fr) minmax(130px, 1fr) minmax(130px, 1fr) auto; gap: 16px; align-items: end; }
.learning-search label { display: block; font-size: 13px; font-weight: 600; }
.learning-search input, .learning-search select { margin-top: 6px; }
.learning-card-foot { font-size: 13px; color: var(--muted, #536276); }
.guide-body { max-width: 900px; }
.guide-steps > li { margin-bottom: 28px; }
.guide-steps > li p { max-width: 75ch; }
.guide-body .guide-steps h2 { font-size: 19px; }
.guide-print-identity { font-size: 13px; color: var(--muted, #536276); }
.launch-checks .card { padding: 20px; }
@media (max-width: 850px) {
  .journey-login { gap: 32px; margin: 16px auto 40px; }
  .learning-search { grid-template-columns: 1fr 1fr; }
  .learning-search label:first-child { grid-column: 1 / -1; }
}
@media (max-width: 700px) {
  .journey-login { display: flex; flex-direction: column; gap: 32px; margin: 0 auto 24px; }
  .journey-login .login-panel { width: 100%; padding: 8px 0; }
  .journey-login .login-panel form { margin-top: 20px; }
  .journey-login .login-story { width: 100%; padding: 24px; margin: 0; }
  .journey-login .login-story h2 { font-size: 28px; margin: 16px 0; }
  .journey-login .login-value-list { margin: 20px 0; }
  .journey-login .eyebrow { font-size: 11px; }
  .setup-progress > summary { padding: 14px 16px; }
  .setup-progress-hint { flex-basis: 100%; margin-left: 0; }
  .setup-progress .setup-stage-list { grid-template-columns: 1fr; padding: 0 16px 12px; }
  .setup-progress > p { padding-inline: 16px; }
  .setup-resume { align-items: flex-start; flex-direction: column; }
  .setup-review-row { align-items: flex-start; flex-direction: column; }
  .setup-review-row .button { margin-left: 0; }
  .learning-search { grid-template-columns: 1fr; }
  .learning-search label:first-child { grid-column: auto; }
  .journey-links { gap: 4px 20px; }
  .library-table, .library-table tbody, .library-table tr, .library-table td { display: block; width: 100%; }
  .library-table thead { display: none; }
  .library-table tr { padding: 12px 0; border-bottom: 1px solid var(--line, #dfe5e9); }
  .library-table td { border: 0; padding: 6px 0; }
  .library-table td[data-label]::before { content: attr(data-label); display: block; color: var(--muted, #536276); font-size: 12px; font-weight: 500; margin-bottom: 4px; }
  .library-table td:first-child { padding-bottom: 12px; }
  .staff-table td { overflow-wrap: anywhere; }
  .staff-actions { gap: 0; }
  .document-facts { gap: 12px 20px; }
  .document-layout .line-items, .document-layout .line-items tbody, .document-layout .line-items tr, .document-layout .line-items td { display: block; width: 100%; }
  .document-layout .line-items thead { display: none; }
  .document-layout .line-items tr { padding-block: 12px; border-bottom: 1px solid var(--line, #dfe5e9); }
  .document-layout .line-items td { border: 0; padding: 6px 0; }
  .document-layout .line-items td::before { content: attr(data-label); display: block; font-size: 13px; color: var(--muted, #536276); margin-bottom: 6px; }
}
@media print {
  .setup-progress { border: 0; }
  .setup-progress > summary, .setup-progress .setup-stage-list { display: block; }
  .setup-progress .setup-stage-list li { border: 0; }
  .setup-resume .button, .journey-links, .staff-access-actions, .login-links { display: none; }
  .guide-body { border: 0; max-width: none; padding: 0; }
  .guide-steps h2, .guide-steps h3 { break-after: avoid; }
}
