/* CP318 · red-primary accents. Color only: no geometry or Hero selectors. */
body.pg-visual-system {
  --accent-primary: #ff163c;
  --accent-primary-hover: #e61034;
  --accent-primary-glow: rgba(255, 22, 60, 0.38);
  --pg-fx-primary: #ff163c;
  --pg-fx-primary-hover: #e61034;
  --pg-fx-primary-glow: rgba(255, 22, 60, 0.38);
  --pg-fx-secondary: #109CFF;
}

/* Main actions across both locales. Homepage Hero descendants are deliberately excluded. */
body.pg-visual-system:not(.pg-page-home) .page :is(a.cta, button.cta, .btn-primary, .pg-home-calc-cta, .pgd-btn-red, .pgm-primary, .pg-home-quote, .pg-quote-add, .pg-filter-open, .pg-photo-fallback, .pg-catalogue-card-quote, .guide-cta-link, .pg-bf-primary, .pg-quote-submit),
body.pg-visual-system.pg-page-home .page :is(a.cta, button.cta, .btn-primary, .pg-home-calc-cta, .pgd-btn-red, .pgm-primary, .pg-home-quote, .pg-quote-add, .pg-filter-open, .pg-photo-fallback, .pg-catalogue-card-quote, .guide-cta-link, .pg-bf-primary, .pg-quote-submit):not(.pgd-hero *):not(.pgm-copy *) {
  border-color: #ff163c !important;
  background-color: #ff163c !important;
  background-image: none !important;
  color: #FFFFFF !important;
  box-shadow: 0 8px 22px rgba(255, 22, 60, 0.24) !important;
}

/* Outrank the established subpage CTA token rules without touching component geometry. */
html body.pg-visual-system:not(.pg-page-home) .page.subpage-shell main#main :is(a.cta, button.cta, .btn-primary, .pg-home-calc-cta, .pg-quote-add, .pg-filter-open, .pg-photo-fallback, .pg-catalogue-card-quote, .guide-cta-link, .pg-bf-primary, .pg-quote-submit) {
  border-color: #ff163c !important;
  background-color: #ff163c !important;
  background-image: none !important;
  color: #FFFFFF !important;
  box-shadow: 0 8px 22px rgba(255, 22, 60, 0.24) !important;
}
html body.pg-page-quote.pg-visual-system :is(a.cta, button.cta, .btn-primary, .pg-quote-submit) {
  border-color: #ff163c !important;
  background-color: #ff163c !important;
  background-image: none !important;
  color: #FFFFFF !important;
  box-shadow: 0 8px 22px rgba(255, 22, 60, 0.24) !important;
}

body.pg-visual-system:not(.pg-page-home) .page :is(a.cta, button.cta, .btn-primary, .pg-home-calc-cta, .pgd-btn-red, .pgm-primary, .pg-home-quote, .pg-quote-add, .pg-filter-open, .pg-photo-fallback, .pg-catalogue-card-quote, .guide-cta-link, .pg-bf-primary, .pg-quote-submit):hover,
body.pg-visual-system.pg-page-home .page :is(a.cta, button.cta, .btn-primary, .pg-home-calc-cta, .pgd-btn-red, .pgm-primary, .pg-home-quote, .pg-quote-add, .pg-filter-open, .pg-photo-fallback, .pg-catalogue-card-quote, .guide-cta-link, .pg-bf-primary, .pg-quote-submit):not(.pgd-hero *):not(.pgm-copy *):hover {
  border-color: #e61034 !important;
  background-color: #e61034 !important;
  background-image: none !important;
  box-shadow: 0 10px 26px rgba(230, 16, 52, 0.38) !important;
}
html body.pg-visual-system:not(.pg-page-home) .page.subpage-shell main#main :is(a.cta, button.cta, .btn-primary, .pg-home-calc-cta, .pg-quote-add, .pg-filter-open, .pg-photo-fallback, .pg-catalogue-card-quote, .guide-cta-link, .pg-bf-primary, .pg-quote-submit):hover,
html body.pg-page-quote.pg-visual-system :is(a.cta, button.cta, .btn-primary, .pg-quote-submit):hover {
  border-color: #e61034 !important;
  background-color: #e61034 !important;
  background-image: none !important;
  box-shadow: 0 10px 26px rgba(230, 16, 52, 0.38) !important;
}

