/* Video Site Template - TI Innotech Style: Dark Navy + Electric Blue + White */

:root {
    --navy:      #040d1e;
    --navy2:     #071428;
    --navy3:     #0b1f3a;
    --navy4:     #0f2850;
    --blue:      #0ea5e9;
    --blue-h:    #38bdf8;
    --blue-d:    #0284c7;
    --blue-glow: rgba(14,165,233,0.18);
    --blue-dim:  rgba(14,165,233,0.08);
    --border:    rgba(14,165,233,0.2);
    --border-lt: rgba(14,165,233,0.1);
    --txt:       #f0f6ff;
    --txt-sub:   #94b8d4;
    --txt-dim:   #4a6a8a;
    --txt-white: #ffffff;
    --shadow-xs: 0 1px 4px rgba(0,0,0,0.5);
    --shadow-sm: 0 2px 10px rgba(0,0,0,0.6);
    --shadow-md: 0 4px 24px rgba(0,0,0,0.7);
    --shadow-blu: 0 0 20px rgba(14,165,233,0.25);
    --r-xs:      4px;
    --r-sm:      8px;
    --r-md:      12px;
    --r-lg:      18px;
    --r-pill:    999px;
    --ease:      all 0.2s ease;
    --max-w:     1080px;
}

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

body {
    font-family: -apple-system, 'PingFang SC', 'Segoe UI', 'Microsoft YaHei', Arial, sans-serif;
    background: var(--navy);
    background-image:
        radial-gradient(ellipse at 15% 0%, rgba(14,165,233,0.12) 0%, transparent 55%),
        radial-gradient(ellipse at 85% 20%, rgba(14,165,233,0.07) 0%, transparent 45%);
    color: var(--txt);
    line-height: 1.55;
    font-size: 14px;
    overflow-x: hidden;
    min-height: 100vh;
}

/* ===================== HEADER ===================== */
.ti-hd {
    background: rgba(4,13,30,0.92);
    border-bottom: 1px solid var(--border);
    padding: 0.5rem 0;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.ti-hd-in {
    display: flex;
    justify-content: center;
    align-items: center;
}

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

.ti-logo {
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.ti-sitename {
    font-size: 21px;
    font-weight: 900;
    color: var(--txt-white);
    letter-spacing: 0.5px;
    line-height: 1;
    text-transform: uppercase;
}

.ti-domain {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 5px 14px;
    background: var(--blue-dim);
    border: 1px solid var(--border);
    border-radius: var(--r-pill);
}

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

.ti-domain-val {
    font-size: 13px;
    font-weight: 700;
    color: var(--blue-h);
    font-family: 'Courier New', monospace;
}

/* ===================== LAYOUT ===================== */
.ti-wrap {
    max-width: var(--max-w);
    margin: 0 auto;
    padding: 0 12px;
}

.ti-row {
    padding: 7px 0;
}

/* ===================== NAV BLOCK ===================== */
.ti-navbox {
    background: var(--navy2);
    border: 1px solid var(--border);
    border-radius: var(--r-md);
    overflow: hidden;
    margin-bottom: 7px;
    box-shadow: var(--shadow-xs);
}

.ti-navstrip {
    display: flex;
    align-items: stretch;
    border-bottom: 1px solid var(--border-lt);
}

.ti-navstrip:last-child {
    border-bottom: none;
}

.ti-navlabel {
    font-size: 13px;
    font-weight: 800;
    color: var(--blue);
    white-space: nowrap;
    width: 10%;
    text-align: center;
    border-right: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 9px 4px;
    flex-shrink: 0;
    background: var(--blue-dim);
    letter-spacing: 0.2px;
    text-transform: uppercase;
}

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

.ti-navlinks a {
    display: inline-block;
    color: var(--txt-sub);
    text-decoration: none;
    padding: 4px 4px;
    border-radius: var(--r-xs);
    transition: var(--ease);
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border-lt);
    white-space: nowrap;
    text-align: center;
    width: calc((100% - 35px) / 8);
    flex-shrink: 0;
    flex-grow: 0;
    font-size: 13px;
}

.ti-navlinks a:hover {
    background: var(--blue);
    color: var(--txt-white);
    border-color: var(--blue);
    box-shadow: 0 0 10px rgba(14,165,233,0.35);
}

.ti-navlinks a.active {
    background: var(--blue-d);
    color: var(--txt-white);
    border-color: var(--blue-d);
    font-weight: 700;
    box-shadow: 0 0 10px rgba(14,165,233,0.3);
}

/* ===================== SEARCH ===================== */
.ti-sbox {
    background: var(--navy2);
    border: 1px solid var(--border);
    border-radius: var(--r-md);
    padding: 10px 12px;
    margin-bottom: 7px;
    box-shadow: var(--shadow-xs);
}

.ti-sbox form {
    display: flex;
    gap: 7px;
    flex-wrap: nowrap;
    align-items: center;
}

.ti-sbox input[type="text"] {
    flex: 1;
    min-width: 100px;
    padding: 9px 14px;
    border: 1px solid var(--border);
    border-radius: var(--r-sm);
    background: rgba(255,255,255,0.05);
    color: var(--txt);
    font-size: 13px;
    transition: var(--ease);
    outline: none;
    font-family: inherit;
}

.ti-sbox input[type="text"]:focus {
    border-color: var(--blue);
    background: rgba(14,165,233,0.08);
    box-shadow: 0 0 0 2px rgba(14,165,233,0.15);
}

.ti-sbox input[type="text"]::placeholder {
    color: var(--txt-dim);
}

.ti-sbox button {
    padding: 9px 16px;
    border: none;
    border-radius: var(--r-sm);
    background: var(--blue);
    color: var(--txt-white);
    font-weight: 800;
    font-size: 13px;
    cursor: pointer;
    transition: var(--ease);
    white-space: nowrap;
    flex-shrink: 0;
    font-family: inherit;
    letter-spacing: 0.3px;
    text-transform: uppercase;
}

.ti-sbox button:hover {
    background: var(--blue-h);
    box-shadow: var(--shadow-blu);
    transform: translateY(-1px);
}

/* ===================== TAG CLOUD ===================== */
.ti-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    list-style: none;
    padding: 9px 10px;
    background: var(--navy2);
    border-radius: var(--r-md);
    margin-bottom: 7px;
    border: 1px solid var(--border);
    box-shadow: var(--shadow-xs);
}

