:root {
  --bg: #faf9f7;
  --ink: #1a1c22;
  --muted: #7a7d85;
  --accent: #d80c18;
  --accent-dark: #b20a15;
  --line: rgba(26, 28, 34, 0.1);
  --surface: rgba(255, 255, 255, 0.55);
  --surface-solid: rgba(255, 255, 255, 0.88);
  --glow: rgba(216, 12, 24, 0.08);
  --glow-strong: rgba(216, 12, 24, 0.15);
  --radius: 12px;
  --radius-lg: 20px;
  --section-gap: clamp(5rem, 8vw, 8rem);
  --logo-q: #d80c18;
  --logo-chevron: #1a1c22;
  --logo-chevron-hover: #d80c18;
  --logo-needle: #f1171e;
  --logo-needle-dark: #aa0000;
}

/* ═══ Dark mode ═══ */

[data-theme="dark"],
:root:not([data-theme="light"]) {
  @media (prefers-color-scheme: dark) {
    --bg: #0d1117;
    --ink: #e0e4ea;
    --muted: #9ba3af;
    --accent: #22d3ee;
    --accent-dark: #06b6d4;
    --line: rgba(30, 42, 53, 0.8);
    --surface: rgba(21, 27, 35, 0.85);
    --surface-solid: rgba(21, 27, 35, 0.95);
    --glow: rgba(34, 211, 238, 0.1);
    --glow-strong: rgba(34, 211, 238, 0.2);
    --logo-q: #22d3ee;
    --logo-chevron: #e0e4ea;
    --logo-chevron-hover: #22d3ee;
    --logo-needle: #22d3ee;
    --logo-needle-dark: #06b6d4;
  }
}

[data-theme="dark"] {
  --bg: #0d1117;
  --ink: #e0e4ea;
  --muted: #9ba3af;
  --accent: #22d3ee;
  --accent-dark: #06b6d4;
  --line: rgba(30, 42, 53, 0.8);
  --surface: rgba(21, 27, 35, 0.85);
  --surface-solid: rgba(21, 27, 35, 0.95);
  --glow: rgba(34, 211, 238, 0.1);
  --glow-strong: rgba(34, 211, 238, 0.2);
  --logo-q: #22d3ee;
  --logo-chevron: #e0e4ea;
  --logo-chevron-hover: #22d3ee;
  --logo-needle: #22d3ee;
  --logo-needle-dark: #06b6d4;
}

* { box-sizing: border-box; }

[id] {
  scroll-margin-top: 5rem;
}

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Plus Jakarta Sans", "Manrope", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

html {
  overflow-x: hidden;
}

/* Ambient glow spots — static background via pseudo-element to avoid background-attachment: fixed jank */

.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

/* ═══ Grain overlay ═══ */

.grain {
  display: none;
}

/* ═══ Reveal ═══ */

[data-reveal] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

[data-reveal].revealed {
  opacity: 1;
  transform: translateY(0);
}

/* ═══ Page shell ═══ */

.page {
  max-width: min(940px, 92vw);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--section-gap);
  padding: 0 1.5rem 3rem;
  position: relative;
}

/* ═══ Floating Nav ═══ */

