/* Shared tokens and reusable primitives for the app shell.
   Keep this file route-agnostic: add new shared classes here only when
   multiple pages need them, and prefer `np-*` names for reusable pieces. */
:root {
  --brand-primary: #62C1BF;
  --brand-primary-hover: #4EAAA8;
  --brand-soft: #E5F6F5;
  --brand-muted: #BFE8E7;
  --brand-color: #62C1BF;

  --sidebar-light: #EEF2F6;
  --sidebar-light-border: #DDE3EA;
  --sidebar-active: #DDF4F3;

  --page-bg: #FAFBFC;
  --card-bg: #FFFFFF;
  --surface-subtle: #FAFBFC;
  --border: #DDE3EA;
  --border-soft: #E8EDF2;

  --text-main: #1F2937;
  --text-secondary: #6B7280;
  --text-muted: #9CA3AF;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;

  --success-bg: #E7F6EC;
  --success-text: #1F7A3A;
  --warning-bg: #FFF4D6;
  --warning-text: #A15C00;
  --danger-bg: #FDECEC;
  --danger-text: #B42318;
  --info-bg: #EAF2FF;
  --info-text: #225EA8;
  --neutral-bg: #EEF2F6;
  --neutral-text: #4B5563;

  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-6: 24px;
  --space-8: 32px;
  --space-12: 48px;

  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 14px;

  --shadow-card: 0 1px 2px rgba(15, 23, 42, 0.06);
  --shadow-panel: 0 12px 30px rgba(15, 23, 42, 0.12);

  --np-sidebar-width: 223px;
}

body {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  background: var(--page-bg);
  color: var(--text-main);
  font-family: "IBM Plex Sans", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: inherit;
}

.np-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: 40px;
  padding: 0 var(--space-4);
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  font-family: "IBM Plex Sans", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.16s ease, border-color 0.16s ease, color 0.16s ease, box-shadow 0.16s ease;
}

.np-btn-primary {
  background: var(--brand-primary);
  border-color: var(--brand-primary);
  color: #000000;
}

.np-btn-primary:hover,
.np-btn-primary:focus {
  background: var(--brand-primary-hover);
  border-color: var(--brand-primary-hover);
  color: #0B2425;
}

.np-btn-secondary {
  background: var(--card-bg);
  border-color: var(--border);
  color: var(--text-main);
}

.np-btn-secondary:hover,
.np-btn-secondary:focus {
  background: var(--brand-soft);
  border-color: var(--brand-muted);
  color: #206E6C;
}

.np-btn-success {
  background: var(--success-bg);
  border-color: rgba(31, 122, 58, 0.16);
  color: var(--success-text);
}

.np-btn-success:hover,
.np-btn-success:focus {
  background: #D8F0E0;
  border-color: rgba(31, 122, 58, 0.24);
  color: #14502A;
}

.np-btn-danger {
  background: var(--danger-bg);
  border-color: rgba(180, 35, 24, 0.16);
  color: var(--danger-text);
}

.np-btn-danger:hover,
.np-btn-danger:focus {
  background: #F9DDDD;
  border-color: rgba(180, 35, 24, 0.24);
  color: #8E1F14;
}

.np-btn-ghost {
  background: transparent;
  border-color: var(--border);
  color: var(--text-main);
}

.np-btn-ghost:hover,
.np-btn-ghost:focus {
  background: var(--surface-subtle);
  border-color: var(--brand-muted);
  color: #206E6C;
}

.np-btn-text {
  min-height: 36px;
  padding: 0 var(--space-2);
  background: transparent;
  border-color: transparent;
  color: #206E6C;
}

.np-btn-text:hover,
.np-btn-text:focus {
  background: var(--brand-soft);
  color: #206E6C;
}

.np-btn-icon {
  width: 40px;
  min-width: 40px;
  padding: 0;
  aspect-ratio: 1 / 1;
}

.np-btn-icon-sm {
  width: 36px;
  min-width: 36px;
  min-height: 36px;
}

.np-btn-sm {
  min-height: 34px;
  padding: 0 var(--space-3);
  font-size: 13px;
}

.np-btn-lg {
  min-height: 44px;
  padding: 0 var(--space-5);
  font-size: 15px;
}

.logs-dropdown-btn {
  height: 20px;
  min-height: 20px;
  padding: 0 9px;
  font-size: 12px;
  line-height: 1;
}

.logs-dropdown {
  display: block;
  position: relative;
  width: 100%;
}

.logs-dropdown-menu {
  /* min-width: 180px;
  padding: 0.25rem;
  overflow: hidden; */
  right: 0;
  left: auto;
}

.logs-dropdown-menu .dropdown-item,
.logs-dropdown-menu .dropdown-item-text {
  min-height: 38px;
  padding: 0.25rem 0.5rem;
  line-height: 1.2;
  white-space: normal;
  word-break: break-word;
  width: 100%;
  box-sizing: border-box;
}

.logs-dropdown-menu .dropdown-item-text {
  display: block;
}

.np-btn-icon .bi,
.np-btn-icon svg,
.np-btn-icon-sm .bi,
.np-btn-icon-sm svg {
  width: 1em;
  height: 1em;
  font-size: 1rem;
  line-height: 1;
}

.dropdown-menu {
  --bs-dropdown-padding-x: 0.5rem;
  --bs-dropdown-padding-y: 0.5rem;
}

.np-dropdown-menu {
  min-width: 220px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-panel);
}

.np-dropdown-menu-sm {
  min-width: 180px;
}

.np-dropdown-menu-md {
  min-width: 220px;
}

.np-dropdown-menu-lg {
  min-width: 250px;
}

.np-dropdown-menu-xl {
  min-width: 320px;
}

.np-dropdown-menu .dropdown-item {
  display: flex;
  align-items: center;
  min-height: 38px;
  padding: 0.6rem 0.75rem;
  border-radius: var(--radius-md);
  color: var(--text-main);
  font-size: 14px;
  line-height: 1.2;
  transition: background-color 0.16s ease, color 0.16s ease;
}

.np-dropdown-menu .dropdown-item:hover,
.np-dropdown-menu .dropdown-item:focus {
  background: var(--brand-soft);
  color: #206E6C;
}

.np-dropdown-menu .dropdown-item:active,
.np-dropdown-menu .dropdown-item.active {
  background: var(--brand-muted);
  color: #0F4F4D;
}

.np-dropdown-menu .dropdown-divider {
  margin: var(--space-2) 0;
}

.np-select,
.np-search-input {
  min-height: 40px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background-color: var(--card-bg);
  color: var(--text-main);
  font-family: "IBM Plex Sans", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 14px;
  line-height: 1.3;
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}

.np-select {
  width: 180px;
  padding: 0 34px 0 var(--space-3);
  appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--text-secondary) 50%),
    linear-gradient(135deg, var(--text-secondary) 50%, transparent 50%);
  background-position:
    calc(100% - 18px) 17px,
    calc(100% - 12px) 17px;
  background-repeat: no-repeat;
  background-size: 6px 6px, 6px 6px;
}

