@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
  --bg-dark: #030303;
  --panel-bg: #09090b;
  --bg-card: #0c0c0e;
  --panel-accent: #18181b;
  --text-primary: #fafafa;
  --text-secondary: #a1a1aa;
  --text-muted: #52525b;
  --accent-indigo: #6366f1;
  --accent-purple: #8b5cf6;
  --accent-cyan: #06b6d4;
  --border-subtle: rgba(255, 255, 255, 0.06);
  --border-hover: rgba(255, 255, 255, 0.12);
  --dot-color: rgba(255, 255, 255, 0.035);
  --hero-glow: radial-gradient(circle, rgba(99, 102, 241, 0.05) 0%, rgba(3, 3, 3, 0) 80%);
  --nav-bg: rgba(3, 3, 3, 0.7);
  --bg-deep: #040406;
  --sidebar-bg: #060608;
  --editor-bg: #050507;
  --logs-bg: #040406;
  --shadow-premium: 0 20px 50px rgba(0, 0, 0, 0.7);
  --font-sans: 'Plus Jakarta Sans', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

[data-theme="light"] {
  --bg-dark: #f8f9fa;
  --panel-bg: #ffffff;
  --bg-card: #ffffff;
  --panel-accent: #f1f3f5;
  --text-primary: #1a1a24;
  --text-secondary: #4a4a5a;
  --text-muted: #868e96;
  --accent-indigo: #4f46e5;
  --accent-purple: #7c3aed;
  --accent-cyan: #0891b2;
  --border-subtle: rgba(0, 0, 0, 0.08);
  --border-hover: rgba(0, 0, 0, 0.15);
  --dot-color: rgba(0, 0, 0, 0.04);
  --hero-glow: radial-gradient(circle, rgba(79, 70, 229, 0.06) 0%, rgba(248, 249, 250, 0) 80%);
  --nav-bg: rgba(255, 255, 255, 0.8);
  --bg-deep: #f1f3f5;
  --sidebar-bg: #f3f3f3;
  --editor-bg: #fafafa;
  --logs-bg: #ececec;
  --shadow-premium: 0 20px 50px rgba(0, 0, 0, 0.06);
}

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

html {
  scroll-behavior: smooth;
  background-color: var(--bg-dark);
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-dark);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Dot matrix background overlay */
body::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image: radial-gradient(circle at 1px 1px, var(--dot-color) 1px, transparent 0);
  background-size: 24px 24px;
  pointer-events: none;
}

/* Elegant ambient glows */
.bg-glow-top {
  position: absolute;
  top: -150px;
  left: 50%;
  transform: translateX(-50%);
  width: 80vw;
  height: 600px;
  background: var(--hero-glow);
  z-index: -1;
  pointer-events: none;
}

/* Navbar styles */
nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 6%;
  background: var(--nav-bg);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-subtle);
  position: sticky;
  top: 0;
  z-index: 100;
}

.logo-container {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo-img {
  width: 26px;
  height: 26px;
  border-radius: 4px;
  filter: grayscale(20%);
}

.logo-text {
  font-weight: 700;
  font-size: 16px;
  letter-spacing: -0.02em;
  font-family: var(--font-sans);
}

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

.nav-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  transition: color 0.2s ease;
}

.nav-links a:hover {
  color: var(--text-primary);
}

.btn-github {
  font-family: var(--font-mono);
  font-size: 11px;
  background: var(--panel-accent);
  border: 1px solid var(--border-subtle);
  padding: 6px 14px;
  border-radius: 4px;
  color: var(--text-primary) !important;
  transition: all 0.2s ease;
}

.btn-github:hover {
  border-color: var(--text-secondary);
  background: #fff;
  color: #000 !important;
}

/* Hero Section */
.hero {
  padding: 120px 6% 80px 6%;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 1100px;
  margin: 0 auto;
}



h1 {
  font-family: var(--font-sans);
  font-size: clamp(34px, 5vw, 56px);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.04em;
  margin-bottom: 24px;
  color: var(--text-primary);
}

.hero-subtitle {
  color: var(--text-secondary);
  font-size: clamp(15px, 1.8vw, 18px);
  font-weight: 400;
  max-width: 720px;
  margin-bottom: 44px;
  line-height: 1.6;
}

.hero-ctas {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  margin-bottom: 74px;
}
.hero-buttons {
  display: flex;
  gap: 14px;
}
.hero-docker-command {
  background: var(--panel-bg, #111);
  border: 1px solid var(--border-subtle);
  padding: 12px 18px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-mono);
  font-size: 13px;
  max-width: 100%;
  overflow-x: auto;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}
@media (max-width: 480px) {
  .hero-buttons {
    flex-direction: column;
    width: 100%;
    gap: 10px;
  }
  .hero-buttons .btn-primary,
  .hero-buttons .btn-secondary {
    width: 100%;
    text-align: center;
  }
  .hero-docker-command {
    font-size: 11px;
    padding: 10px 14px;
    gap: 8px;
    width: 100%;
  }
}

.btn-primary {
  background: var(--text-primary);
  color: var(--bg-dark);
  border: none;
  padding: 12px 24px;
  font-size: 14px;
  font-weight: 600;
  border-radius: 5px;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-primary:hover {
  background: #fff;
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.15);
  transform: translateY(-1px);
}

.btn-secondary {
  background: transparent;
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  padding: 12px 24px;
  font-size: 14px;
  font-weight: 600;
  border-radius: 5px;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-secondary:hover {
  color: var(--text-primary);
  border-color: var(--text-secondary);
  background: rgba(255, 255, 255, 0.02);
}

/* High-Fidelity Obsidian Editor Mockup */
.mockup-container {
  width: 100%;
  max-width: 1040px;
  min-width: 300px;
  background: var(--panel-bg);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow-premium);
  display: flex;
  flex-direction: column;
  margin-bottom: 120px;
  resize: horizontal;
  container-type: inline-size;
  container-name: mockup;
}

