/* FlyPane Control Plane Dashboard Styles */
.dash-wrap {
  max-width: 1240px;
  margin: 0 auto;
  padding: 24px 20px 60px;
}
.dash-nav {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(14px);
  background: rgba(7, 11, 20, 0.88);
  border-bottom: 1px solid var(--border);
}
.dash-nav-inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 20px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.driver-pill {
  font-family: var(--mono);
  font-size: 11px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.12);
  border: 1px solid rgba(34, 211, 238, 0.35);
  color: var(--accent-cyan);
  text-transform: uppercase;
}
.auth-card {
  max-width: 420px;
  margin: 64px auto;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 28px;
}
.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin-bottom: 18px;
  background: #070b14;
  padding: 4px;
  border-radius: 10px;
  border: 1px solid var(--border);
}
.auth-tab {
  border: none;
  background: transparent;
  color: var(--text-muted);
  padding: 8px;
  border-radius: 7px;
  font-weight: 600;
  cursor: pointer;
}
.auth-tab.active {
  background: var(--accent);
  color: #031912;
}

.dash-layout {
  display: grid;
  grid-template-columns: 310px 1fr;
  gap: 20px;
  align-items: start;
}
.fleet-panel {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 16px;
}
.fleet-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}
.fleet-list {
  display: grid;
  gap: 10px;
}
.vm-item {
  background: #0a101f;
  border: 1px solid var(--border);
  border-radius: 11px;
  padding: 12px;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.vm-item:hover { border-color: rgba(148, 163, 184, 0.4); }
.vm-item.active {
  border-color: var(--border-strong);
  background: rgba(16, 185, 129, 0.08);
}
.vm-item-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}
.vm-name { font-weight: 700; font-size: 14px; }
.vm-meta { font-size: 12px; color: var(--text-muted); }

.status-dot {
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
}
.status-dot.running { background: rgba(16, 185, 129, 0.16); color: var(--accent-bright); }
.status-dot.paused_hitl { background: rgba(251, 191, 36, 0.18); color: var(--amber); }
.status-dot.stopped { background: rgba(148, 163, 184, 0.16); color: var(--text-muted); }

.workspace {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
}
.ws-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.ws-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.hitl-banner {
  background: rgba(251, 191, 36, 0.12);
  border-bottom: 1px solid rgba(251, 191, 36, 0.35);
  padding: 12px 20px;
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  color: #fde68a;
  font-size: 13.5px;
}
.hitl-banner.show { display: flex; }

.ws-tabs {
  display: flex;
  gap: 4px;
  padding: 10px 20px 0;
  border-bottom: 1px solid var(--border);
  background: #0c1324;
  overflow-x: auto;
}
.ws-tab {
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--text-muted);
  padding: 10px 14px;
  font-weight: 600;
  font-size: 13.5px;
  cursor: pointer;
}
.ws-tab.active {
  color: var(--accent-bright);
  border-bottom-color: var(--accent-bright);
}
.ws-pane {
  padding: 20px;
  display: none;
}
.ws-pane.active { display: block; }

.stat-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 16px;
}
.stat-box {
  background: #0a101f;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 11px 13px;
}
.stat-box .k { font-size: 11px; color: var(--text-muted); }
.stat-box .v { font-size: 15px; font-weight: 700; margin-top: 2px; }

.preview-frame {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: #050811;
  overflow: hidden;
  min-height: 380px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.preview-frame img {
  width: 100%;
  height: auto;
  display: block;
}
.preview-frame iframe {
  width: 100%;
  height: 480px;
  border: none;
  display: block;
}

.terminal-out {
  background: #050811;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px;
  font-family: var(--mono);
  font-size: 12.5px;
  color: #cbd5e1;
  min-height: 200px;
  max-height: 360px;
  overflow: auto;
  white-space: pre-wrap;
  margin-top: 12px;
}
.code-block {
  background: #050811;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px;
  font-family: var(--mono);
  font-size: 12px;
  color: #a7f3d0;
  overflow-x: auto;
  white-space: pre;
  margin: 8px 0 16px;
}
.empty-state {
  padding: 56px 24px;
  text-align: center;
  color: var(--text-muted);
}

@media (max-width: 920px) {
  .dash-layout { grid-template-columns: 1fr; }
  .stat-row { grid-template-columns: 1fr 1fr; }
}
