/* =========================================================
   阿木电影测试 · 爱壹帆风格前端重制版
   说明：只重做前端视觉，不改变 PHP 接口、播放、静态链接规则。
   ========================================================= */

:root {
    --bg: #090b14;
    --bg2: #0f1424;
    --panel: rgba(18, 22, 35, .72);
    --panel-solid: #121623;
    --line: rgba(255, 255, 255, .08);
    --line2: rgba(255, 255, 255, .13);
    --text: #f8fbff;
    --sub: rgba(248, 251, 255, .72);
    --muted: rgba(248, 251, 255, .46);
    --blue: #24b8ff;
    --cyan: #28e2ff;
    --pink: #ff5fbc;
    --purple: #7d5cff;
    --green: #2ee7a8;
    --shadow: 0 18px 60px rgba(0, 0, 0, .45);
    --radius: 18px;
    --safe-bottom: env(safe-area-inset-bottom, 0px);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
    min-height: 100vh;
    background:
        radial-gradient(circle at 16% 10%, rgba(24, 187, 255, .13), transparent 28%),
        radial-gradient(circle at 84% 18%, rgba(141, 91, 255, .16), transparent 30%),
        linear-gradient(180deg, #070810 0%, #090b14 42%, #080912 100%);
    color: var(--text);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}
body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background-image:
        linear-gradient(rgba(255,255,255,.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.018) 1px, transparent 1px);
    background-size: 56px 56px;
    mask-image: linear-gradient(to bottom, rgba(0,0,0,.65), transparent 70%);
    z-index: -1;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button, input { font: inherit; }
button { cursor: pointer; border: 0; background: none; color: inherit; }
::selection { background: rgba(36, 184, 255, .32); color: #fff; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: #080912; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,.18); border-radius: 999px; }

/* Header */
.site-header {
    position: fixed;
    inset: 0 0 auto 0;
    z-index: 1000;
    background: linear-gradient(180deg, rgba(7, 8, 16, .86), rgba(7, 8, 16, .48) 72%, transparent);
    backdrop-filter: blur(0px);
    transition: background .25s ease, backdrop-filter .25s ease, border-color .25s ease;
}
.site-header.is-scrolled {
    background: rgba(8, 10, 18, .88);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border-bottom: 1px solid var(--line);
}
.header-inner {
    height: 72px;
    max-width: 1760px;
    margin: 0 auto;
    padding: 0 clamp(22px, 4vw, 68px);
    display: flex;
    align-items: center;
    gap: 34px;
}
.brand, .mobile-brand, .footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
    font-weight: 850;
    letter-spacing: .5px;
}
.brand { flex: 0 0 auto; font-size: 23px; }
.brand-mark {
    width: 30px;
    height: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: linear-gradient(135deg, #33d4ff 0%, #7c5cff 54%, #ff62b9 100%);
    box-shadow: 0 0 22px rgba(36, 184, 255, .34);
    color: #fff;
    flex: 0 0 auto;
}
.brand-mark i { font-size: 18px; }
.brand-text {
    background: linear-gradient(90deg, #fff 0%, #bdefff 42%, #f4d1ff 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    white-space: nowrap;
}
.main-nav {
    display: flex;
    align-items: center;
    gap: clamp(18px, 2.6vw, 36px);
    margin-left: auto;
    margin-right: auto;
}
.main-nav a {
    position: relative;
    padding: 22px 0 18px;
    color: rgba(238, 244, 255, .68);
    font-size: 16px;
    font-weight: 720;
    white-space: nowrap;
    transition: color .2s ease;
}
.main-nav a:hover, .main-nav a.active { color: #fff; }
.main-nav a.active::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 11px;
    width: 22px;
    height: 3px;
    border-radius: 99px;
    transform: translateX(-50%);
    background: linear-gradient(90deg, var(--blue), var(--pink));
    box-shadow: 0 0 18px rgba(36, 184, 255, .65);
}
.header-search {
    width: clamp(180px, 18vw, 290px);
    height: 42px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .09);
    border: 1px solid rgba(255, 255, 255, .12);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.05);
}
.header-search i { color: rgba(255,255,255,.58); font-size: 18px; }
.header-search input {
    width: 100%;
    min-width: 0;
    border: 0;
    outline: 0;
    background: transparent;
    color: #fff;
    font-size: 14px;
}
.header-search input::placeholder { color: rgba(255,255,255,.46); }
.header-actions { display: none; gap: 10px; }
.header-actions a {
    width: 38px;
    height: 38px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.1);
    color: rgba(255,255,255,.72);
}
.mobile-head, .mobile-nav { display: none; }

