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

:root {
    --ad-purple:    #3d0a8c;
    --ad-purple2:   #4a0fa8;
    --ad-purple3:   #5a18c0;
    --ad-purple-dk: #2a0660;
    --ad-purple-lt: #f0ebff;
    --ad-purple-mid:#c8b0f0;
    --ad-purple-bg: rgba(61,10,140,.10);
    --ad-gold:      #f5a800;
    --ad-gold-dk:   #d48e00;
    --ad-gold-lt:   #fff8e6;
    --ad-gold-mid:  #f8d070;
    --ad-violet:    #6b2fc8;
    --ad-violet-lt: #e8e0ff;
    --bg:           #ffffff;
    --bg-soft:      #f7f6ff;
    --bg-muted:     #eeeaff;
    --ink:          #1a0840;
    --ink2:         #2e1460;
    --ink3:         #7a609a;
    --ink4:         #b8a8cc;
    --rule:         #e2dcf5;
    --rule2:        #cfc7ea;
    --sh1: 0 1px 4px rgba(61,10,140,.07);
    --sh2: 0 4px 18px rgba(61,10,140,.12);
    --sh3: 0 8px 30px rgba(61,10,140,.18);
    --rd:   6px;
    --rd-sm: 3px;
    --rd-lg: 10px;
    --rd-xl: 14px;
    --rd-pill: 40px;
}

html { font-size: 15px; }

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

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

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

/* ===== SITE HEADER ===== */
.ad-header {
    background: var(--ad-purple);
    border-bottom: 3px solid var(--ad-gold);
    padding: 9px 0;
    box-shadow: 0 2px 14px rgba(61,10,140,.45);
}

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

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

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

.ad-sitename {
    font-size: 1.38rem;
    font-weight: 900;
    color: #fff;
    letter-spacing: -.3px;
    font-style: normal;
    text-decoration: none;
    border-bottom: none;
}

.ad-sitename em {
    color: var(--ad-gold);
    font-style: normal;
}

.ad-domain-badge {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: var(--ad-gold);
    border-radius: var(--rd-sm);
    padding: 5px 17px;
    box-shadow: 0 3px 12px rgba(245,168,0,.35);
}

.ad-domain-badge .adb-hint {
    font-size: 0.61rem;
    color: rgba(0,0,0,.55);
    white-space: nowrap;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .5px;
}

.ad-domain-badge .adb-url {
    font-size: 1.07rem;
    font-weight: 900;
    color: #1a0840;
    white-space: nowrap;
}

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

/* ===== CATEGORY NAV ===== */
.ad-nav {
    background: var(--ad-purple);
    border: 1px solid rgba(255,255,255,.1);
    border-radius: var(--rd-xl);
    overflow: hidden;
    margin: 3px 0;
    box-shadow: var(--sh2);
}

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

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

.ad-nav-zone {
    background: rgba(0,0,0,.25);
    color: var(--ad-gold);
    font-size: .67rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 5px 2px;
    width: 62px;
    min-width: 62px;
    border-right: 1px solid rgba(255,255,255,.08);
    text-align: center;
    line-height: 1.3;
    letter-spacing: .4px;
    flex-shrink: 0;
    text-transform: uppercase;
}

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

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

.ad-nav-links a:hover {
    background: rgba(245,168,0,.18);
    color: var(--ad-gold);
    border-color: rgba(245,168,0,.35);
}

.ad-nav-links a.active {
    background: var(--ad-gold);
    color: var(--ad-purple-dk);
    border-color: var(--ad-gold);
    font-weight: 800;
}

/* ===== SEARCH ===== */
.ad-search {
    background: var(--ad-purple);
    border: 1px solid rgba(255,255,255,.1);
    border-radius: var(--rd-xl);
    padding: 10px 16px;
    margin: 3px 0;
    box-shadow: var(--sh2);
}

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

.ad-search input[type="text"] {
    flex: 1;
    min-width: 0;
    height: 38px;
    border: 1px solid rgba(255,255,255,.2);
    border-radius: var(--rd-pill);
    padding: 0 16px;
    font-size: .87rem;
    color: #fff;
    background: rgba(255,255,255,.1);
    outline: none;
    transition: border-color .18s, box-shadow .18s;
}

.ad-search input[type="text"]::placeholder { color: rgba(255,255,255,.4); }

.ad-search input[type="text"]:focus {
    border-color: var(--ad-gold);
    box-shadow: 0 0 0 2px rgba(245,168,0,.2);
    background: rgba(255,255,255,.15);
}

