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

:root {
  --primary: #e8ab1f;
  --primary-dark: #c9941a;
  --primary-light: #fef3d9;
  --accent: #ff6b35;
  --dark: #1a1a2e;
  --gray-100: #f8f9fa;
  --gray-200: #e9ecef;
  --gray-300: #dee2e6;
  --gray-600: #6c757d;
  --gray-800: #343a40;
  --shadow: 0 2px 16px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 30px rgba(0,0,0,0.12);
  --radius: 16px;
  --radius-sm: 10px;
}

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: #f5f5f5;
  color: var(--dark);
  padding-top: 70px;
  overflow-x: hidden;
}

/* Footer margin set in the main .site-footer rule below */

body.cart-open {
  overflow: hidden;
}

/* ===================== NAVBAR ===================== */
.navbar-glovo {
  background: white;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
  padding: 0.6rem 0;
  z-index: 1030;
}

.navbar-glovo .navbar-brand {
  font-weight: 800;
  font-size: 1.6rem;
  color: var(--primary) !important;
  display: flex;
  align-items: center;
  gap: 8px;
}

.navbar-glovo .navbar-brand .brand-icon {
  font-size: 1.8rem;
}

.navbar-glovo .nav-link {
  font-weight: 500;
  color: var(--gray-800) !important;
  padding: 0.5rem 1rem !important;
  border-radius: var(--radius-sm);
  transition: all 0.2s;
}

.navbar-glovo .nav-link:hover {
  background: var(--primary-light);
  color: var(--primary) !important;
}

.btn-cart-nav {
  position: relative;
  background: var(--primary) !important;
  color: white !important;
  border-radius: 50px !important;
  padding: 0.5rem 1.2rem !important;
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 600 !important;
  transition: all 0.2s;
  margin-left: 10px;
  border: 2px solid var(--primary) !important;
}

.btn-cart-nav:hover {
  background: var(--primary-light) !important;
  color: var(--primary-dark) !important;
  border-color: var(--primary) !important;
  filter: none !important;
  box-shadow: none !important;
}

@media (max-width: 991.98px) {
  .navbar-glovo .navbar-nav {
    width: 100%;
  }

  .navbar-glovo .navbar-nav .nav-item {
    width: 100%;
  }

  .navbar-glovo .navbar-nav.align-items-center {
    flex-direction: column;
    align-items: stretch !important;
    gap: 6px;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid var(--gray-200);
  }

  .btn-cart-nav {
    margin-left: 0;
    width: 100%;
    justify-content: center;
  }

  .btn-login {
    width: 100%;
    justify-content: center;
    display: flex;
  }

  .btn-user {
    width: 100%;
    justify-content: center;
  }

  .user-menu {
    width: 100%;
  }

  .user-arrow {
    display: none;
  }

  .btn-logout-mobile {
    display: block;
    width: 100%;
    padding: 0.4rem;
    background: none;
    border: none;
    font-size: 0.75rem;
    color: #d47a7a;
    text-align: center;
    cursor: pointer;
    transition: color 0.2s;
  }

  .btn-logout-mobile:hover {
    color: #c0392b;
  }
}

#cartBadge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: #691818;
  color: white;
  font-size: 0.65rem;
  font-weight: 700;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid white;
}

/* ===================== HERO SECTION ===================== */
.hero-section {
  background: var(--primary);
  color: white;
  padding: 3rem 0 4rem;
  margin-top: -70px;
  padding-top: calc(70px + 3rem);
  border-radius: 0 0 40px 40px;
}

.hero-section h1 {
  font-weight: 800;
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
}

.hero-section p {
  font-size: 1.1rem;
  opacity: 0.9;
  margin-bottom: 1.5rem;
}

.search-wrapper {
  position: relative;
  max-width: 500px;
}

.search-wrapper input {
  width: 100%;
  padding: 1rem 1.2rem 1rem 3rem;
  border: none;
  border-radius: 60px;
  font-size: 1rem;
  box-shadow: var(--shadow-lg);
}

.search-wrapper input:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(255,255,255,0.3), var(--shadow-lg);
}

.search-wrapper .search-icon {
  position: absolute;
  left: 1.2rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.2rem;
  color: var(--gray-600);
}

/* ===================== SECTION TITLES ===================== */
.section-title {
  font-weight: 700;
  font-size: 1.4rem;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 10px;
}

