/* ==========================================================================
   MARUTI TEXTILES - COMPONENTS STYLESHEET
   Mobile Bottom Bar, Drawers, Modals, Quick View, Cart, Currency
   ========================================================================== */

/* ================== MOBILE STICKY BOTTOM BAR (SAREEKA REPLICA) ================== */
.mobile-bottom-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--bottom-bar-height);
  background-color: #ffffff;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-around;
  z-index: 990;
  box-shadow: 0 -3px 12px rgba(0, 0, 0, 0.08);
}

@media (min-width: 992px) {
  .mobile-bottom-bar {
    display: none; /* Only show on mobile/tablet view */
  }
}

.bottom-bar-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  flex: 1;
  height: 100%;
  color: var(--text-secondary);
  font-size: 0.68rem;
  font-weight: 600;
  position: relative;
  transition: all var(--transition-fast);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.bottom-bar-item.active {
  color: var(--brand-red);
}

.bottom-bar-item svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform var(--transition-fast);
}

.bottom-bar-item:active svg {
  transform: scale(0.9);
}

/* Center Highlighted Currency Button (As circled in user's Sareeka screenshot) */
.bottom-bar-item.currency-highlight-item {
  position: relative;
}

.bottom-currency-circle {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #ffffff;
  border: 3px solid #25d366; /* Bright vibrant green ring as circled in screenshot */
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  box-shadow: 0 4px 14px rgba(37, 211, 102, 0.45);
  margin-top: -12px; /* Slightly elevated circular pill */
  transition: all var(--transition-fast);
}

.bottom-bar-item.currency-highlight-item:hover .bottom-currency-circle {
  transform: scale(1.08);
}

.bottom-currency-circle .flag-emoji {
  line-height: 1;
  font-size: 1.45rem;
}

.currency-label {
  font-weight: 700;
  color: #0b1f3a;
  font-size: 0.68rem;
  margin-top: 2px;
}

/* Badge for wishlist / cart in bottom bar */
.bottom-bar-badge {
  position: absolute;
  top: -6px;
  right: -10px;
  background-color: #e50914;
  color: #ffffff;
  font-size: 0.62rem;
  font-weight: 700;
  min-width: 16px;
  height: 16px;
  border-radius: 99px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 3px;
  border: 1.5px solid #fff;
}

/* ================== BACKDROP & MODAL OVERLAYS ================== */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background-color: rgba(7, 21, 42, 0.6);
  backdrop-filter: blur(4px);
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity var(--transition-normal), visibility var(--transition-normal);
}

.modal-backdrop.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* ================== SLIDE-OVER DRAWER (CART / WISHLIST / MOBILE MENU) ================== */
.slide-drawer {
  position: fixed;
  top: 0;
  bottom: 0;
  width: 100%;
  max-width: 440px;
  background-color: #ffffff;
  z-index: 1050;
  box-shadow: var(--shadow-xl);
  display: flex;
  flex-direction: column;
  transition: transform var(--transition-normal);
}

.slide-drawer.drawer-right {
  right: 0;
  transform: translateX(100%);
}

.slide-drawer.drawer-left {
  left: 0;
  transform: translateX(-100%);
}

.slide-drawer.active {
  transform: translateX(0);
}

/* Drawer Header */
.drawer-header {
  padding: 1.15rem 1.25rem;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: #ffffff;
}

.drawer-title-box {
  display: flex;
  align-items: center;
  gap: 10px;
}

.drawer-title-box h3 {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  color: var(--primary-navy);
}

.drawer-count-badge {
  background-color: var(--brand-red-light);
  color: var(--brand-red);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-full);
}

.drawer-close-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background-color: var(--bg-surface);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  transition: all var(--transition-fast);
}

.drawer-close-btn:hover {
  background-color: var(--brand-red);
  color: #ffffff;
}

/* Drawer Body */
.drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
}

/* Empty State */
.drawer-empty-state {
  margin: auto;
  text-align: center;
  padding: 2rem 1rem;
}

.drawer-empty-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background-color: var(--bg-surface);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.25rem auto;
}

.drawer-empty-icon svg {
  width: 36px;
  height: 36px;
}

.drawer-empty-state h4 {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  color: var(--primary-navy);
  margin-bottom: 0.5rem;
}

