/* ==========================================================================
   拾光吧 · core theme
   ========================================================================== */

:root {
    --bg: #f4f6fb;
    --bg-soft: #eef1f7;
    --surface: #ffffff;
    --surface-soft: #f8f9fd;
    --ink: #182033;
    --ink-2: #343e54;
    --muted: #778197;
    --muted-2: #9aa2b3;
    --line: #e7eaf2;
    --line-strong: #d9deea;
    --brand: #3157d5;
    --brand-dark: #2443a9;
    --brand-soft: #edf1ff;
    --accent: #f07a54;
    --green: #0f9f6e;
    --green-soft: #e9f8f1;
    --orange: #d97917;
    --orange-soft: #fff5e6;
    --red: #d94f4f;
    --red-soft: #fff0f0;
    --purple: #7c5ce5;
    --purple-soft: #f2efff;
    --radius-sm: 9px;
    --radius: 14px;
    --radius-lg: 20px;
    --radius-xl: 28px;
    --shadow-xs: 0 1px 2px rgba(24, 32, 51, .04);
    --shadow-sm: 0 4px 16px rgba(24, 32, 51, .05);
    --shadow-md: 0 16px 40px rgba(24, 32, 51, .09);
    --font: "Inter", "PingFang SC", "Microsoft YaHei UI", "Microsoft YaHei", "Noto Sans SC", sans-serif;
    --header-height: 72px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 96px; }
body {
    margin: 0;
    min-width: 320px;
    color: var(--ink);
    background: var(--bg);
    font-family: var(--font);
    font-size: 15px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}
