

body.page-home .grid,
.cb-grid,
.items-list {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 24px 16px;
    padding: 8px 16px 32px;
    max-width: none;
    margin: 0;
    background: transparent;
    word-break: break-word;
}

@media (min-width: 710px) {
    body.page-home .grid,
    .cb-grid {
        padding-left: 24px;
        padding-right: 24px;
    }
}

@media (max-width: 479px) {
    body.page-home .grid,
    .cb-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 16px 8px;
        padding: 8px 12px 24px;
    }
}

@media (min-width: 600px) and (max-width: 999px) {
    body.page-home .grid,
    .cb-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 24px 12px;
    }
}

@media (min-width: 1000px) {
    body.page-home .grid,
    .cb-grid {
        grid-template-columns: repeat(auto-fill, minmax(218px, 1fr));
        gap: 24px 16px;
    }
}

@media (min-width: 1400px) {
    body.page-home .grid,
    .cb-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    }
}

body.page-home .grid .card,
body.page-home .cb-item,
.cb-item {
    background: transparent !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    overflow: visible !important;
    display: flex;
    flex-direction: column;
    gap: 0;
    transition: none;
    position: relative;
    cursor: pointer;
    max-width: var(--default-max-item-width, 344px);
    width: 100%;
    margin-bottom: 0;
    vertical-align: top;
}

body.page-home .grid .card:hover,
.cb-item:hover {
    transform: none !important;
    background: transparent !important;
    border-color: transparent !important;
    box-shadow: none !important;
}

body.page-home .grid .card .thumb,
body.page-home .grid .card a.thumb,
body.page-home .cb-thumb,
.cb-thumb {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    padding-bottom: 0 !important;
    height: auto;
    border-radius: 0;
    overflow: hidden;
    background: var(--item-thumb-bg, #f5f5f5) center / cover no-repeat;
    text-decoration: none;
}

@media (min-width: 480px) {
    body.page-home .grid .card .thumb,
    body.page-home .grid .card a.thumb,
    body.page-home .cb-thumb,
    .cb-thumb {
        border-radius: 10px;
    }
}

body.page-home .grid .card .thumb img,
body.page-home .cb-thumb img,
.cb-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    border-radius: inherit;
    transition: none;
    pointer-events: none;
}

body.page-home .grid .card:hover .thumb img,
.cb-item:hover .cb-thumb img {
    transform: none;
}

