/* Enhanced Menu Styles - Sidebar Layout */

/* Hide navigation arrows */
.navigation-arrows {
  display: none !important;
}

/* Menu Section */
.menu {
  padding: 40px 5px;
  background: #fff;
}

/* Main Menu Container */
.menu-container {
  display: flex;
  gap: 0;
  max-width: 1400px;
  margin: 0 auto;
  min-height: 600px;
  background: #f8f8f8;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

/* Mobile Controls Container */
.mobile-controls {
  display: none;
  padding: 20px;
  background: #fff;
  border-bottom: 1px solid #e0e0e0;
  flex-direction: column;
  gap: 15px;
}

/* Search Container */
.menu-search-container {
  width: 100%;
  display: flex;
  align-items: center;
}

.search-input-wrapper {
  position: relative;
  width: 100%;
}

.menu-search {
  width: 100%;
  padding: 10px 40px 10px 15px;
  border: 2px solid #e0e0e0;
  border-radius: 25px;
  font-size: 14px;
  outline: none;
  transition: all 0.3s ease;
  background-color: #f8f8f8;
}

@media (max-width: 768px) {
  .menu-search {
    padding: 15px 45px 15px 20px;
    border-radius: 12px;
    font-size: 16px;
    background-color: #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  }
}

.menu-search:focus {
  border-color: #c8102e;
  background-color: #fff;
  box-shadow: 0 0 0 3px rgba(200, 16, 46, 0.1);
}

.search-icon {
  position: absolute;
  right: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: #666;
  pointer-events: none;
  font-size: 14px;
}

/* Category Dropdown for Mobile */
.category-dropdown {
  display: none;
  position: relative;
  width: 100%;
}

/* Custom Dropdown Button */
.dropdown-button {
  width: 100%;
  padding: 5px 25px 5px 10px;
  border: 2px solid #e0e0e0;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
  background: linear-gradient(to bottom, #ffffff 0%, #f8f8f8 100%);
  cursor: pointer;
  outline: none;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  text-align: left;
  position: relative;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  color: #333;
  -webkit-tap-highlight-color: transparent;
}

.dropdown-button:hover {
  border-color: #aaa;
  background: #fff;
}

.dropdown-button.active {
  border-color: #c8102e;
  box-shadow: 0 0 0 3px rgba(200, 16, 46, 0.1), 0 4px 12px rgba(0, 0, 0, 0.1);
  background: #fff;
}

.dropdown-button::after {
  content: '';
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
  border-top: 8px solid #666;
  transition: transform 0.3s ease;
}

.dropdown-button.active::after {
  transform: translateY(-50%) rotate(180deg);
  border-top-color: #c8102e;
}

/* Custom Dropdown List */
.dropdown-list {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  margin-top: 5px;
  background: #fff;
  border: 2px solid #e0e0e0;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
  max-height: 300px;
  overflow-y: auto;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.3s ease;
}

.dropdown-list.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-item {
  padding: 15px 20px;
  font-size: 12px;
  font-weight: 500;
  color: #333;
  cursor: pointer;
  transition: all 0.2s ease;
  border-bottom: 1px solid #f0f0f0;
}

.dropdown-item:last-child {
  border-bottom: none;
}

.dropdown-item:hover {
  background: #f8f8f8;
  color: #c8102e;
  padding-left: 25px;
}

.dropdown-item.active {
  background: #c8102e;
  color: #fff;
  font-weight: 600;
}

.dropdown-item.active:hover {
  background: #a00e26;
  color: #fff;
}

/* Custom scrollbar for dropdown */
.dropdown-list::-webkit-scrollbar {
  width: 6px;
}

.dropdown-list::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 3px;
}

.dropdown-list::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 3px;
}

.dropdown-list::-webkit-scrollbar-thumb:hover {
  background: #999;
}

/* Hide the original select */
.category-dropdown select {
  display: none;
}

/* Sidebar Categories */
.menu-sidebar {
  width: 450px;
  background: #fff;
  border-right: 1px solid #e0e0e0;
  padding: 30px 0;
  overflow-y: auto;
  flex-shrink: 0;
  max-height: 100%;
}

/* Custom scrollbar for sidebar */
.menu-sidebar::-webkit-scrollbar {
  width: 6px;
}

.menu-sidebar::-webkit-scrollbar-track {
  background: #f1f1f1;
}

.menu-sidebar::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 3px;
}

.menu-sidebar::-webkit-scrollbar-thumb:hover {
  background: #999;
}

