::-webkit-scrollbar {
  width: 6px;
  height: 0;
}
::-webkit-scrollbar-track {
  border-radius: 3px;
  background: rgba(0, 0, 0, 0.15);
}
::-webkit-scrollbar-thumb {
  border-radius: 3px;
  background: rgba(0, 0, 0, 0.3);
}

html, body {
  overflow: hidden;
  height: 100%;

  position: fixed;
  -webkit-overflow-scrolling: touch;
  -webkit-user-select: none;
  -moz-user-select: none;
  user-select: none;
}

body {
  font-family: Ubuntu;
  font-size: 14px;
  background-color: #484848;
}

hr {
  border: 0.5px solid rgba(0, 0, 0, 0.15);
  margin: 18px 0 18px;
}

html, body, canvas {
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
}

h1 {
  padding: 0;
  margin: 0;
  text-align: center;
  font: bold 40px/1.1 Ubuntu;
}

div.optionsHeader {
  display: block;
  margin: 10px 0 4px;
  font: bold 13px/1 Ubuntu;
  color: #000000;
  text-align: center;
}

h3 {
  font-size: 14px;
  color: #484848;
  text-align: center;
  padding: 0;
  margin: 4px 0;
}
#startMenuSlidingTrigger:hover > h3 {
  color: #323232;
}
#startMenuSlidingTrigger:hover > h3 > i.arrow {
  border-color: #323232;
}

.serverSelector {
  height: 85px;
  text-align: center;
  font-size: 14px;
  font-weight: bold;
  line-height: 13px;
  padding-left: 10px;
  scroll-behavior: smooth;
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 0, 0, 0.3) rgba(0, 0, 0, 0.15);
}
.serverSelector tr {
  color: #828282;
  cursor: pointer;
}
.serverSelector tr.featured {
  color: #e8ae00;
  text-shadow: /*#ffe500 0 0 4px,*/ #fff27e 0 0 6px;
}
.serverSelector tr.selected {
  color: #8ABC3F;
  cursor: default;
}

.shadowScroll {
  overflow-y: scroll;
  background:
    /* Shadow covers */
    linear-gradient(#dde6eb 30%, rgba(255, 255, 255, 0)),
    linear-gradient(rgba(255, 255, 255, 0), #dde6eb 70%) 0 100%,
    /* Shadows */
    radial-gradient(farthest-side at 50% 0, rgba(0, 0, 0, .2), rgba(0, 0, 0, 0)),
    radial-gradient(farthest-side at 50% 100%, rgba(0, 0, 0, .2), rgba(0, 0, 0, 0)) 0 100%;
  background-repeat: no-repeat;
  background-color: #dde6eb;
  background-size: 100% 40px, 100% 40px, 100% 14px, 100% 14px;
  background-attachment: local, local, scroll, scroll;
}
a:link, a:visited {
  color: #484848;
}
a:link:hover, a:visited:hover {
  color: #909090;
}

input {
  text-align: center;
  width: 100%;
  padding: 10px;
  border: solid 1px #dcdcdc;
  box-sizing: border-box;
  border-radius: 5px;
  margin-top: 5px;
  margin-bottom: 5px;
  outline: none;
  font-family: Ubuntu;
  transition: border 0.3s, background 0.3s, color 0.3s;
}

#playerNameInput {
  padding: 10px;
  font-size: larger;
}

#playerKeyInput {
  padding: 5px;
}

input:focus {
  border: solid 1px #CCCCCC;
}

input.error {
  border: solid 1px #f00;
  background: #fee;
  color: #a00;
}

#mainWrapper {
  padding: 75px 20px 0;
}

#startMenu {
  position: relative;
  margin: 0 auto;
  max-height: 390px;
  padding: 10px;
  border-radius: 5px;
  background-color: #DDE6EB;
  box-sizing: border-box;
  overflow: hidden;
}
.menuTabs {
  height: 26px;
  margin: 0 8px;
}

body.mobile #mainWrapper { padding: 50px 50px 0; }
body.mobile #startMenu { max-height: 340px; }
body.mobile #linkHolder { display: none; }

.referral {
  display: block;
  width: 336px;
  height: 280px;
  margin: 0 8px 6px 7px;
}

