/* Homeboy Pizza Co. one page site
   Layout is a fixed sign header, a full-bleed washed-out map, an order
   card that slides in from the right, and a menu sheet that rests at three heights. */

:root {
  --red: #D42A22;
  --red-dark: #9c1a14;
  --ink: #1b1714;
  --cream: #FBF7EE;
  --display: 'Fraunces', Georgia, 'Times New Roman', serif;
  --text: 'DM Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  /* Measured from the live header by site.js; the map padding, the sheet height and
     the card height all derive from it. */
  --hdr: 118px;
  --tabs: 92px;
  /* A strip of map left showing above the sheet when it is fully open. The map
     credit lives under Licences at the foot of the menu, so this is only air. */
  --credit: 20px;
  --sheet-rest: 50vh;
  /* The order card's padding is a token so the short-viewport and narrow-screen
     queries can each set it without one silently overriding the other. */
  --face-pad-y: 34px;
  --face-pad-x: 32px;
  --face-pad-b: 30px;
  --big-size: 64px;
  /* One measure for every pane, so nothing jumps width between tabs. */
  --content: 1120px;
  --ease-sheet: cubic-bezier(.2, .9, .25, 1);
  --ease-panel: cubic-bezier(.2, .9, .25, 1.05);
  --ease-flip: cubic-bezier(.3, .8, .3, 1);
}

@supports (height: 100dvh) {
  :root { --sheet-rest: 50dvh; }
}

* { box-sizing: border-box }

html, body {
  margin: 0;
  height: 100%;
  overscroll-behavior: none;
  background: #fff;
  color: var(--ink);
  font-family: var(--text);
}

html, body { overflow: hidden }

a { color: var(--red) }

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}

:focus-visible {
  outline: 2px solid rgba(212, 42, 34, .55);
  outline-offset: 3px;
}
/* On red ground a red ring disappears, so it goes white. */
.face :focus-visible,
.cl :focus-visible,
.red :focus-visible,
.merch :focus-visible {
  outline-color: rgba(255, 255, 255, .8);
}
/* Rings are for the keyboard. site.js adds .mouse on a click or tap and takes it off
   again on Tab, so a clicked select or button never picks one up. */
.mouse :focus-visible { outline: none }

.vh {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip {
  position: fixed;
  z-index: 100;
  top: 8px;
  left: 50%;
  transform: translate(-50%, -200%);
  background: var(--ink);
  color: #fff;
  padding: 12px 20px;
  border-radius: 999px;
  font: 700 14px/1 var(--text);
  text-decoration: none;
}
.skip:focus { transform: translate(-50%, 0); color: #fff }

/* Fraunces at its softest end, which sits beside the rounded wordmark. */
.pin .tag, .face h2, .face .big, .board h2, .red h3, .row .n, .row .p,
.tabs button.t, .tabs .meta, .prod .l {
  font-family: var(--display);
  font-variation-settings: 'SOFT' 100;
}

/* ---------- map ---------- */

/* MapLibre draws the map and the pins; cream shows until the first tiles land. */
#map {
  position: fixed;
  inset: 0;
  z-index: 0;
  background: var(--cream);
  font: inherit;
}
#map canvas:focus { outline: none }
/* Just enough credit on the map itself to meet the providers' terms. */
.map-credit {
  position: absolute;
  z-index: 2;
  top: calc(var(--hdr) + 6px);
  left: 10px;
  margin: 0;
  font-size: 10px;
  line-height: 1.3;
  color: rgba(27, 23, 20, .55);
}
.map-credit a { color: inherit; text-decoration: none }

/* ---------- your location ---------- */

.me {
  position: relative;
  display: block;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #2C7BE5;
  border: 3px solid #fff;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, .25), 0 2px 6px rgba(0, 0, 0, .2);
  pointer-events: none;
}
.me::after {
  content: '';
  position: absolute;
  inset: -9px;
  border-radius: 50%;
  background: rgba(44, 123, 229, .22);
  animation: hb-pulse 2.4s ease-out infinite;
}
@keyframes hb-pulse {
  0% { transform: scale(.5); opacity: .9 }
  100% { transform: scale(1.6); opacity: 0 }
}

/* Flies the map back to you. Rides just above the menu sheet's top edge on the
   left, clear of the credit and of the order card, and follows the sheet up and
   down. */
.locate {
  position: fixed;
  z-index: 30;
  left: 16px;
  bottom: calc(var(--sheet-rest) + 14px);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .18);
  display: grid;
  place-items: center;
  transition: bottom .55s var(--ease-sheet), opacity .2s ease;
}
body.low .locate { bottom: calc(var(--tabs) + env(safe-area-inset-bottom, 0px) + 14px) }
body.full .locate, body.dragging .locate { opacity: 0; pointer-events: none }
.locate[hidden] { display: none }
.locate-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #2C7BE5;
  border: 3px solid #fff;
  box-shadow: 0 0 0 2px #2C7BE5;
}

