/* Copyright (c) 2011 The Chromium Authors. All rights reserved.
 * Use of this source code is governed by a BSD-style license that can be
 * found in the LICENSE file.
 */

.app {
  position: absolute;
}

.app span {
  display: block;
  text-decoration: none;
  text-overflow: ellipsis;
  white-space: nowrap;
  overflow: hidden;
}

/* TODO(estade): hover effect? press effect? */
.app img {
  cursor: pointer;
  display: block;
  margin-left: auto;
  margin-right: auto;
  /* -webkit-mask-image set by JavaScript to the image source */
  -webkit-mask-size: 100% 100%;
}

/* Pressed is set when an app is first touched.
   By using the mask, pressing causes a darkening effect of just the image */
.app.grabber-pressed img {
  opacity: 0.8;
}

/* Grabbed is set (and pressed is cleared) when the app has been held. */
.grabber-grabbed {
  opacity: 0.8;
  -webkit-transform: scale3d(1.4, 1.4, 1);
}

/* Dragging is set (without grabbed being cleared) when a grabbed app is
   moved */
.grabber-dragging {
  /* We need to ensure there is no animation applied to its position
    (or the drag touch may stop being over top of it */
  -webkit-transition: none !important;

  /* Ensure the element has a large z-index so that we can get events
     for it as it moves over other elements.  This is animated as the
     element flys back, so we want a large value that will stay large until
     its almost home.  */
  z-index: 100;
}