/* JoyReactor 简洁版样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    background: #f5f5f5;
    color: #333;
    line-height: 1.6;
}

/* 容器 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 导航栏 */
.navbar {
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 60px;
    gap: 20px;
}

.nav-logo {
    font-size: 24px;
    font-weight: bold;
    color: #ff4500;
    text-decoration: none;
    white-space: nowrap;
}

.nav-search {
    flex: 1;
    max-width: 400px;
}

.nav-search form {
    display: flex;
    gap: 5px;
}

.nav-search input {
    flex: 1;
    padding: 8px 15px;
    border: 1px solid #ddd;
    border-radius: 20px;
    outline: none;
    font-size: 14px;
}

.nav-search button {
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    padding: 0 10px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 15px;
}

.nav-link {
    color: #666;
    text-decoration: none;
    font-size: 14px;
}

.nav-link:hover {
    color: #ff4500;
}

.nav-avatar img {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #fff;
    box-shadow: 0 0 0 1px rgba(0,0,0,0.1);
}

/* 主内容布局 */
.main-content {
    display: flex;
    gap: 30px;
    margin-top: 30px;
    align-items: flex-start;
}

/* 侧边栏 */
.sidebar {
    width: 250px;
    flex-shrink: 0;
}

.sidebar-section {
    background: #fff;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.sidebar-section h3 {
    font-size: 16px;
    margin-bottom: 15px;
    color: #333;
}

.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag {
    display: inline-block;
    padding: 4px 12px;
    background: #f0f0f0;
    color: #666;
    text-decoration: none;
    border-radius: 15px;
    font-size: 13px;
    transition: all 0.2s;
}

.tag:hover {
    background: #ff4500;
    color: #fff;
}

.tag-active {
    background: #ff4500;
    color: #fff;
}

.tag-small {
    font-size: 12px;
    padding: 3px 10px;
}

.tag-count {
    font-size: 11px;
    opacity: 0.7;
}

.sidebar-menu {
    list-style: none;
}

.sidebar-menu li {
    margin-bottom: 10px;
}

.sidebar-menu a {
    color: #666;
    text-decoration: none;
    font-size: 14px;
}

.sidebar-menu a:hover {
    color: #ff4500;
}

/* 内容区 */
.content {
    flex: 1;
    min-width: 0;
}

/* 帖子网格 */
.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.post-card {
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    transition: transform 0.2s, box-shadow 0.2s;
}

.post-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.15);
}

.post-card .post-image-link {
    display: block;
    overflow: hidden;
    aspect-ratio: 1;
    background: #f0f0f0;
}

.post-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.post-card:hover img {
    transform: scale(1.05);
}

.post-info {
    padding: 15px;
}

.post-title {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 10px;
    line-height: 1.4;
}

.post-title a {
    color: #333;
    text-decoration: none;
}

.post-title a:hover {
    color: #ff4500;
}

.post-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    font-size: 13px;
    color: #999;
}

.post-author {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #666;
    text-decoration: none;
}

.post-author:hover {
    color: #ff4500;
}

.avatar-small {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    object-fit: cover;
}

.avatar-medium {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
}

.post-stats {
    display: flex;
    gap: 15px;
    font-size: 13px;
    color: #999;
    margin-bottom: 10px;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 3px;
}

.post-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

