/* http://meyerweb.com/eric/tools/css/reset/ 
   v2.0 | 20110126
   License: none (public domain)
*/
html,
body,
div,
span,
applet,
object,
iframe,
h1,
h2,
h3,
h4,
h5,
h6,
p,
blockquote,
pre,
a,
abbr,
acronym,
address,
big,
cite,
code,
del,
dfn,
em,
img,
ins,
kbd,
q,
s,
samp,
small,
strike,
strong,
sub,
sup,
tt,
var,
b,
u,
i,
center,
dl,
dt,
dd,
ol,
ul,
li,
fieldset,
form,
label,
legend,
table,
caption,
tbody,
tfoot,
thead,
tr,
th,
td,
article,
aside,
canvas,
details,
embed,
figure,
figcaption,
footer,
header,
hgroup,
menu,
nav,
output,
ruby,
section,
summary,
time,
mark,
audio,
video {
  margin: 0;
  padding: 0;
  border: 0;
  font-size: 100%;
  font: inherit;
  vertical-align: baseline;
}
/* HTML5 display-role reset for older browsers */
article,
aside,
details,
figcaption,
figure,
footer,
header,
hgroup,
menu,
nav,
section {
  display: block;
}
body {
  line-height: 1;
}
ol,
ul {
  list-style: none;
}
blockquote,
q {
  quotes: none;
}
blockquote:before,
blockquote:after,
q:before,
q:after {
  content: "";
  content: none;
}
table {
  border-collapse: collapse;
  border-spacing: 0;
}
@font-face {
  font-family: CutiveMono;
  font-weight: normal;
  src: url("./CutiveMono-Regular.ttf");
}
button {
  letter-spacing: inherit;
  word-spacing: inherit;
}
button,
details > summary {
  cursor: pointer;
}
b,
strong {
  font-weight: bolder;
}
i,
em {
  font-style: italic;
}
:root {
  background-color: #000;
  color: #fff;
  color-scheme: dark;
  font-family: CutiveMono;
  font-size: 16px;
  font-weight: normal;
}
a {
  text-decoration: none;
  color: #f33;
  transition: opacity 0.1s ease-out;
}
a:hover, a:focus {
  opacity: 0.7;
}
::selection {
  background: #fff;
  color: #000;
}
* {
  box-sizing: border-box;
  image-rendering: pixelated;
}
* {
  scrollbar-width: thin;
  scrollbar-color: rgba(128, 128, 128, 0.25) rgba(128, 128, 128, 0.1);
}
*::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
*::-webkit-scrollbar-track {
  background: rgba(128, 128, 128, 0.1);
}
*::-webkit-scrollbar-thumb {
  background-color: rgba(128, 128, 128, 0.52);
  border-radius: 2px;
  border: 1px solid rgba(128, 128, 128, 0.1);
}
*::-webkit-scrollbar-corner {
  background: rgba(128, 128, 128, 0.1);
}
body {
  background: black;
  height: 100vh;
  width: 100vw;
  overflow: hidden;
  user-select: none;
}
button {
  background: none;
  border: none;
  padding: 0;
  margin: 0;
  font: inherit;
}
[data-valid=false] {
  cursor: not-allowed;
}
[data-theme=default] button.deck:not([data-valid=false]):hover .card:last-child,
[data-theme=default] button.card:not([data-valid=false]):hover,
[data-theme=default] button.slot:not([data-valid=false]):hover .card:last-child {
  background-color: #CCC;
}
button.deck:not([data-valid=false]):hover .card:last-child:not(.selected),
button.card:not([data-valid=false]):hover:not(.selected),
button.slot:not([data-valid=false]):hover .card:last-child:not(.selected) {
  filter: brightness(0.9);
}
.card {
  font: initial;
  font-size: 18vmin;
  line-height: 18vmin;
  min-width: 12.5vmin;
  min-height: 18.5vmin;
  position: relative;
  width: min-content;
  height: min-content;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  vertical-align: middle;
  color: #000;
  overflow: hidden;
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  image-rendering: auto;
  transition: background-color 0.05s ease-out, filter 0.05s ease-out;
}
.card.hearts, .card.diamonds {
  color: #F00;
  border-color: #F00;
}
[data-theme=default] .card {
  background-color: white;
  border-radius: 1vmin;
  padding: 1px;
  border: solid 2px #000;
}
[data-theme=humor] body {
  background-image: linear-gradient(to top, rgb(16, 0, 0), rgba(0, 0, 0, 0));
}
[data-theme=humor] .card {
  font-size: 0;
  background-image: url("./humor back.png");
  min-height: 0;
  height: 17.3vmin;
  image-rendering: pixelated;
}
[data-theme=humor] .card[title="ace of hearts"] {
  background-image: url("./ace of blood.png");
}
[data-theme=humor] .card[title="two of hearts"] {
  background-image: url("./2 of blood.png");
}
[data-theme=humor] .card[title="three of hearts"] {
  background-image: url("./3 of blood.png");
}
[data-theme=humor] .card[title="four of hearts"] {
  background-image: url("./4 of blood.png");
}
[data-theme=humor] .card[title="five of hearts"] {
  background-image: url("./5 of blood.png");
}
[data-theme=humor] .card[title="six of hearts"] {
  background-image: url("./6 of blood.png");
}
[data-theme=humor] .card[title="seven of hearts"] {
  background-image: url("./7 of blood.png");
}
[data-theme=humor] .card[title="eight of hearts"] {
  background-image: url("./8 of blood.png");
}
[data-theme=humor] .card[title="nine of hearts"] {
  background-image: url("./9 of blood.png");
}
[data-theme=humor] .card[title="ten of hearts"] {
  background-image: url("./10 of blood.png");
}
[data-theme=humor] .card[title="jack of hearts"] {
  background-image: url("./11 of blood.png");
}
[data-theme=humor] .card[title="queen of hearts"] {
  background-image: url("./12 of blood.png");
}
[data-theme=humor] .card[title="king of hearts"] {
  background-image: url("./13 of blood.png");
}
[data-theme=humor] .card[title="ace of diamonds"] {
  background-image: url("./ace of phlegm.png");
}
[data-theme=humor] .card[title="two of diamonds"] {
  background-image: url("./2 of phlegm.png");
}
[data-theme=humor] .card[title="three of diamonds"] {
  background-image: url("./3 of phlegm.png");
}
[data-theme=humor] .card[title="four of diamonds"] {
  background-image: url("./4 of phlegm.png");
}
[data-theme=humor] .card[title="five of diamonds"] {
  background-image: url("./5 of phlegm.png");
}
[data-theme=humor] .card[title="six of diamonds"] {
  background-image: url("./6 of phlegm.png");
}
[data-theme=humor] .card[title="seven of diamonds"] {
  background-image: url("./7 of phlegm.png");
}
[data-theme=humor] .card[title="eight of diamonds"] {
  background-image: url("./8 of phlegm.png");
}
[data-theme=humor] .card[title="nine of diamonds"] {
  background-image: url("./9 of phlegm.png");
}
[data-theme=humor] .card[title="ten of diamonds"] {
  background-image: url("./10 of phlegm.png");
}
[data-theme=humor] .card[title="jack of diamonds"] {
  background-image: url("./11 of phlegm.png");
}
[data-theme=humor] .card[title="queen of diamonds"] {
  background-image: url("./12 of phlegm.png");
}
[data-theme=humor] .card[title="king of diamonds"] {
  background-image: url("./13 of phlegm.png");
}
[data-theme=humor] .card[title="ace of clubs"] {
  background-image: url("./ace of yellow bile.png");
}
[data-theme=humor] .card[title="two of clubs"] {
  background-image: url("./2 of yellow bile.png");
}
[data-theme=humor] .card[title="three of clubs"] {
  background-image: url("./3 of yellow bile.png");
}
[data-theme=humor] .card[title="four of clubs"] {
  background-image: url("./4 of yellow bile.png");
}
[data-theme=humor] .card[title="five of clubs"] {
  background-image: url("./5 of yellow bile.png");
}
[data-theme=humor] .card[title="six of clubs"] {
  background-image: url("./6 of yellow bile.png");
}
[data-theme=humor] .card[title="seven of clubs"] {
  background-image: url("./7 of yellow bile.png");
}
[data-theme=humor] .card[title="eight of clubs"] {
  background-image: url("./8 of yellow bile.png");
}
[data-theme=humor] .card[title="nine of clubs"] {
  background-image: url("./9 of yellow bile.png");
}
[data-theme=humor] .card[title="ten of clubs"] {
  background-image: url("./10 of yellow bile.png");
}
[data-theme=humor] .card[title="jack of clubs"] {
  background-image: url("./11 of yellow bile.png");
}
[data-theme=humor] .card[title="queen of clubs"] {
  background-image: url("./12 of yellow bile.png");
}
[data-theme=humor] .card[title="king of clubs"] {
  background-image: url("./13 of yellow bile.png");
}
[data-theme=humor] .card[title="ace of spades"] {
  background-image: url("./ace of black bile.png");
}
[data-theme=humor] .card[title="two of spades"] {
  background-image: url("./2 of black bile.png");
}
[data-theme=humor] .card[title="three of spades"] {
  background-image: url("./3 of black bile.png");
}
[data-theme=humor] .card[title="four of spades"] {
  background-image: url("./4 of black bile.png");
}
[data-theme=humor] .card[title="five of spades"] {
  background-image: url("./5 of black bile.png");
}
[data-theme=humor] .card[title="six of spades"] {
  background-image: url("./6 of black bile.png");
}
[data-theme=humor] .card[title="seven of spades"] {
  background-image: url("./7 of black bile.png");
}
[data-theme=humor] .card[title="eight of spades"] {
  background-image: url("./8 of black bile.png");
}
[data-theme=humor] .card[title="nine of spades"] {
  background-image: url("./9 of black bile.png");
}
[data-theme=humor] .card[title="ten of spades"] {
  background-image: url("./10 of black bile.png");
}
[data-theme=humor] .card[title="jack of spades"] {
  background-image: url("./11 of black bile.png");
}
[data-theme=humor] .card[title="queen of spades"] {
  background-image: url("./12 of black bile.png");
}
[data-theme=humor] .card[title="king of spades"] {
  background-image: url("./13 of black bile.png");
}
[data-theme=humor] .card[title="da joka"] {
  background-image: url("./angel.png");
}
[data-theme=humor] .card[title="the fool"] {
  background-image: url("./hedgehog.png");
}
[data-theme=humor] .slot {
  height: 17.3vmin;
  border: none;
  background-image: url("./humor slot.png");
}
[data-theme=win] body {
  background-color: #008200;
}
[data-theme=win] .card {
  font-size: 0;
  background-image: url("./castle.png");
  min-height: 0;
  height: 16.8vmin;
}
[data-theme=win] .card[title="ace of hearts"] {
  background-image: url("./ace of hearts.png");
}
[data-theme=win] .card[title="two of hearts"] {
  background-image: url("./2 of hearts.png");
}
[data-theme=win] .card[title="three of hearts"] {
  background-image: url("./3 of hearts.png");
}
[data-theme=win] .card[title="four of hearts"] {
  background-image: url("./4 of hearts.png");
}
[data-theme=win] .card[title="five of hearts"] {
  background-image: url("./5 of hearts.png");
}
[data-theme=win] .card[title="six of hearts"] {
  background-image: url("./6 of hearts.png");
}
[data-theme=win] .card[title="seven of hearts"] {
  background-image: url("./7 of hearts.png");
}
[data-theme=win] .card[title="eight of hearts"] {
  background-image: url("./8 of hearts.png");
}
[data-theme=win] .card[title="nine of hearts"] {
  background-image: url("./9 of hearts.png");
}
[data-theme=win] .card[title="ten of hearts"] {
  background-image: url("./10 of hearts.png");
}
[data-theme=win] .card[title="jack of hearts"] {
  background-image: url("./11 of hearts.png");
}
[data-theme=win] .card[title="queen of hearts"] {
  background-image: url("./12 of hearts.png");
}
[data-theme=win] .card[title="king of hearts"] {
  background-image: url("./13 of hearts.png");
}
[data-theme=win] .card[title="da joka"] {
  background-image: url("./hand.png");
}
[data-theme=win] .card[title="the fool"] {
  background-image: url("./beach.png");
}
[data-theme=win] .card[title="ace of diamonds"] {
  background-image: url("./ace of diamonds.png");
}
[data-theme=win] .card[title="two of diamonds"] {
  background-image: url("./2 of diamonds.png");
}
[data-theme=win] .card[title="three of diamonds"] {
  background-image: url("./3 of diamonds.png");
}
[data-theme=win] .card[title="four of diamonds"] {
  background-image: url("./4 of diamonds.png");
}
[data-theme=win] .card[title="five of diamonds"] {
  background-image: url("./5 of diamonds.png");
}
[data-theme=win] .card[title="six of diamonds"] {
  background-image: url("./6 of diamonds.png");
}
[data-theme=win] .card[title="seven of diamonds"] {
  background-image: url("./7 of diamonds.png");
}
[data-theme=win] .card[title="eight of diamonds"] {
  background-image: url("./8 of diamonds.png");
}
[data-theme=win] .card[title="nine of diamonds"] {
  background-image: url("./9 of diamonds.png");
}
[data-theme=win] .card[title="ten of diamonds"] {
  background-image: url("./10 of diamonds.png");
}
[data-theme=win] .card[title="jack of diamonds"] {
  background-image: url("./11 of diamonds.png");
}
[data-theme=win] .card[title="queen of diamonds"] {
  background-image: url("./12 of diamonds.png");
}
[data-theme=win] .card[title="king of diamonds"] {
  background-image: url("./13 of diamonds.png");
}
[data-theme=win] .card[title="da joka"] {
  background-image: url("./hand.png");
}
[data-theme=win] .card[title="the fool"] {
  background-image: url("./beach.png");
}
[data-theme=win] .card[title="ace of clubs"] {
  background-image: url("./ace of clubs.png");
}
[data-theme=win] .card[title="two of clubs"] {
  background-image: url("./2 of clubs.png");
}
[data-theme=win] .card[title="three of clubs"] {
  background-image: url("./3 of clubs.png");
}
[data-theme=win] .card[title="four of clubs"] {
  background-image: url("./4 of clubs.png");
}
[data-theme=win] .card[title="five of clubs"] {
  background-image: url("./5 of clubs.png");
}
[data-theme=win] .card[title="six of clubs"] {
  background-image: url("./6 of clubs.png");
}
[data-theme=win] .card[title="seven of clubs"] {
  background-image: url("./7 of clubs.png");
}
[data-theme=win] .card[title="eight of clubs"] {
  background-image: url("./8 of clubs.png");
}
[data-theme=win] .card[title="nine of clubs"] {
  background-image: url("./9 of clubs.png");
}
[data-theme=win] .card[title="ten of clubs"] {
  background-image: url("./10 of clubs.png");
}
[data-theme=win] .card[title="jack of clubs"] {
  background-image: url("./11 of clubs.png");
}
[data-theme=win] .card[title="queen of clubs"] {
  background-image: url("./12 of clubs.png");
}
[data-theme=win] .card[title="king of clubs"] {
  background-image: url("./13 of clubs.png");
}
[data-theme=win] .card[title="da joka"] {
  background-image: url("./hand.png");
}
[data-theme=win] .card[title="the fool"] {
  background-image: url("./beach.png");
}
[data-theme=win] .card[title="ace of spades"] {
  background-image: url("./ace of spades.png");
}
[data-theme=win] .card[title="two of spades"] {
  background-image: url("./2 of spades.png");
}
[data-theme=win] .card[title="three of spades"] {
  background-image: url("./3 of spades.png");
}
[data-theme=win] .card[title="four of spades"] {
  background-image: url("./4 of spades.png");
}
[data-theme=win] .card[title="five of spades"] {
  background-image: url("./5 of spades.png");
}
[data-theme=win] .card[title="six of spades"] {
  background-image: url("./6 of spades.png");
}
[data-theme=win] .card[title="seven of spades"] {
  background-image: url("./7 of spades.png");
}
[data-theme=win] .card[title="eight of spades"] {
  background-image: url("./8 of spades.png");
}
[data-theme=win] .card[title="nine of spades"] {
  background-image: url("./9 of spades.png");
}
[data-theme=win] .card[title="ten of spades"] {
  background-image: url("./10 of spades.png");
}
[data-theme=win] .card[title="jack of spades"] {
  background-image: url("./11 of spades.png");
}
[data-theme=win] .card[title="queen of spades"] {
  background-image: url("./12 of spades.png");
}
[data-theme=win] .card[title="king of spades"] {
  background-image: url("./13 of spades.png");
}
[data-theme=win] .card[title="da joka"] {
  background-image: url("./hand.png");
}
[data-theme=win] .card[title="the fool"] {
  background-image: url("./beach.png");
}
[data-theme=win] .slot {
  height: 16.8vmin;
  border: none;
  background-image: url("./win slot.png");
}
[data-theme=pirate] body {
  background-image: url("./pirate bg.png");
  background-position: center;
}
[data-theme=pirate] .card {
  font-size: 0;
  background-image: url("./pirate back.png");
  min-height: 0;
  height: 17vmin;
}
[data-theme=pirate] .card[title="ace of hearts"] {
  background-image: url("./ace of grog.png");
}
[data-theme=pirate] .card[title="two of hearts"] {
  background-image: url("./2 of grog.png");
}
[data-theme=pirate] .card[title="three of hearts"] {
  background-image: url("./3 of grog.png");
}
[data-theme=pirate] .card[title="four of hearts"] {
  background-image: url("./4 of grog.png");
}
[data-theme=pirate] .card[title="five of hearts"] {
  background-image: url("./5 of grog.png");
}
[data-theme=pirate] .card[title="six of hearts"] {
  background-image: url("./6 of grog.png");
}
[data-theme=pirate] .card[title="seven of hearts"] {
  background-image: url("./7 of grog.png");
}
[data-theme=pirate] .card[title="eight of hearts"] {
  background-image: url("./8 of grog.png");
}
[data-theme=pirate] .card[title="nine of hearts"] {
  background-image: url("./9 of grog.png");
}
[data-theme=pirate] .card[title="ten of hearts"] {
  background-image: url("./10 of grog.png");
}
[data-theme=pirate] .card[title="jack of hearts"] {
  background-image: url("./11 of grog.png");
}
[data-theme=pirate] .card[title="queen of hearts"] {
  background-image: url("./12 of grog.png");
}
[data-theme=pirate] .card[title="king of hearts"] {
  background-image: url("./13 of grog.png");
}
[data-theme=pirate] .card[title="da joka"] {
  background-image: url("./pirate joker.png");
}
[data-theme=pirate] .card[title="the fool"] {
  background-image: url("./pirate x.png");
}
[data-theme=pirate] .card[title="ace of diamonds"] {
  background-image: url("./ace of coins.png");
}
[data-theme=pirate] .card[title="two of diamonds"] {
  background-image: url("./2 of coins.png");
}
[data-theme=pirate] .card[title="three of diamonds"] {
  background-image: url("./3 of coins.png");
}
[data-theme=pirate] .card[title="four of diamonds"] {
  background-image: url("./4 of coins.png");
}
[data-theme=pirate] .card[title="five of diamonds"] {
  background-image: url("./5 of coins.png");
}
[data-theme=pirate] .card[title="six of diamonds"] {
  background-image: url("./6 of coins.png");
}
[data-theme=pirate] .card[title="seven of diamonds"] {
  background-image: url("./7 of coins.png");
}
[data-theme=pirate] .card[title="eight of diamonds"] {
  background-image: url("./8 of coins.png");
}
[data-theme=pirate] .card[title="nine of diamonds"] {
  background-image: url("./9 of coins.png");
}
[data-theme=pirate] .card[title="ten of diamonds"] {
  background-image: url("./10 of coins.png");
}
[data-theme=pirate] .card[title="jack of diamonds"] {
  background-image: url("./11 of coins.png");
}
[data-theme=pirate] .card[title="queen of diamonds"] {
  background-image: url("./12 of coins.png");
}
[data-theme=pirate] .card[title="king of diamonds"] {
  background-image: url("./13 of coins.png");
}
[data-theme=pirate] .card[title="da joka"] {
  background-image: url("./pirate joker.png");
}
[data-theme=pirate] .card[title="the fool"] {
  background-image: url("./pirate x.png");
}
[data-theme=pirate] .card[title="ace of clubs"] {
  background-image: url("./ace of pistols.png");
}
[data-theme=pirate] .card[title="two of clubs"] {
  background-image: url("./2 of pistols.png");
}
[data-theme=pirate] .card[title="three of clubs"] {
  background-image: url("./3 of pistols.png");
}
[data-theme=pirate] .card[title="four of clubs"] {
  background-image: url("./4 of pistols.png");
}
[data-theme=pirate] .card[title="five of clubs"] {
  background-image: url("./5 of pistols.png");
}
[data-theme=pirate] .card[title="six of clubs"] {
  background-image: url("./6 of pistols.png");
}
[data-theme=pirate] .card[title="seven of clubs"] {
  background-image: url("./7 of pistols.png");
}
[data-theme=pirate] .card[title="eight of clubs"] {
  background-image: url("./8 of pistols.png");
}
[data-theme=pirate] .card[title="nine of clubs"] {
  background-image: url("./9 of pistols.png");
}
[data-theme=pirate] .card[title="ten of clubs"] {
  background-image: url("./10 of pistols.png");
}
[data-theme=pirate] .card[title="jack of clubs"] {
  background-image: url("./11 of pistols.png");
}
[data-theme=pirate] .card[title="queen of clubs"] {
  background-image: url("./12 of pistols.png");
}
[data-theme=pirate] .card[title="king of clubs"] {
  background-image: url("./13 of pistols.png");
}
[data-theme=pirate] .card[title="da joka"] {
  background-image: url("./pirate joker.png");
}
[data-theme=pirate] .card[title="the fool"] {
  background-image: url("./pirate x.png");
}
[data-theme=pirate] .card[title="ace of spades"] {
  background-image: url("./ace of skulls.png");
}
[data-theme=pirate] .card[title="two of spades"] {
  background-image: url("./2 of skulls.png");
}
[data-theme=pirate] .card[title="three of spades"] {
  background-image: url("./3 of skulls.png");
}
[data-theme=pirate] .card[title="four of spades"] {
  background-image: url("./4 of skulls.png");
}
[data-theme=pirate] .card[title="five of spades"] {
  background-image: url("./5 of skulls.png");
}
[data-theme=pirate] .card[title="six of spades"] {
  background-image: url("./6 of skulls.png");
}
[data-theme=pirate] .card[title="seven of spades"] {
  background-image: url("./7 of skulls.png");
}
[data-theme=pirate] .card[title="eight of spades"] {
  background-image: url("./8 of skulls.png");
}
[data-theme=pirate] .card[title="nine of spades"] {
  background-image: url("./9 of skulls.png");
}
[data-theme=pirate] .card[title="ten of spades"] {
  background-image: url("./10 of skulls.png");
}
[data-theme=pirate] .card[title="jack of spades"] {
  background-image: url("./11 of skulls.png");
}
[data-theme=pirate] .card[title="queen of spades"] {
  background-image: url("./12 of skulls.png");
}
[data-theme=pirate] .card[title="king of spades"] {
  background-image: url("./13 of skulls.png");
}
[data-theme=pirate] .card[title="da joka"] {
  background-image: url("./pirate joker.png");
}
[data-theme=pirate] .card[title="the fool"] {
  background-image: url("./pirate x.png");
}
[data-theme=pirate] .slot {
  height: 17.5vmin;
}
.selected {
  filter: invert(1);
}
.board {
  position: absolute;
  inset: 5vmin;
  width: 90vmin;
  height: 90vmin;
  margin: auto;
  display: grid;
  grid-template-areas: "c  .. su .. .." ".. .. du .. .." "sl dl dm dr sr" ".. .. dd .. .." ".. .. sd .. ..";
  justify-content: center;
  align-items: center;
  justify-items: center;
  grid-auto-columns: 0;
  grid-auto-rows: 0;
  gap: 22.5vmin;
  transform-style: preserve-3d;
}
#message {
  grid-area: dm;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  width: 20vmin;
  height: 20vmin;
  white-space: pre-line;
  font-size: 3vmin;
  letter-spacing: -0.1em;
  gap: 0.5rem;
}
#message input {
  font: inherit;
  width: 3.5em;
  text-transform: uppercase;
  text-align: center;
}
#message button {
  display: block;
  padding: 0.25rem;
  border-radius: 0.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border: dotted 1px #FFF;
}
#message button:hover {
  background-color: #333;
}
#message button:active {
  background-color: #FFF;
  color: #000;
}
#deck_m {
  grid-area: dm;
}
#deck_m .card {
  position: absolute;
  inset: 0;
  margin: auto;
  border-width: 0;
}
#deck_m .card:nth-child(0) {
  bottom: 0vmin;
}
#deck_m .card:nth-child(1) {
  bottom: 0.06vmin;
}
#deck_m .card:nth-child(2) {
  bottom: 0.12vmin;
}
#deck_m .card:nth-child(3) {
  bottom: 0.18vmin;
}
#deck_m .card:nth-child(4) {
  bottom: 0.24vmin;
}
#deck_m .card:nth-child(5) {
  bottom: 0.3vmin;
}
#deck_m .card:nth-child(6) {
  bottom: 0.36vmin;
}
#deck_m .card:nth-child(7) {
  bottom: 0.42vmin;
}
#deck_m .card:nth-child(8) {
  bottom: 0.48vmin;
}
#deck_m .card:nth-child(9) {
  bottom: 0.54vmin;
}
#deck_m .card:nth-child(10) {
  bottom: 0.6vmin;
}
#deck_m .card:nth-child(11) {
  bottom: 0.66vmin;
}
#deck_m .card:nth-child(12) {
  bottom: 0.72vmin;
}
#deck_m .card:nth-child(13) {
  bottom: 0.78vmin;
}
#deck_m .card:nth-child(14) {
  bottom: 0.84vmin;
}
#deck_m .card:nth-child(15) {
  bottom: 0.9vmin;
}
#deck_m .card:nth-child(16) {
  bottom: 0.96vmin;
}
#deck_m .card:nth-child(17) {
  bottom: 1.02vmin;
}
#deck_m .card:nth-child(18) {
  bottom: 1.08vmin;
}
#deck_m .card:nth-child(19) {
  bottom: 1.14vmin;
}
#deck_m .card:nth-child(20) {
  bottom: 1.2vmin;
}
#deck_m .card:nth-child(21) {
  bottom: 1.26vmin;
}
#deck_m .card:nth-child(22) {
  bottom: 1.32vmin;
}
#deck_m .card:nth-child(23) {
  bottom: 1.38vmin;
}
#deck_m .card:nth-child(24) {
  bottom: 1.44vmin;
}
#deck_m .card:nth-child(25) {
  bottom: 1.5vmin;
}
#deck_m .card:nth-child(26) {
  bottom: 1.56vmin;
}
#deck_m .card:nth-child(27) {
  bottom: 1.62vmin;
}
#deck_m .card:nth-child(28) {
  bottom: 1.68vmin;
}
#deck_m .card:nth-child(29) {
  bottom: 1.74vmin;
}
#deck_m .card:nth-child(30) {
  bottom: 1.8vmin;
}
#deck_m .card:nth-child(31) {
  bottom: 1.86vmin;
}
#deck_m .card:nth-child(32) {
  bottom: 1.92vmin;
}
#deck_m .card:nth-child(33) {
  bottom: 1.98vmin;
}
#deck_m .card:nth-child(34) {
  bottom: 2.04vmin;
}
#deck_m .card:nth-child(35) {
  bottom: 2.1vmin;
}
#deck_m .card:nth-child(36) {
  bottom: 2.16vmin;
}
#deck_m .card:nth-child(37) {
  bottom: 2.22vmin;
}
#deck_m .card:nth-child(38) {
  bottom: 2.28vmin;
}
#deck_m .card:nth-child(39) {
  bottom: 2.34vmin;
}
#deck_m .card:nth-child(40) {
  bottom: 2.4vmin;
}
#deck_m .card:nth-child(41) {
  bottom: 2.46vmin;
}
#deck_m .card:nth-child(42) {
  bottom: 2.52vmin;
}
#deck_m .card:nth-child(43) {
  bottom: 2.58vmin;
}
#deck_m .card:nth-child(44) {
  bottom: 2.64vmin;
}
#deck_m .card:nth-child(45) {
  bottom: 2.7vmin;
}
#deck_m .card:nth-child(46) {
  bottom: 2.76vmin;
}
#deck_m .card:nth-child(47) {
  bottom: 2.82vmin;
}
#deck_m .card:nth-child(48) {
  bottom: 2.88vmin;
}
#deck_m .card:nth-child(49) {
  bottom: 2.94vmin;
}
#deck_m .card:nth-child(50) {
  bottom: 3vmin;
}
#deck_m .card:nth-child(51) {
  bottom: 3.06vmin;
}
#deck_m .card:nth-child(52) {
  bottom: 3.12vmin;
}
#deck_m .card:nth-child(53) {
  bottom: 3.18vmin;
}
#deck_m .card:nth-child(54) {
  bottom: 3.24vmin;
}
.slot {
  width: 13vmin;
  height: 19.5vmin;
  border: dotted 2px white;
  background: none;
  border-radius: 1vmin;
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  image-rendering: auto;
}
.slot .card {
  pointer-events: none;
}
#deck_u,
#deck_r,
#deck_l,
#deck_d {
  white-space: nowrap;
  flex-direction: column;
  text-align: center;
}
#deck_u .card:not(:first-child),
#deck_r .card:not(:first-child),
#deck_l .card:not(:first-child),
#deck_d .card:not(:first-child) {
  margin-left: -9.5vmin;
}
#deck_u,
#dslot_u {
  grid-area: du;
  transform: rotate(180deg) rotateY(0.1deg) translateZ(1vmin);
}
#deck_r,
#dslot_r {
  grid-area: dr;
  transform: rotate(270deg) rotateY(0.1deg) translateZ(1vmin);
}
#deck_d,
#dslot_d {
  grid-area: dd;
  transform: rotateY(0.1deg) translateZ(1vmin);
}
#deck_l,
#dslot_l {
  grid-area: dl;
  transform: rotate(90deg) rotateY(0.1deg) translateZ(1vmin);
}
.deck + .slot[data-valid=false] {
  display: none;
}
#slot_u {
  grid-area: su;
}
#slot_r {
  grid-area: sr;
  transform: rotate(270deg);
}
#slot_d {
  grid-area: sd;
}
#slot_l {
  grid-area: sl;
  transform: rotate(90deg);
}
@keyframes rotate_u {
  from {
    transform: rotate(-90deg) translateY(-15%);
  }
  to {
    transform: rotate(0deg) translateY(-15%);
  }
}
#deck_m[data-next=u] .card {
  animation: rotate_u 0.2s cubic-bezier(0.05, 2.03, 0.68, 0.72) both;
}
@keyframes rotate_r {
  from {
    transform: rotate(0deg) translateY(-15%);
  }
  to {
    transform: rotate(90deg) translateY(-15%);
  }
}
#deck_m[data-next=r] .card {
  animation: rotate_r 0.2s cubic-bezier(0.05, 2.03, 0.68, 0.72) both;
}
@keyframes rotate_d {
  from {
    transform: rotate(90deg) translateY(-15%);
  }
  to {
    transform: rotate(180deg) translateY(-15%);
  }
}
#deck_m[data-next=d] .card {
  animation: rotate_d 0.2s cubic-bezier(0.05, 2.03, 0.68, 0.72) both;
}
@keyframes rotate_l {
  from {
    transform: rotate(180deg) translateY(-15%);
  }
  to {
    transform: rotate(270deg) translateY(-15%);
  }
}
#deck_m[data-next=l] .card {
  animation: rotate_l 0.2s cubic-bezier(0.05, 2.03, 0.68, 0.72) both;
}
@keyframes toast {
  to {
    transform: translateY(-2em);
    opacity: 0;
  }
}
#card {
  text-align: left;
  font-size: 2.5vmin;
  grid-area: c;
  pointer-events: none;
}
#score {
  font-size: 2.5vmin;
  position: absolute;
  bottom: 0;
  right: 0;
  pointer-events: none;
  width: 100%;
  text-align: right;
}
#score .toast {
  position: absolute;
  bottom: 1em;
  right: 0;
  animation: toast 1.5s ease-out forwards;
}
menu {
  padding: 0;
  margin: 0;
  display: flex;
  list-style: none;
  position: absolute;
  top: 0;
  right: 0;
}
menu > li > button {
  font-size: 125%;
  width: 2rem;
  height: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border: dotted 1px #FFF;
  border-right: none;
  border-top: none;
}
menu > li > button:hover {
  background-color: #333;
}
menu > li > button:active {
  background-color: #FFF;
  color: #000;
}
@media screen and (pointer: coarse) {
  menu > li > button {
    min-width: 44px;
    min-height: 44px;
  }
}
menu > li:first-child > button {
  border-bottom-left-radius: 0.25rem;
}
.modal {
  position: absolute;
  inset: 0;
}
.modal[hidden] {
  display: none;
}
.modal::before {
  content: "";
  background-color: #000;
  opacity: 0.5;
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.modal .box {
  position: absolute;
  inset: 0;
  width: 80%;
  height: 65%;
  background-color: #000;
  border: dotted 1px #fff;
  margin: auto;
  border-radius: 0.25rem;
  letter-spacing: -0.1em;
  font-size: 110%;
  user-select: initial;
}
@media screen and (min-width: 720px) {
  .modal .box {
    width: 50%;
  }
}
.modal .box .content {
  padding: 1rem;
  overflow: auto;
  max-height: 100%;
}
.modal .box .close {
  background-color: #000;
  position: absolute;
  top: 0;
  right: 0;
  font-size: 125%;
  font-family: inherit;
  width: 2rem;
  height: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border: dotted 1px #FFF;
  border-right: none;
  border-top: none;
  border-bottom-left-radius: 0.25rem;
}
.modal .box .close:hover {
  background-color: #333;
}
.modal .box .close:active {
  background-color: #FFF;
  color: #000;
}
.modal h1 {
  font-size: 150%;
  margin-bottom: 0.5rem;
  font-weight: bold;
}
.modal h2 {
  font-size: 125%;
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
  font-weight: bold;
}
.modal ul {
  list-style: "* ";
  margin-inline-start: 1rem;
  margin-bottom: 0.5rem;
}
.modal input {
  border: dotted 1px #fff;
  background: none;
  padding: 0.1rem;
  font: inherit;
  max-width: 100%;
}
.modal sub {
  display: block;
  margin-top: 0.5rem;
}
.modal .radio {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.5em;
  margin-bottom: 0.5rem;
}
@media screen and (pointer: coarse) {
  .modal .radio input {
    min-width: 44px;
    min-height: 44px;
  }
}
#scores {
  text-align: center;
}
#close .box {
  display: flex;
  align-items: center;
  justify-content: center;
}
#close .content {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 1rem;
}
#close .buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  justify-content: center;
}
#close button {
  font-size: 125%;
  font-family: inherit;
  width: 10rem;
  height: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border: dotted 1px #FFF;
  border-radius: 0.1rem;
}
#close button:hover {
  background-color: #333;
}
#close button:active {
  background-color: #FFF;
  color: #000;
}