/* =========================================================================
   ZubesGrub - Menu page (card grid, ordering-friendly)
   Loads AFTER app.css. Each dish is a self-contained card: image, name,
   price, and (for bowls) protein + side choices RIGHT on the card, then
   Add to bag. No hover-preview, no hidden state. NG/US world switch filters.
   Color lock: orange = interactive accent; green = NG, red = US signifiers.
   ========================================================================= */

:root {
  --adire: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='84' height='84' viewBox='0 0 84 84'%3E%3Cg fill='none' stroke='%23ffffff' stroke-opacity='0.10' stroke-width='2'%3E%3Ccircle cx='42' cy='42' r='15'/%3E%3Ccircle cx='42' cy='42' r='6'/%3E%3Cpath d='M42 0v84M0 42h84'/%3E%3Ccircle cx='0' cy='0' r='9'/%3E%3Ccircle cx='84' cy='0' r='9'/%3E%3Ccircle cx='0' cy='84' r='9'/%3E%3Ccircle cx='84' cy='84' r='9'/%3E%3C/g%3E%3C/svg%3E");
}

/* ---------------- Hero band (green, adire) ---------------- */
.menu-hero {
  position: relative;
  background:
    radial-gradient(110% 120% at 90% 0%, rgba(255, 90, 31, 0.25), transparent 55%),
    linear-gradient(180deg, #0c5828, #073d1c);
  color: #f4ffe9;
  overflow: hidden;
  isolation: isolate;
  padding-block: clamp(40px, 6vw, 68px);
}
.menu-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image: var(--adire);
  background-size: 84px 84px;
  opacity: 0.85;
  mask-image: linear-gradient(180deg, #000 40%, transparent);
}
.menu-hero h1 {
  font-size: clamp(2.6rem, 7vw, 5rem);
  line-height: 0.95;
}
.menu-hero p {
  color: #d8f0dd;
  max-width: 48ch;
  margin-top: 12px;
  font-size: 1.1rem;
}

/* ---------------- World switch (sticky so it stays handy) ---------------- */
.switch-bar {
  position: sticky;
  top: var(--nav-h);
  z-index: 30;
  background: rgba(255, 252, 247, 0.92);
  backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--line);
  padding-block: 12px;
}
.world-switch {
  display: inline-flex;
  gap: 4px;
  background: var(--cream);
  border: 1px solid var(--line-2);
  padding: 5px;
  border-radius: 999px;
}
.world-switch button {
  border: 0;
  background: transparent;
  color: var(--ink-2);
  font-weight: 700;
  font-size: 0.95rem;
  padding: 0.55em 1.1em;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition:
    background 0.2s ease,
    color 0.2s ease;
}
.world-switch button.on {
  background: var(--orange);
  color: #fff;
}
.world-count {
  font-family: var(--mono);
  font-size: 0.78rem;
  opacity: 0.7;
}

/* ---------------- Category blocks ---------------- */
.m-cat-block {
  margin-bottom: 40px;
}
.m-cat-head {
  font-family: var(--display);
  font-weight: 800;
  letter-spacing: -0.01em;
  font-size: clamp(1.4rem, 3vw, 2rem);
  color: var(--ink);
  padding-bottom: 14px;
  margin-bottom: 22px;
  border-bottom: 2px solid var(--ink);
  display: flex;
  align-items: center;
  gap: 12px;
}
.m-cat-head .cat-flag {
  font-size: 1.1rem;
}
.m-cat-head .cat-note {
  font-family: var(--sans);
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--ink-3);
  margin-left: auto;
}

/* ---------------- Cards ---------------- */
.m-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  align-items: stretch;
}
.m-grid.tight {
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}
.m-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}
.m-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}
.m-card-img {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, var(--paper-2), var(--cream));
}
.m-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.m-card:hover .m-card-img img {
  transform: scale(1.05);
}
.m-flag {
  position: absolute;
  top: 12px;
  left: 12px;
}
.m-spice {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(26, 13, 5, 0.82);
  color: #fff;
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 0.78rem;
  font-weight: 700;
  backdrop-filter: blur(2px);
}
.m-card-body {
  padding: 18px 20px 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}
.m-card-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
}
.m-card-top h3 {
  font-size: 1.18rem;
  line-height: 1.1;
}
.m-price {
  font-family: var(--mono);
  font-weight: 700;
  font-size: 1.05rem;
  white-space: nowrap;
}
.m-price .from {
  font-family: var(--sans);
  font-weight: 600;
  font-size: 0.72rem;
  color: var(--ink-3);
  display: block;
  text-align: right;
  margin-bottom: -2px;
}
.m-desc {
  color: var(--ink-2);
  font-size: 0.92rem;
}

/* choices (protein / side) */
.choose {
  margin-top: 2px;
}
.choose-label {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink-3);
  margin-bottom: 7px;
}
.choice-row {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}
.choice {
  border: 1.5px solid var(--line-2);
  background: var(--white);
  color: var(--ink-2);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition:
    background 0.15s ease,
    color 0.15s ease,
    border-color 0.15s ease;
}
.choice:hover {
  border-color: var(--ink);
}
.choice.sel {
  background: var(--ink);
  color: #fff;
  border-color: var(--ink);
}
.choice .prem {
  opacity: 0.7;
  font-weight: 500;
}

.includes {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--green-deep);
  background: rgba(19, 138, 54, 0.1);
  border: 1px solid rgba(19, 138, 54, 0.25);
  border-radius: 10px;
  padding: 7px 11px;
}

.m-card .add {
  margin-top: auto;
}

/* feature card (e.g. lone premium entree) spans full width, image beside text */
.m-card.feature {
  grid-column: 1 / -1;
  flex-direction: row;
}
.m-card.feature .m-card-img {
  width: 44%;
  aspect-ratio: auto;
  min-height: 260px;
  flex: none;
}
.m-card.feature .m-card-body {
  justify-content: center;
  padding: 28px 32px;
}
.m-card.feature h3 {
  font-size: 1.5rem;
}

/* ---------------- Responsive ---------------- */
@media (max-width: 900px) {
  .m-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 600px) {
  .m-grid,
  .m-grid.tight {
    grid-template-columns: 1fr;
  }
  .m-card.feature {
    flex-direction: column;
  }
  .m-card.feature .m-card-img {
    width: 100%;
    aspect-ratio: 16 / 10;
    min-height: 0;
  }
  .switch-bar .world-switch {
    width: 100%;
    justify-content: space-between;
  }
}

@media (prefers-reduced-motion: reduce) {
  .m-card,
  .m-card-img img,
  .choice,
  .world-switch button {
    transition: none !important;
  }
}
