* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  background: #f4f7fb;
  color: #23262d;
  font-family: var(--sans);
}

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

button {
  cursor: pointer;
}

svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.9;
}

.icon-sprite {
  display: none;
}

.app-shell {
  min-height: 100vh;
}

body.auth-locked {
  background: #eaf1f5;
}

body.auth-locked .app-shell {
  display: none;
}

.auth-page {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  color: #182438;
  background: #eef2f6;
}

.auth-page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px 32px;
  background: #1c3361;
  color: white;
  border-bottom: 3px solid #2bb7c5;
}

.auth-page-brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  color: white;
}

.auth-page-mark {
  width: 44px;
  height: 42px;
  object-fit: contain;
  filter: brightness(0) invert(1);
}

.auth-page-titles {
  display: grid;
  gap: 2px;
  min-width: 0;
  line-height: 1.1;
}

.auth-page-titles strong {
  font-size: 1.12rem;
  font-weight: 850;
}

.auth-page-titles span {
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.auth-env-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 30px;
  padding: 5px 12px;
  color: white;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.32);
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 850;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.auth-page-main {
  display: grid;
  flex: 1;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 420px);
  gap: 56px;
  align-items: center;
  justify-content: center;
  width: min(1180px, calc(100% - 48px));
  margin: 0 auto;
  padding: 48px 0 64px;
}

.auth-hero {
  display: grid;
  gap: 16px;
  max-width: 580px;
}

