body {
  margin: 0;
  background-color: #f0f2f5;
  overflow-x: hidden;
}

.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(8px);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.popup {
  background: white;
  width: 90%;
  max-width: 500px;
  height: 80vh;
  max-height: 650px;
  border-radius: 16px;
  box-shadow: 0 15px 50px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: slideUp 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

@keyframes slideUp {
  from {
    transform: translateY(50px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.popup-header {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 25px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  flex-shrink: 0;
}

.popup-header h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
}

.clear-btn {
  background: rgba(255, 255, 255, 0.2);
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 20px;
  cursor: pointer;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  line-height: 1;
}

.clear-btn:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: rotate(90deg);
}

.steps {
  display: flex;
  justify-content: space-between;
  padding: 15px 25px 12px;
  position: relative;
  background: white;
}

.step {
  text-align: center;
  flex: 1;
  position: relative;
  z-index: 1;
  cursor: pointer;
  transition: all 0.3s ease;
  opacity: 0.5;
  pointer-events: none;
}

.step.active {
  opacity: 1;
  pointer-events: auto;
}

.step-circle {
  width: 36px;
  height: 36px;
  line-height: 36px;
  border-radius: 50%;
  background: #e0e0e0;
  color: #999;
  margin: 0 auto 6px;
  font-weight: bold;
  font-size: 15px;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.step p {
  font-size: 11px;
  color: #999;
  margin: 0;
  font-weight: 500;
  transition: all 0.3s ease;
}

.step.active .step-circle {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  transform: scale(1.08);
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.step.active p {
  color: #667eea;
  font-weight: 600;
}

.popup-content {
  flex-grow: 1;
  overflow-y: auto;
  padding: 20px;
  background: #f8f9fa;
}

.popup-content::-webkit-scrollbar {
  width: 6px;
}

.popup-content::-webkit-scrollbar-track {
  background: #f1f1f1;
}

.popup-content::-webkit-scrollbar-thumb {
  background: #667eea;
  border-radius: 10px;
}

.tab-content {
  display: none;
  animation: fadeInContent 0.4s ease;
}

@keyframes fadeInContent {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.tab-content.active {
  display: block;
}

.cart-item {
  background: white;
  border-radius: 10px;
  padding: 12px;
  margin-bottom: 12px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
}

.cart-item:hover {
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.12);
  transform: translateY(-2px);
}

.item-details {
  display: flex;
  flex-direction: column;
}

.item-name {
  font-size: 17px;
  font-weight: 600;
  color: #2d3748;
  margin: 0 0 8px;
}

.item-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.item-price {
  font-size: 19px;
  font-weight: 700;
  color: #667eea;
  margin: 0;
}

.item-category {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  background: #f0f4ff;
  border-radius: 16px;
  font-size: 12px;
  color: #667eea;
  font-weight: 500;
}

.women-icon {
  font-size: 16px;
  line-height: 1;
}

.cartquantity-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 2px solid #f0f0f0;
}

.cartquantity-selector {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #f8f9fa;
  border-radius: 20px;
  padding: 4px;
}

.cartqty-btn-separate {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  border: none;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  color: white;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.cartqty-btn-separate:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.cartqty-label {
  font-size: 14px;
  font-weight: 600;
  color: #2d3748;
  min-width: 60px;
  text-align: center;
  padding: 0;
  background: transparent;
}

.remove-btn {
  background: linear-gradient(135deg, #f56565 0%, #e53e3e 100%);
  color: white;
  border: none;
  border-radius: 16px;
  cursor: pointer;
  font-size: 13px;
  height:30px;
  padding:0 14px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.3s ease;
}

.remove-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(245, 101, 101, 0.4);
}

.trash-icon {
  font-size: 14px;
  line-height: 1;
  background-color: red;
}

.cart-summary {
  margin-top: 12px;
}

.summary-details {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  border-radius: 10px;
  padding: 12px;
  text-align: center;
  margin-bottom: 12px;
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.summary-text {
  font-size: 18px;
  font-weight: 700;
  color: white;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  margin: 0;
}

.cart-summary .btn {
  width: 100%;
  background: white;
  color: #667eea;
  padding: 12px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  border: 2px solid #667eea;
  cursor: pointer;
  transition: all 0.3s ease;
  margin: 0;
}

.cart-summary .btn:hover {
  background: #667eea;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

#step2 h2 {
  font-size: 22px;
  color: #2d3748;
  margin-bottom: 12px;
  margin-top: 0;
  text-align: center;
}

.form-group {
  margin-bottom: 15px;
}

.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 6px;
  color: #4a5568;
  font-size: 13px;
}

.form-group input {
  width: 100%;
  padding: 10px 12px;
  border: 2px solid #e2e8f0;
  border-radius: 8px;
  font-size: 14px;
  transition: all 0.3s ease;
  background: white;
  box-sizing: border-box;
}

.form-group input:focus {
  outline: none;
  border-color: #667eea;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.form-actions {
  display: flex;
  gap: 12px;
  margin-top: 20px;
}

.form-actions .btn {
  flex: 1;
  padding: 12px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-back {
  background: #e2e8f0 !important;
  color: #4a5568 !important;
}

.btn-next {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
  color: white !important;
}

.btn-pay {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
  color: white !important;
}

.btn-close {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
  color: white !important;
  width: 100%;
  padding: 12px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
}

.form-actions .btn:hover,
.btn-close:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}


#step3 h2 {
  font-size: 22px;
  color: #2d3748;
  margin-bottom: 12px;
  margin-top: 0;
  text-align: center;
}

.payment-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.payment-options label {
  display: flex;
  align-items: center;
  gap: 10px;
  background: white;
  border: 2px solid #e2e8f0;
  padding: 14px;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-weight: 500;
  font-size: 14px;
}

.payment-options label:hover {
  border-color: #667eea;
  background: #f0f4ff;
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.15);
}

.payment-options input[type="radio"] {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  width: 18px;
  height: 18px;
  border: 2px solid #cbd5e0;
  border-radius: 50%;
  position: relative;
  cursor: pointer;
  transition: all 0.3s ease;
  flex-shrink: 0;
}

.payment-options input[type="radio"]:checked {
  border-color: #667eea;
  background: #667eea;
}

.payment-options input[type="radio"]:checked::after {
  content: '';
  width: 8px;
  height: 8px;
  background: white;
  border-radius: 50%;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.payment-options label:has(input:checked) {
  border-color: #667eea;
  background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
}

.upi-apps-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
  gap: 10px;
  margin-bottom: 20px;
}

.upi-app-button {
  background: white;
  border: 2px solid #e2e8f0;
  padding: 12px;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-weight: 600;
  color: #4a5568;
  text-align: center;
  font-size: 13px;
}

.upi-app-button:hover {
  border-color: #667eea;
  background: #f0f4ff;
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.15);
}

.total-amount {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 10px;
  border-radius: 10px;
  text-align: center;
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 15px;
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.total-amount span {
  font-size: 20px;
  display: block;
  margin-top: 4px;
}

.success-message-card {
  text-align: center;
  padding: 15px;
}

.successcheckmark-circle {
  background: linear-gradient(135deg, #48bb78 0%, #38a169 100%);
  width: 55px;
  height: 55px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 12px;
  font-size: 30px;
  color: white;
  box-shadow: 0 6px 20px rgba(72, 187, 120, 0.4);
  animation: successPop 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  font-weight: bold;
}

@keyframes successPop {
  0% {
    transform: scale(0);
    opacity: 0;
  }
  50% {
    transform: scale(1.2);
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.success-message-card h2 {
  font-size: 24px;
  color: #2d3748;
  margin-bottom: 6px;
  margin-top: 0;
}

.success-message-card p {
  font-size: 14px;
  color: #718096;
  margin: 0;
}

.order-details {
  background: white;
  border-radius: 12px;
  padding: 18px;
  margin: 18;
}


.navbar {
  background-color: #3f51b5;
  color: white;
  padding: 15px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: nowrap;
}

.logo {
  font-size: 24px;
  font-weight: bold;
  flex-shrink: 0;
}

.cartIcon {
  font-size: 24px;
  background: none;
  border: none;
  color: white;
  cursor: pointer;
  flex-shrink: 0;
}

.cart-container {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.login-btn {
  padding: 8px 15px;
  background: white;
  color: #3f51b5;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-weight: 600;
  flex-shrink: 0;
}

.cart-count {
  position: absolute;
  top: -8px;
  right: -8px;
  background-color: #f44336;
  color: white;
  border-radius: 50%;
  padding: 2px 6px;
  font-size: 12px;
  font-weight: bold;
}

.cart-items {
  display: none;
  position: absolute;
  top: 40px;
  right: 0;
  background-color: white;
  border: 1px solid #ccc;
  box-shadow: 0px 2px 8px rgba(0, 0, 0, 0.2);
  width: 220px;
  max-height: 200px;
  overflow-y: auto;
  padding: 10px;
  z-index: 1000;
}
.cart-icon-wrapper {
  position: relative;
  display: inline-block;

}


.bar {
  justify-content: space-between;
  overflow-x: hidden;
}

.search-bar {
  display: flex;
  justify-content: flex-start;
  padding: 20px;
  background-color: white;
  border-bottom: 1px solid #ddd;
  flex-direction: column;
  flex-wrap: wrap;
  box-sizing: border-box;
  gap: 10px;
}

.searchinput {
  flex: 1;
  min-width: 480px;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 5px;
  font-size: 16px;
  margin-right: 20px;
}

.search-button {
  padding: 10px 15px;
  background-color: #3f51b5;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 16px;
}

.filters {
  background-color: white;
  padding: 15px;
  display: flex;
  align-items: center;
  gap: 25px;
  border-bottom: 1px solid #ddd;
  border-radius: 5px;
}

.filters select,
.filters button {
  padding: 8px;
  border: 1px solid #ccc;
  border-radius: 4px;
}

.clear-filter {
  background-color: #f44336;
  color: white;
  border: none;
  cursor: pointer;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  padding: 20px;
}

.product-card {
  background-color: white;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  padding: 15px;
  text-align: center;
  position: relative;
  transition: all 0.3s ease;
}

.product-card.hidden {
  display: none;
}

.product-gender-tag {
  position: absolute;
  top: 10px;
  right: 10px;
  background-color: #607d8b;
  color: white;
  padding: 5px 10px;
  border-radius: 4px;
  font-size: 12px;
}

.product-gender-tag.girl {
  background-color: #ff69b4;
}

.product-gender-tag.boy {
  background-color: #4169e1;
}

.product-gender-tag.unisex {
  background-color: #9c27b0;
}

.product-gender-tag.men {
  background-color: #2196f3;
}

.product-gender-tag.women {
  background-color: #e91e63;
}

.product-image-placeholder {
  width: 100px;
  height: 100px;
  background-color: #eee;
  margin: 0 auto 15px;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 40px;
  color: #bbb;
}

.product-title {
  margin-bottom: 10px;
}

.product-price {
  font-size: 20px;
  font-weight: bold;
  color: #333;
  margin-bottom: 15px;
}

.buttonCart {
  display: flex;
  justify-content: center;
  align-items: center;
}

.add-to-cart {
  background: #3f51b5;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: bold;
}

.quantity-control {
  display: none;
  align-items: center;
  border: 1px solid #3f51b5;
  border-radius: 8px;
  overflow: hidden;
}

.quantity-control button {
  background-color: #3f51b5;
  color: white;
  border: none;
  padding: 10px 15px;
  font-size: 18px;
  cursor: pointer;
}

.quantity-control span {
  padding: 0 15px;
  font-size: 16px;
  font-weight: bold;
}
.product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr); 
  gap: 20px;
  padding: 20px;
}

@media (max-width: 1200px) {
  .product-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 900px) {
  .product-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .product-grid {
    grid-template-columns: 1fr;
  }
}


.overlayscreen {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.popupscreen {
  background: #fff;
  width: 90%;
  max-width: 400px;
  border-radius: 10px;
  padding: 25px 30px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
  position: relative;
  animation: scaleIn 0.3s ease;
}

@keyframes scaleIn {
  from {
    transform: scale(0.8);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.popupscreen h2 {
  margin-top: 0;
  font-size: 22px;
  text-align: center;
}

.screenform-group {
  margin-bottom: 14px;
  text-align: left;
}

.screenform-group label {
  display: block;
  font-size: 14px;
  margin-bottom: 5px;
  color: #333;
}

.screenform-group input {
  width: 100%;
  padding: 10px;
  border-radius: 6px;
  border: 1px solid #ddd;
  font-size: 15px;
  box-sizing: border-box;
}

.popupscreen button {
  width: 100%;
  margin-top: 10px;
  background: #1f6feb;
  border: none;
  color: #fff;
  padding: 10px;
  border-radius: 6px;
  font-size: 15px;
  cursor: pointer;
}

.popupscreen button:hover {
  background: #155ccc;
}

.link {
  display: block;
  margin-top: 10px;
  color: #1f6feb;
  text-decoration: none;
  font-size: 14px;
  cursor: pointer;
  text-align: center;
}

.close-btn {
  position: absolute;
  top: 10px;
  right: 12px;
  font-size: 20px;
  cursor: pointer;
  color: #999;
  background: none;
  border: none;
}

.hidden {
  display: none;
}

.popupscreen p {
  font-size: 14px;
  color: #555;
  margin-top: 0;
  text-align: center;
}

.user-dropdown {
  position: relative;
  display: inline-block;
}

.user-btn {
  background-color: white;
  color: black;
  padding: 6px 12px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}

.dropdown-content {
  display: flex;
  flex-direction: column;
  position: absolute;
  right: 0;
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
  margin-top: 6px;
  overflow: hidden;
}

.dropdown-content a {
  padding: 8px 14px;
  text-decoration: none;
  color: #333;
  font-size: 14px;
}

.dropdown-content a:hover {
  background-color: #f2f2f2;
}

.modal,
.modalpassword {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(5px);
  overflow: auto;
  justify-content: center;
  align-items: center;
}

.modal-content {
  background-color: #fff;
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
  width: 90%;
  max-width: 500px;
  position: relative;
  animation: slideDown 0.3s ease;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-50px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.modal-content h2 {
  margin: 0 0 25px 0;
  font-size: 24px;
  color: #333;
  text-align: center;
}

.close-modal,
.close-update-modal,
.close-password-modal {
  position: absolute;
  top: 15px;
  right: 20px;
  font-size: 28px;
  font-weight: bold;
  color: #999;
  cursor: pointer;
  transition: color 0.2s;
}

.close-modal:hover,
.close-update-modal:hover,
.close-password-modal:hover {
  color: #333;
}

.profile-info {
  background: #f8f9fa;
  padding: 20px;
  border-radius: 8px;
  margin-bottom: 20px;
}

.profile-info p {
  margin: 10px 0;
  font-size: 16px;
  color: #555;
}

.profile-info strong {
  color: #333;
  font-weight: 600;
}

.profile-info span {
  color: #666;
  margin-left: 10px;
}

.profile-actions {
  display: flex;
  gap: 15px;
  justify-content: center;
  margin-top: 20px;
}

.btn-update {
  background: #28a745;
  color: white;
  padding: 12px 25px;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.3s;
}

.btn-update:hover {
  background: #218838;
  transform: translateY(-2px);
}

.btn-change {
  background: #007bff;
  color: white;
  padding: 12px 25px;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  cursor: pointer;
  transition: background 0.3s;
}

.btn-change:hover {
  background: #0056b3;
  transform: translateY(-2px);
}

.modal-content form {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.modal-content label {
  font-weight: 600;
  color: #333;
  margin-bottom: 5px;
}

.modal-content input {
  padding: 12px;
  border: 2px solid #ddd;
  border-radius: 8px;
  font-size: 15px;
  transition: border-color 0.3s;
}

.modal-content input:focus {
  outline: none;
  border-color: #007bff;
}

.btn-submit {
  background: #007bff;
  color: white;
  padding: 12px;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  cursor: pointer;
  transition: background 0.3s;
  margin-top: 10px;
}

.btn-submit:hover {
  background: #0056b3;
}

.btn-submit:disabled {
  background: #6c757d;
  cursor: not-allowed;
}

.btn-cancel {
  background: #6c757d;
  color: white;
  padding: 12px;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  cursor: pointer;
  transition: background 0.3s;
}

.btn-cancel:hover {
  background: #5a6268;
}

@media (max-width: 768px) {
  .popup {
    width: 95%;
    height: 90vh;
  }

  .steps {
    padding: 20px 15px;
  }

  .steps::before {
    left: 10%;
    right: 10%;
  }

  .step-circle {
    width: 40px;
    height: 40px;
    line-height: 40px;
    font-size: 16px;
  }

  .step p {
    font-size: 11px;
  }

  .popup-content {
    padding: 20px 15px;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .payment-options {
    grid-template-columns: 1fr;
  }

  .upi-apps-container {
    grid-template-columns: repeat(2, 1fr);
  }

  .cartquantity-controls {
    flex-direction: column;
    align-items: stretch;
  }

  .cartquantity-selector {
    justify-content: center;
  }

  .modal-content {
    width: 95%;
    padding: 20px;
  }

  .profile-actions {
    flex-direction: column;
  }

  .btn-update,
  .btn-change {
    width: 100%;
  }

  .searchinput {
    min-width: 100%;
    margin-right: 0;
    margin-bottom: 10px;
  }

  .filters {
    flex-direction: column;
    align-items: stretch;
  }

  .filters select,
  .filters button {
    width: 100%;
  }
}

.btn {
  background: #007bff;
  color: #fff;
  border: none;
  padding: 12px 30px;
  font-size: 16px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn:hover {
  background: #0056b3;
  transform: translateY(-2px);
}

html {
  scroll-behavior: smooth;
}

button:focus,
input:focus,
select:focus {
  outline: 2px solid #667eea;
  outline-offset: 2px;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.loading {
  animation: spin 1s linear infinite;
}

.cartIcon,.login-btn {
  cursor: pointer; 
  background: white; 
  border: 1px solid #ddd; 
  width: 40px; 
  height: 40px; 
  border-radius: 50%; 
  display: flex; 
  align-items: center; 
  justify-content: center;
  font-size: 20px;
  padding: 0;
}


/* Mobile First Approach - Base Styles */
body {
  margin: 0;
  background-color: #f0f2f5;
  overflow-x: hidden; 
}

.navbar {
  background-color: #3f51b5;
  color: white;
  padding: 12px 15px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: nowrap;
}

.logo {
  font-size: 20px;
  font-weight: bold;
  flex-shrink: 0;
}

.cart-container {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.cartIcon, .login-btn {
  cursor: pointer;
  background: white;
  border: 1px solid #ddd;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  padding: 0;
  flex-shrink: 0;
}

/* PERFECT ALIGNMENT - Search Bar & Filters */
.bar {
  width: 100%;
  overflow-x: hidden;
  padding: 0 !important;
  margin: 0 !important;
}

.search-bar {
  display: flex;
  justify-content: space-between;
  padding: 15px 12px !important; 
  background-color: white;
  border-bottom: 1px solid #ddd;
  flex-direction: row;
  gap: 8px;
  width: 100%;
  box-sizing: border-box;
  align-items: stretch;
  margin: 0;
}

.searchinput {
  flex: 1;
  min-width: unset;
  padding: 12px;
  border: 1px solid #ccc;
  border-radius: 5px;
  font-size: 14px;
  margin: 0 !important;
  box-sizing: border-box;
  height: 44px;
}

.search-button {
  flex-shrink: 0;
  padding: 12px 20px;
  background-color: #3f51b5;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 14px;
  white-space: nowrap;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 !important;
}

/* Filters  */
.filters {
  background-color: #ffffff;
  padding: 12px 20px; 
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px; 
  border-bottom: 1px solid #ddd;
  border-radius: 0;
  width: 100%;
  box-sizing: border-box;
  flex-wrap: nowrap;
  overflow-x: auto;
  margin: 0;
}


.filters select {
  flex: 0 0 auto;
  min-width: 90px;
  max-width: 110px;
  padding: 10px 8px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 13px;
  box-sizing: border-box;
  height: 40px;
  margin: 0 !important;
}

.clear-filter {
  background-color: #f44336;
  color: white;
  border: none;
  cursor: pointer;
  flex: 0 0 auto;
  padding: 10px 12px;
  white-space: nowrap;
  min-width: auto;
  max-width: none;
  height: 40px;
  font-size: 12px;
  border-radius: 4px;
  margin: 0 !important;
}

/* Product Grid Mobile  */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 12px;
  padding: 12px;
  width: 100%;
  box-sizing: border-box;
}

.product-card {
  background-color: white;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  padding: 12px;
  text-align: center;
  position: relative;
  transition: all 0.3s ease;
  width: 100%;
  box-sizing: border-box;
}

.product-title {
  font-size: 14px;
  margin: 8px 0;
  line-height: 1.3;
}

.product-price {
  font-size: 16px;
  font-weight: bold;
  color: #333;
  margin-bottom: 10px;
}

.product-image-placeholder {
  width: 70px;
  height: 70px;
  background-color: #eee;
  margin: 0 auto 10px;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 30px;
}

.buttonCart {
  display: flex;
  justify-content: center;
  align-items: center;
}

.add-to-cart {
  background: #3f51b5;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: bold;
  font-size: 14px;
}

.quantity-control {
  display: none;
  align-items: center;
  border: 1px solid #3f51b5;
  border-radius: 8px;
  overflow: hidden;
}

.quantity-control button {
  background-color: #3f51b5;
  color: white;
  border: none;
  padding: 10px 15px;
  font-size: 18px;
  cursor: pointer;
}

.quantity-control span {
  padding: 0 15px;
  font-size: 16px;
  font-weight: bold;
}

/* Cart Popup Mobile Fixes */
.popup {
  background: white;
  width: 80%;
  max-width: 400px;
  height: 70vh;
  max-height: 550px;
  border-radius: 12px;
  box-shadow: 0 15px 50px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.popup-header {
  padding: 15px;
  flex-shrink: 0;
}

.popup-header h2 {
  font-size: 18px;
}

.steps {
  padding: 12px 10px;
  overflow-x: visible;
  -webkit-overflow-scrolling: touch;
}

.step {
  min-width: 60px;
}

.step-circle {
  width: 32px;
  height: 32px;
  line-height: 32px;
  font-size: 14px;
  margin-bottom: 4px;
}

.step p {
  font-size: 10px;
  white-space: nowrap;
}

.popup-content {
  padding: 15px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.form-group input {
  width: 100%;
  padding: 10px;
  font-size: 14px;
  box-sizing: border-box;
}

.form-row {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.form-actions {
  flex-direction: column;
}

.form-actions .btn {
  width: 100%;
  margin-bottom: 8px;
}

.cart-item {
  padding: 10px;
  margin-bottom: 10px;
}

.item-name {
  font-size: 15px;
}

.item-price {
  font-size: 16px;
}

.cartquantity-controls {
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
}

.cartquantity-selector {
  justify-content: center;
  width: 100%;
}

.remove-btn {
  width: 100%;
  justify-content: center;
}

.payment-options {
  grid-template-columns: 1fr;
}

.popupscreen {
  width: 82%;
  max-width:320px;
  padding: 20px;
  box-sizing: border-box;
  overflow-y: auto;
  max-height: 75vh;
}

.screenform-group input {
  width: 100%;
  box-sizing: border-box;
}

.user-dropdown {
  position: relative;
}

.user-btn {
  padding: 6px 12px;
  font-size: 13px;
  white-space: nowrap;
}

.dropdown-content {
  min-width: 140px;
  right: 0;
  left: auto;
}

.dropdown-content a {
  padding: 10px 12px;
  font-size: 13px;
}

/* =========== MEDIA ========= */

@media (max-width: 480px) {
  .logo {
    font-size: 18px;
  }
  
  .search-bar {
    padding: 10px 12px !important;
    gap: 6px !important;
  }
  
  .searchinput {
    padding: 10px;
    font-size: 13px;
    height: 40px;
  }
  
  .search-button {
    padding: 10px 15px;
    font-size: 13px;
    height: 40px;
  }
  
  .filters {
    gap: 6px !important;
    padding: 10px  12px !important;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  .filters select {
    min-width: 75px;
    max-width: 85px;
    font-size: 11px;
    padding: 8px 4px;
    height: 36px;
  }
  
  .clear-filter {
    padding: 8px 10px;
    font-size: 11px;
    height: 36px;
  }
  
  .product-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    padding: 10px;
  }
  
  .product-card {
    padding: 10px;
  }
  
  .product-image-placeholder {
    width: 60px;
    height: 60px;
    font-size: 25px;
  }
  
  .product-title {
    font-size: 13px;
  }
  
  .product-price {
    font-size: 15px;
  }
  
  .add-to-cart {
    padding: 8px 12px;
    font-size: 13px;
  }
  
  .popup {
    width: 98%;
    height: 95vh;
  }
  
  .popup-header h2 {
    font-size: 16px;
  }
  
  .step-circle {
    width: 28px;
    height: 28px;
    line-height: 28px;
    font-size: 12px;
  }
  
  .step p {
    font-size: 9px;
  }
}

/* Small Mobile (481px - 600px) */
@media (min-width: 481px) and (max-width: 600px) {
  .product-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .filters {
    flex-wrap: nowrap;
    overflow-x: auto;
  }
  
  .filters select {
    min-width: 85px;
    max-width: 100px;
  }
}

/* Tablet Portrait (601px - 768px) */
@media (min-width: 601px) and (max-width: 768px) {
  .product-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    padding: 15px;
  }
  
  .search-bar {
    padding: 15px !important;
  }
  
  .filters {
    flex-wrap: nowrap;
    gap: 10px !important;
    padding: 15px !important;
  }
  
  .filters select {
    min-width: 100px;
    max-width: 130px;
  }
  
  .clear-filter {
    padding: 10px 15px;
  }
  
  .form-row {
    flex-direction: row;
  }
  
  .form-actions {
    flex-direction: row;
  }
  
  .popup {
    width: 90%;
    max-width: 500px;
    height: 85vh;
  }
}

/* Tablet Landscape (769px - 900px) */
@media (min-width: 769px) and (max-width: 900px) {
  .product-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  
  .search-bar,
  .filters {
    padding: 15px !important;
  }
}

/* Desktop (901px - 1200px) */
@media (min-width: 901px) and (max-width: 1200px) {
  .product-grid {
    grid-template-columns: repeat(4, 1fr);
  }
  
  .search-bar {
    padding: 15px 20px !important;
  }
  
  .filters {
    gap: 12px !important;
    padding: 15px 20px !important;
  }
  
  .filters select {
    min-width: 110px;
    max-width: 140px;
    padding: 10px;
    font-size: 14px;
    height: 42px;
  }
  
  .clear-filter {
    padding: 10px 15px;
    font-size: 14px;
    height: 42px;
  }
  
  .searchinput,
  .search-button {
    height: 46px;
  }
}

/* Large Desktop (1201px+) */
@media (min-width: 1201px) {
  .product-grid {
    grid-template-columns: repeat(4, 1fr);
  }
  
  .searchinput {
    min-width: 400px;
  }
  
  .search-bar {
    padding: 15px 20px !important;
  }
  
  .filters {
    padding: 15px 20px !important;
    gap: 15px !important;
  }
  
  .filters select {
    min-width: 120px;
    max-width: 150px;
    padding: 10px;
    font-size: 14px;
    height: 42px;
  }
  
  .clear-filter {
    padding: 10px 20px;
    font-size: 14px;
    height: 42px;
  }
  
  .searchinput,
  .search-button {
    height: 46px;
  }
}

@media (max-height: 500px) and (orientation: landscape) {
  .popup {
    height: 95vh;
    max-height: 95vh;
  }
  
  .popup-header {
    padding: 10px 15px;
  }
  
  .steps {
    padding: 8px 10px;
  }
  
  .popup-content {
    padding: 10px 15px;
  }
}

@media (hover: none) and (pointer: coarse) {
  .add-to-cart,
  .btn,
  button {
    min-height: 5px;
    touch-action: manipulation;
  }
  
  .cartIcon,
  .login-btn,
  .user-btn {
    min-width: 44px;
    min-height: 44px;
  }
}

@supports (padding: max(0px)) {
  .navbar {
    padding-left: max(15px, env(safe-area-inset-left));
    padding-right: max(15px, env(safe-area-inset-right));
  }
  
  .search-bar,
  .filters,
  .product-grid {
    padding-left: max(12px, env(safe-area-inset-left)) !important;
    padding-right: max(12px, env(safe-area-inset-right)) !important;
  }
  
  .popup {
    margin-left: env(safe-area-inset-left);
    margin-right: env(safe-area-inset-right);
  }
}


@media (max-width: 480px) {
  .navbar { padding: 10px 12px !important; }
  .search-bar { padding: 10px 12px !important; }
  .filters { padding: 10px 12px !important; }
}

@media (min-width: 481px) and (max-width: 600px) {
  .navbar { padding: 12px 15px !important; }
  .search-bar { padding: 12px 15px !important; }
  .filters { padding: 12px 15px !important; }
}

@media (min-width: 601px) {
  .navbar { padding: 15px 20px !important; }
  .search-bar { padding: 15px 20px !important; }
  .filters { padding: 15px 20px !important; }
}

/* ========== ALIGNMENT FIX - ADD THIS AT THE END ========== */

.clear-filter {
  background-color: #f44336 !important;
  color: white !important;
  border: none !important;
  cursor: pointer !important;
  padding: 10px 14px !important;
  white-space: nowrap !important;
  min-width: auto !important;
  max-width: fit-content !important;
  height: 40px !important;
  font-size: 13px !important;
  border-radius: 4px !important;
  margin: 0 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  line-height: 1 !important;
  flex: 0 0 auto !important;
  width: auto !important;
}

.filters {
  justify-content: flex-start !important;
}

@media (max-width: 480px) {
  .navbar { padding: 10px 12px !important; }
  .search-bar { padding: 10px 12px !important; }
  .filters { padding: 10px 12px !important; }
  
  .clear-filter {
    padding: 8px 12px !important;
    font-size: 11px !important;
    height: 36px !important;
  }
}

@media (min-width: 481px) and (max-width: 600px) {
  .navbar { padding: 12px 15px !important; }
  .search-bar { padding: 12px 15px !important; }
  .filters { padding: 12px 15px !important; }
}

@media (min-width: 601px) and (max-width: 768px) {
  .navbar { padding: 12px 15px !important; }
  .search-bar { padding: 15px !important; }
  .filters { padding: 15px !important; }
  
  .clear-filter {
    padding: 10px 15px !important;
    height: 40px !important;
  }
}

@media (min-width: 769px) {
  .navbar { padding: 15px 20px !important; }
  .search-bar { padding: 15px 20px !important; }
  .filters { padding: 15px 20px !important; }
}

.clear-filter {
  height: 28px !important;
  padding: 4px 10px !important;
  font-size: 12px !important;
  line-height: 1 !important;
  box-sizing: border-box !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-width: auto !important;
  max-width: fit-content !important;
}

@media (max-width: 480px) {
  .clear-filter {
    height: 26px !important;
    padding: 4px 8px !important;
    font-size: 10px !important;
  }
}

@media (min-width: 481px) and (max-width: 600px) {
  .clear-filter {
    height: 28px !important;
    padding: 4px 10px !important;
  }
}
.filters {
  background-color: white;
  padding: 15px 20px;
  display: flex;
  align-items: center;
  gap: 15px;
  border-bottom: 1px solid #ddd;
  border-radius: 5px;
  flex-wrap: nowrap;
}

.filters label {
  font-weight: 600;
  color: #333;
  font-size: 14px;
  white-space: nowrap;
  
}


/* Very Small Mobile (320px - 480px) */
@media (max-width: 480px) {
  .filters label {
    display: none;
  }
}

@media (min-width: 481px) and (max-width: 600px) {
  .filters label {
    display: none;
  }
}

@media (min-width: 601px) and (max-width: 768px) {
  .filters label {
    display: none;
  }
}

@media (min-width: 769px) and (max-width: 900px) {
  .filters label {
    display: none;
  }
}

/* Profile Modal Mobile Fixes */
.modal,
.modalpassword {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(5px);
  overflow: auto;
  justify-content: center;
  align-items: center;
}

.modal-content {
  background-color: #fff;
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
  width: 90%;
  max-width: 500px;
  position: relative;
  animation: slideDown 0.3s ease;
  box-sizing: border-box;
}

/* ========== MOBILE RESPONSIVE FIXES ========== */
@media (max-width: 480px) {
  .modal-content {
    width: 85%;
    max-width: 340px;
    padding: 20px;
    margin: 10px;
  }
  
  .modal-content h2 {
    font-size: 18px;
    margin-bottom: 15px;
  }
  
  .profile-info {
    padding: 15px;
    margin-bottom: 15px;
  }
  
  .profile-info p {
    font-size: 14px;
    margin: 8px 0;
  }
  
  .profile-actions {
    flex-direction: column;
    gap: 10px;
  }
  
  .btn-update,
  .btn-change,
  .btn-submit,
  .btn-cancel {
    width: 100%;
    padding: 10px 15px;
    font-size: 14px;
  }
  
  .modal-content form {
    gap: 12px;
  }
  
  .modal-content label {
    font-size: 13px;
  }
  
  .modal-content input {
    padding: 10px;
    font-size: 14px;
  }
  
  .close-modal,
  .close-update-modal,
  .close-password-modal {
    font-size: 24px;
    top: 10px;
    right: 15px;
  }
  
  .order-details {
    padding: 15px;
    margin: 15px 0;
  }
  
  .order-details p {
    font-size: 13px;
    margin: 8px 0;
    word-break: break-word;
  }
  
  .order-details strong {
    display: block;
    margin-bottom: 3px;
  }
  
  .order-details span {
    display: block;
    margin-left: 0;
  }
}

@media (min-width: 481px) and (max-width: 600px) {
  .modal-content {
    width: 88%;
    max-width: 400px;
    padding: 25px;
  }
  
  .modal-content h2 {
    font-size: 20px;
  }
  
  .profile-actions {
    flex-direction: column;
    gap: 10px;
  }
  
  .btn-update,
  .btn-change {
    width: 100%;
  }
}
@media (min-width: 601px) and (max-width: 768px) {
  .modal-content {
    width: 85%;
    max-width: 450px;
    padding: 28px;
  }
  
  .profile-actions {
    flex-direction: row;
    gap: 12px;
  }
}

@media (max-height: 500px) and (orientation: landscape) {
  .modal,
  .modalpassword {
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 10px 0;
  }
  
  .modal-content {
    margin: 20px auto;
    max-height: 90vh;
    overflow-y: auto;
  }
  
  .profile-info {
    padding: 12px;
    margin-bottom: 12px;
  }
}

@media (hover: none) and (pointer: coarse) {
  .btn-update,
  .btn-change,
  .btn-submit,
  .btn-cancel {
    min-height: 44px;
    touch-action: manipulation;
  }
  
  .close-modal,
  .close-update-modal,
  .close-password-modal {
    min-width: 44px;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
  }
}

@supports (padding: max(0px)) {
  .modal-content {
    margin-left: max(10px, env(safe-area-inset-left));
    margin-right: max(10px, env(safe-area-inset-right));
  }
}

.popupscreen#logoutConfirmPopup {
  width: 85%;
  max-width: 340px;
  padding: 25px;
  box-sizing: border-box;
}

@media (max-width: 480px) {
  .popupscreen#logoutConfirmPopup {
    width: 80%;
    max-width: 300px;
    padding: 20px;
  }
  
  .popupscreen#logoutConfirmPopup h2 {
    font-size: 18px;
    margin-bottom: 10px;
  }
  
  .popupscreen#logoutConfirmPopup p {
    font-size: 13px;
    margin: 10px 0;
  }
  
  .logout-buttons {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 15px;
  }
  
  .logout-buttons button {
    width: 100%;
    padding: 10px;
    font-size: 14px;
  }
}

@media (max-width: 480px) {
  .success-message-card {
    padding: 12px;
  }
  
  .successcheckmark-circle {
    width: 45px;
    height: 45px;
    font-size: 24px;
    margin-bottom: 10px;
  }
  
  .success-message-card h2 {
    font-size: 20px;
    margin-bottom: 5px;
  }
  
  .success-message-card p {
    font-size: 13px;
  }
}


@media (max-height: 600px) {
  .modal-content {
    max-height: 85vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  .profile-info,
  .order-details {
    max-height: 40vh;
    overflow-y: auto;
  }
}

@media (max-width: 480px) {
  .btn-close {
    width: 100%;
    padding: 12px;
    font-size: 14px;
    margin-top: 15px;
  }
}

.clear-filter {
  height: 40px !important;
  padding: 10px 14px !important;
  font-size: 13px !important;
  line-height: 1 !important;
  box-sizing: border-box !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-width: auto !important;
  max-width: fit-content !important;
}

@media (max-width: 480px) {
  .clear-filter {
    height: 36px !important;
    padding: 8px 10px !important;
    font-size: 11px !important;
  }
}

@media (min-width: 481px) and (max-width: 600px) {
  .clear-filter {
    height: 40px !important;
    padding: 10px 12px !important;
    font-size: 12px !important;
  }
}

.product-gender-tag {
  position: absolute;
  top: 5px;
  right: 5px;
  background-color: #607d8b;
  color: white;
  padding: 3px 6px;
  border-radius: 3px;
  font-size: 9px;
  z-index: 10;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.product-gender-tag.girl {
  background-color: #ff69b4;
}

.product-gender-tag.boy {
  background-color: #4169e1;
}

.product-gender-tag.unisex {
  background-color: #9c27b0;
}

.product-gender-tag.men {
  background-color: #2196f3;
}

.product-gender-tag.women {
  background-color: #e91e63;
}

@media (max-width: 768px) {
  .product-gender-tag {
    top: 4px;
    right: 4px;
    padding: 2px 5px;
    font-size: 8px;
    border-radius: 2px;
  }
}

@media (max-width: 480px) {
  .product-gender-tag {
    top: 3px;
    right: 3px;
    padding: 2px 4px;
    font-size: 7px;
  }
}

.cartquantity-controls {
    display: flex;
    justify-content: space-between;   
    align-items: center;
    width: 45%;
    flex-direction: row;
    margin-top: 10px;
    gap: 10px;                        
}

.cartquantity-selector {
    flex-shrink: 0;
    display: flex;
    align-items: center;
}

.cartitem-details-p {
    align-items: center; 
}

.remove-btn {
    height: 32px !important;             
    padding: 0 14px !important;          
    line-height: 32px !important;        
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-sizing: border-box !important;
}
.cartquantity-controls {
    align-items: center !important;   
}

.cart-item .remove-btn,
.remove-btn {
    height: auto !important;
    padding: 4px 8px !important;
    line-height: normal !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    background-color: red;
}
.cart-item .cart-actions {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    flex-wrap: nowrap !important;
}
.cart-quantity button,
.cart-quantity span {
    height: auto !important;
}



/* ========== SEARCH BAR HEIGHT FIX ========== */

.search-bar {
  display: flex;
  justify-content: space-between;
  padding: 15px 20px;
  background-color: white;
  border-bottom: 1px solid #ddd;
  flex-direction: row;
  gap: 10px;
  width: 100%;
  box-sizing: border-box;
  align-items: stretch; 
}

.searchinput {
  flex: 1;
  min-width: 0; 
  padding: 12px 15px;
  border: 1px solid #ccc;
  border-radius: 5px;
  font-size: 16px;
  box-sizing: border-box;
  height: 48px; 
  line-height: 1.5;
}

.search-button {
  flex-shrink: 0;
  padding: 12px 20px;
  background-color: #3f51b5;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 16px;
  white-space: nowrap;
  height: 48px; 
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  line-height: 1;
}

.search-button:hover {
  background-color: #303f9f;
}

.search-button:active {
  transform: scale(0.98);
}

/* ========== MOBILE RESPONSIVE ========== */
@media (max-width: 480px) {
  .search-bar {
    padding: 12px;
    gap: 8px;
  }
  
  .searchinput {
    padding: 10px 12px;
    font-size: 14px;
    height: 44px; 
  }
  
  .search-button {
    padding: 10px 15px;
    font-size: 14px;
    height: 44px; 
    min-width: 80px;
  }
}

@media (min-width: 481px) and (max-width: 600px) {
  .search-bar {
    padding: 12px 15px;
    gap: 8px;
  }
  
  .searchinput {
    padding: 11px 14px;
    font-size: 15px;
    height: 46px;
  }
  
  .search-button {
    padding: 11px 18px;
    font-size: 15px;
    height: 46px;
  }
}

@media (min-width: 601px) and (max-width: 768px) {
  .search-bar {
    padding: 15px;
    gap: 10px;
  }
  
  .searchinput {
    padding: 12px 15px;
    font-size: 16px;
    height: 48px;
  }
  
  .search-button {
    padding: 12px 20px;
    font-size: 16px;
    height: 48px;
  }
}

@media (min-width: 769px) {
  .search-bar {
    padding: 15px 20px;
    gap: 12px;
  }
  
  .searchinput {
    padding: 12px 15px;
    font-size: 16px;
    height: 48px;
    max-width: 600px; 
  }
  
  .search-button {
    padding: 12px 24px;
    font-size: 16px;
    height: 48px;
  }
}

/* ========== ALIGNMENT HELPERS ========== */
.bar {
  width: 100%;
  overflow-x: hidden;
  padding: 0;
  margin: 0;
}

.search-button {
  -webkit-appearance: none;
  appearance: none;
}

.searchinput {
  -webkit-appearance: none;
  appearance: none;
}

.searchinput:focus {
  outline: 2px solid #667eea;
  outline-offset: 2px;
  border-color: #667eea;
}

.search-button:focus {
  outline: 2px solid #667eea;
  outline-offset: 2px;
}

/* ========== PERFECT ALIGNMENT FIX ========== */
.searchinput,
.search-button {
  margin: 0 !important;
  vertical-align: middle;
}

.search-bar {
  align-items: center; 
}

@media (hover: none) and (pointer: coarse) {
  .searchinput,
  .search-button {
    min-height: 44px;
  }
}

@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
  .searchinput,
  .search-button {
    border-width: 0.5px; 
  }
}

@media (max-width: 480px) {
  .searchinput,
  .search-button {
    height: 44px !important;
    line-height: normal !important;
    box-sizing: border-box !important;
  }
  
  .search-bar {
    align-items: center !important;
  }
}

@media (min-width: 481px) and (max-width: 600px) {
  .searchinput,
  .search-button {
    height: 46px !important;
  }
}

@media (min-width: 601px) {
  .searchinput,
  .search-button {
    height: 48px !important;
  }
}



/* ========== POPUP CLOSE BUTTON FIX ========== */

.clear-btn {
  background: rgba(255, 255, 255, 0.2);
  border: none;
  width: 32px;
  height: 32px;
  min-width: 32px; 
  min-height: 32px;
  border-radius: 50%; 
  font-size: 20px;
  cursor: pointer;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  line-height: 1;
  padding: 0;
  flex-shrink: 0; 
}

.clear-btn:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: rotate(90deg);
}

.clear-btn:active {
  transform: rotate(90deg) scale(0.95);
}

@media (max-width: 768px) {
  .clear-btn {
    width: 32px;
    height: 32px;
    min-width: 32px;
    min-height: 32px;
    border-radius: 50%;
    padding: 0;
    font-size: 18px;
  }
}

@media (max-width: 480px) {
  .clear-btn {
    width: 30px;
    height: 30px;
    min-width: 30px;
    min-height: 30px;
    font-size: 16px;
  }
}

/* ========== FILTERS ROW - PERFECT HEIGHT ALIGNMENT ========== */

.filters {
  background-color: white;
  padding: 15px 20px;
  display: flex;
  align-items: center; 
  gap: 15px;
  border-bottom: 1px solid #ddd;
  border-radius: 0;
  width: 100%;
  box-sizing: border-box;
  flex-wrap: nowrap;
  overflow-x: auto;
}

.filters label {
  font-weight: 600;
  color: #333;
  font-size: 14px;
  white-space: nowrap;
  line-height: 40px; 
}

/* Filter Dropdowns - Fixed Height */
.filters select {
  flex: 0 0 auto;
  min-width: 120px;
  max-width: 150px;
  padding: 10px 12px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 14px;
  box-sizing: border-box;
  height: 40px; 
  line-height: normal;
  background-color: white;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  padding-right: 30px;
}

.filters select:hover {
  border-color: #3f51b5;
}

.filters select:focus {
  outline: 2px solid #667eea;
  outline-offset: 2px;
  border-color: #667eea;
}

/* ========== CLEAR FILTER BUTTON - MATCHING HEIGHT ========== */

.clear-filter {
  background-color: transparent;
  color: #3f51b5;
  border: none;
  cursor: pointer;
  padding: 10px 0;
  white-space: nowrap;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s ease;
  height: 40px; 
  line-height: 20px;
  display: inline-flex;
  align-items: center;
  box-sizing: border-box;
  flex-shrink: 0;
}

.clear-filter:hover {
  color: #303f9f;
}

.clear-filter:active {
  color: #1a237e;
}

/* ========== MOBILE RESPONSIVE - FILTERS ========== */

@media (max-width: 480px) {
  .filters {
    padding: 10px 12px;
    gap: 8px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  .filters label {
    display: none; 
  }
  
  .filters select {
    min-width: 90px;
    max-width: 110px;
    font-size: 13px;
    padding: 8px 10px;
    padding-right: 28px;
    height: 36px; 
  }
  
  .clear-filter {
    font-size: 13px;
    height: 36px; 
    padding: 8px 0;
    line-height: 20px;
  }
}

@media (min-width: 481px) and (max-width: 600px) {
  .filters {
    padding: 12px 15px;
    gap: 10px;
  }
  
  .filters label {
    display: none;
  }
  
  .filters select {
    min-width: 100px;
    max-width: 120px;
    font-size: 13px;
    height: 38px;
  }
  
  .clear-filter {
    font-size: 13px;
    height: 38px; 
    line-height: 18px;
  }
}

@media (min-width: 601px) and (max-width: 768px) {
  .filters {
    padding: 15px;
    gap: 12px;
  }
  
  .filters label {
    display: none;
  }
  
  .filters select {
    min-width: 110px;
    max-width: 130px;
    height: 40px;
  }
  
  .clear-filter {
    height: 40px;
  }
}

@media (min-width: 769px) and (max-width: 900px) {
  .filters {
    padding: 15px 20px;
    gap: 12px;
  }
  
  .filters label {
    display: none;
  }
  
  .filters select {
    height: 40px;
  }
  
  .clear-filter {
    height: 40px;
  }
}

@media (min-width: 901px) {
  .filters {
    padding: 15px 20px;
    gap: 15px;
  }
  
  .filters label {
    display: inline-block;
  }
  
  .filters select {
    height: 40px;
  }
  
  .clear-filter {
    height: 40px;
  }
}

/* ========== CRITICAL ALIGNMENT OVERRIDE ========== */

.filters {
  align-items: center !important;
}

.filters select,
.clear-filter {
  margin: 0 !important;
  vertical-align: middle !important;
}

@media (hover: none) and (pointer: coarse) {
  .filters select,
  .clear-filter {
    min-height: 36px;
  }
}

.searchinput {
  flex: 1;
  min-width: 0; 
  padding: 12px 15px;
  border: 1px solid #ccc;
  border-radius: 5px;
  font-size: 16px;
  box-sizing: border-box;
  height: 48px; 
  line-height: 1.5;
}

.search-button {
  flex-shrink: 0;
  padding: 12px 20px;
  background-color: #3f51b5;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 16px;
  white-space: nowrap;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  line-height: 1;
}

.search-button:hover {
  background-color: #303f9f;
}

.search-button:active {
  transform: scale(0.98);
}

/* ========== MOBILE RESPONSIVE ========== */

@media (max-width: 480px) {
  .search-bar {
    padding: 12px;
    gap: 8px;
  }
  
  .searchinput {
    padding: 10px 12px;
    font-size: 14px;
    height: 44px; 
  }
  
  .search-button {
    padding: 10px 15px;
    font-size: 14px;
    height: 44px; 
    min-width: 80px;
  }
}

@media (min-width: 481px) and (max-width: 600px) {
  .search-bar {
    padding: 12px 15px;
    gap: 8px;
  }
  
  .searchinput {
    padding: 11px 14px;
    font-size: 15px;
    height: 46px;
  }
  
  .search-button {
    padding: 11px 18px;
    font-size: 15px;
    height: 46px;
  }
}

@media (min-width: 601px) and (max-width: 768px) {
  .search-bar {
    padding: 15px;
    gap: 10px;
  }
  
  .searchinput {
    padding: 12px 15px;
    font-size: 16px;
    height: 48px;
  }
  
  .search-button {
    padding: 12px 20px;
    font-size: 16px;
    height: 48px;
  }
}


@media (min-width: 769px) {
  .search-bar {
    padding: 15px 20px;
    gap: 12px;
  }
  
  .searchinput {
    padding: 12px 15px;
    font-size: 16px;
    height: 48px;
    max-width: 600px; 
  }
  
  .search-button {
    padding: 12px 24px;
    font-size: 16px;
    height: 48px;
  }
}

/* ========== ALIGNMENT HELPERS ========== */
.bar {
  width: 100%;
  overflow-x: hidden;
  padding: 0;
  margin: 0;
}


.search-button {
  -webkit-appearance: none;
  appearance: none;
}
.searchinput {
  -webkit-appearance: none;
  appearance: none;
}

.searchinput:focus {
  outline: 2px solid #667eea;
  outline-offset: 2px;
  border-color: #667eea;
}

.search-button:focus {
  outline: 2px solid #667eea;
  outline-offset: 2px;
}

/* ========== PERFECT ALIGNMENT FIX ========== */

.searchinput,
.search-button {
  margin: 0 !important;
  vertical-align: middle;
}

.search-bar {
  align-items: center; 
}


@media (hover: none) and (pointer: coarse) {
  .searchinput,
  .search-button {
    min-height: 44px;
  }
}

@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
  .searchinput,
  .search-button {
    border-width: 0.5px; 
  }
}


@media (max-width: 480px) {
  .searchinput,
  .search-button {
    height: 44px !important;
    line-height: normal !important;
    box-sizing: border-box !important;
  }
  
  .search-bar {
    align-items: center !important;
  }
}

@media (min-width: 481px) and (max-width: 600px) {
  .searchinput,
  .search-button {
    height: 46px !important;
  }
}

@media (min-width: 601px) {
  .searchinput,
  .search-button {
    height: 48px !important;
  }
}


.bar {
  width: 100%;
  overflow-x: hidden;
  padding: 0;
  margin: 0;
}

.search-bar {
  display: flex;
  justify-content: space-between;
  padding: 15px 20px;
  background-color: white;
  border-bottom: 1px solid #ddd;
  flex-direction: row;
  gap: 10px;
  width: 100%;
  box-sizing: border-box;
  align-items: center;
}

/* Search Input */
.searchinput {
  flex: 1;
  min-width: 0;
  padding: 12px 15px;
  border: 1px solid #ccc;
  border-radius: 5px;
  font-size: 16px;
  box-sizing: border-box;
  height: 48px;
  line-height: 1.5;
  -webkit-appearance: none;
  appearance: none;
}

.searchinput:focus {
  outline: 2px solid #667eea;
  outline-offset: 2px;
  border-color: #667eea;
}


.search-button {
  flex-shrink: 0;
  padding: 12px 20px;
  background-color: #3f51b5;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 16px;
  white-space: nowrap;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  line-height: 1;
  -webkit-appearance: none;
  appearance: none;
}

.search-button:hover {
  background-color: #303f9f;
}

.search-button:active {
  transform: scale(0.98);
}

.search-button:focus {
  outline: 2px solid #667eea;
  outline-offset: 2px;
}

/* ========== FILTERS SECTION ========== */

.filters {
  background-color: white;
  padding: 15px 20px;
  display: flex;
  align-items: center;
  gap: 15px;
  border-bottom: 1px solid #ddd;
  border-radius: 0;
  width: 100%;
  box-sizing: border-box;
  flex-wrap: nowrap; 
  overflow-x: visible; 
}

.filters label {
  font-weight: 600;
  color: #333;
  font-size: 14px;
  white-space: nowrap;
  line-height: 40px;
  flex-shrink: 0;
}

.filters select {
  flex: 1 1 0; 
  min-width: 0; 
  max-width: none;
  padding: 8px 4px;
  padding-right: 20px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 14px;
  box-sizing: border-box;
  height: 40px;
  line-height: normal;
  background-color: white;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 4px center;
  background-size: 10px;
}

.filters select:hover {
  border-color: #3f51b5;
}

.filters select:focus {
  outline: 2px solid #667eea;
  outline-offset: 2px;
  border-color: #667eea;
}
.clear-filter {
  background-color: transparent;
  color: #3f51b5;
  border: none;
  cursor: pointer;
  padding: 8px 4px;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s ease;
  height: 40px;
  line-height: 24px;
  display: inline-flex;
  align-items: center;
  box-sizing: border-box;
  flex: 0 0 auto; 
}

.clear-filter:hover {
  color: #303f9f;
}

.clear-filter:active {
  color: #1a237e;
}

.clear-filter:focus {
  outline: 2px solid #667eea;
  outline-offset: 2px;
}

.popup-header {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 25px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  flex-shrink: 0;
}

.popup-header h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
}

.clear-btn {
  background: rgba(255, 255, 255, 0.2);
  border: none;
  width: 36px;
  height: 36px;
  min-width: 36px;
  min-height: 36px;
  max-width: 36px;
  max-height: 36px;
  border-radius: 50%;
  font-size: 24px;
  font-weight: 300;
  cursor: pointer;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  line-height: 1;
  padding: 0;
  flex-shrink: 0;
  aspect-ratio: 1 / 1;
}

.clear-btn:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: rotate(90deg);
}

.clear-btn:active {
  transform: rotate(90deg) scale(0.95);
}

/* ========== RESPONSIVE - MOBILE ========== */
@media (max-width: 480px) {
  .search-bar {
    padding: 10px 12px;
    gap: 8px;
  }
  
  .searchinput {
    padding: 10px 12px;
    font-size: 14px;
    height: 44px;
  }
  
  .search-button {
    padding: 10px 15px;
    font-size: 14px;
    height: 44px;
    min-width: 80px;
  }
  
  .filters {
    padding: 8px 10px;
    gap: 3px;
    flex-wrap: nowrap;
    overflow: hidden;
    max-width: 100%;
  }
  
  .filters label {
    display: none; 
  }
  
  .filters select {
    flex: 1 1 0;
    min-width: 0;
    max-width: 100%;
    font-size: 10px;
    padding: 4px 1px;
    padding-right: 14px;
    height: 30px;
    background-position: right 1px center;
    background-size: 7px;
    border-width: 1px;
    text-overflow: ellipsis;
    overflow: hidden;
    white-space: nowrap;
  }
  
  .filters select option {
    font-size: 12px; 
  }
  
  .clear-filter {
    flex: 0 0 auto;
    font-size: 9px;
    height: 30px;
    padding: 4px 4px;
    line-height: 22px;
    max-width: 60px;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .popup-header {
    padding: 18px 12px;
  }
  
  .popup-header h2 {
    font-size: 16px;
    gap: 6px;
  }
  
  .clear-btn {
    width: 30px;
    height: 30px;
    min-width: 30px;
    min-height: 30px;
    max-width: 30px;
    max-height: 30px;
    font-size: 20px;
  }
}

@media (max-width: 360px) {
  .filters {
    padding: 6px 8px;
    gap: 2px;
  }
  
  .filters select {
    font-size: 9px;
    padding: 3px 1px;
    padding-right: 12px;
    height: 28px;
    background-size: 6px;
  }
  
  .clear-filter {
    font-size: 8px;
    height: 28px;
    padding: 3px 3px;
    max-width: 50px;
  }
}

@media (min-width: 481px) and (max-width: 600px) {
  .search-bar {
    padding: 12px 15px;
    gap: 8px;
  }
  
  .searchinput {
    padding: 11px 14px;
    font-size: 15px;
    height: 46px;
  }
  
  .search-button {
    padding: 11px 18px;
    font-size: 15px;
    height: 46px;
  }
  .filters {
    padding: 10px 12px;
    gap: 4px;
    flex-wrap: nowrap;
    overflow: hidden;
    max-width: 100%;
  }
  
  .filters label {
    display: none;
  }
  
  .filters select {
    flex: 1 1 0;
    min-width: 0;
    max-width: 100%;
    font-size: 11px;
    padding: 5px 2px;
    padding-right: 16px;
    height: 34px;
    background-position: right 2px center;
    background-size: 8px;
    text-overflow: ellipsis;
    overflow: hidden;
  }
  
  .filters select option {
    font-size: 13px;
  }
  
  .clear-filter {
    flex: 0 0 auto;
    font-size: 10px;
    height: 34px;
    padding: 5px 6px;
    max-width: 70px;
  }
}
@media (min-width: 601px) and (max-width: 768px) {
  .search-bar {
    padding: 15px;
    gap: 10px;
  }
  
  .searchinput {
    padding: 12px 15px;
    font-size: 16px;
    height: 48px;
  }
  
  .search-button {
    padding: 12px 20px;
    font-size: 16px;
    height: 48px;
  }
  
  .filters {
    padding: 15px;
    gap: 12px;
  }
  
  .filters label {
    display: none;
  }
  
  .filters select {
    min-width: 110px;
    max-width: 130px;
    height: 40px;
  }
  
  .clear-filter {
    height: 40px;
  }
  
  .popup-header {
    padding: 20px 15px;
  }
  
  .popup-header h2 {
    font-size: 18px;
  }
  
  .clear-btn {
    width: 32px;
    height: 32px;
    min-width: 32px;
    min-height: 32px;
    max-width: 32px;
    max-height: 32px;
    font-size: 22px;
  }
}

@media (min-width: 769px) and (max-width: 900px) {
  .filters label {
    display: none;
  }
}


@media (min-width: 901px) {
  .filters label {
    display: inline-block; 
  }
}

@media (min-width: 769px) {
  .search-bar {
    padding: 15px 20px;
    gap: 12px;
  }
  
  .searchinput {
    max-width: 600px;
  }
  
  .search-button {
    padding: 12px 24px;
  }
  
  .filters {
    padding: 15px 20px;
    gap: 15px;
  }
}


@media (hover: none) and (pointer: coarse) {
  .searchinput,
  .search-button {
    min-height: 44px;
  }
  
  .filters select,
  .clear-filter {
    min-height: 36px;
  }
  
  .clear-btn {
    width: 40px;
    height: 40px;
    min-width: 40px;
    min-height: 40px;
    max-width: 40px;
    max-height: 40px;
  }
}


@supports (padding: max(0px)) {
  .search-bar,
  .filters {
    padding-left: max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
  }
}

.search-bar,
.filters {
  align-items: center !important;
}

.searchinput,
.search-button,
.filters select,
.clear-filter {
  margin: 0 !important;
  vertical-align: middle !important;
}


.bar {
  width: 100%;
  overflow-x: hidden;
  padding: 0;
  margin: 0;
}

.search-bar {
  display: flex;
  justify-content: space-between;
  padding: 15px 20px;
  background-color: white;
  border-bottom: 1px solid #ddd;
  flex-direction: row;
  gap: 10px;
  width: 100%;
  box-sizing: border-box;
  align-items: center; 
}

.searchinput {
  flex: 1;
  min-width: 0;
  padding: 12px 15px;
  border: 1px solid #ccc;
  border-radius: 5px;
  font-size: 16px;
  box-sizing: border-box;
  height: 48px;
  line-height: 1.5;
  -webkit-appearance: none;
  appearance: none;
}

.searchinput:focus {
  outline: 2px solid #667eea;
  outline-offset: 2px;
  border-color: #667eea;
}

.search-button {
  flex-shrink: 0;
  padding: 12px 20px;
  background-color: #3f51b5;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 16px;
  white-space: nowrap;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  line-height: 1;
  -webkit-appearance: none;
  appearance: none;
}

.search-button:hover {
  background-color: #303f9f;
}

.search-button:active {
  transform: scale(0.98);
}

.search-button:focus {
  outline: 2px solid #667eea;
  outline-offset: 2px;
}

/* ========== FILTERS SECTION ========== */

.filters {
  background-color: white;
  padding: 15px 20px;
  display: flex;
  align-items: center;
  gap: 15px;
  border-bottom: 1px solid #ddd;
  border-radius: 0;
  width: 100%;
  box-sizing: border-box;
  flex-wrap: nowrap; 
  overflow-x: visible;
}

.filters label {
  font-weight: 600;
  color: #333;
  font-size: 14px;
  white-space: nowrap;
  line-height: 40px;
  flex-shrink: 0;
}

.filters select {
  flex: 1 1 0; 
  min-width: 0; 
  max-width: none;
  padding: 8px 4px;
  padding-right: 20px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 14px;
  box-sizing: border-box;
  height: 40px;
  line-height: normal;
  background-color: white;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 4px center;
  background-size: 10px;
}

.filters select:hover {
  border-color: #3f51b5;
}

.filters select:focus {
  outline: 2px solid #667eea;
  outline-offset: 2px;
  border-color: #667eea;
}

/* Clear Filter Button */
.clear-filter {
  background-color: transparent;
  color: #3f51b5;
  border: none;
  cursor: pointer;
  padding: 8px 4px;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s ease;
  height: 40px;
  line-height: 24px;
  display: inline-flex;
  align-items: center;
  box-sizing: border-box;
  flex: 0 0 auto; 
}

.clear-filter:hover {
  color: #303f9f;
}

.clear-filter:active {
  color: #1a237e;
}

.clear-filter:focus {
  outline: 2px solid #667eea;
  outline-offset: 2px;
}

/* ========== SHOPPING CART POPUP ========== */

.popup-header {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 25px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  flex-shrink: 0;
}

.popup-header h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
}

.clear-btn {
  background: rgba(255, 255, 255, 0.2);
  border: none;
  width: 36px;
  height: 36px;
  min-width: 36px;
  min-height: 36px;
  max-width: 36px;
  max-height: 36px;
  border-radius: 50%;
  font-size: 24px;
  font-weight: 300;
  cursor: pointer;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  line-height: 1;
  padding: 0;
  flex-shrink: 0;
  aspect-ratio: 1 / 1;
}

.clear-btn:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: rotate(90deg);
}

.clear-btn:active {
  transform: rotate(90deg) scale(0.95);
}

/* ========== RESPONSIVE - MOBILE ========== */

/* Very Small Mobile (320px - 480px) */
@media (max-width: 480px) {
  .search-bar {
    padding: 10px 12px;
    gap: 8px;
  }
  
  .searchinput {
    padding: 10px 12px;
    font-size: 14px;
    height: 44px;
  }
  
  .search-button {
    padding: 10px 15px;
    font-size: 14px;
    height: 44px;
    min-width: 80px;
  }
  
  /* Filters - */
  .filters {
    padding: 8px 10px;
    gap: 6px;
    flex-wrap: nowrap;
    overflow: hidden;
    max-width: 100%;
  }
  
  .filters label {
    display: none; /
  }
  
  .filters select {
    flex: 1 1 0;
    min-width: 0;
    max-width: 100%;
    font-size: 12px;
    padding: 6px 4px;
    padding-right: 18px;
    height: 34px;
    background-position: right 4px center;
    background-size: 8px;
    border-width: 1px;
    text-overflow: ellipsis;
    overflow: hidden;
    white-space: nowrap;
  }
  
  .filters select option {
    font-size: 14px;
  }
  
  .clear-filter {
    flex: 0 0 auto;
    font-size: 11px;
    height: 34px;
    padding: 6px 8px;
    line-height: 22px;
    max-width: none;
    overflow: visible;
    white-space: nowrap;
  }
  
  .popup-header {
    padding: 18px 12px;
  }
  
  .popup-header h2 {
    font-size: 16px;
    gap: 6px;
  }
  
  .clear-btn {
    width: 30px;
    height: 30px;
    min-width: 30px;
    min-height: 30px;
    max-width: 30px;
    max-height: 30px;
    font-size: 20px;
  }
}

@media (max-width: 360px) {
  .filters {
    padding: 6px 8px;
    gap: 4px;
  }
  
  .filters select {
    font-size: 11px;
    padding: 5px 3px;
    padding-right: 16px;
    height: 32px;
    background-size: 7px;
  }
  
  .clear-filter {
    font-size: 10px;
    height: 32px;
    padding: 5px 6px;
  }
}

@media (min-width: 481px) and (max-width: 600px) {
  .search-bar {
    padding: 12px 15px;
    gap: 8px;
  }
  
  .searchinput {
    padding: 11px 14px;
    font-size: 15px;
    height: 46px;
  }
  
  .search-button {
    padding: 11px 18px;
    font-size: 15px;
    height: 46px;
  }
  
  .filters {
    padding: 10px 12px;
    gap: 6px;
    flex-wrap: nowrap;
    overflow: hidden;
    max-width: 100%;
  }
  
  .filters label {
    display: none;
  }
  
  .filters select {
    flex: 1 1 0;
    min-width: 0;
    max-width: 100%;
    font-size: 12px;
    padding: 6px 4px;
    padding-right: 18px;
    height: 36px;
    background-position: right 4px center;
    background-size: 8px;
    text-overflow: ellipsis;
    overflow: hidden;
  }
  
  .filters select option {
    font-size: 14px;
  }
  
  .clear-filter {
    flex: 0 0 auto;
    font-size: 11px;
    height: 36px;
    padding: 6px 8px;
    max-width: none;
  }
}

@media (min-width: 601px) and (max-width: 768px) {
  .search-bar {
    padding: 15px;
    gap: 10px;
  }
  
  .searchinput {
    padding: 12px 15px;
    font-size: 16px;
    height: 48px;
  }
  
  .search-button {
    padding: 12px 20px;
    font-size: 16px;
    height: 48px;
  }
  .filters {
    padding: 15px;
    gap: 12px;
  }
  
  .filters label {
    display: none;
  }
  
  .filters select {
    min-width: 110px;
    max-width: 130px;
    height: 40px;
  }
  
  .clear-filter {
    height: 40px;
  }
  
  .popup-header {
    padding: 20px 15px;
  }
  
  .popup-header h2 {
    font-size: 18px;
  }
  
  .clear-btn {
    width: 32px;
    height: 32px;
    min-width: 32px;
    min-height: 32px;
    max-width: 32px;
    max-height: 32px;
    font-size: 22px;
  }
}
@media (min-width: 769px) and (max-width: 900px) {
  .filters label {
    display: none;
  }
}

@media (min-width: 901px) {
  .filters label {
    display: inline-block; 
  }
}

@media (min-width: 769px) {
  .search-bar {
    padding: 15px 20px;
    gap: 12px;
  }
  
  .searchinput {
    max-width: 600px;
  }
  
  .search-button {
    padding: 12px 24px;
  }
  
  .filters {
    padding: 15px 20px;
    gap: 15px;
  }
}


@media (hover: none) and (pointer: coarse) {
  .searchinput,
  .search-button {
    min-height: 44px;
  }
  
  .filters select,
  .clear-filter {
    min-height: 36px;
  }
  
  .clear-btn {
    width: 40px;
    height: 40px;
    min-width: 40px;
    min-height: 40px;
    max-width: 40px;
    max-height: 40px;
  }
}


@supports (padding: max(0px)) {
  .search-bar,
  .filters {
    padding-left: max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
  }
}
.search-bar,
.filters {
  align-items: center !important;
}

.searchinput,
.search-button,
.filters select,
.clear-filter {
  margin: 0 !important;
  vertical-align: middle !important;
}


/* ========== SEARCH BAR SECTION ========== */

.bar {
  width: 100%;
  overflow-x: hidden;
  padding: 0;
  margin: 0;
}

.search-bar {
  display: flex;
  justify-content: space-between;
  padding: 15px 20px;
  background-color: white;
  border-bottom: 1px solid #ddd;
  flex-direction: row;
  gap: 10px;
  width: 100%;
  box-sizing: border-box;
  align-items: center; 
}


.searchinput {
  flex: 1;
  min-width: 0;
  padding: 12px 15px;
  border: 1px solid #ccc;
  border-radius: 5px;
  font-size: 16px;
  box-sizing: border-box;
  height: 48px;
  line-height: 1.5;
  -webkit-appearance: none;
  appearance: none;
}

.searchinput:focus {
  outline: 2px solid #667eea;
  outline-offset: 2px;
  border-color: #667eea;
}

.search-button {
  flex-shrink: 0;
  padding: 12px 20px;
  background-color: #3f51b5;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 16px;
  white-space: nowrap;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  line-height: 1;
  -webkit-appearance: none;
  appearance: none;
}

.search-button:hover {
  background-color: #303f9f;
}

.search-button:active {
  transform: scale(0.98);
}

.search-button:focus {
  outline: 2px solid #667eea;
  outline-offset: 2px;
}

/* ========== FILTERS SECTION ========== */

.filters {
  background-color: white;
  padding: 15px 20px;
  display: flex;
  align-items: center;
  gap: 15px;
  border-bottom: 1px solid #ddd;
  border-radius: 0;
  width: 100%;
  box-sizing: border-box;
  flex-wrap: nowrap; 
  overflow-x: visible; 
}

/* Filter Labels */
.filters label {
  font-weight: 600;
  color: #333;
  font-size: 14px;
  white-space: nowrap;
  line-height: 40px;
  flex-shrink: 0;
}

/* Filter Dropdowns */
.filters select {
  flex: 0 1 auto; 
  min-width: 140px; 
  max-width: 180px; 
  padding: 10px 12px;
  padding-right: 30px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 14px;
  box-sizing: border-box;
  height: 40px;
  line-height: 1;
  background-color: white;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 8px center;
  background-size: 10px;
  display: inline-flex;
  align-items: center;
  vertical-align: middle;
  margin: 0;
}

.filters select:hover {
  border-color: #3f51b5;
}

.filters select:focus {
  outline: 2px solid #667eea;
  outline-offset: 2px;
  border-color: #667eea;
}


.clear-filter {
  background-color: transparent;
  color: #3f51b5;
  border: none;
  cursor: pointer;
  padding: 8px 4px;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s ease;
  height: 40px;
  line-height: 24px;
  display: inline-flex;
  align-items: center;
  box-sizing: border-box;
  flex: 0 0 auto; 
}

.clear-filter:hover {
  color: #303f9f;
}

.clear-filter:active {
  color: #1a237e;
}

.clear-filter:focus {
  outline: 2px solid #667eea;
  outline-offset: 2px;
}

/* ========== SHOPPING CART POPUP ========== */

.popup-header {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 25px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  flex-shrink: 0;
}

.popup-header h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
}

.clear-btn {
  background: rgba(255, 255, 255, 0.2);
  border: none;
  width: 36px;
  height: 36px;
  min-width: 36px;
  min-height: 36px;
  max-width: 36px;
  max-height: 36px;
  border-radius: 50%;
  font-size: 24px;
  font-weight: 300;
  cursor: pointer;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  line-height: 1;
  padding: 0;
  flex-shrink: 0;
  aspect-ratio: 1 / 1;
}

.clear-btn:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: rotate(90deg);
}

.clear-btn:active {
  transform: rotate(90deg) scale(0.95);
}

/* ========== RESPONSIVE - MOBILE ========== */
@media (max-width: 480px) {
  .search-bar {
    padding: 10px 12px;
    gap: 8px;
  }
  
  .searchinput {
    padding: 10px 12px;
    font-size: 14px;
    height: 44px;
  }
  
  .search-button {
    padding: 10px 15px;
    font-size: 14px;
    height: 44px;
    min-width: 80px;
  }
  
  /* Filters  */
  .filters {
    padding: 8px 10px;
    gap: 6px;
    flex-wrap: nowrap;
    overflow: hidden;
    max-width: 100%;
    align-items: center;
  }
  
  .filters label {
    display: none;
  }
  
  .filters select {
    flex: 1 1 0;
    min-width: 0;
    max-width: 100%;
    font-size: 12px;
    padding: 0 4px;
    padding-right: 18px;
    height: 36px;
    line-height: 36px;
    background-position: right 4px center;
    background-size: 8px;
    border-width: 1px;
    text-overflow: ellipsis;
    overflow: hidden;
    white-space: nowrap;
    box-sizing: border-box;
    margin: 0;
    display: block;
  }
  
  .filters select option {
    font-size: 14px;
  }
  
  .clear-filter {
    flex: 0 0 auto;
    font-size: 11px;
    height: 36px;
    line-height: 36px;
    padding: 0 10px;
    max-width: none;
    overflow: visible;
    white-space: nowrap;
    box-sizing: border-box;
    display: block;
    text-align: center;
    margin: 0;
  }
  
  .popup-header {
    padding: 18px 12px;
  }
  
  .popup-header h2 {
    font-size: 16px;
    gap: 6px;
  }
  
  .clear-btn {
    width: 30px;
    height: 30px;
    min-width: 30px;
    min-height: 30px;
    max-width: 30px;
    max-height: 30px;
    font-size: 20px;
  }
}

@media (max-width: 360px) {
  .filters {
    padding: 6px 8px;
    gap: 4px;
    align-items: center;
  }
  
  .filters select {
    font-size: 11px;
    padding: 0 3px;
    padding-right: 16px;
    height: 34px;
    line-height: 34px;
    background-size: 7px;
  }
  
  .clear-filter {
    font-size: 10px;
    height: 34px;
    line-height: 34px;
    padding: 0 6px;
  }
}

@media (min-width: 481px) and (max-width: 600px) {

  .search-bar {
    padding: 12px 15px;
    gap: 8px;
  }
  
  .searchinput {
    padding: 11px 14px;
    font-size: 15px;
    height: 46px;
  }
  
  .search-button {
    padding: 11px 18px;
    font-size: 15px;
    height: 46px;
  }
  
  /* Filters  */
  .filters {
    padding: 10px 12px;
    gap: 6px;
    flex-wrap: nowrap;
    overflow: hidden;
    max-width: 100%;
    align-items: center;
  }
  
  .filters label {
    display: none;
  }
  
  .filters select {
    flex: 1 1 0;
    min-width: 0;
    max-width: 100%;
    font-size: 12px;
    padding: 0 4px;
    padding-right: 18px;
    height: 38px;
    line-height: 38px;
    background-position: right 4px center;
    background-size: 8px;
    text-overflow: ellipsis;
    overflow: hidden;
    box-sizing: border-box;
    margin: 0;
    display: block;
  }
  
  .filters select option {
    font-size: 14px;
  }
  
  .clear-filter {
    flex: 0 0 auto;
    font-size: 11px;
    height: 38px;
    line-height: 38px;
    padding: 0 10px;
    max-width: none;
    box-sizing: border-box;
    display: block;
    text-align: center;
    margin: 0;
  }
}

@media (min-width: 601px) and (max-width: 768px) {
  .search-bar {
    padding: 15px;
    gap: 10px;
  }
  
  .searchinput {
    padding: 12px 15px;
    font-size: 16px;
    height: 48px;
  }
  
  .search-button {
    padding: 12px 20px;
    font-size: 16px;
    height: 48px;
  }
  
  .filters {
    padding: 15px;
    gap: 12px;
  }
  
  .filters label {
    display: none;
  }
  
  .filters select {
    min-width: 110px;
    max-width: 130px;
    height: 40px;
  }
  
  .clear-filter {
    height: 40px;
  }
  
  .popup-header {
    padding: 20px 15px;
  }
  
  .popup-header h2 {
    font-size: 18px;
  }
  
  .clear-btn {
    width: 32px;
    height: 32px;
    min-width: 32px;
    min-height: 32px;
    max-width: 32px;
    max-height: 32px;
    font-size: 22px;
  }
}

@media (min-width: 769px) and (max-width: 900px) {
  .filters label {
    display: none;
  }
}

@media (min-width: 901px) {
  .filters label {
    display: inline-block; 
  }
}

@media (min-width: 769px) {
  .search-bar {
    padding: 15px 20px;
    gap: 12px;
  }
  
  .searchinput {
    flex: 4; 
    min-width: 400px;
    max-width: none; 
  }
  
  .search-button {
    flex-shrink: 0;
  }
  
  .filters {
    padding: 15px 20px;
    gap: 15px;
  }
  
  .filters select {
    flex: 0 1 auto; 
    min-width: 140px;
    max-width: 180px; 
  }
  
  .clear-filter {
    flex: 0 0 auto; 
  }
}

@media (min-width: 1200px) {
  .searchinput {
    flex: 5; 
    min-width: 500px;
    max-width: none; 
  }
  
  .filters select {
    min-width: 150px;
    max-width: 200px;
  }
}

@media (min-width: 1600px) {
  .searchinput {
    flex: 6; 
    min-width: 600px;
  }
}

/* ========== TOUCH DEVICE IMPROVEMENTS ========== */

@media (hover: none) and (pointer: coarse) {
  .searchinput,
  .search-button {
    min-height: 44px;
  }
  
  .filters select,
  .clear-filter {
    min-height: 36px;
  }
  
  .clear-btn {
    width: 40px;
    height: 40px;
    min-width: 40px;
    min-height: 40px;
    max-width: 40px;
    max-height: 40px;
  }
}


@supports (padding: max(0px)) {
  .search-bar,
  .filters {
    padding-left: max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
  }
}

/* ========== CRITICAL OVERRIDES ========== */

.search-bar,
.filters {
  align-items: center !important;
}

.searchinput,
.search-button {
  margin: 0 !important;
  vertical-align: middle !important;
  box-sizing: border-box !important;
}

.filters select,
.clear-filter {
  margin: 0 !important;
  box-sizing: border-box !important;
  vertical-align: middle !important;
  border: 1px solid #ccc !important;
}


@media (min-width: 769px) {
  .filters select,
  .clear-filter {
    height: 40px !important;
    line-height: 1 !important;
  }
}

@media (max-width: 480px) {
  .filters select,
  .clear-filter {
    height: 36px !important;
    line-height: 36px !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    display: block !important;
  }
}

@media (max-width: 360px) {
  .filters select,
  .clear-filter {
    height: 34px !important;
    line-height: 34px !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
  }
}

@media (min-width: 481px) and (max-width: 600px) {
  .filters select,
  .clear-filter {
    height: 38px !important;
    line-height: 38px !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    display: block !important;
  }
}

@media (min-width: 601px) and (max-width: 768px) {
  .filters select,
  .clear-filter {
    height: 40px !important;
    line-height: 1 !important;
  }
}




/* ========== CART QUANTITY CONTROLS - EXTRA COMPACT MOBILE ========== */

.cartqty-btn-separate {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  border: none !important;
  outline: none !important;
  width: 20px;
  height: 20px;
  border-radius: 20px;
  color: white;
  font-size: 12px;
  font-weight: bold;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  padding: 0 !important;
  margin: 0 !important;
  line-height: 1;
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.25);
  transition: all 0.2s ease;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}

.cartqty-label {
  font-size: 10px;
  font-weight: 600;
  color: #2d3748;
  min-width: 35px;
  text-align: center;
  background: transparent;
  padding: 0 !important;
  line-height: 20px;
}

.remove-btn {
  background: linear-gradient(135deg, #f56565 0%, #e53e3e 100%);
  color: white;
  border: none !important;
  outline: none !important;
  border-radius: 20px;
  cursor: pointer;
  font-size: 9px;
  height: 20px;
  padding: 0 5px !important;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
  flex-shrink: 0;
  line-height: 1;
  box-shadow: 0 2px 8px rgba(245, 101, 101, 0.25);
  transition: all 0.2s ease;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}

.trash-icon {
  font-size: 8px;
  line-height: 1;
}

.cartquantity-controls {
  display: flex;
  align-items: center;
  gap: 3px;
  margin-top: 4px;
  padding-top: 4px;
}

.cartquantity-selector {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 0;
  background: transparent;
}

/* ========== MOBILE - HALF SIZE ========== */

@media (max-width: 768px) {
  .cartquantity-controls {
    gap: 1.5px;
    margin-top: 2px;
    padding-top: 2px;
  }
  
  .cartquantity-selector {
    gap: 1px;
  }
  
  .cartqty-btn-separate {
    width: 10px !important;
    height: 10px !important;
    font-size: 6px !important;
    min-width: 10px;
    border: none !important;
    border-radius: 10px !important;
    padding: 0 !important;
  }
  
  .cartqty-label {
    font-size: 5px !important;
    min-width: 17px !important;
    line-height: 10px !important;
    padding: 0 !important;
  }
  
  .remove-btn {
    height: 10px !important;
    font-size: 4.5px !important;
    padding: 0 2px !important;
    border-radius: 10px !important;
    gap: 0.5px;
    border: none !important;
  }
  
  .trash-icon {
    font-size: 4px !important;
  }
}

/* Small Mobile */
@media (max-width: 480px) {
  .cartquantity-controls {
    gap: 1px;
    margin-top: 1.5px;
    padding-top: 1.5px;
  }
  
  .cartquantity-selector {
    gap: 1px;
  }
  
  .cartqty-btn-separate {
    width: 10px !important;
    height: 10px !important;
    font-size: 6px !important;
    min-width: 10px;
    border: none !important;
    border-radius: 10px !important;
    padding: 0 !important;
  }
  
  .cartqty-label {
    font-size: 5px !important;
    min-width: 17px !important;
    line-height: 10px !important;
    padding: 0 !important;
  }
  
  .remove-btn {
    height: 10px !important;
    font-size: 4.5px !important;
    padding: 0 2px !important;
    border-radius: 10px !important;
    gap: 0.5px;
    border: none !important;
  }
  
  .trash-icon {
    font-size: 4px !important;
  }
}

/* Extra Small Mobile */
@media (max-width: 360px) {
  .cartqty-btn-separate {
    width: 10px !important;
    height: 10px !important;
    font-size: 6px !important;
    min-width: 10px;
    border: none !important;
    border-radius: 10px !important;
    padding: 0 !important;
  }
  
  .cartqty-label {
    font-size: 5px !important;
    min-width: 17px !important;
    line-height: 10px !important;
    padding: 0 !important;
  }
  
  .remove-btn {
    height: 10px !important;
    font-size: 4.5px !important;
    padding: 0 2px !important;
    border-radius: 10px !important;
    border: none !important;
  }
  
  .trash-icon {
    font-size: 4px !important;
  }
}

/* ========== HOVER EFFECTS ========== */

.cartqty-btn-separate:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.cartqty-btn-separate:active {
  transform: scale(0.95);
}

.remove-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(245, 101, 101, 0.4);
}

.remove-btn:active {
  transform: translateY(0);
}

@media (max-width: 768px) {
  .cartqty-btn-separate:hover {
    transform: scale(1.05);
  }
  
  .remove-btn:hover {
    transform: translateY(-1px);
  }
}

/* ========== CRITICAL ALIGNMENT & BOX REMOVAL ========== */

.cartquantity-selector,
.cartquantity-controls {
  align-items: center !important;
}

.cartqty-btn-separate,
.cartqty-label,
.remove-btn {
  margin: 0 !important;
  box-sizing: border-box !important;
  vertical-align: middle !important;
}

.cartqty-btn-separate:focus,
.remove-btn:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2);
}

.remove-btn:focus {
  box-shadow: 0 0 0 3px rgba(245, 101, 101, 0.2);
}


input.cartqty-btn-separate,
input.remove-btn,
button.cartqty-btn-separate,
button.remove-btn {
  appearance: none !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  border: none !important;
  box-sizing: border-box !important;
}

.cartqty-btn-separate::before,
.cartqty-btn-separate::after {
  display: none !important;
}

.cartquantity-selector > *,
.cartquantity-controls > * {
  border: none !important;
  box-shadow: none;
}

.cartqty-btn-separate {
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.25) !important;
}

.remove-btn {
  box-shadow: 0 2px 8px rgba(245, 101, 101, 0.25) !important;
}


/* ========== POPUP HEADER ========== */

.popup-header {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 12px 20px;       
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  flex-shrink: 0;
}

.popup-header h2 {
  margin: 0;
  font-size: 17px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
}

.popup-cart-img {
  width: 18px;
  height: 18px;
  margin-right: 6px;
  vertical-align: middle;
}

.clear-btn {
  background: rgba(255, 255, 255, 0.2);
  border: none;
  width: 28px;
  height: 28px;
  min-width: 28px;
  min-height: 28px;
  max-width: 28px;
  max-height: 28px;
  border-radius: 50%;
  font-size: 20px;
  font-weight: 300;
  cursor: pointer;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  line-height: 1;
  padding: 0;
  flex-shrink: 0;
}

.clear-btn:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: rotate(90deg);
}

