/* Parky — Custom Styles (Tailwind CDN handles most styling) */

:root {
  --bg-dark: #1a1a2e;
  --bg-card: #16213e;
  --bg-surface: #0f3460;
  --accent-green: #22c55e;
  --accent-blue: #3b82f6;
  --accent-red: #ef4444;
  --accent-yellow: #eab308;
  --text-primary: #f1f5f9;
  --text-secondary: #94a3b8;
}

/* Global */
body {
  background-color: var(--bg-dark);
  color: var(--text-primary);
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  min-height: 100vh;
}

/* Worker big buttons */
.btn-worker {
  min-height: 80px;
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  border-radius: 1rem;
  transition: all 0.15s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  text-transform: uppercase;
  border: 2px solid transparent;
  cursor: pointer;
}

.btn-worker:active {
  transform: scale(0.97);
}

.btn-entry {
  background: linear-gradient(135deg, #16a34a, #22c55e);
  color: white;
  border-color: #22c55e;
}
.btn-entry:hover { background: linear-gradient(135deg, #15803d, #16a34a); }

.btn-exit {
  background: linear-gradient(135deg, #2563eb, #3b82f6);
  color: white;
  border-color: #3b82f6;
}
.btn-exit:hover { background: linear-gradient(135deg, #1d4ed8, #2563eb); }

.btn-search {
  background: linear-gradient(135deg, #475569, #64748b);
  color: white;
  border-color: #64748b;
}
.btn-search:hover { background: linear-gradient(135deg, #334155, #475569); }

.btn-cancel {
  background: linear-gradient(135deg, #dc2626, #ef4444);
  color: white;
  border-color: #ef4444;
}
.btn-cancel:hover { background: linear-gradient(135deg, #b91c1c, #dc2626); }

.btn-confirm {
  background: linear-gradient(135deg, #16a34a, #22c55e);
  color: white;
  min-height: 70px;
  font-size: 1.25rem;
  font-weight: 700;
  border-radius: 1rem;
  border: 2px solid #22c55e;
  cursor: pointer;
  transition: all 0.15s ease;
}
.btn-confirm:active { transform: scale(0.97); }

/* Plate display */
.plate-display {
  background: #fef9c3;
  color: #1a1a2e;
  font-size: 2rem;
  font-weight: 900;
  letter-spacing: 0.15em;
  padding: 1rem 2rem;
  border-radius: 0.75rem;
  text-align: center;
  border: 3px solid #eab308;
  font-family: 'Courier New', monospace;
}

/* Amount display */
.amount-display {
  font-size: 3.5rem;
  font-weight: 900;
  color: #22c55e;
  text-align: center;
  line-height: 1;
}

/* Status badges */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
}
.badge-green { background: rgba(34,197,94,0.15); color: #22c55e; }
.badge-blue { background: rgba(59,130,246,0.15); color: #3b82f6; }
.badge-yellow { background: rgba(234,179,8,0.15); color: #eab308; }
.badge-red { background: rgba(239,68,68,0.15); color: #ef4444; }
.badge-gray { background: rgba(148,163,184,0.15); color: #94a3b8; }

/* Cards */
.stat-card {
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 1rem;
  padding: 1.25rem;
  transition: border-color 0.2s;
}
.stat-card:hover {
  border-color: rgba(255,255,255,0.15);
}

/* Admin sidebar */
.sidebar {
  background: var(--bg-card);
  border-right: 1px solid rgba(255,255,255,0.08);
  min-height: 100vh;
  width: 240px;
}

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  color: var(--text-secondary);
  transition: all 0.15s;
  font-size: 0.9rem;
}
.sidebar-link:hover, .sidebar-link.active {
  background: var(--bg-surface);
  color: var(--text-primary);
}

/* Tables */
.data-table {
  width: 100%;
  border-collapse: collapse;
}
.data-table th {
  text-align: left;
  padding: 0.75rem 1rem;
  font-size: 0.75rem;
  text-transform: uppercase;
  color: var(--text-secondary);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.data-table td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  font-size: 0.875rem;
}
.data-table tbody tr:hover {
  background: rgba(255,255,255,0.03);
}

/* Input styles for dark theme */
.input-dark {
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,0.15);
  color: var(--text-primary);
  border-radius: 0.5rem;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  width: 100%;
  outline: none;
  transition: border-color 0.2s;
}
.input-dark:focus {
  border-color: #3b82f6;
}
.input-dark::placeholder {
  color: var(--text-secondary);
}

/* Worker large input */
.input-plate {
  background: var(--bg-card);
  border: 2px solid rgba(255,255,255,0.2);
  color: var(--text-primary);
  border-radius: 0.75rem;
  padding: 1rem 1.25rem;
  font-size: 1.5rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  width: 100%;
  text-align: center;
  outline: none;
}
.input-plate:focus {
  border-color: #3b82f6;
}

/* Modal overlay */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 50;
  padding: 1rem;
}
.modal-content {
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 1rem;
  padding: 1.5rem;
  max-width: 500px;
  width: 100%;
}

/* QR scanner container */
#qr-reader {
  width: 100%;
  max-width: 400px;
  margin: 0 auto;
  border-radius: 0.75rem;
  overflow: hidden;
}

/* Loading spinner */
.spinner {
  border: 3px solid rgba(255,255,255,0.1);
  border-top: 3px solid #3b82f6;
  border-radius: 50%;
  width: 2rem;
  height: 2rem;
  animation: spin 0.8s linear infinite;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Toast notifications */
.toast {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  padding: 1rem 1.5rem;
  border-radius: 0.75rem;
  font-weight: 500;
  z-index: 100;
  animation: slideUp 0.3s ease;
}
@keyframes slideUp {
  from { transform: translateY(1rem); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}
.toast-success { background: #16a34a; color: white; }
.toast-error { background: #dc2626; color: white; }
.toast-info { background: #2563eb; color: white; }

/* Landscape optimization for worker */
@media (orientation: landscape) and (max-height: 500px) {
  .worker-grid {
    grid-template-columns: 1fr 1fr 1fr;
    grid-template-rows: 1fr;
  }
  .btn-worker {
    min-height: 60px;
  }
}
