/* Dash */
$dash_background_color: rgba(white, 0.12);

$dash_placeholder_size: 32px;
$dash_padding: $base_padding * 2;
$dash_edge_offset: $base_margin * 3;
$dash_border_radius: 20px + $dash_padding;
$dash_spacing: $base_margin * 0.5;

// container for the dash
#dash {
  // a bit of spacing so that dash doesn't touch the screen edges
  padding-left: $base_padding;
  padding-right: $base_padding;

  // background behind item container
  .dash-background {
    background-color: $dash_background_color;
    border-radius: $dash_border_radius;
    padding-top: $dash_padding;
    padding-bottom: $dash_padding;
    padding-left: $dash_padding - $dash_spacing; // subtract the margins added to .overview-tile below
    padding-right: $dash_padding - $dash_spacing;
    border: 1px solid rgba(black, 0.08);
    box-shadow: inset 0 0 0 1px rgba(white, 0.05);
  }

  // items on the dash
  .dash-item-container {
    .placeholder {
      // background-image: url("resource:///org/gnome/shell/theme/dash-placeholder.svg");
      background-image: none;
      background-size: contain;
      height: $dash_placeholder_size;
    }

    .empty-dash-drop-target {
      width: $dash_placeholder_size;
      height: $dash_placeholder_size;
    }

    // IMPORTANT: items on the dash need to extend to the edge to be adequate click targets
    // as such the %tile style is overriden and button styles are applied to the child class .overview-icon
    .show-apps,
    .overview-tile {
      // remove styles
      background: none;
      box-shadow: none;
      border: none;
      border-radius: 0;
      padding: 0;
      margin: 0 $dash_spacing;
      padding-bottom: $dash_edge_offset; // align with other items

      .overview-icon {
        border-radius: 20px;
        padding: $base_padding;
        spacing: $base_padding;
        text-align: center;
        transition-duration: 100ms;
        background: none;
      }

      &:focus .overview-icon { background-color: $light_divider_color; }
      &:hover .overview-icon { background-color: $light_divider_color; }
      &:active .overview-icon { background-color: $light_track_color; }
      &:highlighted .overview-icon,
      &:selected .overview-icon,
      &:checked .overview-icon { background-color: $light_track_color; }
      &:insensitive .overview-icon { background-color: transparent; }
    }

    // running app dot
    .app-grid-running-dot {
      // manually position the dot within the dash item
      // margin-bottom: $dash_padding + $dash_edge_offset - 3px; // 3px = size of dot (5px) subtracted from its translationY from appDisplay.js
      offset-y: -9px;
    }
  }

  // separator between pinned and running apps
  .dash-separator {
    width: 1px;
    margin-left: $base_margin;
    margin-right: $base_margin;
    background-color: rgba(white, 0.15);
  }

  // make sure all dash components have same margin from screen edge
  .dash-separator,
  .dash-background {
    margin-bottom: $dash_edge_offset;
  }
}

// OSD Tooltip
.dash-label {
  -y-offset: $base_margin * 2; // distance from the dash edge
}
