/*
 * AI Future phone launcher icons
 * v20261023mobileonly1
 */

/* Empty searches must hide the grid at every viewport. */
#appsWorkspace #appGrid.hidden {
  display: none !important;
}

@media (max-width: 719px) {
#appsWorkspace #appGrid {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  align-items: start;
  gap: 28px 20px !important;
}

/* Empty searches must hide the grid, including older mobile display rules. */
#appsWorkspace #appGrid.hidden {
  display: none !important;
}

#appsWorkspace #appGrid .launcher-app-item {
  position: relative;
  min-width: 0;
}

#appsWorkspace #appGrid .launcher-app-link.card-hover {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 9px;
  min-height: 118px;
  padding: 8px 8px 10px;
  overflow: visible;
  border: 1px solid transparent;
  border-radius: 16px;
  background: transparent;
  box-shadow: none;
  color: #334155;
  text-align: center;
  text-decoration: none;
  transition: transform 150ms ease, background 150ms ease, border-color 150ms ease, box-shadow 150ms ease;
}

#appsWorkspace #appGrid .launcher-app-link.card-hover:hover,
#appsWorkspace #appGrid .launcher-app-link.card-hover:focus-visible,
#appsWorkspace #appGrid .launcher-app-item:focus-within .launcher-app-link,
#appsWorkspace #appGrid .launcher-app-link.card-hover.is-previewed {
  z-index: 2;
  transform: translateY(-2px);
  border-color: #e1eaf5;
  background: rgba(255, 255, 255, 0.7);
  box-shadow: 0 7px 18px rgba(15, 23, 42, 0.07);
}

#appsWorkspace #appGrid .launcher-app-link.card-hover:focus-visible {
  outline: 2px solid #3b82f6;
  outline-offset: -2px;
}

#appsWorkspace #appGrid .launcher-app-icon {
  display: grid;
  width: 56px;
  height: 56px;
  flex: 0 0 56px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 18px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.45), 0 4px 10px rgba(15, 23, 42, 0.07);
  color: #1f2937;
  transition: transform 150ms ease, box-shadow 150ms ease;
}

#appsWorkspace #appGrid .launcher-app-link.card-hover:hover .launcher-app-icon,
#appsWorkspace #appGrid .launcher-app-link.card-hover:focus-visible .launcher-app-icon,
#appsWorkspace #appGrid .launcher-app-link.card-hover.is-previewed .launcher-app-icon,
#appsWorkspace #appGrid .phone-app-card:focus-visible .launcher-app-icon {
  transform: translateY(-1px) scale(1.03);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.6), 0 6px 13px rgba(15, 23, 42, 0.1);
}

#appsWorkspace #appGrid .launcher-app-icon .app-function-icon {
  display: block;
  width: 26px;
  height: 26px;
  color: #1f2937;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
}

#appsWorkspace #appGrid .launcher-app-name {
  display: -webkit-box;
  width: 100%;
  min-height: 40px;
  overflow: hidden;
  color: #334155;
  font-size: 14px;
  font-weight: 600;
  line-height: 20px;
  letter-spacing: 0.01em;
  text-align: center;
  text-wrap: balance;
  white-space: normal;
  word-break: break-word;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

#appsWorkspace #appGrid .launcher-pastel-0 { background: #eaf2ff; }
#appsWorkspace #appGrid .launcher-pastel-1 { background: #e6f8fb; }
#appsWorkspace #appGrid .launcher-pastel-2 { background: #e5f7f3; }
#appsWorkspace #appGrid .launcher-pastel-3 { background: #f1ebff; }
#appsWorkspace #appGrid .launcher-pastel-4 { background: #fff0e8; }
#appsWorkspace #appGrid .launcher-pastel-5 { background: #ffedf5; }

#appsWorkspace #appGrid .launcher-card-fav.card-fav {
  top: -4px;
  right: calc(50% - 54px);
  left: auto;
  z-index: 4;
  width: 26px;
  height: 26px;
  border: 1px solid rgba(226, 232, 240, 0.95);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 3px 9px rgba(15, 23, 42, 0.08);
  color: #94a3b8;
  transition: transform 150ms ease, color 150ms ease, background 150ms ease, box-shadow 150ms ease;
}