/* ===================== STORE CARDS ===================== */
.store-card {
  background: white;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  height: 100%;
}

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

.store-card-img {
  position: relative;
  height: 180px;
  overflow: hidden;
}

.store-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s;
}

.store-card:hover .store-card-img img {
  transform: scale(1.08);
}

.store-delivery-badge {
  position: absolute;
  bottom: 12px;
  left: 12px;
  background: rgba(0,0,0,0.75);
  color: white;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  backdrop-filter: blur(4px);
}

.store-card-body {
  padding: 1rem 1.2rem 1.2rem;
}

.store-card-title {
  font-weight: 700;
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}

.store-card-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.8rem;
  color: var(--gray-600);
}

.store-rating {
  font-weight: 600;
  color: var(--dark);
}

.store-category {
  background: var(--gray-100);
  padding: 2px 10px;
  border-radius: 20px;
  font-weight: 500;
}

.store-fee {
  font-weight: 500;
}

/* ===================== STORE HERO (Products Page) ===================== */
.store-hero {
  position: relative;
  height: 260px;
  overflow: hidden;
  border-radius: 0 0 40px 40px;
  margin-top: -70px;
}

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

.store-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(transparent 30%, rgba(0,0,0,0.85));
  display: flex;
  align-items: flex-end;
  padding-bottom: 2rem;
}

.store-hero-overlay h1 {
  color: white;
  font-weight: 800;
  font-size: 2.2rem;
  margin-bottom: 0.5rem;
}

.store-hero-info {
  display: flex;
  gap: 16px;
  color: rgba(255,255,255,0.9);
  font-size: 0.9rem;
  font-weight: 500;
}

/* ===================== CATEGORY NAV (sticky) ===================== */
.category-sticky-wrapper {
  position: sticky;
  top: 70px;
  z-index: 1025;
  background: #f5f5f5;
  padding: 0.5rem 0 0;
  border-bottom: 1px solid var(--gray-200);
}

.category-nav {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 0.5rem 0 0.8rem;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.category-nav::-webkit-scrollbar {
  display: none;
}

.category-section-title {
  font-weight: 700;
  font-size: 1.2rem;
  margin-bottom: 1rem;
  padding-top: 0.5rem;
  color: var(--dark);
  border-bottom: 3px solid var(--primary);
  padding-bottom: 0.4rem;
}

.category-section {
  margin-bottom: 2rem;
  scroll-margin-top: 140px;
}

.category-btn {
  white-space: nowrap;
  padding: 0.5rem 1.2rem;
  border: 2px solid var(--gray-200);
  background: white;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--gray-600);
  cursor: pointer;
  transition: all 0.2s;
}

.category-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
}

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

/* ===================== PRODUCT CARDS ===================== */
.product-card {
  background: white;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: all 0.3s;
  height: 100%;
  display: flex;
  flex-direction: column;
  cursor: pointer;
}

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

.product-card-img {
  height: 160px;
  overflow: hidden;
}

.product-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}

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

.product-card-body {
  padding: 0.8rem 1rem 1rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.product-card-name {
  font-weight: 600;
  font-size: 0.95rem;
  margin-bottom: 0.3rem;
}

.product-card-price {
  font-weight: 700;
  color: var(--primary);
  font-size: 1.1rem;
  margin-bottom: 0.3rem;
}

.product-ingredients {
  font-size: 0.75rem;
  color: var(--gray-600);
  line-height: 1.4;
  margin-bottom: 0.6rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.btn-add-cart {
  background: var(--primary-light);
  color: var(--primary);
  border: none;
  border-radius: 50px;
  font-weight: 700;
  font-size: 0.85rem;
  padding: 0.4rem 0;
  width: 100%;
  transition: all 0.2s;
}

.btn-add-cart:hover {
  background: var(--primary);
  color: white;
}

/* ===================== CART SIDEBAR ===================== */
.cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s;
  z-index: 1040;
}

.cart-overlay.show {
  opacity: 1;
  visibility: visible;
}

.cart-sidebar {
  position: fixed;
  top: 0;
  right: -420px;
  width: 420px;
  max-width: 100vw;
  height: 100vh;
  background: white;
  z-index: 1050;
  display: flex;
  flex-direction: column;
  transition: right 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: -4px 0 20px rgba(0,0,0,0.1);
  visibility: hidden;
}

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

.cart-sidebar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.2rem 1.5rem;
  border-bottom: 1px solid var(--gray-200);
}

