@font-face {
  font-family: "Care Lilita";
  src: url("/assets/fonts/LilitaOne-Regular.ttf") format("truetype");
  font-display: swap;
}

@font-face {
  font-family: "Care Baloo";
  src: url("/assets/fonts/Baloo2-Variable.ttf") format("truetype");
  font-weight: 400 800;
  font-display: swap;
}

:root {
  --care-purple: #7227b8;
  --care-purple-dark: #53158a;
  --care-pink: #ef67ad;
  --care-gold: #dda640;
  --care-gold-dark: #b97426;
  --care-cream: #fff9df;
  --care-cream-deep: #f2d793;
  --care-green: #57a947;
  --care-safe-top: env(safe-area-inset-top, 0px);
  --care-safe-right: env(safe-area-inset-right, 0px);
  --care-safe-bottom: max(env(safe-area-inset-bottom, 0px), var(--lila-safe-bottom, 0px));
  --care-safe-left: env(safe-area-inset-left, 0px);
  --care-shadow: 0 8px 18px rgba(70, 40, 24, .2);
  --care-scene: url("/jogos/cuide-do-boi/scene/boi_scene_curral.png");
  --care-animal-width: min(57vw, 670px);
  --care-animal-height: min(78svh, 690px);
}

* { box-sizing: border-box; }
html, body { width: 100%; height: 100%; margin: 0; overflow: hidden; }

body.care-bull-page {
  min-height: 100dvh;
  color: #4c2660;
  background: #eedba5;
  font-family: "Care Baloo", "Trebuchet MS", sans-serif;
  -webkit-tap-highlight-color: transparent;
  overscroll-behavior: none;
}

body.care-bull-page .active-child-bar,
body.care-bull-page .progress-sync-badge { display: none !important; }

.care-bull-page button,
.care-bull-page a,
.care-bull-page img { -webkit-tap-highlight-color: transparent; }
.care-bull-page button { font: inherit; }
.care-bull-page .is-hidden { display: none !important; }
.care-bull-page .sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.care-bull-root {
  position: relative;
  width: 100%;
  height: var(--lila-app-height, 100dvh);
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #eedba5;
  isolation: isolate;
}

.care-bull-root:fullscreen,
.care-bull-root.is-pseudo-fullscreen {
  width: 100vw;
  height: var(--lila-app-height, 100dvh);
  max-width: none;
  max-height: none;
  border-radius: 0;
}

.care-bull-root.is-pseudo-fullscreen {
  position: fixed;
  inset: 0;
  z-index: 4000;
}

body.game-pseudo-fullscreen { overflow: hidden; }

