:root {
  --bg: #0b1020;
  --panel: #131a2e;
  --panel-2: #0f1527;
  --text: #eef2ff;
  --muted: #9da8c6;
  --line: #263252;
  --accent: #77b4ff;
  --success: #1d8f5f;
  --error: #a64040;
  --warning: #9f7b2f;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  background: linear-gradient(180deg, #0b1020, #090d18 45%, #06080f);
  color: var(--text);
  font: 16px/1.5 Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
.container { width: min(1120px, calc(100% - 32px)); margin: 0 auto; }
.topbar { border-bottom: 1px solid var(--line); background: rgba(8,12,25,.75); backdrop-filter: blur(8px); position: sticky; top: 0; z-index: 10; }
.topbar-inner { display: flex; align-items: center; justify-content: space-between; min-height: 68px; gap: 24px; }
.brand { font-weight: 800; color: #fff; font-size: 1.15rem; }
.nav { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.inline-form { display: inline; }
.link-button { background: none; border: 0; color: var(--accent); cursor: pointer; font: inherit; padding: 0; }
main.container { padding: 28px 0 60px; }
.panel {
  background: linear-gradient(180deg, rgba(19,26,46,.96), rgba(10,16,31,.96));
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 22px;
  box-shadow: 0 18px 40px rgba(0,0,0,.18);
}
.hero-panel { padding: 40px; margin-bottom: 24px; }
.hero-panel h1, .public-header h1 { margin-top: 0; font-size: clamp(2rem, 4vw, 3.35rem); line-height: 1.05; }
.eyebrow { margin: 0 0 8px; letter-spacing: .11em; text-transform: uppercase; color: #9dc1ff; font-size: .78rem; }
.actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 16px; }
.button, button.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  background: var(--accent); color: #08111f; border: 0; border-radius: 12px;
  min-height: 42px; padding: 0 16px; font-weight: 700; cursor: pointer; text-decoration: none;
}
.button-secondary { background: transparent; color: var(--text); border: 1px solid var(--line); }
.button-danger { background: #b94747; color: #fff; }
.grid { display: grid; gap: 20px; }
.two-up { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); margin-bottom: 24px; }
.stats-grid { grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); margin-bottom: 24px; }
.stat-card { display: flex; flex-direction: column; gap: 8px; }
.stat-card strong { font-size: 2rem; }
.section-header, .dashboard-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.form-grid .full { grid-column: 1 / -1; }
label { display: flex; flex-direction: column; gap: 8px; color: var(--muted); }
input, select, textarea {
  width: 100%; background: #0b1020; color: var(--text); border: 1px solid var(--line);
  border-radius: 12px; padding: 12px 14px; font: inherit;
}
textarea { resize: vertical; }
.checkbox-row { flex-direction: row; align-items: center; }
.checkbox-row input { width: auto; }
.table { width: 100%; border-collapse: collapse; }
.table th, .table td { padding: 12px 10px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.table.compact th, .table.compact td { padding: 9px 8px; }
.flash { margin-bottom: 16px; padding: 14px 16px; border-radius: 12px; }
.flash-success { background: rgba(29,143,95,.16); border: 1px solid rgba(29,143,95,.35); }
.flash-error { background: rgba(166,64,64,.16); border: 1px solid rgba(166,64,64,.35); }
.flash-warning { background: rgba(159,123,47,.16); border: 1px solid rgba(159,123,47,.35); }
.public-header { padding: 28px 0 12px; }
.section-card { margin-bottom: 16px; }
.badge { display: inline-block; min-width: 0; margin-bottom: 10px; padding: 5px 10px; border-radius: 999px; background: rgba(119,180,255,.12); border: 1px solid rgba(119,180,255,.35); color: #a5cbff; font-size: .82rem; }
.auth-wrap { display: grid; place-items: center; min-height: calc(100vh - 170px); }
.auth-card { width: min(440px, 100%); }
.muted { color: var(--muted); }
.danger-zone { margin-top: 24px; border-color: rgba(185,71,71,.4); }
ul { padding-left: 20px; }
@media (max-width: 760px) {
  .form-grid { grid-template-columns: 1fr; }
}


.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  font-weight: 800;
}
.brand-wordmark { height: 28px; display: block; }
.brand-subline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(79,70,229,.18);
  border: 1px solid rgba(255,255,255,.12);
  color: #dfe4ff;
  font-size: .75rem;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.hidden-form { display: none; }
.studio-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}
.studio-hero-copy { max-width: 740px; }
.studio-grid {
  display: grid;
  grid-template-columns: minmax(280px, 340px) minmax(0, 1fr);
  gap: 20px;
}
.studio-context-panel,
.studio-chat-panel {
  min-height: 620px;
}
.studio-context-form {
  display: grid;
  gap: 14px;
  margin-bottom: 16px;
}
.studio-mini-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 16px;
  margin-bottom: 12px;
  border-radius: 14px;
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.07);
}
.studio-mini-card strong { color: #fff; }
.studio-quick-actions {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}
.studio-chat-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}
.studio-chat-log {
  min-height: 420px;
  max-height: 620px;
  overflow-y: auto;
  padding: 16px;
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.04), rgba(255,255,255,.01)),
    #0b1020;
  border: 1px solid rgba(255,255,255,.08);
}
.studio-chat-empty {
  display: grid;
  place-items: center;
  min-height: 260px;
  color: var(--muted);
  text-align: center;
}
.studio-message {
  display: flex;
  margin-bottom: 16px;
}
.studio-message.user { justify-content: flex-end; }
.studio-message.assistant { justify-content: flex-start; }
.studio-bubble {
  max-width: min(84%, 760px);
  padding: 14px 16px;
  border-radius: 18px;
  border: 1px solid rgba(255,255,255,.08);
  box-shadow: 0 12px 24px rgba(0,0,0,.16);
}
.studio-message.user .studio-bubble {
  background: linear-gradient(180deg, rgba(79,70,229,.88), rgba(67,56,202,.88));
  color: #fff;
}
.studio-message.assistant .studio-bubble {
  background: linear-gradient(180deg, rgba(30,41,59,.96), rgba(15,23,42,.96));
  color: var(--text);
}
.studio-bubble-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
  font-size: .82rem;
  color: #cad6ff;
}
.studio-bubble-text {
  white-space: pre-wrap;
}
.studio-action-list {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}
.studio-action-card {
  padding: 12px;
  border-radius: 14px;
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.08);
}
.studio-action-card strong {
  display: block;
  margin-bottom: 4px;
}
.studio-action-card p {
  margin: 0 0 10px;
  color: var(--muted);
}
.studio-action-card .actions {
  margin-top: 0;
}
.studio-warning-list {
  margin: 12px 0 0;
  padding-left: 18px;
  color: #f2d49a;
}
.studio-suggestion-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 16px;
}
.studio-chip-button {
  appearance: none;
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.04);
  color: var(--text);
  border-radius: 999px;
  padding: 10px 14px;
  cursor: pointer;
  font: inherit;
}
.studio-chat-input {
  display: flex;
  gap: 12px;
  margin-top: 18px;
}
.studio-chat-input input {
  flex: 1;
}
@media (max-width: 980px) {
  .studio-grid {
    grid-template-columns: 1fr;
  }
  .studio-context-panel,
  .studio-chat-panel {
    min-height: 0;
  }
}