.sidebar-title {
  padding: 0 25px;
  margin-bottom: 20px;
  font-size: 18px;
  font-weight: 700;
  color: #333;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Category Buttons in Sidebar */
.menu-buttons {
  display: flex;
  flex-direction: column;
  gap: 5px;
  margin: 0;
  padding: 0;
}

.menu-button {
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 15px 25px;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
  text-align: left;
  position: relative;
  color: #666;
}

.menu-button:hover {
  background: #f8f8f8;
  color: #000000;
  font-weight: bold;
  transform: translateX(5px);
  box-shadow: none;
}

.menu-button.active-button {
  background: #2c2c2c;
  color: white;
  box-shadow: none;
}

.menu-button.active-button::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: #a00e26;
}

.menu-button::after {
  display: none;
}

/* Menu Content Area */
.menu-content {
  flex: 1;
  padding: 30px;
  overflow-y: auto;
  background: #f8f8f8;
}

/* Category Title */
.category-title {
  font-size: 28px;
  font-weight: 700;
  color: #333;
  margin-bottom: 25px;
  padding-bottom: 15px;
  border-bottom: 2px solid #e0e0e0;
}

/* Enhanced Menu Items Grid */
.menu-items {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
}

/* Enhanced Menu Item Card */
.menu-item {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  position: relative;
  animation: fadeInUp 0.5s ease backwards;
}

.menu-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
}

.menu-item.hidden {
  display: none;
}

/* Item Content */
.item-content {
  padding: 20px;
}

.item-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 2px;
}

.item-name {
  font-size: 20px;
  font-weight: 700;
  color: #333;
  margin: 0;
  flex: 1;
  line-height: 1.3;
}

.item-price {
  font-size: 18px;
  font-weight: 600;
  color: #c8102e;
  white-space: nowrap;
  margin-left: 10px;
}

.item-description {
  font-size: 14px;
  color: #666;
  line-height: 1.6;
  margin: 10px 0;
}

.item-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 15px;
}

.item-tag {
  background: #f0f0f0;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
  color: #666;
}

.item-tag.vegan {
  background: #e8f5e9;
  color: #2e7d32;
}

.item-tag.gluten-free {
  background: #fff3e0;
  color: #e65100;
}

.item-tag.spicy {
  background: #ffebee;
  color: #c62828;
}

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

