/* ==============================================================================
   Vertex AI - 5 AI Agents Screens & HUD Widgets Stylesheet
   Mac/Terminal-inspired HUD windows, real-time metrics, charts & animations
   ============================================================================== */

/* ------------------------------------------------------------------------------
   1. Shared HUD Window Shell
   ------------------------------------------------------------------------------ */
.hud {
  border-radius: 18px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  background: rgba(8, 12, 22, 0.92);
  box-shadow: 0 20px 50px -10px rgba(0, 0, 0, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  position: relative;
  min-height: 420px;
}

.hud-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 18px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.14);
  background: rgba(15, 23, 42, 0.6);
  font: 400 12px var(--mono);
  color: var(--text-3);
  user-select: none;
}

.hud-dots {
  display: flex;
  align-items: center;
  gap: 6px;
}

.hud-dots i {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.hud-dots i:nth-child(1) { background: #ef4444; }
.hud-dots i:nth-child(2) { background: #f59e0b; }
.hud-dots i:nth-child(3) { background: #10b981; }

.hud-title {
  color: var(--text-2);
  font-size: 12px;
  letter-spacing: 0.02em;
}

.hud-status {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font: 500 10.5px var(--mono);
  color: var(--cyan);
  background: rgba(34, 211, 238, 0.1);
  border: 1px solid rgba(34, 211, 238, 0.25);
  padding: 2px 8px;
  border-radius: 999px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.hud-status .pulse-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 6px var(--cyan);
  animation: pulseDot 1.8s infinite ease-in-out;
}

/* ------------------------------------------------------------------------------
   2. Screen 1: Channel Agent (Content Pipeline & Follower Growth)
   ------------------------------------------------------------------------------ */
.hud-channel-wrap {
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.channel-stats-row {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 14px;
}

.channel-fol-card {
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(148, 163, 184, 0.12);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.channel-fol-card h4 {
  font: 500 11px var(--mono);
  color: var(--text-3);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.channel-fol-card .fol-num {
  font-size: 26px;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.02em;
  margin: 4px 0 2px;
}

.channel-fol-card .up {
  color: var(--green);
  font: 500 11.5px var(--mono);
}

.channel-cal-card {
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(148, 163, 184, 0.12);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.channel-cal-card h4 {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  font: 500 11px var(--mono);
  color: var(--text-3);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.cal-grid span {
  aspect-ratio: 2.2;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.04);
  transition: background 0.3s;
}

.cal-grid span.tt { background: rgba(34, 211, 238, 0.65); }
.cal-grid span.yt { background: rgba(248, 113, 113, 0.65); }
.cal-grid span.fb { background: rgba(139, 92, 246, 0.65); }

.cal-legend {
  display: flex;
  gap: 12px;
  font: 400 10.5px var(--mono);
  color: var(--text-3);
}

.cal-legend b {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 2px;
  margin-right: 4px;
}

/* Terminal Feed */
.hud-term {
  padding: 14px 16px;
  border-radius: 12px;
  background: rgba(4, 7, 14, 0.85);
  border: 1px solid rgba(148, 163, 184, 0.12);
  font: 400 12.5px/1.85 var(--mono);
  color: var(--text-2);
  min-height: 140px;
  overflow: hidden;
}

.hud-term .line {
  display: block;
}

.hud-term .line.dim { color: var(--text-3); }
.hud-term .line.cyan { color: var(--cyan); }
.hud-term .line.green { color: var(--green); }
.hud-term .line.amber { color: var(--amber); }

.hud-term .line.caret::after {
  content: "▋";
  color: var(--cyan);
  margin-left: 3px;
  animation: blink 1s infinite;
}

@keyframes blink { 50% { opacity: 0.15; } }

/* ------------------------------------------------------------------------------
   3. Screen 2: Ads Agent (Real-time ROAS & Allocation)
   ------------------------------------------------------------------------------ */
.hud-ads-wrap {
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.hud-kpis {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.kpi {
  padding: 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(148, 163, 184, 0.12);
  display: flex;
  flex-direction: column;
}

.kpi .lbl {
  font: 500 10.5px var(--mono);
  color: var(--text-3);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.kpi .val {
  font-size: 22px;
  font-weight: 700;
  color: #fff;
  line-height: 1.2;
  margin: 4px 0 2px;
}

.kpi .val.cyan { color: var(--cyan); }

.kpi .diff {
  font: 500 11px var(--mono);
  color: var(--text-3);
}

.kpi .diff.green { color: var(--green); }

/* ROAS Bars Chart */
.hud-chart {
  padding: 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(148, 163, 184, 0.12);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.hud-chart-head {
  display: flex;
  justify-content: space-between;
  font: 500 11px var(--mono);
  color: var(--text-3);
  text-transform: uppercase;
}

.hud-chart .bars {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  height: 90px;
  padding-top: 10px;
}

.hud-chart .bars i,
.hud-chart .bars span {
  flex: 1;
  height: 15%;
  border-radius: 4px 4px 1px 1px;
  background: linear-gradient(180deg, var(--cyan), rgba(34, 211, 238, 0.15));
  transition: height 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
}

/* Allocation Bars */
.hud-alloc {
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(148, 163, 184, 0.12);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.hud-alloc h4 {
  font: 500 11px var(--mono);
  color: var(--text-3);
  text-transform: uppercase;
  margin-bottom: 2px;
}

.hud-alloc div {
  display: flex;
  align-items: center;
  gap: 10px;
  font: 400 12px var(--mono);
  color: var(--text-2);
}

.hud-alloc em {
  font-style: normal;
  width: 65px;
}

.hud-alloc i {
  flex: 1;
  position: relative;
  overflow: hidden;
  height: 7px;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.06);
}

.hud-alloc i::after {
  content: "";
  position: absolute;
  inset: 0;
  width: var(--w, 15%);
  border-radius: 9px;
  background: linear-gradient(90deg, var(--violet), var(--cyan));
  transition: width 1s ease-out;
}

/* ------------------------------------------------------------------------------
   4. Screen 3: Sales Agent (Unified Inbox & Live Chat)
   ------------------------------------------------------------------------------ */
.hud-chat-wrap {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}

.inbox-channel-tabs {
  display: flex;
  gap: 8px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
  padding-bottom: 10px;
}

.inbox-tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: 8px;
  font: 500 11px var(--mono);
  color: var(--text-3);
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid transparent;
}

.inbox-tab.active {
  color: var(--text);
  background: rgba(34, 211, 238, 0.08);
  border-color: rgba(34, 211, 238, 0.3);
}

.inbox-tab .tag-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
}

.inbox-tab .tag-dot.zl { background: var(--cyan); }
.inbox-tab .tag-dot.fb { background: #60a5fa; }
.inbox-tab .tag-dot.tt { background: #f472b6; }

.hud-msgs {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 4px 0;
  min-height: 220px;
  justify-content: flex-end;
}

.hud-msgs .msg {
  max-width: 85%;
  padding: 10px 14px;
  border-radius: 14px;
  font-size: 13.5px;
  line-height: 1.5;
  position: relative;
  animation: msgPop 0.35s var(--ease);
}

@keyframes msgPop {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

.hud-msgs .msg.user {
  align-self: flex-start;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(148, 163, 184, 0.14);
  color: var(--text);
  border-bottom-left-radius: 4px;
}

.hud-msgs .msg.bot {
  align-self: flex-end;
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.18), rgba(139, 92, 246, 0.18));
  border: 1px solid rgba(34, 211, 238, 0.3);
  color: #fff;
  border-bottom-right-radius: 4px;
}

.hud-msgs .msg .badge {
  display: inline-block;
  font: 500 10px var(--mono);
  color: var(--cyan);
  margin-right: 6px;
  background: rgba(34, 211, 238, 0.15);
  padding: 2px 6px;
  border-radius: 4px;
}

.hud-msgs .msg.sys {
  align-self: center;
  max-width: 90%;
  background: rgba(52, 211, 153, 0.08);
  border: 1px solid rgba(52, 211, 153, 0.3);
  color: var(--green);
  font: 500 11.5px var(--mono);
  padding: 7px 14px;
  border-radius: 999px;
  text-align: center;
}

/* ------------------------------------------------------------------------------
   5. Screen 4: KOL Agent (Virtual KOL Avatar & Livestream Feed)
   ------------------------------------------------------------------------------ */
.hud-stream-body {
  padding: 16px;
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 16px;
}

.stream-avatar-box {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  background: radial-gradient(circle at 50% 35%, rgba(139, 92, 246, 0.35), transparent 65%), var(--bg-2);
  min-height: 220px;
  padding: 12px;
}

.stream-avatar-box svg {
  width: 85%;
  height: auto;
}

.stream-avatar-box .laser-scan {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 35%;
  background: linear-gradient(180deg, transparent, rgba(34, 211, 238, 0.3), transparent);
  will-change: transform;
  animation: laserScan 2.6s linear infinite;
  pointer-events: none;
}

@keyframes laserScan {
  from { transform: translateY(-100%); }
  to { transform: translateY(320%); }
}

.stream-avatar-box .avatar-tag {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 3px 7px;
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 6px;
  background: rgba(5, 7, 13, 0.8);
  font: 500 9.5px var(--mono);
  color: var(--amber);
}

.stream-avatar-box .live-pill {
  position: absolute;
  bottom: 10px;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(239, 68, 68, 0.85);
  color: #fff;
  font: 600 10px var(--mono);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.stream-feed-col {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.kol-traits {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.kol-trait {
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 11.5px;
  color: var(--text-2);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(148, 163, 184, 0.14);
}

.kol-trait.highlight {
  color: #fff;
  border-color: rgba(139, 92, 246, 0.4);
  background: rgba(139, 92, 246, 0.15);
}

.stream-chat-box {
  padding: 12px;
  border-radius: 12px;
  background: rgba(4, 7, 14, 0.85);
  border: 1px solid rgba(148, 163, 184, 0.12);
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 13px;
}

.stream-chat-box .feed-item {
  color: var(--text-2);
  line-height: 1.45;
}

.stream-chat-box .feed-reply {
  color: var(--cyan);
  line-height: 1.45;
  padding-left: 8px;
  border-left: 2px solid var(--cyan);
}

.kol-progress-box {
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(148, 163, 184, 0.1);
}

.kol-progress-box h4 {
  display: flex;
  justify-content: space-between;
  font: 500 10.5px var(--mono);
  color: var(--text-3);
  text-transform: uppercase;
  margin-bottom: 6px;
}

.kol-progress-bar {
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  overflow: hidden;
}

.kol-progress-bar i {
  display: block;
  height: 100%;
  width: 100%;
  background: linear-gradient(90deg, var(--violet), var(--cyan));
}

/* ------------------------------------------------------------------------------
   6. Screen 5: Ops Agent (Enterprise Modules & Workflows)
   ------------------------------------------------------------------------------ */
.hud-ops-wrap {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.ops-modules-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.ops-mod {
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(148, 163, 184, 0.12);
  display: flex;
  flex-direction: column;
}

.ops-mod .lbl {
  font: 500 10px var(--mono);
  color: var(--text-3);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.ops-mod .val {
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  margin: 3px 0 2px;
}

.ops-mod .note {
  font: 500 11px var(--mono);
  color: var(--green);
}

.ops-mod .note.warn {
  color: var(--amber);
}

.ops-flows-box {
  padding: 14px;
  border-radius: 12px;
  background: rgba(4, 7, 14, 0.85);
  border: 1px solid rgba(148, 163, 184, 0.12);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ops-flows-box h4 {
  font: 500 11px var(--mono);
  color: var(--text-3);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 2px;
}

.flow-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--text-2);
  padding: 6px 0;
  border-bottom: 1px dashed rgba(148, 163, 184, 0.1);
}

.flow-item:last-child {
  border-bottom: 0;
}

.flow-item .f-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.flow-item .f-dot.green { background: var(--green); box-shadow: 0 0 6px var(--green); }
.flow-item .f-dot.cyan { background: var(--cyan); box-shadow: 0 0 6px var(--cyan); }
.flow-item .f-dot.amber { background: var(--amber); box-shadow: 0 0 6px var(--amber); }

.flow-item .f-stat {
  margin-left: auto;
  font: 500 11px var(--mono);
  color: var(--text-3);
  background: rgba(255, 255, 255, 0.04);
  padding: 2px 6px;
  border-radius: 4px;
}

/* ------------------------------------------------------------------------------
   6. Studio Agent (All-in-One AI Video Studio - MeFun AI)
   ------------------------------------------------------------------------------ */
.hud-studio {
  background: rgba(8, 12, 22, 0.96);
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 18px;
  box-shadow: 0 24px 60px -15px rgba(0, 0, 0, 0.8), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.hud-studio-wrap {
  padding: 13px 16px;
  display: flex;
  flex-direction: column;
  gap: 9px;
}

/* Modes Toolbar */
.studio-modes-bar {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 1px;
}
.studio-modes-bar::-webkit-scrollbar { display: none; }

.studio-mode-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 999px;
  font: 500 11px var(--sans);
  color: var(--text-3);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(148, 163, 184, 0.16);
  white-space: nowrap;
  transition: all 0.2s ease;
  user-select: none;
}

.studio-mode-pill.is-active,
.studio-mode-pill:hover {
  color: #fff;
  border-color: var(--cyan);
  background: rgba(34, 211, 238, 0.12);
  box-shadow: 0 0 12px rgba(34, 211, 238, 0.2);
}

.studio-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 8px var(--cyan);
}

/* Video Viewport / Canvas */
.studio-viewport {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.2);
  background: #080c16;
  height: 195px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 9px 12px;
  box-shadow: inset 0 0 40px rgba(0, 0, 0, 0.6);
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.studio-viewport:hover {
  border-color: rgba(34, 211, 238, 0.4);
  box-shadow: inset 0 0 30px rgba(0, 0, 0, 0.3), 0 8px 24px rgba(34, 211, 238, 0.15);
}

.studio-canvas-backdrop {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.studio-img-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 32%;
  display: block;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.studio-viewport:hover .studio-img-bg {
  transform: scale(1.035);
}

.studio-img-overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(8, 12, 22, 0.12) 0%, rgba(8, 12, 22, 0.58) 80%, rgba(8, 12, 22, 0.82) 100%),
              linear-gradient(180deg, rgba(8, 12, 22, 0.55) 0%, transparent 28%, transparent 72%, rgba(8, 12, 22, 0.8) 100%);
  pointer-events: none;
}

.studio-svg-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.studio-scanline {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 0%, rgba(34, 211, 238, 0.08) 50%, transparent 100%);
  background-size: 100% 8px;
  animation: scanSweep 3s linear infinite;
  pointer-events: none;
}

@keyframes scanSweep {
  0% { transform: translateY(-100%); }
  100% { transform: translateY(100%); }
}

/* Viewport HUD Overlays */
.viewport-hud-top,
.viewport-hud-bottom {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.v-badge {
  font: 500 10.5px var(--mono);
  padding: 3px 8px;
  border-radius: 6px;
  background: rgba(4, 7, 14, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-2);
  backdrop-filter: blur(8px);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  letter-spacing: 0.02em;
}

.v-badge.rec {
  color: #fff;
  border-color: rgba(239, 68, 68, 0.4);
}

.rec-blink {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #ef4444;
  box-shadow: 0 0 8px #ef4444;
  animation: blinkRec 1.2s infinite;
}

@keyframes blinkRec {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.v-badge.engine {
  color: var(--cyan);
  border-color: rgba(34, 211, 238, 0.3);
}

.v-badge.time {
  color: #fff;
}

.v-badge.cam {
  color: var(--text-2);
}

/* Center Play Control */
.viewport-center-play {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin: auto 0;
  text-decoration: none;
}

.v-play-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(15, 23, 42, 0.75);
  border: 1.5px solid var(--cyan);
  color: var(--cyan);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 20px rgba(34, 211, 238, 0.45);
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.v-play-btn:hover {
  transform: scale(1.08);
  box-shadow: 0 0 28px rgba(34, 211, 238, 0.7);
}

.v-play-btn svg {
  margin-left: 2px;
}

.v-waves {
  display: flex;
  align-items: center;
  gap: 3px;
  height: 20px;
}

.v-waves i {
  display: inline-block;
  width: 3px;
  height: 6px;
  background: var(--cyan);
  border-radius: 2px;
  opacity: 0.8;
  animation: wavePulse 1.2s ease-in-out infinite;
}

.v-waves i:nth-child(1) { animation-delay: 0.1s; height: 8px; }
.v-waves i:nth-child(2) { animation-delay: 0.3s; height: 16px; }
.v-waves i:nth-child(3) { animation-delay: 0.5s; height: 20px; }
.v-waves i:nth-child(4) { animation-delay: 0.2s; height: 12px; }
.v-waves i:nth-child(5) { animation-delay: 0.4s; height: 7px; }

@keyframes wavePulse {
  0%, 100% { transform: scaleY(0.4); opacity: 0.4; }
  50% { transform: scaleY(1); opacity: 1; }
}

/* Timeline */
.studio-timeline {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 7px 12px;
  border-radius: 9px;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(148, 163, 184, 0.12);
}

.timeline-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font: 500 10.5px var(--mono);
  color: var(--text-3);
}

.timeline-track {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.timeline-segments {
  display: flex;
  gap: 4px;
}

.t-seg {
  font: 500 9px var(--mono);
  color: var(--text-3);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(148, 163, 184, 0.1);
  padding: 2px 6px;
  border-radius: 4px;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.timeline-progress-bar {
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
  position: relative;
}

.timeline-progress-bar i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--cyan), var(--violet));
  border-radius: 999px;
  transition: width 1.4s cubic-bezier(0.2, 0.8, 0.2, 1);
  box-shadow: 0 0 10px var(--cyan);
}

/* Prompt Terminal Box */
.studio-prompt-box {
  background: rgba(10, 15, 28, 0.85);
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 9px;
  padding: 7px 12px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.prompt-text {
  font-size: 11.5px;
  line-height: 1.4;
  color: var(--text-2);
}

.prompt-caret {
  color: var(--cyan);
  font-weight: 700;
  margin-right: 4px;
}

.prompt-lbl {
  color: var(--cyan);
  font-weight: 600;
  margin-right: 6px;
}

.prompt-body {
  color: var(--text-2);
}

.prompt-chips {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
}

.p-chip {
  font: 500 9.5px var(--mono);
  color: var(--text-3);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(148, 163, 184, 0.12);
  padding: 2px 6px;
  border-radius: 4px;
}

.p-chip-ok {
  color: var(--green);
  border-color: rgba(52, 211, 153, 0.25);
  background: rgba(52, 211, 153, 0.06);
}

/* Studio Launch Button */
.studio-footer-cta {
  margin-top: 2px;
}

.studio-launch-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 11px 18px;
  border-radius: 10px;
  font: 600 13px var(--sans);
  text-decoration: none;
  color: #fff;
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.22), rgba(139, 92, 246, 0.32));
  border: 1px solid var(--cyan);
  box-shadow: 0 4px 18px rgba(34, 211, 238, 0.25);
  transition: all 0.25s var(--ease);
}

.studio-launch-btn:hover {
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.35), rgba(139, 92, 246, 0.45));
  box-shadow: 0 6px 24px rgba(34, 211, 238, 0.45);
  transform: translateY(-1px);
}

.launch-arrow {
  color: var(--cyan);
  font-size: 15px;
  transition: transform 0.2s ease;
}

.studio-launch-btn:hover .launch-arrow {
  transform: translate(2px, -2px);
}

/* ------------------------------------------------------------------------------
   7. Mobile & Tablet Responsiveness for HUDs
   ------------------------------------------------------------------------------ */
@media (max-width: 860px) {
  .hud {
    min-height: auto;
  }

  .hud-stream-body {
    grid-template-columns: 130px 1fr;
    gap: 12px;
  }

  .ops-modules-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .channel-stats-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .hud-kpis {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .hud-stream-body {
    grid-template-columns: 1fr;
  }

  .stream-avatar-box {
    min-height: 160px;
  }

  .ops-modules-grid {
    grid-template-columns: 1fr;
  }

  .flow-item {
    font-size: 12px;
  }

  .studio-viewport {
    height: 165px;
  }
}
