/**
 * Hydra Tools — Gallery view (Hypercat mgallery pattern).
 * Mobile: 3-col compact. Desktop: auto-fill minmax. Cards = <button>.
 */

/* ---------- hidden guards (specificity vs tools-mobile.css) ---------- */
#hydraToolsShell .st-gallery-host.hidden,
#hydraToolsShell .st-table-scroll.hidden,
#hydraToolsShell .st-cards-list.hidden,
#hydraToolsShell .pw-cards-list.hidden,
#hydraToolsShell .price-watch-table-scroll.hidden,
#hydraToolsShell .pw-gallery-host.hidden,
#hydraToolsShell .pw-mobile-only.pw-cards-list.hidden,
#hydraToolsShell .st-mobile-only.st-cards-list.hidden {
  display: none !important;
}

/* ---------- view-host wrappers ---------- */
#hydraToolsShell .st-gallery-host,
#hydraToolsShell .pw-gallery-host,
#hydraToolsShell .st-view-host,
#hydraToolsShell .ht-view-host {
  padding: 4px 9px 10px;
  min-width: 0;
  overflow: hidden;
  box-sizing: border-box;
}

#hydraToolsShell .st-view-host .hti-gallery-grid,
#hydraToolsShell .pw-mobile-only.st-view-host .hti-gallery-grid,
#hydraToolsShell .ht-view-host .hti-gallery-grid,
#hydraToolsShell .ht-list-panel--gallery .hti-gallery-grid {
  padding: 0;
}

/* ---------- List / Gallery toggle ---------- */
#hydraToolsShell .hti-view-toggle-row {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  padding: 0 0 8px;
  min-width: 0;
}

#hydraToolsShell .hti-view-toggle {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
  padding: 2px;
  border-radius: 10px;
  border: 1px solid rgba(15, 23, 42, 0.1);
  background: #f8fafc;
}

#hydraToolsShell .hti-view-seg {
  flex: 1 1 0;
  min-width: 0;
  height: 30px;
  padding: 0 10px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #64748b;
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

#hydraToolsShell .hti-view-seg.is-active {
  background: #fff;
  color: #c2410c;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
}

/* ================================================================
   Compact filter bar (shared across tools)
   ================================================================ */
@media (max-width: 700px) {
  #hydraToolsShell .tools-filter-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    padding: 0 0 6px;
    min-width: 0;
  }

  #hydraToolsShell .tools-filter-bar--pw-mobile {
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
  }

  #hydraToolsShell .tools-filter-bar--pw-mobile .tools-filter-bar__search {
    flex: 0 0 auto;
    width: 100%;
  }

  #hydraToolsShell .tools-filter-bar__actions {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 6px;
    min-width: 0;
    width: 100%;
  }

  #hydraToolsShell .tools-filter-bar__actions .tools-filter-bar__sort {
    flex: 1 1 0;
    min-width: 0;
    height: 38px;
    padding: 0 8px;
    border: 1px solid rgba(249, 115, 22, 0.25);
    border-radius: 10px;
    background: #fff;
    font-size: 12px;
    font-weight: 700;
    color: #0f172a;
  }

  #hydraToolsShell .tools-filter-bar__actions .tools-filter-bar__btn {
    flex: 0 0 auto;
  }

  #hydraToolsShell .tools-filter-bar__actions .hti-view-toggle-row {
    margin-left: 0;
    flex-shrink: 0;
    padding: 0;
  }

  #hydraToolsShell .tools-filter-bar__actions .hti-view-toggle {
    height: 38px;
  }

  #hydraToolsShell .tools-filter-bar__actions .hti-view-seg {
    height: 34px;
    padding: 0 8px;
  }

  #hydraToolsShell .tools-filter-bar__search {
    flex: 1 1 0;
    min-width: 0;
    height: 38px;
    padding: 0 12px;
    border: 1px solid rgba(249, 115, 22, 0.25);
    border-radius: 10px;
    font-size: 14px;
    background: #fff;
    color: #0f172a;
    outline: none;
    box-sizing: border-box;
  }

  #hydraToolsShell .tools-filter-bar__search:focus {
    border-color: #f97316;
    box-shadow: 0 0 0 2px rgba(249, 115, 22, 0.12);
  }

  #hydraToolsShell .tools-filter-bar__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    height: 38px;
    padding: 0 12px;
    border: 1px solid rgba(249, 115, 22, 0.25);
    border-radius: 10px;
    background: #fff;
    color: #64748b;
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
    cursor: pointer;
    flex-shrink: 0;
    -webkit-tap-highlight-color: transparent;
    -webkit-appearance: none;
    appearance: none;
  }

  #hydraToolsShell .tools-filter-bar__btn.has-active {
    border-color: #f97316;
    background: #fff7ed;
    color: #c2410c;
  }

  #hydraToolsShell .tools-filter-bar__btn.is-expanded {
    border-color: #f97316;
    color: #c2410c;
  }

  #hydraToolsShell .tools-filter-bar__dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #f97316;
    flex-shrink: 0;
  }

  #hydraToolsShell .tools-filter-bar__chev {
    width: 7px;
    height: 7px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg);
    flex-shrink: 0;
    transition: transform 0.15s ease;
  }

  #hydraToolsShell .tools-filter-bar__btn.is-expanded .tools-filter-bar__chev {
    transform: rotate(-135deg);
    margin-top: 2px;
  }

  #hydraToolsShell .tools-filter-bar .hti-view-toggle-row {
    padding: 0;
    margin-left: auto;
    flex-shrink: 0;
  }

  #hydraToolsShell .tools-filter-bar .st-select-inline {
    flex-shrink: 0;
  }

  #hydraToolsShell .tools-filter-panel {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 10px;
    margin-top: 6px;
    background: #fff;
    border: 1px solid rgba(15, 23, 42, 0.08);
    border-radius: 14px;
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.08);
  }

  #hydraToolsShell .tools-filter-panel.is-collapsed {
    display: none;
  }

  #hydraToolsShell .tools-filter-panel__row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  #hydraToolsShell .tools-filter-panel__row--single {
    grid-template-columns: 1fr;
  }

  #hydraToolsShell .tools-filter-panel select {
    width: 100%;
    height: 38px;
    padding: 0 8px;
    border: 1px solid rgba(249, 115, 22, 0.2);
    border-radius: 10px;
    font-size: 13px;
    background: #fff;
    color: #0f172a;
    min-width: 0;
  }

  #hydraToolsShell .tools-filter-panel__row--single {
    display: block;
  }

  #hydraToolsShell .tools-filter-panel__row--single select {
    width: 100%;
    height: 38px;
    padding: 0 8px;
    border: 1px solid rgba(249, 115, 22, 0.2);
    border-radius: 10px;
    font-size: 13px;
    background: #fff;
    color: #0f172a;
    min-width: 0;
  }
}

