/* Puzzlownia - bezpieczny etap wyboru obrazu przed Start. */
body.pz-game-page.pz-image-choice-enabled .pz-retro-setting-tile--theme{display:none!important;}
body.pz-game-page.pz-image-choice-active .pz-retro-hit--options,
body.pz-game-page.pz-image-choice-active .pz-retro-hit--bottom-options{pointer-events:none!important;opacity:.22!important;}
body.pz-game-page.pz-image-choice-active .pz-retro-panel--bottom .pz-retro-slot--bottom1,
body.pz-game-page.pz-image-choice-active .pz-retro-panel--bottom .pz-retro-slot--bottom2,
body.pz-game-page.pz-image-choice-active .pz-retro-panel--bottom .pz-retro-slot--bottom3,
body.pz-game-page.pz-image-choice-active .pz-retro-panel--bottom .pz-retro-slot--readmore{pointer-events:none!important;filter:saturate(.45) brightness(.9)!important;}
body.pz-game-page.pz-image-choice-active .pz-retro-panel--bottom .pz-retro-slot--bottom1 .pz-retro-button,
body.pz-game-page.pz-image-choice-active .pz-retro-panel--bottom .pz-retro-slot--bottom2 .pz-retro-button,
body.pz-game-page.pz-image-choice-active .pz-retro-panel--bottom .pz-retro-slot--bottom3 .pz-retro-button,
body.pz-game-page.pz-image-choice-active .pz-retro-panel--bottom .pz-retro-slot--readmore .pz-retro-button{color:transparent!important;text-shadow:none!important;}
body.pz-game-page.pz-image-choice-active .pz-retro-hit--sound{pointer-events:none!important;opacity:.22!important;}
body.pz-game-page.pz-image-choice-active .pz-retro-caption--sound,
body.pz-game-page.pz-image-choice-active .pz-retro-caption--options{visibility:hidden!important;}
body.pz-game-page.pz-image-choice-active .pz-game-bottom-actions{display:none!important;}
body.pz-game-page.pz-image-choice-active .pz-retro-hint-ready{animation:none!important;box-shadow:none!important;}

.pz-image-choice-overlay{
  position:absolute!important;inset:0!important;z-index:13050!important;
  isolation:isolate!important;pointer-events:auto!important;
  display:block!important;background:rgba(247,243,235,.94)!important;
  backdrop-filter:none!important;-webkit-backdrop-filter:none!important;
  overflow:hidden!important;
}

