@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
  --primary: #0f766e;
  --primary-dark: #0d5a54;
  --primary-light: #14b8a6;
  --secondary: #3b82f6;
  --white: #ffffff;
  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-400: #9ca3af;
  --gray-500: #6b7280;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --gray-800: #1f2937;
  --gray-900: #111827;
  --success: #10b981;
  --success-bg: #d1fae5;
  --warning: #f59e0b;
  --warning-bg: #fef3c7;
  --danger: #ef4444;
  --danger-bg: #fee2e2;
  --info: #3b82f6;
  --info-bg: #dbeafe;
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
  --radius-sm: 0.375rem;
  --radius: 0.5rem;
  --radius-md: 0.75rem;
  --radius-lg: 1rem;
  --radius-xl: 1.5rem;
  --transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
  font-family: 'Plus Jakarta Sans', -apple-system, sans-serif;
  background: var(--gray-50);
  color: var(--gray-800);
  line-height: 1.5;
  min-height: 100vh;
}

h1 { font-size: 1.875rem; font-weight: 700; letter-spacing: -0.02em; color: var(--gray-900); }
h2 { font-size: 1.5rem; font-weight: 600; letter-spacing: -0.01em; color: var(--gray-800); margin-bottom: 1.25rem; }
h3 { font-size: 1.25rem; font-weight: 600; color: var(--gray-800); margin-bottom: 1rem; }

.login-wrapper {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(145deg, var(--gray-800) 0%, var(--gray-900) 100%);
  position: relative;
}

.login-wrapper::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 20% 50%, rgba(15, 118, 110, 0.15) 0%, transparent 50%);
}

.login-card {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: 2.5rem 2rem;
  width: 420px;
  text-align: center;
  box-shadow: var(--shadow-xl);
  position: relative;
  z-index: 1;
}

.login-card .logo { font-size: 3rem; margin-bottom: 0.75rem; }
.login-card h2 { font-size: 1.75rem; font-weight: 700; color: var(--gray-800); margin-bottom: 0.5rem; }
.login-card p.sub { color: var(--gray-500); font-size: 0.875rem; margin-bottom: 1.75rem; }

.form-group { margin-bottom: 1.25rem; text-align: left; }
.form-group label { display: block; font-size: 0.75rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; color: var(--gray-500); margin-bottom: 0.5rem; }

input, select, textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-family: inherit;
  color: var(--gray-800);
  background: var(--white);
  transition: var(--transition);
  outline: none;
}

input:focus, select:focus, textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.1);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.7rem 1.5rem;
  border: none;
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: var(--transition);
}

.btn-primary { background: var(--primary); color: white; }
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-secondary { background: var(--gray-100); color: var(--gray-700); border: 1px solid var(--gray-200); }
.btn-secondary:hover { background: var(--gray-200); }
.btn-danger { background: var(--danger); color: white; }
.btn-danger:hover { background: #dc2626; }
.btn-sm { padding: 0.4rem 1rem; font-size: 0.75rem; }
.btn-full { width: 100%; }

.navbar {
  background: var(--white);
  padding: 0 2rem;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: var(--shadow-sm);
  border-bottom: 1px solid var(--gray-100);
  position: sticky;
  top: 0;
  z-index: 100;
}

.navbar .brand { font-size: 1.25rem; font-weight: 700; color: var(--primary); }
.user-info { display: flex; align-items: center; gap: 1rem; }
.user-info span { color: var(--gray-600); font-weight: 500; font-size: 0.875rem; }
.navbar button { background: var(--gray-100); border: none; padding: 0.5rem 1.25rem; border-radius: var(--radius-sm); font-size: 0.875rem; font-weight: 500; cursor: pointer; transition: var(--transition); }
.navbar button:hover { background: var(--gray-200); }

.page { max-width: 1280px; margin: 2rem auto; padding: 0 1.5rem; }

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  border: 1px solid var(--gray-100);
  box-shadow: var(--shadow-sm);
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary-light);
}

.card .icon { font-size: 2.5rem; margin-bottom: 0.75rem; }
.card .label { font-weight: 600; color: var(--gray-800); }

.panel {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  border: 1px solid var(--gray-100);
  box-shadow: var(--shadow-sm);
}

.menu-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.5rem;
}

.menu-item {
  background: var(--white);
  border-radius: var(--radius);
  padding: 1.25rem;
  border: 1px solid var(--gray-100);
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}

.menu-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary-light);
}

.menu-item.sold-out { opacity: 0.6; background: var(--gray-50); }
.menu-item .item-name { font-weight: 700; font-size: 1.125rem; color: var(--gray-800); }
.menu-item .item-price { color: var(--primary); font-weight: 700; font-size: 1.25rem; margin: 0.5rem 0; }

.status {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: capitalize;
}
.status-pending { background: var(--warning-bg); color: var(--warning); }
.status-approved { background: var(--success-bg); color: var(--success); }
.status-suspended { background: var(--danger-bg); color: var(--danger); }

.table-wrapper { overflow-x: auto; border-radius: var(--radius); }
table { width: 100%; border-collapse: collapse; font-size: 0.875rem; }
th { background: var(--gray-50); color: var(--gray-600); text-align: left; padding: 0.875rem 1rem; font-weight: 600; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.5px; border-bottom: 1px solid var(--gray-200); }
td { padding: 0.875rem 1rem; border-bottom: 1px solid var(--gray-100); }
tr:hover td { background: var(--gray-50); }

.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.modal-content {
  background: var(--white);
  border-radius: var(--radius-xl);
  width: 90%;
  max-width: 480px;
  padding: 2rem;
  animation: modalFadeIn 0.2s ease;
  box-shadow: var(--shadow-xl);
}

@keyframes modalFadeIn {
  from { opacity: 0; transform: scale(0.96) translateY(-10px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--gray-100);
}
.modal-header h3 { margin: 0; font-size: 1.35rem; font-weight: 600; color: var(--gray-800); }
.close { font-size: 1.5rem; cursor: pointer; color: var(--gray-400); transition: var(--transition); line-height: 1; }
.close:hover { color: var(--danger); }

#toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  background: var(--gray-800);
  color: white;
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-weight: 500;
  box-shadow: var(--shadow-lg);
  transform: translateY(100px);
  opacity: 0;
  transition: 0.2s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  z-index: 999;
}
#toast.show { transform: translateY(0); opacity: 1; }
#toast.success { background: var(--success); }
#toast.error { background: var(--danger); }

.form-row { display: flex; gap: 1rem; flex-wrap: wrap; align-items: flex-end; margin-bottom: 1.5rem; }
.form-row .form-group { flex: 1; min-width: 140px; margin-bottom: 0; }

.allergen-badge {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  font-size: 0.65rem;
  font-weight: 500;
  background: var(--gray-100);
  color: var(--gray-600);
}

@media (max-width: 768px) {
  .navbar { padding: 0 1rem; }
  .page { padding: 0 1rem; margin: 1rem auto; }
  h2 { font-size: 1.25rem; }
  .login-card { width: 90%; padding: 2rem 1.5rem; }
  .cards, .menu-grid { grid-template-columns: 1fr; }
  .form-row { flex-direction: column; }
  .form-row .form-group { width: 100%; }
  th, td { padding: 0.625rem; font-size: 0.75rem; }
}
