/* Blog Sidebar Styles */
.blog-sidebar {
    background: #fff;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.sidebar-content {
    padding: 0;
}

.sidebar-section {
    padding: 1.5rem;
    border-bottom: 1px solid #f0f0f0;
}

.sidebar-section:last-child {
    border-bottom: none;
}

.sidebar-section h3 {
    color: #2c3e50;
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.sidebar-section h3 i {
    color: #e74c3c;
    font-size: 1rem;
}

/* Search Section */
.search-box {
    position: relative;
    display: flex;
    gap: 0.5rem;
}

.search-box input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 2px solid #e9ecef;
    border-radius: 25px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.search-box input:focus {
    outline: none;
    border-color: #e74c3c;
    box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.1);
}

.search-box button {
    padding: 0.75rem 1rem;
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    color: white;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.search-box button:hover {
    background: linear-gradient(135deg, #c0392b, #a93226);
    transform: translateY(-2px);
}

/* Article Cards */
.article-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.article-card {
    background: #f8f9fa;
    border-radius: 10px;
    overflow: hidden;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.article-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.article-card.current {
    border-color: #e74c3c;
    background: linear-gradient(135deg, #fff5f5, #ffeaea);
}

.article-image {
    position: relative;
    height: 120px;
    overflow: hidden;
}

.article-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.article-card:hover .article-image img {
    transform: scale(1.05);
}

.article-category {
    position: absolute;
    top: 0.5rem;
    left: 0.5rem;
    background: rgba(231, 76, 60, 0.9);
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 15px;
    font-size: 0.7rem;
    font-weight: 500;
}

.article-info {
    padding: 1rem;
}

.article-info h4 {
    margin: 0 0 0.5rem 0;
    font-size: 0.9rem;
    line-height: 1.3;
}

.article-info h4 a {
    color: #2c3e50;
    text-decoration: none;
    transition: color 0.3s ease;
}

.article-info h4 a:hover {
    color: #e74c3c;
}

.article-meta {
    display: flex;
    gap: 1rem;
    margin-bottom: 0.5rem;
    font-size: 0.75rem;
    color: #6c757d;
}

.article-meta span {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.article-excerpt {
    font-size: 0.8rem;
    color: #6c757d;
    line-height: 1.4;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Categories */
.category-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.category-btn {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 0.75rem 1rem;
    background: #f8f9fa;
    border: 2px solid transparent;
    border-radius: 10px;
    color: #495057;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.category-btn:hover {
    background: #e9ecef;
    transform: translateX(5px);
}

.category-btn.active {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    color: white;
    border-color: #c0392b;
}

.category-btn i {
    margin-right: 0.5rem;
}

.category-btn .count {
    background: rgba(255, 255, 255, 0.2);
    color: inherit;
    padding: 0.25rem 0.5rem;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: 500;
}

.category-btn.active .count {
    background: rgba(255, 255, 255, 0.3);
}

/* Popular Articles */
.popular-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.popular-item {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}

.popular-rank {
    width: 30px;
    height: 30px;
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.8rem;
    flex-shrink: 0;
}

.popular-content {
    flex: 1;
}

.popular-content h4 {
    margin: 0 0 0.5rem 0;
    font-size: 0.85rem;
    line-height: 1.3;
}

.popular-content h4 a {
    color: #2c3e50;
    text-decoration: none;
    transition: color 0.3s ease;
}

.popular-content h4 a:hover {
    color: #e74c3c;
}

.popular-meta {
    display: flex;
    gap: 1rem;
    font-size: 0.7rem;
    color: #6c757d;
}

.popular-meta span {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

/* Newsletter */
.newsletter p {
    color: #6c757d;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.newsletter-form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.newsletter-form input {
    padding: 0.75rem 1rem;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.newsletter-form input:focus {
    outline: none;
    border-color: #e74c3c;
    box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.1);
}

.newsletter-form button {
    padding: 0.75rem 1rem;
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    color: white;
    border: none;
    border-radius: 10px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.newsletter-form button:hover {
    background: linear-gradient(135deg, #c0392b, #a93226);
    transform: translateY(-2px);
}

/* WhatsApp Contact */
.whatsapp-contact p {
    color: #6c757d;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.whatsapp-btn-sidebar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.75rem 1rem;
    background: linear-gradient(135deg, #25d366, #128c7e);
    color: white;
    text-decoration: none;
    border-radius: 10px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.whatsapp-btn-sidebar:hover {
    background: linear-gradient(135deg, #128c7e, #075e54);
    transform: translateY(-2px);
    color: white;
}

.whatsapp-btn-sidebar i {
    font-size: 1.1rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .blog-sidebar {
        margin-bottom: 2rem;
    }
    
    .sidebar-section {
        padding: 1rem;
    }
    
    .article-image {
        height: 100px;
    }
    
    .article-meta {
        flex-direction: column;
        gap: 0.25rem;
    }
    
    .popular-item {
        gap: 0.75rem;
    }
    
    .popular-rank {
        width: 25px;
        height: 25px;
        font-size: 0.7rem;
    }
}

@media (max-width: 480px) {
    .search-box {
        flex-direction: column;
    }
    
    .search-box button {
        align-self: stretch;
    }
    
    .category-btn {
        padding: 0.5rem 0.75rem;
    }
    
    .article-info {
        padding: 0.75rem;
    }
}

/* Animation for loading */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.sidebar-section {
    animation: fadeInUp 0.6s ease forwards;
}

.sidebar-section:nth-child(1) { animation-delay: 0.1s; }
.sidebar-section:nth-child(2) { animation-delay: 0.2s; }
.sidebar-section:nth-child(3) { animation-delay: 0.3s; }
.sidebar-section:nth-child(4) { animation-delay: 0.4s; }
.sidebar-section:nth-child(5) { animation-delay: 0.5s; }
.sidebar-section:nth-child(6) { animation-delay: 0.6s; }

/* Scrollbar Styling */
.blog-sidebar::-webkit-scrollbar {
    width: 6px;
}

.blog-sidebar::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.blog-sidebar::-webkit-scrollbar-thumb {
    background: #e74c3c;
    border-radius: 3px;
}

.blog-sidebar::-webkit-scrollbar-thumb:hover {
    background: #c0392b;
}