/* BUNDLE: article-view-extra-bundle | Generated: 2026-03-07 21:44:04 | Sources: 10 */

/* --- File: articles-view.css --- */
/* Современные стили для страницы просмотра статьи */
.full-article {
    max-width: 100%;
    margin: 0 auto;
}

/* Блок 1: Заголовок */
.article-title-block {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px 20px 0;
    border-radius: 4px;
    margin-bottom: 10px;
    text-align: center;
    /* box-shadow: 0 8px 32px rgba(102, 126, 234, 0.3); */
    margin-left: -20px;
    margin-right: -20px;
    border-radius: 5px 5px 0 0;
    margin-top: -20px;
    min-height: 100px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    /* overflow: hidden; Removed to allow dropdowns to overflow */
}

/* Когда есть Wiki-панель, добавляем отступ снизу для заголовка */
.article-title-block:has(.wiki-interface) {
min-height: 150px;
}


.article-title-block.has-custom-header {
    position: relative;
    overflow: visible; /* Changed from hidden to visible */
    min-height: 200px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 30px 20px 55px;
    border-radius: 10px 10px 0 0;
    margin-bottom: 5px;
}

.article-title-block h1 {
    margin: 10px;
    font-size: 1.8rem;
    font-weight: 800;
    line-height: 1.25;
    color: #f3f4f6;
    transition: all 0.3s ease;
}

.article-title-block.text-shadow-soft h1 {
    text-shadow: 2px 2px 10px rgba(0, 0, 0, 0.5), 0 1px 3px rgba(0, 0, 0, 0.3);
}

.article-title-block.align-left {
    align-items: flex-start;
    text-align: left;
    padding-left: 40px;
}

.article-title-block.align-right {
    align-items: flex-end;
    text-align: right;
    padding-right: 40px;
}

/* Parallax Effect */
.article-title-block.parallax-bg {
    background-attachment: fixed;
    background-size: cover;
}

/* Dividers */
.header-divider {
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    overflow: hidden;
    line-height: 0;
    z-index: 2;
}

.header-divider svg {
    position: relative;
    display: block;
    width: calc(100% + 1.3px);
    height: 40px;
}

.header-divider.gradient-divider {
    height: 60px;
    background: linear-gradient(to top, #ffffff 0%, rgba(255, 255, 255, 0) 100%);
    transform: none;
    bottom: -1px;
}

/* Badge */
.article-header-badge {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(59, 130, 246, 0.9);
    color: #fff;
    padding: 6px 14px;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    z-index: 3;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.align-left .article-header-badge {
    right: 20px;
    left: auto;
}

/* Блок 2: Метаинформация */
.article-meta-block {
		border-bottom: 1px solid #e5e7eb;
    border-radius: 4px;
    padding: 0 0 14px;
    margin-bottom: 10px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 5px;
}

.meta-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.meta-label {
    font-size: 0.75rem;
    color: #6b7280;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.meta-value {
    font-size: 0.875rem;
    color: #1f2937;
    font-weight: 600;
}

.author-link {
    color: #3b82f6;
    text-decoration: none;
    transition: color 0.2s;
}

.author-link:hover {
    color: #1d4ed8;
}

/* Блок 3: Действия */
.article-actions-block {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 14px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 15px;
    box-shadow: 0 1px 4px -1px rgb(0 0 0 / 0.1);
    overflow: visible;
}

.actions-left, .actions-right {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.login-prompt {
    width: 100%;
    margin-top: 10px;
    text-align: center;
}

.action-group {
    display: flex;
    align-items: center;
    gap: 8px;
    overflow: visible;
}

.action-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    background: #f9fafb;
    color: #6b7280;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
}

.action-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}





button#like-btn {
    color: #28a745;
}
button#dislike-btn{
    color: #dc3545;
}
button#like-btn.active {
    color: #ffffff !important;
}

button#dislike-btn.active {
    color: #ffffff !important;
}

.like-btn:hover,
.like-btn.active {
    border-color: #10b981;
    background: #10b981;
    color: white!important;
}

.dislike-btn:hover,
.dislike-btn.active {
    border-color: #ef4444;
    background: #ef4444;
    color: white!important;
}

.bookmark-btn:hover,
.bookmark-btn.active {
    border-color: #f59e0b;
    background: #f59f0b00;
    color: white!important;
}

/* Стили для кнопки репоста (ответа на пост) */
.repost-article-btn-view {
    border-color: #3b82f6 !important;
    background: #eff6ff !important;
    color: #3b82f6 !important;
		font-size: 1.1rem!important;
		padding: 6px 12px!important;
}

.repost-article-btn-view:hover {
    background: #3b82f6 !important;
    color: white !important;
    border-color: #2563eb !important;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3) !important;
}

.repost-article-btn-view i {
    color: inherit !important;
}

.likes-readonly {
    display: flex;
    gap: 16px;
}

.likes-display,
.dislikes-display {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    background: #f3f4f6;
    border-radius: 4px;
    color: #6b7280;
    font-weight: 500;
}

.login-prompt p {
    margin: 0;
    color: #6b7280;
    font-size: 0.95rem;
}

.login-link {
    color: #3b82f6;
    text-decoration: none;
    font-weight: 600;
}

.login-link:hover {
    color: #1d4ed8;
}

/* Стили для кнопок в форме комментариев */
.form-buttons {
    display: flex;
    gap: 10px;
    margin-top: 10px;
		justify-content: space-between;
}

.btn-secondary {
    background-color: #f0f0f0;
    color: #333;
    border: 1px solid #ccc;
    padding: 4px 8px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.2s;
}

.btn-secondary:hover {
    background-color: #e0e0e0;
}

/* Стили для вложенных комментариев */
.comment-replies {
    margin-left: 10px;
    margin-top: 10px;
    padding-left: 10px;
}

.comment.reply {
    margin-bottom: 8px;
}

.button-secondary-article-list {
    display: inline-flex;
    align-items: center;
    padding: 8px;
    border-radius: 4px;
    font-size: 0.95rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s;
    border: 1px solid transparent;
    width: auto;
    background-color: #f3f4f6;
    color: #374151 !important;
    border-color: #e5e7eb;
}

.moderation-history-link{
	padding: 8px;
}



/* Галерея статьи */
.article-gallery-info {
    margin-bottom: 10px;
    color: #555;
    font-size: 15px;
}

/* Отображение рейтинга статьи */
.article-rating-display {
    cursor: pointer;
    padding: 5px 8px;
    background: #f8f9fa;
    border-radius: 10px;
    font-weight: bold;
    color: #495057;
    border: 2px solid #e5e7eb;
    display: inline-flex;
    align-items: center;
		gap: 2px;
}

/* Отображение рейтинга для неавторизованных пользователей */
.article-rating-display.readonly {
    padding: 4px 8px;
}

/* Иконка звезды рейтинга */
.article-rating-display i.fa-star {
    color: #ffc107;
    margin-right: 4px;
}

/* Кнопка жалобы - SVG иконка */
.report-button svg {
    width: 16px;
    height: 16px;
    margin-right: 5px;
}

/* Кнопка избранного - дополнительный padding */
.bookmark-btn.with-padding {
    padding: 6px 12px;
}

/* Иконка избранного */
.bookmark-btn i.fa-bookmark {
    margin-right: 4px;
}

/* Счетчик избранного с курсором */
.bookmark-counter.clickable {
    cursor: pointer;
}

/** Стили для навигационных кнопок футера статьи (ИКОНКИ С ТУЛТИПАМИ) */
.footer-nav-article {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 !important;
    background-color: #ffffff !important;
    border: 0px solid #e5e7eb !important;
    color: #4b5563 !important;
    border-radius: 12px !important;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
    cursor: pointer !important;
    width: 32px !important;
    height: 32px !important;
    box-sizing: border-box !important;
    text-decoration: none !important;
    flex-shrink: 0 !important;
    outline: none !important;
    appearance: none !important;
    -webkit-appearance: none !important;
}

/* Footer Layout with Share Block */
.article-footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    flex-wrap: wrap;
    gap: 15px;
    overflow: visible; /* Добавлено */
}

.article-actions-left {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    overflow: visible; /* Добавлено */
}

.article-footer-share {
    display: flex;
    align-items: center;
    margin-left: auto;
    overflow: visible; /* Добавлено */
}

/* Reset Share Block inside Footer */
.article-footer-share .pbl-sec {
    margin: 0;
    padding: 0;
    background: transparent;
    border: none;
    box-shadow: none;
    gap: 15px;
    display: flex;
    align-items: center;
}

.article-footer-share .pbl-lbl {
    font-size: 13px;
    font-weight: 500;
    color: #6b7280;
    white-space: nowrap;
    cursor: pointer;
    transition: color 0.2s;
}

.article-footer-share .pbl-lbl:hover {
    color: #3b82f6;
}

.article-footer-share .pbl-act {
    display: none !important;
}

.footer-nav-article .button-text {
    display: none !important;
}

.footer-nav-article:hover {
    background-color: #e5e7eb !important;
    color: #111827 !important;
    border-color: #d1d5db !important;
		padding: 15px !important;
		border-radius: 50% !important;
}

.footer-nav-article i,
.footer-nav-article svg {
    font-size: 1.1rem !important;
    width: 20px !important;
    height: 20px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    flex-shrink: 0 !important;
    stroke-width: 2.2 !important;
		color: #6c757d;
}

.footer-nav-article.settings-icon:hover {
    transform: rotate(45deg) !important;
}

.footer-nav-article.delete-icon:hover {
    color: #ef4444 !important;
    background-color: #fef2f2 !important;
    border-color: #fecaca !important;
}

.footer-nav-article.edit-icon:hover {
    color: #2563eb !important;
    background-color: #eff6ff !important;
    border-color: #dbeafe !important;
}

/* --- OVERRIDES: flat 3rd level --- */
.comments-section .comment-replies {
    margin-left: 0 !important;
}

.comments-section .comment.reply-3 {
    margin-left: 0 !important;
}

.comments-section .comment.reply-3 .reply-form {
    margin-left: 0 !important;
}

/* Стили для выпадающего меню настроек (шестеренка) */
.article-settings-dropdown {
    position: relative;
    display: flex;
    width: fit-content;
    height: fit-content;
}

.settings-dropdown-menu {
    position: absolute;
    bottom: calc(100% + 12px);
    left: var(--menu-left, 0); /* Будет устанавливаться через JS */
    right: auto !important;
    min-width: 220px;
    max-width: 320px;
    width: max-content;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(229, 231, 235, 0.8);
    border-radius: 14px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15), 0 5px 15px rgba(0, 0, 0, 0.05);
    padding: 10px;
    z-index: 2000;
    box-sizing: border-box;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none; /* Предотвращаем клики, когда не видно */
}

.settings-dropdown-menu.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
    transform-origin: var(--arrow-x, 50%) bottom; /* Добавлено для плавной анимации от стрелки */
}

/* Треугольник-указатель для меню настроек */
.settings-dropdown-menu::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: var(--arrow-x, 15px); /* Центрируем по иконке через JS */
    transform: translateX(-50%) rotate(45deg);
    width: 12px;
    height: 12px;
    background: #fff;
    border-right: 1px solid rgba(229, 231, 235, 0.8);
    border-bottom: 1px solid rgba(229, 231, 235, 0.8);
    z-index: -1;
    box-shadow: 5px 5px 10px rgba(0,0,0,0.05);
}

/* Состояние: открытие вниз (если сверху нет места) */
.settings-dropdown-menu.open-down {
    bottom: auto;
    top: calc(100% + 12px);
    transform: translateY(-10px);
}

.settings-dropdown-menu.open-down.show {
    transform: translateY(0);
}

.settings-dropdown-menu.open-down::after {
    bottom: auto;
    top: -6px;
    border-right: none;
    border-bottom: none;
    border-left: 1px solid rgba(229, 231, 235, 0.8);
    border-top: 1px solid rgba(229, 231, 235, 0.8);
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 10px 12px;
    color: #4b5563;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    border-radius: 8px;
    transition: all 0.2s ease;
    white-space: normal;
    word-break: break-word;
    text-align: left;
    box-sizing: border-box;
    border: none;
    background: none;
    cursor: pointer;
}

