/* SOUL AGENCY — Premium Dark Telegram Mini App CRM */

/* ── Design tokens ─────────────────────────────────────────────── */
:root {
  --bg: #0A0A0B;
  --card: #111214;
  --card-elevated: #17191D;
  --border: rgba(255, 255, 255, 0.06);
  --text: #FFFFFF;
  --text-secondary: #9CA3AF;
  --muted: #6B7280;
  --accent: #8B5CF6;
  --accent-soft: rgba(139, 92, 246, 0.14);
  --accent-glow: rgba(139, 92, 246, 0.35);
  --danger: #EF4444;
  --danger-soft: rgba(239, 68, 68, 0.12);
  --success: #22C55E;
  --success-soft: rgba(34, 197, 94, 0.12);
  --warning: #F59E0B;
  --card-hover: #1A1C21;
  --radius: 24px;
  --radius-sm: 14px;
  --radius-xs: 10px;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  --shadow-sm: 0 4px 16px rgba(0, 0, 0, 0.25);
  --nav-height: 72px;
  --header-height: auto;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-top: env(safe-area-inset-top, 0px);
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --transition: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.theme-premium,
html.theme-premium {
  --bg: #0A0A0B !important;
  --card: #111214 !important;
  --card-elevated: #17191D !important;
  --border: rgba(255, 255, 255, 0.06) !important;
  --text: #FFFFFF !important;
  --text-secondary: #9CA3AF !important;
  --muted: #6B7280 !important;
  --accent: #8B5CF6 !important;
  --card-hover: #1A1C21 !important;
}

html.theme-light {
  --bg: #F9FAFB;
  --card: #FFFFFF;
  --card-elevated: #FFFFFF;
  --border: #E5E7EB;
  --text: #111827;
  --text-secondary: #6B7280;
  --muted: #9CA3AF;
  --card-hover: #F3F4F6;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

/* ── Reset & base ──────────────────────────────────────────────── */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.5;
  color: var(--text);
  background: var(--bg);
  min-height: 100dvh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

#app {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  padding-top: var(--safe-top);
}

img,
video {
  max-width: 100%;
  display: block;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  border: none;
  background: none;
}

a {
  color: var(--accent);
  text-decoration: none;
}

.hidden {
  display: none !important;
}

/* ── Animations ────────────────────────────────────────────────── */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.animate-in {
  animation: fadeUp 0.45s cubic-bezier(0.22, 1, 0.36, 1) both;
}

/* ── Header ────────────────────────────────────────────────────── */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  padding: 16px 20px 14px;
  background: linear-gradient(180deg, var(--bg) 70%, transparent);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-mark {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--accent) 0%, #6D28D9 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px var(--accent-glow);
}

.brand-mark .ic {
  color: #fff;
  width: 20px;
  height: 20px;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.brand-line {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--text);
}

.brand-line-sub {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.28em;
  color: var(--text-secondary);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-btn {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--card);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  transition: background var(--transition), color var(--transition), transform var(--transition);
}

.header-btn:active {
  transform: scale(0.94);
}

.header-btn:hover {
  background: var(--card-hover);
  color: var(--text);
}

.header-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-soft), var(--card-elevated));
  border: 2px solid var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: -0.02em;
}

.header-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  flex-wrap: wrap;
}

.header-user-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}

.role-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-soft);
  border: 1px solid rgba(139, 92, 246, 0.25);
}

/* ── Content area ──────────────────────────────────────────────── */
.content {
  flex: 1;
  padding: 4px 16px calc(var(--nav-height) + var(--safe-bottom) + 24px);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* ── Cards ─────────────────────────────────────────────────────── */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
}

.card h2,
.card h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 12px;
  color: var(--text);
}

.card h3 {
  font-size: 14px;
}

.card[data-nav] {
  cursor: pointer;
  transition: background var(--transition), transform var(--transition);
}

.card[data-nav]:active {
  transform: scale(0.985);
}

.card[data-nav]:hover {
  background: var(--card-hover);
}

.alert-card {
  border-color: rgba(239, 68, 68, 0.3);
  background: linear-gradient(135deg, var(--card) 0%, rgba(239, 68, 68, 0.06) 100%);
  cursor: pointer;
}

.hub-header {
  background: linear-gradient(160deg, var(--card) 0%, var(--card-elevated) 100%);
}

/* KPI card — stat grid inside cards */
.kpi-card,
.card > .stat-grid:first-of-type {
  /* inherits stat-grid styles */
}

/* ── Stats / KPI grid ──────────────────────────────────────────── */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.stat {
  background: var(--card-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.stat-active {
  border-color: rgba(139, 92, 246, 0.45);
  box-shadow: 0 0 0 1px rgba(139, 92, 246, 0.15);
}

.stat-label {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 6px;
}

.stat-value {
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}

.stats-hero {
  font-size: 36px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 4px;
  font-variant-numeric: tabular-nums;
}

.stats-hero-sub {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

/* ── Finance hub — premium revenue dashboard ───────────────────── */
.finance-hub {
  padding: 24px 20px;
  background: linear-gradient(165deg, rgba(139, 92, 246, 0.06) 0%, var(--card) 42%, var(--card) 100%);
  border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  overflow: hidden;
  position: relative;
  transition: border-color 0.35s ease, box-shadow 0.35s ease;
}

.finance-hub::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 50% at 50% -20%, rgba(139, 92, 246, 0.12), transparent 60%);
  pointer-events: none;
}

.finance-hub:hover {
  border-color: rgba(139, 92, 246, 0.2);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35), 0 0 40px rgba(139, 92, 246, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.finance-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 20px;
  position: relative;
  z-index: 1;
}

.finance-top-left {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.finance-label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-secondary);
  opacity: 0.85;
}

.finance-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.01em;
}

.finance-trend {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  padding: 6px 10px;
  border-radius: 999px;
  white-space: nowrap;
  flex-shrink: 0;
}

.finance-trend-up {
  color: #10B981;
  background: rgba(16, 185, 129, 0.1);
}

.finance-trend-down {
  color: #EF4444;
  background: rgba(239, 68, 68, 0.1);
}

.finance-hero {
  position: relative;
  z-index: 1;
  margin-bottom: 8px;
}

.finance-hero-amount {
  font-size: clamp(36px, 10vw, 46px);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.05;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  margin-bottom: 6px;
}

.finance-hero-sub {
  font-size: 13px;
  color: #9CA3AF;
  font-weight: 500;
}

.finance-sparkline {
  position: relative;
  z-index: 1;
  height: 80px;
  margin: 12px 0 20px;
  opacity: 0.95;
}

.finance-sparkline-svg {
  display: block;
  width: 100%;
  height: 80px;
}

.finance-kpi-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  position: relative;
  z-index: 1;
}

.finance-kpi {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 18px;
  padding: 16px;
  transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease, transform 0.25s ease;
}

.finance-kpi:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(139, 92, 246, 0.15);
  box-shadow: 0 0 20px rgba(139, 92, 246, 0.08);
  transform: translateY(-1px);
}

.finance-kpi-label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.finance-kpi-value {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  margin-bottom: 6px;
  line-height: 1.2;
}

.finance-kpi-sub {
  font-size: 11px;
  color: #9CA3AF;
  font-weight: 500;
}

.finance-kpi .finance-trend {
  padding: 0;
  background: none;
  font-size: 12px;
}

.finance-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
  position: relative;
  z-index: 1;
}

.finance-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 999px;
  transition: background 0.25s ease, border-color 0.25s ease;
}

.finance-pill-click {
  cursor: pointer;
}

.finance-pill-click:hover {
  background: rgba(139, 92, 246, 0.1);
  border-color: rgba(139, 92, 246, 0.25);
}

.finance-pill-label {
  font-size: 11px;
  color: var(--text-secondary);
  font-weight: 500;
}

