/* =========================================================
   ChốtLive – Supplementary Animations & Thermal Print Styles
   + Hiệu ứng Nút bấm, Chuyển tab, Ripple & Micro-interactions
   ========================================================= */

/* ============================================================
   1. RIPPLE EFFECT CHO TẤT CẢ CÁC NÚT
   ============================================================ */
.btn-orange-pill,
.btn-outline-pill,
.btn-ghost-pill,
.chip-pill,
.nav-item-btn,
.bottom-nav-item,
.back-header-btn,
.btn-filter-icon,
.nav-circle-arrow,
.btn-ord-card-print,
.btn-ord-card-ship,
.btn-ord-card-more,
.btn-cmt-quick-print,
.segment-pill-btn,
.chart-toggle-btn,
.setting-menu-row,
.session-row-card .session-info-bubble,
.btn-logout-card,
.btn-admin-act,
.btn-sheet-close-grey,
.btn-edit-link,
.auth-tab-btn,
.btn-modal-close,
.btn-date-nav-pill {
  position: relative;
  overflow: hidden;
}

.btn-orange-pill::after,
.btn-outline-pill::after,
.btn-ghost-pill::after,
.chip-pill::after,
.nav-item-btn::after,
.back-header-btn::after,
.btn-filter-icon::after,
.nav-circle-arrow::after,
.btn-ord-card-print::after,
.btn-ord-card-ship::after,
.btn-ord-card-more::after,
.btn-cmt-quick-print::after,
.segment-pill-btn::after,
.chart-toggle-btn::after,
.btn-logout-card::after,
.btn-admin-act::after,
.btn-sheet-close-grey::after,
.btn-edit-link::after,
.auth-tab-btn::after,
.btn-modal-close::after,
.btn-date-nav-pill::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle, rgba(0, 0, 0, 0.08) 10%, transparent 10.01%);
  transform: scale(10);
  opacity: 0;
  transition: transform 0.45s ease, opacity 0.5s ease;
  pointer-events: none;
}

.btn-orange-pill:active::after,
.btn-outline-pill:active::after,
.btn-ghost-pill:active::after,
.chip-pill:active::after,
.nav-item-btn:active::after,
.back-header-btn:active::after,
.btn-filter-icon:active::after,
.nav-circle-arrow:active::after,
.btn-ord-card-print:active::after,
.btn-ord-card-ship:active::after,
.btn-ord-card-more:active::after,
.btn-cmt-quick-print:active::after,
.segment-pill-btn:active::after,
.chart-toggle-btn:active::after,
.btn-logout-card:active::after,
.btn-admin-act:active::after,
.btn-sheet-close-grey:active::after,
.btn-edit-link:active::after,
.auth-tab-btn:active::after,
.btn-modal-close:active::after,
.btn-date-nav-pill:active::after {
  transform: scale(0);
  opacity: 1;
  transition: 0s;
}

/* ============================================================
   2. NÚT BẤM – HIỆU ỨNG NÂNG CAO ACTIVE / HOVER
   ============================================================ */

/* Nút cam chính - hiệu ứng bấm phóng to nhẹ rồi thu nhỏ */
.btn-orange-pill {
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
  will-change: transform;
}

.btn-orange-pill:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(245, 140, 66, 0.3);
}

.btn-orange-pill:active {
  transform: scale(0.95) translateY(0);
  box-shadow: 0 1px 4px rgba(245, 140, 66, 0.2);
  transition-duration: 0.08s;
}

/* Nút outline */
.btn-outline-pill {
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
  will-change: transform;
}

.btn-outline-pill:hover {
  transform: translateY(-1px);
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.06);
}

.btn-outline-pill:active {
  transform: scale(0.96) translateY(0);
  transition-duration: 0.08s;
}

/* Nút ghost */
.btn-ghost-pill {
  transition: all 0.18s ease;
}

.btn-ghost-pill:active {
  transform: scale(0.95);
  transition-duration: 0.06s;
}

