/* ==========================================================================
   PERSONAL ARCHIVE — style.css
   Palette / 背景 #F1EFE9 · 主文字 #17191D · 辅助 #6B7077 · 科技蓝 #5279A8
   ========================================================================== */

/* ---------- 1. Design tokens ---------- */
:root {
  --bg: #F1EFE9;
  --bg-soft: #E8E5DC;
  --ink: #17191D;
  --muted: #6B7077;
  --blue: #5279A8;
  --blue-light: #8FAFD4;
  --line: rgba(23, 25, 29, 0.14);
  --line-strong: rgba(23, 25, 29, 0.3);

  --container: 1440px;
  --gutter: clamp(20px, 5vw, 72px);
  --header-h: 72px;

  --font-sans: "Helvetica Neue", Helvetica, Arial, "Hiragino Sans GB",
    "Microsoft YaHei", "PingFang SC", sans-serif;
  --font-mono: "SF Mono", "JetBrains Mono", "Cascadia Mono", Consolas,
    "Courier New", monospace;
  --font-serif: "Times New Roman", "Songti SC", SimSun, serif;

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

/* ---------- 2. Reset & base ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 8px);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background-color: var(--bg);
  background-image: radial-gradient(rgba(23, 25, 29, 0.055) 0.5px, transparent 0.5px);
  background-size: 4px 4px;
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

h1, h2, h3, h4, p, figure, dl, dd, ol, ul {
  margin: 0;
}

ol, ul {
  padding: 0;
  list-style: none;
}

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

button {
  font: inherit;
  color: inherit;
}

svg {
  display: block;
}

::selection {
  background: var(--blue);
  color: var(--bg);
}

:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 4px;
}

/* 锚点偏移统一由 html 的 scroll-padding-top 控制 */

/* ---------- 3. Utilities ---------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 200;
  padding: 10px 16px;
  background: var(--ink);
  color: var(--bg);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  transform: translateY(-160%);
  transition: transform 0.3s var(--ease);
}

.skip-link:focus-visible {
  transform: translateY(0);
}

/* ---------- 4. Header & navigation ---------- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(241, 239, 233, 0.86);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid transparent;
  transition: background-color 0.3s var(--ease), border-color 0.3s var(--ease);
}

.site-header.is-scrolled {
  background: rgba(241, 239, 233, 0.95);
  border-bottom-color: var(--line);
}

body.nav-open .site-header {
  background: var(--bg);
}

.header-inner {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: 100%;
  max-width: var(--container);
  height: var(--header-h);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.brand {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  background: var(--ink);
  color: var(--bg);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.04em;
  transition: background-color 0.3s var(--ease);
}

.brand:hover .brand-mark {
  background: var(--blue);
}

.brand-name {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.site-nav {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.nav-list {
  display: flex;
  align-items: center;
  gap: clamp(16px, 2.2vw, 34px);
}

.nav-link {
  position: relative;
  display: inline-flex;
  align-items: baseline;
  gap: 5px;
  padding: 6px 0;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.1em;
  color: var(--ink);
  white-space: nowrap;
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: var(--blue);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.35s var(--ease);
}

.nav-link:hover::after,
.nav-link:focus-visible::after,
.nav-link.is-active::after {
  transform: scaleX(1);
}

.nav-num {
  font-size: 8px;
  color: var(--muted);
  transition: color 0.3s var(--ease);
}

.nav-link.is-active .nav-num,
.nav-link:hover .nav-num {
  color: var(--blue);
}

.nav-cn {
  display: none;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin-left: 6px;
}

.nav-foot {
  display: none;
}

.header-tools {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 18px;
  flex-shrink: 0;
}

.header-date {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.1em;
  color: var(--muted);
  white-space: nowrap;
}

.nav-toggle {
  display: none;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  background: none;
  border: 0;
  cursor: pointer;
}

.nav-toggle-label {
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.16em;
}

.nav-toggle-bars {
  position: relative;
  display: block;
  width: 22px;
  height: 11px;
}

.nav-toggle-bars span {
  position: absolute;
  left: 0;
  width: 100%;
  height: 1.5px;
  background: var(--ink);
  transition: top 0.35s var(--ease), transform 0.35s var(--ease);
}

.nav-toggle-bars span:first-child {
  top: 0;
}

.nav-toggle-bars span:last-child {
  top: 9.5px;
}

body.nav-open .nav-toggle-bars span:first-child {
  top: 4.75px;
  transform: rotate(45deg);
}

body.nav-open .nav-toggle-bars span:last-child {
  top: 4.75px;
  transform: rotate(-45deg);
}

/* scroll progress */
.scroll-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 1px;
  overflow: hidden;
  pointer-events: none;
}

