/* ============================================
   FACTORY DASHBOARD - INDUSTRIAL COMMAND CENTER
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;600;700&family=Plus+Jakarta+Sans:wght@400;500;600;700&display=swap');

/* CSS Variables */
:root {
  /* Background layers */
  --bg-deepest: #08080a;
  --bg-deep: #0d0d10;
  --bg-base: #121215;
  --bg-elevated: #18181c;
  --bg-surface: #1e1e23;
  --bg-hover: #252529;

  /* Accent colors - Industrial amber/gold */
  --accent-primary: #f59e0b;
  --accent-primary-dim: rgba(245, 158, 11, 0.15);
  --accent-primary-glow: rgba(245, 158, 11, 0.4);

  /* Status colors - refined palette */
  --status-active: #22d3ee;
  --status-active-bg: rgba(34, 211, 238, 0.12);
  --status-active-border: rgba(34, 211, 238, 0.3);

  --status-idle: #a78bfa;
  --status-idle-bg: rgba(167, 139, 250, 0.12);
  --status-idle-border: rgba(167, 139, 250, 0.3);

  --status-pending: #fbbf24;
  --status-pending-bg: rgba(251, 191, 36, 0.12);

  --status-completed: #34d399;
  --status-completed-bg: rgba(52, 211, 153, 0.12);

  --status-error: #fb7185;
  --status-error-bg: rgba(251, 113, 133, 0.12);
  --status-error-border: rgba(251, 113, 133, 0.3);

  --status-warning: #fb923c;
  --status-warning-bg: rgba(251, 146, 60, 0.12);

  /* Text hierarchy */
  --text-primary: #f4f4f5;
  --text-secondary: #a1a1aa;
  --text-tertiary: #71717a;
  --text-muted: #52525b;

  /* Borders */
  --border-subtle: rgba(255, 255, 255, 0.06);
  --border-default: rgba(255, 255, 255, 0.1);
  --border-strong: rgba(255, 255, 255, 0.15);

  /* Typography */
  --font-mono: 'JetBrains Mono', 'SF Mono', 'Monaco', monospace;
  --font-sans: 'Plus Jakarta Sans', -apple-system, sans-serif;

  /* Spacing */
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 12px;
  --space-lg: 16px;
  --space-xl: 24px;
  --space-2xl: 32px;

  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition-base: 0.2s ease;
  --transition-slow: 0.3s ease;
}

/* Reset & Base */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-sans);
  background: var(--bg-deepest);
  color: var(--text-primary);
  min-height: 100vh;
  line-height: 1.5;
}

/* Subtle grid pattern overlay */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
  z-index: 0;
}

/* ============================================
   HEADER
   ============================================ */
header {
  background: var(--bg-deep);
  border-bottom: 1px solid var(--border-subtle);
  padding: var(--space-lg) var(--space-xl);
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(12px);
}

.header-content {
  max-width: 1800px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}

header h1 {
  font-family: var(--font-mono);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

header h1::before {
  content: '';
  width: 8px;
  height: 8px;
  background: var(--accent-primary);
  border-radius: 2px;
  box-shadow: 0 0 12px var(--accent-primary-glow);
  animation: pulse-glow 2s ease-in-out infinite;
}

@keyframes pulse-glow {
  0%, 100% { opacity: 1; box-shadow: 0 0 12px var(--accent-primary-glow); }
  50% { opacity: 0.7; box-shadow: 0 0 20px var(--accent-primary-glow); }
}

.header-actions {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
}

.last-updated {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-tertiary);
  letter-spacing: 0.02em;
}

#lastUpdated {
  color: var(--text-secondary);
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
  font-family: var(--font-sans);
  font-size: 0.8125rem;
  font-weight: 600;
  padding: var(--space-sm) var(--space-lg);
  border: 1px solid transparent;
  border-radius: 6px;
  cursor: pointer;
  transition: all var(--transition-base);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent-primary);
  color: #000;
  border-color: var(--accent-primary);
}

.btn-primary:hover {
  background: #d97706;
  border-color: #d97706;
  box-shadow: 0 0 20px var(--accent-primary-dim);
}

.btn-secondary {
  background: var(--bg-surface);
  color: var(--text-secondary);
  border-color: var(--border-default);
}

.btn-secondary:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
  border-color: var(--border-strong);
}

.btn-quick {
  background: var(--bg-elevated);
  color: var(--text-secondary);
  border: 1px solid var(--border-default);
  padding: var(--space-sm) var(--space-md);
}

.btn-quick:hover {
  background: var(--bg-hover);
  color: var(--accent-primary);
  border-color: var(--accent-primary);
}

/* Factory action buttons */
.factory-actions {
  display: flex;
  gap: 6px;
  opacity: 0.7;
  transition: opacity var(--transition-base);
}

