/* ═══════════════════════════════════════════
   Perfect Pizza Point – Premium Loyalty System
   Single CSS file (Light + Dark themes)
   ═══════════════════════════════════════════ */

/* ───── CSS Custom Properties ───── */
:root {
  /* brand gradients & colors */
  --brand-gradient: linear-gradient(135deg, #FF416C, #FF4B2B);
  --brand-gradient-hover: linear-gradient(135deg, #FF4B2B, #FF416C);
  --brand-primary: #FF4B2B;
  --brand-glow: rgba(255, 75, 43, 0.4);
  --whatsapp-color: #25D366;
  
  /* light theme (default) */
  --bg-body: #FDFBF7;
  --bg-card: rgba(255, 255, 255, 0.85);
  --bg-glass: rgba(255, 255, 255, 0.6);
  --bg-input: #F3F0EA;
  --bg-modal: rgba(255, 255, 255, 0.95);
  
  --border-card: rgba(255, 255, 255, 0.5);
  --border-card-solid: #EBE6DF;
  --border-input: rgba(0, 0, 0, 0.08);
  
  --text-primary: #1A1818;
  --text-secondary: #5C5552;
  --text-muted: #9E9692;
  
  --shadow-card: 0 10px 40px rgba(0, 0, 0, 0.04);
  --shadow-elevated: 0 20px 50px rgba(255, 75, 43, 0.15);
  
  --dot-empty: #EBE6DF;
  --dot-filled: var(--brand-primary);
  
  --success: #10B981;
  --danger: #EF4444;
  --info: #3B82F6;
  --warning: #F59E0B;
  --overlay: rgba(0, 0, 0, 0.3);
  
  /* Background shapes */
  --shape-1: #FF4B2B;
  --shape-2: #FF416C;
  --shape-3: #FCA5A5;
}

[data-theme="dark"] {
  --bg-body: #0F0E11;
  --bg-card: rgba(26, 24, 28, 0.7);
  --bg-glass: rgba(15, 14, 17, 0.7);
  --bg-input: rgba(45, 42, 50, 0.6);
  --bg-modal: rgba(26, 24, 28, 0.95);
  
  --border-card: rgba(255, 255, 255, 0.05);
  --border-card-solid: #2D2A32;
  --border-input: rgba(255, 255, 255, 0.1);
  
  --text-primary: #FDFBF7;
  --text-secondary: #AFA8A5;
  --text-muted: #7A7370;
  
  --shadow-card: 0 10px 40px rgba(0, 0, 0, 0.3);
  --shadow-elevated: 0 20px 50px rgba(255, 75, 43, 0.2);
  
  --dot-empty: #2D2A32;
  
  --overlay: rgba(0, 0, 0, 0.7);
  
  --shape-1: #991B1B;
  --shape-2: #831843;
  --shape-3: #4C1D95;
}

/* ───── Reset & Base ───── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; scroll-behavior: smooth; }

body {
  font-family: 'Outfit', system-ui, -apple-system, sans-serif;
  background-color: var(--bg-body);
  color: var(--text-primary);
  min-height: 100vh;
  transition: background-color 0.5s ease, color 0.5s ease;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  position: relative;
}

/* Animated Background Shapes */
.bg-shape {
  position: fixed;
  border-radius: 50%;
  filter: blur(100px);
  z-index: -1;
  opacity: 0.15;
  animation: float 20s infinite alternate ease-in-out;
}
.bg-shape-1 { width: 50vw; height: 50vw; top: -10vw; left: -10vw; background: var(--shape-1); }
.bg-shape-2 { width: 40vw; height: 40vw; bottom: -5vw; right: -5vw; background: var(--shape-2); animation-delay: -5s; }
.bg-shape-3 { width: 30vw; height: 30vw; top: 40vh; left: 30vw; background: var(--shape-3); animation-delay: -10s; }

@keyframes float {
  0% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(5%, 10%) scale(1.1); }
  100% { transform: translate(-5%, -5%) scale(0.9); }
}

a { color: var(--brand-primary); text-decoration: none; }

/* ───── Navbar ───── */
.navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 1rem 0;
  background: var(--bg-glass);
  backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-card);
  transition: all 0.3s ease;
}

.navbar__container {
  max-width: 1200px; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 1.5rem;
}

.navbar__brand {
  display: flex; align-items: center; gap: 0.75rem;
}

.brand-icon {
  font-size: 1.8rem;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1));
}

