/* 全局基础样式 */
*,
*::before,
*::after {
    box-sizing: border-box;
}
:root {
    /* 基础流式字号：所有标题以此为基准按倍数缩放，保证比例一致 */
    --base-fluid: clamp(16px, 3.2vw, 40px);

    /* 视觉变量：背景为黑色 5%，文字为亮色 90% */
    --bg: rgb(20, 20, 20);
    --text: rgb(255, 255, 255);

    /* intro 内容行宽（副标题与按钮将使用相同的宽度以对齐） */
    --intro-line-width: min(640px, 86%);
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
        "Microsoft Yahei", sans-serif;
    color: var(--text);
    background-color: var(--bg);
}

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

.container {
    width: 100%;
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 16px;
}

/* 顶部导航 */

.site-header {
    background-color: rgba(0, 0, 0, 0.9);
    color: var(--text);
    position: sticky;
    top: 0;
    z-index: 100;
    transition: transform 0.3s ease;
    transform: translateY(0);
}

.site-header.hidden {
    transform: translateY(-100%);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 20px;
}

.logo {
    display: inline-flex;
    align-items: center;
    width: clamp(72px, 7vw, 96px);
}

.logo img {
    display: block;
    width: 100%;
    height: auto;
}

.nav {
    display: flex;
    gap: 36px;
    font-size: 15px;
}

.nav a {
    position: relative;
}

.nav a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -4px;
    width: 0;
    height: 2px;
    background-color: var(--text);
    transition: width 0.2s ease;
}

.nav a:hover::after {
    width: 100%;
}

.nav a[aria-current="page"]::after {
    width: 100%;
}

.header-icons {
    display: flex;
    gap: 8px;
}

/* SVG / 图像图标样式 */
.header-icons__svg {
    width: 24px;
    height: 24px;
    padding-left: 6px;
    display: inline-block;
    vertical-align: middle;
    object-fit: contain;
    transition: opacity 0.18s ease, transform 0.18s ease;
}

.header-icons__svg:hover {
    opacity: 0.85;
    transform: translateY(-1px);
}

/* hero 区域 */

.hero {
    position: relative;
    background-color: #000;
}

.hero-bg {
    position: relative;
    width: 100%;
    max-width: 100%;
    height: 70vh;
    overflow: hidden;
    background: #000;
}

