/* ═══════════════════════════════════════════════════════════
   Harvestry — Documentation Stylesheet
   Inherits design tokens from ../css/styles.css
   ═══════════════════════════════════════════════════════════ */

/* ── Docs-specific tokens ─────────────────────────────────── */

:root {
  --sidebar-bg:   #F5F3EE;
  --sidebar-w:    260px;
  --toc-w:        180px;
  --content-max:  720px;
  --nav-h:        64px;
  --docs-body-fs: 15px;
  --docs-lh:      1.75;
  --code-bg:      #1E1D1A;
  --code-border:  rgba(255,255,255,0.08);
}

/* ── Docs body override ───────────────────────────────────── */

body.docs-body-page {
  font-size: var(--docs-body-fs);
  line-height: var(--docs-lh);
}

/* ══════════════════════════════════════════════════════════
   LAYOUT — 3-column grid
   ══════════════════════════════════════════════════════════ */

.docs-layout {
  display: grid;
  grid-template-columns: var(--sidebar-w) 1fr var(--toc-w);
  grid-template-areas: "sidebar content toc";
  min-height: calc(100vh - var(--nav-h));
  align-items: start;
}

/* Sidebar */
.docs-sidebar {
  grid-area: sidebar;
  position: sticky;
  top: var(--nav-h);
  height: calc(100vh - var(--nav-h));
  overflow-y: auto;
  background: var(--sidebar-bg);
  border-right: 1px solid var(--border);
  padding: 24px 0 40px;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}
.docs-sidebar::-webkit-scrollbar { width: 4px; }
.docs-sidebar::-webkit-scrollbar-track { background: transparent; }
.docs-sidebar::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }

/* Sidebar header */
.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 16px 20px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 16px;
}
.sidebar-brand-logo {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  text-decoration: none;
}
.sidebar-brand-badge {
  font-size: 10px;
  font-weight: 600;
  background: var(--plum-light);
  color: var(--plum-text);
  border: 1px solid rgba(122,63,138,0.2);
  border-radius: var(--r-full);
  padding: 1px 7px;
}

/* Sidebar sections */
.sidebar-section {
  margin-bottom: 4px;
}

.sidebar-section-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 6px 16px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-3);
  margin-top: 20px;
  cursor: pointer;
  background: none;
  border: none;
  text-align: left;
  transition: color 0.15s;
}
.sidebar-section-toggle:hover { color: var(--text-2); }
.sidebar-chevron {
  width: 12px;
  height: 12px;
  color: var(--text-3);
  transition: transform 0.2s var(--ease);
  flex-shrink: 0;
}
.sidebar-section.collapsed .sidebar-chevron { transform: rotate(-90deg); }
.sidebar-section.collapsed .sidebar-nav { display: none; }

.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 1px;
  padding: 2px 8px;
}

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 14px;
  color: var(--text-2);
  text-decoration: none;
  transition: background 0.12s, color 0.12s;
  line-height: 1.35;
}
.sidebar-link:hover {
  background: #E7E5E4;
  color: var(--text);
}
.sidebar-link.active {
  background: rgba(122,63,138,0.10);
  color: #7A3F8A;
  font-weight: 500;
}
.sidebar-link-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  opacity: 0.5;
}
.sidebar-link.active .sidebar-link-icon { opacity: 1; }

/* Sidebar search (future) placeholder */
.sidebar-search {
  margin: 0 12px 16px;
}
.sidebar-search input {
  width: 100%;
  padding: 7px 12px;
  font-size: 13px;
  font-family: inherit;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  color: var(--text);
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.sidebar-search input:focus {
  border-color: rgba(122,63,138,0.4);
  box-shadow: 0 0 0 3px rgba(122,63,138,0.08);
}
.sidebar-search input::placeholder { color: var(--text-3); }

/* ── Content area ─────────────────────────────────────────── */

.docs-content {
  grid-area: content;
  min-width: 0;
  padding: 48px 48px 80px;
  max-width: calc(var(--content-max) + 96px);
}

/* ── Right TOC ────────────────────────────────────────────── */

.docs-toc {
  grid-area: toc;
  position: sticky;
  top: calc(var(--nav-h) + 32px);
  max-height: calc(100vh - var(--nav-h) - 64px);
  overflow-y: auto;
  padding: 0 16px 40px 0;
  scrollbar-width: none;
}
.docs-toc::-webkit-scrollbar { display: none; }

.toc-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-3);
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

