:root {
  --bg: #ffffff;
  --text: #1b1b1f;
  --muted: #6b6b74;
  --border: #e2e2e5;
  --surface: #f9f9fb;
  --accent: #1b1b1f;
  --accent-hover: #3a3a40;
  --accent-gold: #c69c6d;
  --accent-gold-hover: #b38b5e;
  --editor-bg: #1b1b1f;
  --editor-sidebar: #232326;
  --editor-panel: #1f1f23;
  --editor-border: #34343a;
  --editor-fg: #d7d7d9;
  --editor-muted: #9ca3af;
  --editor-accent: #c69c6d;
  --editor-active: #2c2c31;
  --font-body: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    Roboto, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas,
    monospace;
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 24px 48px rgba(0, 0, 0, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: inherit;
  text-decoration: none;
}

.container {
  width: min(760px, 92%);
  margin: 0 auto;
}

.container--wide {
  width: min(960px, 92%);
}

.container--narrow {
  width: min(640px, 92%);
}

.site-header {
  padding: 1rem 0;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(8px);
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  font-weight: 600;
  font-size: 1.125rem;
}

.wordmark-icon {
  display: block;
  width: 28px;
  height: 28px;
  border-radius: 7px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.wordmark-name {
  letter-spacing: -0.02em;
}

.hero {
  padding: 5rem 0 4rem;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  top: -40%;
  right: -20%;
  width: 70%;
  height: 100%;
  background: radial-gradient(
    circle at 70% 30%,
    rgba(198, 156, 109, 0.08),
    transparent 60%
  );
  pointer-events: none;
}

.hero-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 3rem;
}

.hero-content {
  max-width: 540px;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--accent-gold);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 1rem;
}

.hero-eyebrow::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-gold);
}

.hero h1 {
  font-size: clamp(2.5rem, 6vw, 3.75rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin: 0 0 1.25rem;
}

.lead {
  font-size: 1.125rem;
  color: var(--muted);
  max-width: 520px;
  margin: 0 0 2rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  font-weight: 500;
  border-radius: 0.5rem;
  transition: transform 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.button:hover {
  transform: translateY(-1px);
}

.button--primary {
  color: #ffffff;
  background: var(--accent);
  box-shadow: var(--shadow-sm);
}

.button--primary:hover {
  background: var(--accent-hover);
  box-shadow: var(--shadow-md);
}

.button--secondary {
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border);
}

.button--secondary:hover {
  background: #ffffff;
  border-color: var(--accent-gold);
  box-shadow: var(--shadow-sm);
}

.hero-visual {
  position: relative;
  flex-shrink: 0;
  width: 320px;
  height: 280px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-icon {
  position: absolute;
  bottom: -0.5rem;
  right: -1rem;
  width: 120px;
  height: 120px;
  border-radius: 28px;
  box-shadow: var(--shadow-lg);
  animation: float 6s ease-in-out infinite;
}

.code-window {
  width: 280px;
  background: var(--editor-bg);
  border: 1px solid var(--editor-border);
  border-radius: 0.75rem;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  line-height: 1.6;
  color: var(--editor-fg);
}

.code-window--small {
  width: 100%;
  max-width: 420px;
  font-size: 0.75rem;
}

.code-window-header {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.625rem 0.875rem;
  background: var(--editor-panel);
  border-bottom: 1px solid var(--editor-border);
}

.code-window-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--editor-muted);
  opacity: 0.6;
}

.code-window-title {
  margin-left: auto;
  font-size: 0.6875rem;
  color: var(--editor-muted);
}

.code-window-body {
  padding: 1rem;
}

.code-window-body pre {
  margin: 0;
  overflow-x: auto;
}

.code-window-body code {
  font-family: inherit;
}

.code-keyword {
  color: #c586c0;
}

.code-function {
  color: #dcdcaa;
}

.code-string {
  color: #ce9178;
}

.code-comment {
  color: #6a9955;
}

.code-prompt {
  color: var(--accent-gold);
  margin-right: 0.5rem;
}

.section {
  padding: 5rem 0;
  border-top: 1px solid var(--border);
}

.section h2 {
  font-size: 0.875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin: 0 0 1.5rem;
}

.section--values {
  padding: 3rem 0;
}

.value-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.value-card {
  padding: 1.5rem;
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  background: var(--surface);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.value-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--accent-gold);
}

.value-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-gold);
  background: rgba(198, 156, 109, 0.1);
  border-radius: 0.625rem;
  margin-bottom: 1rem;
}