.hero-bg video {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* intro 主标题 */

.intro {
    background-color: transparent;
    padding: 120px 0 200px;
    text-align: center;
}

.intro-content {
    display: block;
    width: min(880px, 92%);
    max-width: 880px;
    margin: 0 auto;
    text-align: center;
    padding: 0 12px;
    box-sizing: border-box;
}

.intro-title {
    font-size: calc(var(--base-fluid) * 3.2);
    margin: 0 0 32px;
    letter-spacing: 0.06em;
    line-height: 1;
}

.intro-subtitle {
    margin: 0 0 48px;
    font-size: calc(var(--base-fluid) * 1);
    color: var(--text);
        width: var(--intro-line-width);
        max-width: 100%;
        margin-left: auto;
        margin-right: auto;
    display: block;
    width: var(--intro-line-width);
    max-width: 100%;
        width: 100%;
}

.intro-actions {
    display: flex;
    gap: 16px;
    flex-wrap: nowrap;
    justify-content: center;
    width: var(--intro-line-width);
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
}

.intro-actions .btn {
    flex: 1 1 0;
    min-width: 0;
    text-align: center;
}

.btn {
    display: inline-block;
    padding: calc(var(--base-fluid) * 0.28) calc(var(--base-fluid) * 0.6);
    border: 1px solid rgba(255, 255, 255, 0.9);
    font-size: calc(var(--base-fluid) * 0.6);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    background-color: transparent;
    color: var(--text);
    border-radius: 4px;
    transition: background-color 0.12s ease, color 0.12s ease, transform 0.12s ease;
}

.btn:hover {
    background-color: rgba(255, 255, 255, 1);
    color: var(--bg);
    transform: translateY(-2px);
}

/* section 通用 */

.section-title {
    font-size: 68px;
    margin: 0 0 48px;
    display: flex;
    align-items: baseline;
    gap: 24px;
}

.section-sub {
    font-size: 32px;
    color: var(--text);
}

/* What I Do */

.what-i-do {
    background-color: transparent;
    padding: 40px 0 40px;
}

.what-i-do .section-title {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    text-align: left;
}

.what-i-do .section-sub {
    display: block;
}

/* PC 默认布局：左右并排 */
.ability-row {
    display: grid;
    grid-template-columns: minmax(220px, 280px) 1fr;
    grid-template-rows: auto auto;
    grid-template-areas:
        "text carousel"
        "action carousel";
    align-items: center;
    gap: 24px 36px;
    margin-bottom: 4.5rem;
    /* 间距稍大一点，更呼吸 */
}

/* PC 端左右反转（第二组使用） */
.ability-row-reverse {
    grid-template-columns: 1fr minmax(220px, 280px);
    grid-template-areas:
        "carousel text"
        "carousel action";
}

.ability-text {
    grid-area: text;
    text-align: left;
}

.ability-row-reverse .ability-text {
    text-align: right;
}

.ability-title {
    font-size: 28px;
    font-weight: 600;
    margin-bottom: 4px;
}

.ability-subtitle {
    font-size: 16px;
    color: #dedede;
    line-height: 1.6;
    text-align: justify;
}

.ability-row .ability-carousel {
    grid-area: carousel;
}

.ability-action {
    grid-area: action;
    justify-self: start;
    align-self: start;
    margin-top: 18px;
}

.ability-row-reverse .ability-action {
    justify-self: end;
}

.ability-btn {
    padding: 5px 28px;
    font-size: 14px;
    letter-spacing: 0.08em;
    text-transform: none;
}

.ability-carousel {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    position: relative;
}

.card-display {
    position: relative;
    width: min(520px, 100%);
    aspect-ratio: 16 / 9;
    perspective: 1600px;
    transform-style: preserve-3d;
}

.card-hotspot {
    position: absolute;
    top: 0;
    bottom: 0;
    border: none;
    padding: 0;
    margin: 0;
    background: none;
    cursor: pointer;
    pointer-events: auto;
    opacity: 0;
    z-index: 60;
    transform: translateZ(520px);
    will-change: transform;
    touch-action: manipulation;
}

.card-hotspot--prev {
    left: 0;
    right: 50%;
}

.card-hotspot--next {
    left: 50%;
    right: 0;
}

.card {
    --card-shadow-color: rgba(0, 0, 0, 0.32);
    position: absolute;
    top: 50%;
    left: 50%;
    width: 74%;
    aspect-ratio: 16 / 9;
    margin: 0;
    border-radius: 12px;
    overflow: hidden;
    transform-style: preserve-3d;
    transform: translate3d(-50%, -50%, 0) rotateY(0deg);
    transition: transform 0.9s cubic-bezier(0.22, 0.61, 0.36, 1), opacity 0.9s ease, filter 0.9s ease, box-shadow 0.9s ease;
    box-shadow: 0 28px 48px var(--card-shadow-color);
    background: #0d0d0d;
    will-change: transform, box-shadow, filter;
}

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

.card--front {
    --card-shadow-color: rgba(0, 0, 0, 0.6);
    transform: translate3d(-50%, -50%, 260px) rotateY(0deg);
    z-index: 10;
}

.card--left {
    --card-shadow-color: rgba(0, 0, 0, 0.46);
    transform: translate3d(-88%, -50%, 120px) rotateY(45deg) scale(0.90);
    z-index: 5;
    filter: brightness(0.9);
}

.card--right {
    --card-shadow-color: rgba(0, 0, 0, 0.46);
    transform: translate3d(-12%, -50%, 120px) rotateY(-45deg) scale(0.90);
    z-index: 5;
    filter: brightness(0.9);
}

.card--far-left {
    --card-shadow-color: rgba(0, 0, 0, 0.38);
    transform: translate3d(-110%, -50%, 60px) rotateY(50deg) scale(0.80);
    z-index: 4;
    filter: brightness(0.78) saturate(0.9);
    opacity: 0.78;
}

.card--far-right {
    --card-shadow-color: rgba(0, 0, 0, 0.38);
    transform: translate3d(10%, -50%, 60px) rotateY(-50deg) scale(0.80);
    z-index: 4;
    filter: brightness(0.78) saturate(0.9);
    opacity: 0.78;
}

.card--deep-left {
    --card-shadow-color: rgba(0, 0, 0, 0.28);
    transform: translate3d(-130%, -50%, -10px) rotateY(55deg) scale(0.70);
    z-index: 3;
    filter: brightness(0.62) saturate(0.82);
    opacity: 0;
}

.card--deep-right {
    --card-shadow-color: rgba(0, 0, 0, 0.28);
    transform: translate3d(30%, -50%, -10px) rotateY(-55deg) scale(0.7);
    z-index: 3;
    filter: brightness(0.62) saturate(0.82);
    opacity: 0;
}

.card--back {
    --card-shadow-color: rgba(0, 0, 0, 0.24);
    transform: translate3d(-50%, -50%, -260px) scale(0.78);
    opacity: 0;
    z-index: 1;
    filter: blur(2px) brightness(0.7);
}

.card-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.card-control {
    width: auto;
    height: auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: none;
    background: transparent;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.card-control:hover {
    transform: translateY(-1px);
}

.card-control:focus {
    outline: 2px solid rgba(255, 255, 255, 0.8);
    outline-offset: 3px;
}

.card-control img {
    width: 31px;
    height: auto;
    display: block;
    pointer-events: none;
}

.card-plate {
    position: absolute;
    top: 50%;
    width: 22%;
    height: 68%;
    border-radius: 20px;
    background: linear-gradient(180deg, rgba(79, 152, 255, 0.9) 0%, rgba(63, 128, 255, 0.7) 100%);
    filter: drop-shadow(0 24px 36px rgba(60, 120, 255, 0.32));
    transform-style: preserve-3d;
    z-index: 0;
    pointer-events: none;
}

.card-plate--left {
    left: 4%;
    transform: translateY(-50%) rotateY(26deg);
    transform-origin: right center;
}

.card-plate--right {
    right: 4%;
    transform: translateY(-50%) rotateY(-26deg);
    transform-origin: left center;
}

.card-indicators {
    display: flex;
    gap: 8px;
    align-items: center;
    justify-content: center;
}

.card-dot {
    width: 20px;
    height: 3px;
    border-radius: 999px;
    background-color: rgba(255, 255, 255, 0.28);
    pointer-events: none;
    cursor: default;
    transition: background-color 0.3s ease, opacity 0.3s ease;
    padding: 0;
    display: block;
}

.card-dot.is-active {
    background-color: rgba(255, 255, 255, 0.95);
    opacity: 1;
}



/* About */

.about {
    background-color: transparent;
    padding: clamp(72px, 12vw, 140px) 0;
}

.about-container {
    display: flex;
    flex-direction: column;
    gap: clamp(48px, 8vw, 88px);
    align-items: flex-start;
}

.about .section-title {
    margin: 0;
}

.about-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 40px;
    
}

.about-portrait {
    position: relative;
    
    width: 30%;
    aspect-ratio: 1 / 1;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: visible;
}


.about-portrait img {
    position: relative;
    z-index: 1;
    width: 100%;
    
    object-fit: cover;
    border-radius: 50%;
    box-shadow: 0 26px 48px rgba(0, 0, 0, 0.4);
}

.about-details {
    flex: 1 1 var(--about-content-width);
    
    text-align: justify;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    --about-title-width: 280px;
    --about-content-width: clamp(var(--about-title-width), 70%, 100%);
}

.about-name {
    display: flex;
    align-items: baseline;
    gap: 18px;
    margin: 0 0 12px;
}

.about-name__en {
    font-size: 48px;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.about-name__cn {
    font-size: 32px;
    
}

.about-role {
    margin: 0 0 24px;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: rgba(255, 255, 255, 0.94);
}

.about-description {
    width: min(100%, var(--about-content-width));
    width: 100%;
    margin: 0 0 36px;
    line-height: 1.8;
    font-size: 16px;
    color: rgba(255, 255, 255, 0.80);
}

.about-socials {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 36px;
}

.social-link {
    width: 56px;
    height: 56px;
    border-radius: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: none;
    box-shadow: none;
    transition: transform 0.24s ease, box-shadow 0.24s ease;
}

.social-link:hover {
    transform: translateY(-4px);
    box-shadow: none;
}

.social-link img {
    width: 48px;
    
    display: block;
}

.about-message {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 10px 12px 10px 24px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    width: min(100%, var(--about-content-width));
    width: 100%;
    align-self: flex-start;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
}

.about-message input {
    flex: 1 1 auto;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.88);
    font-size: 16px;
    font-family: inherit;
    padding: 8px 0;
}

.about-message input::placeholder {
    color: rgba(255, 255, 255, 0.46);
}

.about-message input:focus {
    outline: none;
}

.about-message button {
    border: none;
    border-radius: 999px;
    background: linear-gradient(135deg, #ffffff 0%, #d6e2ff 100%);
    color: #1d1d1d;
    font-size: 16px;
    font-weight: 600;
    padding: 10px 28px;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.about-message button:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 18px rgba(214, 226, 255, 0.35);
}

/* Works 页面 */

.works-hero {
    padding-bottom: 0;
}

.works-intro {
    padding: clamp(56px, 9vw, 120px) 0 0;
}

.works-intro__inner {
    display: flex;
    justify-content: center;
    text-align: center;
}

.works-intro__content {
    max-width: 720px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.works-intro__title {
    margin: 0;
    font-size: calc(var(--base-fluid) * 2.4);
    letter-spacing: 0.04em;
}

.works-intro__subtitle {
    margin: 0;
    font-size: 18px;
    color: rgba(255, 255, 255, 0.72);
    line-height: 1.8;
}

.works-gallery {
    padding: clamp(64px, 12vw, 140px) 0 clamp(88px, 14vw, 168px);
}

.works-gallery__title {
    width: 100%;
    justify-content: center;
    text-align: center;
    margin-bottom: clamp(40px, 6vw, 72px);
}

.works-gallery__title .section-sub {
    font-size: 28px;
}

.works-tabs {
    display: flex;
    justify-content: center;
    gap: clamp(36px, 8vw, 72px);
    margin-bottom: clamp(48px, 9vw, 96px);
}

.works-tab {
    position: relative;
    padding: 8px 0;
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.68);
    font-size: 22px;
    letter-spacing: 0.04em;
    cursor: pointer;
    transition: color 0.2s ease;
}

.works-tab::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -12px;
    width: 0;
    height: 3px;
    border-radius: 999px;
    background-color: rgba(255, 255, 255, 0.95);
    transition: width 0.25s ease;
}

.works-tab:hover {
    color: rgba(255, 255, 255, 0.9);
}

.works-tab:hover::after,
.works-tab.is-active::after {
    width: 100%;
}

.works-tab.is-active {
    color: rgba(255, 255, 255, 0.96);
}

.works-panels {
    margin-top: clamp(32px, 5vw, 48px);
}

.works-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: clamp(24px, 4vw, 36px);
}

