/* Minecraft 主题样式 - 赏金阁 */

:root {
    --primary-color: #2a2a2a;
    --secondary-color: #3a3a3a;
    --accent-color: #3b82f6;
    --accent-hover: #2563eb;
    --text-primary: #e0e0e0;
    --text-secondary: #a0a0a0;
    --text-accent: #3b82f6;
    --border-color: #4a4a4a;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.5);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans SC', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: var(--primary-color);
    background-image: url('/images/background.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    background-color: #1a1a1a;
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* 导航栏 */
.navbar {
    background-color: rgba(42, 42, 42, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 2px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.nav-brand h1 {
    color: var(--text-accent);
    font-size: 28px;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav-link {
    color: var(--text-primary);
    text-decoration: none;
    padding: 10px 20px;
    border-radius: 5px;
    transition: var(--transition);
    font-weight: 500;
    position: relative;
}

.nav-link:hover {
    color: var(--text-accent);
    background-color: var(--secondary-color);
    transform: translateY(-2px);
}

.nav-link.active {
    color: var(--text-accent);
    background-color: var(--secondary-color);
}

/* 主内容区域 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
    flex: 1;
}

.page {
    display: none;
    animation: fadeIn 0.5s ease;
}

.page.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    padding-bottom: 20px;
    border-bottom: 2px solid var(--border-color);
}

.page-header h2 {
    color: var(--text-accent);
    font-size: 32px;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

/* 按钮样式 */
.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    transition: var(--transition);
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.btn-primary {
    background-color: var(--accent-color);
    color: white;
    border: 2px solid var(--accent-color);
}

.btn-primary:hover {
    background-color: var(--accent-hover);
    border-color: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: var(--text-primary);
    border: 2px solid var(--border-color);
}

.btn-secondary:hover {
    background-color: var(--border-color);
    transform: translateY(-2px);
}

.btn-danger {
    background-color: #a33;
    color: white;
    border: 2px solid #a33;
}

.btn-danger:hover {
    background-color: #c55;
    border-color: #c55;
}

.btn-block {
    width: 100%;
}

.btn-small {
    padding: 6px 12px;
    font-size: 14px;
}

.btn-link {
    padding: 4px 8px;
    font-size: 13px;
    background: none;
    border: none;
    cursor: pointer;
    text-decoration: none;
}

/* 整合包网格 */
.modpacks-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 25px;
    margin-top: 20px;
}

.modpack-card {
    background-color: var(--secondary-color);
    border: 2px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    transition: var(--transition);
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.modpack-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: var(--accent-color);
}

.modpack-image {
    width: 100%;
    height: 180px;
    object-fit: cover;
    background-color: var(--primary-color);
    border-bottom: 2px solid var(--border-color);
}

.modpack-content {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.modpack-title {
    color: var(--text-accent);
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 12px;
    line-height: 1.3;
}

.modpack-description {
    color: var(--text-secondary);
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 15px;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex-grow: 1;
}

.modpack-actions {
    display: flex;
    gap: 10px;
    margin-top: auto;
    padding-top: 15px;
    border-top: 1px solid var(--border-color);
}

.admin-actions {
    position: absolute;
    top: 12px;
    right: 12px;
    display: flex;
    gap: 8px;
    z-index: 10;
}

.admin-actions .btn {
    padding: 6px 12px;
    font-size: 13px;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.admin-actions .btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.3);
}

/* 成员网格 */
.members-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 20px;
    align-items: stretch;
}

.member-card {
    background: linear-gradient(45deg, #56D8F5, #7ADF8);
    border: 2px solid var(--border-color);
    border-radius: 15px;
    padding: 30px 20px;
    text-align: center;
    transition: var(--transition);
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.member-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: var(--accent-color);
}

.member-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    margin: 0 auto 20px;
    border: 4px solid var(--accent-color);
    background-color: var(--primary-color);
    transition: var(--transition);
}

.member-card:hover .member-avatar {
    border-color: var(--accent-hover);
    transform: scale(1.05);
}

.member-name {
    color: #FFD700;
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 8px;
    letter-spacing: 0.5px;
}

.member-role {
    color: white;
    font-size: 15px;
    margin-bottom: 15px;
    font-weight: 500;
    text-shadow: -1px -1px 0 black, 1px -1px 0 black, -1px 1px 0 black, 1px 1px 0 black;
}

.member-description {
    color: white;
    font-size: 14px;
    line-height: 1.6;
    margin-top: 10px;
    padding-top: 15px;
    border-top: 1px solid var(--border-color);
    width: 100%;
    text-shadow: -1px -1px 0 black, 1px -1px 0 black, -1px 1px 0 black, 1px 1px 0 black;
}

/* 留言板 */
.messages-container {
    max-width: 800px;
    margin: 0 auto;
}

.messages-list {
    margin-bottom: 40px;
}

.message-item {
    background: linear-gradient(112deg, #217B9C, #340D8E);
    border: 2px solid var(--border-color);
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
    transition: var(--transition);
}

.message-item:hover {
    border-color: var(--accent-color);
}

.message-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.message-author {
    color: #ffffff;
    font-weight: 700;
}

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

.message-content {
    color: var(--text-primary);
    line-height: 1.6;
}

.message-form-container {
    border: 2px solid var(--border-color);
    border-radius: 10px;
    padding: 30px;
}

.login-prompt {
    text-align: center;
    padding: 40px;
    background-color: var(--secondary-color);
    border: 2px solid var(--border-color);
    border-radius: 10px;
}

.login-prompt p {
    margin-bottom: 20px;
    font-size: 18px;
}

/* 认证表单 */
.auth-container {
    max-width: 400px;
    margin: 0 auto;
    background-color: var(--secondary-color);
    border: 2px solid var(--border-color);
    border-radius: 10px;
    padding: 30px;
}

.auth-tabs {
    display: flex;
    margin-bottom: 30px;
    border-bottom: 2px solid var(--border-color);
}

.tab-btn {
    flex: 1;
    padding: 15px;
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.tab-btn.active {
    color: var(--text-accent);
    border-bottom: 2px solid var(--accent-color);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    color: var(--text-primary);
    font-weight: 500;
}

.form-control {
    width: 100%;
    padding: 12px;
    background-color: var(--primary-color);
    border: 2px solid var(--border-color);
    border-radius: 5px;
    color: var(--text-primary);
    font-size: 16px;
    transition: var(--transition);
}

.form-control:focus {
    outline: none;
    border-color: var(--accent-color);
}

/* 个人中心 */
.profile-container {
    max-width: 600px;
    margin: 0 auto;
    background-color: var(--secondary-color);
    border: 2px solid var(--border-color);
    border-radius: 10px;
    padding: 30px;
}

.profile-info {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid var(--border-color);
}

.profile-info p {
    margin-bottom: 10px;
}

/* 模态框 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    z-index: 2000;
}

.modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background-color: var(--secondary-color);
    border: 2px solid var(--border-color);
    border-radius: 10px;
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 2px solid var(--border-color);
}

.modal-header h3 {
    color: var(--text-accent);
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 24px;
    cursor: pointer;
    transition: var(--transition);
}

.modal-close:hover {
    color: var(--accent-color);
}

.modal-body {
    padding: 20px;
}

/* 主题切换器 */
.theme-switcher {
    display: flex;
    align-items: center;
}

.theme-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--accent-color);
    border: 2px solid var(--border-color);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 20px;
    transition: var(--transition);
    padding: 0;
}

.theme-btn:hover {
    transform: scale(1.1);
    border-color: var(--accent-color);
}

/* 主题变量 */
body.theme-hell {
    --primary-color: #2a0000;
    --secondary-color: #3a0000;
    --accent-color: #ff4500;
    --accent-hover: #ff6347;
    --text-primary: #ffd4d4;
    --text-secondary: #ff9999;
    --text-accent: #ff4500;
    --border-color: #8b0000;
    --shadow: 0 4px 6px rgba(139, 0, 0, 0.3);
    --shadow-lg: 0 10px 25px rgba(139, 0, 0, 0.5);
}

body.theme-end {
    --primary-color: #0a0020;
    --secondary-color: #1a0030;
    --accent-color: #8a2be2;
    --accent-hover: #9d4edd;
    --text-primary: #e6d4ff;
    --text-secondary: #b999ff;
    --text-accent: #8a2be2;
    --border-color: #4b0082;
    --shadow: 0 4px 6px rgba(75, 0, 130, 0.3);
    --shadow-lg: 0 10px 25px rgba(75, 0, 130, 0.5);
}

body.theme-ocean {
    --primary-color: #001a2a;
    --secondary-color: #002a3a;
    --accent-color: #00ced1;
    --accent-hover: #48d1cc;
    --text-primary: #d4f8ff;
    --text-secondary: #99e6ff;
    --text-accent: #00ced1;
    --border-color: #008b8b;
    --shadow: 0 4px 6px rgba(0, 139, 139, 0.3);
    --shadow-lg: 0 10px 25px rgba(0, 139, 139, 0.5);
}

/* 粒子背景 */
.particle-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
    display: none; /* 默认隐藏 */
}

#home-page.active .particle-canvas {
    display: block; /* 只在首页显示 */
}

/* 页脚 */
.footer {
    background-color: var(--secondary-color);
    border-top: 2px solid var(--border-color);
    padding: 20px;
    text-align: center;
    margin-top: auto;
}

.footer p {
    color: var(--text-secondary);
}

/* 审核管理 */
.review-section {
    margin-top: 30px;
}

.review-section h3 {
    color: var(--text-accent);
    margin-bottom: 20px;
    font-size: 24px;
}

.pending-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
    gap: 20px;
}

