/* General Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Poppins', sans-serif;
  background-color: #F9FAFB;
  color: #1F2937;
  overflow-x: hidden; /* Prevent horizontal overflow */
  font-size: clamp(14px, 2.5vw, 16px); /* Responsive base font size */
}

/* Animations */
.fade-in {
  opacity: 0;
  animation: fadeIn 1s ease-in forwards; /* Shortened for mobile performance */
}

@keyframes fadeIn {
  to {
    opacity: 1;
  }
}

@keyframes zoomIn {
  0% {
    transform: scale(1);
  }
  100% {
    transform: scale(1.1);
  }
}

@keyframes drawLine {
  0% {
    width: 0;
  }
  100% {
    width: 128px;
  }
}

@keyframes fadeUp {
  0% {
    opacity: 0;
    transform: translateY(20px); /* Reduced translate for mobile */
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {
  0%, 100% {
    transform: scale(1);
    opacity: 0.7;
  }
  50% {
    transform: scale(1.1);
    opacity: 1;
  }
}

/* Enhanced Animations for Professional Look */
.animate-slide-in {
  animation: slideIn 0.4s ease-out forwards; /* Shortened for mobile */
}
@keyframes slideIn {
  from { transform: translateX(-20px); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

.animate-fade-in {
  animation: fadeIn 0.4s ease-out forwards;
}

.animate-popup {
  animation: popup 0.3s ease-out forwards;
}
@keyframes popup {
  from { transform: scale(0.95); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.animate-fade-out {
  animation: fadeOut 0.3s ease-out forwards;
}
@keyframes fadeOut {
  from { opacity: 1; }
  to { opacity: 0; }
}

.animate-spin {
  animation: spin 1s linear infinite;
}
@keyframes spin {
  100% { transform: rotate(360deg); }
}

.animate-hero-heading {
  animation: fadeUp 0.8s ease-out 0.3s forwards;
  opacity: 0;
}

.animate-hero-underline {
  animation: drawLine 0.8s ease-out 0.6s forwards;
  width: 0;
}

.animate-hero-subheading {
  animation: fadeUp 0.8s ease-out 0.9s forwards;
  opacity: 0;
}

.animate-hero-tagline {
  animation: fadeUp 0.8s ease-out 1.2s forwards;
  opacity: 0;
}

.animate-hero-button {
  animation: fadeUp 0.8s ease-out 1.5s forwards;
  opacity: 0;
}

.animate-hero-scroll {
  animation: pulse 2s infinite ease-in-out;
}

/* Form Error States */
input:invalid:focus {
  border-color: #DC2626;
  box-shadow: 0 0 0 2px rgba(220, 38, 38, 0.2);
}

/* Popup Styles */
#paypal-popup, #crypto-popup {
  transition: opacity 0.3s ease;
  z-index: 1000; /* Above cart window */
}

#paypal-popup .bg-white, #crypto-popup .bg-white {
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

/* Success/Error Messages */
#success-message, #error-message {
  z-index: 1100; /* Above popups */
}

/* Best Sellers Section */
#best-sellers .flex {
  transition: all 0.3s ease;
}

#best-sellers button {
  transition: transform 0.2s ease, background 0.3s ease;
}

#best-sellers button:hover {
  transform: scale(1.05);
}

/* Cart Items (Shared between cart.html and checkout.html) */
.cart-item {
  display: flex;
  align-items: center;
  padding: clamp(8px, 2vw, 12px) 0; /* Responsive padding */
  border-bottom: 1px solid #E5E7EB;
  transition: background 0.2s ease;
}

.cart-item:hover {
  background: #F9FAFB;
}

.cart-item img {
  width: clamp(48px, 10vw, 64px); /* Responsive image size */
  height: clamp(48px, 10vw, 64px);
  object-fit: cover;
  border-radius: 8px;
  margin-right: clamp(8px, 2vw, 16px);
}

.cart-item .flex-1 {
  flex: 1;
}

.cart-item .flex-1 p {
  font-size: clamp(0.75rem, 2vw, 0.875rem);
}

.cart-item .flex-1 .text-gray-900 {
  color: #1F2937;
  font-weight: 500;
  font-size: clamp(0.875rem, 2.5vw, 1rem);
}

.cart-item .flex-1 .text-gray-600 {
  color: #6B7280;
}

.cart-item .decrement-quantity,
.cart-item .increment-quantity {
  padding: clamp(4px, 1.5vw, 6px) clamp(8px, 2vw, 10px);
  background: #E5E7EB;
  border-radius: 4px;
  font-size: clamp(0.75rem, 2vw, 1rem);
  line-height: 1;
  transition: background 0.2s ease;
  min-width: 44px; /* Accessible touch target */
  min-height: 44px;
}

.cart-item .decrement-quantity:hover,
.cart-item .increment-quantity:hover {
  background: #D1D5DB;
}

.cart-item .quantity-input {
  width: clamp(40px, 8vw, 48px);
  padding: clamp(4px, 1vw, 6px);
  font-size: clamp(0.75rem, 2vw, 0.875rem);
  border: 1px solid #E5E7EB;
  border-radius: 4px;
  text-align: center;
  transition: border 0.2s ease;
}

.cart-item .quantity-input:focus {
  outline: none;
  border-color: #F59E0B;
}

.cart-item .remove-from-cart {
  color: #6B7280;
  transition: color 0.2s ease, transform 0.2s ease;
}

.cart-item .remove-from-cart:hover {
  color: #DC2626;
  transform: scale(1.1);
}

.cart-item .remove-from-cart svg {
  width: clamp(16px, 4vw, 20px);
  height: clamp(16px, 4vw, 20px);
}

/* Cart Items (cart.html) */
#cart-items {
  min-height: 80px;
  max-height: 50vh; /* Consistent height */
  overflow-y: auto;
  padding: 0 8px 8px 8px;
}