.auth-hero-kicker {
  margin: 0;
  color: #247283;
  font-size: 0.74rem;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.auth-hero h1 {
  margin: 0;
  color: #14233f;
  font-size: 2.4rem;
  font-weight: 850;
  letter-spacing: -0.01em;
  line-height: 1.08;
}

.auth-hero-lede {
  max-width: 540px;
  margin: 0;
  color: #4e5866;
  font-size: 1.02rem;
  font-weight: 550;
  line-height: 1.55;
}

.auth-hero-points {
  display: grid;
  gap: 10px;
  margin: 6px 0 0;
  padding: 0;
  list-style: none;
}

.auth-hero-points li {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 10px 12px;
  background: white;
  border: 1px solid #dde6ec;
  border-radius: 8px;
}

.auth-hero-points svg {
  width: 22px;
  height: 22px;
  color: #247283;
}

.auth-hero-points span {
  display: grid;
  gap: 2px;
  color: #4e5866;
  font-size: 0.88rem;
}

.auth-hero-points strong {
  color: #14233f;
  font-size: 0.95rem;
}

.auth-card {
  width: 100%;
  max-width: 420px;
  padding: 32px 32px 28px;
  background: white;
  border: 1px solid #d7e0ea;
  border-radius: 10px;
  box-shadow: 0 12px 36px rgba(15, 23, 42, 0.08);
}

.auth-card-kicker {
  margin: 0 0 8px;
  color: #5b6573;
  font-size: 0.72rem;
  font-weight: 850;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.auth-card h2 {
  margin: 0 0 6px;
  color: #14233f;
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.005em;
}

.auth-card-lede {
  margin: 0 0 18px;
  color: #5b6573;
  font-size: 0.94rem;
  font-weight: 500;
  line-height: 1.5;
}

.auth-notice {
  display: grid;
  gap: 3px;
  margin-bottom: 16px;
  padding: 11px 13px;
  background: #f0f6fa;
  border: 1px solid #cfdce6;
  border-left: 4px solid #2bb7c5;
  border-radius: 6px;
}

.auth-notice strong {
  color: #14233f;
  font-size: 0.92rem;
}

.auth-notice span {
  color: #4e5866;
  font-size: 0.86rem;
  font-weight: 500;
}

.auth-notice.is-error {
  background: #fdf3f1;
  border-color: #e6bdb6;
  border-left-color: #c0392b;
}

.auth-notice.is-error strong {
  color: #9c2318;
}

.auth-notice.is-info {
  border-left-color: #2bb7c5;
}

.auth-form {
  display: grid;
  gap: 14px;
}

.auth-field {
  display: grid;
  gap: 6px;
}

.auth-field > span {
  color: #2c3645;
  font-size: 0.84rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.auth-field input {
  min-height: 42px;
  padding: 9px 12px;
  color: #172033;
  background: white;
  border: 1px solid #cfdbe5;
  border-radius: 6px;
  font-size: 0.96rem;
  transition: border-color 120ms ease, box-shadow 120ms ease;
}

.auth-field input:focus {
  border-color: #246b8a;
  box-shadow: 0 0 0 3px rgba(36, 107, 138, 0.18);
  outline: none;
}

.auth-field small {
  color: #6c7686;
  font-size: 0.78rem;
}

.auth-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  margin-top: 4px;
  padding: 10px 18px;
  color: white;
  background: #1c3361;
  border: 1px solid #15264a;
  border-radius: 6px;
  font-size: 0.98rem;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.auth-submit:hover:not(:disabled),
.auth-submit:focus-visible:not(:disabled) {
  background: #15264a;
}

.auth-submit:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

.auth-card-footer {
  margin-top: 20px;
  padding-top: 14px;
  color: #6c7686;
  font-size: 0.78rem;
  border-top: 1px solid #e5ebf2;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 5;
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 22px;
  align-items: center;
  min-height: 92px;
  padding: 12px 44px;
  background: #1c3361;
  color: white;
  border-bottom: 4px solid #2bb7c5;
  box-shadow: 0 10px 24px rgba(14, 39, 76, 0.18);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 24px;
  min-width: 0;
  color: white;
  text-decoration: none;
}

.ceirr-lockup {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 13px;
  min-width: 0;
}

.ceirr-logo-mark {
  width: 82px;
  height: 76px;
  object-fit: contain;
  filter: brightness(0) invert(1);
}

.ceirr-logo-text,
.app-title-lockup {
  display: grid;
  min-width: 0;
}

.ceirr-logo-text {
  align-items: center;
  line-height: 1;
  text-align: center;
  text-transform: uppercase;
}

.ceirr-wordmark {
  color: white;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 2.74rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  line-height: 0.88;
}

.ceirr-subtitle,
.ceirr-funded {
  color: white;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.ceirr-subtitle {
  font-size: 0.62rem;
  line-height: 1.15;
}

.ceirr-rule {
  display: block;
  width: 100%;
  height: 1px;
  margin: 4px 0;
  background: rgba(255, 255, 255, 0.42);
}

.ceirr-funded {
  font-size: 0.74rem;
  line-height: 1;
}

.app-title-lockup {
  gap: 3px;
  padding-left: 22px;
  border-left: 1px solid rgba(255, 255, 255, 0.36);
  line-height: 1.05;
}

.app-title-lockup strong {
  font-size: 1.34rem;
  font-weight: 850;
}

.app-title-lockup span {
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.status-cluster {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  min-width: 0;
  white-space: nowrap;
}

.status-pill,
.identity-pill,
.connection-pill,
.result-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  padding: 7px 12px;
  background: white;
  border: 1px solid #d7dee8;
  border-radius: 999px;
  color: #23262d;
  font-size: 0.9rem;
  font-weight: 800;
}

.identity-pill {
  max-width: min(430px, 45vw);
  padding: 6px 12px;
  color: white;
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.28);
}

.identity-pill svg {
  flex: 0 0 auto;
}

.identity-copy {
  display: grid;
  min-width: 0;
  line-height: 1.05;
}

.identity-copy strong,
.identity-copy span {
  overflow: hidden;
  text-overflow: ellipsis;
}

.identity-copy strong {
  font-size: 0.88rem;
}

.identity-copy span {
  color: rgba(255, 255, 255, 0.76);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.signout-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  padding: 7px 12px;
  color: white;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.42);
  border-radius: 8px;
  font-size: 0.88rem;
  font-weight: 850;
}

.signout-button:hover,
.signout-button:focus-visible {
  background: rgba(255, 255, 255, 0.12);
}

.status-pill[data-status="healthy"] {
  color: white;
  background: #15985f;
  border-color: #15985f;
}

.status-pill[data-status="error"] {
  color: white;
  background: #c4362e;
  border-color: #c4362e;
}

.status-pill[data-status="pending"] {
  color: #5c3d00;
  background: #fff4d6;
  border-color: #f6c75f;
}

.status-pill .dot {
  background: currentColor;
}

.tool-menu {
  position: sticky;
  top: 92px;
  z-index: 4;
  display: flex;
  gap: 12px;
  align-items: center;
  overflow-x: auto;
  padding: 14px 44px;
  background: linear-gradient(180deg, #f8fbfd 0%, #edf4f8 100%);
  border-bottom: 1px solid #cbd8e4;
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.08);
}

.menu-tab {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 10px 18px;
  color: #29364a;
  background: #ffffff;
  border: 1px solid #cbd8e4;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
  font-weight: 850;
  transition:
    background-color 120ms ease,
    border-color 120ms ease,
    box-shadow 120ms ease,
    color 120ms ease,
    transform 120ms ease;
}

.menu-tab svg {
  width: 22px;
  height: 22px;
}

.menu-tab:hover,
.menu-tab:focus-visible {
  color: #12345c;
  background: #f1fbfd;
  border-color: #2bb7c5;
  box-shadow: 0 10px 22px rgba(31, 61, 104, 0.14);
  transform: translateY(-1px);
}

.menu-tab:focus-visible {
  outline: 3px solid rgba(43, 183, 197, 0.3);
  outline-offset: 2px;
}

.menu-tab.is-active {
  color: white;
  background: linear-gradient(90deg, #1c3361 0%, #246b8a 100%);
  border-color: #2bb7c5;
  box-shadow:
    0 0 0 3px rgba(43, 183, 197, 0.24),
    0 12px 24px rgba(31, 61, 104, 0.24);
}

.menu-tab.is-active:hover,
.menu-tab.is-active:focus-visible {
  color: white;
  background: linear-gradient(90deg, #1c3361 0%, #246b8a 100%);
}

.dot {
  flex: 0 0 auto;
  width: 8px;
  height: 8px;
  background: #ffb020;
  border-radius: 50%;
}

[data-status="healthy"] .dot,
.status-pass {
  background: #1d8f5a;
}

[data-status="error"] .dot,
.status-fail {
  background: #dc3545;
}

.status-pill[data-status] .dot {
  background: currentColor;
}

.content {
  display: grid;
  gap: 22px;
  padding: 28px 32px 44px;
}

.page-section {
  display: grid;
  gap: 22px;
}

.page-view {
  min-width: 0;
}

.section-card,
.panel {
  min-width: 0;
  background: white;
  border: 1px solid #e1e6ef;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
  overflow: hidden;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 18px;
  color: white;
  background: linear-gradient(90deg, #213f6d 0%, #246b8a 72%, #2bb7c5 100%);
}

.section-header h2 {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin: 0;
  font-size: 1.18rem;
}

.section-header p {
  margin: 4px 0 0;
  color: rgba(255, 255, 255, 0.86);
  font-weight: 650;
}

.history-card .section-header {
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
}

.history-card .section-header p {
  margin: 0;
}

.panel {
  padding: 18px;
}

.panel .section-header {
  margin: -18px -18px 18px;
}

.export-mode-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 430px);
  gap: 30px;
  align-items: center;
  padding: 28px 26px;
}

.export-mode-card.is-study-mode .export-mode-layout {
  grid-template-columns: 1fr;
  align-items: stretch;
}

.export-mode-card.is-study-mode .export-action-card {
  justify-items: start;
  padding-top: 2px;
}

.export-mode-card.is-study-mode .export-action-card p {
  max-width: none;
  text-align: left;
}

.mode-choice-row {
  display: flex;
  flex-wrap: wrap;
  gap: 26px;
  align-items: center;
  margin-bottom: 20px;
}

.mode-choice {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 7px 10px;
  color: #424852;
  background: #f8fafc;
  border: 1px solid transparent;
  border-radius: 8px;
  cursor: pointer;
  font-size: 1.02rem;
  font-weight: 850;
  transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease, box-shadow 0.16s ease;
}

.mode-choice:hover {
  color: #263547;
  background: #f0f6f8;
  border-color: #d7e3ea;
}

.mode-choice.is-selected {
  color: #153e58;
  background: #edfafd;
  border-color: #a9e5ec;
  box-shadow: 0 6px 16px rgba(43, 183, 197, 0.12);
}

.radio-dot {
  width: 18px;
  height: 18px;
  border: 2px solid #c7ced8;
  border-radius: 50%;
  background: white;
}

.mode-choice.is-selected .radio-dot {
  border: 6px solid #2bb7c5;
}

.uuid-box {
  display: block;
  margin: 0 0 20px;
}

.standard-export-options {
  display: block;
}

.study-source-options {
  display: grid;
  gap: 14px;
  min-width: 0;
  margin: 0 0 20px;
  padding: 16px;
  background: #fbfcff;
  border: 1px solid #dfe4ec;
  border-radius: 8px;
}

.study-source-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.study-source-header h3 {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin: 0;
  color: #23262d;
  font-size: 1.03rem;
}

.study-source-header svg {
  width: 20px;
  height: 20px;
  color: #246b8a;
}

.all-types-toggle,
.inline-check {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: #3f4650;
  font-weight: 850;
}

.all-types-toggle {
  margin-bottom: 16px;
  font-size: 1.04rem;
}

.template-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(220px, 1fr));
  gap: 10px 28px;
  max-width: 840px;
  padding: 18px 22px;
  border: 1px solid #dfe4ec;
  border-radius: 8px;
}

.template-option {
  display: inline-grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-height: 28px;
  color: #444b55;
  font-weight: 700;
}

.template-option span {
  margin: 0;
  font-size: 0.95rem;
  text-transform: none;
}

.template-option strong {
  font-weight: 700;
}

.export-action-card {
  display: grid;
  justify-items: center;
  gap: 12px;
}

.export-action-card p {
  max-width: 360px;
  margin: 0;
  color: #697380;
  text-align: center;
  font-weight: 650;
}

.export-action-card .action-validation {
  max-width: 300px;
  padding: 10px 12px;
  color: #8d321f;
  background: #fff4ed;
  border: 1px solid #f1c2ad;
  border-radius: 8px;
  font-size: 0.9rem;
  text-align: left;
}

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

.section-card > :not(.section-header) {
  margin-left: 26px;
  margin-right: 26px;
}

.section-card > .section-header + * {
  margin-top: 22px;
}

.section-card > :last-child {
  margin-bottom: 24px;
}

.policy-grid,
.contract-layout {
  display: grid;
  gap: 24px;
}

.policy-grid {
  grid-template-columns: minmax(0, 1fr) minmax(210px, 290px);
  align-items: start;
}

.contract-layout {
  grid-template-columns: minmax(210px, 280px) minmax(0, 1fr);
}

fieldset {
  margin: 0;
  padding: 0;
  border: 0;
}

legend,
label span,
.control-label {
  display: block;
  margin-bottom: 8px;
  color: #4b535e;
  font-size: 0.84rem;
  font-weight: 850;
  text-transform: uppercase;
}

.choice-list {
  display: grid;
  gap: 9px;
  min-height: 42px;
  padding: 12px;
  background: #fbfcff;
  border: 1px solid #dfe4ec;
  border-radius: 8px;
}

.status-list {
  max-height: 170px;
  overflow: auto;
}

.contract-list {
  grid-template-columns: 1fr;
}

.choice-option {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 24px;
  color: #424852;
  font-weight: 700;
}

.choice-option span,
.inline-check span,
.all-types-toggle span {
  display: inline;
  margin-bottom: 0;
  color: inherit;
  font-size: inherit;
  font-weight: inherit;
  text-transform: none;
}

.choice-option input,
.inline-check input,
.all-types-toggle input,
.template-option input {
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: #2a7f92;
}

input[type="date"],
input[type="search"],
input[type="text"],
select,
textarea {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  background: white;
  border: 1px solid #cfd7e3;
  border-radius: 8px;
  color: #23262d;
}

input[type="date"]:focus-visible,
input[type="search"]:focus-visible,
input[type="text"]:focus-visible,
select:focus-visible,
textarea:focus-visible {
  border-color: #2bb7c5;
  outline: 3px solid rgba(43, 183, 197, 0.3);
  outline-offset: 1px;
}

input[type="checkbox"]:focus-visible {
  outline: 3px solid rgba(43, 183, 197, 0.45);
  outline-offset: 2px;
}

.primary:focus-visible,
.secondary:focus-visible,
.mode-choice:focus-visible {
  outline: 3px solid rgba(43, 183, 197, 0.45);
  outline-offset: 2px;
}

.study-search-panel {
  display: grid;
  gap: 14px;
  margin: 0 0 20px;
  padding: 18px 20px;
  background: white;
  border: 1px solid #dfe4ec;
  border-radius: 8px;
}

.study-toolbar {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto auto;
  gap: 12px;
  align-items: end;
}

.study-source-options .study-toolbar {
  grid-template-columns: minmax(260px, 1fr) auto;
}

.study-search-field {
  min-width: 0;
}

.study-search-heading,
.study-search-controls,
.study-selection-summary,
.study-main,
.study-actions {
  display: flex;
  gap: 12px;
  align-items: center;
}

.study-search-heading,
.study-main {
  justify-content: space-between;
}

.study-search-heading h3 {
  margin: 0;
  color: #23262d;
  font-size: 1.02rem;
}

.study-search-controls {
  align-items: end;
}

.study-search-controls label {
  flex: 1 1 360px;
}

.study-search-controls button {
  flex: 0 0 auto;
}

.compact-button {
  min-height: 36px;
  padding: 7px 11px;
  font-size: 0.9rem;
}

.study-selection-summary {
  flex-wrap: wrap;
  justify-content: flex-start;
  min-height: 34px;
  padding: 8px 10px;
  color: #607080;
  background: white;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  font-weight: 700;
}

.study-selection-summary strong {
  color: #1f3d68;
}

.study-selection-summary span,
.study-bulk-bar span {
  margin: 0;
  text-transform: none;
}

.study-table-wrap {
  max-width: 100%;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid #dfe4ec;
  border-radius: 8px;
}

.study-table-wrap:focus-visible {
  outline: 3px solid rgba(43, 183, 197, 0.45);
  outline-offset: 2px;
}

.study-table {
  width: 100%;
  min-width: 1040px;
  border-collapse: collapse;
  background: white;
}

.study-table th,
.study-table td {
  padding: 12px 14px;
  border-bottom: 1px solid #edf0f4;
  text-align: left;
  vertical-align: top;
  overflow-wrap: anywhere;
}

.study-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  color: #4b535e;
  background: #f6f8fb;
  font-size: 0.78rem;
  font-weight: 850;
  text-transform: uppercase;
}

