:root {
  --color-bg-primary: #1e1f22;
  --color-bg-secondary: #2b2d31;
  --color-bg-tertiary: #313338;
  --color-bg-card: #383a40;
  --color-bg-hover: #404249;
  --color-accent-blue: #5865f2;
  --color-accent-cyan: #00d4ff;
  --color-accent-green: #23a55a;
  --color-text-primary: #f2f3f5;
  --color-text-secondary: #b5bac1;
  --color-text-muted: #80848e;
  --color-border: rgba(255, 255, 255, 0.06);
  --font-display: "Rajdhani", sans-serif;
  --font-body: "Inter", sans-serif;
  --font-mono: "JetBrains Mono", monospace;

  --bg: rgba(30, 31, 34, 0.85);
  --bg-solid: var(--color-bg-primary);
  --text: var(--color-text-primary);
  --muted: var(--color-text-muted);
  --body: var(--color-text-secondary);
  --accent: var(--color-accent-green);
  --border: var(--color-border);
  --rl: #256be6;
  --lol: #c89b3c;
  --hypixel: #55ff55;
  --skyblock: var(--color-accent-blue);
}

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

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  background: var(--bg-solid);
  color: var(--text);
  font-family: var(--font-body);
}

::-webkit-scrollbar {
  width: 4px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: #4e5058;
  border-radius: 2px;
}

.app {
  background: var(--bg);
  min-height: 100vh;
  color: var(--text);
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  height: 3rem;
  background: var(--bg);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.logo {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text);
}

.nav {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.nav-link {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--muted);
  transition: color 150ms ease;
}

.nav-link:hover,
.nav-link:focus-visible {
  color: var(--hover-color, var(--text));
}

/* Hero */
.hero {
  padding: 4rem 2rem;
  max-width: 56rem;
  margin: 0 auto;
}

.eyebrow {
  margin-bottom: 0.5rem;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

.hero h1 {
  font-family: var(--font-display);
  font-size: 3.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--text);
  margin-bottom: 0.75rem;
  line-height: 1.1;
}

.lead {
  font-size: 1rem;
  color: var(--body);
  max-width: 480px;
  line-height: 1.6;
  margin-bottom: 2rem;
}

.stats {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
}

.stat-value {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 0.125rem;
}

.stat-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--muted);
}

/* Sections */
.sections {
  max-width: 56rem;
  margin: 0 auto;
  padding: 0 2rem 6rem;
  display: flex;
  flex-direction: column;
  gap: 6rem;
}

.game-section {
  scroll-margin-top: 4rem;
}

.game-section h2 {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  margin-bottom: 0.5rem;
}

.section-kicker {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}

.game-section p {
  color: var(--body);
  line-height: 1.6;
  max-width: 40rem;
}

/* Themed game sections */
.rl-section {
  --section-accent: var(--rl);
  --section-accent-12: rgba(37, 107, 230, 0.12);
  --section-accent-20: rgba(37, 107, 230, 0.2);
  --section-accent-10: rgba(37, 107, 230, 0.1);
  --section-accent-30: rgba(37, 107, 230, 0.3);
  --section-bar-end: #ffaa80;
  --section-peak: #873eed;
}

.lol-section {
  --section-accent: var(--lol);
  --section-accent-12: rgba(200, 155, 60, 0.12);
  --section-accent-20: rgba(200, 155, 60, 0.2);
  --section-accent-10: rgba(200, 155, 60, 0.1);
  --section-accent-30: rgba(200, 155, 60, 0.3);
  --section-bar-end: #e8c06a;
  --section-peak: #c0c7d1;
}

.hypixel-section {
  --section-accent: var(--hypixel);
  --section-accent-12: rgba(85, 255, 85, 0.08);
  --section-accent-20: rgba(85, 255, 85, 0.15);
  --section-accent-10: rgba(85, 255, 85, 0.08);
  --section-accent-30: rgba(85, 255, 85, 0.2);
  --section-bar-end: #a8ffa8;
  --section-peak: #55ffff;
}

.skyblock-section {
  --section-accent: var(--skyblock);
  --section-accent-12: rgba(88, 101, 242, 0.12);
  --section-accent-20: rgba(88, 101, 242, 0.22);
  --section-accent-10: rgba(88, 101, 242, 0.1);
  --section-accent-30: rgba(88, 101, 242, 0.3);
  --section-bar-end: #8b95ff;
  --section-peak: var(--skyblock);
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 2rem;
}