.finance-pill-value {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.finance-hint {
  margin: 14px 0 0;
  font-size: 12px;
  line-height: 1.45;
  color: #9CA3AF;
  text-align: center;
}

.finance-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 12px 0 0;
  font-size: 12px;
  color: var(--text-secondary);
}

.finance-footer .ic {
  opacity: 0.7;
}

/* ── Quick grid / menu grid ──────────────────────────────────────── */
.menu-grid,
.quick-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.menu-item {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 18px 14px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: background var(--transition), transform var(--transition), border-color var(--transition);
  position: relative;
}

.menu-item:active {
  transform: scale(0.96);
}

.menu-item:hover {
  background: var(--card-hover);
  border-color: rgba(139, 92, 246, 0.2);
}

.menu-item .icon {
  font-size: 22px;
  line-height: 1;
}

.menu-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--danger);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ── List rows ───────────────────────────────────────────────────── */
.list-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  transition: opacity var(--transition);
}

.list-row:last-child {
  border-bottom: none;
}

.list-row:active {
  opacity: 0.75;
}

.list-row-static {
  cursor: default;
}

.list-row-static:active {
  opacity: 1;
}

.list-row-head {
  cursor: default;
  padding-bottom: 8px;
}

.list-row-head:active {
  opacity: 1;
}

.row-main {
  flex: 1;
  min-width: 0;
}

.row-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.35;
}

.row-sub {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 3px;
  line-height: 1.4;
}

.row-value {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
}

.row-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.icon-action-group {
  display: flex;
  align-items: center;
  gap: 6px;
}

.icon-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-secondary);
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.25s ease, border-color 0.25s ease, color 0.25s ease, transform 0.2s ease, box-shadow 0.25s ease;
}

.icon-action .ic {
  width: 16px;
  height: 16px;
  stroke-width: 1.75;
}

.icon-action:hover {
  background: rgba(139, 92, 246, 0.12);
  border-color: rgba(139, 92, 246, 0.35);
  color: #c4b5fd;
  box-shadow: 0 0 16px rgba(139, 92, 246, 0.15);
}

.icon-action:active {
  transform: scale(0.94);
}

.icon-action-danger:hover {
  background: rgba(239, 68, 68, 0.12);
  border-color: rgba(239, 68, 68, 0.4);
  color: #fca5a5;
  box-shadow: 0 0 16px rgba(239, 68, 68, 0.12);
}

#revenue-list .list-row {
  padding: 14px 0;
  align-items: center;
  gap: 12px;
}

#revenue-list .row-value {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.02em;
  min-width: 72px;
  text-align: right;
}

.row-halves {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  font-size: 11px;
  color: var(--text-secondary);
  margin-top: 4px;
}

.row-halves b {
  color: var(--text);
  font-weight: 600;
}

/* ── Badges ──────────────────────────────────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 500;
  background: var(--card-elevated);
  border: 1px solid var(--border);
  color: var(--text-secondary);
}

.badge-red {
  background: var(--danger-soft);
  border-color: rgba(239, 68, 68, 0.3);
  color: var(--danger);
}

.badge-ref {
  background: var(--accent-soft);
  border-color: rgba(139, 92, 246, 0.25);
  color: var(--accent);
}

/* ── Trends ──────────────────────────────────────────────────────── */
.trend {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 11px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 999px;
}

.trend-up {
  color: var(--success);
  background: var(--success-soft);
}

.trend-down {
  color: var(--danger);
  background: var(--danger-soft);
}

.trend-neutral {
  color: var(--muted);
  background: rgba(107, 114, 128, 0.12);
}

/* ── Tabs & filters ──────────────────────────────────────────────── */
.tabs {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  margin-bottom: 4px;
}

.tabs::-webkit-scrollbar {
  display: none;
}

.tabs-wrap {
  flex-wrap: wrap;
  overflow: visible;
}

.tab {
  flex-shrink: 0;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  background: var(--card-elevated);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all var(--transition);
  white-space: nowrap;
}

.tab.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.tab-lg {
  padding: 10px 16px;
  font-size: 14px;
}

.filter-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin: 12px 0 8px;
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.filter-bar label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
}

.filter-scroll {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
  padding: 2px 0 10px;
  margin-bottom: 4px;
}

.filter-scroll::-webkit-scrollbar {
  display: none;
}

.filter-chip {
  flex-shrink: 0;
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  background: var(--card);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all var(--transition);
  white-space: nowrap;
}

.filter-chip.active {
  background: var(--accent-soft);
  border-color: rgba(139, 92, 246, 0.4);
  color: var(--accent);
}

/* ── Buttons ─────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 12px 18px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  border: 1px solid transparent;
  transition: background var(--transition), transform var(--transition), opacity var(--transition);
  white-space: nowrap;
}

.btn:active:not(:disabled) {
  transform: scale(0.97);
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent) 0%, #7C3AED 100%);
  color: #fff;
  box-shadow: 0 4px 14px var(--accent-glow);
}

.btn-primary:hover:not(:disabled) {
  filter: brightness(1.08);
}

.btn-secondary {
  background: var(--card-elevated);
  border-color: var(--border);
  color: var(--text);
}

.btn-secondary:hover:not(:disabled) {
  background: var(--card-hover);
}

.btn-danger {
  background: var(--danger-soft);
  border-color: rgba(239, 68, 68, 0.3);
  color: var(--danger);
}

.btn-danger:hover:not(:disabled) {
  background: rgba(239, 68, 68, 0.2);
}

.btn-sm {
  padding: 7px 12px;
  font-size: 12px;
  border-radius: var(--radius-xs);
}

.btn-block {
  display: flex;
  width: 100%;
}

.btn-icon {
  padding: 7px 10px;
  min-width: 36px;
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.btn-ref-video {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 14px;
  margin-bottom: 10px;
  border-radius: var(--radius-sm);
  background: var(--card-elevated);
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background var(--transition);
}

.btn-ref-video:hover {
  background: var(--card-hover);
}

/* ── Forms ───────────────────────────────────────────────────────── */
.form-group {
  margin-bottom: 14px;
}

.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.form-group input,
.form-group select,
.form-group textarea,
.search-input,
.hub-quick-status,
.filter-bar select {
  width: 100%;
  padding: 12px 14px;
  border-radius: var(--radius-xs);
  background: var(--card-elevated);
  border: 1px solid var(--border);
  color: var(--text);
  outline: none;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus,
.search-input:focus {
  border-color: rgba(139, 92, 246, 0.5);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.form-group textarea {
  min-height: 88px;
  resize: vertical;
}

.form-group input[type="file"] {
  padding: 10px;
  font-size: 13px;
}

.input-readonly {
  opacity: 0.7;
  cursor: not-allowed;
}

.key-box {
  background: var(--card-elevated);
  border: 1px dashed var(--border);
  border-radius: var(--radius-xs);
  padding: 12px 14px;
  font-family: ui-monospace, "Cascadia Code", monospace;
  font-size: 13px;
  word-break: break-all;
  margin: 12px 0;
  color: var(--text);
}

.info-box {
  background: var(--card-elevated);
  border-radius: var(--radius-xs);
  padding: 12px 14px;
  margin-bottom: 14px;
  font-size: 13px;
  line-height: 1.6;
}

.confirm-text {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.55;
}

.lang-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.lang-opt.active {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--accent);
}

/* ── Bottom navigation (glass) ─────────────────────────────────── */
.bottom-nav {
  position: fixed;
  bottom: calc(12px + var(--safe-bottom));
  left: 16px;
  right: 16px;
  z-index: 200;
  display: flex;
  align-items: stretch;
  justify-content: space-around;
  gap: 4px;
  padding: 8px 10px;
  border-radius: 20px;
  background: rgba(17, 18, 20, 0.72);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

html.theme-light .bottom-nav {
  background: rgba(255, 255, 255, 0.82);
  border-color: rgba(0, 0, 0, 0.08);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
}

.nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  padding: 6px 4px;
  border-radius: 14px;
  font-size: 10px;
  font-weight: 600;
  color: var(--muted);
  transition: color var(--transition), background var(--transition);
  position: relative;
  min-width: 0;
}

.nav-item.active {
  color: var(--accent);
  background: var(--accent-soft);
}

.nav-icon {
  font-size: 20px;
  line-height: 1;
}

.nav-badge {
  position: absolute;
  top: 2px;
  right: calc(50% - 22px);
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--danger);
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ── Modal ───────────────────────────────────────────────────────── */
.modal {
  position: fixed;
  inset: 0;
  z-index: 500;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 16px;
  padding-bottom: calc(16px + var(--safe-bottom));
}

.modal-body {
  width: 100%;
  max-width: 480px;
  max-height: 85dvh;
  overflow-y: auto;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 20px;
  box-shadow: var(--shadow);
  animation: fadeUp 0.3s ease both;
}

.modal-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--text);
}