.brand-text {
  font-weight: 800; font-size: 1.25rem;
  background: var(--brand-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.5px;
}

.navbar__actions { 
  display: flex; align-items: center; gap: 0.75rem; 
}

.nav-dock {
  display: flex;
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
  background: var(--bg-modal); /* Frosted glass */
  backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-card);
  box-shadow: var(--shadow-elevated);
  padding: 0.4rem;
  border-radius: 50px;
  gap: 0.25rem;
  width: max-content;
}

.nav-dock__indicator {
  position: absolute;
  top: 0.4rem;
  bottom: 0.4rem;
  left: 0.4rem;
  width: 0;
  background: var(--brand-gradient);
  border-radius: 50px;
  z-index: 1;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  box-shadow: 0 4px 15px var(--brand-glow);
}

.nav-btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.75rem 1.25rem; border-radius: 50px;
  font-size: 0.9rem; font-weight: 600; font-family: inherit;
  border: none;
  background: transparent !important;
  color: var(--text-secondary);
  cursor: pointer;
  position: relative;
  z-index: 2;
  transition: color 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-btn:hover:not(.active) { 
  color: var(--text-primary); 
}

.nav-btn.active { 
  color: white; 
}

/* theme toggle */
.theme-toggle {
  width: 40px; height: 40px; border-radius: 12px;
  display: grid; place-items: center;
  border: 1px solid var(--border-input);
  background: var(--bg-card);
  color: var(--text-primary);
  cursor: pointer; font-size: 1.2rem;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.theme-toggle:hover { 
  border-color: var(--brand-primary); 
  transform: rotate(15deg) scale(1.05); 
  box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

/* ───── Layout & Sections ───── */
.main-content {
  padding-top: 6rem;
  padding-bottom: 7rem;
  min-height: 100vh;
}

.page-section { 
  display: none; padding: 1rem 1.5rem; 
  max-width: 580px; margin: 0 auto; 
  animation: fadeIn 0.4s ease-out forwards;
}
.page-section.active { display: block; }
.page-section.wide { max-width: 1200px; }

/* ───── Hero Header ───── */
.hero-header {
  text-align: center; margin-bottom: 2.5rem;
}
.hero-title {
  font-size: 2.5rem; font-weight: 800;
  line-height: 1.1; margin-bottom: 0.5rem;
  letter-spacing: -1px;
}
.text-gradient {
  background: var(--brand-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero-subtitle {
  font-size: 1.1rem; color: var(--text-secondary);
  font-weight: 400;
}

/* ───── Cards ───── */
.card {
  border-radius: 24px;
  padding: 2rem;
  position: relative;
  overflow: hidden;
}

.glass-card {
  background: var(--bg-card);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border-card);
  box-shadow: var(--shadow-card);
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.4s ease;
}

.glass-card:hover { 
  box-shadow: var(--shadow-elevated);
}

.card__title {
  font-size: 1.25rem; font-weight: 700;
  margin-bottom: 1.5rem;
  display: flex; align-items: center; gap: 0.75rem;
}

.card__title.justify-center {
  justify-content: center;
}

.icon-circle {
  width: 40px; height: 40px; border-radius: 12px;
  background: var(--bg-input);
  display: grid; place-items: center;
  font-size: 1.2rem;
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.02);
}

/* ───── Form Elements ───── */
.form-group { margin-bottom: 1.25rem; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }

.form-label {
  display: block; margin-bottom: 0.5rem;
  font-size: 0.85rem; font-weight: 600;
  color: var(--text-secondary);
}

.input-wrapper { position: relative; display: flex; align-items: center; }

.input-prefix, .input-icon {
  position: absolute; left: 1rem;
  color: var(--text-secondary);
  font-weight: 600; font-size: 1rem;
  pointer-events: none;
}

.form-input {
  width: 100%; padding: 0.85rem 1rem;
  border-radius: 16px;
  border: 2px solid var(--border-input);
  background: var(--bg-input);
  color: var(--text-primary);
  font-family: inherit; font-size: 1rem; font-weight: 500;
  transition: all 0.3s ease;
  outline: none;
}

.form-input.with-prefix { padding-left: 3.5rem; }
.form-input.with-icon { padding-left: 2.5rem; }

.form-input::placeholder { color: var(--text-muted); font-weight: 400; }

.form-input:focus {
  border-color: var(--brand-primary);
  background: transparent;
  box-shadow: 0 0 0 4px var(--brand-glow);
}

.form-input.error { 
  border-color: var(--danger); 
  animation: shake 0.4s ease-in-out; 
}

.form-input:disabled { opacity: 0.6; cursor: not-allowed; }

.error-msg {
  font-size: 0.8rem; font-weight: 500; color: var(--danger);
  margin-top: 0.4rem; display: none;
  animation: slideDown 0.3s ease;
}
.error-msg.visible { display: block; }

/* ───── Buttons ───── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  padding: 0.8rem 1.5rem; border-radius: 14px;
  font-family: inherit; font-size: 1rem; font-weight: 600;
  border: none; cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative; overflow: hidden;
}

.btn::after {
  content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(255,255,255,0.2); opacity: 0; transition: opacity 0.3s;
}

.btn:active { transform: scale(0.96); }
.btn:hover::after { opacity: 1; }
.btn:disabled { opacity: 0.5; pointer-events: none; }

.btn--primary {
  background: var(--brand-gradient); color: #fff;
  box-shadow: 0 6px 20px var(--brand-glow);
}
.btn--primary:hover { box-shadow: 0 8px 25px var(--brand-glow); transform: translateY(-2px); }

.btn--secondary {
  background: var(--bg-input); color: var(--text-primary);
}
.btn--secondary:hover { background: var(--border-input); }

.btn--danger { background: var(--brand-gradient); color: #fff; }

.btn--glow { animation: pulseGlow 2s infinite; }

.btn--outline {
  background: transparent; color: var(--text-primary);
  border: 2px solid var(--border-input);
}
.btn--outline:hover { border-color: var(--brand-primary); color: var(--brand-primary); }

.btn--whatsapp {
  background: var(--whatsapp-color); color: #fff;
  box-shadow: 0 6px 20px rgba(37,211,102,0.3);
}
.btn--whatsapp:hover { transform: translateY(-2px); box-shadow: 0 8px 25px rgba(37,211,102,0.4); }

.btn--ghost {
  background: transparent; color: var(--text-secondary);
}
.btn--ghost:hover { color: var(--text-primary); background: var(--bg-input); }

.btn--sm { padding: 0.5rem 1rem; font-size: 0.85rem; border-radius: 10px; }
.btn--lg { padding: 1rem 1.5rem; font-size: 1.1rem; }
.btn--block { width: 100%; }
.btn-row { display: flex; gap: 0.75rem; flex-wrap: wrap; margin-top: 1rem; }

.action-buttons {
  display: grid; grid-template-columns: 1fr auto; align-items: center;
}
@media (max-width: 480px) {
  .action-buttons { grid-template-columns: 1fr; }
}

.pulse-hover:hover { animation: pulse 1s infinite; }

/* ───── Modal ───── */
.modal-overlay {
  position: fixed; inset: 0; z-index: 200;
  background: var(--overlay);
  display: none; place-items: center;
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  animation: fadeIn 0.3s ease;
  padding: 1rem;
}
.modal-overlay.open { display: grid; }

.modal {
  width: 100%; max-width: 460px;
  max-height: 90vh; overflow-y: auto;
  border-radius: 24px;
  animation: scaleIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.glass-modal {
  background: var(--bg-modal);
  border: 1px solid var(--border-card);
  box-shadow: var(--shadow-elevated);
}

.modal__header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.5rem 1.5rem 1rem; border-bottom: 1px solid var(--border-input);
}

.modal__title { font-size: 1.2rem; font-weight: 700; display: flex; align-items: center; gap: 0.5rem; }

.modal__close {
  width: 36px; height: 36px; border-radius: 12px;
  display: grid; place-items: center;
  border: none; background: var(--bg-input);
  color: var(--text-secondary); cursor: pointer;
  transition: all 0.2s;
}
.modal__close:hover { background: var(--danger); color: #fff; transform: rotate(90deg); }

.modal__body { padding: 1.5rem; }

/* Profile details */
.profile-summary { text-align: center; margin-bottom: 1.5rem; }
.profile-number { font-size: 1.8rem; font-weight: 800; letter-spacing: 1px; color: var(--brand-primary); }

.section-title { font-size: 0.9rem; font-weight: 700; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 1rem; }
.flex-between { display: flex; justify-content: space-between; align-items: center; }

.badge { background: var(--brand-gradient); color: white; padding: 0.2rem 0.6rem; border-radius: 20px; font-size: 0.8rem; font-weight: 700; }

.divider { border: none; height: 1px; background: var(--border-input); margin: 1.5rem 0; }

/* ───── Loyalty Dots ───── */
.loyalty-progress-section {
  background: var(--bg-input); border-radius: 16px; padding: 1.25rem; margin-bottom: 1.5rem;
}

.dots-section { display: flex; flex-direction: column; gap: 0.75rem; }

.dots-cycle {
  display: flex; align-items: center; justify-content: space-between;
  background: var(--bg-card); padding: 0.75rem 1rem; border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.02);
}

.dots-cycle__label {
  font-size: 0.8rem; font-weight: 700; color: var(--text-muted);
  min-width: 40px;
}

.dots-row { display: flex; gap: 0.4rem; }

.dot {
  width: 18px; height: 18px; border-radius: 50%;
  background: var(--dot-empty);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  position: relative;
}

.dot.filled {
  background: var(--dot-filled);
  box-shadow: 0 0 10px var(--brand-glow);
  animation: popIn 0.5s ease-out forwards;
}

.dot.reward {
  background: linear-gradient(135deg, #FFD700, #FF8C00);
  box-shadow: 0 0 12px rgba(255, 215, 0, 0.6);
  transform: scale(1.1);
}

.reward-emojis { display: flex; gap: 0.5rem; flex-wrap: wrap; min-height: 40px; align-items: center; }
.reward-emoji { font-size: 1.8rem; animation: popIn 0.5s ease-out forwards; filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1)); }

/* ───── Eligibility Banner ───── */
.eligibility-banner {
  padding: 1rem; border-radius: 14px;
  display: flex; align-items: center; gap: 0.75rem;
  font-weight: 700; font-size: 1rem;
  margin-bottom: 1.5rem;
  animation: slideUp 0.4s ease;
}

.eligibility-banner.eligible {
  background: linear-gradient(135deg, rgba(16,185,129,0.1), rgba(16,185,129,0.2));
  border: 1px solid rgba(16,185,129,0.3);
  color: var(--success);
}

.eligibility-banner.not-eligible {
  background: var(--bg-input);
  border: 1px solid var(--border-input);
  color: var(--text-secondary);
}

/* ───── Entry Table ───── */
.glass-table-wrap {
  background: var(--bg-input); border-radius: 16px; padding: 1rem;
  max-height: 250px; overflow-y: auto;
}

.entry-table {
  width: 100%; border-collapse: separate; border-spacing: 0 0.5rem;
  font-size: 0.85rem;
}
.entry-table th {
  text-align: left; padding: 0.5rem;
  font-weight: 700; font-size: 0.75rem;
  text-transform: uppercase; letter-spacing: 1px;
  color: var(--text-muted);
}
.entry-table td {
  padding: 0.75rem 0.5rem;
  background: var(--bg-card);
  color: var(--text-primary); font-weight: 500;
}
.entry-table td:first-child { border-radius: 8px 0 0 8px; font-weight: 700; color: var(--text-muted); }
.entry-table td:last-child { border-radius: 0 8px 8px 0; }
.entry-table tr { box-shadow: 0 2px 4px rgba(0,0,0,0.02); transition: transform 0.2s; }
.entry-table tr:hover { transform: translateX(4px); }

/* ───── Toasts ───── */
.toast-container {
  position: fixed; top: 80px; right: 20px; z-index: 300;
  display: flex; flex-direction: column; gap: 0.75rem;
  pointer-events: none;
}

.toast {
  padding: 1rem 1.25rem; border-radius: 16px;
  font-size: 0.9rem; font-weight: 600;
  box-shadow: var(--shadow-elevated);
  animation: slideLeft 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  display: flex; align-items: center; gap: 0.75rem;
  max-width: 350px; color: #fff;
  backdrop-filter: blur(10px);
}
.toast--success { background: rgba(16, 185, 129, 0.9); }
.toast--error   { background: rgba(239, 68, 68, 0.9); }
.toast--info    { background: rgba(59, 130, 246, 0.9); }

/* ───── Loaders ───── */
.spinner {
  width: 20px; height: 20px;
  border: 3px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.8s cubic-bezier(0.5, 0, 0.5, 1) infinite;
  display: inline-block;
}

/* ───── ADMIN DASHBOARD ───── */
.dashboard-header {
  display: flex; justify-content: space-between; align-items: center; margin-bottom: 2rem; flex-wrap: wrap; gap: 1rem;
}
.dashboard-title { font-size: 2rem; font-weight: 800; letter-spacing: -1px; }
.date-badge { background: var(--bg-input); padding: 0.5rem 1rem; border-radius: 20px; font-weight: 600; font-size: 0.9rem; color: var(--text-secondary); }

.dashboard-grid {
  display: grid; grid-template-columns: 2fr 1fr; gap: 1.5rem;
}

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

.stat-card {
  background: var(--bg-card); border: 1px solid var(--border-card);
  border-radius: 20px; padding: 1.5rem;
  display: flex; flex-direction: column; justify-content: space-between;
  box-shadow: var(--shadow-card); transition: all 0.3s;
}
.stat-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-elevated); }

