.nsd-dashboard {
  --nsd-navy: #06265d;
  --nsd-navy-deep: #031f4f;
  --nsd-teal: #08a6a6;
  --nsd-teal-dark: #077b7b;
  --nsd-ink: #0b2354;
  --nsd-muted: #62718f;
  --nsd-line: #dbe5ef;
  --nsd-line-soft: #e9eff5;
  --nsd-surface: #ffffff;
  --nsd-canvas: #f5f8fc;

  /* Traffic-light readiness palette. */
  --nsd-strong: #16803c;
  --nsd-strong-bg: #dcfce7;
  --nsd-strong-text: #14532d;
  --nsd-strong-border: #86efac;

  --nsd-track: #a67700;
  --nsd-track-bg: #fff7cc;
  --nsd-track-text: #624900;
  --nsd-track-border: #f2cf52;

  --nsd-review: #dc2626;
  --nsd-review-bg: #fee2e2;
  --nsd-review-text: #991b1b;
  --nsd-review-border: #fca5a5;

  --nsd-neutral: #8a96aa;
  --nsd-neutral-bg: #eef2f6;
  --nsd-neutral-text: #4b5563;
  --nsd-neutral-border: #cbd5e1;

  color: var(--nsd-ink);
  font-family: inherit;
  font-size: 15px;
  line-height: 1.45;
  width: 100%;
  container-type: inline-size;
}

.nsd-dashboard,
.nsd-dashboard *,
.nsd-dashboard *::before,
.nsd-dashboard *::after {
  box-sizing: border-box;
}

.nsd-dashboard--standalone {
  background: var(--nsd-canvas);
  border-radius: 18px;
  padding: clamp(16px, 2.4vw, 34px);
}

.nsd-dashboard--fox {
  padding: 0;
}

.nsd-dashboard h1,
.nsd-dashboard h2,
.nsd-dashboard h3,
.nsd-dashboard p {
  color: inherit;
  font-family: inherit;
  letter-spacing: normal;
  text-transform: none;
}

.nsd-dashboard h1,
.nsd-dashboard h2,
.nsd-dashboard h3 {
  font-weight: 700;
}

.nsd-dashboard h1 {
  font-size: clamp(21px, 2vw, 27px);
  line-height: 1.2;
  margin: 0 0 4px !important;
}

.nsd-dashboard h2 {
  font-size: 18px;
  line-height: 1.3;
  margin: 0 0 14px !important;
}

.nsd-dashboard h3 {
  font-size: 15px;
  line-height: 1.3;
  margin: 0 !important;
}

.nsd-dashboard a {
  text-decoration: none;
}

.nsd-dashboard a:focus-visible,
.nsd-dashboard button:focus-visible {
  border-radius: 6px;
  outline: 3px solid #067676;
  outline-offset: 3px;
}

.nsd-dashboard .nsd-card,
.nsd-dashboard .nsd-welcome,
.nsd-dashboard .nsd-scores {
  background: var(--nsd-surface);
  border: 1px solid var(--nsd-line);
  border-radius: 14px;
  box-shadow: 0 8px 26px rgba(5, 38, 93, 0.045);
}

.nsd-welcome {
  margin-bottom: 16px;
  padding: 22px 26px;
}

.nsd-welcome p {
  color: var(--nsd-muted);
  margin: 0 !important;
}

.nsd-preview-notice {
  align-items: center;
  background: #eef9fb;
  border: 1px solid #a8e0e5;
  border-radius: 10px;
  color: #075f67;
  display: flex;
  font-size: 13px;
  font-weight: 650;
  gap: 9px;
  margin: 0 0 14px;
  padding: 9px 12px;
}

.nsd-preview-notice svg {
  fill: none;
  height: 18px;
  min-width: 18px;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
  width: 18px;
}

.nsd-scores {
  padding: 16px;
}

.nsd-scores > h2 {
  margin-left: 2px;
}

