:root {
  color-scheme: dark;
  --bg: #06101d;
  --panel: #0d1d2e;
  --panel-2: #122842;
  --line: #24405f;
  --text: #eef6ff;
  --muted: #9eb1c8;
  --blue: #2f82ff;
  --accent-soft: #9fc7ff;
  --green: #53d178;
  --amber: #f3bd2f;
  --purple: #8e76ff;
  --red: #ff7575;
  --panel-glow: 0 18px 44px rgba(0, 0, 0, 0.28);
  --soft-line: rgba(130, 181, 255, 0.22);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(120deg, rgba(83, 209, 120, 0.05), transparent 28%),
    linear-gradient(145deg, var(--bg), #020813 70%);
  color: var(--text);
  line-height: 1.45;
}

a {
  color: inherit;
}

.shell {
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  min-height: 100vh;
}

.side {
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 26px 18px;
  border-right: 1px solid rgba(130, 181, 255, 0.18);
  background: linear-gradient(180deg, rgba(4, 17, 30, 0.98), rgba(2, 9, 17, 0.98));
}

.side-header {
  display: block;
}

.side-drawer {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  gap: 24px;
  min-height: 0;
}

.mobile-nav-toggle {
  display: none;
}

.brand img {
  display: block;
  width: min(138px, 100%);
  height: auto;
  margin: 0 0 10px;
  object-fit: contain;
}

.brand strong,
.brand em {
  display: block;
}

.brand strong {
  font-size: 22px;
}

.brand em,
.user-box span,
.hero p,
.panel p,
.metric span {
  color: var(--muted);
  font-style: normal;
}

nav {
  display: grid;
  gap: 8px;
}

nav a {
  display: flex;
  min-height: 42px;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 8px;
  text-decoration: none;
  color: #d4e1f0;
}

nav a.active,
nav a:hover {
  background: rgba(47, 130, 255, 0.22);
  color: white;
}

.nav-sign,
.section-sign,
.hero-sign {
  flex: 0 0 auto;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.nav-sign {
  width: 20px;
  height: 20px;
  padding: 3px;
  border: 1px solid rgba(130, 181, 255, 0.16);
  border-radius: 7px;
  background: rgba(47, 130, 255, 0.08);
  color: #8fbfff;
}

nav a.active .nav-sign,
nav a:hover .nav-sign {
  border-color: rgba(130, 181, 255, 0.32);
  background: rgba(47, 130, 255, 0.2);
  color: #d7e9ff;
}

.nav-text,
.nav-label,
.nav-term {
  display: block;
}

.nav-text {
  min-width: 0;
}

.nav-label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  line-height: 1.1;
}

.nav-term {
  margin-top: 2px;
  color: #93a8bf;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

nav a.active .nav-term,
nav a:hover .nav-term {
  color: #bdd7f5;
}

.side-tools {
  display: grid;
  gap: 14px;
}

.side-tool-block {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(130, 181, 255, 0.2);
  border-radius: 8px;
  background: rgba(13, 29, 46, 0.72);
}

.side-tool-block h2,
.side-jump-form label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  color: #d4e1f0;
  font-size: 13px;
  font-weight: 800;
}

.tool-sign {
  width: 19px;
  height: 19px;
  padding: 3px;
  flex: 0 0 auto;
  border: 1px solid rgba(130, 181, 255, 0.18);
  border-radius: 7px;
  background: rgba(47, 130, 255, 0.08);
  color: #9fc7ff;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.9;
}

.quick-add-link,
.side-view-all,
.side-recent-list a,
.side-jump-form button {
  border: 1px solid rgba(130, 181, 255, 0.28);
  border-radius: 8px;
  color: #d4e1f0;
  font-weight: 800;
  text-decoration: none;
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease, color 160ms ease, transform 160ms ease;
}

.quick-add-link {
  display: grid;
  min-height: 42px;
  place-items: center;
  background: linear-gradient(180deg, #3f8cff, #2f82ff);
  color: white;
  box-shadow: 0 8px 18px rgba(47, 130, 255, 0.13);
}

.side-jump-form div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.side-jump-form input {
  min-width: 0;
  min-height: 38px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #081827;
  color: var(--text);
  font: inherit;
}

.side-jump-form button,
.side-view-all {
  display: inline-flex;
  min-height: 38px;
  align-items: center;
  justify-content: center;
  padding: 0 10px;
  background: rgba(18, 40, 66, 0.96);
  font: inherit;
  cursor: pointer;
}

.side-recent-list {
  display: grid;
  gap: 8px;
}

.side-recent-list a {
  display: grid;
  gap: 2px;
  padding: 9px 10px;
  background: rgba(18, 40, 66, 0.58);
}

.side-recent-list span,
.side-tool-empty {
  color: var(--muted);
  font-size: 12px;
}

.side-tool-empty {
  margin: 0;
}

.quick-add-link:hover,
.quick-add-link:focus-visible,
.side-view-all:hover,
.side-view-all:focus-visible,
.side-recent-list a:hover,
.side-recent-list a:focus-visible,
.side-jump-form button:hover,
.side-jump-form button:focus-visible {
  border-color: rgba(130, 181, 255, 0.72);
  background: rgba(27, 61, 98, 0.98);
  box-shadow: 0 0 0 3px rgba(47, 130, 255, 0.14), 0 12px 24px rgba(0, 0, 0, 0.18);
  color: white;
  outline: none;
  transform: translateY(-1px);
}

.quick-add-link:hover,
.quick-add-link:focus-visible {
  background: #3f8cff;
}

.user-box {
  margin-top: auto;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(13, 29, 46, 0.78);
}

.user-box strong {
  display: block;
  margin-top: 4px;
}

.link-button {
  margin-top: 10px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #9fc7ff;
  font: inherit;
  cursor: pointer;
  transition: color 160ms ease;
}

.link-button:hover,
.link-button:focus-visible {
  color: white;
}

.main {
  min-width: 0;
  padding: 18px 20px;
}

.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
  padding: 18px 20px;
  border: 1px solid rgba(130, 181, 255, 0.2);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(18, 40, 66, 0.9), rgba(9, 23, 38, 0.94));
  box-shadow: var(--panel-glow);
}

.top span {
  display: block;
  color: var(--muted);
}

.top strong {
  display: block;
  margin-top: 3px;
}

.help-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
  padding: 14px 16px;
  border: 1px solid rgba(130, 181, 255, 0.34);
  border-radius: 8px;
  background: rgba(18, 40, 66, 0.72);
}

.help-strip div,
.help-strip strong,
.help-strip span {
  display: block;
}

.help-strip > div {
  flex: 1 1 auto;
  min-width: 0;
}

.help-strip strong {
  margin-bottom: 4px;
}

.help-strip span {
  color: var(--muted);
}

.health {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(130, 181, 255, 0.18);
  border-radius: 8px;
  background: rgba(7, 18, 31, 0.58);
  color: var(--text);
  text-decoration: none;
}

.health b {
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: var(--green);
}

.health.blocked b {
  background: #ff7575;
}

.health.unknown b {
  background: var(--amber);
}

.seller-home-label {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  padding: 6px 12px;
  border: 1px solid rgba(130, 181, 255, 0.28);
  border-radius: 8px;
  background: rgba(47, 130, 255, 0.12);
  color: #cce2ff;
  font-weight: 800;
}

.hero,
.panel {
  padding: 18px;
  border: 1px solid rgba(130, 181, 255, 0.2);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(13, 29, 46, 0.92), rgba(8, 20, 34, 0.94));
  box-shadow: var(--panel-glow);
}

.hero-title-row,
.section-heading,
.side-card-heading {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.icon-link {
  display: inline-grid;
  flex: 0 0 auto;
  text-decoration: none;
}

.hero-title-row {
  align-items: flex-start;
}

.section-heading > div,
.hero-title-row > div {
  min-width: 0;
}

.section-sign,
.hero-sign {
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(130, 181, 255, 0.22);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(47, 130, 255, 0.18), rgba(47, 130, 255, 0.08));
  color: #9fc7ff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.section-sign {
  width: 34px;
  height: 34px;
  padding: 7px;
}

.hero-sign {
  width: 46px;
  height: 46px;
  padding: 10px;
  color: #d6e9ff;
}

.stacked-heading {
  margin-bottom: 14px;
}

.section-heading h1,
.section-heading h2,
.side-card-heading h2,
.hero-title-row h1 {
  margin-bottom: 0;
}

.section-heading p,
.hero-title-row p {
  margin-top: 6px;
  margin-bottom: 0;
}

