
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Poppins', sans-serif;
}

html {
  scroll-behavior: smooth;
}


::-webkit-scrollbar {
  width: 10px; 
}

::-webkit-scrollbar-track {
  background: #f1f1f1; 
}

::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
  background: #069ba0c2;
}


body {
  background-color: #ffffff;
  color: #1f2937;
  line-height: 1.6;
}
a {
  text-decoration: none; 
}

/* Navbar */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  background-color: #fff;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.06);
  position: sticky;
  top: 0;
  z-index: 10;
}

.logo {
  font-size: 2rem;
  font-weight: 700;
  color: #1D4ED8;
  letter-spacing: -1px;
  padding-right: 20px;
}

@media (max-width: 768px) {
  .logo {
    font-size: 1.4rem;
  }
}

@media (max-width: 480px) {
  .logo {
    font-size: 1rem;
  }
}

.search-input {
  width: 45%;
  padding: 0.6rem 1rem;
  border-radius: 999px;
  border: 1px solid #ddd;
  transition: all 0.3s ease;
  display: inline-block;
}


.search-input:focus {
  border-color: #1D4ED8;
  outline: none;
  box-shadow: 0 0 0 2px rgba(29, 78, 216, 0.3);
}


@media (max-width: 480px) {
  .search-input {
    display: none;
  }

  .search-icon {
    display: inline-block;
    background: url('https://img.icons8.com/?size=100&id=12773&format=png&color=000000') center no-repeat;
    width: 25px;
    height: 25px;
    background-size: contain;
    cursor: pointer;
  }
}
.nav-buttons {
  display: flex;
  align-items: center; 
}

.nav-buttons button {
  padding: 0.5rem 1rem;
  margin-left: 0.6rem;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.3s ease;
}

.login {
  background: white;
  border: 1px solid #ccc;
  padding: 0.5rem 1rem;
  font-size: 14px;
  border-radius: 999px;
  transition: background-color 0.3s ease;
}

.login:hover {
  background-color: #f3f4f6;
}

.cart {
  color: white;
  background-color: #1D4ED8;
  position: relative;
  padding: 10px 20px;
  font-size: 16px;
  cursor: pointer;
  border: none;
  border-radius: 999px;
}

.cart-icon-container {
  display: flex;
  align-items: center;
  position: relative;
  cursor: pointer;
  padding-left: 10px;
}

#cartIcon {
  width: 40px;
  height: 40px;
}

.cart-count {
  position: absolute;
  top: -5px;
  right: -5px;
  background-color: red;
  color: white;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  text-align: center;
  font-size: 14px;
  font-weight: bold;
  visibility: hidden; /* Initially hidden until cart count is updated */
}

@media (max-width: 768px) {
  .login {
    padding: 0.4rem 0.8rem;
    font-size: 12px;
  }

  .cart {
    padding: 8px 15px;
    font-size: 14px;
  }

  .cart-icon-container {
    padding-left: 8px;
  }

  #cartIcon {
    width: 35px;
    height: 35px;
  }

  .cart-count {
    width: 18px;
    height: 18px;
    font-size: 12px;
  }
}

@media (max-width: 480px) {
  .login {
    padding: 0.3rem 0.6rem;
    font-size: 10px;
  }

  .cart {
    padding: 6px 12px;
    font-size: 12px;
  }

  .cart-icon-container {
    padding-left: 6px;
  }

  #cartIcon {
    width: 30px;
    height: 30px;
  }

  .cart-count {
    width: 16px;
    height: 16px;
    font-size: 10px;
  }
}

/* Modal Styles */
.modal {
  display: none;
  position: fixed;
  z-index: 1;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.4);
  padding-top: 60px;
  overflow-y: auto;
}

.modal-content {
  background-color: #fff;
  margin: 5% auto;
  padding: 2rem;
  border-radius: 8px;
  width: 80%;
  max-width: 400px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

/* Form inputs and buttons */
input[type="email"], input[type="password"] {
  width: 100%;
  padding: 0.8rem;
  margin: 0.5rem 0;
  border-radius: 8px;
  border: 1px solid #ddd;
}

button[type="submit"], .google-login-btn {
  width: 100%;
  padding: 0.8rem;
  margin-top: 1rem;
  border-radius: 8px;
  background-color: #1D4ED8;
  color: white;
  border: none;
  cursor: pointer;
  font-weight: 600;
}

button[type="submit"]:hover, .google-login-btn:hover {
  background-color: #2563EB;
}

/* Google Login Button Styling */
.google-login-btn {
  background-color: #db4437;
  display: block;
  margin: 0.5rem 0;
}

.google-login-btn:hover {
  background-color: #c1351d;
}


/* Hero Slider */
#slider {
  width: 90%;
  margin: 2rem auto;
  overflow: hidden;
  border-radius: 16px;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.15);
}