.dropdown-item:hover {
    background: #f3f4f6;
    color: #2563eb;
}

.dropdown-item i {
    font-size: 1rem;
    width: 20px;
    text-align: center;
    color: #9ca3af;
    flex-shrink: 0;
}

.dropdown-item:hover i {
    color: #2563eb;
}

.dropdown-divider {
    height: 1px;
    margin: 4px 0;
    overflow: hidden;
    background-color: #e5e7eb;
}

.text-success {
    color: #10b981 !important;
}


/* Выпадающее меню сортировки комментариев */
.sort-controls {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.95rem;
    color: #4b5563;
    margin-bottom: 5px;
}

.sort-dropdown {
    position: relative;
    display: inline-block;
}

.sort-dropdown-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    color: #475569;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

.sort-dropdown-btn:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
    color: #1e293b;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05);
}

.sort-dropdown-btn i {
    font-size: 0.7rem;
    color: #94a3b8;
    transition: transform 0.25s ease;
}

.sort-dropdown.open .sort-dropdown-btn i {
    transform: rotate(180deg);
}

.sort-dropdown-content {
    position: absolute;
    top: var(--menu-top, calc(100% + 8px));
    bottom: var(--menu-bottom, auto);
    left: var(--menu-left, 0);
    min-width: 190px;
    width: max-content;
    max-width: 280px;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(229, 231, 235, 0.8);
    border-radius: 14px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15), 0 5px 15px rgba(0, 0, 0, 0.05);
    padding: 6px;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(var(--menu-transform-y, 10px));
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.sort-dropdown.open .sort-dropdown-content {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.sort-dropdown-item {
    padding: 6px 10px;
    font-size: 0.9rem;
    color: #64748b;
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    font-weight: 500;
		margin-bottom: 2px;
}

.sort-dropdown-item:hover {
    background: #f1f5f9;
    color: #0f172a;
}

.sort-dropdown-item.active {
    background: #eff6ff;
    color: #2563eb;
    font-weight: 600;
}



/* --- Утилитарные классы для замены inline styles --- */
.back-to-list-container {
    margin: 24px 0;
}

.mobile-meta-buttons-container {
    display: none;
}

/* Compact Meta Block */
.article-meta-compact {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid #f0f0f0;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 10px;
}

.meta-left {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.meta-right {
    display: flex;
    align-items: center;
    margin-left: auto;
    gap: 10px;
}

.meta-pill, .meta-author-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 8px;
    border-radius: 20px;
    background: #f8fafc;
    color: #64748b;
    font-size: 0.85rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid #e2e8f0;
}

.meta-pill i, .meta-author-pill i {
    font-size: 0.9rem;
    color: #94a3b8;
}

.meta-author-pill:hover, .meta-pill:hover {
    background: #fff;
    color: #334155;
    border-color: #cbd5e1;
    box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}

.meta-avatar {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    object-fit: cover;
}

.meta-author-name {
    font-weight: 600;
    color: #475569;
}

/* Header Dropdown */
.article-header-dropdown {
    position: relative;
    display: inline-block;
}

.meta-more-btn {
    background: transparent;
    border: 1px solid transparent;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #94a3b8;
    cursor: pointer;
    transition: all 0.2s;
}

.meta-more-btn:hover, .meta-more-btn:active {
    background: #f1f5f9;
    color: #475569;
}

.header-dropdown-menu {
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(229, 231, 235, 0.8);
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    min-width: 220px;
    display: none; /* Toggled by JS */
    z-index: 100;
    padding: 6px;
    transform-origin: top right;
    animation: dropdownFadeIn 0.2s ease-out;
}

.header-dropdown-menu.show {
    display: block;
}

@keyframes dropdownFadeIn {
    from { opacity: 0; transform: scale(0.95) translateY(-10px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

/* .dropdown-item styles merged above */

.dropdown-header-item {
    padding: 8px 12px;
    font-size: 0.8rem;
    color: #9ca3af;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: default;
}

.dropdown-header-item i {
    width: 20px;
    text-align: center;
}

/* Override/Fix for title block to be more compact */
.article-title-block {
    padding: 20px 20px;
    min-height: auto; 
}

/* Hide detailed stats by default to keep header compact */
.article-meta-stats {
    display: none !important;
}

.article-meta-stats.visible {
    display: flex !important;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-5px); }
    to { opacity: 1; transform: translateY(0); }
}


/* Адаптивность */
@media (max-width: 768px) {
    .action-group.likes-group>button#like-btn,button#dislike-btn {
        padding: 4px 8px;
        /* font-size: 1rem; */
    }

    .full-article {
        background-color: #fff;
        border-radius: 6px;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
        padding: 8px!important;
        margin-bottom: 10px!important;
    }

    .article-title-block {
        padding: 5px 8px;
        margin-left: -10px;
        margin-right: -10px;
        border-radius: 5px 5px 0 0;
        margin-top: -10px;
    }

    .article-title-block h1 {
        font-size: 1.5rem;
        color: #e5e7eb;
    }

    .article-meta-block {
        grid-template-columns: 1fr;
        padding: 10px;
    }

    .article-actions-block {
        flex-direction: row;
        align-items: stretch;
        padding: 8px;
        display: flex;
        flex-wrap: wrap;
    }

    .article-footer-content {
        display: flex !important;
        flex-direction: row !important;
        justify-content: space-between !important;
        align-items: center !important;
        gap: 10px !important;
        flex-wrap: nowrap !important;
    }

    .article-actions-left {
        display: flex !important;
        flex-direction: row !important;
        justify-content: flex-start !important;
        gap: 8px !important;
        flex-wrap: nowrap !important;
    }

    .article-footer-share {
        width: auto !important;
        margin-left: auto !important;
    }

    .article-footer-share .pbl-sec {
        flex-direction: row !important;
        align-items: center !important;
        gap: 5px !important;
    }

    .article-footer-share .pbl-lbl span {
        display: none !important;
    }

    .article-footer-share .pbl-lbl {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        width: 36px !important;
        height: 36px !important;
        background: #f3f4f6 !important;
        border-radius: 10px !important;
    }

    .article-footer-share .pbl-lbl i {
        margin: 0 !important;
        font-size: 1.1rem !important;
    }

    /* Навигация в футере (иконки без текста) */
    .footer-nav-article {
        padding: 0 !important;
        margin: 0 !important;
        border-radius: 12px !important;
        justify-content: center !important;
        display: flex !important;
        align-items: center !important;
    }

    .footer-nav-article .button-text {
        display: none !important;
    }

    .button-secondary {
        font-size: 0.8rem;
    }

    .action-group {
        justify-content: center;
				display: contents;
    }

    .article-tags {
        gap: 0;
    }

    .article-meta-block-wrapper {
        display: none;
    }

    /* Контейнер для мобильных кнопок (Информация + Статистика) */
    .mobile-meta-buttons-container {
        display: flex !important;
        gap: 8px;
        margin: 10px 0 12px 0;
        flex-wrap: wrap;
    }

    .meta-toggle-btn {
        display: flex !important;
        align-items: center;
        gap: 6px;
        flex: 1;
        min-width: 120px;
        padding: 8px 14px;
        background: #f3f4f6;
        border: none;
        border-radius: 6px;
        font-size: 13px;
        color: #374151;
        cursor: pointer;
        box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
        transition: all 0.2s ease;
    }

    .meta-toggle-btn:active {
        transform: scale(0.95);
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    }

    .meta-toggle-btn i {
        font-size: 16px;
    }

    .article-meta-block-wrapper.open {
        display: block;
        margin-bottom: 12px;
    }

    .meta-item {
        display: flex;
        flex-direction: row;
        gap: 4px;
    }

    .meta-label {
        font-size: 0.7rem;
        color: #6b7280;
        font-weight: 500;
        text-transform: uppercase;
        letter-spacing: 0.5px;
    }

    .meta-value {
        font-size: 0.775rem;
        color: #1f2937;
        font-weight: 600;
    }

		.article-meta-block-wrapper {
    margin-bottom: 10px;
    background: #f3f4f6;
    padding: 5px;
    border-radius: 6px;
}
.meta-left {
    gap: 0;
}

}

@media (max-width: 480px) {
    .full-article {
        padding: 8px 12px;
    }

    .article-title-block h1 {
        font-size: 1.2rem;
    }

    .action-btn {
        padding: 8px 12px;
        font-size: 0.9rem;
    }

    .article-actions-block {
        background: #fff;
        border: 1px solid #e5e7eb;
        border-radius: 8px;
        padding: 8px;
        margin-bottom: 10px;
        display: flex;
        align-items: center;
        justify-content: space-between;
        flex-wrap: wrap;
        box-shadow: 0 0 0 rgba(0, 0, 0, 0.05);
    }

}

@media (max-width: 360px) {

    .article-actions-block {
        flex-direction: row;
        align-items: stretch;
        padding: 8px;
    }

}


@media (max-width: 768px) {
    .settings-dropdown-menu {
        min-width: 260px;
        max-width: calc(100vw - 20px);
    }
		.article-meta-compact {
			margin-bottom: 0;
		}
		
		.mobile-hidden {
			display: none !important;
		}
}

@media (max-width: 480px) {
    .settings-dropdown-menu {
        max-width: calc(100vw - 20px);
        min-width: 200px;
    }
    .sort-controls {
        flex-direction: row;
        width: 100%;
        gap: 5px;
    }
    .sort-controls > span {
        display: none;
    }
    .sort-dropdown {
        flex-grow: 1;
    }
    .sort-dropdown-btn {
        /* width: 100%; */
        justify-content: space-between;
    }
}
.article-header-overlay { border-radius: inherit; pointer-events: none; }

/* Улучшенные стили для уведомлений о статусе статьи */
.article-status-notice {
    border-radius: 12px;
    padding: 16px 20px;
    margin: 10px 0 20px;
    border: none;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    position: relative;
    overflow: hidden;
    background: white; /* Базовый фон */
}

/* Цвета для разных типов алертов (если нет глобальных или нужны свои) */
.article-status-notice.alert-warning {
    background: #fffbeb;
    border-left: 5px solid #f59e0b;
}

.article-status-notice.alert-info {
    background: #eff6ff;
    border-left: 5px solid #3b82f6;
}

.article-status-notice.alert-danger {
    background: #fef2f2;
    border-left: 5px solid #ef4444;
}

.article-status-notice.alert-purple {
    background: #f5f3ff;
    border-left: 5px solid #8b5cf6;
}

.article-status-notice h4 {
    margin-top: 0;
    margin-bottom: 8px;
    font-size: 1.1rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
    color: #1f2937;
}

.article-status-notice p {
    margin-bottom: 12px;
    opacity: 0.9;
    font-size: 0.95rem;
    color: #4b5563;
}

.moderation-feedback {
    margin: 12px 0;
    padding: 12px 16px;
    background: rgba(0, 0, 0, 0.04);
    border-left: 4px solid #6b7280;
    border-radius: 6px;
}

.moderation-feedback strong {
    display: block;
    margin-bottom: 6px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #374151;
}

.feedback-text {
    font-size: 0.95rem;
    line-height: 1.5;
    color: #1f2937;
}

.alert-warning .moderation-feedback { border-left-color: #f59e0b; background: rgba(245, 158, 11, 0.08); }
.alert-info .moderation-feedback    { border-left-color: #3b82f6; background: rgba(59, 130, 246, 0.08); }
.alert-danger .moderation-feedback  { border-left-color: #ef4444; background: rgba(239, 68, 68, 0.08); }
.alert-purple .moderation-feedback  { border-left-color: #8b5cf6; background: rgba(139, 92, 246, 0.08); }

.status-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 15px;
}

/* Новые компактные кнопки */
.draft-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid transparent;
    cursor: pointer;
    white-space: nowrap;
}

.draft-btn i {
    font-size: 0.9rem;
}

.draft-btn:hover {

    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.draft-btn:active {
    transform: translateY(0);
}

/* Варианты кнопок */
.draft-btn-primary {
    background: #3b82f6;
    color: white !important;
}

.draft-btn-primary:hover {
    background: #2563eb;
}

.draft-btn-success {
    background: #10b981;
    color: white !important;
}

.draft-btn-success:hover {
    background: #059669;
}

.draft-btn-secondary {
    background: #f3f4f6;
    color: #4b5563 !important;
    border-color: #e5e7eb;
}

.draft-btn-secondary:hover {
    background: #e5e7eb;
    color: #1f2937 !important;
}

.draft-btn-info {
    background: #0ea5e9;
    color: white !important;
}

.draft-btn-info:hover {
    background: #0284c7;
}

/* Адаптивность для мобильных */
@media (max-width: 600px) {
    .article-status-notice {
        padding: 12px 15px;
    }

    .draft-btn {
        padding: 8px 10px;
        justify-content: center;
        flex: 1 1 auto;
        min-width: 40px;
    }

    .draft-btn-label {
        display: none;
    }

    .draft-btn i {
        margin: 0;
        font-size: 1.1rem;
    }

    .status-actions {
        gap: 8px;
    }
}

/* Стили для неактивных кнопок действий */
.action-btn.disabled {
    opacity: 0.5;
    cursor: not-allowed !important;
    filter: grayscale(1);
    pointer-events: auto; /* Позволяем клик для вызова alert */
		padding: 8px;
}

.action-btn.disabled:hover {
    transform: none !important;
    box-shadow: none !important;
    background: #adb2b6 !important;
    border-color: #e5e7eb !important;
		color: #ffffff!important;
}


/* --- File: ownership.css --- */
/* Ownership UI styles */
.ownership-transfer-badge{display:inline-flex;align-items:center;gap:8px;padding:6px 10px;border:1px solid #e5e7eb;border-radius:8px;background:#f9fafb;color:#111827;font-size:13px;margin-bottom:6px;}
.ownership-transfer-badge i{font-style:normal}
.ownership-transfer-badge .details-link{margin-left:6px;color:#2563eb;text-decoration:none}
.ownership-transfer-badge .details-link:hover{text-decoration:underline}
.ownership-transfer-badge.status-pending{border-color:#fbbf24;background:#fffbeb}
.ownership-transfer-badge.status-completed{border-color:#34d399;background:#ecfdf5}
.ownership-transfer-badge.status-canceled{border-color:#fca5a5;background:#fef2f2}
.ownership-transfer-badge.status-reverted{border-color:#93c5fd;background:#eff6ff}
.ownership-transfer-badge .badge-actions{display:inline-flex;gap:6px;margin-left:8px}
.ownership-manage-link{display:inline-flex;align-items:center;gap:6px;padding:4px 8px;border:1px solid #e5e7eb;border-radius:6px;background:#fff;color:#374151;text-decoration:none;}
.ownership-manage-link:hover{background:#f3f4f6}

/* Transfer page styles */
.ow-page{background:#fff;border-radius:12px;box-shadow:0 6px 24px rgba(0,0,0,.06);padding:18px;margin:14px 0;}
.ow-back{margin-bottom:16px}
.ow-back-btn{display:inline-flex;align-items:center;gap:8px;padding:8px 16px;border:1px solid #e5e7eb;border-radius:6px;background:#f9fafb;color:#4b5563;font-size:14px;font-weight:500;text-decoration:none;transition:all .2s ease;box-shadow:0 1px 2px rgba(0,0,0,.05)}
.ow-back-btn:hover{background:#fff;border-color:#d1d5db;color:#111827;transform:translateY(0);box-shadow:0 4px 6px rgba(0,0,0,.05)}
.ow-back-btn i {font-size:12px;color:#9ca3af;transition:transform .2s ease}
.ow-back-btn:hover i {transform:translateX(0);color:#4b5563}
.ow-title{margin:0 0 8px 0}
.ow-status{display:flex;align-items:center;gap:10px;color:#374151;margin-top:2px}
.ow-badge{display:inline-flex;align-items:center;gap:6px;padding:4px 10px;border-radius:9999px;border:1px solid #e5e7eb;font-size:12px;line-height:1.6}
.ow-badge.pending{background:#fffbeb;border-color:#fbbf24;color:#92400e}
.ow-badge.completed{background:#ecfdf5;border-color:#34d399;color:#065f46}
.ow-badge.reverted{background:#eff6ff;border-color:#93c5fd;color:#1e3a8a}
.ow-badge.canceled{background:#fef2f2;border-color:#fca5a5;color:#7f1d1d}

.ow-cancel{display:flex;flex-wrap:wrap;gap:8px;margin:12px 0}
.ow-input{min-width:280px;flex:1 1 280px;padding:10px 12px;border:1px solid #d1d5db;border-radius:8px;background:#fff;color:#111827;transition:border-color .15s, box-shadow .15s}
.ow-input:focus{outline:none;border-color:#2563eb;box-shadow:0 0 0 3px rgba(37,99,235,.15)}
.ow-btn{padding:8px 12px;border:1px solid #d1d5db;border-radius:6px;background:#f9fafb;color:#111827;cursor:pointer}
.ow-btn:hover{background:#e9ecef;color:#000000;}

.ow-history{margin-top:16px;border-top:1px solid #eef2f7;padding-top:12px}
.ow-history h3{margin:0 0 10px 0}
.ow-item{padding:10px 0;border-bottom:1px solid #f3f4f6}
.ow-item:last-child{border-bottom:none}
.ow-item .ow-meta{color:#6b7280;font-size:12px;margin-top:2px}
.ow-reason{color:#ef4444;font-size:12px;margin-top:2px}

/* Small helpers */
.ow-mr6{margin-right:6px}


/* --- File: tag-overflow.css --- */
.article-tags {
    position: relative;
    line-height: 1.5;
    margin: 0 0 8px;
    transition: max-height 0.3s ease;
    visibility: visible;
    /* ВРЕМЕННО: показываем теги сразу */
    display: flex;
    align-items: baseline;
}



.article-tags.tags-ready {

    visibility: visible;
    /* Показываем теги после обработки JavaScript */

    /* display: inline-table; */
    display: flex;
    align-items: baseline;

}



.article-tags.expanded {

    height: auto;

}



.article-tags .tags-container {

    /* display: inline-flex; */

    flex-wrap: wrap;

    gap: 5px;

    align-items: center;

    display: inline;

}



.article-tags .tag {

    display: inline-flex;

    align-items: center;

    background-color: #f0f2f5;

    color: #4a5568;

    padding: 3px 10px;

    border-radius: 15px;

    font-size: 0.75rem;

    text-decoration: none;

    transition: background-color 0.2s;

    white-space: nowrap;
    margin-right: 0 !important;

}



.article-tags .tag:hover {

    background-color: #e2e8f0;

    color: #2d3748;

}



.more-tags-container {

    display: block;

    margin-top: 5px;

}



.show-more-tags {

    display: none;
    /* Скрыт по умолчанию, покажем через JavaScript */

    margin-left: 5px;

    color: #4299e1;

    font-size: 0.85rem;

    cursor: pointer;

    white-space: nowrap;

    background: none;

    border: none;

    padding: 3px 8px;

    border-radius: 15px;

    background-color: #ebf4ff;

    transition: background-color 0.2s;

}



.show-more-tags:hover {

    background-color: #bee3f8;

    color: #2b6cb0;

}



.tags-label {

    font-weight: 500;

    margin-right: 8px;

    white-space: nowrap;

}



/* Стили для скрытых тегов */

.article-tags .hidden-tag {

    display: none !important;

}



/* В развернутом состоянии показываем все теги */

.article-tags.expanded .hidden-tag {

    display: inline-flex !important;

}

/* --- File: likes-popup.css --- */
/* Popup для отображения списка пользователей, оценивших статью */
.likes-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.likes-popup-overlay.show {
    opacity: 1;
    visibility: visible;
}

.likes-popup {
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    width: 90%;
    max-width: 500px;
    max-height: 80vh;
    overflow: hidden;
    transform: scale(0.8);
    transition: transform 0.3s ease;
}

.likes-popup-overlay.show .likes-popup {
    transform: scale(1);
}

.likes-popup-header {
    background: #f8f9fa;
    padding: 20px;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.likes-popup-title {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #333;
}

.likes-popup-close {
    background: none;
    border: none;
    font-size: 24px;
    color: #666;
    cursor: pointer;
    padding: 5px;
    line-height: 1;
    transition: color 0.2s ease;
}

.likes-popup-close:hover {
    color: #333;
}

.likes-popup-content {
    padding: 10px;
    max-height: 400px;
    overflow-y: auto;
}

.likes-user-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.likes-user-item {
        background: linear-gradient(145deg, #ffffff 0%, #f8fafc 100%);
            border-radius: 12px;
            padding: 12px 16px;
            display: flex;
            flex-direction: row;
            align-items: center;
            gap: 12px;
            transition: all 0.3s ease;
            border: 1px solid #e5e7eb;
            box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
            margin-bottom: 8px;
}

.likes-user-item:last-child {
    /* border-bottom: none; */
}

.likes-user-item:hover {
    /* background-color: #f3f4f6;
    border-radius: 8px; */
    background: linear-gradient(145deg, #fef3e2 0%, #fef9e7 100%);
    border-color: #f59e0b;
    box-shadow: 0 4px 8px rgba(245, 158, 11, 0.2);
    transform: translateY(-1px);

}

.likes-user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 12px;
    border: 2px solid #e9ecef;
}

.likes-user-info {
    flex: 1;
}

.likes-user-name {
    font-weight: 600;
    color: #333;
    margin: 0 0 4px 0;
    font-size: 14px;
}

.likes-user-name a {
    color: #333;
    text-decoration: none;
    transition: color 0.2s ease;
}

.likes-user-name a:hover {
    color: #3498db;
}

.likes-user-date {
    font-size: 12px;
    color: #666;
    margin: 0;
}

.likes-popup-empty {
    text-align: center;
    padding: 40px 20px;
    color: #666;
}

.likes-popup-empty i {
    font-size: 48px;
    color: #ddd;
    margin-bottom: 16px;
}

/* Анимация загрузки */
.likes-popup-loading {
    text-align: center;
    padding: 40px 20px;
}

.likes-loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #3498db;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 16px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Адаптивность */
@media (max-width: 768px) {
    .likes-popup {
        width: 95%;
        max-height: 90vh;
    }
    
    .likes-popup-header {
        padding: 16px;
    }
    
    .likes-popup-title {
        font-size: 16px;
    }
    
    .likes-popup-content {
        padding: 8px;
    }
    
    .likes-user-avatar {
        width: 36px;
        height: 36px;
    }
}

/* Стили для кликабельных счетчиков лайков */
.likes-count-clickable,
.dislikes-count-clickable {
    cursor: pointer;
}

.likes-count-clickable:hover,
.dislikes-count-clickable:hover {
    text-decoration: underline;
}

/* Для кнопок с лайками */
.action-btn .likes-count-clickable,
.action-btn .dislikes-count-clickable {
    pointer-events: auto;
}

.action-btn .likes-count-clickable:hover,
.action-btn .dislikes-count-clickable:hover {
    text-decoration: none;
    opacity: 0.8;
}

/* MY CSS */
.likes-popup-close:hover{
	color: inherit;
  background-color: #eeeeee;
}

/*END MY CSS*/


/* --- File: article-share.css --- */
/* Стили для функционала "Поделиться статьей" */

.pbl-sec {
    margin: 20px 0;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 15px;
}

.pbl-lbl {
    font-weight: 600;
    color: #495057;
    font-size: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: color 0.3s ease;
}

.pbl-lbl:hover {
    color: #3498db;
}

.pbl-lbl i {
    color: #6c757d;
    font-size: 18px;
    transition: color 0.3s ease;
}

.pbl-lbl:hover i {
    color: #3498db;
}

.pbl-act {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

/* Скрываем социальные кнопки по умолчанию */
.pbl-act .pbl-itm:not(.copy-link-btn) {
    display: none;
}

/* Popup для социальных сетей */
.pbl-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
}

.pbl-modal.active {
    display: flex;
}

.pbl-box {
    background: white;
    border-radius: 12px;
    padding: 20px;
    max-width: 450px;
    width: 90%;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
    position: relative;
    animation: popupFadeIn 0.3s ease;
}

@keyframes popupFadeIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.pbl-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid #e9ecef;
}

.pbl-hd {
    font-size: 18px;
    font-weight: 600;
    color: #495057;
    margin: 0;
}

.pbl-cls {
    background: none;
    border: none;
    font-size: 24px;
    color: #6c757d;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.pbl-cls:hover {
    background: #f8f9fa;
    color: #495057;
}

.pbl-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 15px;
}

.pbl-itm {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.pbl-itm:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    text-decoration: none;
}

.pbl-itm:active {
    transform: translateY(0);
}

/* Кнопка копирования ссылки */
.copy-link-btn {
    background: #3498db;
    color: white;
    border: 2px solid #3498db;
}

.copy-link-btn:hover {
    background: #0056b3;
    border-color: #0056b3;
    color: white;
}

.copy-link-btn.copied {
    background: #28a745;
    border-color: #28a745;
    animation: copySuccess 0.5s ease;
}

@keyframes copySuccess {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* Социальные кнопки */
.btn-tg {
    background: #0088cc;
    color: white;
    border: 2px solid #0088cc;
}

.btn-tg:hover {
    background: #006699;
    border-color: #006699;
    color: white;
}

.btn-vk {
    background: #4c75a3;
    color: white;
    border: 2px solid #4c75a3;
}

.btn-vk:hover {
    background: #3b5a7d;
    border-color: #3b5a7d;
    color: white;
}

.btn-ok {
    background: #ed812b;
    color: white;
    border: 2px solid #ed812b;
}

.btn-ok:hover {
    background: #d46e1c;
    border-color: #d46e1c;
    color: white;
}

.btn-wa {
    background: #25d366;
    color: white;
    border: 2px solid #25d366;
}

.btn-wa:hover {
    background: #1da851;
    border-color: #1da851;
    color: white;
}

.btn-fb {
    background: #3b5998;
    color: white;
    border: 2px solid #3b5998;
}

.btn-fb:hover {
    background: #2d4373;
    border-color: #2d4373;
    color: white;
}

.btn-ml {
    background: #6c757d;
    color: white;
    border: 2px solid #6c757d;
}

.btn-ml:hover {
    background: #545b62;
    border-color: #545b62;
    color: white;
}

.btn-ig {
    background: #e4405f;
    color: white;
    border: 2px solid #e4405f;
}

.btn-ig:hover {
    background: #c13584;
    border-color: #c13584;
    color: white;
}

.btn-tw {
    background: #222222;
    color: white;
    border: 2px solid #222222;
}

.btn-tw:hover {
    background: #1da1f2;
    border-color: #1da1f2;
    color: white;
}

/* URL поле для копирования */
.url-copy-container {
    display: flex;
    align-items: center;
    gap: 10px;
    background: white;
    border: 1px solid #ced4da;
    border-radius: 6px;
    padding: 8px;
    min-width: 300px;
    max-width: 100%;
}

.url-input {
    flex: 1;
    border: none;
    outline: none;
    font-size: 14px;
    color: #495057;
    background: transparent;
    padding: 4px 8px;
    font-family: 'Courier New', monospace;
}

.url-copy-btn {
    background: #f8f9fa;
    border: 1px solid #ced4da;
    color: #6c757d;
    padding: 10px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    white-space: nowrap;
}

.url-copy-btn:hover {
    background: #2980b9;
    color: #ffffff;
}

.url-copy-btn.copied {
    background: #d4edda;
    border-color: #c3e6cb;
    color: #155724;
}

/* Уведомление об успешном копировании */
.copy-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: #28a745;
    color: white;
    padding: 12px 20px;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 1000;
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
}

.copy-notification.show {
    opacity: 1;
    transform: translateX(0);
}

.copy-notification i {
    font-size: 16px;
}

/* Мобильная версия: скрыть копирование в основном блоке, показать в popup */
@media (max-width: 779px) {
  .pbl-sec .copy-link-btn,
  .pbl-sec .url-copy-container {
    display: none !important;
  }
  .pbl-cp-wp {
    display: block !important;
  }
}

/* Всегда показываем копирование в popup */
.pbl-cp-wp {
  display: flex !important;
	flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
  background: #f8f9fa;
  padding: 10px;
  border-radius: 8px;
  border: 1px solid #e9ecef;
}

.pbl-cp-wp .url-input {
  flex: 1;
  width: auto !important;
  margin-bottom: 0 !important;
  background: white;
  border: 1px solid #dee2e6;
  border-radius: 4px;
  padding: 8px;
}

/* Адаптивность для мобильных устройств */
@media (max-width: 768px) {
	
.pbl-sec {
    margin: 0;
    padding: 0;
    background: inherit;
    border-radius: 8px;
    border: 0 solid #e9ecef;
    display: flex;
		flex-direction: row;
		align-items: stretch;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 15px;
}
    
    .pbl-lbl {
        text-align: center;
        justify-content: center;
    }
    
    .pbl-act {
        justify-content: center;
				flex-wrap: wrap;
				width: 100%;
    }
    
    .url-copy-container {
        min-width: auto;
        max-width: 100%;
    }
    
    .url-input {
        font-size: 12px;
    }
    
    .pbl-itm {
        flex: 1;
        justify-content: center;
        min-width: 120px;
    }
}

@media (max-width: 480px) {
    .pbl-act {
        flex-direction: column;
        width: 100%;
    }
    
    .pbl-itm {
        width: 100%;
        justify-content: center;
    }
    
    .url-copy-container {
        flex-direction: column;
        gap: 8px;
    }
    
    .url-copy-btn {
        width: 100%;
        text-align: center;
    }
}

/* Анимация для иконок */
.pbl-itm i {
    transition: transform 0.3s ease;
}

.pbl-itm:hover i {
    transform: scale(1.1);
}

/* Состояние загрузки */
.pbl-itm.loading {
    opacity: 0.7;
    cursor: not-allowed;
}

.pbl-itm.loading i {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Стили для выпадающего меню "Поделиться" в списке статей */
.pbl-dd-cnt {
    position: relative;
    display: inline-block;
}

.pbl-dd-menu {
    position: absolute;
    bottom: 100%;
    left: var(--menu-left, 0);
    right: auto;
    background: #ffffff !important;
    min-width: 220px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    border-radius: 12px;
    padding: 12px;
    z-index: 100001 !important;
    display: none;
    border: 1px solid rgba(0, 0, 0, 0.08);
    margin-bottom: 12px;
    animation: shareDropdownFadeIn 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes shareDropdownFadeIn {
    from { opacity: 0; transform: translateY(10px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes shareDropdownFadeDown {
    from { opacity: 0; transform: translateY(-10px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.pbl-dd-menu.active {
    display: block;
    opacity: 1 !important;
}

.pbl-dd-menu.dropdown-bottom {
    bottom: auto;
    top: 100%;
    margin-bottom: 0;
    margin-top: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2), 0 5px 10px rgba(0, 0, 0, 0.1);
    animation: shareDropdownFadeDown 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.pbl-dd-cnt.menu-open,
.article-card.menu-open {
    z-index: 100 !important;
}

/* Треугольник-указатель */
.pbl-dd-menu::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: var(--arrow-x, 15px);
    width: 12px;
    height: 12px;
    background: #fff;
    transform: translateX(-50%) rotate(45deg);
    border-right: 1px solid #f0f0f0;
    border-bottom: 1px solid #f0f0f0;
}

.pbl-dd-menu.dropdown-bottom::after {
    bottom: auto;
    top: -6px;
    border-right: none;
    border-bottom: none;
    border-left: 1px solid #f0f0f0;
    border-top: 1px solid #f0f0f0;
}

.pbl-dd-soc {
    display: flex;
    justify-content: space-around;
    gap: 10px;
    margin-bottom: 12px;
}

.pbl-dd-itm {
    background: none;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

/* Иконки соцсетей в дропдауне */
.pbl-dd-soc .pbl-dd-itm {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    font-size: 18px;
    color: #6c757d;
    background: #f8f9fa;
}

.pbl-dd-soc .pbl-dd-itm:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.pbl-dd-itm.btn-tg:hover { background: #0088cc; color: #fff; }
.pbl-dd-itm.btn-wa:hover { background: #2de100; color: #fff; }
.pbl-dd-itm.btn-fb:hover { background: #1b00c9; color: #fff; }
.pbl-dd-itm.btn-ig:hover { background: #fb098e; color: #fff; }
.pbl-dd-itm.btn-tw:hover { background: #000000; color: #ffffff; }
.pbl-dd-itm.btn-vk:hover { background: #4c75a3; color: #fff; }
.pbl-dd-itm.mail-btn:hover { background: #4c75a3; color: #fff; }
.pbl-dd-itm.viber-btn:hover { background: #4c75a3; color: #fff; }

/* Текстовый fallback для X (Twitter), если иконка не загрузилась */
.twitter-x-text {
    font-size: 18px;
    font-weight: 800;
    font-family: 'Inter', 'Segoe UI', Arial, sans-serif;
    line-height: 1;
}

/* Если иконка отображается (есть ширина), можно скрыть текст или наоборот.
   Но так как мы не знаем наверняка, просто сделаем так, чтобы они не мешали друг другу. */
.pbl-dd-itm.btn-tw i:empty + .twitter-x-text {
    display: block;
}



.pbl-dd-sep {
    height: 1px;
    background: #f0f0f0;
    margin: 8px 0;
}

.copy-link-btn-dropdown {
    width: 100%;
    padding: 10px 12px;
    border-radius: 8px;
    gap: 10px;
    color: #495057;
    font-size: 14px;
    font-weight: 500;
    justify-content: flex-start !important;
}

.copy-link-btn-dropdown:hover {
    background: #f8f9fa;
    color: #2c3e50;
}

.copy-link-btn-dropdown i {
    font-size: 16px;
    color: #6c757d;
}

.copy-link-btn-dropdown.copied {
    background: #e8f5e9;
    color: #2e7d32;
}

.copy-link-btn-dropdown.copied i {
    color: #2e7d32;
}


/* --- File: bookmark-counter.css --- */
/* Стили для счетчика избранного */

.bookmark-counter {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.875rem;
    color: #6b7280;
    transition: all 0.3s ease;
}

.bookmark-counter-clickable {
    cursor: pointer;
    border-radius: 10px;
    padding: 6px 8px;
    transition: all 0.3s ease;
    background-color: #f3f4f6;
    font-size: 14px;
    position: relative; /* Для позиционирования tooltip */
}

.bookmark-counter-clickable:hover {
    background-color: #f59e0b;
    color: white;
}

.bookmark-counter i {
    font-size: 0.9rem;
    color: #f59e0b;
}

.bookmark-counter-clickable:hover i {
    color: white;
}

.bookmark-counter-text {
    font-weight: 500;
    min-width: 16px;
    text-align: center;
}

/* Интеграция со стилями кнопки избранного */
.bookmark-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 6px 10px;
    font-size: 16px;
    transition: all 0.2s ease;
    overflow: visible; /* Разрешаем tooltip выходить за границы кнопки */
}

.bookmark-btn i {
    font-size: 18px;
    transition: color 0.2s ease, transform 0.2s ease;
    color: #999;
}

.bookmark-btn:hover{
		background-color: hsla(0, 0%, 100%, 0);
		color: #ffffff;
} 

.bookmark-btn .bookmark-counter {
    font-size: 16px;
    font-weight: 600;
    color: #555;
    cursor: pointer;
    transition: all 0.2s ease;
    padding: 0;
    margin: 0;
    text-align: center;
}

.bookmark-btn .bookmark-counter-clickable {
    padding: 0;
    background-color: transparent;
    cursor: pointer;
    transition: all 0.2s ease;
}

.bookmark-btn .bookmark-counter-clickable:hover {
    color: #f59e0b;
}

/* При наведении на кнопку */
.bookmark-btn:hover i {
    color: #f59e0b;
}

.bookmark-btn:hover .bookmark-counter {
    color: #f59e0b;
}

/* Активное состояние - полностью оранжевая иконка (добавлено в избранное) */
.bookmark-btn.active i {
    color: #f59e0b;
    fill: #f59e0b;
}

.bookmark-btn.active .bookmark-counter {
    color: #f59e0b;
    font-weight: 700;
		font-size: 0.95rem;
}

/* Текст кнопки скрывается */
.bookmark-btn .bookmark-text {
    display: none;
}

/* КРАСИВОЕ МОДАЛЬНОЕ ОКНО ИЗБРАННОГО */
.bookmarks-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.6);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(4px);
}

.bookmarks-popup.active {
    display: flex;
    animation: fadeInOverlay 0.3s ease;
}

.action-group.bookmark-group > button.action-btn.bookmark-btn.with-padding {
    gap: 6px;
}

.action-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    /* padding: 4px 6px; */
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    background: #f9fafb;
    color: #6b7280;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    font-size: 14px;
}

.bookmark-btn.guest-btn {
    cursor: default;
}

.bookmark-btn.guest-btn .bookmark-counter-clickable {
    cursor: pointer;
}
.action-btn:hover {
    transform: translateY(0);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border-color: #d1d5db;
}

@keyframes fadeInOverlay {
    from { opacity: 0; }
    to { opacity: 1; }
}

.bookmarks-popup-content {
    background: linear-gradient(145deg, #ffffff 0%, #f8fafc 100%);
    border-radius: 20px;
    padding: 0;
    max-width: 650px;
    width: 95%;
    max-height: 85vh;
    overflow: hidden;
    box-shadow: 
        0 25px 50px rgba(0, 0, 0, 0.25),
        0 10px 25px rgba(0, 0, 0, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.6);
    position: relative;
    animation: popupSlideIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes popupSlideIn {
    from {
        opacity: 0;
        transform: scale(0.8) translateY(40px) rotateY(10deg);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0) rotateY(0deg);
    }
}

/* ЗАГОЛОВОК МОДАЛЬНОГО ОКНА */
.bookmarks-popup-header {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    padding: 20px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: none;
    position: relative;
}

.bookmarks-popup-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255,255,255,0.2) 0%, transparent 50%);
    pointer-events: none;
}

.bookmarks-popup-title {
    margin: 0;
    color: white;
    font-size: 1.4rem;
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    gap: 10px;
}

.bookmarks-popup-title::before {
    content: '⭐';
    font-size: 1.2em;
    animation: sparkle 2s ease-in-out infinite;
}

@keyframes sparkle {
    0%, 100% { transform: scale(1) rotate(0deg); }
    50% { transform: scale(1.2) rotate(5deg); }
}

.bookmarks-popup-close {
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.3);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.bookmarks-popup-close:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
    transform: rotate(90deg) scale(1.1);
}

/* СПИСОК ПОЛЬЗОВАТЕЛЕЙ */
.bookmarks-users-list {
    padding: 10px;
    display: flex;
    flex-direction: column;
    max-height: 60vh;
    overflow-y: auto;
}

.bookmarks-users-list::-webkit-scrollbar {
    width: 12px;
}

.bookmarks-users-list::-webkit-scrollbar-track {
    background: linear-gradient(180deg, #f1f5f9 0%, #e2e8f0 100%);
    border-radius: 10px;
    margin: 8px;
}

.bookmarks-users-list::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #f59e0b 0%, #d97706 100%);
    border-radius: 10px;
    border: 2px solid #f1f5f9;
    transition: all 0.3s ease;
}

.bookmarks-users-list::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #d97706 0%, #b45309 100%);
    transform: scale(1.1);
}

/* КАРТОЧКИ ПОЛЬЗОВАТЕЛЕЙ - КОМПАКТНЫЙ ВИД */
.bookmark-user-item {
    background: linear-gradient(145deg, #ffffff 0%, #f8fafc 100%);
    border-radius: 12px;
    padding: 12px 16px;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 12px;
    transition: all 0.3s ease;
    border: 1px solid #e5e7eb;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    margin-bottom: 8px;
}

/* Анимации удалены для более быстрого и компактного отображения */

/* АВАТАРЫ - КОМПАКТНЫЙ ВИД */
.bookmark-user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #f59e0b;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.bookmark-user-item:hover {
    background: linear-gradient(145deg, #fef3e2 0%, #fef9e7 100%);
    border-color: #f59e0b;
    box-shadow: 0 4px 8px rgba(245, 158, 11, 0.2);
    transform: translateY(-1px);
}

.bookmark-user-item:hover .bookmark-user-avatar {
    border-color: #d97706;
    transform: scale(1.05);
}

/* ИНФОРМАЦИЯ О ПОЛЬЗОВАТЕЛE - КОМПАКТНЫЙ ВИД */
.bookmark-user-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.bookmark-user-name {
    font-weight: 700;
    color: #1f2937;
    margin: 0 0 4px 0;
    font-size: 1rem;
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.bookmark-user-nickname {
    color: #374151;
    font-size: 0.9rem;
    margin: 0;
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-decoration: none;
}

.bookmark-user-nickname:hover {
    color: #f59e0b;
    text-decoration: underline;
}

.bookmark-user-date {
    font-size: 0.75rem;
    color: #6b7280;
    display: flex;
    align-items: center;
    gap: 4px;
    font-weight: 400;
}

.bookmark-user-date i {
    color: #f59e0b;
    font-size: 0.7rem;
}

/* СОСТОЯНИЕ БЕЗ ДАННЫХ */
.no-bookmarks {
    text-align: center;
    padding: 60px 30px;
    background: linear-gradient(145deg, #f8fafc 0%, #e2e8f0 100%);
    border-radius: 16px;
    margin: 20px;
}

.no-bookmarks i {
    font-size: 4rem;
    background: linear-gradient(45deg, #f59e0b, #d97706);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 20px;
    display: block;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.no-bookmarks h4 {
    margin: 0 0 12px 0;
    color: #374151;
    font-size: 1.25rem;
    font-weight: 700;
}

.no-bookmarks p {
    margin: 0;
    font-size: 1rem;
    color: #6b7280;
    font-weight: 500;
}

/* АДАПТИВНОСТЬ */
@media (max-width: 768px) {

    .bookmark-user-item {
            margin-bottom: 4px;
        }

    .bookmarks-popup-content {
        margin: 15px;
        border-radius: 16px;
        max-width: calc(100vw - 30px);
    }
    
    .bookmarks-popup-header {
        padding: 16px 20px;
    }
    
    .bookmarks-popup-title {
        font-size: 1.2rem;
    }
    
    .bookmarks-users-list {
        padding: 10px;
        gap: 5px;
        justify-content: center;
    }
    
    .bookmark-user-item {
        padding: 8px;
    }
    
    .bookmark-user-avatar {
        width: 50px;
        height: 50px;
    }
    
    .bookmark-user-name {
        font-size: 0.9rem;
    }
    
    .bookmark-user-nickname {
        font-size: 0.8rem;
    }
    
    .bookmark-user-date {
        font-size: 0.7rem;
    }
}

@media (max-width: 480px) {
    .bookmarks-popup-content {
        margin: 10px;
        max-width: calc(100vw - 20px);
    }
    
    .bookmarks-users-list {
        padding: 5px;
        gap: 0;
    }
    
    .bookmark-user-item {
        padding: 8px;
    }
    
    .bookmark-user-avatar {
        width: 45px;
        height: 45px;
    }
}

/* Анимации загрузки */
.bookmark-counter.loading {
    opacity: 0.6;
    pointer-events: none;
}

.bookmark-counter.loading::after {
    content: '';
    width: 12px;
    height: 12px;
    border: 2px solid #f59e0b;
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: bookmarkSpin 0.8s linear infinite;
    margin-left: 4px;
}

@keyframes bookmarkSpin {
    to {
        transform: rotate(360deg);
    }
}

/* Интеграция в карточки статей */
.article-card .bookmark-counter,
.article-item .bookmark-counter,
.stats-item .bookmark-counter {
    font-size: 0.875rem;
}

.article-stats .bookmark-counter {
    color: #f59e0b;
    font-weight: 500;
}

/* Стили для мини-счетчика */
.bookmark-counter-mini {
    font-size: 0.75rem;
    padding: 1px 4px;
}

.bookmark-counter-mini i {
    font-size: 0.75rem;
}

/* Успешное обновление */
.bookmark-counter-updated {
    animation: bookmarkPulse 0.5s ease;
}

@keyframes bookmarkPulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

/* Стили для списка в админ-панели */
.admin-bookmarks-stats .bookmark-counter {
    background: #f8fafc;
    padding: 4px 8px;
    border-radius: 6px;
    border: 1px solid #e5e7eb;
}




/* --- File: reading-stats.css --- */
/* ================================
   СТИЛИ ДЛЯ СТАТИСТИКИ ЧТЕНИЯ
   ================================ */

.article-meta-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin: 10px 0 20px;
    padding: 10px;
    background-color: #f8f9fa;
    border-left: 0 solid #3498db;
    border-radius: 8px;
    align-items: center;
}

.article-meta-stats span {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 15px;
    color: #555;
    position: relative;
    cursor: help;
    transition: all 0.2s ease;
}

/* Глобальный тултип (универсальный) */
.global-site-tooltip {
    position: fixed;
    z-index: 1100;
    background-color: #2c3e50;
    color: white;
    padding: 8px 14px;
    border-radius: 6px;
    font-size: 13px;
    white-space: nowrap;
    pointer-events: none;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
}

.global-site-tooltip.active {
    opacity: 0.95;
    visibility: visible;
}

/* Стрелка тултипа */
.global-site-tooltip::after {
    content: '';
    position: absolute;
    left: var(--arrow-x, 50%);
    border: 6px solid transparent;
    transform: translateX(-50%);
}

/* Стрелка снизу (тултип сверху) */
.global-site-tooltip[data-position="top"]::after {
    top: 100%;
    border-top-color: #2c3e50;
}

/* Стрелка сверху (тултип снизу) */
.global-site-tooltip[data-position="bottom"]::after {
    bottom: 100%;
    border-bottom-color: #2c3e50;
}

.article-meta-stats i {
    color: #3498db;
    min-width: 16px;
    text-align: center;
}

.views-count, .word-count, .character-count, .digit-count, .number-count, .punctuation-count {
    font-weight: 500;
}

.views-count strong, .word-count strong, .character-count strong, .digit-count strong, .number-count strong, .punctuation-count strong {
    color: #2c3e50;
    font-weight: 600;
}

.reading-time {
    background-color: white;
    padding: 8px 12px;
    border-radius: 3px;
    border-left: 3px solid #2ecc71;
}

.reading-time strong {
    color: #2ecc71;
    font-weight: 600;
    font-size: 16px;
}

.reading-sessions {
    background-color: white;
    padding: 8px 12px;
    border-radius: 3px;
    border-left: 3px solid #9b59b6;
}

.reading-sessions strong {
    color: #9b59b6;
    font-weight: 600;
}

/* Адаптивность для мобильных */
@media (max-width: 768px) {
    .article-meta-stats {
        display: none;
    }
}

@media (max-width: 480px) {
    .mobile-meta-buttons-container {
        display: flex !important;
        gap: 8px;
        margin: 10px 0 12px 0;
        flex-wrap: wrap;
    }
    
    .meta-toggle-btn, .stats-modal-trigger-btn {
        display: flex !important;
        align-items: center;
        justify-content: center;
        gap: 6px;
        flex: 1;
        min-width: 120px;
        padding: 8px 12px;
        background: #f3f4f6;
        border: 1px solid #e5e7eb;
        border-radius: 8px;
        font-size: 13px;
        font-weight: 600;
        color: #374151;
        cursor: pointer;
        transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    }

    .meta-toggle-btn:active, .stats-modal-trigger-btn:active {
        transform: scale(0.96);
        background: #e5e7eb;
    }

    .stats-modal-trigger-btn {
        background: #eff6ff;
        border-color: #dbeafe;
        color: #2563eb;
    }

    .stats-modal-trigger-btn i {
        color: #2563eb !important;
    }

    .stats-modal-trigger-btn:active {
        background: #dbeafe;
    }
}

/* МОДАЛЬНОЕ ОКНО */
.stats-modal-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 2000;
}

.stats-modal-overlay.active {
    display: flex;
    align-items: flex-end;
    justify-content: center;
}

.stats-modal {
    background-color: white;
    width: 100%;
    border-radius: 12px 12px 0 0;
    padding: 20px;
    max-height: 80vh;
    overflow-y: auto;
    animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
    from { transform: translateY(100%); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.stats-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.stats-modal-title {
    margin: 0;
    font-size: 1.25rem;
    color: #2c3e50;
    font-weight: 700;
}

.stats-modal-close {
    background: #f3f4f6;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #4b5563;
    transition: all 0.2s ease;
}

.stats-modal-close:hover {
    background: #e5e7eb;
    color: #111827;
}

.stats-modal-item {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 12px 0;
    border-bottom: 1px solid #f9fafb;
}

.stats-modal-item:last-child {
    border-bottom: none;
}

.stats-modal-item-label {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.stats-modal-item-label i {
    font-size: 1.1rem;
    color: #3498db;
    margin-top: 3px;
    min-width: 24px;
    text-align: center;
}

.stats-modal-item-label span {
    display: block;
    color: #374151;
    font-weight: 600;
}

.stats-modal-item-description {
    display: block;
    font-size: 0.8rem;
    color: #6b7280;
    font-weight: normal !important;
    margin-top: 2px;
}

.stats-modal-item-value {
    font-weight: 700;
    color: #111827;
    font-size: 1rem;
    text-align: right;
    padding-left: 15px;
}

/* Специальные стили для времени чтения и сессий в модале */
.stats-modal-item.reading-time {
    border-left: 4px solid #2ecc71;
    padding-left: 10px;
    background: #f0fff4;
    margin: 5px -10px;
    padding-right: 10px;
}

.stats-modal-item.reading-time .stats-modal-item-label i {
    color: #2ecc71;
}

.stats-modal-item.reading-time .stats-modal-item-value {
    color: #2ecc71;
}

.stats-modal-item.reading-sessions {
    border-left: 4px solid #9b59b6;
    padding-left: 10px;
    background: #faf5ff;
    margin: 5px -10px;
    padding-right: 10px;
}

.stats-modal-item.reading-sessions .stats-modal-item-label i {
    color: #9b59b6;
}

.stats-modal-item.reading-sessions .stats-modal-item-value {
    color: #9b59b6;
}


/* --- File: report-modal.css --- */
/* Специфические стили для модального окна жалобы на статью */

.report-modal {
    display: none;
    position: fixed;
    z-index: 3000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    align-items: center;
    justify-content: center;
    overflow-y: auto;
    padding: 20px;
}

.report-modal-content {
    background-color: #ffffff;
    border-radius: 12px;
    width: 100%;
    max-width: 500px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    animation: report-modal-fade-in 0.3s ease-out;
    position: relative;
    margin: auto;
}

@keyframes report-modal-fade-in {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.report-modal-header {
    padding: 20px 24px;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.report-modal-header h3 {
    margin: 0;
    font-size: 1.25rem;
    color: #1a1a1a;
    font-weight: 600;
}

.report-modal-close {
    font-size: 28px;
    font-weight: bold;
    color: #999;
    cursor: pointer;
    line-height: 1;
    transition: color 0.2s;
    background: none;
    border: none;
    padding: 5px;
}

.report-modal-close:hover {
    color: #333;
}

.report-modal-body {
    padding: 24px;
}

.report-modal .form-group {
    margin-bottom: 20px;
}

.report-modal .form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #4a4a4a;
    font-size: 0.95rem;
}

.report-modal select,
.report-modal textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.report-modal select:focus,
.report-modal textarea:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.report-modal textarea {
    resize: vertical;
    min-height: 120px;
}

.report-modal .char-counter {
    display: block;
    margin-top: 6px;
    font-size: 0.85rem;
    text-align: right;
    color: #666;
}

.report-modal .form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 8px;
}

.report-modal .button-primary,
.report-modal .button-secondary {
    padding: 10px 20px;
    border-radius: 4px;
    font-weight: 500;
    cursor: pointer;
    transition: filter 0.2s;
}

@media (max-width: 480px) {
    .report-modal {
        padding: 0;
    }
    
    .report-modal-content {
        max-width: 100%;
    }
    
    .report-modal-header {
        padding: 16px 20px;
    }
    
    .report-modal-body {
        padding: 20px;
    }
    
    .report-modal .form-actions {
        flex-direction: column-reverse;
    }
    
    .report-modal .form-actions button {
        width: 100%;
    }
}


/* --- File: wiki-interface.css --- */
/**
 * Стили для Wiki интерфейса
 * Совместное редактирование статей
 */

/* Основной контейнер Wiki интерфейса */
.wiki-interface {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 10;
    border-radius: 0;
}

.wiki-status-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 10px;
		gap: 5px;
    background: rgba(0, 0, 0, 0.25);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    flex-wrap: wrap;
    transition: background 0.3s ease;
}

.wiki-status-bar:hover {
    background: rgba(0, 0, 0, 0.35);
}

.wiki-info {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.wiki-label {
    font-weight: 700;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: rgba(255, 255, 255, 0.15);
    padding: 4px 10px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.wiki-stat {
    display: flex;
    align-items: center;
    gap: 6px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 13px;
    font-weight: 500;
}

.wiki-stat i {
    font-size: 12px;
    opacity: 0.9;
}

.wiki-actions {
    display: flex;
    gap: 10px;
    /* flex-wrap: wrap; */
}

/* Кнопки Wiki */
.wiki-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.15);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
}

.wiki-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    color: white;
    text-decoration: none;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.wiki-btn:active {
    transform: translateY(0);
}

.wiki-btn-edit {
    background: rgba(149, 165, 166, 0.3);
    border-color: rgba(149, 165, 166, 0.5);
}

.wiki-btn-edit:hover {
    background: rgba(149, 165, 166, 0.5);
}

.wiki-btn-history {
    background: rgba(52, 152, 219, 0.3);
    border-color: rgba(52, 152, 219, 0.5);
}

.wiki-btn-history:hover {
    background: rgba(52, 152, 219, 0.5);
}

.wiki-btn-settings {
    background: rgba(149, 165, 166, 0.3);
    border-color: rgba(149, 165, 166, 0.5);
}

.wiki-btn-settings:hover {
    background: rgba(149, 165, 166, 0.5);
}

/* Модальные окна Wiki */
.wiki-modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    animation: fadeIn 0.3s ease;
}

.wiki-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.wiki-modal-content {
    background: white;
    border-radius: 12px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    animation: slideIn 0.3s ease;
}

.wiki-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 15px;
    border-bottom: 1px solid #e1e8ed;
}

.wiki-modal-title {
    margin: 0;
    color: #2c3e50;
    font-size: 1.2rem;
}

.wiki-modal-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #7f8c8d;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.2s;
}

.wiki-modal-close:hover {
    background-color: #f8f9fa;
}

.wiki-modal-body {
    padding: 15px;
}

/* Стили для управления соавторами */
.collaborators-section {
    margin-bottom: 30px;
}

.collaborators-section h4 {
    color: #2c3e50;
    margin-bottom: 15px;
    font-size: 1.1rem;
}

.collaborators-list {
    border: 1px solid #e1e8ed;
    border-radius: 8px;
    max-height: 200px;
    overflow-y: auto;
}

.collaborator-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    border-bottom: 1px solid #f1f2f6;
}

.collaborator-item:last-child {
    border-bottom: none;
}

.collaborator-info {
    flex: 1;
}

.collaborator-info strong {
    display: block;
    color: #2c3e50;
    margin-bottom: 5px;
}

.permission-level {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: bold;
    margin-right: 10px;
}

.permission-level.viewer {
    background: #e3f2fd;
    color: #1976d2;
}

.permission-level.editor {
    background: #e8f5e8;
    color: #388e3c;
}

.permission-level.admin {
    background: #fff3e0;
    color: #f57c00;
}

.collaborator-info small {
    color: #7f8c8d;
    font-size: 11px;
}

.no-collaborators {
    text-align: center;
    color: #7f8c8d;
    padding: 30px;
    font-style: italic;
}

.add-collaborator-section {
    border-top: 1px solid #e1e8ed;
    padding-top: 20px;
}

.add-collaborator-section h4 {
    color: #2c3e50;
    margin-bottom: 15px;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    color: #2c3e50;
    font-weight: 500;
}

.form-control {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #dce7ed;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.2s;
}

.form-control:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.1);
}

.btn {
    padding: 8px 16px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.btn-primary {
    background: #3498db;
    color: white;
}

.btn-primary:hover {
    background: #2980b9;
}

.btn-sm {
    padding: 5px 10px;
    font-size: 12px;
}

.btn-outline-danger {
    background: transparent;
    color: #e74c3c;
    border: 1px solid #e74c3c;
}

.btn-outline-danger:hover {
    background: #e74c3c;
    color: white;
}

/* Wiki Editor */
.wiki-editor {
    width: 100%;
}

.wiki-editor-toolbar {
    display: flex;
    gap: 5px;
    padding: 10px;
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-bottom: none;
    border-radius: 6px 6px 0 0;
    flex-wrap: wrap;
}

.wiki-toolbar-btn {
    padding: 6px 10px;
    background: white;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.2s ease;
}

.wiki-toolbar-btn:hover {
    background: #e9ecef;
    border-color: #adb5bd;
}

.wiki-editor-textarea {
    width: 100%;
    min-height: 400px;
    padding: 15px;
    border: 1px solid #dee2e6;
    border-radius: 0 0 6px 6px;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 14px;
    line-height: 1.6;
    resize: vertical;
    box-sizing: border-box;
}

.wiki-editor-textarea:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.2);
}

.wiki-editor-footer {
		display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    border-top: 1px solid #dee2e6;
    margin-top: 20px;
    flex-wrap: wrap;
}

.wiki-summary-group {
    flex: 1;
    margin-right: 20px;
}

.wiki-summary-input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    font-size: 14px;
}

.wiki-editor-actions {
    display: flex;
    gap: 10px;
}

.wiki-save-btn {
    background: #28a745;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s ease;
}

.wiki-save-btn:hover {
    background: #218838;
		color: #ffffff;
}

.wiki-cancel-btn {
    background: #6c757d;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s ease;
}

.wiki-cancel-btn:hover {
    background: #5a6268;
		color: #ffffff;
}

/* Wiki History */
.wiki-history-list {
    max-height: 60vh;
    overflow-y: auto;
}

/* Кнопка закрытия только окна ревизии (не истории) */
.wiki-revision-close-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 28px;
    color: #999;
    cursor: pointer;
    line-height: 1;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s;
}

.wiki-revision-close-btn:hover {
    color: #333;
}

.wiki-revision-item {
    display: flex;
    align-items: center;
    padding: 15px;
    border-bottom: 1px solid #e9ecef;
    transition: background 0.2s ease;
}

.wiki-revision-item:hover {
    background: #f8f9fa;
}

.wiki-revision-info {
    flex: 1;
}

.wiki-revision-meta {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 5px;
}

.wiki-revision-number {
    background: #667eea;
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.wiki-revision-author {
    font-weight: 500;
    color: #495057;
}

.wiki-revision-date {
    color: #6c757d;
    font-size: 13px;
}

.wiki-revision-summary {
    color: #6c757d;
    font-size: 14px;
    font-style: italic;
}

.wiki-revision-actions {
    display: flex;
    gap: 8px;
}

.wiki-revision-btn {
    padding: 4px 8px;
    border: 1px solid #dee2e6;
    background: white;
    border-radius: 4px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    color: #28a745;
}

.wiki-revision-btn:hover {
    background: #f8f9fa;
    border-color: #adb5bd;
    color: #037c1e;
}

.wiki-revision-btn.view {
    color: #17a2b8;
    border-color: #17a2b8;
}

.wiki-revision-btn.revert {
    color: #dc3545;
    border-color: #dc3545;
}

/* ===== DIFF VIEWER ===== */
.wiki-diff-modal { max-width: 960px; width: 95%; }
.diff-mode-switch { display:flex; gap:8px; margin-bottom:15px; }
.diff-mode-btn { padding:6px 12px; border:1px solid #d0d7de; background:#3498db; border-radius:4px; cursor:pointer; font-size:13px; }
.diff-mode-btn.active { background:#0366d6; color:#fff; border-color:#0366d6; }
.wiki-diff-container { font-family:monospace; font-size:13px; line-height:1.4; max-height:60vh; overflow:auto; border:1px solid #e1e4e8; background:#fff; }
.diff-line { padding:2px 8px; white-space:pre-wrap; }
.diff-line.diff-added { background:#e6ffed; color:#22863a; }
.diff-line.diff-removed { background:#ffeef0; color:#cb2431; }
.diff-line.diff-unchanged { background:#fff; color:#24292e; }
.diff-title-change { background:#fff8c5; border:1px solid #e1e4e8; padding:8px 10px; border-radius:6px; margin-bottom:12px; font-family:system-ui,sans-serif; }
.diff-title-change .old { text-decoration:line-through; color:#cb2431; }
.diff-title-change .new { color:#22863a; font-weight:600; }
/* Side-by-side */
.diff-table { width:100%; border-collapse:collapse; font-family:monospace; }
.diff-table td { vertical-align:top; padding:2px 6px; border-right:1px solid #e1e4e8; }
.diff-table td.old-num, .diff-table td.new-num { width:50px; background:#f6f8fa; color:#6a737d; text-align:right; font-size:12px; }
.diff-table tr.diff-added td.new { background:#e6ffed; }
.diff-table tr.diff-removed td.old { background:#ffeef0; }
.diff-table tr.diff-unchanged td { background:#fff; }
.wiki-diff-container.diff-mode-side { padding:0; }
.wiki-empty-diff { padding:15px; text-align:center; color:#6a737d; }
/* Scrollbar minor tweak */
.wiki-diff-container::-webkit-scrollbar { width:10px; }
.wiki-diff-container::-webkit-scrollbar-thumb { background:#c4cdda; border-radius:5px; }

/* Предупреждения и уведомления */
.wiki-warning {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
    padding: 12px 15px;
    border-radius: 6px;
    margin: 15px 0;
}

.wiki-info {
    color: inherit;
    padding: 0;
    margin: 0;
    background: none;
}

.wiki-success {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
    padding: 12px 15px;
    border-radius: 6px;
    margin: 15px 0;
}

/* Блокировка редактирования */
.wiki-edit-lock {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
    padding: 15px;
    border-radius: 6px;
    margin: 15px 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.wiki-edit-lock i {
    font-size: 18px;
}

/* Базовая раскладка статистики */
.wiki-stats { display: flex; flex-wrap: wrap; gap: 8px; }

/* Мобильный блок статистики — скрыт по умолчанию */
.wiki-stats-mobile { display: none; position: relative; }

/* Кнопка-контейнер для мобильной статистики (использует логику date-tooltip) */
.wiki-stats-mobile-container {
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.25) !important;
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    justify-content: center;
    transition: all 0.2s ease;
}

.wiki-stats-mobile-container:hover {
    background: rgba(255, 255, 255, 0.3);
}

.wiki-stats-mobile-container i.fa-info-circle {
    font-size: 15px;
}

/* Адаптив: компактный режим для мобильных */
@media (max-width: 768px) {
    .wiki-interface { margin: 0; border-radius: 10px; }
    .wiki-status-bar {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        gap: 6px;
        padding: 6px 10px;
    }
    .wiki-info { flex-direction: row; align-items: center; gap: 6px; flex-wrap: nowrap; }
    .wiki-label { font-size: 12px; margin-left: 0; padding: 3px 8px; }

    /* Скрываем десктопную статистику, показываем мобильную кнопку */
    .wiki-stats-desktop { display: none !important; }
    .wiki-stats-mobile { display: block; }

    .wiki-actions { gap: 6px; }
    .wiki-btn { padding: 6px 8px; font-size: 12px; border-radius: 6px; }
    .wiki-btn .wiki-btn-label { display: none; }
    .wiki-btn i { font-size: 14px; }
}

@media (max-width: 480px) {
    .wiki-status-bar { padding: 5px 8px; }
    .wiki-btn { padding: 6px; }
    .wiki-btn i { font-size: 15px; }
}

/* Ultra-compact mobile cleanup */
@media (max-width: 640px) {
    .wiki-interface { background: none !important; box-shadow: none !important; margin: 0; border-radius: 8px; overflow: visible; }
}

/* Анимации */
@keyframes wiki-slide-in {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.wiki-interface {
    animation: wiki-slide-in 0.3s ease-out;
}

.wiki-revision-item {
    opacity: 0;
    animation: wiki-slide-in 0.3s ease-out forwards;
}

.wiki-revision-item:nth-child(1) { animation-delay: 0.1s; }
.wiki-revision-item:nth-child(2) { animation-delay: 0.2s; }
.wiki-revision-item:nth-child(3) { animation-delay: 0.3s; }
.wiki-revision-item:nth-child(4) { animation-delay: 0.4s; }
.wiki-revision-item:nth-child(5) { animation-delay: 0.5s; }

/* Стили для управления соавторами */
.add-collaborator-tabs {
    display: flex;
    border-bottom: 1px solid #dee2e6;
    margin-bottom: 20px;
}

.tab-btn {
    background: none;
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    transition: all 0.3s ease;
    color: #6c757d;
}

.tab-btn.active {
    color: #3498db;
    border-bottom-color: #3498db;
}

.tab-btn:hover {
    background-color: #f8f9fa;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.available-users-list, .available-groups-list {
    max-height: 300px;
    overflow-y: auto;
    border: 1px solid #dee2e6;
    border-radius: 5px;
}

.available-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    border-bottom: 1px solid #f1f3f4;
    transition: background-color 0.2s ease;
}

.available-item:hover {
    background-color: #f8f9fa;
}

.available-item:last-child {
    border-bottom: none;
}

.user-info, .group-info {
    flex: 1;
}

.user-info strong, .group-info strong {
    display: block;
    color: #495057;
    margin-bottom: 4px;
}

.user-info small, .group-info small {
    color: #6c757d;
    font-size: 12px;
}

.add-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}

.add-controls select {
    min-width: 120px;
    padding: 5px 8px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    font-size: 12px;
}

.collaborator-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    border: 1px solid #dee2e6;
    border-radius: 5px;
    margin-bottom: 10px;
    background-color: #fff;
    transition: box-shadow 0.2s ease;
}

.collaborator-item:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.collaborator-info {
    flex: 1;
}


/* Стили для помощи по ролям */
.wiki-roles-help {
    margin-bottom: 20px;
    background: #f8fbff;
    border: 1px solid #d0e3ff;
    border-radius: 8px;
    overflow: hidden;
}

.wiki-roles-help details {
    padding: 0;
}

.wiki-roles-help summary {
    padding: 10px 15px;
    cursor: pointer;
    font-weight: 600;
    color: #3498db;
    list-style: none;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: background 0.2s;
}

.wiki-roles-help summary:hover {
    background: #edf5ff;
}

.wiki-roles-help summary::-webkit-details-marker {
    display: none;
}

.roles-help-content {
    padding: 15px;
    border-top: 1px solid #d0e3ff;
    font-size: 13px;
    line-height: 1.6;
    color: #444;
}

.roles-help-content p {
    margin-bottom: 8px;
}

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

.roles-help-content i {
    width: 18px;
    text-align: center;
    color: #3498db;
}

/* Управление ролями в списке */
.collaborator-role-control {
    margin: 8px 0;
}

.collaborator-role-select {
    width: auto !important;
    display: inline-block !important;
    height: 32px !important;
    padding: 4px 8px !important;
    font-size: 13px !important;
    border-color: #dce7ed !important;
    background-color: #fff !important;
    cursor: pointer;
}

.collaborator-role-select:hover {
    border-color: #3498db !important;
}

.user-group-tag {
    font-weight: 500;
    color: #7f8c8d;
    font-size: 12px;
    margin-left: 4px;
}

.permission-level {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 500;
    text-transform: uppercase;
    margin-bottom: 5px;
}

.permission-level.view {
    background-color: #d1ecf1;
    color: #0c5460;
}

.permission-level.edit {
    background-color: #d4edda;
    color: #155724;
}

.permission-level.admin {
    background-color: #f8d7da;
    color: #721c24;
}

.collaborator-info small {
    color: #6c757d;
    font-size: 12px;
}

.collaborator-actions {
    display: flex;
    gap: 8px;
}

.no-collaborators {
    text-align: center;
    color: #6c757d;
    font-style: italic;
    padding: 20px;
    margin: 0;
}

/* Анимации */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from { 
        opacity: 0;
        transform: translateY(-20px);
    }
    to { 
        opacity: 1;
        transform: translateY(0);
    }
}

/* === Diff & Comparison Styles === */
.wiki-compare-panel {margin-bottom:15px;padding:10px;background:#f1f5f9;border:1px solid #dce3ea;border-radius:6px;display:flex;flex-wrap:wrap;align-items:center;gap:12px;justify-content:space-between;font-size:13px;}
.wiki-compare-panel .compare-actions {display:flex;flex-wrap:wrap;gap:8px;align-items:center;}
.wiki-compare-panel select {padding:4px 8px;font-size:13px;}
.wiki-compare-panel label {display:flex;align-items:center;gap:4px;cursor:pointer;font-weight:500;color:#34495e;}
.wiki-compare-panel .wiki-revision-btn.compare-run {background:#2563eb;color:#fff;border:none;}
.wiki-compare-panel .wiki-revision-btn.compare-run:disabled {background:#94a3b8;cursor:not-allowed;}

.wiki-revision-item {position:relative;}
.wiki-revision-select {margin-right:10px;}
.wiki-revision-item .wiki-compare-checkbox {width:16px;height:16px;cursor:pointer;}

/* Diff Modal */
#wiki-diff-modal .wiki-modal-content {max-width:1000px;width:95%;}
.wiki-diff-meta {display:flex;flex-direction:column;gap:4px;margin-bottom:12px;font-size:13px;color:#475569;}
.wiki-diff-meta .diff-label-old {color:#dc2626;font-weight:600;}
.wiki-diff-meta .diff-label-new {color:#16a34a;font-weight:600;}
.wiki-diff-meta .diff-mode-indicator {font-style:italic;color:#64748b;}

/* Unified view */
.wiki-diff-unified {font-family:Menlo,Consolas,monospace;font-size:13px;line-height:1.45;border:1px solid #e2e8f0;background:#fff;border-radius:6px;overflow:auto;max-height:70vh;padding:8px;}
.wiki-diff-line {padding:2px 6px;border-left:4px solid transparent;white-space:pre-wrap;word-break:break-word;}
.wiki-diff-line.diff-added {background:#f0fdf4;border-color:#16a34a;}
.wiki-diff-line.diff-removed {background:#fef2f2;border-color:#dc2626;}
.wiki-diff-line.diff-changed {background:#fff7ed;border-color:#f59e0b;}
.wiki-diff-line.diff-unchanged {color:#64748b;opacity:.65;}

/* Side-by-side */
.wiki-diff-side {display:flex;flex-direction:column;gap:0;border:1px solid #e2e8f0;border-radius:6px;overflow:auto;max-height:70vh;}
.wiki-diff-row {display:grid;grid-template-columns:1fr 1fr;font-family:Menlo,Consolas,monospace;font-size:13px;line-height:1.45;border-bottom: 1px solid #f1f5f9;}
.wiki-diff-row:nth-child(odd) {background:#f8fafc;}
.wiki-diff-row.diff-added {background:#f0fdf4;}
.wiki-diff-row.diff-removed {background:#fef2f2;}
.wiki-diff-row.diff-changed {background:#fff7ed;}

.diff-col {padding:4px 8px;border-left:4px solid transparent;white-space:pre-wrap;word-break:break-word;min-height: 1.5em;}
.wiki-diff-row.diff-added .diff-new {border-color:#16a34a; background: #e6ffed;}
.wiki-diff-row.diff-removed .diff-old {border-color:#dc2626; background: #ffeef0;}

.wiki-diff-row.diff-changed .diff-old {border-color:#dc2626; background: #ffeef0;}
.wiki-diff-row.diff-changed .diff-new {border-color:#16a34a; background: #e6ffed;}

.wiki-diff-row.diff-unchanged .diff-col { opacity: 0.8; }

/* Inline char diff */
.diff-char-added {background:#bbf7d0;color:#065f46;border-radius:2px;padding:0 1px;}
.diff-char-removed {background:#fecaca;color:#7f1d1d;border-radius:2px;padding:0 1px;}
.inline-old, .inline-new {display:block;}
.inline-old {color:#b91c1c;}
.inline-new {color:#065f46;}

/* Empty diff */
.wiki-empty-diff {padding:20px;text-align:center;color:#64748b;background:#f8fafc;border:1px dashed #cbd5e1;border-radius:6px;}

/* Fold indicator could be added later */

/* Footer buttons */
#wiki-diff-modal .wiki-modal-footer {display:flex;gap:10px;flex-wrap:wrap;justify-content:flex-end;margin: 15px;}
#wiki-diff-modal .wiki-modal-footer .wiki-revision-btn {background:#475569;color:#fff;}
#wiki-diff-modal .wiki-modal-footer .wiki-revision-btn:hover {background:#1e293b;}

.wiki-status.active{
    margin-bottom: 15px;
}

/* Стили для diff в просмотре ревизии */
.wiki-revision-diff-info {
    background: #e3f2fd;
    border: 1px solid #2196f3;
    border-radius: 4px;
    padding: 8px 12px;
    margin: 10px 0;
    font-size: 14px;
    color: #0d47a1;
}

.wiki-revision-diff-info i {
    margin-right: 8px;
}

.wiki-revision-diff {
    font-family: 'Courier New', monospace;
    font-size: 13px;
    line-height: 1.4;
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 4px;
    padding: 10px;
    max-height: 400px;
    overflow: auto;
    white-space: pre-wrap;
}

.wiki-diff-line {
    margin: 2px 0;
    padding: 2px 0;
}

.wiki-diff-line.diff-added {
    background: #d4edda;
    border-left: 4px solid #28a745;
}

.wiki-diff-line.diff-removed {
    background: #f8d7da;
    border-left: 4px solid #dc3545;
}

.wiki-diff-line.diff-changed {
    background: #fff3cd;
    border-left: 4px solid #ffc107;
}

.wiki-diff-line.diff-unchanged {
    background: transparent;
}

.diff-added-line {
    color: #155724;
}

.diff-removed-line {
    color: #721c24;
}

.diff-changed-line {
    color: #856404;
}

.diff-marker {
    font-weight: bold;
    margin-right: 8px;
}

.diff-char-added {
    background: #d4edda;
    color: #155724;
    padding: 1px 2px;
    border-radius: 2px;
}

.diff-char-removed {
    background: #f8d7da;
    color: #721c24;
    padding: 1px 2px;
    border-radius: 2px;
}

.wiki-stats {
    display: flex;
}


/**/
/* Стили для уведомлений о конфликте редактирования */

/* === AJAX User Search Styles === */
.user-search-container {
    margin-bottom: 20px;
    background: #fff;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    padding: 15px;
}

.search-input-container {
    position: relative;
    margin-bottom: 10px;
}

.search-input {
    width: 100%;
    padding: 12px 40px 12px 12px;
    border: 2px solid #e9ecef;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.3s ease;
    background: #fff;
    box-sizing: border-box;
}

.search-input:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.search-icon {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #6c757d;
    font-size: 14px;
}

.search-results {
    max-height: 300px;
    overflow-y: auto;
    border-radius: 6px;
}

.search-result-item {
    display: flex;
    align-items: center;
    padding: 12px;
    border: 1px solid #e9ecef;
    margin-bottom: 8px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    background: #fff;
}

.search-result-item:hover {
    background: #f8f9fa;
    border-color: #3498db;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 123, 255, 0.15);
}

.search-result-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    margin-right: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #e9ecef;
    color: #6c757d;
    font-size: 20px;
}

.search-result-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.search-result-info {
    flex: 1;
}

.search-result-name {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 4px;
}

.search-result-name mark {
    background: #fff3cd;
    color: #856404;
    padding: 1px 3px;
    border-radius: 3px;
}

.search-result-email {
    font-size: 12px;
    color: #6c757d;
}

.search-result-action {
    color: #28a745;
    font-size: 18px;
    margin-left: 12px;
}

.search-loading {
    padding: 20px;
    text-align: center;
    color: #6c757d;
    font-style: italic;
}

.search-loading i {
    margin-right: 8px;
}

.search-no-results {
    padding: 20px;
    text-align: center;
    color: #6c757d;
    font-style: italic;
}

.search-no-results i {
    margin-right: 8px;
    font-size: 18px;
}

.search-error {
    padding: 15px;
    background: #f8d7da;
    color: #721c24;
    border-radius: 6px;
    text-align: center;
}

.search-error i {
    margin-right: 8px;
}

.wiki-stats {
    display: flex;
}

/* === AJAX User Search Interface Styles === */
.user-search-container {
    margin-bottom: 20px;
    background: #fff;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    padding: 15px;
}

.search-input-container {
    position: relative;
    margin-bottom: 10px;
}

.search-input {
    width: 100%;
    padding: 12px 40px 12px 12px;
    border: 2px solid #e9ecef;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.3s ease;
    background: #fff;
}

.search-input:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.search-icon {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #6c757d;
    font-size: 14px;
}

.search-loading {
    text-align: center;
    padding: 10px;
    color: #6c757d;
    font-size: 14px;
}

.search-loading i {
    margin-right: 8px;
    color: #3498db;
}

.search-results {
    min-height: 200px;
    max-height: 400px;
    overflow-y: auto;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    background: #fff;
}

.search-placeholder {
    text-align: center;
    padding: 40px 20px;
    color: #6c757d;
}

.search-placeholder i {
    font-size: 24px;
    margin-bottom: 10px;
    display: block;
    color: #dee2e6;
}

.search-placeholder p {
    margin: 0;
    font-size: 14px;
}

.search-result-item {
    padding: 12px 15px;
    border-bottom: 1px solid #f8f9fa;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.search-result-item:hover {
    background-color: #f8f9fa;
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-user-info {
    display: flex;
    align-items: center;
    flex: 1;
}

.search-user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    margin-right: 12px;
    object-fit: cover;
    border: 2px solid #e9ecef;
}

.search-user-details {
    flex: 1;
}

.search-user-name {
    font-weight: 500;
    color: #212529;
    margin: 0 0 2px 0;
    font-size: 14px;
}

.search-user-email {
    color: #6c757d;
    font-size: 12px;
    margin: 0;
}

.search-user-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.search-permission-select {
    padding: 4px 8px;
    border: 1px solid #e9ecef;
    border-radius: 4px;
    font-size: 12px;
    background: #fff;
    cursor: pointer;
}

.search-add-btn {
    background: #28a745;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 12px;
    cursor: pointer;
    transition: background-color 0.2s ease;
    min-width: 70px;
}

.search-add-btn:hover {
    background: #218838;
}

.search-add-btn:disabled {
    background: #6c757d;
    cursor: not-allowed;
}

.search-no-results {
    text-align: center;
    padding: 30px 20px;
    color: #6c757d;
}

.search-no-results i {
    font-size: 20px;
    margin-bottom: 8px;
    display: block;
    color: #dee2e6;
}

/* Подсветка совпадений в результатах поиска */
.search-result-item mark {
    background-color: #fff3cd;
    color: #856404;
    padding: 1px 2px;
    border-radius: 2px;
    font-weight: 500;
}

/* Стили для результатов поиска в wiki-manage.js */
.search-result-item {
    padding: 12px 15px;
    border-bottom: 1px solid #f8f9fa;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 12px;
}

.search-result-item:hover {
    background-color: #f8f9fa;
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #e9ecef;
    flex-shrink: 0;
}

.search-result-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.search-result-avatar i {
    font-size: 18px;
    color: #6c757d;
}

.search-result-info {
    flex: 1;
}

.search-result-name {
    font-weight: 500;
    color: #212529;
    margin: 0 0 2px 0;
    font-size: 14px;
}

.search-result-email {
    color: #6c757d;
    font-size: 12px;
    margin: 0;
}

.search-result-action {
    color: #28a745;
    font-size: 16px;
    flex-shrink: 0;
}

.search-result-action:hover {
    color: #218838;
}

/* Дополнительные стили для индикаторов */
.search-loading {
    text-align: center;
    padding: 20px;
    color: #6c757d;
    font-size: 14px;
}

.search-loading i {
    margin-right: 8px;
    color: #3498db;
}

.search-no-results {
    text-align: center;
    padding: 30px 20px;
    color: #6c757d;
}

.search-no-results i {
    font-size: 20px;
    margin-bottom: 8px;
    display: block;
    color: #dee2e6;
}

/*MY CSS */

button:hover {
    background-color: #eeeeee;
    color: inherit;
}
/*END MY CSS*/

/* Адаптивность для мобильных устройств */
@media (max-width: 768px) {
    .search-result-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .search-user-actions {
        width: 100%;
        justify-content: flex-end;
    }
    
    .search-permission-select {
        flex: 1;
        margin-right: 10px;
    }
}
/* TinyMCE Z-Index Fix */
.tox-tinymce-aux {
    z-index: 10010 !important;
}

/* Fix for stats in settings modal */
.wiki-settings-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}

.wiki-settings-stats .wiki-stat {
    background: #f8f9fa;
    color: #495057;
    border: 1px solid #dee2e6;
    backdrop-filter: none;
    padding: 6px 12px;
    border-radius: 20px;
}

.wiki-settings-stats .wiki-stat i {
    color: #6c757d;
    margin-right: 5px;
}

/* Reduce margin in settings modal headers */
.wiki-settings-section h4 {
    margin-bottom: 10px;
    margin-top: 0;
    font-size: 1.1rem;
}

.wiki-settings-section {
    margin-bottom: 20px;
}


/* --- File: slider.css --- */
/* Related Articles Slider */
.related-articles-section {
    margin: 0px 0;
    padding: 20px;
    border-top: 1px solid #eee;
		background-color: #fff;
		border-radius: 10px;
}

.related-title {
    font-weight: 700;
    margin-bottom: 0;
    padding-left: 10px;
    border-left: 4px solid #3498db;
}

.related-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: #3498db;
    color: #fff;
    font-size: 0.75rem;
    height: 22px;
    min-width: 22px;
    padding: 0 6px;
    border-radius: 11px;
    margin-left: 8px;
    vertical-align: middle;
    font-weight: 700;
    transform: translateY(-2px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.related-slider {
    display: flex;
    overflow-x: auto;
    gap: 20px;
    padding: 10px 5px 20px 5px; /* bottom padding for scrollbar */
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
}

.related-slider::-webkit-scrollbar {
    height: 8px;
}

.related-slider::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.related-slider::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 4px;
}

.related-slider::-webkit-scrollbar-thumb:hover {
    background: #aaa;
}

.related-card {
    flex: 0 0 280px; /* Fixed width */
    scroll-snap-align: start;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: transform 0.2s, box-shadow 0.2s;
    border: 1px solid #eee;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
}

.related-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.related-thumb {
    height: 160px;
    background-color: #f5f5f5;
    background-size: cover;
    background-position: center;
    position: relative;
}

.related-thumb-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #ccc;
    font-size: 2rem;
}

.related-info {
    padding: 15px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.related-card-title {
    font-weight: 600;
    font-size: 0.8rem;
    margin-bottom: 8px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    color: #333;
}

.related-meta {
    font-size: 0.85rem;
    color: #777;
    margin-top: auto;
    display: flex;
    justify-content: space-between;
}

/* Series badge overlay */
.series-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0,0,0,0.7);
    color: #fff;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
}

/* Mobile responsive */
@media (max-width: 600px) {
    .related-card {
        flex: 0 0 85vw; /* Almost full width on mobile */
    }
}
@media (max-width: 768px) {
.related-articles-section {
    margin: 0px 0;
    padding: 10px;
    border-top: 1px solid #eee;
		background-color: #fff;
		border-radius: 6px;
}
h3.related-title {
    font-size: 14px;
}
.related-card-title {
    font-size: 0.8rem;
}
}