.mockup-header {
  background: var(--panel-bg);
  padding: 0 16px;
  height: 40px;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.window-controls {
  display: flex;
  gap: 6px;
}

.win-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--border-subtle);
}
.win-dot.red { background: #ff5f56; }
.win-dot.yellow { background: #ffbd2e; }
.win-dot.green { background: #27c93f; }

/* Obsidian Multi-Tab UI */
.mockup-tabs {
  display: flex;
  height: 100%;
  align-items: flex-end;
  gap: 4px;
}

.mockup-tab {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 16px;
  height: 32px;
  background: var(--sidebar-bg);
  border: 1px solid var(--border-subtle);
  border-bottom: none;
  border-radius: 6px 6px 0 0;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s ease;
}

.mockup-tab.active {
  background: var(--editor-bg);
  color: var(--text-primary);
  border-color: var(--border-subtle);
  z-index: 2;
}

.mockup-tab svg {
  width: 12px;
  height: 12px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
}

.active-pulse {
  width: 6px;
  height: 6px;
  background-color: var(--accent-indigo);
  border-radius: 50%;
  animation: pulse-sync 2s infinite;
}

.mockup-layout {
  display: flex;
  min-height: 460px;
  background: var(--editor-bg);
  position: relative;
  transition: background-color 0.5s ease;
}

/* Sidebar Folder Tree */
.mockup-sidebar {
  width: 22%;
  border-right: 1px solid var(--border-subtle);
  background: var(--sidebar-bg);
  padding: 18px 14px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: background-color 0.5s ease;
}

.sidebar-title {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
}

.file-tree {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.file-item {
  font-size: 12px;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  padding: 4px 6px;
  border-radius: 3px;
  transition: all 0.15s ease;
}

.file-item:hover {
  background: var(--panel-accent);
  color: var(--text-primary);
}

.file-item.active {
  background: rgba(99, 102, 241, 0.08);
  color: var(--text-primary);
  border-left: 2px solid var(--accent-indigo);
  border-radius: 0 3px 3px 0;
}

.file-item.flash-glow {
  animation: sidebar-glow 1.5s ease infinite alternate;
}

.file-item svg {
  width: 13px;
  height: 13px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
}

/* Editor Main Section */
.mockup-editor {
  flex: 1;
  padding: 24px 20px;
  position: relative;
  overflow-y: auto;
  text-align: left;
  outline: none;
  line-height: 1.7;
}

.editor-content {
  font-family: var(--font-mono);
  font-size: clamp(11px, 1.45cqi, 14.5px);
  color: var(--text-primary);
  white-space: pre-wrap;
  word-break: break-word;
  overflow-x: hidden;
  transition: color 0.5s ease;
}

.editor-line {
  min-height: 26px;
}

/* Highlight tags for Markdown syntax highlighting */
.md-h1 { color: #fdfdfd; font-size: 18px; font-weight: 700; display: block; margin-bottom: 8px; border-bottom: 1px solid var(--border-subtle); padding-bottom: 4px; font-family: var(--font-sans); }
.md-bullet { color: var(--accent-indigo); font-weight: bold; }
.md-checked { color: var(--text-muted); text-decoration: line-through; }
.md-block { color: var(--text-secondary); background: var(--panel-accent); padding: 4px 8px; border-radius: 4px; display: block; border-left: 2px solid var(--text-muted); margin: 8px 0; }
.md-tag { color: var(--accent-cyan); background: rgba(6, 182, 212, 0.1); padding: 1px 5px; border-radius: 3px; font-size: 11px; }

/* Real-Time Collaborator Cursors */
.sync-cursor {
  position: absolute;
  pointer-events: none;
  display: inline-flex;
  flex-direction: column;
  z-index: 10;
  /* Switched to transform for hardware-accelerated, buttery smooth gliding */
  transition: opacity 0.4s ease, transform 0.08s linear;
}

.cursor-flag {
  position: relative;
  display: flex;
  align-items: center;
}

.cursor-caret {
  width: 1.5px; /* Sleeker, sharper line for realism */
  height: 18px;
  border-radius: 1px;
  animation: blink-caret 1s step-end infinite;
}

.cursor-caret.is-typing,
.is-typing {
  animation: none !important;
  opacity: 1 !important;
}

.cursor-tag {
  position: absolute;
  left: 2px;
  top: -16px;
  color: #000000;
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 10px;
  padding: 1px 5px;
  border-radius: 2px;
  white-space: nowrap;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
}

/* Selection overlay highlight span */
.select-span {
  background-color: rgba(99, 102, 241, 0.2);
  border-radius: 2px;
  transition: background-color 0.2s ease;
}
.select-span.cyan {
  background-color: rgba(6, 182, 212, 0.2);
}

/* dynamic notification banners inside the editor */
.sync-banner {
  position: absolute;
  top: 12px;
  left: 50%;
  transform: translateX(-50%) translateY(-40px);
  background: var(--panel-accent);
  border: 1px solid var(--accent-indigo);
  padding: 6px 14px;
  border-radius: 4px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
  z-index: 20;
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.6);
}

.sync-banner.active {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

.sync-banner .banner-pulse {
  width: 6px;
  height: 6px;
  background-color: var(--accent-cyan);
  border-radius: 50%;
  animation: pulse-sync 1.5s infinite;
}

/* Dynamic Themes for the Mockup Editor (Obsidian Redirection) */
.nord-theme .mockup-layout {
  background: #2e3440;
}
.nord-theme .mockup-sidebar {
  background: #242933;
  border-color: #3b4252;
}
.nord-theme .mockup-editor {
  border-color: #3b4252;
}
.nord-theme .mockup-logs {
  background: #20242c;
  border-color: #3b4252;
}
.nord-theme .editor-content {
  color: #d8dee9;
}
.nord-theme .md-h1 {
  color: #88c0d0;
  border-color: #3b4252;
}
.nord-theme .md-bullet {
  color: #ebcb8b;
}

/* Logging Telemetry Pane */
.mockup-logs {
  width: 25%;
  border-left: 1px solid var(--border-subtle);
  background: var(--logs-bg);
  padding: 18px 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: background-color 0.5s ease;
}

.logs-content {
  font-family: var(--font-mono);
  font-size: clamp(8px, 1.1cqi, 10.5px);
  color: var(--text-muted);
  display: flex;
  flex-direction: column;
  gap: 6px;
  overflow-y: hidden;
  height: 100%;
}

.log-line {
  white-space: pre-wrap;
  word-break: break-word;
  padding-left: 17ch;
  text-indent: -17ch;
}
.log-line span {
  color: var(--text-secondary);
}
.log-line.sync {
  color: var(--accent-indigo);
}
.log-line.anna {
  color: #c084fc;
}
.log-line.panos {
  color: #22d3ee;
}

/* Features Grid */
.features-section {
  padding: 100px 6%;
  max-width: 1100px;
  margin: 0 auto;
  border-top: 1px solid var(--border-subtle);
}

.section-title {
  text-align: center;
  font-family: var(--font-sans);
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 12px;
  letter-spacing: -0.03em;
}

.section-subtitle {
  text-align: center;
  color: var(--text-secondary);
  font-size: 15px;
  max-width: 600px;
  margin: 0 auto 54px auto;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 20px;
}

@media (min-width: 600px) {
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .features-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.feature-card {
  background: var(--panel-bg);
  border: 1px solid var(--border-subtle);
  padding: 30px 24px;
  border-radius: 6px;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  text-align: left;
}

.feature-card:hover {
  border-color: var(--border-hover);
  background: var(--panel-accent);
  transform: translateY(-2px);
}

.card-num {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-muted);
  display: block;
  margin-bottom: 20px;
}

.feature-card h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 12px;
  color: var(--text-primary);
}

.feature-card p {
  color: var(--text-secondary);
  font-size: 15px;
  line-height: 1.6;
}

/* Flowchart Section */
.architecture-section {
  padding: 100px 6%;
  background: var(--bg-deep);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  width: 100%;
}

.flowchart-container {
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
}

.flow-diagram {
  margin-top: 60px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  padding: 20px;
  flex-wrap: wrap;
  gap: 30px;
}

.flow-node {
  background: var(--panel-bg);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  padding: 20px;
  width: 240px;
  text-align: left;
  z-index: 2;
  transition: border-color 0.2s ease;
}

.flow-node:hover {
  border-color: var(--text-muted);
}

.flow-node h4 {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.flow-node p {
  color: var(--text-secondary);
  font-size: 11px;
  line-height: 1.5;
}

.node-meta {
  font-family: var(--font-mono);
  font-size: 9px;
  color: var(--text-muted);
  display: block;
  margin-top: 10px;
}

.flow-connector {
  flex: 1;
  height: 2px;
  background: var(--border-subtle);
  position: relative;
  min-width: 60px;
}

/* Pulse pipeline line animation */
.flow-svg {
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  height: 20px;
  transform: translateY(-50%);
  pointer-events: none;
  z-index: 1;
}

.flow-path {
  fill: none;
  stroke: var(--accent-indigo);
  stroke-width: 1.5;
  stroke-dasharray: 6 30;
  animation: pulse-flow 3s linear infinite;
}
.flow-path.reversed {
  stroke: var(--accent-cyan);
  animation: pulse-flow-rev 3s linear infinite;
}

/* Footer Section */
footer {
  padding: 100px 6% 40px 6%;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: var(--bg-dark);
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
}

.footer-logo span {
  font-weight: 700;
  font-size: 18px;
}

.footer-desc {
  color: var(--text-secondary);
  font-size: 13px;
  max-width: 440px;
  margin-bottom: 34px;
}

.copyright {
  color: var(--text-muted);
  font-size: 11px;
  font-family: var(--font-mono);
  margin-top: 60px;
  border-top: 1px solid var(--border-subtle);
  padding-top: 24px;
  width: 100%;
}

/* How It Works Section */
.how-it-works-section {
  padding: 100px 6%;
  background: var(--bg-dark);
  max-width: 1100px;
  margin: 0 auto;
}

.hiw-header {
  text-align: center;
  margin-bottom: 60px;
}

.hiw-grid {
  display: flex;
  gap: 40px;
  align-items: flex-start;
}

.hiw-tabs {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.hiw-tab {
  padding: 24px;
  border-radius: 12px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  background: transparent;
}

.hiw-tab h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text-primary);
}

.hiw-tab p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.5;
}

.hiw-tab:hover {
  background: rgba(255, 255, 255, 0.03);
  border-color: rgba(255, 255, 255, 0.1);
  transform: translateX(4px);
}

.hiw-tab.active {
  background: var(--bg-card);
  border-color: var(--border-subtle);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
  transform: translateX(0);
}

.hiw-visualization-container {
  flex: 1.2;
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  overflow: hidden;
  min-height: 400px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 30px rgba(0,0,0,0.4);
}

.hiw-vis-panel {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px;
}

.hiw-vis-panel.active {
  opacity: 1;
  pointer-events: auto;
}

.vis-caption {
  position: absolute;
  bottom: 24px;
  font-size: 13px;
  color: var(--text-muted);
  text-align: center;
  max-width: 80%;
}

.crdt-video {
  width: 100%;
  max-height: 100%;
  border-radius: 8px;
  border: 1px solid var(--border-subtle);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}

/* Keyframes animations */
@keyframes sidebar-glow {
  from { background-color: rgba(99, 102, 241, 0.03); }
  to { background-color: rgba(99, 102, 241, 0.18); box-shadow: 0 0 10px rgba(99, 102, 241, 0.1); }
}

@keyframes pulse-sync {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 1; }
}

@keyframes pulse-flow {
  0% { stroke-dashoffset: 0; }
  100% { stroke-dashoffset: -36px; }
}

@keyframes pulse-flow-rev {
  0% { stroke-dashoffset: 0; }
  100% { stroke-dashoffset: 36px; }
}

@keyframes blink-caret {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

/* Responsive Overrides */
@media (max-width: 768px) {
  nav {
    padding: 16px 20px;
  }
  .nav-links {
    display: none;
  }
  .hero {
    padding: 80px 20px 60px 20px;
  }
  
  .features-section {
    padding: 60px 20px;
  }
  .section-title {
    font-size: 28px;
  }
  .section-subtitle {
    font-size: 14px;
    margin-bottom: 40px;
  }
  .features-grid {
    gap: 16px;
  }
  .feature-card {
    padding: 24px 20px;
  }
  .feature-card h3 {
    font-size: 18px;
  }
  .feature-card p {
    font-size: 14px;
  }
  .flow-diagram {
    flex-direction: column;
    align-items: center;
    gap: 0;
  }
  .flow-connector {
    width: 2px;
    height: 40px;
    min-width: auto;
  }
  .flow-svg {
    display: none;
  }
  .flow-node {
    margin-bottom: 40px;
    position: relative;
  }
  .flow-node:not(:last-child)::after {
    content: '';
    position: absolute;
    bottom: -40px;
    left: 50%;
    transform: translateX(-50%);
    width: 2px;
    height: 40px;
    background: var(--accent-indigo);
    opacity: 0.5;
  }
}

/* Dynamic Container Queries for the Resizable Mockup */
@container mockup (max-width: 820px) {
  .mockup-sidebar, .mockup-logs {
    display: none;
  }
  .mockup-editor {
    padding: 16px 12px;
  }
  .editor-content {
    font-size: clamp(8.5px, 2.5cqi, 12px);
  }
}

/* ==========================================================================
   UPDATED: Large Hero Section Animation (Layout Shift Fixed)
   ========================================================================== */
.hero-animation {
  font-family: var(--font-sans);
  font-size: clamp(40px, 6vw, 68px); /* Massive, high-impact hero scale */
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.04em;
  margin-bottom: 28px;
  color: var(--text-primary);
  
  /* LOCK LAYOUT: Prevents the text underneath from moving when strings are deleted */
  min-height: 95px; 
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
}

.typing-container {
  display: inline-block;
  position: relative;
  word-break: break-word;
  max-width: 90vw;
  text-align: center;
}

.hero-animation .cursor {
  display: inline-block;
  position: relative;
  width: 4px;
  height: 1.05em;
  margin-left: 4px;
  vertical-align: middle;
}

.hero-animation .cursor::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background-color: var(--accent-cyan);
  border-radius: 2px;
  animation: blink-hero 1s step-end infinite;
}

.hero-animation .cursor.is-typing::before {
  animation: none !important;
  opacity: 1 !important;
}

.hero-animation .cursor-blue::before {
  background-color: var(--accent-indigo, #6366f1);
}

.hero-animation .cursor::after {
  content: 'Alex';
  position: absolute;
  top: -18px;
  left: 6px;
  background-color: var(--accent-cyan);
  color: #000;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 800;
  padding: 3px 6px;
  border-radius: 3px;
  letter-spacing: 0.05em;
  line-height: 1;
  white-space: nowrap;
  box-shadow: 0 4px 10px rgba(0,0,0,0.5);
  pointer-events: none;
  text-transform: uppercase;
}

.hero-animation .cursor-blue::after {
  content: 'Sarah';
  background-color: var(--accent-indigo, #6366f1);
  color: #fff;
}

@keyframes blink-hero {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

/* ==========================================================================
   Interactive "How it Works" Mobile Responsiveness Overrides
   ========================================================================== */
@media (max-width: 900px) {
  .hiw-grid {
    flex-direction: column;
    gap: 24px;
  }
  
  .hiw-tabs {
    flex-direction: row; /* Horizontal tabs layout */
    overflow-x: auto; /* Allows smooth horizontal swipe-scrolling */
    width: 100%;
    padding-bottom: 8px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none; /* Hides default scrollbars on Firefox */
  }
  
  .hiw-tabs::-webkit-scrollbar {
    display: none; /* Hides default scrollbars on Chrome/Safari */
  }

  .hiw-tab {
    flex: 0 0 auto; /* Prevents tab items from shrinking */
    padding: 12px 18px;
    min-width: 180px;
    text-align: center;
  }
  
  .hiw-tab h3 {
    font-size: 15px;
    margin-bottom: 4px;
  }
  
  .hiw-tab p {
    font-size: 11px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  .hiw-visualization-container {
    width: 100%;
    min-height: 280px;
  }
}

/* Remove the permanent global padding from the text base */
#text-main {
  transition: background-color 0.1s;
}

/* Move the padding and border-radius directly into the active highlights */
.highlight-blue {
  background-color: rgba(99, 102, 241, 0.4);
  padding: 0 6px;
  border-radius: 4px;
}

.highlight-white {
  background-color: rgba(255, 255, 255, 0.2);
  padding: 0 6px;
  border-radius: 4px;
}

.hidden {
  opacity: 0 !important;
  width: 0 !important;
  margin: 0 !important;
  overflow: hidden;
  transition: opacity 0.2s ease, width 0.2s ease, margin 0.2s ease;
}

/* ==========================================================================
   NEW: Responsive Mobile Menu Toggles and Drawer
   ========================================================================== */
.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 22px;
  height: 16px;
  background: transparent;
  border: none;
  cursor: pointer;
  z-index: 200;
}

.menu-toggle span {
  width: 100%;
  height: 2px;
  background-color: var(--text-primary);
  border-radius: 2px;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.menu-toggle.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.menu-toggle.open span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.mobile-nav-drawer {
  position: fixed;
  top: 0;
  right: -100%;
  width: 280px;
  height: 100vh;
  background-color: rgba(9, 9, 11, 0.98);
  backdrop-filter: blur(20px);
  border-left: 1px solid var(--border-subtle);
  z-index: 150;
  display: flex;
  flex-direction: column;
  padding: 100px 30px;
  gap: 20px;
  transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.8);
}

.mobile-nav-drawer.open {
  right: 0;
}

.mobile-nav-drawer a {
  font-family: var(--font-sans);
  font-size: 16px;
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s ease;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.02);
}

.mobile-nav-drawer a:hover,
.mobile-nav-drawer a.active {
  color: var(--text-primary);
  border-bottom-color: var(--accent-indigo);
}

.mobile-nav-drawer .btn-github-mobile {
  margin-top: 20px;
  text-align: center;
  font-family: var(--font-mono);
  font-size: 12px;
  background: var(--panel-accent);
  border: 1px solid var(--border-subtle);
  padding: 10px;
  border-radius: 4px;
  color: var(--text-primary);
  text-decoration: none;
  transition: all 0.2s ease;
}

.mobile-nav-drawer .btn-github-mobile:hover {
  background: #fff;
  color: #000;
}

/* Enable toggle for mobile screens */
@media (max-width: 768px) {
  .menu-toggle {
    display: flex;
  }
}

/* ==========================================================================
   NEW: Developer Documentation Hub (docs.html) Styles
   ========================================================================== */
.docs-layout {
  display: flex;
  gap: 40px;
  max-width: 1240px;
  margin: 0 auto;
  padding: 40px 6%;
  align-items: flex-start;
}

.docs-sidebar {
  width: 280px;
  position: sticky;
  top: 90px;
  height: calc(100vh - 120px);
  overflow-y: auto;
  padding-right: 15px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* Custom scrollbars for docs sidebar */
.docs-sidebar::-webkit-scrollbar {
  width: 4px;
}
.docs-sidebar::-webkit-scrollbar-thumb {
  background: var(--border-subtle);
  border-radius: 4px;
}
.docs-sidebar::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}

.docs-search-wrapper {
  position: relative;
  width: 100%;
}

.docs-search-input {
  width: 100%;
  background: var(--panel-accent);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 13px;
  padding: 10px 14px 10px 32px;
  border-radius: 6px;
  outline: none;
  transition: all 0.2s ease;
}

.docs-search-input:focus {
  border-color: var(--accent-indigo);
  background: rgba(255, 255, 255, 0.04);
  box-shadow: 0 0 10px rgba(99, 102, 241, 0.1);
}

.docs-search-wrapper svg {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 14px;
  height: 14px;
  stroke: var(--text-muted);
  fill: none;
  stroke-width: 2;
  pointer-events: none;
}

.docs-nav-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.docs-nav-title {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--accent-indigo);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
  margin-bottom: 4px;
}

.docs-nav-link {
  font-size: 13px;
  color: var(--text-secondary);
  text-decoration: none;
  padding: 4px 0 4px 10px;
  border-left: 1px solid var(--border-subtle);
  transition: all 0.2s ease;
  display: block;
}

.docs-nav-link:hover {
  color: var(--text-primary);
  border-left-color: var(--text-muted);
}

.docs-nav-link.active {
  color: var(--text-primary);
  border-left-color: var(--accent-indigo);
  font-weight: 500;
}

.docs-content {
  flex: 1;
  max-width: 820px;
  min-width: 0;
  text-align: left;
}

.docs-section {
  padding-bottom: 50px;
  margin-bottom: 50px;
  border-bottom: 1px solid var(--border-subtle);
}

.docs-section:last-child {
  border-bottom: none;
}

.docs-section h1 {
  text-align: left;
  font-size: 32px;
  margin-bottom: 16px;
  letter-spacing: -0.03em;
}

.docs-section h2 {
  font-size: 20px;
  margin: 32px 0 16px 0;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.docs-section p {
  color: var(--text-secondary);
  font-size: 15px;
  line-height: 1.7;
  margin-bottom: 20px;
}

.docs-section ul, .docs-section ol {
  color: var(--text-secondary);
  font-size: 15px;
  margin-bottom: 20px;
  padding-left: 20px;
}

.docs-section li {
  margin-bottom: 8px;
}

/* Premium alert banners */
.docs-alert {
  background: rgba(99, 102, 241, 0.04);
  border-left: 3px solid var(--accent-indigo);
  border-radius: 0 8px 8px 0;
  padding: 16px 20px;
  margin: 24px 0;
}

.docs-alert h4 {
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.docs-alert p {
  margin-bottom: 0;
  font-size: 13.5px;
  line-height: 1.6;
}

.docs-alert.tip {
  background: rgba(6, 182, 212, 0.04);
  border-left-color: var(--accent-cyan);
}

/* Beautiful Fenced Code blocks with Clipboard buttons */
.docs-code-container {
  position: relative;
  margin: 20px 0;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: #09090b;
  overflow: hidden;
}

.docs-code-header {
  height: 32px;
  background: rgba(255, 255, 255, 0.01);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  padding: 0 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.docs-code-lang {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.docs-code-copy-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-family: var(--font-sans);
  font-size: 11px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: color 0.2s ease;
  padding: 2px 6px;
}

.docs-code-copy-btn:hover {
  color: var(--text-primary);
}

.docs-code-container pre {
  margin: 0;
  padding: 16px 20px;
  overflow-x: auto;
}

.docs-code-container code {
  font-family: var(--font-mono);
  font-size: 13px;
  color: #e4e4e7;
  line-height: 1.5;
  white-space: pre;
}

@media (max-width: 900px) {
  .docs-layout {
    flex-direction: column;
    padding: 20px 20px;
    gap: 16px;
  }
  .docs-sidebar {
    width: 100%;
    height: auto;
    position: static;
    border-bottom: 1px solid var(--border-subtle);
    padding-bottom: 20px;
    padding-right: 0;
    display: none;
  }
  .docs-sidebar.open {
    display: flex;
  }
  .docs-section {
    padding-bottom: 32px;
    margin-bottom: 32px;
  }
  .docs-section h2 {
    margin: 24px 0 12px 0;
  }
  footer {
    padding: 60px 20px 30px 20px;
  }
  .copyright {
    margin-top: 30px;
  }
}

/* ==========================================================================
   DOCS MOBILE SIDEBAR TOGGLE BUTTON
   ========================================================================== */
.docs-sidebar-toggle {
  display: none;
  align-items: center;
  gap: 8px;
  background: var(--panel-bg);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 500;
  padding: 10px 16px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
  margin-bottom: 8px;
}

.docs-sidebar-toggle:hover {
  border-color: var(--border-hover);
  color: var(--text-primary);
}

.docs-sidebar-toggle.open {
  border-color: var(--accent-indigo);
  color: var(--text-primary);
}

@media (max-width: 900px) {
  .docs-sidebar-toggle {
    display: flex;
  }
}

/* ==========================================================================
   DOCS READING PROGRESS BAR
   ========================================================================== */
.docs-sidebar-footer {
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid var(--border-subtle);
}

.docs-reading-progress {
  width: 100%;
  height: 2px;
  background: var(--border-subtle);
  border-radius: 2px;
  margin-bottom: 6px;
  overflow: hidden;
}

.docs-progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--accent-indigo), var(--accent-cyan));
  border-radius: 2px;
  transition: width 0.2s ease;
}

.docs-progress-label {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-muted);
}

@media (max-width: 900px) {
  .docs-sidebar-footer {
    display: none;
  }
}

/* ==========================================================================
   DOCS SECTION BADGE
   ========================================================================== */
.docs-section-badge {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent-indigo);
  background: rgba(99, 102, 241, 0.08);
  border: 1px solid rgba(99, 102, 241, 0.2);
  padding: 3px 10px;
  border-radius: 20px;
  margin-bottom: 12px;
}

