/* ================================================================
   MUSE ROOM — Five-section owner-input page
   Scoped to .page-muse, prefixed muse-
   ================================================================ */

/* ── Metadata strip ─────────────────────────────────────────── */
.muse-meta {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ivory-faint);
  letter-spacing: 0.5px;
  padding: 0 0 28px;
}

/* ── Section stack ─────────────────────────────────────────── */
.muse-sections {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* ── Panel (shared for all five sections) ──────────────────── */
.muse-panel {
  background: var(--navy-2);
  border: 1px solid var(--ivory-faint);
  border-radius: 4px;
  padding: 32px;
}
.muse-panel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 0;
}
.muse-panel-eyebrow {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 2px;
}
.muse-panel-title {
  font-family: var(--serif);
  font-size: 28px;
  color: var(--ivory);
  font-weight: 400;
  margin: 0 0 4px;
}
.muse-panel-title em {
  font-style: italic;
}
.muse-panel-sub {
  font-family: var(--sans);
  font-size: 13px;
  font-style: italic;
  color: var(--ivory-soft);
  margin-bottom: 24px;
}

/* ── Accordion collapsible panels ─────────────────────────── */
.muse-panel-collapsible {
  padding-top: 0;
  padding-bottom: 0;
  overflow: hidden;
  transition: border-color 0.2s ease;
}
.muse-panel-collapsible:hover { border-color: rgba(226,198,141,0.16); }
.muse-panel-collapsible[data-open="true"] {
  border-color: var(--gold-faint);
}
.muse-panel-collapsible .muse-panel-header {
  padding: 24px 0;
  margin: 0 32px;
  cursor: pointer;
  user-select: none;
  margin-bottom: 0;
  outline: none;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}
.muse-panel-collapsible .muse-panel-header:focus-visible {
  box-shadow: inset 0 0 0 1px var(--gold-faint);
  border-radius: 2px;
}
.muse-panel-header-text { flex: 1; min-width: 0; }
.muse-panel-header-right {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
}
.muse-panel-chevron {
  color: var(--ivory-soft);
  transition: transform 0.25s ease;
  margin-top: 6px;
}
.muse-panel-collapsible[data-open="true"] .muse-panel-chevron {
  transform: rotate(180deg);
  color: var(--gold);
}
.muse-panel-body {
  padding: 0 32px 32px;
}
.muse-panel-body[hidden] {
  display: none !important;
}

/* ── Status pills ─────────────────────────────────────────── */
.muse-pill {
  display: inline-block;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  padding: 4px 8px;
  border-radius: 10px;
  white-space: nowrap;
  margin-top: 6px;
  transition: background 0.3s, border-color 0.3s, color 0.3s;
}
.muse-pill-empty {
  background: transparent;
  border: 1px solid var(--ivory-faint);
  color: var(--ivory-faint);
}
.muse-pill-saving {
  background: var(--gold-faint);
  border: 1px solid var(--gold-faint);
  color: var(--gold);
}
.muse-pill-saved {
  background: transparent;
  border: 1px solid var(--gold-faint);
  color: var(--gold-soft);
}

/* ── SECTION 1: Vision (edit-in-place) ────────────────────── */
.muse-vision-empty {
  text-align: center;
  padding: 48px 0;
}
.muse-vision-empty-text {
  font-family: var(--serif);
  font-style: italic;
  font-size: 16px;
  color: var(--ivory-faint);
  margin-bottom: 16px;
}
.muse-vision-view {
  position: relative;
}
.muse-vision-prose {
  font-family: var(--body);
  font-size: 18px;
  line-height: 1.75;
  color: var(--ivory);
  white-space: pre-wrap;
}
.muse-vision-prose::first-letter {
  font-family: var(--serif);
  font-size: 60px;
  float: left;
  line-height: 0.8;
  padding-right: 8px;
  padding-top: 6px;
  color: var(--gold);
}
.muse-vision-edit-btn {
  position: absolute;
  top: 0;
  right: 0;
}
.muse-vision-textarea {
  width: 100%;
  min-height: 240px;
  background: var(--navy);
  border: none;
  border-radius: 4px;
  padding: 20px;
  font-family: var(--body);
  font-size: 18px;
  line-height: 1.75;
  color: var(--ivory);
  resize: vertical;
  outline: none;
}
.muse-vision-textarea:focus {
  box-shadow: 0 0 0 1px var(--ivory-faint);
}
.muse-vision-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 12px;
}
.muse-vision-wc {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ivory-faint);
}
.muse-vision-actions {
  display: flex;
  gap: 8px;
}

