/* =========================================================
   LUXIMO-STYLE THEME (THEME 5 - MINIMAL BISTRO / QUIET LUXURY)
   Design System & Modern Aesthetic Stylesheet
   ========================================================= */

:root {
  /* Dynamic tokens populated via applyCustomTheme */
  --color-primary: #D4AF37;
  --color-primary-rgb: 212, 175, 55;
  --color-accent: #B38F24;
  --color-accent-rgb: 179, 143, 36;
  --color-chef-badge: #F59E0B;
  --color-chef-badge-rgb: 245, 158, 11;
  --color-theme-bg: #D4AF37;
  --btn-radius: 14px;
  --card-radius: 28px;
  --logo-radius: 50%;

  /* Light Mode Palette: Warm linen, ivory, and soft stone */
  --bg-page: #F7F6F2;
  --bg-surface: #FFFFFF;
  --bg-card: #FFFFFF;
  --bg-elevated: #F0EFEA;
  --text-main: #141517;
  --text-muted: #6B7280;
  --border-subtle: rgba(0, 0, 0, 0.08);
  --border-card: rgba(0, 0, 0, 0.06);
  --header-bg: rgba(247, 246, 242, 0.88);
  --scrim-base: rgba(0, 0, 0, 0.94);
  --shadow-card: 0 10px 30px -10px rgba(0, 0, 0, 0.06);
  --shadow-elevated: 0 20px 40px -12px rgba(0, 0, 0, 0.12);
}

html.dark {
  /* Dark Mode Palette: Deep obsidian basalt */
  --bg-page: #0C0D0E;
  --bg-surface: #141518;
  --bg-card: #18191D;
  --bg-elevated: #202227;
  --text-main: #F3F4F6;
  --text-muted: #9CA3AF;
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-card: rgba(255, 255, 255, 0.08);
  --header-bg: rgba(12, 13, 14, 0.88);
  --scrim-base: rgba(0, 0, 0, 0.95);
  --shadow-card: 0 10px 30px -10px rgba(0, 0, 0, 0.45);
  --shadow-elevated: 0 24px 50px -12px rgba(0, 0, 0, 0.7);
}

/* Brand Theme Mode: Ambient tones derived mathematically via theme.js */
html.theme-brand {
  --bg-page: var(--bg-main, #000505);
  --bg-surface: var(--bg-surface, rgba(14, 27, 27, 0.92));
  --bg-card: var(--bg-card, rgba(18, 38, 38, 0.92));
  --bg-elevated: var(--bg-surface, rgba(22, 48, 48, 0.92));
  --header-bg: rgba(10, 20, 20, 0.88);
  --border-subtle: var(--border-subtle, rgba(255, 255, 255, 0.12));
  --border-card: var(--border-subtle, rgba(255, 255, 255, 0.12));
  --text-main: #FFFFFF;
  --text-muted: rgba(255, 255, 255, 0.72);
}

/* Dynamic wallpaper blur overlay in brand mode driven by admin bgBlur and theme-bg-color */
html.theme-brand #lux-bg-overlay,
html.theme-brand .fixed.inset-0 > div:last-child {
  background-image: none !important;
  background: rgba(0, 0, 0, 0.22) !important;
  backdrop-filter: blur(var(--bg-blur, 0px)) !important;
  -webkit-backdrop-filter: blur(var(--bg-blur, 0px)) !important;
}

#lux-bg-overlay {
  backdrop-filter: blur(var(--bg-blur, 0px)) !important;
  -webkit-backdrop-filter: blur(var(--bg-blur, 0px)) !important;
}