.panel-heading {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.panel-heading h1,
.panel-heading p {
  margin-bottom: 0;
}

.panel-heading p {
  margin-top: 6px;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.help-start {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.help-start p {
  margin-bottom: 0;
}

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

.help-index a {
  padding: 13px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-2);
  color: #d4e1f0;
  font-weight: 800;
  text-decoration: none;
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease, color 160ms ease, transform 160ms ease;
}

.help-section {
  scroll-margin-top: 16px;
}

.help-checklist {
  display: grid;
  gap: 10px;
  margin-bottom: 16px;
}

.help-check-row {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  min-height: 46px;
  padding: 12px;
  border: 1px solid rgba(36, 64, 95, 0.9);
  border-radius: 8px;
  background: rgba(18, 40, 66, 0.56);
  line-height: 1.45;
}

.help-check-row input {
  width: 20px;
  height: 20px;
  margin-top: 2px;
  accent-color: var(--blue);
}

.help-check-row span {
  min-width: 0;
}

.help-check-row.is-done {
  border-color: rgba(83, 209, 120, 0.34);
  background: rgba(37, 92, 66, 0.24);
}

.help-check-row.is-done span {
  color: var(--muted);
  text-decoration: line-through;
  text-decoration-thickness: 2px;
}

.help-check-row.is-cleared,
.help-check-row[hidden] {
  display: none !important;
}

.help-cleared-note {
  margin: 0;
  padding: 9px 12px;
  border: 1px solid rgba(82, 255, 168, 0.24);
  border-radius: 8px;
  color: #8bf0be;
  background: rgba(34, 197, 94, 0.08);
  font-size: 13px;
  font-weight: 800;
}

.help-clear-confirm {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 10px;
  border: 1px solid rgba(255, 211, 106, 0.32);
  border-radius: 8px;
  color: #ffe09a;
  background: rgba(255, 211, 106, 0.1);
}

.help-clear-confirm strong {
  margin-right: auto;
  color: #fff2c5;
}

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

.review-file-card,
.panel,
.side-card,
.file-item,
tr[id^="prep-file-"] {
  scroll-margin-top: 18px;
}

tr[id^="optimization-"] {
  scroll-margin-top: 180px;
}

.legacy-anchor {
  display: block;
  height: 0;
  overflow: hidden;
  scroll-margin-top: 18px;
}

.legacy-anchor + .panel {
  margin-top: 28px;
}

.review-file-card:target,
.panel:target,
.side-card:target,
.file-item:target,
tr[id^="prep-file-"]:target,
tr[id^="optimization-"]:target {
  outline: 2px solid rgba(255, 211, 106, 0.86);
  outline-offset: 3px;
  box-shadow: 0 0 0 6px rgba(255, 211, 106, 0.14), var(--panel-glow);
}

.panel:target h1,
.panel:target h2,
.side-card:target h2 {
  color: #ffe09a;
}

.target-highlight-cleared {
  outline: 0 !important;
  box-shadow: var(--panel-glow) !important;
}

tr.target-highlight-cleared {
  box-shadow: none !important;
}

tr.optimization-row-completed td {
  background: rgba(40, 164, 116, 0.08);
}

tr.optimization-row-completed:target td {
  background: rgba(40, 164, 116, 0.18);
}

.optimization-focus {
  scroll-margin-top: 18px;
  border-color: rgba(44, 223, 139, 0.45);
  box-shadow: 0 0 0 1px rgba(44, 223, 139, 0.12), 0 18px 44px rgba(1, 8, 18, 0.22);
}

.optimization-focus.done {
  background: linear-gradient(180deg, rgba(18, 47, 78, 0.92), rgba(12, 34, 58, 0.92));
}

.optimization-focus-grid,
.optimization-focus-body {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.optimization-focus-grid article,
.optimization-focus-body article {
  border: 1px solid rgba(49, 91, 132, 0.92);
  border-radius: 8px;
  background: rgba(18, 40, 66, 0.58);
  padding: 14px;
}

.optimization-focus-grid span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
}

.optimization-focus-grid strong {
  display: block;
  color: #edf6ff;
  overflow-wrap: anywhere;
}

.optimization-focus-body h2 {
  margin: 0 0 8px;
  font-size: 1rem;
}

.optimization-focus-body p {
  margin: 0;
}

.optimization-focus-decision {
  margin-top: 14px;
}

.optimization-label {
  display: grid;
  gap: 3px;
}

.optimization-label strong {
  color: #dff9eb;
}

.optimization-label span {
  color: var(--muted);
}

.help-steps {
  display: grid;
  gap: 10px;
  margin: 0 0 16px;
  padding: 0;
  list-style: none;
  counter-reset: help-step;
}

.help-steps li {
  position: relative;
  min-height: 46px;
  padding: 12px 12px 12px 54px;
  border: 1px solid rgba(36, 64, 95, 0.9);
  border-radius: 8px;
  background: rgba(18, 40, 66, 0.56);
  line-height: 1.45;
  counter-increment: help-step;
}

.help-steps li::before {
  position: absolute;
  top: 10px;
  left: 12px;
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 999px;
  background: rgba(47, 130, 255, 0.2);
  color: #cce2ff;
  content: counter(help-step);
  font-weight: 900;
}

.help-links {
  justify-content: flex-start;
}

.hero {
  margin-bottom: 14px;
}

.panel + .panel,
main > section.panel + section.panel,
form.inline-review-form + .panel,
.review-item-form + .panel,
.review-photo-section + .panel {
  margin-top: 28px;
}

.metric-grid + .panel,
.health-check-grid + .panel,
.enhance-card-grid + .panel,
.review-grid + .panel,
.inline-review-form + .panel,
.file-board + .panel,
table + .panel {
  margin-top: 28px;
}

h1,
h2,
p {
  margin-top: 0;
}

h1,
h2 {
  color: #f3f8ff;
  font-weight: 900;
  line-height: 1.12;
}

h1 {
  font-size: 30px;
}

h2 {
  font-size: 21px;
}

.hero h1 {
  font-size: 31px;
}

.panel p,
.hero p {
  line-height: 1.48;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.metric-grid.compact {
  margin-top: 16px;
  margin-bottom: 18px;
}

.metric {
  display: block;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-2);
  color: var(--text);
  text-decoration: none;
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

a.metric:hover,
a.metric:focus-visible {
  border-color: rgba(130, 181, 255, 0.48);
  background: rgba(18, 40, 66, 0.74);
  box-shadow: 0 0 0 3px rgba(47, 130, 255, 0.12);
  transform: translateY(-1px);
}

.metric span,
.metric strong {
  display: block;
}

.metric strong {
  margin-top: 8px;
  font-size: 28px;
}

.metric strong.metric-value-attention {
  color: var(--amber);
}

.metric strong.metric-value-positive {
  color: var(--green);
}

.metric strong.metric-value-negative {
  color: #ff7575;
}

.metric strong.metric-value-zero {
  color: var(--text);
}

.metric .small-metric,
.small-metric {
  font-size: 15px;
  overflow-wrap: anywhere;
}

.admin-health {
  margin-bottom: 14px;
}

.health-check-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.health-check {
  display: grid;
  min-height: 156px;
  padding: 14px;
  border: 1px solid var(--line);
  border-left-width: 4px;
  border-radius: 8px;
  background: var(--panel-2);
}

.health-check.good {
  border-left-color: var(--green);
}

.health-check.warn {
  border-left-color: var(--amber);
}

.health-check.bad {
  border-left-color: #ff7575;
}

.health-check span,
.health-check p {
  color: var(--muted);
}

.health-check span,
.health-check strong,
.health-check p {
  display: block;
}

.health-check strong {
  margin-top: 6px;
  font-size: 22px;
}

.health-check p {
  margin: 7px 0 12px;
  font-size: 14px;
}

.health-check a {
  align-self: end;
  color: #9fc7ff;
  font-weight: 800;
  text-decoration: none;
}

.item-progress-list {
  display: grid;
  gap: 12px;
}

#one-item-progress {
  align-items: stretch;
  flex-direction: column;
}

#one-item-progress .section-heading {
  align-items: flex-start;
}

#one-item-progress .button-row {
  justify-content: flex-start;
}

.item-progress-card {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(14, 37, 61, 0.82);
}

.item-progress-card header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.item-progress-card header strong,
.item-progress-card header span {
  display: block;
}

.item-progress-card header strong {
  font-size: 18px;
  color: #d9ecff;
}

.item-progress-card header span {
  color: var(--muted);
}

.item-progress-meta {
  display: grid;
  grid-template-columns: minmax(180px, 1.5fr) repeat(3, minmax(110px, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}

.item-progress-meta > span,
.progress-next {
  min-height: 52px;
  padding: 9px 10px;
  border: 1px solid rgba(91, 141, 196, 0.56);
  border-radius: 8px;
  background: rgba(9, 29, 48, 0.92);
}

.progress-next {
  border-left: 4px solid rgba(142, 177, 215, 0.45);
  color: var(--text);
  text-decoration: none;
}

.progress-next.needs_attention {
  border-color: var(--amber);
  border-left-color: var(--amber);
  background: rgba(243, 189, 47, 0.16);
}

.progress-next.needs_attention strong {
  color: var(--amber);
}

.progress-next.ready {
  border-left-color: var(--blue);
}

.item-progress-meta span,
.progress-next span {
  display: block;
  color: #c6dcf5;
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.item-progress-meta strong,
.progress-next strong {
  display: block;
  margin-top: 3px;
  color: #edf6ff;
  font-size: 15px;
  overflow-wrap: anywhere;
}

.progress-steps {
  display: grid;
  grid-template-columns: repeat(5, minmax(120px, 1fr));
  gap: 8px;
}

.progress-step {
  display: grid;
  gap: 3px;
  min-height: 58px;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-left: 4px solid rgba(142, 177, 215, 0.45);
  border-radius: 8px;
  background: rgba(8, 24, 39, 0.9);
  color: var(--text);
  text-decoration: none;
}

.progress-step span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}

.progress-step strong {
  color: #e8f3ff;
  font-size: 14px;
  overflow-wrap: anywhere;
}

.progress-step.done {
  border-left-color: var(--green);
}

.progress-step.ready {
  border-left-color: var(--blue);
}

.progress-step.needs_attention {
  border-color: var(--amber);
  border-left-color: var(--amber);
  background: rgba(243, 189, 47, 0.16);
}

.progress-step.needs_attention strong {
  color: var(--amber);
}

.progress-step.waiting,
.progress-step.not_started {
  border-left-color: rgba(142, 177, 215, 0.45);
}

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

.action-list a {
  padding: 13px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-2);
  text-decoration: none;
}

.next-step-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 14px;
  padding: 18px;
  border: 1px solid rgba(130, 181, 255, 0.35);
  border-radius: 8px;
  background: rgba(18, 40, 66, 0.86);
}

.next-step-panel span,
.next-list span {
  color: var(--muted);
}

.next-step-panel h1 {
  margin-bottom: 6px;
}

.next-step-panel p {
  margin-bottom: 0;
}

.next-step-panel.urgent {
  border-color: rgba(255, 117, 117, 0.48);
  background: rgba(190, 54, 54, 0.16);
}

.next-step-panel.review {
  border-color: rgba(243, 189, 47, 0.42);
  background: rgba(243, 189, 47, 0.12);
}

.next-step-panel.done {
  border-color: rgba(83, 209, 120, 0.4);
  background: rgba(83, 209, 120, 0.1);
}

.next-list a {
  display: grid;
  gap: 4px;
}

.next-list a.urgent {
  border-color: rgba(255, 94, 117, 0.72);
  background: rgba(255, 94, 117, 0.16);
  box-shadow: inset 3px 0 0 rgba(255, 94, 117, 0.88);
}

.next-list a.urgent strong {
  color: #ffd2d8;
}

.next-list a.urgent span {
  color: #ff9eac;
}

.next-list a.review {
  border-color: rgba(243, 189, 47, 0.32);
}

.next-list a.done {
  border-color: rgba(83, 209, 120, 0.32);
}

.dashboard-command-grid {
  display: grid;
  grid-template-columns: minmax(190px, 0.6fr) minmax(810px, 2.8fr) minmax(225px, 0.7fr);
  gap: 12px;
  align-items: stretch;
  margin-bottom: 14px;
}

