:root {
  --title-font: "Permanent Marker", cursive;
  --regular-font: "Architects Daughter", cursive;
}

html,
body {
  min-height: 100vh;
  padding: 0;
  margin: 0;
}

body {
  background: #000;
  color: #fff;
  font-family: var(--regular-font);
  overflow: hidden;
  display: flex;
}

#main-page {
  min-width: 100%;
  min-height: 100%;
  display: flex;
  flex-direction: column;
}

#main-content {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}



/*
 Stats
*/

.stats {
  display: flex;
}

.stats-song-card,
.card {
  background-color: rgba(100, 100, 100, 0.2);
  border-radius: 8px;
  flex: 1;
  margin: 10px;
  position: relative;
  min-height: 200px;
}

.card-title {
  text-transform: uppercase;
  font-weight: bold;
  font-family: var(--title-font);
  font-size: 1.2em;
}

/*
	Stats card
*/

.card {
  display: flex;
}

.card .card-title {
  position: absolute;
  left: 20px;
  top: 10px;
}

.card .card-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: center;
  font-size: 4em;
  margin: auto;
  height: 100%;
}

/*	
	Stats song card
*/

.stats-song-card .stats-content {
  display: flex;
  padding: 40px 20px;
  flex: 1;
}

.stats-song-card .stats-content_left {
  width: 30%;
  padding-top: 30%;
  background: transparent;
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center;
  margin: auto;
}

.stats-song-card .stats-content_right {
  flex: 1;
  padding: 10px 20px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: center;
  font-size: 2.2em;
}

.stats-song-card .stats-artist {
  font-family: var(--title-font);
}

.top-charts {
  display: flex;
  flex-grow: 1;
}

.top-chart-content {
  padding: 50px 20px;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-auto-rows: 1fr;
  grid-column-gap: 30px;
  grid-row-gap: 30px;
  flex: 1;
  justify-content: space-around;
}

.top-chart-row {
  display: flex;
  position: relative;
}

.top-chart-row_left {
  width: 30%;
  padding-top: 30%;
  background: url("/assets/img/dance.gif");
  background-repeat: no-repeat;
  background-size: contain;
  background-position: center;
  margin: auto;
}



.top-chart-row_right {
  flex: 1;
  padding: 10px;
  display: flex;
}

.top-chart-row_right>* {
  margin: auto;
  font-size: 1.5em;
  text-align: center;
}

.top-chart-value .artist,
#top-artists .top-chart-value {
  font-family: var(--title-font);
}

.top-chart-value .artist {
  display: block;
}

body.page-current .stats-song-card {
  height: calc(100vh - 20px);
  display: flex;
  justify-content: center;
}

body.page-current .card-title {
  position: absolute;
}

body.page-current .stats-song-card .stats-content_left {
  width: 30%;
  padding-top: 30%;
  margin-bottom: 20px;
}

body.page-current .stats-song-card .stats-content_right {
  flex-direction: column;
  vertical-align: middle;
  justify-content: center;
  text-align: center;
  flex: unset;
  font-size: 3em;
}

body.page-current .stats-song-card .stats-content {
  flex-direction: column;
  justify-content: center;
}

body.page-current .stats-content>div {
  margin: 0 auto;
}

.top-charts_left {
  flex: 1;
  display: flex;
}

.top-charts_right {
  flex: 1;
}

.top-charts_left,
.top-charts_right {
  position: relative;
}

.top-charts_left>div,
.top-charts_right>div {
  min-height: 100%;
}

#latest-tracks .top-chart-content {
  grid-template-columns: repeat(3, 1fr);
}

body.page-index #latest-tracks .top-chart-content {
  grid-template-columns: repeat(2, 1fr);
}

body.page-index #top-artists .top-chart-row:nth-child(n + 5),
body.page-index #top-tracks .top-chart-row:nth-child(n + 5),
body.page-index #latest-tracks .top-chart-row:nth-child(n + 7) {
  display: none;
}

body.page-index .top-charts_left .top-chart-content {
  display: flex;
  flex-direction: column;
}

body.page-current .stats-song-card .stats-content_left.hide {
  padding-top: 0;
}

.stats-song-card .stats-content_left.hide {
  width: 0px;
}

footer {
  margin-top: 20px;
  text-align: center;
}

footer a {
  color: white;
  text-decoration: none;
}

body.disco {
  background: linear-gradient(45deg, rgba(255, 0, 89, 1) 0%, rgba(0, 179, 255, 1) 33%, rgba(255, 0, 89, 1) 66%, rgba(0, 179, 255, 1) 100%);
  background-size: 400% 400%;
  height: 100vh;
  animation: disco 1.5s linear infinite;
}

@-webkit-keyframes disco {
  0% {
    background-position: 100% 0%;
  }

  100% {
    background-position: 15% 100%;
  }
}

@-moz-keyframes disco {
  0% {
    background-position: 100% 0%;
  }

  100% {
    background-position: 15% 100%;
  }
}

@keyframes disco {
  0% {
    background-position: 100% 0%;
  }

  100% {
    background-position: 15% 100%;
  }
}

@media only screen and (max-width: 1200px) {

  .stats,
  .top-charts {
    flex-direction: column;
  }

  body.page-current .stats-song-card .stats-content_left {
    width: 50%;
    padding-top: 50%;
  }

  #latest-tracks .top-chart-content {
    grid-template-columns: repeat(2, 1fr);
  }

  body.page-index .top-chart-content {
    grid-template-columns: repeat(1, 1fr);
  }

  body.page-index .top-chart-row {
    display: unset !important;
  }
}

@media only screen and (max-width: 767px) {

  .top-charts_left,
  .stats-song-card .stats-content {
    flex-direction: column;
  }

  .top-chart-content {
    display: flex;
    flex-direction: column;
  }

  body.page-current .stats-song-card .stats-content_left {
    width: 65%;
    padding-top: 65%;
  }
}