/* ── SECTION 2: Vibe (chip inputs) ────────────────────────── */
.muse-vibe-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}
@media (max-width: 900px) {
  .muse-vibe-grid { grid-template-columns: 1fr; }
}
.muse-vibe-block {}
.muse-vibe-label {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--ivory-faint);
  margin-bottom: 12px;
}
.muse-chip-area {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
  min-height: 36px;
}
.muse-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--gold-faint);
  color: var(--ivory);
  font-family: var(--sans);
  font-size: 13px;
  padding: 5px 12px;
  border-radius: 20px;
  border: none;
  white-space: nowrap;
}
.muse-chip-x {
  cursor: pointer;
  opacity: 0;
  font-size: 11px;
  color: var(--ivory-soft);
  transition: opacity 0.15s;
  background: none;
  border: none;
  padding: 0;
  line-height: 1;
}
.muse-chip:hover .muse-chip-x {
  opacity: 1;
}
.muse-chip-ghost {
  background: none;
  border: 1px dashed rgba(245,239,224,0.12);
  color: var(--ivory-faint);
  font-style: italic;
  opacity: 0.3;
}
.muse-chip-input {
  width: 100%;
  background: var(--navy);
  border: 1px solid var(--ivory-faint);
  border-radius: 4px;
  padding: 8px 12px;
  font-family: var(--sans);
  font-size: 13px;
  color: var(--ivory);
  outline: none;
}
.muse-chip-input:focus {
  border-color: var(--gold-faint);
}
.muse-chip-input::placeholder {
  color: var(--ivory-faint);
  font-style: italic;
}
.muse-chip-input:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.muse-chip-helper {
  font-family: var(--sans);
  font-size: 11px;
  color: var(--ivory-faint);
  margin-top: 4px;
}

/* ── SECTION 3: Palette ───────────────────────────────────── */
.muse-palette-modes {
  display: flex;
  flex-direction: column;
  gap: 28px;
  margin-bottom: 28px;
}
.muse-palette-label {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--ivory-faint);
  margin-bottom: 12px;
}
/* Curated row */
.muse-curated-row {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding-bottom: 4px;
  scrollbar-width: thin;
  scrollbar-color: var(--ivory-faint) transparent;
}
.muse-curated-card {
  flex-shrink: 0;
  background: var(--navy);
  border: 1px solid var(--ivory-faint);
  border-radius: 4px;
  padding: 12px;
  cursor: pointer;
  transition: border-color 0.2s;
  text-align: center;
}
.muse-curated-card:hover {
  border-color: var(--gold-faint);
}
.muse-curated-card.active {
  border: 2px solid var(--gold);
}
.muse-curated-strip {
  display: flex;
}
.muse-curated-sq {
  width: 32px;
  height: 32px;
}
.muse-curated-name {
  font-family: var(--serif);
  font-style: italic;
  font-size: 13px;
  color: var(--ivory);
  margin-top: 8px;
  white-space: nowrap;
}
/* Build your own */
.muse-swatch-row {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding-bottom: 4px;
}
.muse-swatch-builder {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}
.muse-swatch-preview {
  width: 48px;
  height: 48px;
  border-radius: 3px;
  cursor: pointer;
  border: 1px solid var(--ivory-faint);
  position: relative;
}
.muse-swatch-picker {
  position: absolute;
  inset: 0;
  opacity: 0;
  width: 100%;
  height: 100%;
  cursor: pointer;
  border: none;
}
.muse-swatch-hex {
  width: 72px;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ivory);
  background: var(--navy);
  border: 1px solid var(--ivory-faint);
  border-radius: 3px;
  padding: 3px 6px;
  text-align: center;
  outline: none;
}
.muse-swatch-hex.invalid {
  border-bottom: 2px solid #c44;
}
.muse-swatch-hex:focus {
  border-color: var(--gold-faint);
}
.muse-swatch-role {
  font-family: var(--sans);
  font-size: 11px;
  color: var(--ivory);
  background: var(--navy);
  border: 1px solid var(--ivory-faint);
  border-radius: 3px;
  padding: 3px 4px;
  outline: none;
  cursor: pointer;
}
.muse-swatch-name {
  width: 90px;
  font-family: var(--sans);
  font-size: 11px;
  color: var(--ivory);
  background: var(--navy);
  border: 1px solid var(--ivory-faint);
  border-radius: 3px;
  padding: 3px 6px;
  text-align: center;
  outline: none;
}
.muse-swatch-name::placeholder {
  font-style: italic;
  color: var(--ivory-faint);
}
/* Extract from image */
.muse-extract-zone {
  width: 100%;
  height: 80px;
  border: 1px dashed var(--gold-faint);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  font-family: var(--sans);
  font-size: 13px;
  color: var(--ivory-faint);
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
}
.muse-extract-zone:hover,
.muse-extract-zone.dragover {
  border-style: solid;
  border-color: var(--gold);
  color: var(--gold);
}
.muse-extract-preview {
  width: 80px;
  height: 80px;
  border-radius: 4px;
  object-fit: cover;
  flex-shrink: 0;
}
.muse-extract-row {
  display: flex;
  gap: 12px;
  align-items: center;
}
.muse-extract-clear {
  background: none;
  border: 1px solid var(--ivory-faint);
  color: var(--ivory-faint);
  font-family: var(--mono);
  font-size: 10px;
  padding: 2px 8px;
  border-radius: 3px;
  cursor: pointer;
}
.muse-extract-clear:hover {
  border-color: var(--gold);
  color: var(--ivory);
}
/* Active palette */
.muse-active-label {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 12px;
}
.muse-active-row {
  display: flex;
}
.muse-active-swatch {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
}
.muse-active-color {
  width: 100%;
  height: 80px;
}
.muse-active-swatch:first-child .muse-active-color {
  border-radius: 4px 0 0 4px;
}
.muse-active-swatch:last-child .muse-active-color {
  border-radius: 0 4px 4px 0;
}
.muse-active-hex {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ivory);
  margin-top: 6px;
}
.muse-active-role {
  font-family: var(--sans);
  font-style: italic;
  font-size: 11px;
  color: var(--ivory-soft);
}
.muse-active-name {
  font-family: var(--serif);
  font-style: italic;
  font-size: 12px;
  color: var(--ivory);
  margin-top: 2px;
}
.muse-active-empty {
  display: flex;
  height: 80px;
  border: 1px dashed var(--ivory-faint);
  border-radius: 4px;
  align-items: center;
  justify-content: center;
  font-family: var(--serif);
  font-style: italic;
  font-size: 13px;
  color: var(--ivory-faint);
}

