/* ===== Design Tokens ===== */
:root {
    --cream: #eeeade;
    --cream-dark: #e4e0d2;
    --cream-light: #f5f3ec;
    --ink: #1a1810;
    --ink-mid: #3d3a2e;
    --ink-muted: #7a7665;
    --ink-dim: #b0ab98;
    --yellow: #e5e040;
    --yellow-dark: #c9ca00;
    --yellow-bg: #f0ef8a;
    --surface: #ffffff;
    --surface2: #f7f5ef;
    --border: #dedad0;
    --border-dark: #c8c4b6;
    --shadow-nav: 0 2px 16px rgba(26,24,16,0.09);
    --shadow-card: 0 1px 6px rgba(26,24,16,0.06);
    --shadow-hover: 0 6px 24px rgba(26,24,16,0.13);
    --r-xs: 6px;
    --r-sm: 12px;
    --r-md: 18px;
    --r-lg: 24px;
    --r-xl: 40px;
    --max-w: 1200px;
}

/* ===== Reset ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; }
body {
    font-family: 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    background: var(--cream);
    color: var(--ink);
    line-height: 1.6;
    min-height: 100vh;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
ul, ol { list-style: none; }

/* ===== Layout ===== */
.seg { width: 100%; margin-bottom: 8px; }
.seg-in {
    max-width: var(--max-w);
    margin: 0 auto;
    padding: 0 16px;
}

/* ===== Site Header ===== */
.pg-hd {
    margin: 10px 0 8px;
}
.pg-hd .seg-in {
    display: flex;
    align-items: center;
    padding-top: 10px;
    padding-bottom: 10px;
    gap: 18px;
    flex-wrap: nowrap;
    padding-left: 20px;
    padding-right: 20px;
    background: var(--surface);
    border-radius: var(--r-lg);
    box-shadow: var(--shadow-nav);
}
.hd-identity {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: nowrap;
}
.site-nm-lk { display: inline-block; }
.site-nm-tx {
    font-size: 21px;
    font-weight: 900;
    color: var(--ink);
    letter-spacing: -0.5px;
    white-space: nowrap;
    font-style: normal;
    text-decoration: none;
    border-bottom: none;
    line-height: 1;
}
.site-nm-tx:hover { color: var(--ink-mid); }

.url-chip {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: var(--yellow-bg);
    border: 1.5px solid var(--yellow-dark);
    border-radius: var(--r-xl);
    padding: 4px 14px 4px 10px;
    flex-shrink: 0;
}
.url-chip-lbl {
    font-size: 10px;
    color: var(--ink-mid);
    font-weight: 800;
    letter-spacing: 1px;
    text-transform: uppercase;
    white-space: nowrap;
}
.url-chip-val {
    font-size: 16px;
    color: var(--ink);
    font-weight: 800;
    white-space: nowrap;
}

/* ===== Banner strip ===== */
.banner-area { margin: 6px 0; }
.banner-area a img { border-radius: var(--r-md); width: 100%; }

/* ===== Category Navigation ===== */
.cat-panel {
    background: var(--surface);
    border: 1.5px solid var(--border);
    border-radius: var(--r-lg);
    overflow: hidden;
    box-shadow: var(--shadow-card);
    margin-bottom: 8px;
}
.cat-strip {
    display: flex;
    align-items: stretch;
    border-bottom: 1px solid var(--border);
}
.cat-strip:last-child { border-bottom: none; }

.cat-zone-nm {
    flex: 0 0 80px;
    background: var(--cream);
    border-right: 2px solid var(--border);
    color: var(--ink-muted);
    font-size: 11px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 6px 4px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}
.cat-lnks {
    flex: 1;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    padding: 5px 8px;
    gap: 5px;
}
.cat-lnks a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 5px 0;
    flex: 1 0 calc(12.5% - 5px);
    min-width: 0;
    background: var(--cream-light);
    border: 1.5px solid var(--border);
    border-radius: var(--r-sm);
    color: var(--ink-mid);
    font-size: 13px;
    font-weight: 600;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: all 0.16s;
}
.cat-lnks a:hover {
    background: var(--yellow-bg);
    color: var(--ink);
    border-color: var(--yellow-dark);
}
.cat-lnks a.active {
    background: var(--yellow);
    color: var(--ink);
    border-color: var(--yellow-dark);
    font-weight: 800;
    box-shadow: 0 2px 8px rgba(229,224,64,0.4);
}