#slider figure {
  position: relative;
  width: 500%;
  margin: 0;
  left: 0;
  animation: 20s slider infinite;
}

#slider figure img {
  float: left;
  width: 20%;
  height: auto;
  object-fit: cover;
  transition: transform 0.5s ease;
}

#slider figure img:hover {
  transform: scale(1.05);
}

@keyframes slider {
  0%, 15% { left: 0; }
  20%, 35% { left: -100%; }
  40%, 55% { left: -200%; }
  60%, 75% { left: -300%; }
  80%, 95% { left: -400%; }
  100% { left: 0; }
}

/* Featured Categories */
.featured-categories {
  padding: 3rem 2rem;
  background-color: #f9fafb;
}

.featured-categories h3 {
  text-align: center;
  font-size: 2rem;
  font-weight: 600;
  color: #1D4ED8;
  margin-bottom: 2rem;
}
@media (max-width: 768px) {
  .featured-categories h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
  }
}

@media (max-width: 480px) {
  .featured-categories h3 {
    font-size: 1rem;
    margin-bottom: 1rem;
  }
}

.categories {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2rem;
}

.category-card {
  overflow: hidden;
  border-radius: 12px;
  background-color: #ffffff;
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.08);
  transition: transform 0.4s ease;
  position: relative;
}

.category-card:hover {
  transform: translateY(-6px);
}

.category-card img {
  width: 100%;
  height: 240px;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.category-name {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 1.1rem;
  font-weight: 600;
  color: #fff;
  background-color: rgba(0, 0, 0, 0.4);
  padding: 0.4rem 1rem;
  border-radius: 20px;
  backdrop-filter: blur(2px);
}

/* Featured Products */
.featured-products {
  padding: 4rem 2rem;
  background-color: #f9fafb;
}

.featured-products h3 {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 2.5rem;
  font-weight: 700;
  color: #1D4ED8;
}
@media (max-width: 768px) {
  .featured-products h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
  }
}

@media (max-width: 480px) {
  .featured-products h3 {
    font-size: 1rem;
    margin-bottom: 1rem;
  }
}

.product-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.8rem;
}

.product-card {
  background: #fff;
  border-radius: 16px;
  padding: 1rem;
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  position: relative;
  display: flex;
  flex-direction: column;
  height: 400px;
  text-align: center;
}

.product-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.12);
}

.product-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  margin-bottom: 1rem;
  border-radius: 12px;
}

.discount-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: #ef4444;
  color: #fff;
  padding: 0.3rem 0.6rem;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
}

.product-name {
  font-size: 1rem;
  font-weight: 500;
  margin-bottom: 0.3rem;
}

.rating {
  color: #ffbb00;
  margin-bottom: 0.4rem;
}

.price {
  font-weight: 600;
  font-size: 1.3rem;
  color: #007c42;
  margin-bottom: 0.8rem;
}

.product-card button {
  padding: 0.5rem 1rem;
  background-color: #1D4ED8;
  color: #fff;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.3s ease;
}

.product-card button:hover {
  background-color: #2563eb;
}

/* Footer */
footer {
  background-color: #1f2937;
  color: #d1d5db;
  padding: 3rem 1rem;
  font-size: 1rem;
  text-align: center;
  font-family: 'Arial', sans-serif;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr;
  gap: 2rem;
  padding: 0 1rem;
}

.footer-links, .footer-socials, .footer-contact, .footer-developer {
  text-align: center;
}

.footer-links a, 
.footer-socials a, 
.footer-developer a {
  color: #d1d5db;
  text-decoration: none;
  margin: 0.5rem 0;
  display: block;
  font-size: 1.1rem;
  transition: color 0.3s ease;
}

.footer-links a:hover, 
.footer-socials a:hover, 
.footer-developer a:hover {
  color: #e11d48;
}

.footer-contact p {
  font-size: 1rem;
  color: #d1d5db;
}

.email-link {
  color: rgb(0, 255, 21);
}

.footer-developer p {
  margin-top: 1rem;
  font-size: 0.9rem;
}

.developer-link {
  font-weight: bold;
  color: #fff;
  font-size: 1.1rem;
  transition: color 0.3s ease;
}

.developer-link:hover {
  color: #e11d48;
}