/* ── SECTION 4: References (inspiration pins) ─────────────── */
.muse-insp-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.muse-insp-tile {
  position: relative;
  aspect-ratio: 1;
  background: var(--navy);
  border: 1px solid rgba(226,198,141,0.08);
  border-radius: 3px;
  overflow: hidden;
  cursor: default;
  transition: border-color 0.2s;
}
.muse-insp-tile:hover {
  border: 1px dashed var(--gold);
}
.muse-insp-tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.muse-insp-tile-prompt {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--serif);
  font-style: italic;
  font-size: 14px;
  color: var(--ivory-faint);
}
.muse-insp-tile-hover {
  position: absolute;
  bottom: 4px;
  right: 6px;
  font-family: var(--mono);
  font-size: 10px;
  color: var(--ivory-faint);
  opacity: 0;
  transition: opacity 0.2s;
}
.muse-insp-tile:hover .muse-insp-tile-hover {
  opacity: 1;
}
.muse-insp-tile-drop {
  border: 1px dashed var(--gold-faint);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--gold-faint);
}
.muse-insp-tile-drop:hover {
  border-color: var(--gold);
  color: var(--gold);
}
.muse-insp-tile.muse-dragover {
  border: 2px solid var(--gold);
  box-shadow: inset 0 0 16px rgba(226,198,141,0.12);
}
.muse-insp-reset {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(11,15,44,0.7);
  border: 1px solid rgba(226,198,141,0.3);
  color: var(--ivory-soft);
  font-size: 11px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.2s;
  z-index: 2;
}
.muse-insp-tile:hover .muse-insp-reset {
  opacity: 1;
}
.muse-insp-reset:hover {
  background: rgba(11,15,44,0.9);
  border-color: var(--gold);
  color: var(--gold);
}
.muse-insp-clear {
  margin-top: 12px;
  font-family: var(--sans);
  font-size: 12px;
  background: none;
  color: var(--ivory-faint);
  border: 1px solid rgba(226,198,141,0.12);
  border-radius: 4px;
  padding: 5px 14px;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
}
.muse-insp-clear:hover {
  border-color: var(--gold);
  color: var(--ivory);
}

/* ── SECTION 5: To Feature (edit-in-place lists) ──────────── */
.muse-feature-label {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--ivory-faint);
  margin-bottom: 12px;
}
.muse-feature-empty {
  font-family: var(--serif);
  font-style: italic;
  font-size: 14px;
  color: var(--ivory-faint);
  padding: 16px 0;
}
.muse-feature-list {
  list-style: none;
  padding: 0;
  margin: 0 0 12px;
}
.muse-feature-row {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding: 6px 0;
  border-bottom: 1px solid rgba(226,198,141,0.05);
}
.muse-feature-bullet {
  width: 6px;
  height: 6px;
  background: var(--gold);
  flex-shrink: 0;
  margin-top: 5px;
}
.muse-feature-name {
  font-family: var(--serif);
  font-size: 16px;
  color: var(--ivory);
}
.muse-feature-note {
  font-family: var(--sans);
  font-size: 12px;
  font-style: italic;
  color: var(--ivory-soft);
  margin-left: auto;
  flex-shrink: 0;
}
.muse-feature-edit-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}
.muse-feature-input {
  flex: 1;
  background: var(--navy);
  border: 1px solid var(--ivory-faint);
  border-radius: 3px;
  padding: 6px 10px;
  font-family: var(--sans);
  font-size: 13px;
  color: var(--ivory);
  outline: none;
}
.muse-feature-input:focus {
  border-color: var(--gold-faint);
}
.muse-feature-input::placeholder {
  color: var(--ivory-faint);
  font-style: italic;
}
.muse-feature-input-note {
  width: 140px;
  flex-shrink: 0;
}
.muse-feature-remove {
  background: none;
  border: none;
  color: var(--ivory-faint);
  cursor: pointer;
  font-size: 14px;
  padding: 0 4px;
}
.muse-feature-remove:hover {
  color: var(--gold);
}
.muse-feature-divider {
  border: none;
  border-top: 1px solid var(--gold-faint);
  margin: 24px 0;
}