/* 帖子详情 */
.post-detail {
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

.post-image-container {
    text-align: center;
    background: #000;
    max-height: 600px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.post-full-image {
    max-width: 100%;
    max-height: 600px;
    object-fit: contain;
}

.post-content {
    padding: 30px;
}

.post-full-title {
    font-size: 24px;
    margin-bottom: 15px;
    line-height: 1.4;
}

.post-description {
    color: #666;
    margin-bottom: 15px;
    line-height: 1.8;
}

.post-tags-full {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.post-actions {
    display: flex;
    gap: 15px;
    padding: 20px 0;
    border-top: 1px solid #eee;
    border-bottom: 1px solid #eee;
    margin-bottom: 20px;
}

.action-btn {
    background: none;
    border: 1px solid #ddd;
    padding: 8px 20px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s;
    color: #666;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.action-btn:hover {
    border-color: #ff4500;
    color: #ff4500;
}

.action-btn.liked {
    background: #ff4500;
    color: #fff;
    border-color: #ff4500;
}

/* 首页帖子卡片点赞按钮 */
.like-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    font-size: inherit;
    color: inherit;
    display: inline-flex;
    align-items: center;
    gap: 3px;
}

.like-btn:hover {
    color: #ff4500;
}

.like-btn.liked {
    color: #ff4500;
}

.like-btn:disabled {
    cursor: not-allowed;
    opacity: 0.5;
}

.post-meta-full {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 20px;
}

.author-link {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #333;
    text-decoration: none;
}

.author-info strong {
    display: block;
    font-size: 16px;
}

.post-time-full {
    font-size: 13px;
    color: #999;
}

.post-stats-full {
    font-size: 14px;
    color: #999;
    display: flex;
    gap: 20px;
}

/* 评论区 */
.comments-section {
    background: #fff;
    border-radius: 8px;
    padding: 30px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.comments-section h2 {
    font-size: 20px;
    margin-bottom: 20px;
}

.comment-form {
    margin-bottom: 30px;
    padding-bottom: 30px;
    border-bottom: 1px solid #eee;
}

.comment-form-content {
    display: flex;
    gap: 12px;
    margin-bottom: 12px;
}

.comment-form textarea {
    flex: 1;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    resize: vertical;
    font-family: inherit;
    font-size: 14px;
}

.login-prompt {
    background: #f9f9f9;
    padding: 20px;
    text-align: center;
    border-radius: 8px;
    margin-bottom: 30px;
}

.login-prompt a {
    color: #ff4500;
    font-weight: 600;
}

.comment {
    padding: 20px 0;
    border-bottom: 1px solid #f0f0f0;
}

.comment:last-child {
    border-bottom: none;
}

.comment-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.comment-author {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #333;
    text-decoration: none;
    font-size: 14px;
}

.comment-author:hover {
    color: #ff4500;
}

.comment-time {
    font-size: 12px;
    color: #999;
}

.comment-content {
    color: #333;
    line-height: 1.6;
    margin-bottom: 10px;
    padding-left: 42px;
}

.comment-actions {
    display: flex;
    gap: 15px;
    padding-left: 42px;
    font-size: 13px;
}

.comment-actions button {
    background: none;
    border: none;
    cursor: pointer;
    color: #999;
    font-size: 13px;
}

.comment-actions button:hover {
    color: #ff4500;
}

.reply-form {
    margin-top: 15px;
    padding-left: 42px;
}

.reply-form textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 8px;
    resize: vertical;
    font-family: inherit;
    margin-bottom: 10px;
}

.replies {
    margin-top: 15px;
    padding-left: 42px;
}

.reply {
    padding: 15px 0;
    border-top: 1px solid #f0f0f0;
}

/* 表单样式 */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 14px;
    color: #333;
}

.required {
    color: #ff4500;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"],
.form-group textarea {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    transition: border-color 0.2s;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #ff4500;
}

.form-hint {
    font-size: 12px;
    color: #999;
    margin-top: 5px;
}

/* 上传区域 */
.upload-area {
    border: 2px dashed #ddd;
    border-radius: 8px;
    padding: 40px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
}

.upload-area:hover,
.upload-area.dragover {
    border-color: #ff4500;
    background: #fff5f0;
}

.upload-area input[type="file"] {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.upload-icon {
    font-size: 48px;
    display: block;
    margin-bottom: 10px;
}

.upload-hint {
    font-size: 12px;
    color: #999;
    margin-top: 10px;
}

.upload-preview {
    position: relative;
    display: inline-block;
}

.upload-preview img {
    max-width: 300px;
    max-height: 300px;
    border-radius: 8px;
}

.btn-remove {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0,0,0,0.5);
    color: #fff;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 16px;
}

/* 按钮 */
.btn {
    padding: 10px 25px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    display: inline-block;
    transition: all 0.2s;
    text-align: center;
}

.btn-primary {
    background: #ff4500;
    color: #fff;
}

.btn-primary:hover {
    background: #e63e00;
}

.btn-secondary {
    background: #f0f0f0;
    color: #666;
}

.btn-secondary:hover {
    background: #e0e0e0;
}

.btn-small {
    padding: 5px 15px;
    font-size: 13px;
}

.btn-lg {
    padding: 12px 40px;
    font-size: 16px;
}

.btn-block {
    display: block;
    width: 100%;
}

.form-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
}

/* 警告框 */
.alert {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.alert-error {
    background: #ffebee;
    color: #c62828;
    border: 1px solid #ffcdd2;
}

.alert-success {
    background: #e8f5e9;
    color: #2e7d32;
    border: 1px solid #c8e6c9;
}

/* 认证页面 */
.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f5f5f5;
}

.auth-box {
    background: #fff;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 450px;
}

.auth-title {
    text-align: center;
    font-size: 32px;
    color: #ff4500;
    margin-bottom: 10px;
}

.auth-subtitle {
    text-align: center;
    color: #999;
    margin-bottom: 30px;
}

.auth-links {
    text-align: center;
    margin-top: 20px;
    color: #666;
}

.auth-links a {
    color: #ff4500;
    text-decoration: none;
    font-weight: 600;
}

/* 验证码样式 */
.captcha-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.captcha-wrapper input[type="text"] {
    width: 120px;
    display: inline-block;
}

.captcha-wrapper img {
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
    height: 40px;
}

.captcha-wrapper a {
    font-size: 12px;
    color: #666;
    text-decoration: none;
}

.captcha-wrapper a:hover {
    color: #ff4500;
    text-decoration: underline;
}

.auth-demo {
    text-align: center;
    margin-top: 20px;
    color: #999;
    font-size: 13px;
}

/* 上传容器 */
.upload-container {
    max-width: 700px;
    margin: 0 auto;
    background: #fff;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.page-title {
    font-size: 24px;
    margin-bottom: 30px;
    text-align: center;
}

/* 分页 */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    padding: 30px 0;
}