.referral-fallback {
  display: none;
}

.respawn-banner {
  position: absolute;
  width: 728px;
  bottom: 30px;
  left: 0;
  right: 0;
  margin-left: auto;
  margin-right: auto;
}

.startMenuHolder {
  width: 350px;
  height: 350px;
  padding: 10px;
  overflow: hidden;
  display: inline-block;
  vertical-align: text-top;
  position: relative;
}

.startMenuHolder.shrinkable {
  width: calc(100% - 394px);
}
body.mobile .startMenuHolder {
  height: 300px;
}
body.mobile .startMenuHolder.shrinkable {
  width: calc(100% - 400px);
}

a.menuTab {
  float: right;
  height: 13px;
  font: 13px Ubuntu;
  padding: 6px 10px 7px 10px;
  border-radius: 5px 5px 0 0;
  color: #ffffff !important;
  text-decoration: none;
  margin-right: 10px;
}
a.menuTab.discord {
  padding: 6px 10px 7px 32px;
  background: #7289DA url(/img/discord.svg) 8px 3px/22px no-repeat;
}
a.menuTab.stat {
  background: #f00 url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAYAAACNMs+9AAAAKUlEQVQoU2NkQAP/////DxJiZGRkRJZC4YAkcCpEl6C9QrgNhKweSgoBUcBf8wTAguMAAAAASUVORK5CYII=) 10px 8px no-repeat;
  /*
  let canvas = document.body.appendChild(document.createElement('canvas'))
  canvas.width = 10
  canvas.height = 10
  canvas.style.background = '#f00'
  let ctx = canvas.getContext('2d')
  ctx.fillStyle = '#fff'
  ctx.fillRect(0, 2, 2, 8)
  ctx.fillRect(4, 0, 2, 10)
  ctx.fillRect(8, 4, 2, 6)
  copy(canvas.toDataURL())
  */
  padding: 6px 10px 7px 28px;
}
a.menuTab:link:hover, a.menuTab:visited:hover {
  text-decoration: underline;
}

.changelogSelectorContainer {
  height: 25px;
  font: bold 20px Ubuntu;
  text-align: center;
  padding: 0 15px 5px 0;
  overflow: auto hidden;
  scrollbar-width: none;
  scroll-behavior: smooth;
}
.changelogSelectorContainer::before, .changelogSelectorContainer::after {
  content: '';
  position: absolute;
  display: block;
  height: 15px;
  width: 8px;
  pointer-events: none;
}
.changelogSelectorContainer::before {
  background: linear-gradient(to right, rgba(221, 230, 235, 1) 0%, rgba(221, 230, 235, 0.3) 100%);
}
.changelogSelectorContainer::after {
  top: 10px;
  right: 10px;
  background: linear-gradient(to left, rgba(221, 230, 235, 1) 0%, rgba(221, 230, 235, 0.3) 100%);
}
.changelogSelector {
  width: 340px;
}
.changelogSelector span {
  transition: color 500ms;
  color: #222;
  cursor: pointer;
}
.changelogSelector span:hover {
  transition: color 200ms;
  color: #555;
}
.changelogSelector span.active {
  color: #777;
  cursor: default;
}

.changelogSelector span:not(:first-child)::before {
  content: ' ';
  color: #aaa;
  margin: 0 3px 0 0;
}
.changelogSelector span:not(:last-child)::after {
  content: ' |';
  color: #aaa;
  margin: 0 0 0 3px;
}

.sliderHolder {
  width: 350px;
  height: 300px;
  overflow: hidden;
}
body.mobile .sliderHolder {
  height: 245px;
}

