:root {
  --pine: #1c2417;
  --pine-2: #2a321f;
  --logo-green: #27473a;
  --paper: #d1d0a0;
  --paper-soft: #e7e2bb;
  --cream: #f5f0cf;
  --brass: #d8b15f;
  --espresso: #12100c;
  --ink-muted: #5e5836;
  --terracotta: #a85430;
  --line: rgba(18, 16, 12, 0.14);
  --shadow: 0 22px 70px rgba(0, 0, 0, 0.28);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--espresso);
  background:
    linear-gradient(90deg, rgba(28, 36, 23, 0.98), rgba(28, 36, 23, 0.8)),
    radial-gradient(circle at 12% 18%, rgba(216, 177, 95, 0.24), transparent 23rem),
    var(--pine);
  font-family: "Source Sans 3", "Segoe UI", sans-serif;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.16;
  background-image:
    linear-gradient(135deg, rgba(255, 255, 255, 0.18) 0 1px, transparent 1px 9px),
    linear-gradient(45deg, rgba(0, 0, 0, 0.24) 0 1px, transparent 1px 10px);
  mix-blend-mode: overlay;
}

.shell {
  width: min(1180px, calc(100% - 24px));
  margin: 0 auto;
  padding: 18px 0 46px;
}

.masthead {
  position: sticky;
  top: 0;
  z-index: 10;
  display: grid;
  grid-template-columns: minmax(220px, 420px) auto;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  min-height: 126px;
  padding: 12px clamp(14px, 4vw, 26px);
  color: var(--cream);
  background: var(--logo-green);
  border: 1px solid rgba(216, 177, 95, 0.2);
  border-radius: 0 0 8px 8px;
  box-shadow: 0 16px 44px rgba(0, 0, 0, 0.24);
  backdrop-filter: blur(12px);
}

.brand-logo {
  display: block;
  width: min(100%, 420px);
  line-height: 0;
}

.brand-logo img {
  display: block;
  width: 100%;
  height: auto;
}

.date-note {
  margin: 0;
  max-width: 210px;
  color: rgba(245, 240, 207, 0.74);
  text-align: right;
  font-style: italic;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.menu-tools {
  position: sticky;
  top: 229px;
  z-index: 9;
  display: grid;
  grid-template-columns: minmax(230px, 340px) 1fr;
  gap: 12px;
  align-items: center;
  margin: 0 -1px 2px;
  padding: 12px 1px;
  background:
    linear-gradient(180deg, rgba(28, 36, 23, 0.98), rgba(28, 36, 23, 0.93)),
    var(--pine);
  border-bottom: 1px solid rgba(216, 177, 95, 0.12);
  backdrop-filter: blur(12px);
}

.search-box {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  align-items: center;
  min-height: 48px;
  padding: 7px 12px 7px 16px;
  color: var(--cream);
  background: rgba(18, 16, 12, 0.3);
  border: 1px solid rgba(216, 177, 95, 0.24);
  border-radius: 8px;
}

.search-box span {
  font-weight: 800;
  color: var(--brass);
}

.search-box input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  color: var(--cream);
  background: transparent;
  font: inherit;
}

.search-box input::placeholder {
  color: rgba(245, 240, 207, 0.54);
}

.category-rail {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 4px 0;
  scrollbar-width: none;
}

.category-rail::-webkit-scrollbar {
  display: none;
}

.category-button {
  flex: 0 0 auto;
  min-height: 44px;
  padding: 10px 15px;
  border: 1px solid rgba(216, 177, 95, 0.24);
  border-radius: 999px;
  color: var(--cream);
  background: rgba(255, 255, 255, 0.05);
  font: 800 0.9rem/1 "Source Sans 3", sans-serif;
  cursor: pointer;
}

.category-button.is-active {
  color: var(--espresso);
  background: var(--brass);
  border-color: var(--brass);
}

.section-panel {
  scroll-margin-top: 340px;
  margin: 14px 0 18px;
  padding: clamp(18px, 4vw, 30px);
  background:
    linear-gradient(115deg, rgba(245, 240, 207, 0.23), rgba(255, 255, 255, 0.02)),
    var(--paper);
  border-radius: 8px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}

