/* PostingCage — design tokens aligned to the Fuse Angular Material admin
   template (https://angular-material.fusetheme.com/admin): --surface-1/--page-plane
   sampled from its light content plane, --sidebar-bg from its dark mat-sidenav,
   --brand-accent-strong from its primary button. Cards are flat/bordered
   (--card-shadow: none) rather than shadow-based, matching Fuse's look. */

.viz-root {
  color-scheme: light;
  --surface-1:      #ffffff;
  --page-plane:     #f3f4f6;
  --text-primary:   #111827;
  --text-secondary: #4b5563;
  --text-muted:     #6b7280;
  --gridline:       #e5e7eb;
  --baseline:       #d1d5db;
  --border:         #e5e7eb;
  --series-1:       #2a78d6; /* blue — single-series sequential default */
  --status-good:     #0ca30c;
  --status-warning:  #fab219;
  --status-serious:  #ec835a;
  --status-critical: #d03b3b;
  --success-text:    #006300;
  --brand-accent:    #2a78d6; /* Fuse's mid-blue */
  --brand-accent-strong: #1565c0; /* Fuse's primary-button blue */
  --sidebar-bg:      #101828; /* Fuse's mat-sidenav dark navy */
  --sidebar-bg-2:    #0b101d;
  --card-radius:     8px;
  --card-shadow:     none;
}
@media (prefers-color-scheme: dark) {
  :root:where(:not([data-theme="light"])) .viz-root {
    color-scheme: dark;
    --surface-1:      #1a1a19;
    --page-plane:     #0d0d0d;
    --text-primary:   #ffffff;
    --text-secondary: #c3c2b7;
    --text-muted:     #898781;
    --gridline:       #2c2c2a;
    --baseline:       #383835;
    --border:         rgba(255,255,255,0.10);
    --series-1:       #3987e5;
    --status-good:     #0ca30c;
    --status-warning:  #fab219;
    --status-serious:  #ec835a;
    --status-critical: #d03b3b;
    --success-text:    #0ca30c;
  }
}
:root[data-theme="dark"] .viz-root {
  color-scheme: dark;
  --surface-1:      #1a1a19;
  --page-plane:     #0d0d0d;
  --text-primary:   #ffffff;
  --text-secondary: #c3c2b7;
  --text-muted:     #898781;
  --gridline:       #2c2c2a;
  --baseline:       #383835;
  --border:         rgba(255,255,255,0.10);
  --series-1:       #3987e5;
  --success-text:    #0ca30c;
}