.drawer-empty-state p {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.btn-start-shopping {
  padding: 0.75rem 1.75rem;
  background-color: var(--primary-navy);
  color: #ffffff;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 0.85rem;
  transition: background-color var(--transition-fast);
}

.btn-start-shopping:hover {
  background-color: var(--brand-red);
}

/* Free Shipping Meter */
.free-shipping-meter-box {
  background: linear-gradient(135deg, #fdfbf7 0%, #faecd3 100%);
  border: 1px solid rgba(201, 152, 57, 0.3);
  border-radius: var(--radius-md);
  padding: 0.85rem 1rem;
  margin-bottom: 1.25rem;
}

.shipping-meter-msg {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--primary-navy);
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.shipping-meter-msg .highlight {
  color: var(--brand-red);
  font-weight: 700;
}

.shipping-progress-track {
  width: 100%;
  height: 6px;
  background-color: rgba(15, 39, 74, 0.1);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.shipping-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--brand-gold) 0%, var(--brand-red) 100%);
  border-radius: var(--radius-full);
  transition: width 0.4s ease;
}

/* Cart Items List */
.cart-items-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.cart-item-card {
  display: flex;
  gap: 12px;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-subtle);
  position: relative;
}

.cart-item-thumb {
  width: 78px;
  height: 98px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background-color: var(--bg-surface);
  flex-shrink: 0;
}

.cart-item-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cart-item-content {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.cart-item-name {
  font-family: var(--font-serif);
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--primary-navy);
  line-height: 1.3;
  margin-bottom: 4px;
}

.cart-item-meta {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.cart-item-price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
}

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

.cart-item-stepper {
  display: flex;
  align-items: center;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xs);
  background-color: var(--bg-surface);
}

.cart-item-stepper button {
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-main);
  font-size: 0.85rem;
  font-weight: 700;
}

.cart-item-stepper button:hover {
  background-color: #ffffff;
  color: var(--brand-red);
}

.cart-item-stepper span {
  width: 28px;
  text-align: center;
  font-size: 0.82rem;
  font-weight: 600;
}

.cart-item-remove-btn {
  color: var(--text-muted);
  font-size: 0.75rem;
  display: flex;
  align-items: center;
  gap: 3px;
  margin-top: 6px;
  transition: color var(--transition-fast);
}

.cart-item-remove-btn:hover {
  color: var(--brand-red);
}

/* Coupon Box */
.coupon-input-box {
  display: flex;
  gap: 8px;
  margin-bottom: 1.25rem;
}

.coupon-input-box input {
  flex: 1;
  padding: 0.65rem 0.85rem;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  background-color: var(--bg-surface);
  font-size: 0.82rem;
  text-transform: uppercase;
}

.coupon-input-box button {
  padding: 0.65rem 1.15rem;
  background-color: var(--primary-navy);
  color: #ffffff;
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
  font-weight: 700;
  transition: background-color var(--transition-fast);
}

.coupon-input-box button:hover {
  background-color: var(--brand-red);
}

.applied-coupon-pill {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: #e8fbf0;
  border: 1px solid #b7f0cb;
  color: #0b6938;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 0.78rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.applied-coupon-pill button {
  color: var(--brand-red);
  font-weight: 700;
}

/* Drawer Footer (Summary & Action Buttons) */
.drawer-footer {
  padding: 1.25rem;
  border-top: 1px solid var(--border-subtle);
  background-color: #ffffff;
}

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

.summary-row.total-row {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--primary-navy);
  padding-top: 0.5rem;
  border-top: 1px dashed var(--border-subtle);
  margin-bottom: 1.25rem;
}

.summary-row.total-row .total-amount {
  color: var(--brand-red);
}

.drawer-actions-stack {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.btn-whatsapp-order {
  width: 100%;
  padding: 0.85rem;
  border-radius: var(--radius-sm);
  background-color: var(--whatsapp-green);
  color: #ffffff;
  font-weight: 700;
  font-size: 0.88rem;
  letter-spacing: 0.4px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 4px 12px rgba(37, 211, 102, 0.3);
  transition: all var(--transition-fast);
}

.btn-whatsapp-order:hover {
  background-color: var(--whatsapp-hover);
  transform: translateY(-2px);
}

.btn-checkout-primary {
  width: 100%;
  padding: 0.85rem;
  border-radius: var(--radius-sm);
  background-color: var(--primary-navy);
  color: #ffffff;
  font-weight: 700;
  font-size: 0.88rem;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: background-color var(--transition-fast);
}

.btn-checkout-primary:hover {
  background-color: var(--brand-red);
}

/* ================== CURRENCY SWITCHER MODAL ================== */
.currency-modal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.95);
  width: 90%;
  max-width: 460px;
  background-color: #ffffff;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  z-index: 1060;
  padding: 1.5rem;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-normal);
}

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

