/* ==================================================================
   蒋海平 · Portfolio V3.0
   Editorial layout + rebuilt iPhone 8 Plus device presentation
   ================================================================== */

/* ---------- 01. Tokens & reset ---------- */
:root {
  --paper: #f3f0e9;
  --paper-deep: #ebe7dd;
  --paper-soft: #f8f6f1;
  --ink: #1c1c19;
  --ink-2: #3b3a35;
  --muted: #7b776d;
  --muted-2: #a19b90;
  --line: #1c1c19;
  --line-soft: rgba(28, 28, 25, 0.13);
  --line-faint: rgba(28, 28, 25, 0.07);
  --accent: #b4442f;
  --accent-soft: #dda08e;
  --green: #4f7a5d;
  --shell: 1360px;
  --gutter: clamp(20px, 3.4vw, 52px);
  --ease: cubic-bezier(0.22, 0.72, 0.18, 1);
  --ff-sans: "Helvetica Neue", "Inter", "PingFang SC", "Hiragino Sans GB",
    "Microsoft YaHei", sans-serif;
  --ff-serif: "Songti SC", "STSong", "Noto Serif CJK SC", "SimSun", Georgia, serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 96px;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--ff-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

body.is-locked {
  overflow: hidden;
}

img {
  max-width: 100%;
}

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

button {
  font: inherit;
  color: inherit;
  cursor: pointer;
  background: none;
  border: 0;
}

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

::selection {
  background: var(--ink);
  color: var(--paper);
}

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

/* textures ------------------------------------------------------------------ */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 999;
  pointer-events: none;
  opacity: 0.028;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------- 02. Layout utilities ---------- */
.shell {
  width: 100%;
  max-width: var(--shell);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section {
  padding-block: clamp(76px, 9vw, 132px);
}

.eyebrow {
  display: block;
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--muted);
}

.accent {
  color: var(--accent);
}

.section-head {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding-top: 15px;
  border-top: 1px solid var(--line);
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--ink-2);
}

.section-head--dark {
  border-top-color: rgba(243, 240, 233, 0.28);
  color: rgba(243, 240, 233, 0.55);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 42px;
  min-height: 52px;
  padding: 0 22px;
  background: var(--ink);
  color: var(--paper);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.1em;
  transition: background 0.35s var(--ease), color 0.35s var(--ease);
}

.btn span {
  font-size: 15px;
  line-height: 1;
}

.btn:hover {
  background: var(--accent);
  color: #fff;
}

.link-underline {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 4px;
  border-bottom: 1px solid currentColor;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  transition: color 0.3s var(--ease), gap 0.3s var(--ease);
}

.link-underline:hover {
  color: var(--accent);
  gap: 17px;
}

/* ---------- 03. Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(243, 240, 233, 0.82);
  border-bottom: 1px solid var(--line-soft);
  backdrop-filter: blur(16px) saturate(1.1);
  -webkit-backdrop-filter: blur(16px) saturate(1.1);
  transition: box-shadow 0.4s var(--ease), background 0.4s var(--ease);
}

.site-header.is-scrolled {
  background: rgba(243, 240, 233, 0.94);
  box-shadow: 0 12px 32px -24px rgba(20, 20, 18, 0.45);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  height: 82px;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: -0.02em;
  white-space: nowrap;
}

.wordmark__mark {
  width: 8px;
  height: 8px;
  background: var(--accent);
  transform: rotate(45deg);
  flex: none;
}

.wordmark__cn {
  padding-left: 11px;
  border-left: 1px solid var(--line-soft);
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(6px, 1.4vw, 18px);
  margin-left: auto;
}

.site-nav a {
  position: relative;
  padding: 8px 10px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  transition: color 0.3s var(--ease);
}

.site-nav a::after {
  content: "";
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 3px;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--ease);
}

.site-nav a:hover {
  color: var(--accent);
}

.site-nav a:hover::after {
  transform: scaleX(1);
}

.header-status {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding-left: 20px;
  margin-left: 6px;
  border-left: 1px solid var(--line-soft);
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--ink-2);
  white-space: nowrap;
}

.header-status .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
  animation: pulse 2.8s ease-out infinite;
}

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(79, 122, 93, 0.35); }
  70% { box-shadow: 0 0 0 7px rgba(79, 122, 93, 0); }
  100% { box-shadow: 0 0 0 0 rgba(79, 122, 93, 0); }
}

.back-link {
  padding-left: 0;
  margin-left: 0;
  border-left: 0;
  gap: 7px;
}

.back-link:hover {
  color: var(--accent);
}

/* ---------- 04. Hero ---------- */
.hero {
  position: relative;
  isolation: isolate;
  padding-top: clamp(18px, 2.6vw, 40px);
}

.hero-paper-field {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 0.9;
  -webkit-mask-image: linear-gradient(90deg, #000 0%, #000 44%, transparent 62%);
  mask-image: linear-gradient(90deg, #000 0%, #000 44%, transparent 62%);
}

.hero > .shell {
  position: relative;
  z-index: 1;
}

.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  align-items: center;
  gap: clamp(28px, 4.4vw, 72px);
  min-height: calc(100svh - 200px);
  padding-block: clamp(20px, 3vw, 48px);
}

.hero__kicker {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--muted);
}

.hero h1 {
  margin-top: clamp(34px, 4.4vw, 58px);
  font-size: clamp(50px, 6.05vw, 90px);
  font-weight: 600;
  line-height: 1.12;
  letter-spacing: -0.065em;
}

.hero h1 em {
  display: block;
  font-family: var(--ff-serif);
  font-style: normal;
  font-size: 0.96em;
  font-weight: 700;
  letter-spacing: -0.045em;
  color: var(--accent);
}

.hero__lede {
  max-width: 480px;
  margin-top: clamp(24px, 3vw, 36px);
  font-size: clamp(14px, 1.15vw, 16px);
  line-height: 1.95;
  color: var(--ink-2);
}

.hero__actions {
  display: flex;
  align-items: center;
  gap: clamp(22px, 3vw, 40px);
  margin-top: clamp(28px, 3.4vw, 42px);
}

.hero__facts {
  display: flex;
  gap: clamp(22px, 3.6vw, 54px);
  margin-top: clamp(36px, 4.6vw, 62px);
  padding-top: 17px;
  border-top: 1px solid var(--line-soft);
}

.hero__facts div {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.hero__facts dt {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--muted-2);
}

