/* ============================================
   MUMBAI SAFETY – Components Stylesheet (v2)
   ============================================ */

/* Search Results Dropdown */
.search-result-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--gray-100);
  cursor: pointer;
  transition: background var(--transition);
}
.search-result-item:hover {
  background: var(--yellow-light);
}
.search-result-item:last-child {
  border-bottom: none;
}
.search-result-item__image {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  background: var(--gray-100);
}
.search-result-item__info {
  flex: 1;
  min-width: 0;
}
.search-result-item__name {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--navy);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.search-result-item__brand {
  font-size: 0.75rem;
  color: var(--gray-500);
}
.search-result-item__price {
  font-weight: 700;
  color: var(--navy);
  font-size: 0.9rem;
}

/* Quantity Selector */
.quantity-selector {
  display: inline-flex;
  align-items: center;
  border: 2px solid var(--gray-200);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.quantity-selector__btn {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gray-50);
  color: var(--gray-700);
  font-size: 1.1rem;
  font-weight: 600;
  transition: all var(--transition);
}
.quantity-selector__btn:hover {
  background: var(--gray-200);
}
.quantity-selector__btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.quantity-selector__input {
  width: 48px;
  height: 36px;
  text-align: center;
  border: none;
  border-left: 2px solid var(--gray-200);
  border-right: 2px solid var(--gray-200);
  font-weight: 600;
  font-size: 0.9rem;
  appearance: textfield;
  -moz-appearance: textfield;
}
.quantity-selector__input::-webkit-outer-spin-button,
.quantity-selector__input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

/* Bundle Offer */
.bundle-offer {
  background: linear-gradient(135deg, rgba(255, 211, 79, 0.15), rgba(15, 23, 42, 0.04));
  border: 1px solid rgba(255, 193, 7, 0.3);
  border-radius: var(--radius-lg);
  padding: 18px 18px 10px;
  margin: 18px 0;
}
.bundle-offer__badge {
  display: inline-block;
  background: var(--yellow);
  color: var(--navy);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.bundle-offer h3 {
  margin: 12px 0 8px;
  font-size: 1.05rem;
  color: var(--navy);
}
.bundle-offer p {
  margin: 0 0 14px;
  font-size: 0.9rem;
  color: var(--gray-600);
  line-height: 1.6;
}
.bundle-progress__meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
  font-size: 0.82rem;
  color: var(--gray-700);
  font-weight: 600;
}
.bundle-progress__bar {
  position: relative;
  width: 100%;
  height: 10px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.08);
  overflow: hidden;
  margin-bottom: 10px;
}
.bundle-progress__bar span {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, #f59e0b, #fbbf24);
  border-radius: inherit;
  transition: width 0.2s ease;
}
.bundle-progress__status {
  color: var(--navy);
  font-size: 0.82rem;
  font-weight: 700;
  margin-bottom: 12px;
}
.bundle-size-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.bundle-size-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
  padding: 8px 10px;
}
.bundle-size-row__label {
  font-weight: 700;
  color: var(--navy);
  font-size: 0.9rem;
}
.bundle-size-row__controls {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-sm);
  overflow: hidden;
}
.bundle-size-btn {
  width: 28px;
  height: 28px;
  border: none;
  background: var(--gray-100);
  color: var(--navy);
  cursor: pointer;
  font-size: 1rem;
  font-weight: 700;
}
.bundle-size-btn:hover {
  background: var(--gray-200);
}
.bundle-size-input {
  width: 42px;
  height: 28px;
  border: none;
  border-left: 1px solid var(--gray-200);
  border-right: 1px solid var(--gray-200);
  text-align: center;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--navy);
  background: var(--white);
  appearance: textfield;
  -moz-appearance: textfield;
}
.bundle-size-input::-webkit-outer-spin-button,
.bundle-size-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
.bundle-summary {
  margin-top: 16px;
  border-top: 1px solid rgba(15, 23, 42, 0.1);
  padding-top: 12px;
}
.bundle-summary__row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.82rem;
  color: var(--gray-700);
  padding: 4px 0;
}
.bundle-summary__row--discount {
  color: #b45309;
}
.bundle-summary__row--total {
  color: var(--navy);
  font-weight: 800;
  font-size: 0.94rem;
  margin-top: 4px;
}
.cart-item__bundle {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
  font-size: 0.78rem;
  color: var(--gray-700);
}
.cart-item__bundle span {
  background: var(--yellow-light);
  border: 1px solid rgba(245, 158, 11, 0.3);
  border-radius: 999px;
  padding: 4px 8px;
}
.cart-item__bundle-discount {
  margin-top: 6px;
  font-size: 0.8rem;
  font-weight: 700;
  color: #b45309;
}