/* Order Summary (checkout.html) */
#summary-items {
  min-height: 80px;
  max-height: 40vh;
  overflow-y: auto;
  padding: 0 8px 8px 8px;
}

/* Cart Summary Section (Updated for cart.html) */
#summary {
  position: relative;
}

#cart-summary-content {
  position: sticky;
  bottom: 0;
  z-index: 10;
  padding: clamp(12px, 2vw, 16px) 0;
}

#cart-subtotal, #cart-total {
  font-size: clamp(1rem, 2.5vw, 1.125rem);
  font-weight: 600;
  color: #1F2937;
}

#cart-total {
  font-weight: 700;
  font-size: clamp(1.125rem, 2.5vw, 1.25rem);
}

#checkout-btn {
  display: block;
  background: #F59E0B;
  color: #FFFFFF;
  padding: clamp(10px, 2vw, 12px) clamp(16px, 3vw, 24px);
  border-radius: 8px;
  font-weight: 600;
  text-align: center;
  transition: background 0.3s ease, transform 0.2s ease;
  width: 100%;
  min-height: 44px; /* Accessible touch target */
}

#checkout-btn:hover {
  background: #D97706;
  transform: scale(1.05);
}

#checkout-btn:disabled {
  background: #9CA3AF;
  cursor: not-allowed;
  transform: none;
}

/* Custom Scrollbar */
#cart-items::-webkit-scrollbar,
#summary-items::-webkit-scrollbar {
  width: 6px; /* Slimmer for mobile */
}

#cart-items::-webkit-scrollbar-track,
#summary-items::-webkit-scrollbar-track {
  background: #F9FAFB;
  border-radius: 4px;
}

#cart-items::-webkit-scrollbar-thumb,
#summary-items::-webkit-scrollbar-thumb {
  background: #F59E0B;
  border-radius: 4px;
}

#cart-items::-webkit-scrollbar-thumb:hover,
#summary-items::-webkit-scrollbar-thumb:hover {
  background: #D97706;
}

/* Hero Section */
.hero-section {
  position: relative;
  min-height: clamp(300px, 80vh, 600px); /* Responsive height */
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: clamp(24px, 5vw, 48px) 16px;
  overflow: hidden;
  background: #0A0A0A;
}

.hero-bg {
  background-size: cover;
  background-position: center;
  animation: zoomIn 15s infinite alternate ease-in-out; /* Shortened for mobile */
  opacity: 0.6;
  transition: opacity 0.5s ease;
}

.hero-section:hover .hero-bg {
  opacity: 0.7;
}