/* ================================================================
   Gallery grid — Hypercat: 3-col mobile (≤900), auto-fill desktop
   Lock 3-col through HYDRA_MOBILE_BP so auto-fill never drops to 2 cols.
   ================================================================ */
#hydraToolsShell .hti-gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  min-width: 0;
  width: 100%;
  box-sizing: border-box;
}

@media (max-width: 900px) {
  #hydraToolsShell .hti-gallery-grid,
  #hydraToolsShell .st-view-host .hti-gallery-grid,
  #hydraToolsShell .st-gallery-host .hti-gallery-grid,
  #hydraToolsShell .pw-gallery-host .hti-gallery-grid,
  #hydraToolsShell .ht-view-host .hti-gallery-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 6px;
  }
}

@media (min-width: 901px) {
  #hydraToolsShell .hti-gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 8px;
  }
}

@media (min-width: 1200px) {
  #hydraToolsShell .hti-gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(155px, 1fr));
    gap: 10px;
  }
}

/* ================================================================
   Gallery card (button — Hypercat mgallery density)
   ================================================================ */
#hydraToolsShell .hti-gallery-card {
  --hti-gallery-info-h: 52px;
  --hti-gallery-title-size: 0.6875rem;
  --hti-gallery-title-lh: 1.2;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  height: 100%;
  min-width: 0;
  width: 100%;
  padding: 0;
  margin: 0;
  border: 1px solid #e8edf4;
  border-radius: 8px;
  background: #fff;
  box-shadow: none;
  text-align: left;
  font: inherit;
  color: inherit;
  cursor: pointer;
  overflow: hidden;
  -webkit-tap-highlight-color: transparent;
  box-sizing: border-box;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.12s ease;
}

#hydraToolsShell .hti-gallery-card:active {
  transform: scale(0.98);
}

#hydraToolsShell .hti-gallery-card.is-active {
  border-color: rgba(249, 115, 22, 0.55);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.14), 0 0 0 2px rgba(249, 115, 22, 0.14);
  transform: translateY(-2px);
}

#hydraToolsShell .hti-gallery-card.is-select-mode {
  cursor: pointer;
}

#hydraToolsShell .hti-gallery-card.is-selected {
  border-color: #f97316;
  box-shadow: 0 0 0 2px rgba(249, 115, 22, 0.18);
}