/* ===== Search ===== */
.srch-bar {
    background: var(--surface);
    border: 1.5px solid var(--border);
    border-radius: var(--r-lg);
    padding: 13px 18px;
    box-shadow: var(--shadow-card);
    margin-bottom: 8px;
}
.srch-frm {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}
.srch-frm input[type="text"] {
    flex: 1 1 200px;
    min-width: 0;
    padding: 9px 16px;
    border: 1.5px solid var(--border-dark);
    border-radius: var(--r-xl);
    font-size: 14px;
    color: var(--ink);
    background: var(--cream-light);
    outline: none;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.srch-frm input[type="text"]::placeholder { color: var(--ink-dim); }
.srch-frm input[type="text"]:focus {
    border-color: var(--ink);
    background: var(--surface);
}
.srch-frm button {
    padding: 9px 20px;
    border: none;
    border-radius: var(--r-xl);
    font-size: 14px;
    font-weight: 800;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.16s;
}
.srch-frm button:hover { transform: translateY(-1px); box-shadow: var(--shadow-hover); }
.srch-frm button[value="1"] { background: var(--yellow); color: var(--ink); border: 1.5px solid var(--yellow-dark); }
.srch-frm button[value="2"] { background: var(--ink); color: #fff; }
.srch-frm button:not([value]) {
    background: var(--cream);
    color: var(--ink-muted);
    border: 1.5px solid var(--border-dark);
}

/* ===== Hot Search Tags ===== */
.hot-tags {
    background: var(--surface);
    border: 1.5px solid var(--border);
    border-radius: var(--r-lg);
    padding: 12px 18px;
    box-shadow: var(--shadow-card);
    margin-bottom: 8px;
}
.hot-tags h4 {
    font-size: 13px;
    font-weight: 800;
    color: var(--ink);
    margin-bottom: 9px;
}
.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.tag-row a {
    display: inline-block;
    padding: 4px 14px;
    background: var(--cream);
    border: 1.5px solid var(--border);
    border-radius: var(--r-xl);
    font-size: 12px;
    color: var(--ink-muted);
    font-weight: 600;
    transition: all 0.16s;
}
.tag-row a:hover {
    background: var(--yellow);
    border-color: var(--yellow-dark);
    color: var(--ink);
    transform: translateY(-1px);
}

/* ===== Section Headings ===== */
.media-seg { margin-bottom: 8px; }
.sec-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
    padding-bottom: 9px;
    border-bottom: 2px solid var(--border);
    position: relative;
}
.sec-head::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 44px;
    height: 2px;
    background: var(--yellow-dark);
    border-radius: 2px;
}
.sec-head h3 {
    font-size: 15px;
    font-weight: 900;
    color: var(--ink);
    letter-spacing: -0.2px;
}
.sec-head h3 a {
    color: var(--ink-muted);
    font-size: 12px;
    font-weight: 700;
    transition: color 0.15s;
}
.sec-head h3 a:hover { color: var(--ink); }

/* ===== Media Grid ===== */
.vid-grd {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}
.v-cd {
    background: var(--surface);
    border: 1.5px solid var(--border);
    border-radius: var(--r-md);
    overflow: hidden;
    transition: all 0.2s;
    box-shadow: var(--shadow-card);
}
.v-cd:hover {
    box-shadow: var(--shadow-hover);
    border-color: var(--border-dark);
    transform: translateY(-3px);
}
.v-thumb {
    display: block;
    width: 100%;
    aspect-ratio: 600 / 350;
    overflow: hidden;
    background: var(--cream);
}
.v-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}
.v-cd:hover .v-thumb img { transform: scale(1.05); }
.v-cap {
    padding: 8px 10px;
    border-top: 1px solid var(--border);
}
.v-cap h5 {
    font-size: 12px;
    font-weight: 600;
    color: var(--ink-mid);
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-height: 1.45;
}
.v-cap h5 a { color: inherit; }
.v-cap h5 a:hover { color: var(--ink); }

/* ===== Entry Detail ===== */
.ent-hd {
    background: var(--surface);
    border: 1.5px solid var(--border);
    border-radius: var(--r-lg);
    padding: 18px 22px;
    margin-bottom: 10px;
    text-align: center;
    font-size: 17px;
    word-break: break-all;
    line-height: 1.8;
    box-shadow: var(--shadow-card);
}
.ent-hd .ct-lk {
    display: inline-block;
    background: var(--yellow-bg);
    color: var(--ink);
    font-weight: 800;
    margin-right: 8px;
    font-size: 12px;
    padding: 2px 10px;
    border-radius: var(--r-xl);
    border: 1px solid var(--yellow-dark);
}
.ent-hd b { color: var(--ink); }

.ent-meta {
    background: var(--surface);
    border: 1.5px solid var(--border);
    border-radius: var(--r-lg);
    padding: 20px 24px;
    font-size: 14px;
    line-height: 2.1;
    margin-bottom: 10px;
    box-shadow: var(--shadow-card);
}
.ent-meta .mk {
    color: var(--ink);
    font-weight: 800;
}

/* Preview */
.cap-img { margin-top: 12px; }
.cap-img picture img {
    width: 100%;
    height: auto;
    border-radius: var(--r-sm);
    display: block;
}

