/* Kitchen 42 — the building is square, the food is round.
   Palette and grid come from the restaurant's own facade on the Princes Hwy. */

@font-face {
  font-family: Archivo;
  src: url(assets/fonts/archivo-var-latin.woff2) format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}

:root {
  --pomodoro: #d7281c;
  --grana: #f7b916;
  --rim: #1b4aa0; /* text-only panels; never next to food */
  --flour: #fff;
  --char: #000;
  --steel: #e6e6e2;
  --line: 4px;
  --pad: clamp(1rem, 3.2vw, 2.75rem);
}

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

html { scroll-behavior: smooth; scroll-padding-top: 5.5rem; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

body {
  margin: 0;
  padding-inline: env(safe-area-inset-left) env(safe-area-inset-right); /* notch, phone on its side */
  font: 400 1.0625rem/1.55 Archivo, "Helvetica Neue", Arial, sans-serif;
  color: var(--char);
  background: var(--flour);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, video, iframe { display: block; max-width: 100%; }
a { color: inherit; text-underline-offset: 0.2em; }
h1, h2, h3, p, ul, ol, figure, blockquote, table { margin: 0; }
ul, ol { padding: 0; list-style: none; }

:focus-visible { outline: 3px solid var(--rim); outline-offset: 3px; }
.dark :focus-visible, .on-red :focus-visible { outline-color: var(--grana); }

.skip {
  position: absolute; left: var(--pad); top: -5rem; z-index: 50;
  padding: 0.6rem 1rem; background: var(--char); color: #fff;
}
.skip:focus { top: 0.5rem; }

/* ---------- type ---------- */

.display {
  font-size: clamp(2.5rem, 5.7vw, 6rem);
  font-stretch: 125%;
  font-weight: 850;
  line-height: 0.95;
  letter-spacing: -0.03em;
}
.display span, .h2 span { display: block; text-wrap: balance; }

.h2 {
  font-size: clamp(2rem, 4vw, 3.5rem);
  font-stretch: 120%;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.025em;
  max-width: 17ch;
  text-wrap: balance;
}

.lede { font-size: clamp(1.125rem, 1.5vw, 1.3125rem); line-height: 1.45; max-width: 34em; }
.prose { max-width: 36em; }
.prose > * + * { margin-top: 1em; }

/* ---------- layout ---------- */

.wrap { max-width: 86rem; margin-inline: auto; padding-inline: var(--pad); }
.band { padding-block: clamp(3.5rem, 8vw, 7rem); }
.band-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 1.5rem; margin-bottom: clamp(2rem, 4vw, 3.5rem); }

/* The facade: colour planes held in black frames. The gap IS the frame. */
.facade {
  display: grid;
  gap: var(--line);
  background: var(--char);
  border-block: var(--line) solid var(--char);
}
.cell { background: var(--flour); padding: var(--pad); min-width: 0; }
.red { background: var(--pomodoro); color: #fff; }
.yellow { background: var(--grana); }
.blue { background: var(--rim); color: #fff; }
.steel { background: var(--steel); }
.dark { background: var(--char); color: #fff; }

/* ---------- buttons ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 3.25rem; padding: 0 1.5rem;
  border: var(--line) solid var(--char);
  background: var(--char); color: #fff;
  font: inherit; font-weight: 650; font-stretch: 112%;
  text-decoration: none; white-space: nowrap; cursor: pointer;
  transition: background-color 0.15s, color 0.15s;
}
.btn-alt { background: var(--flour); color: var(--char); }
.dark .btn { background: var(--grana); color: var(--char); border-color: var(--grana); }
@media (hover: hover) { /* on touch a hover colour sticks after the tap */
  .btn:hover { background: var(--pomodoro); }
  .btn-alt:hover { background: var(--grana); }
  .dark .btn:hover { background: var(--flour); border-color: var(--flour); }
}
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem 1rem; }
.textlink { font-weight: 600; text-decoration-thickness: 2px; }
.textlink:hover { text-decoration-thickness: 4px; }

/* ---------- header ---------- */

.top {
  position: sticky; top: 0; z-index: 20;
  background: var(--flour);
  border-bottom: var(--line) solid var(--char);
}
.top-in { display: flex; align-items: center; gap: 1.75rem; min-height: 4.25rem; padding-inline: var(--pad); }
.brand {
  display: flex; align-items: center; align-self: stretch; gap: 0.6rem; margin-right: auto;
  font-size: 1.3rem; font-weight: 900; font-stretch: 125%; letter-spacing: -0.02em;
  text-decoration: none; white-space: nowrap;
}
.mark { width: 1.75rem; height: 1.75rem; flex: none; }
.nav { display: flex; gap: 1.75rem; }
.nav a { font-weight: 550; text-decoration: none; }
.nav a:hover, .nav a[aria-current] { text-decoration: underline; text-decoration-thickness: 3px; text-underline-offset: 0.35em; }
.top .btn { min-height: 2.75rem; padding-inline: 1.1rem; }

/* ---------- hero ---------- */

.hero {
  grid-template-columns: repeat(12, 1fr);
  grid-template-areas:
    "head head head head head head head pizza pizza pizza pizza pizza"
    "num  num  num  cta  cta  cta  cta  pizza pizza pizza pizza pizza"
    "num  num  num  cta  cta  cta  cta  open  open  open  rate  rate";
  border-top: 0;
}
.hero-head { grid-area: head; padding-block: clamp(2rem, 5vw, 4.5rem); padding-right: 11vw; }
.hero-pizza-cell {
  grid-area: pizza; position: relative; z-index: 2; padding: 0;
  container-type: size; /* lets the pizza size itself to this panel */
}
.hero-num { grid-area: num; display: flex; flex-direction: column; justify-content: space-between; gap: 1rem; text-decoration: none; }
.hero-cta { grid-area: cta; display: flex; flex-direction: column; justify-content: space-between; gap: 1.75rem; }
.hero-open { grid-area: open; }
.hero-rate { grid-area: rate; text-decoration: none; }

.pizza {
  position: absolute; top: 50%; left: -24cqw;
  width: min(116cqw, 94cqh); aspect-ratio: 1;
  translate: 0 -50%;
  border-radius: 50%; overflow: hidden;
  box-shadow: 0 1.5rem 2.5rem -0.75rem rgb(0 0 0 / 0.55);
}
.pizza img { width: 100%; height: 100%; object-fit: cover; scale: 1.07; filter: saturate(1.1) contrast(1.03); }

.num-big { font-size: clamp(4rem, 10vw, 9.5rem); font-weight: 900; font-stretch: 125%; line-height: 0.8; letter-spacing: -0.05em; }
.num-small { font-weight: 600; line-height: 1.25; }

.stat-big { font-size: clamp(1.6rem, 2.6vw, 2.4rem); font-weight: 800; font-stretch: 118%; line-height: 1.05; letter-spacing: -0.02em; }
.stat-small { margin-top: 0.4rem; font-weight: 500; line-height: 1.3; }

/* ---------- specials ---------- */

.specials { grid-template-columns: 1fr 1fr; }
.special { position: relative; overflow: hidden; min-height: clamp(19rem, 34vw, 28rem); padding: clamp(1.5rem, 4vw, 3.5rem); }
.special-day { font-weight: 600; font-size: 1.125rem; }
.special-offer { margin-top: 0.4rem; font-size: clamp(2.2rem, 4.6vw, 4.25rem); font-weight: 850; font-stretch: 122%; line-height: 0.95; letter-spacing: -0.03em; max-width: 9ch; }
.special-note { margin-top: 1rem; max-width: 17em; font-weight: 500; position: relative; z-index: 1; }
.special-wide { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.5rem 3rem; padding: clamp(1.5rem, 4vw, 3.5rem); }
.special-wide .special-offer { max-width: none; font-size: clamp(1.75rem, 3.2vw, 3rem); }
.special-wide .special-note { max-width: 30em; }
.special .plate { position: absolute; right: -9%; bottom: -24%; width: min(54%, 25rem); box-shadow: 0 1rem 2rem -0.5rem rgb(0 0 0 / 0.45); }

/* ---------- plates ---------- */

.plate { aspect-ratio: 1; border-radius: 50%; overflow: hidden; background: var(--steel); }
.plate img {
  width: 100%; height: 100%;
  object-fit: cover; object-position: var(--p, 50% 50%); scale: var(--z, 1);
  filter: saturate(1.12) contrast(1.04);
}

.dishes { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(2rem, 4vw, 3.5rem) clamp(1rem, 2.5vw, 2.5rem); }
.dish-row { display: flex; align-items: baseline; justify-content: space-between; gap: 0.75rem; margin-top: 1.1rem; }
.dish-name { font-size: 1.1875rem; font-weight: 750; font-stretch: 112%; line-height: 1.15; letter-spacing: -0.01em; }
.price { font-weight: 650; font-variant-numeric: tabular-nums; white-space: nowrap; }
.dish-desc { margin-top: 0.35rem; font-size: 0.9375rem; line-height: 1.4; }

/* ---------- kitchen ---------- */

.kitchen { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 5rem); align-items: start; }
.made { margin-top: 2rem; border-top: var(--line) solid var(--char); }
.made li { display: flex; justify-content: space-between; gap: 1rem; padding: 0.7rem 0; border-bottom: 1px solid var(--char); font-weight: 600; }
.made li span { font-weight: 400; text-align: right; }

.frames { grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; border: var(--line) solid var(--char); aspect-ratio: 1.02; }
.frame { position: relative; overflow: hidden; background: var(--char); }
.frames .frame:first-child { grid-row: span 2; }
.frame img, .frame video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.frame figcaption {
  position: absolute; left: 0; bottom: 0; max-width: 90%;
  padding: 0.45rem 0.8rem; background: var(--char); color: #fff;
  font-size: 0.875rem; font-weight: 550; line-height: 1.3;
}

/* ---------- lunch ---------- */

.lunch { grid-template-columns: 5fr 7fr; }
.lunch .frame { min-height: clamp(20rem, 46vw, 40rem); }
.lunch-text { padding-block: clamp(2.5rem, 6vw, 5rem); }

/* ---------- story ---------- */

.story { display: grid; grid-template-columns: 7fr 5fr; gap: clamp(2rem, 5vw, 5rem); align-items: center; }
.photo { border: var(--line) solid var(--char); }
.photo img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- reviews ---------- */

.reviews { grid-template-columns: repeat(12, 1fr); }
.quote { display: flex; flex-direction: column; justify-content: space-between; gap: 1.5rem; }
.quote p { font-size: clamp(1.125rem, 1.6vw, 1.4rem); font-weight: 500; line-height: 1.35; text-wrap: pretty; }
.quote-lead p { font-size: clamp(1.5rem, 2.9vw, 2.6rem); font-weight: 750; font-stretch: 112%; line-height: 1.08; letter-spacing: -0.02em; }
.quote footer { font-size: 0.9375rem; font-weight: 600; }
.span-7 { grid-column: span 7; }
.span-5 { grid-column: span 5; }
.span-4 { grid-column: span 4; }
.score { display: flex; flex-direction: column; justify-content: space-between; gap: 1.5rem; }
.score-num { font-size: clamp(3.5rem, 7vw, 6.5rem); font-weight: 900; font-stretch: 125%; line-height: 0.85; letter-spacing: -0.04em; }

/* ---------- functions ---------- */

.functions { display: grid; grid-template-columns: 5fr 7fr; gap: clamp(2rem, 5vw, 5rem); align-items: center; }
.dark .photo { border-color: #fff; }

/* ---------- book + visit ---------- */

.visit { display: grid; grid-template-columns: 7fr 5fr; gap: clamp(2.5rem, 6vw, 6rem); align-items: start; }
.form { display: grid; grid-template-columns: 1fr 1fr; gap: 1.1rem 1rem; margin-top: 2rem; }
.field { display: flex; flex-direction: column; gap: 0.35rem; }
.field-wide { grid-column: 1 / -1; }
.field label { font-weight: 650; }
.field small { font-size: 0.875rem; }
.field input, .field select, .field textarea {
  width: 100%; min-height: 3.25rem; padding: 0.6rem 0.8rem;
  border: 3px solid var(--char); border-radius: 0; background: var(--flour);
  font: inherit; color: inherit;
}
.field textarea { min-height: 6rem; resize: vertical; }
.form-result { grid-column: 1 / -1; padding: 1.1rem 1.25rem; background: var(--grana); border: 3px solid var(--char); font-weight: 600; }
.form-result:empty { display: none; }
.form-result small { display: block; margin-top: 0.3rem; font-weight: 400; }

.info > * + * { margin-top: 2rem; }
.info h3 { font-size: 1.1875rem; font-weight: 750; font-stretch: 112%; margin-bottom: 0.5rem; }
.hours { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.hours th, .hours td { padding: 0.5rem 0; border-bottom: 1px solid var(--char); text-align: left; font-weight: 400; vertical-align: top; }
.hours td { text-align: right; }
.hours tr[aria-current] th, .hours tr[aria-current] td { font-weight: 750; }
.hours tr[aria-current] th::after { content: " (today)"; font-weight: 400; }
.map { border-block: var(--line) solid var(--char); }
.map iframe { width: 100%; height: clamp(18rem, 40vw, 28rem); border: 0; }

/* ---------- footer ---------- */

.foot { padding-block: clamp(3rem, 6vw, 5rem) 2rem; }
.foot-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 2rem; }
.foot .brand { font-size: clamp(1.75rem, 3vw, 2.5rem); margin-bottom: 1rem; }
.foot .mark { width: 2.25rem; height: 2.25rem; }
.foot h2 { font-size: 1rem; font-weight: 750; font-stretch: 112%; margin-bottom: 0.6rem; }
.foot li + li { margin-top: 0.3rem; }
.foot-grid > div { min-width: 0; }
.foot a { text-decoration: none; overflow-wrap: anywhere; }
.foot a:hover { text-decoration: underline; }
.foot-note { margin-top: 3rem; padding-top: 1.25rem; border-top: 1px solid #fff; font-size: 0.875rem; }

/* ---------- mobile action bar ---------- */

.bar { display: none; }

/* ---------- menu page ---------- */

.menu-head { padding-block: clamp(2.5rem, 6vw, 5rem) clamp(1.5rem, 3vw, 2.5rem); }
.cats {
  position: sticky; top: 4.25rem; z-index: 10; /* its top rule tucks under the header rule */
  display: flex; gap: var(--line); overflow-x: auto; scrollbar-width: none;
  overscroll-behavior-x: contain; scroll-behavior: smooth;
  background: var(--char); border-block: var(--line) solid var(--char);
}
.cats a { flex: 1 0 auto; padding: 0.7rem 1.1rem; background: var(--flour); font-weight: 600; text-align: center; text-decoration: none; white-space: nowrap; }
@media (hover: hover) { .cats a:hover { background: var(--grana); } }
.cats a[aria-current] { background: var(--char); color: #fff; }
.menu-sec { display: grid; grid-template-columns: 3fr 9fr; gap: 2rem clamp(2rem, 4vw, 4rem); padding-block: clamp(2.5rem, 5vw, 4.5rem); border-bottom: var(--line) solid var(--char); scroll-margin-top: 2rem; /* on top of html's scroll-padding */ }
.menu-sec-head { position: sticky; top: 9rem; align-self: start; }
.menu-sec-head p { margin-top: 0.9rem; font-size: 0.9375rem; max-width: 22em; }
.menu-sec .h2 { font-size: clamp(1.75rem, 3vw, 2.75rem); }
.items { display: grid; grid-template-columns: 1fr 1fr; gap: 1.75rem clamp(1.5rem, 4vw, 4rem); align-content: start; }
.item { display: grid; grid-template-columns: 5.25rem 1fr auto; gap: 0 1rem; align-items: start; }
.items-plain .item { grid-template-columns: 1fr auto; }
.item-name { font-size: 1.125rem; font-weight: 750; font-stretch: 110%; line-height: 1.2; letter-spacing: -0.01em; }
.item-text { grid-column: 2; }
.items-plain .item-text { grid-column: 1; }
.item-desc { margin-top: 0.25rem; font-size: 0.9375rem; line-height: 1.4; }
.tag { display: inline-block; margin-left: 0.4rem; padding: 0.05rem 0.45rem; background: var(--grana); font-size: 0.75rem; font-weight: 650; font-stretch: 100%; letter-spacing: 0; vertical-align: 0.15em; white-space: nowrap; }
.subhead { grid-column: 1 / -1; padding-top: 0.5rem; font-size: 1.3125rem; font-weight: 800; font-stretch: 118%; }
.subhead:not(:first-child) { margin-top: 1rem; }
.fineprint { font-size: 0.9375rem; max-width: 46em; }

/* ---------- one orchestrated moment: the facade assembles, the pizza lands ---------- */

@media (prefers-reduced-motion: no-preference) {
  .hero .cell { animation: panel 0.7s cubic-bezier(0.2, 0.7, 0.1, 1) backwards; animation-delay: calc(var(--i) * 90ms); }
  .pizza { animation: land 0.9s cubic-bezier(0.2, 0.9, 0.2, 1) 0.45s backwards; }
  @supports (animation-timeline: scroll()) {
    .pizza img { animation: spin linear both; animation-timeline: scroll(); animation-range: 0 110vh; }
  }
}
@keyframes panel { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 -60% 0 -60%); } }
@keyframes land { from { opacity: 0; scale: 0.55; rotate: -50deg; } }
@keyframes spin { to { rotate: 75deg; } }
@media (prefers-reduced-motion: reduce) { html, .cats { scroll-behavior: auto; } }

/* ---------- small screens ---------- */

@media (max-width: 76rem) {
  .top .btn-alt { display: none; }
}

@media (max-width: 62rem) {
  html { scroll-padding-bottom: calc(4.5rem + env(safe-area-inset-bottom)); } /* nothing scrolls to rest under the bar */
  body { padding-bottom: calc(3.5rem + env(safe-area-inset-bottom)); }
  .nav { display: none; }
  .bar {
    position: fixed; inset: auto 0 0 0; z-index: 30;
    display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--line);
    background: var(--char); border-top: var(--line) solid var(--char);
  }
  .bar a { display: grid; place-items: center; min-height: calc(3.25rem + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom); background: var(--flour); font-weight: 700; font-stretch: 112%; text-decoration: none; }
  .bar a:nth-child(2) { background: var(--grana); }
  .bar a:nth-child(3) { background: var(--pomodoro); color: #fff; }
  .dishes { grid-template-columns: repeat(2, 1fr); }
  .kitchen, .story, .functions, .visit { grid-template-columns: 1fr; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .menu-sec { grid-template-columns: 1fr; }
  .menu-sec-head { position: static; }
  .span-7, .span-5, .span-4 { grid-column: span 12; }
}

@media (max-width: 52rem) {
  :root { --line: 3px; }
  .top-in { gap: 0.75rem; }
  .top .brand { font-size: clamp(1rem, 5vw, 1.3rem); }
  .top .btn { padding-inline: 0.9rem; }
  .hero {
    grid-template-columns: 1fr 1fr;
    grid-template-areas: "head head" "pizza pizza" "num open" "cta cta" "rate rate";
  }
  .hero-head { padding-right: var(--pad); padding-bottom: 5.5rem; }
  .hero-pizza-cell { height: 62vw; }
  .pizza { left: 50%; top: 38%; width: 82cqw; translate: -50% -50%; }
  .specials, .lunch { grid-template-columns: 1fr; }
  .special .plate { width: 52%; }
  .items { grid-template-columns: 1fr; }
  .form { grid-template-columns: 1fr; }
}

@media (max-width: 22rem) {
  .top .btn { display: none; } /* no room; Book is in the bar */
  .dish-row { flex-wrap: wrap; } /* price drops under a long dish name instead of pushing the page wide */
}

/* phones on their side: the header scrolls away so sticky chrome doesn't eat the screen */
@media (max-height: 30rem) {
  html { scroll-padding-top: 0; }
  .top { position: static; }
  .cats { top: 0; }
  .menu-sec { scroll-margin-top: 3.25rem; }
}

/* fingers: standalone text links get a 44px-tall hit area without moving the text */
@media (pointer: coarse) {
  .textlink, .info a, .field small a, .foot li a { display: inline-block; padding-block: 0.6rem; margin-block: -0.6rem; }
  .foot li a { margin-block: 0; }
  .foot li + li { margin-top: 0; }
}
