/* Nami Café sample site: shared styles.

   Phone first. Two breakpoints, chosen from the drawn widths
   (390 phone, 820 tablet, 1440 laptop):
     tablet: 744px and wider (iPad mini upright and up)
     laptop: 1024px and wider (tablets held sideways get it too)
   Media queries cannot read custom properties, so the two widths
   are written out in each @media rule below.

   Above 1440px the 1440 layout stays centred in a "frame"; full-width
   bands (banner, footer) still run edge to edge.
   Sizes that differ between the drawn widths are interpolated
   between them, so the layout changes smoothly. In the laptop layout,
   sizes that would crowd a narrow laptop keep their share of the drawn
   1440 width (drawn px / 1440 = vw) and stop at the drawn size. */


/* Fonts: stored locally in ../fonts, licences beside them. */

@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("../fonts/cormorant-garamond-500.woff2") format("woff2");
}

@font-face {
  font-family: "Jost";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/jost-400.woff2") format("woff2");
}

@font-face {
  font-family: "Jost";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("../fonts/jost-500.woff2") format("woff2");
}


/* Design tokens. Phone values first; the breakpoints below override them. */

:root {
  /* Colours */
  /* Palette "Ro": warm cream, brown-black ink, moss-green accent. */
  --colour-paper: #F3EFE7;
  --colour-ink: #24221E;
  --colour-muted: #5E594F;
  --colour-accent: #44513F;
  --colour-on-accent: #FFFFFF;
  /* Footer band: the palette's light card colour. */
  --colour-band: #E8E1D4;
  --colour-rule: rgba(36, 34, 30, 0.16);
  --colour-rule-light: rgba(36, 34, 30, 0.14);
  --colour-button-hover: #24221E;

  /* Photo slots: each slot's base colour, shown until its photo loads */
  --colour-photo-hero: #AC9A8A;
  --colour-photo-shared-table: #452A1B;
  --colour-photo-extra: #9E5D3C;
  --colour-photo-menu-1: #766F66;
  --colour-photo-menu-2: #6C654C;

  /* Type */
  --font-serif: "Cormorant Garamond", Georgia, serif;
  --font-sans: "Jost", "Helvetica Neue", Arial, sans-serif;
  --leading-body: 1.6;
  --text-body: 15px;
  --text-banner: 12px;
  --text-logo: 26px;
  --text-nav: 14px;
  --text-footer-logo: 24px;
  --tracking-banner: 0.04em;
  --tracking-logo: 0.02em;
  --underline-offset: 5px;
  --underline-thickness: 1px;
  --text-section-title: 34px;
  --leading-section-title: 1.1;
  --text-button: 15px;
  --tracking-button: 0.04em;
  --text-link: 14px;

  /* Frame: the widest drawn layout, centred above that width.
     --frame-inset is the empty space on each side of the frame; use it
     only on elements that span the full page width (its 100% is the
     width of the containing block). */
  --frame-max: 1440px;
  --frame-inset: max(0px, (100% - var(--frame-max)) / 2);

  /* Spacing: pages sit on a wider left gutter than right */
  --gutter-left: 48px;
  --gutter-right: 24px;
  --section-pad-y: 56px;
  /* Home page below the hero: the gap above each block, and between
     the pieces inside one. */
  --home-gap: 40px;
  --home-stack: 24px;
  --nav-gap: 20px;
  --logo-gap: 10px;
  /* Footer: one row, as tall as the header at every width: the 44px
     icon row centred in the header's height (68, 76, 88px). */
  --footer-pad-y: calc((var(--header-height) - var(--touch-target)) / 2);
  /* Between the 44px tap areas; the circles inside them sit 8px
     further apart (12px and 16px). */
  --footer-icon-gap: 4px;

  /* Sizes */
  --touch-target: 44px;
  --button-height: 52px;
  --banner-height: 32px;
  --header-height: 68px;
  --wave-width: 30px;
  --wave-height: 10px;
  --wave-stroke: 1.2;
}

@media (min-width: 744px) {
  :root {
    --column-gap: 40px;
    --text-body: 16px;
    --text-logo: 28px;
    --text-nav: 15px;
    --text-footer-logo: 26px;

    --gutter-left: 64px;
    --gutter-right: 40px;
    --nav-gap: 32px;
    --footer-icon-gap: 8px;
    --text-section-title: 40px;
    --section-pad-y: 80px;
    --home-gap: 56px;
    --home-stack: 32px;

    --header-height: 76px;
    --wave-width: 32px;
    --wave-height: 11px;
    --wave-stroke: 1.15;
  }
}

