:root {
  --yellow: #fcf926;
  --yellow-deep: #e6e321;
  --yellow-soft: rgba(252, 249, 38, 0.35);
  --ink: #080503;
  --paper: #fffef8;
  --card: #ffffff;
  --muted: #5c534c;
  --radius: 14px;
  --shadow: 0 8px 28px rgba(8, 5, 3, 0.12);
  --tab-radius: 8px;
  --sticky-offset: clamp(8rem, 18vh, 10.5rem);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Noto Nastaliq Urdu", "Segoe UI", Tahoma, sans-serif;
  background: var(--paper);
  color: var(--ink);
  line-height: 1.55;
  min-height: 100vh;
}

.sticky-stack {
  position: sticky;
  top: 0;
  z-index: 40;
  box-shadow: 0 6px 24px rgba(8, 5, 3, 0.12);
}

.site-header {
  background: linear-gradient(165deg, var(--yellow) 0%, var(--yellow-deep) 100%);
  color: var(--ink);
  padding: 0.55rem 0.75rem 0.65rem;
  text-align: center;
  border-bottom: 3px solid var(--ink);
}

.site-logo {
  display: block;
  margin: 0 auto;
  max-width: min(72px, 22vw);
  height: auto;
  object-fit: contain;
}

.brand {
  margin: 0.35rem 0 0;
  font-size: clamp(1.05rem, 3.2vw, 1.35rem);
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1.25;
}

.category-nav {
  background: var(--paper);
  border-bottom: 1px solid rgba(8, 5, 3, 0.08);
  padding: 0.55rem 0.5rem;
}

.category-nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  gap: 0.375rem;
  overflow-x: auto;
  padding: 0.125rem 0 4px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}

.category-nav-inner::-webkit-scrollbar {
  height: 4px;
}

.category-nav-inner::-webkit-scrollbar-thumb {
  background: var(--yellow-deep);
  border-radius: 4px;
}

.cat-btn {
  flex: 0 0 auto;
  font-family: inherit;
  padding: 0.4rem 0.72rem;
  border-radius: var(--tab-radius);
  border: 1px solid rgba(8, 5, 3, 0.14);
  background: var(--card);
  color: var(--ink);
  cursor: pointer;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: 1.35;
  white-space: nowrap;
  box-shadow: 0 1px 2px rgba(8, 5, 3, 0.06);
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease,
    box-shadow 0.18s ease;
}

.cat-btn:hover {
  background: rgba(252, 249, 38, 0.22);
  border-color: rgba(8, 5, 3, 0.22);
  box-shadow: 0 2px 6px rgba(8, 5, 3, 0.08);
}

.cat-btn:focus-visible {
  outline: 2px solid var(--yellow-deep);
  outline-offset: 2px;
}

.cat-btn.is-active {
  background: var(--ink);
  color: var(--yellow);
  border-color: var(--ink);
  box-shadow: 0 2px 8px rgba(8, 5, 3, 0.15);
}

.menu-main {
  max-width: 1100px;
  margin: 0 auto;
  padding: 1.25rem 1rem 3rem;
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.menu-section {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.menu-section__anchor {
  flex: 0 0 auto;
}

.menu-section__title {
  margin: 0;
  padding: 0.1rem 0 0.35rem;
  font-size: clamp(1.08rem, 2.8vw, 1.28rem);
  font-weight: 700;
  color: var(--ink);
  text-align: right;
  letter-spacing: 0.02em;
  border-bottom: 2px solid rgba(8, 5, 3, 0.12);
  box-shadow: 0 1px 0 var(--yellow-soft);
}

.menu-card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  direction: rtl;
  border: 1px solid rgba(8, 5, 3, 0.08);
}

.menu-card--first {
  scroll-margin-top: var(--sticky-offset);
}

.menu-card__name {
  padding: 1rem 1.25rem 0.75rem;
  text-align: right;
  width: 100%;
}

.menu-card__title {
  margin: 0;
  font-size: clamp(1.15rem, 3vw, 1.45rem);
  font-weight: 700;
  color: var(--ink);
  line-height: 1.35;
}

.menu-card__image-wrap {
  width: 100%;
  flex: 0 0 auto;
  aspect-ratio: 16 / 10;
  min-height: 180px;
  max-height: 320px;
  background: var(--card);
  display: flex;
  align-items: stretch;
  overflow: hidden;
}

.menu-card__image {
  width: 100%;
  flex: 1 1 auto;
  min-height: 0;
  object-fit: cover;
  object-position: center;
  display: block;
}

.menu-card__meta {
  width: 100%;
  padding: 1rem 1.25rem 1.25rem;
  text-align: right;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  gap: 0.75rem;
  flex: 1 1 auto;
}

.menu-card__details {
  margin: 0;
  font-size: 0.95rem;
  color: var(--muted);
  white-space: pre-line;
  line-height: 1.65;
}

.menu-card__details.is-empty {
  display: none;
}

.menu-card__price {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: 0.02em;
  align-self: flex-start;
  margin-top: 0.15rem;
}

@media (max-width: 768px) {
  .menu-card__image-wrap {
    aspect-ratio: 4 / 3;
    min-height: 200px;
    max-height: none;
  }
}

.site-footer {
  text-align: center;
  padding: 1.5rem 1rem;
  font-size: 0.9rem;
  color: var(--muted);
  border-top: 3px solid var(--yellow);
  background: #faf8ee;
}
