#produk {
  background: radial-gradient(ellipse at 90% 0, #e6eeff, transparent 52%), #f6f8fc;
}

#produk .portfolio-heading {
  align-items: start;
  margin-bottom: clamp(24px, 4vw, 44px);
}

.product-gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(12px, 2vw, 24px);
}

.gallery-card {
  --gallery-accent: #1858b3;
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
  background: #fff;
  padding: 8px;
  border: 1px solid #dbe3ef;
  border-radius: 24px;
  box-shadow: 0 15px 36px #183e7010;
}

.gallery-card:hover, .gallery-card:focus-within { border-color: var(--gallery-accent); }
.gallery-fashion { --gallery-accent: #6741ae; }
.gallery-pesan { --gallery-accent: #126b56; }

.gallery-cover {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(4px, 1vw, 14px);
  height: clamp(112px, 20vw, 226px);
  padding: 12px;
  border-radius: 16px;
}

.gallery-cover-kasir {
  background: radial-gradient(ellipse at 50% 100%, #c4812f, transparent 68%), linear-gradient(135deg, #261b18, #654023);
}
.gallery-cover-kasir img {
  display: block;
  height: 91%;
  width: auto;
  max-width: 44%;
  object-fit: contain;
  border-radius: 6px;
  box-shadow: 0 8px 18px #10090755;
}
.gallery-cover-kasir img:first-child { transform: translateY(-3px); }
.gallery-cover-kasir img:last-child { transform: translateY(3px); }

.gallery-cover-fashion {
  background: radial-gradient(ellipse at 80% 10%, #8d6ed5, transparent 68%), #392663;
}
.gallery-catalog {
  display: grid;
  gap: 5px;
  width: min(100%, 200px);
  padding: clamp(7px, 1.5vw, 14px);
  border-radius: 12px;
  background: #fbf8ff;
  color: #31214e;
  box-shadow: 0 12px 24px #1a103855;
  font-size: clamp(.68rem, 1.35vw, .95rem);
}
.gallery-catalog small { color: #645678; }
.gallery-swatches { display: flex; gap: 6%; }
.gallery-swatches span {
  flex: 1;
  aspect-ratio: 4 / 5;
  border-radius: 8px;
  background: #373345;
}
.gallery-swatches span:nth-child(2) { background: #ead4b1; }
.gallery-swatches span:nth-child(3) { background: #8e9e88; }
.gallery-cover-pesan {
  background: radial-gradient(ellipse at 85% 0, #258e72, transparent 68%), #103e35;
  color: #fff;
  font-size: clamp(1.15rem, 3vw, 2.4rem);
  font-weight: 800;
  letter-spacing: -.045em;
}
.gallery-brand {
  display: grid;
  justify-items: center;
  gap: 4px;
  line-height: 1;
}
.gallery-cover-pesan b { color: #a7f3d0; }

.gallery-copy {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 8px;
  padding: clamp(11px, 2vw, 22px);
  overflow-wrap: anywhere;
}
.gallery-copy p, .gallery-copy h3 { margin: 0; }
.gallery-copy p { color: var(--muted); font-size: .95rem; }
.gallery-copy .gallery-category {
  color: var(--gallery-accent);
  font-size: .7rem;
  font-weight: 800;
  letter-spacing: .05em;
}
.gallery-copy h3 { font-size: clamp(1.05rem, 2.4vw, 1.7rem); line-height: 1.2; letter-spacing: -.035em; }
.gallery-identity {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.gallery-identity img {
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  padding: 4px;
  object-fit: contain;
  background: #fff;
  border: 1px solid #dce5f0;
  border-radius: 10px;
}
.gallery-copy a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  min-height: 44px;
  margin-top: 8px;
  padding: 6px 10px;
  border: 1px solid #dce5f0;
  border-radius: 9px;
  color: var(--gallery-accent);
  font-weight: 800;
  text-decoration: none;
}
.gallery-copy > p:not(.gallery-category) { flex: 1; }
.gallery-copy a:hover { background: #f3f6fc; border-color: currentColor; }

#produk .product { display: none; scroll-margin-top: 112px; }
#produk .product:target { display: grid; margin-top: 30px; }
.gallery-return { display: none; }
#produk .product:target ~ .gallery-return { display: block; margin-top: 18px; }
.gallery-return a { color: var(--blue); font-weight: 700; }

@media (max-width: 540px) {
  .product-gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .gallery-card { padding: 5px; border-radius: 16px; }
  .gallery-copy { gap: 6px; padding: 9px 6px 6px; }
  .gallery-copy p { font-size: .82rem; line-height: 1.45; }
  .gallery-copy .gallery-category { font-size: .64rem; }
  .gallery-identity { gap: 6px; }
  .gallery-identity img { width: 34px; height: 34px; padding: 3px; border-radius: 8px; }
  .gallery-copy a { font-size: .8rem; padding-inline: 6px; }
  .gallery-cover { padding: 7px; border-radius: 11px; }
  .gallery-pesan {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr);
    align-items: stretch;
    gap: 8px;
  }
  .gallery-cover-pesan { height: auto; min-height: 112px; }
}