.factory-card:hover .factory-actions {
  opacity: 1;
}

.btn-stop,
.btn-restart,
.btn-launch,
.btn-delete {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 600;
  padding: 5px 10px;
  border-radius: 4px;
  cursor: pointer;
  transition: all var(--transition-base);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.btn-stop {
  background: var(--status-error-bg);
  color: var(--status-error);
  border: 1px solid var(--status-error-border);
}

.btn-stop:hover {
  background: rgba(251, 113, 133, 0.25);
  box-shadow: 0 0 12px var(--status-error-bg);
}

.btn-restart {
  background: var(--status-pending-bg);
  color: var(--status-pending);
  border: 1px solid rgba(251, 191, 36, 0.3);
}

.btn-restart:hover {
  background: rgba(251, 191, 36, 0.25);
  box-shadow: 0 0 12px var(--status-pending-bg);
}

.btn-launch {
  background: var(--status-completed-bg);
  color: var(--status-completed);
  border: 1px solid rgba(52, 211, 153, 0.3);
}

.btn-launch:hover {
  background: rgba(52, 211, 153, 0.25);
  box-shadow: 0 0 12px var(--status-completed-bg);
}

.btn-delete {
  background: transparent;
  color: var(--text-muted);
  border: 1px solid var(--border-subtle);
  padding: 5px 8px;
}

.btn-delete:hover {
  background: var(--status-error-bg);
  color: var(--status-error);
  border-color: var(--status-error-border);
}

/* ============================================
   MAIN CONTENT
   ============================================ */
main {
  max-width: 1800px;
  margin: 0 auto;
  padding: var(--space-xl);
  position: relative;
  z-index: 1;
}

/* ============================================
   SUMMARY STATS - Command Center Style
   ============================================ */
.summary-section {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: var(--space-lg);
  margin-bottom: var(--space-2xl);
}

.stat-card {
  background: var(--bg-base);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  padding: var(--space-xl) var(--space-lg);
  text-align: center;
  position: relative;
  overflow: hidden;
  transition: all var(--transition-base);
}

.stat-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--border-subtle);
  transition: background var(--transition-base);
}

.stat-card:hover {
  border-color: var(--border-default);
  transform: translateY(-2px);
}

.stat-value {
  font-family: var(--font-mono);
  font-size: 2.5rem;
  font-weight: 700;
  line-height: 1;
  margin-bottom: var(--space-sm);
  color: var(--text-primary);
}

.stat-label {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 500;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

/* Stat card accent colors */
.stat-active::before { background: var(--status-active); }
.stat-active .stat-value { color: var(--status-active); }
.stat-active:hover { border-color: var(--status-active-border); }

.stat-pending::before { background: var(--status-pending); }
.stat-pending .stat-value { color: var(--status-pending); }
.stat-pending:hover { border-color: rgba(251, 191, 36, 0.3); }

.stat-completed::before { background: var(--status-completed); }
.stat-completed .stat-value { color: var(--status-completed); }
.stat-completed:hover { border-color: rgba(52, 211, 153, 0.3); }

/* ============================================
   SERVERS GRID
   ============================================ */
.servers-grid {
  display: flex;
  flex-direction: column;
  gap: var(--space-2xl);
}

.server-section {
  background: var(--bg-base);
  border: 1px solid var(--border-subtle);
  border-radius: 16px;
  padding: var(--space-xl);
  position: relative;
}

.server-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 24px;
  right: 24px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent-primary), transparent);
  opacity: 0.3;
}

.server-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-xl);
  padding-bottom: var(--space-lg);
  border-bottom: 1px solid var(--border-subtle);
}

.server-title {
  display: flex;
  align-items: baseline;
  gap: var(--space-md);
}

.server-title h2 {
  font-family: var(--font-mono);
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
}

.server-ip {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  padding: 2px 8px;
  background: var(--bg-elevated);
  border-radius: 4px;
}

.server-status {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  position: relative;
}

.status-dot.online {
  background: var(--status-completed);
  box-shadow: 0 0 8px rgba(52, 211, 153, 0.5);
}

.status-dot.online::after {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  border: 1px solid var(--status-completed);
  opacity: 0.3;
  animation: ping 2s ease-out infinite;
}

@keyframes ping {
  0% { transform: scale(1); opacity: 0.3; }
  100% { transform: scale(1.8); opacity: 0; }
}

.status-dot.offline {
  background: var(--status-error);
  box-shadow: 0 0 8px rgba(251, 113, 133, 0.5);
}

/* ============================================
   FACTORIES GRID
   ============================================ */
.factories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: var(--space-lg);
}

.factory-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  padding: var(--space-lg);
  transition: all var(--transition-base);
  position: relative;
}

