/* ============================================
   assets/css/sidebar.css
   Боковая панель (TOC и Share)
   ============================================ */

.sidebar {
    position: sticky;
    top: 90px;
}

/* TOC Box */
.toc-box {
    background: var(--white);
    border: 1px solid var(--rule);
    border-top: 3px solid var(--navy);
    padding: 22px 20px;
    border-radius: 4px;
}

.toc-title {
    font-family: var(--font-sans);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--ink-light);
    margin-bottom: 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--rule);
}

.toc-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toc-list a {
    font-family: var(--font-sans);
    font-size: 12.5px;
    color: var(--ink-mid);
    text-decoration: none;
    line-height: 1.4;
    display: block;
    transition: color 0.15s;
    padding-left: 12px;
    border-left: 2px solid transparent;
}

.toc-list a:hover,
.toc-list a.active {
    color: var(--navy);
    border-left-color: var(--amber);
}

/* Share Box */
.share-box {
    margin-top: 20px;
    background: var(--white);
    border: 1px solid var(--rule);
    padding: 16px 20px;
    border-radius: 4px;
}

.share-title {
    font-family: var(--font-sans);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ink-light);
    margin-bottom: 12px;
}

.share-btns {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.share-btn {
    font-family: var(--font-sans);
    font-size: 11px;
    font-weight: 600;
    padding: 6px 12px;
    border-radius: 3px;
    text-decoration: none;
    letter-spacing: 0.04em;
    transition: opacity 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.share-btn:hover {
    opacity: 0.8;
}

.share-fb {
    background: #1877F2;
    color: white;
}

.share-tw {
    background: #1DA1F2;
    color: white;
}

.share-zalo {
    background: #0068FF;
    color: white;
}

.share-link {
    background: var(--ink-light);
    color: white;
}

/* ============================================
   Адаптивность
   ============================================ */

@media (max-width: 900px) {
    .sidebar {
        position: static;
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 16px;
    }

    .share-box {
        margin-top: 0;
    }
}

@media (max-width: 600px) {
    .sidebar {
        grid-template-columns: 1fr;
    }
}