.hero__facts dd {
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.hero__visual {
  min-width: 0;
}

.hero-stage {
  position: relative;
  height: clamp(520px, 50vw, 690px);
  overflow: hidden;
  background:
    radial-gradient(90% 70% at 72% 28%, rgba(255, 255, 255, 0.12), transparent 55%),
    linear-gradient(158deg, #292a23 0%, #1a1b17 48%, #121310 100%);
  isolation: isolate;
}

.hero-stage::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(90% 80% at 50% 50%, transparent 48%, rgba(10, 10, 9, 0.2) 100%);
  pointer-events: none;
  z-index: 1;
}

.hero-stage::after {
  content: "";
  position: absolute;
  left: 18%;
  bottom: 9%;
  width: 64%;
  height: 58%;
  border-radius: 50%;
  background: rgba(180, 68, 47, 0.22);
  filter: blur(70px);
  z-index: -1;
}

.hero-glyph-field {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 0.96;
}

.hero-stage__label,
.hero-stage__tag,
.hero-stage__side {
  position: absolute;
  z-index: 4;
  color: rgba(243, 240, 233, 0.72);
  text-shadow: 0 1px 12px rgba(8, 8, 7, 0.9);
}

.hero-stage__label {
  top: 22px;
  left: 24px;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.16em;
}

.hero-stage__num {
  position: absolute;
  top: 34px;
  right: 22px;
  font-family: var(--ff-serif);
  font-size: clamp(78px, 8vw, 116px);
  line-height: 0.8;
  color: rgba(243, 240, 233, 0.12);
  letter-spacing: -0.05em;
  z-index: 1;
}

.hero-stage__tag {
  display: flex;
  flex-direction: column;
  gap: 4px;
  left: 24px;
  bottom: 24px;
  padding-left: 14px;
  border-left: 2px solid var(--accent);
}

.hero-stage__tag span {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
}

.hero-stage__tag small {
  font-size: 9px;
  letter-spacing: 0.06em;
  color: rgba(243, 240, 233, 0.5);
}

.hero-stage__side {
  right: 22px;
  bottom: 26px;
  writing-mode: vertical-rl;
  font-size: 8.5px;
  letter-spacing: 0.18em;
  color: rgba(243, 240, 233, 0.42);
}

.hero-stage__chip {
  position: absolute;
  right: 24px;
  top: 50%;
  z-index: 5;
  padding: 7px 11px;
  border: 1px solid rgba(243, 240, 233, 0.24);
  background: rgba(18, 19, 16, 0.55);
  backdrop-filter: blur(8px);
  color: rgba(243, 240, 233, 0.85);
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.14em;
}

.device.hero-device {
  position: absolute;
  z-index: 2;
  filter: drop-shadow(0 36px 40px rgba(0, 0, 0, 0.45));
}

.device.hero-device--front {
  --h: 78%;
  right: 10%;
  bottom: 7%;
  transform: rotate(1.4deg);
}

.device.hero-device--back {
  --h: 63%;
  left: 5%;
  bottom: 13%;
  z-index: 1;
  transform: rotate(-4.5deg);
  opacity: 0.97;
}

@media (min-width: 960px) and (max-width: 1200px) {
  .hero-stage { height: 600px; }
  .device.hero-device--front { --h: 74%; right: 7%; }
  .device.hero-device--back { --h: 59%; left: 2%; }
}

/* ---------- 05. Device (iPhone 8 Plus) ---------- */
.device {
  --h: 460px;
  position: relative;
  width: auto;
  height: var(--h);
  aspect-ratio: 781 / 1584;
  flex: none;
  isolation: isolate;
}

.device__body {
  position: absolute;
  inset: 0;
  border-radius: 12.5% / 6.16%;
  background:
    linear-gradient(100deg, rgba(255, 255, 255, 0.72) 0%, rgba(255, 255, 255, 0) 9%, rgba(255, 255, 255, 0) 88%, rgba(255, 255, 255, 0.34) 100%),
    linear-gradient(158deg, #a0a4a8 0%, #565a5e 6%, #1d1e20 19%, #43464a 42%, #242629 57%, #0d0e0f 73%, #6d7175 91%, #2a2c2f 100%);
  box-shadow:
    0 38px 58px -26px rgba(14, 14, 13, 0.55),
    0 12px 24px -12px rgba(14, 14, 13, 0.32),
    inset 0 0 0 1px rgba(255, 255, 255, 0.3),
    inset 0 0 0 2px rgba(0, 0, 0, 0.5);
}

.device__body::before {
  content: "";
  position: absolute;
  inset: 1.15%;
  border-radius: 11.4% / 5.62%;
  background: linear-gradient(160deg, #0b0c0d 0%, #000 55%, #0a0a0b 100%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.07);
  z-index: 0;
}

.device__screen {
  position: absolute;
  left: 5.9%;
  top: 11.4%;
  width: 88.2%;
  height: 77.2%;
  overflow: hidden;
  background: #fff;
  border-radius: 1.55% / 0.78%;
  box-shadow:
    inset 0 0 0 1px rgba(0, 0, 0, 0.75),
    inset 0 0 10px rgba(0, 0, 0, 0.18);
  z-index: 2;
}

.device__shot {
  display: block;
  width: 100%;
  height: auto;
  max-width: none;
  max-height: none;
  object-fit: unset;
  object-position: top center;
  background: #fff;
}

.device__glare {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  background: linear-gradient(
    116deg,
    rgba(255, 255, 255, 0.14) 0%,
    rgba(255, 255, 255, 0.045) 17%,
    rgba(255, 255, 255, 0) 34%,
    rgba(255, 255, 255, 0) 74%,
    rgba(255, 255, 255, 0.05) 100%
  );
  mix-blend-mode: screen;
}

.device__speaker {
  position: absolute;
  top: 4.9%;
  left: 50%;
  width: 13.5%;
  height: 1.15%;
  border-radius: 999px;
  background: linear-gradient(180deg, #26282a 0%, #08090a 60%, #000 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.18),
    0 1px 0 rgba(255, 255, 255, 0.06);
  transform: translateX(-50%);
  z-index: 3;
}

.device__camera {
  position: absolute;
  top: 3.75%;
  left: 28.5%;
  width: 3.1%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle at 38% 34%, #6d90b3 0%, #2a4157 32%, #0a0f14 72%);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.12),
    inset 0 0 0 1px rgba(0, 0, 0, 0.9);
  z-index: 3;
}

.device__camera::after {
  content: "";
  position: absolute;
  inset: 26%;
  border-radius: 50%;
  background: radial-gradient(circle at 36% 30%, #91b2cf, #182838 58%, #05080b);
}

.device__sensor {
  position: absolute;
  top: 4.35%;
  left: 61%;
  width: 1.15%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: #17181a;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
  z-index: 3;
}

.device__home {
  position: absolute;
  left: 50%;
  bottom: 2.4%;
  width: 14.8%;
  aspect-ratio: 1;
  border-radius: 50%;
  transform: translateX(-50%);
  background: radial-gradient(circle at 50% 35%, #1d1e20 0%, #0a0a0b 58%, #020203 100%);
  box-shadow:
    0 0 0 1px rgba(146, 151, 156, 0.13),
    0 1px 2px rgba(0, 0, 0, 0.55),
    inset 0 1px 1px rgba(255, 255, 255, 0.06);
  z-index: 3;
}

.device__home::before {
  content: "";
  position: absolute;
  inset: 6%;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 28%, rgba(255, 255, 255, 0.07) 0%, rgba(255, 255, 255, 0.015) 38%, transparent 62%);
}

.device__home::after {
  content: "";
  position: absolute;
  inset: 12%;
  border-radius: 50%;
  border: 1px solid rgba(180, 185, 190, 0.08);
}

.device__btn {
  position: absolute;
  width: 1.1%;
  border-radius: 2px;
  background: linear-gradient(90deg, #85898d 0%, #3b3e42 44%, #1a1b1d 100%);
  box-shadow: 0 0 0 0.5px rgba(0, 0, 0, 0.45);
  z-index: 0;
}

.device__btn--mute { left: -0.85%; top: 14.5%; height: 3.6%; }
.device__btn--vol-up { left: -0.9%; top: 21%; height: 6.4%; }
.device__btn--vol-down { left: -0.9%; top: 29.4%; height: 6.4%; }
.device__btn--power { right: -0.9%; top: 22.5%; height: 9.5%; }

/* ---------- 06. Browser window ---------- */
.browser {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: 9px;
  background: #fff;
  box-shadow: 0 34px 70px -34px rgba(20, 20, 18, 0.45), 0 2px 6px rgba(20, 20, 18, 0.08);
}

.browser__bar {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 34px;
  flex: none;
  padding: 0 13px;
  background: #f0ede6;
  border-bottom: 1px solid rgba(28, 28, 25, 0.1);
}

.browser__dots {
  display: flex;
  gap: 5px;
  flex: none;
}

.browser__dots i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #cbc6bb;
}

.browser__dots i:nth-child(1) { background: #d7a196; }
.browser__dots i:nth-child(2) { background: #ddc79c; }
.browser__dots i:nth-child(3) { background: #a9bfa6; }

.browser__url {
  flex: 1;
  display: flex;
  align-items: center;
  min-width: 0;
  height: 20px;
  padding: 0 10px;
  border-radius: 4px;
  background: #fff;
  color: #969187;
  font-size: 8.5px;
  letter-spacing: 0.04em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.browser__live {
  flex: none;
  font-size: 7.5px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: #8a857a;
}

.browser__viewport {
  position: relative;
  flex: 1;
  overflow: hidden;
  background: #eae7e0;
}

.browser__viewport img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top left;
}

/* ---------- 07. Ticker ---------- */
.ticker {
  overflow: hidden;
  background: var(--paper-deep);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line-soft);
}

.ticker__track {
  display: flex;
  width: max-content;
  animation: ticker 48s linear infinite;
}

.ticker:hover .ticker__track {
  animation-play-state: paused;
}

.ticker__item {
  display: inline-flex;
  align-items: center;
  gap: 20px;
  padding: 17px 24px;
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.16em;
  white-space: nowrap;
  color: var(--ink-2);
}

.ticker__item i {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--accent);
}

@keyframes ticker {
  to { transform: translateX(-50%); }
}

/* ---------- 08. Work section ---------- */
.work-intro {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: clamp(28px, 4.5vw, 64px);
  margin-block: clamp(38px, 5vw, 66px) clamp(34px, 4.4vw, 58px);
}

.work-intro h2 {
  font-size: clamp(42px, 5.0vw, 72px);
  font-weight: 600;
  line-height: 1.0;
  letter-spacing: -0.07em;
}

.work-intro__aside {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 26px;
  max-width: 560px;
  min-width: 0;
}

.work-intro__aside > p {
  font-size: 12.5px;
  line-height: 1.9;
  color: var(--muted);
  text-align: right;
}

.filters {
  display: flex;
  align-items: flex-end;
  gap: clamp(16px, 1.6vw, 22px);
  min-width: 0;
  max-width: 100%;
  padding-top: 12px;
  border-top: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
}

.filters button {
  position: relative;
  padding: 0 0 12px;
  color: var(--ink-2);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.01em;
  white-space: nowrap;
  transition: color 0.3s var(--ease);
}

.filters button sup {
  margin-left: 4px;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--muted);
  vertical-align: top;
}

.filters button::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  background: var(--ink);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--ease);
}

.filters button:hover {
  color: var(--ink);
}

.filters button.active {
  color: var(--ink);
}

.filters button.active::after {
  transform: scaleX(1);
}

.filters button.active sup {
  color: var(--accent);
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(40px, 4.6vw, 70px) clamp(18px, 2.2vw, 34px);
}

.work-card {
  display: block;
  min-width: 0;
  --stage-h: clamp(370px, 34vw, 480px);
  animation: cardIn 0.7s var(--ease) both;
  animation-delay: var(--delay, 0ms);
}

.work-card.is-half { grid-column: span 6; }
.work-card.is-wide { grid-column: span 7; }
.work-card.is-narrow { grid-column: span 5; }
.work-card.is-third { grid-column: span 4; --stage-h: clamp(330px, 30vw, 430px); }
.work-card.is-full { grid-column: span 12; }

.work-card.is-tall { --stage-h: clamp(440px, 43vw, 600px); }
.work-card.is-full { --stage-h: clamp(440px, 52vw, 660px); }

@keyframes cardIn {
  from { opacity: 0; transform: translateY(22px); }
  to { opacity: 1; transform: none; }
}

.work-card__stage {
  position: relative;
  height: var(--stage-h);
  overflow: hidden;
  background:
    radial-gradient(120% 90% at 18% 0%, rgba(255, 255, 255, 0.62), rgba(255, 255, 255, 0) 58%),
    var(--tone, #e6e2d8);
  isolation: isolate;
}

.work-card__stage::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  box-shadow: inset 0 0 0 1px rgba(28, 28, 25, 0.05);
}

.work-card__glyph {
  position: absolute;
  right: 1%;
  bottom: -7%;
  z-index: 0;
  font-family: var(--ff-serif);
  font-size: clamp(140px, 18vw, 260px);
  line-height: 0.78;
  letter-spacing: -0.08em;
  color: rgba(28, 28, 25, 0.065);
  pointer-events: none;
  user-select: none;
}

.work-card__index {
  position: absolute;
  top: 18px;
  left: 20px;
  z-index: 5;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: rgba(28, 28, 25, 0.45);
}

.work-card__view {
  position: absolute;
  right: 16px;
  bottom: 16px;
  z-index: 6;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 9px 13px;
  background: var(--ink);
  color: var(--paper);
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.13em;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.4s var(--ease), transform 0.4s var(--ease), background 0.3s var(--ease);
}

.work-card__view b {
  font-size: 12px;
  font-weight: 400;
}

.work-card:hover .work-card__view {
  opacity: 1;
  transform: none;
}

.work-card__meta {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto 34px;
  align-items: start;
  gap: 16px;
  padding-top: 15px;
  border-top: 1px solid transparent;
  transition: border-color 0.35s var(--ease);
}

.work-card:hover .work-card__meta {
  border-top-color: var(--line);
}

.work-card__num {
  display: block;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.13em;
  color: var(--accent);
}

.work-card__titles h3 {
  margin-top: 7px;
  word-break: keep-all;
  overflow-wrap: anywhere;
  font-size: clamp(20px, 2vw, 28px);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.045em;
}

.work-card__format {
  padding-top: 19px;
  font-size: 10px;
  color: var(--muted);
  text-align: right;
  white-space: nowrap;
}

.work-card__arrow {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  margin-top: 10px;
  border: 1px solid var(--line-soft);
  border-radius: 50%;
  font-size: 14px;
  transition: background 0.35s var(--ease), border-color 0.35s var(--ease), color 0.35s var(--ease);
}

.work-card:hover .work-card__arrow {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

/* ---------- 09. Covers ---------- */
.cover-phone {
  position: absolute;
  inset: 0;
  z-index: 1;
}

.device.cover-phone__front {
  --h: 86%;
  position: absolute;
  top: 7%;
  right: 12%;
  z-index: 2;
  transform: rotate(1.3deg);
  transition: transform 0.6s var(--ease);
}

.device.cover-phone__back {
  --h: 70%;
  position: absolute;
  top: 15%;
  left: 9%;
  z-index: 1;
  transform: rotate(-4deg);
  opacity: 0.97;
  transition: transform 0.6s var(--ease);
}

.work-card.is-wide .device.cover-phone__front { --h: 88%; right: 15%; }
.work-card.is-wide .device.cover-phone__back { --h: 72%; left: 10%; }
.work-card.is-narrow .device.cover-phone__front { --h: 83%; right: 10%; }
.work-card.is-narrow .device.cover-phone__back { --h: 66%; left: 8%; }

.work-card:hover .device.cover-phone__front {
  transform: rotate(1.3deg) translateY(-9px);
}

.work-card:hover .device.cover-phone__back {
  transform: rotate(-5.2deg) translateY(-4px);
}

.cover-chip {
  position: absolute;
  left: 18px;
  bottom: 16px;
  z-index: 4;
  padding: 7px 10px;
  border: 1px solid rgba(28, 28, 25, 0.14);
  background: rgba(243, 240, 233, 0.82);
  backdrop-filter: blur(6px);
  color: var(--ink-2);
  font-size: 7.5px;
  font-weight: 700;
  letter-spacing: 0.12em;
}

.cover-chip--light {
  left: auto;
  right: 18px;
}

.cover-browser {
  position: absolute;
  top: 13%;
  left: 8%;
  right: 8%;
  bottom: -7%;
  z-index: 1;
  transition: transform 0.6s var(--ease);
}

.work-card:hover .cover-browser {
  transform: translateY(-6px);
}

.cover-hybrid {
  position: absolute;
  inset: 0;
  z-index: 1;
}

.cover-hybrid__browser {
  position: absolute;
  top: 13%;
  left: 6%;
  right: 14%;
  bottom: 17%;
  z-index: 1;
  transition: transform 0.6s var(--ease);
}

.device.cover-hybrid__phone {
  --h: 60%;
  position: absolute;
  right: 7%;
  bottom: 5%;
  z-index: 3;
  transform: rotate(-2deg);
  transition: transform 0.6s var(--ease);
}

.work-card.is-wide .device.cover-hybrid__phone { --h: 64%; right: 8%; }
.work-card:hover .device.cover-hybrid__phone { transform: rotate(-2deg) translateY(-8px); }
.work-card:hover .cover-hybrid__browser { transform: translateY(-4px); }

.cover-system {
  position: absolute;
  inset: 0;
  z-index: 1;
}

.cover-system__browser {
  position: absolute;
  left: 6%;
  right: 18%;
  top: 11%;
  bottom: 18%;
  z-index: 1;
  transition: transform 0.6s var(--ease);
}

.cover-system__tablet {
  position: absolute;
  right: 6%;
  bottom: 6%;
  z-index: 3;
  width: 33%;
  height: auto;
  padding: 0;
  border: 4px solid #161616;
  border-radius: 12px;
  background: #161616;
  box-shadow: 0 26px 42px -22px rgba(20, 20, 18, 0.6), 0 4px 10px rgba(20, 20, 18, 0.18);
  transform: rotate(-2deg);
  transition: transform 0.6s var(--ease);
}

.work-card:hover .cover-system__tablet {
  transform: rotate(-2deg) translateY(-6px);
}

.work-card:hover .cover-system__browser {
  transform: translateY(-4px);
}

.cover-art {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: grid;
  place-items: center;
  padding: clamp(22px, 3.4vw, 48px);
  overflow: hidden;
  isolation: isolate;
}

.cover-art__ambient {
  position: absolute;
  inset: -12%;
  z-index: 0;
  width: 124%;
  height: 124%;
  object-fit: cover;
  filter: blur(46px) saturate(0.85);
  opacity: 0.32;
  transform: scale(1.05);
  pointer-events: none;
}

.cover-art img:not(.cover-art__ambient) {
  position: relative;
  z-index: 1;
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  background: #fff;
  outline: 1px solid rgba(28, 28, 25, 0.07);
  box-shadow: 0 30px 56px -32px rgba(20, 20, 18, 0.5);
  transition: transform 0.7s var(--ease);
}

.cover-art--bleed {
  display: block;
  padding: 0;
}

.cover-art--bleed .cover-art__ambient {
  display: none;
}

.cover-art--bleed img:not(.cover-art__ambient) {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  object-fit: cover;
  object-position: center;
  outline: 0;
  box-shadow: none;
}

.work-card:hover .cover-art img {
  transform: scale(1.012);
}

.work-card:hover .cover-art--bleed img:not(.cover-art__ambient) {
  transform: scale(1.03);
}

/* Tones ------------------------------------------------------------------ */
.tone-vermillion { --tone: #e8d8d1; --tone-deep: #dcc5bc; }
.tone-cyan { --tone: #dbe5e3; --tone-deep: #c8d8d4; }
.tone-coral { --tone: #ead9d1; --tone-deep: #dfc6bb; }
.tone-blue { --tone: #dbe1e8; --tone-deep: #c9d3dd; }
.tone-teal { --tone: #d6e2df; --tone-deep: #c3d4cf; }
.tone-lime { --tone: #e4e7d3; --tone-deep: #d4d9bf; }
.tone-gold { --tone: #eae1cd; --tone-deep: #ded1b5; }
.tone-periwinkle { --tone: #dfe0e9; --tone-deep: #cecfdd; }
.tone-slate { --tone: #dcdfde; --tone-deep: #ccd1d0; }
.tone-ochre { --tone: #e8dfd1; --tone-deep: #daccb7; }
.tone-red { --tone: #e6d9d6; --tone-deep: #d8c5c0; }
.tone-paper { --tone: #e9e5db; --tone-deep: #dcd6c8; }
.tone-violet { --tone: #dfdce9; --tone-deep: #cbc6df; }
.tone-brick { --tone: #e6d3cb; --tone-deep: #d5bdb2; }
.tone-blush { --tone: #eadad4; --tone-deep: #ddc6be; }
.tone-amber { --tone: #ead8c5; --tone-deep: #d9c0a6; }

/* ---------- 10. Archive ---------- */
.archive {
  margin-top: clamp(76px, 9vw, 130px);
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.archive__head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 30px;
  margin-block: 30px 12px;
}

.archive__head h3 {
  margin-top: 12px;
  font-size: clamp(30px, 3.4vw, 48px);
  font-weight: 600;
  letter-spacing: -0.055em;
}

.archive__head p {
  font-size: 11px;
  line-height: 1.8;
  color: var(--muted);
  text-align: right;
}

.archive__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0 clamp(20px, 2.2vw, 32px);
}

.archive-card {
  display: grid;
  grid-template-columns: 104px minmax(0, 1fr) 18px;
  align-items: center;
  gap: 14px;
  padding: 18px 0;
  border-top: 1px solid var(--line-soft);
  transition: padding 0.35s var(--ease);
}

.archive-card:hover {
  padding-left: 6px;
}

.archive-card__thumb {
  display: block;
  height: 72px;
  overflow: hidden;
  background: var(--paper-deep);
}

.archive-card__thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease);
}

.archive-card:hover .archive-card__thumb img {
  transform: scale(1.045);
}

.archive-card__body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.archive-card__body small {
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--muted);
}

.archive-card__body strong {
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.archive-card__arrow {
  font-size: 15px;
  color: var(--muted);
  transition: color 0.3s var(--ease), transform 0.3s var(--ease);
}

.archive-card:hover .archive-card__arrow {
  color: var(--accent);
  transform: translate(3px, -3px);
}

/* ---------- 11. About ---------- */
.about {
  background: var(--paper-deep);
  border-top: 1px solid var(--line-soft);
}

.about__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: clamp(36px, 6vw, 96px);
  margin-top: clamp(44px, 5.6vw, 80px);
}

.about__title {
  position: relative;
}

.about__title h2 {
  font-size: clamp(40px, 4.8vw, 72px);
  font-weight: 600;
  line-height: 1.14;
  letter-spacing: -0.06em;
}

.about__title h2 em {
  font-family: var(--ff-serif);
  font-style: normal;
  font-weight: 700;
  letter-spacing: -0.04em;
  color: var(--accent);
}

.about__note {
  display: block;
  margin-top: clamp(32px, 4vw, 56px);
  font-size: clamp(28px, 3.4vw, 46px);
  font-weight: 300;
  line-height: 0.98;
  letter-spacing: 0.02em;
  color: var(--muted-2);
}

.about__body {
  padding-top: 8px;
}

.about__lead {
  font-size: clamp(18px, 1.65vw, 23px);
  font-weight: 500;
  line-height: 1.75;
  letter-spacing: -0.02em;
}

.about__body > p + p {
  margin-top: 20px;
  font-size: 13.5px;
  line-height: 2.05;
  color: var(--ink-2);
}

.skills {
  margin-top: clamp(34px, 4vw, 52px);
  border-top: 1px solid var(--line);
}

.skill-row {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  align-items: baseline;
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px solid var(--line-soft);
}

.skill-row span {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--accent);
}

.skill-row strong {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.skill-row small {
  font-size: 10.5px;
  line-height: 1.7;
  color: var(--muted);
  text-align: right;
}

.process {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(20px, 2.6vw, 40px);
  margin-top: clamp(66px, 8vw, 110px);
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.process__step span {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--muted-2);
}

.process__step h3 {
  margin: 14px 0 12px;
  font-size: 25px;
  font-weight: 600;
  letter-spacing: -0.04em;
}

.process__step p {
  font-size: 11.5px;
  line-height: 1.9;
  color: var(--muted);
}

.clients {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 12px clamp(18px, 2.4vw, 34px);
  margin-top: clamp(56px, 7vw, 90px);
  padding-top: 18px;
  border-top: 1px solid var(--line-soft);
  font-size: 11.5px;
  color: var(--ink-2);
}

.clients__label {
  margin-right: auto;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--muted-2);
}

/* ---------- 12. Contact ---------- */
.contact {
  position: relative;
  overflow: hidden;
  background: var(--ink);
  color: var(--paper);
  padding-top: clamp(60px, 7vw, 96px);
}

.contact::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(243, 240, 233, 0.032) 1px, transparent 1px),
    linear-gradient(90deg, rgba(243, 240, 233, 0.032) 1px, transparent 1px);
  background-size: 84px 84px;
  pointer-events: none;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.9), transparent 80%);
  -webkit-mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.9), transparent 80%);
}

.contact .shell {
  position: relative;
  z-index: 1;
}

.contact__main {
  padding-block: clamp(52px, 7vw, 100px) clamp(40px, 5vw, 64px);
}

.contact__eyebrow {
  font-size: 11px;
  letter-spacing: 0.06em;
  color: rgba(243, 240, 233, 0.55);
}

.contact h2 {
  margin-top: clamp(26px, 3.6vw, 46px);
  font-size: clamp(48px, 5.6vw, 80px);
  font-weight: 600;
  line-height: 1.06;
  letter-spacing: -0.07em;
}

.contact h2 em {
  font-family: var(--ff-serif);
  font-style: normal;
  font-weight: 700;
  letter-spacing: -0.045em;
  color: var(--accent-soft);
}

.contact__email {
  display: inline-flex;
  align-items: center;
  gap: clamp(18px, 3vw, 40px);
  margin-top: clamp(34px, 4.4vw, 58px);
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(243, 240, 233, 0.35);
  font-size: clamp(19px, 2.5vw, 34px);
  letter-spacing: -0.03em;
  transition: color 0.35s var(--ease), border-color 0.35s var(--ease), gap 0.35s var(--ease);
}

.contact__email:hover {
  color: var(--accent-soft);
  border-color: var(--accent-soft);
  gap: clamp(24px, 3.6vw, 52px);
}

.contact__email-arrow {
  font-size: 0.8em;
}

.contact__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  padding-top: 24px;
  border-top: 1px solid rgba(243, 240, 233, 0.18);
}

.contact__grid div {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.contact__grid span {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: rgba(243, 240, 233, 0.4);
}

.contact__grid strong {
  font-size: 12px;
  font-weight: 500;
  color: rgba(243, 240, 233, 0.86);
}

.footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  margin-top: clamp(56px, 7vw, 96px);
  padding-block: 26px 30px;
  border-top: 1px solid rgba(243, 240, 233, 0.18);
  font-size: 8.5px;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: rgba(243, 240, 233, 0.45);
}

.footer nav {
  display: flex;
  gap: 20px;
}

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

.footer a:hover {
  color: var(--paper);
}

/* ---------- 13. Case hero ---------- */
.case {
  background: var(--paper);
}

.case-hero {
  padding-top: 20px;
}

.case-hero__top {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--muted);
}

.case-back {
  transition: color 0.3s var(--ease);
}

.case-back:hover {
  color: var(--accent);
}

.case-hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(0, 0.55fr);
  align-items: end;
  gap: clamp(30px, 5vw, 72px);
  margin-block: clamp(46px, 6vw, 82px) clamp(40px, 5vw, 64px);
}

.case-hero__en {
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--accent);
}

.case-hero h1 {
  margin-top: 14px;
  font-size: clamp(40px, 5.5vw, 80px);
  word-break: keep-all;
  overflow-wrap: anywhere;
  font-weight: 600;
  line-height: 1.06;
  letter-spacing: -0.075em;
}

.case-hero__lead {
  max-width: 400px;
  padding-bottom: 8px;
  font-size: clamp(13px, 1.15vw, 15.5px);
  line-height: 1.95;
  color: var(--ink-2);
}

/* ---------- 14. Case visual ---------- */
.case-visual {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(110% 90% at 20% 0%, rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0) 55%),
    var(--tone, #e5e2d9);
  isolation: isolate;
}

.case-visual__watermark {
  position: absolute;
  right: var(--gutter);
  top: 26px;
  z-index: 0;
  font-family: var(--ff-serif);
  font-size: clamp(120px, 16vw, 230px);
  line-height: 0.8;
  letter-spacing: -0.06em;
  color: rgba(28, 28, 25, 0.07);
  pointer-events: none;
}

.case-visual__inner {
  position: relative;
  height: 100%;
}

.case-visual__caption {
  position: absolute;
  left: var(--gutter);
  bottom: 18px;
  z-index: 4;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.13em;
  color: rgba(28, 28, 25, 0.5);
}

.case-visual--mobile {
  height: clamp(560px, 46vw, 700px);
}

.case-visual__inner--mobile {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  align-items: center;
  gap: clamp(20px, 4vw, 60px);
}

.case-visual__copy {
  position: relative;
  z-index: 4;
  max-width: 360px;
}

.case-visual__copy h2 {
  margin: 20px 0;
  font-family: var(--ff-serif);
  font-size: clamp(30px, 3.1vw, 46px);
  font-weight: 700;
  line-height: 1.18;
  letter-spacing: -0.035em;
  overflow-wrap: anywhere;
}

.case-visual__copy p {
  margin-bottom: 26px;
  font-size: 12px;
  line-height: 1.9;
  color: rgba(28, 28, 25, 0.62);
}

.case-phone-stage {
  position: relative;
  height: 100%;
}

.device.case-phone {
  position: absolute;
  filter: drop-shadow(0 36px 42px rgba(20, 20, 18, 0.27));
}

.device.case-phone--front {
  --h: 82%;
  right: 13%;
  bottom: 7%;
  z-index: 2;
  transform: rotate(1.4deg);
}

.device.case-phone--back {
  --h: 68%;
  left: 10%;
  bottom: 13%;
  z-index: 1;
  transform: rotate(-4.2deg);
}

.case-phone-stage__note {
  position: absolute;
  right: 2%;
  bottom: 20px;
  z-index: 3;
  font-size: 8px;
  letter-spacing: 0.12em;
  color: rgba(28, 28, 25, 0.42);
}

.case-visual--hybrid {
  height: clamp(540px, 46vw, 700px);
}

.case-visual__inner--hybrid {
  display: flex;
  align-items: center;
}

.case-hybrid__browser {
  position: absolute;
  left: var(--gutter);
  right: 22%;
  top: 13%;
  bottom: 13%;
  z-index: 2;
}

.device.case-hybrid__phone {
  --h: 66%;
  position: absolute;
  right: 7%;
  bottom: 9%;
  z-index: 3;
  transform: rotate(-2deg);
  filter: drop-shadow(0 30px 36px rgba(20, 20, 18, 0.28));
}

.case-visual--system {
  height: clamp(540px, 48vw, 720px);
}

.case-visual__inner--system {
  position: relative;
  height: 100%;
}

.case-system__browser {
  position: absolute;
  left: var(--gutter);
  right: 24%;
  top: 10%;
  bottom: 15%;
  z-index: 2;
}

.case-system__tablet {
  position: absolute;
  right: 6%;
  bottom: 7%;
  z-index: 3;
  width: 31%;
  border: 5px solid #151515;
  border-radius: 14px;
  background: #151515;
  overflow: hidden;
  box-shadow: 0 34px 55px -28px rgba(20, 20, 18, 0.55);
  transform: rotate(-2deg);
  transition: transform 0.5s var(--ease);
}

.case-system__tablet:hover {
  transform: rotate(-2deg) translateY(-5px);
}

.case-system__tablet img {
  display: block;
  width: 100%;
  height: auto;
}

.case-visual--desktop {
  height: clamp(480px, 52vw, 720px);
}

.case-visual__inner--desktop {
  display: grid;
  place-items: center;
  padding-block: clamp(30px, 4vw, 56px) clamp(44px, 5vw, 68px);
}

.case-browser-large {
  display: block;
  width: min(100%, 1080px);
  height: 100%;
}

.case-art-large {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  padding: 0 clamp(0px, 2vw, 30px);
  overflow: hidden;
  isolation: isolate;
}

.case-art-large__ambient {
  position: absolute;
  inset: -10%;
  z-index: 0;
  width: 120%;
  height: 120%;
  object-fit: cover;
  filter: blur(56px) saturate(0.9);
  opacity: 0.3;
  pointer-events: none;
}

.case-art-large a {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

.case-art-large img {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  background: #fff;
  outline: 1px solid rgba(28, 28, 25, 0.08);
  box-shadow: 0 40px 80px -40px rgba(20, 20, 18, 0.55);
}

/* ---------- 15. Case overview ---------- */
.case-overview {
  padding-block: clamp(66px, 8vw, 110px);
}

.case-overview__grid {
  display: grid;
  grid-template-columns: minmax(0, 0.7fr) minmax(0, 1.7fr) minmax(0, 0.9fr);
  gap: clamp(28px, 4vw, 60px);
  padding-top: 20px;
  border-top: 1px solid var(--line-soft);
}

.case-overview__label {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.case-overview__label span {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--muted);
}

.case-overview__label strong {
  font-size: clamp(20px, 2vw, 28px);
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.case-overview__body h2 {
  font-size: clamp(22px, 2.4vw, 32px);
  font-weight: 600;
  letter-spacing: -0.04em;
  line-height: 1.35;
}

.case-overview__body p {
  margin-top: 20px;
  max-width: 660px;
  font-size: 14px;
  line-height: 2;
  color: var(--ink-2);
}

.case-meta {
  align-self: start;
  border-top: 1px solid var(--line);
}

.case-meta div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line-soft);
}

.case-meta span {
  flex: none;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--muted-2);
}

.case-meta strong {
  font-size: 11px;
  font-weight: 500;
  line-height: 1.7;
  text-align: right;
}

/* ---------- 16. Case galleries ---------- */
.case-gallery {
  padding-bottom: clamp(70px, 8vw, 120px);
}

.gallery-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: clamp(28px, 5vw, 80px);
  margin-bottom: clamp(34px, 4.4vw, 56px);
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.gallery-head h2 {
  margin-top: 14px;
  font-size: clamp(34px, 4.4vw, 62px);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.06em;
}

.gallery-head p {
  max-width: 300px;
  padding-bottom: 4px;
  font-size: 11px;
  line-height: 1.9;
  color: var(--muted);
}

.screen-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(36px, 4vw, 56px) clamp(20px, 2.6vw, 38px);
}

.screen-card {
  min-width: 0;
}

.screen-card__stage {
  position: relative;
  display: grid;
  place-items: center;
  height: clamp(460px, 45vw, 590px);
  overflow: hidden;
  background:
    radial-gradient(100% 80% at 25% 0%, rgba(255, 255, 255, 0.6), rgba(255, 255, 255, 0) 60%),
    var(--tone, #e6e2d8);
}

.screen-card__stage::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  box-shadow: inset 0 0 0 1px rgba(28, 28, 25, 0.05);
}

.screen-card__stage .device {
  --h: 88%;
  position: relative;
  z-index: 1;
  transition: transform 0.55s var(--ease);
}

.screen-card__stage:hover .device {
  transform: translateY(-8px);
}

.screen-card__zoom {
  position: absolute;
  right: 14px;
  bottom: 14px;
  z-index: 3;
  padding: 8px 11px;
  background: rgba(243, 240, 233, 0.86);
  border: 1px solid rgba(28, 28, 25, 0.12);
  backdrop-filter: blur(6px);
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--ink-2);
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.35s var(--ease), transform 0.35s var(--ease);
}

.screen-card__stage:hover .screen-card__zoom {
  opacity: 1;
  transform: none;
}

.screen-card__flag {
  position: absolute;
  left: 14px;
  top: 14px;
  z-index: 3;
  padding: 7px 10px;
  background: rgba(28, 28, 25, 0.82);
  color: var(--paper);
  font-size: 7.5px;
  font-weight: 700;
  letter-spacing: 0.1em;
}

.screen-card figcaption {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-top: 13px;
  padding-top: 11px;
  border-top: 1px solid var(--line-soft);
  font-size: 10.5px;
  color: var(--muted);
}

.screen-card__num {
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--accent);
}

.screen-card figcaption strong {
  font-size: 12px;
  font-weight: 500;
  color: var(--ink);
}

.screen-card figcaption em {
  margin-left: auto;
  font-style: normal;
  font-size: 8.5px;
  letter-spacing: 0.04em;
  color: var(--muted-2);
}

.screen-grid--pair {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.screen-grid > .screen-card:last-child:nth-child(odd):not(:only-child) {
  grid-column: 1 / -1;
  width: calc(50% - clamp(20px, 2.6vw, 38px) / 2);
  margin-inline: auto;
}

.browser-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(34px, 4vw, 54px) clamp(20px, 2.6vw, 38px);
}

.browser-card.is-full {
  grid-column: 1 / -1;
}

.browser-card__frame {
  display: block;
  height: clamp(320px, 32vw, 440px);
  padding: clamp(16px, 2.2vw, 30px);
  background: var(--tone, #e6e2d8);
  transition: background 0.4s var(--ease);
}

.browser-card.is-full .browser-card__frame {
  height: clamp(420px, 48vw, 640px);
}

.browser-card figcaption {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--line-soft);
  font-size: 10.5px;
  color: var(--muted);
}

.browser-card figcaption span {
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--accent);
}

