/* Marketplace public UI — white, dense rows, RTL */
body.bm-app {
  background: #fff;
  color: #141414;
}
body.bm-app .floating-cta { display: none; }
body.bm-app .site-header {
  background: #fff !important;
  border-bottom: 1px solid #eee;
  box-shadow: none !important;
  position: sticky;
  top: 0;
  z-index: 40;
}
body.bm-app .site-footer {
  background: #fafafa;
  color: #444;
  border-top: 1px solid #eee;
}

.bm-header-inner {
  display: flex;
  align-items: center;
  min-height: 64px;
  gap: 16px;
}
.bm-desk-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  align-items: center;
  flex: 1;
}
.bm-desk-nav a {
  color: #222;
  text-decoration: none;
  font-weight: 650;
  font-size: 14px;
  padding: 6px 2px;
  font-family: Vazirmatn, sans-serif;
}
.bm-desk-nav a:hover { color: #111; }
.bm-wordmark {
  font-weight: 900;
  font-size: 20px;
  letter-spacing: -0.03em;
  color: #111;
  text-decoration: none;
  white-space: nowrap;
}
.bm-menu { display: none; }
.bm-tools {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 8px;
}
.bm-icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  border: 1px solid #ececec;
  background: #f6f6f6;
  color: #222;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  cursor: pointer;
}
.bm-post {
  background: #c6f221;
  color: #111;
  text-decoration: none;
  font-weight: 800;
  border-radius: 999px;
  padding: 10px 16px;
  font-size: 14px;
}
.bm-post:hover { background: #befa00; }
.bm-burger { display: none; }
.bm-header-search { padding: 0 0 12px; }
.bm-header-search input {
  width: 100%;
  border: 0;
  background: #f3f4f6;
  border-radius: 14px;
  padding: 12px 16px;
  font: inherit;
}

.bm-hero { padding: 18px 0 0; text-align: center; }
.bm-hero h1 {
  margin: 0 0 14px;
  font-size: clamp(26px, 4vw, 36px);
  font-weight: 900;
}
.bm-search {
  max-width: 760px;
  margin: 0 auto 22px;
  background: #f3f4f6;
  border-radius: 18px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  color: #888;
}
.bm-search input {
  flex: 1;
  border: 0;
  background: transparent;
  padding: 12px 4px;
  font: inherit;
  font-size: 15px;
  outline: none;
  color: #111;
}
.bm-cats {
  display: flex;
  justify-content: center;
  gap: 18px;
  margin: 8px 0 18px;
}
.bm-cat {
  text-decoration: none;
  color: #333;
  font-size: 13px;
  font-weight: 700;
  min-width: 84px;
  padding: 16px 10px;
  border-radius: 16px;
  background: #f7f7f8;
}
.bm-cat-on { background: #1d2433; color: #fff; }

.bm-board { padding: 8px 0 48px; }
.bm-board-head, .bm-list-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}
.bm-board-head h2, .bm-list-head h1 { margin: 0; font-size: 20px; font-weight: 800; }
.bm-board-head a { color: #333; font-size: 14px; }
.bm-crumb { color: #999; font-size: 13px; margin-bottom: 12px; display: flex; gap: 6px; }
.bm-crumb a { color: #666; text-decoration: none; }
.bm-sort select {
  border: 1px solid #e5e5e5;
  background: #fff;
  border-radius: 12px;
  padding: 8px 12px;
  font: inherit;
}

.bm-rows { min-width: 0; }
.bm-row a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid #ececec;
  text-decoration: none;
  color: inherit;
}
.bm-row:first-child a { border-top: 1px solid #ececec; }
.bm-photo {
  width: 168px;
  height: 112px;
  flex: 0 0 168px;
  border-radius: 12px;
  overflow: hidden;
  background: #f2f2f2;
}
.bm-photo img, .bm-gallery > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.bm-mid { flex: 1; min-width: 0; text-align: right; }
.bm-mid h3, .bm-card h1 {
  margin: 0 0 2px;
  font-size: 15px;
  font-weight: 800;
  color: #111;
}
.bm-meta { margin: 0; color: #8b9098; font-size: 12.5px; line-height: 1.5; }
.bm-loc { margin: 0; color: #a0a4ab; font-size: 12.5px; }
.bm-price, .bm-detail-price {
  margin-inline-start: auto;
  color: #111;
  font-weight: 800;
  white-space: nowrap;
  font-size: 15px;
  text-align: left;
}
.bm-price small, .bm-detail-price small { font-weight: 600; color: #666; font-size: 12px; }
.bm-empty { color: #888; padding: 24px 0; }

.bm-list-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 28px;
  align-items: start;
}
.bm-filters {
  border: 1px solid #e6e6e6;
  background: #fafafa;
  border-radius: 16px;
  padding: 16px;
  position: sticky;
  top: 84px;
}
.bm-filters-top { display: flex; justify-content: space-between; align-items: center; }
.bm-filters h2 { margin: 0; font-size: 16px; }
.bm-filters h3 { margin: 16px 0 10px; font-size: 14px; }
.bm-filters-top a { font-size: 12px; color: #555; }
.bm-brand-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}
.bm-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  text-decoration: none;
  color: #333;
  font-size: 11px;
  text-align: center;
}
.bm-brand span {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #fff;
  border: 1px solid #e5e5e5;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 12px;
}
.bm-brand.is-on span { border-color: #111; background: #111; color: #fff; }
.bm-brand-grid .bm-extra, .bm-chips .bm-extra { display: none; }
.bm-brand-grid.is-all .bm-extra, .bm-chips.is-all .bm-extra { display: flex; }
.bm-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.bm-chip {
  background: #ececec;
  color: #333;
  text-decoration: none;
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 13px;
}
.bm-chip.is-on { background: #1d2433; color: #fff; }
.bm-outline {
  display: block;
  width: 100%;
  margin-top: 12px;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 12px;
  padding: 10px;
  font: inherit;
  cursor: pointer;
}
.bm-filter-toggle { display: none; margin-bottom: 12px; }

.bm-detail {
  display: grid;
  grid-template-columns: minmax(260px, 380px) minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}
.bm-card {
  background: #f7f7f8;
  border-radius: 18px;
  padding: 18px;
}
.bm-card h1 { font-size: 22px; }
.bm-detail-price { font-size: 22px; margin: 14px 0; }
.bm-specs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 8px 0 12px;
}
.bm-specs div {
  background: #fff;
  border-radius: 12px;
  padding: 8px 10px;
}
.bm-specs span { display: block; color: #999; font-size: 11px; }
.bm-specs strong { font-size: 13px; }
.bm-call, .bm-wa {
  display: block;
  text-align: center;
  text-decoration: none;
  border-radius: 14px;
  padding: 12px;
  font-weight: 800;
  margin-top: 8px;
}
.bm-call { background: #c6f221; color: #111; }
.bm-wa { background: #fff; color: #111; border: 1px solid #ddd; }
.bm-gallery > img, #mainImage {
  width: 100%;
  height: 420px;
  max-height: 420px;
  object-fit: cover;
  object-position: center;
  border-radius: 16px;
  background: #eee;
}
.bm-thumbs { display: flex; gap: 8px; margin-top: 8px; }
.bm-thumbs button { border: 0; padding: 0; background: none; cursor: pointer; }
.bm-thumbs img { width: 72px; height: 54px; object-fit: cover; border-radius: 8px; }
.bm-desc { margin-top: 18px; }
.bm-desc h2 { font-size: 16px; margin: 0 0 8px; }
.bm-desc p { margin: 0; color: #444; line-height: 1.8; }
.bm-photo-empty {
  display: grid;
  place-items: center;
  height: 100%;
  color: #999;
  font-size: 13px;
}
.bm-pager { display: flex; gap: 12px; padding: 16px 0; }
.bm-pager a { color: #111; }

@media (max-width: 860px) {
  .bm-desk-nav, .bm-desk-only { display: none; }
  .bm-burger { display: inline-flex; }
  .bm-wordmark { font-size: 18px; }
  .bm-menu {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 80;
    background: #fff;
    color: #111;
    font-family: Vazirmatn, sans-serif;
    padding: 12px 18px 28px;
    overflow: auto;
  }
  .bm-menu.is-open { display: block; }
  .bm-menu-bar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
  .bm-menu-close {
    border: 0;
    background: #c6f221;
    color: #111;
    font: inherit;
    font-weight: 800;
    border-radius: 999px;
    padding: 12px 18px;
    cursor: pointer;
  }
  .bm-menu nav { display: flex; flex-direction: column; }
  .bm-menu a {
    display: block;
    padding: 16px 4px;
    font-size: 20px;
    font-weight: 700;
    color: #111;
    text-decoration: none;
    border-bottom: 1px solid #f0f0f0;
  }
  .bm-menu a:active { color: #5a7300; }
  .bm-list-layout, .bm-detail { grid-template-columns: 1fr; }
  .bm-filters { display: none; position: static; }
  .bm-filters.is-open { display: block; }
  .bm-filter-toggle { display: block; }
  .bm-row a { flex-wrap: wrap; }
  .bm-photo { width: 100%; flex-basis: 100%; height: 200px; }
  .bm-price { width: 100%; }
}

.bm-foot {
  border-top: 1px solid #eee;
  padding: 16px 0 22px;
  color: #666;
  font-size: 13px;
}
.bm-foot .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.bm-foot span { font-weight: 800; color: #111; }
.bm-foot nav { display: flex; gap: 14px; flex-wrap: wrap; }
.bm-foot a { color: #555; text-decoration: none; }

.bm-page { padding: 28px 0 56px; }
.bm-page h1, .bm-narrow h1 { margin: 0 0 8px; font-size: 28px; font-weight: 900; }
.bm-lead { color: #666; line-height: 1.9; margin: 0 0 18px; }
.bm-narrow { max-width: 480px; }
.bm-form-wide { max-width: 760px; }
.bm-center { text-align: center; }
.bm-center .bm-post { display: inline-block; margin-top: 8px; }
.bm-note { margin-top: 14px; color: #555; }
.bm-note a, .bm-prose a, .bm-card a { color: #111; }

.bm-form label, .bm-install label, .bm-compare-picks label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 12px;
}
body.bm-app .bm-form input,
body.bm-app .bm-form select,
body.bm-app .bm-form textarea,
body.bm-app .bm-install input,
body.bm-app .bm-compare-picks select {
  width: 100%;
  border: 1px solid #e6e6e6;
  background: #f7f7f8;
  border-radius: 12px;
  padding: 10px 12px;
  font: inherit;
  font-weight: 500;
}
.bm-form-row, .bm-install .bm-form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.bm-form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
.bm-span { grid-column: 1 / -1; }
.bm-err { color: #a33; font-weight: 600; font-size: 12px; }
.bm-check { display: flex; align-items: center; gap: 8px; font-weight: 700; }
.bm-post { border: 0; cursor: pointer; }

.bm-split { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(240px, 360px); gap: 22px; align-items: start; }
.bm-points { margin: 0; padding: 0 18px 0 0; line-height: 2; color: #333; }
.bm-map { width: 100%; height: 180px; border: 0; border-radius: 12px; margin-top: 8px; background: #f3f3f3; }
.bm-faq details { border-bottom: 1px solid #eee; padding: 12px 0; }
.bm-faq summary { cursor: pointer; font-weight: 800; }
.bm-faq details div { color: #444; line-height: 1.9; margin-top: 8px; }

.bm-compare-picks { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 12px 0 18px; }
.bm-table-wrap { overflow-x: auto; }
.bm-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.bm-table th, .bm-table td { border-bottom: 1px solid #eee; padding: 10px 8px; text-align: right; }
.bm-table th a { color: #111; }
.bm-ads { display: flex; flex-direction: column; }
.bm-ad { display: flex; align-items: center; gap: 12px; padding: 14px 0; border-bottom: 1px solid #eee; }
.bm-ad .bm-price { margin-inline-start: auto; }

.bm-shortcuts { max-width: 760px; margin: 0 auto 8px; display: grid; gap: 8px; text-align: right; }
.bm-shortcuts div { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: center; }
.bm-shortcuts span { color: #999; font-size: 12px; }
.bm-shortcuts a {
  text-decoration: none;
  background: #f3f4f6;
  color: #222;
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 700;
}

.bm-name-grid { display: grid; grid-template-columns: 1fr; gap: 6px; }
.bm-name-grid a {
  display: block;
  background: #fff;
  border: 1px solid #e5e5e5;
  border-radius: 10px;
  padding: 8px 10px;
  text-align: right;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-decoration: none;
  color: #222;
  font-size: 13px;
  font-weight: 700;
}
.bm-name-grid a.is-on { background: #1d2433; color: #fff; border-color: #1d2433; }
.bm-name-grid .bm-extra { display: none; }
.bm-name-grid.is-all .bm-extra { display: block; }

.bm-detail .bm-card { position: sticky; top: 84px; }
.bm-similar { margin-top: 28px; }
.bm-similar h2, .bm-install h2, .bm-desc h2 { font-size: 16px; margin: 0 0 8px; }
.bm-install { margin-top: 16px; padding-top: 8px; }

@media (max-width: 860px) {
  .bm-split, .bm-form-row, .bm-form-grid, .bm-compare-picks, .bm-install .bm-form-row { grid-template-columns: 1fr; }
  .bm-detail .bm-card { position: static; }
  .bm-foot .container { justify-content: flex-start; }
}

.bm-price .bm-row-actions { display: flex; gap: 6px; margin-top: 6px; justify-content: flex-end; }
.bm-row-actions button {
  border: 1px solid #e5e5e5;
  background: #fff;
  border-radius: 999px;
  padding: 4px 10px;
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}
.bm-row-actions button.active { background: #c6f221; border-color: #c6f221; font-weight: 800; }
.bm-filter-form { display: grid; gap: 8px; margin-top: 16px; }
.bm-filter-form label { display: grid; gap: 4px; font-size: 13px; color: #444; }
.bm-filter-form input, .bm-filter-form select {
  border: 1px solid #e5e5e5;
  border-radius: 10px;
  padding: 8px 10px;
  font: inherit;
  width: 100%;
}
.bm-reveal .bm-call { display: inline-flex; }