.modal-actions {
  margin-top: 20px;
}

/* ── Toast ───────────────────────────────────────────────────────── */
.toast {
  position: fixed;
  bottom: calc(var(--nav-height) + var(--safe-bottom) + 20px);
  left: 50%;
  transform: translateX(-50%);
  z-index: 600;
  padding: 12px 20px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  color: #fff;
  background: var(--card-elevated);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  max-width: calc(100vw - 32px);
  text-align: center;
  animation: fadeUp 0.3s ease both;
}

.toast.ok {
  background: linear-gradient(135deg, #166534, #15803D);
  border-color: rgba(34, 197, 94, 0.3);
}

.toast.err {
  background: linear-gradient(135deg, #991B1B, #B91C1C);
  border-color: rgba(239, 68, 68, 0.3);
}

.bottom-nav.hidden ~ .toast,
#nav.hidden ~ #toast {
  bottom: calc(var(--safe-bottom) + 20px);
}

/* ── Loader & empty states ───────────────────────────────────────── */
.loader {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 48px 20px;
  color: var(--text-secondary);
  font-size: 14px;
}

.spinner {
  width: 32px;
  height: 32px;
  border: 3px solid var(--border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

.empty,
.error {
  padding: 32px 20px;
  text-align: center;
  color: var(--text-secondary);
  font-size: 14px;
}

.error {
  color: var(--danger);
}

.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 48px 24px;
  text-align: center;
  gap: 12px;
}

.empty-state-icon {
  font-size: 40px;
  color: var(--muted);
  opacity: 0.6;
}

.empty-state p {
  font-size: 14px;
  color: var(--text-secondary);
  max-width: 260px;
}

/* ── Back link ───────────────────────────────────────────────────── */
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 0 10px;
  font-size: 14px;
  font-weight: 500;
  color: var(--accent);
  cursor: pointer;
  background: none;
  border: none;
  transition: opacity var(--transition);
}

.back-link:active {
  opacity: 0.7;
}

/* ── Hub tasks (admin) ───────────────────────────────────────────── */
.hub-task-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.hub-task {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 14px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
}

.hub-task-main {
  flex: 1;
  min-width: 0;
  cursor: pointer;
}

.hub-task-icon {
  font-size: 22px;
  flex-shrink: 0;
  line-height: 1;
}

.hub-task-body {
  flex: 1;
  min-width: 0;
}

.hub-task-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
}

.hub-task-meta {
  font-size: 12px;
  color: var(--text-secondary);
}

.hub-task-desc {
  font-size: 12px;
  color: var(--muted);
  margin-top: 6px;
  line-height: 1.4;
}

.hub-task-actions {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.hub-quick-status {
  font-size: 12px;
  padding: 4px 8px;
  border-radius: 8px;
  max-width: 140px;
}

.hub-refs-edit {
  margin-top: 8px;
}

/* ── Model tasks ─────────────────────────────────────────────────── */
.model-tasks-header {
  padding: 4px 4px 8px;
}

.model-tasks-header h2 {
  font-size: 20px;
  font-weight: 700;
}

.model-tasks-sub {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 4px;
}

.model-task-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.model-task {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: background var(--transition), transform var(--transition);
}

.model-task:active {
  transform: scale(0.985);
}

.model-task:hover {
  background: var(--card-hover);
}

.model-task-active {
  border-color: rgba(139, 92, 246, 0.3);
}

.model-task-deadline-urgent {
  border-color: rgba(239, 68, 68, 0.55) !important;
  box-shadow: 0 0 24px rgba(239, 68, 68, 0.22), inset 0 0 0 1px rgba(239, 68, 68, 0.15);
  animation: deadline-glow 2.2s ease-in-out infinite;
}

@keyframes deadline-glow {
  0%, 100% { box-shadow: 0 0 16px rgba(239, 68, 68, 0.18); }
  50% { box-shadow: 0 0 28px rgba(239, 68, 68, 0.38); }
}

.hub-task-urgent {
  border-color: rgba(239, 68, 68, 0.5) !important;
  box-shadow: 0 0 20px rgba(239, 68, 68, 0.2);
  animation: deadline-glow 2.2s ease-in-out infinite;
}

.hub-task-deadline,
.model-task-deadline {
  margin-top: 8px;
}

.deadline-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text-secondary);
}

.deadline-badge-urgent {
  color: #fca5a5;
  background: rgba(239, 68, 68, 0.12);
  border-color: rgba(239, 68, 68, 0.45);
  box-shadow: 0 0 12px rgba(239, 68, 68, 0.2);
}

.model-detail-urgent {
  border-color: rgba(239, 68, 68, 0.45) !important;
  box-shadow: 0 0 28px rgba(239, 68, 68, 0.2);
}

.model-detail-deadline .deadline-badge {
  font-size: 13px;
}

.header-btn-notif {
  position: relative;
}

.notif-badge {
  position: absolute;
  top: 2px;
  right: 2px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: 999px;
  background: #ef4444;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  line-height: 16px;
  text-align: center;
}

.notif-panel {
  max-height: 50vh;
  overflow-y: auto;
}

.notif-row {
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
}

.notif-row-unread {
  background: rgba(139, 92, 246, 0.06);
  margin: 0 -12px;
  padding: 12px;
  border-radius: var(--radius-xs);
}

.notif-row-msg {
  font-size: 13px;
  color: var(--text);
  line-height: 1.4;
}

.notif-row-time {
  font-size: 11px;
  color: var(--text-secondary);
  margin-top: 4px;
}

.model-task-icon {
  font-size: 24px;
  flex-shrink: 0;
}

.model-task-body {
  flex: 1;
  min-width: 0;
}

.model-task-top {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 4px;
}

.model-task-type {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
}

.model-task-badge {
  display: inline-flex;
  align-items: center;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid transparent;
}

.model-task-badge-custom {
  color: #C4B5FD;
  background: rgba(139, 92, 246, 0.15);
  border-color: rgba(139, 92, 246, 0.35);
}

.model-task-badge-trends {
  color: #FDBA74;
  background: rgba(249, 115, 22, 0.12);
  border-color: rgba(249, 115, 22, 0.35);
}

.model-task-badge-wall {
  color: #93C5FD;
  background: rgba(59, 130, 246, 0.12);
  border-color: rgba(59, 130, 246, 0.35);
}

.model-task-badge-sexting {
  color: #F9A8D4;
  background: rgba(236, 72, 153, 0.12);
  border-color: rgba(236, 72, 153, 0.35);
}

.model-task-badge-content {
  color: var(--text-secondary);
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--border);
}