.gallery-subhead {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 24px;
  margin-block: clamp(60px, 7vw, 96px) clamp(28px, 3vw, 42px);
  padding-top: 16px;
  border-top: 1px solid var(--line-soft);
}

.gallery-subhead span {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--muted);
}

.gallery-subhead h3 {
  font-size: clamp(24px, 2.8vw, 38px);
  font-weight: 600;
  letter-spacing: -0.045em;
}

.art-card {
  min-width: 0;
}

.art-card__frame {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  height: clamp(300px, 34vw, 460px);
  padding: clamp(18px, 2.6vw, 36px);
  background:
    radial-gradient(100% 80% at 25% 0%, rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0) 60%),
    var(--tone, #e6e2d8);
  overflow: hidden;
  isolation: isolate;
}

.art-card__ambient {
  position: absolute;
  inset: -12%;
  z-index: 0;
  width: 124%;
  height: 124%;
  object-fit: cover;
  filter: blur(42px) saturate(0.85);
  opacity: 0.28;
  pointer-events: none;
}

.art-card__frame img:not(.art-card__ambient) {
  position: relative;
  z-index: 1;
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  background: #fff;
  outline: 1px solid rgba(28, 28, 25, 0.07);
  box-shadow: 0 24px 48px -30px rgba(20, 20, 18, 0.45);
  transition: transform 0.7s var(--ease);
}

