@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@300;400;500;700&display=swap');

/* 关键修复：重置body和html的默认边距，确保全屏无间隙 */
html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    overflow-x: hidden;
}

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

body {
    font-family: 'Noto Sans SC', sans-serif;
    background: #f5f5f5;
}

/* 背景图区域 - 彻底全屏修复 */
.hero-section {
    height: 100vh; /* 占满视口高度 */
    width: 100vw; /* 占满视口宽度 */
    position: relative;
    overflow: hidden;
    /* 背景图全屏覆盖，无重复，居中显示 */
    background: linear-gradient(rgba(0,0,0,0.3), rgba(0,0,0,0.5)), url('/image/backgroud.png') no-repeat center center/cover;
    margin: 0 !important; /* 强制移除所有边距 */
    padding: 0 !important; /* 强制移除所有内边距 */
    left: 0;
    top: 0;
}

.hero-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: white;
    z-index: 10;
    width: 100%;
    padding: 0 20px;
}

.avatar-container {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    overflow: hidden;
    margin: 0 auto 20px;
    border: 3px solid rgba(255,255,255,0.3);
    animation: float 3s ease-in-out infinite;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.hero-title {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 10px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.3);
    opacity: 0;
    animation: fadeInUp 1s ease forwards 0.5s;
}

.hero-subtitle {
    font-size: 1.1rem;
    color: rgba(255,255,255,0.9);
    margin-bottom: 30px;
    opacity: 0;
    animation: fadeInUp 1s ease forwards 0.7s;
}

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

/* 导航按钮 */
.nav-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 30px;
}

.nav-btn {
    padding: 8px 24px;
    border: 2px solid rgba(255,255,255,0.6);
    border-radius: 25px;
    color: white;
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(10px);
    opacity: 0;
    animation: fadeInUp 1s ease forwards 0.9s;
}

.nav-btn:hover {
    background: white;
    color: #333;
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
}

.nav-btn:nth-child(2) { animation-delay: 1s; }
.nav-btn:nth-child(3) { animation-delay: 1.1s; }
.nav-btn:nth-child(4) { animation-delay: 1.2s; }
.nav-btn:nth-child(5) { animation-delay: 1.3s; }

/* 背景文字效果 */
.bg-text {
    position: absolute;
    font-size: 15vw;
    font-weight: 900;
    color: rgba(255,255,255,0.08);
    white-space: nowrap;
    user-select: none;
    pointer-events: none;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

/* 项目卡片区域 - 全屏显示 */
.projects-section {
    padding: 80px 20px;
    width: 100vw; /* 全屏宽度 */
    margin: 0 auto;
    background: #f5f5f5; /* 背景铺满 */
}

.projects-inner {
    max-width: 1400px; /* 内容宽度限制，不影响背景 */
    margin: 0 auto;
}

.section-title {
    text-align: center;
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 50px;
    color: #1a1a1a;
    position: relative;
    display: inline-block;
    left: 50%;
    transform: translateX(-50%);
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, #667eea, #764ba2);
    border-radius: 2px;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    width: 100%;
}

.project-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    opacity: 0;
    transform: translateY(30px);
}

.project-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
}

.project-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.project-card:hover .project-image {
    transform: scale(1.05);
}

.project-content {
    padding: 20px;
}

.project-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: #1a1a1a;
}

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

.tag {
    padding: 4px 12px;
    background: #f0f0f0;
    border-radius: 12px;
    font-size: 0.75rem;
    color: #666;
    transition: all 0.3s;
}

.tag:hover {
    background: #667eea;
    color: white;
}

/* 开发者信息区域 - 全屏显示 */
.about-section {
    padding: 80px 20px;
    background: white;
    width: 100vw; /* 全屏宽度 */
    margin: 0;
}

.about-container {
    max-width: 1200px; /* 内容宽度限制 */
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    width: 100%;
}

