/* ===========================================================================
   tpl003 重排版样式 —— 设计主题：墨蓝描边 (Ink Slate Outline)
   深墨蓝底 + 直角 + 1px 细描边（无圆角无阴影）+ 琥珀色点缀
   + PC 端左侧固定栏（导航/推荐）+ 高密度紧凑排布 + 列表页横向行式

   约定：
   - 本文件在 all-responsive-metal.css 之后加载，只负责新版式。
   - 所有类名统一 t3- 前缀，与旧主题类名（content/header/box/list-videos/item…）
     完全隔离，避免旧样式表里的规则意外命中新结构。
   - 播放器由程序输出、磁力按钮沿用旧 down_btn 钩子，故旧样式表必须保留引用。
   - 导航与搜索全部为纯 CSS + 原生表单，不依赖 main.min.js。
   =========================================================================== */

.t3-scope,
.t3-scope * { box-sizing: border-box; }

:root {
    --t3-bg: #101722;
    --t3-panel: #16202e;
    --t3-panel-2: #1b2637;
    --t3-line: #2a3849;
    --t3-line-soft: #212d3c;
    --t3-text: #dfe7f1;
    --t3-text-soft: #b3c0d1;
    --t3-muted: #74849a;
    --t3-accent: #f5b301;
    --t3-accent-soft: rgba(245, 179, 1, .14);
    --t3-side-w: 232px;
    --t3-max: 1560px;
}

/* --------------------------------------------------------------- 基础层 */
body.t3-body {
    margin: 0;
    padding-left: var(--t3-side-w);
    background: var(--t3-bg);
    color: var(--t3-text);
    font: 400 13px/1.65 "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

.t3-scope { position: relative; }
.t3-scope-top { z-index: 800; }

.t3-scope a { color: inherit; text-decoration: none; }
.t3-scope img { display: block; max-width: 100%; border: 0; }
.t3-scope ul, .t3-scope li, .t3-scope dl, .t3-scope dd, .t3-scope dt { margin: 0; padding: 0; list-style: none; }
.t3-scope h1, .t3-scope h2, .t3-scope h3, .t3-scope p { margin: 0; font-weight: inherit; }

.t3-wrap {
    max-width: var(--t3-max);
    margin: 0 auto;
    padding: 0 16px;
}

/* --------------------------------------------------------------- 左侧固定栏 */
.t3-side {
    position: fixed;
    left: 0;
    top: 0;
    z-index: 900;
    width: var(--t3-side-w);
    height: 100%;
    padding: 18px 0 24px;
    overflow-y: auto;
    background: #0c121b;
    border-right: 1px solid var(--t3-line);
}

.t3-brand {
    display: block;
    padding: 0 18px 16px;
    border-bottom: 1px solid var(--t3-line-soft);
}

.t3-brand img { max-height: 42px; width: auto; }

.t3-side-group { padding: 14px 0 6px; }

.t3-side-group > dt {
    padding: 0 18px 8px;
    font-size: 11px;
    letter-spacing: 3px;
    color: var(--t3-muted);
    text-transform: uppercase;
}

.t3-side-group > dd > a,
.t3-side-group > a {
    display: block;
    padding: 8px 18px;
    font-size: 13px;
    color: var(--t3-text-soft);
    border-left: 2px solid transparent;
    transition: background .15s, color .15s, border-color .15s;
}

.t3-side-group > dd > a:hover,
.t3-side-group > a:hover {
    background: var(--t3-panel-2);
    border-left-color: var(--t3-accent);
    color: #fff;
}

.t3-side-links {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 6px 14px 0;
}

.t3-side-links a {
    padding: 3px 8px;
    font-size: 12px;
    color: var(--t3-muted);
    border: 1px solid var(--t3-line);
}

.t3-side-links a:hover {
    color: var(--t3-accent);
    border-color: var(--t3-accent);
}

/* --------------------------------------------------------------- 顶部搜索条 */
.t3-topbar {
    border-bottom: 1px solid var(--t3-line);
    background: var(--t3-panel);
}

.t3-topbar-in {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    padding-top: 12px;
    padding-bottom: 12px;
}

.t3-search {
    display: flex;
    flex: 1 1 340px;
    max-width: 620px;
    border: 1px solid var(--t3-line);
    background: #0e1622;
}

.t3-search input {
    flex: 1;
    min-width: 0;
    padding: 9px 14px;
    border: 0;
    outline: 0;
    background: transparent;
    color: var(--t3-text);
    font-size: 13px;
}

.t3-search input::placeholder { color: var(--t3-muted); }

.t3-search button {
    padding: 0 24px;
    border: 0;
    cursor: pointer;
    background: var(--t3-accent);
    color: #16202e;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 2px;
}

.t3-search button:hover { background: #ffc62b; }

.t3-tags {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    font-size: 12px;
    color: var(--t3-muted);
}

.t3-tags b {
    font-weight: 400;
    color: var(--t3-accent);
    letter-spacing: 1px;
}

.t3-tags a {
    padding: 2px 8px;
    border: 1px solid var(--t3-line);
    color: var(--t3-text-soft);
}

.t3-tags a:hover {
    border-color: var(--t3-accent);
    color: var(--t3-accent);
    background: var(--t3-accent-soft);
}

/* --------------------------------------------------------------- 广告位 */
/* 空广告位整块会被替换成空串，所以容器不设最小高度 */
.t3-ad-banner { margin: 14px 0 0; }

.t3-ad-banner a {
    display: block;
    margin-bottom: 6px;
    border: 1px solid var(--t3-line);
}

.t3-ad-banner img { width: 100%; object-fit: cover; }

/* --------------------------------------------------------------- 区块标题 */
.t3-section { margin: 26px 0; }

.t3-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 0 0 10px;
    border-bottom: 1px solid var(--t3-line);
    margin-bottom: 16px;
}

.t3-section-head h1,
.t3-section-head h2 {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 17px;
    font-weight: 700;
    letter-spacing: 1px;
}

.t3-section-head h1::before,
.t3-section-head h2::before {
    content: "";
    display: block;
    width: 10px;
    height: 10px;
    background: var(--t3-accent);
}

.t3-more {
    flex: 0 0 auto;
    padding: 3px 10px;
    font-size: 12px;
    color: var(--t3-muted);
    border: 1px solid var(--t3-line);
}

.t3-more:hover {
    color: var(--t3-accent);
    border-color: var(--t3-accent);
}

/* --------------------------------------------------------------- 网格：直角描边卡 */
.t3-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 14px;
}

