/* F5 Dark Tech - Video Portal Template */

:root {
    --blue: #1a6ba0;
    --blue-mid: #155d8a;
    --blue-deep: #0f4a6f;
    --blue-bright: #2b8ec7;
    --red: #e8132a;
    --dark: #1e1e1e;
    --dark2: #2d2d2d;
    --dark3: #3a3a3a;
    --steel: #4a6b82;
    --white: #ffffff;
    --bg-root: #f4f5f7;
    --bg-panel: #ffffff;
    --bg-card: #f9fafc;
    --bg-dark-panel: #23303d;
    --text-main: #1a1a1a;
    --text-sub: #3a3a3a;
    --text-muted: #6b7280;
    --text-light: #9ca3af;
    --border: #dde2e8;
    --border-blue: #1a6ba0;
    --shadow: rgba(0,0,0,0.07);
    --shadow-md: rgba(0,0,0,0.13);
    --shadow-lg: rgba(0,0,0,0.22);
    --grad-blue: linear-gradient(135deg, #1a6ba0 0%, #0f4a6f 100%);
    --grad-dark: linear-gradient(180deg, #23303d 0%, #1a252f 100%);
    --rd: 4px;
    --rd-sm: 3px;
    --rd-lg: 6px;
    --ease: all 0.2s ease;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Arial, 'Noto Sans SC', sans-serif;
    background: var(--bg-root);
    color: var(--text-main);
    font-size: 14px;
    line-height: 1.6;
    overflow-x: hidden;
}

/* ===== HEADER - NOT sticky ===== */
.f5-header {
    background: var(--white);
    border-bottom: 1px solid var(--border);
    padding: 10px 0;
    box-shadow: 0 1px 4px var(--shadow);
}

.f5-header-inner { display: flex; align-items: center; justify-content: center; }

.f5-branding {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: nowrap;
    justify-content: center;
}

.f5-logo-link {
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    transition: var(--ease);
}

.f5-logo-link:hover { opacity: 0.82; }

.f5-logo-badge {
    width: 40px;
    height: 40px;
    background: var(--red);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #fff;
    font-size: 16px;
    font-weight: 900;
    font-style: italic;
    letter-spacing: -1px;
}

.f5-sitename {
    font-size: 22px;
    font-weight: 800;
    color: var(--dark);
    letter-spacing: -0.4px;
    font-style: normal;
    text-decoration: none;
    border-bottom: none;
}

.f5-domain-block {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #eef4f9;
    border: 1px solid var(--border-blue);
    border-radius: var(--rd);
    padding: 6px 14px;
    flex-shrink: 0;
}

.f5-domain-lbl {
    font-size: 11px;
    font-weight: 700;
    color: var(--blue);
    text-transform: uppercase;
    letter-spacing: 0.6px;
    white-space: nowrap;
}

.f5-domain-url {
    font-size: 17px;
    font-weight: 700;
    color: var(--dark);
    font-family: 'Courier New', monospace;
    white-space: nowrap;
    letter-spacing: 0.2px;
}

/* ===== WRAPPER ===== */
.f5-wrap { max-width: 1080px; margin: 0 auto; padding: 0 14px; }
.f5-row { padding: 7px 0; }

/* ===== BANNER ===== */
.f5-promo { width: 100%; margin: 4px 0; overflow: hidden; line-height: 0; }
.f5-promo img { width: 100%; display: block; }

/* ===== NAVIGATION ===== */
.f5-navboard {
    background: var(--bg-dark-panel);
    border-radius: var(--rd-lg);
    overflow: hidden;
    margin-bottom: 7px;
    border: 1px solid #2e4050;
}

.f5-navrow {
    display: flex;
    align-items: stretch;
    border-bottom: 1px solid #2e4050;
}

.f5-navrow:last-child { border-bottom: none; }

.f5-zone-lbl {
    font-size: 14px;
    font-weight: 700;
    color: #90b8d0;
    white-space: nowrap;
    width: 10%;
    text-align: center;
    border-right: 1px solid #2e4050;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 9px 5px;
    flex-shrink: 0;
    background: rgba(26,107,160,0.25);
}

.f5-navlinks {
    width: 90%;
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    padding: 9px 8px;
    align-items: center;
    background: transparent;
}

.f5-navlinks a {
    display: inline-block;
    color: #b0c8d8;
    text-decoration: none;
    padding: 5px 4px;
    border-radius: var(--rd-sm);
    transition: var(--ease);
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    white-space: nowrap;
    text-align: center;
    width: calc((100% - 35px) / 8);
    flex-shrink: 0;
    flex-grow: 0;
    font-size: 13px;
}

.f5-navlinks a:hover {
    background: var(--blue);
    color: #fff;
    border-color: var(--blue-bright);
}

.f5-navlinks a.active {
    background: var(--blue);
    color: #fff;
    border-color: var(--blue-bright);
    font-weight: 700;
}

/* ===== SEARCH ===== */
.f5-searchbar {
    background: var(--bg-dark-panel);
    border-radius: var(--rd-lg);
    padding: 10px 12px;
    margin-bottom: 7px;
    border: 1px solid #2e4050;
}

#f5sf { display: flex; gap: 6px; flex-wrap: nowrap; align-items: center; }

#f5sf input[type="text"] {
    flex: 1;
    min-width: 80px;
    padding: 9px 14px;
    border: 1px solid #3a5060;
    border-radius: var(--rd-sm);
    background: rgba(255,255,255,0.08);
    color: #d0dce6;
    font-size: 14px;
    transition: var(--ease);
    outline: none;
}

#f5sf input[type="text"]:focus {
    border-color: var(--blue-bright);
    background: rgba(255,255,255,0.12);
    box-shadow: 0 0 0 2px rgba(43,142,199,0.2);
}

