:root {
  --ink: #14110f;
  --ash: #2a2420;
  --smoke: #3d342e;
  --wheat: #e8b84a;
  --ember: #c45c26;
  --clay: #8b3a1a;
  --pine: #2f4a3c;
  --pine-deep: #1a2e24;
  --mist: #d9d2c5;
  --cream-text: #f4efe6;
  --muted: #b8aea0;
  --line: rgba(232, 184, 74, 0.28);
  --font-display: "El Messiri", "Georgia", serif;
  --font-body: "Manrope", "Helvetica Neue", sans-serif;
  --radius: 4px;
  --max: 1100px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--cream-text);
  background: var(--ink);
  line-height: 1.55;
  min-height: 100vh;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

.site-bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(1200px 700px at 10% -10%, rgba(47, 74, 60, 0.45), transparent 60%),
    radial-gradient(900px 600px at 100% 0%, rgba(196, 92, 38, 0.28), transparent 55%),
    linear-gradient(180deg, #1a1512 0%, #14110f 40%, #0f1612 100%);
}

.site-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.07;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  pointer-events: none;
}

.wrap {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

/* Header */
.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(12px);
  background: rgba(20, 17, 15, 0.78);
  border-bottom: 1px solid rgba(232, 184, 74, 0.12);
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.brand img {
  width: 44px;
  height: 44px;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.brand-text strong {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.brand-text span {
  font-size: 0.78rem;
  color: var(--muted);
}

.lang-toggle {
  border: 1px solid var(--line);
  background: transparent;
  color: var(--cream-text);
  font-family: var(--font-body);
  font-size: 0.85rem;
  padding: 0.45rem 0.8rem;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.lang-toggle:hover {
  background: rgba(232, 184, 74, 0.1);
  border-color: var(--wheat);
}

/* Hero */
.hero {
  position: relative;
  min-height: min(92vh, 760px);
  display: grid;
  align-items: end;
  overflow: hidden;
}

.hero-media {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(20, 17, 15, 0.25) 0%, rgba(20, 17, 15, 0.55) 45%, rgba(20, 17, 15, 0.96) 100%),
    radial-gradient(ellipse at 50% 30%, rgba(232, 184, 74, 0.18), transparent 50%),
    url("../img/hero-pattern.svg") center/cover no-repeat,
    linear-gradient(135deg, var(--pine-deep), var(--ink) 50%, var(--clay));
  transform: scale(1.04);
  animation: heroDrift 18s ease-in-out infinite alternate;
}

@keyframes heroDrift {
  from { transform: scale(1.04) translateY(0); }
  to { transform: scale(1.08) translateY(-1.5%); }
}

.hero-content {
  position: relative;
  z-index: 1;
  padding: 5rem 0 3.5rem;
}

.hero-mark {
  width: 88px;
  height: 88px;
  margin-bottom: 1.25rem;
  animation: fadeUp 0.9s ease both;
}

.hero h1 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.6rem, 8vw, 4.8rem);
  line-height: 1.05;
  letter-spacing: 0.01em;
  animation: fadeUp 0.9s ease 0.08s both;
}

.hero h1 .ar {
  display: block;
  font-size: 0.55em;
  color: var(--wheat);
  margin-top: 0.35rem;
}

.hero-tagline {
  margin: 1rem 0 0;
  max-width: 28rem;
  font-size: 1.05rem;
  color: var(--mist);
  animation: fadeUp 0.9s ease 0.16s both;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.75rem;
  animation: fadeUp 0.9s ease 0.24s both;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.85rem 1.35rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  border: 1px solid transparent;
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--wheat);
  color: var(--ink);
}

.btn-primary:hover {
  background: #f0c96a;
}

.btn-ghost {
  border-color: var(--line);
  background: rgba(20, 17, 15, 0.35);
  color: var(--cream-text);
}

