/* 标签页 biaoqian-{id}.html（biaoqian.php）：标签名 + 篇数，下面是一列文章，每篇为标题、标签和日期。
   Title and meta sit tight; a hairline and generous padding separate articles. The date keeps a right-hand column on
   desktop and leads the meta line on phones. Colours follow the legacy list pages (style.css), with muted text darkened to pass 4.5:1. */
.tag-page { --tag-red: #d6281c; --tag-ink: #23282f; --tag-muted: #697078; --tag-chip: #5f5f5f; --tag-chip-bg: #f3f3f3;
    --tag-line: #ededed; --tag-focus: #bf6e2e; box-sizing: border-box; padding: 0 18px 8px; color: var(--tag-ink); }
.tag-page *, .tag-page *::before, .tag-page *::after { box-sizing: border-box; }
.tag-page ::selection { background: var(--tag-red); color: #fff; }
.tag-page :focus-visible { outline: 2px solid var(--tag-focus); outline-offset: 3px; }

.tag-page-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 16px; padding: 32px 0 16px; border-bottom: 2px solid var(--tag-line); }
.tag-page-title { margin: 0; color: var(--tag-red); font-size: 24px; font-weight: 400; line-height: 1.4; overflow-wrap: anywhere; }
.tag-page-count { margin: 0; color: var(--tag-muted); font-size: 14px; line-height: 1.6; }

.tag-list, .tag-item-tags { margin: 0; padding: 0; list-style: none; }
.tag-item { padding: 20px 0; border-bottom: 1px solid var(--tag-line); }
.tag-item-title { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; margin: 0;
    font-size: 17px; font-weight: 400; line-height: 1.7; overflow-wrap: anywhere; }
.tag-item-title a { color: var(--tag-ink); text-decoration: none; transition: color .25s ease-out; }
.tag-item-title a:hover { color: var(--tag-red); }
.tag-item-title img { vertical-align: middle; }

.tag-item-meta { display: flex; align-items: flex-start; gap: 8px 24px; margin-top: 8px; }
.tag-item-tags { display: flex; flex-wrap: wrap; gap: 6px; min-width: 0; }
.tag-item-tags:not(:has(li)) { display: none; }
.tag-item-tags a { display: block; padding: 0 8px; background: var(--tag-chip-bg); color: var(--tag-chip); font-size: 12px; line-height: 24px; text-decoration: none; transition: background-color .2s ease-out, color .2s ease-out; }
.tag-item-tags a:hover { background: #e9e6e3; color: var(--tag-ink); }
.tag-item-tags a.is-current { background: var(--tag-red); color: #fff; }
.tag-item-date { flex: none; margin-left: auto; color: var(--tag-muted); font: 13px/24px Arial, Helvetica, sans-serif; font-variant-numeric: tabular-nums; }

.tag-page .list-pagination { padding: 32px 0 24px; }

@media (prefers-reduced-motion: reduce) { .tag-item-title a, .tag-item-tags a { transition: none; } }

@media (max-width: 767px) {
    .tag-page { padding: 0 14px 4px; }
    .tag-page-head { padding: 20px 0 12px; }
    .tag-page-title { font-size: 20px; }
    .tag-page-count { font-size: 13px; }
    .tag-item { padding: 16px 0; }
    .tag-item-title { display: block; overflow: visible; -webkit-line-clamp: none; font-size: 16px; line-height: 1.6; } /* full title on phones */
    .tag-item-meta { flex-direction: column; gap: 6px; }
    .tag-item-date { order: -1; margin-left: 0; line-height: 20px; }
    .tag-page .list-pagination { padding: 24px 0 16px; }
}