.np-search {
  position: relative;
  flex: 1 1 280px;
  min-width: 220px;
}

.np-search::before {
  content: "";
  position: absolute;
  left: var(--space-3);
  top: 50%;
  width: 14px;
  height: 14px;
  border: 2px solid var(--text-muted);
  border-radius: 999px;
  transform: translateY(-55%);
  pointer-events: none;
}

.np-search::after {
  content: "";
  position: absolute;
  left: 25px;
  top: 24px;
  width: 7px;
  height: 2px;
  border-radius: 999px;
  background: var(--text-muted);
  transform: rotate(45deg);
  pointer-events: none;
}

.np-search-input {
  width: 100%;
  padding: 0 var(--space-3) 0 38px;
}

.np-search-input::placeholder {
  color: var(--text-muted);
}

.np-form-shell {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.np-form-shell--wide {
  width: 704px;
  padding: 0 var(--space-4);
}

.np-inline-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: var(--space-2);
  width: 100%;
}

.np-inline-controls > .form-control,
.np-inline-controls > .form-select,
.np-inline-controls > .np-search {
  flex: 1 1 180px;
  min-width: 0;
}

.np-inline-controls > .np-btn {
  flex: 0 0 auto;
}

.np-inline-controls--tight > .form-control,
.np-inline-controls--tight > .form-select {
  flex-basis: 160px;
}

.np-inline-controls--search > .form-control,
.np-inline-controls--search > .form-select {
  flex-basis: 200px;
}

.np-form-panel {
  width: 100%;
  min-width: 0;
  padding: var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--card-bg);
  color: var(--text-main);
  font-size: 14px;
  line-height: 1.3;
  overflow-y: auto;
}

.np-form-panel--sm {
  min-height: 120px;
  max-height: 120px;
}

.np-form-panel--md {
  min-height: 150px;
  max-height: 150px;
}

.np-form-panel--lg {
  min-height: 160px;
  max-height: 160px;
}

.np-form-panel--xl {
  min-height: 200px;
  max-height: 200px;
}

.np-form-panel--no-min {
  min-height: 0;
}

.np-form-field {
  width: min(100%, 310px);
  max-width: 100%;
}

.np-form-field--compact {
  width: min(100%, 180px);
}

.np-form-field--wide {
  width: min(100%, 360px);
}

.np-form-label {
  display: block;
  margin: 0 0 var(--space-2);
  color: var(--text-main);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.25;
}

.np-form-control,
.np-form-select {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background-color: var(--card-bg);
  color: var(--text-main);
  font-family: "IBM Plex Sans", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 15px;
  line-height: 1.35;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}

.np-form-control {
  padding: 9px var(--space-3);
}

.np-form-select {
  padding: 9px 36px 9px var(--space-3);
}

.np-form-control::placeholder {
  color: var(--text-muted);
  opacity: 1;
  font-weight: 500;
}

.np-form-control:focus,
.np-form-select:focus {
  outline: none;
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 3px rgba(98, 193, 191, 0.18);
}

.np-form-control.is-invalid,
.np-form-select.is-invalid {
  border-color: var(--danger-text);
}

.np-form-help {
  margin-top: var(--space-2);
  color: var(--text-secondary);
  font-size: 13px;
  line-height: 1.35;
}

.np-check-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  align-items: center;
}

.np-check,
.np-check.form-check {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  min-height: 28px;
  /* padding-left: 0; */
  /* margin-bottom: 0; */
}

.np-check-input,
.np-check.form-check > .np-check-input.form-check-input {
  appearance: none;
  -webkit-appearance: none;
  float: none;
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  margin: 0;
  margin-left: 0;
  background-color: var(--card-bg);
  background-position: center;
  background-repeat: no-repeat;
  background-size: 12px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background-color 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.np-check-input--xs,
.np-check.form-check > .np-check-input--xs.form-check-input {
  width: 12px;
  height: 12px;
}

.np-check-input--sm,
.np-check.form-check > .np-check-input--sm.form-check-input {
  width: 16px;
  height: 16px;
}

.np-check-input--md,
.np-check.form-check > .np-check-input--md.form-check-input {
  width: 18px;
  height: 18px;
}

.np-check-input--lg,
.np-check.form-check > .np-check-input--lg.form-check-input {
  width: 20px;
  height: 20px;
}

.np-check-input:hover,
.np-check.form-check > .np-check-input.form-check-input:hover {
  border-color: var(--brand-primary-hover);
  box-shadow: 0 0 0 3px var(--brand-soft);
}

.np-check-input:focus,
.np-check.form-check > .np-check-input.form-check-input:focus {
  border-color: var(--brand-primary-hover);
  box-shadow: 0 0 0 3px rgba(98, 193, 191, 0.28);
}

.np-check-input:checked,
.np-check.form-check > .np-check-input.form-check-input:checked {
  background-color: var(--brand-primary);
  border-color: var(--brand-primary);
  background-image: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M13.5 4.5 6.5 11.5 3 8' stroke='%23ffffff' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3e%3c/svg%3e");
}

.np-check-input:checked:hover,
.np-check.form-check > .np-check-input.form-check-input:checked:hover {
  background-color: var(--brand-primary-hover);
  border-color: var(--brand-primary-hover);
}

.np-check-input:disabled,
.np-check.form-check > .np-check-input.form-check-input:disabled {
  background-color: var(--neutral-bg);
  border-color: var(--border-soft);
  box-shadow: none;
  cursor: not-allowed;
  opacity: 0.8;
}

.np-check-label {
  color: var(--text-main);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.25;
}

.np-modal-dialog-sm {
  max-width: 375px;
}

.np-modal-dialog-md {
  max-width: 640px;
}

.np-modal-dialog-lg {
  max-width: 960px;
}

.np-modal-dialog-xl {
  max-width: min(1280px, calc(100vw - 2rem));
}

.np-modal-dialog-fit {
  width: fit-content;
  max-width: min(70vw, calc(100vw - 2rem));
}

.np-modal-content-fill {
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.np-modal-content {
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-lg);
  background: var(--card-bg);
  box-shadow: var(--shadow-panel);
  overflow: hidden;
}

.np-modal-content-soft {
  background-color: #f2f2f2;
}

.np-form-modal-scroll {
  max-height: calc(100vh - 200px);
  overflow-y: auto;
}

.np-modal-body-scroll {
  min-height: 0;
  overflow-y: auto;
}

.np-modal-body-soft {
  background: var(--surface-subtle);
}

.np-modal-feedback {
  max-height: calc(10 * 1.5em);
  overflow-y: auto;
}

.np-wizard-modal {
  width: 100%;
}

.np-wizard {
  display: flex;
  flex-direction: column;
  min-height: 0;
  padding: var(--space-6);
}

.np-wizard-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-4);
  margin-bottom: var(--space-6);
}

