:root {
  --teal: #2A6478;
  --teal-light: #4a9bb5;
  --coral: #E8836B;
  --green: #27ae60;
  --amber: #f39c12;
  --glass-bg: rgba(255, 255, 255, 0.07);
  --glass-border: rgba(255, 255, 255, 0.12);
  --glass-hover: rgba(255, 255, 255, 0.12);
  --text: #e8edf2;
  --text-muted: rgba(220, 230, 240, 0.5);
  --radius: 16px;
  --radius-sm: 10px;
  --font: 'Georgia', serif;
  --font-ui: system-ui, -apple-system, sans-serif;
  --sidebar-w: 220px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  background: #0b1622;
  color: var(--text);
  font-family: var(--font-ui);
  min-height: 100vh;
  padding: 0;
  position: relative;
  overflow-x: hidden;
  display: flex;
}

/* ── Sidebar ───────────────────────────────────────────────────────────────── */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: var(--sidebar-w);
  height: 100vh;
  background: rgba(8, 14, 24, 0.92);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-right: 1px solid var(--glass-border);
  display: flex;
  flex-direction: column;
  z-index: 100;
  padding: 1.25rem 0;
  overflow-y: auto;
  transition: transform 0.25s ease;
}
.sidebar-header { padding: 0 1.25rem 1.25rem; border-bottom: 1px solid var(--glass-border); margin-bottom: 0.75rem; }
.sidebar-logo { display: block; text-decoration: none; }
.sidebar-logo img { height: 24px; width: auto; filter: brightness(0) invert(1) opacity(0.88); transition: opacity 0.2s; }
.sidebar-logo:hover img { opacity: 1; }
.sidebar-nav { flex: 1; display: flex; flex-direction: column; gap: 0.15rem; padding: 0 0.75rem; }
.sidebar-link {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.6rem 0.75rem;
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-muted);
  text-decoration: none;
  transition: all 0.15s;
  white-space: nowrap;
}
.sidebar-link svg { width: 18px; height: 18px; opacity: 0.6; flex-shrink: 0; }
.sidebar-link:hover { color: var(--text); background: rgba(255,255,255,0.06); }
.sidebar-link:hover svg { opacity: 0.9; }
.sidebar-link.active { color: #fff; background: rgba(42, 100, 120, 0.32); }
.sidebar-link.active svg { opacity: 1; color: var(--teal-light); }
.sidebar-sep { height: 1px; background: var(--glass-border); margin: 0.5rem 1.25rem; }
.sidebar-section-label { font-size: 0.62rem; text-transform: uppercase; letter-spacing: 0.12em; color: var(--text-muted); padding: 0.75rem 0.75rem 0.3rem; opacity: 0.6; }
.sidebar-bottom { padding: 0 0.75rem; margin-top: auto; padding-top: 0.5rem; border-top: 1px solid var(--glass-border); display: flex; flex-direction: column; gap: 0.15rem; }
.sidebar-user { padding: 0.5rem 0.75rem; margin-bottom: 0.25rem; }
.sidebar-user-name { display: block; font-size: 0.78rem; font-weight: 500; color: var(--text); }
.sidebar-user-role { display: block; font-size: 0.65rem; color: var(--text-muted); text-transform: capitalize; }
.sidebar-badge { background: var(--teal); color: #fff; font-size: 0.6rem; padding: 0.15rem 0.45rem; border-radius: 99px; font-weight: 700; min-width: 1.1rem; text-align: center; margin-left: auto; line-height: 1.2; flex-shrink: 0; }

.sidebar-toggle { display: none; }

/* Main content with sidebar offset */
.main-content {
  flex: 1;
  margin-left: var(--sidebar-w);
  min-height: 100vh;
  padding: 2rem 1.5rem 4rem;
  position: relative;
}

/* Background ambient blobs */
body::before {
  content: '';
  position: fixed;
  top: -15%;
  left: -10%;
  width: 55%;
  height: 55%;
  background: radial-gradient(ellipse, rgba(42, 100, 120, 0.22) 0%, transparent 65%);
  pointer-events: none;
  z-index: 0;
}
body::after {
  content: '';
  position: fixed;
  bottom: -20%;
  right: -5%;
  width: 45%;
  height: 55%;
  background: radial-gradient(ellipse, rgba(232, 131, 107, 0.1) 0%, transparent 65%);
  pointer-events: none;
  z-index: 0;
}

.container     { max-width: 760px;  margin: 0 auto; position: relative; z-index: 1; }
.container--wide { max-width: 1100px; margin: 0 auto; position: relative; z-index: 1; }

/* ── Glass card ─────────────────────────────────────────────────────────────── */
.glass-card {
  background: var(--glass-bg);
  backdrop-filter: blur(28px);
  -webkit-backdrop-filter: blur(28px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 2rem 2.25rem;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255,255,255,0.07);
}

/* ── Header ──────────────────────────────────────────────────────────────────  */
header { text-align: center; margin-bottom: 2rem; }
.site-logo {
  max-height: 36px;
  width: auto;
  display: block;
  margin: 0 auto 0.5rem;
  filter: brightness(0) invert(1) opacity(0.92);
}
.subtitle {
  color: var(--text-muted);
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* ── Field ────────────────────────────────────────────────────────────────── */
.field { margin-bottom: 1.75rem; }
.field-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 0.85rem;
}
.field-hint { font-size: 0.82rem; color: var(--text-muted); margin-bottom: 0.75rem; line-height: 1.5; }

/* ── Series grid ─────────────────────────────────────────────────────────── */
.series-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.55rem;
}

.series-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.55rem;
  padding: 1rem 0.5rem 0.85rem;
  background: rgba(255, 255, 255, 0.055);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  font-size: 0.7rem;
  font-weight: 500;
  text-align: center;
  cursor: pointer;
  transition: all 0.18s ease;
  line-height: 1.35;
  letter-spacing: 0.01em;
}
.series-btn-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: transform 0.18s;
}
.series-btn-icon svg { width: 24px; height: 24px; color: var(--teal-light); }
.series-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.22);
  color: var(--text);
}
.series-btn:hover .series-btn-icon { transform: scale(1.15); }

.series-btn.selected {
  background: rgba(42, 100, 120, 0.32);
  border-color: var(--teal-light);
  color: #fff;
  box-shadow: 0 0 18px rgba(74, 155, 181, 0.35), inset 0 1px 0 rgba(255,255,255,0.12);
}

/* ── Textarea ──────────────────────────────────────────────────────────────── */
textarea {
  width: 100%;
  padding: 0.9rem 1.1rem;
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-family: var(--font-ui);
  color: var(--text);
  resize: vertical;
  line-height: 1.65;
  transition: border-color 0.2s, background 0.2s;
}
textarea::placeholder { color: var(--text-muted); }
textarea:focus { outline: none; border-color: var(--teal-light); background: rgba(0, 0, 0, 0.35); }

/* ── Buttons ─────────────────────────────────────────────────────────────── */
button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.7rem 1.4rem;
  background: var(--glass-bg);
  color: var(--text);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  white-space: nowrap;
}
button:hover {
  background: var(--glass-hover);
  border-color: rgba(255, 255, 255, 0.24);
  color: #fff;
}
button:disabled { opacity: 0.45; cursor: not-allowed; transform: none !important; }

.btn-primary {
  background: linear-gradient(135deg, var(--teal) 0%, var(--teal-light) 100%);
  border: none;
  color: #fff;
  font-weight: 600;
  box-shadow: 0 4px 20px rgba(42, 100, 120, 0.45);
}
.btn-primary:hover {
  box-shadow: 0 6px 28px rgba(74, 155, 181, 0.6);
  transform: translateY(-1px);
  background: linear-gradient(135deg, var(--teal) 0%, var(--teal-light) 100%);
  color: #fff;
}

.btn-submit {
  width: 100%;
  padding: 0.95rem 2rem;
  font-size: 0.95rem;
  margin-top: 0.25rem;
}

.btn-secondary {
  background: transparent;
  border-color: var(--glass-border);
}

