/* ===== CSS Variables - 三层表面系统 ===== */
:root {
    /* 表面层级 */
    --bg: #0a0a0b;
    --bg-root: #0a0a0b;
    --surface-1: #141416;
    --surface-2: #1c1c1f;
    --surface-3: #252528;
    
    /* 边框 */
    --border: #2e2e32;
    --border-subtle: #2e2e32;
    --border-emphasis: #3e3e44;
    
    /* 文字 */
    --text-primary: #ededef;
    --text-secondary: #9d9da6;
    --text-muted: #6b6b74;
    
    /* 强调色 */
    --accent: #00e676;
    --accent-hover: #33eb91;
    
    /* 功能色 */
    --success: #22c55e;
    --warning: #f59e0b;
    --info: #3b82f6;
    
    /* 徽章色 */
    --badge-gold: #fbbf24;
    --badge-silver: #c0c0c0;
    --badge-bronze: #cd7f32;
    
    /* 错误色 */
    --error: #ef4444;
    
    /* 导航 */
    --nav-height: 56px;
    --nav-bg: rgba(10, 10, 11, 0.92);
    
    /* 圆角 */
    --radius-sm: 4px;
    --radius-md: 6px;
    --radius-lg: 8px;
}

/* ===== Reset & Base ===== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg-root);
    color: var(--text-primary);
    line-height: 1.5;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    word-break: break-word;
    overflow-wrap: break-word;
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
}

input, select, textarea {
    font-family: inherit;
    border: none;
    outline: none;
}

ul, ol {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
}

/* ===== Typography ===== */
.font-mono {
    font-family: 'Geist Mono', 'JetBrains Mono', 'Space Mono', monospace;
}

.text-micro { font-size: 10px; line-height: 1.3; font-weight: 500; letter-spacing: 0.02em; }
.text-caption { font-size: 11px; line-height: 1.4; font-weight: 500; letter-spacing: 0.02em; }
.text-xs { font-size: 12px; line-height: 1.5; font-weight: 400; }
.text-sm { font-size: 13px; line-height: 1.5; font-weight: 400; }
.text-base { font-size: 14px; line-height: 1.5; font-weight: 400; letter-spacing: -0.01em; }
.text-label { font-size: 12px; line-height: 1.3; font-weight: 600; letter-spacing: 0.03em; }
.text-h-xs { font-size: 15px; line-height: 1.4; font-weight: 600; letter-spacing: -0.01em; }
.text-h-sm { font-size: 18px; line-height: 1.35; font-weight: 600; letter-spacing: -0.02em; }
.text-h { font-size: 24px; line-height: 1.3; font-weight: 600; letter-spacing: -0.03em; }
.text-h-lg { font-size: 28px; line-height: 1.2; font-weight: 600; letter-spacing: -0.04em; }
.text-display { font-size: 36px; line-height: 1.1; font-weight: 600; letter-spacing: -0.05em; }

/* ===== Navigation ===== */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--nav-height);
    background: var(--nav-bg);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid #1e1e22;
    z-index: 1000;
    transition: background 150ms ease;
}

.nav.scrolled {
    background: rgba(10, 10, 11, 0.98);
}

.nav-container {
    max-width: 1280px;
    margin: 0 auto;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
}

.nav-logo {
    font-family: 'Geist Mono', monospace;
    font-weight: 500;
    font-size: 16px;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 6px;
}

.nav-logo::before {
    content: '';
    width: 8px;
    height: 8px;
    background: var(--accent);
    border-radius: 50%;
}

.nav-links {
    display: flex;
    gap: 32px;
}

.nav-link {
    font-size: 13px;
    font-weight: 400;
    color: var(--text-secondary);
    transition: color 150ms ease;
}

.nav-link:hover, .nav-link.active {
    color: var(--text-primary);
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.nav-notification {
    position: relative;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    transition: color 150ms ease;
}

.nav-notification:hover {
    color: var(--text-primary);
}

.nav-notification-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    min-width: 14px;
    height: 14px;
    background: var(--error);
    color: white;
    font-size: 10px;
    font-weight: 500;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 3px;
}

.nav-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--surface-3);
    overflow: hidden;
}

.nav-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ===== Buttons ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-weight: 600;
    border-radius: var(--radius-md);
    transition: all 150ms ease-out;
    white-space: nowrap;
}

.btn-primary {
    background: var(--accent);
    color: var(--bg-root);
    font-size: 13px;
    padding: 10px 20px;
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: scale(1.03);
}

.btn-secondary {
    background: transparent;
    border: 1.5px solid var(--border-emphasis);
    color: var(--text-secondary);
    font-size: 13px;
    padding: 10px 20px;
}

.btn-secondary:hover {
    border-color: var(--accent);
    color: var(--text-primary);
}

.btn-sm {
    padding: 6px 14px;
    font-size: 12px;
    font-weight: 500;
}

