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

:root {
    --page-bg: #1e2a3a;
    --surface: #243040;
    --surface2: #2d3a4e;
    --surface3: #354358;
    --surface4: #3d4f66;
    --lime: #6abf4b;
    --lime-dk: #54a037;
    --lime-lt: rgba(106,191,75,.18);
    --lime-glow: rgba(106,191,75,.32);
    --white: #ffffff;
    --white85: rgba(255,255,255,.85);
    --white60: rgba(255,255,255,.60);
    --white35: rgba(255,255,255,.35);
    --white15: rgba(255,255,255,.15);
    --white08: rgba(255,255,255,.08);
    --white05: rgba(255,255,255,.05);
    --txt: #ffffff;
    --txt2: rgba(255,255,255,.85);
    --txt3: rgba(255,255,255,.50);
    --bdr: rgba(255,255,255,.10);
    --bdr2: rgba(255,255,255,.18);
    --sh1: 0 2px 8px rgba(0,0,0,.3);
    --sh2: 0 4px 16px rgba(0,0,0,.4);
    --sh3: 0 8px 28px rgba(0,0,0,.5);
    --r: 10px;
    --r2: 6px;
    --r3: 12px;
}

html { font-size: 15px; }

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

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

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

/* ===== SITE HEADER ===== */
.eb-topbar {
    background: var(--surface);
    border-bottom: 1px solid var(--bdr);
    padding: 10px 0;
    box-shadow: var(--sh1);
}

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

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

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

.eb-site-name {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--white);
    font-style: normal;
    letter-spacing: -.2px;
    text-decoration: none;
    border-bottom: none;
}

.eb-domain-node {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--surface3);
    border: 1px solid var(--lime);
    border-radius: 22px;
    padding: 4px 15px;
}

.eb-domain-node .dn-label {
    font-size: 0.68rem;
    color: var(--white35);
    white-space: nowrap;
}

.eb-domain-node .dn-value {
    font-size: 1.12rem;
    font-weight: 800;
    color: var(--lime);
    white-space: nowrap;
}

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

/* ===== CATEGORY NAV ===== */
.eb-navframe {
    background: var(--surface);
    border: 1px solid var(--bdr);
    border-radius: var(--r);
    overflow: hidden;
    margin: 4px 0;
    box-shadow: var(--sh1);
}

.eb-navstrip {
    display: flex;
    align-items: stretch;
    border-bottom: 1px solid var(--bdr);
    min-height: 38px;
}

.eb-navstrip:last-child { border-bottom: none; }

.eb-zone-badge {
    background: var(--surface3);
    color: var(--lime);
    font-size: 10px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 5px 2px;
    width: 62px;
    min-width: 62px;
    border-right: 1px solid var(--bdr);
    text-align: center;
    line-height: 1.3;
    letter-spacing: .3px;
    flex-shrink: 0;
}

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

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

.eb-navlinks a:hover {
    background: var(--lime-lt);
    color: var(--lime);
    border-color: rgba(106,191,75,.4);
}

.eb-navlinks a.active {
    background: var(--lime);
    color: #fff;
    border-color: var(--lime-dk);
    font-weight: 700;
}

/* ===== SEARCH ===== */
.eb-searchbar {
    background: var(--surface);
    border: 1px solid var(--bdr);
    border-radius: var(--r);
    padding: 8px 12px;
    margin: 4px 0;
    box-shadow: var(--sh1);
}

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

.eb-searchbar input[type="text"] {
    flex: 1;
    min-width: 0;
    height: 36px;
    border: 1px solid var(--bdr2);
    border-radius: 20px;
    padding: 0 16px;
    font-size: .88rem;
    color: var(--white);
    background: var(--surface2);
    outline: none;
    transition: border-color .15s, box-shadow .15s;
    font-family: inherit;
}

.eb-searchbar input[type="text"]::placeholder { color: var(--white35); }

.eb-searchbar input[type="text"]:focus {
    border-color: var(--lime);
    box-shadow: 0 0 0 3px var(--lime-glow);
}

.eb-searchbar button {
    height: 36px;
    padding: 0 13px;
    border: none;
    border-radius: 20px;
    background: var(--surface3);
    color: var(--white85);
    font-size: .82rem;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    transition: all .15s;
    flex-shrink: 0;
    font-family: inherit;
    border: 1px solid var(--bdr2);
}