.topnav {
  position: fixed;
  top: 1rem;
  left: 50%;
  transform: translateX(-50%);
  width: auto;
  max-width: 90vw;
  z-index: 9999;
  display: flex;
  align-items: center;
  gap: 0.2rem;
  padding: 0.45rem 1.2rem;
  background: rgba(250, 249, 247, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 999px;
  transition: background 300ms ease, box-shadow 300ms ease, border-color 300ms ease;
}

.topnav--scrolled {
  background: rgba(250, 249, 247, 0.92);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
  border-color: var(--line);
}

.topnav__brand {
  font-weight: 700;
  font-size: 0.88rem;
  letter-spacing: 0.04em;
  color: var(--ink);
  text-decoration: none;
  margin-right: 1rem;
}

.topnav__link {
  padding: 0.35rem 0.7rem;
  color: var(--muted);
  text-decoration: none;
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  border-radius: 6px;
  transition: color 180ms ease, background 180ms ease;
}

.topnav__link:hover {
  color: var(--ink);
  background: rgba(0, 0, 0, 0.04);
}

/* ═══ Logo Hero ═══ */

.logo-hero {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 85svh;
  gap: 0.6rem;
  text-align: center;
}

.logo-hero__compass {
  width: min(50vw, 260px);
}

.logo-shell {
  position: relative;
  width: 100%;
  padding: 0 3.5rem;
}

.logo {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: auto;
  border: 0;
  overflow: visible;
  user-select: none;
}

.logo-hit {
  position: absolute;
  top: 18%;
  z-index: 2;
  display: none;
  width: 23%;
  height: 52%;
  padding: 0;
  border: 0;
  background: transparent;
  color: transparent;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.logo-hit--left { left: 0; }
.logo-hit--right { right: 0; }

.needle-hit {
  position: absolute;
  top: 33%;
  left: 33%;
  width: 34%;
  height: 34%;
  border: 0;
  padding: 0;
  background: transparent;
  cursor: pointer;
  z-index: 3;
  -webkit-tap-highlight-color: transparent;
  border-radius: 50%;
}

#needle {
  transform-box: fill-box;
  transform-origin: center;
  transition: transform 220ms ease;
}

#needle.needle--spin {
  animation: needle-spin 640ms ease-out;
  transform-origin: center;
}

@keyframes needle-spin {
  0% { transform: rotate(0deg); }
  70% { transform: rotate(320deg); }
  100% { transform: rotate(360deg); }
}

.needle--wobble-strong {
  animation: needle-wobble-strong 720ms ease-out;
}

@keyframes needle-wobble-strong {
  0% { transform: rotate(0deg); }
  8% { transform: rotate(-1.2deg); }
  18% { transform: rotate(4.6deg); }
  32% { transform: rotate(-3.4deg); }
  46% { transform: rotate(2.2deg); }
  60% { transform: rotate(-1.6deg); }
  74% { transform: rotate(0.9deg); }
  88% { transform: rotate(-0.4deg); }
  100% { transform: rotate(0deg); }
}

.needle--wobble {
  animation: needle-wobble 720ms ease-out;
}

@keyframes needle-wobble {
  0% { transform: rotate(0deg); }
  8% { transform: rotate(-0.7deg); }
  18% { transform: rotate(2.6deg); }
  32% { transform: rotate(-1.9deg); }
  46% { transform: rotate(1.25deg); }
  60% { transform: rotate(-0.8deg); }
  74% { transform: rotate(0.48deg); }
  88% { transform: rotate(-0.22deg); }
  100% { transform: rotate(0deg); }
}

#center-cutout { pointer-events: none; }

.logo-hero__wordmark {
  margin: 0;
  font-size: clamp(2.4rem, 4.5vw, 4rem);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: lowercase;
}

.phrase-wrap {
  margin: 0;
  min-height: 1.8em;
  color: var(--muted);
  font-size: clamp(0.95rem, 1.6vw, 1.15rem);
  letter-spacing: 0.16em;
  text-transform: lowercase;
}

.phrase {
  display: inline-block;
  transition: opacity 220ms ease, transform 220ms ease;
}

.phrase--changing {
  opacity: 0;
  transform: translateY(8px);
}

.logo-hero__tagline {
  margin: 0.8rem 0 0;
  color: var(--muted);
  font-size: 0.85rem;
  line-height: 1.6;
  max-width: 36ch;
}

.logo-hero__cta {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  margin-top: 1.2rem;
}

.hero-install {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: var(--ink);
  color: #f7f8fb;
  border: none;
  border-radius: 8px;
  font-family: "SF Mono", "Fira Code", Menlo, Consolas, monospace;
  font-size: 0.82rem;
  cursor: pointer;
  transition: background 180ms ease, transform 180ms ease;
}

.hero-install:hover {
  background: var(--accent);
  transform: translateY(-1px);
}

.hero-install__icon {
  width: 14px;
  height: 14px;
  opacity: 0.6;
}