/* ===== Main Layout ===== */
.main {
    padding-top: var(--nav-height);
    min-height: 100vh;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

.container-full {
    width: 100%;
    padding: 0 24px;
}

/* ===== Section ===== */
.section {
    padding: 100px 0;
}

.section-sm {
    padding: 64px 0;
}

.section-header {
    margin-bottom: 40px;
}

.section-title {
    font-size: 24px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.section-subtitle {
    font-size: 14px;
    color: var(--text-secondary);
}

/* ===== Cards ===== */
.card {
    background: var(--surface-1);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    transition: border-color 150ms ease;
}

.card:hover {
    border-color: var(--border-emphasis);
}

.card-body {
    padding: 20px;
}

/* ===== Tags/Badges ===== */
.tag {
    display: inline-flex;
    align-items: center;
    font-size: 10px;
    font-weight: 500;
    padding: 2px 8px;
    background: var(--surface-2);
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
}

.tag-accent {
    background: var(--accent);
    color: var(--bg-root);
}

.tag-info {
    background: rgba(59, 130, 246, 0.15);
    color: var(--info);
}

.tag-warning {
    background: rgba(245, 158, 11, 0.15);
    color: var(--warning);
}

.tag-success {
    background: rgba(34, 197, 94, 0.15);
    color: var(--success);
}

/* ===== Badges ===== */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 10px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: var(--radius-sm);
    border: 1px solid;
}

.badge-gold {
    border-color: var(--badge-gold);
    color: var(--badge-gold);
}

.badge-silver {
    border-color: var(--badge-silver);
    color: var(--badge-silver);
}

.badge-bronze {
    border-color: var(--badge-bronze);
    color: var(--badge-bronze);
}

/* ===== Two Column Layout ===== */
.grid-2col {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 32px;
}

/* ===== Sidebar ===== */
.sidebar {
    position: sticky;
    top: 72px;
    height: fit-content;
}

/* ===== Activity Feed ===== */
.feed-filters {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
}

.feed-filter {
    font-size: 12px;
    font-weight: 400;
    color: var(--text-secondary);
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    transition: all 150ms ease;
}

.feed-filter:hover, .feed-filter.active {
    background: var(--surface-2);
    color: var(--text-primary);
}

.feed-item {
    background: var(--surface-1);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    margin-bottom: 12px;
    display: flex;
    gap: 16px;
    transition: all 150ms ease;
}

.feed-item:hover {
    border-color: var(--border-emphasis);
}

.feed-item-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.feed-item-icon.post {
    background: rgba(59, 130, 246, 0.1);
    color: var(--info);
}

.feed-item-icon.event {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
}

.feed-item-icon.resource {
    background: rgba(34, 197, 94, 0.1);
    color: var(--success);
}

.feed-item-icon.member {
    background: rgba(0, 230, 118, 0.1);
    color: var(--accent);
}

.feed-item-content {
    flex: 1;
    min-width: 0;
}

.feed-item-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.feed-item-desc {
    font-size: 13px;
    color: var(--text-secondary);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 10px;
}

.feed-item-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 11px;
    color: var(--text-muted);
}

