/* ---------- themes ---------- */

:root,
[data-theme="ivory"] {
  --bg: #f4efe7;
  --surface: #ebe4d8;
  --ink: #1c1915;
  --muted: #6e665b;
  --line: rgba(28, 25, 21, 0.14);
  --accent: #8b5a3c;
  --on-ink: #f4efe7;
  --shade: rgba(28, 25, 21, 0.38);
}

[data-theme="noir"] {
  --bg: #12100e;
  --surface: #1c1916;
  --ink: #efe7da;
  --muted: #9b9184;
  --line: rgba(239, 231, 218, 0.14);
  --accent: #c9a27a;
  --on-ink: #12100e;
  --shade: rgba(0, 0, 0, 0.45);
}

:root {
  --serif: "Cormorant Garamond", "Times New Roman", serif;
  --sans: "Manrope", system-ui, sans-serif;
  --gutter: clamp(16px, 4vw, 56px);
  --max: 1440px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------- base ---------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

body.no-scroll {
  overflow: hidden;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  color: inherit;
}

::selection {
  background: var(--accent);
  color: var(--on-ink);
}

:focus-visible {
  outline: 1px solid var(--accent);
  outline-offset: 4px;
}

h1,
h2,
h3 {
  font-family: var(--serif);
  font-weight: 400;
  line-height: 1;
  margin: 0;
  letter-spacing: -0.01em;
}

em {
  font-style: italic;
}

.eyebrow {
  margin: 0 0 18px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--muted);
}

/* images fade in once loaded */
img {
  opacity: 0;
  transition: opacity 0.9s var(--ease), transform 1.2s var(--ease);
}
img.is-loaded {
  opacity: 1;
}

/* scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 1s var(--ease), transform 1.1s var(--ease);
  transition-delay: var(--delay, 0ms);
}
.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* ---------- buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 15px 28px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.04em;
  transition: background 0.3s, color 0.3s, border-color 0.3s, transform 0.3s var(--ease);
}
.btn:hover {
  transform: translateY(-2px);
}
.btn-solid {
  background: var(--ink);
  color: var(--on-ink);
  border: 1px solid var(--ink);
}
.btn-solid:hover {
  background: var(--accent);
  border-color: var(--accent);
}
.btn-line {
  border: 1px solid var(--line);
}
.btn-line:hover {
  border-color: var(--ink);
}

/* ---------- header ---------- */

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px var(--gutter);
  transition: padding 0.4s var(--ease), background 0.4s, border-color 0.4s;
  border-bottom: 1px solid transparent;
}
.site-header.is-scrolled {
  padding-block: 14px;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-color: var(--line);
}
.logo {
  font-family: var(--serif);
  font-size: 28px;
  font-style: italic;
  line-height: 1;
}
.logo span {
  color: var(--accent);
}
.site-header nav {
  display: flex;
  gap: clamp(16px, 3vw, 36px);
  font-size: 13px;
  letter-spacing: 0.04em;
}
.site-header nav a {
  position: relative;
  padding-block: 4px;
}
.site-header nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.5s var(--ease);
}
.site-header nav a:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

/* ---------- hero ---------- */

