/* KORZH v477 — screenshot hardfix: modal center, shop FPS, prices, FLEX ruler, AMBER, footer */

/* A) EVERY overlay is viewport-centered. Prevent transformed profile ancestors from turning fixed overlays into local/bottom overlays. */
html:root[data-visual-style="2040"][data-theme="hub"] :is(#profileApp,.profile-page,.profile-v80-main,.profile-v156-content,.profile-v80-content,.profile-v80-content-body){
  transform:none!important;
  perspective:none!important;
  filter:none!important;
}
html:root[data-visual-style="2040"][data-theme="hub"] :is(
  .profile-v81-overlay,
  .replay-overlay,
  .kx229-profile-layer,
  .exchange-overlay,
  .k414-shop-confirm-overlay,
  .trade-link-overlay,
  .deposit-mini-overlay,
  .deposit-v106-overlay
){
  position:fixed!important;
  inset:0!important;
  width:100vw!important;
  height:100dvh!important;
  min-height:100dvh!important;
  margin:0!important;
  padding:24px!important;
  box-sizing:border-box!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  place-items:center!important;
  overflow:auto!important;
  z-index:2147483600!important;
  transform:none!important;
}
html:root[data-visual-style="2040"][data-theme="hub"] :is(
  .profile-v81-overlay,
  .replay-overlay,
  .kx229-profile-layer,
  .exchange-overlay,
  .k414-shop-confirm-overlay,
  .trade-link-overlay,
  .deposit-mini-overlay,
  .deposit-v106-overlay
)>:is(section,.profile-v81-replay-modal,.profile-v81-archive-modal,.kx229-card,.exchange-modal,.k414-shop-confirm,.trade-link-modal,.deposit-v106-modal){
  margin:auto!important;
  flex:0 0 auto!important;
  transform:none!important;
}

/* B) Deposit: real v476 wallet composition on both main site and profile, with strict viewport centering. */
html:root[data-visual-style="2040"] #depositPortal .k477-deposit-overlay,
html:root[data-visual-style="2040"] #depositPortal .k476-deposit-overlay{
  position:fixed!important;inset:0!important;width:100vw!important;height:100dvh!important;
  display:flex!important;align-items:center!important;justify-content:center!important;padding:18px!important;
}
html:root[data-visual-style="2040"] #depositPortal .k477-deposit-modal,
html:root[data-visual-style="2040"] #depositPortal .k476-deposit-modal{
  margin:auto!important;align-self:center!important;justify-self:center!important;
}

/* C) Shop scroll performance: remove the expensive per-card blur/filter paint that caused 3 FPS wheel scroll. */
html:root[data-visual-style="2040"][data-theme="hub"] .k414-shop-body{
  contain:layout style!important;
  transform:translateZ(0)!important;
  backface-visibility:hidden!important;
}
html:root[data-visual-style="2040"][data-theme="hub"] .k414-shop-grid{
  contain:layout style!important;
}
html:root[data-visual-style="2040"][data-theme="hub"] .k414-shop-card{
  content-visibility:auto!important;
  contain:layout paint style!important;
  contain-intrinsic-size:265px 230px!important;
  filter:none!important;
  backdrop-filter:none!important;
  -webkit-backdrop-filter:none!important;
  box-shadow:inset 0 1px rgba(255,255,255,.055),0 8px 18px rgba(0,0,0,.20)!important;
  transition:border-color .12s ease,transform .12s ease!important;
}
html:root[data-visual-style="2040"][data-theme="hub"] .k414-shop-card::before{
  display:none!important;content:none!important;filter:none!important;background:none!important;
}
html:root[data-visual-style="2040"][data-theme="hub"] .k414-shop-card .skin-art{
  filter:none!important;
  transform:none!important;
}
html:root[data-visual-style="2040"][data-theme="hub"] .k414-shop-card .skin-glow{
  display:none!important;filter:none!important;opacity:0!important;
}
html:root[data-visual-style="2040"][data-theme="hub"] .k414-shop-card .skin-art img{
  filter:none!important;
  transition:transform .12s ease!important;
  will-change:auto!important;
}
html:root[data-visual-style="2040"][data-theme="hub"] .k414-shop-card:hover{
  transform:translateY(-2px)!important;
  box-shadow:inset 0 1px rgba(255,255,255,.07),0 12px 24px rgba(0,0,0,.25)!important;
}
html:root[data-visual-style="2040"][data-theme="hub"] .k414-shop-card:hover .skin-art img{
  transform:translateY(-1px) scale(1.012)!important;filter:none!important;
}

/* D) AMBER — force same apparent footprint as EDEN. The source canvas is equal, but Amber reads optically smaller. */
html:root[data-visual-style="2040"][data-theme="hub"] .page-cases .case-prism-amber .prism-product-art{
  overflow:visible!important;
}
html:root[data-visual-style="2040"][data-theme="hub"] .page-cases .case-prism-amber .prism-product-art .prism-case-product-image{
  width:106%!important;max-width:106%!important;height:218px!important;max-height:218px!important;
  object-fit:contain!important;object-position:center center!important;
  transform:translateY(-5px) scale(1.30)!important;transform-origin:center center!important;
}
html:root[data-visual-style="2040"][data-theme="hub"] .page-cases .case-prism-amber:hover .prism-product-art .prism-case-product-image{
  transform:translateY(-7px) scale(1.32)!important;
}

