.market-automotive-gallery .jam-home-top { display: none !important; }
.market-gallery-search, .market-gallery-workspace { box-sizing: border-box; direction: rtl; width: 100%; min-width: 0; }
.market-gallery-search { margin: 8px 0 12px; color: #0c1430; }
.market-gallery-tabs { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); width: min(100%,580px); gap: 4px; padding: 4px 5px 0; border-radius: 12px 12px 0 0; background: #e6edf7; }
.market-gallery-tabs a {
  display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 43px;
  border-radius: 8px 8px 0 0; background: #f8fbff; color: #14223a; font-weight: 700; text-decoration: none;
}
.market-gallery-tabs a[aria-current], .market-gallery-submit {
  background: linear-gradient(180deg,#ff8200,#ff4b00); color: #fff;
}
.market-gallery-search svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.65; stroke-linecap: round; stroke-linejoin: round; flex: none; }
#market-gallery-search {
  display: flex; align-items: end; gap: 10px; min-width: 0; padding: 10px;
  background: #f8fafc; border: 1px solid #dce4ee; border-radius: 10px; box-shadow: 0 2px 8px #091c3510;
}
.market-gallery-keyword { display: grid; gap: 4px; flex: 1; min-width: 0; font-weight: 700; }
.market-gallery-search input, .market-gallery-sidebar input:not([type="checkbox"]), .market-gallery-sidebar select {
  box-sizing: border-box; width: 100%; min-width: 0; min-height: 36px; padding: 5px 8px;
  border: 1px solid #ced8e8; border-radius: 7px; background: #fff; color: #172443; font: inherit;
}
.market-gallery-submit {
  display: inline-flex; align-items: center; justify-content: center; gap: 5px; border: 0; border-radius: 8px;
  min-height: 36px; padding: 6px 14px; font: inherit; font-weight: 700; cursor: pointer; white-space: nowrap;
}
.market-gallery-workspace { display: grid; grid-template-columns: minmax(0,1fr); gap: 9px; align-items: start; padding-bottom: 12px; }
.market-gallery-results { width: 100%; min-width: 0; }
.market-gallery-sidebar {
  display: grid; gap: 7px; align-items: start; min-width: 0; padding: 10px; border: 1px solid #dce4ee;
  border-radius: 10px; background: #fff; color: #14223a; font-size: 13px;
}
.market-gallery-sidebar-head { display: flex; justify-content: space-between; align-items: center; }
.market-gallery-sidebar-head h2 { margin: 0; font-size: 17px; }
.market-gallery-sidebar-head a { color: #9f3800; text-decoration: underline; }
.market-gallery-sidebar label { display: grid; gap: 2px; min-width: 0; }
.market-gallery-sidebar fieldset { min-width: 0; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 5px; padding: 4px 6px 6px; margin: 0; border: 1px solid #e1e7f0; border-radius: 7px; }
.market-gallery-sidebar legend { padding-inline: 4px; font-weight: 700; }
.market-gallery-sidebar fieldset:has(.market-gallery-check) { grid-template-columns: 1fr; }
.market-gallery-sidebar .market-gallery-check { display: flex; gap: 5px; align-items: center; }
.market-gallery-sidebar input[type="checkbox"] { accent-color: #b84300; flex: none; margin: 0; }
.market-gallery-sidebar .market-gallery-submit { position: sticky; bottom: 0; }
@media (min-width: 901px) {
  /* The shared landing section has a fixed desktop width cap. This gallery
     distributes the viewport between the sidebar and the two result views. */
  html body .market-automotive-gallery > #featured {
    box-sizing: border-box;
    width: 98%;
    max-width: none;
    margin-inline: auto;
    padding-inline: 0;
  }
  .market-gallery-tabs { width: 40%; }
  .market-gallery-workspace {
    grid-template-columns: 18% minmax(0,1fr);
    column-gap: 1%;
  }
  .market-gallery-sidebar { position: sticky; top: 8px; max-height: calc(100dvh - 90px); overflow: auto; scrollbar-width: thin; }
}
@media (max-width: 900px) {
  .market-gallery-sidebar { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .market-gallery-sidebar-head, .market-gallery-sidebar fieldset, .market-gallery-sidebar .market-gallery-submit { grid-column: 1/-1; }
  .market-gallery-sidebar fieldset:has(.market-gallery-check) { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .market-gallery-sidebar .market-gallery-submit { position: static; }
}
@media (max-width: 420px) {
  .market-gallery-tabs a { font-size: 12px; }
  .market-gallery-search .market-gallery-submit { padding-inline: 7px; }
}
