/* ============================================================
   同城约 · TONGCHENG YUE — 版式参考 teriteri / B 站首页骨架
   顶栏 + 头图 + 频道条 + 轮播(2×2) + 卡片墙 + 右侧换一换
   ============================================================ */

/* ── 主题变量 ───────────────────────────── */
:root {
    --layout-padding: 60px;
    --max-w: 1980px;

    --bg1: #ffffff;
    --bg1_float: #ffffff;
    --bg2: #f6f7f8;
    --text1: #18191c;
    --text2: #61666d;
    --text3: #9499a0;
    --text4: #c9ccd0;
    --line_light: #f1f2f3;
    --line_regular: #e3e5e7;
    --graph_bg_thin: #f6f7f8;
    --graph_bg_regular: #f1f2f3;
    --graph_bg_thick: #e3e5e7;
    --brand: #fb7299;
    --brand_hover: #ff8cb0;
    --brand_thin: #ffeef3;
    --shadow: 0 2px 4px rgba(0, 0, 0, .08);
    --radius: 6px;
    --radius_md: 8px;
    --banner_c1: #23222d;
    --banner_c2: #3a2740;
    --banner_c3: #4a2b33;
    --banner_txt: #ffffff;
}

[data-theme="dark"] {
    --bg1: #121216;
    --bg1_float: #17171c;
    --bg2: #1b1b21;
    --text1: #e9e9ec;
    --text2: #a7adb8;
    --text3: #767c87;
    --text4: #4a4f58;
    --line_light: #22222a;
    --line_regular: #2b2b34;
    --graph_bg_thin: #1c1c23;
    --graph_bg_regular: #232329;
    --graph_bg_thick: #2c2c35;
    --brand_thin: #3a1f2b;
    --shadow: 0 2px 4px rgba(0, 0, 0, .5);
    --banner_c1: #0f0f13;
    --banner_c2: #241a2b;
    --banner_c3: #33202a;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html, body {
    margin: 0;
    padding: 0;
    background: var(--bg1);
    color: var(--text1);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB",
        "Microsoft YaHei", "Helvetica Neue", Helvetica, Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    -webkit-tap-highlight-color: transparent;
}

body { min-width: 320px; overflow-x: hidden; }