.np-wizard-title {
  margin: 0;
  color: var(--text-main);
  font-size: 22px;
  font-weight: 700;
  line-height: 1.2;
}

.np-wizard-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  min-width: 36px;
  height: 36px;
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  background: var(--surface-subtle);
  color: var(--text-secondary);
  font-size: 22px;
  font-weight: 500;
  line-height: 1;
  cursor: pointer;
  transition: background-color 0.16s ease, border-color 0.16s ease, color 0.16s ease;
}

.np-wizard-close:hover,
.np-wizard-close:focus {
  outline: none;
  background: var(--brand-soft);
  border-color: var(--brand-muted);
  color: #206E6C;
}

.np-wizard-progress {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-6);
}

.np-wizard-dot {
  display: inline-block;
  width: 9px;
  height: 9px;
  flex: 0 0 auto;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: var(--border);
  cursor: pointer;
  transition: width 0.16s ease, background-color 0.16s ease;
}

.np-wizard-dot.is-active,
.np-wizard-dot.is-complete {
  background: var(--brand-primary);
}

.np-wizard-dot:focus-visible {
  outline: 2px solid var(--brand-primary);
  outline-offset: 3px;
}

.np-wizard-dot.is-active {
  width: 26px;
}

.np-wizard-progress-text {
  margin-left: var(--space-2);
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.3;
}

.np-wizard-body {
  min-height: 270px;
  max-height: calc(88vh - 210px);
  overflow-y: auto;
  padding-right: 2px;
}

.np-wizard-step {
  display: none;
}

.np-wizard-step.is-active {
  display: block;
}

.np-wizard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: start;
  gap: var(--space-4);
}

.np-wizard-field {
  display: flex;
  flex-direction: column;
  min-width: 0;
  margin-bottom: var(--space-4);
}

.np-wizard-field--full {
  width: 100%;
}

.np-wizard-inline .np-btn {
  min-height: 44px;
}

.np-wizard-dropdown {
  min-height: 44px;
}

.np-wizard-field > .np-wizard-dropdown {
  width: 100%;
}

.np-wizard-inline > .np-search {
  flex: 1 1 220px;
  min-width: 0;
}

.np-wizard-inline > .np-wizard-dropdown {
  flex: 0 0 160px;
  width: auto;
}

.np-wizard-dropdown > .np-btn {
  min-height: 44px;
}

.np-wizard-dropdown > .np-split-dropdown__label {
  min-width: 0;
}

.np-wizard-dropdown .dropdown-menu {
  min-width: 100%;
}

.np-wizard-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  margin-top: var(--space-6);
}

.np-wizard-save-note {
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 700;
}

.np-wizard-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: var(--space-2);
}

.np-wizard-review-list {
  display: grid;
  gap: var(--space-3);
  margin: 0;
}

.np-wizard-review-row {
  display: grid;
  grid-template-columns: minmax(120px, 0.45fr) minmax(0, 1fr);
  gap: var(--space-3);
  padding: var(--space-3);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-md);
  background: var(--surface-subtle);
}

.np-wizard-review-label {
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.25;
  text-transform: uppercase;
}

.np-wizard-review-value {
  min-width: 0;
  color: var(--text-main);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.np-record-modal,
.np-rerun-modal {
  width: 100%;
  min-height: min(580px, calc(88vh - 2px));
}

.np-rerun-modal {
  min-height: 0;
}

.np-record-modal__header,
.np-rerun-modal__header {
  align-items: flex-start;
  margin-bottom: var(--space-4);
}

.np-record-modal__heading,
.np-rerun-modal__heading {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.np-record-modal__subtitle,
.np-rerun-modal__subtitle {
  margin: 0;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.35;
}

.np-record-modal__subtitle {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.np-rerun-modal__subtitle {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.np-record-modal__body,
.np-rerun-modal__body {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  gap: var(--space-4);
  min-height: 0;
}

.np-record-modal__summary,
.np-rerun-modal__summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-3);
  padding: var(--space-4);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-md);
  background: var(--surface-subtle);
}

.np-record-modal__summary {
  gap: var(--space-4);
  padding: var(--space-3) var(--space-4);
  border: 0;
}

.np-rerun-modal__summary {
  gap: var(--space-4);
  padding: var(--space-3) var(--space-4);
  border: 0;
}

.np-record-modal__summary-item {
  min-width: 0;
}

.np-record-modal__summary-label {
  display: block;
  margin-bottom: 4px;
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1.2;
  text-transform: uppercase;
}

.np-record-modal__summary-value {
  display: block;
  min-width: 0;
  overflow: hidden;
  color: var(--text-main);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.np-record-modal__details,
.np-rerun-modal__selection {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  min-height: 260px;
  overflow: hidden;
}

.np-record-modal__details.np-card {
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.np-record-modal__details {
  min-height: 0;
}

.np-rerun-modal__selection.np-card {
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.np-rerun-modal__selection {
  min-height: 0;
}

.np-record-modal__details-header,
.np-rerun-modal__selection-header {
  flex: 0 0 auto;
  align-items: flex-start;
  gap: var(--space-3);
  padding-right: var(--space-4);
  padding-left: var(--space-4);
}

.np-record-modal__details-header {
  padding-right: 0;
  padding-left: 0;
}

.np-rerun-modal__selection-header {
  align-items: center;
  padding-right: 0;
  padding-left: 0;
}

.np-record-modal__details-header .np-card-title,
.np-rerun-modal__selection-header .np-card-title {
  color: var(--text-main);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.25;
}

.np-record-modal__details-body,
.np-rerun-modal__selection-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  padding: var(--space-4);
}

.np-record-modal__details-body {
  padding: var(--space-3) 0 0;
}

.np-rerun-modal__selection-body {
  padding: var(--space-3) 0 0;
}

.np-record-modal__detail-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  margin: 0;
  border-top: 1px solid var(--border-soft);
}

.np-record-modal__detail-item {
  display: grid;
  grid-template-columns: minmax(128px, 0.4fr) minmax(0, 1fr);
  gap: var(--space-4);
  min-width: 0;
  padding: 11px 0;
  border-bottom: 1px solid var(--border-soft);
  background: transparent;
}

.np-record-modal__detail-item dt {
  margin: 0;
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1.2;
  text-transform: uppercase;
}

.np-record-modal__detail-item dd {
  min-width: 0;
  margin: 0;
  overflow: hidden;
  color: var(--text-main);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.np-record-modal__detail-value--html {
  white-space: normal;
}

.np-record-modal__chip-row {
  gap: 6px;
}

.np-record-modal__chip-row .np-chip {
  min-width: 28px;
  min-height: 24px;
  padding-right: 8px;
  padding-left: 8px;
}

.np-record-modal__modality-badge {
  gap: 4px;
  border: 1px solid transparent;
  text-transform: none;
}

.np-record-modal__modality-badge .bi {
  flex: 0 0 auto;
  color: var(--np-modality-native-color, currentColor);
  font-size: 14px;
  line-height: 1;
}

.np-record-modal__modality-badge--accepted {
  --np-modality-native-color: green;
  border-color: color-mix(in srgb, var(--success-text) 28%, transparent);
  background: var(--success-bg);
  color: var(--success-text);
}

.np-record-modal__modality-badge--rejected {
  --np-modality-native-color: red;
  border-color: color-mix(in srgb, var(--danger-text) 28%, transparent);
  background: var(--danger-bg);
  color: var(--danger-text);
}

.np-record-modal__modality-badge--not-scored {
  --np-modality-native-color: currentColor;
  border-color: color-mix(in srgb, var(--neutral-text) 24%, transparent);
  background: var(--neutral-bg);
  color: var(--neutral-text);
}

.np-rerun-modal__legend {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: var(--space-2);
  margin-left: auto;
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.2;
}

.np-rerun-modal__legend span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}

.np-rerun-modal__option-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  border-top: 1px solid var(--border-soft);
}

.np-rerun-modal__option {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: var(--space-3);
  min-width: 0;
  margin: 0;
  padding: 11px 0;
  border: 0;
  border-bottom: 1px solid var(--border-soft);
  border-radius: 0;
  background: transparent;
}

.np-rerun-modal__checkbox {
  margin: 0;
}

.np-rerun-modal__option-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  min-width: 0;
  margin: 0;
  cursor: pointer;
}

