/* ==========================================================================
   Shenmac-001 天马行空 · base（结构层：令牌 / 布局 / 通用组件）
   --------------------------------------------------------------------------
   只放「全站复用」的东西：容器、按钮、胶囊、印章、顶栏、区块头、卡片、行式榜、
   面包屑、分页、页脚。单页专属的版式一律写在 tm.css（页面层）。
   类名族：tm- = 结构组件；tianma- = 页面版式（见 tm.css）。
   意境：夜空星野 —— 深空蓝黑底 + 星芒金强调 + 星辉蓝点缀。
   ========================================================================== */

:root {
    /* ---- 夜空与星 -------------------------------------------------------- */
    --tm-paper: #0b1122;          /* 页面底：深空蓝黑（冷色相，非纯黑非暖灰） */
    --tm-surface: #131c38;        /* 卡片面：比底亮一档，靠 1px 线分面 */
    --tm-surface-2: #1b2547;      /* 次级面：标签底 / 输入框 */
    --tm-surface-3: #233055;      /* 图占位 / 骨架 */
    --tm-ink: #eef2fc;            /* 星白（主文字） */
    --tm-ink-2: #aab6d8;          /* 次级文字 */
    --tm-ink-3: #7280a6;          /* 弱文字（时间 / 计数） */
    --tm-line: #26325c;           /* 1px 分隔线 */
    --tm-line-2: #3a4a80;         /* 强一点的线（表格头 / 输入框） */

    /* ---- 星芒金（唯一强调色；按钮/角标一律深金底白字，禁金底黑字） ------- */
    --tm-accent: #c89b42;
    --tm-accent-strong: #a1731b;  /* hover 压深 */
    --tm-accent-ink: #ffffff;     /* 金底上的字（硬约束：白字） */
    --tm-accent-soft: rgba(200, 155, 66, .12);
    --tm-accent-soft-2: rgba(200, 155, 66, .26);
    --tm-gold: #dfae52;           /* 星芒金：评分数字 / 星点 / 点亮态 */
    --tm-gold-soft: rgba(223, 174, 82, .14);
    --tm-star: #8fb3ff;           /* 星辉蓝：次级信息点缀（年份 / 计数） */
    /* 错误态：夜里的暖红 —— 全站唯一的非金/蓝彩色，只用于错误与警示 */
    --tm-danger: #e0654f;
    --tm-danger-soft: rgba(224, 101, 79, .35);
    --tm-danger-bg: rgba(224, 101, 79, .10);

    /* ---- 字号（最大标题 26px，需求方硬约束） ----------------------------- */
    --tm-fs-2xs: 11px;
    --tm-fs-xs: 12px;
    --tm-fs-sm: 13px;
    --tm-fs-base: 14px;
    --tm-fs-md: 15px;
    --tm-fs-lg: 18px;
    --tm-fs-xl: 20px;
    --tm-fs-h1: 24px;
    --tm-fs-max: 26px;
    --tm-lh: 1.7;
    --tm-lh-tight: 1.35;

    /* ---- 字体：标题宋体衬线，正文无衬线 -------------------------------- */
    --tm-serif: "Songti SC", "Noto Serif SC", "Source Han Serif SC", STSong, SimSun, serif;
    --tm-sans: "PingFang SC", "HarmonyOS Sans SC", "Microsoft YaHei", system-ui, -apple-system, "Segoe UI", sans-serif;
    --tm-num: "Iowan Old Style", "Songti SC", Georgia, serif;   /* 序号/评分用衬线数字 */

    /* ---- 容器与间距 ------------------------------------------------------ */
    --tm-shell: 1280px;
    --tm-gutter: clamp(12px, 2vw, 24px);
    --tm-gap-block: clamp(20px, 2vw, 30px);
    --tm-gap-inline: clamp(12px, 1.1vw, 16px);

    /* ---- 圆角：星穹弧（4/8/12/16 —— 比默认 web 大圆角克制，比直角柔和） -- */
    --tm-r-xs: 4px;
    --tm-r-sm: 8px;
    --tm-r-md: 12px;
    --tm-r-lg: 16px;
    --tm-r-seal: 5px;

    /* ---- 阴影：冷调深投；悬停点亮靠金晕（--tm-glow）而不是发黑 ------------- */
    --tm-sh-1: 0 1px 3px rgba(2, 4, 12, .45);
    --tm-sh-2: 0 10px 28px rgba(2, 4, 12, .6);
    --tm-glow: 0 0 0 1px rgba(223, 174, 82, .32), 0 8px 22px rgba(223, 174, 82, .1);

    --tm-ease: cubic-bezier(.25, .6, .35, 1);
    --tm-t: .22s;

    --tm-header-h: 64px;
    --tm-anchor-offset: 80px;     /* 顶栏 64 + 吸顶呼吸位 */

    color-scheme: dark;
}

