:root {
  color-scheme: dark;
  font-family: "Inter", "Segoe UI", system-ui, sans-serif;
  --primary: #ffffff;
  --primary-dark: #e2e8f0;
  --surface: #0b0b0b;
  --muted: #111111;
  --text: #ffffff;
  --subtle: #d1d5db;
  --success: #22c55e;
  --border: #1f1f1f;
  --brand: #527619;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background: #000000;
  color: var(--text);
  min-height: 100vh;
}

.page {
  max-width: 1100px;
  margin: 0 auto;
  padding: 32px 24px 64px;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  margin-bottom: 32px;
}

.logo-icon {
  width: 56px;
  height: 56px;
  display: block;
}

.hero {
  display: grid;
  gap: 32px;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  align-items: center;
}

.pill {
  display: inline-flex;
  padding: 6px 14px;
  background: var(--muted);
  color: var(--primary);
  font-weight: 600;
  border-radius: 999px;
  font-size: 0.85rem;
}

.hero h1 {
  font-size: clamp(2.8rem, 5vw, 4.6rem);
  margin: 12px 0 8px;
  color: var(--brand);
  letter-spacing: 0.12em;
}

.hero h2 {
  font-size: clamp(1.2rem, 2vw, 1.6rem);
  font-weight: 600;
  margin-bottom: 12px;
}

.hero-heading {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.hero p {
  color: var(--subtle);
  line-height: 1.6;
}

.hero-stats {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 24px;
}

.stat-value {
  font-size: 2rem;
  font-weight: 700;
  display: block;
}

.stat-label {
  color: var(--subtle);
  font-size: 0.9rem;
}

.stat-tier-label {
  color: var(--subtle);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.stat-tier {
  font-size: 1.4rem;
  font-weight: 700;
}

.hero-card {
  background: #0f0f0f;
  border-radius: 20px;
  padding: 28px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.4);
}

.hero-card h2 {
  margin-bottom: 20px;
}

form {
  display: grid;
  gap: 16px;
}

label {
  display: grid;
  gap: 8px;
  font-weight: 600;
  color: var(--text);
}

input,
select {
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--border);
  font-size: 1rem;
  background: #050505;
  color: var(--text);
}

button {
  padding: 12px 18px;
  border-radius: 999px;
  border: none;
  background: var(--brand);
  color: #ffffff;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease;
}

button:hover {
  background: #3f5c12;
  transform: translateY(-1px);
}

button.secondary {
  background: #1b1b1b;
  color: var(--primary);
}

button.secondary:hover {
  background: #2a2a2a;
}

.verify-row {
  display: flex;
  align-items: center;
  gap: 16px;
}

.hint {
  font-size: 0.85rem;
  color: var(--subtle);
}

.form-note {
  color: var(--subtle);
  font-size: 0.85rem;
}

.referral {
  display: grid;
  gap: 24px;
  margin-top: 48px;
  grid-template-columns: repeat(2, minmax(280px, 1fr));
  align-items: start;
}

.card {
  background: #0f0f0f;
  border-radius: 16px;
  padding: 24px;
  border: 1px solid var(--border);
}

.referral-link {
  display: flex;
  gap: 12px;
  margin: 16px 0 8px;
}

.referral-link input {
  flex: 1;
  background: #050505;
}

.ladder {
  list-style: none;
  display: grid;
  gap: 12px;
  margin: 16px 0;
}

.ladder li {
  display: flex;
  justify-content: space-between;
  color: var(--subtle);
}

.progress {
  height: 10px;
  background: #1f1f1f;
  border-radius: 999px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, #527619, #9acd32);
  transition: width 0.3s ease;
}

.details {
  display: grid;
  grid-template-columns: repeat(2, minmax(280px, 1fr));
  gap: 24px;
  margin-top: 40px;
  color: var(--subtle);
}

.details h3 {
  color: var(--text);
  margin-bottom: 12px;
}

.footer {
  text-align: center;
  padding: 20px;
  color: var(--subtle);
  font-size: 0.9rem;
}

.footer a {
  color: inherit;
}

.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
  z-index: 20;
}

.modal.is-open {
  opacity: 1;
  pointer-events: auto;
}

.modal-card {
  background: #0b0b0b;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 24px;
  max-width: 760px;
  width: 100%;
  max-height: 80vh;
  overflow: auto;
  position: relative;
  color: var(--text);
}

.modal-card h2 {
  color: var(--brand);
  margin-bottom: 16px;
}

.modal-card h3 {
  margin-top: 16px;
  margin-bottom: 8px;
}

.modal-card p,
.modal-card li {
  color: var(--subtle);
  line-height: 1.6;
}

.modal-card ul {
  padding-left: 18px;
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  background: transparent;
  color: var(--text);
  border: none;
  font-size: 1.5rem;
}

.modal-actions {
  display: flex;
  gap: 12px;
  margin-top: 20px;
}

.modal-link {
  color: var(--primary);
  text-decoration: underline;
  cursor: pointer;
}

.success {
  color: var(--success);
  font-weight: 600;
}

@media (max-width: 720px) {
  .referral,
  .details {
    grid-template-columns: 1fr;
  }

  .verify-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .referral-link {
    flex-direction: column;
  }
}