.art-card__frame:hover img {
  transform: scale(1.015);
}

.art-card__zoom {
  position: absolute;
  right: 14px;
  bottom: 14px;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(243, 240, 233, 0.86);
  border: 1px solid rgba(28, 28, 25, 0.12);
  font-size: 12px;
  opacity: 0;
  transition: opacity 0.35s var(--ease);
}

.art-card__frame:hover .art-card__zoom {
  opacity: 1;
}

.art-card figcaption {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--line-soft);
  font-size: 10.5px;
  color: var(--muted);
}

.art-card figcaption span {
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--accent);
}

.art-card--hero {
  margin-bottom: clamp(36px, 4vw, 54px);
}

.art-card--hero .art-card__frame {
  height: clamp(420px, 56vw, 720px);
}

.art-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(30px, 3.6vw, 50px) clamp(20px, 2.6vw, 38px);
}

.art-grid--three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.art-grid--three .art-card__frame {
  height: clamp(240px, 22vw, 330px);
}

.art-grid--three .art-card:last-child {
  grid-column: auto;
}

.gallery-block {
  margin-top: clamp(48px, 6vw, 78px);
}

.gallery-block .gallery-subhead {
  justify-content: flex-start;
  align-items: baseline;
  gap: 24px;
  margin-block: 0 24px;
}

