body  {
  .md-theme-default.md-button:not([disabled]).md-accent.md-raised, .md-theme-default.md-button-toggle.md-accent .md-toggle, .md-theme-default.md-radio .md-radio-container:after, .md-theme-default.md-checkbox.md-checked .md-checkbox-container {
    background-color: #d7373d;
  }
  .md-theme-default.md-radio.md-checked .md-radio-container, .md-theme-default.md-checkbox.md-checked .md-checkbox-container {
    border-color: #d7373d;
  }
  .md-theme-default a:not(.md-button) {
    color: #d7373d;
  }
  .md-theme-default code:not(.hljs) {
    background: #111111;
    color: #DDD;
  }
}
body.theme-classic {
  .md-theme-default .md-checkbox-label {
    color: rgba(0, 0, 0, 0.54)
  }
  #advancedSearch, #advancedSearch .md-list, #wago-tabs { 
    background: white
  }
  .mainnav.bottom .md-list-item-container img {
    filter: invert(100%);
  }
  a.wago-advert-patreon {color: black!important}
  .md-theme-default code:not(.hljs) {
    background: #EEEEEE;
    color: #222;
  }
}
body.theme-dark {
  $Background: #212121;
  $Background2: #333333;
  $Background3: #404040;
  $Links: #c1272d;
  $Text: #DDD;
  $Text2: #B6B6B6;
  $Text3: #999999;

  background-color: $Background!important;
  color: $Text!important;
  h2, .md-subheader {
    color: $Text;
  }
  a.wago-advert-patreon {color: $Text!important}
  .md-theme-default.md-list, .md-theme-default.md-dialog-container .md-dialog, #wago-tabs {
    background: $Background;
    color: $Text;
  }
  .md-theme-default.md-card, .md-card .md-theme-default.md-list, .md-theme-default.md-menu-content .md-list, .md-theme-default.md-select-content .md-menu-item.md-selected, .md-theme-default.md-select-content .md-menu-item.md-checked,
  .md-whiteframe, .md-whiteframe .md-theme-default.md-list,
  #full-sidebar .md-sidenav-content {
    background: $Background2;
    color: $Text;
  }
  #user-info, #gSearch input, #gSearch button, #advancedSearch, #advancedSearch .md-list, #full-sidebar .mainnav {
    background: $Background3;
    color: $Text;
  }
  .md-theme-default.md-select-content .md-menu-item.md-selected, .md-theme-default.md-select-content .md-menu-item.md-checked {
    background: $Background;
  }
  .md-checkbox-container {
    border-color: $Text3;
  }
  .md-list-text-container > :nth-child(2):not(:last-child), .md-theme-default.md-list .md-list-item .router-link-active.md-list-item-container, .md-checkbox-label {
    color: $Text2;
  }
  .md-list-text-container > :nth-child(2), .md-list-text-container > :nth-child(3) {
    color: $Text3;
  }
  .md-theme-default.md-button-toggle.md-accent .md-toggle, .md-theme-default.md-button:not([disabled]).md-primary:not(.md-icon-button), .md-list-item .md-icon {
    color: white;
  }
  .md-button[disabled] {
    color: rgba(255, 255, 255, 0.25)
  }

  #mobile-sidebar .md-sidenav-content, .md-theme-default.md-list .md-list-item-expand .md-list-item-container { background: #090909 }

  .md-input-container {
    &:after {
      background-color: $Text2;
    }
    &.md-has-value input, &.md-has-value textarea, input, textarea, label, .md-icon:not(.md-icon-delete), &.md-has-select {
      color: $Text2;
      -webkit-text-fill-color: $Text2;
    }

    input, textarea {
      &::-webkit-input-placeholder { /* Chrome */ color: $Text2; }
      &:-ms-input-placeholder { /* IE 10+ */ color: $Text2; }
      &::-moz-placeholder { /* Firefox 19+ */ color: $Text2; opacity: 1; }
      &:-moz-placeholder { /* Firefox 4 - 18 */ color: $Text2; opacity: 1; }
    }

    &.md-theme-default.md-input-focused {
      label, .md-icon:not(.md-icon-delete), input, textarea {
        color: $Text;
        -webkit-text-fill-color: $Text;
      }
      &:after {
        background-color: $Text;
      }
    }
  }  

  .md-theme-default.md-select:after, .md-select:not(.md-disabled):after, .md-button-toggle > .md-button:not([disabled]){
    color: white;
    -webkit-text-fill-color: white;
  }

  .md-button-toggle>.md-button:not([disabled]), .md-select:not(.md-disabled):after, .md-theme-default.md-select:after { 
    color: white;
  }
  .md-table .md-table-head, .md-table .md-table-cell { 
    color: $Text;
  }
  .md-table tbody .md-table-row:hover .md-table-cell { 
    background-color: $Background3;
  }
  .md-list:after {
    background-color: $Text3;
  }
  
  .searchText > a {
    color: $Links;
  }
  .user-default {
    color: white!important;
  }
  .cl-priest, .cl-priest a {
    color: white!important;
  }
  .cl-rogue, .cl-rogue a {
    color: #FFF569!important;
  }
  .pvp-battleground, .md-chip.pvp-battleground, .pvp-battleground a {
    color: #0066af!important;
  }
}

