/* چیپ‌ها، شبکه و کارت محصول، صفحه محصول */
.products-panel { margin-top: 40px; scroll-margin-top: calc(var(--header-h) + 16px); outline: none; }
.products-panel.is-loading { opacity: .5; transition: opacity .2s; }
.results__head { margin-bottom: 22px; }
.results__title { font-size: 1.5rem; }
.empty { text-align: center; color: var(--muted); padding: 48px 16px; background: var(--surface); border: 1px dashed var(--border); border-radius: var(--radius); }

.chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px; }
.chip {
  display: inline-flex; align-items: center; min-height: 44px; padding: 6px 20px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--border); color: var(--navy); font-weight: 600; text-decoration: none !important;
  transition: background .2s var(--ease), color .2s var(--ease), border-color .2s var(--ease), transform .12s var(--ease);
}
.chip:hover { border-color: var(--navy); }
.chip:active { transform: scale(.97); }
.chip.is-active { background: var(--navy); color: #fff; border-color: var(--navy); }
.chip--lg { min-height: 48px; padding-inline: 26px; }

.product-grid { display: grid; gap: 22px; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.product-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow);
  overflow: hidden; transition: transform .25s var(--ease), box-shadow .25s var(--ease), border-color .25s var(--ease);
}
.product-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); border-color: #c5d2e6; }
.product-card__link { display: flex; flex-direction: column; height: 100%; color: inherit; text-decoration: none !important; }
.product-card__media { aspect-ratio: 4 / 3; background: #fff; border-bottom: 1px solid var(--border); padding: 12px; display: grid; place-items: center; }
.product-card__media img { width: 100%; height: 100%; object-fit: contain; }
.product-card__body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.product-card__title { font-size: 1.02rem; margin: 0; color: var(--text); }
.product-card__price { margin: 0; color: var(--navy); font-size: 1rem; font-weight: 800; line-height: 1.7; }
.product-card__price--none { color: var(--muted); font-weight: 600; font-size: .9rem; }
.price-unit { font-size: .8em; font-weight: 600; color: var(--muted); }
.product-card__cue { margin-top: auto; padding-top: 6px; display: inline-flex; align-items: center; gap: 4px; color: var(--navy); font-size: .9rem; font-weight: 600; }
.product-card__cue svg { transition: transform .25s var(--ease); }
.product-card:hover .product-card__cue svg { transform: translateX(-4px); }

.pagination { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 32px; }
.pagination__link {
  min-height: 44px; min-width: 80px; display: inline-flex; align-items: center; justify-content: center; padding: 6px 18px;
  border: 1px solid var(--border); background: var(--surface); border-radius: 10px; color: var(--navy); font-weight: 600; text-decoration: none !important;
}
.pagination__link:hover { border-color: var(--navy); }
.pagination__link.is-disabled { color: var(--muted); opacity: .55; }
.pagination__info { color: var(--muted); font-size: .92rem; }

.breadcrumbs { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: .92rem; color: var(--muted); margin-bottom: 24px; }
.breadcrumbs a { color: var(--muted); }
.breadcrumbs a:hover { color: var(--navy); }
.breadcrumbs [aria-current] { color: var(--text); }

/* صفحه محصول: تصویر، نام (زیر تصویر)، توضیحات */
.product-page { max-width: 880px; }
.product-page__figure {
  margin: 0 0 22px; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 20px; display: grid; place-items: center;
}
.product-page__figure img { max-height: 520px; width: auto; max-width: 100%; object-fit: contain; }
.product-gallery { margin-bottom: 20px; }
.product-gallery__thumbs { list-style: none; margin: 12px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.product-gallery__thumb {
  display: block; width: 76px; height: 76px; padding: 4px; background: var(--surface);
  border: 2px solid var(--border); border-radius: 10px; overflow: hidden; cursor: pointer;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.product-gallery__thumb img { width: 100%; height: 100%; object-fit: contain; display: block; }
.product-gallery__thumb:hover { border-color: var(--navy); }
.product-gallery__thumb:focus-visible { outline: 2px solid var(--navy); outline-offset: 2px; }
.product-gallery__thumb.is-active { border-color: var(--navy); box-shadow: var(--shadow); }
@media (max-width: 480px) { .product-gallery__thumb { width: 60px; height: 60px; } }
.product-page__title { font-size: clamp(1.4rem, 1.1rem + 1.2vw, 2rem); font-weight: 800; margin-bottom: .3em; }
.product-page__category { color: var(--muted); }
.price-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 18px 0 20px; padding: 14px 22px;
  background: var(--surface); border: 1px solid var(--border); border-inline-start: 4px solid var(--navy);
  border-radius: var(--radius); box-shadow: var(--shadow);
}
.price-bar__label { color: var(--muted); font-weight: 600; }
.price-bar__value { color: var(--navy); font-size: clamp(1.15rem, 1rem + .8vw, 1.5rem); font-weight: 800; }
.price-bar--none .price-bar__value { color: var(--muted); font-size: 1rem; font-weight: 600; }
.product-page__description { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px 22px; margin-bottom: 28px; overflow-wrap: anywhere; }
.product-page__description > :last-child { margin-bottom: 0; }
.related { margin-top: 56px; }
.related h2 { font-size: 1.25rem; margin-bottom: 18px; }

@media (max-width: 700px) {
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
  .product-card__body { padding: 10px 12px 12px; }
  .product-card__title { font-size: .95rem; }
  .product-page__figure { padding: 12px; }
}
@media (max-width: 380px) { .product-grid { grid-template-columns: 1fr; } }
