.sidebar {
    position: fixed;
    top: 60px;
    left: 0;
    height: calc(100vh - 60px);
    background-color: rgba(249, 247, 247, 0.95);
    backdrop-filter: blur(10px);
    z-index: 40;
    transition: width 0.3s ease;
    display: flex;
    flex-direction: column;
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.05);
    border-right: 1px solid rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.sidebar.collapsed {
    width: 70px;
}

.sidebar.expanded {
    width: 250px;
}

.sidebar-header {
    padding: 1rem;
    display: flex;
    align-items: center;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.sidebar-toggle {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    font-size: 1.2rem;
    color: #5a5a5a;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.sidebar-toggle:hover {
    transform: scale(1.1);
}

.sidebar-title {
    margin-left: 1rem;
    font-family: 'Syne', sans-serif;
    font-size: 1.2rem;
    color: #B8BDE1;
}

.sidebar-content {
    flex: 1;
    overflow-y: auto;
    padding: 1rem 0;
}

.sidebar-categories {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.sidebar-category {
    display: flex;
    align-items: center;
    padding: 0.75rem 1.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
}

.sidebar-category:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.sidebar-category.active {
    border-left-color: #B8BDE1;
    background-color: rgba(184, 189, 225, 0.1);
}

.sidebar-category i {
    font-size: 1.2rem;
    min-width: 24px;
    text-align: center;
    color: #85C7D3;
}

.sidebar-category span {
    margin-left: 1rem;
    font-weight: 500;
    color: #404992;
    white-space: nowrap;
}

.category-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    padding: 0 0.5rem;
}

.category-header i {
    font-size: 1rem;
    color: #85C7D3;
}

.category-header h3 {
    font-size: 1rem;
    font-weight: 600;
    color: #B8BDE1;
    margin: 0;
}

.sidebar-stories {
    padding: 0.5rem 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    max-height: 300px;
    overflow-y: auto;
}

.sidebar-story {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.sidebar-story:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.story-thumbnail {
    width: 30px;
    height: 30px;
    border-radius: 4px;
    overflow: hidden;
    flex-shrink: 0;
}

.story-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.story-title {
    font-size: 2.875rem !important;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #404992;
}

/* Dark mode styles */
.dark-mode .sidebar {
    background-color: rgba(42, 42, 42, 0.95);
    border-right: 1px solid rgba(255, 255, 255, 0.05);
}

.dark-mode .sidebar-header {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.dark-mode .sidebar-toggle,
.dark-mode .sidebar-title,
.dark-mode .sidebar-category i,
.dark-mode .sidebar-category span,
.dark-mode .story-title,
.dark-mode .category-header i,
.dark-mode .category-header h3 {
    color: #e0e0e0;
}

.dark-mode .sidebar-category:hover,
.dark-mode .sidebar-story:hover {
    background-color: rgba(255, 255, 255, 0.05);
}

.dark-mode .sidebar-category.active {
    border-left-color: #B8BDE1;
    background-color: rgba(184, 189, 225, 0.2);
}

@media (max-width: 768px) {
    .sidebar {
        display: none;
    }
}