.model-task-icon-custom { color: #A78BFA; }
.model-task-icon-trends { color: #FB923C; }
.model-task-icon-wall { color: #60A5FA; }
.model-task-icon-sexting { color: #F472B6; }
.model-task-icon-content { color: var(--muted); }

.model-task-kind-custom { border-left: 3px solid rgba(139, 92, 246, 0.6); }
.model-task-kind-trends { border-left: 3px solid rgba(249, 115, 22, 0.6); }
.model-task-kind-wall { border-left: 3px solid rgba(59, 130, 246, 0.6); }
.model-task-kind-sexting { border-left: 3px solid rgba(236, 72, 153, 0.6); }

.model-task-done {
  opacity: 0.72;
}

.model-task-done-label {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.model-task-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 8px var(--accent-glow);
  animation: pulse 2s ease infinite;
}

.model-task-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 3px;
}

.model-task-desc {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 4px;
  line-height: 1.4;
}

.model-task-meta {
  font-size: 12px;
  color: var(--muted);
}

.model-task-arrow {
  font-size: 20px;
  color: var(--muted);
  flex-shrink: 0;
}

/* ── Model detail ────────────────────────────────────────────────── */
.model-detail {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 20px;
  box-shadow: var(--shadow);
}

.model-detail-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.model-detail-type {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
}

.model-detail-status {
  font-size: 11px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
}

.model-detail-title {
  font-size: 22px;
  font-weight: 700;
  line-height: 1.25;
  margin-bottom: 8px;
}

.model-detail-cat {
  font-size: 13px;
  color: var(--accent);
  margin-bottom: 12px;
}

.model-detail-desc {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.55;
  margin-bottom: 16px;
  white-space: pre-wrap;
}

.model-detail-price {
  font-size: 28px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
  font-variant-numeric: tabular-nums;
}

.model-detail-deadline {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

.model-detail-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 20px;
}

/* ── Reference gallery ───────────────────────────────────────────── */
.ref-section {
  margin-top: 16px;
}

.ref-section-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 10px;
}

.ref-gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 10px;
}

.ref-gallery-compact {
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
}

.ref-gallery-editable {
  margin-bottom: 8px;
}

.ref-editable-item {
  position: relative;
}

.ref-thumb {
  aspect-ratio: 1;
  border-radius: var(--radius-xs);
  overflow: hidden;
  background: var(--card-elevated);
  border: 1px solid var(--border);
  cursor: pointer;
  position: relative;
  transition: transform var(--transition);
}

.ref-thumb:active {
  transform: scale(0.96);
}

.ref-thumb img,
.ref-thumb video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ref-thumb-video {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--card-elevated), #1E1B2E);
}

.ref-play {
  font-size: 18px;
  color: #fff;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.ref-type-label {
  position: absolute;
  bottom: 4px;
  left: 4px;
  font-size: 9px;
  font-weight: 600;
  color: #fff;
  background: rgba(0, 0, 0, 0.55);
  padding: 2px 5px;
  border-radius: 4px;
}

.ref-loading {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--card-elevated);
}

.ref-loading-block {
  position: relative;
  padding: 24px;
  flex-direction: column;
  gap: 10px;
  font-size: 13px;
  color: var(--text-secondary);
  border-radius: var(--radius-xs);
  margin-bottom: 10px;
}

.ref-loading-block .spinner {
  width: 24px;
  height: 24px;
}

.ref-del-btn {
  position: absolute;
  top: -6px;
  right: -6px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--danger);
  color: #fff;
  font-size: 14px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--card);
  cursor: pointer;
  z-index: 2;
}

.ref-thumb-error {
  border-color: rgba(239, 68, 68, 0.4);
}

.ref-error {
  font-size: 12px;
  color: var(--danger);
}

.ref-players {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ref-player-wrap {
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--card-elevated);
  border: 1px solid var(--border);
}

.ref-player-label {
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border);
}

.ref-player,
.ref-player-img {
  width: 100%;
  max-height: 280px;
  object-fit: contain;
  background: #000;
}

/* ── Lightbox ────────────────────────────────────────────────────── */
.ref-lightbox {
  position: fixed;
  inset: 0;
  z-index: 700;
  background: rgba(0, 0, 0, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
}

.ref-lightbox-body {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  max-height: 100%;
  padding: 60px 48px;
}

.ref-lightbox-media {
  max-width: 100%;
  max-height: 80dvh;
  object-fit: contain;
  border-radius: 8px;
}

.ref-lightbox-close {
  position: absolute;
  top: calc(16px + var(--safe-top));
  right: 16px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
}

.ref-lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  font-size: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
}

.ref-lightbox-prev { left: 12px; }
.ref-lightbox-next { right: 12px; }

.ref-lightbox-counter {
  position: absolute;
  bottom: calc(20px + var(--safe-bottom));
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255, 255, 255, 0.7);
  font-size: 13px;
  font-weight: 500;
}

/* ── Calendar ────────────────────────────────────────────────────── */
.calendar {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.cal-day {
  aspect-ratio: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 500;
  border-radius: var(--radius-xs);
  background: var(--card-elevated);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: background var(--transition), border-color var(--transition);
  text-align: center;
  line-height: 1.2;
  padding: 2px;
}

.cal-day:hover:not(.past) {
  border-color: rgba(139, 92, 246, 0.35);
}

.cal-day.booked {
  background: var(--accent-soft);
  border-color: rgba(139, 92, 246, 0.35);
  color: var(--accent);
}

.cal-day.mine {
  background: rgba(34, 197, 94, 0.12);
  border-color: rgba(34, 197, 94, 0.35);
  color: var(--success);
}

.cal-day.past {
  opacity: 0.35;
  cursor: not-allowed;
}

.page-stack { display: flex; flex-direction: column; gap: 16px; }

.alert-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background: var(--danger-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--danger);
  flex-shrink: 0;
}

.nav-label { display: block; line-height: 1.2; }

.ic-muted { color: var(--muted); }

/* ── Icons (Lucide) ──────────────────────────────────────────────── */
.ic {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  vertical-align: middle;
}

.ic svg {
  width: 100%;
  height: 100%;
}

.ic-xs {
  width: 12px;
  height: 12px;
}

.ic-sm {
  width: 14px;
  height: 14px;
}

.ic-xl {
  width: 48px;
  height: 48px;
}

/* ── Responsive tweaks ───────────────────────────────────────────── */
@media (min-width: 480px) {
  .content {
    max-width: 520px;
    margin: 0 auto;
    width: 100%;
  }

  .bottom-nav {
    max-width: 488px;
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    width: calc(100% - 32px);
  }

  .stat-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .menu-grid,
  .quick-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.header-brand-block {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  flex: 1;
  min-width: 0;
}

.header-greeting-block {
  padding-left: 52px;
}

.header-greeting {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.02em;
  line-height: 1.3;
}

.header-growth {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 3px;
  font-weight: 500;
}

.header-growth.hidden {
  display: none;
}

.page-executive {
  gap: 16px;
}

/* ── Executive finance hub V2 ──────────────────────────────────── */
.finance-hub-executive {
  padding: 28px 22px 24px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25), 0 0 48px rgba(139, 92, 246, 0.15);
  border: 1px solid rgba(139, 92, 246, 0.12);
}

.finance-hub-executive::before {
  background: radial-gradient(ellipse 90% 60% at 50% -30%, rgba(139, 92, 246, 0.18), transparent 65%);
}

.finance-hero-executive .finance-hero-amount {
  font-size: clamp(42px, 11vw, 52px);
  font-weight: 700;
  letter-spacing: -0.03em;
}

.finance-trend-lg {
  font-size: 14px;
  padding: 8px 12px;
}

.exec-goal {
  position: relative;
  z-index: 1;
  margin: 16px 0 8px;
}

.exec-goal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.exec-goal-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-secondary);
}

.exec-goal-nums {
  font-size: 13px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--text-secondary);
}

.exec-goal-sep {
  opacity: 0.45;
  margin: 0 4px;
}

.exec-progress-track {
  height: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  overflow: hidden;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.25);
}

