Better fix for OAuth dialog with bootstrap

Improves on 4995bf3e49d6bdf1d1c2d5273d4775464c84ccf3

//////////////////// MIXINS

// Minimal, well-documented, general-purpose CSS mixins.
// (Some are same as Bootstrap.)

////////// Box-Sizing: Border-Box

// Setting `box-sizing: border-box` on an element causes the CSS
// layout algorithm to interpret `width` and `height` declarations
// as referring to the size of the border box (outside the border),
// not the content box as usual (inside the padding).
//
// This is especially useful for stretching a form element to the
// width of its container even if the form element has arbitrary
// padding and borders, which can be done using `width: 100%`.
//
// Browser support is IE 8+ and all modern browsers, with the caveat
// that `-moz-box-sizing` in Firefox is considered to have some
// buggy or non-compliant behavior.  For example, min/max-width/height
// may not interact correctly. See
// https://bugzilla.mozilla.org/show_bug.cgi?id=243412.
.box-sizing-by-border () {
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
}

////////// Box-Shadow

.box-shadow (...) {
  box-shadow: @arguments;
  -webkit-box-shadow: @arguments; // For Android
}

////////// Unselectable

.unselectable () {
  -webkit-user-select: none; // Chrome/Safari
  -moz-user-select: none; // Firefox
  -ms-user-select: none; // IE10+

  // These delarations not implemented in browsers yet:
  -o-user-select: none;
  user-select: none;

  // In IE <= 9 and Opera, need unselectable="on" in the HTML.
}

//////////////////// LOGIN BUTTONS

@login-buttons-accounts-dialog-width: 250px;
@login-buttons-color: #596595;
@login-buttons-color-border: darken(@login-buttons-color, 10%);
@login-buttons-color-active: lighten(@login-buttons-color, 10%);
@login-buttons-color-active-border: darken(@login-buttons-color-active, 10%);

@login-buttons-config-color: darken(#f53, 10%);
@login-buttons-config-color-border: darken(@login-buttons-config-color, 10%);
@login-buttons-config-color-active: lighten(@login-buttons-config-color, 10%);
@login-buttons-config-color-active-border: darken(@login-buttons-config-color-active, 10%);

#login-buttons {

  display: inline-block;
  margin-right: 0.2px; // Fixes display on IE8: http://www.compsoft.co.uk/Blog/2009/11/inline-block-not-quite-inline-blocking.html

  // This seems to keep the height of the line from
  // being sensitive to the presence of the unicode down arrow,
  // which otherwise bumps the baseline down by 1px.
  line-height: 1;

  .login-button {
    position: relative; // so that we can position the image absolutely within the button
  }

  .login-buttons-with-only-one-button {
    display: inline-block;
    .login-button { display: inline-block; }
    .login-text-and-button {
      display: inline-block;
    }
  }

  .login-display-name {
    display: inline-block;
    padding-right: 2px;
    line-height: 1.5;
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  }
  .loading {
    line-height: 1;
    background-image: url(data:image/gif;base64,R0lGODlhEAALAPQAAP///wAAANra2tDQ0Orq6gYGBgAAAC4uLoKCgmBgYLq6uiIiIkpKSoqKimRkZL6+viYmJgQEBE5OTubm5tjY2PT09Dg4ONzc3PLy8ra2tqCgoMrKyu7u7gAAAAAAAAAAACH/C05FVFNDQVBFMi4wAwEAAAAh/hpDcmVhdGVkIHdpdGggYWpheGxvYWQuaW5mbwAh+QQJCwAAACwAAAAAEAALAAAFLSAgjmRpnqSgCuLKAq5AEIM4zDVw03ve27ifDgfkEYe04kDIDC5zrtYKRa2WQgAh+QQJCwAAACwAAAAAEAALAAAFJGBhGAVgnqhpHIeRvsDawqns0qeN5+y967tYLyicBYE7EYkYAgAh+QQJCwAAACwAAAAAEAALAAAFNiAgjothLOOIJAkiGgxjpGKiKMkbz7SN6zIawJcDwIK9W/HISxGBzdHTuBNOmcJVCyoUlk7CEAAh+QQJCwAAACwAAAAAEAALAAAFNSAgjqQIRRFUAo3jNGIkSdHqPI8Tz3V55zuaDacDyIQ+YrBH+hWPzJFzOQQaeavWi7oqnVIhACH5BAkLAAAALAAAAAAQAAsAAAUyICCOZGme1rJY5kRRk7hI0mJSVUXJtF3iOl7tltsBZsNfUegjAY3I5sgFY55KqdX1GgIAIfkECQsAAAAsAAAAABAACwAABTcgII5kaZ4kcV2EqLJipmnZhWGXaOOitm2aXQ4g7P2Ct2ER4AMul00kj5g0Al8tADY2y6C+4FIIACH5BAkLAAAALAAAAAAQAAsAAAUvICCOZGme5ERRk6iy7qpyHCVStA3gNa/7txxwlwv2isSacYUc+l4tADQGQ1mvpBAAIfkECQsAAAAsAAAAABAACwAABS8gII5kaZ7kRFGTqLLuqnIcJVK0DeA1r/u3HHCXC/aKxJpxhRz6Xi0ANAZDWa+kEAA7AAAAAAAAAAAA);
    width: 16px;
    background-position: center center;
    background-repeat: no-repeat;
  }
}

#login-buttons .login-button, .accounts-dialog .login-button {
  cursor: pointer;
  .unselectable();
  padding: 4px 8px;

  font-size: 80%;
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  line-height: 1.5;

  text-align: center;
  color: #fff;

  background: @login-buttons-color;
  border: 1px solid @login-buttons-color-border;

  border-radius: 4px;

  &:hover {
    background: @login-buttons-color-active;
  }
  &:active {
    background: @login-buttons-color-active;
    .box-shadow(0 2px 3px 0 rgba(0, 0, 0, 0.2) inset);
  }

  &.login-button-disabled, &.login-button-disabled:active {
    color: #ddd;
    background: #aaa;
    border: 1px solid lighten(#aaa, 10%);
    .box-shadow(none);
  }
}

// precendence of this selector is significant
.accounts-dialog * {
  // A base for our dialog CSS, to reset browser styles and protect against
  // the app's CSS.  Dialogs include the dropdown, config modals, and the
  // reset password modal.  We can't completely isolate the dialogs from
  // the app's CSS, and that isn't the goal because the app can style them.
  // This rule is a compromise that should take precedence over some very
  // broad rules but be overridden by more specific ones.

  // Add more declarations here if they help the dialogs look good
  // out-of-the-box in more apps.

  padding: 0;
  margin: 0;
  line-height: inherit;
  color: inherit;
  font: inherit;

  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

.accounts-dialog .login-button {
  width: auto;
  margin-bottom: 4px;
}

#login-buttons {
  .login-buttons-padding {
    display: inline-block;
    width: 30px;
  }

  .login-display-name { margin-right: 4px; }

  .configure-button {
    background: @login-buttons-config-color;
    border-color: @login-buttons-config-color-border;

    &:active, &:hover {
      background: @login-buttons-config-color-active;
      border-color: @login-buttons-config-color-active-border;
    }
  }

  .login-image {
    display: inline-block;
    position: absolute;
    left: 6px;
    top: 6px;
    width: 16px;
    height: 16px;
  }

  .text-besides-image {
    margin-left: 18px;
  }

  .no-services { color: red; }

  .login-link-and-dropdown-list {
    position: relative;
  }
  .login-close-text {
    float: left;
    position: relative;
    padding-bottom: 8px;
  }

  .login-text-and-button .loading, .login-link-and-dropdown-list .loading {
    display: inline-block;
  }
  &.login-buttons-dropdown-align-left #login-dropdown-list .loading {
    float: right;
  }
  &.login-buttons-dropdown-align-right #login-dropdown-list .loading {
    float: left;
  }

  .login-close-text-clear { clear: both; }

  .or { text-align: center; }
  .hline { text-decoration: line-through; color: lightgrey; }
  .or-text { font-weight: bold; }

  #signup-link { float: right; }
  #forgot-password-link { float: left; }
  #back-to-login-link { float: right; }
}

#login-buttons a, .accounts-dialog a {
    cursor: pointer;
    text-decoration: underline;
}

#login-buttons.login-buttons-dropdown-align-right .login-close-text {
    float: right;
}

@meteor-accounts-base-padding: 8px;
@meteor-accounts-dialog-border-width: 1px;

.accounts-dialog {
  border: @meteor-accounts-dialog-border-width solid #ccc;
  z-index: 1000;
  background: white;
  border-radius: 4px;

  padding: 8px 12px;
  margin: -8px -12px 0 -12px;

  width: @login-buttons-accounts-dialog-width;

  .box-shadow(0 0 3px 0 rgba(0, 0, 0, 0.2));

  // Labels and links inherit app's font with this line commented out:
  //font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-size: 16px;
  color: #333;

  // XXX Make the dropdown and dialogs look good without a top-level
  // line-height: 1.6.  For now, we apply it to everything except
  // the "Close" link, which we want to have the same line-height
  // as the "Sign in" link.
  & > * { line-height: 1.6; }
  & > .login-close-text {
    line-height: inherit;
    font-size: inherit;
    font-family: inherit;
  }

  label, .title {
    font-size: 80%;
    margin-top: 7px;
    margin-bottom: -2px;
  }

  label {
    // Bootstrap sets labels as 'display: none'. Undo that.
    display: inline;
  }

  input[type=text], input[type=email], input[type=password] {
    // Be pixel-accurate in IE 8+ regardless of our borders and
    // paddings, at the expense of IE 7.
    // Any heights or widths applied to this element will set the
    // size of the border box (including padding and borders)
    // instead of the content box.  This makes it possible to
    // do width 100%.
    .box-sizing-by-border();
    width: 100%;
    // A fix purely for the "meteor add bootstrap" experience.
    // Bootstrap sets "height: 20px" on form fields, which is too
    // small when applied to the border box.  People have complained
    // that Bootstrap takes this approach for the sake of IE 7:
    // https://github.com/twitter/bootstrap/issues/2935
    // Our work-around is to override Bootstrap's rule (with higher
    // precedence).
    &[type] { height: auto; }
  }

  .login-button-form-submit { margin-top: 8px; }
  .message { font-size: 80%; margin-top: 8px; line-height: 1.3; }
  .error-message { color: red; }
  .info-message { color: green; }
  .additional-link { font-size: 75%; }

  .accounts-close {
    position: absolute;
    top: 0;
    right: 5px;

    font-size: 20px;
    font-weight: bold;
    line-height: 20px;
    text-decoration: none;
    color: #000;
    opacity: 0.4;

    &:hover {
      opacity: 0.8;
    }
  }

  #login-buttons-cancel-reset-password { float: right; }
  #login-buttons-cancel-enroll-account { float: right; }
}