.button-row { display: flex; gap: 0.65rem; flex-wrap: wrap; margin-top: 1.25rem; }

/* ── Step info ────────────────────────────────────────────────────────────── */
.step-info {
  background: rgba(42, 100, 120, 0.14);
  border-left: 3px solid var(--teal-light);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 0.85rem 1.1rem;
  margin-bottom: 1.5rem;
  font-size: 0.87rem;
  line-height: 1.65;
  color: var(--text);
}
.step-info .field-hint { margin-bottom: 0; }

/* ── Error ────────────────────────────────────────────────────────────────── */
.error {
  background: rgba(232, 131, 107, 0.13);
  border: 1px solid rgba(232, 131, 107, 0.4);
  color: #f5a48f;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-sm);
  margin-bottom: 1rem;
  font-size: 0.87rem;
}

.hidden { display: none !important; }

/* ── Spinner ─────────────────────────────────────────────────────────────── */
.spinner {
  width: 15px;
  height: 15px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  display: inline-block;
  flex-shrink: 0;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Input tabs ──────────────────────────────────────────────────────────── */
.input-tabs { display: flex; gap: 0.3rem; margin-bottom: 0.75rem; }
.input-tab {
  background: transparent;
  color: var(--text-muted);
  border: 1px solid var(--glass-border);
  border-bottom: none;
  border-radius: 7px 7px 0 0;
  padding: 0.45rem 1.1rem;
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
  backdrop-filter: none;
}
.input-tab:hover { background: rgba(255,255,255,0.07); color: var(--text); border-color: rgba(255,255,255,0.2); }
.input-tab.active { background: rgba(0,0,0,0.28); color: #fff; border-color: var(--glass-border); font-weight: 600; }

/* ── File drop ───────────────────────────────────────────────────────────── */
.file-drop {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 130px;
  border: 2px dashed rgba(255, 255, 255, 0.18);
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, 0.22);
  cursor: pointer;
  transition: all 0.2s;
  padding: 1.5rem;
  text-align: center;
}
.file-drop:hover, .file-drop.drag-over {
  border-color: var(--teal-light);
  background: rgba(42, 100, 120, 0.14);
}
.file-drop input[type="file"] { display: none; }
.file-drop span { color: var(--text-muted); font-size: 0.87rem; }

.file-status { margin-top: 0.55rem; font-size: 0.82rem; color: var(--teal-light); font-weight: 500; }
.file-status.error { color: #f5a48f; }

/* ── Image preview ───────────────────────────────────────────────────────── */
.image-preview {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 1.5rem;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.4);
}
.image-preview img { width: 100%; height: auto; display: block; }

/* ── Variants grid ───────────────────────────────────────────────────────── */
.variants-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1rem; margin-bottom: 1.5rem; }
.variant-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
}
.variant-card img { width: 100%; height: auto; display: block; }
.variant-card-footer {
  padding: 0.75rem 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.83rem;
  color: var(--text-muted);
}
.variant-card-footer button { padding: 0.4rem 1rem; font-size: 0.82rem; }

/* ── History ─────────────────────────────────────────────────────────────── */
.history { margin-top: 3rem; border-top: 1px solid var(--glass-border); padding-top: 1.5rem; }
.history h2 { font-size: 0.75rem; color: var(--text-muted); margin-bottom: 1rem; text-transform: uppercase; letter-spacing: 0.1em; }
.history-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 0.75rem; }
.history-item img { width: 100%; height: auto; border-radius: 6px; border: 1px solid var(--glass-border); }

/* ── Link button ─────────────────────────────────────────────────────────── */
.btn-link {
  text-decoration: none;
  padding: 0.7rem 1.4rem;
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text);
  border: 1px solid var(--glass-border);
  background: var(--glass-bg);
  display: inline-flex;
  align-items: center;
  transition: all 0.2s;
}
.btn-link:hover { background: var(--glass-hover); border-color: rgba(255,255,255,0.24); color: #fff; }

/* ── Toast notifications ────────────────────────────────────────────────── */
.toast-container {
  position: fixed;
  top: 1.25rem;
  right: 1.25rem;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  pointer-events: none;
}
.toast {
  pointer-events: all;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.7rem 1.1rem;
  border-radius: 10px;
  font-size: 0.82rem;
  font-weight: 500;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 6px 24px rgba(0,0,0,0.35);
  animation: toast-in 0.25s ease-out;
  max-width: 380px;
  line-height: 1.4;
}
.toast.removing { animation: toast-out 0.2s ease-in forwards; }
.toast svg { width: 16px; height: 16px; flex-shrink: 0; }
.toast-success { background: rgba(39,174,96,0.18); border: 1px solid rgba(39,174,96,0.4); color: #6ddb99; }
.toast-error   { background: rgba(232,131,107,0.18); border: 1px solid rgba(232,131,107,0.4); color: #f5a48f; }
.toast-warning { background: rgba(243,156,18,0.18); border: 1px solid rgba(243,156,18,0.4); color: #f5c96d; }
.toast-info    { background: rgba(74,155,181,0.18); border: 1px solid rgba(74,155,181,0.4); color: var(--teal-light); }
@keyframes toast-in { from { opacity: 0; transform: translateX(30px); } to { opacity: 1; transform: translateX(0); } }
@keyframes toast-out { from { opacity: 1; transform: translateX(0); } to { opacity: 0; transform: translateX(30px); } }

/* ── Library ────────────────────────────────────────────────────────────── */
.filter-toggle-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-bottom: 0.75rem;
  padding: 0.5rem 1rem;
  font-size: 0.82rem;
  min-height: 44px;
}
.library-toolbar { margin-bottom: 1.25rem; padding: 1.25rem 1.5rem; }
.filter-row { display: flex; gap: 1rem; align-items: flex-end; flex-wrap: wrap; }
.filter-group { display: flex; flex-direction: column; gap: 0.3rem; }
.filter-label { font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); font-weight: 600; }
.filter-select, .filter-input {
  padding: 0.5rem 0.75rem;
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid var(--glass-border);
  border-radius: 7px;
  color: var(--text);
  font-size: 0.82rem;
  font-family: var(--font-ui);
}
.filter-select:focus, .filter-input:focus { outline: none; border-color: var(--teal-light); }
.filter-select option { background: #1a2333; }

/* Series filter chips */
.filter-series-icons { display: flex; gap: 0.3rem; flex-wrap: wrap; }
.series-chip {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  padding: 0;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.15s;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.series-chip--label { width: auto; height: auto; padding: 0.3rem 0.6rem; font-size: 0.7rem; display: inline-flex; align-items: center; gap: 0.3rem; color: var(--text-muted); white-space: nowrap; }
.series-chip--label .series-icon-wrap { flex-shrink: 0; color: var(--teal-light); }
.series-chip:hover { background: rgba(255,255,255,0.1); border-color: rgba(255,255,255,0.2); }
.series-chip.active {
  background: rgba(42,100,120,0.3);
  border-color: var(--teal-light);
  color: #fff;
  box-shadow: 0 0 10px rgba(74,155,181,0.3);
}

.bulk-toolbar { display: flex; justify-content: space-between; align-items: center; margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--glass-border); }
.bulk-info { display: flex; align-items: center; gap: 0.75rem; }
.selected-count { font-size: 0.82rem; color: var(--teal-light); font-weight: 600; }
.bulk-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }

.export-options { margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--glass-border); }

.btn-sm { padding: 0.45rem 0.9rem; font-size: 0.78rem; }
.btn-danger { background: rgba(220, 80, 60, 0.22); border: 1px solid rgba(220, 80, 60, 0.4); color: #f5a48f; }
.btn-danger:hover { background: rgba(220, 80, 60, 0.35); border-color: rgba(220, 80, 60, 0.6); color: #fff; }

.library-status { font-size: 0.78rem; color: var(--text-muted); margin-bottom: 1rem; }

/* ── Stats bar ──────────────────────────────────────────────────────────── */
.stats-bar { margin-bottom: 1rem; padding: 1rem 1.5rem; }
.stats-summary { display: flex; justify-content: space-between; align-items: center; }
.stats-total { font-size: 0.88rem; font-weight: 600; color: var(--text); }
.stats-detail { margin-top: 1rem; }
.stats-series { display: flex; flex-direction: column; gap: 0.4rem; }
.stats-row { display: flex; align-items: center; gap: 0.75rem; font-size: 0.78rem; }
.stats-label { width: 140px; color: var(--text-muted); text-align: right; flex-shrink: 0; }
.stats-bar-track { flex: 1; height: 16px; background: rgba(255,255,255,0.06); border-radius: 4px; overflow: hidden; }
.stats-bar-fill { height: 100%; background: linear-gradient(90deg, var(--teal) 0%, var(--teal-light) 100%); border-radius: 4px; transition: width 0.3s; }
.stats-count { width: 30px; color: var(--text-muted); font-weight: 600; }

/* ── Error banner ──────────────────────────────────────────────────────── */
.error-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  background: rgba(232, 131, 107, 0.13);
  border: 1px solid rgba(232, 131, 107, 0.4);
  color: #f5a48f;
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-sm);
  margin-bottom: 1rem;
  font-size: 0.87rem;
}

/* ── Skeleton loader ───────────────────────────────────────────────────── */
.skeleton-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  overflow: hidden;
}
.skeleton-img {
  aspect-ratio: 16/9;
  background: linear-gradient(90deg, rgba(255,255,255,0.04) 25%, rgba(255,255,255,0.08) 50%, rgba(255,255,255,0.04) 75%);
  background-size: 200% 100%;
  animation: skeleton-pulse 1.5s ease-in-out infinite;
}
.skeleton-footer {
  padding: 0.55rem 0.75rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.skeleton-badge {
  width: 70px;
  height: 14px;
  background: rgba(255,255,255,0.06);
  border-radius: 99px;
  animation: skeleton-pulse 1.5s ease-in-out infinite 0.2s;
}
.skeleton-date {
  width: 50px;
  height: 12px;
  background: rgba(255,255,255,0.04);
  border-radius: 4px;
  animation: skeleton-pulse 1.5s ease-in-out infinite 0.4s;
}
@keyframes skeleton-pulse {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 1; }
}