#f5sf input[type="text"]::placeholder { color: #7a94a4; }

#f5sf button {
    padding: 9px 15px;
    border: none;
    border-radius: var(--rd-sm);
    background: var(--grad-blue);
    color: #fff;
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    transition: var(--ease);
    white-space: nowrap;
    flex-shrink: 0;
    letter-spacing: 0.2px;
}

#f5sf button:hover {
    background: linear-gradient(135deg, #2b8ec7 0%, #1a6ba0 100%);
    box-shadow: 0 3px 10px rgba(26,107,160,0.4);
}

/* ===== TAG CLOUD ===== */
.f5-tagpool {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    list-style: none;
    padding: 9px 12px;
    background: var(--bg-panel);
    border-radius: var(--rd-lg);
    margin-bottom: 7px;
    border: 1px solid var(--border);
    box-shadow: 0 1px 4px var(--shadow);
}

.f5-taglink {
    padding: 4px 11px;
    background: #eef4f9;
    border-radius: 3px;
    color: var(--blue);
    text-decoration: none;
    font-size: 12px;
    font-weight: 600;
    transition: var(--ease);
    border: 1px solid #c5d8e8;
}

.f5-taglink:hover {
    background: var(--blue);
    color: #fff;
    border-color: var(--blue);
}

/* ===== CONTENT BLOCKS ===== */
.f5-block { margin-bottom: 10px; }

.f5-block-inner {
    background: var(--bg-panel);
    border-radius: var(--rd-lg);
    border: 1px solid var(--border);
    padding: 14px;
    box-shadow: 0 1px 4px var(--shadow);
}

.f5-block-hd {
    margin-bottom: 12px;
    padding-bottom: 9px;
    border-bottom: 2px solid var(--border);
    position: relative;
}

.f5-block-hd::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 36px;
    height: 2px;
    background: var(--grad-blue);
    border-radius: 2px;
}

.f5-block-ttl { font-size: 18px; font-weight: 800; color: var(--dark); margin: 0; letter-spacing: -0.3px; }
.f5-block-ttl a { color: var(--dark); text-decoration: none; transition: var(--ease); }
.f5-block-ttl a:hover { color: var(--blue); }

/* ===== FILM GRID: 4 PC / 2 mobile ===== */
.f5-filmgrid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    list-style: none;
    padding: 0;
}

.f5-filmgrid li { position: relative; }

.f5-filmthumb {
    display: block;
    position: relative;
    overflow: hidden;
    border-radius: var(--rd);
    aspect-ratio: 600 / 350;
    background: var(--bg-card);
    border: 1px solid var(--border);
}

.f5-filmthumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; display: block; }

.f5-filmthumb::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(26,107,160,0.65) 0%, transparent 55%);
    opacity: 0;
    transition: opacity 0.25s ease;
}

.f5-filmthumb:hover::after { opacity: 1; }
.f5-filmthumb:hover img { transform: scale(1.06); }
.f5-filmthumb:hover { border-color: var(--blue); box-shadow: 0 4px 16px rgba(26,107,160,0.25); }

.f5-filmlabel { padding: 6px 0 3px; }
.f5-filmlabel h5 { margin: 0; font-size: 13px; font-weight: 500; line-height: 1.4; }