.study-table td {
  color: #3f4650;
  font-weight: 650;
}

.study-table td strong {
  display: block;
  color: #23262d;
  font-size: 1rem;
  overflow-wrap: anywhere;
}

.study-table td small {
  display: block;
  margin-top: 4px;
  color: #697380;
  font-weight: 650;
}

.study-table-row.is-selected td {
  background: #f1fbfd;
}

.select-column {
  width: 78px;
}

.actions-column {
  width: 230px;
}

.select-column input,
.study-template-option input {
  width: 18px;
  height: 18px;
  margin: 2px 0 0;
  accent-color: #2a7f92;
}

.study-actions-cell {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.study-actions-cell .compact-button {
  white-space: nowrap;
}

.study-template-row td {
  padding-top: 0;
  background: #fbfcff;
}

.action-dock {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 6;
  display: flex;
  flex-wrap: wrap;
  gap: 14px 18px;
  align-items: center;
  justify-content: space-between;
  padding: 14px 32px;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(8px);
  border-top: 1px solid #dfe4ec;
  box-shadow: 0 -12px 28px rgba(15, 23, 42, 0.08);
}

body.has-action-dock .content {
  padding-bottom: 110px;
}

.action-dock-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 16px;
  align-items: baseline;
  color: #5f6877;
  font-weight: 700;
}

