:root {
  --bg: #eeeae3;
  --ink: #302d28;
  --line: #c9bdab;
  --accent: #70573c;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: Arial, sans-serif;
}

.site-navigation {
  border-bottom: 1px solid var(--line);
}

main {
  max-width: 1100px;
  margin-inline: auto;
  padding: 1.25rem 1rem 3rem;
}

h1 {
  margin: 0.5rem 0 1.5rem;
  text-align: center;
  font-size: clamp(2rem, 6vw, 3rem);
}

.menu-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.875rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.dish {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #faf7f0;
}

.dish img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
}

.dish h2 {
  margin: 0;
  padding: 0.8rem 0.4rem;
  text-align: center;
  font-size: clamp(1rem, 3.6vw, 1.25rem);
  line-height: 1.35;
}

@media (min-width: 720px) {
  .menu-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.25rem;
  }
}

@media (min-width: 1000px) {
  .menu-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.dish {
  display: flex;
  flex-direction: column;
}

.dish-details {
  flex: 1;
}

.dish-details summary {
  position: relative;
  list-style: none;
  cursor: pointer;
}

.dish-details summary::-webkit-details-marker {
  display: none;
}

.dish-details summary::after {
  content: "";
  position: absolute;
  inset-inline-end: 0.65rem;
  bottom: 1.15rem;
  width: 0.4rem;
  height: 0.4rem;
  border: solid var(--accent);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.dish-details[open] summary::after {
  transform: rotate(225deg);
}

.dish-details h2 {
  padding-inline: 1.65rem;
}

.dish-details[open] picture {
  display: none;
}

.dish-description {
  margin: 0;
  padding: 0.5rem 0.8rem 1rem;
  line-height: 1.55;
  text-align: center;
}

.dish-select {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  gap: 0.5rem;
  border-top: 1px solid var(--line);
  cursor: pointer;
}

.dish-select input {
  width: 1.125rem;
  height: 1.125rem;
  accent-color: var(--accent);
}

.dish:has(.dish-select input:checked) {
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--accent);
}

.dish-details summary:focus-visible,
.dish-select input:focus-visible,
.menu-order button:focus-visible {
  outline: 3px solid #a56d36;
  outline-offset: -3px;
}

html {
  scroll-padding-block-start: 5rem;
}

.menu-order {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  margin-block-end: 1.25rem;
  padding: 0.6rem 0.75rem;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #faf7f0;
  box-shadow: 0 3px 12px #302d281c;
}

.menu-order[hidden] {
  display: none;
}

.menu-order p {
  margin: 0;
}

.menu-order button {
  min-height: 44px;
  padding: 0.5rem 1rem;
  border: 1px solid var(--accent);
  border-radius: 9px;
  background: var(--accent);
  color: white;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.menu-order button:disabled {
  color: var(--ink);
  background: var(--bg);
  border-color: var(--line);
  cursor: default;
}

.order-confirmation {
  text-align: center;
  color: var(--accent);
}

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