/* Shared styles for nuyu documentation pages */

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

:root {
    /* Dark mode (default) — matches nuyu site */
    --bg-primary: #000000;
    --bg-secondary: #0a0a0a;
    --bg-content: rgba(255, 255, 255, 0.05);
    --text-primary: #E4E4E7;
    --text-secondary: #D1D5DB;
    --text-muted: #9CA3AF;
    --text-light: #6B7280;
    --border-color: rgba(255, 255, 255, 0.1);
    --border-light: rgba(255, 255, 255, 0.08);
    --accent-primary: #8B5CF6;
    --accent-secondary: #A78BFA;
    --accent-light: rgba(139, 92, 246, 0.15);
    --hover-bg: rgba(255, 255, 255, 0.08);
    --code-bg: rgba(139, 92, 246, 0.1);
}

[data-theme="light"] {
    /* Light mode override */
    --bg-primary: #f5f5f5;
    --bg-secondary: #fafafa;
    --bg-content: #ffffff;
    --text-primary: #1a1a1a;
    --text-secondary: #4b5563;
    --text-muted: #6b7280;
    --text-light: #9ca3af;
    --border-color: #e8e8e8;
    --border-light: #e5e7eb;
    --accent-primary: #6B21A8;
    --accent-secondary: #8B5CF6;
    --accent-light: #ede9fe;
    --hover-bg: #f3f4f6;
    --code-bg: #f8f4ff;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Container and Layout */
.container,
.docs-container {
    display: flex;
    min-height: 100vh;
}

/* Sidebar Styles */
.sidebar {
    width: 300px;
    background-color: var(--bg-secondary);
    border-right: 1px solid var(--border-color);
    padding: 24px 16px;
    overflow-y: auto;
    position: fixed;
    height: 100vh;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.sidebar h2 {
    font-size: 26px;
    font-weight: 800;
    margin-bottom: 32px;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 12px;
}

.sidebar h2::before {
    content: '';
    width: 4px;
    height: 28px;
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
    border-radius: 2px;
}

.nav-section {
    margin-bottom: 8px;
}

.nav-section-title {
    font-weight: 600;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--text-muted);
    margin-bottom: 4px;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    cursor: pointer;
    user-select: none;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.nav-section-title:hover {
    color: var(--text-secondary);
    background-color: var(--hover-bg);
}

.chevron {
    margin-right: 8px;
    transition: transform 0.2s ease;
    font-size: 12px;
    color: var(--text-light);
}

.nav-section.collapsed .chevron {
    transform: rotate(-90deg);
}

.nav-items {
    margin-left: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.nav-section.collapsed .nav-items {
    max-height: 0;
}

.nav-item {
    display: flex;
    align-items: center;
    padding: 8px 16px 8px 36px;
    margin: 1px 0;
    text-decoration: none;
    color: var(--text-secondary);
    border-radius: 6px;
    transition: all 0.15s ease;
    font-size: 14px;
    font-weight: 500;
    position: relative;
}

.nav-item:hover {
    background-color: var(--hover-bg);
    color: var(--text-primary);
    transform: translateX(2px);
}

.nav-item.active {
    background-color: var(--accent-light);
    color: var(--accent-primary);
    font-weight: 600;
}

.nav-item.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 16px;
    background-color: var(--accent-primary);
    border-radius: 0 2px 2px 0;
}

.nav-subsection {
    margin-left: 16px;
    margin-top: 4px;
    position: relative;
}

.nav-subsection::before {
    content: '';
    position: absolute;
    left: 8px;
    top: 0;
    bottom: 8px;
    width: 1px;
    background-color: var(--border-light);
}

.nav-subsection .nav-section-title {
    font-size: 10px;
    padding: 6px 8px;
    margin-left: 8px;
}

.nav-subsection .nav-item {
    font-size: 13px;
    padding: 6px 12px 6px 32px;
    color: var(--text-muted);
}

.nav-subsection .nav-item:hover {
    color: var(--text-secondary);
}

.nav-subsection .nav-item.active {
    background-color: var(--hover-bg);
    color: var(--accent-secondary);
}

/* In-page TOC (anchors within current page) */
.nav-toc {
    margin: 2px 0 6px;
    margin-left: 36px;
    border-left: 2px solid var(--accent-light);
    padding-left: 0;
}

.nav-toc-item {
    display: block;
    padding: 4px 12px;
    font-size: 11.5px;
    color: var(--text-muted);
    text-decoration: none;
    line-height: 1.4;
    transition: color 0.15s ease;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.nav-toc-item:hover {
    color: var(--accent-primary);
}

.nav-toc-item.active {
    color: var(--accent-primary);
    font-weight: 500;
}

/* Main Content */
.main-content {
    margin-left: 300px;
    flex: 1;
    padding: 40px;
    max-width: 900px;
}

.docs-main {
    margin-left: 300px;
    flex: 1;
    max-width: 100%;
}

.docs-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 20px;
}

/* Dark mode toggle button */
.theme-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    background-color: var(--bg-content);
    border: 1px solid var(--border-color);
    border-radius: 50%;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.theme-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.theme-toggle svg {
    width: 24px;
    height: 24px;
    color: var(--text-primary);
    transition: all 0.3s ease;
}

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

[data-theme="dark"] .sun-icon {
    display: none;
}

/* Smooth transitions for dark mode */
* {
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

.content-wrapper {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 20px;
}

.markdown-content h1 {
    font-size: 42px;
    margin-bottom: 30px;
    color: var(--text-primary);
    line-height: 1.2;
}

.markdown-content h2 {
    font-size: 28px;
    margin-top: 40px;
    margin-bottom: 20px;
    color: var(--text-primary);
}

.markdown-content h3 {
    font-size: 20px;
    margin-top: 30px;
    margin-bottom: 15px;
    color: var(--text-primary);
}

.markdown-content p {
    margin-bottom: 20px;
    color: var(--text-secondary);
    font-size: 16px;
    line-height: 1.8;
}

.markdown-content ul,
.markdown-content ol {
    margin-bottom: 20px;
    padding-left: 30px;
}

.markdown-content li {
    margin-bottom: 10px;
    color: var(--text-secondary);
}

.markdown-content strong {
    color: var(--text-primary);
    font-weight: 600;
}

.markdown-content em {
    font-style: italic;
}

.markdown-content hr {
    margin: 40px 0;
    border: none;
    border-top: 1px solid var(--border-light);
}

.markdown-content blockquote {
    border-left: 4px solid var(--accent-primary);
    padding-left: 20px;
    margin: 20px 0;
    font-style: italic;
    color: var(--text-muted);
}

.next-link {
    margin-top: 40px;
    font-style: italic;
    color: var(--text-muted);
}

.nav-button {
    display: inline-block;
    margin-top: 20px;
    padding: 12px 24px;
    background-color: var(--accent-primary);
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 600;
    transition: all 0.2s ease;
}

.nav-button:hover {
    background-color: var(--accent-secondary);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
}

[data-theme="dark"] .nav-button {
    background-color: var(--accent-secondary);
}

[data-theme="dark"] .nav-button:hover {
    background-color: var(--accent-primary);
}

/* Code blocks */
.markdown-content code {
    background-color: var(--code-bg);
    padding: 2px 6px;
    border-radius: 3px;
    font-family: 'Monaco', 'Menlo', monospace;
    font-size: 0.9em;
}

/* Dark mode toggle for content pages */
.theme-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    background-color: var(--bg-content);
    border: 1px solid var(--border-color);
    border-radius: 50%;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.theme-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

/* Smooth transitions */
* {
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

/* -----------------------------------------------
   Navigation: Coming Soon badge
----------------------------------------------- */
.nav-coming-soon-badge {
    margin-left: auto;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: var(--accent-secondary);
    background: var(--accent-light);
    padding: 2px 7px;
    border-radius: 10px;
    border: 1px solid var(--accent-secondary);
    opacity: 0.85;
    flex-shrink: 0;
}

.nav-progress-badge {
    margin-left: auto;
    font-size: 10px;
    font-family: 'DM Mono', 'SF Mono', monospace;
    color: var(--text-muted);
    flex-shrink: 0;
    padding-left: 6px;
}
.nav-progress-badge.complete {
    color: var(--accent-primary);
    font-weight: 600;
}

/* -----------------------------------------------
   Under Development page layout
----------------------------------------------- */
.dev-status-banner {
    background: linear-gradient(135deg, var(--accent-light) 0%, var(--hover-bg) 100%);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 48px 40px 40px;
    text-align: center;
    margin-bottom: 28px;
}

.dev-status-icon {
    font-size: 44px;
    margin-bottom: 16px;
    line-height: 1;
}

.dev-status-label {
    display: inline-block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: var(--accent-secondary);
    background: var(--accent-light);
    border: 1px solid var(--accent-secondary);
    padding: 3px 10px;
    border-radius: 12px;
    margin-bottom: 20px;
}

.dev-status-banner h2 {
    font-size: 26px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 12px;
}

.dev-status-banner > p {
    font-size: 16px;
    color: var(--text-secondary);
    line-height: 1.7;
    max-width: 520px;
    margin: 0 auto 28px;
}

.dev-preview-card,
.dev-bridge-card {
    background: var(--bg-content);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 28px 32px;
    margin-bottom: 20px;
}

.dev-preview-card h3,
.dev-bridge-card h3 {
    font-size: 17px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 12px;
}

.dev-preview-card p,
.dev-bridge-card p {
    color: var(--text-secondary);
    font-size: 15px;
    line-height: 1.7;
    margin-bottom: 12px;
}

.dev-preview-card ul {
    padding-left: 20px;
    margin: 0;
}

.dev-preview-card ul li {
    color: var(--text-secondary);
    font-size: 15px;
    margin-bottom: 8px;
    line-height: 1.6;
}

.dev-bridge-card {
    border-left: 4px solid var(--accent-primary);
}
/* -----------------------------------------------
   Section index: card grid
----------------------------------------------- */
.section-cards {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    margin: 32px 0;
}

.section-card {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    background: var(--bg-content);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 24px;
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.2s ease;
}

.section-card:hover {
    border-color: var(--accent-primary);
    transform: translateX(4px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}

.section-card-number {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    background: var(--accent-light);
    color: var(--accent-primary);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 15px;
}

.section-card-content h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 6px;
}

.section-card-content p {
    font-size: 14px;
    color: var(--text-muted);
    margin: 0;
    line-height: 1.5;
}

/* -----------------------------------------------
   Content page utilities
----------------------------------------------- */
.page-intro {
    font-size: 17px;
    color: var(--text-secondary);
    line-height: 1.75;
    margin: 16px 0 32px;
    max-width: 680px;
}

.prev-page-nav {
    margin-bottom: 28px;
}

.prev-page-nav a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color 0.2s ease;
}

.prev-page-nav a:hover {
    color: var(--accent-primary);
}

.next-page-nav {
    margin-top: 48px;
    padding-top: 32px;
    border-top: 1px solid var(--border-color);
}

/* -----------------------------------------------
   Docs landing page: part grid
----------------------------------------------- */
.parts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin: 32px 0;
}

.part-card {
    background: var(--bg-content);
    border: 1px solid var(--border-color);
    border-radius: 14px;
    padding: 28px;
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.2s ease;
    display: block;
}

.part-card:hover {
    border-color: var(--accent-primary);
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
}

.part-card-label {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: var(--accent-secondary);
    margin-bottom: 10px;
}

.part-card h3 {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 10px;
}

.part-card p {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.6;
    margin: 0;
}

.part-card.coming-soon {
    opacity: 0.65;
}

.part-card.coming-soon .part-card-label {
    color: var(--text-muted);
}

.part-card-progress {
    margin-top: 8px;
    font-size: 12px;
    font-family: 'DM Mono', 'SF Mono', monospace;
    color: var(--text-muted);
}
.part-card-progress.done {
    color: var(--accent-primary);
    font-weight: 600;
}

/* -----------------------------------------------
   Callout boxes
----------------------------------------------- */
.callout {
    border-left: 3px solid var(--accent-primary);
    background: var(--accent-light);
    border-radius: 0 10px 10px 0;
    padding: 20px 24px;
    margin: 32px 0;
}

.callout-title {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--accent-primary);
    margin: 0 0 10px;
}

.callout p {
    margin: 0 0 10px;
    line-height: 1.7;
    color: var(--text-primary);
}

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

/* Amber: key insight */
.callout-insight {
    border-left-color: #d97706;
    background: rgba(217, 119, 6, 0.07);
}
.callout-insight .callout-title {
    color: #d97706;
}
[data-theme="dark"] .callout-insight {
    border-left-color: #fbbf24;
    background: rgba(251, 191, 36, 0.1);
}
[data-theme="dark"] .callout-insight .callout-title {
    color: #fbbf24;
}

/* Teal: science / research note */
.callout-science {
    border-left-color: #0891b2;
    background: rgba(8, 145, 178, 0.07);
}
.callout-science .callout-title {
    color: #0891b2;
}
[data-theme="dark"] .callout-science {
    border-left-color: #22d3ee;
    background: rgba(34, 211, 238, 0.1);
}
[data-theme="dark"] .callout-science .callout-title {
    color: #22d3ee;
}

/* Green: in practice / action */
.callout-practice {
    border-left-color: #059669;
    background: rgba(5, 150, 105, 0.07);
}
.callout-practice .callout-title {
    color: #059669;
}
[data-theme="dark"] .callout-practice {
    border-left-color: #34d399;
    background: rgba(52, 211, 153, 0.1);
}
[data-theme="dark"] .callout-practice .callout-title {
    color: #34d399;
}

/* -----------------------------------------------
   Layer pyramid interactive
----------------------------------------------- */
.layer-pyramid {
    margin: 36px 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.layer-pyramid-item {
    border-radius: 10px;
    padding: 18px 24px;
    border: 1px solid var(--border-color);
    cursor: default;
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
    position: relative;
}

.layer-pyramid-item:hover {
    transform: translateX(6px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.08);
    border-color: var(--accent-secondary);
}

.layer-pyramid-0 {
    background: var(--accent-primary);
    border-color: var(--accent-primary);
    margin-left: 0;
}
.layer-pyramid-0 .layer-pyramid-name,
.layer-pyramid-0 .layer-pyramid-desc,
.layer-pyramid-0 .layer-pyramid-label {
    color: rgba(255,255,255,0.95);
}
.layer-pyramid-0:hover {
    border-color: var(--accent-primary);
    box-shadow: 0 6px 20px rgba(107, 33, 168, 0.35);
}

.layer-pyramid-1 {
    background: var(--accent-light);
    margin-left: 24px;
}

.layer-pyramid-2 {
    background: var(--bg-content);
    margin-left: 48px;
}

.layer-pyramid-3 {
    background: var(--bg-secondary);
    margin-left: 72px;
}

.layer-pyramid-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--accent-secondary);
    margin-bottom: 4px;
}