.map-fallback {
  position: fixed;
  z-index: 2;
  left: 50%;
  top: calc(var(--hdr) + 40px);
  transform: translateX(-50%);
  width: min(420px, calc(100% - 32px));
  background: #fff;
  border: 6px solid var(--red);
  border-radius: 26px;
  padding: 22px 24px;
  text-align: center;
}
.map-fallback p { margin: 0 0 10px; font-size: 15px }
.map-fallback ul { margin: 0; padding: 0; list-style: none; font-size: 15px; line-height: 1.6 }

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

header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  background: #fff;
  border-bottom: 6px solid var(--red);
  padding: calc(20px + env(safe-area-inset-top, 0px))
           calc(24px + env(safe-area-inset-right, 0px))
           16px
           calc(24px + env(safe-area-inset-left, 0px));
  text-align: center;
}
.wordmark {
  margin: 0 auto;
  /* The mark is 1113x126, so height follows width. Clamped so it never dwarfs a
     phone or floats on a wide desktop. */
  width: clamp(210px, 34vw, 360px);
  color: var(--red);
}
.wordmark img { display: block; width: 100%; height: auto }
header .sub {
  margin: 10px 0 0;
  font-size: 13px;
  line-height: 1.3;
  color: rgba(27, 23, 20, .78);
}

/* ---------- map pins ---------- */

/* The button box runs down to the tip of the tail, so MapLibre's bottom anchor puts
   the tip on the shop. */
.pin-btn {
  display: block;
  padding: 0 0 12px;
  cursor: pointer;
}
.pin {
  position: relative;
  display: block;
  width: max-content;
}
.pin .tag {
  display: block;
  background: var(--red);
  color: #fff;
  padding: 9px 14px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 15px;
  white-space: nowrap;
  /* White ring inside, red ring outside, for the sticker look of the shop signage. */
  border: 3px solid #fff;
  box-shadow: 0 0 0 2px var(--red);
}
.pin .tail {
  display: block;
  position: absolute;
  left: 50%;
  bottom: -9px;
  width: 14px;
  height: 14px;
  background: var(--red);
  transform: translateX(-50%) rotate(45deg);
  z-index: -1;
}
.pin.on .tag,
.pin.on .tail { background: var(--ink) }
.pin.on .tag { box-shadow: 0 0 0 2px var(--ink) }
.pin-btn:focus-visible { outline: none }
.pin-btn:focus-visible .tag { box-shadow: 0 0 0 2px var(--red), 0 0 0 5px rgba(212, 42, 34, .35) }
.mouse .pin-btn:focus-visible .tag { box-shadow: 0 0 0 2px var(--red) }
.mouse .pin.on .tag { box-shadow: 0 0 0 2px var(--ink) }

/* ---------- order card ----------
   White on the brand red is 5.06:1, only just over AA. There is no room to soften
   text with opacity here, so hierarchy comes from size and weight instead. */

#panel {
  position: fixed;
  z-index: 45;
  right: 36px;
  top: calc(var(--hdr) + 28px);
  width: 420px;
  perspective: 1600px;
  pointer-events: none;
  transform: translateX(120%);
  transition: transform .7s var(--ease-panel);
}
#panel.open {
  transform: none;
  pointer-events: auto;
}

.card {
  position: relative;
  transform-style: preserve-3d;
  transition: transform .8s var(--ease-flip);
  height: min(660px, calc(100vh - var(--hdr) - var(--tabs) - 40px));
}
@supports (height: 100dvh) {
  .card { height: min(660px, calc(100dvh - var(--hdr) - var(--tabs) - 40px)) }
}
.card.flip { transform: rotateY(180deg) }

