:root {
  --bg-primary: #0c0f14;
  --bg-secondary: #141820;
  --bg-card: #1a1f2b;
  --bg-card-hover: #222838;
  --fg-primary: #e8eaf0;
  --fg-secondary: #8b92a5;
  --fg-muted: #5a6178;
  --accent: #d4943a;
  --accent-light: #e8b56a;
  --accent-glow: rgba(212, 148, 58, 0.15);
  --border: rgba(255, 255, 255, 0.06);
  --radius: 12px;
  --radius-lg: 20px;
  --font-display: 'Space Grotesk', sans-serif;
  --font-body: 'DM Sans', sans-serif;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  background: var(--bg-primary);
  color: var(--fg-primary);
  font-family: var(--font-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.section-inner {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 24px;
}

.accent {
  color: var(--accent);
}

/* ===== HERO ===== */
.hero {
  position: relative;
  min-height: 90vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 120px 24px 80px;
  overflow: hidden;
}

.hero-gradient {
  position: absolute;
  top: -30%;
  left: 50%;
  transform: translateX(-50%);
  width: 800px;
  height: 800px;
  background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

.hero-inner {
  position: relative;
  z-index: 1;
  max-width: 780px;
}

.hero-badge {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid rgba(212, 148, 58, 0.3);
  padding: 8px 20px;
  border-radius: 100px;
  margin-bottom: 32px;
}

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 24px;
}

.lede {
  font-size: 1.15rem;
  color: var(--fg-secondary);
  max-width: 560px;
  margin: 0 auto 48px;
  line-height: 1.7;
}

.hero-stats {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 32px;
  padding: 28px 40px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(10px);
}

.stat {
  text-align: center;
}

.stat-number {
  display: block;
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--accent-light);
}

.stat-label {
  font-size: 0.8rem;
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.stat-divider {
  width: 1px;
  height: 40px;
  background: var(--border);
}

/* ===== HOW IT WORKS ===== */
.how-it-works {
  padding: 100px 0;
  border-top: 1px solid var(--border);
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 60px;
  text-align: center;
}

.section-subtitle {
  text-align: center;
  color: var(--fg-secondary);
  font-size: 1.1rem;
  margin-top: -44px;
  margin-bottom: 60px;
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.step {
  padding: 36px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: border-color 0.3s;
}

.step:hover {
  border-color: rgba(212, 148, 58, 0.2);
}

.step-number {
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 16px;
}

.step h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 12px;
}

.step p {
  color: var(--fg-secondary);
  font-size: 0.95rem;
  line-height: 1.65;
}

/* ===== NICHES ===== */
.niches {
  padding: 100px 0;
  background: var(--bg-secondary);
}

.niche-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.niche-card {
  padding: 32px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: all 0.3s ease;
}

.niche-card:hover {
  background: var(--bg-card-hover);
  transform: translateY(-2px);
}

.niche-featured {
  border-color: rgba(212, 148, 58, 0.25);
  background: linear-gradient(135deg, var(--bg-card) 0%, rgba(212, 148, 58, 0.05) 100%);
}

.niche-coming {
  border-style: dashed;
  border-color: var(--fg-muted);
}

.niche-icon {
  font-size: 1.6rem;
  margin-bottom: 16px;
  opacity: 0.7;
}

.niche-card h3 {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 10px;
}

.niche-card p {
  color: var(--fg-secondary);
  font-size: 0.9rem;
  line-height: 1.6;
}

/* ===== WHY ===== */
.why {
  padding: 100px 0;
  border-top: 1px solid var(--border);
}

.why-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.why-item {
  padding: 36px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: border-color 0.3s;
}

.why-item:hover {
  border-color: rgba(212, 148, 58, 0.2);
}

.why-number {
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 14px;
}

.why-item h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 10px;
}

.why-item p {
  color: var(--fg-secondary);
  font-size: 0.95rem;
  line-height: 1.65;
}

/* ===== CLOSING ===== */
.closing {
  padding: 120px 0;
  background: var(--bg-secondary);
  text-align: center;
}

.closing-content {
  max-width: 640px;
  margin: 0 auto;
}

.closing h2 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
  line-height: 1.2;
}

.closing p {
  color: var(--fg-secondary);
  font-size: 1.1rem;
  line-height: 1.7;
}