.t3-item {
    display: block;
    background: var(--t3-panel);
    border: 1px solid var(--t3-line);
    transition: border-color .15s, background .15s;
}

.t3-item:hover {
    border-color: var(--t3-accent);
    background: var(--t3-panel-2);
}

.t3-item-pic {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #0c121b;
}

.t3-item-pic img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: .92;
    transition: opacity .2s;
}

.t3-item:hover .t3-item-pic img { opacity: 1; }

.t3-item-title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 3em;
    padding: 7px 9px 9px;
    font-size: 12px;
    line-height: 1.5;
    color: var(--t3-text-soft);
    border-top: 1px solid var(--t3-line-soft);
}

.t3-item:hover .t3-item-title { color: var(--t3-accent); }

/* --------------------------------------------------------------- 列表页：横向行 */
.t3-rows {
    display: flex;
    flex-direction: column;
    border-top: 1px solid var(--t3-line-soft);
}

.t3-row {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 10px 8px;
    border-bottom: 1px solid var(--t3-line-soft);
    transition: background .15s;
}

.t3-row:hover { background: var(--t3-panel); }

.t3-row-pic {
    flex: 0 0 200px;
    width: 200px;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #0c121b;
    border: 1px solid var(--t3-line);
}

.t3-row-pic img { width: 100%; height: 100%; object-fit: cover; }

.t3-row-title {
    flex: 1 1 auto;
    min-width: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 14px;
    line-height: 1.6;
    color: var(--t3-text-soft);
}

.t3-row:hover .t3-row-title { color: var(--t3-accent); }

/* --------------------------------------------------------------- 分页 */
.t3-pager {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin: 24px 0 34px;
}

.t3-pager a,
.t3-pager .t3-page-cur {
    display: inline-block;
    min-width: 38px;
    padding: 7px 12px;
    text-align: center;
    font-size: 13px;
    border: 1px solid var(--t3-line);
    color: var(--t3-text-soft);
    background: var(--t3-panel);
}

.t3-pager a:hover {
    border-color: var(--t3-accent);
    color: var(--t3-accent);
}

.t3-pager .t3-page-cur {
    background: var(--t3-accent);
    border-color: var(--t3-accent);
    color: #16202e;
    font-weight: 700;
    cursor: default;
}

/* --------------------------------------------------------------- 详情页 */
.t3-detail { margin: 18px 0 0; }

.t3-detail-title {
    padding: 14px 0 12px;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.5;
    word-break: break-all;
    overflow-wrap: break-word;
    border-bottom: 1px solid var(--t3-line);
}

