/* Quick Actions trang chủ — phong cách tối giản (ô vuông trắng + icon nét mảnh đơn sắc).
   Đổi màu nét icon toàn bộ tại --qa-ink. */

/* 2 hàng, cuộn ngang bằng vuốt; thanh cuộn ẩn. Mỗi khung nhìn ~4,4 cột để lộ mép cột kế tiếp. */
html body #homeGrid.home-grid {
  --qa-ink: #087f8c;
  display: grid;
  grid-template-columns: none;
  grid-template-rows: repeat(2, auto);
  grid-auto-flow: column;
  grid-auto-columns: calc((100% - 8px * 4) / 4.4);
  gap: 16px 8px;
  max-height: none;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  scroll-snap-type: x proximity;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 6px 4px 4px;
}
html body #homeGrid.home-grid::-webkit-scrollbar {
  display: none;
}
html body #homeGrid .home-tile.home-qa {
  scroll-snap-align: start;
}

@media (min-width: 900px) {
  html body #homeGrid.home-grid {
    grid-auto-columns: calc((100% - 12px * 5) / 5.4);
    gap: 20px 12px;
  }
}

html body #homeGrid .home-tile.home-qa {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  min-width: 0;
  width: auto;
  height: auto;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
  color: #334155;
  font-size: 11.5px;
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: 0;
  text-align: center;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}
html body #homeGrid .home-tile.home-qa:hover {
  transform: none;
  box-shadow: none;
  border-color: transparent;
}

html body #homeGrid .home-qa .home-tile-ico {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid #e8edf1;
  border-radius: 12px;
  background: #ffffff;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.06);
  color: var(--qa-ink);
  transition: transform 0.12s ease;
}
html body #homeGrid .home-qa .home-tile-ico svg {
  width: 24px;
  height: 24px;
  stroke-width: 1.6;
}
html body #homeGrid .home-qa .home-tile-ico.is-invest {
  padding: 8px;
  overflow: hidden;
}
html body #homeGrid .home-qa .home-tile-ico.is-invest img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

html body #homeGrid .home-qa .home-tile-label {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  max-width: 100%;
  overflow: hidden;
  overflow-wrap: anywhere;
}

html body #homeGrid .home-qa:active .home-tile-ico {
  transform: scale(0.94);
}

@media (hover: hover) and (pointer: fine) {
  html body #homeGrid .home-qa:hover .home-tile-ico {
    border-color: #d5dee5;
    box-shadow: 0 4px 10px rgba(15, 23, 42, 0.08);
  }
}

html body #homeGrid .home-qa:focus-visible {
  outline: none;
}
html body #homeGrid .home-qa:focus-visible .home-tile-ico {
  outline: 2px solid var(--qa-ink);
  outline-offset: 2px;
}

html body #homeGrid .home-qa.home-qa-add .home-tile-ico {
  border: 2.5px solid #087f8c;
  box-shadow: 0 2px 10px rgba(8, 127, 140, 0.28);
  background: #f3fbfc;
}
@media (hover: hover) and (pointer: fine) {
  html body #homeGrid .home-qa.home-qa-add:hover .home-tile-ico {
    border-color: #06646e;
    box-shadow: 0 4px 12px rgba(8, 127, 140, 0.34);
  }
}

@media (prefers-reduced-motion: reduce) {
  html body #homeGrid .home-qa .home-tile-ico {
    transition: none;
  }
}
