@font-face {
  font-family: "Calibre";
  src: url("./assets/original/calibre-regular.woff2") format("woff2");
  font-display: swap;
  font-style: normal;
  font-weight: 400;
}

@font-face {
  font-family: "Calibre";
  src: url("./assets/original/calibre-medium.woff2") format("woff2");
  font-display: swap;
  font-style: normal;
  font-weight: 500;
}

:root {
  --container-width: 1080px;
  --page-padding: 48px;
  --content-height: 400px;
  --top-offset: calc((100vh - var(--content-height)) / 2.5);
  --display-inset: 7px;
  --display-radius: 3px;
  --browser-inset: 4px;
  --browser-radius: 12px;
  --browser-inner-radius: 12px;
  --header-height: 230px;
  --display-mobile-height: 400px;
  --display-mobile-top: 40px;
  --bg: #f5f5f5;
  --fg: #171717;
  --secondary: #525252;
  --tertiary: #a1a1a1;
  --elevated: #fafafa;
  --desk-top: #fafafa;
  --desk-front: #ededed;
  --desk-front-end: var(--bg);
  --ring: rgba(49, 65, 88, 0.2);
  --shadow: rgba(0, 0, 0, 0.12);
  --media-placeholder: #e9e9e9;
  --media-placeholder-shine: rgba(255, 255, 255, 0.62);
  color-scheme: light;
}

[data-theme="dark"] {
  --bg: #0a0a0a;
  --fg: #f5f5f5;
  --secondary: #a1a1a1;
  --tertiary: #737373;
  --elevated: #171717;
  --desk-top: #282828;
  --desk-front: #171717;
  --desk-front-end: var(--bg);
  --ring: rgba(64, 64, 64, 0.4);
  --shadow: rgba(0, 0, 0, 0.32);
  --media-placeholder: #171717;
  --media-placeholder-shine: rgba(255, 255, 255, 0.055);
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg);
  overflow-y: scroll;
  scrollbar-gutter: stable;
  -webkit-font-smoothing: antialiased;
  text-rendering: geometricPrecision;
}

body {
  min-height: 100%;
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: "Calibre", ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button,
a {
  color: inherit;
  font: inherit;
}

button {
  border: 0;
  background: transparent;
}

a {
  text-decoration: none;
}

img,
svg {
  display: block;
}

.page-shell {
  position: relative;
  display: flex;
  min-height: 100vh;
  flex-direction: column;
  justify-content: space-between;
  overflow-x: clip;
}

html.project-route-pending .page-shell {
  opacity: 0;
}

/*
 * A detail route opened from another document must render directly in its
 * settled state. Keep transitions disabled for two painted frames so the
 * homepage cannot become the first frame of the restored route.
 */
html.project-route-initial .page-shell,
html.project-route-initial .page-shell * {
  transition: none !important;
}

.page-shell::before {
  position: fixed;
  top: 0;
  left: -10vw;
  z-index: 13;
  width: 120vw;
  height: clamp(220px, 28vh, 290px);
  pointer-events: none;
  content: "";
  opacity: 0;
  transform: translate3d(0, 0, 0) scale(1);
  background:
    radial-gradient(ellipse at 2% 44%, rgba(174, 243, 255, 0.52) 0%, rgba(174, 243, 255, 0.24) 32%, transparent 68%),
    radial-gradient(ellipse at 42% 34%, rgba(204, 255, 196, 0.48) 0%, rgba(204, 255, 196, 0.22) 34%, transparent 70%),
    radial-gradient(ellipse at 96% 42%, rgba(195, 196, 255, 0.5) 0%, rgba(195, 196, 255, 0.24) 32%, transparent 68%),
    conic-gradient(from 205deg at 50% 44%, rgba(174, 243, 255, 0.24), rgba(204, 255, 196, 0.26), rgba(195, 196, 255, 0.24), rgba(174, 243, 255, 0.24));
  background-position:
    0% 46%,
    48% 34%,
    100% 44%,
    50% 42%;
  background-size:
    52% 155%,
    64% 170%,
    54% 155%,
    130% 175%;
  background-repeat: no-repeat;
  filter: blur(30px) saturate(1.32) hue-rotate(0deg);
  mask-image: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.98) 0%,
    rgba(0, 0, 0, 0.82) 44%,
    rgba(0, 0, 0, 0.38) 70%,
    rgba(0, 0, 0, 0.12) 86%,
    transparent 100%
  );
  -webkit-mask-image: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.98) 0%,
    rgba(0, 0, 0, 0.82) 44%,
    rgba(0, 0, 0, 0.38) 70%,
    rgba(0, 0, 0, 0.12) 86%,
    transparent 100%
  );
  transition: opacity 480ms ease;
  will-change: background-position, background-size, filter, transform;
}

.page-shell.about-open::before {
  opacity: 0.82;
}

[data-theme="dark"] .page-shell::before {
  opacity: 0;
  mix-blend-mode: screen;
}

[data-theme="dark"] .page-shell.about-open::before {
  opacity: 0.36;
}

@keyframes aurora-drift {
  0% {
    transform: translate3d(-4vw, -3px, 0) scale(1.02);
    background-position:
      -12% 52%,
      30% 28%,
      112% 48%,
      36% 34%;
    background-size:
      60% 176%,
      76% 196%,
      62% 176%,
      152% 206%;
    filter: blur(30px) saturate(1.24) hue-rotate(-8deg);
  }

  48% {
    transform: translate3d(3vw, 5px, 0) scale(1.06);
    background-position:
      12% 34%,
      56% 48%,
      78% 34%,
      62% 56%;
    background-size:
      76% 210%,
      54% 148%,
      76% 204%,
      112% 154%;
    filter: blur(26px) saturate(1.34) hue-rotate(7deg);
  }

  100% {
    transform: translate3d(5vw, 1px, 0) scale(1.04);
    background-position:
      22% 46%,
      70% 30%,
      86% 54%,
      72% 40%;
    background-size:
      64% 184%,
      72% 188%,
      58% 166%,
      146% 196%;
    filter: blur(30px) saturate(1.26) hue-rotate(14deg);
  }
}

.page-pad {
  width: 100%;
  padding-inline: var(--page-padding);
  transition:
    opacity 360ms cubic-bezier(.2, .8, .2, 1),
    transform 500ms cubic-bezier(.2, .8, .2, 1);
}

.page-shell.project-closing .page-pad,
.page-shell.project-closing .site-footer {
  transition-delay: 150ms;
}

.container {
  width: 100%;
  max-width: var(--container-width);
  margin-inline: auto;
}

.stage {
  position: relative;
  display: flex;
}