/* ==========================================================================
   DOCS FEATURE CARDS GRID
   ========================================================================== */
.docs-feature-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin: 20px 0 28px 0;
}

@media (max-width: 640px) {
  .docs-feature-grid {
    grid-template-columns: 1fr;
  }
}

.docs-feature-card {
  background: rgba(255,255,255,0.015);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: all 0.2s ease;
}

.docs-feature-card:hover {
  border-color: var(--border-hover);
  background: rgba(255,255,255,0.03);
}

.docs-feature-icon {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: rgba(99, 102, 241, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-indigo);
  margin-bottom: 4px;
}

.docs-feature-card strong {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.docs-feature-card p {
  font-size: 13px !important;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 0 !important;
}

/* ==========================================================================
   DOCS TABLE
   ========================================================================== */
.docs-table-wrapper {
  overflow-x: auto;
  margin: 20px 0;
  border-radius: 6px;
  border: 1px solid var(--border-subtle);
}

.docs-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
}

.docs-table thead {
  background: rgba(255,255,255,0.02);
  border-bottom: 1px solid var(--border-subtle);
}

.docs-table th {
  padding: 10px 16px;
  text-align: left;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  white-space: nowrap;
}

.docs-table td {
  padding: 10px 16px;
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  vertical-align: top;
}

