/* 基础重置与全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Microsoft YaHei', 'Arial', sans-serif;
}

/* 动态海洋科技风背景 */
.bg-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #0a192f, #112940, #0f3460);
    overflow: hidden;
    z-index: -1;
}
.wave {
    position: absolute;
    width: 200%;
    height: 200%;
    border-radius: 45%;
    background: rgba(30, 136, 229, 0.1);
    animation: wave 20s linear infinite;
}
.wave:nth-child(1) {
    top: -150%;
    left: -50%;
    animation-duration: 15s;
}
.wave:nth-child(2) {
    top: -140%;
    left: -50%;
    animation-duration: 25s;
    animation-delay: 2s;
}
.wave:nth-child(3) {
    top: -130%;
    left: -50%;
    animation-duration: 20s;
    animation-delay: 5s;
}
.glow-point {
    position: absolute;
    width: 2px;
    height: 2px;
    background: rgba(100, 181, 246, 0.8);
    border-radius: 50%;
    animation: glow 3s infinite alternate;
}
@keyframes wave {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
@keyframes glow {
    0% { box-shadow: 0 0 5px rgba(100, 181, 246, 0.5); }
    100% { box-shadow: 0 0 15px rgba(100, 181, 246, 0.9); }
}

/* 头部导航 */
header {
    width: 100%;
    padding: 20px 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(10, 25, 47, 0.7);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(66, 165, 245, 0.3);
}
.logo {
    display: flex;
    align-items: center;
    gap: 15px;
}
.logo-img {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}
.logo-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.logo-text {
    color: #e3f2fd;
    font-size: 24px;
    font-weight: 700;
}
.nav-menu {
    display: flex;
    gap: 30px;
}
.nav-item {
    color: #bbdefb;
    text-decoration: none;
    font-size: 16px;
    padding: 8px 12px;
    border-radius: 6px;
    transition: all 0.3s ease;
    position: relative;
}
.nav-item:hover {
    color: #e3f2fd;
    background: rgba(66, 165, 245, 0.2);
}
.nav-item::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: #42a5f5;
    transition: width 0.3s ease;
}
.nav-item:hover::after {
    width: 100%;
}
.nav-item.active {
    color: #e3f2fd;
    background: rgba(66, 165, 245, 0.2);
}
.nav-item.active::after {
    width: 100%;
}
.mobile-menu-btn {
    display: none;
    font-size: 24px;
    color: #e3f2fd;
    background: none;
    border: none;
    cursor: pointer;
}

/* 页面主体样式 */
.knowledge-main {
    width: 90%;
    margin: 40px auto;
    padding-bottom: 80px;
}

/* 页面标题区 */
.knowledge-header {
    text-align: center;
    margin-bottom: 40px;
    padding: 20px 0;
}
.knowledge-title {
    color: #e3f2fd;
    font-size: 32px;
    margin-bottom: 15px;
    text-shadow: 0 0 8px rgba(30, 136, 229, 0.4);
}
.knowledge-subtitle {
    color: #bbdefb;
    font-size: 18px;
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.6;
}

/* 核心功能区 */
.knowledge-core {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 30px;
    margin-bottom: 50px;
}

/* 通用卡片样式 */
.card-title {
    color: #e3f2fd;
    font-size: 18px;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(66, 165, 245, 0.2);
    display: flex;
    align-items: center;
    gap: 8px;
}
.card-title i {
    color: #42a5f5;
    font-size: 20px;
}
.contribute-card, .my-contribute-card, .update-dynamic-card, .version-card, .statistic-card, .hot-update-card {
    background: rgba(10, 25, 47, 0.6);
    backdrop-filter: blur(8px);
    border-radius: 12px;
    border: 1px solid rgba(66, 165, 245, 0.3);
    padding: 25px;
    margin-bottom: 30px;
}