#login-dropdown-list {
  position: absolute;
  // The top-left of the border-box of the dropdown is absolutely
  // positioned within its container, so we need to compensate
  // for the border.  The padding is already compensated for by
  // negative margins on the dropdown.
  // XXX We could use negative margins to compensate for the
  // border too.
  top: -@meteor-accounts-dialog-border-width;
  left: -@meteor-accounts-dialog-border-width;
}

#login-buttons.login-buttons-dropdown-align-right #login-dropdown-list {
  left: auto;
  right: -@meteor-accounts-dialog-border-width;
}

#login-buttons-message-dialog .message {
    /* we intentionally want it bigger on this dialog since it's the only thing displayed */
    font-size: 100%;
}

.accounts-centered-dialog {
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;

  z-index: 1001;
  position: fixed;

  left: 50%;
  margin-left: -(@login-buttons-accounts-dialog-width
               + @meteor-accounts-base-padding) / 2;

  top: 50%;
  margin-top: -40px; /* = approximately -height/2, though height can change */
}

@configure-login-service-dialog-width: 530px;

#configure-login-service-dialog {
  width: @configure-login-service-dialog-width;
  margin-left: -(@configure-login-service-dialog-width
               + @meteor-accounts-base-padding) / 2;
  margin-top: -220px; /* = approximately -height/2, though height can change */

  table { width: 100%; }
  input[type=text] {
    width: 100%;
    font-family: "Courier New", Courier, monospace;
  }
  ol {
    margin-top: 10px;
    margin-bottom: 10px;

    li { margin-left: 30px; }
  }
  .configuration_labels { width: 30%; }
  .configuration_inputs { width: 70%; }
  .new-section { margin-top: 10px; }
  .url { font-family: "Courier New", Courier, monospace; }
}

#configure-login-service-dialog-save-configuration {
  float: right;
}

.configure-login-service-dismiss-button {
  float: left;
}

#just-verified-dismiss-button, #messages-dialog-dismiss-button {
  margin-top: 8px;
}

.hide-background {
  position: fixed;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  z-index: 999;

  /* XXX consider replacing with DXImageTransform */
  background-color: rgb(0.2, 0.2, 0.2); /* fallback for IE7-8 */

  background-color: rgba(0, 0, 0, 0.7);
}

#login-buttons, .accounts-dialog {
  input[type=text], input[type=email], input[type=password] {
    padding: 4px;
    border: 1px solid #aaa;
    border-radius: 3px;
    line-height: 1;
  }
}

//////////////////// MIXINS

// Minimal, well-documented, general-purpose CSS mixins.
// (Some are same as Bootstrap.)

////////// Box-Sizing: Border-Box

// Setting `box-sizing: border-box` on an element causes the CSS
// layout algorithm to interpret `width` and `height` declarations
// as referring to the size of the border box (outside the border),
// not the content box as usual (inside the padding).
//
// This is especially useful for stretching a form element to the
// width of its container even if the form element has arbitrary
// padding and borders, which can be done using `width: 100%`.
//
// Browser support is IE 8+ and all modern browsers, with the caveat
// that `-moz-box-sizing` in Firefox is considered to have some
// buggy or non-compliant behavior.  For example, min/max-width/height
// may not interact correctly. See
// https://bugzilla.mozilla.org/show_bug.cgi?id=243412.
.box-sizing-by-border () {
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
}

////////// Box-Shadow

.box-shadow (...) {
  box-shadow: @arguments;
  -webkit-box-shadow: @arguments; // For Android
}

////////// Unselectable

.unselectable () {
  -webkit-user-select: none; // Chrome/Safari
  -moz-user-select: none; // Firefox
  -ms-user-select: none; // IE10+

  // These delarations not implemented in browsers yet:
  -o-user-select: none;
  user-select: none;

  // In IE <= 9 and Opera, need unselectable="on" in the HTML.
}

//////////////////// LOGIN BUTTONS

@login-buttons-accounts-dialog-width: 250px;
@login-buttons-color: #596595;
@login-buttons-color-border: darken(@login-buttons-color, 10%);
@login-buttons-color-active: lighten(@login-buttons-color, 10%);
@login-buttons-color-active-border: darken(@login-buttons-color-active, 10%);

@login-buttons-config-color: darken(#f53, 10%);
@login-buttons-config-color-border: darken(@login-buttons-config-color, 10%);
@login-buttons-config-color-active: lighten(@login-buttons-config-color, 10%);
@login-buttons-config-color-active-border: darken(@login-buttons-config-color-active, 10%);

#login-buttons {

  display: inline-block;
  margin-right: 0.2px; // Fixes display on IE8: http://www.compsoft.co.uk/Blog/2009/11/inline-block-not-quite-inline-blocking.html

  // This seems to keep the height of the line from
  // being sensitive to the presence of the unicode down arrow,
  // which otherwise bumps the baseline down by 1px.
  line-height: 1;

  .login-button {
    position: relative; // so that we can position the image absolutely within the button
  }

  .login-buttons-with-only-one-button {
    display: inline-block;
    .login-button { display: inline-block; }
    .login-text-and-button {
      display: inline-block;
    }
  }

  .login-display-name {
    display: inline-block;
    padding-right: 2px;
    line-height: 1.5;
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  }
  .loading {
    line-height: 1;
    background-image: url(data:image/gif;base64,R0lGODlhEAALAPQAAP///wAAANra2tDQ0Orq6gYGBgAAAC4uLoKCgmBgYLq6uiIiIkpKSoqKimRkZL6+viYmJgQEBE5OTubm5tjY2PT09Dg4ONzc3PLy8ra2tqCgoMrKyu7u7gAAAAAAAAAAACH/C05FVFNDQVBFMi4wAwEAAAAh/hpDcmVhdGVkIHdpdGggYWpheGxvYWQuaW5mbwAh+QQJCwAAACwAAAAAEAALAAAFLSAgjmRpnqSgCuLKAq5AEIM4zDVw03ve27ifDgfkEYe04kDIDC5zrtYKRa2WQgAh+QQJCwAAACwAAAAAEAALAAAFJGBhGAVgnqhpHIeRvsDawqns0qeN5+y967tYLyicBYE7EYkYAgAh+QQJCwAAACwAAAAAEAALAAAFNiAgjothLOOIJAkiGgxjpGKiKMkbz7SN6zIawJcDwIK9W/HISxGBzdHTuBNOmcJVCyoUlk7CEAAh+QQJCwAAACwAAAAAEAALAAAFNSAgjqQIRRFUAo3jNGIkSdHqPI8Tz3V55zuaDacDyIQ+YrBH+hWPzJFzOQQaeavWi7oqnVIhACH5BAkLAAAALAAAAAAQAAsAAAUyICCOZGme1rJY5kRRk7hI0mJSVUXJtF3iOl7tltsBZsNfUegjAY3I5sgFY55KqdX1GgIAIfkECQsAAAAsAAAAABAACwAABTcgII5kaZ4kcV2EqLJipmnZhWGXaOOitm2aXQ4g7P2Ct2ER4AMul00kj5g0Al8tADY2y6C+4FIIACH5BAkLAAAALAAAAAAQAAsAAAUvICCOZGme5ERRk6iy7qpyHCVStA3gNa/7txxwlwv2isSacYUc+l4tADQGQ1mvpBAAIfkECQsAAAAsAAAAABAACwAABS8gII5kaZ7kRFGTqLLuqnIcJVK0DeA1r/u3HHCXC/aKxJpxhRz6Xi0ANAZDWa+kEAA7AAAAAAAAAAAA);
    width: 16px;
    background-position: center center;
    background-repeat: no-repeat;
  }
}

#login-buttons .login-button, .accounts-dialog .login-button {
  cursor: pointer;
  .unselectable();
  padding: 4px 8px;

  font-size: 80%;
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  line-height: 1.5;

  text-align: center;
  color: #fff;

  background: @login-buttons-color;
  border: 1px solid @login-buttons-color-border;

  border-radius: 4px;

  &:hover {
    background: @login-buttons-color-active;
  }
  &:active {
    background: @login-buttons-color-active;
    .box-shadow(0 2px 3px 0 rgba(0, 0, 0, 0.2) inset);
  }

  &.login-button-disabled, &.login-button-disabled:active {
    color: #ddd;
    background: #aaa;
    border: 1px solid lighten(#aaa, 10%);
    .box-shadow(none);
  }
}

// precendence of this selector is significant
.accounts-dialog * {
  // A base for our dialog CSS, to reset browser styles and protect against
  // the app's CSS.  Dialogs include the dropdown, config modals, and the
  // reset password modal.  We can't completely isolate the dialogs from
  // the app's CSS, and that isn't the goal because the app can style them.
  // This rule is a compromise that should take precedence over some very
  // broad rules but be overridden by more specific ones.

  // Add more declarations here if they help the dialogs look good
  // out-of-the-box in more apps.

  padding: 0;
  margin: 0;
  line-height: inherit;
  color: inherit;
  font: inherit;

  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

.accounts-dialog .login-button {
  width: auto;
  margin-bottom: 4px;
}

#login-buttons {
  .login-buttons-padding {
    display: inline-block;
    width: 30px;
  }

  .login-display-name { margin-right: 4px; }

  .configure-button {
    background: @login-buttons-config-color;
    border-color: @login-buttons-config-color-border;

    &:active, &:hover {
      background: @login-buttons-config-color-active;
      border-color: @login-buttons-config-color-active-border;
    }
  }

  .login-image {
    display: inline-block;
    position: absolute;
    left: 6px;
    top: 6px;
    width: 16px;
    height: 16px;
  }

  .text-besides-image {
    margin-left: 18px;
  }

  .no-services { color: red; }

  .login-link-and-dropdown-list {
    position: relative;
  }
  .login-close-text {
    float: left;
    position: relative;
    padding-bottom: 8px;
  }

  .login-text-and-button .loading, .login-link-and-dropdown-list .loading {
    display: inline-block;
  }
  &.login-buttons-dropdown-align-left #login-dropdown-list .loading {
    float: right;
  }
  &.login-buttons-dropdown-align-right #login-dropdown-list .loading {
    float: left;
  }

  .login-close-text-clear { clear: both; }

  .or { text-align: center; }
  .hline { text-decoration: line-through; color: lightgrey; }
  .or-text { font-weight: bold; }

  #signup-link { float: right; }
  #forgot-password-link { float: left; }
  #back-to-login-link { float: right; }
}

#login-buttons a, .accounts-dialog a {
    cursor: pointer;
    text-decoration: underline;
}

#login-buttons.login-buttons-dropdown-align-right .login-close-text {
    float: right;
}

@meteor-accounts-base-padding: 8px;
@meteor-accounts-dialog-border-width: 1px;

