@import url(http://weloveiconfonts.com/api/?family=brandico);
/* brandico */
[class*=brandico-]:before {
  font-family: "brandico", sans-serif;
}

* {
  box-sizing: border-box;
}

html, body {
  height: 100%;
}

body {
  background: black;
  min-height: 100%;
  font-family: "Arial", sans-serif;
  overflow: hidden;
}

.wrap {
  position: relative;
  height: 100%;
  min-height: 500px;
  padding-bottom: 20px;
}

.titre {
	height: 80px;
}

.logo {
	float: left;
	margin-top: 5px;
	margin-left: 30px;
}

h1 {
    font-family: "Open Sans", Helvetica, Arial, sans-serif;
	text-shadow: 2px 2px 3px #fff;
	color: #0099eb;
	font-size: 3.5em;
	margin-top: 20px;
	margin-left: calc((100vw - 205px)/2);
}

.difficulty {
	font-family: "Open Sans", Helvetica, Arial, sans-serif;;
	color: #0099eb;
	float: right;
	margin-right: 150px;
	margin-top: -22px;
}

.time {
    font-family: "Open Sans", Helvetica, Arial, sans-serif;;
	color: #0099eb;
	float: right;
	margin-right: 50px;
	margin-top: -22px;
}

#minutes, #seconds {
	float: left;
}

.return_screen {
	color: #0099eb;
	text-align: center;
	font-size: 3vw;
	margin-top: 12%;
}

.choix_theme, .choix_niveau {
    font-size: 18px;
    font-weight: 700;
    text-align: center;
	margin-top: 10%;
}

.choix_theme p,.choix_niveau p {
    font-size: 1.5em;
    margin-bottom: 20px;
	color: #66cc00;
}

.choix_theme ul, .choix_niveau ul {
    list-style: none;
}

.choix_theme ul li button, .choix_niveau ul li button {
    cursor: pointer;
    color: #0099eb;
	border: 0;
	background: 0 0;
	overflow: hidden;
	text-decoration: none;
	white-space: nowrap;
	margin-bottom: 20px;
	font-size: 1em;
	outline: none;
}

.choix_theme ul li button:hover, .choix_niveau ul li button:hover {
	color: #ff9800;
}

.game {
  transform-style: preserve-3d;
  perspective: 500px;
  min-height: 85%;
  height: 85%;
  margin: 0 auto;
}

.game.easy {
	width: 75%;
}

.game.middle, .game.difficult {
	width: 83%;
}

@-webkit-keyframes matchAnim {
  0% {
    background: #bcffcc;
  }
  100% {
    background: white;
  }
}

@keyframes matchAnim {
  0% {
    background: #bcffcc;
  }
  100% {
    background: white;
  }
}
.card.level1 {
  float: left;
  width: 25%;
  height: calc((100vw * 75/100 - 40px) * 300/(422 * 4) + 12px);
  padding: 5px;
  text-align: center;
  display: block;
  perspective: 500px;
  position: relative;
  cursor: pointer;
  z-index: 50;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}
.card.level2 {
  float: left;
  width: 16.66666%;
  height: calc((100vw * 83/100 - 60px) * 300/(422 * 6) + 12px);
  padding: 5px;
  text-align: center;
  display: block;
  perspective: 500px;
  position: relative;
  cursor: pointer;
  z-index: 50;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}
.card.level3 {
  float: left;
  width: 11.11111%;
  height: calc((100vw * 83/100 - 54px) * 300/(422 * 9) + 10px);
  padding: 5px;
  text-align: center;
  display: block;
  perspective: 500px;
  position: relative;
  cursor: pointer;
  z-index: 50;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}
@media (max-width: 800px) {
  .card.level1, .card.level2 {
    width: 25%;
    height: 16.66666%;
  }
  .card.level3 {
    width: 16.66666%;
    height: 11.11111%;
  }
}

.card .inside {
  width: 100%;
  height: 100%;
  display: block;
  transform-style: preserve-3d;
  transition: 0.4s ease-in-out;
  background: white;
}
.card .inside.picked, .card .inside.matched {
  transform: rotateY(180deg);
}
.card .inside.matched {
  -webkit-animation: 1s matchAnim ease-in-out;
          animation: 1s matchAnim ease-in-out;
  -webkit-animation-delay: 0.4s;
          animation-delay: 0.4s;
  cursor: default;
}
.card .front, .card .back {
  border: 1px solid black;
  -webkit-backface-visibility: hidden;
          backface-visibility: hidden;
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}
.card .front {
	padding: 5px;
}
.card .back {
	padding: 20px;
}
.card .front img, .card .back img {
  max-width: 100%;
  display: block;
  margin: 0 auto;
  max-height: 100%;
}
.card .front {
  transform: rotateY(-180deg);
}
.card .back {
  transform: rotateY(0);
}

