@import "variables.scss";

#flow {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  width: 100%;
  overflow: hidden;

  div.flow-toolbar {
    height: 40px;
  }

  div.timeline {
    flex: 1;
  }

  div.quick-coto-editor {
    height: 48px;
  }
  &.editing div.quick-coto-editor {
    height: 190px !important;
  }
  &.editing div.quick-coto-editor textarea.coto {
    height: 140px !important;
  }

  a.new-coto-button {
    z-index: 10;
    position: absolute;
    bottom: 6px;
    right: 10px;

    i.material-icons {
      font-size: 32px;
    }

    span.shortcut {
      vertical-align: 10px;
      font-size: 90%;
      font-weight: bold;
      opacity: .6;

      @media (#{$narrow-viewport}) {
        display: none;
      }
    }
  }
}

div.flow-toolbar {
  position: relative;

  div.tools {
    position: absolute;
    top: 7px;
    right: 40px;
    display: inline-block;

    @media (#{$narrow-viewport}) {
      right: 0;
    }

    i {
      vertical-align: middle;
    }

    a.open-filter {
      margin-right: 20px;

      i {
        vertical-align: -7px;
      }
    }

    a.stream-view {
      margin-right: 10px;
    }

    span.random {
      margin-left: 20px;

      i {
        font-size: 1.6rem;
      }
    }
  }
}

div.more-button-div {
  margin-top: 10px;
  padding-left: 2px;
  padding-right: 2px;
  text-align: center;

  button {
    width: 100%;
    background-color: #fff;

    &.loading {
      padding-top: 4px;
      background-color: rgba(255, 255, 255, 0) !important;
    }
  }

  i.material-icons {
    vertical-align: middle;
    font-size: 36px;
  }
}

div.timeline {
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  margin-bottom: 10px;

  // https://stackoverflow.com/questions/29986977/firefox-ignores-padding-when-using-overflowscroll
  &:after {
    content: "";
    height: 30px;
    display: block;
  }

  @media (#{$wide-viewport}) {
    padding-left: 10px;
    padding-right: 10px;
  }

  &.exclude-pinned-graph div.coto.in-pinned-graph,
  &.exclude-posts-in-cotonoma div.coto.posted-in-any-cotonoma {
    display: none;
  }

  div.unread-start-line {
    position: relative;
    padding-top: 20px;

    hr {
      height: 1px;
      border: 0;
      border-top: 1px solid #f33;
    }

    div.line-label {
      display: inline-block;
      position: absolute;
      top: 40px;
      left: 0;
      right: 0;
      margin: auto;
      width: 80px;
      border: 1px solid #f33;
      border-radius: 6px;
      color: #f33;
      background-color: #fff;
      font-size: 1.1rem;
      font-weight: bold;
      text-align: center;
    }
  }
}

div.quick-coto-editor {
  padding: 0 5px;

  div.toolbar {
    position: relative;
    height: 40px;

    span.session {
      margin-left: 5px;
      line-height: 40px;
      vertical-align: middle;
      font-weight: bold;
      color: gray;

      .material-icons {
        margin-right: 3px;
        vertical-align: -6px;
      }

      img.avatar {
        margin: 0;
        padding: 0;
        width: 32px;
        height: 32px;
        margin-right: 8px;
        border-radius: 4px;
        vertical-align: middle;
      }
    }

    div.tool-buttons {
      display: inline-block;
      position: absolute;
      right: 0;
    }

    span.shortcut-help {
      margin-left: 4px;
      text-transform: none;
      opacity: 0.7;
    }

    span.connect-buttons {
      button {
        padding-left: 10px;
        padding-right: 10px;
        margin-right: 5px;
        background-color: #fff;

        @media (#{$narrow-viewport}) {
          margin-right: 10px;
        }

        i {
          font-size: 18px;
          vertical-align: middle;
        }
      }
    }
  }

  textarea.coto {
    margin: 0;
    width: 100%;
    height: 38px;
    box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
  }
}