.feed-item-meta-item {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* ===== Newbie Tasks ===== */
.task-card {
    background: var(--surface-2);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 20px;
}

.task-card-header {
    margin-bottom: 16px;
}

.task-card-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.task-card-subtitle {
    font-size: 12px;
    color: var(--text-secondary);
}

.task-steps {
    position: relative;
}

.task-step {
    display: flex;
    gap: 12px;
    padding: 12px 0;
    position: relative;
}

.task-step:not(:last-child)::after {
    content: '';
    position: absolute;
    left: 11px;
    top: 36px;
    bottom: 0;
    width: 1px;
    border-left: 1px dashed var(--border-subtle);
}

.task-step-icon {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 11px;
    font-weight: 600;
}

.task-step-icon.pending {
    background: var(--surface-3);
    color: var(--text-muted);
}

.task-step-icon.active {
    background: var(--accent);
    color: var(--bg-root);
}

.task-step-icon.completed {
    background: var(--success);
    color: white;
}

.task-step-content {
    flex: 1;
}

.task-step-title {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.task-step-desc {
    font-size: 11px;
    color: var(--text-secondary);
    margin-top: 2px;
}

.task-badge {
    font-size: 9px;
    font-weight: 500;
    padding: 1px 5px;
    background: var(--accent);
    color: var(--bg-root);
    border-radius: var(--radius-sm);
    animation: badgePop 400ms ease-out;
}

@keyframes badgePop {
    0% { transform: scale(0); }
    70% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

.task-progress {
    margin-top: 16px;
}

.task-progress-bar {
    height: 4px;
    background: var(--border-subtle);
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.task-progress-fill {
    height: 100%;
    background: var(--accent);
    border-radius: var(--radius-sm);
    transition: width 400ms ease;
}

.task-progress-text {
    font-size: 11px;
    color: var(--text-secondary);
    margin-top: 6px;
    text-align: right;
}

/* ===== Stats Card ===== */
.stats-card {
    background: var(--surface-2);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 20px;
    margin-top: 16px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.stat-item {
    text-align: center;
}

.stat-value {
    font-family: 'Geist Mono', monospace;
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
}

.stat-label {
    font-size: 11px;
    color: var(--text-secondary);
    margin-top: 2px;
}

/* ===== Tags Cloud ===== */
.tags-card {
    background: var(--surface-2);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 20px;
    margin-top: 16px;
}

.tags-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.cloud-tag {
    font-size: 11px;
    padding: 4px 10px;
    background: var(--surface-3);
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    transition: all 150ms ease;
}

.cloud-tag:hover {
    background: var(--border-emphasis);
    color: var(--text-primary);
}

/* ===== Discussion ===== */
.discussion-layout {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 32px;
}

.discussion-nav {
    position: sticky;
    top: 72px;
    height: fit-content;
}

/* ===== Ad Slots ===== */
.ad-slot {
    background: var(--surface-1);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    overflow: hidden;
    position: relative;
    transition: all 200ms ease;
}

.ad-slot:hover {
    border-color: var(--border-emphasis);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.ad-slot-label {
    position: absolute;
    top: 8px;
    right: 8px;
    font-size: 10px;
    color: var(--text-muted);
    background: var(--surface-2);
    padding: 2px 6px;
    border-radius: var(--radius-sm);
    z-index: 1;
}

.ad-slot-sidebar {
    margin-top: 16px;
}

.ad-slot-sidebar a {
    display: block;
}

.ad-slot-sidebar img {
    width: 100%;
    height: auto;
    display: block;
}

.ad-slot-top {
    margin-bottom: 16px;
}

.ad-slot-top a {
    display: block;
}

.ad-slot-top img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    display: block;
}

.ad-slot-bottom {
    margin-top: 16px;
}

.ad-slot-bottom a {
    display: block;
}

.ad-slot-bottom img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    display: block;
}

.ad-slot-content {
    padding: 16px;
    text-align: center;
}

.ad-slot-content a {
    display: block;
    color: var(--accent);
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 8px;
}

.ad-slot-content p {
    color: var(--text-secondary);
    font-size: 12px;
    line-height: 1.4;
}

.category-list {
    background: var(--surface-1);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 12px;
}

.category-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    font-size: 13px;
    color: var(--text-secondary);
    transition: all 150ms ease;
    cursor: pointer;
}

.category-item:hover, .category-item.active {
    background: var(--surface-2);
    color: var(--text-primary);
}

.category-count {
    font-size: 11px;
    color: var(--text-muted);
}

.post-list-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.post-sort {
    display: flex;
    gap: 4px;
}

.post-sort-btn {
    font-size: 12px;
    color: var(--text-secondary);
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    transition: all 150ms ease;
}

.post-sort-btn:hover, .post-sort-btn.active {
    background: var(--surface-2);
    color: var(--text-primary);
}

.post-card {
    background: var(--surface-1);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 16px;
    margin-bottom: 12px;
    display: flex;
    gap: 16px;
    transition: all 150ms ease;
    position: relative;
}

.post-card:hover {
    border-color: var(--border-emphasis);
}

.post-card.unread::before {
    content: '';
    position: absolute;
    left: 0;
    top: 12px;
    bottom: 12px;
    width: 3px;
    background: var(--accent);
    border-radius: 0 2px 2px 0;
}

.post-vote {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    min-width: 40px;
}

.vote-btn {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    border-radius: var(--radius-sm);
    transition: all 150ms ease;
}

.vote-btn:hover {
    background: var(--surface-2);
    color: var(--accent);
}

.vote-btn.voted {
    color: var(--accent);
}

.vote-count {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
}

.post-content {
    flex: 1;
    min-width: 0;
}

.post-tags {
    display: flex;
    gap: 6px;
    margin-bottom: 8px;
}

.post-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.post-excerpt {
    font-size: 13px;
    color: var(--text-secondary);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 12px;
}

.post-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 11px;
    color: var(--text-muted);
}

.post-meta-item {
    display: flex;
    align-items: center;
    gap: 4px;
}

.post-badge {
    font-size: 9px;
    font-weight: 600;
    padding: 1px 6px;
    border-radius: var(--radius-sm);
}

.post-badge.pinned {
    background: var(--surface-3);
    color: var(--text-secondary);
}

.post-badge.hot {
    background: var(--badge-gold);
    color: var(--bg-root);
}

/* ===== Events Grid ===== */
.events-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
}

.event-card {
    background: var(--surface-1);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: all 150ms ease;
}

.event-card:hover {
    border-color: var(--border-emphasis);
    transform: translateY(-2px);
}

.event-cover {
    height: 140px;
    background: linear-gradient(135deg, var(--surface-2) 0%, var(--surface-3) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.event-cover-icon {
    width: 48px;
    height: 48px;
    color: var(--text-muted);
}

.event-status {
    position: absolute;
    top: 12px;
    right: 12px;
}

.event-body {
    padding: 16px;
}

.event-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.event-info {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 12px;
    color: var(--text-secondary);
}

.event-info-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

/* ===== Members Directory ===== */
.members-filter-bar {
    position: sticky;
    top: var(--nav-height);
    background: #0f0f12;
    padding: 16px 24px;
    z-index: 100;
    display: flex;
    align-items: center;
    gap: 16px;
    border-bottom: 1px solid var(--border-subtle);
}

.search-input {
    width: 280px;
    background: var(--surface-2);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 8px 12px;
    font-size: 13px;
    color: var(--text-primary);
    transition: border-color 150ms ease;
}

.search-input:focus {
    border-color: var(--accent);
}

.filter-select {
    background: var(--surface-2);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 8px 12px;
    font-size: 13px;
    color: var(--text-primary);
    cursor: pointer;
}

.members-list {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

.member-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 12px 16px;
    background: var(--surface-1);
    border-bottom: 1px solid var(--border-subtle);
    transition: background 150ms ease;
}

.member-item:first-child {
    border-radius: var(--radius-md) var(--radius-md) 0 0;
}

.member-item:last-child {
    border-radius: 0 0 var(--radius-md) var(--radius-md);
    border-bottom: none;
}

.member-item:hover {
    background: #1a1a1d;
}

.member-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--surface-3);
    overflow: hidden;
    flex-shrink: 0;
}

.member-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(100%);
}

.member-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    min-width: 120px;
}

.member-skills {
    display: flex;
    gap: 6px;
    flex: 1;
}

.member-skill {
    font-size: 11px;
    padding: 2px 8px;
    background: var(--surface-2);
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
}

.member-region {
    font-size: 12px;
    color: var(--text-muted);
    min-width: 80px;
}

/* ===== Membership Table ===== */
.membership-table-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--border-subtle);
}

.membership-table {
    width: 100%;
    border-collapse: collapse;
}

.membership-table th,
.membership-table td {
    padding: 16px 20px;
    text-align: center;
    border-bottom: 1px solid var(--border-subtle);
}

