/* ============================================================
   PRINCE CREPS & COFFEE — POS SYSTEM
   Design System & Global Styles
   Dark Glassmorphism Theme
   ============================================================ */

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

/* ============================================================
   CSS VARIABLES
   ============================================================ */

:root {
  --bg-primary: #0d0d15;
  --bg-secondary: #12121d;
  --bg-tertiary: #191928;

  --surface: rgba(255, 255, 255, 0.04);
  --surface-hover: rgba(255, 255, 255, 0.07);
  --surface-active: rgba(255, 255, 255, 0.10);

  --glass: rgba(255, 255, 255, 0.05);
  --glass-border: rgba(255, 255, 255, 0.08);
  --glass-hover: rgba(255, 255, 255, 0.10);

  --primary: #F5A623;
  --primary-light: #FFC058;
  --primary-dark: #D48806;
  --primary-glow: rgba(245, 166, 35, 0.25);
  --primary-bg: rgba(245, 166, 35, 0.1);
  --primary-rgb: 245, 166, 35;

  --accent: #006cb5;
  --accent-light: #2d9ae6;
  --accent-dark: #004d80;
  --accent-rgb: 0, 108, 181;

  --success: #4ECB71;
  --success-bg: rgba(78, 203, 113, 0.12);
  --warning: #FFB84D;
  --warning-bg: rgba(255, 184, 77, 0.12);
  --danger: #FF4757;
  --danger-bg: rgba(255, 71, 87, 0.12);
  --info: #54A0FF;
  --info-bg: rgba(84, 160, 255, 0.12);
  --danger-rgb: 255, 71, 87;

  --text-primary: #EAEAF2;
  --text-secondary: #8E8EA8;
  --text-tertiary: #5A5A72;
  --text-inverse: #0d0d15;

  --border: rgba(255, 255, 255, 0.06);
  --border-light: rgba(255, 255, 255, 0.12);

  --gradient-primary: linear-gradient(135deg, #F5A623 0%, #FFC058 100%);
  --gradient-accent: linear-gradient(135deg, #006cb5 0%, #2d9ae6 100%);
  --gradient-success: linear-gradient(135deg, #4ECB71 0%, #6BDB8B 100%);
  --gradient-danger: linear-gradient(135deg, #FF4757 0%, #FF6B6B 100%);
  --gradient-bg: linear-gradient(160deg, #0d0d15 0%, #12121d 40%, #191928 100%);
  --gradient-card: linear-gradient(145deg, rgba(255,255,255,0.06) 0%, rgba(255,255,255,0.01) 100%);

  --font-heading: 'Bricolage Grotesque', -apple-system, sans-serif;
  --font-body: 'Manrope', -apple-system, sans-serif;

  --space-2xs: 2px;
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 32px;
  --space-2xl: 48px;
  --space-3xl: 64px;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;

  --shadow-sm: 0 2px 8px rgba(0,0,0,0.25);
  --shadow-md: 0 4px 20px rgba(0,0,0,0.35);
  --shadow-lg: 0 8px 40px rgba(0,0,0,0.45);
  --shadow-glow: 0 0 30px var(--primary-glow);

  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 250ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 400ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-bounce: 500ms cubic-bezier(0.34, 1.56, 0.64, 1);

  --navbar-height: 64px;
}

/* ============================================================
   RESET & BASE
   ============================================================ */

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  background:
    radial-gradient(600px 600px at 12% 10%, rgba(var(--primary-rgb), 0.12), transparent 60%),
    radial-gradient(700px 500px at 85% 18%, rgba(var(--accent-rgb), 0.12), transparent 60%),
    radial-gradient(700px 600px at 50% 90%, rgba(var(--primary-rgb), 0.08), transparent 60%),
    var(--gradient-bg);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

a {
  color: var(--primary-light);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover { color: var(--primary); }

img { max-width: 100%; display: block; }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.3;
  color: var(--text-primary);
}

h1 { font-size: 2rem; }
h2 { font-size: 1.5rem; }
h3 { font-size: 1.25rem; }
h4 { font-size: 1.1rem; }

/* Scrollbar */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
  background: rgba(255,255,255,0.12);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.2); }

/* ============================================================
   NAVBAR
   ============================================================ */

.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--navbar-height);
  background: rgba(10, 10, 26, 0.85);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-bottom: 1px solid var(--border);
  z-index: 1000;
}

.navbar-inner {
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
  height: 100%;
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.navbar-brand {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  text-decoration: none;
  color: var(--text-primary);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.15rem;
  flex-shrink: 0;
}

.brand-icon {
  font-size: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: var(--gradient-primary);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-glow);
}

.brand-text {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.navbar-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  cursor: pointer;
  padding: var(--space-sm);
  border-radius: var(--radius-sm);
  transition: background var(--transition-fast);
}
.navbar-toggle:hover { background: var(--surface-hover); }

.navbar-links {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  margin-left: auto;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--space-md);
  color: var(--text-secondary);
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
  text-decoration: none;
  white-space: nowrap;
}