.factory-card:hover {
  border-color: var(--border-default);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
}

.factory-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: var(--space-lg);
  gap: var(--space-md);
}

.factory-title-row {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  flex: 1;
  min-width: 0;
}

.factory-name {
  font-family: var(--font-sans);
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.factory-stats {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-md);
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  margin-top: var(--space-xs);
}

.factory-stat {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 2px 0;
}

.factory-stat::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 2px;
}

.factory-stat.pending { color: var(--status-pending); }
.factory-stat.pending::before { background: var(--status-pending); }

.factory-stat.processing { color: var(--status-active); }
.factory-stat.processing::before { background: var(--status-active); }

.factory-stat.completed { color: var(--status-completed); }
.factory-stat.completed::before { background: var(--status-completed); }

.factory-stat.failed { color: var(--status-error); }
.factory-stat.failed::before { background: var(--status-error); }

/* Factory API Key Display */
.factory-api-key {
  font-family: var(--font-mono);
  font-size: 0.625rem;
  margin: var(--space-md) 0;
  padding: var(--space-sm) var(--space-md);
  background: var(--bg-surface);
  border-radius: 6px;
  border: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  overflow: hidden;
}

.api-key-label {
  color: var(--text-muted);
  white-space: nowrap;
  flex-shrink: 0;
}

.api-key-value {
  color: var(--status-active);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  user-select: all;
  cursor: text;
}

.api-key-value.not-found {
  color: var(--status-error);
  font-style: italic;
}

/* ============================================
   WORKERS
   ============================================ */
.workers-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-sm);
}

.worker-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: var(--space-md);
  cursor: pointer;
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

.worker-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: var(--text-muted);
  transition: background var(--transition-base);
}

.worker-card:hover {
  border-color: var(--accent-primary);
  background: var(--bg-hover);
  transform: translateY(-1px);
}

.worker-card:hover::before {
  background: var(--accent-primary);
}

.worker-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-xs);
}

.worker-num {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.worker-status {
  font-family: var(--font-mono);
  font-size: 0.625rem;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.worker-status.active {
  background: var(--status-active-bg);
  color: var(--status-active);
  box-shadow: 0 0 8px var(--status-active-bg);
}

.worker-status.idle {
  background: var(--status-idle-bg);
  color: var(--status-idle);
}

.worker-status.crashed,
.worker-status.error {
  background: var(--status-error-bg);
  color: var(--status-error);
}

.worker-status.rate_limited {
  background: var(--status-warning-bg);
  color: var(--status-warning);
}

.worker-status.unknown {
  background: rgba(113, 113, 122, 0.15);
  color: var(--text-tertiary);
}

/* Worker card left border colors based on status */
.worker-card:has(.worker-status.active)::before {
  background: var(--status-active);
}

.worker-card:has(.worker-status.idle)::before {
  background: var(--status-idle);
}

.worker-card:has(.worker-status.crashed)::before,
.worker-card:has(.worker-status.error)::before {
  background: var(--status-error);
}

.worker-card:has(.worker-status.rate_limited)::before {
  background: var(--status-warning);
}

/* Orchestrator Card - Special styling */
.orchestrator-card {
  background: linear-gradient(135deg, var(--bg-surface) 0%, rgba(245, 158, 11, 0.05) 100%);
  border-color: rgba(245, 158, 11, 0.2);
}

.orchestrator-card::before {
  background: var(--accent-primary) !important;
}

.orchestrator-card:hover {
  border-color: var(--accent-primary);
  box-shadow: 0 0 16px var(--accent-primary-dim);
}

.orchestrator-card .worker-num {
  color: var(--accent-primary);
}

.worker-task {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ============================================
   MODAL
   ============================================ */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: var(--space-xl);
}

.modal-content {
  background: var(--bg-base);
  border: 1px solid var(--border-default);
  border-radius: 16px;
  width: 100%;
  max-width: 700px;
  max-height: 90vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.5);
}

.modal-large {
  max-width: 900px;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-lg) var(--space-xl);
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-elevated);
}

.modal-header h2 {
  font-family: var(--font-mono);
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
}

.close-btn {
  background: transparent;
  border: none;
  color: var(--text-tertiary);
  font-size: 1.5rem;
  cursor: pointer;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  transition: all var(--transition-fast);
}

.close-btn:hover {
  color: var(--text-primary);
  background: var(--bg-hover);
}

.modal-body {
  padding: var(--space-xl);
  overflow-y: auto;
}

.modal-info {
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  padding: var(--space-md) var(--space-lg);
  border-radius: 8px;
  margin-bottom: var(--space-xl);
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  color: var(--text-secondary);
  line-height: 1.8;
}

.modal-info strong {
  color: var(--text-tertiary);
  font-weight: 500;
}

