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

:root {
    --white: #ffffff;
    --bg-page: #f5f5f5;
    --bg-panel: #ffffff;
    --bg-input: #f0f0f0;
    --bg-hover: #f7f2ff;
    --violet: #6001d2;
    --violet-dk: #4a0199;
    --violet-lt: #7b23e0;
    --violet-pale: #ede8ff;
    --violet-mid: #8833ee;
    --accent2: #ff0080;
    --accent2-dk: #cc0066;
    --slate: #232a36;
    --slate2: #444c5a;
    --slate3: #72788a;
    --divider: #e8e8ec;
    --divider2: #d4d4dc;
    --sh1: 0 1px 3px rgba(0,0,0,.06);
    --sh2: 0 2px 10px rgba(0,0,0,.09);
    --sh3: 0 4px 20px rgba(0,0,0,.12);
    --rad: 6px;
    --rad2: 4px;
    --rad3: 10px;
}

html { font-size: 15px; }

body {
    background: var(--bg-page);
    color: var(--slate);
    font-family: 'PingFang SC','Hiragino Sans GB','Microsoft YaHei','Helvetica Neue',Arial,sans-serif;
    line-height: 1.55;
}

a { color: var(--violet); text-decoration: none; transition: color .15s; }
a:hover { color: var(--violet-dk); }
img { max-width: 100%; display: block; }
ul { list-style: none; }
.clr::after { content: ''; display: table; clear: both; }

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

/* ===== SITE HEADER ===== */
.site-head {
    background: var(--white);
    border-bottom: 1px solid var(--divider);
    padding: 8px 0;
    box-shadow: var(--sh1);
}

.site-head .main-wrap {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: nowrap;
}

.head-identity {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.head-logo-anchor {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

.head-site-title {
    font-size: 1.38rem;
    font-weight: 900;
    color: var(--violet);
    font-style: normal;
    letter-spacing: -.5px;
    border-bottom: none;
    text-decoration: none;
}

.url-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--violet-pale);
    border: 1px solid rgba(96,1,210,.18);
    border-radius: 20px;
    padding: 4px 14px;
}

.url-badge .ub-tip {
    font-size: 0.68rem;
    color: var(--violet-mid);
    white-space: nowrap;
    opacity: .75;
}

.url-badge .ub-domain {
    font-size: 1.02rem;
    font-weight: 800;
    color: var(--violet);
    white-space: nowrap;
}

/* ===== BANNER ===== */
.top-banner {
    margin: 5px 0 4px;
}
.top-banner img { border-radius: var(--rad); width: 100%; }

/* ===== CATEGORY NAV ===== */
.nav-board {
    background: var(--white);
    border: 1px solid var(--divider);
    border-radius: var(--rad);
    overflow: hidden;
    margin: 4px 0;
    box-shadow: var(--sh1);
}

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

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

.zone-label {
    background: var(--violet);
    color: rgba(255,255,255,.9);
    font-size: .68rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 5px 2px;
    width: 62px;
    min-width: 62px;
    border-right: 1px solid rgba(255,255,255,.12);
    text-align: center;
    line-height: 1.3;
    letter-spacing: .3px;
    flex-shrink: 0;
}

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

.nav-items a {
    font-size: .82rem;
    color: var(--slate2);
    padding: 3px 6px;
    border-radius: var(--rad2);
    transition: all .15s;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: center;
    border: 1px solid transparent;
    text-decoration: none;
    display: block;
}

.nav-items a:hover {
    background: var(--bg-hover);
    color: var(--violet);
    border-color: rgba(96,1,210,.2);
}

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

/* ===== SEARCH ===== */
.search-bar {
    background: var(--white);
    border: 1px solid var(--divider);
    border-radius: var(--rad);
    padding: 8px 12px;
    margin: 4px 0;
    box-shadow: var(--sh1);
}

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

.search-bar input[type="text"] {
    flex: 1;
    min-width: 0;
    height: 36px;
    border: 1px solid var(--divider2);
    border-radius: 20px;
    padding: 0 16px;
    font-size: .88rem;
    color: var(--slate);
    background: var(--bg-input);
    outline: none;
    transition: border-color .2s, box-shadow .2s;
}

