:root {
  --navy-950: #061521;
  --navy-900: #0a1b29;
  --navy-850: #0f2333;
  --navy-800: #142a3b;
  --cream-50: #fbf6ec;
  --cream-100: #f5ecdc;
  --cream-150: #efe3cf;
  --paper: #fbf5e9;
  --ink: #172a38;
  --ink-soft: #3f5260;
  --muted: #6e7b84;
  --gold: #c7a66c;
  --gold-deep: #8f6b32;
  --gold-soft: rgba(181, 143, 78, .14);
  --line: rgba(27, 48, 63, .14);
  --line-strong: rgba(27, 48, 63, .23);
  --white-line: rgba(255, 255, 255, .1);
  --success: #39745c;
  --danger: #9b4e45;
  --warning: #99713c;
  --radius: 8px;
  --control-radius: 4px;
  --control-border: rgba(32, 55, 70, .44);
  --control-border-hover: rgba(128, 92, 40, .72);
  --control-surface: #ffffff;
  --control-shadow: 0 1px 2px rgba(25, 45, 58, .055), inset 0 1px 0 rgba(255, 255, 255, .92);
  --focus-ring: 0 0 0 3px rgba(181, 143, 78, .16);
  --helper-text: 13px;
  --shadow: 0 24px 70px rgba(0, 8, 16, .23);
  --serif: "Songti SC", "STSong", "Noto Serif SC", "Source Han Serif SC", Georgia, serif;
  --sans: "Microsoft YaHei UI", "Microsoft YaHei", "PingFang SC", "Noto Sans SC", sans-serif;
  --mono: "Cascadia Mono", "SFMono-Regular", Consolas, monospace;
}

* { box-sizing: border-box; }