.exec-progress-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #7C3AED 0%, #A78BFA 50%, #C4B5FD 100%);
  box-shadow: 0 0 16px rgba(139, 92, 246, 0.45);
  transition: width 1.1s cubic-bezier(0.22, 1, 0.36, 1);
}

.exec-progress-pct {
  text-align: right;
  font-size: 12px;
  font-weight: 700;
  color: var(--accent);
  margin-top: 6px;
  font-variant-numeric: tabular-nums;
}

.finance-sparkline-premium {
  height: 88px;
  margin: 16px 0 22px;
  filter: drop-shadow(0 4px 12px rgba(139, 92, 246, 0.2));
}

.exec-kpi-grid .exec-kpi {
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
  cursor: default;
}

.exec-kpi-grid .exec-kpi:hover {
  transform: scale(1.02);
  border-color: rgba(139, 92, 246, 0.25);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.exec-kpi-grid .exec-kpi:active {
  transform: scale(0.98);
}

.exec-kpi-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 8px;
}

.exec-kpi-trend {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.exec-kpi-trend-up { color: #10B981; }
.exec-kpi-trend-down { color: #EF4444; }
.exec-kpi-trend-neutral { color: var(--muted); }

.exec-kpi-indicator {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}

.exec-kpi-indicator-up {
  background: #10B981;
  box-shadow: 0 0 8px rgba(16, 185, 129, 0.6);
}

.exec-kpi-indicator-down {
  background: #EF4444;
  box-shadow: 0 0 8px rgba(239, 68, 68, 0.5);
}

.exec-kpi-indicator-neutral {
  background: var(--muted);
}

/* ── Agency snapshot pills ─────────────────────────────────────── */
.dash-snapshot {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.dash-snapshot-pill {
  flex: 1 1 calc(33% - 8px);
  min-width: 100px;
  padding: 12px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: flex;
  flex-direction: column;
  gap: 2px;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.dash-snapshot-pill-click {
  cursor: pointer;
}

.dash-snapshot-pill-click:hover {
  transform: scale(1.02);
  border-color: rgba(139, 92, 246, 0.3);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
}

.dash-snapshot-pill-click:active {
  transform: scale(0.98);
}

.dash-snapshot-label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-secondary);
}

.dash-snapshot-value {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

/* ── Dashboard widgets ───────────────────────────────────────────── */
.dash-widgets-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

@media (min-width: 520px) {
  .dash-widgets-row {
    grid-template-columns: 1fr 1fr;
  }
}

.dash-widget {
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.dash-widget:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25), 0 0 32px rgba(139, 92, 246, 0.08);
}

.dash-widget-title {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-secondary);
  margin-bottom: 14px;
}

.dash-leader-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.dash-leader-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.dash-leader-left {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.dash-leader-rank {
  font-size: 14px;
  flex-shrink: 0;
}

.dash-leader-name {
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-leader-right {
  flex-shrink: 0;
  text-align: right;
  min-width: 72px;
}

.dash-leader-value {
  font-size: 13px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  display: block;
  margin-bottom: 4px;
}

.dash-leader-bar {
  height: 3px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  overflow: hidden;
}

.dash-leader-fill {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent), #C4B5FD);
  transition: width 0.9s cubic-bezier(0.22, 1, 0.36, 1);
}

/* ── Live activity ───────────────────────────────────────────────── */
.dash-activity-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.dash-activity-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.dash-activity-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-top: 5px;
  flex-shrink: 0;
}

.dash-activity-dot-green {
  background: #10B981;
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.55);
}

.dash-activity-body p {
  font-size: 13px;
  font-weight: 500;
  line-height: 1.4;
  color: var(--text);
}

.dash-activity-time {
  font-size: 11px;
  color: var(--muted);
  margin-top: 2px;
  display: block;
}

/* ── Management cards (models / chatters) ────────────────────────── */
.mgmt-page {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.mgmt-page-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 0 2px;
}

.mgmt-page-head h2 {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.mgmt-sort-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.mgmt-sort-btn {
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-secondary);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  transition: all 0.2s ease;
}

.mgmt-sort-btn.active,
.mgmt-sort-btn:hover {
  color: var(--accent);
  border-color: rgba(139, 92, 246, 0.35);
  background: var(--accent-soft);
}

.mgmt-leader-mode {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--accent-soft);
  border: 1px solid rgba(139, 92, 246, 0.25);
}

.mgmt-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.mgmt-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
  position: relative;
}

.mgmt-card[data-nav] {
  cursor: pointer;
}

.mgmt-card:hover {
  transform: scale(1.01);
  border-color: rgba(139, 92, 246, 0.2);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25), 0 0 24px rgba(139, 92, 246, 0.1);
}

.mgmt-card:active {
  transform: scale(0.99);
}

.mgmt-card-leader {
  border-color: rgba(139, 92, 246, 0.35);
  background: linear-gradient(165deg, rgba(139, 92, 246, 0.08) 0%, var(--card) 55%);
}

.mgmt-leader-badge {
  position: absolute;
  top: 12px;
  right: 14px;
  font-size: 18px;
}

.mgmt-card-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}

.mgmt-avatar {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--accent-soft), var(--card-elevated));
  border: 1px solid rgba(139, 92, 246, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  color: var(--accent);
  flex-shrink: 0;
}

.mgmt-avatar-chatter {
  border-radius: 50%;
}

.mgmt-card-title {
  flex: 1;
  min-width: 0;
}

.mgmt-card-title h3 {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 4px;
}

.mgmt-status {
  display: inline-flex;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 999px;
}

.mgmt-status-active {
  color: #10B981;
  background: rgba(16, 185, 129, 0.12);
}

.mgmt-status-idle {
  color: var(--muted);
  background: rgba(255, 255, 255, 0.05);
}

.mgmt-metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 12px;
}

.mgmt-metrics div {
  background: var(--card-elevated);
  border-radius: var(--radius-sm);
  padding: 10px;
  border: 1px solid var(--border);
}

.mgmt-metrics span {
  display: block;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

.mgmt-metrics b {
  font-size: 14px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.mgmt-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin-bottom: 14px;
}

.mgmt-meta-grid div span {
  display: block;
  font-size: 10px;
  color: var(--muted);
  margin-bottom: 2px;
}

.mgmt-meta-grid div b {
  font-size: 13px;
  font-weight: 600;
}

.mgmt-open-btn {
  width: 100%;
}

/* ── Kanban board ────────────────────────────────────────────────── */
.kanban-board {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 8px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}

.kanban-col {
  flex: 0 0 240px;
  scroll-snap-align: start;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  max-height: 70vh;
  display: flex;
  flex-direction: column;
}

.kanban-col-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border);
}

.kanban-count {
  background: var(--accent-soft);
  color: var(--accent);
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 10px;
}

.kanban-col-body {
  flex: 1;
  overflow-y: auto;
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 120px;
  transition: background 0.2s ease;
}

.kanban-col-body.kanban-drop-hover {
  background: rgba(139, 92, 246, 0.08);
}

.kanban-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
  cursor: grab;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.kanban-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.22);
}

.kanban-card.dragging {
  opacity: 0.55;
  transform: scale(0.98);
}

.kanban-card-title {
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 4px;
}

.kanban-card-sub {
  font-size: 11px;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.kanban-card-desc {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.35;
  margin-bottom: 8px;
}

.kanban-card-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.kanban-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  color: var(--muted);
  opacity: 0.5;
}

/* ── Premium empty states ────────────────────────────────────────── */
.empty-state {
  background: rgba(255, 255, 255, 0.02);
  border: 1px dashed rgba(255, 255, 255, 0.08);
  border-radius: var(--radius);
}

.empty-state-icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: var(--accent-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  color: var(--accent);
}

.empty-state-icon .ic-xl {
  width: 28px;
  height: 28px;
}