a { color: inherit; text-decoration: none; }
button { font-family: inherit; border: 0; background: none; color: inherit; cursor: pointer; padding: 0; }
img { border: 0; }
input { font-family: inherit; }
::selection { background: var(--brand); color: #fff; }

/* 滚动条 */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-thumb { background: var(--graph_bg_thick); border-radius: 4px; }
::-webkit-scrollbar-track { background: transparent; }

/* ── 18+ 门槛 ───────────────────────────── */
.gate {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: radial-gradient(120% 120% at 50% 0%, #2a1f2e 0%, #0b0b0f 70%);
    transition: opacity .25s ease;
}
.gate.out { opacity: 0; pointer-events: none; }
.gate-box {
    width: 100%;
    max-width: 460px;
    padding: 32px 26px 26px;
    border-radius: 14px;
    background: #16161b;
    border: 1px solid #2b2b34;
    text-align: center;
    color: #e9e9ec;
}
.gate-age {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 100px;
    background: var(--brand);
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1px;
}
.gate-box h2 { margin: 14px 0 10px; font-size: 20px; font-weight: 700; }
.gate-box p { margin: 0 0 22px; font-size: 13px; line-height: 1.75; color: #a7adb8; }
.gate-btns { display: flex; flex-direction: column; gap: 12px; }
.gate-ok {
    height: 44px;
    border-radius: 8px;
    background: var(--brand);
    color: #fff;
    font-size: 15px;
    font-weight: 600;
}
.gate-ok:hover { background: var(--brand_hover); }
.gate-no { font-size: 13px; color: #767c87; }
.gate-no:hover { color: #a7adb8; }

/* ── 顶栏 ───────────────────────────────── */
.header-bar {
    position: absolute;
    left: 0;
    top: 0;
    z-index: 1002;
    width: 100%;
    height: 64px;
    padding: 0 24px;
    color: var(--banner_txt);
    transition: background-color .25s, box-shadow .25s, color .25s;
}
.header-bar__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
    max-width: 2560px;
    margin: 0 auto;
}
.header-bar.slide-down {
    position: fixed;
    background: var(--bg1_float);
    color: var(--text1);
    box-shadow: var(--shadow);
}

.hb-left { display: flex; align-items: center; flex-shrink: 0; margin-right: 20px; }
.logo { display: flex; align-items: center; margin-right: 14px; }
.logo-mark {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    margin-right: 7px;
    color: #fff;
    background: var(--brand);
    border-radius: 9px;
}
.logo-mark svg { width: 18px; height: 18px; }
.logo-txt { display: flex; flex-direction: column; line-height: 1.1; }
.logo-txt b { font-size: 17px; letter-spacing: 2px; font-weight: 700; }
.logo-txt i { font-size: 9px; letter-spacing: 1.6px; font-style: normal; opacity: .65; }

.entry-nav { display: flex; align-items: center; }
.entry-link {
    display: inline-flex;
    align-items: center;
    height: 64px;
    padding: 0 12px;
    font-size: 14px;
    color: inherit;
    opacity: .92;
    transition: color .2s, opacity .2s;
}
.entry-link:hover { color: var(--brand_hover); opacity: 1; }
.header-bar.slide-down .entry-link:hover { color: var(--brand); }
.entry-link.is-on { font-weight: 600; opacity: 1; }
.entry-more .arrow-ico { width: 14px; height: 14px; margin-left: 3px; }
.entry-more.is-open .arrow-ico { transform: rotate(180deg); }

.center-search { position: relative; flex: 1 1 auto; height: 40px; }
.nav-search {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
    min-width: 160px;
    max-width: 500px;
    height: 40px;
    margin: 0 auto;
    padding: 0 48px 0 14px;
    border: 1px solid var(--line_regular);
    border-radius: 8px;
    background-color: rgba(255, 255, 255, .16);
    backdrop-filter: blur(6px);
    transition: background-color .25s, border-color .25s;
}
.nav-search:hover,
.nav-search:focus-within { background-color: var(--bg1); border-color: var(--line_regular); }
.header-bar.slide-down .nav-search { background-color: var(--graph_bg_regular); }
.header-bar.slide-down .nav-search:focus-within { background-color: var(--graph_bg_regular); }
.nav-search-input {
    flex: 1;
    height: 100%;
    min-width: 0;
    border: 0;
    outline: 0;
    background: transparent;
    font-size: 14px;
    color: var(--text1);
}
.nav-search-input::placeholder { color: var(--text3); }
.nav-search-input::-webkit-search-cancel-button { display: none; }
.nav-search-clean {
    position: absolute;
    right: 52px;
    display: flex;
    width: 18px;
    height: 18px;
    color: var(--text3);
}
.nav-search-clean svg { width: 100%; height: 100%; }
.nav-search-clean:hover { color: var(--text1); }
.nav-search-btn {
    position: absolute;
    right: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 6px;
    color: var(--text2);
    transition: background-color .2s, color .2s;
}
.nav-search-btn svg { width: 17px; height: 17px; }
.nav-search-btn:hover { background: var(--graph_bg_thick); color: var(--text1); }

.search-panel {
    position: absolute;
    z-index: 1003;
    width: 100%;
    max-width: 500px;
    max-height: 480px;
    margin: 0 auto;
    left: 0;
    right: 0;
    overflow-y: auto;
    background: var(--bg1);
    border: 1px solid var(--line_regular);
    border-top: 0;
    border-radius: 0 0 8px 8px;
    padding: 12px 0 16px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .12);
}
.sp-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
    height: 24px;
}
.sp-title { font-size: 14px; color: var(--text1); }
.sp-clear { font-size: 12px; color: var(--text3); cursor: pointer; }
.sp-clear:hover { color: var(--text2); }
.sp-tags { display: flex; flex-wrap: wrap; gap: 8px; padding: 12px 16px 0; }
.sp-tag {
    height: 28px;
    padding: 0 12px;
    border-radius: 6px;
    background: var(--graph_bg_thin);
    color: var(--text2);
    font-size: 13px;
    line-height: 28px;
    cursor: pointer;
    transition: background .2s, color .2s;
}
.sp-tag:hover { background: var(--graph_bg_thick); color: var(--text1); }

.hb-right { display: flex; align-items: center; gap: 12px; flex-shrink: 0; margin-left: 16px; }
.icon-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 8px;
    transition: background .2s;
}
.icon-btn:hover { background: rgba(128, 128, 128, .18); }
.icon-btn svg { width: 18px; height: 18px; }
.icon-btn .ico-sun { display: none; }
[data-theme="dark"] .icon-btn .ico-sun { display: block; }
[data-theme="dark"] .icon-btn .ico-moon { display: none; }

.age-pill {
    padding: 2px 8px;
    border-radius: 100px;
    border: 1px solid currentColor;
    font-size: 11px;
    font-weight: 700;
    opacity: .75;
    letter-spacing: .5px;
}
.avatar-box {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: linear-gradient(135deg, #fb7299, #a76ee8);
    color: #fff;
    font-size: 13px;
    font-weight: 600;
}

/* ── 头图 ───────────────────────────────── */
.banner {
    position: relative;
    z-index: 0;
    width: 100%;
    height: 9.375vw;
    min-height: 155px;
    max-height: 240px;
    overflow: hidden;
    background: linear-gradient(115deg, var(--banner_c1) 0%, var(--banner_c2) 55%, var(--banner_c3) 100%);
}
.banner-fx { position: absolute; inset: 0; overflow: hidden; }
.banner-fx .fx {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: .55;
}
.fx-1 { width: 420px; height: 420px; left: -80px; top: -160px; background: #7b3aa8; }
.fx-2 { width: 380px; height: 380px; right: 6%; top: -120px; background: #c2436a; opacity: .45; }
.fx-3 { width: 300px; height: 300px; left: 42%; bottom: -180px; background: #3a5ec2; opacity: .35; }
.banner::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image: radial-gradient(rgba(255, 255, 255, .06) 1px, transparent 1px);
    background-size: 4px 4px;
    opacity: .5;
}
.banner-inner {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    width: 100%;
    max-width: calc(var(--max-w) + 2 * var(--layout-padding));
    height: 100%;
    margin: 0 auto;
    padding: 0 var(--layout-padding) 26px;
    color: #fff;
}
.banner-logo { display: flex; align-items: center; }
.bl-mark {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    margin-right: 14px;
    border-radius: 14px;
    background: rgba(255, 255, 255, .12);
    border: 1px solid rgba(255, 255, 255, .2);
    backdrop-filter: blur(6px);
}
.bl-mark svg { width: 28px; height: 28px; }
.bl-txt { display: flex; flex-direction: column; }
.bl-txt b { font-size: 33px; line-height: 1.1; letter-spacing: 1.5px; font-weight: 800; text-shadow: 0 3px 18px rgba(0, 0, 0, .5); }
.bl-txt i {
    margin-top: 7px;
    font-size: 12px;
    font-style: normal;
    letter-spacing: 1.5px;
    opacity: .8;
}
.banner-sub { margin: 0 0 6px; font-size: 13px; letter-spacing: 1px; opacity: .72; }
.taper-line {
    position: absolute;
    left: 0;
    top: 0;
    z-index: 1;
    width: 100%;
    height: 100px;
    background: linear-gradient(rgba(0, 0, 0, .45), transparent);
    pointer-events: none;
}

/* ── 频道条 ─────────────────────────────── */
.header-channel {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
    max-width: calc(var(--max-w) + 2 * var(--layout-padding));
    min-height: 100px;
    margin: 0 auto;
    padding: 0 var(--layout-padding);
    background: var(--bg1);
}
.channel-icons { display: flex; align-items: center; margin-right: 20px; flex-shrink: 0; }
.channel-icons__item {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-right: 24px;
    color: var(--text1);
}
.channel-icons__item:last-child { margin-right: 0; }
.icon-bg {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    margin-bottom: 6px;
    border-radius: 50%;
    color: #fff;
    transition: background-color .3s, transform .2s;
}
.icon-bg svg { width: 24px; height: 24px; }
.icon-bg__dynamic { background: #48cc69; }
.channel-icons__item:hover .icon-bg__dynamic { background: #6eda89; }
.icon-bg__popular { background: #f07775; }
.channel-icons__item:hover .icon-bg__popular { background: #eb908f; }
.channel-icons__item:hover .icon-bg { transform: translateY(-2px); }
.icon-title { font-size: 14px; line-height: 20px; text-align: center; }

.channel-items {
    display: grid;
    flex: 1;
    grid-auto-flow: column;
    grid-template-rows: repeat(2, 1fr);
    grid-template-columns: repeat(11, 1fr);
    gap: 10px;
    padding-right: 30px;
    max-height: 60px;
    overflow: hidden;
    transition: max-height .25s ease;
}
.channel-items.is-open { max-height: 130px; }
.channel-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 26px;
    padding: 0 4px;
    border: 1px solid var(--line_light);
    border-radius: 6px;
    background: var(--graph_bg_thin);
    color: var(--text2);
    font-size: 14px;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: background-color .25s, color .25s, border-color .25s;
}
.channel-link:hover { background: var(--graph_bg_thick); color: var(--text1); }
.channel-link.is-on {
    background: var(--brand_thin);
    border-color: var(--brand);
    color: var(--brand);
    font-weight: 600;
}
.channel-entry-more {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    margin-left: 6px;
    border-radius: 4px;
    color: var(--text2);
    transition: background .2s;
}
.channel-entry-more:hover { background: var(--graph_bg_thick); }
.channel-entry-more .arrow-ico { width: 16px; height: 16px; transition: transform .25s; }
.channel-entry-more.is-open .arrow-ico { transform: rotate(180deg); }

/* ── 主体网格 ───────────────────────────── */
.main__layout {
    position: relative;
    width: 100%;
    max-width: calc(var(--max-w) + 2 * var(--layout-padding));
    margin: 0 auto;
    padding: 0 var(--layout-padding);
    background: var(--bg1);
}
.recommended-container { position: relative; padding-bottom: 40px; }

.container {
    position: relative;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 20px;
    width: 100%;
}
.container > .sec-hd { margin-bottom: 4px; }

/* 轮播占 2×2 */
.recommended-swipe {
    position: relative;
    grid-column: 1 / 3;
    grid-row: 1 / 3;
    min-height: 0;
}
.recommended-swipe-body {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--graph_bg_regular);
}

/* 分类/搜索时的标题行 */
.sec-hd {
    display: flex;
    align-items: baseline;
    gap: 12px;
    grid-column: 1 / -1;
    padding: 4px 0 2px;
}
.sec-hd h2 { margin: 0; font-size: 20px; font-weight: 700; letter-spacing: .5px; }
.sec-hd .meta { font-size: 12px; color: var(--text3); }
.sec-hd .sec-line { flex: 1; height: 1px; background: var(--line_light); align-self: center; }

/* ── 视频卡片 ───────────────────────────── */
.video-card {
    position: relative;
    --title-font-size: 15px;
    --title-line-height: 22px;
    --subtitle-font-size: 13px;
    --subtitle-line-height: 17px;
    --info-margin-top: 8px;
    --cover-radio: 56.25%;
}
.video-card__wrap { position: relative; display: flex; flex-direction: column; }
.feed-card { position: relative; cursor: pointer; }
.feed-card:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; border-radius: 8px; }

.video-card__image { position: relative; border-radius: var(--radius); }
.video-card__image--wrap {
    position: relative;
    padding-top: var(--cover-radio);
    border-radius: inherit;
    background: var(--graph_bg_regular);
    cursor: pointer;
    overflow: hidden;
}
.video-card__cover {
    position: absolute;
    inset: 0;
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--graph_bg_regular);
}
.video-card__cover img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: transform .35s ease, opacity .35s ease;
}
.video-card__cover img.in { opacity: 1; }
.video-card__cover.is-broken {
    background:
        radial-gradient(120% 120% at 20% 0%, #3a2740 0%, #1b1b22 70%),
        var(--graph_bg_regular);
}
.video-card__cover.is-broken::after {
    content: "同城约";
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, .34);
    font-size: 15px;
    letter-spacing: 6px;
}
.feed-card .video-card__cover.is-broken img { display: none; }
.video-card:hover .video-card__cover img { transform: scale(1.04); }

.video-card__mask { position: absolute; inset: 0; pointer-events: none; }
.video-card__stats {
    position: absolute;
    left: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    height: 38px;
    padding: 16px 8px 6px;
    border-radius: 0 0 var(--radius) var(--radius);
    background-image: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, .8) 100%);
    color: #fff;
    font-size: var(--subtitle-font-size);
    line-height: 18px;
}
.video-card__stats--left { display: flex; align-items: center; min-width: 0; flex: 1; }
.video-card__stats--item { display: flex; align-items: center; margin-right: 10px; min-width: 0; }
.video-card__stats--item svg { width: 14px; height: 14px; margin-right: 3px; flex-shrink: 0; }
.video-card__stats--text { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.video-card__stats__duration {
    flex-shrink: 0;
    max-width: 50%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.video-card__info { margin-top: var(--info-margin-top); min-width: 0; }
.video-card__info--tit {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin: 0;
    padding-right: 8px;
    height: calc(2 * var(--title-line-height));
    font-size: var(--title-font-size);
    line-height: var(--title-line-height);
    font-weight: 500;
    color: var(--text1);
    word-break: break-word;
    line-break: anywhere;
    cursor: pointer;
}
.video-card:hover .video-card__info--tit { color: var(--brand); }
.video-card__info--bottom {
    display: flex;
    align-items: center;
    margin-top: 4px;
    color: var(--text3);
    font-size: var(--subtitle-font-size);
    line-height: var(--subtitle-line-height);
}
.video-card__info--bottom svg { width: 14px; height: 14px; margin-right: 4px; flex-shrink: 0; }
.video-card__info--author {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.video-card__info--date { margin-left: 4px; flex-shrink: 0; }
.vc-km { font-weight: 600; color: var(--brand); }

/* 骨架屏 */
.sk-card { position: relative; }
.sk-cover {
    padding-top: 56.25%;
    border-radius: var(--radius);
    background: linear-gradient(-45deg, var(--graph_bg_regular) 25%, var(--bg1) 45%, var(--graph_bg_regular) 65%);
    background-size: 400% 100%;
    animation: skeleton-loading 1.2s ease-in-out infinite;
}
.sk-line {
    height: 14px;
    margin-top: 10px;
    border-radius: 4px;
    background: linear-gradient(-45deg, var(--graph_bg_regular) 25%, var(--bg1) 45%, var(--graph_bg_regular) 65%);
    background-size: 400% 100%;
    animation: skeleton-loading 1.2s ease-in-out infinite;
}
.sk-line.short { width: 60%; }
@keyframes skeleton-loading {
    0% { background-position: 100% 50%; }
    100% { background-position: 0 50%; }
}

/* ── 轮播 ───────────────────────────────── */
.carousel-area { position: relative; width: 100%; height: 100%; background: #111; }
.carousel-track { position: absolute; inset: 0; }
.carousel-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity .5s ease;
    background-size: cover;
    background-position: center;
    cursor: pointer;
}
.carousel-slide.is-on { opacity: 1; }
.carousel-slide::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0, 0, 0, .18) 0%, rgba(0, 0, 0, 0) 38%, rgba(0, 0, 0, .78) 100%);
}
.carousel-cap {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2;
    padding: 0 20px 22px;
    color: #fff;
}
.carousel-cap h3 {
    margin: 0;
    font-size: 19px;
    font-weight: 600;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-shadow: 0 2px 12px rgba(0, 0, 0, .6);
}
.carousel-cap .cap-sub {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 8px;
    font-size: 12px;
    opacity: .82;
}
.cap-tag {
    padding: 2px 8px;
    border-radius: 4px;
    background: var(--brand);
    color: #fff;
    font-size: 11px;
    font-weight: 600;
}
.carousel-nav {
    position: absolute;
    right: 14px;
    bottom: 16px;
    z-index: 3;
    display: flex;
    gap: 6px;
}
.carousel-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .45);
    transition: width .25s, background .25s;
}
.carousel-dot.is-on { width: 18px; border-radius: 4px; background: #fff; }
.carousel-arrow {
    position: absolute;
    top: 50%;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    margin-top: -17px;
    border-radius: 50%;
    background: rgba(0, 0, 0, .34);
    color: #fff;
    opacity: 0;
    transition: opacity .25s, background .2s;
}
.carousel-arrow svg { width: 18px; height: 18px; }
.carousel-arrow:hover { background: rgba(0, 0, 0, .6); }
.carousel-area:hover .carousel-arrow { opacity: 1; }
.carousel-arrow.prev { left: 12px; }
.carousel-arrow.next { right: 12px; }
@media (hover: none) {
    .carousel-arrow { display: none; }
}

#feed.is-fading { opacity: .35; transition: opacity .2s; }

/* ── 换一换 ─────────────────────────────── */
.feed-roll-btn {
    position: absolute;
    top: 0;
    right: calc(-1 * var(--layout-padding) + 4px);
    z-index: 2;
}
.roll-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 36px;
    padding: 9px 4px;
    border: 1px solid var(--line_regular);
    border-radius: 8px;
    background: var(--bg1);
    color: var(--text1);
    font-size: 12px;
    line-height: 1.15;
    text-align: center;
    transition: background .2s;
}
.roll-btn:hover { background: var(--graph_bg_thick); }
.roll-ico { width: 16px; height: 16px; margin-bottom: 6px; transition: transform .5s ease; }

