/* /docs section — category + article sidebar layout. Reuses .tb-prose
   (css/blog.css) for article typography; this file is just the docs-
   specific chrome (sidebar, category cards, article list, prev/next). */

.docs-layout {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 48px;
    align-items: start;
}

.docs-sidebar {
    position: sticky;
    top: 24px;
    font-size: 0.9rem;
}

.docs-sidebar__cat { margin-bottom: 4px; }

.docs-sidebar__cat-link {
    display: block;
    padding: 9px 12px;
    border-radius: 10px;
    font-weight: 800;
    color: #334155;
    text-decoration: none;
}
.docs-sidebar__cat-link:hover { background: #f1f5f9; }

.docs-sidebar__cat--active > .docs-sidebar__cat-link {
    background: #eef2ff;
    color: #4f46e5;
}

.docs-sidebar__articles {
    list-style: none;
    margin: 4px 0 12px 12px;
    padding: 0 0 0 14px;
    border-left: 2px solid #e5e7eb;
}
.docs-sidebar__articles li a {
    display: block;
    padding: 6px 10px;
    color: #64748b;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.85rem;
    border-radius: 8px;
}
.docs-sidebar__articles li a:hover { color: #4f46e5; background: #f8fafc; }
.docs-sidebar__articles li a.docs-sidebar__art--active {
    color: #4f46e5;
    font-weight: 800;
    background: #eef2ff;
}

.docs-cat-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 24px;
}

.docs-cat-card {
    display: block;
    flex: 1 1 260px;
    max-width: 340px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 20px;
    padding: 28px;
    text-decoration: none;
    transition: box-shadow .15s, transform .15s;
}
.docs-cat-card:hover {
    box-shadow: 0 20px 40px rgba(15,23,42,.08);
    transform: translateY(-2px);
}
.docs-cat-card__icon { font-size: 1.8rem; display: block; margin-bottom: 12px; }
.docs-cat-card__name { font-weight: 900; font-size: 1.2rem; color: #0f172a; margin-bottom: 6px; }
.docs-cat-card__desc { font-size: 0.9rem; color: #64748b; line-height: 1.5; }
.docs-cat-card__count {
    font-size: 0.72rem;
    font-weight: 800;
    color: #4f46e5;
    text-transform: uppercase;
    letter-spacing: .05em;
    margin-top: 16px;
}

.docs-article-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.docs-article-card {
    display: block;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    padding: 20px 24px;
    text-decoration: none;
    transition: box-shadow .15s, border-color .15s;
}
.docs-article-card:hover {
    box-shadow: 0 12px 28px rgba(15,23,42,.06);
    border-color: #c7d2fe;
}
.docs-article-card__title { font-weight: 800; color: #0f172a; margin-bottom: 4px; }
.docs-article-card__desc { font-size: 0.88rem; color: #64748b; }

.docs-prevnext {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    margin-top: 48px;
    padding-top: 24px;
    border-top: 1px solid #e5e7eb;
}
.docs-prevnext a {
    flex: 1;
    padding: 16px 20px;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    text-decoration: none;
}
.docs-prevnext a:hover { border-color: #c7d2fe; background: #f8fafc; }
.docs-prevnext__label {
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    color: #94a3b8;
    letter-spacing: .05em;
}
.docs-prevnext__title { font-weight: 800; color: #0f172a; margin-top: 2px; }
.docs-prevnext--next { text-align: right; }

.docs-crumbs {
    font-size: 0.85rem;
    color: #94a3b8;
    font-weight: 700;
    margin-bottom: 18px;
}
.docs-crumbs a { color: #64748b; text-decoration: none; }
.docs-crumbs a:hover { color: #4f46e5; }

@media (max-width: 900px) {
    .docs-layout { grid-template-columns: 1fr; }
    .docs-sidebar { position: static; margin-bottom: 32px; }
}
