/* Canvas tabs — gray workspace like Vbee */
body.vb-canvas-tab .workspace { background: #eef0f3; }
body.vb-canvas-tab .panel {
  background: transparent;
  padding: 12px 20px 20px !important;
}
body.vb-canvas-tab .sidebar {
  background: #fff;
  border-right: 1px solid #e8eaed;
}
body.vb-canvas-tab .nav-item {
  padding: 10px 14px;
  gap: 10px;
}
body.vb-canvas-tab .nav-item svg,
body.vb-canvas-tab .nav-item .nav-ico {
  width: 18px;
  height: 18px;
}
body.vb-canvas-tab .side-credits {
  margin: 8px 12px 12px;
  padding: 12px 14px;
  background: #fafafa;
  border: 1px solid #e8eaed;
  border-radius: 10px;
}
html.dark body.vb-canvas-tab .workspace { background: var(--bg); }
html.dark body.vb-canvas-tab .sidebar {
  background: var(--surface);
  border-color: var(--border);
}

body.has-flash #studioPromo { display: none !important; }

/* Hide legacy topbar + horizontal nav on canvas tabs */
body.vb-canvas-tab .topbar { display: none !important; }
body.vb-canvas-tab #studioTopnav { display: none !important; }

/* Utility bar — Vbee header */
.vb-utility-bar {
  display: none;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  padding: 10px 20px;
  background: #fff;
  border-bottom: 1px solid #eef0f3;
  flex-shrink: 0;
}
body.vb-canvas-tab #vbUtilityBar {
  display: flex !important;
}
.vb-util-spacer { flex: 1; }
.vb-util-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.vb-util-ico {
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 10px;
  background: transparent;
  color: #6b7280;
  display: grid;
  place-items: center;
  cursor: pointer;
  padding: 0;
}
.vb-util-ico svg { width: 20px; height: 20px; }
.vb-util-ico:hover { background: #f3f4f6; color: #374151; }
.vb-util-credits {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 4px 0 12px;
  border-left: 1px solid #eef0f3;
  margin-left: 4px;
}
.vb-util-credits-lbl {
  font-size: 0.78rem;
  color: #6b7280;
  white-space: nowrap;
}
.vb-top-credits-val {
  font-weight: 800;
  font-size: 0.92rem;
  color: #1f2937;
  white-space: nowrap;
}
.vb-top-plus {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--vbee-yellow);
  color: var(--vbee-purple);
  font-weight: 800;
  font-size: 1.1rem;
  line-height: 1;
  display: grid;
  place-items: center;
  text-decoration: none;
  box-shadow: 0 1px 4px rgba(255, 194, 51, 0.4);
}
.vb-top-plus:hover { background: var(--vbee-yellow-hover); }
.vb-util-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  color: #fff;
  font-weight: 800;
  font-size: 0.85rem;
  cursor: pointer;
  flex-shrink: 0;
}

body.vb-canvas-tab .workspace.vb-inline-hist {
  overflow: hidden;
  flex-direction: column;
}
body.vb-canvas-tab .workspace.vb-inline-hist .panel {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
}

/* Sidebar active — Vbee yellow accent */
.nav-item.active {
  background: rgba(255, 194, 51, 0.14) !important;
  color: #92400e !important;
  box-shadow: inset 3px 0 0 var(--vbee-yellow) !important;
}
html.dark .nav-item.active {
  color: var(--vbee-primary) !important;
  background: rgba(255, 194, 51, 0.1) !important;
}

.voice-cat-tab.active {
  background: var(--vbee-yellow) !important;
  color: var(--vbee-purple) !important;
  border-color: var(--vbee-yellow) !important;
  box-shadow: none !important;
}

.voice-pill.active {
  border-color: var(--vbee-yellow) !important;
  background: rgba(255, 194, 51, 0.12) !important;
}

.vb-page-canvas {
  display: flex;
  flex-direction: column;
  gap: 14px;
  flex: 1;
  min-height: 0;
  max-width: none;
  width: 100%;
}