@media (min-width: 1024px) {
  :root {
    --text-logo: 30px;
    --text-footer-logo: 28px;
    --underline-offset: 6px;

    --gutter-left: 96px;
    --gutter-right: 80px;
    --nav-gap: 40px;
    --logo-gap: 12px;
    --text-section-title: 48px;
    --text-button: 16px;
    --text-link: 15px;
    --section-pad-y: 120px;
    --home-gap: 80px;
    --home-stack: 36px;
    /* Gap between the two columns: 96px at 1440, scaled down below. */
    --column-gap: min(6.6667vw, 96px);

    --header-height: 88px;
    --button-height: 56px;
    --wave-width: 36px;
    --wave-height: 12px;
    --wave-stroke: 1.1;
  }
}


/* Base */

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--colour-paper);
  color: var(--colour-ink);
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: var(--text-body);
  line-height: var(--leading-body);
}

main {
  flex: 1 0 auto;
}

a {
  color: inherit;
}

a:hover {
  color: var(--colour-accent);
}

:focus-visible {
  outline: 2px solid var(--colour-accent);
  outline-offset: 2px;
}

.plain-list {
  margin: 0;
  padding: 0;
  list-style: none;
}


/* Banner: two full-width bands, dark then sand. Text wraps on narrow
   screens; the vertical padding keeps wrapped lines off the edges
   without changing the one-line height. */

.banner {
  margin: 0;
  min-height: var(--banner-height);
  padding: 6px var(--gutter-right);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: var(--colour-ink);
  color: var(--colour-paper);
  font-size: var(--text-banner);
  letter-spacing: var(--tracking-banner);
}

.banner-sand {
  background: var(--colour-band);
  color: var(--colour-ink);
}

.banner-sand a {
  color: var(--colour-ink);
  font-weight: 400;
  text-decoration: underline;
  text-decoration-thickness: var(--underline-thickness);
  text-underline-offset: 3px;
}


/* Logo: the wave mark and the name */

.logo {
  display: flex;
  align-items: center;
  gap: var(--logo-gap);
}

.logo-wave {
  flex-shrink: 0;
  width: var(--wave-width);
  height: var(--wave-height);
}

.logo-wave path {
  stroke: currentColor;
  stroke-width: var(--wave-stroke);
}

.logo-name {
  font-family: var(--font-serif);
  font-weight: 500;
  line-height: 1;
}


/* Header */

/* The page colour, so the header, the side text and the hero sit on
   one surface. It runs edge to edge; its content lines up with the
   frame. */
