/* ===== BASE RESET ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --w-bg: #ffffff;
    --w-bg2: #f5f6f8;
    --w-bg3: #eceef2;
    --w-blue: #1a4a8a;
    --w-blue2: #0f3270;
    --w-blue3: #2a5faa;
    --w-sky: #2d7dd2;
    --w-sky2: #1b6abf;
    --w-sky-bg: #eef4fc;
    --w-teal: #1e8fa0;
    --w-txt: #1a1d26;
    --w-txt2: #404458;
    --w-txt3: #8890a8;
    --w-line: #dde0ea;
    --w-line2: #c8ccd8;
    --w-sh1: 0 1px 4px rgba(26,74,138,.07);
    --w-sh2: 0 3px 12px rgba(26,74,138,.12);
    --w-sh3: 0 6px 24px rgba(26,74,138,.18);
    --w-r: 6px;
    --w-r2: 4px;
    --w-r3: 10px;
}

html { font-size: 15px; }

body {
    background: var(--w-bg2);
    color: var(--w-txt);
    font-family: 'Noto Sans SC','PingFang SC','Microsoft YaHei',sans-serif;
    line-height: 1.6;
}

a { color: var(--w-sky); text-decoration: none; transition: color .16s; }
a:hover { color: var(--w-sky2); }
img { max-width: 100%; display: block; }
ul { list-style: none; }
.fx::after { content: ''; display: table; clear: both; }

/* ===== PAGE WRAPPER ===== */
.outer-wrap {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 14px;
}

/* ===== SITE HEADER ===== */
.top-header {
    background: var(--w-bg);
    border-bottom: 3px solid var(--w-blue);
    padding: 10px 0;
    box-shadow: var(--w-sh1);
}

.top-header .outer-wrap {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: nowrap;
}

.site-brand {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-shrink: 0;
}

.site-brand-link {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

.site-name-text {
    font-size: 1.36rem;
    font-weight: 900;
    color: var(--w-blue);
    font-style: normal;
    letter-spacing: -.3px;
    text-decoration: none;
    border-bottom: none;
    text-transform: uppercase;
}

.url-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--w-blue);
    border-radius: var(--w-r2);
    padding: 5px 13px;
}

.url-tag .ut-lbl {
    font-size: 0.65rem;
    color: rgba(255,255,255,.7);
    white-space: nowrap;
    letter-spacing: .3px;
}

.url-tag .ut-val {
    font-size: 1.06rem;
    font-weight: 800;
    color: #fff;
    white-space: nowrap;
}

/* ===== BANNER ===== */
.banner-row {
    margin: 4px 0 3px;
}
.banner-row img { border-radius: var(--w-r2); width: 100%; }

/* ===== CATEGORY NAV ===== */
.nav-board {
    background: var(--w-bg);
    border: 1px solid var(--w-line);
    border-top: 3px solid var(--w-sky);
    border-radius: var(--w-r);
    overflow: hidden;
    margin: 4px 0;
    box-shadow: var(--w-sh1);
}

.nav-row {
    display: flex;
    align-items: stretch;
    border-bottom: 1px solid var(--w-line);
    min-height: 36px;
}

.nav-row:last-child { border-bottom: none; }

.zone-name {
    background: var(--w-blue);
    color: rgba(255,255,255,.82);
    font-size: .68rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px 2px;
    width: 60px;
    min-width: 60px;
    border-right: 1px solid rgba(255,255,255,.1);
    text-align: center;
    line-height: 1.3;
    letter-spacing: .3px;
    flex-shrink: 0;
}

.zone-items {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    align-items: center;
    padding: 4px 8px;
    gap: 3px;
    flex: 1;
}

.zone-items a {
    font-size: .80rem;
    color: var(--w-txt2);
    padding: 3px 5px;
    border-radius: var(--w-r2);
    transition: all .16s;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: center;
    border: 1px solid transparent;
    text-decoration: none;
    display: block;
}

.zone-items a:hover {
    background: var(--w-sky-bg);
    color: var(--w-sky);
    border-color: #aacff0;
}

.zone-items a.active {
    background: var(--w-sky);
    color: #fff;
    border-color: var(--w-sky);
    font-weight: 700;
}

/* ===== SEARCH ===== */
.qry-block {
    background: var(--w-bg);
    border: 1px solid var(--w-line);
    border-radius: var(--w-r);
    padding: 8px 12px;
    margin: 4px 0;
    box-shadow: var(--w-sh1);
}

.qry-block form {
    display: flex;
    gap: 5px;
    align-items: center;
    flex-wrap: nowrap;
    width: 100%;
}

.qry-block input[type="text"] {
    flex: 1;
    min-width: 0;
    height: 34px;
    border: 1.5px solid var(--w-line2);
    border-radius: var(--w-r2);
    padding: 0 11px;
    font-size: .86rem;
    color: var(--w-txt);
    background: var(--w-bg2);
    outline: none;
    transition: border-color .18s;
}