.install-check-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin-top: 18px;
}
.install-check {
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.03);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.install-check.ok {
  border-color: rgba(29,143,95,.35);
  background: rgba(29,143,95,.08);
}
.install-check.warn {
  border-color: rgba(159,123,47,.35);
  background: rgba(159,123,47,.10);
}
.install-check strong {
  font-size: .95rem;
}
.install-check span,
.field-help,
.install-note {
  color: var(--muted);
}
.field-help {
  font-size: .88rem;
}
.install-note {
  margin: -6px 0 16px;
}

.install-check-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin-top: 18px;
}
.install-check {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.03);
}
.install-check.ok { border-color: rgba(29,143,95,.35); }
.install-check.warn { border-color: rgba(159,123,47,.35); }
.install-form-shell { display: grid; gap: 24px; }
.install-step-block {
  display: grid;
  gap: 16px;
  padding-bottom: 20px;
  border-bottom: 1px solid rgba(255,255,255,.07);
}
.install-step-block:last-of-type { border-bottom: 0; padding-bottom: 0; }
.installer-helper-cards,
.theme-catalog-grid,
.starter-kit-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}
.installer-helper-card,
.theme-catalog-card,
.workflow-card,
.sub-panel {
  padding: 14px 16px;
  border-radius: 14px;
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.08);
}
.theme-catalog-card.active { border-color: rgba(119,180,255,.45); background: rgba(119,180,255,.08); }
.theme-catalog-card strong,
.installer-helper-card strong { display: block; margin-bottom: 6px; }
.field-help { color: var(--muted); }
.install-advanced-block > summary { cursor: pointer; font-weight: 700; }
.install-advanced-block[open] { display: grid; gap: 16px; }
.compact-gap { margin-bottom: 10px; }
.admin-flow-list { margin: 0; padding-left: 18px; display: grid; gap: 8px; }
.starter-kit-overview { margin-top: 22px; }
.studio-section-outline {
  margin-top: 16px;
  padding: 14px 16px;
  border-radius: 14px;
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.08);
}
.studio-section-outline ul,
.recent-ai-log-list { margin: 10px 0 0; padding-left: 18px; }
.recent-ai-log-list li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}
.studio-log-panel {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid rgba(255,255,255,.08);
}
code {
  padding: 2px 6px;
  border-radius: 8px;
  background: rgba(255,255,255,.08);
}
.dual-mode-grid { margin-bottom: 24px; }
.mode-card h2 { margin-top: 0; }
.operator-mode { border-color: rgba(119,180,255,.22); }
.classic-mode { border-color: rgba(255,255,255,.12); }
.compact-list { margin: 10px 0 0; padding-left: 18px; display: grid; gap: 6px; }
.compact-actions { margin-top: 10px; }