.quick-commands {
  margin-bottom: var(--space-xl);
}

.quick-commands h3,
.custom-command h3 {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: var(--space-md);
}

.quick-btns {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
}

.custom-command select,
.custom-command textarea {
  width: 100%;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: 8px;
  padding: var(--space-md);
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  margin-bottom: var(--space-md);
  transition: all var(--transition-fast);
}

.custom-command select:focus,
.custom-command textarea:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px var(--accent-primary-dim);
}

.custom-command textarea {
  resize: vertical;
  min-height: 80px;
}

.command-result {
  padding: var(--space-md) var(--space-lg);
  border-radius: 8px;
  margin-top: var(--space-lg);
  font-family: var(--font-mono);
  font-size: 0.8125rem;
}

.command-result.success {
  background: var(--status-completed-bg);
  border: 1px solid rgba(52, 211, 153, 0.3);
  color: var(--status-completed);
}

.command-result.error {
  background: var(--status-error-bg);
  border: 1px solid var(--status-error-border);
  color: var(--status-error);
}

.modal-footer {
  padding: var(--space-lg) var(--space-xl);
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-elevated);
  max-height: 300px;
  overflow-y: auto;
}

.modal-footer h3 {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: var(--space-md);
}

.worker-output,
.worker-output-full {
  background: var(--bg-deepest);
  border: 1px solid var(--border-subtle);
  padding: var(--space-md);
  border-radius: 8px;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-all;
  color: var(--text-tertiary);
  max-height: 200px;
  overflow-y: auto;
}

.worker-output-full {
  max-height: 60vh;
}

/* Custom scrollbar for output */
.worker-output::-webkit-scrollbar,
.worker-output-full::-webkit-scrollbar {
  width: 6px;
}

.worker-output::-webkit-scrollbar-track,
.worker-output-full::-webkit-scrollbar-track {
  background: transparent;
}

.worker-output::-webkit-scrollbar-thumb,
.worker-output-full::-webkit-scrollbar-thumb {
  background: var(--border-default);
  border-radius: 3px;
}

/* ============================================
   LOADING
   ============================================ */
.loading {
  text-align: center;
  padding: 60px var(--space-xl);
  color: var(--text-tertiary);
  font-family: var(--font-mono);
  font-size: 0.875rem;
}

.loading a {
  color: var(--accent-primary);
  text-decoration: none;
}

.loading a:hover {
  text-decoration: underline;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1200px) {
  .summary-section {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  html {
    font-size: 13px;
  }

  .header-content {
    flex-direction: column;
    gap: var(--space-md);
    text-align: center;
  }

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

  .stat-card {
    padding: var(--space-lg) var(--space-md);
  }

  .stat-value {
    font-size: 2rem;
  }

  .factories-grid {
    grid-template-columns: 1fr;
  }

  .workers-row {
    grid-template-columns: 1fr;
  }

  .modal-content {
    margin: var(--space-md);
    max-height: calc(100vh - 32px);
  }

  .factory-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .factory-actions {
    margin-top: var(--space-sm);
  }
}

@media (max-width: 480px) {
  .summary-section {
    grid-template-columns: 1fr;
  }

  main {
    padding: var(--space-lg);
  }
}

/* ============================================
   SELECTION & FOCUS
   ============================================ */
::selection {
  background: var(--accent-primary);
  color: #000;
}

:focus-visible {
  outline: 2px solid var(--accent-primary);
  outline-offset: 2px;
}

/* ============================================
   LOGIN PAGE STYLES
   ============================================ */
.login-container {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-xl);
}

.login-card {
  background: var(--bg-base);
  border: 1px solid var(--border-subtle);
  border-radius: 16px;
  padding: var(--space-2xl);
  width: 100%;
  max-width: 400px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.4);
}

.login-card h1 {
  font-family: var(--font-mono);
  font-size: 1.25rem;
  font-weight: 600;
  text-align: center;
  margin-bottom: var(--space-xl);
  color: var(--text-primary);
}

.login-card .form-group {
  margin-bottom: var(--space-lg);
}

.login-card label {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: var(--space-sm);
}

.login-card input {
  width: 100%;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: 8px;
  padding: var(--space-md);
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 0.875rem;
  transition: all var(--transition-fast);
}

.login-card input:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px var(--accent-primary-dim);
}

.login-card .btn {
  width: 100%;
  justify-content: center;
  padding: var(--space-md);
  margin-top: var(--space-lg);
}

.login-card .error-message {
  background: var(--status-error-bg);
  border: 1px solid var(--status-error-border);
  color: var(--status-error);
  padding: var(--space-md);
  border-radius: 8px;
  font-size: 0.8125rem;
  margin-bottom: var(--space-lg);
  text-align: center;
}
