/* ══════════════════════════════════════════════════════════════
   墨云阁 · 社区层样式
   ------------------------------------------------------------------
   沿用站点现有配色令牌（--ink-accent 朱红 / --bg-* / --text-* / --border-color），
   尺寸、间距、圆角、断点参照设计稿 SPEC。
   仅新增社区类，不改动已有博客组件。
   ══════════════════════════════════════════════════════════════ */

/* ── 视图切换 tabs ── */
.inkc-tabs {
    display: flex;
    align-items: center;
    gap: 4px;
    border-bottom: 1px solid var(--border-color, #e2e8f0);
    margin: 0 0 1.1rem;
    padding: 0 2px;
    overflow-x: auto;
    scrollbar-width: none;
}
.inkc-tabs::-webkit-scrollbar { display: none; }
.inkc-tab {
    position: relative;
    flex: 0 0 auto;
    padding: .62rem .95rem;
    border: 0;
    background: none;
    font-family: inherit;
    font-size: .95rem;
    color: var(--text-muted, #94a3b8);
    text-decoration: none;
    cursor: pointer;
    white-space: nowrap;
    transition: color .18s;
}
.inkc-tab b {
    font-weight: 400;
    font-variant-numeric: tabular-nums;
    font-size: .8rem;
    margin-left: .3rem;
    opacity: .8;
}
.inkc-tab:hover { color: var(--text-primary, #0f172a); }
.inkc-tab.on { color: var(--text-primary, #0f172a); font-weight: 600; }
.inkc-tab.on::after {
    content: "";
    position: absolute;
    left: .95rem;
    right: .95rem;
    bottom: -1px;
    height: 2px;
    background: var(--ink-accent, #c0392b);
    border-radius: 2px;
}
.inkc-tabs .inkc-tabs-tail {
    margin-left: auto;
    padding-right: .3rem;
    font-size: .8rem;
    color: var(--text-muted, #94a3b8);
    white-space: nowrap;
}
@media (max-width: 560px) {
    .inkc-tabs .inkc-tabs-tail { display: none; }
}

/* ── 社区统计条 ── */
.inkc-stats {
    display: flex;
    background: var(--bg-primary, #fff);
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 1rem;
}
.inkc-stat {
    flex: 1 1 0;
    text-align: center;
    padding: .8rem .4rem;
    border-left: 1px dashed var(--border-color, #e2e8f0);
}
.inkc-stat:first-child { border-left: 0; }
.inkc-stat b {
    display: block;
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--text-primary, #0f172a);
    font-variant-numeric: tabular-nums;
    line-height: 1.25;
}
.inkc-stat span { font-size: .75rem; color: var(--text-muted, #94a3b8); }
@media (max-width: 560px) {
    .inkc-stat b { font-size: 1rem; }
    .inkc-stat span { font-size: .68rem; }
}

/* ── 发布框 ── */
.inkc-composer {
    background: var(--bg-primary, #fff);
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 12px;
    padding: .7rem .85rem;
    margin-bottom: 1rem;
    transition: border-color .18s, box-shadow .18s;
}
.inkc-composer:focus-within {
    border-color: rgba(192, 57, 43, .45);
    box-shadow: 0 0 0 3px rgba(192, 57, 43, .08);
}
.inkc-composer > input {
    width: 100%;
    border: 0;
    background: none;
    font-family: inherit;
    font-size: .95rem;
    color: var(--text-primary, #0f172a);
    padding: .35rem .15rem;
    outline: none;
}
.inkc-composer > input::placeholder { color: var(--text-muted, #94a3b8); }
.inkc-composer .inkc-more { display: none; }
.inkc-composer.open .inkc-more { display: block; }
.inkc-composer.open > input { display: none; }
.inkc-composer textarea {
    width: 100%;
    min-height: 88px;
    resize: vertical;
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 10px;
    background: var(--bg-secondary, #f8fafc);
    font-family: inherit;
    font-size: .94rem;
    line-height: 1.8;
    color: var(--text-primary, #0f172a);
    padding: .7rem .8rem;
    outline: none;
}
.inkc-composer textarea:focus { border-color: rgba(192, 57, 43, .45); }
.inkc-composer-foot {
    display: flex;
    align-items: center;
    gap: .6rem;
    margin-top: .6rem;
    flex-wrap: wrap;
}
.inkc-composer-foot .inkc-hint {
    font-size: .78rem;
    color: var(--text-muted, #94a3b8);
}
.inkc-composer-foot .inkc-mini {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    border: 1px solid var(--border-color, #e2e8f0);
    background: none;
    border-radius: 999px;
    padding: .28rem .7rem;
    font-family: inherit;
    font-size: .8rem;
    color: var(--text-secondary, #475569);
    cursor: pointer;
    transition: all .18s;
}
.inkc-composer-foot .inkc-mini:hover {
    color: var(--ink-accent, #c0392b);
    border-color: rgba(192, 57, 43, .35);
}
.inkc-composer-foot .inkc-mini svg { width: 14px; height: 14px; }
.inkc-send {
    margin-left: auto;
    flex: 0 0 auto;
    border: 0;
    border-radius: 999px;
    background: var(--ink-accent, #c0392b);
    color: #fff;
    font-family: inherit;
    font-size: .88rem;
    font-weight: 600;
    padding: .5rem 1.15rem;
    cursor: pointer;
    transition: opacity .18s, transform .1s;
}
.inkc-send:hover { opacity: .9; }
.inkc-send:active { transform: translateY(1px); }
.inkc-send[disabled] { opacity: .5; cursor: default; }

/* ── 动态卡 ── */
.inkc-feed { display: flex; flex-direction: column; gap: .85rem; }
.inkc-entry {
    background: var(--bg-primary, #fff);
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 12px;
    padding: 1.05rem 1.15rem .8rem;
    transition: border-color .18s;
}
.inkc-entry:hover { border-color: rgba(192, 57, 43, .28); }
.inkc-entry-head { display: flex; align-items: center; gap: .6rem; }
.inkc-avatar {
    flex: 0 0 auto;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    color: #fff;
    font-size: .98rem;
    font-weight: 700;
    letter-spacing: .02em;
    user-select: none;
}
.inkc-avatar.is-sm { width: 34px; height: 34px; font-size: .86rem; }
.inkc-avatar.is-lg { width: 72px; height: 72px; font-size: 1.7rem; border-radius: 50%; }
.inkc-who { flex: 1 1 auto; min-width: 0; }
.inkc-name {
    display: block;
    font-size: .95rem;
    font-weight: 600;
    color: var(--text-primary, #0f172a);
    text-decoration: none;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.inkc-name:hover { color: var(--ink-accent, #c0392b); }
.inkc-when { display: block; font-size: .78rem; color: var(--text-muted, #94a3b8); margin-top: .1rem; }
.inkc-host {
    flex: 0 0 auto;
    font-size: .72rem;
    font-weight: 600;
    color: #fff;
    background: var(--text-primary, #16202b);
    border-radius: 999px;
    padding: .16rem .55rem;
    letter-spacing: .04em;
}
.inkc-body {
    margin: .7rem 0 0;
    font-size: .95rem;
    line-height: 1.85;
    color: var(--text-secondary, #475569);
    word-break: break-word;
}
.inkc-body .hash {
    color: var(--ink-accent, #c0392b);
    text-decoration: none;
    font-weight: 500;
}
.inkc-body .hash:hover { text-decoration: underline; }
.inkc-shots {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: .4rem;
    margin-top: .7rem;
    max-width: 460px;
}
.inkc-shots img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid var(--border-color, #e2e8f0);
    display: block;
}
.inkc-quoted {
    display: block;
    margin-top: .7rem;
    padding: .55rem .8rem;
    background: var(--bg-secondary, #f8fafc);
    border-left: 3px solid var(--text-primary, #16202b);
    border-radius: 0 8px 8px 0;
    text-decoration: none;
}
.inkc-quoted b { display: block; font-size: .88rem; color: var(--text-primary, #0f172a); font-weight: 600; }
.inkc-quoted span { display: block; font-size: .76rem; color: var(--text-muted, #94a3b8); margin-top: .2rem; }
.inkc-peek {
    margin: .7rem 0 0;
    padding: .55rem 0 0;
    border-top: 1px dashed var(--border-color, #e2e8f0);
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: .3rem;
}
.inkc-peek li { font-size: .85rem; line-height: 1.7; color: var(--text-secondary, #475569); }
.inkc-peek li .n { color: var(--text-primary, #0f172a); font-weight: 500; margin-right: .35rem; }
.inkc-peek-all {
    display: inline-block;
    margin-top: .35rem;
    font-size: .82rem;
    color: var(--ink-accent, #c0392b);
    text-decoration: none;
    font-weight: 500;
}
.inkc-peek-all:hover { text-decoration: underline; }
.inkc-act {
    display: flex;
    align-items: center;
    gap: 1.15rem;
    margin-top: .75rem;
    padding-top: .6rem;
    border-top: 1px solid var(--border-color, #e2e8f0);
}
.inkc-act button,
.inkc-act a {
    display: inline-flex;
    align-items: center;
    gap: .32rem;
    border: 0;
    background: none;
    padding: .2rem 0;
    font-family: inherit;
    font-size: .82rem;
    color: var(--text-muted, #94a3b8);
    cursor: pointer;
    text-decoration: none;
    font-variant-numeric: tabular-nums;
    transition: color .18s;
}
.inkc-act svg { width: 16px; height: 16px; }
.inkc-act button:hover,
.inkc-act a:hover { color: var(--ink-accent, #c0392b); }
.inkc-act .on { color: var(--ink-accent, #c0392b); }
.inkc-act .on svg { fill: rgba(192, 57, 43, .12); }
.inkc-act svg.push { animation: inkc-push .2s ease; }
@keyframes inkc-push {
    0% { transform: scale(1); }
    50% { transform: scale(1.14); }
    100% { transform: scale(1); }
}

/* ── 话题榜 ── */
.inkc-topics { display: flex; flex-direction: column; }
.inkc-topic-row {
    display: flex;
    align-items: center;
    gap: .5rem;
    padding: .45rem .1rem;
    border-radius: 8px;
    text-decoration: none;
    transition: background .16s;
}
.inkc-topic-row:hover { background: var(--bg-secondary, #f8fafc); }
.inkc-topic-row .rank {
    flex: 0 0 16px;
    font-size: .86rem;
    color: var(--text-muted, #94a3b8);
    font-variant-numeric: tabular-nums;
}
.inkc-topic-row .tname {
    flex: 1 1 auto;
    font-size: .88rem;
    color: var(--text-primary, #0f172a);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.inkc-topic-row:hover .tname { color: var(--ink-accent, #c0392b); }
.inkc-topic-row .tnum {
    flex: 0 0 auto;
    font-size: .76rem;
    color: var(--text-muted, #94a3b8);
    font-variant-numeric: tabular-nums;
}

/* ── 人物行 ── */
.inkc-who-row {
    display: flex;
    align-items: center;
    gap: .6rem;
    padding: .45rem 0;
}
.inkc-who-row .inkc-who { min-width: 0; }
.inkc-who-row .inkc-sub {
    display: block;
    font-size: .75rem;
    color: var(--text-muted, #94a3b8);
    margin-top: .1rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.inkc-follow {
    flex: 0 0 auto;
    border: 1px solid var(--border-color, #e2e8f0);
    background: none;
    border-radius: 999px;
    padding: .24rem .7rem;
    font-family: inherit;
    font-size: .78rem;
    color: var(--ink-accent, #c0392b);
    cursor: pointer;
    transition: all .18s;
}
.inkc-follow:hover { border-color: rgba(192, 57, 43, .4); }
.inkc-follow.on {
    color: var(--text-muted, #94a3b8);
    border-color: var(--border-color, #e2e8f0);
}

/* ── 新人竖排 ── */
.inkc-crew { display: flex; flex-direction: column; gap: .55rem; }
.inkc-crew-item { display: flex; align-items: center; gap: .55rem; text-decoration: none; }
.inkc-crew-item .n {
    flex: 1 1 auto;
    min-width: 0;
    font-size: .86rem;
    color: var(--text-primary, #0f172a);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.inkc-crew-item:hover .n { color: var(--ink-accent, #c0392b); }
.inkc-crew-item .w { flex: 0 0 auto; font-size: .72rem; color: var(--text-muted, #94a3b8); }

/* ── 话题页头 ── */
.inkc-topic-head {
    background: var(--bg-primary, #fff);
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 12px;
    padding: 1.25rem 1.35rem 1.1rem;
    margin-bottom: 1rem;
}
.inkc-topic-head h1 {
    margin: 0 0 .45rem;
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-primary, #0f172a);
    letter-spacing: .01em;
}
.inkc-topic-head h1::before { content: "#"; opacity: .35; margin-right: .08em; }
.inkc-topic-head h1::after { content: "#"; opacity: .35; margin-left: .08em; }
.inkc-topic-desc {
    font-size: .9rem;
    line-height: 1.8;
    color: var(--text-secondary, #475569);
    margin: 0 0 .8rem;
}
.inkc-topic-acts { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
.inkc-btn-line {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    border: 1px solid var(--border-color, #e2e8f0);
    background: none;
    border-radius: 999px;
    padding: .42rem 1rem;
    font-family: inherit;
    font-size: .86rem;
    color: var(--text-secondary, #475569);
    text-decoration: none;
    cursor: pointer;
    transition: all .18s;
}
.inkc-btn-line:hover { color: var(--ink-accent, #c0392b); border-color: rgba(192, 57, 43, .35); }
.inkc-btn-solid {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    border: 0;
    border-radius: 999px;
    background: var(--ink-accent, #c0392b);
    color: #fff;
    font-family: inherit;
    font-size: .86rem;
    font-weight: 600;
    padding: .45rem 1.1rem;
    text-decoration: none;
    cursor: pointer;
    transition: opacity .18s;
}
.inkc-btn-solid:hover { opacity: .9; }
.inkc-btn-solid.on {
    background: none;
    color: var(--text-muted, #94a3b8);
    border: 1px solid var(--border-color, #e2e8f0);
}

/* ── 回复区 ── */
.inkc-reply-box {
    display: flex;
    align-items: center;
    gap: .55rem;
    background: var(--bg-primary, #fff);
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 999px;
    padding: .35rem .45rem .35rem .5rem;
    margin-bottom: 1rem;
    transition: border-color .18s, box-shadow .18s;
}
.inkc-reply-box:focus-within {
    border-color: rgba(192, 57, 43, .45);
    box-shadow: 0 0 0 3px rgba(192, 57, 43, .08);
}
.inkc-reply-box input {
    flex: 1 1 auto;
    min-width: 0;
    border: 0;
    background: none;
    font-family: inherit;
    font-size: .92rem;
    color: var(--text-primary, #0f172a);
    outline: none;
    padding: .3rem .2rem;
}
.inkc-comments { display: flex; flex-direction: column; gap: 1.05rem; }
.inkc-comment { display: flex; gap: .6rem; }
.inkc-comment-b { flex: 1 1 auto; min-width: 0; }
.inkc-comment-b .nm { font-size: .9rem; font-weight: 600; color: var(--text-primary, #0f172a); text-decoration: none; }
.inkc-comment-b .nm:hover { color: var(--ink-accent, #c0392b); }
.inkc-comment-b .host-tag { font-size: .72rem; color: var(--ink-accent, #c0392b); margin-left: .35rem; }
.inkc-comment-b .wh { font-size: .76rem; color: var(--text-muted, #94a3b8); margin-left: .45rem; }
.inkc-comment-b p {
    margin: .3rem 0 .18rem;
    font-size: .92rem;
    line-height: 1.8;
    color: var(--text-secondary, #475569);
    word-break: break-word;
}
.inkc-comment-b .to { color: var(--ink-accent, #c0392b); }
.inkc-comment-b .rp {
    font-size: .78rem;
    color: var(--text-muted, #94a3b8);
    text-decoration: none;
    cursor: pointer;
}
.inkc-comment-b .rp:hover { color: var(--ink-accent, #c0392b); }

/* ── 个人主页 ── */
.inkc-profile {
    background: var(--bg-primary, #fff);
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 12px;
    padding: 1.35rem 1.4rem;
    margin-bottom: 1rem;
    display: flex;
    gap: 1.1rem;
    align-items: flex-start;
    flex-wrap: wrap;
}
.inkc-profile-main { flex: 1 1 260px; min-width: 0; }
.inkc-profile-name {
    margin: 0 0 .3rem;
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--text-primary, #0f172a);
}
.inkc-profile-bio {
    margin: 0 0 .6rem;
    font-size: .88rem;
    line-height: 1.8;
    color: var(--text-secondary, #475569);
}
.inkc-profile-stat {
    display: flex;
    gap: 1.2rem;
    flex-wrap: wrap;
    font-size: .8rem;
    color: var(--text-muted, #94a3b8);
}
.inkc-profile-stat b {
    font-size: 1rem;
    color: var(--text-primary, #0f172a);
    font-variant-numeric: tabular-nums;
    margin-right: .25rem;
}

/* ── 空状态 ── */
.inkc-empty {
    background: var(--bg-primary, #fff);
    border: 1px dashed var(--border-color, #cbd5e1);
    border-radius: 12px;
    padding: 2.2rem 1.2rem;
    text-align: center;
}
.inkc-empty b {
    display: block;
    font-size: 1rem;
    color: var(--text-primary, #0f172a);
    margin-bottom: .4rem;
}
.inkc-empty p {
    margin: 0 0 .9rem;
    font-size: .86rem;
    color: var(--text-muted, #94a3b8);
}

/* ── 分页 ── */
.inkc-pager {
    display: flex;
    gap: .4rem;
    justify-content: center;
    align-items: center;
    margin: 1.2rem 0 .2rem;
    flex-wrap: wrap;
}
.inkc-pager a,
.inkc-pager span {
    min-width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 .75rem;
    border-radius: 999px;
    border: 1px solid var(--border-color, #e2e8f0);
    font-size: .84rem;
    color: var(--text-secondary, #475569);
    text-decoration: none;
    transition: all .18s;
}
.inkc-pager a:hover { color: var(--ink-accent, #c0392b); border-color: rgba(192, 57, 43, .35); }
.inkc-pager .cur { background: var(--ink-accent, #c0392b); border-color: var(--ink-accent, #c0392b); color: #fff; }
.inkc-pager .off { opacity: .45; }

/* ── toast ── */
.inkc-toast {
    position: fixed;
    left: 50%;
    bottom: 28px;
    transform: translate(-50%, 12px);
    background: rgba(22, 32, 43, .94);
    color: #fff;
    font-size: .86rem;
    padding: .6rem 1.1rem;
    border-radius: 999px;
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s, transform .2s;
    z-index: 9999;
    max-width: 80vw;
    text-align: center;
}
.inkc-toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ── 侧栏挂件通用 ── */
.inkc-side-title {
    display: flex;
    align-items: center;
    gap: .5rem;
    font-size: .9rem;
    font-weight: 700;
    color: var(--text-primary, #0f172a);
    margin: 0 0 .7rem;
}
.inkc-side-title::before {
    content: "";
    width: 18px;
    height: 2px;
    background: var(--text-primary, #16202b);
    opacity: .7;
    border-radius: 2px;
}
.inkc-side-card {
    background: var(--bg-primary, #fff);
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 12px;
    padding: 1rem 1.1rem;
    margin-bottom: .9rem;
}
.inkc-side-note { font-size: .76rem; color: var(--text-muted, #94a3b8); margin: .5rem 0 0; line-height: 1.7; }

/* ── 面包屑 ── */
.inkc-crumb {
    display: flex;
    align-items: center;
    gap: .4rem;
    font-size: .8rem;
    color: var(--text-muted, #94a3b8);
    margin-bottom: .8rem;
    flex-wrap: wrap;
}
.inkc-crumb a { color: var(--text-muted, #94a3b8); text-decoration: none; }
.inkc-crumb a:hover { color: var(--ink-accent, #c0392b); }
.inkc-crumb .sep { opacity: .5; }

/* ── 移动端 ── */
@media (max-width: 768px) {
    .inkc-entry { padding: .95rem 1rem .7rem; }
    .inkc-topic-head { padding: 1.05rem 1.05rem .95rem; }
    .inkc-topic-head h1 { font-size: 1.28rem; }
    .inkc-profile { padding: 1.1rem; gap: .8rem; }
    .inkc-profile .inkc-avatar.is-lg { width: 58px; height: 58px; font-size: 1.35rem; }
    .inkc-shots { max-width: 100%; }
    .inkc-act { gap: .95rem; }
}