.pending-item {
    background-color: var(--secondary-color);
    border: 2px solid var(--border-color);
    border-radius: 10px;
    padding: 20px;
    position: relative;
    transition: var(--transition);
}

.pending-item:hover {
    border-color: var(--accent-color);
    transform: translateY(-3px);
    box-shadow: var(--shadow);
}

.pending-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-color);
}

.pending-title {
    color: var(--text-accent);
    font-size: 18px;
    font-weight: 700;
}

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

.pending-content {
    margin-bottom: 15px;
}

.pending-description {
    color: var(--text-secondary);
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 10px;
}

.pending-link {
    font-size: 13px;
    color: var(--accent-color);
    word-break: break-all;
}

.pending-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

.pending-actions .btn {
    padding: 8px 16px;
    font-size: 14px;
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .modpacks-grid {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
        gap: 20px;
    }
    
    .members-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 25px;
    }
    
    .pending-list {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .nav-container {
        flex-direction: column;
        height: auto;
        padding: 15px;
    }
    
    .nav-menu {
        margin-top: 15px;
        gap: 15px;
    }
    
    .modpacks-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
        gap: 20px;
    }
    
    .members-grid {
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
        gap: 20px;
    }
    
    .container {
        padding: 20px 15px;
    }
    
    .page-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .modal-content {
        width: 95%;
        margin: 20px;
    }
    
    .member-avatar {
        width: 100px;
        height: 100px;
    }
    
    .modpack-image {
        height: 160px;
    }
}

