/* Tokens */
:root {
  --rc-bg: #f7f5fb;
  --rc-surface: #ffffff;
  --rc-surface-muted: rgb(15 23 42 / 5%);
  --rc-skeleton: rgb(15 23 42 / 8%);
  --rc-surface-subtle: rgb(0 0 0 / 2%);
  --rc-line: #e2e8f0;
  --rc-line-soft: #f1f5f9;
  --rc-line-faint: rgb(22 88 155 / 6%);
  --rc-text: #0f172a;
  --rc-text-muted: #55617a;
  --rc-text-faint: rgb(0 0 0 / 45%);
  --rc-accent: #8b5cf6;
  --rc-accent-soft: rgb(139 92 246 / 8%);
  --rc-accent-faint: rgb(139 92 246 / 4%);
  --rc-accent-hover: #7c3aed;
  --rc-focus: rgb(139 92 246 / 15%);
  --rc-hover: rgb(15 23 42 / 4%);
  --rc-row-hover: rgb(15 23 42 / 2%);
  --rc-ok: #10b981;
  --rc-ok-bg: #e1faed;
  --rc-ok-bd: #80e0b7;
  --rc-bad: #ef4444;
  --rc-bad-bg: #fff2f0;
  --rc-bad-bd: #ffc8c2;
  --rc-warn: #f59e0b;
  --rc-warn-bg: #fffae6;
  --rc-warn-bd: #ffde85;
  --rc-info: #3b82f6;
  --rc-info-bg: #f0f8ff;
  --rc-info-bd: #b8daff;
  --rc-idle: rgb(0 0 0 / 65%);
  --rc-idle-bg: #fafafa;
  --rc-idle-bd: #d9d9d9;
  --rc-disabled: rgb(0 0 0 / 35%);
  --rc-white: #ffffff;
  --rc-font: Inter, system-ui, -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif;
  --rc-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --rc-shadow-panel: 0 1px 2px rgb(15 23 42 / 5%);
  --rc-shadow-drawer: -6px 0 16px rgb(0 0 0 / 8%), -3px 0 6px -4px rgb(0 0 0 / 12%),
    -9px 0 28px 8px rgb(0 0 0 / 5%);
  --rc-shadow-popup: 0 6px 16px rgb(0 0 0 / 8%), 0 3px 6px -4px rgb(0 0 0 / 12%);
  --rc-mask: rgb(0 0 0 / 45%);
}

/* Launch selection and three-step batch flow. */
.rc-tests-table-stack {
  display: flex;
  min-height: 0;
  flex: 1;
  flex-direction: column;
}

.rc-tests-selection {
  display: flex;
  min-height: 32px;
  align-items: center;
  padding: 2px 12px;
  border-bottom: 1px solid var(--rc-line-soft);
  color: var(--rc-text-muted);
}

.rc-tests-row-actions,
.rc-launch-confirm,
.rc-launch-footer {
  display: flex;
  align-items: center;
  gap: 12px;
}

.rc-launch-steps {
  display: grid;
  margin: 0 0 16px;
  padding: 0;
  grid-template-columns: repeat(3, 1fr);
  list-style: none;
  align-items: start;
  color: var(--rc-text-muted);
  font-size: 12px;
}

.rc-launch-steps li {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 8px;
  text-align: center;
  gap: 7px;
}

.rc-launch-steps li:not(:last-child)::after {
  position: absolute;
  z-index: 0;
  top: 11px;
  left: calc(50% + 28px);
  width: calc(100% - 56px);
  height: 1px;
  background: var(--rc-line);
  content: "";
}

.rc-launch-step-number {
  position: relative;
  z-index: 1;
  display: inline-flex;
  width: 22px;
  height: 22px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--rc-line);
  border-radius: 50%;
  background: var(--rc-surface);
  font-variant-numeric: tabular-nums;
}

.rc-launch-step-number .rc-icon {
  width: 13px;
  height: 13px;
}

.rc-launch-steps .rc-launch-step-active {
  color: var(--rc-accent);
  font-weight: 600;
}

.rc-launch-step-active .rc-launch-step-number,
.rc-launch-step-done .rc-launch-step-number {
  border-color: var(--rc-accent);
  background: var(--rc-accent-soft);
  color: var(--rc-accent);
}

