/* Product detail layout, shared by the light and dark themes.
 * Load after all colour and typography styles. Values are local to the hero. */
:root[data-theme] .fighter-premium-site .fighter-product-hero {
  --fp-bg: #0e1014;
  --fp-surface: #191c22;
  --fp-gallery: #202630;
  --fp-border: #353a44;
  --fp-accent: #ed1c2b;
  --fp-ink: #ff9aa5;
  --fp-text: #f5f3ef;
  --fp-muted: #b8bec8;
  --fp-id-bg: #322026;
  --fp-id-border: #62313d;
  --fp-spec: #20242c;
  --fp-doc-mark: #808b9b;
  --fp-shadow: rgb(0 0 0 / 45%);
  --fp-gallery-light: #333944;
  --fp-gallery-glow: rgb(67 74 87 / 50%);
  --fp-gallery-start: #302027;
  --fp-gallery-end: #151a22;
  --fp-image-shadow: rgb(0 0 0 / 50%);
  --fp-emblem-opacity: 0.1035;
}

:root[data-theme="light"] .fighter-premium-site .fighter-product-hero {
  --fp-bg: #f0f1f3;
  --fp-surface: #fff;
  --fp-gallery: #eceef0;
  --fp-border: #dcdfe3;
  --fp-accent: #b71f31;
  --fp-ink: #a51c2c;
  --fp-text: #191b1f;
  --fp-muted: #58616b;
  --fp-id-bg: #f9eaed;
  --fp-id-border: #ead0d5;
  --fp-spec: #f7f8f9;
  --fp-doc-mark: #c4c9cf;
  --fp-shadow: rgb(25 27 31 / 28%);
  --fp-gallery-light: #fff;
  --fp-gallery-glow: rgb(255 255 255 / 48%);
  --fp-gallery-start: #f2e4e6;
  --fp-gallery-end: #e3e6e9;
  --fp-image-shadow: rgb(37 30 33 / 25%);
  --fp-emblem-opacity: 0.16;
}

:root[data-theme] .fighter-premium-site .fighter-product-hero {
  padding: clamp(0.75rem, 2vw, 2rem) var(--fighter-pad) clamp(2rem, 4vw, 4rem) !important;
  background: var(--fp-bg);
  border-bottom: 1px solid var(--fp-border);
}

:root[data-theme] .fighter-premium-site .fighter-product-back {
  width: min(100%, 1320px);
  margin: 0 auto 0.75rem !important;
}

:root[data-theme] .fighter-premium-site .fighter-product-back__link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 44px;
  padding: 0.5rem 0.875rem;
  border: 1px solid var(--fp-border);
  background: var(--fp-surface);
  color: var(--fp-text);
  font-size: 0.875rem;
  font-weight: 700;
  text-decoration: none;
}

:root[data-theme] .fighter-premium-site .fighter-product-back__link .fighter-vector-arrow {
  margin-left: 0;
}

:root[data-theme] .fighter-premium-site .fighter-product-back__link:hover,
:root[data-theme] .fighter-premium-site .fighter-product-back__link:focus-visible {
  border-color: var(--fp-ink);
  color: var(--fp-ink);
}

:root[data-theme] .fighter-premium-site .fighter-product-back__link:focus-visible {
  outline: 2px solid var(--fp-ink);
  outline-offset: 2px;
}

:root[data-theme] .fighter-premium-site .fighter-product-hero > .wp-block-columns {
  width: min(100%, 1320px);
  gap: 0 !important;
  align-items: stretch !important;
  border: 1px solid var(--fp-border);
  background: var(--fp-surface);
  box-shadow: 0 18px 50px -30px var(--fp-shadow);
}

:root[data-theme] .fighter-premium-site .fighter-product-hero > .wp-block-columns > .wp-block-column {
  min-width: 0;
  align-self: stretch !important;
}

:root[data-theme] .fighter-premium-site .fighter-product-hero > .wp-block-columns > .wp-block-column:first-child {
  display: flex;
  flex-basis: 46%;
  background: var(--fp-gallery);
  border-right: 1px solid var(--fp-border);
}

