.modal-overlay {
  //background: rgba(255,255,255, 0.7);
  @include background-image(radial-gradient(50% 30%, circle cover, rgba(0,0,0, 0.3), rgba(0,0,0, 0.8)));
  bottom: 0;
  content: "";
  display: none;
  left: 0;
  position: fixed;
  right: 0;
  top: 0;
  z-index: 5;

  &.visible {
    display: block;
  }
}

.modal {
  background: rgba(0,0,0, 0.6);
  border: 1px solid rgba(0, 0, 0, 0.9);
  @include border-radius(0px);
  @include box-shadow(0 15px 80px 15px rgba(0,0,0, 0.5));
  color: #fff;
  display: none;
  left: 50%;
  margin-left: -(grid-width(6)) / 2;
  padding: 8px;
  position: absolute;
  top: 170px;
  width: grid-width(6);
  z-index: 10;

  &.visible {
    display: block;
  }

  &.video-modal {
    //height: 360px;
    left: 50%;
    margin-left: -320px;
    //margin-top: -180px;
    //top: 50%;
    width: 642px;

    .inner-wrapper {
      height: 360px;
      padding: 0px;
      width: 640px;
    }
  }

  .inner-wrapper {
    background: rgb(240,240,240);
    @include border-radius(0px);
    border: 1px solid rgba(0, 0, 0, 0.9);
    @include box-shadow(inset 0 1px 0 0 rgba(255, 255, 255, 0.7));
    overflow: hidden;
    padding-bottom: 30px;
    position: relative;

    header {
      margin-bottom: 30px;
      overflow: hidden;
      padding: 28px 20px 0px;
      position: relative;
      z-index: 2;

      &::before {
        @include background-image(radial-gradient(50% 50%, circle closest-side, rgba(255,255,255, 0.8) 0%, rgba(255,255,255, 0) 100%));
        content: "";
        display: block;
        height: 400px;
        left: 0px;
        margin: 0 auto;
        position: absolute;
        top: -140px;
        width: 100%;
        z-index: 1;
      }

      hr {
        @extend .faded-hr-divider-light;
        border: none;
        margin: 0px;
        position: relative;
        z-index: 2;

        &::after {
          @extend .faded-hr-divider;
          bottom: 0px;
          content: "";
          display: block;
          position: absolute;
          top: -1px;
        }
      }

      h3 {
        color: $lighter-base-font-color;
        font: normal 1.4rem/1.8rem $serif;
        padding-bottom: 20px;
        text-align: center;
        text-shadow: 0 1px rgba(255,255,255, 0.4);
        text-transform: uppercase;
        vertical-align: middle;
        position: relative;
        z-index: 2;
      }

    }

    form {
      margin-bottom: 12px;
      padding: 0px 40px;
      position: relative;
      z-index: 2;

      label {
        display: none;
      }

      input[type="checkbox"] {
        margin-right: 5px;
      }

      input[type="email"],
      input[type="text"],
      input[type="password"] {
        background: rgb(255,255,255);
        display: block;
        height: 45px;
        margin-bottom: 20px;
        width: 100%;
      }

      label.remember-me,
      label.terms-of-service,
      label.honor-code {
        background: rgb(233,233,233);
        border: 1px solid rgb(200,200,200);
        @include border-radius(3px);
        @include box-shadow(0 1px 0 0 rgba(255,255,255, 0.6));
        display: block;
        margin-bottom: 20px;
        padding: 8px 10px;

        &:hover {
          background: rgb(230,230,230);
        }

        a {
          font: normal 1.2rem/1.6rem $serif;
          text-decoration: underline;

          &:hover {
          }
        }
      }

      .honor-code-summary {
        margin-bottom: 20px;
        padding: 0px;
        position: relative;

        p {
          color: $lighter-base-font-color;
          font: 300 1.2rem/1.6rem $sans-serif;
        }

        hr {
          @extend .faded-hr-divider-light;
          border: none;
          margin-top: 30px;
          position: relative;
          z-index: 2;

          &::after {
            @extend .faded-hr-divider;
            bottom: 0px;
            content: "";
            display: block;
            position: absolute;
            top: -1px;
          }
        }

        ul {
          @include box-sizing(border-box);
          margin: 0;
          padding: 0 0 0 20px;
          width: 100%;

          li {
            color: $lighter-base-font-color;
            font: 300 1.2rem/1.6rem $sans-serif;
            margin-bottom: 10px;

            &:last-child {
              margin-bottom: 0px;
            }
          }
        }
      }

      .submit {
        padding-top: 10px;

        input[type="submit"] {
          display: block;
          height: 45px;
          margin: 0 auto;
          width: 100%;
        }
      }
    }

    .login-extra {
      position: relative;
      z-index: 2;

      p {
        color: $lighter-base-font-color;
        font: italic 1.2rem/1.6rem $serif;
        text-align: center;

        a {
          color: $lighter-base-font-color;
          font: italic 1.2rem/1.6rem $serif;
          text-decoration: underline;

          &:hover {
            color: $base-font-color;
          }
        }

        span + a {
          margin-left: 15px;
        }
      }
    }

    .close-modal {
      @include border-radius(2px);
      cursor: pointer;
      @include inline-block;
      padding: 10px;
      position: absolute;
      right: 2px;
      top: 0px;
      z-index: 3;

      .inner {
        p {
          color: $lighter-base-font-color;
          font: normal 1.2rem/1.2rem $sans-serif;
          text-align: center;
          text-shadow: 0 1px rgba(255,255,255, 0.8);
          @include transition(all, 0.15s, ease-out);
        }
      }

      &:hover {
        p {
          color: $base-font-color;
        }
      }
    }
  }
}