.scroll-progress-bar {
  display: block;
  height: 100%;
  background: var(--blue);
  transform: scaleX(0);
  transform-origin: left center;
}

/* ---------- 5. Hero ---------- */
.section {
  position: relative;
  padding: clamp(72px, 9vw, 140px) 0;
}

.hero {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 100vh;
  min-height: 100svh;
  padding-top: calc(var(--header-h) + clamp(48px, 8vh, 96px));
  padding-bottom: clamp(32px, 5vh, 56px);
}

.hero-inner {
  position: relative;
  z-index: 1;
  display: flex;
  flex: 1;
  flex-direction: column;
  justify-content: center;
  padding-bottom: 0;
}

.hero-arc-clip {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.hero-arc {
  position: absolute;
  top: 50%;
  right: -14vw;
  z-index: 0;
  width: clamp(280px, 42vw, 680px);
  height: clamp(320px, 54vw, 680px);
  border: 1px solid rgba(23, 25, 29, 0.18);
  border-radius: 50%;
  transform: translateY(-50%);
  pointer-events: none;
}

.eyebrow {
  display: flex;
  align-items: center;
  margin-bottom: clamp(20px, 4vh, 44px);
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--muted);
}

.eyebrow::before {
  content: "";
  width: 6px;
  height: 6px;
  margin-right: 12px;
  background: var(--blue);
}

.hero-title {
  margin: 0;
  font-size: clamp(2.9rem, 12.2vw, 11rem);
  font-weight: 500;
  line-height: 0.84;
  letter-spacing: -0.045em;
  text-transform: uppercase;
}

.hero-line {
  display: block;
}

.hero-title .dot {
  color: var(--blue);
}

.hero-name {
  margin: 0 0 clamp(18px, 3vh, 30px);
  font-family: var(--font-sans);
  font-size: clamp(6rem, 1.2vw, 1.2rem);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: 0.26em;
  color: var(--ink);
}

.hero-signatures {
  margin-top: clamp(34px, 6vh, 60px);
}

.hero-signature-main {
  font-size: clamp(1.2rem, 1.85vw, 1.55rem);
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: -0.005em;
  color: var(--ink);
}

.hero-signature-sub {
  max-width: 44ch;
  margin-top: clamp(8px, 1.2vh, 12px);
  font-size: clamp(0.82rem, 1.02vw, 0.95rem);
  line-height: 1.9;
  letter-spacing: 0.01em;
  color: var(--muted);
}

/* 首屏载入的克制入场动画 */
.eyebrow,
.hero-name,
.hero-line,
.hero-signatures {
  animation: rise-in 1s var(--ease) both;
}

.hero-name {
  animation-delay: 0s;
}

.hero-line:first-child {
  animation-delay: 0.06s;
}

.hero-line:nth-child(2) {
  animation-delay: 0.14s;
}

.hero-signatures {
  animation-delay: 0.26s;
}

@keyframes rise-in {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ---------- 6. Section headings ---------- */
.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px 48px;
  margin-bottom: clamp(36px, 5vw, 64px);
}

.section-index {
  margin-bottom: 14px;
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}

.index-num {
  color: var(--blue);
}

.index-sep {
  margin: 0 8px;
  opacity: 0.5;
}

.section-title {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 18px;
  font-size: clamp(2.6rem, 6.5vw, 5.6rem);
  font-weight: 500;
  line-height: 0.9;
  letter-spacing: -0.04em;
}

.title-cn {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(0.95rem, 1.4vw, 1.15rem);
  font-weight: 400;
  letter-spacing: 0.1em;
  color: var(--muted);
}

.section-note {
  max-width: 34ch;
  padding-bottom: 6px;
  font-size: 12px;
  line-height: 1.8;
  color: var(--muted);
  text-align: right;
}

.section--about,
.section--projects,
.section--interests {
  border-top: 1px solid var(--line);
}

.section--about {
  overflow: hidden;
}

/* ---------- 7. About ---------- */
.about-head {
  margin-bottom: clamp(36px, 4.8vw, 64px);
}

.about-title {
  display: block;
}

.about-title .dot {
  color: var(--blue);
}

.about-editorial {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  grid-template-areas:
    "copy visual"
    "resume visual";
  gap: clamp(36px, 4.2vw, 60px);
  align-items: start;
}

