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

:root {
    --bg: #ffffff;
    --bg-soft: #f4f4f4;
    --bg-muted: #e8e8e8;
    --yel: #ffe600;
    --yel-dk: #d4be00;
    --yel-lt: #fffbe0;
    --blk: #111111;
    --blk2: #222222;
    --blk3: #333333;
    --grn: #007a33;
    --grn-dk: #005a25;
    --txt: #111111;
    --txt2: #333333;
    --txt3: #888888;
    --bdr: #dddddd;
    --bdr2: #cccccc;
    --sh1: 0 1px 3px rgba(0,0,0,.08);
    --sh2: 0 2px 8px rgba(0,0,0,.11);
    --sh3: 0 4px 18px rgba(0,0,0,.15);
    --rr: 3px;
    --rr2: 2px;
    --rr3: 4px;
}

html { font-size: 15px; }

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

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

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

/* ===== SITE HEADER ===== */
.site-header {
    background: var(--yel);
    border-bottom: 4px solid var(--blk);
    padding: 8px 0;
}

.site-header .page-container {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: nowrap;
}

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

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

.header-sitename {
    font-size: 1.38rem;
    font-weight: 900;
    color: var(--blk);
    font-style: normal;
    letter-spacing: -0.5px;
    border-bottom: none;
    text-decoration: none;
    text-transform: uppercase;
}

.domain-capsule {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: var(--blk);
    border-radius: var(--rr2);
    padding: 4px 12px;
}

.domain-capsule .cap-label {
    font-size: 0.67rem;
    color: rgba(255,255,255,.55);
    white-space: nowrap;
}

.domain-capsule .cap-addr {
    font-size: 1.07rem;
    font-weight: 800;
    color: var(--yel);
    white-space: nowrap;
}

/* ===== BANNER ===== */
.promo-block {
    margin: 4px 0 3px;
}
.promo-block img { border-radius: var(--rr); width: 100%; }

/* ===== CATEGORY NAV ===== */
.channel-nav {
    background: var(--blk);
    border-radius: var(--rr3);
    overflow: hidden;
    margin: 4px 0;
    box-shadow: var(--sh2);
}

.channel-row {
    display: flex;
    align-items: stretch;
    border-bottom: 1px solid rgba(255,255,255,.08);
    min-height: 38px;
}

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

.channel-zone-tag {
    background: var(--yel);
    color: var(--blk);
    font-size: .67rem;
    font-weight: 900;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 5px 2px;
    width: 62px;
    min-width: 62px;
    border-right: 2px solid var(--blk);
    text-align: center;
    line-height: 1.3;
    letter-spacing: .2px;
    flex-shrink: 0;
    text-transform: uppercase;
}

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

.channel-links a {
    font-size: .81rem;
    color: rgba(255,255,255,.82);
    padding: 3px 5px;
    border-radius: var(--rr2);
    transition: all .15s;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: center;
    border: 1px solid transparent;
    text-decoration: none;
    display: block;
}

.channel-links a:hover {
    background: var(--yel);
    color: var(--blk);
    border-color: var(--yel);
    font-weight: 700;
}

.channel-links a.active {
    background: var(--yel);
    color: var(--blk);
    border-color: var(--yel);
    font-weight: 900;
}

/* ===== SEARCH ===== */
.search-zone {
    background: var(--bg);
    border: 2px solid var(--blk);
    border-radius: var(--rr);
    padding: 7px 11px;
    margin: 4px 0;
    box-shadow: var(--sh1);
}

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

.search-zone input[type="text"] {
    flex: 1;
    min-width: 0;
    height: 36px;
    border: 2px solid var(--bdr2);
    border-radius: var(--rr2);
    padding: 0 12px;
    font-size: .87rem;
    color: var(--txt);
    background: var(--bg-soft);
    outline: none;
    transition: border-color .15s;
}

.search-zone input[type="text"]:focus {
    border-color: var(--yel);
    background: var(--bg);
    box-shadow: 0 0 0 2px rgba(255,230,0,.3);
}

.search-zone button {
    height: 36px;
    padding: 0 12px;
    border: 2px solid var(--blk);
    border-radius: var(--rr2);
    background: var(--blk);
    color: var(--yel);
    font-size: .8rem;
    font-weight: 800;
    cursor: pointer;
    white-space: nowrap;
    transition: all .15s;
    flex-shrink: 0;
    text-transform: uppercase;
}