/* ── Hero product picker (combobox) ──────────────────────── */
.muse-hero-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
  min-height: 0;
}
.muse-hero-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--gold-faint);
  border-radius: 20px;
  padding: 4px 12px 4px 4px;
  max-width: 320px;
}
.muse-hero-chip-thumb {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  background: var(--navy);
}
.muse-hero-chip-name {
  font-family: var(--sans);
  font-size: 13px;
  color: var(--ivory);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.muse-hero-chip-x {
  background: none;
  border: none;
  color: var(--ivory-soft);
  cursor: pointer;
  font-size: 14px;
  padding: 0 2px;
  line-height: 1;
  opacity: 0;
  transition: opacity 0.15s;
}
.muse-hero-chip:hover .muse-hero-chip-x { opacity: 1; }
.muse-hero-chip-legacy {
  border: 1px dashed var(--gold-deep);
}
.muse-hero-chip-legacy .muse-hero-chip-name::after {
  content: ' (reselect)';
  font-size: 10px;
  color: var(--gold-deep);
}
.muse-hero-note-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}
.muse-hero-note-label {
  font-family: var(--sans);
  font-size: 12px;
  color: var(--ivory-soft);
  white-space: nowrap;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 160px;
}
.muse-hero-note-input {
  flex: 1;
  background: var(--navy);
  border: 1px solid var(--ivory-faint);
  border-radius: 3px;
  padding: 5px 8px;
  font-family: var(--sans);
  font-size: 12px;
  color: var(--ivory);
  outline: none;
}
.muse-hero-note-input:focus { border-color: var(--gold-faint); }
.muse-hero-note-input::placeholder { color: var(--ivory-faint); font-style: italic; }
.muse-hero-combo-wrap {
  position: relative;
}
.muse-hero-combo-input {
  width: 100%;
  background: var(--navy);
  border: 1px solid var(--ivory-faint);
  border-radius: 4px;
  padding: 10px 14px;
  font-family: var(--sans);
  font-size: 13px;
  color: var(--ivory);
  outline: none;
  box-sizing: border-box;
}
.muse-hero-combo-input:focus { border-color: var(--gold-faint); }
.muse-hero-combo-input::placeholder { color: var(--ivory-faint); font-style: italic; }
.muse-hero-combo-input:disabled { opacity: 0.4; cursor: not-allowed; }
.muse-hero-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  max-height: 360px;
  overflow-y: auto;
  background: var(--navy);
  border: 1px solid var(--gold-faint);
  border-top: none;
  border-radius: 0 0 4px 4px;
  z-index: 100;
  scrollbar-width: thin;
  scrollbar-color: var(--ivory-faint) transparent;
}
.muse-hero-dropdown[hidden] { display: none; }
.muse-hero-dd-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  cursor: pointer;
  transition: background 0.1s;
}
.muse-hero-dd-item:hover,
.muse-hero-dd-item[data-active="true"] {
  background: var(--gold-faint);
}
.muse-hero-dd-item[data-disabled="true"] {
  opacity: 0.3;
  pointer-events: none;
}
.muse-hero-dd-thumb {
  width: 40px;
  height: 40px;
  border-radius: 4px;
  object-fit: cover;
  flex-shrink: 0;
  background: var(--navy-2);
}
.muse-hero-dd-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.muse-hero-dd-name {
  font-family: var(--sans);
  font-size: 13px;
  color: var(--ivory);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.muse-hero-dd-meta {
  font-family: var(--sans);
  font-size: 11px;
  color: var(--ivory-faint);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.muse-hero-dd-empty {
  padding: 16px;
  text-align: center;
  font-family: var(--serif);
  font-style: italic;
  font-size: 13px;
  color: var(--ivory-faint);
}

/* ── Ghost buttons (shared) ───────────────────────────────── */
.muse-btn-ghost {
  background: none;
  border: 1px solid var(--gold-faint);
  color: var(--gold);
  font-family: var(--sans);
  font-size: 12px;
  padding: 6px 16px;
  border-radius: 4px;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}
.muse-btn-ghost:hover {
  border-color: var(--gold);
  color: var(--ivory);
}
.muse-btn-gold {
  background: var(--gold);
  border: none;
  color: var(--navy);
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 500;
  padding: 6px 16px;
  border-radius: 4px;
  cursor: pointer;
  transition: opacity 0.2s;
}
.muse-btn-gold:hover {
  opacity: 0.85;
}
.muse-btn-add {
  background: none;
  border: none;
  color: var(--gold);
  font-family: var(--sans);
  font-size: 12px;
  cursor: pointer;
  padding: 4px 0;
}
.muse-btn-add:hover {
  text-decoration: underline;
}

/* ── Synthesize button area ───────────────────────────────── */
.muse-synth-area {
  text-align: center;
  padding: 48px 0;
}
.muse-synth-label {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--ivory-faint);
  margin-bottom: 16px;
}
.muse-synth-btn {
  font-family: var(--serif);
  font-style: italic;
  font-size: 20px;
  background: var(--gold);
  color: var(--navy);
  border: none;
  padding: 16px 48px;
  border-radius: 4px;
  cursor: pointer;
  transition: opacity 0.2s;
}
.muse-synth-btn:hover {
  opacity: 0.85;
}
.muse-synth-btn:disabled {
  background: var(--ivory-faint);
  color: var(--ivory-soft);
  cursor: not-allowed;
  opacity: 1;
}
.muse-synth-helper {
  font-family: var(--sans);
  font-style: italic;
  font-size: 12px;
  color: var(--ivory-faint);
  margin-top: 14px;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
}

/* ── Toast ─────────────────────────────────────────────────── */
.muse-toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #14142E;
  border: 1px solid var(--gold-soft);
  color: var(--ivory);
  font-family: var(--mono);
  font-size: 12px;
  padding: 10px 18px;
  border-radius: 6px;
  z-index: 10000;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.3s, transform 0.3s;
}
.muse-toast.muse-toast-show {
  opacity: 1;
  transform: translateY(0);
}

