/* === Tasked — Industrial Terminal Aesthetic === */

:root {
  --bg: #0A0E14;
  --bg-raised: #0F1419;
  --bg-card: #111820;
  --border: #1A2230;
  --border-bright: #243040;
  --text: #C5CDD8;
  --text-dim: #6B7A8D;
  --text-bright: #F0F4F8;
  --accent: #CE412B;
  --accent-glow: rgba(206, 65, 43, 0.15);
  --accent-dim: #9A3222;
  --green: #3FB950;
  --green-dim: rgba(63, 185, 80, 0.12);
  --orange: #D29922;
  --font-mono: 'Geist Mono', 'SF Mono', 'Fira Code', monospace;
  --font-body: 'DM Sans', system-ui, -apple-system, sans-serif;
  --max-w: 1180px;
}

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
}

/* === Nav === */

#nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 0 24px;
  transition: background 0.3s, backdrop-filter 0.3s;
}

#nav.scrolled {
  background: rgba(10, 14, 20, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}

.nav-brand {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 18px;
  color: var(--text-bright);
  text-decoration: none;
  letter-spacing: -0.02em;
}

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

.nav-links a {
  font-size: 14px;
  color: var(--text-dim);
  text-decoration: none;
  transition: color 0.2s;
}

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

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

.btn-nav {
  font-family: var(--font-mono);
  font-size: 13px !important;
  padding: 6px 14px;
  border: 1px solid var(--accent);
  border-radius: 4px;
  color: var(--accent) !important;
  transition: background 0.2s, color 0.2s !important;
}

.btn-nav:hover {
  background: var(--accent);
  color: var(--text-bright) !important;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  flex-direction: column;
  gap: 5px;
  padding: 4px;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  transition: transform 0.3s;
}

/* === Buttons === */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  border-radius: 6px;
  transition: all 0.2s;
  cursor: pointer;
}

.btn-primary {
  background: var(--accent);
  color: white;
  border: 1px solid var(--accent);
  box-shadow: 0 0 20px var(--accent-glow), 0 2px 8px rgba(0,0,0,0.3);
}

.btn-primary:hover {
  background: #D94E39;
  box-shadow: 0 0 30px rgba(206, 65, 43, 0.25), 0 4px 12px rgba(0,0,0,0.4);
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border-bright);
}

.btn-ghost:hover {
  border-color: var(--text-dim);
  color: var(--text-bright);
  background: rgba(255,255,255,0.03);
}

/* === Hero === */

.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 100px 24px 60px;
}

.hero-content {
  max-width: var(--max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 60px;
  align-items: center;
  width: 100%;
}

.hero h1 {
  font-family: var(--font-body);
  font-size: clamp(36px, 5vw, 56px);
  font-weight: 700;
  color: var(--text-bright);
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 20px;
}

.hero-sub {
  font-size: 17px;
  color: var(--text-dim);
  max-width: 480px;
  margin-bottom: 32px;
  line-height: 1.65;
}

.hero-ctas {
  display: flex;
  gap: 12px;
  margin-bottom: 40px;
}

.hero-badges {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.badge {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-dim);
  display: inline-flex;
  align-items: center;
}

.badge-sep {
  width: 3px;
  height: 3px;
  background: var(--border-bright);
  border-radius: 50%;
}

/* === Terminal === */

.terminal {
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 8px 40px rgba(0,0,0,0.4), 0 0 0 1px rgba(255,255,255,0.03);
}

.terminal-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: rgba(255,255,255,0.02);
  border-bottom: 1px solid var(--border);
}

.terminal-dots {
  display: flex;
  gap: 6px;
}

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