.value-card h3 {
  font-size: 1.0625rem;
  font-weight: 600;
  margin: 0 0 0.375rem;
}

.value-card p {
  font-size: 0.9375rem;
  color: var(--muted);
  margin: 0;
  line-height: 1.55;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
}

.feature-card {
  padding: 1.25rem;
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  background: #ffffff;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.feature-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.feature-card h3 {
  font-size: 1rem;
  font-weight: 600;
  margin: 0 0 0.375rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.feature-card h3::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-gold);
}

.feature-card p {
  font-size: 0.9375rem;
  color: var(--muted);
  margin: 0;
  line-height: 1.55;
}

.screenshot-gallery {
  margin-top: 0.5rem;
}

.screenshot-tabs {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
}

.screenshot-tab {
  padding: 0.5rem 1rem;
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--muted);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 9999px;
  cursor: pointer;
  transition: color 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}

.screenshot-tab:hover {
  color: var(--text);
  border-color: var(--accent-gold);
}

.screenshot-tab.is-active {
  color: #ffffff;
  background: var(--accent);
  border-color: var(--accent);
}

.screenshot-panes {
  position: relative;
}

.screenshot-pane {
  margin: 0;
  display: none;
  animation: fade-in 0.4s ease;
}

.screenshot-pane.is-active {
  display: block;
}

.screenshot-frame {
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  background: var(--editor-bg);
  padding-top: 28px;
  position: relative;
}

.screenshot-frame::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 28px;
  background: var(--editor-panel);
  border-bottom: 1px solid var(--editor-border);
}

.screenshot-frame::after {
  content: "";
  position: absolute;
  top: 10px;
  left: 12px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ff5f57;
  box-shadow: 14px 0 0 #febc2e, 28px 0 0 #28c840;
}

.screenshot-frame img {
  display: block;
  width: 100%;
  height: auto;
}

.screenshot-pane figcaption {
  margin-top: 0.875rem;
  font-size: 0.875rem;
  color: var(--muted);
  text-align: center;
}

.section--install {
  padding: 4rem 0;
}

.install-card {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.5rem;
  align-items: center;
  padding: 2.5rem;
  background: linear-gradient(135deg, var(--surface) 0%, #ffffff 100%);
  border: 1px solid var(--border);
  border-radius: 1rem;
  box-shadow: var(--shadow-md);
}

.install-content h2 {
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 0.875rem;
  color: var(--text);
  text-transform: none;
}

.install-content p {
  color: var(--muted);
  margin: 0 0 1.5rem;
  line-height: 1.6;
}

.install-terminal {
  display: flex;
  justify-content: center;
}

.contribute-card {
  text-align: center;
  padding: 3rem 2rem;
  border: 1px solid var(--border);
  border-radius: 1rem;
  background: var(--surface);
}

.contribute-card h2 {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 0.75rem;
  color: var(--text);
  text-transform: none;
}

.contribute-card p {
  color: var(--muted);
  max-width: 480px;
  margin: 0 auto 1.5rem;
  line-height: 1.6;
}

.site-footer {
  padding: 3rem 0;
  border-top: 1px solid var(--border);
  font-size: 0.875rem;
  color: var(--muted);
}

.footer-line {
  margin: 0 0 0.25rem;
}

.footer-line:last-child {
  margin-bottom: 0;
}

.footer-line--subtle {
  color: var(--muted);
}

.site-footer a:hover {
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.footer-separator {
  margin: 0 0.5rem;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

@keyframes fade-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 800px) {
  .hero-container {
    flex-direction: column-reverse;
    align-items: flex-start;
    gap: 2.5rem;
  }

  .hero-visual {
    width: 100%;
    height: auto;
    justify-content: flex-start;
  }

  .hero-icon {
    width: 80px;
    height: 80px;
    right: 0;
    bottom: -1rem;
  }

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

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

  .install-card {
    grid-template-columns: 1fr;
  }

  .install-terminal {
    justify-content: flex-start;
  }

  .code-window--small {
    max-width: 100%;
  }
}

@media (max-width: 480px) {
  .hero {
    padding: 3.5rem 0 2.5rem;
  }

  .hero-actions {
    flex-direction: column;
    align-items: flex-start;
  }

  .button {
    width: 100%;
  }

  .section {
    padding: 3.5rem 0;
  }

  .install-card {
    padding: 1.5rem;
  }
}