.ti-tag {
    padding: 4px 12px;
    background: var(--blue-dim);
    border-radius: var(--r-pill);
    color: var(--blue-h);
    text-decoration: none;
    font-size: 12px;
    font-weight: 600;
    transition: var(--ease);
    border: 1px solid var(--border);
}

.ti-tag:hover {
    background: var(--blue);
    color: var(--txt-white);
    border-color: var(--blue);
    box-shadow: 0 0 8px rgba(14,165,233,0.4);
}

/* ===================== SECTION BLOCKS ===================== */
.ti-section {
    margin-bottom: 14px;
}

.ti-sec-hd {
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border-lt);
    position: relative;
}

.ti-sec-hd::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 48px;
    height: 1px;
    background: var(--blue);
    box-shadow: 0 0 8px var(--blue);
}

.ti-sec-ttl {
    font-size: 17px;
    font-weight: 900;
    margin: 0;
    color: var(--txt-white);
    letter-spacing: 0.2px;
    text-transform: uppercase;
}

.ti-sec-ttl a {
    color: var(--txt-white);
    text-decoration: none;
    transition: var(--ease);
}

.ti-sec-ttl a:hover {
    color: var(--blue-h);
}

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

.ti-grid li {
    animation: tiRise 0.4s ease backwards;
}

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

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

.ti-thumb {
    display: block;
    position: relative;
    overflow: hidden;
    border-radius: var(--r-sm);
    aspect-ratio: 600 / 350;
    background: var(--navy3);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-xs);
}

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

.ti-thumb:hover {
    border-color: var(--blue);
    box-shadow: 0 0 18px rgba(14,165,233,0.3);
}

.ti-thumb:hover img {
    transform: scale(1.07);
}

.ti-thumb::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(4,13,30,0.8) 0%, transparent 55%);
    opacity: 0;
    transition: opacity 0.25s ease;
    pointer-events: none;
}

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

.ti-cap {
    padding: 6px 0 2px;
}