.ad-search button {
    height: 38px;
    padding: 0 14px;
    border: 1px solid rgba(255,255,255,.2);
    border-radius: var(--rd-pill);
    background: rgba(255,255,255,.12);
    color: rgba(255,255,255,.85);
    font-size: .8rem;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
    transition: all .15s;
    flex-shrink: 0;
}

.ad-search button:hover {
    background: rgba(255,255,255,.22);
    color: #fff;
}

.ad-search button[value="1"] {
    background: var(--ad-gold);
    color: var(--ad-purple-dk);
    border-color: var(--ad-gold);
    font-weight: 900;
    box-shadow: 0 2px 10px rgba(245,168,0,.3);
}

.ad-search button[value="1"]:hover {
    background: var(--ad-gold-dk);
    border-color: var(--ad-gold-dk);
    box-shadow: 0 4px 16px rgba(245,168,0,.4);
}

.ad-search button[value="2"] {
    background: var(--ad-violet);
    color: #fff;
    border-color: var(--ad-violet);
}

.ad-search button[value="2"]:hover {
    background: var(--ad-purple3);
    border-color: var(--ad-purple3);
}

/* ===== HOT TAGS ===== */
.ad-hotwords {
    background: var(--bg);
    border: 1.5px solid var(--rule);
    border-radius: var(--rd-lg);
    padding: 8px 14px;
    margin: 3px 0;
    box-shadow: var(--sh1);
}

.ad-hotwords h4 {
    font-size: .75rem;
    font-weight: 800;
    color: var(--ad-purple);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: .5px;
}

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

.ad-tag-list .adtag {
    display: inline-block;
    background: var(--ad-purple-lt);
    color: var(--ad-purple);
    border: 1.5px solid var(--ad-purple-mid);
    border-radius: var(--rd-pill);
    padding: 2px 11px;
    font-size: .73rem;
    font-weight: 600;
    text-decoration: none;
    transition: all .15s;
}

.ad-tag-list .adtag:hover {
    background: var(--ad-gold);
    color: var(--ad-purple-dk);
    border-color: var(--ad-gold);
}

/* ===== CONTENT SECTION ===== */
.ad-section {
    background: var(--bg);
    border: 1.5px solid var(--rule);
    border-radius: var(--rd-xl);
    padding: 13px 15px 11px;
    margin: 4px 0;
    box-shadow: var(--sh1);
}

.ad-sect-hd {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 11px;
    padding-bottom: 9px;
    border-bottom: 2px solid var(--bg-muted);
    position: relative;
}

.ad-sect-hd::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 36px;
    height: 2px;
    background: var(--ad-gold);
    border-radius: 2px;
    box-shadow: 0 0 6px rgba(245,168,0,.4);
}

.ad-sect-hd h3 {
    font-size: .97rem;
    font-weight: 900;
    color: var(--ad-purple);
}

.ad-sect-hd h3 a { color: var(--ad-purple); }
.ad-sect-hd h3 a:hover { color: var(--ad-gold-dk); }

.ad-sect-hd h4 {
    font-size: .95rem;
    font-weight: 900;
    color: var(--ad-purple);
}

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

.ad-film-grid li {
    border-radius: var(--rd-lg);
    overflow: hidden;
    border: 1.5px solid var(--rule);
    background: var(--bg-soft);
    transition: box-shadow .2s, transform .2s;
}

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

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

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

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

.ad-film-desc {
    padding: 6px 9px 9px;
    border-top: 1px solid var(--rule);
}

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

.ad-film-desc h5 a { color: var(--ink2); }
.ad-film-desc h5 a:hover { color: var(--ad-purple); }

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

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

.ad-pager-row a.adpb {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    background: var(--bg);
    border: 1.5px solid var(--rule2);
    border-radius: var(--rd-sm);
    font-size: .82rem;
    color: var(--ink2);
    text-decoration: none;
    transition: all .15s;
}

.ad-pager-row a.adpb:hover {
    background: var(--ad-purple-lt);
    border-color: var(--ad-purple);
    color: var(--ad-purple);
}

.ad-pager-row a.adpb-on {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    background: var(--ad-purple);
    border: 1.5px solid var(--ad-purple);
    border-radius: var(--rd-sm);
    font-size: .82rem;
    font-weight: 800;
    color: #fff;
    cursor: default;
    box-shadow: 0 2px 8px var(--ad-purple-bg);
}

/* ===== FOOTER ===== */
.ad-ftr {
    background: var(--ad-purple-dk);
    border-radius: var(--rd-lg);
    padding: 10px 15px;
    margin: 4px 0;
}

.ad-ftr .ad-sect-hd { border-bottom-color: rgba(255,255,255,.1); }
.ad-ftr .ad-sect-hd::after { background: var(--ad-gold); }
.ad-ftr .ad-sect-hd h4 { color: rgba(255,255,255,.45); }