.site-header {
  flex-shrink: 0;
  width: 100%;
  height: var(--header-height);
  padding:
    0
    calc(var(--frame-inset) + var(--gutter-right))
    0
    calc(var(--frame-inset) + var(--gutter-left));
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.site-header .logo {
  min-height: var(--touch-target);
  color: var(--colour-ink);
  text-decoration: none;
}

.site-header .logo-name {
  font-size: var(--text-logo);
  letter-spacing: var(--tracking-logo);
}

.site-nav ul {
  display: flex;
  align-items: center;
  gap: var(--nav-gap);
  font-size: var(--text-nav);
}

.site-nav a {
  display: flex;
  align-items: center;
  min-height: var(--touch-target);
  text-decoration: none;
}

.site-nav a[aria-current="page"] {
  color: var(--colour-muted);
}

/* Laptop: "Book a table" is a small outlined button, so a booking
   action is always on the first screen. 44px tall, the touch size. */
@media (min-width: 744px) {
  .site-nav .nav-book {
    padding: 0 20px;
    border: 1px solid currentColor;
  }
}

/* Visit shows from tablet up */
.site-nav .nav-visit {
  display: none;
}

@media (min-width: 744px) {
  .site-nav .nav-visit {
    display: list-item;
  }
}


/* Frame */

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


/* Shared pieces: section titles, buttons, text links, photo slots */

.section-title {
  margin: 0;
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: var(--text-section-title);
  line-height: var(--leading-section-title);
}

.button {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: var(--button-height);
  padding: 0 24px;
  background: var(--colour-accent);
  color: var(--colour-on-accent);
  font-size: var(--text-button);
  font-weight: 500;
  letter-spacing: var(--tracking-button);
  text-align: center;
  text-decoration: none;
}

.button:hover {
  background: var(--colour-button-hover);
  color: var(--colour-on-accent);
}

.button-outline {
  border: 1px solid currentColor;
  background: transparent;
  color: var(--colour-ink);
}

.button-outline:hover {
  background: transparent;
  color: var(--colour-accent);
}

.text-link {
  display: flex;
  align-items: center;
  min-height: var(--touch-target);
  font-size: var(--text-link);
  text-decoration: underline;
  text-decoration-thickness: var(--underline-thickness);
  text-underline-offset: var(--underline-offset);
}

/* Photo slots. Each photo fills its slot's shape; the files are cropped
   to that shape by scripts/make-images.py, and object-fit covers any
   rounding. The slot's base colour shows until the photo loads. */
.photo {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
}

/* Hero: a landscape crop on phone, a portrait crop from tablet up (two
   files, picked by the <picture> element in the page). */
.photo-hero {
  aspect-ratio: 4 / 3;
  background: var(--colour-photo-hero);
}

@media (min-width: 744px) {
  .photo-hero {
    aspect-ratio: 4 / 5;
  }
}

.photo-shared-table {
  aspect-ratio: 3 / 2;
  background: var(--colour-photo-shared-table);
}

/* Menu page photos. The <picture> around the first one takes no box
   of its own, so the photo itself is the flex or grid item. */
.menu-picture {
  display: contents;
}

.photo-menu-1 {
  aspect-ratio: 7 / 8;
  background: var(--colour-photo-menu-1);
}

.photo-menu-2 {
  aspect-ratio: 4 / 3;
  background: var(--colour-photo-menu-2);
}


/* Home: hero

   Phone: photo (inside the right gutter), title, booking button, with
   24px between them. */

.hero {
  display: grid;
  grid-template-columns: var(--gutter-left) minmax(0, 1fr);
  /* The side text spans both rows, so on narrow phones, where it is
     taller than the photo, it does not push the title down. */
  grid-template-areas:
    "side photo"
    "side text";
  padding-right: var(--gutter-right);
}

.hero-side {
  grid-area: side;
  justify-self: center;
  align-self: start;
  margin: 0;
  padding-top: 4px;
  writing-mode: vertical-rl;
  white-space: nowrap;
  font-size: 11px;
  letter-spacing: 0.22em;
  color: var(--colour-muted);
}

/* No space under the hero: the tables section below sets the gap. */
.hero-text {
  grid-area: text;
  display: flex;
  flex-direction: column;
  padding: 24px 0 0;
}

/* The menu page title uses the same size scale as the hero title. */
.hero-title,
.menu-title {
  margin: 0;
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: 52px;
  line-height: 1.02;
  letter-spacing: -0.01em;
}

/* Phone: the hero title is smaller than the menu page title. */
.hero-title {
  font-size: 40px;
}

.hero-book {
  margin-top: 24px;
}

/* The <picture> around the hero photo takes no box of its own, so the
   photo itself is the grid item. */
.hero-picture {
  display: contents;
}

.photo-hero {
  grid-area: photo;
}

@media (min-width: 744px) {
  .hero {
    /* Photo: 360px wide at 820, growing to 432.36px at 1024, where the
       laptop share (608 of 1440) takes over. */
    --hero-photo-width: calc(69.1412px + 35.47059vw);
    grid-template-columns: var(--gutter-left) minmax(0, 1fr) var(--hero-photo-width);
    grid-template-areas: "side text photo";
    padding: 16px 0 0;
  }

  .hero-text {
    align-self: end;
    padding: 0 var(--gutter-right) 0 0;
  }

  /* 60px at 820, growing to 68.27px at 1024, where the laptop size takes over. */
  .hero-title,
  .menu-title {
    font-size: calc(26.7712px + 4.052288vw);
  }

  .hero-book {
    align-self: flex-start;
    width: 320px;
    margin-top: 28px;
  }
}

@media (min-width: 744px) {
  .hero {
    --hero-photo-width: min(42.2222vw, 608px);
    padding: 0;
  }

  .hero-side {
    padding-top: 8px;
    font-size: 12px;
    letter-spacing: 0.24em;
  }

  /* 68.27px at 1024, 96px at 1440 and wider. */
  .hero-title,
  .menu-title {
    font-size: min(6.6667vw, 96px);
    line-height: 1;
    letter-spacing: -0.015em;
  }

  /* Square on laptop (4:5 on tablet), so the whole hero fits one
     laptop screen. */
  .photo-hero {
    aspect-ratio: 1 / 1;
  }
}


/* Home: below the hero

   One column on phone, in this order: tables (list, photo), opening
   hours, the extra photo with "See the menu", find us. Every block has
   --home-gap above it (and Find us below it too), and --home-stack
   between the pieces inside it. Tablet follows the same order with a
   simple layout, to be redone in the tablet pass; laptop: see "Home:
   laptop page grid" below. */

.tables,
.opening,
.home-photo,
.find {
  display: flex;
  flex-direction: column;
  padding: var(--home-gap) var(--gutter-right) 0 var(--gutter-left);
}

.find {
  padding-bottom: var(--home-gap);
}


/* Home: tables (no title: the list opens the section) */

/* Each row: the name and its description close together (tighter
   lines, a 2px gap), 16px above and below. */
.table-option {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 16px 0;
  border-top: 1px solid var(--colour-rule);
}

.table-option:last-child {
  border-bottom: 1px solid var(--colour-rule);
}

.table-option-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  line-height: 1.3;
}