.dashboard-left-rail,
.dashboard-side-rail {
  display: grid;
  gap: 12px;
}

.board-panel,
.side-card {
  min-height: 100%;
}

.panel-heading.compact {
  margin-bottom: 10px;
}

.count-badge {
  display: inline-grid;
  min-width: 28px;
  min-height: 28px;
  place-items: center;
  padding: 4px 8px;
  border-radius: 8px;
  border: 1px solid rgba(130, 181, 255, 0.18);
  background: linear-gradient(180deg, rgba(47, 130, 255, 0.24), rgba(47, 130, 255, 0.12));
  color: #cce2ff;
  font-weight: 900;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.count-badge.attention-count {
  border-color: rgba(255, 211, 106, 0.5);
  background: linear-gradient(180deg, rgba(255, 211, 106, 0.34), rgba(255, 211, 106, 0.14));
  color: #ffe09a;
}

.command-tiles {
  display: grid;
  gap: 10px;
}

.command-tile {
  display: grid;
  gap: 4px;
  min-height: 76px;
  padding: 14px;
  border: 1px solid var(--soft-line);
  border-left-width: 4px;
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(18, 40, 66, 0.8), rgba(9, 24, 40, 0.9));
  text-decoration: none;
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.command-tile strong,
.command-tile span {
  display: block;
}

.command-tile span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.command-tile.work {
  border-left-color: var(--blue);
}

.command-tile.review {
  border-left-color: var(--amber);
}

.command-tile.urgent {
  border-color: rgba(255, 94, 117, 0.72);
  border-left-color: rgba(255, 94, 117, 0.92);
  background: rgba(255, 94, 117, 0.16);
  box-shadow: inset 3px 0 0 rgba(255, 94, 117, 0.88);
}

.command-tile.urgent strong {
  color: #ffd2d8;
}

.command-tile.urgent span {
  color: #ff9eac;
}

.command-tile.done {
  border-left-color: var(--green);
}

.command-tile:hover,
.command-tile:focus-visible {
  border-color: rgba(130, 181, 255, 0.72);
  box-shadow: 0 0 0 3px rgba(47, 130, 255, 0.14), 0 12px 24px rgba(0, 0, 0, 0.18);
  outline: none;
  transform: translateY(-1px);
}

.stretch-action {
  width: 100%;
  margin-top: 12px;
}

.dashboard-board {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  min-width: 0;
}

.board-column {
  display: grid;
  grid-template-rows: auto 1fr;
  min-width: 0;
  min-height: 500px;
  padding: 9px;
  border: 1px solid var(--soft-line);
  border-top: 3px solid rgba(130, 181, 255, 0.25);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(13, 29, 46, 0.96), rgba(7, 18, 31, 0.96));
  box-shadow: var(--panel-glow);
}

.board-column.photos {
  border-top-color: var(--blue);
}

.board-column.docx {
  border-top-color: #4aa3ff;
}

.board-column.review {
  border-top-color: var(--amber);
}

.board-column.mandrake {
  border-top-color: var(--purple);
}

.board-column.attention {
  border-top-color: var(--red);
}

.board-column header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 42px;
  margin-bottom: 10px;
}

.board-column-title {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.board-column-title h2 {
  min-width: 0;
}

.lane-icon {
  display: inline-grid;
  flex: 0 0 30px;
  width: 30px;
  height: 30px;
  place-items: center;
  border: 1px solid rgba(130, 181, 255, 0.22);
  border-radius: 8px;
  background: rgba(47, 130, 255, 0.14);
  color: #b8d7ff;
  font-size: 11px;
  font-weight: 900;
}

.board-column.review .lane-icon,
.board-column.attention .lane-icon {
  background: rgba(243, 189, 47, 0.12);
  color: #ffd36a;
}

.board-column.mandrake .lane-icon {
  background: rgba(142, 118, 255, 0.16);
  color: #cfc5ff;
}

.board-column h2 {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.2;
  overflow-wrap: normal;
  word-break: normal;
}

.board-card-stack {
  display: grid;
  align-content: start;
  gap: 10px;
}

.board-item {
  display: grid;
  gap: 10px;
  min-height: 176px;
  padding: 8px;
  border: 1px solid rgba(130, 181, 255, 0.22);
  border-left-width: 4px;
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(18, 40, 66, 0.74), rgba(8, 21, 36, 0.92));
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.18);
}

.board-item.work {
  border-left-color: var(--blue);
}

.board-item.review,
.board-item.warn {
  border-left-color: var(--amber);
}

.board-item.waiting {
  border-left-color: var(--purple);
}

.board-item-top {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
}

.board-thumb {
  width: 34px;
  height: 34px;
  border: 1px solid rgba(130, 181, 255, 0.22);
  border-radius: 8px;
  background: #081827;
  object-fit: cover;
}

.board-thumb.empty {
  display: grid;
  place-items: center;
  color: var(--muted);
  font-size: 8px;
  font-weight: 900;
}

