:root {
  --cream: #fbf3e0;
  --page: #f3e9d9;
  --burgundy: #680111;
  --ink: #181b1e;
  --line: rgba(104, 1, 17, 0.28);
}

* { box-sizing: border-box; }

html,
body {
  height: 100%;
  overflow: hidden;
}

body {
  margin: 0;
  display: flex;
  flex-direction: column;
  background: var(--cream);
  color: var(--burgundy);
  font-family: "Cormorant Garamond", Palatino, Georgia, serif;
}

.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  background: var(--burgundy);
  color: var(--cream);
  padding: 0.4rem 0.7rem;
}

.skip:focus { top: 0.6rem; z-index: 6; }

.top {
  flex: 0 0 auto;
  z-index: 4;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  background: #fbf3e0;
  border-bottom: 1px solid var(--line);
}

.brand {
  display: block;
  margin: 0;
  padding: 0.55rem 0;
  text-align: center;
  font-family: "Cormorant Garamond", Palatino, Georgia, serif;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0;
  text-transform: uppercase;
  line-height: 1;
  color: var(--burgundy);
  text-decoration: none;
}

.search-btn {
  justify-self: end;
  margin: 0.35rem 0.5rem 0.35rem 0;
  padding: 0.4rem 0.7rem;
  min-height: 2.25rem;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--burgundy);
  font-family: "Cormorant Garamond", Palatino, Georgia, serif;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0;
  line-height: 1.1;
  text-transform: uppercase;
}

.search-btn[aria-expanded="true"] {
  background: rgba(104, 1, 17, 0.07);
}

.finder {
  flex: 0 0 auto;
  padding: 0.35rem 0.7rem 0.55rem;
  background: var(--cream);
  border-bottom: 1px solid var(--line);
}

.finder input {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0.55rem 0.7rem;
  border: 1px solid var(--line);
  background: var(--page);
  color: var(--burgundy);
  font-family: "Cormorant Garamond", Palatino, Georgia, serif;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.2;
}

.sr {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.sheet:has(#results.is-on) {
  overflow-y: auto;
}

#results.is-on {
  display: block;
  height: auto;
}

#results .dishes li {
  cursor: pointer;
}

.split {
  display: grid;
  grid-template-columns: minmax(8.6rem, 17rem) minmax(0, 1fr);
  width: min(1100px, 100%);
  margin: 0 auto;
  flex: 1;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
}

.rail {
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow-y: auto;
  padding: 0.35rem 0.7rem 1rem;
  border-right: 1px solid var(--line);
  background: var(--cream);
}

.rail a {
  display: block;
  padding: 0.45rem 0.15rem;
  border-bottom: 1px solid var(--line);
  color: var(--burgundy);
  font-family: "Cormorant Garamond", Palatino, Georgia, serif;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0;
  line-height: 1.1;
  text-transform: uppercase;
  text-decoration: none;
}

.rail a[aria-current="true"] {
  background: rgba(104, 1, 17, 0.07);
}

.sheet {
  width: 100%;
  height: 100%;
  min-width: 0;
  overflow: hidden;
  background: var(--page);
}

.panel {
  display: none;
}

.panel.is-on {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
}

.panel img {
  display: block;
  width: 100%;
  flex: 1 1 0;
  min-height: 0;
  height: 0;
  object-fit: contain;
  object-position: center;
  background: var(--page);
}

.copy {
  flex: 0 0 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  padding: 0.35rem 0.8rem 0.3rem;
}

.kicker,
.cols,
.note {
  font-family: "Cormorant Garamond", Palatino, Georgia, serif;
}

.kicker,
h2,
h3,
.price,
.cols,
.note,
.promise li {
  font-family: "Cormorant Garamond", Palatino, Georgia, serif;
  font-size: 13px;
  font-weight: 500;
  font-style: normal;
  letter-spacing: 0;
  line-height: 1.1;
}

.kicker {
  margin: 0;
  text-transform: uppercase;
}

h2 {
  margin: 0 0 0.25rem;
  text-transform: uppercase;
}

.cover-copy { text-align: center; }

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

.promise {
  flex: 1;
}

.promise li {
  padding: 0.35rem 0;
  border-top: 1px solid var(--line);
}

.cols,
.prices {
  display: grid;
  grid-template-columns: repeat(3, 2.4rem);
  justify-content: end;
  gap: 0.35rem;
  text-align: right;
}

.starters .prices,
#starters .prices,
#starters .cols {
  grid-template-columns: repeat(2, 2.6rem);
}

.cols {
  margin: 0 0 0.1rem;
}

.dishes {
  list-style: none;
  margin: 0;
  padding: 0;
  flex: 1;
  min-height: 0;
  border-top: 1px solid var(--line);
}

.dishes li {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.6rem;
  align-items: baseline;
  padding: 1px 0;
  border-bottom: 1px solid rgba(104, 1, 17, 0.12);
}

h3 { margin: 0; }

.note {
  margin: 0.05rem 0 0;
  color: var(--ink);
}

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

a:focus-visible {
  outline: 1px solid var(--burgundy);
  outline-offset: 3px;
}

@media (max-width: 720px) {
  html,
  body {
    height: auto;
    min-height: 100%;
    overflow-x: hidden;
    overflow-y: auto;
  }

  .bar {
    position: sticky;
    top: 0;
    z-index: 5;
    background: var(--cream);
  }

  .split {
    display: block;
    width: 100%;
    height: auto;
    overflow: visible;
  }

  .rail {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    height: auto;
    overflow: visible;
    padding: 0;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .rail a {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 0;
    padding: 0.28rem 0.15rem;
    border-bottom: 1px solid var(--line);
    border-right: 1px solid var(--line);
    font-size: 11px;
    line-height: 1.05;
    text-align: center;
    white-space: normal;
  }

  .rail a:nth-child(4n) { border-right: 0; }

  .sheet {
    height: auto;
    overflow: visible;
  }

  .panel { scroll-margin-top: 3.4rem; }

  .panel.is-on {
    display: block;
    height: auto;
  }

  .panel img {
    flex: none;
    width: 100%;
    height: 132px;
    min-height: 132px;
    max-height: 132px;
    object-fit: cover;
    object-position: center;
  }

  .copy {
    padding: 0.55rem 0.85rem calc(1.25rem + env(safe-area-inset-bottom));
  }

  .dishes li {
    padding: 0.42rem 0;
  }
}