@media (max-width: 480px) {
    .nav-menu {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .nav-link {
        padding: 8px 12px;
        font-size: 14px;
    }
    
    .modpacks-grid {
        grid-template-columns: 1fr;
    }
    
    .members-grid {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    }
    
    .member-avatar {
        width: 80px;
        height: 80px;
    }
    
    .modpack-card, .member-card {
        border-width: 1px;
    }
    
    .admin-actions {
        position: static;
        margin-top: 10px;
        justify-content: center;
    }
    
    .admin-actions .btn {
        font-size: 12px;
        padding: 4px 8px;
    }
}

@media (min-width: 1200px) {
    .modpacks-grid {
        grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    }
    
    .members-grid {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    }
}

/* 整合包评论面板 */
.modpack-detail-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 1500;
    display: none;
}

.modpack-detail-panel {
    position: fixed;
    top: 0;
    right: -100%;
    width: 400px;
    height: 100vh;
    background-color: var(--secondary-color);
    border-left: 2px solid var(--border-color);
    z-index: 1501;
    transition: right 0.3s ease;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.modpack-detail-panel.active {
    right: 0;
}

.panel-header {
    padding: 20px;
    border-bottom: 2px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    background-color: var(--secondary-color);
    z-index: 10;
}

.panel-title {
    color: var(--text-accent);
    font-size: 20px;
    font-weight: 700;
}

.panel-close {
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 24px;
    cursor: pointer;
    transition: var(--transition);
}

.panel-close:hover {
    color: var(--accent-color);
}

.panel-content {
    flex: 1;
    padding: 20px;
}

.modpack-detail-info {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
}

.modpack-detail-image {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 15px;
}

.modpack-detail-title {
    color: var(--text-accent);
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 10px;
}

.modpack-detail-description {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 15px;
}

.modpack-detail-meta {
    font-size: 14px;
    color: var(--text-secondary);
}

.comments-section {
    margin-top: 30px;
}

.comments-title {
    color: var(--text-accent);
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 20px;
}

.comment-form {
    margin-bottom: 30px;
    padding: 15px;
    background-color: var(--primary-color);
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.comment-textarea {
    width: 100%;
    min-height: 80px;
    padding: 12px;
    background-color: var(--primary-color);
    border: 2px solid var(--border-color);
    border-radius: 5px;
    color: var(--text-primary);
    font-size: 14px;
    resize: vertical;
    margin-bottom: 10px;
}

.comment-textarea:focus {
    outline: none;
    border-color: var(--accent-color);
}

.comment-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.comment-item {
    padding: 15px;
    background-color: var(--primary-color);
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.comment-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.comment-author {
    color: #ffffff;
    font-weight: 700;
    font-size: 14px;
}

.comment-time {
    color: var(--text-secondary);
    font-size: 12px;
}

.comment-content {
    color: var(--text-primary);
    line-height: 1.5;
    font-size: 14px;
}

.no-comments {
    text-align: center;
    color: var(--text-secondary);
    padding: 40px 20px;
    font-style: italic;
}

@media (max-width: 768px) {
    .modpack-detail-panel {
        width: 100%;
        right: -100%;
    }
}

/* AI聊天机器人 */
.chatbot-container {
    position: fixed;
    bottom: 120px;
    right: 20px;
    z-index: 3000;
}

.chatbot-toggle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: #00FF00;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
    padding: 0;
    overflow: hidden;
}

.chatbot-toggle img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.chatbot-toggle:hover {
    transform: scale(1.1);
    background-color: var(--accent-hover);
}

.chatbot-window {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 350px;
    height: 500px;
    background-color: var(--secondary-color);
    border: 2px solid var(--border-color);
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    display: none;
    flex-direction: column;
    overflow: hidden;
}

.chatbot-window.active {
    display: flex;
}

.chatbot-header {
    padding: 15px;
    background-color: #00FF00;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chatbot-title {
    font-weight: 700;
    font-size: 16px;
}

.chatbot-close {
    background: none;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
}

.chatbot-messages {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.message {
    max-width: 80%;
    padding: 10px 15px;
    border-radius: 18px;
    font-size: 14px;
    line-height: 1.4;
}

.message.bot {
    align-self: flex-start;
    background-color: var(--primary-color);
    border: 1px solid var(--border-color);
}

.message.user {
    align-self: flex-end;
    background-color: var(--accent-color);
    color: white;
}

.chatbot-input-container {
    padding: 15px;
    border-top: 1px solid var(--border-color);
    display: flex;
    gap: 10px;
}

.chatbot-input {
    flex: 1;
    padding: 10px;
    background-color: var(--primary-color);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    color: var(--text-primary);
    font-size: 14px;
}

.chatbot-input:focus {
    outline: none;
    border-color: var(--accent-color);
}

.chatbot-send {
    background-color: #3b82f6;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 18px;
}

.chatbot-send:hover {
    background-color: #2563eb;
}

/* 居中确认对话框 */
.center-confirm-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

.center-confirm-modal.active {
    display: flex;
}

.confirm-dialog {
    background-color: var(--secondary-color);
    border: 2px solid var(--border-color);
    border-radius: 12px;
    padding: 30px;
    max-width: 400px;
    width: 90%;
    text-align: center;
    box-shadow: var(--shadow-lg);
}

.confirm-dialog h3 {
    color: var(--text-accent);
    margin-bottom: 20px;
    font-size: 20px;
}

.confirm-dialog p {
    color: var(--text-primary);
    margin-bottom: 25px;
    line-height: 1.5;
}

.confirm-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.confirm-buttons .btn {
    min-width: 80px;
}

/* 野史趣事样式 */
.stories-list {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.story-item {
    background: linear-gradient(45deg, rgba(255, 168, 115, 0.68), rgba(255, 49, 107, 0.82));
    border: 2px solid var(--border-color);
    border-radius: 12px;
    padding: 25px;
    transition: var(--transition);
    position: relative;
}

.story-item:hover {
    border-color: var(--accent-color);
    transform: translateY(-3px);
    box-shadow: var(--shadow);
}

.story-header {
    margin-bottom: 20px;
}

.story-title {
    color: #3b82f6;
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 12px;
    line-height: 1.3;
}

.story-meta {
    display: flex;
    gap: 20px;
    align-items: center;
    flex-wrap: wrap;
    font-size: 14px;
    color: var(--text-secondary);
}

.story-heat {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-weight: bold;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        text-shadow: 0 0 5px rgba(255, 69, 0, 0.5);
    }
    50% {
        transform: scale(1.1);
        text-shadow: 0 0 15px rgba(255, 69, 0, 0.8);
    }
    100% {
        transform: scale(1);
        text-shadow: 0 0 5px rgba(255, 69, 0, 0.5);
    }
}

.story-author {
    color: #ffffff;
    font-weight: 500;
}

.story-time {
    font-style: italic;
}

.story-views, .story-likes {
    display: flex;
    align-items: center;
    gap: 5px;
}

.story-image {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    border-radius: 8px;
    margin: 20px 0;
    border: 1px solid var(--border-color);
}

.story-content {
    color: var(--text-primary);
    line-height: 1.8;
    font-size: 16px;
    white-space: pre-wrap;
    word-wrap: break-word;
}

.story-content:empty {
    display: none;
}

.story-actions {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

/* 文章详情页样式 */
.story-detail-container {
    max-width: 800px;
    margin: 0 auto;
    background-color: var(--secondary-color);
    border: 2px solid var(--border-color);
    border-radius: 12px;
    padding: 30px;
}

.story-detail-header {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid var(--border-color);
}

.story-detail-header h2 {
    color: var(--text-accent);
    font-size: 28px;
    margin-bottom: 15px;
}

.story-detail-image {
    width: 100%;
    max-height: 500px;
    object-fit: cover;
    border-radius: 8px;
    margin: 25px 0;
    border: 1px solid var(--border-color);
}

.story-detail-content {
    color: var(--text-primary);
    line-height: 1.8;
    font-size: 17px;
    white-space: pre-wrap;
    word-wrap: break-word;
    margin-bottom: 30px;
}

.story-detail-actions {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

/* 评论区样式 */
.comments-section {
    margin-top: 30px;
}

.comments-section h3 {
    color: var(--text-accent);
    font-size: 24px;
    margin-bottom: 20px;
}

.comment-form {
    background-color: var(--primary-color);
    border: 2px solid var(--border-color);
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 30px;
}

.comment-form h4 {
    color: var(--text-accent);
    margin-bottom: 15px;
}

.comment-form textarea {
    width: 100%;
    min-height: 100px;
    padding: 12px;
    background-color: var(--secondary-color);
    border: 2px solid var(--border-color);
    border-radius: 5px;
    color: var(--text-primary);
    font-size: 14px;
    resize: vertical;
    margin-bottom: 15px;
}

.comment-form-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
}

.comment-item {
    background-color: var(--primary-color);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
}

.comment-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
}

.comment-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--accent-color);
}

.comment-info {
    flex: 1;
}

.comment-author {
    color: #ffffff;
    font-weight: 700;
    font-size: 14px;
}

.comment-time {
    color: var(--text-secondary);
    font-size: 12px;
}

.comment-content {
    color: var(--text-primary);
    line-height: 1.6;
    margin-bottom: 10px;
}

.comment-image {
    max-width: 100%;
    max-height: 300px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    margin-top: 10px;
}

.admin-badge {
    background-color: var(--accent-color);
    color: white;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
    margin-left: 10px;
}

/* 右侧浮动按钮 */
.floating-buttons {
    position: fixed;
    right: 450px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 999;
}

/* 文章详情页的导航按钮 */
.floating-buttons.article-nav {
    right: 450px !important;
}

/* 音乐控制按钮 */
.music-control-btn {
    position: fixed;
    bottom: 200px;
    right: 20px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: var(--accent-color);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
    padding: 0;
    overflow: hidden;
    z-index: 3000;
}

.music-control-btn img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.music-control-btn:hover {
    transform: scale(1.1);
}

/* 旋转动画 */
@keyframes rotate {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.rotating {
    animation: rotate 4s linear infinite;
}

.paused {
    animation-play-state: paused;
}

.floating-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: var(--accent-color);
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
    box-shadow: var(--shadow);
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.floating-btn:hover {
    background-color: var(--accent-hover);
    transform: scale(1.1);
}

@media (max-width: 768px) {
    .floating-buttons {
        right: 10px;
        gap: 8px;
    }
    
    .floating-btn {
        width: 45px;
        height: 45px;
        font-size: 18px;
    }
}

/* Emoji按钮样式 */
.emoji-btn {
    position: absolute;
    bottom: 15px;
    right: 15px;
    background: transparent;
    border: none;
    font-size: 20px;
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    transition: var(--transition);
    opacity: 0.7;
}

.emoji-btn:hover {
    opacity: 1;
    background-color: rgba(255, 255, 255, 0.1);
}

/* Emoji浮窗选择器 */
.emoji-floating-picker {
    position: absolute;
    background-color: var(--secondary-color);
    border: 2px solid var(--border-color);
    border-radius: 10px;
    box-shadow: var(--shadow-lg);
    z-index: 1000;
    padding: 10px;
    max-width: 320px;
    max-height: 250px;
    overflow-y: auto;
    bottom: 100%;
    right: 0;
    margin-bottom: 5px;
}

.emoji-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 8px;
}

.emoji-item {
    font-size: 22px;
    cursor: pointer;
    padding: 4px;
    border-radius: 5px;
    text-align: center;
    transition: var(--transition);
    user-select: none;
}

.emoji-item:hover {
    background-color: var(--primary-color);
    transform: scale(1.2);
}

@media (max-width: 768px) {
    .emoji-floating-picker {
        max-width: 280px;
        max-height: 200px;
        padding: 8px;
    }
    
    .emoji-grid {
        grid-template-columns: repeat(6, 1fr);
        gap: 6px;
    }
    
    .emoji-item {
        font-size: 20px;
        padding: 3px;
    }
}

/* 成功提示 */
.success-toast {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.success-toast.show {
    opacity: 1;
    visibility: visible;
}

.success-content {
    background-color: var(--secondary-color);
    border: 2px solid var(--border-color);
    border-radius: 12px;
    padding: 30px 40px;
    text-align: center;
    box-shadow: var(--shadow-lg);
    transform: scale(0.8);
    transition: transform 0.3s ease;
    min-width: 280px;
    max-width: 400px;
}

.success-toast.show .success-content {
    transform: scale(1);
}

.success-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: white;
    margin: 0 auto 20px;
}

/* 成功类型（绿色） */
.success-toast.toast-success .success-icon {
    background-color: #4ade80;
    box-shadow: 0 4px 10px rgba(74, 222, 128, 0.3);
}

/* 错误类型（红色） */
.success-toast.toast-error .success-icon {
    background-color: #e94560;
    box-shadow: 0 4px 10px rgba(233, 69, 96, 0.3);
}

/* 警告类型（橙色） */
.success-toast.toast-warning .success-icon {
    background-color: #f0a500;
    box-shadow: 0 4px 10px rgba(240, 165, 0, 0.3);
}

.success-message {
    color: var(--text-primary);
    font-size: 16px;
    font-weight: 500;
    margin-bottom: 20px;
    line-height: 1.5;
    word-break: break-word;
}

.toast-close-btn {
    background: var(--primary-color);
    color: var(--text-primary);
    border: none;
    border-radius: 6px;
    padding: 8px 32px;
    font-size: 14px;
    cursor: pointer;
    transition: opacity 0.2s;
}

.toast-close-btn:hover {
    opacity: 0.8;
}

@media (max-width: 768px) {
    .success-content {
        padding: 20px 30px;
        margin: 20px;
    }
    
    .success-icon {
        width: 50px;
        height: 50px;
        font-size: 28px;
    }
    
    .success-message {
        font-size: 16px;
    }
}

/* ==================== 珍宝阁样式 ==================== */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 16px;
    padding: 10px;
}