.hero {
  position: relative;
  max-width: var(--max);
  margin: 0 auto;
  min-height: 100svh;
  padding: 120px var(--gutter) 80px;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: clamp(32px, 5vw, 80px);
  align-items: center;
}
.hero-name {
  font-size: clamp(64px, 11vw, 168px);
  line-height: 0.88;
  margin-bottom: 36px;
}
.hero-name span,
.hero-name em {
  display: block;
}
.hero-name em {
  padding-left: 0.5em;
  color: var(--accent);
  font-size: 0.62em;
  line-height: 1.1;
}
.hero-sub {
  max-width: 440px;
  margin: 0 0 40px;
  font-size: 17px;
  color: var(--muted);
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.hero-photo {
  position: relative;
  margin: 0;
  aspect-ratio: 4 / 5;
  border-radius: 999px 999px 4px 4px;
  overflow: hidden;
  background: var(--surface);
}
.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hero-photo figcaption {
  position: absolute;
  left: 18px;
  bottom: 18px;
  padding: 8px 14px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.scroll-hint {
  position: absolute;
  left: 50%;
  bottom: 24px;
  width: 1px;
  height: 56px;
  background: var(--line);
  overflow: hidden;
}
.scroll-hint span {
  position: absolute;
  inset: 0;
  background: var(--ink);
  animation: drip 2.2s var(--ease) infinite;
}
@keyframes drip {
  0% { transform: translateY(-100%); }
  60%, 100% { transform: translateY(100%); }
}

/* ---------- works ---------- */

.works {
  border-top: 1px solid var(--line);
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(80px, 12vw, 160px) var(--gutter);
}
.section-head {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 8px 32px;
  margin-bottom: clamp(48px, 7vw, 96px);
}
.section-head .eyebrow {
  grid-column: 1 / -1;
  margin: 0;
}
.section-head h2 {
  font-size: clamp(56px, 9vw, 128px);
}
.section-note {
  margin: 0;
  max-width: 260px;
  font-size: 14px;
  color: var(--muted);
  text-align: right;
}
.works-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  column-gap: clamp(24px, 4vw, 64px);
  row-gap: clamp(56px, 8vw, 120px);
}
.work-card:nth-child(even) {
  margin-top: clamp(0px, 14vw, 200px);
}
.work-media {
  position: relative;
  margin: 0 0 20px;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-radius: 4px;
  background: var(--surface);
}
.work-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.work-card:hover .work-media img {
  transform: scale(1.05);
}
.work-cta {
  position: absolute;
  left: 50%;
  top: 50%;
  translate: -50% -50%;
  padding: 14px 24px;
  border-radius: 999px;
  background: var(--bg);
  color: var(--ink);
  font-size: 13px;
  white-space: nowrap;
  opacity: 0;
  scale: 0.9;
  transition: opacity 0.4s, scale 0.5s var(--ease);
}
.work-card:hover .work-cta {
  opacity: 1;
  scale: 1;
}
.work-info {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: baseline;
  gap: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}
.work-info.is-untitled {
  grid-template-columns: 1fr auto;
}
.work-num {
  font-size: 12px;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}
.work-info h3 {
  font-size: clamp(26px, 2.6vw, 38px);
  line-height: 1.1;
}
.work-count {
  font-size: 12px;
  color: var(--muted);
  white-space: nowrap;
}
.work-desc {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 14px;
}

/* ---------- about ---------- */

.about {
  background: var(--surface);
  padding: clamp(96px, 14vw, 180px) var(--gutter);
}
.about-inner {
  max-width: 980px;
  margin: 0 auto;
  text-align: center;
}
.about-quote {
  margin: 0 0 72px;
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(28px, 3.6vw, 50px);
  line-height: 1.18;
}
.about-quote::before {
  content: "“";
  display: block;
  font-size: 1.6em;
  line-height: 0.6;
  color: var(--accent);
}
.about-bio {
  max-width: 600px;
  margin: 0 auto 64px;
  color: var(--muted);
  font-size: 17px;
}
.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin: 0;
  border-top: 1px solid var(--line);
}
.stats.stats-two {
  grid-template-columns: repeat(2, 1fr);
}
.stats div {
  padding: 28px 12px 0;
}
.stats div + div {
  border-left: 1px solid var(--line);
}
.stats dt {
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
}
.stats dd {
  margin: 6px 0 0;
  font-family: var(--serif);
  font-size: clamp(40px, 5vw, 64px);
  line-height: 1;
}
.stats dd.stats-text {
  font-size: clamp(18px, 2vw, 24px);
  line-height: 1.3;
  padding-top: 0.5em;
}

/* ---------- contacts ---------- */

.contacts {
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(96px, 14vw, 180px) var(--gutter);
}
.contacts h2 {
  font-size: clamp(48px, 8vw, 116px);
  max-width: 12ch;
  margin-bottom: 56px;
}
.contacts h2 em {
  color: var(--accent);
}
.contact-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line);
}
.contact-list a {
  display: grid;
  grid-template-columns: 140px 1fr auto;
  align-items: center;
  gap: 16px;
  padding: 24px 0;
  border-bottom: 1px solid var(--line);
  font-family: var(--serif);
  font-size: clamp(24px, 3vw, 36px);
  transition: padding 0.5s var(--ease), color 0.3s;
}
.contact-list a span {
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
}
.contact-list a:hover {
  padding-left: 16px;
  color: var(--accent);
}

/* ---------- footer ---------- */

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 28px var(--gutter);
  border-top: 1px solid var(--line);
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.04em;
}
.to-top:hover {
  color: var(--ink);
}

/* ---------- work page ---------- */

.work-hero {
  max-width: var(--max);
  margin: 0 auto;
  padding: 140px var(--gutter) clamp(64px, 9vw, 120px);
  display: grid;
  grid-template-columns: 1fr minmax(260px, 0.7fr);
  gap: clamp(32px, 6vw, 96px);
  align-items: end;
}
.back {
  display: inline-flex;
  gap: 10px;
  margin-bottom: clamp(40px, 8vw, 96px);
  font-size: 13px;
  color: var(--muted);
  transition: color 0.3s, gap 0.4s var(--ease);
}
.back:hover {
  color: var(--ink);
  gap: 16px;
}
.work-hero h1 {
  font-size: clamp(56px, 9vw, 140px);
  line-height: 0.92;
  margin-bottom: 28px;
}
.work-hero-desc {
  max-width: 520px;
  margin: 0 0 16px;
  font-size: 17px;
  color: var(--muted);
}
.work-hero-meta {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}
.work-hero-cover {
  margin: 0;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border-radius: 4px;
  background: var(--surface);
}
.work-hero-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter) clamp(80px, 10vw, 140px);
  columns: 3 320px;
  column-gap: clamp(12px, 1.6vw, 24px);
}
.shot {
  display: block;
  width: 100%;
  margin: 0 0 clamp(12px, 1.6vw, 24px);
  padding: 0;
  border: 0;
  border-radius: 3px;
  overflow: hidden;
  background: var(--surface);
  cursor: zoom-in;
  break-inside: avoid;
}
.shot img {
  width: 100%;
  height: auto;
}
.shot:hover img {
  transform: scale(1.03);
}

