@import url('https://fonts.googleapis.com/css2?family=Roboto+Mono&display=swap');

:root {
    --size: min(max(30vw, 40vh), 90vw);
    --border-size: 1vw;
    --aspect: 1; /* decimal, aspect ratio of image */
    --theme-light: #7FE5FF;
    --theme-normal: #00C8FF;
    --theme-dark: #00A0CD;
    --cell-padding: max(0.8vw, 1.2vh);
}

body {
    overscroll-behavior-y: contain;
}

.noselect {
    -webkit-touch-callout: none; /* iOS Safari */
      -webkit-user-select: none; /* Safari */
       -khtml-user-select: none; /* Konqueror HTML */
         -moz-user-select: none; /* Firefox */
          -ms-user-select: none; /* Internet Explorer/Edge */
              user-select: none; /* Non-prefixed version, currently
                                    supported by Chrome and Opera */
  }

html, body {
    margin: 0;
    padding: 0;
    background-color: var(--theme-light);
}

h1 {
    margin-top: 0;
}

* {
    font-family: "Roboto Mono", monospace;
}

#tile-container-outer-outer {
    position: relative;
}

#tile-container-outer {
    background-color: var(--theme-normal);
    padding-top: var(--cell-padding);
    padding-left: var(--cell-padding);
    border-radius: var(--cell-padding);
    border: var(--border-size) solid var(--theme-dark);
    width: var(--size);
    clip-path: polygon(100% 25%, calc(100% - var(--border-size)) 25%, calc(100% - var(--border-size)) 75%, 100% 75%, 100% 100%, 0 100%, 0 0, 100% 0);
}

#tile-container {
    position: relative;
    width: var(--size);
    image-rendering: pixelated;
    height: calc(var(--size) / var(--aspect));
}

.tile.player {
    background-image: url("codermuffin1024x1024.png");
    background-size: 50% 50%;
    background-repeat: no-repeat;
    background-position: center center;
}

.tile {
    position: absolute;
    transition: 200ms;
    opacity: 0;
    background-color: var(--theme-dark);
    border-radius: var(--cell-padding);
}

#win-container {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: #000C;
    z-index: 100;
    transition: opacity 200ms;
}

#container, #win-container {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100vw;
    height: 100vh;
}
