/* === Reset & Base === */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --bg-primary: #0d1117;
  --bg-secondary: #161b22;
  --accent-blue: #58a6ff;
  --accent-green: #3fb950;
  --text-primary: #e6edf3;
  --text-secondary: #8b949e;
  --border-color: #30363d;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --font-mono: "SF Mono", "Cascadia Code", "Fira Code", Consolas, "Liberation Mono", monospace;
}

html {
  scroll-behavior: smooth;
}

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

/* === Layout === */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

section {
  padding: 80px 0;
}

/* === Hero === */
.hero {
  min-height: 70vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, var(--border-color) 1px, transparent 1px);
  background-size: 24px 24px;
  opacity: 0.4;
  pointer-events: none;
}

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

.hero h1 {
  font-family: var(--font-mono);
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 700;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.hero .tagline {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  color: var(--text-secondary);
  max-width: 640px;
  margin: 0 auto 40px;
  line-height: 1.5;
}

/* === Buttons === */
.btn-primary {
  display: inline-block;
  padding: 14px 36px;
  background-color: var(--accent-blue);
  color: #ffffff;
  text-decoration: none;
  border-radius: 8px;
  font-size: 1.1rem;
  font-weight: 600;
  transition: opacity 0.2s, transform 0.2s;
}

.btn-primary:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

/* === Features === */
.features {
  background-color: var(--bg-secondary);
}

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

.feature-card {
  background-color: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 32px;
  transition: border-color 0.2s;
}

.feature-card:hover {
  border-color: var(--accent-blue);
}

.feature-card .icon {
  width: 40px;
  height: 40px;
  margin-bottom: 16px;
  color: var(--accent-green);
}

.feature-card h3 {
  font-family: var(--font-mono);
  font-size: 1.1rem;
  margin-bottom: 8px;
}

.feature-card p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.5;
}

/* === Screenshots === */
.screenshots {
  text-align: center;
}

.screenshots h2 {
  font-family: var(--font-mono);
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: 48px;
}

.screenshots-grid {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 40px;
  flex-wrap: wrap;
}

.screenshot-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.screenshot-item img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}

.screenshot-item .label {
  color: var(--text-secondary);
  font-size: 0.85rem;
}

/* === Quick Start === */
.quickstart {
  background-color: var(--bg-secondary);
}

.quickstart h2 {
  font-family: var(--font-mono);
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: 32px;
  text-align: center;
}

.code-block {
  background-color: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 24px;
  overflow-x: auto;
  max-width: 720px;
  margin: 0 auto;
}

.code-block pre {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  line-height: 1.7;
  white-space: pre;
}

.code-block .comment {
  color: var(--accent-green);
}

.code-block .command {
  color: var(--text-primary);
}

/* === Download === */
.download h2 {
  font-family: var(--font-mono);
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: 12px;
  text-align: center;
}

.download .subtitle {
  color: var(--text-secondary);
  text-align: center;
  margin-bottom: 48px;
}

.download-group {
  margin-bottom: 40px;
}

.download-group h3 {
  font-family: var(--font-mono);
  font-size: 1rem;
  color: var(--text-secondary);
  margin-bottom: 16px;
  text-align: center;
}

.download-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

.btn-download {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  background-color: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  text-decoration: none;
  font-size: 0.9rem;
  transition: border-color 0.2s, background-color 0.2s;
}

.btn-download:hover {
  border-color: var(--accent-blue);
  background-color: rgba(88, 166, 255, 0.1);
}

.btn-download svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* === Footer === */
.footer {
  border-top: 1px solid var(--border-color);
  padding: 24px 0;
  text-align: center;
  color: var(--text-secondary);
  font-size: 0.85rem;
}

/* === Section titles (shared) === */
.section-title {
  font-family: var(--font-mono);
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: 48px;
  text-align: center;
}

/* === Responsive === */
@media (max-width: 768px) {
  section {
    padding: 60px 0;
  }

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

  .screenshots-grid {
    flex-direction: column;
    align-items: center;
  }
}
