/*
Copyright (C) 2017  Cloudbase Solutions SRL

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as
published by the Free Software Foundation, either version 3 of the
License, or (at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU Affero General Public License for more details.

You should have received a copy of the GNU Affero General Public License
along with this program.  If not, see <http://www.gnu.org/licenses/>.
*/

@import '../variables.scss';

.root {
  :global(.Dropdown-control) {
    text-align: left;
  }
  .buttons {
    padding-top: 16px;
    .leftBtn {
      float: left;
    }
    .rightBtn {
      float: right;
    }
    &:after {

    }
    .centerBtn {
      margin: 0 auto;
      width: 256px;
      display: block;
    }
  }
}
.header {
  h3 {
    /* Add Cloud Endpoint: */
    font-weight: $weight-light;
    font-size: 24px;
    color: $gray-darker;
    padding: 10px;
    background-color: $gray-light;
    text-align: center;
    margin: 0;
    border-radius: 4px 4px 0 0;
  }
}
.container {
  margin: 0 auto;
  padding: 48px 32px 32px;
  position: relative;
  :global(.form-group) {
    margin-bottom: 16px;
    &:global(.switch-radio) {
      width: 100%;
    }
  }
  input[type="text"], input[type="password"] {
    width: 100%;
    box-sizing: border-box;
  }
  textarea {
    width: 100%;
    height: 96px;
    box-sizing: border-box;
  }
  .fields {
    :global(.form-group):not(:global(.switch-radio)) {
      width: 50%;
      float: left;
      box-sizing: border-box;
      label {
        text-align: left;
        text-transform: uppercase;
        font-size: 9px;
        font-weight: 500;
        color: $black;
        display: block;
        margin-bottom: 6px;
      }
      &:nth-child(2n) {
        padding-left: 16px;
      }
      &:nth-child(2n+1) {
        padding-right: 16px;
      }
    }
    &:after {
      clear: both;
      display: block;
      content: " ";
      height: 0;
    }
    .radioOption {
      margin-bottom: 16px;
      label {
        margin-left: 16px;
      }

    }
    &.larger {
      margin-top: 0px;
    }
  }
  &:after {
    clear: both;
    display: block;
    content: " ";
    height: 0;
  }
  .error {
    input {
      border-color: $red;
    }
    :global(.Dropdown-control) {
      border-color: $red;
    }
  }
}
.cloudList {
  height: 324px;
  overflow-y: scroll;
  padding: 8px;
  .cloudImage {
    width: 128px;
    height: 85.5px;
    background-size: contain;
  }
  .cloudContainer {
    width: 33%;
    float: left;
    height: 110px;
    &:nth-child(3n) {
      text-align: right;
    }
    &:nth-child(3n+2) {
      text-align: center;
    }
    :global(.icon) {
      transition: transform $animation-swift-out;
      &:hover {
        cursor: pointer;
        transform: scale(1.05);
      }
    }
  }
  &:after {
    clear: both;
    display: block;
    content: " ";
    height: 0;
  }
}
.cloudImage {
  text-align: center;
  height: 164px;
}
