.menu-section { border-block: 1px solid var(--color-border); }

/* Fixed groups instead of a filterable pool — see
   openspec/changes/archive/2026-09-17-menu-text-redesign/ Post-ship. Groups are separated by
   this gap (larger than a grid's own row-gap below) *and*, since
   openspec/changes/archive/2026-09-28-menu-group-headings/, each group's own visible heading —
   originally whitespace alone was the only signal, reversed on later
   request.

   The larger `* 1.5` gap was specifically added (spec 003 Post-ship) to
   compensate for that heading being removed — on mobile/tablet it's
   back (openspec/changes/archive/2026-09-28-menu-group-headings/), so the gap reverts to the plain `--space-xl` there
   (owner's follow-up: too much empty space on mobile). Desktop, where
   the heading stays hidden, keeps the larger compensating gap
   unchanged. */
.menu-groups {
  display: flex;
  flex-direction: column;
  gap: var(--space-xl);
}
@media (min-width: 1024px) {
  .menu-groups {
    gap: calc(var(--space-xl) * 1.5);
  }
}

/* openspec/changes/archive/2026-09-28-menu-group-headings/ — one per category
   ("Loempia's"/"Snacks"/"Sauzen"/"Deals"/"Dranken"), set by
   menu-loader.js's categoryLabel(). Reuses the same headline
   font/weight/color as the site's other h1-h3 utilities (typography.css)
   rather than introducing a new type style, sized between the section's
   own .h2 and an individual .menu-item__title.

   Mobile/tablet only, hidden from the `lg` breakpoint (1024px) up —
   owner's follow-up request: liked on mobile, not on desktop. 1024px
   matches this exact section's own existing grid breakpoint just below
   (1/2-column grid → 3-column "desktop" grid), not a new one, since
   that's already this component's own definition of "desktop" layout. */
.menu-group__title {
  margin-bottom: var(--space-md);
  font-family: var(--font-headline);
  font-weight: 700;
  font-size: 1.375rem;
  line-height: 1.2;
  color: var(--color-brand-black);
}
@media (min-width: 1024px) {
  .menu-group__title {
    display: none;
  }
}

.menu-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-lg) var(--space-xl);
}
@media (min-width: 640px) {
  .menu-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
  .menu-grid { grid-template-columns: repeat(3, 1fr); }

  /* A group with exactly two items (currently: sauzes, deals, drinks)
     never fills all 3 columns here, leaving them stuck to the left with
     an empty third column. Centered instead, at the same item width a
     full row would give them (matching calc, not a guessed fixed width)
     — see openspec/changes/archive/2026-09-17-menu-content-driven/ Post-ship. Only needed at
     this breakpoint: the 2-column tablet grid already has two items
     fill the row exactly, and mobile is single-column. */
  .menu-grid--pair {
    grid-template-columns: repeat(2, minmax(0, calc((100% - 2 * var(--space-xl)) / 3)));
    justify-content: center;
  }
}

/* Text-only item — no photo/media slot for now, see openspec/changes/archive/2026-09-17-menu-text-redesign/. */
.menu-item {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.menu-item__title-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--space-sm);
}
.menu-item__title-group {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}
.menu-item__title {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 1.0625rem;
  color: var(--color-brand-black);
}
.menu-item__price {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 1rem;
  /* --color-primary-hover: --color-primary measured ~4.46:1 here, just
     under WCAG AA's 4.5:1 minimum for this text size. */
  color: var(--color-primary-hover);
  white-space: nowrap;
}
.menu-item__desc {
  font-size: 0.8125rem;
  color: var(--color-muted-gray);
  line-height: 1.5;
}

/* openspec/changes/archive/2026-09-24-menu-dietary-badges/ — small icon-only badges next to the
   item name (not a separate row — see Post-ship). Full label is a
   custom hover/focus tooltip (below) plus role="img"/aria-label for
   screen readers, since the icon alone carries no text. */
.menu-item__badges {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}
.dietary-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  position: relative;
}
.dietary-badge .icon {
  width: 1rem;
  height: 1rem;
}
.dietary-badge--vegetarisch,
.dietary-badge--vegan {
  color: var(--color-emerald-tint-text);
}
.dietary-badge--pittig {
  color: var(--color-primary-hover);
}
.dietary-badge--kip {
  color: var(--color-gold-hover);
}
.dietary-badge--halal {
  color: var(--color-purple-tint-text);
}

/* Every dietary icon shares the same 1rem box, but the source artwork
   fills that box very differently (icon-bi-moon-fill's crescent nearly
   touches all four edges, ~94% of the viewBox; icon-leaf/icon-chicken
   have generous built-in padding, ~55%) — same box, visibly different
   weight, reported back as "the moon icon looks much bigger". Scaled
   down per-icon here (not in the sprite) to match visual size rather
   than nominal box size. */
.dietary-badge--pittig .icon {
  width: 0.875rem;
  height: 0.875rem;
}
.dietary-badge--halal .icon {
  width: 0.75rem;
  height: 0.75rem;
}

/* Custom tooltip, shown only on the badges that carry a data-tooltip
   (the real menu-item badges — menu-loader.js's buildDietaryBadges()
   sets it; the legend's own badges don't, since their label is already
   plain visible text next to them, so they're untouched by this rule
   entirely). Replaces relying on the native title="..." tooltip, which
   follows the mouse cursor itself and so started out hidden behind/
   under the very pointer that revealed it — reported back as
   unreadable. This bubble instead has a fixed position above the icon,
   independent of the cursor. */
.dietary-badge[data-tooltip] {
  cursor: default;
}
.dietary-badge[data-tooltip]::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: calc(100% + 0.35rem);
  left: 50%;
  transform: translateX(-50%);
  background: var(--color-brand-black);
  color: #fff;
  font-size: 0.6875rem;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
  padding: 0.3rem 0.55rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s ease;
  z-index: 10;
}
.dietary-badge[data-tooltip]:hover::after,
.dietary-badge[data-tooltip]:focus-visible::after {
  opacity: 1;
}

/* "What do these icons mean" key — built by menu-loader.js's
   buildLegend(), one entry per dietary badge type actually used
   somewhere in the menu. .dietary-badge here is the same icon-only
   badge as on a menu item (same size/color rules above already apply),
   just paired with its own visible label instead of a hover-only one —
   so no tooltip here, there's nothing hidden to reveal — the label is
   already visible plain text right next to the icon.

   Lives inside .section-header (moved here on request, from below the
   whole grid, so a visitor sees what the icons mean before scrolling
   into the items that use them) — that's a flex column with its own
   `gap: var(--space-xs)` between the eyebrow/title/subtext, which
   already provides *some* separation, but this margin-top adds a bit
   more: the legend reads as a distinct little block (icon+label chips),
   not another line of the same flowing copy. */
.menu-legend {
  margin-top: var(--space-sm);
}
.menu-legend__list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 1.25rem;
}
.menu-legend__item {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.8125rem;
  color: var(--color-muted-gray);
}

.menu-allergen-notice {
  margin-top: var(--space-xl);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  text-align: center;
  background: var(--color-subtle);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  padding: 0.6rem 1.25rem;
  font-size: 0.75rem;
  color: var(--color-muted-gray);
}
.menu-allergen-notice .icon { color: var(--color-gold); }
