/* Media Portal — Light Lavender Minimal Theme (Avo-inspired) */

:root {
    --bg-base:     #eeeef5;
    --bg-card:     #ffffff;
    --bg-alt:      #f5f5fb;
    --bg-muted:    #f0f0f8;

    --ink-dark:    #1a1a2d;
    --ink-mid:     #4a4a6a;
    --ink-soft:    #8888aa;
    --ink-faint:   #b0b0cc;

    --sky:         #3d5af1;
    --sky-light:   #e8ecff;
    --sky-hover:   #2d47d4;

    --sage:        #5a9e6f;
    --sage-light:  #e6f4eb;
    --sage-dark:   #3d7a52;

    --sand:        #c9a84c;
    --sand-light:  #fdf6e3;

    --line:        #e2e2ee;
    --line-strong: #d0d0e2;

    --radius-xs:   4px;
    --radius-sm:   8px;
    --radius-md:   12px;
    --radius-lg:   16px;
    --radius-xl:   22px;

    --shadow-xs:   0 1px 3px rgba(60,60,120,0.07);
    --shadow-sm:   0 2px 8px rgba(60,60,120,0.09);
    --shadow-md:   0 4px 16px rgba(60,60,120,0.12);
    --shadow-lg:   0 8px 28px rgba(60,60,120,0.15);

    --ease:        all 0.22s cubic-bezier(0.4,0,0.2,1);
}

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

html { scroll-behavior: smooth; }

body {
    font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Microsoft YaHei', 'Hiragino Sans GB', 'Helvetica Neue', Arial, sans-serif;
    background: var(--bg-base);
    color: var(--ink-dark);
    line-height: 1.55;
    font-size: 15px;
    overflow-x: hidden;
}

/* ===================== HEADER ===================== */
.site-nav {
    background: var(--bg-card);
    border-bottom: 1px solid var(--line);
    padding: 0.6rem 0;
    box-shadow: var(--shadow-xs);
}

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

.hd-brand {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    justify-content: center;
}

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

.hd-logo-link:hover { opacity: 0.8; }