.eb-searchbar button:hover {
    background: var(--white15);
    color: var(--white);
    border-color: var(--white35);
}

.eb-searchbar button[value="1"] {
    background: var(--lime);
    color: #fff;
    border-color: var(--lime-dk);
}
.eb-searchbar button[value="1"]:hover { background: var(--lime-dk); }

.eb-searchbar button[value="2"] {
    background: transparent;
    color: var(--lime);
    border: 1px solid var(--lime);
}
.eb-searchbar button[value="2"]:hover {
    background: var(--lime-lt);
    color: #fff;
}

/* ===== HOT TAGS ===== */
.eb-tagbar {
    background: var(--surface);
    border: 1px solid var(--bdr);
    border-radius: var(--r);
    padding: 7px 12px;
    margin: 4px 0;
    box-shadow: var(--sh1);
}

.eb-tagbar h4 {
    font-size: .79rem;
    font-weight: 700;
    color: var(--white85);
    margin-bottom: 5px;
}

.eb-taglist {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.eb-taglist .eb-tag {
    display: inline-block;
    background: var(--white05);
    color: var(--white60);
    border: 1px solid var(--bdr);
    border-radius: 12px;
    padding: 2px 10px;
    font-size: .76rem;
    text-decoration: none;
    transition: all .15s;
}

.eb-taglist .eb-tag:hover {
    background: var(--lime-lt);
    color: var(--lime);
    border-color: rgba(106,191,75,.4);
}

/* ===== CONTENT SECTION ===== */
.eb-section {
    background: var(--surface);
    border: 1px solid var(--bdr);
    border-radius: var(--r3);
    padding: 13px 13px 10px;
    margin: 4px 0;
    box-shadow: var(--sh1);
}

.eb-section-hd {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--bdr);
    position: relative;
}

.eb-section-hd::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -1px;
    width: 34px;
    height: 2px;
    background: var(--lime);
    border-radius: 2px;
}

.eb-section-hd h3 {
    font-size: .98rem;
    font-weight: 700;
    color: var(--white);
}

.eb-section-hd h3 a { color: var(--white); }
.eb-section-hd h3 a:hover { color: var(--lime); }

.eb-section-hd h4 {
    font-size: .95rem;
    font-weight: 700;
    color: var(--white);
}

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

.eb-grid li {
    border-radius: var(--r2);
    overflow: hidden;
    border: 1px solid var(--bdr);
    background: var(--surface2);
    transition: box-shadow .2s, transform .2s, border-color .2s;
}

.eb-grid li:hover {
    box-shadow: 0 6px 24px rgba(106,191,75,.2);
    transform: translateY(-2px);
    border-color: rgba(106,191,75,.35);
}

.eb-filmlink {
    display: block;
    width: 100%;
    aspect-ratio: 600 / 350;
    overflow: hidden;
    background: var(--surface3);
}

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

.eb-filmlink:hover img { transform: scale(1.04); }

.eb-filmtext {
    padding: 5px 7px 7px;
}

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

.eb-filmtext h5 a { color: var(--white85); }
.eb-filmtext h5 a:hover { color: var(--lime); }

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

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

.eb-pgrow a.ebp {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    background: var(--surface2);
    border: 1px solid var(--bdr2);
    border-radius: var(--r2);
    font-size: .84rem;
    color: var(--white60);
    text-decoration: none;
    transition: all .15s;
}

.eb-pgrow a.ebp:hover {
    background: var(--lime-lt);
    border-color: rgba(106,191,75,.45);
    color: var(--lime);
}

.eb-pgrow a.ebp-on {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    background: var(--lime);
    border: 1px solid var(--lime-dk);
    border-radius: var(--r2);
    font-size: .84rem;
    font-weight: 700;
    color: #fff;
    cursor: default;
    box-shadow: 0 2px 10px var(--lime-glow);
}

/* ===== FOOTER ===== */
.eb-flink-area {
    background: var(--surface);
    border: 1px solid var(--bdr);
    border-radius: var(--r);
    padding: 9px 13px;
    margin: 4px 0;
    box-shadow: var(--sh1);
}

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

