/* ====== PUBLICATIONS FACEBOOK-STYLE CSS ====== */
/* Файл: src/main/resources/static/css/publications.css */

/* ====== CSS VARIABLES ====== */
:root {

    /* SmolyanVote цветове */
    --primary-color: #4cb15c;
    --primary-dark: #198754;
    --accent-green: #228e55;
    --primary-green: #19861c;

    /* Размери и shadow */
    --border-radius: 8px;
    --border-radius-lg: 12px;
    --sidebar-width: 280px;
    --main-feed-width: 680px;
    --transition: all 0.2s ease;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
}

/* ====== PUBLICATIONS SPECIFIC STYLES - ИЗОЛИРАНИ ОТ NAVBAR ====== */
/* Премахваме глобалните стилове за да не влияят на navbar-а */

/* Стилове само за publications страницата */
.publications-page {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--fb-bg);
    color: var(--fb-text);
    line-height: 1.5;
}

/* ====== LAYOUT ====== */
.feed-layout {
    display: flex;
    max-width: 1900px;
    margin: 60px auto;
    gap: 20px;
    padding: 20px 16px;
    min-height: calc(100vh - 120px);
}

/* ====== MOBILE FILTER TOGGLE ====== */
.mobile-filter-toggle {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 1000;
    display: none; /* Скрит по подразбиране */
}

.filter-toggle-btn {
    background: var(--primary-color);
    border: none;
    border-radius: 25px;
    color: var(--fb-white);
    padding: 12px 16px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 8px;
}

.filter-toggle-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

.filter-toggle-btn i {
    font-size: 16px;
}

/* ====== LEFT SIDEBAR - FILTERS ====== */
.left-sidebar {
    width: var(--sidebar-width);
    position: sticky;
    top: 80px;
    height: fit-content;
    max-height: 800px;
    overflow-y: auto;
}

.sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
    border-bottom: 1px solid var(--fb-border);
    margin-bottom: 20px;
    background: var(--fb-white);
    position: sticky;
    top: 0;
    z-index: 10;
}

.close-sidebar {
    background: none;
    border: none;
    color: var(--fb-text-secondary);
    font-size: 24px;
    cursor: pointer;
    padding: 4px;
    border-radius: 50%;
    transition: var(--transition);
    display: none; /* Скрит по подразбиране */
}

.close-sidebar:hover {
    background: var(--fb-hover);
    color: var(--fb-text);
}

.filters-panel {
    background: var(--fb-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    padding: 20px;
    border: 1px solid var(--fb-border);
}

.filters-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--fb-text);
    margin-bottom: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.filters-title i {
    color: var(--primary-color);
}

.filter-section {
    margin-bottom: 24px;
    border-bottom: 1px solid var(--fb-border);
    padding-bottom: 16px;
}

.filter-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.filter-label {
    font-size: 14px;
    font-weight: 600;
    color: var(--fb-text);
    margin-bottom: 12px;
    display: block;
}

/* ====== SEARCH INPUT ====== */
.search-input-wrapper {
    position: relative;
    margin-bottom: 4px;
}

.search-input {
    width: 100%;
    padding: 12px 40px 12px 40px;
    border: 2px solid var(--fb-border);
    border-radius: 20px;
    font-size: 15px;
    background: var(--fb-hover);
    transition: var(--transition);
}

.search-input:focus {
    outline: none;
    border-color: var(--primary-color);
    background: var(--fb-white);
}

.search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--fb-text-secondary);
    font-size: 16px;
}

.clear-search {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--fb-text-secondary);
    cursor: pointer;
    padding: 4px;
    border-radius: 50%;
    transition: var(--transition);
}

.clear-search:hover {
    background: var(--fb-border);
}

/* ====== FILTER OPTIONS ====== */
.filter-options {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.filter-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: var(--transition);
    position: relative;
}

.filter-option:hover {
    background: var(--fb-hover);
}

.filter-option.active {
    background: var(--primary-color);
    color: var(--fb-white);
}

.filter-option.active i {
    color: var(--fb-white);
}

.filter-option i {
    font-size: 18px;
    color: var(--primary-color);
    width: 20px;
    text-align: center;
}

.filter-option span {
    flex: 1;
    font-size: 15px;
    font-weight: 500;
}

.filter-option .count {
    font-size: 14px;
    background: rgba(255, 255, 255, 0);
    color: var(--fb-text-secondary);
    padding: 2px 8px;
    border-radius: 12px;
    font-weight: 600;
    min-width: 24px;
    text-align: right;
}