.action-dock-summary strong {
  color: #14233f;
  font-size: 1.04rem;
  font-weight: 850;
}

.action-dock-summary .dock-meta {
  color: #697380;
  font-size: 0.86rem;
  font-weight: 650;
}

.action-dock-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: flex-end;
}

.action-dock-buttons .secondary,
.action-dock-buttons .primary {
  min-height: 40px;
}

.run-queue {
  position: fixed;
  right: 24px;
  bottom: 92px;
  z-index: 7;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
  pointer-events: none;
}

.run-queue.is-minimized .run-queue-panel {
  display: none;
}

.run-queue:not(.is-minimized) .run-queue-chip {
  display: none;
}

.run-queue-panel {
  width: min(420px, calc(100vw - 48px));
  pointer-events: auto;
  background: linear-gradient(180deg, #f3fbfd 0%, #ffffff 78%);
  border: 1px solid #c7e1e8;
  border-radius: 12px;
  box-shadow: 0 24px 60px rgba(15, 39, 76, 0.22);
  overflow: hidden;
}

.run-queue-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px 8px;
}

.run-queue-heading {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.run-queue-heading .eyebrow {
  margin: 0;
  color: #247283;
}

.run-queue-heading strong {
  color: #14233f;
  font-size: 1.1rem;
  font-weight: 850;
}

.run-queue-heading span {
  color: #5b6573;
  font-size: 0.88rem;
  font-weight: 600;
}

.run-queue-minimize {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  padding: 0;
  background: white;
  border: 1px solid #cfdce6;
  border-radius: 999px;
  color: #2c3645;
  font-size: 1.2rem;
  line-height: 1;
}

.run-queue-minimize:hover,
.run-queue-minimize:focus-visible {
  background: #eaf3f6;
}

.run-queue-list {
  display: grid;
  gap: 10px;
  padding: 4px 18px 18px;
}

.run-queue-item {
  display: grid;
  gap: 10px;
  padding: 12px 14px;
  background: white;
  border: 1px solid #d9e6ec;
  border-radius: 10px;
}

.run-queue-item-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.run-queue-item-header strong {
  color: #14233f;
  font-size: 0.98rem;
}

.run-queue-item-message {
  color: #4e5866;
  font-size: 0.86rem;
}

.run-queue-meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.run-queue-meta > div {
  padding: 8px 10px;
  background: #f4f8fa;
  border: 1px solid #e0e9ee;
  border-radius: 6px;
}

.run-queue-meta span {
  display: block;
  color: #697380;
  font-size: 0.7rem;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.run-queue-meta strong {
  display: block;
  margin-top: 2px;
  color: #14233f;
  font-size: 0.9rem;
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.run-queue-running-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  background: #e7f1fb;
  border-radius: 999px;
  color: #1a4a78;
  font-size: 0.72rem;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.run-queue-running-chip.is-interrupted {
  background: #fbe7d2;
  color: #8a4b14;
}

.run-queue-item.is-interrupted {
  border-color: #f1c896;
  background: #fff7ec;
}

.run-queue-item-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 8px;
}

.run-queue-item-actions .secondary {
  padding: 6px 12px;
  font-size: 0.78rem;
}

.run-queue-chip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  pointer-events: auto;
  background: #14233f;
  border: 1px solid #14233f;
  border-radius: 999px;
  color: white;
  box-shadow: 0 18px 40px rgba(15, 39, 76, 0.32);
  font-weight: 700;
}

.run-queue-chip .dot {
  width: 10px;
  height: 10px;
  background: #2bc46d;
  box-shadow: 0 0 0 3px rgba(43, 196, 109, 0.28);
  border-radius: 50%;
  animation: pulse-dot 1.4s ease-in-out infinite;
}

.run-queue-chip-copy {
  display: grid;
  line-height: 1.1;
  text-align: left;
}

.run-queue-chip-copy strong {
  font-size: 0.92rem;
}

.run-queue-chip-copy span {
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.run-queue-chip-chevron {
  margin-left: 4px;
  font-size: 1rem;
}

@keyframes pulse-dot {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.18); opacity: 0.65; }
}

