/* Reset and base styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: Arial, sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

header {
  background: #000000;
  color: white;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 30px 20px;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 5px rgba(0,0,0,0.15);

  border-radius: 15px 15px 15px 15px;
  overflow: hidden; /* to ensure contents respect rounded corners */
}

.header-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo {
  width: 40px;
  height: 40px;
  background: white;
  border-radius: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #1e90ff;
  font-weight: bold;
  font-size: 24px;
  user-select: none;
  margin-left: 30px
}

.logo img {
  width: 160px;      /* same size as previous div */
  height: 180px;
  object-fit: contain;
  user-select: none;
  margin-top: 8px
}

.store-name {
  font-size: 1.5rem;
  font-weight: 700;
  user-select: none;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 20px;
  position: relative;
}

.header-icon {
  color: white;
  font-size: 1.5rem;
  cursor: pointer;
  transition: color 0.3s ease;
  position: relative;
}

.header-icon:hover {
  color: #ffdd57;
}

.cart-count {
  position: absolute;
  top: -8px;
  right: -12px;
  background: #ff4136;
  color: white;
  font-size: 0.75rem;
  font-weight: bold;
  border-radius: 50%;
  padding: 2px 6px;
  user-select: none;
}

.cart-item {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr;
  gap: 10px;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid #ddd;
}

.cart-item input.quantity-input {
  width: 60px;
  padding: 4px 6px;
  font-size: 1rem;
  text-align: center;
}


main {
  padding: 40px 20px;
  flex-grow: 1;
}

footer {
  background-color: #222;
  color: #eee;
  padding: 10px 30px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 15px;
  border-radius: 15px 15px 15px 15px;
  font-size: 0.9rem;
}

.contact-info {
  max-width: 300px;
  line-height: 1.5;
}

.social-icons {
  display: flex;
  align-items: center;
  gap: 20px;
}

.social-icons a {
  color: #eee;
  font-size: 1.8rem;
  text-decoration: none;
  transition: color 0.3s ease;
}

.social-icons a:hover {
  color: #1e90ff;
}

@media (max-width: 480px) {
  header {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .header-right {
    gap: 15px;
  }

  footer {
    flex-direction: column;
    align-items: flex-start;
  }

  .social-icons {
    margin-top: 10px;
  }
}

.category-list {
  max-width: 1500px;
  margin: 20px auto;
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
  /* optional: provide a perspective context for children */
  perspective: 1000px;
}

.category-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 400px;
  padding: 10px;
  background: transparent; /* or semi‑transparent if you want */
  color: black;
  text-align: center;
  font-size: 1rem;
  border-radius: 8px;
  text-decoration: none;
  user-select: none;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  transform-style: preserve-3d;
  will-change: transform;
}

.category-item img {
  width: 400px;
  height: 250px;
  object-fit: cover;
  border-radius: 6px;
  margin-bottom: 8px;
  transition: transform 0.3s ease;
  transform-style: preserve-3d;
  will-change: transform;
}

/* Hover / tilt effect */
.category-item:hover {
  transform: translateY(-8px);
  z-index: 10;
}

/* You could also tilt the image itself for extra pop */
.category-item:hover img {
  transform: scale(1.3) translateZ(10px);
  z-index: 20;
}

/* Products page */

.product-list {
  max-width: 800px;
  margin: 20px auto;
  display: flex;             /* horizontal row */
  flex-wrap: wrap;           /* wrap if too many */
  gap: 18px;
  justify-content: flex-start; /* or center */
}

.product {
  background: #f0f0f0;
  border-radius: 8px;
  width: 180px;
  padding: 10px;
  box-sizing: border-box;
  text-align: center;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  display: flex;
  flex-direction: column;
  align-items: center;
  user-select: none;
  transition: box-shadow 0.3s ease;
}

.product img {
  width: 140px;
  height: 120px;
  object-fit: cover;
  border-radius: 6px;
  margin-bottom: 10px;
  border: 1px solid #ccc;
}

.product button {
  margin-top: 10px;
  padding: 8px 12px;
  background: #1e90ff;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-weight: 600;
  transition: background-color 0.3s ease;
}

.product button:hover {
  background: #0c63d4;
}

.product:hover {
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

/* Modal Styles */
.modal {
  display: none;
  position: fixed;
  z-index: 2000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background: rgba(0, 0, 0, 0.5);
}

.modal-content {
  background: #fff;
  margin: 10% auto;
  padding: 30px 20px;
  border-radius: 8px;
  width: 90%;
  max-width: 400px;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.3);
  position: relative;
}

.modal-content h2 {
  margin-bottom: 15px;
}

.modal-content label {
  display: block;
  margin-top: 12px;
  margin-bottom: 4px;
}

.modal-content input,
.modal-content textarea {
  width: 100%;
  padding: 8px;
  font-size: 1rem;
  border: 1px solid #ccc;
  border-radius: 4px;
}

.modal-actions {
  margin-top: 20px;
  display: flex;
  justify-content: space-between;
}

.modal-actions button {
  padding: 8px 16px;
  font-size: 1rem;
  cursor: pointer;
  border: none;
  border-radius: 5px;
}

.modal-actions button[type="submit"] {
  background: #1e90ff;
  color: white;
}

.modal-actions button#cancel-order {
  background: #ccc;
}

.close-btn {
  position: absolute;
  top: 10px;
  right: 14px;
  font-size: 22px;
  cursor: pointer;
}