.membership-table th:first-child,
.membership-table td:first-child {
    text-align: left;
}

.membership-table thead th {
    background: var(--surface-1);
    font-size: 12px;
    font-weight: 600;
    color: var(--text-primary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    height: 52px;
}

.membership-table tbody tr:nth-child(odd) {
    background: var(--surface-1);
}

.membership-table tbody tr:nth-child(even) {
    background: #16161a;
}

.membership-table tbody td:first-child {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
}

.membership-table .recommended {
    border-left: 2px solid var(--accent);
    border-right: 2px solid var(--accent);
}

.membership-table thead .recommended {
    position: relative;
}

.membership-table thead .recommended::after {
    content: '推荐';
    position: absolute;
    top: 8px;
    right: 8px;
    font-size: 10px;
    font-weight: 500;
    padding: 2px 6px;
    background: var(--accent);
    color: var(--bg-root);
    border-radius: var(--radius-sm);
}

.check-icon {
    color: var(--success);
}

.cross-icon {
    color: var(--text-muted);
}

.membership-price {
    font-family: 'Geist Mono', monospace;
    font-size: 24px;
    font-weight: 600;
    color: var(--text-primary);
}

.membership-period {
    font-size: 12px;
    color: var(--text-secondary);
    margin-left: 4px;
}

/* ===== Achievements Gallery ===== */
.achievements-scroll {
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding: 24px;
    background: var(--surface-1);
    border-radius: var(--radius-md);
    display: flex;
    gap: 16px;
}

.achievements-scroll::-webkit-scrollbar {
    height: 6px;
}

.achievements-scroll::-webkit-scrollbar-track {
    background: var(--surface-2);
    border-radius: 3px;
}

.achievements-scroll::-webkit-scrollbar-thumb {
    background: var(--border-emphasis);
    border-radius: 3px;
}

.achievement-card {
    flex: 0 0 220px;
    scroll-snap-align: start;
    background: var(--surface-2);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.achievement-thumb {
    width: 100%;
    height: 100px;
    background: linear-gradient(135deg, var(--surface-3) 0%, var(--bg-root) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.achievement-thumb-icon {
    width: 32px;
    height: 32px;
    color: var(--text-muted);
}

.achievement-body {
    padding: 12px;
}

.achievement-title {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.achievement-author {
    font-size: 11px;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.achievement-likes {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    color: var(--text-muted);
}

/* ===== Post Detail ===== */
.post-detail {
    max-width: 800px;
    margin: 0 auto;
}

.post-detail-header {
    margin-bottom: 32px;
}

.post-detail-title {
    font-size: 28px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 16px;
    line-height: 1.3;
}

.post-detail-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-subtle);
}

.post-author {
    display: flex;
    align-items: center;
    gap: 10px;
}

.post-author-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--surface-3);
}

.post-author-name {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
}

.post-detail-content {
    font-size: 15px;
    line-height: 1.8;
    color: var(--text-primary);
}

.post-detail-content p {
    margin-bottom: 20px;
}

.post-detail-content code {
    background: var(--surface-2);
    padding: 2px 6px;
    border-radius: var(--radius-sm);
    font-family: 'Geist Mono', monospace;
    font-size: 13px;
}

.post-detail-content pre {
    background: var(--surface-1);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 16px;
    overflow-x: auto;
    margin: 20px 0;
}

.post-detail-content pre code {
    background: none;
    padding: 0;
}

/* ===== Comments ===== */
.comments-section {
    margin-top: 48px;
    padding-top: 32px;
    border-top: 1px solid var(--border-subtle);
}

.comments-header {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 24px;
}

.comment-item {
    display: flex;
    gap: 12px;
    padding: 16px 0;
    border-bottom: 1px solid var(--border-subtle);
}

.comment-item:last-child {
    border-bottom: none;
}

.comment-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--surface-3);
    flex-shrink: 0;
}

.comment-content {
    flex: 1;
}

.comment-author {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.comment-text {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.comment-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 8px;
    font-size: 11px;
    color: var(--text-muted);
}

/* ===== Event Detail ===== */
.event-detail {
    max-width: 900px;
    margin: 0 auto;
}

.event-detail-cover {
    height: 280px;
    background: linear-gradient(135deg, var(--surface-2) 0%, var(--surface-3) 100%);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 32px;
}

.event-detail-title {
    font-size: 32px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 16px;
}

.event-detail-info {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    margin-bottom: 32px;
    padding: 20px;
    background: var(--surface-1);
    border-radius: var(--radius-md);
}

.event-info-block {
    display: flex;
    align-items: center;
    gap: 10px;
}

.event-info-icon {
    width: 36px;
    height: 36px;
    background: var(--surface-2);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
}

.event-info-text {
    display: flex;
    flex-direction: column;
}

.event-info-label {
    font-size: 11px;
    color: var(--text-muted);
}

.event-info-value {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
}

.event-detail-content {
    font-size: 15px;
    line-height: 1.8;
    color: var(--text-primary);
}

.event-detail-content h3 {
    font-size: 18px;
    font-weight: 600;
    margin: 32px 0 16px;
}

.event-detail-content ul {
    padding-left: 20px;
    margin-bottom: 20px;
}

.event-detail-content li {
    margin-bottom: 8px;
    position: relative;
    padding-left: 16px;
}

.event-detail-content li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 10px;
    width: 6px;
    height: 6px;
    background: var(--accent);
    border-radius: 50%;
}

/* ===== Footer ===== */
.footer {
    background: var(--surface-1);
    border-top: 1px solid var(--border-subtle);
    padding: 48px 0 24px;
    margin-top: 100px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr repeat(3, 1fr);
    gap: 48px;
    margin-bottom: 40px;
}

