/* =============================================
   CAFECA ATRIUM — Main Stylesheet
   Beige / Cream / Coffee-Brown Theme
   ============================================= */

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

/* ─── CSS Variables ─── */
:root {
  --cream-50: #FDFBF7;
  --cream-100: #F8F4EC;
  --cream-200: #F0E8D6;
  --cream-300: #E4D5B8;
  --beige-400: #D4B896;
  --beige-500: #C4A575;
  --coffee-600: #A08050;
  --coffee-700: #7D5F35;
  --coffee-800: #5C4020;
  --coffee-900: #3D2B0F;
  --espresso: #2C1A09;

  --white: #FFFFFF;
  --success: #5a9e6f;
  --danger: #c0392b;
  --warning: #e6a817;
  --info: #2980b9;

  --shadow-xs: 0 1px 3px rgba(60, 40, 10, .08);
  --shadow-sm: 0 2px 8px rgba(60, 40, 10, .10);
  --shadow-md: 0 4px 20px rgba(60, 40, 10, .14);
  --shadow-lg: 0 8px 40px rgba(60, 40, 10, .18);
  --shadow-xl: 0 16px 60px rgba(60, 40, 10, .22);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;

  --font-body: 'Inter', sans-serif;
  --font-display: 'Playfair Display', serif;

  --sidebar-w: 260px;
  --transition: all .28s cubic-bezier(.4, 0, .2, 1);
}



/* ─── Base ─── */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background: var(--cream-100);
  color: var(--coffee-900);
  font-size: 0.9375rem;
  line-height: 1.6;
  transition: background .3s, color .3s;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-display);
  color: var(--coffee-800);
  font-weight: 600;
}

a {
  color: var(--coffee-700);
  text-decoration: none;
  transition: var(--transition);
}

a:hover {
  color: var(--coffee-900);
}

img {
  max-width: 100%;
}

/* ─── Scrollbar ─── */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: var(--cream-200);
}

::-webkit-scrollbar-thumb {
  background: var(--beige-400);
  border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--coffee-600);
}

/* ─── Buttons ─── */
.btn-coffee {
  background: linear-gradient(135deg, var(--coffee-700), var(--coffee-800));
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  padding: .55rem 1.4rem;
  font-weight: 600;
  font-size: .9rem;
  transition: var(--transition);
  box-shadow: 0 3px 12px rgba(125, 95, 53, .35);
}

.btn-coffee:hover {
  background: linear-gradient(135deg, var(--coffee-800), var(--espresso));
  color: #fff;
  box-shadow: 0 6px 20px rgba(125, 95, 53, .45);
  transform: translateY(-1px);
}

.btn-cream {
  background: var(--cream-100);
  color: var(--coffee-800);
  border: 1.5px solid var(--beige-400);
  border-radius: var(--radius-sm);
  padding: .55rem 1.4rem;
  font-weight: 500;
  transition: var(--transition);
}

.btn-cream:hover {
  background: var(--cream-200);
  border-color: var(--coffee-600);
  color: var(--coffee-900);
}

.btn-outline-coffee {
  border: 1.5px solid var(--coffee-700);
  color: var(--coffee-700);
  border-radius: var(--radius-sm);
  padding: .55rem 1.4rem;
  font-weight: 500;
  background: transparent;
  transition: var(--transition);
}

.btn-outline-coffee:hover {
  background: var(--coffee-700);
  color: #fff;
}

/* ─── Cards ─── */
.card-glass {
  background: rgba(253, 251, 247, .82);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(212, 184, 150, .3);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  transition: var(--transition);
}

.card-glass:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

.card-stat {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  border: 1px solid var(--cream-200);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

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

.card-product {
  background: var(--white);
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--cream-200);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.card-product:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

.card-product .product-img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  transition: transform .4s ease;
}

.card-product:hover .product-img {
  transform: scale(1.05);
}