.search-zone button:hover {
    background: var(--blk2);
    border-color: var(--blk2);
}

.search-zone button[value="1"] {
    background: var(--yel);
    color: var(--blk);
    border-color: var(--yel);
}
.search-zone button[value="1"]:hover {
    background: var(--yel-dk);
    border-color: var(--yel-dk);
}

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

/* ===== HOT TAGS ===== */
.trending-section {
    background: var(--bg);
    border: 2px solid var(--blk);
    border-radius: var(--rr);
    padding: 7px 12px;
    margin: 4px 0;
    box-shadow: var(--sh1);
}

.trending-section h4 {
    font-size: .79rem;
    font-weight: 900;
    color: var(--blk);
    margin-bottom: 5px;
    text-transform: uppercase;
    letter-spacing: .5px;
}

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

.tag-cloud .tc-item {
    display: inline-block;
    background: var(--yel-lt);
    color: var(--blk);
    border: 1.5px solid var(--bdr2);
    border-radius: 20px;
    padding: 2px 10px;
    font-size: .75rem;
    font-weight: 600;
    text-decoration: none;
    transition: all .15s;
}

.tag-cloud .tc-item:hover {
    background: var(--yel);
    color: var(--blk);
    border-color: var(--yel-dk);
}

/* ===== CONTENT SECTION ===== */
.media-section {
    background: var(--bg);
    border: 2px solid var(--blk);
    border-radius: var(--rr3);
    padding: 12px 12px 9px;
    margin: 4px 0;
    box-shadow: var(--sh1);
}

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

.section-header h3 {
    font-size: 1rem;
    font-weight: 900;
    color: var(--blk);
    text-transform: uppercase;
    letter-spacing: .3px;
}

.section-header h3 a { color: var(--blk); }
.section-header h3 a:hover { color: var(--grn); }

.section-header h4 {
    font-size: .96rem;
    font-weight: 900;
    color: var(--blk);
    text-transform: uppercase;
}

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

.film-grid li {
    border-radius: var(--rr);
    overflow: hidden;
    border: 1.5px solid var(--bdr);
    background: var(--bg-soft);
    transition: box-shadow .18s, transform .18s;
}

.film-grid li:hover {
    box-shadow: var(--sh3);
    transform: translateY(-2px);
    border-color: var(--yel-dk);
}

.film-poster {
    display: block;
    width: 100%;
    aspect-ratio: 600 / 350;
    overflow: hidden;
    background: var(--bg-muted);
}

.film-poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .28s;
}

.film-poster:hover img { transform: scale(1.05); }

.film-meta {
    padding: 5px 7px 6px;
    border-top: 2px solid var(--yel);
}

