:root {
  --blue-950: #17345f;
  --blue-800: #24528e;
  --blue-700: #2f67ad;
  --blue-100: #eaf2ff;
  --blue-50: #f5f8ff;
  --ink: #202a3a;
  --muted: #647086;
  --line: #dbe2ed;
  --paper: #ffffff;
  --canvas: #f2f5f9;
  --warm: #fff7ea;
  --warm-line: #efd6aa;
  --danger: #b43c35;
  --success: #247558;
  --shadow: 0 18px 48px rgba(30, 53, 88, 0.11);
  --radius-lg: 24px;
  --radius-md: 16px;
  --radius-sm: 11px;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--canvas);
  color: var(--ink);
  font-family: "Microsoft YaHei", "PingFang SC", system-ui, sans-serif;
  min-width: 320px;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 6% 2%, rgba(70, 126, 201, 0.12), transparent 27rem),
    linear-gradient(180deg, #f9fbff 0, var(--canvas) 28rem);
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid rgba(47, 103, 173, 0.3);
  outline-offset: 2px;
}

[hidden] {
  display: none !important;
}

.site-header {
  align-items: center;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(211, 220, 233, 0.9);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  min-height: 66px;
  padding: 0 32px;
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(16px);
}

.brand {
  align-items: center;
  color: var(--blue-800);
  display: inline-flex;
  gap: 9px;
  text-decoration: none;
  width: max-content;
}

.brand span {
  font-size: 23px;
}

.header-copy {
  align-items: baseline;
  display: flex;
  gap: 10px;
}

.header-copy span {
  background: var(--blue-100);
  border-radius: 999px;
  color: var(--blue-800);
  font-size: 12px;
  font-weight: 700;
  padding: 4px 9px;
}

.header-copy strong {
  font-size: 16px;
}

.header-reset {
  background: transparent;
  border: 0;
  color: var(--muted);
  cursor: pointer;
  justify-self: end;
  padding: 10px 4px;
}

main {
  margin: 0 auto;
  max-width: 1320px;
  padding: 52px 28px 80px;
}

.hero {
  align-items: end;
  display: grid;
  gap: 42px;
  grid-template-columns: minmax(0, 1fr) 280px;
}

.eyebrow,
.step-kicker,
.section-label {
  color: var(--blue-700);
  display: block;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.12em;
  margin-bottom: 12px;
  text-transform: uppercase;
}

.hero h1 {
  color: var(--blue-950);
  font-size: clamp(32px, 5vw, 58px);
  letter-spacing: -0.045em;
  line-height: 1.12;
  margin: 0;
  max-width: 820px;
}

.hero p {
  color: var(--muted);
  font-size: 17px;
  line-height: 1.85;
  margin: 22px 0 0;
  max-width: 850px;
}

.hero-status {
  background: var(--blue-950);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  color: white;
  display: flex;
  flex-direction: column;
  gap: 7px;
  padding: 24px;
}

.hero-status span,
.hero-status small {
  color: rgba(255, 255, 255, 0.72);
  font-size: 12px;
}

.hero-status strong {
  font-size: 20px;
}

.candidate-access {
  align-items: center;
  background: linear-gradient(135deg, #17345f, #285d9f);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  color: white;
  display: grid;
  gap: 24px;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.72fr);
  margin: 32px 0 24px;
  padding: 25px 28px;
}

.candidate-access .section-label {
  color: #bdd8ff;
  margin-bottom: 7px;
}

.candidate-access h2 {
  font-size: 22px;
  margin: 0;
}

.candidate-access p {
  color: rgba(255, 255, 255, 0.77);
  font-size: 13px;
  line-height: 1.7;
  margin: 8px 0 0;
}

.candidate-access__form,
.candidate-session {
  background: rgba(255, 255, 255, 0.11);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-md);
  padding: 16px;
}

.candidate-access__form label,
.candidate-session > span,
.candidate-session > small {
  color: rgba(255, 255, 255, 0.78);
  display: block;
  font-size: 12px;
  margin-bottom: 7px;
}

.candidate-access__form > div {
  display: grid;
  gap: 9px;
  grid-template-columns: minmax(0, 1fr) auto;
}