.table-option-name {
  margin: 0;
  font-size: 15px;
  font-weight: 500;
}

.table-option-size {
  font-size: 13px;
  color: var(--colour-muted);
  white-space: nowrap;
}

.table-option-text {
  margin: 0;
  font-size: 14px;
  line-height: 1.4;
  color: var(--colour-muted);
}

.photo-shared-table {
  margin-top: var(--home-stack);
}

@media (min-width: 744px) {
  .tables-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 32px;
  }

  .table-option {
    border-bottom: 1px solid var(--colour-rule);
  }

  .table-option-name {
    font-size: 16px;
  }

  .table-option-size {
    font-size: 14px;
  }

  .table-option-text {
    font-size: 15px;
  }
}

@media (min-width: 744px) {
  .tables-list {
    display: block;
  }

  .table-option {
    border-bottom: 0;
  }

  /* Laptop: larger than tablet, so the rows hold their own beside
     the photo. */
  .table-option-name {
    font-size: 20px;
  }

  .table-option-size {
    font-size: 16px;
  }

  .table-option-text {
    font-size: 17px;
  }

  .photo-shared-table {
    margin-top: 0;
  }
}


/* Home: opening hours */

.hours {
  margin-top: var(--home-stack);
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.hours tr {
  border-top: 1px solid var(--colour-rule);
}

.hours tr:last-child {
  border-bottom: 1px solid var(--colour-rule);
}

/* 44px row plus its 1px rule, as drawn. */
.hours th,
.hours td {
  height: 45px;
  padding: 0;
  text-align: left;
  font-weight: 400;
  white-space: nowrap;
}

.hours th,
.hours-time {
  padding-right: 8px;
  font-variant-numeric: tabular-nums;
}

.hours-note {
  color: var(--colour-muted);
}

/* The drawn column widths fit from 360px up; narrower, the columns
   size to their text. */
@media (min-width: 360px) {
  .hours th {
    width: 96px;
  }

  .hours-time {
    width: 112px;
  }
}

@media (min-width: 744px) {
  .hours {
    font-size: 15px;
  }

  .hours-time {
    width: 120px;
  }
}

@media (min-width: 744px) {
  .hours {
    font-size: 18px;
  }

  /* 52px row plus its 1px rule, as drawn. */
  .hours th,
  .hours td {
    height: 53px;
  }

  /* 140px and 180px at 1440, scaled down on narrower laptops. The time
     column stops at 150px so the note keeps clear of the 18px times. */
  .hours th {
    width: min(9.7222vw, 140px);
  }

  .hours-time {
    width: clamp(150px, 12.5vw, 180px);
  }
}


/* Home: extra photo and "See the menu" */

.photo-extra {
  aspect-ratio: 4 / 3;
  background: var(--colour-photo-extra);
}

.home-menu {
  margin-top: var(--home-stack);
}

@media (min-width: 744px) {
  .home-menu {
    align-self: flex-start;
    width: 320px;
  }
}




/* Home: find us

   Title, address and link read as one block: 12px under the title,
   and the link pulled up into the empty top of its own 44px tap area
   (the tap area keeps its size; it overlaps only empty space). */

.find-address {
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  font-style: normal;
}

.find-address p {
  margin: 0;
  font-size: 14px;
  color: var(--colour-muted);
}

.find-address .text-link {
  margin-top: -10px;
}

@media (min-width: 744px) {
  .find-address p {
    font-size: 15px;
  }
}

@media (min-width: 744px) {
  .find-address p {
    font-size: 18px;
  }

  .find-address .text-link {
    font-size: 17px;
  }
}


/* Home: laptop page grid

   On laptop the whole home page is one grid, so pieces can sit beside
   pieces from other sections while phone and tablet keep the source
   order. The section wrappers (hero, its text, tables, photo block)
   drop out of the layout (display: contents) and their pieces are
   placed one by one.

   Columns: left gutter | left 640 | column gap | right 256 | 16 |
   right 256 | right gutter (at 1440; scaled on narrower laptops). The
   right column is split in two for the side-by-side buttons; the hero
   photo runs from the right column to the edge (528 + 80 = 608).

   Rows: hero | gap | tables: photo on the left, centred against it on
   the right the rows and the two buttons ("Book a table" from the
   hero, "See the menu" from the photo block) | gap | Opening hours
   with Find us under it on the left, the photo on the right | gap.

   Tab order is unchanged and still matches what is seen: the two
   buttons, then the map link. */

@media (min-width: 744px) {
  .home {
    display: grid;
    grid-template-columns:
      var(--gutter-left)
      minmax(0, 640fr)
      var(--column-gap)
      minmax(0, 256fr)
      16px
      minmax(0, 256fr)
      var(--gutter-right);
    grid-template-rows:
      auto                /* 1 hero */
      var(--home-gap)     /* 2 */
      1fr auto auto 1fr   /* 3-6 tables */
      var(--home-gap)     /* 7 */
      auto auto           /* 8-9 hours, find us */
      var(--home-gap);    /* 10 */
    width: 100%;
    max-width: var(--frame-max);
    margin-inline: auto;
  }

  .hero,
  .hero-text,
  .tables,
  .home-photo {
    display: contents;
  }

  /* Hero */

  .hero-side {
    grid-column: 1;
    grid-row: 1;
  }

  /* Side padding: 80px and 96px at 1440, scaled down on narrower
     laptops. The bottom padding equals the empty space above the
     title's tallest letters in its line box (0.085 of the title size),
     so the visible text is centred on the photo. */
  .hero-title {
    grid-column: 2 / 4;
    grid-row: 1;
    align-self: center;
    padding: 0 min(6.6667vw, 96px) calc(min(6.6667vw, 96px) * 0.085) min(5.5556vw, 80px);
  }

  .photo-hero {
    grid-column: 4 / -1;
    grid-row: 1;
  }

  /* Tables */

  .photo-shared-table {
    grid-column: 2;
    grid-row: 3 / 7;
  }

  .tables-list {
    grid-column: 4 / 7;
    grid-row: 4;
  }

  .hero-book,
  .home-menu {
    grid-row: 5;
    width: auto;
    margin-top: var(--home-stack);
  }

  .hero-book { grid-column: 4; }
  .home-menu { grid-column: 6; }

  /* Opening hours, Find us and the photo */

  .opening {
    grid-column: 2;
    grid-row: 8;
    padding: 0;
  }

  /* Find us: the address follows the hours as one block of visit
     details. Its title is hidden on laptop but kept for screen readers
     (and as the target of the header's Visit link). */
  .find {
    position: relative;
    grid-column: 2;
    grid-row: 9;
    padding: 32px 0 0;
  }

  .find .section-title {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }

  .photo-extra {
    grid-column: 4 / 7;
    grid-row: 8 / 10;
    align-self: start;
  }

  .opening .hours {
    margin-top: 24px;
  }

  .find-address {
    margin-top: 0;
  }
}


/* Menu page

   Phone: one column, the button after the lists.
   Tablet: title and button on the left, the lists on the right, with
   240px for the left column and a 48px gap.
   Laptop: two blocks, drinks and food; see the laptop rules below.
   Two photos: the first (menu_1) as drawn; the second (menu_2, not
   drawn) in the lists, between Tea and To eat, spaced like a section.
   The drawn note under the title was removed on request; the button
   keeps its drawn gap and sits directly under the title. */

.menu {
  display: flex;
  flex-direction: column;
  padding: 40px var(--gutter-right) var(--section-pad-y) var(--gutter-left);
}

.menu-section-title {
  margin: 40px 0 0;
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: 24px;
  line-height: 1.2;
}

.menu-items {
  margin-top: 8px;
}

/* Price rows: 48px row plus its 1px rule, as drawn. */
.menu-items li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  min-height: 49px;
  border-bottom: 1px solid var(--colour-rule-light);
}