/* ── Lumina's Read (output panel) ─────────────────────────── */
.muse-read-panel {
  background: var(--navy-2);
  border: 1px solid var(--ivory-faint);
  border-top: 2px solid var(--gold-faint);
  border-radius: 4px;
  padding: 32px 40px;
  margin-bottom: 24px;
}
.muse-read-toprow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}
.muse-read-toprow-left {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.5px;
  color: var(--ivory-faint);
}
.muse-read-toprow-right {
  display: flex;
  gap: 8px;
}
.muse-read-eyebrow {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 4px;
}
.muse-read-headline {
  font-family: var(--serif);
  font-style: italic;
  font-size: 24px;
  color: var(--ivory);
  font-weight: 400;
  margin: 0 0 20px;
  line-height: 1.3;
}
.muse-read-body {
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.7;
  color: var(--ivory);
  white-space: pre-wrap;
}
.muse-read-body::first-letter {
  font-family: var(--serif);
  font-size: 52px;
  float: left;
  line-height: 0.8;
  padding-right: 8px;
  padding-top: 4px;
  color: var(--gold);
}
.muse-read-rule {
  border: none;
  border-top: 1px solid var(--gold-faint);
  margin: 28px 0 12px;
}
.muse-read-signoff {
  font-family: var(--serif);
  font-style: italic;
  font-size: 14px;
  color: var(--ivory-soft);
  text-align: right;
}
.muse-read-jumps {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 20px;
}
.muse-read-jumps-label {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--ivory-faint);
}
.muse-read-jump-btn {
  background: none;
  border: 1px solid var(--ivory-faint);
  color: var(--ivory-soft);
  font-family: var(--mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  padding: 3px 10px;
  border-radius: 4px;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
}
.muse-read-jump-btn:hover {
  border-color: var(--gold);
  color: var(--gold);
}
/* Collapsed bar */
.muse-read-collapsed {
  background: var(--navy-2);
  border: 1px solid var(--ivory-faint);
  border-top: 2px solid var(--gold-faint);
  border-radius: 4px;
  padding: 14px 24px;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
}
.muse-read-collapsed-text {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ivory-soft);
  letter-spacing: 0.3px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
  margin-right: 16px;
}
.muse-read-collapsed-expand {
  font-family: var(--mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--gold);
  flex-shrink: 0;
}