.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-brand-name {
    font-family: 'Geist Mono', monospace;
    font-size: 16px;
    font-weight: 500;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 6px;
}

.footer-brand-name::before {
    content: '';
    width: 8px;
    height: 8px;
    background: var(--accent);
    border-radius: 50%;
}

.footer-brand-desc {
    font-size: 13px;
    color: var(--text-secondary);
    max-width: 280px;
}

.footer-col-title {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-primary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 16px;
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-link {
    font-size: 13px;
    color: var(--text-secondary);
    transition: color 150ms ease;
}

.footer-link:hover {
    color: var(--text-primary);
}

.footer-bottom {
    padding-top: 24px;
    border-top: 1px solid var(--border-subtle);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: var(--text-muted);
}

/* ===== Mobile Menu ===== */
.mobile-menu-btn {
    display: none;
    width: 32px;
    height: 32px;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .mobile-menu-btn {
        display: flex;
    }
    
    .nav-container {
        padding: 0 16px;
    }
    
    .container {
        padding: 0 16px;
    }
    
    .section {
        padding: 64px 0;
    }
    
    /* 帖子卡片移动端适配 */
    .post-card {
        padding: 12px;
        gap: 10px;
    }
    
    .post-vote {
        min-width: 32px;
        gap: 2px;
    }
    
    .vote-btn {
        width: 24px;
        height: 24px;
    }
    
    .vote-btn svg {
        width: 14px;
        height: 14px;
    }
    
    .vote-count {
        font-size: 12px;
    }
    
    .post-title {
        font-size: 13px;
    }
    
    .post-excerpt {
        font-size: 12px;
        margin-bottom: 8px;
    }
    
    .post-meta {
        flex-wrap: wrap;
        gap: 8px;
        font-size: 10px;
    }
    
    .post-meta-item svg {
        width: 10px;
        height: 10px;
    }
    
    /* 分类列表横向滚动 */
    .category-list {
        gap: 6px;
        padding: 6px;
    }
    
    .category-item {
        padding: 8px 10px;
        font-size: 12px;
    }
    
    .post-list-header {
        margin-bottom: 12px;
    }
    
    .post-sort-btn {
        font-size: 11px;
        padding: 4px 10px;
    }
    
    .events-grid {
        grid-template-columns: 1fr;
    }
    
    .members-filter-bar {
        flex-wrap: wrap;
        padding: 12px 16px;
    }
    
    .search-input {
        width: 100%;
    }
    
    .membership-table-wrapper {
        border-radius: 0;
    }
    
    .membership-table,
    .membership-table tbody,
    .membership-table tr,
    .membership-table td {
        display: block;
    }
    
    .membership-table thead {
        display: none;
    }
    
    .membership-table tr {
        margin-bottom: 16px;
        border: 1px solid var(--border-subtle);
        border-radius: var(--radius-md);
        overflow: hidden;
    }
    
    .membership-table td {
        display: flex;
        justify-content: space-between;
        padding: 12px 16px;
        text-align: right;
    }
    
    .membership-table td:first-child {
        background: var(--surface-2);
        font-weight: 600;
    }
    
    .membership-table td::before {
        content: attr(data-label);
        font-weight: 500;
        color: var(--text-secondary);
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    .footer-brand-desc {
        max-width: 100%;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }
    
    .footer {
        padding: 32px 0 20px;
        margin-top: 60px;
    }
    
    /* 分页适配 */
    .pagination {
        gap: 2px;
        margin-top: 20px;
    }
    
    .pagination-btn {
        min-width: 32px;
        height: 32px;
        font-size: 12px;
    }
    
    /* 成员列表适配 */
    .member-item {
        padding: 10px 12px;
        gap: 10px;
        flex-wrap: wrap;
    }
    
    .member-skills {
        flex-wrap: wrap;
        gap: 4px;
    }
    
    .member-region {
        min-width: auto;
        font-size: 11px;
    }
}

@media (max-width: 1024px) {
    .grid-2col {
        grid-template-columns: 1fr;
    }
    
    .sidebar {
        position: static;
    }
    
    .discussion-layout {
        grid-template-columns: 1fr;
    }
    
    .discussion-nav {
        position: static;
    }
    
    /* Mobile Ad Slots */
    .ad-slot-sidebar {
        display: none;
    }
    
    .ad-slot-top,
    .ad-slot-bottom {
        min-height: 60px;
    }
    
    .ad-slot-content {
        padding: 12px;
    }
    
    .ad-slot-content a {
        font-size: 13px;
    }
    
    .ad-slot-content p {
        font-size: 11px;
    }
    
    .category-list {
        display: flex;
        overflow-x: auto;
        gap: 8px;
        padding: 8px;
    }
    
    .category-item {
        white-space: nowrap;
    }
    
    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 32px;
    }
}

/* ===== Page Hero ===== */
.page-hero {
    padding: 60px 0 40px;
    text-align: center;
}

.page-hero-title {
    font-size: 36px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.page-hero-desc {
    font-size: 16px;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

/* ===== Breadcrumb ===== */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 24px;
}

.breadcrumb a {
    color: var(--text-secondary);
    transition: color 150ms ease;
}

.breadcrumb a:hover {
    color: var(--accent);
}

.breadcrumb-separator {
    color: var(--text-muted);
}

/* ===== Form ===== */
.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-size: 12px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 6px;
}

.form-input {
    width: 100%;
    background: var(--surface-2);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 10px 14px;
    font-size: 14px;
    color: var(--text-primary);
    transition: border-color 150ms ease;
}

.form-input:focus {
    border-color: var(--accent);
}

.form-textarea {
    min-height: 120px;
    resize: vertical;
}

/* ===== Empty State ===== */
.empty-state {
    text-align: center;
    padding: 60px 20px;
}

.empty-state-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 16px;
    color: var(--text-muted);
}