.qry-block input[type="text"]:focus {
    border-color: var(--w-sky);
    background: var(--w-bg);
}

.qry-block button {
    height: 34px;
    padding: 0 11px;
    border: none;
    border-radius: var(--w-r2);
    background: var(--w-blue);
    color: #fff;
    font-size: .80rem;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
    transition: background .16s;
    flex-shrink: 0;
}

.qry-block button:hover { background: var(--w-blue3); }

.qry-block button[value="1"] { background: var(--w-sky); }
.qry-block button[value="1"]:hover { background: var(--w-sky2); }

.qry-block button[value="2"] { background: var(--w-teal); }
.qry-block button[value="2"]:hover { background: #167080; }

/* ===== HOT TAGS ===== */
.kwd-panel {
    background: var(--w-bg);
    border: 1px solid var(--w-line);
    border-radius: var(--w-r);
    padding: 7px 12px;
    margin: 4px 0;
    box-shadow: var(--w-sh1);
}

.kwd-panel h4 {
    font-size: .78rem;
    font-weight: 700;
    color: var(--w-blue);
    margin-bottom: 5px;
}

.kwd-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.kwd-cloud .kw {
    display: inline-block;
    background: var(--w-bg2);
    color: var(--w-txt2);
    border: 1px solid var(--w-line2);
    border-radius: 3px;
    padding: 2px 9px;
    font-size: .74rem;
    text-decoration: none;
    transition: all .16s;
}

.kwd-cloud .kw:hover {
    background: var(--w-sky-bg);
    color: var(--w-sky);
    border-color: #99c4e8;
}

/* ===== CONTENT BLOCK ===== */
.content-block {
    background: var(--w-bg);
    border: 1px solid var(--w-line);
    border-radius: var(--w-r3);
    padding: 12px 12px 10px;
    margin: 4px 0;
    box-shadow: var(--w-sh1);
}

.cb-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
    padding-bottom: 7px;
    border-bottom: 2px solid var(--w-bg3);
    position: relative;
}

.cb-heading::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 36px;
    height: 2px;
    background: var(--w-sky);
    border-radius: 2px;
}

.cb-heading h3 {
    font-size: .96rem;
    font-weight: 800;
    color: var(--w-blue);
}

.cb-heading h3 a { color: var(--w-blue); }
.cb-heading h3 a:hover { color: var(--w-sky); }

.cb-heading h4 {
    font-size: .92rem;
    font-weight: 800;
    color: var(--w-blue);
}

/* ===== MOVIE GRID ===== */
.movie-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 9px;
    list-style: none;
    padding: 0;
    margin: 0;
}

.movie-grid li {
    border-radius: var(--w-r);
    overflow: hidden;
    border: 1px solid var(--w-line);
    background: var(--w-bg2);
    transition: box-shadow .2s, transform .18s;
}

.movie-grid li:hover {
    box-shadow: var(--w-sh3);
    transform: translateY(-2px);
}

.thumb-box {
    display: block;
    width: 100%;
    aspect-ratio: 600 / 350;
    overflow: hidden;
    background: var(--w-bg3);
}

.thumb-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .3s;
}

.thumb-box:hover img { transform: scale(1.05); }

.movie-title {
    padding: 5px 7px 7px;
}

