/**
 * Most Viewed Posts Block Styles
 * @package beatrix
 */

.beatrix-most-viewed-posts-block {
    margin-bottom: 30px;
}

.beatrix-most-viewed-posts-block .beatrix-most-viewed-posts-title {
    font-family: var(--primary-font, "Anton", sans-serif);
    font-size: 24px;
    color: #ffffff !important;
    margin-bottom: 20px;
    letter-spacing: 0.5px;
}

.beatrix-most-viewed-posts-list {
    list-style: none !important;
    padding: 0;
    margin: 0;
}

.beatrix-most-viewed-post-item {
    display: flex;
    margin-bottom: 20px;
    padding-left: 0 !important;
    list-style: none !important;
    list-style-type: none !important;
}

.beatrix-most-viewed-post-item::before {
    display: none !important;
    content: none !important;
}

.beatrix-most-viewed-post-item:last-child {
    margin-bottom: 0;
}

.beatrix-most-viewed-post-item .post-thumbnail {
    flex-shrink: 0;
    margin-right: 15px;
}

.beatrix-most-viewed-post-item .post-thumbnail a {
    display: block;
    overflow: hidden;
    border-radius: 4px;
}

.beatrix-most-viewed-post-item .post-thumbnail img {
    width: 96px;
    height: 96px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.beatrix-most-viewed-post-item .post-thumbnail a:hover img {
    transform: scale(1.1);
}

.beatrix-most-viewed-post-item .post-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.beatrix-most-viewed-post-item .post-content a {
    color: #ffffff;
    font-family: var(--primary-font, "Anton", sans-serif);
    font-size: 16px;
    line-height: 1.4;
    text-decoration: none;
    margin-bottom: 8px;
    display: inline-block;
    transition: color 0.3s ease;
}

.beatrix-most-viewed-post-item .post-content a:hover {
    color: var(--primary-color, #3CFFD0);
}

.beatrix-most-viewed-post-item .post-author {
    display: block;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 5px;
    font-family: var(--secondary-font, "Poppins", sans-serif);
}

.beatrix-most-viewed-post-item .post-date {
    display: block;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 5px;
    font-family: var(--secondary-font, "Poppins", sans-serif);
}

.beatrix-most-viewed-post-item .post-views {
    display: inline-flex;
    align-items: center;
    font-size: 12px;
    color: var(--primary-color, #3CFFD0);
    font-family: var(--secondary-font, "Poppins", sans-serif);
    font-weight: 500;
}

.beatrix-most-viewed-post-item .post-views i {
    margin-right: 5px;
    font-size: 14px;
}

/* Error message styling */
.beatrix-most-viewed-posts-block-error {
    padding: 15px;
    background-color: rgba(255, 0, 0, 0.1);
    border: 1px solid rgba(255, 0, 0, 0.3);
    border-radius: 4px;
    color: #ff0000;
    font-family: var(--secondary-font, "Poppins", sans-serif);
}

/* Editor preview styling */
.beatrix-most-viewed-posts-editor-preview {
    min-height: 200px;
    padding: 20px;
    background-color: rgba(0, 0, 0, 0.02);
    border-radius: 4px;
}

/* Light mode support - when body has 'likhun-dark' class (light background) */
body.likhun-dark .beatrix-most-viewed-posts-block .beatrix-most-viewed-posts-title {
    color: #000000 !important;
}

body.likhun-dark .beatrix-most-viewed-post-item .post-content a {
    color: #000000 !important;
}

body.likhun-dark .beatrix-most-viewed-post-item .post-content a:hover {
    color: var(--primary-color, #3CFFD0) !important;
}

body.likhun-dark .beatrix-most-viewed-post-item .post-author {
    color: rgba(0, 0, 0, 0.7) !important;
}

body.likhun-dark .beatrix-most-viewed-post-item .post-date {
    color: rgba(0, 0, 0, 0.6) !important;
}

/* Responsive */
@media (max-width: 767px) {
    .beatrix-most-viewed-posts-title {
        font-size: 20px;
    }

    .beatrix-most-viewed-post-item .post-thumbnail img {
        width: 80px;
        height: 80px;
    }

    .beatrix-most-viewed-post-item .post-content a {
        font-size: 14px;
    }
}