table {
  width: 100%;
}
body.mobile .controlTable {
  display: none;
}
.resetControls {
  opacity: 0;
  transform: rotate(0deg);
  transition: opacity 1000ms, margin 1000ms;
  margin: 0 -6px;
}
.resetControls.spin {
  transition: transform 500ms, opacity 1000ms 150ms, margin 1000ms 150ms;
  transform: rotate(360deg);
}
.resetControls.active {
  opacity: 1;
  margin: 0 5px;
  cursor: pointer;
}
.moreControls {
  cursor: pointer;
}
.controlTable {
  border-collapse: collapse;
  margin: 0 2px;
}
.controlTable tr {
  border: 0;
  transition: opacity 500ms;
}
.controlTable tr.hidden {
  opacity: 0;
  pointer-events: none;
}
.controlTable td {
  transition: padding 500ms;
}
.controlTable div {
  position: relative;
  top: 0px;
  height: 18px;
  transition: height 500ms, top 500ms;
}
.controlTable tr.hidden td {
  padding: 0 1px;
}
.controlTable tr.hidden div {
  top: -20px;
  height: 0;
}
.controlTable td b {
  display: inline-block;
  width: 12px;
  height: 16px;
  cursor: pointer;
  text-align: right;
  vertical-align: bottom;
}
.controlTable td b:hover {
  color: #777;
}
.controlTable td.editing b {
  background: #fff;
  color: #333;
  border: 1px solid #dcdcdc;
  border-radius: 4px;
  padding: 1px 4px;
  margin: -2px -7px -2px -3px;
  text-align: center;
  cursor: text;
  -webkit-user-select: auto;
  -moz-user-select: auto;
  -ms-user-select: auto;
  user-select: auto;
}
.controlTable td.editing span {
  visibility: hidden;
}

#optColors {
  width: 220px;
}
#optMobile {
  display: none;
}
#optBorders {
  width: 120px;
}
body.mobile #optColors {
  width: 346px;
  margin-bottom: 4px;
}
body.mobile #optMobile, body.mobile #optBorders {
  width: 170px;
  margin-bottom: 4px;
  display: inline-block;
}

.slider {
  position: relative;
  top: 0px;
  opacity: 1;
  width: 100%;
  transition: top 500ms, opacity 500ms;
}
.slided .slider {
  top: -275px;
}
body.mobile .slided .slider {
  top: -225px;
}

.startMenuSlidingContent {
  height: 275px;
}
body.mobile .startMenuSlidingContent {
  height: 225px;
}

#startMenuSlidingTrigger {
  cursor: pointer;
  height: 15px;
}

.icon {
  display: block;
  width: 96px;
  height: 96px;
  border-radius: 50%;
}
body.mobile .icon {
  width: 90px;
  height: 90px;
}

#patchNotes {
  max-width: 330px;
  height: calc(100% - 40px);
  padding: 5px 10px 10px;
  overflow: hidden auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 0, 0, 0.3) rgba(0, 0, 0, 0.15);
}

#patchNotes ul {
  padding-left: 15px;
  margin-left: 10px;
}

#patchNotes table.poll-list {
  margin: 8px 0px 20px 5px;
}
#patchNotes table.poll-table {
  text-align: center;
  margin: 0 0 12px;
}
#patchNotes table.poll-table thead {
  font-weight: bold;
}
#patchNotes b small {
  color: #444;
}
#patchNotes b small a {
  margin-left: 10px;
}

#patchNotes div {
  transition: max-height 500ms, opacity 500ms, line-height 500ms;
  max-height: 1500px;
  opacity: 1;
  margin-bottom: 0;
  line-height: 1.2;
}
#patchNotes div hr {
  transition: margin 500ms;
}
#patchNotes.updates .balance,
#patchNotes.updates .patch,
#patchNotes.events .update,
#patchNotes.events .poll,
#patchNotes.events .balance-update,
#patchNotes.events .balance,
#patchNotes.events .patch,
#patchNotes.balances .update,
#patchNotes.balances .poll,
#patchNotes.balances .event-poll,
#patchNotes.balances .event,
#patchNotes.balances .patch {
  max-height: 0px;
  opacity: 0;
  line-height: 0;
}
#patchNotes.updates .balance hr,
#patchNotes.updates .patch hr,
#patchNotes.events .update hr,
#patchNotes.events .poll hr,
#patchNotes.events .balance-update hr,
#patchNotes.events .balance hr,
#patchNotes.events .patch hr,
#patchNotes.balances .update hr,
#patchNotes.balances .poll hr,
#patchNotes.balances .event-poll hr,
#patchNotes.balances .event hr,
#patchNotes.balances .patch hr {
  margin: 0;
}