/* Sidebar mobile overlay */
.sidebar-overlay {
  position: fixed;
  inset: 0;
  background: rgba(44, 26, 9, 0.4);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  z-index: 999;
  display: none;
}

.sidebar-overlay.show {
  display: block;
}

/* ─── Sidebar ─── */
.sidebar {
  width: var(--sidebar-w);
  min-height: 100vh;
  background: linear-gradient(180deg, var(--espresso) 0%, var(--coffee-900) 50%, var(--coffee-800) 100%);
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 1000;
  transition: transform .3s ease;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  overflow-x: hidden;
}

.sidebar-brand {
  padding: 1.5rem 1.2rem 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
  display: flex;
  align-items: center;
  gap: .8rem;
}

.sidebar-brand img {
  width: 60px;
  height: 60px;
  border-radius: 8px;
  object-fit: contain;
}

.navbar-brand-text {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.4rem;
  color: var(--cream-100);
  letter-spacing: 0.5px;
  line-height: 1;
  transition: var(--transition);
}

.navbar-brand-text:hover {
  color: var(--beige-400);
}

.sidebar-brand .brand-text {
  font-family: var(--font-display);
  color: var(--cream-200);
  font-size: 1.05rem;
  font-weight: 600;
  line-height: 1.2;
}

.sidebar-brand .brand-sub {
  color: var(--beige-400);
  font-size: .7rem;
  font-family: var(--font-body);
  letter-spacing: 2px;
  text-transform: uppercase;
}

.sidebar-section-title {
  color: var(--beige-500);
  font-size: .65rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 1rem 1.2rem .4rem;
  font-family: var(--font-body);
  font-weight: 600;
}

.sidebar-nav {
  padding: .5rem 0;
  flex: 1;
}

.sidebar-nav .nav-item {
  margin: 2px 8px;
}

.sidebar-nav .nav-link {
  color: rgba(240, 228, 208, .75);
  padding: .65rem 1rem;
  border-radius: var(--radius-sm);
  font-size: .875rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: .75rem;
  transition: var(--transition);
  position: relative;
}

.sidebar-nav .nav-link i {
  font-size: 1.05rem;
  width: 20px;
  text-align: center;
}

.sidebar-nav .nav-link:hover {
  color: var(--cream-100);
  background: rgba(255, 255, 255, .1);
}

.sidebar-nav .nav-link.active {
  color: var(--cream-100);
  background: linear-gradient(90deg, var(--coffee-600), var(--beige-500));
  box-shadow: 0 3px 10px rgba(160, 128, 80, .4);
}

.sidebar-nav .nav-link .badge-count {
  margin-left: auto;
  background: var(--danger);
  color: #fff;
  border-radius: 20px;
  padding: 1px 7px;
  font-size: .7rem;
  font-weight: 700;
}

.sidebar-footer {
  padding: 1rem 1.2rem;
  border-top: 1px solid rgba(255, 255, 255, .08);
}

.sidebar-footer .user-mini {
  display: flex;
  align-items: center;
  gap: .75rem;
  color: rgba(240, 228, 208, .8);
  font-size: .82rem;
}

.sidebar-footer .user-mini img {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--beige-500);
}

/* ─── Main Content ─── */
.main-content {
  margin-left: var(--sidebar-w);
  min-height: 100vh;
  transition: margin-left .3s ease;
}

/* ─── Topbar ─── */
.topbar {
  background: rgba(253, 251, 247, .92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--cream-200);
  padding: .75rem 1.5rem;
  position: sticky;
  top: 0;
  z-index: 900;
  display: flex;
  align-items: center;
  gap: 1rem;
  box-shadow: var(--shadow-xs);
}

.topbar .page-title {
  font-family: var(--font-display);
  font-size: 1.15rem;
  color: var(--coffee-800);
  font-weight: 600;
  margin: 0;
}

.topbar .topbar-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: .75rem;
}

/* ─── Dashboard Stats ─── */
.stat-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
}