/* 左侧操作区 */
.contribute-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}
.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.form-label {
    color: #e3f2fd;
    font-size: 16px;
    font-weight: 500;
}
.form-select, .form-input {
    background: rgba(10, 25, 47, 0.8);
    border: 1px solid rgba(66, 165, 245, 0.3);
    color: #e3f2fd;
    padding: 10px 15px;
    border-radius: 8px;
    outline: none;
    font-size: 14px;
}
.form-select option {
    background: #0a192f;
}
.form-textarea {
    background: rgba(10, 25, 47, 0.8);
    border: 1px solid rgba(66, 165, 245, 0.3);
    color: #e3f2fd;
    padding: 15px;
    border-radius: 8px;
    outline: none;
    font-size: 14px;
    resize: none;
    min-height: 180px;
}
.form-textarea::placeholder {
    color: #90caf9;
    opacity: 0.7;
}
.submit-btn {
    padding: 12px 0;
    background: #2196f3;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 10px;
}
.submit-btn:hover {
    background: #1976d2;
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(33, 150, 243, 0.3);
}

/* 我的贡献记录 */
.contribute-filters {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}
.filter-btn {
    padding: 6px 14px;
    background: rgba(66, 165, 245, 0.1);
    color: #bbdefb;
    border: 1px solid rgba(66, 165, 245, 0.3);
    border-radius: 20px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s ease;
}
.filter-btn:hover {
    background: rgba(66, 165, 245, 0.2);
    color: #e3f2fd;
}
.filter-btn.active {
    background: #2196f3;
    color: #fff;
    border-color: #2196f3;
}
.contribute-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-height: 280px;
    overflow-y: auto;
    padding-right: 10px;
}
.contribute-list::-webkit-scrollbar {
    width: 6px;
}
.contribute-list::-webkit-scrollbar-track {
    background: rgba(10, 25, 47, 0.4);
    border-radius: 3px;
}
.contribute-list::-webkit-scrollbar-thumb {
    background: rgba(66, 165, 245, 0.3);
    border-radius: 3px;
}
.contribute-list::-webkit-scrollbar-thumb:hover {
    background: #42a5f5;
}
.contribute-item {
    background: rgba(10, 25, 47, 0.4);
    border-radius: 8px;
    padding: 15px;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
}
.contribute-item:hover {
    background: rgba(10, 25, 47, 0.5);
    border-left-color: #42a5f5;
}
.contribute-title {
    color: #e3f2fd;
    font-size: 15px;
    font-weight: 500;
    margin-bottom: 8px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.contribute-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    color: #90caf9;
    font-size: 13px;
}
.contribute-type {
    padding: 2px 8px;
    background: rgba(66, 165, 245, 0.1);
    border-radius: 10px;
}
.contribute-status {
    padding: 2px 8px;
    border-radius: 10px;
}
.contribute-status.pending {
    background: rgba(255, 193, 7, 0.1);
    color: #ffc107;
}
.contribute-status.approved {
    background: rgba(76, 175, 80, 0.1);
    color: #4caf50;
}
.contribute-status.rejected {
    background: rgba(239, 83, 80, 0.1);
    color: #ef5350;
}
.contribute-status.updated {
    background: rgba(33, 150, 243, 0.1);
    color: #42a5f5;
}
.reject-reason {
    color: #ef5350;
    font-size: 12px;
    margin-left: 8px;
}

