:root {
    --background-color: #FFF;
    --text-color: #555;
    --link-color: #2A8CB7;
    --link--visited-color: #8F00F5;
}

html[data-theme='light'] {
    --background-color: #FFF;
    --text-color: #555;
    --text-hover-color: #646464;
    --link-color: #2A8CB7;
    --link--visited-color: #8F00F5;
   
}

html[data-theme='dark'] {
    --background-color: #1C1B22;
    --text-color: #F7F8F8;
    --text-hover-color: rgb(194, 194, 194);
    --link-color: #69BADD;
    --link--visited-color: #BB5CFF;
}

#theme-toggle {
    position: absolute;
    left: 0;
    top: 0;
    font-size: 1.5em;
    padding: 6px;
    border: none;
    background-color: transparent;
    z-index: 10;

}

[data-theme='light'] #theme-toggle {
    filter: contrast(70%) brightness(120%) opacity(40%);
}

[data-theme='dark'] #theme-toggle {
    filter: contrast(70%) brightness(130%) opacity(40%);
}

[data-theme='light'] #theme-toggle:hover {
    filter: none;
    cursor: pointer;
}

[data-theme='light'] #theme-toggle:active {
    font-size: 1.45em;
}

[data-theme='dark'] #theme-toggle:hover {
    filter: none;
    cursor: pointer;
}

[data-theme='dark'] #theme-toggle:active {
    font-size: 1.45em;
}

[data-theme='light'] #theme-toggle::after {
    content: "\1F31E";
}

[data-theme='dark'] #theme-toggle::after {
    content: "\1F319";
}
body {
    margin: 0 auto;
    max-width: 50em;
    line-height: 1.5;
    padding: 4em 1em;
    color: var(--text-color);
    background: var(--background-color);
    font-family: "Helvetica", "Arial", sans-serif;
}

h2 {
    margin-top: 1em;
    padding-top: 1em;
}

label {
    padding-left: 10px;
}

a {
    color: var(--link-color);
}

a:visited {
    color: var(--link--visited-color);
}
:root {
    --background-color: #FFF;
    --text-color: #555;
    --link-color: #2A8CB7;
    --link--visited-color: #8F00F5;
}

html[data-theme='light'] {
    --background-color: #FFF;
    --text-color: #555;
    --text-hover-color: #646464;
    --link-color: #2A8CB7;
    --link--visited-color: #8F00F5;
   
}

html[data-theme='dark'] {
    --background-color: #1C1B22;
    --text-color: #F7F8F8;
    --text-hover-color: rgb(194, 194, 194);
    --link-color: #69BADD;
    --link--visited-color: #BB5CFF;
}

#theme-toggle {
    position: absolute;
    left: 0;
    top: 0;
    font-size: 1.5em;
    padding: 6px;
    border: none;
    background-color: transparent;
    z-index: 10;

}

[data-theme='light'] #theme-toggle {
    filter: contrast(70%) brightness(120%) opacity(40%);
}

[data-theme='dark'] #theme-toggle {
    filter: contrast(70%) brightness(130%) opacity(40%);
}

[data-theme='light'] #theme-toggle:hover {
    filter: none;
    cursor: pointer;
}

[data-theme='light'] #theme-toggle:active {
    font-size: 1.45em;
}

[data-theme='dark'] #theme-toggle:hover {
    filter: none;
    cursor: pointer;
}

[data-theme='dark'] #theme-toggle:active {
    font-size: 1.45em;
}

[data-theme='light'] #theme-toggle::after {
    content: "\1F31E";
}

[data-theme='dark'] #theme-toggle::after {
    content: "\1F319";
}
body {
    margin: 0 auto;
    max-width: 50em;
    line-height: 1.5;
    padding: 4em 1em;
    color: var(--text-color);
    background: var(--background-color);
    font-family: "Helvetica", "Arial", sans-serif;
}

h2 {
    margin-top: 1em;
    padding-top: 1em;
}

label {
    padding-left: 10px;
}

a {
    color: var(--link-color);
}

a:visited {
    color: var(--link--visited-color);
}
.main-menu-button {
  background-color: unset;
  border: none;
  cursor: pointer;
}

.main-menu {
  position: relative;
  display: inline-block;
}

h1 {
    color: var(--text-color);
    font-family: "Helvetica", "Arial", sans-serif;
}

h1:hover {
    color: var(--text-hover-color);
}
.main-menu-content {
  display: none;
  position: absolute;
  background-color: #f9f9f9;
  min-width: 160px;
  box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
  z-index: 1;
}