.toc-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.toc-link {
  display: block;
  font-size: 13px;
  line-height: 1.4;
  color: var(--text-3);
  text-decoration: none;
  padding: 4px 8px;
  border-left: 2px solid transparent;
  border-radius: 0 4px 4px 0;
  transition: color 0.15s, border-color 0.15s;
}
.toc-link:hover { color: var(--text-2); }
.toc-link.active {
  color: #7A3F8A;
  border-left-color: #7A3F8A;
  font-weight: 500;
}
.toc-link--h3 {
  padding-left: 18px;
  font-size: 12px;
}

/* ══════════════════════════════════════════════════════════
   DOCS PAGE HERO
   ══════════════════════════════════════════════════════════ */

.docs-hero {
  margin-bottom: 40px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--border);
}

.docs-breadcrumb {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--text-3);
  margin-bottom: 14px;
}
.docs-breadcrumb a {
  color: var(--text-3);
  text-decoration: none;
  transition: color 0.15s;
}
.docs-breadcrumb a:hover { color: var(--text-2); }
.docs-breadcrumb-sep { font-size: 11px; }

.docs-hero h1 {
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.18;
  color: var(--text);
  margin-bottom: 12px;
}

.docs-hero-sub {
  font-size: 16px;
  line-height: 1.65;
  color: var(--text-2);
  max-width: 600px;
}

/* ══════════════════════════════════════════════════════════
   CONTENT TYPOGRAPHY
   ══════════════════════════════════════════════════════════ */

.docs-content h2 {
  font-size: 1.4rem;
  font-weight: 650;
  letter-spacing: -0.018em;
  line-height: 1.25;
  color: var(--text);
  margin-top: 2.5rem;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
  scroll-margin-top: calc(var(--nav-h) + 24px);
}

.docs-content h3 {
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: -0.012em;
  line-height: 1.3;
  color: var(--text);
  margin-top: 2rem;
  margin-bottom: 10px;
  scroll-margin-top: calc(var(--nav-h) + 24px);
}

.docs-content h4 {
  font-size: 0.95rem;
  font-weight: 650;
  letter-spacing: 0.01em;
  color: var(--text);
  margin-top: 1.5rem;
  margin-bottom: 8px;
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: 0.07em;
  color: var(--text-3);
}

.docs-content p {
  font-size: var(--docs-body-fs);
  line-height: var(--docs-lh);
  color: var(--text-2);
  margin-bottom: 1rem;
}

.docs-content p:last-child { margin-bottom: 0; }

.docs-content a {
  color: #7A3F8A;
  text-decoration: underline;
  text-decoration-color: rgba(122,63,138,0.3);
  text-underline-offset: 2px;
  transition: text-decoration-color 0.15s;
}
.docs-content a:hover { text-decoration-color: #7A3F8A; }

.docs-content ul,
.docs-content ol {
  margin-bottom: 1rem;
  padding-left: 1.5rem;
}
.docs-content ul { list-style: disc; }
.docs-content ol { list-style: decimal; }

.docs-content li {
  font-size: var(--docs-body-fs);
  line-height: var(--docs-lh);
  color: var(--text-2);
  margin-bottom: 0.35rem;
}

.docs-content li:last-child { margin-bottom: 0; }

.docs-content ul ul,
.docs-content ol ol { margin-top: 0.35rem; margin-bottom: 0.35rem; }

.docs-content strong { color: var(--text); font-weight: 600; }
.docs-content em { font-style: italic; }

.docs-content code {
  font-family: 'SF Mono', 'Menlo', 'Consolas', monospace;
  font-size: 13px;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 1px 5px;
  color: var(--text);
}

.docs-content hr {
  border: none;
  border-top: 1px solid var(--border);
  margin: 2rem 0;
}

/* ── Data Tables ──────────────────────────────────────────── */

.docs-table-wrap {
  overflow-x: auto;
  margin-bottom: 1.5rem;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
}

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

.docs-table th {
  background: var(--bg-alt);
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-3);
  text-align: left;
  padding: 10px 16px;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

.docs-table td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  color: var(--text-2);
  vertical-align: top;
  line-height: 1.55;
}
.docs-table tr:last-child td { border-bottom: none; }
.docs-table tr:hover td { background: var(--bg-alt); }
.docs-table td strong { color: var(--text); }