/* Mobile Responsive Styles */
@media (max-width: 768px) {
  .menu-container {
    flex-direction: column;
    border-radius: 0;
  }
  
  .menu-sidebar {
    display: none;
  }
  
  .mobile-controls {
    display: flex;
  }
  
  .category-dropdown {
    display: block;
  }
  
  .menu-content {
    padding: 0px;
  }
  
  .category-title {
    font-size: 18px;
    margin-bottom: 20px;
  }
  
  .menu-items {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  
  .item-image {
    height: 180px;
  }
  
  .item-name {
    font-size: 18px;
  }
  
  .item-price {
    font-size: 16px;
  }
}

@media (max-width: 480px) {
  .menu-search {
    font-size: 14px;
    padding: 10px 40px 10px 15px;
  }
  
  .item-content {
    padding: 15px;
  }
  
  /* Keep item header as flex row on mobile */
  .item-header {
    flex-direction: row !important;
    align-items: flex-start !important;
    justify-content: space-between !important;
  }
  
  .item-price {
    margin-left: 10px !important;
    margin-top: 0 !important;
  }
}

/* Loading State */
.menu-loading {
  text-align: center;
  padding: 40px;
  color: #666;
}

.menu-loading::after {
  content: '';
  display: inline-block;
  width: 20px;
  height: 20px;
  margin-left: 10px;
  border: 3px solid #f0f0f0;
  border-top-color: #c8102e;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* No Results Message */
.no-results {
  text-align: center;
  padding: 60px 20px;
  color: #666;
}

.no-results i {
  font-size: 48px;
  color: #ddd;
  margin-bottom: 20px;
}

.no-results h3 {
  font-size: 20px;
  margin-bottom: 10px;
  color: #333;
}

.no-results p {
  font-size: 16px;
  color: #999;
}

/* Enhanced Mobile Menu Optimizations */
@media (max-width: 768px) {
  /* Mobile menu controls styling from backup */
  .mobile-menu-controls,
  .mobile-controls {
    display: flex !important;
    flex-direction: row !important;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background-color: #f8f8f8;
    border-bottom: 2px solid #e0e0e0;
    position: sticky;
    top: 85px;
    z-index: 100;
    gap: 15px;
  }
  
  .mobile-menu-controls #menu-search,
  .mobile-controls #menuSearch {
    flex: 1;
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 16px;
    background: #fff;
    transition: all 0.3s ease;
  }
  
  .mobile-menu-controls #menu-search:focus,
  .mobile-controls #menuSearch:focus {
    border-color: #c8102e;
    outline: none;
    box-shadow: 0 0 0 3px rgba(200, 16, 46, 0.1);
  }
  
  .dropdown {
    position: relative;
    min-width: 140px;
  }
  
  .dropbtn {
    background-color: #c8102e;
    color: white;
    padding: 12px 16px;
    font-size: 14px;
    font-weight: 600;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    width: 100%;
    text-align: left;
    position: relative;
    transition: all 0.3s ease;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    -webkit-tap-highlight-color: transparent;
  }
  
  .dropbtn:hover {
    background-color: #a60d26;
  }
  
  .dropbtn i {
    float: right;
    margin-top: 2px;
    transition: transform 0.3s ease;
  }
  
  .dropdown-content {
    display: none;
    position: absolute;
    right: 0;
    background-color: #fff;
    min-width: 200px;
    max-height: 300px;
    overflow-y: auto;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    border-radius: 8px;
    border: 1px solid #e0e0e0;
    z-index: 1000;
    margin-top: 5px;
  }
  
  .dropdown-content a {
    color: #333;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    font-weight: 500;
    transition: all 0.3s ease;
    border-bottom: 1px solid #f0f0f0;
  }
  
  .dropdown-content a:last-child {
    border-bottom: none;
  }
  
  .dropdown-content a:hover {
    background-color: #f8f8f8;
    color: #c8102e;
  }
  
  .dropdown:hover .dropdown-content {
    display: block;
  }
  
  .dropdown:hover .dropbtn i {
    transform: rotate(180deg);
  }
  
  /* Category headers for mobile */
  .category-header {
    background: linear-gradient(135deg, #4a4a4a 0%, #2c2c2c 100%);
    color: white;
    padding: 15px 20px;
    margin: 20px 0 15px 0;
    font-size: 18px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(24, 24, 24, 0.678); 
    position: sticky;
    top: 150px;
    z-index: 50;
    clear: both;
    display: block !important;
  }
  
  .category-header:first-child {
    margin-top: 0;
  }
  
  /* Mobile menu container */
  .mobile-menu-container {
    width: 100%;
    display: block;
    padding-top: 0px;
    clear: both;
  }
  
  .mobile-menu-container > :first-child {
    margin-bottom: 140px !important;
  }
  
  .mobile-menu-item {
    margin-bottom: 15px !important;
  }
  
  /* Hide category title heading on mobile */
  .category-title {
    display: none !important;
  }
  
  /* Enhanced menu items for mobile - Compact Design */
  .menu-item {
    background: #fff !important;
    border-radius: 8px !important;
    padding: 15px !important;
    margin-bottom: 12px !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06) !important;
    border: 1px solid #e8e8e8 !important;
    transition: all 0.3s ease !important;
  }
  
  .menu-item:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1) !important;
    border-color: #d0d0d0 !important;
  }
  
  /* Compact item layout with title/price on same row */
  .item-details {
    display: flex !important;
    flex-direction: column !important;
    gap: 8px !important;
  }
  
  .item-header {
    display: flex !important;
    flex-direction: row !important;
    justify-content: space-between !important;
    align-items: flex-start !important;
    gap: 10px !important;
  }
  
  .item-name {
    font-size: 16px !important;
    font-weight: 600 !important;
    color: #333 !important;
    margin: 0 !important;
    line-height: 1.4 !important;
    flex: 1 !important;
  }
  
  .item-price {
    font-size: 16px !important;
    font-weight: 700 !important;
    color: #c8102e !important;
    margin: 0 !important;
    white-space: nowrap !important;
    flex-shrink: 0 !important;
  }
  
  .item-desc {
    font-size: 13px !important;
    color: #666 !important;
    line-height: 1.4 !important;
    margin: 0 !important;
  }
  
  .item-desc span {
    display: none !important; /* Hide category span in mobile view */
  }
}

/* Additional responsive improvements */
@media (max-width: 480px) {
  .mobile-menu-controls,
  .mobile-controls {
    flex-direction: row !important;
    gap: 10px !important;
    padding: 12px 2px !important;
  }
  
  .dropdown {
    width: auto !important;
    min-width: 120px !important;
    flex-shrink: 0 !important;
  }
  
  .dropbtn {
    width: 100% !important;
    text-align: center !important;
    font-size: 12px !important;
    padding: 10px 12px !important;
  }
  
  .dropdown-content {
    right: auto !important;
    left: 0 !important;
    width: 100% !important;
    min-width: auto !important;
  }
  
  .category-header {
    font-size: 16px !important;
    padding: 12px 15px !important;
    margin: 15px 0 10px 0 !important;
  }
  
  .menu-item {
    padding: 15px 5px !important;
    margin-bottom: 12px !important;
  }
  
  .item-name {
    font-size: 16px !important;
  }
  
  .item-price {
    font-size: 18px !important;
    padding: 2px 0px !important;
  }
}