.ti-cap h5 {
    font-size: 12px;
    font-weight: 500;
    margin: 0;
    line-height: 1.4;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.ti-cap h5 a {
    color: var(--txt-sub);
    text-decoration: none;
    transition: var(--ease);
}

.ti-cap h5 a:hover {
    color: var(--blue-h);
}

/* ===================== VIDEO PLAYER ===================== */
.ti-player {
    background: var(--navy2);
    border-radius: var(--r-md);
    overflow: hidden;
    border: 1px solid var(--border);
    margin-bottom: 12px;
    box-shadow: var(--shadow-md);
}

.video-container {
    position: relative;
    width: 100%;
    height: 480px;
    background: #000;
    overflow: hidden;
}

.video-container iframe,
.video-container video,
.video-container object,
.video-container embed {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    border: 0;
}

/* ===================== DETAIL INFO ===================== */
.ti-det-ttl {
    line-height: 1.8;
    text-align: center;
    padding: 14px 18px;
    font-size: 15px;
    margin: 10px 0;
    word-break: break-all;
    background: var(--blue-dim);
    border-radius: var(--r-md);
    border: 1px solid var(--border);
}

.ti-det-ttl a {
    color: var(--blue-h);
    text-decoration: none;
    font-weight: 800;
    margin-right: 6px;
}

.ti-det-ttl a:hover { text-decoration: underline; }

.ti-det-meta {
    font-size: 14px;
    line-height: 1.9;
    padding: 18px 20px;
    background: var(--navy2);
    border-radius: var(--r-md);
    border: 1px solid var(--border);
    margin: 10px 0;
    box-shadow: var(--shadow-xs);
}

/* ===================== TORRENT CAPTURES ===================== */
.ti-preview {
    margin-top: 12px;
}

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

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

/* ===================== DOWNLOAD BUTTONS ===================== */
.ti-dl-bar {
    display: flex;
    gap: 12px;
    justify-content: center;
    align-items: center;
    padding: 14px 10px;
    margin: 10px 0;
    flex-wrap: wrap;
}

.ti-dl-btn {
    display: inline-block;
    padding: 10px 26px;
    border-radius: var(--r-sm);
    font-size: 14px;
    font-weight: 800;
    text-decoration: none;
    cursor: pointer;
    transition: var(--ease);
    border: none;
    background: var(--blue);
    color: var(--txt-white);
    font-family: inherit;
    letter-spacing: 0.3px;
    text-transform: uppercase;
    box-shadow: 0 0 12px rgba(14,165,233,0.3);
}

.ti-dl-btn:hover {
    background: var(--blue-h);
    box-shadow: 0 0 22px rgba(14,165,233,0.5);
    transform: translateY(-2px);
}

/* ===================== CLIENT LINKS ===================== */
.ti-client {
    text-align: center;
    padding: 10px 16px;
}

.ti-client a {
    color: var(--blue);
    text-decoration: none;
    font-weight: 700;
    font-size: 13px;
}

.ti-client a:hover {
    color: var(--blue-h);
    text-decoration: underline;
}

/* ===================== SHARE SECTION ===================== */
.share-section {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    background: var(--navy2);
    border: 1px solid var(--border);
    border-radius: var(--r-md);
    margin: 10px 0;
    flex-wrap: nowrap;
    box-shadow: var(--shadow-xs);
}

.share-url-display {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    min-width: 0;
    background: rgba(255,255,255,0.04);
    padding: 7px 12px;
    border-radius: var(--r-xs);
    border: 1px solid var(--border-lt);
    overflow: hidden;
}

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

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

.share-copy-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 8px 14px;
    border-radius: var(--r-sm);
    background: var(--blue);
    color: var(--txt-white);
    border: none;
    font-size: 12px;
    font-weight: 800;
    cursor: pointer;
    transition: var(--ease);
    white-space: nowrap;
    flex-shrink: 0;
    font-family: inherit;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.share-copy-btn:hover {
    background: var(--blue-h);
    box-shadow: var(--shadow-blu);
}

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

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

.ti-pg,
.ti-pg-on {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 14px;
    border-radius: var(--r-xs);
    font-size: 13px;
    font-weight: 600;
    transition: var(--ease);
    min-width: 34px;
    text-align: center;
    text-decoration: none;
    font-family: inherit;
}

.ti-pg {
    background: var(--navy2);
    color: var(--txt-sub);
    border: 1px solid var(--border);
}

.ti-pg:hover {
    background: var(--blue);
    border-color: var(--blue);
    color: var(--txt-white);
    box-shadow: 0 0 8px rgba(14,165,233,0.3);
}

.ti-pg-on {
    background: var(--blue);
    color: var(--txt-white);
    border: 1px solid var(--blue);
    cursor: default;
    font-weight: 800;
    box-shadow: 0 0 10px rgba(14,165,233,0.35);
}

/* ===================== FOOTER ===================== */
.ti-foot {
    padding: 20px 0;
    text-align: center;
    border-top: 1px solid var(--border);
    margin-top: 20px;
    background: var(--navy2);
}

.ti-foot p {
    margin: 4px 0;
    color: var(--txt-dim);
    font-size: 12px;
}

.ti-foot a {
    color: var(--txt-dim);
    text-decoration: none;
    transition: var(--ease);
}

.ti-foot a:hover { color: var(--blue); }

/* ===================== FRIEND LINKS ===================== */
.ti-flink {
    padding: 9px 12px;
    background: var(--navy2);
    border-radius: var(--r-md);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-xs);
}