.clear-btn:active {
  transform: rotate(90deg) scale(0.95);
}

/* ========== DESKTOP -  ========== */

/* Extra Large Desktop (1600px+) */
@media (min-width: 1600px) {
  .popup {
    max-width: 560px;        
    height: 85vh;
    max-height: 900px;
  }
  
  .popup-header {
    padding: 12px 20px;
  }
  
  .popup-header h2 {
    font-size: 17px;
  }
}

/* Large Desktop (1201px - 1599px) */
@media (min-width: 1201px) and (max-width: 1599px) {
  .popup {
    max-width: 540px;        
    height: 90vh;
    max-height: 950px;
  }
  
  .popup-header {
    padding: 12px 20px;
  }
  
  .popup-header h2 {
    font-size: 17px;
  }
}

/* Desktop (901px - 1200px) */
@media (min-width: 901px) and (max-width: 1200px) {
  .popup {
    max-width: 520px;        
    height: 85vh;
    max-height: 800px;
  }
  
  .popup-header {
    padding: 12px 20px;
  }
  
  .popup-header h2 {
    font-size: 17px;
  }
}

/* Desktop/Tablet Landscape (769px - 900px) */
@media (min-width: 769px) and (max-width: 900px) {
  .popup {
    max-width: 500px;        
    height: 75vh;
    max-height: 620px;
  }
  
  .popup-header {
    padding: 12px 18px;
  }
  
  .popup-header h2 {
    font-size: 16px;
  }
  
  .clear-btn {
    width: 26px;
    height: 26px;
    min-width: 26px;
    min-height: 26px;
    max-width: 26px;
    max-height: 26px;
    font-size: 19px;
  }
}

