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

  /* Chrome and Opera */
  user-select: none;

  /* Safari */
  -webkit-user-select: none;

  /* Konqueror HTML */
  -khtml-user-select: none;

  /* Firefox */
  -moz-user-select: none;

  /* Internet Explorer/Edge */
  -ms-user-select: none;
}

:link {
  color: #6f6;
}

:visited {
  color: #66f;
}

/* ---------- Design tokens ---------- */
:root {
  --brand: #ccffcc;
  --brand-mid: #a8f0a8;
  --brand-dark: #5ecf6a;
  --brand-text: #1a6b1a;
  --bg: #f4fef4;
  --bg-alt: #edfced;
  --surface: rgba(255, 255, 255, 0.55);
  --surface-hover: rgba(255, 255, 255, 0.75);
  --border: rgba(180, 240, 180, 0.55);
  --text: #1a2e1a;
  --text-muted: #4a6f4a;
  --text-faint: #7fa87f;
  --shadow-sm: 0 2px 12px rgba(100, 200, 100, 0.12);
  --shadow-md: 0 8px 32px rgba(80, 160, 80, 0.16);
  --shadow-lg: 0 16px 56px rgba(60, 130, 60, 0.18);
  --blur: 18px;
  --radius: 16px;
  --radius-sm: 10px;
  --radius-lg: 24px;
  --font: 'Jua', sans-serif;
  --font-code: 'Fira Code', 'Consolas', 'Monaco', monospace;
  --nav-h: 64px;
  --transition: 0.22s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
  transition: background var(--transition), color var(--transition);
}

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

a:hover {
  text-decoration: underline;
}

em {
  font-style: italic;
}

strong {
  font-weight: 700;
}

code {
  font-family: var(--font-code);
  font-size: 0.85em;
  background: rgba(100, 200, 100, 0.15);
  color: var(--brand-text);
  padding: 0.15em 0.45em;
  border-radius: 5px;
}

.nav-logo-img {
  width: 28px;
  height: 28px;
  object-fit: contain;
}

.footer-logo {
  width: 16px;
  height: 16px;
  object-fit: contain;
  vertical-align: middle;
}

/* ---------- Ambient background blobs ---------- */
.bg-blobs {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.45;
  animation: blobDrift 18s ease-in-out infinite alternate;
}

.blob-1 {
  width: 520px;
  height: 520px;
  background: radial-gradient(circle, #b8ffb8, #ccffcc88);
  top: -120px;
  left: -100px;
  animation-duration: 20s;
}

.blob-2 {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, #a0f0a0, #e0ffe088);
  bottom: 80px;
  right: -80px;
  animation-duration: 16s;
  animation-delay: -6s;
}

.blob-3 {
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, #d4ffd4, #ccffcc44);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  animation-duration: 24s;
  animation-delay: -12s;
}

@keyframes blobDrift {
  0% {
    transform: translate(0, 0) scale(1);
  }

  50% {
    transform: translate(30px, -20px) scale(1.05);
  }

  100% {
    transform: translate(-20px, 30px) scale(0.97);
  }
}

/* ---------- Glass utility ---------- */
.glass {
  background: var(--surface);
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

/* ---------- Font picker ---------- */
.font-picker-wrapper {
  position: fixed;
  top: calc(var(--nav-h) + 12px);
  right: 20px;
  z-index: 200;
}

.font-picker-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
  color: var(--text);
  font-family: var(--font);
  font-size: 0.85rem;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: background var(--transition), box-shadow var(--transition);
}

.font-picker-toggle:hover {
  background: var(--surface-hover);
  box-shadow: var(--shadow-md);
}

.font-dropdown {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  min-width: 160px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--surface);
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
  animation: dropIn 0.18s ease;
}

.font-dropdown.open {
  display: block;
}

