:root {
  /* Colors */
  --green-500: #22c55e;
  --green-700: #15803d;
  --neutral-50: #f8faf8;
  --neutral-600: #4b5548;
  --neutral-800: #1e2a1e;

  /* Type scale (Tailwind-aligned) */
  --text-xs: 0.75rem;   /* 12px */
  --text-sm: 0.875rem;  /* 14px */
  --text-base: 1rem;    /* 16px */
  --text-lg: 1.125rem;  /* 18px */
  --text-xl: 1.25rem;   /* 20px */
  --text-2xl: 1.5rem;   /* 24px */
  --text-3xl: 1.875rem; /* 30px */
  --text-4xl: 2.25rem;  /* 36px */
  --text-code: 0.6875rem; /* 11px - all code blocks */

  --line-height-base: 1.5;

  /* MkDocs Material overrides */
  --md-primary-fg-color: #22c55e;
  --md-primary-fg-color--light: #4ade80;
  --md-primary-fg-color--dark: #15803d;
}

body {
  font-family: "Poppins", sans-serif;
  font-size: var(--text-base);
  line-height: var(--line-height-base);
  color: var(--neutral-800);
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: auto;
  padding: clamp(1rem, 3vw, 3rem);
  padding-top: 0;
}

h1, h2, h3, h4, h5, h6 {
  line-height: 1.2;
  margin-bottom: 0.5em;
}

h1 { font-size: var(--text-2xl); }
h2 { font-size: var(--text-xl); }
h3 { font-size: var(--text-lg); }
h4 { font-size: var(--text-base); }

p { margin-bottom: 1em; }

/* Buttons */
.btn {
  display: inline-block;
  text-decoration: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: var(--text-sm);
  padding: 0.6em 1.3em;
  transition: all 0.2s ease;
}

.btn-primary {
  background: var(--green-500);
  color: #fff;
}

.btn-primary:hover {
  background: var(--green-700);
}

/* ===================== */
/* Hero                  */
/* ===================== */
.hero {
  background: linear-gradient(175deg, #fff 60%, var(--neutral-50) 100%);
  padding: clamp(2rem, 5vw, 5rem) 5%;
  overflow: hidden;
  position: relative;
}

.hero::before {
  content: "";
  position: absolute;
  top: -30%;
  right: -10%;
  width: 70%;
  height: 80%;
  background: radial-gradient(ellipse, rgba(34, 197, 94, 0.15), transparent 70%);
  pointer-events: none;
}

.hero::after {
  content: "";
  position: absolute;
  bottom: -20%;
  left: -10%;
  width: 50%;
  height: 60%;
  background: radial-gradient(ellipse, rgba(34, 197, 94, 0.08), transparent 70%);
  pointer-events: none;
}

.hero-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: clamp(2rem, 4vw, 5rem);
}

.hero-text {
  flex: 0.8;
  min-width: 280px;
}

.hero h1 {
  font-size: clamp(var(--text-2xl), 3vw + 0.5rem, var(--text-4xl));
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 0.6em;
  color: var(--neutral-800);
}

.text-green {
  color: var(--green-500);
}

.hero p {
  font-size: var(--text-sm);
  color: var(--neutral-600);
  max-width: 480px;
  margin-bottom: 1.5em;
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  gap: 0.8em;
  flex-wrap: wrap;
}

/* Code window */
.hero-code {
  flex: 1.4;
  min-width: 300px;
  max-width: 680px;
  position: relative;
  z-index: 0;
}

.code-window {
  background: #1e1e2e;
  border-radius: 12px;
  overflow: hidden;
  box-shadow:
    0 20px 60px rgba(0, 0, 0, 0.15),
    0 4px 16px rgba(0, 0, 0, 0.1);
}

.code-titlebar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 12px 16px;
  background: #181825;
}

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