.nav-link:hover {
  color: var(--text-primary);
  background: var(--surface-hover);
}

.nav-link.active {
  color: var(--primary-light);
  background: var(--primary-bg);
}

.nav-link svg { flex-shrink: 0; }

/* Mobile navbar */
@media (max-width: 768px) {
  .navbar-toggle { display: block; }

  .navbar-links {
    display: none;
    position: absolute;
    top: var(--navbar-height);
    left: 0;
    right: 0;
    background: rgba(10, 10, 26, 0.95);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    padding: var(--space-sm);
    gap: var(--space-2xs);
  }

  .navbar-links.show { display: flex; }

  .nav-link {
    width: 100%;
    padding: var(--space-md);
    border-radius: var(--radius-md);
  }
}

/* ============================================================
   PAGE LAYOUT
   ============================================================ */

.page-container {
  padding-top: calc(var(--navbar-height) + var(--space-lg));
  padding-left: var(--space-lg);
  padding-right: var(--space-lg);
  padding-bottom: var(--space-2xl);
  max-width: 1440px;
  margin: 0 auto;
}

.page-header {
  margin-bottom: var(--space-xl);
}

.page-title {
  font-size: 1.75rem;
  font-weight: 800;
  margin-bottom: var(--space-xs);
}

.page-subtitle {
  color: var(--text-secondary);
  font-size: 0.9rem;
}

/* ============================================================
   CARDS
   ============================================================ */

.card {
  background: var(--gradient-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  transition: all var(--transition-normal);
}

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

.card-flat {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-lg);
}

.card-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
}

/* Stat cards */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--space-md);
  margin-bottom: var(--space-xl);
}

.stat-card {
  background: var(--gradient-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  position: relative;
  overflow: hidden;
}

.stat-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.stat-card.purple::before { background: var(--gradient-primary); }
.stat-card.coral::before { background: var(--gradient-accent); }
.stat-card.green::before { background: var(--gradient-success); }
.stat-card.blue::before { background: linear-gradient(135deg, #54A0FF, #78B8FF); }

.stat-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-md);
}

.stat-icon.purple { background: var(--primary-bg); color: var(--primary-light); }
.stat-icon.coral { background: rgba(var(--accent-rgb), 0.12); color: var(--accent-light); }
.stat-icon.green { background: var(--success-bg); color: var(--success); }
.stat-icon.blue { background: var(--info-bg); color: var(--info); }

.stat-value {
  font-family: var(--font-heading);
  font-size: 1.75rem;
  font-weight: 800;
  margin-bottom: var(--space-2xs);
  line-height: 1.2;
}

.stat-label {
  color: var(--text-secondary);
  font-size: 0.8rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ============================================================
   BUTTONS
   ============================================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: 10px 20px;
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 600;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-fast);
  text-decoration: none;
  white-space: nowrap;
  line-height: 1.4;
}

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

.btn-primary {
  background: var(--gradient-primary);
  color: white;
  box-shadow: 0 4px 15px var(--primary-glow);
}
.btn-primary:hover {
  box-shadow: 0 6px 25px var(--primary-glow);
  transform: translateY(-1px);
}

.btn-accent {
  background: var(--gradient-accent);
  color: white;
  box-shadow: 0 4px 15px rgba(var(--accent-rgb), 0.25);
}

.btn-success {
  background: var(--gradient-success);
  color: var(--text-inverse);
}

.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border-light);
}
.btn-outline:hover {
  background: var(--surface-hover);
  border-color: var(--primary);
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  padding: var(--space-sm);
}
.btn-ghost:hover {
  background: var(--surface-hover);
  color: var(--text-primary);
}