body.pc-dashboard {
  background: var(--page-plane, #f8f9fa);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* ================================================================
   Layout shell — AdminLTE v4 structure: dark app-sidebar (250px,
   fixed), light app-header, tertiary-gray content plane.
   ================================================================ */
.pc-shell { display: flex; min-height: 100vh; }

.pc-sidebar {
  width: 250px;
  flex-shrink: 0;
  background: var(--sidebar-bg, #101828);
  color: #c2c7d0;
  box-shadow: none;
  border-right: 1px solid rgba(255,255,255,0.06);
  transition: margin-left 0.2s ease-in-out;
}
.pc-sidebar .sidebar-brand {
  display: flex; align-items: center; gap: 0.65rem;
  padding: 0.8rem 1rem;
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.3px;
  border-bottom: 1px solid rgba(255,255,255,0.15);
  white-space: nowrap; overflow: hidden;
}
.pc-sidebar .sidebar-brand-mark {
  width: 32px; height: 32px; border-radius: 8px; flex-shrink: 0;
  background: var(--brand-accent, #2a78d6); color: #fff;
  display: flex; align-items: center; justify-content: center; font-size: 0.95rem;
  box-shadow: 0 0 0 2px rgba(255,255,255,0.15);
}
.pc-sidebar .sidebar-brand-text span { color: var(--brand-accent, #2a78d6); }

.pc-nav { list-style: none; margin: 0.6rem 0.5rem; padding: 0; }
.pc-nav .pc-nav-item a {
  display: flex; align-items: center; gap: 0.75rem;
  padding: 0.6rem 0.75rem; margin-bottom: 0.1rem;
  color: #c2c7d0; text-decoration: none; font-size: 0.9rem; border-radius: 6px;
}
.pc-nav .pc-nav-item a i:first-child { width: 18px; text-align: center; opacity: 0.9; flex-shrink: 0; }
.pc-nav .pc-nav-item a:hover { background: rgba(255,255,255,0.1); color: #fff; }
.pc-nav .pc-nav-item.active a {
  background: rgba(255,255,255,0.1);
  color: #fff;
  font-weight: 600;
}
.pc-nav .pc-nav-section {
  padding: 1rem 0.75rem 0.35rem;
  font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--brand-accent, #2a78d6);
  font-weight: 700;
  display: flex; flex-direction: column; gap: 0.15rem;
}
.pc-nav .pc-nav-section:first-child { padding-top: 0.6rem; }
.pc-nav-section-subtitle {
  text-transform: none; letter-spacing: normal; font-weight: 400;
  font-size: 0.72rem; color: #8a929b;
}

/* Per-page "Channels" nav — each connected Facebook Page with a Publish/Insights sub-nav */
.pc-nav-channel-toggle {
  width: 100%; display: flex; align-items: center; gap: 0.6rem;
  padding: 0.55rem 0.75rem; margin-bottom: 0.1rem;
  background: transparent; border: 0; color: #c2c7d0; font-size: 0.88rem;
  border-radius: 6px; cursor: pointer; text-align: left;
}
.pc-nav-channel-toggle:hover { background: rgba(255,255,255,0.1); color: #fff; }
.pc-nav-channel.active > .pc-nav-channel-toggle { background: rgba(255,255,255,0.1); color: #fff; font-weight: 600; }
.pc-nav-channel-icon {
  width: 22px; height: 22px; border-radius: 6px; object-fit: cover; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 700; font-size: 0.68rem;
}
.pc-nav-channel-name {
  flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.pc-nav-channel-count {
  font-size: 0.72rem; color: #8a929b; background: rgba(255,255,255,0.08);
  border-radius: 10px; padding: 0.05rem 0.45rem; flex-shrink: 0;
}
.pc-nav-channel.is-open .pc-nav-channel-count { display: none; }
.pc-nav-channel-caret {
  font-size: 0.7rem; opacity: 0.7; transition: transform 0.15s ease; flex-shrink: 0;
}
.pc-nav-channel.is-open .pc-nav-channel-caret { transform: rotate(180deg); }
.pc-nav-sub {
  list-style: none; margin: 0; padding: 0;
  max-height: 0; overflow: hidden; transition: max-height 0.2s ease;
}
.pc-nav-channel.is-open .pc-nav-sub { max-height: 200px; }
.pc-nav-sub li a {
  display: flex; align-items: center; gap: 0.65rem;
  padding: 0.45rem 0.75rem 0.45rem 1.9rem; font-size: 0.84rem;
  color: #a8afb8; text-decoration: none; border-radius: 6px;
}
.pc-nav-sub li a i { width: 16px; text-align: center; opacity: 0.85; flex-shrink: 0; }
.pc-nav-sub li a:hover { background: rgba(255,255,255,0.08); color: #fff; }
.pc-nav-sub li a.active { background: rgba(42,120,214,0.22); color: #fff; font-weight: 600; }

/* Icon-only collapsed state (sidebar toggle in the topbar) */
body.pc-sidebar-collapsed .pc-sidebar { width: 62px; }
body.pc-sidebar-collapsed .pc-sidebar .sidebar-brand-text,
body.pc-sidebar-collapsed .pc-nav .pc-nav-item a span,
body.pc-sidebar-collapsed .pc-nav .pc-nav-item a .pc-nav-badge {
  display: none;
}
body.pc-sidebar-collapsed .pc-sidebar .sidebar-brand { justify-content: center; padding: 0.8rem 0; }
body.pc-sidebar-collapsed .pc-nav .pc-nav-item a { justify-content: center; padding: 0.65rem; }
body.pc-sidebar-collapsed .pc-nav .pc-nav-item a i:first-child { width: auto; }
body.pc-sidebar-collapsed .pc-nav-section,
body.pc-sidebar-collapsed .pc-nav-channel-name,
body.pc-sidebar-collapsed .pc-nav-channel-count,
body.pc-sidebar-collapsed .pc-nav-channel-caret,
body.pc-sidebar-collapsed .pc-nav-sub {
  display: none;
}
body.pc-sidebar-collapsed .pc-nav-channel-toggle { justify-content: center; padding: 0.65rem; }

.pc-main { flex: 1; min-width: 0; }

.pc-topbar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem;
  padding: 0.6rem 1rem;
  background: var(--surface-1, #fff);
  border-bottom: 1px solid var(--border, #dee2e6);
}
.pc-topbar-left { display: flex; align-items: center; gap: 0.75rem; min-width: 0; }
.pc-sidebar-toggle {
  border: 0; background: transparent; color: var(--text-secondary, #495057);
  width: 36px; height: 36px; border-radius: 6px; font-size: 1.1rem; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.pc-sidebar-toggle:hover { background: var(--page-plane, #f8f9fa); }
.pc-topbar .pc-search {
  display: flex; align-items: center; gap: 0.5rem;
  background: var(--page-plane, #f8f9fa); border-radius: 6px;
  padding: 0.4rem 0.85rem; color: var(--text-muted, #6c757d);
  width: 320px; max-width: 40vw;
}
.pc-topbar .pc-search input { border: 0; background: transparent; outline: none; width: 100%; font-size: 0.88rem; }
.pc-topbar .pc-user { display: flex; align-items: center; gap: 0.35rem; }
.pc-topbar-icon {
  position: relative; color: var(--text-secondary, #495057); font-size: 1.05rem;
  width: 38px; height: 38px; border-radius: 6px; border: 0; background: transparent;
  display: inline-flex; align-items: center; justify-content: center; text-decoration: none; cursor: pointer;
}
.pc-topbar-icon:hover { background: var(--page-plane, #f8f9fa); color: var(--text-primary, #212529); }
.pc-topbar .pc-bell .pc-dot {
  position: absolute; top: 4px; right: 4px; width: 8px; height: 8px;
  border-radius: 50%; background: var(--status-critical, #d03b3b);
  border: 2px solid var(--surface-1, #fff);
}

/* User menu dropdown */
.pc-user-pop-wrap { position: relative; }
.pc-avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--brand-accent, #2a78d6); color: #fff; display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 0.8rem; box-shadow: 0 0 0 2px var(--surface-1, #fff), 0 0 0 3px rgba(0,0,0,0.08);
  border: 0; cursor: pointer;
}
.pc-user-menu {
  position: absolute; right: 0; top: calc(100% + 0.5rem); z-index: 50;
  min-width: 190px; background: var(--surface-1, #fff); border: 1px solid var(--border, #dee2e6);
  border-radius: var(--card-radius, 8px); box-shadow: var(--bs-box-shadow, 0 0.5rem 1rem rgba(0,0,0,0.15));
  padding: 0.4rem; display: none;
}
.pc-user-menu.is-open { display: block; }
.pc-user-menu-head { padding: 0.5rem 0.6rem 0.65rem; border-bottom: 1px solid var(--gridline, #eee); margin-bottom: 0.3rem; }
.pc-user-menu-head strong { display: block; font-size: 0.86rem; color: var(--text-primary, #212529); }
.pc-user-menu-head span { font-size: 0.75rem; color: var(--text-muted, #6c757d); }
.pc-user-menu a {
  display: flex; align-items: center; gap: 0.6rem; padding: 0.5rem 0.6rem; border-radius: 6px;
  color: var(--text-primary, #212529); text-decoration: none; font-size: 0.86rem;
}
.pc-user-menu a:hover { background: var(--page-plane, #f8f9fa); color: var(--text-primary, #212529); }
.pc-user-menu a.is-danger { color: var(--status-critical, #d03b3b); }
.pc-user-menu form { margin: 0; }

.pc-content { padding: 1.5rem; }

.pc-page-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.25rem; }
.pc-page-head h1 { font-size: 1.5rem; font-weight: 600; margin: 0; color: var(--text-primary, #1a1a2e); }
.pc-page-head p { margin: 0.15rem 0 0; color: var(--text-secondary, #767b91); font-size: 0.9rem; }

/* ---- Stat tiles ---- */
.pc-stat-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; margin-bottom: 1.25rem; }
@media (max-width: 992px) { .pc-stat-row { grid-template-columns: repeat(2, 1fr); } }

.pc-stat-tile {
  background: var(--surface-1, #fff); border: 1px solid var(--border, #eee);
  border-radius: var(--card-radius, 8px); padding: 1.1rem 1.25rem;
  box-shadow: var(--card-shadow, 0 0.125rem 0.25rem rgba(0,0,0,0.075));
}
.pc-stat-tile .pc-stat-top { display: flex; align-items: center; justify-content: space-between; }
.pc-stat-tile .pc-stat-label { font-size: 0.82rem; color: var(--text-secondary, #767b91); }
.pc-stat-tile .pc-stat-icon {
  width: 34px; height: 34px; border-radius: 8px; display: flex; align-items: center; justify-content: center;
  font-size: 0.95rem;
}
.pc-stat-tile .pc-stat-value {
  font-size: 1.7rem; font-weight: 700; color: var(--text-primary, #1a1a2e);
  margin-top: 0.35rem; line-height: 1.1;
}
.pc-stat-tile .pc-stat-delta { font-size: 0.8rem; margin-top: 0.3rem; display: flex; align-items: center; gap: 0.3rem; }
.pc-stat-tile .pc-stat-delta.is-good { color: var(--success-text, #006300); }
.pc-stat-tile .pc-stat-delta.is-bad { color: var(--status-critical, #d03b3b); }
.pc-stat-tile .pc-stat-delta .pc-delta-period { color: var(--text-muted, #898781); }

/* ---- Cards ---- */
.pc-card {
  background: var(--surface-1, #fff); border: 1px solid var(--border, #eee);
  border-radius: var(--card-radius, 8px); margin-bottom: 1.25rem;
  box-shadow: var(--card-shadow, 0 0.125rem 0.25rem rgba(0,0,0,0.075));
}
.pc-card .pc-card-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.75rem 1.25rem; border-bottom: 1px solid var(--gridline, #eee);
}
.pc-card .pc-card-head h5 { margin: 0; font-size: 1rem; font-weight: 700; color: var(--text-primary, #1a1a2e); }
.pc-card .pc-card-head .pc-card-sub { font-size: 0.78rem; color: var(--text-muted, #898781); margin-top: 0.1rem; }
.pc-card .pc-card-body { padding: 1.25rem; }

/* ---- Dashboard: greeting / streak / first steps ---- */
.pc-dash-greet { display: flex; align-items: center; gap: 0.9rem; margin-bottom: 1.25rem; }
.pc-dash-wave {
  width: 42px; height: 42px; border-radius: 10px; flex-shrink: 0;
  background: rgba(24,119,242,0.10); display: flex; align-items: center; justify-content: center; font-size: 1.35rem;
}
.pc-dash-greet h1 { font-size: 1.5rem; font-weight: 600; margin: 0; color: var(--text-primary, #1a1a2e); }
.pc-dash-greet p { margin: 0.1rem 0 0; color: var(--text-secondary, #767b91); font-size: 0.88rem; }

.pc-dash-stats {
  display: flex; align-items: center; flex-wrap: wrap; gap: 2.5rem;
  background: var(--page-plane, #f8f9fa); border: 1px solid var(--border, #eee);
  border-radius: var(--card-radius, 8px); padding: 1.25rem 1.5rem; margin-bottom: 1.5rem;
}
.pc-dash-stat { display: flex; align-items: center; gap: 1rem; }
.pc-dash-ring {
  width: 52px; height: 52px; border-radius: 50%; border: 3px solid;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
  font-size: 1.15rem; font-weight: 700;
}
.pc-dash-ring.is-streak { border-color: var(--brand-accent, #2a78d6); color: var(--brand-accent, #2a78d6); }
.pc-dash-ring.is-goal { border-color: var(--baseline, #c3c2b7); color: var(--text-muted, #898781); }
.pc-dash-stat-label { font-size: 0.88rem; font-weight: 600; color: var(--text-primary, #1a1a2e); display: flex; align-items: center; gap: 0.35rem; }
.pc-dash-stat-label i { font-size: 0.78rem; color: var(--text-muted, #898781); cursor: help; }
.pc-dash-stat-sub { font-size: 0.8rem; color: var(--text-muted, #898781); margin-top: 0.1rem; }

.pc-dash-section-label {
  font-size: 0.95rem; font-weight: 700; color: var(--text-primary, #1a1a2e); margin: 0 0 0.9rem;
}

.pc-dash-steps { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: 1.25rem; }
@media (max-width: 820px) { .pc-dash-steps { grid-template-columns: 1fr; } }

.pc-dash-step-card {
  background: var(--page-plane, #f8f9fa); border: 1px solid var(--border, #eee);
  border-radius: var(--card-radius, 8px); padding: 1.15rem 1.25rem;
}
.pc-dash-step-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 0.75rem; }
.pc-dash-step-head h5 { margin: 0; font-size: 0.95rem; font-weight: 700; color: var(--text-primary, #1a1a2e); }
.pc-dash-step-head i { font-size: 1.05rem; color: var(--baseline, #c3c2b7); flex-shrink: 0; margin-top: 0.1rem; }
.pc-dash-step-head i.is-done { color: var(--status-good, #0ca30c); }
.pc-dash-step-card p { font-size: 0.85rem; color: var(--text-secondary, #767b91); margin: 0.5rem 0 1rem; line-height: 1.5; }
.pc-dash-step-btn {
  display: inline-flex; align-items: center; gap: 0.45rem;
  border: 1px solid var(--border, #ddd); background: var(--surface-1, #fff); color: var(--text-primary, #1a1a2e);
  font-size: 0.85rem; font-weight: 600; padding: 0.5rem 0.9rem; border-radius: 8px; text-decoration: none;
}
.pc-dash-step-btn:hover { background: var(--page-plane, #f4f4f1); color: var(--text-primary, #1a1a2e); text-decoration: none; }

/* ---- Table-view toggle ---- */
.pc-toggle-btn {
  border: 1px solid var(--border, #ddd); background: transparent; color: var(--text-secondary, #767b91);
  font-size: 0.76rem; padding: 0.25rem 0.6rem; border-radius: 6px; cursor: pointer;
}
.pc-toggle-btn:hover { background: var(--page-plane, #f4f6fb); }

/* ---- Line chart ---- */
.pc-chart-wrap { position: relative; }
.pc-chart-wrap table.pc-data-table { display: none; }
.pc-chart-wrap.is-table-view svg.pc-chart-svg { display: none; }
.pc-chart-wrap.is-table-view table.pc-data-table { display: table; }

svg.pc-chart-svg .grid-line { stroke: var(--gridline); stroke-width: 1; }
svg.pc-chart-svg .baseline { stroke: var(--baseline); stroke-width: 1; }
svg.pc-chart-svg .axis-label { fill: var(--text-muted); font-size: 11px; }
svg.pc-chart-svg .series-line { stroke: var(--series-1); stroke-width: 2; fill: none; stroke-linecap: round; stroke-linejoin: round; }
svg.pc-chart-svg .series-area { fill: var(--series-1); opacity: 0.10; }
svg.pc-chart-svg .end-dot { fill: var(--series-1); stroke: var(--surface-1); stroke-width: 2; }
svg.pc-chart-svg .hover-dot { fill: var(--series-1); stroke: var(--surface-1); stroke-width: 2; opacity: 0; }
svg.pc-chart-svg .crosshair { stroke: var(--baseline); stroke-width: 1; opacity: 0; }
svg.pc-chart-svg .end-label { fill: var(--text-primary); font-size: 13px; font-weight: 700; }

.pc-tooltip {
  position: absolute; pointer-events: none; opacity: 0;
  background: var(--text-primary, #1a1a2e); color: var(--surface-1, #fff);
  font-size: 0.78rem; padding: 0.35rem 0.6rem; border-radius: 6px;
  transform: translate(-50%, -115%); white-space: nowrap; transition: opacity 0.08s;
}

table.pc-data-table { width: 100%; border-collapse: collapse; font-size: 0.85rem; }
table.pc-data-table th, table.pc-data-table td {
  text-align: left; padding: 0.4rem 0.6rem; border-bottom: 1px solid var(--gridline);
  color: var(--text-secondary);
  font-variant-numeric: tabular-nums;
}
table.pc-data-table th { color: var(--text-muted); font-weight: 600; font-size: 0.75rem; text-transform: uppercase; }

/* ---- Queue table ---- */
.pc-queue-table { width: 100%; border-collapse: collapse; }
.pc-queue-table th {
  text-align: left; font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.04em;
  color: var(--text-muted, #898781); padding: 0.5rem 0.75rem; border-bottom: 1px solid var(--gridline, #eee);
}
.pc-queue-table td { padding: 0.65rem 0.75rem; border-bottom: 1px solid var(--gridline, #f1f1ee); font-size: 0.86rem; vertical-align: middle; }
.pc-queue-table tr:last-child td { border-bottom: 0; }
.pc-queue-caption { color: var(--text-secondary, #767b91); max-width: 260px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.pc-btn-primary {
  background: var(--brand-accent-strong, #1565c0); border: none; color: #fff; font-size: 0.85rem; font-weight: 600;
  padding: 0.55rem 1.1rem; border-radius: 8px; display: inline-flex; align-items: center; gap: 0.4rem;
  text-decoration: none; box-shadow: var(--card-shadow, none);
}
.pc-btn-primary:hover { background: #0d47a1; color: #fff; }

/* ---- Accounts page: connect header ---- */
.pc-connect-head { display: flex; align-items: center; gap: 0.6rem; margin-bottom: 1.25rem; }
.pc-connect-head .pc-fb-mark {
  width: 30px; height: 30px; border-radius: 7px; background: #1877f2; color: #fff;
  display: flex; align-items: center; justify-content: center; font-size: 1rem;
}
.pc-connect-head h1 { font-size: 1.5rem; font-weight: 600; color: #1877f2; margin: 0; }
.pc-btn-fb {
  background: #1877f2; border: none; color: #fff; font-size: 0.9rem; font-weight: 600;
  padding: 0.6rem 1.2rem; border-radius: 8px; display: inline-flex; align-items: center; gap: 0.5rem;
  text-decoration: none; box-shadow: var(--card-shadow, none);
}
.pc-btn-fb:hover { background: #1466d4; color: #fff; }

/* ---- Account header row (avatar · N pages · name · unlink) ---- */
.pc-account-head { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }
.pc-account-avatar {
  width: 82px; height: 82px; border-radius: 8px; object-fit: cover; flex-shrink: 0;
  border: 1px solid var(--border, #e7e7e7); background: var(--page-plane, #f4f6fb);
}
.pc-account-avatar-fallback {
  width: 82px; height: 82px; border-radius: 8px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: #1877f2; color: #fff; font-size: 2rem; font-weight: 700;
}
.pc-account-meta { flex: 1; min-width: 180px; }
.pc-account-meta .pc-page-count { font-size: 0.8rem; color: var(--text-muted, #898781); }
.pc-account-meta .pc-account-name { font-size: 1.05rem; font-weight: 700; color: var(--text-primary); margin: 0.15rem 0 0.5rem; }
.pc-btn-unlink {
  border: 1px solid var(--status-critical, #d03b3b); color: var(--status-critical, #d03b3b);
  background: transparent; font-size: 0.8rem; font-weight: 600; padding: 0.3rem 0.7rem;
  border-radius: 6px; display: inline-flex; align-items: center; gap: 0.35rem; cursor: pointer;
}
.pc-btn-unlink:hover { background: rgba(208,59,59,0.08); }
.pc-account-search {
  margin-left: auto; display: flex; align-items: center; gap: 0.5rem;
  background: var(--page-plane, #f4f6fb); border: 1px solid var(--border, #e7e7e7);
  border-radius: 8px; padding: 0.45rem 0.8rem; min-width: 220px;
}
.pc-account-search input { border: 0; background: transparent; outline: none; width: 100%; font-size: 0.85rem; color: var(--text-primary); }

/* ---- Page list heading ---- */
.pc-pagelist-title { font-size: 0.95rem; font-weight: 700; color: var(--text-primary); margin: 1.5rem 0 0.9rem; }
.pc-pagelist-title span { color: var(--text-muted, #898781); font-weight: 500; }

/* ---- Page card grid ---- */
.pc-page-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
@media (max-width: 1100px) { .pc-page-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 720px) { .pc-page-grid { grid-template-columns: 1fr; } }

.pc-page-card {
  background: var(--surface-1, #fff); border: 1px solid var(--border, #eee);
  border-radius: var(--card-radius, 8px); padding: 1.1rem 1.15rem;
  box-shadow: var(--card-shadow, 0 0.125rem 0.25rem rgba(0,0,0,0.075));
}
.pc-page-card .pc-page-top { display: flex; gap: 0.9rem; }
.pc-page-card .pc-page-pic {
  width: 64px; height: 64px; border-radius: 50%; object-fit: cover; flex-shrink: 0;
}
.pc-page-card .pc-page-pic-fallback {
  width: 64px; height: 64px; border-radius: 50%; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 1.6rem; font-weight: 700;
}
.pc-page-card .pc-page-info { min-width: 0; }
.pc-page-card .pc-page-name { color: #1877f2; font-weight: 600; font-size: 0.98rem; overflow-wrap: anywhere; }
.pc-page-card .pc-page-email { font-size: 0.82rem; color: var(--text-secondary); margin-top: 0.2rem; display: flex; align-items: center; gap: 0.3rem; overflow-wrap: anywhere; }
.pc-page-card .pc-page-id { font-size: 0.78rem; color: var(--text-muted); margin-top: 0.15rem; display: flex; align-items: center; gap: 0.35rem; font-variant-numeric: tabular-nums; }
.pc-page-card .pc-page-id .pc-status-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--status-good, #0ca30c); flex-shrink: 0; }
.pc-page-card .pc-page-actions { display: flex; align-items: center; justify-content: space-between; margin-top: 1rem; gap: 0.5rem; }
.pc-btn-analytics {
  border: 1px solid #1877f2; color: #1877f2; background: transparent;
  font-size: 0.8rem; font-weight: 600; padding: 0.35rem 0.8rem; border-radius: 20px;
  display: inline-flex; align-items: center; gap: 0.4rem; text-decoration: none;
}
.pc-btn-analytics:hover { background: rgba(24,119,242,0.08); color: #1877f2; }
.pc-page-iconbtns { display: flex; gap: 0.4rem; }
.pc-icon-btn {
  width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--border, #ddd);
  background: transparent; display: inline-flex; align-items: center; justify-content: center;
  cursor: pointer; font-size: 0.8rem; color: var(--text-secondary);
}
.pc-icon-btn.is-danger { border-color: var(--status-critical, #d03b3b); color: var(--status-critical, #d03b3b); }
.pc-icon-btn.is-danger:hover { background: rgba(208,59,59,0.08); }
.pc-icon-btn:hover { background: var(--page-plane, #f4f6fb); }

/* ---- Analytics dashboard ---- */
.pc-analytics-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
@media (max-width: 980px) { .pc-analytics-grid { grid-template-columns: 1fr; } }

.pc-legend { display: flex; flex-wrap: wrap; gap: 0.9rem; margin-bottom: 0.75rem; }
.pc-legend .pc-legend-item { display: inline-flex; align-items: center; gap: 0.4rem; font-size: 0.8rem; color: var(--text-secondary); }
.pc-legend .pc-legend-swatch { width: 12px; height: 12px; border-radius: 3px; display: inline-block; }

/* Horizontal bars (engagement breakdown, countries) */
.pc-hbars { list-style: none; margin: 0; padding: 0; }
.pc-hbars li { margin-bottom: 0.85rem; }
.pc-hbars li:last-child { margin-bottom: 0; }
.pc-hbar-head { display: flex; justify-content: space-between; font-size: 0.82rem; margin-bottom: 0.3rem; }
.pc-hbar-head .pc-hbar-label { color: var(--text-secondary); }
.pc-hbar-head .pc-hbar-value { color: var(--text-primary); font-weight: 600; font-variant-numeric: tabular-nums; }
.pc-hbar-track { height: 10px; background: var(--gridline, #eee); border-radius: 5px; overflow: hidden; }
.pc-hbar-fill { height: 100%; border-radius: 5px; background: var(--series-1, #2a78d6); }

/* Age × gender grouped rows */
.pc-agegender li { margin-bottom: 0.7rem; }
.pc-agegender .pc-ag-bucket { font-size: 0.8rem; color: var(--text-secondary); margin-bottom: 0.25rem; }
.pc-ag-bar { height: 9px; border-radius: 5px; margin-bottom: 0.25rem; min-width: 2px; }
.pc-ag-bar.is-f { background: #eb6834; }   /* categorical slot 2 (orange) */
.pc-ag-bar.is-m { background: #2a78d6; }   /* categorical slot 1 (blue) */

/* Best-time heatmap */
.pc-heatmap-wrap { overflow-x: auto; }
.pc-heatmap { border-collapse: separate; border-spacing: 2px; }
.pc-heatmap th { font-size: 0.68rem; color: var(--text-muted); font-weight: 500; padding: 2px; text-align: center; }
.pc-heatmap td.pc-day-label { font-size: 0.72rem; color: var(--text-secondary); padding-right: 6px; text-align: right; white-space: nowrap; }
.pc-heatmap .pc-heat-cell { width: 16px; height: 16px; border-radius: 3px; }

/* Top-posts table reuses .pc-queue-table; add numeric cells */
.pc-num { text-align: right; font-variant-numeric: tabular-nums; }

/* ---- Composer ---- */
.pc-target-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.6rem; }
@media (max-width: 820px) { .pc-target-list { grid-template-columns: 1fr; } }
.pc-target-list label {
  display: flex; align-items: center; gap: 0.7rem; margin: 0; padding: 0.6rem 0.75rem;
  border: 1px solid var(--border, #e7e7e7); border-radius: 8px; cursor: pointer;
}
.pc-target-list label:hover { background: var(--page-plane, #f4f6fb); }
.pc-target-list input:checked + .pc-target-body { color: var(--text-primary); }
.pc-target-list .pc-target-name { font-weight: 600; font-size: 0.9rem; color: var(--text-primary); }
.pc-target-list .pc-target-sub { font-size: 0.76rem; color: var(--text-muted); }

.pc-type-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
@media (max-width: 820px) { .pc-type-grid { grid-template-columns: 1fr; } }
.pc-type-card {
  background: var(--surface-1, #fff); border: 1px solid var(--border, #eee); border-radius: var(--card-radius, 8px);
  box-shadow: var(--card-shadow, 0 0.125rem 0.25rem rgba(0,0,0,0.075));
  padding: 1.4rem 1.25rem; cursor: pointer; text-align: left; width: 100%; display: block;
  text-decoration: none;
  transition: border-color .12s, box-shadow .12s, transform .12s;
}
.pc-type-card:hover { text-decoration: none; }
.pc-type-card:hover { border-color: var(--brand-accent-strong, #1565c0); box-shadow: 0 3px 12px rgba(21,101,192,0.10); transform: translateY(-1px); }
.pc-type-card:disabled { opacity: 0.55; cursor: not-allowed; }
.pc-type-card .pc-type-icon {
  width: 46px; height: 46px; border-radius: 10px; display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 1.3rem; margin-bottom: 0.85rem;
}
.pc-type-card h5 { margin: 0 0 0.35rem; font-size: 1rem; color: var(--text-primary); }
.pc-type-card p { margin: 0; font-size: 0.83rem; color: var(--text-secondary); line-height: 1.4; }

/* ---- Media Post editor (3-column) ---- */
.pc-composer { display: grid; grid-template-columns: 260px minmax(0, 1fr) 360px; gap: 1rem; align-items: start; }
@media (max-width: 1200px) { .pc-composer { grid-template-columns: 240px minmax(0, 1fr); } .pc-composer .pc-preview-col { grid-column: 1 / -1; } }
@media (max-width: 820px) { .pc-composer { grid-template-columns: 1fr; } }

.pc-composer .pc-card { margin-bottom: 0; }

/* Left: page picker */
.pc-publish-link { color: #1877f2; font-weight: 600; font-size: 0.9rem; text-decoration: none; display: inline-flex; align-items: center; gap: 0.4rem; }
.pc-page-checklist { list-style: none; margin: 0.5rem 0 0; padding: 0; max-height: 360px; overflow-y: auto; }
.pc-page-checklist li { display: flex; align-items: center; gap: 0.6rem; padding: 0.5rem 0.25rem; border-bottom: 1px solid var(--gridline, #eee); }
.pc-page-checklist li:last-child { border-bottom: 0; }
.pc-page-checklist label { display: flex; align-items: center; gap: 0.6rem; margin: 0; cursor: pointer; width: 100%; }
.pc-page-checklist .pc-mini-avatar { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; flex-shrink: 0; display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 700; }
.pc-page-checklist .pc-page-nm { font-size: 0.9rem; color: var(--text-primary); }

/* Tabs */
.pc-tabs { display: flex; gap: 0.25rem; border-bottom: 1px solid var(--gridline, #eee); margin-bottom: 1.1rem; flex-wrap: wrap; }
.pc-tab {
  border: 0; background: transparent; padding: 0.6rem 0.85rem; font-size: 0.88rem; font-weight: 600;
  color: var(--text-secondary); cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px;
  display: inline-flex; align-items: center; gap: 0.4rem;
}
.pc-tab:hover { color: #1877f2; }
.pc-tab.is-active { color: #1877f2; border-bottom-color: #1877f2; }
.pc-tabpane { display: none; }
.pc-tabpane.is-active { display: block; }

.pc-char-count { font-size: 0.75rem; color: var(--text-muted); text-align: right; margin-top: 0.25rem; }

/* Upload dropzones */
.pc-dropzone { border: 1.5px dashed var(--baseline, #c3c2b7); border-radius: 10px; padding: 1.5rem; text-align: center; color: var(--text-muted); cursor: pointer; }
.pc-dropzone:hover { border-color: #1877f2; color: #1877f2; }
.pc-thumbs { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 0.75rem; }
.pc-thumbs img, .pc-thumbs video { width: 76px; height: 76px; object-fit: cover; border-radius: 8px; border: 1px solid var(--border, #eee); }

/* Facebook preview */
.pc-fb-preview { border: 1px solid var(--border, #eee); border-radius: 10px; overflow: hidden; background: var(--surface-1, #fff); }
.pc-fb-preview .pc-fb-head { display: flex; align-items: center; gap: 0.6rem; padding: 0.85rem 1rem 0.5rem; }
.pc-fb-preview .pc-fb-avatar { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; background: #d8dbe6; display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 700; }
.pc-fb-preview .pc-fb-name { font-weight: 700; font-size: 0.9rem; color: var(--text-primary); }
.pc-fb-preview .pc-fb-meta { font-size: 0.75rem; color: var(--text-muted); }
.pc-fb-preview .pc-fb-body { padding: 0.25rem 1rem 0.75rem; font-size: 0.9rem; color: var(--text-primary); white-space: pre-wrap; word-break: break-word; min-height: 1.2rem; }
.pc-fb-preview .pc-fb-media img, .pc-fb-preview .pc-fb-media video { width: 100%; display: block; max-height: 320px; object-fit: cover; }
.pc-fb-preview .pc-fb-link { border: 1px solid var(--gridline); border-top: 0; padding: 0.6rem 1rem; }
.pc-fb-preview .pc-fb-link .pc-fb-link-url { font-size: 0.72rem; color: var(--text-muted); text-transform: uppercase; }
.pc-fb-preview .pc-fb-actions { display: flex; justify-content: space-around; border-top: 1px solid var(--gridline, #eee); padding: 0.5rem 0; color: var(--text-secondary); font-size: 0.82rem; }
.pc-fb-preview .pc-fb-actions span { display: inline-flex; align-items: center; gap: 0.35rem; }

/* ================================================================
   Create Post dialog — the multimedia composer
   ================================================================ */
.pc-cp-page { max-width: 1120px; margin: 0 auto; }
.pc-cp-page.is-expanded { max-width: none; }

.pc-cp-dialog {
  background: var(--surface-1, #fff);
  border: 1px solid var(--border, rgba(11,11,11,0.10));
  border-radius: 14px;
  box-shadow: 0 10px 34px rgba(11,11,11,0.08);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* ---- Header ---- */
.pc-cp-head {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 0.85rem 1.15rem;
  border-bottom: 1px solid var(--gridline, #e1e0d9);
  flex-wrap: wrap;
}
.pc-cp-head-left { display: flex; align-items: center; gap: 0.85rem; }
.pc-cp-head-left h1 { font-size: 1.15rem; font-weight: 700; margin: 0; color: var(--text-primary, #0b0b0b); }
.pc-cp-head-right { display: flex; align-items: center; gap: 0.35rem; flex-wrap: wrap; }

.pc-cp-headbtn {
  border: 0; background: transparent; cursor: pointer;
  font-size: 0.85rem; font-weight: 500; color: var(--text-secondary, #52514e);
  padding: 0.4rem 0.65rem; border-radius: 8px;
  display: inline-flex; align-items: center; gap: 0.4rem;
}
.pc-cp-headbtn:hover { background: var(--page-plane, #f4f4f1); color: var(--text-primary, #0b0b0b); }
.pc-cp-headbtn i { font-size: 0.85rem; opacity: 0.8; }
.pc-cp-headbtn.is-preview {
  background: #e8f4ec; color: #2f7d5f; border: 1px solid #cfe7d8;
}
.pc-cp-headbtn.is-preview:hover { background: #dcefe3; color: #276a51; }
.pc-cp-headbtn.is-preview.is-off { background: transparent; color: var(--text-secondary, #52514e); border-color: transparent; }

.pc-cp-iconbtn {
  border: 0; background: transparent; cursor: pointer; text-decoration: none;
  width: 32px; height: 32px; border-radius: 8px; color: var(--text-muted, #898781);
  display: inline-flex; align-items: center; justify-content: center; font-size: 0.95rem;
}
.pc-cp-iconbtn:hover { background: var(--page-plane, #f4f4f1); color: var(--text-primary, #0b0b0b); }

/* ---- Popovers (emoji, +, #, schedule) ---- */
.pc-cp-pop-wrap { position: relative; }
.pc-cp-pop {
  position: absolute; z-index: 40; top: calc(100% + 0.4rem); left: 0;
  min-width: 250px; max-width: 340px; padding: 0.75rem;
  background: var(--surface-1, #fff); border: 1px solid var(--border, #e0e0e0);
  border-radius: 10px; box-shadow: 0 8px 24px rgba(11,11,11,0.14);
  display: none;
}
.pc-cp-pop.is-open { display: block; }
.pc-cp-pop.to-right { left: auto; right: 0; }
.pc-cp-pop.drop-up { top: auto; bottom: calc(100% + 0.4rem); }
.pc-cp-pop-title {
  font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.05em;
  color: var(--text-muted, #898781); margin-bottom: 0.5rem; font-weight: 600;
}
.pc-cp-pop-note { font-size: 0.75rem; color: var(--text-muted, #898781); margin-top: 0.55rem; }
.pc-cp-pop-scroll { max-height: 260px; overflow-y: auto; }

.pc-cp-menu { list-style: none; margin: 0; padding: 0; }
.pc-cp-menu button {
  width: 100%; text-align: left; border: 0; background: transparent; cursor: pointer;
  padding: 0.45rem 0.5rem; border-radius: 7px; font-size: 0.86rem; color: var(--text-primary, #0b0b0b);
  display: flex; align-items: center; gap: 0.55rem;
}
.pc-cp-menu button:hover { background: var(--page-plane, #f4f4f1); }
.pc-cp-menu button i { width: 16px; text-align: center; color: var(--text-muted, #898781); }
.pc-cp-menu button .pc-cp-menu-sub { display: block; font-size: 0.74rem; color: var(--text-muted, #898781); }
.pc-cp-menu button.is-selected { background: rgba(24,119,242,0.08); color: #1877f2; }
.pc-cp-menu button.is-selected i { color: #1877f2; }

/* Free-text entry inside a popover (hashtags) */
.pc-cp-taginput {
  width: 100%; border: 1px solid var(--border, #e0e0e0); border-radius: 7px;
  padding: 0.4rem 0.6rem; font-size: 0.84rem; outline: none;
  background: var(--surface-1, #fff); color: var(--text-primary, #0b0b0b);
}
.pc-cp-taginput:focus { border-color: #1877f2; }

/* Emoji grid */
.pc-cp-emoji { display: grid; grid-template-columns: repeat(8, 1fr); gap: 0.15rem; }
.pc-cp-emoji button {
  border: 0; background: transparent; cursor: pointer; font-size: 1.1rem;
  padding: 0.2rem; border-radius: 6px; line-height: 1.2;
}
.pc-cp-emoji button:hover { background: var(--page-plane, #f4f4f1); }

/* ---- Body split ---- */
.pc-cp-body { display: grid; grid-template-columns: minmax(0, 1fr) 340px; align-items: stretch; }
.pc-cp-body.is-preview-off { grid-template-columns: minmax(0, 1fr); }
.pc-cp-body.is-preview-off .pc-cp-side { display: none; }
@media (max-width: 900px) { .pc-cp-body { grid-template-columns: minmax(0, 1fr); } }

.pc-cp-main { padding: 1.15rem; min-width: 0; }

/* ---- Account avatar strip ---- */
.pc-cp-avatars { display: flex; align-items: center; gap: 0.6rem; flex-wrap: wrap; margin-bottom: 1.1rem; }
.pc-cp-avatar { position: relative; margin: 0; cursor: pointer; line-height: 1; }
.pc-cp-avatar input { position: absolute; opacity: 0; width: 0; height: 0; }
.pc-cp-avatar .pc-cp-avatar-face {
  width: 42px; height: 42px; border-radius: 11px; object-fit: cover; display: flex;
  align-items: center; justify-content: center; color: #fff; font-weight: 700; font-size: 1.05rem;
  transition: opacity .12s, box-shadow .12s;
  opacity: 0.5; filter: grayscale(0.35);
}
.pc-cp-avatar .pc-cp-avatar-badge {
  position: absolute; right: -3px; bottom: -3px;
  width: 17px; height: 17px; border-radius: 50%; background: #1877f2; color: #fff;
  display: flex; align-items: center; justify-content: center; font-size: 0.55rem;
  border: 2px solid var(--surface-1, #fff);
}
.pc-cp-avatar input:checked ~ .pc-cp-avatar-face {
  opacity: 1; filter: none; box-shadow: 0 0 0 2px var(--surface-1, #fff), 0 0 0 3.5px #1877f2;
}
.pc-cp-avatar input:focus-visible ~ .pc-cp-avatar-face { outline: 2px solid #1877f2; outline-offset: 3px; }

.pc-cp-addbtn {
  width: 42px; height: 42px; border-radius: 11px; text-decoration: none;
  border: 1px solid var(--border, #dcdad4); color: var(--text-muted, #898781);
  display: inline-flex; align-items: center; justify-content: center; font-size: 0.95rem;
  background: transparent;
}
.pc-cp-addbtn:hover { border-color: #1877f2; color: #1877f2; }

.pc-cp-campaign {
  border: 0; border-bottom: 1px dashed transparent; background: transparent; outline: none;
  font-size: 0.95rem; font-weight: 600; color: var(--text-primary, #0b0b0b);
  width: 100%; max-width: 420px; padding: 0.2rem 0; margin-bottom: 0.9rem;
}
.pc-cp-campaign::placeholder { color: var(--text-muted, #898781); font-weight: 500; }
.pc-cp-campaign:hover, .pc-cp-campaign:focus { border-bottom-color: var(--border, #dcdad4); }

/* ---- Editor card ---- */
.pc-cp-editor {
  border: 1px solid var(--border, #e6e4de); border-radius: 12px; padding: 0.9rem 1rem 0.6rem;
}
.pc-cp-formats { display: flex; align-items: center; gap: 1.1rem; flex-wrap: wrap; margin-bottom: 0.35rem; }
.pc-cp-netmark {
  width: 26px; height: 26px; border-radius: 7px; background: #1877f2; color: #fff;
  display: inline-flex; align-items: center; justify-content: center; font-size: 0.85rem; flex-shrink: 0;
}
.pc-cp-radio { display: inline-flex; align-items: center; gap: 0.45rem; margin: 0; cursor: pointer; font-size: 0.88rem; color: var(--text-primary, #0b0b0b); }
.pc-cp-radio input { position: absolute; opacity: 0; width: 0; height: 0; }
.pc-cp-radio .pc-cp-dot {
  width: 15px; height: 15px; border-radius: 50%; border: 1.5px solid var(--baseline, #c3c2b7);
  display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.pc-cp-radio input:checked ~ .pc-cp-dot { border-color: #0e8a3e; }
.pc-cp-radio input:checked ~ .pc-cp-dot::after { content: ''; width: 8px; height: 8px; border-radius: 50%; background: #0e8a3e; }
.pc-cp-radio input:focus-visible ~ .pc-cp-dot { outline: 2px solid #1877f2; outline-offset: 2px; }
.pc-cp-radio input:disabled ~ .pc-cp-dot { opacity: 0.4; }
.pc-cp-radio.is-disabled { color: var(--text-muted, #898781); cursor: not-allowed; }

.pc-cp-hint { font-size: 0.76rem; color: var(--text-muted, #898781); margin-bottom: 0.5rem; }
.pc-cp-warn {
  font-size: 0.78rem; color: #9a6700; background: rgba(250,178,25,0.12);
  border: 1px solid rgba(250,178,25,0.35); border-radius: 8px; padding: 0.4rem 0.6rem;
  margin-bottom: 0.6rem; display: none; align-items: center; gap: 0.4rem;
}
.pc-cp-warn.is-on { display: flex; }

.pc-cp-caption { position: relative; }
.pc-cp-caption textarea {
  width: 100%; border: 0; outline: none; resize: vertical; background: transparent;
  min-height: 96px; font-size: 0.92rem; line-height: 1.5; color: var(--text-primary, #0b0b0b);
  padding: 0.35rem 0;
}
.pc-cp-caption textarea::placeholder { color: var(--text-muted, #898781); }

.pc-cp-linkrow { display: none; margin-top: 0.5rem; }
.pc-cp-linkrow.is-on { display: flex; align-items: center; gap: 0.5rem; }
.pc-cp-linkrow input {
  flex: 1; min-width: 0; border: 1px solid var(--border, #e0e0e0); border-radius: 7px;
  padding: 0.4rem 0.6rem; font-size: 0.85rem; outline: none;
  background: var(--surface-1, #fff); color: var(--text-primary, #0b0b0b);
}
.pc-cp-linkrow input:focus { border-color: #1877f2; }

/* Dropzone + thumbs */
.pc-cp-drop {
  width: 155px; border: 1.5px dashed var(--baseline, #d3d1c9); border-radius: 10px;
  padding: 1.1rem 0.75rem; text-align: center; cursor: pointer; margin: 0.75rem 0 0.25rem;
  color: var(--text-secondary, #52514e); font-size: 0.8rem; line-height: 1.45;
  background: transparent; display: block;
}
.pc-cp-drop i { font-size: 1.15rem; color: var(--text-secondary, #52514e); display: block; margin-bottom: 0.55rem; }
.pc-cp-drop .pc-cp-filelink { color: #2f7d5f; font-weight: 600; display: block; }
.pc-cp-drop:hover { border-color: #2f7d5f; }
.pc-cp-drop.is-dragover { border-color: #1877f2; background: rgba(24,119,242,0.06); }

.pc-cp-thumbs { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0.6rem 0 0; }
.pc-cp-thumb { position: relative; width: 78px; height: 78px; border-radius: 9px; overflow: hidden; border: 1px solid var(--border, #e6e4de); }
.pc-cp-thumb img, .pc-cp-thumb video { width: 100%; height: 100%; object-fit: cover; display: block; }
.pc-cp-thumb button {
  position: absolute; top: 3px; right: 3px; width: 20px; height: 20px; border-radius: 50%;
  border: 0; background: rgba(11,11,11,0.65); color: #fff; cursor: pointer;
  display: flex; align-items: center; justify-content: center; font-size: 0.65rem; padding: 0;
}
.pc-cp-thumb .pc-cp-thumb-kind {
  position: absolute; left: 3px; bottom: 3px; background: rgba(11,11,11,0.65); color: #fff;
  border-radius: 4px; font-size: 0.6rem; padding: 0.05rem 0.25rem;
}

/* Toolbar */
.pc-cp-toolbar {
  display: flex; align-items: center; gap: 0.35rem;
  border-top: 1px solid var(--gridline, #eceae4); margin-top: 0.85rem; padding-top: 0.55rem;
}
.pc-cp-toolbtn {
  border: 0; background: transparent; cursor: pointer; color: var(--text-secondary, #52514e);
  width: 30px; height: 30px; border-radius: 7px; font-size: 0.95rem;
  display: inline-flex; align-items: center; justify-content: center; gap: 0.2rem;
}
.pc-cp-toolbtn.has-caret { width: auto; padding: 0 0.4rem; }
.pc-cp-toolbtn.has-caret .fa-chevron-down { font-size: 0.6rem; opacity: 0.7; }
.pc-cp-toolbtn:hover { background: var(--page-plane, #f4f4f1); color: #1877f2; }
.pc-cp-toolbtn.is-on { color: #1877f2; background: rgba(24,119,242,0.08); }
.pc-cp-toolbar .pc-cp-count { margin-left: auto; font-size: 0.74rem; color: var(--text-muted, #898781); font-variant-numeric: tabular-nums; }

/* First comment */
.pc-cp-fc {
  display: flex; align-items: center; gap: 1rem;
  border-top: 1px solid var(--gridline, #eceae4); margin-top: 0.55rem; padding: 0.7rem 0 0.15rem;
}
.pc-cp-fc > label {
  margin: 0; flex: 0 0 96px; font-size: 0.86rem; color: var(--text-secondary, #52514e);
}
.pc-cp-fc-field { position: relative; flex: 1; min-width: 0; }
.pc-cp-fc-field input {
  width: 100%; border: 1px solid var(--border, #dcdad4); border-radius: 8px;
  padding: 0.5rem 2.5rem 0.5rem 0.8rem; font-size: 0.88rem; outline: none;
  background: var(--surface-1, #fff); color: var(--text-primary, #0b0b0b);
}
.pc-cp-fc-field input::placeholder { color: var(--text-muted, #898781); }
.pc-cp-fc-field input:focus { border-color: #1877f2; }
.pc-cp-fc-action {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  width: 27px; height: 27px; border-radius: 50%; border: 0; cursor: pointer;
  background: #e8f4ec; color: #2f7d5f; font-size: 0.75rem;
  display: inline-flex; align-items: center; justify-content: center;
}
.pc-cp-fc-action:hover { background: #d7ecdf; color: #276a51; }
.pc-cp-fc-action:disabled { background: var(--gridline, #e9e8e4); color: var(--text-muted, #a8a6a0); cursor: not-allowed; }
.pc-cp-fc-note { font-size: 0.76rem; color: var(--text-muted, #898781); margin: 0.3rem 0 0 calc(96px + 1rem); }
.pc-cp-fc-note.is-warn { color: #9a6700; }

/* First comment in the preview */
.pc-cp-pv-comment { display: flex; gap: 0.45rem; margin-top: 0.7rem; align-items: flex-start; }
.pc-cp-pv-comment-face {
  width: 26px; height: 26px; border-radius: 50%; flex-shrink: 0; object-fit: cover;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 700; font-size: 0.7rem;
}
.pc-cp-pv-comment-bubble {
  background: var(--gridline, #e9e8e4); border-radius: 14px; padding: 0.4rem 0.7rem;
  font-size: 0.8rem; color: var(--text-primary, #0b0b0b); min-width: 0;
  overflow-wrap: anywhere; line-height: 1.4;
}
.pc-cp-pv-comment-bubble strong { display: block; font-size: 0.76rem; }

/* ---- Preview side ---- */
.pc-cp-side {
  background: var(--page-plane, #f4f4f1);
  border-left: 1px solid var(--gridline, #e1e0d9);
  padding: 1.15rem 1.1rem;
  min-width: 0;
}
@media (max-width: 900px) { .pc-cp-side { border-left: 0; border-top: 1px solid var(--gridline, #e1e0d9); } }
.pc-cp-side-head { display: flex; align-items: center; gap: 0.4rem; margin-bottom: 0.9rem; }
.pc-cp-side-head h2 { font-size: 0.98rem; font-weight: 600; margin: 0; color: var(--text-primary, #0b0b0b); }
.pc-cp-side-head i { color: var(--text-muted, #898781); font-size: 0.85rem; cursor: help; }

.pc-cp-pv-tabs { display: flex; gap: 0.4rem; margin-bottom: 0.8rem; flex-wrap: wrap; }
.pc-cp-pv-tabs button {
  border: 0; background: transparent; cursor: pointer; padding: 0; border-radius: 9px; line-height: 1;
}
.pc-cp-pv-tabs .pc-cp-pv-face {
  width: 30px; height: 30px; border-radius: 8px; object-fit: cover; display: flex;
  align-items: center; justify-content: center; color: #fff; font-weight: 700; font-size: 0.8rem;
  opacity: 0.45;
}
.pc-cp-pv-tabs button.is-active .pc-cp-pv-face { opacity: 1; box-shadow: 0 0 0 2px var(--page-plane, #f4f4f1), 0 0 0 3.5px #1877f2; }

/* Empty state */
.pc-cp-empty { text-align: center; padding: 2.5rem 0.5rem 1rem; position: relative; }
.pc-cp-empty-card {
  width: 152px; margin: 0 auto 1.6rem; padding: 0.85rem;
  background: var(--gridline, #e6e5df); border-radius: 8px;
}
.pc-cp-empty-line { height: 7px; border-radius: 4px; background: var(--baseline, #d3d1c9); margin-bottom: 0.4rem; }
.pc-cp-empty-line.is-short { width: 55%; }
.pc-cp-empty-line.is-dot { width: 22px; height: 22px; border-radius: 50%; float: left; margin-right: 0.5rem; }
.pc-cp-empty-block { height: 108px; border-radius: 6px; background: var(--baseline, #d9d7d0); margin-top: 0.7rem; clear: both; }
.pc-cp-empty p { font-size: 0.92rem; color: var(--text-secondary, #52514e); margin: 0; }
.pc-cp-empty .pc-cp-spark { position: absolute; color: var(--baseline, #d3d1c9); font-size: 0.8rem; }
.pc-cp-empty .pc-cp-spark.s1 { top: 1.2rem; right: 2.2rem; font-size: 1rem; }
.pc-cp-empty .pc-cp-spark.s2 { bottom: 2.6rem; left: 1.4rem; }
.pc-cp-empty .pc-cp-spark.s3 { bottom: 1.9rem; left: 2.6rem; font-size: 0.65rem; }

/* Vertical (reel/story) preview frame */
.pc-cp-vertical {
  position: relative; aspect-ratio: 9 / 16; max-height: 420px; margin: 0 auto;
  background: #111; border-radius: 12px; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
}
.pc-cp-vertical img, .pc-cp-vertical video { width: 100%; height: 100%; object-fit: cover; }
.pc-cp-vertical .pc-cp-vertical-empty { color: rgba(255,255,255,0.55); font-size: 0.82rem; text-align: center; padding: 1rem; }
.pc-cp-vertical .pc-cp-vertical-top {
  position: absolute; top: 0; left: 0; right: 0; padding: 0.6rem 0.7rem;
  display: flex; align-items: center; gap: 0.5rem; color: #fff; font-size: 0.8rem; font-weight: 600;
  background: linear-gradient(rgba(0,0,0,0.45), rgba(0,0,0,0));
}
.pc-cp-vertical .pc-cp-vertical-top .pc-cp-vf {
  width: 26px; height: 26px; border-radius: 50%; object-fit: cover; display: flex;
  align-items: center; justify-content: center; font-size: 0.7rem; flex-shrink: 0;
}
.pc-cp-vertical .pc-cp-vertical-cap {
  position: absolute; bottom: 0; left: 0; right: 0; padding: 1.5rem 0.7rem 0.7rem;
  color: #fff; font-size: 0.8rem; line-height: 1.4; white-space: pre-wrap; word-break: break-word;
  background: linear-gradient(rgba(0,0,0,0), rgba(0,0,0,0.7));
  max-height: 55%; overflow: hidden;
}
.pc-cp-pv-tagline { font-size: 0.75rem; color: var(--text-muted, #898781); margin-top: 0.7rem; text-align: center; }

/* ---- Footer ---- */
.pc-cp-foot {
  display: flex; align-items: center; justify-content: space-between; gap: 0.75rem;
  padding: 0.8rem 1.15rem; border-top: 1px solid var(--gridline, #e1e0d9);
  flex-wrap: wrap;
}
.pc-cp-foot-left, .pc-cp-foot-right { display: flex; align-items: center; gap: 0.7rem; flex-wrap: wrap; }
.pc-cp-check { display: inline-flex; align-items: center; gap: 0.45rem; margin: 0; font-size: 0.86rem; color: var(--text-primary, #0b0b0b); cursor: pointer; }
.pc-cp-check input { width: 15px; height: 15px; accent-color: #1877f2; margin: 0; }
.pc-cp-foot-sep { width: 1px; height: 20px; background: var(--gridline, #e1e0d9); }
.pc-cp-linkbtn {
  border: 0; background: transparent; cursor: pointer; font-size: 0.86rem;
  color: var(--text-secondary, #52514e); padding: 0.35rem 0.2rem; border-radius: 6px;
}
.pc-cp-linkbtn:hover { color: #1877f2; }
.pc-cp-linkbtn:disabled { color: var(--text-muted, #898781); cursor: not-allowed; }

.pc-cp-when {
  border: 1px solid var(--border, #dcdad4); background: transparent; cursor: pointer;
  font-size: 0.86rem; color: var(--text-primary, #0b0b0b); padding: 0.45rem 0.8rem; border-radius: 8px;
  display: inline-flex; align-items: center; gap: 0.5rem;
}
.pc-cp-when:hover { background: var(--page-plane, #f4f4f1); }
.pc-cp-when .fa-chevron-down { font-size: 0.65rem; opacity: 0.7; }

.pc-cp-submit {
  border: 0; border-radius: 8px; padding: 0.55rem 1.1rem; font-size: 0.88rem; font-weight: 600;
  background: #1877f2; color: #fff; cursor: pointer;
  display: inline-flex; align-items: center; gap: 0.45rem;
}
.pc-cp-submit:hover { background: #1466d4; }
.pc-cp-submit:disabled {
  background: var(--gridline, #e9e8e4); color: var(--text-muted, #a8a6a0); cursor: not-allowed;
}
.pc-cp-customtime {
  display: none; align-items: center; gap: 0.4rem;
}
.pc-cp-customtime.is-on { display: inline-flex; }
.pc-cp-customtime input {
  border: 1px solid var(--border, #dcdad4); border-radius: 8px; padding: 0.4rem 0.6rem;
  font-size: 0.84rem; background: var(--surface-1, #fff); color: var(--text-primary, #0b0b0b); outline: none;
}
.pc-cp-customtime input:focus { border-color: #1877f2; }

/* ---- CTA editor ---- */
.pc-cta-layout { display: grid; grid-template-columns: minmax(0, 1fr) 420px; gap: 1.25rem; align-items: start; }
@media (max-width: 980px) { .pc-cta-layout { grid-template-columns: 1fr; } }
.pc-pagebox { border: 1px solid var(--border, #e7e7e7); border-radius: 8px; padding: 0.25rem 0.6rem; max-height: 150px; overflow-y: auto; }
.pc-pagebox .pc-page-checklist { margin: 0; }

/* ---- Carousel slider cards ---- */
.pc-slide-card { border: 1px solid var(--border, #e7e7e7); border-radius: 10px; padding: 1rem 1.1rem; margin-bottom: 1rem; background: var(--page-plane, #f9f9f7); }

/* ---------- Post listing pages (one per post type) ---------- */
.pc-list-head { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 0.75rem 1rem; margin-bottom: 1.25rem; }
.pc-list-head-left { display: flex; align-items: center; gap: 0.75rem; flex-wrap: wrap; }
.pc-list-head-left h1 { font-size: 1.5rem; font-weight: 600; color: #1877f2; margin: 0; }
.pc-list-mark { color: #1877f2; font-size: 1.3rem; display: inline-flex; }
.pc-breadcrumb { font-size: 0.85rem; color: var(--text-muted, #898781); display: flex; align-items: center; gap: 0.4rem; }
.pc-breadcrumb a { color: #1877f2; text-decoration: none; }
.pc-breadcrumb a:hover { text-decoration: underline; }
.pc-breadcrumb .is-current { color: var(--text-secondary, #52514e); }

/* Filter bar */
.pc-list-filters { display: flex; align-items: flex-start; justify-content: space-between; flex-wrap: wrap; gap: 0.75rem; margin-bottom: 1rem; }
.pc-filter-group { display: flex; align-items: stretch; flex-wrap: wrap; gap: 0.5rem; }
.pc-filter-select, .pc-filter-input {
  border: 1px solid var(--border, #e0e0e0); border-radius: 6px; padding: 0.45rem 0.7rem;
  font-size: 0.86rem; background: var(--surface-1, #fff); color: var(--text-primary, #0b0b0b); outline: none; min-height: 38px;
}
.pc-filter-select { min-width: 140px; }
.pc-filter-input { min-width: 240px; }
.pc-filter-select:focus, .pc-filter-input:focus { border-color: #1877f2; box-shadow: 0 0 0 2px rgba(24,119,242,0.12); }
.pc-filter-submit {
  background: #1877f2; color: #fff; border: 0; border-radius: 6px; padding: 0.45rem 1.1rem;
  font-size: 0.86rem; font-weight: 600; display: inline-flex; align-items: center; gap: 0.4rem; cursor: pointer; min-height: 38px;
}
.pc-filter-submit:hover { background: #1466d4; }

.pc-filter-date { position: relative; }
.pc-btn-fb.is-active { background: #1466d4; }
.pc-date-panel {
  position: absolute; right: 0; top: calc(100% + 0.4rem); z-index: 20; display: flex; flex-wrap: wrap;
  align-items: flex-end; gap: 0.6rem; padding: 0.85rem; border-radius: 8px;
  background: var(--surface-1, #fff); border: 1px solid var(--border, #e0e0e0); box-shadow: 0 6px 20px rgba(0,0,0,0.12);
}
.pc-date-field { display: flex; flex-direction: column; gap: 0.2rem; }
.pc-date-field label { font-size: 0.72rem; color: var(--text-muted, #898781); margin: 0; }
.pc-date-field input {
  border: 1px solid var(--border, #e0e0e0); border-radius: 6px; padding: 0.35rem 0.5rem;
  font-size: 0.83rem; background: var(--surface-1, #fff); color: var(--text-primary, #0b0b0b);
}
.pc-date-actions { display: flex; align-items: center; gap: 0.4rem; }

/* Table */
.pc-list-table-wrap { overflow-x: auto; }
.pc-list-table { width: 100%; border-collapse: collapse; font-size: 0.86rem; }
.pc-list-table th {
  text-align: left; font-size: 0.8rem; font-weight: 600; color: #1877f2; white-space: nowrap;
  padding: 0.85rem 0.9rem; background: rgba(24,119,242,0.05); border-bottom: 1px solid var(--gridline, #e1e0d9);
}
.pc-list-table th + th, .pc-list-table td + td { border-left: 1px solid var(--gridline, #e1e0d9); }
.pc-list-table td { padding: 0.8rem 0.9rem; border-bottom: 1px solid var(--gridline, #e1e0d9); color: var(--text-primary, #0b0b0b); vertical-align: middle; }
.pc-list-table tbody tr:hover td { background: var(--page-plane, #f9f9f7); }
.pc-list-table .pc-col-num { color: var(--text-secondary, #52514e); font-variant-numeric: tabular-nums; width: 48px; }
.pc-list-table .pc-col-name { font-weight: 500; }
.pc-list-table .pc-col-type { white-space: nowrap; }
.pc-list-table .pc-col-type i { margin-right: 0.35rem; color: var(--text-secondary, #52514e); }
.pc-list-table .pc-col-sched { white-space: nowrap; font-variant-numeric: tabular-nums; }
.pc-list-table .pc-col-error { max-width: 220px; }
.pc-error-text { color: var(--status-critical, #d03b3b); font-size: 0.82rem; display: block; overflow: hidden; text-overflow: ellipsis; }

.pc-sort-link { color: #1877f2; text-decoration: none; display: inline-flex; align-items: center; gap: 0.5rem; }
.pc-sort-link:hover { color: #1466d4; text-decoration: none; }
.pc-sort-link i { font-size: 0.72rem; }
.pc-sort-link i.pc-sort-idle { opacity: 0.4; }

/* Performance per Post — the per-post table's thumbnail + rank + caption cell */
.pc-ins-postrow-rank { font-weight: 700; color: var(--text-secondary, #52514e); font-size: 0.8rem; flex-shrink: 0; }
.pc-ins-postrow-media { position: relative; width: 46px; height: 46px; border-radius: 6px; overflow: hidden; background: var(--page-plane, #f4f4f1); flex-shrink: 0; }
.pc-ins-postrow-media img, .pc-ins-postrow-media video { width: 100%; height: 100%; object-fit: cover; display: block; }
.pc-ins-postrow-media.is-empty { display: flex; align-items: center; justify-content: center; color: var(--text-muted, #898781); }
.pc-ins-postrow-play { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: #fff; font-size: 0.9rem; background: rgba(0,0,0,0.15); }
.pc-ins-postrow-caption { max-width: 420px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pc-ins-postrow-date { font-size: 0.76rem; color: var(--text-muted, #898781); margin-top: 0.1rem; }

.pc-publisher { color: #1877f2; text-decoration: none; }
.pc-publisher:hover { text-decoration: underline; }

.pc-row-actions { display: flex; align-items: center; gap: 0.35rem; }
.pc-action-btn {
  background: #1877f2; color: #fff; border: 0; border-radius: 6px; width: 34px; height: 32px;
  display: inline-flex; align-items: center; justify-content: center; font-size: 0.85rem; cursor: pointer;
}
.pc-action-btn:hover { background: #1466d4; }
.pc-action-btn.is-open { background: #0f4f9e; }
.pc-action-btn.is-danger { background: transparent; color: var(--status-critical, #d03b3b); border: 1px solid var(--border, #e0e0e0); }
.pc-action-btn.is-danger:hover { background: rgba(208,59,59,0.08); }

.pc-list-status { display: inline-flex; align-items: center; gap: 0.35rem; font-size: 0.83rem; font-weight: 500; white-space: nowrap; }
.pc-list-status.is-good { color: var(--success-text, #006300); }
.pc-list-status.is-info { color: #1c5cab; }
.pc-list-status.is-muted { color: var(--text-muted, #898781); }
.pc-list-status.is-bad { color: var(--status-critical, #d03b3b); }
.pc-not-scheduled { color: var(--text-muted, #898781); display: inline-flex; align-items: center; gap: 0.35rem; }

/* Row details drawer */
.pc-details-row td { background: var(--page-plane, #f9f9f7); }
.pc-details-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0.9rem; }
.pc-details-lbl { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.03em; color: var(--text-muted, #898781); }
.pc-details-val { font-size: 0.86rem; color: var(--text-primary, #0b0b0b); word-break: break-word; white-space: pre-wrap; margin-top: 0.15rem; }
.pc-details-media { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 0.9rem; }
.pc-details-media img, .pc-details-media video { width: 84px; height: 84px; object-fit: cover; border-radius: 8px; border: 1px solid var(--border, #eee); }

.pc-list-empty { text-align: center; padding: 3rem 1rem; color: var(--text-muted, #898781); }
.pc-list-empty i { font-size: 2rem; display: block; margin-bottom: 0.6rem; color: #1877f2; opacity: 0.5; }

/* Footer: page size + range + pagination */
.pc-list-foot { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-top: 1rem; flex-wrap: wrap; }
.pc-list-foot .pc-filter-select { min-width: 88px; }
.pc-list-count { font-size: 0.85rem; color: var(--text-secondary, #52514e); font-variant-numeric: tabular-nums; }
.pc-list-pager { display: flex; justify-content: flex-end; gap: 0.35rem; margin-top: 0.9rem; flex-wrap: wrap; }
.pc-page-btn {
  border: 1px solid var(--border, #e0e0e0); border-radius: 6px; padding: 0.4rem 0.85rem; font-size: 0.85rem;
  color: #1877f2; background: var(--surface-1, #fff); text-decoration: none; display: inline-flex; align-items: center;
}
.pc-page-btn:hover { background: rgba(24,119,242,0.08); color: #1877f2; text-decoration: none; }
.pc-page-btn.is-current { background: #1877f2; border-color: #1877f2; color: #fff; }
.pc-page-btn.is-disabled { color: var(--text-muted, #898781); pointer-events: none; opacity: 0.65; }

@media (max-width: 760px) {
  .pc-list-filters { flex-direction: column; align-items: stretch; }
  .pc-filter-input { min-width: 0; flex: 1; }
  .pc-date-panel { right: auto; left: 0; }
}

.pc-type-card .pc-type-links { display: flex; gap: 0.5rem; margin-top: 0.9rem; padding-top: 0.75rem; border-top: 1px solid var(--gridline, #e1e0d9); }
.pc-type-card .pc-type-links a {
  flex: 1; text-align: center; font-size: 0.82rem; font-weight: 600; color: #1877f2; text-decoration: none;
  padding: 0.4rem 0.5rem; border: 1px solid var(--border, #e0e0e0); border-radius: 6px;
}
.pc-type-card .pc-type-links a:hover { background: rgba(24,119,242,0.08); text-decoration: none; }
button.pc-btn-fb, button.pc-toggle-btn { cursor: pointer; }

/* ================================================================
   Sidebar "New" badge (used by the Insights nav item)
   ================================================================ */
.pc-nav-badge {
  background: #d6336c; color: #fff; font-size: 0.62rem; font-weight: 700;
  padding: 0.1rem 0.4rem; border-radius: 20px; margin-left: 0.35rem; text-transform: uppercase; letter-spacing: 0.03em;
}

/* ================================================================
   Insights
   ================================================================ */
.pc-ins-head { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 0.75rem; margin-bottom: 1rem; }
.pc-ins-head-left { display: flex; align-items: center; gap: 0.6rem; }
.pc-ins-head-left h1 { font-size: 1.5rem; font-weight: 600; margin: 0; color: var(--text-primary, #1a1a2e); }
.pc-ins-head-right { display: flex; align-items: center; gap: 0.5rem; }

.pc-ins-iconbtn {
  border: 1px solid var(--border, #e0e0e0); background: var(--surface-1, #fff); cursor: pointer;
  width: 34px; height: 34px; border-radius: 8px; color: var(--text-secondary, #52514e);
  display: inline-flex; align-items: center; justify-content: center; font-size: 0.9rem; text-decoration: none;
}
.pc-ins-iconbtn:hover { background: var(--page-plane, #f4f4f1); color: var(--text-secondary, #52514e); text-decoration: none; }
.pc-ins-iconbtn.is-disabled { opacity: 0.5; cursor: not-allowed; }
.pc-ins-iconbtn.is-disabled:hover { background: var(--surface-1, #fff); }

/* Generic small popover shared by the Channels filter and Export menu */
.pc-ins-pop-wrap { position: relative; }
.pc-ins-pop {
  position: absolute; z-index: 30; top: calc(100% + 0.4rem); right: 0;
  min-width: 220px; max-width: 300px; padding: 0.5rem;
  background: var(--surface-1, #fff); border: 1px solid var(--border, #e0e0e0);
  border-radius: 10px; box-shadow: 0 8px 24px rgba(11,11,11,0.14); display: none;
}
.pc-ins-pop.is-open { display: block; }
.pc-ins-menu { list-style: none; margin: 0; padding: 0; max-height: 260px; overflow-y: auto; }
.pc-ins-menu button, .pc-ins-menu a {
  width: 100%; text-align: left; border: 0; background: transparent; cursor: pointer; text-decoration: none;
  padding: 0.45rem 0.55rem; border-radius: 7px; font-size: 0.86rem; color: var(--text-primary, #0b0b0b);
  display: flex; align-items: center; gap: 0.55rem;
}
.pc-ins-menu button:hover, .pc-ins-menu a:hover { background: var(--page-plane, #f4f4f1); }
.pc-ins-menu button.is-selected { background: rgba(24,119,242,0.08); color: #1877f2; font-weight: 600; }
.pc-ins-avatar {
  width: 24px; height: 24px; border-radius: 50%; object-fit: cover; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center; color: #fff; font-weight: 700; font-size: 0.65rem;
}

.pc-btn-outline {
  background: var(--surface-1, #fff); border: 1px solid var(--border, #dee2e6); color: var(--text-primary, #212529);
  font-size: 0.82rem; font-weight: 600; padding: 0.45rem 0.9rem; border-radius: 6px;
  display: inline-flex; align-items: center; gap: 0.4rem; text-decoration: none; cursor: pointer;
}
.pc-btn-outline:hover { background: var(--page-plane, #f8f9fa); color: var(--text-primary, #212529); text-decoration: none; }
.pc-btn-outline.is-disabled { opacity: 0.5; cursor: not-allowed; }
.pc-btn-outline.is-disabled:hover { background: var(--surface-1, #fff); }

/* Weekly Takeaways — a dismissible/collapsible pair of data-driven nudge cards */
.pc-ins-takeaways { background: rgba(21,101,192,0.06); border: 1px solid rgba(21,101,192,0.15); border-radius: 10px; padding: 0.9rem 1.1rem 1.1rem; margin-bottom: 1.25rem; }
.pc-ins-takeaways-toggle {
  border: 0; background: transparent; cursor: pointer; padding: 0; margin-bottom: 0.75rem;
  font-size: 0.72rem; font-weight: 700; letter-spacing: 0.06em; color: var(--brand-accent-strong, #1565c0);
  display: inline-flex; align-items: center; gap: 0.4rem;
}
.pc-ins-takeaways-body { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1rem; }
.pc-ins-takeaways.is-collapsed .pc-ins-takeaways-body { display: none; }
.pc-ins-takeaways.is-collapsed .pc-ins-takeaways-toggle i { transform: rotate(180deg); }
.pc-ins-takeaway-card { background: var(--surface-1, #fff); border-radius: 8px; padding: 1rem 1.1rem; }
.pc-ins-takeaway-icon { color: var(--brand-accent-strong, #1565c0); font-size: 1rem; margin-bottom: 0.5rem; }
.pc-ins-takeaway-title { font-weight: 700; font-size: 0.92rem; color: var(--text-primary, #212529); margin-bottom: 0.4rem; }
.pc-ins-takeaway-card p { font-size: 0.83rem; color: var(--text-secondary, #495057); margin-bottom: 0.85rem; }
.pc-ins-takeaway-actions { display: flex; align-items: center; gap: 0.5rem; }

.pc-ins-section-title { font-size: 1.05rem; font-weight: 700; color: var(--text-primary, #212529); margin: 0 0 0.75rem; }

/* Date-range tabs + filters row */
.pc-ins-toolbar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 0.75rem; margin-bottom: 1.25rem; }
.pc-ins-range-tabs { display: inline-flex; align-items: center; gap: 0.25rem; background: var(--page-plane, #f4f4f1); border-radius: 9px; padding: 0.2rem; }
.pc-ins-tab {
  border: 0; background: transparent; cursor: pointer; text-decoration: none;
  font-size: 0.83rem; font-weight: 500; color: var(--text-secondary, #52514e);
  padding: 0.4rem 0.75rem; border-radius: 7px; display: inline-flex; align-items: center; gap: 0.35rem;
}
.pc-ins-tab:hover { color: var(--text-primary, #0b0b0b); }
.pc-ins-tab.is-active { background: var(--surface-1, #fff); color: var(--text-primary, #0b0b0b); font-weight: 700; box-shadow: 0 1px 2px rgba(11,11,11,0.08); }
.pc-ins-tab i { font-size: 0.7rem; color: #9a6700; }
.pc-ins-filters { display: flex; align-items: center; gap: 0.5rem; }
.pc-ins-filter-btn {
  border: 1px solid var(--border, #e0e0e0); background: var(--surface-1, #fff); cursor: pointer;
  font-size: 0.85rem; color: var(--text-primary, #0b0b0b); padding: 0.45rem 0.75rem; border-radius: 8px;
  display: inline-flex; align-items: center; gap: 0.45rem; text-decoration: none;
}
.pc-ins-filter-btn:hover { background: var(--page-plane, #f4f4f1); color: var(--text-primary, #0b0b0b); text-decoration: none; }
.pc-ins-filter-btn i.fa-chevron-down { font-size: 0.65rem; opacity: 0.7; }
.pc-ins-filter-btn.is-active-view { background: var(--page-plane, #f8f9fa); font-weight: 600; }
.pc-ins-filter-btn.is-disabled { opacity: 0.5; cursor: not-allowed; }
.pc-ins-filter-btn.is-disabled:hover { background: var(--surface-1, #fff); }

.pc-ins-custom-row { display: none; align-items: flex-end; gap: 0.6rem; margin-top: 0.6rem; flex-wrap: wrap; }
.pc-ins-custom-row.is-active { display: flex; }
.pc-ins-custom-field { display: flex; flex-direction: column; gap: 0.2rem; }
.pc-ins-custom-field label { font-size: 0.72rem; color: var(--text-muted, #898781); }
.pc-ins-custom-field input {
  border: 1px solid var(--border, #e0e0e0); border-radius: 7px; padding: 0.4rem 0.55rem;
  font-size: 0.83rem; background: var(--surface-1, #fff); color: var(--text-primary, #0b0b0b);
}

/* Summary */
.pc-ins-period { font-size: 0.8rem; color: var(--text-muted, #898781); margin-top: 0.1rem; }
.pc-ins-summary-grid { display: grid; grid-template-columns: repeat(5, 1fr); }
@media (max-width: 1100px) { .pc-ins-summary-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 640px) { .pc-ins-summary-grid { grid-template-columns: repeat(2, 1fr); } }
.pc-ins-stat {
  padding: 1rem 1.15rem; border-bottom: 1px solid var(--gridline, #eee);
  border-right: 1px solid var(--gridline, #eee);
}
.pc-ins-summary-grid .pc-ins-stat:nth-child(5n), .pc-ins-summary-grid .pc-ins-stat:last-child { border-right: 0; }
@media (max-width: 1100px) { .pc-ins-summary-grid .pc-ins-stat:nth-child(3n) { border-right: 0; } .pc-ins-summary-grid .pc-ins-stat:nth-child(5n) { border-right: 1px solid var(--gridline, #eee); } }
@media (max-width: 640px) { .pc-ins-summary-grid .pc-ins-stat:nth-child(2n) { border-right: 0; } }
.pc-ins-stat-label { font-size: 0.8rem; color: var(--text-secondary, #52514e); display: flex; align-items: center; gap: 0.3rem; }
.pc-ins-stat-label i { font-size: 0.72rem; color: var(--text-muted, #898781); cursor: help; }
.pc-ins-stat-value { font-size: 1.35rem; font-weight: 700; color: var(--text-primary, #1a1a2e); margin-top: 0.3rem; }

/* Top 5 posts */
.pc-ins-top5-row { display: flex; gap: 0.9rem; overflow-x: auto; padding-bottom: 0.25rem; }
.pc-ins-postcard {
  flex: 0 0 200px; border: 1px solid var(--border, #e6e4de); border-radius: 10px; overflow: hidden;
  display: flex; flex-direction: column;
}
.pc-ins-postcard-head {
  display: flex; align-items: center; justify-content: space-between; padding: 0.5rem 0.7rem;
  border-bottom: 1px solid var(--gridline, #eee); font-size: 0.8rem;
}
.pc-ins-postcard-rank { font-weight: 700; color: var(--text-primary, #1a1a2e); }
.pc-ins-postcard-metric { color: var(--text-secondary, #52514e); }
.pc-ins-postcard-body { padding: 0.6rem 0.7rem; flex: 1; display: flex; flex-direction: column; gap: 0.4rem; }
.pc-ins-postcard-meta { display: flex; align-items: center; gap: 0.4rem; font-size: 0.76rem; color: var(--text-muted, #898781); }
.pc-ins-postcard-caption {
  font-size: 0.82rem; color: var(--text-primary, #0b0b0b); line-height: 1.35;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.pc-ins-postcard-media { margin-top: auto; border-radius: 7px; overflow: hidden; background: var(--page-plane, #f4f4f1); height: 90px; }
.pc-ins-postcard-media img, .pc-ins-postcard-media video { width: 100%; height: 100%; object-fit: cover; display: block; }
.pc-ins-postcard-media.is-empty { display: flex; align-items: center; justify-content: center; color: var(--text-muted, #898781); font-size: 1.1rem; }
.pc-ins-postcard-foot {
  display: flex; align-items: center; justify-content: space-between; padding: 0.45rem 0.7rem;
  border-top: 1px solid var(--gridline, #eee); color: var(--text-muted, #898781); font-size: 0.85rem;
}

/* Segmented toggle (Reactions/Comments, Bar/Line/Growth, Bar/Stacked Bar) */
.pc-ins-seg { display: inline-flex; align-items: center; gap: 0.2rem; background: var(--page-plane, #f4f4f1); border-radius: 8px; padding: 0.15rem; }
.pc-ins-seg button {
  border: 0; background: transparent; cursor: pointer; font-size: 0.8rem; font-weight: 500;
  color: var(--text-secondary, #52514e); padding: 0.35rem 0.65rem; border-radius: 6px;
}
.pc-ins-seg button.is-active { background: #e8f4ec; color: #2f7d5f; font-weight: 700; }

/* Horizontal bar-with-axis chart (Followers / Posts) */
.pc-ins-hbar-chart { }
.pc-ins-hbar-row { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 0.9rem; }
.pc-ins-hbar-label {
  flex: 0 0 130px; font-size: 0.85rem; color: var(--text-primary, #0b0b0b);
  display: flex; align-items: center; gap: 0.35rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.pc-ins-hbar-label i { font-size: 0.68rem; color: var(--text-muted, #898781); flex-shrink: 0; }
.pc-ins-hbar-track { position: relative; flex: 1; height: 18px; background: transparent; }
.pc-ins-hbar-fill { position: absolute; top: 0; height: 100%; border-radius: 4px; min-width: 2px; }
.pc-ins-hbar-value { flex: 0 0 60px; text-align: right; font-size: 0.82rem; color: var(--text-secondary, #52514e); font-variant-numeric: tabular-nums; }
.pc-ins-hbar-axis { position: relative; height: 20px; margin-left: calc(130px + 0.75rem); border-top: 1px solid var(--gridline, #eee); }
.pc-ins-hbar-axis span { position: absolute; top: 5px; transform: translateX(-50%); font-size: 0.72rem; color: var(--text-muted, #898781); }
.pc-ins-hbar-axis span:first-child { transform: translateX(0); }
.pc-ins-axis-caption { text-align: center; font-size: 0.78rem; color: var(--text-muted, #898781); margin-top: 0.5rem; }

.pc-ins-chart-pane { display: none; }
.pc-ins-chart-pane.is-active { display: block; }

.pc-ins-legend-row { display: flex; flex-wrap: wrap; gap: 0.85rem; margin-bottom: 1rem; }
.pc-ins-legend-item { display: inline-flex; align-items: center; gap: 0.35rem; font-size: 0.78rem; color: var(--text-secondary, #52514e); }
.pc-ins-legend-swatch { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }

.pc-ins-empty { text-align: center; padding: 3rem 1.5rem; }
.pc-ins-empty i { font-size: 2rem; color: #1877f2; opacity: 0.5; display: block; margin-bottom: 0.75rem; }

/* ================================================================
   Auth pages — AdminLTE's "login-box" pattern, layered over the
   6 existing Blade views (login/register/forgot-reset/confirm/verify)
   without touching their markup — those already emit plain Bootstrap
   .card/.card-primary/.form-group/.custom-control, which this scopes.
   ================================================================ */
body.pc-auth-page {
  background: var(--page-plane, #f8f9fa);
  min-height: 100vh;
  display: flex; align-items: center;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
.pc-auth-page .pc-auth-wrap { width: 100%; padding: 2rem 1rem; }
.pc-auth-page .login-brand { text-align: center; margin-bottom: 1.25rem; }
.pc-auth-page .login-brand span { font-size: 1.6rem; font-weight: 700; color: var(--brand-accent-strong, #1565c0); }

.pc-auth-page .card {
  border: 1px solid var(--border, #dee2e6);
  border-radius: var(--card-radius, 8px);
  box-shadow: var(--bs-box-shadow, 0 0.5rem 1rem rgba(0,0,0,0.15));
  overflow: hidden;
}
.pc-auth-page .card.card-primary { border-top: 3px solid var(--brand-accent, #2a78d6); }
.pc-auth-page .card-header {
  background: var(--surface-1, #fff); border-bottom: 1px solid var(--gridline, #eee);
  padding: 1rem 1.25rem;
}
.pc-auth-page .card-header h4 { margin: 0; font-size: 1.05rem; font-weight: 700; color: var(--text-primary, #212529); }
.pc-auth-page .card-header h4 i { color: var(--brand-accent, #2a78d6); margin-right: 0.4rem; }
.pc-auth-page .card-body { padding: 1.5rem; background: var(--surface-1, #fff); }
.pc-auth-page .form-group label { font-size: 0.86rem; font-weight: 600; color: var(--text-secondary, #495057); }
.pc-auth-page .form-control {
  border-radius: 6px; border-color: var(--border, #dee2e6); padding: 0.5rem 0.75rem; font-size: 0.9rem;
}
.pc-auth-page .form-control:focus { border-color: var(--brand-accent, #2a78d6); box-shadow: 0 0 0 0.2rem rgba(42,120,214,0.2); }
.pc-auth-page .btn-primary {
  background: var(--brand-accent-strong, #1565c0); border-color: var(--brand-accent-strong, #1565c0);
  border-radius: 6px; font-weight: 600;
}
.pc-auth-page .btn-primary:hover { background: #0d47a1; border-color: #0d47a1; }
.pc-auth-page .text-small { font-size: 0.8rem; }
.pc-auth-page a { color: var(--brand-accent-strong, #1565c0); }

/* ================================================================
   Publish — a single chronological feed across every composer type,
   grouped by day. Reuses .pc-ins-head-left/.pc-ins-iconbtn/.pc-ins-pop*
   from Insights (identical header/popover chrome).
   ================================================================ */
.pc-pub-head-avatar-wrap { position: relative; flex-shrink: 0; display: inline-flex; }
.pc-pub-head-avatar {
  width: 36px; height: 36px; border-radius: 8px; object-fit: cover;
  display: inline-flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 700; font-size: 1rem;
}
.pc-pub-head-badge {
  position: absolute; bottom: -3px; right: -3px; color: #1877f2; background: #fff;
  border-radius: 50%; font-size: 0.85rem; box-shadow: 0 0 0 2px #fff;
}
.pc-pub-goal-link {
  border: 0; background: transparent; padding: 0; margin-top: 0.1rem;
  font-size: 0.78rem; color: var(--text-muted, #6c757d); display: inline-flex; align-items: center; gap: 0.3rem;
}
.pc-pub-goal-link.is-disabled { cursor: not-allowed; opacity: 0.8; }

.pc-pub-tabs-row {
  display: flex; align-items: center; justify-content: space-between; gap: 0.75rem;
  border-bottom: 1px solid var(--gridline, #eee); margin-bottom: 1rem; flex-wrap: wrap;
}
.pc-pub-tabs { display: flex; align-items: center; gap: 0.25rem; flex-wrap: wrap; }
.pc-pub-tabs-extra { display: flex; align-items: center; gap: 0.5rem; padding-bottom: 0.4rem; flex-shrink: 0; }
.pc-pub-tab {
  border: 0; background: transparent; cursor: pointer; text-decoration: none;
  padding: 0.6rem 0.9rem; font-size: 0.88rem; font-weight: 600; color: var(--text-secondary, #495057);
  border-bottom: 2px solid transparent; margin-bottom: -1px; display: inline-flex; align-items: center; gap: 0.4rem;
}
.pc-pub-tab:hover { color: var(--text-primary, #212529); text-decoration: none; }
.pc-pub-tab.is-active { color: var(--brand-accent-strong, #1565c0); border-bottom-color: var(--brand-accent-strong, #1565c0); }
.pc-pub-tab-count {
  background: var(--page-plane, #f8f9fa); color: var(--text-muted, #6c757d);
  font-size: 0.72rem; font-weight: 700; padding: 0.05rem 0.4rem; border-radius: 20px;
}
.pc-pub-tab.is-active .pc-pub-tab-count { background: rgba(21,101,192,0.12); color: var(--brand-accent-strong, #1565c0); }

.pc-pub-toolbar { display: flex; align-items: center; justify-content: flex-end; gap: 0.5rem; margin-bottom: 1.25rem; }

.pc-pub-daygroup { font-size: 0.9rem; font-weight: 700; color: var(--text-primary, #212529); margin: 1.5rem 0 0.75rem; }
.pc-pub-daygroup:first-child { margin-top: 0; }

.pc-pub-card {
  background: var(--surface-1, #fff); border: 1px solid var(--border, #eee);
  border-radius: var(--card-radius, 8px); box-shadow: var(--card-shadow, 0 0.125rem 0.25rem rgba(0,0,0,0.075));
  padding: 1rem 1.1rem; margin-bottom: 0.9rem;
}
.pc-pub-card-time { font-size: 0.78rem; color: var(--text-muted, #6c757d); margin-bottom: 0.5rem; display: flex; align-items: center; justify-content: space-between; }
.pc-pub-card-time-left { display: flex; align-items: center; gap: 0.6rem; }
.pc-pub-card-format { display: inline-flex; align-items: center; gap: 0.3rem; }
.pc-pub-comment-btn {
  border: 0; background: transparent; color: var(--text-muted, #6c757d); cursor: not-allowed;
  width: 26px; height: 26px; border-radius: 6px; font-size: 0.85rem; opacity: 0.6;
  display: inline-flex; align-items: center; justify-content: center;
}
.pc-pub-card-meta { display: flex; align-items: center; gap: 0.55rem; margin-bottom: 0.5rem; }
.pc-pub-card-meta .pc-ins-avatar { width: 28px; height: 28px; }
.pc-pub-card-meta strong { font-size: 0.88rem; color: var(--text-primary, #212529); }
.pc-pub-card-body { display: grid; grid-template-columns: minmax(0, 1fr) 130px; gap: 1rem; align-items: start; }
@media (max-width: 640px) { .pc-pub-card-body { grid-template-columns: 1fr; } }
.pc-pub-caption {
  font-size: 0.9rem; color: var(--text-primary, #212529); line-height: 1.5; white-space: pre-wrap; word-break: break-word;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.pc-pub-caption.is-expanded { -webkit-line-clamp: unset; }
.pc-pub-hashtag { color: #1877f2; font-weight: 500; }
.pc-pub-more-link { border: 0; background: transparent; color: var(--text-secondary, #495057); font-size: 0.85rem; font-weight: 600; cursor: pointer; padding: 0.2rem 0 0; }
.pc-pub-more-link:hover { color: var(--brand-accent-strong, #1565c0); }
.pc-pub-media { position: relative; border-radius: 6px; overflow: hidden; background: var(--page-plane, #f8f9fa); width: 130px; height: 100px; }
.pc-pub-media img, .pc-pub-media video { width: 100%; height: 100%; object-fit: cover; display: block; }
.pc-pub-media .pc-pub-play {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 1.4rem; background: rgba(0,0,0,0.15); text-shadow: 0 1px 3px rgba(0,0,0,0.4);
}
.pc-pub-media .pc-pub-media-count {
  position: absolute; right: 4px; bottom: 4px; background: rgba(0,0,0,0.65); color: #fff;
  font-size: 0.68rem; font-weight: 600; padding: 0.05rem 0.35rem; border-radius: 4px;
}

.pc-pub-stats { display: flex; flex-wrap: wrap; gap: 1.4rem; margin: 0.85rem 0 0.75rem; padding-top: 0.75rem; border-top: 1px solid var(--gridline, #eee); }
.pc-pub-stat { font-size: 0.78rem; color: var(--text-muted, #6c757d); }
.pc-pub-stat strong { display: block; font-size: 0.86rem; font-weight: 700; color: var(--text-primary, #212529); margin-top: 0.1rem; }

.pc-pub-foot { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; padding-top: 0.7rem; border-top: 1px solid var(--gridline, #eee); flex-wrap: wrap; }
.pc-pub-foot-via { font-size: 0.8rem; color: var(--text-muted, #6c757d); display: inline-flex; align-items: center; gap: 0.4rem; }
.pc-pub-foot-via i.fa-facebook { color: #1877f2; }
.pc-pub-foot-error { font-size: 0.8rem; color: var(--status-critical, #d03b3b); display: inline-flex; align-items: center; gap: 0.4rem; }
.pc-pub-foot-actions { display: flex; align-items: center; gap: 0.9rem; }
.pc-pub-foot-actions a.pc-pub-goto { font-size: 0.82rem; color: var(--brand-accent-strong, #1565c0); text-decoration: none; font-weight: 600; }
.pc-pub-foot-actions a.pc-pub-goto:hover { text-decoration: underline; }
.pc-pub-more-wrap { position: relative; }
.pc-pub-more-btn { border: 0; background: transparent; color: var(--text-muted, #6c757d); cursor: pointer; width: 28px; height: 28px; border-radius: 6px; }
.pc-pub-more-btn:hover { background: var(--page-plane, #f8f9fa); color: var(--text-primary, #212529); }
.pc-pub-more-btn.is-disabled { opacity: 0.5; cursor: not-allowed; }
.pc-pub-more-btn.is-disabled:hover { background: transparent; color: var(--text-muted, #6c757d); }
.pc-pub-more-menu {
  position: absolute; right: 0; bottom: calc(100% + 0.35rem); z-index: 20; min-width: 150px;
  background: var(--surface-1, #fff); border: 1px solid var(--border, #dee2e6); border-radius: 8px;
  box-shadow: 0 8px 24px rgba(11,11,11,0.14); padding: 0.35rem; display: none;
}
.pc-pub-more-menu.is-open { display: block; }
.pc-pub-more-menu button {
  width: 100%; text-align: left; border: 0; background: transparent; cursor: pointer;
  padding: 0.45rem 0.55rem; border-radius: 6px; font-size: 0.85rem; color: var(--status-critical, #d03b3b);
  display: flex; align-items: center; gap: 0.5rem;
}
.pc-pub-more-menu button:hover { background: rgba(208,59,59,0.08); }

.pc-pub-empty { text-align: center; padding: 3rem 1.5rem; }
.pc-pub-empty i { font-size: 2rem; color: #1877f2; opacity: 0.5; display: block; margin-bottom: 0.75rem; }

/* ================================================================
   Publish — Calendar view. A 7-day week grid; each hour row renders
   at a fixed 60px so an event's pixel offset from midnight equals
   its minute-of-day (1 minute == 1px) — no percentage math needed.
   ================================================================ */
.pc-cal-toolbar {
  display: flex; align-items: center; justify-content: space-between; gap: 0.75rem;
  flex-wrap: wrap; margin-bottom: 1rem; padding-bottom: 0.85rem; border-bottom: 1px solid var(--gridline, #eee);
}
.pc-cal-toolbar-left { display: flex; align-items: center; gap: 0.5rem; }
.pc-cal-toolbar-right { display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap; }
.pc-cal-range { font-size: 0.95rem; font-weight: 700; color: var(--text-primary, #212529); margin-left: 0.35rem; }

.pc-cal-wrap { border: 1px solid var(--gridline, #eee); border-radius: 8px; overflow: auto; max-height: 640px; position: relative; background: var(--surface-1, #fff); }
.pc-cal-headrow { display: flex; position: sticky; top: 0; z-index: 3; background: var(--surface-1, #fff); border-bottom: 1px solid var(--gridline, #eee); }
.pc-cal-corner { width: 56px; flex-shrink: 0; position: sticky; left: 0; z-index: 4; background: var(--surface-1, #fff); }
.pc-cal-headcell {
  flex: 1; min-width: 100px; text-align: center; padding: 0.6rem 0.4rem;
  font-size: 0.78rem; color: var(--text-muted, #6c757d); border-left: 1px solid var(--gridline, #f2f2f2);
}
.pc-cal-headcell strong { display: block; font-size: 0.95rem; color: var(--text-primary, #212529); margin-top: 0.1rem; }
.pc-cal-headcell.is-today, .pc-cal-headcell.is-today strong { color: var(--brand-accent-strong, #1565c0); }

.pc-cal-body { display: flex; position: relative; }
.pc-cal-gutter { width: 56px; flex-shrink: 0; position: sticky; left: 0; z-index: 2; background: var(--surface-1, #fff); border-right: 1px solid var(--gridline, #eee); }
.pc-cal-hour-row { height: 60px; box-sizing: border-box; border-top: 1px solid var(--gridline, #f2f2f2); position: relative; }
.pc-cal-gutter .pc-cal-hour-row span {
  position: absolute; top: -0.6em; right: 8px; font-size: 0.68rem; color: var(--text-muted, #6c757d);
  background: var(--surface-1, #fff); padding-left: 4px;
}
.pc-cal-col { flex: 1; min-width: 100px; position: relative; border-left: 1px solid var(--gridline, #f2f2f2); background: var(--page-plane, #fafafa); }
.pc-cal-col.is-today { background: rgba(21,101,192,0.04); }
.pc-cal-event {
  position: absolute; left: 3px; right: 3px; min-height: 34px; box-sizing: border-box;
  background: #eef2ff; border: 1px solid #c7d0ff; border-radius: 6px;
  padding: 0.2rem 0.4rem; text-align: left; font-size: 0.68rem; line-height: 1.3;
  color: var(--text-primary, #212529); cursor: pointer; overflow: hidden; text-decoration: none; display: block;
}
.pc-cal-event:hover { border-color: var(--brand-accent-strong, #1565c0); color: var(--text-primary, #212529); text-decoration: none; }
.pc-cal-event.is-sent { background: #eafaf0; border-color: #bfe8cf; }
.pc-cal-event.is-muted { cursor: default; }
.pc-cal-event-time { font-weight: 700; display: block; }
.pc-cal-event-caption { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; color: var(--text-muted, #6c757d); }