.movie-title h5 {
    font-size: .76rem;
    font-weight: 500;
    color: var(--w-txt);
    line-height: 1.4;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.movie-title h5 a { color: var(--w-txt); }
.movie-title h5 a:hover { color: var(--w-sky); }

/* ===== PAGINATION ===== */
.pg-zone {
    margin: 12px 0 5px;
    display: flex;
    justify-content: center;
}

.pg-row {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    align-items: center;
    justify-content: center;
}

.pg-row a.pgb {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
    padding: 0 9px;
    background: var(--w-bg);
    border: 1.5px solid var(--w-line2);
    border-radius: var(--w-r2);
    font-size: .82rem;
    color: var(--w-txt2);
    text-decoration: none;
    transition: all .16s;
}

.pg-row a.pgb:hover {
    background: var(--w-sky-bg);
    border-color: var(--w-sky);
    color: var(--w-sky);
}

.pg-row a.pgb-on {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
    padding: 0 9px;
    background: var(--w-sky);
    border: 1.5px solid var(--w-sky);
    border-radius: var(--w-r2);
    font-size: .82rem;
    font-weight: 700;
    color: #fff;
    cursor: default;
}

/* ===== FOOTER ===== */
.foot-links {
    background: var(--w-bg);
    border: 1px solid var(--w-line);
    border-radius: var(--w-r);
    padding: 9px 12px;
    margin: 4px 0;
    box-shadow: var(--w-sh1);
}

.fl-list {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.fl-list dd { display: inline; }

.fl-list a {
    display: inline-block;
    font-size: .75rem;
    color: var(--w-txt3);
    padding: 2px 8px;
    border-radius: 3px;
    border: 1px solid var(--w-line);
    background: var(--w-bg2);
    text-decoration: none;
    transition: all .16s;
}

.fl-list a:hover { color: var(--w-sky); border-color: var(--w-sky); }

.foot-copy {
    text-align: center;
    padding: 8px 0 14px;
    color: var(--w-txt3);
    font-size: .74rem;
}

/* ===== DETAIL PAGES ===== */
.vod-title {
    line-height: 1.8;
    text-align: center;
    padding: 12px 14px;
    font-size: .96rem;
    margin: 4px 0;
    word-break: break-all;
    background: var(--w-bg);
    border: 1px solid var(--w-line);
    border-left: 4px solid var(--w-sky);
    border-radius: var(--w-r);
    box-shadow: var(--w-sh1);
}

.vod-title a {
    color: var(--w-sky);
    font-weight: 700;
    margin-right: 6px;
}

.vod-meta {
    font-size: .88rem;
    line-height: 1.95;
    padding: 14px 16px;
    background: var(--w-bg);
    border: 1px solid var(--w-line);
    border-radius: var(--w-r);
    box-shadow: var(--w-sh1);
    margin: 4px 0;
}

.img-preview {
    display: block;
    width: 100%;
    margin-top: 10px;
}

.img-preview picture,
.img-preview img {
    width: 100%;
    height: auto;
    border-radius: var(--w-r2);
    display: block;
}

/* ===== ACTION BUTTONS ===== */
.btn-group {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    margin: 12px 0;
}

.act-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 9px 20px;
    background: var(--w-blue);
    color: #fff;
    border: none;
    border-radius: var(--w-r2);
    font-size: .88rem;
    font-weight: 700;
    cursor: pointer;
    transition: background .18s, transform .14s;
    text-decoration: none;
}

.act-btn:hover {
    background: var(--w-sky);
    color: #fff;
    transform: translateY(-1px);
}

.app-tip {
    text-align: center;
    padding: 7px;
    font-size: .80rem;
}

.app-tip a { color: var(--w-blue); font-weight: 600; }
.app-tip a:hover { color: var(--w-sky); }

/* ===== SHARE BAR ===== */
.link-bar {
    display: flex;
    align-items: center;
    gap: 9px;
    background: var(--w-bg2);
    border: 1px solid var(--w-line);
    border-radius: var(--w-r);
    padding: 8px 12px;
    margin: 4px 0;
    flex-wrap: wrap;
}

.link-bar .lb-label { font-size: .75rem; color: var(--w-txt3); white-space: nowrap; }
.link-bar .lb-url { font-size: .77rem; color: var(--w-txt2); flex: 1; min-width: 0; word-break: break-all; }

.link-bar .lb-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 5px 13px;
    background: var(--w-blue);
    color: #fff;
    border: none;
    border-radius: var(--w-r2);
    font-size: .78rem;
    font-weight: 600;
    cursor: pointer;
    transition: background .16s;
    flex-shrink: 0;
}

.link-bar .lb-btn:hover { background: var(--w-sky); }

/* ===== VISIBILITY ===== */
.desk-only { display: block; }
.mob-only { display: none; }

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
    .movie-grid { grid-template-columns: repeat(2, 1fr); gap: 7px; }
    .desk-only { display: none; }
    .mob-only { display: block; }
}

@media (max-width: 768px) {
    html { font-size: 14px; }

    .site-name-text { font-size: 1.04rem; }
    .url-tag .ut-val { font-size: .90rem; }

    .nav-row { align-items: stretch; }

    .zone-name {
        width: 15%;
        min-width: 15%;
        max-width: 15%;
        font-size: 10px;
        padding: 4px 2px;
        letter-spacing: 0;
        line-height: 1.4;
        word-break: break-all;
        flex-shrink: 0;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .zone-items {
        width: 85%;
        flex: 1;
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 3px;
        padding: 4px 5px;
        align-items: center;
    }

    .zone-items a {
        font-size: 12px;
        padding: 5px 2px;
        text-align: center;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        display: block;
    }

    /* Search: all one row, no wrap */
    .qry-block form {
        flex-wrap: nowrap;
        gap: 4px;
    }

    .qry-block input[type="text"] {
        height: 32px;
        font-size: .76rem;
        padding: 0 6px;
    }

    .qry-block button {
        height: 32px;
        padding: 0 6px;
        font-size: .72rem;
    }

    /* Movie grid: 2 col */
    .movie-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 6px;
    }

    .thumb-box { aspect-ratio: 600 / 350; }
    .movie-title h5 { font-size: .70rem; }
    .content-block { padding: 9px 8px 7px; }
    .act-btn { padding: 8px 13px; font-size: .82rem; }
}

@media (min-width: 481px) and (max-width: 768px) {
    .zone-name { font-size: 10px; }
    .zone-items a { font-size: 13px; }
}

@media (max-width: 380px) {
    .zone-name { font-size: 10px; }
    .zone-items a { font-size: 12px; }
    .qry-block button { padding: 0 4px; font-size: .66rem; }
}