.main-menu-content a {
  color: black;
  padding: 12px 16px;
  text-decoration: none;
  display: block;
}

.main-menu-content a:hover {background-color: #f1f1f1}

.main-menu:hover .main-menu-content {
  display: block;
}


.firework-container {
    position: fixed;
    top:0;
    left:0;

    width: 100%;
    height: 100%;
}

.firework {
	position: absolute;
    --firework-color: #f5cf52;
}
.explosion {
	position: absolute;
	left: -2px;
	bottom: 0;
	width: 4px;
	height: 80px;
	transform-origin: 50% 100%;
	overflow: hidden;
}
.explosion:nth-child(1) {
	transform: rotate(0deg) translateY(-15px);
}
.explosion:nth-child(2) {
	transform: rotate(30deg) translateY(-15px);
}
.explosion:nth-child(3) {
	transform: rotate(60deg) translateY(-15px);
}
.explosion:nth-child(4) {
	transform: rotate(90deg) translateY(-15px);
}
.explosion:nth-child(5) {
	transform: rotate(120deg) translateY(-15px);
}
.explosion:nth-child(6) {
	transform: rotate(150deg) translateY(-15px);
}
.explosion:nth-child(7) {
	transform: rotate(180deg) translateY(-15px);
}
.explosion:nth-child(8) {
	transform: rotate(210deg) translateY(-15px);
}
.explosion:nth-child(9) {
	transform: rotate(240deg) translateY(-15px);
}
.explosion:nth-child(10) {
	transform: rotate(270deg) translateY(-15px);
}
.explosion:nth-child(11) {
	transform: rotate(300deg) translateY(-15px);
}
.explosion:nth-child(12) {
	transform: rotate(330deg) translateY(-15px);
}

.explosion::before {
	content: '';
	position: absolute;
	left: 0;
	right: 0;
	top: 100%;
	height: 40px;
	background-color: var(--firework-color);
}
@keyframes explosion {
	0% {
		top: 100%;
	}
	33%, 100% {
		top: -50%;
	}
}

#firework-play {
	transform: scale(1);
}
#firework-play .explosion::before {
	animation: explosion 2s ease-in-out;
}

.text-scroller-container {
    position: absolute;
    top:4rem;
    left:0;
	height: 2px;
    width: 100%;
    /* height: 100%; */
}

@media (min-width: 1100px) {
	.text-scroller-container {
		top:-3rem;
	}
}

.text-scroller {
	text-align: center;
	font-size: 2rem;
    --text-scroller-color: #f5cf52;
	color: var(--text-scroller-color);
	opacity: 0;
}

.scroll-play {
	animation-fill-mode: forwards;
	animation: fadedown 0.6s linear;
}

@media (min-width: 1100px) {
	.scroll-play {
		animation: fadeup 0.6s linear;
	}
}


.no-transition {
	animation: none !important;
  }


@keyframes fadeup
{
	0% {transform: translateY(0); opacity: 0;}
	30% { transform: translateY(-30px); opacity: 1;}
	70% { transform: translateY(-70px); opacity: 1;}
	100% { transform: translateY(-100px); opacity: 0;}
}

@keyframes fadedown
{
	0% {transform: translateY(0); opacity: 0;}
	30% { transform: translateY(30px); opacity: 1;}
	70% { transform: translateY(70px); opacity: 1;}
	100% { transform: translateY(100px); opacity: 0;}
}

.emoji-scroller-container {
    position: absolute;
    top:4rem;
    left:0;
	height: 2px;
    width: 100%;
}

.emoji-scroller-container>p {
	opacity: 0;
	font-size: 2rem;
	height: 2px;
	position: absolute;
}
@media (min-width: 1100px) {
	.emoji-scroller-container {
		top:-3rem;
	}
}


.emoji-scroll-play {
	animation-fill-mode: forwards;
	animation: fadedown 0.6s linear;
}

@media (min-width: 1100px) {
	.emoji-scroll-play {
		animation: fadeup 0.6s linear;
	}
}
.score {
    font-size: 3em;
    font-weight: bold;
}

.counter {
    margin-top: 5px;
    font-size: 2em;
    padding-left: 1.5em;
  }
  
@media (min-width: 1100px) {
    .counter {
        padding-left: 0;
    }
}
body {
  touch-action: none;
}

html,
body {
  height: 100%;
  width: 100vw;
  padding: 0px;
  overflow: hidden;
}

#root {
  padding: 0px;
  overflow: hidden;
}