.np-rerun-modal__option-name {
  min-width: 0;
  overflow: hidden;
  color: var(--text-main);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.np-rerun-modal__option-status {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 5px;
  min-height: 24px;
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--surface-subtle);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.2;
}

.np-rerun-modal__option-status--accepted {
  background: var(--success-bg);
  color: var(--success-text);
}

.np-rerun-modal__option-status--rejected {
  background: var(--danger-bg);
  color: var(--danger-text);
}

.np-rerun-modal__option-status--not-scored {
  background: var(--neutral-bg);
  color: var(--neutral-text);
}

.np-record-modal__footer,
.np-rerun-modal__footer {
  display: flex;
  flex: 0 0 auto;
  align-items: stretch;
  flex-direction: column;
  gap: var(--space-3);
  padding-top: var(--space-4);
  border-top: 1px solid var(--border-soft);
}

.np-record-modal__note,
.np-rerun-modal__note {
  max-width: none;
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.4;
}

.np-record-modal__actions,
.np-rerun-modal__actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: nowrap;
  gap: var(--space-2);
  min-width: 0;
  width: 100%;
}

.np-rerun-modal__actions .np-btn {
  flex: 0 0 auto;
  min-width: 118px;
  padding-right: 10px;
  padding-left: 10px;
  white-space: nowrap;
}

.np-record-modal__actions .np-btn {
  flex: 0 0 auto;
  min-width: 92px;
  white-space: nowrap;
}

.np-rerun-modal__empty {
  margin: auto;
  max-width: 420px;
  text-align: center;
}

@media (max-width: 640px) {
  .np-wizard {
    padding: var(--space-4);
  }

  .np-wizard-title {
    font-size: 20px;
  }

  .np-wizard-progress {
    align-items: flex-start;
    flex-wrap: wrap;
    gap: var(--space-2);
  }

  .np-wizard-progress-text {
    flex: 1 1 100%;
    margin-left: 0;
  }

  .np-wizard-grid {
    grid-template-columns: 1fr;
  }

  .np-wizard-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .np-wizard-actions,
  .np-wizard-actions .np-btn {
    width: 100%;
  }

  .np-wizard-review-row {
    grid-template-columns: 1fr;
  }

  .np-record-modal,
  .np-rerun-modal {
    min-height: 0;
  }

  .np-record-modal__summary,
  .np-rerun-modal__summary,
  .np-record-modal__detail-list,
  .np-rerun-modal__option-grid {
    grid-template-columns: 1fr;
  }

  .np-record-modal__details-header,
  .np-rerun-modal__selection-header {
    flex-direction: column;
    padding-left: var(--space-4);
  }

  .np-record-modal__details-header {
    padding-left: 0;
  }

  .np-rerun-modal__selection-header {
    padding-left: 0;
  }

  .np-record-modal__detail-item {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .np-record-modal__actions {
    align-items: stretch;
    flex-direction: column;
  }

  .np-rerun-modal__actions {
    align-items: stretch;
    flex-direction: column;
  }

  .np-record-modal__actions .np-btn,
  .np-rerun-modal__actions .np-btn {
    width: 100%;
  }

  .np-rerun-modal__legend {
    margin-left: 0;
  }
}

.np-progress {
  height: 1rem;
  background: var(--border-soft);
  border-radius: 999px;
  overflow: hidden;
}

.np-progress .progress-bar,
.np-progress__bar {
  background: linear-gradient(90deg, var(--brand-primary), var(--brand-primary-hover));
  color: #0b2425;
  font-weight: 700;
}

.np-progress--striped .progress-bar,
.np-progress--striped .np-progress__bar {
  background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.18) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.18) 50%, rgba(255, 255, 255, 0.18) 75%, transparent 75%, transparent);
  background-size: 1rem 1rem, 100% 100%;
}

.np-loader {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
}

.np-loader__bar {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 999px;
  background: var(--brand-primary);
  animation: np-loader-bounce 1.05s ease-in-out infinite;
}

.np-loader__bar:nth-child(2) {
  animation-delay: 0.12s;
}

.np-loader__bar:nth-child(3) {
  animation-delay: 0.24s;
}

.np-loader__bar:nth-child(4) {
  animation-delay: 0.36s;
}

.np-loader__bar:nth-child(5) {
  animation-delay: 0.48s;
}

.np-loader__bar:nth-child(6) {
  animation-delay: 0.6s;
}

@keyframes np-loader-bounce {
  0%, 80%, 100% {
    transform: translateY(0);
    opacity: 0.65;
  }

  40% {
    transform: translateY(-0.45rem);
    opacity: 1;
  }
}

.np-select:focus,
.np-search-input:focus,
.np-btn:focus {
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 3px rgba(98, 193, 191, 0.22);
  outline: 0;
}

.np-filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-3);
  width: 100%;
  padding: var(--space-3) var(--space-4);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface-subtle);
  box-shadow: var(--shadow-card);
}

@media (max-width: 720px) {
  .np-filter-bar {
    align-items: stretch;
  }

  .np-filter-bar .np-select,
  .np-filter-bar .np-search,
  .np-filter-bar .np-btn {
    width: 100%;
  }

  .np-filter-bar .np-search {
    min-width: 100%;
  }
}

@media (max-width: 768px) {
  .np-form-shell--wide {
    width: 100%;
    padding: 0 var(--space-3);
  }

  .np-inline-controls,
  .np-inline-controls > .np-search {
    width: 100%;
  }

  .np-form-field,
  .np-form-field--compact,
  .np-form-field--wide {
    width: 100%;
  }
}