.filter-option.active .count {
    background: rgba(255, 255, 255, 0);
    color: var(--fb-white);
}
F
/* ====== CLEAR FILTERS BUTTON ====== */
.clear-all-filters {
    width: 100%;
    padding: 12px 16px;
    background: transparent;
    border: 2px solid var(--fb-border);
    border-radius: var(--border-radius);
    color: var(--fb-text-secondary);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.clear-all-filters:hover {
    background: var(--fb-hover);
    border-color: var(--fb-text-secondary);
}

/* ====== ACTIVE FILTERS SUMMARY ====== */
.active-filters-summary {
    background: var(--fb-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    padding: 16px;
    margin-top: 16px;
    border: 1px solid var(--fb-border);
}

.active-filters-summary h4 {
    font-size: 14px;
    font-weight: 600;
    color: var(--fb-text);
    margin-bottom: 12px;
}

.active-filters-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.active-filter-tag {
    background: var(--primary-color);
    color: var(--fb-white);
    padding: 4px 12px;
    border-radius: 16px;
    font-size: 13px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 6px;
}

.active-filter-tag .remove {
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
}

.active-filter-tag .remove:hover {
    opacity: 0.7;
}

/* ====== MAIN FEED ====== */
.main-feed {
    flex: 1;
    max-width: var(--main-feed-width);
    margin: 0 auto;
}

/* ====== CREATE POST ====== */
.create-post {
    background: var(--fb-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    margin-bottom: 20px;
    padding: 16px;
    border: 1px solid var(--fb-border);
}

.create-post-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--fb-white);
    font-weight: 700;
    font-size: 16px;
    text-transform: uppercase;
}

.create-post-input {
    flex: 1;
    background: var(--fb-hover);
    border: none;
    border-radius: 50px;
    padding: 12px 16px;
    font-size: 16px;
    cursor: pointer;
    color: var(--fb-text-secondary);
    transition: var(--transition);
}

.create-post-input:hover {
    background: var(--fb-border);
}

.create-post-actions {
    display: flex;
    justify-content: space-around;
    padding-top: 12px;
    border-top: 1px solid var(--fb-border);
}

.create-action {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: var(--transition);
    background: none;
    border: none;
    color: var(--fb-text-secondary);
    font-weight: 600;
    font-size: 15px;
    flex: 1;
    justify-content: center;
}

.create-action:hover {
    background: var(--fb-hover);
}

.create-action i {
    font-size: 20px;
}

/* ====== LOGIN PROMPT ====== */
.login-prompt {
    background: var(--fb-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    margin-bottom: 20px;
    padding: 32px;
    text-align: center;
    border: 1px solid var(--fb-border);
}

.prompt-content i {
    font-size: 48px;
    color: var(--fb-text-secondary);
    margin-bottom: 16px;
}

.prompt-content h3 {
    font-size: 20px;
    font-weight: 700;
    color: var(--fb-text);
    margin-bottom: 12px;
}

.prompt-content p {
    color: var(--fb-text-secondary);
    font-size: 15px;
    margin-bottom: 20px;
    line-height: 1.4;
}

.prompt-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
}

/* ====== ENHANCED BUTTON STYLES - САМО ЗА PUBLICATIONS ====== */
.publications-page .publications-btn,
.publications-page .btn {
    padding: 12px 24px;
    border-radius: var(--border-radius);
    font-weight: 600;
    font-size: 15px;
    text-decoration: none;
    transition: var(--transition);
    border: 2px solid;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.publications-page .publications-btn.btn-primary,
.publications-page .btn-primary {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: var(--fb-white);
}

.publications-page .publications-btn.btn-primary:hover,
.publications-page .btn-primary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    color: var(--fb-white);
    text-decoration: none;
}

.publications-page .publications-btn.btn-outline-primary,
.publications-page .btn-outline-primary {
    background: transparent;
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.publications-page .publications-btn.btn-outline-primary:hover,
.publications-page .btn-outline-primary:hover {
    background: var(--primary-color);
    color: var(--fb-white);
    text-decoration: none;
}

/* ====== POSTS CONTAINER ====== */
.posts-container {
    display: flex;
    flex-direction: column;
    gap: 50px;
}

/* ====== POST CARD ====== */
.post {
    background: var(--fb-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--fb-border);
    overflow: hidden;
    transition: var(--transition);
    animation: fadeInUp 0.4s ease-out;
}

.post:hover {
    box-shadow: var(--shadow-md);
}

.post-header {
    padding: 16px 16px 0 16px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.post-author-info {
    flex: 1;
}

.post-author-name {
    font-weight: 700;
    font-size: 15px;
    color: var(--fb-text);
    text-decoration: none;
    display: block;
    line-height: 1.3;
}

.post-author-name:hover {
    text-decoration: underline;
    color: var(--fb-text);
}

.post-meta {
    color: var(--fb-text-secondary);
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 4px;
    margin-top: 2px;
}

.post-status {
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    margin-left: 8px;
}

.status-published {
    background: #d4edda;
    color: #155724;
}

.status-review {
    background: #cce5ff;
    color: #004085;
}

.status-draft {
    background: #fff3cd;
    color: #856404;
}

.status-edited {
    background: #e2e3e5;
    color: #495057;
}

.post-menu {
    position: relative;
    color: var(--fb-text-secondary);
    cursor: pointer;
    padding: 8px;
    border-radius: 50%;
    transition: var(--transition);
}

.post-menu:hover {
    background: var(--fb-hover);
}

.post-menu-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--fb-white);
    border: 1px solid var(--fb-border);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    z-index: 1000;
    min-width: 200px;
    padding: 8px 0;
    display: none;
}

.post-menu-dropdown.show {
    display: block;
    animation: fadeInDown 0.2s ease-out;
}

.menu-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: var(--fb-text);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition: var(--transition);
    background: none;
    border: none;
    width: 100%;
    text-align: left;
    cursor: pointer;
}