.stage::after {
  position: fixed;
  inset: 0;
  z-index: 12;
  pointer-events: none;
  content: "";
  opacity: 0;
  background:
    linear-gradient(
      90deg,
      var(--bg) 0%,
      color-mix(in srgb, var(--bg) 96%, transparent) 28%,
      color-mix(in srgb, var(--bg) 68%, transparent) 58%,
      transparent 100%
    ),
    linear-gradient(
      180deg,
      color-mix(in srgb, var(--bg) 92%, transparent) 0%,
      transparent 36%,
      color-mix(in srgb, var(--bg) 94%, transparent) 100%
    );
  transition: opacity 520ms cubic-bezier(.2, .8, .2, 1);
}

.content-column {
  min-width: 350px;
}

.intro {
  position: sticky;
  top: 0;
  z-index: 50;
  margin-bottom: 56px;
  margin-left: -32px;
  padding-top: var(--top-offset);
  padding-left: 32px;
  background: var(--bg);
  transition: margin-bottom 360ms cubic-bezier(.2, .8, .2, 1);
}

.intro-copy {
  position: relative;
  z-index: 2;
  max-width: 448px;
}

.intro h1 {
  margin: 0 0 4px;
  font-size: 28px;
  font-weight: 500;
  letter-spacing: 0;
  line-height: 1.2;
  transition:
    margin-bottom 280ms ease-out,
    transform 360ms cubic-bezier(.2, .8, .2, 1);
}

.headline {
  max-width: 320px;
  height: 34px;
  margin: 0;
  color: var(--secondary);
  font-size: 28px;
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1.2;
  opacity: 1;
  transform: translateY(0);
  transition:
    height 360ms cubic-bezier(.2, .8, .2, 1),
    opacity 220ms ease,
    transform 360ms cubic-bezier(.2, .8, .2, 1);
}

.headline span {
  display: inline;
}

.more-button {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 12px;
  padding: 0;
  color: var(--tertiary);
  cursor: pointer;
  font-size: 16px;
  font-weight: 500;
  transition: color 180ms ease, transform 360ms cubic-bezier(.2, .8, .2, 1);
}

.more-button:hover {
  color: var(--secondary);
}

.more-button svg {
  width: 10px;
  height: 6px;
  transform: translateY(1px);
  transition: transform 180ms ease;
}

.more-button path {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.more-button[aria-expanded="true"] svg {
  transform: translateY(1px) rotate(180deg);
}

.more-button-open {
  margin-top: 12px;
}

.more-button-close {
  margin-top: 32px;
}

.about-details {
  display: grid;
  width: 100%;
  grid-template-rows: 0fr;
  opacity: 0;
  transform: translate3d(0, 10px, 0);
  transition:
    grid-template-rows 460ms cubic-bezier(.22, 1, .36, 1),
    opacity 240ms ease,
    transform 460ms cubic-bezier(.22, 1, .36, 1);
  will-change: grid-template-rows, opacity, transform;
}

.about-details-inner {
  min-height: 0;
  overflow: hidden;
}

.more-panel {
  max-width: 600px;
  color: var(--secondary);
  font-size: 18px;
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1.36;
}

.about-summary {
  display: grid;
  gap: 16px;
}

.about-summary p {
  margin: 0;
  color: var(--secondary);
}

.experience-section {
  max-width: 600px;
  margin-top: 30px;
}

.experience-section-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 8px;
  color: var(--tertiary);
}

.experience-section-heading h2 {
  margin: 0;
  color: var(--fg);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.04em;
}

.experience-section-heading > span {
  font-size: 13px;
  letter-spacing: 0.02em;
}

.experience-list {
  border-bottom: 1px solid color-mix(in srgb, var(--fg) 10%, transparent);
}

.experience-item {
  border-top: 1px solid color-mix(in srgb, var(--fg) 10%, transparent);
}

.experience-item summary {
  display: grid;
  min-height: 64px;
  padding: 14px 0;
  align-items: center;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 16px;
  cursor: pointer;
  list-style: none;
  transition: color 180ms ease;
}

.experience-item summary::-webkit-details-marker {
  display: none;
}

.experience-item summary:hover .experience-main strong,
.experience-item summary:focus-visible .experience-main strong,
.experience-item.is-open .experience-main strong {
  color: var(--fg);
}

.experience-item summary:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--fg) 32%, transparent);
  outline-offset: 6px;
  border-radius: 3px;
}

.experience-main,
.experience-meta {
  display: flex;
  align-items: baseline;
}

.experience-logo {
  display: block;
  width: 38px;
  height: 38px;
  justify-self: center;
  overflow: hidden;
  border: 0;
  padding: 1px;
  border-radius: 11px;
  background: transparent;
}

[data-theme="dark"] .experience-logo {
  border: 1px solid var(--fg);
  padding: 0;
}

.experience-logo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.experience-main {
  min-width: 0;
  gap: 10px;
}

.experience-main strong {
  color: var(--secondary);
  font-size: 17px;
  font-weight: 500;
  letter-spacing: 0.01em;
  transition: color 180ms ease;
}

.experience-main > span {
  color: var(--tertiary);
  font-size: 14px;
  white-space: nowrap;
}

.experience-meta {
  justify-content: flex-end;
  gap: 12px;
  color: var(--tertiary);
  font-size: 13px;
  white-space: nowrap;
}

.experience-action {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  min-width: 28px;
  color: var(--tertiary);
}

.experience-action svg {
  width: 12px;
  height: auto;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 220ms cubic-bezier(.22, 1, .36, 1);
}

/* 展开时箭头翻转朝上 */
.experience-item.is-open .experience-action svg {
  transform: rotate(180deg);
}

/* 悬浮该条时箭头变深 */
.experience-item summary:hover .experience-action,
.experience-item summary:focus-visible .experience-action {
  color: var(--fg);
}

.experience-detail {
  display: grid;
  grid-template-rows: 0fr;
  overflow: hidden;
  padding-left: 58px;
  color: var(--secondary);
  font-size: 15px;
  line-height: 1.55;
  transition: grid-template-rows 250ms ease-out;
  will-change: grid-template-rows;
}

.experience-detail-inner {
  display: grid;
  min-height: 0;
  gap: 8px;
  overflow: hidden;
  padding-bottom: 0;
  transition: padding-bottom 250ms ease-out;
}

.experience-item.is-open .experience-detail {
  grid-template-rows: 1fr;
}

.experience-item.is-open .experience-detail-inner {
  padding-bottom: 18px;
}

.experience-detail p {
  margin: 0;
}

.experience-note {
  color: var(--tertiary);
  font-size: 13px;
}

.intro-fade {
  position: absolute;
  right: 0;
  bottom: -64px;
  left: 0;
  height: 64px;
  pointer-events: none;
  background: linear-gradient(to bottom, var(--bg) 20%, transparent);
}

.display-wrap {
  position: absolute;
  inset: 0 0 0 500px;
  width: calc(100% - 500px);
  opacity: 1;
  transform: translateY(0) scale(1);
  transition:
    opacity 360ms ease,
    transform 420ms cubic-bezier(.2, .8, .2, 1);
}