#appsWorkspace #appGrid .launcher-card-fav.card-fav:hover,
#appsWorkspace #appGrid .launcher-card-fav.card-fav:focus-visible {
  transform: scale(1.08);
  background: #fff;
  color: #d97706;
  outline: 2px solid #fbbf24;
  outline-offset: 2px;
}

#appsWorkspace #appGrid .launcher-card-fav.card-fav.is-on {
  color: #d97706;
}

@media (min-width: 960px) {
  #appsWorkspace #appGrid {
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
    gap: 30px 22px !important;
  }
}

@media (min-width: 1180px) {
  #appsWorkspace #appGrid {
    grid-template-columns: repeat(6, minmax(0, 1fr)) !important;
    gap: 32px 24px !important;
  }
}

@media (min-width: 1440px) {
  #appsWorkspace #appGrid {
    grid-template-columns: repeat(7, minmax(0, 1fr)) !important;
    gap: 34px 26px !important;
  }
}

@media (min-width: 1680px) {
  #appsWorkspace #appGrid {
    grid-template-columns: repeat(8, minmax(0, 1fr)) !important;
    gap: 36px 28px !important;
  }
}

@media (max-width: 719px) {
  #appsWorkspace #appGrid {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 22px 8px !important;
  }

  #appsWorkspace #appGrid .phone-app-card {
    display: flex;
    width: 100%;
    min-height: 112px;
    padding: 3px 0 0;
    overflow: visible;
    border: 0;
    border-radius: 14px;
    background: transparent;
    box-shadow: none;
    color: #334155;
    text-align: center;
    font: inherit;
    cursor: pointer;
    -webkit-appearance: none;
    appearance: none;
    transition: transform 150ms ease, background 150ms ease;
  }

  #appsWorkspace #appGrid .phone-app-card:active {
    transform: scale(0.97);
  }

  #appsWorkspace #appGrid .phone-app-card:focus-visible {
    outline: 2px solid #3b82f6;
    outline-offset: 3px;
  }

  #appsWorkspace #appGrid .launcher-phone-content {
    display: flex;
    width: 100%;
    min-width: 0;
    flex-direction: column;
    align-items: center;
    gap: 8px;
  }

  #appsWorkspace #appGrid .launcher-app-name {
    min-height: 38px;
    font-size: 13px;
    line-height: 19px;
  }
}

@media (min-width: 720px) and (hover: none), (min-width: 720px) and (pointer: coarse) {
  #appsWorkspace #appGrid .launcher-card-fav.card-fav {
    top: -13px;
    right: calc(50% - 63px);
    width: 44px;
    height: 44px;
    border: 0;
    background: transparent;
    box-shadow: none;
  }

  #appsWorkspace #appGrid .launcher-card-fav.card-fav::before {
    content: "";
    position: absolute;
    inset: 9px;
    z-index: 0;
    border: 1px solid rgba(226, 232, 240, 0.95);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 3px 9px rgba(15, 23, 42, 0.08);
  }

  #appsWorkspace #appGrid .launcher-card-fav.card-fav svg {
    position: relative;
    z-index: 1;
  }

  #appsWorkspace #appGrid .launcher-card-fav.card-fav:hover,
  #appsWorkspace #appGrid .launcher-card-fav.card-fav:focus-visible {
    background: transparent;
  }

  #appsWorkspace #appGrid .launcher-card-fav.card-fav:hover::before,
  #appsWorkspace #appGrid .launcher-card-fav.card-fav:focus-visible::before {
    background: #fff;
  }
}

@media (prefers-reduced-motion: reduce) {
  #appsWorkspace #appGrid .launcher-app-link,
  #appsWorkspace #appGrid .launcher-app-icon,
  #appsWorkspace #appGrid .launcher-card-fav,
  #appsWorkspace #appGrid .phone-app-card {
    transition: none !important;
  }

  #appsWorkspace #appGrid .fade-in {
    animation: none !important;
  }
}
}