.stat-icon.coffee {
  background: linear-gradient(135deg, var(--coffee-700), var(--coffee-800));
  color: #fff;
}

.stat-icon.success {
  background: linear-gradient(135deg, #5a9e6f, #3d7a52);
  color: #fff;
}

.stat-icon.warning {
  background: linear-gradient(135deg, #e6a817, #c48a0e);
  color: #fff;
}

.stat-icon.info {
  background: linear-gradient(135deg, #2980b9, #1c5e8a);
  color: #fff;
}

/* ─── Forms ─── */
.form-control,
.form-select {
  border: 1.5px solid var(--cream-300);
  border-radius: var(--radius-sm);
  background: var(--cream-50);
  color: var(--coffee-900);
  padding: .6rem 1rem;
  font-size: .9rem;
  transition: var(--transition);
}

.form-control:focus,
.form-select:focus {
  border-color: var(--coffee-600);
  box-shadow: 0 0 0 3px rgba(160, 128, 80, .15);
  background: var(--white);
}

.form-label {
  color: var(--coffee-800);
  font-weight: 500;
  font-size: .875rem;
  margin-bottom: .35rem;
}

.input-group-text {
  background: var(--cream-200);
  border: 1.5px solid var(--cream-300);
  color: var(--coffee-600);
}

/* ─── Tables ─── */
.table-cafeca thead th {
  background: var(--cream-200);
  color: var(--coffee-800);
  font-weight: 600;
  font-size: .82rem;
  text-transform: uppercase;
  letter-spacing: .5px;
  border-bottom: 2px solid var(--beige-400);
  white-space: nowrap;
}

.table-cafeca tbody tr {
  transition: var(--transition);
  border-bottom: 1px solid var(--cream-200);
}

.table-cafeca tbody tr:hover {
  background: var(--cream-100);
}

/* ─── Badges / Status ─── */
.badge-status {
  display: inline-block;
  padding: .3rem .8rem;
  border-radius: 20px;
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .3px;
}

.status-pending {
  background: #fff3cd;
  color: #856404;
}

.status-approved {
  background: #d1f5e0;
  color: #1a6b35;
}

.status-preparing {
  background: #cce5ff;
  color: #003f88;
}

.status-for_delivery {
  background: #e2d9f3;
  color: #4a2c7a;
}

.status-on_delivery {
  background: #ffd5ec;
  color: #7a1540;
}

.status-ready_for_pickup {
  background: #fff0d4;
  color: #8a5a19;
  border: 1px solid #ffd899;
}

.status-completed {
  background: #d1f5e0;
  color: #1a6b35;
}

.status-cancelled {
  background: #fde8e8;
  color: #7a1a1a;
}

.status-expired {
  background: #f8f9fa;
  color: #6c757d;
  border: 1px dashed #adb5bd;
}

.status-verified {
  background: #d1f5e0;
  color: #1a6b35;
}

.status-rejected {
  background: #fde8e8;
  color: #7a1a1a;
}

/* ─── Landing Page ─── */
.hero-section {
  min-height: 100vh;
  background: linear-gradient(135deg, var(--espresso) 0%, var(--coffee-900) 40%, var(--coffee-800) 100%);
  position: relative;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url('../images/hero-bg.jpg') center/cover no-repeat;
  opacity: .12;
}

.hero-section .hero-content {
  position: relative;
  z-index: 1;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 7vw, 5rem);
  color: var(--cream-100);
  line-height: 1.1;
  font-weight: 700;
}

.hero-title span {
  color: var(--beige-400);
}

.hero-subtitle {
  color: var(--cream-300);
  font-size: 1.1rem;
  max-width: 500px;
}

/* Hero Circles */
.hero-circle-outer {
  width: 440px;
  height: 440px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
}

.hero-circle-inner {
  width: 360px;
  height: 360px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
}

body.no-bg .hero-circle-outer,
body.no-bg .hero-circle-inner {
  background: transparent !important;
  border: none !important;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  background: rgba(255, 255, 255, .1);
  border: 1px solid rgba(255, 255, 255, .2);
  color: var(--beige-400);
  padding: .4rem 1rem;
  border-radius: 30px;
  font-size: .8rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  backdrop-filter: blur(10px);
  margin-bottom: 1.5rem;
}

/* ─── Navbar (Public) ─── */
.navbar-cafeca {
  background: rgba(44, 26, 9, .95);
  backdrop-filter: blur(10px);
  padding: .8rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, .06);
}

.navbar-cafeca .navbar-brand img {
  height: 38px;
}

.navbar-cafeca .nav-link {
  color: rgba(240, 228, 208, .8) !important;
  font-size: .88rem;
  font-weight: 500;
  padding: .4rem .9rem !important;
  transition: var(--transition);
}

.navbar-cafeca .nav-link:hover {
  color: var(--beige-400) !important;
}

/* ─── Product Cards (Public) ─── */
.product-badge {
  position: absolute;
  top: .7rem;
  left: .7rem;
  background: linear-gradient(135deg, var(--coffee-700), var(--coffee-800));
  color: #fff;
  padding: .2rem .6rem;
  border-radius: 4px;
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .5px;
  text-transform: uppercase;
}

/* ─── Cart ─── */
.cart-sidebar {
  position: fixed;
  top: 0;
  right: -400px;
  width: 380px;
  height: 100vh;
  background: var(--cream-50);
  box-shadow: -4px 0 30px rgba(44, 26, 9, .2);
  z-index: 1050;
  transition: right .35s ease;
  display: flex;
  flex-direction: column;
}

.cart-sidebar.open {
  right: 0;
}

.cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(44, 26, 9, .5);
  z-index: 1049;
  display: none;
  backdrop-filter: blur(2px);
}