/* ── Enhanced bottom nav V2 ────────────────────────────────────────── */
.bottom-nav {
  bottom: calc(14px + var(--safe-bottom));
  padding: 10px 12px;
  border-radius: 22px;
  background: rgba(12, 13, 16, 0.78);
  backdrop-filter: blur(28px) saturate(200%);
  -webkit-backdrop-filter: blur(28px) saturate(200%);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45), 0 0 40px rgba(139, 92, 246, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.nav-item {
  transition: color 0.25s ease, background 0.25s ease, transform 0.2s ease;
  border-radius: 16px;
}

.nav-item:active {
  transform: scale(0.96);
}

.nav-item.active {
  background: linear-gradient(180deg, rgba(139, 92, 246, 0.22) 0%, rgba(139, 92, 246, 0.1) 100%);
  box-shadow: 0 0 20px rgba(139, 92, 246, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.quick-card {
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.quick-card:hover {
  transform: scale(1.02);
}

.quick-card:active {
  transform: scale(0.98);
}

.card {
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18);
}

.exec-goal-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.shift-card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
}

.shift-card-bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(145deg, rgba(139, 92, 246, 0.12) 0%, var(--card) 45%, var(--card) 100%);
  pointer-events: none;
}

.shift-card-active .shift-card-bg {
  background: linear-gradient(145deg, rgba(16, 185, 129, 0.14) 0%, rgba(139, 92, 246, 0.08) 40%, var(--card) 100%);
}

.shift-card-active {
  border-color: rgba(16, 185, 129, 0.35);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25), 0 0 40px rgba(16, 185, 129, 0.12);
}

.shift-card-content {
  position: relative;
  z-index: 1;
  padding: 22px 20px;
}

.shift-card-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.shift-status-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.shift-live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--muted);
}

.shift-live-dot-on {
  background: #10B981;
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.7);
  animation: pulse 1.5s ease-in-out infinite;
}

.shift-status-text {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
}

.shift-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.shift-timer-wrap {
  text-align: right;
}

.shift-timer-label {
  display: block;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

.shift-timer {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
  color: #10B981;
}

.shift-earned-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  margin-bottom: 16px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 13px;
  color: var(--text-secondary);
}

.shift-earned-row strong {
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.shift-toggle-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px 20px;
  border-radius: 16px;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.01em;
  transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.shift-toggle-btn:active {
  transform: scale(0.98);
}

.shift-toggle-btn:disabled {
  opacity: 0.6;
}

.shift-toggle-btn-start {
  background: linear-gradient(135deg, #7C3AED 0%, #8B5CF6 50%, #A78BFA 100%);
  color: #fff;
  box-shadow: 0 8px 28px rgba(139, 92, 246, 0.4);
}

.shift-toggle-btn-end {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.15) 0%, rgba(239, 68, 68, 0.08) 100%);
  color: #FCA5A5;
  border: 1px solid rgba(239, 68, 68, 0.35);
}

.shift-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 16px;
}

.shift-summary-grid div {
  background: var(--card-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px;
}

.shift-summary-grid span {
  display: block;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

.shift-summary-grid b {
  font-size: 15px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.shift-history-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.shift-history-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: var(--card-elevated);
  border: 1px solid var(--border);
}

.shift-history-row-active {
  border-color: rgba(16, 185, 129, 0.35);
  background: rgba(16, 185, 129, 0.06);
}

.shift-history-date {
  font-size: 14px;
  font-weight: 600;
}

.shift-history-sub {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 2px;
}

.shift-history-earned {
  font-size: 15px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
}

.mgmt-card-online {
  border-color: rgba(16, 185, 129, 0.3);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18), 0 0 24px rgba(16, 185, 129, 0.08);
}

.exec-goal-edit {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text-secondary);
  flex-shrink: 0;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.exec-goal-edit:hover {
  color: var(--accent);
  border-color: rgba(139, 92, 246, 0.35);
  background: var(--accent-soft);
}

.exec-goal-edit:active {
  transform: scale(0.94);
}

.exec-goal-target {
  font-variant-numeric: tabular-nums;
}

/* ── Chatter period income — fintech dashboard ─────────────────── */
.chatter-period-module {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
  max-width: 100%;
  overflow: hidden;
}

.cpm-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 0 2px;
}

.cpm-title {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  margin: 0;
}

.cpm-badge {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--text-secondary);
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  white-space: nowrap;
}

.cpm-segments {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  padding: 4px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(12px);
}

.cpm-segment {
  appearance: none;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 600;
  padding: 10px 8px;
  border-radius: 12px;
  cursor: pointer;
  transition: color 0.25s ease, background 0.25s ease, box-shadow 0.25s ease, transform 0.2s ease;
  font-variant-numeric: tabular-nums;
}

.cpm-segment:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
}

.cpm-segment.active {
  color: #fff;
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.35) 0%, rgba(109, 40, 217, 0.22) 100%);
  box-shadow:
    0 0 0 1px rgba(139, 92, 246, 0.45),
    0 0 24px rgba(139, 92, 246, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  animation: cpm-segment-pulse 2.8s ease-in-out infinite;
}

@keyframes cpm-segment-pulse {
  0%, 100% { box-shadow: 0 0 0 1px rgba(139, 92, 246, 0.45), 0 0 20px rgba(139, 92, 246, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.12); }
  50% { box-shadow: 0 0 0 1px rgba(139, 92, 246, 0.55), 0 0 32px rgba(139, 92, 246, 0.38), inset 0 1px 0 rgba(255, 255, 255, 0.14); }
}

.cpm-hero {
  position: relative;
  border-radius: 24px;
  padding: 24px 20px;
  overflow: hidden;
  background:
    linear-gradient(155deg, rgba(139, 92, 246, 0.14) 0%, rgba(20, 20, 22, 0.95) 38%, var(--card) 100%);
  border: 1px solid rgba(139, 92, 246, 0.18);
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.35),
    0 0 48px rgba(139, 92, 246, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.cpm-hero-orb {
  position: absolute;
  top: -40%;
  right: -15%;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(139, 92, 246, 0.35) 0%, transparent 68%);
  pointer-events: none;
  filter: blur(8px);
}

.cpm-hero-inner {
  position: relative;
  z-index: 1;
}

.cpm-hero-amount {
  font-size: clamp(36px, 9vw, 44px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.05;
  font-variant-numeric: tabular-nums;
  background: linear-gradient(180deg, #fff 0%, rgba(255, 255, 255, 0.82) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin-bottom: 6px;
}

.cpm-hero-sub {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 18px;
}

.cpm-metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.cpm-metric {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 10px 8px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.cpm-metric-label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-secondary);
  opacity: 0.85;
  line-height: 1.2;
}

.cpm-metric-value {
  font-size: 14px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--text);
}

.cpm-progress-block {
  padding: 0 2px;
}

.cpm-progress-labels {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 10px;
  font-size: 12px;
  color: var(--text-secondary);
  flex-wrap: wrap;
}

.cpm-progress-earned {
  font-weight: 600;
  color: var(--text);
}

.cpm-progress-total b {
  color: var(--text);
  font-weight: 700;
}

.cpm-progress-track {
  position: relative;
  height: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  overflow: visible;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.25);
}

.cpm-progress-fill {
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--cpm-progress, 0%);
  border-radius: 999px;
  background: linear-gradient(90deg, #6D28D9 0%, #8B5CF6 55%, #A78BFA 100%);
  box-shadow: 0 0 16px rgba(139, 92, 246, 0.55);
  transition: width 1.1s cubic-bezier(0.22, 1, 0.36, 1);
}

.cpm-progress-glow {
  position: absolute;
  top: 50%;
  left: var(--cpm-progress, 0%);
  width: 14px;
  height: 14px;
  margin: -7px 0 0 -7px;
  border-radius: 50%;
  background: #C4B5FD;
  box-shadow:
    0 0 12px rgba(167, 139, 250, 0.95),
    0 0 28px rgba(139, 92, 246, 0.65);
  transition: left 1.1s cubic-bezier(0.22, 1, 0.36, 1);
  pointer-events: none;
}