.next-work {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 32px;
  padding: clamp(56px, 8vw, 100px) var(--gutter);
  border-top: 1px solid var(--line);
  max-width: var(--max);
  margin: 0 auto;
}
.next-work h2 {
  font-size: clamp(40px, 7vw, 104px);
  transition: color 0.3s;
}
.next-work h2 span {
  display: inline-block;
  color: var(--accent);
  transition: transform 0.5s var(--ease);
}
.next-work:hover h2 span {
  transform: translateX(16px);
}
.next-work figure {
  margin: 0;
  width: clamp(110px, 16vw, 220px);
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-radius: 999px 999px 4px 4px;
  background: var(--surface);
}
.next-work img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.next-work:hover img {
  transform: scale(1.06);
}

.empty {
  min-height: 80svh;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 16px;
  padding: 120px var(--gutter);
  text-align: center;
}
.empty h1 {
  font-size: clamp(44px, 7vw, 88px);
  margin-bottom: 16px;
}

/* ---------- lightbox ---------- */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  grid-template-columns: 80px 1fr 80px;
  grid-template-rows: auto 1fr;
  background: rgba(12, 11, 10, 0.97);
  color: #efe7da;
  opacity: 0;
  transition: opacity 0.4s;
}
.lightbox.is-open {
  opacity: 1;
}
.lb-top {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 18px var(--gutter);
  font-size: 13px;
}
.lb-title {
  font-family: var(--serif);
  font-style: italic;
  font-size: 22px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.lb-counter {
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.12em;
  opacity: 0.7;
}
.lb-close {
  justify-self: end;
  background: none;
  border: 0;
  cursor: pointer;
  opacity: 0.8;
  font-size: 13px;
  letter-spacing: 0.06em;
}
.lb-close:hover {
  opacity: 1;
}
.lb-stage {
  margin: 0;
  display: grid;
  place-items: center;
  min-height: 0;
  padding: 0 0 24px;
}
.lb-stage img {
  max-width: 100%;
  max-height: calc(100svh - 96px);
  object-fit: contain;
  transition: opacity 0.35s;
}
.lb-nav {
  align-self: center;
  justify-self: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: 1px solid rgba(239, 231, 218, 0.25);
  background: none;
  cursor: pointer;
  font-size: 20px;
  transition: background 0.3s, border-color 0.3s;
}
.lb-nav:hover {
  background: rgba(239, 231, 218, 0.1);
  border-color: rgba(239, 231, 218, 0.6);
}

/* ---------- responsive ---------- */

@media (max-width: 900px) {
  .hero {
    grid-template-columns: 1fr;
    padding-top: 104px;
    min-height: auto;
  }
  .hero-photo {
    order: -1;
    max-width: 440px;
    width: 100%;
    justify-self: center;
  }
  .scroll-hint {
    display: none;
  }
  .work-hero {
    grid-template-columns: 1fr;
    padding-top: 104px;
  }
  .work-hero-cover {
    order: -1;
    aspect-ratio: 4 / 3;
  }
  .back {
    margin-bottom: 32px;
  }
}

@media (max-width: 640px) {
  .site-header nav a:nth-child(2) {
    display: none;
  }
  .works-grid {
    grid-template-columns: 1fr;
  }
  .work-card:nth-child(even) {
    margin-top: 0;
  }
  .work-cta {
    display: none;
  }
  .section-head {
    grid-template-columns: 1fr;
  }
  .section-note {
    text-align: left;
  }
  .stats {
    grid-template-columns: 1fr 1fr;
  }
  .stats:not(.stats-two) div:last-child {
    grid-column: 1 / -1;
    border-left: 0;
    border-top: 1px solid var(--line);
    margin-top: 28px;
  }
  .contact-list a {
    grid-template-columns: 1fr auto;
  }
  .contact-list a span {
    grid-column: 1 / -1;
  }
  .gallery {
    columns: 2;
  }
  .lightbox {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto 1fr auto;
  }
  .lb-stage {
    grid-column: 1 / -1;
    grid-row: 2;
    padding: 0;
  }
  .lb-stage img {
    max-height: calc(100svh - 170px);
  }
  .lb-prev,
  .lb-next {
    grid-row: 3;
    margin: 16px 0 24px;
  }
  .lb-title {
    display: none;
  }
  .lb-top {
    grid-template-columns: 1fr 1fr;
  }
  .site-footer {
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
  img {
    opacity: 1;
  }
}