.about-visual {
  position: absolute;
  inset: 0 0 0 clamp(520px, 52%, 680px);
  z-index: 18;
  width: auto;
  pointer-events: none;
  opacity: 0;
  transform: translate3d(0, 16px, 0);
  transition:
    opacity 220ms cubic-bezier(.4, 0, .2, 1),
    transform 320ms cubic-bezier(.4, 0, .2, 1);
}

.about-visual-inner {
  position: sticky;
  top: 0;
  display: flex;
  height: 100vh;
  align-items: stretch;
  justify-content: center;
  overflow: hidden;
  padding: 0;
}

.about-lanyard-root {
  position: relative;
  width: min(680px, 64vw);
  height: 100vh;
  min-height: 560px;
  pointer-events: none;
}

.page-shell.about-open .about-visual,
.page-shell.about-open .about-lanyard-root {
  pointer-events: auto;
}

.lanyard-wrapper {
  position: relative;
  width: 100%;
  height: 100%;
  touch-action: none;
  user-select: none;
  visibility: hidden;
  opacity: 0;
}

.lanyard-wrapper.is-ready {
  visibility: visible;
  opacity: 1;
  transition: opacity 120ms ease-out;
}

.lanyard-wrapper canvas {
  display: block;
  width: 100% !important;
  height: 100% !important;
  outline: none;
}

.page-shell.about-open .stage::after {
  opacity: 1;
}

.page-shell.about-open .intro,
.page-shell.about-closing .intro {
  background: transparent;
}

.page-shell.about-open .intro {
  margin-bottom: 80px;
}

.page-shell.about-open .headline {
  height: 0;
  opacity: 0;
  transform: translateY(-8px);
}

.page-shell.about-open .intro h1 {
  margin-bottom: 18px;
}

.page-shell.about-open .about-details {
  grid-template-rows: 1fr;
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

.page-shell.about-open .more-button-open {
  display: none;
}

.page-shell.about-open .more-button-close {
  transform: translateY(0);
}

.page-shell.about-open .display-wrap {
  opacity: 0;
  transform: translate3d(0, 18px, 0) scale(0.97);
  pointer-events: none;
}

.page-shell.about-open .about-visual {
  opacity: 1;
  transform: translate3d(0, 0, 0);
  transition:
    opacity 320ms ease,
    transform 480ms cubic-bezier(.22, 1, .36, 1);
}

/* 收起时：工牌区瞬间消失（不淡出、不缩小），先于显示器退场，避免银色残影 */
.page-shell.about-closing .about-visual {
  opacity: 0;
  transform: translate3d(0, 0, 0);
  transition: opacity 0ms;
}

/* 收起时：背景遮罩快速淡出，避免暗色渐变残留成"影子" */
.page-shell.about-closing .stage::after {
  transition: opacity 200ms cubic-bezier(.4, 0, 1, 1);
}

/* 收起时：显示器延后更久再淡回，等工牌完全退场，两者不重叠 */
.page-shell.about-closing .display-wrap {
  transition:
    opacity 300ms ease 140ms,
    transform 320ms cubic-bezier(.2, .8, .2, 1) 140ms;
}

@media (min-width: 1024px) {
  .page-shell.about-open .container {
    max-width: 1320px;
  }

  .page-shell.about-open .content-column {
    width: 100%;
  }

  .page-shell.about-open .intro {
    display: flex;
    width: clamp(520px, 51%, 680px);
    min-height: 100vh;
    align-items: center;
    margin-bottom: 0;
    padding-top: 0;
  }

  .page-shell.about-open .intro-copy {
    width: 100%;
    max-width: 620px;
  }
}

.display-inner {
  position: sticky;
  top: 0;
  display: flex;
  width: 100%;
  height: 100vh;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding-top: var(--top-offset);
  user-select: none;
}

.display-machine {
  position: relative;
  display: flex;
  width: 100%;
  max-width: 550px;
  flex-direction: column;
  align-items: center;
  background: var(--bg);
}

.monitor {
  position: relative;
  z-index: 10;
  width: 100%;
  padding-top: 58%;
  border-radius: var(--display-radius);
  background: #171717;
  box-shadow: inset 0 0 0 1px var(--ring);
}

.monitor-bezel {
  position: absolute;
  inset: var(--display-inset);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: #e9ecef;
}

.screen-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.screen-bg-dark,
.stand-dark,
.keyboard-dark {
  display: none;
}

[data-theme="dark"] .screen-bg-light,
[data-theme="dark"] .stand-light,
[data-theme="dark"] .keyboard-light {
  display: none;
}

[data-theme="dark"] .screen-bg-dark,
[data-theme="dark"] .stand-dark,
[data-theme="dark"] .keyboard-dark {
  display: block;
}

.glass-layer {
  position: absolute;
  width: 80%;
  padding-top: 46.4%;
  border-radius: var(--browser-radius);
  background: rgba(241, 245, 249, 0.4);
  box-shadow: inset 0 0 0 0.5px var(--ring), 0 20px 25px -5px var(--shadow);
  backdrop-filter: blur(4px);
}

.browser-frame {
  position: absolute;
  width: 80%;
  padding-top: 46.4%;
  overflow: hidden;
  border-radius: var(--browser-radius);
  box-shadow:
    0 0 0 var(--browser-inset) rgba(255, 255, 255, 0.5),
    0 0 0 calc(var(--browser-inset) + 0.5px) rgba(49, 65, 88, 0.08),
    0 26px 42px -22px rgba(0, 0, 0, 0.24),
    0 8px 16px -14px rgba(0, 0, 0, 0.22);
  background: transparent;
  transition: box-shadow 500ms ease;
}

.browser-frame::before {
  position: absolute;
  inset: 0;
  z-index: 5;
  border-radius: inherit;
  content: "";
  pointer-events: none;
  box-shadow: inset 0 0 0 0.5px rgba(49, 65, 88, 0.042);
}

.browser-frame img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  object-fit: cover;
  transition: opacity 160ms ease;
}

#preview-image.is-committing {
  opacity: 1;
  transition: none;
}

.preview-image-next {
  z-index: 3;
  opacity: 0;
  transition: opacity 160ms ease;
}

.preview-image-next.is-visible {
  opacity: 1;
}

.preview-image-next.is-resetting {
  opacity: 0;
  transition: none;
}

.browser-frame video {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: none;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  object-fit: cover;
}

.browser-frame video.is-visible {
  display: block;
}

.stand {
  position: relative;
  z-index: 4;
  display: flex;
  width: 100%;
  flex-direction: column;
  align-items: center;
}

.stand-image {
  width: 129%;
  min-width: 129%;
  height: auto;
  margin-top: -1px;
}

.keyboard-image {
  width: 90%;
  height: auto;
  margin-top: -3%;
}