.cart-sidebar-header h5 {
  font-weight: 700;
  margin: 0;
}

.cart-sidebar-header h5 span {
  color: var(--gray-600);
  font-weight: 500;
  font-size: 0.9rem;
}

.btn-close-cart {
  background: var(--gray-100);
  border: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-close-cart:hover {
  background: var(--gray-200);
}

.cart-sidebar-body {
  flex: 1;
  overflow-y: auto;
  padding: 1rem 1.5rem;
}

.empty-cart-state {
  text-align: center;
  padding: 3rem 0;
  color: var(--gray-600);
}

.empty-cart-state .empty-icon {
  font-size: 4rem;
  margin-bottom: 1rem;
}

.empty-cart-state h6 {
  font-weight: 600;
  color: var(--dark);
}

/* Cart items */
.cart-store-group {
  margin-bottom: 1rem;
}

.cart-store-name {
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 0.5rem;
  padding-bottom: 0.3rem;
  border-bottom: 2px solid var(--primary-light);
}

.cart-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--gray-200);
}

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

.cart-item-img {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  object-fit: cover;
}

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

.cart-item-clickable {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  min-width: 0;
  cursor: pointer;
  padding: 2px 4px;
  margin: -2px -4px;
  border-radius: 6px;
  transition: background 0.2s;
}

.cart-item-clickable:hover {
  background: var(--primary-light);
}

.cart-item-clickable .cart-item-name::after {
  content: ' ✏️';
  font-size: 0.7rem;
  opacity: 0.5;
}

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

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

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

.qty-btn {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2px solid var(--gray-200);
  background: white;
  font-weight: 700;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
  color: var(--dark);
}

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

.cart-item-qty span {
  font-weight: 700;
  font-size: 0.9rem;
  min-width: 16px;
  text-align: center;
}

.cart-sidebar-footer {
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--gray-200);
  background: white;
}

.cart-total-row {
  display: flex;
  justify-content: space-between;
  font-weight: 700;
  font-size: 1.1rem;
  margin-bottom: 0.8rem;
}

.btn-checkout {
  width: 100%;
  padding: 0.6rem;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 60px;
  font-weight: 700;
  font-size: 0.9rem;
  transition: all 0.2s;
  cursor: pointer;
}

.btn-checkout:hover {
  background: var(--primary-dark);
}

.btn-clear-cart {
  width: 100%;
  padding: 0.45rem;
  background: transparent;
  color: var(--gray-600);
  border: 1px solid var(--gray-200);
  border-radius: 60px;
  font-weight: 600;
  font-size: 0.8rem;
  margin-top: 0.4rem;
  transition: all 0.2s;
  cursor: pointer;
}

.btn-clear-cart:hover {
  background: #fff0f0;
  color: #dc3545;
  border-color: #dc3545;
}

/* ===================== FLOATING CART BAR (Products Page) ===================== */
.floating-cart-bar {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: var(--dark);
  color: white;
  padding: 0.8rem 1.5rem;
  border-radius: 60px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: var(--shadow-lg);
  z-index: 1060;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  opacity: 0;
  pointer-events: none;
}

.floating-cart-bar.show {
  transform: translateX(-50%) translateY(0) !important;
  opacity: 1 !important;
  pointer-events: all;
  visibility: visible !important;
  background: var(--primary);
}

.floating-cart-bar.show:hover {
  background: var(--primary-dark);
}

