:root {
  --bg: #0a0d14;
  --bg-gradient: radial-gradient(circle at 50% 0%, rgba(99, 102, 241, 0.12) 0%, rgba(10, 13, 20, 1) 75%);
  --card: #121724;
  --card-border: rgba(255, 255, 255, 0.08);
  --text: #e2e8f0;
  --text-muted: #94a3b8;
  --text-heading: #ffffff;
  --accent: #818cf8;
  --accent-hover: #a5b4fc;
  --line: #1e293b;
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html {
  background-color: var(--bg);
}

body {
  margin: 0;
  background: var(--bg);
  background-image: var(--bg-gradient);
  background-attachment: fixed;
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  padding: env(safe-area-inset-top) 0 env(safe-area-inset-bottom);
  min-height: 100vh;
}

header, main, footer {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 24px;
}

header {
  padding-top: 24px;
  padding-bottom: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  border-bottom: 1px solid var(--line);
}

header a.brand {
  font-weight: 800;
  font-size: 1.25rem;
  letter-spacing: -0.025em;
  background: linear-gradient(135deg, #ffffff 0%, #cbd5e1 50%, #818cf8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

nav a {
  padding: 6px 14px;
  border-radius: 8px;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  transition: all 0.15s ease;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

nav a:hover, nav a:focus-visible {
  color: #ffffff;
  background: rgba(99, 102, 241, 0.15);
  border-color: rgba(99, 102, 241, 0.35);
  text-decoration: none;
}

main {
  padding-top: 40px;
  padding-bottom: 20px;
}

h1 {
  font-size: 2.25rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.2;
  margin: 0 0 8px;
  color: var(--text-heading);
}

.muted {
  color: var(--text-muted);
  font-size: 0.875rem;
  margin-top: 0;
  margin-bottom: 28px;
}

h2 {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.015em;
  margin: 36px 0 12px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  color: var(--text-heading);
}

p {
  margin: 14px 0;
  color: var(--text);
}

strong {
  color: #ffffff;
  font-weight: 600;
}

a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.15s ease;
}

a:hover, a:focus-visible {
  color: var(--accent-hover);
  text-decoration: underline;
}

ul {
  padding-left: 20px;
  margin: 14px 0;
}

li {
  margin-bottom: 8px;
  color: var(--text);
}

.note {
  background: rgba(18, 23, 36, 0.7);
  border: 1px solid rgba(99, 102, 241, 0.25);
  border-radius: 12px;
  padding: 16px 20px;
  margin: 24px 0;
  color: #cbd5e1;
  box-shadow: 0 4px 20px -4px rgba(0, 0, 0, 0.4);
}

footer {
  margin-top: 48px;
  padding-top: 28px;
  padding-bottom: 48px;
  border-top: 1px solid var(--line);
  font-size: 0.875rem;
  color: var(--text-muted);
  display: flex;
  flex-direction: column;
  gap: 14px;
}

footer a {
  color: var(--text-muted);
  margin-right: 16px;
  font-size: 0.875rem;
  text-decoration: none;
}

footer a:hover {
  color: #ffffff;
  text-decoration: underline;
}

footer p {
  margin: 4px 0 0;
  color: #64748b;
  font-size: 0.8125rem;
}

/* Custom scrollbars */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: rgba(15, 23, 42, 0.6);
}
::-webkit-scrollbar-thumb {
  background: rgba(99, 102, 241, 0.4);
  border-radius: 9999px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(99, 102, 241, 0.8);
}