.menu-item:hover {
    background: var(--fb-hover);
    color: var(--fb-text);
    text-decoration: none;
}

.menu-item.text-danger {
    color: var(--fb-red);
}

.menu-item.text-danger:hover {
    background: rgba(231, 76, 60, 0.1);
    color: var(--fb-red);
}

.post-content {
    padding: 12px 16px;
}

.post-category {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: rgba(75, 177, 92, 0.1);
    color: var(--primary-color);
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 8px;
}

.post-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--fb-text);
    margin-bottom: 8px;
    line-height: 1.3;
}

.post-excerpt {
    color: var(--fb-text);
    font-size: 15px;
    line-height: 1.33;
    margin-bottom: 12px;
}

.post-image {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    border-radius: var(--border-radius);
    margin-bottom: 12px;
}

/* ====== НОВА СТРУКТУРА ЗА POST STATS ====== */
.post-stats {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: var(--fb-hover);
    border-top: 1px solid var(--fb-border);
    border-bottom: 1px solid var(--fb-border);
    margin: 0;
}

.stats-left {
    display: flex;
    align-items: center;
    gap: 6px;
    padding-left: 11px;
}
.stats-right{
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3.88rem;
    padding-left: 20px;
    margin-right: 0.6rem;
}

.stats-item {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--fb-text-secondary);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    padding: 6px 8px;
    border-radius: 6px;
}

.stats-icon {
    font-size: 16px;
    color: var(--primary-color);
    transition: var(--transition);
}

.stats-count {
    font-weight: 600;
    transition: transform 0.2s ease;
    min-width: 20px;
    text-align: center;
}

/* ====== POST ACTIONS ====== */
.post-actions {
    display: flex;
    align-items: center;
    justify-content: space-around;
    padding: 8px 0;
    background: var(--fb-white);
    border-top: 1px solid var(--fb-border);
}

.post-action {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 5px;
    background: none !important;
    border: none !important;
    box-shadow: none !important;
    outline: none !important;
    border-radius: 6px;
    color: var(--fb-text-secondary);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    flex: 1;
    position: relative;
}

/* Премахваме всички hover/focus ефекти за like/dislike */
.like-btn:hover, .dislike-btn:hover,
.like-btn:focus, .dislike-btn:focus,
.like-btn:focus-visible, .dislike-btn:focus-visible,
.like-btn:active, .dislike-btn:active {
    background: none !important;
    border: none !important;
    box-shadow: none !important;
    outline: none !important;
    transform: none !important;
    color: var(--fb-text-secondary) !important;
}

/* Hover само за comment и share */
.comment-btn:hover, .share-btn:hover {
    background-color: rgba(75, 177, 92, 0.1) !important;
    color: var(--primary-color) !important;
    transform: translateY(-1px);
}

.post-action i {
    font-size: 20px;
    color: var(--primary-color);
    transition: all 0.2s ease;
}

.comment-btn:hover i, .share-btn:hover i {
    color: var(--primary-dark) !important;
    transform: scale(1.1);
}

/* ====== POST ACTIONS ====== */
.post-actions {
    display: flex;
    align-items: center;
    justify-content: space-around;
    padding: 8px 0;
    background: var(--fb-white);
    border-top: 1px solid var(--fb-border);
}

.post-action {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 5px;
    background: none;
    border: none;
    border-radius: 6px;
    color: var(--fb-text-secondary);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    flex: 1;
    position: relative;
}

/* Hover ефекти за бутони, които не са в активно състояние */
.post-action:not(.liked):not(.disliked):hover {
    background-color: rgba(75, 177, 92, 0.1);
    color: var(--primary-color);
    text-decoration: none;
    transform: translateY(-1px);
}

.post-action:focus,
.post-action:focus-visible,
.post-action:active {
    border: none;
    box-shadow: none;
    outline: none;
}

.post-action i {
    font-size: 20px;
    color: var(--primary-color);
    transition: all 0.2s ease;
}

