:root {
  --bg: #ffffff;
  --fg: #1a1a2e;
  --muted: #5a5a72;
  --accent: #6c5ce7;
  --card: #f4f4fb;
  --alt: #f9f9fd;
}

[data-theme="dark"] {
  --bg: #14141f;
  --fg: #eaeaf2;
  --muted: #a0a0b8;
  --accent: #a29bfe;
  --card: #1e1e2e;
  --alt: #1a1a28;
}

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

body {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--fg);
  line-height: 1.6;
  transition: background 0.3s, color 0.3s;
}

.hero {
  background: linear-gradient(135deg, var(--accent), #00cec9);
  color: #fff;
  padding: 1.5rem 2rem 5rem;
}

.nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 960px;
  margin: 0 auto;
}

.logo { font-weight: 700; font-size: 1.2rem; }

.nav-links { list-style: none; display: flex; gap: 1.5rem; }
.nav-links a { color: #fff; text-decoration: none; opacity: 0.9; }
.nav-links a:hover { opacity: 1; text-decoration: underline; }

.hero-content {
  max-width: 960px;
  margin: 4rem auto 0;
  text-align: center;
}
.hero-content h1 { font-size: 2.5rem; margin-bottom: 0.5rem; }
.hero-content p { font-size: 1.15rem; opacity: 0.95; margin-bottom: 1.5rem; }

.btn {
  display: inline-block;
  background: #fff;
  color: var(--accent);
  padding: 0.7rem 1.6rem;
  border-radius: 999px;
  font-weight: 600;
  text-decoration: none;
  border: none;
  cursor: pointer;
  font-size: 1rem;
  transition: transform 0.15s;
}
.btn:hover { transform: translateY(-2px); }

.section {
  max-width: 960px;
  margin: 0 auto;
  padding: 4rem 2rem;
}
.section.alt { background: var(--alt); max-width: none; }
.section.alt > * { max-width: 960px; margin-left: auto; margin-right: auto; }

.section h2 { font-size: 1.8rem; margin-bottom: 1rem; }
.section p { color: var(--muted); }

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}
.card {
  background: var(--card);
  padding: 1.5rem;
  border-radius: 12px;
}
.card h3 { margin-bottom: 0.5rem; }
.card p { color: var(--muted); }

#theme-toggle { margin-top: 1.5rem; background: var(--accent); color: #fff; }

.footer {
  text-align: center;
  padding: 2rem;
  color: var(--muted);
  font-size: 0.9rem;
}

@media (max-width: 600px) {
  .nav-links { gap: 0.9rem; font-size: 0.9rem; }
  .hero-content h1 { font-size: 1.9rem; }
}