.btn-danger {
  background: var(--danger-bg);
  color: var(--danger);
  border: 1px solid rgba(255,71,87,0.2);
}
.btn-danger:hover {
  background: rgba(255,71,87,0.2);
}

.btn-sm {
  padding: 6px 12px;
  font-size: 0.8rem;
  border-radius: var(--radius-sm);
}

.btn-lg {
  padding: 14px 28px;
  font-size: 1rem;
  border-radius: var(--radius-lg);
}

.btn-block {
  width: 100%;
}

.btn-icon {
  width: 36px;
  height: 36px;
  padding: 0;
  border-radius: var(--radius-sm);
}

.btn:disabled, .btn.disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

/* ============================================================
   FORM INPUTS
   ============================================================ */

.form-group {
  margin-bottom: var(--space-md);
}

.form-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: var(--space-sm);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 10px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 0.9rem;
  transition: all var(--transition-fast);
  outline: none;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
  background: var(--surface-hover);
}

.form-input::placeholder { color: var(--text-tertiary); }
.form-textarea { resize: vertical; min-height: 80px; }

.form-select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%238E8EA8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}

.form-select option {
  background: var(--bg-secondary);
  color: var(--text-primary);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-md);
}

.input-group {
  display: flex;
  gap: 0;
}

.input-group .form-input {
  border-radius: var(--radius-md) 0 0 var(--radius-md);
}

.input-group .btn {
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  flex-shrink: 0;
}

/* Search input */
.search-wrap {
  position: relative;
}

.search-wrap svg {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-tertiary);
  pointer-events: none;
}

.search-wrap .form-input {
  padding-left: 42px;
}

/* ============================================================
   MODAL
   ============================================================ */

.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 2000;
  align-items: center;
  justify-content: center;
  padding: var(--space-md);
}

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

.modal {
  background: var(--bg-secondary);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  animation: modalSlideUp 0.3s var(--transition-normal);
  box-shadow: var(--shadow-lg);
}

.modal-lg { max-width: 720px; }
.modal-sm { max-width: 380px; }

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-lg);
  border-bottom: 1px solid var(--border);
}

.modal-title {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 700;
}

.modal-close {
  background: none;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  padding: var(--space-sm);
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
  display: flex;
}
.modal-close:hover {
  background: var(--surface-hover);
  color: var(--text-primary);
}

.modal-body {
  padding: var(--space-lg);
}

.modal-footer {
  display: flex;
  gap: var(--space-sm);
  justify-content: flex-end;
  padding: var(--space-md) var(--space-lg);
  border-top: 1px solid var(--border);
}

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

/* ============================================================
   TABLE
   ============================================================ */

.table-wrap {
  overflow-x: auto;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
}

.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}

.table th {
  text-align: left;
  padding: 12px 16px;
  background: var(--surface);
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

.table td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  color: var(--text-primary);
  vertical-align: middle;
}

.table tr:last-child td { border-bottom: none; }

.table tr:hover td {
  background: var(--surface);
}

/* ============================================================
   BADGES & PILLS
   ============================================================ */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  font-size: 0.7rem;
  font-weight: 600;
  border-radius: var(--radius-full);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.badge-success {
  background: var(--success-bg);
  color: var(--success);
}

.badge-danger {
  background: var(--danger-bg);
  color: var(--danger);
}

.badge-warning {
  background: var(--warning-bg);
  color: var(--warning);
}

.badge-info {
  background: var(--info-bg);
  color: var(--info);
}

.badge-purple {
  background: var(--primary-bg);
  color: var(--primary-light);
}

/* ============================================================
   PROGRESS BAR
   ============================================================ */

.progress {
  width: 100%;
  height: 8px;
  background: var(--surface);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  border-radius: var(--radius-full);
  transition: width var(--transition-slow);
  background: var(--gradient-primary);
}