.floating-cart-bar.cart-open-hidden {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

.floating-cart-bar:hover {
  transform: translateX(-50%) translateY(-2px);
  background: #2a2a3e;
}

.cart-bar-icon {
  position: relative;
  font-size: 1.3rem;
}

.cart-bar-count {
  position: absolute;
  top: -8px;
  right: -10px;
  background: #691818;
  font-size: 0.6rem;
  font-weight: 700;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cart-bar-total {
  font-weight: 700;
  font-size: 1.05rem;
  min-width: 60px;
}

.cart-bar-action {
  background: var(--primary);
  padding: 0.4rem 1rem;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.85rem;
}

/* ===================== TOAST ===================== */
.toast-container {
  position: fixed;
  top: 80px;
  right: 20px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toast-notification {
  background: white;
  padding: 0.8rem 1.2rem;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 500;
  font-size: 0.9rem;
  transform: translateX(120%);
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  border-left: 4px solid var(--primary);
}

.toast-notification.show {
  transform: translateX(0);
}

/* ===================== CART ITEM EXTRAS ===================== */
.cart-item-extra {
  display: block;
  font-size: 0.7rem;
  color: var(--gray-600);
  line-height: 1.3;
}

/* ===================== CUSTOMIZATION MODAL ===================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s;
  z-index: 1060;
}

.modal-overlay.show {
  opacity: 1;
  visibility: visible;
}

.custom-modal {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  max-width: 500px;
  margin: 0 auto;
  background: white;
  border-radius: 20px 20px 0 0;
  z-index: 1070;
  transform: translateY(100%);
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 -4px 30px rgba(0,0,0,0.15);
}

.custom-modal.open {
  transform: translateY(0);
}

.custom-modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: none;
  background: var(--gray-100);
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 2;
  transition: all 0.2s;
}

.custom-modal-close:hover {
  background: var(--gray-200);
}

.custom-modal-body {
  padding: 1.5rem;
  overflow-y: auto;
  flex: 1;
}

.custom-modal-top {
  display: flex;
  gap: 14px;
  align-items: center;
  margin-bottom: 1.5rem;
  padding-right: 30px;
}

.custom-modal-img {
  width: 72px;
  height: 72px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  flex-shrink: 0;
}

.custom-modal-title {
  font-weight: 700;
  margin: 0 0 0.2rem;
  font-size: 1.1rem;
}

.custom-modal-baseprice {
  margin: 0;
  font-size: 0.85rem;
  color: var(--gray-600);
}

.custom-section {
  margin-bottom: 1.2rem;
}

.custom-section-title {
  font-weight: 700;
  font-size: 0.9rem;
  margin-bottom: 0.6rem;
  color: var(--dark);
}

.custom-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0.7rem 1rem;
  border: 2px solid var(--gray-200);
  border-radius: var(--radius-sm);
  margin-bottom: 6px;
  cursor: pointer;
  transition: all 0.2s;
}

.custom-option:hover {
  border-color: var(--primary);
  background: var(--primary-light);
}

.custom-option.selected {
  border-color: var(--primary);
  background: var(--primary-light);
}

.custom-option input {
  display: none;
}

.custom-option-label {
  flex: 1;
  font-weight: 500;
  font-size: 0.9rem;
}

.custom-option-price {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--primary);
}

.custom-modal-footer {
  border-top: 1px solid var(--gray-200);
  padding: 1rem 0 0;
  margin-top: 0.5rem;
}

.custom-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.8rem;
  font-weight: 700;
  font-size: 1.1rem;
}

.custom-total-price {
  color: var(--primary);
  font-size: 1.2rem;
}

.btn-custom-add {
  width: 100%;
  padding: 0.9rem;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 60px;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-custom-add:hover {
  background: var(--primary-dark);
  transform: scale(1.01);
}

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

/* ===================== BUILD BOX MODAL ===================== */
.box-modal {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  max-width: 560px;
  margin: 0 auto;
  background: white;
  border-radius: 20px 20px 0 0;
  z-index: 1070;
  transform: translateY(100%);
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 -4px 30px rgba(0,0,0,0.15);
}

.box-modal.open {
  transform: translateY(0);
}

.box-modal-header {
  padding: 1.5rem 1.5rem 0.5rem;
  flex-shrink: 0;
}

.box-modal-top {
  display: flex;
  gap: 14px;
  align-items: center;
  padding-right: 30px;
}

.box-modal-img {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  flex-shrink: 0;
}

.box-modal-title {
  font-weight: 700;
  margin: 0 0 0.15rem;
  font-size: 1.1rem;
}

.box-modal-desc {
  margin: 0;
  font-size: 0.8rem;
  color: var(--gray-600);
}

.box-modal-body {
  flex: 1;
  overflow-y: auto;
  padding: 0.5rem 1.5rem;
}

.box-section {
  margin-bottom: 1.2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--gray-200);
}

.box-section:last-child {
  border-bottom: none;
}

.box-section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.6rem;
}

.box-section-title {
  font-weight: 700;
  font-size: 0.9rem;
  margin: 0;
}

.box-section-counter {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--gray-600);
  background: var(--gray-100);
  padding: 2px 10px;
  border-radius: 20px;
}

.box-section-counter.complete {
  background: var(--primary-light);
  color: var(--primary-dark);
}

.box-options {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.box-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0.6rem 0.8rem;
  border: 2px solid var(--gray-200);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s;
}