.ti-flink dl {
    margin: 0;
    display: flex;
    flex-wrap: wrap;
}

.ti-flink dd {
    display: inline-block;
    margin: 3px 2px;
}

.ti-flink a {
    color: var(--blue);
    text-decoration: none;
    transition: var(--ease);
    font-size: 12px;
    padding: 1px 5px;
    border-radius: var(--r-xs);
}

.ti-flink a:hover {
    color: var(--txt-white);
    background: var(--blue-dim);
}

/* ===================== CLEARFIX ===================== */
.ticlr::after { content: ""; display: table; clear: both; }

/* ===================== VISIBILITY ===================== */
.ti-pc  { display: block; }
.ti-mob { display: block; }

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

/* ===================== RESPONSIVE ===================== */
@media (max-width: 768px) {
    .ti-wrap { padding: 0 8px; }
    .ti-hd { padding: 0.4rem 0; }
    .ti-brand { gap: 9px; }
    .ti-sitename { font-size: 17px; }
    .ti-domain { padding: 4px 10px; gap: 6px; }
    .ti-domain-lbl { font-size: 9px; }
    .ti-domain-val { font-size: 11px; }
    .ti-row { padding: 5px 0; }

    /* Mobile nav: zone 15%, links 85%, 4 per row */
    .ti-navstrip .ti-navlabel {
        width: 15%;
        font-size: 10px;
        padding: 7px 2px;
        letter-spacing: 0;
    }

    .ti-navstrip .ti-navlinks {
        width: 85%;
        font-size: 12px;
        gap: 3px;
        padding: 7px 3px;
    }

    .ti-navstrip .ti-navlinks a {
        font-size: 12px;
        padding: 4px 2px;
        width: calc((100% - 9px) / 4);
        flex-shrink: 0;
        flex-grow: 0;
    }

    .ti-grid { grid-template-columns: repeat(2, 1fr); gap: 9px; }
    .ti-cap h5 { font-size: 12px; }
    .ti-sec-ttl { font-size: 14px; }
    .ti-tags { padding: 7px 8px; gap: 5px; }
    .ti-tag { padding: 3px 9px; font-size: 11px; }

    .ti-sbox { padding: 8px 9px; }
    .ti-sbox form { gap: 5px; }
    .ti-sbox input[type="text"] { min-width: 70px; padding: 7px 10px; font-size: 12px; }
    .ti-sbox button { padding: 7px 10px; font-size: 12px; }

    .video-container { height: 56.25vw; max-height: 340px; margin-bottom: 12px; }

    .ti-dl-bar { padding: 10px 6px; gap: 8px; }
    .ti-dl-btn { padding: 8px 16px; font-size: 12px; }

    .share-section { padding: 8px 10px; margin: 8px 0; gap: 6px; }
    .share-url-display { padding: 6px 9px; gap: 5px; }
    .share-label { font-size: 10px; }
    .share-url { font-size: 10px; }
    .share-copy-btn { padding: 6px 10px; font-size: 11px; flex-shrink: 0; }
    .share-icon { font-size: 13px; }

    .ti-pager { gap: 4px; padding: 12px 0; }
    .ti-pg, .ti-pg-on { padding: 5px 10px; font-size: 12px; min-width: 28px; }
    .ti-foot { padding: 15px 0; margin-top: 15px; }
}

@media (max-width: 480px) {
    .ti-sitename { font-size: 15px; }
    .ti-domain-lbl { font-size: 8px; }
    .ti-domain-val { font-size: 10px; }

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

    .ti-cap h5 { font-size: 12px; }
    .ti-sec-ttl { font-size: 13px; }
    .video-container { height: 56.25vw; max-height: 260px; }
    .ti-dl-btn { padding: 7px 13px; font-size: 12px; }
    .share-section { padding: 6px 8px; }
    .share-url-display { padding: 5px 7px; }
    .share-copy-btn { padding: 5px 8px; font-size: 11px; }
}

/* ===================== LAZY IMG ===================== */
img[data-original] { background: var(--navy3); }
