:root {
  --bg: #f6f2ee;
  --text: #2b2b2b;
  --accent: #c05a3b;
  --card: #ffffff;
  --muted: #6b6b6b;
  --line: #e7ddd5;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
}
.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 28px;
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.logo-wrap { display: flex; align-items: center; gap: 12px; }
.logo { width: 56px; height: 56px; object-fit: cover; border-radius: 10px; }
.brand-name { font-weight: 800; letter-spacing: 0.5px; }
.brand-sub { color: var(--muted); font-size: 13px; }
.btn {
  text-decoration: none;
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid var(--accent);
  color: var(--accent);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.btn.primary {
  background: var(--accent);
  color: #fff;
}
.hero {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  padding: 24px 28px;
}
.hero h1 { margin: 0 0 8px 0; }
.hero-meta { display: flex; gap: 8px; flex-wrap: wrap; }
.pill {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 12px;
}
.filters {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 0 28px 16px 28px;
}
.filter-row {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}
.filters input {
  flex: 1;
  min-width: 220px;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fff;
}
.family-filters {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.family-filters button {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 999px;
  padding: 8px 14px;
  font-weight: 600;
  cursor: pointer;
  color: var(--text);
}
.family-filters button.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
.note { color: var(--muted); font-size: 12px; }
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  padding: 0 28px 28px 28px;
}
.card {
  background: var(--card);
  border: 1px solid #eee;
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.08);
}
.card img.main {
  width: 100%;
  height: 220px;
  object-fit: cover;
  background: #f3f3f3;
}
.card-body { padding: 12px 14px; display: flex; flex-direction: column; gap: 8px; }
.card-title { font-weight: 700; }
.card-price { font-weight: 700; color: var(--accent); }
.card-meta { font-size: 12px; color: var(--muted); }
.badge { font-size: 11px; padding: 2px 8px; border-radius: 999px; border: 1px solid var(--line); display: inline-block; }
.variant-row { display: flex; gap: 6px; flex-wrap: wrap; }
.variant-row img { width: 36px; height: 36px; object-fit: cover; border-radius: 6px; border: 1px solid var(--line); cursor: pointer; }
.card-actions { display: flex; gap: 8px; align-items: center; }
.site-footer { padding: 20px 28px; color: var(--muted); font-size: 12px; }
.site-footer.secondary {
  padding-top: 0;
  padding-bottom: 28px;
  border-top: 1px solid var(--line);
  background: #fff;
}
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.footer-copy div {
  font-size: 11px;
}
.footer-social {
  display: flex;
  gap: 10px;
}
.footer-social a {
  width: 32px;
  height: 32px;
  border-radius: 999px;
  border: 1px solid var(--line);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  transition: border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}
.footer-social a:hover {
  color: var(--accent);
  border-color: var(--accent);
  transform: translateY(-1px);
}
.footer-social svg {
  width: 16px;
  height: 16px;
  display: block;
}
.empty {
  display: none;
  padding: 0 28px 28px 28px;
  color: var(--muted);
}
.empty.show { display: block; }

.modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 50;
}
.modal.hidden { display: none; }
.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
}
.modal-panel {
  position: relative;
  background: #fff;
  border-radius: 16px;
  width: min(900px, 92vw);
  max-height: 90vh;
  overflow: auto;
  padding: 20px;
  z-index: 1;
}
.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 6px 12px;
  cursor: pointer;
}
.modal-content {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) minmax(240px, 1fr);
  gap: 20px;
  align-items: start;
}
.modal-gallery .modal-main {
  width: 100%;
  height: 320px;
  object-fit: cover;
  border-radius: 12px;
  background: #f3f3f3;
}
.modal-thumbs {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  flex-wrap: wrap;
}
.modal-thumbs img {
  width: 58px;
  height: 58px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--line);
  cursor: pointer;
}
.modal-title { font-weight: 800; font-size: 20px; margin-bottom: 4px; }
.modal-price { color: var(--accent); font-weight: 700; margin-bottom: 4px; }
.modal-family { color: var(--muted); font-size: 12px; margin-bottom: 10px; }
.modal-desc { margin: 0 0 12px 0; color: var(--text); }
.modal-attrs { display: flex; flex-direction: column; gap: 6px; }
.modal-attrs div { font-size: 13px; color: var(--muted); }
.modal-actions { margin-top: 16px; }

@media (max-width: 720px) {
  .site-header { flex-direction: column; align-items: flex-start; gap: 10px; }
  .hero { flex-direction: column; align-items: flex-start; }
  .modal-content { grid-template-columns: 1fr; }
  .modal-gallery .modal-main { height: 260px; }
}