:root[data-theme] .fighter-premium-site .fighter-product-hero > .wp-block-columns > .wp-block-column:last-child {
  flex-basis: 54%;
  padding: clamp(1.5rem, 3vw, 3rem) !important;
  border-top: 4px solid var(--fp-accent);
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-label {
  margin: 0 0 1.1rem !important;
  padding: 0 !important;
  color: var(--fp-ink) !important;
  font-size: 0.65rem;
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-label a {
  color: inherit;
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .wp-block-post-title {
  color: var(--fp-text);
  max-width: 22ch;
  margin: 0 !important;
  padding: 0 !important;
  font-size: clamp(1.55rem, 2.3vw, 2.5rem) !important;
  line-height: 1.18 !important;
  letter-spacing: -0.045em !important;
  overflow-wrap: anywhere;
  text-wrap: balance;
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .wp-block-post-excerpt {
  margin: 1rem 0 1.65rem !important;
  color: var(--fp-muted);
  font-size: 0.95rem;
  line-height: 1.65;
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-identifier {
  /* Keep the label above codes so long SKU lists cannot collapse it. */
  grid-template-columns: minmax(0, 1fr);
  gap: 0.55rem;
  margin: 0 !important;
  padding: 1.1rem 1.2rem;
  background: var(--fp-id-bg);
  border: 1px solid var(--fp-id-border);
  border-left: 3px solid var(--fp-accent);
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-identifier strong {
  min-width: 0;
  max-width: 100%;
  color: var(--fp-ink);
  font-size: 1.35rem;
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-specs {
  gap: 0;
  margin: 0 !important;
  background: var(--fp-spec);
  border: 1px solid var(--fp-border);
  border-top: 0;
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-spec {
  min-width: 0;
  padding: 1.1rem 1.2rem;
  background: var(--fp-spec);
  border-color: var(--fp-border);
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-spec span,
:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-identifier span {
  color: var(--fp-muted);
  font-size: 0.6rem;
  letter-spacing: 0.07em;
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-spec strong {
  color: var(--fp-text);
  font-size: 0.92rem;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-spec--document {
  background: var(--fp-surface);
  border-bottom: 0;
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-spec--document::after {
  top: 1.25rem;
  right: 1.2rem;
  color: var(--fp-doc-mark);
  font-size: 1rem;
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .wp-block-buttons {
  margin: 1.5rem 0 0 !important;
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .wp-block-button,
:root[data-theme] .fighter-premium-site .fighter-product-hero .wp-block-button__link {
  width: 100%;
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .wp-block-button__link {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.15rem 1.3rem;
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-gallery {
  display: flex;
  flex-direction: column;
  max-width: none;
  --fighter-gallery-image-gap: clamp(3rem, 7vw, 6rem);
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-gallery__stage {
  flex: 1;
  min-height: 530px;
  aspect-ratio: auto;
  border: 0;
  background:
    radial-gradient(ellipse at 50% 42%, var(--fp-gallery-light) 0%, var(--fp-gallery-glow) 35%, transparent 70%),
    linear-gradient(145deg, var(--fp-gallery-start), var(--fp-gallery) 50%, var(--fp-gallery-end));
}

/* The same softened red crest used in the consultation panel.
   Contain centres the unwarped artwork behind every gallery slide. */
:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-gallery__stage::before {
  content: "";
  position: absolute;
  inset: 2%;
  width: auto;
  height: auto;
  z-index: 0;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  background: linear-gradient(150deg, #ed1c2b 10%, #b30d25 80%);
  -webkit-mask: url("../images/fighter-product-emblem.svg") center / contain no-repeat;
  mask: url("../images/fighter-product-emblem.svg") center / contain no-repeat;
  mask-mode: alpha;
  opacity: var(--fp-emblem-opacity);
  filter: none;
  transform: none;
  pointer-events: none;
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-gallery__stage::after {
  content: none;
  display: none;
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-gallery__image {
  filter: drop-shadow(0 24px 18px var(--fp-image-shadow));
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-gallery__thumbs {
  margin: 0;
  padding: 1rem;
  background: var(--fp-gallery);
}

@media (max-width: 781px) {
  :root[data-theme] .fighter-premium-site .fighter-product-hero {
    padding: 1rem var(--fighter-pad) 2rem !important;
  }
  :root[data-theme] .fighter-premium-site .fighter-product-hero > .wp-block-columns > .wp-block-column:first-child {
    border-right: 0;
    border-bottom: 1px solid var(--fp-border);
  }
  :root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-gallery__stage {
    min-height: 0;
    flex: auto;
    aspect-ratio: 1 / 1;
  }
  :root[data-theme] .fighter-premium-site .fighter-product-hero > .wp-block-columns > .wp-block-column:last-child {
    padding: 1.5rem 1.2rem !important;
  }
}

@media (max-width: 420px) {
  :root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-specs {
    grid-template-columns: 1fr;
  }
  :root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-spec {
    border-right: 0;
  }
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-spec--document a {
  color: var(--fp-ink);
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-spec--document a:hover {
  color: var(--fp-text);
}

:root[data-theme] .fighter-premium-site .fighter-product-hero .fighter-product-gallery--empty {
  min-height: 100%;
  background: var(--fp-gallery);
  border: 0;
}
