:root {
  --primary: #cc0000;
  --secondary: #990000;
  --accent: #ff2222;
  --dark: #000000;
  --light: #f5f5f5;
}

body {
  background-color: #111111;
  color: #f0f0f0;
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

/* ── Navbar ── */
.navbar {
  background-color: #000000 !important;
  border-bottom: 1px solid #222;
  box-shadow: 0 2px 12px rgba(0,0,0,0.6);
}

.navbar-brand {
  color: #ffffff !important;
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: 0.5px;
}

.nav-link {
  color: rgba(255,255,255,0.65) !important;
  transition: color 0.15s;
}

.nav-link:hover {
  color: var(--accent) !important;
}

.btn-accent {
  background-color: var(--primary);
  color: white;
  border: none;
  border-radius: 4px;
  padding: 6px 18px;
  font-weight: 600;
  text-decoration: none;
  display: inline-block;
  transition: background-color 0.15s;
  line-height: 1.5;
}

.btn-accent:hover {
  background-color: var(--secondary);
  color: white;
}

/* ── Bootstrap overrides ── */
.btn-primary {
  background-color: var(--primary);
  border-color: var(--primary);
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
  background-color: var(--secondary);
  border-color: var(--secondary);
}

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

a:hover {
  color: var(--primary);
}

/* ── Hero ── */
.hero {
  position: relative;
  overflow: hidden;
  background-color: #000000;
  color: white;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  border-bottom: 2px solid var(--primary);
}

.hero-video {
  position: absolute;
  top: 50%;
  left: 50%;
  min-width: 100%;
  min-height: 100%;
  transform: translate(-50%, -50%);
  object-fit: cover;
  opacity: 0.45;
  z-index: 0;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
}

.hero-title {
  font-size: clamp(2.8rem, 8vw, 6rem);
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -1px;
  line-height: 1.05;
  margin-bottom: 1.5rem;
}

.hero-tagline {
  font-size: clamp(1rem, 2.5vw, 1.4rem);
  color: rgba(255,255,255,0.75);
  font-style: italic;
  font-weight: 300;
  max-width: 640px;
  margin: 0 auto 2.5rem;
  line-height: 1.6;
}

.hero-subtext {
  font-size: clamp(0.9rem, 2vw, 1.1rem);
  color: rgba(255,255,255,0.5);
  max-width: 560px;
  margin: 0 auto 2.5rem;
  line-height: 1.7;
  font-style: italic;
}

.hero-divider {
  width: 60px;
  height: 3px;
  background-color: var(--primary);
  margin: 0 auto 2rem;
}

/* ── Stat cards ── */
.stat-card {
  border: 1px solid #2a2a2a;
  border-radius: 8px;
  box-shadow: none;
  background: #1a1a1a;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

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

.stat-number {
  font-size: 2.4rem;
  font-weight: 700;
  color: var(--accent);
  line-height: 1.1;
  margin-bottom: 4px;
}

/* ── Section backgrounds ── */
.section-dark {
  background-color: #000000;
}

.section-mid {
  background-color: #141414;
}

/* ── How it works icons ── */
.how-icon {
  font-size: 2.2rem;
  color: var(--primary);
  margin-bottom: 1rem;
  display: block;
}

/* ── Leaderboard ── */
.leaderboard-table thead th {
  background-color: #000000;
  color: var(--accent);
  border-bottom: 2px solid var(--primary);
}

.leaderboard-table tbody tr {
  border-color: #2a2a2a;
  color: #f0f0f0;
}

.leaderboard-table tbody tr:hover {
  background-color: #1a1a1a;
}

.rank-badge {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.8rem;
}

.rank-1 { background: #ffd700; color: #111; }
.rank-2 { background: #c0c0c0; color: #111; }
.rank-3 { background: #cd7f32; color: white; }
.rank-other { background: #2a2a2a; color: #aaa; }

/* ── Forms ── */
.card {
  background-color: #1a1a1a;
  border: 1px solid #2a2a2a;
  color: #f0f0f0;
}

.form-control {
  background-color: #0d0d0d;
  border-color: #333;
  color: #f0f0f0;
}

.form-control:focus {
  background-color: #0d0d0d;
  border-color: var(--primary);
  color: #f0f0f0;
  box-shadow: 0 0 0 0.2rem rgba(204,0,0,0.2);
}

.form-control::placeholder {
  color: #555;
}

.form-label {
  color: #ccc;
}

.form-text {
  color: #666;
}

.table {
  color: #f0f0f0;
}

.table-light th {
  background-color: #1a1a1a;
  color: #ccc;
  border-color: #333;
}

.table tbody tr {
  border-color: #2a2a2a;
}

.table-hover tbody tr:hover {
  background-color: #1f1f1f;
  color: #f0f0f0;
}

.text-muted {
  color: #888 !important;
}

.alert-info {
  background-color: #1a1a1a;
  border-color: var(--primary);
  color: #f0f0f0;
}

.badge.bg-light {
  background-color: #2a2a2a !important;
  color: #ccc !important;
}

/* ── Footer ── */
footer {
  background-color: #000000;
  color: rgba(255,255,255,0.4);
  border-top: 1px solid #1a1a1a;
  padding: 40px 0;
  margin-top: 0;
}