.nsd-score-grid,
.nsd-summary {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
}

.nsd-score-card {
  align-items: flex-start;
  box-shadow: none;
  display: flex;
  gap: 15px;
  min-height: 132px;
  padding: 16px;
}

.nsd-icon {
  align-items: center;
  background: linear-gradient(145deg, #10b7b2, #079795);
  border-radius: 999px;
  color: #ffffff;
  display: inline-flex;
  flex: 0 0 48px;
  height: 48px;
  justify-content: center;
  width: 48px;
}

.nsd-icon--small {
  flex-basis: 42px;
  height: 42px;
  width: 42px;
}

.nsd-icon--large {
  flex-basis: 54px;
  height: 54px;
  width: 54px;
}

.nsd-icon svg {
  fill: none;
  height: 25px;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
  width: 25px;
}

.nsd-score-card__body {
  flex: 1 1 auto;
  min-width: 0;
}

.nsd-score-card__body h3 {
  color: var(--nsd-ink);
  margin-bottom: 8px !important;
}

.nsd-score-values {
  align-items: end;
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(2, minmax(70px, 1fr));
}

.nsd-score-value {
  display: flex;
  flex-direction: column;
}

.nsd-score-label {
  color: var(--nsd-muted);
  font-size: 12px;
  font-weight: 550;
  margin-bottom: 1px;
}

.nsd-score-value strong {
  color: var(--nsd-navy);
  font-size: 26px;
  font-variant-numeric: tabular-nums;
  line-height: 1.05;
}

.nsd-score-value--latest strong {
  font-size: 38px;
}

.nsd-score-value--average strong {
  color: #7c89a4;
}

.nsd-session-count {
  color: var(--nsd-ink);
  font-size: 12px;
  font-weight: 650;
  margin: 4px 0 0 !important;
}

.nsd-summary {
  margin: 14px 0;
}

.nsd-summary-card {
  align-items: center;
  box-shadow: none;
  display: flex;
  gap: 14px;
  min-height: 72px;
  padding: 12px 16px;
}

.nsd-summary-card > div:last-child {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.nsd-summary-card span {
  color: var(--nsd-ink);
  font-size: 12px;
  font-weight: 650;
}

.nsd-summary-card strong {
  color: var(--nsd-navy);
  font-size: 24px;
  font-variant-numeric: tabular-nums;
  line-height: 1.15;
}

.nsd-summary-card small {
  color: var(--nsd-muted);
  font-size: 11px;
  font-weight: 600;
  line-height: 1.25;
  margin-top: 1px;
}

.nsd-domain-panel,
.nsd-recent {
  padding: 16px 18px;
}

.nsd-domain-panel {
  margin-bottom: 14px;
}

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

.nsd-domain-column {
  min-width: 0;
}

.nsd-domain-row {
  align-items: center;
  border-bottom: 1px solid var(--nsd-line-soft);
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(150px, 1.35fr) minmax(100px, 1fr) 52px;
  min-width: 0;
  padding: 9px 0 10px;
}

.nsd-domain-name {
  color: var(--nsd-ink);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.25;
  min-width: 0;
  overflow-wrap: anywhere;
}

.nsd-domain-percent {
  color: var(--nsd-neutral-text);
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.nsd-domain-percent {
  font-weight: 700;
  text-align: right;
}

.nsd-progress {
  background: #e5eaf0;
  border-radius: 999px;
  height: 7px;
  margin: 0;
  min-width: 68px;
  overflow: hidden;
  width: 100%;
}

.nsd-progress__fill {
  background: var(--nsd-neutral);
  border-radius: inherit;
  display: block;
  height: 100%;
}

.nsd-status--strong .nsd-progress__fill {
  background: var(--nsd-strong);
}

.nsd-status--strong .nsd-domain-percent {
  color: var(--nsd-strong);
}

.nsd-status--on-track .nsd-progress__fill {
  background: var(--nsd-track);
}

.nsd-status--on-track .nsd-domain-percent {
  color: var(--nsd-track);
}

.nsd-status--needs-review .nsd-progress__fill {
  background: var(--nsd-review);
}

.nsd-status--needs-review .nsd-domain-percent {
  color: var(--nsd-review);
}

.nsd-button-row {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: auto;
}

.nsd-dashboard .nsd-button {
  align-items: center;
  border: 2px solid transparent;
  border-radius: 8px;
  box-shadow: none;
  display: inline-flex;
  font-size: 13px;
  font-weight: 750;
  justify-content: center;
  line-height: 1.2;
  min-height: 42px;
  padding: 9px 15px;
  text-align: center;
  text-decoration: none;
  transition: background-color 140ms ease, border-color 140ms ease, color 140ms ease;
}

.nsd-dashboard .nsd-button--primary {
  background: var(--nsd-navy);
  border-color: var(--nsd-navy);
  color: #ffffff;
}

.nsd-dashboard .nsd-button--primary:hover {
  background: var(--nsd-navy-deep);
  border-color: var(--nsd-navy-deep);
  color: #ffffff;
}

.nsd-dashboard .nsd-button--secondary {
  background: #ffffff;
  border-color: var(--nsd-teal);
  color: var(--nsd-teal-dark);
}

.nsd-dashboard .nsd-button--secondary:hover {
  background: #ecfbfb;
  color: #056f70;
}

.foxlms-wrapper .nsd-dashboard a.nsd-button--primary:focus-visible {
  background: var(--nsd-navy);
  border-color: var(--nsd-navy);
  color: #ffffff;
}

.foxlms-wrapper .nsd-dashboard a.nsd-button--secondary:focus-visible {
  background: #ffffff;
  border-color: var(--nsd-teal);
  color: var(--nsd-teal-dark);
}

.nsd-empty-state {
  color: var(--nsd-muted);
  margin: auto 0;
  text-align: center;
}

.nsd-empty-state p {
  color: inherit;
  margin: 8px 0 18px !important;
}

.nsd-empty-state--table {
  padding: 18px;
}

.nsd-empty-state--table p {
  margin: 0 !important;
}

.nsd-recent h2 {
  margin-bottom: 8px !important;
}

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

.nsd-table-wrap:focus-visible {
  outline: 3px solid #067676;
  outline-offset: 3px;
}

.nsd-dashboard .nsd-table {
  border: 0;
  border-collapse: collapse;
  color: var(--nsd-ink);
  font-family: inherit;
  font-size: 12px;
  margin: 0;
  min-width: 760px;
  width: 100%;
}

.nsd-dashboard .nsd-table th,
.nsd-dashboard .nsd-table td {
  background: #ffffff;
  border: 0;
  border-bottom: 1px solid var(--nsd-line-soft);
  color: inherit;
  font-family: inherit;
  font-size: inherit;
  padding: 10px 12px;
  text-align: left;
  vertical-align: middle;
}

.nsd-dashboard .nsd-table thead th {
  color: var(--nsd-ink);
  font-weight: 750;
}

.nsd-dashboard .nsd-table tbody th {
  font-weight: 600;
}

.nsd-dashboard .nsd-table tbody tr:last-child th,
.nsd-dashboard .nsd-table tbody tr:last-child td {
  border-bottom: 0;
}

.nsd-dashboard .nsd-table th:first-child {
  min-width: 320px;
  width: 52%;
}

.nsd-dashboard .nsd-table td:nth-child(3),
.nsd-dashboard .nsd-table td:nth-child(4) {
  font-variant-numeric: tabular-nums;
}

.nsd-dashboard .nsd-review-link {
  color: var(--nsd-teal-dark);
  font-weight: 750;
}

.nsd-dashboard .nsd-review-link:hover {
  color: #056566;
  text-decoration: underline;
}

.foxlms-wrapper .nsd-dashboard a.nsd-review-link:focus-visible {
  color: var(--nsd-teal-dark);
  text-decoration: underline;
}

.nsd-completed-label {
  color: #64748b;
  font-weight: 650;
}

.nsd-no-score {
  color: var(--nsd-muted);
}

.nsd-login-card {
  background: #ffffff;
  border: 1px solid var(--nsd-line);
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(5, 38, 93, 0.06);
  margin: 36px auto;
  max-width: 520px;
  padding: 38px;
  text-align: center;
}

.nsd-login-card .nsd-icon {
  margin-bottom: 18px;
}

.nsd-login-card h2 {
  font-size: 24px;
}

.nsd-login-card p {
  color: var(--nsd-muted);
  margin: 0 0 22px !important;
}

.nsd-login-card .nsd-button {
  min-width: 150px;
}

.nsd-dashboard .screen-reader-text {
  border: 0;
  clip: rect(1px, 1px, 1px, 1px);
  clip-path: inset(50%);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute !important;
  width: 1px;
  word-wrap: normal !important;
}

/* Welcome copy added to the open left side of Fox LMS's account header. */
.foxlms-dashboard__content-header {
  position: relative;
}

.foxlms-dashboard__content-header .foxlms-page__header-search {
  display: none;
}

.foxlms-dashboard__content-header .nsd-fox-welcome {
  color: #06265d;
  display: flex;
  flex-direction: column;
  left: 40px;
  line-height: 1.35;
  max-width: min(48%, 560px);
  pointer-events: none;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
}

.foxlms-dashboard__content-header .nsd-fox-welcome strong {
  font-size: 20px;
  font-weight: 750;
}

.foxlms-dashboard__content-header .nsd-fox-welcome span {
  color: #62718f;
  font-size: 14px;
}

@container (max-width: 760px) {
  .nsd-domain-grid {
    grid-template-columns: 1fr;
  }
}

@container (max-width: 600px) {
  .nsd-welcome,
  .nsd-scores,
  .nsd-domain-panel,
  .nsd-recent {
    border-radius: 11px;
    padding: 14px;
  }

  .nsd-score-card {
    min-height: 0;
  }

  .nsd-score-value--latest strong {
    font-size: 34px;
  }

  .nsd-domain-row {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .nsd-domain-name {
	grid-column: 1 / -1;
	margin-bottom: 2px;
  }

  .nsd-progress {
	grid-column: 1;
	min-width: 120px;
  }

  .nsd-domain-percent {
	grid-column: 2;
  }

  .nsd-button-row {
    grid-template-columns: 1fr;
  }
}

/* Viewport fallbacks for browsers without container-query support. */
@supports not (container-type: inline-size) {
  @media (max-width: 820px) {
    .nsd-domain-grid {
      grid-template-columns: 1fr;
    }
  }
}

@media (max-width: 991.98px) {
  .foxlms-dashboard__content-header .nsd-fox-welcome {
    left: 90px;
    max-width: calc(100% - 420px);
  }

  .foxlms-dashboard__content-header .nsd-fox-welcome strong {
    font-size: 16px;
  }

  .foxlms-dashboard__content-header .nsd-fox-welcome span {
    display: none;
  }
}

@media (max-width: 575.98px) {
  .foxlms-dashboard__content-header .nsd-fox-welcome {
    max-width: calc(100% - 180px);
  }
}

@media (max-width: 640px) {
  .nsd-dashboard--standalone {
    border-radius: 0;
    padding: 12px;
  }
}

@media (max-width: 480px) {
  .foxlms-dashboard__content-header .nsd-fox-welcome {
    display: none;
  }
}

@media (forced-colors: active) {
  .nsd-progress__fill {
    border: 1px solid currentColor;
    forced-color-adjust: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  .nsd-dashboard .nsd-button {
    transition: none;
  }
}