.accounts-dialog {
  border: @meteor-accounts-dialog-border-width solid #ccc;
  z-index: 1000;
  background: white;
  border-radius: 4px;

  padding: 8px 12px;
  margin: -8px -12px 0 -12px;

  width: @login-buttons-accounts-dialog-width;

  .box-shadow(0 0 3px 0 rgba(0, 0, 0, 0.2));

  // Labels and links inherit app's font with this line commented out:
  //font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-size: 16px;
  color: #333;

  // XXX Make the dropdown and dialogs look good without a top-level
  // line-height: 1.6.  For now, we apply it to everything except
  // the "Close" link, which we want to have the same line-height
  // as the "Sign in" link.
  & > * { line-height: 1.6; }
  & > .login-close-text {
    line-height: inherit;
    font-size: inherit;
    font-family: inherit;
  }

  label, .title {
    display: inline;
    font-size: 80%;
    margin-top: 7px;
    margin-bottom: -2px;
  }
  input[type=text], input[type=email], input[type=password] {
    // Be pixel-accurate in IE 8+ regardless of our borders and
    // paddings, at the expense of IE 7.
    // Any heights or widths applied to this element will set the
    // size of the border box (including padding and borders)
    // instead of the content box.  This makes it possible to
    // do width 100%.
    .box-sizing-by-border();
    width: 100%;
    // A fix purely for the "meteor add bootstrap" experience.
    // Bootstrap sets "height: 20px" on form fields, which is too
    // small when applied to the border box.  People have complained
    // that Bootstrap takes this approach for the sake of IE 7:
    // https://github.com/twitter/bootstrap/issues/2935
    // Our work-around is to override Bootstrap's rule (with higher
    // precedence).
    &[type] { height: auto; }
  }

  .login-button-form-submit { margin-top: 8px; }
  .message { font-size: 80%; margin-top: 8px; line-height: 1.3; }
  .error-message { color: red; }
  .info-message { color: green; }
  .additional-link { font-size: 75%; }

  .accounts-close {
    position: absolute;
    top: 0;
    right: 5px;

    font-size: 20px;
    font-weight: bold;
    line-height: 20px;
    text-decoration: none;
    color: #000;
    opacity: 0.4;

    &:hover {
      opacity: 0.8;
    }
  }

  #login-buttons-cancel-reset-password { float: right; }
  #login-buttons-cancel-enroll-account { float: right; }
}

#login-dropdown-list {
  position: absolute;
  // The top-left of the border-box of the dropdown is absolutely
  // positioned within its container, so we need to compensate
  // for the border.  The padding is already compensated for by
  // negative margins on the dropdown.
  // XXX We could use negative margins to compensate for the
  // border too.
  top: -@meteor-accounts-dialog-border-width;
  left: -@meteor-accounts-dialog-border-width;
}

#login-buttons.login-buttons-dropdown-align-right #login-dropdown-list {
  left: auto;
  right: -@meteor-accounts-dialog-border-width;
}

#login-buttons-message-dialog .message {
    /* we intentionally want it bigger on this dialog since it's the only thing displayed */
    font-size: 100%;
}

.accounts-centered-dialog {
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;

  z-index: 1001;
  position: fixed;

  left: 50%;
  margin-left: -(@login-buttons-accounts-dialog-width
               + @meteor-accounts-base-padding) / 2;

  top: 50%;
  margin-top: -40px; /* = approximately -height/2, though height can change */
}

@configure-login-service-dialog-width: 530px;

#configure-login-service-dialog {
  width: @configure-login-service-dialog-width;
  margin-left: -(@configure-login-service-dialog-width
               + @meteor-accounts-base-padding) / 2;
  margin-top: -220px; /* = approximately -height/2, though height can change */

  table { width: 100%; }
  input[type=text] {
    width: 100%;
    font-family: "Courier New", Courier, monospace;
  }
  ol {
    margin-top: 10px;
    margin-bottom: 10px;

    li { margin-left: 30px; }
  }
  .configuration_labels { width: 30%; }
  .configuration_inputs { width: 70%; }
  .new-section { margin-top: 10px; }
  .url { font-family: "Courier New", Courier, monospace; }
}

#configure-login-service-dialog-save-configuration {
  float: right;
}

.configure-login-service-dismiss-button {
  float: left;
}

#just-verified-dismiss-button, #messages-dialog-dismiss-button {
  margin-top: 8px;
}

.hide-background {
  position: fixed;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  z-index: 999;

  /* XXX consider replacing with DXImageTransform */
  background-color: rgb(0.2, 0.2, 0.2); /* fallback for IE7-8 */

  background-color: rgba(0, 0, 0, 0.7);
}

#login-buttons, .accounts-dialog {
  input[type=text], input[type=email], input[type=password] {
    padding: 4px;
    border: 1px solid #aaa;
    border-radius: 3px;
    line-height: 1;
  }
}


removed merging

removed merging

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/Digipalvelutehdas/APIKA.git/'


Make hevnly symbol slightly larger

Make hevnly symbol slightly larger

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/hevnly/asset-bazaar.git/'


[FEATURE] sap.m.Panel: Add HCB styles

[FEATURE] sap.m.Panel: Add HCB styles

Change-Id: Iafd8d84fbb22f82554d68788337bae0219dedf41

/* ============================================= */
/* Theme CSS for control sap.m/Panel.control     */
/* ============================================= */
.sapMPanelBG {
	background-color: @sapHCStandardBG;
}

/* if Panel is expandable, we do not wish toolbar to come with own border */
.sapMPanelWrappingDivTb>.sapMPanelHdrExpandable.sapMTB {
	border-width: 0;
}

/* if Panel is not expandable, we do wish header to come with own border */
.sapMPanelHdr:not(.sapMPanelHdrExpandable),
/* notice: sapMPanelWrappingDiv is available if Panel is expandable */
.sapMPanelWrappingDiv,
/* do not want border if expanded and if only header text */
.sapMPanelWrappingDivTb {
	border-bottom: 1px solid @sapHCStandardFG;
}

.sapMPanelWrappingDiv.sapMPanelWrappingDivExpanded {
	border-bottom-width: 0;
}

.sapMPanelHdr {
	overflow: hidden;
	white-space: nowrap;
	text-overflow: ellipsis;
	font: @sapUiFontHeaderWeight @sapMFontHeader5Size @sapUiFontFamily;
	text-shadow: none;
	color: @sapHCStandardFG;
	height: 3rem;
	line-height: 3rem;
	padding: 0 1rem;
	background-color: @sapHCStandardBG;
}

.sapMPanelContent {
	padding: 1rem;
	border-bottom: 1px solid @sapHCStandardFG;
}

/* panel placed directly in a body of a Fiori page */
.sap-tablet .sapUiFioriObjectPage > section > div > .sapMPanel, .sap-desktop .sapUiFioriObjectPage > section > div > .sapMPanel
{
	padding: 0 1rem;
	-webkit-box-sizing: border-box;
	-moz-box-sizing: border-box;
	box-sizing: border-box;
}

.sapMPanelHdrExpandable.sapMPanelHdr, .sapMPanelHdrExpandable.sapMTB-Transparent-CTX.sapMTB
{
	padding-left: 0;
}

.sapMIBar.sapMPanelHdrExpandable .sapMBarChild:first-child {
	margin-left: 0;
}

/* 3rem is standard height in this context */
.sapMPanelExpandableIcon {
	width: 3rem;
	line-height: 3rem;
	font-size: 1rem;
	color: @sapHCStandardFG;
}

.sapMPanelHdrExpandable.sapMPanelHdr,
.sapMPanelWrappingDivTb > .sapMTB {
	margin-left: 3rem;
}

.sapMPanelExpandableIcon:focus {
	outline: .125rem dotted @sapHCStandardFG;
	outline-offset: -0.75rem;
}

error: pathspec 'src/sap.m/src/sap/m/themes/sap_hcb/Panel.less' did not match any file(s) known to git


Add flat class for tx-icon

Add flat class for tx-icon

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/xaun/transac.git/'


Unstyle <kbd>

Unstyle <kbd>

that got intruduced in latest Boostrap upgrade.

Fixes #6923

fatal: unable to access 'https://github.com/dsandstrom/atom.git/': The requested URL returned error: 403


Add missing less

Add missing less

.diff{
  table {
  	table-layout: fixed;
  	border-collapse: collapse;
  	width: 100%;
  }
  td {
  	width: 33%;
  	vertical-align: top;
  	text-align: center;
  }
  pre, textarea {
  	height: 99%;
  	width: 99%;
  	margin: auto;
  	font: 1em monospace;
  	text-align: left;
  	white-space: pre-wrap;
  }
  ins, del {
  	display: inline-block;
  }
  del {
  	text-decoration: none;
  	color: #b30000;
  	background: #fadad7;
  }
  ins {
  	background: #eaf2c2;
  	color: #406619;
  	text-decoration: none;
  }
  del.key {
  	border: 1px solid #f8a4a4;
  	border-bottom-width: 0;
  }
  ins.key {
  	border: 1px solid #a3ce4c;
  	border-top-width: 0;
  }

  span {
  	color: #b2b2b2;
  }
  del span {
  	color: #dfb2b2;
  }
  ins span {
  	color: #c2ccb8;
  }

  .level {
  	margin-left: 1.6em;
  }
  .footer {
  	position: absolute;
  	padding: .2em .5em;
  	right: 10px;
  	bottom: 0;
  }

  .error {
  	color: #600;
  }

  @media screen and (-webkit-min-device-pixel-ratio:0) {
  	/* In Firefox and Opera all these stuff disables default outline for textarea. Do it just for WebKit. */
  	textarea {
  		border: 1px solid #DDD;
  	}
  	textarea:focus {
  		border-color: #6699cc;
  	}
  	.error {
  		background-color: #fffafa;
  		border-color: #deb1b1;
  		outline-color: #ff7f7f;
  	}
  	.error:focus {
  		border-color: #c46969;
  	}
  }
}

error: pathspec 'www/assets/less/inc/diff.less' did not match any file(s) known to git


Se corrigen nombres de archivos

Se corrigen nombres de archivos

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/jstoledano/koding.git/'


学习中心首页

学习中心首页

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/XUEJS/xue-project.git/'


slight alignment adjustments

slight alignment adjustments

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/DellGDC/dell-ui-components.git/'


background image

background image

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/cgoudarzi/cgoudarzi.github.io.git/'


Use the 400 'normal' font weight for Lato. Closes #24

Also add the italic font to avoid browser creating
ugly italic fonts from the normal font.