/* --------------------------------------------------------------------------
   1. 容器
   -------------------------------------------------------------------------- */
.tm-shell {
    width: 100%;
    max-width: var(--tm-shell);
    margin-inline: auto;
    padding-inline: var(--tm-gutter);
}
.tm-main { padding-block: var(--tm-gap-block); min-height: 50vh; }

/* --------------------------------------------------------------------------
   2. 按钮 / 胶囊 / 印章
   -------------------------------------------------------------------------- */
.tm-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex: 0 0 auto;                 /* 硬约束：行内不压缩 */
    height: 36px;
    padding: 0 16px;
    border-radius: var(--tm-r-sm);
    background: var(--tm-accent);
    color: var(--tm-accent-ink);
    font-size: var(--tm-fs-base);
    font-weight: 600;
    white-space: nowrap;
    transition: background var(--tm-t) var(--tm-ease), color var(--tm-t) var(--tm-ease), border-color var(--tm-t) var(--tm-ease);
}
.tm-btn:hover { background: var(--tm-accent-strong); }
.tm-btn svg { width: 14px; height: 14px; fill: currentColor; flex: 0 0 auto; }
.tm-btn--ghost {
    background: transparent;
    color: var(--tm-ink);
    border: 1px solid var(--tm-line-2);
}
.tm-btn--ghost:hover { background: var(--tm-surface-2); border-color: var(--tm-accent); color: var(--tm-accent); }
.tm-btn--sm { height: 30px; padding: 0 12px; font-size: var(--tm-fs-sm); }

.tm-chip {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    flex: 0 0 auto;
    height: 27px;
    padding: 0 10px;
    border-radius: var(--tm-r-sm);
    background: var(--tm-surface-2);
    border: 1px solid transparent;
    font-size: var(--tm-fs-xs);
    color: var(--tm-ink-2);
    white-space: nowrap;
    max-width: 100%;
    transition: color var(--tm-t) var(--tm-ease), background var(--tm-t) var(--tm-ease), border-color var(--tm-t) var(--tm-ease);
}
.tm-chip:hover { color: var(--tm-accent); background: var(--tm-accent-soft); }
.tm-chip.is-active { background: var(--tm-accent); color: var(--tm-accent-ink); font-weight: 600; }

/* 印章编号：朱底白字小方章，用于楼层序号 / 榜单单号 */
.tm-seal {
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    min-width: 22px;
    height: 22px;
    padding: 0 5px;
    border-radius: var(--tm-r-seal);
    background: var(--tm-accent);
    color: var(--tm-accent-ink);
    font: 700 var(--tm-fs-2xs)/1 var(--tm-serif);
    font-variant-numeric: tabular-nums;
}
.tm-seal--ghost { background: var(--tm-accent-soft); color: var(--tm-accent); }

/* 编号数字（衬线，弱色）：行式榜的 01/02/03 */
.tm-num {
    font-family: var(--tm-num);
    font-variant-numeric: tabular-nums;
    color: var(--tm-ink-3);
    font-weight: 600;
}

/* --------------------------------------------------------------------------
   3. 顶栏（传统横排频道菜单；窄屏收进抽屉）
   -------------------------------------------------------------------------- */
.tm-header {
    position: sticky;
    top: 0;
    z-index: 60;
    background: var(--tm-surface);
    border-bottom: 1px solid var(--tm-line);
}
.tm-header__bar {
    display: flex;
    align-items: center;
    gap: 14px;
    height: var(--tm-header-h);
}

.tm-brand { display: inline-flex; align-items: center; gap: 8px; flex: 0 0 auto; }
.tm-brand__mark {
    display: grid;
    place-items: center;
    width: 30px; height: 30px;
    border-radius: var(--tm-r-sm);
    background: var(--tm-accent);
    color: var(--tm-accent-ink);
    font: 700 17px/1 var(--tm-serif);
}
.tm-brand__name {
    font-family: var(--tm-serif);
    font-size: var(--tm-fs-lg);
    font-weight: 700;
    letter-spacing: .02em;
}
.tm-brand__slogan {
    font-size: var(--tm-fs-2xs);
    color: var(--tm-ink-3);
    padding-left: 8px;
    margin-left: 2px;
    border-left: 1px solid var(--tm-line);
    white-space: nowrap;
}