.cart-overlay.show {
  display: block;
}

/* ─── POS Layout ─── */
.pos-wrapper {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 1.5rem;
  height: calc(100vh - 80px);
}

.pos-left {
  overflow-y: auto;
  padding-right: .5rem;
}

.pos-right {
  background: var(--white);
  border-radius: var(--radius-md);
  border: 1px solid var(--cream-200);
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.pos-right .pos-header {
  padding: 1rem 1.2rem;
  background: linear-gradient(135deg, var(--coffee-800), var(--espresso));
  color: var(--cream-100);
}

.pos-cart-items {
  flex: 1;
  overflow-y: auto;
  padding: .75rem;
}

.pos-footer {
  padding: 1rem;
  border-top: 2px solid var(--cream-200);
  background: var(--cream-50);
}

/* ─── Skeleton Loader ─── */
.skeleton {
  background: linear-gradient(90deg, var(--cream-200) 25%, var(--cream-300) 50%, var(--cream-200) 75%);
  background-size: 200% 100%;
  animation: skeleton-load 1.5s infinite;
  border-radius: var(--radius-sm);
}

@keyframes skeleton-load {
  0% {
    background-position: 200% 0;
  }

  100% {
    background-position: -200% 0;
  }
}

/* ─── Toast ─── */
.toast-container {
  z-index: 9999;
}

.toast-cafeca {
  border-radius: var(--radius-md);
  border: none;
  box-shadow: var(--shadow-lg);
  background: var(--cream-50);
  border-left: 4px solid var(--coffee-700);
}



/* ─── Animations ─── */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

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

@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateX(-15px);
  }

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

.fade-up {
  animation: fadeInUp .5s ease forwards;
}

.fade-in {
  animation: fadeIn .4s ease forwards;
}

.slide-in {
  animation: slideIn .4s ease forwards;
}

.stagger-1 {
  animation-delay: .1s;
  opacity: 0;
}

.stagger-2 {
  animation-delay: .2s;
  opacity: 0;
}

.stagger-3 {
  animation-delay: .3s;
  opacity: 0;
}