html { min-width: 320px; background: var(--navy-950); }

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  background:
    radial-gradient(circle at 74% 22%, rgba(48, 94, 120, .16), transparent 38%),
    radial-gradient(circle at 16% 74%, rgba(143, 107, 50, .07), transparent 32%),
    linear-gradient(135deg, #081925 0%, #061521 48%, #081b29 100%);
  color: #eef1ed;
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

button, input, textarea { font: inherit; }
button { color: inherit; }
button, summary { -webkit-tap-highlight-color: transparent; }

button:focus-visible,
input:focus-visible,
summary:focus-visible,
a:focus-visible {
  outline: 2px solid rgba(190, 149, 80, .72);
  outline-offset: 2px;
}

[hidden] { display: none !important; }

.page { position: relative; min-height: 100vh; overflow: hidden; }

.ambient {
  position: fixed;
  z-index: 0;
  border-radius: 50%;
  pointer-events: none;
  filter: blur(2px);
}

.ambient-a {
  top: -260px;
  right: -180px;
  width: 720px;
  height: 720px;
  background: radial-gradient(circle, rgba(81, 139, 168, .1), transparent 67%);
}

.ambient-b {
  bottom: -340px;
  left: -240px;
  width: 780px;
  height: 780px;
  background: radial-gradient(circle, rgba(194, 157, 95, .075), transparent 69%);
}

.topbar {
  position: relative;
  z-index: 10;
  border-bottom: 1px solid var(--white-line);
  background: rgba(6, 21, 33, .42);
  backdrop-filter: blur(12px);
}

.topbar-inner {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto;
  align-items: center;
  width: min(1600px, calc(100% - 64px));
  height: 86px;
  margin: 0 auto;
}

.brand {
  display: inline-flex;
  align-items: center;
  justify-self: start;
  gap: 13px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #d9d9d1;
  cursor: pointer;
  text-align: left;
}

.brand-mark {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 44px;
  height: 44px;
  color: var(--gold);
}

.brand-mark svg { width: 100%; height: 100%; }
.brand-copy { display: flex; flex-direction: column; gap: 2px; }
.brand-name { color: #f4f1e9; font-family: var(--serif); font-size: 19px; font-weight: 700; letter-spacing: .02em; }
.brand-name b { margin-left: 2px; color: #dedbd2; font-family: var(--sans); font-size: 14px; font-weight: 600; letter-spacing: .12em; }
.brand-sub { color: rgba(228, 231, 225, .54); font-size: 12.5px; letter-spacing: .08em; }


.topbar-actions {
  display: flex;
  align-items: center;
  justify-self: end;
  gap: 10px;
}

.engine-status {
  display: inline-flex;
  align-items: center;
  justify-self: end;
  gap: 8px;
  min-height: 38px;
  padding: 0 15px;
  border: 1px solid rgba(222, 201, 159, .2);
  border-radius: 999px;
  background: rgba(255, 255, 255, .018);
  color: rgba(234, 236, 231, .58);
  font-size: 12.5px;
  white-space: nowrap;
}

.engine-status b { color: rgba(241, 236, 226, .83); font-weight: 500; }
.status-dot { width: 6px; height: 6px; border-radius: 50%; background: #b58b63; box-shadow: 0 0 0 4px rgba(181, 139, 99, .08); }
.engine-status.is-online .status-dot { background: #75c69e; box-shadow: 0 0 0 4px rgba(117, 198, 158, .11); }
.engine-status.is-offline .status-dot { background: #b58b63; }

.topbar-new-research {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  height: 40px;
  padding: 0 16px;
  border: 1px solid #e0c791;
  border-radius: 4px;
  background: linear-gradient(180deg, #ddc58f 0%, #c9a96b 100%);
  box-shadow: 0 5px 14px rgba(0, 7, 12, .24), inset 0 1px 0 rgba(255, 255, 255, .36);
  color: #102b3a;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .02em;
  white-space: nowrap;
  cursor: pointer;
  transition: border-color .16s ease, background .16s ease, color .16s ease, box-shadow .16s ease, transform .16s ease;
}
.topbar-new-research svg {
  width: 15px;
  height: 15px;
  flex: 0 0 auto;
  color: #153747;
}
.topbar-new-research:hover {
  border-color: #f0ddb3;
  background: linear-gradient(180deg, #e7d29f 0%, #d3b476 100%);
  box-shadow: 0 7px 18px rgba(0, 7, 12, .3), inset 0 1px 0 rgba(255, 255, 255, .44);
  color: #081f2b;
  transform: translateY(-1px);
}
.topbar-new-research:active { transform: translateY(0); }
.topbar-new-research:focus-visible {
  outline: 2px solid rgba(235, 211, 165, .9);
  outline-offset: 2px;
}

.auth-chip {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 40px;
  padding: 4px 5px 4px 5px;
  border: 1px solid rgba(222, 201, 159, .18);
  border-radius: 999px;
  background: rgba(255, 255, 255, .025);
  white-space: nowrap;
}
.auth-avatar {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 1px solid rgba(229, 207, 164, .28);
  border-radius: 50%;
  background: linear-gradient(145deg, rgba(221, 192, 137, .24), rgba(126, 97, 53, .13));
  color: #e9d7ae;
  font-family: var(--serif);
  font-size: 13px;
  font-weight: 700;
}
.auth-copy {
  display: flex;
  min-width: 0;
  max-width: 130px;
  flex-direction: column;
  gap: 1px;
  line-height: 1.2;
}
.auth-copy strong {
  overflow: hidden;
  color: rgba(245, 241, 232, .9);
  font-size: 12px;
  font-weight: 600;
  text-overflow: ellipsis;
}
.auth-copy small {
  color: rgba(225, 228, 221, .48);
  font-size: 10px;
  letter-spacing: .04em;
}
.auth-logout {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-width: 30px;
  height: 30px;
  padding: 0 10px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: rgba(235, 230, 220, .58);
  font-size: 11px;
  cursor: pointer;
  transition: background .16s ease, color .16s ease, border-color .16s ease;
}
.auth-logout svg { width: 14px; height: 14px; flex: 0 0 auto; }
.auth-logout:hover:not(:disabled) {
  border-color: rgba(222, 201, 159, .18);
  background: rgba(255, 255, 255, .06);
  color: #f2e8d3;
}
.auth-logout:disabled { cursor: wait; opacity: .55; }
.auth-logout:focus-visible {
  outline: 2px solid rgba(235, 211, 165, .9);
  outline-offset: 2px;
}

.workspace-shell { position: relative; z-index: 1; width: min(1600px, calc(100% - 64px)); margin: 0 auto; padding: 42px 0 64px; }
.workspace-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; align-items: start; gap: 28px; }
.main-column { min-width: 0; }

.research-panel {
  min-height: 0;
  padding: 28px 36px 24px;
  border: 1px solid rgba(205, 186, 151, .4);
  border-radius: var(--radius);
  background: linear-gradient(125deg, rgba(255, 255, 255, .28), transparent 36%), var(--paper);
  box-shadow: var(--shadow);
  color: var(--ink);
}

.panel-topline, .run-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 32px; }
.panel-heading { min-width: 0; }

.eyebrow {
  display: block;
  margin-bottom: 7px;
  color: var(--gold-deep);
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: .15em;
  line-height: 1.2;
  text-transform: uppercase;
}

h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 0; color: #122635; font-family: var(--serif); font-size: 24px; font-weight: 700; line-height: 1.25; letter-spacing: .01em; }
.panel-intro { max-width: 720px; margin: 11px 0 24px; color: var(--ink-soft); font-size: 13.5px; }

.flow-progress { display: flex; align-items: center; gap: 8px; margin: 3px 0 0; padding: 0; list-style: none; white-space: nowrap; }
.flow-progress li { display: flex; align-items: center; gap: 5px; color: rgba(41, 61, 74, .38); font-size: 12.5px; }
.flow-progress li:not(:last-child)::after { width: 30px; height: 1px; margin: 0 3px; background: rgba(41, 61, 74, .14); content: ""; }
.flow-progress b { font-family: var(--mono); font-size: 12px; font-weight: 500; }
.flow-progress li.is-active, .flow-progress li.is-complete { color: var(--gold-deep); }
.flow-progress li.is-active b { font-weight: 700; }

.intake-fields { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(230px, .65fr); align-items: start; gap: 20px; }
.brand-field { min-width: 0; }
.brand-field > label, .field-label-row label { display: block; margin-bottom: 7px; color: var(--ink); font-size: 13.5px; font-weight: 600; }

.brand-input-shell,
.region-field input,
.profile-item-input,
.inline-add input {
  border: 1px solid var(--control-border);
  border-radius: var(--control-radius);
  background: var(--control-surface);
  box-shadow: var(--control-shadow);
  transition: border-color .18s ease, background .18s ease, box-shadow .18s ease;
}

.brand-input-shell,
.region-field input { height: 48px; }

.brand-input-shell { display: flex; align-items: center; padding: 0 16px; }
.brand-input-shell:hover,
.region-field input:hover { border-color: rgba(37, 59, 74, .4); }
.brand-input-shell:focus-within,
.region-field input:focus,
.profile-item-input:focus,
.inline-add input:focus { border-color: var(--control-border-hover); background: #ffffff; box-shadow: var(--focus-ring), inset 0 1px 0 rgba(255, 255, 255, .95); }
.field-icon { display: inline-flex; flex: 0 0 auto; width: 17px; height: 17px; margin-right: 11px; color: rgba(26, 48, 64, .46); }
.field-icon svg { width: 100%; height: 100%; }

.brand-input-shell input {
  width: 100%;
  min-width: 0;
  height: 40px;
  padding: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: #192d3d;
  font-size: 15.5px;
  font-weight: 500;
  letter-spacing: .005em;
}

.brand-input-shell input::placeholder { color: rgba(23, 42, 56, .4); font-weight: 400; }
.field-error { display: block; color: var(--danger); font-size: 12px; }
.field-error:not(:empty) { padding-top: 5px; }
.field-label-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 7px; }
.field-label-row label { margin: 0; }
.field-label-row span { color: rgba(48, 68, 81, .68); font-size: var(--helper-text); }

.region-field input {
  width: 100%;
  padding: 0 14px;
  outline: 0;
  color: var(--ink);
  font-size: 14.5px;
}

.region-field input::placeholder { color: rgba(23, 42, 56, .4); }

.ui-note,
.field-label-row span,
.run-summary-copy p,
.stage-pending-copy,
.stage-running-copy,
.stage-note,
.collection-action-note,
.collection-export-label,
.source-verification-note,
.confirm-copy,
.report-dialog-subtitle {
  color: rgba(48, 68, 81, .68);
  font-size: var(--helper-text);
  line-height: 1.55;
}

.form-actions { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--line); }
.form-actions .primary-button { min-height: 40px; padding: 0 17px; font-size: 13px; }
.deliverable-strip { display: flex; flex-wrap: wrap; gap: 16px; color: rgba(48, 68, 81, .68); font-size: var(--helper-text); }
.deliverable-strip span, .run-meta span, .model-chip { display: inline-flex; align-items: center; gap: 6px; }
.dot { width: 5px; height: 5px; border-radius: 50%; background: rgba(55, 78, 93, .36); }
.dot.gold { background: var(--gold); }

.primary-button,
.secondary-button,
.text-button,
.collection-action,
.evidence-expand,
.evidence-toggle,
.tiny-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border-radius: var(--control-radius);
  font-size: 13px;
  font-weight: 500;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: transform .16s ease, background .16s ease, border-color .16s ease, color .16s ease, box-shadow .16s ease, opacity .16s ease;
}

.primary-button {
  min-height: 40px;
  padding: 0 17px;
  border: 1px solid #233b4d;
  background: #1a3141;
  box-shadow: 0 3px 10px rgba(16, 35, 49, .11);
  color: #f7f2e8;
  font-weight: 600;
}

.primary-button svg { width: 14px; height: 14px; }
.primary-button:hover:not(:disabled) { transform: translateY(-1px); border-color: #142a39; background: #142a39; box-shadow: 0 5px 14px rgba(16, 35, 49, .17); }
.primary-button:active:not(:disabled),
.secondary-button:active:not(:disabled),
.collection-action:active:not(:disabled),
.evidence-expand:active:not(:disabled),
.evidence-toggle:active:not(:disabled) { transform: translateY(1px); }
.primary-button:disabled, .secondary-button:disabled, .collection-action:disabled { cursor: wait; opacity: .58; }
.primary-button.compact, .secondary-button.compact { min-height: 36px; padding: 0 12px; font-size: 13px; }
.secondary-button,
.text-button {
  min-height: 38px;
  padding: 0 13px;
  border: 1px solid var(--control-border);
  background: var(--control-surface);
  box-shadow: 0 1px 1px rgba(25, 45, 58, .025);
  color: #38515f;
}
.secondary-button:hover:not(:disabled),
.text-button:hover:not(:disabled) { border-color: var(--control-border-hover); background: #ffffff; color: #253e4c; }
.text-button { white-space: nowrap; }

.icon-button { display: grid; place-items: center; width: 32px; height: 32px; padding: 0; border: 1px solid transparent; border-radius: var(--control-radius); background: transparent; color: inherit; font-size: 17px; cursor: pointer; transition: background .16s ease, border-color .16s ease, color .16s ease; }
.icon-button:hover { border-color: rgba(39, 59, 73, .14); background: rgba(39, 59, 73, .07); }

.alert-banner { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; margin-bottom: 16px; padding: 14px 16px; border: 1px solid rgba(159, 75, 64, .32); border-radius: 4px; background: rgba(111, 38, 31, .24); color: #f1ded9; backdrop-filter: blur(8px); }
.alert-copy { display: flex; flex-direction: column; gap: 2px; }
.alert-copy strong { font-size: 13.5px; font-weight: 600; }
.alert-copy span { color: rgba(241, 222, 217, .78); font-size: 13px; }
.alert-banner .icon-button { flex: 0 0 auto; margin: -2px -4px 0 0; }

/* Inline profile */
.profile-section {
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--line-strong);
}
.profile-inline-head { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.profile-inline-head .eyebrow { margin-bottom: 5px; }
.profile-inline-caption { display: block; }
.profile-inline-head-actions { display: flex; align-items: center; gap: 10px; white-space: nowrap; }
.profile-edit-button { min-width: 108px; }

.profile-building, .profile-build-error {
  display: flex;
  align-items: center;
  gap: 13px;
  margin-top: 20px;
  padding: 14px 16px;
  border: 1px solid rgba(159, 134, 91, .24);
  background: rgba(193, 161, 105, .065);
}
.profile-building > div, .profile-build-error > div { display: flex; min-width: 0; flex-direction: column; gap: 2px; }
.profile-building strong, .profile-build-error strong { color: #354b59; font-size: 14px; font-weight: 600; }
.profile-building > div > span, .profile-build-error > div > span { color: rgba(55, 75, 88, .58); font-size: 13px; line-height: 1.55; }
.profile-building .spinner { width: 16px; height: 16px; }
.profile-build-error { justify-content: space-between; border-color: rgba(155, 78, 69, .22); border-left: 2px solid rgba(155, 78, 69, .55); background: rgba(155, 78, 69, .045); }
.profile-build-error strong { color: #74433c; }
.profile-build-error button { flex: 0 0 auto; }

#researchForm.is-locked .brand-input-shell,
#researchForm.is-locked .region-field input {
  border-color: rgba(46, 70, 86, .14);
  background: rgba(255, 255, 255, .24);
  box-shadow: none;
}
#researchForm.is-locked input { cursor: default; }
#researchForm.is-locked .auto-profile-note,
#researchForm.is-locked .form-actions { display: none; }

/* Profile */
.profile-lead { display: flex; align-items: flex-start; justify-content: space-between; gap: 30px; margin: 20px 0 22px; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.profile-name-row { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; }
.profile-name-row h2 { margin: 0; color: #1b3040; font-family: var(--serif); font-size: 20px; }
.confidence-badge, .run-status, .stage-status { display: inline-flex; align-items: center; justify-content: center; min-height: 24px; padding: 0 8px; border: 1px solid rgba(143, 107, 50, .25); background: rgba(181, 143, 78, .08); color: #775b30; font-size: 12.5px; font-weight: 600; white-space: nowrap; }
.profile-tags { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 9px; }
.profile-tag { display: inline-flex; align-items: center; min-height: 25px; padding: 0 8px; border: 1px solid rgba(64, 85, 99, .16); background: rgba(255, 255, 255, .28); color: #596b77; font-size: 12.5px; }
.profile-evidence { display: flex; max-width: 260px; flex: 0 0 auto; flex-direction: column; align-items: flex-end; gap: 4px; padding-top: 4px; color: rgba(55, 75, 88, .58); font-size: 12.5px; text-align: right; }
.profile-evidence a { color: #70552f; text-decoration: none; }
.profile-evidence a:hover { text-decoration: underline; }

.profile-overview { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; overflow: hidden; border: 1px solid var(--line); background: var(--line); }
.profile-fact { min-height: 68px; padding: 12px 14px; background: rgba(255, 255, 255, .25); }
.profile-fact span { display: block; margin-bottom: 3px; color: rgba(55, 75, 88, .5); font-size: 12.5px; }
.profile-fact strong { display: block; overflow: hidden; color: #304653; font-size: 14px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.profile-positioning { margin: 16px 0 0; padding-left: 12px; border-left: 2px solid rgba(183, 143, 77, .55); color: #405563; font-size: 14px; line-height: 1.7; }
.profile-columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px; margin-top: 26px; }
.profile-group { min-width: 0; }
.profile-group-head { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 11px; }
.profile-group-head h2 { margin: 0; color: #243b4a; font-family: var(--serif); font-size: 17px; }
.profile-group-head > div > span { display: block; margin-top: 2px; color: rgba(55, 75, 88, .62); font-size: 13px; }
.editable-list { display: flex; flex-direction: column; gap: 7px; }

.profile-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto 32px;
  align-items: center;
  gap: 6px;
  min-height: 46px;
  padding: 0;
  border: 0;
  background: transparent;
}

.profile-item-input {
  min-width: 0;
  height: 44px;
  padding: 0 12px;
  border: 1px solid var(--control-border);
  border-radius: var(--control-radius);
  outline: 0;
  background: var(--control-surface);
  box-shadow: 0 1px 2px rgba(25, 45, 58, .035);
  color: #2d4351;
  font-size: 14px;
  transition: border-color .16s ease, box-shadow .16s ease, background .16s ease;
}
.profile-item-input:hover { border-color: rgba(37, 59, 74, .4); }
.profile-item-input:focus { border-color: rgba(143, 107, 50, .62); background: #fffefa; box-shadow: var(--focus-ring); }
.source-badge { display: inline-flex; align-items: center; justify-content: center; min-height: 21px; margin-left: 8px; padding: 0 6px; border: 1px solid rgba(106, 133, 148, .2); background: rgba(93, 125, 143, .045); color: #657d8b; font-size: 12px; white-space: nowrap; }
.source-badge.official { border-color: rgba(151, 112, 50, .25); background: rgba(184, 144, 78, .07); color: #76572b; }
.source-badge.custom { border-color: rgba(74, 101, 121, .24); background: rgba(67, 96, 116, .06); color: #496577; }

.item-remove { display: grid; place-items: center; width: 32px; height: 32px; padding: 0; border: 1px solid rgba(48, 67, 80, .13); border-radius: var(--control-radius); background: rgba(255, 255, 255, .45); color: rgba(48, 67, 80, .48); font-size: 17px; cursor: pointer; }
.item-remove:hover:not(:disabled) { border-color: rgba(139, 72, 59, .24); background: rgba(139, 72, 59, .07); color: #8e5146; }
.item-remove:disabled { cursor: not-allowed; opacity: .25; }

.inline-add { display: grid; grid-template-columns: minmax(0, 1fr) 64px 32px; align-items: center; gap: 6px; min-height: 44px; margin-top: 8px; padding: 0; border: 0; background: transparent; box-shadow: none; }
.inline-add input { min-width: 0; height: 44px; padding: 0 12px; border: 1px solid var(--control-border); border-radius: var(--control-radius); outline: 0; background: var(--control-surface); color: var(--ink); font-size: 14px; }
.inline-add input:focus { border-color: rgba(143, 107, 50, .62); box-shadow: var(--focus-ring); }
.inline-add input::placeholder { color: rgba(43, 62, 75, .43); }
.inline-add button { height: 44px; border: 1px solid #233b4d; border-radius: var(--control-radius); background: #1a3141; color: #f7f2e8; font-size: 13px; font-weight: 600; cursor: pointer; }
.inline-add button:hover { background: #142a39; }
.inline-add .inline-cancel { width: 32px; padding: 0; border: 1px solid rgba(48, 67, 80, .18); border-radius: var(--control-radius); background: var(--control-surface); color: rgba(48, 67, 80, .58); font-size: 17px; }
.inline-add .inline-cancel:hover { border-color: rgba(139, 72, 59, .28); background: rgba(139, 72, 59, .06); color: #8e5146; }

.profile-context { margin-top: 18px; border-top: 1px solid var(--line); }
.profile-context summary { display: inline-flex; align-items: center; gap: 7px; min-height: 36px; margin-top: 10px; padding: 0 12px; border: 1px solid rgba(143, 107, 50, .3); border-radius: var(--control-radius); background: rgba(199, 170, 115, .07); color: #71552b; font-size: 13px; font-weight: 500; cursor: pointer; list-style: none; }
.profile-context summary::-webkit-details-marker { display: none; }
.profile-context summary::after { color: #8f6b32; font-size: 15px; content: "›"; transition: transform .16s ease; }
.profile-context[open] summary::after { transform: rotate(90deg); }
.profile-context summary:hover { border-color: rgba(143, 107, 50, .52); background: rgba(199, 170, 115, .13); }
.context-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 24px; padding: 13px 0 5px; }
.context-block span { display: block; margin-bottom: 5px; color: rgba(55, 75, 88, .64); font-size: 13px; }
.context-block p { margin: 0; color: #405562; font-size: 13.5px; line-height: 1.7; }
.profile-context ul { margin: 10px 0 0; padding-left: 18px; color: #6b593c; font-size: 12.5px; }

.profile-actions { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--line); }
.profile-actions-right { display: flex; align-items: center; gap: 18px; }
.cost-note { max-width: 270px; text-align: right; }
/* Run view */
.run-panel { min-height: 0; }
.run-overview {
  position: relative;
  overflow: hidden;
  padding: 30px 36px 26px;
  border: 1px solid #d4c5ad;
  border-radius: 7px;
  background: #fdfaf4;
  box-shadow: 0 20px 52px rgba(0, 5, 12, .2);
}
.run-overview::before {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, #94703c, #c5a46d 60%, #e4d6be);
  content: "";
}
.run-heading { align-items: center; }
.run-head-actions { display: flex; align-items: center; gap: 10px; }
.run-status.is-running { color: #35624e; border-color: #a7c5b6; background: #eef7f1; }
.run-status.is-failed { color: #8a4138; border-color: #d6aaa4; background: #fbefec; }
.run-status.is-completed { color: #705226; border-color: #d4bf9b; background: #f8f0df; }

.run-summary { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-top: 22px; padding-bottom: 3px; }
.run-brand-line { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.run-brand-line strong { color: #172d3c; font-family: var(--serif); font-size: 20px; font-weight: 700; }
.run-brand-line span { padding-left: 10px; border-left: 1px solid #c9d0d1; color: #5b6d78; font-size: 12.5px; }
.run-summary-copy p { margin: 5px 0 0; color: #536570; font-size: 13px; }
.run-percent { color: #6d4f25; font-family: var(--mono); font-size: 21px; font-weight: 600; }
.progress-track { height: 3px; margin-top: 12px; overflow: hidden; background: #e1ddd4; }
.progress-track span { display: block; width: 0; height: 100%; background: linear-gradient(90deg, #9b7138, #c8a66d); transition: width .45s ease; }
.run-meta { display: flex; flex-wrap: wrap; gap: 7px 16px; margin-top: 10px; color: #697983; font-size: 12.5px; }

.run-error { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-top: 20px; padding: 15px 16px; border: 1px solid #d6aaa4; background: #fff7f4; }
.run-error strong { color: #773b33; font-size: 13.5px; }
.run-error p { margin: 3px 0 0; color: #795b56; font-size: 12.5px; }

.stage-list {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-top: 14px;
  padding: 23px 24px 25px;
  border: 1px solid #d4c7b4;
  border-radius: 7px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .5), transparent 150px),
    #f2ece1;
  box-shadow: 0 18px 46px rgba(0, 5, 12, .16);
  color: #243b49;
}
.stage-group { min-width: 0; }
.stage-group + .stage-group { padding-top: 23px; border-top: 1px solid rgba(42, 63, 77, .17); }
.stage-group-heading { display: flex; align-items: center; gap: 11px; margin: 0 1px 12px; }
.stage-group-heading::after { height: 1px; flex: 1; margin-left: 4px; background: linear-gradient(90deg, rgba(108, 80, 40, .27), transparent); content: ""; }
.stage-group-index { color: #896635; font-family: var(--mono); font-size: 10.5px; font-weight: 700; letter-spacing: .08em; }
.stage-group-copy { min-width: 0; }
.stage-group-copy h2 { margin: 0; color: #182f3e; font-family: var(--serif); font-size: 15px; font-weight: 700; letter-spacing: .04em; }
.stage-group-copy p { margin: 2px 0 0; color: #60717b; font-size: 12.5px; }
.stage-group-copy p:empty { display: none; }
.stage-group-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; gap: 11px; }
.stage-group-signal .stage-group-list { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.stage-group-analysis .stage-group-list { grid-template-columns: minmax(0, 1fr); }

.stage-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid #d8cdbc;
  border-radius: 4px;
  background: #fffdf9;
  box-shadow: 0 3px 9px rgba(18, 34, 46, .055);
  color: #243b49;
  transition: border-color .2s ease, background .2s ease, box-shadow .2s ease, transform .2s ease;
}
.stage-card:hover { border-color: #b99b6b; box-shadow: 0 7px 18px rgba(18, 34, 46, .09); transform: translateY(-1px); }
.stage-card.is-open { grid-column: 1 / -1; border-color: #c6ae84; background: #fffefb; box-shadow: 0 12px 28px rgba(18, 34, 46, .12); }
.stage-card.is-running { border-color: #a98245; box-shadow: 0 7px 18px rgba(18, 34, 46, .09), inset 3px 0 0 #a98245; }
.stage-card.is-failed { border-color: #b98179; background: #fff9f6; }
.stage-card.has-no-body { border-color: #d8d1c6; background: #f5f2ec; box-shadow: none; }
.stage-card.has-no-body:hover { border-color: #d8d1c6; box-shadow: none; transform: none; }
.stage-card-evidence { border-color: #d2bd96; }
.stage-card-boards { border-color: #cdb47e; background: #fffaf1; }

.evidence-metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid #e3dcd1; border-bottom: 1px solid #e3dcd1; }
.evidence-metrics .stage-metric { min-height: 62px; padding: 11px 13px; border: 0; border-right: 1px solid #e3dcd1; background: #faf7f1; }
.evidence-metrics .stage-metric:last-child { border-right: 0; }
.evidence-metrics .stage-metric span { color: #62737d; font-size: 11.5px; }
.evidence-metrics .stage-metric strong { margin-top: 2px; color: #263e4c; font-family: var(--serif); font-size: 18px; }
.evidence-signal-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 9px; }
.evidence-signal-grid .stage-metric { display: flex; min-height: 34px; align-items: baseline; justify-content: space-between; gap: 8px; padding: 7px 10px; border: 1px solid #e1d9ce; background: #faf7f1; }
.evidence-signal-grid .stage-metric span { color: #64757f; font-size: 11.5px; }
.evidence-signal-grid .stage-metric strong { margin: 0; color: #6d5028; font-family: var(--mono); font-size: 13px; }
.evidence-conclusion { margin-top: 13px; padding: 15px 17px 14px; border: 1px solid #e2d4bd; border-left: 3px solid #9f783e; background: #fbf6eb; }
.evidence-conclusion-label { display: block; margin-bottom: 6px; color: #705225; font-size: 10.5px; font-weight: 700; letter-spacing: .13em; }
.evidence-summary { margin: 0; color: #3d5360; font-size: 13px; line-height: 1.85; }
.evidence-summary.is-clamped { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 4; }
.evidence-expand { margin-top: 7px; padding: 2px 0; border: 0; background: transparent; color: #6e5128; font-size: 11.5px; cursor: pointer; }
.evidence-expand:hover { color: #4e3517; text-decoration: underline; }

.stage-card-head { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto 24px; align-items: center; gap: 10px; width: 100%; min-height: 64px; padding: 11px 14px; border: 0; background: transparent; color: inherit; text-align: left; }
button.stage-card-head { cursor: pointer; }
button.stage-card-head:hover { background: #faf6ee; }
button.stage-card-head:focus-visible { outline: 2px solid rgba(143, 107, 50, .48); outline-offset: -3px; }
.stage-number { display: grid; place-items: center; width: 28px; height: 28px; border: 1px solid #ccd2d3; color: #617179; font-family: var(--mono); font-size: 11.5px; }
.stage-card.is-running .stage-number, .stage-card.is-completed .stage-number { border-color: #c6ac7d; background: #fbf5e9; color: #755427; }
.stage-title { min-width: 0; }
.stage-title strong { display: block; color: #172c3a; font-size: 14.5px; font-weight: 700; }
.stage-title span { display: block; overflow: hidden; margin-top: 2px; color: #566975; font-size: 12.5px; text-overflow: ellipsis; white-space: nowrap; }
.stage-progress-mini { width: 96px; height: 3px; overflow: hidden; background: #e1ddd4; }
.stage-progress-mini i { display: block; height: 100%; background: #ae874e; transition: width .35s ease; }
.stage-status { min-width: 52px; min-height: 24px; border-color: #ccd2d3; background: #f7f6f2; color: #596a73; font-size: 12px; }
.stage-status.is-running { border-color: #9dbdae; background: #eef7f1; color: #35624e; }
.stage-status.is-completed { border-color: #d0b98f; background: #f8f0df; color: #6e5025; }
.stage-status.is-failed { border-color: #d1a09a; background: #fbefec; color: #884038; }
.stage-chevron { position: relative; width: 8px; height: 8px; }
.stage-chevron::before,
.stage-chevron::after { position: absolute; top: 3px; width: 6px; height: 1px; background: #536874; content: ""; transition: transform .2s ease; }
.stage-chevron::before { left: 0; transform: rotate(45deg); }
.stage-chevron::after { right: 0; transform: rotate(-45deg); }
.stage-card.is-open .stage-chevron::before { transform: rotate(-45deg); }
.stage-card.is-open .stage-chevron::after { transform: rotate(45deg); }

.stage-body { padding: 0 14px 16px 54px; }
.stage-body:empty { display: none; }
.stage-pending-copy { margin: 0; color: #66767f; font-size: 13px; }
.stage-running-copy { display: flex; align-items: center; gap: 9px; margin: 0; color: #526874; font-size: 13px; }
.spinner { display: inline-block; flex: 0 0 auto; width: 13px; height: 13px; border: 1.5px solid rgba(143, 107, 50, .24); border-top-color: #8f6b32; border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.stage-metrics { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 7px; }
.stage-metric { min-height: 54px; padding: 9px 11px; border: 1px solid #e1d9ce; background: #faf7f1; }
.stage-metric span { display: block; color: #63747d; font-size: 12px; }
.stage-metric strong { display: block; overflow: hidden; margin-top: 2px; color: #263d4b; font-size: 14px; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.stage-note { margin: 10px 0 0; color: #445a67; font-size: 13.5px; line-height: 1.72; }
.stage-chip-row, .model-row { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 9px; }
.stage-chip, .model-chip { min-height: 25px; padding: 0 9px; border: 1px solid #d8d2c8; background: #faf8f3; color: #526671; font-size: 12px; }
.stage-chip.trust { border-color: #d4bd95; color: #6e5129; }
.stage-chip.competitor { border-color: #c3d1d8; color: #456577; }
.stage-chip.demand { border-color: #c5d2c7; color: #476350; }

.stage-details { margin-top: 10px; border-top: 1px solid #e2dbd0; }
.stage-details summary { padding: 9px 0 2px; color: #684c27; font-size: 12px; font-weight: 600; cursor: pointer; }
.question-group { margin-top: 11px; }
.question-group-title { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-bottom: 5px; color: #405866; font-size: 12px; font-weight: 700; }
.question-group-title span { color: #697983; font-size: 11.5px; font-weight: 400; }
.question-list { display: flex; flex-direction: column; gap: 4px; }
.question-row { display: grid; grid-template-columns: 42px minmax(0, 1fr) auto; gap: 8px; align-items: start; padding: 6px 8px; background: #faf7f1; }
.question-id { padding-top: 1px; color: #77858c; font-family: var(--mono); font-size: 11.5px; }
.question-main { min-width: 0; }
.question-main p { margin: 0; color: #344c5a; font-size: 12px; line-height: 1.5; }
.question-tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 3px; }
.question-tag { color: #63737c; font-size: 11.5px; }
.question-tag + .question-tag::before { margin-right: 4px; content: "?"; }
.priority { color: #7a5a2c; font-family: var(--mono); font-size: 11.5px; }

.collection-samples { margin-top: 14px; padding-top: 12px; border-top: 1px solid #e2dbd0; }
.collection-sample-head { display: flex; align-items: baseline; justify-content: space-between; gap: 14px; margin-bottom: 8px; }
.collection-sample-title { display: flex; align-items: baseline; gap: 8px; min-width: 0; }
.collection-sample-title strong { color: #2d4553; font-size: 13px; }
.collection-sample-title span, .collection-source-note { color: #6d7c84; font-size: 11.5px; }
.collection-source-note { flex: 0 0 auto; }
.collection-sample-host.is-expanded { max-height: 620px; overflow-y: auto; padding-right: 5px; scrollbar-width: thin; scrollbar-color: #cbbfa9 transparent; }
.sample-list { display: flex; flex-direction: column; gap: 8px; }
.sample-item { padding: 10px 12px 11px; border-left: 2px solid #c5aa78; background: #faf7f1; }
.sample-meta { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: #63747d; font-size: 11.5px; }
.sample-report-label { flex: 0 0 auto; padding: 1px 5px; border: 1px solid #d8c9ae; color: #76572d; font-size: 10.5px; line-height: 1.5; }
.sample-meta-copy { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sample-source-count { flex: 0 0 auto; }
.sample-item p { margin: 4px 0 0; color: #405763; font-size: 12px; line-height: 1.62; }
.sample-item .sample-question { color: #526773; font-size: 11.5px; line-height: 1.55; }
.sample-item .sample-answer { margin-top: 5px; color: #344c5a; font-size: 12.5px; line-height: 1.68; white-space: pre-wrap; }
.sample-citations { display: flex; flex-direction: column; gap: 2px; margin-top: 8px; padding-top: 6px; border-top: 1px solid #e5ddcf; }
.sample-source { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px; min-height: 24px; }
.sample-source-link { overflow: hidden; color: #6b4d25; font-size: 11.5px; text-decoration: none; text-overflow: ellipsis; white-space: nowrap; }
.sample-source-link::after { margin-left: 5px; color: #9a825d; content: "↗"; font-size: 10px; }
.sample-source-link:hover { color: #4d3416; text-decoration: underline; }
.sample-source-domain { color: #78868c; font-family: var(--mono); font-size: 10.5px; white-space: nowrap; }
.sample-no-source { display: block; margin-top: 7px; color: #7b898f; font-size: 11.5px; }
.collection-actions { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-top: 10px; padding-top: 9px; border-top: 1px solid #e2dbd0; }
.collection-actions-primary, .collection-export-group { display: flex; align-items: center; gap: 10px; min-width: 0; }
.collection-action { padding: 2px 0; border: 0; background: transparent; color: #6b4d25; font-size: 11.5px; font-weight: 600; text-decoration: none; cursor: pointer; }
.collection-action:hover { color: #4d3416; text-decoration: underline; }
.collection-action:disabled { color: #89959a; cursor: wait; text-decoration: none; }
.collection-action-note, .collection-export-label { color: #7b898f; font-size: 11.5px; white-space: nowrap; }

.source-verification-section { margin-top: 13px; padding-top: 12px; border-top: 1px solid #e2dbd0; }
.source-verification-head { display: flex; align-items: baseline; justify-content: space-between; gap: 14px; margin-bottom: 8px; }
.source-verification-title { display: flex; align-items: baseline; gap: 8px; min-width: 0; }
.source-verification-title strong { color: #2d4553; font-size: 13px; }
.source-verification-title span, .source-verification-note { color: #718087; font-size: 11px; }
.source-verification-note { flex: 0 0 auto; }
.source-verification-host { min-width: 0; }
.source-verify-list { display: flex; flex-direction: column; gap: 6px; }
.source-verify-item { padding: 9px 11px 8px; border: 1px solid #e2dbd0; border-left: 2px solid #9b8b74; background: #faf7f1; }
.source-verify-item.is-verified { border-left-color: #4f8067; }
.source-verify-item.is-partial { border-left-color: #a47c41; }
.source-verify-item.is-unavailable { border-left-color: #a3655d; }
.source-verify-top { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px; }
.source-verify-link { overflow: hidden; color: #5f4727; font-size: 12px; font-weight: 600; text-decoration: none; text-overflow: ellipsis; white-space: nowrap; }
.source-verify-link::after { margin-left: 5px; color: #9a825d; content: "↗"; font-size: 10px; }
.source-verify-link:hover { color: #3f2d18; text-decoration: underline; }
.source-verify-status { flex: 0 0 auto; padding: 1px 6px; border: 1px solid #d7cdbd; color: #6c6254; font-size: 10px; line-height: 1.55; white-space: nowrap; }
.source-verify-status.is-verified { border-color: #bfd0c6; color: #3d745b; }
.source-verify-status.is-partial { border-color: #d8c6a7; color: #8d6b35; }
.source-verify-status.is-unavailable { border-color: #d9c1bd; color: #9b5650; }
.source-verify-meta { display: flex; flex-wrap: wrap; gap: 3px 12px; margin-top: 4px; color: #78858b; font-size: 10.5px; }
.source-verify-domain { color: #6b767b; font-family: var(--mono); }
.source-verify-error { margin: 5px 0 0; color: #955e56; font-size: 10.5px; line-height: 1.5; }
.source-verification-actions { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-top: 8px; }
.source-verification-actions-primary { display: flex; align-items: center; gap: 10px; min-width: 0; }

.board-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.board-card { display: flex; min-height: 128px; flex-direction: column; justify-content: space-between; padding: 13px 14px 12px; border: 1px solid #dacdb8; border-radius: 3px; background: #fffdf8; box-shadow: 0 3px 10px rgba(34, 48, 58, .045); color: inherit; text-align: left; cursor: pointer; transition: background .18s ease, box-shadow .18s ease, border-color .18s ease; }
.board-card:hover { border-color: #b99a65; background: #fffefb; box-shadow: inset 0 2px 0 #a47c41, 0 6px 16px rgba(34, 48, 58, .08); }
.board-card.is-empty { justify-content: center; cursor: default; opacity: .55; }
.board-card.is-empty:hover { background: #fffdf8; box-shadow: none; }
.board-card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.board-index { color: #7f8a8f; font-family: var(--mono); font-size: 10.5px; }
.board-kicker { color: #745529; font-size: 10.5px; font-weight: 700; letter-spacing: .11em; }
.board-card h3 { margin: 10px 0 0; color: #1b3241; font-family: var(--serif); font-size: 14.5px; font-weight: 700; line-height: 1.45; }
.board-card p { display: -webkit-box; overflow: hidden; margin: 0; color: #4f626e; font-size: 12.5px; line-height: 1.7; -webkit-box-orient: vertical; -webkit-line-clamp: 3; }
.board-card .board-specific-title { display: block; overflow: hidden; margin: 6px 0 0; color: #5e707b; font-size: 12px; line-height: 1.55; text-overflow: ellipsis; white-space: nowrap; -webkit-line-clamp: unset; }
.board-card-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 13px; padding-top: 9px; border-top: 1px solid #e4dcd0; color: #536772; font-size: 11.5px; }
.board-card-foot b { color: #684b25; font-weight: 700; white-space: nowrap; }
.report-inline-metric { display: flex; align-items: baseline; gap: 7px; margin: 8px 0 9px; }
.report-inline-metric strong { color: #263e4d; font-family: var(--serif); font-size: 20px; }
.report-inline-metric span { color: #64747d; font-size: 11.5px; }
.tiny-link { border: 0; background: transparent; color: #6f5028; font-size: 11.5px; cursor: pointer; }
.tiny-link:hover { text-decoration: underline; }
/* Task rail */
.task-rail { position: sticky; top: 28px; display: flex; flex-direction: column; gap: 12px; }
.rail-heading { display: flex; align-items: center; justify-content: space-between; min-height: 27px; padding: 0 2px; color: rgba(232, 235, 230, .5); font-size: 11.5px; letter-spacing: .1em; }
.rail-heading .icon-button { width: 28px; height: 28px; color: rgba(232, 235, 230, .42); }
.rail-heading .icon-button:hover { background: rgba(255, 255, 255, .055); color: rgba(242, 240, 234, .8); }
.rail-heading svg { width: 15px; height: 15px; }
.rail-card { overflow: hidden; border: 1px solid rgba(177, 202, 219, .13); border-radius: 5px; background: rgba(17, 37, 52, .64); box-shadow: 0 14px 38px rgba(0, 6, 12, .09); backdrop-filter: blur(14px); }
.rail-toggle { display: grid; grid-template-columns: 36px minmax(0, 1fr) auto 15px; align-items: center; gap: 10px; width: 100%; min-height: 70px; padding: 11px 13px; border: 0; background: transparent; color: #e7e9e4; text-align: left; cursor: pointer; }
.rail-toggle:hover { background: rgba(255, 255, 255, .018); }
.rail-icon { display: grid; place-items: center; width: 34px; height: 34px; border: 1px solid rgba(219, 194, 147, .28); border-radius: 50%; color: #cdb079; }
.rail-icon svg { width: 17px; height: 17px; }
.rail-copy { display: flex; min-width: 0; flex-direction: column; gap: 2px; }
.rail-copy strong { overflow: hidden; color: #e9eae5; font-family: var(--serif); font-size: 14px; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.rail-copy small { overflow: hidden; color: rgba(225, 230, 225, .55); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.rail-count { display: grid; min-width: 22px; height: 22px; place-items: center; border: 1px solid rgba(226, 205, 165, .18); color: rgba(238, 232, 218, .74); font-family: var(--mono); font-size: 11px; }
.rail-chevron { width: 15px; height: 15px; color: rgba(231, 234, 228, .48); transition: transform .2s ease; }
.rail-card.is-open .rail-chevron { transform: rotate(180deg); }
.rail-body { max-height: 0; overflow: hidden; border-top: 1px solid transparent; transition: max-height .28s ease, border-color .28s ease; }
.rail-card.is-open .rail-body { max-height: 430px; overflow-y: auto; border-top-color: rgba(255, 255, 255, .07); }
.rail-card.is-open .rail-toggle { min-height: 64px; padding-top: 9px; padding-bottom: 9px; }
.rail-card.is-open .rail-icon { width: 32px; height: 32px; }
.rail-list { padding: 7px; }
.rail-item { display: flex; width: 100%; flex-direction: column; gap: 5px; padding: 11px 10px; border: 0; border-bottom: 1px solid rgba(255, 255, 255, .055); background: transparent; color: #dfe4df; text-align: left; cursor: pointer; transition: background .16s ease; }
.rail-item:last-child { border-bottom: 0; }
.rail-item:hover { background: rgba(255, 255, 255, .035); }
.rail-item.is-current { background: rgba(194, 158, 94, .07); box-shadow: inset 2px 0 0 rgba(198, 165, 105, .65); }
.rail-item-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.rail-item-top strong { overflow: hidden; color: #e7e8e3; font-size: 12.5px; font-weight: 500; text-overflow: ellipsis; white-space: nowrap; }
.rail-item-top span { flex: 0 0 auto; color: rgba(225, 230, 225, .43); font-family: var(--mono); font-size: 11.5px; }
.rail-item-meta { display: flex; align-items: center; justify-content: space-between; gap: 10px; color: rgba(225, 230, 225, .38); font-size: 11.5px; }
.rail-item-meta b { color: #c5a66c; font-weight: 500; }
.rail-item-badge { padding: 1px 5px; border: 1px solid rgba(197, 166, 108, .32); color: #c6a66d !important; font-size: 10.5px !important; line-height: 1.4; white-space: nowrap; }
.rail-empty { padding: 22px 12px; color: rgba(225, 230, 225, .38); font-size: 12px; text-align: center; }
.rail-note { margin: 1px 5px 0; color: rgba(224, 229, 224, .48); font-size: 12px; line-height: 1.55; }

/* Dialog */
.modal { width: min(1080px, calc(100vw - 44px)); max-height: 88vh; padding: 0; overflow: hidden; border: 1px solid rgba(199, 166, 108, .36); border-radius: 6px; background: var(--paper); box-shadow: 0 26px 80px rgba(0, 5, 12, .46); color: var(--ink); }
.modal::backdrop { background: rgba(1, 10, 17, .7); backdrop-filter: blur(7px); }
.modal-shell { display: flex; max-height: 88vh; flex-direction: column; }
.compact-shell { max-height: none; }
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; padding: 20px 24px 15px; border-bottom: 1px solid var(--line); }
.modal-head h2 { margin: 0; color: #1d3444; font-family: var(--serif); font-size: 19px; }
.report-dialog-subtitle { margin: 5px 0 0; color: #6a7880; font-size: 13px; line-height: 1.55; }
.report-dialog-actions { display: flex; flex: 0 0 auto; align-items: center; gap: 9px; padding-top: 1px; }
.report-export-button { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 36px; padding: 0 12px; border-color: rgba(143, 107, 50, .35); background: var(--control-surface); color: #644a27; font-size: 13px; letter-spacing: .01em; white-space: nowrap; }
.report-export-button:hover:not(:disabled) { border-color: rgba(143, 107, 50, .42); background: rgba(186, 151, 91, .13); }
.report-export-button:focus-visible { outline: 1px solid rgba(143, 107, 50, .5); outline-offset: 2px; }
.report-export-button svg { width: 14px; height: 14px; flex: 0 0 auto; }
.modal-close { display: grid; width: 34px; height: 34px; flex: 0 0 auto; place-items: center; padding: 0; border: 1px solid rgba(53, 74, 88, .22); border-radius: var(--control-radius); background: rgba(255, 255, 255, .32); color: #576b76; font-size: 18px; cursor: pointer; }
.modal-close:hover { background: rgba(39, 59, 73, .06); }
.modal-close:focus-visible { outline: 1px solid rgba(143, 107, 50, .5); outline-offset: 1px; }
.modal-body { overflow-y: auto; padding: 20px 24px 22px; }
.report-summary { max-width: 840px; margin: 0 0 20px; padding: 15px 17px 14px; border: 1px solid rgba(58, 80, 94, .13); background: rgba(255, 255, 255, .22); color: #435966; font-size: 13.5px; line-height: 1.78; }
.report-summary::before { display: block; margin-bottom: 7px; color: var(--gold-deep); font-size: 10.5px; font-weight: 700; letter-spacing: .13em; content: "执行摘要"; }
.report-hero { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 22px; padding: 16px 18px; border: 1px solid rgba(143, 107, 50, .2); background: rgba(190, 156, 97, .065); }
.report-hero strong { display: block; color: #263e4e; font-family: var(--serif); font-size: 23px; line-height: 1.1; }
.report-hero span { display: block; margin-top: 4px; color: #6d7a80; font-size: 12px; }
.report-hero .metric-basis { margin-top: 6px; color: #82612f; font-size: 10.5px; font-weight: 600; letter-spacing: .04em; }
.report-hero p { max-width: 430px; margin: 0; color: #6a5a3e; font-size: 12px; text-align: right; }
.report-section { margin-top: 27px; }
.report-section h3 { display: flex; align-items: center; gap: 10px; margin: 0 0 12px; color: #263d4c; font-family: var(--serif); font-size: 16px; }
.report-section h3::after { height: 1px; flex: 1; background: var(--line); content: ""; }
.report-section-intro { max-width: 760px; margin: -3px 0 14px; color: #68777e; font-size: 12px; line-height: 1.75; }
.section-badge { order: 2; padding: 2px 6px; border: 1px solid rgba(143, 107, 50, .22); color: #806337; font-size: 10.5px; font-weight: 500; line-height: 1.4; }
.finding-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.finding-card { padding: 15px 16px; border: 1px solid rgba(58, 80, 94, .13); background: rgba(255, 255, 255, .22); }
.finding-card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.finding-card h4 { margin: 0; color: #344b59; font-size: 13.5px; font-weight: 600; line-height: 1.5; }
.finding-priority { flex: 0 0 auto; color: #8b6630; font-family: var(--mono); font-size: 11.5px; }
.finding-card p { margin: 7px 0 0; color: #556974; font-size: 12.5px; line-height: 1.7; }
.finding-implication { margin-top: 9px; padding-top: 8px; border-top: 1px solid rgba(58, 80, 94, .11); color: #755b35 !important; }
.evidence-list { display: flex; flex-direction: column; gap: 7px; margin-top: 9px; }
.evidence-item { padding: 8px 9px; border-left: 2px solid rgba(143, 107, 50, .22); background: rgba(143, 107, 50, .035); color: rgba(67, 86, 98, .72); font-size: 11.5px; line-height: 1.62; }
.evidence-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-bottom: 4px; }
.evidence-verified { padding: 1px 5px; border: 1px solid rgba(61, 112, 82, .2); color: #476d55; font-size: 10px; }
.evidence-id { color: #8a7960; font-family: var(--mono); font-size: 10px; }
.evidence-quote { display: block; }
.evidence-item a { display: inline-block; margin-top: 4px; color: #73582f; }
.evidence-toggle { align-self: flex-start; margin-top: 2px; padding: 0; border: 0; background: transparent; color: #74562d; font-size: 11px; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.report-provenance { display: flex; align-items: flex-start; gap: 12px; margin: 0 0 18px; padding: 11px 13px; border: 1px solid rgba(127, 89, 44, .22); background: rgba(179, 137, 78, .07); color: #66563f; font-size: 11.5px; line-height: 1.6; }
.report-provenance strong { flex: 0 0 auto; color: #72532c; font-weight: 600; }
.report-provenance span { color: #786b58; }
.report-limitations { margin: 8px 0 0; padding-left: 18px; color: #695b43; font-size: 12.5px; }
.methodology-note { margin-top: 24px; padding: 13px 15px; border-left: 2px solid rgba(143, 107, 50, .4); background: rgba(186, 151, 91, .055); color: #65747c; font-size: 12px; line-height: 1.7; }

.confirm-modal { width: min(680px, calc(100vw - 44px)); }
.confirm-copy { margin: 0; color: #506470; font-size: 13.5px; line-height: 1.7; }
.confirm-facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; margin-top: 16px; border: 1px solid var(--line); background: var(--line); }
.confirm-facts span { display: flex; align-items: baseline; justify-content: center; gap: 4px; min-height: 40px; background: rgba(255, 255, 255, .28); color: #687780; font-size: 12px; }
.confirm-facts b { color: #5d4524; font-family: var(--serif); font-size: 16px; }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 16px; }

.toast { position: fixed; z-index: 100; right: 28px; bottom: 26px; max-width: min(430px, calc(100vw - 40px)); padding: 12px 15px; border: 1px solid rgba(198, 165, 105, .34); background: #142b3b; box-shadow: 0 18px 46px rgba(0, 5, 12, .3); color: #ebe9e1; font-size: 13px; line-height: 1.55; }

/* Unified interaction and description system */
.primary-button {
  min-height: 40px;
  padding: 0 17px;
  border-color: #203847;
  background: #183244;
  color: #fffaf1;
  font-size: 13.5px;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(16, 35, 49, .14);
}
.primary-button:hover:not(:disabled) {
  border-color: #102937;
  background: #102937;
  box-shadow: 0 6px 16px rgba(16, 35, 49, .2);
}

.secondary-button,
.text-button {
  min-height: 38px;
  padding: 0 13px;
  border: 1px solid rgba(32, 55, 70, .44);
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(25, 45, 58, .055);
  color: #2d4858;
  font-size: 13px;
  font-weight: 600;
}
.secondary-button:hover:not(:disabled),
.text-button:hover:not(:disabled) {
  border-color: rgba(128, 92, 40, .62);
  background: #fffaf1;
  color: #233e4d;
}
.primary-button.compact,
.secondary-button.compact {
  min-height: 34px;
  padding: 0 12px;
  font-size: 13px;
}

.brand-input-shell,
.region-field input {
  height: 46px;
}
.brand-input-shell {
  padding: 0 14px;
}
.brand-input-shell input {
  height: 44px;
  font-size: 15px;
}
.region-field input {
  font-size: 14px;
}
.profile-item-input,
.inline-add input {
  height: 42px;
  font-size: 13.5px;
}
.profile-item {
  grid-template-columns: minmax(0, 1fr) auto 34px;
  min-height: 44px;
}
.item-remove {
  width: 34px;
  height: 34px;
  border-color: rgba(48, 67, 80, .22);
  background: #ffffff;
}
.inline-add {
  grid-template-columns: minmax(0, 1fr) 58px 36px;
  min-height: 42px;
}
.inline-add button {
  height: 42px;
  font-size: 13px;
}
.inline-add .inline-cancel {
  width: 36px;
  height: 42px;
}
.brand-input-shell:focus-within,
.region-field input:focus,
.profile-item-input:focus,
.inline-add input:focus {
  border-color: var(--control-border-hover);
  background: #ffffff;
  box-shadow: var(--focus-ring), inset 0 1px 0 rgba(255, 255, 255, .95);
}
#researchForm.is-locked .brand-input-shell,
#researchForm.is-locked .region-field input {
  border-color: rgba(46, 70, 86, .2);
  background: rgba(255, 255, 255, .52);
}

.ui-note,
.field-label-row span,
.run-summary-copy p,
.stage-pending-copy,
.stage-running-copy,
.stage-note,
.collection-action-note,
.collection-export-label,
.source-verification-note,
.confirm-copy,
.report-dialog-subtitle,
.profile-evidence {
  color: rgba(48, 68, 81, .68);
  font-size: 13px;
  line-height: 1.55;
}
.profile-evidence a {
  color: #75572d;
  font-size: 13px;
}

.collection-action,
.evidence-expand,
.evidence-toggle,
.tiny-link {
  min-height: 32px;
  padding: 0 10px;
  border: 1px solid rgba(32, 55, 70, .38);
  border-radius: var(--control-radius);
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(25, 45, 58, .045);
  color: #4e4232;
  font-size: 12.5px;
  font-weight: 600;
  text-decoration: none;
}
.collection-action:hover:not(:disabled),
.evidence-expand:hover:not(:disabled),
.evidence-toggle:hover:not(:disabled),
.tiny-link:hover:not(:disabled) {
  border-color: rgba(128, 92, 40, .62);
  background: #fffaf1;
  color: #352b20;
  text-decoration: none;
}
.evidence-expand {
  margin-top: 8px;
}
.evidence-toggle {
  min-height: 30px;
}

.stage-card-head {
  gap: 11px;
  min-height: 62px;
}
button.stage-card-head:hover {
  background: #fbf7ef;
}
.stage-chevron {
  width: 24px;
  height: 24px;
  border: 1px solid rgba(65, 84, 96, .26);
  border-radius: var(--control-radius);
  background: #ffffff;
  color: #586b76;
  transition: background .16s ease, border-color .16s ease;
}
.stage-chevron::before,
.stage-chevron::after {
  top: 9px;
  width: 6px;
}
.stage-chevron::before { left: 6px; }
.stage-chevron::after { right: 6px; }
button.stage-card-head:hover .stage-chevron,
.stage-card.is-open .stage-chevron {
  border-color: rgba(128, 92, 40, .45);
  background: #fffaf1;
}

.stage-details {
  margin-top: 12px;
  padding-top: 9px;
  border-top: 1px solid #e2dbd0;
}
.stage-details summary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 32px;
  margin: 0;
  padding: 0 10px;
  border: 1px solid rgba(32, 55, 70, .38);
  border-radius: var(--control-radius);
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(25, 45, 58, .045);
  color: #4e4232;
  font-size: 12.5px;
  font-weight: 600;
  list-style: none;
  cursor: pointer;
}
.stage-details summary::-webkit-details-marker { display: none; }
.stage-details summary::after {
  width: 6px;
  height: 6px;
  margin-top: -3px;
  border-right: 1px solid currentColor;
  border-bottom: 1px solid currentColor;
  content: "";
  transform: rotate(45deg);
  transition: transform .16s ease, margin .16s ease;
}
.stage-details[open] summary::after {
  margin-top: 3px;
  transform: rotate(225deg);
}
.stage-details summary:hover {
  border-color: rgba(128, 92, 40, .62);
  background: #fffaf1;
  color: #352b20;
}

.profile-context > summary.secondary-button {
  min-height: 34px;
  margin-top: 12px;
  padding: 0 11px;
  border: 1px solid rgba(32, 55, 70, .38);
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(25, 45, 58, .045);
  color: #415663;
  font-size: 13px;
  font-weight: 600;
}
.profile-context > summary.secondary-button::after {
  color: #7a5d34;
  font-size: 15px;
}
.profile-context > summary.secondary-button:hover,
.profile-context[open] > summary.secondary-button {
  border-color: rgba(128, 92, 40, .62);
  background: #fffaf1;
  color: #2c4351;
}

.stage-group-index,
.evidence-conclusion-label,
.sample-report-label,
.source-verify-status,
.board-index,
.board-kicker {
  font-size: 11.5px;
}
.stage-title span,
.stage-group-copy p,
.evidence-metrics .stage-metric span,
.evidence-signal-grid .stage-metric span,
.collection-sample-title span,
.collection-source-note,
.sample-meta,
.sample-item .sample-question,
.sample-source-link,
.source-verification-title span,
.source-verification-note,
.source-verify-meta,
.question-group-title span,
.question-tag,
.board-card-foot,
.report-inline-metric span {
  font-size: 12.5px;
}
.sample-item .sample-answer,
.question-main p {
  font-size: 13px;
}
.report-provenance {
  font-size: 12.5px;
}

/* Final control hierarchy: controls are solid; helper copy is quiet. */
.primary-button,
.secondary-button,
.text-button,
.collection-action,
.evidence-expand,
.evidence-toggle,
.tiny-link,
.inline-add button,
.modal-close,
.item-remove {
  border-radius: var(--control-radius);
  transition: border-color .16s ease, background .16s ease, color .16s ease, box-shadow .16s ease, transform .16s ease;
}

.primary-button {
  min-height: 42px;
  border-color: #173243;
  background: #173243;
  box-shadow: 0 5px 14px rgba(16, 35, 49, .2);
}
.primary-button:hover:not(:disabled) {
  border-color: #0e2737;
  background: #0e2737;
  box-shadow: 0 7px 18px rgba(16, 35, 49, .25);
}

.secondary-button,
.text-button {
  min-height: 36px;
  border: 1px solid rgba(35, 57, 71, .58);
  background: #fffdfa;
  box-shadow: 0 1px 2px rgba(25, 45, 58, .08);
  color: #203b4b;
  font-size: 13px;
  font-weight: 600;
}
.secondary-button:hover:not(:disabled),
.text-button:hover:not(:disabled) {
  border-color: rgba(128, 92, 40, .78);
  background: #fffaf0;
  color: #243d4b;
}
.primary-button.compact,
.secondary-button.compact {
  min-height: 34px;
  padding: 0 12px;
}

.brand-input-shell,
.region-field input,
.profile-item-input,
.inline-add input {
  border: 1px solid rgba(35, 57, 71, .56);
  background: #fffefa;
  box-shadow: 0 1px 2px rgba(25, 45, 58, .075), inset 0 1px 0 rgba(255, 255, 255, .88);
}
.brand-input-shell:hover,
.region-field input:hover,
.profile-item-input:hover,
.inline-add input:hover {
  border-color: rgba(54, 76, 90, .72);
  background: #ffffff;
}
.brand-input-shell:focus-within,
.region-field input:focus,
.profile-item-input:focus,
.inline-add input:focus {
  border-color: rgba(128, 92, 40, .86);
  background: #ffffff;
  box-shadow: var(--focus-ring), inset 0 0 0 1px rgba(197, 165, 106, .12);
}
.brand-input-shell input::placeholder,
.region-field input::placeholder,
.profile-item-input::placeholder,
.inline-add input::placeholder {
  color: rgba(38, 57, 70, .5);
}
#researchForm.is-locked .brand-input-shell,
#researchForm.is-locked .region-field input {
  border-color: rgba(46, 70, 86, .25);
  background: rgba(255, 255, 255, .55);
}

.inline-add {
  grid-template-columns: minmax(0, 1fr) 58px 36px;
}
.inline-add button {
  min-height: 40px;
  border-color: #173243;
  background: #173243;
  box-shadow: 0 2px 6px rgba(16, 35, 49, .12);
}
.inline-add .inline-cancel {
  min-height: 40px;
  border: 1px solid rgba(35, 57, 71, .38);
  background: #fffdfa;
}
.profile-item {
  grid-template-columns: minmax(0, 1fr) auto 34px;
}
.source-badge.public {
  display: none;
}
.source-badge {
  margin-left: 2px;
  border: 0;
  border-radius: 999px;
  background: rgba(91, 116, 132, .09);
  color: #526b79;
  font-size: 11.5px;
}
.source-badge.official,
.source-badge.custom {
  border: 0;
  border-radius: 999px;
}

.confidence-badge,
.run-status,
.stage-status {
  gap: 6px;
  border: 0;
  border-radius: 999px;
  background: rgba(143, 107, 50, .1);
  padding: 0 9px;
}
.confidence-badge::before,
.run-status::before,
.stage-status::before {
  width: 5px;
  height: 5px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: currentColor;
  content: "";
}

.profile-lead {
  gap: 22px;
  margin-top: 18px;
}
.profile-tags {
  gap: 6px;
}
.profile-tag {
  max-width: 100%;
  overflow: hidden;
  border-color: rgba(64, 85, 99, .2);
  background: rgba(255, 255, 255, .4);
  text-overflow: ellipsis;
  white-space: nowrap;
}
.profile-evidence {
  max-width: 310px;
  flex-direction: row;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 4px 10px;
  color: rgba(55, 75, 88, .58);
}
.profile-evidence-label {
  color: rgba(55, 75, 88, .48);
  font-size: 12.5px;
}
.profile-evidence a {
  color: #6f552f;
  text-decoration: none;
  border-bottom: 1px solid rgba(111, 85, 47, .22);
}
.profile-positioning {
  color: #3c5260;
  line-height: 1.62;
}
.profile-group-head > div > span {
  margin-top: 2px;
  color: rgba(55, 75, 88, .62);
  font-size: 13px;
}
.profile-context > summary.secondary-button {
  min-height: 34px;
  border-color: rgba(35, 57, 71, .58);
  background: #fffdfa;
  color: #203b4b;
}

.deliverable-strip {
  gap: 0;
  color: rgba(48, 68, 81, .62);
}
.deliverable-strip .dot {
  display: none;
}
.ui-note,
.field-label-row span,
.run-summary-copy p,
.stage-pending-copy,
.stage-running-copy,
.stage-note,
.collection-action-note,
.collection-export-label,
.source-verification-note,
.confirm-copy,
.report-dialog-subtitle,
.profile-evidence {
  font-size: 13px;
  line-height: 1.55;
}
.auto-profile-note,
.cost-note,
.profile-inline-caption {
  color: rgba(48, 68, 81, .6);
  font-size: 13px;
  line-height: 1.55;
}

.collection-action,
.evidence-expand,
.evidence-toggle,
.tiny-link {
  border: 1px solid rgba(35, 57, 71, .5);
  background: #fffdfa;
  box-shadow: 0 1px 2px rgba(25, 45, 58, .06);
}
.stage-details summary,
.profile-context > summary.secondary-button {
  box-shadow: 0 1px 2px rgba(25, 45, 58, .06);
}
.modal-close,
.item-remove {
  border-color: rgba(35, 57, 71, .32);
  background: #fffdfa;
}

@media (max-width: 760px) {
  .profile-lead {
    gap: 12px;
  }
  .profile-evidence {
    justify-content: flex-start;
    text-align: left;
  }
  .profile-item {
    grid-template-columns: minmax(0, 1fr) auto;
  }
  .source-badge {
    display: none;
  }
  .secondary-button,
  .text-button {
    min-height: 38px;
  }
  .primary-button {
    min-height: 42px;
  }
  .profile-context > summary.secondary-button {
    min-height: 38px;
  }
}

@media (max-width: 1280px) {
  .workspace-grid { grid-template-columns: minmax(0, 1fr) 310px; gap: 22px; }
  .stage-group-signal .stage-group-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .research-panel { padding: 28px 30px 26px; }
  .run-overview { padding: 28px 30px 26px; }
  .deliverable-strip { gap: 12px; }
  .board-card { min-height: 128px; }
}

@media (max-width: 1020px) {
  .topbar-inner { grid-template-columns: 1fr auto; }
  .workspace-grid { grid-template-columns: 1fr; }
  .task-rail { position: static; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rail-heading, .rail-note { grid-column: 1 / -1; }
  .rail-card.is-open .rail-body { max-height: 300px; }
}

@media (max-width: 760px) {
  body { font-size: 14px; }
  .topbar-inner, .workspace-shell { width: calc(100% - 30px); }
  .topbar-inner { height: 72px; }
  .topbar-actions { gap: 8px; }
  .topbar-new-research { width: 34px; height: 34px; padding: 0; }
  .topbar-new-research span { display: none; }
  .brand-mark { width: 36px; height: 36px; }
  .brand-name { font-size: 16px; }
  .brand-sub { display: none; }
  .engine-status { min-height: 32px; padding: 0 10px; font-size: 11.5px; }
  .engine-status > span:not(.status-dot) { display: none; }
  .auth-chip { min-height: 34px; padding: 2px; gap: 1px; border-color: transparent; background: transparent; }
  .auth-avatar { width: 30px; height: 30px; }
  .auth-copy { display: none; }
  .auth-logout { width: 30px; min-width: 30px; height: 30px; padding: 0; }
  .auth-logout span { display: none; }
  .workspace-shell { padding: 20px 0 38px; }
  .research-panel { min-height: 0; padding: 22px 18px 20px; }
  .run-overview { padding: 22px 18px 20px; }
  .intake-fields { grid-template-columns: 1fr; gap: 18px; }
  h1 { font-size: 22px; }
  .flow-progress { gap: 3px; }
  .flow-progress li span { display: none; }
  .flow-progress li:not(:last-child)::after { width: 15px; }
  .profile-columns, .finding-list, .context-grid { grid-template-columns: 1fr; }
  .auto-profile-note { margin-top: 4px; }
  .form-actions, .profile-lead, .profile-actions, .run-heading, .run-error { align-items: stretch; flex-direction: column; }
  .profile-inline-head, .profile-build-error { align-items: flex-start; flex-direction: column; }
  .profile-inline-head-actions { width: 100%; justify-content: space-between; }
  .profile-build-error button { width: 100%; }
  .form-actions .primary-button, .profile-actions-right, .profile-actions .primary-button { width: 100%; }
  .profile-actions-right { align-items: stretch; flex-direction: column; }
  .cost-note { max-width: none; text-align: left; }
  .deliverable-strip { justify-content: space-between; }
  .profile-overview { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .profile-evidence { max-width: none; align-items: flex-start; text-align: left; }
  .run-head-actions { justify-content: space-between; }
  .stage-group-list { grid-template-columns: 1fr; }
  .stage-group-signal .stage-group-list { grid-template-columns: 1fr; }
  .stage-card.is-open { grid-column: auto; }
  .stage-card-head { grid-template-columns: 30px minmax(0, 1fr) auto 24px; min-height: 62px; padding: 10px 12px; }
  .stage-body { padding: 0 12px 14px 50px; }
  .collection-sample-head, .collection-actions { align-items: flex-start; flex-direction: column; }
  .collection-actions { gap: 8px; }
  .collection-export-group { width: 100%; justify-content: flex-end; }
  .sample-source { grid-template-columns: 1fr; gap: 1px; }
  .sample-source-domain { padding-bottom: 3px; }
  .evidence-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .evidence-metrics .stage-metric:nth-child(2) { border-right: 0; }
  .evidence-metrics .stage-metric:nth-child(-n+2) { border-bottom: 1px solid rgba(60, 81, 95, .11); }
  .evidence-signal-grid { grid-template-columns: 1fr; }
  .board-grid { grid-template-columns: 1fr; }
  .board-card { min-height: 0; }
  .task-rail { grid-template-columns: 1fr; }
  .rail-heading, .rail-note { grid-column: auto; }
  .modal { width: calc(100vw - 24px); max-height: 92vh; }
  .modal-head { padding: 20px 19px 15px; }
  .report-dialog-actions { gap: 7px; }
  .report-export-button { min-height: 29px; padding: 0 9px; }
  .modal-body { padding: 20px 19px 24px; }
  .report-hero { align-items: flex-start; flex-direction: column; }
  .report-hero p { text-align: left; }
  .confirm-facts { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

/* Design hierarchy v3: one quiet copy style, one obvious control language. */
:root {
  --control-border: rgba(31, 54, 69, .58);
  --control-border-hover: rgba(138, 101, 46, .86);
  --control-surface: #fffefa;
  --helper-text: 13px;
}

body {
  font-size: 14.5px;
}

/* One shared button system. */
.primary-button,
.secondary-button,
.text-button,
.collection-action,
.evidence-expand,
.evidence-toggle,
.tiny-link,
.inline-add button,
.modal-close,
.item-remove {
  border-radius: 4px;
}

.primary-button {
  min-height: 42px;
  padding: 0 18px;
  border: 1px solid #0d2636;
  background: #132f42;
  box-shadow: 0 5px 14px rgba(13, 38, 54, .2);
  color: #fffaf0;
  font-size: 13.5px;
  font-weight: 650;
  letter-spacing: .01em;
}
.primary-button:hover:not(:disabled) {
  border-color: #091f2d;
  background: #091f2d;
  box-shadow: 0 7px 18px rgba(13, 38, 54, .26);
  transform: translateY(-1px);
}
.primary-button svg {
  width: 15px;
  height: 15px;
}

.secondary-button,
.text-button {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid rgba(35, 57, 71, .62);
  background: #fffdf8;
  box-shadow: 0 1px 3px rgba(25, 45, 58, .09);
  color: #203a49;
  font-size: 13.5px;
  font-weight: 600;
}
.secondary-button:hover:not(:disabled),
.text-button:hover:not(:disabled) {
  border-color: rgba(128, 92, 40, .78);
  background: #fff8ec;
  color: #183443;
  box-shadow: 0 2px 6px rgba(25, 45, 58, .1);
}
.primary-button.compact,
.secondary-button.compact {
  min-height: 34px;
  padding: 0 12px;
  font-size: 13px;
}
.profile-edit-button {
  min-width: 104px;
}
.profile-edit-button svg {
  width: 14px;
  height: 14px;
  flex: 0 0 auto;
}

/* Inputs read as fields, not as paragraphs. */
.brand-input-shell,
.region-field input,
.profile-item-input,
.inline-add input {
  border: 1px solid rgba(31, 54, 69, .58);
  background: #fffefa;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .9), 0 1px 2px rgba(25, 45, 58, .07);
}
.brand-input-shell:hover,
.region-field input:hover,
.profile-item-input:hover,
.inline-add input:hover {
  border-color: rgba(52, 75, 89, .78);
  background: #ffffff;
}
.brand-input-shell:focus-within,
.region-field input:focus,
.profile-item-input:focus,
.inline-add input:focus {
  border-color: rgba(134, 97, 43, .9);
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(181, 143, 78, .17);
}

.profile-item-input,
.inline-add input {
  height: 40px;
  font-size: 13.5px;
}
.profile-item {
  grid-template-columns: minmax(0, 1fr) 34px;
  gap: 7px;
  min-height: 42px;
}
.profile-item.has-source {
  grid-template-columns: minmax(0, 1fr) auto 34px;
}
.editable-list {
  gap: 5px;
}
.item-remove,
.modal-close {
  width: 34px;
  height: 34px;
  border: 1px solid rgba(35, 57, 71, .38);
  background: #fffdf8;
  color: #596b76;
  font-size: 17px;
  font-weight: 400;
}
.item-remove:hover:not(:disabled),
.modal-close:hover:not(:disabled) {
  border-color: rgba(139, 72, 59, .44);
  background: #fff7f4;
  color: #8e4d43;
}
.inline-add {
  grid-template-columns: minmax(0, 1fr) 56px 36px;
  min-height: 40px;
}
.inline-add button {
  height: 40px;
  border: 1px solid #132f42;
  background: #132f42;
  box-shadow: 0 2px 6px rgba(13, 38, 54, .14);
  color: #fffaf0;
  font-size: 13px;
  font-weight: 600;
}
.inline-add .inline-cancel {
  width: 36px;
  height: 40px;
  border-color: rgba(35, 57, 71, .38);
  background: #fffdf8;
  color: #596b76;
}

/* Secondary in-page actions use the same outlined control, not link styling. */
.collection-action,
.evidence-expand,
.evidence-toggle,
.tiny-link,
.stage-details summary,
.profile-context > summary.secondary-button {
  min-height: 34px;
  padding: 0 11px;
  border: 1px solid rgba(35, 57, 71, .52);
  background: #fffdf8;
  box-shadow: 0 1px 3px rgba(25, 45, 58, .08);
  color: #314b59;
  font-size: 12.5px;
  font-weight: 600;
  text-decoration: none;
}
.collection-action:hover:not(:disabled),
.evidence-expand:hover:not(:disabled),
.evidence-toggle:hover:not(:disabled),
.tiny-link:hover:not(:disabled),
.stage-details summary:hover,
.profile-context > summary.secondary-button:hover,
.profile-context[open] > summary.secondary-button {
  border-color: rgba(128, 92, 40, .74);
  background: #fff8ec;
  color: #243e4d;
  text-decoration: none;
}
.evidence-expand {
  margin-top: 8px;
}
.stage-details summary::after,
.profile-context > summary.secondary-button::after {
  margin-left: 2px;
}

/* Compact icon controls stay visible without becoming primary buttons. */
.icon-button.rail-refresh {
  width: 30px;
  height: 30px;
  border: 1px solid rgba(220, 226, 222, .17);
  background: rgba(255, 255, 255, .025);
  color: rgba(231, 235, 231, .64);
}
.icon-button.rail-refresh:hover {
  border-color: rgba(218, 198, 160, .34);
  background: rgba(255, 255, 255, .065);
  color: #f2ece0;
}
.stage-chevron {
  width: 27px;
  height: 27px;
  border-color: rgba(35, 57, 71, .38);
  background: #fffdf8;
  box-shadow: 0 1px 2px rgba(25, 45, 58, .07);
}
.stage-chevron::before,
.stage-chevron::after {
  top: 10px;
}
.stage-chevron::before { left: 7px; }
.stage-chevron::after { right: 7px; }

/* Profile hierarchy: identity first, edit control second, supporting copy last. */
.profile-section {
  margin-top: 24px;
  padding-top: 21px;
}
.profile-lead {
  align-items: flex-start;
  gap: 26px;
  margin: 0 0 18px;
  padding-bottom: 17px;
}
.profile-identity {
  min-width: 0;
  flex: 1 1 auto;
}
.profile-identity .eyebrow {
  display: block;
  margin-bottom: 7px;
}
.profile-name-row {
  gap: 10px;
}
.profile-name-row h2 {
  color: #1a3040;
  font-size: 23px;
  line-height: 1.25;
}
.profile-lead-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: flex-end;
  flex-direction: column;
  gap: 9px;
}
.profile-tags {
  gap: 6px;
  margin-top: 7px;
}
.profile-tag {
  min-height: 23px;
  border-color: rgba(64, 85, 99, .18);
  background: rgba(255, 255, 255, .3);
  color: #5d6f7a;
  font-size: 12px;
}
.profile-evidence {
  max-width: 320px;
  gap: 3px 9px;
  padding: 0;
  color: #6f7e86;
  font-size: 12.5px;
  line-height: 1.5;
}
.profile-evidence-label {
  font-size: 12px;
}
.profile-evidence a {
  color: #70562f;
  font-size: 12.5px;
  border-bottom-color: rgba(112, 86, 47, .26);
}
.profile-overview {
  margin-top: 15px;
}
.profile-fact span {
  color: #75838b;
  font-size: 12px;
}
.profile-fact strong {
  font-size: 13.5px;
}
.profile-positioning {
  margin-top: 14px;
  padding-left: 11px;
  color: #405562;
  font-size: 13.5px;
  line-height: 1.65;
}
.profile-columns {
  gap: 26px;
  margin-top: 22px;
}
.profile-group-head {
  margin-bottom: 9px;
}
.profile-group-head h2 {
  font-size: 16px;
}
.profile-actions {
  justify-content: flex-end;
  margin-top: 22px;
  padding-top: 17px;
}
.profile-actions-right {
  gap: 0;
}

/* Quiet, consistent explanatory text. */
.ui-note,
.field-label-row span,
.run-summary-copy p,
.stage-pending-copy,
.stage-running-copy,
.stage-note,
.collection-action-note,
.collection-export-label,
.source-verification-note,
.confirm-copy,
.report-dialog-subtitle,
.auto-profile-note,
.cost-note,
.profile-inline-caption {
  color: #697982;
  font-size: 13px;
  line-height: 1.55;
}
.stage-title span,
.stage-group-copy p,
.collection-source-note,
.source-verification-title span,
.board-card-foot {
  color: #667781;
}

@media (max-width: 760px) {
  body { font-size: 14px; }
  .profile-lead {
    gap: 13px;
  }
  .profile-lead-actions {
    width: 100%;
    align-items: flex-start;
    gap: 8px;
  }
  .profile-name-row h2 {
    font-size: 22px;
  }
  .profile-evidence {
    max-width: none;
    align-items: flex-start;
    text-align: left;
  }
  .profile-item,
  .profile-item.has-source {
    grid-template-columns: minmax(0, 1fr) 36px;
  }
  .profile-item-input {
    height: 42px;
  }
  .item-remove {
    width: 36px;
    height: 36px;
  }
  .secondary-button,
  .text-button,
  .profile-context > summary.secondary-button,
  .stage-details summary,
  .collection-action,
  .evidence-expand,
  .evidence-toggle,
  .tiny-link {
    min-height: 40px;
  }
  .primary-button {
    min-height: 44px;
  }
  .profile-actions {
    justify-content: stretch;
  }
}


/* Positioning copy stays scannable until the reader asks for the full brief. */
.profile-positioning-wrap {
  display: flex;
  align-items: flex-start;
  flex-direction: column;
  gap: 7px;
  margin-top: 14px;
}
.profile-positioning-wrap .profile-positioning {
  margin-top: 0;
}
.profile-positioning:not(.is-expanded) {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}
.profile-positioning-toggle {
  min-height: 32px;
  padding: 0 10px;
  font-size: 12px;
}
@media (max-width: 760px) {
  .profile-positioning:not(.is-expanded) {
    -webkit-line-clamp: 3;
  }
  .profile-positioning-toggle {
    min-height: 36px;
  }
}

/* Control system v4: quiet surfaces, unified geometry, one dominant action per view. */
:root {
  --control-radius: 9px;
  --control-radius-sm: 8px;
  --control-border: rgba(20, 43, 58, .15);
  --control-border-hover: rgba(20, 43, 58, .27);
  --control-border-focus: rgba(139, 103, 49, .58);
  --control-surface: rgba(255, 253, 249, .82);
  --control-surface-hover: #fffefb;
  --control-shadow: inset 0 1px 0 rgba(255, 255, 255, .9), 0 1px 2px rgba(17, 34, 47, .035);
  --focus-ring: 0 0 0 3px rgba(169, 130, 66, .115);
}

.primary-button,
.secondary-button,
.text-button,
.collection-action,
.evidence-expand,
.evidence-toggle,
.tiny-link,
.inline-add button,
.modal-close,
.item-remove {
  border-radius: var(--control-radius-sm);
  font-family: var(--sans);
  letter-spacing: .012em;
  transition:
    background-color .16s ease,
    border-color .16s ease,
    color .16s ease,
    box-shadow .16s ease,
    transform .12s ease;
}

.primary-button {
  min-height: 40px;
  padding: 0 16px;
  border: 1px solid rgba(8, 29, 43, .92);
  background: #183344;
  box-shadow:
    0 4px 10px rgba(10, 30, 44, .14),
    inset 0 1px 0 rgba(255, 255, 255, .075);
  color: #fffaf1;
  font-size: 13.5px;
  font-weight: 600;
}
.primary-button:hover:not(:disabled) {
  border-color: #0a2637;
  background: #102c3e;
  box-shadow:
    0 5px 13px rgba(10, 30, 44, .18),
    inset 0 1px 0 rgba(255, 255, 255, .075);
  transform: none;
}
.primary-button:active:not(:disabled) {
  background: #0b2536;
  box-shadow: 0 2px 6px rgba(10, 30, 44, .14);
  transform: translateY(1px);
}
.primary-button:focus-visible {
  outline: 0;
  box-shadow:
    0 0 0 3px rgba(169, 130, 66, .2),
    0 4px 10px rgba(10, 30, 44, .14);
}
.primary-button svg {
  width: 14px;
  height: 14px;
}

.secondary-button,
.text-button {
  min-height: 36px;
  padding: 0 13px;
  border: 1px solid rgba(20, 43, 58, .14);
  background: rgba(255, 255, 255, .3);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .55);
  color: #344d5c;
  font-size: 13px;
  font-weight: 600;
}
.secondary-button:hover:not(:disabled),
.text-button:hover:not(:disabled) {
  border-color: rgba(20, 43, 58, .25);
  background: rgba(255, 255, 255, .72);
  color: #183344;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .75);
}
.secondary-button:focus-visible,
.text-button:focus-visible {
  outline: 0;
  border-color: var(--control-border-focus);
  box-shadow: var(--focus-ring), inset 0 1px 0 rgba(255, 255, 255, .75);
}
.primary-button.compact,
.secondary-button.compact {
  min-height: 32px;
  padding: 0 11px;
  font-size: 12.5px;
}

.brand-input-shell,
.region-field input,
.profile-item-input,
.inline-add input {
  border: 1px solid var(--control-border);
  border-radius: var(--control-radius);
  background: var(--control-surface);
  box-shadow: var(--control-shadow);
  color: #223946;
  transition: background-color .16s ease, border-color .16s ease, box-shadow .16s ease;
}
.brand-input-shell,
.region-field input {
  height: 46px;
}
.brand-input-shell {
  padding: 0 14px;
}
.region-field input {
  padding: 0 13px;
  font-size: 14px;
}
.brand-input-shell:hover,
.region-field input:hover,
.profile-item-input:hover,
.inline-add input:hover {
  border-color: var(--control-border-hover);
  background: var(--control-surface-hover);
}
.brand-input-shell:focus-within,
.region-field input:focus,
.profile-item-input:focus,
.inline-add input:focus {
  border-color: var(--control-border-focus);
  outline: 0;
  background: #fffefa;
  box-shadow: var(--focus-ring), inset 0 1px 0 rgba(255, 255, 255, .95);
}
.brand-input-shell input {
  font-size: 15px;
}
.brand-input-shell input::placeholder,
.region-field input::placeholder,
.profile-item-input::placeholder,
.inline-add input::placeholder {
  color: rgba(31, 51, 65, .34);
  font-weight: 400;
}
.field-icon {
  color: rgba(31, 51, 65, .4);
}
#researchForm.is-locked .brand-input-shell,
#researchForm.is-locked .region-field input {
  border-color: rgba(20, 43, 58, .08);
  background: rgba(255, 253, 249, .34);
  box-shadow: none;
}

.profile-item {
  grid-template-columns: minmax(0, 1fr) 32px;
  gap: 6px;
  min-height: 40px;
}
.profile-item.has-source {
  grid-template-columns: minmax(0, 1fr) auto 32px;
}
.editable-list {
  gap: 6px;
}
.profile-item-input {
  height: 38px;
  padding: 0 11px;
  font-size: 13.5px;
}
.item-remove,
.modal-close {
  width: 32px;
  height: 32px;
  border: 1px solid transparent;
  border-radius: var(--control-radius-sm);
  background: transparent;
  box-shadow: none;
  color: rgba(50, 70, 82, .43);
  font-size: 16px;
  font-weight: 400;
}
.item-remove:hover:not(:disabled),
.modal-close:hover:not(:disabled) {
  border-color: rgba(155, 78, 69, .13);
  background: rgba(155, 78, 69, .065);
  color: #8b4d44;
}
.item-remove:focus-visible,
.modal-close:focus-visible {
  outline: 0;
  border-color: rgba(155, 78, 69, .35);
  box-shadow: 0 0 0 3px rgba(155, 78, 69, .1);
}

.inline-add {
  grid-template-columns: minmax(0, 1fr) 54px 32px;
  gap: 6px;
  min-height: 38px;
}
.inline-add input,
.inline-add button {
  height: 38px;
}
.inline-add input {
  padding: 0 11px;
  font-size: 13.5px;
}
.inline-add button {
  border: 1px solid rgba(8, 29, 43, .9);
  background: #183344;
  box-shadow: 0 2px 5px rgba(10, 30, 44, .1);
  color: #fffaf1;
  font-size: 12.5px;
  font-weight: 600;
}
.inline-add button:hover {
  border-color: #0a2637;
  background: #102c3e;
}
.inline-add .inline-cancel {
  width: 32px;
  border-color: transparent;
  background: transparent;
  box-shadow: none;
  color: rgba(50, 70, 82, .43);
}
.inline-add .inline-cancel:hover {
  border-color: rgba(155, 78, 69, .13);
  background: rgba(155, 78, 69, .065);
  color: #8b4d44;
}

.collection-action,
.evidence-expand,
.evidence-toggle,
.tiny-link,
.stage-details summary,
.profile-context > summary.secondary-button {
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid rgba(20, 43, 58, .13);
  border-radius: var(--control-radius-sm);
  background: rgba(255, 255, 255, .36);
  box-shadow: none;
  color: #405764;
  font-size: 12.5px;
  font-weight: 600;
  text-decoration: none;
}
.collection-action:hover:not(:disabled),
.evidence-expand:hover:not(:disabled),
.evidence-toggle:hover:not(:disabled),
.tiny-link:hover:not(:disabled),
.stage-details summary:hover,
.profile-context > summary.secondary-button:hover,
.profile-context[open] > summary.secondary-button {
  border-color: rgba(20, 43, 58, .24);
  background: rgba(255, 255, 255, .7);
  color: #193342;
  text-decoration: none;
}
.collection-action:focus-visible,
.evidence-expand:focus-visible,
.evidence-toggle:focus-visible,
.tiny-link:focus-visible,
.stage-details summary:focus-visible,
.profile-context > summary.secondary-button:focus-visible {
  outline: 0;
  border-color: var(--control-border-focus);
  box-shadow: var(--focus-ring);
}

.stage-chevron {
  width: 24px;
  height: 24px;
  border: 1px solid rgba(20, 43, 58, .16);
  border-radius: 7px;
  background: rgba(255, 255, 255, .4);
  box-shadow: none;
}

.report-export-button {
  min-height: 32px;
  padding: 0 11px;
  border-color: rgba(20, 43, 58, .14);
  background: rgba(255, 255, 255, .34);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .55);
  color: #344d5c;
}
.report-export-button:hover:not(:disabled) {
  border-color: rgba(20, 43, 58, .25);
  background: rgba(255, 255, 255, .74);
  color: #183344;
}

.rail-card {
  border-color: rgba(177, 202, 219, .11);
  border-radius: 10px;
  box-shadow: 0 12px 32px rgba(0, 7, 13, .07);
}
.rail-toggle {
  transition: background-color .16s ease;
}
.rail-toggle:hover {
  background: rgba(255, 255, 255, .026);
}
.rail-toggle:focus-visible {
  outline: 1px solid rgba(205, 176, 121, .55);
  outline-offset: -3px;
}
.rail-count {
  border-radius: 6px;
  background: rgba(255, 255, 255, .025);
}
.icon-button.rail-refresh {
  border-color: transparent;
  border-radius: 8px;
  background: transparent;
}
.icon-button.rail-refresh:hover {
  border-color: rgba(218, 198, 160, .2);
  background: rgba(255, 255, 255, .05);
}

@media (max-width: 760px) {
  .primary-button {
    min-height: 42px;
  }
  .topbar-inner { width: calc(100% - 24px); }
  .topbar-actions { gap: 6px; }
  .brand-copy { min-width: 0; }
  .brand-name { white-space: nowrap; }

  .primary-button.compact,
  .secondary-button.compact {
    min-height: 36px;
  }
  .secondary-button,
  .text-button,
  .profile-context > summary.secondary-button,
  .stage-details summary,
  .collection-action,
  .evidence-expand,
  .evidence-toggle,
  .tiny-link {
    min-height: 38px;
  }
  .brand-input-shell,
  .region-field input {
    height: 48px;
  }
  .profile-item-input,
  .inline-add input,
  .inline-add button {
    height: 40px;
  }
  .item-remove,
  .modal-close {
    width: 36px;
    height: 36px;
  }
}/* Confirmation dialog v2: compact editorial sheet instead of a table-like alert. */
.confirm-modal {
  width: min(520px, calc(100vw - 32px));
  overflow: hidden;
  border-color: rgba(143, 107, 50, .27);
  border-radius: 12px;
  background: linear-gradient(180deg, #fbf8f1 0%, #f7f2e8 100%);
  box-shadow:
    0 30px 90px rgba(0, 5, 12, .42),
    0 8px 28px rgba(0, 5, 12, .18);
}
.confirm-modal .compact-shell {
  overflow: hidden;
  border-radius: inherit;
}
.confirm-modal .modal-head {
  align-items: flex-start;
  gap: 16px;
  padding: 20px 22px 15px;
  border-bottom-color: rgba(50, 66, 75, .115);
  background: rgba(255, 255, 255, .16);
}
.confirm-modal .modal-head > div {
  min-width: 0;
}
.confirm-modal .eyebrow {
  display: block;
  margin: 0 0 7px;
  color: #886735;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .14em;
  line-height: 1.2;
}
.confirm-modal .modal-head h2 {
  color: #1d3444;
  font-size: 22px;
  line-height: 1.2;
  letter-spacing: -.015em;
}
.confirm-modal .modal-close {
  width: 30px;
  height: 30px;
  margin-top: -1px;
  padding: 0 0 1px;
  border-color: transparent;
  border-radius: 50%;
  background: transparent;
  color: #718087;
  font-family: Arial, sans-serif;
  font-size: 19px;
  font-weight: 400;
  line-height: 1;
}
.confirm-modal .modal-close:hover:not(:disabled) {
  border-color: rgba(50, 66, 75, .09);
  background: rgba(50, 66, 75, .055);
  color: #344d5c;
}
.confirm-modal .modal-close:focus-visible {
  border-color: var(--control-border-focus);
  box-shadow: var(--focus-ring);
}
.confirm-modal .modal-body {
  padding: 19px 22px 18px;
}
.confirm-modal .confirm-copy {
  max-width: 44em;
  margin: 0;
  color: #526671;
  font-size: 14px;
  line-height: 1.72;
}
.confirm-modal .confirm-facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  margin: 17px 0 0;
  padding: 14px 0;
  border: 0;
  border-top: 1px solid rgba(50, 66, 75, .115);
  border-bottom: 1px solid rgba(50, 66, 75, .115);
  background: transparent;
}
.confirm-modal .confirm-facts span {
  display: flex;
  min-width: 0;
  min-height: 50px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 4px;
  padding: 0 12px;
  background: transparent;
  color: #6d7c83;
  font-size: 11.5px;
  line-height: 1.2;
  white-space: nowrap;
}
.confirm-modal .confirm-facts span + span {
  border-left: 1px solid rgba(50, 66, 75, .105);
}
.confirm-modal .confirm-facts b {
  color: #4e3c24;
  font-family: var(--serif);
  font-size: 25px;
  font-weight: 600;
  line-height: 1;
  letter-spacing: -.02em;
}
.confirm-modal .modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 17px;
  padding-top: 15px;
  border-top: 1px solid rgba(50, 66, 75, .08);
}
.confirm-modal .modal-actions .secondary-button,
.confirm-modal .modal-actions .primary-button {
  min-height: 38px;
  padding-right: 16px;
  padding-left: 16px;
  font-size: 13px;
}
.confirm-modal .modal-actions .primary-button {
  min-width: 132px;
}

@media (max-width: 760px) {
  .confirm-modal .modal-head {
    padding: 18px 18px 14px;
  }
  .confirm-modal .modal-head h2 {
    font-size: 21px;
  }
  .confirm-modal .modal-body {
    padding: 17px 18px 16px;
  }
  .confirm-modal .confirm-copy {
    font-size: 13.5px;
  }
  .confirm-modal .confirm-facts {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .confirm-modal .confirm-facts span {
    min-height: 47px;
    padding: 0 7px;
    font-size: 11px;
  }
  .confirm-modal .confirm-facts b {
    font-size: 23px;
  }
  .confirm-modal .modal-actions .secondary-button,
  .confirm-modal .modal-actions .primary-button {
    min-height: 39px;
    font-size: 12.5px;
  }
}

@media (max-width: 520px) {
  .engine-status b { display: none; }
  .engine-status { width: 30px; min-height: 30px; padding: 0; justify-content: center; }
  .brand-name b { display: none; }
}

@media (max-width: 340px) {
  .confirm-modal .confirm-facts span {
    padding: 0 4px;
  }
  .confirm-modal .confirm-facts b {
    font-size: 21px;
  }
}

.finding-missing { margin: 9px 0 0 !important; padding: 8px 9px; border-left: 2px solid rgba(143, 107, 50, .32); background: rgba(143, 107, 50, .045); color: #756a59 !important; font-size: 11.5px !important; line-height: 1.65 !important; }


/* Consulting report reading system */
.report-modal {
  width: min(1120px, calc(100vw - 40px));
  max-height: 91vh;
  border-radius: 10px;
  border-color: rgba(180, 145, 86, .32);
  background: #f7f1e6;
}
.report-modal .modal-shell { max-height: 91vh; }
.report-modal .modal-head {
  padding: 17px 26px 14px;
  background: linear-gradient(180deg, rgba(255, 255, 255, .46), rgba(255, 255, 255, .1));
}
.report-modal .eyebrow { color: #8a6734; font-size: 10px; letter-spacing: .15em; }
.report-modal .modal-head h2 { font-size: 20px; letter-spacing: -.01em; }
.report-modal .report-dialog-subtitle { font-size: 12.5px; color: #6f7d84; }

.report-consulting {
  padding: 22px 28px 34px;
  background:
    radial-gradient(circle at 95% 4%, rgba(181, 143, 78, .08), transparent 24%),
    linear-gradient(180deg, #faf6ed 0%, #f5eee2 100%);
  color: #334a58;
  font-size: 13px;
  line-height: 1.75;
}
.report-consulting > * { width: min(100%, 980px); margin-right: auto; margin-left: auto; }
.report-consulting .report-summary {
  max-width: 980px;
  margin-top: 0;
  margin-bottom: 14px;
  padding: 18px 20px 17px;
  border: 1px solid rgba(25, 48, 64, .13);
  border-left: 3px solid #9d783e;
  border-radius: 7px;
  background: rgba(255, 255, 255, .5);
  box-shadow: 0 8px 24px rgba(22, 40, 54, .045);
  color: #344d5c;
  font-family: var(--serif);
  font-size: 14.5px;
  line-height: 1.9;
}
.report-consulting .report-summary::before {
  margin-bottom: 8px;
  color: #886532;
  font-family: var(--sans);
  font-size: 9.5px;
  letter-spacing: .16em;
}
.report-consulting .report-hero {
  margin-top: 0;
  margin-bottom: 14px;
  padding: 15px 18px;
  border: 1px solid rgba(143, 107, 50, .17);
  border-radius: 7px;
  background: rgba(190, 156, 97, .07);
  box-shadow: none;
}
.report-consulting .report-hero strong { font-size: 24px; color: #243f50; }
.report-consulting .report-hero p { color: #6e604c; font-size: 11.5px; line-height: 1.65; }

.report-consulting .report-section {
  margin-top: 14px;
  padding: 19px 20px 20px;
  border: 1px solid rgba(26, 49, 65, .115);
  border-radius: 8px;
  background: rgba(255, 255, 255, .54);
  box-shadow: 0 8px 24px rgba(18, 36, 49, .045);
}
.report-consulting .report-section h3 {
  gap: 8px;
  margin-bottom: 14px;
  color: #1f3949;
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: .015em;
}
.report-consulting .report-section h3::after { background: rgba(24, 46, 61, .115); }
.report-consulting .report-section h3 small.section-badge {
  order: 2;
  padding: 2px 6px;
  border: 1px solid rgba(139, 103, 49, .22);
  border-radius: 3px;
  background: rgba(175, 137, 74, .055);
  color: #826332;
  font-family: var(--sans);
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: .03em;
  line-height: 1.45;
  white-space: nowrap;
}

.report-consulting .report-card-head,
.report-consulting .finding-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.report-consulting .report-card-title {
  display: flex;
  min-width: 0;
  align-items: baseline;
  gap: 9px;
}
.report-consulting .report-card-title h4,
.report-consulting .report-choice-card h4,
.report-consulting .report-roadmap-head h4 {
  margin: 0;
  color: #233d4d;
  font-family: var(--sans);
  font-size: 13.5px;
  font-weight: 700;
  line-height: 1.55;
}
.report-consulting .report-card-index {
  flex: 0 0 auto;
  color: #9a7b49;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: .04em;
}
.report-consulting .report-confidence,
.report-consulting .report-priority {
  flex: 0 0 auto;
  padding: 1px 6px;
  border: 1px solid rgba(55, 78, 92, .15);
  border-radius: 3px;
  color: #6f7d84;
  font-family: var(--mono);
  font-size: 9.5px;
  line-height: 1.55;
  text-transform: uppercase;
}

.report-consulting .report-takeaway-grid,
.report-consulting .report-choice-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 10px;
}
.report-consulting .report-takeaway-card,
.report-consulting .report-choice-card {
  position: relative;
  display: flex;
  min-width: 0;
  flex-direction: column;
  padding: 15px 15px 14px;
  border: 1px solid rgba(28, 52, 68, .105);
  border-radius: 6px;
  background: rgba(255, 255, 255, .42);
}
.report-consulting .report-takeaway-card::before {
  position: absolute;
  top: 15px;
  bottom: 15px;
  left: 0;
  width: 2px;
  background: rgba(154, 116, 55, .42);
  content: "";
}
.report-consulting .report-judgment {
  margin: 9px 0 0;
  color: #455d6a;
  font-size: 12.5px;
  line-height: 1.78;
}
.report-consulting .report-decision {
  margin-top: 11px;
  padding: 9px 10px;
  border: 1px solid rgba(142, 105, 49, .13);
  border-radius: 4px;
  background: rgba(183, 146, 81, .06);
}
.report-consulting .report-decision-label,
.report-consulting .report-detail-label,
.report-consulting .report-choice-label {
  display: block;
  color: #866536;
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: .08em;
  line-height: 1.5;
}
.report-consulting .report-decision p {
  margin: 3px 0 0;
  color: #4d4438;
  font-size: 12.5px;
  line-height: 1.7;
}

.report-consulting .report-choice-card > h4 { margin-bottom: 10px; }
.report-consulting .report-choice-row {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 9px;
  padding: 7px 0;
  border-top: 1px solid rgba(31, 54, 69, .075);
}
.report-consulting .report-choice-row p {
  margin: 0;
  color: #495f6b;
  font-size: 12.5px;
  line-height: 1.7;
}
.report-consulting .report-choice-label { padding-top: 2px; color: #7e765f; }

.report-consulting .report-section-intro { margin: -2px 0 12px; color: #687b84; font-size: 12.2px; line-height: 1.78; }
.report-consulting .finding-list.is-consulting { gap: 9px; }
.report-consulting .finding-list.is-consulting .finding-card {
  padding: 14px 15px;
  border: 1px solid rgba(29, 52, 68, .105);
  border-radius: 6px;
  background: rgba(255, 255, 255, .36);
}
.report-consulting .finding-card h4 { color: #2b4555; font-size: 12.8px; }
.report-consulting .finding-priority { color: #927242; font-size: 10px; }
.report-consulting .finding-card p { color: #4f6571; font-size: 12.4px; line-height: 1.8; }
.report-consulting .finding-card > .report-narrative-copy { margin: 9px 0 0; }
.report-consulting .report-choice-card > .report-judgment { margin: 0; }
.report-consulting .finding-implication {
  margin-top: 9px;
  padding-top: 8px;
  border-top-color: rgba(29, 52, 68, .08);
  color: #705b38 !important;
  font-size: 12px !important;
}

.report-consulting .report-action-list { display: flex; flex-direction: column; gap: 10px; }
.report-consulting .report-action-card {
  padding: 16px 17px 15px;
  border: 1px solid rgba(27, 51, 67, .11);
  border-left: 3px solid rgba(143, 107, 50, .56);
  border-radius: 5px;
  background: rgba(255, 255, 255, .46);
}
.report-consulting .report-action-tags { display: flex; gap: 5px; }
.report-consulting .report-action-lead {
  margin: 9px 0 0;
  color: #354f5f;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.72;
}
.report-consulting .report-action-why {
  margin-top: 11px;
  padding: 9px 10px;
  border-left: 2px solid rgba(143, 107, 50, .28);
  background: rgba(179, 139, 74, .05);
}
.report-consulting .report-action-why p,
.report-consulting .report-action-boundary p {
  margin: 3px 0 0;
  color: #586a73;
  font-size: 12.2px;
  line-height: 1.72;
}
.report-consulting .report-actions-block { margin-top: 13px; }
.report-consulting .report-action-steps,
.report-consulting .report-detail-list {
  margin: 6px 0 0;
  padding-left: 17px;
  color: #485f6c;
  font-size: 12.1px;
  line-height: 1.72;
}
.report-consulting .report-action-steps li + li,
.report-consulting .report-detail-list li + li { margin-top: 3px; }
.report-consulting .report-action-details {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 11px 18px;
  margin-top: 13px;
  padding-top: 12px;
  border-top: 1px solid rgba(29, 52, 68, .08);
}
.report-consulting .report-detail-block { min-width: 0; }
.report-consulting .report-action-boundary {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px dashed rgba(143, 107, 50, .2);
}
.report-consulting .report-action-nongoals { margin-top: 10px; }
.report-consulting .report-action-basis {
  margin: 11px 0 0;
  color: #718087;
  font-size: 11.5px;
  line-height: 1.65;
}

.report-consulting .report-roadmap {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.report-consulting .report-roadmap::before {
  position: absolute;
  top: 20px;
  bottom: 20px;
  left: 16px;
  width: 1px;
  background: rgba(143, 107, 50, .24);
  content: "";
}
.report-consulting .report-roadmap-phase {
  position: relative;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 12px;
}
.report-consulting .report-roadmap-marker {
  z-index: 1;
  display: grid;
  width: 33px;
  height: 33px;
  place-items: center;
  border: 1px solid rgba(143, 107, 50, .32);
  border-radius: 50%;
  background: #faf5eb;
  color: #856431;
  font-family: var(--mono);
  font-size: 9px;
}
.report-consulting .report-roadmap-body {
  padding: 13px 14px;
  border: 1px solid rgba(28, 52, 68, .105);
  border-radius: 6px;
  background: rgba(255, 255, 255, .42);
}
.report-consulting .report-roadmap-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}
.report-consulting .report-roadmap-head span { color: #7d8587; font-size: 10.5px; text-align: right; }
.report-consulting .report-roadmap-objective {
  margin: 5px 0 0;
  color: #526874;
  font-size: 12.2px;
  line-height: 1.72;
}
.report-consulting .report-roadmap-body .report-detail-block { margin-top: 10px; }
.report-consulting .report-roadmap-details { margin-top: 11px; padding-top: 10px; }

.report-consulting .report-section-metrics { overflow: hidden; }
.report-consulting .report-metric-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 11.8px;
  line-height: 1.6;
}
.report-consulting .report-metric-table th {
  padding: 8px 9px;
  border-top: 1px solid rgba(28, 52, 68, .1);
  border-bottom: 1px solid rgba(28, 52, 68, .12);
  background: rgba(34, 58, 74, .035);
  color: #766548;
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: .07em;
  text-align: left;
}
.report-consulting .report-metric-table th:nth-child(1) { width: 18%; }
.report-consulting .report-metric-table th:nth-child(2) { width: 42%; }
.report-consulting .report-metric-table th:nth-child(3) { width: 24%; }
.report-consulting .report-metric-table th:nth-child(4) { width: 16%; }
.report-consulting .report-metric-table td {
  padding: 10px 9px;
  border-bottom: 1px solid rgba(28, 52, 68, .075);
  color: #536974;
  vertical-align: top;
}
.report-consulting .report-metric-table tr:last-child td { border-bottom: 0; }
.report-consulting .report-metric-name { color: #2e4858 !important; font-weight: 600; }
.report-consulting .report-metric-target { color: #74572d !important; font-family: var(--mono); font-size: 11.3px; }
.report-consulting .report-metric-cadence { color: #78858a !important; white-space: nowrap; }

.report-consulting .report-boundary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px 14px;
}
.report-consulting .report-boundary-item {
  display: grid;
  grid-template-columns: 12px minmax(0, 1fr);
  gap: 7px;
  padding: 8px 0;
  border-top: 1px solid rgba(139, 103, 49, .11);
}
.report-consulting .report-boundary-mark { color: #9a7a48; }
.report-consulting .report-boundary-item p {
  margin: 0;
  color: #5d696f;
  font-size: 12px;
  line-height: 1.68;
}

.report-consulting .report-brief-evidence {
  margin-top: 11px;
  padding-top: 9px;
  border-top: 1px solid rgba(28, 52, 68, .075);
}
.report-consulting .report-brief-meta,
.report-consulting .report-brief-source {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 5px 8px;
}
.report-consulting .report-brief-label {
  color: #8b6735;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .1em;
}
.report-consulting .report-brief-id {
  color: #8c806b;
  font-family: var(--mono);
  font-size: 9px;
}
.report-consulting .report-brief-verified {
  padding: 0 4px;
  border: 1px solid rgba(62, 113, 82, .16);
  border-radius: 2px;
  color: #54735f;
  font-size: 8.5px;
}
.report-consulting .report-brief-quote {
  display: -webkit-box;
  overflow: hidden;
  margin: 4px 0 4px;
  color: #78858a;
  font-size: 10.8px;
  line-height: 1.6;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}
.report-consulting .report-brief-domain { color: #8b806e; font-family: var(--mono); font-size: 9px; }
.report-consulting .report-brief-link,
.report-consulting .report-appendix-link {
  color: #70542c;
  font-size: 10.5px;
  font-weight: 600;
  text-decoration: none;
  text-underline-offset: 2px;
}
.report-consulting .report-brief-link:hover,
.report-consulting .report-appendix-link:hover { text-decoration: underline; }
.report-consulting .report-brief-more { margin-left: auto; color: #8c8374; font-size: 9.5px; }

.report-consulting .report-section-appendix {
  border-color: rgba(139, 103, 49, .16);
  background: rgba(248, 243, 233, .72);
  box-shadow: none;
}
.report-consulting .report-appendix-intro {
  margin: -4px 0 9px;
  color: #7d8587;
  font-size: 10.8px;
}
.report-consulting .report-appendix-item {
  padding: 11px 0;
  border-top: 1px solid rgba(28, 52, 68, .085);
}
.report-consulting .report-appendix-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 5px 8px;
  margin-bottom: 5px;
}
.report-consulting .report-appendix-verified {
  padding: 0 4px;
  border: 1px solid rgba(62, 113, 82, .18);
  border-radius: 2px;
  color: #4f715c;
  font-size: 8.5px;
}
.report-consulting .report-appendix-id,
.report-consulting .report-appendix-domain {
  color: #8c806e;
  font-family: var(--mono);
  font-size: 9px;
}
.report-consulting .report-appendix-item blockquote {
  margin: 0 0 5px;
  color: #596d78;
  font-family: var(--serif);
  font-size: 11.8px;
  line-height: 1.7;
}
.report-consulting .report-appendix-source {
  display: flex;
  min-width: 0;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
}
.report-consulting .report-appendix-url {
  overflow: hidden;
  max-width: min(100%, 620px);
  color: #9a8f7e;
  font-family: var(--mono);
  font-size: 8.7px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.report-consulting .report-appendix-toggle {
  min-height: 28px;
  margin-top: 8px;
  padding: 0 10px;
  border: 1px solid rgba(139, 103, 49, .2);
  border-radius: 3px;
  background: rgba(255, 255, 255, .4);
  color: #74582f;
  font-size: 10.5px;
  cursor: pointer;
}
.report-consulting .report-appendix-toggle:hover { background: rgba(255, 255, 255, .72); }
.report-consulting .report-appendix-toggle:focus-visible { outline: 1px solid rgba(143, 107, 50, .5); outline-offset: 1px; }
.report-consulting .report-section-limitations { background: rgba(255, 255, 255, .34); box-shadow: none; }
.report-consulting .report-limitations { margin-top: 0; color: #66757d; font-size: 11.5px; line-height: 1.72; }
.report-consulting .methodology-note {
  margin-top: 10px;
  padding: 9px 12px;
  border-left-color: rgba(143, 107, 50, .26);
  background: rgba(186, 151, 91, .035);
  color: #7b8589;
  font-size: 10.5px;
}
.report-consulting .report-provenance { font-size: 10.5px; }

@media (max-width: 820px) {
  .report-modal { width: calc(100vw - 20px); max-height: 94vh; }
  .report-modal .modal-shell { max-height: 94vh; }
  .report-modal .modal-head { padding: 15px 17px 13px; }
  .report-modal .modal-head h2 { font-size: 18px; }
  .report-consulting { padding: 14px 13px 24px; }
  .report-consulting .report-section { padding: 16px 14px; }
  .report-consulting .report-takeaway-grid,
  .report-consulting .report-choice-grid,
  .report-consulting .finding-list.is-consulting,
  .report-consulting .report-boundary-grid { grid-template-columns: 1fr; }
  .report-consulting .report-action-details { grid-template-columns: 1fr; gap: 9px; }
  .report-consulting .report-hero { align-items: flex-start; flex-direction: column; gap: 8px; }
  .report-consulting .report-hero p { max-width: none; text-align: left; }
  .report-consulting .report-metric-table,
  .report-consulting .report-metric-table tbody,
  .report-consulting .report-metric-table tr,
  .report-consulting .report-metric-table td { display: block; width: 100%; }
  .report-consulting .report-metric-table thead { display: none; }
  .report-consulting .report-metric-table tr {
    padding: 8px 0;
    border-bottom: 1px solid rgba(28, 52, 68, .09);
  }
  .report-consulting .report-metric-table tr:last-child { border-bottom: 0; }
  .report-consulting .report-metric-table td {
    padding: 4px 8px;
    border: 0;
  }
  .report-consulting .report-metric-table td::before {
    display: inline-block;
    width: 58px;
    color: #8a7653;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .05em;
  }
  .report-consulting .report-metric-table td:nth-child(1)::before { content: "指标"; }
  .report-consulting .report-metric-table td:nth-child(2)::before { content: "定义"; }
  .report-consulting .report-metric-table td:nth-child(3)::before { content: "目标"; }
  .report-consulting .report-metric-table td:nth-child(4)::before { content: "频率"; }
  .report-consulting .report-metric-cadence { white-space: normal; }
}

@media (max-width: 480px) {
  .report-consulting .report-card-head,
  .report-consulting .finding-card-head { gap: 7px; }
  .report-consulting .report-card-title { gap: 6px; }
  .report-consulting .report-roadmap-phase { grid-template-columns: 28px minmax(0, 1fr); gap: 8px; }
  .report-consulting .report-roadmap::before { left: 13px; }
  .report-consulting .report-roadmap-marker { width: 27px; height: 27px; font-size: 8px; }
  .report-consulting .report-brief-more { width: 100%; margin-left: 0; }
}

/* Job lifecycle controls */
.danger-button {
  min-height: 38px;
  padding: 0 13px;
  border: 1px solid rgba(137, 73, 62, .38);
  border-radius: var(--control-radius);
  background: rgba(255, 250, 247, .82);
  box-shadow: 0 1px 2px rgba(48, 24, 20, .04);
  color: #82483f;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: border-color .16s ease, background .16s ease, color .16s ease;
}
.danger-button:hover:not(:disabled) {
  border-color: rgba(125, 61, 51, .62);
  background: rgba(139, 72, 59, .075);
  color: #6e382f;
}
.danger-button:focus-visible {
  outline: 2px solid rgba(137, 73, 62, .34);
  outline-offset: 2px;
}
.danger-button:disabled { cursor: wait; opacity: .58; }
.danger-button.danger-button-solid {
  border-color: #7f433a;
  background: #7f433a;
  color: #fffaf2;
  box-shadow: 0 4px 12px rgba(89, 41, 34, .16);
}
.danger-button.danger-button-solid:hover:not(:disabled) {
  border-color: #6d352e;
  background: #6d352e;
  color: #ffffff;
}
.profile-building-cancel {
  flex: 0 0 auto;
  margin-left: auto;
}
.confirm-modal .modal-actions .danger-button {
  min-height: 38px;
  padding-right: 16px;
  padding-left: 16px;
  font-size: 13px;
}

.rail-entry {
  display: flex;
  align-items: stretch;
  border-bottom: 1px solid rgba(255, 255, 255, .055);
}
.rail-entry:last-child { border-bottom: 0; }
.rail-entry .rail-item {
  min-width: 0;
  flex: 1 1 auto;
  border-bottom: 0;
}
.rail-action {
  display: flex;
  width: 46px;
  min-height: 54px;
  flex: 0 0 46px;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 0;
  border-left: 1px solid rgba(255, 255, 255, .055);
  background: transparent;
  color: rgba(232, 218, 204, .52);
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: .04em;
  cursor: pointer;
  transition: background .16s ease, color .16s ease;
}
.rail-action:hover:not(:disabled) {
  background: rgba(139, 72, 59, .12);
  color: #e2b9ac;
}
.rail-action:focus-visible {
  outline: 1px solid rgba(222, 180, 160, .58);
  outline-offset: -3px;
}
.rail-action:disabled { cursor: wait; opacity: .42; }

.run-status.is-cancelled {
  border-color: #d0c1b2;
  background: #f5f0e9;
  color: #706256;
}
.run-percent.is-cancelled {
  color: #74665a;
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: .08em;
}
.stage-card.is-cancelled {
  border-color: #cfc1b2;
  background: #faf6f0;
  box-shadow: none;
}
.stage-card.is-cancelled .stage-number {
  border-color: #d3c7b9;
  background: #f4eee6;
  color: #79695b;
}
.stage-status.is-cancelled {
  border-color: #d3c6b8;
  background: #f6f1ea;
  color: #726356;
}
@media (max-width: 760px) {
  .profile-building { align-items: flex-start; flex-wrap: wrap; }
  .profile-building-cancel { margin-left: 29px; }
  .rail-action { width: 44px; flex-basis: 44px; }
}