.docs-table tr:last-child td {
  border-bottom: none;
}

.docs-table tr:hover td {
  background: rgba(255,255,255,0.015);
}

.docs-table code {
  font-family: var(--font-mono);
  font-size: 12px;
  background: rgba(255,255,255,0.06);
  padding: 2px 6px;
  border-radius: 3px;
  color: var(--accent-cyan);
}

/* Colored status badges in tables */
.docs-badge {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 3px;
  white-space: nowrap;
  background: rgba(99, 102, 241, 0.12);
  color: var(--accent-indigo);
  border: 1px solid rgba(99, 102, 241, 0.2);
}

.docs-badge.cyan {
  background: rgba(6, 182, 212, 0.12);
  color: var(--accent-cyan);
  border-color: rgba(6, 182, 212, 0.2);
}

.docs-badge.green {
  background: rgba(34, 197, 94, 0.12);
  color: #22c55e;
  border-color: rgba(34, 197, 94, 0.2);
}

.docs-badge.muted {
  background: rgba(255,255,255,0.04);
  color: var(--text-muted);
  border-color: var(--border-subtle);
}

.docs-badge.indigo {
  background: rgba(99, 102, 241, 0.12);
  color: var(--accent-indigo);
  border-color: rgba(99, 102, 241, 0.2);
}