.face {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  background: var(--red);
  color: #fff;
  border-radius: 32px;
  padding: var(--face-pad-y) var(--face-pad-x) calc(var(--face-pad-b) + env(safe-area-inset-bottom, 0px));
  display: flex;
  flex-direction: column;
  overflow: auto;
  overscroll-behavior: contain;
}
.face.back { transform: rotateY(180deg) }
.face .kicker {
  font-size: 16px;
  line-height: 1.3;
  margin: 0;
}
.face h2 {
  font-weight: 700;
  font-size: 40px;
  line-height: 1.05;
  letter-spacing: -.01em;
  margin: 8px 0 14px;
}
.face p { margin: 0; font-size: 15px; line-height: 1.5 }
/* Address, hours and contact are three separate blocks, not one run-on paragraph. */
.face .addr { font-size: 16px; line-height: 1.5; margin-top: 14px }
.face .addr + .addr { margin-top: 10px; opacity: .95 }
.face .pick { margin-bottom: 16px }
.face .grow { flex: 1 }
.face .spacer { height: 26px }
.face a { color: inherit }

/* The argument scrolls if it has to; the buttons under it never move out of reach,
   whatever the viewport leaves between the header and the dropped menu sheet. */
#backDelivery {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
#backDelivery .prose {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
}
#backDelivery .choice { flex: none }
/* Smaller than the front face's display type: this side has to carry an argument and
   three controls in the same box. */
#backDelivery .big { font-size: min(52px, 24cqi) }
/* If the argument does overflow on a short screen, the fade says so rather than
   letting a sentence stop mid-word. site.js adds .overflows only when it does, so
   text that fits is never faded. */
#backDelivery .prose.overflows {
  -webkit-mask-image: linear-gradient(#000 calc(100% - 24px), transparent);
  mask-image: linear-gradient(#000 calc(100% - 24px), transparent);
}
#backDelivery .prose:not(:hover):not(:focus-visible) { scrollbar-width: none }

.choice { display: flex; flex-direction: column; gap: 10px }
/* Two lesser choices share a line so the card does not outgrow the space between the
   header and the dropped menu sheet. */
.choice-row { display: flex; flex-wrap: wrap; gap: 10px }
.choice-row .btn { flex: 1 1 0; justify-content: center; text-align: center; padding: 18px 14px }
.choice-row .todo-note { flex: 1 0 100% }

.btn {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 18px 22px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 16px;
  text-decoration: none;
  text-align: left;
}
.btn.w { background: #fff; color: var(--red) }
.btn.o { border: 2px solid rgba(255, 255, 255, .8); color: #fff }
.btn.k { background: var(--ink); color: #fff }

/* A call to action whose URL is still missing from the config. Visible, obviously
   not clickable, and impossible to ship by accident. */
.btn.is-todo {
  opacity: .55;
  cursor: not-allowed;
}
/* The white button stays white: faded, it read as a pink slab on the red card. */
.btn.w.is-todo {
  opacity: 1;
  color: rgba(212, 42, 34, .6);
}
.face .todo-note {
  margin: -2px 0 0;
  font-size: 13px;
  text-align: center;
}

.x {
  position: absolute;
  top: 18px;
  right: 22px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(0, 0, 0, .18);
  color: #fff;
  font: 700 20px/1 var(--text);
  display: flex;
  align-items: center;
  justify-content: center;
}

.face .big {
  font-weight: 700;
  letter-spacing: -.015em;
  font-size: var(--big-size);
  line-height: .9;
  margin: 6px 0 10px;
}
/* "Delivery." at 96px is 334px wide inside a 336px card, so it clips the moment the
   card is any narrower. Size it against the card instead of the viewport. */
@supports (container-type: inline-size) {
  .face { container-type: inline-size }
  .face .big { font-size: min(var(--big-size), 28.7cqi) }
}

/* Swapping sides while the card is already flipped cannot re-use the flip, so the
   incoming copy fades in rather than cutting. */
@keyframes hb-swap {
  from { opacity: 0; transform: translateY(6px) }
  to { opacity: 1; transform: none }
}
.face.back .swap-in { animation: hb-swap .22s ease-out }

/* ---------- menu sheet ---------- */

#sheet {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 40;
  height: calc(100vh - var(--hdr) - var(--credit));
  background: var(--cream);
  border-radius: 34px 34px 0 0;
  display: flex;
  flex-direction: column;
  transform: translateY(calc(100% - var(--sheet-rest)));
  transition: transform .55s var(--ease-sheet);
}
@supports (height: 100dvh) {
  #sheet { height: calc(100dvh - var(--hdr) - var(--credit)) }
}
body.full #sheet { transform: none }
body.low #sheet { transform: translateY(calc(100% - var(--tabs) - env(safe-area-inset-bottom, 0px))) }

#sheet .grab {
  flex: none;
  padding: 2px 16px 0;
  cursor: grab;
  touch-action: none;
}
#sheet .grab .bar {
  display: grid;
  place-items: center;
  margin: 0 auto;
  padding: 8px 24px;
  min-height: 22px;
  cursor: inherit;
}
#sheet .grab .grab-line {
  width: 56px;
  height: 6px;
  border-radius: 3px;
  background: var(--red);
  transition: background-color .2s ease;
}
#sheet .grab:active,
body.dragging #sheet .grab { cursor: grabbing }