/* Nút back tròn */
.back-header-btn {
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.back-header-btn:hover {
  transform: translateX(-2px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.back-header-btn:active {
  transform: scale(0.9) translateX(-3px);
  transition-duration: 0.06s;
}

/* Nút filter tròn */
.btn-filter-icon {
  transition: all 0.2s ease;
}

.btn-filter-icon:hover {
  background: #f5f2ed;
  border-color: #d5cfc6;
}

.btn-filter-icon:active {
  transform: scale(0.9);
  transition-duration: 0.06s;
}

/* Nút mũi tên ngày */
.nav-circle-arrow {
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.nav-circle-arrow:active {
  transform: scale(0.88);
  transition-duration: 0.06s;
}

/* Nút 3 chấm */
.btn-ord-card-more {
  transition: all 0.18s ease;
}

.btn-ord-card-more:hover {
  background: #f5f2ed;
  border-color: #d4cdc3;
}

.btn-ord-card-more:active {
  transform: scale(0.88);
  background: #ede9e3;
  transition-duration: 0.06s;
}

/* Nút In đơn trong order card */
.btn-ord-card-print {
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.btn-ord-card-print:hover {
  transform: translateY(-1px);
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
}

.btn-ord-card-print:active {
  transform: scale(0.95);
  transition-duration: 0.06s;
}

/* Nút Giao hàng trong order card */
.btn-ord-card-ship {
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.btn-ord-card-ship:hover {
  transform: translateY(-1px);
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.06);
}

.btn-ord-card-ship:active {
  transform: scale(0.95);
  transition-duration: 0.06s;
}

/* Nút in nhanh trong comment */
.btn-cmt-quick-print {
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.btn-cmt-quick-print:hover {
  transform: scale(1.05);
}

.btn-cmt-quick-print:active {
  transform: scale(0.92);
  transition-duration: 0.06s;
}

/* Nút đăng xuất */
.btn-logout-card {
  transition: all 0.2s ease;
}

.btn-logout-card:hover {
  background: #fff5f5;
  border-color: #fecaca;
}

.btn-logout-card:active {
  transform: scale(0.97);
  background: #fef2f2;
  transition-duration: 0.06s;
}

/* Nút admin */
.btn-admin-act {
  transition: all 0.18s ease;
}

.btn-admin-act:active {
  transform: scale(0.93);
  transition-duration: 0.06s;
}

/* Nút đóng modal */
.btn-modal-close {
  transition: all 0.2s ease;
}

.btn-modal-close:hover {
  background: #ece9e3;
  transform: rotate(90deg);
}

.btn-modal-close:active {
  transform: rotate(90deg) scale(0.85);
  transition-duration: 0.06s;
}

/* ============================================================
   3. CHIP PILLS – HIỆU ỨNG CHUYỂN ĐỔI ACTIVE
   ============================================================ */
.chip-pill {
  transition: all 0.22s cubic-bezier(0.34, 1.56, 0.64, 1);
  will-change: transform;
}

.chip-pill:active {
  transform: scale(0.93);
  transition-duration: 0.06s;
}

.chip-pill.active {
  animation: chipActivate 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes chipActivate {
  0% {
    transform: scale(0.92);
  }

  50% {
    transform: scale(1.06);
  }

  100% {
    transform: scale(1);
  }
}

/* Chart toggle buttons */
.chart-toggle-btn {
  transition: all 0.22s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.chart-toggle-btn.active {
  animation: chipActivate 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.chart-toggle-btn:active {
  transform: scale(0.93);
  transition-duration: 0.06s;
}

/* Segmented control pills */
.segment-pill-btn {
  transition: all 0.22s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.segment-pill-btn.active {
  animation: segmentSlide 0.28s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes segmentSlide {
  0% {
    transform: scale(0.9);
    opacity: 0.5;
  }

  60% {
    transform: scale(1.04);
  }

  100% {
    transform: scale(1);
    opacity: 1;
  }
}

/* ============================================================
   4. SIDEBAR & BOTTOM NAV – HIỆU ỨNG CHUYỂN TAB
   ============================================================ */

/* Sidebar nav items */
.nav-item-btn {
  transition: all 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  will-change: transform, background;
}

.nav-item-btn:active {
  transform: scale(0.95);
  transition-duration: 0.06s;
}

.nav-item-btn.active {
  animation: navItemPop 0.32s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes navItemPop {
  0% {
    transform: scale(0.92) translateX(-4px);
    opacity: 0.6;
  }

  50% {
    transform: scale(1.04) translateX(0);
  }

  100% {
    transform: scale(1) translateX(0);
    opacity: 1;
  }
}

/* Bottom navigation items (mobile) */
.bottom-nav-item {
  transition: all 0.22s cubic-bezier(0.34, 1.56, 0.64, 1);
  will-change: transform;
}

.bottom-nav-item:active {
  transform: scale(0.85);
  transition-duration: 0.06s;
}

.bottom-nav-item.active {
  animation: bottomNavBounce 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.bottom-nav-item.active svg {
  animation: bottomNavIconPop 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes bottomNavBounce {
  0% {
    transform: scale(0.85);
  }

  40% {
    transform: scale(1.12);
  }

  70% {
    transform: scale(0.97);
  }

  100% {
    transform: scale(1);
  }
}

@keyframes bottomNavIconPop {
  0% {
    transform: scale(0.6) translateY(4px);
  }

  40% {
    transform: scale(1.2) translateY(-2px);
  }

  100% {
    transform: scale(1) translateY(0);
  }
}

/* ============================================================
   5. CHUYỂN ĐỔI VIEW SECTIONS – FADE & SLIDE
   ============================================================ */
.view-section.active {
  animation: viewSlideIn 0.32s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes viewSlideIn {
  0% {
    opacity: 0;
    transform: translateY(8px);
  }

  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ============================================================
   6. CARDS & ROWS – HOVER / TAP HIỆU ỨNG
   ============================================================ */

/* Customer row card – nhấn vào phóng to nhẹ */
.customer-row-item {
  transition: all 0.22s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  will-change: transform;
}

.customer-row-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
}

.customer-row-item:active {
  transform: scale(0.98) translateY(0);
  transition-duration: 0.08s;
}

/* Order card - hover lift */
.order-card-item {
  transition: all 0.22s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  will-change: transform;
}

.order-card-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
  border-color: #e4ddd3;
}

.order-card-item:active {
  transform: scale(0.98);
  transition-duration: 0.08s;
}

/* Comment row item */
.comment-row-item {
  transition: all 0.18s ease;
}

.comment-row-item:active {
  transform: scale(0.98);
  transition-duration: 0.06s;
}

.comment-row-item.selected {
  animation: commentHighlight 0.3s ease;
}

@keyframes commentHighlight {
  0% {
    background: transparent;
    transform: scale(1);
  }

  30% {
    background: #fef0e3;
    transform: scale(1.01);
  }

  100% {
    background: #fdf4ec;
    transform: scale(1);
  }
}

/* Session row card */
.session-row-card {
  transition: all 0.2s ease;
}

.session-row-card:hover .session-info-bubble {
  transform: translateX(3px);
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.04);
}

.session-row-card:active .session-info-bubble {
  transform: scale(0.98);
  transition-duration: 0.06s;
}

/* Session info bubble chevron */
.session-chevron {
  transition: transform 0.2s ease;
}

.session-row-card:hover .session-chevron {
  transform: translateX(3px);
}

/* Setting menu row */
.setting-menu-row {
  transition: all 0.18s ease;
}

.setting-menu-row:hover {
  background: #faf8f5;
}

.setting-menu-row:active {
  background: #f4f1ec;
  transform: scale(0.99);
  transition-duration: 0.06s;
}

.setting-menu-row .row-chevron {
  transition: transform 0.2s ease;
}

.setting-menu-row:hover .row-chevron {
  transform: translateX(3px);
}

/* Account item box */
.account-item-box {
  transition: all 0.18s ease;
}

.account-item-box:hover {
  background: #fdf9f5;
}

.account-item-box:active {
  transform: scale(0.98);
  transition-duration: 0.06s;
}

/* Admin user row */
.admin-user-row-card {
  transition: all 0.2s ease;
}

.admin-user-row-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.04);
}

/* Shop profile card in sidebar */
.shop-profile-card {
  transition: all 0.2s ease;
}

.shop-profile-card:active {
  transform: scale(0.96);
  transition-duration: 0.06s;
}

/* Order detail customer card */
.order-detail-cust-card {
  transition: all 0.2s ease;
}

.order-detail-cust-card:hover {
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.05);
  border-color: #e0dbd3;
}

.order-detail-cust-card:active {
  transform: scale(0.99);
  transition-duration: 0.06s;
}

/* ============================================================
   7. HERO REVENUE CARD – HIỆU ỨNG SHIMMER
   ============================================================ */
.hero-revenue-card {
  position: relative;
  overflow: hidden;
  transition: transform 0.2s ease;
}

.hero-revenue-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(90deg,
      transparent,
      rgba(255, 255, 255, 0.15),
      transparent);
  animation: heroShimmer 4s ease-in-out infinite;
  pointer-events: none;
}

@keyframes heroShimmer {
  0% {
    left: -60%;
  }

  50% {
    left: 110%;
  }

  100% {
    left: 110%;
  }
}

.hero-revenue-card:hover {
  transform: translateY(-2px);
}

/* ============================================================
   8. MODAL / BOTTOM SHEET – HIỆU ỨNG MỞ / ĐÓNG NÂNG CAO
   ============================================================ */
.app-modal-dialog {
  animation: modalFadeIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalFadeIn {
  from {
    opacity: 0;
    transform: scale(0.95) translateY(10px);
  }

  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.app-modal-dialog::backdrop {
  animation: backdropFadeIn 0.25s ease;
}

@keyframes backdropFadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

/* Bottom sheet on mobile – enhanced slide up */
@media (max-width: 768px) {
  .bottom-sheet-dialog .modal-content-card {
    animation: slideUpSheetEnhanced 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  }
}

@keyframes slideUpSheetEnhanced {
  0% {
    transform: translateY(100%);
    opacity: 0.8;
  }

  60% {
    transform: translateY(-2%);
    opacity: 1;
  }

  100% {
    transform: translateY(0);
    opacity: 1;
  }
}

/* Sheet drag handle – pulse hint on open */
.sheet-drag-handle {
  transition: all 0.2s ease;
  animation: dragHandlePulse 1.5s ease 0.5s 1;
}

@keyframes dragHandlePulse {
  0% {
    width: 42px;
  }

  25% {
    width: 56px;
    background: #c4bfb7;
  }

  50% {
    width: 42px;
  }

  100% {
    width: 42px;
  }
}

/* ============================================================
   9. BADGES – HIỆU ỨNG XUẤT HIỆN
   ============================================================ */
.badge-pill-tag {
  animation: badgePop 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes badgePop {
  0% {
    transform: scale(0);
    opacity: 0;
  }

  70% {
    transform: scale(1.15);
  }

  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.badge-live-tag {
  animation: liveBadgePulse 2s ease infinite;
}

@keyframes liveBadgePulse {
  0% {
    box-shadow: 0 0 0 0 rgba(217, 56, 41, 0.15);
  }

  50% {
    box-shadow: 0 0 0 6px rgba(217, 56, 41, 0);
  }

  100% {
    box-shadow: 0 0 0 0 rgba(217, 56, 41, 0);
  }
}

.badge-order-status {
  transition: all 0.2s ease;
}

/* ============================================================
   10. LIVE PULSE DOT – MỞ RỘNG ANIMATION
   ============================================================ */
.live-red-dot {
  animation: liveRedDotBlink 1.4s ease infinite;
}

@keyframes liveRedDotBlink {

  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.4;
    transform: scale(0.7);
  }
}

/* ============================================================
   11. STAGGERED ANIMATIONS – DANH SÁCH ITEMS XUẤT HIỆN LẦN LƯỢT
   ============================================================ */
.customer-row-item,
.order-card-item,
.history-order-row,
.saved-live-item,
.sheet-option-item,
.admin-user-row-card {
  animation: listItemSlideIn 0.35s cubic-bezier(0.16, 1, 0.3, 1) both;
}

/* Delay lần lượt từng item bằng CSS nth-child */
.customer-row-item:nth-child(1),
.order-card-item:nth-child(1),
.admin-user-row-card:nth-child(1) {
  animation-delay: 0.02s;
}

.customer-row-item:nth-child(2),
.order-card-item:nth-child(2),
.admin-user-row-card:nth-child(2) {
  animation-delay: 0.06s;
}

.customer-row-item:nth-child(3),
.order-card-item:nth-child(3),
.admin-user-row-card:nth-child(3) {
  animation-delay: 0.10s;
}

.customer-row-item:nth-child(4),
.order-card-item:nth-child(4),
.admin-user-row-card:nth-child(4) {
  animation-delay: 0.14s;
}

.customer-row-item:nth-child(5),
.order-card-item:nth-child(5),
.admin-user-row-card:nth-child(5) {
  animation-delay: 0.18s;
}

.customer-row-item:nth-child(n+6),
.order-card-item:nth-child(n+6),
.admin-user-row-card:nth-child(n+6) {
  animation-delay: 0.22s;
}

/* Danh sách bình luận được vẽ lại liên tục khi đang live. Hiệu ứng từ độ mờ 0 chạy lại ở
   mỗi lần vẽ từng làm các dòng không bao giờ hiện ra, nên không dùng cho bình luận. */
.comment-row-item.is-new {
  animation: commentRowArrive 0.6s ease-out;
}

.comment-row-item .badge-pill-tag {
  animation: none;
}

/* Chỉ nháy nền, chữ luôn hiện rõ dù bình luận về dồn dập. */
@keyframes commentRowArrive {
  from {
    background-color: #fff1e6;
  }

  to {
    background-color: transparent;
  }
}

@keyframes listItemSlideIn {
  0% {
    opacity: 0;
    transform: translateY(12px);
  }

  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ============================================================
   12. BARCHART – HIỆU ỨNG CỘT MỌC LÊN
   ============================================================ */
.barchart-pill-bar {
  animation: barGrow 0.6s cubic-bezier(0.16, 1, 0.3, 1) both;
  transform-origin: bottom;
}

.barchart-col:nth-child(1) .barchart-pill-bar {
  animation-delay: 0.05s;
}

.barchart-col:nth-child(2) .barchart-pill-bar {
  animation-delay: 0.10s;
}

.barchart-col:nth-child(3) .barchart-pill-bar {
  animation-delay: 0.15s;
}

.barchart-col:nth-child(4) .barchart-pill-bar {
  animation-delay: 0.20s;
}

.barchart-col:nth-child(5) .barchart-pill-bar {
  animation-delay: 0.25s;
}

.barchart-col:nth-child(6) .barchart-pill-bar {
  animation-delay: 0.30s;
}

.barchart-col:nth-child(7) .barchart-pill-bar {
  animation-delay: 0.35s;
}

@keyframes barGrow {
  0% {
    transform: scaleY(0);
    opacity: 0;
  }

  100% {
    transform: scaleY(1);
    opacity: 1;
  }
}

.barchart-tooltip-val {
  animation: tooltipFadeIn 0.4s cubic-bezier(0.16, 1, 0.3, 1) 0.4s both;
}

@keyframes tooltipFadeIn {
  0% {
    opacity: 0;
    transform: translateY(4px);
  }

  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Barchart col hover effect */
.barchart-col:hover .barchart-pill-bar {
  filter: brightness(1.1);
  transform: scaleY(1.03);
  transition: all 0.15s ease;
}

/* ============================================================
   13. TIMELINE – HIỆU ỨNG DÒNG THỜI GIAN
   ============================================================ */
.timeline-live-chunk {
  animation: chunkFadeIn 0.5s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.timeline-live-chunk.active-chunk {
  animation: chunkFadeIn 0.5s cubic-bezier(0.16, 1, 0.3, 1) 0.15s both,
    chunkPulse 3s ease 1s infinite;
}

@keyframes chunkFadeIn {
  from {
    transform: scaleX(0);
    opacity: 0;
  }

  to {
    transform: scaleX(1);
    opacity: 1;
  }
}

@keyframes chunkPulse {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.7;
  }
}

.timeline-cursor-line {
  animation: cursorBlink 1.8s ease infinite;
}

@keyframes cursorBlink {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.3;
  }
}

/* ============================================================
   14. METRICS TILES – COUNTER ANIMATION
   ============================================================ */
.tile-metric-item {
  transition: all 0.2s ease;
  animation: tileSlideUp 0.35s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.tile-metric-item:nth-child(1) {
  animation-delay: 0.05s;
}

.tile-metric-item:nth-child(2) {
  animation-delay: 0.10s;
}

.tile-metric-item:nth-child(3) {
  animation-delay: 0.15s;
}

.tile-metric-item:nth-child(4) {
  animation-delay: 0.20s;
}

@keyframes tileSlideUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.tile-metric-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
}

/* ============================================================
   15. DONUT CHART – HIỆU ỨNG VẼ VÒNG TRÒN
   ============================================================ */
#sales-donut-circle {
  transition: stroke-dashoffset 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* ============================================================
   16. STAT WHITE BOXES – HOVER LIFT
   ============================================================ */
.stat-white-box {
  transition: all 0.2s ease;
}

.stat-white-box:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.05);
}

/* ============================================================
   17. TOAST – HIỆU ỨNG NÂNG CAO
   ============================================================ */
.toast-item {
  animation: toastSlideIn 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes toastSlideIn {
  0% {
    opacity: 0;
    transform: translateY(16px) scale(0.9);
  }

  60% {
    transform: translateY(-2px) scale(1.02);
  }

  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* ============================================================
   18. AUTH SCREEN – HIỆU ỨNG CARD LOGIN
   ============================================================ */
.auth-card-box {
  animation: authCardIn 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes authCardIn {
  0% {
    opacity: 0;
    transform: translateY(20px) scale(0.96);
  }

  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.auth-logo-badge {
  animation: logoBounce 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) 0.2s both;
}

@keyframes logoBounce {
  0% {
    transform: scale(0) rotate(-15deg);
  }

  60% {
    transform: scale(1.15) rotate(3deg);
  }

  100% {
    transform: scale(1) rotate(0);
  }
}

/* Auth tab switcher – sliding indicator effect */
.auth-tab-btn {
  transition: all 0.22s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.auth-tab-btn.active {
  animation: authTabPop 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes authTabPop {
  0% {
    transform: scale(0.95);
  }

  50% {
    transform: scale(1.04);
  }

  100% {
    transform: scale(1);
  }
}

/* Auth submit button loading state */
.auth-submit-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  animation: btnPulseLoading 1.2s ease infinite;
}

@keyframes btnPulseLoading {

  0%,
  100% {
    opacity: 0.7;
  }

  50% {
    opacity: 0.5;
  }
}

/* ============================================================
   19. STICKY ORDER BAR – SLIDE UP
   ============================================================ */
.mobile-sticky-order-bar {
  animation: stickyBarSlideUp 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes stickyBarSlideUp {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

/* ============================================================
   20. PROFILE CARD – HIỆU ỨNG SLIDE IN
   ============================================================ */
.profile-summary-card,
.profile-address-card,
.profile-history-card {
  animation: profileCardSlide 0.35s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.profile-address-card {
  animation-delay: 0.06s;
}

.profile-history-card {
  animation-delay: 0.12s;
}

@keyframes profileCardSlide {
  from {
    opacity: 0;
    transform: translateY(15px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ============================================================
   21. FOCUS RING CHO INPUT FIELDS
   ============================================================ */
.form-field-input {
  transition: all 0.2s ease;
}

.form-field-input:focus {
  border-color: var(--primary-orange);
  box-shadow: 0 0 0 3px rgba(245, 140, 66, 0.12);
}

/* Search box enhanced focus */
.header-search-box {
  transition: all 0.2s ease;
}

.header-search-box:focus-within {
  box-shadow: 0 0 0 3px rgba(245, 140, 66, 0.1);
  border-color: var(--primary-orange);
}

/* ============================================================
   22. QUICK PRINTER & SYNC BADGES – HOVER
   ============================================================ */
.quick-printer-badge {
  transition: all 0.18s ease;
}

.quick-printer-badge:hover {
  background: #fff;
  transform: translateX(2px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.quick-printer-badge:active {
  transform: scale(0.96);
  transition-duration: 0.06s;
}

/* Printer dot pulse when connected */
.printer-dot {
  transition: background 0.3s ease;
}

.printer-dot[style*="background:#16a34a"],
.printer-dot[style*="background: #16a34a"],
.printer-dot[style*="background: rgb(22, 163, 74)"] {
  animation: printerDotPulse 2.5s ease infinite;
}

@keyframes printerDotPulse {

  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.4);
  }

  50% {
    box-shadow: 0 0 0 4px rgba(22, 163, 74, 0);
  }
}

/* ============================================================
   23. SAVED LIVE ITEMS – STAGGERED ENTRY
   ============================================================ */
.saved-live-item {
  animation: savedItemSlide 0.3s cubic-bezier(0.16, 1, 0.3, 1) both;
  transition: all 0.18s ease;
}

.saved-live-item:nth-child(1) {
  animation-delay: 0.05s;
}

.saved-live-item:nth-child(2) {
  animation-delay: 0.10s;
}

.saved-live-item:nth-child(3) {
  animation-delay: 0.15s;
}

@keyframes savedItemSlide {
  from {
    opacity: 0;
    transform: translateX(-10px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.saved-live-item:hover {
  background: #fdfbf8;
  border-color: #e0dbd3;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

/* ============================================================
   24. HIỆU ỨNG SCROLL MƯỢT CHO CÁC CONTAINER
   ============================================================ */
.comment-list-stream,
.customers-list-table,
.orders-list-table,
.sessions-list-container,
.area-ward-list,
.history-orders-list {
  scroll-behavior: smooth;
}

/* ============================================================
   25. REDUCE MOTION – TÔN TRỌNG CÀI ĐẶT HỆ THỐNG
   ============================================================ */
@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ============================================================
   VIRTUAL RECEIPT TICKET STYLES (giữ nguyên)
   ============================================================ */
.printed-bill-ticket {
  margin: 10px auto;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  animation: rollTicket 0.6s cubic-bezier(0.2, 0.9, 0.3, 1);
  display: inline-block;
  background: #fff;
}

.printed-bill-ticket img {
  display: block;
  max-width: 100%;
  height: auto;
}

@keyframes rollTicket {
  0% {
    transform: translateY(-40px) scaleY(0.4);
    opacity: 0;
  }

  100% {
    transform: translateY(0) scaleY(1);
    opacity: 1;
  }
}

/* Print media */
@media print {

  .app-sidebar,
  .view-header,
  .btn-orange-pill,
  .btn-outline-pill,
  .btn-ghost-pill {
    display: none !important;
  }

  body,
  .app-container,
  .app-main {
    background: #fff !important;
    padding: 0 !important;
  }
}