.search-bar input[type="text"]:focus {
    border-color: var(--violet);
    background: var(--white);
    box-shadow: 0 0 0 2px rgba(96,1,210,.12);
}

.search-bar button {
    height: 36px;
    padding: 0 12px;
    border: 1px solid var(--divider2);
    border-radius: 20px;
    background: var(--bg-input);
    color: var(--slate2);
    font-size: .82rem;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    transition: all .15s;
    flex-shrink: 0;
}

.search-bar button:hover { background: var(--divider); }

.search-bar button[value="1"] {
    background: var(--violet);
    color: #fff;
    border-color: transparent;
}
.search-bar button[value="1"]:hover { background: var(--violet-dk); }

.search-bar button[value="2"] {
    background: var(--accent2);
    color: #fff;
    border-color: transparent;
}
.search-bar button[value="2"]:hover { background: var(--accent2-dk); }

/* ===== HOT TAGS ===== */
.trending-panel {
    background: var(--white);
    border: 1px solid var(--divider);
    border-radius: var(--rad);
    padding: 7px 12px;
    margin: 4px 0;
    box-shadow: var(--sh1);
}

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

.trend-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.trend-tags .kw-tag {
    display: inline-block;
    background: var(--bg-input);
    color: var(--slate2);
    border: 1px solid var(--divider2);
    border-radius: 20px;
    padding: 2px 11px;
    font-size: .76rem;
    text-decoration: none;
    transition: all .15s;
}

.trend-tags .kw-tag:hover {
    background: var(--violet-pale);
    color: var(--violet);
    border-color: rgba(96,1,210,.25);
}

/* ===== CONTENT SECTION ===== */
.list-section {
    background: var(--white);
    border: 1px solid var(--divider);
    border-radius: var(--rad3);
    padding: 12px 12px 10px;
    margin: 5px 0;
    box-shadow: var(--sh1);
}

.section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
    padding-bottom: 7px;
    border-bottom: 2px solid var(--bg-page);
    position: relative;
}

.section-head::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 38px;
    height: 2px;
    background: var(--violet);
    border-radius: 2px;
}

.section-head h3 {
    font-size: .97rem;
    font-weight: 800;
    color: var(--slate);
}

.section-head h3 a { color: var(--slate); }
.section-head h3 a:hover { color: var(--violet); }

.section-head h4 {
    font-size: .95rem;
    font-weight: 800;
    color: var(--slate);
}

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

.card-grid li {
    border-radius: var(--rad);
    overflow: hidden;
    border: 1px solid var(--divider);
    background: var(--bg-page);
    transition: box-shadow .2s, transform .2s;
}

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

.card-thumb {
    display: block;
    width: 100%;
    aspect-ratio: 600 / 350;
    overflow: hidden;
    background: var(--bg-input);
}

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

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

.card-desc {
    padding: 5px 7px 7px;
}

.card-desc h5 {
    font-size: .78rem;
    font-weight: 500;
    color: var(--slate);
    line-height: 1.4;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.card-desc h5 a { color: var(--slate); }
.card-desc h5 a:hover { color: var(--violet); }

/* ===== PAGINATION ===== */
.pages-row {
    margin: 14px 0 6px;
    display: flex;
    justify-content: center;
}

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

.pages-inner a.pg-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    background: var(--white);
    border: 1px solid var(--divider2);
    border-radius: var(--rad2);
    font-size: .84rem;
    color: var(--slate2);
    text-decoration: none;
    transition: all .15s;
}

.pages-inner a.pg-num:hover {
    background: var(--violet-pale);
    border-color: var(--violet);
    color: var(--violet);
}

.pages-inner a.pg-active {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    background: var(--violet);
    border: 1px solid var(--violet);
    border-radius: var(--rad2);
    font-size: .84rem;
    font-weight: 700;
    color: #fff;
    cursor: default;
}