.about-column {
  grid-area: copy;
  min-width: 0;
}

.about-block {
  padding-top: clamp(18px, 2.4vw, 24px);
  border-top: 1px solid var(--line);
}

.about-block + .about-block {
  margin-top: clamp(32px, 4.5vw, 52px);
}

.about-kicker {
  font-family: var(--font-mono);
  font-size: 8.5px;
  line-height: 1.4;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--blue);
}

.about-block-title {
  margin-top: 10px;
  font-size: clamp(1.35rem, 2vw, 1.8rem);
  font-weight: 500;
  line-height: 1.25;
  letter-spacing: -0.02em;
}

.about-text {
  max-width: 52ch;
  margin-top: 14px;
  font-size: 14px;
  line-height: 1.95;
  color: var(--ink);
}

.about-visual {
  grid-area: visual;
  position: relative;
  justify-self: stretch;
  width: 100%;
  max-width: 100%;
  align-self: center;
}

.about-gallery {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(14px, 1.5vw, 20px);
  align-content: start;
  align-items: start;
  width: 100%;
  padding-top: clamp(10px, 1.2vw, 16px);
}

.about-arc {
  position: absolute;
  top: 50%;
  left: calc(100% - clamp(40px, 8vw, 120px));
  z-index: 0;
  width: clamp(320px, 30vw, 440px);
  height: clamp(440px, 44vw, 620px);
  border: 1px solid rgba(23, 25, 29, 0.09);
  border-radius: 50%;
  clip-path: inset(0 50% 0 0);
  transform: translateY(-50%);
  pointer-events: none;
}

.about-photo {
  min-width: 0;
  margin: 0;
}

@media (min-width: 901px) {
  .about-photo:nth-child(2) {
    align-self: center;
  }
}

.about-photo-media {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: var(--photo-ratio, 3 / 4);
  overflow: hidden;
  border: 1px solid var(--line);
  background-color: var(--bg-soft);
  background-image:
    linear-gradient(rgba(23, 25, 29, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(23, 25, 29, 0.045) 1px, transparent 1px);
  background-size: 28px 28px;
  background-position: center;
}

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

.about-photo-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 12px;
  text-align: center;
  pointer-events: none;
}

.about-photo-index {
  font-family: var(--font-mono);
  font-size: 8px;
  letter-spacing: 0.16em;
  color: var(--blue);
}

.about-photo-label {
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.18em;
  color: var(--ink);
}

.about-photo-note {
  font-family: var(--font-mono);
  font-size: 7px;
  line-height: 1.5;
  letter-spacing: 0.1em;
  color: var(--muted);
}

.about-resume {
  grid-area: resume;
  margin-top: 0;
}

.resume-button {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  width: min(100%, 320px);
  padding: 15px 18px;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: var(--bg);
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.3s var(--ease), border-color 0.3s var(--ease);
}

.resume-button:hover {
  border-color: var(--blue);
  background: #24282f;
}

.resume-button:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 4px;
}

.resume-icon {
  flex: 0 0 auto;
  width: 20px;
  height: 20px;
  color: var(--blue-light);
}

.resume-icon svg {
  width: 100%;
  height: 100%;
}

.resume-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.resume-cn {
  font-size: 14px;
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: 0.02em;
  color: #fff;
}

.resume-en {
  font-family: var(--font-mono);
  font-size: 7.5px;
  line-height: 1.4;
  letter-spacing: 0.12em;
  color: rgba(241, 239, 233, 0.55);
}

.resume-arrow {
  margin-left: auto;
  font-size: 16px;
  line-height: 1;
  color: var(--blue-light);
  transition: transform 0.3s var(--ease);
}

.resume-button:hover .resume-arrow {
  transform: translate(3px, -3px);
}

/* ---------- 8. Projects ---------- */
/* 编辑式项目网格：两列两排，左文右图，无卡片底、无阴影。 */
.project-archive {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: clamp(48px, 6vw, 96px);
  row-gap: clamp(56px, 7vw, 96px);
  align-items: start;
}

.project-entry {
  display: grid;
  grid-template-columns: minmax(0, 1fr) clamp(160px, 15vw, 216px);
  align-items: start;
  gap: clamp(24px, 2.8vw, 40px);
  min-width: 0;
  padding-top: clamp(18px, 2vw, 26px);
  border-top: 1px solid var(--line);
}

.project-entry-copy {
  min-width: 0;
}

