/* Import Noto Sans and Noto Sans Bengali fonts */
@import url("https://fonts.googleapis.com/css2?family=Noto+Sans:wght@400;500;600;700&family=Noto+Sans+Bengali:wght@400;500;600;700&display=swap");

/* Custom styles for Fresh Grocery */

body {
  font-family: "PT Sans", sans-serif;
}

.navbar-brand {
  padding-top: 0;
}

.navbar {
  transition: all 0.3s ease;
  background: transparent;
}

.sticky-nav {
  background: rgba(255, 255, 255, 0.5) !important;
  backdrop-filter: blur(15px) !important;
  -webkit-backdrop-filter: blur(15px) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

[data-bs-theme="dark"] .sticky-nav {
  background: rgba(33, 37, 41, 0.5) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

/* Hero Section */
.hero-section {
  background-color: var(--bs-light-bg-subtle);
  padding: 4rem 0;
}

.index-hero-search.search-box .form-control {
  border-radius: 25px 0 0 25px;
  padding-left: 1.5rem;
}

.index-hero-search.search-box .btn {
  border-radius: 0 25px 25px 0;
  padding-right: 1.5rem;
}

.shop-search {
  top: 82px;
  z-index: 999;
}

/* Mobile shop-search */
@media screen and (max-width: 767.98px) {
  .shop-search {
    top: 56px;
  }
  
}

/* Categories Section */
.category-card {
  transition: transform 0.3s ease;
  cursor: pointer;
}

.category-card:hover {
  transform: translateY(-5px);
}

.category-name {
  font-size: 1rem;
  margin-bottom: 0;
  color: var(--bs-secondary);
}

/* Categories Section Styles */
.categories-scroll {
  position: relative;
}

.categories-scroll .row::-webkit-scrollbar {
  display: none;
}

.category-card {
  transition: transform 0.2s ease;
  cursor: pointer;
}

.category-card:hover {
  transform: translateY(-2px);
}

.category-name {
  font-size: 0.875rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Make sure horizontal scroll works on touch devices */
.categories-scroll .row {
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
}

/* Product Cards */
.product-card {
  border: none;
  box-shadow: 0 2px 10px var(--bs-border-color-translucent);
  transition: transform 0.3s ease;
  height: 100%;
}

.product-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 4px 8px var(--bs-border-color-translucent);
}

/* Product title with Bengali support */
.product-title {
  font-family: "Noto Sans", "Noto Sans Bengali", sans-serif;
  font-weight: 500;
}

.product-image {
  height: 200px;
  object-fit: cover;
}

.product-image-wrapper {
  position: relative;
  padding-top: 75%;
  overflow: hidden;
}

.product-image-wrapper img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.current-price {
  color: var(--bs-success);
  font-size: 1.25rem;
}

.original-price {
  font-size: 0.875rem;
}

.quantity-control {
  max-width: 120px;
}

.quantity-control input {
  text-align: center;
}

/* Special Offers */
.offer-card {
  height: 100%;
  transition: transform 0.3s ease;
}

.offer-card:hover {
  transform: translateY(-5px);
}

/* Features Section */
.feature-card {
  height: 100%;
  transition: transform 0.3s ease;
}

.feature-card:hover {
  transform: translateY(-5px);
}

.feature-card i {
  color: var(--bs-success);
}

/* App Download Section */
.app-download {
  background: linear-gradient(
    135deg,
    var(--bs-success) 0%,
    var(--bs-success-dark) 100%
  );
  color: var(--bs-white);
  padding: 4rem 0;
}

.app-buttons .btn {
  padding: 0.75rem 1.5rem;
  margin-top: 1rem;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
  .hero-section {
    padding: 2rem 0;
  }

  .product-card {
    margin-bottom: 1rem;
  }
}

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1.5;
}

/* Cart Badge */
.cart-count {
  position: absolute;
  top: -8px;
  right: -8px;
  background-color: var(--bs-success);
  color: var(--bs-white);
  border-radius: 50%;
  width: 20px;
  height: 20px;
  font-size: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

/* Loading States */
.loading {
  opacity: 0.7;
  pointer-events: none;
}

/* Toast Notifications */
.toast-container {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 1060;
}

/* Category badges */
.category-badge {
  background-color: var(--bs-success);
  color: var(--bs-white);
  padding: 0.25rem 0.5rem;
  border-radius: 0.25rem;
}

/* Cart button animation */
.add-to-cart:active {
  transform: scale(0.95);
}

/* Custom form controls */
.form-control:focus {
  border-color: var(--bs-primary);
  box-shadow: 0 0 0 0.2rem var(--bs-primary-rgb);
}

/* Product quantity input */
.quantity-input {
  max-width: 80px;
  border-color: var(--bs-primary)
}

/* Order status badges */
.status-pending {
  background-color: var(--bs-warning);
}
.status-processing {
  background-color: var(--bs-info);
}
.status-shipped {
  background-color: var(--bs-primary);
}
.status-delivered {
  background-color: var(--bs-success);
}
.status-cancelled {
  background-color: var(--bs-danger);
}

/* Responsive images in product details */
.product-detail-image {
  max-height: 400px;
  object-fit: contain;
}

/* Category sidebar */
.category-sidebar {
  position: sticky;
  top: 20px;
  max-height: calc(100vh - 40px);
  overflow-y: auto;
}

/* Custom scrollbar for sidebar */
.category-sidebar::-webkit-scrollbar {
  width: 5px;
}

.category-sidebar::-webkit-scrollbar-thumb {
  background-color: var(--bs-success);
  border-radius: 5px;
}

/* Theme toggle custom styling */
.theme-toggle-wrapper {
  position: relative;
}

.theme-toggle-input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}

.theme-toggle-label {
  cursor: pointer;
  width: 50px;
  height: 26px;
  background: var(--bs-secondary-bg);
  display: block;
  border-radius: 100px;
  position: relative;
  transition: background-color 0.3s;
}

.theme-toggle-label::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  transition: 0.3s;
}

