/* ============================================================
   作品集网站 - 主样式表
   配色：白 #F9F8F6 / 黑 #1A1A1A / 橙 #F15A24
   风格：极简，线条、色块、简约交互
   ============================================================ */

/* ------------------------ 基础重置 ------------------------ */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
    color: #1A1A1A;
    background: #F9F8F6;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
}

img {
    max-width: 100%;
    display: block;
}

button {
    border: none;
    background: none;
    cursor: pointer;
    font-family: inherit;
}

/* ------------------------ 通用：区域编号和标题 ------------------------ */
.section-number {
    font-size: 0.875rem;
    color: #F15A24;
    font-weight: 500;
    letter-spacing: 0.05em;
    display: block;
    margin-bottom: 0.5rem;
}

/* 编号三色：数字=橙色，斜杠=灰色，文字=黑色 */
.num { color: #F15A24; }
.slash { color: #999; }
.text { color: #1A1A1A; }

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #1A1A1A;
    line-height: 1.2;
}

/* ============================================================
   顶部导航栏
   ============================================================ */
.nav {
    position: fixed;
    top: 1.2rem;
    left: 0;
    right: 0;
    z-index: 1000;
    pointer-events: none;
}

.nav__inner {
    max-width: 1620px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav__logo {
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: #1A1A1A;
    position: relative;
    display: inline-block;
    pointer-events: auto;
}

.nav__logo--light {
    position: absolute;
    top: 0;
    left: 0;
    color: #FFFFFF;
    pointer-events: none;
    white-space: nowrap;
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    line-height: inherit;
}

.nav__menu {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #1A1A1A;
    padding: 0.6rem 1.5rem;
    border-radius: 50px;
    background: transparent;
    border: 1px solid transparent;
    font: inherit;
    position: relative;
    pointer-events: auto;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 滚动后 — Menu 按钮变为磨砂玻璃胶囊 */
.nav--scrolled .nav__menu {
    background: rgba(249, 248, 246, 0.20);
    backdrop-filter: blur(30px) saturate(180%);
    -webkit-backdrop-filter: blur(30px) saturate(180%);
    border-color: rgba(255, 255, 255, 0.35);
    box-shadow:
        0 4px 30px rgba(0, 0, 0, 0.06),
        inset 0 1px 0 rgba(255, 255, 255, 0.5);
}

/* --- Menu 白色副本（通过 padding:inherit 精确匹配原始按钮内边距） --- */
.nav__menu--light {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding: inherit;
    color: #FFFFFF;
    pointer-events: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav__menu-text-light {
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.05em;
    color: #FFFFFF;
}

.nav__menu-icon-light {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.nav__menu-icon-light span {
    display: block;
    width: 4px;
    height: 4px;
    background: #FFFFFF;
}

.nav__menu-text {
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.05em;
}

/* 菜单图标：三个小方块 */
.nav__menu-icon {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.nav__menu-icon span {
    display: block;
    width: 4px;
    height: 4px;
    background: #F15A24;
}

/* ============================================================
   首页展示区 Hero
   参考 specia1ne.com 的交互效果
   ============================================================ */
.hero {
    position: relative;
    width: 100%;
    height: 100vh;
    background: #F9F8F6;
    overflow: hidden;
}

/* --- 内容容器（从顶部自然排列，状态栏自动推到底部） --- */
.hero__inner {
    position: relative;
    width: 100%;
    max-width: 1620px;
    margin: 0 auto;
    padding: 4rem 2rem;
    height: 100vh;
    display: flex;
    flex-direction: column;
    /* 去掉 justify-content: center，让内容从顶部自然排列 */
}

/* 区域编号（绝对定位，可自由调上下位置） */
.hero__number {
    position: absolute;
    top:10rem;           /* ← 改这个数字调上下位置 */
    left: 2rem;          /* 和内容区左侧对齐 */
    font-size: 0.875rem;
    font-weight: 500;
    letter-spacing: 0.08em;
}

/* 区域编号白色副本 */
.hero__number--light {
    color: #FFFFFF;
    z-index: 9;
    pointer-events: none;
}
.hero__number--light .num,
.hero__number--light .slash,
.hero__number--light .text {
    color: #FFFFFF;
}

/* 标题 + 描述文字组 */
.hero__text-group {
    position: relative;
    margin-top: 15rem;   /* 加这行，数字越大越往下 */

}

.hero__content {
    position: relative;
    z-index: 2;
    color: #1A1A1A;
    pointer-events: none;
}

/* --- 亮色文字层（被橙色矩形裁剪后才显示，文字变白） --- */
.hero__content--light {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    color: #FFFFFF;
    z-index: 9;
    /* clip-path 由 JavaScript 动态控制 */
}

/* --- 大标题（单行） --- */
.hero__title--single {
    font-size: 7rem;
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: 0.02em;
    margin-bottom:2rem;
}

/* --- 描述文字 --- */
.hero__desc {
    max-width: px;
    font-size: 0.95rem;
    color: #666666;
    line-height: 1.7;
    font-weight: 400;
}

.hero__content--light .hero__desc {
    color: rgba(255, 255, 255, 0.8);
}

/* --- 橙色矩形（固定定位） --- */
.hero__bar {
    position: fixed;
    top: 0;
    height: 100vh;
    width: 140px;
    background: #F15A24;
    z-index: 8;
    pointer-events: none;
}

/* 黑色遮罩层：置于橙色bar上方，从透明→黑色控制过渡 */
.hero__bar-mask {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #0D0D0D;
    opacity: 0;
    pointer-events: none;
}

/* --- 底部状态栏容器（你可以用 margin-top 调上下位置） --- */
.hero__status-wrapper {
    position: relative;
    margin-top: 14rem;   /* ← 改这个数字调整状态栏的上下位置 */
}

/* --- 底部状态栏 --- */
.hero__status {
    font-size: 0.8rem;
    color: #1A1A1A;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    z-index: 5;
    letter-spacing: 0.05em;
}

.hero__status--light {
    position: absolute;
    top: 0;
    left: 0;
    color: #FFFFFF;
    z-index: 9;
    /* clip-path 由 JavaScript 动态控制 */
}

.hero__status--light .hero__status-dot {
    background: #FFFFFF;
}

.hero__status-dot {
    display: inline-block;
    width: 6px;
    height: 6px;
    background: #F15A24;
    border-radius: 50%;
}

/* ============================================================
   个人介绍区 About
   ============================================================ */
.about {
    position: relative;
    background: #F9F8F6;
    height: 100vh;
    overflow: hidden;
}

/* About 区编号文字全部白色 */
.about .num,
.about .slash,
.about .text {
    color: #FFFFFF;
}

/* About 区头像边框改为白色 */
.about .about__avatar {
    border-color: #FFFFFF;
    background: rgba(255,255,255,0.1);
}

.about__inner {
    position: relative;
    z-index: 9;
    max-width: 1620px;
    margin: 0 auto;
    padding: 0 15rem;
    padding-top: 8rem
}

/* --- 区域头部 --- */
.about__header {
    margin-bottom: 9rem;
}

/* --- 主体布局：左头像 + 右介绍 --- */
.about__body {
    display: flex;
    gap: 5rem;
    align-items: flex-start;
}

/* --- 左侧头像区 --- */
.about__avatar-area {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding-left: 0;
}

.about__avatar {
    width: 280px;
    height: 330px;
    border-radius: 8px;
    background: #E8E5DF;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.5rem;
    border: 2px solid #F15A24;
    overflow: hidden;
}

.about__avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.about__avatar-placeholder {
    font-size: 0.9rem;
    color: #ddd;
    text-align: center;
    line-height: 1.5;
}

.about__name {
    font-size: 1.8rem;
    font-weight: 00;
    color: #FFFFFF;
    margin-bottom: 0.1rem;
}

.about__role {
    font-size: 1.1rem;
    color: #ddd;
    letter-spacing: 0.03em;
}

/* --- 右侧信息区 --- */
.about__info {
    flex: 1;
}

.about__bio {
    font-size: 1.2rem;
    color: #eee;
    line-height: 1.8;
    margin-bottom: 1.5rem;
}

/* 第二段简介和第一段之间的间距 */
.about__bio--second {
    margin-top: 1rem;
}

/* --- 技能标签 --- */
.about__skills {
    margin-bottom: 2.5rem;
}

.about__skills-title {
    font-size: 0.85rem;
    font-weight: 600;
    color: #F15A24;
    margin-bottom: 1rem;
    letter-spacing: 0.08em;
}

.about__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.about__tag {
    display: inline-block;
    padding: 0.4rem 1rem;
    border: 1px solid #D0D0D0;
    font-size: 0.85rem;
    color: #555;
    letter-spacing: 0.03em;
    transition: all 0.3s ease;
    cursor: default;
}

.about__tag:hover {
    border-color: #F15A24;
    color: #F15A24;
    background: rgba(241, 90, 36, 0.05);
}

/* --- 联系方式 --- */
.about__contact {
    display: flex;
    flex-wrap: wrap;
    gap: 3rem;
}

.about__contact-item {
    font-size: 1.1rem;
    color: #ddd;
    position: relative;
    transition: color 0.3s ease;
}

.about__contact-item[href]:hover {
    color: #F15A24;
}

/* 联系方式之间的分隔线 */
.about__contact-item + .about__contact-item::before {
    content: '';
    position: absolute;
    left: -0.85rem;
    top: 50%;
    transform: translateY(-50%);
    width: 1px;
    height: 12px;
    background: #D0D0D0;
}

/* --- VIEW RESUME 按钮（右侧顶部，与头像框上边对齐） --- */
.about__resume-btn {
    margin-bottom: 2.5rem;
}

.about__resume-link {
    font-size: 1.1rem;
    color: #F15A24;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1.4rem;
    border-radius: 50px;
    background: #FFFFFF;
    transition: opacity 0.3s ease;
    cursor: pointer;
}

/* 左右尖括号 < VIEW RESUME > */
.about__resume-link::before { content: '<'; }
.about__resume-link::after  { content: '>'; }

.about__resume-link:hover {
    opacity: 0.75;
}

/* ============================================================
   作品展示区 Portfolio
   ============================================================ */
.portfolio {
    position: relative;
    background: #111111;
    padding: 0;
}

.portfolio__inner {
    display: flex;
    max-width: 1620px;
    margin: 0 auto;
    position: relative;
    z-index: 9;
}

/* --- 左侧：粘性固定面板 --- */
.portfolio__sticky {
    flex: 0 0 35%;
    align-self: flex-start;
    position: sticky;
    top: 0;
    height: 100vh;
    display: flex;
    flex-direction: column;
    padding: 5rem 2rem;
    z-index: 1;
}

/* 编号放在顶部 */
.portfolio__number {
    font-size: 0.875rem;
    display: block;
}

/* 编号和正文之间的弹性区域：把正文推到面板垂直居中 */
.portfolio__sticky-body {
    flex: 1;
    display: flex;
    align-items: center;
}

.portfolio__sticky-info {
    width: 100%;
}

.portfolio__number {
    font-size: 0.875rem;
    display: block;
}

.portfolio__number .text {
    color: #FFFFFF;
}

.portfolio__card-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #999;
    line-height: 1.4;
    margin-bottom: 1rem;
    letter-spacing: 0.05em;
    transition: opacity 0.35s ease;
}

.portfolio__card-desc {
    font-size: 2.5rem;
    font-weight: 400;
    color: #FFFFFF;
    line-height: 1.2;
    transition: opacity 0.35s ease;
}

/* --- 右侧：可滚动图片区 --- */
.portfolio__scroll {
    flex: 0 0 65%;
}

.portfolio__gallery-item {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 7rem 2rem 3rem 0;
}

/* --- 轮播容器 --- */
.portfolio__card-gallery {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    border-radius: 20px;
}

/* 图片轨道：所有图片一字排开，用 transform 丝滑切换 */
.gallery__track {
    display: flex;
    height: 100%;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform;
}

.gallery__slide {
    flex: 1;
    height: 100%;
    overflow: hidden;
}

.gallery__slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    pointer-events: none;
}

/* --- 左右箭头（半透明圆形） --- */
.gallery__arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    border: none;
    color: #FFF;
    font-size: 1.8rem;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.25s ease, opacity 0.3s ease;
    z-index: 2;
    backdrop-filter: blur(4px);
}

.gallery__arrow:hover {
    background: rgba(255, 255, 255, 0.3);
}

.gallery__arrow--prev {
    left: 10px;
}

.gallery__arrow--next {
    right: 10px;
}

/* --- 外层容器 --- */
.portfolio__card-gallery-wrapper {
    width: 100%;
}

/* --- 圆点指示器 --- */
.gallery__dots {
    display: flex;
    gap: 8px;
    margin-top: 0.6rem;
    align-items: center;
}

.gallery__dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #555;
    transition: background 0.3s ease, transform 0.3s ease;
    cursor: default;
}

.gallery__dot.active {
    background: #F15A24;       /* 橙色，表示当前图片 */
    transform: scale(1.3);
}

/* ============================================================
   响应式适配 — 平板（768px ~ 1024px）
   ============================================================ */
@media (max-width: 1024px) {

    .hero__title--single {
        font-size: 3.6rem;
    }

    .hero__bar {
        width: 110px;
    }

    .about__body {
        gap: 3rem;
    }

    .about__avatar {
        width: 150px;
        height: 150px;
    }

    .portfolio__inner {
        flex-direction: column;
    }

    .portfolio__sticky {
        flex: 0 0 auto;
        position: static;
        height: auto;
        padding: 4rem 1.5rem 2rem;
        text-align: left;
    }

    .portfolio__scroll {
        flex: 0 0 auto;
        width: 100%;
    }

    .portfolio__gallery-item {
        min-height: auto;
        padding: 1.5rem;
    }

    .portfolio__card-gallery {
        aspect-ratio: 16 / 10;
    }

    .portfolio__card-gallery-wrapper {
        width: 100%;
    }

    .portfolio__card-title {
        font-size: 0.85rem;
    }

    .portfolio__card-desc {
        font-size: 2rem;
    }
}

/* ============================================================
   响应式适配 — 手机（< 768px）
   ============================================================ */
@media (max-width: 768px) {

    /* 导航栏 */
    .nav {
        top: 0.8rem;
    }

    .nav__inner {
        padding: 0 1rem;
    }

    .nav__menu {
        padding: 0.4rem 1.2rem;
        border-radius: 40px;
    }

    /* Hero */
    .hero__inner {
        padding: 5rem 1.5rem;
    }

    .hero__title--single {
        font-size: 2.8rem;
    }

    .hero__desc {
        font-size: 0.85rem;
        max-width: 260px;
    }

    .hero__bar {
        width: 80px;
        opacity: 0.3;
        right: 15%;
        left: auto !important;
        pointer-events: none;
    }

    /* 手机上隐藏亮色文字层（因为没鼠标，效果没意义） */
    .hero__content--light {
        display: none;
    }

    .hero__status {
        left: 1.5rem;
        bottom: 1.5rem;
    }

    /* About */
    .about {
        height: auto;
        min-height: 100vh;
    }

    .about__inner {
        padding: 0 1.5rem;
    }

    .about__body {
        flex-direction: column;
        gap: 2rem;
    }

    .about__avatar-area {
        flex-direction: row;
        gap: 1.5rem;
        text-align: left;
    }

    .about__avatar {
        width: 100px;
        height: 100px;
        margin-bottom: 0;
    }

    .section-title {
        font-size: 2rem;
    }

    /* Portfolio */
    .portfolio__inner {
        flex-direction: column;
    }

    .portfolio__sticky {
        flex: 0 0 auto;
        position: static;
        height: auto;
        padding: 3rem 1.5rem 2rem;
        text-align: left;
    }

    .portfolio__scroll {
        flex: 0 0 auto;
        width: 100%;
    }

    .portfolio__gallery-item {
        min-height: auto;
        padding: 1.5rem;
    }

    .portfolio__card-gallery {
        aspect-ratio: 16 / 10;
    }

    .portfolio__card-gallery-wrapper {
        width: 100%;
    }

    .portfolio__card-title {
        font-size: 0.8rem;
    }

    .portfolio__card-desc {
        font-size: 1.8rem;
    }

    /* 右侧菜单面板 — 手机全宽 */
    .menu-panel__body {
        width: 100vw;
        min-width: unset;
        padding: 1rem 1.5rem;
    }

    .menu-panel__name {
        font-size: 1.3rem;
    }
}

/* ============================================================
   右侧滑出菜单面板
   ============================================================ */

/* 遮罩层：挡住主页面，淡入淡出 */
.menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(255, 255, 255, 0.5);
    z-index: 1999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.35s ease;
}

.menu-overlay--active {
    opacity: 1;
    pointer-events: auto;
}

/* 面板：全宽容器，用 inner 对齐导航栏网格 */
.menu-panel {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 100vh;
    z-index: 2000;
    transform: translateX(100%);
    transition: transform 0.45s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none;
}

.menu-panel--open {
    transform: translateX(0);
    pointer-events: auto;
}

/* 内层：和 nav__inner 完全相同的容器 */
.menu-panel__inner {
    max-width: 1620px;
    margin: 0 auto;
    padding: 0 2rem;
    height: 100%;
    display: flex;
    justify-content: flex-end;
}

/* 实际橙色面板 */
.menu-panel__body {
    width: 23vw;
    min-width: 230px;
    height: 100%;
    background: #F15A24;
    display: flex;
    flex-direction: column;
    padding: 1.2rem 2rem;
}

/* --- 顶部栏：Menu / 01—03 / Close --- */
.menu-panel__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4rem;
}

.menu-panel__label {
    font-size: 0.8rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.7);
    letter-spacing: 0.06em;
}