/* ── TTS page ── */
.vb-tts-page { gap: 14px; }

.vb-tts-title-row {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 2px 4px 0;
}
.vb-tts-title-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}
.vb-tts-title-wrap input {
  flex: 1;
  min-width: 0;
  font-size: 1.05rem;
  font-weight: 800;
  border: none;
  background: transparent;
  color: var(--text);
  padding: 4px 0;
}
.vb-tts-title-wrap input:focus { outline: none; }
.vb-tts-title-wrap input:disabled { opacity: 0.7; }
.vb-title-edit {
  border: none;
  background: transparent;
  color: #9ca3af;
  font-size: 0.95rem;
  padding: 4px;
  cursor: pointer;
  line-height: 1;
}
.vb-title-edit:hover { color: #374151; }

.vb-tts-credit-banner {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 14px;
  padding: 10px 14px;
  margin-bottom: 12px;
  border-radius: 10px;
  border: 1px solid #fde68a;
  background: #fffbeb;
  color: #92400e;
  font-size: 0.84rem;
  font-weight: 600;
}
.vb-tts-credit-banner.waiting {
  border-color: #bfdbfe;
  background: #eff6ff;
  color: #1e40af;
}
.vb-tts-credit-banner a {
  color: inherit;
  font-weight: 800;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.vb-tts-credit-banner a:hover { opacity: 0.85; }

.vb-tts-card {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0;
  overflow: hidden;
  background: #fff;
  border: 1px solid #e8eaed;
  border-radius: 14px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
  min-height: min(480px, calc(100vh - 420px));
}

.vb-tts-card .toolbar.ivoi-tts-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 0;
  padding: 10px 14px;
  border: none;
  border-bottom: 1px solid #eef0f3;
  border-radius: 0;
  box-shadow: none;
  background: #fff;
  flex-shrink: 0;
}
.vb-tts-card .ivoi-tts-toolbar .vb-tts-toolbar-left,
.vb-tts-card .ivoi-tts-toolbar .vb-tts-toolbar-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.vb-tts-card .ivoi-tts-toolbar .vb-tts-toolbar-right {
  margin-left: auto;
}
.vb-tts-card .ivoi-tts-toolbar .voice-pick-btn {
  min-width: 180px;
  max-width: 260px;
  padding: 6px 10px;
  border-radius: 10px;
  border-color: #e5e7eb;
  background: #fff;
}
.vb-tts-card .ivoi-tts-toolbar .voice-pick-btn:hover {
  border-color: #22c55e;
}
.vb-tts-card .ivoi-tts-toolbar .tb-speed-wrap {
  border-color: #e5e7eb;
  background: #fff;
}
.vb-tts-card .ivoi-tts-toolbar .tb-select {
  border-color: #e5e7eb;
  background: #fff;
  font-weight: 700;
  text-transform: uppercase;
}
.vb-tts-card .ivoi-tts-toolbar .tb-divider {
  display: block;
  height: 28px;
  background: #e5e7eb;
  margin: 0 2px;
}
.vb-tts-card .ivoi-tts-toolbar .tb-icon-btn {
  width: 38px;
  height: 38px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: #64748b;
}
.vb-tts-card .ivoi-tts-toolbar .tb-icon-btn:hover {
  color: #22c55e;
  background: rgba(34, 197, 94, 0.08);
}
.vb-tts-card .ivoi-tts-toolbar .tb-icon-btn.on {
  color: #78350f;
  background: rgba(255, 194, 51, 0.12);
  border-color: var(--vbee-yellow);
}
.vb-tts-card .ivoi-tts-toolbar .btn-vbee-cta {
  margin-left: auto;
  border-radius: 10px;
  padding: 10px 18px;
  font-size: 0.88rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}
.vb-tts-card .voice-banner {
  margin: 0;
  border-radius: 0;
  border-left: none;
  border-right: none;
  border-top: none;
  flex-shrink: 0;
}

.vb-pause-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #f9fafb;
  font-size: 0.82rem;
  font-weight: 700;
  padding: 6px 10px;
  color: #374151;
  cursor: pointer;
}
.vb-pause-pill:hover { border-color: var(--vbee-yellow); }
.vb-pause-pill .vb-pause-clock {
  width: 16px;
  height: 16px;
  color: #6b7280;
  flex-shrink: 0;
}
.vb-pause-pill .vb-pause-val { line-height: 1; }
.vb-pause-pill .vp-chev {
  font-size: 0.7rem;
  color: #9ca3af;
  margin-left: 0;
}

