/* Galata Mutfağı: one screen at a time, text set over shadowed photographs. */

:root {
  --stone: #1d1c19;        /* base: stone in shadow */
  --soot: #131210;         /* deepest shadow */
  --limestone: #e2dccf;    /* text on photographs */
  --stone-grey: #a29b8f;   /* secondary text */
  --verdigris: #7fa899;    /* oxidised copper: icons, focus, hover */
  --veil: rgb(19 18 16 / .58);

  /* --serif and --sans come from fonts.css (npm run fonts), with metric-matched fallbacks */

  --gutter: clamp(16px, 4vw, 72px);
  --header-h: 88px;

  color-scheme: dark;
}

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

html { scroll-behavior: smooth; }
/* Desktop: panels settle into place when you stop near one. Proximity, not mandatory:
   mandatory snapping pulls back from panels taller than the screen (the menu list, contact). */
@media (min-width: 900px) and (min-height: 600px) and (hover: hover) {
  html { scroll-snap-type: y proximity; }
  .panel { scroll-snap-align: start; }
}

body {
  margin: 0;
  background: var(--stone);
  color: var(--limestone);
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

img { display: block; max-width: 100%; }
figure { margin: 0; }
h1, h2, h3 { font-weight: 400; margin: 0; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }

a { color: inherit; text-underline-offset: .25em; text-decoration-thickness: 1px; }
a:hover { color: var(--verdigris); }
:focus-visible { outline: 2px solid var(--verdigris); outline-offset: 4px; }

.skip {
  position: absolute; left: var(--gutter); top: -100px; z-index: 50;
  padding: 10px 16px; background: var(--limestone); color: var(--soot);
}
.skip:focus { top: 12px; }

/* Facts the client still has to supply. */
.tbc { background: none; color: var(--verdigris); border-bottom: 1px dashed currentColor; }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 30px;
  border: 1.5px solid var(--limestone);
  background: none; color: var(--limestone);
  font: 600 .8125rem/1 var(--sans);
  letter-spacing: .12em; text-transform: uppercase;
  text-decoration: none; cursor: pointer;
  transition: background-color .3s ease, color .3s ease, border-color .3s ease;
}
.btn:hover { background: var(--limestone); color: var(--soot); }
.btn--header { min-height: 44px; padding: 0 20px; }
/* The one solid button: every "book a table" moment. */
.btn--solid { background: var(--limestone); color: var(--soot); text-shadow: none; }
.btn--solid:hover { background: var(--verdigris); border-color: var(--verdigris); color: var(--soot); }

/* ---------- Header ---------- */

.site-header {
  position: fixed; inset: 0 0 auto; z-index: 40;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  height: var(--header-h);
  padding: 0 var(--gutter);
  background: linear-gradient(rgb(19 18 16 / .78), rgb(19 18 16 / .35) 60%, rgb(19 18 16 / 0));
  transition: background-color .4s ease;
}
/* Past the opening screen the header gets its own ground, so it stays legible over light photos and the menu card. */
.site-header.is-solid { background: rgb(19 18 16 / .94); }
.site-header .btn--header { justify-self: end; }

.wordmark {
  font-family: var(--serif);
  font-size: 1.25rem;
  letter-spacing: .22em;
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
}

.menu-toggle {
  justify-self: start;
  display: inline-flex; align-items: center; gap: 14px;
  min-height: 44px; padding: 0;
  background: none; border: 0; color: var(--limestone); cursor: pointer;
  font: 500 .8125rem var(--sans); letter-spacing: .12em; text-transform: uppercase;
}
.menu-toggle__bars, .menu-toggle__bars::before, .menu-toggle__bars::after {
  display: block; width: 30px; height: 1.5px; background: currentColor;
  transition: transform .35s ease, opacity .2s ease;
}
.menu-toggle__bars { position: relative; }
.menu-toggle__bars::before, .menu-toggle__bars::after { content: ""; position: absolute; left: 0; }
.menu-toggle__bars::before { top: -9px; }
.menu-toggle__bars::after { top: 9px; }
.nav-open .menu-toggle__bars { background: transparent; }
.nav-open .menu-toggle__bars::before { transform: translateY(9px) rotate(45deg); }
.nav-open .menu-toggle__bars::after { transform: translateY(-9px) rotate(-45deg); }