.art-grid .art-card:only-child,
.art-grid .art-card:nth-last-child(1):nth-child(odd) {
  grid-column: 1 / -1;
}

.art-grid.art-grid--three .art-card:last-child {
  grid-column: auto;
}

/* ---------- 17. Next project + case footer ---------- */
.case-next {
  position: relative;
  overflow: hidden;
  background: var(--tone, #e6e2d8);
}

.case-next::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(90% 120% at 15% 20%, rgba(255, 255, 255, 0.5), rgba(255, 255, 255, 0) 60%),
    linear-gradient(90deg, rgba(243, 240, 233, 0.4) 0%, rgba(243, 240, 233, 0.06) 100%);
  pointer-events: none;
}

.case-next__glyph {
  position: absolute;
  right: 4%;
  bottom: -18%;
  z-index: 1;
  font-family: var(--ff-serif);
  font-size: clamp(220px, 30vw, 420px);
  line-height: 1;
  color: rgba(28, 28, 25, 0.07);
  pointer-events: none;
}

.case-next__inner {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 30px;
  padding-block: clamp(60px, 8vw, 104px);
}

.case-next__inner h2 {
  margin-top: 18px;
  font-size: clamp(36px, 5.0vw, 72px);
  font-weight: 600;
  line-height: 1.04;
  letter-spacing: -0.07em;
}