/* ── Agent cards ──────────────────────────────────────────── */
.muse-agents-area {
  padding-top: 64px;
}
.muse-agents-header {
  margin-bottom: 24px;
}
.muse-agents-header .muse-panel-eyebrow {
  color: var(--gold);
}
.muse-agents-header-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}
.muse-agent-card {
  background: var(--navy);
  border: 1px solid var(--ivory-faint);
  border-radius: 4px;
  padding: 24px;
  margin-bottom: 16px;
}
.muse-agent-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}
.muse-agent-glyph {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--gold);
  flex-shrink: 0;
}
.muse-agent-name {
  font-family: var(--serif);
  font-style: italic;
  font-size: 18px;
  color: var(--ivory);
}
.muse-agent-role {
  font-family: var(--sans);
  font-size: 12px;
  font-style: italic;
  color: var(--ivory-soft);
}
.muse-agent-sub {
  margin-bottom: 16px;
}
.muse-agent-sub-label {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--gold-faint);
  margin-bottom: 6px;
}
.muse-agent-sub-text {
  font-family: var(--serif);
  font-size: 16px;
  color: var(--ivory);
  line-height: 1.5;
}
.muse-agent-sub-text-sm {
  font-family: var(--serif);
  font-size: 14px;
  font-style: italic;
  color: var(--ivory);
  line-height: 1.5;
}
.muse-agent-sub-para {
  font-family: var(--serif);
  font-size: 14px;
  font-style: italic;
  color: var(--ivory);
  line-height: 1.5;
}
.muse-agent-bullets {
  list-style: none;
  padding: 0;
  margin: 0;
}
.muse-agent-bullets li {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 3px 0;
  font-family: var(--sans);
  font-size: 14px;
  color: var(--ivory);
  line-height: 1.5;
}
.muse-agent-bullets li::before {
  content: '';
  display: inline-block;
  width: 5px;
  height: 5px;
  background: var(--gold);
  flex-shrink: 0;
  margin-top: 6px;
}
.muse-agent-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.muse-agent-chip-lean {
  display: inline-block;
  background: var(--gold-faint);
  color: var(--ivory);
  font-family: var(--sans);
  font-size: 12px;
  padding: 3px 10px;
  border-radius: 14px;
}
.muse-agent-chip-avoid {
  display: inline-block;
  background: var(--ivory-faint);
  color: var(--ivory-soft);
  font-family: var(--sans);
  font-size: 12px;
  padding: 3px 10px;
  border-radius: 14px;
  text-decoration: line-through;
}
.muse-agent-code {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ivory);
  background: var(--navy-2);
  padding: 16px;
  border-radius: 4px;
  overflow-x: auto;
  white-space: pre-wrap;
  word-break: break-word;
  line-height: 1.6;
}
.muse-agent-table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--sans);
  font-size: 13px;
  color: var(--ivory);
}
.muse-agent-table th {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--ivory-faint);
  text-align: left;
  padding: 6px 8px;
  border-bottom: 1px solid var(--ivory-faint);
}
.muse-agent-table td {
  padding: 6px 8px;
  border-bottom: 1px solid rgba(245,239,224,0.05);
  vertical-align: top;
}
.muse-agent-card-footer {
  text-align: right;
  margin-top: 16px;
}
.muse-agent-palette-strip {
  display: flex;
  margin-bottom: 8px;
}
.muse-agent-palette-swatch {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
}
.muse-agent-palette-color {
  width: 100%;
  height: 40px;
}
.muse-agent-palette-swatch:first-child .muse-agent-palette-color {
  border-radius: 4px 0 0 4px;
}
.muse-agent-palette-swatch:last-child .muse-agent-palette-color {
  border-radius: 0 4px 4px 0;
}
.muse-agent-palette-role {
  font-family: var(--sans);
  font-size: 10px;
  color: var(--ivory-faint);
  margin-top: 4px;
}
.muse-agent-palette-note {
  font-family: var(--sans);
  font-size: 12px;
  font-style: italic;
  color: var(--ivory-soft);
  margin-top: 6px;
}
.muse-agent-refs-strip {
  display: flex;
  gap: 8px;
  overflow-x: auto;
}
.muse-agent-ref-thumb {
  width: 56px;
  height: 56px;
  border-radius: 3px;
  object-fit: cover;
  flex-shrink: 0;
}
.muse-agents-broadcast {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0;
  margin-top: 16px;
}
.muse-agents-broadcast-left {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ivory-faint);
}
.muse-agent-register {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: var(--gold);
}

/* ── Dev links ────────────────────────────────────────────── */
.muse-dev-links {
  text-align: center;
  padding: 24px 0 48px;
}
.muse-dev-link {
  font-family: var(--mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--gold-faint);
  background: none;
  border: none;
  cursor: pointer;
  margin: 0 8px;
}
.muse-dev-link:hover {
  color: var(--gold);
}

/* ── Month selector strip ────────────────────────────────── */
.muse-period-strip {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding: 16px 0 24px;
  border-bottom: 1px solid var(--ivory-faint);
  margin-bottom: 24px;
}
.muse-period-selector { display: flex; align-items: center; gap: 12px; }
.muse-period-label { font-family: var(--mono); font-size: 10px; letter-spacing: 1.5px; text-transform: uppercase; color: var(--gold); }
.muse-period-select { background: var(--navy-2); color: var(--ivory); border: 1px solid var(--ivory-faint); border-radius: 4px; padding: 8px 12px; font-family: var(--serif); font-size: 16px; font-style: italic; }
.muse-period-instruction { font-family: var(--serif); font-style: italic; color: var(--ivory-soft); font-size: 14px; max-width: 480px; text-align: right; margin: 0; }