/* Product Image Gallery */
.product-gallery {
  display: flex;
  gap: 16px;
}
.product-gallery__thumbs {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.product-gallery__thumb {
  width: 70px;
  height: 70px;
  border: 2px solid var(--gray-200);
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
  transition: border-color var(--transition);
}
.product-gallery__thumb.active,
.product-gallery__thumb:hover {
  border-color: var(--yellow);
}
.product-gallery__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.product-gallery__main {
  flex: 1;
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--gray-50);
  cursor: zoom-in;
}
.product-gallery__main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition);
}
.product-gallery__main:hover img {
  transform: scale(1.5);
}

/* Specifications Table */
.specs-table {
  width: 100%;
  border-collapse: collapse;
}
.specs-table tr {
  border-bottom: 1px solid var(--gray-200);
}
.specs-table tr:last-child {
  border-bottom: none;
}
.specs-table td {
  padding: 10px 12px;
  font-size: 0.9rem;
}
.specs-table td:first-child {
  font-weight: 600;
  color: var(--gray-700);
  width: 35%;
}
.specs-table td:last-child {
  color: var(--gray-600);
}

/* Cart Item */
.cart-item {
  display: flex;
  gap: 16px;
  padding: 20px 0;
  border-bottom: 1px solid var(--gray-200);
  align-items: center;
}
.cart-item__image {
  width: 100px;
  height: 100px;
  border-radius: var(--radius-md);
  object-fit: cover;
  background: var(--gray-50);
  flex-shrink: 0;
}
.cart-item__details {
  flex: 1;
  min-width: 0;
}
.cart-item__name {
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 4px;
}
.cart-item__brand {
  font-size: 0.8rem;
  color: var(--gray-500);
  margin-bottom: 4px;
}
.cart-item__weight {
  font-size: 0.8rem;
  color: var(--gray-500);
}
.cart-item__price {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--navy);
  white-space: nowrap;
}
.cart-item__actions {
  display: flex;
  align-items: center;
  gap: 12px;
}
.cart-item__remove {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--gray-100);
  color: var(--gray-500);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
}
.cart-item__remove:hover {
  background: var(--danger);
  color: var(--white);
}

/* Cart Summary */
.cart-summary {
  background: var(--gray-50);
  border-radius: var(--radius-lg);
  padding: 24px;
  border: 1px solid var(--gray-200);
}
.cart-summary__row {
  display: flex;
  justify-content: space-between;
  padding: 10px 0;
  font-size: 0.95rem;
}
.cart-summary__row--total {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--navy);
  border-top: 2px solid var(--gray-200);
  padding-top: 16px;
  margin-top: 8px;
}
.cart-summary__row--shipping {
  color: var(--gray-600);
}

/* Checkout Form */
.checkout-form {
  max-width: 600px;
}
.form-group {
  margin-bottom: 20px;
}
.form-label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--gray-700);
  margin-bottom: 6px;
}
.form-label--optional::after {
  content: " (optional)";
  font-weight: 400;
  color: var(--gray-500);
  font-size: 0.8rem;
}
.form-input {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid var(--gray-200);
  border-radius: var(--radius-md);
  font-size: 0.95rem;
  transition: border-color var(--transition);
  background: var(--white);
}
.form-input:focus {
  outline: none;
  border-color: var(--yellow);
  box-shadow: 0 0 0 3px var(--yellow-light);
}
.form-input--error {
  border-color: var(--danger);
}
.form-error {
  color: var(--danger);
  font-size: 0.8rem;
  margin-top: 4px;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

/* Payment Options */
.payment-option {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  border: 2px solid var(--gray-200);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition);
  margin-bottom: 12px;
}
.payment-option:hover,
.payment-option.active {
  border-color: var(--yellow);
  background: var(--yellow-light);
}
.payment-option__radio {
  width: 20px;
  height: 20px;
  accent-color: var(--yellow);
}

/* Invoice */
.invoice {
  max-width: 800px;
  margin: 0 auto;
  padding: 40px;
  background: var(--white);
  border: 1px solid var(--gray-200);
}
.invoice__header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 32px;
  padding-bottom: 24px;
  border-bottom: 2px solid var(--navy);
}
.invoice__info {
  text-align: right;
}
.invoice__title {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--navy);
}
.invoice__number {
  font-size: 0.9rem;
  color: var(--gray-500);
}
.invoice__addresses {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 24px;
}
.invoice__address h4 {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--gray-500);
  margin-bottom: 8px;
}
.invoice__table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0;
}
.invoice__table th {
  background: var(--navy);
  color: var(--white);
  padding: 12px;
  text-align: left;
  font-size: 0.85rem;
}
.invoice__table td {
  padding: 12px;
  border-bottom: 1px solid var(--gray-200);
  font-size: 0.9rem;
}
.invoice__table .text-right {
  text-align: right;
}
.invoice__total {
  text-align: right;
  margin-top: 16px;
}
.invoice__total-row {
  display: flex;
  justify-content: flex-end;
  gap: 40px;
  padding: 8px 0;
}
.invoice__total-row--grand {
  font-size: 1.2rem;
  font-weight: 700;
  border-top: 2px solid var(--navy);
  padding-top: 12px;
  margin-top: 8px;
}