.currency-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border-subtle);
}

.currency-modal-header h3 {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  color: var(--primary-navy);
}

.currency-options-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  max-height: 380px;
  overflow-y: auto;
  padding: 2px;
}

.currency-option-card {
  padding: 0.85rem;
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  background-color: var(--bg-surface);
  transition: all var(--transition-fast);
}

.currency-option-card:hover {
  border-color: var(--brand-gold);
  background-color: #ffffff;
  transform: translateY(-2px);
}

.currency-option-card.active {
  border-color: var(--brand-red);
  background-color: var(--brand-red-light);
}

.currency-flag-box {
  font-size: 1.6rem;
  line-height: 1;
}

.currency-info-box {
  display: flex;
  flex-direction: column;
}

.currency-code-text {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--primary-navy);
}

.currency-name-text {
  font-size: 0.7rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100px;
}

/* ================== QUICK VIEW PRODUCT MODAL ================== */
.quick-view-modal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.95);
  width: 95%;
  max-width: 860px;
  max-height: 90vh;
  background-color: #ffffff;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  z-index: 1060;
  overflow-y: auto;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-normal);
}

.quick-view-modal.active {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, -50%) scale(1);
}

.quick-view-close-btn {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.95);
  box-shadow: var(--shadow-sm);
  color: var(--primary-navy);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  z-index: 10;
  transition: all var(--transition-fast);
}

.quick-view-close-btn:hover {
  background-color: var(--brand-red);
  color: #ffffff;
}

.quick-view-grid {
  display: grid;
  grid-template-columns: 1fr;
}

@media (min-width: 768px) {
  .quick-view-grid {
    grid-template-columns: 1fr 1.15fr;
  }
}

.quick-view-gallery {
  position: relative;
  background-color: var(--bg-surface);
}

.quick-view-main-image {
  width: 100%;
  height: 380px;
  overflow: hidden;
}

@media (min-width: 768px) {
  .quick-view-main-image {
    height: 100%;
    min-height: 480px;
  }
}

.quick-view-main-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.quick-view-details {
  padding: 2rem 1.5rem;
  display: flex;
  flex-direction: column;
}

@media (min-width: 768px) {
  .quick-view-details {
    padding: 2.5rem 2rem;
  }
}

.quick-view-cat {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--brand-red);
  margin-bottom: 6px;
}

.quick-view-title {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary-navy);
  line-height: 1.3;
  margin-bottom: 8px;
}

.quick-view-prices {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin: 12px 0 16px 0;
}

.quick-view-curr-price {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--brand-red);
}

.quick-view-orig-price {
  font-size: 1.1rem;
  color: var(--text-muted);
  text-decoration: line-through;
}

.quick-view-discount-badge {
  background-color: var(--brand-red-light);
  color: var(--brand-red);
  padding: 3px 8px;
  border-radius: var(--radius-xs);
  font-size: 0.75rem;
  font-weight: 700;
}

.quick-view-specs {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.82rem;
  color: var(--text-secondary);
  margin-bottom: 1.25rem;
  padding: 0.85rem;
  background-color: var(--bg-surface);
  border-radius: var(--radius-sm);
}

.quick-view-sizes-wrapper {
  margin-bottom: 1.5rem;
}

.size-select-label {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--primary-navy);
  margin-bottom: 8px;
  display: block;
}

.size-chips-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.size-chip-btn {
  padding: 6px 14px;
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
  font-weight: 600;
  background-color: #ffffff;
  color: var(--text-main);
  transition: all var(--transition-fast);
}

.size-chip-btn:hover {
  border-color: var(--primary-navy);
}

.size-chip-btn.active {
  border-color: var(--brand-red);
  background-color: var(--brand-red);
  color: #ffffff;
}