.works-grid[hidden] {
    display: none;
}

.works-grid__empty {
    grid-column: 1 / -1;
    padding: clamp(36px, 5vw, 56px);
    border-radius: 18px;
    text-align: center;
    color: rgba(255, 255, 255, 0.72);
    background: rgba(18, 18, 18, 0.9);
    border: 1px dashed rgba(255, 255, 255, 0.22);
    font-size: 1rem;
    letter-spacing: 0.02em;
}

.work-card {
    border-radius: 18px;
    overflow: hidden;
    background: rgba(15, 15, 15, 0.92);
    box-shadow: 0 30px 50px rgba(0, 0, 0, 0.38);
    position: relative;
    transition: box-shadow 0.18s ease;
}

.work-card::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    border: 1px solid rgba(255, 255, 255, 0.38);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

.work-card:hover,
.work-card:focus-within {
    box-shadow: 0 38px 60px rgba(0, 0, 0, 0.46);
}

.work-card:hover::after,
.work-card:focus-within::after {
    opacity: 1;
}

.work-card__link {
    display: flex;
    flex-direction: column;
    height: 100%;
    color: inherit;
}

.work-card__thumb {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #101010;
    border-radius: 14px;
}

.work-card__media-indicator {
    position: absolute;
    right: 16px;
    bottom: 16px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.92);
    background: rgba(0, 0, 0, 0.68);
    box-shadow: 0 18px 32px rgba(0, 0, 0, 0.42);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    transition: transform 0.18s ease, opacity 0.18s ease;
    pointer-events: none;
    opacity: 0.92;
}