/* ── 加载更多 / 状态 ─────────────────────── */
.load-more-wrap { display: flex; justify-content: center; padding: 36px 0 56px; }
.load-more {
    min-width: 180px;
    height: 40px;
    padding: 0 26px;
    border: 1px solid var(--line_regular);
    border-radius: 8px;
    background: var(--graph_bg_thin);
    color: var(--text2);
    font-size: 14px;
    transition: background .2s, color .2s;
}
.load-more:hover { background: var(--graph_bg_thick); color: var(--text1); }
.end-line { font-size: 13px; color: var(--text3); letter-spacing: .5px; }

.state {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 70px 20px;
    color: var(--text3);
}
.state svg { width: 42px; height: 42px; margin-bottom: 14px; opacity: .7; }
.state p { margin: 0 0 6px; font-size: 16px; color: var(--text2); }
.state small { font-size: 13px; }

/* ── 页脚 ───────────────────────────────── */
.ft {
    border-top: 1px solid var(--line_light);
    background: var(--bg2);
}
.ft-in {
    max-width: calc(var(--max-w) + 2 * var(--layout-padding));
    margin: 0 auto;
    padding: 28px var(--layout-padding) 40px;
}
.ft-top { display: flex; align-items: center; gap: 10px; }
.ft-brand { font-size: 14px; font-weight: 600; letter-spacing: 1px; color: var(--text1); }
.ft-age {
    padding: 1px 7px;
    border-radius: 100px;
    border: 1px solid var(--text3);
    font-size: 10px;
    font-weight: 700;
    color: var(--text3);
}
.ft-note { margin: 10px 0 0; font-size: 12px; line-height: 1.8; color: var(--text3); }
.ft-mirrors { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 14px; }
.ft-mirror-lb { font-size: 12px; color: var(--text3); }
.ft-mirrors a {
    padding: 4px 10px;
    border: 1px solid var(--line_regular);
    border-radius: 6px;
    font-size: 12px;
    color: var(--text2);
}
.ft-mirrors a:hover { color: var(--brand); border-color: var(--brand); }