.hd-site-name {
    font-size: 24px;
    font-weight: 900;
    letter-spacing: -0.3px;
    font-style: normal;
    text-decoration: none;
    border-bottom: none;
    background: linear-gradient(135deg, var(--sky) 0%, #7b5ea7 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hd-domain-pill {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 5px 14px;
    background: var(--sky-light);
    border: 1.5px solid rgba(61,90,241,0.2);
    border-radius: var(--radius-xl);
    transition: var(--ease);
}

.hd-domain-pill:hover {
    border-color: var(--sky);
    box-shadow: 0 2px 10px rgba(61,90,241,0.15);
}

.hd-domain-tag {
    font-size: 11px;
    font-weight: 700;
    color: var(--sky);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.hd-domain-url {
    font-size: 18px;
    font-weight: 800;
    color: var(--sky);
    white-space: nowrap;
    letter-spacing: -0.2px;
}

/* ===================== LAYOUT ===================== */
.lyt-wrap {
    max-width: 1060px;
    margin: 0 auto;
    padding: 0 14px;
}

.lyt-block {
    padding: 8px 0;
}

/* ===================== PROMO BANNER ===================== */
.banner-zone {
    width: 100%;
    overflow: hidden;
    border-radius: var(--radius-md);
    margin: 2px 0;
}

.banner-zone a { display: block; line-height: 0; }
.banner-zone img { width: 100%; display: block; border-radius: var(--radius-md); }

/* ===================== CATEGORY NAV ===================== */
.vod-nav {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    overflow: hidden;
    margin-bottom: 8px;
    border: 1px solid var(--line);
    box-shadow: var(--shadow-xs);
}

.vod-nav-row {
    display: flex;
    align-items: stretch;
    border-bottom: 1px solid var(--line);
}

.vod-nav-row:last-child { border-bottom: none; }

.vod-zone-label {
    font-size: 14px;
    font-weight: 700;
    color: var(--ink-mid);
    background: var(--bg-alt);
    width: 10%;
    min-width: 50px;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px 4px;
    flex-shrink: 0;
    border-right: 1px solid var(--line);
    white-space: nowrap;
    overflow: hidden;
}

.vod-zone-links {
    width: 90%;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 9px 10px;
    align-items: center;
}

.vod-zone-links a {
    display: inline-block;
    color: var(--ink-mid);
    text-decoration: none;
    padding: 5px 4px;
    border-radius: var(--radius-sm);
    transition: var(--ease);
    background: var(--bg-muted);
    border: 1px solid var(--line);
    white-space: nowrap;
    text-align: center;
    width: calc((100% - 42px) / 8);
    flex-shrink: 0;
    flex-grow: 0;
    font-size: 13px;
}

.vod-zone-links a:hover {
    background: var(--sky);
    color: #fff;
    border-color: var(--sky);
    box-shadow: 0 3px 10px rgba(61,90,241,0.2);
    transform: translateY(-1px);
}

.vod-zone-links a.active {
    background: var(--sky);
    color: #fff;
    border-color: var(--sky);
    box-shadow: 0 3px 10px rgba(61,90,241,0.2);
    font-weight: 700;
}

/* ===================== SEARCH ===================== */
.qr-box {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    padding: 12px;
    margin-bottom: 8px;
    border: 1px solid var(--line);
    box-shadow: var(--shadow-xs);
}

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

.qr-box input[type="text"] {
    flex: 1;
    min-width: 180px;
    padding: 10px 14px;
    border: 1.5px solid var(--line-strong);
    border-radius: var(--radius-sm);
    background: var(--bg-alt);
    color: var(--ink-dark);
    font-size: 14px;
    transition: var(--ease);
    outline: none;
    font-family: inherit;
}

.qr-box input[type="text"]:focus {
    border-color: var(--sky);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(61,90,241,0.1);
}

.qr-box input[type="text"]::placeholder { color: var(--ink-faint); }

.qr-box button {
    padding: 10px 15px;
    border: none;
    border-radius: var(--radius-sm);
    background: var(--sky);
    color: #fff;
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    transition: var(--ease);
    white-space: nowrap;
    flex-shrink: 0;
    font-family: inherit;
    letter-spacing: 0.2px;
}

.qr-box button:hover {
    background: var(--sky-hover);
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
}

/* ===================== TAG CLOUDS ===================== */
.kw-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    list-style: none;
    padding: 11px 12px;
    background: var(--bg-card);
    border-radius: var(--radius-md);
    margin-bottom: 8px;
    border: 1px solid var(--line);
    box-shadow: var(--shadow-xs);
}

.kw-pill {
    padding: 4px 13px;
    background: var(--bg-muted);
    border-radius: 14px;
    color: var(--ink-mid);
    text-decoration: none;
    font-size: 13px;
    transition: var(--ease);
    border: 1px solid var(--line);
}

.kw-pill:hover {
    background: var(--sage);
    color: #fff;
    border-color: var(--sage);
    box-shadow: 0 3px 10px rgba(90,158,111,0.2);
    transform: translateY(-1px);
}

/* ===================== CONTENT SECTIONS ===================== */
.media-block {
    margin-bottom: 14px;
}

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

.media-block-hd::after {
    content: '';
    position: absolute;
    bottom: -1.5px;
    left: 0;
    width: 44px;
    height: 2px;
    background: var(--sky);
    border-radius: 2px;
}

.media-block-title {
    font-size: 18px;
    font-weight: 800;
    margin: 0;
    color: var(--ink-dark);
    letter-spacing: -0.2px;
}

.media-block-title a {
    color: inherit;
    text-decoration: none;
    transition: var(--ease);
}

.media-block-title a:hover { color: var(--sky); }

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

.vod-grid li {
    animation: pop-up 0.45s ease backwards;
}

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

@keyframes pop-up {
    from { opacity: 0; transform: translateY(14px); }
    to   { opacity: 1; transform: translateY(0); }
}

.vod-thumb {
    display: block;
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-md);
    aspect-ratio: 600 / 350;
    background: var(--bg-muted);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-xs);
    transition: var(--ease);
}

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

.vod-thumb:hover {
    box-shadow: var(--shadow-lg);
    border-color: var(--line-strong);
    transform: translateY(-2px);
}

.vod-thumb:hover img { transform: scale(1.06); }

.vod-thumb::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(26,26,45,0.5) 0%, transparent 55%);
    opacity: 0;
    transition: opacity 0.3s ease;
    border-radius: var(--radius-md);
}

.vod-thumb:hover::after { opacity: 1; }

.vod-caption {
    padding: 7px 0 0;
}