@keyframes dropIn {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.font-option {
  padding: 10px 18px;
  cursor: pointer;
  font-size: 0.9rem;
  transition: background var(--transition);
  color: var(--text);
}

.font-option:hover {
  background: rgba(180, 240, 180, 0.3);
}

.font-option.active {
  background: var(--brand);
  color: var(--brand-text);
  font-weight: 700;
}

/* ---------- Navbar ---------- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-h);
  z-index: 100;
  border-top: none;
  border-left: none;
  border-right: none;
  border-radius: 0;
}

.nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

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

.nav-logo {
  font-size: 1.4rem;
}

.nav-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--brand-text);
  letter-spacing: -0.02em;
}

.nav-badge {
  font-size: 0.65rem;
  font-weight: 700;
  background: var(--brand-dark);
  color: #fff;
  padding: 1px 7px;
  border-radius: 999px;
  letter-spacing: 0.04em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-link {
  padding: 6px 13px;
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  color: var(--text-muted);
  transition: background var(--transition), color var(--transition);
}

.nav-link:hover {
  background: rgba(180, 240, 180, 0.3);
  color: var(--text);
  text-decoration: none;
}

.nav-link-docs {
  background: var(--brand);
  color: var(--brand-text) !important;
  font-weight: 700;
}

.nav-link-docs:hover {
  background: var(--brand-mid);
  text-decoration: none;
}

/* ---------- Hamburger button ---------- */
.nav-hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  padding: 6px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background var(--transition);
}

.nav-hamburger:hover {
  background: rgba(180, 240, 180, 0.3);
}

.nav-hamburger span {
  display: block;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform var(--transition), opacity var(--transition);
}

/* ---------- Mobile sidebar ---------- */
.nav-sidebar {
  position: fixed;
  top: 0;
  right: 0;
  height: 100%;
  width: 280px;
  max-width: 85vw;
  background: var(--bg);
  border-left: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  z-index: 300;
  display: flex;
  flex-direction: column;
  padding: 20px;
  transform: translateX(100%);
  transition: transform 0.28s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-sidebar.open {
  transform: translateX(0);
}

.nav-sidebar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 32px;
}

.nav-sidebar-close {
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  width: 32px;
  height: 32px;
  font-size: 1rem;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--transition);
}

.nav-sidebar-close:hover {
  background: rgba(180, 240, 180, 0.3);
}

.nav-sidebar-links {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nav-sidebar-link {
  display: block;
  padding: 11px 14px;
  border-radius: var(--radius-sm);
  font-size: 1rem;
  color: var(--text-muted);
  text-decoration: none;
  transition: background var(--transition), color var(--transition);
}

.nav-sidebar-link:hover {
  background: rgba(180, 240, 180, 0.3);
  color: var(--text);
  text-decoration: none;
}

.nav-sidebar-link-docs {
  margin-top: 12px;
  background: var(--brand);
  color: var(--brand-text) !important;
  font-weight: 700;
}

.nav-sidebar-link-docs:hover {
  background: var(--brand-mid);
}

/* Overlay */
.nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.25);
  z-index: 299;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.28s ease;
}

.nav-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  border: none;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition);
  text-decoration: none !important;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn:active {
  transform: translateY(0);
}

.btn-primary {
  background: var(--brand-dark);
  color: #fff;
  box-shadow: 0 4px 18px rgba(80, 180, 80, 0.35);
  font-size: 1.05rem;
  padding: 14px 30px;
}

.btn-primary:hover {
  background: #4ab856;
  box-shadow: 0 8px 28px rgba(80, 180, 80, 0.45);
}

.btn-secondary {
  background: var(--surface);
  color: var(--brand-text);
  border: 1.5px solid var(--brand-dark);
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
}

.btn-secondary:hover {
  background: var(--brand);
  box-shadow: var(--shadow-sm);
}

.btn-lg {
  font-size: 1.1rem;
  padding: 15px 34px;
}

/* ---------- Hero ---------- */
.hero {
  min-height: 100vh;
  padding-top: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 60px;
  padding-left: 24px;
  padding-right: 24px;
  max-width: 1100px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.hero-inner {
  flex: 1;
  max-width: 560px;
}

.hero-eyebrow {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  background: rgba(180, 240, 180, 0.35);
  padding: 4px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  margin-bottom: 20px;
}

.hero-title {
  margin-bottom: 18px;
}

.hero-title-main {
  display: block;
  font-size: clamp(3.2rem, 8vw, 5.5rem);
  line-height: 1;
  color: var(--brand-text);
  letter-spacing: -0.03em;
}

.hero-title-sub {
  display: block;
  font-size: clamp(1rem, 2.5vw, 1.35rem);
  color: var(--text-muted);
  font-weight: 400;
  margin-top: 6px;
  letter-spacing: 0;
}

.hero-desc {
  font-size: 1rem;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 28px;
  max-width: 480px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 16px;
}

.hero-hint {
  font-size: 0.82rem;
  color: var(--text-faint);
}

/* Terminal mock */
.hero-visual {
  flex: 0 0 auto;
  width: 340px;
}

.terminal {
  border-radius: var(--radius);
  overflow: hidden;
  font-family: var(--font-code);
  font-size: 0.82rem;
}

.terminal-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 16px;
  background: rgba(200, 240, 200, 0.5);
  border-bottom: 1px solid var(--border);
}

.dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
}

.dot-red {
  background: #ff6058;
}

.dot-yellow {
  background: #ffbd2e;
}

.dot-green {
  background: #28c840;
}

.terminal-title {
  margin-left: 8px;
  font-size: 0.75rem;
  color: var(--text-muted);
  font-family: var(--font);
}

.terminal-body {
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.terminal-line {
  color: var(--text);
  line-height: 1.5;
}

.t-dim {
  color: var(--text-faint);
}

.t-green {
  color: var(--brand-dark);
}

.t-yellow {
  color: #c9900c;
}

.cursor-blink {
  display: inline-block;
  animation: blink 1s step-end infinite;
  color: var(--brand-dark);
}

@keyframes blink {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0;
  }
}

/* ---------- Sections ---------- */
.section {
  padding: 96px 24px;
  position: relative;
  z-index: 1;
}

.section-alt {
  background: linear-gradient(180deg, transparent, rgba(204, 255, 204, 0.25), transparent);
}

.section-inner {
  max-width: 1000px;
  margin: 0 auto;
}

.section-label {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--brand-dark);
  background: rgba(180, 240, 180, 0.3);
  padding: 3px 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  margin-bottom: 14px;
}

.section-title {
  font-size: clamp(1.7rem, 4vw, 2.6rem);
  color: var(--brand-text);
  margin-bottom: 20px;
  letter-spacing: -0.02em;
}

.section-body {
  font-size: 1rem;
  color: var(--text-muted);
  line-height: 1.75;
  max-width: 640px;
  margin-bottom: 48px;
}

/* Feature grid */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 20px;
}

.feature-card {
  padding: 24px;
  border-radius: var(--radius);
  transition: transform var(--transition), box-shadow var(--transition);
}

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

.feature-icon {
  font-size: 2rem;
  margin-bottom: 12px;
}

.feature-card h3 {
  font-size: 1rem;
  color: var(--brand-text);
  margin-bottom: 8px;
}

.feature-card p {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.65;
}

/* Prose card */
.prose-card {
  padding: 32px 36px;
  border-radius: var(--radius-lg);
  max-width: 760px;
}

.prose-card p {
  font-size: 0.97rem;
  color: var(--text-muted);
  line-height: 1.8;
  margin-bottom: 16px;
}

.prose-card p:last-child {
  margin-bottom: 0;
}

/* ---------- Steps ---------- */
.steps {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.step {
  display: flex;
  gap: 24px;
  padding: 28px 30px;
  border-radius: var(--radius);
  align-items: flex-start;
  transition: box-shadow var(--transition);
}

.step:hover {
  box-shadow: var(--shadow-md);
}

.step-number {
  flex: 0 0 auto;
  font-size: 2rem;
  font-weight: 700;
  color: var(--brand-mid);
  line-height: 1;
  margin-top: 2px;
  letter-spacing: -0.03em;
  min-width: 44px;
}

.step-content {
  flex: 1;
  min-width: 0;
}

.step-content h3 {
  font-size: 1.05rem;
  color: var(--brand-text);
  margin-bottom: 10px;
}

.step-content p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 14px;
}

.step-content p:last-child {
  margin-bottom: 0;
}

.step-note {
  font-size: 0.82rem !important;
  color: var(--text-faint) !important;
  background: rgba(180, 240, 180, 0.2);
  border-left: 3px solid var(--brand-mid);
  padding: 10px 14px !important;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin-top: 12px !important;
}

/* ---------- Code blocks ---------- */
.code-block-wrapper {
  position: relative;
  margin: 14px 0;
  border-radius: var(--radius-sm);
  overflow: hidden;         /* clips child backgrounds to rounded corners */
  border: 1px solid var(--border);
  max-width: 100%;
  width: 100%;
}

.code-block-wrapper pre {
  margin: 0;
  overflow-x: auto;         /* horizontal scroll when content is wider than container */
  -webkit-overflow-scrolling: touch; /* smooth scrolling on iOS */
  font-size: 0.82rem;
  background: rgba(240, 254, 240, 0.85) !important;
  /* no max-width here — the wrapper constrains width; pre scrolls its content */
}

.code-block-wrapper code {
  background: transparent !important;
  padding: 0 !important;
  border-radius: 0 !important;
  font-size: inherit;
  color: inherit;
}

