         if element_bottom + (scroll_y - @scroll_y) + @options.bottom_offset > container_bottom
           scroll_y = container_bottom - element_bottom + @scroll_y - @options.bottom_offset
 
+      # console.log ""
+      # console.log "General:"
+      # console.log "          pinch zoom ratio: #{$(window).width() / window.innerWidth}"
+      # console.log "   window.devicePixelRatio: #{window.devicePixelRatio}"
+      # console.log "        navigator.platform: #{navigator.platform}"
+      # console.log "         navigator.appName: #{navigator.appName}"
+      # console.log "       navigator.userAgent: #{navigator.userAgent}"
+      
+      # console.log ""
+      # console.log "Horizontal:"
+      # console.log "        @$el.offset().left: #{@$el.offset().left}px"
+      # console.log "    $(window).scrollLeft(): #{$(window).scrollLeft()}px"
+      # console.log "         window.innerWidth: #{window.innerWidth}px"
+      # console.log "       $(document).width(): #{$(document).width()}px"
+      # console.log "              screen.width: #{screen.width}"
+      # console.log "               *adjustment: #{scroll_x}"
+
+      # console.log ""
+      # console.log "Vertical:"
+      # console.log "        @$el.offset().top: #{@$el.offset().top}px"
+      # console.log "    $(window).scrollTop(): #{$(window).scrollTop()}px"
+      # console.log "       window.innerHeight: #{window.innerHeight}px"
+      # console.log "       $(window).height(): #{$(window).height()}px"
+      # console.log "     $(document).height(): #{$(document).height()}px"
+      # console.log "            screen.height: #{screen.height}"
+      # console.log "              *adjustment: #{scroll_y}"
+
+
       ####
       # APPLY THE ADJUSTMENTS to the fixed element
       if scroll_y != @scroll_y || scroll_x != @scroll_x

        @$el[0].style['-ms-transform'] = "translate(-#{@scroll_x}px, #{@scroll_y}px)"
        @$el[0].style['-moz-transform'] = "translate(-#{@scroll_x}px, #{@scroll_y}px)"

      # make sure that elements that don't scroll down past their container bottom
      if effective_viewport_top + element_height > container_bottom
        @$el[0].style['top'] = "#{container_bottom - element_height - viewport_top}px" 
      else if @$el[0].style['top'] != "#{@options.top_offset}px"
        @$el[0].style['top'] = "#{@options.top_offset}px"          


      @last_viewport_top = viewport_top





    resize : -> @viewport_height = window.innerHeight

    # Update 
    # Updates the position of the element with respect to the viewport. 