.section-panel::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 16px;
  background:
    linear-gradient(135deg, transparent 33%, #050505 33% 46%, transparent 46%) 0 0 / 32px 16px,
    linear-gradient(225deg, transparent 33%, #050505 33% 46%, transparent 46%) 0 0 / 32px 16px;
}

.section-heading {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: end;
  margin-bottom: 18px;
  border-bottom: 1px solid rgba(18, 16, 12, 0.18);
  padding-bottom: 10px;
}

.section-heading h2 {
  margin: 0;
  font-family: "Bodoni Moda", Georgia, serif;
  font-size: clamp(2.5rem, 7vw, 5rem);
  line-height: 0.95;
  letter-spacing: 0;
}

.section-heading span {
  color: var(--ink-muted);
  font-weight: 800;
}

.items-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.menu-card {
  display: grid;
  gap: 8px;
  min-height: 156px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(245, 240, 207, 0.34);
}

.menu-card-top {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
}

.menu-card-top p {
  grid-column: 1;
}

.menu-card h3 {
  margin: 0;
  font-size: clamp(1.08rem, 2.6vw, 1.42rem);
  line-height: 1.1;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 900;
}

.menu-card p {
  margin: 0;
  color: #282416;
  font-size: 1.04rem;
  font-style: italic;
  line-height: 1.28;
}

.price-stack {
  grid-column: 2;
  grid-row: 1 / 3;
  display: grid;
  gap: 5px;
  justify-items: end;
  min-width: 56px;
  color: var(--espresso);
  font-size: clamp(1.22rem, 2.8vw, 1.44rem);
  font-weight: 900;
  line-height: 1;
  text-align: right;
  white-space: nowrap;
}

.empty-state {
  padding: 28px;
  border-radius: 8px;
  color: var(--cream);
  background: rgba(18, 16, 12, 0.32);
  border: 1px solid rgba(216, 177, 95, 0.2);
  text-align: center;
  font-weight: 800;
}

.board-gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 24px;
}

.board-button {
  padding: 0;
  border: 1px solid rgba(216, 177, 95, 0.25);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.28);
  overflow: hidden;
  cursor: pointer;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.24);
}

.board-button img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.board-button span {
  display: block;
  padding: 10px 12px;
  color: var(--cream);
  font-weight: 800;
  text-align: left;
}

.image-dialog {
  width: min(96vw, 1320px);
  padding: 0;
  border: 1px solid rgba(216, 177, 95, 0.45);
  border-radius: 8px;
  background: #111;
}

.image-dialog::backdrop {
  background: rgba(0, 0, 0, 0.82);
}

.image-dialog img {
  display: block;
  width: 100%;
  height: auto;
}

.dialog-close {
  position: fixed;
  top: 14px;
  right: 14px;
  z-index: 2;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(245, 240, 207, 0.55);
  border-radius: 50%;
  color: var(--cream);
  background: rgba(18, 16, 12, 0.82);
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
}

@media (max-width: 980px) {
  .masthead {
    grid-template-columns: minmax(220px, 360px) auto;
  }

  .date-note {
    max-width: 190px;
  }

  .menu-tools {
    top: 202px;
    grid-template-columns: 1fr;
  }

  .items-grid,
  .board-gallery {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .shell {
    width: min(100% - 18px, 560px);
    padding-top: 8px;
  }

  .masthead {
    grid-template-columns: 1fr;
    min-height: 118px;
    gap: 12px;
    padding: 12px;
  }

  .menu-tools {
    top: 202px;
    margin-inline: 0;
    padding: 10px 0 12px;
  }

  .brand-logo {
    width: min(100%, 300px);
  }

  .date-note {
    max-width: none;
    text-align: left;
    font-size: 0.85rem;
  }

  .items-grid,
  .board-gallery {
    grid-template-columns: 1fr;
  }

  .section-heading {
    display: block;
  }

  .section-heading h2 {
    margin-bottom: 6px;
  }

  .menu-card {
    min-height: auto;
  }
}