/* ==========================================================================
   DOCS TOPOLOGY CARDS (Quickstart section)
   ========================================================================== */
.docs-topology-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin: 24px 0;
}

@media (max-width: 720px) {
  .docs-topology-cards {
    grid-template-columns: 1fr;
  }
}

.docs-topology-card {
  background: var(--panel-bg);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: border-color 0.2s ease;
}

.docs-topology-card:hover {
  border-color: var(--border-hover);
}

.docs-topology-num {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--accent-indigo);
  font-weight: 700;
  margin-bottom: 4px;
}

.docs-topology-card strong {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.docs-topology-card p {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 8px !important;
}

.docs-topology-url {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--accent-cyan);
  background: rgba(6, 182, 212, 0.06);
  padding: 4px 8px;
  border-radius: 4px;
  border: 1px solid rgba(6, 182, 212, 0.15);
  display: block;
  word-break: break-all;
}

/* ==========================================================================
   DOCS CODE TABS (Tailscale section)
   ========================================================================== */
.docs-code-tabs {
  margin: 20px 0;
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  overflow: hidden;
}

.docs-code-tab-bar {
  display: flex;
  background: rgba(255,255,255,0.01);
  border-bottom: 1px solid var(--border-subtle);
  overflow-x: auto;
  scrollbar-width: none;
}