.code-block-wrapper .hljs {
  padding: 18px 20px;
  background: rgba(240, 254, 240, 0.85) !important;
}

.copy-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  padding: 4px 12px;
  font-family: var(--font);
  font-size: 0.75rem;
  font-weight: 700;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.85);
  color: var(--text-muted);
  cursor: pointer;
  z-index: 5;
  transition: background var(--transition), color var(--transition);
}

.copy-btn:hover {
  background: var(--brand);
  color: var(--brand-text);
}

.copy-btn.copied {
  background: var(--brand-dark);
  color: #fff;
}

/* ---------- CTA strip ---------- */
.cta-strip {
  padding: 48px 24px 80px;
  position: relative;
  z-index: 1;
}

.cta-inner {
  max-width: 760px;
  margin: 0 auto;
  border-radius: var(--radius-lg);
  padding: 44px 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
  background: linear-gradient(135deg, rgba(204, 255, 204, 0.65), rgba(255, 255, 255, 0.5));
}

.cta-text h2 {
  font-size: 1.6rem;
  color: var(--brand-text);
  margin-bottom: 8px;
}

.cta-text p {
  font-size: 0.92rem;
  color: var(--text-muted);
  max-width: 360px;
  line-height: 1.65;
}

/* ---------- Footer ---------- */
.footer {
  border-top: 1px solid var(--border);
  padding: 20px 24px;
  position: relative;
  z-index: 1;
  background: rgba(240, 254, 240, 0.6);
}

.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 0.83rem;
  color: var(--text-faint);
}

.footer-sep {
  color: var(--border);
}

.footer-fka {
  font-style: italic;
  opacity: 0.7;
}

/* ---------- Scroll reveal animations ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- Responsive ---------- */
@media (max-width: 820px) {
  .hero {
    flex-direction: column;
    padding-top: calc(var(--nav-h) + 32px);
    gap: 40px;
    text-align: center;
  }

  .hero-inner {
    max-width: 100%;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-visual {
    width: 100%;
    max-width: 340px;
  }

  .nav-links {
    display: none;
  }

  .nav-hamburger {
    display: flex;
  }

  .font-picker-wrapper {
    top: auto;
    bottom: 20px;
    right: 16px;
  }

  .step {
    flex-direction: column;
    gap: 12px;
  }

  .step-number {
    font-size: 1.4rem;
  }

  .cta-inner {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 500px) {
  .hero-title-main {
    font-size: 3rem;
  }

  .section {
    padding: 64px 16px;
  }

  .prose-card {
    padding: 22px;
  }

  .step {
    padding: 20px;
  }

}

/* Ensure inline code wraps rather than overflows on narrow screens */
@media (max-width: 640px) {
  code {
    word-break: break-word;
  }

  .nav-inner {
    padding: 0 16px;
  }

  .hero {
    padding-left: 16px;
    padding-right: 16px;
  }

  .cta-inner {
    padding: 28px 22px;
  }

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

/* ---------- Very narrow screens (≥260px) ---------- */
@media (max-width: 320px) {
  html {
    font-size: 14px;
  }

  .nav-inner {
    padding: 0 10px;
  }

  .nav-badge {
    display: none;
  }

  .hero {
    padding-left: 12px;
    padding-right: 12px;
    gap: 28px;
  }

  .hero-title-main {
    font-size: 2.2rem;
  }

  .hero-title-sub {
    font-size: 0.95rem;
  }

  .hero-desc {
    font-size: 0.88rem;
  }

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

  .hero-actions .btn {
    justify-content: center;
    width: 100%;
  }

  .section {
    padding: 48px 12px;
  }

  .section-title {
    font-size: 1.5rem;
  }

  .prose-card {
    padding: 16px;
  }

  .step {
    padding: 16px;
  }

  .step-number {
    font-size: 1.1rem;
  }

  .cta-inner {
    padding: 20px 16px;
  }

  .cta-text h2 {
    font-size: 1.2rem;
  }

  .nav-sidebar {
    width: 100%;
    max-width: 100%;
  }

  .font-picker-wrapper {
    right: 10px;
    bottom: 16px;
  }

  .font-picker-toggle {
    padding: 5px 10px;
    font-size: 0.78rem;
  }

  .footer-inner {
    font-size: 0.75rem;
    gap: 6px;
  }
}

/* Global overflow guard — prevents horizontal scroll at any width */
html {
  overflow-x: hidden;
}