/* ==========================================================
 * iGotCoffee POS - Mobile-First Coffee Shop Theme
 * Designed for Smartphone (iPhone/Android) & Tablet (iPad)
 * Zero PC Dependency
 * ========================================================== */

:root {
  --bg-app: #F8F5F0;
  --bg-card: #FFFFFF;
  --bg-subtle: #F1ECE4;
  --color-espresso: #20130B;
  --color-coffee-mid: #4A3528;
  --color-caramel: #C27838;
  --color-caramel-hover: #A6632B;
  --color-cream: #E9DFD3;
  --color-text-main: #1C1917;
  --color-text-muted: #78716C;
  --color-success: #15803D;
  --color-success-bg: #DCFCE7;
  --color-warning: #B45309;
  --color-warning-bg: #FEF3C7;
  --color-danger: #B91C1C;
  --color-danger-bg: #FEE2E2;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 12px rgba(40,24,14,0.08);
  --shadow-lg: 0 10px 25px rgba(40,24,14,0.12);
  --font-base: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Sarabun", Helvetica, Arial, sans-serif;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 16px);
  --safe-left: env(safe-area-inset-left, 0px);
  --safe-right: env(safe-area-inset-right, 0px);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html {
  height: 100%;
  min-height: 100%;
  background-color: var(--color-espresso);
}

body {
  font-family: var(--font-base);
  background-color: var(--bg-app);
  color: var(--color-text-main);
  line-height: 1.4;
  user-select: none;
  -webkit-user-select: none;
  min-height: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  min-height: -webkit-fill-available;
  display: flex;
  flex-direction: column;
  padding-bottom: calc(90px + env(safe-area-inset-bottom, 16px));
  overflow-x: hidden;
}

.main-content {
  flex: 1 0 auto;
  width: 100%;
  display: flex;
  flex-direction: column;
}

/* ==========================================================
 * TOP HEADER
 * ========================================================== */
.app-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background-color: var(--color-espresso);
  color: #FFFFFF;
  padding-top: calc(12px + env(safe-area-inset-top, 0px));
  padding-bottom: 12px;
  padding-left: calc(14px + env(safe-area-inset-left, 0px));
  padding-right: calc(14px + env(safe-area-inset-right, 0px));
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  box-sizing: border-box;
}

@media (max-width: 480px) {
  .header-brand {
    gap: 8px;
  }
  .header-logo-icon {
    font-size: 1.35rem;
  }
  .header-title-box h1 {
    font-size: 0.98rem;
  }
  .header-title-box small {
    display: none;
  }
  .header-actions {
    gap: 6px;
  }
  .cloud-pill {
    padding: 4px 8px;
    font-size: 0.70rem;
  }
  .user-auth-pill {
    padding: 3px 8px;
    font-size: 0.70rem;
    max-width: 110px;
  }
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.header-logo-icon {
  font-size: 1.6rem;
}

.header-title-box h1 {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.2px;
}

.header-title-box small {
  font-size: 0.75rem;
  color: var(--color-cream);
  opacity: 0.85;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.pwa-btn {
  background-color: var(--color-caramel);
  color: #FFF;
  border: none;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: var(--radius-full);
  cursor: pointer;
}

.cloud-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  background-color: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.28);
  color: #FFF;
  padding: 5px 10px;
  border-radius: var(--radius-full);
  font-size: 0.74rem;
  font-weight: 700;
  cursor: pointer;
  user-select: none;
  transition: all 0.2s ease;
}

.cloud-pill:hover {
  background-color: rgba(255, 255, 255, 0.28);
}

.cloud-pill:active {
  transform: scale(0.96);
}

.cloud-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
  background-color: #94A3B8;
}

.cloud-pill.connected .cloud-dot {
  background-color: #22C55E;
  box-shadow: 0 0 6px #22C55E;
}

.cloud-pill.syncing .cloud-dot {
  background-color: #F59E0B;
  animation: cloudPulse 0.9s infinite alternate;
}

.cloud-pill.offline .cloud-dot {
  background-color: #94A3B8;
}

.cloud-pill.logged-out .cloud-dot {
  background-color: #F59E0B;
}

.cloud-pill.error .cloud-dot {
  background-color: #EF4444;
}

@keyframes cloudPulse {
  0% { transform: scale(0.8); opacity: 0.6; }
  100% { transform: scale(1.3); opacity: 1; }
}

/* User Auth Pill in Header */
.user-auth-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  background-color: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.28);
  color: #FFF;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 0.74rem;
  font-weight: 700;
  cursor: pointer;
  user-select: none;
  transition: all 0.2s ease;
  max-width: 140px;
}

.user-auth-pill:hover {
  background-color: rgba(255, 255, 255, 0.28);
}

.user-auth-pill:active {
  transform: scale(0.96);
}

.user-auth-pill.logged-in {
  background-color: rgba(245, 158, 11, 0.25);
  border-color: rgba(245, 158, 11, 0.5);
  color: #FEF3C7;
}

.user-avatar-img {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid #FFF;
  display: inline-block;
}

.user-auth-text {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Google Sign-In Button */
.btn-google {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  background-color: #FFFFFF;
  color: #3C4043;
  border: 1px solid #DADCE0;
  border-radius: var(--radius-md);
  padding: 12px 16px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(60, 64, 67, 0.08);
  transition: background-color 0.15s, box-shadow 0.15s, transform 0.1s;
  user-select: none;
}

.btn-google:hover {
  background-color: #F8FAFC;
  box-shadow: 0 2px 6px rgba(60, 64, 67, 0.15);
  border-color: #C2C6DC;
}

.btn-google:active {
  background-color: #F1F3F4;
  transform: scale(0.98);
}

.btn-google svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* Auth Divider */
.auth-divider {
  display: flex;
  align-items: center;
  text-align: center;
  margin: 16px 0;
  color: var(--color-text-muted);
  font-size: 0.78rem;
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  border-bottom: 1px solid #E2E8F0;
}

.auth-divider span {
  padding: 0 10px;
}

/* User Profile Card */
.user-profile-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--bg-subtle);
  border: 1px solid var(--color-cream);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  margin-bottom: 16px;
}

.user-profile-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 2px solid var(--color-caramel);
  object-fit: cover;
  flex-shrink: 0;
  background: #FFF;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
}

.user-profile-details h4 {
  font-size: 1.05rem;
  color: var(--color-espresso);
  margin-bottom: 2px;
}

.user-profile-details p {
  font-size: 0.82rem;
  color: var(--color-text-muted);
}

/* ==========================================================
 * ALERT BANNER
 * ========================================================== */