.price {
  font-variant-numeric: tabular-nums;
}

.menu-book {
  margin-top: 48px;
}

/* Phone: under the title, above the lists (title to photo as on the
   home tables section). Tablet and laptop: the left column's width,
   under the button, with the button's gap above it. */
.menu-photo {
  margin-top: 28px;
}

/* The second photo: the same space above it as above a section title. */
.menu-lists-photo {
  margin-top: 40px;
}

@media (min-width: 744px) {
  .menu {
    display: grid;
    grid-template-columns: 240px minmax(0, 1fr);
    grid-template-rows: auto auto auto 1fr;
    grid-template-areas:
      "title lists"
      "book  lists"
      "photo lists"
      ".     lists";
    column-gap: 48px;
    padding-top: 64px;
  }

  .menu-photo {
    grid-area: photo;
    margin-top: 32px;
  }

  .menu-title {
    grid-area: title;
  }

  .menu-lists {
    grid-area: lists;
  }

  .menu-section-title {
    margin-top: 48px;
    font-size: 26px;
  }

  .menu-section:first-child .menu-section-title {
    margin-top: 0;
  }

  .menu-lists-photo {
    margin-top: 48px;
  }

  .menu-book {
    grid-area: book;
    align-self: start;
    margin-top: 32px;
  }
}