.candidate-access__form input {
  background: white;
  border: 0;
  border-radius: 11px;
  min-width: 0;
  padding: 12px 13px;
}

.candidate-access__form .form-error,
.candidate-session > small {
  color: #ffdfb0;
  margin-bottom: 0;
}

.candidate-session strong {
  display: block;
  font-size: 17px;
  margin-bottom: 5px;
}

.candidate-session .button {
  margin-top: 12px;
}

.privacy-strip {
  align-items: flex-start;
  background: var(--warm);
  border: 1px solid var(--warm-line);
  border-radius: var(--radius-md);
  display: flex;
  gap: 14px;
  margin: 36px 0 26px;
  padding: 17px 20px;
}

.privacy-strip > span {
  font-size: 22px;
}

.privacy-strip strong {
  color: #765021;
  display: block;
  line-height: 1.55;
}

.privacy-strip p {
  color: #876b46;
  font-size: 13px;
  line-height: 1.65;
  margin: 3px 0 0;
}

.workspace {
  align-items: start;
  display: grid;
  gap: 24px;
  grid-template-columns: 248px minmax(0, 1fr);
}

.stepper {
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 20px;
  position: sticky;
  top: 90px;
}

.stepper ol {
  list-style: none;
  margin: 0;
  padding: 0;
}

.stepper li {
  align-items: center;
  color: var(--muted);
  display: grid;
  gap: 12px;
  grid-template-columns: 36px 1fr;
  min-height: 67px;
  position: relative;
}

.stepper li:not(:last-child)::after {
  background: var(--line);
  content: "";
  height: 31px;
  left: 17px;
  position: absolute;
  top: 52px;
  width: 2px;
}

.stepper li > span {
  align-items: center;
  background: #edf1f6;
  border: 1px solid var(--line);
  border-radius: 50%;
  display: flex;
  font-size: 13px;
  font-weight: 800;
  height: 36px;
  justify-content: center;
  width: 36px;
}

.stepper li strong,
.stepper li small {
  display: block;
}

.stepper li strong {
  font-size: 14px;
  line-height: 1.5;
}

.stepper li small {
  font-size: 12px;
  margin-top: 2px;
}

.stepper li.is-active {
  color: var(--blue-950);
}

.stepper li.is-active > span,
.stepper li.is-complete > span {
  background: var(--blue-700);
  border-color: var(--blue-700);
  color: white;
}

.stepper li.is-complete::after {
  background: var(--blue-700);
}

.stepper-boundary {
  background: var(--blue-50);
  border-radius: var(--radius-sm);
  margin-top: 18px;
  padding: 14px;
}

.stepper-boundary strong {
  color: var(--blue-950);
  font-size: 13px;
}

.stepper-boundary p {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.65;
  margin: 6px 0 0;
}

.panel {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  min-height: 650px;
  overflow: hidden;
  padding: clamp(24px, 5vw, 54px);
}

.step-view h2 {
  color: var(--blue-950);
  font-size: clamp(25px, 3vw, 36px);
  letter-spacing: -0.025em;
  margin: 0;
}

.lead {
  color: var(--muted);
  line-height: 1.8;
  margin: 13px 0 28px;
}

.notice-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.notice-grid article {
  align-items: flex-start;
  background: var(--blue-50);
  border: 1px solid #e0e8f5;
  border-radius: var(--radius-md);
  display: flex;
  gap: 13px;
  min-height: 128px;
  padding: 18px;
}

.notice-grid article > span {
  color: var(--blue-700);
  font-size: 12px;
  font-weight: 900;
  padding-top: 2px;
}

.notice-grid strong {
  color: var(--blue-950);
  display: block;
  margin-bottom: 6px;
}

.notice-grid p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
  margin: 0;
}

.consent-row {
  align-items: flex-start;
  background: var(--warm);
  border: 1px solid var(--warm-line);
  border-radius: var(--radius-md);
  cursor: pointer;
  display: flex;
  gap: 12px;
  line-height: 1.65;
  margin-top: 22px;
  padding: 17px;
}

