:root {
  --ui-bg-color: #a9a9a9;
  --ui-border-color: #d3d3d3;
  --ui-button-color: #efefef;
  --ui-font-size-sm: 0.875rem;
  --rw-bg-color: #111;
}

*,
*::before,
*::after {
  box-sizing: inherit;
}

html {
  font-size: 16px;
  line-height: 1.15;
  box-sizing: border-box;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  padding: 0;
  background-color: var(--ui-bg-color);
  image-rendering: pixelated;
  image-rendering: crisp-edges; /* fallback for Firefox */
}

body.scroll-lock {
  overflow: hidden;
}

main {
  display: block;
}

strong {
  font-weight: bolder;
}

button,
input,
optgroup,
select,
textarea {
  font-family: inherit;
  font-size: 100%;
  line-height: 1.15;
  margin: 0;
}

button,
input {
  overflow: visible;
}

button,
select {
  text-transform: none;
}

button,
[type="button"],
[type="reset"],
[type="submit"] {
  -webkit-appearance: button;
}

button::-moz-focus-inner,
[type="button"]::-moz-focus-inner,
[type="reset"]::-moz-focus-inner,
[type="submit"]::-moz-focus-inner {
  border-style: none;
  padding: 0;
}

button:-moz-focusring,
[type="button"]:-moz-focusring,
[type="reset"]:-moz-focusring,
[type="submit"]:-moz-focusring {
  outline: 1px dotted ButtonText;
}

fieldset {
  padding: 0.35em 0.75em 0.625em;
  display: block;
  margin-inline-start: 2px;
  margin-inline-end: 2px;
  padding-block-start: 0.35em;
  padding-inline-start: 0.75em;
  padding-inline-end: 0.75em;
  padding-block-end: 0.625em;
  min-inline-size: min-content;
  border-width: 2px;
  border-style: groove;
  border-color: var(--ui-border-color);
  border-image: initial;
}

legend {
  box-sizing: border-box;
  color: inherit;
  display: table;
  max-width: 100%;
  padding: 0;
  white-space: normal;
}

.app-content {
  display: flex;
}

.player-panel {
  width: 300px;
  flex-shrink: 0;
}

.ascii-map-panel .player-details {
  display: flex;
  justify-content: space-evenly;
  text-align: center;
}

.ascii-map-panel .player-details > span {
  flex: 1 1 25%;
}

.ascii-map-panel .player-details > span:last-child {
  flex: 2 2 50%;
}

.play-area {
  flex-grow: 1;
  min-height: 100vh;
}

.play-area fieldset {
  height: 100%;
}

.play-area .board {
  position: relative;
  background-color: var(--rw-bg-color);
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  overflow-x: auto;
  border-style: inset;
  border-width: 2px;
}

.sprite {
  position: absolute;
}

.translucent {
  opacity: 0.4;
}

.player {
  width: 30px;
  height: 52px;
}

.boy {
  background-image: url(/img/sprite/boy.png);
}

.girl {
  background-image: url(/img/sprite/girl.png);
}

.floor {
  width: 40px;
  height: 30px;
  background-size: 40px 30px;
  background-image: url(/img/floor/floor.png);
}

.wall {
  width: 30px;
  height: 60px;
  background-size: 30px 60px;
}

.cap {
  width: 30px;
  height: 60px;
  background-size: 30px 60px;
}

.nsw {
  background-image: url(/img/wall/nsw.png);
}

.eww {
  background-image: url(/img/wall/eww.png);
}

.new {
  background-image: url(/img/wall/new.png);
}

.nww {
  background-image: url(/img/wall/nww.png);
}

.sew {
  background-image: url(/img/wall/sew.png);
}

.sww {
  background-image: url(/img/wall/sww.png);
}

.net {
  background-image: url(/img/wall/net.png);
}

.nwt {
  background-image: url(/img/wall/nwt.png);
}

.set {
  background-image: url(/img/wall/set.png);
}

.swt {
  background-image: url(/img/wall/swt.png);
}

.crt {
  background-image: url(/img/wall/crt.png);
}

.csp {
  background-image: url(/img/wall/csp.png);
}

.swc {
  background-image: url(/img/wall/swc.png);
}

.ewc {
  background-image: url(/img/wall/ewc.png);
}

.sec {
  background-image: url(/img/wall/sec.png);
}
