/* ==========================================================================
   mcpspec.dev — Landing Page Styles
   Typography: IBM Plex Sans + IBM Plex Mono
   Palette: Monochrome on #09090b
   ========================================================================== */

:root {
  --bg-primary: #09090b;
  --bg-elevated: #111113;
  --bg-subtle: #18181b;
  --border: #27272a;
  --text-primary: #fafafa;
  --text-secondary: #a1a1aa;
  --text-muted: #87878f;
  --text-faint: #3f3f46;
  --font-sans: "IBM Plex Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: "IBM Plex Mono", "SF Mono", Consolas, monospace;
}

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

body {
  background: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Nav ---------- */

.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg-primary);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s;
}

.nav.scrolled {
  border-bottom-color: var(--border);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
}

.nav-logo {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  letter-spacing: 0.8px;
  text-transform: uppercase;
  text-decoration: none;
}

.nav-github {
  color: var(--text-muted);
  transition: color 0.15s;
  display: flex;
  align-items: center;
}

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

.nav-github svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

/* ---------- Hero ---------- */

.hero {
  padding: 120px 0 80px;
}

.hero-headline {
  font-family: var(--font-sans);
  font-size: 44px;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.5px;
  color: var(--text-primary);
  margin-bottom: 20px;
}

.struck {
  text-decoration: line-through;
  text-decoration-color: var(--text-secondary);
  text-decoration-thickness: 2px;
  color: var(--text-faint);
}

.hero-subtitle {
  font-family: var(--font-sans);
  font-size: 18px;
  font-weight: 400;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 20px;
}

.hero-oss {
  font-family: var(--font-sans);
  font-size: 15px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 32px;
}

.install-commands {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 20px;
}

.install-cmd {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 14px 18px;
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text-muted);
}

.install-cmd .prompt {
  color: var(--text-faint);
  margin-right: 8px;
  user-select: none;
}

.install-cmd .cmd-text {
  flex: 1;
}

.install-cmd .copy-btn {
  background: none;
  border: none;
  color: var(--text-faint);
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  transition: color 0.15s;
}

.install-cmd .copy-btn:hover {
  color: var(--text-secondary);
}

.badges {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.badges img {
  height: 20px;
}

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

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  text-decoration: none;
  padding: 12px 28px;
  border-radius: 3px;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.btn-primary {
  border: 1.5px solid var(--text-primary);
  color: var(--text-primary);
  background: transparent;
}

.btn-primary:hover {
  background: var(--bg-subtle);
}

.btn-secondary {
  border: 1px solid var(--text-faint);
  color: var(--text-muted);
  background: transparent;
}

.btn-secondary:hover {
  background: var(--bg-subtle);
  color: var(--text-secondary);
}

/* ---------- Code Snippet Section ---------- */

.section {
  padding: 80px 0;
}

.section-border {
  border-top: 1px solid var(--border);
}

.code-tabs {
  display: flex;
  gap: 0;
  margin-bottom: 0;
  border-bottom: 1px solid var(--border);
}

.code-tab {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  padding: 10px 20px;
  cursor: pointer;
  border-bottom: 1px solid transparent;
  margin-bottom: -1px;
  user-select: none;
  background: none;
  border-top: none;
  border-left: none;
  border-right: none;
  transition: color 0.15s;
}

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

.code-tab.active {
  color: var(--text-primary);
  border-bottom-color: var(--text-primary);
}

.code-panels {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-top: none;
  border-radius: 0 0 6px 6px;
  overflow: hidden;
}

.code-panel {
  display: none;
  padding: 24px;
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1.7;
  overflow-x: auto;
}

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

.code-panel pre {
  margin: 0;
  white-space: pre;
}

/* Minimal syntax highlighting — monochrome */
.kw { color: var(--text-secondary); }   /* keywords */
.str { color: var(--text-muted); }      /* strings */
.cmt { color: var(--text-faint); }      /* comments */
.fn { color: var(--text-primary); }     /* function names */

/* ---------- What You Get ---------- */

.features {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.feature {
  padding-left: 20px;
  border-left: 1px solid var(--border);
}

.feature-name {
  font-family: var(--font-mono);
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.feature-desc {
  font-family: var(--font-sans);
  font-size: 15px;
  font-weight: 400;
  color: var(--text-muted);
}

/* ---------- Viewer ---------- */

.viewer-header {
  font-family: var(--font-sans);
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 20px;
}

.viewer-split {
  display: grid;
  grid-template-columns: 2fr 3fr;
  gap: 0;
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
  min-height: 500px;
}

.viewer-input {
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--border);
}

.viewer-input-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px;
  background: var(--bg-subtle);
  border-bottom: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-muted);
}

.viewer-textarea {
  flex: 1;
  background: var(--bg-elevated);
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.6;
  border: none;
  resize: none;
  padding: 16px;
  outline: none;
  tab-size: 2;
}

.viewer-textarea::placeholder {
  color: var(--text-faint);
}

.viewer-error {
  padding: 8px 16px;
  background: #1a0a0a;
  border-top: 1px solid #3d1515;
  font-family: var(--font-mono);
  font-size: 11px;
  color: #f87171;
  display: none;
}

.viewer-error.visible {
  display: block;
}

.viewer-preview {
  background: var(--bg-elevated);
}

.viewer-preview iframe {
  width: 100%;
  height: 100%;
  border: none;
  min-height: 500px;
}

.viewer-actions {
  margin-top: 12px;
}

/* ---------- Trust Section ---------- */

.trust-headline {
  font-family: var(--font-sans);
  font-size: 28px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.trust-body {
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 400;
  color: var(--text-muted);
  line-height: 1.7;
  max-width: 640px;
}

.trust-body p {
  margin-bottom: 12px;
}

.trust-body p:last-child {
  margin-bottom: 0;
}

/* ---------- Footer ---------- */

.footer {
  border-top: 1px solid var(--border);
  padding: 32px 0;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-logo {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  letter-spacing: 0.8px;
  text-transform: uppercase;
}

.footer-links {
  display: flex;
  gap: 20px;
  align-items: center;
}

.footer-links a {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.15s;
}

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

.footer-attribution {
  text-align: center;
  margin-top: 20px;
  font-family: var(--font-sans);
  font-size: 13px;
  color: var(--text-muted);
}

.footer-attribution a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.15s;
}

.footer-attribution a:hover {
  color: var(--text-primary);
}

.footer-attribution svg {
  width: 14px;
  height: 14px;
  fill: currentColor;
  vertical-align: -2px;
  margin-left: 6px;
}

/* ---------- Focus styles ---------- */

:focus-visible {
  outline: 2px solid var(--text-muted);
  outline-offset: 2px;
  border-radius: 2px;
}

:focus:not(:focus-visible) {
  outline: none;
}

/* ---------- Responsive ---------- */

@media (max-width: 640px) {
  .hero {
    padding: 80px 0 60px;
  }

  .hero-headline {
    font-size: 32px;
  }

  .hero-subtitle {
    font-size: 16px;
  }

  .hero-ctas {
    flex-direction: column;
    gap: 10px;
  }

  .hero-ctas .btn {
    text-align: center;
  }

  .viewer-split {
    grid-template-columns: 1fr;
  }

  .viewer-input {
    border-right: none;
    border-bottom: 1px solid var(--border);
  }

  .viewer-textarea {
    min-height: 200px;
  }

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