/* Mobile Responsiveness */
@media (max-width: 1024px) {
  .footer-container {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  footer {
    padding: 2rem 1rem;
  }
  .footer-container {
    grid-template-columns: 1fr;
  }
  .footer-links a, 
  .footer-socials a, 
  .footer-developer a {
    font-size: 1rem;
  }
}

/* Small mobile devices */
@media (max-width: 480px) {
  .footer-links a, 
  .footer-socials a, 
  .footer-developer a {
    font-size: 0.9rem;
  }
  .footer-contact p {
    font-size: 0.85rem;
  }
}

/* Mobile Responsiveness */
@media (max-width: 1024px) {
  .footer-container {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  footer {
    padding: 1.5rem 0.5rem;
  }
  .footer-container {
    grid-template-columns: 1fr;
    text-align: left;
  }
  .footer-links,
  .footer-socials,
  .footer-contact,
  .footer-developer {
    margin-bottom: 1.5rem;
  }
  .footer-developer p {
    font-size: 0.85rem;
  }
}

/* Small mobile devices */
@media (max-width: 480px) {
  .footer-links a,
  .footer-socials a,
  .footer-developer a {
    font-size: 0.9rem;
  }

  .footer-contact p {
    font-size: 0.85rem;
  }
}

/* Responsive */
@media (max-width: 600px) {
  .featured-products {
    padding: 1rem;
  }

  .slides img {
    height: 250px;
  }
}

.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0; top: 0;
  width: 100%; height: 100%;
  background-color: rgba(0,0,0,0.4);
}

.modal-content {
  background: white;
  padding: 2rem;
  margin: 10% auto;
  width: 300px;
  border-radius: 10px;
}

/* Product Modal Styles */
.product-modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.7);
  align-items: center;
  justify-content: center;
}

.product-modal-content {
  background-color: #fff;
  margin: auto;
  width: 90%;
  max-width: 1000px;
  max-height: 90vh;
  overflow-y: auto;
  border-radius: 8px;
  padding: 20px;
  position: relative;
}

.close-modal {
  width: 40px;  
  height: 40px; 
  background-color: #e74c3c; 
  color: white;
  position: fixed;
  right: 20px;
  top: 15px;
  font-size: 22px; 
  font-weight: bold;
  display: flex;
  justify-content: center;
  align-items: center;
  border: none;  
  border-radius: 8px;  
  cursor: pointer;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);  
  transition: background-color 0.3s ease, transform 0.2s ease;
}

.close-modal:hover {
  background-color: #c0392b;  
  transform: scale(1.1);  
}

.product-details {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
  margin-bottom: 30px;
}

.product-images {
  flex: 1;
  min-width: 300px;
}

.main-image {
  width: 100%;
  height: 350px;
  margin-bottom: 15px;
  border: 1px solid #eee;
  border-radius: 8px;
  overflow: hidden;
}

.main-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.image-thumbnails {
  display: flex;
  gap: 10px;
  overflow-x: auto;
}

.image-thumbnail {
  width: 80px;
  height: 80px;
  border: 1px solid #ddd;
  border-radius: 4px;
  cursor: pointer;
  overflow: hidden;
}

.image-thumbnail.active {
  border: 2px solid #18CEF6;
}

.image-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-info {
  flex: 1;
  min-width: 300px;
}

.product-info h2 {
  margin-top: 0;
  color: #333;
}

.product-rating {
  margin: 10px 0;
  color: #ffc107;
  font-size: 18px;
}

.product-price {
  font-size: 24px;
  font-weight: bold;
  color: #1a1a1a;
  margin: 10px 0;
}

.product-discount {
  color: #e74c3c;
  font-weight: bold;
  margin-bottom: 15px;
}

.product-description {
  margin: 20px 0;
  line-height: 1.6;
  color: #555;
}

.quantity-selector {
  display: flex;
  align-items: center;
  margin: 20px 0;
}

.quantity-selector button {
  background: #f1f1f1;
  border: none;
  width: 35px;
  height: 35px;
  font-size: 18px;
  cursor: pointer;
}

.quantity-selector input {
  width: 50px;
  height: 35px;
  text-align: center;
  border: 1px solid #ddd;
  margin: 0 5px;
}

.add-to-cart-modal {
  background-color: #18CEF6;
  color: white;
  border: none;
  padding: 12px 25px;
  border-radius: 4px;
  font-size: 16px;
  cursor: pointer;
  font-weight: bold;
  transition: background-color 0.3s;
}

.add-to-cart-modal:hover {
  background-color: #0DABD2;
}

.product-reviews {
  border-top: 1px solid #eee;
  padding-top: 20px;
}

.product-reviews h3 {
  margin-bottom: 20px;
  color: #333;
}

.review {
  display: flex;
  gap: 15px;
  margin-bottom: 20px;
  padding-bottom: 15px;
  border-bottom: 1px solid #eee;
}

.review img {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  object-fit: cover;
}

.review-content {
  flex: 1;
}

.review-stars {
  margin: 5px 0;
  color: #ffc107;
}

.review-content p {
  margin-top: 5px;
  color: #555;
}

@media (max-width: 768px) {
  .product-details {
    flex-direction: column;
  }
  
  .main-image {
    height: 250px;
  }
}