body.theme-waluigi {
  $Background: #2b043c;
  $Background2: #3D0056;
  $Background3: #4D076C;
  $VeryDark: #190023;
  $Links: #C5A81D;
  $Text: #DDD;
  $Text2: #B6B6B6;
  $Text3: #999999;
  background-color: $Background!important;
  
  #app .md-theme-default.md-button-toggle.md-primary .md-toggle, #app .md-theme-default.md-toolbar {background: $VeryDark}
  #logo img {
    filter: hue-rotate(25deg) contrast(1) brightness(4.3);
    transform: scaleY(-1);
  }
  #loading svg {
    filter: hue-rotate(25deg) contrast(1) brightness(4.3);
    transform: scaleY(-1) translateY(260px);
  }
  #wago-addons-btn {border-color: $Links; background-color: $VeryDark;}
  #cta-wago-addons {
    background-color: $VeryDark;
    border-color: $Links;
    p {background: #190023A6;}
    .md-button {background: $Links;}
  }

  .md-theme-default a:not(.md-button), #content a:not(.md-button) {
    color: $Links;
  }
  .user-admin, .user-admin:hover {
    color: $Links!important;
  }
  .copy-import-button, .md-theme-default.md-radio.md-checked .md-radio-container, .md-theme-default.md-checkbox.md-checked .md-checkbox-container {
    border-color: $Links
  }

  #notification-banner, .md-button:not([disabled]).md-accent.md-raised, .md-button-toggle.md-accent .md-toggle, .md-radio .md-radio-container:after, .md-checkbox.md-checked .md-checkbox-container, .unreadCount, #app .md-theme-default.md-button-toggle.md-primary .md-toggle {
    background-color: $Links;
  }
  .md-button-toggle.md-accent .md-toggle:hover:not([disabled]), #wago-versions .chip-button:hover, #wago-versions .chip-button.md-toggle {
    background-color: #C7C700;
  }

  .md-list, .md-theme-default.md-dialog-container .md-dialog, .md-theme-default.md-list, #wago-tabs {
    background: $Background;
  }
  .md-theme-default.md-card, .md-card .md-theme-default.md-list, .md-theme-default.md-menu-content .md-list, .md-theme-default.md-select-content .md-menu-item.md-selected, .md-theme-default.md-select-content .md-menu-item.md-checked, .md-whiteframe, .md-whiteframe .md-theme-default.md-list, #full-sidebar .md-sidenav-content {
    background: $Background2;
  }
  #user-info, #gSearch input, #gSearch button, #advancedSearch, #advancedSearch .md-list, #full-sidebar .mainnav {
    background: $Background3;
  }
  .md-select-content .md-menu-item.md-selected, .md-select-content .md-menu-item.md-checked {
    background: $Background;
  }
  .md-checkbox-container {
    border-color: $Text3;
  }

  #mobile-sidebar .md-sidenav-content, .md-list .md-list-item-expand .md-list-item-container { background: $Background2 }

  .md-input-container {
    &:after {
      background-color: $Text2;
    }
    &.md-has-value input, &.md-has-value textarea, input, textarea, label, .md-icon:not(.md-icon-delete), &.md-has-select {
      color: $Text2;
      -webkit-text-fill-color: $Text2;
    }
  }  

  .md-table tbody .md-table-row:hover .md-table-cell { 
    background-color: $Background3;
  }
  .md-list:after {
    background-color: $Text3;
  }
  .searchText > a {
    color: $Links;
  }
}


.md-layout > .md-list:after { background-color: transparent }

/* rtl support */
.rtl-lang {
  .md-sidenav-content, input, textarea, #gSearch, #inputStringWrapper, .md-input-container, .md-list-item-container, .md-list-text-container {
    direction: rtl;
  }
  .md-input-container label {
    left: auto;
    right: 0;
  }
  .md-list-text-container {
    text-align: right;
  }
  #gSearch {
    text-align: left;
    button { 
      margin-left: 0;
      margin-right: -48px;
    }
  }
}