/* Full-screen menu */
.site-nav {
  position: fixed; inset: 0; z-index: 30;
  display: grid; place-items: center;
  background: var(--soot);
  visibility: hidden; opacity: 0;
  transition: opacity .4s ease, visibility 0s .4s;
}
.nav-open .site-nav { visibility: visible; opacity: 1; transition: opacity .4s ease; }
.nav-open { overflow: hidden; }
.site-nav ul { display: grid; gap: clamp(6px, 1.4vh, 14px); text-align: center; }
.site-nav a {
  font-family: var(--serif);
  font-size: clamp(2.25rem, 6vh, 3.75rem);
  line-height: 1.15;
  letter-spacing: .08em;
  text-transform: uppercase;
  text-decoration: none;
}

/* ---------- Panels ---------- */

.panel {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: grid; place-items: center;
  overflow: hidden;
  isolation: isolate;
}
.panel__bg {
  position: absolute; inset: 0; z-index: -2;
  width: 100%; height: 100%; object-fit: cover;
}
/* Legibility over busy photographs: an even veil, deeper behind the text in the middle
   and at the top and bottom edges, where the header and controls sit. */
.panel:has(.panel__bg)::before,
.slide--full::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(ellipse 60% 55% at 50% 52%, rgb(19 18 16 / .45), rgb(19 18 16 / 0) 72%),
    linear-gradient(rgb(19 18 16 / .5), rgb(19 18 16 / .2) 30%, rgb(19 18 16 / .2) 70%, rgb(19 18 16 / .55)),
    var(--veil);
}
.panel__content, .slide__text, .kicker--over { text-shadow: 0 1px 2px rgb(0 0 0 / .35), 0 2px 24px rgb(0 0 0 / .45); }

.panel__content {
  width: min(100% - 2 * var(--gutter), 56rem);
  padding: calc(var(--header-h) + 24px) 0 72px;
  display: grid; justify-items: center; gap: clamp(20px, 3vh, 32px);
  text-align: center;
  text-wrap: balance;
}

/* Small titles: a name cut into the lintel. */
.kicker {
  font-family: var(--serif);
  font-size: clamp(1.25rem, 1.8vw, 1.625rem);
  letter-spacing: .24em;
  text-transform: uppercase;
}
.kicker--over {
  position: absolute; z-index: 3; left: 0; right: 0;
  top: calc(var(--header-h) + 8px);
  text-align: center;
  pointer-events: none;
  text-shadow: 0 1px 24px rgb(0 0 0 / .6);
}

.statement {
  font-family: var(--serif);
  font-size: clamp(1.875rem, 4vw, 3.5rem);
  line-height: 1.15;
}
.statement--list { color: var(--stone-grey); font-size: clamp(1.5rem, 2.8vw, 2.5rem); line-height: 1.35; }
.statement--strong { font-size: clamp(1.875rem, 4vw, 3.5rem); }

.lead {
  max-width: 34em;
  font-size: clamp(1.125rem, 1.6vw, 1.375rem);
  line-height: 1.55;
  color: var(--limestone);
}