.f5-filmlabel h5 a {
    color: var(--text-sub);
    text-decoration: none;
    transition: var(--ease);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.f5-filmlabel h5 a:hover { color: var(--blue); }

/* ===== VIDEO PLAYER ===== */
.f5-player {
    width: 100%;
    height: 620px;
    max-height: 620px;
    background: #000;
    border-radius: var(--rd-lg);
    overflow: hidden;
    margin-bottom: 12px;
    box-shadow: 0 6px 24px var(--shadow-lg);
    position: relative;
}

.f5-player iframe, .f5-player video, .f5-player #video-container { width: 100%; height: 100%; border: none; }

.MacPlayer { background: #000; border-radius: var(--rd-lg); overflow: hidden; margin-bottom: 12px; box-shadow: 0 6px 20px var(--shadow-lg); }

/* ===== TORRENT PREVIEW ===== */
.f5-capture { width: 100%; margin-top: 10px; }
.f5-capture img, .f5-capture .img_item img { width: 100%; height: auto; border-radius: var(--rd-sm); border: 1px solid var(--border); display: block; }
.f5-capture .img_item { width: 100%; }

/* ===== DOWNLOAD BUTTONS ===== */
.f5-dlrow {
    text-align: center;
    padding: 14px;
    background: var(--bg-dark-panel);
    border-radius: var(--rd-lg);
    margin: 12px 0;
    border: 1px solid #2e4050;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: nowrap;
    gap: 10px;
}

.down_btn {
    display: inline-block;
    padding: 10px 22px;
    background: var(--grad-blue);
    color: #fff;
    text-decoration: none;
    border-radius: var(--rd-sm);
    font-weight: 700;
    font-size: 14px;
    transition: var(--ease);
    border: none;
    white-space: nowrap;
    flex-shrink: 0;
    cursor: pointer;
    letter-spacing: 0.2px;
}

.down_btn:hover {
    background: linear-gradient(135deg, #2b8ec7 0%, #1a6ba0 100%);
    box-shadow: 0 4px 14px rgba(26,107,160,0.4);
}

/* ===== SHARE SECTION ===== */
.share-section {
    background: var(--bg-dark-panel);
    border-radius: var(--rd-lg);
    padding: 14px;
    margin: 12px 0;
    border: 1px solid #2e4050;
    display: flex;
    align-items: center;
    gap: 10px;
}

.share-url-display {
    background: rgba(255,255,255,0.06);
    border: 1px solid #3a5060;
    border-radius: var(--rd-sm);
    padding: 9px 13px;
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    min-width: 0;
}

.share-label { font-weight: 700; font-size: 12px; color: #90b8d0; white-space: nowrap; flex-shrink: 0; }

.share-url {
    font-size: 12px;
    color: #8aabb8;
    font-family: 'Courier New', monospace;
    word-break: break-all;
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 1.5;
}

.share-copy-btn {
    padding: 9px 16px;
    background: var(--grad-blue);
    color: #fff;
    border: none;
    border-radius: var(--rd-sm);
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    transition: var(--ease);
    display: flex;
    align-items: center;
    gap: 5px;
    white-space: nowrap;
    flex-shrink: 0;
}

.share-copy-btn:hover {
    background: linear-gradient(135deg, #2b8ec7 0%, #1a6ba0 100%);
    box-shadow: 0 3px 10px rgba(26,107,160,0.4);
}

.share-icon { font-size: 15px; }

/* ===== PAGINATION ===== */
.page_info_div {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 5px;
    flex-wrap: wrap;
    padding: 16px 0;
}

.a_page_info, .page_info_focus {
    display: inline-block;
    padding: 7px 13px;
    border-radius: var(--rd-sm);
    text-decoration: none;
    font-weight: 600;
    font-size: 13px;
    transition: var(--ease);
    min-width: 36px;
    text-align: center;
}

.a_page_info { background: var(--bg-panel); color: var(--text-main); border: 1px solid var(--border); }
.a_page_info:hover { background: var(--blue); border-color: var(--blue); color: #fff; }
.page_info_focus { background: var(--grad-blue); color: #fff; border: 1px solid var(--blue-mid); cursor: default; }

/* ===== FOOTER ===== */
.f5-footer {
    padding: 20px 0;
    text-align: center;
    border-top: 3px solid var(--blue);
    margin-top: 16px;
    background: var(--bg-dark-panel);
}

.f5-footer p { margin: 6px 0; color: #7a9bac; font-size: 12px; }
.f5-footer a { color: #7a9bac; text-decoration: none; transition: var(--ease); }
.f5-footer a:hover { color: #90b8d0; }

/* ===== FRIEND LINKS ===== */
.f5-flinks { padding: 10px 12px; background: var(--bg-panel); border-radius: var(--rd-lg); border: 1px solid var(--border); }
.f5-flinks dl { margin: 0; }
.f5-flinks dd { display: inline-block; margin: 3px 4px; }
.f5-flinks a { color: var(--text-muted); text-decoration: none; transition: var(--ease); font-size: 13px; }
.f5-flinks a:hover { color: var(--blue); }

/* ===== UTILITIES ===== */
.clearfix::after { content: ""; display: table; clear: both; }
.xhide-mob { display: block; }
.xhide-pc { display: block; }

/* ===== TABLET / MOBILE ===== */
@media (max-width: 768px) {
    .f5-wrap { padding: 0 8px; }
    .f5-row { padding: 5px 0; }
    .f5-sitename { font-size: 19px; }
    .f5-branding { gap: 12px; }
    .f5-logo-badge { width: 34px; height: 34px; font-size: 14px; }
    .f5-domain-block { padding: 4px 10px; gap: 6px; }
    .f5-domain-lbl { font-size: 10px; }
    .f5-domain-url { font-size: 15px; }

    /* Mobile nav: 15% label, 85% links, 4 per row */
    .f5-navrow { display: flex; align-items: stretch; }
    .f5-zone-lbl { width: 15%; font-size: 10px; padding: 7px 2px; text-align: center; }
    .f5-navlinks { width: 85%; gap: 4px; padding: 7px 4px; }
    .f5-navlinks a {
        font-size: 13px;
        padding: 4px 2px;
        text-align: center;
        width: calc((100% - 12px) / 4);
        flex-shrink: 0;
        flex-grow: 0;
    }

    /* Search all on one line */
    #f5sf { flex-wrap: nowrap; gap: 5px; }
    #f5sf input[type="text"] { min-width: 80px; padding: 8px 9px; font-size: 13px; }
    #f5sf button { padding: 8px 9px; font-size: 12px; }

    /* Film: 2 cols */
    .f5-filmgrid { grid-template-columns: repeat(2, 1fr); gap: 9px; }

    .f5-player { height: 56.25vw; max-height: 380px; margin-bottom: 10px; }
    .f5-block-ttl { font-size: 15px; }
    .f5-taglink { font-size: 11px; padding: 3px 9px; }
    .down_btn { padding: 9px 13px; font-size: 13px; }
    .f5-dlrow { padding: 10px 8px; gap: 7px; flex-wrap: nowrap; }
    .share-section { padding: 9px; gap: 7px; flex-wrap: nowrap; }
    .share-url-display { padding: 7px 9px; flex: 1; min-width: 0; }
    .share-label { font-size: 11px; }
    .share-url { font-size: 10px; }
    .share-copy-btn { padding: 8px 10px; font-size: 12px; flex-shrink: 0; }
    .page_info_div { gap: 4px; padding: 12px 0; }
    .a_page_info, .page_info_focus { padding: 6px 10px; font-size: 12px; min-width: 30px; }
    .xhide-mob { display: none !important; }
}

/* ===== SMALL MOBILE ===== */
@media (max-width: 480px) {
    .f5-branding { gap: 8px; }
    .f5-sitename { font-size: 17px; }
    .f5-logo-badge { width: 30px; height: 30px; font-size: 13px; }
    .f5-domain-url { font-size: 13px; }
    .f5-domain-lbl { font-size: 9px; }

    .f5-zone-lbl { width: 15%; font-size: 10px; padding: 5px 2px; }
    .f5-navlinks { width: 85%; gap: 3px; padding: 5px 3px; }
    .f5-navlinks a { font-size: 12px; padding: 3px 1px; width: calc((100% - 9px) / 4); }

    #f5sf input[type="text"] { min-width: 60px; padding: 7px 7px; font-size: 12px; }
    #f5sf button { padding: 7px 7px; font-size: 11px; }

    .f5-filmgrid { grid-template-columns: repeat(2, 1fr); gap: 7px; }
    .f5-filmlabel h5 { font-size: 12px; }
    .f5-block-ttl { font-size: 14px; }
    .down_btn { padding: 8px 9px; font-size: 12px; }
    .f5-dlrow { padding: 8px 4px; gap: 5px; }
    .share-section { padding: 7px; gap: 5px; flex-wrap: nowrap; }
    .share-url-display { padding: 6px 7px; }
    .share-label { font-size: 10px; }
    .share-url { font-size: 10px; }
    .share-copy-btn { padding: 7px 8px; font-size: 11px; }
}

@media (min-width: 769px) { .xhide-pc { display: none !important; } }

img[data-original] { background: var(--bg-card); }