.np-split-action,
.np-split-dropdown {
  display: inline-flex;
  align-items: stretch;
}

.np-split-action > .np-btn,
.np-split-dropdown > .np-btn {
  border-radius: 0;
}

.np-split-action > .np-btn:first-child,
.np-split-dropdown > .np-btn:first-child {
  border-top-left-radius: var(--radius-md);
  border-bottom-left-radius: var(--radius-md);
  flex: 1 1 auto;
}

.np-split-action > .np-split-toggle,
.np-split-dropdown > .np-split-dropdown-toggle {
  flex: 0 0 auto;
  min-width: 42px;
  padding-inline: 0.65rem;
  border-left-color: rgba(255, 255, 255, 0.22);
  border-top-right-radius: var(--radius-md);
  border-bottom-right-radius: var(--radius-md);
}

.np-split-action > .np-split-toggle,
.np-split-dropdown > .np-split-dropdown-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.np-split-action > .np-split-toggle::after,
.np-split-dropdown > .np-split-dropdown-toggle::after {
  margin-left: 0;
}

.np-split-action .dropdown-menu,
.np-split-dropdown .dropdown-menu {
  min-width: 220px;
}

/* Radio toggle button group */
.btn-check {
  position: absolute;
  clip: rect(0, 0, 0, 0);
  pointer-events: none;
}

.np-btn-radio {
  background: var(--card-bg);
  border-color: var(--border);
  color: var(--text-main);
  border-radius: 0;
  margin-left: -1px;
}

.btn-group > .btn-check:first-child + .np-btn-radio {
  margin-left: 0;
  border-top-left-radius: var(--radius-md);
  border-bottom-left-radius: var(--radius-md);
}

.btn-group > .np-btn-radio:last-child {
  border-top-right-radius: var(--radius-md);
  border-bottom-right-radius: var(--radius-md);
}

.np-btn-radio:hover {
  background: var(--brand-soft);
  border-color: var(--brand-muted);
  color: #206E6C;
  z-index: 1;
}

.btn-check:checked + .np-btn-radio {
  background: var(--brand-soft);
  border-color: var(--brand-primary);
  color: #206E6C;
  z-index: 1;
}

.btn-check:focus + .np-btn-radio {
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 3px rgba(98, 193, 191, 0.22);
  outline: 0;
  z-index: 2;
}

.np-page {
  min-height: 100vh;
}

.np-page-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  width: 100%;
  min-width: 0;
  margin-bottom: 0;
}

.np-page-header--compact,
.projects-page .project-page-topbar,
.overview-page .overview-topbar {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  width: 100%;
  min-width: 0;
  min-height: 52px;
  padding: 2px 4px 0;
}

.np-page-header--compact .np-page-header__left,
.projects-page .project-page-topbar-left,
.overview-page .overview-topbar-left {
  display: flex;
  align-items: center;
  min-width: 0;
}

.np-page-heading {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.np-page-header__actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-2);
  margin-left: auto;
  min-width: 0;
  flex-shrink: 0;
}

.np-page-header--compact .np-page-header__actions,
.projects-page .project-page-topbar-actions,
.overview-page .overview-topbar-actions {
  gap: var(--space-3);
}

.np-page-breadcrumb,
.projects-page .project-breadcrumb,
.overview-page .overview-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  min-width: 0;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 600;
}

.np-page-breadcrumb-item,
.projects-page .project-breadcrumb-item,
.overview-page .overview-breadcrumb-item {
  color: inherit;
  text-decoration: none;
  white-space: nowrap;
}

.np-project-breadcrumb-switcher {
  display: inline-flex;
  min-width: 0;
}

.np-project-breadcrumb-toggle {
  display: inline-flex;
  align-items: center;
  max-width: min(34vw, 360px);
  padding: 0;
  border: 0;
  background: transparent;
  font: inherit;
  font-weight: 700;
  line-height: inherit;
  text-align: left;
  overflow: hidden;
  text-overflow: ellipsis;
  vertical-align: baseline;
  cursor: pointer;
}

.np-project-breadcrumb-toggle.dropdown-toggle::after {
  flex: 0 0 auto;
  margin-left: 0.35rem;
}

.np-project-breadcrumb-toggle:hover,
.np-project-breadcrumb-toggle:focus {
  color: var(--brand-primary-hover);
  text-decoration: underline;
}

.np-project-breadcrumb-toggle:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--brand-primary) 35%, transparent);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

.np-project-breadcrumb-menu {
  width: min(360px, calc(100vw - 32px));
  max-height: min(420px, calc(100vh - 140px));
  overflow-y: auto;
  overflow-x: hidden;
}

.np-project-breadcrumb-menu .np-dropdown-group-header {
  letter-spacing: 0;
  text-transform: capitalize;
}

.np-page-breadcrumb-item:hover,
.np-page-breadcrumb-item:focus,
.projects-page .project-breadcrumb-item:hover,
.projects-page .project-breadcrumb-item:focus,
.overview-page .overview-breadcrumb-item:hover,
.overview-page .overview-breadcrumb-item:focus {
  color: var(--brand-primary-hover);
  text-decoration: underline;
}

.np-page-breadcrumb-current,
.projects-page .project-breadcrumb-current,
.overview-page .overview-breadcrumb-current {
  color: var(--text-main);
  font-weight: 700;
  white-space: nowrap;
}

.np-page-breadcrumb-separator,
.projects-page .project-breadcrumb-separator,
.overview-page .overview-breadcrumb-separator {
  color: var(--text-muted);
}

.np-page-title {
  margin: 0;
  color: var(--text-main);
  font-size: 32px;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.025em;
}

.np-page-subtitle {
  margin: var(--space-2) 0 0;
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.45;
}

.np-page-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: var(--space-2);
}

.np-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  width: 100%;
  min-width: 0;
}

.np-toolbar__group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  min-width: 0;
}

.np-toolbar__group--end {
  justify-content: flex-end;
  margin-left: auto;
}

.np-toolbar__spacer {
  flex: 1 1 auto;
  min-width: 0;
}

.np-page-shell {
  box-sizing: border-box;
  display: flex;
  align-items: stretch;
  justify-content: stretch;
  width: 100%;
  min-width: 0;
  padding: var(--space-4);
  background: var(--page-bg);
  overflow: hidden;
}

.np-page-stack {
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  gap: var(--space-4);
  width: 100%;
  max-width: none;
  min-width: 0;
  min-height: 0;
  margin: 0;
  padding: 0;
}

.np-page-surface {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--card-bg);
  box-shadow: none;
}

.np-page-surface-pad {
  padding: var(--space-4);
}

.np-section-kicker {
  margin: 0;
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1.2;
  text-transform: uppercase;
}

.np-split-dropdown__label {
  min-width: 120px;
  justify-content: flex-start;
}

.np-dropdown-search {
  width: 100%;
  margin-bottom: var(--space-2);
}

