html.command-theme {
  color-scheme: dark;
  --ink: var(--c-cream);
  --muted: var(--c-muted);
  --line: var(--c-hairline);
  --paper: var(--c-bg);
  --surface: var(--c-surface);
  --sage: var(--c-copper);
  --sage-dark: var(--c-copper);
  --clay: var(--c-copper);
  --gold: var(--c-copper);
  --sky: var(--c-surface-2);
  --rose: var(--c-surface-2);
  --shadow: 0 22px 70px rgba(0, 0, 0, 0.34);
}

html.command-theme body {
  background: var(--paper);
  color: var(--ink);
}

html.command-theme main {
  width: min(1600px, 100%);
  padding: 26px;
  gap: 18px;
}

html.command-theme .topbar {
  align-items: start;
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--c-surface);
}

html.command-theme .brand-mark {
  background: var(--c-surface-2);
  color: var(--c-copper);
}

html.command-theme .brand h1,
html.command-theme .mission-strip h2,
html.command-theme .section-heading h2,
html.command-theme .panel-head h2 {
  color: var(--ink);
  letter-spacing: 0;
}

html.command-theme .brand h1 {
  font-size: clamp(2rem, 4vw, 3.8rem);
  line-height: 0.98;
}

html.command-theme .eyebrow {
  color: var(--c-copper);
  letter-spacing: 0.18em;
  font-family: var(--c-mono);
  text-transform: uppercase;
}

html.command-theme .mission-strip,
html.command-theme .panel,
html.command-theme .map-workspace,
html.command-theme .hero-panel,
html.command-theme .map-guided {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: none;
}

html.command-theme .mission-strip {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  padding: 20px;
  background: var(--c-surface-2);
}

html.command-theme .mission-strip p:last-child {
  color: var(--muted);
}

html.command-theme .primary-button,
html.command-theme .secondary-button,
html.command-theme .icon-button,
html.command-theme .text-button,
html.command-theme .advisor-actions button,
html.command-theme .priority-actions button,
html.command-theme .card-actions button,
html.command-theme .secondary-link {
  border-color: var(--c-hairline-strong);
  border-radius: var(--radius-xs);
}

html.command-theme .primary-button,
html.command-theme .icon-button {
  background: var(--c-copper);
  color: var(--c-copper-ink);
}

html.command-theme .secondary-button,
html.command-theme .advisor-actions button,
html.command-theme .priority-actions button,
html.command-theme .card-actions button,
html.command-theme .secondary-link {
  background: var(--c-surface-2);
  color: var(--ink);
}

html.command-theme .text-button {
  color: var(--c-copper);
}

html.command-theme .week-pill,
html.command-theme .tag,
html.command-theme .suggested-time {
  border-color: var(--c-hairline-strong);
  background: var(--c-surface-2);
  color: var(--c-copper);
}

html.command-theme .content-grid {
  grid-template-columns: minmax(300px, 0.42fr) minmax(0, 1fr);
}

html.command-theme .panel {
  padding: 18px;
}

html.command-theme .advisor-message {
  min-height: 180px;
  border: 1px solid var(--c-hairline-strong);
  background: var(--c-surface-2);
  color: var(--ink);
  font-size: 1.16rem;
}

html.command-theme .advisor-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

html.command-theme .chat-thread,
html.command-theme .calendar-grid,
html.command-theme .google-link-list {
  border-color: var(--line);
  background: var(--c-bg-deep);
}

html.command-theme input,
html.command-theme textarea,
html.command-theme select {
  border-color: var(--c-hairline-strong);
  background: var(--c-fill-soft);
  color: var(--ink);
}

html.command-theme input::placeholder,
html.command-theme textarea::placeholder {
  color: var(--c-muted-3);
}

html.command-theme .map-workspace {
  padding: 20px;
}

html.command-theme .map-guided {
  background: var(--c-surface-2);
}

html.command-theme .map-dump-voice,
html.command-theme .dictation-panel {
  border-color: var(--c-hairline-strong);
  background: var(--c-surface);
}

html.command-theme .dump-dictate-button,
html.command-theme .dictate-button {
  border-color: var(--c-copper);
  background: var(--c-fill-soft);
  color: var(--c-copper);
}

html.command-theme .dump-dictate-button.recording,
html.command-theme .dictate-button.recording {
  background: var(--c-copper);
  color: var(--c-copper-ink);
}