.hero-particles {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.hero-particles::before {
  content: '';
  position: absolute;
  width: 2px;
  height: 2px;
  background: rgba(255, 215, 0, 0.5);
  box-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
  animation: particleMove 8s infinite linear; /* Shortened for mobile */
}

.hero-particles::after {
  content: '';
  position: absolute;
  width: 2px;
  height: 2px;
  background: rgba(255, 215, 0, 0.5);
  box-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
  animation: particleMove 12s infinite linear reverse;
}

@keyframes particleMove {
  0% {
    transform: translate(0, 0);
  }
  100% {
    transform: translate(100vw, 100vh);
  }
}

.hero-heading {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 6vw, 4rem);
  font-weight: 700;
  background: linear-gradient(90deg, #FFFFFF, #F0E68C);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 3px 3px 10px rgba(0, 0, 0, 0.5);
  letter-spacing: 2px;
  margin-bottom: clamp(8px, 2vw, 16px);
}

.hero-underline {
  height: 2px;
  background: linear-gradient(to right, #FBBF24, #D97706);
}

.hero-subheading {
  font-size: clamp(1rem, 3vw, 1.75rem);
  font-weight: 300;
  color: #E5E7EB;
  margin-bottom: clamp(8px, 2vw, 16px);
}

.hero-tagline {
  font-size: clamp(0.875rem, 2.5vw, 1.125rem);
  font-weight: 400;
  font-style: italic;
  color: #D1D5DB;
  margin-bottom: clamp(16px, 3vw, 32px);
}

.hero-button {
  background: linear-gradient(to right, #FBBF24, #D97706);
  color: #FFFFFF;
  padding: clamp(12px, 2.5vw, 16px) clamp(32px, 5vw, 48px);
  font-size: clamp(0.875rem, 2vw, 1.125rem);
  font-weight: 600;
  border-radius: 50px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.5s ease;
  min-height: 44px; /* Accessible touch target */
}

.hero-button:hover {
  background: linear-gradient(to right, #D97706, #B45309);
  transform: scale(1.05);
  box-shadow: 0 6px 25px rgba(251, 191, 36, 0.5);
}

/* Header */
header {
  background: #fff;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  position: relative;
  z-index: 900;
}

 .container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 clamp(8px, 2vw, 16px);
}

header a {
  text-decoration: none;
}

header nav a {
  font-weight: 500;
}

header .text-gray-600 {
  color: #4B5563;
}

header .hover\:text-amber-500:hover {
  color: #F59E0B;
}

/* Search Bar */
#search-bar {
  transition: all 0.3s ease;
  width: clamp(100px, 30vw, 200px); /* Responsive width */
}

#search-bar:focus {
  box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.5);
}

/* Cart Icon */
#cart-toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  cursor: pointer;
}

#cart-count {
  font-size: clamp(0.625rem, 1.5vw, 0.75rem);
  font-weight: 600;
}

/* Mobile Menu / Cart Window */
.nav-menu {
  position: fixed;
  top: 0;
  right: 0;
  height: 100vh;
  width: clamp(200px, 80vw, 300px); /* Responsive width */
  background: #fff;
  transform: translateX(100%);
  transition: transform 0.3s ease;
  z-index: 950;
  overflow-y: auto;
  box-sizing: border-box;
  padding: clamp(8px, 2vw, 16px);
  box-shadow: -2px 0 8px rgba(0, 0, 0, 0.1);
  border-left: 1px solid #E5E7EB;
}

.nav-menu.open {
  transform: translateX(0);
}