/* ===== FOOTER ===== */
.footer {
  padding: 40px 0;
  border-top: 1px solid var(--border);
}

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

.footer-brand {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--fg-primary);
}

.footer-tagline {
  font-size: 0.85rem;
  color: var(--fg-muted);
}

/* ===== MOBILE ===== */
@media (max-width: 768px) {
  .hero {
    min-height: auto;
    padding: 100px 20px 60px;
  }

  .hero-stats {
    flex-direction: column;
    gap: 20px;
    padding: 24px;
  }

  .stat-divider {
    width: 60px;
    height: 1px;
  }

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

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

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

  .section-title {
    margin-bottom: 40px;
  }

  .section-subtitle {
    margin-top: -24px;
    margin-bottom: 40px;
  }

  .how-it-works,
  .niches,
  .why {
    padding: 60px 0;
  }

  .closing {
    padding: 80px 0;
  }

  .footer-content {
    flex-direction: column;
    gap: 8px;
    text-align: center;
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 2rem;
  }

  .lede {
    font-size: 1rem;
  }

  .step,
  .niche-card,
  .why-item {
    padding: 24px;
  }
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 600;
  padding: 12px 24px;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent);
  color: #0c0f14;
}

.btn-primary:hover {
  background: var(--accent-light);
  transform: translateY(-1px);
}

.btn-secondary {
  background: transparent;
  color: var(--fg-primary);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  border-color: rgba(255, 255, 255, 0.15);
  background: var(--bg-secondary);
}

.btn-lg {
  font-size: 1rem;
  padding: 14px 32px;
  border-radius: var(--radius-lg);
}

.btn-sm {
  font-size: 0.8rem;
  padding: 8px 16px;
}

.btn-full {
  width: 100%;
}

/* ===== NAV ===== */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(12, 15, 20, 0.88);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 24px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--fg-primary);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-link {
  font-size: 0.9rem;
  color: var(--fg-secondary);
  text-decoration: none;
  transition: color 0.2s;
}

.nav-link:hover {
  color: var(--fg-primary);
}

.admin-badge {
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  background: var(--accent);
  color: #0c0f14;
  padding: 2px 8px;
  border-radius: 4px;
}

/* Compensate for fixed nav height */
.hero {
  padding-top: 160px;
}

/* ===== HERO CTA ROW ===== */
.hero-cta-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 48px;
  flex-wrap: wrap;
}

/* ===== PAGE HERO (guild selection) ===== */
.page-hero {
  padding: 140px 0 60px;
  text-align: center;
}

.page-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 20px;
}

/* ===== GUILDS SELECTION PAGE ===== */
.guilds-section {
  padding: 40px 0 80px;
}

.guild-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 48px;
}

.guild-card {
  padding: 32px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  transition: all 0.25s ease;
}

.guild-card:hover {
  background: var(--bg-card-hover);
  border-color: rgba(212, 148, 58, 0.2);
  transform: translateY(-2px);
}

.guild-featured {
  border-color: rgba(212, 148, 58, 0.3);
  background: linear-gradient(135deg, var(--bg-card) 0%, rgba(212, 148, 58, 0.07) 100%);
}

.guild-coming {
  border-style: dashed;
  border-color: var(--fg-muted);
  opacity: 0.55;
  pointer-events: none;
}

.guild-icon {
  font-size: 1.8rem;
  margin-bottom: 16px;
}

.guild-card h3 {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 10px;
}

.guild-card p {
  color: var(--fg-secondary);
  font-size: 0.9rem;
  line-height: 1.6;
  flex: 1;
  margin-bottom: 20px;
}

.guild-price {
  margin-bottom: 16px;
}

.price-amount {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--accent-light);
}

.price-period {
  font-size: 0.9rem;
  color: var(--fg-muted);
  margin-left: 2px;
}

.guild-btn {
  width: 100%;
  text-align: center;
}

.guilds-guarantee {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 40px;
  padding: 24px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}

.guarantee-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9rem;
  color: var(--fg-secondary);
}

.guarantee-icon {
  color: var(--accent);
  font-weight: 700;
}

/* ===== CHECKOUT SUCCESS ===== */
.success-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 120px 24px 80px;
}

.success-card {
  max-width: 560px;
  margin: 0 auto;
  text-align: center;
}