#hydraToolsShell .st-gallery-select-mark {
  position: absolute;
  z-index: 4;
  top: 5px;
  right: 5px;
  width: 20px;
  height: 20px;
  border: 1.5px solid rgba(71, 85, 105, 0.52);
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 2px 7px rgba(15, 23, 42, 0.12);
  pointer-events: none;
}

#hydraToolsShell .st-gallery-select-mark.is-checked {
  border-color: #f97316;
  background: #f97316;
}

#hydraToolsShell .st-gallery-select-mark.is-checked::after {
  content: "";
  position: absolute;
  left: 6px;
  top: 3px;
  width: 5px;
  height: 9px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

/* ================================================================
   Art / image area — fixed aspect, contain (no crop)
   ================================================================ */
#hydraToolsShell .hti-gallery-art {
  position: relative !important;
  display: grid;
  place-items: center;
  width: 100%;
  aspect-ratio: 0.72 / 1;
  height: auto;
  min-height: 0;
  padding: 6px;
  box-sizing: border-box;
  background: #f8fafc;
  overflow: hidden;
  flex-shrink: 0;
  border-radius: 8px 8px 0 0;
}

#hydraToolsShell .hti-gallery-art__btn {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  padding: 0;
  margin: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}

#hydraToolsShell .hti-gallery-art__img {
  display: block;
  width: 90%;
  height: 94%;
  max-width: 90%;
  max-height: 94%;
  min-width: 0;
  min-height: 0;
  object-fit: contain;
  object-position: center;
  transform-origin: center center;
  transform: scale(var(--hti-gallery-scale, 1));
  pointer-events: none;
}

#hydraToolsShell .hti-gallery-art--empty .hti-gallery-art__fallback,
#hydraToolsShell .hti-gallery-art__fallback {
  width: 48px;
  height: auto;
  aspect-ratio: 0.72 / 1;
  max-width: 50%;
  max-height: 55%;
  min-height: 0;
  border-radius: 4px;
  background: rgba(15, 23, 42, 0.08);
}

/* Grade / condition badge — small floating overlay, top-left of art */
#hydraToolsShell .hti-gallery-cond-badge {
  position: absolute !important;
  left: 4px !important;
  top: 4px !important;
  right: auto !important;
  bottom: auto !important;
  z-index: 2;
  padding: 1px 5px;
  border-radius: 4px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: rgba(255, 255, 255, 0.92);
  color: #0f172a;
  font-size: 9px;
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: 0.01em;
  pointer-events: none;
  /* Leave room for quantity badge on the right (×N). */
  max-width: calc(100% - 44px);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.12);
}

/* Quantity — top-right of art, opposite grade badge */
#hydraToolsShell .hti-gallery-art .st-qty-badge--gallery {
  position: absolute !important;
  right: 4px !important;
  top: 4px !important;
  left: auto !important;
  bottom: auto !important;
  z-index: 2;
  margin: 0 !important;
  padding: 1px 5px;
  border-radius: 4px;
  border: 1px solid rgba(15, 118, 110, 0.25);
  background: rgba(204, 251, 241, 0.95);
  color: #0f766e;
  font-size: 9px;
  font-weight: 800;
  line-height: 1.25;
  pointer-events: none;
  flex-shrink: 0;
  max-width: 40px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.12);
}

/* ================================================================
   Card body — title (≤2 lines) + price only
   ================================================================ */
#hydraToolsShell .hti-gallery-card__body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2px;
  flex: 0 0 var(--hti-gallery-info-h);
  height: var(--hti-gallery-info-h);
  min-height: var(--hti-gallery-info-h);
  max-height: var(--hti-gallery-info-h);
  padding: 4px 5px 5px;
  box-sizing: border-box;
  min-width: 0;
  overflow: hidden;
}

#hydraToolsShell .hti-gallery-card__title {
  margin: 0;
  flex: 0 0 auto;
  font-size: var(--hti-gallery-title-size);
  font-weight: 600;
  line-height: var(--hti-gallery-title-lh);
  color: #0f172a;
  min-width: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  word-break: break-word;
}

#hydraToolsShell .hti-gallery-card__meta,
#hydraToolsShell .hti-gallery-card__badges {
  display: none !important;
}

#hydraToolsShell .hti-gallery-card__money {
  margin: 0;
  flex: 0 0 auto;
  font-size: clamp(10px, 2.7vw, 12px);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
  color: #2563eb;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#hydraToolsShell .hti-gallery-card__money--muted {
  color: #94a3b8;
  font-weight: 600;
}

/* Hit gallery: Raw price never clipped; PSA on own compact line */
#hydraToolsShell .hti-gallery-card--hit {
  --hti-gallery-info-h: 58px;
}