/* Cabeçalho compacto, na mesma família dos jogos já refinados. */
.care-bull-topbar {
  position: relative;
  z-index: 30;
  flex: 0 0 auto;
  min-height: calc(60px + var(--care-safe-top));
  padding: calc(4px + var(--care-safe-top)) max(8px, var(--care-safe-right)) 4px max(8px, var(--care-safe-left));
  display: grid;
  grid-template-columns: 54px minmax(116px, 1fr) auto;
  align-items: center;
  gap: 8px;
  border-bottom: 3px solid #d29a35;
  background: linear-gradient(180deg, #fff6d4 0%, #f1d28a 100%);
  box-shadow: 0 5px 14px rgba(82, 50, 24, .24), inset 0 1px 0 rgba(255, 255, 255, .94);
}

.care-bull-back,
.care-bull-icon-btn {
  height: 52px;
  border: 2px solid #dca43d;
  border-radius: 17px;
  display: inline-grid;
  place-items: center;
  color: var(--care-purple-dark);
  background: linear-gradient(180deg, #fffdf1, #f3dca4);
  box-shadow: 0 4px 0 #bb7528, 0 6px 12px rgba(82, 48, 24, .18), inset 0 1px 0 #fff;
  cursor: pointer;
  touch-action: manipulation;
}

.care-bull-back {
  width: 54px;
  min-width: 54px;
  padding: 2px;
  text-decoration: none;
}

.care-bull-back img { width: 44px; height: 44px; object-fit: contain; }

.care-bull-topbar-actions {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 7px;
}

.care-bull-icon-btn {
  width: 52px;
  min-width: 52px;
  padding: 2px;
}

.care-bull-icon-btn img {
  width: 42px;
  height: 42px;
  display: block;
  object-fit: contain;
  pointer-events: none;
}

#care-bull-restart-btn img { width: 44px; height: 44px; }

.care-bull-back:active,
.care-bull-icon-btn:active { transform: translateY(2px); box-shadow: 0 2px 0 #bb7528, 0 4px 8px rgba(82, 48, 24, .16); }
.care-bull-back:focus-visible,
.care-bull-icon-btn:focus-visible,
.care-bull-task-card:focus-visible,
.care-bull-tool-button:focus-visible { outline: 4px solid #8239bd; outline-offset: 2px; }

.care-bull-task-progress {
  justify-self: center;
  display: grid;
  grid-template-columns: repeat(4, 28px);
  gap: 6px;
}

body.care-bull-selecting .care-bull-topbar {
  grid-template-columns: 54px minmax(0, 1fr);
}

body.care-bull-selecting .care-bull-task-progress,
body.care-bull-selecting .care-bull-topbar-actions { display: none; }

.care-bull-task-progress span {
  position: relative;
  width: 28px;
  height: 28px;
  overflow: hidden;
  border: 2px solid #d69e38;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: transparent;
  font-size: 0;
  background: #fff5cc;
  box-shadow: inset 0 1px 2px rgba(90, 52, 20, .14);
}

.care-bull-task-progress span::after {
  content: "";
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--care-pink);
  box-shadow: 0 0 0 3px rgba(239, 103, 173, .18);
}

.care-bull-task-progress span.locked::after {
  width: 17px;
  height: 17px;
  border-radius: 0;
  background: url("/jogos/cuide-do-boi/assets/ui/ui_lock_trimmed.png") center / contain no-repeat;
  box-shadow: none;
  filter: grayscale(.25);
  opacity: .68;
}

.care-bull-task-progress span.done {
  border-color: #5b9c42;
  background: #eaf7ce;
}

.care-bull-task-progress span.done::after {
  content: "✓";
  width: auto;
  height: auto;
  color: #3d8b39;
  background: transparent;
  box-shadow: none;
  font-family: "Care Baloo", sans-serif;
  font-size: 18px;
  font-weight: 800;
  line-height: 1;
}

.care-bull-shell { flex: 1 1 auto; min-height: 0; overflow: hidden; }

.care-animal-selection {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 0;
  overflow: hidden;
  display: grid;
  place-items: center;
  padding: 10px max(14px, var(--care-safe-right)) max(10px, var(--care-safe-bottom)) max(14px, var(--care-safe-left));
  background:
    linear-gradient(rgba(255, 248, 218, .18), rgba(238, 202, 126, .2)),
    url("/jogos/cuide-do-boi/scene/boi_scene_curral.png") center 58% / cover no-repeat;
}

.care-animal-selection::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(255, 250, 229, .24), rgba(255,255,255,.06), rgba(255, 250, 229, .24));
  pointer-events: none;
}

.care-animal-selection-panel {
  position: relative;
  z-index: 1;
  width: min(94vw, 1120px);
  max-height: 100%;
  padding: 9px 14px 14px;
  border: 4px solid #d9a13d;
  border-radius: 30px;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 7px;
  background: linear-gradient(160deg, rgba(255, 254, 241, .97), rgba(249, 225, 171, .95));
  box-shadow: 0 9px 0 rgba(174, 105, 36, .72), 0 17px 30px rgba(64, 37, 20, .24), inset 0 2px 0 #fff;
}

.care-animal-selection-panel h1 {
  margin: 0;
  color: #64249d;
  font-family: "Care Lilita", "Care Baloo", sans-serif;
  font-size: clamp(31px, 7svh, 44px);
  font-weight: 400;
  line-height: 1;
  text-align: center;
  text-shadow: 0 2px 0 #fff, 0 4px 8px rgba(88, 35, 117, .16);
}

.care-animal-grid {
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(8px, 1.35vw, 14px);
}

.care-animal-card {
  position: relative;
  min-width: 0;
  height: clamp(220px, 59svh, 272px);
  padding: 7px 8px 9px;
  overflow: hidden;
  border: 4px solid #e1ad45;
  border-radius: 25px;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  gap: 3px;
  color: #5a2383;
  background: linear-gradient(180deg, #fffdf1, #f7dda6);
  box-shadow: 0 6px 0 #b96f25, 0 10px 18px rgba(75, 41, 25, .2), inset 0 1px 0 #fff;
  cursor: pointer;
  touch-action: manipulation;
  transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease;
}

.care-animal-card::after {
  content: "";
  position: absolute;
  inset: 7px;
  border: 2px solid rgba(255,255,255,.72);
  border-radius: 17px;
  pointer-events: none;
}

.care-animal-card:active {
  transform: translateY(3px) scale(.985);
  border-color: #8c39c2;
  box-shadow: 0 3px 0 #7130a4, 0 7px 13px rgba(75, 41, 25, .18), inset 0 1px 0 #fff;
}

.care-animal-card:focus-visible { outline: 5px solid #8036bd; outline-offset: 3px; }

.care-animal-card-image {
  min-height: 0;
  overflow: hidden;
  border-radius: 17px;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at 50% 44%, rgba(255,255,255,.94), rgba(240, 206, 242, .54) 58%, rgba(226, 178, 225, .28));
}

.care-animal-card-image img {
  width: 100%;
  height: 100%;
  box-sizing: border-box;
  padding: 5px;
  display: block;
  object-fit: contain;
  object-position: center;
  filter: drop-shadow(0 7px 7px rgba(55, 25, 42, .2));
  pointer-events: none;
}

.care-animal-card strong {
  position: relative;
  z-index: 1;
  min-height: 34px;
  display: grid;
  place-items: center;
  font-family: "Care Lilita", "Care Baloo", sans-serif;
  font-size: clamp(18px, 4.4svh, 25px);
  font-weight: 400;
  line-height: 1;
  text-align: center;
}

.care-animal-card.premium-locked .premium-lock-label {
  left:50%;
  bottom:43px;
  transform:translateX(-50%);
  padding:6px 11px;
  font-family:"Care Baloo", sans-serif;
  font-size:12px;
}

.care-bull-game { position: relative; width: 100%; height: 100%; min-height: 0; overflow: hidden; isolation: isolate; }
.care-bull-layout {
  width: 100%;
  height: 100%;
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) clamp(250px, 29vw, 330px);
}

/* Área funcional do boi preservada. */
.care-bull-stage {
  position: relative;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  isolation: isolate;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  background-image: var(--care-scene);
  background-size: var(--care-scene-size, cover);
  background-position: var(--care-scene-position, center 58%);
  touch-action: none;
  user-select: none;
  -webkit-touch-callout: none;
  outline: none;
}

.care-bull-stage::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(to bottom, rgba(255,255,255,.02) 45%, rgba(70,36,0,.12));
  pointer-events: none;
}