.project-entry-num {
  display: block;
  margin-bottom: clamp(16px, 1.8vw, 22px);
  font-family: var(--font-mono);
  font-size: 9px;
  line-height: 1;
  letter-spacing: 0.18em;
  color: var(--blue);
}

.project-entry-title {
  font-size: clamp(1.35rem, 1.6vw, 1.6rem);
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: -0.015em;
  color: var(--ink);
  text-wrap: balance;
}

.project-entry-en {
  margin-top: 10px;
  font-family: var(--font-mono);
  font-size: 8.5px;
  line-height: 1.6;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--muted);
  overflow-wrap: break-word;
}

.project-entry-desc {
  max-width: 34em;
  margin-top: clamp(14px, 1.6vw, 18px);
  font-size: 14px;
  line-height: 1.9;
  color: var(--muted);
  text-wrap: pretty;
}

/* 1:1 画框 + cover：图片铺满画框。 */
.project-entry-media {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--bg-soft);
}

.project-entry-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

/* CAD project page entry */
.project-entry--cad {
  position: relative;
}

.project-entry--cad .project-entry-aside {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
  min-width: 0;
}

.project-entry--cad .project-entry-aside .project-entry-media {
  width: 100%;
}

.project-entry--cad .project-entry-media img {
  transition: transform 0.7s var(--ease);
}

.project-entry--cad .project-entry-title {
  transition: color 0.3s var(--ease);
}

.project-entry--cad:focus-within .project-entry-title,
.project-entry--cad:focus-within .project-entry-view {
  color: var(--blue);
}

@media (hover: hover) and (pointer: fine) {
  .project-entry--cad:hover .project-entry-media img {
    transform: scale(1.035);
  }

  .project-entry--cad:hover .project-entry-title,
  .project-entry--cad:hover .project-entry-view {
    color: var(--blue);
  }
}

/* ---------- 9. Interests ---------- */
.interest-list {
  border-top: 1px solid var(--line);
}

.interest-item {
  position: relative;
  display: grid;
  grid-template-columns: 56px minmax(0, 0.9fr) minmax(0, 1.5fr) 72px;
  align-items: center;
  gap: clamp(12px, 3vw, 40px);
  padding: clamp(22px, 3vw, 34px) 0;
  border-bottom: 1px solid var(--line);
  transition: padding-left 0.45s var(--ease), background-color 0.45s var(--ease);
}

.interest-item::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 2px;
  background: var(--blue);
  transform: scaleY(0);
  transform-origin: top center;
  transition: transform 0.4s var(--ease);
}

.interest-item:hover {
  padding-left: 18px;
  background-image: linear-gradient(90deg, rgba(82, 121, 168, 0.07), transparent 60%);
}

.interest-item:hover::before {
  transform: scaleY(1);
}

.interest-num {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.12em;
  color: var(--muted);
}

.interest-name h3 {
  font-size: clamp(1.4rem, 2.6vw, 2.1rem);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.02em;
}

.interest-name p {
  margin-top: 8px;
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}

.interest-desc {
  max-width: 46ch;
  font-size: 13px;
  line-height: 1.75;
  color: var(--muted);
}

.interest-fig {
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.12em;
  color: var(--muted);
  text-align: right;
  transition: color 0.35s var(--ease);
}

.interest-item:hover .interest-fig {
  color: var(--blue);
}

/* 电影兴趣条目：整行可点击进入 CINEMA ARCHIVE */
.interest-item--link {
  cursor: pointer;
}

.interest-entry {
  display: inline-block;
  transition: color 0.35s var(--ease);
}

.interest-entry::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
}

.interest-item--link:hover .interest-entry {
  color: var(--blue);
}

.interest-fig--entry {
  color: var(--ink);
  white-space: nowrap;
}

.interest-fig--entry span {
  display: inline-block;
  transition: transform 0.35s var(--ease);
}

.interest-item--link:hover .interest-fig--entry {
  color: var(--blue);
}

.interest-item--link:hover .interest-fig--entry span {
  transform: translate(2px, -2px);
}

.interest-entry:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 4px;
}

@supports selector(:has(*)) {
  .interest-entry:focus-visible {
    outline: none;
  }

  .interest-item--link:has(.interest-entry:focus-visible) {
    outline: 2px solid var(--blue);
    outline-offset: 4px;
  }
}

/* ---------- 10. Contact ---------- */
.section--contact {
  padding-bottom: 0;
  background-color: var(--ink);
  background-image: radial-gradient(rgba(241, 239, 233, 0.05) 0.5px, transparent 0.5px);
  background-size: 4px 4px;
  color: var(--bg);
}