.vb-break-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #f9fafb;
  font-size: 0.82rem;
  font-weight: 700;
  padding: 6px 10px;
  color: #374151;
  position: relative;
}
.vb-break-pill:hover { border-color: var(--vbee-yellow); }
.vb-break-pill .vb-pause-clock {
  width: 16px;
  height: 16px;
  color: #6b7280;
  flex-shrink: 0;
  pointer-events: none;
}
.vb-break-pill select {
  border: none;
  background: transparent;
  font: inherit;
  font-weight: 700;
  color: inherit;
  padding: 0 2px 0 0;
  margin: 0;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  min-width: 2.5em;
}
.vb-break-pill select:focus { outline: none; }
.vb-break-pill .vp-chev {
  font-size: 0.7rem;
  color: #9ca3af;
  pointer-events: none;
}

/* legacy Vbee toolbar pieces (other tabs) */
.vb-tts-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 10px 14px;
  border-bottom: 1px solid #eef0f3;
  background: #fff;
  flex-shrink: 0;
}
.vb-tts-toolbar-left,
.vb-tts-toolbar-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.vb-speed-pill {
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #f9fafb;
  font-size: 0.82rem;
  font-weight: 700;
  padding: 6px 10px;
  color: #374151;
  cursor: pointer;
}
.vb-fmt-select {
  border: 1px solid #e5e7eb !important;
  border-radius: 8px;
  background: #f9fafb;
  font-size: 0.82rem;
  font-weight: 700;
  padding: 6px 10px;
  text-transform: lowercase;
}
.vb-tts-toolbar .tb-icon-btn {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  border: 1px solid #e5e7eb;
  background: #fff;
  color: #6b7280;
  display: grid;
  place-items: center;
  padding: 0;
  cursor: pointer;
}
.vb-tts-toolbar .tb-icon-btn svg { width: 18px; height: 18px; }
.vb-tts-toolbar .tb-icon-btn.on {
  border-color: var(--vbee-yellow);
  background: rgba(255, 194, 51, 0.12);
  color: #78350f;
}

.vb-voice-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  max-width: 220px;
  padding: 5px 10px 5px 5px !important;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
  background: #fff;
  cursor: pointer;
}
.vb-voice-pill:hover { border-color: var(--vbee-yellow); }
.vb-voice-av {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  display: grid;
  place-items: center;
}
.vb-voice-av .vpill-av-img,
.vb-voice-av .vpill-av-grad {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 0.72rem;
  font-weight: 800;
  color: #fff;
}
.vb-voice-mid { min-width: 0; flex: 1; }
.vb-voice-pill .vp-name {
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
}
.vb-voice-pill .vp-chev { font-size: 0.75rem; color: #9ca3af; }

.vb-split-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  font-weight: 700;
  color: #374151;
  cursor: pointer;
  user-select: none;
}
.vb-split-toggle input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}
.vb-split-track {
  width: 36px;
  height: 20px;
  border-radius: 999px;
  background: #d1d5db;
  position: relative;
  transition: background 0.2s;
}
.vb-split-thumb {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
  transition: transform 0.2s;
}
.vb-split-toggle input:checked + .vb-split-track {
  background: var(--vbee-yellow);
}
.vb-split-toggle input:checked + .vb-split-track .vb-split-thumb {
  transform: translateX(16px);
}