.layer-pyramid-name {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.layer-pyramid-desc {
    font-size: 13px;
    color: var(--text-secondary);
}

/* -----------------------------------------------
   Input-Output loop diagram
----------------------------------------------- */
.io-loop {
    margin: 32px 0;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 0;
    border: 1px solid var(--border-color);
    border-radius: 14px;
    overflow: hidden;
}

.io-loop-inputs,
.io-loop-outputs {
    padding: 24px 20px;
}

.io-loop-inputs {
    background: var(--accent-light);
    border-right: 1px solid var(--border-color);
}

.io-loop-outputs {
    background: var(--bg-content);
}

.io-loop-center {
    background: var(--accent-primary);
    color: white;
    padding: 24px 16px;
    text-align: center;
    min-width: 80px;
}

.io-loop-center-label {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    opacity: 0.8;
    margin-bottom: 6px;
}

.io-loop-center-name {
    font-size: 14px;
    font-weight: 700;
}

.io-loop-section-title {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--accent-primary);
    margin-bottom: 12px;
}

.io-loop-outputs .io-loop-section-title {
    color: var(--text-secondary);
}

.io-loop-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.io-loop-list li {
    font-size: 13px;
    color: var(--text-secondary);
    padding: 3px 0;
    display: flex;
    align-items: center;
    gap: 6px;
}