/* ── Empty state ────────────────────────────────────────────────────────── */
.empty-state { text-align: center; padding: 4rem 2rem; color: var(--text-muted); }
.empty-icon-lg { width: 100px; height: 68px; margin-bottom: 1.5rem; opacity: 0.25; }
.empty-title { font-size: 1.05rem; margin-bottom: 0.5rem; color: var(--text); }
.empty-subtitle { font-size: 0.87rem; margin-bottom: 1.5rem; color: var(--text-muted); }
.empty-state .btn-primary { display: inline-flex; }
.empty-state .btn-link { font-size: 0.87rem; }

/* ── Assets grid ────────────────────────────────────────────────────────── */
.assets-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.asset-card {
  position: relative;
  animation: fadeIn 0.3s ease-out both;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  transition: all 0.2s;
}
.asset-card:hover { border-color: rgba(255,255,255,0.24); box-shadow: 0 4px 20px rgba(0,0,0,0.3); }
.asset-card.selected { border-color: var(--teal-light); box-shadow: 0 0 0 2px rgba(74,155,181,0.4); }
.asset-card img { width: 100%; aspect-ratio: 16/9; object-fit: cover; display: block; }
.asset-card-checkbox { position: absolute; top: 0.5rem; left: 0.5rem; z-index: 2; }
.asset-card-checkbox input[type="checkbox"] { width: 18px; height: 18px; cursor: pointer; accent-color: var(--teal-light); }
.asset-card-footer { padding: 0.55rem 0.75rem; font-size: 0.72rem; color: var(--text-muted); }
.asset-card-footer-top { display: flex; justify-content: space-between; align-items: center; }
.asset-title {
  font-size: 0.68rem;
  color: var(--text-muted);
  margin-top: 0.3rem;
  line-height: 1.35;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  opacity: 0.75;
}
.asset-series-badge { background: rgba(42,100,120,0.25); color: var(--teal-light); padding: 0.15rem 0.5rem; border-radius: 99px; font-size: 0.68rem; font-weight: 600; }
.asset-date { opacity: 0.7; }

/* ── Lightbox ───────────────────────────────────────────────────────────── */
.lightbox { position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: 1000; display: flex; align-items: center; justify-content: center; }
.lightbox-backdrop { position: absolute; inset: 0; background: rgba(0,0,0,0.85); backdrop-filter: blur(8px); }
.lightbox-content { position: relative; max-width: 90vw; max-height: 90vh; display: flex; flex-direction: column; }
.lightbox-content img { max-width: 100%; max-height: 70vh; border-radius: var(--radius); object-fit: contain; }
.lightbox-close { position: absolute; top: -2rem; right: -0.5rem; background: none; border: none; color: #fff; font-size: 2rem; cursor: pointer; padding: 0; line-height: 1; backdrop-filter: none; -webkit-backdrop-filter: none; }
.lightbox-close:hover { color: var(--coral); background: none; border: none; }
.lightbox-nav { position: absolute; top: 50%; transform: translateY(-50%); width: calc(100% + 5rem); left: -2.5rem; display: flex; justify-content: space-between; pointer-events: none; z-index: 2; }
.lightbox-nav-btn { pointer-events: all; background: rgba(0,0,0,0.5); border: none; color: #fff; font-size: 2.5rem; padding: 0.5rem 0.8rem; cursor: pointer; border-radius: 50%; backdrop-filter: none; -webkit-backdrop-filter: none; line-height: 1; }
.lightbox-nav-btn:hover { background: rgba(42,100,120,0.6); border: none; }
.lightbox-footer { margin-top: 0.75rem; padding: 0 0.25rem; }
.lightbox-meta-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 0.5rem; }
.lightbox-meta { color: var(--text-muted); font-size: 0.8rem; }
.lightbox-counter { color: var(--text-muted); font-size: 0.75rem; }
.lightbox-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; align-items: center; }
.lightbox-export-group { display: flex; gap: 0.3rem; align-items: center; }
.lightbox-export-group .filter-select { padding: 0.35rem 0.5rem; font-size: 0.75rem; }