.progress-bar.danger { background: var(--gradient-danger); }
.progress-bar.success { background: var(--gradient-success); }
.progress-bar.warning { background: linear-gradient(135deg, #FFB84D, #FFD088); }

/* ============================================================
   PRODUCT GRID (POS)
   ============================================================ */

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: var(--space-md);
}

.product-card {
  background: var(--gradient-card);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  padding: var(--space-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  text-align: center;
  position: relative;
  overflow: hidden;
}

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

.product-card:active {
  transform: scale(0.97);
}

.product-img {
  width: 100%;
  aspect-ratio: 1;
  border-radius: var(--radius-md);
  margin-bottom: var(--space-sm);
  object-fit: cover;
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  color: var(--text-tertiary);
  overflow: hidden;
}

.product-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-name {
  font-weight: 600;
  font-size: 0.85rem;
  margin-bottom: var(--space-xs);
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-price {
  color: var(--primary-light);
  font-weight: 700;
  font-size: 0.9rem;
  font-family: var(--font-heading);
}

.product-category {
  position: absolute;
  top: var(--space-sm);
  right: var(--space-sm);
  padding: 2px 8px;
  font-size: 0.65rem;
  font-weight: 600;
  background: var(--primary-bg);
  color: var(--primary-light);
  border-radius: var(--radius-full);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

/* ============================================================
   CART
   ============================================================ */

.cart-section {
  background: var(--gradient-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  height: calc(100vh - var(--navbar-height) - var(--space-xl));
  position: sticky;
  top: calc(var(--navbar-height) + var(--space-md));
}

.cart-header {
  padding: var(--space-md) var(--space-lg);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}

.cart-header h3 {
  font-size: 1rem;
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.cart-count {
  background: var(--primary);
  color: white;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  font-size: 0.7rem;
  font-weight: 700;
}

.cart-items {
  flex: 1;
  overflow-y: auto;
  padding: var(--space-md);
}

.cart-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: var(--text-tertiary);
  text-align: center;
  padding: var(--space-xl);
}

.cart-empty svg {
  margin-bottom: var(--space-md);
  opacity: 0.4;
}

.cart-empty p {
  font-size: 0.85rem;
}

.cart-item {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm) 0;
  border-bottom: 1px solid var(--border);
  animation: fadeIn 0.3s ease;
}

.cart-item:last-child { border-bottom: none; }

.cart-item-info {
  flex: 1;
  min-width: 0;
}

.cart-item-name {
  font-size: 0.85rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cart-item-price {
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.cart-item-qty {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
}

.qty-btn {
  width: 28px;
  height: 28px;
  border: 1px solid var(--border-light);
  background: var(--surface);
  color: var(--text-primary);
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: 600;
  transition: all var(--transition-fast);
}

.qty-btn:hover {
  background: var(--primary-bg);
  border-color: var(--primary);
  color: var(--primary-light);
}

.qty-value {
  font-weight: 700;
  font-size: 0.85rem;
  min-width: 24px;
  text-align: center;
}

.cart-item-total {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--primary-light);
  min-width: 70px;
  text-align: right;
}

.cart-item-remove {
  background: none;
  border: none;
  color: var(--text-tertiary);
  cursor: pointer;
  padding: 4px;
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
  display: flex;
}
.cart-item-remove:hover {
  color: var(--danger);
  background: var(--danger-bg);
}

/* Cart summary */
.cart-summary {
  padding: var(--space-md) var(--space-lg);
  border-top: 1px solid var(--border);
  flex-shrink: 0;
}

.cart-summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-xs) 0;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.cart-summary-row.total {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--text-primary);
  padding-top: var(--space-sm);
  margin-top: var(--space-sm);
  border-top: 2px solid var(--primary);
  font-family: var(--font-heading);
}

.cart-summary-row.total .cart-total-value {
  color: var(--primary-light);
}

.cart-discount {
  display: flex;
  gap: var(--space-sm);
  margin-bottom: var(--space-sm);
}

.cart-actions {
  padding: var(--space-md) var(--space-lg);
  display: flex;
  gap: var(--space-sm);
  flex-shrink: 0;
}

/* ============================================================
   POS LAYOUT (Split View)
   ============================================================ */

.pos-layout {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: var(--space-lg);
  padding-top: calc(var(--navbar-height) + var(--space-lg));
  padding-left: var(--space-lg);
  padding-right: var(--space-lg);
  padding-bottom: var(--space-lg);
  min-height: 100vh;
}

.pos-products {
  min-width: 0;
}

.pos-toolbar {
  display: flex;
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
  flex-wrap: wrap;
}

.pos-toolbar .search-wrap { flex: 1; min-width: 200px; }

.category-filters {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.category-btn {
  padding: 8px 16px;
  font-size: 0.8rem;
  font-weight: 600;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
}

.category-btn:hover {
  background: var(--surface-hover);
  color: var(--text-primary);
}

.category-btn.active {
  background: var(--primary-bg);
  border-color: var(--primary);
  color: var(--primary-light);
}

@media (max-width: 1024px) {
  .pos-layout {
    grid-template-columns: 1fr;
  }

  .cart-section {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: auto;
    max-height: 70vh;
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    z-index: 500;
    transform: translateY(calc(100% - 60px));
    transition: transform var(--transition-slow);
    box-shadow: 0 -8px 40px rgba(0,0,0,0.5);
  }

  .cart-section.expanded {
    transform: translateY(0);
  }

  .cart-toggle-bar {
    display: flex !important;
    align-items: center;
    justify-content: center;
    padding: var(--space-sm);
    cursor: pointer;
  }

  .cart-toggle-bar .bar {
    width: 40px;
    height: 4px;
    background: var(--text-tertiary);
    border-radius: var(--radius-full);
  }

  .pos-products {
    padding-bottom: 80px;
  }
}

@media (min-width: 1025px) {
  .cart-toggle-bar { display: none; }
}

/* ============================================================
   RECEIPT / STRUK
   ============================================================ */

.receipt {
  background: white;
  color: #333;
  padding: 24px;
  max-width: 320px;
  margin: 0 auto;
  font-family: 'Courier New', monospace;
  font-size: 12px;
  line-height: 1.4;
}

.receipt-header {
  text-align: center;
  padding-bottom: 12px;
  border-bottom: 2px dashed #ccc;
  margin-bottom: 12px;
}

.receipt-logo {
  font-size: 18px;
  font-weight: bold;
  color: #333;
  margin-bottom: 4px;
}

.receipt-info { color: #666; font-size: 11px; }

.receipt-divider {
  border: none;
  border-top: 1px dashed #ccc;
  margin: 8px 0;
}

.receipt-items { margin-bottom: 8px; }

.receipt-item {
  display: flex;
  justify-content: space-between;
  padding: 3px 0;
}

.receipt-item-detail {
  color: #888;
  font-size: 10px;
  padding-left: 8px;
}

.receipt-summary {
  border-top: 2px dashed #ccc;
  padding-top: 8px;
  margin-top: 8px;
}

.receipt-row {
  display: flex;
  justify-content: space-between;
  padding: 2px 0;
}

.receipt-row.total {
  font-size: 16px;
  font-weight: bold;
  border-top: 2px solid #333;
  padding-top: 6px;
  margin-top: 4px;
}

.receipt-footer {
  text-align: center;
  margin-top: 16px;
  padding-top: 12px;
  border-top: 2px dashed #ccc;
  color: #666;
  font-size: 11px;
}

.receipt-footer .thanks {
  font-size: 13px;
  font-weight: bold;
  color: #333;
  margin-top: 8px;
}

/* ============================================================
   CUSTOMER MENU PAGE
   ============================================================ */

.customer-hero {
  text-align: center;
  padding: var(--space-3xl) var(--space-lg);
  position: relative;
  overflow: hidden;
}

.customer-hero::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at center, var(--primary-glow) 0%, transparent 60%);
  animation: heroGlow 6s ease-in-out infinite alternate;
}

@keyframes heroGlow {
  0% { transform: scale(1); opacity: 0.5; }
  100% { transform: scale(1.1); opacity: 0.8; }
}

.customer-hero h1 {
  font-size: 2.5rem;
  font-weight: 800;
  position: relative;
  z-index: 1;
  margin-bottom: var(--space-sm);
}

.customer-hero p {
  color: var(--text-secondary);
  font-size: 1.1rem;
  position: relative;
  z-index: 1;
}

.menu-tabs {
  display: flex;
  justify-content: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-xl);
}

.menu-tab {
  padding: 12px 32px;
  font-size: 0.9rem;
  font-weight: 600;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-normal);
}

.menu-tab:hover {
  background: var(--surface-hover);
  color: var(--text-primary);
}

.menu-tab.active {
  background: var(--gradient-primary);
  border-color: transparent;
  color: white;
  box-shadow: var(--shadow-glow);
}

.customer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--space-lg);
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.menu-card {
  background: var(--gradient-card);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-xl);
  overflow: hidden;
  transition: all var(--transition-normal);
}

