@charset "utf-8";

@import url(https://fonts.googleapis.com/css?family=Lora:400,700|Roboto:400,700,100);

body, select {
  font-family: 'Roboto';
  font-size: 1.1em;
}

h1, h2, h3, h4 {
  font-family: 'Lora';
}

* {
  box-sizing: border-box;
}

/* =============================================================================
    General Styles
  =========================================================================== */

html, body {
  padding: 0;
  margin: 0
}

#page {
  min-width: 320px;
  max-width: 1500px;
  padding: 0 20px 10px 60px;
}

a {
  color: #2020ff;
  transition: all 200ms ease-out;
}

a:hover {
  color: #ff0000;
}

.align-center {
  text-align: center;
}

.padded {
  padding: 10px;
}

.warning {
  color: #c11b17;
  font-weight: bold;
  font-size: 65%;
}

button, select {
  font-size: 1.0em;
  padding: 4px;
}

button {
  border: 1px solid gray;
  background-color: #fff;
}

/* =============================================================================
    Header
  =========================================================================== */

.movie-count {
  font-family: monospace;
  font-size: 1.3em;
}

.order-ratings {
  text-align: right;
  padding: 20px 0;
  margin: -60px 0 40px 0;
  border-bottom: 2px solid #e0e0e0;
}

.order-field-container {
  display: inline-block;
  padding: 4px 0;
}


/* =============================================================================
    Cards
  =========================================================================== */

.moviecards-container {
  padding: 0 20px 40px 20px;
}

.moviecard {
  position: relative;
  width: 100%;
  max-width: 100%;
  padding: 0 40px;

  transition: all 200ms ease-out;
}
.moviecard:nth-child(2n) {
  background-color: #E5E4E2;
}

.moviecard.open {
  padding: 0 40px 40px 40px;
  margin: 0 0 20px 0;
  box-shadow: 0px 10px 22px -1px rgba(69,69,69,0.2);
  background-color: #fff;
}

.moviecard.highlight {
  background-color: #FFFFD1;
  border: 1px solid #FFFF3A;
}

.moviecard-content {
  height: 0;
  overflow: hidden;
  opacity: 0;
  transition: all 300ms ease-out;
}
.moviecard.open > .moviecard-content {
  height: auto;
  opacity: 1.0;
}

.movie-title {
  padding: 30px 110px 30px 0;
  margin: 0;
  font-size: 1.3em;
  font-weight: normal;
  cursor: pointer;
  color: #2020ff;
  transition: all 200ms ease-out;
}
.movie-title:hover {
  color: #ff0000;
}

.moviecard.open .movie-title {
  border-bottom: 1px solid #ccc;
  padding-bottom: 50px;
}
.moviecard.open .movie-title  > .expand::after {
  content: '-';
}
.movie-title > .expand::after {
  display: inline-block;
  content: '+';
}

.movie-title > .movie-subtitle {
  color: #666;
  font-size: 0.8em;
}

.movie-title a,
.movie-title a:visited {
  text-decoration: none;
}

.movie-rating {
  position: absolute;
  right: 20px;
  top: 18px;
  width: 50px;
  height: 50px;
  background-size: contain;
  background-repeat: no-repeat;
  transition: all 200ms ease-out;
}
.moviecard.open .movie-rating {
  top: 4px;
  width: 100px;
  height: 100px;
}

.movie-facts {
  float: right;
  right: 0;
  width: 226px;
  margin-top: 26px;
  list-style-type: none;
}

.movie-facts > li {
  font-size: 0.8em;
  padding: 4px 0;
}
.movie-facts > li > label {
  font-weight: bold;
}

.top-link {
  padding-top: 10px;
  display: block;
  text-align: right;
}

/* =============================================================================
    Rating Legend
  =========================================================================== */

.rating-legend {
  position: fixed;
  top: 30%;
  width: 500px;
  right: -500px;
  background-color: #fff;
  z-index: 9999;
}

.rating-legend > .handle {
  display: block;
  position: absolute;
  left: -40px;
  width: 40px;
  height: 84px;
  background-color: white;
  font-size: 70px;
  text-align: center;
  box-shadow: 10px 10px 13px -8px rgba(0,0,0,0.49);
  color: #fff;
  text-decoration: none;
  background-color: rgba(30, 30, 30, 0.8);
}


/* -----------------------------------------------------------------------------
    Legend-Table
  --------------------------------------------------------------------------- */


.legend-box {
  position: absolute;
  display: none;
  z-index: 10;
}

.legend-table {
  border: 1px solid #B6B6B4;
  border-collapse: collapse;
  line-height: 18px;
}

.legend-table tr {
  border-bottom: 1px solid #B6B6B4;
}

.legend-table th {
  text-align: center;
  font-size: 125%;
  font-style: strong;
  background-color: #D1D0CE;
}

.legend-table td {
  padding: 2px;
  font-size: 65%;
  line-height: 12px;
  background-color: #FFFFFF;
}

th.category {
  text-align: center;
  font-size: 85%;
  font-style: strong;
  line-height: 14px;
  background-color: #E5E4E2;
}

/* =============================================================================
    Footer
  =========================================================================== */

footer {
  font-size: 0.7em;
  color: #444;
  margin: 30px 0 0px 0;
  padding: 20px 60px;
  border-top: 2px solid #e0e0e0;
}

.footer-title {
  padding: 0;
  margin: 0;
}

.statistics-table {
  margin: 6px 0 0 0;;
  padding: 0;
  list-style-type: none;
}
.statistics-table > li {
  display: inline-block;
}
.statistics-table > li:not(:last-child) {
  margin-right: 20px;
}
.statistics-table > li > label {
  font-weight: bold;
}

/* =============================================================================
    Mobile
  =========================================================================== */

@media screen and (max-width: 1050px) {
  .order-ratings {
    margin-top: -20px;
    text-align: left;
  }
}

@media screen and (max-width: 850px) {
  #page {
    padding-left: 20px;
  }

  body {
    padding: 0 4px 0 10px;
  }

  footer { display: none; }

  .rating-legend {
    display: none;
  }

  .moviecards-container {
    padding: 0;
  }

  .rating-legend {
    width: 80vw;
    min-width: 280px;
  }

  .movie-facts {
    float: none;
    width: 100%;
  }
  .moviecard.open,
  .moviecard {
    padding: 6px 14px;
    margin-top: 0;
  }
  .moviecard.open .movie-rating {
    top: 30px;
    width: 50px;
    height: 50px;
  }
  .movie-title {
    padding-right: 55px;
  }
}


