/* 项目导航页面基础样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', 'Microsoft YaHei', sans-serif;
}

:root {
    --primary-color: #4a85bd;
    --secondary-color: #e28aa6;
    --accent-color: #f2b3c3;
    --dark-color: #2d3436;
    --light-color: #f5f6fa;
    --glass-color: rgba(255, 255, 255, 0.15);
    --text-color: #2d3436;
    --text-light: #636e72;
    --card-bg: #ffffff;
    --shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    --transition: all 0.3s ease;
}

body {
    font-family: 'Poppins', 'Segoe UI', 'Microsoft YaHei', sans-serif;
    background:
        radial-gradient(1100px 520px at 8% -5%, rgba(165, 211, 240, 0.30), transparent 60%),
        radial-gradient(900px 480px at 95% 5%, rgba(242, 179, 195, 0.30), transparent 60%),
        linear-gradient(160deg, #f8fbff 0%, #eef6fc 50%, #fdf1f5 100%);
    background:
        -webkit-radial-gradient(1100px 520px at 8% -5%, rgba(165, 211, 240, 0.30), transparent 60%),
        -webkit-radial-gradient(900px 480px at 95% 5%, rgba(242, 179, 195, 0.30), transparent 60%),
        -webkit-linear-gradient(160deg, #f8fbff 0%, #eef6fc 50%, #fdf1f5 100%);
    color: var(--text-color);
    line-height: 1.6;
    min-height: 100vh;
    padding: 20px;
    position: relative;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

header {
    text-align: center;
    margin-bottom: 40px;
    padding: 30px 20px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.88);
    border: 1px solid rgba(255, 255, 255, 0.95);
    color: var(--dark-color);
    box-shadow: var(--shadow);
    position: relative;
    overflow: hidden;
}

header::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: #a5d3f0;
}

.avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 4px solid transparent;
    background: linear-gradient(#fff, #fff) padding-box,
                #a5d3f0 border-box;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(74, 133, 189, 0.18);
    overflow: hidden;
}

.avatar img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

.avatar i {
    font-size: 60px;
    color: #2c3e50;
}

h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    font-weight: 700;
    color: #4a85bd;
}

.subtitle {
    font-size: 1.15rem;
    max-width: 600px;
    margin: 0 auto;
    color: #6b7b8c;
    letter-spacing: 0.5px;
}

.github-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 18px;
    color: #4a85bd;
    text-decoration: none;
    background: rgba(74, 133, 189, 0.06);
    padding: 9px 18px;
    border-radius: 30px;
    transition: var(--transition);
    border: 1px solid rgba(74, 133, 189, 0.3);
    font-weight: 500;
}

.github-link:hover {
    background: rgba(74, 133, 189, 0.12);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(74, 133, 189, 0.15);
    color: #3a6fa5;
}

.intro {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 50px;
    font-size: 1.05rem;
    color: #5a6b7a;
    line-height: 1.9;
    font-weight: 400;
}

.repo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.repo-card {
    background: #ffffff;
    border: 1px solid rgba(74, 133, 189, 0.1);
    border-radius: 16px;
    padding: 25px;
    box-shadow: 0 1px 3px rgba(45, 52, 54, 0.04), 0 8px 24px rgba(74, 133, 189, 0.08);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    height: 100%;
    position: relative;
    overflow: hidden;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

.repo-card::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: #a5d3f0;
    z-index: 1;
}

.repo-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 10px 30px rgba(74, 133, 189, 0.15);
    border-color: rgba(74, 133, 189, 0.25);
}

.repo-icon {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    background: #d9ecfb;
    color: #4a85bd;
    font-size: 1.5rem;
    margin-bottom: 18px;
    position: relative;
    z-index: 1;
}

.repo-name {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: #2d3436;
    position: relative;
    z-index: 1;
    transition: color 0.3s ease;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.forked-from {
    font-size: 0.75rem;
    font-weight: 400;
    color: #999;
    margin-left: 5px;
}

.forked-link {
    color: #4a85bd;
    text-decoration: none;
    transition: color 0.3s ease;
}

.forked-link:hover {
    color: #e28aa6;
    text-decoration: underline;
}

.repo-card:hover .repo-name {
    color: var(--primary-color);
}

.repo-desc {
    color: #5a6b7a;
    margin-bottom: 20px;
    flex-grow: 1;
    line-height: 1.7;
    position: relative;
    z-index: 1;
    font-weight: 400;
}

.repo-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #b9dff7;
    color: #3b76b6;
    text-decoration: none;
    padding: 12px 20px;
    border-radius: 10px;
    font-weight: 500;
    letter-spacing: 0.5px;
    transition: var(--transition);
    width: 100%;
    text-align: center;
    margin-top: auto;
    position: relative;
    z-index: 1;
    box-shadow: 0 4px 12px rgba(122, 162, 216, 0.35);
}

.repo-link:hover {
    background: #9ed2f2;
    color: #2d6098;
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(122, 162, 216, 0.45);
}

footer {
    text-align: center;
    padding: 30px;
    margin-top: 40px;
    color: #7a8a99;
    border-top: 1px solid rgba(74, 133, 189, 0.12);
    font-size: 0.95rem;
}

.stats {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.stat-item {
    background: #ffffff;
    border: 1px solid rgba(74, 133, 189, 0.1);
    padding: 20px 30px;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(45, 52, 54, 0.04), 0 8px 24px rgba(74, 133, 189, 0.08);
    min-width: 150px;
    text-align: center;
    transition: var(--transition);
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

.stat-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(74, 133, 189, 0.18);
    border-color: rgba(74, 133, 189, 0.25);
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
    display: block;
}

.stat-label {
    font-size: 0.9rem;
    color: #555;
    margin-top: 5px;
    display: block;
    font-weight: 500;
}

/* 导航菜单样式 */
.nav-menu {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin: 30px 0;
    flex-wrap: wrap;
}

.nav-item {
    background: white;
    padding: 15px 30px;
    border-radius: 50px;
    box-shadow: var(--shadow);
    transition: var(--transition);
    text-decoration: none;
    color: var(--primary-color);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid #e1e4e8;
}

.nav-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.1);
    background: #4a85bd;
    color: white;
}

@media (max-width: 768px) {
    .repo-grid {
        grid-template-columns: 1fr;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    header {
        padding: 20px 15px;
    }
    
    .stats {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }
    
    .stat-item {
        width: 100%;
        max-width: 250px;
    }
    
    .avatar {
        width: 100px;
        height: 100px;
    }
    
    .avatar i {
        font-size: 45px;
    }
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #a5d3f0;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #8ec0e8;
}

/* 返回顶部按钮 */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: #b9dff7;
    color: #3b76b6;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    transform: translateY(20px);
    transition: var(--transition);
    z-index: 1000;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.back-to-top.show {
    opacity: 1;
    transform: translateY(0);
}

.back-to-top:hover {
    background: #9ed2f2;
    color: #2d6098;
    transform: translateY(-2px);
}