.theme-toggle-input:checked + .theme-toggle-label {
  background: var(--bs-secondary);
  transition: background-color 0.3s;
}

.theme-toggle-input:checked + .theme-toggle-label::after {
  left: calc(100% - 23px);
}

#theme-icon {
  position: absolute;
  top: 50%;
  left: 6px;
  transform: translateY(-50%);
  z-index: 1;
  transition: 0.3s;
  color: var(--bs-success);
}

.theme-toggle-input:checked ~ label #theme-icon {
  color: var(--bs-white);
  transform: translateY(-50%) translateX(24px);
}

/* Remove old theme toggle styles */
.form-check-input[type="checkbox"],
.form-check-input:checked,
.form-check-label {
  display: none;
}

/* Theme-specific logo handling */
.theme-logo {
  display: none;
}

[data-bs-theme="light"] .light-logo {
  display: block;
}

[data-bs-theme="dark"] .dark-logo {
  display: block;
}

/* Bengali text specific styles */
.bn-text {
  font-family: "Noto Sans Bengali", sans-serif;
}

#get-location {
  border: 1px solid #fff;
}

/* Custom input type [number] */
/* Chrome, Safari, Edge, Opera */
input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

/* Firefox */
input[type="number"] {
  appearance: textfield;
  -moz-appearance: textfield;
}

.navbar-nav .nav-link.active, .navbar-nav .nav-link.show {
  color: var(--bs-navbar-active-color) !important;
  border-bottom: 1px solid #fff;
}

@media (max-width: 767.98px) {
  .marquee {
    white-space: nowrap;
    overflow: hidden;
    box-sizing: border-box;
  }

  .marquee-content {
    display: inline-block;
    padding-left: 100%;
    animation: marquee 30s linear infinite;
  }

  @keyframes marquee {
    0%   { transform: translateX(0%); }
    100% { transform: translateX(-100%); }
  }

  .service-area-notice {
    top: 0 !important;
  }
}

.alert-info.service-area-notice {
  border: none;
}

.alert.service-area-notice {
  border-radius: 0;
  margin-bottom: 0;
  padding: 0.5rem 0.5rem;
}


.drawer-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1050;
  display: flex;
  justify-content: flex-end;
}

[data-bs-theme="dark"] .drawer-overlay {
  background: rgba(0, 0, 0, 0.8);
}

.drawer-content {
  background: #fff;
  width: 300px;
  height: 100%;
  padding: 20px;
  box-shadow: -2px 0 5px rgba(0, 0, 0, 0.2);
}

[data-bs-theme="dark"] .drawer-content {
  background: #212529;
  color: #f8f9fa;
}

.drawer-header {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  margin-bottom: 20px;
}

.drawer-header .btn-close {
  align-self: flex-end;
}

.drawer-header .user-info {
  display: flex;
  align-items: center;
  margin-top: 10px;
  width: 100%;
}

.drawer-header .user-info .rounded-circle {
  background-color: #f8f9fa;
  border: 1px solid #dee2e6;
}

.drawer-menu {
  list-style: none;
  padding: 0;
}

.drawer-menu li {
  margin-bottom: 10px;
}

.drawer-menu a {
  text-decoration: none;
  color: #000;
}

[data-bs-theme="dark"] .drawer-menu a {
  color: #f8f9fa;
}