/* Hero: the tower turns above, the name is cut into the plinth below. */
.panel--hero {
  place-items: end center;
  /* A faint warmth behind the tower, so it separates from the night. */
  /* Warm haze behind the tower instead of a glow filter on the canvas:
     a CSS filter on an animated canvas cost a third of all frames (measured). This costs nothing. */
  background:
    radial-gradient(14% 34% at 50% 40%, rgb(214 160 96 / .1), transparent 72%),
    radial-gradient(48% 62% at 50% 40%, rgb(110 84 58 / .14), transparent 70%),
    var(--stone);
}
.panel--hero .panel__content { padding-bottom: clamp(88px, 12vh, 128px); gap: 14px; }
.tower {
  position: absolute; inset: 0; z-index: -1;
  /* The foot of the tower dissolves into the dark before it reaches the name. */
  -webkit-mask-image: linear-gradient(#000 52%, transparent 84%);
          mask-image: linear-gradient(#000 52%, transparent 84%);
  opacity: 0;
  transition: opacity 1.8s ease;
}
.tower.is-ready { opacity: 1; }
.tower canvas { display: block; width: 100%; height: 100%; }
.embers {
  position: absolute; inset: 0; z-index: -2;
  width: 100%; height: 100%;
  opacity: 0;
  transition: opacity 2.4s ease;
}
.embers.is-ready { opacity: 1; }
/* Parallax: one scroll value, three speeds. */
.motion .panel--hero .tower { translate: 0 calc(var(--py, 0) * .32px); }
.motion .panel--hero .embers { translate: 0 calc(var(--py, 0) * .14px); }
.motion .panel--hero .panel__content { translate: 0 calc(var(--py, 0) * -.12px); }

.hero-name {
  font-family: var(--serif);
  font-size: clamp(2.25rem, 6vw, 5.25rem);
  line-height: 1;
  letter-spacing: .14em;
  text-transform: uppercase;
  /* Optical centring: tracking adds space after the last letter. */
  padding-left: .14em;
}
.hero-line { max-width: 24em; font-size: clamp(1.125rem, 1.8vw, 1.5rem); line-height: 1.5; }

.scroll-cue {
  position: absolute; left: 50%; bottom: 32px;
  width: 44px; height: 44px; margin-left: -22px;
  display: grid; place-items: center;
}
.scroll-cue::before {
  content: ""; width: 1px; height: 36px; background: var(--limestone);
  transform-origin: top;
}
.motion .scroll-cue::before { animation: cue 2.4s ease-in-out infinite; }
@keyframes cue {
  0% { transform: scaleY(0); opacity: 1; }
  60% { transform: scaleY(1); opacity: 1; }
  100% { transform: scaleY(1); opacity: 0; }
}

/* ---------- Menu book: sheets turn over the spine ---------- */

.panel__content--menu {
  width: min(100% - 2 * var(--gutter), 74rem);
  gap: clamp(20px, 3vh, 32px);
  padding-block: calc(var(--header-h) + 16px) 40px;
}
.menu-intro { display: grid; justify-items: center; gap: 14px; }
.menu-intro .statement { font-size: clamp(1.625rem, 3vw, 2.5rem); }

.book-wrap { width: 100%; display: grid; justify-items: center; gap: 18px; }

.book {
  --paper: #e4ddcf;
  --ink: #23211d;
  --ink-soft: #6a6357;
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .2 0 0 0 0 .18 0 0 0 0 .15 0 0 0 .07 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  position: relative;
  width: min(780px, 100%, calc((100svh - 400px) * 1.43));
  aspect-ratio: 1.43;
  perspective: 2400px;
  transition: transform 0.9s cubic-bezier(.645, .045, .355, 1);
  text-align: center;
  text-wrap: balance;
}
.book:focus-visible { outline-offset: 10px; }
/* Closed, the book sits centred on its cover; open, the spine is in the middle. */
.book[data-state="front"] { transform: translateX(-25%); }
.book[data-state="back"] { transform: translateX(25%); }

.book__leaf {
  position: absolute; top: 0; left: 50%;
  width: 50%; height: 100%;
  transform-origin: left center;
  transform-style: preserve-3d;
  transition: transform 1.1s cubic-bezier(.645, .045, .355, 1);
  will-change: transform; /* ready on the GPU before the first turn */
}
.book__leaf.is-turned { transform: rotateY(-180deg); }
.book__leaf.is-next, .book__leaf.is-prev { cursor: pointer; }

.page {
  position: absolute; inset: 0;
  display: grid; place-content: center; justify-items: center; gap: 18px;
  padding: clamp(28px, 4vw, 52px) clamp(22px, 3vw, 40px);
  background: var(--grain), var(--paper);
  color: var(--ink);
  outline: 1px solid rgb(35 33 29 / .22);
  outline-offset: -12px;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  box-shadow: 0 30px 60px -24px rgb(0 0 0 / .65);
}
.page--back { transform: rotateY(180deg); }
/* The fold: each page darkens towards the spine. */
.page::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to right, rgb(35 33 29 / .2), rgb(35 33 29 / 0) 9%);
}
.page--back::after { background: linear-gradient(to left, rgb(35 33 29 / .2), rgb(35 33 29 / 0) 9%); }

.page--cover {
  background: var(--grain), #27241f;
  color: var(--limestone);
  outline-color: rgb(143 181 167 / .4);
}
.page--cover::after { background: none; }
.cover-tower { width: 34px; height: 85px; fill: none; stroke: var(--limestone); stroke-width: 1; stroke-linecap: round; opacity: .9; }
.cover-tower--small { width: 22px; height: 55px; }
.cover-house { font-size: .75rem; font-weight: 500; letter-spacing: .26em; text-transform: uppercase; }
.cover-title { font-family: var(--serif); font-size: clamp(1.75rem, 3vw, 2.5rem); line-height: 1.1; }
.cover-season { font-size: .875rem; color: var(--stone-grey); }

.page-prose { max-width: 15em; font-family: var(--serif); font-size: clamp(1.25rem, 1.8vw, 1.625rem); line-height: 1.35; }

