@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=Inter:wght@300;400;500;600;700&display=swap');

/* ── Base Variables ───────────────────────────────────────────── */
:root {
  --font-primary: 'Outfit', sans-serif;
  --font-secondary: 'Inter', sans-serif;
  
  --bg-dark: #070a13;
  --bg-card: rgba(13, 18, 36, 0.65);
  --border-light: rgba(255, 255, 255, 0.07);
  --border-glow: rgba(99, 102, 241, 0.25);
  
  --color-primary: #6366f1;
  --color-primary-glow: rgba(99, 102, 241, 0.4);
  --color-secondary: #06b6d4;
  --color-discord: #5865F2;
  --color-success: #10b981;
  --color-error: #ef4444;
  --color-warning: #f59e0b;
  
  --text-primary: #f8fafc;
  --text-muted: #94a3b8;
  --text-dark: #64748b;
  
  --transition-smooth: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ── Global Styles ─────────────────────────────────────────────── */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background-color: var(--bg-dark);
  font-family: var(--font-secondary);
  color: var(--text-primary);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  position: relative;
  overflow-x: hidden;
}

/* ── Background Video & Overlay ────────────────────────────────── */
#background-container {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100vh;
  z-index: -10;
  overflow: hidden;
}

#background-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.2) contrast(1.1) saturate(0.9) blur(2px);
}

.video-overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 50%, rgba(7, 10, 19, 0.4) 0%, rgba(7, 10, 19, 0.9) 80%);
  pointer-events: none;
}

/* ── Glow Orbs ─────────────────────────────────────────────────── */
.glow-orb {
  position: fixed;
  top: 10%;
  left: 20%;
  width: 500px;
  height: 500px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--color-primary-glow) 0%, rgba(0,0,0,0) 70%);
  z-index: -9;
  filter: blur(80px);
  pointer-events: none;
  opacity: 0.4;
}

/* ── Main Wrapper ──────────────────────────────────────────────── */
.formbold-main-wrapper {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  min-height: 100vh;
  padding: 60px 20px 80px;
  position: relative;
  z-index: 1;
}

/* ── Form Card ─────────────────────────────────────────────────── */
.formbold-form-wrapper {
  width: 100%;
  max-width: 820px;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-top: 2px solid var(--color-primary);
  border-radius: 20px;
  padding: 48px 52px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4),
              0 0 30px rgba(99, 102, 241, 0.05);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  position: relative;
  overflow: hidden;
}

/* ── Back to Home Link ────────────────────────────────────────── */
.back-to-home {
  position: absolute;
  top: 24px;
  left: 32px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  text-decoration: none;
  transition: var(--transition-smooth);
}

.back-to-home:hover {
  color: var(--text-primary);
  transform: translateX(-4px);
}

/* ── Header ────────────────────────────────────────────────────── */
.formbold-img {
  display: block;
  width: 64px;
  height: 64px;
  margin: 12px auto 24px;
  border-radius: 50%;
  border: 2px solid var(--color-primary);
  box-shadow: 0 0 15px var(--color-primary-glow);
}

.formbold-form-title {
  text-align: center;
  margin-bottom: 40px;
}

.formbold-form-title h2 {
  font-family: var(--font-primary);
  font-size: 28px;
  font-weight: 800;
  background: linear-gradient(135deg, #ffffff 40%, var(--text-muted) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 8px;
}

.formbold-form-title p {
  font-size: 14.5px;
  color: var(--text-muted);
  max-width: 580px;
  margin: 0 auto;
  line-height: 1.6;
}

/* ── Multi-Step Progress Tracker ───────────────────────────────── */
.step-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 44px;
  position: relative;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

.step-container::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  height: 2px;
  background: rgba(255, 255, 255, 0.05);
  z-index: 1;
  transform: translateY(-50%);
}

.step-progress-bar {
  position: absolute;
  top: 50%;
  left: 0;
  width: 0%; /* Dynamic update */
  height: 2px;
  background: linear-gradient(90deg, var(--color-primary), var(--color-secondary));
  z-index: 2;
  transform: translateY(-50%);
  transition: var(--transition-smooth);
}

.step-node {
  position: relative;
  z-index: 3;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #0f1322;
  border: 2px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-primary);
  font-size: 14px;
  font-weight: 700;
  color: var(--text-muted);
  transition: var(--transition-smooth);
}

.step-node.active {
  border-color: var(--color-primary);
  color: var(--text-primary);
  box-shadow: 0 0 15px rgba(99, 102, 241, 0.4);
  background: var(--bg-dark);
}

.step-node.completed {
  border-color: var(--color-secondary);
  background: var(--color-secondary);
  color: white;
  box-shadow: 0 0 15px rgba(6, 182, 212, 0.4);
}

.step-label {
  position: absolute;
  top: 44px;
  font-size: 11.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-dark);
  white-space: nowrap;
  transition: var(--transition-smooth);
}

.step-node.active .step-label {
  color: var(--text-primary);
}

.step-node.completed .step-label {
  color: var(--color-secondary);
}

/* ── Step Panels ───────────────────────────────────────────────── */
.step-panel {
  display: none; /* Controlled by JS */
  animation: fadeIn 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.step-panel.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ── Conditions Section (Step 1) ───────────────────────────────── */
.formbold-conditions {
  background: rgba(255, 255, 255, 0.015);
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-left: 4px solid var(--color-primary);
  border-radius: 12px;
  padding: 28px 32px;
  margin-bottom: 32px;
}

.formbold-conditions h3 {
  font-family: var(--font-primary);
  font-size: 15px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08px;
  color: var(--text-primary);
  margin-bottom: 20px;
}

.conditions-list-container {
  max-height: 250px;
  overflow-y: auto;
  padding-right: 12px;
  margin-bottom: 24px;
}

/* Custom Scrollbar for Conditions */
.conditions-list-container::-webkit-scrollbar {
  width: 6px;
}
.conditions-list-container::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.01);
}
.conditions-list-container::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 3px;
}
.conditions-list-container::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.15);
}