@import url(https://fonts.googleapis.com/css?family=Lato:400,700,400italic&subset=latin);
@font-family-sans-serif: Lato, "Helvetica Neue", Helvetica, Arial, sans-serif;
@font-size-base: 17px;
@import "cucumber-glyphs";

@import url(https://fonts.googleapis.com/css?family=Lato:300,700);
@font-family-sans-serif: Lato, "Helvetica Neue", Helvetica, Arial, sans-serif;
@font-size-base: 16px;
@import "cucumber-glyphs";


Alerts - link underlines and text colour

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/putterschool/styleguide.git/'


added css for the playground

added css for the playground

@import "base";

h1{
	color:#FFF;
	.special-line-shadow;
	font-size: 5em;
	text-align:center;
	letter-spacing:4px;
}

error: pathspec 'src/gofire/main/template/css/playground.less' did not match any file(s) known to git


Make appropriate color changes from PR comments

See for details: https://github.com/adobe/brackets/pull/6315/files#r8624968

// Copyright (c) 2012 Adobe Systems Incorporated. All rights reserved.
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.

/* Brackets patterns (and overrides and re-definitions of Bootstrap patterns)
 *
 * This file should contain all _reusable_ UI elements / LESS definitions
 * That is, things that will either a.) be used for more than one element or
 * b.) exist in multiple versions of brackets (e.g. App, In-Browser, etc.)
 *
 * Note that if you want a UI element to be themeable, you should put the
 * themeable part in "brackets_theme_default" as variables/mixins.
 *
 */

/* Variable Overrides */

@tooltipBackground: #fff;
@tooltipArrowColor: @tooltipBackground;

/* Links */

a {
    color: @tc-link;
    text-decoration: none;
}

a:hover {
    color: @tc-link-hover;
    text-decoration: underline;
}

a:focus {
    color: @tc-link-hover;
    outline: 0;
    border-radius: 3px;
    box-shadow: @tc-input-glow;
    text-decoration: none;
}

.panel {
    .vbox;
    .box-flex(1);

    padding: 0;
    margin: 0;

    background: @project-panel-base-color url("images/propertiespanel_back.png") repeat-x 0 0;
    color: #bbb;
    letter-spacing: .01em;
    text-shadow: 0px 1px 2px rgba(0,0,0,.5);
}

/* Toolbar-related styles */

/* Simple toolbar layout (project panel, find in files, etc.)
   We don't set this directly on .toolbar because it'd be a pain to override all the pieces
   if other code (e.g. #main-toolbar) wants to do a different layout */
.simple-toolbar-layout.toolbar {
    .hbox;
    .box-align(center);
    overflow: hidden;

    .title-wrapper {
        /* This is necessary because text-overflow: ellipsis doesn't work when it's set
           directly on a flexing box in Chrome currently. */
        .box-flex(1);
    }
    .buttons {
        .hbox;
        margin-left: 4px;
    }
}

/* Horizontal titlebar/menubar (in-browser only)

   CSS hack based on this code: http://jsfiddle.net/cD657/3/ (via StackOverflow)
   This center-aligns the title across the full width of the toolbar (ignoring the width of the nav floated
   left and buttons floated right), yet still have the browser automatically wrap the floats onto a 2nd row
   if they collide with the title. But the centered content must be a block element with fixed width. Since
   the editor title (filename) varies in width, we rely on JS code to update the width whenever the string
   changes.

   Another wrinkle: wrapping to/from the two-line toolbar layout requires notifying the CodeMirror editor that
   its height changed. Currently, we assume this can ONLY happen in two cases:
    - the window resizes (handled by general listener in EditorManager)
    - title content changes (the same JS code that sets .title-wrapper's fixed width is expected to handle this)
*/
#titlebar {
    // Visible only in-browser
    body.has-appshell-menus & {
        display: none;
    }

    text-align: center;
    .nav {  // menubar
        float: left;
        text-align: left;
        > li {
            float: left;
        }
    }
    .title {
        float: none;
        display: inline;  // must be an inline for JS to measure text size
    }
    .title-wrapper {
        margin: 0 auto;
        display: block;  // must be a block for the fixed width applied by JS to be respected
        // width set in px is appled/updated by JavaScript in DocumentCommandHandlers
    }
}

/* Vertical icon toolbar on right */
#main-toolbar {
    position: absolute;
    top: 0;
    right: 0;
    width: @main-toolbar-width;
    height: 100%;
    box-sizing: border-box;

    background: @main-toolbar-background-color;
    padding: 7px 0px;

    // Ensure icons are vertically stacked & horizontally centered
    .vbox;
    .box-flex(1);
    text-align: center;

    .buttons,
    .bottom-buttons {
        text-align: center;
        margin: 0;

        > a {
            border-radius: 3px;
            background-repeat: no-repeat;
            display: block;
            height: 24px;
            margin: 7px 0px 0px 3px;
            width: 24px;
        }

        > a:hover {
            background-color: rgba(0, 0, 0, 0.24) !important;
        }

        > a:active {
            background-color: rgba(0, 0, 0, 0.66) !important;
        }
    }

    .bottom-buttons {
        position: absolute;
        bottom: 5px;
    }
}

/* Toolbar appearance - shared by all toolbars, independent of layout */

@toolbar-top-gap-px: 5px;

.toolbar {
    font-size: @label-font-size;
    padding: 4px 8px;
    background-color: @bc-white;
    color: @bc-black;

    position: relative;  // needed for abs-positioned elements in toolbar (e.g. right-aligned "X")

    .title-wrapper {
        // Title is taller than menu text, so reduce top padding to keep its baseline aligned
        padding: (@toolbar-top-gap-px - 3px) 0 3px 0;
    }
    .title {
        font-size: @title-font-size;
        line-height: normal;
        font-weight: @font-weight-light;

        // On Win, the size+weight combo used above does not look good for the bullet character
        .dirty-dot {
            font-weight: normal;
        }

        white-space: nowrap;
        overflow: hidden;
        -ms-text-overflow: ellipsis;
        -o-text-overflow: ellipsis;
        text-overflow: ellipsis;
    }

    .buttons {
        margin: @toolbar-top-gap-px 0 0 4px;

        span, a {
            cursor: default;
        }
    }
}

/* Menu-related styles */

@menubar-top-padding: 8px;
@menubar-bottom-padding: 6px;
@menubar-h-padding: 9px;
@item-highlight-color: #e0f0fa;

.toolbar .nav, .context-menu, .codehint-menu {

    // The 1px adjustments here are to account for the border around the top-level menu items.
    margin: (@toolbar-top-gap-px - @menubar-top-padding - 1) 0 (-@menubar-bottom-padding + 1) (-@menubar-h-padding + 4);

    // General item appearance
    a {
        color: @bc-black;
        text-shadow: none;
        cursor: default;
    }

    // Menubar item appearance
    .dropdown-toggle {
        padding: @menubar-top-padding @menubar-h-padding @menubar-bottom-padding;
        border: 1px solid rgba(0, 0, 0, 0); // transparent border just to hold the layout so it doesn't shift on hover
        color: fadeout(@bc-black, 25%);
        font-weight: @font-weight-light;
    }
    .dropdown-toggle:focus {
        background-color: @bc-white;
        outline: 0;
    }
    .dropdown-toggle:hover, .dropdown.open .dropdown-toggle {
        /* Note: we need several selectors for this in order to match the specificity of all the various Bootstrap
           color rules we need to override (and Bootstrap has several selectors because the colors really differ
           in their defaults). */
        color: @bc-black;
        background: @item-highlight-color;
        border-color: #dbeaf4;
    }

    // no triangle icon after menu items
    .dropdown-toggle:after {
        border: 0;
        margin: 0;
    }

    // Menu dropdown appearance
    .dropdown-menu {
        top: 34px; // Offset from top of menubar item
        margin-top: 0;

        // Fix for #4593: don't let narrow parent (menubar item) cause text wrap at the float boundary between
        // the menu item label and keyboard shortcut. This takes away the "gotta get narrower" pressure.
        // This technique won't work on all browsers; see comments in #4593 for alternative options.
        width: -webkit-max-content;
        width: -moz-max-content;

        background-color: @bc-white;
        .border-radius(0 0 3px 3px);
        box-shadow: @tc-dropdown-shadow;
        border: none;

        // Menu items
        li {
            a {
                font-size: @menu-item-font-size;
                line-height: 18px;

                // Slightly less padding on left to account for checkmark.
                // More padding on top than bottom to center font within its bg highlight better.
                padding: 2px 10px 0px 6px;

                color: @bc-black;
                text-shadow: none;
                white-space: nowrap;
                .box-shadow(none);

                &.wide-result {
                    white-space: normal;
                }

                &:hover, &.highlight {
                    color: @bc-black;
                    background: @item-highlight-color;
                }

                &.disabled {
                    color: @bc-gray;

                    &:hover {
                        background: @bc-white;
                    }
                }

                /* hidden checkmark for all list item content ensures consistent left spacing */
                &::before {
                    content: "✓\00a0"; /* non-breaking space */
                    visibility: hidden;
                }
                /* toggle checkmark visibility */
                &.checked::before {
                    visibility: visible;
                }
            }
        }

        .divider {
            background-color: #eaeaea;
            border: 0;
            margin: 5px 1px;
        }
    }

    // Ensure a minimum amount of space to the left of the shortcut
    .menu-shortcut {
        float: right;
        margin-left: 15px;
    }
}

/* Context menu styles */

.context-menu, .codehint-menu {
    position: absolute;
    z-index: @z-index-brackets-context-menu-base;
    list-style-type: none;

    .dropdown-menu {
        .border-radius(3px);
        box-shadow: @tc-dropdown-shadow;
    }

    .menu-shortcut {
        float: right;
    }
}

.codehint-menu {
    opacity: 0;
    .dropdown-menu {
        box-shadow: @tc-dropdown-shadow;
        max-height: 160px;
        overflow-y: auto;
        padding: 0;

        li {
            a {
                // Less padding than on menus. More padding on top than bottom
                // to center font within its bg highlight better.
                padding: 2px 20px 0px 0px;

                // Don't show highlighting on hover for code hints...
                &:hover {
                    color: @bc-black;
                    background-color: @bc-white;
                }

                // ...except for selected item
                &.highlight:hover {
                    color: @bc-black;
                    background-color: @item-highlight-color;
                }
            }
        }
    }
}

.codehint-menu.open {
    opacity: 1;
    transition: opacity 67ms cubic-bezier(0.03, 0.78, 0.17, 0.97);
}

.codehint-menu.apply-transition {
    transition: right 167ms, left 167ms;
}

#context-menu-bar {
    margin: 0;
}

/* Stylesheet button & dropdown styles */

.stylesheet-button.btn-mini {
    margin-left: 8px;
    position: relative;
    top: -1px;
}

.stylesheet-button.btn-mini.btn-dropdown {
    padding-right: 24px;
}

.stylesheet-button.btn-dropdown::after {
    content: "";
    display: block;
    height: 0px;
    width: 0px;
    position: absolute;
    right: 6px;
    top: 7px;

    /* dropdown triangle */
    border-top: 4px solid @tc-gray-component-triangle;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
}