.vod-caption h5 {
    margin: 0;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.45;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    color: var(--ink-mid);
}

.vod-caption h5 a {
    color: inherit;
    text-decoration: none;
    transition: var(--ease);
}

.vod-caption h5 a:hover { color: var(--sky); }

/* ===================== DETAIL INFO PANEL ===================== */
.item-title-bar {
    line-height: 1.8;
    text-align: center;
    padding: 16px 18px;
    font-size: 16px;
    margin: 12px 0;
    word-break: break-all;
    background: var(--bg-card);
    border-radius: var(--radius-md);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-xs);
}

.item-title-bar a {
    color: var(--sky);
    text-decoration: none;
    font-weight: 700;
    margin-right: 8px;
}

.item-detail-card {
    font-size: 15px;
    line-height: 1.9;
    padding: 20px 22px;
    background: var(--bg-card);
    border-radius: var(--radius-md);
    margin: 10px 0;
    border: 1px solid var(--line);
    box-shadow: var(--shadow-xs);
}

.img-preview-wrap {
    margin-top: 12px;
}

.img-preview-wrap picture {
    display: block;
    width: 100%;
}

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

/* ===================== DOWNLOAD BUTTONS ===================== */
.action-btns {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    padding: 16px 12px;
    margin: 10px 0;
    background: var(--bg-card);
    border-radius: var(--radius-md);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-xs);
}

.action-btn {
    display: inline-block;
    padding: 10px 22px;
    background: var(--sky);
    color: #fff !important;
    text-decoration: none;
    border-radius: var(--radius-xl);
    font-weight: 700;
    font-size: 14px;
    border: none;
    cursor: pointer;
    transition: var(--ease);
    box-shadow: 0 3px 12px rgba(61,90,241,0.2);
    letter-spacing: 0.2px;
    font-family: inherit;
}

.action-btn:hover {
    background: var(--sky-hover);
    transform: translateY(-2px);
    box-shadow: 0 5px 18px rgba(61,90,241,0.28);
}

/* ===================== SHARE ===================== */
.share-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    margin: 10px 0;
    background: var(--bg-card);
    border-radius: var(--radius-md);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-xs);
    flex-wrap: nowrap;
}

.share-url-display {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 12px;
    background: var(--bg-alt);
    border-radius: var(--radius-sm);
    border: 1px solid var(--line);
    flex: 1;
    min-width: 0;
    overflow: hidden;
}

.share-label {
    font-size: 11px;
    font-weight: 700;
    color: var(--sky);
    white-space: nowrap;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

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

.share-copy-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 9px 15px;
    background: var(--sage);
    color: #fff;
    border: none;
    border-radius: var(--radius-xl);
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    transition: var(--ease);
    white-space: nowrap;
    flex-shrink: 0;
    font-family: inherit;
}