.hero-install--copied .hero-install__icon--copy { display: none; }
.hero-install--copied .hero-install__icon--check { display: inline-block; }
.hero-install__icon--check { display: none; color: #4ade80; }

.hero-learn {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.82rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: color 180ms ease;
}

.hero-learn:hover { color: var(--ink); }

.hero-learn__arrow {
  display: inline-block;
  transition: transform 200ms ease;
}

.hero-learn:hover .hero-learn__arrow { transform: translateY(2px); }

/* ═══ Statement ═══ */

.statement {
  text-align: center;
  max-width: 680px;
}

.statement__text {
  margin: 0;
  font-size: clamp(1.25rem, 2.4vw, 1.7rem);
  font-weight: 500;
  line-height: 1.6;
  color: var(--ink);
}

.statement__text em {
  font-style: normal;
  color: var(--accent);
}

/* ═══ Scroll hint ═══ */

.scroll-hint {
  position: fixed;
  bottom: 4.5rem;
  left: 0;
  right: 0;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.1rem;
  color: var(--ink);
  opacity: 0.7;
  animation: scroll-bounce 2s ease-in-out infinite;
  transition: opacity 0.4s ease;
  cursor: default;
}

.scroll-hint__label {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: lowercase;
}

.scroll-hint__arrow {
  color: var(--accent);
  opacity: 1;
}

.scroll-hint--hidden {
  opacity: 0;
  pointer-events: none;
}

@keyframes scroll-bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(6px); }
}

/* ═══ Hero Preview (parallax background) ═══ */

.hero-preview {
  width: 100%;
  height: 85vh;
  min-height: 500px;
  max-height: 1000px;
  overflow: hidden;
  position: relative;
  contain: layout paint;
}

.hero-preview {
  margin-top: 2rem;
}

#hero-preview {
  margin-top: -20vh;
}

.page--continued {
  padding-top: var(--section-gap);
}

.hero-preview__bg {
  position: absolute;
  inset: -10% 0 -10% -5%;
  background-image: url('./assets/screenshots/screenshot_1_dashboard.webp');
  background-size: cover;
  background-position: center 0%;
  background-repeat: no-repeat;
}

[data-theme="dark"] .hero-preview__bg {
  background-image: url('./assets/screenshots/screeshots_dashboard_dm.webp');
}

.hero-preview__bg--detail {
  background-image: url('./assets/screenshots/screenshot_detail.webp');
}

[data-theme="dark"] .hero-preview__bg--detail {
  background-image: url('./assets/screenshots/screeshots_detail_dm.webp');
}

/* Fade edges into page background — only visible when image is shown */
.hero-preview::before,
.hero-preview::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.hero-preview.hero-preview--visible::before,
.hero-preview.hero-preview--visible::after {
  opacity: 1;
}

.hero-preview::before {
  top: 0;
  height: 300px;
  background: linear-gradient(to bottom, var(--bg) 10%, transparent);
}

.hero-preview::after {
  bottom: 0;
  height: 300px;
  background: linear-gradient(to top, var(--bg) 10%, transparent);
}

.hero-preview__bg {
  opacity: 0;
  transition: opacity 0.3s ease;
  will-change: transform, opacity;
}

.hero-preview.hero-preview--visible .hero-preview__bg {
  opacity: 0.88;
  transition: opacity 1.5s ease;
}

#detail-preview.hero-preview--visible .hero-preview__bg {
  transition: opacity 0.8s ease;
}


/* ═══ Story connector ═══ */

.story {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}

.story .glass-card {
  width: 100%;
}

.story__connector {
  display: flex;
  justify-content: center;
  margin: 2rem 0;
}

.story__connector-line {
  width: 1px;
  height: clamp(3rem, 5vw, 5rem);
  background: linear-gradient(to bottom, transparent 10%, var(--accent) 40%, var(--accent) 60%, transparent 90%);
  opacity: 0.25;
}

/* ═══ Glass Card ═══ */

.glass-card {
  width: 100%;
  background: var(--surface-solid);
  border: 1px solid rgba(255, 255, 255, 0.6);
  border-radius: var(--radius-lg);
  padding: 2rem 2.4rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04), inset 0 1px 0 rgba(255, 255, 255, 0.5);
  position: relative;
  overflow: hidden;
}

.glass-card__lead {
  margin: 0 0 0.8rem;
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  font-weight: 700;
  line-height: 1.5;
  color: var(--ink);
}

.glass-card__detail {
  margin: 0;
  font-size: 0.85rem;
  line-height: 1.7;
  color: var(--ink);
  opacity: 0.7;
}

.glass-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: 0.3;
}

