:root {
  /* Black-and-white palette */
  --ink: #0e0e0e;
  --paper: #ffffff;
  --graphite: #333333;
  --slate: #444444;
  --pewter: #555555;
  --ash: #666666;
  --fog: #888888;
  --silver: #bbbbbb;
  --mist: #dddddd;
  --haze: #e4e4e4;
  --cloud: #eeeeee;
  --bone: #f2f2f2;

  --serif: "Instrument Serif", Georgia, serif;
  --sans: "Hanken Grotesk", system-ui, sans-serif;
  --mono: "Geist Mono", ui-monospace, monospace;

  /* Surfaces */
  --nav-bg: rgba(255, 255, 255, 0.82);
  --lightbox-bg: rgba(255, 255, 255, 0.97);
  --card-bg: var(--ink);
  --card-fg: var(--paper);
  --card-muted: var(--silver);
  --card-rule: var(--graphite);
  color-scheme: light;

  /* Button corners: 0 for sharp rectangles, 999px for pills. */
  --cta-radius: 0;

  --gutter: clamp(20px, 5vw, 72px);
  --section: clamp(80px, 14vh, 160px);
  --max: 1440px;
  /* Left edge of the content column, also for full-bleed rows like the carousel */
  --edge: max(var(--gutter), calc((100% - var(--max)) / 2 + var(--gutter)));
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

/* Dark mode: ink and paper swap places; greys keep the same steps of contrast. */
:root[data-theme="dark"] {
  --ink: #f2f2f2;
  --paper: #0e0e0e;
  --graphite: #cfcfcf;
  --slate: #bdbdbd;
  --pewter: #ababab;
  --ash: #9a9a9a;
  --fog: #7a7a7a;
  --silver: #8a8a8a;
  --mist: #2c2c2c;
  --haze: #2a2a2a;
  --cloud: #222222;
  --bone: #181818;
  --nav-bg: rgba(14, 14, 14, 0.82);
  --lightbox-bg: rgba(14, 14, 14, 0.97);
  --card-bg: #181818;
  --card-fg: #f2f2f2;
  --card-muted: #9a9a9a;
  --card-rule: #333333;
  color-scheme: dark;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  transition: background-color 0.35s, color 0.35s;
  background: var(--paper);
  color: var(--ink);
  font: 400 17px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; height: auto; }

/* Blurred placeholder behind each photo; the photo fades in once loaded. */
.lqip { display: block; background-size: cover; background-position: center; }
picture.lqip > img { opacity: 0; transition: opacity 0.6s var(--ease), transform 0.9s var(--ease); }
picture.lqip > img.is-loaded { opacity: 1; }
@media (prefers-reduced-motion: reduce) { picture.lqip > img { transition: none; } }
a { color: inherit; text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
p, h1, h2, h3, figure, dl, dd, ol { margin: 0; }
em { font-style: italic; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
section[id] { scroll-margin-top: 64px; }

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

.skip {
  position: absolute; left: var(--gutter); top: -4rem; z-index: 100;
  background: var(--ink); color: var(--paper); padding: 0.6rem 1rem;
}
.skip:focus { top: 1rem; }

/* Type roles */
.label, .count, .hint, .btn, .nav, .slide__place, .facts dt, .steps__n, .footer__copy {
  font-family: var(--mono);
  text-transform: uppercase;
}
.label { font-size: 12px; font-weight: 500; letter-spacing: 0.12em; line-height: 1; color: var(--ash); }
.label--dark { color: var(--card-muted); }
.count { font-size: 12px; letter-spacing: 0.08em; color: var(--ash); font-variant-numeric: tabular-nums; }
.hint { font-size: 11px; letter-spacing: 0.1em; color: var(--fog); }

.heading {
  font: 400 clamp(44px, 6vw, 96px)/0.95 var(--serif);
  letter-spacing: -0.02em;
  margin-top: 18px;
}

/* Buttons: pills, mono caps */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 46px; padding: 0 26px;
  background: var(--ink); color: var(--paper);
  border: 1px solid var(--ink); border-radius: var(--cta-radius);
  font-size: 12px; font-weight: 500; letter-spacing: 0.1em; line-height: 1;
  text-decoration: none; white-space: nowrap; cursor: pointer;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
}
.btn:hover { background: var(--graphite); border-color: var(--graphite); }
.btn--outline { background: transparent; color: var(--ink); }
.btn--outline:hover { background: var(--ink); color: var(--paper); border-color: var(--ink); }

.arrow {
  width: 46px; height: 46px; display: grid; place-items: center; flex: none;
  border: 1px solid var(--ink); border-radius: 50%;
  background: var(--paper); color: var(--ink); cursor: pointer; padding: 0;
  transition: background 0.2s, color 0.2s;
}
.arrow svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.4; }
.arrow:hover { background: var(--ink); color: var(--paper); }
.arrow:disabled { opacity: 0.25; pointer-events: none; }

/* Header: blends with the ink over the hero, frosted paper below it */
.nav {
  position: fixed; inset: 0 0 auto; z-index: 20;
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  height: 64px; padding: 0 var(--gutter);
  font-size: 12px; letter-spacing: 0.1em;
  color: #fff; mix-blend-mode: difference;
}
.nav.is-solid {
  color: var(--ink); mix-blend-mode: normal;
  background: var(--nav-bg);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--cloud);
}
.theme-toggle {
  display: grid; place-items: center; width: 36px; height: 36px; padding: 0;
  border: 0; border-radius: 50%; background: none; color: inherit; cursor: pointer;
}
.theme-toggle svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.4; transition: rotate 0.5s var(--ease); }
.theme-toggle path { fill: currentColor; stroke: none; }
.theme-toggle[aria-pressed="true"] svg { rotate: 180deg; }
@media (prefers-reduced-motion: reduce) { .theme-toggle svg { transition: none; } }
.nav__name { font: 400 22px/1 var(--serif); text-transform: none; letter-spacing: 0; text-decoration: none; }
.nav nav { display: flex; align-items: center; gap: clamp(16px, 3vw, 36px); }
.nav nav a { text-decoration: none; }
.nav nav a:not(.ink-pill):hover { text-decoration: underline; }

