/* ============================================================
   SocialAI Manager — Dashboard page styles
   Layered on top of style.css (which already defines the app
   shell, kpi-card, section-card, tags, etc.)
   ============================================================ */

/* ---------- Mini KPI strip ---------- */
.mini-kpi {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
  display: flex; flex-direction: column; gap: .15rem;
  transition: transform var(--transition), box-shadow var(--transition);
  height: 100%;
}
.mini-kpi:hover { transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.mini-label { font-size: .78rem; color: var(--text-muted); font-weight: 500; }
.mini-value { font-family: 'Sora'; font-size: 1.4rem; font-weight: 800; }

/* ---------- Segmented control (chart metric switch) ---------- */
.seg-control {
  display: inline-flex;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  padding: .2rem;
}
.seg {
  border: none; background: none; cursor: pointer;
  padding: .35rem .85rem; border-radius: var(--radius-pill);
  font-size: .8rem; font-weight: 600; color: var(--text-muted);
  transition: all var(--transition);
}
.seg:hover { color: var(--text); }
.seg.active { background: var(--surface); color: var(--brand-600); box-shadow: var(--shadow-sm); }
[data-theme="dark"] .seg.active { background: var(--brand-700); color: #fff; }

/* ---------- Chart wrap ---------- */
.chart-wrap { position: relative; width: 100%; }

/* ---------- Platform legend ---------- */
.platform-legend { list-style: none; margin: 0; padding: 0; display: grid; gap: .65rem; }
.platform-legend li {
  display: flex; align-items: center; gap: .65rem;
  font-size: .9rem;
}
.platform-legend .swatch {
  width: 12px; height: 12px; border-radius: 4px; flex: none;
}
.platform-legend .pl-name { flex: 1; color: var(--text-soft); }
.platform-legend .pl-val { font-weight: 700; font-family: 'Sora'; }
.platform-legend .pl-bar {
  height: 6px; border-radius: 6px; background: var(--surface-2);
  overflow: hidden; margin-top: .2rem;
}
.platform-legend .pl-bar > span { display: block; height: 100%; border-radius: 6px; }

/* ---------- Best post rows ---------- */
.post-row {
  display: flex; align-items: center; gap: 1rem;
  padding: .9rem 0; border-bottom: 1px solid var(--border);
}
.post-row:last-child { border-bottom: none; }
.post-thumb {
  width: 52px; height: 52px; border-radius: 12px; flex: none;
  display: grid; place-items: center; color: #fff; font-size: 1.2rem;
}
.post-thumb.ig { background: linear-gradient(135deg,#f58529,#dd2a7b,#8134af); }
.post-thumb.fb { background: #1877f2; }
.post-thumb.li { background: #0a66c2; }
.post-thumb.yt { background: #ff0000; }
.post-thumb.x  { background: #000; }
.post-main { flex: 1; min-width: 0; }
.post-main h4 { margin: 0; font-size: .95rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.post-main small { color: var(--text-muted); font-size: .8rem; }
.post-stats { display: flex; gap: 1rem; font-size: .8rem; color: var(--text-muted); flex: none; }
.post-stats span { display: inline-flex; align-items: center; gap: .3rem; }
.post-stats i { color: var(--brand-500); }

/* ---------- Queue / timeline list ---------- */
.queue-item {
  display: flex; gap: .8rem; padding: .75rem 0;
  border-bottom: 1px dashed var(--border);
}
.queue-item:last-child { border-bottom: none; }
.queue-time {
  flex: none; width: 56px; text-align: center;
  font-family: 'Sora'; font-weight: 700; font-size: .85rem;
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: .5rem .25rem; line-height: 1.2;
}
.queue-time small { display: block; font-family: 'Inter'; font-weight: 500; font-size: .68rem; color: var(--text-muted); }
.queue-body { flex: 1; min-width: 0; }
.queue-body h4 { margin: 0 0 .15rem; font-size: .9rem; font-weight: 600; }
.queue-body .queue-meta { display: flex; gap: .4rem; flex-wrap: wrap; }

/* ---------- AI suggestion card ---------- */
.ai-card { background:
  linear-gradient(var(--surface), var(--surface)) padding-box,
  linear-gradient(135deg, rgba(99,102,241,.5), rgba(236,72,153,.5)) border-box;
  border: 1px solid transparent;
}
.ai-card .card-head h3 i { color: var(--accent-pink); }
.ai-sug {
  display: flex; gap: .75rem; padding: .8rem;
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  margin-bottom: .6rem;
}
.ai-sug:last-child { margin-bottom: 0; }
.ai-sug .ai-ic {
  flex: none; width: 34px; height: 34px; border-radius: 9px;
  display: grid; place-items: center; color: #fff; font-size: .9rem;
  background: var(--gradient-brand);
}
.ai-sug p { margin: 0; font-size: .85rem; color: var(--text-soft); line-height: 1.45; }
.ai-sug .ai-action { font-size: .78rem; color: var(--brand-600); font-weight: 600; margin-top: .35rem; display: inline-block; }

/* ---------- Notification list ---------- */
.notif-item {
  display: flex; gap: .75rem; padding: .7rem 0;
  border-bottom: 1px solid var(--border);
}
.notif-item:last-child { border-bottom: none; }
.notif-item.unread { font-weight: 500; }
.notif-item .dot-unread {
  flex: none; width: 8px; height: 8px; border-radius: 50%;
  background: var(--brand-500); margin-top: 7px; opacity: 0;
}
.notif-item.unread .dot-unread { opacity: 1; }
.notif-ic {
  flex: none; width: 36px; height: 36px; border-radius: 10px;
  display: grid; place-items: center; font-size: .9rem;
}
.notif-body { flex: 1; min-width: 0; }
.notif-body p { margin: 0; font-size: .85rem; color: var(--text-soft); line-height: 1.4; }
.notif-body small { color: var(--text-muted); font-size: .74rem; }

/* ---------- Team activity feed ---------- */
.activity-item { display: flex; gap: .75rem; padding: .65rem 0; }
.activity-item:not(:last-child) { border-bottom: 1px solid var(--border); }
.activity-av {
  flex: none; width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center; color: #fff; font-weight: 700; font-size: .78rem;
}
.activity-body { flex: 1; font-size: .84rem; color: var(--text-soft); line-height: 1.4; }
.activity-body strong { color: var(--text); }
.activity-body small { display: block; color: var(--text-muted); font-size: .72rem; margin-top: .1rem; }

/* ---------- Topbar notification dot ---------- */
.dot-badge {
  position: absolute; top: 8px; right: 9px;
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--accent-rose); border: 2px solid var(--surface);
}
.position-relative { position: relative; }

/* ---------- Responsive dashboard tweaks ---------- */
@media (max-width: 767.98px) {
  .post-stats { display: none; }
  .seg-control { width: 100%; justify-content: space-between; }
  .seg { flex: 1; }
}

/* ============================================================
   SCHEDULER PAGE COMPONENTS
   ============================================================ */

/* ---------- Platform picker (multi-select chips) ---------- */
.platform-picker { display: flex; flex-wrap: wrap; gap: .5rem; }
.pl-chip {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .5rem .85rem; border-radius: var(--radius-pill);
  border: 1px solid var(--border-strong); background: var(--surface-2);
  color: var(--text-soft); font-weight: 600; font-size: .85rem; cursor: pointer;
  transition: all var(--transition); user-select: none;
}
.pl-chip i { font-size: 1rem; }
.pl-chip:hover { border-color: var(--brand-500); transform: translateY(-1px); }
.pl-chip.selected {
  color: #fff; border-color: transparent;
  background: var(--gradient-brand);
  box-shadow: var(--shadow-sm);
}
.pl-chip.selected i { color: #fff; }
.pl-chip.ig-i  i { color: #dd2a7b; }
.pl-chip.fb-i  i { color: #1877f2; }
.pl-chip.li-i  i { color: #0a66c2; }
.pl-chip.yt-i  i { color: #ff0000; }
.pl-chip.x-i   i { color: #1f2430; }
.pl-chip.tk-i  i { color: #000; }
.pl-chip.pi-i  i { color: #e60023; }
[data-theme="dark"] .pl-chip.x-i i, [data-theme="dark"] .pl-chip.tk-i i { color: #fff; }
.pl-chip.selected.ig-i, .pl-chip.selected.fb-i, .pl-chip.selected.li-i,
.pl-chip.selected.yt-i, .pl-chip.selected.x-i, .pl-chip.selected.tk-i, .pl-chip.selected.pi-i { background: var(--gradient-brand); }
.pl-chip.selected i { color: #fff !important; }

/* ---------- Post-type picker ---------- */
.type-picker { display: flex; flex-wrap: wrap; gap: .45rem; }
.type-chip {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .4rem .7rem; border-radius: var(--radius-sm);
  border: 1px solid var(--border); background: var(--surface-2);
  color: var(--text-soft); font-size: .8rem; font-weight: 600; cursor: pointer;
  transition: all var(--transition);
}
.type-chip i { font-size: .85rem; color: var(--brand-500); }
.type-chip:hover { border-color: var(--brand-500); }
.type-chip.selected { background: var(--brand-50); color: var(--brand-700); border-color: var(--brand-500); }
[data-theme="dark"] .type-chip.selected { background: rgba(99,102,241,.16); color: var(--brand-300); }

/* ---------- Media dropzone ---------- */
.media-dropzone {
  border: 2px dashed var(--border-strong);
  border-radius: var(--radius);
  padding: 1.8rem 1rem; text-align: center; cursor: pointer;
  color: var(--text-muted); transition: all var(--transition);
  background: var(--surface-2);
}
.media-dropzone i { font-size: 1.8rem; margin-bottom: .5rem; color: var(--brand-500); }
.media-dropzone p { font-weight: 600; color: var(--text-soft); font-size: .9rem; }
.media-dropzone:hover, .media-dropzone.dragover {
  border-color: var(--brand-500); background: var(--brand-50); color: var(--brand-600);
}
[data-theme="dark"] .media-dropzone:hover, [data-theme="dark"] .media-dropzone.dragover { background: rgba(99,102,241,.1); }

/* ---------- Post list rows ---------- */
.post-card {
  display: flex; align-items: center; gap: 1rem;
  padding: 1rem; border-radius: var(--radius);
  border: 1px solid var(--border); background: var(--surface);
  margin-bottom: .75rem; transition: all var(--transition);
}
.post-card:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); border-color: var(--border-strong); }
.post-card .pc-thumb {
  width: 52px; height: 52px; border-radius: 12px; flex: none;
  display: grid; place-items: center; color: #fff; font-size: 1.2rem;
}
.post-card .pc-main { flex: 1; min-width: 0; }
.post-card .pc-main h4 { margin: 0 0 .2rem; font-size: .95rem; font-weight: 600; }
.post-card .pc-main .pc-meta { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; font-size: .78rem; color: var(--text-muted); }
.post-card .pc-actions { display: flex; gap: .25rem; flex: none; }
.post-card .pc-actions .btn-icon { width: 34px; height: 34px; font-size: .85rem; }

/* Grid view */
.posts-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1rem; }
.post-card.grid-card { flex-direction: column; align-items: stretch; text-align: center; padding: 1.2rem; }
.post-card.grid-card .pc-thumb { margin: 0 auto .75rem; width: 64px; height: 64px; }
.post-card.grid-card .pc-actions { justify-content: center; margin-top: .75rem; }

/* Platform thumbnail colors */
.pc-thumb.ig, .post-thumb.ig { background: linear-gradient(135deg,#f58529,#dd2a7b,#8134af); }
.pc-thumb.fb, .post-thumb.fb { background: #1877f2; }
.pc-thumb.li, .post-thumb.li { background: #0a66c2; }
.pc-thumb.yt, .post-thumb.yt { background: #ff0000; }
.pc-thumb.x  , .post-thumb.x  { background: #1f2430; }
.pc-thumb.tk { background: #000; }
.pc-thumb.pi { background: #e60023; }

@media (max-width: 575.98px) {
  .post-card { flex-wrap: wrap; }
  .post-card .pc-actions { width: 100%; justify-content: flex-end; }
  .post-card .pc-meta { font-size: .72rem; }
}

/* ============================================================
   CONTENT CALENDAR PAGE
   ============================================================ */

/* Legend checkboxes */
.legend-check {
  display: inline-flex; align-items: center; gap: .4rem;
  font-size: .82rem; color: var(--text-soft); cursor: pointer;
  padding: .3rem .55rem; border-radius: var(--radius-pill);
  border: 1px solid var(--border); background: var(--surface-2);
  transition: all var(--transition); user-select: none;
}
.legend-check:hover { border-color: var(--brand-500); }
.legend-check input { margin: 0; }
.legend-check.is-off { opacity: .4; text-decoration: line-through; }
.legend-dot { width: 10px; height: 10px; border-radius: 50%; flex: none; }

/* FullCalendar theming (works in both light & dark) */
.fc {
  --fc-border-color: var(--border);
  --fc-page-bg-color: var(--surface);
  --fc-neutral-bg-color: var(--surface-2);
  --fc-today-bg-color: rgba(99, 102, 241, .08);
  color: var(--text);
  font-family: 'Inter', sans-serif;
}
.fc .fc-toolbar.fc-header-toolbar { flex-wrap: wrap; gap: .75rem; margin-bottom: 1rem; }
.fc .fc-toolbar-title { font-family: 'Sora', sans-serif; font-size: 1.3rem; font-weight: 700; color: var(--text); }
.fc .fc-button {
  background: var(--surface-2); color: var(--text-soft);
  border: 1px solid var(--border); border-radius: var(--radius-sm) !important;
  padding: .4rem .7rem; box-shadow: none !important; text-transform: capitalize; font-weight: 600; font-size: .82rem;
  transition: all var(--transition);
}
.fc .fc-button:hover { background: var(--brand-50); color: var(--brand-600); border-color: var(--brand-500); }
[data-theme="dark"] .fc .fc-button:hover { background: rgba(99,102,241,.14); }
.fc .fc-button-primary:not(:disabled).fc-button-active,
.fc .fc-button-primary:not(:disabled):active {
  background: var(--gradient-brand); color: #fff; border-color: transparent;
}
.fc .fc-button:disabled { opacity: .5; }
.fc .fc-col-header-cell-cushion { color: var(--text-muted); font-weight: 600; font-size: .82rem; padding: .75rem 0; }
.fc-daygrid-day-number, .fc-col-header-cell-cushion { color: var(--text-soft); text-decoration: none; }
.fc .fc-daygrid-day.fc-day-today { background: var(--fc-today-bg-color); }
.fc .fc-daygrid-day.fc-day-today .fc-daygrid-day-number { color: var(--brand-600); font-weight: 700; }
.fc-event {
  border: none; border-radius: 6px; padding: 2px 6px;
  font-size: .76rem; font-weight: 600; cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition);
}
.fc-event:hover { transform: translateY(-1px); box-shadow: var(--shadow-sm); }
.fc .fc-timegrid-slot { height: 2.4em; }
.fc .fc-list-event-dot { border-color: transparent; }
.fc .fc-list-day-cushion, .fc .fc-list-day-text, .fc .fc-list-day-side-text { background: var(--surface-2); color: var(--text); }
.fc-theme-standard td, .fc-theme-standard th { border-color: var(--border); }
.fc .fc-scrollgrid, .fc .fc-scrollgrid-section > * { border-color: var(--border); }
.fc .fc-list-empty { background: var(--surface); color: var(--text-muted); }

/* Event colors are set inline; ensure readable text */
.fc-event { color: #fff; }
.fc-event.holiday-event { background: #6b7280 !important; opacity: .85; }
.fc-event.deadline-event { background: #10b981 !important; }

@media (max-width: 767.98px) {
  .fc .fc-toolbar.fc-header-toolbar { font-size: .9rem; }
  .fc .fc-toolbar-title { font-size: 1.1rem; }
}

/* ============================================================
   PLATFORM PAGES (Instagram, Facebook, LinkedIn, YouTube)
   ============================================================ */

/* Platform hero */
.platform-hero, .ig-hero { position: relative; overflow: hidden; }
.platform-hero-bg, .ig-hero-bg {
  position: absolute; inset: 0; opacity: .9;
  background: var(--platform-gradient, var(--gradient-soft));
}
.ig-hero-bg { background: linear-gradient(135deg, #f58529 0%, #dd2a7b 45%, #8134af 100%); opacity: .14; }
.platform-hero-body, .ig-hero-body { position: relative; display: flex; align-items: center; gap: 1.5rem; flex-wrap: wrap; padding-top: 1.5rem; padding-bottom: 1.5rem; }
.platform-avatar, .ig-avatar {
  width: 88px; height: 88px; border-radius: 26px; flex: none;
  display: grid; place-items: center; color: #fff; font-size: 2.4rem;
  background: var(--gradient-brand); position: relative;
  box-shadow: var(--shadow-md);
}
.ig-avatar { background: linear-gradient(135deg, #f58529, #dd2a7b, #8134af); }
.ig-connected {
  position: absolute; right: -4px; bottom: -4px;
  width: 26px; height: 26px; border-radius: 50%; background: var(--accent-emerald);
  color: #fff; display: grid; place-items: center; font-size: .7rem; border: 3px solid var(--surface);
}
.platform-id, .ig-id { flex: 1; min-width: 200px; }
.platform-id h1, .ig-id h1 { margin: 0 0 .15rem; font-size: 1.6rem; }
.platform-id p, .ig-id p { margin: 0; color: var(--text-muted); font-size: .92rem; }
.platform-stats, .ig-stats { display: flex; gap: 1.5rem; margin-top: .6rem; flex-wrap: wrap; }
.platform-stats span, .ig-stats span { font-size: .85rem; color: var(--text-muted); }
.platform-stats strong, .ig-stats strong { color: var(--text); font-family: 'Sora'; font-size: 1.05rem; display: block; }
.platform-hero-actions, .ig-hero-actions { display: flex; gap: .5rem; flex-wrap: wrap; }

/* Platform tabs */
.platform-tabs { display: flex; gap: .4rem; overflow-x: auto; padding-bottom: .25rem; }
.ptab {
  display: inline-flex; align-items: center; gap: .5rem; white-space: nowrap;
  padding: .55rem 1rem; border-radius: var(--radius-pill);
  background: var(--surface-2); border: 1px solid var(--border);
  color: var(--text-soft); font-weight: 600; font-size: .87rem; cursor: pointer;
  transition: all var(--transition);
}
.ptab i { font-size: .9rem; }
.ptab:hover { border-color: var(--brand-500); color: var(--text); }
.ptab.active { background: var(--gradient-brand); color: #fff; border-color: transparent; }
.ptab-panel { animation: fadeUp .4s var(--ease-out); }

/* Instagram grid */
.ig-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.ig-tile {
  aspect-ratio: 1 / 1; border-radius: 10px; position: relative; overflow: hidden;
  background: var(--surface-2); display: grid; place-items: center; color: #fff; font-size: 1.6rem;
  cursor: pointer; transition: transform var(--transition);
}
.ig-tile:hover { transform: scale(1.02); }
.ig-tile::after {
  content: attr(data-label); position: absolute; left: 0; right: 0; bottom: 0;
  padding: .4rem .5rem; font-size: .68rem; font-weight: 600;
  background: linear-gradient(transparent, rgba(0,0,0,.6)); opacity: 0; transition: opacity var(--transition);
}
.ig-tile:hover::after { opacity: 1; }
.t1 { background: linear-gradient(135deg,#f58529,#dd2a7b); }
.t2 { background: linear-gradient(135deg,#6366f1,#8b5cf6); }
.t3 { background: linear-gradient(135deg,#10b981,#34d399); }
.t4 { background: linear-gradient(135deg,#f59e0b,#fb7185); }
.t5 { background: linear-gradient(135deg,#0ea5e9,#6366f1); }
.t6 { background: linear-gradient(135deg,#ec4899,#f472b6); }
.t7 { background: linear-gradient(135deg,#8b5cf6,#6366f1); }
.t8 { background: linear-gradient(135deg,#34d399,#0ea5e9); }
.t9 { background: linear-gradient(135deg,#fb7185,#f59e0b); }

/* Reels grid */
.reels-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 1rem; }
.reel-card {
  aspect-ratio: 9 / 16; border-radius: var(--radius); overflow: hidden; position: relative;
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: .8rem; color: #fff; cursor: pointer;
}
.reel-card h4 { font-size: .9rem; margin: 0; }
.reel-card .reel-meta { font-size: .75rem; opacity: .9; }
.reel-card .reel-play {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%);
  width: 44px; height: 44px; border-radius: 50%; background: rgba(0,0,0,.4);
  display: grid; place-items: center; font-size: 1.1rem;
}
.r1 { background: linear-gradient(160deg,#dd2a7b,#8134af); }
.r2 { background: linear-gradient(160deg,#6366f1,#0ea5e9); }
.r3 { background: linear-gradient(160deg,#f59e0b,#ec4899); }
.r4 { background: linear-gradient(160deg,#10b981,#34d399); }

/* Stories row */
.stories-row { display: flex; gap: 1rem; flex-wrap: wrap; }
.story-card {
  width: 120px; text-align: center; cursor: pointer;
}
.story-ring {
  width: 84px; height: 84px; border-radius: 50%; margin: 0 auto .5rem;
  padding: 3px; background: linear-gradient(135deg,#f58529,#dd2a7b,#8134af);
}
.story-ring > span {
  width: 100%; height: 100%; border-radius: 50%; background: var(--surface);
  display: grid; place-items: center; font-size: 1.4rem; color: #fff;
}
.story-card.add .story-ring { background: var(--border-strong); }
.story-card.add .story-ring > span { color: var(--text-muted); background: var(--surface-2); }
.story-card p { font-size: .78rem; margin: 0; color: var(--text-soft); }

/* Highlights */
.ig-highlights { display: flex; gap: 1rem; flex-wrap: wrap; }
.highlight {
  width: 72px; text-align: center; cursor: pointer;
}
.highlight-ring {
  width: 64px; height: 64px; border-radius: 50%; margin: 0 auto .35rem;
  display: grid; place-items: center; font-size: 1.2rem; color: #fff;
}
.highlight p { font-size: .72rem; margin: 0; color: var(--text-muted); }

/* Hashtag sets */
.hashtag-set {
  padding: 1rem; border: 1px solid var(--border); border-radius: var(--radius);
  margin-bottom: .75rem; background: var(--surface);
}
.hashtag-set h4 { font-size: .95rem; margin: 0 0 .5rem; display: flex; align-items: center; justify-content: space-between; }
.hashtag-set .tags-cloud { display: flex; flex-wrap: wrap; gap: .35rem; }
.ht {
  font-size: .78rem; padding: .25rem .6rem; border-radius: var(--radius-pill);
  background: var(--surface-2); color: var(--brand-600); border: 1px solid var(--border); cursor: pointer;
}
.ht:hover { background: var(--brand-50); }
[data-theme="dark"] .ht:hover { background: rgba(99,102,241,.14); }
.ht .ht-count { color: var(--text-muted); font-size: .68rem; margin-left: .2rem; }

/* Caption library */
.caption-item {
  padding: 1rem; border: 1px solid var(--border); border-radius: var(--radius);
  margin-bottom: .75rem; background: var(--surface);
}
.caption-item .cap-top { display: flex; align-items: center; gap: .5rem; margin-bottom: .5rem; }
.caption-item p { margin: 0 0 .5rem; color: var(--text-soft); font-size: .9rem; line-height: 1.5; }
.caption-item .cap-actions { display: flex; gap: .5rem; }

/* Bio preview card */
.ig-preview-card {
  text-align: center; padding: 1.5rem; border-radius: var(--radius);
  background: var(--surface-2); border: 1px solid var(--border);
}
.ig-preview-av {
  width: 72px; height: 72px; border-radius: 50%; margin: 0 auto .75rem;
  display: grid; place-items: center; color: #fff; font-size: 1.8rem;
  background: linear-gradient(135deg,#f58529,#dd2a7b,#8134af);
}
.ig-preview-card h4 { margin: 0; font-size: 1.1rem; }
.ig-preview-handle { color: var(--brand-600); margin: .1rem 0 .6rem; font-size: .85rem; font-weight: 600; }
.ig-preview-bio { color: var(--text-soft); font-size: .9rem; margin: 0 0 .75rem; }
.ig-preview-link {
  display: inline-block; padding: .5rem 1rem; border-radius: var(--radius-sm);
  background: var(--surface); border: 1px solid var(--border); color: var(--text-soft);
  font-size: .8rem; font-weight: 600;
}

/* Competitor list */
.competitor-row {
  display: flex; align-items: center; gap: 1rem; padding: 1rem 0;
  border-bottom: 1px solid var(--border);
}
.competitor-row:last-child { border-bottom: none; }
.comp-av { width: 48px; height: 48px; border-radius: 50%; flex: none; display: grid; place-items: center; color: #fff; font-weight: 700; }
.comp-main { flex: 1; min-width: 0; }
.comp-main h4 { margin: 0; font-size: .95rem; }
.comp-main small { color: var(--text-muted); font-size: .8rem; }
.comp-bar { height: 6px; border-radius: 6px; background: var(--surface-2); overflow: hidden; margin-top: .35rem; }
.comp-bar > span { display: block; height: 100%; border-radius: 6px; background: var(--gradient-brand); }

/* Facebook-specific */
.fb-hero-bg { background: linear-gradient(135deg, #1877f2 0%, #6366f1 100%); opacity: .12; }
.fb-avatar { background: #1877f2; }

/* LinkedIn-specific */
.li-hero-bg { background: linear-gradient(135deg, #0a66c2 0%, #0077b5 100%); opacity: .12; }
.li-avatar { background: #0a66c2; }

/* YouTube-specific */
.yt-hero-bg { background: linear-gradient(135deg, #ff0000 0%, #cc0000 100%); opacity: .1; }
.yt-avatar { background: #ff0000; }
.yt-video-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 1rem; }
.yt-video-card {
  border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: var(--surface);
  transition: transform var(--transition), box-shadow var(--transition);
}
.yt-video-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.yt-thumb { aspect-ratio: 16/9; position: relative; display: grid; place-items: center; color: #fff; font-size: 2rem; }
.yt-duration {
  position: absolute; right: 8px; bottom: 8px; background: rgba(0,0,0,.8); color: #fff;
  font-size: .72rem; font-weight: 700; padding: .15rem .4rem; border-radius: 4px;
}
.yt-video-body { padding: .8rem; }
.yt-video-body h4 { font-size: .92rem; margin: 0 0 .3rem; line-height: 1.3; }
.yt-video-meta { font-size: .78rem; color: var(--text-muted); display: flex; gap: .8rem; }

/* SEO checklist (YouTube/LinkedIn) */
.checklist { list-style: none; padding: 0; margin: 0; display: grid; gap: .6rem; }
.checklist li { display: flex; align-items: center; gap: .65rem; font-size: .9rem; color: var(--text-soft); }
.checklist .chk-ic {
  width: 24px; height: 24px; border-radius: 7px; flex: none;
  display: grid; place-items: center; font-size: .75rem;
}
.chk-done { background: rgba(16,185,129,.16); color: var(--accent-emerald); }
.chk-todo { background: var(--surface-2); color: var(--text-muted); border: 1px solid var(--border); }

/* Audience insights list */
.audience-row { display: flex; align-items: center; gap: .75rem; padding: .6rem 0; }
.audience-row:not(:last-child) { border-bottom: 1px solid var(--border); }
.audience-ic { width: 36px; height: 36px; border-radius: 9px; display: grid; place-items: center; flex: none; }
.audience-row .a-name { flex: 1; font-size: .88rem; color: var(--text-soft); }
.audience-row .a-val { font-weight: 700; font-family: 'Sora'; font-size: .92rem; }

/* Ad campaign overview */
.ad-card {
  padding: 1rem; border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: .75rem; background: var(--surface);
}
.ad-card .ad-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: .5rem; }
.ad-card h4 { font-size: .95rem; margin: 0; }
.ad-card .ad-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: .5rem; margin-top: .5rem; }
.ad-card .ad-stat { text-align: center; }
.ad-card .ad-stat small { display: block; font-size: .68rem; color: var(--text-muted); }
.ad-card .ad-stat strong { font-family: 'Sora'; font-size: .95rem; }
.ad-progress { height: 6px; border-radius: 6px; background: var(--surface-2); overflow: hidden; margin-top: .5rem; }
.ad-progress > span { display: block; height: 100%; background: var(--gradient-brand); }

/* Lead gen placeholder (LinkedIn) */
.lead-card {
  display: flex; align-items: center; gap: .75rem; padding: .75rem; border-radius: var(--radius-sm);
  background: var(--surface-2); border: 1px dashed var(--border-strong); margin-bottom: .5rem;
}
.lead-card i { color: var(--accent-sky); font-size: 1.1rem; }

/* Messenger/WhatsApp placeholder */
.chat-placeholder {
  text-align: center; padding: 2rem 1rem; color: var(--text-muted);
}
.chat-placeholder i { font-size: 2.4rem; margin-bottom: .5rem; color: var(--border-strong); }

@media (max-width: 767.98px) {
  .ad-card .ad-stats { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- Profile page ---------- */
.profile-hero-bg { height: 80px; border-radius: var(--radius) var(--radius) 0 0; background: var(--gradient-brand); margin: -1.25rem -1.25rem 0; opacity: .12; }
.profile-hero-body { position: relative; }
.profile-avatar-lg {
  width: 96px; height: 96px; border-radius: 50%; margin: -48px auto 0;
  display: grid; place-items: center; color: #fff; font-family: 'Sora'; font-weight: 800; font-size: 2rem;
  background: var(--gradient-brand); border: 4px solid var(--surface); box-shadow: var(--shadow-md);
}

/* ---------- Settings page ---------- */
.settings-nav { display: flex; flex-direction: column; gap: .25rem; }
.settings-nav a {
  display: flex; align-items: center; gap: .65rem; padding: .6rem .75rem;
  border-radius: var(--radius-sm); color: var(--text-soft); font-weight: 500; font-size: .9rem;
}
.settings-nav a i { width: 18px; color: var(--text-muted); }
.settings-nav a:hover { background: var(--surface-2); color: var(--text); }
.settings-nav a.active { background: var(--brand-50); color: var(--brand-700); }
[data-theme="dark"] .settings-nav a.active { background: rgba(99,102,241,.16); color: var(--brand-300); }
.color-swatches { display: flex; gap: .6rem; flex-wrap: wrap; }
.color-swatch {
  width: 40px; height: 40px; border-radius: 50%; cursor: pointer;
  border: 3px solid transparent; transition: transform var(--transition), border-color var(--transition);
}
.color-swatch:hover { transform: scale(1.1); }
.color-swatch.active { border-color: var(--text); transform: scale(1.1); }

/* ---------- Contact page ---------- */
.contact-channel { display: flex; align-items: center; gap: 1rem; padding: 1.25rem; }
.contact-channel-ic {
  width: 52px; height: 52px; border-radius: 14px; flex: none;
  display: grid; place-items: center; color: #fff; font-size: 1.3rem;
}
.faq-mini-item { border-bottom: 1px solid var(--border); }
.faq-mini-item:last-child { border-bottom: none; }
.faq-mini-q { width: 100%; text-align: left; background: none; border: none; padding: 1rem 0; font-weight: 600; color: var(--text); display: flex; align-items: center; }
.faq-mini-q i { margin-left: auto; transition: transform var(--transition); color: var(--text-muted); }
.faq-mini-q[aria-expanded="true"] i { transform: rotate(180deg); }