/* ===== FOOTER ===== */
.links-footer {
    background: var(--white);
    border: 1px solid var(--divider);
    border-radius: var(--rad);
    padding: 9px 12px;
    margin: 5px 0;
    box-shadow: var(--sh1);
}

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

.flink-list dd { display: inline; }

.flink-list a {
    display: inline-block;
    font-size: .77rem;
    color: var(--slate3);
    padding: 2px 9px;
    border-radius: 4px;
    border: 1px solid var(--divider);
    background: var(--bg-page);
    text-decoration: none;
    transition: all .15s;
}

.flink-list a:hover { color: var(--violet); border-color: rgba(96,1,210,.3); }

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

/* ===== DETAIL PAGES ===== */
.detail-bar {
    line-height: 1.8;
    text-align: center;
    padding: 12px 15px;
    font-size: .98rem;
    margin: 5px 0;
    word-break: break-all;
    background: var(--white);
    border: 1px solid var(--divider);
    border-left: 4px solid var(--violet);
    border-radius: var(--rad);
    box-shadow: var(--sh1);
}

.detail-bar a {
    color: var(--violet);
    font-weight: 700;
    margin-right: 6px;
}

.detail-specs {
    font-size: .9rem;
    line-height: 1.95;
    padding: 14px 17px;
    background: var(--white);
    border: 1px solid var(--divider);
    border-radius: var(--rad);
    box-shadow: var(--sh1);
    margin: 5px 0;
}

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

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

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

.dl-item {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 10px 24px;
    background: var(--violet);
    color: #fff;
    border: none;
    border-radius: 22px;
    font-size: .9rem;
    font-weight: 700;
    cursor: pointer;
    transition: background .18s, transform .15s;
    text-decoration: none;
    box-shadow: 0 2px 8px rgba(96,1,210,.25);
}

.dl-item:hover {
    background: var(--violet-dk);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(96,1,210,.35);
}

.client-note {
    text-align: center;
    padding: 6px;
    font-size: .82rem;
}

.client-note a { color: var(--violet); font-weight: 600; }
.client-note a:hover { color: var(--violet-dk); }

/* ===== SHARE ===== */
.share-strip {
    display: flex;
    align-items: center;
    gap: 9px;
    background: var(--bg-page);
    border: 1px solid var(--divider);
    border-radius: var(--rad);
    padding: 7px 12px;
    margin: 5px 0;
    flex-wrap: wrap;
}

.share-strip .share-txt { font-size: .77rem; color: var(--slate3); white-space: nowrap; }
.share-strip .share-link { font-size: .79rem; color: var(--slate2); flex: 1; min-width: 0; word-break: break-all; }

.share-strip .copy-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 5px 14px;
    background: var(--violet);
    color: #fff;
    border: none;
    border-radius: 18px;
    font-size: .8rem;
    font-weight: 600;
    cursor: pointer;
    transition: background .15s;
    flex-shrink: 0;
}

.share-strip .copy-btn:hover { background: var(--violet-dk); }

/* ===== VIS HELPERS ===== */
.vis-pc { display: block; }
.vis-mb { display: none; }

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
    .card-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
    .vis-pc { display: none; }
    .vis-mb { display: block; }
}

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

    .head-site-title { font-size: 1.08rem; }
    .url-badge .ub-domain { font-size: .9rem; }

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

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

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

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

    .search-bar form {
        flex-wrap: nowrap;
        gap: 4px;
    }

    .search-bar input[type="text"] {
        height: 34px;
        font-size: .79rem;
        padding: 0 10px;
    }

    .search-bar button {
        height: 34px;
        padding: 0 8px;
        font-size: .74rem;
    }

    .card-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 7px;
    }

    .card-thumb { aspect-ratio: 600 / 350; }
    .card-desc h5 { font-size: .72rem; }
    .list-section { padding: 9px 9px 7px; }
    .dl-item { padding: 9px 16px; font-size: .84rem; }
}

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

@media (max-width: 380px) {
    .zone-label { font-size: 10px; }
    .nav-items a { font-size: 12px; }
    .search-bar button { padding: 0 5px; font-size: .68rem; }
}
