/* Enhanced Order Page Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
  min-height: 100vh;
  color: #333;
  line-height: 1.6;
}

/* Navigation */
.main-nav {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1000;
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: center;
  gap: 2rem;
  padding: 1rem 2rem;
}

.nav-link {
  text-decoration: none;
  color: #555;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  transition: all 0.3s ease;
}

.nav-link:hover,
.nav-link.active {
  background: #764ba2;
  color: white;
  transform: translateY(-2px);
}

/* Hero Section */
.hero {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  text-align: center;
  padding: 8rem 2rem 4rem;
  margin-top: 60px;
}

.hero-content h1 {
  font-size: 3rem;
  margin-bottom: 1rem;
  font-weight: 300;
  letter-spacing: 2px;
}

.hero-content p {
  font-size: 1.2rem;
  opacity: 0.9;
}

/* Main Container */
.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 2rem;
  display: grid;
  grid-template-columns: 1fr 350px;
  gap: 2rem;
  align-items: start;
}

/* Left Column - Menu */
.menu-section {
  background: white;
  border-radius: 16px;
  padding: 2rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  min-height: 600px;
}

.section-title {
  font-size: 2rem;
  color: #333;
  margin-bottom: 2rem;
  text-align: center;
  font-weight: 300;
}

/* Menu Grid - Compact Layout */
.menu-grid {
  display: grid;
  gap: 2rem;
}

.category-group {
  background: #fafafa;
  border-radius: 12px;
  padding: 1.5rem;
  border-left: 4px solid var(--cat-color, #764ba2);
}

.category-title {
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--cat-color, #764ba2);
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.category-items {
  display: grid;
  gap: 1rem;
}

.menu-item {
  background: white;
  border-radius: 10px;
  padding: 1.25rem;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
  border: 1px solid #eee;
}

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

.item-names {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.name-en {
  font-weight: 600;
  color: #333;
  font-size: 1.1rem;
}

.divider {
  color: #999;
  font-weight: 300;
}

.name-al {
  color: #666;
  font-style: italic;
}

.item-desc {
  color: #777;
  font-size: 0.9rem;
  margin-bottom: 1rem;
  line-height: 1.4;
}

.desc-en {
  display: block;
  margin-bottom: 0.25rem;
}

.desc-al {
  display: block;
  font-style: italic;
  opacity: 0.8;
}

.item-price-add {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.price {
  font-weight: 700;
  color: #764ba2;
  font-size: 1.1rem;
}

.add-btn {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.add-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(118, 75, 162, 0.3);
}

/* Right Column - Sidebar */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  position: sticky;
  top: 100px;
}

/* Glass Card Effect */
.glass-card {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.glass-card h2 {
  color: #333;
  margin-bottom: 1rem;
  font-size: 1.4rem;
  font-weight: 600;
}

/* Connection Status */
.connection-status {
  background: rgba(52, 152, 219, 0.1);
  border: 1px solid rgba(52, 152, 219, 0.3);
  border-radius: 8px;
  padding: 0.75rem;
  text-align: center;
  font-size: 0.9rem;
  margin-bottom: 1rem;
}

.connection-status.connected {
  background: rgba(39, 174, 96, 0.1);
  border-color: rgba(39, 174, 96, 0.3);
  color: #27ae60;
}

.connection-status.disconnected {
  background: rgba(231, 76, 60, 0.1);
  border-color: rgba(231, 76, 60, 0.3);
  color: #e74c3c;
}

/* Cart Styles */
.cart-section {
  min-height: 200px;
}

.cart-list {
  list-style: none;
  margin-bottom: 1rem;
}

.cart-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 0;
  border-bottom: 1px solid #eee;
}

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

.cart-item-each {
  display: block;
  font-size: 0.85rem;
  color: #777;
  margin-top: 0.25rem;
}

.cart-controls {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.cart-qty-btn {
  background: #f8f9fa;
  border: 1px solid #dee2e6;
  width: 30px;
  height: 30px;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.2s ease;
}

.cart-qty-btn:hover {
  background: #e9ecef;
  transform: scale(1.1);
}

.cart-qty {
  font-weight: 600;
  min-width: 20px;
  text-align: center;
}

.cart-remove-btn {
  background: #dc3545;
  color: white;
  border: none;
  width: 30px;
  height: 30px;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.2s ease;
}

.cart-remove-btn:hover {
  background: #c82333;
  transform: scale(1.1);
}

.cart-total {
  font-size: 1.2rem;
  font-weight: 700;
  color: #764ba2;
  text-align: right;
  padding-top: 1rem;
  border-top: 2px solid #eee;
}

/* Order Form */
.order-form {
  margin-top: 1rem;
}

.form-group {
  margin-bottom: 1rem;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.75rem;
  border: 2px solid #e9ecef;
  border-radius: 8px;
  font-size: 1rem;
  transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #764ba2;
}

.form-group textarea {
  height: 80px;
  resize: vertical;
}

.submit-btn {
  width: 100%;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border: none;
  padding: 1rem 2rem;
  border-radius: 12px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.submit-btn:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(118, 75, 162, 0.3);
}

.submit-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Status Messages */
.status-message {
  text-align: center;
  color: #666;
  font-style: italic;
  padding: 2rem;
}

.status-active {
  color: #27ae60;
  font-weight: 500;
  text-align: center;
  padding: 1rem;
  background: rgba(39, 174, 96, 0.1);
  border-radius: 8px;
  border: 1px solid rgba(39, 174, 96, 0.3);
}

/* Toast Notifications */
.toast {
  position: fixed;
  top: 100px;
  right: 20px;
  background: rgba(39, 174, 96, 0.95);
  color: white;
  padding: 1rem 1.5rem;
  border-radius: 8px;
  opacity: 0;
  transform: translateX(100%);
  transition: all 0.3s ease;
  z-index: 1001;
  max-width: 300px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.toast-show {
  opacity: 1;
  transform: translateX(0);
}

.toast-error {
  background: rgba(231, 76, 60, 0.95);
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .container {
    grid-template-columns: 1fr;
    gap: 1rem;
    padding: 1rem;
  }
  
  .sidebar {
    position: relative;
    top: 0;
    order: -1;
  }
  
  .hero-content h1 {
    font-size: 2rem;
  }
  
  .nav-container {
    gap: 1rem;
    padding: 1rem;
  }
  
  .menu-item {
    padding: 1rem;
  }
  
  .item-price-add {
    flex-direction: column;
    gap: 0.5rem;
    align-items: stretch;
  }
  
  .add-btn {
    justify-content: center;
  }
}

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

.menu-item {
  animation: fadeInUp 0.5s ease-out;
}

.category-group:nth-child(1) .menu-item { animation-delay: 0.1s; }
.category-group:nth-child(2) .menu-item { animation-delay: 0.2s; }
.category-group:nth-child(3) .menu-item { animation-delay: 0.3s; }

.category-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 2rem;
  justify-content: center;
}

.category-filters button {
  background: #764ba2;
  color: white;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 500;
  transition: background 0.3s ease;
}

.category-filters button:hover,
.category-filters button.active {
  background: #5a3c91;
}