/* Product Card */
.product-card {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-card:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.product-card img {
  width: 100%;
  height: clamp(150px, 30vw, 200px); /* Responsive height */
  object-fit: cover;
}

.product-card .product-info {
  padding: clamp(8px, 2vw, 16px);
}

.product-card h3 {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  color: #1F2937;
  margin-bottom: 8px;
}

.product-card .price {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.product-card .original-price {
  text-decoration: line-through;
  color: #6B7280;
}

.product-card .discount-price {
  color: #DC2626;
  font-weight: 600;
}

.product-card .rating {
  display: flex;
  gap: 4px;
  margin-bottom: 8px;
}

.product-card .rating svg {
  width: clamp(16px, 2vw, 18px);
  height: clamp(16px, 2vw, 18px);
}

.product-card button {
  width: 100%;
  padding: clamp(6px, 1.5vw, 8px);
  background: #1F2937;
  color: #fff;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 500;
  transition: background 0.3s ease, transform 0.2s ease;
  min-height: 44px; /* Accessible touch target */
}

.product-card button:hover {
  background: linear-gradient(to right, #F59E0B, #D97706);
  transform: scale(1.02);
}

/* Category Card */
.category-card {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.category-card img {
  width: 100%;
  height: clamp(120px, 25vw, 150px);
  object-fit: cover;
  transition: transform 0.3s ease;
}

.category-card:hover img {
  transform: scale(1.1);
}

.category-card h3 {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  color: #1F2937;
  padding: clamp(8px, 2vw, 16px);
}

/* Product Detail */
#product-detail {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 clamp(8px, 2vw, 16px);
}

#main-image img {
  max-height: clamp(300px, 50vh, 500px);
  width: 100%;
  object-fit: cover;
}

#thumbnail-list {
  max-height: clamp(300px, 40vh, 400px);
}

.thumbnail {
  width: clamp(48px, 10vw, 64px);
  height: clamp(48px, 10vw, 64px);
  object-fit: cover;
  border-radius: 8px;
  cursor: pointer;
  transition: opacity 0.3s ease, border 0.3s ease;
}

.thumbnail:hover {
  opacity: 0.8;
}

.thumbnail.active {
  border: 2px solid #F59E0B;
  opacity: 1;
}

#product-name {
  font-size: clamp(1.5rem, 3vw, 1.875rem);
}

#product-price .original-price {
  text-decoration: line-through;
  color: #6B7280;
}

#product-price .discount-price {
  color: #DC2626;
}

#quantity {
  border-left: none;
  border-right: none;
}

#decrement-quantity, #increment-quantity {
  transition: background 0.2s ease;
  min-height: 44px; /* Accessible touch target */
}

/* Tabs */
.tab-button {
  font-weight: 500;
  transition: color 0.3s ease, border 0.3s ease;
}

.tab-button.active {
  color: #F59E0B;
  border-bottom: 2px solid #F59E0B;
}

.tab-pane {
  transition: opacity 0.3s ease;
}

/* Load More Button */
.load-more-btn {
  padding: clamp(6px, 1.5vw, 8px) clamp(16px, 3vw, 24px);
  background: #DC2626;
  color: #fff;
  border: none;
  border-radius: 4px;
  font-weight: 600;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.3s ease;
  min-height: 44px; /* Accessible touch target */
}

.load-more-btn:hover:not(:disabled) {
  background: #B91C1C;
}

.load-more-btn:disabled {
  background: #9CA3AF;
  cursor: not-allowed;
}

/* Feature Boxes */
.feature-boxes {
  padding: clamp(16px, 3vw, 32px) 0;
}

.feature-boxes .flex > div {
  max-width: clamp(250px, 30vw, 300px);
}

.feature-boxes svg {
  width: clamp(36px, 5vw, 48px);
  height: clamp(36px, 5vw, 48px);
  margin-bottom: clamp(8px, 2vw, 16px);
  color: #1F2937;
}

.feature-boxes h3 {
  font-size: clamp(1rem, 2vw, 1.125rem);
  font-weight: 700;
  color: #1F2937;
  margin-bottom: 8px;
}

.feature-boxes p {
  font-size: clamp(0.75rem, 2vw, 0.875rem);
  color: #6B7280;
}

/* Buttons */
.bg-gray-900 {
  background: #1F2937;
}

.bg-amber-500 {
  background: #F59E0B;
}