/* ── Lumina section panel ────────────────────────────────── */
.muse-lumina-panel {
  background: var(--navy-2);
  border: 1px solid var(--gold-faint);
  border-radius: 4px;
  padding: 40px;
  margin-bottom: 40px;
}
.muse-lumina-header { margin-bottom: 24px; }
.muse-lumina-eyebrow { font-family: var(--mono); font-size: 10px; letter-spacing: 1.5px; text-transform: uppercase; color: var(--gold); margin-bottom: 8px; }
.muse-lumina-title { font-family: var(--serif); font-size: 32px; color: var(--ivory); font-weight: 400; margin: 0; }
.muse-lumina-title em { font-style: italic; }
.muse-lumina-empty { font-family: var(--serif); font-style: italic; color: var(--ivory-soft); font-size: 16px; margin: 0 0 24px 0; max-width: 540px; }
.muse-synth-button {
  background: var(--gold);
  color: var(--navy);
  border: none;
  padding: 14px 28px;
  font-family: var(--sans);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 1px;
  text-transform: uppercase;
  cursor: pointer;
  border-radius: 2px;
  transition: background 0.2s;
}
.muse-synth-button:hover { background: var(--gold-deep); }
.muse-synth-button:disabled { background: var(--ivory-faint); color: var(--navy-2); cursor: not-allowed; }
.muse-staging-caption { font-family: var(--mono); font-size: 10px; letter-spacing: 0.5px; color: var(--ivory-faint); margin: 12px 0 0 0; }
.muse-lumina-loading-text { font-family: var(--serif); font-style: italic; font-size: 18px; color: var(--ivory-soft); margin: 0 0 16px 0; }
.muse-lumina-loading-bar { height: 2px; background: var(--gold-faint); border-radius: 1px; overflow: hidden; position: relative; }
.muse-lumina-loading-bar::after { content: ''; position: absolute; top: 0; left: -40%; width: 40%; height: 100%; background: var(--gold); animation: muse-loading-slide 1.6s ease-in-out infinite; }
@keyframes muse-loading-slide { 0% { left: -40%; } 100% { left: 100%; } }
.muse-letter-body {
  font-family: var(--serif);
  font-size: 18px;
  line-height: 1.7;
  color: var(--ivory);
  white-space: pre-wrap;
  padding: 16px 0;
  border-top: 1px solid var(--ivory-faint);
  border-bottom: 1px solid var(--ivory-faint);
  outline: none;
}
.muse-letter-body[contenteditable="true"] {
  background: rgba(226,198,141,0.06);
  padding: 16px;
  border: 1px solid var(--gold-faint);
  border-radius: 4px;
}
.muse-letter-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 16px;
}
.muse-letter-saved {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--gold-deep);
  padding: 4px 10px;
  border: 1px solid var(--gold-faint);
  border-radius: 10px;
}
.muse-letter-actions { display: flex; gap: 12px; }
.muse-letter-action-btn {
  background: transparent;
  color: var(--ivory-soft);
  border: 1px solid var(--ivory-faint);
  padding: 8px 16px;
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 1px;
  text-transform: uppercase;
  cursor: pointer;
  border-radius: 2px;
}
.muse-letter-action-btn:hover { color: var(--ivory); border-color: var(--gold); }
.muse-letter-structured {
  margin-top: 24px;
  font-family: var(--sans);
  font-size: 13px;
  color: var(--ivory-soft);
}
.muse-letter-structured summary {
  cursor: pointer;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--gold);
  padding: 8px 0;
}
.muse-letter-structured[open] summary { margin-bottom: 12px; }
.muse-structured-theme {
  font-family: var(--serif);
  font-style: italic;
  font-size: 16px;
  color: var(--ivory);
  margin-bottom: 16px;
  padding-left: 12px;
  border-left: 2px solid var(--gold-faint);
}
.muse-structured-arc {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 16px;
}
.muse-structured-arc th {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--ivory-faint);
  text-align: left;
  padding: 6px 8px;
  border-bottom: 1px solid var(--ivory-faint);
}
.muse-structured-arc td {
  padding: 6px 8px;
  border-bottom: 1px solid rgba(244,239,231,0.05);
  font-family: var(--sans);
  font-size: 13px;
  color: var(--ivory);
}
.muse-structured-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 16px;
}
.muse-structured-chip-gold {
  display: inline-block;
  background: var(--gold-faint);
  color: var(--ivory);
  font-family: var(--sans);
  font-size: 12px;
  padding: 3px 10px;
  border-radius: 14px;
}
.muse-structured-chip-faint {
  display: inline-block;
  background: var(--ivory-faint);
  color: var(--ivory-soft);
  font-family: var(--sans);
  font-size: 12px;
  padding: 3px 10px;
  border-radius: 14px;
  text-decoration: line-through;
}
.muse-structured-label {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--ivory-faint);
  margin-bottom: 8px;
}
.muse-structured-reading {
  font-family: var(--serif);
  font-style: italic;
  font-size: 14px;
  color: var(--ivory-soft);
  margin-top: 12px;
}