.stagger-4 {
  animation-delay: .4s;
  opacity: 0;
}

/* ─── Responsive ─── */
@media (max-width: 991.98px) {
  .sidebar {
    transform: translateX(-100%);
  }

  .sidebar.open {
    transform: translateX(0);
  }

  .main-content {
    margin-left: 0;
  }

  .pos-wrapper {
    grid-template-columns: 1fr;
    height: auto;
  }

  .pos-left {
    overflow: visible;
  }

  .pos-right {
    height: auto;
    min-height: 400px;
  }

  .hero-circle-outer {
    width: 340px;
    height: 340px;
  }

  .hero-circle-inner {
    width: 280px;
    height: 280px;
  }
}

@media (max-width: 575.98px) {
  .hero-title {
    font-size: 2rem;
  }

  .cart-sidebar {
    width: 100%;
    right: -100%;
  }

  .topbar {
    padding: .75rem .75rem;
    gap: .5rem;
  }

  .topbar .page-title {
    font-size: .95rem;
  }

  .topbar .btn {
    padding: .25rem .5rem;
    font-size: .8rem;
  }

  .hero-circle-outer {
    width: 280px;
    height: 280px;
  }

  .hero-circle-inner {
    width: 230px;
    height: 230px;
  }

  .hero-floating-card-left {
    left: 5px !important;
    top: 5% !important;
  }

  .hero-floating-card-right {
    right: 5px !important;
    bottom: 5% !important;
  }
}

/* ─── Utilities ─── */
.text-coffee {
  color: var(--coffee-700) !important;
}

.bg-coffee {
  background: var(--coffee-700) !important;
}

.bg-cream {
  background: var(--cream-100) !important;
}

.border-cream {
  border-color: var(--cream-200) !important;
}

.rounded-cafeca {
  border-radius: var(--radius-md) !important;
}

.shadow-cafeca {
  box-shadow: var(--shadow-md) !important;
}

/* ─── DataTables override ─── */
.dataTables_wrapper .dataTables_filter input {
  border: 1.5px solid var(--cream-300);
  border-radius: var(--radius-sm);
  padding: .4rem .8rem;
}

.dataTables_wrapper .dataTables_length select {
  border: 1.5px solid var(--cream-300);
  border-radius: var(--radius-sm);
  padding: .3rem .5rem;
}

.page-link {
  color: var(--coffee-700);
}

.page-item.active .page-link {
  background: var(--coffee-700);
  border-color: var(--coffee-700);
}

/* ─── Charts wrapper ─── */
.chart-wrapper {
  position: relative;
  min-height: 250px;
}

/* ─── Receipt ─── */
.receipt-paper {
  background: #fff;
  max-width: 320px;
  margin: 0 auto;
  padding: 1.5rem;
  font-family: 'Courier New', monospace;
  font-size: .8rem;
  border: 1px dashed #ccc;
  border-radius: 4px;
}

.receipt-paper .receipt-logo {
  text-align: center;
  margin-bottom: .75rem;
}

.receipt-paper hr {
  border-top: 1px dashed #ccc;
}

.receipt-paper .receipt-total {
  font-size: 1.1rem;
  font-weight: bold;
}

/* ─── Notification badge ─── */
.notif-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--danger);
  color: #fff;
  border-radius: 50%;
  width: 18px;
  height: 18px;
  font-size: .65rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  border: 2px solid var(--cream-50);
}

/* ─── Order tracking timeline (Base / Desktop) ─── */
.order-timeline {
  display: flex;
  align-items: flex-start;
  gap: 0;
  margin: 1.5rem 0;
  width: 100%;
}

.timeline-step {
  flex: 1;
  text-align: center;
  position: relative;
}

.timeline-step::before {
  content: '';
  position: absolute;
  top: 17px;
  left: -50%;
  width: 100%;
  height: 4px;
  background: var(--cream-300);
  z-index: 0;
  transition: all 0.3s ease;
  border-radius: 2px;
}