/* ══════════════════════════════════════════════════════════
   CALLOUT BOXES
   ══════════════════════════════════════════════════════════ */

.callout {
  display: flex;
  gap: 14px;
  padding: 16px 18px;
  border-radius: var(--r-md);
  margin-bottom: 1.25rem;
  font-size: 14px;
  line-height: 1.65;
}

.callout-icon {
  font-size: 16px;
  flex-shrink: 0;
  margin-top: 1px;
}

.callout-body { flex: 1; min-width: 0; }
.callout-body p { margin-bottom: 0; font-size: 14px; }
.callout-body strong { font-weight: 600; }

.callout--tip {
  background: var(--plum-light);
  border-left: 3px solid var(--plum);
  color: var(--plum-text);
}
.callout--tip strong { color: var(--plum-text); }

.callout--note {
  background: #EFF6FF;
  border-left: 3px solid #3B82F6;
  color: #1E3A5F;
}
.callout--note strong { color: #1E3A5F; }

.callout--warning {
  background: var(--amber-light);
  border-left: 3px solid var(--amber);
  color: var(--amber-text);
}
.callout--warning strong { color: var(--amber-text); }

.callout--info {
  background: var(--plum-light);
  border-left: 3px solid var(--plum);
  color: var(--plum-text);
}
.callout--info strong { color: var(--plum-text); }

/* ══════════════════════════════════════════════════════════
   CODE BLOCKS
   ══════════════════════════════════════════════════════════ */

.code-block {
  margin-bottom: 1.5rem;
  border-radius: var(--r-md);
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.06);
  box-shadow: var(--sh-sm);
}

.code-block-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #2A2825;
  padding: 8px 14px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.code-lang {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.3);
}

.code-copy-btn {
  font-size: 11px;
  font-weight: 500;
  color: rgba(255,255,255,0.35);
  background: rgba(255,255,255,0.07);
  border: none;
  border-radius: 4px;
  padding: 3px 9px;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
  font-family: inherit;
}
.code-copy-btn:hover {
  background: rgba(255,255,255,0.13);
  color: rgba(255,255,255,0.65);
}
.code-copy-btn.copied {
  background: rgba(122,63,138,0.2);
  color: #4ADE80;
}

.code-block pre {
  background: var(--code-bg);
  padding: 18px 20px;
  overflow-x: auto;
  margin: 0;
  font-family: 'SF Mono', 'Menlo', 'Consolas', monospace;
  font-size: 13px;
  line-height: 1.65;
  color: #E5E2DD;
  tab-size: 2;
}

.code-block code {
  background: none;
  border: none;
  border-radius: 0;
  padding: 0;
  font-size: inherit;
  color: inherit;
}