/* Layout */
.site-shell { min-height: 100vh; }
.page-wrap {
    width: min(100% - 48px, 1640px);
    margin: 0 auto;
    padding-top: 104px;
    padding-bottom: 56px;
}
.home-wrap { padding-top: 28px; }
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-bottom: 22px;
    color: var(--muted);
    font-size: 14px;
    flex-wrap: wrap;
}
.breadcrumb a { color: var(--sub); transition: color .2s ease; }
.breadcrumb a:hover { color: #fff; }
.breadcrumb strong { color: #fff; font-weight: 650; }

/* Home hero */
.iyf-hero {
    position: relative;
    min-height: 680px;
    height: min(82vh, 820px);
    overflow: hidden;
    background: #080912;
}
.hero-bg, .hero-shade {
    position: absolute;
    inset: 0;
}
.hero-bg {
    background-size: cover;
    background-position: center 24%;
    transform: scale(1.04);
    filter: saturate(1.04);
}
.hero-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    backdrop-filter: blur(0px);
}
.hero-shade {
    background:
        linear-gradient(90deg, rgba(7,8,16,.94) 0%, rgba(7,8,16,.72) 36%, rgba(7,8,16,.28) 70%, rgba(7,8,16,.76) 100%),
        linear-gradient(180deg, rgba(7,8,16,.15) 0%, rgba(7,8,16,.10) 50%, #090b14 100%);
}
.hero-content {
    position: relative;
    z-index: 1;
    width: min(100% - 80px, 1640px);
    height: 100%;
    margin: 0 auto;
    padding-top: 160px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.hero-copy { max-width: 620px; transform: translateY(-42px); }
.hero-kicker {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 12px;
    border-radius: 999px;
    color: #effcff;
    background: rgba(255, 255, 255, .12);
    border: 1px solid rgba(255, 255, 255, .13);
    font-size: 13px;
    font-weight: 750;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.06);
}
.hero-kicker i { color: #ff4d8d; }
.hero-copy h1 {
    margin-top: 18px;
    font-size: clamp(44px, 5vw, 76px);
    line-height: 1.04;
    letter-spacing: -3px;
    font-weight: 900;
    text-shadow: 0 18px 42px rgba(0,0,0,.46);
}
.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 18px 0 0;
}
.hero-meta span {
    padding: 5px 10px;
    border-radius: 999px;
    background: rgba(0,0,0,.30);
    border: 1px solid rgba(255,255,255,.14);
    color: rgba(255,255,255,.78);
    font-size: 13px;
}
.hero-copy p {
    margin-top: 18px;
    color: rgba(255,255,255,.78);
    font-size: 17px;
    max-width: 590px;
}
.hero-actions {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-top: 28px;
    flex-wrap: wrap;
}
.watch-btn, .info-btn {
    height: 48px;
    padding: 0 22px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    font-weight: 800;
    transition: transform .2s ease, filter .2s ease, background .2s ease;
}
.watch-btn {
    color: #fff;
    background: linear-gradient(135deg, #27c7ff 0%, #7e5cff 52%, #ff63b7 100%);
    box-shadow: 0 15px 36px rgba(61, 124, 255, .36);
}
.info-btn {
    color: rgba(255,255,255,.86);
    background: rgba(255,255,255,.12);
    border: 1px solid rgba(255,255,255,.16);
}
.watch-btn:hover, .info-btn:hover { transform: translateY(-2px); filter: brightness(1.08); }
.hero-picks {
    position: absolute;
    left: clamp(24px, 4vw, 0px);
    right: clamp(24px, 4vw, 0px);
    bottom: 74px;
    display: flex;
    gap: 18px;
    align-items: flex-end;
    overflow-x: auto;
    padding: 6px 4px 12px;
    scrollbar-width: none;
}
.hero-picks::-webkit-scrollbar { display: none; }
.hero-pick {
    flex: 0 0 150px;
    display: block;
    color: #fff;
    transition: transform .2s ease;
}
.hero-pick:hover { transform: translateY(-4px); }
.pick-img {
    position: relative;
    display: block;
    height: 214px;
    border-radius: 14px;
    overflow: hidden;
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.14);
    box-shadow: 0 12px 28px rgba(0,0,0,.38);
}
.pick-img img { width: 100%; height: 100%; object-fit: cover; }
.pick-img::after {
    content: "";
    position: absolute;
    inset: 45% 0 0;
    background: linear-gradient(transparent, rgba(0,0,0,.72));
}
.pick-title {
    display: block;
    margin-top: 10px;
    line-height: 1.3;
    font-size: 14px;
    font-weight: 760;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.hero-pick em {
    display: block;
    margin-top: 2px;
    color: rgba(255,255,255,.56);
    font-size: 12px;
    font-style: normal;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Categories */
.quick-cats {
    position: relative;
    z-index: 2;
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding: 3px 0 22px;
    margin-bottom: 8px;
    scrollbar-width: none;
}
.quick-cats::-webkit-scrollbar { display: none; }
.quick-cats a, .filter-item {
    flex: 0 0 auto;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 20px;
    border-radius: 999px;
    color: rgba(255,255,255,.68);
    background: rgba(255,255,255,.055);
    border: 1px solid rgba(255,255,255,.09);
    font-weight: 700;
    font-size: 14px;
    transition: background .2s ease, color .2s ease, border-color .2s ease;
}
.quick-cats a:hover, .filter-item:hover { color: #fff; background: rgba(255,255,255,.10); }
.quick-cats a.active, .filter-item.active {
    color: #fff;
    border-color: rgba(36,184,255,.38);
    background: linear-gradient(135deg, rgba(36,184,255,.32), rgba(125,92,255,.25));
    box-shadow: 0 0 24px rgba(36,184,255,.18);
}

/* Sections and cards */
.content-section { margin-top: 34px; }
.section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 20px;
}
.section-head h2 {
    position: relative;
    font-size: 26px;
    line-height: 1.1;
    font-weight: 900;
    letter-spacing: -.5px;
}
.section-head h2::before {
    content: "";
    display: inline-block;
    width: 4px;
    height: 22px;
    margin-right: 10px;
    vertical-align: -3px;
    border-radius: 99px;
    background: linear-gradient(180deg, var(--blue), var(--pink));
    box-shadow: 0 0 16px rgba(36,184,255,.55);
}
.section-head span {
    display: block;
    margin-top: 5px;
    margin-left: 16px;
    color: var(--muted);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1.2px;
}
.section-head.compact { margin-bottom: 16px; }
.more-link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: rgba(255,255,255,.55);
    font-weight: 720;
    font-size: 14px;
}
.more-link:hover { color: #fff; }
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 26px 18px;
}
.card {
    position: relative;
    min-width: 0;
    display: block;
    color: #fff;
}
.card-poster {
    position: relative;
    width: 100%;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    border-radius: 13px;
    background:
        linear-gradient(135deg, rgba(36,184,255,.15), rgba(255,95,188,.12)),
        #121623;
    box-shadow: 0 11px 24px rgba(0,0,0,.30);
    transform: translateZ(0);
}
.card-poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .32s ease, filter .32s ease;
}
.card:hover .card-poster img { transform: scale(1.06); filter: brightness(.78); }
.card-poster::after {
    content: "";
    position: absolute;
    inset: 45% 0 0;
    background: linear-gradient(transparent, rgba(0,0,0,.74));
    opacity: .78;
}
.badge-top-left {
    position: absolute;
    left: 8px;
    top: 8px;
    z-index: 2;
    max-width: calc(100% - 16px);
    padding: 4px 9px;
    border-radius: 999px;
    color: #fff;
    background: linear-gradient(135deg, #26c7ff, #8d5cff 60%, #ff5fbc);
    box-shadow: 0 6px 18px rgba(0,0,0,.26);
    font-size: 12px;
    font-weight: 800;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.card-overlay {
    position: static;
    padding-top: 10px;
}
.play-btn {
    position: absolute;
    left: 50%;
    top: calc(50% - 22px);
    z-index: 3;
    width: 48px;
    height: 48px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    transform: translate(-50%, -50%) scale(.86);
    color: #fff;
    background: rgba(255,255,255,.18);
    border: 1px solid rgba(255,255,255,.35);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    opacity: 0;
    transition: opacity .2s ease, transform .2s ease;
}
.card:hover .play-btn { opacity: 1; transform: translate(-50%, -50%) scale(1); }
.card-info { min-width: 0; }
.card-title {
    color: rgba(255,255,255,.92);
    font-size: 15px;
    line-height: 1.28;
    font-weight: 760;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.card-meta {
    margin-top: 4px;
    color: rgba(255,255,255,.46);
    font-size: 13px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.card:hover .card-title { color: #fff; }
.empty-state {
    padding: 52px 20px;
    border-radius: var(--radius);
    text-align: center;
    color: var(--muted);
    background: rgba(255,255,255,.055);
    border: 1px solid var(--line);
}

/* List */
.list-hero, .search-hero {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    min-height: 220px;
    padding: 34px;
    background:
        linear-gradient(135deg, rgba(36,184,255,.18), rgba(125,92,255,.14) 52%, rgba(255,95,188,.16)),
        rgba(255,255,255,.055);
    border: 1px solid rgba(255,255,255,.10);
    box-shadow: var(--shadow);
}
.list-hero-bg {
    position: absolute;
    inset: -20px;
    background-size: cover;
    background-position: center;
    filter: blur(26px) saturate(1.25);
    opacity: .30;
}
.list-hero::after, .search-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(9,11,20,.78), rgba(9,11,20,.42));
}
.list-hero-inner, .search-hero > * { position: relative; z-index: 1; }
.list-hero h1, .search-hero h1 {
    margin-top: 12px;
    font-size: clamp(32px, 4vw, 56px);
    line-height: 1.06;
    letter-spacing: -1.8px;
    font-weight: 900;
}
.list-hero p { margin-top: 10px; color: var(--sub); max-width: 620px; }
.result-count { margin-top: 18px; color: var(--sub); font-size: 14px; }
.result-count em { color: var(--cyan); font-style: normal; font-weight: 850; }
.filter-panel {
    margin: 22px 0 6px;
    padding: 16px;
    border-radius: 22px;
    background: rgba(255,255,255,.055);
    border: 1px solid var(--line);
    display: flex;
    align-items: center;
    gap: 14px;
}
.filter-label { color: rgba(255,255,255,.78); font-weight: 800; flex: 0 0 auto; }
.filter-scroll { display: flex; gap: 10px; overflow-x: auto; scrollbar-width: none; }
.filter-scroll::-webkit-scrollbar { display: none; }

/* Detail */
.detail-backdrop {
    position: relative;
    min-height: 720px;
    overflow: hidden;
    background: #070810;
}
.detail-bg, .detail-bg-mask { position: absolute; inset: 0; }
.detail-bg {
    background-size: cover;
    background-position: center 18%;
    transform: scale(1.06);
    filter: blur(5px) saturate(1.12);
    opacity: .70;
}
.detail-bg-mask {
    background:
        linear-gradient(90deg, rgba(7,8,16,.92), rgba(7,8,16,.62) 48%, rgba(7,8,16,.72)),
        linear-gradient(180deg, rgba(7,8,16,.18), #090b14 92%);
}
.detail-layout {
    position: relative;
    z-index: 1;
    width: min(100% - 48px, 1460px);
    margin: 0 auto;
    padding-top: 108px;
    padding-bottom: 68px;
}
.detail-breadcrumb { margin-bottom: 28px; }
.detail-card {
    display: grid;
    grid-template-columns: 290px minmax(0, 1fr);
    gap: clamp(28px, 5vw, 70px);
    align-items: center;
}
.detail-poster {
    width: 100%;
    border-radius: 20px;
    overflow: hidden;
    background: #111827;
    box-shadow: 0 26px 70px rgba(0,0,0,.52);
    border: 1px solid rgba(255,255,255,.13);
}
.detail-poster img { width: 100%; aspect-ratio: 2/3; object-fit: cover; }
.detail-info h1 {
    margin-top: 16px;
    font-size: clamp(38px, 5vw, 70px);
    line-height: 1.06;
    font-weight: 920;
    letter-spacing: -2px;
}
.detail-en { margin-top: 8px; color: rgba(255,255,255,.52); font-size: 15px; }
.detail-meta .score { color: #ffe17a; border-color: rgba(255,225,122,.35); }
.detail-people {
    margin-top: 22px;
    max-width: 850px;
    color: rgba(255,255,255,.70);
    display: grid;
    gap: 7px;
}
.detail-people p {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.detail-people b { color: rgba(255,255,255,.92); }
.detail-desc {
    margin-top: 18px;
    max-width: 850px;
    color: rgba(255,255,255,.72);
    font-size: 16px;
}
.detail-content { padding-top: 8px; }
.text-panel {
    margin-top: 34px;
    padding: 26px;
    border-radius: 22px;
    background: rgba(255,255,255,.055);
    border: 1px solid var(--line);
}
.text-panel h2 { font-size: 22px; margin-bottom: 12px; }
.synopsis-text { color: rgba(255,255,255,.70); line-height: 1.95; }
.synopsis-text p + p { margin-top: 10px; }

/* Episodes */
.episode-section { padding-top: 4px; }
.ep-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(112px, 1fr));
    gap: 12px;
}
.ep-btn {
    min-height: 44px;
    padding: 10px 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    text-align: center;
    color: rgba(255,255,255,.75);
    background: rgba(255,255,255,.055);
    border: 1px solid rgba(255,255,255,.09);
    font-size: 14px;
    font-weight: 720;
    transition: background .2s ease, color .2s ease, border-color .2s ease;
}
.ep-btn:hover, .ep-btn.active {
    color: #fff;
    background: linear-gradient(135deg, rgba(36,184,255,.32), rgba(125,92,255,.22));
    border-color: rgba(36,184,255,.35);
}

/* Player */
.play-page { max-width: 1500px; }
.player-card {
    overflow: hidden;
    border-radius: 24px;
    background: #000;
    box-shadow: 0 24px 70px rgba(0,0,0,.52);
    border: 1px solid rgba(255,255,255,.10);
}
.player-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000;
}
.vp-video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #000;
}
.vp-big-play {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 78px;
    height: 78px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(36,184,255,.88), rgba(125,92,255,.88), rgba(255,95,188,.88));
    color: #fff;
    border: 1px solid rgba(255,255,255,.34);
    box-shadow: 0 18px 42px rgba(0,0,0,.48);
    z-index: 5;
}
.vp-big-play i { font-size: 42px; margin-left: 4px; }
.player-placeholder {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    color: rgba(255,255,255,.68);
}
.player-placeholder i { font-size: 54px; }
.play-title-row {
    margin: 22px 0 26px;
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: center;
    flex-wrap: wrap;
}
.play-title-row h1 { font-size: clamp(24px, 3vw, 38px); line-height: 1.15; }
.play-title-row p { color: var(--muted); margin-top: 6px; }
.play-next-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* Search */
.search-hero { min-height: 260px; display: flex; flex-direction: column; justify-content: center; }
.search-page-box {
    margin-top: 22px;
    width: min(100%, 760px);
    height: 58px;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 8px 0 18px;
    border-radius: 999px;
    background: rgba(255,255,255,.12);
    border: 1px solid rgba(255,255,255,.16);
}
.search-page-box i { color: rgba(255,255,255,.62); font-size: 22px; }
.search-page-box input {
    flex: 1;
    min-width: 0;
    border: 0;
    outline: 0;
    background: transparent;
    color: #fff;
    font-size: 16px;
}
.search-page-box input::placeholder { color: rgba(255,255,255,.45); }
.search-page-box button {
    height: 42px;
    padding: 0 22px;
    border-radius: 999px;
    color: #fff;
    background: linear-gradient(135deg, var(--blue), var(--purple));
    font-weight: 850;
}

/* Pagination and footer */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
    margin: 40px 0 6px;
}
.page-btn {
    min-width: 42px;
    height: 42px;
    padding: 0 13px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: rgba(255,255,255,.70);
    background: rgba(255,255,255,.055);
    border: 1px solid rgba(255,255,255,.09);
    font-weight: 780;
}
.page-btn.active, .page-btn:hover {
    color: #fff;
    background: linear-gradient(135deg, rgba(36,184,255,.35), rgba(125,92,255,.26));
    border-color: rgba(36,184,255,.35);
}
.page-btn.dots { pointer-events: none; background: transparent; border-color: transparent; }
.site-footer {
    border-top: 1px solid rgba(255,255,255,.07);
    background: rgba(0,0,0,.16);
}
.footer-inner {
    width: min(100% - 48px, 1640px);
    margin: 0 auto;
    padding: 34px 0 calc(34px + var(--safe-bottom));
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    flex-wrap: wrap;
    color: var(--muted);
}
.footer-brand { color: #fff; font-size: 18px; }
.footer-links { display: flex; gap: 18px; flex-wrap: wrap; }
.footer-links a:hover { color: #fff; }
.footer-copy { font-size: 13px; }
.back-to-top {
    position: fixed;
    right: 22px;
    bottom: 28px;
    z-index: 900;
    width: 44px;
    height: 44px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: rgba(255,255,255,.12);
    border: 1px solid rgba(255,255,255,.16);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    opacity: 0;
    transform: translateY(14px);
    pointer-events: none;
    transition: opacity .2s ease, transform .2s ease;
}
.back-to-top.visible { opacity: 1; transform: translateY(0); pointer-events: auto; }
.mobile-tabbar { display: none; }

/* Compatibility with old class names that may appear in cache/templates */
.container { width: min(100% - 48px, 1640px); margin: 0 auto; padding-top: 104px; padding-bottom: 56px; }
.glass-panel { background: rgba(255,255,255,.055); border: 1px solid var(--line); border-radius: 22px; }
.section { margin-top: 34px; }
.section-header { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 20px; }
.section-title { font-size: 26px; font-weight: 900; }
.section-more { color: var(--muted); }
.result-info { color: var(--muted); margin: 14px 0 22px; }
.result-info em { color: var(--cyan); font-style: normal; font-weight: 850; }

@media (min-width: 1700px) {
    .grid { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); }
    .hero-pick { flex-basis: 164px; }
    .pick-img { height: 235px; }
}

@media (max-width: 1180px) {
    .header-search { display: none; }
    .header-actions { display: flex; }
    .main-nav { gap: 20px; margin-right: 0; }
    .brand { font-size: 20px; }
    .grid { grid-template-columns: repeat(auto-fill, minmax(138px, 1fr)); }
    .detail-card { grid-template-columns: 240px minmax(0,1fr); }
}

@media (max-width: 760px) {
    body { background: #080912; }
    .site-header {
        background: rgba(7, 8, 16, .92);
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        border-bottom: 1px solid rgba(255,255,255,.07);
    }
    .header-inner { display: none; }
    .mobile-head {
        height: 54px;
        padding: 0 12px;
        display: flex;
        align-items: center;
        gap: 10px;
    }
    .mobile-brand { flex: 0 1 auto; min-width: 0; font-size: 16px; }
    .mobile-brand span:last-child {
        overflow: hidden;
        white-space: nowrap;
        text-overflow: ellipsis;
    }
    .brand-mark { width: 26px; height: 26px; border-radius: 8px; }
    .brand-mark i { font-size: 16px; }
    .mobile-search {
        flex: 1;
        height: 34px;
        min-width: 110px;
        display: flex;
        align-items: center;
        gap: 6px;
        padding: 0 11px;
        border-radius: 999px;
        background: rgba(255,255,255,.085);
        border: 1px solid rgba(255,255,255,.10);
    }
    .mobile-search input {
        flex: 1;
        min-width: 0;
        border: 0;
        outline: 0;
        background: transparent;
        color: #fff;
        font-size: 13px;
    }
    .mobile-search i { color: rgba(255,255,255,.58); }
    .mobile-nav {
        display: flex;
        gap: 18px;
        overflow-x: auto;
        padding: 0 13px 10px;
        scrollbar-width: none;
    }
    .mobile-nav::-webkit-scrollbar { display: none; }
    .mobile-nav a {
        position: relative;
        flex: 0 0 auto;
        color: rgba(255,255,255,.62);
        font-size: 15px;
        font-weight: 760;
        padding-bottom: 7px;
    }
    .mobile-nav a.active { color: #fff; }
    .mobile-nav a.active::after {
        content: "";
        position: absolute;
        left: 0;
        right: 0;
        bottom: 0;
        height: 2px;
        border-radius: 99px;
        background: var(--blue);
    }
    .mobile-tabbar {
        position: fixed;
        left: 10px;
        right: 10px;
        bottom: calc(8px + var(--safe-bottom));
        z-index: 1001;
        height: 58px;
        display: grid;
        grid-template-columns: repeat(5, 1fr);
        border-radius: 18px;
        background: rgba(12, 15, 25, .88);
        border: 1px solid rgba(255,255,255,.10);
        backdrop-filter: blur(18px);
        -webkit-backdrop-filter: blur(18px);
        box-shadow: 0 12px 34px rgba(0,0,0,.42);
    }
    .tab-item {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 2px;
        color: rgba(255,255,255,.48);
        font-size: 11px;
    }
    .tab-item i { font-size: 20px; }
    .tab-item.active { color: #4fd4ff; }
    .page-wrap, .container {
        width: calc(100% - 24px);
        padding-top: 108px;
        padding-bottom: calc(86px + var(--safe-bottom));
    }
    .home-wrap { padding-top: 18px; }
    .breadcrumb { font-size: 12px; margin-bottom: 14px; }

    .iyf-hero {
        height: auto;
        min-height: 505px;
        padding-bottom: 18px;
    }
    .hero-bg { background-position: center top; filter: saturate(1.08); }
    .hero-shade {
        background:
            linear-gradient(180deg, rgba(7,8,16,.38) 0%, rgba(7,8,16,.76) 52%, #080912 100%),
            linear-gradient(90deg, rgba(7,8,16,.82), rgba(7,8,16,.22));
    }
    .hero-content {
        width: calc(100% - 24px);
        min-height: 505px;
        padding-top: 122px;
        justify-content: flex-start;
    }
    .hero-copy { transform: none; max-width: 100%; }
    .hero-kicker { padding: 4px 9px; font-size: 12px; }
    .hero-copy h1 {
        margin-top: 12px;
        font-size: 34px;
        line-height: 1.08;
        letter-spacing: -1px;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }
    .hero-meta { gap: 6px; margin-top: 11px; }
    .hero-meta span { font-size: 11px; padding: 3px 7px; }
    .hero-copy p {
        margin-top: 12px;
        font-size: 13px;
        line-height: 1.65;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }
    .hero-actions { margin-top: 16px; gap: 10px; }
    .watch-btn, .info-btn { height: 40px; padding: 0 15px; font-size: 13px; }
    .hero-picks {
        position: relative;
        left: auto;
        right: auto;
        bottom: auto;
        margin-top: 26px;
        gap: 11px;
        padding: 0 2px 8px;
    }
    .hero-pick { flex-basis: 92px; }
    .pick-img { height: 130px; border-radius: 10px; }
    .pick-title { font-size: 12px; margin-top: 7px; }
    .hero-pick em { font-size: 10px; }

    .quick-cats { gap: 8px; padding-bottom: 12px; }
    .quick-cats a, .filter-item { height: 34px; padding: 0 13px; font-size: 12px; }
    .content-section { margin-top: 25px; }
    .section-head { margin-bottom: 14px; }
    .section-head h2 { font-size: 20px; }
    .section-head h2::before { height: 18px; margin-right: 8px; }
    .section-head span { margin-left: 12px; font-size: 10px; }
    .more-link { font-size: 12px; }
    .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px 10px; }
    .card-poster { border-radius: 10px; }
    .badge-top-left { left: 5px; top: 5px; padding: 3px 6px; font-size: 10px; }
    .play-btn { display: none; }
    .card-title { font-size: 12px; }
    .card-meta { font-size: 11px; margin-top: 2px; }

    .list-hero, .search-hero { border-radius: 20px; min-height: 170px; padding: 22px 18px; }
    .list-hero h1, .search-hero h1 { font-size: 30px; letter-spacing: -1px; }
    .list-hero p { font-size: 13px; }
    .filter-panel { align-items: flex-start; gap: 10px; padding: 12px; border-radius: 16px; }
    .filter-label { padding-top: 6px; font-size: 13px; }

    .detail-backdrop { min-height: auto; }
    .detail-layout { width: calc(100% - 24px); padding-top: 108px; padding-bottom: 26px; }
    .detail-card { grid-template-columns: 108px minmax(0,1fr); gap: 16px; align-items: start; }
    .detail-poster { border-radius: 13px; }
    .detail-info h1 { margin-top: 10px; font-size: 27px; letter-spacing: -.6px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
    .detail-en { display: none; }
    .detail-meta { margin-top: 9px; }
    .detail-people { display: none; }
    .detail-desc { margin-top: 10px; font-size: 13px; line-height: 1.6; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
    .detail-actions { margin-top: 14px; }
    .detail-content { padding-top: 0; }
    .text-panel { padding: 18px; border-radius: 18px; }
    .text-panel h2 { font-size: 18px; }
    .synopsis-text { font-size: 13px; line-height: 1.8; }

    .ep-grid { grid-template-columns: repeat(3, minmax(0,1fr)); gap: 8px; }
    .ep-btn { min-height: 38px; border-radius: 10px; font-size: 12px; padding: 8px 6px; }
    .player-card { border-radius: 16px; }
    .play-page { padding-top: 108px; }
    .player-wrap { aspect-ratio: 16 / 9; }
    .vp-big-play { width: 58px; height: 58px; }
    .vp-big-play i { font-size: 32px; }
    .play-title-row { margin: 16px 0 20px; }
    .play-title-row h1 { font-size: 21px; }
    .play-title-row p { font-size: 12px; }
    .play-next-actions { width: 100%; }
    .play-next-actions .info-btn { flex: 1; }

    .search-page-box { height: 48px; padding-left: 14px; }
    .search-page-box button { height: 36px; padding: 0 15px; }
    .pagination { margin-top: 28px; }
    .page-btn { min-width: 36px; height: 36px; font-size: 13px; }
    .footer-inner { width: calc(100% - 24px); padding-bottom: calc(92px + var(--safe-bottom)); justify-content: center; text-align: center; }
    .footer-links { justify-content: center; }
    .back-to-top { right: 16px; bottom: calc(78px + var(--safe-bottom)); width: 40px; height: 40px; }
}

@media (max-width: 380px) {
    .grid { gap: 16px 8px; }
    .hero-copy h1 { font-size: 30px; }
    .detail-card { grid-template-columns: 96px minmax(0,1fr); gap: 13px; }
    .detail-info h1 { font-size: 23px; }
    .ep-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
}

/* =========================================================
   V2 修正：PC 首页顶部改为爱壹帆式分类面板 + 移动端底部 Dock + 首拼 URL
   ========================================================= */
@media (min-width: 761px) {
    .site-header {
        background: rgba(9, 11, 24, .94);
        backdrop-filter: blur(18px);
        -webkit-backdrop-filter: blur(18px);
        border-bottom: 1px solid rgba(255,255,255,.07);
    }
    .header-inner { height: 66px; }
    .brand { font-size: 24px; }
    .brand-mark {
        width: 34px;
        height: 34px;
        border-radius: 11px;
    }
    .main-nav a {
        padding: 20px 0 18px;
        font-size: 17px;
    }
    .main-nav a.active::after { bottom: 8px; }
    .header-search {
        width: clamp(240px, 22vw, 360px);
        height: 48px;
        background: rgba(255,255,255,.10);
        border-color: rgba(255,255,255,.14);
    }
    .mobile-hero { display: none; }
    .home-wrap { padding-top: 30px; }
}

.home-pc-board {
    width: min(100% - 140px, 1580px);
    margin: 0 auto;
    padding-top: 112px;
    padding-bottom: 18px;
}
.pc-board-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(360px, 560px);
    gap: 10px;
    align-items: stretch;
}
.pc-filter-card {
    min-height: 408px;
    padding: 22px 36px;
    border-radius: 0;
    background: rgba(30, 33, 52, .92);
    border: 1px solid rgba(255,255,255,.06);
    box-shadow: 0 18px 44px rgba(0,0,0,.22);
}
.pc-filter-row {
    display: grid;
    grid-template-columns: 110px minmax(0, 1fr);
    gap: 18px;
    align-items: start;
    padding: 10px 0;
}
.pc-filter-label {
    height: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: linear-gradient(90deg, #04c8ff, #13a9ff);
    font-weight: 760;
    font-size: 15px;
    box-shadow: 0 8px 18px rgba(4,200,255,.16);
}
.pc-filter-links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 28px;
    min-height: 30px;
    align-items: center;
}
.pc-filter-links a {
    color: rgba(245,249,255,.82);
    font-size: 15px;
    line-height: 30px;
    white-space: nowrap;
    transition: color .18s ease, transform .18s ease;
}
.pc-filter-links a:hover,
.pc-filter-links a.is-hot {
    color: #18c8ff;
}
.pc-filter-links a:hover { transform: translateY(-1px); }
.pc-ad-card {
    position: relative;
    min-height: 408px;
    overflow: hidden;
    padding: 34px 36px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    color: #fff;
    background:
        radial-gradient(circle at 78% 18%, rgba(38, 140, 255, .58), transparent 25%),
        radial-gradient(circle at 30% 72%, rgba(255, 102, 181, .40), transparent 28%),
        linear-gradient(135deg, #02040c 0%, #091237 46%, #050506 100%);
    border: 1px solid rgba(255,255,255,.06);
    box-shadow: 0 18px 44px rgba(0,0,0,.25);
}
.pc-ad-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px),
        linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px);
    background-size: 28px 28px;
    mask-image: radial-gradient(circle at center, #000, transparent 76%);
    opacity: .8;
}
.pc-ad-card::after {
    content: "";
    position: absolute;
    width: 240px;
    height: 240px;
    right: -54px;
    top: -40px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(0,207,255,.55), rgba(255,83,193,.42));
    filter: blur(8px);
    opacity: .66;
}
.pc-ad-card > * { position: relative; z-index: 1; }
.ad-badge {
    width: max-content;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 999px;
    color: #fff;
    background: linear-gradient(90deg, #ffb800, #ff40cf);
    font-weight: 850;
    font-size: 14px;
    box-shadow: 0 10px 24px rgba(255,64,207,.26);
}
.pc-ad-card strong {
    margin-top: 18px;
    font-size: clamp(42px, 4.8vw, 72px);
    line-height: .98;
    letter-spacing: -2px;
    text-shadow: 0 12px 28px rgba(0,0,0,.45);
}
.pc-ad-card em {
    margin-top: 18px;
    color: rgba(255,255,255,.74);
    font-style: normal;
    font-size: 17px;
}
.ad-button {
    width: max-content;
    margin-top: 28px;
    padding: 12px 26px;
    border-radius: 999px;
    background: linear-gradient(90deg, #ff7a2f, #ff3d2e);
    color: #fff;
    font-size: 18px;
    font-weight: 900;
    box-shadow: 0 14px 28px rgba(255,61,46,.25);
}

@media (max-width: 1280px) and (min-width: 761px) {
    .home-pc-board { width: min(100% - 56px, 1180px); }
    .pc-board-layout { grid-template-columns: 1fr; }
    .pc-ad-card { min-height: 220px; }
    .pc-filter-card { min-height: auto; }
}

@media (max-width: 760px) {
    .home-pc-board { display: none; }
    .mobile-hero { display: block; }

    .mobile-tabbar {
        left: 14px;
        right: 14px;
        bottom: calc(12px + var(--safe-bottom));
        height: 66px;
        padding: 7px;
        display: grid;
        grid-template-columns: repeat(5, 1fr);
        border-radius: 28px;
        background:
            linear-gradient(180deg, rgba(32, 38, 62, .94), rgba(12, 15, 28, .94));
        border: 1px solid rgba(120, 209, 255, .16);
        box-shadow:
            0 18px 42px rgba(0,0,0,.55),
            inset 0 1px 0 rgba(255,255,255,.08);
        overflow: visible;
    }
    .mobile-tabbar::before {
        content: "";
        position: absolute;
        left: 18px;
        right: 18px;
        top: 0;
        height: 1px;
        background: linear-gradient(90deg, transparent, rgba(58,211,255,.72), rgba(255,92,190,.64), transparent);
    }
    .tab-item {
        position: relative;
        min-width: 0;
        border-radius: 21px;
        color: rgba(255,255,255,.52);
        font-size: 10px;
        font-weight: 760;
        letter-spacing: .2px;
        transition: color .2s ease, background .2s ease, transform .2s ease;
    }
    .tab-item i {
        width: 27px;
        height: 27px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border-radius: 12px;
        font-size: 18px;
        transition: background .2s ease, box-shadow .2s ease;
    }
    .tab-item.active {
        color: #fff;
        background: rgba(255,255,255,.08);
        transform: translateY(-2px);
    }
    .tab-item.active i {
        background: linear-gradient(135deg, #21c8ff, #7c5cff 58%, #ff62bb);
        box-shadow: 0 8px 18px rgba(33,200,255,.28);
    }
}