.docs-code-tab-bar::-webkit-scrollbar {
  display: none;
}

.docs-code-tab-btn {
  flex: 0 0 auto;
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  padding: 10px 18px;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.docs-code-tab-btn:hover {
  color: var(--text-secondary);
}

.docs-code-tab-btn.active {
  color: var(--accent-cyan);
  border-bottom-color: var(--accent-cyan);
}

.docs-code-tab-content {
  display: none;
}

.docs-code-tab-content.active {
  display: block;
}

/* ==========================================================================
   DOCS TOPOLOGY DIAGRAM (Tailscale section)
   ========================================================================== */
.docs-topology-diagram {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  margin: 28px 0;
  padding: 28px;
  background: rgba(99, 102, 241, 0.03);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
}

.docs-topo-node {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 16px 20px;
  background: var(--panel-bg);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  text-align: center;
  min-width: 140px;
  transition: border-color 0.2s ease;
}

.docs-topo-node.host {
  border-color: rgba(99, 102, 241, 0.4);
  background: rgba(99, 102, 241, 0.06);
}

.docs-topo-node.peer {
  border-color: rgba(6, 182, 212, 0.25);
}

.docs-topo-icon {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  background: rgba(99, 102, 241, 0.12);
  color: var(--accent-indigo);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 4px;
}

.docs-topo-icon.cyan {
  background: rgba(6, 182, 212, 0.12);
  color: var(--accent-cyan);
}

.docs-topo-node strong {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
}

.docs-topo-node span {
  font-size: 11px;
  color: var(--text-muted);
}

.docs-topo-node code {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--accent-cyan);
  background: rgba(6, 182, 212, 0.08);
  padding: 2px 6px;
  border-radius: 3px;
  margin-top: 2px;
}