.hover\:bg-gradient-to-r:hover {
  background: linear-gradient(to right, #F59E0B, #D97706);
}

.transform.hover\:scale-105:hover {
  transform: scale(1.05);
}

/* Footer */
footer {
  background: linear-gradient(135deg, #1F2937 0%, #111827 100%);
  padding: clamp(24px, 5vw, 48px) 0;
  color: #D1D5DB;
  position: relative;
  z-index: 800;
}

footer .container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 clamp(16px, 3vw, 24px);
}

footer a {
  text-decoration: none;
  color: #D1D5DB;
  transition: color 0.3s ease;
}

footer a:hover {
  color: #F59E0B;
}

footer h3 {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  font-weight: 700;
  color: #FFFFFF;
  margin-bottom: clamp(8px, 2vw, 16px);
}

footer p, footer ul li {
  font-size: clamp(0.875rem, 2vw, 0.9375rem);
  line-height: 1.6;
}

footer ul {
  list-style: none;
  margin-bottom: clamp(16px, 3vw, 24px);
}

footer ul li {
  margin-bottom: clamp(8px, 1.5vw, 12px);
}

footer .text-gray-300 {
  color: #D1D5DB;
}

footer .hover\:text-amber-500:hover {
  color: #F59E0B;
}

footer .border-t {
  border-color: rgba(255, 255, 255, 0.1);
}

footer .social-icons {
  display: flex;
  gap: clamp(8px, 2vw, 16px);
}

footer .social-icons svg {
  width: clamp(20px, 3vw, 24px);
  height: clamp(20px, 3vw, 24px);
  transition: transform 0.3s ease, color 0.3s ease;
}

footer .social-icons svg:hover {
  color: #F59E0B;
  transform: scale(1.1);
}

footer .newsletter {
  margin-top: clamp(16px, 3vw, 24px);
}

footer .newsletter input {
  padding: clamp(6px, 1.5vw, 8px) clamp(12px, 2vw, 16px);
  border: 1px solid #4B5563;
  border-radius: 4px;
  background: #1F2937;
  color: #FFFFFF;
  font-size: clamp(0.75rem, 2vw, 0.875rem);
  width: 100%;
  max-width: clamp(250px, 40vw, 300px);
  margin-bottom: clamp(8px, 2vw, 16px);
}

footer .newsletter input:focus {
  outline: none;
  border-color: #F59E0B;
  box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.2);
}

footer .newsletter button {
  padding: clamp(6px, 1.5vw, 8px) clamp(16px, 3vw, 24px);
  background: #F59E0B;
  color: #FFFFFF;
  border: none;
  border-radius: 4px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.2s ease;
  min-height: 44px; /* Accessible touch target */
}

footer .newsletter button:hover {
  background: #D97706;
  transform: scale(1.05);
}

footer .footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: clamp(16px, 3vw, 24px);
  margin-top: clamp(16px, 3vw, 24px);
  text-align: center;
}

footer .footer-bottom p {
  font-size: clamp(0.75rem, 2vw, 0.875rem);
  color: #9CA3AF;
}

/* Skeleton Loading */
.skeleton {
  background: #E5E7EB;
  border-radius: 8px;
  animation: pulse 1.5s infinite ease-in-out;
}

@keyframes pulse {
  0% {
    opacity: 0.6;
  }
  50% {
    opacity: 1;
  }
  100% {
    opacity: 0.6;
  }
}

/* Custom styles for PayPal popup */
.paypal-font {
  font-family: "Helvetica Neue", Arial, sans-serif;
}

.paypal-blue {
  background-color: #0070BA;
}

.paypal-blue:hover {
  background-color: #005EA6;
}

.paypal-border {
  border-color: #E0E0E0;
}

.paypal-text-dark {
  color: #1A1A1A;
}

.paypal-text-light {
  color: #666;
}

.paypal-link {
  color: #0070BA;
}

.paypal-link:hover {
  text-decoration: underline;
}

.separator::before,
.separator::after {
  content: '';
  flex: 1;
  border-bottom: 1px solid #E0E0E0;
  margin: 0 10px;
}

/* Styles for payment method selection */
.payment-method {
  border: 2px solid #E0E0E0;
  border-radius: 8px;
  padding: clamp(8px, 2vw, 16px);
  cursor: pointer;
  transition: border-color 0.2s ease-in-out;
}

.payment-method.selected {
  border-color: #F59E0B;
  background-color: #FFF7ED;
}

.payment-method:hover {
  border-color: #F59E0B;
}

.paypal-footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: clamp(4px, 1vw, 6px);
}

/* Styles for Crypto Popup */
.crypto-blue {
  background-color: #2563EB;
}

.crypto-blue:hover {
  background-color: #1D4ED8;
}

/* PayPal Loading Animation */
.paypal-loading-container {
  position: relative;
  width: clamp(50px, 10vw, 60px);
  height: clamp(50px, 10vw, 60px);
}