@media (max-width: 800px) {
  .card .back {
    padding: 10px;
  }
}
.card.highlight {
	/*border: 1px solid gray;*/
    filter: brightness(400%);
    -webkit-filter: brightness(400%);
    -moz-filter: brightness(400%);
    -o-filter: brightness(400%);
    -ms-filter: brightness(400%);
    -webkit-transition: all 0.50s;
    transition: all 0.50s;
}
.name {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 16px;
  font-weight: bold;
}

.modal-overlay {
  display: none;
  background: rgba(0, 0, 0, 0.5);
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.modal {
  display: none;
  position: relative;
  width: 500px;
  height: 400px;
  max-height: 90%;
  max-width: 90%;
  min-height: 380px;
  margin: 0 auto;
  background: white;
  top: 50%;
  transform: translateY(-50%);
  padding: 30px 10px;
  border-radius: 10px;
  box-shadow: 10px 10px 5px #888;
}
.modal .winner {
  font-size: 80px;
  text-align: center;
  font-family: "Anton", sans-serif;
  color: #0099eb;
  text-shadow: 0px 3px 0 black;
}
.modal-difficulty {
	font-size: 20px;
	font-family: "Anton", sans-serif;
  	color: #ff9800;
	text-align: center;
	margin-bottom: 20px;
	margin-top: 50px;
}
.modal-time {
	font-size: 20px;
	font-family: "Anton", sans-serif;
  	color: #66cc00;
	text-align: center;
}
@media (max-width: 480px) {
  .modal .winner {
    font-size: 60px;
  }
}
.modal .restart {
  font-family: "Anton", sans-serif;
  margin: 30px auto;
  padding: 20px 30px;
  display: block;
  font-size: 30px;
  border: none;
  background: #4d4d4d;
  background: linear-gradient(#4d4d4d, #222);
  border: 1px solid #222;
  border-radius: 5px;
  color: white;
  text-shadow: 0px 1px 0 black;
  cursor: pointer;
}
.modal .restart:hover {
  background: linear-gradient(#222, black);
}
.modal .message {
  text-align: center;
}
.modal .message a {
  text-decoration: none;
  color: #28afe6;
  font-weight: bold;
}
.modal .message a:hover {
  color: #56c0eb;
  border-bottom: 1px dotted #56c0eb;
}
.modal .share-text {
  text-align: center;
  margin: 10px auto;
}
.modal .social {
  margin: 20px auto;
  text-align: center;
}
.modal .social li {
  display: inline-block;
  height: 50px;
  width: 50px;
  margin-right: 10px;
}
.modal .social li:last-child {
  margin-right: 0;
}
.modal .social li a {
  display: block;
  line-height: 50px;
  font-size: 20px;
  color: white;
  text-decoration: none;
  border-radius: 5px;
}
.modal .social li a.facebook {
  background: #3b5998;
}
.modal .social li a.facebook:hover {
  background: #4c70ba;
}
.modal .social li a.google {
  background: #D34836;
}
.modal .social li a.google:hover {
  background: #dc6e60;
}
.modal .social li a.twitter {
  background: #4099FF;
}
.modal .social li a.twitter:hover {
  background: #73b4ff;
}

footer {
  height: 20px;
  position: absolute;
  bottom: 0;
  width: 100%;
  z-index: 0;
}
footer .disclaimer {
  line-height: 20px;
  font-size: 12px;
  color: #727272;
  text-align: center;
}
@media (max-width: 767px) {
  footer .disclaimer {
    font-size: 8px;
  }
}

@media only screen and (max-width: 1500px) and (orientation: landscape) {
	.game.easy {
		width: 77%;
		margin-top: 2%;
	}
	
	.game.easy .card.level1 {
		height: calc((100vw * 77/100 - 40px) * 300/(422 * 4) + 12px);
	}
	
	.game.middle {
		width: 87%;
		margin-top: 2%;
	}
	
	.game.middle .card.level2 {
		height: calc((100vw * 87/100 - 60px) * 300/(422 * 6) + 12px);
	}
	
	.game.difficult {
		margin-top: 2%
	}
	
	.game.difficult .card.level3 {
		padding: 3px;
		height: calc((100vw * 83/100 - 54px) * 300/(422 * 9) + 8px);
	}
	
	.game.difficult .card.level3 .front {
		padding: 3px;
	}
}

@media only screen and (max-width: 1400px) and (orientation: landscape) {
	.game.easy {
		width: 70%;
	}
	
	.game.easy .card.level1 {
		height: calc((100vw * 70/100 - 40px) * 300/(422 * 4) + 12px);
	}
	
	.game.middle, .game.difficult {
		margin-top: 0;
	}
	
	.game.middle {
		width: 76%;
	}
	
	.game.middle .card.level2 {
		height: calc((100vw * 76/100 - 36px) * 300/(422 * 6) + 10px);
	}
	
	.game.difficult {
		width: 74%;
	}
	
	.game.difficult .card.level3 {
		padding: 3px;
		height: calc((100vw * 74/100 - 54px) * 300/(422 * 9) + 8px);
	}
	
	.game.difficult .card.level3 .front {
		padding: 3px;
	}
}

@media only screen and (max-width: 1280px) and (orientation: landscape) {
	.game.easy {
		width: 85%;
		margin-top: 2%;
	}
	
	.game.easy .card.level1 {
		height: calc((100vw * 85/100 - 40px) * 300/(422 * 4) + 12px);
	}
	
	.game.middle {
		margin-top: 4%;
	}
	
	.game.middle .card.level2 {
		height: calc((100vw * 87/100 - 60px) * 300/(422 * 6) + 12px);
	}
	
	.game.difficult {
		width: 95%;
	}
	
	.game.difficult .card.level3 {
		height: calc((100vw * 95/100) * 300/(422 * 9) + 4px);
	}
	
	.game.difficult .card.level3 .front {
		padding: 3px;
	}
}

@media only screen and (max-width: 1024px) and (orientation: landscape) {
	.game.easy {
		width: 90%;
		margin-top: 6%;
	}
	
	.game.easy .card.level1 {
		height: calc((100vw * 90/100 - 24px) * 300/(422 * 4) + 9px);
		padding: 3px;
	}
	
	.game.middle {
		width: 95%;
		margin-top: 7%;
	}
	
	.game.middle .card.level2 {
		height: calc((100vw * 95/100 - 54px) * 300/(422 * 6) + 11px);
		padding: 3px;
	}
	
	.game.difficult {
		margin-top: 6%;
	}
	
	.game.difficult .card.level3 {
		height: calc((100vw * 95/100 - 54px) * 300/(422 * 9) + 8px);
		padding: 3px;
	}
	
	.game.difficult .card.level3 .front {
		padding: 3px;
	}
	
	.game.difficult .card.level3 .front .name {
		font-size: 14px;
	}
}

@media only screen and (max-width: 915px) and (orientation: landscape) {
	.return_screen {
		display: block!important;
	}
	
	.choix_theme {
		display: none!important;
	}
}

@media only screen and (max-width: 800px) and (orientation: portrait) {
	.choix_theme, .choix_niveau {
		margin-top: 25%;
	}
	
	.game.easy {
		margin-top: 20%;
	}
	
	.game.easy .card.level1 {
		width: 33.33333%;
		height: calc((100vw * 83/100 - 30px) * 300/(422*3) + 2px);
	}
	
	.game.middle {
		width: 85%;
		margin-top: 20%;
	}
	
	.game.middle .card.level2 {
		width: 25%;
		height: calc((100vw * 85/100 - 40px) * 300/(422*4) + 12px);
	}
	
	.game.difficult {
		margin-top: 22%;
	}
	
	.game.difficult .card.level3 {
		height: calc((100vw * 83/100 - 36px) * 300/(422*6) + 8px);
		padding: 3px;
	}
	
	.game.difficult .card.level3 .front {
		padding: 3px;
	}
	
	.game.difficult .card.level3 .front .name {
		font-size: 14px;
	}
}

@media only screen and (max-width: 768px) and (orientation: portrait) {
	.difficulty {
		margin-right: 120px;
	}
	
	.game.easy {
		margin-top: 15%;
	}
	
	.game.easy .card.level1 {
		height: calc((100vw * 83/100 - 30px) * 300/(422*3) + 12px);
	}
	
	.game.middle {
		margin-top: 10%;
	}
	
	.game.middle .card.level2 {
		height: calc((100vw * 85/100 - 40px) * 300/(422*4) + 12px);
	}
	
	.game.difficult {
		margin-top: 10%;
	}
	
	.game.difficult .card.level3 {
		height: calc((100vw * 83/100 - 36px) * 300/(422*6) + 8px);
	}
}

@media only screen and (max-width: 740px) and (orientation: landscape) {
	.return_screen {
		display: block!important;
	}
	
	.choix_theme {
		display: none!important;
	}
	
	.choix_niveau {
		display: none!important;
	}
	
	.game {
		display: none!important;
	}
	
	.modal-overlay {
		display: none!important;
	}
}

@media only screen and (max-width: 736px) and (orientation: landscape) {
	.return_screen {
		display: block!important;
	}
	
	.choix_theme {
		display: none!important;
	}
	
	.choix_niveau {
		display: none!important;
	}
	
	.game {
		display: none!important;
	}
	
	.modal-overlay {
		display: none!important;
	}
}

@media only screen and (max-width: 667px) and (orientation: landscape) {
	.return_screen {
		display: block!important;
	}
	
	.choix_theme {
		display: none!important;
	}
	
	.choix_niveau {
		display: none!important;
	}
	
	.game {
		display: none!important;
	}
	
	.modal-overlay {
		display: none!important;
	}
}

@media only screen and (max-width: 640px) and (orientation: landscape) {
	.return_screen {
		display: block!important;
	}
	
	.choix_theme {
		display: none!important;
	}
	
	.choix_niveau {
		display: none!important;
	}
	
	.game {
		display: none!important;
	}
	
	.modal-overlay {
		display: none!important;
	}
}

@media only screen and (max-width: 480px) and (orientation: landscape) {
	.return_screen {
		display: block!important;
	}
	
	.choix_theme {
		display: none!important;
	}
	
	.choix_niveau {
		display: none!important;
	}
	
	.game {
		display: none!important;
	}
	
	.modal-overlay {
		display: none!important;
	}
}

@media only screen and (max-width: 414px) and (orientation: portrait) {
	.logo {
		margin-left: calc((100vw - 200px)/2);
	}
	
	.difficulty, .time {
		position: relative;
		top: 50px;
	}
	
	.time {
		margin-right: calc((100vw - 191px)/2);
	}
	
	.difficulty {
		margin-right: calc(90px + (100vw - 191px)/2);
	}
	
	.choix_theme, .choix_niveau {
		margin-top: 35%;
	}
	
	.game.easy {
		width: 90%;
		margin-top: 35%;
	}
	
	.game.easy .card.level1 {
		height: calc((100vw * 90/100) * 300/(3 * 422) + 3px);
		padding: 2px;
	}
	
	.game.middle {
		width: 90%;
		margin-top: 30%;
	}
	
	.game.middle .card.level2 {
		height: calc((100vw * 90/100) * 300/(4 * 422) + 3px);
		padding: 2px;
	}
	
	.game.middle .card.level2 .front .name {
		font-size: 14px;
	}
	
	.game.difficult {
		width: 90%;
		margin-top: 30%;
	}
	
	.game.difficult .card.level3 {
		height: calc((100vw * 90/100) * 300/(6 * 422) + 2px);
		padding: 1px;
	}
	
	.game.difficult .card.level3 .front .name {
		font-size: 12px;
		font-weight: normal;
	}
	
	.card .front, .card .back {
		padding: 2px!important;
	}
}

@media only screen and (max-width: 412px) and (orientation: portrait) {
	.logo {
		margin-left: calc((100vw - 200px)/2);
	}
	
	.difficulty, .time {
		position: relative;
		top: 50px;
	}
	
	.time {
		margin-right: calc((100vw - 191px)/2);
	}
	
	.difficulty {
		margin-right: calc(90px + (100vw - 191px)/2);
	}
	
	.choix_theme, .choix_niveau {
		margin-top: 35%;
	}
	
	.game.easy {
		width: 90%;
		margin-top: 35%;
	}
	
	.game.easy .card.level1 {
		height: calc((100vw * 90/100) * 300/(3 * 422) + 3px);
		padding: 2px;
	}
	
	.game.middle {
		width: 90%;
		margin-top: 35%;
	}
	
	.game.middle .card.level2 {
		height: calc((100vw * 90/100) * 300/(4 * 422) + 3px);
		padding: 2px;
	}
	
	.game.difficult {
		width: 90%;
		margin-top: 35%;
	}
	
	.game.difficult .card.level3 {
		height: calc((100vw * 90/100) * 300/(6 * 422) + 2px);
		padding: 1px;
	}
	
	.card .front, .card .back {
		padding: 2px!important;
	}
}

@media only screen and (max-width: 375px) and (orientation: portrait) {
	.game.easy {
		width: 95%;
	}
	
	.game.easy .card.level1 {
		height: calc((100vw * 95/100 - 16px) * 300/(3 * 422) + 2px);
		padding: 1px;
	}
	
	.game.easy .card.level1 .front .name {
		font-size: 14px;
	}
	
	.game.midle {
		width: 95%;
	}
	
	.game.middle .card.level2 {
		height: calc((100vw * 95/100) * 300/(4 * 422) - 1px);
		padding: 1px;
	}
	
	.game.middle .card.level2 .front .name {
		font-size: 13px;
	}
	
	.game.difficult {
		width: 95%;
	}
	
	.game.difficult .card.level3 {
		height: calc((100vw * 90/100) * 300/(6 * 422) + 4px);
		padding: 1px;
	}
	
	.game.difficult .card.level3 .front .name {
		font-size: 11px;
	}
	
	.modal {
		height: 350px;
		min-height: 350px;
	}
	
	.modal .winner {
		font-size: 50px;
	}
}

@media only screen and (max-width: 360px) and (orientation: portrait) {
	.logo {
		margin-left: calc((100vw - 200px)/2);
	}
	
	.difficulty, .time {
		position: relative;
		top: 35px;
	}
	
	.time {
		margin-right: calc((100vw - 191px)/2);
	}
	
	.difficulty {
		margin-right: calc(90px + (100vw - 191px)/2);
	}
	
	.choix_theme, .choix_niveau {
		margin-top: 22%;
	}
	
	.game.easy {
		width: 95%;
		margin-top: 22%;
	}
	
	.game.easy .card.level1 {
		height: calc((100vw * 95/100) * 300/(422 * 3) + 2px);
		padding: 2px;
	}
	
	.game.easy .card.level1 .front {
		padding: 2px;
	}
	
	.game.easy .card.level1 .front .name {
		font-size: 14px;
	}
	
	.game.middle {
		width: 95%;
		margin-top: 22%;
	}
	
	.game.middle .card.level2 {
		height: calc((100vw * 95/100) * 300/(422 * 4) + 2px);
		padding: 1px;
	}
	
	.game.middle .card.level2 .front {
		padding: 2px;
	}
	
	.game.middle .card.level2 .front .name {
		font-size: 13px;
	}
	
	.game.difficult {
		width: 95%;
		margin-top: 22%;
	}
	
	.game.difficult .card.level3 {
		height: calc((100vw * 95/100) * 300/(422 * 6) + 2px);
		padding: 1px;
	}
	
	.game.difficult .card.level3 .front {
		padding: 1px;
	}
	
	.game.difficult .card.level3 .front .name {
		font-size: 10px;
	}
}

@media only screen and (max-width: 320px) and (orientation: portrait) {
	.logo img {
		width: 150px;
	}
	
	.logo {
		margin-left: calc((100vw - 150px)/2);
	}
	
	h1 {
		font-size: 2em;
		margin-left: calc((100vw - 118px)/2);
	}
	
	.choix_theme, .choix_niveau {
		margin-top: 25%;
	}
	
	.choix_theme p, .choix_niveau p {
		font-size: 1em;
	}
	
	.choix_theme ul li button, .choix_niveau ul li button {
		font-size: 0.8em;
		margin-bottom: 15px;
	}
	
	.difficulty, .time {
		font-size: 0.8em;
		margin-top: -40px;
	}
	
	.time {
		margin-right: calc((100vw - 172px)/2);
	}
	
	.difficulty {
		margin-right: calc(90px + (100vw - 172px)/2);
	}
	
	.game.easy {
		margin-top: 9%;
	}
	
	.game.easy .card.level1 {
		height: calc((100vw * 95/100) * 300/(422 * 3) + 3px);
	}
	
	.game.middle {
		margin-top: 9%;
	}
	
	.game.middle .card.level2 {
		height: calc((100vw * 95/100) * 300/(422 * 4) + 2px);
	}
	
	.game.difficult {
		margin-top: 9%;
	}
	
	.game.difficult .card.level3 {
		height: calc((100vw * 95/100) * 300/(422 * 6) + 2px);
	}
	
	.game .card .front .name {
		display: none!important;
	}
	
	.modal .winner {
		font-size: 40px;
	}
	
	.modal .restart {
		font-size: 25px;
	}
}