.operator-overlay-toggle {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 60;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 54px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.14);
  background: linear-gradient(180deg, rgba(79,70,229,.96), rgba(55,48,163,.96));
  color: #fff;
  font: inherit;
  font-weight: 700;
  box-shadow: 0 16px 30px rgba(0,0,0,.28);
  cursor: pointer;
}
.operator-overlay-toggle-mark {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: rgba(255,255,255,.16);
  font-size: .9rem;
  font-weight: 800;
}
.operator-overlay-panel {
  position: fixed;
  right: 24px;
  bottom: 88px;
  width: min(430px, calc(100vw - 24px));
  max-width: calc(100vw - 24px);
  z-index: 59;
  opacity: 0;
  pointer-events: none;
  transform: translateY(18px) scale(.98);
  transition: opacity .16s ease, transform .16s ease;
}
.operator-overlay-panel.is-open {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}
.operator-overlay-shell {
  border-radius: 22px;
  border: 1px solid rgba(255,255,255,.1);
  background: linear-gradient(180deg, rgba(19,26,46,.98), rgba(10,16,31,.98));
  box-shadow: 0 26px 60px rgba(0,0,0,.35);
  padding: 18px;
}
.operator-overlay-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}
.operator-overlay-header h2 {
  margin: 0;
  font-size: 1.05rem;
}
.operator-overlay-subline {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: .9rem;
}
.operator-overlay-context-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}
.operator-overlay-context-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px;
  border-radius: 14px;
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.06);
}
.operator-overlay-context-card strong { font-size: .82rem; color: #dce5ff; }
.operator-overlay-suggestions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.operator-overlay-log {
  min-height: 290px;
  max-height: min(46vh, 520px);
  overflow-y: auto;
  padding: 14px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255,255,255,.04), rgba(255,255,255,.01)), #0b1020;
  border: 1px solid rgba(255,255,255,.08);
}
.operator-overlay-input {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  margin-top: 14px;
}
.operator-overlay-footer {
  margin-top: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.studio-inline-note {
  margin-bottom: 24px;
}
.studio-inline-note p { margin: 8px 0 0; }
@media (max-width: 900px) {
  .operator-overlay-context-grid { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .operator-overlay-toggle {
    right: 16px;
    bottom: 16px;
  }
  .operator-overlay-panel {
    right: 12px;
    left: 12px;
    bottom: 78px;
    width: auto;
    max-width: none;
  }
  .operator-overlay-header,
  .operator-overlay-footer,
  .operator-overlay-input {
    grid-template-columns: 1fr;
    display: grid;
  }
}

body[data-ui-theme="light"] {
  --bg: #eef2fb;
  --panel: #ffffff;
  --panel-2: #f7f9fe;
  --text: #101828;
  --muted: #5a6474;
  --line: #d5dceb;
  --accent: #4f46e5;
}
body[data-ui-theme="light"] {
  background: linear-gradient(180deg, #eef2fb, #f6f8fd 52%, #edf1f8);
}
body[data-ui-theme="light"] .topbar,
body[data-ui-theme="light"] .panel,
body[data-ui-theme="light"] .panel-lite,
body[data-ui-theme="light"] .studio-nav-link,
body[data-ui-theme="light"] .studio-mobile-tabs,
body[data-ui-theme="light"] .operator-overlay-panel,
body[data-ui-theme="light"] .studio-canvas-frame,
body[data-ui-theme="light"] .studio-visual-grid .panel,
body[data-ui-theme="light"] .theme-catalog-card,
body[data-ui-theme="light"] .wizard-choice-card {
  box-shadow: 0 10px 35px rgba(16, 24, 40, .08);
}
body[data-ui-theme="light"] input,
body[data-ui-theme="light"] select,
body[data-ui-theme="light"] textarea {
  background: #fff;
}

.panel-lite {
  background: linear-gradient(180deg, rgba(15,23,42,.94), rgba(11,18,32,.94));
  border: 1px solid rgba(148,163,184,.16);
  border-radius: 16px;
  box-shadow: 0 18px 40px rgba(0,0,0,.16);
}
.brand-sidebar { width: 100%; justify-content: flex-start; }
.brand-mark {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  object-fit: cover;
  box-shadow: 0 10px 22px rgba(0,0,0,.22);
}
.brand-stack { display: flex; flex-direction: column; gap: 2px; }

.studio-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 18px;
  padding: 18px;
}
.studio-sidebar {
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: sticky;
  top: 18px;
  align-self: start;
  min-height: calc(100vh - 36px);
}
.studio-sidebar-top,
.studio-nav,
.studio-side-note,
.studio-topbar-shell {
  padding: 16px;
}
.studio-nav { display: grid; gap: 10px; }
.studio-nav-link {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(148,163,184,.12);
  background: rgba(11,18,32,.48);
  color: var(--text);
  text-decoration: none;
}
.studio-nav-link strong { color: #fff; font-size: .98rem; }
.studio-nav-link span { color: var(--muted); font-size: .88rem; }
.studio-nav-link.is-active {
  border-color: rgba(99,102,241,.45);
  background: linear-gradient(180deg, rgba(79,70,229,.18), rgba(79,70,229,.08));
}
.studio-main-shell { min-width: 0; display: flex; flex-direction: column; gap: 18px; }
.studio-topbar-shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  position: sticky;
  top: 18px;
  z-index: 20;
}
.shell-title { margin: 0; font-size: clamp(1.4rem, 2vw, 2rem); }
.studio-topbar-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.shell-icon-button {
  appearance: none;
  border: 1px solid rgba(148,163,184,.18);
  background: rgba(255,255,255,.04);
  color: var(--text);
  border-radius: 12px;
  width: 42px;
  height: 42px;
  cursor: pointer;
  font: inherit;
}
.studio-main-content {
  padding-bottom: 92px;
}
.sidebar-pill-row { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.shell-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(79,70,229,.18);
  border: 1px solid rgba(99,102,241,.35);
  font-size: .76rem;
  color: #dbe3ff;
}
.shell-pill-muted {
  background: rgba(255,255,255,.04);
  border-color: rgba(148,163,184,.18);
  color: var(--muted);
}
.studio-mobile-tabs {
  display: none;
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: 14px;
  padding: 8px;
  border-radius: 16px;
  background: rgba(15,23,42,.95);
  border: 1px solid rgba(148,163,184,.18);
  backdrop-filter: blur(12px);
  z-index: 40;
}
.studio-mobile-tab {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  border-radius: 12px;
  color: var(--muted);
  text-decoration: none;
}
.studio-mobile-tab.is-active {
  color: #fff;
  background: rgba(79,70,229,.22);
}

.cogimo-surface-grid,
.studio-visual-grid {
  display: grid;
  gap: 18px;
}
.cogimo-surface-grid {
  grid-template-columns: 1.1fr .9fr;
}
.studio-visual-grid {
  grid-template-columns: 300px minmax(0, 1fr) 360px;
  align-items: start;
}
.studio-column,
.studio-canvas-panel,
.studio-chat-panel,
.studio-context-panel { min-width: 0; }
.studio-canvas-panel {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-height: 680px;
}
.studio-canvas-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.studio-device-switch { display: flex; gap: 8px; flex-wrap: wrap; }
.studio-device-button {
  appearance: none;
  border: 1px solid rgba(148,163,184,.16);
  background: rgba(255,255,255,.04);
  color: var(--text);
  border-radius: 10px;
  padding: 9px 12px;
  cursor: pointer;
  font: inherit;
}
.studio-device-button.is-active {
  background: rgba(79,70,229,.2);
  border-color: rgba(99,102,241,.45);
  color: #fff;
}
.studio-canvas-frame {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  min-height: 560px;
  padding: 18px;
  border-radius: 20px;
  border: 1px solid rgba(148,163,184,.14);
  background: linear-gradient(180deg, rgba(2,6,23,.7), rgba(15,23,42,.46));
  overflow: auto;
}
.studio-canvas-frame iframe {
  width: 100%;
  min-height: 540px;
  border: 0;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 22px 60px rgba(0,0,0,.35);
}
.studio-canvas-frame[data-device="tablet"] iframe {
  max-width: 820px;
}
.studio-canvas-frame[data-device="mobile"] iframe {
  width: 390px;
  max-width: 100%;
}
.studio-outline-card {
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(148,163,184,.12);
}
.studio-outline-list,
.recent-ai-log-list,
.compact-list-tight {
  display: grid;
  gap: 8px;
}
.studio-outline-list { list-style: none; padding: 0; margin: 0; }
.studio-outline-list li {
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(148,163,184,.08);
}
.studio-outline-list strong { display: block; margin-bottom: 2px; }
.studio-mini-card,
.wizard-choice-card,
.theme-catalog-card {
  cursor: default;
}
.wizard-choice-card,
.theme-catalog-card,
.site-card {
  padding: 16px;
  border-radius: 16px;
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(148,163,184,.12);
  transition: border-color .18s ease, transform .18s ease, background .18s ease;
}
.wizard-choice-card:hover,
.theme-catalog-card:hover,
.site-card:hover {
  transform: translateY(-1px);
  border-color: rgba(99,102,241,.3);
}
.wizard-choice-card.is-active,
.theme-catalog-card.is-active,
.site-card.is-active {
  border-color: rgba(99,102,241,.48);
  background: linear-gradient(180deg, rgba(79,70,229,.16), rgba(79,70,229,.06));
}
.theme-catalog-grid,
.starter-kit-grid,
.site-card-grid,
.template-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
}
.site-card-grid.compact { grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.site-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}
.site-card-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 14px; }
.mini-kpi-row { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 12px; }
.mini-kpi {
  padding: 14px;
  border-radius: 14px;
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(148,163,184,.12);
}
.mini-kpi strong { display: block; font-size: 1.5rem; color: #fff; }
.form-card,
.workflow-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.form-hint-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}
.form-hint-card {
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(148,163,184,.1);
}
.empty-state-card {
  padding: 28px;
  text-align: center;
}
.studio-chat-panel {
  min-height: 680px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.studio-chat-log { min-height: 340px; max-height: 520px; }
.operator-overlay-toggle {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 50;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 16px;
  border-radius: 999px;
  border: 1px solid rgba(99,102,241,.35);
  background: linear-gradient(180deg, rgba(15,23,42,.95), rgba(11,18,32,.95));
  color: #fff;
  cursor: pointer;
  box-shadow: 0 18px 40px rgba(0,0,0,.28);
}
.operator-overlay-toggle-mark {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: rgba(79,70,229,.85);
  font-weight: 800;
}
.operator-overlay-panel {
  position: fixed;
  right: 22px;
  bottom: 86px;
  width: min(520px, calc(100vw - 28px));
  max-height: min(82vh, 880px);
  z-index: 55;
  display: none;
}
.operator-overlay-panel.is-open { display: block; }
.operator-overlay-shell {
  padding: 18px;
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(15,23,42,.98), rgba(11,18,32,.98));
  border: 1px solid rgba(148,163,184,.18);
  box-shadow: 0 28px 70px rgba(0,0,0,.35);
}
.operator-overlay-log {
  min-height: 260px;
  max-height: 420px;
  overflow-y: auto;
  margin: 16px 0;
  padding: 14px;
  border-radius: 18px;
  background: rgba(2,6,23,.52);
  border: 1px solid rgba(148,163,184,.12);
}
.operator-overlay-context-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 10px;
  margin: 14px 0;
}
.operator-overlay-context-card {
  padding: 12px;
  border-radius: 14px;
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(148,163,184,.1);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.operator-overlay-suggestions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.operator-overlay-input {
  display: flex;
  gap: 10px;
}
.operator-overlay-input input { flex: 1; }
.operator-overlay-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 12px;
}
.install-check-grid,
.installer-helper-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}
.install-check,
.installer-helper-card {
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(148,163,184,.1);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.install-check.ok { border-color: rgba(29,143,95,.38); }
.install-check.warn { border-color: rgba(159,123,47,.35); }
.install-step-block {
  display: grid;
  gap: 14px;
  padding: 18px 0;
  border-top: 1px solid rgba(148,163,184,.12);
}
.install-step-block:first-of-type { border-top: 0; padding-top: 0; }
.field-help { color: var(--muted); font-size: .84rem; }
.public-stack { display: grid; gap: 18px; }
@media (max-width: 1280px) {
  .studio-shell { grid-template-columns: 270px minmax(0, 1fr); }
  .studio-visual-grid { grid-template-columns: 260px minmax(0, 1fr) 320px; }
}
@media (max-width: 1100px) {
  .studio-shell { grid-template-columns: 1fr; }
  .studio-sidebar { position: static; min-height: auto; }
  .studio-visual-grid,
  .cogimo-surface-grid { grid-template-columns: 1fr; }
  .studio-mobile-tabs { display: flex; }
}
@media (max-width: 760px) {
  .studio-topbar-shell,
  .studio-canvas-toolbar,
  .operator-overlay-input,
  .operator-overlay-footer {
    flex-direction: column;
    align-items: stretch;
  }
  .operator-overlay-context-grid,
  .mini-kpi-row { grid-template-columns: 1fr; }
  .operator-overlay-toggle { right: 16px; bottom: 84px; }
  .operator-overlay-panel { right: 14px; left: 14px; width: auto; }
}

/* Fix9 — Cogimo Chat parity: shared overlay + studio chat */
.cogimo-chat-card{display:flex;flex-direction:column;gap:14px;min-height:0;color:#e6eefc}
.cogimo-chat-header{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;flex-wrap:wrap}
.cogimo-chat-header h2{margin:0;font-size:1.12rem}
.cogimo-chat-subline{margin:6px 0 0;color:var(--muted)}
.cogimo-chat-scopes{display:flex;flex-wrap:wrap;gap:10px}
.cogimo-chat-scope-pill{display:inline-flex;align-items:flex-start;gap:10px;border:1px solid rgba(148,163,184,.16);background:rgba(15,23,42,.72);color:#e6eefc;border-radius:16px;padding:10px 12px;cursor:pointer;min-width:0}
.cogimo-chat-scope-pill span{display:block;font-size:.7rem;text-transform:uppercase;letter-spacing:.05em;color:#a9bbd7}
.cogimo-chat-scope-pill strong{display:block;font-size:.9rem;line-height:1.2;color:#fff}
.cogimo-chat-scope-pill.is-active{border-color:rgba(95,225,194,.42);background:linear-gradient(180deg,rgba(31,45,74,.96),rgba(15,23,42,.96));box-shadow:0 14px 30px rgba(2,6,23,.22)}
.cogimo-chat-quickbar{display:flex;flex-wrap:wrap;gap:8px}
.cogimo-chat-log{display:flex;flex-direction:column;gap:12px;overflow:auto;min-height:280px;max-height:420px;padding-right:4px}
.cogimo-chat-empty{padding:14px 16px;border:1px dashed rgba(148,163,184,.22);border-radius:18px;background:rgba(8,17,32,.56);color:#b9c6da}
.cogimo-chat-empty.is-hidden{display:none}
.cogimo-chat-message{display:flex}
.cogimo-chat-message.user{justify-content:flex-end}
.cogimo-chat-message.assistant{justify-content:flex-start}
.cogimo-chat-bubble{max-width:92%;padding:14px 16px;border-radius:20px;border:1px solid rgba(148,163,184,.16);background:rgba(15,23,42,.82);box-shadow:0 16px 30px rgba(2,6,23,.18)}
.cogimo-chat-message.user .cogimo-chat-bubble{background:linear-gradient(180deg,rgba(37,99,235,.22),rgba(37,99,235,.15));border-color:rgba(96,165,250,.4)}
.cogimo-chat-bubble-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:8px}
.cogimo-chat-bubble-head strong{color:#fff}
.cogimo-chat-bubble-head span{font-size:.76rem;color:#a9bbd7;text-transform:uppercase;letter-spacing:.05em}
.cogimo-chat-bubble-text{white-space:pre-wrap;line-height:1.55}
.cogimo-chat-action-list{display:grid;gap:10px;margin-top:12px}
.cogimo-chat-action-card{padding:12px;border-radius:16px;background:rgba(8,17,32,.62);border:1px solid rgba(148,163,184,.14)}
.cogimo-chat-action-card strong{display:block;color:#fff;margin-bottom:4px}
.cogimo-chat-action-card p{margin:0 0 10px;color:#b9c6da}
.cogimo-chat-warning-list{margin:12px 0 0;padding-left:18px;color:#fbbf24}
.cogimo-chat-footer{display:grid;gap:10px}
.cogimo-chat-footer-top{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}
.cogimo-chat-composer{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:12px;align-items:end}
.cogimo-chat-composer textarea{width:100%;min-height:84px;max-height:220px;resize:vertical;border-radius:18px;border:1px solid rgba(148,163,184,.18);background:rgba(8,17,32,.78);color:#f8fbff;padding:14px 16px;font:inherit}
.cogimo-chat-composer textarea:focus{outline:none;border-color:rgba(95,225,194,.44);box-shadow:0 0 0 3px rgba(95,225,194,.12)}
.cogimo-chat-thread-sheet{display:none;position:relative;padding:14px;border-radius:18px;border:1px solid rgba(148,163,184,.14);background:rgba(8,17,32,.82)}
.cogimo-chat-thread-sheet.is-open{display:grid;gap:12px}
.cogimo-chat-thread-sheet-head,.cogimo-chat-thread-sheet-section{display:grid;gap:10px}
.cogimo-chat-thread-sheet-head{grid-template-columns:minmax(0,1fr) auto;align-items:center}
.cogimo-chat-thread-sheet-label{font-size:.78rem;text-transform:uppercase;letter-spacing:.05em;color:#9db0cc}
.cogimo-chat-thread-list{display:grid;gap:8px}
.cogimo-thread-item,.cogimo-thread-empty{padding:11px 12px;border-radius:14px;border:1px solid rgba(148,163,184,.14);background:rgba(15,23,42,.72)}
button.cogimo-thread-item{cursor:pointer;text-align:left;color:inherit}
.cogimo-thread-item strong{display:block;color:#fff;margin-bottom:3px}
.cogimo-thread-item span{display:block;color:#b9c6da;font-size:.88rem}
.cogimo-thread-item.is-active{border-color:rgba(95,225,194,.42)}
.cogimo-chat-card-studio{min-height:620px}
.cogimo-chat-card-studio .cogimo-chat-log{flex:1;max-height:none;min-height:340px}
.cogimo-chat-card-overlay{height:100%}
.cogimo-chat-card-overlay .cogimo-chat-log{max-height:calc(100vh - 430px);min-height:260px}
.operator-overlay-shell{display:flex;flex-direction:column;height:100%}
.operator-overlay-panel{display:none}
.operator-overlay-panel.is-open{display:block}
.operator-overlay-shell .cogimo-chat-card{height:100%}
.operator-overlay-panel{position:fixed;right:22px;bottom:94px;width:min(460px,calc(100vw - 32px));z-index:90}
.operator-overlay-shell{padding:18px;border-radius:28px;border:1px solid rgba(148,163,184,.16);background:linear-gradient(180deg,rgba(9,16,30,.98),rgba(9,16,30,.94));box-shadow:0 24px 70px rgba(2,6,23,.45);backdrop-filter:blur(16px)}
.operator-overlay-toggle{z-index:91}
body[data-ui-theme="light"] .cogimo-chat-scope-pill,
body[data-ui-theme="light"] .cogimo-chat-bubble,
body[data-ui-theme="light"] .cogimo-chat-action-card,
body[data-ui-theme="light"] .cogimo-chat-thread-sheet,
body[data-ui-theme="light"] .cogimo-thread-item,
body[data-ui-theme="light"] .operator-overlay-shell{background:#fff;color:#0f172a;border-color:#dbe4ef}
body[data-ui-theme="light"] .cogimo-chat-bubble-head strong,
body[data-ui-theme="light"] .cogimo-chat-action-card strong,
body[data-ui-theme="light"] .cogimo-thread-item strong,
body[data-ui-theme="light"] .cogimo-chat-scope-pill strong{color:#0f172a}
body[data-ui-theme="light"] .cogimo-chat-bubble-head span,
body[data-ui-theme="light"] .cogimo-chat-subline,
body[data-ui-theme="light"] .cogimo-chat-empty,
body[data-ui-theme="light"] .cogimo-thread-item span,
body[data-ui-theme="light"] .cogimo-chat-scope-pill span{color:#5b6b84}
body[data-ui-theme="light"] .cogimo-chat-composer textarea{background:#fff;color:#0f172a;border-color:#dbe4ef}
body[data-ui-theme="light"] .cogimo-chat-message.user .cogimo-chat-bubble{background:#eef5ff;border-color:#bfd9ff}
@media (max-width: 980px){
  .cogimo-chat-card-studio{min-height:0}
  .cogimo-chat-card-studio .cogimo-chat-log{min-height:240px}
}
@media (max-width: 780px){
  .cogimo-chat-header,.cogimo-chat-footer-top{grid-template-columns:1fr;display:grid}
  .cogimo-chat-composer{grid-template-columns:1fr}
  .cogimo-chat-composer .button{width:100%}
  .operator-overlay-panel{right:0;left:0;bottom:0;width:100%;height:100dvh;max-height:100dvh}
  .operator-overlay-shell{height:100%;border-radius:26px 26px 0 0;padding:14px 14px calc(18px + env(safe-area-inset-bottom))}
  .cogimo-chat-card-overlay .cogimo-chat-log{max-height:none;min-height:220px;flex:1}
  .cogimo-chat-scopes{overflow:auto;flex-wrap:nowrap;padding-bottom:4px}
  .cogimo-chat-scope-pill{min-width:160px}
  .operator-overlay-toggle{right:14px !important;bottom:82px !important}
}

/* Fix10 — Cogimo Copilot UI adoption: desktop + mobile parity */
.cogimo-copilot-shell{position:relative;display:flex;flex-direction:column;gap:12px;min-height:0;height:100%;border-radius:28px;border:1px solid rgba(255,255,255,.12);background:linear-gradient(180deg,rgba(9,18,36,.98),rgba(9,16,30,.96));box-shadow:0 24px 70px rgba(2,6,23,.45);overflow:hidden}
.cogimo-copilot-topbar{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:16px 18px;border-bottom:1px solid rgba(148,163,184,.16);background:linear-gradient(180deg,rgba(255,255,255,.06),rgba(255,255,255,.02))}
.cogimo-copilot-topbar-left,.cogimo-copilot-topbar-right{display:flex;align-items:center;gap:12px;min-width:0}
.cogimo-copilot-topbar-right{flex:0 0 auto}
.cogimo-copilot-brandmark,.cogimo-copilot-context-card-icon{display:inline-flex;align-items:center;justify-content:center;width:56px;height:56px;border-radius:18px;background:radial-gradient(circle at 35% 30%,rgba(173,128,255,.4),rgba(110,71,255,.22) 52%,rgba(9,18,36,.04) 100%);box-shadow:0 16px 30px rgba(63,94,251,.22);overflow:hidden}
.cogimo-copilot-brandmark img,.cogimo-copilot-context-card-icon img,.operator-overlay-toggle-icon{width:100%;height:100%;object-fit:cover}
.cogimo-copilot-heading{display:grid;gap:4px;min-width:0}
.cogimo-copilot-heading strong{display:block;font-size:1.5rem;line-height:1.05;color:#f8fafc;letter-spacing:-.03em}
.cogimo-copilot-heading span{display:block;color:#aab9d3;font-size:.92rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.cogimo-copilot-iconbutton{display:inline-flex;align-items:center;justify-content:center;gap:4px;width:52px;height:52px;border-radius:18px;border:1px solid rgba(255,255,255,.12);background:rgba(8,17,32,.82);color:#f8fafc;cursor:pointer;box-shadow:0 10px 24px rgba(2,6,23,.18);font:inherit;font-size:1.35rem;line-height:1}
.cogimo-copilot-iconbutton:hover{border-color:rgba(59,130,246,.34);background:rgba(15,23,42,.96)}
.cogimo-copilot-iconbutton span{display:block;width:18px;height:2px;border-radius:999px;background:currentColor}
.cogimo-copilot-context-card{display:flex;align-items:center;gap:14px;margin:0 18px;padding:16px 18px;border-radius:24px;border:1px solid rgba(255,255,255,.12);background:linear-gradient(180deg,rgba(10,20,39,.96),rgba(8,17,32,.92));box-shadow:0 18px 40px rgba(2,6,23,.22)}
.cogimo-copilot-context-card-copy{display:grid;gap:3px;min-width:0}
.cogimo-copilot-context-card-copy strong{font-size:1.1rem;color:#f8fafc;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.cogimo-copilot-context-card-copy span{color:#f8fafc;font-weight:700;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.cogimo-copilot-context-card-copy small{color:#9bb0cc;line-height:1.35}
.cogimo-chat-scopes{padding:0 18px;display:flex;flex-wrap:wrap;gap:8px}
.cogimo-chat-scope-pill{border-radius:999px;padding:9px 12px;background:rgba(255,255,255,.04);border:1px solid rgba(148,163,184,.16);box-shadow:none}
.cogimo-chat-scope-pill.is-active{border-color:rgba(59,130,246,.34);background:rgba(37,99,235,.18);box-shadow:0 10px 22px rgba(29,78,216,.18)}
.cogimo-chat-scope-pill span{font-size:.68rem}
.cogimo-chat-scope-pill strong{font-size:.88rem}
.cogimo-chat-quickbar{display:none;padding:0 18px 2px;flex-wrap:wrap;gap:8px}
.cogimo-chat-quickbar.is-open{display:flex}
.cogimo-chat-quick-action{border-radius:999px}
.cogimo-chat-log{flex:1 1 auto;min-height:280px;max-height:none;padding:0 18px 4px;overflow:auto;display:flex;flex-direction:column;gap:12px}
.cogimo-chat-empty{margin:0 18px;padding:14px 16px;border-radius:18px;background:rgba(255,255,255,.03);border:1px dashed rgba(148,163,184,.22);color:#9bb0cc}
.cogimo-chat-message{display:flex}
.cogimo-chat-message.user{justify-content:flex-end}
.cogimo-chat-message.assistant{justify-content:flex-start}
.cogimo-chat-bubble{max-width:92%;padding:14px 16px;border-radius:18px;border:1px solid rgba(148,163,184,.16);background:rgba(255,255,255,.04);box-shadow:none}
.cogimo-chat-message.user .cogimo-chat-bubble{background:rgba(37,99,235,.18);border-color:rgba(59,130,246,.34)}
.cogimo-chat-bubble-head{margin-bottom:8px}
.cogimo-chat-bubble-head strong{font-size:.92rem}
.cogimo-chat-bubble-head span{font-size:.72rem}
.cogimo-chat-bubble-text{line-height:1.6}
.cogimo-chat-action-list{display:grid;gap:10px;margin-top:12px}
.cogimo-chat-action-card{padding:12px;border-radius:16px;background:rgba(2,6,23,.42);border:1px solid rgba(148,163,184,.14)}
.cogimo-copilot-footer{margin-top:auto;border-top:1px solid rgba(148,163,184,.12);background:rgba(15,23,42,.9);padding:14px 18px calc(18px + env(safe-area-inset-bottom))}
.cogimo-copilot-composer{display:block}
.cogimo-copilot-composer-frame{display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:12px;align-items:end}
.cogimo-copilot-plus{display:inline-flex;align-items:center;justify-content:center;width:58px;height:58px;border-radius:18px;border:1px solid rgba(255,255,255,.12);background:rgba(8,17,32,.82);color:#f8fafc;cursor:pointer;font:inherit;font-size:2rem;line-height:1;box-shadow:0 10px 24px rgba(2,6,23,.18)}
.cogimo-copilot-plus:hover{border-color:rgba(59,130,246,.34);background:rgba(15,23,42,.96)}
.cogimo-copilot-composer textarea{width:100%;min-height:90px;max-height:220px;resize:vertical;border-radius:20px;border:1px solid rgba(148,163,184,.16);background:rgba(2,6,23,.42);color:#f8fafc;padding:16px;font:inherit;box-shadow:inset 0 1px 0 rgba(255,255,255,.02)}
.cogimo-copilot-composer textarea:focus{outline:none;border-color:rgba(59,130,246,.34);box-shadow:0 0 0 3px rgba(59,130,246,.14)}
.cogimo-copilot-send{min-width:116px;min-height:58px;border-radius:18px;border:1px solid rgba(59,130,246,.42);background:linear-gradient(180deg,rgba(27,90,224,.96),rgba(24,72,184,.96));color:#fff;font-weight:700;box-shadow:0 18px 34px rgba(27,90,224,.22)}
.cogimo-copilot-send:hover{transform:translateY(-1px);box-shadow:0 22px 40px rgba(27,90,224,.3)}
.cogimo-chat-thread-sheet{position:absolute;inset:0;display:none;z-index:24}
.cogimo-chat-thread-sheet.is-open{display:block}
.cogimo-chat-thread-sheet-backdrop{position:absolute;inset:0;border:0;background:rgba(2,6,23,.56);cursor:pointer}
.cogimo-chat-thread-sheet-panel{position:absolute;left:16px;top:16px;bottom:16px;width:min(360px,calc(100% - 32px));display:grid;gap:14px;padding:16px;border-radius:24px;border:1px solid rgba(255,255,255,.12);background:linear-gradient(180deg,rgba(8,17,32,.98),rgba(15,23,42,.96));box-shadow:0 28px 70px rgba(2,6,23,.48);overflow:auto}
.cogimo-chat-thread-sheet-head,.cogimo-chat-thread-sheet-section{display:grid;gap:10px}
.cogimo-chat-thread-sheet-head{grid-template-columns:minmax(0,1fr) auto;align-items:start}
.cogimo-chat-thread-sheet-head strong{font-size:1.05rem;color:#f8fafc}
.cogimo-chat-thread-list{display:grid;gap:8px}
.cogimo-thread-item,.cogimo-thread-empty{padding:12px 13px;border-radius:16px;border:1px solid rgba(148,163,184,.14);background:rgba(255,255,255,.04)}
.cogimo-thread-item.is-active{border-color:rgba(59,130,246,.38);background:rgba(37,99,235,.14)}
.cogimo-thread-item strong{display:block;margin-bottom:4px}
.cogimo-thread-item span{font-size:.88rem;color:#aab9d3}
.cogimo-chat-card-studio{min-height:0}
.cogimo-chat-card-studio .cogimo-chat-log{min-height:340px}
.cogimo-chat-card-overlay .cogimo-chat-log{min-height:260px}
.operator-overlay-panel{position:fixed;right:22px;bottom:94px;width:min(560px,calc(100vw - 32px));z-index:90;display:none}
.operator-overlay-panel.is-open{display:block}
.operator-overlay-shell{padding:0;border:0;background:transparent;box-shadow:none;height:100%}
.operator-overlay-toggle{display:inline-flex;align-items:center;gap:10px;padding:0 18px;height:58px;border-radius:999px;border:1px solid rgba(255,255,255,.18);background:linear-gradient(180deg,rgba(19,31,54,.98),rgba(8,17,32,.96));box-shadow:0 18px 40px rgba(8,17,32,.35)}
.operator-overlay-toggle-icon{width:28px;height:28px;border-radius:999px;overflow:hidden}
body[data-ui-theme="light"] .cogimo-copilot-shell,
body[data-ui-theme="light"] .cogimo-copilot-context-card,
body[data-ui-theme="light"] .cogimo-chat-bubble,
body[data-ui-theme="light"] .cogimo-chat-thread-sheet-panel,
body[data-ui-theme="light"] .cogimo-thread-item,
body[data-ui-theme="light"] .cogimo-copilot-footer{background:#fff;color:#0f172a;border-color:#dbe4ef}
body[data-ui-theme="light"] .cogimo-copilot-topbar{background:#f8fafc;border-color:#dbe4ef}
body[data-ui-theme="light"] .cogimo-copilot-heading strong,
body[data-ui-theme="light"] .cogimo-copilot-context-card-copy strong,
body[data-ui-theme="light"] .cogimo-copilot-context-card-copy span,
body[data-ui-theme="light"] .cogimo-thread-item strong,
body[data-ui-theme="light"] .cogimo-chat-bubble-head strong{color:#0f172a}
body[data-ui-theme="light"] .cogimo-copilot-heading span,
body[data-ui-theme="light"] .cogimo-copilot-context-card-copy small,
body[data-ui-theme="light"] .cogimo-thread-item span,
body[data-ui-theme="light"] .cogimo-chat-empty{color:#5b6b84}
body[data-ui-theme="light"] .cogimo-copilot-iconbutton,
body[data-ui-theme="light"] .cogimo-copilot-plus{background:#fff;color:#0f172a;border-color:#dbe4ef}
body[data-ui-theme="light"] .cogimo-chat-scope-pill{background:#f8fafc;border-color:#dbe4ef}
body[data-ui-theme="light"] .cogimo-chat-scope-pill strong{color:#0f172a}
body[data-ui-theme="light"] .cogimo-copilot-composer textarea{background:#fff;color:#0f172a;border-color:#dbe4ef}
body[data-ui-theme="light"] .cogimo-chat-message.user .cogimo-chat-bubble{background:#eef5ff;border-color:#bfd9ff}
@media (max-width: 980px){
  .cogimo-copilot-topbar{padding:14px}
  .cogimo-copilot-brandmark,.cogimo-copilot-context-card-icon{width:52px;height:52px}
  .cogimo-copilot-heading strong{font-size:1.28rem}
  .cogimo-chat-thread-sheet-panel{width:min(340px,calc(100% - 24px));left:12px;top:12px;bottom:12px}
}
@media (max-width: 780px){
  .operator-overlay-panel{right:0;left:0;bottom:0;width:100%;height:100dvh;max-height:100dvh}
  .operator-overlay-shell{height:100%}
  .cogimo-copilot-shell{border-radius:26px 26px 0 0;height:100%;max-height:none}
  .cogimo-copilot-topbar{padding:14px 14px 12px;align-items:flex-start}
  .cogimo-copilot-topbar-left{gap:10px;align-items:flex-start}
  .cogimo-copilot-topbar-right{gap:8px}
  .cogimo-copilot-iconbutton{width:50px;height:50px;border-radius:16px}
  .cogimo-copilot-brandmark{width:54px;height:54px}
  .cogimo-copilot-heading strong{font-size:1.18rem}
  .cogimo-copilot-heading span{font-size:.86rem;white-space:normal}
  .cogimo-copilot-context-card{margin:0 14px;padding:14px;border-radius:22px}
  .cogimo-chat-scopes{padding:0 14px;overflow:auto;flex-wrap:nowrap}
  .cogimo-chat-scope-pill{min-width:156px}
  .cogimo-chat-quickbar{padding:0 14px 2px;overflow:auto;flex-wrap:nowrap}
  .cogimo-chat-log{padding:0 14px 4px;min-height:0}
  .cogimo-chat-empty{margin:0 14px}
  .cogimo-copilot-footer{padding:12px 14px calc(16px + env(safe-area-inset-bottom))}
  .cogimo-copilot-composer-frame{grid-template-columns:auto minmax(0,1fr);gap:10px}
  .cogimo-copilot-composer textarea{min-height:84px}
  .cogimo-copilot-send{grid-column:1 / -1;width:100%;min-height:54px}
  .cogimo-chat-thread-sheet-panel{left:10px;right:10px;top:auto;bottom:10px;width:auto;max-height:min(72vh,560px);border-radius:22px}
}

/* Fix12 — system surfaces + structured visual editor */
.editor-grid-tight { grid-template-columns: 280px minmax(0, 1fr) 340px; }
.editor-canvas-surface {
  display: grid;
  gap: 14px;
  padding: 18px;
  border-radius: 20px;
  border: 1px solid rgba(148,163,184,.14);
  background: linear-gradient(180deg, rgba(2,6,23,.42), rgba(15,23,42,.28));
}
.editor-section-card {
  padding: 18px;
  border-radius: 18px;
  border: 1px solid rgba(148,163,184,.14);
  background: rgba(255,255,255,.03);
}
.editor-section-card.is-active {
  border-color: rgba(99,102,241,.46);
  background: linear-gradient(180deg, rgba(79,70,229,.14), rgba(79,70,229,.05));
  box-shadow: 0 14px 30px rgba(2,6,23,.14);
}
.editor-section-card h3 { margin: 10px 0 8px; }
.editor-section-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.studio-outline-list li.is-active,
.studio-outline-list li:has(a[href]) {
  transition: border-color .16s ease, background .16s ease;
}
.studio-outline-list li.is-active {
  border-color: rgba(99,102,241,.42);
  background: rgba(79,70,229,.12);
}
.studio-outline-list li a {
  display: block;
  color: inherit;
  text-decoration: none;
}
@media (max-width: 1280px) {
  .editor-grid-tight { grid-template-columns: 1fr; }
}

/* Fix13 — visual editor actions + frontend-near canvas */
.editor-outline-list li.is-muted {
  opacity: .82;
}
.editor-outline-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 10px;
}
.editor-mini-actions,
.editor-preview-actions,
.editor-inline-form-footer,
.editor-inspector-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.editor-mini-button,
.editor-inline-action {
  min-width: 40px;
  min-height: 40px;
  padding: 8px 12px;
}
.badge-ghost {
  background: rgba(148,163,184,.16);
  color: #d8e2f0;
}
.editor-frontend-surface {
  padding: 0;
  background: linear-gradient(180deg, rgba(8,17,32,.72), rgba(8,17,32,.48));
}
.editor-preview-frame {
  display: grid;
  gap: 0;
  border-radius: 22px;
  overflow: hidden;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(148,163,184,.16);
  box-shadow: 0 24px 46px rgba(2,6,23,.18);
}
.editor-preview-browserbar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(148,163,184,.14);
  background: rgba(2,6,23,.42);
}
.editor-preview-browserbar span {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: rgba(255,255,255,.22);
}
.editor-preview-browserbar strong {
  margin-left: 8px;
  font-size: .85rem;
  color: #b9c6da;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.editor-preview-page-header {
  margin: 0;
  border-radius: 0;
  border: 0;
  border-bottom: 1px solid rgba(148,163,184,.12);
}
.editor-preview-section {
  position: relative;
  margin: 0;
  border-left: 0;
  border-right: 0;
  border-bottom: 0;
  border-radius: 0;
  transition: border-color .16s ease, box-shadow .16s ease, opacity .16s ease;
}
.editor-preview-section:first-of-type {
  border-top: 0;
}
.editor-preview-section.is-active {
  border-color: rgba(59,130,246,.34);
  box-shadow: inset 0 0 0 1px rgba(59,130,246,.24);
  background: linear-gradient(180deg, rgba(37,99,235,.08), rgba(37,99,235,.03));
}
.editor-preview-section.is-hidden-preview {
  opacity: .72;
}
.editor-preview-section-toolbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.editor-inline-form {
  display: grid;
  gap: 12px;
}
.editor-inline-form input,
.editor-inline-form textarea {
  width: 100%;
}
.editor-inline-form label,
.editor-inspector-actions {
  display: grid;
  gap: 6px;
}
.editor-hidden-note {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed rgba(148,163,184,.18);
}
@media (max-width: 980px) {
  .editor-preview-section-toolbar,
  .editor-outline-actions,
  .editor-inline-form-footer,
  .editor-inspector-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .editor-preview-actions,
  .editor-mini-actions {
    width: 100%;
  }
  .editor-preview-actions form,
  .editor-mini-actions form {
    flex: 1 1 auto;
  }
  .editor-inline-action,
  .editor-mini-button {
    width: 100%;
  }
}

/* Fix16b – visible frontend effects for Design / Grow / System */
.public-container {
  padding-top: 24px;
  padding-bottom: 72px;
}
.public-topbar {
  background: color-mix(in srgb, var(--bg) 84%, transparent);
}
.public-nav {
  gap: 12px;
}
.public-nav > a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid transparent;
}
.public-nav > a.is-active {
  border-color: color-mix(in srgb, var(--accent) 45%, var(--line));
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  color: #fff;
}
body.cogimo-public-site {
  transition: background .18s ease, color .18s ease;
}
body.cogimo-public-site .button {
  background: var(--accent);
}
body.cogimo-public-site.surface-glass .panel {
  background: linear-gradient(180deg, rgba(19,26,46,.72), rgba(10,16,31,.68));
  backdrop-filter: blur(12px);
}
body.cogimo-public-site.surface-solid .panel {
  background: linear-gradient(180deg, rgba(22,28,46,.98), rgba(13,18,31,.98));
}
body.cogimo-public-site.radius-sharp .panel,
body.cogimo-public-site.radius-sharp .button,
body.cogimo-public-site.radius-sharp input,
body.cogimo-public-site.radius-sharp textarea,
body.cogimo-public-site.radius-sharp select {
  border-radius: 8px;
}
body.cogimo-public-site.radius-medium .panel,
body.cogimo-public-site.radius-medium .button,
body.cogimo-public-site.radius-medium input,
body.cogimo-public-site.radius-medium textarea,
body.cogimo-public-site.radius-medium select {
  border-radius: 14px;
}
body.cogimo-public-site.radius-soft .panel,
body.cogimo-public-site.radius-soft .button,
body.cogimo-public-site.radius-soft input,
body.cogimo-public-site.radius-soft textarea,
body.cogimo-public-site.radius-soft select {
  border-radius: 20px;
}
body.cogimo-public-site.font-editorial {
  font-family: Georgia, "Times New Roman", serif;
}
body.cogimo-public-site.font-product {
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: -.01em;
}
body.cogimo-public-site.density-airy .panel {
  padding: 30px;
}
body.cogimo-public-site.density-compact .panel {
  padding: 16px;
}
body.cogimo-public-site.header-solid .topbar {
  background: rgba(7,10,18,.96);
  border-bottom-color: color-mix(in srgb, var(--accent) 20%, var(--line));
}
body.cogimo-public-site.header-minimal .topbar {
  background: transparent;
  border-bottom-color: transparent;
  backdrop-filter: none;
}
.public-hero-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, .8fr);
  gap: 22px;
  margin-bottom: 22px;
}
.public-header-copy,
.public-lead {
  color: var(--muted);
  max-width: 68ch;
}
.public-context-grid,
.public-card-grid,
.public-contact-grid {
  display: grid;
  gap: 14px;
}
.public-context-grid {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}
.public-context-card,
.public-contact-card,
.public-mini-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px;
  border-radius: 18px;
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.08);
  color: inherit;
  text-decoration: none;
}
.public-contact-card em,
.public-context-card em {
  color: var(--muted);
  font-style: normal;
}
.public-section {
  margin-bottom: 16px;
}
.public-section h2 {
  margin-top: 0;
  margin-bottom: 10px;
  font-size: clamp(1.35rem, 2vw, 2rem);
}
.public-section-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(240px, .85fr);
  gap: 20px;
  align-items: center;
}
.public-feature-list,
.public-inline-list,
.public-slot-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding-left: 0;
  list-style: none;
}
.public-feature-list li,
.public-inline-list li {
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.07);
}
.public-faq-list {
  display: grid;
  gap: 12px;
}
.public-faq-item {
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 16px;
  padding: 14px 16px;
  background: rgba(255,255,255,.02);
}
.public-faq-item summary {
  cursor: pointer;
  font-weight: 700;
}
.public-footer-panel {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
}
.public-footer-meta {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: flex-end;
}
@media (max-width: 960px) {
  .public-hero-shell,
  .public-section-hero,
  .public-footer-panel {
    grid-template-columns: 1fr;
    display: grid;
  }
  .public-footer-meta {
    align-items: flex-start;
  }
}
@media (max-width: 760px) {
  .public-nav {
    width: 100%;
    justify-content: flex-start;
  }
  .public-nav > a.button {
    min-height: 40px;
  }
  .public-context-grid,
  .public-card-grid,
  .public-contact-grid {
    grid-template-columns: 1fr;
  }
}


/* Fix17d overlay calm-down */
.cogimo-copilot-context-strip{display:grid;gap:3px;padding:12px 16px;border-top:1px solid rgba(148,163,184,.12);border-bottom:1px solid rgba(148,163,184,.12);background:rgba(8,17,32,.42)}
.cogimo-copilot-context-strip strong{font-size:.98rem;color:#f8fafc}
.cogimo-copilot-context-strip span,.cogimo-copilot-context-strip small{color:#9bb0cc}
.operator-overlay-panel .cogimo-copilot-topbar{padding:12px 14px}
.operator-overlay-panel .cogimo-copilot-brandmark{width:42px;height:42px;border-radius:14px}
.operator-overlay-panel .cogimo-copilot-heading strong{font-size:1.2rem}
.operator-overlay-panel .cogimo-copilot-heading span{font-size:.82rem}
.operator-overlay-panel .cogimo-copilot-context-actions{margin:0;padding:10px 16px;border-bottom:1px solid rgba(148,163,184,.12);background:rgba(8,17,32,.28)}
.operator-overlay-panel .cogimo-chat-quickbar.is-hidden{display:none}
.operator-overlay-panel .cogimo-chat-empty{padding:12px 14px}
.operator-overlay-panel .cogimo-copilot-composer-frame{gap:10px}
.operator-overlay-panel .cogimo-copilot-plus{width:48px;height:48px;border-radius:14px;font-size:1.6rem}
.operator-overlay-panel .cogimo-copilot-composer textarea{min-height:64px;max-height:160px}
