
/* App Icons */

.show-apps,
.app-well-app,
%app-well-app {
  & .overview-icon {
    color: on($osd, secondary);
    border-radius: $base_radius * 2.5;
    padding: 6px;
    border: none;
    transition-duration: 100ms;
    text-align: center;
  }

  &:hover .overview-icon,
  &:focus .overview-icon,
  &:selected .overview-icon {
    background-color: on($osd, divider);
    border-image: none;
    background-image: none;
  }

  &:active .overview-icon,
  &:checked .overview-icon {
    background-color: on($osd, track);
    box-shadow: none;
  }
}

// App Folders
.app-well-app.app-folder {
  background-color: on(black, divider);
  border-radius: $base_radius * 2.5;

  .overview-icon {
    background-color: transparent;
    border-radius: $base_radius * 2.5;
  }

  &:hover {
    background-color: overlay(black, active);
  }

  &:active {
    background-color: on(black, track);
  }
}

// expanded folder
.app-folder-dialog {
  border-radius: $menu_radius * 3;
  padding: $base_padding * 2;
  box-shadow: none;

  @if $color_type == 'blackness' {
    background-color: $scrim-alt;
  } @else {
    background-color: $osd;
  }

  @if $rimless == 'false' {
    border: 2px solid $osd-primary;
  } @else {
    border: none;
  }

  .folder-name-container {
    padding: ($base_padding * 4) ($base_padding * 6) 0;
    spacing: $base_spacing * 2;

    .folder-name-label,
    .folder-name-entry {
      font-size: 18pt;
      font-weight: bold;
    }

    .folder-name-entry {
      @extend %overview-search-entry;
      width: 300px;
      border: 2px solid transparent;
    }

    .folder-name-label {
      padding: $base_padding * 1.5 ($base_padding + 2px);
      color: on($osd, secondary);
    }

    .edit-folder-button {
      background-color: overlay($osd);
      color: on($osd, secondary);
      border: none;
      padding: 0;
      width: 36px;
      height: 36px;
      border-radius: $circular_radius;

      > StIcon { icon-size: $base_icon_size; }

      &:hover { background-color: overlay($osd, hover); }
      &:checked, &:active { background-color: $inverse-indicator; color: on($inverse-indicator); }
    }
  }

  .icon-grid {
    row-spacing: 12px;
    column-spacing: 24px;
    page-padding-top: 0;
    page-padding-bottom: 0;
    page-padding-left: 0;
    page-padding-right: 0;
  }

  .page-indicators {
    margin-bottom: 18px;
  }
}

.app-folder-dialog-container {
  padding: 0;
  width: 620px;
  height: 620px;
}

// Running app indicator (also shown in dash)
.app-well-app-running-dot {
  width: $base_padding; height: 3px;
  border-radius: 2px;
  background-color: on(black, track);
  margin-bottom: 0;

  StWidget.focused & {
    width: $base_padding * 4;
    background-color: $inverse-indicator !important;
  }
}

// right-click app menu
.app-menu,
.app-well-menu {
  max-width: 27.25em;
}

// Rename popup for app folders
.rename-folder-popup {
  .rename-folder-popup-item {
    spacing: $base_padding;
    &:ltr, &:rtl { padding: 0 $base_padding * 2; }
  }
}

// shutdown and other actions in the grid
.system-action-icon {
  box-shadow: 0 4px 4px rgba(0, 0, 0, 0.2); // FIXME: this should really have a highlight
  background-color: $osd;
  color: on($osd);
  border-radius: $circular_radius;
  icon-size: 48px;
}