#startButton {
  margin: 0;
  width: 100%;
  height: 40px;
  box-sizing: border-box;
  color: white;
  text-align: center;
  text-shadow: 0 0 3px rgba(0, 0, 0, 0.2), 0 1px 2px rgba(0, 0, 0, 0.2);
  background: #A9D86D;
  border: 0;
  border-bottom: 2px solid #8ABC3F;
  cursor: pointer;
  box-shadow: inset 0 -2px #8ABC3F;
  border-radius: 5px;
  font: 16px Ubuntu;
}
#startButton:hover {
  margin-top: 1px;
  height: 39px;
  border-bottom: 1px solid #8ABC3F;
}

#startButton:active {
  margin-top: 2px;
  height: 38px;
  background: #8ABC3F;
  border-bottom: 0px
  outline: none;
  box-shadow: none;
}

#bottomHolder > a {
  display: inline-block;
  position: relative;
  margin: 2px;
  border: 0px;
  padding: 5px;
  width: 100px;
  height: 16px;
  font-size: smaller;
  color: white;
  text-align: center;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
  text-decoration: none;
  cursor: pointer;
  background: #B58EFD;
  border-radius: 5px;
  box-shadow: inset 0 -4px rgba(0, 0, 0, 0.15);
}
#bottomHolder > a:hover {
  top: 1px;
  height: 15px;
  box-shadow: inset 0 -3px rgba(0, 0, 0, 0.15);
}
#bottomHolder > a:active {
  top: 4px;
  height: 12px;
  box-shadow: inset 0 -25px rgba(0, 0, 0, 0.15);
}

#startMenuWrapper {
  transition: top 1s;
  position: relative;
  top: 0px;
  z-index: 2;
  max-width: 755px;
  margin: 0 auto;
}
body.mobile #startMenuWrapper { max-width: 750px; }

#gameAreaWrapper {
  position: absolute !important;
  top: 0;
  left: 0;
  opacity: 0;
}

*:focus {
  outline: 1px solid transparent;
}

/* Customize the label (the container) */
.count {
  display: inline-block;
  width: 20px;
  font: bold 12px Ubuntu;
}
.count span {
  font-size: 10px;
}

.container {
  position: relative;
  padding-left: 20px;
  cursor: pointer;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}

.container input {
  position: absolute;
  visibility: hidden;
  width: 0;
  height: 0;
  cursor: pointer;
}

.checkmark {
  position: absolute;
  top: 0;
  left: 0;
  height: 14px;
  width: 14px;
  border-radius: 4px;
  background-color: #eee;
  border: 1px solid #ccc;
}

.container:hover input ~ .checkmark {
  background-color: #ccc;
}

.container input:disabled ~ .checkmark {
  background-color: #ddd;
}

.container input:checked ~ .checkmark {
  background-color: #8ABC3F;
  border: 1px solid #8ABC3F;
}

.container:hover input:checked ~ .checkmark {
  background-color: #7FA843;
  border: 1px solid #7FA843;
}

.container input:disabled:checked ~ .checkmark {
  background-color: #a1c172;
  border: 1px solid #a1c172;
}