.board-item-title {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.board-item-id,
.board-item-name,
.board-next-action {
  min-width: 0;
}

.board-item-id {
  display: block;
  max-width: 100%;
  overflow: hidden;
  color: #dcecff;
  font-size: 11.5px;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.board-item-name,
.board-warning {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.3;
}

.board-item-name {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.board-checks {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 11.5px;
}

.board-checks span {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  min-width: 0;
}

.board-checks em {
  min-width: 0;
  color: #b8c9dd;
  font-style: normal;
}

.status-value {
  justify-self: end;
  max-width: 86px;
  overflow: hidden;
  line-height: 1.15;
  overflow-wrap: anywhere;
  color: var(--text);
  font-weight: 800;
  text-align: right;
}

.status-value.good {
  color: #67e892;
}

.status-value.warn,
.status-value.review {
  color: #ffd36a;
}

.status-value.waiting {
  color: #c1cbd8;
}

.status-value.muted {
  color: var(--text);
}

.board-warning {
  color: #ffd36a;
}

.board-next-action {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  align-self: end;
  min-height: 34px;
  padding: 8px 10px;
  border: 1px solid rgba(130, 181, 255, 0.22);
  border-radius: 8px;
  background: rgba(47, 130, 255, 0.08);
  color: #9fc7ff;
  font-size: 13px;
  font-weight: 900;
  text-decoration: none;
}

.board-next-action span {
  min-width: 0;
}

.board-next-action b {
  flex: 0 0 auto;
}

.board-empty,
.side-empty {
  display: grid;
  min-height: 94px;
  place-items: center;
  padding: 12px;
  border: 1px dashed rgba(130, 181, 255, 0.28);
  border-radius: 8px;
  color: var(--muted);
  text-align: center;
  background: rgba(18, 40, 66, 0.22);
}

.mini-calendar {
  display: grid;
  gap: 12px;
}

.mini-calendar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.mini-calendar-head strong {
  text-align: center;
}

.mini-calendar-head a,
.mini-calendar-reset,
.mini-calendar-today {
  color: #9fc7ff;
  font-size: 13px;
  font-weight: 900;
  text-decoration: none;
}

.calendar-nav-button {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border: 1px solid rgba(130, 181, 255, 0.26);
  border-radius: 8px;
  background: rgba(47, 130, 255, 0.08);
  line-height: 1;
}

.calendar-nav-button:hover,
.mini-calendar-reset:hover,
.mini-calendar-today:hover {
  border-color: rgba(130, 181, 255, 0.48);
  background: rgba(47, 130, 255, 0.16);
}

.mini-calendar-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.mini-calendar-reset,
.mini-calendar-today {
  padding: 5px 8px;
  border: 1px solid rgba(130, 181, 255, 0.22);
  border-radius: 8px;
  background: rgba(47, 130, 255, 0.06);
}

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

.mini-calendar-grid span,
.mini-calendar-grid a {
  display: grid;
  position: relative;
  min-height: 30px;
  place-items: center;
  border-radius: 8px;
  color: #d4e1f0;
  font-size: 13px;
  text-decoration: none;
}

.mini-calendar-grid .day-label {
  min-height: 22px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.mini-calendar-grid .muted-day {
  opacity: 0.3;
}

.mini-calendar-grid .today {
  background: linear-gradient(180deg, #3f8cff, #2f82ff);
  color: white;
  font-weight: 900;
}

.mini-calendar-grid .has-reminders {
  border: 1px solid rgba(255, 211, 106, 0.86);
  background: rgba(255, 211, 106, 0.18);
  color: #ffe09a;
  font-weight: 900;
  box-shadow: inset 0 0 0 1px rgba(255, 211, 106, 0.16);
}

.mini-calendar-grid .has-overdue-reminders {
  border-color: rgba(255, 94, 117, 0.88);
  background: rgba(255, 94, 117, 0.16);
  color: #ffd2d8;
  box-shadow: inset 0 0 0 1px rgba(255, 94, 117, 0.24), 0 0 0 1px rgba(255, 94, 117, 0.16);
}

.mini-calendar-grid .selected-day {
  box-shadow: 0 0 0 2px rgba(82, 168, 255, 0.62);
}

.mini-calendar-grid .has-reminders b {
  position: absolute;
  top: -7px;
  right: -7px;
  display: grid;
  min-width: 20px;
  height: 20px;
  place-items: center;
  padding: 0 5px;
  border-radius: 999px;
  background: #ffd36a;
  color: #06111d;
  font-size: 11px;
  font-weight: 950;
  line-height: 1;
}

.mini-calendar-grid .has-overdue-reminders b {
  background: #ff5e75;
  color: #fff5f7;
}

.mini-calendar-busy {
  display: grid;
  gap: 8px;
  padding-top: 2px;
}

.mini-calendar-busy > span,
.mini-calendar-empty {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.mini-calendar-busy > div {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.mini-calendar-busy a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 8px;
  border: 1px solid rgba(255, 211, 106, 0.42);
  border-radius: 999px;
  color: #ffe09a;
  background: rgba(255, 211, 106, 0.1);
  font-size: 12px;
  text-decoration: none;
}

.mini-calendar-busy a b {
  display: grid;
  min-width: 18px;
  height: 18px;
  place-items: center;
  border-radius: 999px;
  color: #06111d;
  background: #ffd36a;
}

.mini-calendar-busy a.overdue {
  border-color: rgba(255, 94, 117, 0.72);
  background: rgba(255, 94, 117, 0.14);
  color: #ffd2d8;
}

.mini-calendar-busy a.overdue b {
  background: #ff5e75;
  color: #fff5f7;
}

.side-list {
  display: grid;
  gap: 8px;
}

.side-list a {
  display: grid;
  gap: 3px;
  padding: 10px;
  border: 1px solid rgba(130, 181, 255, 0.2);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(18, 40, 66, 0.62), rgba(9, 24, 40, 0.82));
  text-decoration: none;
}

.side-list span,
.side-card p {
  color: var(--muted);
}

.side-list a.urgent {
  border-color: rgba(255, 94, 117, 0.72);
  background: rgba(255, 94, 117, 0.16);
  box-shadow: inset 3px 0 0 rgba(255, 94, 117, 0.88);
}

.side-list a.urgent strong {
  color: #ffd2d8;
}

.side-list a.urgent span {
  color: #ff9eac;
}

.side-card h2 {
  margin-bottom: 8px;
  font-size: 18px;
}

.side-card p {
  margin-bottom: 8px;
}

.side-card p strong {
  color: var(--text);
}

.side-stat-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid rgba(130, 181, 255, 0.12);
}

.side-stat-row span {
  color: var(--muted);
}

.side-stat-row strong {
  color: var(--text);
}

.warning-card {
  border-color: rgba(243, 189, 47, 0.28);
}

.warn-badge {
  background: linear-gradient(180deg, rgba(243, 189, 47, 0.24), rgba(243, 189, 47, 0.1));
  color: #ffe08a;
}

.reminder-badge {
  background: linear-gradient(180deg, rgba(255, 211, 106, 0.36), rgba(255, 211, 106, 0.14));
  color: #ffe09a;
}

.reminder-badge.overdue {
  background: linear-gradient(180deg, rgba(255, 94, 117, 0.36), rgba(255, 94, 117, 0.16));
  color: #ffd2d8;
  border-color: rgba(255, 94, 117, 0.58);
}

.summary-strip {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
  padding: 12px;
  border: 1px solid var(--soft-line);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(13, 29, 46, 0.9), rgba(7, 18, 31, 0.96));
  box-shadow: var(--panel-glow);
}

.summary-strip article,
.summary-strip .summary-card {
  display: block;
  min-height: 72px;
  padding: 10px;
  border: 1px solid rgba(130, 181, 255, 0.2);
  border-radius: 8px;
  background: rgba(18, 40, 66, 0.5);
  color: var(--text);
  text-decoration: none;
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.summary-strip .summary-card:hover,
.summary-strip .summary-card:focus-visible {
  border-color: rgba(130, 181, 255, 0.48);
  background: rgba(18, 40, 66, 0.78);
  box-shadow: 0 0 0 3px rgba(47, 130, 255, 0.12);
  transform: translateY(-1px);
}

.summary-strip span,
.summary-strip strong {
  display: block;
}

.summary-strip span {
  color: var(--muted);
  font-size: 12px;
}

.summary-strip strong {
  margin-top: 8px;
  font-size: 21px;
}

@media (max-width: 1320px) {
  .dashboard-command-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .dashboard-board {
    grid-template-columns: repeat(5, minmax(210px, 1fr));
    overflow-x: auto;
    padding-bottom: 2px;
    -webkit-overflow-scrolling: touch;
  }

  .board-item {
    grid-template-columns: 1fr;
  }

  .board-thumb {
    width: 100%;
    height: 92px;
  }

  .dashboard-side-rail {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.search-form,
.root-list {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: end;
}

.search-form label {
  flex: 1 1 280px;
}

.search-form input,
.search-form select {
  min-width: 0;
  min-height: 42px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #0b2138;
  color: var(--text);
  font: inherit;
}

.search-form input:focus,
.search-form select:focus {
  outline: 2px solid rgba(47, 130, 255, 0.65);
  outline-offset: 2px;
  border-color: rgba(130, 181, 255, 0.78);
}

.root-list {
  margin-top: 14px;
}

.root-list.compact {
  align-items: stretch;
  margin-top: 0;
}

.root-list a,
.root-list span,
.secondary-action {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(18, 40, 66, 0.98), rgba(13, 29, 46, 0.98));
  color: #d4e1f0;
  font-weight: 800;
  text-decoration: none;
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease, color 160ms ease, transform 160ms ease;
}

.path-cell {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  overflow-wrap: anywhere;
}

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

.mission-grid article {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(18, 40, 66, 0.48);
}

.mission-grid dl {
  margin: 0;
}

.mission-grid dt {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.mission-grid dd {
  margin: 3px 0 12px;
}

table {
  display: block;
  width: 100%;
  max-width: 100%;
  border-collapse: collapse;
  overflow: hidden;
  overflow-x: auto;
  border-radius: 8px;
  -webkit-overflow-scrolling: touch;
}

th,
td {
  padding: 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.pill {
  display: inline-flex;
  padding: 4px 8px;
  border-radius: 6px;
  background: rgba(47, 130, 255, 0.18);
  color: #9fc7ff;
  font-size: 12px;
  font-weight: 800;
}

.pill.good {
  background: rgba(83, 209, 120, 0.14);
  color: var(--green);
}

.pill.warn {
  background: rgba(243, 189, 47, 0.13);
  color: var(--amber);
}

code {
  color: var(--amber);
}

.auth-page {
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 20px;
}

.login-card {
  width: min(440px, 100%);
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(13, 29, 46, 0.94);
}

.login-brand {
  display: grid;
  justify-items: center;
  margin-bottom: 20px;
  text-align: center;
}

.login-brand img {
  width: min(180px, 72vw);
}

.login-card label {
  display: grid;
  gap: 7px;
  margin-top: 14px;
  color: var(--muted);
}

.login-card input {
  width: 100%;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #081827;
  color: var(--text);
  font: inherit;
}

.password-control {
  position: relative;
  display: block;
}

.password-control input {
  width: 100%;
  padding-right: 52px;
}

.password-toggle {
  position: absolute;
  top: 50%;
  right: 6px;
  display: grid;
  width: 38px;
  height: 34px;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #9fc7ff;
  cursor: pointer;
  transform: translateY(-50%);
}

.password-toggle:hover,
.password-toggle:focus-visible {
  background: rgba(47, 130, 255, 0.18);
  outline: none;
}

.password-toggle svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.password-toggle .eye-closed {
  display: none;
}

.password-toggle.is-visible .eye-open {
  display: none;
}

.password-toggle.is-visible .eye-closed {
  display: block;
}

.intake-form {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.listing-wizard {
  display: block;
}

#create-listing {
  scroll-margin-top: 84px;
}

.listing-wizard-steps {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  margin: 18px 0;
  padding: 0;
  list-style: none;
}

.listing-wizard-steps button {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  align-items: center;
  gap: 7px;
  width: 100%;
  min-height: 48px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #081827;
  color: var(--muted);
  font: inherit;
  font-size: 12px;
  font-weight: 900;
  text-align: left;
}

.listing-wizard-steps button span {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #183a61;
  color: var(--text);
}

.listing-wizard-steps button.is-active,
.listing-wizard-steps button:hover {
  border-color: rgba(76, 145, 255, 0.86);
  background: rgba(41, 112, 217, 0.2);
  color: var(--text);
}

.listing-wizard-steps button.is-active span {
  background: var(--blue);
}

.listing-wizard-step {
  min-width: 0;
  margin: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(8, 24, 39, 0.56);
}

.listing-wizard-step[hidden] {
  display: none !important;
}

.listing-wizard-step legend {
  max-width: 100%;
  padding: 0 8px;
  color: var(--text);
  font-size: 18px;
  font-weight: 900;
}

.listing-wizard-step legend span {
  display: block;
  margin-bottom: 3px;
  color: var(--blue-2);
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.wizard-fields {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.wizard-helper {
  margin: 0 0 14px;
  color: var(--muted);
}

.wizard-next-note {
  padding: 14px;
  border: 1px solid rgba(76, 145, 255, 0.48);
  border-radius: 9px;
  background: rgba(22, 68, 119, 0.2);
}

.wizard-next-note h2 {
  margin: 0 0 8px;
  font-size: 17px;
}

.wizard-next-note p {
  margin: 7px 0 0;
}

.listing-wizard-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 16px;
}

.listing-wizard-actions [hidden] {
  display: none !important;
}

.wizard-progress {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.listing-wizard-summary {
  margin: 14px 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #081827;
}

.listing-wizard-summary dl {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 8px 14px;
  margin: 0;
}

.listing-wizard-summary dt {
  color: var(--muted);
  font-weight: 800;
}

.listing-wizard-summary dd {
  min-width: 0;
  margin: 0;
  overflow-wrap: anywhere;
  font-weight: 900;
}

.intake-form label {
  display: grid;
  gap: 7px;
  min-width: 0;
  color: var(--muted);
}

.intake-form .full {
  grid-column: 1 / -1;
}

.intake-form input,
.intake-form select,
.intake-form textarea {
  min-width: 0;
  width: 100%;
  min-height: 42px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #081827;
  color: var(--text);
  font: inherit;
}

.reminder-title-field {
  position: relative;
}

.char-counter {
  justify-self: end;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.char-counter.over-limit,
.form-error {
  color: var(--red);
}

.field-over-limit {
  border-color: rgba(255, 117, 117, 0.9) !important;
  box-shadow: 0 0 0 2px rgba(255, 117, 117, 0.18);
}

.form-error {
  margin-top: 0;
  padding: 10px 12px;
  border: 1px solid rgba(255, 117, 117, 0.45);
  border-radius: 8px;
  background: rgba(74, 20, 32, 0.28);
  font-weight: 800;
}

.intake-form input[type="checkbox"],
.intake-form input[type="radio"] {
  justify-self: start;
  width: auto;
  min-height: auto;
}

.intake-form .checkbox-tile {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 42px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 24, 39, 0.82);
  color: var(--text);
  font-weight: 800;
}

.intake-form .checkbox-tile input {
  flex: 0 0 auto;
  width: 16px;
  min-height: 16px;
  margin: 0;
  accent-color: var(--blue);
}

.intake-form textarea {
  min-height: 74px;
  padding-top: 10px;
  resize: vertical;
}

.compact-edit {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.upload-dropzone {
  min-height: 124px;
  padding: 18px;
  border: 1px dashed rgba(130, 181, 255, 0.55);
  border-radius: 8px;
  background: rgba(8, 24, 39, 0.62);
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

.upload-dropzone span,
.upload-dropzone small,
.upload-dropzone em {
  display: block;
}

.upload-dropzone span {
  color: var(--text);
  font-weight: 900;
}

.upload-dropzone small,
.upload-dropzone em {
  color: var(--muted);
}

.upload-dropzone small {
  max-width: 760px;
  line-height: 1.45;
}

.upload-dropzone input[type="file"] {
  margin: 12px 0 6px;
}

.selected-file-preview {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(118px, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.selected-file-preview article {
  min-height: 92px;
  padding: 8px;
  border: 1px solid rgba(130, 181, 255, 0.32);
  border-radius: 8px;
  background: rgba(15, 37, 61, 0.82);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.04);
  overflow: hidden;
}

.selected-file-preview img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 6px;
  margin-bottom: 7px;
  background: rgba(5, 14, 25, 0.9);
}

.selected-file-preview b {
  display: grid;
  place-items: center;
  min-height: 70px;
  margin-bottom: 7px;
  border-radius: 6px;
  background: rgba(45, 130, 255, 0.16);
  color: var(--accent-soft);
  font-size: 0.74rem;
  letter-spacing: 0;
}

.selected-file-preview span {
  display: block;
  color: var(--text);
  font-size: 0.78rem;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.upload-dropzone.is-dragging,
.upload-dropzone:hover,
.upload-dropzone:focus-within {
  border-color: rgba(130, 181, 255, 0.78);
  background: rgba(18, 40, 66, 0.92);
  box-shadow: 0 0 0 3px rgba(47, 130, 255, 0.14);
}

.mini-action {
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid rgba(130, 181, 255, 0.4);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(18, 40, 66, 0.98), rgba(13, 29, 46, 0.98));
  color: white;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease, color 160ms ease, transform 160ms ease;
}

.mini-action.danger {
  border-color: rgba(255, 117, 117, 0.42);
  background: rgba(190, 54, 54, 0.34);
}

.mini-action:disabled {
  opacity: 0.68;
  cursor: not-allowed;
  filter: saturate(0.72);
}

.submit-lock.is-submitting {
  opacity: 0.86;
  pointer-events: none;
}

.workflow-note {
  margin-top: 8px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.workflow-note.warn {
  color: #ffd36a;
}

.workflow-note.good {
  color: #65d98b;
}

.saved-review-note {
  margin-bottom: 12px;
  padding: 10px 12px;
  border: 1px solid rgba(82, 255, 168, 0.25);
  border-radius: 8px;
  background: rgba(34, 197, 94, 0.08);
}

.workflow-note.info {
  padding: 10px 12px;
  border: 1px solid rgba(255, 211, 106, 0.22);
  border-radius: 8px;
  color: #ffe09a;
  background: rgba(255, 211, 106, 0.08);
}

.mini-link {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  margin-top: 8px;
  padding: 0 10px;
  border: 1px solid rgba(130, 181, 255, 0.4);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(18, 40, 66, 0.98), rgba(13, 29, 46, 0.98));
  color: white;
  font-weight: 800;
  text-decoration: none;
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease, color 160ms ease, transform 160ms ease;
}

.checklist-rows {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 8px;
}

.checklist-rows li {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.checklist-inline {
  margin-left: 0;
}

.checklist-inline .mini-action {
  min-height: 28px;
  margin: 0;
  padding: 0 8px;
  font-size: 12px;
}

.nas-preview {
  display: block;
  width: 96px;
  max-height: 96px;
  margin-top: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  object-fit: contain;
  background: #081827;
}

.file-thumb {
  display: block;
  width: 84px;
  height: 84px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #081827;
  object-fit: cover;
}

.enhance-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.enhance-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid rgba(130, 181, 255, 0.22);
  border-radius: 8px;
  background: rgba(8, 24, 39, 0.4);
}

.enhance-card h3 {
  margin: 0 0 4px;
}

.enhance-card p {
  margin: 0;
  color: var(--muted);
}

.enhance-card .item-full-title {
  color: #aabbd0;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.3;
}

.enhance-form,
.enhance-form fieldset {
  display: grid;
  gap: 10px;
}

.enhance-form fieldset {
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  margin: 0;
  padding: 10px;
  border: 1px solid rgba(130, 181, 255, 0.2);
  border-radius: 8px;
}

.enhance-form .enhance-focus-list {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.enhance-focus-list label {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 8px;
  border: 1px solid rgba(130, 181, 255, 0.18);
  border-radius: 8px;
  background: rgba(18, 40, 66, 0.48);
}

.enhance-focus-list label span {
  display: grid;
  gap: 3px;
}

.enhance-focus-list label small {
  color: var(--muted);
  line-height: 1.35;
}

.enhance-form legend {
  padding: 0 6px;
  color: var(--muted);
  font-weight: 800;
}

.enhance-note {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-weight: 800;
}

.enhance-note textarea {
  width: 100%;
  min-height: 74px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #081827;
  color: var(--text);
  font: inherit;
  resize: vertical;
}

.review-photo-section {
  margin: 16px 0;
  padding: 12px;
  border: 1px solid rgba(130, 181, 255, 0.2);
  border-radius: 8px;
  background: rgba(8, 24, 39, 0.3);
}

.compact-heading {
  margin-bottom: 12px;
}

.review-photo-strip {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(142px, 1fr));
  gap: 12px;
}

.review-photo-card {
  position: relative;
  display: grid;
  gap: 8px;
  min-height: 208px;
  padding: 10px;
  border: 1px solid rgba(130, 181, 255, 0.22);
  border-radius: 8px;
  background: rgba(18, 40, 66, 0.5);
}

.sortable-photo-card {
  cursor: grab;
}

.sortable-photo-card:active,
.sortable-photo-card.is-dragging {
  cursor: grabbing;
}

.sortable-photo-card.is-dragging {
  opacity: 0.58;
  outline: 2px dashed rgba(255, 211, 106, 0.72);
}

.sortable-photo-card.is-cover-order {
  border-color: rgba(255, 211, 106, 0.46);
}

.review-photo-card img {
  width: 100%;
  aspect-ratio: 1;
  border: 1px solid rgba(130, 181, 255, 0.24);
  border-radius: 8px;
  background: #081827;
  object-fit: cover;
}

.photo-order {
  position: absolute;
  top: 8px;
  left: 8px;
  display: inline-flex;
  min-width: 28px;
  height: 28px;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(130, 181, 255, 0.5);
  border-radius: 8px;
  background: rgba(13, 29, 46, 0.88);
  color: white;
  font-weight: 900;
}

.photo-card-meta,
.photo-warning-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.photo-card-meta strong {
  color: var(--text);
}

.photo-card-meta span {
  color: var(--muted);
  font-size: 12px;
}

.photo-move-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.photo-listing-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.photo-move-button,
.photo-edit-button,
.photo-remove-button,
.photo-restore-button {
  min-height: 44px;
  padding: 9px 8px;
  border: 1px solid rgba(130, 181, 255, 0.5);
  border-radius: 8px;
  background: #102d4b;
  color: var(--text);
  font: inherit;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.15;
  cursor: pointer;
}

.photo-edit-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  text-decoration: none;
}

.photo-remove-button {
  border-color: rgba(255, 115, 137, 0.7);
  background: rgba(126, 38, 62, 0.6);
}

.photo-restore-button {
  border-color: rgba(88, 212, 137, 0.7);
  background: rgba(24, 104, 74, 0.54);
}

.photo-move-button:hover:not(:disabled),
.photo-move-button:focus-visible,
.photo-edit-button:hover,
.photo-edit-button:focus-visible,
.photo-remove-button:hover,
.photo-remove-button:focus-visible,
.photo-restore-button:hover,
.photo-restore-button:focus-visible {
  border-color: var(--blue);
  background: rgba(43, 126, 255, 0.24);
  outline: none;
}

.photo-move-button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.removed-photo-panel {
  margin-top: 14px;
  padding: 12px;
  border: 1px solid rgba(255, 184, 80, 0.42);
  border-radius: 10px;
  background: rgba(74, 56, 25, 0.24);
}

.removed-photo-panel summary {
  cursor: pointer;
  color: #ffd886;
  font-weight: 800;
}

.removed-photo-strip {
  margin-top: 12px;
}

.removed-photo-card {
  border-color: rgba(255, 184, 80, 0.48);
}

.review-photo-order-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 12px;
}

.file-review-cards {
  display: grid;
  gap: 12px;
}

.remove-locked-note {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}

.review-file-card {
  display: grid;
  grid-template-columns: 104px minmax(220px, 0.8fr) minmax(360px, 1.4fr);
  gap: 12px;
  align-items: start;
  padding: 12px;
  border: 1px solid rgba(130, 181, 255, 0.2);
  border-radius: 8px;
  background: rgba(8, 24, 39, 0.38);
}

.review-file-media {
  display: grid;
  min-height: 92px;
  place-items: center;
}

.review-file-details {
  display: grid;
  gap: 10px;
}

.review-file-details strong {
  display: block;
}

.file-meta,
.review-markers {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.muted {
  color: var(--muted);
}

.primary-action,
.primary-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  margin-top: 18px;
  padding: 0 18px;
  border: 1px solid rgba(130, 181, 255, 0.4);
  border-radius: 8px;
  background: linear-gradient(180deg, #3f8cff, #2f82ff);
  color: white;
  font: inherit;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(47, 130, 255, 0.13);
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease, color 160ms ease, transform 160ms ease;
}

.help-index a:hover,
.help-index a:focus-visible,
.root-list a:hover,
.root-list a:focus-visible,
.secondary-action:hover,
.secondary-action:focus-visible,
.mini-action:hover,
.mini-action:focus-visible,
.mini-link:hover,
.mini-link:focus-visible,
.primary-action:hover,
.primary-action:focus-visible,
.primary-link:hover,
.primary-link:focus-visible {
  border-color: rgba(130, 181, 255, 0.72);
  background: rgba(27, 61, 98, 0.98);
  box-shadow: 0 0 0 3px rgba(47, 130, 255, 0.14), 0 12px 24px rgba(0, 0, 0, 0.18);
  color: white;
  outline: none;
  transform: translateY(-1px);
}

.primary-action:hover,
.primary-action:focus-visible,
.primary-link:hover,
.primary-link:focus-visible {
  background: #3f8cff;
}

.mini-action.danger:hover,
.mini-action.danger:focus-visible {
  border-color: rgba(255, 117, 117, 0.68);
  background: rgba(190, 54, 54, 0.48);
  box-shadow: 0 0 0 3px rgba(255, 117, 117, 0.12), 0 12px 24px rgba(0, 0, 0, 0.18);
}

.primary-action:active,
.primary-link:active,
.secondary-action:active,
.mini-action:active,
.mini-link:active,
.help-index a:active,
.root-list a:active {
  transform: translateY(0);
}

input[type="file"]::file-selector-button {
  min-height: 32px;
  margin-right: 8px;
  padding: 0 10px;
  border: 1px solid rgba(130, 181, 255, 0.42);
  border-radius: 8px;
  background: rgba(18, 40, 66, 0.96);
  color: white;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease, color 160ms ease;
}

input[type="file"]::file-selector-button:hover {
  border-color: rgba(130, 181, 255, 0.72);
  background: rgba(27, 61, 98, 0.98);
  box-shadow: 0 0 0 3px rgba(47, 130, 255, 0.14);
}

.primary-action:disabled:hover,
.mini-action:disabled:hover {
  box-shadow: none;
  transform: translateY(1px);
}

.primary-action:disabled {
  opacity: 0.68;
  cursor: not-allowed;
  filter: saturate(0.72);
  transform: translateY(1px);
}

.intake-form.is-submitting {
  opacity: 0.86;
  pointer-events: none;
}

.file-board {
  display: grid;
  gap: 14px;
}

.item-workspace-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 12px;
}

.item-workspace-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  min-height: 116px;
  padding: 14px;
  border: 1px solid rgba(130, 181, 255, 0.32);
  border-left: 5px solid rgba(47, 130, 255, 0.76);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(18, 40, 66, 0.62), rgba(7, 18, 31, 0.8));
}

.item-workspace-card h2 {
  margin: 0 0 4px;
  font-size: 22px;
}

.item-workspace-card p,
.item-workspace-card small {
  display: block;
  margin: 0 0 8px;
  color: var(--muted);
}

.item-workspace-card small {
  margin-top: 8px;
  font-size: 13px;
}

.item-primary-action {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 16px;
  border: 1px solid rgba(47, 130, 255, 0.58);
  border-left: 5px solid var(--blue);
  border-radius: 10px;
  background: linear-gradient(105deg, rgba(21, 54, 92, 0.92), rgba(8, 24, 39, 0.9));
}

.item-primary-action > div {
  min-width: 0;
}

.item-primary-action span {
  display: block;
  margin-bottom: 2px;
  color: #99c7ff;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.item-primary-action h2 {
  margin: 0;
  color: #f3f8ff;
  font-size: 22px;
}

.item-primary-action p {
  margin: 5px 0 0;
  color: var(--muted);
}

.item-primary-action .primary-action {
  min-width: 168px;
}

.item-workspace-more {
  margin-top: 12px;
  border: 1px solid rgba(130, 181, 255, 0.26);
  border-radius: 8px;
  background: rgba(8, 24, 39, 0.42);
}

.item-workspace-more summary {
  min-height: 44px;
  padding: 11px 14px;
  cursor: pointer;
  color: #d4e1f0;
  font-weight: 850;
}

.item-workspace-more[open] summary {
  border-bottom: 1px solid rgba(130, 181, 255, 0.2);
}

.item-workspace-more > p,
.item-workspace-more > .button-row {
  margin: 12px 14px;
}

.item-workspace-more > p {
  color: var(--muted);
}

.item-workspace-more > .button-row {
  justify-content: flex-start;
}

.secondary-workspace-panel {
  border-color: rgba(130, 181, 255, 0.22);
}

.file-item {
  padding: 14px;
  border: 1px solid rgba(130, 181, 255, 0.32);
  border-left: 5px solid rgba(47, 130, 255, 0.76);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(18, 40, 66, 0.62), rgba(7, 18, 31, 0.8));
}

.file-item header,
.file-item summary.item-section-head {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: baseline;
  margin: -14px -14px 16px;
  padding: 13px 16px;
  border-bottom: 1px solid rgba(130, 181, 255, 0.28);
  border-radius: 8px 8px 0 0;
  background: linear-gradient(90deg, rgba(47, 130, 255, 0.24), rgba(18, 40, 66, 0.72));
}

.file-item summary.item-section-head {
  cursor: pointer;
  list-style: none;
}

.file-item summary.item-section-head::-webkit-details-marker {
  display: none;
}

.item-collapsible:not([open]) summary.item-section-head {
  margin-bottom: -14px;
  border-bottom: 0;
  border-radius: 8px;
}

.item-collapsible.needs-attention {
  border-left-color: var(--amber);
}

.item-collapsible.needs-attention summary.item-section-head {
  background: linear-gradient(90deg, rgba(255, 193, 7, 0.2), rgba(18, 40, 66, 0.72));
}

.item-section-head strong {
  color: #dcecff;
  font-size: 20px;
  letter-spacing: 0;
}

.file-item header span,
.file-item summary.item-section-head span {
  min-width: min(100%, 280px);
  flex: 1 1 520px;
  color: var(--muted);
  font-size: 16px;
  font-weight: 800;
  white-space: normal;
  overflow-wrap: anywhere;
}

.file-actions {
  display: grid;
  gap: 10px;
  min-width: min(520px, 100%);
}

.file-actions form {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: stretch;
}

.file-actions label {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  color: var(--muted);
  font-size: 13px;
}

.file-actions input[type="number"] {
  width: 66px;
  min-height: 34px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #081827;
  color: var(--text);
}

.file-review-form {
  max-width: 780px;
}

.action-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  min-height: 44px;
  padding: 8px;
  border: 1px solid rgba(130, 181, 255, 0.2);
  border-radius: 8px;
  background: rgba(8, 24, 39, 0.44);
}

.action-group-title {
  width: 100%;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.action-group-note {
  width: 100%;
  margin: -2px 0 2px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.prep-group {
  flex: 1 1 360px;
}

.save-group {
  align-content: center;
  justify-content: center;
  min-width: 92px;
  padding: 6px;
}

.save-group .mini-action {
  margin: 0;
}

.file-actions select,
.file-actions input[name="crop_note"] {
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #081827;
  color: var(--text);
}

.file-actions select {
  max-width: 132px;
}

.file-actions input[name="crop_note"] {
  width: min(220px, 100%);
  padding: 0 8px;
}

.notice {
  padding: 12px;
  border: 1px solid rgba(243, 189, 47, 0.3);
  border-radius: 8px;
  background: rgba(243, 189, 47, 0.11);
}

.review-card h2 {
  margin-bottom: 8px;
  font-size: 16px;
}

.review-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.review-head > div {
  flex: 1;
  min-width: 0;
}

.review-title-category {
  margin-top: 8px;
}

.review-readiness-checklist {
  display: grid;
  gap: 12px;
  margin: 0 0 16px;
  padding: 14px;
  border: 1px solid rgba(130, 181, 255, 0.34);
  border-radius: 10px;
  background: rgba(18, 40, 66, 0.72);
}

.review-readiness-checklist header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.review-readiness-checklist h2,
.review-readiness-checklist p {
  margin: 0;
}

.review-readiness-checklist p {
  margin-top: 4px;
  color: var(--muted);
}

.review-readiness-checklist ul {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.review-readiness-check {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  min-width: 0;
  padding: 10px;
  border: 1px solid rgba(130, 181, 255, 0.24);
  border-radius: 8px;
  background: rgba(8, 24, 39, 0.58);
}

.review-readiness-check.ready {
  border-left: 4px solid var(--green);
}

.review-readiness-check.attention {
  border-left: 4px solid var(--amber);
}

.review-readiness-icon {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  background: rgba(83, 209, 120, 0.16);
  color: var(--green);
  font-weight: 900;
}

.review-readiness-check.attention .review-readiness-icon {
  background: rgba(255, 211, 106, 0.16);
  color: #ffe09a;
}

.review-readiness-check > div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.review-readiness-check strong {
  color: var(--text);
}

.review-readiness-check > div span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.review-readiness-state {
  grid-column: 2;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.review-readiness-check.ready .review-readiness-state {
  color: var(--green);
}

.review-readiness-check.attention .review-readiness-state {
  color: #ffe09a;
}

.review-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.review-buyer-content {
  display: grid;
  gap: 14px;
  margin-bottom: 16px;
}

.review-buyer-detail-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.review-context-grid {
  grid-template-columns: minmax(0, 1fr);
  margin-top: 14px;
}

.review-workflow-context {
  margin-top: 4px;
}

.packet-readiness-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 10px;
  margin: 12px 0 16px;
}

.packet-readiness-card {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(130, 181, 255, 0.28);
  border-left: 4px solid rgba(142, 177, 215, 0.45);
  border-radius: 8px;
  background: rgba(18, 40, 66, 0.72);
}

.packet-readiness-card.good {
  border-left-color: var(--green);
}

.packet-readiness-card.warn {
  border-left-color: var(--amber);
}

.packet-readiness-card.info {
  border-left-color: var(--blue);
}

.packet-readiness-card header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.packet-readiness-card header strong,
.packet-readiness-card header span {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.packet-readiness-card header strong {
  color: #e8f3ff;
}

.packet-readiness-card header span,
.packet-readiness-card p {
  color: var(--muted);
}

.packet-readiness-card .pill {
  max-width: 100%;
  white-space: normal;
  text-align: right;
  overflow-wrap: anywhere;
}

.packet-readiness-card p {
  margin: 0;
}

.packet-readiness-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 7px;
}

.packet-readiness-metrics span {
  display: grid;
  gap: 2px;
  min-width: 0;
  padding: 7px 8px;
  border: 1px solid rgba(130, 181, 255, 0.2);
  border-radius: 8px;
  background: rgba(8, 24, 39, 0.58);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.packet-readiness-metrics strong {
  color: var(--text);
  font-size: 13px;
  text-transform: none;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.packet-readiness-metrics span:last-child {
  display: grid;
  align-items: center;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: 6px;
  grid-column: 1 / -1;
  min-height: 38px;
}

.packet-readiness-metrics .status-value {
  justify-self: start;
  max-width: none;
  overflow: visible;
  font-size: 12px;
  line-height: 1.2;
  text-align: left;
  white-space: normal;
  overflow-wrap: normal;
  word-break: normal;
}

.packet-readiness-metrics span:last-child .status-value {
  margin-top: 0;
}

.review-grid article {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(18, 40, 66, 0.68);
}

.review-detail-card {
  display: grid;
  align-content: start;
  gap: 8px;
}

.review-detail-head {
  display: grid;
  justify-items: start;
  gap: 6px;
}

.review-detail-head h2 {
  margin: 0;
}

.review-detail-head .mini-link {
  max-width: 100%;
  margin-top: 0;
  white-space: normal;
}

.inline-review-editor {
  width: 100%;
}

.inline-review-editor summary {
  cursor: pointer;
  list-style: none;
}

.inline-review-editor summary::-webkit-details-marker {
  display: none;
}

.inline-review-editor[open] {
  padding: 10px;
  border: 1px solid rgba(130, 181, 255, 0.28);
  border-radius: 8px;
  background: rgba(7, 19, 31, 0.38);
}

.inline-review-editor[open] summary {
  margin-bottom: 10px;
}

.inline-review-editor form {
  display: grid;
  gap: 10px;
}

.inline-review-form {
  display: grid;
  gap: 12px;
  margin-top: 6px;
}

.review-item-form {
  margin-top: 0;
}

.review-local-draft {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 14px;
  border: 1px solid rgba(130, 181, 255, 0.28);
  border-radius: 9px;
  background: rgba(12, 37, 62, 0.52);
}

.review-local-draft.has-device-draft {
  border-color: rgba(77, 219, 139, 0.55);
  background: rgba(34, 104, 75, 0.18);
}

.review-local-draft strong {
  display: block;
  color: var(--text);
}

.review-local-draft p,
.review-local-draft-actions span {
  margin: 3px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.review-local-draft-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px;
  text-align: right;
}

.inline-review-form input,
.inline-review-form textarea,
.inline-review-form select {
  width: 100%;
  min-width: 0;
  min-height: 32px;
  padding: 6px 9px;
  border: 1px solid rgba(130, 181, 255, 0.34);
  border-radius: 6px;
  background: rgba(12, 37, 62, 0.96);
  color: var(--text);
  font: inherit;
}

.inline-review-form textarea {
  min-height: 96px;
  resize: vertical;
}

.inline-review-form input::placeholder,
.inline-review-form textarea::placeholder {
  color: rgba(158, 177, 200, 0.72);
}

.inline-review-form input:focus,
.inline-review-form textarea:focus,
.inline-review-form select:focus {
  border-color: rgba(159, 199, 255, 0.82);
  box-shadow: 0 0 0 2px rgba(47, 130, 255, 0.22);
  outline: none;
}

.value-editor {
  display: grid;
  gap: 6px;
}

.title-editor {
  width: min(980px, 100%);
  max-width: 100%;
  margin-top: 10px;
}

.field-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.value-editor span,
.fixed-field span,
.shipping-edit-grid span,
.field-label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.fixed-field-list {
  display: grid;
  gap: 9px;
}

.review-subsection {
  display: grid;
  gap: 12px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(130, 181, 255, 0.18);
}

.review-subsection:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.review-subsection h3 {
  margin: 0;
  color: var(--gold);
  font-size: 14px;
}

.readonly-field {
  display: grid;
  gap: 4px;
  padding: 8px 9px;
  border: 1px solid rgba(130, 181, 255, 0.24);
  border-radius: 6px;
  background: rgba(7, 19, 31, 0.34);
}

.readonly-field span,
.readonly-field small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.readonly-field strong {
  color: var(--text);
}

.fixed-field {
  display: grid;
  grid-template-columns: minmax(78px, 0.38fr) minmax(0, 1fr);
  align-items: center;
  gap: 10px;
}

.review-pricing-editor {
  display: grid;
  gap: 9px;
}

.review-pricing-editor + .review-pricing-editor {
  margin-top: 4px;
}

.review-pricing-editor .pricing-field {
  display: grid;
  grid-template-columns: minmax(112px, 0.38fr) minmax(0, 1fr) !important;
  align-items: center;
  gap: 10px;
  margin: 0 !important;
}

.review-pricing-editor .pricing-field span {
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.review-pricing-editor .pricing-field + .pricing-field,
.review-pricing-editor .pricing-cost-grid + .pricing-field {
  margin-top: 0 !important;
}

.review-pricing-editor .pricing-field > input,
.review-pricing-editor .pricing-field > textarea,
.review-pricing-editor .pricing-field > select {
  display: block;
  width: 100%;
}

.review-detail-card .fixed-field-list .fixed-field {
  grid-template-columns: minmax(0, 1fr);
  align-items: stretch;
  gap: 6px;
}

.review-detail-card .fixed-field-list .fixed-field span {
  line-height: 1.25;
}

.fixed-field span small {
  display: block;
  margin-top: 2px;
  color: var(--green);
  font-size: 11px;
  font-weight: 800;
}

.specifics-profile {
  display: grid;
  gap: 5px;
  margin-bottom: 10px;
  padding: 10px;
  border: 1px solid rgba(130, 181, 255, 0.24);
  border-radius: 8px;
  background: rgba(7, 19, 31, 0.34);
}

.specifics-profile h3,
.specifics-profile p {
  margin: 0;
}

.specifics-profile h3 {
  color: var(--text);
  font-size: 15px;
}

.specifics-profile p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.specifics-profile .specifics-profile-kicker {
  color: var(--gold);
  font-size: 12px;
  font-weight: 900;
}

.specifics-profile .specifics-profile-status {
  color: var(--green);
  font-weight: 800;
}

.saved-specifics {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid rgba(130, 181, 255, 0.16);
  color: var(--muted);
}

.saved-specifics summary {
  color: var(--text);
  cursor: pointer;
  font-weight: 800;
}

.saved-specifics p {
  margin: 8px 0;
  font-size: 13px;
  line-height: 1.35;
}

.saved-specifics ul {
  display: grid;
  gap: 4px;
  margin: 0;
  padding-left: 18px;
  font-size: 13px;
}

.pricing-cost-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 9px;
}

@media (max-width: 520px) {
  .pricing-cost-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

.fixed-field.optional-field {
  opacity: 0.86;
}

.stacked-inputs {
  display: grid;
  gap: 8px;
}

.inline-subsection {
  display: grid;
  gap: 8px;
  padding-top: 8px;
  border-top: 1px solid rgba(130, 181, 255, 0.14);
}

.inline-subsection h3 {
  margin: 0;
  color: var(--text);
  font-size: 15px;
}

.helper-copy {
  margin: 0;
}

.shipping-edit-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.shipping-edit-grid label {
  display: grid;
  gap: 5px;
}

.carrier-choice-list {
  display: grid;
  gap: 7px;
}

.carrier-choice-list label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text);
}

.carrier-choice-list input {
  width: 14px;
  height: 14px;
  min-height: 14px;
  flex: 0 0 14px;
  padding: 0;
  border: 1px solid rgba(130, 181, 255, 0.58);
  border-radius: 3px;
  appearance: none;
  background: rgba(12, 37, 62, 0.96);
}

.carrier-choice-list input:checked {
  border-color: rgba(159, 199, 255, 0.9);
  background:
    linear-gradient(135deg, transparent 0 42%, #eef6ff 42% 56%, transparent 56%),
    linear-gradient(45deg, transparent 0 46%, #eef6ff 46% 60%, transparent 60%),
    var(--blue);
}

.carrier-choice-list label.is-disabled {
  color: rgba(158, 177, 200, 0.74);
}

.carrier-choice-list label.is-hidden {
  display: none;
}

.carrier-choice-list input:disabled {
  opacity: 0.82;
  cursor: not-allowed;
}

.shipping-exclusive-note {
  margin: 0;
}

.shipping-summary {
  margin: 0;
}

.review-head .inline-review-editor {
  max-width: 720px;
  margin-top: 10px;
}

.review-grid dl,
.review-grid ul {
  margin: 0;
}

.review-grid dt {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

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

.review-mini-lists {
  display: grid;
  gap: 10px;
}

.review-mini-lists h3 {
  margin: 0 0 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.review-mini-lists .small-list {
  display: grid;
  gap: 6px;
  padding-left: 18px;
}

@media (max-width: 760px) {
  .fixed-field {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .shipping-edit-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.review-description {
  max-height: 260px;
  overflow: auto;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #081827;
  color: var(--text);
  white-space: pre-wrap;
  font: inherit;
}

.review-description-editor {
  margin-top: 4px;
}

.review-description-input {
  min-height: 118px;
}

.decision-form {
  display: flex;
  align-items: end;
  gap: 12px;
  margin-top: 12px;
}

.decision-form label {
  display: grid;
  gap: 7px;
  color: var(--muted);
}

.decision-form .grow {
  flex: 1;
}

.decision-form select,
.decision-form textarea {
  min-height: 42px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(12, 37, 62, 0.96);
  color: var(--text);
  font: inherit;
}

.decision-form textarea {
  min-height: 64px;
  padding-top: 10px;
}

.reminder-list {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.reminder-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-2);
}

.reminder-row > div:first-child {
  min-width: 0;
}

.reminder-row.overdue {
  border-color: rgba(255, 94, 117, 0.72);
  background: rgba(255, 94, 117, 0.16);
  box-shadow: inset 3px 0 0 rgba(255, 94, 117, 0.88);
}

.reminder-row.overdue strong {
  color: #ffd2d8;
}

.reminder-row.overdue span {
  color: #ff9eac;
}

.reminder-row.done {
  opacity: 0.82;
}

.reminder-row.done strong {
  text-decoration: line-through;
  text-decoration-thickness: 2px;
}

.reminder-row.archived,
.reminder-row.archived-empty {
  border-style: dashed;
  background: rgba(18, 40, 66, 0.32);
  opacity: 0.88;
}

.reminder-row strong,
.reminder-row span {
  display: block;
}

.reminder-row span {
  margin-top: 3px;
  color: var(--muted);
}

.reminder-actions {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 7px;
}

.reminder-actions form {
  margin: 0;
}

.reminder-archive-block {
  display: grid;
  gap: 10px;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid rgba(36, 64, 95, 0.9);
}

.archive-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.archive-heading h3 {
  margin: 0;
  font-size: 18px;
}

.archive-heading h1 {
  margin: 0;
}

.archive-heading p {
  margin: 4px 0 0;
  color: var(--muted);
}

.history-panel .archive-heading {
  margin-bottom: 14px;
}

.archive-controls {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin: 0 0 14px;
}

.archive-controls label,
.archive-custom-range label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 150px;
  margin: 0;
  font-weight: 800;
}

.archive-controls select,
.archive-controls input {
  min-width: 0;
  min-height: 42px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #081827;
  color: var(--text);
  font: inherit;
}

.archive-controls .archive-control-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  margin: 0;
  padding: 0 14px;
  font: inherit;
  font-weight: 900;
  line-height: 1;
}

.archive-custom-range {
  display: contents;
}

.archive-custom-range.is-hidden {
  display: none;
}

.archived-list {
  margin-top: 0;
}

.archive-details {
  border: 1px solid rgba(130, 181, 255, 0.24);
  border-radius: 8px;
  background: rgba(8, 24, 39, 0.34);
}

.archive-details + .archive-details {
  margin-top: 10px;
}

.archive-details > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  cursor: pointer;
  list-style: none;
  color: var(--text);
  font-weight: 900;
}

.archive-details > summary::-webkit-details-marker {
  display: none;
}

.archive-details > p,
.archive-details > table,
.archive-details > .archived-list {
  margin: 0 14px 14px;
}

.history-empty {
  border: 1px dashed rgba(130, 181, 255, 0.28);
  border-radius: 8px;
  color: var(--muted);
  padding: 14px;
}

.table-sort-link {
  color: var(--muted);
  text-decoration: none;
}

.table-sort-link:hover,
.table-sort-link:focus-visible {
  color: var(--text);
}

.table-sort-button {
  align-items: center;
  appearance: none;
  background: transparent !important;
  background-color: transparent !important;
  border: 0 !important;
  border-radius: 0;
  box-shadow: none !important;
  color: inherit;
  cursor: pointer;
  display: inline-flex;
  filter: none !important;
  font: inherit;
  font-weight: 800;
  font-size: inherit;
  gap: 4px;
  letter-spacing: 0;
  line-height: inherit;
  max-width: none;
  min-height: 0;
  min-width: 0;
  padding: 0;
  text-align: left;
  text-transform: none;
  width: auto;
}

.table-sort-button::after {
  content: none !important;
  display: none !important;
}

.table-sort-button .sort-label {
  display: inline;
  text-transform: none;
}

.table-sort-button:hover,
.table-sort-button:focus-visible {
  color: var(--text);
  outline: none;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.sort-indicator {
  display: inline-block;
  font-size: 11px;
  line-height: 1;
  min-width: 10px;
  opacity: 0;
}

.table-sort-button[data-sort-direction="asc"] .sort-indicator::after {
  content: "↑";
}

.table-sort-button[data-sort-direction="desc"] .sort-indicator::after {
  content: "↓";
}

.table-sort-button[data-sort-direction] .sort-indicator {
  opacity: 0.9;
}

.metric.metric-link {
  color: inherit;
  cursor: pointer;
  display: block;
  text-decoration: none;
}

.metric.metric-link:hover,
.metric.metric-link:focus-visible {
  background: rgba(32, 64, 104, 0.32);
  border-color: rgba(130, 181, 255, 0.68);
  outline: none;
}

.metric.metric-attention {
  background: linear-gradient(135deg, rgba(250, 204, 21, 0.14), rgba(24, 40, 64, 0.72));
  border-color: rgba(250, 204, 21, 0.72);
}

.metric.metric-attention strong {
  color: #fde68a;
}

.metric-value-positive {
  color: #86efac;
}

.metric-detail {
  color: var(--muted);
  display: block;
  font-size: 0.88rem;
  line-height: 1.35;
  margin-top: 8px;
}

.danger-action {
  border-color: rgba(255, 104, 104, 0.5);
  color: #ffd0d0;
  background: rgba(120, 28, 42, 0.22);
}

.danger-action:hover {
  border-color: rgba(255, 104, 104, 0.78);
  background: rgba(120, 28, 42, 0.34);
}

@media (max-width: 720px) {
  .reminder-row {
    align-items: stretch;
    flex-direction: column;
  }

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

.security-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
}

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

.stacked-form label {
  display: grid;
  gap: 7px;
  color: var(--muted);
}

.stacked-form input {
  width: 100%;
  min-height: 42px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #081827;
  color: var(--text);
  font: inherit;
}

.notice.success {
  border-color: rgba(73, 197, 130, 0.45);
  background: rgba(73, 197, 130, 0.12);
  color: var(--text);
}

.notice.error {
  border-color: rgba(255, 105, 105, 0.55);
  background: rgba(255, 105, 105, 0.1);
  color: var(--text);
}

@media (max-width: 860px) {
  .shell {
    grid-template-columns: 1fr;
  }

  .side {
    position: sticky;
    top: 0;
    z-index: 50;
    gap: 10px;
    padding: 10px 12px;
    border-right: 0;
    border-bottom: 1px solid rgba(130, 181, 255, 0.24);
    box-shadow: 0 14px 30px rgba(0, 0, 0, 0.34);
  }

  .side-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
  }

  .brand {
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr);
    column-gap: 10px;
    align-items: center;
    min-width: 0;
  }

  .brand img {
    grid-row: span 2;
    width: 48px;
    margin: 0;
  }

  .brand strong {
    align-self: end;
    font-size: 18px;
    line-height: 1.1;
  }

  .brand em {
    align-self: start;
    overflow: hidden;
    font-size: 12px;
    line-height: 1.15;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .mobile-nav-toggle {
    display: inline-flex;
    min-height: 44px;
    flex: 0 0 auto;
    align-items: center;
    gap: 8px;
    padding: 9px 12px;
    border: 1px solid rgba(130, 181, 255, 0.38);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(47, 130, 255, 0.28), rgba(47, 130, 255, 0.14));
    color: var(--text);
    font: inherit;
    font-weight: 800;
    cursor: pointer;
  }

  .mobile-nav-toggle:hover,
  .mobile-nav-toggle:focus-visible {
    border-color: rgba(159, 199, 255, 0.78);
    outline: 2px solid rgba(47, 130, 255, 0.52);
    outline-offset: 2px;
  }

  .mobile-nav-state {
    color: var(--accent-soft);
    font-size: 11px;
    font-weight: 700;
  }

  .side-drawer {
    display: none;
    max-height: calc(100dvh - 72px);
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 4px 2px 10px;
    scrollbar-gutter: stable;
  }

  .side.is-nav-open .side-drawer {
    display: grid;
    gap: 14px;
  }

  .side.is-nav-open .mobile-nav-toggle {
    background: rgba(47, 130, 255, 0.24);
  }

  .user-box {
    margin-top: 0;
  }

  .side-tools {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .dashboard-main {
    display: flex;
    flex-direction: column;
  }

  .dashboard-main > * {
    order: 6;
  }

  .dashboard-main > .next-step-panel {
    order: 1;
  }

  .dashboard-main > #mission-board {
    order: 2;
  }

  .dashboard-main > #dashboard {
    order: 3;
  }

  .dashboard-main > .top {
    order: 4;
  }

  .dashboard-main > .help-strip {
    order: 5;
  }

  .panel {
    overflow-x: hidden;
  }

  nav,
  .metric-grid,
  .health-check-grid,
  .dashboard-command-grid,
  .dashboard-board,
  .summary-strip,
  .intake-form,
  .wizard-fields,
  .mission-grid,
  .security-grid,
  .review-grid {
    grid-template-columns: 1fr 1fr;
  }

  .review-readiness-checklist ul {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .decision-form {
    display: grid;
  }

  .top,
  .panel-heading,
  .next-step-panel,
  .help-strip,
  .help-start {
    align-items: stretch;
    flex-direction: column;
  }

  .button-row {
    justify-content: flex-start;
  }

  table {
    display: block;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .review-file-card {
    grid-template-columns: 96px minmax(0, 1fr);
  }

  .review-file-card .file-actions {
    grid-column: 1 / -1;
  }

  .selected-file-preview {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dashboard-board {
    grid-column: 1 / -1;
  }

  .dashboard-side-rail {
    grid-column: 1 / -1;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .optimization-focus-grid,
  .optimization-focus-body {
    grid-template-columns: 1fr 1fr;
  }

  .progress-steps {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .item-progress-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .listing-wizard-steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .listing-wizard-steps li:last-child {
    grid-column: 1 / -1;
  }
}

@media (max-width: 560px) {
  .main {
    padding: 12px;
  }

  .brand {
    grid-template-columns: 44px minmax(0, 1fr);
  }

  .brand img {
    width: 44px;
  }

  nav,
  .metric-grid,
  .health-check-grid,
  .dashboard-command-grid,
  .dashboard-board,
  .dashboard-side-rail,
  .summary-strip,
  .intake-form,
  .wizard-fields,
    .mission-grid,
    .security-grid,
    .review-grid,
    .review-readiness-checklist ul,
    .help-index,
    .optimization-focus-grid,
    .optimization-focus-body {
    grid-template-columns: 1fr;
  }

  nav {
    grid-template-columns: 1fr 1fr;
  }

  .side-tools {
    grid-template-columns: 1fr;
  }

  nav a {
    padding: 10px 12px;
  }

  .review-file-card {
    grid-template-columns: 1fr;
  }

  .review-file-media {
    justify-items: start;
  }

  .file-actions,
  .prep-group,
  .file-review-form {
    min-width: 0;
    max-width: 100%;
  }

  .board-column {
    min-height: auto;
  }

  .summary-strip strong {
    font-size: 19px;
  }

  .item-progress-card header {
    align-items: stretch;
    flex-direction: column;
  }

  .item-progress-meta {
    grid-template-columns: 1fr;
  }

  .item-primary-action {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .item-primary-action .primary-action {
    width: 100%;
  }

  .progress-steps {
    grid-template-columns: 1fr;
  }

  .review-local-draft {
    align-items: stretch;
    flex-direction: column;
  }

  .review-local-draft-actions {
    align-items: flex-start;
    justify-content: flex-start;
    text-align: left;
  }
}

@media (max-width: 1320px) {
  .dashboard-command-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .dashboard-board {
    grid-template-columns: repeat(5, minmax(220px, 1fr));
    overflow-x: auto;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
  }

  .dashboard-side-rail {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .dashboard-command-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .dashboard-board {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    overflow-x: visible;
  }

  .dashboard-side-rail,
  .summary-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .dashboard-board,
  .dashboard-side-rail,
  .summary-strip {
    grid-template-columns: minmax(0, 1fr);
  }

  .board-item-top {
    grid-template-columns: 58px minmax(0, 1fr);
  }

  .board-thumb {
    width: 58px;
    height: 58px;
  }
}