.gallery-item {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
}

.gallery-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.gallery-item-img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
    background: var(--secondary-color);
}

.gallery-item-video {
    width: 100%;
    height: 220px;
    object-fit: cover;
    background: #000;
}

.gallery-item-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.85));
    padding: 30px 12px 12px;
    color: #fff;
}

.gallery-item-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.gallery-item-meta {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.7);
    display: flex;
    align-items: center;
    gap: 10px;
}

.gallery-item-play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 50px;
    height: 50px;
    background: rgba(0, 0, 0, 0.6);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    pointer-events: none;
}

/* 珍宝阁详情页 */
.gallery-detail-container {
    display: flex;
    gap: 24px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    min-height: calc(100vh - 200px);
}

.gallery-detail-left {
    flex: 1;
    min-width: 0;
    position: sticky;
    top: 80px;
    align-self: flex-start;
}

.gallery-detail-image-wrap {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    background: #000;
    text-align: center;
}

.gallery-detail-image-wrap img {
    max-width: 100%;
    max-height: 75vh;
    object-fit: contain;
    display: block;
    margin: 0 auto;
}

.gallery-detail-image-wrap video {
    max-width: 100%;
    max-height: 75vh;
}

.gallery-detail-info {
    padding: 16px 0;
}

.gallery-detail-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.gallery-detail-description {
    color: var(--text-secondary);
    font-size: 14px;
    line-height: 1.6;
    white-space: pre-wrap;
}