.work-card:hover .work-card__media-indicator,
.work-card:focus-within .work-card__media-indicator {
    transform: scale(1.08);
    opacity: 1;
}

.work-card__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.24s ease;
}

.work-card:hover .work-card__thumb img,
.work-card:focus-within .work-card__thumb img {
    transform: scale(1.05);
}


.work-card__body {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 24px;
}

@media (prefers-reduced-motion: reduce) {
    .work-card__thumb img {
        transition: none;
    }

    .work-card:hover .work-card__thumb img,
    .work-card:focus-within .work-card__thumb img {
        transform: none;
    }

    .work-card::after {
        transition: opacity 0.2s ease;
    }

    .work-card__media-indicator {
        transition: none;
    }

    .project-media__play,
    .project-media__play-icon {
        transition: none;
    }
}

.work-card__title {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.96);
    line-height: 1.4;
}

.work-card__meta {
    margin: 0;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.58);
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* 项目详情页 */

.project-main {
    display: flex;
    flex-direction: column;
    gap: 96px;
    padding: 120px 0 160px;
}

.project-hero__inner {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.project-hero__label {
    margin: 0;
    font-size: 14px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.58);
}

.project-hero__title {
    margin: 0;
    font-size: clamp(42px, 6vw, 72px);
    line-height: 1.08;
    color: rgba(255, 255, 255, 0.96);
}