/* ========== TABLET PORTRAIT (601px - 768px) -  ========== */

@media (min-width: 601px) and (max-width: 768px) {
  .popup {
    width: 85%;
    max-width: 420px;      
    height: 78vh;
    max-height: 600px;
  }
  
  .popup-header {
    padding: 11px 16px;
  }
  
  .popup-header h2 {
    font-size: 16px;
  }
  
  .popup-cart-img {
    width: 17px;
    height: 17px;
  }
  
  .clear-btn {
    width: 26px;
    height: 26px;
    min-width: 26px;
    min-height: 26px;
    max-width: 26px;
    max-height: 26px;
    font-size: 18px;
  }
}

/* ========== MOBILE (481px - 600px)  ========== */

@media (min-width: 481px) and (max-width: 600px) {
  .popup {
    width: 88%;
    max-width: 380px;        
    height: 80vh;
    max-height: 580px;
  }
  
  .popup-header {
    padding: 10px 14px;
  }
  
  .popup-header h2 {
    font-size: 15px;
  }
  
  .popup-cart-img {
    width: 16px;
    height: 16px;
  }
  
  .clear-btn {
    width: 24px;
    height: 24px;
    min-width: 24px;
    min-height: 24px;
    max-width: 24px;
    max-height: 24px;
    font-size: 17px;
  }
}