.post-action:not(.liked):not(.disliked):hover i {
    color: var(--primary-dark);
    transform: scale(1.1);
}

/* Активни състояния на бутоните */
.like-btn.liked {
    color: var(--primary-color);
    background: rgba(75, 177, 92, 0.1);
    animation: pulseGreen 0.3s ease;
}

.like-btn.liked i {
    color: var(--primary-color);
}

.like-btn.liked:hover {
    background: rgba(75, 177, 92, 0.15);
    color: var(--primary-dark);
}

.like-btn.liked:hover i {
    color: var(--primary-dark);
}

.dislike-btn.disliked {
    color: var(--fb-red);
    background: rgba(231, 76, 60, 0.1);
    animation: pulseRed 0.3s ease;
}

.dislike-btn.disliked i {
    color: var(--fb-red);
}

.dislike-btn.disliked:hover {
    background: rgba(231, 76, 60, 0.15);
    color: #c0392b;
}

.dislike-btn.disliked:hover i {
    color: #c0392b;
}

/* Анимации за реакции */
@keyframes pulseGreen {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

@keyframes pulseRed {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

.bookmark-btn.bookmarked {
    color: #ffc107 !important;
    animation: pulse 0.3s ease;
}

.follow-btn {
    transition: all 0.2s ease;
}

.follow-btn.following {
    background: #28a745 !important;
}

.follow-btn.following:hover {
    background: #218838 !important;
}

.post-action:active {
    transform: scale(0.95);
}

/* ====== АНИМАЦИИ ЗА СТАТИСТИКИ ====== */
.stats-count {
    transition: all 0.3s ease;
}

@keyframes statsUpdate {
    0% { transform: scale(1); }
    50% { transform: scale(1.2); color: var(--primary-color); }
    100% { transform: scale(1); }
}

.stats-count.updated {
    animation: statsUpdate 0.4s ease;
}

/* ====== LOADING INDICATOR ====== */
.loading-indicator {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    padding: 40px;
    background: var(--fb-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--fb-border);
    margin-top: 20px;
}

.spinner {
    display: flex;
    gap: 4px;
}

.spinner > div {
    width: 12px;
    height: 12px;
    background-color: var(--primary-color);
    border-radius: 100%;
    animation: sk-bouncedelay 1.4s infinite ease-in-out both;
}

.spinner .bounce1 {
    animation-delay: -0.32s;
}

.spinner .bounce2 {
    animation-delay: -0.16s;
}

@keyframes sk-bouncedelay {
    0%, 80%, 100% {
        transform: scale(0);
    } 40% {
          transform: scale(1.0);
      }
}

.loading-indicator span {
    color: var(--fb-text-secondary);
    font-size: 15px;
    font-weight: 500;
}

/* ====== NO MORE POSTS ====== */
.no-more-posts {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 24px;
    color: var(--fb-text-secondary);
    font-size: 15px;
    font-weight: 500;
    margin-top: 20px;
}

.no-more-posts i {
    color: var(--primary-color);
    font-size: 18px;
}

/* ====== NO RESULTS ====== */
.no-results {
    text-align: center;
    padding: 60px 20px;
    background: var(--fb-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--fb-border);
    margin-top: 20px;
}

.no-results i {
    font-size: 48px;
    color: var(--fb-text-secondary);
    margin-bottom: 16px;
    opacity: 0.5;
}

.no-results h3 {
    font-size: 20px;
    font-weight: 600;
    color: var(--fb-text);
    margin-bottom: 12px;
}

.no-results p {
    color: var(--fb-text-secondary);
    font-size: 15px;
    margin-bottom: 20px;
    line-height: 1.4;
}

/* ====== RIGHT SIDEBAR ====== */
.right-sidebar {
    width: var(--sidebar-width);
    position: sticky;
    top: 80px;
    height: fit-content;
    max-height: 800px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.sidebar-widget {
    background: var(--fb-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    padding: 20px;
    border: 1px solid var(--fb-border);
}

.widget-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--fb-text);
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.widget-title i {
    color: var(--primary-color);
}

/* ====== TRENDING TOPICS ====== */
.trending-topics {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.trending-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: var(--transition);
}

.trending-item:hover {
    background: var(--fb-hover);
}

.hashtag {
    font-weight: 600;
    color: var(--primary-color);
    font-size: 14px;
}

.trending-item .count {
    font-size: 12px;
    color: var(--fb-text-secondary);
}

/* ====== RECENT AUTHORS ====== */
.recent-authors {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.author-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 12px;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: var(--transition);
}

.author-item:hover {
    background: var(--fb-hover);
}

.author-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--fb-white);
    font-weight: 600;
    font-size: 14px;
    text-transform: uppercase;
}

.author-info {
    flex: 1;
}

.author-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--fb-text);
    line-height: 1.2;
}