.project-hero__meta {
    margin: 0;
    font-size: 15px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.52);
}

.project-hero__summary {
    margin: 0;
    max-width: min(720px, 92%);
    font-size: 18px;
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.85);
}

.project-hero__summary p {
    margin: 0 0 1.1em;
}

.project-hero__summary p:last-child {
    margin-bottom: 0;
}

.project-media__figure {
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.project-media__frame {
    position: relative;
    width: 100%;
    border-radius: 28px;
    overflow: hidden;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.35);
}
.project-media__frame::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.14));
    opacity: 0;
    transition: opacity 0.18s ease;
}

.project-media__image {
    width: 100%;
    border-radius: 28px;
    object-fit: cover;
    display: block;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.35);
}
.project-media--has-video .project-media__image {
    box-shadow: none;
}
.project-media__video {
    width: 100%;
    border-radius: 28px;
    display: block;
    background: #000;
    object-fit: cover;
}
.project-media__play {
    position: absolute;
    inset: 0;
    border: none;
    margin: 0;
    padding: 0;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.18), rgba(0, 0, 0, 0.42));
    color: rgba(255, 255, 255, 0.94);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease, opacity 0.2s ease;
    outline: none;
}
.project-media__play:hover,
.project-media__play:focus-visible {
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.22), rgba(0, 0, 0, 0.52));
}
.project-media__play:focus-visible {
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.4);
}
.project-media__play-icon {
    width: 96px;
    height: 96px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.92);
    transition: transform 0.2s ease, color 0.2s ease;
}
.project-media__play:hover .project-media__play-icon,
.project-media__play:focus-visible .project-media__play-icon {
    transform: scale(1.08);
    color: #fff;
}
.project-media__play-icon svg {
    width: 100%;
    height: 100%;
    display: block;
    pointer-events: none;
    filter: drop-shadow(0 18px 36px rgba(0, 0, 0, 0.38));
}
.project-media--has-video .project-media__frame::after {
    opacity: 1;
}
.project-media--playing .project-media__frame::after {
    opacity: 0;
}

.project-media__caption {
    font-size: 13px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.5);
}

.project-gallery {
    margin-top: clamp(32px, 5vw, 56px);
    display: flex;
    flex-direction: column;
    gap: clamp(24px, 5vw, 40px);
}

.project-gallery__item {
    margin: 0;
}

.project-gallery__image {
    width: 100%;
    display: block;
}


.project-back .container {
    display: flex;
    justify-content: flex-end;
}

.project-back__link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.28);
    font-size: 14px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    transition: background-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.project-back__link:hover,
.project-back__link:focus-visible {
    background-color: rgba(255, 255, 255, 1);
    color: #0b0b0b;
    transform: translateY(-2px);
}

/* footer */

.site-footer {
    background-color: #111;
    color: var(--text);
    font-size: 12px;
    padding: 12px 0;
}

.footer-inner {
    text-align: center;
}

/* ========= 仅保留两档布局：PC (>900px) & Mobile (<=900px) ========= */

