/* ============================================================
   VIBRA CREATOR STUDIO — CSS v1.0
   Creator analytics, monetization, scheduling, audience insights
   ============================================================ */

#vibra-creator-panel {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: #07050f;
  overflow-y: auto;
  font-family: var(--mono, 'DM Mono', monospace);
  -webkit-overflow-scrolling: touch;
}

#vibra-creator-panel.active {
  display: flex;
  flex-direction: column;
}

/* ── Header ── */
.vc-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(7,5,15,0.97);
  border-bottom: 1px solid rgba(138,87,255,0.2);
  padding: 1rem 1rem 0;
  backdrop-filter: blur(10px);
}

.vc-header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.75rem;
}

.vc-back {
  background: none;
  border: none;
  color: rgba(200,180,255,0.7);
  font-size: 1.3rem;
  cursor: pointer;
  padding: 0.25rem;
  line-height: 1;
}

.vc-title-wrap {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.vc-title {
  font-family: var(--sans, 'Syne', sans-serif);
  font-size: 1.05rem;
  font-weight: 800;
  color: #fff;
}

.vc-badge {
  background: linear-gradient(135deg, #8a57ff, #ff6b9d);
  color: #fff;
  font-size: 0.52rem;
  font-weight: 700;
  padding: 0.2rem 0.45rem;
  border-radius: 99px;
  letter-spacing: 0.08em;
}

.vc-level-chip {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  background: rgba(138,87,255,0.15);
  border: 1px solid rgba(138,87,255,0.3);
  border-radius: 99px;
  padding: 0.25rem 0.65rem;
  font-size: 0.6rem;
  color: #b088ff;
  letter-spacing: 0.06em;
}

.vc-level-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #b088ff;
  animation: vcp-pulse 2s ease-in-out infinite;
}

/* ── Tabs ── */
.vc-tabs {
  display: flex;
  gap: 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.vc-tabs::-webkit-scrollbar { display: none; }

.vc-tab {
  flex-shrink: 0;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  color: rgba(200,180,255,0.5);
  font-family: var(--mono, 'DM Mono', monospace);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  padding: 0.65rem 0.9rem;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.vc-tab.active {
  color: #b088ff;
  border-bottom-color: #8a57ff;
}

/* ── Body ── */
.vc-body {
  flex: 1;
  padding: 1rem;
}

.vc-tab-pane { display: none; }
.vc-tab-pane.active { display: block; }

/* ── Hero Stats Row ── */
.vc-hero-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.6rem;
  margin-bottom: 1rem;
}

.vc-hero-stat {
  background: rgba(138,87,255,0.08);
  border: 1px solid rgba(138,87,255,0.18);
  border-radius: 12px;
  padding: 0.85rem;
  text-align: center;
}

.vc-hero-stat.gold {
  background: rgba(255,196,0,0.08);
  border-color: rgba(255,196,0,0.25);
}

.vc-hero-stat.teal {
  background: rgba(0,212,255,0.07);
  border-color: rgba(0,212,255,0.2);
}

.vc-hero-stat.pink {
  background: rgba(255,107,157,0.08);
  border-color: rgba(255,107,157,0.2);
}

.vchs-val {
  font-family: var(--sans, 'Syne', sans-serif);
  font-size: 1.6rem;
  font-weight: 800;
  color: #fff;
  line-height: 1;
  margin-bottom: 0.25rem;
}

.vc-hero-stat.gold .vchs-val { color: #ffc400; }
.vc-hero-stat.teal .vchs-val { color: #00d4ff; }
.vc-hero-stat.pink .vchs-val { color: #ff6b9d; }

.vchs-label {
  font-size: 0.57rem;
  color: rgba(200,180,255,0.55);
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.vchs-trend {
  font-size: 0.58rem;
  margin-top: 0.2rem;
}

.vchs-trend.up { color: #00e676; }
.vchs-trend.down { color: #ff5252; }

/* ── Section Label ── */
.vc-section-label {
  font-size: 0.58rem;
  color: rgba(200,180,255,0.5);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 0.6rem;
  margin-top: 1.1rem;
}

/* ── Post Performance List ── */
.vc-post-list {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.vc-post-card {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 10px;
  padding: 0.75rem;
  cursor: pointer;
  transition: background 0.2s;
}

.vc-post-card:hover {
  background: rgba(138,87,255,0.08);
}

.vcp-top {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  margin-bottom: 0.5rem;
}

.vcp-dept-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 0.2rem;
}

.vcp-text {
  font-size: 0.72rem;
  color: rgba(240,235,255,0.85);
  line-height: 1.45;
  flex: 1;
}

.vcp-time {
  font-size: 0.55rem;
  color: rgba(200,180,255,0.4);
  flex-shrink: 0;
}

.vcp-metrics {
  display: flex;
  gap: 0.75rem;
}

.vcp-metric {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.58rem;
  color: rgba(200,180,255,0.6);
}

.vcp-metric span:first-child {
  font-size: 0.75rem;
}

.vcp-score-bar {
  height: 3px;
  background: rgba(138,87,255,0.15);
  border-radius: 99px;
  margin-top: 0.5rem;
  overflow: hidden;
}

.vcp-score-fill {
  height: 100%;
  background: linear-gradient(90deg, #8a57ff, #b088ff);
  border-radius: 99px;
  transition: width 0.8s ease;
}

/* ── Zone Heatmap ── */
.vc-zone-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.5rem;
}

.vc-zone-bar-item {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 8px;
  padding: 0.6rem 0.7rem;
}

.vcz-name {
  font-size: 0.62rem;
  color: rgba(240,235,255,0.8);
  margin-bottom: 0.35rem;
}

.vcz-bar-wrap {
  height: 4px;
  background: rgba(138,87,255,0.12);
  border-radius: 99px;
  overflow: hidden;
  margin-bottom: 0.25rem;
}

.vcz-bar {
  height: 100%;
  background: linear-gradient(90deg, #8a57ff, #ff6b9d);
  border-radius: 99px;
  transition: width 1s ease;
}

.vcz-pct {
  font-size: 0.55rem;
  color: rgba(200,180,255,0.5);
}

/* ── Audience Rings ── */
.vc-audience-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.6rem;
  margin-bottom: 1rem;
}

.vc-aud-ring-wrap {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 10px;
  padding: 0.75rem 0.5rem;
  text-align: center;
}

.vc-ring-svg {
  width: 56px;
  height: 56px;
  margin: 0 auto 0.4rem;
  display: block;
}

.vc-ring-track {
  fill: none;
  stroke: rgba(138,87,255,0.12);
  stroke-width: 5;
}

.vc-ring-fill {
  fill: none;
  stroke-width: 5;
  stroke-linecap: round;
  transform: rotate(-90deg);
  transform-origin: center;
  transition: stroke-dashoffset 1.2s ease;
}

.vc-ring-label {
  font-size: 0.56rem;
  color: rgba(200,180,255,0.55);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.vc-ring-val {
  font-family: var(--sans, 'Syne', sans-serif);
  font-size: 0.85rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 0.1rem;
}

/* ── Tribe Breakdown ── */
.vc-tribe-list {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.vc-tribe-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 8px;
  padding: 0.55rem 0.7rem;
}

.vct-icon {
  font-size: 1.1rem;
  flex-shrink: 0;
}

.vct-info {
  flex: 1;
}

.vct-name {
  font-size: 0.65rem;
  color: rgba(240,235,255,0.85);
  margin-bottom: 0.15rem;
}

.vct-bar-wrap {
  height: 3px;
  background: rgba(138,87,255,0.12);
  border-radius: 99px;
  overflow: hidden;
}

.vct-bar {
  height: 100%;
  border-radius: 99px;
  transition: width 1s ease;
}

.vct-pct {
  font-size: 0.6rem;
  color: rgba(200,180,255,0.55);
  flex-shrink: 0;
}

/* ── Hourly Activity Chart ── */
.vc-hourly-chart {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 60px;
  padding: 0 0.5rem;
  margin-bottom: 0.4rem;
}

.vc-hour-bar {
  flex: 1;
  background: rgba(138,87,255,0.25);
  border-radius: 3px 3px 0 0;
  min-height: 4px;
  transition: all 0.5s ease;
  cursor: pointer;
  position: relative;
}

.vc-hour-bar.peak {
  background: linear-gradient(180deg, #ff6b9d, #8a57ff);
}

.vc-hour-bar:hover::after {
  content: attr(data-hour);
  position: absolute;
  bottom: calc(100% + 4px);
  left: 50%;
  transform: translateX(-50%);
  background: rgba(9,6,18,0.95);
  color: #b088ff;
  font-size: 0.5rem;
  padding: 0.15rem 0.3rem;
  border-radius: 4px;
  white-space: nowrap;
  pointer-events: none;
}

.vc-hour-labels {
  display: flex;
  justify-content: space-between;
  padding: 0 0.5rem;
  font-size: 0.5rem;
  color: rgba(200,180,255,0.35);
  letter-spacing: 0.04em;
  margin-bottom: 0.75rem;
}

/* ── Scheduler ── */
.vc-scheduler-form {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(138,87,255,0.18);
  border-radius: 12px;
  padding: 1rem;
  margin-bottom: 1rem;
}

.vc-sched-label {
  font-size: 0.58rem;
  color: rgba(200,180,255,0.55);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 0.4rem;
}

.vc-sched-textarea {
  width: 100%;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(138,87,255,0.2);
  border-radius: 8px;
  color: rgba(240,235,255,0.9);
  font-family: var(--mono, 'DM Mono', monospace);
  font-size: 0.72rem;
  padding: 0.65rem;
  resize: none;
  min-height: 80px;
  box-sizing: border-box;
  margin-bottom: 0.75rem;
  outline: none;
}

.vc-sched-textarea:focus {
  border-color: rgba(138,87,255,0.5);
}

.vc-sched-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.6rem;
  margin-bottom: 0.75rem;
}

.vc-sched-select {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(138,87,255,0.2);
  border-radius: 8px;
  color: rgba(240,235,255,0.8);
  font-family: var(--mono, 'DM Mono', monospace);
  font-size: 0.65rem;
  padding: 0.55rem 0.6rem;
  outline: none;
  width: 100%;
}

.vc-sched-time {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(138,87,255,0.2);
  border-radius: 8px;
  color: rgba(240,235,255,0.8);
  font-family: var(--mono, 'DM Mono', monospace);
  font-size: 0.65rem;
  padding: 0.55rem 0.6rem;
  outline: none;
  width: 100%;
  box-sizing: border-box;
}

.vc-sched-btn {
  width: 100%;
  background: linear-gradient(135deg, #8a57ff, #b088ff);
  border: none;
  border-radius: 8px;
  color: #fff;
  font-family: var(--mono, 'DM Mono', monospace);
  font-size: 0.65rem;
  font-weight: 600;
  padding: 0.7rem;
  cursor: pointer;
  letter-spacing: 0.06em;
  transition: opacity 0.2s;
}

.vc-sched-btn:hover { opacity: 0.85; }

.vc-sched-optimal {
  background: rgba(0,230,118,0.08);
  border: 1px solid rgba(0,230,118,0.2);
  border-radius: 8px;
  padding: 0.6rem 0.75rem;
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.6rem;
  color: #00e676;
}

/* ── Scheduled Queue ── */
.vc-queue-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.vc-queue-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 8px;
  padding: 0.65rem 0.75rem;
}

.vcq-time-col {
  text-align: center;
  flex-shrink: 0;
  width: 42px;
}

.vcq-time {
  font-size: 0.65rem;
  color: #b088ff;
  font-weight: 600;
}

.vcq-date {
  font-size: 0.52rem;
  color: rgba(200,180,255,0.4);
}

.vcq-text {
  flex: 1;
  font-size: 0.65rem;
  color: rgba(240,235,255,0.75);
  line-height: 1.4;
}

.vcq-status {
  font-size: 0.55rem;
  padding: 0.2rem 0.4rem;
  border-radius: 99px;
  flex-shrink: 0;
}

.vcq-status.scheduled {
  background: rgba(138,87,255,0.15);
  color: #b088ff;
}

.vcq-status.published {
  background: rgba(0,230,118,0.12);
  color: #00e676;
}

.vcq-del {
  background: none;
  border: none;
  color: rgba(255,82,82,0.6);
  cursor: pointer;
  font-size: 0.85rem;
  padding: 0.1rem;
  line-height: 1;
  flex-shrink: 0;
}

/* ── Monetization ── */
.vc-money-hero {
  background: linear-gradient(135deg, rgba(255,196,0,0.1), rgba(255,107,157,0.08));
  border: 1px solid rgba(255,196,0,0.25);
  border-radius: 14px;
  padding: 1.2rem;
  text-align: center;
  margin-bottom: 1rem;
}

.vc-money-label {
  font-size: 0.58rem;
  color: rgba(255,196,0,0.7);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.vc-money-amount {
  font-family: var(--sans, 'Syne', sans-serif);
  font-size: 2.8rem;
  font-weight: 900;
  color: #ffc400;
  line-height: 1;
  margin-bottom: 0.3rem;
}

.vc-money-sub {
  font-size: 0.6rem;
  color: rgba(255,196,0,0.5);
}

.vc-money-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.6rem;
  margin-bottom: 1rem;
}

.vc-money-btn {
  background: rgba(255,196,0,0.1);
  border: 1px solid rgba(255,196,0,0.25);
  border-radius: 10px;
  color: #ffc400;
  font-family: var(--mono, 'DM Mono', monospace);
  font-size: 0.6rem;
  font-weight: 600;
  padding: 0.75rem 0.5rem;
  cursor: pointer;
  letter-spacing: 0.06em;
  text-align: center;
  transition: background 0.2s;
}

.vc-money-btn:hover { background: rgba(255,196,0,0.18); }

.vc-money-btn.primary {
  background: linear-gradient(135deg, #ffc400, #ff9500);
  color: #07050f;
  border: none;
}

/* ── Earnings History ── */
.vc-earnings-list {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.vc-earning-item {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.6rem 0.75rem;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 8px;
}

.vce-icon {
  font-size: 1rem;
  flex-shrink: 0;
}

.vce-info {
  flex: 1;
}

.vce-desc {
  font-size: 0.62rem;
  color: rgba(240,235,255,0.8);
  margin-bottom: 0.1rem;
}

.vce-time {
  font-size: 0.53rem;
  color: rgba(200,180,255,0.4);
}

.vce-amount {
  font-family: var(--sans, 'Syne', sans-serif);
  font-size: 0.85rem;
  font-weight: 700;
  flex-shrink: 0;
}

.vce-amount.positive { color: #ffc400; }
.vce-amount.negative { color: rgba(200,180,255,0.4); }

/* ── NERHIA Tips ── */
.vc-tips-list {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.vc-tip-card {
  display: flex;
  gap: 0.65rem;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 10px;
  padding: 0.75rem;
}

.vct-priority {
  width: 4px;
  border-radius: 99px;
  flex-shrink: 0;
}

.vct-priority.high { background: #ff6b9d; }
.vct-priority.medium { background: #ffc400; }
.vct-priority.low { background: #8a57ff; }

.vct-content { flex: 1; }

.vct-tag {
  display: inline-block;
  font-size: 0.5rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.15rem 0.35rem;
  border-radius: 99px;
  margin-bottom: 0.35rem;
}

.vct-tag.high {
  background: rgba(255,107,157,0.15);
  color: #ff6b9d;
}

.vct-tag.medium {
  background: rgba(255,196,0,0.12);
  color: #ffc400;
}

.vct-tag.low {
  background: rgba(138,87,255,0.15);
  color: #b088ff;
}

.vct-tip-text {
  font-size: 0.67rem;
  color: rgba(240,235,255,0.8);
  line-height: 1.5;
  margin-bottom: 0.4rem;
}

.vct-action-btn {
  background: none;
  border: 1px solid rgba(138,87,255,0.3);
  border-radius: 6px;
  color: #b088ff;
  font-family: var(--mono, 'DM Mono', monospace);
  font-size: 0.55rem;
  padding: 0.25rem 0.5rem;
  cursor: pointer;
  letter-spacing: 0.06em;
  transition: all 0.2s;
}

.vct-action-btn:hover {
  background: rgba(138,87,255,0.12);
}

/* ── Animations ── */
@keyframes vcp-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

@keyframes vcp-slide-in {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

.vc-tab-pane.active {
  animation: vcp-slide-in 0.25s ease;
}

/* ── Empty State ── */
.vc-empty {
  text-align: center;
  padding: 2rem 1rem;
  color: rgba(200,180,255,0.4);
  font-size: 0.65rem;
  line-height: 1.6;
}

.vc-empty-icon {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
}

/* ── Creator Level Progress ── */
.vc-level-progress {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(138,87,255,0.15);
  border-radius: 12px;
  padding: 0.85rem;
  margin-bottom: 1rem;
}

.vc-lp-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.vc-lp-name {
  font-size: 0.7rem;
  color: rgba(240,235,255,0.85);
  font-weight: 600;
}

.vc-lp-xp {
  font-size: 0.6rem;
  color: #b088ff;
}

.vc-lp-bar-wrap {
  height: 6px;
  background: rgba(138,87,255,0.12);
  border-radius: 99px;
  overflow: hidden;
  margin-bottom: 0.4rem;
}

.vc-lp-bar {
  height: 100%;
  background: linear-gradient(90deg, #8a57ff, #ff6b9d);
  border-radius: 99px;
  transition: width 1.2s ease;
}

.vc-lp-milestones {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.vc-milestone {
  font-size: 0.52rem;
  padding: 0.18rem 0.4rem;
  border-radius: 99px;
  background: rgba(138,87,255,0.1);
  color: rgba(200,180,255,0.55);
  border: 1px solid rgba(138,87,255,0.2);
}

.vc-milestone.done {
  background: rgba(0,230,118,0.1);
  color: #00e676;
  border-color: rgba(0,230,118,0.25);
}

/* ── Responsive tweak ── */
@media (min-width: 400px) {
  .vc-hero-stats {
    grid-template-columns: repeat(4, 1fr);
  }

  .vc-zone-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}