.case-next__format {
  display: block;
  margin-top: 14px;
  font-size: 10px;
  color: var(--muted);
}

.case-next__arrow {
  flex: none;
  display: grid;
  place-items: center;
  width: clamp(48px, 5vw, 70px);
  height: clamp(48px, 5vw, 70px);
  border: 1px solid var(--ink);
  border-radius: 50%;
  font-size: 24px;
  transition: background 0.35s var(--ease), color 0.35s var(--ease), transform 0.35s var(--ease);
}

.case-next__inner:hover .case-next__arrow {
  background: var(--ink);
  color: var(--paper);
  transform: translate(4px, -4px);
}

.case-footer {
  background: var(--ink);
  color: var(--paper);
}

.case-footer__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding-block: 28px;
  font-size: 8.5px;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: rgba(243, 240, 233, 0.5);
}

.case-footer a {
  transition: color 0.3s var(--ease);
}

.case-footer a:hover {
  color: var(--paper);
}

.case-footer .wordmark {
  color: var(--paper);
  letter-spacing: 0.02em;
}

.empty-case {
  padding-block: 160px;
  text-align: center;
}

.empty-case h1 {
  margin: 24px 0 40px;
  font-size: clamp(38px, 5vw, 64px);
  letter-spacing: -0.06em;
}

/* ---------- 18. Lightbox ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  background: rgba(16, 16, 14, 0.96);
  padding: 22px;
  backdrop-filter: blur(8px);
}

.lightbox[hidden] {
  display: none !important;
}

.lightbox__scroll {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: auto;
  overscroll-behavior: contain;
  min-height: 0;
}

.lightbox__scroll img {
  display: block;
  max-width: min(92vw, 1240px);
  max-height: calc(100vh - 120px);
  width: auto;
  height: auto;
  object-fit: contain;
  box-shadow: 0 40px 100px -40px #000;
}

.lightbox__scroll img.is-tall {
  max-height: none;
  width: min(90vw, 720px);
  margin-block: 10px;
}

.lightbox:has(img.is-tall) .lightbox__scroll {
  align-items: flex-start;
}

.lightbox__cap {
  flex: none;
  padding-top: 14px;
  text-align: center;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: rgba(243, 240, 233, 0.6);
}

.lightbox__close {
  position: absolute;
  top: 18px;
  right: 20px;
  z-index: 3;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(243, 240, 233, 0.3);
  border-radius: 50%;
  color: var(--paper);
  font-size: 24px;
  line-height: 1;
  transition: background 0.3s var(--ease), color 0.3s var(--ease);
}

.lightbox__close:hover {
  background: var(--paper);
  color: var(--ink);
}

.lightbox__nav {
  position: absolute;
  top: 50%;
  z-index: 3;
  transform: translateY(-50%);
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 1px solid rgba(243, 240, 233, 0.28);
  border-radius: 50%;
  color: var(--paper);
  font-size: 18px;
  transition: background 0.3s var(--ease), color 0.3s var(--ease);
}

.lightbox__nav:hover {
  background: var(--paper);
  color: var(--ink);
}

.lightbox__nav--prev { left: 18px; }
.lightbox__nav--next { right: 18px; }

.lightbox__nav[hidden] {
  display: none;
}

/* ---------- 19. Reveal & motion ---------- */
[data-full] {
  cursor: zoom-in;
}

[data-reveal] {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

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

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .hero-glyph-field {
    opacity: 0.62;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  [data-reveal] {
    opacity: 1;
    transform: none;
  }
}

/* ---------- 20. Responsive ---------- */
@media (max-width: 1180px) {
  .archive__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .hero__grid {
    min-height: calc(100svh - 190px);
  }
  .hero h1 {
    font-size: clamp(50px, 6.6vw, 86px);
  }
  .work-card.is-tall { --stage-h: clamp(420px, 42vw, 540px); }
  .case-visual--mobile { height: clamp(540px, 48vw, 640px); }
  .case-visual__copy h2 { font-size: clamp(28px, 3vw, 40px); }
}

@media (max-width: 1024px) {
  .wordmark__cn { display: none; }
  .hero__grid {
    grid-template-columns: 1fr;
    gap: 44px;
    min-height: 0;
    padding-block: 24px 16px;
  }
  .hero-paper-field {
    -webkit-mask-image: none;
    mask-image: none;
    opacity: 0.78;
  }
  .hero__copy {
    max-width: 760px;
  }
  .hero h1 {
    font-size: clamp(56px, 9vw, 100px);
  }
  .hero-stage {
    height: clamp(480px, 66vw, 620px);
  }
  .device.hero-device--front { --h: 78%; right: auto; left: 57%; }
  .device.hero-device--back { --h: 63%; left: auto; right: 57%; }
  .project-grid {
    gap: 44px 24px;
  }
  .work-card.is-tall { --stage-h: clamp(400px, 44vw, 500px); }
  .about__grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .about__title h2 {
    font-size: clamp(42px, 6.4vw, 64px);
  }
  .about__note {
    display: none;
  }
  .case-hero__grid {
    grid-template-columns: 1fr;
    gap: 26px;
  }
  .case-hero__lead {
    max-width: 640px;
  }
  .case-overview__grid {
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 2fr);
  }
  .case-meta {
    grid-column: 2;
    margin-top: 10px;
  }
  .case-visual__inner--mobile {
    grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  }
  .case-hybrid__browser { right: 26%; }
  .device.case-hybrid__phone { right: 5%; --h: 62%; }
}