.box-option:hover {
  border-color: var(--primary);
  background: var(--primary-light);
}

.box-option.selected {
  border-color: var(--primary);
  background: var(--primary-light);
}

.box-option-img {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
}

.box-option-info {
  flex: 1;
  min-width: 0;
}

.box-option-name {
  display: block;
  font-weight: 600;
  font-size: 0.85rem;
}

.box-option-price {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--primary);
}

.box-option-qty {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 700;
  background: var(--primary);
  color: white;
  padding: 1px 7px;
  border-radius: 10px;
  margin-top: 2px;
}

.box-option-check {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 2px solid var(--gray-200);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
  color: transparent;
  transition: all 0.2s;
  flex-shrink: 0;
}

.box-option.selected .box-option-check {
  background: var(--primary);
  border-color: var(--primary);
  color: white;
}

.box-modal-footer {
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--gray-200);
  flex-shrink: 0;
  background: white;
}

.box-footer-row {
  display: flex;
  align-items: center;
  gap: 16px;
}

.box-total {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--gray-600);
  white-space: nowrap;
}

.box-total-price {
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--primary);
}

.box-footer-row .btn-custom-add {
  flex: 1;
}

.box-card {
  cursor: pointer;
  transition: all 0.3s;
}

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

.box-card .btn-add-cart {
  cursor: pointer;
  pointer-events: none;
}

/* ===================== FOOTER ===================== */
.site-footer {
  background: #1c1c1e;
  color: rgba(255,255,255,0.8);
  padding: 3rem 0 0;
  margin-top: 3rem;
  font-size: 0.9rem;
  border-radius: 40px 40px 0 0;
}

.footer-brand {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 0.5rem;
}

.footer-desc {
  opacity: 0.7;
  line-height: 1.5;
  max-width: 260px;
}

.footer-heading {
  font-weight: 700;
  color: white;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.8rem;
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 0.4rem;
}

.footer-links a,
.footer-links span {
  color: rgba(255,255,255,0.65);
  text-decoration: none;
  transition: color 0.2s;
}

.footer-links a {
  cursor: pointer;
}

.footer-links span {
  cursor: default;
}

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

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 0;
  margin-top: 2rem;
  border-top: 1px solid rgba(255,255,255,0.1);
  font-size: 0.8rem;
  opacity: 0.6;
}

.footer-social {
  display: flex;
  gap: 12px;
}

.footer-social a {
  font-size: 1.2rem;
  text-decoration: none;
  opacity: 0.7;
  transition: opacity 0.2s;
}

.footer-social a:hover {
  opacity: 1;
}

@media (max-width: 767.98px) {
  .site-footer .row {
    text-align: center;
  }

  .site-footer .col-6 {
    flex: 0 0 50%;
    max-width: 50%;
  }

  .site-footer .col-md-4 {
    flex: 0 0 100%;
    max-width: 100%;
  }

  .footer-desc {
    max-width: 100%;
    margin: 0 auto;
  }

  .footer-links {
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 10px;
    text-align: center;
  }

  .footer-brand {
    text-align: center;
  }
}

/* ===================== SCROLL TO TOP ===================== */
.scroll-top-btn {
  position: fixed;
  bottom: 80px;
  right: 20px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: none;
  background: var(--primary);
  color: white;
  font-size: 1.3rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(0,0,0,0.2);
  z-index: 1030;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.scroll-top-btn.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.scroll-top-btn:hover {
  background: var(--primary-dark);
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0,0,0,0.25);
}

@media (max-width: 576px) {
  .scroll-top-btn {
    width: 38px;
    height: 38px;
    font-size: 1.1rem;
    bottom: 70px;
    right: 14px;
  }
}

/* ===================== CHECKOUT PAGE ===================== */
.checkout-hero {
  background: #1c1c1e;
  color: white;
  padding: 3rem 0 2.5rem;
  margin-top: -70px;
  padding-top: calc(70px + 2rem);
  text-align: center;
  border-radius: 0 0 40px 40px;
}
.checkout-hero h1 { font-weight: 800; font-size: 2rem; margin-bottom: 0.3rem; }
.checkout-hero p { opacity: 0.9; margin-bottom: 0; font-size: 0.95rem; }

.checkout-section {
  padding: 2.5rem 0;
}

.checkout-card {
  background: white;
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow);
  margin-bottom: 1rem;
}

