:root {
    --bs-primary-rgb: 0, 82, 217;
    --bs-primary: var(--meow-primary);
    --bs-link-color-rgb: 0, 82, 217;
    --bs-link-hover-color-rgb: 0, 60, 171;
    --meow-primary: #0052d9;
    --meow-primary-dark: #003cab;
    --meow-primary-soft: #f2f3ff;
    --meow-primary-border: #b5c7ff;
    --meow-on-primary: #fff;
    --meow-ink: #252b36;
    --meow-muted: #778092;
    --meow-line: #e8ecf2;
    --meow-bg: #f5f7fa;
    --meow-card: #fff;
    --meow-placeholder: #eef2f8;
    --meow-placeholder-ink: #8793a8;
    --meow-radius: 12px;
    --meow-shadow: 0 8px 24px rgba(31, 48, 78, .05);
    --meow-header-height: 76px;
}
html { scroll-behavior: smooth; scroll-padding-top: 100px; }
body { color: var(--meow-ink); background: var(--meow-bg); font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif; font-size: 14px; line-height: 1.65; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--meow-primary); }
button, input, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 3px solid var(--meow-primary); outline-offset: 4px; }
::selection { color: var(--meow-primary-dark); background: var(--meow-primary-border); }
h1, h2, h3, p { overflow-wrap: anywhere; }
.site-container { width: 100%; max-width: 1440px; padding-right: 32px; padding-left: 32px; }
.min-w-0, .primary-column, .secondary-column { min-width: 0; }
.ui-icon { width: 20px; height: 20px; flex: 0 0 auto; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; vertical-align: middle; }
.icon-definitions { position: absolute; width: 0; height: 0; overflow: hidden; }
.skip-link { position: fixed; top: -100px; left: 20px; z-index: 1090; padding: 12px 18px; color: #fff; background: var(--meow-primary); border-radius: 8px; }
.skip-link:focus { top: 12px; color: #fff; }
.eyebrow { display: block; margin-bottom: 7px; color: var(--meow-primary); font-size: 12px; font-weight: 600; letter-spacing: 1px; }

/* 顶部承载全局操作，左侧保留稳定频道，主内容宽度不随显示器无限拉伸。 */
.site-header { background: #fff; border-bottom: 1px solid var(--meow-line); }
.site-header .navbar { min-height: var(--meow-header-height); padding: 12px 0; }
.brand { display: inline-flex; align-items: center; gap: 10px; margin-right: 0; color: var(--meow-ink); }
.brand:hover { color: var(--meow-ink); }
.brand-mark { display: grid; width: 40px; height: 40px; place-items: center; color: #fff; background: var(--meow-primary); border-radius: 13px 13px 13px 4px; font-size: 23px; font-weight: 700; }
.brand-copy { display: grid; gap: 2px; }
.brand-copy strong { font-size: 20px; line-height: 1.25; letter-spacing: 1px; }
.brand-copy small { color: var(--meow-muted); font-size: 10px; letter-spacing: 1px; }
.navbar-nav .nav-link { padding: 9px 16px !important; color: #626c66; font-size: 15px; font-weight: 600; border-radius: 8px; white-space: nowrap; }
.navbar-nav .nav-link.active, .navbar-nav .nav-link:hover { color: var(--meow-primary); background: var(--meow-primary-soft); }
.header-search { display: flex; width: min(380px, 100%); padding: 3px 4px 3px 12px; align-items: center; gap: 3px; background: #f5f7fa; border: 1px solid transparent; border-radius: 8px; }
.header-search > .ui-icon { width: 17px; height: 17px; color: #8a948d; }
.header-search:focus-within { background: #fff; border-color: var(--meow-primary-border); box-shadow: 0 0 0 3px rgba(0,82,217,.08); }
/* 搜索按钮不能参与压缩，中文按钮保持单行。 */
.header-search .form-control { flex: 1 1 0; width: auto; min-width: 0; min-height: 32px; padding: 5px 8px; background: transparent; border: 0; box-shadow: none; font-size: 13px; }
.header-search .btn { flex: 0 0 auto; min-width: 54px; padding: 5px 10px; color: var(--meow-primary-dark); background: var(--meow-primary-soft); border: 0; border-radius: 5px; font-size: 13px; white-space: nowrap; }
.header-search .btn:hover { background: #d9e1ff; }
.header-user-button { display: flex; max-width: 190px; padding: 3px 8px 3px 3px; align-items: center; gap: 8px; color: var(--meow-ink); background: transparent; border: 1px solid var(--meow-line); border-radius: 24px; font-size: 13px; }
.header-user-button > span:not(.avatar) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dropdown-menu { padding: 6px; border-color: var(--meow-line); border-radius: 10px; box-shadow: var(--meow-shadow); font-size: 14px; }
.dropdown-item { padding: 9px 12px; border-radius: 5px; }
.dropdown-item:active { background: var(--meow-primary); }
.btn { padding: 8px 18px; border-radius: 7px; font-size: 14px; font-weight: 500; white-space: nowrap; }
.btn-primary { --bs-btn-color: #fff; --bs-btn-bg: var(--meow-primary); --bs-btn-border-color: var(--meow-primary); --bs-btn-hover-color: #fff; --bs-btn-hover-bg: var(--meow-primary-dark); --bs-btn-hover-border-color: var(--meow-primary-dark); --bs-btn-active-color: #fff; --bs-btn-active-bg: var(--meow-primary-dark); --bs-btn-active-border-color: var(--meow-primary-dark); --bs-btn-disabled-bg: var(--meow-primary); --bs-btn-disabled-border-color: var(--meow-primary); --bs-btn-focus-shadow-rgb: 0,82,217; }
.btn-outline-primary { --bs-btn-color: var(--meow-primary); --bs-btn-border-color: var(--meow-primary-border); --bs-btn-hover-color: #fff; --bs-btn-hover-bg: var(--meow-primary); --bs-btn-hover-border-color: var(--meow-primary); --bs-btn-active-color: #fff; --bs-btn-active-bg: var(--meow-primary-dark); --bs-btn-active-border-color: var(--meow-primary-dark); --bs-btn-focus-shadow-rgb: 0,82,217; }
/* Bootstrap 原生表单与进度条也使用品牌色，避免仍显示组件默认蓝。 */
.form-check-input:checked { background-color: var(--meow-primary); border-color: var(--meow-primary); }
.form-check-input:focus { border-color: var(--meow-primary-border); box-shadow: 0 0 0 3px rgba(var(--bs-primary-rgb), .15); }
.progress { --bs-progress-bar-bg: var(--meow-primary); }
.form-control { font-size: 14px; border-color: #dde4ef; border-radius: 7px; }
.form-control::placeholder { color: #969d98; }
.form-control:focus { border-color: var(--meow-primary); box-shadow: 0 0 0 3px rgba(0,82,217,.1); }
.site-shell { display: grid; grid-template-columns: 174px minmax(0,1fr); gap: 28px; align-items: start; padding-top: 28px; padding-bottom: 48px; }
.site-main { min-width: 0; min-height: calc(100vh - 230px); }
.site-main:focus { outline: none; }
.site-sidebar { position: sticky; top: calc(var(--meow-header-height) + 24px); }
.sidebar-inner { max-height: calc(100vh - var(--meow-header-height) - 48px); overflow-y: auto; scrollbar-width: thin; padding: 8px 0; }
.sidebar-label { margin: 0 0 9px; padding: 0 14px; color: #929993; font-size: 11px; letter-spacing: 1px; }
.sidebar-nav { display: grid; gap: 5px; }
.sidebar-link { display: flex; width: 100%; min-height: 46px; padding: 10px 14px; gap: 12px; align-items: center; color: #5d6760; background: transparent; border: 0; border-radius: 8px; text-align: left; }
.sidebar-link.active { color: var(--meow-primary-dark); background: #d9e1ff; font-weight: 600; }
.sidebar-link:hover { color: var(--meow-primary); background: var(--meow-primary-soft); }
.sidebar-divider { height: 1px; margin: 22px 14px; background: var(--meow-line); }
.page-columns { display: grid; grid-template-columns: minmax(0,1fr) 274px; gap: 24px; align-items: start; }
.secondary-column { display: grid; gap: 18px; }
.sticky-sidebar { position: sticky; top: calc(var(--meow-header-height) + 24px); }
.site-footer { padding: 20px 0; color: #969d97; border-top: 1px solid var(--meow-line); font-size: 12px; }
.back-to-top { position: fixed; right: 16px; bottom: 24px; z-index: 1000; display: grid; width: 44px; padding: 9px 4px; gap: 4px; justify-items: center; color: #7e8a81; background: #fff; border: 1px solid var(--meow-line); border-radius: 8px; box-shadow: var(--meow-shadow); font-size: 10px; }
.content-card { background: var(--meow-card); border: 1px solid var(--meow-line); border-radius: var(--meow-radius); }
.content-stack { display: grid; overflow: hidden; background: var(--meow-card); border: 1px solid var(--meow-line); border-radius: var(--meow-radius); }
.page-heading { display: flex; margin-bottom: 24px; align-items: center; justify-content: space-between; gap: 20px; }
.page-heading h1, .search-hero h1 { margin: 0; font-size: 28px; font-weight: 700; line-height: 1.4; }
.page-heading p { margin: 9px 0 0; color: var(--meow-muted); font-size: 13px; }
.section-heading { display: flex; margin-bottom: 18px; align-items: center; justify-content: space-between; gap: 16px; }
.section-heading h1, .section-heading h2 { margin: 0; font-size: 18px; line-height: 1.5; font-weight: 650; }
.section-heading > a { flex: 0 0 auto; color: var(--meow-muted); font-size: 12px; }
.section-heading > a:hover { color: var(--meow-primary); }
.section-heading > span { color: #929992; font-size: 12px; }
.section-heading.compact { margin-bottom: 16px; }
.home-banner { overflow: hidden; height: 178px; margin-bottom: 20px; background: var(--meow-primary-soft); border-radius: 12px; }
.home-banner .carousel-inner, .home-banner .carousel-item, .home-banner a { display: block; height: 100%; }
.home-banner .carousel-item:not(.active):not(.carousel-item-next):not(.carousel-item-prev) { display: none; }
.home-banner img { height: 100%; object-fit: cover; }
.home-banner .carousel-item::after { position: absolute; inset: 0; content: ""; background: linear-gradient(90deg, rgba(17,33,63,.58), transparent 85%); pointer-events: none; }
.home-banner .carousel-caption { right: 56px; bottom: 24px; left: 40px; z-index: 1; padding: 0; text-align: left; }
.home-banner .carousel-caption span { font-size: 11px; letter-spacing: 2px; opacity: .85; }
.home-banner h2 { margin: 8px 0 0; font-size: 25px; line-height: 1.4; }
.home-banner .carousel-control-prev, .home-banner .carousel-control-next { width: 32px; }
.home-banner .carousel-control-prev-icon, .home-banner .carousel-control-next-icon { width: 16px; }
.feed-toolbar { padding: 20px 24px 18px; background: #fff; border: 1px solid var(--meow-line); border-radius: 12px 12px 0 0; }
.feed-section > .content-stack, .feed-section > .empty-state { border-top: 0; border-radius: 0 0 12px 12px; }
.filter-pills { display: flex; flex-wrap: wrap; gap: 6px; }
.filter-pill { padding: 5px 12px; color: #79837b; border: 1px solid transparent; border-radius: 6px; font-size: 13px; line-height: 1.7; }
.filter-pill:hover { color: var(--meow-primary); background: var(--meow-primary-soft); }
.filter-pill.active { color: var(--meow-primary-dark); background: var(--meow-primary-soft); font-weight: 600; }
/* 为右侧展开入口预留空间，展开内容仍在下方占满整行。 */
.category-filter { position: relative; }
.category-filter-expandable > .filter-pills { min-height: 34px; padding-right: 140px; }
.category-more { font-size: 12px; }
.category-more summary { position: absolute; top: 0; right: 0; width: fit-content; min-height: 34px; padding: 7px 0; color: var(--meow-primary); white-space: nowrap; cursor: pointer; }
.category-more summary small { margin-left: 8px; color: #929b94; font-size: 11px; }
.category-more > .filter-pills { max-height: 230px; margin-top: 12px; padding-top: 12px; overflow-y: auto; border-top: 1px solid var(--meow-line); scrollbar-width: thin; }
.category-more-close, .category-more[open] .category-more-open { display: none; }
.category-more[open] .category-more-close { display: inline; }
.side-card { padding: 22px 20px; }
.side-card h2 { margin: 0 0 14px; font-size: 16px; line-height: 1.5; font-weight: 650; }
.side-card .section-heading h2 { margin: 0; }
.side-card p { color: var(--meow-muted); font-size: 13px; line-height: 1.9; }
.hot-topic-list { display: grid; gap: 18px; }
.hot-topic-item { display: flex; min-width: 0; gap: 10px; align-items: center; }
.topic-rank { width: 12px; flex: 0 0 auto; color: #b3bab4; font-size: 13px; font-weight: 600; font-variant-numeric: tabular-nums; }
.hot-topic-item:nth-child(-n+3) .topic-rank { color: #c18853; }
.hot-topic-cover { position: relative; display: block; flex: 0 0 42px; width: 42px; height: 42px; overflow: hidden; background: var(--meow-placeholder); border-radius: 9px; }
.hot-topic-cover img, .hot-topic-fallback { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hot-topic-fallback { display: grid; place-items: center; color: var(--meow-placeholder-ink); background: var(--meow-placeholder); font-size: 17px; font-weight: 600; }
.hot-topic-fallback[hidden], .hot-topic-cover img[hidden] { display: none; }
.hot-topic-info { display: grid; min-width: 0; gap: 3px; }
.hot-topic-info strong { overflow: hidden; font-size: 13px; font-weight: 550; text-overflow: ellipsis; white-space: nowrap; }
.hot-topic-info small { color: #969d97; font-size: 10px; }
.side-empty { margin: 0; }
.community-note { padding: 4px 10px; }
.community-note h2 { font-size: 13px; color: #7a857c; }
.community-note p { color: #969e97; font-size: 12px; line-height: 1.9; }
.community-note a { color: var(--meow-primary); font-size: 12px; }

/* 信息流以作者、正文、媒体、反馈四层呈现，保持中文正文舒适行长。 */
.post-card { position: relative; border-bottom: 1px solid var(--meow-line); transition: background-color .18s ease; }
.content-stack > .post-card:last-child { border-bottom: 0; }
.post-card-link { cursor: pointer; }
.post-card-link:hover { background: #fdfdff; }
.post-card-link:focus-visible { outline-offset: -3px; }
.post-card-layout { display: grid; padding: 24px; gap: 12px; grid-template-columns: 40px minmax(0,1fr); }
.post-card-layout-no-avatar { grid-template-columns: minmax(0,1fr); }
.post-card-avatar, .post-card-avatar .avatar { width: 40px; height: 40px; }
.post-card-main { min-width: 0; }
.post-card-head { display: flex; min-height: 26px; align-items: center; justify-content: space-between; gap: 12px; }
.post-card-head time { flex: 0 0 auto; color: #a0a7a1; font-size: 11px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.avatar { display: grid; flex: 0 0 auto; width: 40px; height: 40px; place-items: center; object-fit: cover; border: 1px solid rgba(0,0,0,.035); border-radius: 50%; }
.avatar-lg { width: 48px; height: 48px; }
.header-avatar { width: 30px; height: 30px; }
.avatar-fallback { color: var(--meow-primary); background: var(--meow-primary-soft); font-size: 13px; }
.author-name { display: inline-block; min-width: 0; max-width: 100%; overflow: hidden; font-size: 13px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.post-author { display: flex; align-items: center; gap: 12px; }
.post-author > div { min-width: 0; }
.post-meta { display: flex; margin-top: 3px; flex-wrap: wrap; gap: 4px 12px; color: #929a94; font-size: 12px; }
.post-meta a { color: var(--meow-primary); }
.post-body-link { display: block; margin-top: 10px; }
.post-title { margin: 0 0 8px; font-size: 18px; font-weight: 650; line-height: 1.65; }
.post-content { display: -webkit-box; margin: 0; overflow: hidden; color: #646f66; font-size: 14px; line-height: 1.9; white-space: pre-wrap; -webkit-box-orient: vertical; -webkit-line-clamp: 3; }
.post-media-grid { display: grid; width: min(100%, 540px); margin-top: 16px; gap: 8px; grid-template-columns: repeat(3,minmax(0,1fr)); }
.post-media-grid.media-count-1 { max-width: 370px; grid-template-columns: minmax(0,1fr); }
.post-media-grid.media-count-2 { max-width: 450px; grid-template-columns: repeat(2,minmax(0,1fr)); }
.post-media-button { position: relative; display: block; overflow: hidden; padding: 0; background: var(--meow-placeholder); border: 0; border-radius: 8px; cursor: zoom-in; }
.post-media-button img { display: block; width: 100%; aspect-ratio: 4/3; object-fit: cover; transition: transform .2s ease; }
.post-media-grid.media-count-1 img { aspect-ratio: 16/10; }
.post-media-grid.media-count-2 img { aspect-ratio: 1.25; }
.post-media-button:hover img { transform: scale(1.025); }
.post-card-footer { display: grid; gap: 14px; margin-top: 16px; }
.post-card-topic, .post-stats { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 14px; }
.post-chip, .post-location-chip { display: inline-flex; max-width: 100%; padding: 3px 8px; color: #667a97; background: #f1f5fb; border-radius: 5px; font-size: 11px; overflow-wrap: anywhere; }
.post-chip-discuss { color: #6d8794; background: #f0f4f6; }
.post-stats { gap: 28px; color: #97a097; font-size: 12px; }
.post-stats > span, .post-stats > a { display: inline-flex; align-items: center; gap: 6px; }
.post-stats .ui-icon { width: 16px; height: 16px; }
.post-stats a:hover { color: var(--meow-primary); }
.inline-search { display: flex; width: min(330px,100%); gap: 8px; }
.inline-search .form-control { min-width: 0; }
.directory-heading { padding: 28px; background: #fff; border: 1px solid var(--meow-line); border-radius: 12px; }
.directory-filters { margin-bottom: 26px; padding: 18px 20px; background: #fff; border: 1px solid var(--meow-line); border-radius: 10px; }
.directory-filters .filter-pills { align-items: center; }
.filter-label { margin-right: 12px; color: #929992; font-size: 12px; }
.topic-grid { display: grid; gap: 16px; grid-template-columns: repeat(3,minmax(0,1fr)); }
.topic-card { display: grid; min-width: 0; padding: 22px; gap: 16px; grid-template-columns: 56px minmax(0,1fr); transition: border-color .18s, box-shadow .18s; }
.topic-card:hover { border-color: var(--meow-primary-border); box-shadow: var(--meow-shadow); }
.topic-cover-link { align-self: start; }
.topic-cover, .topic-cover-fallback { display: grid; flex: 0 0 auto; width: 56px; height: 56px; place-items: center; object-fit: cover; background: var(--meow-placeholder); border-radius: 10px; }
.topic-cover-fallback { color: var(--meow-placeholder-ink); font-size: 22px; font-weight: 600; }
.topic-card-body { min-width: 0; }
.topic-card h3 { margin: 0; font-size: 16px; line-height: 1.5; }
.topic-name { display: block; overflow: hidden; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.topic-card p { display: -webkit-box; min-height: 44px; margin: 8px 0 10px; overflow: hidden; color: var(--meow-muted); font-size: 12px; line-height: 1.8; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.topic-stats { display: flex; flex-wrap: wrap; gap: 6px 14px; color: #96a097; font-size: 11px; }
.topic-card-entry { display: flex; grid-column: 1/-1; padding-top: 12px; justify-content: space-between; color: var(--meow-primary); border-top: 1px solid var(--meow-line); font-size: 12px; }
.pagination { --bs-pagination-color: #6f7c72; --bs-pagination-active-bg: var(--meow-primary); --bs-pagination-active-border-color: var(--meow-primary); --bs-pagination-border-color: var(--meow-line); --bs-pagination-focus-box-shadow: 0 0 0 3px rgba(0,82,217,.1); gap: 6px; flex-wrap: wrap; }
.page-link { min-width: 36px; padding: 6px 11px; border-radius: 6px !important; font-size: 13px; text-align: center; }
.pagination-summary { margin: 12px 0 0; color: #929b94; font-size: 12px; text-align: center; }

/* 详情页、评论与响应式规则 */
.breadcrumb-nav { display: flex; flex-wrap: wrap; align-items: center; gap: 9px; margin-bottom: 20px; color: #97a097; font-size: 12px; }
.breadcrumb-nav > span:last-child { color: #616d64; }
.topic-hero { position: relative; overflow: hidden; margin-bottom: 24px; color: #fff; background: #163e7c; border-radius: 12px; }
.topic-hero-bg, .topic-hero-overlay { position: absolute; inset: 0; width: 100%; height: 100%; }
.topic-hero-bg { object-fit: cover; }
.topic-hero-overlay { background: linear-gradient(90deg,rgba(16,35,70,.86),rgba(20,57,110,.55)); }
.topic-hero-content { position: relative; display: flex; min-height: 204px; padding: 32px; align-items: center; gap: 24px; }
.topic-hero-cover { display: grid; flex: 0 0 88px; width: 88px; height: 88px; place-items: center; object-fit: cover; border: 3px solid rgba(255,255,255,.75); border-radius: 16px; }
.topic-hero-main { min-width: 0; flex: 1; }
.topic-hero h1 { margin: 0 0 10px; font-size: 30px; font-weight: 650; line-height: 1.5; }
.topic-hero-main > p { max-width: 620px; margin-bottom: 16px; color: #e1eaff; font-size: 13px; line-height: 1.9; }
.topic-hero-stats { display: flex; flex-wrap: wrap; gap: 16px; color: #c6d8ff; font-size: 12px; }
.topic-hero-stats strong { margin-right: 3px; color: #fff; font-size: 15px; }
.topic-notice { display: grid; gap: 8px; padding: 18px; color: #827553; background: #fbf8ed; border: 1px solid #f1ebd6; border-radius: 10px; }
.topic-notice strong { font-size: 13px; }
.topic-notice p { margin: 0; white-space: pre-wrap; font-size: 12px; line-height: 1.9; }
.pinned-card { padding: 4px 20px; }
.pinned-card a { display: flex; padding: 13px 0; align-items: center; gap: 10px; border-bottom: 1px solid var(--meow-line); }
.pinned-card a:last-child { border-bottom: 0; }
.pinned-card span { flex: 0 0 auto; padding: 1px 6px; color: #bf8061; background: #faf0e9; border-radius: 4px; font-size: 10px; }
.pinned-card strong { min-width: 0; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; font-weight: 500; }
.pinned-card i { color: var(--meow-muted); font-style: normal; }
.discuss-chip { display: inline-flex; max-width: 100%; padding: 4px 10px; color: var(--meow-primary); background: var(--meow-primary-soft); border-radius: 5px; font-size: 12px; overflow-wrap: anywhere; }
.discuss-row { display: flex; flex-wrap: wrap; gap: 8px; }
.discuss-hero { display: flex; padding: 28px; margin-bottom: 24px; align-items: center; gap: 20px; }
.discuss-symbol { display: grid; flex: 0 0 64px; width: 64px; height: 64px; place-items: center; color: var(--meow-primary); background: var(--meow-primary-soft); border-radius: 14px; font-size: 32px; font-weight: 600; }
.discuss-hero-main { min-width: 0; flex: 1; }
.discuss-hero h1 { margin: 0 0 10px; font-size: 26px; line-height: 1.6; font-weight: 650; }
.discuss-hero-main > p { margin-bottom: 14px; color: var(--meow-muted); font-size: 13px; }
.topic-mini-card { display: flex; min-width: 0; padding: 14px; align-items: center; gap: 10px; background: #f4f7fc; border-radius: 8px; }
.topic-mini-card img, .topic-mini-card .topic-cover-fallback { width: 42px; height: 42px; flex: 0 0 auto; object-fit: cover; border-radius: 8px; }
.topic-mini-card > span { display: grid; min-width: 0; flex: 1; gap: 4px; }
.topic-mini-card strong { overflow-wrap: anywhere; font-size: 13px; }
.topic-mini-card small { color: var(--meow-muted); font-size: 11px; }
.topic-mini-card i { color: var(--meow-primary); font-style: normal; }
.member-list { display: grid; gap: 12px; }
.member-list a { display: flex; min-width: 0; align-items: center; gap: 10px; }
.member-list .avatar { width: 32px; height: 32px; }
.member-list a > span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }
.login-note { padding: 14px; color: #8a958b; background: #f5f7fc; border-radius: 7px; font-size: 12px; line-height: 1.9; }
.post-detail-card { padding: 32px; }
.detail-title { margin: 26px 0 16px; font-size: 28px; font-weight: 650; line-height: 1.65; }
.post-detail-card > .discuss-chip { margin-top: 16px; }
.detail-content { margin-top: 22px; color: #46554a; font-size: 16px; line-height: 2; white-space: pre-wrap; overflow-wrap: anywhere; }
.detail-media-grid { display: grid; margin-top: 24px; gap: 8px; grid-template-columns: repeat(3,minmax(0,1fr)); }
.detail-media-grid.media-count-1 { grid-template-columns: minmax(0,1fr); }
.detail-media-grid.media-count-2 { grid-template-columns: repeat(2,minmax(0,1fr)); }
.detail-media-grid.media-count-1 img { max-height: 640px; aspect-ratio: auto; object-fit: contain; }
.location-chip { display: inline-block; margin-top: 18px; padding: 4px 8px; color: var(--meow-muted); background: #f5f7fc; border-radius: 5px; font-size: 12px; }
.detail-stats { display: flex; margin-top: 26px; padding-top: 18px; flex-wrap: wrap; align-items: center; gap: 10px 18px; color: #96a097; border-top: 1px solid var(--meow-line); font-size: 12px; }
.detail-stats strong { font-weight: 500; }
.copy-link-button { margin-left: auto; padding: 5px 10px; color: var(--meow-primary); background: var(--meow-primary-soft); border: 0; border-radius: 5px; }
.side-topic-head { display: flex; margin-bottom: 16px; align-items: center; gap: 12px; }
.side-topic-head img, .side-topic-head .topic-cover-fallback { width: 48px; height: 48px; flex: 0 0 auto; object-fit: cover; border-radius: 9px; }
.side-topic-head > div { min-width: 0; }
.side-topic-head h2 { margin: 0 0 4px; font-size: 15px; }
.side-topic-head span { color: var(--meow-muted); font-size: 11px; }
.author-profile { display: grid; justify-items: center; text-align: center; }
.author-profile .avatar { width: 56px; height: 56px; margin-bottom: 12px; }
.author-profile strong { font-size: 15px; overflow-wrap: anywhere; }
.author-profile p { margin-top: 6px; font-size: 12px; }

/* 评论保持原有登录、回复、点赞与删除钩子，仅调整阅读层级。 */
.comments-section { scroll-margin-top: 100px; }
.comment-list { overflow: hidden; }
.comment-composer { padding: 24px; }
.comment-composer-user { display: flex; margin-bottom: 16px; align-items: center; gap: 10px; }
.comment-composer-user > div { display: grid; gap: 3px; }
.comment-composer-user strong { font-size: 13px; }
.comment-composer-user span { color: var(--meow-muted); font-size: 11px; }
.comment-composer textarea { min-height: 110px; padding: 13px 15px; resize: vertical; background: #fafbfe; line-height: 1.8; }
.comment-composer-footer { display: flex; margin-top: 12px; align-items: center; justify-content: space-between; gap: 12px; }
.comment-composer-footer > span { color: var(--meow-muted); font-size: 12px; }
.reply-context { display: flex; margin-bottom: 10px; padding: 8px 11px; align-items: center; justify-content: space-between; color: var(--meow-primary); background: var(--meow-primary-soft); border-radius: 6px; font-size: 13px; }
.reply-context[hidden] { display: none; }
.reply-context button { padding: 0 4px; color: inherit; background: transparent; border: 0; font-size: 20px; line-height: 1; }
.comment-login-prompt { display: flex; padding: 24px; align-items: center; justify-content: space-between; gap: 18px; }
.comment-login-prompt > div { display: grid; gap: 6px; }
.comment-login-prompt strong { font-size: 14px; }
.comment-login-prompt span { color: var(--meow-muted); font-size: 12px; }
.comment-item { display: flex; padding: 24px; align-items: flex-start; gap: 12px; border-bottom: 1px solid var(--meow-line); }
.comment-item:last-child { border-bottom: 0; }
.comment-main { min-width: 0; flex: 1; }
.comment-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 10px; }
.comment-head strong { font-size: 13px; overflow-wrap: anywhere; }
.comment-head span { color: #9aa39c; font-size: 11px; }
.comment-main > p { margin: 8px 0 0; color: #536157; line-height: 1.9; white-space: pre-wrap; }
.comment-actions { display: flex; margin-top: 10px; align-items: center; gap: 16px; }
.comment-actions button { min-height: 28px; padding: 2px 0; color: #8d988f; background: transparent; border: 0; font-size: 12px; }
.comment-actions button:hover, .comment-actions button.active { color: var(--meow-primary); }
.comment-actions button.danger:hover { color: #be5151; }
.comment-actions button:disabled { opacity: .55; }
.comment-replies { margin-top: 12px; padding: 14px; background: #f5f7fc; border-radius: 8px; }
.comment-replies > .comment-reply + .comment-reply { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--meow-line); }
.comment-replies span { color: var(--meow-muted); font-size: 12px; }
.comment-replies p { margin: 6px 0 0; font-size: 13px; white-space: pre-wrap; }
.comment-reply-head { display: flex; align-items: center; flex-wrap: wrap; gap: 5px 9px; font-size: 12px; }
.comment-reply-head time { margin-left: auto; color: #9aa39c; font-size: 10px; }
.load-replies-button { margin-top: 10px; padding: 5px 0; color: var(--meow-primary); background: transparent; border: 0; font-size: 12px; }
.form-feedback { min-height: 20px; font-size: 12px; }
.form-feedback.error { color: #be5151; }
.form-feedback.success { color: #16876b; }
.toast { box-shadow: 0 10px 30px rgba(0,0,0,.12); }
.auth-modal-content { padding: 18px; border: 0; border-radius: 16px; box-shadow: 0 24px 70px rgba(19,35,67,.2); }
.auth-modal-content .modal-title { font-size: 25px; font-weight: 650; }
.auth-modal-content .form-control { min-height: 46px; }
.preview-modal-content { position: relative; padding: 12px; background: #17243b; border: 0; }
.preview-modal-content .btn-close { position: absolute; z-index: 2; top: 20px; right: 20px; padding: 9px; background-color: rgba(255,255,255,.2); border-radius: 50%; }
.preview-modal-image { max-width: 100%; max-height: 86vh; object-fit: contain; }

.user-cover { margin-bottom: 24px; padding: 36px 32px; background: linear-gradient(110deg,var(--meow-primary-soft),#f8faff); border: 1px solid var(--meow-primary-border); border-radius: 12px; }
.user-profile { display: flex; align-items: center; gap: 22px; }
.profile-avatar { display: grid; flex: 0 0 88px; width: 88px; height: 88px; place-items: center; object-fit: cover; border: 4px solid #fff; border-radius: 50%; font-size: 26px; }
.user-profile > div { min-width: 0; }
.user-profile h1 { margin: 0 0 8px; font-size: 28px; font-weight: 650; }
.user-profile p { margin: 0; color: #7b8ca5; font-size: 12px; }
.profile-stats { display: flex; margin-left: auto; gap: 28px; }
.profile-stats span { display: grid; gap: 2px; color: #7d8ba3; font-size: 12px; text-align: center; }
.profile-stats strong { color: #3e5f91; font-size: 25px; font-weight: 600; font-variant-numeric: tabular-nums; }
.search-hero { padding: 28px; background: #fff; border: 1px solid var(--meow-line); border-radius: 12px; }
.search-hero h1 { margin-bottom: 20px; font-size: 24px; }
.search-hero form { display: flex; gap: 10px; }
.search-hero .form-control { min-width: 0; min-height: 44px; background: #fafbfe; }
.search-tabs { display: flex; margin: 24px 0; gap: 20px; border-bottom: 1px solid var(--meow-line); }
.search-tabs a { padding: 11px 18px; color: #8d978e; font-weight: 500; border-bottom: 2px solid transparent; }
.search-tabs a.active { color: var(--meow-primary); border-color: var(--meow-primary); font-weight: 600; }
.user-result-grid { display: grid; gap: 14px; grid-template-columns: repeat(3,minmax(0,1fr)); }
.user-result { display: grid; min-width: 0; padding: 24px 16px; justify-items: center; gap: 10px; text-align: center; }
.user-result:hover { border-color: var(--meow-primary-border); }
.user-result .profile-avatar { width: 64px; height: 64px; }
.user-result strong { max-width: 100%; overflow-wrap: anywhere; font-size: 14px; }
.user-result span:last-child { color: var(--meow-muted); font-size: 12px; }
.search-results .topic-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
.empty-state, .error-state { padding: 60px 24px; text-align: center; }
.empty-state > .ui-icon { width: 40px; height: 40px; color: #a3b9db; stroke-width: 1.2; }
.empty-state > span { font-size: 36px; }
.empty-state h3 { margin: 18px 0 8px; font-size: 17px; font-weight: 600; }
.empty-state p { margin: 0; color: #97a096; font-size: 13px; }
.error-state { background: #fff; border: 1px solid var(--meow-line); border-radius: 12px; }
.error-state > span { display: block; color: #b5c7e6; font-size: 110px; font-weight: 600; line-height: 1.2; letter-spacing: 6px; }
.error-state h1 { margin-top: 16px; font-size: 25px; }
.error-state p { margin: 14px 0 24px; color: var(--meow-muted); }

/* 优先维持内容可读宽度：中屏先压缩侧栏，再在平板折叠辅助信息。 */
@media (max-width: 1279.98px) {
    .site-container { padding-right: 24px; padding-left: 24px; }
    .site-shell { grid-template-columns: 150px minmax(0,1fr); gap: 20px; }
    .page-columns { grid-template-columns: minmax(0,1fr) 240px; gap: 20px; }
    .sidebar-link { padding-right: 10px; padding-left: 10px; gap: 10px; }
    .side-card { padding: 20px 16px; }
    .hot-topic-list { gap: 16px; }
    .hot-topic-item { gap: 7px; }
    .hot-topic-cover { flex-basis: 36px; width: 36px; height: 36px; }
    .topic-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .post-card-layout { padding: 20px; grid-template-columns: 36px minmax(0,1fr); }
    .post-card-avatar, .post-card-avatar .avatar { width: 36px; height: 36px; }
    .post-detail-card { padding: 24px; }
}
@media (max-width: 1099.98px) and (min-width: 992px) {
    .site-shell { grid-template-columns: 136px minmax(0,1fr); gap: 16px; }
    .page-columns { grid-template-columns: minmax(0,1fr); }
    .home-layout > .secondary-column { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .secondary-column { position: static; }
    .header-search { width: 300px; }
}
@media (max-width: 991.98px) {
    :root { --meow-header-height: 68px; }
    .site-sidebar { display: none; }
    .site-shell { grid-template-columns: minmax(0,1fr); padding-top: 24px; }
    .page-columns { grid-template-columns: minmax(0,1fr); gap: 24px; }
    .secondary-column { position: static; grid-template-columns: repeat(2,minmax(0,1fr)); }
    .header-search { width: 100%; }
    .header-user-button { max-width: 100%; }
    .navbar-nav { padding-top: 18px; }
    .navbar-collapse { padding-bottom: 10px; }
    .brand-copy small { display: none; }
    .brand-mark { width: 36px; height: 36px; font-size: 20px; }
    .home-banner { height: 210px; }
    .topic-hero-content > .btn { display: none; }
    .sticky-sidebar { position: static; }
}
@media (max-width: 767.98px) {
    .site-container { padding-right: 16px; padding-left: 16px; }
    .site-shell { padding-top: 20px; padding-bottom: 32px; }
    .page-heading { align-items: flex-start; flex-direction: column; gap: 18px; }
    .page-heading h1 { font-size: 25px; }
    .directory-heading, .search-hero { padding: 22px; }
    .directory-filters { padding: 14px; }
    .inline-search { width: 100%; }
    .feed-toolbar { padding: 18px; }
    .category-filter-expandable > .filter-pills { padding-right: 0; }
    .category-more { margin-top: 10px; }
    .category-more summary { position: static; min-height: auto; padding: 2px 12px; }
    .secondary-column { grid-template-columns: minmax(0,1fr); }
    .home-banner { height: 176px; }
    .home-banner h2 { font-size: 21px; }
    .home-banner .carousel-caption { left: 32px; bottom: 24px; }
    .topic-hero-content { padding: 24px; gap: 16px; align-items: flex-start; }
    .topic-hero-cover { width: 64px; height: 64px; flex-basis: 64px; border-radius: 12px; }
    .topic-hero h1 { font-size: 24px; }
    .topic-hero-stats { gap: 8px 14px; }
    .post-card-layout { padding: 18px; gap: 10px; }
    .post-title { font-size: 17px; }
    .post-card-head { align-items: flex-start; flex-direction: column; gap: 0; }
    .post-card-head time { font-size: 10px; }
    .post-stats { gap: 24px; }
    .post-detail-card { padding: 24px; }
    .detail-title { font-size: 24px; }
    .detail-content { font-size: 15px; }
    .discuss-hero { padding: 24px; align-items: flex-start; gap: 14px; }
    .discuss-symbol { width: 48px; height: 48px; flex-basis: 48px; font-size: 25px; }
    .discuss-hero h1 { font-size: 23px; }
    .user-cover { padding: 28px 24px; }
    .user-profile { flex-wrap: wrap; gap: 18px; }
    .profile-avatar { width: 72px; height: 72px; flex-basis: 72px; }
    .user-profile h1 { font-size: 24px; }
    .profile-stats { width: 100%; margin: 6px 0 0; padding-top: 20px; justify-content: space-around; border-top: 1px solid var(--meow-primary-border); }
    .user-result-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .comment-item, .comment-composer, .comment-login-prompt { padding: 20px; }
    .back-to-top { right: 8px; bottom: 12px; width: 36px; opacity: .94; }
    .site-footer { padding-right: 30px; }
}
@media (max-width: 479.98px) {
    .site-container { padding-right: 12px; padding-left: 12px; }
    .topic-grid, .search-results .topic-grid { grid-template-columns: minmax(0,1fr); }
    .post-card-layout { grid-template-columns: 30px minmax(0,1fr); padding: 16px 14px; }
    .post-card-layout-no-avatar { grid-template-columns: minmax(0,1fr); }
    .post-card-avatar, .post-card-avatar .avatar { width: 30px; height: 30px; }
    .post-media-grid { gap: 5px; }
    .post-media-button { border-radius: 5px; }
    .post-content { font-size: 13px; }
    .post-detail-card { padding: 20px; }
    .detail-stats { gap: 10px 14px; }
    .detail-title { font-size: 22px; }
    .detail-media-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .comment-login-prompt { align-items: stretch; flex-direction: column; }
    .comment-item > .avatar { width: 30px; height: 30px; }
    .comment-item { padding: 18px 14px; gap: 10px; }
    .topic-hero-content { flex-wrap: wrap; }
    .topic-hero-main { flex-basis: calc(100% - 80px); }
    .search-hero form { gap: 6px; }
    .search-hero .btn { padding: 8px 12px; }
    .search-tabs { gap: 8px; }
    .search-tabs a { padding: 10px 16px; }
}
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}

.auth-tabs { gap: 4px; padding: 4px; background: var(--meow-primary-soft); border-radius: 14px; }
.auth-tabs .nav-link { color: var(--meow-muted); border-radius: 11px; }
.auth-tabs .nav-link.active { color: #fff; background: var(--meow-primary); }
.auth-agreement-check { display: flex; gap: 8px; align-items: flex-start; font-size: 13px; line-height: 1.7; }
.auth-agreement-check input { flex-shrink: 0; margin-top: 5px; }
.auth-agreement-check a { color: var(--meow-primary); text-decoration: underline; }
.auth-agreement-content { white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.9; }
.agreement-card { max-width: 980px; margin: 0 auto; padding: clamp(20px, 4vw, 44px); }
.agreement-navigation { display: flex; flex-wrap: wrap; gap: 12px 24px; margin: 24px 0; padding-bottom: 18px; border-bottom: 1px solid var(--meow-line); }
.agreement-navigation a { color: var(--meow-primary); }
.agreement-navigation [aria-current="page"] { font-weight: 600; text-decoration: underline; }
.agreement-content { overflow-wrap: anywhere; font-size: 15px; line-height: 1.95; }
.agreement-content h2 { margin: 32px 0 16px; font-size: 21px; }
.agreement-content h3 { margin: 24px 0 12px; font-size: 18px; }
.agreement-content p, .agreement-content li { margin-bottom: 14px; }
.agreement-content a { color: var(--meow-primary); text-decoration: underline; }
.auth-modal-content .js-send-code { min-width: 110px; }
