/* Video Site Template - AWS / Amazon Cloud Edition */

:root {
    --clr-orange:    #ff9900;
    --clr-orange2:   #e68a00;
    --clr-navy:      #232f3e;
    --clr-navy2:     #1a232f;
    --clr-navy3:     #131a22;
    --clr-teal:      #007dbc;
    --clr-teal2:     #006097;
    --clr-bg:        #f8f8f8;
    --clr-bg2:       #f2f3f3;
    --clr-bg3:       #eaecec;
    --clr-white:     #ffffff;
    --clr-text:      #16191f;
    --clr-text2:     #545b64;
    --clr-text3:     #879596;
    --clr-border:    #d5dbdb;
    --clr-border2:   #aab7b8;
    --clr-shadow:    rgba(0, 0, 0, 0.09);
    --clr-shadow2:   rgba(0, 0, 0, 0.16);
    --grad-orange:   linear-gradient(135deg, #ff9900 0%, #ffb84d 100%);
    --grad-navy:     linear-gradient(180deg, #232f3e 0%, #131a22 100%);
    --grad-teal:     linear-gradient(135deg, #007dbc 0%, #0090d6 100%);
    --rd:            8px;
    --rd-sm:         6px;
    --rd-xs:         4px;
    --ease:          all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Amazon Ember', 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', Arial, sans-serif;
    background: var(--clr-bg);
    color: var(--clr-text);
    line-height: 1.6;
    font-size: 14px;
    overflow-x: hidden;
}

/* ── SITE HEADER ─────────────────────────────── */
.site-header {
    background: var(--grad-navy);
    padding: 0.55rem 0;
    box-shadow: 0 1px 0 rgba(255,255,255,0.08), 0 2px 12px rgba(0,0,0,0.35);
}

.brand-wrap {
    display: flex;
    justify-content: center;
    align-items: center;
}

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

.site-logo {
    text-decoration: none;
    display: inline-block;
    transition: var(--ease);
}
.site-logo:hover { opacity: 0.88; }

.site-ttl {
    font-size: 26px;
    font-weight: 700;
    color: var(--clr-white);
    letter-spacing: 0.3px;
    font-style: normal;
    text-decoration: none;
}
.site-ttl:hover { color: var(--clr-orange); }

.domain-badge {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 5px 15px;
    border-radius: var(--rd-xs);
    border: 1px solid rgba(255,255,255,0.22);
    background: rgba(255,255,255,0.07);
}

.domain-tag {
    font-size: 11px;
    font-weight: 500;
    color: rgba(255,255,255,0.6);
    white-space: nowrap;
}

.domain-val {
    font-size: 18px;
    font-weight: 700;
    color: var(--clr-orange);
    font-family: 'Courier New', Courier, monospace;
    letter-spacing: 0.4px;
    white-space: nowrap;
}

/* ── LAYOUT ──────────────────────────────────── */
.pg-wrap {
    max-width: 1060px;
    margin: 0 auto;
    padding: 0 13px;
}

.pg-body { padding: 7px 0; }

/* ── CATEGORY NAVIGATION ─────────────────────── */
.cate-nav {
    background: var(--clr-white);
    border-radius: var(--rd);
    overflow: hidden;
    margin-bottom: 7px;
    border: 1px solid var(--clr-border);
    box-shadow: 0 1px 4px var(--clr-shadow);
}

.cate-row {
    display: flex;
    align-items: stretch;
    border-bottom: 1px solid var(--clr-border);
}
.cate-row:last-child { border-bottom: none; }

.cate-zone {
    font-weight: 600;
    font-size: 12px;
    color: var(--clr-white);
    white-space: nowrap;
    width: 10%;
    text-align: center;
    border-right: 1px solid rgba(255,255,255,0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px 4px;
    flex-shrink: 0;
    background: var(--clr-navy);
    letter-spacing: 0.2px;
}

.cate-links {
    width: 90%;
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    padding: 7px 8px;
    align-items: center;
}

.cate-links a {
    display: inline-block;
    color: var(--clr-text2);
    text-decoration: none;
    padding: 4px 3px;
    border-radius: var(--rd-xs);
    transition: var(--ease);
    background: var(--clr-bg2);
    border: 1px solid var(--clr-border);
    white-space: nowrap;
    text-align: center;
    width: calc((100% - 35px) / 8);
    flex-shrink: 0;
    flex-grow: 0;
    font-size: 13px;
}

.cate-links a:hover {
    background: #fef6e8;
    color: var(--clr-orange2);
    border-color: #ffc04d;
    font-weight: 600;
}

.cate-links a.active {
    background: var(--clr-orange);
    color: var(--clr-navy);
    border-color: var(--clr-orange2);
    font-weight: 700;
    box-shadow: 0 2px 6px rgba(255,153,0,0.3);
}

/* ── SEARCH BOX ──────────────────────────────── */
.srch-box {
    background: var(--clr-white);
    border-radius: var(--rd);
    padding: 10px 13px;
    margin-bottom: 7px;
    border: 1px solid var(--clr-border);
    box-shadow: 0 1px 4px var(--clr-shadow);
}

.srch-box form {
    display: flex;
    gap: 6px;
    flex-wrap: nowrap;
    align-items: center;
}

.srch-box input[type="text"] {
    flex: 1;
    min-width: 180px;
    padding: 9px 13px;
    border: 1px solid var(--clr-border2);
    border-radius: var(--rd-xs);
    background: var(--clr-white);
    color: var(--clr-text);
    font-size: 14px;
    transition: var(--ease);
    outline: none;
}

.srch-box input[type="text"]:focus {
    border-color: var(--clr-teal);
    box-shadow: 0 0 0 2px rgba(0,125,188,0.18);
}

.srch-box input[type="text"]::placeholder { color: var(--clr-text3); }

.srch-box button {
    padding: 9px 16px;
    border: none;
    border-radius: var(--rd-xs);
    background: var(--clr-navy);
    color: var(--clr-white);
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    transition: var(--ease);
    white-space: nowrap;
    flex-shrink: 0;
}

.srch-box button:hover {
    background: var(--clr-navy2);
    box-shadow: 0 2px 8px rgba(0,0,0,0.25);
}

/* ── HOT TAGS ────────────────────────────────── */
.tag-wrap {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    list-style: none;
    padding: 8px 12px;
    background: var(--clr-white);
    border-radius: var(--rd);
    margin-bottom: 7px;
    border: 1px solid var(--clr-border);
    box-shadow: 0 1px 4px var(--clr-shadow);
}

.tag-link {
    padding: 4px 12px;
    background: var(--clr-bg2);
    border-radius: var(--rd-xs);
    color: var(--clr-teal);
    text-decoration: none;
    font-size: 12px;
    transition: var(--ease);
    border: 1px solid var(--clr-border);
}

.tag-link:hover {
    background: #e8f4fc;
    color: var(--clr-teal2);
    border-color: #9fd0ec;
    font-weight: 600;
}

/* ── SECTION BLOCKS ──────────────────────────── */
.sec-block { margin-bottom: 12px; }

.sec-inner {
    background: var(--clr-white);
    border-radius: var(--rd);
    border: 1px solid var(--clr-border);
    padding: 13px 14px 10px;
    box-shadow: 0 1px 4px var(--clr-shadow);
}

.sec-head {
    margin-bottom: 11px;
    padding-bottom: 9px;
    border-bottom: 1px solid var(--clr-border);
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
}

.sec-head::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 44px;
    height: 2px;
    background: var(--clr-orange);
    border-radius: 2px;
}

.sec-ttl {
    font-size: 17px;
    font-weight: 700;
    margin: 0;
    color: var(--clr-text);
    letter-spacing: -0.1px;
}

.sec-ttl a {
    color: var(--clr-text);
    text-decoration: none;
    transition: var(--ease);
}
.sec-ttl a:hover { color: var(--clr-teal); }

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

.film-grid li {
    position: relative;
    animation: fadeUp 0.38s ease backwards;
}

.film-grid li:nth-child(1) { animation-delay: 0.03s; }
.film-grid li:nth-child(2) { animation-delay: 0.06s; }
.film-grid li:nth-child(3) { animation-delay: 0.09s; }
.film-grid li:nth-child(4) { animation-delay: 0.12s; }
.film-grid li:nth-child(5) { animation-delay: 0.15s; }
.film-grid li:nth-child(6) { animation-delay: 0.18s; }
.film-grid li:nth-child(7) { animation-delay: 0.21s; }
.film-grid li:nth-child(8) { animation-delay: 0.24s; }

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

/* AWS card style: white card with rounded top image */
.film-grid li > .card-wrap {
    background: var(--clr-white);
    border: 1px solid var(--clr-border);
    border-radius: var(--rd);
    overflow: hidden;
    box-shadow: 0 1px 4px var(--clr-shadow);
    transition: var(--ease);
}

.film-grid li > .card-wrap:hover {
    box-shadow: 0 4px 14px var(--clr-shadow2);
    transform: translateY(-2px);
    border-color: var(--clr-border2);
}

.film-thumb {
    display: block;
    position: relative;
    overflow: hidden;
    /* 封面比例 600:350 */
    aspect-ratio: 600 / 350;
    background: var(--clr-bg3);
    border-radius: 0;
}

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

.film-thumb:hover img { transform: scale(1.05); }

.film-meta {
    padding: 8px 10px 7px;
    background: var(--clr-white);
}

.film-meta h5 {
    margin: 0;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.45;
}

.film-meta h5 a {
    color: var(--clr-text2);
    text-decoration: none;
    transition: var(--ease);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.film-meta h5 a:hover { color: var(--clr-teal); }

/* Wrap li content as AWS card */
.film-grid li {
    display: flex;
    flex-direction: column;
}

.film-grid li > a.film-thumb {
    border-radius: var(--rd) var(--rd) 0 0;
    border: 1px solid var(--clr-border);
    border-bottom: none;
}

.film-grid li > .film-meta {
    border: 1px solid var(--clr-border);
    border-top: none;
    border-radius: 0 0 var(--rd) var(--rd);
    background: var(--clr-white);
    box-shadow: 0 2px 6px var(--clr-shadow);
    transition: var(--ease);
}

.film-grid li:hover > .film-meta {
    box-shadow: 0 4px 14px var(--clr-shadow2);
}

.film-grid li:hover > a.film-thumb {
    border-color: var(--clr-border2);
}

/* ── VIDEO PLAYER ────────────────────────────── */
.video-container {
    width: 100%;
    height: 620px;
    max-height: 620px;
    margin-bottom: 12px;
    background: #000;
    border-radius: var(--rd);
    overflow: hidden;
    box-shadow: 0 4px 16px var(--clr-shadow2);
    position: relative;
    border: 1px solid var(--clr-border);
}

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

.MacPlayer {
    background: #000;
    border-radius: var(--rd);
    overflow: hidden;
    margin-bottom: 10px;
    box-shadow: 0 4px 14px var(--clr-shadow2);
    border: 1px solid var(--clr-border);
}

/* ── TORRENT CAPTURE ─────────────────────────── */
.snap-grid { width: 100%; }

.snap-grid picture { display: block; width: 100%; }

.snap-grid img,
.snap-grid .img_item img {
    width: 100%;
    height: auto;
    border-radius: var(--rd-sm);
    border: 1px solid var(--clr-border);
    display: block;
}

.snap-grid .img_item { width: 100%; }

/* ── DOWNLOAD BUTTONS ────────────────────────── */
.dl-wrap {
    text-align: center;
    padding: 12px;
    background: var(--clr-white);
    border-radius: var(--rd);
    margin: 9px 0;
    border: 1px solid var(--clr-border);
    box-shadow: 0 1px 4px var(--clr-shadow);
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: nowrap;
    gap: 10px;
}

.dl-btn {
    display: inline-block;
    padding: 9px 22px;
    background: var(--clr-orange);
    color: var(--clr-navy);
    text-decoration: none;
    border-radius: var(--rd-xs);
    font-weight: 700;
    font-size: 14px;
    transition: var(--ease);
    border: 1px solid var(--clr-orange2);
    white-space: nowrap;
    flex-shrink: 0;
    cursor: pointer;
    letter-spacing: 0.1px;
}

.dl-btn:hover {
    background: var(--clr-orange2);
    box-shadow: 0 3px 10px rgba(255,153,0,0.35);
}

/* ── LINK / SHARE SECTION ────────────────────── */
.lnk-section {
    background: var(--clr-white);
    border-radius: var(--rd);
    padding: 12px;
    margin: 9px 0;
    border: 1px solid var(--clr-border);
    box-shadow: 0 1px 4px var(--clr-shadow);
    display: flex;
    align-items: center;
    gap: 10px;
}

.lnk-display {
    background: var(--clr-bg2);
    border: 1px solid var(--clr-border);
    border-radius: var(--rd-xs);
    padding: 9px 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    min-width: 0;
}

.lnk-label {
    font-weight: 700;
    font-size: 12px;
    color: var(--clr-teal);
    white-space: nowrap;
    flex-shrink: 0;
}

.lnk-url {
    font-size: 12px;
    color: var(--clr-text3);
    font-family: 'Courier New', Courier, monospace;
    word-break: break-all;
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.lnk-copy {
    padding: 9px 18px;
    background: var(--clr-navy);
    color: var(--clr-white);
    border: 1px solid var(--clr-navy2);
    border-radius: var(--rd-xs);
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    transition: var(--ease);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    white-space: nowrap;
    flex-shrink: 0;
}

.lnk-copy:hover {
    background: var(--clr-navy2);
    box-shadow: 0 2px 8px rgba(0,0,0,0.25);
}
.lnk-copy:active { transform: scale(0.97); }
.lnk-icon { font-size: 15px; }

/* ── PAGINATION ──────────────────────────────── */
.pager-wrap {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 4px;
    flex-wrap: wrap;
    padding: 14px 0;
}

.pg-link, .pg-cur {
    display: inline-block;
    padding: 6px 12px;
    border-radius: var(--rd-xs);
    text-decoration: none;
    font-weight: 500;
    font-size: 13px;
    transition: var(--ease);
    min-width: 32px;
    text-align: center;
}

.pg-link {
    background: var(--clr-white);
    color: var(--clr-text2);
    border: 1px solid var(--clr-border2);
}

.pg-link:hover {
    background: var(--clr-navy);
    border-color: var(--clr-navy);
    color: var(--clr-white);
    font-weight: 600;
}

.pg-cur {
    background: var(--clr-navy);
    color: var(--clr-white);
    border: 1px solid var(--clr-navy2);
    cursor: default;
    font-weight: 700;
}

/* ── FOOTER ──────────────────────────────────── */
.site-footer {
    padding: 18px 0;
    text-align: center;
    border-top: 1px solid var(--clr-border);
    margin-top: 14px;
    background: var(--clr-navy3);
}

.site-footer p {
    margin: 5px 0;
    color: rgba(255,255,255,0.45);
    font-size: 12px;
}

.site-footer a {
    color: rgba(255,255,255,0.45);
    text-decoration: none;
    transition: var(--ease);
}

.site-footer a:hover { color: var(--clr-orange); text-decoration: underline; }

/* ── FRIENDLY LINKS ──────────────────────────── */
.flink-box {
    padding: 10px 12px;
    background: var(--clr-white);
    border-radius: var(--rd);
    border: 1px solid var(--clr-border);
}

.flink-box dl { margin: 0; }
.flink-box dd { display: inline-block; margin: 3px; }

.flink-box a {
    color: var(--clr-teal);
    text-decoration: none;
    transition: var(--ease);
    font-size: 13px;
    padding: 2px 4px;
}

.flink-box a:hover { color: var(--clr-teal2); text-decoration: underline; }

.pd5 { padding: 2px 4px; }

/* ── UTILITY ─────────────────────────────────── */
.clearfix::after { content: ""; display: table; clear: both; }

.hide-mob { display: block; }
.hide-pc  { display: block; }

@media (max-width: 768px) { .hide-mob { display: none !important; } }
@media (min-width: 769px) { .hide-pc  { display: none !important; } }

img[data-original] { background: var(--clr-bg3); }

/* ── RESPONSIVE ≤ 768px ──────────────────────── */
@media (max-width: 768px) {
    .pg-wrap { padding: 0 8px; }
    .pg-body  { padding: 6px 0; }

    .site-ttl  { font-size: 20px; }
    .domain-val { font-size: 16px; }
    .domain-tag { font-size: 10px; }

    .cate-zone  { width: 15%; font-size: 10px; padding: 7px 2px; }
    .cate-links { width: 85%; gap: 4px; padding: 7px 4px; }
    .cate-links a {
        font-size: 14px;
        padding: 4px 2px;
        width: calc((100% - 12px) / 4);
        flex-shrink: 0;
        flex-grow: 0;
    }

    .film-grid  { grid-template-columns: repeat(2, 1fr); gap: 9px; }
    .film-meta h5 { font-size: 11px; }
    .sec-ttl   { font-size: 16px; }
    .sec-block { margin-bottom: 9px; }
    .sec-inner { padding: 10px 10px 8px; }

    .srch-box  { padding: 8px 10px; }
    .srch-box input[type="text"] { min-width: 90px; font-size: 12px; padding: 8px 9px; }
    .srch-box button { padding: 8px 10px; font-size: 12px; }

    .tag-wrap  { padding: 7px 9px; gap: 5px; }
    .tag-link  { padding: 3px 9px; font-size: 11px; }

    .dl-wrap   { padding: 9px 6px; margin: 7px 0; gap: 6px; }
    .dl-btn    { padding: 8px 14px; font-size: 13px; }

    .lnk-section { padding: 9px; margin: 8px 0; gap: 6px; }
    .lnk-display  { padding: 7px 9px; }
    .lnk-copy     { padding: 8px 10px; font-size: 12px; }

    .pager-wrap { padding: 11px 0; gap: 4px; }
    .pg-link, .pg-cur { padding: 5px 9px; font-size: 12px; min-width: 28px; }

    .video-container { height: 56.25vw; max-height: 360px; margin-bottom: 10px; }
    .site-footer { padding: 13px 0; margin-top: 10px; }

    .film-meta { padding: 6px 8px 5px; }
}

/* ── RESPONSIVE ≤ 480px ──────────────────────── */
@media (max-width: 480px) {
    .site-ttl  { font-size: 18px; }
    .domain-val { font-size: 15px; }
    .brand-inner { gap: 12px; }

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

    .film-grid  { grid-template-columns: repeat(2, 1fr); gap: 7px; }
    .film-meta h5 { font-size: 10px; }
    .sec-ttl   { font-size: 14px; }

    .srch-box input[type="text"] { min-width: 65px; padding: 7px 8px; }
    .srch-box button { padding: 7px 8px; font-size: 11px; }

    .dl-btn { padding: 7px 12px; font-size: 12px; }
    .lnk-url   { font-size: 10px; }
    .lnk-label { font-size: 10px; }

    .video-container { height: 56.25vw; max-height: 260px; margin-bottom: 8px; }
}