.page-link {
    padding: 8px 20px;
    background: #fff;
    color: #666;
    text-decoration: none;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    transition: all 0.2s;
}

.page-link:hover {
    background: #ff4500;
    color: #fff;
}

.page-info {
    color: #999;
    font-size: 14px;
}

/* 页面头部 */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.page-header h2 {
    font-size: 20px;
}

/* 空状态 */
.empty-state,
.empty-comments {
    text-align: center;
    padding: 60px 20px;
    color: #999;
}

.empty-state a,
.empty-comments a {
    color: #ff4500;
    font-weight: 600;
}

/* 页脚 */
.footer {
    text-align: center;
    padding: 40px 20px;
    color: #999;
    font-size: 14px;
    margin-top: 60px;
}

/* 用户页面 */
.user-profile {
    background: #fff;
    border-radius: 8px;
    padding: 30px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

.user-header {
    display: flex;
    align-items: center;
    gap: 20px;
}

.user-avatar img {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
}

.user-info h1 {
    font-size: 24px;
    margin-bottom: 5px;
}

.user-info p {
    color: #999;
    margin-bottom: 10px;
}

.user-stats {
    display: flex;
    gap: 30px;
    margin-top: 20px;
}

.stat {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 20px;
    font-weight: bold;
    color: #333;
}

.stat-label {
    font-size: 13px;
    color: #999;
}

/* 响应式 */
@media (max-width: 768px) {
    .main-content {
        flex-direction: column;
    }
    
    .sidebar {
        width: 100%;
        order: 2;
    }
    
    .content {
        order: 1;
    }
    
    .posts-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 10px;
    }
    
    .nav-content {
        flex-wrap: wrap;
        height: auto;
        padding: 10px 0;
    }
    
    .nav-search {
        order: 3;
        max-width: 100%;
        width: 100%;
    }
}

/* 广告容器样式 */
.ad-container {
    margin: 20px 0;
    text-align: center;
    overflow: hidden;
}

.ad-header {
    margin-top: 0;
    padding-top: 10px;
}

.ad-sidebar {
    margin-top: 20px;
}

.ad-between-posts {
    grid-column: 1 / -1;
    margin: 20px auto;
}

.ad-post-content {
    margin: 30px 0;
    padding: 20px;
    background: #f9f9f9;
    border-radius: 8px;
}

.ad-footer {
    margin-bottom: 0;
    padding-bottom: 10px;
}

/* 举报弹窗样式 */
.modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.modal-content {
    background: #fff;
    border-radius: 12px;
    width: 400px;
    max-width: 90vw;
    overflow: hidden;
    box-shadow: 0 8px 30px rgba(0,0,0,0.3);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid #eee;
}

.modal-header h3 {
    margin: 0;
    font-size: 16px;
}

.modal-close {
    background: none;
    border: none;
    font-size: 22px;
    cursor: pointer;
    color: #999;
    line-height: 1;
}
.modal-close:hover {
    color: #333;
}

.modal-body {
    padding: 20px;
}

.modal-body .report-option {
    margin-bottom: 10px;
    font-size: 14px;
}

.modal-body .report-option label {
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}

.modal-body .report-option input[type="radio"] {
    accent-color: #ff4500;
}

.modal-body textarea {
    width: 100%;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 8px;
    font-size: 13px;
    resize: vertical;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 16px 20px;
    border-top: 1px solid #eee;
}

.modal-footer .btn {
    padding: 8px 20px;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
    border: none;
}

.modal-footer .btn-secondary {
    background: #eee;
    color: #333;
}
.modal-footer .btn-secondary:hover {
    background: #ddd;
}

.modal-footer .btn-primary {
    background: #ff4500;
    color: #fff;
}
.modal-footer .btn-primary:hover {
    background: #e03d00;
}

/* 举报按钮样式 */
.report-btn {
    background: none;
    border: 1px solid #ff4500;
    color: #ff4500;
    padding: 6px 14px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 13px;
}
.report-btn:hover {
    background: #fff5f0;
}