/* Category Parent Card Icons in Brand Theme: Ensure icons without custom color use brand primary and translucent glass circle */
html.theme-brand .w-14.h-14.rounded-full.bg-gray-100:not([style*="background-color"]),
html.theme-brand .w-14.h-14.rounded-full:not([style*="background-color"]):not(.overflow-hidden) {
  background-color: rgba(255, 255, 255, 0.08) !important;
  color: var(--color-primary, #d4af37) !important;
  box-shadow: inset 0 0 12px rgba(255, 255, 255, 0.05), 0 0 15px color-mix(in srgb, var(--color-primary, #d4af37) 20%, transparent) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
}

html.theme-brand .w-14.h-14.rounded-full:not([style*="background-color"]) i {
  color: var(--color-primary, #d4af37) !important;
}

/* Typography & Base */
body {
  font-family: 'IRANYekanX', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background-color: var(--bg-page);
  color: var(--text-main);
  transition: background-color 0.35s ease, color 0.35s ease;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overflow-x: hidden;
  padding-bottom: 6rem;
}

/* Smooth Scrollbars */
::-webkit-scrollbar {
  width: 5px;
  height: 5px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: rgba(125, 125, 125, 0.25);
  border-radius: 9999px;
}

/* Glass Box Container (Header, Modals, Category Cards) */
.glass-box {
  background: var(--bg-surface, rgba(255, 255, 255, 0.92));
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-subtle, rgba(0, 0, 0, 0.08));
  box-shadow: var(--shadow-card, 0 10px 30px -10px rgba(0, 0, 0, 0.06));
  border-radius: var(--card-radius, 28px);
}

html.dark .glass-box {
  background: var(--bg-surface, rgba(20, 21, 24, 0.88));
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.08));
  box-shadow: var(--shadow-card, 0 10px 30px -10px rgba(0, 0, 0, 0.45));
}

html.theme-brand .glass-box {
  background: rgba(0, 0, 0, 0.45) !important;
  backdrop-filter: blur(20px) !important;
  -webkit-backdrop-filter: blur(20px) !important;
  border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.12)) !important;
  box-shadow: 0 14px 40px -10px rgba(0, 0, 0, 0.5) !important;
}

/* Category Navigation Bar & Buttons */
.sticky-nav {
  position: -webkit-sticky;
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--header-bg, rgba(247, 246, 242, 0.9));
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-subtle, rgba(0, 0, 0, 0.08));
}

html.dark .sticky-nav {
  background: var(--header-bg, rgba(12, 13, 14, 0.9));
  border-bottom: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.08));
}

/* ==================== CATEGORY NAVIGATION BAR ==================== */
/* Completely transparent container so the categories section has no background bar */
.sticky-nav,
html.dark .sticky-nav,
html.theme-brand .sticky-nav {
  position: sticky;
  top: 0;
  z-index: 40;
  background: transparent !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  border: none !important;
  border-bottom: none !important;
  box-shadow: none !important;
}

/* Tab Buttons */
.tab-btn {
  outline: none;
  cursor: pointer;
  padding: 0.55rem 1.15rem;
  font-family: inherit;
  font-weight: 800;
  font-size: 0.85rem;
  border-radius: var(--btn-radius, 14px) !important;
  white-space: nowrap;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border: 1px solid transparent;
  flex-shrink: 0;
}

.tab-btn span {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

/* Inactive Tab Pill - Solid, non-transparent capsule with high contrast */
.tab-btn.normal-tab:not(.active) {
  background: #FFFFFF !important;
  color: #1F2937 !important;
  border: 1px solid rgba(0, 0, 0, 0.12) !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08) !important;
  font-weight: 700;
}

.tab-btn.normal-tab:hover:not(.active) {
  background: #F3F4F6 !important;
  color: #111827 !important;
  border-color: rgba(0, 0, 0, 0.2) !important;
}

html.dark .tab-btn.normal-tab:not(.active) {
  background: #1C1E22 !important;
  color: #F3F4F6 !important;
  border: 1px solid rgba(255, 255, 255, 0.16) !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.45) !important;
  font-weight: 700;
}

html.dark .tab-btn.normal-tab:hover:not(.active) {
  background: #2A2D33 !important;
  color: #FFFFFF !important;
  border-color: rgba(255, 255, 255, 0.28) !important;
}

html.theme-brand .tab-btn.normal-tab:not(.active) {
  background: var(--bg-card, #122B2B) !important;
  color: #FFFFFF !important;
  border: 1px solid rgba(255, 255, 255, 0.25) !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35) !important;
  opacity: 1 !important;
  font-weight: 700;
}