.dot-red { background: #FF5F57; }
.dot-yellow { background: #FEBC2E; }
.dot-green { background: #28C840; }

.terminal-title {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-dim);
}

.terminal-body {
  padding: 20px;
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1.8;
  min-height: 280px;
  position: relative;
}

.term-line {
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.3s, transform 0.3s;
  white-space: nowrap;
}

.term-line.visible {
  opacity: 1;
  transform: translateY(0);
}

.term-line.replaced {
  display: none;
}

.term-prompt { color: var(--text-dim); margin-right: 8px; }
.term-cmd { color: var(--text-bright); }
.term-accent { color: var(--accent); margin-right: 4px; }
.term-dim { color: var(--text-dim); }
.term-dim-r { color: var(--text-dim); margin-left: 8px; }
.term-tag {
  color: var(--text);
  display: inline-block;
  min-width: 120px;
}
.term-running { color: var(--orange); }
.term-ok { color: var(--green); }
.term-ok-bold { color: var(--green); font-weight: 600; }

.term-summary { margin-top: 4px; }

/* === Sections === */

.section-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}

.section-title {
  font-family: var(--font-body);
  font-size: clamp(28px, 3.5vw, 40px);
  font-weight: 700;
  color: var(--text-bright);
  text-align: center;
  margin-bottom: 12px;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.section-sub {
  font-size: 16px;
  color: var(--text-dim);
  text-align: center;
  max-width: 560px;
  margin: 0 auto 52px;
}

/* === Features === */

.features {
  padding: 120px 0;
  background: linear-gradient(180deg, var(--bg) 0%, rgba(15, 20, 25, 0.5) 100%);
}

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

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 28px;
  transition: border-color 0.3s, box-shadow 0.3s;
}

.feature-card:hover {
  border-color: var(--border-bright);
  box-shadow: 0 4px 20px rgba(0,0,0,0.2);
}

.feature-icon {
  font-family: var(--font-mono);
  font-size: 20px;
  color: var(--accent);
  margin-bottom: 16px;
}

.feature-card h3 {
  font-size: 17px;
  font-weight: 600;
  color: var(--text-bright);
  margin-bottom: 8px;
}

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

/* === Code Example === */

.code-example {
  padding: 120px 0;
}

.code-panels {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.code-panel {
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}

.code-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px;
  background: rgba(255,255,255,0.02);
  border-bottom: 1px solid var(--border);
}

.code-filename {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-dim);
}

.copy-btn {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-dim);
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 3px 10px;
  cursor: pointer;
  transition: all 0.2s;
}

.copy-btn:hover {
  color: var(--text);
  border-color: var(--border-bright);
}

.code-block {
  padding: 20px;
  font-family: var(--font-mono);
  font-size: 12.5px;
  line-height: 1.7;
  overflow-x: auto;
  color: var(--text);
}