body::before {
    content: "";
    position: fixed;
    z-index: -1;
    inset: 0;
    pointer-events: none;
    background:
        radial-gradient(circle at 8% 12%, rgba(79, 110, 247, .055), transparent 30%),
        radial-gradient(circle at 92% 26%, rgba(240, 122, 84, .04), transparent 25%);
}
h1, h2, h3, h4, p, ul, ol, dl, dd, figure { margin: 0; }
h1, h2, h3, h4 { color: var(--ink); font-weight: 700; line-height: 1.3; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
img, svg { display: block; }
::selection { background: #cdd8ff; color: var(--ink); }
:focus-visible { outline: 3px solid rgba(49, 87, 213, .3); outline-offset: 2px; }

.container { width: min(100% - 40px, 1200px); margin-inline: auto; }
.page-shell { width: min(100% - 40px, 1200px); margin-inline: auto; padding: 0 0 72px; }
.visually-hidden {
    position: absolute !important;
    width: 1px !important; height: 1px !important;
    padding: 0 !important; margin: -1px !important;
    overflow: hidden !important; clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important; border: 0 !important;
}
.skip-link {
    position: fixed; z-index: 500; top: 10px; left: 12px;
    padding: 10px 16px; border-radius: 8px;
    background: var(--ink); color: #fff;
    transform: translateY(-160%); transition: transform .2s;
}
.skip-link:focus { transform: translateY(0); }
.svg-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon {
    width: 1em; height: 1em; flex-shrink: 0;
    fill: none; stroke: currentColor; stroke-width: 1.8;
    stroke-linecap: round; stroke-linejoin: round;
    vertical-align: -.13em;
}

/* Buttons ----------------------------------------------------------------- */
.button {
    display: inline-flex; align-items: center; justify-content: center; gap: 7px;
    height: 40px; padding: 0 17px; border: 1px solid transparent;
    border-radius: 10px; background: transparent;
    font-size: 14px; font-weight: 650; line-height: 1; white-space: nowrap;
    transition: background .18s, color .18s, border-color .18s, transform .18s, box-shadow .18s;
}
.button:hover { transform: translateY(-1px); }
.button:active { transform: translateY(0); }
.button .icon { width: 16px; height: 16px; }
.button--primary {
    color: #fff; background: linear-gradient(135deg, #3d67e8, var(--brand));
    box-shadow: 0 5px 14px rgba(49, 87, 213, .2);
}
.button--primary:hover { background: linear-gradient(135deg, #3157d5, var(--brand-dark)); box-shadow: 0 7px 18px rgba(49, 87, 213, .26); }
.button--ghost { color: var(--ink-2); background: var(--surface); border-color: var(--line-strong); }
.button--ghost:hover { border-color: #bcc5da; background: #fbfcff; }
.button--secondary { color: var(--brand); background: var(--brand-soft); }
.button--secondary:hover { background: #e2e9ff; }
.button--light { color: var(--ink); background: #fff; border-color: rgba(255, 255, 255, .6); box-shadow: var(--shadow-sm); }
.button--light:hover { background: #f7f9ff; }
.button--danger { color: #fff; background: var(--red); box-shadow: 0 5px 14px rgba(217, 79, 79, .18); }
.button--danger:hover { background: #c63f3f; }
.button--on-color { color: #fff; background: color-mix(in srgb, var(--forum-color) 76%, #172033); }
.button--on-color:hover { filter: brightness(.96); }
.button--sm { height: 34px; padding: 0 12px; border-radius: 8px; font-size: 13px; }
.button--sm .icon { width: 14px; height: 14px; }
.button--lg { height: 48px; padding: 0 22px; border-radius: 12px; font-size: 15px; }
.button--full { width: 100%; }
.button--icon-only { width: 40px; padding: 0; }
.btn-badge, .mini-count {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 19px; height: 19px; padding: 0 5px;
    border-radius: 99px; font-size: 10.5px; font-weight: 800; line-height: 1;
}
.btn-badge { margin-left: 2px; color: #fff; background: rgba(255, 255, 255, .23); }
.mini-count { margin-left: auto; color: var(--brand); background: var(--brand-soft); }
.icon-button {
    display: inline-flex; align-items: center; justify-content: center;
    width: 38px; height: 38px; padding: 0;
    color: var(--ink-2); background: transparent; border: 1px solid transparent;
    border-radius: 9px;
}
.icon-button:hover { background: var(--bg-soft); }

/* Header ------------------------------------------------------------------ */
.site-header {
    position: sticky; top: 0; z-index: 100;
    background: rgba(255, 255, 255, .91);
    border-bottom: 1px solid rgba(226, 230, 240, .9);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}
.site-header__inner { min-height: var(--header-height); display: flex; align-items: center; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 11px; flex-shrink: 0; }
.brand__mark {
    display: inline-flex; align-items: center; justify-content: center;
    width: 39px; height: 39px; border-radius: 12px;
    color: #fff; background:
        radial-gradient(circle at 26% 18%, rgba(255, 255, 255, .28), transparent 42%),
        linear-gradient(145deg, #5076ed, #2345bd);
    box-shadow: 0 5px 13px rgba(49, 87, 213, .26);
    font-size: 19px; font-weight: 800; line-height: 1;
}
.brand__mark--small { width: 34px; height: 34px; border-radius: 10px; font-size: 16px; }
.brand__text { display: flex; flex-direction: column; line-height: 1.25; }
.brand__text strong { font-size: 18px; letter-spacing: .2px; }
.brand__text small { margin-top: 2px; color: var(--muted); font-size: 10px; letter-spacing: .7px; }
.primary-nav { display: flex; align-items: center; gap: 2px; }
.nav-link {
    position: relative; padding: 8px 12px; border-radius: 8px;
    color: var(--ink-2); font-size: 14px; font-weight: 550;
    transition: color .18s, background .18s;
}
.nav-link:hover { color: var(--brand); background: var(--brand-soft); }
.nav-link.is-active { color: var(--brand); font-weight: 700; }
.nav-link.is-active::after {
    content: ""; position: absolute; left: 50%; bottom: 1px;
    width: 14px; height: 2px; border-radius: 2px;
    background: var(--brand); transform: translateX(-50%);
}
.header-search {
    display: flex; align-items: center; gap: 9px;
    width: clamp(180px, 23vw, 286px); height: 38px;
    margin-left: auto; padding: 0 10px 0 13px;
    background: #f5f7fb; border: 1px solid #edf0f6; border-radius: 10px;
    color: var(--muted); transition: border-color .18s, background .18s, box-shadow .18s;
}
.header-search:focus-within { background: #fff; border-color: #b9c8f6; box-shadow: 0 0 0 3px rgba(49, 87, 213, .07); }
.header-search .icon { width: 16px; height: 16px; flex-shrink: 0; }
.header-search input { width: 100%; min-width: 0; border: 0; outline: 0; background: transparent; font-size: 13px; }
.header-search kbd {
    padding: 1px 5px; border: 1px solid var(--line); border-radius: 4px;
    color: var(--muted-2); background: #fff; font-size: 10px; font-family: inherit;
}
.header-actions { display: flex; align-items: center; gap: 9px; flex-shrink: 0; }
.header-write { gap: 6px; }
.header-admin {
    position: relative; display: inline-flex; align-items: center; justify-content: center;
    width: 35px; height: 35px; color: var(--brand);
    border-radius: 9px; background: var(--brand-soft);
}
.header-admin:hover { background: #e1e8ff; }
.header-admin .icon { width: 17px; height: 17px; }
.header-admin__dot {
    position: absolute; top: -4px; right: -4px;
    min-width: 16px; height: 16px; padding: 0 4px;
    color: #fff; background: var(--accent);
    border: 2px solid #fff; border-radius: 99px;
    font-size: 8px; font-weight: 800; line-height: 12px; text-align: center;
}
.login-link { padding: 8px 10px; }
.user-menu { position: relative; }
.user-trigger {
    display: flex; align-items: center; gap: 8px;
    height: 38px; padding: 3px 7px 3px 4px;
    border: 1px solid transparent; border-radius: 10px; background: transparent;
}
.user-trigger:hover, .user-menu.is-open .user-trigger { background: var(--surface-soft); border-color: var(--line); }
.user-trigger__name { max-width: 82px; overflow: hidden; text-overflow: ellipsis; font-size: 13px; font-weight: 600; white-space: nowrap; }
.user-trigger__chevron { width: 13px; height: 13px; color: var(--muted); transition: transform .18s; }
.user-menu.is-open .user-trigger__chevron { transform: rotate(180deg); }
.dropdown-panel {
    position: absolute; top: calc(100% + 9px); right: 0; z-index: 120;
    width: 230px; padding: 8px;
    background: #fff; border: 1px solid var(--line); border-radius: 14px;
    box-shadow: var(--shadow-md);
    opacity: 0; visibility: hidden; transform: translateY(-5px) scale(.98);
    transform-origin: top right;
    transition: opacity .16s, visibility .16s, transform .16s;
}
.user-menu.is-open .dropdown-panel { opacity: 1; visibility: visible; transform: translateY(0) scale(1); }
.dropdown-profile { display: flex; align-items: center; gap: 10px; padding: 9px 8px 11px; }
.dropdown-profile > div { min-width: 0; display: flex; flex-direction: column; }
.dropdown-profile strong { font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dropdown-profile span { color: var(--muted); font-size: 11.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dropdown-divider { height: 1px; margin: 4px 2px; background: var(--line); }
.dropdown-link {
    display: flex; align-items: center; gap: 9px; width: 100%;
    padding: 9px 9px; border: 0; border-radius: 8px;
    color: var(--ink-2); background: transparent; text-align: left; font-size: 13px;
}
.dropdown-link .icon { width: 15px; height: 15px; color: var(--muted); }
.dropdown-link:hover { color: var(--brand); background: var(--brand-soft); }
.dropdown-link:hover .icon { color: var(--brand); }
.dropdown-link--danger { color: var(--red); }
.dropdown-link--danger .icon { color: var(--red); }
.dropdown-link--danger:hover { color: #b93838; background: var(--red-soft); }
.dropdown-panel form { margin: 0; }
.mobile-toggle { display: none; }
.mobile-panel { display: none; }

/* Avatars ----------------------------------------------------------------- */
.avatar {
    display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0;
    width: 34px; height: 34px; border-radius: 11px;
    color: #fff; background:
        radial-gradient(circle at 30% 20%, rgba(255, 255, 255, .25), transparent 45%),
        var(--avatar-color, #4f6ef7);
    font-size: 14px; font-weight: 750; line-height: 1;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .15);
    user-select: none;
}
.avatar--xs { width: 24px; height: 24px; border-radius: 8px; font-size: 10.5px; }
.avatar--sm { width: 30px; height: 30px; border-radius: 9px; font-size: 12px; }
.avatar--md { width: 38px; height: 38px; border-radius: 12px; font-size: 15px; }
.avatar--lg { width: 58px; height: 58px; border-radius: 17px; font-size: 23px; }
.avatar--xl { width: 96px; height: 96px; border-radius: 26px; font-size: 37px; box-shadow: 0 8px 24px rgba(24, 32, 51, .16), inset 0 0 0 4px rgba(255, 255, 255, .9); }
.avatar-stack { display: inline-flex; padding-left: 7px; }
.avatar-stack .avatar { margin-left: -7px; border: 2px solid #fff; box-sizing: content-box; }
.avatar-stack--on-card .avatar { border-color: #f6f8fd; }
.badge-owner, .badge-admin, .badge-self, .badge-banned, .badge-lz {
    display: inline-flex; align-items: center; gap: 3px;
    height: 19px; padding: 0 6px; border-radius: 5px;
    font-size: 10px; font-weight: 700; line-height: 1.5; white-space: nowrap; vertical-align: 1px;
}
.badge-owner { color: #a55c00; background: #fff2d8; }
.badge-owner .icon { width: 10px; height: 10px; }
.badge-admin { color: var(--brand); background: var(--brand-soft); border: 1px solid #dce5ff; }
.badge-admin .icon { width: 11px; height: 11px; }
.badge-self { color: var(--green); background: var(--green-soft); }
.badge-banned { color: var(--red); background: var(--red-soft); }
.badge-lz { color: var(--brand); background: #eaf0ff; }
.tag {
    display: inline-flex; align-items: center; gap: 3px;
    height: 21px; padding: 0 7px; border-radius: 5px;
    font-size: 10.5px; font-weight: 650; white-space: nowrap;
}
.tag .icon { width: 11px; height: 11px; }
.tag--pin { color: #b06b05; background: #fff4df; }
.tag--featured { color: var(--purple); background: var(--purple-soft); }
.tag--locked { color: var(--muted); background: var(--bg-soft); }

/* Flash ------------------------------------------------------------------- */
.flash-stack {
    position: fixed; z-index: 300; top: 86px; right: max(20px, calc((100vw - 1200px) / 2));
    display: flex; flex-direction: column; gap: 9px; width: min(390px, calc(100vw - 40px));
}
.flash {
    display: flex; align-items: flex-start; gap: 10px;
    padding: 12px 12px 12px 13px;
    background: rgba(255, 255, 255, .98); border: 1px solid var(--line);
    border-radius: 12px; box-shadow: var(--shadow-md);
    animation: flashIn .26s ease-out both;
}
.flash.is-leaving { animation: flashOut .2s ease-in both; }
.flash__icon { display: flex; color: var(--muted); }
.flash__icon .icon { width: 18px; height: 18px; margin-top: 1px; }
.flash--success .flash__icon { color: var(--green); }
.flash--error .flash__icon { color: var(--red); }
.flash--info .flash__icon { color: var(--brand); }
.flash__message { flex: 1; color: var(--ink-2); font-size: 13px; line-height: 1.55; }
.flash__close { display: flex; padding: 4px; color: var(--muted-2); background: none; border: 0; border-radius: 5px; }
.flash__close:hover { color: var(--ink); background: var(--bg-soft); }
.flash__close .icon { width: 13px; height: 13px; }
@keyframes flashIn { from { opacity: 0; transform: translateY(-8px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes flashOut { to { opacity: 0; transform: translateY(-5px); } }

/* Forms ------------------------------------------------------------------- */
.field { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.field__label { color: var(--ink-2); font-size: 13px; font-weight: 650; }
.field__label small { margin-left: 4px; color: var(--muted); font-size: 11px; font-weight: 400; }
.field__control {
    display: flex; align-items: center; gap: 9px;
    min-height: 44px; padding: 0 13px;
    background: #fbfcfe; border: 1px solid var(--line-strong); border-radius: 10px;
    transition: border-color .18s, box-shadow .18s, background .18s;
}
.field__control:focus-within { background: #fff; border-color: #a9bcf8; box-shadow: 0 0 0 3px rgba(49, 87, 213, .08); }
.field__control > .icon { width: 16px; height: 16px; color: var(--muted); flex-shrink: 0; }
.field__control input { width: 100%; min-width: 0; border: 0; outline: 0; background: transparent; font-size: 14px; }
.field__control input:disabled { color: var(--muted); cursor: not-allowed; }
.field__reveal {
    display: inline-flex; padding: 5px; color: var(--muted-2);
    border: 0; border-radius: 5px; background: transparent;
}
.field__reveal:hover { color: var(--ink); background: var(--bg-soft); }
.field__reveal .icon { width: 16px; height: 16px; }
.input, textarea, .admin-select {
    width: 100%; padding: 10px 13px;
    background: #fbfcfe; border: 1px solid var(--line-strong); border-radius: 10px;
    outline: 0; font-size: 14px; resize: vertical;
    transition: border-color .18s, box-shadow .18s, background .18s;
}
.input { height: 44px; }
.input:focus, textarea:focus, .admin-select:focus { background: #fff; border-color: #a9bcf8; box-shadow: 0 0 0 3px rgba(49, 87, 213, .08); }
textarea { min-height: 92px; line-height: 1.7; }
input::placeholder, textarea::placeholder { color: var(--muted-2); }
.form-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.form-row--four { grid-template-columns: 1.15fr 1fr .65fr .55fr; }
.select-wrap { position: relative; max-width: 340px; }
.select-wrap select {
    appearance: none; width: 100%; height: 44px; padding: 0 38px 0 13px;
    background: #fbfcfe; border: 1px solid var(--line-strong); border-radius: 10px; outline: 0;
    font-size: 14px;
}
.select-wrap .icon { position: absolute; top: 50%; right: 13px; width: 15px; height: 15px; color: var(--muted); transform: translateY(-50%); pointer-events: none; }
.input-counter, .textarea-wrap { position: relative; }
.input-counter .input { padding-right: 70px; }
.input-counter > span { position: absolute; top: 50%; right: 13px; color: var(--muted-2); font-size: 11px; transform: translateY(-50%); }
.textarea-wrap textarea { padding-bottom: 32px; }
.textarea-counter { position: absolute; right: 13px; bottom: 10px; color: var(--muted-2); font-size: 11px; }
.input-counter b, .textarea-counter b { color: var(--muted); font-weight: 600; }
.check-field { display: inline-flex; align-items: center; gap: 8px; color: var(--ink-2); font-size: 13px; cursor: pointer; }
.check-field input { width: 16px; height: 16px; accent-color: var(--brand); }
.field--inline { flex-direction: row; align-items: center; gap: 9px; }

/* Breadcrumb & notices ---------------------------------------------------- */
.breadcrumb {
    display: flex; align-items: center; flex-wrap: wrap; gap: 7px;
    padding: 21px 2px 17px; color: var(--muted); font-size: 12.5px;
}
.breadcrumb a { display: inline-flex; align-items: center; gap: 4px; color: var(--ink-2); }
.breadcrumb a:hover { color: var(--brand); }
.breadcrumb .icon { width: 13px; height: 13px; }
.breadcrumb__current { color: var(--muted-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 280px; }
.notice {
    display: flex; align-items: flex-start; gap: 12px;
    padding: 15px 17px; margin: 0 0 20px;
    border: 1px solid var(--line); border-radius: 12px; background: var(--surface); font-size: 13px;
}
.notice > .icon { width: 19px; height: 19px; margin-top: 1px; flex-shrink: 0; }
.notice strong { color: var(--ink-2); font-size: 13.5px; }
.notice p { margin-top: 2px; color: var(--muted); font-size: 12.5px; }
.notice--warning { background: #fffbf0; border-color: #f4e4b9; color: var(--orange); }
.notice--locked { background: #f8f9fc; border-color: var(--line); color: var(--muted); }
.notice--warning strong, .notice--locked strong { color: var(--ink-2); }

/* Hero -------------------------------------------------------------------- */
.hero {
    position: relative; display: grid; grid-template-columns: minmax(0, 1.04fr) minmax(0, .96fr);
    min-height: 418px; margin: 26px 0 20px; padding: 50px 52px;
    overflow: hidden; border: 1px solid #e4e9f7; border-radius: var(--radius-xl);
    background:
        radial-gradient(circle at 90% 12%, rgba(76, 115, 235, .12), transparent 36%),
        radial-gradient(circle at 4% 100%, rgba(240, 122, 84, .08), transparent 32%),
        linear-gradient(135deg, #fdfefe 0%, #f6f8ff 58%, #f3f6ff 100%);
    box-shadow: 0 10px 35px rgba(40, 55, 100, .04);
}
.hero::after {
    content: ""; position: absolute; inset: 0; pointer-events: none;
    background-image: radial-gradient(rgba(49, 87, 213, .12) .7px, transparent .7px);
    background-size: 18px 18px;
    -webkit-mask-image: linear-gradient(90deg, transparent 45%, #000 100%);
    mask-image: linear-gradient(90deg, transparent 45%, #000 100%);
    opacity: .5;
}
.hero__copy { position: relative; z-index: 2; align-self: center; }
.eyebrow {
    display: flex; align-items: center; gap: 8px;
    color: var(--brand); font-size: 11px; font-weight: 750;
    letter-spacing: 1.6px; text-transform: uppercase;
}
.eyebrow > span { width: 22px; height: 1.5px; background: var(--brand); opacity: .65; }
.eyebrow--small { font-size: 9.5px; letter-spacing: 1.4px; color: var(--muted-2); }
.eyebrow--small > span { display: none; }
.hero h1 {
    margin-top: 18px;
    font-size: clamp(38px, 4.4vw, 57px);
    line-height: 1.18; letter-spacing: -2px;
}
.accent-text {
    background: linear-gradient(105deg, #2f63e8, #1aa3a5);
    -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero__lead { max-width: 490px; margin-top: 18px; color: var(--muted); font-size: 15px; line-height: 1.8; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.hero__actions .button--ghost { border-color: #dbe2f2; background: rgba(255, 255, 255, .7); }
.hero__trust { display: flex; align-items: center; gap: 12px; margin-top: 27px; color: var(--muted); font-size: 11.5px; }
.hero__trust p { max-width: 330px; }
.hero__trust strong { color: var(--ink-2); font-weight: 700; }
.hero__stage { position: relative; z-index: 2; min-height: 320px; }
.hero-blob { position: absolute; border-radius: 50%; filter: blur(2px); }
.hero-blob--one { width: 250px; height: 250px; right: -50px; top: -50px; background: rgba(75, 112, 234, .11); }
.hero-blob--two { width: 180px; height: 180px; left: 8%; bottom: -90px; background: rgba(240, 122, 84, .1); }
.hero-thread {
    position: absolute; z-index: 2; top: 48px; left: 7%; width: 89%;
    padding: 21px 23px 18px;
    background: rgba(255, 255, 255, .95);
    border: 1px solid rgba(224, 231, 248, .95); border-radius: 17px;
    box-shadow: 0 22px 55px rgba(32, 53, 112, .12);
    transform: rotate(-1.4deg);
}
.hero-thread__top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.hero-thread__forum {
    display: inline-flex; align-items: center; gap: 5px;
    padding: 4px 8px; color: var(--brand); background: var(--brand-soft);
    border-radius: 6px; font-size: 10.5px; font-weight: 650;
}
.hero-thread__forum i { font-style: normal; }
.hero-thread__time { color: var(--muted-2); font-size: 10px; }
.hero-thread h3 { margin-top: 12px; font-size: 17px; line-height: 1.45; }
.hero-thread > p { margin-top: 7px; color: var(--muted); font-size: 12px; line-height: 1.7; }
.hero-thread__meta { display: flex; align-items: center; gap: 10px; margin-top: 15px; padding-top: 13px; border-top: 1px solid #eef1f8; color: var(--muted); font-size: 10.5px; }
.hero-thread__likes { margin-left: auto; color: #d56a70; }
.hero-float {
    position: absolute; z-index: 3; display: flex; align-items: center; gap: 9px;
    padding: 10px 13px; background: rgba(255, 255, 255, .96);
    border: 1px solid #e8ecf7; border-radius: 12px; box-shadow: 0 10px 30px rgba(32, 53, 112, .11);
    font-size: 11.5px; animation: floatCard 6s ease-in-out infinite;
}
.hero-float > span:first-child { font-size: 18px; }
.hero-float > div { display: flex; flex-direction: column; gap: 1px; }
.hero-float strong { font-size: 11.5px; }
.hero-float small { color: var(--muted); font-size: 9.5px; }
.hero-float--forum { top: 6px; right: -2%; animation-delay: -.8s; }
.hero-float--topic { right: 0; bottom: 14px; animation-delay: -2.4s; }
.hero-float--people { left: 0; bottom: 42px; padding: 9px 13px; border-radius: 99px; animation-delay: -4s; }
.hero-float--people strong { font-size: 10.5px; color: var(--ink-2); }
.mini-pulse, .live-dot {
    width: 7px; height: 7px; border-radius: 50%; background: #24b47e;
    box-shadow: 0 0 0 4px rgba(36, 180, 126, .12);
}
@keyframes floatCard { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-7px); } }

/* Announcement & categories ---------------------------------------------- */
.announcement-bar {
    display: flex; align-items: center; gap: 12px;
    min-height: 43px; margin-top: 22px; padding: 8px 13px;
    background: #f1f8f5; border: 1px solid #dcefe5; border-radius: 11px;
    color: #326a52; font-size: 12.5px;
}
.announcement-bar__label {
    display: inline-flex; align-items: center; gap: 4px; flex-shrink: 0;
    padding-right: 11px; border-right: 1px solid #cfe5d9;
    font-weight: 700; font-size: 11px;
}
.announcement-bar__label .icon { width: 13px; height: 13px; }
.announcement-bar p { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.announcement-bar__close { display: flex; padding: 4px; color: #78a692; background: none; border: 0; border-radius: 5px; }
.announcement-bar__close:hover { color: #326a52; background: #e5f4ec; }
.announcement-bar__close .icon { width: 13px; height: 13px; }
.announcement-bar.is-hidden { display: none; }
.category-strip { display: flex; align-items: flex-start; gap: 20px; padding: 4px 1px 22px; }
.category-strip__head { flex-shrink: 0; display: flex; flex-direction: column; gap: 4px; padding-top: 8px; }
.category-strip__head span { display: flex; align-items: center; gap: 5px; color: var(--ink-2); font-size: 11.5px; font-weight: 700; }
.category-strip__head .icon { width: 13px; height: 13px; color: var(--muted); }
.category-strip__head a { color: var(--muted); font-size: 10px; }
.category-strip__head a:hover { color: var(--brand); }
.category-strip__list { display: flex; gap: 8px; flex: 1; overflow-x: auto; padding: 1px 1px 6px; scrollbar-width: none; }
.category-strip__list::-webkit-scrollbar { display: none; }
.category-chip {
    display: inline-flex; align-items: center; gap: 7px; flex-shrink: 0;
    height: 38px; padding: 0 11px 0 7px;
    background: #fff; border: 1px solid var(--line); border-radius: 10px;
    color: var(--ink-2); font-size: 12.5px; font-weight: 550;
    transition: border-color .18s, transform .18s, box-shadow .18s;
}
.category-chip:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--forum-color) 35%, var(--line)); box-shadow: var(--shadow-sm); }
.category-chip__icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 25px; height: 25px; border-radius: 7px;
    background: color-mix(in srgb, var(--forum-color) 11%, #fff);
    font-size: 14px;
}
.category-chip small { color: var(--muted-2); font-size: 9.5px; }
.category-chip:hover small { color: var(--forum-color); }

/* Feed & content grid ----------------------------------------------------- */
.content-grid { display: grid; grid-template-columns: minmax(0, 1fr) 316px; gap: 23px; align-items: start; }
.feed { min-width: 0; }
.section-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 13px; padding: 8px 2px 0; }
.section-heading h2 { margin-top: 5px; font-size: 25px; letter-spacing: -.5px; }
.section-heading > div > p:last-child { margin-top: 4px; color: var(--muted); font-size: 12px; }
.section-heading--compact { margin-top: -2px; }
.section-heading--compact h2 { font-size: 22px; }
.sort-tabs {
    display: inline-flex; align-items: center; gap: 2px; flex-shrink: 0;
    padding: 4px; background: #eaeef6; border-radius: 10px;
}
.sort-tabs a {
    display: inline-flex; align-items: center; justify-content: center;
    height: 29px; min-width: 48px; padding: 0 11px;
    border-radius: 7px; color: var(--muted); font-size: 11.5px; font-weight: 600;
    transition: color .18s, background .18s, box-shadow .18s;
}
.sort-tabs a:hover { color: var(--ink-2); }
.sort-tabs a.is-active { color: var(--ink); background: #fff; box-shadow: 0 2px 6px rgba(35, 45, 75, .08); }
.feed__count {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 10px; padding: 0 3px;
    color: var(--muted-2); font-size: 11px;
}
.feed__count span { display: inline-flex; align-items: center; gap: 5px; }
.feed__count .icon { width: 13px; height: 13px; }
.feed__live { color: #b16c19; }
.feed__live i { width: 6px; height: 6px; border-radius: 50%; background: var(--orange); box-shadow: 0 0 0 3px rgba(217, 121, 23, .1); }
.post-list { display: flex; flex-direction: column; gap: 11px; }

/* Post card --------------------------------------------------------------- */
.post-card {
    padding: 20px 22px 17px;
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
    box-shadow: var(--shadow-xs);
    transition: border-color .2s, box-shadow .2s, transform .2s;
}
.post-card:hover { border-color: #d5dded; box-shadow: 0 10px 25px rgba(24, 32, 51, .055); transform: translateY(-1px); }
.post-card__top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.post-card__labels { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; min-width: 0; }
.post-time { flex-shrink: 0; color: var(--muted-2); font-size: 10.5px; }
.forum-badge {
    display: inline-flex; align-items: center; gap: 5px;
    height: 23px; padding: 0 8px; border-radius: 6px;
    color: color-mix(in srgb, var(--forum-color) 75%, #172033);
    background: color-mix(in srgb, var(--forum-color) 10%, #fff);
    font-size: 10.5px; font-weight: 650; white-space: nowrap;
    transition: background .18s;
}
.forum-badge:hover { background: color-mix(in srgb, var(--forum-color) 17%, #fff); }
.forum-badge span { font-size: 12px; }
.post-card__title { margin-top: 10px; font-size: 19px; line-height: 1.45; letter-spacing: -.25px; }
.post-card__title a { transition: color .18s; }
.post-card__title a:hover { color: var(--brand); }
.post-card__excerpt {
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
    overflow: hidden; margin-top: 6px;
    color: var(--muted); font-size: 12.5px; line-height: 1.72;
}
.post-card__bottom {
    display: flex; align-items: center; justify-content: space-between; gap: 14px;
    margin-top: 14px; padding-top: 12px; border-top: 1px solid #f1f3f8;
}
.author-mini { display: inline-flex; align-items: center; gap: 6px; min-width: 0; color: var(--ink-2); font-size: 11.5px; }
.author-mini__name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 120px; }
.author-mini:hover .author-mini__name { color: var(--brand); }
.post-metrics { display: flex; align-items: center; gap: 13px; color: var(--muted-2); font-size: 10.5px; }
.metric { display: inline-flex; align-items: center; gap: 4px; color: var(--muted-2); }
.metric .icon { width: 13px; height: 13px; }
.metric--button { padding: 2px; border: 0; background: none; font-size: inherit; transition: color .18s; }
.metric--button:hover { color: var(--brand); }
.metric--button.is-active { color: #df5f6c; }
.metric--button.is-active .icon { fill: currentColor; }
.js-toggle-action form, .inline-action { display: inline-flex; margin: 0; }

/* Sidebar ----------------------------------------------------------------- */
.sidebar { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.side-card {
    padding: 17px 18px;
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
    box-shadow: var(--shadow-xs);
}
.side-card--mine { background: linear-gradient(160deg, #fbfcff, #f3f6ff); border-color: #e1e7f7; }
.side-card__head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.side-card__head h3 { display: flex; align-items: center; gap: 6px; font-size: 13px; }
.side-card__head h3 .icon { width: 14px; height: 14px; color: var(--brand); }
.side-card__head > a { color: var(--muted); font-size: 10.5px; }
.side-card__head > a:hover { color: var(--brand); }
.side-card__hint { padding: 1px 5px; border-radius: 4px; color: var(--muted-2); background: var(--bg-soft); font-size: 8.5px; font-weight: 700; letter-spacing: .7px; }
.side-forum-list { display: flex; flex-direction: column; gap: 1px; }
.side-forum { display: flex; align-items: center; gap: 9px; padding: 7px 5px; border-radius: 7px; color: var(--ink-2); font-size: 12px; }
.side-forum:hover { background: rgba(255, 255, 255, .8); color: var(--brand); }
.side-forum__icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 25px; height: 25px; border-radius: 7px; font-size: 13px;
    background: color-mix(in srgb, var(--forum-color) 12%, #fff);
}
.side-forum__name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side-forum__count { color: var(--muted-2); font-size: 9.5px; }
.side-forum > .icon { width: 12px; height: 12px; color: var(--muted-2); }
.hot-list { display: flex; flex-direction: column; gap: 12px; }
.hot-list li { display: flex; align-items: flex-start; gap: 9px; }
.hot-list__rank { color: #aab2c2; font-size: 11px; font-weight: 800; font-variant-numeric: tabular-nums; line-height: 1.55; }
.hot-list__rank--1 { color: var(--accent); }
.hot-list__rank--2 { color: #e19a2e; }
.hot-list__rank--3 { color: #b58a5b; }
.hot-list__body { min-width: 0; }
.hot-list__body a {
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
    color: var(--ink-2); font-size: 12px; line-height: 1.55; transition: color .18s;
}
.hot-list__body a:hover { color: var(--brand); }
.hot-list__body span { display: block; margin-top: 3px; color: var(--muted-2); font-size: 9.5px; }
.side-empty { padding: 12px 0; color: var(--muted-2); font-size: 11.5px; text-align: center; }
.active-users { display: flex; flex-direction: column; gap: 2px; }
.active-user { display: flex; align-items: center; gap: 9px; padding: 6px 4px; border-radius: 8px; }
.active-user:hover { background: var(--surface-soft); }
.active-user__info { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.active-user__info strong { display: flex; align-items: center; gap: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-2); font-size: 11.5px; font-weight: 650; }
.active-user__info small { color: var(--muted-2); font-size: 9.5px; }
.active-user__dot { width: 6px; height: 6px; border-radius: 50%; background: #34b985; flex-shrink: 0; }
.community-pulse {
    overflow: hidden; padding: 18px;
    color: rgba(255, 255, 255, .76);
    background:
        radial-gradient(circle at 100% 0, rgba(112, 150, 255, .35), transparent 45%),
        linear-gradient(145deg, #202d54, #152044);
    border: 1px solid rgba(255, 255, 255, .08); border-radius: var(--radius);
    box-shadow: 0 12px 28px rgba(21, 32, 68, .14);
}
.community-pulse__head { display: flex; align-items: center; justify-content: space-between; font-size: 11.5px; font-weight: 650; }
.community-pulse__head span { display: inline-flex; align-items: center; gap: 6px; color: #fff; }
.community-pulse__head .icon { width: 14px; height: 14px; color: #9db4ff; }
.community-pulse__stats { display: grid; grid-template-columns: repeat(3, 1fr); margin: 14px 0 11px; }
.community-pulse__stats div { display: flex; flex-direction: column; gap: 1px; padding: 0 10px; border-left: 1px solid rgba(255, 255, 255, .12); }
.community-pulse__stats div:first-child { padding-left: 0; border-left: 0; }
.community-pulse__stats strong { color: #fff; font-size: 19px; font-weight: 700; line-height: 1.3; }
.community-pulse__stats span { color: rgba(255, 255, 255, .5); font-size: 9.5px; }
.community-pulse > p { color: rgba(255, 255, 255, .48); font-size: 10px; line-height: 1.65; }
.sidebar-join {
    position: relative; overflow: hidden; padding: 20px;
    background: linear-gradient(145deg, #fff6ee, #fffaf5);
    border: 1px solid #f4e4d7; border-radius: var(--radius);
}
.sidebar-join__mark { display: flex; align-items: center; justify-content: center; width: 32px; height: 32px; margin-bottom: 10px; border-radius: 9px; color: var(--accent); background: #fff0e6; }
.sidebar-join h3 { font-size: 15px; }
.sidebar-join p { margin: 5px 0 13px; color: var(--muted); font-size: 11px; line-height: 1.65; }
.sidebar-join .button--light { border-color: #f0d9c8; background: #fff; box-shadow: none; }
.sidebar-join--admin { background: linear-gradient(145deg, #f3f6ff, #fafbff); border-color: #dfe6f8; }
.sidebar-join--admin .sidebar-join__mark { color: var(--brand); background: var(--brand-soft); }

/* Empty, pagination ------------------------------------------------------ */
.empty-state {
    padding: 60px 20px; text-align: center;
    background: var(--surface); border: 1px dashed #dce2ee; border-radius: var(--radius);
}
.empty-state__icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 48px; height: 48px; margin-bottom: 13px; border-radius: 14px;
    color: var(--brand); background: var(--brand-soft);
}
.empty-state__icon .icon { width: 23px; height: 23px; }
.empty-state h3 { font-size: 16px; }
.empty-state p { max-width: 360px; margin: 5px auto 16px; color: var(--muted); font-size: 12.5px; line-height: 1.7; }
.pagination { display: flex; align-items: center; justify-content: center; gap: 5px; margin-top: 24px; }
.pagination__page, .pagination__arrow {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 33px; height: 33px; padding: 0 8px;
    color: var(--ink-2); background: #fff; border: 1px solid var(--line); border-radius: 8px;
    font-size: 12px; transition: border-color .18s, color .18s, background .18s;
}
.pagination__page:hover, .pagination__arrow:hover { color: var(--brand); border-color: #bccbf4; background: #fbfcff; }
.pagination__page.is-current { color: #fff; background: var(--brand); border-color: var(--brand); font-weight: 700; }
.pagination__arrow .icon { width: 15px; height: 15px; }
.pagination__arrow.is-disabled { color: #c8ceda; background: #fafbfc; cursor: not-allowed; }
.pagination__ellipsis { min-width: 18px; color: var(--muted-2); text-align: center; font-size: 11px; }

/* Footer ------------------------------------------------------------------ */
.site-footer { margin-top: 12px; padding: 34px 0; background: rgba(255, 255, 255, .65); border-top: 1px solid var(--line); }
.site-footer__inner { display: flex; align-items: flex-start; justify-content: space-between; gap: 30px; }
.footer-brand { display: flex; align-items: flex-start; gap: 11px; }
.footer-brand strong { font-size: 14px; }
.footer-brand p { margin-top: 3px; color: var(--muted); font-size: 11px; }
.footer-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 11px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 16px; }
.footer-links a { color: var(--muted); font-size: 11px; }
.footer-links a:hover { color: var(--brand); }
.footer-meta > p { color: var(--muted-2); font-size: 10px; }

@keyframes spin { to { transform: rotate(360deg); } }