/* Green tail for completed steps */
.timeline-step.done::before {
  background: #2e7d32;
  box-shadow: 0 0 6px rgba(46, 125, 50, 0.4);
}

/* Flow of green tail leading into the active step */
.timeline-step.active::before {
  background: linear-gradient(90deg, #2e7d32 0%, #66bb6a 50%, #2e7d32 100%);
  background-size: 200% 100%;
  box-shadow: 0 0 8px rgba(76, 175, 80, 0.5);
  animation: flowGreenTail 1.8s linear infinite;
}

.timeline-step:first-child::before {
  display: none !important;
}

.timeline-step .step-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--cream-300);
  color: var(--coffee-700);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto .5rem;
  font-size: .9rem;
  position: relative;
  z-index: 1;
  transition: var(--transition);
}

.timeline-step.done .step-icon {
  background: #2e7d32;
  color: #fff;
  box-shadow: 0 2px 8px rgba(46, 125, 50, 0.35);
}

.timeline-step.active .step-icon {
  background: #2e7d32;
  color: #fff;
  box-shadow: 0 0 0 4px rgba(46, 125, 50, 0.25), 0 0 12px rgba(76, 175, 80, 0.5);
  animation: activeGreenPulse 2s ease-in-out infinite;
}

.timeline-step .step-label {
  font-size: .75rem;
  color: var(--coffee-600);
  font-weight: 500;
  line-height: 1.25;
}

.timeline-step.done .step-label {
  color: #2e7d32;
  font-weight: 600;
}

.timeline-step.active .step-label {
  color: #1b5e20;
  font-weight: 700;
}

/* Animations for green tail flow & active pulse */
@keyframes flowGreenTail {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

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

@keyframes activeGreenPulse {
  0% {
    box-shadow: 0 0 0 3px rgba(46, 125, 50, 0.3), 0 0 8px rgba(76, 175, 80, 0.3);
  }
  50% {
    box-shadow: 0 0 0 6px rgba(46, 125, 50, 0.15), 0 0 16px rgba(76, 175, 80, 0.55);
  }
  100% {
    box-shadow: 0 0 0 3px rgba(46, 125, 50, 0.3), 0 0 8px rgba(76, 175, 80, 0.3);
  }
}

/* ─── Responsive Order Tracking for Tablets & Phones (< 768px) ─── */
@media (max-width: 767.98px) {
  .order-timeline {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 1.25rem !important;
    margin: 1.25rem 0 !important;
    padding: 0.25rem 0 0.25rem 0.5rem !important;
  }

  .timeline-step {
    flex: none !important;
    text-align: left !important;
    display: flex !important;
    align-items: center !important;
    gap: 0.85rem !important;
    width: 100% !important;
    position: relative !important;
  }

  .timeline-step::before {
    left: 15px !important;
    top: -1.25rem !important;
    width: 4px !important;
    height: 1.25rem !important;
    background: var(--cream-300) !important;
    z-index: 0 !important;
    border-radius: 2px !important;
  }

  .timeline-step.done::before {
    background: #2e7d32 !important;
    box-shadow: 0 0 6px rgba(46, 125, 50, 0.4) !important;
  }

  .timeline-step.active::before {
    background: linear-gradient(180deg, #2e7d32 0%, #66bb6a 50%, #2e7d32 100%) !important;
    background-size: 100% 200% !important;
    box-shadow: 0 0 8px rgba(76, 175, 80, 0.5) !important;
    animation: flowGreenTailVertical 1.8s linear infinite !important;
  }

  .timeline-step:first-child::before {
    display: none !important;
  }

  .timeline-step .step-icon {
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    margin: 0 !important;
    font-size: 0.85rem !important;
    flex-shrink: 0 !important;
  }

  .timeline-step .step-label {
    font-size: 0.88rem !important;
    line-height: 1.3 !important;
    text-align: left !important;
    color: #666;
  }

  .timeline-step.done .step-label {
    color: #2e7d32 !important;
    font-weight: 600 !important;
  }

  .timeline-step.active .step-label {
    color: #1b5e20 !important;
    font-weight: 700 !important;
    font-size: 0.95rem !important;
  }
}

/* ─── Extra Compact Adjustments for Small Mobile Phones (< 576px) ─── */
@media (max-width: 575.98px) {
  .main-content > .p-4 {
    padding: 1rem !important;
  }

  .card-glass.active-order-card,
  .card-glass.active-order-tracking-card,
  div[id^="order-"].card-glass {
    padding: 1.15rem 1rem !important;
    border-radius: 14px !important;
  }

  .active-order-header {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 0.65rem !important;
    margin-bottom: 0.85rem !important;
  }

  .active-order-header > div:first-child {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    width: 100% !important;
  }

  .active-order-actions {
    width: 100% !important;
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    justify-content: flex-start !important;
    gap: 0.4rem !important;
  }

  .active-order-actions .btn {
    font-size: 0.78rem !important;
    padding: 0.32rem 0.6rem !important;
  }

  .active-order-actions .badge-status {
    font-size: 0.72rem !important;
    padding: 0.28rem 0.55rem !important;
  }

  .active-order-footer {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 0.5rem !important;
    width: 100% !important;
  }

  .active-order-footer .fw-bold {
    align-self: flex-end !important;
    font-size: 1.05rem !important;
  }

  .rider-info-box {
    padding: 0.65rem !important;
    font-size: 0.8rem !important;
  }
}

/* ─── FAB ─── */
.fab {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--coffee-700), var(--coffee-800));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  box-shadow: var(--shadow-lg);
  z-index: 999;
  cursor: pointer;
  transition: var(--transition);
  border: none;
}