@media (max-width: 900px) {

    /* hero：视频保持比例不拉伸 */
    .hero-bg {
        display: flex;
        align-items: center;
        justify-content: center;
        height: auto;
        max-height: none;
    }

    .hero-bg img,
    .hero-bg video {
        width: 150%;
        height: auto;
        max-height: 60vh;
        margin: 0 auto;
        flex: 0 0 auto;
    }

    .intro {
        padding: 72px 0 128px;
    }

    .intro-content {
        width: 100%;
        max-width: 720px;
        padding: 0 16px;
        box-sizing: border-box;
        text-align: center;
    }

    .intro-actions {
        flex-direction: column;
        gap: 12px;
        width: var(--intro-line-width);
        max-width: 100%;
        margin-left: auto;
        margin-right: auto;
    }

    .intro-actions .btn {
        width: 100%;
    }

    /* What I Do：标题在上，卡片在下，整体一列居中 */
    .ability-row,
    .ability-row-reverse {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 28px;
        margin-bottom: 64px;
    }

    .ability-text {
        margin-bottom: 0;
        text-align: center;
    }

    .ability-title {
        text-align: center;
        width: 100%;
    }

    .ability-action {
        width: var(--intro-line-width);
        max-width: 100%;
        display: flex;
        justify-content: center;
        margin-top: 8px;
        margin-bottom: 36px;
        margin-left: auto;
        margin-right: auto;
    }

    .ability-action .ability-btn {
        width: 100%;
        margin-left: 0;
        margin-right: 0;
    }

    .ability-carousel {
        width: 100%;
    }

    .card-display {
       
        width: min(360px, 90%);
    }

    .card {
        width: 80%;
    }

    .card--left {
        transform: translate3d(-80%, -50%, 96px) rotateY(45deg) scale(0.92);
    }

    .card--right {
        transform: translate3d(-20%, -50%, 96px) rotateY(-45deg) scale(0.92);
    }

    .card--far-left {
        transform: translate3d(-98%, -50%, 20px) rotateY(50deg) scale(0.84);
        opacity: 0.55;
    }

    .card--far-right {
        transform: translate3d(-2%, -50%, 20px) rotateY(-50deg) scale(0.84);
        opacity: 0.55;
    }

    .card--deep-left {
        transform: translate3d(-110%, -50%, -20px) rotateY(55deg) scale(0.78);
        opacity: 0;
    }

    .card--deep-right {
        transform: translate3d(10%, -50%, -20px) rotateY(-55deg) scale(0.78);
        opacity: 0;
    }

    .card-plate {
        width: 24%;
        height: 64%;
    }

    .card-controls {
        gap: 10px;
    }

    .card-control {
        transform: none;
    }

    .card-control img {
        width: 27px;
        height: auto;
    }

    .card-hotspot {
        width: 50%;
    }

    /* About 区改为竖排居中 */
    .about-container {
        gap: 48px;
        align-items: center;
    }

    .about-content {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 36px;
    }

    .about .section-title {
        align-items: center;
        text-align: center;
    }

    .about-portrait {
        flex: none;
        width: clamp(188px, 52vw, 240px);
    }

    .about-portrait img {
        width: 94%;
        height: 94%;
    }

    .about-details {
        max-width: 640px;
        text-align: center;
        align-items: center;
    }

    .about-name {
        justify-content: center;
        gap: 12px;
    }

    .about-description,
    .about-message {
        width: min(100%, var(--about-content-width));
    }

    .about-description {
        text-align: justify;
    }

    .about-socials {
        justify-content: center;
    }

    .about-message {
        margin: 0 auto;
        padding: 12px 16px 12px 20px;
        align-self: center;
    }

    .works-intro {
        padding: 48px 0 0;
    }

    .works-intro__title {
        font-size: calc(var(--base-fluid) * 1.8);
    }

    .works-intro__subtitle {
        font-size: 16px;
    }

    .works-gallery {
        padding: 56px 0 96px;
    }

    .works-gallery__title {
        margin-bottom: 32px;
    }

    .works-tabs {
        flex-wrap: wrap;
        gap: 18px 28px;
    }

    .works-tab {
        font-size: 18px;
    }

    .works-grid {
        gap: 16px;
        grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    }

    .work-card {
        border-radius: 14px;
    }

    .work-card__thumb {
        border-radius: 10px;
    }

    .work-card__title {
        font-size: 18px;
    }

    .project-main {
        gap: 64px;
        padding: 96px 0 120px;
    }

    .project-hero__title {
        font-size: clamp(36px, 8vw, 58px);
    }

    .project-hero__summary {
        font-size: 17px;
    }

    .project-back .container {
        justify-content: center;
    }
}

@media (max-width: 600px) {
    .works-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
    }

    .work-card__body {
        padding: 18px;
    }

    .work-card__title {
        font-size: 16px;
    }
}