.np-dropdown-search .np-search-input,
.np-search-input.np-dropdown-search {
  min-height: 36px;
}

.np-dropdown-group + .np-dropdown-group {
  margin-top: var(--space-1);
  padding-top: var(--space-1);
  border-top: 1px solid var(--border-soft);
}

.np-dropdown-group-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 0.5rem 0.75rem;
  border: 0;
  border-radius: var(--radius-md);
  background: transparent;
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 1.2;
  text-align: left;
  text-transform: uppercase;
}

.np-dropdown-group-header:hover,
.np-dropdown-group-header:focus {
  background: var(--brand-soft);
  color: #206E6C;
}

.np-dropdown-group-header .bi {
  transition: transform 0.16s ease;
}

.np-dropdown-group.is-collapsed .np-dropdown-group-header .bi {
  transform: rotate(-90deg);
}

.np-dropdown-group-list {
  padding-left: var(--space-2);
}

.np-dropdown-group-item {
  display: flex;
  align-items: center;
  width: 100%;
  padding: 0.5rem 0.75rem;
  border: 0;
  border-radius: var(--radius-md);
  background: transparent;
  color: var(--text-main);
  font-size: 14px;
  line-height: 1.2;
  text-align: left;
  transition: background-color 0.16s ease, color 0.16s ease;
}

.np-dropdown-group-item:hover,
.np-dropdown-group-item:focus {
  background: var(--brand-soft);
  color: #206E6C;
}

.np-dropdown-group-item[hidden],
.np-dropdown-group[hidden] {
  display: none !important;
}

.np-pagination-pills {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin: 0;
  padding: 0;
  list-style: none;
}

.np-pagination-pills .page-item {
  margin: 0;
}

.np-pagination-pills .page-link {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--card-bg);
  color: var(--text-main);
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
}

.np-pagination-pills .page-link:hover,
.np-pagination-pills .page-link:focus {
  background: var(--brand-soft);
  border-color: var(--brand-muted);
  color: #206E6C;
}

.np-pagination-pills .page-item.active .page-link {
  background: var(--brand-primary);
  border-color: var(--brand-primary);
  color: #0B2425;
}

.np-classification-shell {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  min-height: 0;
}

.np-classification-results {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  min-height: 0;
}

.np-classification-summary {
  align-items: center;
  justify-content: space-between;
}

.np-classification-summary .np-alert__body {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
}

.np-classification-summary .np-alert__title,
.np-classification-summary .np-alert__text {
  margin: 0;
}

.np-classification-summary__badge {
  flex: 0 0 auto;
}

.np-classification-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(320px, 0.75fr);
  gap: var(--space-4);
  align-items: stretch;
  min-height: 0;
}

.np-classification-chart-shell {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  min-height: 0;
  padding: var(--space-2) 0;
}

.np-classification-panel {
  display: flex;
  flex-direction: column;
  min-width: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--card-bg);
  overflow: hidden;
  box-shadow: var(--shadow-card);
}

.np-classification-panel__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--border-soft);
  background: var(--surface-subtle);
}

.np-classification-panel__title {
  margin: 0;
  color: var(--text-main);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.3;
}

.np-classification-panel__body {
  display: flex;
  flex: 1 1 auto;
  min-height: 0;
  padding: var(--space-4);
}

.np-classification-panel--chart .np-classification-panel__body {
  align-items: center;
  justify-content: center;
}

.np-classification-panel--table .np-classification-panel__body {
  overflow: auto;
}

.np-classification-chart {
  width: min(100%, 560px);
  height: auto;
  margin: 0 auto;
  font: 12px "IBM Plex Sans", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.np-classification-chart .center-label-line1 {
  font-size: 44px;
  font-weight: 700;
  fill: var(--text-secondary);
  text-anchor: middle;
  pointer-events: none;
}

.np-classification-chart .center-label-line2 {
  font-size: 36px;
  fill: var(--text-main);
  text-anchor: middle;
  pointer-events: none;
}

.np-classification-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}

.np-classification-table thead th {
  position: sticky;
  top: 0;
  padding: 0 12px 10px;
  border-bottom: 1px solid var(--border-soft);
  background: var(--card-bg);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.05em;
  line-height: 1.2;
  text-transform: uppercase;
}

.np-classification-table tbody td {
  padding: 12px;
  border-bottom: 1px solid var(--border-soft);
  color: var(--text-main);
  font-size: 14px;
  line-height: 1.35;
}

.np-classification-table tbody tr {
  transition: background-color 0.16s ease;
}

.np-classification-table tbody tr:hover {
  background: var(--brand-soft);
}

.np-classification-table tbody td:last-child {
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
}

.np-classification-swatch {
  display: inline-block;
  width: 12px;
  height: 12px;
  margin-right: 8px;
  border-radius: 999px;
  vertical-align: middle;
}

.np-classification-disclaimer {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  color: var(--text-secondary);
  font-size: 13px;
  line-height: 1.5;
  text-align: center;
}

.np-classification-toggle-group {
  flex-wrap: wrap;
  gap: 0;
}

.np-classification-toggle-group .np-btn-radio {
  margin-left: -1px;
}

.np-classification-toggle-group .np-btn-radio:first-of-type {
  margin-left: 0;
}

@media (max-width: 720px) {
  .np-page-shell {
    padding: var(--space-3);
  }

  .np-page-stack {
    gap: var(--space-3);
  }

  .np-page-surface-pad {
    padding: var(--space-3);
  }

  .np-toolbar {
    align-items: stretch;
  }

  .np-toolbar__group,
  .np-toolbar__group--end {
    width: 100%;
    margin-left: 0;
    justify-content: stretch;
  }

  .np-toolbar .np-btn,
  .np-toolbar .np-select,
  .np-toolbar .np-search {
    width: 100%;
  }
}

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

  .np-classification-panel__body {
    padding: var(--space-3);
  }
}

.np-section,
.np-card {
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-lg);
  background: var(--card-bg);
  box-shadow: var(--shadow-card);
}

.np-section {
  padding: var(--space-6);
}

.np-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.np-card--compact .np-card-header,
.np-card--compact .np-card-body,
.np-card--compact .np-card-footer {
  padding-left: var(--space-4);
  padding-right: var(--space-4);
}

.np-card--compact .np-card-header {
  padding-top: var(--space-3);
  padding-bottom: var(--space-2);
}

.np-card--compact .np-card-body {
  padding-top: 0;
  padding-bottom: var(--space-3);
}

.np-card--compact .np-card-footer {
  padding-top: 0;
  padding-bottom: var(--space-3);
}

.np-card--stat {
  min-width: 0;
}

.np-card--stat .np-card-body {
  gap: var(--space-2);
}

.np-card--stat .np-card-title {
  font-size: 14px;
  line-height: 1.2;
}

.np-card--stat .np-card-meta {
  font-size: 12px;
}

.np-card--interactive {
  appearance: none;
  background: var(--card-bg);
  border: 1px solid var(--border-soft);
  padding: 0;
  text-align: left;
  transition: box-shadow 0.18s ease, transform 0.18s ease;
}

