/* Product pages: /packs/<slug>/ and /tools/<slug>/ */
.pack-page { overflow-x: hidden; }
.pack-main { padding-bottom: 24px; }

.breadcrumb { display: flex; flex-wrap: wrap; gap: 6px 8px; list-style: none; padding: 16px 0 0; margin: 0; font-size: .9rem; color: var(--muted); }
.breadcrumb li { display: inline-flex; align-items: center; gap: 8px; }
.breadcrumb li:not(:last-child)::after { content: "/"; color: var(--line); }
.breadcrumb a { color: var(--muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--text); }
.breadcrumb [aria-current="page"] { color: var(--text); }

.pack-hero { padding: 20px 0 36px; }
.pack-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr);
  gap: 36px;
  align-items: start;
}
.pack-visual {
  position: relative;
  background: #121019;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 630 / 500;
}
.pack-visual img, .pack-visual video, .pack-visual picture {
  display: block;
  width: 100%;
  height: 100%;
}
.pack-visual img, .pack-visual video {
  object-fit: contain;
  image-rendering: pixelated;
  background: #121019;
}
.pack-visual .still { display: none; }
@media (prefers-reduced-motion: reduce) {
  .pack-visual .motion { display: none !important; }
  .pack-visual .still { display: block; }
}

.thumb-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(72px, 1fr));
  gap: 8px;
  margin-top: 10px;
}
.thumb-strip button {
  appearance: none;
  -webkit-appearance: none;
  margin: 0;
  padding: 0;
  border: 2px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
  background: #121019;
  cursor: pointer;
  min-width: 0;
  min-height: 44px;
}
.thumb-strip button img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 630 / 500;
  object-fit: contain;
  image-rendering: pixelated;
}
.thumb-strip button[aria-pressed="true"],
.thumb-strip button:focus-visible { border-color: var(--gold); }
.thumb-strip button:hover { border-color: var(--muted); }

.pack-copy h1 { font-size: clamp(1.7rem, 3.2vw, 2.35rem); margin-bottom: .35em; }
.pack-hook { font-size: 1.05rem; color: var(--muted); max-width: 46ch; margin-bottom: 14px; }
.pack-count { margin: 0 0 12px; font-weight: 650; }
.price-row { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: baseline; margin: 0 0 16px; }
.price-row .price-free { color: var(--gold); font-weight: 700; }
.price-row .price-paid { font-weight: 750; font-size: 1.25rem; }
.pack-ctas { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 0 0 14px; }
.pack-ctas .btn { min-height: 44px; min-width: 44px; justify-content: center; }
.btn-buy { background: var(--gold-fill); color: #1b1826; border-color: transparent; }
.btn-buy:hover { background: var(--gold-fill-hover); color: #1b1826; }
.pack-trust { margin: 0 0 6px; font-size: .92rem; color: var(--muted); }
.pack-date { margin: 0; font-size: .9rem; }
.pack-devlog { margin: 8px 0 0; font-size: .92rem; }

.pack-section { padding: 48px 0; }
.pack-section h2 { margin-bottom: .6em; }
.scene-frame {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: #121019;
}
.scene-frame img, .scene-frame picture, .scene-frame video { width: 100%; height: auto; display: block; image-rendering: pixelated; }
.scene-caption { color: var(--muted); font-size: .9rem; margin: 10px 0 0; }

.contents-cols { columns: 2; column-gap: 28px; margin: 0; padding: 0 0 0 1.1em; }
.contents-cols li { break-inside: avoid; margin: .2em 0; }
.contents-block { margin: 0 0 1.1em; }
.contents-block h3 { font-size: 1rem; margin: 0 0 .4em; }

.pack-table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); -webkit-overflow-scrolling: touch; }
.pack-table-wrap table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.pack-table-wrap th, .pack-table-wrap td { padding: 12px 16px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.pack-table-wrap tr:last-child td { border-bottom: 0; }
.pack-table-wrap thead th { font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); background: var(--bg-2); }
.pack-table-wrap .cta-row .btn { margin: 4px 8px 0 0; }

.license-plain { max-width: 62ch; }
.pack-faq details { border: 1px solid var(--line); border-radius: 12px; background: var(--card); padding: 4px 16px; margin: 0 0 8px; }
.pack-faq summary { cursor: pointer; font-weight: 650; padding: 10px 0; min-height: 44px; }
.pack-faq details p { color: var(--muted); margin: 0 0 12px; }

.related-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.related-card { display: flex; flex-direction: column; text-decoration: none; color: var(--text); background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.related-card:hover { border-color: var(--gold); color: var(--text); }
.related-card img { width: 100%; height: auto; aspect-ratio: 630 / 500; object-fit: contain; image-rendering: pixelated; background: #121019; }
.related-card .related-body { padding: 12px 14px 14px; }
.related-card h3 { margin: 0 0 4px; font-size: 1rem; }

/* Sticky mobile CTA: reserved space so it does not cover content or shift layout. */
@media (max-width: 860px) {
  body.pack-page { padding-bottom: calc(76px + env(safe-area-inset-bottom, 0px)); }
  .pack-hero-grid, .related-grid { grid-template-columns: 1fr; }
  /* Copy and dual CTAs first so they stay above the fold on a 390px screen. */
  .pack-hero-grid .pack-copy { order: -1; }
  .contents-cols { columns: 1; }
  .sticky-cta {
    position: fixed;
    left: 12px;
    right: 12px;
    bottom: calc(8px + env(safe-area-inset-bottom, 0px));
    z-index: 30;
    display: none;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 8px 10px 8px 14px;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 12px;
    box-shadow: 0 8px 28px rgb(0 0 0 / .35);
  }
  .sticky-cta.is-on { display: flex; }
  .sticky-cta .sticky-price { font-weight: 700; font-size: .95rem; white-space: nowrap; }
  .sticky-cta .btn { min-height: 44px; padding: 8px 14px; }
  .sticky-cta .sticky-free { font-size: .88rem; white-space: nowrap; }
}
@media (min-width: 861px) {
  .sticky-cta { display: none !important; }
}
@media (max-width: 390px) {
  .pack-ctas { flex-direction: column; align-items: stretch; }
  .pack-ctas .btn { width: 100%; text-align: center; }
  .sticky-cta { flex-wrap: wrap; }
  .thumb-strip { grid-template-columns: repeat(3, 1fr); }
}