.checkout-card-title {
  font-weight: 700;
  font-size: 1.05rem;
  margin-bottom: 1.2rem;
  padding-bottom: 0.6rem;
  border-bottom: 2px solid var(--primary-light);
}

.checkout-label {
  display: block;
  font-weight: 600;
  font-size: 0.8rem;
  color: var(--gray-600);
  margin-bottom: 0.3rem;
}

.checkout-input {
  width: 100%;
  padding: 0.7rem 0.9rem;
  border: 2px solid var(--gray-200);
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  transition: border-color 0.2s;
  background: white;
}

.checkout-input:focus {
  outline: none;
  border-color: var(--primary);
}

.checkout-textarea {
  resize: vertical;
  min-height: 60px;
}

.payment-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.payment-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0.8rem 1rem;
  border: 2px solid var(--gray-200);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s;
}

.payment-option:hover {
  border-color: var(--primary);
  background: var(--primary-light);
}

.payment-option.selected {
  border-color: var(--primary);
  background: var(--primary-light);
}

.payment-option input { display: none; }

.payment-option-icon { font-size: 1.3rem; }

.payment-option-label {
  font-weight: 600;
  font-size: 0.9rem;
}

/* Order summary sidebar */
.checkout-summary {
  background: white;
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow);
  position: sticky;
  top: 90px;
}

.checkout-store-group {
  margin-bottom: 1rem;
}

.checkout-store-name {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--primary);
  margin-bottom: 0.5rem;
  padding-bottom: 0.3rem;
  border-bottom: 1px solid var(--gray-200);
}

.checkout-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--gray-100);
}

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

.checkout-item-img {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
}

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

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

.checkout-item-extras {
  font-size: 0.7rem;
  color: var(--gray-600);
  line-height: 1.3;
}

.checkout-item-qty {
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--gray-600);
  flex-shrink: 0;
}

.checkout-item-price {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--dark);
  flex-shrink: 0;
  min-width: 55px;
  text-align: right;
}

.checkout-item-qty-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 2px;
}

.checkout-qty-label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--gray-600);
}

.checkout-item-total {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--primary);
}

.checkout-divider {
  height: 1px;
  background: var(--gray-200);
  margin: 0.8rem 0;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
  color: var(--gray-600);
  margin-bottom: 0.4rem;
}

.summary-total {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--dark);
}

.btn-back-store {
  display: block;
  text-align: center;
  margin-top: 0.8rem;
  font-size: 0.85rem;
  color: var(--gray-600);
  text-decoration: none;
  transition: color 0.2s;
}

.btn-back-store:hover {
  color: var(--primary);
}

.checkout-empty {
  display: none;
  text-align: center;
  padding: 4rem 1rem;
}

.checkout-section.checkout-empty-active {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 70px - 200px);
}

.checkout-section.checkout-empty-active > .container {
  width: 100%;
}

.checkout-section.checkout-empty-active .checkout-empty {
  width: 100%;
}

@media (max-width: 992px) {
  .checkout-summary {
    position: static;
  }
}

/* ===================== LOGIN MODAL ===================== */
.login-modal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.9);
  width: 400px;
  max-width: 90vw;
  background: white;
  border-radius: var(--radius);
  z-index: 1070;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 10px 40px rgba(0,0,0,0.2);
}

.login-modal.open {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, -50%) scale(1);
}

@media (min-width: 992px) {
  #logoutMobileItem {
    display: none !important;
  }
}

.login-modal-body {
  padding: 2rem;
  text-align: center;
}

.login-icon {
  font-size: 3rem;
  margin-bottom: 0.5rem;
}

.login-title {
  font-weight: 700;
  font-size: 1.3rem;
  margin-bottom: 0.3rem;
}

.login-subtitle {
  font-size: 0.85rem;
  color: var(--gray-600);
  margin-bottom: 1.5rem;
}

.login-form {
  text-align: left;
}

.login-hint {
  font-size: 0.75rem;
  color: var(--gray-600);
  text-align: center;
}

.login-register-link {
  text-align: center;
  font-size: 0.78rem;
  color: var(--gray-600);
  margin-top: 0.8rem;
}

.login-register-link a {
  color: var(--gray-600);
  text-decoration: underline;
  transition: color 0.2s;
}

.login-register-link a:hover {
  color: var(--dark);
}