.np-card--interactive:hover,
.np-card--interactive:focus-visible {
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.12);
  transform: translateY(-1px);
}

.np-card--interactive:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

.np-card--metric {
  background: #212529;
  border-color: rgba(255, 255, 255, 0.18);
  color: #fff;
}

.np-card--metric .np-card-header,
.np-card--metric .np-card-body,
.np-card--metric .np-card-footer,
.np-card--metric .np-card-title,
.np-card--metric .np-card-meta {
  color: #fff;
}

.np-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-3);
}

.np-card-body {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  gap: var(--space-3);
}

.np-card-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-2);
}

.np-card-title {
  margin: 0;
  color: var(--text-main);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
}

.np-card-meta {
  margin: 0;
  color: var(--text-secondary);
  font-size: 13px;
  line-height: 1.4;
}

.np-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
}

.np-badge-success { background: var(--success-bg); color: var(--success-text); }
.np-badge-warning { background: var(--warning-bg); color: var(--warning-text); }
.np-badge-danger { background: var(--danger-bg); color: var(--danger-text); }
.np-badge-info { background: var(--info-bg); color: var(--info-text); }
.np-badge-neutral { background: var(--neutral-bg); color: var(--neutral-text); }
.np-badge-running { background: var(--brand-soft); color: #206E6C; }

.np-token {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 24px;
  padding: 2px 8px;
  border: 1px solid var(--border-soft);
  border-radius: 999px;
  background: var(--surface-subtle);
  color: var(--text-main);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.3;
  white-space: nowrap;
}

.np-token--mono {
  font-family: var(--font-mono);
  letter-spacing: 0;
  text-transform: none;
}

.np-token--wrap {
  align-items: flex-start;
  white-space: normal;
  word-break: break-word;
}

.np-token--success { background: var(--success-bg); border-color: rgba(31, 122, 58, 0.16); color: var(--success-text); }
.np-token--warning { background: var(--warning-bg); border-color: rgba(161, 92, 0, 0.16); color: var(--warning-text); }
.np-token--danger { background: var(--danger-bg); border-color: rgba(180, 35, 24, 0.16); color: var(--danger-text); }
.np-token--info { background: var(--info-bg); border-color: rgba(34, 94, 168, 0.16); color: var(--info-text); }
.np-token--neutral { background: var(--neutral-bg); border-color: rgba(75, 85, 99, 0.12); color: var(--neutral-text); }

.np-alert {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  border: 1px solid transparent;
  border-radius: var(--radius-lg);
  font-size: 14px;
  line-height: 1.45;
}

.np-alert__icon {
  flex: 0 0 auto;
  margin-top: 2px;
  font-size: 18px;
  line-height: 1;
}

.np-alert__body {
  flex: 1 1 auto;
  min-width: 0;
}

.np-alert__title {
  margin: 0 0 2px;
  font-size: 14px;
  font-weight: 700;
}

.np-alert__text {
  margin: 0;
}

.np-alert-success {
  background: var(--success-bg);
  border-color: rgba(31, 122, 58, 0.16);
  color: var(--success-text);
}

.np-alert-warning {
  background: var(--warning-bg);
  border-color: rgba(161, 92, 0, 0.16);
  color: var(--warning-text);
}

.np-alert-danger {
  background: var(--danger-bg);
  border-color: rgba(180, 35, 24, 0.16);
  color: var(--danger-text);
}

.np-alert-info {
  background: var(--info-bg);
  border-color: rgba(34, 94, 168, 0.16);
  color: var(--info-text);
}

.np-alert-neutral {
  background: var(--neutral-bg);
  border-color: rgba(75, 85, 99, 0.12);
  color: var(--neutral-text);
}

.np-empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  padding: var(--space-8);
  border: 1px dashed var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface-subtle);
  color: var(--text-secondary);
  text-align: center;
}

.np-empty-state__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: #206E6C;
  font-size: 24px;
}

.np-empty-state__title {
  margin: 0;
  color: var(--text-main);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
}

.np-empty-state__text {
  margin: 0;
  max-width: 52ch;
  font-size: 14px;
  line-height: 1.5;
}

.np-empty-state__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-2);
}

.np-table-panel {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
}

.np-table-panel__toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3) var(--space-4);
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--border-soft);
}

.np-table-panel__search {
  flex: 1 1 320px;
  min-width: 280px;
}

.np-table-panel__search .dataTables_filter {
  width: min(380px, 100%);
  margin: 0;
  padding: 0;
}

.np-table-panel__search .dataTables_filter label {
  display: block;
  width: 100%;
  margin: 0;
}

.np-table-panel__search .dataTables_filter input[type="search"] {
  width: 100%;
  margin-left: 0;
}

.np-table-panel__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-2);
  margin-left: auto;
}

.np-table-panel__body {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
}

.np-table-panel__body > .np-data-table-shell {
  flex: 1 1 auto;
  min-height: 0;
}

.np-table-panel--loading .np-data-table-shell {
  visibility: hidden;
  opacity: 0;
}

.np-table-panel--ready .np-data-table-shell {
  visibility: visible;
  opacity: 1;
  transition: opacity 0.16s ease;
}

.np-data-table-shell {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  min-height: 0;
  overflow-x: auto;
  overflow-y: auto;
  border: 1px solid var(--border-soft);
  border-radius: 0;
  background: var(--card-bg);
  scrollbar-gutter: stable;
  overscroll-behavior: contain;
}

table.np-data-table {
  width: 100%;
  table-layout: auto;
  margin-bottom: 0;
  border-collapse: separate;
  border-spacing: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  color: var(--text-main);
  font-size: 14px;
}

table.np-data-table--fixed {
  table-layout: fixed;
}

table.np-data-table.dataTable,
table.np-data-table.dataTable.no-footer {
  border-bottom: 0 !important;
  box-shadow: none !important;
}

table.np-data-table--sticky thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  padding: 10px 10px;
  border-bottom: 1px solid var(--border-soft) !important;
  background: linear-gradient(180deg, #F7F9FB 0%, #EEF2F6 100%);
  background-color: #EEF2F6;
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}

table.np-data-table tbody th,
table.np-data-table tbody td {
  height: 28px;
  padding: 4px 10px;
  border-bottom: 1px solid var(--border-soft);
  background: #FFFFFF;
  background-clip: padding-box;
  line-height: 1.1;
  vertical-align: middle;
}

table.np-data-table tbody tr:hover > * {
  background: var(--brand-soft);
}

table.np-data-table tbody tr:last-child > * {
  border-bottom: 0;
}

table.np-data-table tbody tr.np-row--selected > * {
  background: rgba(98, 193, 191, 0.18) !important;
}

