* {
  box-sizing: border-box;
}

html {
  height: 100%;
}

body {
  height: 100%;
  width: 100%;
  margin: 0;
  font-family: $roboto;
  font-size: 14px;
}

.clearfix:before,
.clearfix:after {
  display: table;
  content: " ";
}
.clearfix:after {
  clear: both;
}

.hide {
  display: none;
}

#header {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1;
  height: $header-height;
  line-height: 24px;
  background: #f2f2f2;
  box-shadow: 0 -4px 3px 4px rgba(darken($header-color, 30%), 0.8);
  color: $blue;
}

.title-text {
  display: block;
  text-align: center;
  height: $header-height;
  line-height: $header-height;
  font-family: $roboto-light;
}

.title-bar button {
  width: $header-height;
  height: $header-height;
  line-height: $header-height;
  margin-right: 8px;
  padding: 0;
  border: 0;
  outline: 0;
}

button { cursor: pointer; }

button.back {
  float: left;
  background: $header-color url('/images/back.png') no-repeat center center;

  & + .title-text {
    text-indent: -$header-height;
  }
}

.menu {
  position: relative;
  float: right;
  height: 36px;
  padding-left: 8px;

  .hamburger {
    width: 36px;
    background: url('/images/menu.png') no-repeat center;
  }
  .menu-list {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    margin: 0;
    padding: 0;
    border: solid 1px $blue;
    background-color: white;
    box-shadow: 0 4px 3px 0px rgba(darken($blue, 30%), 0.8);

    li {
      display: block;
      cursor: pointer;
      white-space: nowrap;
      padding: 5px 15px 5px 10px;
    }
  }
}

.file-input {
  position: relative;
  width: 36px;
  margin-right: 10px;

  .paperclip {
    width: 100%;
    height: 100%;
    background: url('/images/paperclip.png') no-repeat;
    background-size: 90%;
    background-position: center 6px;
  }

  input[type=file] {
    display: none;
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    top: 0;
    left: 0;
    cursor: pointer;
    z-index: 1;
  }

  img.preview {
    max-width: 100%;
  }

  .close {
    font-family: sans-serif;
    color: white;
    position: absolute;
    top: -10px;
    left: 20px;
    text-align: center;
    cursor: default;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    padding: 0px;

    background: #666;
    color: #fff;
    text-align: center;
  }
}