.cpm-distribution {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 4px 2px;
}

.cpm-dist-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.04);
  transition: border-color 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
}

.cpm-dist-row-active {
  border-color: rgba(139, 92, 246, 0.28);
  background: rgba(139, 92, 246, 0.05);
}

.cpm-dist-glow .cpm-dist-fill {
  background: linear-gradient(90deg, rgba(109, 40, 217, 0.85) 0%, #8B5CF6 100%);
  box-shadow: 0 0 14px rgba(139, 92, 246, 0.45);
}

.cpm-dist-empty .cpm-dist-fill {
  background: rgba(255, 255, 255, 0.08);
  box-shadow: none;
}

.cpm-dist-empty .cpm-dist-amount {
  color: var(--text-secondary);
}

.cpm-dist-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

.cpm-dist-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
}

.cpm-dist-row-active .cpm-dist-label {
  color: var(--text);
}

.cpm-dist-amount {
  font-size: 15px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--text);
}

.cpm-dist-track {
  position: relative;
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  overflow: visible;
}

.cpm-dist-fill {
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--cpm-fill, 0%);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  transition: width 1s cubic-bezier(0.22, 1, 0.36, 1);
}

.cpm-dist-endpoint {
  position: absolute;
  top: 50%;
  left: var(--cpm-fill, 0%);
  width: 8px;
  height: 8px;
  margin: -4px 0 0 -4px;
  border-radius: 50%;
  background: #A78BFA;
  box-shadow: 0 0 10px rgba(139, 92, 246, 0.7);
}

.cpm-summary {
  position: relative;
  border-radius: 24px;
  padding: 20px 18px;
  overflow: hidden;
  background:
    linear-gradient(165deg, rgba(255, 255, 255, 0.06) 0%, rgba(255, 255, 255, 0.02) 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(20px);
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.cpm-summary-glow {
  position: absolute;
  inset: -30% auto auto 50%;
  transform: translateX(-50%);
  width: 180px;
  height: 120px;
  background: radial-gradient(ellipse, rgba(139, 92, 246, 0.15) 0%, transparent 70%);
  pointer-events: none;
}

.cpm-summary-top {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.cpm-summary-label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-secondary);
}

.cpm-summary-amount {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  color: var(--text);
}

.cpm-sparkline {
  position: relative;
  z-index: 1;
  margin-bottom: 14px;
  min-height: 56px;
}

.cpm-chips {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.cpm-chip {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  padding: 10px 10px;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.06);
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.cpm-chip:hover {
  border-color: rgba(139, 92, 246, 0.25);
  box-shadow: 0 0 20px rgba(139, 92, 246, 0.1);
}

.cpm-chip-arrow {
  font-size: 11px;
  color: #10B981;
  font-weight: 700;
  line-height: 1;
}

.cpm-chip-label {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
}

.cpm-chip-value {
  font-size: 13px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--text);
}

.cpm-hint {
  font-size: 12px;
  line-height: 1.45;
  color: var(--text-secondary);
  padding: 0 4px 4px;
  margin: -4px 0 0;
}

/* ── Admin chatter profile — performance dashboard ───────────── */
.ach-page {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ach-profile-head {
  padding: 4px 2px 8px;
}

.ach-profile-name {
  margin: 0 0 12px;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
}

.ach-profile-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ach-profile-group label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-secondary);
}

.ach-group-select {
  width: 100%;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text);
  font-size: 14px;
}

.ach-dashboard {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ach-section {
  position: relative;
  border-radius: 20px;
  padding: 14px 14px 16px;
  background: linear-gradient(165deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.02) 100%);
  border: 1px solid rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(16px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.05);
  overflow: hidden;
}

.ach-section-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  font-size: 16px;
}

.ach-section-head h3 {
  margin: 0;
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
}

.ach-kpi-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.ach-kpi-grid-6 {
  grid-template-columns: repeat(3, 1fr);
}

.ach-kpi-card,
.ach-mini-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 11px 9px;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.06);
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
  min-height: 72px;
}

.ach-kpi-card:hover,
.ach-mini-card:hover {
  border-color: rgba(139, 92, 246, 0.3);
  box-shadow: 0 0 20px rgba(139, 92, 246, 0.12);
}

.ach-kpi-emoji,
.ach-mini-emoji {
  font-size: 14px;
}

.ach-kpi-value-wrap {
  display: flex;
  align-items: baseline;
  gap: 2px;
}

.ach-kpi-value,
.ach-mini-value {
  font-size: 17px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  color: var(--text);
  line-height: 1.1;
}

.ach-kpi-suffix,
.ach-mini-suffix {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-secondary);
}

.ach-kpi-label,
.ach-mini-label {
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-secondary);
  line-height: 1.25;
}

.ach-mini-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.ach-prod-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.ach-prod-item {
  padding: 12px 10px;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.05);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.ach-prod-emoji { font-size: 14px; }
.ach-prod-val { font-size: 16px; font-weight: 700; color: var(--text); font-variant-numeric: tabular-nums; }
.ach-prod-lbl { font-size: 9px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; color: var(--text-secondary); }

.ach-rank-body { display: flex; flex-direction: column; gap: 10px; }
.ach-rank-pos { display: flex; align-items: center; gap: 10px; }
.ach-rank-medal { font-size: 22px; }
.ach-rank-text { font-size: 15px; font-weight: 700; }
.ach-rank-gap { display: flex; justify-content: space-between; font-size: 12px; color: var(--text-secondary); }
.ach-rank-gap b { color: var(--accent); }
.ach-rank-track { position: relative; height: 6px; border-radius: 999px; background: rgba(255,255,255,0.06); }
.ach-rank-fill {
  position: absolute; inset: 0 auto 0 0; width: var(--ach-progress, 0%);
  border-radius: 999px;
  background: linear-gradient(90deg, #6D28D9, #8B5CF6, #A78BFA);
  box-shadow: 0 0 14px rgba(139, 92, 246, 0.5);
  transition: width 1.1s cubic-bezier(0.22, 1, 0.36, 1);
}
.ach-rank-glow {
  position: absolute; top: 50%; left: var(--ach-progress, 0%);
  width: 12px; height: 12px; margin: -6px 0 0 -6px; border-radius: 50%;
  background: #C4B5FD; box-shadow: 0 0 12px rgba(167, 139, 250, 0.9);
  transition: left 1.1s cubic-bezier(0.22, 1, 0.36, 1);
  pointer-events: none;
}
.ach-rank-leader { font-size: 13px; font-weight: 600; color: #10B981; }

.ach-streak-section { padding-bottom: 14px; }
.ach-streak-glow {
  position: absolute; top: -20px; right: -10px; width: 100px; height: 100px;
  background: radial-gradient(circle, rgba(251, 146, 60, 0.18) 0%, transparent 70%);
  pointer-events: none;
}
.ach-streak-flame { animation: ci-flame-pulse 2.4s ease-in-out infinite; }
.ach-streak-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.ach-streak-item {
  padding: 10px 12px; border-radius: 14px;
  background: rgba(0,0,0,0.2); border: 1px solid rgba(255,255,255,0.05);
}
.ach-streak-lbl {
  display: block; font-size: 10px; font-weight: 600; text-transform: uppercase;
  letter-spacing: 0.05em; color: var(--text-secondary); margin-bottom: 4px;
}
.ach-streak-item span { font-size: 14px; font-weight: 700; color: var(--text); }

.ach-ai-section { padding-bottom: 14px; }
.ach-ai-glow {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse 70% 60% at 20% 0%, rgba(139, 92, 246, 0.12), transparent 65%);
  pointer-events: none;
}
.ach-ai-text {
  position: relative; z-index: 1; margin: 0; font-size: 13px; line-height: 1.5;
  color: var(--text); font-weight: 500; transition: opacity 0.25s ease;
}
.ach-ai-dots { position: relative; z-index: 1; display: flex; gap: 6px; margin-top: 10px; justify-content: center; }
.ach-ai-dot {
  width: 6px; height: 6px; border-radius: 50%; background: rgba(255,255,255,0.2);
  transition: background 0.25s ease, box-shadow 0.25s ease;
}
.ach-ai-dot.active { background: var(--accent); box-shadow: 0 0 8px rgba(139, 92, 246, 0.6); }

.ach-model-list { display: flex; flex-direction: column; gap: 8px; }
.ach-model-card {
  padding: 12px 14px; border-radius: 16px;
  background: rgba(0,0,0,0.22); border: 1px solid rgba(255,255,255,0.06);
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}
.ach-model-assigned {
  border-color: rgba(139, 92, 246, 0.22);
  background: linear-gradient(165deg, rgba(139, 92, 246, 0.06) 0%, rgba(0,0,0,0.22) 100%);
}
.ach-model-card:hover { box-shadow: 0 0 20px rgba(139, 92, 246, 0.1); }
.ach-model-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 8px; }
.ach-model-name { font-size: 15px; font-weight: 700; color: var(--text); }
.ach-model-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.ach-model-stat { display: flex; flex-direction: column; gap: 2px; }
.ach-model-stat-wide { grid-column: 1 / -1; }
.ach-model-stat-val { font-size: 15px; font-weight: 700; color: var(--text); font-variant-numeric: tabular-nums; }
.ach-model-activity { font-size: 13px; font-weight: 600; color: var(--accent); }
.ach-model-stat-lbl { font-size: 10px; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.04em; }
.ach-model-available { margin-top: 8px; padding-top: 8px; border-top: 1px solid rgba(255,255,255,0.06); }
.ach-model-available-lbl { display: block; font-size: 10px; font-weight: 600; text-transform: uppercase; color: var(--text-secondary); margin-bottom: 8px; }