html[data-theme='light'] {
  --background-color: #c6e4ef;
  --hover-color: #FF9551;
  --panel-color: rgba(198, 228, 239, 0.6);
  --selected-color: rgba(198, 228, 239, 0.8);
}

html[data-theme='dark'] {
  --background-color: #263440;
  --hover-color: #C16E70;
  --panel-color: rgba(38, 52, 64, 0.6);
  --selected-color: rgba(38, 52, 64, 0.8);
}


.main-menu {
  text-align: center;
  pointer-events: all;
  position: absolute;
  left: calc(50% - 60px);
  width: 120px;
  z-index: 100;
}

h1 {
  text-align: center;
  line-height: 1;
  margin: 0rem;
  margin-top: 15px;
  font-size: 1.2rem;
}

.quiz-container {
  user-select: none;
  -webkit-user-select: none;
  pointer-events: none;
  position: absolute;
  left: 0;
  right: 0;
  height: 100%;
  width: 100%;
  display: flex;
  flex-direction: column;
  flex-wrap: nowrap;
}

@media (min-width: 1100px) {
  .quiz-container {
    height: unset;
    width: unset;
    position: absolute;
    min-width: 300px;
    box-shadow: rgba(17, 17, 26, 0.05) 0px 4px 16px, rgba(17, 17, 26, 0.05) 0px 8px 32px;
    background-color: var(--panel-color);
    left: 0;
    right: unset;
    top: unset;
    bottom: 0;
    margin: 2em;
    padding: 1em;
 }
}

.top-container {
  pointer-events: auto;
  flex-shrink: 0;
  padding: 1rem;
  padding-top: 0;
  padding-bottom: 0;
}

.bottom-container {
  pointer-events: auto;
  flex-shrink: 0;
  padding: 1rem;
  padding-bottom: 1rem;
  padding-top: 0;
}
@media (min-width: 1100px) {
  .bottom-container {
    padding-bottom: 0rem;
  }
}
.map-spacer {
  pointer-events: none;
  flex-grow: 1;
  overflow: auto;
}

.game-options {
  background-color: var(--background-color);
}

.time-score {
  display: flex;
  justify-content: space-between;
}


.bottom-container button {
  margin-top: 10px;
  width: 100%;
  font-size: 1.3em;
}

@media (min-width: 1100px) {
  .bottom-container button {
    width: 100%;
    height: 2rem;
    font-size: unset;
    margin-bottom: unset;
  }
}

.guess {
  display: flex;
  justify-content: stretch;
  align-items: center;
}

.guess label {
  margin: 0;
  padding: 0px;
  padding-right: 4px;
}

.guess input {
  height: 2em;
  width: 100%;
  font-size: 1rem;
}

.hint {
  margin-top: 2px;
  text-align: center;
  min-height: 1.5rem;
}


.hint .hint-button {
  position: relative;
  color:rgba(0, 0, 0, 0);
}
.hint .hint-button>button {
  position: absolute;
  left:0;
  right: 0;
  width: 100%;
  min-width: 3rem;
}

.map-container {
  position: absolute;
  overflow: hidden;
  left: 0;
  right: 0;
  top: 0;
  bottom: 0;
  display: flex;
  height: 100%;
  width: 100%;
}

svg {
  pointer-events: auto;
  margin-top: 1.8rem;
}

svg:not(:root) {
  width: 100%;
  height: auto;
}

.cixx {
  opacity: 1;
  fill: var(--text-color);
  stroke: #000000;
  stroke-width: 0.8;
}

/*
  * Smaller circles around subnational territories: Australian external territories, 
  * Chinese SARs, Dutch special municipalities, and French DOMs (overseas regions/departments) 
  * [but not French COMs (overseas collectivities)]
  *
  * Change opacity to 1 to display all circles
  */
.subxx {
  opacity: 1;
  fill: var(--text-color);
  stroke: #000000;
  stroke-width: 0.5;
}


/*
  * Land
  * (all land, as opposed to water, should belong to this class; 
  * in order to modify the coastline for land pieces with no borders 
  * on them a special class "coastxx" has been added below)
  */
.lxx {
  fill: var(--text-color);
  stroke: var(--background-color);
  stroke-width: 0.5;
  fill-rule: evenodd;
}

.lxx:hover,
.cixx:hover {
  fill: var(--hover-color) !important;
}


/*
  * Styles for coastlines of islands and continents with no borders on them
  * (all of them should also belong to the class "landxx" - to allow for all 
  * land to be modified at once by refining "landxx" style's definition further down)
  */