.empty-state-title {
    font-size: 16px;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.empty-state-desc {
    font-size: 14px;
    color: var(--text-secondary);
}

/* ===== Pagination ===== */
.pagination {
    display: flex;
    justify-content: center;
    gap: 4px;
    margin-top: 32px;
}

.pagination-btn {
    min-width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    transition: all 150ms ease;
}

.pagination-btn:hover {
    background: var(--surface-2);
    color: var(--text-primary);
}

.pagination-btn.active {
    background: var(--accent);
    color: var(--bg-root);
}

/* ===== CTA Section ===== */
.cta-section {
    text-align: center;
    padding: 80px 24px;
    background: var(--surface-1);
    border-radius: var(--radius-lg);
    margin: 60px 0;
}

.cta-title {
    font-size: 28px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.cta-desc {
    font-size: 16px;
    color: var(--text-secondary);
    margin-bottom: 24px;
}

/* ===== Online Members ===== */
.online-members {
    background: var(--surface-2);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 20px;
    margin-top: 16px;
}

.online-members-title {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.online-members-title::before {
    content: '';
    width: 6px;
    height: 6px;
    background: var(--success);
    border-radius: 50%;
}

.online-avatars {
    display: flex;
    gap: 8px;
}

.online-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--surface-3);
    border: 2px solid var(--surface-2);
}

/* ===== Animations ===== */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 300ms ease-out;
}

/* ===== Admin Badge ===== */
.admin-badge {
    display: inline-block;
    padding: 1px 6px;
    font-size: 10px;
    font-weight: 600;
    color: #fff;
    background: var(--accent);
    border-radius: 3px;
    margin-left: 6px;
    vertical-align: middle;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

/* ===== Author Badge ===== */
.author-badge {
    display: inline-block;
    padding: 1px 6px;
    font-size: 10px;
    font-weight: 600;
    color: #fff;
    background: #22c55e;
    border-radius: 3px;
    margin-left: 6px;
    vertical-align: middle;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

/* ===== Vote Animation ===== */
@keyframes voteFloat {
    from { opacity: 1; transform: translateY(0); }
    to { opacity: 0; transform: translateY(-8px); }
}

.vote-float {
    position: absolute;
    color: var(--accent);
    font-size: 12px;
    font-weight: 600;
    animation: voteFloat 200ms ease-out forwards;
}

/* ===== Post Author Avatar ===== */
.post-author-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--surface-3);
    background-size: cover;
    background-position: center;
    margin-right: 12px;
    flex-shrink: 0;
}

/* ===== Comment Avatar ===== */
.comment-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--surface-3);
    background-size: cover;
    background-position: center;
    margin-right: 12px;
    flex-shrink: 0;
}

/* ===== Comment Item Layout ===== */
.comment-item {
    display: flex;
    align-items: flex-start;
    padding: 16px 0;
    border-bottom: 1px solid var(--border-subtle);
}

.comment-item:last-child {
    border-bottom: none;
}

.comment-content {
    flex: 1;
    min-width: 0;
}

.comment-author {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.comment-text {
    font-size: 14px;
    color: var(--text-primary);
    line-height: 1.6;
    margin-bottom: 8px;
    word-wrap: break-word;
}

.comment-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 12px;
    color: var(--text-muted);
}

.comment-meta button {
    color: var(--text-muted);
    font-size: 11px;
    padding: 0;
    background: none;
    border: none;
    cursor: pointer;
}

.comment-meta button:hover {
    color: var(--accent);
}

/* ===== Comment Like Button ===== */
.comment-like-btn {
    display: flex;
    align-items: center;
    gap: 4px;
    color: var(--text-muted);
    font-size: 11px;
    padding: 2px 6px;
    border-radius: var(--radius-sm);
    transition: all 0.2s;
}

.comment-like-btn:hover {
    color: var(--error);
    background: rgba(239, 68, 68, 0.1);
}

.comment-like-btn.liked {
    color: var(--error);
}

.comment-like-btn.liked svg {
    fill: var(--error);
    stroke: var(--error);
}

/* ===== Post Actions ===== */
.post-actions {
    display: flex;
    gap: 12px;
    margin-top: 32px;
    padding: 16px;
    background: var(--surface-1);
    border-radius: var(--radius-md);
}

.action-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: var(--radius-md);
    background: var(--surface-2);
    color: var(--text-secondary);
    font-size: 14px;
    transition: all 0.2s;
}

.action-btn:hover {
    background: var(--surface-3);
    color: var(--text-primary);
}

.action-btn.liked {
    background: rgba(239, 68, 68, 0.15);
    color: var(--error);
}

.action-btn.liked svg {
    fill: var(--error);
    stroke: var(--error);
}

.action-btn.favorited {
    background: rgba(251, 191, 36, 0.15);
    color: var(--badge-gold);
}

.action-btn.favorited svg {
    fill: var(--badge-gold);
    stroke: var(--badge-gold);
}

.action-btn .count {
    font-weight: 600;
}

/* ===== Rich Text Editor ===== */
/* Rich Content Display (post detail) */
.rich-content h1 {
    font-size: 24px;
    font-weight: 700;
    margin: 24px 0 12px;
    color: var(--text-primary);
}

.rich-content h2 {
    font-size: 20px;
    font-weight: 600;
    margin: 20px 0 10px;
    color: var(--text-primary);
}