.study-list {
  display: grid;
  gap: 10px;
}

.study-row {
  display: grid;
  gap: 12px;
  padding: 14px;
  background: white;
  border: 1px solid #dfe4ec;
  border-radius: 8px;
}

.study-row.is-selected {
  border-color: #75cbd5;
  box-shadow: inset 4px 0 0 #2bb7c5;
}

.study-select {
  display: inline-flex;
  gap: 10px;
  align-items: flex-start;
  min-width: min(420px, 100%);
}

.study-template-option input {
  width: 18px;
  height: 18px;
  margin: 2px 0 0;
  accent-color: #2a7f92;
}

.study-select span,
.study-template-option span {
  display: grid;
  gap: 3px;
  margin-bottom: 0;
  text-transform: none;
}

.study-select strong {
  color: #23262d;
  font-size: 1rem;
}

.study-select small,
.study-template-option small {
  color: #68727f;
  font-weight: 650;
}

.study-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  color: #68727f;
  font-weight: 650;
}

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

.study-template-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(220px, 1fr));
  gap: 10px;
  padding: 12px;
  background: #fbfcff;
  border: 1px solid #edf0f4;
  border-radius: 8px;
}

.study-template-option {
  display: inline-flex;
  gap: 9px;
  align-items: flex-start;
}

.study-template-option strong {
  color: #3f4650;
}

.queue-chip {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 9px;
  border-radius: 999px;
  color: #607080;
  background: #f2f4f7;
  font-size: 0.84rem;
  font-weight: 850;
}

.queue-chip.is-running,
.update-chip.is-running {
  color: #614800;
  background: #ffe8a3;
}

.queue-chip.is-complete,
.update-chip.is-complete {
  color: white;
  background: #15985f;
}

.queue-chip.is-failed,
.update-chip.is-failed {
  color: white;
  background: #c0392b;
}

textarea {
  resize: vertical;
}

.option-line {
  margin-top: 20px;
}

.field-hint {
  display: block;
  margin-top: 8px;
  color: #697380;
  font-size: 0.86rem;
  font-weight: 650;
  line-height: 1.35;
}

.field-hint.indented {
  margin-left: 28px;
}

.date-filter-row {
  display: grid;
  grid-template-columns: max-content minmax(180px, 260px);
  gap: 12px;
  align-items: center;
  margin-top: 26px;
}

.contract-copy {
  color: #67717e;
  font-size: 0.9rem;
  line-height: 1.5;
}

.contract-copy strong {
  display: block;
  margin-bottom: 4px;
  color: #4b535e;
}

.contract-copy ul {
  margin: 0;
  padding-left: 18px;
}

.hidden {
  display: none !important;
}

.action-row {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 18px;
}

.primary,
.secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 10px 16px;
  border-radius: 8px;
  font-weight: 850;
}

.primary {
  color: white;
  background: #15985f;
  border: 1px solid #10784b;
}

.big-action {
  min-height: 60px;
  padding: 14px 24px;
  background: linear-gradient(90deg, #213f6d 0%, #246b8a 55%, #2bb7c5 100%);
  border: 0;
  font-size: 1.14rem;
}

.secondary {
  color: #1f3d68;
  background: white;
  border: 1px solid #1f3d68;
}

.drop-zone {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 18px 14px;
  margin: 6px 0;
  background: #f8fafc;
  border: 2px dashed #c8d3e0;
  border-radius: 8px;
  text-align: center;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.drop-zone:hover,
.drop-zone:focus-visible {
  background: #eef4fb;
  border-color: #1f3d68;
  outline: none;
}

.drop-zone.is-drag-over {
  background: #e1ecf8;
  border-color: #1a4a78;
  border-style: solid;
}

.drop-zone p {
  margin: 0;
  font-size: 0.88rem;
  color: #1a1f2c;
}

.drop-zone .drop-zone-hint {
  font-size: 0.78rem;
  color: #495057;
}

.drop-zone code {
  background: #eef0f3;
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 0.78rem;
}

.danger-outline {
  color: #9c2318;
  background: white;
  border: 1px solid #c97365;
  padding: 9px 14px;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
}

.danger-outline:hover {
  background: #fff4f2;
}

.danger-outline:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.secondary:disabled,
.primary:disabled,
.danger-outline:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

button.is-busy {
  cursor: progress;
  opacity: 0.82;
}

button.is-busy svg {
  display: none;
}

button.is-busy::before {
  content: "";
  width: 16px;
  height: 16px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: spin 0.75s linear infinite;
}

#actionDockButtons button.is-busy {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  box-shadow: 0 0 0 1px rgba(48, 85, 143, 0.12), 0 10px 28px rgba(48, 85, 143, 0.18);
}

#actionDockButtons button.is-busy::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(110deg, transparent 0%, rgba(255, 255, 255, 0.62) 42%, transparent 72%);
  transform: translateX(-120%);
  animation: dockBusySweep 1.15s ease-in-out infinite;
}

