/* ============================================================
   FPCS Auth Gate + Onboarding + Boot Screen Styles
   Injected by auth.js — styles only in this file
   Part of TRAILS: Technology · Robotics · AI · Language · Skills
   ============================================================ */

/* ---- Auth Gate (Sign-In Overlay) ---- */
#authGate {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: #0a0a0a;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  font-family: system-ui, -apple-system, sans-serif;
}
#authGate .lock-icon {
  font-size: 64px;
  margin-bottom: 16px;
}
#authGate h1 {
  color: #e5e7eb;
  font-size: 22px;
  margin-bottom: 8px;
}
#authGate .auth-sub {
  color: #9ca3af;
  font-size: 14px;
  margin-bottom: 24px;
}
#authGate .g-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 28px;
  font-size: 15px;
  font-weight: 600;
  border: 2px solid #333;
  border-radius: 8px;
  background: #1a1a1a;
  color: #e5e7eb;
  cursor: pointer;
  transition: all 0.2s;
}
#authGate .g-btn:hover {
  border-color: #4285f4;
  background: #111;
}
#authGate .g-btn svg {
  width: 20px; height: 20px;
}
#authGate .auth-err {
  color: #ef4444;
  font-size: 13px;
  margin-top: 12px;
  min-height: 20px;
}
#authGate .auth-loading {
  color: #9ca3af;
  font-size: 14px;
  margin-top: 12px;
}

#dashContent {
  display: none;
}


/* ---- Onboarding Modal ---- */
.onboard-modal {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0,0,0,0.92);
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: system-ui, -apple-system, sans-serif;
  transition: opacity 0.3s;
}
.onboard-card {
  background: #141a2e;
  border: 1px solid #2d3748;
  border-radius: 16px;
  width: 90%;
  max-width: 520px;
  padding: 0;
  overflow: hidden;
  box-shadow: 0 24px 80px rgba(0,0,0,0.6), 0 0 60px rgba(56,189,248,0.08);
}
.onboard-header {
  padding: 28px 28px 20px;
  text-align: center;
  border-bottom: 1px solid #2d3748;
  background: linear-gradient(180deg, #1a2340 0%, #141a2e 100%);
}
.onboard-welcome-icon {
  font-size: 48px;
  display: block;
  margin-bottom: 8px;
}
.onboard-header h2 {
  color: #e5e7eb;
  font-size: 20px;
  margin: 0 0 6px;
}
.onboard-header p {
  color: #9ca3af;
  font-size: 13px;
  margin: 0;
}

.onboard-body {
  padding: 16px 20px;
  max-height: 340px;
  overflow-y: auto;
}
.onboard-option {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.15s;
  border: 1px solid transparent;
  margin-bottom: 6px;
}
.onboard-option:hover {
  background: rgba(56,189,248,0.06);
  border-color: #2d3748;
}
.onboard-section-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #6b7280;
  padding: 8px 14px 4px;
}
.onboard-option input[type="checkbox"] {
  width: 18px; height: 18px;
  accent-color: #38bdf8;
  cursor: pointer;
  flex-shrink: 0;
}
.onboard-icon {
  font-size: 22px;
  flex-shrink: 0;
  width: 28px;
  text-align: center;
}
.onboard-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.onboard-label {
  color: #e5e7eb;
  font-size: 14px;
  font-weight: 600;
}
.onboard-desc {
  color: #6b7280;
  font-size: 11px;
}
.onboard-led {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #374151;
  flex-shrink: 0;
  transition: all 0.2s;
}
.onboard-option input:checked ~ .onboard-led {
  background: #4ade80;
  box-shadow: 0 0 8px rgba(74,222,128,0.5);
}

.onboard-footer {
  padding: 16px 28px 24px;
  text-align: center;
  border-top: 1px solid #2d3748;
}
.onboard-hint {
  color: #6b7280;
  font-size: 11px;
  margin-bottom: 12px;
}
.onboard-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 36px;
  font-size: 16px;
  font-weight: 700;
  border: none;
  border-radius: 10px;
  background: linear-gradient(135deg, #38bdf8, #6366f1);
  color: #fff;
  cursor: pointer;
  transition: all 0.2s;
  letter-spacing: 0.5px;
}
.onboard-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(56,189,248,0.4);
}


/* ---- Boot Progress Screen ---- */
.boot-screen {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: #0a0a0f;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: system-ui, -apple-system, sans-serif;
  transition: opacity 0.4s;
}
.boot-card {
  width: 90%;
  max-width: 480px;
  text-align: center;
}
.boot-card h2 {
  color: #e5e7eb;
  font-size: 20px;
  margin: 0 0 24px;
  letter-spacing: 0.5px;
}

/* Main progress bar */
.boot-progress-wrap {
  width: 100%;
  height: 8px;
  background: #1e293b;
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 8px;
  box-shadow: inset 0 1px 3px rgba(0,0,0,0.4);
}
.boot-progress-bar {
  height: 100%;
  width: 0%;
  border-radius: 4px;
  background: linear-gradient(90deg, #38bdf8, #4ade80, #fbbf24);
  transition: width 0.3s ease;
  box-shadow: 0 0 12px rgba(56,189,248,0.4);
}
.boot-percent {
  color: #6b7280;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 20px;
  font-variant-numeric: tabular-nums;
}

/* Individual step rows */
.boot-steps {
  text-align: left;
}
.boot-step {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-radius: 8px;
  transition: all 0.2s;
}
.boot-step.active {
  background: rgba(56,189,248,0.08);
}
.boot-step.done {
  opacity: 0.5;
}

/* LED indicator */
.boot-led {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #374151;
  flex-shrink: 0;
  transition: all 0.3s;
}
.boot-step.active .boot-led {
  background: var(--led-color, #38bdf8);
  box-shadow: 0 0 10px var(--led-color, #38bdf8);
  animation: led-pulse 0.8s ease-in-out infinite;
}
.boot-step.done .boot-led {
  background: #4ade80;
  box-shadow: 0 0 6px rgba(74,222,128,0.4);
}

@keyframes led-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.boot-icon {
  font-size: 16px;
  flex-shrink: 0;
  width: 22px;
  text-align: center;
}
.boot-label {
  flex: 1;
  color: #9ca3af;
  font-size: 13px;
  font-weight: 500;
}
.boot-step.active .boot-label {
  color: #e5e7eb;
}
.boot-status {
  color: #4b5563;
  font-size: 11px;
  font-family: 'Courier New', monospace;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  min-width: 60px;
  text-align: right;
}
.boot-step.active .boot-status {
  color: #38bdf8;
}
.boot-step.done .boot-status {
  color: #4ade80;
}


/* ---- Responsive ---- */
@media (max-width: 500px) {
  .onboard-card { width: 95%; }
  .boot-card { width: 95%; }
  .onboard-body { max-height: 260px; }
  .onboard-option { padding: 10px; gap: 8px; }
}
