:root {
  --brand-coral: #FF4B4B;
  --brand-orange: #FF8A00;
  --brand-navy: #0B1020;
  --brand-white: #FFFFFF;
  --brand-gradient: linear-gradient(135deg, #FF4B4B 0%, #FF8A00 100%);
  --background-primary: #F6F7FB;
  --background-secondary: #F1F3F7;
  --surface-primary: #FFFFFF;
  --surface-brand-light: #FFF1ED;
  --text-primary: #0B1020;
  --text-secondary: #64748B;
  --text-disabled: #94A3B8;
  --border-primary: #E7EAF0;
  --brand-coral-hover: #E63E3E;
  --brand-orange-hover: #E67600;
  --status-success: #22C55E;
  --status-info: #3B82F6;
  --status-warning: #F59E0B;
  --status-danger: #EF4444;
  --bg: var(--background-primary);
  --bg-2: var(--background-secondary);
  --surface: var(--surface-primary);
  --surface-2: var(--background-secondary);
  --line: var(--border-primary);
  --text: var(--text-primary);
  --muted: var(--text-secondary);
  --gold: var(--brand-coral);
  --gold-2: var(--brand-orange);
  --cyan: var(--status-info);
  --danger: var(--status-danger);
  --ok: var(--status-success);
  --shadow: 0 10px 28px rgba(11, 16, 32, .06);
  --radius: 16px;
  --sidebar-w: 300px;
  --sidebar-mini: 88px;
  --header-h: 64px;
  --ease: 220ms ease;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; overflow-x: clip; }
body {
  font-family: Manrope, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.5;
  background: var(--background-primary);
  color: var(--text-primary);
  letter-spacing: 0;
}
a { color: var(--brand-coral); text-decoration: none; }
img { max-width: 100%; display: block; }
img[hidden],
#final-image[hidden] { display: none !important; }
button, input, select, textarea {
  font: inherit;
  color: inherit;
}
h1, h2, h3, .brand-word, .auth-brand strong {
  font-family: Manrope, "Segoe UI", sans-serif;
  font-weight: 700;
  letter-spacing: -.03em;
  color: var(--text-primary);
}

.app-body { background: var(--background-primary); }
.shell {
  display: grid;
  grid-template-columns: var(--sidebar-w) minmax(0, 1fr);
  min-height: 100vh;
  min-width: 0;
  max-width: 100%;
  transition: grid-template-columns 220ms ease;
}
html.nav-mini { --sidebar-w: var(--sidebar-mini); }
.workspace { min-width: 0; display: flex; flex-direction: column; min-height: 100vh; max-width: 100%; }

.sidebar {
  position: sticky; top: 0; z-index: 40;
  height: 100vh;
  display: flex; flex-direction: column; gap: 14px;
  padding: 14px 12px 14px;
  background: #fff;
  color: var(--text-primary);
  border-right: 1px solid var(--border-primary);
  overflow: auto;
}
.brand-row {
  display: flex; align-items: center; gap: 6px;
  min-height: 64px; flex: 0 0 auto;
}
.brand {
  display: flex; align-items: center;
  flex: 1; min-width: 0; height: 64px;
}
.brand-logo {
  display: block;
  height: 58px; width: auto; max-width: 230px;
  object-fit: contain; object-position: left center;
}
.brand-mark { display: none; width: 48px; height: 48px; object-fit: contain; }
.collapse-btn { flex: 0 0 auto; color: var(--text-secondary); }
.ico-unfold { display: none !important; }
html.nav-mini .ico-fold { display: none !important; }
html.nav-mini .ico-unfold { display: block !important; }
.side-nav {
  display: grid; gap: 4px;
  flex: 1; align-content: start;
}
.side-nav a {
  display: flex; align-items: center; gap: 10px;
  min-height: 44px; padding: 0 12px;
  border-radius: 12px;
  color: var(--text-secondary);
  font-weight: 600; font-size: 14px;
  transition: background var(--ease), color var(--ease);
}
.side-nav a svg {
  width: 18px; height: 18px; flex: 0 0 auto;
  padding: 7px; box-sizing: content-box;
  background: var(--background-primary);
  border-radius: 10px;
  color: var(--brand-coral);
}
.side-nav a.is-active svg {
  background: #fff;
  color: var(--brand-coral);
}
.side-nav a:hover { background: var(--background-primary); color: var(--text-primary); }
.side-nav a.is-active {
  color: var(--brand-coral);
  background: var(--surface-brand-light);
  box-shadow: inset 3px 0 0 var(--brand-orange);
}
.side-nav a:focus-visible, .icon-btn:focus-visible, .btn:focus-visible, .side-logout:focus-visible {
  outline: 2px solid var(--brand-coral);
  outline-offset: 2px;
}
.side-label {
  margin: 14px 12px 4px;
  font-size: 11px; font-weight: 700;
  letter-spacing: .16em; text-transform: uppercase;
  color: var(--text-disabled);
}
.sidebar-foot {
  display: grid; gap: 10px;
  padding-top: 12px;
  border-top: 1px solid var(--border-primary);
}
.side-search {
  display: flex; align-items: center; gap: 8px;
  height: 40px;
  background: var(--background-primary);
  border: 1px solid var(--border-primary);
  border-radius: 12px; padding: 0 12px;
  color: var(--text-secondary);
}
.side-search svg { width: 16px; height: 16px; flex: 0 0 16px; }
.side-search input {
  border: 0; background: transparent; padding: 0; outline: none;
  color: var(--text-primary);
}
.side-search input::placeholder { color: var(--text-disabled); }
.side-user { display: flex; align-items: center; gap: 10px; min-width: 0; }
.avatar-btn {
  width: 40px; height: 40px; border-radius: 50%;
  border: 0;
  background: var(--brand-gradient); color: #fff; font-weight: 700;
  display: grid; place-items: center; flex: 0 0 auto;
}
.side-who { min-width: 0; }
.side-who strong, .side-who small {
  display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.side-who strong { font-size: 13px; color: var(--text-primary); }
.side-who small { color: var(--text-secondary); font-size: 11px; }
.side-logout {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; height: 40px;
  border: 1px solid var(--border-primary);
  background: #fff; color: var(--text-secondary);
  border-radius: 12px; cursor: pointer; font-weight: 600;
}
.side-logout:hover { background: var(--background-primary); color: var(--text-primary); }
.side-logout svg { width: 16px; height: 16px; }

.icon-btn {
  width: 40px; height: 40px; border-radius: 11px; border: 0;
  display: grid; place-items: center;
  background: transparent; color: var(--text-secondary); cursor: pointer;
  transition: background var(--ease), color var(--ease);
}
.icon-btn:hover { background: var(--background-primary); color: var(--text-primary); }
.icon-btn svg { width: 18px; height: 18px; }

.app-header {
  position: sticky; top: 0; z-index: 30;
  height: var(--header-h);
  display: flex; align-items: center; gap: 10px;
  padding: 0 20px;
  background: rgba(255,255,255,.9);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-primary);
}
.head-search {
  display: flex; align-items: center; gap: 8px;
  height: 40px; width: min(360px, 32vw); flex: 1;
  background: var(--background-primary);
  border: 1px solid var(--border-primary);
  border-radius: 12px; padding: 0 12px;
  color: var(--text-secondary);
}
.head-search svg { width: 16px; height: 16px; flex: 0 0 16px; }
.head-search input { border: 0; background: transparent; padding: 0; outline: none; }
.head-shortcuts {
  display: flex; align-items: center; gap: 4px;
  margin-left: auto;
}
.head-shortcuts a {
  width: 40px; height: 40px; border-radius: 11px;
  display: grid; place-items: center;
  color: var(--text-secondary);
}
.head-shortcuts a:hover { background: var(--background-primary); color: var(--brand-coral); }
.head-shortcuts a svg { width: 18px; height: 18px; }
.head-cta { flex: 0 0 auto; }
.head-logo { display: none; }
.head-balance { display: none; }
.tabbar { display: none; }
.burger { display: none; }
.nav-backdrop { display: none; }

html.nav-mini .nav-text,
html.nav-mini .side-label,
html.nav-mini .side-who { display: none; }
html.nav-mini .brand { justify-content: center; height: 52px; }
html.nav-mini .brand-logo { display: none !important; }
html.nav-mini .brand-mark { display: block; }
html.nav-mini .brand-row { justify-content: center; flex-direction: column; min-height: 52px; }
html.nav-mini .sidebar { padding: 12px 8px; align-items: center; }
html.nav-mini .side-nav { width: 100%; justify-items: center; }
html.nav-mini .side-nav a {
  width: 44px; padding: 0; justify-content: center;
  box-shadow: none;
}
html.nav-mini .side-nav a svg { padding: 6px; }
html.nav-mini .side-logout { width: 44px; padding: 0; justify-content: center; }
html.nav-mini .sidebar-foot { width: 100%; justify-items: center; }

.main { padding: 20px 22px 48px; max-width: none; width: 100%; margin: 0; }
.main.wide { max-width: none; }

.page-head { display: flex; justify-content: space-between; gap: 20px; align-items: flex-end; margin-bottom: 28px; }
.kicker { color: var(--brand-coral); text-transform: uppercase; letter-spacing: .16em; font-size: 11px; margin: 0 0 8px; font-family: Manrope, sans-serif; font-weight: 700; }
.lede { color: var(--muted); margin: 8px 0 0; max-width: 640px; }
h1 { font-size: 36px; margin: 0; }

.panel {
  background: var(--surface-primary);
  border: 1px solid var(--border-primary);
  border-radius: var(--radius);
  padding: 22px;
  margin-bottom: 22px;
  box-shadow: var(--shadow);
}
.panel.highlight { border-color: #FFC4A8; background: var(--surface-brand-light); }
.panel-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.panel h2 { margin: 0 0 14px; font-size: 22px; }

.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 22px; }
.stat { background: var(--surface-primary); border: 1px solid var(--border-primary); border-radius: 16px; padding: 18px; box-shadow: var(--shadow); }
.stat span { color: var(--text-secondary); font-size: 12px; }
.stat strong { display: block; font-size: 28px; margin-top: 8px; font-family: Manrope, sans-serif; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 1px solid var(--border-primary); background: var(--surface-primary);
  color: var(--text-primary); border-radius: 12px; padding: 0 18px; height: 48px; cursor: pointer;
  font-size: 15px; font-weight: 800; line-height: 1;
  transition: transform var(--ease), box-shadow var(--ease), background var(--ease), border-color var(--ease);
}
.btn:hover { background: var(--background-primary); }
.btn.gold {
  background: var(--brand-gradient); color: var(--brand-white); border: 0;
  box-shadow: 0 8px 18px rgba(255, 75, 75, .22);
}
.btn.gold:hover { filter: brightness(1.05); transform: translateY(-1px); }
.btn.gold:active { transform: translateY(0); }
.btn.danger { color: var(--status-danger); border-color: #fecaca; }
.btn.full { width: 100%; justify-content: center; }
.btn.sm { height: 40px; padding: 0 14px; font-size: 14px; font-weight: 700; }
.btn[disabled] { opacity: .55; cursor: wait; filter: none; transform: none; }

.form-grid { display: grid; gap: 14px; }
.form-grid label, .form-grid .full { display: grid; gap: 7px; font-size: 14px; font-weight: 650; color: var(--text-secondary); }
.form-grid .btn { font-size: 16px; font-weight: 800; color: inherit; }
.form-grid .full { grid-column: 1 / -1; }
input, select, textarea {
  background: var(--surface-primary); border: 1px solid var(--border-primary);
  border-radius: 12px; padding: 12px 14px; width: 100%;
  font-size: 15px;
}
input:focus, select:focus, textarea:focus {
  outline: 2px solid rgba(255, 75, 75, .22);
  border-color: var(--brand-coral);
}
textarea { resize: vertical; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.check { display: flex !important; flex-direction: row; align-items: center; gap: 10px; color: var(--text) !important; }
.sep { border: 0; border-top: 1px solid var(--line); margin: 8px 0; }
.logo-row { display: flex; gap: 16px; align-items: center; }
.logo-preview { width: 72px; height: 72px; object-fit: contain; background: #fff; border-radius: 16px; padding: 8px; border: 1px solid var(--line); }
.color-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; }
.color-field { display: flex; gap: 8px; align-items: center; }
.color-field input[type=color] { width: 48px; height: 40px; padding: 0; border: 0; background: transparent; }
.brand-preview {
  border-radius: 18px; padding: 22px; background: var(--p);
  display: flex; justify-content: space-between; align-items: center;
  color: #fff;
}
.brand-preview span {
  background: var(--a); color: #1a1408; padding: 10px 18px; border-radius: 999px; font-weight: 700;
}

.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 16px; }
.card-grid.lg { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.thumb-card { color: var(--text); display: grid; gap: 10px; transition: transform .2s ease; }
.thumb-card:hover { transform: translateY(-3px); }
.thumb { border-radius: 16px; overflow: hidden; background: var(--background-secondary); aspect-ratio: 4/5; border: 1px solid var(--border-primary); }
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.thumb-ph { height: 100%; display: grid; place-items: center; color: var(--muted); }
.badge { display: inline-block; padding: 3px 8px; border-radius: 999px; font-size: 11px; background: var(--surface-brand-light); color: var(--text-secondary); }
.badge.ready { color: var(--ok); background: #eaf8ef; }
.badge.failed { color: var(--danger); }
.badge.generating { color: var(--gold); }

.dash-page { display: grid; gap: 18px; }
.dash-welcome {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 20px;
  padding: 28px 28px;
  border-radius: 28px;
  color: #fff;
  background:
    radial-gradient(520px 240px at 92% 10%, rgba(255,255,255,.22), transparent 55%),
    radial-gradient(420px 220px at 0% 100%, rgba(11,16,32,.18), transparent 50%),
    var(--brand-gradient);
  box-shadow: 0 18px 40px rgba(255, 75, 75, .22);
}
.dash-welcome h1 { color: #fff; font-size: 34px; letter-spacing: -.04em; }
.dash-welcome .kicker { color: rgba(255,255,255,.9); display: inline-flex; align-items: center; gap: 6px; }
.dash-welcome .kicker svg { width: 14px; height: 14px; }
.dash-welcome .lede { color: rgba(255,255,255,.9); max-width: 520px; font-size: 15px; }
.dash-welcome-end { display: flex; align-items: center; gap: 14px; }
.dash-welcome .btn.gold {
  background: #fff; color: var(--brand-coral);
  box-shadow: 0 10px 24px rgba(11,16,32,.16);
}
.dash-score {
  width: 76px; height: 76px; border-radius: 50%;
  display: grid; place-items: center; text-align: center;
  background: rgba(255,255,255,.16);
  border: 3px solid rgba(255,255,255,.55);
  color: #fff;
}
.dash-score strong { font-size: 18px; line-height: 1; }
.dash-score span { font-size: 10px; letter-spacing: .08em; text-transform: uppercase; opacity: .85; }

.dash-tiles {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}
.dash-tile {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  background: #fff;
  border: 1px solid var(--border-primary);
  border-radius: 18px;
  padding: 14px 14px;
  color: var(--text-primary);
  box-shadow: var(--shadow);
  transition: transform var(--ease), border-color var(--ease), box-shadow var(--ease);
}
.dash-tile:hover {
  transform: translateY(-3px);
  border-color: #FFC4A8;
  box-shadow: 0 14px 28px rgba(255, 75, 75, .12);
}
.dash-tile-ico {
  width: 44px; height: 44px; border-radius: 14px;
  display: grid; place-items: center;
  background: var(--surface-brand-light);
  color: var(--brand-coral);
  flex: 0 0 44px;
}
.dash-tile-ico svg { width: 20px; height: 20px; }
.dash-tile-copy { min-width: 0; display: grid; gap: 2px; }
.dash-tile-copy strong { font-size: 14px; line-height: 1.25; }
.dash-tile-copy small { color: var(--text-secondary); font-size: 12px; }
.dash-tile-go { width: 16px; height: 16px; color: var(--text-disabled); }
.tone-coral .dash-tile-ico, .dash-kpi.tone-coral .dash-kpi-ico { background: var(--brand-gradient); color: #fff; }
.tone-orange .dash-tile-ico, .dash-kpi.tone-orange .dash-kpi-ico { background: #FFF1E0; color: #E67600; }
.tone-green .dash-tile-ico, .dash-kpi.tone-green .dash-kpi-ico { background: #E8F8EE; color: #16A34A; }
.tone-navy .dash-tile-ico, .dash-kpi.tone-navy .dash-kpi-ico { background: #EEF0F6; color: #0B1020; }
.tone-violet .dash-tile-ico { background: #F3EEFF; color: #7C3AED; }
.tone-blue .dash-tile-ico { background: #E8F1FF; color: #2563EB; }
.tone-peach .dash-tile-ico { background: #FFE8E0; color: #FF4B4B; }
.tone-slate .dash-tile-ico { background: #F1F5F9; color: #475569; }

.dash-setup {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center; gap: 16px; margin: 0;
}
.dash-setup h2 { margin: 0 0 4px; }
.dash-setup p { margin: 0; color: var(--text-secondary); }

.dash-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}
.dash-kpi {
  background: #fff;
  border: 1px solid var(--border-primary);
  border-radius: 20px;
  padding: 18px 18px 16px;
  box-shadow: var(--shadow);
  display: grid;
  gap: 6px;
}
.dash-kpi-ico {
  width: 40px; height: 40px; border-radius: 12px;
  display: grid; place-items: center;
  margin-bottom: 4px;
}
.dash-kpi-ico svg { width: 18px; height: 18px; }
.dash-kpi-label { font-size: 13px; font-weight: 700; color: var(--text-secondary); }
.dash-kpi strong { font-size: 32px; letter-spacing: -.04em; line-height: 1.1; word-break: break-word; }
.dash-kpi small { color: var(--text-secondary); font-size: 12px; }
.dash-kpi .kpi-bar { margin-top: 8px; }
.dash-kpi.tone-green .kpi-bar i { background: #22C55E; }
.dash-kpi.tone-orange .kpi-bar i { background: #FF8A00; }
.dash-kpi.tone-navy .kpi-bar i { background: #0B1020; }

.dash-chip {
  display: inline-flex; align-items: center;
  height: 28px; padding: 0 10px;
  border-radius: 999px;
  background: var(--surface-brand-light);
  color: var(--brand-coral);
  font-size: 12px; font-weight: 800;
}
.dash-charts {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(280px, .85fr);
  gap: 16px;
}
.dash-chart, .dash-donut-card, .dash-mid .panel, .dash-recent { margin-bottom: 0; }
.dash-chart h2, .dash-donut-card h2, .dash-mid h2, .dash-recent h2,
.dash-chart .panel-head h2, .panel-head h2 {
  display: flex; align-items: center; gap: 8px; margin: 0;
}
.dash-page .panel-head h2 svg { width: 18px; height: 18px; color: var(--brand-coral); }
.kpi-bar {
  height: 8px; border-radius: 99px;
  background: var(--background-secondary); margin-top: 10px; overflow: hidden;
}
.kpi-bar i {
  display: block; height: 100%; border-radius: 99px;
  background: var(--brand-gradient);
}
.kpi-bar.ok i { background: var(--status-success); }
.kpi-bar.warn i { background: var(--brand-orange); }
.bars {
  display: grid; grid-template-columns: repeat(14, 1fr);
  gap: 8px; align-items: end; height: 200px;
  padding: 8px 4px 0;
}
.bar {
  display: grid; grid-template-rows: 18px 1fr 18px;
  justify-items: center; height: 100%; gap: 6px;
}
.bar span { font-size: 11px; font-weight: 800; color: var(--text-secondary); min-height: 14px; }
.bar i {
  align-self: end; width: 100%; max-width: 22px;
  border-radius: 10px 10px 6px 6px;
  background: #FFE0D2;
  min-height: 10px;
  transition: height .3s ease;
}
.bar.has-val i { background: var(--brand-gradient); box-shadow: 0 8px 16px rgba(255, 75, 75, .18); }
.bar.is-today i { outline: 2px solid rgba(255, 138, 0, .45); outline-offset: 2px; }
.bar small { font-size: 11px; font-weight: 700; color: var(--text-secondary); }
.bar.is-today small { color: var(--brand-coral); }
.donut-wrap { display: flex; gap: 22px; align-items: center; }
.donut {
  width: 148px; height: 148px; border-radius: 50%;
  display: grid; place-items: center; flex: 0 0 148px;
  box-shadow: 0 12px 28px rgba(11,16,32,.08);
}
.donut > div {
  width: 96px; height: 96px; border-radius: 50%;
  background: #fff; display: grid; place-items: center; text-align: center;
  box-shadow: inset 0 0 0 1px var(--border-primary);
}
.donut strong { font-size: 26px; line-height: 1; letter-spacing: -.04em; }
.donut small { color: var(--text-secondary); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.legend { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; flex: 1; }
.legend li {
  display: flex; align-items: center; gap: 10px; font-size: 14px;
  padding: 8px 10px; border-radius: 12px; background: var(--background-primary);
}
.legend i { width: 10px; height: 10px; border-radius: 99px; flex: 0 0 10px; }
.legend b { margin-left: auto; font-size: 15px; }
.format-bars { display: grid; gap: 16px; }
.format-row { display: grid; grid-template-columns: auto 1fr; gap: 12px; align-items: center; }
.format-ico {
  width: 40px; height: 40px; border-radius: 12px;
  display: grid; place-items: center;
  background: var(--surface-brand-light); color: var(--brand-coral);
}
.format-ico svg { width: 18px; height: 18px; }
.format-meta { min-width: 0; }
.format-meta em { font-style: normal; color: var(--text-disabled); font-size: 12px; font-weight: 600; margin-left: 6px; }
.dash-mid {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(0, 1.2fr) minmax(240px, .8fr);
  gap: 16px;
}
.health-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.health {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px; border-radius: 14px;
  border: 1px solid var(--border-primary); color: var(--text-primary);
  min-height: 58px;
  transition: transform var(--ease);
}
.health:hover { transform: translateY(-1px); }
.health svg { width: 18px; height: 18px; flex: 0 0 18px; }
.health strong, .health small { display: block; }
.health small { color: var(--text-secondary); font-size: 11px; }
.health.on { background: #f3faf5; border-color: #b7d7c1; }
.health.on svg { color: var(--status-success); }
.health.off { background: var(--surface-brand-light); }
.health.off svg { color: var(--brand-orange); }
.dash-agenda { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.dash-agenda li {
  display: grid; grid-template-columns: 84px 1fr auto;
  gap: 10px; align-items: center;
  padding: 10px 12px; border-radius: 12px;
  background: var(--background-primary);
}
.dash-agenda time { font-size: 12px; color: var(--brand-coral); font-weight: 800; }
.dash-empty {
  display: grid; justify-items: center; gap: 8px; text-align: center;
  padding: 28px 12px; color: var(--text-secondary);
}
.dash-empty.wide { grid-column: 1 / -1; }
.dash-empty svg { width: 32px; height: 32px; color: var(--brand-coral); }
.dash-empty p { margin: 0; }

.studio-page {
  display: grid;
  gap: 18px;
}
.studio-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 18px 28px;
  padding: 8px 4px 2px;
}
.studio-hero-copy { min-width: 0; }
.studio-hero h1 { font-size: 32px; margin: 0; letter-spacing: -.04em; }
.studio-hero .kicker { display: inline-flex; align-items: center; gap: 6px; margin: 0 0 6px; }
.studio-hero .kicker svg { width: 14px; height: 14px; }
.studio-hero .lede { margin: 8px 0 0; max-width: 520px; font-size: 15px; color: var(--text-secondary); line-height: 1.5; }
.studio-hero-end { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; justify-content: flex-end; }
.studio-brandchip {
  display: flex; align-items: center; gap: 12px;
  background: #fff;
  border: 1px solid var(--border-primary);
  border-radius: 16px;
  padding: 10px 14px;
  box-shadow: var(--shadow);
}
.studio-brandchip strong { display: block; font-size: 14px; line-height: 1.2; }
.studio-brandchip small { display: block; color: var(--text-secondary); font-size: 12px; }

.studio-atelier {
  display: grid;
  grid-template-columns: minmax(280px, 340px) minmax(0, 1fr) minmax(260px, 320px);
  gap: 0;
  background: #fff;
  border: 1px solid var(--border-primary);
  border-radius: 28px;
  box-shadow: var(--shadow);
  overflow: hidden;
  min-height: 640px;
}
.studio-brief {
  border-right: 1px solid var(--border-primary);
  background: linear-gradient(180deg, #fff 0%, #FFF8F4 100%);
  min-width: 0;
}
.studio-brief-card {
  display: grid;
  gap: 16px;
  padding: 22px 20px 22px;
  margin: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
  border-radius: 0;
}
.studio-col-head { display: flex; align-items: center; gap: 12px; }
.studio-col-head h2 { font-size: 20px; margin: 0; }
.studio-col-head small { display: block; color: var(--text-secondary); font-size: 13px; margin-top: 2px; }
.studio-ico {
  width: 44px; height: 44px; border-radius: 14px;
  display: grid; place-items: center;
  background: var(--brand-gradient);
  color: #fff;
  box-shadow: 0 10px 20px rgba(255, 75, 75, .22);
  flex: 0 0 44px;
}
.studio-ico svg { width: 20px; height: 20px; }
.studio-field { display: grid; gap: 8px; }
.studio-n {
  display: inline-grid; place-items: center;
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--brand-gradient); color: #fff;
  font-size: 11px; font-weight: 800; font-style: normal;
  margin-right: 6px; vertical-align: middle;
}
.studio-brief textarea {
  min-height: 148px;
  font-size: 15px;
  line-height: 1.55;
  border-radius: 16px;
  background: #fff;
}
.studio-brief select {
  font-size: 15px;
  min-height: 50px;
  border-radius: 14px;
  background: #fff;
}
.studio-brief .pe-field span {
  display: inline-flex; align-items: center;
  font-size: 14px; font-weight: 700; color: var(--text-primary);
}

.studio-stage {
  display: grid;
  justify-items: center;
  align-content: start;
  gap: 12px;
  width: 100%;
  min-width: 0;
  padding: 22px 18px 24px;
  background:
    radial-gradient(420px 220px at 50% 12%, rgba(255, 75, 75, .16), transparent 62%),
    radial-gradient(360px 200px at 80% 90%, rgba(255, 138, 0, .12), transparent 55%),
    #FBF7F3;
}
.studio-stage-kicker {
  margin: 0;
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; font-weight: 800; letter-spacing: .12em;
  text-transform: uppercase; color: var(--brand-coral);
}
.studio-stage-kicker svg { width: 14px; height: 14px; }
.poster-stage {
  width: 100%;
  min-height: 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0;
  display: grid;
  place-items: center;
  box-shadow: none;
}
.studio-stage .pe-bezel {
  width: min(100%, 360px);
  background: linear-gradient(180deg, #2c2622, #12100e);
  border-radius: 34px;
  padding: 12px 10px 14px;
  box-shadow:
    0 28px 50px rgba(255, 75, 75, .18),
    0 0 0 8px rgba(255, 255, 255, .35);
}
.studio-stage .poster-phone { width: 100%; box-shadow: none; border-radius: 20px; }
.poster-phone {
  width: 100%;
  aspect-ratio: 4 / 5;
  border-radius: 18px;
  overflow: hidden;
  background: #141210;
  display: grid;
  place-items: center;
}
.poster-phone img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #0f0e0c;
}
.poster-stage.has-poster .canvas-empty { display: none !important; }
.studio-empty-orb {
  width: 56px; height: 56px; border-radius: 18px;
  display: grid; place-items: center;
  background: var(--brand-gradient);
  color: #fff;
  box-shadow: 0 12px 24px rgba(255, 75, 75, .28);
  margin-bottom: 4px;
}
.studio-empty-orb svg { width: 24px; height: 24px; color: #fff; opacity: 1; }
.studio-empty-orb.sm { width: 44px; height: 44px; border-radius: 14px; margin-bottom: 10px; }
.studio-empty-orb.sm svg { width: 20px; height: 20px; }
.canvas-empty {
  text-align: center; color: rgba(255,255,255,.9); padding: 28px 20px;
  line-height: 1.45; display: grid; justify-items: center; gap: 8px;
  font-size: 17px; font-weight: 800;
}
.canvas-empty small { display: block; opacity: .75; font-size: 13px; font-weight: 600; }
.studio-status {
  min-height: 18px;
  margin: 0;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 650;
  text-align: center;
}
.canvas-actions { display: flex; gap: 10px; justify-content: center; margin: 4px 0 0; width: 100%; }
.canvas-actions .btn { min-width: 140px; font-size: 15px; }
#generate-btn {
  height: 54px;
  font-size: 16px;
  font-weight: 800;
  margin-top: 4px;
  box-shadow: 0 14px 28px rgba(255, 75, 75, .28);
}

.studio-copy {
  display: grid;
  align-content: start;
  gap: 0;
  min-width: 0;
  border-left: 1px solid var(--border-primary);
  background: #fff;
}
.studio-copy .panel {
  margin: 0; padding: 22px 20px;
  border: 0; box-shadow: none; border-radius: 0; background: transparent;
}
.studio-hint { text-align: left; }
.studio-hint h2 { font-size: 20px; margin: 0 0 8px; }
.studio-hint-lead { margin: 0 0 16px; font-size: 14px; color: var(--text-secondary); line-height: 1.5; }
.studio-hint-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.studio-hint-list li {
  display: flex; align-items: flex-start; gap: 10px;
  font-size: 14px; color: var(--text-secondary); line-height: 1.45;
  padding: 10px 12px;
  background: var(--background-primary);
  border-radius: 12px;
}
.studio-hint-list svg { width: 16px; height: 16px; color: var(--brand-coral); flex: 0 0 16px; margin-top: 2px; }
.result-panel h2 { display: flex; align-items: center; gap: 8px; font-size: 18px; margin: 0; }
.result-panel h2 svg { width: 18px; height: 18px; color: var(--brand-coral); }

.caption-preview {
  margin: 0 0 10px;
  white-space: pre-wrap;
  line-height: 1.55;
  font-size: 14px;
}
.poster-frame {
  width: min(100%, 420px);
  aspect-ratio: 4 / 5;
  background: #141414;
  border-radius: 22px;
  overflow: hidden;
  display: grid;
  place-items: center;
  box-shadow: 0 24px 48px rgba(255, 75, 75, .16);
}
.poster-frame.has-image { background: #0f0e0c; }
.poster-frame img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #0f0e0c;
}
.recent-strip {
  background: #fff;
  border: 1px solid var(--border-primary);
  border-radius: 20px;
  padding: 14px 16px 16px;
  box-shadow: var(--shadow);
}
.strip-label {
  margin: 0 0 10px;
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--text-secondary);
  font-weight: 800;
  display: flex; align-items: center; gap: 6px;
}
.strip-label svg { width: 14px; height: 14px; color: var(--brand-coral); }
.recent-row { display: flex; gap: 10px; overflow: auto; padding-bottom: 2px; }
.recent-thumb {
  flex: 0 0 76px;
  width: 76px;
  height: 95px;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--surface-brand-light);
  transition: transform var(--ease), box-shadow var(--ease);
}
.recent-thumb:hover { transform: translateY(-3px); box-shadow: 0 12px 22px rgba(255, 75, 75, .16); }
.recent-thumb img { width: 100%; height: 100%; object-fit: cover; }

.canvas-frame {
  background: var(--background-secondary); border: 1px solid var(--line); border-radius: 28px;
  min-height: 640px; display: grid; place-items: center; overflow: hidden;
  box-shadow: var(--shadow);
}
.canvas-frame img { width: 100%; height: auto; }
.steps { list-style: none; padding: 0; margin: 0 0 16px; }
.steps li {
  padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; margin-bottom: 8px;
  color: var(--muted); background: #fff;
}
.steps li.on { border-color: var(--brand-orange); color: var(--brand-coral); background: var(--surface-brand-light); }
.steps li.done { color: var(--ok); border-color: #b7d7c1; }
.chip-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--background-primary); border: 1px solid var(--line); color: var(--text);
  border-radius: 999px; padding: 8px 12px; cursor: pointer; font-size: 13px; font-weight: 650;
}
.chip svg { width: 14px; height: 14px; color: var(--gold); }
.chip:hover, .chip.on { border-color: var(--brand-orange); background: var(--surface-brand-light); }
.prompt-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 6px; }
.prompt-head span { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 700; color: var(--text-primary); }
.prompt-head span svg { width: 14px; height: 14px; color: var(--gold); }
.studio-brief #ideas-btn {
  border-color: #FFC4A8;
  color: var(--brand-coral);
  background: #fff;
}
.pill { display: inline-flex; align-items: center; gap: 6px; border-radius: 999px; padding: 8px 12px; font-size: 12px; border: 1px solid var(--line); background: #fff; white-space: nowrap; }
.pill svg { width: 14px; height: 14px; }
.pill.on { color: var(--brand-coral); background: var(--surface-brand-light); border-color: #FFC4A8; }
.pill.off { color: var(--muted); }
.swatches { display: flex; gap: 8px; }
.swatches i { width: 22px; height: 22px; border-radius: 50%; display: block; border: 1px solid var(--line); }
.meta-list { display: grid; gap: 10px; }
.meta-list dt { color: var(--gold); font-size: 11px; text-transform: uppercase; letter-spacing: .12em; font-weight: 600; }
.meta-list dd { margin: 0; }

.split-page { display: grid; grid-template-columns: minmax(280px, 420px) 1fr; gap: 22px; }
.sticky { position: sticky; top: 20px; }
.row-gap { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.row-gap form { margin: 0; }

.post-studio {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(340px, 420px);
  gap: 24px;
  align-items: start;
}
.post-preview {
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0;
  box-shadow: none;
  min-height: 0;
  display: grid;
  justify-items: center;
}
.post-preview img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 0;
  background: #0f0e0c;
}
.post-preview-col { display: grid; gap: 18px; }
.post-edit-col { display: grid; gap: 0; min-width: 0; }
.post-edit-actions { display: grid; gap: 10px; position: sticky; bottom: 16px; }

.pe-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 22px;
}
.pe-head h1 { font-size: 28px; line-height: 1.15; max-width: 720px; }
.pe-chips, .pe-tools { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.pe-chips { margin-top: 12px; }
.pe-chip {
  display: inline-flex; align-items: center; gap: 6px;
  background: #fff; border: 1px solid var(--line);
  border-radius: 999px; padding: 6px 12px;
  font-size: 12px; color: var(--muted); font-weight: 500;
}
.pe-chip svg { width: 14px; height: 14px; }
.pe-chip.status.ready { color: var(--ok); background: #f3faf5; border-color: #b7d7c1; }
.pe-chip.status.failed { color: var(--danger); background: #fdecea; border-color: #f0b4ae; }
.pe-chip.status.generating { color: var(--gold); background: var(--surface-brand-light); border-color: var(--brand-orange); }
.pe-tools .btn { padding: 9px 14px; }
.pe-tools form { margin: 0; }

.pe-board {
  display: grid;
  grid-template-columns: minmax(320px, 460px) minmax(380px, 1fr);
  gap: 24px;
  align-items: start;
}
.pe-stage { display: grid; gap: 16px; justify-items: center; }
.pe-bezel {
  width: min(100%, 400px);
  background: linear-gradient(180deg, #2a2520, #161310);
  border-radius: 36px;
  padding: 12px 10px 16px;
  box-shadow: 0 36px 70px rgba(28, 22, 12, .28);
}
.pe-notch {
  display: block;
  width: 86px; height: 7px;
  margin: 0 auto 10px;
  background: #3d362e;
  border-radius: 999px;
}
.pe-stage .poster-stage { padding: 18px 16px 20px; }
.pe-stage .poster-phone {
  width: 100%;
  border-radius: 18px;
  box-shadow: none;
}
.pe-caption-preview {
  width: min(100%, 400px);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 16px 18px;
  box-shadow: var(--shadow);
}
.pe-caption-preview h2 {
  margin: 0;
  font-size: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.pe-caption-preview h2 svg { width: 16px; height: 16px; color: var(--gold); }
.pe-caption-preview .caption-body { font-size: 13px; color: var(--muted); }

.pe-desk {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 28px;
  padding: 18px 18px 16px;
  box-shadow: var(--shadow);
  display: grid;
  gap: 16px;
  min-width: 0;
}
.pe-desk-top { display: grid; gap: 14px; }
.pe-brand-mini {
  display: flex; align-items: center; gap: 12px;
}
.pe-brand-mini img, .pe-brand-ph {
  width: 44px; height: 44px; border-radius: 14px;
  object-fit: contain; background: var(--background-secondary);
  border: 1px solid var(--line);
}
.pe-brand-ph { display: grid; place-items: center; color: var(--muted); }
.pe-brand-mini strong { display: block; font-size: 15px; }
.pe-brand-mini small { color: var(--muted); font-size: 12px; }
.pe-tabs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  background: var(--surface-brand-light);
  padding: 5px;
  border-radius: 16px;
}
.pe-tab {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  border: 0; background: transparent; color: #6d675f;
  border-radius: 12px; padding: 10px 8px; cursor: pointer; font-weight: 600; font-size: 13px;
}
.pe-tab svg { width: 16px; height: 16px; }
.pe-tab.on { background: #fff; color: var(--brand-coral); box-shadow: 0 6px 16px rgba(40,32,20,.08); }
.pe-pane { display: grid; gap: 12px; }
.pe-pane[hidden] { display: none !important; }
.pe-hint {
  display: flex; align-items: flex-start; gap: 8px;
  margin: 0; font-size: 13px; color: var(--muted); line-height: 1.45;
  background: #faf6ee; border-radius: 12px; padding: 10px 12px;
}
.pe-hint svg { width: 16px; height: 16px; flex: 0 0 16px; margin-top: 1px; color: var(--gold); }
.pe-field { display: grid; gap: 7px; font-size: 14px; font-weight: 650; color: var(--text-secondary); }
.pe-field em { font-style: normal; font-weight: 400; opacity: .75; }
.pe-field > span { display: inline-flex; align-items: center; gap: 7px; font-weight: 600; }
.pe-field > span svg { width: 15px; height: 15px; color: var(--gold); }
.pe-split { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.pe-toggles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pe-switch {
  position: relative;
  display: flex; align-items: center; gap: 10px;
  margin: 0; padding: 12px 14px;
  border: 1px solid var(--line); border-radius: 14px;
  background: var(--background-secondary); cursor: pointer; color: var(--text);
}
.pe-switch > i {
  position: relative; width: 40px; height: 22px; flex: 0 0 40px;
  background: #e4ddd2; border-radius: 999px; transition: .2s;
}
.pe-switch > i:before {
  content: ""; position: absolute; width: 16px; height: 16px;
  background: #fff; border-radius: 50%; top: 3px; left: 3px; transition: .2s;
}
.pe-switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.pe-switch:has(input:checked) { border-color: var(--brand-orange); background: var(--surface-brand-light); }
.pe-switch:has(input:checked) > i { background: var(--brand-orange); }
.pe-switch:has(input:checked) > i:before { transform: translateX(18px); }
.pe-switch span { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; }
.pe-switch span svg { width: 15px; height: 15px; color: var(--gold); }
.pe-dock {
  position: sticky; bottom: 10px;
  display: grid; grid-template-columns: 1fr 1fr 1.35fr;
  gap: 8px; padding-top: 6px;
}
.pe-dock .btn { justify-content: center; padding: 12px 10px; font-size: 13px; }
.btn.pulse { animation: pe-pulse 1s ease 2; }
@keyframes pe-pulse {
  0%, 100% { transform: scale(1); }
  50% { box-shadow: 0 0 0 6px rgba(196,163,90,.28); transform: scale(1.02); }
}
.pe-ideas h2 { display: flex; align-items: center; gap: 8px; margin: 0; }
.idea-num {
  position: absolute; left: 14px; top: 14px;
  font-style: normal; font-family: Manrope, sans-serif;
  font-size: 18px; color: var(--gold); font-weight: 700;
}
.pe-busy {
  position: fixed; inset: 0;
  background: rgba(28, 25, 21, .55);
  display: grid; place-items: center;
  z-index: 60;
}
.pe-busy[hidden] { display: none !important; }
.pe-busy > div {
  background: #fff; border-radius: 24px; padding: 28px 32px;
  text-align: center; display: grid; gap: 8px; justify-items: center;
  box-shadow: var(--shadow); max-width: 360px;
}
.pe-busy svg { width: 28px; height: 28px; color: var(--gold); }
.pe-busy span { color: var(--muted); font-size: 13px; }

.caption-card .caption-body {
  margin: 0;
  white-space: pre-wrap;
  line-height: 1.55;
  color: var(--text);
}
.hashtag-line { margin: 12px 0 0; color: var(--gold); font-size: 13px; font-weight: 500; }
.check-row { display: flex; flex-wrap: wrap; gap: 16px; }
.check-row .check { margin: 0; }
.page-head .kicker a { color: inherit; }
.prompt-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--muted);
}
.prompt-head { flex-wrap: wrap; margin-bottom: 8px; }
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(11, 16, 32, .45);
  display: grid; place-items: center;
  z-index: 90; padding: 20px;
}
.modal-overlay[hidden] { display: none !important; }
.modal-card {
  width: min(560px, 100%);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 22px;
  box-shadow: var(--shadow);
  max-height: min(80vh, 720px);
  overflow: auto;
}
.ideas-list { display: grid; gap: 10px; margin-top: 14px; }
.idea-card {
  text-align: left;
  width: 100%;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px 16px;
  cursor: pointer;
  color: inherit;
}
.idea-card:hover { border-color: var(--brand-orange); background: var(--surface-brand-light); }
.idea-card strong { display: block; margin-bottom: 6px; }
.idea-card span { display: block; color: var(--muted); font-size: 13px; line-height: 1.45; }
.pe-ideas .idea-card { position: relative; padding: 14px 16px 14px 58px; }
.toast-copy {
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%);
  background: var(--brand-navy); color: var(--brand-white); padding: 10px 16px; border-radius: 999px;
  font-size: 13px; z-index: 80; box-shadow: var(--shadow);
}
.insp-card { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; }
.insp-card img { aspect-ratio: 1; object-fit: cover; width: 100%; }
.insp-card div { padding: 14px; display: grid; gap: 8px; }

.insp-page { display: grid; gap: 18px; }
.insp-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px 24px;
  background: #fff; border: 1px solid var(--border-primary);
  border-radius: 18px; padding: 18px 20px;
}
.insp-toolbar-copy { min-width: 0; }
.insp-toolbar h1 { font-size: 26px; }
.insp-toolbar .kicker { display: inline-flex; align-items: center; gap: 6px; margin: 0 0 4px; }
.insp-toolbar .kicker svg { width: 14px; height: 14px; }
.insp-toolbar .lede { margin: 6px 0 0; max-width: 520px; font-size: 13px; }
.insp-toolbar-end {
  display: flex; align-items: center; gap: 12px;
  justify-self: end;
}
.insp-stats-row {
  display: flex; align-items: center; gap: 2px;
  margin: 0;
  padding: 4px;
  background: var(--background-primary);
  border: 1px solid var(--border-primary);
  border-radius: 14px;
}
.insp-stats-row span {
  display: inline-flex; align-items: center; gap: 6px;
  background: transparent; border-radius: 10px;
  padding: 8px 12px; font-size: 12px; color: var(--text-secondary); font-weight: 650;
  white-space: nowrap;
}
.insp-stats-row span:first-child { background: #fff; color: var(--text-primary); }
.insp-stats-row svg { width: 14px; height: 14px; color: var(--brand-coral); }
.insp-toolbar-end .btn { height: 44px; padding: 0 16px; white-space: nowrap; }
.insp-intake { display: grid; gap: 14px; margin: 0; padding: 4px 0 0; background: none; border: 0; box-shadow: none; }
.insp-label {
  margin: 0; display: flex; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 600; color: var(--muted);
}
.insp-label svg { width: 16px; height: 16px; color: var(--gold); }
.insp-types { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.insp-type {
  text-align: left; background: var(--background-secondary); border: 1px solid var(--line);
  border-radius: 16px; padding: 14px; cursor: pointer; color: inherit;
  display: grid; gap: 4px;
}
.insp-type svg { width: 22px; height: 22px; color: var(--gold); }
.insp-type strong { font-size: 14px; }
.insp-type span { font-size: 12px; color: var(--muted); line-height: 1.35; }
.insp-type:hover, .insp-type.on { border-color: var(--brand-orange); background: var(--surface-brand-light); }
.insp-fields { display: grid; gap: 12px; }
.insp-drop {
  display: grid; justify-items: center; gap: 6px; text-align: center;
  border: 1px dashed var(--line); border-radius: 18px; padding: 18px;
  background: var(--background-secondary); cursor: pointer; color: var(--muted); position: relative;
}
.insp-drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.insp-drop svg { width: 22px; height: 22px; color: var(--gold); }
.insp-drop strong { color: var(--text); font-size: 14px; }
.insp-drop small { font-size: 12px; }
.insp-drop.on, .insp-drop.required { border-color: var(--brand-orange); }
.insp-drop.has-file { padding: 10px; }
.insp-drop img { max-height: 140px; width: auto; border-radius: 12px; }
.insp-board {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(460px, 1fr));
  gap: 16px;
}
.insp-vision {
  background: #fff; border: 1px solid var(--line); border-radius: 20px;
  overflow: hidden; box-shadow: var(--shadow);
  display: grid; grid-template-columns: 148px minmax(0, 1fr);
  min-height: 220px;
}
.insp-cover { position: relative; background: #161616; min-height: 100%; }
.insp-cover img { width: 100%; height: 100%; object-fit: cover; }
.insp-cover-ph { height: 100%; min-height: 220px; display: grid; place-items: center; color: rgba(255,255,255,.45); background: var(--brand-gradient); }
.insp-cover-ph svg { width: 36px; height: 36px; color: #fff; }
.insp-kind {
  position: absolute; left: 10px; top: 10px;
  display: inline-flex; align-items: center; gap: 4px;
  background: rgba(255,255,255,.94); border-radius: 999px;
  padding: 4px 10px; font-size: 11px; font-weight: 700; letter-spacing: .04em;
  text-transform: uppercase; color: var(--brand-coral);
}
.insp-kind svg { width: 12px; height: 12px; }
.insp-body {
  padding: 16px 16px 0;
  display: flex; flex-direction: column; gap: 8px; min-width: 0;
}
.insp-body-top { min-width: 0; }
.insp-body h2 {
  margin: 0; font-size: 17px; line-height: 1.25;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.insp-meta { margin: 4px 0 0; font-size: 12px; color: var(--gold); font-weight: 600; text-transform: capitalize; }
.insp-vision-text {
  margin: 0; font-size: 13px; color: var(--muted); line-height: 1.45;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.insp-swatches { display: flex; gap: 6px; }
.insp-swatches i { width: 16px; height: 16px; border-radius: 50%; border: 1px solid var(--line); display: block; }
.insp-lessons { display: flex; flex-wrap: wrap; gap: 6px; }
.insp-lessons span {
  background: var(--surface-brand-light); color: var(--brand-navy); border-radius: 999px;
  padding: 4px 10px; font-size: 11px; font-weight: 600;
  max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.insp-source { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; }
.insp-source svg { width: 14px; height: 14px; }
.insp-actions {
  display: flex; align-items: center; gap: 6px;
  margin-top: auto;
  padding: 10px 0 12px;
  border-top: 1px solid var(--border-primary);
}
.insp-actions form { margin: 0; }
.insp-actions a, .insp-actions button {
  display: inline-flex; align-items: center; gap: 6px;
  height: 34px; padding: 0 10px;
  border: 0; background: var(--background-primary);
  border-radius: 10px; color: var(--text-secondary);
  font-weight: 650; font-size: 12px; cursor: pointer;
}
.insp-actions a:hover, .insp-actions button:hover { background: var(--surface-brand-light); color: var(--brand-coral); }
.insp-actions svg { width: 14px; height: 14px; }
.insp-actions .is-danger { margin-left: auto; padding: 0 9px; color: var(--status-danger); }
.insp-actions .is-danger:hover { background: #fdecea; }
.insp-empty {
  text-align: center; padding: 64px 24px; color: var(--muted);
  background: #fff; border: 1px solid var(--border-primary); border-radius: 24px;
  display: grid; justify-items: center; gap: 8px;
}
.insp-empty svg { width: 44px; height: 44px; color: var(--brand-coral); }
.insp-empty h2 { margin: 4px 0; color: var(--text-primary); }
.insp-empty p { max-width: 480px; margin: 0; }
.insp-modal { width: min(640px, 100%); max-height: min(90vh, 820px); overflow: auto; }

.gen-overlay {
  position: fixed; inset: 0;
  background: rgba(18, 15, 12, .58);
  backdrop-filter: blur(10px);
  display: grid; place-items: center;
  z-index: 80; padding: 20px;
}
.gen-overlay[hidden] { display: none !important; }
.gen-card {
  width: min(440px, 100%);
  background: #fff;
  border-radius: 28px;
  padding: 32px 28px 24px;
  text-align: center;
  box-shadow: 0 30px 70px rgba(28, 22, 12, .28);
  animation: gen-pop .45s cubic-bezier(.2, .9, .2, 1);
}
@keyframes gen-pop {
  from { opacity: 0; transform: translateY(16px) scale(.96); }
  to { opacity: 1; transform: none; }
}
.gen-orb {
  width: 88px; height: 88px; margin: 0 auto 18px;
  position: relative; display: grid; place-items: center;
  color: var(--brand-coral);
}
.gen-orb > svg { width: 28px; height: 28px; z-index: 2; }
.gen-ring, .gen-spark {
  position: absolute; inset: 0; border-radius: 50%;
}
.gen-ring {
  border: 2px solid transparent;
  border-top-color: var(--brand-orange);
  border-right-color: rgba(196,163,90,.35);
  animation: gen-spin 1.1s linear infinite;
}
.gen-ring-2 {
  inset: 8px;
  border-top-color: var(--brand-orange);
  animation-duration: 1.8s;
  animation-direction: reverse;
}
.gen-spark {
  background: radial-gradient(circle, rgba(227,197,122,.45), transparent 62%);
  animation: gen-pulse 1.6s ease-in-out infinite;
}
@keyframes gen-spin { to { transform: rotate(360deg); } }
@keyframes gen-pulse {
  0%, 100% { transform: scale(.85); opacity: .7; }
  50% { transform: scale(1.08); opacity: 1; }
}
.gen-card h2 { margin: 0 0 8px; font-size: 24px; }
.gen-tip {
  margin: 0 0 18px; color: var(--muted); font-size: 14px; min-height: 42px; line-height: 1.45;
}
.gen-tip.swap { animation: gen-fade .45s ease; }
@keyframes gen-fade {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: none; }
}
.gen-bar {
  height: 8px; background: var(--surface-brand-light); border-radius: 999px; overflow: hidden;
}
.gen-bar i {
  display: block; height: 100%; width: 4%;
  background: var(--brand-gradient);
  border-radius: inherit;
  transition: width .25s ease;
}
.gen-pct { margin: 8px 0 16px; font-weight: 700; color: var(--brand-coral); font-size: 13px; }
.gen-steps {
  list-style: none; padding: 0; margin: 0 0 16px;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px;
}
.gen-steps li {
  margin: 0; font-size: 11px; font-weight: 600;
  color: var(--muted); background: var(--background-secondary); border: 1px solid var(--line);
  border-radius: 12px; padding: 8px 4px;
  display: grid; justify-items: center; gap: 4px;
}
.gen-steps svg { width: 14px; height: 14px; }
.gen-steps li.on { color: var(--brand-coral); background: var(--surface-brand-light); border-color: var(--brand-orange); animation: gen-step .9s ease infinite; }
.gen-steps li.done { color: var(--ok); background: #f3faf5; border-color: #b7d7c1; }
@keyframes gen-step {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-2px); }
}
.gen-card.ok .gen-ring, .gen-card.err .gen-ring { animation: none; border-color: transparent; }
.gen-card.ok .gen-orb { color: var(--ok); }
.gen-card.err .gen-orb { color: var(--danger); }
.gen-card #gen-close { width: 100%; justify-content: center; }

.extract { white-space: pre-wrap; font-size: 12px; color: var(--muted); max-height: 240px; overflow: auto; }

.calendar {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px;
}
.cal-page { display: grid; gap: 16px; }
.cal-toolbar {
  display: flex; flex-wrap: wrap; align-items: center; gap: 14px;
  background: #fff; border: 1px solid var(--border-primary);
  border-radius: 16px; padding: 14px 16px;
}
.cal-toolbar h1 { font-size: 26px; }
.cal-toolbar .kicker { display: inline-flex; align-items: center; gap: 6px; margin: 0 0 4px; }
.cal-toolbar .kicker svg { width: 14px; height: 14px; }
.cal-stats { display: flex; gap: 8px; flex-wrap: wrap; margin-left: auto; }
.cal-stats span {
  background: var(--background-primary); border-radius: 999px;
  padding: 6px 10px; font-size: 12px; color: var(--text-secondary);
}
.cal-stats .st-planned { background: #fff4e5; color: #c2410c; }
.cal-stats .st-ready { background: #eaf8ef; color: var(--ok); }
.cal-actions { display: flex; align-items: center; gap: 8px; }
.cal-actions .btn.is-now { border-color: #FFC4A8; background: var(--surface-brand-light); color: var(--brand-coral); }
.cal-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 16px;
  align-items: start;
}
.cal-h {
  color: var(--text-secondary); font-size: 12px; font-weight: 700;
  letter-spacing: .08em; text-transform: uppercase; padding: 4px 8px;
}
.cal-day {
  min-height: 128px; background: #fff; border: 1px solid var(--border-primary);
  border-radius: 14px; padding: 8px; display: grid; align-content: start; gap: 6px;
}
.cal-day.empty { background: transparent; border: 0; min-height: 0; }
.cal-day.is-weekend { background: #fafbfc; }
.cal-day.is-today { border-color: var(--brand-orange); box-shadow: inset 0 0 0 1px rgba(255,138,0,.35); }
.cal-day-top { display: flex; justify-content: space-between; align-items: center; }
.cal-day-top strong { font-size: 13px; }
.cal-day.is-today .cal-day-top strong {
  width: 26px; height: 26px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--brand-gradient); color: #fff; font-size: 12px;
}
.cal-day-add {
  width: 24px; height: 24px; border: 0; border-radius: 8px;
  background: transparent; color: var(--text-disabled); cursor: pointer;
  display: grid; place-items: center; opacity: 0;
}
.cal-day:hover .cal-day-add, .cal-day-add:focus { opacity: 1; }
.cal-day-add:hover { background: var(--surface-brand-light); color: var(--brand-coral); }
.cal-day-add svg { width: 14px; height: 14px; }
.cal-ev {
  display: flex; justify-content: space-between; align-items: flex-start; gap: 6px;
  border-radius: 10px; padding: 6px 8px; font-size: 12px; font-weight: 600;
}
.cal-ev.idea { background: #f1f5f9; color: #475569; }
.cal-ev.planned { background: #fff4e5; color: #c2410c; }
.cal-ev.ready { background: #eaf8ef; color: #15803d; }
.cal-ev.published { background: var(--surface-brand-light); color: var(--brand-coral); }
.cal-ev-main { display: flex; gap: 6px; min-width: 0; }
.cal-ev-main svg { width: 13px; height: 13px; flex: 0 0 13px; margin-top: 2px; }
.cal-ev-main span { min-width: 0; }
.cal-ev-main time { display: block; font-size: 10px; opacity: .75; font-weight: 700; }
.cal-ev-acts { display: flex; gap: 2px; flex: 0 0 auto; }
.cal-ev-acts a, .cal-ev-acts button {
  width: 22px; height: 22px; border: 0; background: transparent; color: inherit;
  border-radius: 6px; cursor: pointer; display: grid; place-items: center; padding: 0;
}
.cal-ev-acts svg { width: 12px; height: 12px; }
.cal-ev-acts a:hover, .cal-ev-acts button:hover { background: rgba(255,255,255,.55); }
.cal-agenda { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.cal-agenda li {
  display: grid; grid-template-columns: 1fr auto; gap: 2px 8px;
  padding: 10px 12px; border-radius: 12px; background: var(--background-primary);
}
.cal-agenda time { font-size: 11px; color: var(--text-secondary); font-weight: 700; }
.cal-agenda strong { grid-column: 1; font-size: 13px; }
.cal-agenda small { grid-column: 1; color: var(--text-secondary); font-size: 11px; }
.cal-agenda .cal-ev-acts { grid-column: 2; grid-row: 1 / span 3; align-self: center; }
.cal-agenda .icon-btn { width: 32px; height: 32px; }
.cal-legend h2 { font-size: 16px; }
.cal-legend ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.cal-legend li { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.cal-legend li svg { width: 16px; height: 16px; }
.cal-legend li b { margin-left: auto; }
.cal-legend .idea { color: #475569; }
.cal-legend .planned { color: #c2410c; }
.cal-legend .ready { color: #15803d; }
.cal-legend .published { color: var(--brand-coral); }
.cal-modal { width: min(520px, 100%); }
.cal-side .panel-head h2 { display: flex; align-items: center; gap: 8px; font-size: 16px; margin: 0; }
.cal-side .panel-head h2 svg { width: 16px; height: 16px; color: var(--brand-coral); }

.flash-stack { display: grid; gap: 8px; margin-bottom: 16px; }
.flash { padding: 12px 14px; border-radius: 12px; }
.flash.ok { background: #e8f6ee; color: var(--ok); }
.flash.err { background: #fdecea; color: var(--danger); }
.flash.info { background: #e8f3f1; color: var(--cyan); }
.muted { color: var(--muted); }
.ai-box { border-color: var(--brand-orange); background: #fffdf8; }
.ai-box h2 { margin-bottom: 8px; }
.ai-box .full { display: grid; gap: 7px; margin: 12px 0; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }

.auth-body { min-height: 100vh; margin: 0; background: var(--background-primary); }
.auth-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(280px, 0.9fr) minmax(420px, 1.1fr);
}
.auth-hero {
  position: relative;
  overflow: hidden;
  padding: 48px 44px;
  color: #fff;
  display: grid;
  align-content: center;
  background:
    radial-gradient(640px 380px at 8% 0%, rgba(255,255,255,.2), transparent 55%),
    radial-gradient(520px 320px at 100% 100%, rgba(11,16,32,.22), transparent 52%),
    var(--brand-gradient);
}
.auth-hero-inner { max-width: 440px; display: grid; gap: 16px; position: relative; z-index: 1; }
.auth-hero::after {
  content: "";
  position: absolute; right: -80px; bottom: -90px;
  width: 340px; height: 340px; border-radius: 36px;
  border: 16px solid rgba(255,255,255,.12);
  transform: rotate(16deg);
  pointer-events: none;
}
.auth-hero-brand {
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 8px;
}
.auth-hero-brand img { width: 48px; height: 48px; object-fit: contain; }
.auth-hero-brand strong {
  font-size: 24px; font-weight: 800; letter-spacing: -.04em; color: #fff;
}
.auth-hero-brand em { font-style: normal; color: #fff; }
.auth-hero h2 {
  margin: 0;
  font-size: clamp(26px, 3vw, 38px);
  line-height: 1.15;
  color: #fff;
}
.auth-hero p { margin: 0; color: rgba(255,255,255,.88); font-size: 15px; line-height: 1.5; }
.auth-points { list-style: none; padding: 8px 0 0; margin: 0; display: grid; gap: 10px; }
.auth-points li {
  display: flex; align-items: center; gap: 10px;
  font-weight: 650; color: #fff; font-size: 14px;
}
.auth-points svg { width: 18px; height: 18px; flex: 0 0 18px; }
.auth-panel {
  background: var(--background-primary);
  display: grid;
  place-items: center;
  padding: 40px 32px;
}
.auth-card {
  width: min(400px, 100%);
  background: #fff;
  border: 1px solid var(--border-primary);
  border-radius: 24px;
  box-shadow: var(--shadow);
  padding: 32px 28px;
}
.auth-card h1 { font-size: 28px; }
.auth-lead { color: var(--text-secondary); margin: 8px 0 22px; font-size: 14px; }
.auth-field {
  display: flex; align-items: center; gap: 8px;
  border: 1px solid var(--border-primary);
  background: var(--background-primary);
  border-radius: 14px; padding: 0 12px;
  min-height: 50px;
}
.auth-field:focus-within {
  border-color: var(--brand-orange);
  box-shadow: 0 0 0 4px rgba(255, 138, 0, .12);
  background: #fff;
}
.auth-field svg { width: 18px; height: 18px; color: var(--text-secondary); flex: 0 0 18px; }
.auth-field input {
  border: 0 !important; background: transparent !important;
  padding: 12px 0 !important; outline: none !important; box-shadow: none !important;
  flex: 1; min-width: 0; width: auto;
}
.auth-eye {
  border: 0; background: transparent; color: var(--text-secondary);
  width: 36px; height: 36px; border-radius: 10px; cursor: pointer;
  display: grid; place-items: center;
}
.auth-eye:hover { background: #fff; color: var(--text-primary); }
.auth-submit {
  height: 50px !important; margin-top: 6px;
  color: #fff !important; font-weight: 800;
  box-shadow: 0 12px 24px rgba(255, 75, 75, .28);
}
.auth-submit svg { width: 18px; height: 18px; }
.auth-alt { text-align: center; color: var(--muted); margin: 18px 0 0; }
.auth-panel .flash-stack { width: min(440px, 100%); }

@media (max-width: 900px) {
  .auth-body {
    min-height: 100vh;
    min-height: 100dvh;
    background: var(--brand-gradient);
  }
  .auth-shell {
    grid-template-columns: 1fr;
    grid-template-rows: auto minmax(0, 1fr);
    min-height: 100vh;
    min-height: 100dvh;
  }
  .auth-hero {
    padding: 16px 20px 32px;
    align-content: start;
    min-height: 0;
  }
  .auth-hero-inner { gap: 0; max-width: none; }
  .auth-hero h2,
  .auth-hero p,
  .auth-points { display: none; }
  .auth-hero::after { display: none; }
  .auth-hero-brand { margin: 0; }
  .auth-hero-brand img { width: 40px; height: 40px; }
  .auth-hero-brand strong { font-size: 20px; }
  .auth-panel {
    padding: 0;
    place-items: stretch;
    align-content: start;
    background: #fff;
    border-radius: 28px 28px 0 0;
    margin-top: -18px;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
  }
  .auth-card {
    width: 100%;
    max-width: none;
    border: 0;
    box-shadow: none;
    border-radius: 28px 28px 0 0;
    padding: 22px 20px calc(24px + env(safe-area-inset-bottom, 0px));
  }
  .auth-card .kicker { margin-bottom: 4px; }
  .auth-card h1 { font-size: 24px; }
  .auth-lead { margin: 4px 0 14px; font-size: 13px; }
  .auth-card .form-grid { gap: 12px; }
  .auth-submit { margin-top: 4px; }
  .auth-alt { margin: 14px 0 0; }
  .auth-panel .flash-stack {
    width: 100%;
    padding: 16px 20px 0;
    box-sizing: border-box;
  }
}
.checks { list-style: none; padding: 0; display: grid; gap: 6px; }
.checks li { padding: 8px 10px; border-radius: 10px; background: var(--background-secondary); }
.checks .on { color: var(--ok); }
.checks .off { color: var(--danger); }
.empty-hero { padding: 80px 20px; text-align: center; }

.brand-hq { display: grid; gap: 16px; }
.hq-page { display: grid; gap: 16px; }
.hq-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px 24px;
  background: #fff; border: 1px solid var(--border-primary);
  border-radius: 18px; padding: 18px 20px;
}
.hq-toolbar h1 { font-size: 26px; }
.hq-toolbar .kicker { display: inline-flex; align-items: center; gap: 6px; margin: 0 0 4px; }
.hq-toolbar .kicker svg { width: 14px; height: 14px; }
.hq-toolbar .lede { margin: 6px 0 0; max-width: 560px; font-size: 13px; }
.hq-toolbar-end { display: flex; align-items: center; gap: 10px; }
.hq-score {
  background: var(--surface-brand-light); color: var(--brand-coral);
  border-radius: 999px; padding: 8px 12px; font-size: 12px; font-weight: 700;
}
.panel-head h2 { display: flex; align-items: center; gap: 8px; margin: 0; font-size: 18px; }
.panel-head h2 svg { width: 18px; height: 18px; color: var(--brand-coral); }
.hq-assist-row {
  display: grid; grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px; align-items: end;
}
.hq-assist-row label { display: grid; gap: 7px; font-size: 13px; color: var(--muted); }
.brand-hero {
  display: grid;
  grid-template-columns: 180px minmax(0, 1.2fr) minmax(220px, 280px);
  gap: 20px;
  align-items: center;
}
.logo-drop {
  display: grid;
  justify-items: center;
  gap: 10px;
  cursor: pointer;
  padding: 12px;
  border: 1px dashed var(--line);
  border-radius: 20px;
  background: var(--surface-2);
  text-align: center;
}
.logo-drop.on { border-color: var(--brand-orange); background: var(--surface-brand-light); }
.logo-drop-preview {
  width: 132px;
  height: 132px;
  border-radius: 22px;
  background: #fff;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--line);
}
.logo-drop-preview img { max-width: 88%; max-height: 88%; object-fit: contain; }
.logo-drop-ph { color: var(--muted); font-size: 13px; padding: 12px; display: grid; justify-items: center; gap: 6px; }
.logo-drop-ph svg { width: 22px; height: 22px; color: var(--brand-coral); }
.brand-hero-copy { display: grid; gap: 12px; }
.brand-hero-copy label { display: grid; gap: 7px; font-size: 13px; color: var(--muted); }
.brand-hero-copy label span { display: inline-flex; align-items: center; gap: 6px; }
.brand-hero-copy label svg { width: 14px; height: 14px; color: var(--brand-coral); }
.hero-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.live-brand-card {
  background: var(--p);
  color: var(--t, #fff);
  border-radius: 22px;
  padding: 20px;
  min-height: 180px;
  display: grid;
  align-content: start;
  gap: 8px;
  box-shadow: var(--shadow);
}
.live-brand-card small { opacity: .75; font-size: 11px; letter-spacing: .14em; text-transform: uppercase; }
.live-brand-card strong { font-size: 22px; line-height: 1.1; }
.live-brand-card em { font-style: normal; opacity: .85; font-size: 13px; }
.live-cta {
  justify-self: start;
  background: var(--a);
  color: #1a1408;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  margin-top: 6px;
}
.swatches.lg i { width: 18px; height: 18px; }
.brand-colors { margin: 16px 0; }
.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 10px;
  margin-top: 12px;
}
.category-chip {
  display: flex !important;
  flex-direction: row;
  align-items: center;
  gap: 10px;
  margin: 0;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  color: var(--text) !important;
  cursor: pointer;
}
.category-chip svg { width: 16px; height: 16px; color: var(--brand-coral); flex: 0 0 16px; }
.category-chip:has(input:checked) {
  border-color: var(--brand-orange);
  background: var(--surface-brand-light);
}
.category-chip input { width: 16px; height: 16px; accent-color: var(--brand-coral); }
.hq-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.hq-save {
  position: sticky;
  bottom: 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 14px 18px;
  box-shadow: var(--shadow);
  z-index: 5;
}
.hq-save p { margin: 0; display: flex; align-items: center; gap: 8px; }
.hq-save p svg { width: 16px; height: 16px; color: var(--brand-coral); }

@media (max-width: 1280px) {
  .studio-atelier { grid-template-columns: minmax(250px, 300px) minmax(0, 1fr) minmax(230px, 280px); }
  .studio-stage .pe-bezel { width: min(100%, 300px); }
  .studio-hero h1 { font-size: 28px; }
}

@media (max-width: 1100px) {
  .shell { grid-template-columns: 1fr; }
  html.nav-mini { --sidebar-w: 300px; }
  html.nav-mini .nav-text,
  html.nav-mini .side-label,
  html.nav-mini .side-who { display: initial; }
  html.nav-mini .brand { justify-content: flex-start; height: 64px; }
  html.nav-mini .brand-logo {
    display: block !important;
    width: auto; height: 52px; max-width: 210px;
    object-fit: contain; object-position: left center;
  }
  html.nav-mini .brand-mark { display: none !important; }
  html.nav-mini .brand-row { flex-direction: row; justify-content: space-between; min-height: 64px; }
  html.nav-mini .sidebar { padding: 14px 12px; align-items: stretch; }
  html.nav-mini .side-nav { justify-items: stretch; }
  html.nav-mini .side-nav a { width: auto; padding: 0 12px; justify-content: flex-start; }
  html.nav-mini .side-logout { width: 100%; padding: 0; }
  html.nav-mini .sidebar-foot { justify-items: stretch; }
  .sidebar {
    position: fixed; inset: 0 auto 0 0;
    width: min(300px, 88vw);
    transform: translateX(-110%);
    transition: transform 220ms ease;
    z-index: 70;
  }
  .sidebar.is-open { transform: none; }
  .burger { display: grid; grid-column: 1; }
  .desktop-only, .sidebar .collapse-btn { display: none; }
  .app-header {
    padding: 0 12px;
    display: grid;
    grid-template-columns: 40px minmax(0, 1fr) 40px;
    align-items: center;
    gap: 8px;
  }
  .head-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
    height: 64px;
    grid-column: 2;
  }
  .head-logo img {
    height: 40px;
    width: auto;
    max-width: min(210px, 58vw);
    object-fit: contain;
  }
  .head-balance { display: block; width: 40px; height: 40px; grid-column: 3; }
  .head-search, .head-shortcuts, .head-cta { display: none !important; }

  .tabbar {
    display: grid;
    grid-template-columns: 1fr 1fr 72px 1fr 1fr;
    align-items: end;
    position: fixed;
    left: 0; right: 0; bottom: 0;
    z-index: 60;
    padding: 22px 4px max(10px, env(safe-area-inset-bottom, 0px));
    background: #fff;
    border-top: 1px solid var(--border-primary);
    box-shadow: 0 -12px 32px rgba(11, 16, 32, .10);
  }
  .tab {
    display: grid;
    justify-items: center;
    gap: 3px;
    padding: 6px 2px 4px;
    color: var(--text-secondary);
    font-size: 11px;
    font-weight: 700;
    background: transparent;
    border: 0;
    cursor: pointer;
    text-decoration: none;
    min-width: 0;
  }
  .tab svg { width: 22px; height: 22px; }
  .tab.is-active { color: var(--brand-coral); }
  .tab-fab {
    display: grid;
    justify-items: center;
    align-content: end;
    gap: 4px;
    position: relative;
    color: var(--text-secondary);
    font-size: 11px;
    font-weight: 800;
    text-decoration: none;
    padding-bottom: 4px;
    z-index: 2;
  }
  .tab-fab-btn {
    position: absolute;
    left: 50%;
    bottom: 22px;
    transform: translateX(-50%);
    width: 58px; height: 58px;
    border-radius: 50%;
    display: grid; place-items: center;
    background: var(--brand-gradient);
    color: #fff;
    box-shadow: 0 10px 22px rgba(255, 75, 75, .38);
    border: 5px solid #F6F7FB;
  }
  .tab-fab-btn svg { width: 26px; height: 26px; stroke-width: 2.6; color: #fff; }
  .tab-fab.is-active { color: var(--brand-coral); }
  .tab-fab.is-active .tab-fab-btn {
    box-shadow: 0 10px 22px rgba(255, 75, 75, .38), 0 0 0 3px rgba(255, 138, 0, .25);
  }

  .nav-backdrop {
    display: block; position: fixed; inset: 0;
    background: rgba(11, 16, 32, .45); z-index: 65;
  }
  .nav-backdrop[hidden] { display: none !important; }

  .studio, .split-page, .stat-grid, .color-grid, .post-studio, .studio-atelier, .brand-hero, .hq-grid, .pe-board,
  .dash-charts, .dash-mid, .dash-grid, .dash-grid.two, .cal-layout { grid-template-columns: 1fr; }
  .dash-kpis { grid-template-columns: 1fr 1fr; }
  .dash-tiles, .health-grid { grid-template-columns: 1fr; }
  .dash-welcome {
    grid-template-columns: 1fr;
    padding: 20px 18px;
    border-radius: 22px;
  }
  .dash-welcome h1 { font-size: 26px; }
  .dash-welcome-end { width: 100%; justify-content: space-between; }
  .dash-welcome .btn.gold { display: none; }
  .dash-tile { padding: 12px; }
  .donut-wrap { flex-wrap: wrap; }
  .donut { flex: 0 0 120px; width: 120px; height: 120px; }
  .donut > div { width: 78px; height: 78px; }
  .hq-toolbar { grid-template-columns: 1fr; }
  .hq-assist-row { grid-template-columns: 1fr; }
  .insp-toolbar { grid-template-columns: 1fr; }
  .insp-toolbar-end { justify-self: stretch; justify-content: space-between; }
  .insp-types { grid-template-columns: 1fr; }
  .insp-board { grid-template-columns: 1fr; }
  .insp-vision { grid-template-columns: 1fr; }
  .insp-cover { min-height: 160px; aspect-ratio: 16 / 9; }
  .studio-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 0 2px;
  }
  .studio-hero .kicker,
  .studio-hero .lede,
  .studio-brandchip { display: none !important; }
  .studio-hero h1 { font-size: 22px; }
  .studio-hero-end { width: auto; margin: 0; }
  .studio-page { gap: 12px; }
  .studio-atelier {
    display: block;
    background: transparent;
    border: 0;
    box-shadow: none;
    min-height: 0;
    overflow: visible;
    border-radius: 0;
  }
  .studio-brief {
    background: #fff;
    border: 1px solid var(--border-primary);
    border-radius: 22px;
    box-shadow: var(--shadow);
  }
  .studio-stage,
  .studio-copy,
  .studio-hint,
  .recent-strip { display: none !important; }
  .studio-page.has-result .studio-stage {
    display: grid !important;
    margin-top: 12px;
    padding: 16px 12px;
    background: #fff;
    border: 1px solid var(--border-primary);
    border-radius: 22px;
    box-shadow: var(--shadow);
  }
  .studio-page.has-result .studio-copy {
    display: block !important;
    margin-top: 12px;
    background: #fff;
    border: 1px solid var(--border-primary);
    border-radius: 22px;
    box-shadow: var(--shadow);
  }
  .studio-page.has-result .studio-hint { display: none !important; }
  .studio-page.has-result .result-panel { display: block; }
  .studio-brief-card { padding: 16px 14px 18px; gap: 14px; }
  .studio-col-head h2 { font-size: 18px; }
  .studio-brief textarea { min-height: 120px; }
  .studio-brief .prompt-head {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
  }
  .studio-brief #ideas-btn {
    width: auto;
    height: 36px;
    padding: 0 12px;
    font-size: 13px;
    flex: 0 0 auto;
  }
  .studio-gen-bar {
    position: static;
    margin: 2px 0 0;
    padding: 0;
    background: none;
  }
  #generate-btn {
    height: 52px;
    font-size: 16px;
    box-shadow: 0 10px 22px rgba(255, 75, 75, .28);
  }
  .studio-copy .panel { padding: 16px 14px; }
  .studio-stage .pe-bezel { width: min(100%, 230px); }
  .canvas-actions { width: 100%; }
  .canvas-actions .btn { flex: 1; min-width: 0; }
  .modal-overlay { padding: 12px 12px 100px; align-items: end; }
  .pe-dock, .pe-toggles, .pe-split { grid-template-columns: 1fr; }
  .studio-brief, .studio-copy { position: static; max-height: none; }
  .studio-atelier { overflow: visible; }
  .split { grid-template-columns: 1fr; }
  .hq-save { flex-wrap: wrap; position: static; }
  .panel { padding: 16px; }
  .main { padding: 14px 14px calc(132px + env(safe-area-inset-bottom, 0px)); }
}

@media (max-width: 720px) {
  h1 { font-size: 26px; }
  .page-head, .pe-head, .studio-hero { flex-direction: column; align-items: flex-start; }
  .dash-agenda li { grid-template-columns: 1fr; }
  .dash-kpis, .stat-grid { grid-template-columns: 1fr 1fr; }
  .color-grid { grid-template-columns: 1fr 1fr; }
  .card-grid, .card-grid.lg { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .bars { height: 150px; gap: 3px; }
  .bar i { max-width: 14px; }
  .bar span, .bar small { font-size: 9px; }
  .format-meta em { display: none; }
  .studio-hero h1 { font-size: 22px; }
  .studio-stage .pe-bezel { width: min(100%, 220px); }
}