.ad-flinks {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.ad-flinks dd { display: inline; }

.ad-flinks a {
    display: inline-block;
    font-size: .74rem;
    color: rgba(255,255,255,.38);
    padding: 2px 9px;
    border-radius: var(--rd-sm);
    border: 1px solid rgba(255,255,255,.08);
    background: rgba(255,255,255,.04);
    text-decoration: none;
    transition: all .15s;
}

.ad-flinks a:hover {
    color: var(--ad-gold);
    border-color: rgba(245,168,0,.4);
    background: rgba(245,168,0,.1);
}

.ad-cr {
    text-align: center;
    padding: 8px 0 14px;
    color: var(--ink4);
    font-size: .73rem;
}

/* ===== DETAIL PAGES ===== */
.ad-entry-hd {
    line-height: 1.8;
    padding: 12px 18px;
    font-size: .97rem;
    margin: 4px 0;
    word-break: break-all;
    background: var(--ad-purple);
    border: none;
    border-left: 4px solid var(--ad-gold);
    border-radius: var(--rd-lg);
    box-shadow: var(--sh2);
    color: #fff;
}

.ad-entry-hd a {
    color: var(--ad-gold);
    font-weight: 700;
    margin-right: 8px;
    font-size: .75rem;
    text-transform: uppercase;
    letter-spacing: .4px;
}

.ad-entry-hd b { color: #fff; font-weight: 800; }

.ad-entry-specs {
    font-size: .9rem;
    line-height: 1.9;
    padding: 14px 18px;
    background: var(--bg);
    border: 1.5px solid var(--rule);
    border-radius: var(--rd-lg);
    box-shadow: var(--sh1);
    margin: 4px 0;
    color: var(--ink2);
}

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

.ad-preview-fig picture,
.ad-preview-fig img {
    width: 100%;
    height: auto;
    border-radius: var(--rd-sm);
    display: block;
}

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

.ad-op-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 10px 26px;
    background: var(--ad-gold);
    color: var(--ad-purple-dk);
    border: none;
    border-radius: var(--rd-sm);
    font-size: .9rem;
    font-weight: 900;
    cursor: pointer;
    transition: background .18s, transform .15s, box-shadow .18s;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: .4px;
    box-shadow: 0 4px 14px rgba(245,168,0,.3);
}

.ad-op-btn:hover {
    background: var(--ad-gold-dk);
    color: var(--ad-purple-dk);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(245,168,0,.4);
}

.ad-dl-tip {
    text-align: center;
    padding: 6px;
    font-size: .81rem;
}

.ad-dl-tip a { color: var(--ink3); font-weight: 600; }
.ad-dl-tip a:hover { color: var(--ad-purple); }

/* ===== SHARE BAR ===== */
.ad-share-bar {
    display: flex;
    align-items: center;
    gap: 9px;
    background: var(--ad-purple-lt);
    border: 1.5px solid var(--ad-purple-mid);
    border-radius: var(--rd-lg);
    padding: 9px 15px;
    margin: 4px 0;
    flex-wrap: wrap;
}

.ad-share-bar .asb-lbl { font-size: .72rem; color: var(--ad-purple); white-space: nowrap; font-weight: 700; text-transform: uppercase; letter-spacing: .4px; }
.ad-share-bar .asb-url { font-size: .77rem; color: var(--ink2); flex: 1; min-width: 0; word-break: break-all; }

.ad-share-bar .asb-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 6px 14px;
    background: var(--ad-gold);
    color: var(--ad-purple-dk);
    border: none;
    border-radius: var(--rd-sm);
    font-size: .78rem;
    font-weight: 900;
    cursor: pointer;
    transition: background .15s;
    flex-shrink: 0;
    text-transform: uppercase;
    letter-spacing: .3px;
}

.ad-share-bar .asb-btn:hover { background: var(--ad-gold-dk); }

/* ===== VISIBILITY ===== */
.ad-dsk { display: block; }
.ad-mob { display: none; }

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
    .ad-film-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
    .ad-dsk { display: none; }
    .ad-mob { display: block; }
}

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

    .ad-sitename { font-size: 1.08rem; }
    .ad-domain-badge .adb-url { font-size: .9rem; }

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

    .ad-nav-zone {
        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;
    }

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

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

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

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

    .ad-search button {
        height: 34px;
        padding: 0 9px;
        font-size: .73rem;
    }

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

    .ad-poster { aspect-ratio: 600 / 350; }
    .ad-film-desc h5 { font-size: .71rem; }
    .ad-section { padding: 10px 10px 8px; }
    .ad-op-btn { padding: 9px 18px; font-size: .82rem; }
}

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

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