.eb-flinks dd { display: inline; }

.eb-flinks a {
    display: inline-block;
    font-size: .77rem;
    color: var(--white35);
    padding: 2px 9px;
    border-radius: 4px;
    border: 1px solid var(--bdr);
    background: var(--white05);
    text-decoration: none;
    transition: all .15s;
}

.eb-flinks a:hover {
    color: var(--lime);
    border-color: rgba(106,191,75,.4);
    background: var(--lime-lt);
}

.eb-cr-line {
    text-align: center;
    padding: 8px 0 14px;
    color: var(--white35);
    font-size: .76rem;
}

/* ===== DETAIL PAGES ===== */
.eb-dtl-title {
    line-height: 1.8;
    text-align: center;
    padding: 12px 15px;
    font-size: .98rem;
    margin: 4px 0;
    word-break: break-all;
    background: var(--surface);
    border: 1px solid var(--bdr);
    border-left: 3px solid var(--lime);
    border-radius: var(--r);
    box-shadow: var(--sh1);
    color: var(--white85);
}

.eb-dtl-title a {
    color: var(--lime);
    font-weight: 700;
    margin-right: 6px;
}

.eb-dtl-title a:hover { color: #fff; }

.eb-dtl-body {
    font-size: .9rem;
    line-height: 1.95;
    padding: 15px 18px;
    background: var(--surface);
    border: 1px solid var(--bdr);
    border-radius: var(--r);
    box-shadow: var(--sh1);
    margin: 4px 0;
    color: var(--white85);
}

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

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

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

.eb-dl-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 10px 24px;
    background: var(--lime);
    color: #fff;
    border: none;
    border-radius: 24px;
    font-size: .9rem;
    font-weight: 700;
    cursor: pointer;
    transition: all .18s;
    text-decoration: none;
    font-family: inherit;
    box-shadow: 0 3px 14px var(--lime-glow);
}

.eb-dl-btn:hover {
    background: var(--lime-dk);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 6px 20px var(--lime-glow);
}

.eb-hint {
    text-align: center;
    padding: 7px;
    font-size: .82rem;
}

.eb-hint a { color: var(--white60); font-weight: 600; }
.eb-hint a:hover { color: var(--lime); }

/* ===== SHARE BAR ===== */
.eb-sharerow {
    display: flex;
    align-items: center;
    gap: 9px;
    background: var(--surface);
    border: 1px solid var(--bdr);
    border-radius: var(--r);
    padding: 8px 13px;
    margin: 4px 0;
    flex-wrap: wrap;
}

.eb-sharerow .er-lbl { font-size: .77rem; color: var(--white35); white-space: nowrap; }
.eb-sharerow .er-url { font-size: .79rem; color: var(--white60); flex: 1; min-width: 0; word-break: break-all; }

.eb-sharerow .er-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 6px 14px;
    background: var(--lime);
    color: #fff;
    border: none;
    border-radius: 18px;
    font-size: .8rem;
    font-weight: 600;
    cursor: pointer;
    transition: background .15s;
    flex-shrink: 0;
    font-family: inherit;
}

.eb-sharerow .er-btn:hover { background: var(--lime-dk); }

/* ===== VIS HELPERS ===== */
.eb-dpc { display: block; }
.eb-dmb { display: none; }

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

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

    .eb-site-name { font-size: 1.08rem; }
    .eb-domain-node .dn-value { font-size: .94rem; }

    .eb-navstrip { align-items: stretch; }

    .eb-zone-badge {
        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;
    }

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

    .eb-navlinks 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 */
    .eb-searchbar form {
        flex-wrap: nowrap;
        gap: 4px;
    }

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

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

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

    .eb-filmlink { aspect-ratio: 600 / 350; }
    .eb-filmtext h5 { font-size: .72rem; }
    .eb-section { padding: 9px 9px 7px; }
    .eb-dl-btn { padding: 9px 16px; font-size: .84rem; }
}

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

@media (max-width: 380px) {
    .eb-zone-badge { font-size: 10px; }
    .eb-navlinks a { font-size: 12px; }
    .eb-searchbar button { padding: 0 5px; font-size: .68rem; }
}