.operation-banner,
.environment-notice {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  min-height: 52px;
  padding: 12px 16px;
  background: white;
  border: 1px solid #dfe4ec;
  border-left: 6px solid #2bb7c5;
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}

.environment-notice {
  display: flex;
  justify-content: space-between;
}

.operation-copy,
.environment-notice {
  min-width: 0;
}

.operation-copy {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 14px;
  align-items: center;
}

.operation-copy span {
  min-width: min(100%, 340px);
  overflow-wrap: anywhere;
}

.operation-banner span,
.environment-notice span {
  color: #697380;
}

.operation-progress {
  display: none;
  height: 4px;
  overflow: hidden;
  background: #dce8ef;
  border-radius: 999px;
}

.operation-progress span {
  display: block;
  width: 42%;
  height: 100%;
  background: #2bb7c5;
  border-radius: inherit;
  animation: progress-slide 1.1s ease-in-out infinite;
}

.operation-banner.is-running .operation-progress {
  display: block;
}

.operation-banner.is-success {
  border-left-color: #15985f;
}

.operation-banner.is-error,
.environment-notice {
  border-left-color: #c0392b;
}

.operation-banner.is-info {
  border-left-color: #2bb7c5;
}

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

.preview-grid article {
  min-height: 74px;
  padding: 13px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
}

.preview-grid span {
  display: block;
  color: #697380;
  font-size: 0.78rem;
  font-weight: 850;
  text-transform: uppercase;
}

.preview-grid strong {
  display: block;
  margin-top: 8px;
  font-family: var(--mono);
  font-size: 1.36rem;
}

.confirmation-strip,
.side-effect-preview,
.detail-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.confirmation-strip {
  align-items: center;
  margin-top: 16px;
  color: #697380;
  font-weight: 700;
}

.confirmation-strip span,
.confirmation-strip div span,
.side-effect-preview article {
  padding: 6px 9px;
  background: #effbfd;
  border: 1px solid #bfeaf0;
  border-radius: 999px;
  color: #1f3d68;
}

.side-effect-preview {
  margin-top: 14px;
}

.side-effect-preview article {
  display: grid;
  border-radius: 8px;
}

.side-effect-preview span,
.side-effect-preview small {
  color: #4d5b6b;
}

.warning-list,
.artifact-list,
.exclusion-list,
.uuid-resolution-list,
.run-list,
.accession-preview {
  display: grid;
  gap: 12px;
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}

.empty-list {
  color: #697380;
}

.review-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 14px;
  margin-top: 16px;
}

.review-grid h3 {
  margin: 0 0 10px;
}

.review-section[hidden] {
  display: none;
}

.exclusion-summary {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 12px;
}

.exclusion-summary p {
  margin: 0 0 8px 0;
  font-size: 0.92rem;
  color: #1a1f2c;
}

.exclusion-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.exclusion-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  background: #eef0f3;
  border-radius: 999px;
  font-size: 0.78rem;
  color: #495057;
}

.exclusion-chip strong {
  color: #1a1f2c;
}

.exclusion-details {
  margin-top: 10px;
  font-size: 0.85rem;
}

.exclusion-details summary {
  cursor: pointer;
  color: #1a4a78;
  font-weight: 600;
  padding: 6px 0;
}

.exclusion-detail-list {
  display: grid;
  gap: 8px;
  margin-top: 8px;
}

.artifact-row,
.exclusion-row,
.uuid-row,
.quiet-row {
  display: grid;
  gap: 6px;
  padding: 11px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
}

.run-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 16px 18px;
  background: white;
  border: 1px solid #edf0f4;
  border-radius: 8px;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.06);
}

.run-row header {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 10px;
  align-items: center;
  margin-bottom: 7px;
}

.run-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  color: #23262d;
}

.download-chip,
.date-chip,
.update-chip,
.records-chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 10px;
  border-radius: 999px;
  font-weight: 800;
}

.download-chip {
  color: white;
  background: #15985f;
}

.date-chip,
.records-chip {
  color: #67717e;
  background: #f2f4f7;
  font-style: italic;
}

.update-chip {
  color: white;
  background: #2bb7c5;
}

.records-chip {
  margin-top: 7px;
  border-left: 4px solid #7d8996;
  border-radius: 4px;
}

.history-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

.run-download {
  min-width: 140px;
}

.history-details {
  margin-top: 14px;
  padding: 0;
  background: transparent;
  border-radius: 0;
}

.run-detail-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 16px;
  background: #f8f9fa;
  border-radius: 10px;
}

.run-detail-grid {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(320px, 1.4fr);
  gap: 18px;
}

@media (max-width: 900px) {
  .run-detail-grid {
    grid-template-columns: 1fr;
  }
}

.run-detail-section {
  background: #ffffff;
  border: 1px solid #e3e6ec;
  border-radius: 8px;
  padding: 14px 16px;
}

.run-detail-section header {
  margin-bottom: 10px;
}

.run-detail-section header strong {
  font-size: 0.95rem;
  color: #1a1f2c;
}

