/* Docs-specific layout: top nav, two-column page (sidebar + content),
   typography, inline code, callouts, "Next:" link, "coming soon" entries.
   Loaded after /shared/tokens.css and /shared/components.css. */

/* ── Top nav ──────────────────────────────────────────────────────── */
nav {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 40px;
  background: rgba(10, 10, 10, 0.95);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}
nav .nav-links { display: flex; gap: 32px; align-items: center; }
nav .nav-links a { font-size: 14px; color: var(--muted); transition: color 0.2s; }
nav .nav-links a:hover { color: var(--text); text-decoration: none; }
nav .nav-links a.active { color: var(--green); }

/* ── Page shell: sidebar + content ────────────────────────────────── */
.docs-shell {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 48px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 40px 80px;
  align-items: start;
}

.sidebar {
  position: sticky;
  top: 88px;
  max-height: calc(100vh - 108px);
  overflow-y: auto;
  padding-right: 8px;
}
.sidebar h4 {
  margin: 24px 0 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--green);
}
.sidebar h4:first-child { margin-top: 0; }
.sidebar ul { list-style: none; }
.sidebar li { margin: 2px 0; }
.sidebar a {
  display: block;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 14px;
  color: var(--muted);
  transition: background 0.2s, color 0.2s;
}
.sidebar a:hover { background: var(--bg2); color: var(--text); text-decoration: none; }
.sidebar a.active {
  background: rgba(74, 222, 128, 0.1);
  color: var(--green);
  font-weight: 600;
}
.sidebar a.soon {
  color: var(--dim);
  cursor: not-allowed;
}
.sidebar a.soon::after {
  content: 'soon';
  margin-left: 6px;
  padding: 1px 6px;
  border-radius: 4px;
  background: var(--bg3);
  font-size: 10px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: var(--muted);
}
.sidebar a.soon:hover { background: transparent; color: var(--dim); }

/* ── Content typography ───────────────────────────────────────────── */
.content { max-width: 760px; }
.content .breadcrumb {
  margin-bottom: 16px;
  font-size: 13px;
  color: var(--muted);
}
.content .breadcrumb a { color: var(--muted); }
.content .breadcrumb a:hover { color: var(--text); text-decoration: none; }
.content h1 {
  margin-bottom: 20px;
  font-size: 40px;
  font-weight: 800;
  color: #fff;
  letter-spacing: -1px;
  line-height: 1.15;
}
.content .lead {
  margin-bottom: 32px;
  font-size: 18px;
  color: var(--text);
  line-height: 1.7;
}
.content h2 {
  margin: 48px 0 16px;
  font-size: 26px;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.5px;
}
.content h3 {
  margin: 32px 0 12px;
  font-size: 18px;
  font-weight: 700;
  color: #fff;
}
.content p {
  margin-bottom: 16px;
  font-size: 15px;
  color: var(--text);
  line-height: 1.75;
}
.content ul, .content ol {
  margin: 0 0 20px 24px;
  font-size: 15px;
  line-height: 1.75;
  color: var(--text);
}
.content li { margin-bottom: 6px; }
.content code:not(pre code) {
  padding: 2px 6px;
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: 4px;
  font-family: 'Fira Code', 'Cascadia Code', monospace;
  font-size: 13px;
  color: var(--green);
}
.content strong { color: #fff; font-weight: 600; }
.content a { color: var(--green); }

/* Definition list (used on concepts/leases.html for the config surface) */
.content dl { margin: 0 0 24px; }
.content dt {
  margin-top: 16px;
  font-size: 15px;
  font-weight: 600;
  color: #fff;
  font-family: 'Fira Code', 'Cascadia Code', monospace;
}
.content dd {
  margin: 4px 0 0 0;
  font-size: 14px;
  color: var(--muted);
  line-height: 1.7;
}

/* Blockquote / pillar callout */
.content blockquote {
  margin: 24px 0;
  padding: 20px 24px;
  background: rgba(74, 222, 128, 0.05);
  border-left: 3px solid var(--green);
  border-radius: 0 8px 8px 0;
  font-size: 15px;
  color: var(--text);
  line-height: 1.75;
}
.content blockquote p:last-child { margin-bottom: 0; }

/* ── Two-path (x402 vs API key) side-by-side ──────────────────────── */
.two-path {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin: 24px 0 32px;
}
.path-card {
  padding: 24px;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 12px;
}
.path-card h3 {
  margin: 0 0 6px;
  font-size: 15px;
  color: var(--green);
}
.path-card p {
  margin: 0;
  font-size: 14px;
  color: var(--muted);
}

/* Code block spacing inside content */
.content .code-block { margin-top: 20px; margin-bottom: 28px; }
.content .code-block .code-tabs {
  padding: 0 16px;
  background: var(--bg3);
}
.content pre { padding: 20px 24px; }

/* ── "Next:" link footer ─────────────────────────────────────────── */
.next-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 64px;
  padding: 20px 24px;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 12px;
  transition: border-color 0.2s;
}
.next-link:hover { border-color: var(--green); text-decoration: none; }
.next-link .next-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--green);
}
.next-link .next-title {
  margin-top: 2px;
  font-size: 16px;
  font-weight: 600;
  color: #fff;
}
.next-link .next-arrow {
  font-size: 20px;
  color: var(--green);
}

/* ── Responsive ───────────────────────────────────────────────────── */
@media (max-width: 900px) {
  nav { padding: 16px 20px; }
  nav .nav-links { gap: 18px; }
  .docs-shell {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 24px 20px 60px;
  }
  .sidebar {
    position: static;
    max-height: none;
    padding: 0;
    border-bottom: 1px solid var(--border);
    padding-bottom: 16px;
  }
  .two-path { grid-template-columns: 1fr; }
  .content h1 { font-size: 32px; }
  .content h2 { font-size: 22px; }
}