.paypal-loading-logo {
  width: clamp(50px, 10vw, 60px);
  height: clamp(32px, 6vw, 38px);
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.paypal-pulse {
  position: absolute;
  top: 0;
  left: 0;
  width: clamp(50px, 10vw, 60px);
  height: clamp(50px, 10vw, 60px);
  border-radius: 50%;
  background: rgba(0, 112, 186, 0.2);
  animation: paypal-pulse 1.5s ease-in-out infinite;
}

@keyframes paypal-pulse {
  0% {
    transform: scale(0);
    opacity: 1;
  }
  100% {
    transform: scale(1.5);
    opacity: 0;
  }
}

/* Crypto Loading Animation */
.crypto-loading-container {
  position: relative;
  width: clamp(50px, 10vw, 60px);
  height: clamp(50px, 10vw, 60px);
}

.crypto-node {
  position: absolute;
  width: clamp(10px, 2vw, 12px);
  height: clamp(10px, 2vw, 12px);
  background: #2563EB;
  border-radius: 50%;
  animation: crypto-orbit 2s linear infinite;
}

.crypto-node:nth-child(1) {
  animation-delay: 0s;
}

.crypto-node:nth-child(2) {
  animation-delay: 0.5s;
}

.crypto-node:nth-child(3) {
  animation-delay: 1s;
}

@keyframes crypto-orbit {
  0% {
    transform: rotate(0deg) translateX(25px) rotate(0deg);
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
  100% {
    transform: rotate(360deg) translateX(25px) rotate(-360deg);
    opacity: 1;
  }
}

.crypto-center {
  position: absolute;
  top: 50%;
  left: 50%;
  width: clamp(16px, 3vw, 20px);
  height: clamp(16px, 3vw, 20px);
  background: #2563EB;
  border-radius: 50%;
  transform: translate(-50%, -50%);
}

/* Responsive Design */
@media (max-width: 360px) { /* Ultra-small screens */
  body {
    font-size: clamp(12px, 3vw, 14px);
  }

  .hero-section {
    min-height: 300px;
    padding: 16px;
  }

  .hero-heading {
    font-size: clamp(1.5rem, 5vw, 2rem);
  }

  .hero-subheading {
    font-size: clamp(0.875rem, 2.5vw, 1rem);
  }

  .hero-tagline {
    font-size: clamp(0.75rem, 2vw, 0.875rem);
  }

  .hero-button {
    padding: 8px 24px;
    font-size: clamp(0.75rem, 2vw, 0.875rem);
  }

  .nav-menu {
    width: clamp(180px, 90vw, 250px);
  }

  .cart-item img {
    width: 40px;
    height: 40px;
  }

  .cart-item .quantity-input {
    width: 36px;
  }

  #cart-items, #summary-items {
    max-height: 40vh;
  }

  #checkout-btn {
    padding: 8px;
    font-size: 0.75rem;
  }
}

@media (max-width: 640px) {
  #search-bar {
    width: clamp(80px, 25vw, 120px) !important;
  }

  .product-card img {
    height: clamp(120px, 25vw, 150px);
  }

  .product-card h3 {
    font-size: clamp(0.875rem, 2vw, 1rem);
  }

  .product-card .price {
    font-size: clamp(0.75rem, 2vw, 0.9rem);
  }

  .category-card img {
    height: clamp(100px, 20vw, 120px);
  }

  #product-grid {
    grid-template-columns: 1fr;
    gap: clamp(8px, 2vw, 16px);
  }

  #thumbnail-list {
    max-height: 300px;
    width: 100%;
    flex-direction: row;
    overflow-x: auto;
    overflow-y: hidden;
    gap: 8px;
  }

  #thumbnail-list img {
    width: clamp(48px, 12vw, 60px);
    height: clamp(48px, 12vw, 60px);
  }

  #main-image img {
    max-height: 300px;
  }

  .cart-item {
    flex-wrap: wrap;
    gap: clamp(8px, 2vw, 12px);
  }

  .cart-item img {
    width: clamp(40px, 8vw, 48px);
    height: clamp(40px, 8vw, 48px);
  }

  .cart-item .flex-1 {
    flex-basis: 100%;
    margin-bottom: 8px;
  }

  .cart-item .flex-1 .text-gray-900 {
    font-size: clamp(0.75rem, 2vw, 0.875rem);
  }

  .cart-item .flex-1 .text-gray-600 {
    font-size: clamp(0.625rem, 1.5vw, 0.75rem);
  }

  .cart-item .quantity-input {
    width: clamp(36px, 8vw, 40px);
  }

  .cart-item .decrement-quantity,
  .cart-item .increment-quantity {
    font-size: clamp(0.625rem, 1.5vw, 0.75rem);
  }

  #cart-subtotal, #cart-total {
    font-size: clamp(0.875rem, 2vw, 1rem);
  }

  #checkout-btn {
    padding: clamp(8px, 2vw, 10px);
    font-size: clamp(0.75rem, 2vw, 0.875rem);
  }

  .feature-boxes .flex {
    flex-direction: column;
    gap: clamp(16px, 3vw, 32px);
  }

  .feature-boxes .flex > div {
    max-width: 100%;
  }

  footer .grid {
    grid-template-columns: 1fr;
    gap: clamp(16px, 3vw, 32px);
  }

  footer h3 {
    font-size: clamp(0.875rem, 2vw, 1.125rem);
  }

  footer p, footer ul li {
    font-size: clamp(0.75rem, 2vw, 0.875rem);
  }

  footer .container {
    padding: 0 clamp(12px, 3vw, 24px);
  }

  footer .newsletter input {
    max-width: 100%;
  }

  .hero-section {
    min-height: clamp(350px, 70vh, 400px);
    padding: clamp(16px, 4vw, 32px) 16px;
  }

  .hero-heading {
    font-size: clamp(2rem, 5vw, 2.5rem);
  }

  .hero-subheading {
    font-size: clamp(1rem, 3vw, 1.25rem);
  }

  .hero-tagline {
    font-size: clamp(0.875rem, 2.5vw, 1rem);
  }

  .hero-button {
    padding: clamp(10px, 2vw, 12px) clamp(24px, 4vw, 32px);
    font-size: clamp(0.875rem, 2vw, 1rem);
  }

  #paypal-popup .bg-white, #crypto-popup .bg-white {
    width: clamp(80%, 90vw, 90%);
    height: auto;
  }

  .nav-menu {
    width: clamp(200px, 90vw, 280px);
  }

  #cart-items {
    max-height: 45vh;
  }

  #summary-items {
    max-height: 35vh;
  }
}

