/* Basic reset and styling */
* {
  box-sizing: border-box;
}
body {
  font-family: Arial, sans-serif;
  margin: 0; padding: 20px;
  background: #f9fafb;
  color: #333;
}
header {
  text-align: center;
  margin-bottom: 20px;
}
header h1 {
  font-size: 2rem;
  margin-bottom: 10px;
}
#searchInput {
  width: 100%;
  max-width: 400px;
  padding: 10px;
  font-size: 1rem;
}

#dealsContainer {
  display: grid;
  grid-template-columns: repeat(auto-fill,minmax(280px,1fr));
  gap: 20px;
  margin-bottom: 40px;
}

.deal-card {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 1px 6px rgba(0,0,0,0.1);
  padding: 15px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
}

.deal-card.expired {
  opacity: 0.6;
}

.deal-card.expired::after {
  content: "Expired";
  color: white;
  background: #ef4444;
  font-weight: bold;
  font-size: 0.9rem;
  padding: 4px 8px;
  border-radius: 4px;
  position: absolute;
  top: 10px;
  right: 10px;
}

.deal-card img {
  max-width: 100%;
  height: 150px;
  object-fit: contain;
  margin-bottom: 10px;
}

.deal-title {
  font-weight: bold;
  font-size: 1.2rem;
  margin-bottom: 8px;
}

.deal-description {
  font-size: 0.9rem;
  margin-bottom: 5px;
  flex-grow: 1;
}

.additional-text {
  font-weight: bold;
  font-size: 0.85rem;
  color: #FAA41A;
  margin-bottom: 10px;
  font-style: italic;
}

/* Original price is bright and bold now */
.original-price {
  color: #FF0000; /* bright red */
  font-weight: bold;
  margin-right: 10px;
}
/* Strike through if discounted price exists */
.has-discounted-price .original-price {
  text-decoration: line-through;
  color: #6b7280; /* muted gray */
}

.discounted-price {
  font-weight: bold;
  color: #22c55e;
  margin-right: 10px;
}

.discount-percent {
  color: #ef4444; /* red */
  font-weight: bold;
}

/* Limited Time Deal badge */
.limited-time-deal {
  font-weight: bold;
  color: #b91c1c; /* bright red */
  margin-bottom: 6px;
  font-size: 0.9rem;
}

.expiry {
  font-size: 0.85rem;
  color: #555;
  margin-bottom: 10px;
}

.btn-deal {
  background: #2563eb;
  color: white;
  padding: 10px;
  text-align: center;
  text-decoration: none;
  border-radius: 6px;
  font-weight: bold;
  transition: background 0.3s;
}

.btn-deal:hover {
  background: #1d4ed8;
}

.social-share {
  margin-top: 10px;
  font-size: 0.85rem;
}

.social-share a {
  color: #2563eb;
  text-decoration: none;
  margin-right: 10px;
}

.social-share a:hover {
  text-decoration: underline;
}

#newsletterSection {
  text-align: center;
  margin-bottom: 20px;
}

#newsletterForm {
  margin-top: 10px;
}

#newsletterForm input[type="email"] {
  padding: 8px;
  width: 250px;
  max-width: 80vw;
  border: 1px solid #ccc;
  border-radius: 4px 0 0 4px;
  font-size: 1rem;
}

#newsletterForm button {
  padding: 8px 15px;
  background-color: #2563eb;
  color: white;
  border: none;
  border-radius: 0 4px 4px 0;
  font-size: 1rem;
  cursor: pointer;
  font-weight: bold;
}

#newsletterForm button:hover {
  background-color: #1d4ed8;
}

footer {
  text-align: center;
  font-size: 0.9rem;
  color: #777;
  padding-top: 10px;
  border-top: 1px solid #ddd;
}
