/* Reset cơ bản */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Poppins", sans-serif;
}

/* BODY */
body {
  font-family: 'Poppins', sans-serif;
  color: #fff;
  background: 
    linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)),
    url('image/banner/z7142830940785_2699f98ca09d36773f81393a5f6ea6eb.jpg') no-repeat center center fixed;
  background-size: cover;
  line-height: 1.6;
}

/* ===== HEADER ===== */
header {
  background: linear-gradient(135deg, #ff4b2b, #ff416c);
  box-shadow: 0 3px 10px rgba(0,0,0,0.2);
  position: sticky;
  top: 0;
  z-index: 1000;
}

/* Menu */
nav ul {
  list-style: none;
  display: flex;
  justify-content: center;
  padding: 15px 0;
}

nav ul li { margin: 0 20px; }

nav ul li a {
  color: white;
  font-size: 18px;
  text-decoration: none;
  font-weight: 500;
  display: flex;
  align-items: center;
  transition: 0.3s;
}

nav ul li a i { margin-right: 8px; }

nav ul li a:hover {
  color: #fff200;
  transform: scale(1.1);
}

/* ===== GIỎ HÀNG ICON ===== */
.cart-icon {
  position: fixed;
  top: 20px;
  right: 20px;
  background: #0072ff;
  color: white;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  z-index: 1100;
  font-size: 24px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.3);
}

.cart-icon span {
  position: absolute;
  top: -5px;
  right: -5px;
  background: red;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  color: white;
  font-size: 12px;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* ===== GIỎ HÀNG SIDEBAR ===== */
.cart {
  position: fixed;
  right: -400px;
  top: 0;
  width: 350px;
  height: 100%;
  background: #f8f9fa;
  box-shadow: -3px 0 10px rgba(0,0,0,0.2);
  padding: 20px;
  transition: right 0.3s ease;
  z-index: 1050;
  color: #333;
}

.cart.show { right: 0; }

.cart h3 { margin-top: 0; }

.cart ul { list-style: none; padding: 0; max-height: 60%; overflow-y: auto; }

.cart li { display: flex; justify-content: space-between; margin-bottom: 10px; }

.cart-total { font-weight: bold; margin-top: 10px; }

.cart button { margin-top: 10px; width: 100%; padding: 10px; cursor: pointer; }

/* ===== PRODUCT CARD ===== */
.product-section { padding: 60px 5%; }
.product-section h2 { font-size: 32px; margin-bottom: 40px; text-transform: uppercase; position: relative; }
.product-section h2::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -10px;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background: linear-gradient(90deg, #ff416c, #ff4b2b);
  border-radius: 2px;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 25px;
}

.product-card {
  background: white;
  border-radius: 15px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  text-align: center;
  padding: 20px;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.product-card:hover { transform: translateY(-10px); box-shadow: 0 8px 20px rgba(0,0,0,0.2); }

.product-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 12px;
  transition: transform 0.4s ease;
}

.product-card:hover img { transform: scale(1.1); }

.product-name { font-size: 17px; font-weight: bold; color: #333; margin-top: 12px; }

.product-price { font-size: 16px; color: #ff416c; font-weight: 600; margin: 8px 0; }

/* Buttons sản phẩm */
.product-buttons { display: flex; justify-content: center; gap: 10px; margin-top: 15px; }

.add-cart-btn {
  background: linear-gradient(90deg, #00c6ff, #0072ff);
  color: white;
  box-shadow: 0 3px 8px rgba(0,114,255,0.3);
  border-radius: 30px;
  padding: 10px 18px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.add-cart-btn:hover {
  background: linear-gradient(90deg, #0072ff, #00c6ff);
  transform: scale(1.08) rotate(-1deg);
  box-shadow: 0 5px 15px rgba(0,114,255,0.4);
  animation: shakeCart 0.4s ease;
}

.buy-btn {
  background: linear-gradient(90deg, #ff416c, #ff4b2b);
  color: #fff;
  box-shadow: 0 3px 8px rgba(255,65,108,0.3);
  border-radius: 30px;
  padding: 10px 18px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.buy-btn:hover {
  transform: scale(1.08) rotate(1deg);
  box-shadow: 0 5px 15px rgba(255,65,108,0.4);
}

@keyframes shakeCart {
  0% { transform: scale(1) rotate(0deg); }
  25% { transform: scale(1.1) rotate(-5deg); }
  50% { transform: scale(1.05) rotate(5deg); }
  75% { transform: scale(1.1) rotate(-3deg); }
  100% { transform: scale(1.05) rotate(0deg); }
}

/* Nút quay lại */
a[href="index.html"] {
  display: inline-block;
  background-color: #109ea1;
  color: white;
  padding: 12px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  box-shadow: 0 3px 8px rgba(0,0,0,0.2);
  transition: all 0.3s ease;
}

a[href="index.html"]:hover {
  background-color: #0db3b6;
  transform: translateY(-3px);
}

/* Footer */
footer {
  text-align: center;
  background: #222;
  color: white;
  padding: 20px 0;
  margin-top: 60px;
  font-size: 15px;
}
