/* The character, coins, level, energy and hunger live in a side panel that stays put between screens. */
body.has-profile .topbar .status { display: none; }
.game-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 22px; align-items: start; padding-top: 18px; }
.game-main { min-width: 0; }
.buddy-panel {
  position: sticky;
  top: 92px;
  overflow: hidden;
  border: 4px solid #234c66;
  border-radius: 16px;
  background: linear-gradient(#3c7fa3, #2c6688);
  box-shadow: 0 5px 0 #1d4057, 0 14px 26px #2c526b33;
  color: #fff8e6;
}
.buddy-name {
  margin: 0;
  padding: 9px 12px;
  border-bottom: 3px solid #234c66;
  background: #1f4a66;
  color: #fff3cf;
  font: 900 19px/1.15 Nunito, system-ui, sans-serif;
  letter-spacing: .4px;
  text-align: center;
  overflow-wrap: anywhere;
}
.buddy-stage {
  position: relative;
  height: 236px;
  margin: 8px 10px 0;
}
.buddy-stage .avatar { bottom: 2px; transform: translateX(-50%) scale(.66); transform-origin: bottom center; }
/* A thicker outer contour so the character stands out on the panel. */
.buddy-stage .avatar-art { filter: drop-shadow(3.5px 0 0 #0e2130) drop-shadow(-3.5px 0 0 #0e2130) drop-shadow(0 3.5px 0 #0e2130) drop-shadow(0 -3.5px 0 #0e2130); }
.buddy-stats { padding: 10px 12px 14px; }
.buddy-stats h3 {
  margin: 0 0 8px;
  padding: 4px 8px;
  border-radius: 7px;
  background: #1f4a66;
  color: #fff3cf;
  font: 900 13px Nunito, system-ui, sans-serif;
  letter-spacing: 1.4px;
  text-transform: uppercase;
}
.buddy-money, .buddy-level { display: flex; align-items: center; gap: 6px; margin: 0 0 6px; color: #fff8e6; font: 800 14px/1.2 Nunito, system-ui, sans-serif; }
.buddy-money strong, .buddy-level strong { color: #ffe08a; font-size: 17px; }
.buddy-bar { display: grid; grid-template-columns: 1fr auto; gap: 3px 6px; margin-top: 9px; font: 800 13px/1.2 Nunito, system-ui, sans-serif; }
.buddy-bar b { color: #ffe08a; font-weight: 900; }
.buddy-track { grid-column: 1 / -1; height: 12px; border: 2px solid #1d4057; border-radius: 99px; background: #1f4a66; overflow: hidden; }
.buddy-track i { display: block; height: 100%; border-radius: inherit; box-shadow: inset 0 2px 0 #ffffff59; transition: width .3s ease; }
.bar-energy .buddy-track i { background: linear-gradient(#ffe27a, #f2b736); }
.bar-hunger .buddy-track i { background: linear-gradient(#f48a76, #d9493f); }

@media (max-width: 900px) {
  .game-layout { grid-template-columns: 1fr; gap: 12px; padding-top: 12px; }
  .buddy-panel { position: static; display: grid; grid-template-columns: 112px minmax(0, 1fr); grid-template-rows: auto 1fr; }
  .buddy-name { grid-column: 1 / -1; padding: 6px 10px; font-size: 16px; }
  .buddy-stage { height: 150px; margin: 8px 0 8px 8px; }
  .buddy-stage .avatar { transform: translateX(-50%) scale(.42); }
  .buddy-stats { padding: 8px 10px 10px; }
  .buddy-stats h3 { display: none; }
  .buddy-money, .buddy-level { display: inline-flex; margin: 0 12px 2px 0; font-size: 13px; }
  .buddy-bar { margin-top: 5px; font-size: 12px; }
}
.buddy-stage .avatar-art > ellipse:first-of-type { display: none; }
