:root {
  --carta: #faf7f2;       /* warm paper, the page */
  --inchiostro: #24345c;  /* night blue, every word */
  --tenue: #24345c99;     /* night blue at 60%, the captions */
  --filo: #24345c26;      /* hairlines */
  --argilla: #b98468;     /* the one accent: rules and the dot */
  --ombra: 20, 28, 52;    /* rgb of the soft shadows */
  --serif: "Newsreader Variable", "Times New Roman", serif;
  --sans: "Mona Sans Variable", "Helvetica Neue", Arial, sans-serif;
  --expo: cubic-bezier(.16, 1, .3, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { background: var(--carta); }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
body {
  background: var(--carta);
  color: var(--inchiostro);
  font-family: var(--sans);
  font-size: clamp(11px, min(1.05vw, 1.9vh), 15px);
  line-height: 1.45;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
img { display: block; width: 100%; height: 100%; object-fit: cover; }
a { color: inherit; text-decoration: none; }

/* the bar */
.bar {
  position: fixed; inset: 0 0 auto 0; z-index: 5;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  padding: clamp(10px, 2.4vh, 22px) clamp(14px, 3vw, 40px);
  background: linear-gradient(var(--carta) 55%, #faf7f200);
}
.brand { font-family: var(--serif); font-size: clamp(16px, min(1.8vw, 3.4vh), 24px); font-variation-settings: "opsz" 36; letter-spacing: -.01em; }
.bar__mid { font-size: .8em; letter-spacing: .08em; text-transform: uppercase; opacity: .7; }
.book { justify-self: end; display: inline-flex; align-items: center; gap: .55em; font-size: .9em; letter-spacing: .02em; }
.book__dot {
  width: .5em; height: .5em; border-radius: 50%; background: var(--argilla);
  transform: scale(0); transition: transform .5s var(--expo);
}
@media (hover: hover) { .book:hover .book__dot { transform: scale(1); } }
.book:focus-visible .book__dot { transform: scale(1); }

/* the opening */
.hero {
  height: 100vh;
  display: flex; flex-direction: column; justify-content: center;
  padding: 0 clamp(14px, 6vw, 120px);
  gap: clamp(10px, 2.6vh, 26px);
  position: relative;
}
.kicker, .label { font-size: .78em; letter-spacing: .1em; text-transform: uppercase; }
.kicker { opacity: .75; }
.title {
  font-family: var(--serif); font-weight: 340; font-variation-settings: "opsz" 72;
  font-size: clamp(26px, min(6.2vw, 10.5vh), 96px);
  line-height: 1; letter-spacing: -.02em; max-width: 15em;
}
.indent { display: inline-block; width: clamp(28px, 7vw, 120px); }
.lede { max-width: 30em; color: var(--tenue); }
.w { display: inline-block; will-change: transform; }
.hint { position: absolute; left: 50%; bottom: clamp(12px, 4vh, 36px); display: flex; flex-direction: column; align-items: center; gap: 8px; transform: translateX(-50%); }
.hint__line { position: relative; width: 1px; height: clamp(22px, 6vh, 52px); background: var(--filo); overflow: hidden; }
.hint__run { position: absolute; left: 0; top: 0; width: 1px; height: 40%; background: var(--inchiostro); }
.hint__txt { font-size: .7em; letter-spacing: .14em; text-transform: uppercase; opacity: .6; }

/* the two features */
.feature {
  height: 100vh;
  display: grid; align-items: start;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: clamp(12px, 4vw, 80px);
  padding: clamp(46px, 11vh, 110px) clamp(14px, 6vw, 120px) 0;
}
.feature[data-side="left"] { grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); }
.side { display: flex; flex-direction: column; gap: clamp(10px, 3vh, 36px); height: 100%; }
.feature[data-side="left"] .side { align-items: flex-end; text-align: right; }
.head {
  font-family: var(--serif); font-weight: 340; font-variation-settings: "opsz" 48;
  font-size: clamp(17px, min(3.6vw, 6.2vh), 60px);
  line-height: 1.02; letter-spacing: -.015em; max-width: 7.4em;
}
.small {
  position: sticky; top: 30vh;
  width: min(24vw, 26vh, 270px);
  display: flex; flex-direction: column; gap: clamp(6px, 1.4vh, 12px);
}
.small--wide { width: min(28vw, 30vh, 320px); }
.small__img { aspect-ratio: 727 / 1024; overflow: hidden; border-radius: 2px; box-shadow: 0 10px 24px -14px rgba(var(--ombra), .45); }
.small--wide .small__img { aspect-ratio: 4 / 3; }
figcaption { display: flex; flex-direction: column; gap: 6px; }
.feature[data-side="left"] figcaption { align-items: flex-end; }
.rule { width: 100%; height: 1px; background: var(--argilla); transform-origin: 0 50%; opacity: .7; }
.feature[data-side="left"] .rule { transform-origin: 100% 50%; }
.cap { color: var(--tenue); font-size: .9em; }
.ch { display: inline-block; }

.big { display: flex; justify-content: center; }
.frame {
  position: relative;
  width: min(40vw, 46vh, 460px);
  aspect-ratio: 701 / 1235;
  overflow: hidden; border-radius: 3px;
  box-shadow: 0 30px 60px -36px rgba(var(--ombra), .55), 0 2px 6px -2px rgba(var(--ombra), .18);
}
.frame__in { position: absolute; left: 0; right: 0; top: -25%; height: 125%; }
.shine {
  position: absolute; inset: 0; pointer-events: none; border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .28);
  background: linear-gradient(115deg, rgba(255, 255, 255, .16), rgba(255, 255, 255, 0) 38%);
}
.chip {
  position: absolute; left: 10px; bottom: 10px;
  padding: .45em .8em; border-radius: 99px;
  background: rgba(250, 247, 242, .82); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  font-size: .72em; letter-spacing: .06em; text-transform: uppercase; white-space: nowrap;
}
.feature[data-side="left"] .chip { left: auto; right: 10px; }

/* the end */
.end {
  height: 100vh;
  display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center;
  gap: clamp(14px, 3.4vh, 32px);
  padding: 0 clamp(14px, 6vw, 120px);
}
.end__title { font-family: var(--serif); font-weight: 340; font-variation-settings: "opsz" 60; font-size: clamp(22px, min(4.6vw, 8vh), 72px); line-height: 1.02; letter-spacing: -.02em; max-width: 11em; }
.pill {
  position: relative; display: inline-grid; place-items: center;
  padding: .95em 1.9em; border-radius: 99px; color: var(--carta);
  font-size: 1em; letter-spacing: .02em;
}
.pill__bg { position: absolute; inset: 0; border-radius: inherit; background: var(--inchiostro); transition: transform .5s cubic-bezier(.34, 1.56, .64, 1); }
.pill__txt { position: relative; font-variation-settings: "wdth" 100; transition: font-variation-settings .5s var(--expo); }
@media (hover: hover) {
  .pill:hover .pill__bg { transform: scale(1.06, 1.12); }
  .pill:hover .pill__txt { font-variation-settings: "wdth" 125; }
}
.pill:active .pill__bg { transform: scale(.96); transition-duration: .12s; }
.hours { color: var(--tenue); font-size: .85em; }

.grain {
  position: fixed; inset: 0; pointer-events: none; z-index: 9; opacity: .06; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

/* narrow and short: the phone box */
@media (max-width: 640px) {
  .bar__mid { display: none; }
  .bar { grid-template-columns: 1fr 1fr; }
  .feature { padding-top: clamp(44px, 12vh, 80px); gap: 12px; }
  .frame { width: min(46vw, 40vh); }
  .small { top: 22vh; width: min(30vw, 22vh); }
  .small--wide { width: min(34vw, 24vh); }
  .cap { display: none; }
  .chip { left: 6px; bottom: 6px; font-size: .62em; }
  .feature[data-side="left"] .chip { right: 6px; }
}