@media (max-width: 900px) {
  .site-nav { gap: 0; }
  .site-nav a { padding-inline: 8px; }
  .header-status { display: none; }
  .work-intro {
    grid-template-columns: 1fr;
    align-items: start;
    gap: 26px;
  }
  .work-intro__aside {
    align-items: flex-start;
    width: 100%;
    max-width: none;
    min-width: 0;
  }
  .work-intro__aside > p {
    text-align: left;
  }
  .filters {
    width: 100%;
    max-width: 100%;
    flex-wrap: wrap;
    gap: 8px 22px;
    overflow: visible;
  }
  .work-card.is-wide,
  .work-card.is-narrow,
  .work-card.is-third {
    grid-column: span 6;
  }
  .work-card.is-tall { --stage-h: clamp(400px, 52vw, 500px); }
  .work-card.is-full { --stage-h: clamp(400px, 58vw, 540px); }
  .device.cover-phone__front,
  .work-card.is-wide .device.cover-phone__front { --h: 84%; right: 10%; }
  .device.cover-phone__back,
  .work-card.is-wide .device.cover-phone__back { --h: 67%; left: 7%; }
  .cover-hybrid__browser { right: 18%; }
  .archive__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .archive-card { grid-template-columns: 120px minmax(0, 1fr) 18px; }
  .archive-card__thumb { height: 80px; }
  .screen-grid > .screen-card:last-child:nth-child(odd):not(:only-child) {
    width: calc(50% - 9px);
  }
  .process {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 32px;
  }
  .contact__grid { grid-template-columns: 1fr 1fr; }
  .footer {
    flex-wrap: wrap;
    gap: 14px 22px;
  }
  .footer span:nth-child(2) { display: none; }
  .case-visual--mobile {
    height: auto;
    min-height: 0;
  }
  .case-visual__inner--mobile {
    grid-template-columns: 1fr;
    gap: 10px;
    padding-block: 42px 32px;
  }
  .case-visual__copy {
    max-width: 520px;
  }
  .case-visual__copy h2 { margin: 14px 0; }
  .case-phone-stage {
    height: 470px;
  }
  .device.case-phone--front { --h: 80%; right: 14%; }
  .device.case-phone--back { --h: 66%; left: 12%; }
  .case-phone-stage__note { right: 0; }
  .case-visual--hybrid {
    height: auto;
    min-height: 0;
  }
  .case-visual__inner--hybrid {
    display: block;
    height: 520px;
    margin-block: 26px;
  }
  .case-hybrid__browser {
    left: var(--gutter);
    right: 20%;
    top: 6%;
    bottom: 10%;
  }
  .device.case-hybrid__phone { --h: 60%; right: 4%; bottom: 7%; }
  .case-visual--desktop { height: 480px; }
  .case-visual--system { height: auto; min-height: 0; }
  .case-visual__inner--system { height: 520px; margin-block: 26px; }
  .case-system__browser { left: 6%; right: 20%; top: 5%; bottom: 20%; }
  .case-system__tablet { width: 38%; right: 4%; bottom: 5%; }
  .case-overview__grid { grid-template-columns: 1fr; gap: 26px; }
  .case-meta { grid-column: 1; }
  .case-overview__label {
    flex-direction: row;
    justify-content: space-between;
    align-items: baseline;
  }
  .case-overview__label strong br { display: none; }
  .screen-grid { gap: 36px 18px; }
  .browser-gallery { grid-template-columns: 1fr; }
  .browser-card.is-full { grid-column: auto; }
  .browser-card__frame { height: 340px; }
  .browser-card.is-full .browser-card__frame { height: 420px; }
  .art-grid { grid-template-columns: 1fr; }
  .art-grid--three { grid-template-columns: 1fr; }
  .art-grid--three .art-card__frame { height: 320px; }
  .art-card__frame { height: 340px; }
  .art-card--hero .art-card__frame { height: 460px; }
}

@media (max-width: 720px) {
  .site-header__inner { height: 68px; gap: 14px; }
  .wordmark { font-size: 12px; }
  .site-nav a { font-size: 10px; letter-spacing: 0.08em; padding: 8px 6px; }
  .hero { padding-top: 8px; }
  .hero h1 {
    font-size: clamp(42px, 11.4vw, 72px);
    margin-top: 30px;
  }
  .hero__lede { font-size: 13.5px; line-height: 1.9; }
  .hero__actions {
    gap: 22px;
    margin-top: 26px;
  }
  .btn { min-height: 48px; gap: 26px; padding: 0 18px; }
  .hero__facts {
    flex-wrap: wrap;
    gap: 16px 28px;
    margin-top: 32px;
  }
  .hero__facts dd { font-size: 10.5px; }
  .hero-stage { height: 470px; }
  .device.hero-device--front { --h: 74%; left: auto; right: 7%; bottom: 6%; }
  .device.hero-device--back { --h: 58%; right: auto; left: 4%; bottom: 13%; }
  .hero-stage__num { font-size: 70px; top: 26px; }
  .hero-stage__side { display: none; }
  .hero-glyph-field { opacity: 0.82; }
  .hero-paper-field { opacity: 0.62; }
  .hero-stage__chip { right: 14px; }
  .ticker__item { padding: 14px 18px; font-size: 8.5px; }
  .section { padding-block: 68px; }
  .section-head {
    font-size: 8px;
    letter-spacing: 0.1em;
    padding-top: 12px;
  }
  .work-intro { margin-block: 32px 30px; }
  .work-intro h2 { font-size: clamp(38px, 11vw, 56px); }
  .filters { gap: 8px 16px; }
  .filters button { font-size: 12.5px; }
  .project-grid { grid-template-columns: 1fr; gap: 38px; }
  .work-card.is-half,
  .work-card.is-wide,
  .work-card.is-narrow,
  .work-card.is-third,
  .work-card.is-full {
    grid-column: 1 / -1;
  }
  .work-card,
  .work-card.is-tall,
  .work-card.is-full {
    --stage-h: clamp(340px, 96vw, 440px);
  }
  .work-card__meta {
    grid-template-columns: minmax(0, 1fr) 30px;
    gap: 10px;
  }
  .work-card__format {
    grid-column: 1;
    grid-row: 2;
    padding-top: 2px;
    text-align: left;
  }
  .work-card__arrow {
    grid-column: 2;
    grid-row: 1 / span 2;
    align-self: center;
    margin-top: 0;
  }
  .work-card__view { display: none; }
  .device.cover-phone__front,
  .work-card.is-wide .device.cover-phone__front,
  .work-card.is-narrow .device.cover-phone__front { --h: 82%; right: 8%; }
  .device.cover-phone__back,
  .work-card.is-wide .device.cover-phone__back,
  .work-card.is-narrow .device.cover-phone__back { --h: 65%; left: 5%; }
  .cover-chip { font-size: 7px; left: 12px; bottom: 12px; }
  .cover-art { padding: 18px; }
  .cover-browser { top: 12%; left: 5%; right: 5%; bottom: -6%; }
  .cover-hybrid__browser { top: 10%; left: 4%; right: 16%; bottom: 18%; }
  .device.cover-hybrid__phone { --h: 56%; right: 5%; bottom: 4%; }
  .archive__head { display: block; }
  .archive__head p { margin-top: 14px; text-align: left; }
  .archive__grid { grid-template-columns: 1fr; }
  .archive-card { grid-template-columns: 112px minmax(0, 1fr) 18px; gap: 14px; }
  .archive-card__thumb { height: 78px; }
  .case-phone-stage__note { display: none; }
  .archive-card__body strong { font-size: 14px; }
  .about__body > p + p { font-size: 13px; }
  .skill-row {
    grid-template-columns: 28px minmax(0, 1fr);
    gap: 4px 12px;
  }
  .skill-row small {
    grid-column: 2;
    text-align: left;
  }
  .process { gap: 26px; }
  .process__step h3 { font-size: 22px; }
  .clients { gap: 10px 18px; font-size: 11px; }
  .clients__label { width: 100%; }
  .contact h2 { font-size: clamp(38px, 10.8vw, 54px); }
  .contact__main { padding-block: 44px 36px; }
  .contact__email { font-size: clamp(17px, 4.6vw, 24px); }
  .contact__grid { grid-template-columns: 1fr; gap: 18px; }
  .footer nav { gap: 12px; flex-wrap: wrap; }
  .case-hero__top span:nth-child(3) { display: none; }
  .case-hero h1 { font-size: clamp(32px, 9.2vw, 56px); }
  .case-hero__lead { font-size: 13.5px; }
  .case-visual__watermark { display: none; }
  .case-visual__caption { display: none; }
  .case-phone-stage { height: 400px; }
  .device.case-phone--front { --h: 82%; right: 8%; }
  .device.case-phone--back { --h: 66%; left: 6%; }
  .case-visual__inner--hybrid { height: 400px; }
  .case-hybrid__browser { left: 6%; right: 20%; top: 5%; bottom: 12%; }
  .device.case-hybrid__phone { --h: 56%; right: 5%; }
  .case-visual--desktop { height: 380px; }
  .case-visual__inner--system { height: 400px; }
  .case-system__browser { left: 5%; right: 16%; top: 4%; bottom: 22%; }
  .case-system__tablet { width: 43%; right: 3%; bottom: 4%; }
  .cover-system__browser { left: 5%; right: 14%; top: 9%; bottom: 22%; }
  .cover-system__tablet { width: 40%; right: 4%; bottom: 5%; }
  .case-browser-large { height: 100%; }
  .gallery-head {
    display: block;
  }
  .gallery-head p { margin-top: 16px; padding: 0; max-width: 100%; }
  .screen-grid,
  .screen-grid--pair { grid-template-columns: 1fr; gap: 32px; }
  .screen-grid > .screen-card:last-child:nth-child(odd):not(:only-child) {
    width: 100%;
  }
  .screen-card__stage { height: clamp(440px, 120vw, 560px); }
  .screen-card__stage .device { --h: 86%; }
  .screen-card__zoom { opacity: 1; transform: none; }
  .browser-card__frame,
  .browser-card.is-full .browser-card__frame { height: 300px; padding: 14px; }
  .art-card__frame,
  .art-card--hero .art-card__frame { height: 320px; padding: 18px; }
  .art-card__zoom { opacity: 1; }
  .case-next__inner {
    display: block;
    padding-block: 54px;
  }
  .case-next__inner h2 { font-size: clamp(30px, 8.4vw, 50px); }
  .case-next__arrow {
    margin-top: 24px;
    width: 46px;
    height: 46px;
    font-size: 19px;
  }
  .case-footer__inner {
    flex-wrap: wrap;
    gap: 12px 20px;
    font-size: 8px;
  }
  .lightbox { padding: 14px; }
  .lightbox__nav { display: none; }
  .lightbox__scroll img { max-height: calc(100vh - 100px); }
}

