/* ===== PRODUCT PAGE CSS ===== */
@import url('https://fonts.googleapis.com/css2?family=Fredoka:wght@400;600&display=swap');

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --pink:       #f4a7b9;
  --pink-light: #ffeef1;
  --pink-dark:  #e7688b;
  --cream:      #fdf5f7;
  --brown:      #5e3c3c;
  --text:       #5e3c3c;
  --muted:      #888888;
  --white:      #ffffff;
  --shadow:     0 4px 18px rgba(0,0,0,0.10);
  --radius:     14px;
  --nav-h:      80px;
  --font:       'Fredoka', sans-serif;
}

body { font-family: var(--font); background: var(--cream); color: var(--text); }
a { text-decoration: none; color: inherit; }
img { display: block; max-width: 100%; }
ul { list-style: none; }

/* NAVBAR */
.navbar {
  position: sticky; top: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: #ffeef1; padding: 0 24px; height: var(--nav-h);
  box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}
.logo-image { height: 64px; width: auto; flex-shrink: 0; }
.nav-links { display: flex; gap: 6px; align-items: center; }
.nav-links li a {
  font-size: 15px; font-weight: 600; color: var(--brown);
  padding: 6px 12px; border-radius: 20px; transition: background 0.2s, color 0.2s; white-space: nowrap;
}
.nav-links li a:hover { background: #ffffff; color: var(--pink-dark); }
.search-bar { position: relative; flex: 1; max-width: 260px; }
.input-wrapper {
  display: flex; align-items: center; background: var(--cream);
  border: 1.5px solid var(--pink); border-radius: 24px; padding: 6px 14px; gap: 8px;
}
.search-input { border: none; background: transparent; font-family: var(--font); font-size: 14px; color: var(--text); outline: none; width: 100%; }
.input-wrapper .fa-magnifying-glass { color: var(--pink-dark); font-size: 14px; }
.search-results {
  display: none; position: absolute; top: calc(100% + 6px); left: 0; right: 0;
  background: var(--white); border: 1.5px solid var(--pink); border-radius: var(--radius);
  box-shadow: var(--shadow); z-index: 200; overflow: hidden;
}
.search-results.active { display: block; }
.search-result-item { display: flex; align-items: center; gap: 10px; padding: 8px 14px; cursor: pointer; transition: background 0.15s; font-size: 14px; }
.search-result-item:hover { background: var(--pink-light); }
.search-thumb { width: 36px; height: 36px; object-fit: cover; border-radius: 8px; }
.nav-icons { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.cart-btn {
  position: relative;
  display: flex; align-items: center; justify-content: center;
  width: 42px; height: 42px; background: #ffffff;
  border-radius: 50%; color: var(--pink-dark); font-size: 18px;
  transition: background 0.2s, transform 0.2s;
}
.cart-btn:hover { background: var(--pink); transform: scale(1.08); }
.cart-badge {
  position: absolute; top: -5px; right: -5px;
  background: var(--pink-dark); color: #ffffff;
  border-radius: 50%; width: 18px; height: 18px;
  font-size: 11px; font-weight: 600;
  display: none; align-items: center; justify-content: center;
  pointer-events: none; line-height: 1;
}
.hamburger { display: none; flex-direction: column; gap: 5px; cursor: pointer; padding: 6px; border: none; background: transparent; }
.hamburger span { display: block; width: 22px; height: 2px; background: var(--brown); border-radius: 2px; }

/* PRODUCT PAGE LAYOUT */
.product-page {
  max-width: 1100px;
  margin: 48px auto;
  padding: 0 24px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}

/* GALLERY */
.product-gallery { display: flex; flex-direction: column; gap: 12px; }

.main-image {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.item-img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.thumbnail-container { display: flex; gap: 8px; flex-wrap: wrap; }

.thumb {
  width: 68px; height: 68px;
  object-fit: cover; border-radius: 10px;
  cursor: pointer; border: 2px solid transparent;
  transition: border-color 0.2s, transform 0.15s;
}
.thumb:hover { transform: scale(1.05); }
.thumb.active { border-color: var(--pink-dark); }

/* PRODUCT CONTENT */
.product-content { display: flex; flex-direction: column; gap: 16px; }

.product-content h3 {
  font-size: 1.7rem; font-weight: 600; color: var(--brown); line-height: 1.3;
}

.product-content p { color: var(--muted); font-size: 1rem; line-height: 1.65; }

.product-content hr { border: none; border-top: 1px solid var(--pink-light); }

.product-content h4 { font-size: 1rem; color: var(--brown); font-weight: 600; }

.list { padding-left: 20px; list-style: disc; }
.list li { color: var(--muted); font-size: 0.95rem; margin-bottom: 4px; }

.price { font-size: 1.6rem !important; font-weight: 600; color: var(--pink-dark) !important; }

/* VARIANTS */
.variant-selector { display: flex; flex-direction: column; gap: 8px; }
.variant-selector p { font-size: 0.9rem; color: var(--muted); }
.variant-buttons { display: flex; gap: 8px; flex-wrap: wrap; }
.variant-btn {
  padding: 8px 18px; border-radius: 20px; border: 1.5px solid var(--pink);
  background: var(--white); color: var(--brown); font-family: var(--font);
  font-size: 0.9rem; font-weight: 600; cursor: pointer; transition: all 0.2s;
}
.variant-btn:hover, .variant-btn.selected { background: var(--pink-light); border-color: var(--pink-dark); color: var(--pink-dark); }

/* QTY SELECTOR */
.quantity-selector {
  display: flex; align-items: center; gap: 12px; width: fit-content;
}
.quantity-selector button {
  width: 34px; height: 34px; border-radius: 50%;
  border: 1.5px solid var(--pink); background: var(--pink-light);
  color: var(--pink-dark); font-size: 18px; font-weight: 600;
  cursor: pointer; line-height: 1; transition: background 0.2s;
  display: flex; align-items: center; justify-content: center;
}
.quantity-selector button:hover { background: var(--pink); color: var(--white); }
.quantity-selector input {
  width: 48px; text-align: center; border: 1.5px solid var(--pink);
  border-radius: 10px; padding: 6px; font-family: var(--font);
  font-size: 1rem; color: var(--text); background: var(--cream); outline: none;
}

/* ADD TO CART */
.addtocart-btn button {
  padding: 14px 36px; background: var(--pink-dark); color: var(--white);
  border: none; border-radius: 30px; font-family: var(--font);
  font-size: 1rem; font-weight: 600; cursor: pointer;
  transition: background 0.2s, transform 0.2s;
  box-shadow: 0 4px 16px rgba(231,104,139,0.25);
}
.addtocart-btn button:hover { background: #c44a6e; transform: translateY(-2px); }

/* Toast */
.toast {
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%);
  background: var(--white); color: var(--pink-dark); padding: 12px 26px;
  border-radius: 30px; font-size: 1rem; font-weight: 600;
  box-shadow: var(--shadow); z-index: 999; opacity: 0;
  transition: opacity 0.3s; pointer-events: none; white-space: nowrap;
}
.toast.show { opacity: 1; }

/* Footer */
.site-footer { background: #ffeef1; color: var(--text); text-align: center; padding: 36px 24px; margin-top: 60px; }
.footer-content { display: flex; justify-content: center; gap: 64px; flex-wrap: wrap; margin-bottom: 20px; }
.footer-col { min-width: 140px; text-align: left; }
.site-footer h3 { font-size: 1rem; font-weight: 600; margin-bottom: 10px; color: var(--brown); text-transform: uppercase; letter-spacing: 0.5px; }
.site-footer a { color: var(--pink-dark); transition: color 0.2s; }
.site-footer a:hover { color: var(--brown); }
.site-footer p { margin-bottom: 6px; font-size: 0.9rem; }
.footer-note { margin-top: 4px; font-size: 0.82rem; opacity: 0.7; }

/* MOBILE */
@media (max-width: 768px) {
  .navbar { flex-wrap: wrap; height: auto; padding: 10px 16px; gap: 8px; }
  .logo-image { height: 50px; }
  .hamburger { display: flex; order: 3; }
  .nav-links { display: none; flex-direction: column; width: 100%; order: 5; padding-bottom: 10px; gap: 2px; }
  .nav-links.open { display: flex; }
  .nav-links li a { display: block; padding: 10px 14px; border-radius: 10px; }
  .search-bar { order: 4; max-width: 100%; flex: 1 1 100%; }
  .nav-icons { order: 2; margin-left: auto; }

  .product-page { grid-template-columns: 1fr; gap: 28px; margin: 28px auto; }
  .product-content { order: 2; }
  .product-gallery { order: 1; }
  .thumb { width: 56px; height: 56px; }
}