.care-bull-night-overlay { position: absolute; inset: 0; z-index: 1; background: rgba(20, 22, 68, .55); opacity: 0; transition: opacity .5s; pointer-events: none; }
.care-bull-night-overlay.active { opacity: 1; }
.care-bull-image {
  position: relative;
  z-index: 2;
  width: var(--care-animal-width);
  height: var(--care-animal-height);
  object-fit: contain;
  object-position: var(--care-animal-position, center bottom);
  filter: drop-shadow(0 12px 12px rgba(30,15,0,.28));
  transform-origin: center bottom;
  transition: opacity .18s, transform .22s;
  pointer-events: auto;
  user-select: none;
}

.care-bull-image.happy-bounce { animation: careHappyBounce .7s ease; }
@keyframes careHappyBounce { 0%,100%{transform:translateY(0)} 35%{transform:translateY(-18px) scale(1.03)} 65%{transform:translateY(0) scale(.99)} }

.care-bull-instruction {
  position: absolute;
  z-index: 5;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  max-width: calc(100% - 32px);
  padding: 7px 18px 8px;
  border: 2px solid rgba(218, 163, 69, .78);
  border-radius: 999px;
  color: #6926a2;
  background: rgba(255, 251, 226, .95);
  box-shadow: 0 5px 14px rgba(65, 37, 23, .2), inset 0 1px 0 #fff;
  font-family: "Care Lilita", "Care Baloo", sans-serif;
  font-size: clamp(22px, 3vw, 32px);
  font-weight: 400;
  line-height: 1;
  text-align: center;
  white-space: nowrap;
}

.care-bull-step-progress {
  position: absolute;
  z-index: 6;
  left: 20%;
  right: 20%;
  bottom: max(9px, env(safe-area-inset-bottom, 0px));
  height: 18px;
  overflow: hidden;
  border: 3px solid #dca948;
  border-radius: 999px;
  background: rgba(255, 247, 218, .96);
  box-shadow: 0 3px 8px rgba(59, 24, 71, .18), inset 0 1px 3px rgba(98, 46, 105, .16);
}

.care-bull-step-progress-fill {
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #7a2bc1 0%, #c24ed7 48%, #f08ab8 74%, #ffd34f 100%);
  box-shadow: inset 0 2px 0 rgba(255, 255, 255, .44);
  transition: width .12s linear;
}

.care-bull-effect-layer { position: absolute; inset: 0; z-index: 4; pointer-events: none; overflow: hidden; }
.care-bull-particle { position: absolute; width: clamp(55px, 13vw, 105px); height: auto; transform: translate(-50%,-50%); animation: careParticlePop .7s ease-out forwards; }
@keyframes careParticlePop { from{opacity:0;transform:translate(-50%,-35%) scale(.45)} 30%{opacity:1} to{opacity:0;transform:translate(-50%,-95%) scale(1.05)} }
.care-bull-big-effect { position: absolute; left: 50%; top: 40%; width: min(44vw, 320px); transform: translate(-50%,-50%); animation: careBigEffect 1.25s ease forwards; }
@keyframes careBigEffect { 0%{opacity:0;transform:translate(-50%,-35%) scale(.5)} 25%{opacity:1} 100%{opacity:0;transform:translate(-50%,-75%) scale(1.12)} }