/* 播放器由程序注入，这里只做外框，不干预其内部结构与高度 */
.t3-player {
    margin-top: 14px;
    background: #000;
    border: 1px solid var(--t3-line);
}

.t3-player video,
.t3-player iframe { display: block; width: 100%; border: 0; }

.t3-panel {
    margin-top: 14px;
    padding: 16px;
    background: var(--t3-panel);
    border: 1px solid var(--t3-line);
}

.t3-spec {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1px;
    background: var(--t3-line-soft);
    border: 1px solid var(--t3-line-soft);
}

.t3-spec div {
    padding: 8px 12px;
    background: var(--t3-panel-2);
    font-size: 13px;
    color: var(--t3-text-soft);
    word-break: break-all;
}

.t3-spec b {
    display: inline-block;
    min-width: 6em;
    font-weight: 400;
    color: var(--t3-muted);
}

.t3-subtitle {
    margin: 16px 0 8px;
    font-size: 13px;
    letter-spacing: 2px;
    color: var(--t3-muted);
}

.t3-shots {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
}

.t3-shots img {
    width: 100%;
    border: 1px solid var(--t3-line);
}

/* 磁力按钮：沿用旧的 down_btn 钩子，这里只做外观覆盖 */
.t3-btns {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

.t3-btns .down_btn {
    display: inline-block;
    padding: 10px 24px;
    cursor: pointer;
    font-size: 13px;
    letter-spacing: 1px;
    color: var(--t3-accent);
    background: transparent;
    border: 1px solid var(--t3-accent);
    transition: background .15s, color .15s;
}

.t3-btns .down_btn:hover {
    background: var(--t3-accent);
    color: #16202e;
}

.t3-tip {
    margin-top: 12px;
    font-size: 12px;
    color: var(--t3-muted);
}

.t3-tip a { color: var(--t3-accent); }

/* --------------------------------------------------------------- 页脚 */
.t3-footer {
    margin-top: 30px;
    padding: 24px 0 30px;
    border-top: 1px solid var(--t3-line);
    background: #0c121b;
    color: var(--t3-muted);
    font-size: 12px;
    line-height: 1.9;
    text-align: center;
}

.t3-footer .t3-footer-note {
    max-width: 900px;
    margin: 8px auto 0;
    color: #5f6e83;
}

/* --------------------------------------------------------------- 响应式 */
/* 平板 */
@media (max-width: 1280px) {
    .t3-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (max-width: 960px) {
    body.t3-body { padding-left: 0; }

    /* 侧栏在窄屏还原为普通文档流区块，导航横向可滑动 */
    .t3-side {
        position: static;
        width: auto;
        height: auto;
        padding: 10px 0 0;
        overflow: visible;
        border-right: 0;
        border-bottom: 1px solid var(--t3-line);
    }

    .t3-brand { padding: 0 14px 10px; text-align: center; border-bottom: 0; }
    .t3-brand img { margin: 0 auto; max-height: 36px; }

    .t3-side-group {
        display: flex;
        align-items: center;
        gap: 2px;
        padding: 0 10px;
        overflow-x: auto;
        scrollbar-width: none;
        white-space: nowrap;
    }

    .t3-side-group::-webkit-scrollbar { display: none; }
    .t3-side-group > dt { flex: 0 0 auto; padding: 0 8px 0 4px; }

    .t3-side-group > dd { flex: 0 0 auto; }

    .t3-side-group > dd > a,
    .t3-side-group > a {
        flex: 0 0 auto;
        padding: 8px 10px;
        border-left: 0;
        border-bottom: 2px solid transparent;
    }

    .t3-side-group > dd > a:hover,
    .t3-side-group > a:hover { border-bottom-color: var(--t3-accent); }

    .t3-side-links { padding: 8px 12px 10px; }

    .t3-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .t3-spec { grid-template-columns: 1fr; }
}

/* 手机 */
@media (max-width: 640px) {
    .t3-wrap { padding: 0 10px; }
    .t3-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
    .t3-section { margin: 18px 0; }
    .t3-section-head h1,
    .t3-section-head h2 { font-size: 15px; }
    .t3-row { gap: 10px; padding: 8px 4px; }
    .t3-row-pic { flex: 0 0 132px; width: 132px; }
    .t3-row-title { font-size: 13px; }
    .t3-detail-title { font-size: 16px; }
    .t3-shots { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .t3-btns .down_btn { flex: 1 1 auto; text-align: center; padding: 10px 12px; }
    .t3-search { flex: 1 1 100%; }
}

/* --------------------------------------------------------------- 全站工具类 */
/* 模板里大量使用但全站原本无定义，PC / 手机两套区块会同时渲染 */ } }