.stat-card__value {
  font-size: 2.2rem; font-weight: 800;
  background: var(--brand-gradient);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text; margin-bottom: 0.5rem;
}
.stat-card__label { font-size: 0.9rem; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: 1px; }

/* Chart Cards */
.chart-card { padding: 1.5rem; margin-bottom: 1.5rem; }
.chart-card__header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.5rem; flex-wrap: wrap; gap: 1rem; }
.chart-card__title { font-size: 1.1rem; font-weight: 700; display: flex; align-items: center; gap: 0.5rem; }
.chart-wrap { position: relative; width: 100%; height: 250px; }
.donut-wrap { height: 220px; }

.highlight-card { background: var(--brand-gradient); color: white; border: none; }
.highlight-card .chart-card__title { color: rgba(255,255,255,0.9); }
.huge-value { font-size: 3.5rem; font-weight: 800; line-height: 1; margin-top: 1rem; }

/* Toggles */
.toggle-row {
  display: inline-flex; background: var(--bg-input); border-radius: 12px; padding: 0.25rem;
}
.toggle-row.mini { background: rgba(0,0,0,0.2); }
.toggle-btn {
  padding: 0.5rem 1rem; font-size: 0.85rem; font-weight: 600; font-family: inherit;
  border: none; border-radius: 8px; cursor: pointer; background: transparent; color: var(--text-secondary); transition: all 0.2s;
}
.toggle-row.mini .toggle-btn { color: rgba(255,255,255,0.7); }
.toggle-btn.active { background: var(--bg-card); color: var(--text-primary); box-shadow: 0 2px 8px rgba(0,0,0,0.1); }
.toggle-row.mini .toggle-btn.active { background: white; color: var(--brand-primary); }

