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

:root {
  --bg: #0d0e10;
  --bg-code: #0a0b0d;
  --border: #1e2128;
  --border-hi: #2e3240;
  --text: #c8cdd8;
  --text-dim: #5a6070;
  --text-hi: #edf0f6;
  --accent: #7c3aed;
  --accent-dim: #5f4aa8;
  --green: #4caf7d;
  --mono: "IBM Plex Mono", "SF Mono", "Cascadia Code", Menlo, Consolas, monospace;
  --sans: "IBM Plex Sans", "Avenir Next", "Segoe UI", sans-serif;
  --display: "Rajdhani", "Segoe UI", sans-serif;
  --max-w: 1100px;
  --gutter: clamp(1.25rem, 5vw, 2.5rem);
}

html {
  scroll-behavior: smooth;
}

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

a {
  color: var(--accent);
  text-decoration: none;
}

a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--accent);
  color: #0d0e10;
  padding: 0.6rem 0.9rem;
  z-index: 120;
  font-family: var(--mono);
  font-size: 0.75rem;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

section {
  padding: clamp(4rem, 10vw, 6rem) 0;
  border-top: 1px solid var(--border);
}

section:first-of-type {
  border-top: none;
}

h1,
h2,
h3 {
  font-family: var(--display);
  color: var(--text-hi);
  letter-spacing: -0.02em;
}

h1 {
  font-size: clamp(3rem, 8vw, 5.5rem);
  font-weight: 800;
  line-height: 0.95;
}

h2 {
  font-size: clamp(1.5rem, 4vw, 2.25rem);
  font-weight: 700;
  margin-bottom: 2rem;
}

h3 {
  font-size: 1rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  margin-bottom: 0.5rem;
}

p {
  color: var(--text);
  max-width: 62ch;
}

code,
pre {
  font-family: var(--mono);
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(13, 14, 16, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

.topbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 3.4rem;
}

.topbar-logo {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text-hi);
  letter-spacing: -0.02em;
}

.topbar-logo span {
  color: var(--accent);
}

.topbar-links {
  display: flex;
  gap: 1.25rem;
  align-items: center;
}

.topbar-links a {
  font-family: var(--mono);
  font-size: 0.8rem;
  color: var(--text-dim);
  transition: color 0.15s;
}

.topbar-links a:hover {
  color: var(--text-hi);
}

#hero {
  padding: clamp(5rem, 12vw, 9rem) 0 clamp(4rem, 8vw, 6rem);
}

#hero h1 {
  margin-bottom: 1.5rem;
}

#hero p {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  margin-bottom: 2.4rem;
  max-width: 54ch;
  line-height: 1.5;
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
}

.btn-primary,
.btn-ghost {
  display: inline-flex;
  align-items: center;
  padding: 0.7rem 1.25rem;
  font-family: var(--mono);
  font-size: 0.8rem;
}

.btn-primary {
  border: 1px solid transparent;
  background: var(--accent);
  color: #0b0c0f;
  font-weight: 600;
  transition: filter 0.15s;
}

.btn-primary:hover {
  filter: brightness(1.08);
}

.btn-ghost {
  border: 1px solid var(--border-hi);
  color: var(--text);
  transition: border-color 0.15s, color 0.15s;
}

.btn-ghost:hover {
  border-color: var(--text-dim);
  color: var(--text-hi);
}

.brew-snippet {
  display: inline-block;
  padding: 0.7rem 1rem;
  background: var(--bg-code);
  border: 1px solid var(--border-hi);
  font-size: 0.84rem;
  color: var(--green);
  user-select: all;
}

.what-list {
  display: grid;
  gap: 0.85rem;
  margin-top: 0.25rem;
  max-width: 78ch;
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  line-height: 1.5;
  list-style: none;
  padding: 0;
}

#demo,
#demo + section {
  border-top: none;
}

#demo + section {
  padding-top: 2rem;
}

#demo {
  padding: 0;
}

.demo-caption {
  width: calc(100% - 60px);
  max-width: 800px;
  margin: 0 auto 0.75rem;
  margin-bottom: 20px;
}

#demo video {
  display: block;
  width: calc(100% - 60px);
  max-width: 800px;
  margin: 0 auto;
}

.code-block-wrap {
  background: var(--bg-code);
  border: 1px solid var(--border-hi);
  overflow-x: auto;
}

.code-header {
  display: flex;
  align-items: center;
  padding: 0.6rem 1rem;
  border-bottom: 1px solid var(--border);
  gap: 0.4rem;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--border-hi);
}

.code-label {
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--text-dim);
  margin-left: 0.4rem;
}

.code-block-wrap pre {
  padding: 1.5rem;
  font-size: 0.875rem;
  line-height: 1.9;
}

.cmd-prefix {
  color: var(--accent-dim);
  user-select: none;
}

.cmd-main {
  color: var(--accent);
}

.cmd-sub {
  color: var(--text-hi);
}

.cmd-flag {
  color: #7a9ec8;
}

.cmd-val {
  color: #8fcfa8;
}

.cmd-comment {
  color: var(--text-dim);
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid var(--border);
  margin-top: 2rem;
}

.step {
  padding: 2rem 1.75rem;
  border-right: 1px solid var(--border);
}

.step:last-child {
  border-right: none;
}

.step-num,
.step-icon {
  margin-bottom: 1rem;
}

.step-num {
  font-family: var(--display);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--accent);
  text-transform: uppercase;
}

.step-icon {
  font-size: 1.75rem;
  display: block;
}

.step h3 {
  font-size: 20px;
  font-weight: 700;
  text-transform: none;
  letter-spacing: -0.01em;
  margin-bottom: 0.5rem;
}

.step p {
  font-size: 20px;
  max-width: 30ch;
}

footer {
  border-top: 1px solid var(--border);
  padding: 2rem 0;
  font-family: var(--mono);
}

footer .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-left {
  font-size: 0.8rem;
  color: var(--text-dim);
}

.footer-left strong {
  color: var(--text-hi);
  font-family: var(--display);
  font-weight: 700;
}

.footer-right {
  display: flex;
  gap: 1.25rem;
  font-size: 0.75rem;
}

.footer-right a {
  color: var(--text-dim);
  transition: color 0.15s;
}

.footer-right a:hover {
  color: var(--text-hi);
}

@media (max-width: 760px) {
  .topbar-links {
    display: none;
  }

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

  .step {
    border-right: none;
    border-bottom: 1px solid var(--border);
  }

  .step:last-child {
    border-bottom: none;
  }

  .demo-caption,
  #demo video {
    width: 100%;
    margin-left: 0;
    margin-right: 0;
  }

}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
