/* 针对home页面的特殊样式 */
body.home-page {
    padding-top: 0 !important;
    overflow: hidden;
    /* background-color: #ffffe7; */
}

/* 隐藏所有滚动条 */
body.home-page,
body.home-page * {
    scrollbar-width: none;
    /* Firefox */
    -ms-overflow-style: none;
    /* IE and Edge */
}

body.home-page::-webkit-scrollbar,
body.home-page *::-webkit-scrollbar {
    display: none;
    /* Chrome, Safari, Opera */
}

/* Topbar隐藏状态 */
.topbar.hidden {
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
}

/* Topbar显示状态 */
.topbar.visible {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}

/* Topbar过渡动画 */
.topbar {
    transition: transform 0.5s ease, opacity 0.5s ease;
}

/* 隐藏sidebar和main-content的布局影响 */
body.home-page .sidebar,
body.home-page .main-content {
    display: none !important;
}

/* 修复fullPage.js section的padding问题 */
.fp-section,
.fp-slide,
.fp-tableCell {
    padding: 0 !important;
    margin: 0 !important;

}

/* fullPage.js 导航点自定义样式 */
#fp-nav ul li a span,
.fp-slidesNav ul li a span {
    background: var(--primary-medium);
    width: 12px;
    height: 12px;
    border: 2px solid var(--primary-light);
    transition: all 0.3s ease;
}

#fp-nav ul li a.active span,
.fp-slidesNav ul li a.active span,
#fp-nav ul li:hover a.active span,
.fp-slidesNav ul li:hover a.active span {
    background: var(--primary-light);
    border-color: var(--primary-dark);
    transform: scale(1.2);
    transform-origin: center;
}

#fp-nav ul li:hover a span,
.fp-slidesNav ul li:hover a span {
    background: var(--accent-light);
    border-color: var(--primary-medium);
}

/* 确保导航点位置合适 */
#fp-nav {
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
}

/* 确保section高度正确 */
.section {
    height: 100vh;
}

.fp-auto-height .section,
.fp-auto-height .fp-slide,
.fp-auto-height .fp-tableCell {
    height: auto !important;
}

/* Section-specific styles extracted from home.html */
.section-hero .content-placeholder,
.section-about .content-placeholder,
.section-projects .content-placeholder,
.section-team .content-placeholder {
    width: 100vw;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: 80px !important;
    overflow: hidden;
}


/* 禁止team部分的上下滑动 */
.section-team {
    overflow: hidden !important;
    touch-action: pan-x !important;
}

.section-team * {
    touch-action: pan-x !important;
}

.section.fp-auto-height {
    transform: translate3d(0, 0, 0);
    will-change: transform;
}

/* 添加2×4网格布局 */
.image-stack-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: repeat(2, 1fr);
    gap: 0px 0px;
    width: 100%;
    max-width: 1400px;
    padding: 60px 40px;
}

/* image-stack容器样式 */
.image-stack-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.image-stack-container:hover {
    transform: translateY(-5px);
}

/* 调整image-stack尺寸以适应网格 */
.section-team .image-stack {
    width: 220px;
    height: 220px;
    margin: 0;
    pointer-events: auto;
}

/* 添加标题样式 */
.image-stack-title {
    text-align: center;
    margin-top: 20px;
    font-family: var(--font-sans);
    font-weight: 100;
    font-style: italic;
    font-size: 1.3rem;
    color: var(--primary-dark);
    letter-spacing: 0.5px;
    transition: color 0.3s ease;
    pointer-events: auto;
}

.image-stack-container:hover .image-stack-title {
    color: var(--primary-light);
}

/* 响应式布局 */
@media (max-width: 1400px) {
    .image-stack-grid {
        gap: 30px 20px;
        padding: 40px 30px;
    }

    .section-team .image-stack {
        width: 190px;
        height: 190px;
    }

    .image-stack-title {
        font-size: 1.1rem;
    }
}

@media (max-width: 1024px) {
    .image-stack-grid {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: repeat(4, 1fr);
        gap: 40px 30px;
    }
}

@media (max-width: 768px) {
    .image-stack-grid {
        grid-template-columns: 1fr;
        grid-template-rows: auto;
        gap: 40px;
        padding: 30px 20px;
    }

    .section-team .image-stack {
        width: 220px;
        height: 220px;
    }
}