/* Painel lateral inteiramente creme/dourado. */
.care-bull-controls {
  position: relative;
  z-index: 8;
  min-width: 0;
  min-height: 0;
  padding: 10px calc(10px + var(--care-safe-right)) calc(10px + var(--care-safe-bottom)) 10px;
  display: flex;
  align-items: center;
  border-left: 3px solid #d49b39;
  background: linear-gradient(160deg, rgba(255, 252, 230, .98), rgba(246, 219, 158, .98));
  box-shadow: -6px 0 18px rgba(72, 43, 24, .2), inset 1px 0 0 rgba(255,255,255,.8);
}

.care-bull-task-menu {
  width: 100%;
  height: min(310px, 100%);
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
  gap: 9px;
}

.care-bull-task-card {
  position: relative;
  min-width: 0;
  min-height: 0;
  padding: 7px 5px 6px;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  place-items: center;
  overflow: hidden;
  border: 3px solid #dda33c;
  border-radius: 22px;
  color: #5f178e;
  background: linear-gradient(145deg, #fffdf2 0%, #f7dfa5 100%);
  box-shadow: 0 5px 0 #bd7429, 0 9px 17px rgba(73, 44, 25, .18), inset 0 1px 0 #fff;
  font-size: clamp(15px, 1.8vw, 18px);
  font-weight: 800;
  line-height: 1;
  text-align: center;
  cursor: pointer;
  touch-action: manipulation;
}

.care-bull-task-card:active { transform: translateY(2px); }
.care-bull-task-icon { width: clamp(56px, 15svh, 78px); aspect-ratio: 1; display: grid; place-items: center; transition: transform .18s ease; }
.care-bull-task-icon img { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 4px 5px rgba(80, 38, 54, .13)); }