/* ===== Action Buttons ===== */
.dl-grp {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    margin: 18px 0;
}
.dl-b {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 12px 32px;
    border: none;
    border-radius: var(--r-xl);
    font-size: 14px;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.16s;
    text-decoration: none;
    letter-spacing: 0.1px;
}
.dl-b:hover { transform: translateY(-2px); box-shadow: var(--shadow-hover); }
.dl-b-y { background: var(--yellow); color: var(--ink); border: 1.5px solid var(--yellow-dark); }
.dl-b-k { background: var(--ink); color: #fff; }
.dl-b-o { background: var(--surface); color: var(--ink-muted); border: 1.5px solid var(--border-dark); }
.dl-b-o:hover { border-color: var(--ink); color: var(--ink); box-shadow: none; }

.cl-hint {
    text-align: center;
    padding: 10px;
    font-size: 13px;
}
.cl-hint a { color: var(--ink); font-weight: 700; text-decoration: underline; }

/* ===== Share ===== */
.shr-bx {
    background: var(--surface);
    border: 1.5px solid var(--border);
    border-radius: var(--r-lg);
    padding: 12px 18px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 10px;
    box-shadow: var(--shadow-card);
}
.shr-lft {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    min-width: 0;
    overflow: hidden;
}
.shr-badge {
    font-size: 10px;
    background: var(--yellow);
    color: var(--ink);
    padding: 2px 9px;
    border-radius: var(--r-xl);
    font-weight: 800;
    white-space: nowrap;
    flex-shrink: 0;
    border: 1px solid var(--yellow-dark);
}
.shr-link {
    font-size: 12px;
    color: var(--ink-dim);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.shr-cp-btn {
    background: var(--cream);
    color: var(--ink);
    border: 1.5px solid var(--border-dark);
    border-radius: var(--r-xl);
    padding: 7px 16px;
    font-size: 12px;
    font-weight: 800;
    cursor: pointer;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: all 0.16s;
}
.shr-cp-btn:hover { background: var(--yellow); border-color: var(--yellow-dark); }

/* ===== Pagination ===== */
.pg-nav {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 6px;
    padding: 16px 0;
}
.pg-nav a,
.pg-nav .pg-now {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 12px;
    border-radius: var(--r-xl);
    font-size: 13px;
    font-weight: 700;
    border: 1.5px solid var(--border);
    background: var(--surface);
    color: var(--ink-muted);
    transition: all 0.16s;
}
.pg-nav a:hover {
    background: var(--yellow-bg);
    border-color: var(--yellow-dark);
    color: var(--ink);
}
.pg-nav .pg-now {
    background: var(--yellow);
    color: var(--ink);
    border-color: var(--yellow-dark);
    font-weight: 900;
}

/* ===== Footer ===== */
.fl-bx {
    background: var(--surface);
    border: 1.5px solid var(--border);
    border-radius: var(--r-lg);
    padding: 12px 18px;
    margin-bottom: 8px;
    box-shadow: var(--shadow-card);
}
.fl-bx h4 {
    font-size: 11px;
    font-weight: 800;
    color: var(--ink-muted);
    margin-bottom: 9px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    border-bottom: 1px solid var(--border);
    padding-bottom: 7px;
}
.fl-rw {
    display: flex;
    flex-wrap: wrap;
    gap: 5px 14px;
}
.fl-rw a {
    font-size: 12px;
    color: var(--ink-dim);
    transition: color 0.15s;
}
.fl-rw a:hover { color: var(--ink); }

.ft-end {
    background: var(--cream-dark);
    border-top: 1px solid var(--border);
    padding: 14px 16px;
    text-align: center;
    font-size: 12px;
    color: var(--ink-muted);
}

/* ===== Utilities ===== */
.clearfix::after { content: ''; display: table; clear: both; }
.hide-mobile { display: block; }
.hide-pc { display: none; }

/* ===== Responsive ===== */
@media (max-width: 992px) {
    .vid-grd { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .hide-mobile { display: none; }
    .hide-pc { display: block; }
    .pg-hd { margin: 6px 0; }

    .site-nm-tx { font-size: 16px; }
    .url-chip-val { font-size: 13px; }

    .cat-zone-nm {
        flex: 0 0 15%;
        font-size: 10px;
        padding: 4px 2px;
        letter-spacing: 0;
    }
    .cat-lnks {
        flex: 0 0 85%;
        padding: 4px;
        gap: 3px;
    }
    .cat-lnks a {
        flex: 1 0 calc(25% - 3px);
        font-size: 12px;
        padding: 5px 2px;
    }
}

@media (min-width: 481px) and (max-width: 768px) {
    .cat-lnks a { font-size: 14px; }
}

@media (min-width: 769px) {
    .cat-zone-nm { flex: 0 0 80px; font-size: 11px; }
    .cat-lnks a {
        flex: 1 0 calc(12.5% - 5px);
        font-size: 13px;
    }
}