.courses { display: grid; gap: clamp(28px, 5vh, 52px); }
.courses li { display: grid; justify-items: center; gap: 4px; }
.courses li::before {
  content: attr(value);
  margin-bottom: 6px;
  font-size: .75rem; font-weight: 500; letter-spacing: .12em;
  color: var(--ink-soft);
}
.course__dish { font-family: var(--serif); font-size: clamp(1.625rem, 2.6vw, 2.25rem); line-height: 1.1; }
.course__with { font-family: var(--serif); font-size: clamp(1.125rem, 1.6vw, 1.375rem); color: var(--ink-soft); }
.course__origin { margin-top: 6px; font-size: .6875rem; font-weight: 500; letter-spacing: .2em; text-transform: uppercase; color: var(--ink-soft); }

.prices { display: grid; gap: 10px; width: 100%; max-width: 17rem; margin: 0; font-size: .9375rem; }
.prices div { display: flex; justify-content: space-between; gap: 16px; text-align: left; }
.prices dd { margin: 0; }
.page-note { max-width: 17rem; font-size: .8125rem; line-height: 1.5; color: var(--ink-soft); }
.page .tbc { color: #2f5c4f; }

.book-controls { display: flex; align-items: center; gap: 20px; }
.book-controls .slider__arrow { position: static; margin: 0; }
.book-status { min-width: 5.5em; font-size: .875rem; color: var(--stone-grey); font-variant-numeric: tabular-nums; }

/* ---------- Book or list ---------- */

.menu-view { display: inline-flex; gap: 4px; padding: 4px; border: 1px solid rgb(226 220 207 / .25); }
.menu-view button {
  min-height: 36px; padding: 0 18px;
  background: none; border: 0; color: var(--stone-grey); cursor: pointer;
  font: 500 .8125rem var(--sans); letter-spacing: .12em; text-transform: uppercase;
  transition: background-color .25s ease, color .25s ease;
}
.menu-view button:hover { color: var(--limestone); }
.menu-view button[aria-pressed="true"] { background: rgb(226 220 207 / .12); color: var(--limestone); }

/* Without JavaScript the book cannot turn, so the list shows instead. */
html:not(.js) .menu-view,
html:not(.js) .book-wrap,
[data-view="list"] .book-wrap,
[data-view="book"] .menu-list { display: none; }

.menu-list { width: min(100%, 40rem); text-align: left; text-wrap: pretty; }
.menu-list__head {
  display: flex; justify-content: space-between; align-items: baseline; gap: 16px;
  padding-bottom: 14px; border-bottom: 1px solid rgb(226 220 207 / .3);
  font-family: var(--serif); font-size: 1.5rem;
}
.menu-list__head span { font-family: var(--sans); font-size: .875rem; color: var(--stone-grey); }
.menu-list__courses { counter-reset: course; }
.menu-list__courses li {
  counter-increment: course;
  display: grid; grid-template-columns: 2.25rem 1fr auto; align-items: baseline; gap: 4px 12px;
  padding: 14px 0;
  border-bottom: 1px solid rgb(226 220 207 / .12);
}
.menu-list__courses li::before { content: counter(course); font-size: .8125rem; color: var(--stone-grey); font-variant-numeric: tabular-nums; }
.menu-list__dish { font-family: var(--serif); font-size: clamp(1.25rem, 2vw, 1.5rem); line-height: 1.25; }
.menu-list__dish span { color: var(--stone-grey); margin: 0 .15em; }
.menu-list__origin { font-size: .6875rem; font-weight: 500; letter-spacing: .2em; text-transform: uppercase; color: var(--stone-grey); }
.menu-list__prices { display: grid; gap: 8px; margin: 22px 0 0; }
.menu-list__prices div { display: flex; justify-content: space-between; gap: 16px; }
.menu-list__prices dd { margin: 0; }
.menu-list__note { margin-top: 16px; font-size: .875rem; color: var(--stone-grey); }

@media (max-width: 480px) {
  .menu-list__courses li { grid-template-columns: 2rem 1fr; }
  .menu-list__origin { grid-column: 2; }
}

/* Phones: no spread, the pages sit side by side and swipe. */
@media (max-width: 760px) {
  .book {
    --grain: none; /* the paper texture costs frames while swiping on a slow phone (measured) */
    display: flex;
    width: min(100%, 360px);
    aspect-ratio: auto;
    perspective: none;
    transform: none !important;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
  }
  .book::-webkit-scrollbar { display: none; }
  .book__leaf { display: contents; }
  .page {
    position: relative; inset: auto;
    flex: 0 0 100%;
    aspect-ratio: .7;
    transform: none;
    backface-visibility: visible;
    -webkit-backface-visibility: visible;
    scroll-snap-align: center;
    box-shadow: none;
  }
  .page::after { background: none; }
}

@media (prefers-reduced-motion: reduce) {
  .book, .book__leaf { transition: none; }
}

/* Reservation rules */
.panel__content--rules { gap: 18px; }
.panel__content--rules p { max-width: 38em; font-size: clamp(1.0625rem, 1.5vw, 1.3125rem); line-height: 1.55; }
.panel__content--rules .btn { margin-top: 18px; }

/* ---------- Sliders ---------- */

.panel--slider { display: block; place-items: normal; }
.slider { position: relative; height: 100vh; height: 100svh; }
.slider__track {
  display: flex; height: 100%;
  overflow-x: auto; overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}
.slider__track::-webkit-scrollbar { display: none; }
.slider__track:focus-visible { outline-offset: -4px; }

.slide { position: relative; flex: 0 0 100%; scroll-snap-align: start; overflow: hidden; }
.slide img { width: 100%; height: 100%; object-fit: cover; }
/* One light for all photographs: a little dimmer, a little less colour. */
.slide--split img { filter: brightness(.82) saturate(.85); }

.slide--split { display: grid; grid-template-columns: 1fr 1fr; }
.slide--split::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(rgb(19 18 16 / .45), rgb(19 18 16 / 0) 30%, rgb(19 18 16 / 0) 70%, rgb(19 18 16 / .55));
  pointer-events: none;
}
.slide--split .slide__caption {
  position: absolute; z-index: 1; left: 0; right: 0; bottom: 84px;
  text-align: center;
  font-family: var(--serif); font-size: clamp(1.25rem, 2vw, 1.75rem);
  text-shadow: 0 1px 20px rgb(0 0 0 / .7);
}

