:root {
  --bg-white: #FFFFFF;
  --bg-dark: #2E3036;
  --text-dark: #1C1C1E;
  --text-muted: #6B6E76;
  --btn-dark: #1C1C1E;
  --btn-hover: #111111;
}

/* RESET */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Inter', sans-serif;
}

body {
  background: var(--bg-white);
  color: var(--text-dark);
  text-align: center;
}

/* ================= NAV ================= */
nav {
  padding: 28px 8%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #E3E3E3;
  position: relative;
}

nav h1 {
  letter-spacing: 3px;
  font-weight: 600;
}

.nav-links {
  display: flex;
  gap: 20px;
}

nav a {
  text-decoration: none;
  color: var(--text-muted);
  margin-left: 25px;
  transition: 0.15s;
}

nav a:hover {
  color: var(--text-dark);
}

/* MENU */
.menu-btn {
  display: none;
  font-size: 24px;
  cursor: pointer;
}

/* ================= COLLECTION ================= */
.collection {
  padding: 80px 8%;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 280px));
  justify-content: center;
  gap: 40px;
}

.collection h2 {
  grid-column: 1 / -1;
  text-align: center;
  margin-bottom: 30px;
  font-size: 2rem;
  font-weight: 700;
}

/* ================= CARD ================= */
.card {
  background: #fff;
  width: 100%;
  border-radius: 18px;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card img {
  width: 100%;
  height: 220px;
  object-fit: cover;
}

.card-content {
  padding: 20px;
  text-align: left;
}

.card-content h3 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.card-content p.price {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--btn-dark);
  margin-bottom: 10px;
}

.card-content p.description {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.4;
  margin-bottom: 15px;
}

/* ================= TAGS ================= */
.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.tags span {
  background: #F5F0EC;
  color: var(--btn-dark);
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 500;
}

/* ================= BUTTONS ================= */
.btn,
.view-btn {
  padding: 12px 28px;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  display: inline-block;
  transition: all 0.15s ease;
}

.btn {
  background: var(--btn-dark);
  color: var(--bg-white);
}

.view-btn {
  background: transparent;
  color: var(--text-dark);
  border: 1px solid #1C1C1E;
}

/* 👉 spacing fix area */
.card-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 14px;
  gap: 12px;
}

/* ================= FAVORITE ================= */
.favourite-btn {
  background: transparent;
  border: none;
  cursor: pointer;

  padding: 8px;
  display: flex;
  align-items: center;
  justify-content: center;

  transition: transform 0.15s ease;
}

/* SVG heart */
.heart-icon {
  width: 28px;
  height: 28px;

  fill: none;
  stroke: #999;
  stroke-width: 2;

  transition: all 0.25s ease;
}

/* hover effect */
.favourite-btn:hover {
  transform: scale(1.1);
}

/* ACTIVE = filled heart */
.favourite-btn.active .heart-icon {
  fill: red;
  stroke: red;
  transform: scale(1.15);
}

/* little pop when toggled */
.favourite-btn.active {
  animation: heartPop 0.25s ease;
}

/* animation */
@keyframes heartPop {
  0% { transform: scale(1); }
  50% { transform: scale(1.25); }
  100% { transform: scale(1); }
}

/* ================= TOAST ================= */
.toast {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background: #e9ddcd;
  color: #110f0f;
  padding: 12px 20px;
  border-radius: 8px;
  font-weight: 500;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  opacity: 0;
  transform: translateX(100%);
  transition: 0.5s ease;
  z-index: 9999;
}

.toast.show {
  opacity: 1;
  transform: translateX(0);
}

/* ================= MODAL ================= */
.overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  display: none;
  justify-content: center;
  align-items: center;
  backdrop-filter: blur(6px);
}

.overlay.show {
  display: flex;
}

.modal {
  background: white;
  padding: 25px;
  border-radius: 16px;
  width: 320px;
  animation: pop 0.25s ease;
}

@keyframes pop {
  from { transform: scale(0.9); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

/* ================= INTERACTIONS ================= */
.btn.clicked {
  transform: scale(0.95);
}

/* ================= FOOTER ================= */
footer {
  padding: 50px 8%;
  color: var(--text-muted);
  font-size: 0.9rem;
  border-top: 1px solid #E3E3E3;
  margin-top: 50px;
}

/* ================= MOBILE NAV ================= */
@media (max-width: 768px) {
  body {
    text-align: left;
  }

  .menu-btn {
    display: block;
  }

  .nav-links {
    display: none;
    flex-direction: column;
    background: white;
    position: absolute;
    top: 80px;
    left: 0;
    width: 100%;
    padding: 20px;
    border-bottom: 1px solid #E3E3E3;
  }

  .nav-links.active {
    display: flex;
  }

  .nav-links a {
    margin: 10px 0;
    font-size: 16px;
  }

  .btn,
  .view-btn {
    width: 100%;
    text-align: center;
  }

  .btn:active,
  .view-btn:active {
    transform: scale(0.96);
  }

  .card-content {
    padding: 16px;
  }

  /* spacing still clean on mobile */
  .card-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .favourite-btn {
    align-self: flex-end;
  }
}

/* ================= HOVER (DESKTOP ONLY) ================= */
@media (hover: hover) {
  .btn:hover {
    background: var(--btn-hover);
    transform: translateY(-2px);
  }

  .view-btn:hover {
    background: #f5f5f5;
    transform: translateY(-2px);
  }

  .card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
  }
}

/* ================= RESPONSIVE GRID ================= */
@media (max-width: 900px) {
  .collection {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 500px) {
  .collection {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 700px) {
  .collection {
    gap: 30px;
  }
}