.ach-shift-summary {
  display: flex; flex-wrap: wrap; gap: 10px 16px; font-size: 12px;
  color: var(--text-secondary); margin-bottom: 12px;
}
.ach-shift-summary b { color: var(--text); }
.ach-shift-list { display: flex; flex-direction: column; gap: 8px; }
.ach-shift-card {
  padding: 12px 14px; border-radius: 14px;
  background: rgba(0,0,0,0.2); border: 1px solid rgba(255,255,255,0.05);
  transition: border-color 0.25s ease;
}
.ach-shift-card-active { border-color: rgba(16, 185, 129, 0.3); }
.ach-shift-date { font-size: 13px; font-weight: 700; margin-bottom: 6px; color: var(--text); }
.ach-shift-metrics {
  display: flex; flex-wrap: wrap; gap: 8px 14px; font-size: 12px;
  font-weight: 600; color: var(--text-secondary); margin-bottom: 6px;
}
.ach-shift-badge { font-size: 11px; font-weight: 600; }
.ach-shift-active { color: #10B981; }
.ach-shift-done { color: var(--text-secondary); }

.ach-custom-row {
  padding: 10px 0; border-bottom: 1px solid rgba(255,255,255,0.05);
}
.ach-custom-row:last-child { border-bottom: none; }
.ach-custom-title { font-size: 13px; font-weight: 600; color: var(--text); }
.ach-custom-sub { font-size: 11px; color: var(--text-secondary); margin-top: 2px; }

/* ── Chatter insights — achievements, stats, ranking ─────────── */
.chatter-insights-stack {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 100%;
  margin-top: 4px;
}

.ci-section {
  position: relative;
  border-radius: 20px;
  padding: 14px 14px 16px;
  background: linear-gradient(165deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.02) 100%);
  border: 1px solid rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(16px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.05);
  overflow: hidden;
}

.ci-section-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.ci-section-icon {
  font-size: 16px;
  line-height: 1;
}

.ci-section-title {
  margin: 0;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text);
}

.ci-ach-grid,
.ci-kpi-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.ci-kpi-grid-3 {
  grid-template-columns: repeat(3, 1fr);
}

.ci-ach-card,
.ci-kpi-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 12px 10px;
  border-radius: 16px;
  background: rgba(0, 0, 0, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.06);
  transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.2s ease;
  min-height: 78px;
}

.ci-ach-card:hover,
.ci-kpi-card:hover {
  border-color: rgba(139, 92, 246, 0.35);
  box-shadow: 0 0 24px rgba(139, 92, 246, 0.14);
  transform: translateY(-1px);
}

.ci-ach-emoji,
.ci-kpi-emoji {
  font-size: 15px;
  line-height: 1;
}

.ci-ach-value,
.ci-kpi-value {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  color: var(--text);
  line-height: 1.1;
}

.ci-ach-label,
.ci-kpi-label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--text-secondary);
  line-height: 1.25;
}

.ci-rank-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ci-rank-pos {
  display: flex;
  align-items: center;
  gap: 10px;
}

.ci-rank-medal {
  font-size: 22px;
  line-height: 1;
}

.ci-rank-text {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
}

.ci-rank-gap {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
  font-size: 12px;
}

.ci-rank-gap-label {
  color: var(--text-secondary);
}

.ci-rank-gap-value {
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--accent);
}

.ci-rank-progress-track {
  position: relative;
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  overflow: visible;
}

.ci-rank-progress-fill {
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--ci-progress, 0%);
  border-radius: 999px;
  background: linear-gradient(90deg, #6D28D9, #8B5CF6, #A78BFA);
  box-shadow: 0 0 14px rgba(139, 92, 246, 0.5);
  transition: width 1.1s cubic-bezier(0.22, 1, 0.36, 1);
}

.ci-rank-progress-glow {
  position: absolute;
  top: 50%;
  left: var(--ci-progress, 0%);
  width: 12px;
  height: 12px;
  margin: -6px 0 0 -6px;
  border-radius: 50%;
  background: #C4B5FD;
  box-shadow: 0 0 12px rgba(167, 139, 250, 0.9);
  transition: left 1.1s cubic-bezier(0.22, 1, 0.36, 1);
  pointer-events: none;
}

.ci-rank-leader {
  font-size: 13px;
  font-weight: 600;
  color: #10B981;
}

.ci-streak-section {
  padding-bottom: 14px;
}

.ci-streak-glow {
  position: absolute;
  top: -20px;
  right: -10px;
  width: 100px;
  height: 100px;
  background: radial-gradient(circle, rgba(251, 146, 60, 0.18) 0%, transparent 70%);
  pointer-events: none;
}

.ci-streak-flame {
  animation: ci-flame-pulse 2.4s ease-in-out infinite;
}

@keyframes ci-flame-pulse {
  0%, 100% { filter: drop-shadow(0 0 4px rgba(251, 146, 60, 0.4)); transform: scale(1); }
  50% { filter: drop-shadow(0 0 10px rgba(251, 146, 60, 0.75)); transform: scale(1.06); }
}

.ci-streak-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.ci-streak-item {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.ci-streak-label {
  display: block;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

.ci-streak-value {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.ci-ai-section {
  padding-bottom: 14px;
}

.ci-ai-glow {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 70% 60% at 20% 0%, rgba(139, 92, 246, 0.12), transparent 65%);
  pointer-events: none;
}

.ci-ai-text {
  position: relative;
  z-index: 1;
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--text);
  font-weight: 500;
  transition: opacity 0.25s ease;
}

.ci-ai-dots {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 6px;
  margin-top: 10px;
  justify-content: center;
}

.ci-ai-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  transition: background 0.25s ease, box-shadow 0.25s ease;
}

.ci-ai-dot.active {
  background: var(--accent);
  box-shadow: 0 0 8px rgba(139, 92, 246, 0.6);
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