.menu-panel__range {
    font-size: 0.8rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.6);
    letter-spacing: 0.04em;
}

.menu-panel__close {
    font-size: 0.9rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.7);
    letter-spacing: 0.06em;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    font-family: inherit;
    transition: color 0.3s ease;
}

.menu-panel__close:hover {
    color: #FFFFFF;
}

/* --- 章节列表 --- */
.menu-panel__nav {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.menu-panel__link {
    display: flex;
    align-items: baseline;
    gap: 1rem;
    padding: 1.4rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.25);
    text-decoration: none;
    transition: opacity 0.3s ease;
}

.menu-panel__link:hover {
    opacity: 0.6;
}

.menu-panel__num {
    font-size: 0.8rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.7);
    letter-spacing: 0.04em;
    flex-shrink: 0;
    width: 1.5rem;
}

.menu-panel__name {
    font-size: 1.6rem;
    font-weight: 600;
    color: #FFFFFF;
    letter-spacing: 0.04em;
}

/* --- 底部 --- */
.menu-panel__footer {
    padding-top: 2rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.menu-panel__footer-link {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.5);
    letter-spacing: 0.04em;
}

.menu-panel__footer-divider {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.35);
}

/* ============================================================
   作品详情页
   ============================================================ */
.detail {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: #0D0D0D;
    z-index: 900;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
}

.detail--open {
    display: block;
}

.detail__images {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3rem;
    padding: 6rem 0 5rem;
}

.detail__images img {
    width: 95vw;
    max-width: 1600px;
    height: auto;
    display: block;
}

.detail__video {
    width: 95vw;
    max-width: 1600px;
    display: block;
    outline: none;
    background: #000;
}

/* B站嵌入播放器 16:9 */
.detail__bilibili {
    aspect-ratio: 16 / 9;
    height: auto;
    border: none;
}

/* 可点击的幻灯片 */
.gallery__slide--clickable {
    cursor: pointer;
}

/* ============================================================
   滚动淡入效果
   ============================================================ */
.fade-up {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
    will-change: opacity, transform;
}

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

/* 延迟序列：让About区域各元素依次淡入 */
.fade-up-delay-1 { transition-delay: 0s; }
.fade-up-delay-2 { transition-delay: 0.15s; }
.fade-up-delay-3 { transition-delay: 0.3s; }
.fade-up-delay-4 { transition-delay: 0.45s; }
.fade-up-delay-5 { transition-delay: 0.6s; }