@media (max-width: 420px) {
  :root { --gutter: 18px; }
  .hero h1 { font-size: clamp(38px, 11.8vw, 52px); }
  .hero-stage { height: 420px; }
  .device.hero-device--front { --h: 72%; }
  .device.hero-device--back { --h: 56%; }
  .work-card,
  .work-card.is-tall,
  .work-card.is-full { --stage-h: 330px; }
  .screen-card__stage { height: 430px; }
  .case-phone-stage { height: 360px; }
  .case-visual__inner--hybrid { height: 360px; }
  .contact h2 { font-size: 42px; }
}

/* ------------------------------------------------------------------
   21. V3.3 — 1112-style typographic banner
   Full-width canvas field + single centered serif headline.
------------------------------------------------------------------ */
.hero.hero-motion {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-height: clamp(470px, 58vh, 610px);
  padding-top: 0;
  padding-bottom: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero-motion .hero-glyph-field {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 1;
}

.hero.hero-motion h1 {
  position: relative;
  z-index: 1;
  width: 100%;
  margin: 0 auto;
  text-align: center;
  white-space: nowrap;
  font-family: var(--ff-serif);
  font-size: clamp(58px, 7.15vw, 112px);
  font-weight: 600;
  line-height: 1.16;
  letter-spacing: -0.075em;
  color: var(--ink);
  text-shadow: 0 2px 8px rgba(246, 244, 239, 0.72);
}

.hero.hero-motion h1 span,
.hero.hero-motion h1 em {
  font: inherit;
  letter-spacing: inherit;
}

.hero.hero-motion h1 em {
  display: inline;
  color: var(--accent);
  font-style: normal;
  font-size: 1em;
}

.hero.hero-motion .hero-lower {
  position: absolute;
  right: var(--gutter);
  bottom: clamp(28px, 4vw, 44px);
  z-index: 1;
  width: auto;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  margin: 0;
}

.hero.hero-motion .hero-description {
  width: auto;
}

.hero.hero-motion .hero-description p {
  margin: 0;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.hero.hero-motion .round-arrow {
  margin-left: 0;
  width: 52px;
  height: 52px;
  border: 1px solid var(--ink);
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 23px;
  transition: background 0.3s var(--ease), color 0.3s var(--ease), transform 0.3s var(--ease);
}

.hero.hero-motion .round-arrow:hover {
  background: var(--ink);
  color: var(--paper);
  transform: rotate(45deg);
}

@media (max-width: 900px) {
  .hero.hero-motion {
    min-height: 490px;
    padding-bottom: 0;
  }
  .hero.hero-motion h1 {
    font-size: clamp(54px, 8.3vw, 82px);
  }
  .hero.hero-motion .hero-lower {
    bottom: 32px;
  }
}

@media (max-width: 620px) {
  .hero.hero-motion {
    min-height: 410px;
    padding-bottom: 0;
  }
  .hero.hero-motion h1 {
    white-space: normal;
    text-align: left;
    font-size: clamp(38px, 10.7vw, 64px);
    line-height: 1.35;
    letter-spacing: -0.08em;
  }
  .hero.hero-motion h1 span {
    display: block;
  }
  .hero.hero-motion .hero-lower {
    bottom: 24px;
  }
  .hero.hero-motion .hero-description p {
    font-size: 13px;
  }
  .hero.hero-motion .round-arrow {
    width: 44px;
    height: 44px;
    font-size: 20px;
  }
  .hero-motion .hero-glyph-field {
    opacity: 0.86;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-motion .hero-glyph-field {
    opacity: 0.65;
  }
}

/* V3.3 — cleaner cards / archive / contact */
.work-card__titles h3 {
  margin-top: 0;
}

.archive__grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

@media (max-width: 900px) {
  .archive__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .archive__grid {
    grid-template-columns: 1fr;
  }
}

.contact__grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 720px) {
  .contact__grid {
    grid-template-columns: 1fr;
  }
}


/* One-column art section for wide spatial screens */
.art-grid--one {
  grid-template-columns: 1fr;
}

.art-grid--one .art-card__frame {
  height: auto;
  aspect-ratio: 21 / 9;
  padding: 0;
  background: transparent;
}

.art-grid--one .art-card__frame img:not(.ambient) {
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  object-fit: contain;
}

@media (max-width: 720px) {
  .art-grid--one .art-card__frame {
    aspect-ratio: 16 / 9;
  }
}

/* V3.5 — full-width work filter bar */
.work-intro {
  margin-bottom: clamp(24px, 3vw, 36px);
}

.work-filterbar {
  display: flex;
  align-items: center;
  gap: clamp(24px, 3vw, 48px);
  margin: 0 0 clamp(28px, 3.4vw, 42px);
  padding: 14px 0 16px;
  border-top: 1px solid var(--ink);
  border-bottom: 1px solid var(--line-soft);
}

.work-filterbar__label {
  flex: 0 0 auto;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--muted);
  white-space: nowrap;
}

.work-filterbar .filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  width: auto;
  max-width: 100%;
  padding: 0;
  border: 0;
}

.work-filterbar .filters button {
  padding: 8px 15px 7px;
  border: 1px solid transparent;
  border-radius: 999px;
  color: var(--ink-2);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0;
  transition: background 0.25s var(--ease), color 0.25s var(--ease), border-color 0.25s var(--ease);
}

.work-filterbar .filters button::after {
  display: none;
}

.work-filterbar .filters button:hover {
  background: rgba(28, 28, 25, 0.07);
  color: var(--ink);
}

.work-filterbar .filters button.active {
  background: var(--ink);
  color: var(--paper);
}

.work-filterbar .filters button sup {
  margin-left: 4px;
  font-size: 9px;
  font-weight: 600;
  color: var(--muted);
  opacity: 0.8;
  vertical-align: top;
}

.work-filterbar .filters button.active sup {
  color: var(--paper);
  opacity: 0.65;
}

@media (max-width: 720px) {
  .work-filterbar {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    padding: 13px 0 15px;
    margin-bottom: 28px;
  }
  .work-filterbar__label {
    font-size: 10px;
  }
  .work-filterbar .filters {
    gap: 6px;
  }
  .work-filterbar .filters button {
    padding: 7px 12px 6px;
    font-size: 12.5px;
  }
}

/* V3.7 — tighter contact after removing the duplicate info grid */
.contact__main {
  padding-bottom: clamp(24px, 3vw, 36px);
}

.contact .footer {
  margin-top: clamp(36px, 4.4vw, 56px);
}

@media (max-width: 720px) {
  .contact .footer {
    margin-top: 36px;
  }
}