.film-meta h5 {
    font-size: .77rem;
    font-weight: 600;
    color: var(--txt);
    line-height: 1.4;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.film-meta h5 a { color: var(--txt); }
.film-meta h5 a:hover { color: var(--grn); }

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

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

.pager-btns a.pb {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    background: var(--bg);
    border: 2px solid var(--blk);
    border-radius: var(--rr2);
    font-size: .83rem;
    font-weight: 700;
    color: var(--blk);
    text-decoration: none;
    transition: all .15s;
}

.pager-btns a.pb:hover {
    background: var(--yel);
    border-color: var(--yel-dk);
    color: var(--blk);
}

.pager-btns a.pb-active {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    background: var(--yel);
    border: 2px solid var(--blk);
    border-radius: var(--rr2);
    font-size: .83rem;
    font-weight: 900;
    color: var(--blk);
    cursor: default;
}

/* ===== FOOTER ===== */
.friendlink-block {
    background: var(--bg);
    border: 2px solid var(--blk);
    border-radius: var(--rr);
    padding: 9px 12px;
    margin: 4px 0;
    box-shadow: var(--sh1);
}

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

.friendlink-list dd { display: inline; }

.friendlink-list a {
    display: inline-block;
    font-size: .76rem;
    color: var(--txt3);
    padding: 2px 9px;
    border-radius: 3px;
    border: 1px solid var(--bdr);
    background: var(--bg-soft);
    text-decoration: none;
    transition: all .15s;
}

.friendlink-list a:hover {
    color: var(--blk);
    border-color: var(--yel-dk);
    background: var(--yel-lt);
}

.bottom-credits {
    text-align: center;
    padding: 8px 0 14px;
    color: var(--txt3);
    font-size: .75rem;
}

/* ===== DETAIL PAGES ===== */
.entry-heading {
    line-height: 1.8;
    text-align: center;
    padding: 12px 15px;
    font-size: .97rem;
    margin: 4px 0;
    word-break: break-all;
    background: var(--bg);
    border: 2px solid var(--blk);
    border-left: 5px solid var(--yel);
    border-radius: var(--rr);
    box-shadow: var(--sh1);
}

.entry-heading a {
    color: var(--grn);
    font-weight: 800;
    margin-right: 6px;
}

.entry-details {
    font-size: .89rem;
    line-height: 1.95;
    padding: 14px 17px;
    background: var(--bg);
    border: 2px solid var(--blk);
    border-radius: var(--rr);
    box-shadow: var(--sh1);
    margin: 4px 0;
}

.snapshot-view {
    display: block;
    width: 100%;
    margin-top: 10px;
}

.snapshot-view picture,
.snapshot-view img {
    width: 100%;
    height: auto;
    border-radius: var(--rr2);
    display: block;
}

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

.action-link-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 10px 22px;
    background: var(--blk);
    color: var(--yel);
    border: 2px solid var(--blk);
    border-radius: var(--rr2);
    font-size: .89rem;
    font-weight: 800;
    cursor: pointer;
    transition: all .18s;
    text-decoration: none;
    text-transform: uppercase;
}

.action-link-btn:hover {
    background: var(--yel);
    color: var(--blk);
    border-color: var(--blk);
    transform: translateY(-1px);
}

.download-hint {
    text-align: center;
    padding: 6px;
    font-size: .81rem;
}

.download-hint a { color: var(--grn); font-weight: 700; }
.download-hint a:hover { color: var(--grn-dk); }

/* ===== SHARE ===== */
.url-share-bar {
    display: flex;
    align-items: center;
    gap: 9px;
    background: var(--yel-lt);
    border: 2px solid var(--blk);
    border-radius: var(--rr);
    padding: 8px 12px;
    margin: 4px 0;
    flex-wrap: wrap;
}

.url-share-bar .usb-lbl { font-size: .76rem; color: var(--txt3); white-space: nowrap; font-weight: 700; }
.url-share-bar .usb-addr { font-size: .78rem; color: var(--txt2); flex: 1; min-width: 0; word-break: break-all; }

.url-share-bar .usb-copy {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 6px 13px;
    background: var(--blk);
    color: var(--yel);
    border: 2px solid var(--blk);
    border-radius: var(--rr2);
    font-size: .79rem;
    font-weight: 800;
    cursor: pointer;
    transition: all .15s;
    flex-shrink: 0;
    text-transform: uppercase;
}

.url-share-bar .usb-copy:hover {
    background: var(--yel);
    color: var(--blk);
    border-color: var(--blk);
}

/* ===== VIS HELPERS ===== */
.show-desktop { display: block; }
.show-mobile { display: none; }

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
    .film-grid { grid-template-columns: repeat(2, 1fr); gap: 7px; }
    .show-desktop { display: none; }
    .show-mobile { display: block; }
}

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

    .header-sitename { font-size: 1.06rem; }
    .domain-capsule .cap-addr { font-size: .93rem; }

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

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

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

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

    /* Search: single row no wrap */
    .search-zone form {
        flex-wrap: nowrap;
        gap: 4px;
    }

    .search-zone input[type="text"] {
        height: 34px;
        font-size: .77rem;
        padding: 0 7px;
    }

    .search-zone button {
        height: 34px;
        padding: 0 7px;
        font-size: .72rem;
    }

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

    .film-poster { aspect-ratio: 600 / 350; }
    .film-meta h5 { font-size: .71rem; }
    .media-section { padding: 8px 8px 6px; }
    .action-link-btn { padding: 9px 13px; font-size: .83rem; }
}

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

@media (max-width: 380px) {
    .channel-zone-tag { font-size: 10px; }
    .channel-links a { font-size: 12px; }
    .search-zone button { padding: 0 5px; font-size: .67rem; }
}
