/* Film Portal - Government/Medical Portal Style */

@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@400;500;600;700;900&display=swap');

:root {
    --blue: #3a7bd5;
    --blue-dark: #2563ae;
    --blue-deeper: #1a4f8f;
    --blue-nav: #4a90d9;
    --blue-light: #e8f2fb;
    --blue-lighter: #f0f7ff;
    --sky: #5ba8e5;
    --teal: #2db3a4;
    --orange: #f07d00;
    --gold: #f5a623;
    --red-notice: #c00;
    --dark: #1a1a1a;
    --text: #333333;
    --text-mid: #555555;
    --text-muted: #888888;
    --border: #dde8f5;
    --border-mid: #c8d8ed;
    --border-light: #eef4fc;
    --panel: #ffffff;
    --surface: #f0f4f8;
    --surface2: #f7fafd;
    --shadow-sm: 0 1px 4px rgba(58,123,213,0.08);
    --shadow: 0 2px 12px rgba(58,123,213,0.12);
    --shadow-lg: 0 4px 20px rgba(58,123,213,0.16);
    --radius: 4px;
    --radius-sm: 2px;
    --radius-lg: 6px;
    --ease: all 0.2s ease;
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
    font-family: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', 'SimHei', Arial, sans-serif;
    background: var(--surface);
    color: var(--text);
    font-size: 14px;
    line-height: 1.7;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* ===== SITE HEADER ===== */
.site-header {
    background: #fff;
    border-bottom: 1px solid var(--border);
    padding: 12px 0;
    box-shadow: var(--shadow-sm);
}

.site-header-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    flex-wrap: nowrap;
}

.site-branding {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: nowrap;
}

.brand-logo {
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
    transition: var(--ease);
}
.brand-logo:hover { opacity: 0.85; }

.brand-icon {
    width: 42px;
    height: 42px;
    background: linear-gradient(135deg, var(--blue) 0%, var(--blue-deeper) 100%);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    line-height: 1;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(58,123,213,0.3);
}