.vb-proj-go {
  border: none;
  border-radius: 8px;
  background: #ef4444;
  color: #fff;
  font-size: 0.8rem;
  font-weight: 800;
  padding: 8px 14px;
  cursor: pointer;
}
.vb-proj-go:hover { filter: brightness(0.95); }

.vb-tts-editor-wrap {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 280px;
}
.vb-tts-editor-meta {
  position: absolute;
  right: 14px;
  bottom: 10px;
  display: flex;
  align-items: center;
  gap: 12px;
  pointer-events: none;
  z-index: 1;
}
.vb-tts-editor-meta .vb-tts-chars,
.vb-tts-editor-meta .vb-tts-preview {
  font-size: 0.78rem;
  font-weight: 700;
  color: #9ca3af;
  font-variant-numeric: tabular-nums;
}

.vb-tts-textarea {
  width: 100%;
  flex: 1;
  min-height: 280px;
  border: none;
  resize: vertical;
  padding: 16px 18px 36px;
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--text);
  background: #fff;
  font-family: inherit;
}
.vb-tts-textarea:focus { outline: none; }
.vb-tts-textarea::placeholder { color: #9ca3af; }

.vb-tts-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 12px 14px;
  border-top: 1px solid #eef0f3;
  background: #fafafa;
  flex-shrink: 0;
}
.vb-tts-bottom-chips-only {
  justify-content: flex-start;
  background: #fff;
  border-top: 1px solid #f3f4f6;
}
.vb-tts-bottom-chips {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  flex: 1;
  min-width: 0;
}
.vb-tts-cost {
  color: #6b7280;
  font-size: 0.76rem;
  white-space: nowrap;
}
.vb-tts-footer {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 16px;
  padding: 12px 14px;
  border-top: 1px solid #eef0f3;
  background: #fafafa;
  flex-shrink: 0;
}
.vb-tts-chars {
  font-size: 0.82rem;
  font-weight: 700;
  color: #374151;
  justify-self: start;
}
.vb-tts-preview {
  font-size: 0.82rem;
  font-weight: 700;
  color: #9ca3af;
  font-variant-numeric: tabular-nums;
  justify-self: center;
}
.vb-tts-go {
  justify-self: end;
  border-radius: 999px;
  padding: 11px 24px;
  min-width: 168px;
  font-size: 0.92rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.vb-tts-play { width: 16px; height: 16px; flex-shrink: 0; }
.vb-tts-wand { width: 18px; height: 18px; }
.vb-tts-card .msg {
  padding: 0 14px 12px;
  margin: 0;
}

/* Inline history table */
.vb-hist-panel {
  background: #fff;
  border: 1px solid #e8eaed;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
  flex-shrink: 0;
}
.vb-hist-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 12px 16px;
  border-bottom: 1px solid #eef0f3;
  background: #fafafa;
}
.vb-hist-title {
  font-weight: 800;
  font-size: 0.92rem;
  color: #1f2937;
}
.vb-hist-title .cnt {
  font-weight: 600;
  color: #9ca3af;
  margin-left: 2px;
}
.vb-hist-head-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.vb-hist-search {
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 7px 12px;
  font-size: 0.82rem;
  min-width: 180px;
  background: #fff;
}
.vb-hist-ico {
  width: 34px;
  height: 34px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
  color: #6b7280;
  cursor: pointer;
  font-size: 1rem;
  display: grid;
  place-items: center;
  padding: 0;
}
.vb-hist-ico svg { width: 16px; height: 16px; }
.vb-hist-ico:hover {
  border-color: var(--vbee-yellow);
  color: #78350f;
}
.vb-hist-bulk-del {
  border: 1px solid #fecaca;
  border-radius: 8px;
  background: #fef2f2;
  color: #dc2626;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 7px 12px;
  cursor: pointer;
}
.vb-hist-bulk-del:hover { background: #fee2e2; }

.vb-hist-table-head {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) 140px 100px;
  gap: 12px;
  align-items: center;
  padding: 10px 16px;
  background: #fafafa;
  border-bottom: 1px solid #eef0f3;
  font-size: 0.72rem;
  font-weight: 800;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.vb-hist-list {
  max-height: min(420px, 42vh);
  overflow-y: auto;
}
.vb-hist-row {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) 140px auto;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  min-height: 62px;
  border-bottom: 1px solid #f3f4f6;
  cursor: pointer;
}
.vb-hist-row:nth-child(even) { background: #fcfcfd; }
.vb-hist-row:hover { background: #fafafa; }
.vb-hist-row.fail {
  opacity: 1;
  align-items: start;
  background: #fff7f7;
  border-left: 3px solid #ef4444;
  box-shadow: inset 0 -1px 0 rgba(239, 68, 68, 0.12);
  padding-top: 12px;
  padding-bottom: 12px;
}
.vb-hist-row.fail .vb-hist-check,
.vb-hist-row.fail .vb-hist-voice,
.vb-hist-row.fail .vb-hist-actions {
  padding-top: 4px;
}
.vb-hist-row.fail:hover { background: #ffefef; }
.vb-hist-row.fail:nth-child(even) { background: #fff5f5; }
.vb-hist-badge {
  display: inline-flex;
  align-items: center;
  margin-right: 8px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  line-height: 1.4;
  vertical-align: middle;
  white-space: nowrap;
}
.vb-hist-badge.is-fail {
  color: #b91c1c;
  background: #fee2e2;
  border: 1px solid #fecaca;
}
.vb-hist-badge.is-run {
  color: #b45309;
  background: #ffedd5;
  border: 1px solid #fed7aa;
}
.vb-hist-badge.is-expired {
  color: #64748b;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
}
.vb-hist-fail-box {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
  padding: 10px 12px;
  border-radius: 10px;
  background: #fef2f2;
  border: 1px solid #fecaca;
  width: 100%;
  box-sizing: border-box;
}
.vb-hist-check input {
  width: 16px;
  height: 16px;
  accent-color: var(--vbee-yellow);
}
.vb-hist-preview {
  font-size: 0.86rem;
  font-weight: 600;
  color: #1f2937;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.vb-hist-meta {
  font-size: 0.72rem;
  color: #9ca3af;
  margin-top: 3px;
  line-height: 1.4;
}
.vb-hist-run { color: #d97706; font-weight: 700; margin-left: 6px; }
.vb-hist-voice {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.vb-hav {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  background: #f3f4f6;
}
.vb-hav-img { width: 100%; height: 100%; object-fit: cover; }
.vb-hav-letter { font-size: 0.72rem; font-weight: 800; color: #6b7280; }
.vb-vname {
  font-size: 0.78rem;
  font-weight: 700;
  color: #374151;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.vb-hist-actions {
  display: flex;
  align-items: center;
  gap: 4px;
  justify-content: flex-end;
}
.vb-hist-act {
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: #6b7280;
  display: grid;
  place-items: center;
  cursor: pointer;
  text-decoration: none;
  padding: 0;
}
.vb-hist-act svg { width: 16px; height: 16px; }
.vb-hist-act:hover {
  background: rgba(255, 194, 51, 0.15);
  color: #78350f;
}
.vb-hist-err {
  flex: 1 1 220px;
  font-size: 0.8rem;
  font-weight: 600;
  color: #b91c1c;
  line-height: 1.4;
  padding: 0;
}
.vb-hist-fail-box .vb-hist-retry-btn {
  flex: 0 0 auto;
  margin-left: auto;
}
.vb-hist-retry-status {
  grid-column: 1 / -1;
  font-size: 0.78rem;
  font-weight: 700;
  color: #6d28d9;
  line-height: 1.35;
  padding-top: 4px;
}
.vb-hist-retry-row {
  grid-column: 1 / -1;
  display: flex;
  justify-content: flex-start;
  margin-top: 2px;
}
.vb-hist-retry-btn {
  border: 1px solid rgba(234, 88, 12, 0.45);
  background: rgba(234, 88, 12, 0.1);
  color: #c2410c;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 5px 10px;
  border-radius: 8px;
  cursor: pointer;
}
.vb-hist-retry-btn:hover { filter: brightness(0.97); }
.vb-hist-retry-btn:disabled { opacity: 0.6; cursor: wait; }
.vb-hist-act.vb-hist-retry-failed { color: #c2410c; }
.vb-hist-pager {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
  padding: 10px 16px;
  border-top: 1px solid #eef0f3;
  background: #fafafa;
  font-size: 0.78rem;
  color: #6b7280;
}
.vb-hist-pager select {
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  padding: 4px 8px;
  margin-left: 6px;
  font-size: 0.78rem;
}
.vb-hist-pager .pg-nav {
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  background: #fff;
  width: 28px;
  height: 28px;
  cursor: pointer;
  color: #374151;
}
.vb-hist-pager .pg-nav:disabled { opacity: 0.35; cursor: not-allowed; }

@media (max-width: 900px) {
  .vb-hist-table-head,
  .vb-hist-row {
    grid-template-columns: 32px minmax(0, 1fr) auto;
  }
  .vb-hist-table-head span:nth-child(3),
  .vb-hist-voice { display: none; }
  .vb-util-credits-lbl { display: none; }
}

/* Projects page styles (unchanged essentials) */
.vb-projects-page {
  display: flex;
  flex-direction: column;
  gap: 28px;
  width: 100%;
  max-width: none;
  padding: 4px 2px 24px;
}
.vb-projects-page .projects-page-head h1 {
  font-size: 1.5rem;
  font-weight: 800;
}
.vb-projects-page .proj-help-link {
  border: 1px solid #e5e7eb;
  background: #fff;
  color: #374151;
  border-radius: 10px;
  padding: 8px 16px;
}
.vb-projects-page .proj-help-link:hover {
  border-color: var(--vbee-yellow);
  color: #78350f;
}
.vb-projects-page .projects-create { gap: 20px; }
.vb-projects-page .proj-create-card {
  border-radius: 16px;
  border: 1px solid #e8eaed;
  padding: 24px 20px 22px;
  min-height: 168px;
  position: relative;
  overflow: hidden;
}
.vb-projects-page .proj-list {
  border-radius: 14px;
  border-color: #e8eaed;
}
.vb-projects-page .proj-list-head,
.vb-projects-page .proj-row {
  display: grid;
  grid-template-columns: 36px 44px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}
.workspace.has-hist .hist {
  border-top: 1px solid #e8eaed;
  background: #fff;
}

/* ── Shared canvas (SRT + legacy) ── */
.vb-title-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding: 4px 2px 0;
}
.vb-title-row input {
  flex: 1;
  min-width: 200px;
  font-size: 1.125rem;
  font-weight: 800;
  border: none;
  background: transparent;
  color: var(--text);
  padding: 4px 0;
}
.vb-quota-pill {
  font-size: 0.78rem;
  font-weight: 800;
  color: #92400e;
  background: rgba(255, 194, 51, 0.2);
  border: 1px solid rgba(255, 194, 51, 0.45);
  padding: 5px 10px;
  border-radius: 999px;
}
.vb-card {
  background: #fff;
  border: 1px solid #e8eaed;
  border-radius: 14px;
  padding: 14px 16px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
}
.vb-work-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
  min-height: 0;
  padding: 16px;
}
.vb-srt-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  font-weight: 800;
  color: var(--text);
  margin: -4px 0 0 2px;
}
.vb-srt-label::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--vbee-yellow);
}
.srt-dub-banner {
  margin: 0;
  padding: 12px 14px;
  border-radius: 10px;
  background: rgba(255, 194, 51, 0.12);
  border: 1px solid rgba(255, 194, 51, 0.35);
  font-size: 0.84rem;
  font-weight: 600;
  line-height: 1.45;
  color: #78350f;
}
.vb-work-section .upload-drop.srt-drop {
  border: 2px dashed #e5e7eb;
  border-radius: 12px;
  background: #fafafa;
  padding: 32px 20px;
  text-align: center;
}