.run-detail-section dl {
  margin: 0;
  display: grid;
  grid-template-columns: minmax(140px, 0.45fr) 1fr;
  row-gap: 6px;
  column-gap: 12px;
}

.run-detail-section dl > div {
  display: contents;
}

.run-detail-section dt {
  font-weight: 700;
  color: #495057;
  font-size: 0.82rem;
}

.run-detail-section dd {
  margin: 0;
  color: #23262d;
  font-size: 0.88rem;
  overflow-wrap: anywhere;
}

.run-detail-headline {
  margin: 0 0 4px 0;
  font-size: 1rem;
}

.run-detail-subline {
  margin: 0 0 10px 0;
  font-size: 0.9rem;
  color: #495057;
}

.run-detail-subhead {
  margin: 14px 0 6px 0;
  font-size: 0.88rem;
}

.run-detail-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}

.run-detail-table th,
.run-detail-table td {
  text-align: left;
  padding: 6px 10px;
  border-bottom: 1px solid #eef0f3;
}

.run-detail-table th {
  font-weight: 700;
  color: #495057;
  background: #f3f5f8;
}

.run-detail-table tbody tr:nth-child(even) td {
  background: #fafbfc;
}

.run-detail-status-card {
  background: #effdf3;
  border: 1px solid #c8ecd0;
  border-radius: 8px;
  padding: 12px 14px;
}

.run-detail-status-title {
  margin: 0 0 8px 0;
  font-weight: 700;
  color: #1c5a30;
  display: flex;
  align-items: center;
  gap: 8px;
}

.run-detail-status-title .status-dot {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  background: #2bc46d;
  color: white;
  border-radius: 50%;
  font-size: 0.7rem;
}

.run-detail-status-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px 24px;
  margin-bottom: 10px;
}

.run-detail-status-grid > div {
  display: flex;
  flex-direction: column;
}

.run-detail-status-grid dt {
  font-size: 0.78rem;
  font-weight: 700;
  color: #495057;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.run-detail-status-grid dd {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 700;
  color: #1a1f2c;
}

.run-detail-status-meta {
  margin: 0;
  font-size: 0.82rem;
  color: #495057;
}

.quiet-note {
  margin: 0;
  color: #495057;
  font-style: italic;
  font-size: 0.85rem;
}

.accession-workbench > :not(.section-header),
.admin-grid > :not(.section-header) {
  margin-left: 26px;
  margin-right: 26px;
}

.accession-purpose {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 16px;
  align-items: center;
  padding: 14px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
}

.accession-purpose strong,
.accession-purpose span {
  display: block;
}

.accession-purpose span {
  margin-top: 4px;
  color: #697380;
  font-weight: 650;
}

.step-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}

.step-strip span {
  padding: 6px 8px;
  background: white;
  border: 1px solid #dfe4ec;
  border-radius: 999px;
  color: #424852;
  font-size: 0.75rem;
  font-weight: 850;
  text-transform: uppercase;
}

.accession-grid {
  display: grid;
  grid-template-columns: minmax(360px, 0.42fr) minmax(0, 1fr);
  gap: 14px;
}

.accession-counts {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.accession-row-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.accession-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr) auto;
  gap: 10px;
  align-items: center;
  padding: 12px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
}

.accession-row span {
  color: #697380;
  overflow-wrap: anywhere;
}

.admin-grid article {
  display: grid;
  gap: 12px;
  padding: 16px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
}

.admin-layout {
  display: grid;
  grid-template-columns: minmax(280px, 0.38fr) minmax(0, 1fr);
  gap: 14px;
}

.admin-form {
  display: grid;
  gap: 12px;
}

.admin-note {
  margin: 0;
  color: #697380;
  font-weight: 650;
}

.admin-note.is-error {
  color: #8d321f;
}

.admin-note.is-success {
  color: #166534;
}

.admin-user-list {
  display: grid;
  gap: 10px;
}

.admin-user-row {
  grid-template-columns: minmax(180px, 1fr) max-content max-content minmax(130px, 160px) max-content max-content;
  align-items: center;
}

.admin-user-main {
  min-width: 0;
}

.admin-user-main strong,
.admin-user-main span {
  display: block;
  overflow-wrap: anywhere;
}

.admin-user-main span {
  margin-top: 3px;
  color: #697380;
  font-size: 0.82rem;
  font-weight: 650;
}

.admin-enabled-toggle {
  margin: 0;
}

.role-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(220px, max-content));
  gap: 10px;
}

.role-list span {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 7px 10px;
  background: white;
  border: 1px solid #dfe4ec;
  border-radius: 6px;
  color: #23262d;
  font-family: var(--mono);
  font-size: 0.82rem;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 10;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(15, 23, 42, 0.58);
}

.modal {
  width: min(560px, 100%);
  padding: 22px;
  background: white;
  border: 1px solid #dfe4ec;
  border-radius: 12px;
  box-shadow: 0 24px 80px rgba(15, 23, 42, 0.34);
}

.modal.modal-compact {
  display: grid;
  gap: 12px;
  width: min(420px, 100%);
  padding: 20px 22px;
}

.modal.modal-compact .action-row {
  justify-content: flex-end;
  margin-top: 4px;
}

