/* Hub Dashboard Stylesheet */
.hub-body {
  background: radial-gradient(circle at 10% 20%, rgba(37, 99, 235, 0.08) 0%, transparent 40%),
              radial-gradient(circle at 90% 80%, rgba(225, 29, 72, 0.08) 0%, transparent 40%),
              var(--bg-main);
  min-height: 100vh;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Header */
.hub-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
}

.logo-area {
  display: flex;
  align-items: center;
  gap: 16px;
}

.logo-icon {
  font-size: 28px;
  background: linear-gradient(135deg, #3b82f6 0%, #06b6d4 100%);
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  box-shadow: 0 4px 16px rgba(6, 182, 212, 0.3);
}

.hub-title {
  font-family: var(--font-body);
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.5px;
  color: #fff;
}

.hub-subtitle {
  font-size: 13px;
  color: var(--text-muted);
}

.live-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #34d399;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1px;
}

.live-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: #34d399;
  box-shadow: 0 0 10px #34d399;
  animation: liveBlink 1.5s infinite;
}

/* Mode Switcher */
.mode-switcher-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  gap: 16px;
  flex-wrap: wrap;
}

.mode-switcher-label {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-muted);
}

.mode-tabs {
  display: flex;
  gap: 12px;
  flex: 1;
  max-width: 680px;
}

.mode-tab {
  flex: 1;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  text-align: left;
  transition: all 0.2s;
  color: #fff;
}

.mode-tab .mode-icon {
  font-size: 24px;
}

.mode-tab strong {
  display: block;
  font-size: 13px;
  margin-bottom: 2px;
}

.mode-tab small {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.2;
}

.mode-tab:hover {
  background: rgba(255, 255, 255, 0.08);
}

.mode-tab.active {
  background: linear-gradient(135deg, rgba(2, 132, 199, 0.25) 0%, rgba(14, 165, 233, 0.1) 100%);
  border-color: #0284c7;
  box-shadow: 0 0 16px rgba(2, 132, 199, 0.3);
}

.mode-tab.active strong {
  color: #38bdf8;
}

.btn-secondary-link.highlight {
  background: rgba(2, 132, 199, 0.15);
  border-color: rgba(56, 189, 248, 0.3);
  color: #38bdf8;
}

.btn-secondary-link.highlight:hover {
  background: rgba(2, 132, 199, 0.25);
  color: #fff;
}


/* Hub Grid */
.hub-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

@media (min-width: 1024px) {
  .hub-grid {
    grid-template-columns: 420px 1fr;
  }
}

/* Hub Card */
.hub-card {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.card-header {
  display: flex;
  align-items: center;
  gap: 14px;
}

.badge-icon {
  font-size: 24px;
  background: rgba(255, 255, 255, 0.05);
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-subtle);
}

.card-header h2 {
  font-size: 18px;
  font-weight: 700;
  color: #fff;
}

.card-header p {
  font-size: 13px;
  color: var(--text-muted);
}

/* Network Selector */
.network-selector-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.network-selector-group label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
}

.form-select {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  padding: 10px 14px;
  color: #fff;
  font-size: 14px;
  outline: none;
  cursor: pointer;
}

.form-select option {
  background: #111827;
  color: #fff;
}

/* QR Code Display */
.qr-display-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  background: rgba(0, 0, 0, 0.35);
  padding: 20px;
  border-radius: 14px;
  border: 1px solid var(--border-subtle);
}

.qr-wrapper {
  position: relative;
  background: #ffffff;
  padding: 12px;
  border-radius: 16px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
}

.qr-wrapper img {
  width: 220px;
  height: 220px;
  display: block;
  border-radius: 8px;
}

.qr-overlay-brand {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: #0f172a;
  color: #38bdf8;
  font-family: var(--font-score);
  font-weight: 800;
  font-size: 12px;
  letter-spacing: 1px;
  padding: 4px 8px;
  border-radius: 6px;
  border: 2px solid #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.url-copy-box {
  display: flex;
  width: 100%;
  gap: 8px;
}

.url-copy-box input {
  flex: 1;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 8px 12px;
  color: #94a3b8;
  font-size: 13px;
  outline: none;
  font-family: monospace;
}

.btn-copy {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid var(--border-subtle);
  color: #fff;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s;
  white-space: nowrap;
}

.btn-copy:active {
  transform: scale(0.95);
}

.btn-copy.btn-primary {
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  border: none;
  color: #fff;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35);
}

.qr-tip {
  font-size: 12px;
  color: var(--text-dim);
  line-height: 1.6;
  background: rgba(255, 255, 255, 0.03);
  padding: 10px 14px;
  border-radius: 8px;
  border-left: 3px solid var(--accent-amber);
}

.btn-secondary-link {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  text-decoration: none;
  padding: 10px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  transition: all 0.2s;
}

.btn-secondary-link:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

/* OBS Section */
.style-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.style-tab {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.style-tab.active {
  background: rgba(37, 99, 235, 0.2);
  border-color: #3b82f6;
  color: #60a5fa;
}

.obs-steps-panel {
  background: rgba(0, 0, 0, 0.25);
  padding: 16px;
  border-radius: 12px;
  border: 1px solid var(--border-subtle);
}

.obs-steps-panel h3 {
  font-size: 14px;
  margin-bottom: 10px;
  color: #e2e8f0;
}

.steps-list {
  padding-left: 20px;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.8;
}

.steps-list strong {
  color: #fff;
}

/* Live Preview Box */
.live-preview-box {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.preview-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.preview-label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--text-muted);
}

.preview-link {
  font-size: 12px;
  color: #60a5fa;
  text-decoration: none;
}

.preview-iframe-wrapper {
  position: relative;
  width: 100%;
  height: 220px;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border-subtle);
  background: #020617 url("data:image/svg+xml,%3Csvg width='32' height='32' viewBox='0 0 32 32' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0 0h16v16H0V0zm16 16h16v16H16V16z' fill='%230b1120' fill-rule='evenodd'/%3E%3C/svg%3E");
}

.preview-iframe-wrapper iframe {
  width: 100%;
  height: 100%;
  border: none;
  pointer-events: none;
}

/* Quick Tester Bar (Bottom) */
.quick-tester-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px;
  flex-wrap: wrap;
  gap: 12px;
}

.tester-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-muted);
}

.tester-controls {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.test-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-subtle);
  color: #fff;
  padding: 6px 14px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
}

.test-btn:active {
  transform: scale(0.95);
}

.test-btn.timer {
  color: #34d399;
}
.test-btn.undo {
  color: #fbbf24;
}
.test-btn.reset {
  color: #f87171;
}