.quick-view-actions {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: auto;
}

@media (min-width: 500px) {
  .quick-view-actions {
    flex-direction: row;
  }
}

.quick-view-add-btn {
  flex: 1;
  padding: 0.85rem 1.25rem;
  background-color: var(--primary-navy);
  color: #ffffff;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: background-color var(--transition-fast);
}

.quick-view-add-btn:hover {
  background-color: var(--brand-red);
}

.quick-view-wa-btn {
  padding: 0.85rem 1.25rem;
  background-color: var(--whatsapp-green);
  color: #ffffff;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: background-color var(--transition-fast);
}

.quick-view-wa-btn:hover {
  background-color: var(--whatsapp-hover);
}

/* ================== MOBILE NAVIGATION DRAWER ================== */
.mobile-nav-drawer {
  max-width: 320px;
}

.mobile-nav-logo-box {
  display: flex;
  align-items: center;
  gap: 10px;
}

.mobile-nav-list {
  display: flex;
  flex-direction: column;
  padding: 1rem 0;
}

.mobile-nav-item {
  border-bottom: 1px solid var(--border-subtle);
}

.mobile-nav-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 1.25rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--primary-navy);
}

.mobile-nav-link.active {
  color: var(--brand-red);
}

.mobile-submenu {
  display: none;
  background-color: var(--bg-surface);
  padding: 0.5rem 0 0.75rem 1.75rem;
}

.mobile-nav-item.open .mobile-submenu {
  display: block;
}

.mobile-submenu a {
  display: block;
  padding: 0.5rem 0;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.mobile-submenu a:hover {
  color: var(--brand-red);
}

/* ================== LIVE SEARCH OVERLAY ================== */
.search-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background-color: #ffffff;
  z-index: 1080;
  padding: 1.5rem 1rem 2rem 1rem;
  box-shadow: var(--shadow-xl);
  transform: translateY(-100%);
  transition: transform var(--transition-normal);
}

.search-overlay.active {
  transform: translateY(0);
}

.search-overlay-input-wrap {
  display: flex;
  align-items: center;
  max-width: 760px;
  margin: 0 auto;
  position: relative;
}

.search-overlay-input-wrap input {
  width: 100%;
  padding: 1rem 3.5rem 1rem 1.5rem;
  font-size: 1.1rem;
  border: 2px solid var(--border-subtle);
  border-radius: var(--radius-full);
  background-color: var(--bg-surface);
}

.search-overlay-input-wrap input:focus {
  background-color: #ffffff;
  border-color: var(--brand-gold);
}

.search-overlay-close {
  position: absolute;
  right: 14px;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background-color: #ffffff;
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
}

.search-results-preview {
  max-width: 760px;
  margin: 1.5rem auto 0 auto;
  max-height: 50vh;
  overflow-y: auto;
}

/* ================== FLOATING WHATSAPP BUTTON ================== */
.floating-whatsapp-btn {
  position: fixed;
  right: 18px;
  bottom: calc(var(--bottom-bar-height) + 16px);
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background-color: var(--whatsapp-green);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(37, 211, 102, 0.45);
  z-index: 980;
  transition: all var(--transition-fast);
}

@media (min-width: 992px) {
  .floating-whatsapp-btn {
    bottom: 24px;
    right: 24px;
    width: 58px;
    height: 58px;
  }
}

.floating-whatsapp-btn:hover {
  background-color: var(--whatsapp-hover);
  transform: scale(1.1) rotate(5deg);
}

.floating-whatsapp-btn svg {
  width: 28px;
  height: 28px;
  fill: currentColor;
}

/* ================== TOAST NOTIFICATION ================== */
.toast-container {
  position: fixed;
  top: 80px;
  right: 20px;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

.toast-item {
  background-color: var(--primary-navy-dark);
  color: #ffffff;
  border-left: 4px solid var(--brand-gold);
  border-radius: var(--radius-sm);
  padding: 0.75rem 1.25rem;
  font-size: 0.85rem;
  font-weight: 600;
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 10px;
  transform: translateX(120%);
  transition: transform 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  pointer-events: auto;
}

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

.toast-item.toast-success {
  border-left-color: var(--success);
}

.toast-item.toast-danger {
  border-left-color: var(--brand-red);
}