#hydraToolsShell .hti-gallery-card--hit .hti-gallery-card__money {
  overflow: visible;
  text-overflow: clip;
}

#hydraToolsShell .hti-gallery-card--hit .hti-gallery-card__psa {
  margin: 0;
  flex: 0 0 auto;
  font-size: 9px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: #64748b;
  line-height: 1.15;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ---------- Hit toolbar overrides ---------- */
#hydraToolsShell .ht-cards-toolbar__view-toggle {
  margin-left: 0;
  padding: 0;
  justify-content: flex-end;
}

#hydraToolsShell .ht-cards-toolbar__controls {
  flex-wrap: nowrap;
}

/* ================================================================
   Responsive polish
   ================================================================ */

@media (max-width: 360px) {
  #hydraToolsShell .st-gallery-host,
  #hydraToolsShell .pw-gallery-host,
  #hydraToolsShell .st-view-host,
  #hydraToolsShell .ht-view-host {
    padding-left: 8px;
    padding-right: 8px;
  }

  #hydraToolsShell .hti-gallery-grid {
    gap: 5px;
  }

  #hydraToolsShell .hti-gallery-card {
    --hti-gallery-info-h: 50px;
    --hti-gallery-title-size: 0.625rem;
  }

  #hydraToolsShell .hti-gallery-art {
    padding: 5px;
  }
}

/* ================================================================
   Shared list card (Hypercat-inspired)
   Used by Storage / Price Watch / Hit Tool list modes.
   Does NOT touch .hti-gallery-* gallery cards.
   ================================================================ */

#hydraToolsShell .tools-list-wrap {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 6px 12px 12px;
  min-width: 0;
}

#hydraToolsShell .tools-list-card {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  background: #fff;
  border-radius: 14px;
  padding: 8px 10px;
  border: 1px solid rgba(15, 23, 42, 0.06);
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.05);
  min-width: 0;
  text-align: left;
  font: inherit;
  color: inherit;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  -webkit-appearance: none;
  appearance: none;
  box-sizing: border-box;
  transition: box-shadow 0.12s ease;
}

#hydraToolsShell .tools-list-card:not(.tools-list-card--has-thumb) {
  grid-template-columns: minmax(0, 1fr) auto;
}

#hydraToolsShell .tools-list-card:active {
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
}

#hydraToolsShell .tools-list-card.is-active {
  border-color: rgba(249, 115, 22, 0.4);
  box-shadow: 0 0 0 2px rgba(249, 115, 22, 0.12), 0 2px 8px rgba(15, 23, 42, 0.05);
}

#hydraToolsShell .tools-list-card--sold {
  opacity: 0.72;
}

#hydraToolsShell .tools-list-card--selected {
  border-color: rgba(37, 99, 235, 0.35);
  background: #eff6ff;
}

/* ---------- Thumb ---------- */
#hydraToolsShell .tools-list-card .hti-thumb-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  padding: 0;
  margin: 0;
  border: 0;
  border-radius: 10px;
  background: #f3f6f9;
  overflow: hidden;
  cursor: pointer;
  flex-shrink: 0;
  -webkit-appearance: none;
  appearance: none;
}

#hydraToolsShell .tools-list-card .hydra-tool-card__thumb,
#hydraToolsShell .tools-list-card .hti-thumb-img {
  width: 58px;
  height: 58px;
  border-radius: 10px;
  object-fit: contain;
  flex-shrink: 0;
}

#hydraToolsShell .tools-list-thumb-empty {
  width: 58px;
  height: 58px;
  border-radius: 10px;
  background: linear-gradient(145deg, #f1f5f9 0%, #e2e8f0 100%);
  flex-shrink: 0;
}

/* ---------- Main ---------- */
#hydraToolsShell .tools-list-main {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

#hydraToolsShell .tools-list-title {
  font-size: 13px;
  line-height: 1.18;
  font-weight: 850;
  color: #071225;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-width: 0;
}

#hydraToolsShell button.tools-list-title--action {
  appearance: none;
  -webkit-appearance: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  text-align: left;
  width: 100%;
  max-width: 100%;
  cursor: pointer;
  font: inherit;
  color: inherit;
}

#hydraToolsShell .tools-list-rank {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 16px;
  padding: 0 4px;
  border-radius: 4px;
  background: #f1f5f9;
  color: #64748b;
  font-size: 9px;
  font-weight: 800;
  line-height: 1;
  vertical-align: middle;
  margin-right: 4px;
  flex-shrink: 0;
}

#hydraToolsShell .tools-list-meta {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: nowrap;
  overflow: hidden;
  min-width: 0;
  margin-top: 1px;
}