/* Ink pill: ink floods in from where the cursor enters and drains out where
   it leaves; the label flips to its negative as the ink passes. Set
   --negative to the colour the label should turn. */
.nav { --negative: #000; }
.nav.is-solid { --negative: var(--paper); }
.ink-pill {
  --x: 50%; --y: 50%;
  position: relative; display: inline-grid; place-items: center;
  border: 1px solid currentColor; border-radius: var(--cta-radius); padding: 10px 16px;
  font: 500 12px/1 var(--mono); letter-spacing: 0.1em; text-transform: uppercase;
  text-decoration: none; white-space: nowrap;
  overflow: hidden; isolation: isolate;
}
.ink-pill > * { grid-area: 1 / 1; }
/* Both layers cover the whole pill (padding included) so their circles line up. */
.ink-pill__ink, .ink-pill__flip { position: relative; align-self: stretch; justify-self: stretch; margin: -16px -22px; }
/* The wash is cropped to a growing circle on the inner span and roughened by
   the filter on the outer one: a filter applies before clip-path on the same
   element, so they have to be split for the ragged edge to show. */
.ink-pill__ink { filter: url(#watercolour); }
.ink-pill__ink > span, .ink-pill__flip {
  clip-path: circle(0% at var(--x) var(--y));
  /* Fast start then a long slow spread, like pigment soaking into wet paper. */
  transition: clip-path 0.8s cubic-bezier(0.16, 0.84, 0.3, 1);
}
.ink-pill__ink > span { position: absolute; inset: 0; background: currentColor; }
.ink-pill__label, .ink-pill__flip { display: flex; align-items: center; justify-content: center; }
.ink-pill__flip { color: var(--negative, var(--paper)); }
.ink-pill:hover .ink-pill__ink > span, .ink-pill:focus-visible .ink-pill__ink > span { clip-path: circle(160% at var(--x) var(--y)); }
.ink-pill:hover .ink-pill__flip, .ink-pill:focus-visible .ink-pill__flip { clip-path: circle(150% at var(--x) var(--y)); }
/* Leaving drains a little quicker than the bloom. */
.ink-pill:not(:hover):not(:focus-visible) .ink-pill__ink > span,
.ink-pill:not(:hover):not(:focus-visible) .ink-pill__flip { transition-duration: 0.5s; }
@media (prefers-reduced-motion: reduce) { .ink-pill__ink > span, .ink-pill__flip { transition: none; } }

/* Instagram: same size as the other page buttons, with its icon. */
.ink-pill--insta { font-size: 12px; padding: 16px 26px; }
.ink-pill--insta .ink-pill__ink, .ink-pill--insta .ink-pill__flip { margin: -22px -32px; }

/* Booking card: a large light pill on the dark card. */
.ink-pill--card { --negative: var(--card-bg); color: var(--card-fg); font-size: 13px; padding: 20px 34px; }
.ink-pill--card .ink-pill__ink, .ink-pill--card .ink-pill__flip { margin: -26px -40px; }

@media (max-width: 560px) {
  .nav__name, .nav__ig { display: none; }
  .nav { justify-content: flex-end; }
}

/* Hero */
.hero {
  position: relative;
  height: 100svh; min-height: 560px;
  overflow: hidden; isolation: isolate;
  background: var(--paper);
}
.hero__ink { position: absolute; inset: 0; width: 100%; height: 100%; display: block; touch-action: pan-y; }
.hero:not(.has-ink) {
  background:
    radial-gradient(55% 65% at 78% 42%, rgba(14,14,14,0.2), transparent 70%),
    radial-gradient(30% 40% at 64% 72%, rgba(14,14,14,0.1), transparent 70%),
    var(--paper);
}

/* Hero text: tagline + name anchored bottom left, details and actions below.
   White + difference blend reads as ink on paper and paper over the ink. */
.hero__text {
  position: absolute;
  inset: auto var(--gutter) clamp(24px, 4.5vh, 48px);
  display: flex; flex-direction: column; gap: clamp(24px, 5vh, 56px);
  pointer-events: none;
}
.hero__text a { pointer-events: auto; }

.hero__tagline, .hero__foot {
  color: #fff; mix-blend-mode: difference;
  /* Keep these on their own GPU layer. Safari (iOS especially) only blends
     with the WebGL canvas between composited layers; without this the text
     turns plain white once its fade-in animation ends. */
  transform: translateZ(0); will-change: transform;
  font: 400 13px/1.35 var(--mono); letter-spacing: 0.12em; text-transform: uppercase;
}
.hero__tagline { font-weight: 500; margin-bottom: clamp(12px, 2.5vh, 28px); }

.hero__name {
  font: 400 clamp(68px, 14vw, 240px)/0.86 var(--serif);
  letter-spacing: -0.035em;
  color: #fff; mix-blend-mode: difference; /* fallback without WebGL */
  transform: translateZ(0);
}
.hero__name span { display: block; }
.hero__name span:last-child { padding-left: 0.38em; }
/* With WebGL the shader draws the name, so it can invert through the ink. */
.has-ink .hero__name { color: transparent; mix-blend-mode: normal; }

.hero__foot { --negative: #000; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px 32px; }
.hero__meta { display: flex; gap: 0.9em; }
.hero__actions { display: flex; align-items: center; gap: clamp(20px, 2.5vw, 36px); }
.hero__link { text-decoration: underline; text-underline-offset: 0.45em; text-decoration-thickness: 1px; }
.hero__link:hover { text-decoration-thickness: 2px; }
.hero__foot .ink-pill { font-size: 13px; padding: 16px 30px; }
.hero__foot .ink-pill__ink, .hero__foot .ink-pill__flip { margin: -22px -36px; }

@media (max-width: 700px) {
  .hero__name span:last-child { padding-left: 0.25em; }
  .hero__foot { justify-content: flex-start; }
}

@media (prefers-reduced-motion: no-preference) {
  .hero__tagline, .hero__foot {
    opacity: 0; animation: appear 1.2s var(--ease) 1.6s forwards;
  }
  .hero:not(.has-ink) .hero__name span { opacity: 0; animation: appear 1.4s var(--ease) 0.2s forwards; }
}
@keyframes appear { to { opacity: 1; } }

/* About */
.about {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 40px var(--gutter);
  padding-block: var(--section);
  align-items: start;
}
.about__label { grid-column: 1 / -1; }
.about__portrait { grid-column: 1 / span 5; }
.about__portrait img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; background: var(--bone); }
.about__text { grid-column: 7 / span 6; display: grid; gap: 36px; }
.about__intro {
  font: 400 clamp(32px, 3.6vw, 54px)/1.08 var(--serif);
  letter-spacing: -0.01em;
  text-wrap: balance;
}
.prose { display: grid; gap: 1em; color: var(--graphite); max-width: 36em; }

.facts { display: grid; border-top: 1px solid var(--mist); max-width: 36em; }
.facts div { display: grid; grid-template-columns: 110px 1fr; gap: 16px; padding: 18px 0; border-bottom: 1px solid var(--mist); }
.facts dt { font-size: 12px; letter-spacing: 0.12em; color: var(--ash); padding-top: 4px; }
.facts dd { color: var(--graphite); }
.facts a { text-decoration: none; }
.facts a:hover { color: var(--pewter); text-decoration: underline; }

@media (max-width: 860px) {
  .about__portrait { grid-column: 1 / -1; max-width: 420px; }
  .about__text { grid-column: 1 / -1; }
}

/* Work carousel */
.work { padding-block: var(--section); border-top: 1px solid var(--cloud); }
.work__head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 40px; }
.work__controls { display: flex; align-items: center; gap: 8px; }
.work__controls .count { margin-right: 14px; }

.track {
  list-style: none; margin: 0;
  display: flex; gap: clamp(12px, 1.6vw, 24px);
  overflow-x: auto; overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  padding: 0 var(--edge) 4px;
  scroll-padding-inline: var(--edge);
  scrollbar-width: none;
  cursor: grab;
}
.track::-webkit-scrollbar { display: none; }
.track.is-dragging { cursor: grabbing; scroll-snap-type: none; }
.track.is-dragging .slide__open { pointer-events: none; }

.slide { flex: 0 0 clamp(240px, 24vw, 380px); scroll-snap-align: start; }
.slide__open {
  display: block; width: 100%; padding: 0; border: 0; background: var(--bone);
  cursor: zoom-in; overflow: hidden;
}
.slide__open img {
  width: 100%; aspect-ratio: 2 / 3; object-fit: cover;
  transition: transform 0.9s var(--ease);
  user-select: none; -webkit-user-drag: none;
}
.slide__open:hover img { transform: scale(1.03); }
.slide__caption { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding-top: 14px; }
.slide__title { font: 400 22px/1.1 var(--serif); }
.slide__place { font-size: 11px; letter-spacing: 0.12em; color: var(--ash); white-space: nowrap; }
@media (max-width: 700px) { .slide { flex-basis: 72vw; } }

.work__foot { display: flex; align-items: center; gap: 24px; margin-top: 32px; }
.progress { position: relative; flex: 1; height: 1px; background: var(--haze); }
.progress span { position: absolute; top: -0.5px; bottom: -0.5px; left: 0; background: var(--ink); width: 10%; }

/* Ink flecks: a few small dots on the corner of a heading's last word.
   The box has no width, so the dots hang off the word without moving layout. */
.speck { display: inline-block; position: relative; width: 0; height: 1em; vertical-align: top; color: var(--ink); }
.speck svg { position: absolute; left: 0.05em; top: -0.12em; overflow: visible; }
.speck--3 svg { width: 42px; height: 33px; }
.speck circle { transform-box: fill-box; transform-origin: center; }

/* Dropped in on scroll: main.js arms the flecks, then marks each one as it
   comes into view. Without JS or with reduced motion they simply show. */
.specks-armed .speck circle { opacity: 0; }
.specks-armed .speck.is-dropped .speck__drop { animation: speck-fall 0.75s cubic-bezier(0.55, 0, 0.75, 0.4) both; }
.specks-armed .speck.is-dropped .speck__splat {
  animation: speck-splash 0.55s cubic-bezier(0.15, 0.8, 0.3, 1) both;
  animation-delay: calc(0.62s + var(--i) * 0.06s);
}
@keyframes speck-fall {
  0%   { opacity: 0; transform: translateY(-90px) scale(0.6, 1.9); }
  15%  { opacity: 1; }
  78%  { transform: translateY(0) scale(0.8, 1.3); }
  88%  { transform: translateY(0) scale(1.35, 0.7); }   /* squash on impact */
  100% { opacity: 1; transform: none; }
}
@keyframes speck-splash {
  0%   { opacity: 0; transform: translate(var(--dx), var(--dy)) scale(0.2); }
  30%  { opacity: 1; }
  100% { opacity: 1; transform: none; }
}

/* Instagram */
.insta { padding-block: var(--section); border-top: 1px solid var(--cloud); }
.insta__head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 24px; }
.insta .heading a { text-decoration: none; }
.insta .heading a:hover { text-decoration: underline; text-decoration-thickness: 2px; }
.ig-icon { width: 16px; height: 16px; margin-right: 10px; fill: none; stroke: currentColor; stroke-width: 1.6; }
.ig-icon__dot { fill: currentColor; stroke: none; }
.ig-grid {
  list-style: none; padding: 0; margin: 40px 0 0;
  display: grid; grid-template-columns: repeat(6, 1fr); gap: clamp(8px, 1vw, 16px);
}
.ig-grid a { position: relative; display: block; overflow: hidden; background: var(--bone); }
.ig-grid img { width: 100%; aspect-ratio: 1; object-fit: cover; transition: transform 0.9s var(--ease); }
.ig-grid a:hover img { transform: scale(1.04); }
.ig-grid__tag {
  position: absolute; top: 8px; right: 8px; padding: 4px 7px; border-radius: 999px;
  background: var(--paper); color: var(--ink);
  font: 500 10px/1 var(--mono); letter-spacing: 0.1em; text-transform: uppercase;
}
@media (max-width: 860px) { .ig-grid { grid-template-columns: repeat(3, 1fr); } }

/* Booking */
.booking { padding-block: var(--section); border-top: 1px solid var(--cloud); }
.booking__top {
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 32px var(--gutter);
  align-items: end; margin: 24px 0 clamp(40px, 6vw, 72px);
}
.booking__headline {
  grid-column: 1 / span 8;
  font: 400 clamp(60px, 11vw, 190px)/0.9 var(--serif);
  letter-spacing: -0.03em;
}
.booking__text { grid-column: 9 / span 4; color: var(--graphite); max-width: 26em; }

.booking__card {
  background: var(--card-bg); color: var(--card-fg);
  padding: clamp(28px, 4.5vw, 64px);
  display: grid; gap: clamp(28px, 4vw, 48px);
}
.steps { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px clamp(24px, 3vw, 48px); }
.steps li { display: grid; gap: 10px; align-content: start; border-top: 1px solid var(--card-rule); padding-top: 20px; }
.steps__n { font-size: 12px; letter-spacing: 0.1em; color: var(--card-muted); }
.steps h3 { font: 400 clamp(26px, 2.4vw, 36px)/1.05 var(--serif); }
.steps p { color: var(--card-muted); font-size: 16px; line-height: 1.55; }
.booking__cta { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 28px; }
.booking__note { color: var(--card-muted); font-size: 15px; }
.booking__card :focus-visible { outline-color: var(--card-fg); }

@media (max-width: 860px) {
  .booking__headline, .booking__text { grid-column: 1 / -1; }
  .steps { grid-template-columns: 1fr; }
}

/* Footer: one quiet row of mono caps. Studio left, copyright centred, contact right. */
.footer {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: end; gap: 32px var(--gutter);
  padding-block: 48px;
  border-top: 1px solid var(--cloud);
  font: 400 12px/1.9 var(--mono); letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--pewter);
}
.footer__col { display: grid; justify-items: start; font-style: normal; }
.footer__contact { justify-items: end; }
.footer a { text-decoration: none; }
.footer a:hover { color: var(--ink); text-decoration: underline; }
.footer__copy { color: var(--ash); text-align: center; }
.footer__icon-link { display: inline-flex; align-items: center; }
.footer__icon-link .ig-icon { width: 14px; height: 14px; margin-right: 10px; }
@media (max-width: 760px) {
  .footer { grid-template-columns: 1fr; align-items: start; }
  .footer__contact { justify-items: start; }
  .footer__copy { order: 1; text-align: left; }
}