.stock-alert-banner {
  background-color: var(--color-warning-bg);
  color: var(--color-warning);
  border-bottom: 1px solid #FDE68A;
  padding: 8px 16px;
  font-size: 0.82rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

/* ==========================================================
 * TAB VIEWS
 * ========================================================== */
.tab-view {
  display: none;
  padding: 14px 16px calc(90px + env(safe-area-inset-bottom, 16px));
  max-width: 1100px;
  margin: 0 auto;
  width: 100%;
  box-sizing: border-box;
}

#tab-pos.tab-view {
  max-width: 1440px;
  padding-left: clamp(12px, 1.8vw, 24px);
  padding-right: clamp(12px, 1.8vw, 24px);
}

.tab-view.active {
  display: block;
  flex: 1 0 auto;
  min-height: calc(100dvh - 135px);
  min-height: calc(100vh - 135px);
  animation: fadeIn 0.15s ease;
}

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

/* ==========================================================
 * POS LAYOUT (SPLIT ON TABLET / VERTICAL ON MOBILE)
 * ========================================================== */
.pos-container {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
  box-sizing: border-box;
}

@media (min-width: 850px) {
  .pos-container {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    align-items: start;
    gap: 18px;
    width: 100%;
    box-sizing: border-box;
  }
}

@media (min-width: 1150px) {
  .pos-container {
    grid-template-columns: minmax(0, 1fr) 350px;
    gap: 24px;
  }
}

.pos-menu-col {
  min-width: 0;
  width: 100%;
  box-sizing: border-box;
}

/* Category Pills Bar (แสดงครบทุกหมวดหมู่ ไม่ต้องลากซ้ายขวา) */
.category-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-bottom: 4px;
  margin-bottom: 8px;
  width: 100%;
  box-sizing: border-box;
}

.category-pill {
  flex-shrink: 0;
  background-color: var(--bg-card);
  border: 1px solid var(--color-cream);
  color: var(--color-coffee-mid);
  padding: 7px 14px;
  border-radius: var(--radius-full);
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  transition: all 0.15s ease;
  box-shadow: var(--shadow-sm);
}

.category-pill:hover {
  background-color: #FFF;
  border-color: var(--color-caramel);
  color: var(--color-espresso);
  transform: translateY(-1px);
}

.category-pill.active {
  background-color: var(--color-espresso);
  color: #FFFFFF;
  border-color: var(--color-espresso);
  box-shadow: 0 2px 8px rgba(32, 19, 11, 0.25);
}

@media (max-width: 500px) {
  .category-pill {
    padding: 6px 11px;
    font-size: 0.80rem;
    gap: 4px;
  }
}

/* Menu Grid */
.menu-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 12px;
  margin-top: 10px;
}

@media (min-width: 500px) {
  .menu-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 14px;
  }
}

.menu-card {
  background-color: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 12px;
  border: 1px solid var(--color-cream);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  cursor: pointer;
  position: relative;
  transition: transform 0.1s ease, box-shadow 0.1s ease;
  box-shadow: var(--shadow-sm);
}

.menu-card:active {
  transform: scale(0.97);
  box-shadow: none;
}

.menu-card-icon {
  width: 54px;
  height: 54px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  margin-bottom: 8px;
}

.menu-card-img-wrap {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-md, 12px);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 8px;
  background-color: var(--bg-subtle, #F8F5F1);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
  border: 1px solid rgba(0, 0, 0, 0.06);
}

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

@media (min-width: 500px) {
  .menu-card-img-wrap {
    width: 74px;
    height: 74px;
  }
}

.modifier-visual-box {
  width: 38px;
  height: 38px;
  border-radius: 8px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-subtle, #F8F5F1);
  border: 1px solid var(--color-cream, #E5DCD3);
  flex-shrink: 0;
}

.recipe-image-section {
  margin-bottom: 14px;
  padding: 12px;
  background: var(--bg-subtle, #F8F5F1);
  border-radius: var(--radius-md, 12px);
  border: 1px dashed var(--color-cream, #E5DCD3);
}

.recipe-img-preview-box {
  width: 76px;
  height: 76px;
  border-radius: var(--radius-md, 12px);
  border: 2px solid var(--color-cream, #E5DCD3);
  background: #FFF;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.06);
  cursor: pointer;
  transition: border-color 0.15s ease, transform 0.15s ease;
}

.recipe-img-preview-box:hover {
  border-color: var(--color-caramel, #C27838);
  transform: scale(1.02);
}

.recipe-img-preview-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.menu-card-title {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--color-text-main);
  margin-bottom: 4px;
  line-height: 1.25;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.menu-card-price {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--color-caramel);
}

.menu-card-add-btn {
  position: absolute;
  bottom: 8px;
  right: 8px;
  width: 28px;
  height: 28px;
  border-radius: var(--radius-full);
  background-color: var(--color-espresso);
  color: #FFF;
  border: none;
  font-size: 1.1rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

/* Cart Panel (Desktop & Tablet) */
.pos-cart-panel {
  background-color: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-cream);
  padding: 16px;
  box-shadow: var(--shadow-md);
  position: sticky;
  top: 75px;
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
}

.cart-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 12px;
  border-bottom: 1px dashed var(--color-cream);
  width: 100%;
  box-sizing: border-box;
}

.cart-header h3 {
  font-size: 1.05rem;
  font-weight: 700;
  white-space: nowrap;
}

.cart-badge {
  background-color: var(--color-caramel);
  color: #FFF;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  flex-shrink: 0;
}

.cart-items-list {
  max-height: 320px;
  overflow-y: auto;
  padding: 8px 0;
}

.cart-empty {
  text-align: center;
  color: var(--color-text-muted);
  padding: 30px 10px;
  font-size: 0.88rem;
}

.cart-item {
  padding: 10px 0;
  border-bottom: 1px solid #F5EFE6;
}

.cart-item-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 6px;
}

.cart-item-name {
  font-size: 0.9rem;
  color: var(--color-text-main);
}

.cart-item-mods {
  font-size: 0.75rem;
  color: var(--color-caramel);
  margin-top: 2px;
}

.cart-item-price {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--color-espresso);
}

.cart-item-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.qty-btn {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  background-color: var(--bg-subtle);
  border: 1px solid var(--color-cream);
  font-size: 1.1rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

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

.del-btn {
  background: none;
  border: none;
  font-size: 1rem;
  cursor: pointer;
  margin-left: auto;
  opacity: 0.6;
}
.del-btn:hover { opacity: 1; }

.cart-summary {
  padding-top: 12px;
  border-top: 1px dashed var(--color-cream);
}

.summary-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  color: var(--color-text-muted);
  margin-bottom: 4px;
}

.summary-total {
  display: flex;
  justify-content: space-between;
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--color-espresso);
  margin: 10px 0 14px;
}

.checkout-btn {
  width: 100%;
  background-color: var(--color-caramel);
  color: #FFF;
  border: none;
  padding: 14px;
  border-radius: var(--radius-md);
  font-size: 1.05rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  box-shadow: 0 4px 14px rgba(194, 120, 56, 0.35);
  transition: background 0.15s;
}

.checkout-btn:disabled {
  background-color: #D6D3D1;
  box-shadow: none;
  cursor: not-allowed;
}

