#duos-dialog {
  width: min(620px, 94vw);
}
#duos-dialog .community-card {
  display: grid;
  gap: 10px;
  margin: 12px 0;
}
#duos-dialog button {
  min-height: 44px;
}
#duos-request:not(:empty) {
  padding: 14px;
  border: 2px solid #516746;
  background: #eef2d6;
}
#duos-encounters > button {
  display: block;
  width: 100%;
  margin: 8px 0;
}
#battle-dialog[data-format='doubles'] .battle-scene {
  aspect-ratio: 240 / 112;
}
#battle-dialog[data-format='doubles'] .monster-info {
  width: 41%;
  min-width: 0;
  padding: 0.6% 1%;
  font-size: 4.1cqw;
  line-height: 1.05;
}
#battle-dialog[data-format='doubles'] .monster-info strong {
  overflow: hidden;
  text-overflow: ellipsis;
}
#battle-dialog[data-format='doubles'] .monster-info small,
#battle-dialog[data-format='doubles'] #own-health {
  /* Keep trainer names and exact HP accessible without adding a third HUD row. */
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  clip-path: inset(50%);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
#battle-dialog[data-format='doubles'] #enemy-level,
#battle-dialog[data-format='doubles'] #own-level {
  font-size: inherit;
}
#battle-dialog[data-format='doubles'] .hp-row b {
  font-size: 3.2cqw;
}
#battle-dialog[data-format='doubles'] .monster-meta {
  display: none;
}
#battle-dialog[data-format='doubles'] .enemy-info {
  left: 6%;
  top: 3%;
  bottom: auto;
  right: auto;
}
#battle-dialog[data-format='doubles'] .enemy-ally-info {
  left: 1%;
  top: 25%;
  right: auto;
  bottom: auto;
}
#battle-dialog[data-format='doubles'] .own-info {
  left: auto;
  bottom: 27%;
  right: 7%;
  top: auto;
}
#battle-dialog[data-format='doubles'] .ally-info {
  right: 2%;
  bottom: 2%;
  left: auto;
  top: auto;
}
#battle-dialog[data-format='doubles'] .own-sprite,
#battle-dialog[data-format='doubles'] .ally-sprite,
#battle-dialog[data-format='doubles'] .enemy-sprite,
#battle-dialog[data-format='doubles'] .enemy-ally-sprite {
  position: absolute;
  width: 35%;
  height: 65%;
  max-width: none;
  object-fit: contain;
  image-rendering: pixelated;
  z-index: 1;
  transform-origin: center bottom;
}
#battle-dialog[data-format='doubles'] .enemy-sprite {
  left: auto;
  top: 0;
  right: 0;
  bottom: auto;
}
#battle-dialog[data-format='doubles'] .enemy-ally-sprite {
  left: 50%;
  right: auto;
  top: 7%;
  bottom: auto;
  z-index: 2;
}
#battle-dialog[data-format='doubles'] .own-sprite {
  left: -3%;
  bottom: -8%;
  top: auto;
  right: auto;
  width: 36%;
  height: 67%;
  z-index: 3;
}
#battle-dialog[data-format='doubles'] .ally-sprite {
  left: 22%;
  right: auto;
  bottom: -1%;
  top: auto;
  width: 34%;
  height: 58%;
  z-index: 2;
}
#battle-dialog[data-format='doubles'] #battle-exp {
  display: none;
}
#battle-dialog #battle-targets {
  display: grid;
  gap: 8px;
  grid-template-columns: 1fr;
  padding: 10px;
}
#battle-dialog #battle-targets p {
  font-size: 3.8cqw;
  margin: 0;
}
#battle-dialog #battle-targets button {
  min-height: 44px;
  font-size: 4.8cqw;
  padding: 8px;
}
#battle-dialog[data-panel='targets'] .battle-console {
  height: max(26cqw, 205px);
}
#battle-dialog[data-panel='targets'] #battle-question {
  display: none;
}
#battle-dialog #battle-targets {
  grid-column: 1 / -1;
  grid-row: 1;
  grid-template-rows: auto 1fr 1fr;
  overflow: auto;
  padding-bottom: 38px;
}
#battle-dialog[data-format='doubles'] #enemy-count {
  color: inherit;
}
