/* ── Layout ─────────────────────────────────────────────────────────────────── */
.dash-container {
  padding-top: 72px;
  max-width: 1400px;
  margin: 0 auto;
  padding-left: 32px;
  padding-right: 32px;
  padding-bottom: 80px;
}

.dash-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 28px;
}
.dash-title {
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 800;
  letter-spacing: -1px;
  color: var(--text);
  margin-bottom: 6px;
}
.dash-subtitle { font-size: 14px; color: var(--text-muted); }

.dash-actions { display: flex; gap: 10px; }

/* ── Buttons ─────────────────────────────────────────────────────────────────── */
.btn-primary {
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  padding: 10px 20px;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: opacity 0.2s;
}
.btn-primary:hover { opacity: 0.88; }
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-ghost {
  background: var(--surface-2);
  color: var(--text-muted);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px 20px;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-ghost:hover { color: var(--text); border-color: var(--text-dim); }
.btn-ghost.danger:hover { color: #FF5F57; border-color: #FF5F57; }

/* ── Channel Tabs ─────────────────────────────────────────────────────────────── */
.channel-tabs {
  display: flex;
  gap: 6px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}
.channel-tab {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 7px 16px;
  font-size: 13px;
  color: var(--text-muted);
  font-family: var(--font-body);
  cursor: pointer;
  transition: all 0.2s;
}
.channel-tab:hover { color: var(--text); border-color: var(--text-dim); }
.channel-tab.active {
  background: var(--accent-dim);
  border-color: var(--accent);
  color: var(--accent);
}

/* ── Stats ───────────────────────────────────────────────────────────────────── */
.dash-stats {
  display: flex;
  gap: 32px;
  margin-bottom: 36px;
  padding: 24px 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}
.dash-stat { text-align: center; }
.dash-stat-num {
  display: block;
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 800;
  color: var(--accent);
  margin-bottom: 4px;
}
.dash-stat-label {
  font-size: 12px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* ── Kanban ──────────────────────────────────────────────────────────────────── */
.kanban {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
  min-height: 600px;
}
.kanban-col {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.kanban-col-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--surface-2);
}
.kanban-col-title {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
}
.kanban-col-count {
  background: var(--border);
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 10px;
}
.kanban-cards {
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 200px;
}

/* ── Video Card ──────────────────────────────────────────────────────────────── */
.video-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px;
  cursor: pointer;
  transition: all 0.2s;
}
.video-card:hover { border-color: var(--accent); transform: translateY(-1px); }

.vc-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}
.vc-channel {
  font-size: 10px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 1px;
}
.vc-step {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.5px;
}
.vc-title {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.4;
  margin-bottom: 10px;
}
.vc-thumbnail-row {
  position: relative;
  margin-bottom: 10px;
}
.vc-thumb-img {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid var(--border);
}
.vc-thumb-placeholder {
  width: 100%;
  aspect-ratio: 16/9;
  background: var(--surface-2);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-dim);
  font-size: 20px;
}
.vc-video-badge {
  position: absolute;
  top: 6px;
  right: 6px;
  background: rgba(0,0,0,0.7);
  border-radius: 4px;
  padding: 2px 6px;
  font-size: 12px;
}
.vc-actions { display: flex; gap: 6px; }
.vc-gen-btn {
  flex: 1;
  background: var(--accent-dim);
  color: var(--accent);
  border: 1px solid rgba(255,107,44,0.2);
  border-radius: 6px;
  padding: 7px 10px;
  font-size: 11px;
  font-weight: 600;
  font-family: var(--font-body);
  cursor: pointer;
  transition: all 0.2s;
}
.vc-gen-btn:hover:not(:disabled) { background: var(--accent); color: #fff; }
.vc-gen-btn:disabled { opacity: 0.5; cursor: not-allowed; }

/* ── Modals ──────────────────────────────────────────────────────────────────── */
.modal-overlay {
  display: flex;
  align-items: center;
  justify-content: center;
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.7);
  z-index: 200;
  backdrop-filter: blur(4px);
}
.modal {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  width: 480px;
  max-width: 90vw;
  box-shadow: 0 40px 80px rgba(0,0,0,0.6);
}
.modal-wide { width: 680px; }
.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 28px;
}
.modal-title {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
}
.modal-close {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 24px;
  cursor: pointer;
  line-height: 1;
}
.modal-close:hover { color: var(--text); }

/* ── Forms ───────────────────────────────────────────────────────────────────── */
.form-group { margin-bottom: 20px; }
.form-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 8px;
  font-family: var(--font-display);
}
.form-hint { font-weight: 400; color: var(--text-dim); }
.form-input {
  width: 100%;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 16px;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s;
  box-sizing: border-box;
}
.form-input:focus { border-color: var(--accent); }
.btn-primary.full { width: 100%; }

/* ── Video Detail ─────────────────────────────────────────────────────────────── */
.detail-meta {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.detail-badge {
  font-size: 12px;
  color: var(--text-muted);
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 4px 10px;
}
.detail-thumb {
  margin-bottom: 24px;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
}
.detail-thumb img { width: 100%; display: block; }
.detail-section { margin-bottom: 20px; }
.detail-section h4 {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 10px;
}
.detail-script {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  font-size: 12px;
  line-height: 1.7;
  color: var(--text-muted);
  white-space: pre-wrap;
  max-height: 300px;
  overflow-y: auto;
}
.detail-actions {
  display: flex;
  gap: 10px;
  margin-top: 20px;
}

/* ── Responsive ───────────────────────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .kanban { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 768px) {
  .dash-container { padding: 72px 16px 60px; }
  .dash-header { flex-direction: column; align-items: flex-start; gap: 12px; }
  .kanban { grid-template-columns: 1fr; }
  .dash-stats { flex-wrap: wrap; gap: 16px; }
  .modal { padding: 24px; }
}