/* ── 镜像提示条 ─────────────────────────── */
.mtip {
    position: fixed;
    left: 50%;
    bottom: 20px;
    z-index: 9000;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: 8px;
    background: rgba(24, 24, 28, .94);
    color: #fff;
    font-size: 13px;
    transform: translateX(-50%);
    box-shadow: 0 6px 24px rgba(0, 0, 0, .3);
}
.mtip a { color: var(--brand); font-weight: 600; }
.mtip button { color: #999; font-size: 16px; line-height: 1; }

/* ── 播放浮层 ───────────────────────────── */
.player-mask {
    position: fixed;
    inset: 0;
    z-index: 5000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(0, 0, 0, .82);
    backdrop-filter: blur(3px);
}
.player-mask[hidden] { display: none; }
.player-box {
    width: 100%;
    max-width: 1080px;
    max-height: 100%;
    overflow-y: auto;
    border-radius: 10px;
    background: #14141a;
    color: #e9e9ec;
    box-shadow: 0 20px 60px rgba(0, 0, 0, .5);
}
.player-stage {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000;
    overflow: hidden;
    border-radius: 10px 10px 0 0;
}
.player-stage video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #000;
    transition: transform .3s ease;
}
.player-stage.crop video { transform: scale(1.08); }
.pclose {
    position: absolute;
    top: 10px;
    right: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(0, 0, 0, .55);
    color: #fff;
    transition: background .2s;
}
.pclose svg { width: 16px; height: 16px; }
.pclose:hover { background: rgba(0, 0, 0, .8); }
.ptip {
    position: absolute;
    left: 12px;
    bottom: 58px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 12px;
    border-radius: 6px;
    background: rgba(0, 0, 0, .72);
    color: #ddd;
    font-size: 12px;
}
.ptip button {
    height: 24px;
    padding: 0 9px;
    border-radius: 4px;
    background: var(--brand);
    color: #fff;
    font-size: 12px;
}
.ptip button#ptipBack { background: rgba(255, 255, 255, .16); }
.pfall {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 20px;
    background: #0b0b0f;
    text-align: center;
}
.pfall svg { width: 38px; height: 38px; color: #8b8f99; }
.pfall p { margin: 4px 0 0; font-size: 15px; color: #e9e9ec; }
.pfall small { font-size: 12px; color: #8b8f99; }
.pf-btns { display: flex; gap: 10px; margin-top: 12px; }
.pf-btns button, .pf-btns a {
    height: 32px;
    padding: 0 14px;
    border-radius: 6px;
    background: var(--brand);
    color: #fff;
    font-size: 13px;
    line-height: 32px;
}
.pf-btns a { background: rgba(255, 255, 255, .14); }
.player-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 14px 18px 6px;
}
.player-info h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.4;
    color: #f2f2f5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.player-tools { display: flex; gap: 8px; flex-shrink: 0; }
.ptool {
    height: 30px;
    padding: 0 12px;
    border: 1px solid #33333d;
    border-radius: 6px;
    color: #a7adb8;
    font-size: 13px;
    transition: all .2s;
}
.ptool:hover { color: #e9e9ec; border-color: #4a4a56; }
.ptool.on { background: var(--brand); border-color: var(--brand); color: #fff; }
.eps {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 8px 18px 18px;
    max-height: 150px;
    overflow-y: auto;
}
.eps:empty { display: none; }
.ep {
    height: 30px;
    padding: 0 12px;
    border: 1px solid #2c2c35;
    border-radius: 6px;
    background: #1b1b22;
    color: #a7adb8;
    font-size: 13px;
    max-width: 180px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    transition: all .2s;
}
.ep:hover { color: #e9e9ec; border-color: #4a4a56; }
.ep.on { background: var(--brand); border-color: var(--brand); color: #fff; }

/* ── 响应式 ─────────────────────────────── */
@media (max-width: 1700px) {
    :root { --layout-padding: 40px; }
    .channel-items { grid-template-columns: repeat(9, 1fr); }
}
@media (max-width: 1400px) {
    .container { grid-template-columns: repeat(4, 1fr); }

}
@media (max-width: 1200px) {
    :root { --layout-padding: 24px; }
    .feed-roll-btn { display: none; }
    .entry-nav .entry-link { padding: 0 9px; font-size: 13px; }
    .banner-sub { display: none; }
}
@media (max-width: 1024px) {
    .container { grid-template-columns: repeat(3, 1fr); }
    .bl-txt b { font-size: 26px; letter-spacing: 1px; }
    .header-channel { min-height: 84px; }
    .channel-icons__item { margin-right: 16px; }
    .icon-bg { width: 40px; height: 40px; }
    .icon-bg svg { width: 21px; height: 21px; }
    .icon-title { font-size: 13px; }
    .channel-items { grid-template-columns: repeat(6, 1fr); }
    .feed-roll-btn { display: none; }
}
@media (max-width: 768px) {
    :root { --layout-padding: 12px; }
    .header-bar { padding: 0 12px; height: 56px; }
    .entry-nav { display: none; }
    .logo-txt b { font-size: 15px; }
    .logo-txt i { display: none; }
    .logo-mark { width: 26px; height: 26px; border-radius: 7px; }
    .logo-mark svg { width: 16px; height: 16px; }
    .center-search { min-width: 0; height: 36px; }
    .nav-search { min-width: 0; height: 36px; max-width: none; padding-left: 10px; }
    .hb-left { margin-right: 8px; }
    .hb-right { margin-left: 8px; gap: 8px; }
    .logo { margin-right: 6px; }
    .header-bar__inner { min-width: 0; }
    .nav-search-input { font-size: 13px; }
    .age-pill { display: none; }
    .avatar-box { width: 30px; height: 30px; font-size: 12px; }
    .icon-btn { width: 30px; height: 30px; }
    .banner { min-height: 108px; height: 30vw; }
    .banner-inner { padding: 0 12px 14px; }
    .bl-mark { width: 38px; height: 38px; border-radius: 10px; margin-right: 10px; }
    .bl-mark svg { width: 21px; height: 21px; }
    .bl-txt b { font-size: 20px; letter-spacing: .3px; }
    .bl-txt i { font-size: 10px; letter-spacing: .3px; margin-top: 4px; }
    .header-channel { min-height: auto; padding: 10px 12px 0; flex-wrap: wrap; }
    .channel-icons { margin-right: 10px; }
    .channel-icons__item { margin-right: 12px; }
    .icon-bg { width: 34px; height: 34px; margin-bottom: 4px; }
    .icon-bg svg { width: 18px; height: 18px; }
    .icon-title { font-size: 11px; line-height: 15px; }
    .channel-items {
        display: flex;
        flex: 1 0 100%;
        margin-top: 6px;
        gap: 8px;
        padding: 0 0 10px;
        max-height: none;
        overflow-x: auto;
        overflow-y: hidden;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
    }
    .channel-items::-webkit-scrollbar { display: none; }
    .channel-items.is-open { max-height: none; }
    .channel-link { flex: 0 0 auto; width: auto; min-width: 56px; height: 28px; padding: 0 12px; font-size: 13px; }
    .channel-entry-more { display: none; }
    .container { grid-template-columns: repeat(2, 1fr); gap: 12px; }

    .recommended-swipe {
        grid-column: 1 / -1;
        grid-row: auto;
        aspect-ratio: 16 / 9;
    }
    .recommended-swipe-body { position: absolute; }
    .video-card { --title-font-size: 13px; --title-line-height: 19px; --subtitle-font-size: 11px; --subtitle-line-height: 15px; }
    .video-card__info--tit { padding-right: 0; }
    .video-card__stats { height: 32px; padding: 14px 6px 5px; font-size: 11px; }
    .carousel-cap { padding: 0 12px 14px; }
    .carousel-cap h3 { font-size: 14px; }
    .carousel-nav { right: 10px; bottom: 10px; }
    .sec-hd { padding: 2px 0 0; }
    .sec-hd h2 { font-size: 16px; }
    .load-more-wrap { padding: 24px 0 40px; }
    .ft-in { padding: 20px 12px 30px; }
    .player-mask { padding: 0; align-items: flex-end; }
    .player-box { max-width: none; border-radius: 12px 12px 0 0; max-height: 92vh; }
    .player-stage { border-radius: 12px 12px 0 0; }
    .player-info { padding: 12px 12px 4px; }
    .player-info h3 { font-size: 14px; }
    .eps { padding: 6px 12px 14px; }
    .ptip { left: 8px; bottom: 50px; font-size: 11px; padding: 6px 8px; }
}
@media (max-width: 380px) {
    .container { grid-template-columns: repeat(2, 1fr); gap: 10px; }
}

/* VIP 入口 */
.vip-entry {
    display: inline-flex; align-items: center; gap: 4px;
    padding: 5px 10px; border-radius: 999px;
    font-size: 12px; font-weight: 700; text-decoration: none;
    color: #8a5a12; background: linear-gradient(135deg, #f7dda6, #e8b463);
    white-space: nowrap;
}
.vip-entry svg { width: 14px; height: 14px; }
.vip-entry:hover { filter: brightness(1.05); }
@media (max-width: 640px) {
    .vip-entry { padding: 4px 7px; font-size: 11px; }
}

/* ── 搜索多词提示（按第一个词搜）── */
.kw-tip {
  font-size: 12px;
  color: var(--muted, #8d8d99);
  background: rgba(212, 175, 55, .12);
  border: 1px solid rgba(212, 175, 55, .28);
  color: #c8a44a;
  padding: 2px 8px;
  border-radius: 999px;
  margin-left: 10px;
  white-space: nowrap;
}

/* ── 加载失败重试 ── */
.state-retry {
  margin: 14px auto 0;
  display: block;
  padding: 9px 26px;
  border-radius: 999px;
  border: 1px solid rgba(212, 175, 55, .5);
  background: rgba(212, 175, 55, .1);
  color: #c8a44a;
  font-size: 14px;
  cursor: pointer;
}
.state-retry:hover { background: rgba(212, 175, 55, .2); }