html.theme-brand .tab-btn.normal-tab:hover:not(.active) {
  background: var(--bg-surface, #1A3838) !important;
  border-color: rgba(255, 255, 255, 0.4) !important;
}

/* Active Tab Pill */
.tab-btn.normal-tab.active,
html.dark .tab-btn.normal-tab.active,
html.theme-brand .tab-btn.normal-tab.active {
  color: #000000 !important;
  background: var(--color-primary) !important;
  border-color: var(--color-primary) !important;
  box-shadow: 0 4px 16px rgba(var(--color-primary-rgb), 0.45) !important;
  font-weight: 900 !important;
  transform: translateY(-1px);
}

.tab-btn.normal-tab.active span,
html.dark .tab-btn.normal-tab.active span,
html.theme-brand .tab-btn.normal-tab.active span {
  color: #000000 !important;
}

/* Special Chef Tab */
.tab-btn.special-tab:not(.active) {
  background: #FFFFFF !important;
  border: 1.5px solid rgba(var(--color-primary-rgb), 0.6) !important;
  color: var(--color-primary) !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08) !important;
}

html.dark .tab-btn.special-tab:not(.active) {
  background: #1C1E22 !important;
  border: 1.5px solid rgba(var(--color-primary-rgb), 0.6) !important;
  color: var(--color-primary) !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4) !important;
}

.tab-btn.special-tab.active,
html.dark .tab-btn.special-tab.active,
html.theme-brand .tab-btn.special-tab.active {
  background: var(--color-primary) !important;
  color: #000000 !important;
  border-color: var(--color-primary) !important;
  box-shadow: 0 6px 20px -2px rgba(var(--color-primary-rgb), 0.6) !important;
  font-weight: 900 !important;
  transform: translateY(-1px);
}

.tab-btn.special-tab.active span,
html.dark .tab-btn.special-tab.active span,
html.theme-brand .tab-btn.special-tab.active span {
  color: #000000 !important;
}

/* Daily Special Tab */
.tab-btn.daily-special-tab:not(.active) {
  background: #FFFFFF !important;
  border: 1.5px solid rgba(234, 179, 8, 0.6) !important;
  color: #EAB308 !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08) !important;
}

html.dark .tab-btn.daily-special-tab:not(.active) {
  background: #1C1E22 !important;
  border: 1.5px solid rgba(234, 179, 8, 0.6) !important;
  color: #EAB308 !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4) !important;
}

.tab-btn.daily-special-tab.active,
html.dark .tab-btn.daily-special-tab.active,
html.theme-brand .tab-btn.daily-special-tab.active {
  background: #EAB308 !important;
  color: #000000 !important;
  border-color: #EAB308 !important;
  box-shadow: 0 6px 20px -2px rgba(234, 179, 8, 0.6) !important;
  font-weight: 900 !important;
  transform: translateY(-1px);
}

.tab-btn.daily-special-tab.active span,
html.dark .tab-btn.daily-special-tab.active span,
html.theme-brand .tab-btn.daily-special-tab.active span {
  color: #000000 !important;
}

/* Favorites Tab */
.tab-btn.special-fav-tab:not(.active) {
  background: #FFFFFF !important;
  border: 1.5px solid rgba(244, 63, 94, 0.6) !important;
  color: #F43F5E !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08) !important;
}

html.dark .tab-btn.special-fav-tab:not(.active) {
  background: #1C1E22 !important;
  border: 1.5px solid rgba(244, 63, 94, 0.6) !important;
  color: #F43F5E !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4) !important;
}

.tab-btn.special-fav-tab.active,
html.dark .tab-btn.special-fav-tab.active,
html.theme-brand .tab-btn.special-fav-tab.active {
  background: #F43F5E !important;
  color: #FFFFFF !important;
  border-color: #F43F5E !important;
  box-shadow: 0 6px 20px -2px rgba(244, 63, 94, 0.6) !important;
  font-weight: 900 !important;
  transform: translateY(-1px);
}

.tab-btn.special-fav-tab.active span,
html.dark .tab-btn.special-fav-tab.active span,
html.theme-brand .tab-btn.special-fav-tab.active span {
  color: #FFFFFF !important;
}


/* Scrollbar Hiding Utility */
.hide-scrollbar::-webkit-scrollbar {
  display: none !important;
  width: 0 !important;
  height: 0 !important;
}

.hide-scrollbar {
  -ms-overflow-style: none !important;
  scrollbar-width: none !important;
}