.checkout-btn:active:not(:disabled) {
  background-color: var(--color-caramel-hover);
  transform: scale(0.99);
}

/* ==========================================================
 * BOTTOM FIXED NAVIGATION BAR
 * ========================================================== */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  width: 100%;
  height: auto;
  box-sizing: border-box;
  padding-top: 8px;
  padding-bottom: calc(8px + env(safe-area-inset-bottom, 16px));
  padding-left: calc(4px + env(safe-area-inset-left, 0px));
  padding-right: calc(4px + env(safe-area-inset-right, 0px));
  background-color: #FFFFFF;
  border-top: 1px solid var(--color-cream);
  display: flex;
  justify-content: space-around;
  align-items: flex-start;
  z-index: 1000;
  box-shadow: 0 -3px 12px rgba(0, 0, 0, 0.08);
  transform: translateZ(0);
  -webkit-transform: translateZ(0);
}

.bottom-nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border: none;
  background: none;
  color: var(--color-text-muted);
  font-size: 0.70rem;
  font-weight: 600;
  cursor: pointer;
  padding: 2px 0;
  gap: 2px;
  transition: color 0.15s;
}

.bottom-nav-item .nav-icon {
  font-size: 1.3rem;
  line-height: 1.1;
}

.bottom-nav-item.active {
  color: var(--color-caramel);
}

/* ==========================================================
 * MODALS & BOTTOM SHEETS
 * ========================================================== */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2500;
  display: none;
  align-items: flex-end;
  justify-content: center;
}

.modal.active {
  display: flex;
}

@media (min-width: 600px) {
  .modal {
    align-items: center;
    padding: 20px;
  }
}

.modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}

.modal-content {
  position: relative;
  background-color: #FFFFFF;
  width: 100%;
  max-width: 480px;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  padding: 20px 20px calc(24px + env(safe-area-inset-bottom, 16px));
  max-height: calc(88dvh - env(safe-area-inset-top, 0px));
  max-height: calc(88vh - env(safe-area-inset-top, 0px));
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  box-shadow: var(--shadow-lg);
  z-index: 10;
  animation: slideUp 0.25s ease-out;
  box-sizing: border-box;
}

@media (min-width: 600px) {
  .modal-content {
    border-radius: var(--radius-lg);
    padding: 24px;
    max-height: 85vh;
  }
}

@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

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

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

.modal-close {
  background: var(--bg-subtle);
  border: none;
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  font-size: 1.2rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Modifiers Selection inside Modal */
.modal-section-title {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--color-coffee-mid);
  margin: 12px 0 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.options-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.option-pill {
  padding: 8px 14px;
  background-color: var(--bg-subtle);
  border: 1px solid var(--color-cream);
  border-radius: var(--radius-md);
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
}

.option-pill input { display: none; }

.option-pill.selected {
  background-color: var(--color-espresso);
  color: #FFF;
  border-color: var(--color-espresso);
}

.option-checkbox {
  width: 100%;
  padding: 10px 14px;
  background-color: var(--bg-subtle);
  border: 1px solid var(--color-cream);
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}

.option-checkbox.selected {
  background-color: #FEF3C7;
  border-color: var(--color-caramel);
  color: var(--color-espresso);
}

.form-group {
  margin-bottom: 14px;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-coffee-mid);
  margin-bottom: 6px;
}

.form-input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--color-cream);
  border-radius: var(--radius-md);
  font-size: 1rem;
  font-family: inherit;
  background-color: #FFF;
}

.form-input:focus {
  outline: none;
  border-color: var(--color-caramel);
  box-shadow: 0 0 0 3px rgba(194, 120, 56, 0.15);
}

/* ==========================================================
 * CHECKOUT & PROMPTPAY STYLES
 * ========================================================== */
.pay-methods-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 16px;
}

.pay-method-btn {
  padding: 12px;
  border: 2px solid var(--color-cream);
  background-color: var(--bg-card);
  border-radius: var(--radius-md);
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.pay-method-btn.selected {
  border-color: var(--color-caramel);
  background-color: #FEF3C7;
  color: var(--color-espresso);
}

.promptpay-qr-card {
  text-align: center;
  background-color: #FFFFFF;
  border: 2px solid #005697; /* PromptPay Blue */
  border-radius: var(--radius-lg);
  padding: 16px;
  margin: 10px 0;
}

.promptpay-logo-badge {
  display: inline-block;
  background-color: #005697;
  color: #FFF;
  font-weight: 800;
  font-size: 0.85rem;
  padding: 4px 14px;
  border-radius: var(--radius-sm);
  margin-bottom: 10px;
}

#promptpay-qr-canvas {
  margin: 0 auto;
  border: 6px solid #FFF;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  display: block;
}

.quick-cash-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin: 8px 0 14px;
}

.quick-cash-btn {
  padding: 10px 4px;
  background-color: var(--bg-subtle);
  border: 1px solid var(--color-cream);
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
}

.change-display-box {
  background-color: var(--bg-subtle);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 1.1rem;
  font-weight: 700;
}

/* ==========================================================
 * RECEIPT DESIGN
 * ========================================================== */
.receipt-paper {
  background-color: #FFF;
  padding: 20px;
  border-radius: var(--radius-md);
  box-shadow: 0 0 10px rgba(0,0,0,0.08);
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.85rem;
  color: #111;
  border: 1px dashed #CCC;
}

.receipt-header {
  text-align: center;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px dashed #333;
}

.receipt-header h3 {
  font-size: 1.15rem;
  margin-bottom: 2px;
}

.receipt-item-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 6px;
}

.receipt-item-desc small {
  display: block;
  font-size: 0.75rem;
  color: #666;
}

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

.receipt-total-row {
  display: flex;
  justify-content: space-between;
  font-size: 1.05rem;
  font-weight: 700;
  margin: 6px 0;
}

.receipt-footer {
  text-align: center;
  margin-top: 14px;
  font-size: 0.78rem;
  color: #555;
}

/* ==========================================================
 * INVENTORY & ACCOUNTING CARDS
 * ========================================================== */
.stats-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 14px;
}

.stat-card {
  background-color: var(--bg-card);
  border: 1px solid var(--color-cream);
  border-radius: var(--radius-md);
  padding: 14px;
  display: flex;
  flex-direction: column;
}

.stat-card.warning {
  border-color: #F59E0B;
  background-color: #FFFBEB;
}

.stat-label {
  font-size: 0.75rem;
  color: var(--color-text-muted);
  font-weight: 600;
  margin-bottom: 4px;
}

.stat-value {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--color-espresso);
}

.action-bar-sticky {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
}