.cxx {
  stroke-width: 0.5;
}


/*
  * Styles for territories without permanent population (the largest of which is Antarctica)
  *
  * Change opacity to 0 to hide all territories
  */
.antxx {
  opacity: 1;
  fill: var(--text-color);
}

/*
  * Circles around small countries without permanent population
  *
  * Change opacity to 1 to display all circles
  */
.noxx {
  opacity: 1;
  fill: var(--text-color);
  stroke: #000000;
  stroke-width: 0.5;
}


/*
  * Styles for territories with limited or no recognition
  * (all of them - including Taiwan - are overlays (i.e. duplicate layers) 
  * over their "host" countries, and so not showing them doesn't leave any gaps on the map)
  *
  * Change opacity to 1 to display all territories
  */
.limitxx {
  opacity: 1;
  fill: var(--text-color);
  stroke: #ffffff;
  stroke-width: 0.2;
  fill-rule: evenodd;
}

/*
  * Smaller circles around small territories with limited or no recognition
  *
  * Change opacity to 1 to display all circles
  */
.unxx {
  opacity: 1;
  fill: var(--text-color);
  stroke: #000000;
  stroke-width: 0.3;
}

.hide {
  opacity: 0.2;
}

fieldset {
  border: 1px solid var(--text-color);
}

.enter-tooltip {
  background-color: var(--hover-color);
  color: var(--text-color);
  position: absolute;
  right: 9px;
  border-radius: 4px;
  font-size: 0.6em;
  padding: 0.55em;
  padding-left: 8px;
  border: 1px solid var(--text-color);
}

.enter-tooltip-arrow {
  height: 8px;
  width: 8px;
  background-color: var(--hover-color);
  position: absolute;
  left: 0;
  top: 50%;

  /* Border */
  border-bottom: 1px solid var(--text-color);
  border-left: 1px solid var(--text-color);
  transform: translate(-50%, -50%) rotate(45deg);
}

@media (min-width: 1100px) {
  .enter-tooltip {
    right: -35px;
  }
}

/* Wobble Horizontal */
@-webkit-keyframes hvr-wobble-horizontal {
  16.65% {
    -webkit-transform: translateX(8px);
    transform: translateX(8px);
  }

  33.3% {
    -webkit-transform: translateX(-6px);
    transform: translateX(-6px);
  }

  49.95% {
    -webkit-transform: translateX(4px);
    transform: translateX(4px);
  }

  66.6% {
    -webkit-transform: translateX(-2px);
    transform: translateX(-2px);
  }

  83.25% {
    -webkit-transform: translateX(1px);
    transform: translateX(1px);
  }

  100% {
    -webkit-transform: translateX(0);
    transform: translateX(0);
  }
}

@keyframes hvr-wobble-horizontal {
  16.65% {
    -webkit-transform: translateX(8px);
    transform: translateX(8px);
  }

  33.3% {
    -webkit-transform: translateX(-6px);
    transform: translateX(-6px);
  }

  49.95% {
    -webkit-transform: translateX(4px);
    transform: translateX(4px);
  }

  66.6% {
    -webkit-transform: translateX(-2px);
    transform: translateX(-2px);
  }

  83.25% {
    -webkit-transform: translateX(1px);
    transform: translateX(1px);
  }

  100% {
    -webkit-transform: translateX(0);
    transform: translateX(0);
  }
}

.hvr-wobble-horizontal {
  display: inline-block;
  vertical-align: middle;
  -webkit-transform: perspective(1px) translateZ(0);
  transform: perspective(1px) translateZ(0);
  box-shadow: 0 0 1px rgba(0, 0, 0, 0);
}

.hvr-wobble-horizontal,
.hvr-wobble-horizontal,
.hvr-wobble-horizontal {
  -webkit-animation-name: hvr-wobble-horizontal;
  animation-name: hvr-wobble-horizontal;
  animation-delay: 1s;
  -webkit-animation-delay: 1s;
  -webkit-animation-duration: 1.5s;
  animation-duration: 1.5s;
  -webkit-animation-timing-function: ease-in-out;
  animation-timing-function: ease-in-out;
  -webkit-animation-iteration-count: infinite;
  animation-iteration-count: infinite;
}

.winner-text {
  pointer-events: none;
  font-size: 6em;
  position: absolute;
  text-align: center;
  left: 0;
  right: 0;
  top: 40%;
  color: var(--text-color);
}



