/* ====================================================================
   BONDOUT DIMSUM POS - RESPONSIVE STYLESHEET
   Tema: Modern, Clean, Elegan (Merah Marun, Emas, & Putih)
   Optimal untuk Layar Handphone (Android & iPhone), Tablet, & Desktop
   ==================================================================== */

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

:root {
  --primary-maroon: #7A0C1E;
  --primary-maroon-dark: #580614;
  --primary-maroon-light: #9B152B;
  --accent-gold: #D4AF37;
  --accent-gold-dark: #B8860B;
  --accent-gold-light: #F6E05E;
}

html, body {
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  max-width: 100vw;
}

/* Touch manipulation optimization for mobile */
button, input, select, textarea, a {
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

/* Custom Scrollbars */
::-webkit-scrollbar {
  width: 5px;
  height: 5px;
}
::-webkit-scrollbar-track {
  background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 9999px;
}
::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Monospace for Numbers, Invoices, Receipts */
.font-mono-code {
  font-family: 'JetBrains Mono', monospace;
}

/* Subtle shadows & transitions */
.card-hover {
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.card-hover:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px -5px rgba(122, 12, 30, 0.08), 0 8px 10px -6px rgba(122, 12, 30, 0.04);
}

/* Sidebar Active Indicator */
.sidebar-item-active {
  background: linear-gradient(135deg, rgba(122, 12, 30, 0.95), rgba(88, 6, 20, 0.98)) !important;
  color: #ffffff !important;
  box-shadow: 0 4px 12px rgba(122, 12, 30, 0.35);
  border-left: 4px solid #D4AF37;
}

/* Bottom Nav Active Indicator */
.bottom-nav-item-active {
  color: #7A0C1E !important;
}
.bottom-nav-item-active .bottom-nav-icon {
  transform: translateY(-2px) scale(1.1);
  color: #7A0C1E;
}

/* Safe area inset for modern smartphones with home indicator / gestures */
.safe-area-bottom {
  padding-bottom: max(0.75rem, env(safe-area-inset-bottom, 0.75rem));
}

/* Thermal Paper Styling */
.thermal-paper {
  background-color: #ffffff;
  color: #111827;
  font-family: 'Courier New', Courier, monospace;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  border-radius: 4px;
  position: relative;
}

.thermal-paper-80mm {
  width: 100%;
  max-width: 300px;
  padding: 16px;
  font-size: 12px;
  line-height: 1.35;
}

.thermal-paper-58mm {
  width: 100%;
  max-width: 220px;
  padding: 10px;
  font-size: 10px;
  line-height: 1.25;
}

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

.receipt-divider-double {
  border-top: 2px dashed #111827;
  margin: 8px 0;
}

/* Slide-Up Bottom Sheet Animations */
@keyframes slideUpSheet {
  from {
    transform: translateY(100%);
    opacity: 0.5;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}
@keyframes slideDownSheet {
  from {
    transform: translateY(0);
    opacity: 1;
  }
  to {
    transform: translateY(100%);
    opacity: 0;
  }
}

.sheet-animate-up {
  animation: slideUpSheet 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.sheet-animate-down {
  animation: slideDownSheet 0.25s ease-in forwards;
}

/* Toast Notifications Animation */
@keyframes slideInRight {
  from {
    transform: translateX(110%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}
@keyframes slideOutRight {
  from {
    transform: translateX(0);
    opacity: 1;
  }
  to {
    transform: translateX(110%);
    opacity: 0;
  }
}

.toast-animate-in {
  animation: slideInRight 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.toast-animate-out {
  animation: slideOutRight 0.25s ease-in forwards;
}

/* Dedicated Print Container */
#print-area {
  display: none;
}

@media print {
  #print-area {
    display: block !important;
  }

  body * {
    visibility: hidden;
  }
  
  #print-area, #print-area * {
    visibility: visible;
  }
  
  #print-area {
    position: absolute;
    left: 0;
    top: 0;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  .no-print {
    display: none !important;
  }

  @page {
    margin: 0;
    size: auto;
  }
}

/* Custom modal backdrop blur */
.modal-backdrop {
  background-color: rgba(15, 23, 42, 0.7);
  backdrop-filter: blur(4px);
}

/* Pulsing Badge for low stock */
@keyframes pulseLowStock {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.55;
  }
}

.badge-pulse {
  animation: pulseLowStock 2s infinite ease-in-out;
}