.desk {
  position: absolute;
  bottom: -34%;
  left: -20%;
  width: 164%;
  transform-origin: top;
}

.desk-top {
  height: 75px;
  background: linear-gradient(to bottom, var(--bg), var(--desk-top));
  clip-path: polygon(13.2% 0, 86.8% 0, 100% 100%, 0 100%);
}

.desk-front {
  height: 150px;
  background: linear-gradient(to bottom, var(--desk-front), var(--desk-front-end));
}

.desk::before,
.desk::after {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 30%;
  content: "";
  pointer-events: none;
}

.desk::before {
  left: 0;
  background: linear-gradient(to left, transparent, var(--bg) 70%);
}

.desk::after {
  right: 0;
  background: linear-gradient(to right, transparent, var(--bg) 70%);
}

.project-list {
  position: relative;
  z-index: 20;
  width: 350px;
  padding-bottom: 24vh;
  opacity: 1;
  transform: translateY(0);
  transition:
    opacity 420ms ease,
    transform 520ms cubic-bezier(.2, .8, .2, 1);
}

.project-list-inner {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-left: -18px;
}

.project-button {
  position: relative;
  display: flex;
  width: 100%;
  cursor: pointer;
  align-items: center;
  justify-content: space-between;
  border-radius: 18px;
  min-height: 52px;
  padding: 12px 52px 12px 18px;
  overflow: visible;
  text-align: left;
  color: color-mix(in srgb, var(--secondary) 60%, transparent);
  isolation: isolate;
  transition:
    color 220ms cubic-bezier(.2, .8, .2, 1),
    filter 260ms ease,
    opacity 260ms ease;
}

.project-button::before {
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: 999px;
  content: "";
  opacity: 0;
  background: rgba(250, 250, 250, 0.62);
  box-shadow:
    0 -10px 28px -24px rgba(0, 0, 0, 0.22),
    0 -1px 2px rgba(255, 255, 255, 0.72),
    0 10px 18px -14px rgba(0, 0, 0, 0.18),
    0 22px 58px -34px rgba(0, 0, 0, 0.34),
    0 42px 92px -64px rgba(0, 0, 0, 0.22),
    0 0 0 1px rgba(0, 0, 0, 0.02),
    inset 0 -2px 0 rgba(255, 255, 255, 0.95),
    inset 0 2px 0 rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(22px) saturate(1.2);
  -webkit-backdrop-filter: blur(22px) saturate(1.2);
  transition: opacity 220ms cubic-bezier(.2, .8, .2, 1);
}

[data-theme="dark"] .project-button::before {
  background: rgba(18, 18, 18, 0.66);
  box-shadow:
    0 -10px 30px -24px rgba(0, 0, 0, 0.92),
    0 10px 18px -14px rgba(0, 0, 0, 0.72),
    0 24px 66px -34px rgba(0, 0, 0, 0.98),
    0 44px 96px -64px rgba(0, 0, 0, 0.8),
    0 0 0 1px rgba(255, 255, 255, 0.04),
    inset 0 -2px 0 rgba(255, 255, 255, 0.04),
    inset 0 2px 0 rgba(255, 255, 255, 0.12);
}

.project-button:hover,
.project-button.is-active {
  color: var(--fg);
}

.project-button:hover::before,
.project-button.is-active::before {
  opacity: 1;
}

.project-button:hover {
  transform: none;
}

/* hover 抑制期间：禁用鼠标悬停高亮，只保留当前 active，避免出现两个高亮胶囊 */
.page-shell.hover-locked .project-button:hover {
  color: color-mix(in srgb, var(--secondary) 60%, transparent);
}

.page-shell.hover-locked .project-button:hover::before {
  opacity: 0;
}

.page-shell.hover-locked .project-button.is-active {
  color: var(--fg);
}

.page-shell.hover-locked .project-button.is-active::before {
  opacity: 1;
}

.project-button h3 {
  margin: 0;
  font-size: 20px;
  font-weight: 500;
  letter-spacing: 0;
  line-height: 1.2;
}

.project-arrow {
  position: absolute;
  top: 50%;
  right: 17px;
  display: grid;
  width: 22px;
  height: 22px;
  place-items: center;
  color: var(--tertiary);
  opacity: 0;
  transform: translate(-7px, -50%) scale(0.92);
  transition:
    opacity 220ms cubic-bezier(.2, .8, .2, 1),
    transform 220ms cubic-bezier(.2, .8, .2, 1),
    color 220ms ease;
}

.project-arrow svg {
  width: 16px;
  height: 16px;
}