.btn-ghost:hover {
  border-color: var(--wheat);
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Category nav */
.cat-nav-wrap {
  position: sticky;
  top: 68px;
  z-index: 30;
  background: rgba(20, 17, 15, 0.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(232, 184, 74, 0.1);
}

.cat-nav {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding: 0.85rem 0;
  scrollbar-width: none;
}

.cat-nav::-webkit-scrollbar {
  display: none;
}

.cat-nav a {
  flex: 0 0 auto;
  padding: 0.55rem 0.95rem;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 0.9rem;
  color: var(--muted);
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.cat-nav a:hover,
.cat-nav a.is-active {
  color: var(--cream-text);
  border-color: var(--line);
  background: rgba(232, 184, 74, 0.08);
}

/* Menu sections */
.menu {
  padding: 2.5rem 0 4rem;
}

.menu-section {
  margin-bottom: 3rem;
  scroll-margin-top: 140px;
}

.section-head {
  margin-bottom: 1.25rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid var(--line);
}

.section-head h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 4vw, 2.3rem);
  font-weight: 700;
}

.section-head .ar-name {
  display: block;
  margin-top: 0.2rem;
  color: var(--wheat);
  font-size: 0.75em;
}

.section-head p {
  margin: 0.45rem 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.menu-list {
  display: grid;
  gap: 0;
}

.menu-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.75rem 1.25rem;
  padding: 1.15rem 0;
  border-bottom: 1px solid rgba(217, 210, 197, 0.08);
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.menu-item.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.menu-item.has-image {
  grid-template-columns: 72px 1fr auto;
  align-items: start;
}

.item-thumb {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: var(--radius);
  border: 1px solid rgba(232, 184, 74, 0.2);
}

.item-main h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 600;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
}

.item-main .ar-name {
  color: var(--mist);
  font-size: 0.92rem;
  font-weight: 500;
}

.item-main p {
  margin: 0.35rem 0 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.badge {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-body);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink);
  background: var(--wheat);
  padding: 0.18rem 0.45rem;
  border-radius: 999px;
}

.item-price {
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--wheat);
  white-space: nowrap;
  padding-top: 0.15rem;
}

/* Featured strip */
.featured {
  padding: 0 0 1rem;
}

.featured h2 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  margin: 0 0 1rem;
}

.featured-rail {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(220px, 260px);
  gap: 0.85rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  scrollbar-width: thin;
}

.featured-card {
  padding: 1rem;
  border: 1px solid var(--line);
  background: linear-gradient(160deg, rgba(47, 74, 60, 0.35), rgba(20, 17, 15, 0.6));
  border-radius: 8px;
  min-height: 140px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.featured-card:hover {
  border-color: var(--wheat);
  transform: translateY(-2px);
}

.featured-card h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.15rem;
}

.featured-card p {
  margin: 0.4rem 0 0;
  color: var(--muted);
  font-size: 0.85rem;
}

.featured-card .price {
  margin-top: 0.85rem;
  color: var(--wheat);
  font-weight: 700;
}

/* Footer */
.site-footer {
  border-top: 1px solid rgba(232, 184, 74, 0.12);
  padding: 2.5rem 0 3rem;
  color: var(--muted);
}

.footer-grid {
  display: grid;
  gap: 1.5rem;
}

.footer-brand {
  font-family: var(--font-display);
  font-size: 1.4rem;
  color: var(--cream-text);
  margin: 0 0 0.35rem;
}

.footer-meta {
  display: grid;
  gap: 0.35rem;
  font-size: 0.92rem;
}

.footer-meta a:hover {
  color: var(--wheat);
}

@media (min-width: 720px) {
  .footer-grid {
    grid-template-columns: 1.2fr 1fr;
    align-items: start;
  }

  .menu-item.has-image {
    grid-template-columns: 88px 1fr auto;
  }

  .item-thumb {
    width: 88px;
    height: 88px;
  }
}

/* Language visibility */
body.lang-en [data-lang="ar"] { display: none !important; }
body.lang-ar [data-lang="en"] { display: none !important; }
body.lang-ar {
  direction: rtl;
}
body.lang-ar .cat-nav,
body.lang-ar .hero-actions,
body.lang-ar .brand {
  direction: rtl;
}

.empty-state {
  padding: 3rem 1rem;
  text-align: center;
  color: var(--muted);
}