@media (max-width: 768px) {
    .about-container {
        grid-template-columns: 1fr;
    }
}

.developer-card {
    display: flex;
    gap: 30px;
    align-items: center;
}

.dev-avatar {
    width: 150px;
    height: 150px;
    border-radius: 20px;
    object-fit: cover;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    transition: transform 0.3s;
}

.dev-avatar:hover {
    transform: scale(1.05) rotate(2deg);
}

.dev-info h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: #1a1a1a;
}

.dev-detail {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    color: #666;
    font-size: 0.95rem;
}

.dev-detail i {
    width: 20px;
    color: #667eea;
}

/* 技能圆环 */
.skills-container {
    display: flex;
    gap: 30px;
    justify-content: center;
    flex-wrap: wrap;
}

.skill-circle {
    position: relative;
    width: 120px;
    height: 120px;
}

.skill-circle svg {
    transform: rotate(-90deg);
    width: 100%;
    height: 100%;
}

.skill-circle circle {
    fill: none;
    stroke-width: 8;
}

.skill-circle .bg {
    stroke: #f0f0f0;
}

.skill-circle .progress {
    stroke: #667eea;
    stroke-linecap: round;
    transition: stroke-dashoffset 1.5s ease;
    stroke-dasharray: 339.292;
    stroke-dashoffset: 339.292;
}

.skill-circle:nth-child(2) .progress { stroke: #f59e0b; }
.skill-circle:nth-child(3) .progress { stroke: #10b981; }
.skill-circle:nth-child(4) .progress { stroke: #8b5cf6; }

.skill-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}

.skill-percent {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1a1a1a;
}

.skill-name {
    font-size: 0.85rem;
    color: #666;
    margin-top: 5px;
}

/* 语言技能区域 - 全屏显示 */
.languages-section {
    padding: 80px 20px;
    width: 100vw; /* 全屏宽度 */
    margin: 0 auto;
    background: #f5f5f5; /* 背景铺满 */
}

.languages-inner {
    max-width: 1400px; /* 内容宽度限制 */
    margin: 0 auto;
}

.languages-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px;
    width: 100%;
}

.language-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
    transition: all 0.4s ease;
}

.language-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.12);
}

.lang-image {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.language-card:hover .lang-image {
    transform: scale(1.03);
}

.lang-content {
    padding: 25px;
}

.lang-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f0f0;
}