.tm-nav { display: flex; align-items: center; gap: 2px; min-width: 0; }
.tm-nav__item { position: relative; }
.tm-nav__link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    height: 34px;
    padding: 0 11px;
    border-radius: var(--tm-r-sm);
    font-size: var(--tm-fs-base);
    color: var(--tm-ink-2);
    white-space: nowrap;
    transition: color var(--tm-t) var(--tm-ease), background var(--tm-t) var(--tm-ease);
}
.tm-nav__item:hover > .tm-nav__link,
.tm-nav__link.is-active { color: var(--tm-accent); background: var(--tm-accent-soft); }
.tm-nav__caret {
    width: 10px; height: 10px;
    fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round;
    opacity: .55;
    transition: transform var(--tm-t) var(--tm-ease);
}
.tm-nav__item:hover > .tm-nav__link .tm-nav__caret { transform: rotate(180deg); }

.tm-nav__sub {
    position: absolute;
    left: 0;
    top: 100%;
    z-index: 3;
    width: max-content;             /* 不写会被条目宽度收缩成一条 */
    max-width: 460px;
    padding: 10px 12px;
    margin-top: 4px;
    background: var(--tm-surface);
    border: 1px solid var(--tm-line);
    border-radius: var(--tm-r-md);
    box-shadow: var(--tm-sh-2);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-4px);
    transition: opacity var(--tm-t) var(--tm-ease), visibility var(--tm-t) var(--tm-ease), transform var(--tm-t) var(--tm-ease);
}
.tm-nav__sub a {
    display: inline-block;
    padding: 4px 9px;
    margin: 2px 2px 2px 0;
    border-radius: var(--tm-r-xs);
    font-size: var(--tm-fs-sm);
    color: var(--tm-ink-2);
}
.tm-nav__sub a:hover { background: var(--tm-accent-soft); color: var(--tm-accent); }
@media (min-width: 1024px) {
    .tm-nav__item:hover > .tm-nav__sub,
    .tm-nav__item:focus-within > .tm-nav__sub,
    .tm-nav__item[data-open="1"] > .tm-nav__sub { opacity: 1; visibility: visible; transform: translateY(0); }
}

.tm-tools { display: flex; align-items: center; gap: 8px; margin-left: auto; flex: 0 0 auto; }
.tm-search {
    display: flex;
    align-items: center;
    gap: 6px;
    height: 34px;
    padding: 0 10px;
    border: 1px solid var(--tm-line-2);
    border-radius: var(--tm-r-sm);
    background: var(--tm-surface-2);
    transition: border-color var(--tm-t) var(--tm-ease), background var(--tm-t) var(--tm-ease);
}
.tm-search:focus-within { border-color: var(--tm-accent); background: var(--tm-surface); }
.tm-search svg { width: 14px; height: 14px; fill: none; stroke: var(--tm-ink-3); stroke-width: 2; flex: 0 0 auto; }
.tm-search input {
    width: 148px;
    border: 0;
    background: none;
    outline: none;
    font-size: var(--tm-fs-sm);
}
.tm-search input::placeholder { color: var(--tm-ink-3); }
.tm-iconbtn {
    display: grid;
    place-items: center;
    width: 34px; height: 34px;
    border-radius: var(--tm-r-sm);
    border: 1px solid var(--tm-line-2);
    color: var(--tm-ink-2);
}
.tm-iconbtn:hover { border-color: var(--tm-accent); color: var(--tm-accent); }
.tm-iconbtn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.tm-header__burger { display: none; }
@media (max-width: 1023.98px) {
    .tm-nav, .tm-search { display: none; }
    .tm-header__burger { display: grid; }
}