.menu-card:hover {
  border-color: var(--primary);
  transform: translateY(-4px);
  box-shadow: var(--shadow-glow);
}

.menu-card-img {
  width: 100%;
  aspect-ratio: 4/3;
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 4rem;
  position: relative;
  overflow: hidden;
}

.menu-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.menu-card-body {
  padding: var(--space-lg);
}

.menu-card-category {
  display: inline-block;
  padding: 3px 10px;
  font-size: 0.65rem;
  font-weight: 700;
  background: var(--primary-bg);
  color: var(--primary-light);
  border-radius: var(--radius-full);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: var(--space-sm);
}

.menu-card-name {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: var(--space-xs);
}

.menu-card-desc {
  color: var(--text-secondary);
  font-size: 0.85rem;
  margin-bottom: var(--space-md);
  line-height: 1.5;
}

.menu-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.menu-card-price {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--primary-light);
}

/* ============================================================
   FILTER TOOLBAR
   ============================================================ */

.toolbar {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
  flex-wrap: wrap;
}

.toolbar .search-wrap { flex: 1; min-width: 200px; }

/* ============================================================
   LOADING
   ============================================================ */

.loading-spinner {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-3xl);
}

.spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

.skeleton {
  background: linear-gradient(90deg, var(--surface) 25%, var(--surface-hover) 50%, var(--surface) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: var(--radius-md);
}

@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ============================================================
   TOAST NOTIFICATIONS
   ============================================================ */

#toast-container {
  position: fixed;
  top: calc(var(--navbar-height) + var(--space-md));
  right: var(--space-md);
  z-index: 3000;
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  pointer-events: none;
}