.rich-content h3 {
    font-size: 17px;
    font-weight: 600;
    margin: 16px 0 8px;
    color: var(--text-primary);
}

.rich-content p {
    margin: 10px 0;
    line-height: 1.7;
}

.rich-content ul,
.rich-content ol {
    padding-left: 28px;
    margin: 14px 0;
}

.rich-content li {
    margin: 6px 0;
    line-height: 1.6;
}

.rich-content blockquote {
    border-left: 4px solid var(--accent);
    padding: 14px 18px;
    margin: 18px 0;
    background: var(--surface-1);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    color: var(--text-secondary);
    font-style: italic;
}

.rich-content pre.code-block {
    background: #1e1e2e;
    color: #cdd6f4;
    padding: 18px 22px;
    border-radius: var(--radius-md);
    margin: 18px 0;
    overflow-x: auto;
    font-family: 'JetBrains Mono', monospace;
    font-size: 13px;
    line-height: 1.6;
}

.rich-content pre.code-block code {
    background: transparent;
    padding: 0;
    color: inherit;
    font-size: inherit;
}

.rich-content code {
    background: var(--surface-3);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.9em;
    color: var(--accent);
}

.rich-content a {
    color: var(--accent);
    text-decoration: underline;
}

.rich-content a:hover {
    opacity: 0.8;
}

.rich-content img {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-md);
    margin: 14px 0;
    display: block;
}

.rich-content hr {
    border: none;
    border-top: 1px solid var(--border-subtle);
    margin: 28px 0;
}

.rich-content strong,
.rich-content b {
    font-weight: 600;
}

.rich-content em,
.rich-content i {
    font-style: italic;
}

.rich-content del,
.rich-content s {
    text-decoration: line-through;
    color: var(--text-muted);
}

/* Editor styles */
.rich-editor {
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    background: var(--surface-2);
    overflow: hidden;
}

.rich-editor:focus-within {
    border-color: var(--accent);
}

.editor-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 2px;
    padding: 8px 12px;
    background: var(--surface-1);
    border-bottom: 1px solid var(--border-subtle);
}

.toolbar-group {
    display: flex;
    align-items: center;
    gap: 2px;
}

.toolbar-divider {
    width: 1px;
    height: 20px;
    background: var(--border-subtle);
    margin: 0 6px;
}

.toolbar-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: none;
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.15s;
}

.toolbar-btn:hover {
    background: var(--surface-2);
    color: var(--text-primary);
}

.toolbar-btn.active {
    background: var(--accent);
    color: #fff;
}

.toolbar-btn svg {
    width: 16px;
    height: 16px;
}

.editor-content {
    min-height: 300px;
    max-height: 600px;
    overflow-y: auto;
    padding: 16px 20px;
    font-size: 15px;
    line-height: 1.7;
    color: var(--text-primary);
    outline: none;
}

.editor-content:empty::before {
    content: attr(data-placeholder);
    color: var(--text-muted);
    pointer-events: none;
}

.editor-content.drag-over {
    background: rgba(59, 130, 246, 0.05);
    outline: 2px dashed var(--accent);
    outline-offset: -8px;
}

/* Editor content styles */
.editor-content h1 {
    font-size: 24px;
    font-weight: 700;
    margin: 20px 0 12px;
    color: var(--text-primary);
}

.editor-content h2 {
    font-size: 20px;
    font-weight: 600;
    margin: 18px 0 10px;
    color: var(--text-primary);
}

.editor-content h3 {
    font-size: 17px;
    font-weight: 600;
    margin: 16px 0 8px;
    color: var(--text-primary);
}

.editor-content p {
    margin: 8px 0;
}

.editor-content ul,
.editor-content ol {
    padding-left: 24px;
    margin: 12px 0;
}

.editor-content li {
    margin: 4px 0;
}

.editor-content blockquote {
    border-left: 4px solid var(--accent);
    padding: 12px 16px;
    margin: 16px 0;
    background: var(--surface-1);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    color: var(--text-secondary);
}

.editor-content pre.code-block {
    background: #1e1e2e;
    color: #cdd6f4;
    padding: 16px 20px;
    border-radius: var(--radius-md);
    margin: 16px 0;
    overflow-x: auto;
    font-family: 'JetBrains Mono', monospace;
    font-size: 13px;
    line-height: 1.5;
}

.editor-content pre.code-block code {
    background: transparent;
    padding: 0;
    color: inherit;
    font-size: inherit;
}

.editor-content code {
    background: var(--surface-3);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.9em;
    color: var(--accent);
}

.editor-content a {
    color: var(--accent);
    text-decoration: underline;
}

.editor-content img {
    max-width: 100%;
    border-radius: var(--radius-md);
    margin: 12px 0;
}

.editor-content hr {
    border: none;
    border-top: 1px solid var(--border-subtle);
    margin: 24px 0;
}

.editor-content .upload-loading {
    display: inline-block;
    padding: 4px 12px;
    background: var(--surface-3);
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    font-size: 13px;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Editor mobile responsive */
@media (max-width: 768px) {
    .editor-toolbar {
        padding: 6px 8px;
    }
    
    .toolbar-btn {
        width: 28px;
        height: 28px;
    }
    
    .toolbar-btn svg {
        width: 14px;
        height: 14px;
    }
    
    .toolbar-divider {
        margin: 0 4px;
        height: 16px;
    }
    
    .editor-content {
        min-height: 200px;
        padding: 12px 14px;
        font-size: 14px;
    }
    
    .editor-content h1 { font-size: 20px; }
    .editor-content h2 { font-size: 17px; }
    .editor-content h3 { font-size: 15px; }
    .editor-content pre.code-block { font-size: 12px; padding: 12px; }
}

@media (max-width: 480px) {
    .editor-content {
        min-height: 180px;
        max-height: 400px;
        padding: 10px 12px;
        font-size: 14px;
    }
    
    .toolbar-btn {
        width: 26px;
        height: 26px;
    }
    
    .toolbar-btn span {
        font-size: 11px !important;
    }
}

/* ===== Toast Notifications ===== */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 380px;
}