.success-icon {
  width: 72px;
  height: 72px;
  background: rgba(212, 148, 58, 0.15);
  border: 2px solid var(--accent);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  color: var(--accent);
  margin: 0 auto 28px;
}

.success-card h1 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.4rem);
  font-weight: 700;
  margin-bottom: 12px;
}

.success-guild {
  font-size: 1.05rem;
  color: var(--fg-secondary);
  margin-bottom: 8px;
}

.success-message {
  font-size: 1rem;
  color: var(--fg-secondary);
  margin-bottom: 40px;
  line-height: 1.65;
}

.success-what-next {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  margin-bottom: 32px;
  text-align: left;
}

.success-what-next h3 {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  margin-bottom: 20px;
  color: var(--fg-secondary);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.next-steps {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.next-step {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.next-num {
  width: 28px;
  height: 28px;
  background: var(--accent);
  color: #0c0f14;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 700;
  flex-shrink: 0;
}

.next-step p {
  font-size: 0.9rem;
  color: var(--fg-secondary);
  line-height: 1.6;
  margin-top: 4px;
}

/* ===== ADMIN ===== */
.admin-body {
  background: var(--bg-primary);
}

.admin-layout {
  padding-top: 64px;
}

.admin-main {
  max-width: 1100px;
  margin: 0 auto;
  padding: 48px 24px 80px;
}

.admin-header {
  margin-bottom: 36px;
}

.admin-header h1 {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.admin-subtitle {
  color: var(--fg-secondary);
  font-size: 0.95rem;
}

.stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 40px;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
}

.stat-card-value {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent-light);
  margin-bottom: 4px;
}

.stat-card-label {
  font-size: 0.8rem;
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.admin-section {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  margin-bottom: 24px;
}

.admin-section h2 {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

table {
  width: 100%;
  border-collapse: collapse;
}

th {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--fg-muted);
  text-align: left;
  padding: 0 12px 12px 0;
}

td {
  padding: 12px 12px 12px 0;
  border-top: 1px solid var(--border);
  font-size: 0.9rem;
  color: var(--fg-secondary);
  vertical-align: middle;
}

td:first-child, th:first-child {
  color: var(--fg-primary);
}

.link-btn {
  color: var(--accent);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 500;
}

.link-btn:hover {
  color: var(--accent-light);
}

.status-badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 100px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: capitalize;
}

.status-active {
  background: rgba(52, 211, 153, 0.15);
  color: #34d399;
}

.status-canceled,
.status-cancelled {
  background: rgba(239, 68, 68, 0.1);
  color: #f87171;
}

.status-trialing {
  background: rgba(212, 148, 58, 0.15);
  color: var(--accent-light);
}

.empty-state {
  text-align: center;
  padding: 40px 0;
}

.empty-state p {
  color: var(--fg-secondary);
  margin-bottom: 20px;
}

/* ===== ADMIN LOGIN ===== */
.login-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px 24px;
}

.login-card {
  width: 100%;
  max-width: 400px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 40px;
}

.login-card h1 {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.login-subtitle {
  color: var(--fg-secondary);
  font-size: 0.9rem;
  margin-bottom: 28px;
}

.login-error {
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.2);
  color: #f87171;
  padding: 12px 16px;
  border-radius: var(--radius);
  font-size: 0.9rem;
  margin-bottom: 20px;
}

.login-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--fg-secondary);
}

.form-group input {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--fg-primary);
  font-family: var(--font-body);
  font-size: 0.95rem;
  padding: 12px 16px;
  outline: none;
  transition: border-color 0.2s;
}

.form-group input:focus {
  border-color: rgba(212, 148, 58, 0.4);
}

.login-back {
  display: block;
  text-align: center;
  margin-top: 20px;
  font-size: 0.85rem;
  color: var(--fg-muted);
  text-decoration: none;
  transition: color 0.2s;
}

.login-back:hover {
  color: var(--fg-secondary);
}

/* ===== MOBILE ADDITIONS ===== */
@media (max-width: 768px) {
  .nav-links .nav-link {
    display: none;
  }

  .hero-cta-row {
    flex-direction: column;
    align-items: stretch;
  }

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

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

  .guilds-guarantee {
    flex-direction: column;
    gap: 16px;
    align-items: flex-start;
  }
}

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