/* Laptop: two equal columns and two blocks, like the home page.
   Drinks: the pour photo on the left, Coffee and Tea on the right,
   centred against it. Food: To eat on the left, the cake photo on the
   right, the list centred against it. The lists
   wrapper drops out of the layout (display: contents) so its sections
   and the cake photo are placed one by one; the source order, and so
   the reading and tab order, stays the phone order. */
@media (min-width: 744px) {
  .menu {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    grid-template-rows:
      auto                /* 1 title */
      64px                /* 2 */
      1fr auto auto 1fr   /* 3-6 drinks */
      var(--home-gap)     /* 7 */
      1fr auto auto 1fr;  /* 8-11 food */
    grid-template-areas: none;
    column-gap: var(--column-gap);
    padding-top: 96px;
  }

  .menu-lists {
    display: contents;
  }

  .menu-title {
    grid-column: 1 / -1;
    grid-row: 1;
  }

  .menu-photo {
    grid-column: 1;
    grid-row: 3 / 7;
    margin-top: 0;
  }

  .menu-section:nth-child(1) { grid-column: 2; grid-row: 4; }
  .menu-section:nth-child(2) { grid-column: 2; grid-row: 5; }
  .menu-section:last-child   { grid-column: 1; grid-row: 9; }

  .menu-lists-photo {
    grid-column: 2;
    grid-row: 8 / 12;
    margin-top: 0;
  }

  /* Not shown on laptop: the header's "Book a table" button covers it.
     Phone and tablet keep it after the lists. */
  .menu-book {
    display: none;
  }

  /* Larger on laptop, so the lists hold their own beside the photos. */
  .menu-section-title {
    margin-top: 56px;
    font-size: 32px;
  }

  .menu-section:first-child .menu-section-title,
  .menu-section:last-child .menu-section-title {
    margin-top: 0;
  }

  .menu-items {
    margin-top: 12px;
  }

  .menu-items li {
    min-height: 57px;
    font-size: 18px;
  }
}


/* Social media placeholder page: heading and link centred in the space
   left under the header, raised by the drawn 120px bottom padding. */

.placeholder {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  padding: 0 var(--gutter-right) 120px var(--gutter-left);
}

.placeholder-title {
  margin: 0;
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: 44px;
  line-height: 1.05;
  letter-spacing: -0.01em;
}

.placeholder-back {
  margin-top: 28px;
}