.tabs {
  flex: none;
  display: flex;
  gap: 8px;
  /* Same measure as the boards below, padding included, so the pills start on the
     same line as the menu. */
  width: 100%;
  max-width: calc(var(--content) + 48px);
  margin-inline: auto;
  padding: 12px calc(24px + env(safe-area-inset-right, 0px)) 16px calc(24px + env(safe-area-inset-left, 0px));
  align-items: center;
}
.tabs .scroll {
  display: flex;
  flex: 1 1 auto;
  min-width: 0;
  gap: 8px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
  /* Room for the focus ring, which would otherwise be clipped by the scroller. */
  padding: 4px 0;
  margin: -4px 0;
}
.tabs .scroll::-webkit-scrollbar { display: none }
.tabs button.t {
  padding: 11px 20px;
  line-height: 20px;
  border-radius: 999px;
  border: 2px solid var(--red);
  color: var(--red);
  font-weight: 700;
  font-size: 15px;
  white-space: nowrap;
}
.tabs button.t.on { background: var(--red); color: #fff }
.tabs .meta {
  margin: 0 0 0 auto;
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 15px;
  white-space: nowrap;
}
/* Same 2px border as the picker beside it, so the two pills are the same height. */
.tabs .meta .order {
  padding: 11px 20px;
  line-height: 20px;
  border: 2px solid var(--red);
  border-radius: 999px;
  background: var(--red);
  color: #fff;
}

/* The shop picker wears the same pill as the tabs, so the row reads as one control
   set rather than a form field parked next to some buttons. */
.picker { position: relative; display: inline-flex; align-items: center }
.pick-select {
  appearance: none;
  font: inherit;
  font-weight: 700;
  color: var(--red);
  background: transparent;
  border: 2px solid var(--red);
  border-radius: 999px;
  padding: 11px 38px 11px 20px;
  line-height: 20px;
  height: auto;
  cursor: pointer;
  max-width: 46vw;
  text-overflow: ellipsis;
}
/* The chevron is drawn on the wrapper so the native one can go without losing it. */
.picker::after {
  content: '';
  position: absolute;
  right: 17px;
  width: 9px;
  height: 9px;
  border-right: 2px solid var(--red);
  border-bottom: 2px solid var(--red);
  transform: translateY(-3px) rotate(45deg);
  pointer-events: none;
}
.body {
  flex: 1;
  overflow: auto;
  padding: 8px calc(24px + env(safe-area-inset-right, 0px)) 60px calc(24px + env(safe-area-inset-left, 0px));
  padding-bottom: calc(60px + env(safe-area-inset-bottom, 0px));
  overscroll-behavior: contain;
}
.pane { display: none }
.pane.on { display: block }
/* Keeps the price next to the dish on a very wide monitor. */
.pane, .menu-foot { max-width: var(--content); margin-inline: auto }
.pane:focus { outline: none }

/* ---------- menu boards ---------- */

.board + .board,
.board + .merch,
.merch + .board { margin-top: 22px }

.board {
  background: #fff;
  border: 8px solid var(--red);
  border-radius: 34px;
  overflow: hidden;
  display: grid;
  grid-template-columns: 1fr 1fr;
}
.board.one { grid-template-columns: 1fr }
.board > div { padding: 34px 38px 30px }
.board .cl { background: var(--red); color: #fff }
.board h2 {
  font-weight: 800;
  font-size: 40px;
  line-height: 1.05;
  letter-spacing: -.01em;
  margin: 0 0 16px;
  color: var(--red);
}
.board h2.mt { margin-top: 30px }
.board .cl h2 { color: #fff }
.board h2 small {
  font-family: var(--text);
  font-weight: 500;
  font-size: 16px;
  letter-spacing: 0;
  color: rgba(27, 23, 20, .78);
  vertical-align: baseline;
  margin-left: 12px;
}
.board .cl h2 small { color: #fff }

.rows { list-style: none; margin: 0; padding: 0 }
.row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px solid rgba(0, 0, 0, .12);
}
.cl .row { border-color: rgba(255, 255, 255, .3) }
.row .rt { display: block }
.row .n { font-size: 17px; line-height: 1.2; font-weight: 700; display: block }
.row .d {
  font-size: 13px;
  line-height: 1.4;
  color: rgba(27, 23, 20, .72);
  display: block;
  margin-top: 3px;
}
.cl .row .d { color: #fff }
.row .p { font-weight: 700; font-size: 17px; white-space: nowrap }

.note {
  margin: 18px 0 0;
  font-size: 15px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.rows.two { display: grid; grid-template-columns: 1fr 1fr; gap: 0 40px }

/* ---------- catering ---------- */

.red {
  background: var(--red);
  color: #fff;
  border-radius: 34px;
  padding: 40px 44px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: start;
}
.red h3 {
  font-weight: 400;
  font-size: 64px;
  line-height: .95;
  margin: 0 0 16px;
}
.red p {
  margin: 0 0 14px;
  font-size: 17px;
  line-height: 1.5;
  max-width: 460px;
  text-wrap: pretty;
}

.form { display: grid; grid-template-columns: 1fr 1fr; gap: 12px }
.form .f { margin: 0 }
.form .f.wide { grid-column: 1 / -1 }
.form input,
.form textarea {
  width: 100%;
  padding: 16px 18px;
  border-radius: 20px;
  border: 0;
  background: #fff;
  color: var(--ink);
  font: 15px var(--text);
}
.form textarea { height: 110px; resize: none; display: block }
.form input::placeholder,
.form textarea::placeholder { color: rgba(27, 23, 20, .62); opacity: 1 }
.form input:user-invalid,
.form textarea:user-invalid { box-shadow: 0 0 0 3px var(--ink) }
.form .btn { grid-column: 1 / -1; justify-content: center }
.form .formmsg {
  grid-column: 1 / -1;
  margin: 0;
  font-size: 15px;
  line-height: 1.4;
  min-height: 0;
}
.form .formmsg:empty { display: none }

/* ---------- merch ---------- */

.merch {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  background: var(--red);
  border-radius: 34px;
  padding: 24px;
  margin: 0;
  list-style: none;
}
.prod {
  background: #fff;
  color: var(--ink);
  border-radius: 26px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.prod .shot {
  width: 100%;
  height: 260px;
  display: block;
  border-radius: 18px;
  object-fit: cover;
  background: var(--cream);
}
.prod .shot.empty {
  display: grid;
  place-items: center;
  border: 2px dashed rgba(212, 42, 34, .45);
  color: rgba(27, 23, 20, .72);
  font-size: 15px;
  text-align: center;
  padding: 12px;
}
.prod .l {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-weight: 700;
  font-size: 16px;
  padding: 0 6px 4px;
}

/* A dish carried by both shops. Burley Road runs the long menu, so the exception
   worth marking is what Street Lane also has. */
.at-both {
  display: inline-block;
  vertical-align: 2px;
  margin-left: 8px;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--ink);
  color: #fff;
  font-style: normal;
  font-weight: 700;
  font-size: 11px;
  line-height: 1.5;
  white-space: nowrap;
}
.cl .at-both { background: #fff; color: var(--red) }
/* With scripting the menu follows the chosen shop, so the badges have nothing left
   to say. */
.menu-by-shop .at-both { display: none }
.pane [data-only][hidden] { display: none }

.lede {
  margin: 0 0 18px;
  font-size: 16px;
  line-height: 1.55;
  max-width: 56ch;
}
.face .mt { margin-top: 12px }

.face .contact { font-size: 15px; line-height: 1.55; margin-top: 10px }
.face .contact a { color: inherit; text-decoration: underline; text-underline-offset: 3px }

/* ---------- the line under the menu ---------- */

.menu-foot {
  margin: 30px auto 0;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.7;
  text-align: center;
  color: rgba(27, 23, 20, .82);
}

/* Two quiet links under the menu, each opening the small-print dialog. */
.small-links {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin: 30px auto 0;
}
.made-by {
  margin: 12px auto 0;
  text-align: center;
  font-size: 12px;
  color: rgba(27, 23, 20, .6);
}
.made-by a { color: inherit; font-weight: 600; text-underline-offset: 2px }
.small-links button {
  padding: 7px 14px;
  border-radius: 999px;
  border: 1.5px solid rgba(27, 23, 20, .22);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.2;
  color: rgba(27, 23, 20, .8);
}

/* ---------- small print dialog ---------- */

.info {
  width: min(460px, calc(100vw - 32px));
  max-height: calc(100dvh - 48px);
  padding: 30px 28px 26px;
  border: 6px solid var(--red);
  border-radius: 30px;
  background: var(--cream);
  color: var(--ink);
  overflow: auto;
  overscroll-behavior: contain;
}
.info::backdrop { background: rgba(27, 23, 20, .45) }
.info h2 {
  margin: 0 0 12px;
  padding-right: 44px;
  font-family: var(--display);
  font-variation-settings: 'SOFT' 100;
  font-weight: 800;
  font-size: 32px;
  line-height: 1.05;
  color: var(--red);
}
.info p { margin: 0 0 10px; font-size: 15px; line-height: 1.55 }
.info a { color: var(--red); text-underline-offset: 2px }
.info-phones { margin: 14px 0 0; padding: 0; list-style: none; font-size: 15px; line-height: 1.8 }
.info-phones a { font-weight: 700 }
.info-x {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(212, 42, 34, .12);
  color: var(--red);
  font: 700 20px/1 var(--text);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ---------- footer, only reachable without scripting ---------- */

.foot {
  padding: 28px 24px calc(28px + env(safe-area-inset-bottom, 0px));
  text-align: center;
  font-size: 14px;
  background: var(--cream);
  border-top: 6px solid var(--red);
}
.foot p { margin: 0 }
.foot { display: none }

.noscript {
  padding: 20px 24px;
  background: var(--cream);
  border-bottom: 6px solid var(--red);
  text-align: center;
  font-size: 15px;
}
.noscript p { margin: 0 }

/* ---------- narrow screens ---------- */

@media (max-width: 900px) {
  #panel {
    right: 0;
    left: 0;
    top: auto;
    bottom: 0;
    width: auto;
    transform: translateY(120%);
    /* Rises straight to its rest position. The desktop curve overshoots, which on a
       bottom sheet lifts it clear of the screen edge and shows a strip of page
       under it before it settles. */
    transition-timing-function: var(--ease-sheet);
  }
  .card {
    height: auto;
    /* Never taller than the space under the header, or a landscape phone clips the
       top of the card along with its close button. */
    min-height: min(600px, calc(100dvh - var(--hdr) - 20px));
    max-height: calc(100dvh - var(--hdr) - 10px);
    display: flex;
    flex-direction: column;
  }
  .face.front { flex: 1 }
  :root {
    --face-pad-y: 28px;
    --face-pad-x: 22px;
    --face-pad-b: 28px;
  }
  .face {
    position: relative;
    border-radius: 32px 32px 0 0;
  }
  .face.back { position: absolute; inset: 0 }
  .board, .red { grid-template-columns: 1fr; padding: 26px 22px }
  .rows.two { grid-template-columns: 1fr }
  .board > div { padding: 0 }
  /* The red column bleeds to whichever board edge it sits against. Pizzas puts it
     last, Drinks puts it first, and one shared rule cannot serve both. */
  .board .cl { padding: 26px 22px }
  .board .cl:last-child { margin: 22px -22px -26px }
  .board .cl:first-child { margin: -26px -22px 22px }
  .red h3 { font-size: 48px }
  .board h2 small { display: block; margin: 8px 0 0; line-height: 1.4 }
  .body { padding: 20px 16px 60px; padding-bottom: calc(60px + env(safe-area-inset-bottom, 0px)) }
  .tabs {
    flex-wrap: wrap;
    row-gap: 10px;
    padding-left: 16px;
    padding-right: 16px;
  }
  .tabs .meta { order: -1; width: 100%; margin: 0; gap: 8px }
  .tabs .scroll { flex: 1 1 100% }
  .picker { flex: 1 1 auto; min-width: 0 }
  .pick-select { width: 100%; max-width: none }
  /* The strip scrolls here; fade its edge so a clipped pill reads as more-to-come
     rather than as a button sliding under the Order pill. */
  .tabs .scroll {
    -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 22px), transparent);
    mask-image: linear-gradient(90deg, #000 calc(100% - 22px), transparent);
  }
  .form { grid-template-columns: 1fr }
  .form .f.wide { grid-column: auto }
  /* Under 16px, iOS zooms the page on focus and offers no way back out. */
  .form input, .form textarea { font-size: 16px }
}

/* Landscape phones match this and the narrow-screen query at once, so it comes last
   and wins on the declarations they share. */
@media (max-height: 680px) {
  :root {
    --face-pad-y: 24px;
    --face-pad-x: 24px;
    --face-pad-b: 22px;
    --big-size: 64px;
  }
  .face h2 { font-size: 34px }
  .face p { font-size: 14px }
  .btn { padding: 13px 18px; font-size: 12px }
}

/* On desktop the sheet is a panel over the map rather than a full-width drawer, so
   the map stays visible down both sides. */
@media (min-width: 901px) {
  /* Only as wide as the menu boards plus the body's gutter, so the red border sits
     close to the sheet's edge rather than floating in cream. */
  #sheet {
    width: min(calc(var(--content) + 48px), calc(100% - 80px));
    margin-inline: auto;
    border-radius: 34px 34px 0 0;
  }
}

/* Between the breakpoint and roughly a laptop the 400px card plus its 36px offset
   crowds the map, so pull it in. */
@media (min-width: 901px) and (max-width: 1100px) {
  #panel { right: 20px; width: 360px }
}

/* ---------- hover, only where a pointer can actually hover ----------
   Unguarded :hover leaves a tapped button stuck in its hover state on a phone. */

@media (hover: hover) and (pointer: fine) {
  a:hover { color: var(--red-dark) }
  .btn.w:hover { background: var(--cream); color: var(--red) }
  .btn.o:hover { border-color: #fff }
  .btn.k:hover { background: #000 }
  .x:hover { background: rgba(0, 0, 0, .3) }
  .tabs .meta .order:hover { background: var(--red-dark) }
  .small-links button:hover { border-color: var(--red); color: var(--red) }
  .made-by a:hover { color: var(--red) }
  .info-x:hover { background: rgba(212, 42, 34, .22) }
  .locate:hover { box-shadow: 0 2px 14px rgba(0, 0, 0, .28) }
  #sheet .grab:hover .grab-line { background: var(--red-dark) }
}

/* ---------- reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  #panel, .card, #sheet { transition-duration: .01ms }
  .face.back .swap-in { animation: none }
  .me::after { animation: none }
  html { scroll-behavior: auto }
}

/* ---------- print: just the menu ---------- */

@media print {
  html, body { overflow: visible; height: auto; background: #fff }
  #map, #panel, .tabs, #sheet .grab, .skip, .map-fallback, .locate, .small-links { display: none !important }
  header { position: static }
  #sheet { position: static; height: auto; transform: none; background: #fff }
  .body { overflow: visible; padding: 0 }
  .pane, .pane[hidden] { display: block !important; break-inside: avoid; margin-bottom: 18px }
  .board { border-color: #000 }
  .foot { display: block }
}