.gallery-detail-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-top: 12px;
    font-size: 13px;
    color: var(--text-muted);
}

.gallery-detail-meta img {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    vertical-align: middle;
}

/* 珍宝阁右侧评论区 */
.gallery-detail-right {
    width: 360px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    max-height: calc(100vh - 120px);
    position: sticky;
    top: 80px;
}

.gallery-comments-header {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.gallery-comments-list {
    flex: 1;
    overflow-y: auto;
    padding-right: 4px;
}

.gallery-comment-item {
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.gallery-comment-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.gallery-comment-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
}

.gallery-comment-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-accent);
}

.gallery-comment-time {
    font-size: 11px;
    color: var(--text-muted);
    margin-left: auto;
}

.gallery-comment-content {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.5;
    padding-left: 36px;
}

.gallery-comment-delete {
    font-size: 11px;
    color: var(--text-muted);
    cursor: pointer;
    margin-left: auto;
    opacity: 0;
    transition: opacity 0.2s;
}

.gallery-comment-item:hover .gallery-comment-delete {
    opacity: 1;
}

.gallery-comment-delete:hover {
    color: #ef4444;
}

.gallery-comment-reply-trigger {
    font-size: 11px;
    color: var(--text-muted);
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.2s;
    margin-left: 8px;
}

