:root {
  color-scheme: light;
  --ink: #172026;
  --muted: #5b6871;
  --line: #d7e0e3;
  --paper: #fbfcfb;
  --panel: #ffffff;
  --mint: #27c59a;
  --teal: #0f766e;
  --coral: #f26d5b;
  --sun: #f6bd4a;
  --shadow: 0 24px 70px rgba(23, 32, 38, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    linear-gradient(180deg, rgba(39, 197, 154, 0.08), transparent 420px),
    var(--paper);
  color: var(--ink);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  letter-spacing: 0;
}

a {
  color: inherit;
}

.site-header {
  align-items: center;
  background: rgba(251, 252, 251, 0.86);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(215, 224, 227, 0.75);
  display: flex;
  gap: 24px;
  justify-content: space-between;
  min-height: 72px;
  padding: 0 clamp(20px, 5vw, 72px);
  position: sticky;
  top: 0;
  z-index: 3;
}

.brand,
.header-actions,
.nav-links,
.language-switcher,
.hero-actions,
.site-footer {
  align-items: center;
  display: flex;
}

.brand {
  font-weight: 800;
  gap: 10px;
  min-width: 0;
  text-decoration: none;
}

.brand-mark {
  align-items: center;
  background: var(--ink);
  border-radius: 8px;
  color: white;
  display: inline-flex;
  flex: 0 0 34px;
  height: 34px;
  justify-content: center;
}

.nav-links {
  color: var(--muted);
  gap: clamp(14px, 3vw, 28px);
  font-size: 0.95rem;
}

.header-actions {
  gap: clamp(14px, 2vw, 24px);
  min-width: 0;
}

.language-switcher {
  border: 1px solid var(--line);
  border-radius: 8px;
  flex: 0 0 auto;
  font-size: 0.82rem;
  overflow: hidden;
}

.language-switcher a {
  padding: 7px 9px;
  text-decoration: none;
}

.language-switcher a[aria-current="page"] {
  background: var(--ink);
  color: white;
  font-weight: 800;
}

.nav-links a,
.inline-link {
  text-decoration: none;
}

.nav-links a:hover,
.inline-link:hover {
  color: var(--teal);
}

.hero {
  display: grid;
  gap: clamp(32px, 6vw, 76px);
  grid-template-columns: minmax(0, 1.02fr) minmax(320px, 0.98fr);
  min-height: calc(82vh - 72px);
  padding: clamp(28px, 5vw, 54px) clamp(20px, 5vw, 72px) 28px;
}

.hero-copy {
  align-self: center;
  max-width: 720px;
}

.eyebrow {
  color: var(--teal);
  font-size: 0.78rem;
  font-weight: 800;
  margin: 0 0 14px;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  font-size: clamp(2.75rem, 6.2vw, 4.85rem);
  line-height: 1;
  margin-bottom: 24px;
}

h2 {
  font-size: clamp(2rem, 4vw, 3.5rem);
  line-height: 1;
  margin-bottom: 18px;
}

h3 {
  font-size: 1.1rem;
  margin-bottom: 10px;
}

.hero-text,
.section p {
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.7;
}

.hero-actions {
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.button {
  border: 1px solid var(--ink);
  border-radius: 8px;
  font-weight: 800;
  min-height: 46px;
  padding: 12px 18px;
  text-decoration: none;
}

.button.primary {
  background: var(--ink);
  color: white;
}

.button.secondary {
  background: transparent;
}

.terminal-card,
.code-panel,
.file-tree {
  border: 1px solid rgba(23, 32, 38, 0.12);
  border-radius: 8px;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.terminal-card {
  align-self: center;
  background: #172026;
  color: #e8fff7;
  margin: 0;
}

.terminal-chrome {
  background: #22313a;
  display: flex;
  gap: 8px;
  padding: 14px 16px;
}

.terminal-chrome span {
  border-radius: 999px;
  height: 12px;
  width: 12px;
}

.terminal-chrome span:nth-child(1) {
  background: var(--coral);
}

.terminal-chrome span:nth-child(2) {
  background: var(--sun);
}

.terminal-chrome span:nth-child(3) {
  background: var(--mint);
}

pre {
  margin: 0;
  overflow-x: auto;
  padding: 24px;
}

code {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: clamp(0.8rem, 1.2vw, 0.94rem);
  line-height: 1.75;
}

.terminal-card code {
  white-space: pre-wrap;
}

.section {
  padding: clamp(56px, 8vw, 96px) clamp(20px, 5vw, 72px);
}

.stats {
  background: var(--ink);
  color: white;
  display: grid;
  gap: 1px;
  grid-template-columns: repeat(3, 1fr);
  padding-bottom: 0;
  padding-top: 0;
}

.stats div {
  background: rgba(255, 255, 255, 0.06);
  min-height: 132px;
  padding: 28px;
}

.stats strong {
  display: block;
  font-size: clamp(2rem, 5vw, 3.6rem);
  line-height: 1;
}

.stats span {
  color: rgba(255, 255, 255, 0.72);
}

.split {
  align-items: center;
  display: grid;
  gap: clamp(28px, 6vw, 72px);
  grid-template-columns: minmax(0, 0.92fr) minmax(300px, 1.08fr);
}

.split.reverse {
  grid-template-columns: minmax(300px, 1.08fr) minmax(0, 0.92fr);
}

.code-panel,
.file-tree {
  background: var(--panel);
}

.section-heading {
  max-width: 760px;
}

.template-grid,
.faq-grid,
.use-case-grid,
.option-grid {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 32px;
}

.template-grid article,
.faq-grid article,
.use-case-grid article,
.option-grid article {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  min-height: 176px;
  padding: 24px;
}

.template-grid p,
.faq-grid p,
.use-case-grid p,
.option-grid p {
  font-size: 0.98rem;
}

.use-case-grid code,
.option-grid code {
  background: rgba(23, 32, 38, 0.07);
  border-radius: 4px;
  color: var(--ink);
  font-size: 0.9em;
  padding: 2px 5px;
}

.option-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 0;
}

.faq {
  background: rgba(15, 118, 110, 0.05);
}

.faq-grid article {
  min-height: 210px;
}

.faq-grid code {
  background: rgba(23, 32, 38, 0.07);
  border-radius: 4px;
  color: var(--ink);
  font-size: 0.9em;
  padding: 2px 5px;
}

.inline-link {
  color: var(--teal);
  display: inline-block;
  font-weight: 800;
  margin-top: 8px;
}

.site-footer {
  border-top: 1px solid var(--line);
  color: var(--muted);
  gap: 16px;
  justify-content: space-between;
  padding: 28px clamp(20px, 5vw, 72px);
}

.site-footer a {
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
}

@media (max-width: 900px) {
  .site-header,
  .header-actions,
  .nav-links,
  .site-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .site-header {
    gap: 12px;
    padding-bottom: 14px;
    padding-top: 14px;
    position: static;
  }

  .nav-links {
    flex-direction: row;
    flex-wrap: wrap;
  }

  .header-actions {
    gap: 12px;
  }

  .language-switcher {
    align-self: flex-start;
  }

  .hero,
  .split,
  .split.reverse,
  .template-grid,
  .faq-grid,
  .use-case-grid,
  .option-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
  }

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

@media (max-width: 560px) {
  .brand {
    font-size: 0.96rem;
  }

  .terminal-card,
  .code-panel,
  .file-tree {
    margin-left: -4px;
    margin-right: -4px;
  }

  pre {
    padding: 18px;
  }
}