/* ── Dashboard ──────────────────────────────────────────────────────────── */
.dash-page-title { font-size: 1.4rem; font-weight: 600; margin-bottom: 1.5rem; }
.dash-stats-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 0.75rem; margin-bottom: 1.5rem; }
.dash-stat-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 1.1rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}
.dash-stat-link { text-decoration: none; cursor: pointer; transition: border-color 0.2s, transform 0.15s; }
.dash-stat-link:hover { border-color: var(--accent-primary); transform: translateY(-2px); }
.dash-stat-value { font-size: 1.6rem; font-weight: 700; color: var(--teal-light); }
.dash-stat-label { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); }
.dash-section { margin-bottom: 1.75rem; }
.dash-section-title { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-muted); margin-bottom: 0.75rem; font-weight: 600; }
.dash-quick-actions { display: flex; gap: 0.6rem; flex-wrap: wrap; }
.dash-quick-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.2rem;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  color: var(--text);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 500;
  transition: all 0.15s;
}
.dash-quick-btn:hover { background: rgba(42,100,120,0.2); border-color: var(--teal-light); color: #fff; }
.dash-quick-btn svg { width: 18px; height: 18px; color: var(--teal-light); }

.dash-recent-list { display: flex; flex-direction: column; gap: 0.4rem; }
.dash-recent-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.6rem 0.85rem;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 8px;
  transition: all 0.15s;
  text-decoration: none;
  color: var(--text);
}
.dash-recent-item:hover { background: rgba(255,255,255,0.06); border-color: rgba(255,255,255,0.12); }
.dash-recent-title { font-size: 0.82rem; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dash-recent-meta { font-size: 0.7rem; color: var(--text-muted); white-space: nowrap; }
.dash-recent-badge { font-size: 0.65rem; padding: 0.12rem 0.5rem; border-radius: 99px; font-weight: 600; white-space: nowrap; }
.status-draft { background: rgba(255,255,255,0.08); color: var(--text-muted); }
.status-in_review { background: rgba(243,156,18,0.2); color: #f5c96d; }
.status-ready { background: rgba(74,155,181,0.2); color: var(--teal-light); }
.status-published { background: rgba(39,174,96,0.2); color: #6ddb99; }
.status-archived { background: rgba(255,255,255,0.05); color: rgba(220,230,240,0.35); }
.status-done { background: rgba(39,174,96,0.2); color: #6ddb99; }
.status-error { background: rgba(231,76,60,0.2); color: #e74c3c; }
.status-pending { background: rgba(255,255,255,0.08); color: var(--text-muted); }
.status-progress { background: rgba(243,156,18,0.2); color: #f5c96d; }

/* ── Content Library ───────────────────────────────────────────────────── */
.content-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.25rem; flex-wrap: wrap; gap: 0.75rem; }
.content-header-left { display: flex; align-items: center; gap: 1rem; }
.content-header h2 { font-size: 1.2rem; font-weight: 600; }
.content-header-count { font-size: 0.82rem; color: var(--text-muted); }
.content-filters { display: flex; gap: 0.5rem; flex-wrap: wrap; margin-bottom: 1rem; align-items: center; }
.content-search {
  flex: 1;
  min-width: 200px;
  padding: 0.55rem 0.85rem 0.55rem 2.2rem;
  background: rgba(0,0,0,0.28) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='rgba(220,230,240,0.4)' stroke-width='1.6' stroke-linecap='round'%3E%3Ccircle cx='7' cy='7' r='5'/%3E%3Cline x1='11' y1='11' x2='15' y2='15'/%3E%3C/svg%3E") no-repeat 0.7rem center;
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  color: var(--text);
  font-size: 0.82rem;
  font-family: var(--font-ui);
}
.content-search:focus { outline: none; border-color: var(--teal-light); }
.content-search::placeholder { color: var(--text-muted); }
.content-filter-chip {
  padding: 0.4rem 0.75rem;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--glass-border);
  border-radius: 7px;
  color: var(--text-muted);
  font-size: 0.75rem;
  cursor: pointer;
  transition: all 0.15s;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}
.content-filter-chip:hover { background: rgba(255,255,255,0.1); color: var(--text); }
.content-filter-chip.active { background: rgba(42,100,120,0.3); border-color: var(--teal-light); color: #fff; }
.content-view-toggle { display: flex; gap: 0.2rem; margin-left: auto; }
.content-view-btn { padding: 0.4rem; background: transparent; border: 1px solid transparent; border-radius: 6px; color: var(--text-muted); cursor: pointer; }
.content-view-btn.active { background: rgba(255,255,255,0.08); border-color: var(--glass-border); color: var(--text); }
.content-view-btn svg { width: 18px; height: 18px; }

.content-table { width: 100%; border-collapse: collapse; }
.content-table th {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  font-weight: 600;
  padding: 0.6rem 0.75rem;
  text-align: left;
  border-bottom: 1px solid var(--glass-border);
}
.content-table td {
  padding: 0.65rem 0.75rem;
  font-size: 0.82rem;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  vertical-align: middle;
}
.content-table tr:hover td { background: rgba(255,255,255,0.03); }
.content-table .article-title-cell { max-width: 300px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.content-table .article-title-link { color: var(--text); text-decoration: none; }
.content-table .article-title-link:hover { color: var(--teal-light); }

.content-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 0.75rem; }
.content-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
  transition: all 0.15s;
  cursor: pointer;
}
.content-card:hover { border-color: rgba(255,255,255,0.22); }
.content-card-title { font-size: 0.88rem; font-weight: 600; margin-bottom: 0.4rem; line-height: 1.35; }
.content-card-meta { font-size: 0.72rem; color: var(--text-muted); margin-bottom: 0.5rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.content-card-footer { display: flex; justify-content: space-between; align-items: center; }
.content-card-series { display: flex; align-items: center; gap: 0.3rem; font-size: 0.7rem; color: var(--text-muted); }
.content-card-series svg { width: 14px; height: 14px; color: var(--teal-light); }
.content-card-date { font-size: 0.68rem; color: var(--text-muted); }

/* ── Auth pages (login, setup, invite) ─────────────────────────────────── */
.auth-page {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 1.5rem;
}

.auth-container {
  width: 100%;
  max-width: 400px;
  margin: 0 auto;
}

.auth-card {
  padding: 2.5rem 2.25rem;
}

.auth-logo {
  text-align: center;
  margin-bottom: 1.5rem;
}

.auth-logo img {
  max-width: 180px;
  height: auto;
  filter: brightness(0) invert(1) drop-shadow(0 1px 4px rgba(0,0,0,0.2));
}

.auth-title {
  text-align: center;
  font-family: var(--font);
  font-size: 1.35rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  color: var(--text);
}

.auth-subtitle {
  text-align: center;
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-top: -1rem;
  margin-bottom: 1.5rem;
}

/* ── Responsive ──────────────────────────────────────────────────────────── */

/* Tablet */
@media (max-width: 1024px) {
  .assets-grid { grid-template-columns: repeat(3, 1fr); }
  .filter-row { flex-wrap: wrap; }
  .bulk-toolbar { flex-wrap: wrap; gap: 0.75rem; }
}

/* Tablet */
@media (max-width: 960px) {
  .series-grid { grid-template-columns: repeat(3, 1fr); }
  .lm-format-grid { grid-template-columns: repeat(2, 1fr); }
  .dash-stats-row { grid-template-columns: repeat(2, 1fr); }
  .dashboard-grid { grid-template-columns: repeat(2, 1fr); }
  .wizard-panel { max-width: 90%; }
}

/* Mobile */
@media (max-width: 768px) {
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: translateX(0); }
  .sidebar-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 99; }
  .sidebar-overlay.visible { display: block; }
  .sidebar-toggle { display: flex; position: fixed; top: 0.75rem; left: 0.75rem; z-index: 101; background: var(--glass-bg); border: 1px solid var(--glass-border); color: var(--text); padding: 0.5rem; border-radius: 8px; cursor: pointer; backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
  .sidebar-toggle svg { width: 20px; height: 20px; }
  .main-content { margin-left: 0; padding: 3.5rem 1rem 4rem; }

  .glass-card { padding: 1.5rem 1.25rem; }
  .series-grid { grid-template-columns: repeat(2, 1fr); }
  .button-row { flex-direction: column; }
  .btn-submit, .button-row > button, .button-row > a { width: 100%; }
  .assets-grid { grid-template-columns: repeat(2, 1fr); }
  .filter-toggle-btn { display: inline-flex; }
  .filter-row.collapsed { display: none; }
  .bulk-toolbar { flex-direction: column; gap: 0.75rem; }
  .bulk-actions { flex-direction: column; width: 100%; }
  .bulk-actions .btn-sm { width: 100%; min-height: 44px; }
  .lightbox-content { max-width: 100vw; max-height: 100vh; }
  .lightbox-content img { max-height: 55vh; border-radius: 0; }
  .lightbox-footer { flex-direction: column; gap: 0.5rem; }
  .lightbox-actions { flex-direction: column; }
  .lightbox-nav { width: calc(100% + 2rem); left: -1rem; }
  .lightbox-nav-btn { min-width: 44px; min-height: 44px; }
  .lightbox-close { min-width: 44px; min-height: 44px; font-size: 1.5rem; display: flex; align-items: center; justify-content: center; }
  .stats-label { width: 100px; font-size: 0.7rem; }
  .asset-card-checkbox input[type="checkbox"] { width: 22px; height: 22px; min-width: 44px; min-height: 44px; padding: 11px; }
  .content-grid { grid-template-columns: 1fr; }
  .dash-stats-row { grid-template-columns: repeat(2, 1fr); }
}

/* ─── Article Wizard ──────────────────────────────────────────────────────── */

.wizard-progress { display: flex; justify-content: center; gap: 0.5rem; margin: 1.5rem 0; }
.wizard-step { display: flex; align-items: center; gap: 0.3rem; padding: 0.4rem 0.8rem; border-radius: 20px; background: rgba(255,255,255,0.05); color: var(--text-muted); font-size: 0.8rem; transition: all 0.3s; }
.wizard-step.active { background: var(--accent-primary); color: #fff; }
.wizard-step.completed { background: rgba(42,100,120,0.3); color: var(--accent-primary); }
.step-num { width: 22px; height: 22px; border-radius: 50%; background: rgba(255,255,255,0.1); display: flex; align-items: center; justify-content: center; font-size: 0.75rem; font-weight: 600; }
.wizard-step.active .step-num { background: rgba(255,255,255,0.2); }
.step-label { display: none; }
@media (min-width: 600px) { .step-label { display: inline; } }

.wizard-panel { max-width: 720px; margin: 0 auto 2rem; }
.wizard-title { font-size: 1.3rem; margin-bottom: 0.3rem; }
.wizard-subtitle { color: var(--text-muted); font-size: 0.85rem; margin-bottom: 1.2rem; }

.series-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 0.8rem; }
.series-card { background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.08); border-radius: 12px; padding: 1.2rem 0.8rem; display: flex; flex-direction: column; align-items: center; gap: 0.5rem; cursor: pointer; transition: all 0.2s; }
.series-card:hover { background: rgba(42,100,120,0.15); border-color: var(--accent-primary); transform: translateY(-2px); }
.series-card-icon { display: flex; align-items: center; justify-content: center; }
.series-card-icon svg { width: 28px; height: 28px; color: var(--teal-light); }
.series-card-name { font-size: 0.8rem; color: var(--text-secondary); text-align: center; }

.wizard-tabs { display: flex; gap: 0.3rem; margin-bottom: 1rem; }
.wizard-tab { padding: 0.5rem 1rem; border-radius: 8px; background: rgba(255,255,255,0.05); border: 1px solid transparent; color: var(--text-muted); cursor: pointer; font-size: 0.85rem; transition: all 0.2s; }
.wizard-tab.active { background: var(--accent-primary); color: #fff; }

.topic-recommendations { margin-bottom: 1rem; }
.topic-chip { display: block; width: 100%; text-align: left; padding: 0.7rem 1rem; margin-bottom: 0.4rem; background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.08); border-radius: 8px; color: var(--text-primary); cursor: pointer; transition: all 0.2s; }
.topic-chip:hover { background: rgba(42,100,120,0.12); border-color: var(--accent-primary); }
.topic-chip strong { display: block; font-size: 0.9rem; margin-bottom: 0.2rem; }
.topic-chip-meta { font-size: 0.75rem; color: var(--text-muted); }

.form-group { margin-bottom: 1rem; }
.form-group label { display: block; font-size: 0.8rem; color: var(--text-secondary); margin-bottom: 0.3rem; }
.form-input, .form-select, .form-textarea { width: 100%; padding: 0.6rem 0.8rem; background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.1); border-radius: 8px; color: var(--text-primary); font-size: 0.9rem; }
.form-input:focus, .form-select:focus, .form-textarea:focus { border-color: var(--accent-primary); outline: none; }
.form-textarea { resize: vertical; font-family: inherit; }
.form-hint { font-size: 0.75rem; color: var(--text-muted); margin-top: 0.3rem; }
.loading-text { color: var(--text-muted); font-size: 0.85rem; }

.config-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: 1rem; }
@media (max-width: 600px) { .config-grid { grid-template-columns: 1fr; } }

.key-points-list { margin-bottom: 0.5rem; }
.key-point-item { display: flex; align-items: center; justify-content: space-between; padding: 0.4rem 0.6rem; background: rgba(255,255,255,0.04); border-radius: 6px; margin-bottom: 0.3rem; font-size: 0.85rem; }
.key-point-add { display: flex; gap: 0.4rem; }
.key-point-add .form-input { flex: 1; }

.wizard-nav { display: flex; justify-content: space-between; margin-top: 1.5rem; }

.generating-animation { text-align: center; padding: 3rem 0; }
.spinner-lg { width: 48px; height: 48px; border: 3px solid rgba(255,255,255,0.1); border-top-color: var(--accent-primary); border-radius: 50%; animation: spin 0.8s linear infinite; margin: 0 auto 1rem; }
@keyframes spin { to { transform: rotate(360deg); } }
.generating-text { color: var(--text-muted); font-size: 0.9rem; }

.result-meta { color: var(--text-muted); font-size: 0.85rem; margin-bottom: 1rem; font-style: italic; }
[contenteditable="true"]:hover { outline: 1px dashed rgba(42,100,120,0.4); outline-offset: 4px; }
[contenteditable="true"]:focus { outline: 1px solid var(--accent-primary); outline-offset: 4px; }
.result-article { background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.08); border-radius: 8px; padding: 1.5rem; margin-bottom: 1.5rem; line-height: 1.7; font-size: 0.9rem; max-height: 500px; overflow-y: auto; }
.result-article h1 { font-size: 1.3rem; margin-bottom: 0.8rem; color: var(--accent-primary); }
.result-article h2 { font-size: 1.1rem; margin: 1.2rem 0 0.5rem; color: var(--text-primary); }
.result-article h3 { font-size: 1rem; margin: 1rem 0 0.4rem; }
.result-article .checklist-item { padding: 0.3rem 0; color: var(--text-secondary); }
.result-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }

/* Tiptap Editor */
.editor-toolbar { display: flex; align-items: center; gap: 0.25rem; padding: 0.5rem; background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.1); border-radius: 8px 8px 0 0; flex-wrap: wrap; }
.editor-toolbar .toolbar-group { display: flex; gap: 2px; }
.editor-toolbar .toolbar-separator { width: 1px; height: 24px; background: rgba(255,255,255,0.12); margin: 0 0.25rem; }
.editor-toolbar button { background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.08); border-radius: 4px; color: var(--text-secondary); padding: 0.3rem 0.5rem; font-size: 0.78rem; cursor: pointer; transition: background 0.15s, color 0.15s; line-height: 1; }
.editor-toolbar button:hover { background: rgba(255,255,255,0.1); color: var(--text-primary); }
.editor-toolbar button.is-active { background: var(--accent-primary); color: #fff; border-color: var(--accent-primary); }

.editor-container { background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.1); border-top: none; border-radius: 0 0 8px 8px; margin-bottom: 1.5rem; min-height: 300px; max-height: 600px; overflow-y: auto; }
.editor-container .tiptap-content { padding: 1.5rem; outline: none; line-height: 1.7; font-size: 0.9rem; color: var(--text-primary); min-height: 280px; }
.editor-container .tiptap-content:focus { outline: none; }
.editor-container .tiptap-content h2 { font-size: 1.2rem; margin: 1.4rem 0 0.5rem; color: var(--text-primary); }
.editor-container .tiptap-content h3 { font-size: 1.05rem; margin: 1.1rem 0 0.4rem; }
.editor-container .tiptap-content h4 { font-size: 0.95rem; margin: 1rem 0 0.3rem; font-weight: 600; }
.editor-container .tiptap-content p { margin: 0.5rem 0; }
.editor-container .tiptap-content ul, .editor-container .tiptap-content ol { padding-left: 1.5rem; margin: 0.5rem 0; }
.editor-container .tiptap-content li { margin: 0.2rem 0; }
.editor-container .tiptap-content blockquote { border-left: 3px solid var(--accent-primary); margin: 1rem 0; padding: 0.5rem 1rem; color: var(--text-secondary); background: rgba(255,255,255,0.02); border-radius: 0 4px 4px 0; }
.editor-container .tiptap-content hr { border: none; border-top: 1px solid rgba(255,255,255,0.12); margin: 1.5rem 0; }
.editor-container .tiptap-content table { border-collapse: collapse; width: 100%; margin: 1rem 0; }
.editor-container .tiptap-content th, .editor-container .tiptap-content td { border: 1px solid rgba(255,255,255,0.15); padding: 0.5rem; text-align: left; }
.editor-container .tiptap-content th { background: rgba(255,255,255,0.06); font-weight: 600; }
.editor-container .tiptap-content strong { font-weight: 700; }
.editor-container .tiptap-content em { font-style: italic; }
.editor-container .tiptap-content s { text-decoration: line-through; color: var(--text-muted); }
.editor-container .tiptap-content .is-empty::before { content: attr(data-placeholder); color: var(--text-muted); pointer-events: none; height: 0; float: left; }

