:root {
  --hub-bg: #141518;
  --hub-sidebar: #1a1b1f;
  --hub-sidebar-border: #28292e;
  --hub-accent: #b38b47;
  --hub-accent-hover: #c49d58;
  --hub-text: #f0f0f2;
  --hub-text-muted: #8a8b94;
}

.hub-container {
  display: flex;
  height: 100vh;
  width: 100vw;
  overflow: hidden;
  background: var(--hub-bg);
  color: var(--hub-text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* Sidebar Navigation */
.hub-nav {
  width: 230px;
  flex: 0 0 230px;
  background: var(--hub-sidebar);
  border-right: 1px solid var(--hub-sidebar-border);
  display: flex;
  flex-direction: column;
  transition: width 0.22s cubic-bezier(0.16, 1, 0.3, 1), flex-basis 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 100;
  user-select: none;
}

.hub-nav.collapsed {
  width: 58px;
  flex: 0 0 58px;
}

.hub-nav-header {
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 12px;
  border-bottom: 1px solid var(--hub-sidebar-border);
}

.hub-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  overflow: hidden;
  white-space: nowrap;
}

.hub-logo {
  width: 26px;
  height: 26px;
  border-radius: 4px;
  object-fit: contain;
  flex-shrink: 0;
}

.hub-brand-text {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.hub-title {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--hub-text);
}

.hub-subtitle {
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--hub-accent);
}

.hub-nav.collapsed .hub-brand-text,
.hub-nav.collapsed .hub-nav-label,
.hub-nav.collapsed .hub-nav-badge,
.hub-nav.collapsed .hub-status-text {
  display: none;
}

.hub-toggle-btn {
  background: transparent;
  border: none;
  color: var(--hub-text-muted);
  cursor: pointer;
  padding: 6px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.15s ease;
}

.hub-toggle-btn:hover {
  color: var(--hub-text);
  background: rgba(255, 255, 255, 0.05);
}

.hub-nav-items {
  flex: 1;
  padding: 12px 8px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.hub-nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 9px 12px;
  background: transparent;
  border: none;
  border-radius: 6px;
  color: var(--hub-text-muted);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  text-align: left;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.hub-nav.collapsed .hub-nav-item {
  justify-content: center;
  padding: 9px 0;
}

.hub-nav-item:hover {
  background: rgba(255, 255, 255, 0.04);
  color: var(--hub-text);
}

.hub-nav-item.active {
  background: rgba(179, 139, 71, 0.15);
  color: #ffffff;
  font-weight: 600;
}

.hub-nav-item.active svg {
  color: var(--hub-accent);
}

.hub-nav-icon {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hub-nav-badge {
  margin-left: auto;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 2px 6px;
  border-radius: 4px;
}

.hub-nav-badge.live {
  background: rgba(43, 94, 59, 0.25);
  color: #4ade80;
}

.hub-nav-badge.ready {
  background: rgba(179, 139, 71, 0.2);
  color: var(--hub-accent);
}

.hub-nav-badge.pending {
  background: rgba(255, 255, 255, 0.06);
  color: var(--hub-text-muted);
}

.hub-nav-footer {
  padding: 12px;
  border-top: 1px solid var(--hub-sidebar-border);
}

.hub-status-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  color: var(--hub-text-muted);
}

.hub-status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 6px rgba(74, 222, 128, 0.5);
  flex-shrink: 0;
}

/* Main Hub Content Area */
.hub-content {
  flex: 1;
  height: 100vh;
  min-width: 0;
  overflow: hidden;
  position: relative;
}

.hub-view {
  display: none;
  width: 100%;
  height: 100%;
}

.hub-view.active {
  display: flex;
  flex-direction: column;
}

/* Existing .app integration */
.hub-view#view-editor .app {
  width: 100%;
  height: 100%;
}

/* Staging Screens for Steps 2, 3, 4 */
.hub-staging-wrap {
  flex: 1;
  overflow-y: auto;
  padding: 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: #18191c;
}

.hub-staging-card {
  max-width: 580px;
  width: 100%;
  background: #232428;
  border: 1px solid #38393f;
  border-radius: 8px;
  padding: 32px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.35);
}

.hub-staging-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
}

.hub-staging-icon {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  background: rgba(179, 139, 71, 0.15);
  color: var(--hub-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.hub-staging-title {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  color: #ffffff;
}

.hub-staging-subtitle {
  font-size: 12px;
  color: var(--hub-accent);
  margin-top: 2px;
}

.hub-staging-desc {
  font-size: 13.5px;
  line-height: 1.55;
  color: #b5b6be;
  margin: 0 0 24px 0;
}

.hub-staging-checklist {
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid #33343a;
  border-radius: 6px;
  padding: 16px;
  margin-bottom: 24px;
}

.hub-staging-check-title {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--hub-text-muted);
  margin-bottom: 12px;
}

.hub-staging-check-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12.5px;
  color: #e0e1e6;
  margin-bottom: 8px;
}

.hub-staging-check-item:last-child {
  margin-bottom: 0;
}

.hub-staging-check-item svg {
  color: #4ade80;
  flex-shrink: 0;
}

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

.hub-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: #2b2c31;
  border: 1px solid #44454d;
  color: #ffffff;
  border-radius: 6px;
  font-size: 12.5px;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.15s ease;
}

.hub-btn:hover {
  border-color: var(--hub-accent);
  color: var(--hub-accent);
}

.hub-btn-primary {
  background: var(--hub-accent);
  border-color: var(--hub-accent);
  color: #1a1b1f;
  font-weight: 600;
}

.hub-btn-primary:hover {
  background: var(--hub-accent-hover);
  border-color: var(--hub-accent-hover);
  color: #1a1b1f;
}