/* Print Styles */
@media print {
  .header, .footer, .back-to-top, .toast-container,
  .btn:not(.btn--print), .no-print {
    display: none !important;
  }
  .invoice {
    border: none;
    padding: 0;
  }
  body {
    font-size: 12px;
  }
}

/* Filters Sidebar */
.filters-sidebar {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 20px;
}
.filter-group {
  margin-bottom: 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--gray-200);
}
.filter-group:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}
.filter-group__title {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--navy);
  margin-bottom: 12px;
}
.filter-option {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
  font-size: 0.9rem;
  color: var(--gray-600);
  cursor: pointer;
}
.filter-option input[type="checkbox"] {
  accent-color: var(--yellow);
}
.price-range {
  display: flex;
  gap: 8px;
  align-items: center;
}
.price-range input {
  width: 100%;
  padding: 8px;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
}

/* Sort Select */
.sort-select {
  padding: 8px 32px 8px 12px;
  border: 2px solid var(--gray-200);
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  color: var(--gray-700);
  background: var(--white);
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%2364748B' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
}

/* View Toggle */
.view-toggle {
  display: flex;
  gap: 4px;
  border: 2px solid var(--gray-200);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.view-toggle__btn {
  padding: 8px 12px;
  background: var(--white);
  color: var(--gray-500);
  transition: all var(--transition);
}
.view-toggle__btn.active {
  background: var(--navy);
  color: var(--white);
}

/* Pagination */
.pagination {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-top: 40px;
}
.pagination__btn {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 500;
  border: 1px solid var(--gray-200);
  background: var(--white);
  color: var(--gray-700);
  transition: all var(--transition);
}
.pagination__btn:hover:not(:disabled) {
  border-color: var(--yellow);
  background: var(--yellow-light);
}
.pagination__btn.active {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
}
.pagination__btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* FAQ */
.faq-item {
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
  margin-bottom: 12px;
  overflow: hidden;
}
.faq-item__question {
  width: 100%;
  padding: 16px 20px;
  text-align: left;
  font-weight: 600;
  color: var(--navy);
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--white);
  transition: background var(--transition);
}
.faq-item__question:hover {
  background: var(--gray-50);
}
.faq-item__icon {
  transition: transform var(--transition);
}
.faq-item.active .faq-item__icon {
  transform: rotate(180deg);
}
.faq-item__answer {
  padding: 0 20px;
  max-height: 0;
  overflow: hidden;
  transition: all var(--transition);
}
.faq-item.active .faq-item__answer {
  padding: 16px 20px;
  max-height: 500px;
}

/* Recently Viewed */
.recently-viewed {
  padding: 20px 0;
}
.recently-viewed__grid {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding-bottom: 10px;
}
.recently-viewed__item {
  flex-shrink: 0;
  width: 180px;
}

/* Wishlist Sidebar */
.wishlist-sidebar {
  position: fixed;
  top: 0;
  right: 0;
  width: 380px;
  height: 100%;
  background: var(--white);
  box-shadow: var(--shadow-xl);
  z-index: 1001;
  transform: translateX(100%);
  transition: transform var(--transition);
  display: flex;
  flex-direction: column;
}
.wishlist-sidebar.active {
  transform: translateX(0);
}
.wishlist-sidebar__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  border-bottom: 1px solid var(--gray-200);
}
.wishlist-sidebar__body {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
}

/* Sticky Mobile Cart Button */
.mobile-cart-btn {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--navy);
  color: var(--white);
  padding: 12px 20px;
  z-index: 900;
  text-align: center;
  font-weight: 600;
  box-shadow: 0 -4px 12px rgba(0,0,0,0.2);
}

/* Dark Mode Toggle */
.dark-mode-toggle {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gray-700);
  transition: all var(--transition);
}
.dark-mode-toggle:hover {
  background: var(--gray-100);
}

/* Bulk Order Highlight Link (for header) */
.header__bulk-link {
  background: var(--yellow);
  color: var(--navy) !important;
  padding: 6px 14px !important;
  border-radius: var(--radius-full);
  font-weight: 700;
  margin-left: 8px;
}
.header__bulk-link:hover {
  background: var(--yellow-dark) !important;
}