/* Docs page styles (file historically named examples.css) */
.examples-layout {
    display: flex;
    flex-direction: row !important;
    flex: 1;
    overflow: hidden;
    min-height: 0;
}

/* ── Sidebar ── */
.examples-sidebar {
    width: 240px;
    flex-shrink: 0;
    background: #181825;
    border-right: 1px solid #313244;
    overflow-y: auto;
    padding: 12px 0 24px;
}

.sidebar-section {
    padding: 16px 18px 8px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: #89b4fa;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    user-select: none;
    transition: color 0.15s;
}

.sidebar-section:hover { color: #74c7ec; }

.sidebar-section .chevron {
    font-size: 9px;
    transition: transform 0.2s;
    display: inline-block;
}

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

.sidebar-group {
    overflow: hidden;
    transition: max-height 0.25s ease;
}

.sidebar-group.collapsed {
    max-height: 0 !important;
}

.sidebar-item {
    display: block;
    padding: 7px 18px 7px 28px;
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
    font-size: 12px;
    color: #6c7086;
    cursor: pointer;
    border-left: 2px solid transparent;
    transition: all 0.12s;
    line-height: 1.4;
}

.sidebar-item:hover {
    color: #cdd6f4;
    background: rgba(205, 214, 244, 0.04);
}

.sidebar-item.active {
    color: #a6e3a1;
    background: rgba(166, 227, 161, 0.06);
    border-left-color: #a6e3a1;
}

/* ── Detail panel ── */
.examples-detail {
    flex: 1;
    overflow-y: auto;
    padding: 28px 36px 48px;
    min-width: 0;
}

.detail-header {
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid #313244;
}

.detail-header h2 {
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
    font-size: 18px;
    color: #a6e3a1;
    margin-bottom: 6px;
    font-weight: 600;
}

.detail-sig {
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
    font-size: 13px;
    color: #585b70;
    margin-bottom: 8px;
}

.detail-actions-badge {
    display: inline-block;
    padding: 3px 12px;
    background: rgba(249, 226, 175, 0.08);
    border: 1px solid rgba(249, 226, 175, 0.15);
    border-radius: 999px;
    font-size: 11px;
    color: #f9e2af;
    font-weight: 500;
}

.detail-desc {
    font-size: 14px;
    color: #a6adc8;
    line-height: 1.7;
    margin-bottom: 24px;
    max-width: 700px;
}

.detail-desc code {
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
    font-size: 12px;
    color: #cdd6f4;
    background: #313244;
    padding: 1px 5px;
    border-radius: 3px;
}

.detail-labels {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #585b70;
}

.detail-labels span:first-child { flex: 1; }
.detail-labels span:last-child { flex: 1; }

.detail-pair {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

.detail-card {
    background: #11111b;
    border: 1px solid #313244;
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.detail-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 14px;
    background: #181825;
    border-bottom: 1px solid #313244;
}

.detail-card-header span {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #585b70;
}

.copy-btn {
    background: transparent;
    color: #45475a;
    border: 1px solid #313244;
    border-radius: 4px;
    padding: 2px 10px;
    font-size: 10px;
    cursor: pointer;
    transition: all 0.15s;
}

.copy-btn:hover { color: #cdd6f4; border-color: #45475a; }
.copy-btn.copied { color: #a6e3a1; border-color: #a6e3a1; }

.detail-code {
    padding: 16px;
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
    font-size: 12px;
    line-height: 1.8;
    color: #cdd6f4;
    white-space: pre-wrap;
    margin: 0;
    flex: 1;
    tab-size: 4;
}

/* Flags display */
.detail-flags {
    margin-bottom: 16px;
    background: #181825;
    border: 1px solid #313244;
    border-radius: 6px;
    overflow: hidden;
    display: inline-block;
}

.detail-flags-table {
    border-collapse: collapse;
}

.detail-flags-header th {
    padding: 5px 12px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    color: #585b70;
    text-align: left;
    border-bottom: 1px solid #313244;
}

.detail-flags-table td {
    padding: 4px 12px;
    font-size: 12px;
    border-bottom: 1px solid #1e1e2e;
}

.detail-flags-table td:first-child,
.detail-flags-table td:nth-child(2) {
    white-space: nowrap;
}

.detail-flags-table td code {
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
    font-size: 11px;
    color: #cba6f7;
}

.detail-flags-table td:last-child {
    color: #a6adc8;
}

/* Guide items in sidebar */
.sidebar-guide-item {
    font-family: system-ui, -apple-system, sans-serif !important;
}

/* Guide content in detail pane */
.guide-header h2 {
    font-family: system-ui, -apple-system, sans-serif !important;
    color: #cdd6f4 !important;
}

.guide-content {
    max-width: 700px;
    font-size: 14px;
    color: #a6adc8;
    line-height: 1.7;
}

.guide-content h3 {
    font-size: 16px;
    color: #cdd6f4;
    font-weight: 600;
    margin: 28px 0 10px;
}

.guide-content h4 {
    font-size: 13px;
    color: #89b4fa;
    font-weight: 600;
    margin: 20px 0 8px;
}

.guide-content p {
    margin: 0 0 12px;
}

.guide-content ol {
    margin: 0 0 12px;
    padding-left: 20px;
}

.guide-content li {
    margin-bottom: 6px;
}

.guide-content code {
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
    font-size: 12px;
    color: #a6e3a1;
    background: #313244;
    padding: 1px 5px;
    border-radius: 3px;
}

.guide-content pre.detail-code {
    background: #11111b;
    border: 1px solid #313244;
    border-radius: 8px;
    padding: 14px 16px;
    margin: 8px 0 16px;
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
    font-size: 12px;
    line-height: 1.7;
    color: #cdd6f4;
    overflow-x: auto;
}

.guide-content a {
    color: #89b4fa;
    text-decoration: none;
}

.guide-content a:hover {
    text-decoration: underline;
}

.guide-content strong {
    color: #cdd6f4;
}

/* Syntax highlighting for code blocks */
.hl-c  { color: #6c7086; }
.hl-k  { color: #cba6f7; }
.hl-fn { color: #a6e3a1; }
.hl-s  { color: #f9e2af; }