.toast {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: 12px 18px;
  background: var(--bg-secondary);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  font-size: 0.85rem;
  transform: translateX(120%);
  transition: all var(--transition-normal);
  pointer-events: auto;
  max-width: 380px;
}

.toast-show { transform: translateX(0); }
.toast-hide { transform: translateX(120%); opacity: 0; }

.toast-icon { flex-shrink: 0; display: flex; }
.toast-msg { flex: 1; }

.toast-success { border-left: 3px solid var(--success); }
.toast-success .toast-icon { color: var(--success); }

.toast-error { border-left: 3px solid var(--danger); }
.toast-error .toast-icon { color: var(--danger); }

.toast-info { border-left: 3px solid var(--info); }
.toast-info .toast-icon { color: var(--info); }

.toast-warning { border-left: 3px solid var(--warning); }
.toast-warning .toast-icon { color: var(--warning); }

/* ============================================================
   TAB SWITCH
   ============================================================ */

.tab-group {
  display: flex;
  gap: var(--space-xs);
  background: var(--surface);
  padding: var(--space-xs);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
}

.tab-btn {
  padding: 8px 16px;
  font-size: 0.8rem;
  font-weight: 600;
  background: transparent;
  border: none;
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.tab-btn:hover { color: var(--text-primary); }

.tab-btn.active {
  background: var(--primary);
  color: white;
}

/* ============================================================
   QRIS DISPLAY
   ============================================================ */

.qris-display {
  text-align: center;
  padding: var(--space-lg);
}

.qris-img {
  max-width: 250px;
  margin: 0 auto var(--space-md);
  background: white;
  padding: var(--space-md);
  border-radius: var(--radius-lg);
}

.qris-img img {
  width: 100%;
}

.qris-placeholder {
  width: 250px;
  height: 250px;
  margin: 0 auto var(--space-md);
  background: white;
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #999;
  font-size: 0.85rem;
}

.qris-amount {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--primary-light);
  margin-bottom: var(--space-sm);
}

/* ============================================================
   EMPTY STATE
   ============================================================ */

.empty-state {
  text-align: center;
  padding: var(--space-3xl) var(--space-xl);
  color: var(--text-tertiary);
}

.empty-state svg {
  margin-bottom: var(--space-md);
  opacity: 0.3;
}

.empty-state h3 {
  color: var(--text-secondary);
  margin-bottom: var(--space-sm);
}

.empty-state p {
  font-size: 0.85rem;
  max-width: 300px;
  margin: 0 auto;
}

/* ============================================================
   TOGGLE / SWITCH
   ============================================================ */