.stylesheet-dropdown {
    &.dropdown-menu:focus {
        outline: none;
    }

    &.dropdown-menu {
        border: none;
        border-radius: @tc-control-border-radius;
        padding: 0;
        position: absolute;
        display: block;
        box-shadow: @tc-dropdown-shadow;
        max-height: 160px;
        overflow-y: auto;
        max-width: none;
        min-width: 200px;
        z-index: @z-index-brackets-stylesheet-menu;
    }

    .stylesheet-link, .stylesheet-name {
        white-space: nowrap;
    }

    &.dropdown-menu li a {
        padding: 1px 15px 1px 15px;
    }

    &.dropdown-menu .stylesheet-link {
        display: block;
    }

    .stylesheet-name {
        color: @tc-text;
    }

    .stylesheet-dir {
        color: @tc-quiet-text;
    }

    &.dropdown-menu a.selected {
        background: @tc-highlight;
        color: @bc-black !important;
    }

    &.dropdown-menu a:not(.selected):hover {
         background: none;
    }
}

/* Dialog-related styles */

.modal-wrapper {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    overflow: auto;
    display: table;
}

.modal-inner-wrapper {
    display: table-cell;
    vertical-align: middle;
}

.modal {
    background-color: @tc-gray-panel;
    min-width: 200px;
    position: relative;
    top: 0;
    margin: auto;
}

.modal .close {
    cursor: default;
    margin: 7px 5px 0 0;
}

.modal-header {
    background: @tc-gray-panel-top-bar;
    border-radius: 4px 4px 0 0;
    border-bottom: 1px solid @tc-gray-panel-separator;
}

.modal-body {
    background-color: @tc-gray-panel;
}

.modal-body, .modal-header, .modal-footer {
    /* See styles/bootstrap/patterns.less .modal class.
       Pushing this value down to .modal-header and .modal-body
       to allow the overall modal to take the width of the footer */
    width: auto;
}

.modal-footer {
    text-align: right;
    background-color: @tc-gray-panel;
    border-top: 1px solid @tc-gray-panel-separator;
    box-shadow: none;
    padding: 10px 15px 12px;
    white-space: nowrap;
}

.modal-footer .btn {
    float: none;
}
.modal-footer .btn.left {
    float: left;

    /* Transfer the margin to the right of each left-aligned button, so the left side lines up properly
     * with the title.
     */
    margin-left: 0;
    margin-right: 5px;
}
.modal-footer .btn:not(.left) {
    margin-left: 5px;
}

.platform-win {
    /* Reverse Save/Cancel button order on Win */
    .modal-footer {
        text-align: left;
    }
    .modal-footer .btn:not(.left) {
        float: right;
    }
}

.modal-body ul {
    /* Bootstrap's type.less defines a heavy margin-bottom on ul/ol that we don't want in dialogs
       since they have heavy padding instead. */
    margin-bottom: 0;
}

.modal-backdrop {
    opacity: 0;
}
.last-backdrop {
    /* Only show the last modal backdrop */
    opacity: 0.5;
}

.dialog-title {
    color: @tc-light-weight-text;
    margin-bottom: 0;
    margin-top: 0;
    font-size: 22px;
    line-height: 30px;
    font-weight: normal;
}

.dialog-message {
    color: @tc-text;
    font-size: 14px;
    line-height: 20px;
    margin-bottom: 20px;
    font-weight: normal;
}

.dialog-message li {
    line-height: 20px;
    color: @tc-light-weight-text;
    padding: 0 0 5px;
}

.dialog-message select {
    margin-left: 10px;
}

.dialog-list {
    list-style: none;
    margin: 5px 0 20px 10px;
}

.dialog-list > li:before {
    content: "•  ";
    color: @tc-input-border;
    font-size: 1.5em;
    position: relative;
    top: 1px;
}

.dialog-filename {
    word-wrap: break-word;

    font-weight: @font-weight-semibold;
}

/* Any Dialog text in this style is automatically turned into a link that opens in the browser. Use href for the link's target. */
a[href^="http"] {
    cursor: pointer;
}

/* Update dialog */
.update-dialog .modal-body {
    position: relative;
    .update-icon {
        position: absolute;
        left: 30px; // relative to border of modal-body
        top: 20px;
        width: 80px;
        height: 80px;
    }
    .update-text {
        // Icon is 120px, so we need at least that much left padding/margin to avoid overlap
        margin: 0 10px 0 123px;

        .update-info {
            max-height: 200px;
            overflow: auto;

            // Enable text selection
            cursor: auto;
            .user-select(text);
        }
    }
}

/* Project Settings and Install Extension dialogs */
.project-settings-dialog .modal-body, .install-extension-dialog .modal-body {
    text-align: center;

    .field-container {
        display: inline-block;
    }
    label {
        float: none;
    }
    input.url {
        display: inline;
    }
}

.project-settings-dialog .modal-body input.url {
    margin: 0 0 0 5px;
    width: 400px;
}

.install-extension-dialog .modal-body input.url {
    margin: 10px 0;
    width: 550px;
}

/* Extension Manager dialog */
.extension-manager-dialog {
    background-color: #d4d7d7;
    width: 760px;

    .modal-header {
        border-bottom: none;
        padding: 0;

        .nav-tabs {
            margin: 0;
            border-color: #c3c6c5;

            /* Tab styling */
            > li > a {
                min-width: 80px;
                min-height: 60px;
                color: black;
                cursor: default;
                font-size: 12px;

                .box;
                box-sizing: border-box;
                .box-align(center);
                .box-pack(center);
                padding: 0;
                margin: 0;

                text-align: center;

                &:hover {
                    background-color: rgba(0, 0, 0, 0.04);
                    border-color: rgba(0, 0, 0, 0.04);
                }

                > img {
                    margin-top: 5px;
                    padding-bottom: 2px;
                }
            }

            /* Remove border-left from the first tab */
            > li:nth-child(1) > a {
                border-left: transparent;
            }

            /* Colors for the active tab, remove bottom border */
            > .active > a,
            > .active > a:hover {
                background-color: #dfe2e2;
                border-color: #b4b7b7 #b4b7b7 transparent #b4b7b7;
            }

            > li {
                position: relative;  // for positioning .notification icon
                > .notification {
                    display: none;  // hidden by default
                    background-color: #91CC41;
                    color: white;
                    border-radius: 16px;
                    padding: 0 5px;
                    position: absolute;
                    right: 19px;
                    top: 8px;
                }
            }
        }

        /* Search box */
        > :nth-child(2) {
            position: absolute;
            top: 15px;
            right: 15px;
        }
        .search {
            background: #fff url("images/topcoat-search-20.svg") 3px 4px no-repeat;
            float: right;
            margin: 0;
            padding-left: 27px;
            padding-right: 20px;
        }
        .search-clear {
            position: relative;
            display: block;
            float: right;
            left: -5px;
            margin: 7px 0 0 -20px;
            opacity: 0.5;
            background: url("images/topcoat-cancel-15.svg") no-repeat;
            width: 15px;
            height: 16px;
            z-index: 1;
            border: 0;

            &:disabled {
                opacity: 0.3;
                cursor: default;
            }
        }
        .search-clear:active {
            opacity: 0.7;
            &:disabled {
                opacity: 0.3;
            }
        }
    }
    .modal-body {
        height: 400px;
        overflow-y: scroll;
        background-color: @tc-gray-panel;
        padding: 0;

        .empty-message {
            position: absolute;
            top: 50%;
            width: 100%;
            margin-top: -1em;
            text-align: center;
        }

        .info-message {
            background-color: @tc-gray-panel;
            padding: 1em;
        }

        .spinner {
            position: absolute;
            top: 50%;
            left: 50%;
            margin-top: -18px;
            margin-left: -18px;
        }

        .extension-list {
            td {
                height: 2em;
            }
            .ext-info {
                padding-left: 15px;
                width: 220px;
            }
            .ext-name {
                color: @tc-text;
                display: block;
                font-size: 15px;
                font-weight: normal;
                .user-select(text);
                cursor: text;
            }
            .ext-desc {
                width: auto;
                color: @tc-text;
                font-weight: normal;
                .user-select(text);
                cursor: text;
            }
            .muted {
                color: #888;
            }
            .error {
                font-weight: @font-weight-semibold;
                color: #ff5656;
            }
            .ext-version,
            .ext-date,
            .ext-author {
                font-size: 11px;
            }
            .ext-author {
                display: block;
            }
            .ext-action {
                font-size: 12px;
                padding-right: 15px;
                text-align: right;
                vertical-align: middle;
                width: 150px;
            }
            .load-error {
                display: inline-block;
                margin-top: 240px;
            }
        }
    }
}

/* About dialog */
.about-dialog .modal-body {
    // Simple two-column layout: image on left, text taking up remaining space on right
    position: relative;
    .about-icon {
        position: absolute;
        left: 10px;  // relative to border of modal-body (bounds outside padding)
        top:  11px;
    }
    .about-text {
        // Icon is 120px, so we need at least that much left padding/margin to avoid overlap
        margin: 0 10px 0 123px;

        #about-build-number {
            color: @tc-light-weight-quiet-text;
        }
        .about-info {
            max-height: 300px;
            overflow: auto;
        }
        .about-contributors {
            min-height: 100px;

            a {
                text-decoration: none;
            }
        }
        .about-contributors img {
            opacity: 0;
            -webkit-transition: opacity 1s;
            -moz-transition: opacity 1s;
            -o-transition: opacity 1s;
            transition: opacity 1s;
        }
    }

    h2 {
        font-weight: normal;
        font-size: 25px;
        margin-bottom: -4px;
        margin-top: 3px;
    }
    .dialog-message {
        font-size: 14px;
        line-height: 17px;

        // Enable text selection
        cursor: auto;
        .user-select(text);
    }
}

/* Input */
textarea,
input[type="text"],
input[type="password"],
input[type="datetime"],
input[type="datetime-local"],
input[type="date"],
input[type="month"],
input[type="time"],
input[type="week"],
input[type="number"],
input[type="email"],
input[type="url"],
input[type="search"],
input[type="tel"],
input[type="color"],
.uneditable-input {
    background-color: @tc-input-background;
    border: 1px solid @tc-input-border;
    color: @tc-light-weight-text;
    font-size: (@baseFontSize + 1px);
    font-weight: normal;
    -webkit-font-smoothing: antialiased;
    .border-radius(@tc-control-border-radius);
    .box-shadow(@tc-input-inner-shadow);
    .transition(~"border linear 0s, box-shadow linear 0s");

    &::-webkit-input-placeholder {
        color: @tc-input-placeholder-text;
        font-weight: normal;
        -webkit-font-smoothing: antialiased;
    }

    &:focus {
        outline: 0;
        background-color: @tc-input-background;
        text-shadow: none;
        border: 1px solid @tc-gray-component-focused-border;
        box-shadow: @tc-input-inner-shadow, @tc-input-glow;
    }

    &:disabled {
        opacity: @tc-disabled-opacity;
        cursor: default;
    }
}

/* Twipsy tooltips */

.tooltip {
    &.in { opacity: 1; }
}

.tooltip-inner {
    box-shadow: @tc-dropdown-shadow;
    color: @tc-text;
    max-width: 220px;
    text-align: left;
}