.gallery-comment-item:hover .gallery-comment-reply-trigger {
    opacity: 1;
}

.gallery-comment-reply-trigger:hover {
    color: var(--text-accent);
}

/* 嵌套回复 */
.gallery-comment-replies {
    margin-left: 36px;
    padding-left: 12px;
    border-left: 2px solid rgba(255, 255, 255, 0.08);
}

/* 评论输入框 */
.gallery-comment-input-wrap {
    padding-top: 12px;
    border-top: 1px solid var(--border-color);
    margin-top: 12px;
}

.gallery-comment-input-wrap textarea {
    width: 100%;
    min-height: 60px;
    padding: 10px 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--secondary-color);
    color: var(--text-primary);
    font-size: 13px;
    resize: vertical;
    font-family: inherit;
    outline: none;
    transition: border-color 0.2s;
    box-sizing: border-box;
}

.gallery-comment-input-wrap textarea:focus {
    border-color: var(--primary-color);
}

.gallery-comment-input-wrap .btn-row {
    display: flex;
    justify-content: flex-end;
    margin-top: 8px;
}

/* 上传/申请弹窗 */
.gallery-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3000;
}

.gallery-modal {
    background: var(--secondary-color);
    border: 2px solid var(--border-color);
    border-radius: 16px;
    padding: 30px;
    width: 480px;
    max-width: 90vw;
    max-height: 85vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.gallery-modal h3 {
    font-size: 20px;
    color: var(--text-primary);
    margin-bottom: 20px;
}

.gallery-modal label {
    display: block;
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 6px;
    font-weight: 600;
}

.gallery-modal input,
.gallery-modal textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--card-bg);
    color: var(--text-primary);
    font-size: 14px;
    outline: none;
    margin-bottom: 16px;
    box-sizing: border-box;
    font-family: inherit;
}

.gallery-modal input:focus,
.gallery-modal textarea:focus {
    border-color: var(--primary-color);
}

.gallery-modal textarea {
    min-height: 80px;
    resize: vertical;
}

.gallery-file-upload {
    border: 2px dashed var(--border-color);
    border-radius: 12px;
    padding: 30px;
    text-align: center;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
    margin-bottom: 16px;
}

.gallery-file-upload:hover {
    border-color: var(--primary-color);
    background: rgba(59, 130, 246, 0.05);
}

.gallery-file-upload.has-file {
    border-color: #22c55e;
    background: rgba(34, 197, 94, 0.08);
}

.gallery-file-upload .file-preview {
    max-width: 100%;
    max-height: 200px;
    border-radius: 8px;
    margin-top: 10px;
}

.gallery-modal-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

/* 响应式 */
@media (max-width: 768px) {
    .gallery-detail-container {
        flex-direction: column;
    }
    .gallery-detail-left {
        position: static;
    }
    .gallery-detail-right {
        width: 100%;
        position: static;
        max-height: none;
    }
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 10px;
    }
    .gallery-item-img,
    .gallery-item-video {
        height: 160px;
    }
}