:root {
  --ink: #0a0a0a;
  --paper: #f2f1ed;
  --muted: #85847f;
  --line: rgba(10, 10, 10, 0.16);
  --white: #ffffff;
  --edge: clamp(20px, 4vw, 64px);
  --ease: cubic-bezier(0.76, 0, 0.24, 1);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  background: var(--paper);
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family:
    "Helvetica Neue",
    "Avenir Next",
    "PingFang SC",
    "Hiragino Sans GB",
    "Microsoft YaHei",
    sans-serif;
  -webkit-font-smoothing: antialiased;
}

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

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

.case-header {
  position: fixed;
  z-index: 20;
  top: 0;
  left: 0;
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  padding: 20px var(--edge);
  color: var(--white);
  mix-blend-mode: difference;
}

.case-brand,
.case-back {
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.case-brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.case-brand-mark {
  width: 9px;
  height: 9px;
  border: 1px solid currentColor;
  border-radius: 50%;
}

.case-hero {
  position: relative;
  display: flex;
  min-height: 100svh;
  align-items: flex-end;
  overflow: hidden;
  background: #171918;
  color: var(--white);
}

.case-hero-media,
.case-hero-shade {
  position: absolute;
  inset: 0;
}

.case-hero-media {
  background: #262827;
}

.case-hero-media img {
  filter: saturate(0.86) contrast(1.03);
  transform: scale(1.05);
}

.case-hero-shade {
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(5, 7, 7, 0.82), rgba(5, 7, 7, 0.16) 72%),
    linear-gradient(0deg, rgba(4, 5, 5, 0.7), transparent 58%);
}

.case-hero-content {
  position: relative;
  z-index: 2;
  width: 100%;
  padding: 130px var(--edge) 54px;
}

.case-eyebrow {
  margin: 0 0 20px;
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.case-hero h1 {
  max-width: 1180px;
  margin: 0;
  font-size: clamp(66px, 11vw, 178px);
  font-weight: 500;
  letter-spacing: -0.065em;
  line-height: 0.82;
}

.case-hero-subtitle {
  max-width: 560px;
  margin: 34px 0 0 auto;
  font-size: 14px;
  line-height: 1.7;
}

.case-hero--poster {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 42vw);
  align-items: center;
  gap: clamp(44px, 8vw, 140px);
  padding: 96px var(--edge) 44px;
  background: #e9e7e1;
  color: var(--ink);
}

.case-hero--poster .case-hero-media {
  position: relative;
  inset: auto;
  grid-column: 2;
  grid-row: 1;
  width: 100%;
  height: min(78svh, 760px);
  background: #dedbd4;
}

.case-hero--poster .case-hero-media img {
  object-fit: contain;
  filter: saturate(0.9) contrast(1.02);
  transform: none;
}

.case-hero--poster .case-hero-shade {
  display: none;
}

.case-hero--poster .case-hero-content {
  grid-column: 1;
  grid-row: 1;
  width: auto;
  padding: 0;
}

.case-hero--poster h1 {
  font-size: clamp(56px, 8vw, 132px);
}

.case-body {
  padding: 0 var(--edge);
}

.case-intro {
  display: grid;
  grid-template-columns: minmax(190px, 0.8fr) minmax(0, 1.8fr);
  gap: clamp(40px, 8vw, 150px);
  padding: clamp(90px, 12vw, 170px) 0;
  border-top: 1px solid var(--line);
}

.case-label {
  margin: 0;
  color: var(--muted);
  font-size: 9px;
  font-weight: 650;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.case-intro-copy {
  max-width: 920px;
  margin: 0;
  font-size: clamp(29px, 3.6vw, 58px);
  font-weight: 500;
  letter-spacing: -0.04em;
  line-height: 1.18;
}

.case-meta {
  grid-column: 2;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  margin-top: 72px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.case-meta-item span {
  display: block;
  margin-bottom: 13px;
  color: var(--muted);
  font-size: 9px;
  font-weight: 650;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.case-meta-item p {
  margin: 0;
  font-size: 12px;
  line-height: 1.65;
}

.case-gallery {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(12px, 1.8vw, 28px);
  padding-bottom: clamp(100px, 14vw, 190px);
}

.case-figure {
  position: relative;
  grid-column: span 12;
  min-height: 0;
  margin: 0;
  overflow: hidden;
  background: #dedbd4;
}

.case-figure--wide {
  aspect-ratio: 16 / 10;
}

.case-figure--half {
  grid-column: span 6;
  aspect-ratio: 4 / 5;
}

.case-figure--third {
  grid-column: span 4;
  aspect-ratio: 4 / 5;
}

.case-figure--poster {
  grid-column: span 6;
  aspect-ratio: 4 / 5;
  padding: clamp(16px, 2vw, 34px);
}

.case-figure--poster img {
  object-fit: contain;
}

.case-figure figcaption {
  position: absolute;
  z-index: 2;
  right: 14px;
  bottom: 13px;
  padding: 6px 8px;
  color: var(--white);
  background: rgba(0, 0, 0, 0.46);
  backdrop-filter: blur(8px);
  font-size: 8px;
  font-weight: 600;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.case-next {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1px solid var(--line);
}

.case-next a {
  display: flex;
  min-height: 260px;
  align-items: flex-end;
  justify-content: space-between;
  padding: 34px var(--edge);
  font-size: clamp(28px, 3vw, 48px);
  letter-spacing: -0.04em;
}

.case-next a + a {
  border-left: 1px solid var(--line);
  text-align: right;
}

.case-next small {
  color: var(--muted);
  font-size: 9px;
  font-weight: 650;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.case-footer {
  display: flex;
  justify-content: space-between;
  padding: 20px var(--edge);
  border-top: 1px solid var(--line);
  font-size: 9px;
  font-weight: 650;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.case-reveal {
  opacity: 0;
  transform: translateY(32px);
  transition:
    opacity 0.9s ease,
    transform 1s var(--ease);
}

.case-reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 760px) {
  .case-header {
    padding-top: 18px;
  }

  .case-hero-content {
    padding-bottom: 36px;
  }

  .case-hero h1 {
    font-size: clamp(58px, 18vw, 96px);
  }

  .case-hero-subtitle {
    margin: 24px 0 0;
  }

  .case-hero--poster {
    grid-template-columns: 1fr;
    gap: 30px;
    padding-top: 108px;
  }

  .case-hero--poster .case-hero-content {
    grid-column: 1;
    grid-row: 1;
  }

  .case-hero--poster .case-hero-media {
    grid-column: 1;
    grid-row: 2;
    height: min(54svh, 500px);
  }

  .case-intro {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .case-intro-copy,
  .case-meta {
    grid-column: 1;
  }

  .case-meta {
    grid-template-columns: 1fr;
    gap: 20px;
    margin-top: 34px;
  }

  .case-figure--half,
  .case-figure--third,
  .case-figure--poster {
    grid-column: span 12;
  }

  .case-figure--half {
    aspect-ratio: 4 / 5;
  }

  .case-next {
    grid-template-columns: 1fr;
  }

  .case-next a {
    min-height: 180px;
  }

  .case-next a + a {
    border-top: 1px solid var(--line);
    border-left: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .case-reveal {
    opacity: 1;
    transform: none;
  }
}
