//
// Login form
// --------------------------------------------------

#login-form {
  box-sizing: border-box;
  margin: $line-height-computed * 2 auto $line-height-computed;

  label,
  input:not([type="checkbox"]) {
    width: 100%;
  }

  label {
    display: block;
    margin-bottom: $padding-base-vertical;
    font-weight: $font-weight-bold;
    line-height: inherit;

    &[for="autologin"] {
      @include check;
      margin-bottom: $line-height-computed;
    }

    > a {
      float: right;
      font-weight: $font-weight-normal;
    }
  }

  input[type="text"],
  input[type="password"] {
    margin-bottom: $panel-body-padding-vertical;
  }

  #login-submit {
    padding-top: $padding-base-vertical;
    padding-bottom: $padding-base-vertical;
  }

  table {
    margin: auto;
    table-layout: fixed;
  }

  td {
    padding: 0;

    &:first-child {
      width: $login-form-label-width;
      padding-right: $table-cell-padding;
      white-space: nowrap;
    }

    > label {
      margin-bottom: $panel-body-padding-vertical;
    }

    > input[type="submit"] {
      width: auto;
      margin-right: 0;
    }
  }

  @media screen and (min-width: $login-form-box-breakpoint) {
    width: $login-form-width;
    padding: $padding-side;
    border: 1px solid $panel-border;
    border-radius: $border-radius-base;
    background-color: $panel-bg;
    box-shadow: $panel-shadow;
    color: $panel-color;

    table {
      width: 100%;
    }
  }

  @each $adjustment, $languages in $login-form-adjustments-map {
    @each $language in $languages {
      html[lang="#{$language}"] & td:first-child {
        width: $login-form-label-width + $adjustment * 1em;
      }
    }
  }
}

#openid_url {
  padding-right: $input-padding-horizontal + 24px;
  background-image: url("../../../images/openid-bg.gif");
  background-repeat: no-repeat;
  background-position: right $input-padding-horizontal center;
}