/* Buttons */
.btn-modern {
  background: var(--color-primary) !important;
  color: #000000 !important;
  font-weight: 900;
  border-radius: var(--btn-radius, 14px) !important;
  box-shadow: 0 4px 14px -2px rgba(var(--color-primary-rgb), 0.45);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  white-space: nowrap;
}

.btn-modern:hover {
  background: var(--color-accent) !important;
  transform: translateY(-1px) scale(1.02);
  box-shadow: 0 6px 20px -2px rgba(var(--color-primary-rgb), 0.6);
}

.btn-modern:active {
  transform: scale(0.95);
}

.btn-modern * {
  color: #000000 !important;
}

.shadow-btn {
  box-shadow: 0 6px 18px -3px rgba(var(--color-primary-rgb), 0.4);
}

.btn-circle-add {
  border-radius: 50% !important;
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-primary);
  color: #000000;
  box-shadow: 0 4px 14px -2px rgba(var(--color-primary-rgb), 0.45);
  transition: all 0.2s ease;
}

.btn-circle-add:hover {
  background: var(--color-accent);
  transform: scale(1.05);
}

.btn-circle-add:active {
  transform: scale(0.92);
}

/* Floating Bottom Cart Bar */
#cart-bar {
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

#cart-bar.show {
  transform: translateY(0) !important;
}

/* Profile Modal Tabs */
.profile-tab-btn {
  transition: all 0.25s ease;
  border: 1px solid transparent;
}

.profile-tab-btn.active {
  background-color: var(--color-primary) !important;
  color: #000000 !important;
  font-weight: 900;
  box-shadow: 0 4px 14px rgba(var(--color-primary-rgb), 0.4);
}

/* Special Items & Chef Badges */
.star-badge {
  font-size: 1.2rem;
  color: var(--color-chef-badge, var(--color-primary));
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
  animation: star-pulse 2.5s ease-in-out infinite;
  z-index: 20;
}

.daily-fire-badge {
  color: #EAB308;
  font-size: 1.35rem !important;
  animation: fire-pulse-yellow 2s infinite alternate ease-in-out;
  z-index: 20;
}

@keyframes star-pulse {
  0%, 100% {
    transform: scale(1);
    filter: drop-shadow(0 0 2px rgba(var(--color-chef-badge-rgb), 0.5));
  }
  50% {
    transform: scale(1.2);
    filter: drop-shadow(0 0 8px rgba(var(--color-chef-badge-rgb), 0.8));
  }
}

@keyframes fire-pulse-yellow {
  0% {
    transform: scale(1);
    filter: drop-shadow(0 0 3px rgba(234, 179, 8, 0.5));
  }
  100% {
    transform: scale(1.2);
    filter: drop-shadow(0 0 10px rgba(250, 204, 21, 0.8));
    color: #FACC15;
  }
}

.special-card {
  position: relative;
  z-index: 1;
  overflow: hidden;
  border: 2px solid var(--color-chef-badge, var(--color-primary)) !important;
  border-radius: var(--card-radius, 28px) !important;
}

.daily-special-card {
  position: relative;
  z-index: 1;
  overflow: hidden;
  border: 2px solid #EAB308 !important;
  border-radius: var(--card-radius, 28px) !important;
}

/* Animations */
@keyframes luxFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
}

.animate-float {
  animation: luxFloat 4s ease-in-out infinite;
}

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

.animate-slide-up {
  animation: luxSlideUp 0.35s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes luxFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.animate-fade-in {
  animation: luxFadeIn 0.3s ease both;
}

/* =========================================================
   CINEMATIC PROGRESSIVE BLUR FOOD CARD
   ========================================================= */
.lux-cinematic-card {
  position: relative;
  height: 380px;
  width: 100%;
  border-radius: var(--card-radius);
  overflow: hidden;
  background-color: #121316;
  box-shadow: var(--shadow-card);
  border: 1px solid var(--border-card);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.4s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.35s ease;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.lux-cinematic-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-elevated), 0 0 0 1px rgba(var(--color-primary-rgb), 0.35);
  border-color: rgba(var(--color-primary-rgb), 0.5);
}

/* Food Photo Layer */
.lux-card-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 1;
}

.lux-cinematic-card:hover .lux-card-img {
  transform: scale(1.05);
}