.toggle {
  width: 44px;
  height: 24px;
  background: var(--surface-active);
  border-radius: var(--radius-full);
  position: relative;
  cursor: pointer;
  transition: background var(--transition-fast);
  border: none;
  flex-shrink: 0;
}

.toggle::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  background: white;
  border-radius: 50%;
  transition: transform var(--transition-fast);
}

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

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

/* ============================================================
   ANIMATIONS
   ============================================================ */

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

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

@keyframes slideInRight {
  from { opacity: 0; transform: translateX(20px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

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

.animate-fade-in { animation: fadeIn 0.4s ease; }
.animate-fade-in-up { animation: fadeInUp 0.5s ease; }
.animate-slide-in { animation: slideInRight 0.4s ease; }
.animate-scale-in { animation: scaleIn 0.3s ease; }

/* ============================================================
   RESPONSIVE UTILITIES
   ============================================================ */

.desktop-only { display: block; }
.mobile-only { display: none; }

@media (max-width: 768px) {
  .desktop-only { display: none !important; }
  .mobile-only { display: block !important; }

  h1 { font-size: 1.5rem; }
  h2 { font-size: 1.25rem; }

  .page-container {
    padding-left: var(--space-md);
    padding-right: var(--space-md);
  }

  .stat-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .product-grid {
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: var(--space-sm);
  }

  .product-card {
    padding: var(--space-sm);
  }

  .product-name { font-size: 0.78rem; }
  .product-price { font-size: 0.8rem; }

  .customer-hero h1 { font-size: 1.75rem; }
  .customer-grid {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: var(--space-md);
    padding: 0 var(--space-md);
  }

  .form-row { grid-template-columns: 1fr; }

  .toolbar {
    flex-direction: column;
    align-items: stretch;
  }

  .toolbar .search-wrap { min-width: 100%; }
}

@media (max-width: 480px) {
  .stat-grid {
    grid-template-columns: 1fr;
  }

  .customer-grid {
    grid-template-columns: 1fr;
  }

  .menu-tabs {
    flex-wrap: wrap;
  }

  .menu-tab {
    padding: 10px 20px;
    font-size: 0.8rem;
  }
}

/* ============================================================
   PRINT STYLES
   ============================================================ */

@media print {
  body {
    background: white !important;
    color: #333 !important;
  }

  .navbar, .no-print, .cart-actions, .modal-footer {
    display: none !important;
  }

  .receipt {
    max-width: 100%;
    margin: 0;
    padding: 10px;
    border: none;
    box-shadow: none;
  }

  .modal-overlay {
    position: static;
    background: none;
    backdrop-filter: none;
  }

  .modal {
    box-shadow: none;
    border: none;
    max-width: 100%;
  }
}

/* ============================================================
   UTILITY CLASSES
   ============================================================ */

.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.gap-xs { gap: var(--space-xs); }
.gap-sm { gap: var(--space-sm); }
.gap-md { gap: var(--space-md); }
.gap-lg { gap: var(--space-lg); }
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-sm { font-size: 0.8rem; }
.text-xs { font-size: 0.7rem; }
.text-secondary { color: var(--text-secondary); }
.text-success { color: var(--success); }
.text-danger { color: var(--danger); }
.text-primary { color: var(--primary-light); }
.font-bold { font-weight: 700; }
.font-heading { font-family: var(--font-heading); }
.mt-sm { margin-top: var(--space-sm); }
.mt-md { margin-top: var(--space-md); }
.mt-lg { margin-top: var(--space-lg); }
.mb-sm { margin-bottom: var(--space-sm); }
.mb-md { margin-bottom: var(--space-md); }
.mb-lg { margin-bottom: var(--space-lg); }
.w-full { width: 100%; }
.truncate {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ============================================================
   BRAND LOGO & CUSTOM FOOTER ATTRIBUTIONS
   ============================================================ */

.brand-logo-img {
  height: 40px;
  width: 40px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--primary);
  box-shadow: 0 0 10px var(--primary-glow);
}

.customer-hero-logo {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: var(--space-md);
  border: 3px solid var(--primary);
  box-shadow: var(--shadow-glow);
  position: relative;
  z-index: 1;
}

.admin-footer {
  text-align: center;
  padding-top: var(--space-lg);
  margin-top: var(--space-2xl);
  border-top: 1px solid var(--border);
  color: var(--text-secondary);
  font-size: 0.8rem;
  opacity: 0.7;
}