html[data-theme="dark"] .pz-image-choice-overlay{background:rgba(14,17,20,.95)!important;}
body.pz-image-choice-open #stage > :not(.pz-image-choice-overlay){visibility:hidden!important;}
.pz-image-choice-overlay[hidden]{display:none!important;}
.pz-image-choice-card{
  --pz-image-choice-scale:1;
  z-index:1!important;
  position:absolute!important;left:50%!important;top:50%!important;
  transform:translate(-50%,-50%) scale(var(--pz-image-choice-scale))!important;
  transform-origin:center!important;
  width:min(94%,780px)!important;max-height:94%!important;
  box-sizing:border-box!important;padding:clamp(12px,2.2vw,24px)!important;
  border:1px solid rgba(83,61,37,.22)!important;border-radius:22px!important;
  background:rgba(255,250,240,.96)!important;color:#241b12!important;
  box-shadow:0 18px 60px rgba(34,24,14,.24)!important;text-align:center!important;
  font-family:Manrope,Arial,sans-serif!important;
}
html[data-theme="dark"] .pz-image-choice-card{
  background:rgba(35,29,23,.97)!important;color:#f2e8d8!important;border-color:rgba(255,231,196,.16)!important;
  box-shadow:0 18px 60px rgba(0,0,0,.5)!important;
}
.pz-image-choice-card>strong{display:block!important;font-size:clamp(20px,2.6vw,34px)!important;line-height:1.02!important;font-weight:1000!important;letter-spacing:-.03em!important;}
.pz-image-choice-card>p{max-width:680px!important;margin:7px auto 12px!important;font-size:clamp(11px,1.1vw,15px)!important;line-height:1.35!important;}
.pz-image-choice-close{position:absolute!important;right:10px!important;top:8px!important;width:36px!important;height:36px!important;border:0!important;border-radius:50%!important;background:rgba(82,60,35,.09)!important;color:inherit!important;font-size:25px!important;line-height:1!important;cursor:pointer!important;}
.pz-image-choice-close[hidden]{display:none!important;}
.pz-image-choice-grid{display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:clamp(7px,1.2vw,12px)!important;align-items:stretch!important;}
.pz-image-choice-style,.pz-image-choice-custom{font:inherit!important;color:inherit!important;border:1px solid rgba(101,75,44,.2)!important;background:rgba(255,255,255,.58)!important;border-radius:16px!important;box-shadow:0 4px 14px rgba(47,34,20,.07)!important;cursor:pointer!important;transition:transform .12s ease,border-color .12s ease,box-shadow .12s ease!important;}
html[data-theme="dark"] .pz-image-choice-style,html[data-theme="dark"] .pz-image-choice-custom{background:rgba(255,255,255,.055)!important;border-color:rgba(255,229,195,.13)!important;}
.pz-image-choice-style:hover,.pz-image-choice-custom:hover{transform:translateY(-2px)!important;box-shadow:0 8px 20px rgba(47,34,20,.12)!important;}
.pz-image-choice-style.is-selected{border-color:#b8732a!important;box-shadow:0 0 0 2px rgba(184,115,42,.18),0 8px 20px rgba(47,34,20,.1)!important;}
.pz-image-choice-style{padding:9px 8px 8px!important;min-width:0!important;}
.pz-image-choice-style>b{display:block!important;margin-bottom:7px!important;font-size:clamp(11px,1.1vw,15px)!important;line-height:1.05!important;font-weight:1000!important;}
.pz-image-choice-previews{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:4px!important;}
.pz-image-choice-previews img{display:block!important;width:100%!important;aspect-ratio:4/5!important;object-fit:cover!important;border-radius:8px!important;border:1px solid rgba(60,43,28,.12)!important;background:#eee6d7!important;}
.pz-image-choice-style[data-style="humor"] .pz-image-choice-previews img{aspect-ratio:17/20!important;}
.pz-image-choice-custom{grid-column:1/-1!important;min-height:64px!important;padding:8px 16px!important;display:flex!important;align-items:center!important;justify-content:center!important;gap:14px!important;}
.pz-image-choice-custom>img{width:48px!important;height:48px!important;object-fit:contain!important;}
.pz-image-choice-custom>span{text-align:left!important;display:grid!important;gap:2px!important;}
.pz-image-choice-custom b{font-size:clamp(12px,1.15vw,16px)!important;font-weight:1000!important;}
.pz-image-choice-custom small{font-size:clamp(9px,.9vw,12px)!important;opacity:.76!important;}
.pz-image-choice-status{min-height:18px!important;margin-top:7px!important;font-size:11px!important;font-weight:800!important;}
.pz-image-choice-status.is-error{color:#9f3429!important;}
.pz-image-choice-overlay.is-busy .pz-image-choice-grid{opacity:.55!important;pointer-events:none!important;}

body.pz-image-choice-preview-ready #puzzleBox{cursor:pointer!important;}
body.pz-image-choice-preview-ready #puzzleBox::after{pointer-events:none!important;}

@media(max-width:820px) and (orientation:portrait){
  .pz-image-choice-card{width:94%!important;padding:12px 10px!important;border-radius:18px!important;}
  .pz-image-choice-card>strong{font-size:clamp(18px,5vw,24px)!important;}
  .pz-image-choice-card>p{font-size:clamp(10px,2.7vw,12px)!important;margin:5px auto 8px!important;}
  .pz-image-choice-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:6px!important;}
  .pz-image-choice-style{padding:7px 6px 6px!important;border-radius:13px!important;}
  .pz-image-choice-style>b{font-size:clamp(10px,3vw,13px)!important;margin-bottom:5px!important;}
  .pz-image-choice-previews{gap:3px!important;}
  .pz-image-choice-previews img{border-radius:6px!important;}
  .pz-image-choice-custom{min-height:52px!important;padding:6px 10px!important;gap:10px!important;}
  .pz-image-choice-custom>img{width:38px!important;height:38px!important;}
  .pz-image-choice-custom b{font-size:12px!important;}.pz-image-choice-custom small{font-size:9px!important;}
  .pz-image-choice-status{min-height:14px!important;margin-top:4px!important;font-size:9px!important;}
}

/* Ciemny motyw komunikatow i flyoutow przy panelach. */
html[data-theme="dark"] body.pz-game-page .pz-retro-info-popover,
html[data-theme="dark"] body.pz-game-page .pz-retro-instruction-popover,
html[data-theme="dark"] body.pz-game-page .pz-retro-mat-popover{
  background:#1b2025!important;
  color:#f2eadf!important;
  border-color:rgba(255,231,199,.16)!important;
  box-shadow:0 14px 34px rgba(0,0,0,.5)!important;
}
html[data-theme="dark"] body.pz-game-page .pz-retro-info-popover .pz-retro-flyout__head,
html[data-theme="dark"] body.pz-game-page .pz-retro-instruction-popover .pz-retro-flyout__head,
html[data-theme="dark"] body.pz-game-page .pz-retro-mat-popover .pz-retro-flyout__head{
  border-color:rgba(255,255,255,.10)!important;
}
html[data-theme="dark"] body.pz-game-page .pz-retro-info-popover .pz-retro-flyout__head b,
html[data-theme="dark"] body.pz-game-page .pz-retro-info-popover .pz-retro-flyout__body,
html[data-theme="dark"] body.pz-game-page .pz-retro-info-popover .pz-retro-flyout__body b,
html[data-theme="dark"] body.pz-game-page .pz-retro-info-popover .pz-retro-flyout__body p,
html[data-theme="dark"] body.pz-game-page .pz-retro-instruction-popover .pz-retro-flyout__body,
html[data-theme="dark"] body.pz-game-page .pz-retro-mat-popover .pz-retro-flyout__body{
  color:#f2eadf!important;
}
html[data-theme="dark"] body.pz-game-page .pz-retro-info-popover .pz-retro-settings-close,
html[data-theme="dark"] body.pz-game-page .pz-retro-instruction-popover .pz-retro-settings-close,
html[data-theme="dark"] body.pz-game-page .pz-retro-mat-popover .pz-retro-settings-close{
  background:#272d33!important;
  color:#f2eadf!important;
  border-color:rgba(255,255,255,.13)!important;
}


/* IMAGE CHOICE - MOBILE CONSISTENCY
   W przygotowaniu na telefonie pokazujemy dokładnie ten sam uproszczony
   panel co na desktopie. Dolne przyciski zostają fizycznie na swoim miejscu,
   ale bez napisów i bez działania. Bardzo wysoka specyficzność jest celowa:
   mobile-panels-v10 ma własne !important dla kolorów tekstu. */
@media (max-width:820px) and (orientation:portrait){
  body.pz-game-page.pz-classic-layout-v2.pz-retro-ui-v1.pz-retro-ui-v2.pz-retro-ui-v3.pz-retro-ui-v4.pz-retro-ui-v5.pz-retro-ui-v6.pz-image-choice-active
  .pz-retro-panel--bottom :is(.pz-retro-slot--bottom1,.pz-retro-slot--bottom2,.pz-retro-slot--bottom3,.pz-retro-slot--readmore) .pz-retro-button,
  body.pz-game-page.pz-classic-layout-v2.pz-retro-ui-v1.pz-retro-ui-v2.pz-retro-ui-v3.pz-retro-ui-v4.pz-retro-ui-v5.pz-retro-ui-v6.pz-image-choice-active
  .pz-retro-panel--bottom .pz-retro-slot--readmore .pz-retro-button--readmore{
    color:transparent!important;
    text-shadow:none!important;
    font-size:0!important;
    line-height:0!important;
  }
  body.pz-game-page.pz-classic-layout-v2.pz-retro-ui-v1.pz-retro-ui-v2.pz-retro-ui-v3.pz-retro-ui-v4.pz-retro-ui-v5.pz-retro-ui-v6.pz-image-choice-active
  .pz-retro-panel--bottom :is(.pz-retro-slot--bottom1,.pz-retro-slot--bottom2,.pz-retro-slot--bottom3,.pz-retro-slot--readmore){
    pointer-events:none!important;
  }
}

/* 20260929 - ostrzeżenie przed opuszczeniem prywatnych zdjęć */
.pz-image-choice-custom-warning{margin:8px 0 10px!important;padding:9px 11px!important;border:1px solid #e6b06f!important;border-radius:11px!important;background:#fff6e9!important;color:#6e481e!important;font-size:10px!important;line-height:1.45!important;font-weight:800!important}
.pz-image-choice-confirm[hidden],.pz-image-choice-custom-warning[hidden]{display:none!important}
.pz-image-choice-confirm{position:absolute!important;inset:50% auto auto 50%!important;z-index:5!important;transform:translate(-50%,-50%)!important;width:min(430px,88%)!important;padding:16px!important;border:1px solid #ded6c8!important;border-radius:16px!important;background:#fffdf9!important;box-shadow:0 18px 60px rgba(0,0,0,.28)!important;color:#201b16!important;text-align:left!important}
.pz-image-choice-confirm>strong{display:block!important;font-size:18px!important;margin-bottom:6px!important}.pz-image-choice-confirm>p{margin:0 0 12px!important;font-size:11px!important;line-height:1.5!important;color:#655d54!important}.pz-image-choice-confirm>div{display:grid!important;grid-template-columns:1fr 1fr!important;gap:8px!important}.pz-image-choice-confirm button{min-height:40px!important;border:1px solid #d8d0c5!important;border-radius:10px!important;background:#f7f4ef!important;color:#2a241e!important;font-weight:900!important;font-size:10px!important;cursor:pointer!important}.pz-image-choice-confirm button[data-choice-confirm]{border-color:#ff8d50!important;background:#ff5a00!important;color:#fff!important}
html[data-theme="dark"] .pz-image-choice-custom-warning{border-color:#765739!important;background:#2a2118!important;color:#f1d4ae!important}
html[data-theme="dark"] .pz-image-choice-confirm{border-color:#414951!important;background:#181d22!important;color:#f2f4f6!important}html[data-theme="dark"] .pz-image-choice-confirm>p{color:#aab3bd!important}html[data-theme="dark"] .pz-image-choice-confirm button{border-color:#3b434b!important;background:#242a30!important;color:#f4f6f8!important}
@media(max-width:820px) and (orientation:portrait){.pz-image-choice-custom-warning{font-size:9px!important;margin:5px 0 7px!important;padding:7px 8px!important}.pz-image-choice-confirm{width:min(360px,92%)!important;padding:12px!important}.pz-image-choice-confirm>strong{font-size:15px!important}.pz-image-choice-confirm>p{font-size:9px!important}.pz-image-choice-confirm>div{grid-template-columns:1fr!important}}