.toast {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
    animation: toastSlideIn 0.3s ease-out;
    transition: all 0.3s ease;
}

.toast-hiding {
    animation: toastSlideOut 0.3s ease-in forwards;
}

.toast-icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
}

.toast-success .toast-icon {
    background: rgba(34, 197, 94, 0.15);
    color: var(--success);
}

.toast-error .toast-icon {
    background: rgba(239, 68, 68, 0.15);
    color: var(--error);
}

.toast-warning .toast-icon {
    background: rgba(245, 158, 11, 0.15);
    color: var(--warning);
}

.toast-info .toast-icon {
    background: rgba(59, 130, 246, 0.15);
    color: var(--info);
}

.toast-message {
    flex: 1;
    font-size: 14px;
    color: var(--text-primary);
    line-height: 1.4;
}

.toast-close {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    background: transparent;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
}

.toast-close:hover {
    background: var(--surface-3);
    color: var(--text-primary);
}

@keyframes toastSlideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes toastSlideOut {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* ===== Modal Dialog ===== */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    animation: modalFadeIn 0.2s ease-out;
}

.modal-hiding {
    animation: modalFadeOut 0.2s ease-in forwards;
}

.modal-dialog {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    width: 90%;
    max-width: 420px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: modalScaleIn 0.2s ease-out;
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px 0;
}

.modal-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
}

.modal-close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    background: transparent;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
}

.modal-close:hover {
    background: var(--surface-3);
    color: var(--text-primary);
}

.modal-body {
    padding: 20px 24px;
}

.modal-message {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding: 0 24px 20px;
}

.modal-footer .btn {
    min-width: 80px;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes modalFadeOut {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}

@keyframes modalScaleIn {
    from {
        transform: scale(0.95);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

/* ===== Responsive ===== */
@media (max-width: 480px) {
    .toast-container {
        top: 12px;
        right: 12px;
        left: 12px;
        max-width: none;
    }
    
    .modal-dialog {
        width: 95%;
    }
    
    /* 评论区适配 */
    .comment-item {
        gap: 8px;
    }
    
    .comment-avatar {
        width: 32px;
        height: 32px;
        margin-right: 8px;
    }
    
    .comment-author {
        font-size: 13px;
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        gap: 4px;
    }
    
    .admin-badge,
    .author-badge {
        margin-left: 0;
        font-size: 9px;
        padding: 1px 5px;
    }
    
    .comment-text {
        font-size: 13px;
    }
    
    .comment-meta {
        flex-wrap: wrap;
        gap: 8px;
    }
    
    /* 帖子列表作者名适配 */
    .post-meta-item {
        display: inline-flex;
        align-items: center;
        flex-wrap: nowrap;
    }
    
    /* 帖子详情作者名适配 */
    .post-author-name {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        gap: 6px;
    }
    
    /* 帖子详情页适配 */
    .post-detail-title {
        font-size: 20px;
        line-height: 1.4;
    }
    
    .post-detail-meta {
        flex-direction: column;
        gap: 8px;
        align-items: flex-start;
    }
    
    .post-detail-meta > div:last-child {
        margin-left: 0 !important;
        flex-wrap: wrap;
        gap: 8px;
    }
    
    .post-author-avatar {
        width: 36px;
        height: 36px;
    }
    
    .post-detail-content {
        font-size: 14px;
        line-height: 1.7;
    }
    
    .post-detail-content pre {
        font-size: 12px;
        padding: 12px;
        overflow-x: auto;
    }
    
    .post-detail-content h3 {
        font-size: 16px;
    }
    
    /* 投票区域适配 */
    .post-detail + div[style*="display: flex"] {
        flex-wrap: wrap;
        gap: 12px !important;
        padding: 12px !important;
    }
    
    .vote-btn {
        width: 32px !important;
        height: 32px !important;
    }
    
    /* 帖子操作按钮适配 */
    .post-actions {
        padding: 12px;
        gap: 8px;
    }
    
    .action-btn {
        flex: 1;
        justify-content: center;
        padding: 8px 12px;
        font-size: 13px;
    }
    
    .action-btn svg {
        width: 16px;
        height: 16px;
    }
    
    /* 评论区标题适配 */
    .comments-header {
        font-size: 16px;
    }
    
    /* 评论输入框适配 */
    .comments-section textarea {
        font-size: 14px;
        min-height: 80px;
    }
    
    .comments-section .btn-primary {
        width: 100%;
    }
    
    /* 面包屑适配 */
    .breadcrumb {
        font-size: 12px;
        flex-wrap: wrap;
    }
}

/* ===== 更小屏幕适配 ===== */
@media (max-width: 360px) {
    .container {
        padding: 0 12px;
    }
    
    .post-detail-title {
        font-size: 18px;
    }
    
    .comment-avatar {
        width: 28px;
        height: 28px;
    }
    
    .comment-text {
        font-size: 12px;
    }
    
    .comment-meta {
        font-size: 10px;
    }
    
    .comment-like-btn {
        font-size: 10px;
        padding: 2px 4px;
    }
    
    .comment-like-btn svg {
        width: 10px;
        height: 10px;
    }
}