/* Top List */
.top-list { list-style: none; display: flex; flex-direction: column; gap: 0.75rem; }
.top-list li {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.75rem 1rem; background: var(--bg-input); border-radius: 12px; font-weight: 600;
  transition: transform 0.2s;
}
.top-list li:hover { transform: translateX(5px); }
.top-list__rank {
  width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center;
  font-size: 0.8rem; font-weight: 800; background: var(--bg-card); color: var(--text-secondary); margin-right: 0.75rem;
}
.top-list li:nth-child(1) .top-list__rank { background: linear-gradient(135deg, #FDE68A, #F59E0B); color: #78350F; }
.top-list li:nth-child(2) .top-list__rank { background: linear-gradient(135deg, #E5E7EB, #9CA3AF); color: #1F2937; }
.top-list li:nth-child(3) .top-list__rank { background: linear-gradient(135deg, #FDBA74, #D97706); color: #78350F; }

/* Heatmap */
.heatmap-wrapper { overflow-x: auto; padding-bottom: 1rem; }
.heatmap-grid { display: grid; grid-template-columns: 40px repeat(24, 1fr); gap: 3px; font-size: 0.7rem; min-width: 600px; }
.heatmap-label { display: flex; align-items: center; font-weight: 600; color: var(--text-muted); justify-content: flex-end; padding-right: 8px; }
.heatmap-header { text-align: center; font-weight: 600; color: var(--text-muted); margin-bottom: 4px; }
.heatmap-cell {
  aspect-ratio: 1; border-radius: 4px; background: var(--dot-empty);
  position: relative; cursor: pointer; transition: transform 0.2s, box-shadow 0.2s;
}
.heatmap-cell:hover { transform: scale(1.5); z-index: 10; box-shadow: 0 4px 10px rgba(0,0,0,0.2); }
.heatmap-tooltip {
  display: none; position: absolute; bottom: calc(100% + 5px); left: 50%; transform: translateX(-50%);
  background: var(--bg-modal); color: var(--text-primary); padding: 0.4rem 0.6rem; border-radius: 8px;
  font-size: 0.75rem; font-weight: 600; white-space: nowrap; box-shadow: var(--shadow-elevated); z-index: 20;
}
.heatmap-cell:hover .heatmap-tooltip { display: block; animation: fadeIn 0.2s; }

/* Mini stats row */
.tbv-stats-mini { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }
.tbv-stats-mini .stat-card { padding: 1rem; border-radius: 12px; }
.tbv-stats-mini .stat-card__value { font-size: 1.4rem; }

/* ───── Animations ───── */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
@keyframes slideDown { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }
@keyframes slideLeft { from { opacity: 0; transform: translateX(50px); } to { opacity: 1; transform: translateX(0); } }
@keyframes scaleIn { from { opacity: 0; transform: scale(0.95); } to { opacity: 1; transform: scale(1); } }
@keyframes popIn { 0% { transform: scale(0.5); opacity: 0; } 70% { transform: scale(1.1); } 100% { transform: scale(1); opacity: 1; } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes shake { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-5px); } 75% { transform: translateX(5px); } }
@keyframes pulseGlow { 0%, 100% { box-shadow: 0 0 0 0 var(--brand-glow); } 50% { box-shadow: 0 0 0 10px rgba(255,75,43,0); } }
@keyframes pulse { 0% { transform: scale(1); } 50% { transform: scale(1.02); } 100% { transform: scale(1); } }

/* Utility */
.text-center { text-align: center; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mr-1 { margin-right: 0.5rem; }
.hidden { display: none !important; }
.fade-in { animation: fadeIn 0.5s ease forwards; }
.slide-up { animation: slideUp 0.5s ease forwards; }

/* ───── Responsive ───── */
@media (max-width: 992px) {
  .dashboard-grid { grid-template-columns: 1fr; }
  .tbv-stats-mini { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 600px) {
  .navbar__container { padding: 0 1rem; }
  .navbar__brand span { font-size: 1.1rem; }
  
  .nav-dock {
    width: 90%;
    max-width: 400px;
    justify-content: space-between;
    gap: 0;
  }
  .nav-btn {
    flex: 1;
    justify-content: center;
    padding: 0.75rem 0.5rem;
  }
  .nav-text {
    font-size: 0.85rem;
  }
  
  .page-section { padding: 1rem; }
  .hero-title { font-size: 2rem; }
  .card { padding: 1.5rem; }
  .stats-grid { grid-template-columns: 1fr 1fr; gap: 1rem; }
  .stat-card__value { font-size: 1.8rem; }
  .form-grid { grid-template-columns: 1fr; gap: 0; }
  .dots-row { flex-wrap: wrap; }
}

/* Custom Scrollbar */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border-input); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* ───── POS SYSTEM STYLES ───── */

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

.pos-table-card {
  background: var(--bg-card);
  border: 2px solid var(--border-input);
  border-radius: 16px;
  padding: 1.5rem 1rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: var(--shadow-card);
}

.pos-table-card:hover {
  border-color: var(--brand-primary);
  transform: translateY(-5px);
  box-shadow: var(--shadow-elevated);
}

.pos-table-card .table-icon {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

.pos-table-card .table-name {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text-primary);
}

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

.pos-category-card {
  background: var(--brand-gradient);
  color: white;
  border-radius: 16px;
  padding: 2rem 1rem;
  text-align: center;
  font-weight: 700;
  font-size: 1.2rem;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 10px 30px var(--brand-glow);
}

.pos-category-card:hover {
  transform: translateY(-5px) scale(1.02);
  box-shadow: 0 15px 35px var(--brand-glow);
}

.pos-dishes-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1.5rem;
}

@media (max-width: 1200px) {
  .pos-dishes-grid { grid-template-columns: repeat(4, 1fr); }
}

@media (max-width: 900px) {
  .pos-dishes-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 600px) {
  .pos-dishes-grid { grid-template-columns: repeat(2, 1fr); }
}

.pos-dish-card {
  background: var(--bg-card);
  border: 1px solid var(--border-input);
  border-radius: 16px;
  padding: 1.25rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: var(--shadow-card);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.pos-dish-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-elevated);
}

.pos-dish-name {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  word-wrap: break-word;
}

.pos-dish-price {
  font-weight: 600;
  color: var(--brand-primary);
  margin-bottom: 1rem;
  font-size: 1rem;
}

.qty-selector {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: var(--bg-input);
  border-radius: 12px;
  padding: 0.25rem;
}

.qty-btn {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  border: none;
  background: var(--bg-card);
  color: var(--text-primary);
  font-weight: 700;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: all 0.2s ease;
  box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.qty-btn:hover {
  background: var(--brand-primary);
  color: white;
}

.qty-display {
  font-weight: 700;
  width: 30px;
  text-align: center;
}