.tooltip {
    &.top .tooltip-arrow {
        left: 50%;
    }
    &.right .tooltip-arrow {
        top: 15px;
    }
    &.left .tooltip-arrow {
        top: 15px;
    }
    &.bottom .tooltip-arrow {
        left: 50%;
    }
}

/* Buttons */

// Base .btn styles

.btn:hover,
.btn:focus,
.btn.disabled,
.btn[disabled] {
    background-color: @tc-button-background;
}

.btn.primary:hover,
.btn.primary:focus,
.btn.primary.disabled,
.btn.primary[disabled] {
    background-color: @tc-call-to-action;
}

.btn {
    // Button Base
    background-image: none;

    background-color: @tc-button-background;
    text-shadow: @tc-text-shadow;
    color: @tc-text;
    cursor: default;
    font-size: (@baseFontSize + 1);
    font-weight: @font-weight-semibold;
    line-height: normal;
    border: 1px solid @tc-gray-component-border;
    .border-radius(@tc-control-border-radius);
    box-shadow: @tc-button-highlight;
    -webkit-font-smoothing: antialiased;

    &:hover {
        background-color: @tc-button-background;
        color: @tc-text;
    }

    // Focus state for keyboard and accessibility
    &:focus {
        border: 1px solid @tc-gray-component-focused-border;
        box-shadow: @tc-button-highlight, @tc-input-glow;
        color: @tc-text;
        outline: none;
    }

    // Active and Disabled states
    &.active:not([disabled]),
    &:active:not([disabled]) {
        background-image: none;
        background-color: @tc-button-down-background;
        box-shadow: @tc-button-down-shadow;
        color: @tc-text;
    }

    &.disabled, &[disabled] {
        opacity: @tc-disabled-opacity;
    }

    // Primary Button Type
    &.primary {
        background-image: none;
        background-color: @tc-call-to-action;
        border: 1px solid  @tc-call-to-action-border;
        box-shadow: @tc-call-to-action-highlight;
        color: @tc-call-to-action-text;
        text-shadow: @tc-call-to-action-text-shadow;
        &.active,
        &:active {
            background-image: none;
            background-color: @tc-call-to-action-down;
            box-shadow: @tc-call-to-action-down-shadow;
            color: @tc-call-to-action-text;
        }

        &:focus {
            border: 1px solid @tc-gray-component-focused-border;
            box-shadow: @tc-call-to-action-highlight, @tc-input-glow;
            outline: none;
        }
    }

    // Update Button Type
    &.update {
        background-color: #91cc41;
        border-color: #65a015;
        box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.27);
        color: #fff;
		font-weight: @font-weight-semibold;
        text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.24) ;

        &:active {
            background-color: #82b839;
            border-color: #5b8028;
            box-shadow: inset 0 1px 0 rgba(0, 0, 0, 0.06);
            color: #fff;
        }
    }

    // Button Sizes
    &.large {
        font-size: (@baseFontSize + 1px);
        .border-radius(@tc-control-border-radius);
    }
    &.small {
        font-size: (@baseFontSize - 1px);
    }
}

.btn-mini {
    padding: 2px 6px;
    font-size: 11px;
    font-weight: normal;
    line-height: 14px;
    &:focus {
        border: 1px solid @tc-gray-component-focused-border;
        box-shadow: @tc-button-highlight, @tc-input-small-glow;
        outline: none;
    }
}

/* Tables */

.table, table {
    th {
        font-weight: @font-weight-semibold;
    }
    td {
        border-top: 1px solid transparent;
    }
    tbody th {
        border-top: 1px solid transparent);
    }
}

.table-striped tbody {
    tr:nth-child(odd) td,
    tr:nth-child(odd) th {
        background-color: @tc-lighter-gray; // TopCoat palette
    }
    tr:nth-child(even) td,
    tr:nth-child(even) th {
        background-color: @tc-gray-panel; // turn off bootstrap hover highlight
    }
}
.row-highlight tbody {
    tr:hover td,
    tr:hover th {
        background-color: @tc-highlight; // TopCoat palette
    }
}

/* Emphasis */

strong {
    font-weight: @font-weight-semibold;
}

/* Type */

code {
    color: @bc-black;
    background-color: transparent;
}

label {
    font-size: @label-font-size;
}

/* Overriding Bootstrap's bold properties */

h1,
h2,
h3,
h4,
h5,
h6,
b,
strong,
dt,
.label {
    font-weight: @font-weight-semibold;
}

.alert-message a,
.form-stacked label {
    font-weight: @font-weight-semibold;
}

.alert {
    text-shadow: none;
    background-color: @tc-warning-background;
    border: none;
}
.alert,
.alert h4 {
    // Specified for the h4 to prevent conflicts of changing @headingsColor
    color: @tc-warning-text;
}

input[type="radio"],
input[type="checkbox"] {
    margin: 0;
}

input[type="checkbox"] {
    height: 13px;
    width: 13px;
    vertical-align: middle;
    border: 1px solid @tc-gray-component-border;
    border-radius: 3px;
    background-color: @tc-button-background;
    -webkit-appearance: none;
    box-shadow: @tc-button-highlight;
}

input[type="checkbox"]:active:not(:disabled) {
    background-color: @tc-button-down-background;
    box-shadow: @tc-button-down-shadow;
}

input[type="checkbox"]:focus {
    outline:none;
    border: 1px solid @tc-gray-component-focused-border;
    box-shadow: @tc-input-glow;
}

input[type="checkbox"]:checked:before {
    font-weight: bold;
    color: @tc-text;
    content: '\2713';
    -webkit-margin-start: 0;
    position: relative;
    left: 2px;
    top: -7px;
    font-size: 16px;
}

// Copyright (c) 2012 Adobe Systems Incorporated. All rights reserved.
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.

/* Brackets patterns (and overrides and re-definitions of Bootstrap patterns)
 *
 * This file should contain all _reusable_ UI elements / LESS definitions
 * That is, things that will either a.) be used for more than one element or
 * b.) exist in multiple versions of brackets (e.g. App, In-Browser, etc.)
 *
 * Note that if you want a UI element to be themeable, you should put the
 * themeable part in "brackets_theme_default" as variables/mixins.
 *
 */

/* Variable Overrides */

@tooltipBackground: #fff;
@tooltipArrowColor: @tooltipBackground;

/* Links */

a {
    color: @tc-link;
    text-decoration: none;
}

a:hover {
    color: @tc-link-hover;
    text-decoration: underline;
}

a:focus {
    color: @tc-link-hover;
    outline: 0;
    border-radius: 3px;
    box-shadow: @tc-input-glow;
    text-decoration: none;
}

.panel {
    .vbox;
    .box-flex(1);

    padding: 0;
    margin: 0;

    background: @project-panel-base-color url("images/propertiespanel_back.png") repeat-x 0 0;
    color: #bbb;
    letter-spacing: .01em;
    text-shadow: 0px 1px 2px rgba(0,0,0,.5);
}

/* Toolbar-related styles */

/* Simple toolbar layout (project panel, find in files, etc.)
   We don't set this directly on .toolbar because it'd be a pain to override all the pieces
   if other code (e.g. #main-toolbar) wants to do a different layout */
.simple-toolbar-layout.toolbar {
    .hbox;
    .box-align(center);
    overflow: hidden;

    .title-wrapper {
        /* This is necessary because text-overflow: ellipsis doesn't work when it's set
           directly on a flexing box in Chrome currently. */
        .box-flex(1);
    }
    .buttons {
        .hbox;
        margin-left: 4px;
    }
}

/* Horizontal titlebar/menubar (in-browser only)

   CSS hack based on this code: http://jsfiddle.net/cD657/3/ (via StackOverflow)
   This center-aligns the title across the full width of the toolbar (ignoring the width of the nav floated
   left and buttons floated right), yet still have the browser automatically wrap the floats onto a 2nd row
   if they collide with the title. But the centered content must be a block element with fixed width. Since
   the editor title (filename) varies in width, we rely on JS code to update the width whenever the string
   changes.

   Another wrinkle: wrapping to/from the two-line toolbar layout requires notifying the CodeMirror editor that
   its height changed. Currently, we assume this can ONLY happen in two cases:
    - the window resizes (handled by general listener in EditorManager)
    - title content changes (the same JS code that sets .title-wrapper's fixed width is expected to handle this)
*/
#titlebar {
    // Visible only in-browser
    body.has-appshell-menus & {
        display: none;
    }

    text-align: center;
    .nav {  // menubar
        float: left;
        text-align: left;
        > li {
            float: left;
        }
    }
    .title {
        float: none;
        display: inline;  // must be an inline for JS to measure text size
    }
    .title-wrapper {
        margin: 0 auto;
        display: block;  // must be a block for the fixed width applied by JS to be respected
        // width set in px is appled/updated by JavaScript in DocumentCommandHandlers
    }
}

/* Vertical icon toolbar on right */
#main-toolbar {
    position: absolute;
    top: 0;
    right: 0;
    width: @main-toolbar-width;
    height: 100%;
    box-sizing: border-box;

    background: @main-toolbar-background-color;
    padding: 7px 0px;

    // Ensure icons are vertically stacked & horizontally centered
    .vbox;
    .box-flex(1);
    text-align: center;

    .buttons,
    .bottom-buttons {
        text-align: center;
        margin: 0;

        > a {
            border-radius: 3px;
            background-repeat: no-repeat;
            display: block;
            height: 24px;
            margin: 7px 0px 0px 3px;
            width: 24px;
        }

        > a:hover {
            background-color: rgba(0, 0, 0, 0.24) !important;
        }

        > a:active {
            background-color: rgba(0, 0, 0, 0.66) !important;
        }
    }

    .bottom-buttons {
        position: absolute;
        bottom: 5px;
    }
}

/* Toolbar appearance - shared by all toolbars, independent of layout */

@toolbar-top-gap-px: 5px;

.toolbar {
    font-size: @label-font-size;
    padding: 4px 8px;
    background-color: @bc-white;
    color: @bc-black;

    position: relative;  // needed for abs-positioned elements in toolbar (e.g. right-aligned "X")

    .title-wrapper {
        // Title is taller than menu text, so reduce top padding to keep its baseline aligned
        padding: (@toolbar-top-gap-px - 3px) 0 3px 0;
    }
    .title {
        font-size: @title-font-size;
        line-height: normal;
        font-weight: @font-weight-light;

        // On Win, the size+weight combo used above does not look good for the bullet character
        .dirty-dot {
            font-weight: normal;
        }

        white-space: nowrap;
        overflow: hidden;
        -ms-text-overflow: ellipsis;
        -o-text-overflow: ellipsis;
        text-overflow: ellipsis;
    }

    .buttons {
        margin: @toolbar-top-gap-px 0 0 4px;

        span, a {
            cursor: default;
        }
    }
}

/* Menu-related styles */