/* ========== SMALL MOBILE (max-width: 480px) -  ========== */

@media (max-width: 480px) {
  .popup {
    width: 92%;
    max-width: 360px;        
    height: 85vh;
    max-height: 550px;
  }
  
  .popup-header {
    padding: 10px 12px;
  }
  
  .popup-header h2 {
    font-size: 14px;
  }
  
  .popup-cart-img {
    width: 15px;
    height: 15px;
  }
  
  .clear-btn {
    width: 24px;
    height: 24px;
    min-width: 24px;
    min-height: 24px;
    max-width: 24px;
    max-height: 24px;
    font-size: 16px;
  }
}

/* ========== EXTRA SMALL MOBILE (max-width: 360px) ========== */

@media (max-width: 360px) {
  .popup {
    width: 95%;
    max-width: 340px;        
    height: 88vh;
    max-height: 520px;
  }
  
  .popup-header {
    padding: 9px 10px;
  }
  
  .popup-header h2 {
    font-size: 13px;
  }
  
  .clear-btn {
    width: 22px;
    height: 22px;
    min-width: 22px;
    min-height: 22px;
    max-width: 22px;
    max-height: 22px;
    font-size: 15px;
  }
}
.cartIcon,
.login-btn {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    padding: 0;
}
.cart-img {
    width: 20px;    
    height: 20px;
    object-fit: contain;
    filter: invert(0);  
}

.login-img {
    width: 20px;
    height: 20px;
    object-fit: contain;
}

.popup-cart-img {
  width: 22px;       
  height: 22px;
  margin-right: 8px; 
  vertical-align: middle;
}

.icon {
  width:17px;
  height: 17px;
}