.lang-icon1 {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    background-image: url("/image/fnn.png");
    background-repeat: no-repeat;
    background-size: contain;
    background-position: center;
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

 
.lang-icon2 {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    background-image: url("/image/pm.png");
    background-repeat: no-repeat;
    background-size: contain;
    background-position: center;
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

.lang-icon3 {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    background-image: url("/image/ht.png");
    background-repeat: no-repeat;
    background-size: contain;
    background-position: center;
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

.lang-icon4 {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    background-image: url("/image/sz.png");
    background-repeat: no-repeat;
    background-size: contain;
    background-position: center;
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

.lang-icon5 {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    background-image: url("/image/ly.png");
    background-repeat: no-repeat;
    background-size: contain;
    background-position: center;
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

.lang-title {
    font-size: 1.3rem;
    font-weight: 600;
    color: #1a1a1a;
}

.lang-desc {
    color: #666;
    line-height: 1.8;
    font-size: 0.95rem;
}

.lang-desc li {
    margin-bottom: 8px;
    position: relative;
    padding-left: 15px;
}

.lang-desc li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: #667eea;
    font-weight: bold;
}

/* 时间线 */
.timeline-section {
    padding: 80px 20px;
    background: white;
    width: 100vw; /* 全屏宽度 */
    margin: 0;
}

.timeline {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    padding-left: 30px;
    width: 100%;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(to bottom, #667eea, #764ba2);
    border-radius: 3px;
}

.timeline-item {
    position: relative;
    padding: 25px;
    margin-bottom: 30px;
    background: #f8f9fa;
    border-radius: 15px;
    margin-left: 20px;
    opacity: 0;
    transform: translateX(-30px);
    transition: all 0.5s ease;
}

.timeline-item.visible {
    opacity: 1;
    transform: translateX(0);
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -26px;
    top: 30px;
    width: 16px;
    height: 16px;
    background: #667eea;
    border-radius: 50%;
    border: 4px solid white;
    box-shadow: 0 0 0 3px #667eea;
}

.timeline-content {
    color: #444;
    line-height: 1.8;
}

/* 页脚 */
.footer {
    background: #0a0a0a;
    color: white;
    padding: 60px 20px 30px;
    text-align: center;
    position: relative;
    overflow: hidden;
    width: 100vw; /* 全屏宽度 */
    margin: 0;
}

.footer-content {
    position: relative;
    z-index: 2;
}

.footer-title {
    font-size: 2.5rem;
    font-weight: 300;
    margin-bottom: 20px;
    opacity: 0.9;
}

.footer-quote {
    font-size: 1.1rem;
    color: rgba(255,255,255,0.7);
    margin-bottom: 10px;
    font-style: italic;
}

.footer-divider {
    width: 60px;
    height: 2px;
    background: rgba(255,255,255,0.3);
    margin: 20px auto;
}

.footer-logo {
    font-size: 5rem;
    font-weight: 900;
    background: linear-gradient(135deg, rgba(255,255,255,0.1), rgba(255,255,255,0.05));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin: 30px 0;
    letter-spacing: 10px;
}

.footer-bottom {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.5);
    font-size: 0.9rem;
}

/* 滚动动画 */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* 粒子效果 */
.particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: rgba(255,255,255,0.5);
    border-radius: 50%;
    animation: particle-float 15s infinite;
}

@keyframes particle-float {
    0%, 100% {
        transform: translateY(100vh) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateY(-100vh) rotate(720deg);
        opacity: 0;
    }
}

/* 响应式 */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2rem;
    }
    .nav-buttons {
        gap: 10px;
    }
    .nav-btn {
        padding: 6px 16px;
        font-size: 0.8rem;
    }
    .projects-grid {
        grid-template-columns: 1fr;
    }
    .languages-grid {
        grid-template-columns: 1fr;
    }
}

/* 加载动画 */
.loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #1a1a1a;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s, visibility 0.5s;
}

.loader.hidden {
    opacity: 0;
    visibility: hidden;
}

.loader-text {
    color: white;
    font-size: 2rem;
    font-weight: 300;
    letter-spacing: 0.5em;
    animation: pulse 1.5s ease-in-out infinite;
}

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

/* 平滑滚动 */
html {
    scroll-behavior: smooth;
    scrollbar-width: none; /* Firefox隐藏纵向滚动条 */
    -ms-overflow-style: none; /* IE/Edge隐藏纵向滚动条 */
}

/* 隐藏纵向滚动条（保留滚动功能） */
::-webkit-scrollbar {
    width: 0px !important; /* 强制隐藏纵向滚动条宽度 */
    height: 8px; /* 横向滚动条保留原有宽度 */
}

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

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

::-webkit-scrollbar-thumb:hover {
    background: #764ba2;
}

/* 兜底：防止部分场景滚动条残留 */
body {
    overflow-y: scroll; /* 强制开启滚动但隐藏滚动条 */
    scrollbar-width: none;
}

/* VIDEO区域基础样式 */
.video-container {
    width: 100vw;
    padding: 20px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
}

.video-card1 {
    width: calc(33.333% - 20px);
    min-width: 300px;
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.video__video iframe {
    width: 100%;
    height: 200px;
    border: none;
}

.video__info {
    padding: 15px;
}

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

.video__avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

.video__title {
    font-size: 1.1rem;
    font-weight: 600;
}

.video__list {
    list-style: none;
    color: #666;
    font-size: 0.9rem;
}