.section-title {
  font-family: var(--font-display);
  font-size: 2.25rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--color-text-primary);
  line-height: 1.15;
}

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

.tracker-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-decoration: none;
  color: var(--section-accent);
  background: var(--section-accent-12);
  border: 1px solid var(--section-accent-30);
  transition: background 150ms ease;
  white-space: nowrap;
}

.tracker-btn:hover,
.tracker-btn:focus-visible {
  background: var(--section-accent-20);
}

.tracker-btn svg {
  width: 14px;
  height: 14px;
}

.tracker-row {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.tracker-btn-stack {
  flex-direction: column;
  align-items: flex-end;
  line-height: 1.3;
}

.tracker-note {
  color: #4e5058;
  font-size: 9px;
  letter-spacing: 0.08em;
}

.network-stats {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 2.5rem;
}

.network-value {
  font-family: var(--font-display);
  font-size: 2.25rem;
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 0.25rem;
}

.game-blocks {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.game-block {
  border-radius: 12px;
  padding: 1.25rem;
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-top: 2px solid var(--game-color);
}

.game-block-title {
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--game-color);
  margin-bottom: 1rem;
}

.game-block-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

.game-block-value {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-text-primary);
  margin-bottom: 0.125rem;
}

.sky-top-stats {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 1rem 2.5rem;
}

.sky-stat-value {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--section-accent);
  margin-bottom: 0.125rem;
}

.skill-panel {
  border-radius: 12px;
  padding: 1.25rem;
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
}

.skill-panel-title {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  margin-bottom: 1rem;
}

.skill-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.skill-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.skill-name {
  flex-shrink: 0;
  width: 5rem;
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: var(--color-text-secondary);
}

.skill-track {
  flex: 1;
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
}

.skill-fill {
  height: 100%;
  border-radius: 999px;
  opacity: 0.8;
}

.skill-level {
  flex-shrink: 0;
  width: 1.5rem;
  text-align: right;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  opacity: 0.9;
}

.rank-banner {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  background: linear-gradient(
    135deg,
    var(--section-accent-10) 0%,
    var(--color-bg-secondary) 70%
  );
  border: 1px solid var(--section-accent-20);
}

.rank-glow {
  position: absolute;
  right: 0;
  top: 0;
  width: 18rem;
  height: 18rem;
  pointer-events: none;
  background: radial-gradient(
    circle,
    var(--section-accent-10) 0%,
    transparent 70%
  );
  transform: translate(30%, -30%);
}

.rank-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.rank-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--color-text-muted);
  margin-bottom: 0.25rem;
}

.rank-name {
  font-family: var(--font-display);
  font-size: 3rem;
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 0.25rem;
}

.rank-name.peak {
  color: var(--section-peak);
}

.rank-mmr {
  font-size: 0.875rem;
  color: var(--color-text-secondary);
}

.mmr-bar-wrap {
  margin-top: 0.75rem;
}

.mmr-scale {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: #4e5058;
  margin-bottom: 0.25rem;
}

.mmr-track {
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.mmr-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    var(--section-accent),
    var(--section-bar-end)
  );
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 0.75rem;
}

.stat-card {
  border-radius: 8px;
  padding: 1rem;
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
}

.stat-card-value {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--section-accent);
  margin-bottom: 0.125rem;
}

.stat-card-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--color-text-muted);
  line-height: 1.3;
}

@media (max-width: 720px) {
  .section-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .rank-grid,
  .stat-grid,
  .game-blocks {
    grid-template-columns: 1fr 1fr;
  }

  .rank-name {
    font-size: 2.25rem;
  }

  .sky-top-stats {
    grid-template-columns: 1fr 1fr 1fr;
  }
}

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

.placeholder-note {
  margin-top: 1rem;
  padding: 1rem 1.25rem;
  border: 1px dashed var(--border);
  border-radius: 8px;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 12px;
}

@media (max-width: 640px) {
  .site-header {
    padding: 0 1rem;
    gap: 1rem;
  }

  .nav {
    gap: 0.75rem;
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .hero {
    padding: 2.5rem 1rem;
  }

  .hero h1 {
    font-size: 2.75rem;
  }

  .sections {
    padding: 0 1rem 4rem;
    gap: 4rem;
  }
}
