/* ===== v19 — slimmer Smoczek, 3 heroes, tutorial, playroom grid, levels ===== */
.pet-lid--l { left: 23%; top: 25.6%; width: 11.3%; height: 14.7%; }
.pet-lid--r { left: 46.6%; top: 26.7%; width: 14.3%; height: 16%; }

/* —— Pokój zabaw: all 13 games on one board, never scrolls —— */
.pr-menu19 { overflow: hidden !important; }
.pr-menu19 .pr-stage { min-height: 0; }
.pg19-menu {
  flex: 1 1 auto; min-height: 0; width: 100%;
  display: grid; grid-template-columns: clamp(110px, 17vw, 200px) minmax(0, 1fr); gap: .5rem;
  align-items: stretch;
}
.pg19-host { min-height: 0; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: .55rem; padding-bottom: .2rem; }
.pg19-bubble { max-width: 100%; font-size: clamp(.78rem, 1.8vh, 1rem); padding: .35rem .55rem .42rem; }
.pg19-pet { min-height: 0; display: flex; justify-content: center; }
body.world-zamek .pg19-pet .playroom-pet { height: min(34vh, 190px); }
.pg19-board { min-height: 0; display: flex; flex-direction: column; gap: .35rem; }
.pg19-legend { display: flex; flex-wrap: wrap; justify-content: center; gap: .25rem .45rem; flex: 0 0 auto; }
.pg19-leg {
  display: inline-flex; align-items: center; gap: .3rem;
  font-size: clamp(.66rem, 1.6vh, .86rem); font-weight: 800; color: #4A1F5C;
  background: rgba(255, 251, 240, .9); border: 1.5px solid #D8B25A; border-radius: 999px; padding: .08rem .5rem .1rem .14rem;
  box-shadow: 0 2px 0 rgba(110, 74, 22, .35);
}
.pg19-leg i, .pg19-chip {
  font-style: normal; display: inline-grid; place-items: center;
  min-width: 1.45em; height: 1.45em; padding: 0 .2em; border-radius: 999px;
  font-weight: 800; line-height: 1; color: #fff; text-shadow: 0 1px 0 rgba(40, 10, 50, .4);
  box-shadow: inset 0 0 0 1.5px rgba(255, 240, 190, .85), 0 1px 0 rgba(40, 10, 50, .35);
}
.pg19-leg--add i, .pg19--add .pg19-chip { background: linear-gradient(180deg, #59A9E0, #2F6FA8); }
.pg19-leg--mul i, .pg19--mul .pg19-chip { background: linear-gradient(180deg, #F07C93, #B63E5C); }
.pg19-leg--div i, .pg19--div .pg19-chip { background: linear-gradient(180deg, #F2B544, #B3761C); }
.pg19-leg--eq i, .pg19--eq .pg19-chip { background: linear-gradient(180deg, #A783D8, #6B45A3); }
.pg19-grid {
  flex: 1 1 auto; min-height: 0;
  display: grid; gap: clamp(.45rem, 1.6vh, .9rem) clamp(.35rem, 1vw, .7rem);
  grid-template-columns: repeat(7, minmax(0, 1fr)); grid-template-rows: repeat(2, minmax(0, 1fr));
  padding: .5rem .1rem .45rem;
}
body.world-zamek .pg19-grid .hub-btn.cplq.pg19 {
  max-width: none; width: 100%; height: 100%; min-height: 0; min-width: 0;
  padding: .55rem .25rem .35rem; gap: .2rem; justify-content: flex-end;
  border-radius: 50% 50% 14px 14px / 30px 30px 14px 14px;
  animation: pg19In .42s cubic-bezier(.3, 1.5, .5, 1) calc(var(--ci, 0) * .03s) both;
}
body.world-zamek .pg19-grid .hub-btn.cplq.pg19::before { border-radius: 50% 50% 11px 11px / 27px 27px 11px 11px; }
body.world-zamek .cplq--lilac { --pa: #FCF7FF; --pb: #E2D3F2; --glow: rgba(236, 220, 255, .95); }
.pg19-win { flex: 1 1 auto; min-height: 0; width: 100% !important; height: auto !important; }
.pg19-win img { object-fit: contain; }
.pg19-lab.cplq-lab {
  white-space: normal; text-align: center; max-width: 100%;
  font-size: clamp(.64rem, 1.75vh, .92rem); line-height: 1.02; padding: .1rem .35rem .14rem;
  overflow-wrap: anywhere; hyphens: auto;
}
.pg19-lvl { font-size: clamp(.58rem, 1.45vh, .78rem); font-weight: 800; color: #7A4A12; line-height: 1; white-space: nowrap; }
.pg19-lvl b { color: #4A1F5C; }
.pg19-chip { position: absolute; top: .3rem; left: .3rem; z-index: 2; font-size: clamp(.62rem, 1.6vh, .82rem); }
@keyframes pg19In { from { opacity: 0; transform: translateY(10px) scale(.92); } to { opacity: 1; transform: none; } }
@media (hover: hover) {
  body.world-zamek .pg19-grid .hub-btn.cplq.pg19:hover { transform: translateY(-4px) rotate(-1deg); z-index: 3; }
}
body.world-zamek .pg19-grid .hub-btn.cplq.pg19:focus-visible { outline: 3px solid #FFE27A; outline-offset: 2px; }
@media (orientation: landscape) and (max-aspect-ratio: 19/10) {
  .pg19-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); grid-template-rows: repeat(3, minmax(0, 1fr)); }
}
/* portrait: pet + bubble on top row, 3 columns × 5 rows (tablet 4 × 4) */
@media (orientation: portrait) {
  .pg19-menu { grid-template-columns: 1fr; grid-template-rows: auto minmax(0, 1fr); gap: .3rem; }
  .pg19-host { flex-direction: row-reverse; justify-content: center; align-items: flex-end; gap: .5rem; padding: 0 .3rem; }
  .pg19-bubble { max-width: 230px; }
  .pg19-bubble::after { left: auto; right: -10px; bottom: 30%; margin-left: 0; transform: rotate(-45deg); }
  body.world-zamek .pg19-pet .playroom-pet { height: min(14vh, 150px); }
  .pg19-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); grid-template-rows: repeat(5, minmax(0, 1fr)); padding-bottom: .3rem; }
  body.world-zamek .pg19-grid .hub-btn.cplq.pg19 { padding: .4rem .2rem .28rem; gap: .12rem; }
  .pg19-lab.cplq-lab { font-size: clamp(.66rem, 1.5vh, .95rem); }
}
@media (orientation: portrait) and (min-width: 700px) {
  .pg19-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); grid-template-rows: repeat(4, minmax(0, 1fr)); }
  .pg19-bubble { max-width: 340px; font-size: 1.1rem; }
}
/* Poziom badge inside a game card */
.pr-lvl {
  flex: 0 0 auto; display: inline-flex; align-items: baseline; gap: .25rem;
  font-size: .78rem; font-weight: 800; color: #FFF3D6; white-space: nowrap;
  background: linear-gradient(180deg, #8E4FC0, #5A2370); border-radius: 999px; padding: .1rem .55rem .14rem;
  box-shadow: inset 0 0 0 1.5px #E9C46A, 0 2px 0 #3A1248;
}
.pr-lvl b { font-size: 1rem; color: #FFE27A; }
.pr-lvl.is-up { animation: prLvlUp .9s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes prLvlUp { 0% { transform: scale(1); } 35% { transform: scale(1.35); box-shadow: inset 0 0 0 1.5px #E9C46A, 0 0 0 6px rgba(255, 226, 122, .6); } 100% { transform: scale(1); } }
@media (max-width: 560px) {
  body.world-zamek .pr-task .pr-top { flex-wrap: wrap; row-gap: 3px; justify-content: center; }
  body.world-zamek .pr-task .pr-top .pr-verb { flex: 1 1 100%; max-width: none; text-align: center; justify-content: center; }
}

/* ═══ v19 start flow: castle splash · pick 3 heroes · name ═══ */
.st19 {
  position: fixed; inset: 0; display: grid; place-items: center; padding: 10px;
  min-height: 0 !important; overflow: hidden;
  background: linear-gradient(180deg, rgba(58, 22, 84, .30), rgba(58, 22, 84, .55)), url("art/tlo-zamek.jpg") center / cover no-repeat;
  font-family: 'Baloo 2', system-ui, sans-serif;
}
.st19-card {
  position: relative; box-sizing: border-box;
  width: min(94vw, 760px); max-height: calc(100dvh - 20px);
  display: flex; flex-direction: column; align-items: center; gap: clamp(4px, 1.4vh, 12px);
  padding: clamp(10px, 2.4vh, 24px) clamp(14px, 3vw, 30px);
  background: linear-gradient(180deg, #FFFCF3 0%, #F8EBD0 100%);
  border: 3px solid #C99A3C; border-radius: 26px;
  box-shadow: 0 0 0 5px rgba(255, 246, 220, .75), 0 18px 40px rgba(40, 12, 60, .38);
  color: #4A1F5C; text-align: center;
}
.st19-crest { width: clamp(38px, 7vh, 58px); height: auto; margin-top: calc(-1 * clamp(28px, 5vh, 44px)); filter: drop-shadow(0 3px 3px rgba(80, 40, 10, .3)); }
.st19-logo { margin: 0; font-size: clamp(1.7rem, 6.4vh, 2.8rem); line-height: 1; font-weight: 800; color: #5A2370; letter-spacing: .01em; text-shadow: 0 2px 0 #FFE9A8; }
.st19-sub { margin: 0; font-size: clamp(.9rem, 2.6vh, 1.1rem); font-weight: 600; color: #8A5A2B; }
.st19-h { margin: 0; font-size: clamp(1.25rem, 4.6vh, 2rem); line-height: 1.1; font-weight: 800; color: #5A2370; }
.st19-lead { margin: 0; font-size: clamp(.95rem, 2.8vh, 1.2rem); font-weight: 600; color: #6B3F7A; }
.st19-btns { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; }
.st19 .wd-btn { font-size: clamp(1rem, 3vh, 1.25rem); padding: .4rem 1.3rem .48rem; }
.st19 .st19-go { min-width: 12em; }
.st19 .wd-btn:disabled { opacity: .5; filter: grayscale(.4); cursor: default; }
/* hero art: feet on the frame line, no pedestal, gentle breathing */
.st19-hero { display: block; position: relative; aspect-ratio: 1; height: 100%; }
.st19-hero img { display: block; width: 100%; height: 100%; object-fit: contain; transform-origin: 50% 91%; animation: petBreathe 3.3s ease-in-out infinite; filter: drop-shadow(0 5px 5px rgba(60, 25, 70, .2)); }
.st19-b1 img { animation-delay: -1.1s; }
.st19-b2 img { animation-delay: -2.2s; }
.st19-trio { display: flex; justify-content: center; align-items: flex-end; width: 100%; margin-bottom: -2.5%; }
.st19-trio .st19-hero { flex: 0 1 auto; height: auto; width: clamp(90px, 34vh, 250px); max-width: 34%; margin: 0 -1%; }
.st19-trio--one .st19-hero { max-width: 60%; }
/* pick */
.st19-picks { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(8px, 2vw, 18px); width: 100%; }
.st19-pick {
  display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 4px;
  padding: 8px 6px 10px; border-radius: 20px; cursor: pointer; font-family: inherit;
  background: linear-gradient(180deg, #FFFFFF 0%, #F3E3F7 100%); border: 3px solid #D9B6E8;
  box-shadow: 0 5px 0 #B48ACB, 0 10px 18px rgba(74, 31, 92, .16);
  transition: transform .15s ease, box-shadow .15s ease;
}
.st19-pick--smok { background: linear-gradient(180deg, #FFFFFF 0%, #E1F3E4 100%); border-color: #A9D8B2; box-shadow: 0 5px 0 #77B585, 0 10px 18px rgba(30, 90, 50, .16); }
.st19-pick--chlopiec { background: linear-gradient(180deg, #FFFFFF 0%, #DDEBFA 100%); border-color: #A9C7EA; box-shadow: 0 5px 0 #7CA1CF, 0 10px 18px rgba(30, 60, 110, .16); }
.st19-pick:hover { transform: translateY(-3px); }
.st19-pick:active { transform: translateY(3px); }
.st19-pick .st19-hero { height: auto; width: min(100%, clamp(80px, 38vh, 260px)); margin-bottom: -6%; }
.st19-pick { min-width: 0; }
.st19-pick-lab { font-size: clamp(1rem, 3.2vh, 1.35rem); font-weight: 800; color: #4A1F5C; background: #FFF7E2; border: 2px solid #C99A3C; border-radius: 999px; padding: .05rem .8rem .12rem; white-space: nowrap; position: relative; z-index: 1; }
/* name */
.st19-card--name { flex-direction: row; gap: clamp(10px, 3vw, 28px); width: min(94vw, 820px); }
.st19-name-art { flex: 0 0 auto; height: clamp(150px, 62vh, 340px); display: flex; align-items: flex-end; }
.st19-name-r { flex: 1 1 auto; display: flex; flex-direction: column; align-items: center; gap: clamp(6px, 1.8vh, 14px); min-width: 0; }
.st19-names { display: grid; grid-template-columns: repeat(3, auto); gap: 8px; justify-content: center; }
.st19-nm { font-family: inherit; font-size: clamp(1rem, 3vh, 1.2rem); font-weight: 700; color: #4A1F5C; background: #FFFFFF; border: 2.5px solid #D9B6E8; border-radius: 999px; padding: .2rem 1rem .28rem; cursor: pointer; box-shadow: 0 3px 0 #C9A6DA; min-width: 5.2em; }
.st19-nm.is-on { background: linear-gradient(180deg, #8E4FC0, #6B2E92); color: #FFF4D6; border-color: #5A2370; box-shadow: 0 3px 0 #3A1248; }
@media (orientation: portrait) {
  .st19-card--name { flex-direction: column; }
  .st19-name-art { height: clamp(140px, 30vh, 300px); }
  .st19-trio .st19-hero { width: clamp(90px, 24vh, 250px); }
  .st19-pick .st19-hero { width: min(100%, clamp(80px, 24vh, 230px)); }
}
@media (max-width: 480px) {
  .st19-names { grid-template-columns: repeat(2, auto); }
  .st19-pick-lab { font-size: .92rem; padding: .05rem .5rem .12rem; }
}

/* ═══ v19 human heroes: no wing, no lids; same breathing + grounding ═══ */
.pet-sprite--human .pet-rig { transform-origin: 50% 91%; }
.bedroom15 .bed-sleeper--ksiezniczka, .bedroom15 .bed-sleeper--chlopiec { filter: drop-shadow(0 3px 3px rgba(60, 25, 70, .18)); }

/* ═══ v19 tutorial ═══ */
.tut19 { position: fixed; inset: 0; z-index: 9000; font-family: 'Baloo 2', system-ui, sans-serif; }
.tut19-ring {
  position: fixed; border-radius: 22px; pointer-events: none;
  box-shadow: 0 0 0 4px #FFE27A, 0 0 0 9999px rgba(36, 12, 52, .58), 0 0 22px 6px rgba(255, 226, 122, .9);
  transition: all .35s ease;
}
.tut19-hand { position: fixed; pointer-events: none; z-index: 2; filter: drop-shadow(0 4px 4px rgba(0, 0, 0, .35)); transition: left .35s ease, top .35s ease; }
.tut19-hand.is-on { animation: tutPoke 1.1s ease-in-out infinite; }
@keyframes tutPoke { 0%, 100% { translate: 0 0; } 50% { translate: -5px -5px; } }
.tut19-card {
  position: fixed; left: 50%; transform: translateX(-50%); z-index: 3;
  width: min(92vw, 560px); box-sizing: border-box; padding: 12px 18px 12px;
  background: linear-gradient(180deg, #FFFCF3, #F8EBD0); border: 3px solid #C99A3C; border-radius: 22px;
  box-shadow: 0 12px 28px rgba(20, 6, 30, .45); color: #4A1F5C; text-align: center;
}
.tut19-card.is-top { top: 12px; }
.tut19-card.is-bot { bottom: 12px; }
.tut19-n { display: inline-block; font-size: .85rem; font-weight: 800; color: #8A5A2B; background: #FFF2C6; border-radius: 999px; padding: 0 .6rem; }
.tut19-t { margin: .2rem 0 .5rem; font-size: clamp(1.15rem, 4.2vh, 1.6rem); line-height: 1.2; font-weight: 800; }
.tut19-btns { display: flex; justify-content: center; gap: 10px; }
.tut19 .wd-btn { font-size: clamp(1rem, 3vh, 1.2rem); }
@media (max-height: 430px) {
  .tut19-card { width: min(60vw, 520px); padding: 8px 14px; }
  .tut19-t { font-size: 1.1rem; margin: .1rem 0 .35rem; }
}