.docs-topo-lines {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 8px 0;
}

.docs-topo-line {
  width: 2px;
  height: 30px;
  background: linear-gradient(to bottom, var(--accent-indigo), var(--accent-cyan));
  border-radius: 2px;
  opacity: 0.5;
}

.docs-topo-label {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-muted);
  white-space: nowrap;
}

.docs-topo-peers {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}

/* ==========================================================================
   DOCS FAQ ACCORDION
   ========================================================================== */
.docs-faq-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}

.docs-faq-item {
  background: var(--panel-bg);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  overflow: hidden;
  transition: border-color 0.2s ease;
}

.docs-faq-item[open] {
  border-color: var(--border-hover);
}

.docs-faq-question {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px 20px;
  cursor: pointer;
  font-size: 15px;
  font-weight: 500;
  color: var(--text-primary);
  list-style: none;
  user-select: none;
  transition: color 0.2s ease;
}

.docs-faq-question::-webkit-details-marker {
  display: none;
}

.docs-faq-question svg {
  flex-shrink: 0;
  color: var(--accent-indigo);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.docs-faq-item[open] .docs-faq-question svg {
  transform: rotate(90deg);
}

.docs-faq-answer {
  padding: 0 20px 16px 44px;
  border-top: 1px solid var(--border-subtle);
}

.docs-faq-answer p {
  margin-bottom: 0 !important;
  padding-top: 14px;
  font-size: 14px !important;
  line-height: 1.65;
}

/* ==========================================================================
   ENHANCED DOCS RESPONSIVE: Improved mobile experience
   ========================================================================== */
@media (max-width: 768px) {
  .docs-layout {
    padding: 14px 14px;
    gap: 10px;
  }

  .docs-content {
    max-width: 100%;
  }

  .docs-section {
    padding-bottom: 24px;
    margin-bottom: 24px;
  }

  .docs-section h1 {
    font-size: 24px !important;
    margin-bottom: 12px;
  }

  .docs-section h2 {
    font-size: 17px !important;
    margin: 20px 0 10px 0;
  }

  .docs-section p {
    font-size: 14px !important;
    margin-bottom: 14px;
  }

  .docs-section li {
    font-size: 14px !important;
  }

  .docs-section ul, .docs-section ol {
    padding-left: 16px;
    margin-bottom: 14px;
  }

  .docs-code-container {
    margin: 14px 0;
  }

  .docs-code-container pre {
    padding: 12px;
    overflow-x: auto;
  }

  .docs-code-container code {
    font-size: 11px !important;
  }

  .docs-alert {
    padding: 12px 14px;
    margin: 16px 0;
  }

  .docs-alert h4 {
    font-size: 13px;
  }

  .docs-alert p {
    font-size: 13px !important;
  }

  .docs-table-wrapper {
    margin: 14px 0;
  }

  .docs-table th, .docs-table td {
    padding: 8px 10px;
    font-size: 12px;
  }

  .docs-table code {
    font-size: 11px;
  }

  .docs-feature-grid {
    gap: 10px;
    margin: 14px 0 20px 0;
  }

  .docs-feature-card {
    padding: 16px;
  }

  .docs-topology-cards {
    gap: 10px;
    margin: 16px 0;
  }

  .docs-topology-card {
    padding: 16px;
  }

  .docs-topology-diagram {
    padding: 14px 10px;
    margin: 18px 0;
  }

  .docs-topo-peers {
    flex-direction: column;
    width: 100%;
    gap: 8px;
  }

  .docs-topo-node {
    width: 100%;
    padding: 12px 14px;
  }

  .docs-section-badge {
    font-size: 9px;
    padding: 2px 8px;
    margin-bottom: 8px;
  }

  .docs-faq-item {
    border-radius: 6px;
  }

  .docs-faq-question {
    font-size: 14px;
    padding: 12px 14px;
    gap: 8px;
  }

  .docs-faq-answer {
    padding: 0 14px 12px 32px;
  }

  .docs-faq-answer p {
    font-size: 13px !important;
    padding-top: 10px;
  }

  .docs-code-tabs {
    margin: 14px 0;
  }

  .docs-code-tab-btn {
    padding: 8px 12px;
    font-size: 10px;
  }

  .docs-sidebar-toggle {
    font-size: 12px;
    padding: 8px 14px;
  }

  footer {
    padding: 40px 16px 24px 16px;
  }

  .footer-desc {
    font-size: 12px;
    margin-bottom: 24px;
  }

  .copyright {
    margin-top: 24px;
    padding-top: 16px;
    font-size: 10px;
  }
}

/* ==========================================================================
   NEW: Guided Setup Wizard (setup.html) Styles
   ========================================================================== */
.setup-hero {
  padding: 80px 6% 40px 6%;
  text-align: center;
}

.setup-layout {
  max-width: 800px;
  margin: 0 auto 100px auto;
  padding: 0 20px;
}

/* Wizard step sequence bar */
.setup-steps {
  display: flex;
  justify-content: space-between;
  margin-bottom: 40px;
  position: relative;
}

.setup-steps::before {
  content: '';
  position: absolute;
  top: 15px;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--border-subtle);
  z-index: 1;
}