.code-dot--red { background: #f38ba8; }
.code-dot--yellow { background: #f9e2af; }
.code-dot--green { background: #a6e3a1; }

.code-filename {
  margin-left: 8px;
  font-size: var(--text-xs);
  color: #6c7086;
  font-family: "Roboto Mono", monospace;
}

.code-body {
  padding: 20px;
  margin: 0;
  overflow-x: auto;
  font-family: "Roboto Mono", monospace;
  font-size: var(--text-code);
  line-height: 1.7;
  color: #cdd6f4;
}

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

/* Syntax highlighting */
.kw { color: #cba6f7; }
.mod { color: #89b4fa; }
.cls { color: #a6e3a1; }
.fn  { color: #89dceb; }
.cmt { color: #6c7086; }
.num { color: #fab387; }
.str { color: #f9e2af; }
.str .expr { color: #fab387; }

@media (max-width: 768px) {
  .hero-inner {
    flex-direction: column;
  }

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

  .hero h1 {
    font-size: var(--text-2xl);
  }
}

/* ===================== */
/* Logo Bar              */
/* ===================== */
.logo-bar {
  border-top: 1px solid #e5e7eb;
  border-bottom: 1px solid #e5e7eb;
  padding: clamp(2rem, 4vw, 4rem) 0;
  overflow: hidden;
}

.logo-bar-header {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 5%;
}

.logo-bar-label {
  text-align: center;
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #7a8578;
  margin-bottom: 40px;
}

.logo-bar-mask {
  mask-image: linear-gradient(90deg, transparent, black 15%, black 85%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, black 15%, black 85%, transparent);
}

.logo-scroll {
  display: flex;
  gap: 3rem;
  animation: scroll-logos 45s linear infinite;
  width: max-content;
}

.logo-scroll span {
  flex-shrink: 0;
  font-family: "Poppins", sans-serif;
  font-size: var(--text-xl);
  font-weight: 600;
  color: #a8b5a5;
  white-space: nowrap;
}

@keyframes scroll-logos {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

@media (prefers-reduced-motion: reduce) {
  .logo-scroll {
    animation: none;
  }
}

/* ===================== */
/* Features              */
/* ===================== */
.features {
  padding: clamp(2rem, 5vw, 5rem) 0;
}

.feature {
  display: flex;
  margin-bottom: clamp(2rem, 5vw, 4rem);
  gap: clamp(1.5rem, 3vw, 3rem);
  align-items: center;
}

.feature:nth-child(even) {
  flex-direction: row-reverse;
}

.feature-content {
  flex: 1;
}

.feature-image {
  flex: 0 0 clamp(200px, 45%, 480px);
}

.feature-image img {
  width: 100%;
  height: auto;
  border-radius: 10px;
}

.feature h3 {
  font-weight: 600;
  font-size: var(--text-lg);
  margin-bottom: 0.5em;
  color: var(--neutral-800);
}

.feature p {
  font-size: var(--text-sm);
  color: var(--neutral-600);
  line-height: 1.7;
  margin-bottom: 1em;
}

.feature a {
  font-size: var(--text-sm);
  color: var(--green-500);
  font-weight: 500;
  text-decoration: none;
}

.feature a:hover {
  text-decoration: underline;
}

@media (max-width: 768px) {
  .feature,
  .feature:nth-child(even) {
    flex-direction: column;
  }

  .feature-image {
    flex: 0 0 100%;
  }
}

/* ===================== */
/* Get Started           */
/* ===================== */
.get-started {
  background: #0d0d0d;
  color: #fff;
  padding: clamp(3rem, 6vw, 6rem) 5%;
}

.get-started-inner {
  max-width: 680px;
  margin: 0 auto;
  text-align: center;
}

.get-started h2 {
  font-size: clamp(var(--text-2xl), 2.5vw + 0.5rem, var(--text-3xl));
  font-weight: 700;
  margin-bottom: 0.4em;
}

.get-started-subtitle {
  color: rgba(255, 255, 255, 0.5);
  font-size: var(--text-sm);
  margin-bottom: 2em;
}

.install-command {
  display: inline-block;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 8px;
  padding: 0.7em 1.5em;
  font-family: "Roboto Mono", monospace;
  font-size: var(--text-xs);
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 2em;
}

.install-prompt {
  color: var(--green-500);
  margin-right: 0.5em;
}

.code-window--get-started {
  text-align: left;
  margin-bottom: 2em;
}

.get-started-actions {
  display: flex;
  justify-content: center;
  gap: 0.8em;
  flex-wrap: wrap;
}

/* ===================== */
/* MkDocs Overrides      */
/* ===================== */

/* Header - clean white style */
.md-header {
  background: #fff;
  box-shadow: none;
  border-bottom: 1px solid #e5e7eb;
  color: var(--neutral-800);
}

.md-header__title {
  margin-left: 0 !important;
  color: var(--neutral-800);
  font-weight: 600;
}

.md-header__topic {
  color: var(--neutral-800);
  font-weight: 600;
}

/* Nav tabs - clean text links */
.md-tabs {
  background: #fff;
  border: none;
}

.md-tabs__link {
  color: var(--neutral-600);
  font-size: var(--text-xs);
  font-weight: 500;
  opacity: 1;
}

.md-tabs__link:hover,
.md-tabs__link--active,
.md-tabs__item--active .md-tabs__link {
  color: var(--neutral-800);
}

/* Override Material's white active indicator */
.md-tabs__link--active,
.md-tabs__item--active .md-tabs__link {
  border-bottom-color: var(--green-500);
}

/* Search icon */
.md-search__icon,
.md-header__button {
  color: var(--neutral-600);
}