.slide--full img { position: absolute; inset: 0; }
.slide--full::after { z-index: 0; }
.slide__text {
  position: relative; z-index: 1;
  height: 100%;
  display: grid; place-content: center; justify-items: center; gap: 22px;
  padding: 0 calc(var(--gutter) + 64px);
  text-align: center; text-wrap: balance;
}
.slide__text h3 { font-family: var(--serif); font-size: clamp(2rem, 4vw, 3.5rem); line-height: 1.1; }
.slide__text p { max-width: 30em; font-size: clamp(1.125rem, 1.7vw, 1.5rem); line-height: 1.5; }

.slider__arrow {
  position: absolute; top: 50%; z-index: 2;
  width: 48px; height: 48px; margin-top: -24px;
  display: grid; place-items: center;
  background: rgb(19 18 16 / .25); color: var(--limestone);
  border: 1px solid rgb(226 220 207 / .7);
  cursor: pointer;
  transition: background-color .3s ease, color .3s ease;
}
.slider__arrow:hover { background: var(--limestone); color: var(--soot); }
.slider__arrow:disabled { opacity: .3; cursor: default; }
.slider__arrow:disabled:hover { background: rgb(19 18 16 / .25); color: var(--limestone); }
.slider__arrow svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.5; }
.slider__arrow--prev { left: var(--gutter); }
.slider__arrow--next { right: var(--gutter); }

.slider__dots {
  position: absolute; z-index: 2; left: 0; right: 0; bottom: 28px;
  display: flex; justify-content: center; gap: 4px;
}
.slider__dots button {
  width: 32px; height: 32px; padding: 0;
  display: grid; place-items: center;
  background: none; border: 0; cursor: pointer;
}
.slider__dots button::before {
  content: ""; width: 11px; height: 11px; border-radius: 50%;
  border: 1px solid var(--limestone);
  transition: background-color .3s ease;
}
.slider__dots button[aria-current="true"]::before { background: var(--limestone); }

/* ---------- Contact ---------- */

.panel--contact {
  display: block;
  place-items: normal; /* block layout honours justify-items now */
  background: var(--stone);
  padding: calc(var(--header-h) + 16px) var(--gutter) 0;
}
.contact-title {
  font-family: var(--serif);
  font-size: clamp(2.25rem, 4vw, 3.5rem);
  text-align: center;
  margin-bottom: clamp(32px, 6vh, 64px);
}
.contact {
  display: grid; grid-template-columns: 1.4fr 1fr; gap: clamp(32px, 5vw, 72px);
  max-width: 1200px; margin: 0 auto;
  align-items: center;
}
.map { display: grid; gap: 10px; width: 100%; }
.map iframe {
  display: block; width: 100%;
  aspect-ratio: 4 / 3; max-height: 56vh;
  border: 0;
  background: var(--soot);
  /* Night version of the street map, in the site's stone tones */
  filter: grayscale(1) invert(.9) sepia(.18) contrast(.9) brightness(.92);
}
.map figcaption { font-size: .875rem; }

