/* Workbench status strip and persistence checkpoint.
   This module owns the compact identity, demo mode, current-state controls,
   next action, and the exceptional storage-health warning. */

.reviewBanner {
  position: relative;
  z-index: 90;
  display: flex;
  justify-content: center;
  gap: 10px;
  padding: 9px 18px;
  border-bottom: 1px solid #d5bd78;
  background: #fff7dc;
  color: #493d1f;
  font-size: 13px;
  line-height: 1.35;
  text-align: center;
}

.reviewBanner[hidden] { display: none; }
.reviewBanner strong { white-space: nowrap; }

body[data-distribution-mode="review"] .demoSwitch {
  cursor: default;
}

@media (max-width: 680px) {
  .reviewBanner { flex-direction: column; gap: 2px; }
}

.nav {
  position: relative;
  top: auto;
  z-index: 50;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, .94);
  box-shadow: 0 8px 24px rgba(7, 24, 63, .08);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
}

.navIn {
  display: flex;
  max-width: 100%;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin: 0 auto;
  padding: 10px clamp(16px, 2.4vw, 32px);
}

.navBrand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--navy);
  font-weight: 700;
  letter-spacing: .02em;
  text-decoration: none;
  white-space: nowrap;
}

.navBrand:hover {
  color: var(--blue);
}

.navMark {
  width: 24px;
  height: 24px;
  flex: 0 0 auto;
  border: 1px solid #ccd3da;
  border-radius: 6px;
  background: #f1f3f5;
  color: var(--navy);
  box-shadow: none;
}

.cmapNavMark {
  display: inline-grid;
  place-items: center;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: -.02em;
}

.navStatus {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.navStatus > span,
.demoSwitch,
.nextActionBtn {
  border: 1px solid rgba(63, 83, 106, .14);
  border-radius: 999px;
  padding: 6px 10px;
  background: #fff;
  box-shadow: 0 6px 18px rgba(34, 42, 52, .035);
}

.navStatus b {
  color: var(--navy);
  font-size: 16px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.hiddenStatus {
  display: none !important;
}

.demoSwitch {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding-left: 7px;
  color: var(--ink);
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
}

.demoSwitch input {
  position: relative;
  width: 34px;
  height: 20px;
  margin: 0;
  appearance: none;
  border-radius: 999px;
  background: #dbe7f4;
  box-shadow: inset 0 0 0 1px rgba(111, 132, 166, .22);
}

.demoSwitch input::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 1px 4px rgba(0, 31, 84, .24);
  transition: transform .16s ease;
}

.demoSwitch b {
  color: currentColor;
  font-size: 12px;
}

.demoSwitch.active,
.demoSwitch.isActive {
  border-color: #d88418;
  background: #fff3d8;
  color: #5f3400;
  box-shadow: none;
}

.demoSwitch.active input,
.demoSwitch.isActive input {
  background: #e88919;
}

.demoSwitch.active input::after,
.demoSwitch.isActive input::after {
  transform: translateX(14px);
}

.nextActionBtn {
  border-color: #bfc7ce;
  border-radius: 6px;
  color: var(--navy);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  transition: background-color .16s ease, color .16s ease, border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}

.nextActionBtn b {
  margin-left: 3px;
}

.nextActionBtn:hover,
.nextActionBtn:focus-visible {
  border-color: var(--blue);
  background: #f2f5f8;
  color: var(--entry-ink);
  box-shadow: 0 10px 26px rgba(34, 42, 52, .08);
}

.storageHealthBanner[hidden] {
  display: none;
}

.storageHealthBanner {
  position: sticky;
  top: 0;
  z-index: 80;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  margin: 8px clamp(14px, 2.4vw, 28px) 0;
  border: 1px solid #e0b36d;
  border-left: 4px solid var(--attention);
  border-radius: 8px;
  padding: 10px 12px;
  background: rgba(255, 248, 233, .97);
  box-shadow: 0 8px 24px rgba(75, 54, 21, .15);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}

.storageHealthIcon {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 50%;
  background: var(--attention);
  color: var(--navy);
  font-size: 15px;
  font-weight: 900;
}

.storageHealthBanner > div {
  display: grid;
  gap: 2px;
}

.storageHealthBanner strong {
  color: #563b16;
  font-size: 12px;
}

.storageHealthBanner > div > span {
  color: #6b5737;
  font-size: 11px;
}

@media (max-width: 980px) {
  .navIn,
  .navStatus {
    flex-wrap: wrap;
  }

  .navBrand {
    width: 100%;
  }
}

@media (max-width: 940px) {
  .navIn {
    align-items: flex-start;
    flex-direction: column;
  }

  .navStatus {
    white-space: normal;
  }
}

@media (max-width: 620px) {
  .storageHealthBanner {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .storageHealthBanner .actionBtn {
    grid-column: 1 / -1;
    width: 100%;
  }
}

@media print {
  .nav,
  .storageHealthBanner {
    display: none;
  }
}