.author-stats {
    font-size: 12px;
    color: var(--fb-text-secondary);
}

.follow-btn {
    background: var(--primary-color);
    border: none;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--fb-white);
    cursor: pointer;
    transition: var(--transition);
}

.follow-btn:hover {
    background: var(--primary-dark);
    transform: scale(1.05);
}

.follow-btn.following {
    background: var(--fb-green);
}

.follow-btn i {
    font-size: 14px;
}

/* ====== STATISTICS ====== */
.stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.stat-item {
    text-align: center;
    padding: 12px;
    background: var(--fb-hover);
    border-radius: var(--border-radius);
}

.stat-number {
    font-size: 20px;
    font-weight: 700;
    color: var(--primary-color);
    line-height: 1;
}

.stat-label {
    font-size: 12px;
    color: var(--fb-text-secondary);
    font-weight: 500;
    margin-top: 4px;
}

/* ====== SCROLL TO TOP ====== */
.scroll-to-top {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 48px;
    height: 48px;
    background: var(--primary-color);
    border: none;
    border-radius: 50%;
    color: var(--fb-white);
    font-size: 20px;
    cursor: pointer;
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
    z-index: 1000;
}

.scroll-to-top:hover {
    background: var(--primary-dark);
    transform: scale(1.1);
}

/* ====== MOBILE OVERLAY ====== */
.mobile-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9998;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.mobile-overlay.show {
    display: block;
    opacity: 1;
}

.status-active {
    background: #d4edda;
    color: #4b9f3e;
}

.status-inactive {
    background: #f8d7da;
    color: #a62532;
}

.status-draft {
    background: #fff3cd;
    color: #bb4c11;
}

.status-pending {
    background: #cce5ff;
    color: #9e9fa1;
}

/* ====== ОНЛАЙН СТАТУС ИНДИКАТОР ====== */
.online-status-indicator {
    margin: 0 4px;
    font-size: 6px;
    transition: all 0.2s ease;
    cursor: help;
    border-radius: 50%;
    width: 8px;
    height: 8px;
    display: table;
}

.online-status-indicator.online {
    background-color: #4b9f3e !important;
    text-shadow: 0 0 8px rgba(16, 185, 129, 0.6);
    animation: pulse-dot 2s infinite;
}

.online-status-indicator.away {
    background-color: #f59e0b !important;
    text-shadow: 0 0 4px rgba(245, 158, 11, 0.4);
}

.online-status-indicator.offline {
    background-color: #6b7280 !important;
}

/* ====== EDIT OPTIONS ====== */
.inline-edit-form {
    margin: 12px 0;
}

.edit-textarea {
    width: 100%;
    border: 2px solid var(--primary-color);
    border-radius: 8px;
    padding: 12px;
    font-size: 15px;
    font-family: inherit;
    resize: vertical;
    min-height: 120px;
}

.edit-buttons {
    display: flex;
    gap: 8px;
    margin-top: 8px;
    color: #7e7e7e;
}

.edit-buttons .btn {
    padding: 6px 12px;
    font-size: 13px;
}

/* ====== CREATE PUBLICATION LOADER ====== */
.spinner-border-sm {
    width: 1rem;
    height: 1rem;
    border-width: 0.2em;
}

.spinner-border {
    display: inline-block;
    border: 0.25em solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: spinner-border 0.75s linear infinite;
}

@keyframes spinner-border {
    to {
        transform: rotate(360deg);
    }
}

.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

@keyframes pulse-dot {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.2);
        opacity: 0.7;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* ====== ANIMATIONS ====== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes likeAnimation {
    0% {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
    50% {
        transform: translateY(-20px) scale(1.2);
        opacity: 0.8;
    }
    100% {
        transform: translateY(-40px) scale(0.8);
        opacity: 0;
    }
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

@keyframes fadeOut {
    from {
        opacity: 1;
        transform: translateY(0);
    }
    to {
        opacity: 0;
        transform: translateY(-20px);
    }
}

@keyframes pulseBlue {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); color: var(--primary-color); }
    100% { transform: scale(1); }
}

@keyframes pulseRed {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); color: #e74c3c; }
    100% { transform: scale(1); }
}

.like-btn.liked {
    animation: pulseBlue 0.3s ease;
}

.dislike-btn.disliked {
    animation: pulseRed 0.3s ease;
}

.like-btn, .dislike-btn {
    transition: all 0.2s ease;
}

.bookmark-btn.bookmarked {
    color: #ffc107 !important;
    animation: pulse 0.3s ease;
}

.follow-btn {
    transition: all 0.2s ease;
}

.follow-btn.following {
    background: #28a745 !important;
}

.follow-btn.following:hover {
    background: #218838 !important;
}

.like-count, .dislike-count {
    transition: transform 0.2s ease;
}

.like-count:hover, .dislike-count:hover {
    transform: scale(1.05);
}