.rc-launch-content,
.rc-launch-selected,
.rc-launch-members,
.rc-launch-checks {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.rc-launch-selected-row,
.rc-launch-member {
  display: grid;
  align-items: center;
  padding: 6px 8px;
  border: 1px solid var(--rc-line-soft);
  border-radius: 6px;
  grid-template-columns: minmax(0, 1fr) auto auto auto;
  gap: 8px;
}

.rc-launch-presets {
  display: grid;
  padding: 0;
  border: 0;
  gap: 7px;
}

.rc-launch-presets legend {
  margin-bottom: 7px;
  color: var(--rc-text-muted);
  font-size: 12px;
}

.rc-launch-preset {
  display: grid;
  align-items: start;
  padding: 9px;
  border: 1px solid var(--rc-line);
  border-radius: 7px;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 8px;
}

.rc-launch-preset:hover,
.rc-launch-preset:focus-within {
  border-color: var(--rc-accent);
  background: var(--rc-accent-soft);
}

.rc-launch-preset-choice {
  display: grid;
  min-width: 0;
  cursor: pointer;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 8px;
}

.rc-launch-preset-details,
.rc-launch-preset-details small {
  display: block;
}

.rc-launch-preset-details strong {
  font-size: 14px;
}

.rc-launch-preset-description {
  display: -webkit-box;
  overflow: hidden;
  margin-top: 2px;
  color: var(--rc-text-muted);
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.rc-launch-preset-description-expanded {
  display: block;
  overflow: visible;
}

.rc-launch-preset-estimate {
  align-self: center;
  padding: 0 7px;
  border: 1px solid var(--rc-info-bd);
  border-radius: 4px;
  background: var(--rc-info-bg);
  color: var(--rc-info);
  font-size: 12px;
  line-height: 20px;
  white-space: nowrap;
}

.rc-launch-preset-disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.rc-launch-concurrency.rc-input {
  width: 110px;
}

.rc-launch-note,
.rc-launch-error,
.rc-launch-warning,
.rc-refresh-failed-text {
  color: var(--rc-text-muted);
  font-size: 12px;
}

.rc-launch-error {
  color: var(--rc-bad);
}

.rc-launch-warning {
  color: var(--rc-warn);
}

.rc-launch-quote {
  min-width: 0;
  table-layout: fixed;
}

.rc-launch-quote th,
.rc-launch-quote td {
  white-space: nowrap;
}

.rc-launch-quote th:first-child,
.rc-launch-quote td:first-child {
  overflow: hidden;
  width: 50%;
  text-overflow: ellipsis;
}

.rc-launch-quote th:nth-child(2) {
  width: 72px;
}

/* Reserve costs ("预留 $… （价格未知）") are longer than plain totals: wrap, never clip. */
.rc-launch-quote td:last-child {
  height: auto;
  white-space: normal;
  overflow-wrap: anywhere;
}

.rc-launch-total {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.rc-launch-fingerprint {
  display: block;
  overflow-x: auto;
  padding: 8px;
  border-radius: 6px;
  background: var(--rc-surface-subtle);
  font-family: var(--rc-mono);
  white-space: nowrap;
}

.rc-launch-fingerprint strong {
  padding: 2px 3px;
  border-radius: 3px;
  background: var(--rc-accent-soft);
  font-weight: 600;
}

.rc-launch-cost-note {
  margin: -4px 0 0;
  color: var(--rc-text-muted);
  font-size: 12px;
}

.rc-launch-confirm .rc-input {
  flex: 1;
}

.rc-launch-check {
  display: flex;
  align-items: center;
  gap: 7px;
}

.rc-launch-partner {
  flex-wrap: wrap;
  padding: 8px;
  border: 1px solid var(--rc-warn-bd);
  border-radius: 6px;
  background: var(--rc-warn-bg);
}

.rc-launch-footer {
  justify-content: flex-end;
  padding-top: 6px;
}

.rc-launch-progress {
  width: 100%;
  accent-color: var(--rc-accent);
}

.rc-launch-members {
  max-height: min(360px, calc(100vh - 330px));
  overflow-y: auto;
}

@media (max-width: 640px) {
  .rc-launch-selected-row,
  .rc-launch-member {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .rc-launch-preset {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .rc-launch-preset > small {
    grid-column: 2;
  }
}

/* Base */
* {
  box-sizing: border-box;
}

/* The hidden attribute must win over any component rule that sets display. */
[hidden] {
  display: none !important;
}

html,
body,
#app {
  height: 100%;
  margin: 0;
}

body {
  overflow: hidden;
  background: var(--rc-bg);
  color: var(--rc-text);
  font: 400 14px/22px var(--rc-font);
}

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

.rc-icon {
  display: block;
  width: 1em;
  height: 1em;
  flex: none;
}

/* Shell */
.rc-app {
  display: grid;
  grid-template: minmax(0, 1fr) / 240px minmax(0, 1fr);
  height: 100%;
}

.rc-sider {
  display: flex;
  flex-direction: column;
  grid-row: 1;
  min-height: 0;
  overflow: hidden;
  background: var(--rc-surface);
  border-right: 1px solid var(--rc-line);
}

.rc-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 56px;
  padding: 0 14px;
  font-weight: 600;
  flex-shrink: 0;
}

.rc-nav { flex: 1; min-height: 0; overflow-y: auto; overflow-x: hidden; }

.rc-sider-account {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  gap: 8px;
  min-height: 64px;
  padding: 12px;
  border-top: 1px solid var(--rc-line);
}

.rc-sider-account .rc-user { flex: 1; min-width: 0; }
.rc-sider-account .rc-avatar { flex: none; }
.rc-sider-account .rc-user-copy { min-width: 0; }
.rc-sider-account .rc-user-copy strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rc-button.rc-signout { display: inline-flex; align-items: center; gap: 5px; flex: none; }
.rc-signout .rc-icon { width: 14px; height: 14px; }

.rc-brand-mark {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  color: var(--rc-white);
  background: var(--rc-accent);
  border-radius: 8px;
}

.rc-brand-mark .rc-icon {
  width: 19px;
  height: 19px;
}

.rc-brand-name {
  flex: 1;
}

.rc-collapse {
  width: 24px;
  padding: 0;
}

.rc-nav-group {
  margin: 0;
  padding: 8px 16px;
  color: var(--rc-text-faint);
  font-size: 10.5px;
  font-weight: 400;
  line-height: 16.5px;
}

.rc-nav-item {
  display: flex;
  align-items: center;
  gap: 14px;
  height: 28px;
  margin: 4px;
  padding: 0 16px 0 24px;
  color: var(--rc-text);
  text-decoration: none;
  border-radius: 8px;
}

.rc-nav-item .rc-icon {
  width: 14px;
  height: 14px;
}

.rc-nav-item:hover {
  background: var(--rc-hover);
}

.rc-nav-item:active {
  color: var(--rc-accent);
}

.rc-nav-item:focus-visible {
  outline: 2px solid var(--rc-accent);
  outline-offset: -2px;
}

.rc-nav-item.rc-selected {
  color: var(--rc-accent);
  background: var(--rc-accent-soft);
}

.rc-topbar {
  display: none;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
  height: 56px;
  padding: 0 14px;
  background: var(--rc-surface);
  border-bottom: 1px solid var(--rc-line);
}

.rc-environment {
  margin-right: 28px;
}

.rc-user {
  display: flex;
  align-items: center;
  gap: 8px;
}

.rc-avatar {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  color: var(--rc-accent);
  font-weight: 600;
  background: var(--rc-accent-soft);
  border-radius: 50%;
}

.rc-user-copy strong,
.rc-user-copy small {
  display: block;
}

.rc-user-copy strong {
  font-size: 12px;
  line-height: 12px;
}

.rc-user-copy small {
  margin-top: 3px;
  color: var(--rc-text-muted);
  font-size: 10.5px;
}

.rc-button.rc-mobile-menu {
  display: none;
}

.rc-content {
  display: flex;
  min-width: 0;
  min-height: 0;
  padding: 10.5px;
  overflow: hidden;
  grid-column: 2;
  grid-row: 1;
}

/* Panel */
.rc-panel {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  background: var(--rc-surface);
  border: 1px solid var(--rc-line);
  border-radius: 10.5px;
  box-shadow: var(--rc-shadow-panel);
}

.rc-panel-header {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 36px;
  padding: 0 10.5px;
  border-bottom: 1px solid var(--rc-line);
}

.rc-icon-chip {
  display: grid;
  place-items: center;
  width: 25px;
  height: 25px;
  color: var(--rc-accent);
  background: var(--rc-accent-soft);
  border-radius: 7px;
}

.rc-panel-heading {
  display: flex;
  flex: 1;
  align-items: baseline;
  gap: 8px;
  min-width: 0;
}

.rc-panel-heading h2 {
  margin: 0;
  font-size: 12.25px;
  line-height: 17.5px;
  white-space: nowrap;
}

.rc-panel-heading p {
  margin: 0;
  overflow: hidden;
  color: var(--rc-text-muted);
  font-size: 10.5px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.rc-panel-actions {
  display: flex;
  align-items: center;
  gap: 7px;
}

.rc-tests-panel .rc-panel-actions {
  min-width: 0;
}

.rc-input.rc-tests-search {
  width: 160px;
  padding-right: 11px;
  padding-left: 30px;
}

.rc-tests-search-box:has(.rc-tests-search-clear) .rc-input.rc-tests-search {
  padding-right: 30px;
}

.rc-tests-search-box {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.rc-tests-search-box > .rc-icon {
  position: absolute;
  top: 50%;
  left: 9px;
  z-index: 1;
  width: 14px;
  height: 14px;
  color: var(--rc-text-muted);
  transform: translateY(-50%);
  pointer-events: none;
}

.rc-tests-search-clear {
  position: absolute;
  right: 4px;
  width: 20px;
  height: 20px;
  padding: 0;
  border: 0;
}

.rc-refresh-failed {
  width: 8px;
  height: 8px;
  background: var(--rc-warn);
  border-radius: 50%;
}

.rc-tests-body {
  flex: 1;
  min-height: 0;
  overflow: hidden;
}

.rc-tests-scroll {
  height: 100%;
}

.rc-tests-table {
  width: 100%;
  min-width: 0;
  table-layout: fixed;
}

.rc-tests-table .rc-tests-col-select {
  width: 40px;
  overflow: visible;
  padding-right: 0;
  padding-left: 0;
  text-align: center;
  text-overflow: clip;
}

.rc-tests-table .rc-tests-col-task {
  width: 124px;
}

.rc-tests-table .rc-tests-col-access {
  width: auto;
}

.rc-tests-table .rc-tests-col-url {
  width: auto;
}

.rc-tests-table .rc-tests-col-protocol {
  width: 144px;
}

.rc-tests-table .rc-tests-col-model {
  width: auto;
}

.rc-tests-table .rc-tests-col-count,
.rc-tests-table .rc-tests-col-rate {
  width: 80px;
  text-align: right;
}

.rc-tests-table .rc-tests-col-result {
  width: 224px;
}

.rc-tests-table .rc-tests-col-verdict {
  width: 112px;
}

.rc-tests-table .rc-tests-col-actions {
  width: 168px;
  padding-right: 8px;
  padding-left: 8px;
  text-overflow: clip;
}

.rc-tests-table th,
.rc-tests-table td {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.rc-tests-access > span,
.rc-tests-url > span,
.rc-tests-model > span,
.rc-tests-model > small {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.rc-tests-url,
.rc-task-id {
  font-family: var(--rc-mono);
}

.rc-task-cell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}

.rc-task-cell .rc-button {
  padding-inline: 3px;
}

.rc-task-cell .rc-copy-icon-only {
  width: 20px;
  height: 20px;
  padding: 0;
  opacity: 0;
}

.rc-task-cell:hover .rc-copy-icon-only,
.rc-copy-icon-only:focus-visible {
  opacity: 1;
}

.rc-task-time {
  grid-column: 1 / -1;
}

.rc-number {
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.rc-progress {
  display: block;
  width: 100%;
  height: 3px;
  margin-top: 5px;
  overflow: hidden;
  background: var(--rc-info-bg);
  border-radius: 2px;
}

.rc-progress::after {
  display: block;
  width: var(--rc-progress);
  height: 100%;
  content: "";
  background: var(--rc-info);
}

.rc-panel-body {
  flex: 1;
  min-height: 0;
  overflow: auto;
}

.rc-panel-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  height: 36px;
  padding: 0 12px;
  background: var(--rc-surface-subtle);
  border-top: 1px solid var(--rc-line);
}

/* Controls */
.rc-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 28px;
  padding: 0 15px;
  white-space: nowrap;
  background: var(--rc-surface);
  border: 1px solid var(--rc-line);
  border-radius: 6px;
  cursor: pointer;
}

.rc-button:hover:not(:disabled) {
  color: var(--rc-accent);
  border-color: var(--rc-accent);
}

.rc-button:active:not(:disabled) {
  transform: translateY(1px);
}

.rc-button:focus-visible,
.rc-input:focus-visible,
.rc-select:focus-visible,
.rc-page:focus-visible {
  border-color: var(--rc-accent);
  outline: 0;
  box-shadow: 0 0 0 2px var(--rc-focus);
}

.rc-button:disabled,
.rc-input:disabled,
.rc-select:disabled {
  color: var(--rc-disabled);
  cursor: not-allowed;
  opacity: 0.7;
}

.rc-button-primary {
  color: var(--rc-white);
  background: var(--rc-accent);
  border-color: var(--rc-accent);
}

.rc-button-primary:hover:not(:disabled) {
  color: var(--rc-white);
  background: var(--rc-accent-hover);
}

.rc-button-primary:disabled {
  color: var(--rc-disabled);
  background: var(--rc-surface-muted);
  border-color: var(--rc-line);
  opacity: 1;
}

.rc-button-link {
  padding-inline: 6px;
  color: var(--rc-accent);
  background: transparent;
  border-color: transparent;
}

.rc-button-small {
  height: 24px;
  padding: 0 8px;
  font-size: 12px;
}

.rc-spinner {
  width: 12px;
  height: 12px;
  border: 2px solid currentcolor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: rc-spin 0.8s linear infinite;
}

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

/* States and tables */
.rc-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 180px;
  color: var(--rc-text-muted);
}

.rc-state .rc-icon {
  width: 32px;
  height: 32px;
  color: var(--rc-text-faint);
}

.rc-state p,
.rc-state small {
  margin: 0;
}

.rc-table-wrap {
  position: relative;
  min-height: 132px;
  overflow: auto;
}

/* Inside a drawer a table is as tall as its rows; the reserved height is only for page-level tables. */
.rc-drawer .rc-table-wrap {
  min-height: 0;
}

.rc-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

.rc-table th {
  height: 41px;
  position: sticky;
  top: 0;
  z-index: 1;
  padding: 9px 16px;
  color: var(--rc-text-muted);
  font-weight: 600;
  text-align: left;
  background: var(--rc-surface-muted);
  border-bottom: 1px solid var(--rc-line-soft);
}

.rc-table td {
  height: 47px;
  padding: 9px 16px;
  overflow: hidden;
  vertical-align: middle;
  border-bottom: 1px solid var(--rc-line-soft);
  white-space: nowrap;
}

.rc-comparison-table .rc-table td {
  height: auto;
  white-space: normal;
  overflow-wrap: anywhere;
}

/* The case rules table sits in a drawer: every column wraps, 说明 takes the rest. */
.rc-rules-table td {
  height: auto;
  vertical-align: top;
  white-space: normal;
  overflow-wrap: anywhere;
}

.rc-rules-table th:nth-child(1) { width: 22%; }
.rc-rules-table th:nth-child(2) { width: 18%; }
.rc-rules-table th:nth-child(3) { width: 12%; }
.rc-rules-table th:nth-child(4) { width: 14%; }

@media (max-width: 640px) {
  .rc-rules-table th,
  .rc-rules-table td { padding: 8px; }
}

.rc-comparison-table .rc-comparison-item { width: 20%; }
.rc-comparison-table .rc-comparison-result { width: 64px; }

.rc-active-row {
  cursor: pointer;
}

.rc-active-row:hover {
  background: var(--rc-row-hover);
}

.rc-active-row:active {
  background: var(--rc-accent-soft);
}

.rc-active-row:focus-visible {
  outline: 2px solid var(--rc-accent);
  outline-offset: -2px;
}

.rc-cell-id {
  display: block;
  color: var(--rc-text-muted);
  font: 400 10.5px/14px var(--rc-mono);
}

.rc-truncate > * {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.rc-skeleton {
  display: block;
  height: 14px;
  background: var(--rc-skeleton);
  border-radius: 6px;
  animation: rc-pulse 1.2s ease-in-out infinite;
}

.rc-skeleton-short {
  width: 40%;
}

.rc-skeleton-wide {
  width: 60%;
}

.rc-skeleton-full {
  width: 80%;
}

@keyframes rc-pulse {
  50% {
    opacity: 0.45;
  }
}

/* Tags and forms */
.rc-tag {
  display: inline-block;
  padding: 0 7px;
  font-size: 12px;
  line-height: 20px;
  white-space: nowrap;
  border: 1px solid;
  border-radius: 4px;
}

.rc-tag-ok {
  color: var(--rc-ok);
  background: var(--rc-ok-bg);
  border-color: var(--rc-ok-bd);
}

.rc-tag-bad {
  color: var(--rc-bad);
  background: var(--rc-bad-bg);
  border-color: var(--rc-bad-bd);
}

.rc-tag-warn {
  color: var(--rc-warn);
  background: var(--rc-warn-bg);
  border-color: var(--rc-warn-bd);
}

.rc-tag-info {
  color: var(--rc-info);
  background: var(--rc-info-bg);
  border-color: var(--rc-info-bd);
}

.rc-tag-idle {
  color: var(--rc-idle);
  background: var(--rc-idle-bg);
  border-color: var(--rc-idle-bd);
}

.rc-section-label {
  margin: 16px 0 8px;
  color: var(--rc-text-muted);
  font-size: 12px;
  font-weight: 400;
  line-height: 20px;
}

.rc-kit {
  padding: 0 12px 20px;
}

.rc-demo-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

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

.rc-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  color: var(--rc-text-muted);
  font-size: 12px;
}

.rc-field-switchable {
  position: relative;
}

.rc-button.rc-field-switch {
  position: absolute;
  top: -4px;
  right: 0;
  height: 22px;
  padding-inline: 0;
}

.rc-field-label {
  display: flex;
  gap: 4px;
}

.rc-required,
.rc-field-error {
  color: var(--rc-bad);
}

.rc-input,
.rc-select {
  height: 28px;
  padding: 2px 11px;
  font-size: 14px;
  background: var(--rc-surface);
  border: 1px solid var(--rc-line);
  border-radius: 6px;
}

/* Chrome's customizable select: the closed control and the option list follow the page tokens. */
@supports (appearance: base-select) {
  .rc-select,
  .rc-select::picker(select) {
    appearance: base-select;
  }

  .rc-select {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    min-width: 0;
    padding: 0 11px;
    line-height: 20px;
    color: var(--rc-text);
    cursor: pointer;
  }

  .rc-select::picker-icon {
    flex: none;
    width: 6px;
    height: 6px;
    margin-bottom: 3px;
    content: "";
    border-right: 1.5px solid var(--rc-text-faint);
    border-bottom: 1.5px solid var(--rc-text-faint);
    transform: rotate(45deg);
  }

  .rc-select:open::picker-icon {
    margin-top: 3px;
    margin-bottom: 0;
    transform: rotate(225deg);
  }

  .rc-select:open {
    border-color: var(--rc-accent);
    box-shadow: 0 0 0 2px var(--rc-focus);
  }

  .rc-select::picker(select) {
    max-height: 264px;
    margin: 4px 0;
    padding: 4px;
    overflow-y: auto;
    color: var(--rc-text);
    background: var(--rc-surface);
    border: 1px solid var(--rc-line);
    border-radius: 8px;
    box-shadow: var(--rc-shadow-popup);
  }

  .rc-select option {
    display: block;
    min-height: 30px;
    padding: 5px 10px;
    overflow: hidden;
    font-size: 14px;
    line-height: 20px;
    text-overflow: ellipsis;
    white-space: nowrap;
    border-radius: 4px;
    cursor: pointer;
  }

  .rc-select option::checkmark {
    display: none;
  }

  .rc-select option:hover,
  .rc-select option:focus-visible {
    background: var(--rc-hover);
    outline: 0;
  }

  .rc-select option:checked {
    font-weight: 600;
    color: var(--rc-accent);
    background: var(--rc-accent-soft);
  }

  .rc-select option:disabled {
    color: var(--rc-disabled);
    cursor: not-allowed;
  }
}

.rc-pagination {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  padding: 8px;
  font-variant-numeric: tabular-nums;
}

.rc-page {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 6px;
}

.rc-page:hover {
  color: var(--rc-accent);
}

.rc-page:active {
  background: var(--rc-accent-soft);
}

.rc-page-active {
  font-weight: 600;
  background: var(--rc-accent-soft);
  border-color: var(--rc-accent);
}

/* Descriptions */
.rc-descriptions {
  display: grid;
  grid-template-columns: 174px minmax(0, 1fr) 174px minmax(0, 1fr) 174px minmax(0, 1fr);
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--rc-line-faint);
  border-radius: 8px;
}

.rc-descriptions dt,
.rc-descriptions dd {
  margin: 0;
  padding: 8px 16px;
  border-right: 1px solid var(--rc-line-faint);
  border-bottom: 1px solid var(--rc-line-faint);
}

.rc-descriptions dt {
  color: var(--rc-text-muted);
  background: var(--rc-surface-subtle);
}

.rc-descriptions dd:nth-child(6n) {
  border-right: 0;
}

.rc-description-full-label {
  grid-column: 1 / 2;
}

.rc-description-full-value {
  grid-column: 2 / -1;
  border-right: 0 !important;
}

.rc-description-last {
  border-bottom: 0 !important;
}

/* Run drawer */
.rc-run-drawer {
  min-height: 100%;
}

.rc-drawer-copy,
.rc-capabilities,
.rc-case-group-counts {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.rc-drawer-mono {
  overflow: hidden;
  font-family: var(--rc-mono);
  white-space: nowrap;
  text-overflow: ellipsis;
}

.rc-drawer-copy .rc-copy-icon-only {
  width: 22px;
  height: 22px;
  padding: 0;
}

.rc-capabilities {
  flex-wrap: wrap;
}

.rc-drawer-summary-value {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 0;
}

.rc-blockers {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 16px;
  min-width: 0;
}

.rc-button.rc-blocker-link {
  max-width: 100%;
  height: auto;
  padding: 0;
  line-height: 20px;
  text-align: left;
  white-space: normal;
  overflow-wrap: anywhere;
}

.rc-visit-intro {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.rc-visit-intro p {
  margin: 0;
}

.rc-drawer-note {
  color: var(--rc-text-muted);
  font-size: 10.5px;
  line-height: 16px;
}

.rc-drawer-section {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.rc-outcome-notice {
  display: grid;
  gap: 8px;
  min-width: 0;
  margin-block: 16px;
}

.rc-outcome-related,
.rc-outcome-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.rc-outcome-actions {
  margin-top: 16px;
}

.rc-outcome-notice p,
.rc-outcome-actions p {
  margin: 0;
}

.rc-outcome-actions p {
  flex-basis: 100%;
}

.rc-case-filters {
  display: flex;
  align-items: center;
}

.rc-segment {
  border-radius: 0;
}

.rc-segment + .rc-segment {
  margin-left: -1px;
}

.rc-segment:first-child {
  border-radius: 6px 0 0 6px;
}

.rc-segment:last-child {
  border-radius: 0 6px 6px 0;
}

.rc-segment-active {
  z-index: 1;
  color: var(--rc-accent);
  background: var(--rc-accent-soft);
  border-color: var(--rc-accent);
}

.rc-case-table {
  min-width: 920px;
}

.rc-case-table th:nth-child(1) {
  width: 300px;
}

.rc-case-table th:nth-child(2) {
  width: 92px;
}

.rc-case-table th:nth-child(3) {
  width: 96px;
}

.rc-case-table th:nth-child(4) {
  width: 132px;
  text-align: right;
}

.rc-case-table th:nth-child(6) {
  width: 72px;
}

.rc-case-table td {
  height: 47px;
  white-space: nowrap;
}

.rc-case-table .rc-case-result-cell { white-space: normal; }
.rc-case-result { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
.rc-outdated-notice {
  padding: 12px 16px;
  margin-bottom: 16px;
  color: var(--rc-text);
  background: var(--rc-warn-bg);
  border: 1px solid var(--rc-warn-bd);
  border-radius: 8px;
  overflow-wrap: anywhere;
}
.rc-outdated-notice h3 { margin: 0; font-size: 14px; }
.rc-outdated-notice p { margin: 6px 0 0; line-height: 22px; }

.rc-case-table thead th {
  position: sticky;
  top: 0;
  z-index: 2;
}

.rc-case-group th {
  position: static;
  height: 36px;
  color: var(--rc-text);
  background: var(--rc-surface-subtle);
  border-top: 1px solid var(--rc-line);
}

.rc-case-group-counts {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: 8px;
}

.rc-case-request > .rc-drawer-summary-value {
  align-items: flex-end;
}

.rc-case-must {
  font-weight: 600;
}

.rc-case-message {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.rc-tag-dashed {
  border-style: dashed;
}

.rc-case-highlight {
  background: var(--rc-accent-soft);
  outline: 2px solid var(--rc-accent);
  outline-offset: -2px;
}

.rc-not-run-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  color: var(--rc-text-muted);
}

.rc-drawer-description-skeleton {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 17px 32px;
  min-height: 258px;
  padding: 18px 16px;
  border: 1px solid var(--rc-line-faint);
  border-radius: 8px;
}

.rc-tests-access-select {
  width: 220px;
  max-width: 220px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rc-case-detail-nav,
.rc-visit-summary,
.rc-visit-body-heading,
.rc-source-list li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.rc-case-detail-nav {
  margin-bottom: 12px;
}

.rc-case-detail-nav-spacer,
.rc-visit-summary-spacer {
  flex: 1;
}

.rc-case-conclusion {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 10px 12px;
  border-left: 4px solid var(--rc-idle);
  background: var(--rc-surface-subtle);
}

.rc-case-conclusion-ok {
  border-left-color: var(--rc-ok);
}

.rc-case-conclusion-bad {
  border-left-color: var(--rc-bad);
}

.rc-case-conclusion-warn {
  border-left-color: var(--rc-warn);
}

.rc-source-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 0;
  list-style: none;
}

.rc-muted-line {
  color: var(--rc-text-muted);
}

.rc-visit-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.rc-visit-block {
  border: 1px solid var(--rc-line);
  border-radius: 8px;
}

.rc-visit-summary {
	flex-wrap: wrap;
  min-height: 42px;
  padding: 6px 10px;
  background: var(--rc-surface-subtle);
}

.rc-input-usage-evidence {
  padding: 12px;
  border: 1px solid var(--rc-line);
  border-radius: 6px;
  background: var(--rc-surface-subtle);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font: 12px/1.7 var(--rc-mono);
}

.rc-visit-detail {
  padding: 12px;
  border-top: 1px solid var(--rc-line);
}

.rc-visit-loading {
  min-height: 180px;
  padding: 24px;
}

.rc-visit-facts {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 5px 14px;
  margin: 0 0 12px;
  padding: 12px 14px;
  font-size: 13px;
  line-height: 20px;
  background: var(--rc-accent-faint);
  border: 1px solid var(--rc-line);
  border-radius: 8px;
}

.rc-visit-facts dt {
  color: var(--rc-text-muted);
}

.rc-visit-facts dd {
  min-width: 0;
  margin: 0;
  font-family: var(--rc-mono);
  overflow-wrap: anywhere;
}

.rc-visit-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.rc-visit-header-list summary {
  width: fit-content;
  font-family: var(--rc-font);
  color: var(--rc-text-muted);
  cursor: pointer;
}

.rc-visit-header-list summary:hover {
  color: var(--rc-accent);
}

.rc-visit-fact-note {
  margin-left: 8px;
  color: var(--rc-text-faint);
  font-size: 12px;
}

.rc-visit-header-list ul {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin: 4px 0 2px;
  padding: 0;
  list-style: none;
}

.rc-visit-body + .rc-visit-body {
  margin-top: 12px;
}

.rc-visit-body-heading {
  justify-content: space-between;
  margin: 6px 0;
}

.rc-stream-toggle .rc-button[aria-pressed="true"] {
  color: var(--rc-accent);
  background: var(--rc-accent-soft);
  border-color: var(--rc-accent);
}

.rc-visit-body-actions,
.rc-evidence-flags,
.rc-stream-toggle {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.rc-code-block {
  max-height: 520px;
  padding: 12px;
  overflow: auto;
  font-family: var(--rc-mono);
  white-space: pre-wrap;
  word-break: break-word;
  background: var(--rc-surface-muted);
  border: 1px solid var(--rc-line-soft);
  border-radius: 6px;
}

/* Layers */
.rc-mask {
  position: fixed;
  z-index: 70;
  inset: 0;
  background: var(--rc-mask);
}

.rc-drawer,
.rc-modal {
  position: fixed;
  z-index: 71;
  display: flex;
  flex-direction: column;
  background: var(--rc-surface);
}

.rc-drawer {
  inset: 0 0 0 auto;
  width: 1080px;
  max-width: 100vw;
  box-shadow: var(--rc-shadow-drawer);
}

.rc-modal {
  top: 50%;
  left: 50%;
  width: 520px;
  max-width: calc(100vw - 24px);
  max-height: calc(100vh - 24px);
  border-radius: 8px;
  transform: translate(-50%, -50%);
}

.rc-modal-wide {
  width: 720px;
}

.rc-drawer-header,
.rc-modal-header {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 49px;
  padding: 12px;
  font-size: 16px;
  font-weight: 600;
  line-height: 24px;
  border-bottom: 1px solid var(--rc-line-faint);
}

.rc-drawer-body,
.rc-modal-body {
  padding: 16px;
  overflow: auto;
}

.rc-drawer-body {
  flex: 1;
}

.rc-layer-close {
  width: 24px;
  padding: 0;
}

.rc-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.rc-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.rc-scroll-locked {
  overflow: hidden;
}

.rc-toasts {
  position: fixed;
  top: 64px;
  left: 50%;
  z-index: 80;
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: min(420px, calc(100vw - 24px));
  transform: translateX(-50%);
}

.rc-scroll-locked .rc-toasts {
  top: 12px;
}

.rc-launched-row {
  background: var(--rc-accent-soft);
}

.rc-case-subgroup th {
  height: 32px;
  padding: 4px 16px;
  color: var(--rc-text-muted);
  text-align: left;
  background: var(--rc-surface-subtle);
}

.rc-toast {
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: space-between;
  padding: 10px 14px;
  border: 1px solid;
  border-radius: 8px;
}

.rc-toast-error {
  color: var(--rc-bad);
  background: var(--rc-bad-bg);
  border-color: var(--rc-bad-bd);
}

.rc-toast-info {
  color: var(--rc-info);
  background: var(--rc-info-bg);
  border-color: var(--rc-info-bd);
}

.rc-toast-close {
  width: 24px;
  padding: 0;
  color: currentcolor;
  background: transparent;
  border-color: transparent;
}

/* Login and routing */
.rc-login {
  display: grid;
  place-items: center;
  height: 100%;
  padding: 20px;
}

.rc-login-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 360px;
  max-width: 100%;
  padding: 28px;
  background: var(--rc-surface);
  border: 1px solid var(--rc-line);
  border-radius: 10.5px;
  box-shadow: var(--rc-shadow-panel);
}

.rc-login-card h1,
.rc-login-card p {
  margin: 0;
}

.rc-login-card p {
  color: var(--rc-text-muted);
}

.rc-login-mark {
  width: 40px;
  height: 40px;
}

.rc-login-error {
  color: var(--rc-bad) !important;
}

.rc-not-found {
  margin: auto;
  color: var(--rc-text-muted);
  text-align: center;
}

.rc-not-found .rc-icon {
  width: 40px;
  height: 40px;
  margin: auto;
}

.rc-not-found a {
  color: var(--rc-accent);
}

.rc-collapsed {
  grid-template-columns: 56px minmax(0, 1fr);
}

.rc-collapsed .rc-brand-name,
.rc-collapsed .rc-nav-group,
.rc-collapsed .rc-nav-item span {
  display: none;
}

.rc-collapsed .rc-nav-item {
  justify-content: center;
  padding: 0;
}

.rc-collapsed .rc-brand { justify-content: center; padding: 0; }
.rc-collapsed .rc-brand-mark { display: none; }
.rc-collapsed .rc-collapse { width: 32px; height: 32px; }
.rc-collapsed .rc-sider-account { flex-direction: column; padding: 12px 4px; }
.rc-collapsed .rc-sider-account .rc-user-copy,
.rc-collapsed .rc-signout-label { display: none; }
.rc-collapsed .rc-button.rc-signout { justify-content: center; width: 44px; height: 44px; padding: 0; }

/* Responsive */
@media (max-width: 900px) {
  .rc-app {
    grid-template-columns: 56px minmax(0, 1fr);
  }

  .rc-brand-name,
  .rc-collapse,
  .rc-nav-group,
  .rc-nav-item span {
    display: none;
  }

  .rc-nav-item {
    justify-content: center;
    padding: 0;
  }

  .rc-sider-account { flex-direction: column; padding: 12px 4px; }
  .rc-sider-account .rc-user-copy,
  .rc-signout-label { display: none; }
  .rc-button.rc-signout { justify-content: center; width: 44px; height: 44px; padding: 0; }
  .rc-collapsed .rc-brand-mark { display: grid; }
  .rc-collapsed .rc-collapse { display: none; }

  .rc-descriptions {
    grid-template-columns: 110px minmax(0, 1fr);
  }

  .rc-description-full-label {
    grid-column: 1;
  }

  .rc-description-full-value {
    grid-column: 2;
  }

  .rc-demo-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .rc-app {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: 48px minmax(0, 1fr);
  }

  .rc-sider {
    position: fixed;
    z-index: 60;
    inset: 0 auto 0 0;
    width: 240px;
    background: var(--rc-surface);
    visibility: hidden;
    transform: translateX(-100%);
    transition: transform 0.2s;
  }

  .rc-mobile-open .rc-sider {
    visibility: visible;
    box-shadow: var(--rc-shadow-drawer);
    transform: translateX(0);
  }

  .rc-sider .rc-brand-name,
  .rc-sider .rc-nav-group,
  .rc-sider .rc-nav-item span {
    display: block;
  }

  .rc-sider .rc-nav-item {
    justify-content: flex-start;
    padding: 0 16px 0 24px;
  }

  .rc-button.rc-mobile-menu {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 44px;
    height: 44px;
    padding: 0;
  }

  .rc-topbar { display: flex; justify-content: flex-start; height: 48px; padding: 0 10.5px; gap: 8px; }
  .rc-mobile-title { font-weight: 600; }
  .rc-content { grid-column: 1; grid-row: 2; }
  .rc-sider-account,
  .rc-collapsed .rc-sider-account { flex-direction: row; padding: 12px; }
  .rc-sider-account .rc-user-copy,
  .rc-collapsed .rc-sider-account .rc-user-copy,
  .rc-signout-label,
  .rc-collapsed .rc-signout-label { display: block; }
  .rc-button.rc-signout,
  .rc-collapsed .rc-button.rc-signout { width: auto; min-width: 44px; height: 44px; padding: 0 8px; }

  .rc-environment,
  .rc-panel-heading p,
  .rc-pagination > span {
    display: none;
  }

  .rc-panel-header {
    flex-wrap: wrap;
    padding-block: 5px;
  }

  .rc-tests-panel .rc-panel-actions {
    width: 100%;
    overflow-x: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* Adapt to the actual workspace, including changes in sidebar width. */
.rc-tests-panel { container: rc-tests / inline-size; }
.rc-tests-panel > .rc-panel-header { flex-wrap: wrap; gap: 8px; padding-block: 6px; }
.rc-tests-panel .rc-panel-heading { flex: 1 1 240px; }
.rc-tests-panel .rc-panel-actions { flex-wrap: wrap; justify-content: flex-end; overflow: visible; }

@container rc-tests (max-width: 1500px) {
  .rc-tests-table .rc-tests-col-url,
  .rc-tests-table .rc-tests-col-rate { display: none; }
}

@container rc-tests (max-width: 1250px) {
  .rc-tests-table .rc-tests-col-protocol { display: none; }
  .rc-tests-table .rc-tests-col-task { width: 108px; }
  .rc-tests-table .rc-task-time { display: none; }
  .rc-tests-table .rc-tests-col-count { width: 80px; }
  .rc-tests-table .rc-tests-col-result { width: 208px; }
  .rc-tests-table .rc-tests-col-verdict { width: 108px; }
  .rc-tests-panel .rc-panel-heading p { display: none; }
}

@container rc-tests (max-width: 1100px) {
  .rc-tests-table .rc-tests-col-task,
  .rc-tests-table .rc-tests-col-count { display: none; }
  .rc-tests-table .rc-tests-col-result { width: 200px; }
  .rc-tests-panel .rc-panel-actions { flex: 1 1 100%; justify-content: flex-start; }
}

/* Narrow workspaces use compact records with results and actions always visible. */
@container rc-tests (max-width: 840px) {
  .rc-tests-table,
  .rc-tests-table thead,
  .rc-tests-table tbody { display: block; }
  .rc-tests-table thead tr { display: block; }
  .rc-tests-table thead th { display: none; }
  .rc-tests-table thead .rc-tests-col-select {
    display: flex;
    width: auto;
    height: auto;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
  }
  .rc-tests-table thead .rc-tests-col-select::after { content: "选择当前页"; font-weight: 400; }
  .rc-tests-table tbody tr {
    display: grid;
    grid-template-columns: 28px minmax(0, 1fr) auto;
    align-items: start;
    gap: 8px 12px;
    padding: 12px;
    border-bottom: 1px solid var(--rc-line-soft);
  }
  .rc-tests-table tbody td {
    display: none;
    width: auto;
    min-width: 0;
    height: auto;
    padding: 0;
    border: 0;
    white-space: normal;
  }
  .rc-tests-table tbody td[class] { width: auto; overflow: visible; }
  .rc-tests-table tbody .rc-tests-col-select {
    display: block;
    grid-column: 1;
    grid-row: 1;
    padding-top: 3px;
  }
  .rc-tests-table tbody .rc-tests-col-access {
    display: block;
    grid-column: 2 / -1;
    grid-row: 1;
  }
  .rc-tests-table tbody .rc-tests-col-model {
    display: flex;
    grid-column: 2 / -1;
    grid-row: 2;
    align-items: baseline;
    gap: 8px;
  }
  .rc-tests-table tbody .rc-tests-col-model::before,
  .rc-tests-table tbody .rc-tests-col-verdict::before {
    color: var(--rc-text-muted);
    font-size: 12px;
    white-space: nowrap;
  }
  .rc-tests-table tbody .rc-tests-col-model::before { content: "模型"; }
  .rc-tests-model { min-width: 0; }
  .rc-tests-table tbody .rc-tests-col-result { display: block; grid-column: 2; grid-row: 3; }
  .rc-tests-table tbody .rc-tests-col-verdict { display: block; grid-column: 3; grid-row: 3; }
  .rc-tests-table tbody .rc-tests-col-verdict::before { content: "准入判定"; display: block; margin-bottom: 4px; }
  .rc-tests-table tbody .rc-tests-col-actions { display: block; grid-column: 2 / -1; grid-row: 4; }
  .rc-tests-row-actions > .rc-button,
  .rc-tests-row-actions .rc-report-control > .rc-button { min-height: 36px; height: auto; padding-block: 6px; }
  .rc-tests-panel .rc-panel-actions { flex: 1 1 100%; justify-content: flex-start; }
}

@container rc-tests (max-width: 480px) {
  .rc-tests-panel .rc-panel-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rc-tests-panel .rc-panel-actions > *,
  .rc-tests-panel .rc-tests-search { width: 100%; min-width: 0; max-width: none; }
  .rc-tests-table tbody tr { grid-template-columns: 24px minmax(0, 1fr); gap: 8px; }
  .rc-tests-table tbody .rc-tests-col-verdict { display: flex; grid-column: 2; grid-row: 4; gap: 8px; }
  .rc-tests-table tbody .rc-tests-col-verdict::before { margin-bottom: 0; }
  .rc-tests-table tbody .rc-tests-col-actions { grid-row: 5; }
  .rc-tests-row-actions > .rc-button,
  .rc-tests-row-actions .rc-report-control > .rc-button { min-height: 40px; }
}

/* Model access page */
.rc-access-body {
  min-height: 0;
  overflow: auto;
}

.rc-access-search-box {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.rc-access-search-box > .rc-icon {
  position: absolute;
  left: 9px;
  z-index: 1;
  width: 14px;
  height: 14px;
  color: var(--rc-text-muted);
  pointer-events: none;
}

.rc-input.rc-access-search {
  width: 260px;
  padding-left: 29px;
}

.rc-access-table {
  min-width: 1050px;
  table-layout: fixed;
}

.rc-access-table th:nth-child(1) {
  width: 130px;
}

.rc-access-table th:nth-child(2) {
  width: 150px;
}

.rc-access-table th:nth-child(3) {
  width: 260px;
}

.rc-access-table th:nth-child(4) {
  width: 170px;
}

.rc-access-table th:nth-child(5) {
  width: 150px;
}

.rc-access-table th:nth-child(6) {
  width: 150px;
}

.rc-access-table th:nth-child(7),
.rc-access-table th:nth-child(8) {
  width: 80px;
}

.rc-mono {
  overflow: hidden;
  font-family: var(--rc-mono);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rc-check-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.rc-check-row small {
  display: block;
  color: var(--rc-text-muted);
}

.rc-discard,
.rc-inline-warning {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  color: var(--rc-warn);
  background: var(--rc-warn-bg);
  border: 1px solid var(--rc-warn-bd);
  border-radius: 6px;
}

.rc-discard span:first-child {
  margin-right: auto;
}

.rc-access-drawer {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.rc-access-section {
  padding: 16px;
  border: 1px solid var(--rc-line);
  border-radius: 8px;
}

.rc-access-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.rc-access-section-header h3 {
  margin: 0;
  font-size: 16px;
}

.rc-access-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 16px;
}

.rc-readonly,
.rc-field-help {
  color: var(--rc-text-muted);
}

.rc-access-section-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 16px;
}

.rc-credential-status,
.rc-secret-field,
.rc-inline-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.rc-credential-status {
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.rc-access-table .rc-credential-status {
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  margin-bottom: 0;
}

.rc-credential-status small {
  color: var(--rc-text-muted);
}

.rc-key-details {
  margin-top: 8px;
  color: var(--rc-text-muted);
  font-size: 12px;
  overflow-wrap: anywhere;
}

.rc-key-details summary { cursor: pointer; }

.rc-secret-field .rc-input {
  flex: 1;
}

.rc-tabs {
  display: flex;
  gap: 16px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--rc-line);
}

.rc-tab {
  padding: 8px 2px;
  color: var(--rc-text-muted);
  background: transparent;
  border: 0;
  border-bottom: 2px solid transparent;
  cursor: pointer;
}

.rc-tab-active {
  color: var(--rc-accent);
  border-bottom-color: var(--rc-accent);
}

.rc-tab:focus-visible {
  outline: 2px solid var(--rc-accent);
  outline-offset: 2px;
}

.rc-model-tab {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.rc-newapi-import {
  min-width: 0;
  gap: 12px;
  overflow-wrap: anywhere;
}

.rc-newapi-import p {
  margin: 0;
}

.rc-newapi-import .rc-model-choices > p {
  padding: 8px 10px;
}

.rc-newapi-import .rc-modal-actions {
  flex-wrap: wrap;
}

.rc-newapi-import .rc-field,
.rc-newapi-import .rc-input,
.rc-newapi-import .rc-select {
  min-width: 0;
  max-width: 100%;
}

.rc-model-choices {
  max-height: 320px;
  overflow: auto;
  border: 1px solid var(--rc-line);
  border-radius: 6px;
}

.rc-model-choices .rc-check-row {
  padding: 8px 10px;
  border-bottom: 1px solid var(--rc-line-soft);
}

.rc-model-choices .rc-check-row:last-child {
  border-bottom: 0;
}

.rc-model-table th:nth-child(1) {
  width: 35%;
}

.rc-model-table th:nth-child(2) {
  width: 40%;
}

.rc-model-table th:nth-child(3) {
  width: 25%;
}

@media (max-width: 640px) {
  .rc-access-panel .rc-panel-actions {
    width: 100%;
  }

  .rc-input.rc-access-search {
    width: 100%;
  }

  .rc-access-search-box {
    flex: 1;
  }

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

/* Workbench: counts describe configured models and their latest test only. */
.rc-dashboard > .rc-panel-body {
  overflow: auto;
}

.rc-dashboard-body {
  padding: 14px;
}

.rc-dashboard-updated {
  margin: 0 0 10px;
  color: var(--rc-text-muted);
  font-size: 12px;
}

.rc-dashboard-stale {
  padding: 8px 10px;
  border: 1px solid var(--rc-warn-bd);
  border-radius: 6px;
  background: var(--rc-warn-bg);
  color: var(--rc-text);
}

.rc-dashboard-metrics,
.rc-dashboard-loading {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.rc-dashboard-metric {
  display: grid;
  min-width: 0;
  min-height: 118px;
  padding: 14px;
  border: 1px solid var(--rc-line);
  border-radius: 8px;
  color: var(--rc-text);
  text-decoration: none;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 4px;
}

.rc-dashboard-metric .rc-icon-chip {
  grid-column: 2;
  grid-row: 1 / 3;
}

.rc-dashboard-metric-label {
  color: var(--rc-text-muted);
  font-size: 12px;
}

.rc-dashboard-metric strong {
  font-size: 28px;
  line-height: 34px;
  font-variant-numeric: tabular-nums;
}

.rc-dashboard-metric small {
  grid-column: 1 / -1;
  color: var(--rc-text-muted);
  font-size: 12px;
}

.rc-dashboard-link {
  display: inline-block;
  max-width: 100%;
  overflow: hidden;
  color: var(--rc-accent);
  text-decoration: none;
  text-overflow: ellipsis;
  vertical-align: middle;
  white-space: nowrap;
}

.rc-dashboard-link:hover {
  text-decoration: underline;
}

.rc-dashboard-metric:hover,
.rc-dashboard-state:hover {
  border-color: var(--rc-accent);
  background: var(--rc-accent-faint);
}

.rc-dashboard a:focus-visible {
  outline: 2px solid var(--rc-accent);
  outline-offset: -2px;
}

.rc-dashboard a:active {
  color: var(--rc-accent-hover);
}

.rc-dashboard-steps {
  display: grid;
  margin: 14px 0;
  padding: 14px 0;
  border-block: 1px solid var(--rc-line-soft);
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  list-style: none;
}

.rc-dashboard-steps li {
  display: flex;
  min-width: 0;
  align-items: start;
  gap: 8px;
}

.rc-dashboard-steps .rc-launch-step-number {
  flex: none;
  color: var(--rc-accent);
  border-color: var(--rc-accent);
  background: var(--rc-accent-soft);
}

.rc-dashboard-steps p,
.rc-dashboard-distribution > p {
  margin: 4px 0 0;
  color: var(--rc-text-muted);
  font-size: 12px;
}

.rc-dashboard-distribution h3 {
  margin: 0;
  font-size: 12.25px;
}

.rc-dashboard-states {
  display: grid;
  margin: 10px 0 16px;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.rc-dashboard-state {
  display: flex;
  min-width: 0;
  flex-direction: column;
  padding: 10px;
  border: 1px solid var(--rc-line);
  border-radius: 6px;
  color: var(--rc-text-muted);
  text-decoration: none;
  font-size: 12px;
}

.rc-dashboard-state strong {
  color: var(--rc-text);
  font-size: 18px;
  line-height: 28px;
  font-variant-numeric: tabular-nums;
}

.rc-dashboard-recent .rc-panel-body {
  overflow: visible;
}

.rc-dashboard-table {
  width: 100%;
  table-layout: fixed;
}

.rc-dashboard-table th,
.rc-dashboard-table td,
.rc-dashboard-table .rc-cell-id {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.rc-dashboard-table .rc-dashboard-col-model { width: 26%; }
.rc-dashboard-table .rc-dashboard-col-access { width: 23%; }
.rc-dashboard-table .rc-dashboard-col-time { width: 23%; }
.rc-dashboard-table .rc-dashboard-col-result { width: 28%; }

.rc-dashboard-table .rc-tag {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  vertical-align: middle;
}

.rc-dashboard-model-id {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 4px;
}

.rc-dashboard-model-id .rc-cell-id {
  flex: 1;
}

.rc-dashboard-model-id .rc-button {
  flex: none;
  width: 18px;
  height: 18px;
  padding: 0;
}

/* Supplier accounts and model admission. */
.rc-portal-body { padding: 12px; }
.rc-portal-actions,
.rc-portal-tabs,
.rc-portal-row-actions { display: flex; align-items: center; gap: 12px; }
.rc-portal-tabs { margin-bottom: 12px; }
.rc-portal-note { width: 100%; height: auto; min-height: 96px; resize: vertical; font: inherit; }
.rc-portal-stale {
  padding: 8px 12px;
  border: 1px solid var(--rc-warn-bd);
  border-radius: 6px;
  background: var(--rc-warn-bg);
  color: var(--rc-text);
}
.rc-portal-detail .rc-form { margin-top: 16px; }
.rc-portal-detail > p { overflow-wrap: anywhere; }
.rc-portal-panel .rc-table td,
.rc-portal-panel .rc-table th { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.rc-portal-actions-col { width: 148px; }
.rc-tests-readonly .rc-tests-col-select { display: none; }
@media (max-width: 640px) {
  .rc-portal-panel .rc-portal-vendor,
  .rc-portal-panel .rc-portal-group,
  .rc-portal-panel .rc-portal-role { display: none; }
  .rc-portal-panel .rc-table td,
  .rc-portal-panel .rc-table th { padding-inline: 8px; }
  .rc-portal-actions-col { width: 120px; }
  .rc-portal-tabs { flex-wrap: wrap; }
}

.rc-dashboard-loading-table {
  grid-column: 1 / -1;
  margin-top: 16px;
}

/* Dated reference sources share the official-model page without becoming publications. */
.rc-reference-page,
.rc-reference-host { display: flex; flex-direction: column; flex: 1; min-width: 0; min-height: 0; }
.rc-reference-tabs { flex: none; flex-wrap: wrap; gap: 8px 20px; margin: 0 0 10px; }
.rc-reference-tabs .rc-tab { white-space: nowrap; }
.rc-reference-panel { min-width: 0; }
.rc-reference-note { margin: 0 0 8px; color: var(--rc-text-muted); line-height: 1.6; }
.rc-reference-counts { margin: 0 0 12px; color: var(--rc-text-muted); font-variant-numeric: tabular-nums; }
.rc-reference-filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.rc-reference-filters input { flex: 1 1 240px; min-width: 0; }
.rc-reference-filters select { width: 160px; }
.rc-reference-table .rc-table { min-width: 960px; }
.rc-reference-table th:first-child { width: 25%; }
.rc-reference-table th:nth-child(2) { width: 10%; }
.rc-reference-table th:nth-child(3) { width: 14%; }
.rc-reference-table th:nth-child(4) { width: 12%; }
.rc-reference-table th:nth-child(5) { width: 12%; }
.rc-reference-table th:last-child { width: 112px; }
.rc-reference-table td > div { overflow: hidden; text-overflow: ellipsis; }
.rc-reference-pagination { flex-wrap: wrap; justify-content: flex-end; gap: 8px; margin-top: 12px; }
.rc-reference-pagination select { width: 100px; }
.rc-reference-detail { min-width: 0; }
.rc-reference-detail dd,
.rc-reference-detail td { white-space: pre-wrap; overflow-wrap: anywhere; }
.rc-reference-detail .rc-table { table-layout: fixed; }
.rc-reference-detail th:first-child { width: 160px; }
.rc-help { max-width: 1360px; margin: 0 auto; padding: 20px; }
.rc-help-intro { padding: 4px 0 24px; border-bottom: 1px solid var(--rc-line); }
.rc-help-intro h1 { margin: 0 0 8px; font-size: 24px; line-height: 1.4; }
.rc-help-intro p { color: var(--rc-text-muted); line-height: 1.7; }
.rc-help-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.rc-help-actions a { display: inline-flex; align-items: center; text-decoration: none; }
.rc-help-layout { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 32px; padding-top: 24px; }
.rc-help-toc { display: flex; flex-direction: column; align-items: stretch; align-self: start; gap: 4px; }
.rc-help-toc strong { margin: 0 15px 10px; font-size: 12px; color: var(--rc-text-muted); }
.rc-help-toc button { height: auto; min-height: 32px; text-align: left; justify-content: flex-start; }
.rc-help-articles { min-width: 0; }
.rc-help-section { padding: 0 0 24px; margin-bottom: 24px; border-bottom: 1px solid var(--rc-line); }
.rc-help-section:last-child { margin-bottom: 0; border: 0; }
.rc-help-section h3 { margin: 0 0 16px; font-size: 17px; line-height: 1.5; scroll-margin-top: 16px; }
.rc-help-section h3:focus-visible { outline: 2px solid var(--rc-accent); outline-offset: 4px; }
.rc-help-section p,
.rc-help-section li,
.rc-help-section dd { line-height: 1.85; overflow-wrap: anywhere; }
.rc-help-section p { margin: 8px 0; }
.rc-help-section ol { padding-left: 24px; margin: 8px 0; }
.rc-help-section li { padding: 4px 0 4px 6px; }
.rc-help-definitions { display: grid; grid-template-columns: 140px minmax(0, 1fr); gap: 12px 20px; }
.rc-help-definitions dt { font-weight: 600; line-height: 1.85; }
.rc-help-definitions dd { margin: 0; color: var(--rc-text-muted); }
.rc-help-statuses { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.rc-help-statuses > div { padding: 14px; border: 1px solid var(--rc-line); border-radius: 8px; }
.rc-help-statuses p { color: var(--rc-text-muted); }
.rc-help-section details { border-bottom: 1px solid var(--rc-line-soft); padding: 12px 0; }
.rc-help-section summary { cursor: pointer; font-weight: 600; line-height: 1.7; }
.rc-help-section summary:hover,
.rc-help-section summary:active { color: var(--rc-accent); }
.rc-help-section summary:focus-visible { outline: 2px solid var(--rc-accent); outline-offset: 4px; }
.rc-help-section details p { margin-left: 18px; color: var(--rc-text-muted); }
@media (max-width: 900px) {
  .rc-help-layout { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .rc-help-toc { flex-direction: row; flex-wrap: wrap; gap: 4px; }
  .rc-help-toc strong { flex-basis: 100%; margin-left: 0; }
}
@media (max-width: 640px) {
  .rc-help { padding: 12px; }
  .rc-help-intro h1 { font-size: 21px; }
  .rc-help-definitions { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .rc-help-definitions dd { margin-bottom: 12px; }
  .rc-help-statuses { grid-template-columns: minmax(0, 1fr); }
}
.rc-reference-detail .rc-portal-actions { margin: 12px 0; flex-wrap: wrap; }
@media (max-width: 640px) {
  .rc-reference-detail th:first-child { width: 105px; }
  .rc-reference-filters input { flex-basis: 100%; }
  .rc-reference-tabs { gap: 4px 12px; }
}

@media (max-width: 1100px) {
  .rc-dashboard-table .rc-dashboard-col-time { display: none; }
  .rc-dashboard-table .rc-dashboard-col-model { width: 34%; }
  .rc-dashboard-table .rc-dashboard-col-access { width: 30%; }
  .rc-dashboard-table .rc-dashboard-col-result { width: 36%; }
}

@media (max-width: 640px) {
  .rc-dashboard-body { padding: 10px; }
  .rc-dashboard-metrics,
  .rc-dashboard-loading { grid-template-columns: minmax(0, 1fr); }
  .rc-dashboard-metric { min-height: 108px; }
  .rc-dashboard-steps { grid-template-columns: minmax(0, 1fr); }
  .rc-dashboard-states { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rc-dashboard-table .rc-dashboard-col-access { display: none; }
  .rc-dashboard-table .rc-dashboard-col-model { width: 50%; }
  .rc-dashboard-table .rc-dashboard-col-result { width: 50%; }
}

/* Multi-credential endpoint configuration. */
.rc-access-detail-table { min-width: 780px; table-layout: auto; }
.rc-access-detail-table td { overflow-wrap: anywhere; white-space: normal; }
.rc-access-detail-table .rc-inline-actions { flex-wrap: wrap; }
.rc-combination-body { padding: 12px; }
.rc-combination[hidden] { display: none; }

.rc-history-body .rc-table {
  min-width: 980px;
}

.rc-history-body .rc-table th {
  white-space: nowrap;
}

.rc-stress-body {
  padding: 16px;
}

.rc-stress-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: end;
  gap: 16px;
}

.rc-stress-form > :first-child,
.rc-stress-form > .rc-check-row,
.rc-stress-form > .rc-model-tab {
  grid-column: 1 / -1;
}

.rc-stress-form > .rc-button {
  justify-self: start;
}

@media (max-width: 700px) {
  .rc-history-panel .rc-panel-header {
    flex-wrap: wrap;
  }

  .rc-history-panel .rc-panel-actions {
    flex: 1 0 100%;
    flex-wrap: wrap;
  }

  .rc-history-panel .rc-panel-actions > .rc-input {
    flex: 1 0 100%;
  }

  .rc-stress-form {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Access details use the complete content area; nested tables scroll within it. */
[hidden] { display: none !important; }
.rc-access-detail { display: grid; gap: 16px; min-width: 0; }
.rc-access-detail .rc-access-section { min-width: 0; padding: 16px; }
.rc-access-detail .rc-access-section > h3 { margin-top: 0; }
.rc-access-detail .rc-access-section-header { flex-wrap: wrap; gap: 12px; }
.rc-access-detail .rc-access-section-header h3 { flex-shrink: 0; white-space: nowrap; }
.rc-access-detail .rc-access-section-header > .rc-inline-actions { flex-wrap: wrap; }
.rc-access-form-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.rc-access-models > table { min-width: 1440px; }
.rc-access-combinations > table { min-width: 1040px; }
.rc-access-detail-table th { white-space: nowrap; }
.rc-access-model-id { display: block; min-width: 170px; max-width: 240px; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis; }
.rc-access-note { min-width: 120px; max-width: 240px; overflow-wrap: anywhere; }
.rc-access-capabilities { display: flex; flex-wrap: wrap; gap: 4px; min-width: 200px; max-width: 280px; }
.rc-access-capability-options { display: flex; flex-wrap: wrap; gap: 12px; }
.rc-access-status-note:empty { display: none; }
.rc-access-switch { position: relative; width: 36px; height: 22px; padding: 2px; border: 0;
  border-radius: 12px; background: var(--rc-line); cursor: pointer; }
.rc-access-switch::after { content: ""; display: block; width: 18px; height: 18px; border-radius: 50%;
  background: var(--rc-surface); transition: transform 120ms ease; }
.rc-access-switch-on { background: var(--rc-accent); }
.rc-access-switch-on::after { transform: translateX(14px); }
.rc-access-switch:focus-visible { outline: 2px solid var(--rc-accent); outline-offset: 3px; }
@media (max-width: 900px) {
  .rc-access-form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 600px) {
  .rc-access-panel .rc-panel-header { flex-wrap: wrap; padding: 8px; }
  .rc-access-panel .rc-panel-actions > .rc-inline-actions { flex-wrap: wrap; }
  .rc-access-form-grid { grid-template-columns: minmax(0, 1fr); }
  .rc-access-detail .rc-access-section { padding: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .rc-access-switch::after { transition: none; }
}

/* Workflow context, protocol evidence and compact, readable actions. */
.rc-portal-actions,
.rc-portal-tabs,
.rc-portal-row-actions,
.rc-review-protocol-tabs,
.rc-review-steps,
.rc-review-coverage { flex-wrap: wrap; }
.rc-portal-actions > .rc-input { width: min(280px, 100%); }
.rc-portal-panel .rc-table { min-width: 880px; table-layout: auto; }
.rc-portal-panel .rc-table td { white-space: normal; overflow-wrap: anywhere; }
.rc-portal-row-actions { gap: 4px 10px; min-width: 112px; }
.rc-review-submit { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; min-width: 0; }
.rc-review-submit > * { min-width: 0; }
.rc-review-submit .rc-table-wrap { width: 100%; min-width: 0; }
.rc-review-submit .rc-table { min-width: 720px; }
.rc-review-submit .rc-table td { overflow-wrap: anywhere; }
.rc-review-protocol-tabs,
.rc-review-steps,
.rc-review-coverage { display: flex; gap: 8px; align-items: center; }
.rc-review-protocol-tabs { padding-bottom: 12px; border-bottom: 1px solid var(--rc-line); }
.rc-review-submit .rc-modal-actions { margin-top: 8px; }
.rc-review-evidence { border: 1px solid var(--rc-line); border-radius: 8px; padding: 14px; margin-block: 16px; }
.rc-review-evidence > summary { cursor: pointer; font-weight: 600; overflow-wrap: anywhere; }
.rc-review-evidence > p { overflow-wrap: anywhere; }
.rc-review-evidence .rc-table { min-width: 580px; }
.rc-review-notice,
.rc-workflow-context { padding: 12px 16px; border-radius: 8px; background: var(--rc-surface-muted); }
.rc-workflow-context:empty { display: none; }
.rc-workflow-context > p { margin: 0 0 8px; }
.rc-workflow-target { background: var(--rc-surface-muted); outline: 2px solid var(--rc-accent); outline-offset: -2px; }
@media (max-width: 720px) {
  .rc-portal-actions { width: 100%; gap: 8px; }
  .rc-portal-actions > .rc-input { flex: 1 1 180px; }
  .rc-portal-panel .rc-portal-vendor,
  .rc-portal-panel .rc-portal-group { display: table-cell; }
  .rc-review-submit { gap: 12px; }
  .rc-review-evidence { padding: 10px; }
  .rc-review-protocol-tabs > .rc-button { flex: 1 1 180px; }
}

.rc-review-modal { width: 1000px; }
.rc-review-submit .rc-descriptions,
.rc-portal-detail .rc-descriptions { grid-template-columns: 112px minmax(0, 1fr); }
.rc-review-submit .rc-descriptions dt,
.rc-review-submit .rc-descriptions dd,
.rc-portal-detail .rc-descriptions dt,
.rc-portal-detail .rc-descriptions dd { padding: 10px 12px; overflow-wrap: anywhere; }
.rc-review-submit .rc-description-full-value,
.rc-portal-detail .rc-description-full-value { grid-column: 2; }
.rc-review-submit .rc-table { min-width: 900px; table-layout: auto; }
.rc-review-submit .rc-table td { white-space: normal; }
.rc-review-submit .rc-table td:first-child,
.rc-review-submit .rc-table th:first-child { min-width: 64px; white-space: nowrap; }
.rc-review-submit .rc-table td:nth-child(2) { white-space: nowrap; }
@media (max-width: 480px) {
  .rc-review-submit .rc-descriptions,
  .rc-portal-detail .rc-descriptions { grid-template-columns: 88px minmax(0, 1fr); }
}

/* Reports stay visible beside the other row actions at every table width. */
.rc-tests-table .rc-tests-col-actions { white-space: normal; }
.rc-tests-row-actions { align-items: flex-start; flex-wrap: wrap; gap: 4px 8px; }
.rc-report-control { display: inline-flex; flex-direction: column; align-items: flex-start; max-width: 100%; }
.rc-report-status { color: var(--rc-text-muted); line-height: 18px; overflow-wrap: anywhere; white-space: normal; }
.rc-report-status:empty { display: none; }
.rc-report-section { margin-block: 16px; padding: 12px; border: 1px solid var(--rc-line); border-radius: 8px; }
.rc-report-section h3 { margin: 0; font-size: 14px; }
.rc-report-evidence { margin-block: 12px; }
.rc-report-evidence > summary { cursor: pointer; color: var(--rc-text-muted); }
.rc-history-body .rc-inline-actions { align-items: flex-start; flex-wrap: wrap; white-space: normal; }

/* Keep the primary outcome separate from the two supporting coverage counts. */
.rc-tests-col-result > div {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
  gap: 4px 10px;
}
.rc-tests-col-result .rc-tag {
  grid-column: 1 / -1;
  justify-self: start;
  max-width: 100%;
  white-space: normal;
  overflow-wrap: anywhere;
}
.rc-tests-col-result .rc-progress,
.rc-tests-col-result .rc-history-alert { grid-column: 1 / -1; }
/* Counts wrap inside their own grid cell instead of running into the next one. */
.rc-tests-table td.rc-tests-col-result { white-space: normal; }
.rc-tests-col-result > div > * { min-width: 0; overflow-wrap: anywhere; }
.rc-tests-row-actions .rc-report-status,
.rc-history-body .rc-report-status { padding-inline: 8px; }

/* Reference-style row actions: compact icons, with labels available on hover and focus. */
.rc-sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.rc-tests-row-actions,
.rc-history-row-actions { align-items: center; justify-content: flex-end; flex-wrap: nowrap; gap: 8px; }
.rc-button.rc-row-action { width: 28px; min-width: 28px; height: 28px; min-height: 28px;
  padding: 0; font-size: 14px; line-height: 22px; border: 0; border-radius: 6px; }
.rc-row-action > .rc-icon { width: 16px; height: 16px; }
.rc-row-action:hover:not(:disabled) { background: var(--rc-accent-soft); }
.rc-row-more { display: inline-flex; flex: 0 0 auto; }
.rc-report-control-icon { position: relative; display: inline-flex; flex: 0 0 auto; }
.rc-report-control-icon .rc-report-status { position: absolute; width: 1px; height: 1px;
  overflow: hidden; clip-path: inset(50%); white-space: nowrap; padding: 0; }
.rc-report-control-icon[data-report-state="failed"] .rc-row-action { color: var(--rc-warn); }
.rc-row-menu { position: fixed; z-index: 140; left: var(--rc-menu-x); top: var(--rc-menu-y);
  width: 168px; padding: 4px; border: 1px solid var(--rc-line); border-radius: 6px;
  background: var(--rc-surface); box-shadow: var(--rc-shadow-popup); }
.rc-row-menu .rc-row-menu-item { display: flex; width: 100%; height: 36px; padding: 0 12px;
  justify-content: flex-start; font-size: 14px; text-decoration: none; color: var(--rc-text); }
.rc-row-menu-item:hover { background: var(--rc-hover); }
@container rc-tests (max-width: 840px) {
  .rc-tests-row-actions { justify-content: flex-start; }
  .rc-tests-row-actions .rc-button.rc-row-action { width: 36px; min-width: 36px; height: 36px; }
}
@container rc-tests (max-width: 480px) {
  .rc-tests-row-actions .rc-button.rc-row-action { width: 40px; min-width: 40px; height: 40px; }
}

.rc-toast-success { color: var(--rc-ok); background: var(--rc-ok-bg); border-color: var(--rc-ok-bd); }

.rc-tests-table th.rc-tests-col-actions { text-align: right; padding-right: 12px; }
.rc-history-body .rc-table th:last-child { text-align: right; }

.rc-upstream-accounts-table { min-width: 960px; }
.rc-upstream-accounts-table th:last-child { width: 340px; }
.rc-upstream-accounts-table td:last-child { overflow: visible; }
.rc-upstream-accounts-table .rc-inline-actions { flex-wrap: wrap; }
.rc-upstream-accounts-panel .rc-panel-actions > .rc-inline-actions { flex-wrap: wrap; }
.rc-history-alert {
  display: block; color: var(--rc-text); font-size: 12px;
  white-space: normal; overflow-wrap: anywhere;
}
.rc-availability-warning {
  padding: 10px 12px; border-left: 3px solid var(--rc-warn); background: var(--rc-warn-bg);
  color: var(--rc-text); white-space: normal;
}
.rc-launch-group-control { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

/* Images are derived only from stored evidence; thumbnails never load upstream URLs. */
.rc-image-evidence { margin: 12px 0; }
.rc-image-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
  gap: 12px;
}
.rc-image-card {
  margin: 0;
  padding: 12px;
  border: 1px solid var(--rc-line);
  border-radius: 6px;
  overflow-wrap: anywhere;
}
.rc-image-card figcaption { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.rc-image-preview { display: block; width: 100%; height: 180px; object-fit: contain; margin: 12px 0; }
.rc-image-hash { display: flex; flex-direction: column; gap: 4px; font-size: 11px; }
.rc-image-hash .rc-drawer-copy { min-width: 0; overflow-wrap: anywhere; }

/* Accounts: identity link, scope pickers. */
a.rc-user { color: inherit; text-decoration: none; border-radius: 6px; }
a.rc-user:hover { background: var(--rc-hover); }
a.rc-user:focus-visible { outline: 2px solid var(--rc-focus); }
.rc-scope-picker {
  display: grid;
  gap: 8px;
  max-height: 280px;
  margin: 0;
  padding: 8px 12px;
  overflow: auto;
  border: 1px solid var(--rc-line);
  border-radius: 6px;
}
.rc-scope-picker legend { padding: 0 4px; color: var(--rc-text-muted); }
.rc-scope-group { display: grid; gap: 4px; }
.rc-scope-group > .rc-check-row + .rc-check-row { padding-left: 24px; }
.rc-portal-panel .rc-accounts-actions-col { width: 248px; }
