/* Tencent Video-inspired dark theme: blue-to-mint gradients on deep navy surfaces. */
:root {
    --qiyi-green: #00c9ff;
    --qiyi-green-hover: #15dcaf;
    --qiyi-page: #0b1020;
    --qiyi-surface: #141b2d;
    --qiyi-surface-raised: #202a42;
    --qiyi-border: #33415f;
    --qiyi-text: #f3f7ff;
    --qiyi-muted: #a3b1cc;
    --tencent-gradient: linear-gradient(135deg, #00b9ff 0%, #00d5ad 100%);
    --tencent-gradient-hover: linear-gradient(135deg, #1acaff 0%, #20e0b9 100%);
}

html,
body { background: var(--qiyi-page); color: var(--qiyi-text); }

.maomi-content, .video-box, .main-container, .player-detail .container .row { background: var(--qiyi-surface); }

a, h1, h2, h3, h4, h5, h6,
.details-play-title .nav-tabs > li.active > a,
.details-play-title .nav-tabs > li.active > a:focus,
.details-play-title .nav-tabs > li.active > a:hover,
.details-play-title .nav-tabs > li > a:hover,
.details-play-title .nav-tabs > li.open > a,
.details-play-title .dropdown-menu > li > a,
.dropdown-menu > li > a { color: var(--qiyi-text); }

a:hover, a:focus, a:visited, .row-item-content .item:hover a,
.film-operate .title a:hover, .ylinks ul li a, .yltitle h3,
.row table tr td a, .app li a { color: var(--qiyi-green); }

.c_red, .c_pink, .c_theme, .film-operate .remark { color: var(--qiyi-green); }
.c_default, .c_gray_blue, .row-item-content .item a { color: var(--qiyi-muted); }

.border_bootom { border-color: var(--qiyi-border); }
.border_bootom_default, .enter-content .btt-content, .enter-content .down-content { border-color: var(--qiyi-green); }

.bg_red, .box-title, .nav-row, .nav li, .scroll-mian ul li { background: var(--tencent-gradient); color: #061522; }
.bg_red .c_white, .box-title h3, .box-title .share_img { color: #061522 !important; }

.row-item.even, .row-item.odd, .first_title, .second_title, .film-operate .title { background: var(--qiyi-surface-raised); color: var(--qiyi-text); }
.film-operate .title a, .film-operate .content a { color: var(--qiyi-text); }
.film-operate .content a, .pagination a, .pagination em { background: #2a2a32; color: var(--qiyi-muted); }
.film-operate .content a:hover, .pagination a:hover, .pagination strong, .pagination .pagenow { background: var(--tencent-gradient); color: #061522; text-shadow: none; }

.video-box .content-list .content-item { border-color: var(--qiyi-border); }

.footer-container { background: #080d19; border-top: 1px solid var(--qiyi-border); color: var(--qiyi-muted); }
.footer-container a, .footer-container a:visited { color: var(--qiyi-text); }

.search-input { background: #202a42; border: 1px solid var(--qiyi-border); color: var(--qiyi-text); }
.search-button { background: var(--tencent-gradient); border-color: #00c9e2; color: #061522; }
.tag, .toplinks a, .navnav a { color: var(--qiyi-text); }

/* Link groups: fixed-size tiles, aligned across recommendations, partners and friend links. */
.toplinks,
.navnav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0;
}

.toplinks > div,
.navnav > div {
    flex: 0 0 100%;
}

.toplinks > div span,
.navnav > div span {
    color: var(--qiyi-green) !important;
    margin-left: 0 !important;
}

.toplinks a,
.navnav a {
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 128px;
    min-height: 34px;
    /* Margin provides row spacing even in browsers without flex-gap support. */
    margin: 0 4px 12px 0;
    padding: 4px 8px;
    overflow: hidden;
    border: 1px solid currentColor;
    border-radius: 4px;
    color: #fff !important;
    font-size: 14px;
    font-weight: 600;
    line-height: 18px;
    text-align: center;
    white-space: nowrap;
    text-overflow: ellipsis;
}

/* Calm blue/teal fallback palette; qiyi-links.js randomizes it on every page load. */
.toplinks a:nth-of-type(6n + 1), .navnav a:nth-of-type(6n + 1) { background: #1a5f8b; border-color: #3e7fa6; }
.toplinks a:nth-of-type(6n + 2), .navnav a:nth-of-type(6n + 2) { background: #176e70; border-color: #3d9291; }
.toplinks a:nth-of-type(6n + 3), .navnav a:nth-of-type(6n + 3) { background: #31569b; border-color: #5d7fc0; }
.toplinks a:nth-of-type(6n + 4), .navnav a:nth-of-type(6n + 4) { background: #286982; border-color: #5799af; }
.toplinks a:nth-of-type(6n + 5), .navnav a:nth-of-type(6n + 5) { background: #21745f; border-color: #4d9b80; }
.toplinks a:nth-of-type(6n), .navnav a:nth-of-type(6n) { background: #4a5489; border-color: #737daf; }

.toplinks a:hover,
.navnav a:hover {
    color: #fff !important;
    filter: brightness(1.14);
    transform: translateY(-1px);
}

@media (max-width: 520px) {
    .toplinks,
    .navnav { justify-content: space-between; }

    .toplinks a,
    .navnav a { width: calc((100% - 8px) / 3); min-height: 32px; margin: 0 0 10px; font-size: 13px; }
}