/* Lightbox */
.lightbox {
  width: 100vw; height: 100dvh; max-width: none; max-height: none;
  margin: 0; padding: 0; border: 0;
  background: var(--lightbox-bg); color: var(--ink);
  overscroll-behavior: contain;
}
.lightbox::backdrop { background: transparent; }
.lightbox[open] { display: grid; place-items: center; }
.lightbox figure {
  display: grid; gap: 14px; justify-items: center; align-content: center;
  width: 100%; height: 100%;
  padding: 80px 96px 32px;
}
.lightbox img {
  max-width: 100%; max-height: calc(100dvh - 160px);
  width: auto; height: auto; object-fit: contain;
  background: var(--bone);
}
.lightbox figcaption { display: flex; align-items: baseline; gap: 16px; }
.lightbox__close { position: absolute; top: 12px; right: var(--gutter); min-height: 40px; }
.lightbox .arrow { position: absolute; top: 50%; translate: 0 -50%; }
.lightbox__prev { left: var(--gutter); }
.lightbox__next { right: var(--gutter); }
@media (max-width: 700px) {
  .lightbox figure { padding: 72px 16px 96px; }
  .lightbox .arrow { top: auto; bottom: 28px; translate: none; }
}
@media (prefers-reduced-motion: no-preference) {
  .lightbox[open] img { animation: develop 0.5s var(--ease); }
}
@keyframes develop { from { opacity: 0; filter: blur(8px); } }