/* 抽屉（窄屏把整棵菜单搬进来，见 js/tm.js） */
.tm-drawer {
    position: fixed;
    inset: 0;
    z-index: 90;
    display: none;
    background: rgba(4, 7, 16, .55);
}
.tm-drawer.is-open { display: block; }
.tm-drawer__panel {
    position: absolute;
    top: 0; right: 0;
    width: min(86vw, 360px);
    height: 100%;
    overflow-y: auto;
    background: var(--tm-paper);
    border-left: 1px solid var(--tm-line);
    padding: 16px;
}
.tm-drawer__head { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.tm-drawer__head strong { font-family: var(--tm-serif); font-size: var(--tm-fs-md); }
.tm-drawer__close { margin-left: auto; }
.tm-drawer__search { margin-bottom: 14px; }
.tm-drawer__search .tm-search { display: flex; }
.tm-drawer__search .tm-search input { width: 100%; }

/* 抽屉里承载的是**被搬进来的同一棵菜单**（不是第二份 DOM）：
   窄屏竖排渲染，子分类就地展开成标签云。 */
.tm-drawer .tm-nav { display: block; }
.tm-drawer .tm-nav__item { display: block; border-bottom: 1px solid var(--tm-line); }
.tm-drawer .tm-nav__link {
    display: flex;
    width: 100%;
    height: auto;
    padding: 12px 8px;
    border-radius: 0;
    font-family: var(--tm-serif);
    font-size: var(--tm-fs-md);
    font-weight: 700;
    color: var(--tm-ink);
}
.tm-drawer .tm-nav__caret { display: none; }
.tm-drawer .tm-nav__sub {
    position: static;
    width: auto;
    max-width: none;
    opacity: 1;
    visibility: visible;
    transform: none;
    margin: 0;
    padding: 0 8px 10px;
    border: 0;
    box-shadow: none;
    background: none;
    display: flex;
    flex-wrap: wrap;
}

/* --------------------------------------------------------------------------
   4. 区块头 / 面
   -------------------------------------------------------------------------- */
.tm-sec { margin-top: var(--tm-gap-block); }
.tm-sec__head {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px 12px;
    padding-bottom: 10px;
    margin-bottom: 14px;
    border-bottom: 1px solid var(--tm-line);
}
.tm-sec__head h2 { font-size: var(--tm-fs-lg); }
.tm-sec__head h2 a:hover { color: var(--tm-accent); }
.tm-sec__head em {
    font-style: normal;
    font-size: var(--tm-fs-sm);
    color: var(--tm-ink-3);
}
.tm-sec__more {
    margin-left: auto;
    flex: 0 0 auto;
    font-size: var(--tm-fs-sm);
    color: var(--tm-ink-3);
}
.tm-sec__more:hover { color: var(--tm-accent); }

.tm-panel {
    background: var(--tm-surface);
    border: 1px solid var(--tm-line);
    border-radius: var(--tm-r-md);
    padding: 14px;
}

/* --------------------------------------------------------------------------
   5. 海报卡（全站共用 · 星座卡）
   签名：悬停时海报浮现「星座层」（微光 + 连线 + 星点闪烁），卡片不位移不缩放，
        只靠描边金晕与图片提亮提示可点。
   角标预算 = 2：左上「金签·评分」+ 右下「彗星签·更新状态」。不得再加第三个。
   -------------------------------------------------------------------------- */
.tm-card {
    position: relative;
    min-width: 0;
    background: var(--tm-surface);
    border: 1px solid var(--tm-line);
    border-radius: var(--tm-r-md);
    overflow: hidden;
    transition: border-color var(--tm-t) var(--tm-ease), box-shadow var(--tm-t) var(--tm-ease);
}
.tm-card:hover { border-color: var(--tm-accent); box-shadow: var(--tm-glow); }
.tm-card > a { display: block; }
.tm-card__pic {
    position: relative;
    display: block;
    aspect-ratio: 2 / 3;
    background: var(--tm-surface-3);
    overflow: hidden;
}
.tm-card__pic img {
    width: 100%; height: 100%;
    object-fit: cover;
    transition: filter .45s var(--tm-ease);
}
.tm-card:hover .tm-card__pic img { filter: brightness(1.1); }
/* 星座层分两层：连线（::before）与星点（::after）。
   ⚠️ twinkle 动画只碰 filter，不碰 opacity —— 淡入用的 opacity 过渡在同一个
   元素上被 animation 覆盖会让淡入直接失效。 */
.tm-card__pic::before,
.tm-card__pic::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    opacity: 0;
    pointer-events: none;
    transition: opacity .5s var(--tm-ease);
}
.tm-card__pic::before {
    background:
        radial-gradient(120px 90px at 26% 24%, rgba(223, 174, 82, .18), transparent 70%),
        linear-gradient(112deg, transparent 30.6%, rgba(223, 174, 82, .3) 30.6% 31%, transparent 31%),
        linear-gradient(31deg, transparent 47.8%, rgba(143, 179, 255, .26) 47.8% 48.2%, transparent 48.2%),
        linear-gradient(74deg, transparent 64.4%, rgba(223, 174, 82, .24) 64.4% 64.8%, transparent 64.8%);
}
.tm-card__pic::after {
    background:
        radial-gradient(circle at 22% 27%, rgba(223, 174, 82, .95) 0 2px, transparent 2.6px),
        radial-gradient(circle at 55% 19%, rgba(223, 174, 82, .8) 0 1.5px, transparent 2px),
        radial-gradient(circle at 78% 41%, rgba(143, 179, 255, .9) 0 2px, transparent 2.6px),
        radial-gradient(circle at 63% 63%, rgba(143, 179, 255, .75) 0 1.5px, transparent 2px),
        radial-gradient(circle at 33% 74%, rgba(223, 174, 82, .85) 0 2px, transparent 2.6px),
        radial-gradient(circle at 84% 78%, rgba(223, 174, 82, .7) 0 1.5px, transparent 2px);
    animation: tm-twinkle 3.4s ease-in-out infinite;
}
.tm-card:hover .tm-card__pic::before,
.tm-card:hover .tm-card__pic::after { opacity: 1; }
@keyframes tm-twinkle {
    0%, 100% { filter: brightness(1); }
    50%      { filter: brightness(1.7); }
}
/* 金签·评分：金渐变胶囊 + 星标（硬约束：金底白字，禁黑字） */
.tm-card__score {
    position: absolute;
    left: 6px; top: 6px;
    z-index: 2;
    display: inline-flex;
    align-items: baseline;
    gap: 3px;
    padding: 2px 8px 2px 7px;
    border-radius: 999px;
    background: linear-gradient(135deg, #dfae52, #c89b42 52%, #a1731b);
    color: #ffffff;
    font: 700 var(--tm-fs-xs)/1.6 var(--tm-num);
    box-shadow: 0 2px 8px rgba(2, 4, 12, .45);
}
.tm-card__score::before { content: "\2605"; font-size: 8px; line-height: 1; align-self: center; }
.tm-card__score i { font: 400 var(--tm-fs-2xs)/1 var(--tm-sans); font-style: normal; opacity: .85; }
/* 彗星签·更新状态：左尖角 + 金色彗头，只做形状与色带，不加第二个元素 */
.tm-card__note {
    position: absolute;
    right: 6px; bottom: 6px;
    z-index: 2;
    max-width: calc(100% - 12px);
    padding: 3px 8px 3px 12px;
    clip-path: polygon(0 50%, 7px 0, 100% 0, 100% 100%, 7px 100%);
    background: linear-gradient(90deg, #dfae52 0 3px, rgba(8, 12, 26, .88) 3px);
    color: #f1f5ff;
    font-size: var(--tm-fs-2xs);
    line-height: 1.6;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.tm-card__body { display: block; padding: 9px 10px 11px; }
.tm-card__body h3 {
    font-family: var(--tm-sans);
    font-size: var(--tm-fs-base);
    font-weight: 600;
    line-height: 1.45;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    transition: color var(--tm-t) var(--tm-ease);
}
.tm-card:hover .tm-card__body h3 { color: var(--tm-gold); }
.tm-card__body p {
    margin-top: 4px;
    font-size: var(--tm-fs-xs);
    color: var(--tm-ink-3);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* --------------------------------------------------------------------------
   6. 行式条目（资讯 / 榜单 / 搜索结果共用）
   ⚠️ 多列布局要定义在**行内层**，不能定义在 ul/ol 上（li 会被依次塞进各列）
   -------------------------------------------------------------------------- */
.tm-vrow {
    display: grid;
    grid-template-columns: 46px minmax(0, 1fr);
    align-items: center;
    gap: 11px;
    padding: 9px 10px;
    border-radius: var(--tm-r-sm);
    transition: background var(--tm-t) var(--tm-ease);
}
.tm-vrow:hover { background: var(--tm-surface-2); }
.tm-vrow__pic {
    width: 46px;
    aspect-ratio: 2 / 3;
    border-radius: var(--tm-r-xs);
    overflow: hidden;
    background: var(--tm-surface-3);
}
.tm-vrow__pic img { width: 100%; height: 100%; object-fit: cover; }
.tm-vrow__copy { display: grid; gap: 3px; min-width: 0; }
.tm-vrow__copy b {
    font-size: var(--tm-fs-base);
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.tm-vrow__copy i {
    font-style: normal;
    font-size: var(--tm-fs-xs);
    color: var(--tm-ink-3);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 文字榜：序号 / 标题 / 右侧计数 三列 —— 三列定义在行内 <a> 上 */
.tm-rows { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1px; }
.tm-rows > li { min-width: 0; }
.tm-rows > li > a {
    display: grid;
    grid-template-columns: 22px minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    padding: 8px 8px;
    border-radius: var(--tm-r-sm);
    font-size: var(--tm-fs-base);
    min-width: 0;
    transition: background var(--tm-t) var(--tm-ease), color var(--tm-t) var(--tm-ease);
}
.tm-rows > li > a:hover { background: var(--tm-surface-2); color: var(--tm-accent); }
.tm-rows > li > a > span:nth-child(2) {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    min-width: 0;
}
.tm-rows > li > a em {
    font-style: normal;
    font-size: var(--tm-fs-xs);
    color: var(--tm-ink-3);
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}
/* 带缩略图的文字榜：序号 / 图 / 标题+副行 / 计数 */
.tm-rows--pic > li > a { grid-template-columns: 22px 42px minmax(0, 1fr) auto; }
.tm-rows--pic .pic {
    width: 42px;
    aspect-ratio: 2 / 3;
    border-radius: var(--tm-r-xs);
    overflow: hidden;
    background: var(--tm-surface-3);
}
.tm-rows--pic .pic img { width: 100%; height: 100%; object-fit: cover; }
.tm-rows--pic .tt { display: grid; gap: 2px; min-width: 0; }
.tm-rows--pic .tt b { font-size: var(--tm-fs-base); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tm-rows--pic .tt em { font-size: var(--tm-fs-xs); color: var(--tm-ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tm-rows > li > a.is-top .tm-num { color: var(--tm-accent); }

/* --------------------------------------------------------------------------
   7. 资料表（详情页 / 演员页共用）
   -------------------------------------------------------------------------- */
.tm-facts { display: grid; gap: 0; }
.tm-facts > div {
    display: grid;
    grid-template-columns: 58px minmax(0, 1fr);
    gap: 10px;
    padding: 7px 0;
    font-size: var(--tm-fs-sm);
    border-bottom: 1px dashed var(--tm-line);
}
.tm-facts > div:last-child { border-bottom: 0; }
.tm-facts dt { color: var(--tm-ink-3); }
.tm-facts dd { min-width: 0; overflow-wrap: anywhere; color: var(--tm-ink-2); }
.tm-facts dd a { border-bottom: 1px solid var(--tm-line-2); }
.tm-facts dd a:hover { color: var(--tm-accent); border-color: var(--tm-accent); }
.tm-facts--links dd { display: flex; flex-wrap: wrap; gap: 5px 10px; }
.tm-facts--links dd a { border-bottom: 0; }

/* 横排资料带（详情页顶卡底部）：dt:dd 成对横排、自动换行。
   ⚠️ 用横排带而不是竖排资料表，是为了让顶卡不必「三栏等高」——
      等高 + 某一栏内容短，必然在那一栏底部留一个洞（vela 实测 219px）。 */
.tm-facts--inline {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 22px;
}
.tm-facts--inline > div {
    display: flex;
    gap: 6px;
    min-width: 0;
    padding: 0;
    border: 0;
    font-size: var(--tm-fs-sm);
}
.tm-facts--inline dt { color: var(--tm-ink-3); flex: 0 0 auto; }
.tm-facts--inline dt::after { content: "："; }
.tm-facts--inline dd { color: var(--tm-ink-2); min-width: 0; overflow-wrap: anywhere; }

/* --------------------------------------------------------------------------
   8. 正文排版（资讯正文 / 详情页简介共用）
   宽度由调用方容器决定，本组件不设 max-width
   -------------------------------------------------------------------------- */
.tm-copy { color: var(--tm-ink-2); font-size: var(--tm-fs-md); line-height: 1.9; }
.tm-copy p { margin-bottom: 14px; }
.tm-copy p:last-child { margin-bottom: 0; }
.tm-copy h2, .tm-copy h3 {
    margin: 22px 0 10px;
    font-family: var(--tm-serif);
    color: var(--tm-ink);
}
.tm-copy h2 { font-size: var(--tm-fs-lg); }
.tm-copy h3 { font-size: var(--tm-fs-md); }
.tm-copy a { color: var(--tm-accent); border-bottom: 1px solid var(--tm-accent-soft-2); }
.tm-copy ul, .tm-copy ol { margin: 0 0 14px; padding-left: 22px; list-style: disc; }
.tm-copy ol { list-style: decimal; }
.tm-copy li { margin: 4px 0; }
.tm-copy img { border-radius: var(--tm-r-sm); margin: 14px auto; }
.tm-copy blockquote {
    margin: 0 0 14px;
    padding: 10px 14px;
    border-left: 3px solid var(--tm-accent);
    background: var(--tm-accent-soft);
    color: var(--tm-ink-2);
}
.tm-copy table { margin-bottom: 14px; font-size: var(--tm-fs-sm); }
.tm-copy th, .tm-copy td { padding: 7px 10px; border: 1px solid var(--tm-line); text-align: left; }
.tm-copy th { background: var(--tm-surface-2); font-weight: 600; }
.tm-copy strong { color: var(--tm-ink); }

/* --------------------------------------------------------------------------
   9. 面包屑 / 页头
   -------------------------------------------------------------------------- */
.tm-pagehead {
    padding: 12px 0;
    border-bottom: 1px solid var(--tm-line);
}
.tm-pagebar { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 14px; }
.tm-pagebar__side { margin-left: auto; }
.tm-pagebar__hint { font-size: var(--tm-fs-xs); color: var(--tm-ink-3); }
.tm-pagebar__hint b { color: var(--tm-ink-2); font-weight: 600; }
.tm-pagebar__hint i { font-style: normal; padding: 0 5px; opacity: .6; }

.tm-crumb { display: flex; align-items: center; flex-wrap: wrap; gap: 5px; font-size: var(--tm-fs-sm); color: var(--tm-ink-3); min-width: 0; }
.tm-crumb svg {
    width: 11px; height: 11px;
    fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round;
    opacity: .5;
    flex: 0 0 auto;
}
.tm-crumb a:hover { color: var(--tm-accent); }
.tm-crumb [aria-current="page"] {
    color: var(--tm-ink-2);
    max-width: 40vw;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* --------------------------------------------------------------------------
   10. 分页 / 空态
   -------------------------------------------------------------------------- */
.tm-pager { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 6px; margin-top: 22px; }
.tm-pager a, .tm-pager span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
    padding: 0 9px;
    border: 1px solid var(--tm-line-2);
    border-radius: var(--tm-r-sm);
    font-size: var(--tm-fs-sm);
    color: var(--tm-ink-2);
}
.tm-pager a:hover { border-color: var(--tm-accent); color: var(--tm-accent); }
.tm-pager .is-active { background: var(--tm-accent); border-color: var(--tm-accent); color: var(--tm-accent-ink); font-weight: 600; }
.tm-pager .is-disabled { color: var(--tm-ink-3); opacity: .6; }
.tm-pager__meta { border: 0 !important; color: var(--tm-ink-3); font-size: var(--tm-fs-xs); }

/* 结果统计条：由 widget/page 在列表之后输出（此时 $__PAGING__ 才有值）。
   左右分栏：左「共 N 条」右「第 x / y 页」，窄屏换行居中。 */
.tm-resultbar {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 8px 14px;
    flex-wrap: wrap;
    margin-top: 18px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--tm-line);
    font-size: var(--tm-fs-sm);
    color: var(--tm-ink-3);
}
.tm-resultbar b { color: var(--tm-ink); font-family: var(--tm-num); font-size: var(--tm-fs-md); }
@media (max-width: 560px) { .tm-resultbar { justify-content: center; } }

.tm-empty {
    padding: 40px 20px;
    text-align: center;
    background: var(--tm-surface);
    border: 1px solid var(--tm-line);
    border-radius: var(--tm-r-md);
}
.tm-empty h2 { font-size: var(--tm-fs-md); margin-bottom: 6px; }
.tm-empty p { font-size: var(--tm-fs-sm); color: var(--tm-ink-3); }

/* --------------------------------------------------------------------------
   11. 页脚 · 星空双层（顶部星河横带 + 马蹄铁徽章品牌区 + 频道胶囊带 + 三列）
   频道胶囊带仍承担「全站分类内链」的 SEO 职责（数据全量，不依赖顶栏白名单）。
   -------------------------------------------------------------------------- */
.tm-foot {
    margin-top: var(--tm-gap-block);
    padding: 0 0 30px;
    background: var(--tm-surface);
}
/* 星河横带：金 → 蓝 → 金渐变线 + 向下微光，替代普通 1px 顶边 */
.tm-foot__band {
    height: 3px;
    background: linear-gradient(90deg, transparent, #dfae52 18%, #8fb3ff 50%, #dfae52 82%, transparent);
    box-shadow: 0 0 18px rgba(143, 179, 255, .35);
}
.tm-foot__brand { display: flex; align-items: center; gap: 14px; padding: 20px 0 2px; }
/* 马蹄铁徽章：∩ 形金描边 + 双铆钉，内嵌「馬」字标 */
.tm-foot__crest {
    position: relative;
    display: grid;
    place-items: center;
    width: 54px; height: 46px;
    flex: 0 0 auto;
    font: 700 21px/1 var(--tm-serif);
    color: var(--tm-gold);
    border: 3px solid var(--tm-accent);
    border-bottom: 0;
    border-radius: 27px 27px 6px 6px;
    background:
        radial-gradient(circle at 50% 66%, rgba(223, 174, 82, .16), transparent 70%),
        var(--tm-surface-2);
    box-shadow: inset 0 0 0 1px rgba(223, 174, 82, .22), 0 6px 16px rgba(2, 4, 12, .5);
}
.tm-foot__crest::before,
.tm-foot__crest::after {
    content: "";
    position: absolute;
    bottom: -3px;
    width: 6px; height: 6px;
    border-radius: 50%;
    background: var(--tm-accent);
}
.tm-foot__crest::before { left: -3px; }
.tm-foot__crest::after { right: -3px; }
.tm-foot__slogan { display: grid; gap: 4px; }
.tm-foot__slogan strong { font-family: var(--tm-serif); font-size: var(--tm-fs-lg); line-height: 1.2; }
.tm-foot__slogan span { font-size: var(--tm-fs-xs); color: var(--tm-ink-3); letter-spacing: .1em; }

/* 频道胶囊带：全量一级分类，一行平铺、自动换行 */
.tm-foot__channels {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 16px 0 22px;
    padding: 14px;
    border: 1px solid var(--tm-line);
    border-radius: var(--tm-r-md);
    background: var(--tm-surface-2);
}
.tm-foot__channels a {
    padding: 3px 12px;
    border: 1px solid var(--tm-line-2);
    border-radius: 999px;
    background: var(--tm-surface);
    font-size: var(--tm-fs-xs);
    color: var(--tm-ink-2);
    transition: border-color var(--tm-t) var(--tm-ease), color var(--tm-t) var(--tm-ease);
}
.tm-foot__channels a:hover { border-color: var(--tm-accent); color: var(--tm-gold); }

.tm-foot__cols {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
}
@media (min-width: 720px)  { .tm-foot__cols { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .tm-foot__cols { grid-template-columns: 1.5fr repeat(2, minmax(0, 1fr)); } }
.tm-foot h3 { font-size: var(--tm-fs-base); margin-bottom: 9px; }
.tm-foot__links { display: flex; flex-wrap: wrap; gap: 6px 12px; }
.tm-foot__links a { font-size: var(--tm-fs-sm); color: var(--tm-ink-2); }
.tm-foot__links a:hover { color: var(--tm-gold); }
.tm-foot__links--stack { flex-direction: column; align-items: flex-start; gap: 7px; }
.tm-foot__links--stack span { font-size: var(--tm-fs-sm); color: var(--tm-ink-3); }
.tm-foot__about p { font-size: var(--tm-fs-sm); color: var(--tm-ink-3); line-height: 1.85; }
.tm-foot__bottom {
    margin-top: 22px;
    padding-top: 14px;
    border-top: 1px solid var(--tm-line);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 16px;
    font-size: var(--tm-fs-xs);
    color: var(--tm-ink-3);
}
.tm-foot__credit { margin-left: auto; }
.tm-foot__top {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 12px;
    border: 1px solid var(--tm-line-2);
    border-radius: 999px;
    color: var(--tm-ink-2);
    transition: border-color var(--tm-t) var(--tm-ease), color var(--tm-t) var(--tm-ease);
}
.tm-foot__top:hover { border-color: var(--tm-accent); color: var(--tm-gold); }
.tm-foot__top svg { width: 12px; height: 12px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; }

/* --------------------------------------------------------------------------
   12. 广告位 / 工具
   -------------------------------------------------------------------------- */
.tm-ad { display: block; margin: 0 auto; text-align: center; }
.tm-ad img { margin-inline: auto; }

.tm-clamp-1, .tm-clamp-2, .tm-clamp-3 { display: -webkit-box; -webkit-box-orient: vertical; overflow: hidden; }
.tm-clamp-1 { -webkit-line-clamp: 1; }
.tm-clamp-2 { -webkit-line-clamp: 2; }
.tm-clamp-3 { -webkit-line-clamp: 3; }