/* Multi-stop Optical Scrim Gradient */
.lux-card-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    var(--scrim-base) 0%,
    rgba(0, 0, 0, 0.84) 28%,
    rgba(0, 0, 0, 0.52) 55%,
    rgba(0, 0, 0, 0.16) 75%,
    transparent 100%
  );
  z-index: 2;
  pointer-events: none;
}

/* True CSS Progressive Blur */
.lux-card-blur {
  position: absolute;
  inset: auto 0 0 0;
  height: 64%;
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  mask-image: linear-gradient(to top, black 45%, transparent 100%);
  -webkit-mask-image: linear-gradient(to top, black 45%, transparent 100%);
  z-index: 3;
  pointer-events: none;
}

/* Overlay Content Container */
.lux-card-content {
  position: relative;
  z-index: 4;
  padding: 1.25rem 1.25rem 1.15rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  width: 100%;
}

/* Force pure white with deep drop shadows so titles & descriptions are 100% readable across all photos and light/dark modes */
.lux-card-content h3,
.lux-cinematic-card h3 {
  color: #FFFFFF !important;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.9) !important;
}

.lux-card-content p,
.lux-cinematic-card p,
.lux-card-desc {
  color: rgba(255, 255, 255, 0.85) !important;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8) !important;
}

/* Floating Badges */
.lux-card-badges {
  position: absolute;
  top: 1rem;
  right: 1rem;
  left: 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 5;
  pointer-events: none;
}

.lux-badge-chef {
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(var(--color-chef-badge-rgb), 0.5);
  color: var(--color-chef-badge);
  font-size: 0.7rem;
  font-weight: 800;
  padding: 0.3rem 0.65rem;
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.lux-badge-discount {
  background: #EF4444;
  color: #FFFFFF;
  font-size: 0.72rem;
  font-weight: 900;
  padding: 0.25rem 0.55rem;
  border-radius: 9999px;
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.45);
}

/* Action Bar: Price on Right, Button on Left (RTL Flow) */
.lux-action-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding-top: 0.6rem;
  margin-top: 0.25rem;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

/* Action Button (Add / Counter) */
.lux-add-btn {
  background: var(--color-primary);
  color: #000000;
  font-weight: 900;
  font-size: 0.85rem;
  border-radius: var(--btn-radius);
  padding: 0.55rem 1.15rem;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  border: none;
  cursor: pointer;
  box-shadow: 0 6px 18px -3px rgba(var(--color-primary-rgb), 0.5);
  transition: all 0.25s ease;
  white-space: nowrap;
}

.lux-add-btn:hover {
  background: var(--color-accent);
  transform: scale(1.03);
  box-shadow: 0 8px 24px -2px rgba(var(--color-primary-rgb), 0.65);
}

.lux-add-btn:active {
  transform: scale(0.96);
}

/* Quantity Pill */
.lux-qty-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  background: rgba(0, 0, 0, 0.7);
  border: 1px solid rgba(var(--color-primary-rgb), 0.55);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: var(--btn-radius);
  padding: 0.25rem 0.5rem;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

.lux-qty-btn {
  width: 30px;
  height: 30px;
  border-radius: calc(var(--btn-radius) - 4px);
  background: rgba(255, 255, 255, 0.12);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
}

.lux-qty-btn:hover {
  background: var(--color-primary);
  color: #000000;
}

.lux-qty-val {
  font-size: 0.95rem;
  font-weight: 900;
  color: #FFFFFF;
  min-width: 1.2rem;
  text-align: center;
}

/* Floating Bottom Cart Bar */
.lux-floating-cart {
  position: fixed;
  bottom: 1.25rem;
  left: 1rem;
  right: 1rem;
  max-width: 520px;
  margin: 0 auto;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--card-radius);
  box-shadow: 0 16px 36px -8px rgba(0, 0, 0, 0.25);
  padding: 0.85rem 1.15rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 50;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  transform: translateY(120%);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.lux-floating-cart.visible {
  transform: translateY(0);
}

/* Bottom Sheet Modals */
.lux-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 90;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.lux-modal-backdrop.active {
  opacity: 1;
  pointer-events: auto;
}