.glass-card__kicker {
  margin: 0 0 0.8rem;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}

.glass-card__body {
  margin: 0 0 0.8rem;
  font-size: 0.92rem;
  line-height: 1.75;
  color: var(--ink);
}

.glass-card__body:last-child { margin-bottom: 0; }

.glass-card__body strong {
  font-weight: 600;
}

/* ═══ Section Divider ═══ */

.divider {
  width: 60px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: 0.25;
  border: none;
}

/* ═══ Timeline (How it works) ═══ */

.timeline {
  width: 100%;
}

.timeline__title {
  margin: 0 0 3rem;
  text-align: center;
  font-size: clamp(1.4rem, 2.8vw, 2rem);
  font-weight: 700;
  letter-spacing: 0.02em;
}

.timeline__track {
  position: relative;
  display: flex;
  flex-direction: column;
}

/* Vertical line */
.timeline__track::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 1px;
  background: linear-gradient(to bottom, transparent, var(--line), var(--accent), var(--line), transparent);
  transform: translateX(-50%);
}

.timeline__step {
  display: flex;
  align-items: flex-start;
  gap: 2rem;
  padding: 1.5rem 0;
  position: relative;
}

.timeline__step:nth-child(odd) {
  flex-direction: row-reverse;
  text-align: right;
}

.timeline__num {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--bg);
  border: 2.5px solid var(--accent);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent);
  z-index: 1;
}

.timeline__content {
  width: calc(50% - 2rem);
  padding: 1.2rem 1.6rem;
  background: var(--surface-solid);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: var(--radius);
  transition: box-shadow 300ms ease, transform 300ms ease;
}

.timeline__content:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
  transform: translateY(-2px);
}

.timeline__step:nth-child(odd) .timeline__content {
  margin-right: auto;
  margin-left: calc(50% + 2rem);
}

.timeline__step:nth-child(even) .timeline__content {
  margin-left: auto;
  margin-right: calc(50% + 2rem);
}

.timeline__content strong {
  display: block;
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
  letter-spacing: 0.02em;
  color: var(--accent);
}

.timeline__content p {
  margin: 0;
  font-size: 0.85rem;
  line-height: 1.65;
  color: var(--ink);
}

/* ═══ Principles ═══ */

.principles {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.principle {
  padding: 1.6rem 1.4rem;
  background: var(--surface-solid);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: var(--radius);
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  transition: box-shadow 300ms ease, transform 300ms ease, border-color 300ms ease;
}

.principle:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 32px var(--glow), 0 2px 8px rgba(0, 0, 0, 0.05);
  border-color: rgba(216, 12, 24, 0.15);
}

.principle__icon {
  flex: 0 0 auto;
  opacity: 0.7;
}

.principle__title {
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--accent);
}

.principle__desc {
  margin: 0;
  font-size: 0.85rem;
  line-height: 1.65;
  color: var(--ink);
}

/* ═══ AI Providers ═══ */

.providers {
  width: 100%;
  text-align: center;
}

.providers__label {
  margin: 0 0 1.2rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink);
}

.providers__grid {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.provider {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  padding: 1rem 1.4rem;
  background: var(--surface-solid);
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: var(--radius);
  transition: border-color 200ms ease, transform 200ms ease, box-shadow 200ms ease;
  min-width: 110px;
  text-decoration: none;
  cursor: pointer;
}

.provider:hover {
  border-color: var(--accent);
  transform: translateY(-3px);
  box-shadow: 0 6px 20px var(--glow);
}

.provider__name {
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--ink);
}

.provider__tag {
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.06em;
}

[data-theme="dark"] .provider {
  background: rgba(21, 27, 35, 0.8);
  border-color: rgba(30, 42, 53, 0.8);
}

[data-theme="dark"] .provider:hover {
  border-color: var(--accent);
}

/* ═══ Screenshot Marquee ═══ */

.marquee-section {
  width: 100%;
  overflow: hidden;
  margin-top: var(--section-gap);
}

.marquee {
  position: relative;
  padding: 1rem 0;
}

/* Fade edges */
.marquee::before,
.marquee::after {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  width: clamp(40px, 10vw, 160px);
  z-index: 2;
  pointer-events: none;
}

.marquee::before {
  left: 0;
  background: linear-gradient(to right, var(--bg), transparent);
}