.fab:hover {
  transform: scale(1.1) rotate(15deg);
  box-shadow: var(--shadow-xl);
  color: #fff;
}

/* ─── Global Background Reset ─── */
body.no-bg,
body.no-bg *,
body.no-bg *::before,
body.no-bg *::after {
  background: transparent !important;
  background-color: transparent !important;
  background-image: none !important;
  color: #000000 !important;
}

body.no-bg *:hover,
body.no-bg *:focus,
body.no-bg *:active {
  transform: none !important;
  box-shadow: none !important;
  background: transparent !important;
  color: #000000 !important;
}

body.no-bg a,
body.no-bg .nav-link,
body.no-bg .navbar-cafeca .nav-link,
body.no-bg .navbar-brand-text {
  color: #000000 !important;
}

body.no-bg .btn,
body.no-bg button,
body.no-bg input[type="submit"],
body.no-bg input[type="button"],
body.no-bg a.btn {
  border: 1px solid #000000 !important;
  border-radius: 4px !important;
  box-shadow: none !important;
  padding: 0.4rem 0.8rem !important;
}

body.no-bg img {
  background-color: transparent !important;
  /* allow the circle effect */
}

body.no-bg img.floating-cup {
  background-color: #fff !important;
}
/* Product Card Layout Fixes */
html {
  scroll-padding-top: 85px;
}

.card-product-content {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-desc {
  min-height: 40px;
}

.product-desc-placeholder {
  min-height: 40px;
  margin-bottom: 1rem;
}

.order-btn-wrapper {
  margin-top: auto;
}
/* Product Card Layout Fixes */
html { scroll-padding-top: 85px; }
.card-product { display: flex !important; flex-direction: column !important; height: 100% !important; }
.card-product .product-img { flex-shrink: 0 !important; }
.card-product-content { display: flex !important; flex-direction: column !important; flex: 1 !important; }
.product-desc { min-height: 44px; }
.product-desc-placeholder { min-height: 44px; margin-bottom: 1rem; }
.order-btn-wrapper { margin-top: auto !important; width: 100%; }

.btn-bestseller { width: 191px !important; }