.results-container {
  /* user-select: none;
  -webkit-user-select: none;
  pointer-events: none; */
  position: absolute;
  display: flex;
  left: 0;
  right: 0;
  top: 3.7rem;
  bottom: 8rem;
  width: 100%;
  flex-direction: column;
  flex-wrap: nowrap;
  align-items: stretch;
  text-align: center;
  font-size: 1.5rem;
  background-color: var(--panel-color);
}

.results-container .minimize-button {
  align-self: flex-end;
  justify-self: right;

}
.results-container button {
  font-size: 1.4rem;
  padding: 5px 15px;
  margin: 5px 2rem;
}

.results-container.minimized {
  /* box-shadow: unset; */
  left: unset;
  bottom: unset;
  min-width: unset;
  background-color: unset;
}

@media (min-width: 1100px) {
  .results-container {
    height: unset;
    width: unset;
    position: absolute;
    min-width: 300px;
    text-align: left;
    /* max-height: 500px; */
    box-shadow: rgba(17, 17, 26, 0.05) 0px 4px 16px, rgba(17, 17, 26, 0.05) 0px 8px 32px;
    left: unset;
    right: 0;
    top: 0;
    bottom: 0;
    margin: 2em;
    padding: 1em;
    background-color: var(--panel-color);
  }
  .results-container button {
    margin: 5px 0px;
  }
}

.results-container>ul {
  overflow-y: auto;
  list-style: none;
  margin: 0;
  margin-top: 5px;
  padding-left: 0;
}

.results-container li.selected {
  background-color: var(--selected-color);
  color: var(--hover-color);
}

.results-container li {
  padding: 0.6rem;
  font-size: 1rem;
}

.results-container h2 {
  font-size: 1.6rem;
  margin: 0;
}
.selected-in-map {
  fill: var(--hover-color);
}

#world-map {
  overflow: hidden;
  transform-origin: 0 0
}

.hello {
  --color-primary: #f6aca2;
  --color-secondary: #f49b90;
  --color-tertiary: #f28b7d;
  --color-quaternary: #f07a6a;
  --color-quinary: #ee6352;

  text-shadow: 3px 3px 0 var(--color-secondary), 6px 6px 0 var(--color-tertiary),
    9px 9px var(--color-quaternary), 12px 12px 0 var(--color-quinary);
  font-family: bungee, sans-serif;
  font-weight: 1000;
  text-transform: uppercase;
  font-size: calc(2rem + 5vw);
  text-align: center;
  margin: 0;
  color: var(--color-primary);
  animation: shadows 1.2s ease-in infinite, move 1.2s ease-in infinite;
  letter-spacing: 0.4rem;
}

@keyframes shadows {
  0% {
    text-shadow: none;
  }
  10% {
    text-shadow: 3px 3px 0 var(--color-secondary);
  }
  20% {
    text-shadow: 3px 3px 0 var(--color-secondary),
      6px 6px 0 var(--color-tertiary);
  }
  30% {
    text-shadow: 3px 3px 0 var(--color-secondary),
      6px 6px 0 var(--color-tertiary), 9px 9px var(--color-quaternary);
  }
  40% {
    text-shadow: 3px 3px 0 var(--color-secondary),
      6px 6px 0 var(--color-tertiary), 9px 9px var(--color-quaternary),
      12px 12px 0 var(--color-quinary);
  }
  50% {
    text-shadow: 3px 3px 0 var(--color-secondary),
      6px 6px 0 var(--color-tertiary), 9px 9px var(--color-quaternary),
      12px 12px 0 var(--color-quinary);
  }
  60% {
    text-shadow: 3px 3px 0 var(--color-secondary),
      6px 6px 0 var(--color-tertiary), 9px 9px var(--color-quaternary),
      12px 12px 0 var(--color-quinary);
  }
  70% {
    text-shadow: 3px 3px 0 var(--color-secondary),
      6px 6px 0 var(--color-tertiary), 9px 9px var(--color-quaternary);
  }
  80% {
    text-shadow: 3px 3px 0 var(--color-secondary),
      6px 6px 0 var(--color-tertiary);
  }
  90% {
    text-shadow: 3px 3px 0 var(--color-secondary);
  }
  100% {
    text-shadow: none;
  }
}

@keyframes move {
  0% {
    transform: translate(0px, 0px);
  }
  40% {
    transform: translate(-12px, -12px);
  }
  50% {
    transform: translate(-12px, -12px);
  }
  60% {
    transform: translate(-12px, -12px);
  }
  100% {
    transform: translate(0px, 0px);
  }
}