.consent-row input {
  flex: 0 0 auto;
  height: 20px;
  margin: 2px 0 0;
  width: 20px;
}

.document-grid {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.document-card {
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  color: var(--ink);
  min-height: 170px;
  padding: 19px;
  position: relative;
  text-align: left;
}

button.document-card {
  cursor: pointer;
}

.document-card.is-selected {
  background: var(--blue-50);
  border-color: var(--blue-700);
  box-shadow: inset 0 0 0 1px var(--blue-700);
}

.document-card.is-locked {
  background: #fafbfc;
  color: #7d8798;
}

.document-icon {
  align-items: center;
  background: var(--blue-100);
  border-radius: 12px;
  color: var(--blue-800);
  display: flex;
  font-weight: 900;
  height: 42px;
  justify-content: center;
  margin-bottom: 19px;
  width: 42px;
}

.document-card.is-locked .document-icon {
  background: #edf0f3;
  color: #818a98;
}

.document-state {
  border: 1px solid #c7daf3;
  border-radius: 999px;
  color: var(--blue-700);
  font-size: 11px;
  font-weight: 800;
  padding: 4px 8px;
  position: absolute;
  right: 14px;
  top: 14px;
}

.is-locked .document-state {
  border-color: #d8dde4;
  color: #8a93a0;
}

.document-card strong,
.document-card small {
  display: block;
}

.document-card strong {
  font-size: 17px;
  margin-bottom: 7px;
}

.document-card small {
  line-height: 1.6;
}

fieldset {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 0 0 30px;
  padding: 26px 0 0;
}

fieldset:first-child {
  border-top: 0;
  padding-top: 0;
}

legend {
  align-items: center;
  color: var(--blue-950);
  display: flex;
  font-size: 18px;
  font-weight: 800;
  gap: 10px;
  margin-bottom: 18px;
  padding: 0;
  width: 100%;
}

legend span {
  color: var(--blue-700);
  font-size: 12px;
}

.form-grid {
  display: grid;
  gap: 17px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.field {
  display: block;
}

.field--wide {
  grid-column: 1 / -1;
}

.field > span {
  color: #354156;
  display: block;
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 8px;
}

.field b {
  color: var(--danger);
}

.field input,
.field select,
.field textarea,
.followup-field input,
.followup-field select,
.followup-field textarea {
  background: white;
  border: 1px solid #cfd8e5;
  border-radius: var(--radius-sm);
  color: var(--ink);
  min-height: 48px;
  padding: 11px 13px;
  width: 100%;
}

.field textarea,
.followup-field textarea {
  line-height: 1.7;
  min-height: 140px;
  resize: vertical;
}

.field input:focus,
.field select:focus,
.field textarea:focus,
.followup-field input:focus,
.followup-field select:focus,
.followup-field textarea:focus {
  border-color: var(--blue-700);
}

.field small,
.field-help {
  color: var(--muted);
  display: block;
  font-size: 12px;
  line-height: 1.65;
  margin: 7px 0 13px;
}

.choice-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.choice-grid label,
.compact-choices label {
  align-items: flex-start;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: flex;
  gap: 10px;
  padding: 13px;
}

.choice-grid label:has(input:checked),
.compact-choices label:has(input:checked) {
  background: var(--blue-50);
  border-color: var(--blue-700);
}

.choice-grid input,
.compact-choices input {
  flex: 0 0 auto;
  height: 18px;
  margin: 2px 0 0;
  width: 18px;
}

.choice-grid strong,
.choice-grid small {
  display: block;
}

.choice-grid small {
  color: var(--muted);
  line-height: 1.5;
  margin-top: 3px;
}

.compact-choices {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.compact-choices label {
  font-size: 13px;
  padding: 10px 12px;
}

.calculation-link {
  align-items: center;
  background: linear-gradient(135deg, var(--blue-50), #f9fbff);
  border: 1px solid #cfdef1;
  border-radius: var(--radius-md);
  display: grid;
  gap: 16px;
  grid-template-columns: minmax(0, 1fr) auto;
  padding: 20px;
}

.calculation-link h3,
.calculation-link p {
  margin: 0;
}

.calculation-link h3 {
  color: var(--blue-950);
  margin-bottom: 7px;
}

.calculation-link p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.calculation-transfer {
  align-items: center;
  background: white;
  border: 1px solid #bbd0ea;
  border-radius: var(--radius-sm);
  display: grid;
  gap: 4px 12px;
  grid-column: 1 / -1;
  grid-template-columns: auto 1fr auto;
  padding: 14px;
}

.calculation-transfer > span {
  background: #e7f7f0;
  border-radius: 999px;
  color: var(--success);
  font-size: 11px;
  font-weight: 800;
  padding: 4px 8px;
}

.calculation-transfer p {
  grid-column: 2 / 3;
}

.calculation-transfer button {
  background: transparent;
  border: 0;
  color: var(--danger);
  cursor: pointer;
  grid-column: 3;
  grid-row: 1 / 3;
}

.question-summary {
  background: var(--blue-50);
  border: 1px solid #d6e2f2;
  border-radius: var(--radius-md);
  color: var(--blue-950);
  line-height: 1.7;
  margin-bottom: 18px;
  padding: 16px 18px;
}

.question-summary strong {
  display: block;
}

.question-summary p {
  color: var(--muted);
  font-size: 13px;
  margin: 3px 0 0;
}

.followup-list {
  display: grid;
  gap: 12px;
}

.followup-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 18px;
}

.followup-card header {
  align-items: flex-start;
  display: flex;
  gap: 11px;
  margin-bottom: 14px;
}

.followup-card header span {
  align-items: center;
  background: var(--blue-100);
  border-radius: 50%;
  color: var(--blue-800);
  display: flex;
  flex: 0 0 auto;
  font-size: 12px;
  font-weight: 900;
  height: 28px;
  justify-content: center;
  width: 28px;
}

.followup-card h3,
.followup-card p {
  margin: 0;
}

.followup-card h3 {
  color: var(--blue-950);
  font-size: 15px;
  line-height: 1.55;
}

.followup-card p {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
  margin-top: 3px;
}

.followup-field > span {
  display: block;
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 7px;
}

.form-error {
  color: var(--danger);
  font-size: 13px;
  line-height: 1.6;
  min-height: 20px;
}

.step-actions {
  align-items: center;
  border-top: 1px solid var(--line);
  display: flex;
  gap: 10px;
  justify-content: space-between;
  margin-top: 30px;
  padding-top: 22px;
}

.step-actions--end {
  justify-content: flex-end;
}

.step-actions--wrap {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.button {
  align-items: center;
  border-radius: 12px;
  cursor: pointer;
  display: inline-flex;
  font-weight: 800;
  justify-content: center;
  min-height: 46px;
  padding: 11px 18px;
  text-decoration: none;
}

.button:disabled {
  cursor: not-allowed;
  opacity: 0.48;
}

.button-primary {
  background: var(--blue-700);
  border: 1px solid var(--blue-700);
  color: white;
}

.button-primary:hover:not(:disabled) {
  background: var(--blue-800);
}

.button-secondary {
  background: white;
  border: 1px solid #bdc9d8;
  color: #3a4b65;
}

.delivery-head {
  align-items: start;
  display: flex;
  gap: 20px;
  justify-content: space-between;
}

.delivery-head h2,
.delivery-head p {
  margin: 0;
}

.delivery-head p {
  color: var(--muted);
  line-height: 1.7;
  margin-top: 8px;
}

.watermark-pill {
  background: #fff0ee;
  border: 1px solid #efc5c0;
  border-radius: 999px;
  color: var(--danger);
  flex: 0 0 auto;
  font-size: 12px;
  font-weight: 800;
  padding: 7px 11px;
}

.delivery-tabs {
  border-bottom: 1px solid var(--line);
  display: flex;
  gap: 3px;
  margin: 26px 0 20px;
}

.delivery-tabs button {
  background: transparent;
  border: 0;
  border-bottom: 3px solid transparent;
  color: var(--muted);
  cursor: pointer;
  font-weight: 800;
  padding: 11px 15px;
}

.delivery-tabs button.is-active {
  border-bottom-color: var(--blue-700);
  color: var(--blue-800);
}

.document-preview {
  background: #fffefb;
  border: 1px solid #ddd8cc;
  box-shadow: 0 12px 28px rgba(50, 45, 34, 0.08);
  margin: 0 auto;
  max-width: 820px;
  min-height: 920px;
  padding: clamp(26px, 6vw, 68px);
  position: relative;
}

.document-preview::before {
  color: rgba(180, 60, 53, 0.11);
  content: "法律候选 · 不可提交";
  font-size: clamp(28px, 5vw, 50px);
  font-weight: 900;
  left: 50%;
  letter-spacing: 0.08em;
  position: absolute;
  top: 42%;
  transform: translate(-50%, -50%) rotate(-25deg);
  white-space: nowrap;
}

.document-preview h1 {
  color: #171717;
  font-family: SimSun, "Songti SC", serif;
  font-size: 26px;
  letter-spacing: 0.18em;
  margin: 0 0 34px;
  text-align: center;
}

.document-preview h2 {
  color: #171717;
  font-family: SimSun, "Songti SC", serif;
  font-size: 17px;
  margin: 24px 0 10px;
}

.document-preview p,
.document-preview li {
  color: #222;
  font-family: SimSun, "Songti SC", serif;
  font-size: 16px;
  line-height: 2;
  position: relative;
}

.document-preview p {
  margin: 6px 0;
}

.document-preview .fact-paragraph {
  text-align: justify;
  text-indent: 2em;
}

.document-preview ol,
.document-preview ul {
  padding-left: 1.5em;
}

.document-preview .draft-meta {
  color: var(--danger);
  font-family: inherit;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.6;
  text-align: center;
}

.document-preview .signature-block {
  margin-left: auto;
  margin-top: 36px;
  width: min(330px, 70%);
}

.request-review {
  background: #fff8e7;
  border-left: 3px solid #e4a72d;
  color: #76591e;
  display: block;
  font-family: system-ui, "Microsoft YaHei", sans-serif;
  font-size: 12px;
  line-height: 1.65;
  margin: 7px 0 13px;
  padding: 7px 10px;
}

.process-preview,
.checklist-preview,
.legal-basis-preview,
.evidence-catalog-preview {
  display: grid;
  gap: 14px;
}

.evidence-catalog-head,
.evidence-gaps {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 18px;
}

.evidence-catalog-head h2,
.evidence-gaps h3 {
  color: var(--blue-950);
  margin: 0 0 8px;
}

.evidence-catalog-head p,
.evidence-gaps p,
.evidence-gaps li {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.evidence-table-wrap {
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  overflow-x: auto;
}

.evidence-table {
  background: #fff;
  border-collapse: collapse;
  min-width: 780px;
  table-layout: fixed;
  width: 100%;
}

.evidence-table th,
.evidence-table td {
  border-bottom: 1px solid var(--line);
  border-right: 1px solid var(--line);
  color: #253247;
  font-size: 13px;
  line-height: 1.6;
  padding: 12px;
  vertical-align: middle;
}

.evidence-table th {
  background: var(--blue-50);
  color: var(--blue-950);
  font-weight: 800;
  text-align: left;
}

.evidence-table th:first-child,
.evidence-table td:first-child {
  text-align: center;
  width: 52px;
}

.evidence-table th:nth-child(2) {
  width: 23%;
}

.evidence-table th:nth-child(4) {
  width: 25%;
}

.evidence-table th:last-child,
.evidence-table td:last-child {
  border-right: 0;
}

.evidence-table tbody tr:last-child td {
  border-bottom: 0;
}

.evidence-table small {
  color: var(--muted);
  display: block;
  margin-top: 5px;
}

.legal-profile-summary,
.legal-gate-card,
.legal-source-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 18px;
}

.legal-profile-summary {
  background: linear-gradient(135deg, var(--blue-50), #f7fbff);
  border-color: #cfddec;
}

.legal-profile-summary p,
.legal-gate-card p,
.legal-source-card p,
.legal-source-card li {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.legal-profile-summary p,
.legal-gate-card p,
.legal-source-card p,
.legal-source-card ul {
  margin-bottom: 0;
}

.legal-gate-grid {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.legal-gate-card h3,
.legal-source-card h3 {
  color: var(--blue-950);
  font-size: 16px;
  margin: 0 0 8px;
}

.legal-source-list {
  display: grid;
  gap: 12px;
}

.legal-source-card header {
  align-items: flex-start;
  display: flex;
  gap: 18px;
  justify-content: space-between;
}

.legal-source-card a {
  color: var(--blue-700);
  flex: 0 0 auto;
  font-size: 13px;
  font-weight: 800;
}

.legal-source-card ul {
  padding-left: 20px;
}

.audit-card {
  background: var(--blue-50);
  border: 1px solid #d8e3f1;
  border-radius: var(--radius-md);
  padding: 18px;
}

.audit-card h3 {
  color: var(--blue-950);
  font-size: 16px;
  margin: 0 0 9px;
}

.audit-card p,
.audit-card li {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.audit-card p,
.audit-card ul,
.audit-card ol {
  margin-bottom: 0;
}

.audit-card ul,
.audit-card ol {
  padding-left: 20px;
}

.check-row {
  align-items: flex-start;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  display: flex;
  gap: 11px;
  padding: 14px;
}

.check-row span {
  align-items: center;
  background: #fff0ee;
  border-radius: 50%;
  color: var(--danger);
  display: flex;
  flex: 0 0 auto;
  font-size: 12px;
  font-weight: 900;
  height: 25px;
  justify-content: center;
  width: 25px;
}

.check-row strong,
.check-row small {
  display: block;
}

.check-row small {
  color: var(--muted);
  line-height: 1.6;
  margin-top: 3px;
}

.delivery-warning {
  background: var(--warm);
  border: 1px solid var(--warm-line);
  border-radius: var(--radius-md);
  margin-top: 20px;
  padding: 15px 17px;
}

.delivery-warning strong {
  color: #765021;
}

.delivery-warning p {
  color: #876b46;
  font-size: 13px;
  line-height: 1.7;
  margin: 4px 0 0;
}

.runtime-delivery-action {
  background: var(--blue-50);
  border: 1px solid #bcd0eb;
  border-radius: var(--radius-md);
  display: grid;
  gap: 14px;
  margin-top: 20px;
  padding: 18px;
}

.runtime-delivery-action h3,
.runtime-delivery-action p {
  margin: 0;
}

.runtime-delivery-action p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.consent-row--compact {
  margin: 0;
  padding: 13px;
}

.runtime-delivery-action > .button {
  justify-self: end;
}

.export-status {
  color: var(--success);
  font-size: 13px;
  min-height: 20px;
  text-align: right;
}

footer {
  align-items: center;
  background: var(--blue-950);
  color: rgba(255, 255, 255, 0.78);
  display: flex;
  gap: 16px;
  justify-content: center;
  min-height: 90px;
  padding: 24px;
  text-align: center;
}

footer strong {
  color: white;
}

@media (max-width: 900px) {
  .site-header {
    grid-template-columns: 1fr auto;
  }

  .header-copy {
    display: none;
  }

  .hero {
    align-items: stretch;
    grid-template-columns: 1fr;
  }

  .hero-status {
    max-width: 420px;
  }

  .candidate-access {
    grid-template-columns: 1fr;
  }

  .workspace {
    grid-template-columns: 1fr;
  }

  .stepper {
    overflow-x: auto;
    padding: 12px;
    position: static;
  }

  .stepper ol {
    display: grid;
    gap: 7px;
    grid-template-columns: repeat(5, minmax(105px, 1fr));
    min-width: 620px;
  }

  .stepper li {
    gap: 7px;
    grid-template-columns: 30px 1fr;
    min-height: 50px;
  }

  .stepper li > span {
    height: 30px;
    width: 30px;
  }

  .stepper li::after {
    display: none;
  }

  .stepper-boundary {
    display: none;
  }
}

@media (max-width: 640px) {
  .site-header {
    min-height: 58px;
    padding: 0 16px;
  }

  .brand strong {
    font-size: 14px;
  }

  .header-reset {
    font-size: 13px;
  }

  main {
    padding: 30px 12px calc(54px + env(safe-area-inset-bottom));
  }

  .hero h1 {
    font-size: 34px;
  }

  .hero p {
    font-size: 15px;
    line-height: 1.75;
  }

  .privacy-strip {
    margin-top: 24px;
    padding: 14px;
  }

  .candidate-access {
    border-radius: 18px;
    margin-top: 22px;
    padding: 18px 15px;
  }

  .candidate-access__form > div {
    grid-template-columns: 1fr;
  }

  .candidate-access__form .button,
  .candidate-session .button,
  .runtime-delivery-action > .button {
    min-height: 48px;
    width: 100%;
  }

  .stepper {
    overflow-x: visible;
    padding: 9px 6px;
  }

  .stepper ol {
    gap: 2px;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    min-width: 0;
  }

  .stepper li {
    align-items: center;
    display: flex;
    flex-direction: column;
    gap: 5px;
    justify-content: flex-start;
    min-height: 66px;
    min-width: 0;
    padding: 4px 1px;
    text-align: center;
  }

  .stepper li > span {
    flex: 0 0 auto;
    height: 28px;
    width: 28px;
  }

  .stepper li div {
    min-width: 0;
  }

  .stepper li strong {
    font-size: 11px;
    line-height: 1.25;
  }

  .stepper li small {
    display: none;
  }

  .panel {
    border-radius: 18px;
    min-height: 0;
    padding: 23px 16px;
  }

  .notice-grid,
  .document-grid,
  .form-grid,
  .choice-grid {
    grid-template-columns: 1fr;
  }

  .notice-grid article {
    min-height: 0;
  }

  .document-card {
    min-height: 144px;
  }

  .calculation-link {
    grid-template-columns: 1fr;
  }

  .calculation-link .button {
    width: 100%;
  }

  .calculation-transfer {
    grid-template-columns: auto 1fr;
  }

  .calculation-transfer p {
    grid-column: 1 / -1;
  }

  .calculation-transfer button {
    grid-column: 2;
    grid-row: 1;
    justify-self: end;
  }

  .step-actions,
  .step-actions--end,
  .step-actions--wrap {
    align-items: stretch;
    flex-direction: column-reverse;
  }

  .step-actions .button {
    min-height: 50px;
    width: 100%;
  }

  .delivery-head {
    display: block;
  }

  .watermark-pill {
    display: inline-block;
    margin-top: 13px;
  }

  .delivery-tabs {
    overflow-x: auto;
  }

  .delivery-tabs button {
    flex: 1 0 auto;
  }

  .document-preview {
    min-height: 680px;
    padding: 32px 21px;
  }

  .document-preview h1 {
    font-size: 21px;
  }

  .document-preview p,
  .document-preview li {
    font-size: 15px;
    line-height: 1.9;
  }

  .document-preview .signature-block {
    width: 82%;
  }

  .legal-gate-grid {
    grid-template-columns: 1fr;
  }

  .legal-source-card header {
    display: block;
  }

  .legal-source-card a {
    display: inline-block;
    margin-top: 8px;
  }

  footer {
    align-items: center;
    flex-direction: column;
    font-size: 12px;
  }
}

@media print {
  body {
    background: white;
  }

  .site-header,
  .hero,
  .candidate-access,
  .privacy-strip,
  .stepper,
  .step-kicker,
  .delivery-head,
  .delivery-tabs,
  .delivery-warning,
  .runtime-delivery-action,
  .step-actions,
  .export-status,
  footer {
    display: none !important;
  }

  main,
  .workspace,
  .panel {
    display: block;
    margin: 0;
    max-width: none;
    padding: 0;
  }

  .panel,
  .document-preview {
    border: 0;
    box-shadow: none;
  }

  .step-view:not([data-step-view="5"]),
  [data-delivery-panel]:not([data-delivery-panel="document"]) {
    display: none !important;
  }

  [data-step-view="5"],
  [data-delivery-panel="document"] {
    display: block !important;
  }

  .document-preview {
    max-width: none;
    min-height: 0;
    padding: 18mm 16mm;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}