/* ===================== USER MENU ===================== */
.btn-login {
  background: transparent;
  border: 2px solid var(--gray-200);
  border-radius: 50px !important;
  padding: 0.5rem 1.2rem !important;
  font-weight: 600 !important;
  font-size: 0.9rem;
  color: var(--gray-800);
  transition: all 0.2s;
  cursor: pointer;
  white-space: nowrap;
}

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

.user-menu {
  position: relative;
}

.btn-user {
  background: var(--primary-light);
  border: 2px solid var(--primary);
  border-radius: 50px;
  padding: 0.3rem 0.8rem 0.3rem 0.3rem;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--primary-dark);
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.btn-user:hover {
  background: var(--primary);
  color: white;
}

.user-avatar {
  font-size: 1.1rem;
}

.user-arrow {
  font-size: 0.6rem;
  transition: transform 0.2s;
}

.user-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  background: white;
  border-radius: var(--radius-sm);
  box-shadow: 0 4px 20px rgba(0,0,0,0.12);
  min-width: 180px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: all 0.2s;
  z-index: 1060;
  overflow: hidden;
}

.user-dropdown.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.user-dropdown a {
  display: block;
  padding: 0.7rem 1rem;
  text-decoration: none;
  color: var(--dark);
  font-size: 0.85rem;
  font-weight: 500;
  transition: background 0.2s;
}

.user-dropdown a:hover {
  background: var(--primary-light);
  color: var(--primary-dark);
}

/* ===================== PROFILE PAGE ===================== */
.profile-hero {
  background: #1c1c1e;
  color: white;
  padding: 3rem 0 2.5rem;
  margin-top: -70px;
  padding-top: calc(70px + 2rem);
  text-align: center;
  border-radius: 0 0 40px 40px;
}

.profile-hero h1 { font-weight: 800; font-size: 2rem; margin-bottom: 0.3rem; }
.profile-hero p { opacity: 0.9; margin-bottom: 0; font-size: 0.95rem; }

.profile-section {
  padding: 2.5rem 0;
  max-width: 1100px;
  margin: 0 auto;
}

.profile-sidebar {
  background: white;
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow);
  position: sticky;
  top: 90px;
}

@media (max-width: 991.98px) {
  .profile-sidebar {
    position: static;
  }
}

.profile-not-logged {
  text-align: center;
  padding: 3rem 0;
}

.order-card {
  background: white;
  border-radius: var(--radius) !important;
  box-shadow: var(--shadow);
  margin-bottom: 0.6rem;
  overflow: hidden;
  border: 1px solid var(--gray-200) !important;
}

.order-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.8rem 1.2rem;
  border-bottom: 1px solid var(--gray-200);
  background: var(--gray-100);
}

.order-store {
  font-size: 0.85rem;
  color: var(--gray-600);
  margin-left: 6px;
}

.order-info {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  color: var(--gray-600);
  margin-bottom: 0.3rem;
}

.order-info span {
  flex-shrink: 0;
}

.order-status-pending {
  background: #e2e3e5;
  color: #383d41;
}

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

.order-status-on-the-way {
  background: #cce5ff;
  color: #004085;
}

.order-status-delivered {
  background: #d4edda;
  color: #155724;
}

.order-status-cancelled {
  background: #f8d7da;
  color: #721c24;
}

.order-card .accordion-button {
  padding: 0.6rem 1rem;
  background: white;
  box-shadow: none !important;
  border-radius: var(--radius) !important;
  display: flex;
  align-items: center;
}

.order-card .accordion-button:not(.collapsed) {
  background: white;
  color: var(--dark);
  border-radius: var(--radius) var(--radius) 0 0 !important;
}

.order-card .accordion-button:hover {
  background: var(--primary-light);
}

.order-card .accordion-button::after {
  margin-left: auto;
  flex-shrink: 0;
  background-size: 12px;
  width: 12px;
  height: 12px;
  transition: transform 0.2s ease;
}

.order-card .accordion-collapse {
  border-radius: 0 0 var(--radius) var(--radius);
}

.order-acc-header {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  flex-wrap: wrap;
}

.order-acc-header .order-id {
  flex-shrink: 0;
}

.order-acc-store {
  font-weight: 600;
  font-size: 0.8rem;
  color: var(--primary-dark);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
  min-width: 80px;
}

.order-acc-header .order-date {
  flex-shrink: 0;
}

.order-acc-header .order-status {
  flex-shrink: 0;
}