#hydraToolsShell .tools-list-meta .st-badge,
#hydraToolsShell .tools-list-meta .pw-badge,
#hydraToolsShell .tools-list-meta .ht-cat-badge {
  flex-shrink: 0;
  height: 16px;
  padding: 0 5px;
  font-size: 8px;
  border-radius: 4px;
  line-height: 16px;
  white-space: nowrap;
}

#hydraToolsShell .tools-list-meta-text {
  font-size: 10px;
  color: #64748b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

#hydraToolsShell .tools-list-stats {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 2px;
  min-width: 0;
}

#hydraToolsShell .tools-list-stat {
  font-size: 10px;
  color: #64748b;
  white-space: nowrap;
  line-height: 1.2;
}

#hydraToolsShell .tools-list-stat b,
#hydraToolsShell .tools-list-stat strong {
  font-weight: 800;
  color: #0f172a;
}

#hydraToolsShell .tools-list-stat .st-profit-up,
#hydraToolsShell .tools-list-stat .pw-up,
#hydraToolsShell .tools-list-stat .pw-card__pct--ath {
  color: #15803d;
}

#hydraToolsShell .tools-list-stat .st-profit-down,
#hydraToolsShell .tools-list-stat .pw-down,
#hydraToolsShell .tools-list-stat .pw-card__pct--down {
  color: #dc2626;
}

#hydraToolsShell .tools-list-stat .pw-card__pct--warn {
  color: #a16207;
}

/* ---------- Side ---------- */
#hydraToolsShell .tools-list-side {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
  flex-shrink: 0;
}

#hydraToolsShell .tools-list-price {
  font-size: 13px;
  font-weight: 850;
  font-variant-numeric: tabular-nums;
  color: #2563eb;
  white-space: nowrap;
  line-height: 1.15;
}

#hydraToolsShell .tools-list-price--muted {
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
}

#hydraToolsShell .tools-list-sub-price {
  font-size: 10px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: #64748b;
  white-space: nowrap;
  line-height: 1.15;
}

#hydraToolsShell .tools-list-menu {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  min-width: 28px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #94a3b8;
  font-size: 16px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  padding: 0;
  line-height: 1;
  -webkit-appearance: none;
  appearance: none;
}

#hydraToolsShell .tools-list-menu:active {
  background: #f1f5f9;
}

/* ---------- Select mode ---------- */
#hydraToolsShell .tools-list-card .tools-list-check {
  display: none;
}

#hydraToolsShell .tools-list-card--select-mode .tools-list-check {
  display: flex;
  align-items: center;
}

#hydraToolsShell .tools-list-card--select-mode {
  grid-template-columns: 24px 58px minmax(0, 1fr) auto;
}

#hydraToolsShell .tools-list-card--select-mode:not(.tools-list-card--has-thumb) {
  grid-template-columns: 24px minmax(0, 1fr) auto;
}

/* ---------- Hit set-group spacing ---------- */
#hydraToolsShell .ht-set-group__body .tools-list-card {
  margin-bottom: 6px;
}

#hydraToolsShell .ht-set-group__body .tools-list-card:last-child {
  margin-bottom: 0;
}

/* ---------- PW menu inside tools-list-side ---------- */
#hydraToolsShell .tools-list-side .pw-actions {
  display: flex;
}

#hydraToolsShell .tools-list-side .pw-row-menu-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  min-width: 28px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #94a3b8;
  font-size: 16px;
  cursor: pointer;
  padding: 0;
  line-height: 1;
  -webkit-appearance: none;
  appearance: none;
}

#hydraToolsShell .tools-list-side .pw-row-menu-btn:active {
  background: #f1f5f9;
}

/* ---------- Responsive ---------- */
@media (max-width: 360px) {
  #hydraToolsShell .tools-list-card {
    gap: 8px;
    padding: 7px 8px;
  }
  #hydraToolsShell .tools-list-card .hti-thumb-btn,
  #hydraToolsShell .tools-list-card .hydra-tool-card__thumb,
  #hydraToolsShell .tools-list-card .hti-thumb-img,
  #hydraToolsShell .tools-list-thumb-empty {
    width: 52px;
    height: 52px;
  }
  #hydraToolsShell .tools-list-card:not(.tools-list-card--has-thumb) {
    grid-template-columns: minmax(0, 1fr) auto;
  }
  #hydraToolsShell .tools-list-card.tools-list-card--has-thumb {
    grid-template-columns: 52px minmax(0, 1fr) auto;
  }
  #hydraToolsShell .tools-list-title {
    font-size: 12px;
  }
  #hydraToolsShell .tools-list-price {
    font-size: 12px;
  }
}