.marquee::after {
  right: 0;
  background: linear-gradient(to left, var(--bg), transparent);
}

.marquee__track {
  display: flex;
  gap: 1.5rem;
  width: max-content;
  will-change: transform;
  cursor: grab;
}

.marquee__track:active {
  cursor: grabbing;
}

.marquee__item {
  flex: 0 0 auto;
  width: min(70vw, 560px);
  margin: 0;
}

.marquee__item img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  transition: transform 300ms ease, box-shadow 300ms ease;
}

.marquee__item:hover img {
  transform: scale(1.02);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.12);
}

[data-theme="dark"] .marquee__item img {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 99999;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: zoom-out;
  opacity: 0;
  transition: opacity 250ms ease;
  pointer-events: none;
}

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

.lightbox__img {
  max-width: 92vw;
  max-height: 92vh;
  border-radius: 8px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
  transform: scale(0.95);
  transition: transform 250ms ease;
}

.lightbox--open .lightbox__img {
  transform: scale(1);
}

.marquee__item img {
  cursor: zoom-in;
}

.marquee__item figcaption {
  padding: 0.5rem 0.2rem 0;
  font-size: 0.78rem;
  color: var(--muted);
  text-align: center;
}

/* ═══ Mid CTA ═══ */

.mid-cta {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.2rem;
}

.mid-cta__buttons {
  display: flex;
  gap: 0.8rem;
  flex-wrap: wrap;
  justify-content: center;
}

.mid-cta__text {
  margin: 0;
  font-size: clamp(1rem, 2vw, 1.3rem);
  font-weight: 600;
  color: var(--ink);
  letter-spacing: 0.01em;
}

/* ═══ Install ═══ */

.install-section {
  width: 100%;
  text-align: center;
}

.install-section__title {
  margin: 0 0 1.5rem;
  font-size: clamp(1.2rem, 2.2vw, 1.6rem);
  font-weight: 700;
}

.install-inner {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
}

.install-label {
  display: block;
  padding-left: 14px;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.install-commands {
  display: flex;
  gap: 12px;
  padding: 12px 14px;
  background: var(--surface-solid);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: var(--radius);
}

.install-cmd {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: rgba(240, 241, 245, 0.85);
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 8px;
  color: var(--ink);
  font-family: "SF Mono", "Fira Code", Menlo, Consolas, monospace;
  font-size: 0.82rem;
  line-height: 1.2;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease, transform 160ms ease;
  -webkit-tap-highlight-color: transparent;
}

.install-cmd:hover {
  background: rgba(232, 233, 238, 0.95);
  border-color: rgba(216, 12, 24, 0.25);
  transform: translateY(-1px);
}

.install-cmd__text { pointer-events: none; }

.install-cmd__icon {
  width: 14px;
  height: 14px;
  flex: 0 0 auto;
  opacity: 0.5;
  transition: opacity 160ms ease;
}

.install-cmd:hover .install-cmd__icon { opacity: 1; }

.install-cmd__icon--check {
  display: none;
  color: #16a34a;
  opacity: 1;
}

.install-cmd--copied .install-cmd__icon--copy { display: none; }
.install-cmd--copied .install-cmd__icon--check { display: block; }

/* ═══ GitHub Section ═══ */

.github-section {
  display: flex;
  justify-content: center;
  gap: 0.8rem;
  flex-wrap: wrap;
}

.github-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  color: #f7f8fb;
  background: linear-gradient(155deg, #0e0f13cc 0%, #11131acc 100%);
  border: 1px solid rgba(27, 29, 36, 0.8);
  border-radius: 10px;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.88rem;
  line-height: 1.1;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.18);
  transition: transform 200ms ease, box-shadow 200ms ease, background 200ms ease;
}

.github-tag:hover {
  transform: translateY(-2px);
  color: #ffffff;
  background: linear-gradient(155deg, var(--accent) 0%, var(--accent-dark) 100%);
  border-color: transparent;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.22);
}

.github-tag--youtube:hover {
  background: linear-gradient(155deg, #ff0000 0%, #cc0000 100%);
}

.github-tag:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
}

.github-tag__icon {
  width: 15px;
  height: 15px;
  flex: 0 0 auto;
}