@media (min-width: 641px) and (max-width: 767px) { /* Small tablets */
  #product-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: clamp(12px, 2vw, 16px);
  }

  .product-card img {
    height: clamp(140px, 25vw, 160px);
  }

  .hero-section {
    min-height: clamp(400px, 75vh, 450px);
  }

  .nav-menu {
    width: clamp(250px, 50vw, 300px);
  }
}

@media (min-width: 768px) and (max-width: 1023px) { /* Tablets */
  #product-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: clamp(16px, 2.5vw, 20px);
  }

  .product-card img {
    height: clamp(160px, 25vw, 180px);
  }

  #thumbnail-list {
    max-height: 350px;
  }

  .feature-boxes .flex {
    flex-direction: row;
    gap: clamp(16px, 3vw, 24px);
    flex-wrap: wrap;
  }

  footer .grid {
    grid-template-columns: repeat(2, 1fr);
    gap: clamp(16px, 3vw, 24px);
  }

  .hero-section {
    min-height: clamp(450px, 80vh, 500px);
  }

  .hero-heading {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
  }

  .hero-subheading {
    font-size: clamp(1.25rem, 3vw, 1.5rem);
  }

  .hero-tagline {
    font-size: clamp(0.875rem, 2vw, 1.125rem);
  }
}

@media (min-width: 1024px) { /* Desktops */
  #product-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: clamp(20px, 2vw, 24px);
  }

  .feature-boxes .flex {
    gap: clamp(24px, 3vw, 48px);
  }

  footer .grid {
    grid-template-columns: repeat(4, 1fr);
    gap: clamp(24px, 3vw, 48px);
  }

  .hero-section {
    min-height: clamp(600px, 80vh, 700px);
  }

  .hero-heading {
    font-size: clamp(3rem, 5vw, 4rem);
  }
}
/* ... existing styles ... */

/* Animation for the live viewer count element */
@keyframes pulse-and-fade-in {
  0% {
    opacity: 0;
    transform: translateY(10px) scale(0.95);
  }
  70% {
    opacity: 1;
    transform: translateY(0) scale(1.02);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.animate-viewer-show {
  animation: pulse-and-fade-in 0.7s ease-out forwards;
}

/* Animation for when the number changes */
@keyframes number-pop {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.25);
  }
  100% {
    transform: scale(1);
  }
}

.animate-number-pop {
  display: inline-block; /* Required for transform to work properly */
  animation: number-pop 0.3s ease-in-out;
}