.project-arrow path {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.project-button:hover .project-arrow,
.project-button.is-active .project-arrow {
  color: var(--secondary);
  opacity: 1;
  transform: translate(0, -50%) scale(1);
}

.site-footer {
  position: sticky;
  bottom: 0;
  z-index: 60;
  display: flex;
  width: fit-content;
  align-items: center;
  gap: 24px;
  margin-top: -132px;
  margin-left: auto;
  padding: 80px 22px 20px 80px;
  color: var(--secondary);
  opacity: 0.72;
  transition: opacity 180ms ease, transform 320ms cubic-bezier(.2, .8, .2, 1);
}

.site-footer:hover {
  opacity: 1;
}

.page-shell.about-open .project-list {
  max-height: 0;
  padding-bottom: 0;
  overflow: hidden;
  opacity: 0;
  transform: translate3d(0, 20px, 0);
  pointer-events: none;
}

.page-shell.about-open .site-footer {
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
}

.social-links {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 13px;
  font-weight: 500;
  line-height: 32px;
}

.social-links a,
.social-links button {
  opacity: 0.5;
  cursor: pointer;
  transition: opacity 160ms ease;
}

.social-links a:hover,
.social-links button:hover {
  opacity: 1;
}

.wechat-contact {
  position: relative;
  display: flex;
  align-items: center;
}

.wechat-qr-card {
  position: absolute;
  right: -8px;
  bottom: calc(100% + 12px);
  z-index: 80;
  display: grid;
  width: 188px;
  gap: 8px;
  padding: 10px 10px 9px;
  border: 1px solid color-mix(in srgb, var(--fg) 10%, transparent);
  border-radius: 8px;
  background: color-mix(in srgb, var(--elevated) 96%, transparent);
  box-shadow: 0 14px 38px rgba(0, 0, 0, 0.16);
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
  transform: translate3d(0, 6px, 0) scale(0.98);
  transform-origin: calc(100% - 24px) 100%;
  transition:
    visibility 0s linear 180ms,
    opacity 160ms ease,
    transform 180ms cubic-bezier(.22, 1, .36, 1);
}

.wechat-qr-card::after {
  position: absolute;
  right: 24px;
  bottom: -5px;
  width: 9px;
  height: 9px;
  border-right: 1px solid color-mix(in srgb, var(--fg) 10%, transparent);
  border-bottom: 1px solid color-mix(in srgb, var(--fg) 10%, transparent);
  background: var(--elevated);
  content: "";
  transform: rotate(45deg);
}

.wechat-contact:hover .wechat-qr-card,
.wechat-contact:focus-within .wechat-qr-card {
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
  transform: translate3d(0, 0, 0) scale(1);
  transition-delay: 0s;
}

.wechat-qr-card img {
  width: 100%;
  height: auto;
  border-radius: 4px;
}

.wechat-qr-card span {
  color: var(--secondary);
  font-size: 13px;
  line-height: 1.3;
  text-align: center;
}

.theme-switcher {
  position: relative;
  display: flex;
  height: 34px;
  align-items: center;
  gap: 3px;
  border-radius: 10px;
  padding: 4px;
  background: rgba(229, 229, 229, 0.7);
}

[data-theme="dark"] .theme-switcher {
  background: rgba(38, 38, 38, 0.5);
}

.theme-switcher button {
  position: relative;
  z-index: 2;
  display: flex;
  width: 26px;
  height: 26px;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  color: var(--tertiary);
}

.theme-switcher button.is-active {
  color: var(--fg);
}

.theme-switcher svg {
  width: 23px;
  height: 23px;
}

.theme-switcher path,
.theme-switcher circle {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.45;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.theme-thumb {
  position: absolute;
  top: 4px;
  left: 4px;
  z-index: 1;
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: var(--elevated);
  box-shadow: 0 1px 3px rgba(0,0,0,0.12), 0 0 0 0.5px rgba(0,0,0,0.04);
  transition: transform 180ms ease;
}

.theme-switcher[data-active="light"] .theme-thumb {
  transform: translateX(29px);
}

.theme-switcher[data-active="dark"] .theme-thumb {
  transform: translateX(58px);
}

.project-detail {
  position: fixed;
  inset: 0;
  z-index: 90;
  overflow: hidden;
  background: var(--bg);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition:
    opacity 360ms cubic-bezier(.65, 0, .35, 1),
    visibility 0s linear 360ms;
}

.project-detail-shell {
  width: min(var(--container-width), calc(100% - var(--page-padding) * 2));
  margin-inline: auto;
  padding: 54px 0 86px;
}

.project-back {
  display: grid;
  width: 48px;
  height: 48px;
  cursor: pointer;
  place-items: center;
  margin-bottom: 52px;
  padding: 0;
  border-radius: 999px;
  color: var(--secondary);
  background: rgba(250, 250, 250, 0.58);
  box-shadow:
    0 16px 28px -20px rgba(0, 0, 0, 0.28),
    0 7px 12px -9px rgba(0, 0, 0, 0.18),
    0 0 0 1px rgba(255, 255, 255, 0.58),
    inset 0 1px 0 rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(18px) saturate(1.2);
  -webkit-backdrop-filter: blur(18px) saturate(1.2);
  transition:
    color 160ms ease,
    background 180ms ease,
    transform 220ms cubic-bezier(.2, .8, .2, 1),
    box-shadow 180ms ease;
}

.project-back:hover {
  color: var(--fg);
  background: rgba(255, 255, 255, 0.78);
  box-shadow:
    0 18px 34px -20px rgba(0, 0, 0, 0.34),
    0 8px 14px -9px rgba(0, 0, 0, 0.22),
    0 0 0 1px rgba(255, 255, 255, 0.72),
    inset 0 1px 0 rgba(255, 255, 255, 0.84);
  transform: translateX(-2px) scale(1.02);
}

[data-theme="dark"] .project-back {
  color: rgba(255, 255, 255, 0.88);
  background: rgba(255, 255, 255, 0.1);
  box-shadow:
    0 16px 32px -20px rgba(0, 0, 0, 0.72),
    0 0 0 1px rgba(255, 255, 255, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

[data-theme="dark"] .project-back:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  box-shadow:
    0 18px 38px -20px rgba(0, 0, 0, 0.8),
    0 0 0 1px rgba(255, 255, 255, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.project-back span {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.project-back svg {
  width: 24px;
  height: 24px;
}

.project-back path {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.project-detail-card {
  display: grid;
  grid-template-columns: minmax(280px, 0.8fr) minmax(440px, 1.2fr);
  gap: 64px;
  align-items: center;
}

.project-detail-copy,
.project-detail-media {
  opacity: 1;
  transform: none;
}

.project-detail-media {
  transform: none;
}

.project-detail-kicker {
  margin: 0 0 10px;
  color: var(--tertiary);
  font-size: 15px;
  font-weight: 500;
}

.project-detail-title {
  max-width: 640px;
  margin: 0;
  color: var(--fg);
  font-size: clamp(24px, 3vw, 34px);
  font-weight: 500;
  letter-spacing: 0;
  line-height: 1.08;
  white-space: nowrap;
}

.project-detail-description {
  max-width: 460px;
  margin: 16px 0 0;
  color: var(--secondary);
  font-size: 18px;
  line-height: 1.36;
}

.project-detail-highlights {
  max-width: 460px;
  margin: 24px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 16px;
}

.project-detail-highlights[hidden] {
  display: none;
}

.project-detail-highlights li {
  display: grid;
  gap: 4px;
  padding-left: 14px;
  border-left: 2px solid color-mix(in srgb, var(--fg) 18%, transparent);
}

.project-detail-highlights .highlight-label {
  font-size: 16px;
  font-weight: 600;
  color: var(--fg);
}

.project-detail-highlights .highlight-text {
  font-size: 15px;
  line-height: 1.5;
  color: var(--tertiary);
}

.project-detail-link {
  display: inline-flex;
  margin-top: 28px;
  color: var(--fg);
  font-size: 16px;
  font-weight: 500;
  text-decoration: underline;
  text-decoration-color: color-mix(in srgb, currentColor 28%, transparent);
  text-underline-offset: 4px;
}

.project-detail-links {
  display: flex;
  flex-wrap: nowrap;
  gap: clamp(14px, 1.35vw, 22px);
  margin-top: 28px;
}

.project-detail-links[hidden] {
  display: none;
}

.project-detail-links .project-detail-link {
  margin-top: 0;
  flex: 0 0 auto;
  white-space: nowrap;
  font-size: clamp(14px, 1vw, 16px);
}

.project-detail-links.is-prominent {
  gap: clamp(24px, 2vw, 36px);
  margin-top: 32px;
}

.project-detail-links.is-prominent .project-detail-link {
  min-height: 48px;
  padding: 8px 4px;
  align-items: center;
  font-size: clamp(17px, 1.2vw, 19px);
  line-height: 1.35;
}

.project-detail-media {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: var(--browser-radius);
  background: transparent;
  box-shadow: none;
}

.project-detail-media img {
  width: 100%;
  height: 100%;
  aspect-ratio: auto 16 / 9;
  object-fit: cover;
  transition: opacity 180ms ease;
}

.project-detail.has-gallery .project-detail-media img {
  aspect-ratio: 16 / 9;
}

.project-detail-media img[data-zoomable="true"],
.project-gallery img[data-zoomable="true"] {
  cursor: zoom-in;
}

.project-detail-media img[data-zoomable="true"]:focus-visible,
.project-gallery img[data-zoomable="true"]:focus-visible {
  outline: none;
}

/* 灯箱关闭时由脚本还原的焦点不显示外框；正常 Tab 导航仍保留焦点提示。 */
.project-detail-media img.is-lightbox-focus-returned:focus,
.project-gallery img.is-lightbox-focus-returned:focus {
  outline: none;
}

.project-gallery {
  display: grid;
  gap: 24px;
  margin-top: 72px;
}

.project-gallery[hidden] {
  display: none;
}

.project-gallery img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 12px;
  box-shadow:
    0 24px 70px -54px rgba(0, 0, 0, 0.32),
    0 0 0 1px rgba(0, 0, 0, 0.04);
}

.project-gallery > .gallery-image {
  aspect-ratio: auto 16 / 9;
  object-fit: cover;
  background: var(--media-placeholder);
}

.project-gallery .gallery-media {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  line-height: 0;
  overflow: hidden;
  border-radius: 12px;
  background: var(--media-placeholder);
  box-shadow:
    0 24px 70px -54px rgba(0, 0, 0, 0.32),
    0 0 0 1px rgba(0, 0, 0, 0.04);
}

.project-gallery .gallery-media img {
  height: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  transition: opacity 180ms ease;
}

@keyframes media-placeholder-shimmer {
  from { background-position: 180% 0; }
  to { background-position: -80% 0; }
}

.project-gallery .gallery-media.is-loading,
.project-gallery > .gallery-image.is-loading {
  background-color: var(--media-placeholder);
  background-image: linear-gradient(
    100deg,
    transparent 28%,
    var(--media-placeholder-shine) 46%,
    transparent 64%
  );
  background-size: 220% 100%;
  animation: media-placeholder-shimmer 1.35s ease-in-out infinite;
}

.project-detail-media.is-loading > img,
.project-gallery .gallery-media.is-loading > img {
  opacity: 0;
}

.project-gallery .gallery-media.is-load-error,
.project-gallery > .gallery-image.is-load-error {
  background: var(--media-placeholder);
}

.project-gallery .gallery-slot {
  position: absolute;
  overflow: hidden;
  border-radius: 4px;
  background: #000;
  cursor: zoom-in;
  transform: scale(1.01);
}

.project-gallery .gallery-slot-video {
  display: block;
  width: 100%;
  /* 高出 2% 并顶部对齐：把录屏底部那条白边挤出容器裁掉，不动到底部真实内容 */
  height: 102%;
  object-fit: cover;
  object-position: center top;
}

.project-gallery .gallery-slot.is-uncropped .gallery-slot-video {
  height: 100%;
  object-position: center;
}

.project-gallery .gallery-lottie-trigger {
  position: absolute;
  z-index: 2;
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.001);
  cursor: zoom-in;
}

.project-gallery .gallery-lottie-trigger:focus-visible {
  outline: 2px solid #00bfa6;
  outline-offset: 3px;
}

.project-gallery .gallery-link-slot {
  position: absolute;
  z-index: 2;
  display: block;
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.001);
  cursor: pointer;
}

.project-gallery .gallery-link-slot:focus-visible {
  outline: 2px solid #00bfa6;
  outline-offset: 3px;
}

.image-lightbox {
  position: fixed;
  inset: 0;
  z-index: 130;
  display: grid;
  overflow: auto;
  place-items: center;
  padding: 40px;
  background: rgba(0, 0, 0, 0.78);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  opacity: 0;
  pointer-events: none;
  cursor: zoom-out;
  transition: opacity 280ms ease;
}

.image-lightbox.is-open {
  opacity: 1;
  pointer-events: auto;
}

.image-lightbox-frame {
  position: relative;
  max-width: 100%;
  line-height: 0;
  /* 不做 scale 缩放动画：图片是位图层、视频是独立合成层，缩放时无法逐帧同步，
     会露出图片里的白框。改为只靠容器 opacity 淡入，图片与视频始终 1:1 对齐。 */
}

.image-lightbox-media {
  display: block;
  width: auto;
  max-width: min(92vw, 1800px);
  height: auto;
  max-height: calc(100vh - 80px);
  border-radius: 16px;
  background: #0a0a0a;
  box-shadow: 0 44px 120px -36px rgba(0, 0, 0, 0.9);
  object-fit: contain;
  user-select: none;
}

.image-lightbox-slot {
  position: absolute;
  z-index: 1;
  overflow: hidden;
  border-radius: 4px;
  background: #000;
  cursor: zoom-in;
  will-change: transform;
  backface-visibility: hidden;
  transition: box-shadow 0.2s ease, filter 0.2s ease;
}

.image-lightbox-slot:hover {
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.9), 0 18px 40px -16px rgba(0, 0, 0, 0.6);
  filter: brightness(1.05);
}

.image-lightbox-link {
  position: absolute;
  z-index: 2;
  display: block;
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.001);
  cursor: pointer;
}

.image-lightbox-link:focus-visible {
  outline: 2px solid #00bfa6;
  outline-offset: 3px;
}

.image-lightbox-video {
  display: block;
  width: 100%;
  /* 高出 2% 顶部对齐，裁掉录屏底部白边 */
  height: 102%;
  object-fit: cover;
  object-position: center top;
}

.image-lightbox-close {
  position: fixed;
  top: 24px;
  right: 24px;
  display: grid;
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: 999px;
  color: #fff;
  background: rgba(30, 30, 30, 0.64);
  box-shadow: 0 12px 36px -16px rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  cursor: pointer;
  place-items: center;
  transition: background 180ms ease, transform 180ms ease;
}

.image-lightbox-close:hover {
  background: rgba(54, 54, 54, 0.82);
  transform: scale(1.05);
}

.image-lightbox-close:focus-visible {
  outline: none;
}

.image-lightbox-close svg {
  width: 20px;
  height: 20px;
}

.image-lightbox-close path {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
}

.video-lightbox {
  position: fixed;
  inset: 0;
  /* 高于图片灯箱(130)，这样在放大的图上点视频，视频灯箱能盖在其之上 */
  z-index: 140;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.28s ease;
  cursor: zoom-out;
}

.video-lightbox.is-open {
  opacity: 1;
  pointer-events: auto;
}

.video-lightbox-frame {
  overflow: hidden;
  width: min(92vw, 40vh);
  aspect-ratio: 1124 / 2436;
  max-width: 92vw;
  max-height: 86vh;
  border-radius: 24px;
  box-shadow: 0 44px 120px -40px rgba(0, 0, 0, 0.85);
  transform: scale(0.9);
  transition: transform 0.32s cubic-bezier(0.2, 0.7, 0.2, 1);
  line-height: 0;
  background: #000;
}

.video-lightbox.is-open .video-lightbox-frame {
  transform: scale(1);
}

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

.lottie-lightbox {
  position: fixed;
  inset: 0;
  z-index: 145;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.28s ease;
  cursor: zoom-out;
}

.lottie-lightbox.is-open {
  opacity: 1;
  pointer-events: auto;
}

.lottie-lightbox-frame {
  position: relative;
  width: min(94vw, 1600px);
  aspect-ratio: 1920 / 836;
  overflow: hidden;
  border-radius: 20px;
  background: #eafffd;
  box-shadow: 0 44px 120px -40px rgba(0, 0, 0, 0.85);
  transform: scale(0.94);
  transition: transform 0.32s cubic-bezier(0.2, 0.7, 0.2, 1);
  cursor: default;
}

.lottie-lightbox.is-open .lottie-lightbox-frame {
  transform: scale(1);
}

.lottie-lightbox-background {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  user-select: none;
}

.lottie-lightbox-media {
  position: absolute;
  z-index: 1;
  overflow: hidden;
}

.lottie-lightbox-media,
.lottie-lightbox-media svg {
  display: block;
}

.lottie-lightbox-media svg {
  width: 100% !important;
  height: 100% !important;
}

.lottie-lightbox {
  position: fixed;
  inset: 0;
  z-index: 145;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.28s ease;
  cursor: zoom-out;
}

.lottie-lightbox.is-open {
  opacity: 1;
  pointer-events: auto;
}

.lottie-lightbox-frame {
  position: relative;
  width: min(94vw, 1600px);
  aspect-ratio: 1920 / 836;
  overflow: hidden;
  border-radius: 20px;
  background: #eafffd;
  box-shadow: 0 44px 120px -40px rgba(0, 0, 0, 0.85);
  transform: scale(0.94);
  transition: transform 0.32s cubic-bezier(0.2, 0.7, 0.2, 1);
  cursor: default;
}

.lottie-lightbox.is-open .lottie-lightbox-frame {
  transform: scale(1);
}

.lottie-lightbox-background {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  user-select: none;
}

.lottie-lightbox-media {
  position: absolute;
  z-index: 1;
  overflow: hidden;
}

.lottie-lightbox-media,
.lottie-lightbox-media svg {
  display: block;
}

.lottie-lightbox-media svg {
  width: 100% !important;
  height: 100% !important;
}

body.lightbox-open {
  overflow: hidden;
}

/* 项目详情入场/退场的共享元素动画期间锁住页面滚动：
   克隆元素是 position:fixed、落点按 scrollY=0 计算，若动画途中滚动，
   真实内容会随滚动位移而克隆不动，造成标题/封面/画廊重叠错位。 */
html:has(.page-shell.project-transitioning) {
  overflow: hidden;
}

[data-theme="dark"] .project-gallery > img,
[data-theme="dark"] .project-gallery .gallery-media {
  box-shadow:
    0 24px 70px -54px rgba(0, 0, 0, 0.8),
    0 0 0 1px rgba(255, 255, 255, 0.06);
}

.project-bottom-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
  margin-top: 72px;
}

.project-pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 168px;
  height: 52px;
  padding: 0 28px;
  cursor: pointer;
  border: none;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 500;
  color: var(--fg);
  background: rgba(250, 250, 250, 0.62);
  box-shadow:
    0 -10px 28px -24px rgba(0, 0, 0, 0.22),
    0 -1px 2px rgba(255, 255, 255, 0.72),
    0 10px 18px -14px rgba(0, 0, 0, 0.18),
    0 22px 58px -34px rgba(0, 0, 0, 0.34),
    0 42px 92px -64px rgba(0, 0, 0, 0.22),
    0 0 0 1px rgba(0, 0, 0, 0.02),
    inset 0 -2px 0 rgba(255, 255, 255, 0.95),
    inset 0 2px 0 rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(22px) saturate(1.2);
  -webkit-backdrop-filter: blur(22px) saturate(1.2);
  transition:
    color 160ms ease,
    transform 220ms cubic-bezier(.2, .8, .2, 1),
    box-shadow 220ms cubic-bezier(.2, .8, .2, 1);
}