/* ═══ Menu overlay (hidden on desktop) ═══ */

.menu-overlay {
  display: none;
}

/* ═══ Install option tags ═══ */

.install-option {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
}

.install-option__tag {
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: lowercase;
  color: var(--muted);
}

/* ═══ Final CTA ═══ */

.final-cta {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.8rem;
  padding: 2rem 0;
}

.final-cta__title {
  margin: 0;
  font-size: clamp(1.4rem, 2.8vw, 2rem);
  font-weight: 700;
  letter-spacing: 0.01em;
}

.final-cta__subtitle {
  margin: 0;
  font-size: 0.92rem;
  color: var(--muted);
}

.final-cta__buttons {
  margin-top: 0.4rem;
}

/* ═══ Footer ═══ */

.site-footer {
  text-align: center;
  padding: 1rem 0 0;
}

.site-footer__meta {
  display: block;
  color: var(--muted);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  margin-bottom: 0.6rem;
}

.site-footer__blog {
  display: inline-block;
  color: var(--muted);
  text-decoration: none;
  font-size: 0.68rem;
  letter-spacing: 0.04em;
  opacity: 0.4;
  transition: opacity 180ms ease;
}

.site-footer__blog:hover {
  opacity: 0.7;
}

.site-footer__link {
  color: inherit;
  text-decoration: none;
  transition: opacity 160ms ease;
}

.site-footer__link:hover {
  opacity: 1;
  text-decoration: underline;
}

.site-footer__social {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 0.8rem;
}

.site-footer__social a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.9rem;
  opacity: 0.5;
  transition: opacity 160ms ease;
  display: flex;
  align-items: center;
}

.site-footer__social a:hover {
  opacity: 1;
}

/* ═══ Dark mode overrides ═══ */

[data-theme="dark"] .topnav {
  background: rgba(13, 17, 23, 0.9);
  border-color: rgba(30, 42, 53, 0.6);
}

[data-theme="dark"] .topnav--scrolled {
  background: rgba(13, 17, 23, 0.9);
  border-color: rgba(30, 42, 53, 0.8);
}

[data-theme="dark"] .glass-card {
  background: rgba(21, 27, 35, 0.8);
  border-color: rgba(30, 42, 53, 0.8);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

[data-theme="dark"] .glass-card::before {
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
}

[data-theme="dark"] .timeline__content {
  background: rgba(21, 27, 35, 0.8);
  border-color: rgba(30, 42, 53, 0.8);
}

[data-theme="dark"] .timeline__num {
  background: var(--bg);
}

[data-theme="dark"] .principle {
  background: rgba(21, 27, 35, 0.8);
  border-color: rgba(30, 42, 53, 0.8);
}

[data-theme="dark"] .principle:hover {
  border-color: rgba(34, 211, 238, 0.25);
}

[data-theme="dark"] .github-tag {
  background: linear-gradient(155deg, rgba(21, 27, 35, 0.9) 0%, rgba(13, 17, 23, 0.9) 100%);
  border-color: rgba(30, 42, 53, 0.8);
  color: #e0e4ea;
}

[data-theme="dark"] .github-tag:hover {
  background: linear-gradient(155deg, var(--accent) 0%, var(--accent-dark) 100%);
  color: #0d1117;
  border-color: transparent;
}

[data-theme="dark"] .hero-install {
  background: #e0e4ea;
  color: #0d1117;
}

[data-theme="dark"] .hero-install:hover {
  background: var(--accent);
  color: #0d1117;
}

[data-theme="dark"] .install-commands {
  background: rgba(21, 27, 35, 0.6);
  border-color: rgba(30, 42, 53, 0.8);
}

[data-theme="dark"] .install-cmd {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(30, 42, 53, 0.8);
}

[data-theme="dark"] .install-cmd:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(34, 211, 238, 0.3);
}


[data-theme="dark"] .divider {
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
}

[data-theme="dark"] .topnav__theme-icon--light { display: none; }
[data-theme="dark"] .topnav__theme-icon--dark { display: block; }

/* ═══ Theme toggle + Hamburger ═══ */

.topnav__links {
  display: flex;
  align-items: center;
  gap: 0.2rem;
}

.topnav__theme {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border: none;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  border-radius: 6px;
  transition: color 180ms ease, background 180ms ease;
  margin-left: 0.3rem;
}

