/* ── Build page ─────────────────────────────────────────── */

.build-head {
  position: relative;
}

/* Real photo of the box, framed like a print */
.build-photo {
  position: relative;
  border: 2.5px solid var(--ink);
  border-radius: 4px;
  overflow: hidden;
  background: rgba(31, 27, 22, 0.06);
  box-shadow: 5px 6px 0 rgba(31, 27, 22, 0.14);
  transform: rotate(-0.5deg);
}
.build-photo img {
  width: 100%;
  display: block;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  object-position: center;
}
@media (min-width: 768px) {
  .build-photo img { aspect-ratio: 4 / 3; }
}

/* Hand-written caption under a photo */
.photo-caption {
  font-family: 'Caveat', cursive;
  font-size: 20px;
  line-height: 1.25;
  color: rgba(31, 27, 22, 0.7);
  display: inline-block;
  transform: rotate(-1deg);
}

/* ── The parts list ─────────────────────────────────────── */

.parts {
  border: 2.5px solid var(--ink);
  border-radius: 4px;
  background: var(--cream);
  box-shadow: 5px 6px 0 rgba(31, 27, 22, 0.12);
  overflow: hidden;
}

.part {
  display: flex;
  align-items: baseline;
  gap: 14px;
  padding: 16px 18px;
  border-bottom: 1px dashed rgba(31, 27, 22, 0.22);
}
.part:last-child { border-bottom: none; }

.part-num {
  font-family: 'Caprasimo', serif;
  font-size: 19px;
  line-height: 1;
  color: var(--ink);
  opacity: 0.35;
  flex: 0 0 auto;
  min-width: 26px;
  padding-top: 3px;
}

.part-body { flex: 1 1 auto; min-width: 0; }

.part-name {
  font-family: 'Caprasimo', serif;
  font-size: 17px;
  line-height: 1.25;
  color: var(--ink);
}
.part-name a {
  color: inherit;
  text-decoration: none;
  border-bottom: 2px solid var(--mustard);
  padding-bottom: 1px;
  transition: border-color 0.2s ease, color 0.2s ease;
}
.part-name a:hover { color: var(--cherry); border-color: var(--cherry); }

.part-note {
  font-size: 14.5px;
  line-height: 1.4;
  opacity: 0.72;
  margin-top: 4px;
}

/* Empty slot — a value only the owner has */
.slot {
  font-family: 'Caveat', cursive;
  font-size: 19px;
  color: rgba(31, 27, 22, 0.45);
  background: rgba(242, 193, 78, 0.22);
  border-radius: 2px;
  padding: 0 4px;
  white-space: nowrap;
}

.part--dollartree { background: rgba(111, 179, 210, 0.12); }
.part--printed { background: rgba(103, 168, 122, 0.13); }

/* Back-to-home pill */
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'Fraunces', serif;
  font-weight: 500;
  font-size: 17px;
  color: var(--ink);
  background: var(--cream);
  padding: 10px 20px;
  border: 2.5px solid var(--ink);
  border-radius: 999px;
  text-decoration: none;
  box-shadow: 3px 4px 0 rgba(31, 27, 22, 0.14);
  transition: all 0.2s ease;
}
.back-link:hover {
  background: var(--mustard);
  transform: translateY(-2px);
  box-shadow: 5px 6px 0 rgba(31, 27, 22, 0.2);
}

@media (max-width: 640px) {
  .part { gap: 10px; padding: 14px 15px; }
  .build-photo { transform: rotate(0); }
}