.project-pill-btn:hover {
  transform: translateY(-2px);
}

.project-pill-btn:active {
  transform: translateY(0);
}

.project-pill-btn svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.project-pill-btn path {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

[data-theme="dark"] .project-pill-btn {
  background: rgba(18, 18, 18, 0.66);
  box-shadow:
    0 -10px 30px -24px rgba(0, 0, 0, 0.92),
    0 10px 18px -14px rgba(0, 0, 0, 0.72),
    0 24px 66px -34px rgba(0, 0, 0, 0.98),
    0 44px 96px -64px rgba(0, 0, 0, 0.8),
    0 0 0 1px rgba(255, 255, 255, 0.04),
    inset 0 -2px 0 rgba(255, 255, 255, 0.04),
    inset 0 2px 0 rgba(255, 255, 255, 0.12);
}

.project-back,
.project-detail-kicker,
.project-detail-description,
.project-detail-highlights,
.project-detail-link {
  opacity: 0;
  transform: translateY(8px);
  transition:
    opacity 360ms cubic-bezier(.65, 0, .35, 1),
    transform 460ms cubic-bezier(.65, 0, .35, 1);
}

.page-shell.project-open .page-pad,
.page-shell.project-open .site-footer {
  opacity: 0;
  filter: none;
  transform: none;
  pointer-events: none;
}

.page-shell.project-open .project-detail {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition:
    opacity 360ms cubic-bezier(.65, 0, .35, 1),
    visibility 0s;
}

.page-shell.project-open .project-back,
.page-shell.project-open .project-detail-kicker,
.page-shell.project-open .project-detail-description,
.page-shell.project-open .project-detail-highlights,
.page-shell.project-open .project-detail-link {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 280ms;
}

.page-shell.project-closing .project-detail {
  opacity: 0;
  visibility: visible;
  pointer-events: none;
  transition:
    opacity 460ms cubic-bezier(.65, 0, .35, 1),
    visibility 0s linear 540ms;
}

.page-shell.project-closing .project-back,
.page-shell.project-closing .project-detail-kicker,
.page-shell.project-closing .project-detail-description,
.page-shell.project-closing .project-detail-highlights,
.page-shell.project-closing .project-detail-link {
  opacity: 0;
  transform: translateY(8px);
  transition-delay: 0ms;
  transition-duration: 280ms;
}

.page-shell.project-transitioning .browser-frame img,
.page-shell.project-transitioning .browser-frame video,
.page-shell.project-transitioning .project-detail-media img,
.page-shell.project-transitioning .project-detail-title,
.page-shell.project-transitioning .project-button.is-active h3 {
  visibility: hidden;
}

.page-shell.project-transitioning .browser-frame::before {
  opacity: 0;
}

.page-shell.project-transitioning .browser-frame {
  box-shadow:
    0 0 0 var(--browser-inset) rgba(255, 255, 255, 0),
    0 0 0 calc(var(--browser-inset) + 0.5px) rgba(49, 65, 88, 0),
    0 26px 42px -22px rgba(0, 0, 0, 0.24),
    0 8px 16px -14px rgba(0, 0, 0, 0.22);
}

.shared-cover-clone,
.shared-title-clone {
  position: fixed;
  z-index: 140;
  pointer-events: none;
  transform-origin: top left;
  will-change: top, left, width, height, transform, opacity, border-radius;
}

.shared-cover-clone {
  overflow: hidden;
  border-radius: var(--browser-radius);
  background: transparent;
  box-shadow: none;
  contain: paint;
}

.shared-cover-clone img {
  width: 100%;
  height: 100%;
  border-radius: inherit;
  object-fit: cover;
}

.shared-title-clone {
  margin: 0;
  color: var(--fg);
  white-space: nowrap;
}

@media (max-width: 1023px) {
  :root {
    --top-offset: 52px;
    --page-padding: 40px;
    --display-inset: 5px;
    --browser-inset: 3px;
  }

  .page-shell {
    min-height: 100vh;
  }

  .stage {
    justify-content: center;
  }

  .content-column {
    min-width: 0;
    width: 100%;
  }

  .intro {
    position: relative;
    z-index: 24;
    min-height: var(--header-height);
    height: auto;
    margin: 0;
    padding: var(--top-offset) 0 0;
  }

  .intro h1,
  .headline {
    font-size: 24px;
  }

  .headline {
    height: 30px;
  }

  .more-panel {
    max-width: 620px;
    font-size: 17px;
    line-height: 1.4;
  }

  .about-summary {
    gap: 14px;
  }

  .experience-section {
    max-width: 620px;
  }

  .experience-item summary {
    min-height: 72px;
    grid-template-columns: 44px minmax(0, 1fr);
    gap: 8px;
  }

  .experience-logo {
    grid-row: 1 / span 2;
    width: 36px;
    height: 36px;
  }

  .experience-main {
    justify-content: space-between;
  }

  .experience-meta {
    grid-column: 2;
    justify-content: space-between;
  }

  .experience-detail {
    padding-left: 52px;
  }

  .intro-fade {
    display: none;
  }

  .display-wrap {
    pointer-events: none;
    position: sticky;
    top: var(--display-mobile-top);
    right: 0;
    bottom: auto;
    left: 0;
    z-index: 10;
    width: 100%;
    height: var(--display-mobile-height);
  }

  .about-visual {
    position: relative;
    top: auto;
    right: 0;
    left: 0;
    z-index: 18;
    width: 100%;
    height: var(--display-mobile-height);
    margin-top: 24px;
  }

  .about-visual-inner {
    height: var(--display-mobile-height);
    padding-top: 0;
    padding-right: 0;
    align-items: stretch;
  }

  .about-lanyard-root {
    width: 100%;
    height: var(--display-mobile-height);
    min-height: 0;
  }

  .lanyard-wrapper {
    touch-action: pan-y;
  }

  .page-shell.about-open .intro {
    margin-bottom: 0;
  }

  .page-shell.about-open .intro-copy {
    padding-inline: clamp(20px, 3.2vw, 32px);
  }

  .page-shell.about-open .experience-section {
    margin-top: 26px;
  }

  .page-shell.about-open .site-footer {
    display: none;
  }

  .display-inner {
    height: auto;
    padding-top: 0;
  }

  .display-machine {
    max-width: 400px;
  }

  .desk {
    bottom: -20%;
    left: -32%;
  }

  .desk-front {
    height: 75px;
  }

  .desk::before,
  .desk::after {
    width: 22%;
  }

  .project-list {
    z-index: 6;
    width: min(350px, calc(100vw - var(--page-padding) * 2));
    max-width: 350px;
    margin-top: 40px;
    margin-inline: auto;
    padding-bottom: calc(100vh - var(--display-mobile-height) - 180px);
  }

  .project-list-inner {
    position: relative;
    z-index: 1;
    margin-left: 0;
    gap: 10px;
  }

  .project-button.is-before-active {
    opacity: 0.5;
    filter: blur(0.2px);
  }

  .project-button.is-prev-1 {
    opacity: 0.58;
  }

  .project-button.is-prev-2 {
    opacity: 0.2;
  }

  .project-button.is-before-far {
    opacity: 0.06;
  }

  .project-button.is-active {
    opacity: 1;
    filter: none;
  }

  .project-button {
    min-height: 50px;
    padding-block: 10px;
  }

  .project-button h3 {
    font-size: 18px;
  }

  .site-footer {
    position: relative;
    width: auto;
    justify-content: space-between;
    margin-top: 12vh;
    margin-left: 0;
    padding: 0 var(--page-padding) 28px;
  }

  .social-links {
    order: 2;
    font-size: 14px;
  }

  .project-detail-shell {
    width: calc(100% - var(--page-padding) * 2);
    padding-top: 42px;
  }

  .project-back {
    width: 44px;
    height: 44px;
    margin-bottom: 34px;
  }

  .project-detail-card {
    grid-template-columns: 1fr;
    gap: 34px;
  }

  .project-detail-title {
    max-width: 620px;
    font-size: clamp(24px, 7vw, 34px);
  }

  .project-detail-description {
    max-width: 600px;
    font-size: 17px;
  }
}

@media (max-width: 464px) {
  :root {
    --page-padding: 24px;
    --display-mobile-height: calc(100vw - var(--page-padding) * 2);
  }

  .page-shell.about-open .intro-copy {
    padding-inline: 8px;
  }

  .site-footer {
    align-items: flex-start;
    gap: 18px;
  }

  .experience-section-heading {
    gap: 12px;
  }

  .experience-main {
    align-items: flex-start;
    flex-direction: column;
    gap: 3px;
  }

  .experience-main strong {
    font-size: 16px;
  }

  .experience-meta {
    font-size: 12px;
  }

  .social-links {
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 12px;
  }

  .project-detail-description {
    font-size: 16px;
  }

  .project-detail-links {
    flex-wrap: wrap;
  }

  .project-detail-title {
    font-size: 24px;
    white-space: normal;
  }

  .image-lightbox {
    padding: 20px;
  }

  .image-lightbox-media {
    max-width: calc(100vw - 40px);
    max-height: calc(100vh - 40px);
    border-radius: 10px;
  }

  .image-lightbox-close {
    top: 12px;
    right: 12px;
  }
}
