/* ===== Reservation System Styles ===== */

/* Wizard Steps */
.wizard-steps {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 2rem;
}

.wizard-step {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: 9999px;
  font-size: 1rem;
  font-weight: 500;
  color: #9CA3AF;
  background: #F3F4F6;
  transition: all 0.3s;
}

.wizard-step.active {
  background: #1E293B;
  color: white;
}

.wizard-step.completed {
  background: #F5C518;
  color: white;
}

.wizard-step .step-num {
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  font-weight: 700;
  background: rgba(255,255,255,0.2);
}

.wizard-step.active .step-num,
.wizard-step.completed .step-num {
  background: rgba(255,255,255,0.3);
}

.wizard-panel {
  display: none;
  animation: fadeIn 0.3s ease;
}

.wizard-panel.active {
  display: block;
}

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

/* Calendar */
.calendar {
  max-width: 420px;
  margin: 0 auto;
  background: white;
  border-radius: 1rem;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
  overflow: hidden;
}

.calendar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  background: #1E293B;
  color: white;
}

.calendar-header button {
  background: none;
  border: none;
  color: white;
  cursor: pointer;
  padding: 0.25rem;
  border-radius: 0.375rem;
  transition: background 0.2s;
}

.calendar-header button:hover {
  background: rgba(255,255,255,0.15);
}

.calendar-header h3 {
  font-size: 1rem;
  font-weight: 600;
}

.calendar-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  text-align: center;
  padding: 0.75rem 0.5rem 0.25rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: #6B7280;
}

.calendar-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  padding: 0.25rem 0.5rem 0.75rem;
  gap: 0.25rem;
}

.calendar-day {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.5rem;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.15s;
  border: 2px solid transparent;
}

.calendar-day:hover:not(.disabled):not(.empty) {
  background: #E9F5F7;
  color: #1E293B;
}

.calendar-day.selected {
  background: #1E293B;
  color: white;
  font-weight: 600;
}

.calendar-day.today {
  border-color: #F5C518;
  font-weight: 600;
}

.calendar-day.disabled {
  color: #D1D5DB;
  cursor: not-allowed;
}

.calendar-day.empty {
  cursor: default;
}

/* Time Slots */
.time-slots {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
  max-width: 480px;
  margin: 0 auto;
}

@media (min-width: 640px) {
  .time-slots {
    grid-template-columns: repeat(4, 1fr);
  }
}

.time-slot {
  padding: 0.75rem;
  text-align: center;
  border: 2px solid #E5E7EB;
  border-radius: 0.5rem;
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
  background: white;
}

.time-slot:hover:not(.disabled) {
  border-color: #1E293B;
  color: #1E293B;
  background: #E9F5F7;
}

.time-slot.selected {
  background: #1E293B;
  color: white;
  border-color: #1E293B;
}

.time-slot.disabled {
  background: #F9FAFB;
  color: #D1D5DB;
  cursor: not-allowed;
  border-color: #F3F4F6;
}

/* Reservation Form */
.res-form-group {
  margin-bottom: 1.25rem;
}

.res-form-group label {
  display: block;
  font-size: 1rem;
  font-weight: 600;
  color: #374151;
  margin-bottom: 0.375rem;
}

.res-form-group input {
  width: 100%;
  padding: 0.625rem 0.875rem;
  border: 2px solid #E5E7EB;
  border-radius: 0.5rem;
  font-size: 1rem;
  transition: border-color 0.2s;
}

.res-form-group input:focus {
  outline: none;
  border-color: #1E293B;
}

.res-form-group .error-msg {
  color: #EF4444;
  font-size: 0.9rem;
  margin-top: 0.25rem;
  display: none;
}

.res-form-group.has-error input {
  border-color: #EF4444;
}

.res-form-group.has-error .error-msg {
  display: block;
}

/* Summary card */
.res-summary {
  background: #F9FAFB;
  border-radius: 0.75rem;
  padding: 1.25rem;
  margin-bottom: 1.5rem;
}

.res-summary-row {
  display: flex;
  justify-content: space-between;
  padding: 0.5rem 0;
  font-size: 1rem;
}

.res-summary-row:not(:last-child) {
  border-bottom: 1px solid #E5E7EB;
}

.res-summary-row .label {
  color: #6B7280;
}

.res-summary-row .value {
  font-weight: 600;
  color: #1F2937;
}