.post-menu-dropdown {
    animation: fadeInDown 0.2s ease;
}


/* ====== FACEBOOK SHARE DROPDOWN ====== */
.share-dropdown {
    position: absolute;
    top: 100%;
    right: 50%;
    width: 320px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    z-index: 1000;
    display: none;
    margin-top: 8px;
    border: 1px solid #e4e6ea;
    overflow: hidden;
}

.share-dropdown-content {
    padding: 0;
}

.share-options {
    padding: 8px 0;
    border-bottom: 1px solid #e4e6ea;
}

.share-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: none;
    border: none;
    width: 100%;
    text-align: left;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: 'Inter', sans-serif;
    font-size: 15px;
    font-weight: 500;
    color: #1c1e21;
}

.share-option:hover {
    background: #f0f2f5;
}

.share-option-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.facebook-icon {
    background: #1877f2;
    color: white;
}

.copy-icon {
    background: #6c757d;
    color: white;
}

.share-option-icon i {
    font-size: 16px;
}

.facebook-preview {
    padding: 16px;
    background: #f8f9fa;
}

.preview-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
    font-size: 13px;
    font-weight: 600;
    color: #65676b;
}

.preview-icon {
    color: #1877f2;
    font-size: 14px;
}

.preview-card {
    background: white;
    border: 1px solid #dadde1;
    border-radius: 8px;
    overflow: hidden;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.preview-site-info {
    padding: 12px 12px 8px 12px;
    border-bottom: 1px solid #dadde1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.preview-site-name {
    font-size: 12px;
    font-weight: 600;
    color: #1c1e21;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.preview-site-url {
    font-size: 11px;
    color: #65676b;
    text-transform: uppercase;
}

.preview-image {
    width: 100%;
    height: 140px;
    overflow: hidden;
    background: #f0f2f5;
}

.preview-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.preview-content {
    padding: 12px;
}

.preview-title {
    font-size: 14px;
    font-weight: 600;
    color: #1c1e21;
    line-height: 1.3;
    margin-bottom: 6px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.preview-description {
    font-size: 13px;
    color: #65676b;
    line-height: 1.4;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.preview-metadata {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 11px;
    color: #8a8d91;
}

.preview-metadata span {
    display: flex;
    align-items: center;
    gap: 3px;
}

.share-dropdown::before {
    content: '';
    position: absolute;
    top: -8px;
    right: 20px;
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 8px solid white;
}

.share-dropdown::after {
    content: '';
    position: absolute;
    top: -9px;
    right: 20px;
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 8px solid #e4e6ea;
}

.share-option.facebook-share:hover .facebook-icon {
    background: #166fe5;
    transform: scale(1.05);
}

.share-option.copy-link:hover .copy-icon {
    background: #5a6169;
    transform: scale(1.05);
}

.post-action {
    position: relative;
}

.post-item {
    position: relative;
    z-index: 1;
}

.post-item:has(.share-dropdown[style*="display: block"]) {
    z-index: 10;
}

/* Link Input Section */
.link-input-section {
    margin-bottom: 12px;
    animation: slideDown 0.3s ease;
}

.link-input-wrapper {
    margin-bottom: 12px;
}

.link-input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #e4e6eb;
    border-radius: 8px;
    background: white;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s ease;
    box-sizing: border-box;
}

.link-input:focus {
    border-color: #4b9f3e;
}

.link-input::placeholder {
    color: #65676b;
}

/* Link Preview Container */
.link-preview-container {
    animation: slideDown 0.3s ease;
}

.link-preview {
    border: 1px solid #e4e6eb;
    border-radius: 8px;
    overflow: hidden;
    background: white;
    transition: all 0.2s ease;
}

.link-preview:hover {
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

/* YouTube Preview */
.youtube-preview .preview-thumbnail {
    width: 100%;
    height: 200px;
    background-size: cover;
    background-position: center;
    position: relative;
}

.youtube-preview .play-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background: rgba(255, 0, 0, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
}

.youtube-preview .preview-content {
    padding: 12px;
}

.youtube-preview .preview-title {
    font-size: 14px;
    font-weight: 600;
    color: #1c1e21;
    margin-bottom: 4px;
    line-height: 1.3;
}

.youtube-preview .preview-description {
    font-size: 12px;
    color: #65676b;
    line-height: 1.4;
}

.youtube-preview .preview-source {
    font-size: 11px;
    color: #65676b;
    margin-top: 8px;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Image Preview */
.image-preview {
    text-align: center;
    padding: 8px;
}

.image-preview img {
    max-width: 100%;
    max-height: 300px;
    border-radius: 6px;
}

/* Website Preview */
/* ====== WEBSITE PREVIEW STYLES FOR MAIN FEED ====== */

/* Large website preview with image */
.website-preview-large {
    margin-top: 12px;
    transition: transform 0.2s ease;
}

.website-preview-large:hover {
    transform: translateY(-2px);
}

.website-large-image {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    transition: transform 0.2s ease;
}

.website-large-image:hover {
    transform: scale(1.02);
}

.website-overlay {
    background: linear-gradient(transparent, rgba(0,0,0,0.7)) !important;
}

/* Compact website preview */
.website-preview-compact {
    margin-top: 12px;
    transition: all 0.2s ease !important;
}

.website-preview-compact:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.15) !important;
    transform: translateY(-1px);
}

.website-preview-compact img {
    transition: transform 0.2s ease;
}

.website-preview-compact:hover img {
    transform: scale(1.1);
}

/* Mobile responsive for website previews */
@media (max-width: 768px) {
    .website-large-image {
        height: 150px !important;
    }

    .website-overlay {
        padding: 12px !important;
    }

    .website-preview-compact {
        padding: 8px !important;
        gap: 8px !important;
    }

    .website-preview-compact > div:first-child {
        width: 40px !important;
        height: 40px !important;
    }
}

@media (max-width: 480px) {
    .website-large-image {
        height: 120px !important;
    }

    .website-overlay {
        padding: 8px !important;
    }

    .website-overlay > div:first-child {
        font-size: 13px !important;
    }

    .website-overlay > div:nth-child(2) {
        font-size: 11px !important;
    }
}

/* ====== IMAGE PREVIEW STYLES FOR MAIN FEED ====== */

/* Large image preview */
.image-preview-large {
    margin-top: 12px;
    transition: transform 0.2s ease;
}

.image-preview-large:hover {
    transform: translateY(-2px);
}

.image-large-display {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    transition: transform 0.2s ease !important;
    cursor: pointer;
}

.image-large-display:hover {
    transform: scale(1.02) !important;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.image-overlay {
    background: linear-gradient(transparent, rgba(0,0,0,0.6)) !important;
}

/* Mobile responsive for image previews */
@media (max-width: 768px) {
    .image-large-display {
        height: 180px !important;
    }

    .image-overlay {
        padding: 12px !important;
    }

    .image-overlay > div:first-child {
        font-size: 13px !important;
    }

    .image-overlay > div:nth-child(2) {
        font-size: 11px !important;
    }
}

@media (max-width: 480px) {
    .image-large-display {
        height: 150px !important;
    }

    .image-overlay {
        padding: 8px !important;
    }
}

@media (max-width: 480px) {
    .share-dropdown {
        width: 280px;
        right: -20px;
    }

    .preview-image {
        height: 120px;
    }
}

/* ====== RESPONSIVE DESIGN ====== */
@media (max-width: 1024px) {
    .right-sidebar {
        display: none;
    }

    .feed-layout {
        max-width: 960px;
    }
}

@media (max-width: 768px) {
    .mobile-filter-toggle {
        display: block;
    }

    .left-sidebar {
        position: fixed;
        height: 100vh;
        top: 20px;
        left: -100%;
        width: 100%;
        background: var(--fb-white);
        z-index: 9999;
        transition: left 0.3s ease;
        overflow-y: auto;
        padding: 0;
    }

    .left-sidebar.show {
        left: 0;
    }

    .close-sidebar {
        display: block;
    }

    .sidebar-header {
        margin-bottom: 0;
        border-bottom: 1px solid var(--fb-border);
    }

    .filters-panel {
        margin-top: 0;
        border-radius: 0;
        border: none;
        box-shadow: none;
    }

    .feed-layout {
        flex-direction: column;
        padding: 16px 12px;
    }

    .main-feed {
        max-width: 100%;
    }

    .scroll-to-top {
        bottom: 80px; /* Над filter toggle */
    }

    /* ====== MOBILE RESPONSIVE ЗА НОВАТА СТРУКТУРА ====== */
    .post-stats {
        padding: 8px 12px;
    }

    .stats-item {
        font-size: 13px;
        gap: 4px;
    }

    .stats-icon {
        font-size: 14px;
    }

    .post-action {
        padding: 8px 6px;
        font-size: 14px;
    }

    .post-action i {
        font-size: 18px;
    }
}

@media (max-width: 480px) {
    .feed-layout {
        padding: 12px 8px;
    }

    .create-post-actions {
        flex-direction: column;
        gap: 8px;
    }

    .create-action {
        justify-content: flex-start;
        padding: 12px 16px;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .prompt-actions {
        flex-direction: column;
    }

    .btn {
        padding: 10px 20px;
        font-size: 14px;
    }

    .filter-toggle-btn {
        padding: 10px 14px;
        font-size: 13px;
    }

    .scroll-to-top {
        width: 44px;
        height: 44px;
        font-size: 18px;
        bottom: 70px;
    }

    .post-stats {
        padding: 6px 8px;
    }

    .stats-item {
        font-size: 12px;
        gap: 3px;
        flex-direction: column;
    }

    .stats-icon {
        font-size: 16px;
    }

    .stats-count {
        font-size: 11px;
    }

    .post-action span {
        display: none;
    }

    .post-action {
        padding: 8px;
    }
}

@media (max-width: 360px) {
    .feed-layout {
        padding: 8px 4px;
    }

    .post,
    .create-post,
    .login-prompt,
    .no-results,
    .loading-indicator {
        margin-left: 0;
        margin-right: 0;
    }

    .sidebar-header {
        padding: 12px 16px;
    }

    .filters-panel {
        padding: 16px;
    }

    .create-post-header {
        gap: 8px;
    }

    .user-avatar {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }

    .author-avatar {
        width: 28px;
        height: 28px;
        font-size: 12px;
    }
}

/* ====== SCROLLBAR STYLING ====== */
.left-sidebar::-webkit-scrollbar,
.right-sidebar::-webkit-scrollbar {
    width: 6px;
}

.left-sidebar::-webkit-scrollbar-track,
.right-sidebar::-webkit-scrollbar-track {
    background: var(--fb-hover);
    border-radius: 3px;
}

.left-sidebar::-webkit-scrollbar-thumb,
.right-sidebar::-webkit-scrollbar-thumb {
    background: var(--fb-border);
    border-radius: 3px;
}

.left-sidebar::-webkit-scrollbar-thumb:hover,
.right-sidebar::-webkit-scrollbar-thumb:hover {
    background: var(--fb-text-secondary);
}

/* ====== ACCESSIBILITY ====== */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ====== FOCUS STYLES - САМО ЗА PUBLICATIONS ====== */
.publications-page .filter-option:focus,
.publications-page .post-action:focus,
.publications-page .create-action:focus,
.publications-page .btn:focus,
.publications-page .search-input:focus,
.publications-page .clear-all-filters:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* ====== PRINT STYLES ====== */
@media print {
    .left-sidebar,
    .right-sidebar,
    .mobile-filter-toggle,
    .scroll-to-top,
    .mobile-overlay {
        display: none !important;
    }

    .feed-layout {
        flex-direction: column;
        max-width: 100%;
        padding: 0;
    }

    .main-feed {
        max-width: 100%;
    }

    .post {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid #000;
    }
}

/* ====== (FUTURE) ====== */
@media (prefers-color-scheme: dark) {
    .post-actions {
        border-top-color: #3a3b3c;
    }

    .post-action {
        color: #b0b3b8;
    }

    .post-action:hover {
        background-color: #3a3b3c;
        color: #e4e6ea;
    }

    .post-stats {
        color: #b0b3b8;
    }
}

/* ====== UTILITY CLASSES - САМО ЗА PUBLICATIONS ====== */
.publications-page .text-center {
    text-align: center;
}

.publications-page .text-left {
    text-align: left;
}

.publications-page .text-right {
    text-align: right;
}

.publications-page .d-none {
    display: none !important;
}

.publications-page .d-block {
    display: block !important;
}

.publications-page .d-flex {
    display: flex !important;
}

.publications-page .align-items-center {
    align-items: center;
}

.publications-page .justify-content-center {
    justify-content: center;
}

.publications-page .justify-content-between {
    justify-content: space-between;
}

.publications-page .gap-2 {
    gap: 8px;
}

.publications-page .gap-3 {
    gap: 12px;
}

.publications-page .gap-4 {
    gap: 16px;
}

.publications-page .mt-2 {
    margin-top: 8px;
}

.publications-page .mt-3 {
    margin-top: 12px;
}

.publications-page .mt-4 {
    margin-top: 16px;
}

.publications-page .mb-2 {
    margin-bottom: 8px;
}

.publications-page .mb-3 {
    margin-bottom: 12px;
}

.publications-page .mb-4 {
    margin-bottom: 16px;
}

.publications-page .p-2 {
    padding: 8px;
}

.publications-page .p-3 {
    padding: 12px;
}

.publications-page .p-4 {
    padding: 16px;
}

.publications-page .rounded {
    border-radius: var(--border-radius);
}

.publications-page .rounded-lg {
    border-radius: var(--border-radius-lg);
}

.publications-page .shadow-sm {
    box-shadow: var(--shadow-sm);
}

.publications-page .shadow-md {
    box-shadow: var(--shadow-md);
}

.publications-page .shadow-lg {
    box-shadow: var(--shadow-lg);
}

/* ====== HOVER EFFECTS - САМО ЗА PUBLICATIONS ====== */
.publications-page .hover-lift:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.publications-page .hover-scale:hover {
    transform: scale(1.02);
}

.publications-page .hover-fade:hover {
    opacity: 0.8;
}

/* ====== END OF CSS ====== */