html.command-theme .map-sheet {
  gap: 12px;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

html.command-theme .map-branch {
  grid-template-columns: minmax(180px, 0.24fr) minmax(0, 1fr);
  gap: 14px;
  padding: 14px;
  border: 1px solid var(--c-hairline);
  border-radius: var(--radius);
  background: var(--c-bg-deep);
}

html.command-theme .map-branch:not(:last-child) {
  border-bottom: 1px solid var(--c-hairline);
}

html.command-theme .map-branch-title::after,
html.command-theme .map-stone-list::before,
html.command-theme .map-stone::before {
  display: none;
}

html.command-theme .map-branch-title h3 {
  color: var(--ink);
}

html.command-theme .map-stone-list {
  gap: 8px;
  padding: 0;
}

html.command-theme .map-stone {
  grid-template-columns: minmax(0, 1fr) 108px auto;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid var(--c-hairline-strong);
  border-radius: var(--radius);
  background: var(--c-surface);
}

html.command-theme .map-stone h4,
html.command-theme .priority-card h3,
html.command-theme .suggestion-card h3,
html.command-theme .approval-card h3 {
  color: var(--ink);
}

html.command-theme .map-action-explain {
  background: var(--c-surface-2) !important;
  color: var(--c-copper) !important;
  border-color: var(--c-hairline-strong) !important;
}

html.command-theme .map-stone-actions button,
html.command-theme .map-add-link {
  border-color: var(--c-hairline-strong);
  background: var(--c-surface-2);
  color: var(--c-cream);
}

html.command-theme .map-action-schedule {
  background: var(--c-copper) !important;
  border-color: var(--c-copper) !important;
  color: var(--c-copper-ink) !important;
}

html.command-theme .map-action-google {
  background: var(--c-surface-2) !important;
  border-color: var(--c-copper) !important;
  color: var(--c-copper) !important;
}

html.command-theme .map-action-delete {
  background: var(--c-surface-2) !important;
  border-color: var(--c-hairline-strong) !important;
  color: var(--c-muted) !important;
}

html.command-theme .stone-actions .primary-button,
html.command-theme .stone-actions .secondary-button,
html.command-theme .stone-actions .text-button {
  background: var(--c-surface-2);
  border-color: var(--c-hairline-strong);
  color: var(--c-cream);
}

html.command-theme .stone-actions .primary-button {
  background: var(--c-copper);
  border-color: var(--c-copper);
  color: var(--c-copper-ink);
}

html.command-theme .priority-card,
html.command-theme .suggestion-card,
html.command-theme .approval-card,
html.command-theme .dump-result-card,
html.command-theme .google-link-card,
html.command-theme .prayer-point-card,
html.command-theme .explain-result > div,
html.command-theme .guided-proposal {
  border-color: var(--c-hairline-strong);
  background: var(--c-surface);
  color: var(--ink);
}

html.command-theme .dump-result-column h4,
html.command-theme .dump-result-card h5,
html.command-theme .guided-proposal h3 {
  color: var(--ink);
}

html.command-theme .empty-state {
  border-color: var(--c-hairline-strong);
  background: var(--c-bg-deep);
  color: var(--muted);
}

html.command-theme dialog {
  border-color: var(--line);
  background: var(--surface);
  color: var(--ink);
}

html.command-theme dialog::backdrop {
  background: rgba(0, 0, 0, 0.62);
}

html.command-theme .explain-card,
html.command-theme .google-card {
  color: var(--ink);
}

html.command-theme .chat-bubble {
  border: 1px solid var(--c-hairline-strong);
  background: var(--c-surface);
}

html.command-theme .chat-bubble.user {
  background: var(--c-surface-2);
}

html.command-theme .chat-bubble p,
html.command-theme .stewardship-card p,
html.command-theme .priority-card p,
html.command-theme .suggestion-card p,
html.command-theme .approval-card p,
html.command-theme .map-guided p,
html.command-theme .dictation-panel p,
html.command-theme .explain-result p,
html.command-theme .guided-proposal p,
html.command-theme .prayer-point-card p,
html.command-theme .prayer-point-card small,
html.command-theme .dump-result-card p,
html.command-theme .dump-result-card small {
  color: var(--muted);
}

@media (max-width: 980px) {
  html.command-theme .content-grid,
  html.command-theme .mission-strip,
  html.command-theme .map-branch,
  html.command-theme .advisor-actions {
    grid-template-columns: 1fr;
  }
}