/* ── Musing sections (8-part structured musing) ──────────── */
.muse-musing-body {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.muse-musing-section {
  padding: 24px 0;
  border-bottom: 1px solid var(--ivory-faint);
}
.muse-musing-section:last-child { border-bottom: none; }
.muse-musing-section-label {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 12px;
}
.muse-musing-section-text {
  font-family: var(--sans);
  font-style: normal;
  font-size: 14px;
  line-height: 1.75;
  color: var(--ivory);
  white-space: pre-wrap;
}
.muse-musing-throughline {
  font-family: var(--sans);
  font-style: normal;
  font-size: 14px;
  color: var(--gold);
  padding: 16px 0 16px 16px;
  border-left: 2px solid var(--gold-faint);
  margin: 16px 0;
}

/* ── Version bar ─────────────────────────────────────────── */
.muse-version-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding: 16px 0 24px;
  border-bottom: 1px solid var(--ivory-faint);
  margin-bottom: 0;
}
.muse-version-select {
  background: var(--navy);
  color: var(--ivory);
  border: 1px solid var(--ivory-faint);
  border-radius: 4px;
  padding: 8px 12px;
  font-family: var(--sans);
  font-size: 12px;
  min-width: 200px;
}
.muse-version-active-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold);
  flex-shrink: 0;
}
.muse-synth-button-sm {
  padding: 8px 16px;
  font-size: 11px;
}
.muse-letter-action-btn-danger {
  color: var(--vermillion);
  border-color: rgba(210,69,46,0.3);
  margin-left: auto;
}
.muse-letter-action-btn-danger:hover {
  color: #fff;
  border-color: var(--vermillion);
  background: rgba(210,69,46,0.15);
}

/* ── Tone bank (vibe section redesign) ───────────────────── */
.muse-tone-bank {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 28px;
}
.muse-tone-category {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.muse-tone-category-label {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--ivory-faint);
}
.muse-tone-category-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.muse-tone-pill {
  background: transparent;
  color: var(--ivory);
  border: 1px solid var(--ivory-faint);
  border-radius: 999px;
  padding: 6px 14px;
  font-family: var(--sans);
  font-style: normal;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
}
.muse-tone-pill:hover {
  border-color: var(--gold);
  color: var(--gold);
}
.muse-tone-pill[data-selected="true"] {
  background: var(--gold);
  color: var(--navy);
  border-color: var(--gold);
  font-style: normal;
  font-weight: 500;
}
.muse-tone-pill[data-selected="true"]:hover {
  background: var(--gold-deep);
  border-color: var(--gold-deep);
}
.muse-tone-selected-wrap {
  border-top: 1px solid var(--ivory-faint);
  padding-top: 20px;
  margin-bottom: 24px;
}
.muse-tone-selected-label {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1.5px;
  color: var(--gold);
  margin-bottom: 12px;
}
.muse-tone-selected-label span {
  color: var(--ivory);
}
.muse-tone-selected {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-height: 36px;
}
.muse-tone-selected:empty::after {
  content: 'No tone words selected yet.';
  font-family: var(--serif);
  font-style: italic;
  color: var(--ivory-faint);
  font-size: 14px;
}
.muse-tone-selected .muse-tone-pill {
  background: var(--gold);
  color: var(--navy);
  border-color: var(--gold);
  font-style: normal;
  font-weight: 500;
  padding-right: 28px;
  position: relative;
}
.muse-tone-selected .muse-tone-pill::after {
  content: '\00d7';
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 16px;
  line-height: 1;
  color: var(--navy);
  opacity: 0.6;
}
.muse-tone-selected .muse-tone-pill:hover::after {
  opacity: 1;
}
.muse-tone-warn {
  font-family: var(--serif);
  font-style: italic;
  color: var(--gold-deep);
  font-size: 13px;
  margin: 12px 0 0 0;
}
.muse-tone-warn[hidden] { display: none; }
.muse-tone-custom {
  margin-top: 8px;
}
.muse-tone-input {
  width: 100%;
  background: transparent;
  color: var(--ivory);
  border: 1px solid var(--ivory-faint);
  border-radius: 4px;
  padding: 12px 16px;
  font-family: var(--sans);
  font-style: normal;
  font-size: 13px;
  outline: none;
}
.muse-tone-input::placeholder {
  color: var(--ivory-faint);
}
.muse-tone-input:focus {
  border-color: var(--gold-faint);
}