.btn {
  flex: 1;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  font-size: 0.95rem;
  font-weight: 700;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.btn-primary {
  background-color: var(--color-caramel);
  color: #FFF;
}

.btn-secondary {
  background-color: var(--color-espresso);
  color: #FFF;
}

.btn-outline {
  background-color: transparent;
  border: 1px solid var(--color-cream);
  color: var(--color-text-main);
}

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

.btn-xs {
  padding: 4px 10px;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-cream);
  background-color: #FFF;
  cursor: pointer;
}

.btn-danger-outline {
  border-color: var(--color-danger);
  color: var(--color-danger);
  background: transparent;
}

.card-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.inventory-card, .expense-card, .order-history-card {
  background-color: var(--bg-card);
  border-radius: var(--radius-md);
  border: 1px solid var(--color-cream);
  padding: 14px;
  box-shadow: var(--shadow-sm);
}

.inventory-card-main {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 10px;
}

.inventory-name {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--color-espresso);
}

.inventory-sub {
  font-size: 0.78rem;
  color: var(--color-text-muted);
  margin-top: 2px;
}

.inventory-status-box {
  text-align: right;
}

.inventory-stock-amount {
  font-size: 1.15rem;
  font-weight: 800;
}
.inventory-stock-amount .unit {
  font-size: 0.8rem;
  font-weight: normal;
  color: var(--color-text-muted);
}

.inventory-card-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding-top: 8px;
  border-top: 1px dashed var(--color-cream);
}

.badge {
  display: inline-block;
  padding: 3px 8px;
  border-radius: var(--radius-full);
  font-size: 0.7rem;
  font-weight: 700;
}

.badge-success { background: var(--color-success-bg); color: var(--color-success); }
.badge-warning { background: var(--color-warning-bg); color: var(--color-warning); }
.badge-danger { background: var(--color-danger-bg); color: var(--color-danger); }
.badge-outline { border: 1px solid var(--color-cream); background: transparent; }

/* ==========================================================
 * MODERN INVENTORY STYLES
 * ========================================================== */