.cover-result { margin-top: 1.5rem; text-align: center; }
.cover-result img { max-width: 100%; border-radius: 8px; margin-top: 0.5rem; }

/* Dashboard */
.dashboard-section { max-width: 720px; margin: 0 auto 2rem; }
.dashboard-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 0.6rem; }
.dashboard-card { background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.08); border-radius: 10px; padding: 0.8rem; cursor: pointer; transition: all 0.2s; }
.dashboard-card:hover { border-color: var(--accent-primary); transform: translateY(-1px); }
.dashboard-card.rec-high { border-left: 3px solid #e74c3c; }
.dashboard-card.rec-medium { border-left: 3px solid #f39c12; }
.dashboard-card.rec-low { border-left: 3px solid #27ae60; }
.dash-series-name { font-size: 0.8rem; font-weight: 600; margin-bottom: 0.3rem; }
.dash-count { font-size: 0.75rem; color: var(--text-muted); }
.dash-bar { height: 4px; background: rgba(255,255,255,0.08); border-radius: 2px; margin: 0.4rem 0; overflow: hidden; }
.dash-bar-fill { height: 100%; background: var(--accent-primary); border-radius: 2px; transition: width 0.5s; }
.dash-rec { font-size: 0.7rem; color: var(--text-muted); }

/* Strategy editor */
.strategy-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; flex-wrap: wrap; gap: 0.5rem; }
.strategy-tabs { display: flex; gap: 0.3rem; }
.strategy-tab { padding: 0.35rem 0.8rem; background: rgba(255,255,255,0.05); border: 1px solid var(--glass-border); border-radius: 6px; color: var(--text-muted); font-size: 0.75rem; cursor: pointer; transition: all 0.15s; }
.strategy-tab:hover { background: rgba(255,255,255,0.1); color: var(--text); }
.strategy-tab.active { background: rgba(42,100,120,0.3); border-color: var(--teal-light); color: #fff; }

.strategy-series-filter { display: flex; gap: 0.4rem; flex-wrap: wrap; margin-bottom: 1rem; }
.strategy-series-btn { padding: 0.3rem 0.7rem; background: rgba(255,255,255,0.05); border: 1px solid var(--glass-border); border-radius: 6px; color: var(--text-muted); font-size: 0.72rem; cursor: pointer; transition: all 0.15s; }
.strategy-series-btn:hover { background: rgba(255,255,255,0.1); }
.strategy-series-btn.active { background: rgba(42,100,120,0.3); border-color: var(--teal-light); color: #fff; }

.strategy-topic-list { display: flex; flex-direction: column; gap: 0.5rem; }
.strategy-series-group { margin-bottom: 1.2rem; }
.strategy-series-group-title { font-size: 0.85rem; font-weight: 600; margin-bottom: 0.5rem; display: flex; align-items: center; gap: 0.5rem; }
.strategy-series-group-title .series-icon { font-size: 1.1rem; }
.strategy-series-group-count { font-size: 0.7rem; color: var(--text-muted); font-weight: 400; }

.strategy-topic-item { display: flex; align-items: center; gap: 0.6rem; padding: 0.5rem 0.7rem; background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.06); border-radius: 8px; transition: all 0.15s; }
.strategy-topic-item:hover { background: rgba(255,255,255,0.06); border-color: rgba(255,255,255,0.12); }
.strategy-topic-item.covered { opacity: 0.5; }
.strategy-topic-item.covered .topic-status { color: #27ae60; }
.strategy-topic-item:not(.covered) .topic-status { color: var(--text-muted); }
.topic-status { font-size: 0.85rem; flex-shrink: 0; width: 1.2rem; text-align: center; }
.topic-text { font-size: 0.78rem; flex: 1; }
.topic-action { padding: 0.2rem 0.5rem; background: rgba(42,100,120,0.2); border: 1px solid var(--teal-light); border-radius: 5px; color: var(--teal-light); font-size: 0.65rem; cursor: pointer; transition: all 0.15s; white-space: nowrap; }
.topic-action:hover { background: rgba(42,100,120,0.4); }
.topic-action.covered-btn { background: transparent; border-color: rgba(255,255,255,0.1); color: var(--text-muted); }
.strategy-rec-item { border-color: rgba(42,100,120,0.2); background: rgba(42,100,120,0.06); }
.strategy-rec-item:hover { border-color: var(--accent-primary); background: rgba(42,100,120,0.12); }

.strategy-existing { margin-top: 0.5rem; padding: 0.4rem 0.6rem; background: rgba(39,174,96,0.08); border-radius: 6px; }
.strategy-existing-title { font-size: 0.7rem; color: #27ae60; margin-bottom: 0.3rem; font-weight: 600; }
.strategy-existing-item { font-size: 0.68rem; color: var(--text-muted); padding: 0.15rem 0; }

/* ─── Strategy Overview ─────────────────────────────────────────────────── */
.strategy-overview { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 0.75rem; margin-bottom: 1.5rem; }
.strategy-overview-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
}
.strategy-overview-series { font-size: 0.82rem; font-weight: 600; margin-bottom: 0.4rem; display: flex; align-items: center; gap: 0.4rem; }
.strategy-overview-stats { font-size: 0.72rem; color: var(--text-muted); margin-bottom: 0.5rem; }
.strategy-progress { height: 6px; background: rgba(255,255,255,0.06); border-radius: 3px; overflow: hidden; }
.strategy-progress-fill { height: 100%; border-radius: 3px; transition: width 0.4s ease; }
.strategy-progress-fill.low { background: linear-gradient(90deg, #e74c3c, #e67e22); }
.strategy-progress-fill.mid { background: linear-gradient(90deg, #f39c12, #f1c40f); }
.strategy-progress-fill.high { background: linear-gradient(90deg, #27ae60, var(--teal-light)); }

/* ─── Kanban Board ──────────────────────────────────────────────────────── */
.kanban-board { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.75rem; margin-bottom: 1.5rem; min-height: 300px; }
.kanban-column {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: var(--radius);
  padding: 0.75rem;
  display: flex;
  flex-direction: column;
  min-height: 200px;
}
.kanban-column-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 0.6rem;
  margin-bottom: 0.5rem;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.kanban-column-title { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); font-weight: 600; }
.kanban-column-count { font-size: 0.68rem; color: var(--text-muted); background: rgba(255,255,255,0.06); padding: 0.1rem 0.4rem; border-radius: 99px; }
.kanban-cards { flex: 1; display: flex; flex-direction: column; gap: 0.4rem; min-height: 40px; }
.kanban-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  padding: 0.6rem 0.75rem;
  cursor: grab;
  transition: all 0.15s;
  font-size: 0.8rem;
  line-height: 1.4;
}
.kanban-card:hover { border-color: rgba(255,255,255,0.22); background: rgba(255,255,255,0.09); }
.kanban-card:active { cursor: grabbing; }
.kanban-card.sortable-ghost { opacity: 0.4; border-color: var(--teal-light); }
.kanban-card.sortable-chosen { box-shadow: 0 4px 16px rgba(0,0,0,0.4); }
.kanban-card-topic { font-size: 0.78rem; font-weight: 500; margin-bottom: 0.3rem; }
.kanban-card-meta { display: flex; justify-content: space-between; align-items: center; gap: 0.3rem; }
.kanban-card-series { font-size: 0.65rem; color: var(--teal-light); display: flex; align-items: center; gap: 0.2rem; }
.kanban-card-priority { font-size: 0.6rem; padding: 0.08rem 0.35rem; border-radius: 4px; font-weight: 600; }
.priority-high { background: rgba(231,76,60,0.2); color: #f5a48f; }
.priority-medium { background: rgba(243,156,18,0.2); color: #f5c96d; }
.priority-low { background: rgba(39,174,96,0.2); color: #6ddb99; }
.kanban-card-date { font-size: 0.62rem; color: var(--text-muted); }

/* ─── Strategy Table View ───────────────────────────────────────────────── */
.strategy-table { width: 100%; border-collapse: collapse; }
.strategy-table th {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  font-weight: 600;
  padding: 0.6rem 0.75rem;
  text-align: left;
  border-bottom: 1px solid var(--glass-border);
}
.strategy-table td {
  padding: 0.55rem 0.75rem;
  font-size: 0.8rem;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  vertical-align: middle;
}
.strategy-table tr:hover td { background: rgba(255,255,255,0.03); }
.strategy-table .status-badge {
  font-size: 0.65rem;
  padding: 0.12rem 0.5rem;
  border-radius: 99px;
  font-weight: 600;
}
.status-planned { background: rgba(255,255,255,0.08); color: var(--text-muted); }
.status-in_progress { background: rgba(74,155,181,0.2); color: var(--teal-light); }
.status-completed { background: rgba(39,174,96,0.2); color: #6ddb99; }
.status-cancelled { background: rgba(255,255,255,0.05); color: rgba(220,230,240,0.35); }

/* ─── Modal ─────────────────────────────────────────────────────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  animation: fadeIn 0.15s ease-out;
}
.modal-content {
  background: rgba(11,22,34,0.97);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 1.75rem 2rem;
  max-width: 520px;
  width: 90%;
  max-height: 85vh;
  overflow-y: auto;
  position: relative;
  box-shadow: 0 12px 48px rgba(0,0,0,0.5);
}
.modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.25rem; }
.modal-title { font-size: 1.1rem; font-weight: 600; }
.modal-close {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0;
  line-height: 1;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.modal-close:hover { color: var(--text); background: none; border: none; }
.modal-actions { display: flex; gap: 0.5rem; justify-content: flex-end; margin-top: 1.25rem; }

/* ─── Tabs (Settings) ───────────────────────────────────────────────────── */
.settings-tabs { display: flex; gap: 0.25rem; margin-bottom: 1.5rem; border-bottom: 1px solid var(--glass-border); padding-bottom: 0; }
.settings-tab {
  padding: 0.55rem 1rem;
  background: transparent;
  border: 1px solid transparent;
  border-bottom: 2px solid transparent;
  border-radius: 8px 8px 0 0;
  color: var(--text-muted);
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  margin-bottom: -1px;
}
.settings-tab:hover { color: var(--text); background: rgba(255,255,255,0.04); }
.settings-tab.active { color: #fff; border-bottom-color: var(--teal-light); background: rgba(42,100,120,0.12); }
.settings-panel { display: none; }
.settings-panel.active { display: block; }

/* ─── Settings: Series Grid ─────────────────────────────────────────────── */
.settings-series-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 0.75rem; }
.settings-series-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 1.1rem 1.25rem;
  transition: all 0.15s;
  cursor: pointer;
}
.settings-series-card:hover { border-color: rgba(255,255,255,0.22); }
.settings-series-card.inactive { opacity: 0.45; }
.settings-series-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 0.5rem; }
.settings-series-name { font-size: 0.88rem; font-weight: 600; display: flex; align-items: center; gap: 0.4rem; }
.settings-series-active { font-size: 0.65rem; padding: 0.08rem 0.4rem; border-radius: 4px; }
.settings-series-active.on { background: rgba(39,174,96,0.2); color: #6ddb99; }
.settings-series-active.off { background: rgba(232,131,107,0.2); color: #f5a48f; }
.settings-series-desc { font-size: 0.75rem; color: var(--text-muted); margin-bottom: 0.6rem; line-height: 1.4; }
.settings-series-palette { display: flex; gap: 0.25rem; margin-bottom: 0.4rem; }
.settings-series-swatch { width: 22px; height: 22px; border-radius: 5px; border: 1px solid rgba(255,255,255,0.15); }
.settings-series-target { font-size: 0.68rem; color: var(--text-muted); }

/* ─── Settings: History ─────────────────────────────────────────────────── */
.settings-history-list { display: flex; flex-direction: column; gap: 0.3rem; }
.settings-history-item {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  padding: 0.6rem 0.8rem;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.05);
  border-radius: 8px;
  font-size: 0.78rem;
}
.settings-history-date { font-size: 0.68rem; color: var(--text-muted); white-space: nowrap; min-width: 100px; }
.settings-history-detail { flex: 1; }
.settings-history-field { font-weight: 600; color: var(--teal-light); }
.settings-history-entity { font-size: 0.72rem; color: var(--text-muted); }

/* ─── Settings: Users ───────────────────────────────────────────────────── */
.users-list { display: flex; flex-direction: column; gap: 0.4rem; }
.user-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 0.85rem;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 8px;
}
.user-avatar { width: 32px; height: 32px; border-radius: 50%; background: rgba(42,100,120,0.3); display: flex; align-items: center; justify-content: center; font-size: 0.75rem; font-weight: 700; color: var(--teal-light); flex-shrink: 0; }
.user-info { flex: 1; }
.user-name { font-size: 0.85rem; font-weight: 500; }
.user-email { font-size: 0.72rem; color: var(--text-muted); }
.user-role-badge { font-size: 0.65rem; padding: 0.12rem 0.5rem; border-radius: 99px; font-weight: 600; }
.role-owner { background: rgba(243,156,18,0.2); color: #f5c96d; }
.role-editor { background: rgba(74,155,181,0.2); color: var(--teal-light); }
.role-viewer { background: rgba(255,255,255,0.08); color: var(--text-muted); }

/* ─── Settings: Guidelines ──────────────────────────────────────────────── */
.guidelines-section { margin-bottom: 1.5rem; }
.guidelines-title { font-size: 0.85rem; font-weight: 600; margin-bottom: 0.5rem; display: flex; align-items: center; gap: 0.4rem; }
.guidelines-content {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 8px;
  padding: 0.85rem 1rem;
  font-size: 0.78rem;
  line-height: 1.6;
  color: var(--text-muted);
  white-space: pre-wrap;
  font-family: var(--font-ui);
}

/* ─── Kanban + Strategy responsive ──────────────────────────────────────── */
@media (max-width: 1024px) {
  .kanban-board { grid-template-columns: repeat(2, 1fr); }
  .strategy-overview { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
  .kanban-board { grid-template-columns: 1fr; }
  .strategy-overview { grid-template-columns: 1fr; }
  .settings-tabs { overflow-x: auto; }
  .settings-series-grid { grid-template-columns: 1fr; }
  .modal-content { padding: 1.25rem; width: 95%; max-height: 80vh; overflow-y: auto; }
  .sidebar.open ~ .sidebar-toggle { display: none; }
}

/* ─── Lead Magnets ─────────────────────────────────────────────────────── */

.lm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 0.75rem; }
.lm-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
  transition: all 0.15s;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.lm-card:hover { border-color: rgba(255,255,255,0.22); transform: translateY(-1px); }
.lm-card-header { display: flex; justify-content: space-between; align-items: center; }
.lm-card-format { display: flex; align-items: center; gap: 0.35rem; font-size: 0.72rem; color: var(--teal-light); font-weight: 500; }
.lm-card-format svg { width: 16px; height: 16px; flex-shrink: 0; }
.lm-card-status { font-size: 0.65rem; padding: 0.1rem 0.45rem; border-radius: 99px; font-weight: 600; }
.lm-card-status.status-draft { background: rgba(255,255,255,0.08); color: var(--text-muted); }
.lm-card-status.status-generating { background: rgba(243,156,18,0.2); color: #f5c96d; }
.lm-card-status.status-review { background: rgba(74,155,181,0.2); color: var(--teal-light); }
.lm-card-status.status-ready { background: rgba(39,174,96,0.2); color: #6ddb99; }
.lm-card-status.status-published { background: rgba(42,100,120,0.3); color: var(--accent-primary); }
.lm-card-title { font-size: 0.9rem; font-weight: 600; line-height: 1.3; }
.lm-card-meta { font-size: 0.75rem; color: var(--text-muted); line-height: 1.4; }
.lm-card-footer { display: flex; justify-content: space-between; font-size: 0.7rem; color: var(--text-muted); margin-top: auto; padding-top: 0.4rem; border-top: 1px solid rgba(255,255,255,0.05); }
.lm-card-actions { display: flex; gap: 0.4rem; margin-top: 0.4rem; }
.lm-card-actions .btn-sm { padding: 0.3rem 0.7rem; font-size: 0.72rem; border-radius: 6px; background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.1); color: var(--text-secondary); cursor: pointer; transition: all 0.15s; }
.lm-card-actions .btn-sm:hover { background: rgba(255,255,255,0.12); color: var(--text-primary); }
.lm-card-actions .btn-danger { color: #f5a48f; }
.lm-card-actions .btn-danger:hover { background: rgba(231,76,60,0.2); border-color: rgba(231,76,60,0.3); }

/* Format selection grid (wizard step 4) */
.lm-format-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 0.8rem; }
.lm-format-card {
  background: rgba(255,255,255,0.05);
  border: 2px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  padding: 1.2rem 0.8rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: all 0.2s;
  text-align: center;
}
.lm-format-card:hover { background: rgba(42,100,120,0.15); border-color: var(--accent-primary); transform: translateY(-2px); }
.lm-format-card.selected { border-color: var(--teal-light); background: rgba(42,100,120,0.2); box-shadow: 0 0 0 1px var(--teal-light); }
.lm-format-icon { display: flex; align-items: center; justify-content: center; }
.lm-format-icon svg { width: 32px; height: 32px; color: var(--teal-light); }
.lm-format-card h4 { font-size: 0.82rem; color: var(--text-secondary); margin: 0; }
.lm-format-desc { font-size: 0.68rem; color: var(--text-muted); margin: 0.35rem 0 0; line-height: 1.4; }

/* Analysis result */
.lm-analysis-result { margin-bottom: 1rem; }
.lm-analysis-section { margin-bottom: 1rem; }
.lm-analysis-section h4 { font-size: 0.85rem; margin-bottom: 0.4rem; }
.tag-list { display: flex; flex-wrap: wrap; gap: 0.3rem; }
.tag { font-size: 0.72rem; padding: 0.2rem 0.55rem; background: rgba(42,100,120,0.2); border: 1px solid rgba(42,100,120,0.3); border-radius: 99px; color: var(--teal-light); }
.lm-rec-list { display: flex; flex-direction: column; gap: 0.4rem; }
.lm-rec-card {
  padding: 0.7rem 0.9rem;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s;
}
.lm-rec-card:hover { background: rgba(42,100,120,0.12); border-color: var(--accent-primary); }
.lm-rec-card strong { font-size: 0.85rem; display: block; margin-bottom: 0.2rem; }
.lm-rec-format { font-size: 0.68rem; color: var(--teal-light); font-weight: 500; }
.lm-rec-card p { font-size: 0.75rem; color: var(--text-muted); margin: 0.3rem 0 0; }

/* Topic list (wizard step 5) */
.lm-topic-list { display: flex; flex-direction: column; gap: 0.4rem; margin-bottom: 1rem; }
.lm-topic-card {
  padding: 0.7rem 0.9rem;
  background: rgba(255,255,255,0.04);
  border: 2px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s;
}
.lm-topic-card:hover { background: rgba(42,100,120,0.12); border-color: var(--accent-primary); }
.lm-topic-card.selected { border-color: var(--teal-light); background: rgba(42,100,120,0.15); }
.lm-topic-card h4 { font-size: 0.85rem; margin: 0 0 0.2rem; }
.lm-topic-card p { font-size: 0.75rem; color: var(--text-muted); margin: 0; }

/* Outline (wizard step 6) */
.lm-outline-list { display: flex; flex-direction: column; gap: 0.4rem; margin-bottom: 1rem; }
.lm-outline-item { display: flex; gap: 0.75rem; padding: 0.6rem 0.8rem; background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.06); border-radius: 8px; }
.lm-outline-num { width: 28px; height: 28px; border-radius: 50%; background: rgba(42,100,120,0.3); display: flex; align-items: center; justify-content: center; font-size: 0.75rem; font-weight: 700; color: var(--teal-light); flex-shrink: 0; }
.lm-outline-content { flex: 1; }
.lm-outline-content strong { font-size: 0.85rem; display: block; margin-bottom: 0.15rem; }
.lm-outline-content p { font-size: 0.75rem; color: var(--text-muted); margin: 0; }

/* Chapters nav (wizard step 7) */
.lm-chapters-nav { display: flex; flex-wrap: wrap; gap: 0.3rem; margin-bottom: 1rem; }
.lm-chapter-btn {
  padding: 0.4rem 0.75rem;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 6px;
  color: var(--text-muted);
  font-size: 0.75rem;
  cursor: pointer;
  transition: all 0.15s;
}
.lm-chapter-btn:hover { background: rgba(255,255,255,0.1); color: var(--text-primary); }
.lm-chapter-btn.active { background: rgba(42,100,120,0.3); border-color: var(--teal-light); color: #fff; }
.lm-chapter-btn.done { border-left: 3px solid #27ae60; }
.lm-chapter-btn.pending { border-left: 3px solid rgba(255,255,255,0.15); }
.lm-chapter-status { font-size: 0.62rem; color: var(--text-muted); margin-left: auto; font-weight: 400; }
.lm-chapter-btn.done .lm-chapter-status { color: #27ae60; }
.lm-chapter-editor { margin-bottom: 1rem; }
.lm-chapter-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 0.5rem; }
.lm-chapter-header h3 { font-size: 1rem; margin: 0; }

/* Preview (wizard step 8) */
.lm-preview { background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.08); border-radius: 8px; padding: 1.5rem; max-height: 600px; overflow-y: auto; }
.lm-preview-cover { text-align: center; padding: 2rem 1rem; border-bottom: 1px solid rgba(255,255,255,0.08); margin-bottom: 1.5rem; }
.lm-preview-cover h1 { font-size: 1.3rem; margin-bottom: 0.5rem; }
.lm-preview-cover p { font-size: 0.85rem; color: var(--text-muted); }
.lm-preview-toc { margin-bottom: 1.5rem; padding-bottom: 1rem; border-bottom: 1px solid rgba(255,255,255,0.06); }
.lm-preview-toc h2 { font-size: 1rem; margin-bottom: 0.5rem; }
.lm-preview-toc ol { padding-left: 1.5rem; font-size: 0.85rem; color: var(--text-secondary); }
.lm-preview-toc li { margin: 0.25rem 0; }
.lm-preview-chapter { margin-bottom: 1.5rem; line-height: 1.7; font-size: 0.9rem; }
.lm-preview-empty { padding: 1rem; background: rgba(255,255,255,0.02); border-radius: 6px; }

/* Goal presets */
.lm-goal-presets { display: flex; flex-wrap: wrap; gap: 0.3rem; margin-top: 0.5rem; }
.tag-btn { padding: 0.3rem 0.65rem; background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.1); border-radius: 99px; color: var(--text-secondary); font-size: 0.72rem; cursor: pointer; transition: all 0.15s; }
.tag-btn:hover { background: rgba(42,100,120,0.2); border-color: var(--teal-light); color: var(--teal-light); }
.tag-suggestions { margin-top: 0.5rem; }

/* Lead magnets responsive */
@media (max-width: 768px) {
  .lm-grid { grid-template-columns: 1fr; }
  .lm-format-grid { grid-template-columns: repeat(2, 1fr); }
}