@media (min-width: 744px) {
  .placeholder-title {
    font-size: 52px;
  }
}

@media (min-width: 1024px) {
  /* 56.89px at 1024, 80px at 1440 and wider. */
  .placeholder-title {
    font-size: min(5.5556vw, 80px);
    line-height: 1;
    letter-spacing: -0.015em;
  }

  .placeholder-back {
    margin-top: 40px;
  }
}


/* Footer */

.site-footer {
  flex-shrink: 0;
  /* The band runs edge to edge; its content lines up with the frame. */
  padding:
    var(--footer-pad-y)
    calc(var(--frame-inset) + var(--gutter-right))
    var(--footer-pad-y)
    calc(var(--frame-inset) + var(--gutter-left));
  /* A band in the palette's light card colour, ink text. */
  background: var(--colour-band);
  color: var(--colour-ink);
}

/* Logo left, icons right, on one row at every width. */
.footer-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.site-footer .logo-name {
  font-size: var(--text-footer-logo);
}

.footer-nav ul {
  display: flex;
  gap: var(--footer-icon-gap);
}

/* Email: phone shows the round icon (it opens the mail app). Tablet and
   laptop show the address as a text link instead, so it can be read and
   copied even where no email program is set up to open the link. */
.footer-email-text {
  display: none;
}

@media (min-width: 744px) {
  .footer-email-text {
    display: flex;
    align-items: center;
    margin-right: 16px;
  }

  .footer-email-icon {
    display: none;
  }
}

/* Round outlined icon buttons: a 36px circle with a 16px line icon,
   both in ink. The tap area stays 44px: the circle is drawn 4px
   inside it. On hover the circle fills with ink and the icon turns
   the page colour. */
.footer-icon {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: var(--touch-target);
  height: var(--touch-target);
  border-radius: 50%;
  color: var(--colour-ink);
}

.footer-icon::before {
  content: "";
  position: absolute;
  inset: 4px;
  border: 1px solid currentColor;
  border-radius: 50%;
}

.footer-icon:hover {
  color: var(--colour-paper);
}

.footer-icon:hover::before {
  border-color: var(--colour-ink);
  background: var(--colour-ink);
}

.footer-icon svg {
  position: relative;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.footer-icon .footer-icon-dot {
  fill: currentColor;
  stroke: none;
}


/* Tablet (744 to 1023px): the laptop layout, with tablet sizes.
   Everything below applies only in this range, so phone and laptop
   are untouched. */

@media (min-width: 744px) and (max-width: 1023.98px) {
  /* Hero title: less side padding, so the title fits its column. */
  .hero-title {
    padding: 0 24px calc(min(6.6667vw, 96px) * 0.085) 32px;
  }

  /* Section 2: smaller rows than laptop; button padding trimmed so
     both labels fit side by side in the narrow right column. */
  .table-option-name {
    font-size: 18px;
  }

  .table-option-size {
    font-size: 15px;
  }

  .table-option-text {
    font-size: 16px;
  }

  .hero-book,
  .home-menu {
    padding: 0 12px;
  }

  /* Opening hours and the address. */
  .hours {
    font-size: 16px;
  }

  .hours th,
  .hours td {
    height: 48px;
  }

  .hours th {
    width: 88px;
  }

  .hours-time {
    width: 128px;
  }

  .find-address p {
    font-size: 16px;
  }

  .find-address .text-link {
    font-size: 15px;
  }

  /* The toast photo takes the height of the hours-and-address block
     beside it (top of "Opening hours" to the map link), cropped to
     fit. Its own size is ignored for sizing (contain: size), so the
     text alone sets the height. */
  .photo-extra {
    align-self: stretch;
    height: 100%;
    aspect-ratio: auto;
    contain: size;
  }

  /* Menu page. The pour photo takes the height of the Coffee and Tea
     lists beside it, cropped to fit (from the taller tablet file; see
     menu.html). Its own size is ignored for sizing (contain: size), so
     the lists alone set the height. */
  .menu {
    padding-top: 64px;
  }

  .menu-photo {
    align-self: stretch;
    height: 100%;
    aspect-ratio: auto;
    contain: size;
  }

  .menu-section-title {
    margin-top: 48px;
    font-size: 28px;
  }

  .menu-items li {
    min-height: 53px;
    font-size: 16px;
  }
}
