:root {
  --ink: #fff8ed;
  --muted: #b9d1dd;
  --paper: #041a35;
  --surface: #082745;
  --line: #1b4e70;
  --accent: #12c4d5;
  --sage: #32c7b3;
  --warning: #f4b63d;
  --danger: #ff846e;
  --sidebar: #020f25;
  --sidebar-muted: #9ab8c8;
  --radius: 7px;
  --display: "Libre Baskerville", Georgia, serif;
  font-family: "DM Sans", Arial, sans-serif;
  color: var(--ink);
  background: var(--paper);
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; background: var(--paper); color: var(--ink); }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: wait; opacity: .58; }
.is-busy body { cursor: progress; }
button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: 3px solid rgba(18, 196, 213, .45);
  outline-offset: 2px;
}

.app-shell { min-height: 100vh; display: grid; grid-template-columns: 238px minmax(0, 1fr); }
.sidebar { background: var(--sidebar); color: #fff; padding: 24px 16px; display: flex; flex-direction: column; gap: 28px; }
.brand { display: flex; gap: 11px; align-items: center; padding: 0 8px; }
.brand-logo { width: 42px; height: 42px; object-fit: cover; border-radius: 50%; border: 1px solid rgba(18,196,213,.8); }
.brand-title { display: block; color: #fff8ed; font-size: 16px; font-weight: 700; line-height: 1.05; }
.brand-subtitle { display: block; margin-top: 3px; color: var(--accent); font-family: "DM Mono", monospace; font-size: 10px; letter-spacing: .12em; text-transform: uppercase; }
.nav { display: grid; gap: 4px; }
.nav-button { height: 42px; border: 0; background: transparent; color: var(--sidebar-muted); display: flex; align-items: center; gap: 11px; padding: 0 10px; border-radius: 5px; text-align: left; }
.nav-button:hover, .nav-button.active { color: #fff8ed; background: rgba(18,196,213,.13); }
.nav-button svg { width: 18px; height: 18px; }
.nav-health { width: 7px; height: 7px; margin-left: auto; border-radius: 50%; background: var(--sage); }
.nav-health.degraded { background: var(--warning); }
.nav-health.critical { background: #ff6b57; box-shadow: 0 0 0 3px rgba(255,107,87,.15); }
.nav-health.paused, .nav-health.checking { background: var(--sidebar-muted); }
.sidebar-foot { margin-top: auto; border-top: 1px solid rgba(255,255,255,.18); padding: 18px 8px 0; }
.sidebar-foot p { margin: 5px 0 0; color: var(--sidebar-muted); font-size: 12px; line-height: 1.45; }
.sidebar-foot strong { font-size: 13px; }

.main { min-width: 0; padding: 26px clamp(20px, 4vw, 56px) 42px; }
.topbar { min-height: 48px; display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 34px; }
.eyebrow { font-family: "DM Mono", monospace; color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .07em; }
.topbar h1 { margin: 4px 0 0; font-family: var(--display); font-size: 25px; letter-spacing: 0; line-height: 1.2; }
.top-actions { display: flex; align-items: center; justify-content: flex-end; gap: 10px; }
.automation-state { min-height: 34px; display: flex; gap: 8px; align-items: center; border: 0; padding: 0 8px; border-radius: 4px; font-size: 13px; color: var(--muted); background: transparent; white-space: nowrap; }
.automation-state:hover { background: rgba(20,34,43,.05); color: var(--ink); }
.dot { width: 8px; height: 8px; background: var(--sage); border-radius: 50%; }
.dot.degraded { background: var(--warning); }
.dot.critical { background: var(--danger); }
.dot.paused, .dot.checking { background: var(--muted); }
.button { min-height: 39px; border: 1px solid var(--ink); color: white; background: var(--ink); border-radius: 5px; padding: 0 14px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; font-weight: 600; font-size: 13px; }
.button:hover { background: #0d3b60; }
.button.accent { background: var(--accent); border-color: var(--accent); }
.button.accent:hover { background: #0eaabd; }
.button.secondary { background: #0a2d4e; color: var(--ink); border-color: var(--line); }
.button.secondary:hover { background: #0d3b60; }
.button.ghost { background: transparent; color: var(--ink); border-color: transparent; }
.button.danger { background: #4a2631; color: #fff8ed; border-color: #bf5f60; }
.button svg { width: 16px; height: 16px; }
.icon-button { width: 36px; height: 36px; padding: 0; border: 1px solid var(--line); color: var(--ink); background: var(--surface); display: inline-grid; place-items: center; border-radius: 5px; }
.icon-button:hover { border-color: var(--ink); }
.icon-button svg { width: 17px; height: 17px; }

.view-intro { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; margin-bottom: 22px; }
.view-intro h2 { font-size: 19px; margin: 0; letter-spacing: 0; }
.view-intro p { margin: 4px 0 0; color: var(--muted); font-size: 13px; }
.health-banner { min-height: 68px; margin-bottom: 14px; padding: 14px 16px; display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; align-items: center; gap: 13px; border: 1px solid #b9d8cf; border-left: 5px solid var(--sage); border-radius: var(--radius); background: #edf7f4; }
.health-banner.degraded { border-color: #e5cf9c; border-left-color: var(--warning); background: #fff9e9; }
.health-banner.critical { border-color: #efc1ba; border-left-color: var(--danger); background: #fff5f2; }
.health-banner.paused { border-color: var(--line); border-left-color: var(--muted); background: #f0f2f1; }
.health-icon { width: 34px; height: 34px; display: grid; place-items: center; color: var(--sage); }
.health-banner.degraded .health-icon { color: var(--warning); }
.health-banner.critical .health-icon { color: var(--danger); }
.health-icon svg { width: 23px; height: 23px; }
.health-banner strong { display: block; font-size: 13px; }
.health-banner p { margin: 3px 0 0; color: var(--muted); font-size: 12px; line-height: 1.4; }
.health-banner .button { padding-right: 4px; }
.metrics { display: grid; grid-template-columns: repeat(4, minmax(120px, 1fr)); border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.metric { padding: 17px 20px; min-height: 100px; border-right: 1px solid var(--line); }
.metric:last-child { border-right: 0; }
.metric-label { font-family: "DM Mono", monospace; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; font-size: 10px; }
.metric-value { display: block; margin-top: 10px; font-size: 28px; font-weight: 700; }
.metric-detail { margin-top: 4px; color: var(--muted); font-size: 12px; }

.control-band { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(310px, .8fr); margin-top: 20px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.next-release { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; padding: 24px; background: #eef5f2; }
.next-release h2 { max-width: 660px; margin: 7px 0 6px; font-size: 22px; line-height: 1.12; }
.next-release p { max-width: 680px; margin: 0; color: #405057; font-size: 13px; line-height: 1.5; }
.release-meta { min-width: 142px; display: grid; justify-items: end; gap: 7px; text-align: right; }
.release-meta strong { font: 700 16px "DM Mono", monospace; color: var(--sage); white-space: nowrap; }
.release-meta span { color: var(--muted); font-size: 11px; line-height: 1.35; }
.quick-composer { min-width: 0; display: grid; align-content: center; gap: 9px; padding: 22px; border-left: 1px solid var(--line); background: #fffdf8; }
.quick-composer label { color: var(--muted); font: 700 10px "DM Mono", monospace; letter-spacing: .06em; text-transform: uppercase; }
.quick-composer div { min-width: 0; display: flex; gap: 8px; }
.quick-composer input { min-width: 0; flex: 1; min-height: 39px; border: 1px solid var(--line); border-radius: 4px; padding: 0 10px; color: var(--ink); background: white; }
.quick-composer input:focus { border-color: var(--ink); }
.overview-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(280px, .65fr); gap: 20px; margin-top: 20px; align-items: start; }
.panel { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.panel-head { padding: 17px 18px 14px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.panel-head h3 { margin: 0; font-size: 14px; }
.panel-head span { color: var(--muted); font-size: 12px; }
.content-row { padding: 14px 17px; display: grid; grid-template-columns: 46px minmax(0, 1fr) auto auto auto; align-items: center; gap: 13px; border-bottom: 1px solid var(--line); }
.content-row:last-child { border-bottom: 0; }
.content-row:hover { background: #fbfbf8; }
.type-thumbnail { width: 46px; height: 58px; padding: 7px 5px; display: flex; flex-direction: column; justify-content: space-between; background: var(--ink); color: white; border-left: 4px solid var(--accent); overflow: hidden; }
.type-thumbnail span { font: 700 10px "DM Mono", monospace; color: #f9d877; }
.type-thumbnail strong { font-size: 9px; line-height: 1.1; text-transform: uppercase; overflow: hidden; max-height: 30px; }
.content-title { margin: 0; font-size: 13px; font-weight: 700; line-height: 1.32; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.content-meta { margin: 4px 0 0; font-size: 12px; color: var(--muted); }
.content-copy { min-width: 0; }
.mode-pill { display: inline-flex; align-items: center; white-space: nowrap; border-radius: 999px; padding: 5px 8px; font-family: "DM Mono", monospace; text-transform: uppercase; letter-spacing: .03em; font-size: 9px; color: #25444e; background: #e8f0ee; }
.mode-pill.playful { color: #7b4500; background: #fff0ca; }
.mode-pill.story { color: #285761; background: #dceff0; }
.mode-pill.myth { color: #7d3130; background: #fbe1dc; }
.row-actions { display: flex; align-items: center; gap: 10px; }
.quality { font-family: "DM Mono", monospace; color: var(--sage); font-size: 12px; }
.status { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; font-family: "DM Mono", monospace; letter-spacing: .02em; text-transform: uppercase; }
.status::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--muted); }
.status.ready::before, .status.scheduled::before { background: var(--sage); }
.status.review::before { background: var(--warning); }
.status.held::before, .status.blocked::before { background: var(--danger); }
.status.published::before { background: var(--accent); }
.signal-row { padding: 14px 17px; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 14px; justify-content: space-between; }
.signal-row:last-child { border-bottom: 0; }
.signal-row strong { font-size: 12px; line-height: 1.4; font-weight: 600; }
.signal-row span { color: var(--sage); font-family: "DM Mono", monospace; font-size: 11px; white-space: nowrap; }
.timeline-item { width: 100%; display: grid; grid-template-columns: 104px minmax(0, 1fr) auto; align-items: center; gap: 15px; padding: 16px 18px; border: 0; border-bottom: 1px solid var(--line); color: var(--ink); background: transparent; text-align: left; }
.timeline-item:hover { background: #fbfbf8; }
.timeline-item:last-child { border-bottom: 0; }
.timeline-item.is-next { background: #fff8f3; box-shadow: inset 4px 0 0 var(--accent); }
.timeline-time { color: var(--sage); font: 700 11px "DM Mono", monospace; line-height: 1.35; }
.timeline-copy { min-width: 0; }
.timeline-copy strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }
.timeline-copy small { display: block; margin-top: 4px; overflow: hidden; color: var(--muted); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.timeline-item .mode-pill { justify-self: end; }
.timeline-item svg { width: 17px; height: 17px; color: var(--muted); }
.reserve-body { padding: 19px; }
.reserve-body p { margin: 13px 0 17px; color: var(--muted); font-size: 13px; line-height: 1.45; }
.reserve-progress { height: 9px; overflow: hidden; background: #e4e9e6; border-radius: 99px; }
.reserve-progress span { display: block; height: 100%; background: var(--sage); border-radius: inherit; }
.autopilot-controls { display: flex; flex-wrap: wrap; gap: 9px; }
.autopilot-controls.compact { display: grid; grid-template-columns: 1fr; }
.autopilot-controls.compact .button { width: 100%; }
.control-summary { display: grid; grid-template-columns: 1fr 1fr; gap: 0; }
.control-summary div { padding: 20px 18px 14px; border-right: 1px solid var(--line); }
.control-summary div:nth-child(2) { border-right: 0; }
.control-summary strong { display: block; color: var(--accent); font: 700 26px "DM Mono", monospace; }
.control-summary span { color: var(--muted); font-size: 12px; }
.control-summary p { grid-column: 1 / -1; margin: 0; padding: 14px 18px 18px; border-top: 1px solid var(--line); color: #405057; font-size: 12px; line-height: 1.45; }

.filter-bar { border-bottom: 1px solid var(--line); display: flex; gap: 8px; padding: 0 0 15px; margin-bottom: 15px; overflow-x: auto; }
.filter { flex: 0 0 auto; border: 1px solid var(--line); padding: 7px 10px; border-radius: 999px; font-size: 12px; color: var(--muted); background: var(--surface); }
.filter.active { background: var(--ink); color: white; border-color: var(--ink); }
.topic-create { display: grid; grid-template-columns: 190px minmax(0, 1fr); align-items: center; gap: 12px; padding: 13px; margin-bottom: 15px; border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius); }
.topic-create label { color: var(--muted); font: 700 10px "DM Mono", monospace; letter-spacing: .06em; text-transform: uppercase; }
.topic-create > div { min-width: 0; display: flex; gap: 9px; }
.topic-create input { min-width: 0; flex: 1; border: 0; outline: 0; color: var(--ink); padding: 0 7px; }
.content-toolbar { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.content-toolbar > span { padding-top: 8px; color: var(--muted); font: 700 10px "DM Mono", monospace; white-space: nowrap; }
.library-tools { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 14px; }
.library-tools > span { color: var(--muted); font: 700 10px "DM Mono", monospace; white-space: nowrap; }
.search-field { width: min(520px, 100%); min-height: 40px; display: flex; align-items: center; gap: 9px; padding: 0 11px; border: 1px solid var(--line); border-radius: 5px; background: var(--surface); }
.search-field:focus-within { border-color: var(--ink); box-shadow: 0 0 0 2px rgba(20,34,43,.1); }
.search-field svg { width: 16px; height: 16px; color: var(--muted); }
.search-field input { min-width: 0; flex: 1; border: 0; outline: 0; color: var(--ink); background: transparent; }
.result-limit { margin: 12px 0 0; color: var(--muted); text-align: center; font-size: 12px; }
.load-more { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 14px; }
.load-more span { color: var(--muted); font: 10px "DM Mono", monospace; }
.content-list { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.content-list .content-row { grid-template-columns: 58px minmax(0, 1fr) 98px 90px auto; min-height: 87px; }
.content-list .type-thumbnail { width: 58px; height: 72px; }
.format-pill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 8px;
  border: 1px solid #b6d5cc;
  border-radius: 4px;
  color: #195b51;
  background: #edf8f4;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}
.empty { color: var(--muted); padding: 32px; text-align: center; }

.calendar { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.calendar-day { display: grid; grid-template-columns: 150px minmax(0, 1fr); min-height: 85px; border-bottom: 1px solid var(--line); }
.calendar-day:last-child { border-bottom: 0; }
.day-label { padding: 15px 17px; border-right: 1px solid var(--line); }
.day-label strong { display: block; font-size: 13px; text-transform: capitalize; }
.day-label span { display: block; margin-top: 4px; color: var(--muted); font-size: 12px; }
.day-posts { padding: 12px 16px; display: flex; align-items: center; gap: 10px; overflow-x: auto; }
.calendar-post { min-width: 220px; max-width: 270px; padding: 10px 12px; border-left: 4px solid var(--accent); background: #fff8f5; }
.calendar-post.is-next { border-color: var(--sage); background: #e7f3f0; }
.calendar-post strong { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 12px; }
.calendar-post span { display: block; margin-top: 5px; color: var(--muted); font-family: "DM Mono", monospace; font-size: 10px; }
.day-tabs { display: flex; gap: 7px; margin-bottom: 14px; overflow-x: auto; padding-bottom: 3px; }
.day-tab { min-width: 112px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 5px; color: var(--muted); background: var(--surface); text-align: left; }
.day-tab strong, .day-tab span { display: block; }
.day-tab strong { color: var(--ink); font-size: 12px; text-transform: capitalize; }
.day-tab span { margin-top: 4px; font: 10px "DM Mono", monospace; }
.day-tab.active { border-color: var(--sage); background: #e7f3f0; box-shadow: inset 0 -3px 0 var(--sage); }
.agenda { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.agenda-head { min-height: 76px; padding: 15px 18px; display: flex; align-items: center; justify-content: space-between; gap: 18px; border-bottom: 1px solid var(--line); background: #eef5f2; }
.agenda-head h3 { margin: 5px 0 0; font-size: 17px; text-transform: capitalize; }
.agenda-head > strong { color: var(--sage); font: 700 12px "DM Mono", monospace; }
.agenda-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.agenda-post { min-height: 76px; display: grid; grid-template-columns: 54px minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 12px 15px; border: 0; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); color: var(--ink); background: transparent; text-align: left; }
.agenda-post:nth-child(2n) { border-right: 0; }
.agenda-post:hover { background: #fbfbf8; }
.agenda-post.is-next { background: #fff8f3; box-shadow: inset 4px 0 0 var(--accent); }
.agenda-post > span { color: var(--sage); font: 700 11px "DM Mono", monospace; }
.agenda-post strong, .agenda-post small { display: block; overflow: hidden; text-overflow: ellipsis; }
.agenda-post strong { font-size: 12px; white-space: nowrap; }
.agenda-post small { margin-top: 4px; color: var(--muted); font-size: 11px; white-space: nowrap; }
.agenda-post svg { width: 16px; height: 16px; color: var(--muted); }

.settings-grid { display: grid; grid-template-columns: minmax(0, 1.18fr) minmax(300px, .82fr); gap: 20px; }
.settings-section { border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius); padding: 20px; }
.settings-section h3 { font-size: 14px; margin: 0 0 17px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; }
.field { display: grid; gap: 7px; }
.field.full { grid-column: 1 / -1; }
.field label { color: var(--muted); font-family: "DM Mono", monospace; font-size: 10px; text-transform: uppercase; letter-spacing: .06em; }
.field input, .field textarea, .field select { width: 100%; border: 1px solid var(--line); min-height: 39px; padding: 8px 10px; color: var(--ink); background: #fff; border-radius: 4px; outline: none; }
.field textarea { resize: vertical; min-height: 78px; line-height: 1.45; }
.field input:focus, .field textarea:focus, .field select:focus { border-color: var(--ink); box-shadow: 0 0 0 2px rgba(20,34,43,.1); }
.themes { display: flex; flex-wrap: wrap; gap: 7px; min-height: 32px; }
.theme-chip { background: #e9efed; color: #24463e; display: inline-flex; gap: 7px; align-items: center; padding: 6px 8px 6px 10px; border-radius: 999px; font-size: 12px; }
.theme-chip button { background: transparent; border: 0; padding: 0; color: #24463e; display: grid; place-items: center; }
.theme-chip svg { width: 13px; height: 13px; }
.theme-add { display: flex; gap: 8px; margin-top: 10px; }
.theme-add input { border: 1px solid var(--line); padding: 8px 10px; border-radius: 4px; min-width: 0; flex: 1; }
.section-separator { height: 1px; background: var(--line); margin: 22px -20px; }
.toggle-row { display: flex; justify-content: space-between; gap: 20px; align-items: center; }
.toggle-row strong { display: block; font-size: 13px; }
.toggle-row span { display: block; color: var(--muted); margin-top: 4px; font-size: 12px; line-height: 1.4; }
.switch { position: relative; width: 44px; height: 24px; flex: 0 0 auto; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch-track { position: absolute; inset: 0; border-radius: 999px; background: #b8c1bf; transition: .2s; }
.switch-track::before { content: ""; position: absolute; width: 18px; height: 18px; left: 3px; top: 3px; border-radius: 50%; background: white; transition: .2s; }
.switch input:checked + .switch-track { background: var(--sage); }
.switch input:checked + .switch-track::before { transform: translateX(20px); }
.settings-footer { margin-top: 20px; display: flex; justify-content: flex-end; }
.cadence-summary { display: flex; gap: 11px; margin-top: 17px; padding: 13px; background: #eef5f2; border-left: 4px solid var(--sage); }
.cadence-summary svg { flex: 0 0 auto; width: 18px; height: 18px; color: var(--sage); }
.cadence-summary p { margin: 0; }
.cadence-summary strong, .cadence-summary span { display: block; font-size: 12px; }
.cadence-summary span { margin-top: 4px; color: var(--muted); line-height: 1.4; }
.connector { padding: 13px 0; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 10px; }
.connector:last-child { border-bottom: 0; }
.connector-icon { width: 29px; height: 29px; display: grid; place-items: center; background: var(--paper); border: 1px solid var(--line); }
.connector strong { display: block; font-size: 13px; }
.connector span { display: block; margin-top: 3px; color: var(--muted); font-size: 11px; }
.connector-state { margin-left: auto; font-family: "DM Mono", monospace; font-size: 10px; text-transform: uppercase; color: var(--warning); }
.mode-select { display: flex; gap: 7px; flex-wrap: wrap; }
.mode-toggle { border: 1px solid var(--line); background: white; color: var(--muted); min-height: 33px; padding: 0 10px; border-radius: 999px; font-size: 12px; }
.mode-toggle.active { color: var(--ink); background: #e3f1ed; border-color: #83b9ad; font-weight: 700; }
.analytics-grid { grid-template-columns: minmax(0, 1.2fr) minmax(280px, .8fr); }
.growth-view { display: grid; gap: 20px; }
.growth-hero { min-height: 184px; padding: 26px; display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; color: #14333d; border-left: 6px solid var(--accent); background: #fff0ec; }
.growth-hero h2 { max-width: 660px; margin: 7px 0 7px; font-size: 29px; line-height: 1.06; }
.growth-hero p { max-width: 700px; margin: 0; color: #405057; font-size: 13px; line-height: 1.55; }
.growth-hero-actions { display: flex; flex: 0 0 auto; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
.growth-metrics { margin-top: 0; }
.growth-channel-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.growth-channel { min-height: 142px; display: grid; grid-template-columns: 36px minmax(0, 1fr); align-content: start; gap: 12px; padding: 16px; border: 1px solid var(--line); border-top: 3px solid var(--sage); background: var(--surface); }
.growth-channel.paused { border-top-color: #9aa8a5; }
.growth-channel.needs_connection { border-top-color: var(--warning); }
.growth-channel-icon { width: 34px; height: 34px; display: grid; place-items: center; color: #1a665c; background: #e4f2ee; }
.growth-channel.needs_connection .growth-channel-icon { color: #8d5b08; background: #fff0cb; }
.growth-channel-icon svg { width: 17px; height: 17px; }
.growth-channel-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.growth-channel h3 { margin: 0; font-size: 13px; }
.growth-channel h3 + span { flex: 0 0 auto; color: var(--sage); font: 700 9px "DM Mono", monospace; text-transform: uppercase; }
.growth-channel.needs_connection h3 + span { color: var(--warning); }
.growth-channel.paused h3 + span { color: var(--muted); }
.growth-channel p { margin: 8px 0 0; color: #405057; font-size: 12px; line-height: 1.45; }
.growth-layout { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(280px, .7fr); gap: 20px; }
.growth-policy .panel-head, .growth-guardrail .panel-head, .growth-public .panel-head { align-items: start; }
.growth-policy .panel-head p, .growth-guardrail .panel-head p, .growth-public .panel-head p { margin: 4px 0 0; color: var(--muted); font-size: 11px; line-height: 1.4; }
.growth-policy-body { padding: 0 17px; }
.growth-policy .toggle-row { min-height: 74px; padding: 13px 0; border-bottom: 1px solid var(--line); }
.growth-number-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding: 16px 0; }
.growth-number-grid .field { display: grid; gap: 6px; }
.growth-number-grid .field > span { color: var(--muted); font: 700 10px "DM Mono", monospace; text-transform: uppercase; }
.growth-actions { display: flex; flex-wrap: wrap; gap: 8px; padding: 0 0 17px; }
.growth-guardrail .principle-list { padding: 5px 17px 9px; }
.growth-forecast { margin: 0 17px 17px; padding: 13px; border-left: 3px solid var(--accent); color: #405057; background: #fff6f3; font-size: 12px; line-height: 1.48; }
.growth-public { overflow: hidden; }
.growth-traffic { overflow: hidden; }
.growth-traffic .panel-head > strong { color: var(--accent); font: 700 24px "DM Mono", monospace; }
.traffic-sources { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); border-top: 1px solid var(--line); }
.traffic-sources > div { min-height: 66px; display: grid; align-content: center; gap: 5px; padding: 11px 15px; border-right: 1px solid var(--line); }
.traffic-sources > div:last-child { border-right: 0; }
.traffic-sources span { color: var(--muted); font-size: 10px; }
.traffic-sources strong { font: 700 16px "DM Mono", monospace; }
.growth-indexnow { min-height: 64px; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 13px 17px; border-top: 1px solid var(--line); background: #f6faf7; }
.growth-indexnow > div { display: flex; align-items: center; gap: 10px; }
.growth-indexnow svg { width: 18px; height: 18px; color: #1a665c; }
.growth-indexnow strong, .growth-indexnow small { display: block; }
.growth-indexnow strong { font-size: 12px; }
.growth-indexnow small { margin-top: 2px; color: var(--muted); font-size: 11px; }
.growth-reels { margin-top: 20px; overflow: hidden; }
.reel-summary { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-bottom: 1px solid var(--line); }
.reel-summary > div { min-height: 78px; padding: 14px 17px; display: grid; align-content: center; gap: 4px; border-right: 1px solid var(--line); }
.reel-summary > div:last-child { border-right: 0; }
.reel-summary strong { overflow: hidden; font-size: 16px; line-height: 1.25; text-overflow: ellipsis; white-space: nowrap; }
.reel-summary span { color: var(--muted); font-size: 11px; }
.growth-links { display: grid; grid-template-columns: repeat(3, 1fr); }
.growth-links a { min-height: 62px; display: grid; grid-template-columns: 20px minmax(0, 1fr) 16px; align-items: center; gap: 9px; padding: 14px 17px; color: #23454b; border-right: 1px solid var(--line); text-decoration: none; font-size: 12px; font-weight: 700; }
.growth-links a:last-child { border-right: 0; }
.growth-links a:hover { color: #0e5e54; background: #eef6f3; }
.growth-links svg { width: 16px; height: 16px; }
.comment-row { padding: 13px 16px; border-bottom: 1px solid var(--line); }
.comment-row:last-child { border-bottom: 0; }
.comment-row p { margin: 7px 0 0; color: #405057; font-size: 12px; line-height: 1.45; }
.comment-kind { color: var(--sage); font-family: "DM Mono", monospace; font-size: 10px; text-transform: uppercase; letter-spacing: .05em; }
.principle-list { padding: 4px 17px 12px; }
.principle-list p { display: flex; align-items: flex-start; gap: 9px; color: #405057; font-size: 12px; line-height: 1.5; }
.principle-list svg { flex: 0 0 auto; width: 16px; height: 16px; color: var(--accent); margin-top: 1px; }
.login-page { min-height: 100vh; display: grid; place-items: center; padding: 20px; background: #020f25; }
.login-panel { width: min(440px, 100%); border: 1px solid #216080; background: #082745; border-radius: 8px; padding: 34px; box-shadow: 0 28px 80px rgba(0,0,0,.32); }
.login-logo { display: block; width: 96px; height: 96px; margin: 0 auto 20px; object-fit: cover; border: 1px solid var(--accent); border-radius: 50%; }
.login-kicker { display: block; color: var(--accent); font: 700 11px "DM Mono", monospace; letter-spacing: .16em; text-align: center; }
.login-panel h1 { font-family: var(--display); font-size: 28px; line-height: 1.2; margin: 12px 0 9px; text-align: center; }
.login-panel p { color: var(--muted); margin: 0 0 22px; font-size: 13px; line-height: 1.5; }
.login-panel form { display: grid; gap: 10px; }
.login-panel input { min-height: 42px; border: 1px solid var(--line); border-radius: 4px; padding: 0 11px; color: var(--ink); background: #041a35; }

.modal-backdrop { position: fixed; inset: 0; z-index: 30; background: rgba(20,34,43,.48); display: grid; place-items: center; padding: 18px; }
.modal { width: min(1050px, 100%); max-height: min(840px, calc(100vh - 36px)); overflow: auto; background: var(--paper); border-radius: 8px; box-shadow: 0 26px 80px rgba(20,34,43,.25); }
.modal-head { position: sticky; top: 0; z-index: 3; padding: 18px 21px; background: var(--paper); border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; gap: 12px; align-items: center; }
.modal-head h2 { margin: 0; font-size: 18px; line-height: 1.2; }
.modal-head .head-meta { margin-top: 5px; color: var(--muted); font-size: 12px; }
.modal-body { padding: 22px; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(270px, .9fr); gap: 22px; }
.slides { display: flex; gap: 12px; overflow-x: auto; align-items: flex-start; padding-bottom: 10px; scroll-snap-type: x mandatory; }
.rendered-slide { width: 272px; min-width: 272px; aspect-ratio: .8; margin: 0; overflow: hidden; background: #eef1ed; border: 1px solid #dce3df; border-radius: 4px; scroll-snap-align: start; }
.rendered-slide img { display: block; width: 100%; height: 100%; object-fit: contain; }
.text-slide { width: 272px; min-width: 272px; aspect-ratio: .8; display: flex; flex-direction: column; overflow: hidden; padding: 21px 19px 18px; color: #14333d; background: #f4f7f2; scroll-snap-align: start; }
.text-slide.is-cta { color: #fff; background: #14333d; }
.text-slide.is-interlude { background: #f6c75b; color: #14333d; }
.slide-top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; padding-bottom: 12px; opacity: .9; font: 700 9px "DM Mono", monospace; }
.slide-top b { font-size: 12px; }
.text-slide h3 { margin: 24px 0 18px; overflow-wrap: anywhere; font-size: 30px; line-height: 1.02; letter-spacing: 0; }
.text-slide p { margin: 0; overflow-wrap: anywhere; color: inherit; opacity: .84; font-size: 13px; line-height: 1.46; }
.text-slide footer { margin-top: auto; padding-top: 14px; font: 700 8px "DM Mono", monospace; letter-spacing: .06em; text-transform: uppercase; opacity: .72; }
.detail-block { padding: 0 0 18px; margin-bottom: 18px; border-bottom: 1px solid var(--line); }
.detail-block:last-child { margin-bottom: 0; border-bottom: 0; }
.detail-block h3 { margin: 0 0 9px; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; font-family: "DM Mono", monospace; }
.detail-block p { color: #405057; line-height: 1.55; font-size: 13px; white-space: pre-line; margin: 0; }
.source-link { display: block; color: #1b6157; font-size: 13px; text-decoration: none; margin: 8px 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.source-link:hover { text-decoration: underline; }
.quality-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 7px; }
.quality-score { padding: 9px 7px; background: white; border: 1px solid var(--line); text-align: center; }
.quality-score strong { display: block; font-size: 17px; }
.quality-score span { display: block; color: var(--muted); font-size: 10px; margin-top: 3px; }
.issue { color: var(--danger) !important; }
.modal-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 18px; }
.danger-outline { color: var(--danger); border-color: #d9a8a1; background: transparent; }
.danger-outline:hover { background: #fff1ee; }
.button.danger { color: #fff; border-color: var(--danger); background: var(--danger); }
.confirm-modal { width: min(520px, 100%); }
.confirm-body { padding: 24px; text-align: center; }
.confirm-body > svg { width: 28px; height: 28px; color: var(--danger); }
.confirm-body p { margin: 14px 0 22px; color: #405057; font-size: 13px; line-height: 1.55; }
.confirm-body > div { display: flex; justify-content: center; gap: 9px; }
.schedule-editor { margin-top: 16px; padding: 14px; border: 1px solid var(--line); background: var(--surface); }
.schedule-editor label { display: block; margin-bottom: 8px; color: var(--muted); font: 700 10px "DM Mono", monospace; text-transform: uppercase; }
.schedule-editor > div { display: flex; gap: 8px; }
.schedule-editor input { min-width: 0; flex: 1; min-height: 39px; padding: 7px 9px; border: 1px solid var(--line); background: #fff; }
.post-editor { padding: 22px; }
.editor-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.editor-grid label, .slide-editor label, .source-editor label { display: grid; gap: 6px; color: var(--muted); font: 700 10px "DM Mono", monospace; text-transform: uppercase; }
.editor-grid label.full { grid-column: 1 / -1; }
.editor-grid input, .editor-grid textarea, .editor-grid select, .slide-editor input, .slide-editor textarea, .source-editor input, .source-editor textarea { width: 100%; min-height: 39px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 4px; color: var(--ink); background: #fff; font-family: "DM Sans", Arial, sans-serif; text-transform: none; resize: vertical; }
.editor-grid textarea { min-height: 76px; }
.editor-grid label.full:last-child textarea { min-height: 118px; }
.editor-section-head { display: flex; justify-content: space-between; align-items: end; gap: 18px; margin: 26px 0 12px; }
.editor-section-head h3 { margin: 0; font-size: 15px; }
.editor-section-head p { max-width: 680px; margin: 5px 0 0; color: var(--muted); font-size: 12px; line-height: 1.45; }
.slide-editor-list { display: grid; gap: 10px; }
.slide-editor { display: grid; grid-template-columns: 170px minmax(180px, .7fr) minmax(260px, 1.3fr); gap: 12px; padding: 13px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); }
.slide-editor header { grid-column: 1 / -1; display: flex; justify-content: space-between; align-items: center; min-height: 30px; }
.slide-editor header strong { font-size: 12px; }
.slide-editor header > div { display: flex; gap: 5px; }
.slide-editor textarea { min-height: 86px; line-height: 1.45; }
.slide-editor label:nth-of-type(2) textarea { min-height: 60px; }
.source-editor-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.source-editor { display: grid; gap: 10px; padding: 14px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); }
.source-editor strong { font-size: 12px; }
.source-editor textarea { min-height: 96px; line-height: 1.45; }
.cta-lock { display: flex; gap: 11px; align-items: center; margin-top: 10px; padding: 14px; color: #dce9e5; background: var(--sidebar); }
.cta-lock svg { flex: 0 0 auto; width: 18px; height: 18px; }
.cta-lock strong, .cta-lock span { display: block; }
.cta-lock strong { color: #fff; font-size: 12px; }
.cta-lock span { margin-top: 3px; font-size: 11px; }
.editor-actions { position: sticky; bottom: 0; display: flex; justify-content: flex-end; gap: 9px; margin: 22px -22px -22px; padding: 14px 22px; border-top: 1px solid var(--line); background: var(--paper); }

.outreach-view { display: grid; gap: 20px; }
.outreach-hero { min-height: 158px; padding: 25px; display: flex; align-items: flex-end; justify-content: space-between; gap: 22px; border: 1px solid #b9d8cf; border-left: 6px solid var(--sage); border-radius: var(--radius); background: #e8f4f0; }
.outreach-hero h2 { margin: 7px 0 5px; font-size: 25px; line-height: 1.13; }
.outreach-hero p { max-width: 720px; margin: 0; color: #405057; font-size: 13px; line-height: 1.5; }
.outreach-hero .button { flex: 0 0 auto; }
.prospecting-hero { border-color: #b9d1dc; border-left-color: #2d7188; background: #edf5f8; }
.prospecting-hero .button { background: #2d7188; }
.prospecting-hero .button:hover { background: #20586d; }
.outreach-workspace, .outreach-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(300px, .75fr); gap: 20px; align-items: start; }
.outreach-composer form { display: grid; gap: 14px; padding: 18px; }
.outreach-composer .panel-head kbd { padding: 5px 7px; border: 1px solid var(--line); border-radius: 4px; color: var(--muted); background: #f7f8f6; font: 10px "DM Mono", monospace; white-space: nowrap; }
.outreach-focus-note { display: grid; gap: 4px; padding: 12px 13px; border-left: 3px solid var(--accent); background: #fff7f2; }
.outreach-focus-note strong { font-size: 12px; }
.outreach-focus-note span { color: #405057; font-size: 12px; line-height: 1.45; }
.outreach-composer textarea { min-height: 108px; resize: vertical; }
.outreach-composer input, .outreach-composer textarea, .outreach-composer select, .outreach-account-form input, .outreach-account-form select { width: 100%; min-height: 39px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 4px; color: var(--ink); background: #fff; resize: vertical; }
.outreach-form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.outreach-compose-actions { display: flex; align-items: center; justify-content: space-between; gap: 15px; }
.outreach-compose-actions span { max-width: 470px; color: var(--muted); font-size: 12px; line-height: 1.45; }
.outreach-principles ol { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; }
.outreach-principles li { display: grid; grid-template-columns: 26px minmax(0, 1fr); align-items: center; gap: 10px; padding: 14px 17px; border-bottom: 1px solid var(--line); color: #405057; font-size: 12px; line-height: 1.4; }
.outreach-principles li b { display: grid; width: 24px; height: 24px; place-items: center; color: var(--sage); background: #e3f1ed; border-radius: 50%; font: 700 10px "DM Mono", monospace; }
.outreach-rule { display: flex; align-items: center; gap: 9px; padding: 14px 17px; color: var(--sage); background: #edf7f4; font-size: 12px; line-height: 1.4; }
.outreach-rule svg { flex: 0 0 auto; width: 17px; height: 17px; }
.outreach-draft-list, .outreach-account-list { display: grid; }
.outreach-draft { padding: 16px 18px; border-bottom: 1px solid var(--line); }
.outreach-draft:last-child, .outreach-account:last-child { border-bottom: 0; }
.outreach-draft.sent { background: #f8fbf9; }
.outreach-draft header, .outreach-draft footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.outreach-draft header span { color: var(--sage); font: 700 10px "DM Mono", monospace; text-transform: uppercase; }
.outreach-draft header small { overflow: hidden; color: var(--muted); font: 10px "DM Mono", monospace; text-overflow: ellipsis; white-space: nowrap; }
.outreach-draft p { margin: 12px 0 15px; color: #22343c; font-size: 14px; line-height: 1.55; }
.outreach-draft footer { justify-content: flex-start; flex-wrap: wrap; }
.outreach-draft footer .button { min-height: 34px; }
.outreach-account-form { display: grid; grid-template-columns: minmax(180px, 1.45fr) minmax(145px, 1fr) minmax(110px, .7fr) auto; gap: 10px; align-items: end; padding: 15px 17px; border-bottom: 1px solid var(--line); background: #fffdf8; }
.outreach-account-form .field.full { grid-column: 1 / -2; }
.outreach-account-form .button { min-height: 39px; }
.outreach-account { min-height: 86px; padding: 14px 17px; display: flex; align-items: center; justify-content: space-between; gap: 14px; border-bottom: 1px solid var(--line); }
.outreach-account-main { min-width: 0; display: flex; align-items: center; gap: 11px; }
.outreach-avatar { width: 34px; height: 34px; flex: 0 0 auto; display: grid; place-items: center; color: white; background: var(--sidebar); font: 700 15px "DM Mono", monospace; }
.outreach-account-head { display: flex; align-items: center; gap: 8px; }
.outreach-account-head strong { overflow: hidden; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.outreach-priority { padding: 3px 5px; color: #405057; background: #e8eeeb; font: 700 9px "DM Mono", monospace; text-transform: uppercase; white-space: nowrap; }
.outreach-priority.high { color: #93401f; background: #ffe0d4; }
.outreach-priority.low { color: #647176; background: #eef0ef; }
.prospecting-status, .prospecting-source { color: #2d7188; font: 700 9px "DM Mono", monospace; text-transform: uppercase; white-space: nowrap; }
.prospecting-status { padding: 3px 5px; background: #dfeff4; }
.prospecting-status.contacted { color: #24584e; background: #e3f1ed; }
.prospecting-status.archived { color: #647176; background: #eef0ef; }
.prospecting-status-select { min-height: 32px; max-width: 112px; padding: 5px 7px; border: 1px solid var(--line); border-radius: 4px; color: var(--ink); background: #fff; font: 700 10px "DM Mono", monospace; }
.prospecting-lead.archived { opacity: .62; }
.outreach-account p, .outreach-account small { display: block; margin: 4px 0 0; color: var(--muted); font-size: 11px; line-height: 1.35; }
.outreach-account small { max-width: 410px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.outreach-account-actions { display: flex; flex: 0 0 auto; gap: 6px; }
.outreach-account-actions .icon-button { width: 32px; height: 32px; }
.outreach-empty { min-height: 132px; display: grid; place-items: center; gap: 8px; padding: 22px; text-align: center; }
.outreach-empty svg { width: 23px; height: 23px; color: var(--muted); }
.outreach-empty p { max-width: 460px; margin: 0; color: var(--muted); font-size: 12px; line-height: 1.45; }
.comment-inbox-panel { overflow: hidden; border: 1px solid #b9d8cf; background: var(--surface); }
.comment-inbox-head { min-height: 106px; padding: 18px 20px; display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; border-bottom: 1px solid var(--line); background: #f4faf7; }
.comment-inbox-head h2 { margin: 5px 0 4px; font-size: 19px; }
.comment-inbox-head p { margin: 0; color: var(--muted); font-size: 11px; }
.comment-inbox-count { min-width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; color: white; background: var(--accent); font: 700 14px "DM Mono", monospace; }
.comment-inbox-alert { display: flex; align-items: flex-start; gap: 10px; padding: 13px 18px; color: #8a451e; background: #fff3df; border-bottom: 1px solid #f0d5a2; font-size: 12px; line-height: 1.45; }
.comment-inbox-alert svg { width: 18px; flex: 0 0 auto; }
.comment-thread-stack { display: grid; }
.comment-thread { display: grid; grid-template-columns: minmax(290px, .73fr) minmax(0, 1.27fr); border-bottom: 1px solid var(--line); }
.comment-thread:last-child { border-bottom: 0; }
.ig-post-preview { min-width: 0; padding: 16px; border-right: 1px solid var(--line); background: #fbfcfa; }
.ig-post-preview > header { display: flex; align-items: center; gap: 9px; padding-bottom: 12px; }
.ig-post-preview > header > div:nth-child(2) { min-width: 0; display: grid; gap: 2px; }
.ig-post-preview > header strong { overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.ig-post-preview > header span { color: var(--muted); font: 10px "DM Mono", monospace; }
.ig-post-preview > header .icon-button { width: 30px; height: 30px; margin-left: auto; }
.ig-profile-mark { width: 30px; height: 30px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 50%; color: white; background: var(--sidebar); font: 700 12px "DM Mono", monospace; }
.ig-media-scroller { max-height: 520px; display: grid; gap: 8px; overflow-y: auto; scrollbar-width: thin; scroll-snap-type: y proximity; border: 1px solid var(--line); background: #edf0ee; }
.ig-media-scroller img { width: 100%; display: block; scroll-snap-align: start; object-fit: contain; background: #edf0ee; }
.ig-media-empty { min-height: 300px; display: grid; place-items: center; gap: 8px; padding: 24px; color: var(--muted); text-align: center; border: 1px solid var(--line); background: #f0f3f1; font-size: 12px; }
.ig-media-empty svg { width: 24px; }
.ig-post-copy { padding: 12px 2px 2px; }
.ig-post-copy strong { font-size: 13px; line-height: 1.35; }
.ig-post-copy p { margin: 6px 0 0; color: #405057; font-size: 12px; line-height: 1.45; white-space: pre-line; }
.comment-thread-list { min-width: 0; }
.comment-thread-head { min-height: 88px; display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 16px 18px; border-bottom: 1px solid var(--line); }
.comment-thread-head h3 { max-width: 620px; margin: 4px 0 0; font-size: 15px; line-height: 1.32; }
.comment-thread-head > span { flex: 0 0 auto; color: var(--accent); font: 700 10px "DM Mono", monospace; text-transform: uppercase; white-space: nowrap; }
.comment-card { padding: 16px 18px; border-bottom: 1px solid var(--line); }
.comment-card:last-child { border-bottom: 0; }
.comment-card.handled { background: #f8fbf9; }
.comment-card.confirmation_needed { background: #fffaf0; }
.comment-card header { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.comment-author { min-width: 0; display: flex; align-items: center; gap: 9px; }
.comment-author > span { width: 30px; height: 30px; flex: 0 0 auto; display: grid; place-items: center; color: var(--sage); background: #e3f1ed; border-radius: 50%; font: 700 12px "DM Mono", monospace; }
.comment-author div { min-width: 0; display: grid; gap: 2px; }
.comment-author strong { overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.comment-author small { color: var(--muted); font: 10px "DM Mono", monospace; }
.comment-meta { display: flex; align-items: center; justify-content: flex-end; gap: 7px; color: var(--muted); font: 10px "DM Mono", monospace; }
.comment-meta > span:last-child { display: inline-flex; align-items: center; gap: 3px; }
.comment-meta svg { width: 12px; height: 12px; }
.comment-kind { padding: 4px 6px; color: #405057; background: #edf0ef; text-transform: uppercase; white-space: nowrap; }
.comment-card > p { margin: 13px 0 14px; color: #18333c; font-size: 14px; line-height: 1.52; white-space: pre-wrap; }
.comment-reply-box { display: grid; gap: 9px; }
.comment-suggestions { display: flex; flex-wrap: wrap; gap: 6px; }
.comment-suggestion { border: 1px solid #c9d9d4; border-radius: 999px; min-height: 28px; padding: 0 9px; color: #28584f; background: #eef7f3; font-size: 11px; }
.comment-suggestion:hover { border-color: #7daea1; background: #e3f1ed; }
.comment-reply-box textarea { width: 100%; min-height: 86px; padding: 10px 11px; border: 1px solid var(--line); border-radius: 4px; color: var(--ink); background: white; font: inherit; font-size: 13px; line-height: 1.45; resize: vertical; }
.comment-reply-box textarea:focus { border-color: var(--ink); box-shadow: 0 0 0 2px rgba(20,34,43,.1); outline: none; }
.comment-actions { display: flex; align-items: center; justify-content: flex-end; gap: 7px; flex-wrap: wrap; }
.comment-actions .icon-button { width: 34px; height: 34px; margin-right: auto; }
.comment-actions .button { min-height: 34px; }
.comment-sent, .comment-handled, .comment-confirmation { display: flex; align-items: flex-start; gap: 8px; padding: 10px 11px; font-size: 12px; line-height: 1.45; }
.comment-sent { color: #24584e; background: #e9f5ef; }
.comment-handled { color: var(--muted); background: #eff2f0; }
.comment-confirmation { color: #8a451e; background: #fff0d5; }
.comment-sent svg, .comment-handled svg, .comment-confirmation svg { width: 16px; height: 16px; flex: 0 0 auto; }
.comment-inbox-empty { min-height: 220px; }

* { letter-spacing: 0 !important; }

.toast-region { position: fixed; right: 20px; bottom: 20px; z-index: 50; display: grid; gap: 8px; max-width: min(390px, calc(100vw - 40px)); }
.toast { background: var(--ink); color: white; padding: 12px 14px; border-radius: 6px; box-shadow: 0 12px 32px rgba(20,34,43,.22); font-size: 13px; line-height: 1.35; }
.toast.error { background: var(--danger); }
.data-freshness { min-height: 30px; margin-top: 26px; display: flex; align-items: center; justify-content: flex-end; gap: 7px; color: var(--muted); font-size: 11px; }
.data-freshness svg { width: 14px; height: 14px; }
.health-hero { min-height: 148px; padding: 25px; display: flex; align-items: flex-end; justify-content: space-between; gap: 22px; border-left: 6px solid var(--sage); background: #e8f4f0; }
.health-hero.degraded { border-color: var(--warning); background: #fff7e4; }
.health-hero.critical { border-color: var(--danger); background: #fff1ed; }
.health-hero.paused { border-color: var(--muted); background: #ecefed; }
.health-hero h2 { margin: 7px 0 5px; font-size: 25px; }
.health-hero p { max-width: 680px; margin: 0; color: #405057; font-size: 13px; line-height: 1.5; }
.health-layout { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(280px, .65fr); gap: 20px; margin-top: 20px; }
.health-checks, .runtime-summary, .activity-log { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.section-title { min-height: 67px; padding: 15px 17px; display: flex; align-items: center; justify-content: space-between; gap: 15px; border-bottom: 1px solid var(--line); }
.section-title h3 { margin: 0; font-size: 14px; }
.section-title p { margin: 4px 0 0; color: var(--muted); font-size: 11px; line-height: 1.4; }
.section-title > span { color: var(--muted); font: 10px "DM Mono", monospace; white-space: nowrap; }
.health-check { min-height: 69px; padding: 13px 17px; display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; align-items: center; gap: 11px; border-bottom: 1px solid var(--line); }
.health-check:last-child { border-bottom: 0; }
.check-mark { width: 27px; height: 27px; display: grid; place-items: center; border-radius: 50%; color: var(--sage); background: #e4f2ee; }
.health-check.warning .check-mark { color: var(--warning); background: #fff0cb; }
.health-check.error .check-mark { color: var(--danger); background: #fde5df; }
.health-check.paused .check-mark { color: var(--muted); background: #e8ebea; }
.check-mark svg { width: 15px; height: 15px; }
.health-check strong { font-size: 12px; }
.health-check p { margin: 4px 0 0; color: var(--muted); font-size: 11px; line-height: 1.4; }
.check-state { color: var(--sage); font: 700 9px "DM Mono", monospace; text-transform: uppercase; }
.health-check.warning .check-state { color: var(--warning); }
.health-check.error .check-state { color: var(--danger); }
.runtime-summary dl { margin: 0; }
.runtime-summary dl div { padding: 13px 17px; display: flex; justify-content: space-between; gap: 14px; border-bottom: 1px solid var(--line); }
.runtime-summary dl div:last-child { border-bottom: 0; }
.runtime-summary dt { color: var(--muted); font-size: 11px; }
.runtime-summary dd { margin: 0; max-width: 58%; overflow: hidden; color: var(--ink); font: 700 10px "DM Mono", monospace; text-align: right; text-overflow: ellipsis; white-space: nowrap; }
.activity-log { margin-top: 20px; }
.activity-row { min-height: 52px; padding: 10px 17px; display: flex; align-items: center; gap: 11px; border-bottom: 1px solid var(--line); }
.activity-row:last-child { border-bottom: 0; }
.activity-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--sage); }
.activity-row strong, .activity-row small { display: block; }
.activity-row strong { font-size: 12px; text-transform: capitalize; }
.activity-row small { margin-top: 3px; color: var(--muted); font: 10px "DM Mono", monospace; }
.job-alert { display: flex; align-items: center; gap: 9px; padding: 13px 17px; color: var(--warning); background: #fff8e8; font-size: 12px; }
.job-alert svg { width: 16px; height: 16px; }
.status.publishing::before { background: var(--warning); animation: pulse 1.4s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .35; } }

@media (max-width: 1180px) {
  .control-band, .overview-grid { grid-template-columns: 1fr; }
  .quick-composer { border-top: 1px solid var(--line); border-left: 0; }
  .quick-composer div { max-width: 680px; }
}

@media (max-width: 900px) {
  .app-shell { grid-template-columns: 1fr; }
  .sidebar { position: sticky; top: 0; z-index: 10; flex-direction: row; align-items: center; gap: 12px; padding: 11px 14px; min-height: 60px; }
  .sidebar .nav { display: flex; margin-left: auto; }
  .nav-button { width: 40px; padding: 0; justify-content: center; }
  .nav-button span, .brand-subtitle, .sidebar-foot { display: none; }
  .main { padding-top: 22px; }
  .metrics { grid-template-columns: repeat(2, 1fr); }
  .metric:nth-child(2) { border-right: 0; }
  .metric:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .control-band, .overview-grid, .settings-grid, .modal-body, .health-layout, .growth-layout, .outreach-workspace, .outreach-grid, .comment-thread { grid-template-columns: 1fr; }
  .ig-post-preview { border-right: 0; border-bottom: 1px solid var(--line); }
  .growth-channel-grid { grid-template-columns: 1fr; }
  .slide-editor { grid-template-columns: 1fr 1fr; }
  .slide-editor label:last-child { grid-column: 1 / -1; }
}

@media (max-width: 620px) {
  .app-shell { padding-bottom: 64px; }
  .sidebar { position: fixed; inset: auto 0 0; min-height: 62px; height: 62px; padding: 8px 9px; border-top: 1px solid rgba(255,255,255,.16); }
  .sidebar .brand, .sidebar-foot { display: none; }
  .sidebar .nav { width: 100%; margin: 0; justify-content: space-between; }
  .nav-button { position: relative; flex: 1; width: auto; min-width: 0; }
  .nav-health { position: absolute; top: 7px; right: calc(50% - 14px); }
  .main { padding: 18px 14px 34px; }
  .topbar { width: 100%; align-items: stretch; flex-direction: column; margin-bottom: 26px; }
  .top-actions { width: 100%; align-items: stretch; flex-direction: column; }
  .top-actions .button { width: 100%; }
  .automation-state { display: none; }
  .health-banner { grid-template-columns: 32px minmax(0, 1fr); }
  .health-banner .button { grid-column: 1 / -1; width: 100%; }
  .health-hero { min-height: 0; align-items: flex-start; flex-direction: column; padding: 20px; }
  .health-hero .autopilot-controls { width: 100%; display: grid; grid-template-columns: 1fr; }
  .health-hero .button { width: 100%; }
  .growth-hero { min-height: 0; align-items: flex-start; flex-direction: column; padding: 20px; }
  .growth-hero-actions { width: 100%; justify-content: stretch; flex-direction: column; }
  .growth-hero-actions .button { width: 100%; }
  .outreach-hero { min-height: 0; align-items: flex-start; flex-direction: column; padding: 20px; }
  .outreach-hero .button { width: 100%; }
  .outreach-metrics { grid-template-columns: repeat(2, 1fr); }
  .outreach-form-grid, .outreach-account-form { grid-template-columns: 1fr; }
  .outreach-account-form .field.full { grid-column: auto; }
  .outreach-account-form .button { width: 100%; }
  .outreach-compose-actions { align-items: stretch; flex-direction: column; }
  .outreach-compose-actions .button { width: 100%; }
  .outreach-account { align-items: flex-start; }
  .outreach-account-actions { flex-wrap: wrap; justify-content: flex-end; }
  .outreach-account small { max-width: 210px; }
  .comment-inbox-head { min-height: 0; padding: 16px; }
  .comment-thread-head, .comment-card { padding-left: 15px; padding-right: 15px; }
  .comment-thread-head { align-items: flex-start; flex-direction: column; }
  .comment-thread-head > span { white-space: normal; }
  .ig-post-preview { padding: 14px; }
  .ig-media-scroller { max-height: 430px; }
  .comment-card header { align-items: flex-start; }
  .comment-meta { flex-wrap: wrap; }
  .comment-actions { align-items: stretch; }
  .comment-actions .button { flex: 1; }
  .growth-number-grid, .growth-links { grid-template-columns: 1fr; }
  .reel-summary { grid-template-columns: 1fr; }
  .reel-summary > div { border-right: 0; border-bottom: 1px solid var(--line); }
  .reel-summary > div:last-child { border-bottom: 0; }
  .traffic-sources { grid-template-columns: repeat(2, 1fr); }
  .traffic-sources > div:nth-child(2n) { border-right: 0; }
  .growth-indexnow { align-items: flex-start; flex-direction: column; }
.growth-indexnow .button { width: 100%; }
  .growth-links a { border-right: 0; border-bottom: 1px solid var(--line); }
.growth-links a:last-child { border-bottom: 0; }
  .view-intro { align-items: flex-start; flex-direction: column; }
  .view-intro .button { width: 100%; }
  .content-list .content-row { grid-template-columns: 48px minmax(0, 1fr) auto; }
  .content-list .content-row > :nth-child(3), .content-list .content-row > :nth-child(4) { display: none; }
  .topic-create { grid-template-columns: 1fr; align-items: stretch; }
  .topic-create > div { align-items: stretch; flex-direction: column; }
  .topic-create input { min-height: 38px; }
  .quick-composer { padding: 18px; }
  .quick-composer div { align-items: stretch; flex-direction: column; }
  .quick-composer .button { width: 100%; }
  .next-release { align-items: flex-start; flex-direction: column; gap: 18px; padding: 20px; }
  .next-release h2 { font-size: 20px; }
  .release-meta { justify-items: start; text-align: left; }
  .timeline-item { grid-template-columns: 86px minmax(0, 1fr) auto; gap: 10px; padding: 14px; }
  .timeline-copy small { white-space: normal; }
  .content-toolbar { align-items: stretch; flex-direction: column; gap: 0; }
  .content-toolbar > span { padding: 0 0 11px; }
  .library-tools { align-items: stretch; flex-direction: column; }
  .library-tools > span { white-space: normal; }
  .form-grid { grid-template-columns: 1fr; }
  .field.full { grid-column: auto; }
  .calendar-day { grid-template-columns: 110px minmax(0, 1fr); }
  .day-label { padding: 13px; }
  .agenda-grid { grid-template-columns: 1fr; }
  .agenda-post { border-right: 0; }
  .agenda-head { align-items: flex-start; flex-direction: column; }
  .health-check { grid-template-columns: 28px minmax(0, 1fr); }
  .check-state { grid-column: 2; }
  .data-freshness { justify-content: center; }
  .modal-backdrop { padding: 0; place-items: stretch; }
  .modal { max-height: 100vh; border-radius: 0; }
  .post-editor { padding: 16px; }
  .editor-grid, .slide-editor, .source-editor-list { grid-template-columns: 1fr; }
  .editor-grid label.full, .slide-editor label:last-child { grid-column: auto; }
  .editor-section-head { align-items: stretch; flex-direction: column; }
  .editor-section-head .button { width: 100%; }
  .schedule-editor > div { align-items: stretch; flex-direction: column; }
  .editor-actions { margin: 18px -16px -16px; padding: 12px 16px; }
}

/* Studio dark: neutral workspace with a restrained Le Declic accent. */
:root {
  --ink: #f3f6f8;
  --muted: #a6b0b9;
  --paper: #121417;
  --surface: #1a1e23;
  --line: #303841;
  --accent: #16bec8;
  --sage: #4acb9a;
  --warning: #e6b75d;
  --danger: #ee7379;
  --sidebar: #0d0f12;
  --sidebar-muted: #98a4ae;
}
body { background: #121417; background-image: none; }
.sidebar { border-right: 1px solid #292f36; background: #0d0f12; }
.sidebar::before { display: none; }
.main { background: #121417; }
.eyebrow, .metric-label, .quick-composer label, .topic-create label, .content-toolbar > span, .library-tools > span { color: var(--accent); }
.automation-state { color: var(--muted); }
.automation-state:hover { color: var(--ink); background: rgba(22,190,200,.1); }
.button { color: var(--ink); border-color: #3a434c; background: #252b31; }
.button:hover { background: #303941; }
.button.accent { color: #051719; border-color: var(--accent); background: var(--accent); }
.button.accent:hover { background: #39d1d8; }
.button.secondary { color: var(--ink); border-color: #3a434c; background: #1d2228; }
.button.secondary:hover { background: #2a3138; }
.button.danger { color: #fff; border-color: #9e4e56; background: #8d3e47; }
.button.danger:hover { background: #a84853; }
.panel, .metrics, .control-band, .content-list, .health-checks, .runtime-summary, .activity-log, .schedule-editor, .topic-create, .search-field, .quality-score { background: #1a1e23; border-color: #303841; }
.panel-head, .section-title, .modal-head, .content-row, .timeline-item, .signal-row, .metric, .detail-block, .schedule-editor, .quality-score { border-color: #303841; }
.content-row:hover, .timeline-item:hover, .agenda-post:hover { background: #22282f; }
.timeline-item.is-next { background: #202b30; box-shadow: inset 4px 0 0 var(--accent); }
.next-release, .agenda-head { background: #20252b; }
.next-release p, .control-summary p, .comment-row p, .principle-list p, .detail-block p, .confirm-body p { color: var(--muted); }
.quick-composer { background: #181c21; border-color: #303841; }
.quick-composer input, .topic-create input, .search-field input, .schedule-editor input, .login-panel input, .editor-grid input, .editor-grid textarea, .slide-editor input, .slide-editor textarea, .field input, .field textarea, .field select, select { color: var(--ink); background: #111419; border-color: #3a434c; }
.quick-composer input::placeholder, .topic-create input::placeholder, input::placeholder, textarea::placeholder { color: #7f8a94; }
.health-banner { color: var(--ink); border-color: #315b60; border-left-color: var(--accent); background: #1b2529; }
.health-banner.degraded { border-color: #715d34; border-left-color: var(--warning); background: #2b281e; }
.health-banner.critical { border-color: #75484d; border-left-color: var(--danger); background: #2b2023; }
.health-banner.paused { border-color: #45515a; border-left-color: var(--muted); background: #20252a; }
.health-banner p, .health-check p, .section-title p, .runtime-summary dt, .activity-row small { color: var(--muted); }
.type-thumbnail { background: #171b20; border-left-color: var(--accent); }
.type-thumbnail span { color: var(--warning); }
.mode-pill { color: #c7f4f5; background: #174d55; }
.mode-pill.playful { color: #ffe3a5; background: #55451f; }
.mode-pill.story { color: #c9edf0; background: #1b505b; }
.mode-pill.myth { color: #ffd0d1; background: #57383e; }
.filter { color: var(--muted); background: #1a1e23; border-color: #303841; }
.filter.active { color: #07191c; background: var(--accent); border-color: var(--accent); }
.icon-button, .rendered-slide { color: var(--ink); background: #1a1e23; border-color: #3a434c; }
.icon-button:hover { border-color: var(--accent); background: #222a30; }
.modal { background: #181c21; box-shadow: 0 26px 80px rgba(0,0,0,.52); }
.modal-head { background: #181c21; border-color: #303841; }
.text-slide { color: #f3f6f8; background: #1a1e23; }
.text-slide.is-cta { background: #1c292d; }
.text-slide.is-interlude { color: #f3f6f8; background: #24242c; }
.source-link { color: var(--accent); }
.growth-hero, .outreach-hero, .prospecting-hero, .health-hero { background: #1b2529; border-color: #303841; }
.growth-links a, .outreach-account, .outreach-draft, .comment-card, .ig-post-preview, .traffic-source, .reel-summary > div { background: #1a1e23; border-color: #303841; color: var(--ink); }
.growth-links a:hover { color: var(--accent); background: #222a30; }
.data-freshness { color: var(--muted); }

/* Secondary tools use the same quiet dark surfaces instead of isolated light cards. */
.format-pill { color: #bff3ef; border-color: #286f6d; background: #173b3c; }
.reserve-progress { background: #2a3037; }
.calendar-post { background: #1d242a; }
.calendar-post.is-next, .day-tab.active { background: #1d2d2c; }
.agenda-post.is-next { background: #1e2d31; }
.field input, .field textarea, .field select, .theme-add input, .outreach-composer input, .outreach-composer textarea, .outreach-composer select, .outreach-account-form input, .outreach-account-form select, .prospecting-status-select, .comment-reply-box textarea { color: var(--ink); border-color: #3a434c; background: #111419; }
.theme-chip { color: #c6eff0; background: #243138; }
.theme-chip button { color: #c6eff0; }
.switch-track { background: #48515a; }
.switch-track::before { background: #e8edf0; }
.cadence-summary, .growth-indexnow, .comment-inbox-head { background: #20252b; }
.mode-toggle { color: var(--muted); border-color: #3a434c; background: #1a1e23; }
.mode-toggle.active { color: var(--ink); border-color: #397d75; background: #1d3936; }
.growth-hero, .outreach-hero, .prospecting-hero, .health-hero { color: var(--ink); }
.prospecting-hero .button { color: #051719; background: var(--accent); }
.prospecting-hero .button:hover { background: #39d1d8; }
.growth-hero p, .outreach-hero p, .health-hero p, .growth-channel p, .growth-forecast, .outreach-focus-note span, .outreach-principles li, .outreach-draft p, .ig-post-copy p, .comment-card > p, .detail-block p, .confirm-body p, .principle-list p, .comment-row p { color: var(--muted); }
.growth-channel-icon, .comment-author > span, .outreach-principles li b, .check-mark { color: var(--sage); background: #193b33; }
.growth-channel.needs_connection .growth-channel-icon, .health-check.warning .check-mark { color: var(--warning); background: #3d3420; }
.health-check.error .check-mark { color: var(--danger); background: #3d2529; }
.growth-forecast, .outreach-focus-note, .outreach-rule { background: #1d292d; }
.outreach-composer .panel-head kbd { background: #252b31; }
.outreach-draft.sent, .comment-card.handled { background: #1d2825; }
.comment-card.confirmation_needed { background: #2d281e; }
.outreach-account-form { background: #20252b; }
.outreach-priority { color: var(--muted); background: #2a3036; }
.outreach-priority.high { color: #ffd1b7; background: #56342d; }
.outreach-priority.low, .prospecting-status.archived { color: var(--muted); background: #2a3036; }
.prospecting-status { color: #a9e5ed; background: #1b3b46; }
.prospecting-status.contacted { color: #aee7d3; background: #1c3b31; }
.comment-inbox-panel { border-color: #315b60; }
.comment-inbox-alert, .comment-confirmation { color: #ffd99b; border-color: #735a31; background: #372d1e; }
.ig-media-scroller, .ig-media-scroller img { background: #111419; }
.ig-media-empty { background: #20252b; }
.comment-kind { color: #c2ccd3; background: #2b3239; }
.comment-suggestion { color: #bff0e3; border-color: #316a5b; background: #193b33; }
.comment-suggestion:hover { border-color: #4e9f8d; background: #21483d; }
.comment-sent { color: #b8ebd5; background: #1b3d32; }
.comment-handled { color: var(--muted); background: #252c31; }
.job-alert { background: #302a1d; }
.login-page { background: #0d0f12; }
.login-panel { border-color: #303841; background: #1a1e23; }
.toast { color: #111419; background: #eef2f4; }
.toast.error { color: #fff; background: var(--danger); }

/* Content can be removed without opening it. The action remains visible on touch screens. */
.content-row .delete-post { opacity: 0; pointer-events: none; color: #ff9aa0; transform: translateX(4px); transition: opacity .16s ease, transform .16s ease, background .16s ease; }
.content-row.is-manageable:hover .delete-post, .content-row.is-manageable:focus-within .delete-post { opacity: 1; pointer-events: auto; transform: translateX(0); }
.content-row .delete-post:hover { color: #fff; border-color: #b6555f; background: #7d3941; }
@media (hover: none) {
  .content-row .delete-post { opacity: 1; pointer-events: auto; transform: none; }
}