.np-data-table-shell .dataTables_info,
.np-data-table-shell ~ .dataTables_info,
.np-table-panel .dataTables_info {
  display: block;
  flex: 0 0 auto;
  float: none;
  clear: none;
  margin: 0;
  padding: var(--space-2) var(--space-4) var(--space-3);
  border-top: 1px solid var(--border-soft);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 600;
}

table.np-data-table.dataTable thead > tr > th.sorting,
table.np-data-table.dataTable thead > tr > th.sorting_asc,
table.np-data-table.dataTable thead > tr > th.sorting_desc,
table.np-data-table.dataTable thead > tr > th.sorting_disabled,
table.np-data-table.dataTable thead > tr > th.sorting_asc_disabled,
table.np-data-table.dataTable thead > tr > th.sorting_desc_disabled {
  background-image: none !important;
  padding-right: 12px !important;
}

table.np-data-table.dataTable thead > tr > th.sorting::before,
table.np-data-table.dataTable thead > tr > th.sorting::after,
table.np-data-table.dataTable thead > tr > th.sorting_asc::before,
table.np-data-table.dataTable thead > tr > th.sorting_asc::after,
table.np-data-table.dataTable thead > tr > th.sorting_desc::before,
table.np-data-table.dataTable thead > tr > th.sorting_desc::after,
table.np-data-table.dataTable thead > tr > th.sorting_asc_disabled::before,
table.np-data-table.dataTable thead > tr > th.sorting_asc_disabled::after,
table.np-data-table.dataTable thead > tr > th.sorting_desc_disabled::before,
table.np-data-table.dataTable thead > tr > th.sorting_desc_disabled::after {
  content: none !important;
  display: none !important;
  opacity: 0 !important;
}

.np-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  overflow: hidden;
  border: 2px solid var(--card-bg);
  border-radius: 999px;
  background: var(--neutral-bg);
  color: var(--neutral-text);
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  text-transform: uppercase;
}

.np-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.np-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.np-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  min-height: 32px;
  padding: 0 10px;
  border-radius: 999px;
  background: var(--chip-bg, var(--neutral-bg));
  color: var(--chip-fg, var(--neutral-text));
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  text-transform: uppercase;
}

.np-sidebar-shell {
  flex: 0 0 var(--np-sidebar-width);
}

.np-sidebar {
  width: var(--np-sidebar-width);
  height: 100vh;
  display: flex;
  flex-direction: column;
  padding: var(--space-4);
  background: var(--sidebar-light);
  color: var(--text-main);
  border-right: 1px solid var(--sidebar-light-border);
  font-family: "IBM Plex Sans", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  overflow-y: auto;
  overflow-x: hidden;
}

.np-sidebar-brand {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  min-height: 44px;
  margin-bottom: 0;
  color: var(--text-main);
  font-size: 20px;
  font-weight: 700;
  text-decoration: none;
}

.np-sidebar-brand:hover,
.np-sidebar-brand:focus {
  color: var(--text-main);
}

.np-sidebar-brand svg {
  width: 36px;
  height: 36px;
  flex: 0 0 auto;
}

.np-brand-divider {
  height: 1px;
  margin: 0 0 var(--space-3);
  background: var(--sidebar-light-border);
}

.np-sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1 1 auto;
  margin: 0;
  padding: 0;
  list-style: none;
}

.np-sidebar .np-nav-section-title {
  display: block;
  margin: 22px 0 8px;
  padding: 0 var(--space-2);
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1.2;
  text-transform: uppercase;
}

.np-sidebar .np-nav-item {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  min-height: 34px;
  margin-bottom: 0;
  padding: 0 12px;
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.25;
  text-decoration: none;
}

.np-sidebar .np-nav-item svg {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  color: var(--text-muted);
}

.np-sidebar .np-nav-item:hover,
.np-sidebar .np-nav-item:focus {
  background: rgba(255, 255, 255, 0.72);
  color: var(--text-main);
}

.np-sidebar .np-nav-item.active {
  background: rgba(98, 193, 191, 0.16) !important;
  border-color: transparent;
  color: #276B6A !important;
  font-weight: 700;
}

.np-sidebar .np-nav-item.active svg {
  color: #276B6A;
}

.np-sidebar .np-sidebar-report-link {
  display: none;
}

.np-sidebar .np-project-switcher {
  width: 100%;
  min-height: 24px;
  margin-bottom: var(--space-1);
  padding: 0 var(--space-2);
  border: 0;
  background: transparent;
  color: #206E6C;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.25;
}

.np-sidebar #sidebar-project-name {
  cursor: pointer;
}

.np-sidebar #sidebar-project-name::after {
  border-top-color: var(--brand-primary);
}

.np-sidebar #projectMenuCollapse.collapse:not(.show) {
  display: none !important;
}

.np-sidebar hr,
.np-sidebar-divider {
  width: 100%;
  margin: var(--space-4) 0;
  border: 0;
  border-top: 1px solid var(--sidebar-light-border);
  opacity: 1;
}

.np-sidebar-system {
  margin-top: 22px;
}

.np-system-label {
  display: block;
  margin: 0 0 var(--space-2);
  padding: 0 var(--space-2);
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1.2;
  text-transform: uppercase;
}

.np-compute-meter {
  padding: 0 var(--space-2);
}

.np-compute-meter__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  color: var(--text-secondary);
  font-size: 13px;
  line-height: 1.3;
}

.np-compute-meter__row strong {
  color: var(--text-main);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.np-compute-meter__bar {
  height: 4px;
  margin-top: var(--space-2);
  overflow: hidden;
  border-radius: 999px;
  background: var(--border-soft);
}

.np-compute-meter__fill {
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: var(--brand-primary);
  transition: width 0.2s ease, background-color 0.2s ease;
}

.np-compute-meter[data-status="warning"] .np-compute-meter__fill {
  background: var(--warning-text);
}

.np-compute-meter[data-status="danger"] .np-compute-meter__fill {
  background: var(--danger-text);
}

.np-compute-meter[data-status="unavailable"] .np-compute-meter__fill {
  background: var(--text-muted);
}

.np-sidebar-user {
  margin-top: 22px;
}

.np-sidebar-user-toggle {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  min-height: 40px;
  padding: var(--space-2) 0;
  border: 0;
  background: transparent;
  color: var(--text-main);
  text-decoration: none;
}

.np-sidebar-user-toggle:hover,
.np-sidebar-user-toggle:focus {
  color: var(--text-main);
  background: transparent;
}

.np-sidebar-user-toggle strong {
  overflow: hidden;
  color: var(--text-main);
  font-size: 13px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.np-sidebar-avatar {
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  border-radius: 50%;
}

.np-sidebar .dropdown-menu {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-panel);
}

.np-sidebar .dropdown-item {
  color: var(--text-main);
  font-size: 14px;
}

.np-sidebar .dropdown-item:hover,
.np-sidebar .dropdown-item:focus {
  background: var(--brand-soft);
  color: #206E6C;
}

.np-sidebar .avatar-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--brand-soft);
  color: #206E6C;
  font-size: 12px;
  font-weight: 700;
}