.care-bull-task-card.next-task:not(.completed) {
  opacity: 1;
  border: 4px solid #f5c332;
  background: linear-gradient(145deg, #fffdf4 0%, #ffe6a2 100%);
  box-shadow: 0 5px 0 rgba(190,121,20,.42), 0 7px 16px rgba(97,53,10,.18), inset 0 1px 0 #fff;
  animation: careNextTaskPulse 1.7s ease-in-out infinite;
}

.care-bull-task-card.next-task:not(.completed) .care-bull-task-icon { transform: scale(1.06); }
.care-bull-task-card.locked {
  opacity: .82;
  filter: grayscale(.08) saturate(.82);
  border: 2px solid #d9c9ad;
  background: linear-gradient(145deg, #fffdf7 0%, #eee8dc 100%);
  box-shadow: 0 3px 8px rgba(76,47,16,.1);
  cursor: not-allowed;
}

.care-bull-task-card.locked .care-bull-task-icon { opacity: .78; }
.care-bull-task-card.locked::after {
  content: "";
  position: absolute;
  top: 7px;
  right: 7px;
  width: 29px;
  height: 29px;
  border: 2px solid #d7aa55;
  border-radius: 50%;
  background: #fff7da url("/jogos/cuide-do-boi/assets/ui/ui_lock_trimmed.png") center / 24px 24px no-repeat;
  box-shadow: 0 3px 7px rgba(59, 34, 17, .18);
}

.care-bull-task-card.completed {
  opacity: .94;
  border-color: #76a94d;
  color: #3d752e;
  background: linear-gradient(145deg, #fbfff0, #dff0bd);
  box-shadow: 0 4px 0 #6f9d44, 0 8px 15px rgba(54, 98, 39, .16), inset 0 1px 0 #fff;
}

.care-bull-task-check {
  display: none;
  position: absolute;
  top: 7px;
  right: 7px;
  width: 28px;
  height: 28px;
  border: 2px solid #fff8d9;
  border-radius: 50%;
  place-items: center;
  color: white;
  background: #4ba646;
  box-shadow: 0 3px 7px rgba(39, 76, 27, .22);
  font-size: 18px;
  font-weight: 800;
}

.care-bull-task-card.completed .care-bull-task-check { display: grid; }
@keyframes careNextTaskPulse { 0%,100%{transform:translateY(0)} 50%{transform:translateY(-2px)} }
.care-bull-task-card.blocked,
.care-bull-tool-button.blocked { animation: careBlockedShake .38s ease; }
@keyframes careBlockedShake { 20%,60%{transform:translateX(-7px)} 40%,80%{transform:translateX(7px)} }

.care-bull-activity-panel {
  width: 100%;
  height: min(310px, 100%);
  min-height: 0;
  padding: 9px;
  display: grid;
  grid-template-columns: 1fr;
  grid-template-rows: 47px minmax(0, 1fr) auto;
  align-content: center;
  gap: 7px;
  overflow: hidden;
  border: 3px solid #dca948;
  border-radius: 24px;
  background: linear-gradient(155deg, #fffdf0, #f5d99a);
  box-shadow: 0 8px 19px rgba(74, 41, 23, .18), inset 0 1px 0 #fff;
}

.care-bull-activity-back {
  width: 100%;
  min-height: 47px;
  padding: 3px 12px 3px 6px;
  border: 2px solid #d5a343;
  border-radius: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: #64248a;
  background: linear-gradient(#fffdf3, #ffe8b3);
  box-shadow: 0 4px 0 #bd792d, 0 6px 10px rgba(85, 39, 32, .13);
  font-weight: 800;
  cursor: pointer;
}

.care-bull-activity-back img { width: 38px; height: 38px; object-fit: contain; }
.care-bull-activity-items,
.care-bull-activity-items.bath-sequence {
  min-width: 0;
  min-height: 0;
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: center;
  gap: clamp(5px, .72vw, 8px);
}

.care-bull-tool-button {
  position: relative;
  flex: 0 1 auto;
  width: clamp(62px, 8vw, 84px);
  height: clamp(62px, 8vw, 84px);
  padding: 3px;
  border: 3px solid #dca948;
  border-radius: 20px;
  background: linear-gradient(145deg, #fffef4, #ffe8ad);
  box-shadow: 0 5px 0 #bd792d, 0 8px 14px rgba(72, 30, 46, .15), inset 0 1px 0 #fff;
  cursor: grab;
  touch-action: none;
}

.care-bull-tool-button:active { cursor: grabbing; transform: translateY(2px); }
.care-bull-tool-button img { width: 90%; height: 90%; object-fit: contain; pointer-events: none; }
.care-bull-activity-items:has(> .care-bull-tool-button:only-child) .care-bull-tool-button { width: clamp(98px, 13vw, 120px); height: clamp(98px, 13vw, 120px); }
.care-bull-tool-button.active { border-color: #f4c431; box-shadow: 0 0 0 3px rgba(255, 214, 65, .4), 0 5px 0 #bd792d, 0 8px 14px rgba(72, 30, 46, .15); animation: careActiveToolPulse 1.35s ease-in-out infinite; }
.care-bull-tool-button.completed { opacity: .78; border-color: #76a94d; background: #e8f5ce; cursor: default; }
.care-bull-tool-button.locked { opacity: .7; filter: grayscale(.16) saturate(.8); cursor: not-allowed; }
.care-bull-tool-button.wrong { animation: careWrongShake .4s ease; background: #ffe1e1; }
@keyframes careWrongShake { 20%,60%{transform:translateX(-8px)} 40%,80%{transform:translateX(8px)} }
@keyframes careActiveToolPulse { 0%,100%{transform:scale(1)} 50%{transform:scale(1.035)} }

.care-bull-tool-check,
.care-bull-tool-lock {
  display: none;
  position: absolute;
  top: 4px;
  right: 4px;
  width: 25px;
  height: 25px;
  border: 2px solid #fff8d9;
  border-radius: 50%;
  place-items: center;
  color: white;
  background: #4ba646;
  box-shadow: 0 3px 7px rgba(38,13,51,.2);
  font-size: 15px;
  font-weight: 800;
}

.care-bull-tool-lock {
  color: transparent;
  font-size: 0;
  background: #fff5d3 url("/jogos/cuide-do-boi/assets/ui/ui_lock_trimmed.png") center / 21px 21px no-repeat;
}

.care-bull-tool-button.completed .care-bull-tool-check,
.care-bull-tool-button.locked .care-bull-tool-lock { display: grid; }

.care-bull-activity-hint {
  min-height: 34px;
  margin: 0;
  padding: 5px 8px;
  align-self: end;
  display: grid;
  place-items: center;
  border: 1px solid rgba(216, 162, 67, .58);
  border-radius: 13px;
  color: #64248a;
  background: rgba(255, 252, 232, .9);
  font-size: clamp(13px, 1.45vw, 15px);
  font-weight: 750;
  line-height: 1.08;
  text-align: center;
  text-wrap: balance;
}

.care-bull-drag-ghost { position: absolute; z-index: 5000; width: clamp(90px, 23vw, 145px); height: auto; pointer-events: none; transform: translate(-50%,-50%) rotate(-6deg); filter: drop-shadow(0 10px 12px rgba(0,0,0,.25)); }

/* Pausa e conclusão premium, sem alterar as ações. */
.care-bull-modal {
  position: absolute;
  inset: 0;
  z-index: 2000;
  padding: 8px;
  display: grid;
  place-items: center;
  background: rgba(35, 22, 42, .58);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.care-bull-pause-modal { z-index: 2100; }
.care-bull-root.is-paused .care-bull-layout { filter: saturate(.72); }
.care-bull-modal-card {
  position: relative;
  width: min(620px, 88vw);
  max-height: calc(100svh - 78px);
  padding: clamp(10px, 2svh, 18px) clamp(16px, 3vw, 28px);
  display: grid;
  justify-items: center;
  align-content: center;
  gap: clamp(4px, 1svh, 8px);
  overflow: hidden;
  border: 4px solid #d9a13d;
  border-radius: 30px;
  color: #5b1688;
  background: linear-gradient(155deg, #fffdf0, #f5daa0);
  box-shadow: 0 18px 45px rgba(31, 17, 34, .34), inset 0 0 0 2px rgba(255,255,255,.82);
  text-align: center;
  animation: careModalIn .35s cubic-bezier(.2,.85,.35,1.15);
}

.care-bull-modal-card::before,
.care-bull-modal-card::after {
  content: "";
  position: absolute;
  width: 82px;
  height: 82px;
  border-radius: 50%;
  pointer-events: none;
  background: radial-gradient(circle at 35% 35%, rgba(124, 177, 71, .58) 0 13%, transparent 14%), radial-gradient(circle at 65% 62%, rgba(239, 103, 173, .4) 0 10%, transparent 11%);
  opacity: .65;
}
.care-bull-modal-card::before { top: -22px; left: -18px; }
.care-bull-modal-card::after { right: -18px; bottom: -22px; transform: rotate(180deg); }
@keyframes careModalIn { from{opacity:0;transform:scale(.76)} to{opacity:1;transform:scale(1)} }

.care-bull-finish-art { width: clamp(84px, 17svh, 120px); height: clamp(70px, 14svh, 100px); object-fit: contain; filter: drop-shadow(0 6px 6px rgba(67, 38, 24, .2)); }
.care-bull-finish-stars { color: #f7b928; font-size: clamp(24px, 6svh, 34px); line-height: .9; letter-spacing: 4px; text-shadow: 0 2px 0 #fff5c9; }
.care-bull-modal-card h2 { margin: 0; font-family: "Care Lilita", "Care Baloo", sans-serif; font-size: clamp(27px, 7svh, 38px); font-weight: 400; line-height: 1; }
.care-bull-modal-card p { max-width: 520px; margin: 0; color: #6f5576; font-size: clamp(14px, 3svh, 18px); font-weight: 700; line-height: 1.12; }
.care-bull-finish-actions { width: 100%; margin-top: 3px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.care-bull-finish-actions a,
.care-bull-finish-actions button {
  min-width: 0;
  min-height: 52px;
  padding: 6px 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 2px solid #dca43d;
  border-radius: 17px;
  font-family: "Care Baloo", sans-serif;
  font-size: clamp(14px, 2vw, 17px);
  font-weight: 800;
  line-height: 1;
  text-decoration: none;
}

.care-bull-finish-actions .secondary-btn { color: #5d2681; background: linear-gradient(#fffdf3, #f4dda7); box-shadow: 0 4px 0 #bd792d; }
.care-bull-finish-actions .primary-btn { color: white; border-color: #6721a4; background: linear-gradient(145deg, #8b35c4, #6721a4); box-shadow: 0 4px 0 #461370; }
.care-bull-finish-actions img { width: 34px; height: 34px; flex: 0 0 34px; object-fit: contain; }
.care-bull-pause-card { width: min(500px, 86vw); }
.care-bull-pause-icon { width: clamp(82px, 18svh, 112px); height: clamp(82px, 18svh, 112px); display: grid; place-items: center; }
.care-bull-pause-icon img { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 7px 8px rgba(76, 40, 22, .22)); }

@media (orientation: landscape) and (max-height: 420px) {
  .care-bull-topbar {
    min-height: calc(56px + var(--care-safe-top));
    padding-top: calc(2px + var(--care-safe-top));
    padding-bottom: 2px;
    grid-template-columns: 50px minmax(108px, 1fr) auto;
    gap: 6px;
  }
  .care-bull-back,
  .care-bull-icon-btn { height: 50px; }
  .care-bull-back { width: 50px; min-width: 50px; }
  .care-bull-back img { width: 42px; height: 42px; }
  .care-bull-icon-btn { width: 50px; min-width: 50px; }
  .care-bull-icon-btn img { width: 40px; height: 40px; }
  #care-bull-restart-btn img { width: 42px; height: 42px; }
  .care-bull-topbar-actions { gap: 5px; }
  .care-bull-task-progress { grid-template-columns: repeat(4, 26px); gap: 4px; }
  .care-bull-task-progress span { width: 26px; height: 26px; }
  .care-bull-controls { padding: 7px calc(7px + var(--care-safe-right)) calc(7px + var(--care-safe-bottom)) 7px; }
  .care-bull-task-menu { height: min(292px, 100%); gap: 7px; }
  .care-bull-task-card { padding: 4px; border-radius: 18px; font-size: 15px; }
  .care-bull-task-icon { width: clamp(54px, 14svh, 62px); }
  .care-bull-activity-panel { height: min(292px, 100%); padding: 7px; grid-template-rows: 43px minmax(0, 1fr) auto; gap: 5px; border-radius: 20px; }
  .care-bull-activity-back { min-height: 43px; }
  .care-bull-activity-back img { width: 35px; height: 35px; }
  .care-bull-tool-button { width: clamp(60px, 7.7vw, 72px); height: clamp(60px, 7.7vw, 72px); border-radius: 17px; }
  .care-bull-activity-items:has(> .care-bull-tool-button:only-child) .care-bull-tool-button { width: clamp(90px, 12vw, 106px); height: clamp(90px, 12vw, 106px); }
  .care-bull-activity-hint { min-height: 31px; padding-block: 3px; font-size: 13px; }
  .care-bull-instruction { top: 7px; padding: 5px 15px 6px; font-size: clamp(20px, 5svh, 24px); }
  .care-bull-step-progress { bottom: max(7px, env(safe-area-inset-bottom, 0px)); }
  .care-bull-modal-card { max-height: calc(100svh - 68px); padding-block: 8px; gap: 3px; }
  .care-bull-finish-art { width: 84px; height: 65px; }
  .care-bull-finish-stars { font-size: 23px; }
  .care-bull-modal-card h2 { font-size: 27px; }
  .care-bull-modal-card p { font-size: 13px; }
  .care-bull-finish-actions a,
  .care-bull-finish-actions button { min-height: 46px; }
  .care-bull-pause-icon { width: 76px; height: 76px; }
}

@media (prefers-reduced-motion: reduce) {
  .care-bull-page *,
  .care-bull-page *::before,
  .care-bull-page *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

/* Touch + landscape + fullscreen: canvas lógico único, escalado por contain. */
@media (hover: none) and (pointer: coarse) and (orientation: landscape) {
  html.lila-portable-touch-game:fullscreen body.care-bull-page {
    position: relative;
    isolation: isolate;
    width: 100%;
    height: 100%;
    min-height: 0;
    overflow: hidden;
    background-color: #eedba5;
  }

  html.lila-portable-touch-game:fullscreen body.care-bull-page::before {
    content: "";
    position: fixed;
    inset: -10px;
    z-index: 0;
    pointer-events: none;
    background-color: #eedba5;
    background-image: var(--care-page-scene, url("/jogos/cuide-do-boi/scene/boi_scene_curral.png"));
    background-position: center 58%;
    background-size: cover;
    background-repeat: no-repeat;
    filter: brightness(.82) saturate(.94) blur(5px);
    transform: scale(1.02);
    transform-origin: center;
  }

  html.lila-portable-touch-game:fullscreen body.care-bull-page.care-mobile-stage-active .care-bull-root {
    --care-safe-top: 0px;
    --care-safe-right: 0px;
    --care-safe-bottom: 0px;
    --care-safe-left: 0px;
    position: fixed;
    top: 50%;
    left: 50%;
    width: 1280px;
    height: 720px;
    min-width: 1280px;
    min-height: 720px;
    z-index: 1;
    overflow: hidden;
    transform: translate(-50%, -50%) scale(var(--care-stage-scale, 1));
    transform-origin: center;
  }

  html.lila-portable-touch-game:fullscreen .care-bull-topbar {
    min-height: 76px;
    height: 76px;
    padding: 8px 14px;
    grid-template-columns: 60px minmax(160px, 1fr) auto;
    gap: 12px;
    border-bottom-width: 4px;
  }

  html.lila-portable-touch-game:fullscreen body.care-bull-selecting .care-bull-topbar {
    grid-template-columns: 60px minmax(0, 1fr);
  }

  html.lila-portable-touch-game:fullscreen .care-bull-back,
  html.lila-portable-touch-game:fullscreen .care-bull-icon-btn {
    width: 56px;
    min-width: 56px;
    height: 56px;
    padding: 3px;
    border-radius: 18px;
  }

  html.lila-portable-touch-game:fullscreen .care-bull-back img,
  html.lila-portable-touch-game:fullscreen .care-bull-icon-btn img,
  html.lila-portable-touch-game:fullscreen #care-bull-restart-btn img {
    width: 46px;
    height: 46px;
  }

  html.lila-portable-touch-game:fullscreen .care-bull-topbar-actions { gap: 10px; }
  html.lila-portable-touch-game:fullscreen .care-bull-task-progress { grid-template-columns: repeat(4, 34px); gap: 8px; }
  html.lila-portable-touch-game:fullscreen .care-bull-task-progress span { width: 34px; height: 34px; }
  html.lila-portable-touch-game:fullscreen .care-bull-task-progress span::after { width: 15px; height: 15px; }

  html.lila-portable-touch-game:fullscreen .care-bull-shell { width: 1280px; height: 644px; flex: 0 0 644px; }
  html.lila-portable-touch-game:fullscreen .care-animal-selection { width: 1280px; height: 644px; padding: 18px 34px 26px; }
  html.lila-portable-touch-game:fullscreen .care-animal-selection-panel {
    width: 1160px;
    height: 590px;
    max-height: none;
    padding: 16px 22px 22px;
    border-width: 5px;
    border-radius: 34px;
    grid-template-rows: 54px 1fr;
    gap: 12px;
  }
  html.lila-portable-touch-game:fullscreen .care-animal-selection-panel h1 { font-size: 46px; }
  html.lila-portable-touch-game:fullscreen .care-animal-grid { grid-template-columns: repeat(4, 1fr); gap: 16px; }
  html.lila-portable-touch-game:fullscreen .care-animal-card {
    width: auto;
    height: 480px;
    padding: 10px 10px 14px;
    border-width: 5px;
    border-radius: 28px;
    gap: 6px;
  }
  html.lila-portable-touch-game:fullscreen .care-animal-card-image { border-radius: 19px; }
  html.lila-portable-touch-game:fullscreen .care-animal-card-image img { padding: 7px; }
  html.lila-portable-touch-game:fullscreen .care-animal-card strong { min-height: 44px; font-size: 28px; }
  html.lila-portable-touch-game:fullscreen .care-animal-card.premium-locked .premium-lock-label { bottom: 56px; font-size: 16px; }

  html.lila-portable-touch-game:fullscreen .care-bull-game,
  html.lila-portable-touch-game:fullscreen .care-bull-layout { width: 1280px; height: 644px; }
  html.lila-portable-touch-game:fullscreen .care-bull-layout { grid-template-columns: 920px 360px; }
  html.lila-portable-touch-game:fullscreen .care-bull-stage { width: 920px; height: 644px; }
  html.lila-portable-touch-game:fullscreen .care-bull-image { width: 670px; height: 590px; }
  html.lila-portable-touch-game:fullscreen .care-bull-image[data-animal="lola"] { width: 650px; height: 590px; }
  html.lila-portable-touch-game:fullscreen .care-bull-image[data-animal="horse"] { width: 620px; height: 600px; }
  html.lila-portable-touch-game:fullscreen .care-bull-image[data-animal="pig"] { width: 590px; height: 580px; }
  html.lila-portable-touch-game:fullscreen .care-bull-instruction { top: 14px; max-width: 850px; padding: 9px 24px 10px; font-size: 24px; }
  html.lila-portable-touch-game:fullscreen .care-bull-step-progress { bottom: 18px; width: 500px; height: 22px; }
  html.lila-portable-touch-game:fullscreen .care-bull-particle { width: 105px; }
  html.lila-portable-touch-game:fullscreen .care-bull-big-effect { width: 320px; }

  html.lila-portable-touch-game:fullscreen .care-bull-controls { width: 360px; height: 644px; padding: 18px 16px 22px; }
  html.lila-portable-touch-game:fullscreen .care-bull-task-menu { width: 328px; height: 604px; gap: 12px; }
  html.lila-portable-touch-game:fullscreen .care-bull-task-card { min-height: 0; padding: 10px; border-radius: 24px; font-size: 23px; }
  html.lila-portable-touch-game:fullscreen .care-bull-task-icon { width: 92px; height: 92px; }
  html.lila-portable-touch-game:fullscreen .care-bull-activity-panel { width: 328px; height: 604px; padding: 14px; grid-template-rows: 58px minmax(0, 1fr) 54px; gap: 12px; border-radius: 26px; }
  html.lila-portable-touch-game:fullscreen .care-bull-activity-back { min-height: 58px; padding: 8px 12px; font-size: 22px; }
  html.lila-portable-touch-game:fullscreen .care-bull-activity-back img { width: 42px; height: 42px; }
  html.lila-portable-touch-game:fullscreen .care-bull-activity-items { gap: 12px; }
  html.lila-portable-touch-game:fullscreen .care-bull-tool-button,
  html.lila-portable-touch-game:fullscreen .care-bull-activity-items:has(> .care-bull-tool-button:only-child) .care-bull-tool-button { width: 128px; height: 128px; }
  html.lila-portable-touch-game:fullscreen .care-bull-activity-hint { min-height: 54px; padding: 8px 10px; font-size: 17px; }
  html.lila-portable-touch-game:fullscreen .care-bull-drag-ghost { width: 145px; }

  html.lila-portable-touch-game:fullscreen .care-bull-modal { width: 1280px; height: 720px; }
  html.lila-portable-touch-game:fullscreen .care-bull-modal-card { width: 760px; max-width: none; padding: 26px 34px 30px; gap: 12px; border-radius: 34px; }
  html.lila-portable-touch-game:fullscreen .care-bull-finish-art { width: 120px; height: 100px; }
  html.lila-portable-touch-game:fullscreen .care-bull-finish-stars { font-size: 34px; }
  html.lila-portable-touch-game:fullscreen .care-bull-modal-card h2 { font-size: 42px; }
  html.lila-portable-touch-game:fullscreen .care-bull-modal-card p { font-size: 21px; }
  html.lila-portable-touch-game:fullscreen .care-bull-finish-actions { gap: 14px; }
  html.lila-portable-touch-game:fullscreen .care-bull-finish-actions a,
  html.lila-portable-touch-game:fullscreen .care-bull-finish-actions button { min-height: 62px; padding: 10px 18px; font-size: 20px; }
  html.lila-portable-touch-game:fullscreen .care-bull-pause-icon { width: 112px; height: 112px; }
}