@menubar-top-padding: 8px;
@menubar-bottom-padding: 6px;
@menubar-h-padding: 9px;
@item-highlight-color: #e0f0fa;

.toolbar .nav, .context-menu, .codehint-menu {

    // The 1px adjustments here are to account for the border around the top-level menu items.
    margin: (@toolbar-top-gap-px - @menubar-top-padding - 1) 0 (-@menubar-bottom-padding + 1) (-@menubar-h-padding + 4);

    // General item appearance
    a {
        color: @bc-black;
        text-shadow: none;
        cursor: default;
    }

    // Menubar item appearance
    .dropdown-toggle {
        padding: @menubar-top-padding @menubar-h-padding @menubar-bottom-padding;
        border: 1px solid rgba(0, 0, 0, 0); // transparent border just to hold the layout so it doesn't shift on hover
        color: fadeout(@bc-black, 25%);
        font-weight: @font-weight-light;
    }
    .dropdown-toggle:focus {
        background-color: @bc-white;
        outline: 0;
    }
    .dropdown-toggle:hover, .dropdown.open .dropdown-toggle {
        /* Note: we need several selectors for this in order to match the specificity of all the various Bootstrap
           color rules we need to override (and Bootstrap has several selectors because the colors really differ
           in their defaults). */
        color: @bc-black;
        background: @item-highlight-color;
        border-color: #dbeaf4;
    }

    // no triangle icon after menu items
    .dropdown-toggle:after {
        border: 0;
        margin: 0;
    }

    // Menu dropdown appearance
    .dropdown-menu {
        top: 34px; // Offset from top of menubar item
        margin-top: 0;

        // Fix for #4593: don't let narrow parent (menubar item) cause text wrap at the float boundary between
        // the menu item label and keyboard shortcut. This takes away the "gotta get narrower" pressure.
        // This technique won't work on all browsers; see comments in #4593 for alternative options.
        width: -webkit-max-content;
        width: -moz-max-content;

        background-color: @bc-white;
        .border-radius(0 0 3px 3px);
        box-shadow: @tc-dropdown-shadow;
        border: none;

        // Menu items
        li {
            a {
                font-size: @menu-item-font-size;
                line-height: 18px;

                // Slightly less padding on left to account for checkmark.
                // More padding on top than bottom to center font within its bg highlight better.
                padding: 2px 10px 0px 6px;

                color: @bc-black;
                text-shadow: none;
                white-space: nowrap;
                .box-shadow(none);

                &.wide-result {
                    white-space: normal;
                }

                &:hover, &.highlight {
                    color: @bc-black;
                    background: @item-highlight-color;
                }

                &.disabled {
                    color: @bc-gray;

                    &:hover {
                        background: @bc-white;
                    }
                }

                /* hidden checkmark for all list item content ensures consistent left spacing */
                &::before {
                    content: "✓\00a0"; /* non-breaking space */
                    visibility: hidden;
                }
                /* toggle checkmark visibility */
                &.checked::before {
                    visibility: visible;
                }
            }
        }

        .divider {
            background-color: #eaeaea;
            border: 0;
            margin: 5px 1px;
        }
    }

    // Ensure a minimum amount of space to the left of the shortcut
    .menu-shortcut {
        float: right;
        margin-left: 15px;
    }
}

/* Context menu styles */

.context-menu, .codehint-menu {
    position: absolute;
    z-index: @z-index-brackets-context-menu-base;
    list-style-type: none;

    .dropdown-menu {
        .border-radius(3px);
        box-shadow: @tc-dropdown-shadow;
    }

    .menu-shortcut {
        float: right;
    }
}

.codehint-menu {
    opacity: 0;
    .dropdown-menu {
        box-shadow: @tc-dropdown-shadow;
        max-height: 160px;
        overflow-y: auto;
        padding: 0;

        li {
            a {
                // Less padding than on menus. More padding on top than bottom
                // to center font within its bg highlight better.
                padding: 2px 20px 0px 0px;

                // Don't show highlighting on hover for code hints...
                &:hover {
                    color: @bc-black;
                    background-color: @bc-white;
                }

                // ...except for selected item
                &.highlight:hover {
                    color: @bc-black;
                    background-color: @item-highlight-color;
                }
            }
        }
    }
}

.codehint-menu.open {
    opacity: 1;
    transition: opacity 67ms cubic-bezier(0.03, 0.78, 0.17, 0.97);
}

.codehint-menu.apply-transition {
    transition: right 167ms, left 167ms;
}

#context-menu-bar {
    margin: 0;
}

/* Stylesheet button & dropdown styles */

.stylesheet-button.btn-mini {
    margin-left: 8px;
    position: relative;
    top: -1px;
}

.stylesheet-button.btn-mini.btn-dropdown {
    padding-right: 24px;
}

.stylesheet-button.btn-dropdown::after {
    content: "";
    display: block;
    height: 0px;
    width: 0px;
    position: absolute;
    right: 6px;
    top: 7px;

    /* dropdown triangle */
    border-top: 4px solid @tc-gray-component-triangle;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
}

.stylesheet-dropdown {
    &.dropdown-menu:focus {
        outline: none;
    }

    &.dropdown-menu {
        border: none;
        border-radius: @tc-control-border-radius;
        padding: 0;
        position: absolute;
        display: block;
        box-shadow: @tc-dropdown-shadow;
        max-height: 160px;
        overflow-y: auto;
        max-width: none;
        min-width: 200px;
        z-index: @z-index-brackets-stylesheet-menu;
    }

    .stylesheet-link, .stylesheet-name {
        white-space: nowrap;
    }

    &.dropdown-menu li a {
        padding: 1px 15px 1px 15px;
    }

    &.dropdown-menu .stylesheet-link {
        display: block;
    }

    .stylesheet-name {
        color: @tc-text;
    }

    .stylesheet-dir {
        color: @tc-quiet-text;
    }

    &.dropdown-menu a.selected {
        background: @tc-highlight;
        color: @bc-black !important;
    }

    &.dropdown-menu a:not(.selected):hover {
         background: none;
    }
}

/* Dialog-related styles */

.modal-wrapper {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    overflow: auto;
    display: table;
}

.modal-inner-wrapper {
    display: table-cell;
    vertical-align: middle;
}

.modal {
    background-color: @tc-gray-panel;
    min-width: 200px;
    position: relative;
    top: 0;
    margin: auto;
}

.modal .close {
    cursor: default;
    margin: 7px 5px 0 0;
}

.modal-header {
    background: @tc-gray-panel-top-bar;
    border-radius: 4px 4px 0 0;
    border-bottom: 1px solid @tc-gray-panel-separator;
}

.modal-body {
    background-color: @tc-gray-panel;
}

.modal-body, .modal-header, .modal-footer {
    /* See styles/bootstrap/patterns.less .modal class.
       Pushing this value down to .modal-header and .modal-body
       to allow the overall modal to take the width of the footer */
    width: auto;
}

.modal-footer {
    text-align: right;
    background-color: @tc-gray-panel;
    border-top: 1px solid @tc-gray-panel-separator;
    box-shadow: none;
    padding: 10px 15px 12px;
    white-space: nowrap;
}

.modal-footer .btn {
    float: none;
}
.modal-footer .btn.left {
    float: left;

    /* Transfer the margin to the right of each left-aligned button, so the left side lines up properly
     * with the title.
     */
    margin-left: 0;
    margin-right: 5px;
}
.modal-footer .btn:not(.left) {
    margin-left: 5px;
}

.platform-win {
    /* Reverse Save/Cancel button order on Win */
    .modal-footer {
        text-align: left;
    }
    .modal-footer .btn:not(.left) {
        float: right;
    }
}

.modal-body ul {
    /* Bootstrap's type.less defines a heavy margin-bottom on ul/ol that we don't want in dialogs
       since they have heavy padding instead. */
    margin-bottom: 0;
}

.modal-backdrop {
    opacity: 0;
}
.last-backdrop {
    /* Only show the last modal backdrop */
    opacity: 0.5;
}

.dialog-title {
    color: @tc-light-weight-text;
    margin-bottom: 0;
    margin-top: 0;
    font-size: 22px;
    line-height: 30px;
    font-weight: normal;
}

.dialog-message {
    color: @tc-text;
    font-size: 14px;
    line-height: 20px;
    margin-bottom: 20px;
    font-weight: normal;
}

.dialog-message li {
    line-height: 20px;
    color: @tc-light-weight-text;
    padding: 0 0 5px;
}

.dialog-message select {
    margin-left: 10px;
}

.dialog-list {
    list-style: none;
    margin: 5px 0 20px 10px;
}

.dialog-list > li:before {
    content: "•  ";
    color: @tc-input-border;
    font-size: 1.5em;
    position: relative;
    top: 1px;
}

.dialog-filename {
    word-wrap: break-word;

    font-weight: @font-weight-semibold;
}

/* Any Dialog text in this style is automatically turned into a link that opens in the browser. Use href for the link's target. */
a[href^="http"] {
    cursor: pointer;
}

/* Update dialog */
.update-dialog .modal-body {
    position: relative;
    .update-icon {
        position: absolute;
        left: 30px; // relative to border of modal-body
        top: 20px;
        width: 80px;
        height: 80px;
    }
    .update-text {
        // Icon is 120px, so we need at least that much left padding/margin to avoid overlap
        margin: 0 10px 0 123px;

        .update-info {
            max-height: 200px;
            overflow: auto;

            // Enable text selection
            cursor: auto;
            .user-select(text);
        }
    }
}

/* Project Settings and Install Extension dialogs */
.project-settings-dialog .modal-body, .install-extension-dialog .modal-body {
    text-align: center;

    .field-container {
        display: inline-block;
    }
    label {
        float: none;
    }
    input.url {
        display: inline;
    }
}

.project-settings-dialog .modal-body input.url {
    margin: 0 0 0 5px;
    width: 400px;
}

.install-extension-dialog .modal-body input.url {
    margin: 10px 0;
    width: 550px;
}