/* 右侧展示区 */
.dynamic-filters {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}
.filter-select {
    flex: 1;
    min-width: 150px;
    background: rgba(10, 25, 47, 0.8);
    border: 1px solid rgba(66, 165, 245, 0.3);
    color: #e3f2fd;
    padding: 10px 15px;
    border-radius: 8px;
    outline: none;
    font-size: 14px;
}
.filter-select option {
    background: #0a192f;
}
.dynamic-list {
    display: flex;
    flex-direction: column;
    gap: 18px;
    max-height: 400px;
    overflow-y: auto;
    padding-right: 10px;
}
.dynamic-list::-webkit-scrollbar {
    width: 6px;
}
.dynamic-list::-webkit-scrollbar-track {
    background: rgba(10, 25, 47, 0.4);
    border-radius: 3px;
}
.dynamic-list::-webkit-scrollbar-thumb {
    background: rgba(66, 165, 245, 0.3);
    border-radius: 3px;
}
.dynamic-list::-webkit-scrollbar-thumb:hover {
    background: #42a5f5;
}
.dynamic-item {
    background: rgba(10, 25, 47, 0.4);
    border-radius: 8px;
    padding: 18px;
    transition: all 0.3s ease;
}
.dynamic-item:hover {
    background: rgba(10, 25, 47, 0.5);
    border: 1px solid rgba(66, 165, 245, 0.3);
}
.dynamic-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}
.dynamic-title {
    color: #e3f2fd;
    font-size: 16px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
}
.dynamic-title i {
    color: #42a5f5;
}
.dynamic-time {
    color: #90caf9;
    font-size: 13px;
}
.dynamic-content {
    color: #bbdefb;
    font-size: 14px;
    line-height: 1.8;
    margin-bottom: 12px;
}
.dynamic-content p {
    margin-bottom: 6px;
    padding-left: 20px;
    position: relative;
}
.dynamic-content p::before {
    content: '•';
    position: absolute;
    left: 0;
    color: #42a5f5;
    font-weight: bold;
}
.dynamic-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    color: #90caf9;
    font-size: 13px;
}
.dynamic-category {
    padding: 2px 8px;
    background: rgba(66, 165, 245, 0.1);
    border-radius: 10px;
}
.load-more-btn {
    width: 100%;
    padding: 10px 0;
    background: transparent;
    border: 1px solid rgba(66, 165, 245, 0.3);
    color: #42a5f5;
    border-radius: 8px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.load-more-btn:hover {
    background: rgba(66, 165, 245, 0.1);
    color: #e3f2fd;
}

/* 知识版本管理 */
.version-search {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}
.version-input {
    flex: 1;
    background: rgba(10, 25, 47, 0.8);
    border: 1px solid rgba(66, 165, 245, 0.3);
    color: #e3f2fd;
    padding: 10px 15px;
    border-radius: 8px;
    outline: none;
    font-size: 14px;
}
.version-input::placeholder {
    color: #90caf9;
    opacity: 0.7;
}
.search-btn {
    padding: 0 18px;
    background: #2196f3;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}
.search-btn:hover {
    background: #1976d2;
}
.version-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}
.version-item {
    background: rgba(10, 25, 47, 0.4);
    border-radius: 8px;
    padding: 18px;
}
.version-title {
    color: #e3f2fd;
    font-size: 16px;
    font-weight: 500;
    margin-bottom: 15px;
}
.version-versions {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}
.version-btn {
    padding: 6px 14px;
    background: rgba(66, 165, 245, 0.1);
    color: #bbdefb;
    border: 1px solid rgba(66, 165, 245, 0.3);
    border-radius: 20px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s ease;
}
.version-btn:hover {
    background: rgba(66, 165, 245, 0.2);
    color: #e3f2fd;
}
.version-btn.active {
    background: #2196f3;
    color: #fff;
    border-color: #2196f3;
}
.version-changelog {
    color: #bbdefb;
    font-size: 14px;
    line-height: 1.8;
}
.version-changelog h4 {
    color: #e3f2fd;
    margin-bottom: 10px;
    font-size: 15px;
}
.changelog-list {
    list-style: none;
    padding-left: 20px;
}
.changelog-list li {
    position: relative;
    margin-bottom: 8px;
}
.changelog-list li::before {
    content: '';
    position: absolute;
    left: -20px;
    top: 6px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #42a5f5;
}
.changelog-list li i {
    color: #42a5f5;
    margin-right: 8px;
}

/* 统计与热门更新 */
.knowledge-statistics {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}
.statistic-content {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}
.statistic-item {
    background: rgba(10, 25, 47, 0.4);
    border-radius: 8px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: all 0.3s ease;
}
.statistic-item:hover {
    transform: translateY(-5px);
    border: 1px solid rgba(66, 165, 245, 0.5);
    box-shadow: 0 10px 20px rgba(30, 136, 229, 0.15);
}
.statistic-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(66, 165, 245, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #42a5f5;
    font-size: 24px;
}
.statistic-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.statistic-value {
    color: #e3f2fd;
    font-size: 28px;
    font-weight: 700;
}
.statistic-label {
    color: #90caf9;
    font-size: 14px;
}

/* 热门更新 */
.hot-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}
.hot-item {
    display: flex;
    align-items: center;
    gap: 15px;
    background: rgba(10, 25, 47, 0.4);
    border-radius: 8px;
    padding: 15px;
    transition: all 0.3s ease;
}
.hot-item:hover {
    background: rgba(10, 25, 47, 0.5);
    border-left: 3px solid #42a5f5;
}
.hot-rank {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: rgba(66, 165, 245, 0.1);
    color: #42a5f5;
    font-size: 16px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.hot-item:nth-child(1) .hot-rank {
    background: rgba(255, 215, 0, 0.1);
    color: #ffd700;
}
.hot-item:nth-child(2) .hot-rank {
    background: rgba(192, 192, 192, 0.1);
    color: #c0c0c0;
}
.hot-item:nth-child(3) .hot-rank {
    background: rgba(205, 127, 50, 0.1);
    color: #cd7f32;
}
.hot-info {
    flex: 1;
}
.hot-title {
    color: #e3f2fd;
    font-size: 15px;
    font-weight: 500;
    margin-bottom: 6px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.hot-meta {
    display: flex;
    gap: 12px;
    color: #90caf9;
    font-size: 13px;
}
.hot-category {
    padding: 2px 8px;
    background: rgba(66, 165, 245, 0.1);
    border-radius: 10px;
}

/* 成功弹窗 */
.success-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(10, 25, 47, 0.7);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}
.modal-content {
    background: rgba(10, 25, 47, 0.9);
    border: 1px solid rgba(66, 165, 245, 0.5);
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    padding: 30px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}
.modal-header {
    color: #4caf50;
    font-size: 20px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}
.modal-header i {
    font-size: 24px;
}
.modal-body {
    color: #bbdefb;
    font-size: 15px;
    line-height: 1.8;
}
.modal-body p {
    margin-bottom: 8px;
}
.modal-body span {
    color: #42a5f5;
    font-weight: 500;
}
.modal-footer {
    display: flex;
    justify-content: center;
}
.close-modal-btn {
    padding: 10px 30px;
    background: #2196f3;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
}
.close-modal-btn:hover {
    background: #1976d2;
}

/* 底部样式 */
footer {
    width: 100%;
    padding: 40px 5%;
    background: rgba(10, 25, 47, 0.8);
    border-top: 1px solid rgba(66, 165, 245, 0.3);
    margin-top: 80px;
}
.footer-content {
    color: #bbdefb;
    text-align: center;
    font-size: 14px;
    line-height: 1.8;
}

/* 响应式适配 */
@media (max-width: 1200px) {
    .knowledge-core {
        grid-template-columns: 1fr;
    }
    .knowledge-statistics {
        grid-template-columns: 1fr;
    }
}
@media (max-width: 768px) {
    .nav-menu {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100px;
        right: 5%;
        background: rgba(10, 25, 47, 0.9);
        backdrop-filter: blur(10px);
        border-radius: 8px;
        padding: 20px;
        border: 1px solid rgba(66, 165, 245, 0.3);
        z-index: 999;
    }
    .nav-menu.active {
        display: flex;
    }
    .mobile-menu-btn {
        display: block;
    }
    .knowledge-header {
        margin-bottom: 30px;
    }
    .knowledge-title {
        font-size: 28px;
    }
    .statistic-content {
        grid-template-columns: 1fr;
    }
    .version-search {
        flex-direction: column;
    }
}
@media (max-width: 480px) {
    .knowledge-subtitle {
        font-size: 16px;
    }
    .contribute-card, .my-contribute-card, .update-dynamic-card, .version-card, .statistic-card, .hot-update-card {
        padding: 15px;
    }
    .card-title {
        font-size: 16px;
    }
    .form-textarea {
        min-height: 120px;
    }
    .dynamic-content p {
        padding-left: 15px;
    }
    .modal-content {
        padding: 20px;
    }
}