/* Shared quote CTA, header, drawer and mobile action bar are outside the locked Hero. */
body.pg-visual-system :is(.pg-site-header, .mobile-drawer, .pg-quote-cart-bar, .pg-sticky-actions) :is(.btn-primary, .cta) {
  border-color: #ff163c !important;
  background: #ff163c !important;
  color: #FFFFFF !important;
  box-shadow: 0 8px 22px rgba(255, 22, 60, 0.24) !important;
}
body.pg-visual-system :is(.pg-site-header, .mobile-drawer, .pg-quote-cart-bar, .pg-sticky-actions) :is(.btn-primary, .cta):hover {
  border-color: #e61034 !important;
  background: #e61034 !important;
  box-shadow: 0 10px 26px rgba(230, 16, 52, 0.38) !important;
}

/* Active finder filters and quote-list count become the primary red signal. */
body.pg-visual-system .page :is(.brand-pill.active, .brand-pill[aria-pressed="true"], .pg-industry-filter-pill.active, .pg-industry-filter-pill[aria-pressed="true"], .pg-filter-pill.active, .pg-filter-pill[aria-pressed="true"]) {
  border-color: #ff163c !important;
  background-color: rgba(255, 22, 60, 0.16) !important;
  color: #F3F6F8 !important;
}
body.pg-visual-system .pg-quote-cart-summary strong { color: #ff163c !important; }
body.pg-visual-system .pg-footer-global-dot { background-color: #ff163c !important; }

/* Scroll progress, B2B process numbers and non-Hero image hotspots. */
body.pg-visual-system .pg-reading-progress > span {
  background: linear-gradient(90deg, #e61034, #ff163c 72%, #109CFF) !important;
  box-shadow: 0 0 10px rgba(255, 22, 60, 0.38) !important;
}
body.pg-visual-system .pg-bf-step-number,
body.pg-visual-system .pg-partner-step-number,
body.pg-visual-system .pg-guide-step-number,
body.pg-visual-system .pg-process-step-number,
body.pg-visual-system .pg-b2b-step-number {
  border-color: rgba(255, 22, 60, 0.56) !important;
  background: rgba(255, 22, 60, 0.14) !important;
  color: #ff163c !important;
}
body.pg-visual-system :is(.pg-product-hotspot, .pg-stage-hotspot, .pg-image-hotspot) {
  border-color: #ff163c !important;
  background: rgba(255, 22, 60, 0.92) !important;
  box-shadow: 0 0 0 4px rgba(255, 22, 60, 0.18), 0 0 18px rgba(255, 22, 60, 0.38) !important;
}
body.pg-visual-system :is(.pg-card, .card, .model-card, .sector-card, .pos-finder-card, .sector-pill-card, .pg-bento-card, .pg-stress-card, .pg-catalogue-card, .pg-model-accessory-card, .pg-industry-card):not(.pgd-hero *):not(.pgm-copy *):hover {
  border-color: rgba(255, 22, 60, 0.88) !important;
  box-shadow: 0 12px 28px -8px rgba(255, 22, 60, 0.2), inset 0 1px 0 rgba(255, 22, 60, 0.16) !important;
}

/* Red-led energy layers use blue only for restrained contrast. */
body.pg-visual-system .pg-fx-electric-backdrop::before {
  background:
    radial-gradient(ellipse at 18% 42%, rgba(255, 22, 60, 0.19), transparent 38%),
    radial-gradient(ellipse at 82% 70%, rgba(16, 156, 255, 0.065), transparent 34%) !important;
}
body.pg-visual-system .pg-fx-electric-backdrop::after {
  background:
    radial-gradient(ellipse at 50% 92%, rgba(255, 22, 60, 0.12), transparent 45%),
    radial-gradient(ellipse at 16% 28%, rgba(16, 156, 255, 0.05), transparent 35%) !important;
}
body.pg-visual-system .pg-fx-footer-stage::after {
  background: linear-gradient(90deg, transparent, #ff163c 36%, #e61034 50%, #ff163c 64%, transparent) !important;
  box-shadow: 0 0 12px rgba(255, 22, 60, 0.38);
}
body.pg-visual-system .pg-fx-product-stage::before {
  background:
    radial-gradient(ellipse at 72% 62%, rgba(255, 22, 60, 0.17), transparent 43%),
    radial-gradient(ellipse at 25% 64%, rgba(16, 156, 255, 0.075), transparent 38%),
    linear-gradient(180deg, rgba(2, 8, 17, 0.1), transparent 35%, rgba(2, 8, 17, 0.07)) !important;
}
/* The product template intentionally clears picture backgrounds; restore only verified stage wrappers. */
html body.pg-visual-system .page.subpage-shell .product-page[data-pg-product-id] .product-layout > picture.product-image-wrap.pg-fx-product-stage {
  background-color: #020811 !important;
  background-image:
    radial-gradient(ellipse at 72% 62%, rgba(255, 22, 60, 0.17), transparent 43%),
    radial-gradient(ellipse at 25% 64%, rgba(16, 156, 255, 0.075), transparent 38%),
    radial-gradient(rgba(16, 156, 255, 0.12) 0.7px, transparent 0.8px),
    none !important;
  background-size: auto, auto, 16px 16px, cover !important;
  background-position: center, center, center, center !important;
  background-repeat: no-repeat, no-repeat, repeat, no-repeat !important;
}
body.pg-visual-system .pg-fx-product-stage::after {
  background: linear-gradient(180deg, transparent, rgba(255, 22, 60, 0.14), rgba(220, 38, 38, 0.22), transparent) !important;
}
body.pg-visual-system .pg-fx-category-card::after {
  background: linear-gradient(90deg, transparent, rgba(255, 22, 60, 0.13), rgba(16, 156, 255, 0.045), transparent) !important;
}
body.pg-visual-system .pg-fx-category-card:hover {
  border-color: #ff163c !important;
  box-shadow: 0 12px 28px -8px rgba(255, 22, 60, 0.24) !important;
}
/* Keep category SVGs at icon scale; legacy desktop image rules also match these <img> tags. */
body.pg-visual-system.pg-page-home .page.home-shell .pgd-products#products .pgd-category-icon > img[src*="/assets/library/icons/category-"] {
  width: 24px !important;
  min-width: 24px !important;
  max-width: 24px !important;
  height: 24px !important;
  min-height: 24px !important;
  max-height: 24px !important;
  flex: 0 0 24px !important;
  object-fit: contain !important;
}
body.pg-visual-system .pg-home-compare-card--protected { border-left-color: #ff163c !important; }
body.pg-visual-system .pg-home-compare-card--protected .pg-home-compare-icon { color: #ff163c !important; }
body.pg-visual-system .pg-fx-cta-pulse::after {
  border-color: rgba(255, 22, 60, 0.55) !important;
}
body.pg-visual-system .pg-fx-ripple-wave { background: rgba(255, 22, 60, 0.42) !important; }
body.pg-visual-system :is(.cat-card, .sector-pill-card, .pg-stress-card, .pg-bento-card):hover .pg-fx-icon-box { filter: drop-shadow(0 0 7px rgba(255, 22, 60, 0.38)); }
body.pg-visual-system :is(.cat-card, .sector-pill-card, .pg-stress-card, .pg-bento-card):hover .pg-fx-icon-box img { filter: drop-shadow(0 0 5px rgba(255, 22, 60, 0.38)); }

/* Adaptive ambient themes remain dark, with a red-led glow and blue as a secondary accent. */
html[data-time-theme="day"] { --ambient-glow: rgba(255, 22, 60, 0.15); --secondary-glow: rgba(16, 156, 255, 0.06); --pg-fx-ambient: var(--ambient-glow); --pg-fx-warm: var(--secondary-glow); }
html[data-time-theme="sunset"] { --ambient-glow: rgba(255, 22, 60, 0.17); --secondary-glow: rgba(16, 156, 255, 0.07); --pg-fx-ambient: var(--ambient-glow); --pg-fx-warm: var(--secondary-glow); }
html[data-time-theme="night"] { --ambient-glow: rgba(255, 22, 60, 0.095); --secondary-glow: rgba(16, 156, 255, 0.045); --pg-fx-ambient: var(--ambient-glow); --pg-fx-warm: var(--secondary-glow); }

@media (prefers-reduced-motion: reduce) {
  body.pg-visual-system .pg-fx-electric-backdrop,
  body.pg-visual-system .pg-fx-electric-backdrop::after,
  body.pg-visual-system .pg-fx-footer-stage::after,
  body.pg-visual-system .pg-fx-product-stage img,
  body.pg-visual-system .pg-fx-cta-pulse::after { animation: none !important; transition: none !important; }
}