.order-acc-total {
  font-weight: 700;
  color: var(--dark);
  font-size: 0.85rem;
  flex-shrink: 0;
  margin-left: auto;
  margin-right: 8px;
}

.order-id {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--dark);
}

.order-date {
  font-size: 0.75rem;
  color: var(--gray-600);
}

.order-card-body {
  padding: 0.8rem 1.2rem 1rem;
}

.order-status {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 20px;
  white-space: nowrap;
}

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

.status-on-the-way {
  background: #cce5ff;
  color: #004085;
}

.status-delivered {
  background: #d4edda;
  color: #155724;
}

.order-card-body {
  padding: 0.8rem 1.2rem 1rem;
}

.order-items {
  margin-bottom: 0.5rem;
}

.order-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0.3rem 0;
  font-size: 0.85rem;
}

.order-item-name {
  flex: 1;
  font-weight: 500;
}

.order-item-qty {
  color: var(--gray-600);
  font-weight: 600;
  min-width: 30px;
  text-align: center;
}

.order-item-price {
  font-weight: 600;
  min-width: 55px;
  text-align: right;
}

.order-total-row {
  display: flex;
  justify-content: space-between;
  padding-top: 0.5rem;
  border-top: 1px solid var(--gray-200);
  font-weight: 700;
  font-size: 0.95rem;
}

.order-total-price {
  color: var(--primary);
}

/* ===================== ORDER DETAILS MODAL ===================== */
.order-modal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.9);
  width: 520px;
  max-width: 95vw;
  max-height: 85vh;
  background: white;
  border-radius: var(--radius);
  z-index: 1070;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 10px 40px rgba(0,0,0,0.2);
  display: flex;
  flex-direction: column;
}

.order-modal.open {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, -50%) scale(1);
}

.order-modal-body {
  padding: 1.5rem;
  overflow-y: auto;
  flex: 1;
}

.order-modal-top {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 1rem;
}

.order-modal-top .order-modal-title {
  margin-right: auto;
}

.order-modal-close {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: none;
  background: var(--gray-100);
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.2s;
}

.order-modal-close:hover {
  background: var(--gray-200);
}

.order-modal-title {
  font-weight: 700;
  font-size: 1.1rem;
  margin: 0;
}

.order-modal-info {
  background: var(--gray-100);
  border-radius: var(--radius-sm);
  padding: 0.8rem 1rem;
  margin-bottom: 1rem;
}

.info-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.83rem;
  padding: 0.3rem 0;
}

.info-row span:first-child {
  color: var(--gray-600);
  font-weight: 500;
}

.info-row span:last-child {
  font-weight: 600;
  text-align: right;
}

.order-modal-subtitle {
  font-weight: 700;
  font-size: 0.9rem;
  margin-bottom: 0.6rem;
}

.order-modal-items {
  margin-bottom: 0.5rem;
}

@media (max-width: 576px) {
  .order-modal {
    top: auto;
    bottom: 0;
    left: 0;
    right: 0;
    transform: translateY(100%);
    width: 100vw;
    max-width: 100vw;
    max-height: 85vh;
    border-radius: 20px 20px 0 0;
    box-shadow: 0 -4px 30px rgba(0,0,0,0.15);
  }

  .order-modal.open {
    transform: translateY(0);
  }
}

/* ===================== RESPONSIVE ===================== */
@media (max-width: 768px) {
  .hero-section h1 {
    font-size: 1.8rem;
  }

  .store-card-img {
    height: 140px;
  }

  .store-hero {
    height: 200px;
  }

  .store-hero-overlay h1 {
    font-size: 1.5rem;
  }

  .cart-sidebar {
    width: 100vw;
  }

  .floating-cart-bar {
    width: 60%;
    justify-content: space-between;
    padding: 0.5rem 1rem;
    gap: 10px;
    border-radius: 40px;
  }

  .floating-cart-bar .cart-bar-total {
    font-size: 0.85rem;
    min-width: 40px;
  }

  .floating-cart-bar .cart-bar-icon {
    font-size: 1.1rem;
  }

  .product-card-img {
    height: 130px;
  }
}

@media (max-width: 576px) {
  .hero-section {
    padding: 2rem 0 3rem;
    padding-top: calc(70px + 2rem);
  }

  .hero-section h1 {
    font-size: 1.5rem;
  }

  .navbar-glovo .navbar-brand {
    font-size: 1.3rem;
  }
}