.lux-bottom-sheet {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  max-width: 640px;
  margin: 0 auto;
  background: var(--bg-surface);
  border-top-left-radius: 32px;
  border-top-right-radius: 32px;
  border: 1px solid var(--border-subtle);
  border-bottom: none;
  box-shadow: 0 -20px 50px rgba(0, 0, 0, 0.4);
  z-index: 100;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  transform: translateY(100%);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.lux-bottom-sheet.active {
  transform: translateY(0);
}

.lux-sheet-handle {
  width: 44px;
  height: 5px;
  border-radius: 9999px;
  background: rgba(125, 125, 125, 0.3);
  margin: 0.75rem auto 0.25rem auto;
  cursor: grab;
}

/* Floating Action Button (Call Waiter) */
.lux-fab-waiter {
  position: fixed;
  bottom: 1.5rem;
  right: 1.25rem;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.2);
  cursor: pointer;
  z-index: 45;
  transition: transform 0.25s ease, background 0.25s ease;
}

.lux-fab-waiter:hover {
  transform: scale(1.1);
  background: var(--bg-elevated);
}

/* Animations */
@keyframes fadeInSlideUp {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-enter {
  animation: fadeInSlideUp 0.45s cubic-bezier(0.16, 1, 0.3, 1) both;
}

/* ==================== ACTIVE PARENT CATEGORY BADGE ==================== */
/* Parent category pill when viewing subcategories */
.active-parent-badge {
  background: rgba(var(--color-primary-rgb), 0.12);
  color: var(--color-primary);
  border: 1px solid rgba(var(--color-primary-rgb), 0.25);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

html.dark .active-parent-badge {
  background: rgba(var(--color-primary-rgb), 0.2);
  color: var(--color-primary);
  border: 1px solid rgba(var(--color-primary-rgb), 0.4);
}

/* In brand theme, surface is already dark/brand background; make badge high-contrast white frosted glass */
html.theme-brand .active-parent-badge {
  background: rgba(255, 255, 255, 0.18) !important;
  color: #FFFFFF !important;
  border: 1px solid rgba(255, 255, 255, 0.35) !important;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25) !important;
}

html.theme-brand .active-parent-badge span,
html.theme-brand .active-parent-badge i,
html.theme-brand .active-parent-badge [class*="text-primary"],
html.theme-brand .active-parent-badge div {
  color: #FFFFFF !important;
}

/* ==================== FOOTER STYLING ==================== */
.lux-footer {
  margin-top: auto;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid var(--border-subtle, rgba(0, 0, 0, 0.08));
  padding-top: 2rem;
  padding-bottom: 9rem;
  border-radius: 2.5rem 2.5rem 0 0;
  transition: background 0.35s ease, border-color 0.35s ease;
}

html.dark .lux-footer {
  background: rgba(18, 19, 23, 0.92) !important;
  border-top: 1px solid rgba(255, 255, 255, 0.08) !important;
}

html.theme-brand .lux-footer {
  background: var(--bg-card, rgba(14, 27, 27, 0.92)) !important;
  border-top: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.12)) !important;
  color: #FFFFFF !important;
}

/* Footer social buttons */
.lux-footer-btn {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.04);
  color: var(--text-muted, #6B7280);
  border: 1px solid rgba(0, 0, 0, 0.06);
  transition: all 0.2s ease;
}

html.dark .lux-footer-btn {
  background: rgba(255, 255, 255, 0.06) !important;
  color: rgba(255, 255, 255, 0.75) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
}

html.theme-brand .lux-footer-btn {
  background: rgba(255, 255, 255, 0.1) !important;
  color: #FFFFFF !important;
  border: 1px solid rgba(255, 255, 255, 0.18) !important;
}

.lux-footer-divider {
  border-top: 1px dashed rgba(0, 0, 0, 0.1);
  border-bottom: 1px dashed rgba(0, 0, 0, 0.1);
}

html.dark .lux-footer-divider {
  border-top: 1px dashed rgba(255, 255, 255, 0.1) !important;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.1) !important;
}

html.theme-brand .lux-footer-divider {
  border-top: 1px dashed rgba(255, 255, 255, 0.15) !important;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.15) !important;
}

html.dark .lux-footer p,
html.dark .lux-footer span {
  color: rgba(243, 244, 246, 0.85);
}

html.theme-brand .lux-footer p,
html.theme-brand .lux-footer span {
  color: rgba(255, 255, 255, 0.85);
}