.json-key { color: #7DCFFF; }
.json-str { color: #9ECE6A; }
.json-num { color: #FF9E64; }
.qs-comment { color: var(--text-dim); }

/* === How It Works === */

.how-it-works {
  padding: 120px 0;
  background: linear-gradient(180deg, var(--bg) 0%, rgba(15, 20, 25, 0.5) 100%);
}

.steps {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 0;
}

.step {
  flex: 1;
  max-width: 320px;
  text-align: center;
  padding: 0 24px;
}

.step-number {
  font-family: var(--font-mono);
  font-size: 48px;
  font-weight: 700;
  color: var(--accent);
  opacity: 0.3;
  line-height: 1;
  margin-bottom: 20px;
}

.step-content h3 {
  font-size: 20px;
  font-weight: 600;
  color: var(--text-bright);
  margin-bottom: 10px;
}

.step-content p {
  font-size: 14px;
  color: var(--text-dim);
  margin-bottom: 16px;
  line-height: 1.6;
}

.step-code {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-dim);
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 8px 14px;
  display: inline-block;
}

.step-connector {
  width: 60px;
  height: 1px;
  background: var(--border-bright);
  margin-top: 30px;
  flex-shrink: 0;
}

/* === Comparison === */

.comparison {
  padding: 120px 0;
}

.table-wrapper {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 8px;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

th, td {
  padding: 12px 18px;
  text-align: left;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

th {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-dim);
  background: var(--bg-raised);
  position: sticky;
  top: 0;
}

td {
  color: var(--text);
}

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

tr:hover td { background: rgba(255,255,255,0.015); }

.col-highlight {
  background: rgba(206, 65, 43, 0.04) !important;
  border-left: 1px solid rgba(206, 65, 43, 0.15);
  border-right: 1px solid rgba(206, 65, 43, 0.15);
}

th.col-highlight {
  color: var(--accent);
  background: rgba(206, 65, 43, 0.06) !important;
}

.check { color: var(--green); font-weight: bold; }
.cross { color: var(--text-dim); opacity: 0.4; }
.val { color: var(--text-bright); font-family: var(--font-mono); font-size: 12px; }
.val-dim { color: var(--text-dim); font-family: var(--font-mono); font-size: 12px; }

/* === Use Cases === */

.use-cases {
  padding: 120px 0;
  background: linear-gradient(180deg, var(--bg) 0%, rgba(15, 20, 25, 0.5) 100%);
}

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

.usecase-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 28px;
}

.usecase-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.1em;
  margin-bottom: 12px;
}

.usecase-card h3 {
  font-size: 17px;
  font-weight: 600;
  color: var(--text-bright);
  margin-bottom: 8px;
}

.usecase-card p {
  font-size: 14px;
  color: var(--text-dim);
  line-height: 1.6;
  margin-bottom: 16px;
}

.usecase-card code {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-dim);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 6px 12px;
  display: inline-block;
}

/* === Quick Start === */

.quickstart {
  padding: 120px 0;
}

.qs-tabs {
  display: flex;
  justify-content: center;
  gap: 4px;
  margin-bottom: 24px;
}

.qs-tab {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text-dim);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 6px 16px;
  cursor: pointer;
  transition: all 0.2s;
}

.qs-tab:hover {
  color: var(--text);
  border-color: var(--border-bright);
}

.qs-tab.active {
  color: var(--text-bright);
  background: rgba(255,255,255,0.05);
  border-color: var(--border-bright);
}

.qs-panel {
  display: none;
}

.qs-panel.active {
  display: block;
}

.quickstart-terminal {
  max-width: 700px;
  margin: 0 auto;
}

.qs-code {
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1.7;
  color: var(--text);
  overflow-x: auto;
  padding: 20px;
}

.copy-btn-qs {
  position: absolute;
  top: 56px;
  right: 16px;
}

.quickstart-ctas {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-top: 40px;
}

/* === Footer === */

footer {
  border-top: 1px solid var(--border);
  padding: 24px;
}

.footer-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-brand {
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 14px;
  color: var(--text-dim);
}

.footer-mid {
  font-size: 13px;
  color: var(--text-dim);
  display: flex;
  align-items: center;
  gap: 6px;
}

.footer-right {
  font-size: 13px;
  color: var(--text-dim);
}

/* === Reveal Animation === */

.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

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

/* === Mobile === */

@media (max-width: 1024px) {
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .code-panels { grid-template-columns: 1fr; }
  .steps { flex-direction: column; align-items: center; }
  .step-connector {
    width: 1px;
    height: 40px;
    margin: 0;
  }
}

@media (max-width: 768px) {
  .hero-content {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .hero { padding: 90px 24px 40px; min-height: auto; }

  .nav-links { display: none; }
  .nav-toggle { display: flex; }

  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 60px;
    left: 0;
    right: 0;
    background: rgba(10, 14, 20, 0.97);
    backdrop-filter: blur(12px);
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
    gap: 16px;
  }

  .features-grid { grid-template-columns: 1fr; }
  .usecases-grid { grid-template-columns: 1fr; }

  .hero-ctas { flex-direction: column; }
  .hero-ctas .btn { text-align: center; justify-content: center; }

  .footer-inner { flex-direction: column; gap: 8px; text-align: center; }
}