.ing-kpi-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 12px;
}
@media (max-width: 640px) {
  .ing-kpi-grid {
    grid-template-columns: 1fr 1fr;
  }
  .ing-kpi-grid .stat-card:last-child {
    grid-column: span 2;
  }
}
.stat-card.clickable {
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}
.stat-card.clickable:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.stat-card.active-filter {
  outline: 2px solid var(--color-warning, #D97706);
  background: #FFFBEB !important;
}

/* Search and View Controls Bar */
.ing-controls-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}
.ing-search-wrap {
  position: relative;
  flex: 1;
  min-width: 200px;
}
.ing-search-wrap .search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.95rem;
  color: var(--color-text-muted);
  pointer-events: none;
}
.ing-search-input {
  width: 100%;
  padding: 8px 34px 8px 34px;
  border-radius: var(--radius-full, 9999px);
  border: 1px solid var(--color-cream, #E5DCD3);
  background: #FFFFFF;
  font-size: 0.88rem;
  color: var(--color-espresso, #20130B);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  box-sizing: border-box;
}
.ing-search-input:focus {
  border-color: var(--color-coffee, #6F4E37);
  box-shadow: 0 0 0 3px rgba(111, 78, 55, 0.12);
}
.ing-search-clear {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  font-size: 0.85rem;
  color: #94A3B8;
  cursor: pointer;
  padding: 4px;
  line-height: 1;
  border-radius: 50%;
}
.ing-search-clear:hover {
  color: #475569;
}

.ing-view-toggle {
  display: flex;
  background: #EDE8E1;
  padding: 3px;
  border-radius: var(--radius-full, 9999px);
  gap: 2px;
}
.ing-view-btn {
  padding: 5px 12px;
  border-radius: var(--radius-full, 9999px);
  border: none;
  background: transparent;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-coffee-mid, #5C4333);
  cursor: pointer;
  transition: all 0.15s ease;
  display: flex;
  align-items: center;
  gap: 4px;
}
.ing-view-btn.active {
  background: #FFFFFF;
  color: var(--color-espresso, #20130B);
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

/* Modern Card Grid */
.ing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 12px;
}
@media (max-width: 640px) {
  .ing-grid {
    grid-template-columns: 1fr;
  }
}

.ing-card-modern {
  background: #FFFFFF;
  border-radius: var(--radius-lg, 16px);
  border: 1px solid var(--color-cream, #E5DCD3);
  padding: 14px 16px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
  position: relative;
}
.ing-card-modern:hover {
  box-shadow: var(--shadow-md);
  border-color: #D3C4B3;
}
.ing-card-modern.is-low-stock {
  border-left: 4px solid var(--color-warning, #F59E0B);
}
.ing-card-modern.is-out-of-stock {
  border-left: 4px solid var(--color-danger, #EF4444);
  background: #FFFDFC;
}

.ing-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}
.ing-card-title-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 0;
}
.ing-card-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--bg-subtle, #F8F5F1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  flex-shrink: 0;
  border: 1px solid var(--color-cream, #E5DCD3);
}
.ing-card-title-text {
  min-width: 0;
}
.ing-card-name {
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--color-espresso, #20130B);
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.ing-card-category-tag {
  display: inline-block;
  font-size: 0.72rem;
  color: #64748B;
  background: #F1F5F9;
  padding: 1px 7px;
  border-radius: 9999px;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 140px;
}

.ing-stock-body {
  margin-bottom: 10px;
  padding: 8px 10px;
  background: var(--bg-subtle, #FAF7F2);
  border-radius: 10px;
  border: 1px solid #EFE8E0;
}
.ing-stock-main-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 6px;
}
.ing-stock-label {
  font-size: 0.78rem;
  color: #64748B;
  font-weight: 500;
}
.ing-stock-qty {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--color-espresso, #20130B);
  letter-spacing: -0.5px;
}
.ing-stock-qty .unit {
  font-size: 0.82rem;
  font-weight: 500;
  color: #64748B;
  margin-left: 2px;
}

/* Visual Stock Health Bar */
.stock-level-bar {
  width: 100%;
  height: 6px;
  background: #E2E8F0;
  border-radius: 9999px;
  overflow: hidden;
  margin-bottom: 6px;
}
.stock-level-fill {
  height: 100%;
  border-radius: 9999px;
  transition: width 0.3s ease;
}
.stock-level-fill.normal {
  background: linear-gradient(90deg, #10B981, #059669);
}
.stock-level-fill.warning {
  background: linear-gradient(90deg, #FBBF24, #D97706);
}
.stock-level-fill.danger {
  background: linear-gradient(90deg, #F87171, #DC2626);
}

.ing-stock-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  color: #64748B;
  flex-wrap: wrap;
  gap: 4px;
}
.ing-stock-meta-val {
  font-weight: 600;
  color: var(--color-coffee-mid, #5C4333);
}

/* Modern Card Actions Bar */
.ing-card-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding-top: 10px;
  border-top: 1px dashed var(--color-cream, #E5DCD3);
}
.ing-action-primary-btn {
  background: #10B981;
  color: #FFFFFF;
  border: none;
  border-radius: var(--radius-sm, 8px);
  padding: 6px 12px;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: background 0.15s ease, transform 0.1s ease;
}
.ing-action-primary-btn:hover {
  background: #059669;
  transform: translateY(-1px);
}
.ing-action-btn-group {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Compact Table View */
.ing-table-wrap {
  width: 100%;
  overflow-x: auto;
  background: #FFFFFF;
  border-radius: var(--radius-md, 12px);
  border: 1px solid var(--color-cream, #E5DCD3);
  box-shadow: var(--shadow-sm);
  -webkit-overflow-scrolling: touch;
}
.ing-table-compact {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
  text-align: left;
  min-width: 580px;
}
.ing-table-compact th {
  background: var(--bg-subtle, #F8F5F1);
  padding: 10px 12px;
  font-weight: 700;
  color: var(--color-coffee, #6F4E37);
  border-bottom: 1px solid var(--color-cream, #E5DCD3);
  white-space: nowrap;
}
.ing-table-compact td {
  padding: 10px 12px;
  border-bottom: 1px solid #F1ECE6;
  vertical-align: middle;
}
.ing-table-compact tr:last-child td {
  border-bottom: none;
}
.ing-table-compact tr:hover {
  background: #FAF7F2;
}

/* ==========================================================
 * PROFIT & LOSS STYLES
 * ========================================================== */
.filter-pills-row {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
  overflow-x: auto;
}

.pill-btn {
  padding: 6px 14px;
  border-radius: var(--radius-full);
  border: 1px solid var(--color-cream);
  background-color: var(--bg-card);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
}

.pill-btn.active {
  background-color: var(--color-espresso);
  color: #FFF;
  border-color: var(--color-espresso);
}

.pnl-main-card {
  background-color: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-cream);
  padding: 16px;
  box-shadow: var(--shadow-md);
  margin-bottom: 16px;
}

.pnl-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 700;
  font-size: 0.95rem;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--color-cream);
}

.pnl-orders-badge {
  background-color: var(--bg-subtle);
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
}

.pnl-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin: 14px 0;
}

.pnl-metric {
  background-color: var(--bg-subtle);
  padding: 10px 12px;
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
}

.pnl-metric .label {
  font-size: 0.75rem;
  color: var(--color-text-muted);
  font-weight: 600;
  margin-bottom: 2px;
}

.pnl-metric .value {
  font-size: 1.15rem;
  font-weight: 800;
}

.pnl-metric .subtext {
  font-size: 0.7rem;
  color: var(--color-text-muted);
  margin-top: 2px;
}

.text-success { color: var(--color-success); }
.text-danger { color: var(--color-danger); }
.text-primary { color: var(--color-caramel); }
.text-muted { color: var(--color-text-muted); }

.net-profit-banner {
  background: linear-gradient(135deg, #15803D, #166534);
  color: #FFF;
  border-radius: var(--radius-md);
  padding: 16px;
  text-align: center;
}

.net-profit-banner.negative {
  background: linear-gradient(135deg, #B91C1C, #991B1B);
}

.net-title { font-size: 0.85rem; opacity: 0.9; font-weight: 600; }
.net-amount { font-size: 1.75rem; font-weight: 900; margin: 4px 0; }
.net-margin { font-size: 0.78rem; opacity: 0.85; }

/* ==========================================================
 * TAX STYLES (ภ.ง.ด. 94 & 90)
 * ========================================================== */
.tax-period-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 16px;
}

.tax-period-btn {
  padding: 12px 10px;
  border-radius: var(--radius-md);
  border: 2px solid var(--color-cream);
  background-color: var(--bg-card);
  text-align: center;
  cursor: pointer;
  display: flex;
  flex-direction: column;
}

.tax-period-btn strong { font-size: 0.95rem; }
.tax-period-btn small { font-size: 0.75rem; color: var(--color-text-muted); margin-top: 2px; }

.tax-period-btn.active {
  border-color: var(--color-caramel);
  background-color: #FEF3C7;
  color: var(--color-espresso);
}

.tax-source-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 16px;
}

.tax-source-btn {
  padding: 12px 10px;
  border-radius: var(--radius-md);
  border: 2px solid var(--color-cream);
  background-color: var(--bg-card);
  text-align: left;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
  position: relative;
  transition: all 0.15s ease;
  font-family: inherit;
}

.tax-source-btn:active {
  transform: scale(0.98);
}

.tax-source-btn .source-icon {
  font-size: 1.45rem;
  flex-shrink: 0;
}

.tax-source-btn .source-text {
  flex-grow: 1;
}

.tax-source-btn strong {
  font-size: 0.88rem;
  display: block;
  color: var(--color-espresso);
  line-height: 1.2;
}

.tax-source-btn small {
  font-size: 0.72rem;
  color: var(--color-text-muted);
  display: block;
  margin-top: 3px;
}

.tax-source-btn.active {
  border-color: #0284C7;
  background-color: #F0F9FF;
  box-shadow: 0 2px 8px rgba(2, 132, 199, 0.15);
}

.tax-source-btn.active strong {
  color: #0369A1;
}

.source-tag {
  position: absolute;
  top: -8px;
  right: 8px;
  background-color: #0284C7;
  color: #FFF;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: var(--radius-full);
}

.tax-recommendation-card {
  background: #EFF6FF;
  border: 1px solid #BFDBFE;
  border-radius: var(--radius-md);
  padding: 14px 16px;
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
}

.rec-icon { font-size: 1.6rem; flex-shrink: 0; }
.rec-title { font-size: 0.95rem; font-weight: 700; color: #1E40AF; margin-bottom: 4px; }
.rec-desc { font-size: 0.85rem; color: #1E3A8A; line-height: 1.4; }

.tax-income-overview {
  background-color: var(--bg-card);
  border-radius: var(--radius-md);
  border: 1px solid var(--color-cream);
  padding: 14px;
  margin-bottom: 16px;
}

.tax-overview-header {
  font-weight: 700;
  font-size: 0.9rem;
  margin-bottom: 8px;
}

.tax-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.88rem;
  padding: 4px 0;
}

.tax-compare-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-bottom: 16px;
}

@media (min-width: 600px) {
  .tax-compare-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.tax-method-card {
  background-color: var(--bg-card);
  border: 2px solid var(--color-cream);
  border-radius: var(--radius-md);
  padding: 16px;
  position: relative;
}

.tax-method-card.winner {
  border-color: var(--color-success);
  background-color: #F0FDF4;
}

.winner-badge {
  position: absolute;
  top: -10px;
  right: 12px;
  background-color: var(--color-success);
  color: #FFF;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-full);
}

.method-header h4 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--color-espresso);
}

.tax-line {
  display: flex;
  justify-content: space-between;
  font-size: 0.82rem;
  margin-top: 8px;
}

.tax-line-total {
  display: flex;
  justify-content: space-between;
  font-size: 1rem;
  font-weight: 800;
  margin-top: 12px;
  padding-top: 8px;
  border-top: 1px dashed var(--color-cream);
}

.tax-final-amount {
  color: var(--color-danger);
  font-size: 1.15rem;
}

.efiling-card {
  background-color: var(--bg-card);
  border-radius: var(--radius-md);
  border: 1px solid var(--color-cream);
  padding: 16px;
}

.efiling-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.efiling-header h4 { font-size: 0.92rem; font-weight: 700; }

.efiling-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  padding: 6px 0;
  border-bottom: 1px solid #F3EDE4;
}

.efiling-row.highlight {
  background-color: #FEF3C7;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  margin-top: 6px;
  font-weight: 700;
}

/* ==========================================================
 * TOAST NOTIFICATION
 * ========================================================== */
.toast {
  position: fixed;
  bottom: calc(85px + env(safe-area-inset-bottom, 16px));
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background-color: var(--color-espresso);
  color: #FFF;
  padding: 10px 20px;
  border-radius: var(--radius-full);
  font-size: 0.88rem;
  font-weight: 600;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  pointer-events: none;
  transition: all 0.25s ease;
  z-index: 3000;
  white-space: nowrap;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ==========================================================
 * RECIPE & MENU EDITOR STYLES
 * ========================================================== */
.recipe-variations-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 6px;
}

.variation-item-row {
  background-color: var(--bg-subtle);
  border: 1px solid var(--color-cream);
  border-radius: var(--radius-md);
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.var-toggle-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
}

.var-price-input {
  padding: 6px 10px;
  font-size: 0.9rem;
  border-radius: var(--radius-sm);
}

.recipe-type-pills {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
  overflow-x: auto;
}

.recipe-type-pill-btn {
  padding: 6px 14px;
  border-radius: var(--radius-full);
  border: 1px solid var(--color-cream);
  background-color: var(--bg-card);
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}

.recipe-type-pill-btn.active {
  background-color: var(--color-caramel);
  color: #FFF;
  border-color: var(--color-caramel);
}

.recipe-editor-box {
  background-color: var(--bg-subtle);
  border: 1px solid var(--color-cream);
  border-radius: var(--radius-md);
  padding: 12px;
}

.recipe-ing-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: #FFF;
  border: 1px solid var(--color-cream);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  margin-bottom: 8px;
  font-size: 0.88rem;
}

.recipe-ing-info {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
}

.recipe-ing-name {
  font-weight: 600;
  color: var(--color-espresso);
}

.recipe-ing-amount-box {
  display: flex;
  align-items: center;
  gap: 8px;
}

.recipe-ing-qty-input {
  width: 75px;
  padding: 4px 8px;
  text-align: center;
  font-weight: 700;
}

.add-ingredient-to-recipe-row {
  display: flex;
  gap: 6px;
  margin-top: 10px;
  align-items: center;
}

.recipe-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.recipe-card-actions {
  display: flex;
  gap: 6px;
}

/* ==========================================================
 * QUEUE STYLES
 * ========================================================== */
.quick-queue-bar {
  background-color: #FEF3C7;
  border-bottom: 1px solid #FDE68A;
  color: #92400E;
  padding: 10px 16px;
  font-size: 0.88rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
}

.queue-pulse-dot {
  width: 9px;
  height: 9px;
  background-color: #D97706;
  border-radius: 50%;
  display: inline-block;
  animation: queuePulse 1.5s infinite;
}

@keyframes queuePulse {
  0% { transform: scale(0.85); opacity: 0.6; }
  50% { transform: scale(1.3); opacity: 1; }
  100% { transform: scale(0.85); opacity: 0.6; }
}

.nav-badge {
  position: absolute;
  top: -4px;
  right: -10px;
  background-color: #DC2626;
  color: #FFF;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 1px 5px;
  border-radius: 9999px;
  line-height: 1.2;
}

.queue-card {
  background-color: var(--bg-card);
  border: 1px solid var(--color-cream);
  border-radius: var(--radius-md);
  padding: 16px;
  margin-bottom: 12px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.1s ease;
}

.queue-card.pending {
  border-left: 6px solid var(--color-caramel);
}

.queue-card.completed {
  border-left: 6px solid var(--color-success);
  opacity: 0.88;
}

.queue-card-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding-bottom: 10px;
  border-bottom: 1px dashed var(--color-cream);
  margin-bottom: 10px;
}

.queue-badge-number {
  font-size: 1.35rem;
  font-weight: 900;
  color: var(--color-espresso);
  background: #FEF3C7;
  padding: 3px 12px;
  border-radius: var(--radius-sm);
  display: inline-block;
}

.queue-customer-note {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--color-coffee-mid);
  margin-left: 8px;
}

.queue-time-box {
  text-align: right;
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

.queue-time-elapsed {
  font-weight: 700;
  color: var(--color-caramel);
}

.queue-items-list {
  list-style: none;
  margin: 10px 0;
}

.queue-item-row {
  display: flex;
  justify-content: space-between;
  padding: 5px 0;
  font-size: 0.92rem;
  border-bottom: 1px solid #F7F3EE;
}

.queue-item-mods {
  font-size: 0.78rem;
  color: var(--color-caramel);
  margin-top: 2px;
}

.queue-serve-btn {
  width: 100%;
  background-color: var(--color-success);
  color: #FFF;
  border: none;
  padding: 12px;
  border-radius: var(--radius-md);
  font-size: 1.05rem;
  font-weight: 700;
  cursor: pointer;
  margin-top: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 2px 8px rgba(21, 128, 61, 0.25);
}

.queue-serve-btn:active {
  transform: scale(0.98);
}

/* Payment Type Switcher in POS Cart */
.pay-type-selector {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 10px;
}

.pay-type-btn {
  padding: 10px 8px;
  border: 2px solid var(--color-cream);
  background-color: var(--bg-card);
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--color-text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.15s ease;
}

.pay-type-btn.active.transfer {
  border-color: #0284C7;
  background-color: #E0F2FE;
  color: #0369A1;
}

.pay-type-btn.active.cash {
  border-color: #16A34A;
  background-color: #DCFCE7;
  color: #15803D;
}

/* Payment Badges on Queue Cards */
.badge-pay {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.15s ease;
  user-select: none;
}

.badge-pay:hover {
  filter: brightness(0.95);
}

.badge-pay:active {
  transform: scale(0.95);
}

.badge-pay-transfer {
  background-color: #E0F2FE;
  color: #0369A1;
  border-color: #BAE6FD;
}

.badge-pay-cash {
  background-color: #DCFCE7;
  color: #15803D;
  border-color: #BBF7D0;
}

.badge-pay-unpaid {
  background-color: #FEF3C7;
  color: #B45309;
  border-color: #FDE68A;
}

/* Serve Choice Buttons in Modal */
.btn-serve-choice {
  padding: 18px 12px;
  border-radius: var(--radius-lg);
  border: 2px solid transparent;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  transition: all 0.15s ease;
  font-family: inherit;
  box-shadow: var(--shadow-sm);
}

.btn-serve-choice:active {
  transform: scale(0.96);
}

.btn-serve-choice.transfer {
  background-color: #E0F2FE;
  border-color: #0284C7;
  color: #0369A1;
}

.btn-serve-choice.transfer:hover {
  background-color: #BAE6FD;
}

.btn-serve-choice.cash {
  background-color: #DCFCE7;
  border-color: #16A34A;
  color: #15803D;
}

.btn-serve-choice.cash:hover {
  background-color: #BBF7D0;
}

.btn-serve-choice strong {
  font-size: 1.15rem;
  font-weight: 800;
  margin-top: 4px;
}

.btn-serve-choice small {
  font-size: 0.78rem;
  opacity: 0.85;
}

/* Direct Serve Buttons on Queue Card */
.btn-serve-direct {
  width: 100%;
  padding: 13px 8px;
  border-radius: var(--radius-md);
  font-size: 0.98rem;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: none;
  font-family: inherit;
  transition: transform 0.1s ease, filter 0.15s ease;
}

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

.btn-serve-direct.transfer {
  background: linear-gradient(135deg, #0284C7, #0369A1);
  color: #FFF;
  box-shadow: 0 3px 10px rgba(2, 132, 199, 0.3);
}

.btn-serve-direct.cash {
  background: linear-gradient(135deg, #16A34A, #15803D);
  color: #FFF;
  box-shadow: 0 3px 10px rgba(22, 163, 74, 0.3);
}

/* ==========================================================
 * FIREBASE CLOUD SYNC STYLES
 * ========================================================== */
.firebase-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  border-bottom: 1px dashed #BAE6FD;
  padding-bottom: 10px;
  margin-bottom: 12px;
}

.firebase-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  font-weight: 700;
  white-space: nowrap;
}

.firebase-badge.connected {
  background-color: #DCFCE7;
  color: #15803D;
  border: 1px solid #BBF7D0;
}

.firebase-badge.syncing {
  background-color: #FEF3C7;
  color: #B45309;
  border: 1px solid #FDE68A;
}

.firebase-badge.offline {
  background-color: #F1F5F9;
  color: #64748B;
  border: 1px solid #CBD5E1;
}

.firebase-badge.logged-out {
  background-color: #FEF3C7;
  color: #92400E;
  border: 1px solid #FDE68A;
}

.firebase-badge.error {
  background-color: #FEE2E2;
  color: #DC2626;
  border: 1px solid #FECACA;
}

.firebase-guide-box {
  background-color: #F8FAFC;
  border: 1px solid #E2E8F0;
  border-radius: var(--radius-md);
  padding: 12px 14px;
  font-size: 0.84rem;
  line-height: 1.55;
  margin: 12px 0;
}

.firebase-guide-box ol {
  margin-left: 18px;
  margin-top: 6px;
}

.firebase-guide-box li {
  margin-bottom: 6px;
}

.firebase-status-box {
  background: #FFF;
  border: 1px solid #E2E8F0;
  border-radius: var(--radius-md);
  padding: 12px;
  margin-bottom: 12px;
}

/* ==========================================================
 * RICH ICON PICKER PALETTE (100+ EMOJIS)
 * ========================================================== */
.icon-picker-widget {
  background: var(--bg-subtle);
  border: 1px solid var(--color-cream);
  border-radius: var(--radius-md);
  padding: 10px 12px;
  margin-top: 8px;
  margin-bottom: 12px;
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.03);
}

.icon-picker-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.icon-picker-title {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--color-coffee-mid);
  display: flex;
  align-items: center;
  gap: 6px;
}

.icon-picker-count-badge {
  background: var(--color-espresso);
  color: #FFFFFF;
  font-size: 0.68rem;
  padding: 2px 7px;
  border-radius: var(--radius-full);
  font-weight: 700;
}

.icon-picker-toggle-btn {
  background: transparent;
  border: 1px solid var(--color-cream);
  color: var(--color-coffee-mid);
  padding: 3px 8px;
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
}

.icon-picker-toggle-btn:hover {
  background: #FFFFFF;
  border-color: var(--color-caramel);
}

.icon-picker-tabs {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 6px;
  margin-bottom: 8px;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.icon-picker-tabs::-webkit-scrollbar { display: none; }

.icon-picker-tab-btn {
  background: #FFFFFF;
  border: 1px solid var(--color-cream);
  color: var(--color-coffee-mid);
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 0.76rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s ease;
  user-select: none;
}

.icon-picker-tab-btn:hover {
  border-color: var(--color-caramel);
}

.icon-picker-tab-btn.active {
  background: var(--color-espresso);
  color: #FFFFFF;
  border-color: var(--color-espresso);
  box-shadow: 0 1px 4px rgba(32,19,11,0.15);
}

.icon-picker-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(36px, 1fr));
  gap: 6px;
  max-height: 135px;
  overflow-y: auto;
  padding: 4px;
  background: #FFFFFF;
  border: 1px solid var(--color-cream);
  border-radius: var(--radius-sm);
  scrollbar-width: thin;
}

.icon-picker-item-btn {
  height: 38px;
  border: 1px solid rgba(0,0,0,0.06);
  background: #FAFAF9;
  border-radius: 6px;
  font-size: 1.3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.12s ease, border-color 0.12s ease, background-color 0.12s ease;
  padding: 0;
  user-select: none;
}

.icon-picker-item-btn:hover {
  background-color: var(--bg-subtle);
  border-color: var(--color-caramel);
  transform: scale(1.12);
}

.icon-picker-item-btn:active {
  transform: scale(0.92);
}

.icon-picker-item-btn.active {
  background-color: #FEF3C7;
  border-color: var(--color-caramel);
  box-shadow: 0 0 0 2px var(--color-caramel);
  transform: scale(1.05);
}

/* ==========================================================
 * GATEKEEPER LOGIN SCREEN (FULLSCREEN PRE-POS AUTH)
 * ========================================================== */
.gatekeeper-screen {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  background: radial-gradient(circle at 50% 30%, #3D2517 0%, #20130B 70%, #150C07 100%);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: calc(20px + env(safe-area-inset-top, 0px)) 16px calc(24px + env(safe-area-inset-bottom, 16px));
  box-sizing: border-box;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.gatekeeper-screen.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  display: none !important;
}

.gatekeeper-card {
  width: 100%;
  max-width: 400px;
  background: #FFFFFF;
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
  text-align: center;
  animation: slideUp 0.3s ease-out;
  position: relative;
}

.gatekeeper-brand-icon {
  font-size: 3rem;
  line-height: 1;
  margin-bottom: 8px;
  display: inline-block;
  animation: floatCoffee 3s ease-in-out infinite;
}

@keyframes floatCoffee {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

.gatekeeper-title {
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--color-espresso);
  letter-spacing: -0.3px;
  margin-bottom: 4px;
}

.gatekeeper-tagline {
  font-size: 0.84rem;
  color: var(--color-text-muted);
  margin-bottom: 22px;
}

.gatekeeper-loading-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 30px 10px;
}

.gatekeeper-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(194, 120, 56, 0.2);
  border-top-color: var(--color-caramel);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

.btn-google-primary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  min-height: 50px;
  background-color: #FFFFFF;
  color: #1F1F1F;
  border: 1.5px solid #747775;
  border-radius: var(--radius-md);
  padding: 12px 16px;
  font-size: 0.98rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
  transition: all 0.2s ease;
  user-select: none;
  box-sizing: border-box;
}

.btn-google-primary:hover {
  background-color: #F8FAFD;
  border-color: #1A73E8;
  box-shadow: 0 4px 12px rgba(26, 115, 232, 0.15);
  transform: translateY(-1px);
}

.btn-google-primary:active {
  background-color: #E8F0FE;
  transform: scale(0.98);
}

.btn-google-primary .google-icon {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.gatekeeper-security-hint {
  font-size: 0.74rem;
  color: var(--color-text-muted);
  margin-top: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

.btn-emergency-toggle {
  background: transparent;
  border: none;
  color: var(--color-text-muted);
  font-size: 0.78rem;
  cursor: pointer;
  padding: 6px 10px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: color 0.15s;
}

/* ==========================================================
 * RECIPE BOM MANAGER - MENU TILES & REORDERING
 * ========================================================== */
.recipe-filter-pills-bar {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 4px;
  flex-wrap: wrap;
  -webkit-overflow-scrolling: touch;
}

.recipe-filter-pill {
  padding: 6px 14px;
  border-radius: var(--radius-full, 9999px);
  font-size: 0.82rem;
  font-weight: 600;
  border: 1px solid var(--color-cream, #E5DCD3);
  background: #FFF;
  color: var(--color-text-main, #20130B);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: all 0.15s ease;
  user-select: none;
}

.recipe-filter-pill:hover {
  background: var(--bg-subtle, #F8F5F1);
  border-color: var(--color-caramel, #C27838);
}

.recipe-filter-pill.active {
  background: var(--color-espresso, #20130B);
  color: #FFF;
  border-color: var(--color-espresso, #20130B);
  box-shadow: 0 2px 6px rgba(32, 19, 11, 0.2);
}

.recipe-menu-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 12px;
  padding: 4px 2px;
}

@media (max-width: 640px) {
  .recipe-menu-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }
}

.recipe-menu-tile {
  background: #FFFFFF;
  border: 1.5px solid var(--color-cream, #E5DCD3);
  border-radius: var(--radius-md, 12px);
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  cursor: pointer;
  position: relative;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.1s ease;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}

.recipe-menu-tile:hover {
  border-color: var(--color-caramel, #C27838);
  box-shadow: 0 4px 14px rgba(194, 120, 56, 0.12);
  transform: translateY(-1px);
}

.recipe-menu-tile:active {
  transform: scale(0.99);
}

.recipe-tile-top {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.recipe-tile-visual {
  width: 52px;
  height: 52px;
  border-radius: 10px;
  overflow: hidden;
  background: var(--bg-subtle, #F8F5F1);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.recipe-tile-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.recipe-tile-emoji {
  font-size: 1.8rem;
  line-height: 1;
}

.recipe-tile-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.recipe-tile-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.recipe-tile-title {
  font-size: 0.96rem;
  font-weight: 700;
  color: var(--color-espresso, #20130B);
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.recipe-tile-pos-badge {
  font-size: 0.70rem;
  font-weight: 700;
  color: #64748b;
  background: #f1f5f9;
  padding: 2px 6px;
  border-radius: 6px;
  flex-shrink: 0;
}

.recipe-tile-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.recipe-tile-cat-badge {
  font-size: 0.73rem;
  background: var(--bg-subtle, #F8F5F1);
  color: #6F4E37;
  padding: 2px 8px;
  border-radius: 6px;
  font-weight: 600;
}

.recipe-tile-price {
  font-size: 0.90rem;
  font-weight: 800;
  color: var(--color-caramel, #C27838);
}

.recipe-tile-status-row {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 2px;
}

.recipe-tile-ing-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  padding-top: 8px;
  border-top: 1px dashed #f1f5f9;
}

.recipe-ing-tag {
  font-size: 0.72rem;
  background: #f8fafc;
  color: #475569;
  border: 1px solid #e2e8f0;
  padding: 2px 7px;
  border-radius: 5px;
  white-space: nowrap;
}

.recipe-tile-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 8px;
  border-top: 1px solid #f1f5f9;
  margin-top: auto;
}

.recipe-tile-arrows {
  display: flex;
  gap: 4px;
}

.recipe-tile-arrows button {
  padding: 3px 8px;
  font-size: 0.80rem;
  font-weight: 700;
}

.recipe-tile-btns {
  display: flex;
  gap: 6px;
}

/* ==========================================================
 * PRODUCT REORDER MODAL
 * ========================================================== */
.product-reorder-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: #FFFFFF;
  border: 1px solid var(--color-cream, #E5DCD3);
  border-radius: var(--radius-md, 10px);
  margin-bottom: 8px;
  gap: 12px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  transition: transform 0.15s ease, background 0.15s ease;
}

.product-reorder-item:hover {
  background: #FAFAF9;
}

.product-reorder-left {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 0;
}

.product-reorder-num {
  font-size: 0.85rem;
  font-weight: 800;
  color: var(--color-caramel, #C27838);
  min-width: 28px;
}

.product-reorder-visual {
  width: 42px;
  height: 42px;
  border-radius: 8px;
  overflow: hidden;
  background: var(--bg-subtle, #F8F5F1);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 1px solid rgba(0, 0, 0, 0.06);
}

.product-reorder-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
}

.product-reorder-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--color-espresso, #20130B);
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.product-reorder-sub {
  font-size: 0.75rem;
  color: var(--color-text-muted, #78716c);
  display: flex;
  gap: 6px;
  align-items: center;
}

.product-reorder-actions {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}

.product-reorder-actions button {
  padding: 6px 12px;
  font-size: 0.95rem;
  font-weight: 800;
  border-radius: 8px;
  min-width: 44px;
}

/* Print Only Styles */
@media print {
  body {
    background: #FFF;
    padding: 0;
  }
  .app-header, .bottom-nav, .modal-close, .btn, .cart-panel, .action-bar-sticky {
    display: none !important;
  }
  .modal.active {
    position: static;
    display: block;
  }
  .modal-content {
    box-shadow: none;
    max-width: 100%;
    padding: 0;
  }
  .receipt-paper {
    border: none;
    box-shadow: none;
    width: 100%;
    max-width: 80mm;
    margin: 0 auto;
    padding: 0;
  }
}