/* =========================================================
   LOYALTY MODAL — Dark Mode Overrides
   (Tailwind dark: utilities have no effect without a build;
    these rules replicate what dark:bg-[#16171B] etc. intend)
   ========================================================= */

html.dark #loyalty-bottom-sheet {
  background-color: #16171B !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
}

/* Inputs inside loyalty modal */
html.dark #loyalty-bottom-sheet input[type="tel"],
html.dark #loyalty-bottom-sheet input[type="number"],
html.dark #loyalty-bottom-sheet input[type="text"] {
  background-color: rgba(0, 0, 0, 0.30) !important;
  border-color: rgba(255, 255, 255, 0.10) !important;
  color: #F3F4F6 !important;
}

/* Heading text */
html.dark #loyalty-bottom-sheet h3 {
  color: #FFFFFF !important;
}

/* Close button */
html.dark #loyalty-modal-close {
  background-color: rgba(127, 29, 29, 0.30) !important;
}

html.dark #loyalty-modal-close:hover {
  background-color: rgba(127, 29, 29, 0.50) !important;
}

/* Copy button inside bank modal (same pattern) */
html.dark #bank-modal-content .bg-white {
  background-color: #1F2937 !important;
}

/* =========================================================
   PROFILE MODAL — Dark Mode Overrides
   ========================================================= */

html.dark #profile-modal-content {
  background-color: #16171B !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
}

/* Header border */
html.dark #profile-modal-content .border-b {
  border-color: rgba(255, 255, 255, 0.08) !important;
}

/* Title text */
html.dark #profile-modal-content h3 {
  color: #FFFFFF !important;
}

/* Close button */
html.dark #profile-modal-content > div > button {
  background-color: rgba(255, 255, 255, 0.08) !important;
}

/* Inactive tab buttons (dynamically set by switchProfileTab) */
html.dark .profile-tab-btn:not(.active) {
  background-color: rgba(255, 255, 255, 0.06) !important;
  color: rgba(255, 255, 255, 0.7) !important;
}

/* Order / fav card backgrounds (rendered via JS innerHTML) */
html.dark #profile-tab-history .bg-gray-50,
html.dark #profile-tab-favs .bg-gray-50,
html.dark #profile-tab-history > div > div,
html.dark #profile-tab-favs > div > div {
  background-color: rgba(0, 0, 0, 0.25) !important;
  border-color: rgba(255, 255, 255, 0.07) !important;
}

/* Item badges inside history */
html.dark #profile-tab-history .bg-white {
  background-color: #1F2937 !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
}

/* Info tab inputs */
html.dark #profile-tab-info input,
html.dark #profile-tab-info textarea {
  background-color: rgba(0, 0, 0, 0.25) !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
  color: #F3F4F6 !important;
}

html.dark #profile-tab-info input[readonly] {
  background-color: rgba(0, 0, 0, 0.40) !important;
  opacity: 0.6;
}

/* Brand theme styling for soft-bg buttons to avoid washed out light-blue appearance on dark canvas */
html.theme-brand .soft-bg-blue,
html.theme-brand button[onclick*="shareItem"] {
  background-color: rgba(59, 130, 246, 0.2) !important;
  border: 1px solid rgba(59, 130, 246, 0.35) !important;
  color: #ffffff !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;
}

html.theme-brand .soft-bg-blue:hover,
html.theme-brand button[onclick*="shareItem"]:hover {
  background-color: rgba(59, 130, 246, 0.35) !important;
  border-color: rgba(59, 130, 246, 0.5) !important;
  color: #ffffff !important;
}

html.theme-brand .soft-bg-blue .mask-icon,
html.theme-brand button[onclick*="shareItem"] .mask-icon {
  background-color: #ffffff !important;
  opacity: 0.95 !important;
}

html.theme-brand .soft-bg-red {
  background-color: rgba(239, 68, 68, 0.2) !important;
  border: 1px solid rgba(239, 68, 68, 0.35) !important;
  color: #ffffff !important;
}

html.theme-brand .soft-bg-green {
  background-color: rgba(34, 197, 94, 0.2) !important;
  border: 1px solid rgba(34, 197, 94, 0.35) !important;
  color: #ffffff !important;
}