.io-loop-list li::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent-secondary);
    flex-shrink: 0;
}

.io-loop-outputs .io-loop-list li::before {
    background: var(--text-muted);
}

/* Surface navigation pill (docs sidebar) */
.surface-pill {
    display: flex;
    align-items: center;
    gap: 2px;
    background: rgba(255,255,255,0.06);
    border-radius: 100px;
    padding: 2px;
    font-size: 0.72rem;
    letter-spacing: 0.03em;
    width: fit-content;
    margin-bottom: 1rem;
}
.surface-pill a,
.surface-pill .pill-current {
    padding: 0.25rem 0.65rem;
    border-radius: 100px;
    text-decoration: none;
    transition: color 0.2s, background 0.2s;
}
.surface-pill a { color: #6b7280; }
.surface-pill a:hover { color: #d1d5db; }
.surface-pill .pill-current { background: rgba(255,255,255,0.1); color: #f9fafb; }

/* Techniques section divider in sidebar nav */
.nav-section-divider {
    border-top: 1px solid var(--border-color);
    margin: 1rem 0 0.5rem;
}

/* ───────────────────────────────────────────────────────────
   Wave 1: Interactive Component Styles
   ─────────────────────────────────────────────────────────── */

/* ── Page Hook ─────────────────────────────────────────── */
.page-hook {
    font-size: 17px;
    font-weight: 450;
    line-height: 1.75;
    color: var(--text-primary);
    margin: 0 0 32px;
    max-width: 680px;
}

/* ── Learning Objectives ───────────────────────────────── */
.learning-objectives {
    background: var(--accent-light);
    border-radius: 10px;
    padding: 20px 24px;
    margin: 0 0 36px;
}

.learning-objectives-title {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--accent-primary);
    margin: 0 0 10px;
}

.learning-objectives ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.learning-objectives li {
    font-size: 14px;
    color: var(--text-secondary);
    padding: 4px 0;
    display: flex;
    align-items: baseline;
    gap: 8px;
    line-height: 1.5;
}

.learning-objectives li::before {
    content: '—';
    color: var(--accent-secondary);
    flex-shrink: 0;
}

/* ── Key Takeaways ─────────────────────────────────────── */
.key-takeaways {
    border-top: 2px solid var(--border-color);
    padding: 24px 0 0;
    margin: 48px 0 0;
}

.key-takeaways-title {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin: 0 0 12px;
}

.key-takeaways ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.key-takeaways li {
    font-size: 14px;
    color: var(--text-secondary);
    padding: 6px 0;
    line-height: 1.6;
}

/* ── The Number (prominent stat) ───────────────────────── */
.the-number {
    text-align: center;
    padding: 32px 20px;
    margin: 32px 0;
}

.the-number-value {
    font-size: 48px;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

.the-number-label {
    font-size: 15px;
    color: var(--text-secondary);
    margin: 8px 0 0;
    line-height: 1.5;
}

.the-number-source {
    font-size: 12px;
    color: var(--text-muted);
    margin: 6px 0 0;
}

/* ── Myth vs Reality Callout ───────────────────────────── */
.callout-myth {
    border-left-color: #dc2626;
    background: rgba(220, 38, 38, 0.06);
}
.callout-myth .callout-title {
    color: #dc2626;
}
[data-theme="dark"] .callout-myth {
    border-left-color: #f87171;
    background: rgba(248, 113, 113, 0.1);
}
[data-theme="dark"] .callout-myth .callout-title {
    color: #f87171;
}

.myth-text {
    text-decoration: line-through;
    color: var(--text-muted);
    font-style: italic;
}

.reality-text {
    color: var(--text-primary);
    font-weight: 500;
}

/* ── Quiz Block ────────────────────────────────────────── */
.quiz-block {
    margin: 48px 0 32px;
    border-top: 2px solid var(--border-color);
    padding-top: 24px;
}

.quiz-header {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: var(--accent-primary);
    margin: 0 0 20px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.quiz-icon {
    font-size: 16px;
}

.quiz-question {
    margin: 0 0 20px;
}

.quiz-q-text {
    font-size: 15px;
    font-weight: 500;
    color: var(--text-primary);
    margin: 0 0 10px;
    line-height: 1.5;
}

.quiz-q-num {
    color: var(--text-muted);
    margin-right: 4px;
}

.quiz-options {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.quiz-option {
    display: block;
    width: 100%;
    text-align: left;
    padding: 10px 14px;
    font-size: 14px;
    color: var(--text-secondary);
    background: var(--bg-content);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease;
    font-family: inherit;
    line-height: 1.4;
}

.quiz-option:hover:not(.disabled) {
    border-color: var(--accent-secondary);
    background: var(--accent-light);
}

.quiz-option.disabled {
    cursor: default;
    opacity: 0.7;
}

.quiz-option.correct {
    border-color: #059669;
    background: rgba(5, 150, 105, 0.08);
    color: var(--text-primary);
    opacity: 1;
}

.quiz-option.wrong {
    border-color: #dc2626;
    background: rgba(220, 38, 38, 0.06);
    opacity: 1;
}

.quiz-feedback {
    display: none;
    font-size: 13px;
    line-height: 1.5;
    padding: 10px 14px;
    margin: 8px 0 0;
    border-radius: 6px;
}

.quiz-feedback.correct {
    color: #059669;
    background: rgba(5, 150, 105, 0.08);
}
[data-theme="dark"] .quiz-feedback.correct {
    color: #34d399;
    background: rgba(52, 211, 153, 0.1);
}

.quiz-feedback.wrong {
    color: #dc2626;
    background: rgba(220, 38, 38, 0.06);
}
[data-theme="dark"] .quiz-feedback.wrong {
    color: #f87171;
    background: rgba(248, 113, 113, 0.1);
}

.quiz-fb-icon {
    font-weight: 700;
    margin-right: 4px;
}

.quiz-summary {
    display: none;
    text-align: center;
    padding: 20px;
    margin: 16px 0 0;
    border-top: 1px solid var(--border-color);
}

.quiz-score {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
    font-variant-numeric: tabular-nums;
}

.quiz-score-msg {
    font-size: 14px;
    color: var(--text-secondary);
    margin: 8px 0 0;
}

/* ── Checkpoint Quiz ───────────────────────────────────── */
.checkpoint-progress {
    margin: 0 0 24px;
}

.checkpoint-progress span {
    font-size: 13px;
    color: var(--text-muted);
}

.checkpoint-bar {
    height: 4px;
    background: var(--border-color);
    border-radius: 2px;
    margin: 8px 0 0;
    overflow: hidden;
}

.checkpoint-bar-fill {
    height: 100%;
    background: var(--accent-primary);
    border-radius: 2px;
    transition: width 0.3s ease;
}

.quiz-next-btn {
    display: inline-block;
    margin: 16px 0 0;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    color: white;
    background: var(--accent-primary);
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-family: inherit;
    transition: background 0.15s ease;
}

.quiz-next-btn:hover {
    background: var(--accent-secondary);
}

.checkpoint-results {
    text-align: center;
    padding: 32px 20px;
}

.checkpoint-score-ring {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border: 4px solid var(--accent-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.checkpoint-score-num {
    font-size: 28px;
    font-weight: 800;
    color: var(--accent-primary);
}

.checkpoint-score-label {
    font-size: 14px;
    color: var(--text-secondary);
    margin: 0 0 20px;
}

.checkpoint-revisit {
    text-align: left;
    max-width: 400px;
    margin: 20px auto 0;
}

.checkpoint-revisit-title {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 8px;
}

.checkpoint-revisit ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.checkpoint-revisit li {
    padding: 4px 0;
}

.checkpoint-revisit a {
    font-size: 14px;
    color: var(--accent-primary);
    text-decoration: none;
}

.checkpoint-revisit a:hover {
    text-decoration: underline;
}

.checkpoint-perfect {
    font-size: 15px;
    color: var(--text-secondary);
    margin: 16px 0 0;
}

/* ── Slider Simulator ──────────────────────────────────── */
.slider-sim {
    margin: 24px 0;
}

.slider-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 8px;
}

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

.slider-input {
    flex: 1;
    height: 6px;
    -webkit-appearance: none;
    appearance: none;
    background: var(--border-color);
    border-radius: 3px;
    outline: none;
}

.slider-input::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--accent-primary);
    cursor: pointer;
    border: 2px solid var(--bg-primary);
    box-shadow: 0 1px 4px rgba(0,0,0,0.2);
}

.slider-input::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--accent-primary);
    cursor: pointer;
    border: 2px solid var(--bg-primary);
    box-shadow: 0 1px 4px rgba(0,0,0,0.2);
}

.slider-value {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
    min-width: 48px;
    text-align: right;
    font-variant-numeric: tabular-nums;
}

.slider-viz {
    margin: 16px 0 0;
    min-height: 60px;
}

/* ── Drag-and-Drop Sort ────────────────────────────────── */
.sort-exercise {
    margin: 24px 0;
}

.sort-items {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0 0 16px;
}

.sort-item {
    padding: 8px 14px;
    font-size: 14px;
    color: var(--text-secondary);
    background: var(--bg-content);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    cursor: pointer;
    user-select: none;
    transition: border-color 0.15s ease, transform 0.15s ease;
}

.sort-item:hover:not(.placed) {
    border-color: var(--accent-secondary);
}

.sort-item.selected {
    border-color: var(--accent-primary);
    background: var(--accent-light);
    transform: scale(1.02);
}

.sort-item.placed {
    cursor: default;
}

.sort-item.correct {
    border-color: #059669;
    background: rgba(5, 150, 105, 0.08);
    color: var(--text-primary);
}

.sort-item.wrong {
    border-color: #dc2626;
    background: rgba(220, 38, 38, 0.06);
}

.sort-buckets {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
}

.sort-bucket {
    background: var(--bg-secondary);
    border: 2px dashed var(--border-color);
    border-radius: 10px;
    padding: 16px;
    min-height: 100px;
    cursor: pointer;
    transition: border-color 0.15s ease;
}

.sort-bucket:hover {
    border-color: var(--accent-secondary);
}

.sort-bucket-label {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    margin: 0 0 10px;
}

.sort-bucket-items {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.sort-result {
    display: none;
    margin: 16px 0 0;
}

.sort-score {
    font-size: 14px;
    color: var(--text-secondary);
}

/* ── Exercise Block ────────────────────────────────────── */
.exercise-block {
    margin: 32px 0;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    overflow: hidden;
}

.exercise-step {
    padding: 14px 18px;
    border-bottom: 1px solid var(--border-light);
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.exercise-step:last-child {
    border-bottom: none;
}

.exercise-check {
    margin-top: 3px;
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    accent-color: var(--accent-primary);
}

.exercise-step.completed {
    background: rgba(5, 150, 105, 0.04);
}

.exercise-step.completed .exercise-step-header {
    text-decoration: line-through;
    color: var(--text-muted);
}

.exercise-step-header {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
    cursor: pointer;
    flex: 1;
}

.exercise-step-body {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin: 6px 0 0;
    padding-left: 30px;
}

.exercise-step.collapsed .exercise-step-body {
    display: none;
}

/* ── Breathing Timer ───────────────────────────────────── */
.breathing-timer {
    text-align: center;
    padding: 24px;
    margin: 24px 0;
}

.breathing-label {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 16px;
}

.breathing-circle {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    border: 3px solid var(--border-color);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
    transition: border-color 0.5s ease, transform 0.5s ease;
}

.breathing-circle.phase-0 {
    border-color: #059669;
    transform: scale(1.1);
}

.breathing-circle.phase-1 {
    border-color: var(--accent-primary);
    transform: scale(1.1);
}

.breathing-circle.phase-2 {
    border-color: #0891b2;
    transform: scale(0.95);
}

.breathing-phase {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

.breathing-count {
    font-size: 32px;
    font-weight: 800;
    color: var(--text-primary);
    font-variant-numeric: tabular-nums;
    line-height: 1;
}

.breathing-progress {
    font-size: 13px;
    color: var(--text-muted);
    margin: 0 0 12px;
}

.breathing-start-btn {
    padding: 10px 24px;
    font-size: 14px;
    font-weight: 600;
    color: white;
    background: var(--accent-primary);
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-family: inherit;
}

.breathing-start-btn:hover:not(:disabled) {
    background: var(--accent-secondary);
}

.breathing-start-btn:disabled {
    opacity: 0.6;
    cursor: default;
}

/* ── Countdown Timer ───────────────────────────────────── */
.countdown-timer {
    text-align: center;
    padding: 20px;
    margin: 24px 0;
}

.countdown-label {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 12px;
}

.countdown-display {
    font-size: 40px;
    font-weight: 800;
    color: var(--text-primary);
    font-variant-numeric: tabular-nums;
    margin: 0 0 12px;
}

.countdown-btn {
    padding: 8px 20px;
    font-size: 14px;
    font-weight: 600;
    color: white;
    background: var(--accent-primary);
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-family: inherit;
}

.countdown-btn:hover {
    background: var(--accent-secondary);
}

/* ── Checkpoint Page ───────────────────────────────────── */
.checkpoint-page .docs-content {
    max-width: 640px;
}

/* ── Responsive: Mobile ────────────────────────────────── */
@media (max-width: 768px) {
    .sort-buckets {
        grid-template-columns: 1fr;
    }

    .the-number-value {
        font-size: 36px;
    }

    .breathing-circle {
        width: 120px;
        height: 120px;
    }

    .countdown-display {
        font-size: 32px;
    }

    .slider-row {
        flex-wrap: wrap;
    }

    .slider-value {
        min-width: auto;
    }
}