body.page-home .grid .card .duration,
body.page-home .grid .card .thumb .duration,
body.page-home .cb-duration,
.cb-duration {
    position: absolute !important;
    right: 0 !important;
    bottom: 0 !important;
    left: auto !important;
    top: auto !important;
    margin: 4px !important;
    background: var(--item-duration-bg, hsl(0, 0%, 6.7%)) !important;
    color: var(--item-duration-fg, #fff) !important;
    font-size: 12px !important;
    font-weight: 500 !important;
    line-height: 13.5px !important;
    letter-spacing: 0.5px !important;
    padding: 2px 4px !important;
    border-radius: 2px !important;
    border: 0 !important;
    opacity: 0.8;
    z-index: 2;
    pointer-events: none;
    font-variant-numeric: tabular-nums;
}

body.page-home .grid .card .badge,
body.page-home .grid .card .vip-badge,
body.page-home .grid .card .badge-top,
body.page-home .cb-badge {
    position: absolute;
    top: 6px;
    left: 6px;
    z-index: 2;
    font-size: 11px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 2px;
    background: var(--accent);
    color: #fff;
    letter-spacing: 0.02em;
}

body.page-home .grid .card .info,
body.page-home .grid .card .card-body,
body.page-home .cb-meta,
.cb-meta {
    padding: 0 !important;
    background: transparent !important;
    display: block !important;
    flex: none !important;
    justify-content: flex-start !important;
}

body.page-home .grid .card .title,
body.page-home .grid .card h3,
body.page-home .grid .card .desc,
body.page-home .cb-title,
.cb-title {
    margin: 12px 0 6px !important;
    font-size: var(--item-title-font-size, 14px) !important;
    line-height: var(--item-title-line-height, 18px) !important;
    font-weight: 500 !important;
    color: var(--item-title-text, #111) !important;
    display: -webkit-box !important;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    overflow: hidden;
    text-decoration: none !important;
    min-height: 0 !important;
    max-height: calc(var(--item-title-max-lines, 2) * var(--item-title-line-height, 18px));
}

body.page-home .grid .card .title a,
body.page-home .grid .card .desc,
body.page-home .cb-title a {
    color: inherit !important;
    text-decoration: none !important;
}

body.page-home .grid .card .desc:hover {
    color: var(--text-primary) !important;
}

body.page-home .grid .card .meta-row,
body.page-home .grid .card .meta,
body.page-home .cb-sub {
    display: flex !important;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-start !important;
    gap: 0 4px;
    font-size: 13px !important;
    line-height: 18px !important;
    color: var(--item-meta-text, rgba(17, 17, 17, 0.6)) !important;
    border-top: 0 !important;
    padding-top: 0 !important;
    margin-top: 0 !important;
    font-family: Arial, sans-serif;
}

body.page-home .grid .card .u-tag {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px !important;
    color: var(--item-meta-text) !important;
    overflow: hidden;
    min-width: 0;
    flex: 1 1 auto;
}

body.page-home .grid .card .u-avt-small {
    width: 24px !important;
    height: 24px !important;
    border-radius: 50% !important;
    background-size: cover !important;
    background-position: center !important;
    flex-shrink: 0;
    background-color: rgba(0, 0, 0, 0.07);
}

body.page-home .grid .card .u-name {
    font-size: 13px !important;
    font-weight: 400 !important;
    color: var(--item-meta-text) !important;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

body.page-home .grid .card .u-name:hover {
    color: rgba(17, 17, 17, 0.85) !important;
}

body.page-home .grid .card .stats-tag {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 12px !important;
    color: var(--item-meta-text) !important;
    flex: 0 0 auto;
    margin-left: auto;
}

body.page-home .grid .card .stats-tag span {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    cursor: pointer;
    color: inherit;
}

body.page-home .grid .card .stats-tag span:hover {
    color: var(--text-primary);
}

body.page-home .grid .card .stats-tag .like-btn.active,
body.page-home .grid .card .stats-tag .fav-btn.active {
    color: var(--accent) !important;
}

body.page-home .grid .card .card-menu-wrap {
    position: absolute;
    top: 6px;
    right: 6px;
    z-index: 10;
}

body.page-home .grid .card .card-menu-btn {
    background: rgba(0, 0, 0, 0.65) !important;
    border: 0 !important;
    color: #fff !important;
    width: 28px !important;
    height: 28px !important;
    min-width: 28px !important;
    min-height: 28px !important;
    border-radius: 50% !important;
    opacity: 0;
    transition: opacity 0.15s ease;
}

body.page-home .grid .card:hover .card-menu-btn,
body.page-home .grid .card .card-menu-btn:focus {
    opacity: 1;
}

@media (hover: none) {
    body.page-home .grid .card .card-menu-btn {
        opacity: 1;
    }
}

body.page-home .cw-scroll,
body.page-home #cwScroll {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding: 4px 16px 16px;
    scroll-snap-type: x mandatory;
    scrollbar-width: thin;
}

@media (min-width: 710px) {
    body.page-home .cw-scroll,
    body.page-home #cwScroll {
        padding-left: 24px;
        padding-right: 24px;
    }
}

body.page-home .cw-scroll .card,
body.page-home .cw-scroll .cb-item {
    flex: 0 0 218px;
    max-width: 218px;
    scroll-snap-align: start;
}

body.page-home .tab-empty-state {
    text-align: center;
    padding: 80px 16px 32px;
    color: var(--text-secondary);
}

body.page-home .tab-empty-btn,
body.page-home .tab-empty-btn.primary {
    background: #0f0f0f !important;
    color: #fff !important;
    border-radius: 18px !important;
    border: 0 !important;
    height: 36px;
    padding: 0 16px;
    text-transform: none;
    font-weight: 500;
    letter-spacing: 0;
    box-shadow: none !important;
}
body.page-home .tab-empty-btn:hover,
body.page-home .tab-empty-btn.primary:hover {
    background: #272727 !important;
    color: #fff !important;
    transform: none !important;
}

body.page-home .scroll-sentinel,
body.page-home .scroll-end-msg {
    text-align: center;
    padding: 24px;
    color: var(--text-muted);
    font-size: 13px;
    font-weight: 500;
}

body.page-home .skeleton,
body.page-home .card.skeleton .thumb {
    background: linear-gradient(
        90deg,
        var(--skeleton-base) 25%,
        var(--skeleton-hl) 50%,
        var(--skeleton-base) 75%
    ) !important;
    background-size: 200% 100% !important;
    animation: cb-skel 1.2s ease-in-out infinite;
}

@keyframes cb-skel {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

@media (prefers-reduced-motion: reduce) {
    body.page-home .skeleton,
    body.page-home .card.skeleton .thumb {
        animation: none !important;
    }
}

body.page-home .grid .card [style*="f5c518"],
body.page-home .grid .card [style*="F5C518"] {
    color: var(--accent) !important;
}