/* Syntax colouring (basic) */
.tok-kw  { color: #C792EA; }
.tok-str { color: #C3E88D; }
.tok-cmt { color: #546E7A; font-style: italic; }
.tok-num { color: #F78C6C; }
.tok-fn  { color: #82AAFF; }
.tok-cls { color: #FFCB6B; }
.tok-op  { color: #89DDFF; }

/* Inline terminal */
.terminal {
  background: var(--code-bg);
  border-radius: var(--r-md);
  padding: 14px 18px;
  font-family: 'SF Mono', 'Menlo', monospace;
  font-size: 13px;
  color: #C3E88D;
  margin-bottom: 1.25rem;
  overflow-x: auto;
  border: 1px solid rgba(255,255,255,0.07);
}
.terminal::before {
  content: '$ ';
  color: rgba(255,255,255,0.3);
}

/* ══════════════════════════════════════════════════════════
   STEP COMPONENT
   ══════════════════════════════════════════════════════════ */

.steps {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin: 1.5rem 0;
  position: relative;
}

.step {
  display: flex;
  gap: 20px;
  padding-bottom: 28px;
  position: relative;
}

.step:last-child { padding-bottom: 0; }

/* Vertical connector line */
.step:not(:last-child)::before {
  content: '';
  position: absolute;
  left: 15px;
  top: 32px;
  bottom: 0;
  width: 2px;
  background: var(--border);
}

.step-num {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--plum);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  position: relative;
  z-index: 1;
  box-shadow: 0 0 0 4px var(--plum-light);
}

.step-body { flex: 1; padding-top: 4px; }
.step-title {
  font-size: 15px;
  font-weight: 650;
  color: var(--text);
  margin-bottom: 6px;
  letter-spacing: -0.01em;
}
.step-body p {
  margin-bottom: 0;
  font-size: 14px;
}

/* ══════════════════════════════════════════════════════════
   KEYBOARD SHORTCUT BADGES
   ══════════════════════════════════════════════════════════ */

kbd {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 2px 6px;
  font-family: inherit;
  font-size: 12px;
  font-weight: 500;
  background: var(--bg);
  border: 1px solid var(--border);
  border-bottom-width: 2px;
  border-radius: 4px;
  color: var(--text-2);
  white-space: nowrap;
}

/* ══════════════════════════════════════════════════════════
   UI MOCKUP COMPONENTS  (macOS app illustrations)
   ══════════════════════════════════════════════════════════ */

.mock-window {
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--sh-win);
  background: #1A1917;
  margin: 24px 0 32px;
  border: 1px solid rgba(0,0,0,0.18);
}

.mock-titlebar {
  height: 40px;
  background: #252220;
  display: flex;
  align-items: center;
  padding: 0 14px;
  gap: 8px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  position: relative;
}

.mock-traffic {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
}
.mock-traffic:nth-child(1) { background: #FF5F57; }
.mock-traffic:nth-child(2) { background: #FEBC2E; }
.mock-traffic:nth-child(3) { background: #28C840; }

.mock-title {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  font-size: 12px;
  font-weight: 600;
  color: rgba(255,255,255,0.5);
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.mock-body {
  display: flex;
  height: 360px;
}

.mock-body--tall { height: 480px; }
.mock-body--short { height: 240px; }

/* Sidebar pane */
.mock-sidebar {
  width: 200px;
  flex-shrink: 0;
  background: #1C1B18;
  border-right: 1px solid rgba(255,255,255,0.06);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.mock-sidebar-header {
  padding: 10px 12px 8px;
  border-bottom: 1px solid rgba(255,255,255,0.07);
  flex-shrink: 0;
}

.mock-sidebar-title {
  font-size: 10px;
  font-weight: 700;
  color: rgba(255,255,255,0.7);
  letter-spacing: -0.01em;
}

.mock-sidebar-list {
  flex: 1;
  overflow: hidden;
  padding: 4px 6px;
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.mock-sidebar-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 8px;
  border-radius: 6px;
  cursor: default;
}

.mock-sidebar-item--active {
  background: rgba(253,186,18,0.14);
}

.mock-thumb {
  width: 36px;
  height: 24px;
  background: rgba(255,255,255,0.07);
  border-radius: 4px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 8px;
  color: rgba(255,255,255,0.2);
  overflow: hidden;
}

.mock-item-text {
  flex: 1;
  min-width: 0;
}

.mock-item-name {
  font-size: 9px;
  font-weight: 550;
  color: rgba(255,255,255,0.5);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}
.mock-sidebar-item--active .mock-item-name { color: rgba(255,255,255,0.9); font-weight: 600; }

.mock-item-status {
  font-size: 7.5px;
  color: rgba(255,255,255,0.25);
  display: flex;
  align-items: center;
  gap: 3px;
  margin-top: 2px;
}

.mock-status-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  flex-shrink: 0;
}
.mock-status-dot--green { background: #28C840; }
.mock-status-dot--amber { background: #FEBC2E; }
.mock-status-dot--gray  { background: rgba(255,255,255,0.2); }
.mock-status-dot--red   { background: #FF5F57; }

/* Detail pane */
.mock-detail {
  flex: 1;
  background: #1E1D1A;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.mock-toolbar {
  height: 36px;
  background: #252320;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 14px;
  flex-shrink: 0;
}

.mock-toolbar-title {
  font-size: 10px;
  font-weight: 600;
  color: rgba(255,255,255,0.45);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mock-toolbar-btns {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}

.mock-btn {
  font-size: 9px;
  padding: 3px 9px;
  border-radius: 4px;
  background: rgba(255,255,255,0.07);
  color: rgba(255,255,255,0.4);
  white-space: nowrap;
}

.mock-btn--green {
  background: #7A3F8A;
  color: rgba(255,255,255,0.9);
  font-weight: 600;
}

.mock-btn--amber {
  background: rgba(254,188,46,0.9);
  color: rgba(0,0,0,0.7);
  font-weight: 600;
}

.mock-detail-body {
  flex: 1;
  padding: 14px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow: hidden;
}

/* Video preview area */
.mock-video {
  width: 100%;
  max-width: 340px;
  aspect-ratio: 16/9;
  background: #0D0C0A;
  border-radius: 7px;
  border: 1px solid rgba(255,255,255,0.07);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin: 0 auto;
}

.mock-play-btn {
  width: 36px;
  height: 36px;
  background: rgba(0,0,0,0.45);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mock-play-tri {
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 7px 0 7px 12px;
  border-color: transparent transparent transparent rgba(255,255,255,0.7);
  margin-left: 2px;
}

/* Scrubber */
.mock-scrubber {
  width: 100%;
  max-width: 340px;
  height: 30px;
  background: rgba(255,255,255,0.04);
  border-radius: 6px;
  display: flex;
  align-items: center;
  padding: 0 10px;
  gap: 7px;
  margin: 0 auto;
  flex-shrink: 0;
}

.mock-scrub-time {
  font-size: 8.5px;
  color: rgba(255,255,255,0.3);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.mock-scrub-track {
  flex: 1;
  height: 3px;
  background: rgba(255,255,255,0.1);
  border-radius: 2px;
  position: relative;
}

.mock-scrub-fill {
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 30%;
  background: #7A3F8A;
  border-radius: 2px;
}

.mock-scrub-thumb {
  position: absolute;
  left: 30%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 10px;
  height: 10px;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(0,0,0,0.5);
}

.mock-scrub-btn {
  height: 20px;
  padding: 0 8px;
  border-radius: 4px;
  background: rgba(255,255,255,0.07);
  font-size: 8px;
  color: rgba(255,255,255,0.4);
  display: flex;
  align-items: center;
  white-space: nowrap;
  flex-shrink: 0;
}

.mock-scrub-btn--green {
  background: rgba(122,63,138,0.18);
  color: rgba(80,210,120,0.9);
}

/* Pipeline step rows */
.mock-pipeline {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 2px 0;
}

.mock-pipeline-step {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px;
  border-radius: 6px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.05);
}

.mock-step-check {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 8px;
  color: #fff;
  font-weight: 700;
}
.mock-step-check--done  { background: #28C840; }
.mock-step-check--run   { background: #FEBC2E; }
.mock-step-check--wait  { background: rgba(255,255,255,0.12); }
.mock-step-check--skip  { background: rgba(255,255,255,0.08); }

.mock-step-info { flex: 1; min-width: 0; }
.mock-step-name {
  font-size: 9.5px;
  font-weight: 600;
  color: rgba(255,255,255,0.6);
  line-height: 1.3;
}
.mock-step-desc {
  font-size: 8px;
  color: rgba(255,255,255,0.28);
  margin-top: 1px;
}

.mock-progress-bar {
  height: 3px;
  background: rgba(255,255,255,0.08);
  border-radius: 2px;
  overflow: hidden;
  margin-top: 4px;
}
.mock-progress-fill {
  height: 100%;
  border-radius: 2px;
  background: #28C840;
}
.mock-progress-fill--amber { background: #FEBC2E; }
.mock-progress-fill--blue  { background: #60A5FA; }

/* Segment control (macOS picker) */
.mock-segment-control {
  display: inline-flex;
  background: rgba(255,255,255,0.07);
  border-radius: 7px;
  padding: 2px;
  gap: 1px;
}

.mock-segment {
  padding: 4px 14px;
  border-radius: 5px;
  font-size: 10px;
  font-weight: 500;
  color: rgba(255,255,255,0.4);
  cursor: default;
}

.mock-segment--active {
  background: rgba(255,255,255,0.14);
  color: rgba(255,255,255,0.85);
  font-weight: 600;
}

/* Transcript block */
.mock-transcript {
  width: 240px;
  flex-shrink: 0;
  background: #181715;
  border-left: 1px solid rgba(255,255,255,0.06);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.mock-panel-header {
  padding: 9px 14px 8px;
  border-bottom: 1px solid rgba(255,255,255,0.07);
  flex-shrink: 0;
}

.mock-panel-title {
  font-size: 10px;
  font-weight: 700;
  color: rgba(255,255,255,0.7);
}

.mock-tx-scroll {
  flex: 1;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: 4px 0;
}

.mock-tx-row {
  display: flex;
  align-items: flex-start;
  gap: 0;
  padding: 5px 14px;
  flex-shrink: 0;
}
.mock-tx-row--active { background: rgba(255,255,255,0.04); }

.mock-tx-ts {
  width: 36px;
  flex-shrink: 0;
  font-size: 7px;
  font-variant-numeric: tabular-nums;
  color: rgba(255,255,255,0.22);
  padding-top: 1px;
  text-align: right;
  padding-right: 8px;
  font-family: 'SF Mono', monospace;
}
.mock-tx-row--active .mock-tx-ts { color: rgba(255,255,255,0.45); }

.mock-tx-body {
  flex: 1;
  font-size: 7.5px;
  line-height: 1.65;
  color: rgba(255,255,255,0.45);
}
.mock-tx-row--active .mock-tx-body { color: rgba(255,255,255,0.78); }

.mock-tx-hl {
  background: rgba(251,191,36,0.2);
  border-radius: 2px;
  padding: 0 2px;
  color: rgba(251,191,36,0.9);
}

.mock-tx-shot {
  margin: 3px 14px 2px;
  border-radius: 5px;
  border: 1px solid rgba(255,255,255,0.07);
  aspect-ratio: 16/9;
  background: rgba(255,255,255,0.04);
  overflow: hidden;
  flex-shrink: 0;
}

.mock-highlight-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 3px;
  font-size: 8px;
  font-weight: 500;
  margin: 1px 2px;
}
.mock-hl--yellow { background: rgba(251,191,36,0.2); color: rgba(251,191,36,0.9); }
.mock-hl--green  { background: rgba(122,63,138,0.2);  color: rgba(80,210,120,0.9); }
.mock-hl--blue   { background: rgba(96,165,250,0.2); color: rgba(147,197,253,0.9); }
.mock-hl--pink   { background: rgba(244,114,182,0.2);color: rgba(249,168,212,0.9); }

/* Mock margin note */
.mock-margin-note {
  background: rgba(122,63,138,0.15);
  border: 1px solid rgba(122,63,138,0.3);
  border-radius: 4px;
  padding: 4px 8px;
  font-size: 7.5px;
  color: rgba(200,150,220,0.85);
  margin: 3px 14px;
}

/* Mock stat label */
.mock-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.mock-stat-val {
  font-size: 11px;
  font-weight: 700;
  color: rgba(255,255,255,0.7);
  font-variant-numeric: tabular-nums;
}
.mock-stat-lbl {
  font-size: 7px;
  color: rgba(255,255,255,0.25);
  margin-top: 1px;
}

/* Settings pane mock */
.mock-settings {
  flex: 1;
  background: #1E1D1A;
  padding: 16px 20px;
  overflow: hidden;
}

.mock-settings-section {
  margin-bottom: 14px;
}

.mock-settings-title {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.3);
  margin-bottom: 7px;
}

.mock-settings-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 10px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 6px;
  margin-bottom: 4px;
}

.mock-settings-label {
  font-size: 9.5px;
  color: rgba(255,255,255,0.55);
}

.mock-settings-value {
  font-size: 9px;
  color: rgba(255,255,255,0.3);
  font-family: 'SF Mono', monospace;
}

.mock-settings-badge {
  font-size: 8px;
  padding: 2px 6px;
  border-radius: 3px;
  font-weight: 600;
}
.mock-settings-badge--green { background: rgba(40,200,64,0.15); color: #28C840; }
.mock-settings-badge--gray  { background: rgba(255,255,255,0.07); color: rgba(255,255,255,0.3); }

.mock-slider-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.mock-slider {
  flex: 1;
  height: 4px;
  background: rgba(255,255,255,0.1);
  border-radius: 2px;
  position: relative;
}

.mock-slider-fill {
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 50%;
  background: #7A3F8A;
  border-radius: 2px;
}

.mock-slider-knob {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%,-50%);
  width: 12px;
  height: 12px;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(0,0,0,0.4);
}

.mock-text-field {
  flex: 1;
  height: 22px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 4px;
  display: flex;
  align-items: center;
  padding: 0 8px;
}

.mock-text-placeholder {
  font-size: 8.5px;
  color: rgba(255,255,255,0.2);
  font-family: 'SF Mono', monospace;
}

/* Folder group */
.mock-folder-label {
  font-size: 7.5px;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.22);
  padding: 8px 10px 2px;
  display: flex;
  align-items: center;
  gap: 4px;
}

/* ══════════════════════════════════════════════════════════
   DOCS HOME — INTRO CARDS
   ══════════════════════════════════════════════════════════ */

.docs-home-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin: 32px 0;
}

.docs-intro-card {
  padding: 24px 22px;
  border: 1.5px solid var(--border);
  border-radius: var(--r-lg);
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s, box-shadow 0.15s, transform 0.15s;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: var(--bg);
}

.docs-intro-card:hover {
  border-color: rgba(122,63,138,0.35);
  box-shadow: 0 4px 20px rgba(122,63,138,0.08);
  transform: translateY(-2px);
}

.docs-intro-card-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--r-md);
  background: var(--plum-light);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--plum);
}
.docs-intro-card-icon svg { width: 20px; height: 20px; }

.docs-intro-card-title {
  font-size: 16px;
  font-weight: 650;
  letter-spacing: -0.012em;
  color: var(--text);
}

.docs-intro-card-body {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-2);
  flex: 1;
}

.docs-intro-card-arrow {
  font-size: 14px;
  color: var(--plum);
  margin-top: 4px;
}

/* Quick links */
.docs-quicklinks {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin: 16px 0;
}

.docs-quicklink {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  text-decoration: none;
  font-size: 14px;
  color: var(--text-2);
  transition: all 0.15s;
}
.docs-quicklink:hover {
  border-color: rgba(122,63,138,0.3);
  color: var(--text);
  background: var(--plum-light);
}

.docs-quicklink-icon { color: var(--plum); flex-shrink: 0; }

/* ══════════════════════════════════════════════════════════
   PAGINATION
   ══════════════════════════════════════════════════════════ */

.docs-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 40px;
  margin-top: 48px;
  border-top: 1px solid var(--border);
  gap: 16px;
}

.docs-pagination-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  border: 1.5px solid var(--border);
  border-radius: var(--r-md);
  text-decoration: none;
  color: var(--text-2);
  transition: all 0.15s;
  min-width: 180px;
  max-width: 260px;
}

.docs-pagination-link:hover {
  border-color: rgba(122,63,138,0.35);
  color: var(--text);
  background: var(--plum-light);
}

.docs-pagination-link--next { margin-left: auto; text-align: right; flex-direction: row-reverse; }

.docs-pagination-dir {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-3);
  display: block;
  margin-bottom: 2px;
}

.docs-pagination-title {
  font-size: 14px;
  font-weight: 550;
  color: inherit;
  display: block;
  line-height: 1.3;
}

.docs-pagination-arrow { color: var(--text-3); flex-shrink: 0; }

/* ══════════════════════════════════════════════════════════
   MOBILE SIDEBAR TOGGLE
   ══════════════════════════════════════════════════════════ */

.sidebar-toggle-btn {
  display: none;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-2);
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  cursor: pointer;
  margin-bottom: 20px;
  font-family: inherit;
  width: 100%;
}

.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  z-index: 199;
}

/* ══════════════════════════════════════════════════════════
   RESPONSIVE
   ══════════════════════════════════════════════════════════ */

/* Below 1100px: hide right TOC */
@media (max-width: 1100px) {
  .docs-layout {
    grid-template-columns: var(--sidebar-w) 1fr;
    grid-template-areas: "sidebar content";
  }
  .docs-toc { display: none; }
  .docs-content { max-width: none; }
}

/* Below 800px: sidebar becomes toggle drawer */
@media (max-width: 800px) {
  .docs-layout {
    grid-template-columns: 1fr;
    grid-template-areas: "content";
  }

  .sidebar-toggle-btn { display: flex; }

  .docs-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: var(--sidebar-w);
    max-width: 85vw;
    height: 100vh;
    z-index: 200;
    transform: translateX(-100%);
    transition: transform 0.25s var(--ease);
    box-shadow: var(--sh-lg);
  }

  .docs-sidebar.open {
    transform: translateX(0);
  }

  .sidebar-overlay.open {
    display: block;
  }

  .docs-content { padding: 32px 20px 64px; }

  .docs-home-grid { grid-template-columns: 1fr; }
  .docs-quicklinks { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .docs-pagination { flex-direction: column; align-items: stretch; }
  .docs-pagination-link--next { margin-left: 0; text-align: left; flex-direction: row; }
}