.brand-name {
    font-size: 26px;
    font-weight: 900;
    color: var(--blue-deeper);
    letter-spacing: 1px;
    line-height: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.site-domain-wrap {
    display: flex;
    align-items: center;
    gap: 7px;
    background: var(--blue-lighter);
    border: 1px solid var(--border-mid);
    border-radius: var(--radius-lg);
    padding: 6px 14px;
    flex-shrink: 0;
}

.domain-tag {
    font-size: 11px;
    font-weight: 700;
    background: var(--blue);
    color: #fff;
    padding: 2px 7px;
    border-radius: 10px;
    white-space: nowrap;
}

.domain-str {
    font-size: 14px;
    font-weight: 600;
    color: var(--blue-dark);
    font-family: 'Courier New', 'Consolas', monospace;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 200px;
}

/* ===== CONTAINER ===== */
.container { max-width: 1060px; margin: 0 auto; padding: 0 14px; }
.content { padding: 8px 0; }

/* ===== CATEGORY NAV - Sky blue full bar style ===== */
.category-nav-block {
    background: var(--blue-nav);
    overflow: hidden;
    margin-bottom: 8px;
    box-shadow: var(--shadow);
}

.category-row {
    display: flex;
    align-items: stretch;
    border-bottom: 1px solid rgba(255,255,255,0.12);
}
.category-row:last-child { border-bottom: none; }

.category-zone {
    font-size: 12px;
    font-weight: 700;
    color: #fff;
    background: var(--blue-deeper);
    white-space: nowrap;
    width: 9%;
    min-width: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 9px 3px;
    flex-shrink: 0;
    letter-spacing: 0.3px;
    border-right: 1px solid rgba(255,255,255,0.18);
}

.category-links {
    display: flex;
    flex-wrap: nowrap;
    padding: 0;
    width: 91%;
    align-items: stretch;
}

.category-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #e8f4ff;
    font-size: 13px;
    font-weight: 500;
    padding: 9px 0;
    transition: var(--ease);
    white-space: nowrap;
    text-align: center;
    flex: 1;
    border-right: 1px solid rgba(255,255,255,0.10);
    position: relative;
}
.category-links a:last-child { border-right: none; }
.category-links a:hover { color: #fff; background: rgba(255,255,255,0.15); }
.category-links a.active {
    color: #fff;
    font-weight: 700;
    background: rgba(255,255,255,0.22);
}
.category-links a.active::after {
    content: '';
    position: absolute;
    bottom: 0; left: 20%; right: 20%;
    height: 3px;
    background: #fff;
    border-radius: 3px 3px 0 0;
}

/* ===== SEARCH ===== */
.search-wrap {
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 12px 16px;
    margin-bottom: 8px;
    box-shadow: var(--shadow-sm);
}
.search-wrap form { display: flex; gap: 8px; align-items: center; flex-wrap: nowrap; }

.search-wrap input[type="text"] {
    flex: 1;
    min-width: 120px;
    padding: 9px 16px;
    border: 1px solid var(--border-mid);
    border-radius: var(--radius-lg);
    background: var(--surface2);
    color: var(--dark);
    font-size: 14px;
    font-family: inherit;
    outline: none;
    transition: var(--ease);
}
.search-wrap input[type="text"]:focus {
    border-color: var(--blue);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(58,123,213,0.12);
}
.search-wrap input[type="text"]::placeholder { color: #bbb; }

.search-wrap button {
    padding: 9px 16px;
    border: none;
    font-family: inherit;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--ease);
    white-space: nowrap;
    flex-shrink: 0;
    border-radius: var(--radius-lg);
}
.search-wrap button[value="1"],
.search-wrap button[value="2"] { background: var(--blue); color: #fff; }
.search-wrap button[value="1"]:hover,
.search-wrap button[value="2"]:hover { background: var(--blue-dark); box-shadow: 0 3px 10px rgba(58,123,213,0.35); }
.search-wrap button:not([value]) { background: var(--surface2); color: var(--text-mid); border: 1px solid var(--border-mid); }
.search-wrap button:not([value]):hover { background: var(--blue); color: #fff; border-color: var(--blue); }

/* ===== HOT SEARCH ===== */
.hot-search-panel {
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 12px 16px;
    margin-bottom: 8px;
    box-shadow: var(--shadow-sm);
}
.hot-search-panel h4 {
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--blue-deeper);
    display: flex;
    align-items: center;
    gap: 8px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border-light);
}
.hot-search-panel h4::before {
    content: '';
    display: inline-block;
    width: 4px; height: 16px;
    background: var(--blue);
    border-radius: 2px;
    flex-shrink: 0;
}

.tag-list {
    display: flex; flex-wrap: wrap; gap: 7px;
    list-style: none; padding: 0; margin: 0;
}
.tag-list a, .tag-item {
    display: inline-block;
    padding: 4px 13px;
    background: var(--blue-lighter);
    border: 1px solid var(--border);
    border-radius: 16px;
    color: var(--blue-dark);
    text-decoration: none;
    font-size: 12px;
    transition: var(--ease);
}
.tag-list a:hover, .tag-item:hover {
    background: var(--blue);
    color: #fff;
    border-color: var(--blue);
    box-shadow: 0 2px 8px rgba(58,123,213,0.25);
}

/* ===== SECTION BLOCKS ===== */
.section-block {
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin-bottom: 12px;
    box-shadow: var(--shadow-sm);
}

.section-head {
    display: flex;
    align-items: center;
    padding: 0;
    border-bottom: 2px solid var(--border-light);
    background: var(--blue-lighter);
}

.section-title {
    font-size: 15px;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(90deg, var(--blue) 0%, var(--sky) 100%);
    padding: 10px 22px 10px 14px;
    clip-path: polygon(0 0, 100% 0, calc(100% - 12px) 100%, 0 100%);
    letter-spacing: 0.5px;
    white-space: nowrap;
    line-height: 1.2;
}
.section-title a { color: #fff; text-decoration: none; }
.section-title a:hover { color: #d8eeff; }
.section-title span {
    font-size: 12px; font-weight: 400;
    color: rgba(255,255,255,0.75);
    margin-left: 8px;
}

.section-body { padding: 16px; }

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

.film-grid li { animation: fadeUp 0.45s ease backwards; }
.film-grid li:nth-child(1) { animation-delay: 0.04s; }
.film-grid li:nth-child(2) { animation-delay: 0.08s; }
.film-grid li:nth-child(3) { animation-delay: 0.12s; }
.film-grid li:nth-child(4) { animation-delay: 0.16s; }
.film-grid li:nth-child(5) { animation-delay: 0.20s; }
.film-grid li:nth-child(6) { animation-delay: 0.24s; }
.film-grid li:nth-child(7) { animation-delay: 0.28s; }
.film-grid li:nth-child(8) { animation-delay: 0.32s; }

@keyframes fadeUp {
    from { opacity: 0; transform: translateY(12px); }
    to   { opacity: 1; transform: translateY(0); }
}

.film-thumb {
    display: block;
    position: relative;
    overflow: hidden;
    aspect-ratio: 600 / 350;
    background: var(--surface);
    border-radius: var(--radius);
    border: 1px solid var(--border);
}
.film-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.35s ease; display: block; }
.film-thumb:hover img { transform: scale(1.06); }
.film-thumb::after {
    content: '▶';
    position: absolute; inset: 0;
    display: flex; align-items: center; justify-content: center;
    font-size: 32px;
    color: rgba(255,255,255,0.92);
    background: rgba(26,79,143,0.28);
    opacity: 0;
    transition: opacity 0.22s ease;
}
.film-thumb:hover::after { opacity: 1; }

.film-info { padding: 7px 0 2px; }
.film-info h5 { margin: 0; font-size: 12px; font-weight: 400; line-height: 1.5; }
.film-info h5 a {
    color: var(--text);
    text-decoration: none;
    transition: var(--ease);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.film-info h5 a:hover { color: var(--blue); }

/* ===== VIDEO PLAYER ===== */
.video-container {
    width: 100%; height: 600px;
    background: #000;
    border-radius: var(--radius);
    overflow: hidden;
    margin-bottom: 14px;
    box-shadow: var(--shadow-lg);
}
.video-container iframe, .video-container video, .video-container #video-container { width: 100%; height: 100%; border: none; }
.MacPlayer { background: #000; border-radius: var(--radius); overflow: hidden; margin-bottom: 14px; }

/* ===== DETAIL TITLE ===== */
.detail-title-bar {
    line-height: 1.8;
    text-align: center;
    padding: 16px 20px;
    font-size: 16px;
    margin: 12px 0;
    word-break: break-all;
    background: var(--panel);
    border: 1px solid var(--border);
    border-top: 3px solid var(--blue);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}
.detail-title-bar a { color: var(--blue); text-decoration: none; font-weight: 700; margin-right: 8px; transition: var(--ease); }
.detail-title-bar a:hover { color: var(--blue-dark); text-decoration: underline; }

/* ===== META BOX ===== */
.meta-info-box {
    font-size: 14px; line-height: 2;
    padding: 18px 22px;
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    margin: 12px 0;
    box-shadow: var(--shadow-sm);
}

/* ===== TORRENT PREVIEW ===== */
.preview-image-wrap { width: 100%; margin: 10px 0; }
.preview-image-wrap picture,
.preview-image-wrap img { display: block; width: 100%; height: auto; border-radius: var(--radius); border: 1px solid var(--border); }

/* ===== DOWNLOAD BUTTONS ===== */
.btn-group-center {
    text-align: center;
    padding: 18px 16px;
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    margin: 12px 0;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    flex-wrap: nowrap;
    box-shadow: var(--shadow-sm);
}

.btn-action {
    display: inline-block;
    padding: 11px 26px;
    background: linear-gradient(135deg, var(--blue) 0%, var(--blue-dark) 100%);
    color: #fff;
    text-decoration: none;
    border-radius: var(--radius-lg);
    font-weight: 600;
    font-size: 14px;
    transition: var(--ease);
    border: none;
    white-space: nowrap;
    flex-shrink: 0;
    cursor: pointer;
    font-family: inherit;
    letter-spacing: 0.3px;
    box-shadow: 0 2px 8px rgba(58,123,213,0.28);
}
.btn-action:hover {
    background: linear-gradient(135deg, var(--blue-dark) 0%, var(--blue-deeper) 100%);
    box-shadow: 0 4px 16px rgba(58,123,213,0.42);
    transform: translateY(-1px);
}
.btn-action:active { transform: translateY(0); }

/* ===== SHARE ===== */
.share-section {
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 14px 16px;
    margin: 12px 0;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: var(--shadow-sm);
}

.share-url-display {
    background: var(--blue-lighter);
    border: 1px solid var(--border-mid);
    border-radius: var(--radius-lg);
    padding: 9px 14px;
    display: flex; align-items: center; gap: 8px;
    flex: 1; min-width: 0;
}

.share-label {
    font-weight: 700; font-size: 11px;
    background: var(--blue);
    color: #fff;
    padding: 2px 8px;
    border-radius: 10px;
    white-space: nowrap; flex-shrink: 0;
}

.share-url {
    font-size: 12px; color: var(--text-muted);
    font-family: 'Courier New', monospace;
    flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

.share-copy-btn {
    padding: 10px 18px;
    background: var(--blue);
    color: #fff; border: none;
    border-radius: var(--radius-lg);
    font-weight: 600; font-size: 13px;
    cursor: pointer; transition: var(--ease);
    display: flex; align-items: center; gap: 5px;
    white-space: nowrap; flex-shrink: 0;
    font-family: inherit;
    box-shadow: 0 2px 6px rgba(58,123,213,0.22);
}
.share-copy-btn:hover { background: var(--blue-dark); box-shadow: 0 3px 12px rgba(58,123,213,0.35); }
.share-icon { font-size: 15px; }

/* ===== PAGINATION ===== */
.page_info_div {
    display: flex; justify-content: center; align-items: center;
    gap: 5px; flex-wrap: wrap; padding: 20px 0;
}
.a_page_info, .page_info_focus {
    display: inline-block; padding: 7px 14px;
    text-decoration: none; font-weight: 400; font-size: 13px;
    transition: var(--ease); min-width: 36px; text-align: center;
    border: 1px solid var(--border-mid); border-radius: var(--radius);
}
.a_page_info { background: var(--panel); color: var(--text-mid); }
.a_page_info:hover { background: var(--blue); border-color: var(--blue); color: #fff; }
.page_info_focus { background: var(--blue); color: #fff; border: 1px solid var(--blue); cursor: default; font-weight: 700; }

/* ===== FRIEND LINKS ===== */
.link-panel {
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 14px 16px;
    margin-bottom: 8px;
    box-shadow: var(--shadow-sm);
}
.link-panel-head {
    font-size: 14px; font-weight: 700;
    color: #fff;
    background: linear-gradient(90deg, var(--blue) 0%, var(--sky) 100%);
    padding: 8px 16px 8px 14px;
    margin: -14px -16px 12px;
    display: flex; align-items: center; gap: 7px;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}
.link-grid dl { margin: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.link-grid dd { margin: 0; }
.link-grid a {
    display: inline-block; padding: 4px 12px;
    color: var(--blue-dark); text-decoration: none; font-size: 12px;
    border: 1px solid var(--border); border-radius: 14px;
    background: var(--blue-lighter); transition: var(--ease);
}
.link-grid a:hover { color: #fff; border-color: var(--blue); background: var(--blue); }

/* ===== FOOTER ===== */
.site-footer {
    background: var(--blue-deeper);
    padding: 22px 0;
    margin-top: 18px;
    text-align: center;
}
.site-footer p { color: rgba(255,255,255,0.55); font-size: 12px; margin: 5px 0; line-height: 1.8; }
.site-footer a { color: rgba(255,255,255,0.65); text-decoration: none; transition: var(--ease); }
.site-footer a:hover { color: #fff; }

/* ===== CLIENT DOWNLOAD ===== */
.client-dl-pc, .client-dl-mobile { text-align: center; padding: 12px 16px; }
.client-dl-pc a, .client-dl-mobile a { color: var(--blue); text-decoration: none; font-weight: 600; font-size: 14px; transition: var(--ease); }
.client-dl-pc a:hover, .client-dl-mobile a:hover { color: var(--blue-dark); text-decoration: underline; }

/* ===== HIDE UTILS ===== */
.hide_mobile { display: block; }
.hide_pc { display: block; }
@media (max-width: 768px) { .hide_mobile { display: none !important; } }
@media (min-width: 769px) { .hide_pc { display: none !important; } }

/* ===== CLEARFIX ===== */
.clearfix::after { content: ""; display: table; clear: both; }
img[data-original] { background: var(--surface); }

/* ===== RESPONSIVE 768px ===== */
@media (max-width: 768px) {
    .container { padding: 0 8px; }
    .content { padding: 6px 0; }

    .site-branding { gap: 10px; flex-wrap: nowrap; }
    .brand-name { font-size: 20px; letter-spacing: 0.5px; }
    .brand-icon { width: 34px; height: 34px; font-size: 18px; }
    .site-domain-wrap { padding: 4px 10px; flex-shrink: 0; }
    .domain-str { font-size: 12px; max-width: 130px; }
    .domain-tag { font-size: 10px; padding: 1px 5px; }

    .category-zone { width: 16%; min-width: 38px; font-size: 10px; padding: 6px 2px; letter-spacing: 0; }
    .category-links { width: 84%; flex-wrap: wrap; }
    .category-links a {
        font-size: 14px; padding: 8px 2px;
        width: 25%; flex: none;
        border-right: 1px solid rgba(255,255,255,0.10);
        border-bottom: 1px solid rgba(255,255,255,0.08);
    }
    .category-links a.active::after { display: none; }

    .film-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .film-info h5 { font-size: 12px; }
    .section-title { font-size: 14px; }
    .section-body { padding: 12px; }
    .video-container { height: 56.25vw; max-height: 360px; }

    .btn-group-center { padding: 14px 10px; gap: 8px; flex-wrap: nowrap; }
    .btn-action { padding: 10px 16px; font-size: 13px; }

    .share-section { padding: 12px; gap: 8px; flex-wrap: nowrap; }
    .share-url-display { padding: 8px 10px; }
    .share-url { font-size: 11px; }
    .share-copy-btn { padding: 9px 12px; font-size: 12px; }

    .search-wrap { padding: 10px 12px; }
    .search-wrap button { padding: 8px 10px; font-size: 12px; }
    .search-wrap input[type="text"] { min-width: 80px; padding: 8px 12px; font-size: 13px; }
    .hot-search-panel { padding: 10px 12px; }
    .tag-list a, .tag-item { font-size: 12px; padding: 3px 10px; }

    .page_info_div { padding: 14px 0; gap: 4px; }
    .a_page_info, .page_info_focus { padding: 5px 10px; font-size: 12px; min-width: 30px; }
    .detail-title-bar { padding: 12px 14px; font-size: 14px; }
    .meta-info-box { padding: 14px; font-size: 13px; }
}

/* ===== RESPONSIVE 480px ===== */
@media (max-width: 480px) {
    .brand-name { font-size: 18px; }
    .brand-icon { width: 28px; height: 28px; font-size: 16px; }
    .domain-tag { display: none; }
    .domain-str { font-size: 12px; max-width: 120px; }

    .category-zone { width: 15%; min-width: 34px; font-size: 9px; padding: 4px 1px; }
    .category-links { width: 85%; }
    .category-links a { font-size: 13px; padding: 7px 1px; width: 25%; }

    .film-grid { gap: 8px; }
    .film-info h5 { font-size: 11px; }
    .section-title { font-size: 13px; }
    .video-container { height: 56.25vw; max-height: 260px; }
    .btn-action { padding: 9px 12px; font-size: 12px; }
    .share-copy-btn { padding: 8px 10px; font-size: 11px; }
}