.formbold-conditions ul {
  padding-left: 18px;
  list-style: disc;
}

.formbold-conditions ul li {
  font-size: 13.5px;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 12px;
}

.formbold-conditions ul li:last-child {
  margin-bottom: 0;
}

.formbold-conditions strong {
  color: var(--text-primary);
}

/* ── Checkbox Integration ──────────────────────────────────────── */
.checkbox-container {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin: 24px 0 32px 0;
  cursor: pointer;
  user-select: none;
}

.checkbox-input {
  appearance: none;
  width: 20px;
  height: 20px;
  border: 1.5px solid rgba(255, 255, 255, 0.15);
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.2);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-smooth);
  flex-shrink: 0;
  margin-top: 2px;
}

.checkbox-input:checked {
  background-color: var(--color-primary);
  border-color: var(--color-primary);
}

.checkbox-input:checked::after {
  content: '✓';
  font-size: 12px;
  color: white;
  font-weight: 700;
}

.checkbox-text {
  font-size: 13.5px;
  color: var(--text-muted);
  line-height: 1.5;
}

.checkbox-text strong {
  color: var(--text-primary);
}

/* ── Discord Authenticated Banner ──────────────────────────────── */
.discord-user-profile {
  background: rgba(88, 101, 242, 0.08);
  border: 1.5px solid rgba(88, 101, 242, 0.25);
  border-radius: 12px;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 32px;
}

.discord-user-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--color-discord);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  color: white;
}

.discord-user-info {
  flex-grow: 1;
}

.discord-user-tag {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
}

.discord-user-status {
  font-size: 12px;
  color: var(--text-muted);
}

.discord-logout-link {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-error);
  text-decoration: none;
}

/* ── Form Fields ────────────────────────────────────────────────── */
.formbold-mb-3 {
  margin-bottom: 24px;
}

.formbold-form-label {
  display: block;
  font-family: var(--font-primary);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
  letter-spacing: 0.01em;
}

.formbold-form-input {
  width: 100%;
  padding: 12px 18px;
  border: 1.5px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.25);
  font-family: var(--font-secondary);
  font-size: 14.5px;
  color: var(--text-primary);
  outline: none;
  transition: var(--transition-smooth);
  resize: vertical;
}

.formbold-form-input::placeholder {
  color: var(--text-dark);
}

.formbold-form-input:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
  background: rgba(0, 0, 0, 0.35);
}

.formbold-form-input[readonly] {
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-muted);
  border-color: rgba(255, 255, 255, 0.04);
  cursor: not-allowed;
}

select.formbold-form-input {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 18px center;
  padding-right: 48px;
}

select.formbold-form-input option {
  background-color: #0c0f1d;
  color: var(--text-primary);
}

textarea.formbold-form-input {
  min-height: 120px;
  line-height: 1.6;
}

.formbold-char-counter {
  display: block;
  font-size: 11px;
  color: var(--text-dark);
  text-align: right;
  margin-top: 6px;
  font-weight: 500;
}

/* ── Buttons & Button Containers ───────────────────────────────── */
.button-container {
  display: flex;
  justify-content: center;
  margin-top: 8px;
}

.form-navigation-buttons {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 36px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 24px;
}

.formbold-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: var(--color-primary);
  color: #ffffff;
  border: none;
  border-radius: 8px;
  padding: 13px 32px;
  font-family: var(--font-primary);
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: var(--transition-smooth);
  box-shadow: 0 4px 15px rgba(99, 102, 241, 0.25);
  white-space: nowrap;
}

.formbold-btn:hover:not(:disabled) {
  background: #4f46e5;
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
  transform: translateY(-1.5px);
}

.formbold-btn:active:not(:disabled) {
  transform: translateY(0);
}

.formbold-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  box-shadow: none;
}

.formbold-btn-secondary {
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-primary);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: none;
}

.formbold-btn-secondary:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.15);
  color: white;
}

.formbold-btn-discord {
  background: var(--color-discord);
  box-shadow: 0 4px 15px rgba(88, 101, 242, 0.25);
}

.formbold-btn-discord:hover:not(:disabled) {
  background: #4752c4;
  box-shadow: 0 6px 20px rgba(88, 101, 242, 0.4);
}

.discord-logo {
  width: 20px;
  height: auto;
  flex-shrink: 0;
}

/* ── Success Screen ────────────────────────────────────────────── */
.success-screen {
  text-align: center;
  padding: 32px 0;
}

.success-icon {
  width: 72px;
  height: 72px;
  background: rgba(16, 185, 129, 0.1);
  border: 2px solid var(--color-success);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  color: var(--color-success);
  margin: 0 auto 28px;
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.2);
}

/* ── Responsive ─────────────────────────────────────────────────── */
@media (max-width: 680px) {
  .formbold-form-wrapper {
    padding: 36px 24px;
    border-radius: 16px;
  }

  .formbold-form-title h2 {
    font-size: 22px;
  }

  .step-label {
    display: none;
  }

  .form-navigation-buttons {
    flex-direction: column;
  }

  .form-navigation-buttons button, .form-navigation-buttons a {
    width: 100%;
  }
}