.topnav__theme:hover {
  color: var(--ink);
  background: rgba(128, 128, 128, 0.1);
}

.topnav__theme-icon--dark { display: none; }

.topnav__burger {
  display: none;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border: none;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  border-radius: 6px;
  padding: 0;
  margin-left: 0.2rem;
}

.topnav__burger:hover { color: var(--ink); }

/* ═══ Responsive ═══ */

@media (max-width: 900px) {
  .timeline__track::before { left: 20px; }

  .timeline__step,
  .timeline__step:nth-child(odd) {
    flex-direction: row;
    text-align: left;
  }

  .timeline__num {
    left: 20px;
    position: relative;
    transform: none;
    flex: 0 0 auto;
  }

  .timeline__content,
  .timeline__step:nth-child(odd) .timeline__content,
  .timeline__step:nth-child(even) .timeline__content {
    width: auto;
    margin: 0;
    flex: 1;
  }

  .principles {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .grain {
    display: none;
  }

  .page {
    padding: 0 1rem 2rem;
    gap: clamp(3rem, 6vw, 5rem);
  }

  .topnav {
    gap: 0;
    padding: 0.4rem 0.8rem;
  }

  .topnav__brand {
    font-size: 0.8rem;
    padding-right: 0.4rem;
  }

  .topnav__links {
    display: none;
  }

  .topnav__links .topnav__link {
    font-size: 1.1rem;
    font-weight: 600;
    padding: 0.8rem 1.5rem;
    color: var(--ink);
  }

  .topnav__burger {
    display: flex;
  }

  .topnav__theme {
    display: none;
  }

  /* Fullscreen menu overlay */
  .menu-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 9998;
    background: var(--bg);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
  }

  .menu-overlay.open {
    display: flex;
  }

  .menu-overlay .topnav__link {
    font-size: 1.1rem;
    font-weight: 600;
    padding: 0.8rem 1.5rem;
    color: var(--ink);
    text-decoration: none;
    border-radius: 8px;
    transition: background 180ms ease;
  }

  .menu-overlay .topnav__link:hover {
    background: rgba(128, 128, 128, 0.1);
  }

  .menu-overlay__theme {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin-top: 0.5rem;
    padding: 0.8rem 1.5rem;
    border: none;
    border-radius: 8px;
    background: transparent;
    color: var(--ink);
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 180ms ease;
  }

  .menu-overlay__theme:hover {
    background: rgba(128, 128, 128, 0.1);
  }

  .logo-hero {
    padding-top: 6vh;
  }

  .logo-hero__compass {
    width: min(55vw, 200px);
  }

  .logo-hero__cta {
    flex-direction: column;
    gap: 0.8rem;
  }

  .statement__text {
    font-size: clamp(1.1rem, 4vw, 1.3rem);
  }

  .glass-card {
    padding: 1.4rem 1.6rem;
  }

  .timeline__track::before { left: 14px; }
  .timeline__num { width: 24px; height: 24px; font-size: 0.6rem; }
  .timeline__step { gap: 1rem; padding: 1rem 0; }

  .principles {
    grid-template-columns: 1fr;
    gap: 0.8rem;
  }

  .install-commands {
    flex-direction: column;
    gap: 8px;
  }

  .install-cmd {
    font-size: 0.76rem;
    padding: 8px 12px;
  }

  .phrase-wrap {
    max-width: 26ch;
    line-height: 1.45;
  }

  .logo-hit { display: block; }

  .scroll-hint {
    bottom: 4rem;
  }

  .hero-preview {
    height: 40vh;
    min-height: 220px;
    max-height: 400px;
  }

  .hero-preview::before,
  .hero-preview::after {
    height: 60px;
  }

  .marquee__item {
    width: min(85vw, 400px);
  }

  .providers__grid {
    gap: 0.5rem;
  }

  .provider {
    padding: 0.7rem 1rem;
    min-width: 90px;
  }
}


/* ═══ Reduced motion ═══ */

@media (prefers-reduced-motion: reduce) {
  [data-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }

  [data-parallax] {
    will-change: auto;
  }

  .marquee__track {
    animation: none;
  }

  #needle,
  .phrase {
    transition: none;
  }
}