.container .checkmark:after {
  content: '';
  position: absolute;
  display: none;
  left: 4px;
  top: 1px;
  width: 4px;
  height: 8px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.container input:checked ~ .checkmark:after {
  display: block;
}

.radio {
  position: absolute;
  top: 0;
  left: 0;
  height: 14px;
  width: 14px;
  border-radius: 50%;
  background-color: #eee;
  border: 1px solid #ccc;
}

.container:hover input ~ .radio {
  background-color: #ccc;
}

.container input:disabled ~ .radio {
  background-color: #ddd;
}

.container input:checked ~ .radio {
  background-color: #8ABC3F;
  border: 1px solid #8ABC3F;
}

.container:hover input:checked ~ .radio {
  background-color: #7FA843;
  border: 1px solid #7FA843;
}

.container input:disabled:checked ~ .radio {
  background-color: #a1c172;
  border: 1px solid #a1c172;
}

.container .radio:after {
  content: '';
  display: none;
  margin: 4px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #fff;
}

.container input:checked ~ .radio:after {
  display: block;
}

select {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  font: 13px/1 Ubuntu;
  padding: 2px 28px 2px 8px;
  height: 21px;
  margin-left: 3px;
  background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAAICAYAAAD0g6+qAAAAwklEQVQoU42QMQrCQBBFZxeGgJ7BI1jYa2GzTTY3sRUECy1yA0svEQhhEHIHLdRrqF2a5EuCkbgmmin/zLz5f5QxZsTMK2ZeR1F0p5ay1i7zPD+LiLT1S01Za7dEtCGiY5Zl8zRNH81h3/d3SqkFgFOSJJNOUBAEAwAHIpq6sAbkprWexXF86QSVjTaY53nhy8lfSBWtvuDAKhlAL8gHyHUGAFrr8a84zZhvR7VojBkyc1gUxV5Erl0/cfUvUN9Fd+4JA1JkCdbmVf8AAAAASUVORK5CYII=) 100% no-repeat #eee;
  /*
  let canvas = document.body.appendChild(document.createElement('canvas'))
  canvas.width = Math.ceil(8 * Math.sqrt(2)) + 6
  canvas.height = Math.ceil(5 * Math.sqrt(2))
  let ctx = canvas.getContext('2d')
  ctx.strokeStyle = '#4c4c4c'
  ctx.translate(4 * Math.sqrt(2), -3 * Math.sqrt(2))
  ctx.rotate(Math.PI * 0.25)
  ctx.lineCap = 'round'
  ctx.lineJoin = 'round'
  ctx.lineWidth = 2
  ctx.beginPath()
  ctx.moveTo(1, 7)
  ctx.lineTo(7, 7)
  ctx.lineTo(7, 1)
  ctx.stroke()
  copy(canvas.toDataURL())
  */
  border-radius: 4px;
  border: 1px solid #ccc;
}
select:hover {
  background-color: #ccc;
}
select:active {
  background-color: #eee;
}

.tooltip {
  position: relative;
  bottom: 1px;
  display: inline-block;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  text-align: center;
  background: rgb(0, 0, 0, 0.6);
  font: bold 10px/15px Ubuntu;
  color: #fff;
  margin: 0 4px;
}
.tooltip::before {
  content: '?';
}

.tooltip span {
  position: absolute;
  width: 160px;
  background-color: #444444;
  color: #fff;
  font: bold 11px Ubuntu;
  text-align: center;
  border-radius: 6px;
  padding: 5px 0;
  z-index: 1;
  margin-left: -80px;
  left: 50%;
  transition: opacity 200ms, bottom 200ms;
  pointer-events: none;
  opacity: 0;
  bottom: 200%;
}
.tooltip span::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  margin-left: -5px;
  border-width: 5px;
  border-style: solid;
  border-color: #444444 transparent transparent transparent;
}
.tooltip:hover span {
  pointer-events: unset;
  opacity: 1;
  bottom: 150%;
}

i {
  transition: transform 500ms;
}
i.arrow {
  border: solid #484848;
  border-width: 0 2px 2px 0;
  display: inline-block;
  padding: 3px;
}
i.reset {
  display: inline-block;
  width: 8px;
  height: 8px;
  border: #000 2px solid;
  border-right-color: transparent;
  border-radius: 50%;
  position: relative;
  top: 3px;
}
i.reset::after {
  content: '';
  display: inline-block;
  border: 3px solid;
  border-color: transparent #000 #000 transparent;
  position: relative;
  left: 3px;
  bottom: 8px;
}
i.cross {
  display: inline-block;
  width: 2px;
  height: 2px;
  margin: 0 5px -3px;
  padding: 6px;
}
i.cross.x {
  transform: rotate(135deg);
}
i.cross::before, i.cross::after {
  content: '';
  display: inline-block;
  background-color: #000;
  border-radius: 2px;
  float: left;
}
i.cross::before {
  width: 12px;
  height: 2px;
  margin-left: -5px;
}
i.cross::after {
  width: 2px;
  height: 12px;
  margin-top: -7px;
}
i.flag {
  display: inline-block;
  width: 2px;
  height: 12px;
  background: #000;
  margin: 0 15px 0 5px;
}
i.flag::before {
  content: '';
  display: inline-block;
  width: 9px;
  height: 7px;
  background-color: #000;
  margin: 0 0 5px 3px;
  transition: margin-bottom 500ms;
}
i.flag.down::before {
  margin-bottom: 2px;
}