* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary: #2d6a4f;
  --primary-light: #40916c;
  --accent: #d4a373;
  --bg: #fefae0;
  --card-bg: #ffffff;
  --text: #1b1b1b;
  --text-light: #555;
  --error: #d32f2f;
  --success: #2e7d32;
  --radius: 12px;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.container {
  max-width: 600px;
  margin: 0 auto;
  padding: 0 1rem;
  width: 100%;
}

header {
  background: var(--primary);
  padding: 1rem 0;
  color: white;
}

header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 1.3rem;
  font-weight: 700;
}

.lang-btn {
  background: rgba(255,255,255,0.2);
  border: 1px solid rgba(255,255,255,0.4);
  color: white;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 600;
}

.lang-btn:hover {
  background: rgba(255,255,255,0.3);
}

main {
  flex: 1;
  padding: 2rem 0;
}

.card {
  background: var(--card-bg);
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  margin-bottom: 1.5rem;
}

.status-badge {
  display: inline-block;
  padding: 0.4rem 1rem;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.status-badge.open {
  background: #e8f5e9;
  color: var(--success);
}

.status-badge.closed {
  background: #fce4ec;
  color: var(--error);
}

.dish-image {
  margin-bottom: 1.5rem;
  border-radius: 8px;
  overflow: hidden;
}

.dish-image img,
.dish-slideshow img {
  width: 100%;
  height: 250px;
  object-fit: cover;
  display: block;
  transition: opacity 0.3s ease;
}

.dish-slideshow {
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 1rem;
}

.dish-info {
  margin-bottom: 1.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid #eee;
}

.dish-info h2 {
  font-size: 1.4rem;
  margin-bottom: 0.5rem;
  color: var(--primary);
}

.dish-info p {
  color: var(--text-light);
  line-height: 1.5;
}

.dish-ingredients {
  font-size: 0.85rem;
  color: var(--text-light);
  margin-top: 0.5rem;
  font-style: italic;
}

.price {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--primary);
  margin-top: 0.5rem;
}

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

.form-group label {
  display: block;
  margin-bottom: 0.3rem;
  font-weight: 500;
  font-size: 0.9rem;
}

.form-group input,
.form-group select {
  width: 100%;
  padding: 0.7rem;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 1rem;
  transition: border-color 0.2s;
  background: white;
}

.form-group input:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--primary);
}

.order-total {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 1rem 0;
  color: var(--primary);
}

.btn {
  display: inline-block;
  padding: 0.8rem 2rem;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-primary {
  background: var(--primary);
  color: white;
  width: 100%;
}

.btn-primary:hover {
  background: var(--primary-light);
}

.error {
  color: var(--error);
  font-size: 0.9rem;
  margin-top: 0.5rem;
}

.hidden {
  display: none !important;
}

.payment-info {
  text-align: center;
}

.payment-details {
  background: #f5f5f5;
  border-radius: 8px;
  padding: 1.5rem;
  margin: 1rem 0;
}

.payment-details p {
  margin-bottom: 0.5rem;
  font-size: 1.1rem;
}

.payment-details p:last-child {
  margin-bottom: 0;
}

.payment-note {
  font-size: 0.85rem;
  color: var(--text-light);
  margin-top: 1rem;
  font-style: italic;
}

.counter {
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-light);
  margin-top: 1rem;
}

footer {
  background: var(--primary);
  color: rgba(255,255,255,0.8);
  text-align: center;
  padding: 1.2rem 0;
  font-size: 0.85rem;
}

.social-link {
  color: white;
  text-decoration: none;
  display: inline-block;
  margin-top: 0.5rem;
  font-weight: 600;
}

.social-link:hover {
  text-decoration: underline;
}

/* Admin Styles */
.admin-login {
  max-width: 400px;
  margin: 3rem auto;
}

.admin-dashboard {
  max-width: 700px;
  margin: 0 auto;
  padding: 2rem 1rem;
}

.admin-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
}

.admin-header h1 {
  font-size: 1.4rem;
}

.toggle-container {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin-bottom: 1rem;
}

.toggle {
  width: 50px;
  height: 26px;
  background: #ccc;
  border-radius: 13px;
  position: relative;
  cursor: pointer;
  transition: background 0.2s;
}

.toggle.active {
  background: var(--success);
}

.toggle::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  background: white;
  border-radius: 50%;
  transition: transform 0.2s;
}

.toggle.active::after {
  transform: translateX(24px);
}

.settings-grid {
  display: grid;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.settings-grid .form-group {
  margin-bottom: 0;
}

.order-list {
  list-style: none;
}

.order-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
  border: 1px solid #eee;
  border-radius: 8px;
  margin-bottom: 0.5rem;
}

.order-item .order-info {
  flex: 1;
}

.order-item .order-info p {
  font-size: 0.85rem;
  color: var(--text-light);
}

.order-item .order-info .ref {
  font-weight: 600;
  color: var(--text);
}

.order-actions {
  display: flex;
  gap: 0.5rem;
}

.btn-sm {
  padding: 0.4rem 0.8rem;
  font-size: 0.8rem;
  border-radius: 6px;
}

.btn-success {
  background: var(--success);
  color: white;
}

.btn-danger {
  background: var(--error);
  color: white;
}

.btn-secondary {
  background: #eee;
  color: var(--text);
}

.status-pill {
  display: inline-block;
  padding: 0.2rem 0.5rem;
  border-radius: 10px;
  font-size: 0.75rem;
  font-weight: 600;
}

.status-pill.confirmed {
  background: #e8f5e9;
  color: var(--success);
}

.status-pill.pending {
  background: #fff3e0;
  color: #e65100;
}

.status-pill.cancelled {
  background: #fce4ec;
  color: var(--error);
}

.max-control {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.max-control button {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 2px solid var(--primary);
  background: white;
  color: var(--primary);
  font-size: 1.2rem;
  font-weight: bold;
  cursor: pointer;
}

.max-control button:hover {
  background: var(--primary);
  color: white;
}

.max-control span {
  font-size: 1.3rem;
  font-weight: 700;
  min-width: 2rem;
  text-align: center;
}

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

.dish-qty-row:last-child {
  border-bottom: none;
}

.dish-qty-name {
  font-weight: 600;
  flex: 1;
}

.dish-qty-price {
  color: var(--text-light);
  margin-right: 1rem;
  font-size: 0.9rem;
}

.dish-qty-control {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.dish-qty-control button {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid var(--primary);
  background: white;
  color: var(--primary);
  font-size: 1.1rem;
  font-weight: bold;
  cursor: pointer;
}

.dish-qty-control button:hover {
  background: var(--primary);
  color: white;
}

.dish-qty-control span {
  font-size: 1.1rem;
  font-weight: 700;
  min-width: 1.5rem;
  text-align: center;
}

@media (max-width: 480px) {
  .card {
    padding: 1.5rem;
  }

  .order-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }
}