.section-index--light {
  color: rgba(241, 239, 233, 0.55);
}

.section-index--light .index-num {
  color: var(--blue-light);
}

.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: clamp(36px, 6vw, 100px);
  align-items: end;
  margin-top: clamp(20px, 3vw, 40px);
}

.contact-title {
  font-size: clamp(3.4rem, 9.5vw, 8.5rem);
  font-weight: 500;
  line-height: 0.85;
  letter-spacing: -0.05em;
}

.contact-title .dot {
  color: var(--blue-light);
}

.contact-body {
  padding-bottom: 8px;
}

.contact-copy {
  max-width: 40ch;
  font-size: 14.5px;
  line-height: 1.85;
  color: rgba(241, 239, 233, 0.68);
}

.contact-mail {
  display: inline-block;
  max-width: 100%;
  margin-top: 26px;
  padding-bottom: 6px;
  border-bottom: 1px solid rgba(241, 239, 233, 0.38);
  font-size: clamp(1.05rem, 1.9vw, 1.45rem);
  letter-spacing: -0.01em;
  word-break: break-word;
  transition: color 0.3s var(--ease), border-color 0.3s var(--ease);
}

.contact-mail:hover {
  color: var(--blue-light);
  border-color: var(--blue-light);
}

.contact-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 32px;
  margin-top: 44px;
  border-top: 1px solid rgba(241, 239, 233, 0.16);
}

.contact-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
  padding: 13px 0;
  border-bottom: 1px solid rgba(241, 239, 233, 0.16);
}

.contact-row dt {
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.16em;
  color: rgba(241, 239, 233, 0.5);
  white-space: nowrap;
}

.contact-row dd {
  font-size: 11.5px;
  color: rgba(241, 239, 233, 0.86);
  text-align: right;
  word-break: break-word;
}

.contact-row dd a {
  border-bottom: 1px solid transparent;
  transition: color 0.25s var(--ease), border-color 0.25s var(--ease);
}

.contact-row dd a:hover {
  color: var(--blue-light);
  border-bottom-color: currentColor;
}

.site-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px 32px;
  margin-top: clamp(64px, 9vw, 120px);
  padding: 24px 0 30px;
  border-top: 1px solid rgba(241, 239, 233, 0.18);
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.12em;
  color: rgba(241, 239, 233, 0.55);
}

.footer-brand {
  color: var(--bg);
  letter-spacing: 0.18em;
}

.footer-top {
  color: var(--bg);
  transition: color 0.3s var(--ease);
}

.footer-top:hover {
  color: var(--blue-light);
}

.footer-rights {
  flex-basis: 100%;
  margin-top: 8px;
  font-family: var(--font-mono);
  font-size: 7px;
  line-height: 1.6;
  letter-spacing: 0.1em;
  color: rgba(241, 239, 233, 0.48);
}

.section--contact :focus-visible {
  outline-color: var(--blue-light);
}

/* ---------- 11. Reveal on scroll ---------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(26px);
}

[data-reveal].is-visible {
  animation: reveal-in 0.9s var(--ease) forwards;
  animation-delay: var(--reveal-delay, 0s);
}

@keyframes reveal-in {
  from {
    opacity: 0;
    transform: translateY(26px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.project-archive .project-entry:nth-child(2),
.interest-list .interest-item:nth-child(2) {
  --reveal-delay: 0.07s;
}

.project-archive .project-entry:nth-child(3),
.interest-list .interest-item:nth-child(3) {
  --reveal-delay: 0.14s;
}

.project-archive .project-entry:nth-child(4),
.interest-list .interest-item:nth-child(4) {
  --reveal-delay: 0.21s;
}

/* ---------- 12. Responsive ---------- */
@media (max-width: 1100px) {
  .about-editorial {
    gap: clamp(32px, 3.6vw, 48px);
  }

  .about-gallery {
    gap: 14px;
  }

  .about-arc {
    left: calc(100% - clamp(60px, 9vw, 110px));
    width: clamp(280px, 32vw, 360px);
    height: clamp(380px, 44vw, 500px);
  }
}