/* Buttons */
.btn-primary {
  background: #1E293B;
  color: white;
  padding: 0.625rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 600;
  font-size: 1rem;
  border: none;
  cursor: pointer;
  transition: background 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-primary:hover { background: #0d3f4d; }
.btn-primary:disabled { background: #9CA3AF; cursor: not-allowed; }

.btn-secondary {
  background: white;
  color: #374151;
  padding: 0.625rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 600;
  font-size: 1rem;
  border: 2px solid #E5E7EB;
  cursor: pointer;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-secondary:hover { border-color: #1E293B; color: #1E293B; }

/* Success screen */
.success-screen {
  text-align: center;
  padding: 2rem 0;
}

.success-icon {
  width: 4rem;
  height: 4rem;
  margin: 0 auto 1rem;
  background: #10B981;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: scaleIn 0.4s ease;
}

@keyframes scaleIn {
  from { transform: scale(0); }
  to { transform: scale(1); }
}

/* ===== Admin Styles ===== */

/* Login */
.admin-login {
  max-width: 400px;
  margin: 4rem auto;
  padding: 2rem;
  background: white;
  border-radius: 1rem;
  box-shadow: 0 4px 20px rgba(0,0,0,0.08);
}

/* Tabs */
.admin-tabs {
  display: flex;
  border-bottom: 2px solid #E5E7EB;
  margin-bottom: 1.5rem;
}

.admin-tab {
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  color: #6B7280;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  cursor: pointer;
  transition: all 0.2s;
  background: none;
  border-top: none;
  border-left: none;
  border-right: none;
}

.admin-tab:hover { color: #1E293B; }

.admin-tab.active {
  color: #1E293B;
  border-bottom-color: #F5C518;
}

.admin-panel {
  display: none;
}

.admin-panel.active {
  display: block;
}

/* Table */
.admin-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.95rem;
}

.admin-table thead th {
  background: #F9FAFB;
  padding: 0.625rem 0.75rem;
  text-align: left;
  font-weight: 600;
  color: #6B7280;
  border-bottom: 2px solid #E5E7EB;
  white-space: nowrap;
}

.admin-table tbody td {
  padding: 0.625rem 0.75rem;
  border-bottom: 1px solid #F3F4F6;
  vertical-align: middle;
}

.admin-table tbody tr:hover {
  background: #F9FAFB;
}

/* Status badges */
.status-badge {
  display: inline-block;
  padding: 0.125rem 0.5rem;
  border-radius: 9999px;
  font-size: 0.9rem;
  font-weight: 600;
}

.status-pending { background: #FEF3C7; color: #92400E; }
.status-confirmed { background: #D1FAE5; color: #065F46; }
.status-completed { background: #DBEAFE; color: #1E40AF; }
.status-cancelled { background: #FEE2E2; color: #991B1B; }

/* Status select */
.status-select {
  padding: 0.25rem 0.5rem;
  border: 1px solid #E5E7EB;
  border-radius: 0.375rem;
  font-size: 0.9rem;
  cursor: pointer;
}

/* Memo input */
.memo-input {
  width: 100%;
  min-width: 120px;
  padding: 0.25rem 0.5rem;
  border: 1px solid transparent;
  border-radius: 0.375rem;
  font-size: 0.95rem;
  transition: border-color 0.2s;
}

.memo-input:focus {
  outline: none;
  border-color: #1E293B;
  background: #E9F5F7;
}

/* Filters */
.admin-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1rem;
  align-items: center;
}

.admin-filters input,
.admin-filters select {
  padding: 0.375rem 0.625rem;
  border: 1px solid #E5E7EB;
  border-radius: 0.375rem;
  font-size: 0.95rem;
}

/* Pagination */
.pagination {
  display: flex;
  justify-content: center;
  gap: 0.25rem;
  margin-top: 1.5rem;
}

.pagination button {
  padding: 0.375rem 0.75rem;
  border: 1px solid #E5E7EB;
  border-radius: 0.375rem;
  background: white;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.15s;
}

.pagination button:hover:not(:disabled) {
  border-color: #1E293B;
  color: #1E293B;
}

.pagination button.active {
  background: #1E293B;
  color: white;
  border-color: #1E293B;
}

.pagination button:disabled {
  color: #D1D5DB;
  cursor: not-allowed;
}

/* Admin Calendar */
.admin-cal-day {
  aspect-ratio: 1;
  border: 1px solid #E5E7EB;
  border-radius: 0.5rem;
  padding: 0.25rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.15s;
  position: relative;
}

.admin-cal-day:hover:not(.empty) {
  border-color: #1E293B;
  background: #F9FAFB;
}

.admin-cal-day .day-num {
  font-weight: 600;
  margin-bottom: 0.125rem;
}

.admin-cal-day .badge {
  font-size: 0.8rem;
  font-weight: 700;
  padding: 0.0625rem 0.375rem;
  border-radius: 9999px;
  color: white;
}

.badge-green { background: #10B981; }
.badge-yellow { background: #F59E0B; }
.badge-red { background: #EF4444; }

/* Stats cards */
.stat-card {
  background: white;
  border-radius: 0.75rem;
  padding: 1.25rem;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.stat-card .stat-label {
  font-size: 0.9rem;
  color: #6B7280;
  margin-bottom: 0.25rem;
}

.stat-card .stat-value {
  font-size: 1.5rem;
  font-weight: 700;
  color: #1E293B;
}

/* Modal */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  z-index: 100;
  align-items: center;
  justify-content: center;
}

.modal-overlay.active {
  display: flex;
}

.modal-content {
  background: white;
  border-radius: 1rem;
  padding: 1.5rem;
  max-width: 600px;
  width: 90%;
  max-height: 80vh;
  overflow-y: auto;
}

/* Loading spinner */
.spinner {
  width: 2rem;
  height: 2rem;
  border: 3px solid #E5E7EB;
  border-top-color: #1E293B;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 2rem auto;
}

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

/* Nav reservation button */
.nav-reserve-btn {
  background: #F5C518;
  color: white !important;
  padding: 0.5rem 1.5rem;
  border-radius: 0.375rem;
  font-weight: 600 !important;
  font-size: 1rem;
  transition: background 0.2s;
}

.nav-reserve-btn:hover {
  background: #c96a52;
}