/* Extension Manager dialog */
.extension-manager-dialog {
    background-color: #d4d7d7;
    width: 760px;

    .modal-header {
        border-bottom: none;
        padding: 0;

        .nav-tabs {
            margin: 0;
            border-color: #c3c6c5;

            /* Tab styling */
            > li > a {
                min-width: 80px;
                min-height: 60px;
                color: black;
                cursor: default;
                font-size: 12px;

                .box;
                box-sizing: border-box;
                .box-align(center);
                .box-pack(center);
                padding: 0;
                margin: 0;

                text-align: center;

                &:hover {
                    background-color: rgba(0, 0, 0, 0.04);
                    border-color: rgba(0, 0, 0, 0.04);
                }

                > img {
                    margin-top: 5px;
                    padding-bottom: 2px;
                }
            }

            /* Remove border-left from the first tab */
            > li:nth-child(1) > a {
                border-left: transparent;
            }

            /* Colors for the active tab, remove bottom border */
            > .active > a,
            > .active > a:hover {
                background-color: #dfe2e2;
                border-color: #b4b7b7 #b4b7b7 transparent #b4b7b7;
            }

            > li {
                position: relative;  // for positioning .notification icon
                > .notification {
                    display: none;  // hidden by default
                    background-color: #91CC41;
                    color: white;
                    border-radius: 16px;
                    padding: 0 5px;
                    position: absolute;
                    right: 19px;
                    top: 8px;
                }
            }
        }

        /* Search box */
        > :nth-child(2) {
            position: absolute;
            top: 15px;
            right: 15px;
        }
        .search {
            background: #fff url("images/topcoat-search-20.svg") 3px 4px no-repeat;
            float: right;
            margin: 0;
            padding-left: 27px;
            padding-right: 20px;
        }
        .search-clear {
            position: relative;
            display: block;
            float: right;
            left: -5px;
            margin: 7px 0 0 -20px;
            opacity: 0.5;
            background: url("images/topcoat-cancel-15.svg") no-repeat;
            width: 15px;
            height: 16px;
            z-index: 1;
            border: 0;

            &:disabled {
                opacity: 0.3;
                cursor: default;
            }
        }
        .search-clear:active {
            opacity: 0.7;
            &:disabled {
                opacity: 0.3;
            }
        }
    }
    .modal-body {
        height: 400px;
        overflow-y: scroll;
        background-color: @tc-gray-panel;
        padding: 0;

        .empty-message {
            position: absolute;
            top: 50%;
            width: 100%;
            margin-top: -1em;
            text-align: center;
        }

        .info-message {
            background-color: @tc-gray-panel;
            padding: 1em;
        }

        .spinner {
            position: absolute;
            top: 50%;
            left: 50%;
            margin-top: -18px;
            margin-left: -18px;
        }

        .extension-list {
            td {
                height: 2em;
            }
            .ext-info {
                padding-left: 15px;
                width: 220px;
            }
            .ext-name {
                color: @tc-text;
                display: block;
                font-size: 15px;
                font-weight: normal;
                .user-select(text);
                cursor: text;
            }
            .ext-desc {
                width: auto;
                color: @tc-text;
                font-weight: normal;
                .user-select(text);
                cursor: text;
            }
            .muted {
                color: #888;
            }
            .error {
                font-weight: @font-weight-semibold;
                color: #ff5656;
            }
            .ext-version,
            .ext-date,
            .ext-author {
                font-size: 11px;
            }
            .ext-author {
                display: block;
            }
            .ext-action {
                font-size: 12px;
                padding-right: 15px;
                text-align: right;
                vertical-align: middle;
                width: 150px;
            }
            .load-error {
                display: inline-block;
                margin-top: 240px;
            }
        }
    }
}

/* About dialog */
.about-dialog .modal-body {
    // Simple two-column layout: image on left, text taking up remaining space on right
    position: relative;
    .about-icon {
        position: absolute;
        left: 10px;  // relative to border of modal-body (bounds outside padding)
        top:  11px;
    }
    .about-text {
        // Icon is 120px, so we need at least that much left padding/margin to avoid overlap
        margin: 0 10px 0 123px;

        #about-build-number {
            color: @tc-light-weight-quiet-text;
        }
        .about-info {
            max-height: 300px;
            overflow: auto;
        }
        .about-contributors {
            min-height: 100px;

            a {
                text-decoration: none;
            }
        }
        .about-contributors img {
            opacity: 0;
            -webkit-transition: opacity 1s;
            -moz-transition: opacity 1s;
            -o-transition: opacity 1s;
            transition: opacity 1s;
        }
    }

    h2 {
        font-weight: normal;
        font-size: 25px;
        margin-bottom: -4px;
        margin-top: 3px;
    }
    .dialog-message {
        font-size: 14px;
        line-height: 17px;

        // Enable text selection
        cursor: auto;
        .user-select(text);
    }
}

/* Input */
textarea,
input[type="text"],
input[type="password"],
input[type="datetime"],
input[type="datetime-local"],
input[type="date"],
input[type="month"],
input[type="time"],
input[type="week"],
input[type="number"],
input[type="email"],
input[type="url"],
input[type="search"],
input[type="tel"],
input[type="color"],
.uneditable-input {
    background-color: @tc-input-background;
    border: 1px solid @tc-input-border;
    color: @tc-light-weight-text;
    font-size: (@baseFontSize + 1px);
    font-weight: normal;
    -webkit-font-smoothing: antialiased;
    .border-radius(@tc-control-border-radius);
    .box-shadow(@tc-input-inner-shadow);
    .transition(~"border linear 0s, box-shadow linear 0s");

    &::-webkit-input-placeholder {
        color: @tc-input-placeholder-text;
        font-weight: normal;
        -webkit-font-smoothing: antialiased;
    }

    &:focus {
        outline: 0;
        background-color: @tc-input-background;
        text-shadow: none;
        border: 1px solid @tc-gray-component-focused-border;
        box-shadow: @tc-input-inner-shadow, @tc-input-glow;
    }

    &:disabled {
        opacity: @tc-disabled-opacity;
        cursor: default;
    }
}

/* Twipsy tooltips */

.tooltip {
    &.in { opacity: 1; }
}

.tooltip-inner {
    box-shadow: @tc-dropdown-shadow;
    color: @tc-text;
    max-width: 220px;
    text-align: left;
}

.tooltip {
    &.top .tooltip-arrow {
        left: 50%;
    }
    &.right .tooltip-arrow {
        top: 15px;
    }
    &.left .tooltip-arrow {
        top: 15px;
    }
    &.bottom .tooltip-arrow {
        left: 50%;
    }
}

/* Buttons */

// Base .btn styles

.btn:hover,
.btn:focus,
.btn.disabled,
.btn[disabled] {
    background-color: @tc-button-background;
}

.btn.primary:hover,
.btn.primary:focus,
.btn.primary.disabled,
.btn.primary[disabled] {
    background-color: @tc-call-to-action;
}

.btn {
    // Button Base
    background-image: none;

    background-color: @tc-button-background;
    text-shadow: @tc-text-shadow;
    color: @tc-text;
    cursor: default;
    font-size: (@baseFontSize + 1);
    font-weight: @font-weight-semibold;
    line-height: normal;
    border: 1px solid @tc-gray-component-border;
    .border-radius(@tc-control-border-radius);
    box-shadow: @tc-button-highlight;
    -webkit-font-smoothing: antialiased;

    &:hover {
        background-color: @tc-button-background;
        color: @tc-text;
    }

    // Focus state for keyboard and accessibility
    &:focus {
        border: 1px solid @tc-gray-component-focused-border;
        box-shadow: @tc-button-highlight, @tc-input-glow;
        color: @tc-text;
        outline: none;
    }

    // Active and Disabled states
    &.active:not([disabled]),
    &:active:not([disabled]) {
        background-image: none;
        background-color: @tc-button-down-background;
        box-shadow: @tc-button-down-shadow;
        color: @tc-text;
    }

    &.disabled, &[disabled] {
        opacity: @tc-disabled-opacity;
    }

    // Primary Button Type
    &.primary {
        background-image: none;
        background-color: @tc-call-to-action;
        border: 1px solid  @tc-call-to-action-border;
        box-shadow: @tc-call-to-action-highlight;
        color: @tc-call-to-action-text;
        text-shadow: @tc-call-to-action-text-shadow;
        &.active,
        &:active {
            background-image: none;
            background-color: @tc-call-to-action-down;
            box-shadow: @tc-call-to-action-down-shadow;
            color: @tc-call-to-action-text;
        }

        &:focus {
            border: 1px solid @tc-gray-component-focused-border;
            box-shadow: @tc-call-to-action-highlight, @tc-input-glow;
            outline: none;
        }
    }

    // Update Button Type
    &.update {
        background-color: #91cc41;
        border-color: #658e2d;
        box-shadow: inset 0 1px 0 #d9edbd;
        color: #fff;
        text-shadow: 0 1px 0 #333;

        &:active {
            background-color: #82b839;
            border-color: #5b8028;
            box-shadow: inset 0 1px 0 #d3e6ba;
            color: #fff;
        }
    }

    // Button Sizes
    &.large {
        font-size: (@baseFontSize + 1px);
        .border-radius(@tc-control-border-radius);
    }
    &.small {
        font-size: (@baseFontSize - 1px);
    }
}

.btn-mini {
    padding: 2px 6px;
    font-size: 11px;
    font-weight: normal;
    line-height: 14px;
    &:focus {
        border: 1px solid @tc-gray-component-focused-border;
        box-shadow: @tc-button-highlight, @tc-input-small-glow;
        outline: none;
    }
}

/* Tables */

.table, table {
    th {
        font-weight: @font-weight-semibold;
    }
    td {
        border-top: 1px solid transparent;
    }
    tbody th {
        border-top: 1px solid transparent);
    }
}

.table-striped tbody {
    tr:nth-child(odd) td,
    tr:nth-child(odd) th {
        background-color: @tc-lighter-gray; // TopCoat palette
    }
    tr:nth-child(even) td,
    tr:nth-child(even) th {
        background-color: @tc-gray-panel; // turn off bootstrap hover highlight
    }
}
.row-highlight tbody {
    tr:hover td,
    tr:hover th {
        background-color: @tc-highlight; // TopCoat palette
    }
}

/* Emphasis */

strong {
    font-weight: @font-weight-semibold;
}

/* Type */

code {
    color: @bc-black;
    background-color: transparent;
}

label {
    font-size: @label-font-size;
}

/* Overriding Bootstrap's bold properties */

h1,
h2,
h3,
h4,
h5,
h6,
b,
strong,
dt,
.label {
    font-weight: @font-weight-semibold;
}

.alert-message a,
.form-stacked label {
    font-weight: @font-weight-semibold;
}

.alert {
    text-shadow: none;
    background-color: @tc-warning-background;
    border: none;
}
.alert,
.alert h4 {
    // Specified for the h4 to prevent conflicts of changing @headingsColor
    color: @tc-warning-text;
}

input[type="radio"],
input[type="checkbox"] {
    margin: 0;
}

input[type="checkbox"] {
    height: 13px;
    width: 13px;
    vertical-align: middle;
    border: 1px solid @tc-gray-component-border;
    border-radius: 3px;
    background-color: @tc-button-background;
    -webkit-appearance: none;
    box-shadow: @tc-button-highlight;
}

input[type="checkbox"]:active:not(:disabled) {
    background-color: @tc-button-down-background;
    box-shadow: @tc-button-down-shadow;
}

input[type="checkbox"]:focus {
    outline:none;
    border: 1px solid @tc-gray-component-focused-border;
    box-shadow: @tc-input-glow;
}

input[type="checkbox"]:checked:before {
    font-weight: bold;
    color: @tc-text;
    content: '\2713';
    -webkit-margin-start: 0;
    position: relative;
    left: 2px;
    top: -7px;
    font-size: 16px;
}