.modal .eyebrow {
  margin: 0 0 6px;
  color: #697380;
  font-size: 0.76rem;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.modal h2 {
  margin: 0;
}

.modal p {
  color: #697380;
}

.modal ul {
  display: grid;
  gap: 8px;
  margin: 16px 0;
  padding-left: 20px;
}

.confirm-filters[hidden] {
  display: none;
}

.confirm-filters {
  margin: 14px 0;
  padding: 12px 14px;
  background: #f3f5f8;
  border: 1px solid #e3e6ec;
  border-radius: 8px;
}

.confirm-filters-title,
.confirm-actions-title {
  margin: 0 0 8px 0;
  font-size: 0.88rem;
  color: #1a1f2c;
}

.confirm-filters dl {
  display: grid;
  grid-template-columns: minmax(140px, 0.5fr) 1fr;
  row-gap: 6px;
  column-gap: 12px;
  margin: 0;
}

.confirm-filters dl > div {
  display: contents;
}

.confirm-filters dt {
  font-size: 0.82rem;
  font-weight: 700;
  color: #495057;
}

.confirm-filters dd {
  margin: 0;
  font-size: 0.88rem;
  color: #1a1f2c;
  overflow-wrap: anywhere;
}

.confirm-actions-title {
  margin-top: 14px;
}

.confirm-check {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 12px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  font-weight: 700;
}

.confirm-prod {
  display: grid;
  gap: 8px;
  margin-top: 12px;
  padding: 12px;
  background: #fff4f2;
  border: 1px solid #e6a29a;
  border-radius: 8px;
}

.confirm-prod span {
  margin: 0;
  color: #9c2318;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes dockBusySweep {
  to {
    transform: translateX(120%);
  }
}

@keyframes progress-slide {
  0% {
    transform: translateX(-115%);
  }
  100% {
    transform: translateX(245%);
  }
}

@media (max-width: 1100px) {
  .auth-page-main {
    grid-template-columns: 1fr;
    gap: 28px;
    padding: 36px 0 56px;
  }

  .auth-hero {
    max-width: 640px;
  }

  .auth-card {
    max-width: 480px;
  }

  .topbar {
    position: static;
    grid-template-columns: 1fr;
    justify-items: start;
  }

  .tool-menu {
    top: 0;
  }

  .status-cluster {
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .identity-pill {
    max-width: min(520px, 100%);
  }

  .export-mode-layout,
  .policy-layout,
  .policy-grid,
  .contract-layout,
  .review-grid,
  .history-details {
    grid-template-columns: 1fr;
  }

  .export-action-card {
    justify-items: start;
  }

  .export-action-card p {
    text-align: left;
  }
}

@media (max-width: 720px) {
  .auth-page-header {
    padding: 12px 18px;
  }

  .auth-page-titles strong {
    font-size: 1rem;
  }

  .auth-card {
    padding: 24px 22px 22px;
  }

  .auth-hero h1 {
    font-size: 1.9rem;
  }

  .auth-card h2 {
    font-size: 1.3rem;
  }

  .topbar {
    padding: 12px 16px;
  }

  .brand {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .ceirr-lockup {
    gap: 10px;
  }

  .ceirr-logo-mark {
    width: 58px;
    height: 54px;
  }

  .ceirr-wordmark {
    font-size: 2.04rem;
    letter-spacing: 0.13em;
  }

  .ceirr-subtitle {
    font-size: 0.48rem;
  }

  .ceirr-funded {
    font-size: 0.6rem;
  }

  .app-title-lockup {
    width: 100%;
    padding-top: 9px;
    padding-left: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.28);
    border-left: 0;
  }

  .tool-menu {
    gap: 8px;
    padding: 12px 14px;
  }

  .status-cluster {
    width: 100%;
  }

  .identity-pill {
    flex: 1 1 220px;
  }

  .menu-tab {
    gap: 7px;
    min-height: 44px;
    padding: 9px 11px;
    font-size: 0.95rem;
  }

  .menu-tab svg {
    width: 20px;
    height: 20px;
  }

  .content {
    padding: 18px 16px 32px;
  }

  body.has-action-dock .content {
    padding-bottom: 188px;
  }

  .export-mode-layout {
    padding: 22px 16px;
  }

  .mode-choice-row {
    align-items: flex-start;
    gap: 14px 18px;
  }

  .study-source-options {
    padding: 12px;
  }

  .study-source-header {
    align-items: stretch;
    flex-direction: column;
  }

  .study-source-options .study-toolbar {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .template-grid,
  .preview-grid,
  .accession-grid,
  .accession-counts,
  .accession-row,
  .admin-layout,
  .admin-user-row,
  .study-template-list,
  .role-list,
  .date-filter-row,
  .run-row {
    grid-template-columns: 1fr;
  }

  .section-card > :not(.section-header),
  .accession-workbench > :not(.section-header),
  .admin-grid > :not(.section-header) {
    margin-left: 16px;
    margin-right: 16px;
  }

  .accession-purpose {
    grid-template-columns: 1fr;
  }

  .step-strip,
  .study-search-heading,
  .study-search-controls,
  .study-main,
  .action-row,
  .history-actions {
    align-items: stretch;
    flex-direction: column;
    justify-content: flex-start;
  }

  .study-actions {
    justify-content: flex-start;
  }

  .action-dock {
    align-items: stretch;
    padding: 12px 16px max(12px, env(safe-area-inset-bottom));
  }

  .action-dock-summary {
    flex: 1 1 100%;
  }

  .action-dock-buttons {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
  }

  .action-dock-buttons .secondary,
  .action-dock-buttons .primary {
    justify-content: center;
    width: 100%;
    min-width: 0;
  }
}

@media (max-width: 420px) {
  .ceirr-logo-mark {
    width: 50px;
    height: 48px;
  }

  .ceirr-wordmark {
    font-size: 1.78rem;
  }

  .ceirr-subtitle {
    font-size: 0.42rem;
  }

  .ceirr-funded {
    font-size: 0.54rem;
  }

  body.has-action-dock .content {
    padding-bottom: 236px;
  }

  .mode-choice {
    flex: 1 1 100%;
  }

  .action-dock-buttons {
    grid-template-columns: 1fr;
  }
}