/* E) HARD price capsule rebuild — one exact size/style everywhere, with larger OSCAR/CHICK PICK numerals. */
html:root[data-visual-style="2040"][data-theme="hub"] .page-cases :is(
  .case-price-premium,
  .case-price-tag.case-price-premium,
  .case-price-tag.case-price-centered,
  .k220-oscar-price,
  .k221-oscar-price,
  .k449-chick-pick-price
){
  box-sizing:border-box!important;
  width:106px!important;min-width:106px!important;max-width:106px!important;
  height:36px!important;min-height:36px!important;max-height:36px!important;
  padding:0 11px!important;margin:9px auto 0!important;
  display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:6px!important;
  border-radius:13px!important;
  border:1px solid color-mix(in srgb,var(--accent,#e4a070) 58%,rgba(255,255,255,.13))!important;
  background:linear-gradient(180deg,rgba(255,248,242,.085),rgba(39,24,19,.34) 48%,rgba(10,8,8,.88))!important;
  box-shadow:inset 0 1px rgba(255,255,255,.13),inset 0 -1px rgba(0,0,0,.44),0 6px 15px rgba(0,0,0,.20),0 0 14px color-mix(in srgb,var(--accent,#e4a070) 12%,transparent)!important;
  backdrop-filter:none!important;-webkit-backdrop-filter:none!important;
  white-space:nowrap!important;overflow:hidden!important;transform:none!important;
  font-size:13.5px!important;font-weight:850!important;line-height:1!important;color:#fffaf6!important;
}
html:root[data-visual-style="2040"][data-theme="hub"] .page-cases :is(
  .case-price-premium,
  .case-price-tag.case-price-premium,
  .k220-oscar-price,
  .k221-oscar-price,
  .k449-chick-pick-price
) :is(.case-price-value,.korzh-money,.korzh-money-number){
  display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:6px!important;
  margin:0!important;padding:0!important;line-height:1!important;
  font-size:13.5px!important;font-weight:850!important;letter-spacing:.01em!important;color:#fffaf6!important;
}
html:root[data-visual-style="2040"][data-theme="hub"] .page-cases :is(.k221-oscar-price,.k449-chick-pick-price) :is(.case-price-value,.korzh-money,.korzh-money-number){
  font-size:14px!important;font-weight:900!important;
}
html:root[data-visual-style="2040"][data-theme="hub"] .page-cases :is(
  .case-price-premium,
  .case-price-tag,
  .k220-oscar-price,
  .k221-oscar-price,
  .k449-chick-pick-price
) :is(.korzh-currency-icon,.korzh-currency-logo){
  width:15px!important;height:15px!important;min-width:15px!important;min-height:15px!important;max-width:15px!important;max-height:15px!important;
}

/* F) FLEX ruler — same bullet + separator line as every neighbouring collection. */
html:root[data-visual-style="2040"][data-theme="hub"] .page-cases .hub-showcase-flex .collection-heading{
  display:flex!important;align-items:center!important;gap:13px!important;width:100%!important;min-height:30px!important;
  overflow:visible!important;
}
html:root[data-visual-style="2040"][data-theme="hub"] .page-cases .hub-showcase-flex .collection-heading::before{
  content:""!important;display:block!important;flex:0 0 7px!important;width:7px!important;height:7px!important;
  border-radius:50%!important;background:#fff8f0!important;box-shadow:0 0 11px rgba(255,247,238,.55)!important;
}
html:root[data-visual-style="2040"][data-theme="hub"] .page-cases .hub-showcase-flex .collection-heading::after{
  content:""!important;display:block!important;flex:1 1 auto!important;width:auto!important;height:1px!important;min-width:40px!important;
  background:linear-gradient(90deg,rgba(255,247,238,.23),rgba(231,199,172,.075) 38%,transparent 86%)!important;
}

/* G) Footer/legal area is text on the page background — never a separate plate. */
html:root[data-visual-style="2040"][data-theme="hub"] .korzh-footer,
html:root[data-visual-style="2040"][data-theme="hub"] .profile-page .korzh-footer{
  background:transparent!important;background-image:none!important;
  border:0!important;border-radius:0!important;box-shadow:none!important;
  backdrop-filter:none!important;-webkit-backdrop-filter:none!important;
}
html:root[data-visual-style="2040"][data-theme="hub"] .korzh-footer::before,
html:root[data-visual-style="2040"][data-theme="hub"] .profile-page .korzh-footer::before{
  display:none!important;content:none!important;background:none!important;
}

/* H) Keep modal/backdrop open-state smooth without expensive full-screen live blur. */
html:root[data-visual-style="2040"][data-theme="hub"] :is(.profile-v81-overlay,.k414-shop-confirm-overlay,.kx229-profile-layer,.deposit-mini-overlay){
  backdrop-filter:none!important;-webkit-backdrop-filter:none!important;
  background:rgba(7,4,4,.84)!important;
}