.contact-list { display: grid; gap: 26px; }
.contact-list li { display: grid; grid-template-columns: 48px 1fr; gap: 22px; align-items: center; font-size: 1.0625rem; line-height: 1.5; }
.contact-icon {
  width: 48px; height: 48px; border-radius: 50%;
  border: 1px solid var(--verdigris);
  display: grid; place-items: center;
}
.contact-icon svg { width: 22px; height: 22px; fill: none; stroke: var(--verdigris); stroke-width: 1.3; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- Closing call to action ---------- */

.closing-cta {
  display: grid; justify-items: center; gap: 20px;
  max-width: 1200px; margin: clamp(56px, 9vh, 96px) auto 0;
  text-align: center;
}
.closing-cta__line { font-family: var(--serif); font-size: clamp(2rem, 4vw, 3.25rem); line-height: 1.1; }

/* ---------- Back to top ---------- */

.to-top {
  position: fixed; right: var(--gutter); bottom: 28px; z-index: 35;
  width: 48px; height: 48px;
  display: grid; place-items: center;
  background: rgb(19 18 16 / .78); color: var(--limestone);
  border: 1px solid rgb(226 220 207 / .45);
  cursor: pointer;
  opacity: 0; visibility: hidden; translate: 0 8px;
  transition: opacity .5s ease, translate .5s ease, visibility 0s .5s, background-color .3s ease, color .3s ease;
}
.to-top.is-visible { opacity: 1; visibility: visible; translate: 0 0; transition: opacity .5s ease, translate .5s ease, background-color .3s ease, color .3s ease; }
.to-top:hover { background: var(--limestone); color: var(--soot); }
.to-top svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.5; }
.nav-open .to-top { opacity: 0; visibility: hidden; }
@media (max-width: 760px) {
  /* clear of the slider arrows, which sit at the bottom on phones */
  .to-top { bottom: 84px; width: 44px; height: 44px; }
}

.site-footer {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px;
  max-width: 1200px; margin: clamp(48px, 8vh, 88px) auto 0;
  padding: 24px 0 28px;
  border-top: 1px solid rgb(226 220 207 / .12);
  font-size: .8125rem; color: var(--stone-grey);
}

/* ---------- Entrance: text settles as its panel arrives ---------- */

/* Not the hero: it is on screen at load, and fading it in held back the largest paint (measured LCP +2.5 s on mobile). */
.motion .panel:not(.panel--hero) .panel__content,
.motion .slide__text { opacity: 0; transform: translateY(14px); transition: opacity 1s ease, transform 1.2s cubic-bezier(.2, .7, .2, 1); }
.motion .panel.is-in .panel__content,
.motion .is-in .slide__text { opacity: 1; transform: none; }

/* ---------- Small screens ---------- */

@media (max-width: 760px) {
  :root { --header-h: 72px; }
  .site-header { grid-template-columns: auto 1fr auto; gap: 12px; }
  /* hidden from view, still the button's name for screen readers */
  .menu-toggle__label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .wordmark { justify-self: center; font-size: 1rem; letter-spacing: .16em; }
  .btn--header { padding: 0 14px; font-size: .75rem; letter-spacing: .08em; }

  .slide--split { grid-template-columns: 1fr; grid-template-rows: 1fr 1fr; }
  .slide--split figcaption { bottom: 76px; }
  .slider__arrow { top: auto; bottom: 20px; margin-top: 0; width: 44px; height: 44px; }
  .slider__dots { bottom: 26px; }
  .slide__text { padding: 0 var(--gutter); }

  .contact { grid-template-columns: 1fr; }
  .map { aspect-ratio: 4 / 3; }
  .contact-list li { grid-template-columns: 44px 1fr; gap: 16px; font-size: 1rem; }
  .contact-icon { width: 44px; height: 44px; }
}

@media (max-width: 380px) {
  .wordmark { letter-spacing: .1em; font-size: .9375rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn, .site-nav, .slider__arrow, .to-top, .menu-view button, .menu-toggle__bars, .menu-toggle__bars::before, .menu-toggle__bars::after { transition: none !important; }
}