.setup-step {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

.step-num {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #09090b;
  border: 2px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: bold;
  color: var(--text-muted);
  transition: all 0.3s ease;
}

.setup-step.active .step-num {
  border-color: var(--accent-indigo);
  color: var(--text-primary);
  box-shadow: 0 0 15px rgba(99, 102, 241, 0.4);
}

.setup-step.completed .step-num {
  border-color: var(--accent-cyan);
  background: var(--accent-cyan);
  color: #000;
}

.step-label {
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
  transition: color 0.3s ease;
}

.setup-step.active .step-label {
  color: var(--text-primary);
}

.setup-step.completed .step-label {
  color: var(--accent-cyan);
}

/* Wizard Card and form elements */
.setup-card {
  background: var(--panel-bg);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 40px;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.6);
  text-align: left;
  display: none;
}

.setup-card.active {
  display: block;
  animation: fadeIn 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.setup-card h2 {
  font-family: var(--font-sans);
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 12px;
  letter-spacing: -0.02em;
}

.setup-card p {
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 30px;
}

/* Form Group layout */
.setup-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 30px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

@media (max-width: 600px) {
  .form-row {
    grid-template-columns: 1fr;
  }
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group label {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.form-input {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  padding: 12px 14px;
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 14px;
  outline: none;
  transition: all 0.2s ease;
}

.form-input:focus {
  border-color: var(--accent-indigo);
  background: rgba(255, 255, 255, 0.04);
  box-shadow: 0 0 10px rgba(99, 102, 241, 0.1);
}

.setup-output-title {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--accent-cyan);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 10px;
  font-weight: bold;
}

.setup-output-card {
  margin: 20px 0 30px 0;
}

.setup-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 40px;
  border-top: 1px solid var(--border-subtle);
  padding-top: 24px;
}

.btn-wizard-next {
  background: var(--text-primary);
  color: var(--bg-dark);
  border: none;
  padding: 10px 20px;
  font-size: 13px;
  font-weight: 600;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-wizard-next:hover {
  background: #fff;
  box-shadow: 0 0 15px rgba(255, 255, 255, 0.2);
}

.btn-wizard-prev {
  background: transparent;
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  padding: 10px 20px;
  font-size: 13px;
  font-weight: 600;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-wizard-prev:hover {
  border-color: var(--text-secondary);
  color: var(--text-primary);
}

@media (max-width: 768px) {
  .setup-card {
    padding: 24px 20px;
  }
  .setup-hero {
    padding: 60px 20px 30px 20px;
  }
  .mockup-container {
    margin-bottom: 60px;
  }
}
@media (max-width: 600px) {
  .setup-steps {
    margin-bottom: 28px;
  }
  .setup-layout {
    margin-bottom: 60px;
  }
}
@media (max-width: 480px) {
  .setup-card {
    padding: 20px 16px;
  }
  .setup-card h2 {
    font-size: 18px !important;
  }
  .setup-card p {
    font-size: 13px !important;
    line-height: 1.5;
  }
  .step-label {
    display: none;
  }
  .setup-steps::before {
    top: 16px;
  }
  .setup-actions {
    flex-direction: column-reverse;
    gap: 12px;
    align-items: stretch;
    margin-top: 24px;
    padding-top: 16px;
  }
  .setup-actions button {
    width: 100%;
    text-align: center;
    padding: 12px 16px;
  }
  .btn-wizard-next, .btn-wizard-prev {
    width: 100%;
    justify-content: center;
    display: flex;
  }
}

/* Global page transition effects */
html {
  transition: background-color 0.3s ease;
}
body {
  transition: background-color 0.3s ease, color 0.3s ease;
}
nav {
  transition: background-color 0.3s ease, border-color 0.3s ease;
}

/* Theme Toggle Switch */
.theme-toggle {
  background: transparent;
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.25s ease;
  padding: 0;
  flex-shrink: 0;
}

.theme-toggle:hover {
  color: var(--text-primary);
  border-color: var(--border-hover);
  background: var(--panel-accent);
  transform: scale(1.05);
}

/* Hide sun in dark theme, hide moon in light theme */
html[data-theme="dark"] .theme-toggle .sun-icon {
  display: none;
}
html[data-theme="light"] .theme-toggle .moon-icon {
  display: none;
}

/* Mobile drawer theme control container */
.mobile-theme-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 500;
}


