.gtg-single-product {
  --gtg-product-ink: var(--gtg-shop-ink, var(--gtg-ink, #252b32));
  --gtg-product-muted: var(--gtg-shop-muted, #62564d);
  --gtg-product-card: var(--gtg-shop-card, var(--gtg-paper, #fffaf3));
  --gtg-product-paper: var(--gtg-shop-paper, #fffdf8);
  --gtg-product-accent: var(--gtg-shop-accent, var(--gtg-orange, #f26522));
  --gtg-product-yellow: var(--gtg-shop-yellow, var(--gtg-yellow, #f4bf45));
  --gtg-product-green: #2f8f42;
  --gtg-product-shadow: var(--gtg-shop-shadow, var(--gtg-ink, #252b32));
  --gtg-product-section-gap: clamp(1rem, 2vw, 1.35rem);
  display: grid;
  gap: var(--gtg-product-section-gap);
  padding-top: clamp(1.1rem, 4vw, 2.4rem);
  padding-bottom: clamp(2rem, 5vw, 4rem);
  color: var(--gtg-product-ink);
}

.gtg-single-product,
.gtg-single-product * { box-sizing: border-box; }
.gtg-single-product a { color: inherit; }
.gtg-single-product [hidden] { display: none !important; }

.gtg-single-product__back { margin: 0; }
.gtg-single-product__back a {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  color: var(--gtg-product-muted);
  font-weight: 950;
  text-decoration: none;
}
.gtg-single-product__back a:hover { color: var(--gtg-product-accent); }

.gtg-single-product__hero {
  display: grid;
  grid-template-columns: minmax(0, 1.04fr) minmax(330px, .76fr);
  gap: clamp(1rem, 3vw, 2rem);
  align-items: stretch;
}

.gtg-single-product__gallery,
.gtg-single-product__buy-card,
.gtg-single-product__panel,
.gtg-single-product__related {
  border: 2px solid var(--gtg-product-ink);
  border-radius: 22px;
  background: var(--gtg-product-card);
  box-shadow: 4px 4px 0 var(--gtg-product-shadow);
}

.gtg-single-product__gallery {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  gap: .8rem;
  min-height: 100%;
  padding: clamp(.75rem, 2vw, 1rem);
}

.gtg-single-product__main-image {
  position: relative;
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  min-height: 440px;
  padding: clamp(.85rem, 2.5vw, 1.4rem);
  border: 0;
  border-radius: 18px;
  background: #fffaf2;
  cursor: zoom-in;
  overflow: hidden;
}
.gtg-single-product__main-image img {
  display: block;
  width: 100%;
  height: 100%;
  max-height: 620px;
  object-fit: contain;
  filter: drop-shadow(0 10px 14px rgba(31,34,38,.13));
}
.gtg-single-product__main-image span {
  position: absolute;
  right: .75rem;
  bottom: .75rem;
  display: inline-flex;
  padding: .32rem .58rem;
  border: 2px solid var(--gtg-product-ink);
  border-radius: 999px;
  background: var(--gtg-product-yellow);
  box-shadow: 2px 2px 0 var(--gtg-product-shadow);
  font-size: .76rem;
  font-weight: 950;
}
.gtg-single-product__main-image--placeholder { cursor: default; }

.gtg-single-product__thumbs { display: flex; flex-wrap: wrap; gap: .55rem; }
.gtg-single-product__thumb {
  width: 72px;
  height: 72px;
  padding: .25rem;
  border: 2px solid rgba(37,32,29,.3);
  border-radius: 14px;
  background: #fffaf2;
  cursor: pointer;
}
.gtg-single-product__thumb.is-active { border-color: var(--gtg-product-ink); box-shadow: 2px 2px 0 var(--gtg-product-shadow); }
.gtg-single-product__thumb img { width: 100%; height: 100%; object-fit: contain; }

.gtg-single-product__buy-card {
  position: sticky;
  top: clamp(5.5rem, 10vh, 6.75rem);
  display: flex;
  flex-direction: column;
  gap: .78rem;
  min-height: 100%;
  padding: clamp(1rem, 2.5vw, 1.45rem);
}
.admin-bar .gtg-single-product__buy-card { top: calc(clamp(5.5rem, 10vh, 6.75rem) + 32px); }

.gtg-single-product h1 {
  margin: 0;
  max-width: 12ch;
  font-family: var(--gtg-font-heading, inherit);
  font-size: clamp(2rem, 4.1vw, 3.25rem);
  line-height: .98;
  letter-spacing: -.025em;
}
.gtg-single-product h1.is-long { max-width: 16ch; font-size: clamp(1.75rem, 3.3vw, 2.55rem); line-height: 1.03; }
.gtg-single-product h1.is-very-long { max-width: 19ch; font-size: clamp(1.55rem, 2.65vw, 2.15rem); line-height: 1.08; letter-spacing: -.015em; }

.gtg-single-product__pitch { margin: 0; color: var(--gtg-product-muted); font-size: 1rem; font-weight: 800; line-height: 1.35; }
.gtg-single-product__price { color: var(--gtg-product-accent); font-size: clamp(1.6rem, 4vw, 2.25rem); font-weight: 950; line-height: 1; }
.gtg-single-product__price del { opacity: .6; font-size: .7em; }
.gtg-single-product__price ins { text-decoration: none; }

.gtg-single-product__stock {
  width: fit-content;
  margin: 0;
  padding: .35rem .65rem;
  border: 2px solid var(--gtg-product-ink);
  border-radius: 999px;
  box-shadow: 2px 2px 0 var(--gtg-product-shadow);
  font-weight: 950;
}
.gtg-single-product__stock.is-in { background: #d8efc4; }
.gtg-single-product__stock.is-low { background: var(--gtg-product-yellow); }
.gtg-single-product__stock.is-out { background: #f1b7a8; }

.gtg-single-product__chips {
  display: flex;
  flex-wrap: wrap;
  gap: .35rem .65rem;
  align-items: center;
  margin-top: -.2rem;
}
.gtg-single-product__chips span { display: inline-flex; color: var(--gtg-product-muted); font-size: .84rem; font-weight: 900; line-height: 1.1; }
.gtg-single-product__chips span::before { content: '#'; color: var(--gtg-product-accent); margin-right: .08rem; }

.gtg-single-product__cart-actions {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  gap: .65rem;
  align-items: end;
  margin-top: auto;
}
.gtg-single-product__qty { display: grid; gap: .3rem; color: var(--gtg-product-muted); font-size: .72rem; font-weight: 950; text-transform: uppercase; }
.gtg-single-product__qty input,
.gtg-single-product__back-in-stock input {
  width: 100%;
  min-height: 48px;
  padding: .65rem .65rem;
  border: 2px solid var(--gtg-product-ink);
  border-radius: 12px;
  background: #fff;
  color: var(--gtg-product-ink);
  font: inherit;
  font-weight: 850;
}
.gtg-single-product__qty input { text-align: center; appearance: textfield; -moz-appearance: textfield; }
.gtg-single-product__qty input::-webkit-outer-spin-button,
.gtg-single-product__qty input::-webkit-inner-spin-button { margin: 0; }

.gtg-single-product__add,
.gtg-single-product__checkout,
.gtg-single-product__back-in-stock button,
.gtg-single-product__after-add a:not(.gtg-single-product__checkout),
.gtg-single-product__rail-controls button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: .68rem .9rem;
  border: 2px solid var(--gtg-product-ink);
  border-radius: 14px;
  background: var(--gtg-product-accent);
  color: #fff !important;
  box-shadow: 4px 4px 0 var(--gtg-product-shadow);
  font: inherit;
  font-weight: 950;
  text-decoration: none !important;
  cursor: pointer;
  transform: translate(0, 0);
  transition: transform .12s ease, box-shadow .12s ease, filter .12s ease;
}
.gtg-single-product__add:hover,
.gtg-single-product__checkout:hover,
.gtg-single-product__back-in-stock button:hover,
.gtg-single-product__after-add a:not(.gtg-single-product__checkout):hover,
.gtg-single-product__rail-controls button:hover { filter: brightness(1.03); transform: translate(1px, 1px); box-shadow: 3px 3px 0 var(--gtg-product-shadow); }
.gtg-single-product__add:active,
.gtg-single-product__checkout:active,
.gtg-single-product__back-in-stock button:active,
.gtg-single-product__after-add a:not(.gtg-single-product__checkout):active,
.gtg-single-product__rail-controls button:active { transform: translate(4px, 4px); box-shadow: 0 0 0 var(--gtg-product-shadow); }
.gtg-single-product__add.is-loading,
.gtg-single-product__add[aria-disabled='true'] { cursor: wait; opacity: .76; }
.gtg-single-product__add.is-added { background: var(--gtg-product-yellow); color: var(--gtg-product-ink) !important; }

.gtg-single-product__after-add {
  display: grid;
  gap: .55rem;
  padding: .75rem;
  border: 2px solid var(--gtg-product-ink);
  border-radius: 14px;
  background: #fff3cf;
}
.gtg-single-product__after-add div { display: grid; grid-template-columns: 1fr 1fr; gap: .55rem; }
.gtg-single-product__after-add a:not(.gtg-single-product__checkout) { background: var(--gtg-product-card); color: var(--gtg-product-ink) !important; }

.gtg-single-product__back-in-stock {
  display: grid;
  gap: .6rem;
  margin-top: auto;
  padding: .85rem;
  border: 2px solid var(--gtg-product-ink);
  border-radius: 16px;
  background: #fff3cf;
}
.gtg-single-product__back-in-stock p { margin: 0; color: var(--gtg-product-muted); line-height: 1.35; }
.gtg-single-product__back-in-stock small { min-height: 1.2em; font-weight: 850; }
.gtg-single-product__back-in-stock small[data-type='success'] { color: #2d6f2e; }
.gtg-single-product__back-in-stock small[data-type='error'] { color: #9d2d1c; }

.gtg-single-product__stats {
  display: grid;
  grid-template-columns: minmax(0, .78fr) minmax(240px, .42fr);
  gap: 1rem;
  align-items: stretch;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}
.gtg-single-product__score-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  align-items: stretch;
  padding: .5rem .7rem;
  border: 2px solid rgba(37,32,29,.22);
  border-radius: 14px;
  background: #fffdf8;
  box-shadow: 3px 3px 0 var(--gtg-product-shadow);
}
.gtg-single-product__score-card {
  --score-live: 0;
  display: grid;
  justify-items: center;
  align-content: center;
  gap: .46rem;
  min-height: 132px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--gtg-product-ink);
  box-shadow: none;
  text-align: center;
}
.gtg-single-product__score-title {
  color: var(--gtg-product-muted);
  font-size: clamp(.98rem, 1.25vw, 1.16rem);
  font-weight: 950;
  letter-spacing: .01em;
  line-height: 1;
}
.gtg-single-product__score-ring {
  display: grid;
  place-items: center;
  width: clamp(88px, 8.6vw, 112px);
  aspect-ratio: 1;
  border-radius: 50%;
  background:
    radial-gradient(circle at center, #151719 0 56%, transparent 57%),
    conic-gradient(from -90deg, var(--gtg-product-green) 0 calc(var(--score-live, 0) * 1%), #101214 calc(var(--score-live, 0) * 1%) 100%);
  border: 5px solid #101214;
}
.gtg-single-product__score-ring strong {
  position: relative;
  z-index: 1;
  color: #fff;
  font-size: clamp(1rem, 1.6vw, 1.32rem);
  line-height: .95;
  max-width: 86%;
  overflow-wrap: anywhere;
}
.gtg-single-product__side-facts {
  display: grid;
  grid-template-rows: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  height: 100%;
}
.gtg-single-product__side-facts div {
  display: grid;
  align-content: center;
  gap: .16rem;
  min-height: 0;
  padding: .5rem .7rem;
  border: 2px solid rgba(37,32,29,.22);
  border-radius: 14px;
  background: #fffdf8;
}
.gtg-single-product__side-facts span { color: var(--gtg-product-muted); font-size: .72rem; font-weight: 950; text-transform: uppercase; }
.gtg-single-product__side-facts strong { font-size: .95rem; }

.gtg-single-product__content-grid { display: grid; grid-template-columns: 1fr; gap: var(--gtg-product-section-gap); }
.gtg-single-product__panel { padding: clamp(1rem, 2.5vw, 1.45rem); }
.gtg-single-product__play-first {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas: 'copy button';
  align-items: center;
  gap: .65rem 1.1rem;
  padding: .65rem .9rem;
  margin: 0;
  background: #fff3cf;
}
.gtg-single-product__play-first-copy { grid-area: copy; display: grid; gap: .16rem; min-width: 0; }
.gtg-single-product__play-first h2 { margin: 0 !important; white-space: nowrap; }
.gtg-single-product__play-first-copy p { max-width: none; margin: 0; }
.gtg-single-product__play-first > .gtg-single-product__checkout { grid-area: button; justify-self: end; align-self: center; min-height: 56px; padding-inline: 1.25rem; white-space: nowrap; }
.gtg-single-product__panel h2,
.gtg-single-product__related h2 { margin: 0 0 .7rem; font-size: clamp(1.45rem, 3vw, 2.2rem); line-height: 1; }
.gtg-single-product__panel p { color: var(--gtg-product-muted); font-weight: 750; line-height: 1.45; }
.gtg-single-product__description > *:last-child { margin-bottom: 0; }

.gtg-single-product__related { padding: clamp(1rem, 2.5vw, 1.45rem); overflow: hidden; }
.gtg-single-product__related-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 1.2rem; }
.gtg-single-product__related-head h2 { margin: 0; }
.gtg-single-product__rail-controls { display: inline-flex; gap: .5rem; }
.gtg-single-product__rail-controls button { min-width: 46px; padding-inline: .75rem; background: var(--gtg-product-yellow); color: var(--gtg-product-ink) !important; }
.gtg-single-product__related-rail {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(210px, 250px);
  gap: .9rem;
  overflow-x: auto;
  overflow-y: hidden;
  padding: .35rem .15rem .75rem;
  scroll-snap-type: x proximity;
  cursor: grab;
  scrollbar-width: thin;
  touch-action: pan-y;
}
.gtg-single-product__related-rail.is-dragging { cursor: grabbing; scroll-snap-type: none; }
.gtg-single-product__related-rail.is-dragging .gtg-single-product__related-card { pointer-events: none; }
.gtg-single-product__related-card {
  display: grid;
  grid-template-rows: 160px minmax(0, 1fr);
  gap: .85rem;
  scroll-snap-align: start;
  padding: .75rem;
  border: 2px solid var(--gtg-product-ink);
  border-radius: 18px;
  background: var(--gtg-product-paper);
  box-shadow: 3px 3px 0 var(--gtg-product-shadow);
  text-decoration: none;
  user-select: none;
  -webkit-user-drag: none;
}
.gtg-single-product__related-card:hover { transform: translateY(-1px); box-shadow: 4px 4px 0 var(--gtg-product-shadow); }
.gtg-single-product__related-image { display: grid; place-items: center; padding: .45rem; border-radius: 14px; background: #fffaf2; }
.gtg-single-product__related-image img { max-width: 100%; max-height: 100%; object-fit: contain; pointer-events: none; -webkit-user-drag: none; }
.gtg-single-product__related-copy { display: block; padding-top: .18rem; }
.gtg-single-product__related-copy strong { display: block; margin: .25rem 0 .55rem; font-size: 1.06rem; font-weight: 950; line-height: 1.12; }
.gtg-single-product__related-price { display: block; color: var(--gtg-product-accent); font-weight: 950; }
.gtg-single-product__related-stock {
  display: inline-flex;
  width: fit-content;
  margin-top: .45rem;
  padding: .22rem .45rem;
  border: 2px solid var(--gtg-product-ink);
  border-radius: 999px;
  box-shadow: 2px 2px 0 var(--gtg-product-shadow);
  font-size: .72rem;
  font-weight: 950;
}
.gtg-single-product__related-stock.is-in { background: #d8efc4; }
.gtg-single-product__related-stock.is-low { background: var(--gtg-product-yellow); }
.gtg-single-product__related-stock.is-out { background: #f1b7a8; }

.gtg-single-product__lightbox {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: grid;
  place-items: center;
  padding: clamp(1rem, 4vw, 2rem);
  background: rgba(37, 32, 29, .78);
}
.gtg-single-product__lightbox[hidden] { display: none; }
.gtg-single-product__lightbox img {
  max-width: min(1100px, 100%);
  max-height: calc(100vh - 4rem);
  object-fit: contain;
  border: 2px solid var(--gtg-product-ink);
  border-radius: 20px;
  background: #fffaf2;
  box-shadow: 6px 6px 0 var(--gtg-product-shadow);
}
.gtg-single-product__lightbox button {
  position: fixed;
  top: 1rem;
  right: 1rem;
  width: 44px;
  height: 44px;
  border: 2px solid var(--gtg-product-ink);
  border-radius: 999px;
  background: var(--gtg-product-yellow);
  box-shadow: 3px 3px 0 var(--gtg-product-shadow);
  color: var(--gtg-product-ink);
  font-size: 1.7rem;
  font-weight: 950;
  line-height: 1;
  cursor: pointer;
}
body.gtg-single-product-lightbox-open { overflow: hidden; }

@media (max-width: 980px) {
  .gtg-single-product__hero,
  .gtg-single-product__stats { grid-template-columns: 1fr; }
  .gtg-single-product__buy-card { position: static; }
  .gtg-single-product__main-image { min-height: 320px; height: auto; }
  .gtg-single-product__score-grid { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
  .gtg-single-product__play-first { grid-template-columns: 1fr auto; }
}

@media (max-width: 560px) {
  .gtg-single-product { width: min(100% - 1.2rem, var(--gtg-shell, 1200px)); }
  .gtg-single-product__cart-actions { grid-template-columns: 82px minmax(0, 1fr); }
  .gtg-single-product__after-add div { grid-template-columns: 1fr; }
  .gtg-single-product__thumb { width: 64px; height: 64px; }
  .gtg-single-product__score-grid { grid-template-columns: 1fr; }
  .gtg-single-product__side-facts { grid-template-rows: none; }
  .gtg-single-product__play-first { grid-template-columns: 1fr; grid-template-areas: 'copy' 'button'; }
  .gtg-single-product__play-first h2 { white-space: normal; }
  .gtg-single-product__play-first > .gtg-single-product__checkout { justify-self: stretch; width: 100%; }
  .gtg-single-product__related-head { align-items: flex-start; flex-direction: column; }
  .gtg-single-product__related-rail { grid-auto-columns: minmax(190px, 78vw); }
}

@media (prefers-reduced-motion: reduce) {
  .gtg-single-product * { transition: none !important; animation: none !important; }
}
