/* css/time-rift.css */

/* 阻止默认的滚动并隐藏滚动条 */
html, body {
    overflow: hidden !important;
    height: 100vh;
    width: 100vw;
    margin: 0;
    padding: 0;
    touch-action: none; /* 禁用默认的触摸滚动 */
}

/* 时间裂缝主容器 */
#time-rift-main {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    perspective: 2000px;
    transform-style: preserve-3d;
    z-index: 10;
    pointer-events: none; /* 让鼠标事件透过主容器 */
}

/* 裂缝截面 (每个 Section) */
.rift-section {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    min-height: unset !important;
    margin: 0 !important;
    /* 居中内容 */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    
    transform-origin: center center;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    will-change: transform, opacity, filter;
    
    /* 修复原有的 z-index */
    z-index: 2;
    padding: 0 !important;
}

/* 覆盖原始区域的 padding */
.hero, .about, .projects, .contact {
    padding: 0 !important;
}

/* 只有激活状态的 section 才允许交互 */
.rift-section.is-active {
    pointer-events: auto;
}

/* 时间裂缝 UI 提示 */
.time-rift-indicator {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: row;
    gap: 15px;
    z-index: 100;
    pointer-events: auto;
}

.rift-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 0 10px rgba(255, 255, 255, 0);
}

.rift-dot.active {
    background: rgba(255, 255, 255, 1);
    transform: scale(1.5);
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.8);
}

/* 覆盖关于页和项目的容器让其居中 */
.about .container, .contact .container {
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: center;
}

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

/* 裂缝速度线 (视觉特效) */
#speed-lines-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.2s;
}

/* 去除脚本里的默认平滑滚动条显示 */
.scroll-progress {
    display: none !important;
}