.share-copy-btn:hover {
    background: var(--sage-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

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

/* ===================== CLIENT LINKS ===================== */
.client-pc-hint,
.client-mb-hint {
    text-align: center;
    padding: 14px;
}

.client-pc-hint a,
.client-mb-hint a {
    color: var(--sky);
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    transition: var(--ease);
}

.client-pc-hint a:hover,
.client-mb-hint a:hover { color: var(--sky-hover); }

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

.pager-lnk,
.pager-cur {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 7px 13px;
    border-radius: var(--radius-sm);
    font-size: 13px;
    transition: var(--ease);
    min-width: 36px;
    text-align: center;
    text-decoration: none;
}

.pager-lnk {
    background: var(--bg-card);
    color: var(--ink-mid);
    border: 1px solid var(--line);
}

.pager-lnk:hover {
    background: var(--sky);
    border-color: var(--sky);
    color: #fff;
    box-shadow: 0 3px 10px rgba(61,90,241,0.18);
}

.pager-cur {
    background: var(--sky);
    color: #fff;
    border: 1px solid var(--sky);
    font-weight: 700;
    cursor: default;
}

/* ===================== FOOTER LINKS ===================== */
.ext-links {
    padding: 12px;
    background: var(--bg-card);
    border-radius: var(--radius-md);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-xs);
}

.ext-links dl { margin: 0; }

.ext-links dd {
    display: inline-block;
    margin: 4px;
}

.ext-links a {
    color: var(--ink-soft);
    text-decoration: none;
    font-size: 13px;
    transition: var(--ease);
}

.ext-links a:hover { color: var(--sky); }

.pd5 { padding: 3px 6px; }

/* ===================== SITE FOOTER ===================== */
.bottom-bar {
    padding: 20px 0;
    text-align: center;
    border-top: 1px solid var(--line);
    margin-top: 16px;
    background: var(--bg-card);
}

.bottom-bar p {
    margin: 5px 0;
    color: var(--ink-soft);
    font-size: 13px;
}

.bottom-bar a {
    color: var(--ink-soft);
    text-decoration: none;
    transition: var(--ease);
}

.bottom-bar a:hover { color: var(--sky); }

/* ===================== UTILS ===================== */
.clearfix::after { content: ""; display: table; clear: both; }

.hide-mb { display: block; }
.hide-dt { display: block; }

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

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

/* ===================== RESPONSIVE ===================== */

@media (max-width: 768px) {
    .lyt-wrap { padding: 0 8px; }

    .site-nav { padding: 0.5rem 0; }

    .hd-brand { gap: 10px; }
    .hd-site-name { font-size: 19px; }
    .hd-domain-pill { padding: 4px 11px; gap: 5px; }
    .hd-domain-tag  { font-size: 10px; }
    .hd-domain-url  { font-size: 16px; }

    .lyt-block { padding: 6px 0; }

    .vod-zone-label {
        width: 15%;
        font-size: 10px;
        padding: 8px 2px;
        white-space: normal;
        word-break: break-all;
        overflow: visible;
    }

    .vod-zone-links {
        width: 85%;
        gap: 4px;
        padding: 8px 5px;
    }

    .vod-zone-links a {
        font-size: 12px;
        padding: 4px 2px;
        width: calc((100% - 12px) / 4);
        flex-shrink: 0;
        flex-grow: 0;
    }

    .vod-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 9px;
    }

    .media-block-title { font-size: 16px; }
    .vod-caption h5    { font-size: 12px; }

    .qr-box { padding: 10px; }
    .qr-box form { gap: 6px; }
    .qr-box input[type="text"] { min-width: 90px; padding: 9px 11px; font-size: 13px; }
    .qr-box button { padding: 9px 10px; font-size: 12px; }

    .kw-cloud { padding: 9px 10px; gap: 6px; }
    .kw-pill  { padding: 4px 10px; font-size: 12px; }

    .action-btns { padding: 12px 8px; gap: 8px; }
    .action-btn  { padding: 9px 16px; font-size: 13px; }

    .share-row         { padding: 10px; gap: 8px; margin: 8px 0; }
    .share-url-display { padding: 8px 10px; gap: 6px; }
    .share-label       { font-size: 10px; }
    .share-url         { font-size: 10px; }
    .share-copy-btn    { padding: 8px 11px; font-size: 12px; }
    .share-icon        { font-size: 14px; }

    .pager-lnk,
    .pager-cur { padding: 6px 10px; font-size: 12px; min-width: 30px; }

    .media-block { margin-bottom: 10px; }

    .item-title-bar   { padding: 13px 14px; font-size: 14px; margin: 10px 0; }
    .item-detail-card { padding: 14px 13px; font-size: 14px; margin: 8px 0; }
}

@media (max-width: 480px) {
    .site-nav { padding: 0.4rem 0; }

    .hd-site-name { font-size: 17px; }
    .hd-domain-pill { padding: 4px 9px; }
    .hd-domain-tag  { font-size: 9px; }
    .hd-domain-url  { font-size: 15px; }

    .vod-zone-label {
        width: 15%;
        font-size: 10px;
        padding: 6px 2px;
    }

    .vod-zone-links {
        width: 85%;
        gap: 3px;
        padding: 6px 4px;
    }

    .vod-zone-links a {
        font-size: 12px;
        padding: 3px 1px;
        width: calc((100% - 9px) / 4);
    }

    .vod-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 7px;
    }

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

    .media-block-title { font-size: 15px; }
    .action-btn { padding: 8px 13px; font-size: 12px; }

    .share-row      { padding: 8px; gap: 6px; }
    .share-copy-btn { padding: 7px 10px; font-size: 11px; }
}

@media (min-width: 769px) {
    .vod-grid { grid-template-columns: repeat(4, 1fr); }
    .vod-zone-label { font-size: 14px; }
    .vod-zone-links a { font-size: 13px; }
}