@media (max-width: 960px) {
  :root {
    --header-h: 64px;
  }

  /* backdrop-filter 会让内部 fixed 导航相对 header 定位，移动端改用实色背景 */
  .site-header,
  .site-header.is-scrolled {
    background: var(--bg);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .header-tools {
    gap: 16px;
  }

  .site-nav {
    position: fixed;
    inset: 0;
    z-index: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: calc(var(--header-h) + 28px) var(--gutter) 30px;
    background-color: var(--bg);
    background-image: radial-gradient(rgba(23, 25, 29, 0.055) 0.5px, transparent 0.5px);
    background-size: 4px 4px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-12px);
    overflow-y: auto;
    overscroll-behavior: contain;
    transition: opacity 0.35s var(--ease), transform 0.35s var(--ease),
      visibility 0.35s;
  }

  body.nav-open .site-nav {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }

  body.nav-open {
    overflow: hidden;
  }

  .nav-list {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }

  .nav-link {
    width: 100%;
    display: grid;
    grid-template-columns: 34px auto 1fr;
    align-items: baseline;
    gap: 0;
    padding: 14px 0;
    border-bottom: 1px solid var(--line);
    font-family: var(--font-sans);
    font-size: clamp(1.65rem, 7.5vw, 2.5rem);
    font-weight: 500;
    letter-spacing: -0.03em;
    line-height: 1;
    white-space: normal;
  }

  .nav-link::after {
    display: none;
  }

  .nav-num {
    font-family: var(--font-mono);
    font-size: 9px;
    letter-spacing: 0.08em;
  }

  .nav-cn {
    display: inline;
    justify-self: start;
    margin-left: 12px;
    font-size: 12px;
  }

  .nav-foot {
    display: block;
    margin-top: 32px;
    font-family: var(--font-serif);
    font-style: italic;
    font-size: 15px;
    color: var(--muted);
  }

  .header-date {
    font-size: 9.5px;
  }

  .section-note {
    text-align: left;
  }

  .project-archive {
    grid-template-columns: minmax(0, 1fr);
    row-gap: clamp(40px, 6vw, 64px);
  }

  .project-entry {
    grid-template-columns: minmax(0, 1fr) clamp(180px, 24vw, 280px);
  }
}

@media (max-width: 760px) {
  .interest-item {
    grid-template-columns: 30px minmax(0, 1fr) auto;
    gap: 4px 16px;
    padding: 24px 0;
  }

  .interest-num {
    grid-column: 1;
    grid-row: 1;
    padding-top: 5px;
  }

  .interest-name {
    grid-column: 2;
    grid-row: 1;
  }

  .interest-desc {
    grid-column: 2 / -1;
    grid-row: 2;
    margin-top: 10px;
    max-width: none;
  }

  .interest-fig {
    grid-column: 3;
    grid-row: 1;
    padding-top: 5px;
  }

  .interest-item:hover {
    padding-left: 0;
  }

  .interest-item:hover::before {
    transform: scaleY(1);
  }
}

@media (max-width: 900px) {
  .about-editorial {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "visual"
      "copy"
      "resume";
    gap: clamp(36px, 5.5vw, 52px);
  }

  .about-visual {
    justify-self: start;
    width: min(100%, 520px);
  }

  .about-gallery {
    gap: clamp(14px, 2.2vw, 18px);
  }

  .about-arc {
    display: none;
  }
}

@media (max-width: 720px) {
  .hero-arc {
    display: none;
  }

  .about-editorial {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "visual"
      "copy"
      "resume";
    gap: clamp(32px, 5vw, 44px);
  }

  .about-visual {
    justify-self: start;
    width: min(100%, 460px);
    max-width: 100%;
  }

  .about-arc {
    display: none;
  }
}

@media (max-width: 640px) {
  .contact-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 32px;
    align-items: start;
  }

  .contact-body {
    padding-bottom: 0;
  }

  .contact-list {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
  }

  .site-footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .footer-top {
    margin-top: 6px;
  }

  .header-date {
    display: none;
  }

  .about-resume {
    margin-top: 0;
  }

  .resume-button {
    width: 100%;
  }

  .about-block + .about-block {
    margin-top: 30px;
  }
}

@media (max-width: 560px) {
  .project-entry {
    grid-template-columns: minmax(0, 1fr);
    gap: 22px;
  }

  .project-entry-media {
    width: 100%;
    max-width: 420px;
  }

  .project-entry-desc {
    max-width: none;
  }
}

@media (max-width: 420px) {
  .brand-name {
    display: none;
  }

  .hero-title {
    font-size: clamp(2.75rem, 13.5vw, 4rem);
  }
}

/* ---------- 13. Motion preferences ---------- */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }

  [data-reveal] {
    opacity: 1;
    transform: none;
  }
}