/* Product filters share the same controls in the catalog and each store. */
.catalog-layout.catalog-reference {
  grid-template-columns: 284px minmax(0, 1fr);
  gap: 24px;
}
.catalog-reference .filters {
  position: sticky;
  top: 20px;
  min-width: 0;
  border: 0;
  background: transparent;
}
.filter-panel {
  position: static;
  inset: auto;
  width: 100%;
  max-width: none;
  max-height: calc(100dvh - 40px);
  margin: 0;
  padding: 0;
  border: 1px solid #dce7fa;
  border-radius: 19px;
  background: #fff;
  color: var(--navy);
  box-shadow: 0 8px 28px #1542a008;
  overflow: hidden;
}
.filter-panel[open] { display: flex; flex-direction: column; }
.filter-panel-heading {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 20px 18px 18px;
  border-bottom: 1px solid #e9effa;
  flex-shrink: 0;
}
.filter-heading-icon {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 37px;
  height: 39px;
  background: #edf4ff;
  color: var(--commerce);
  border-radius: 11px;
}
.catalog-reference .filters .filter-panel-heading h2 {
  font-size: 16px;
  line-height: 1.3;
  letter-spacing: -.02em;
  padding: 0;
  margin: 0;
  border: 0;
}
.filter-panel-heading p {
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.4;
}
.filter-count {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  min-width: 24px;
  height: 24px;
  padding-inline: 5px;
  margin-left: auto;
  background: var(--commerce);
  border-radius: 8px;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
}
.filter-close { display: none; }
.catalog-reference .filters form {
  position: static;
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  background: transparent;
  overflow: hidden;
}
.filter-panel-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: #bfcfee transparent;
  padding: 18px;
}
.catalog-reference .filters .filter-query > label {
  display: block;
  margin: 0 0 8px;
  color: var(--navy);
  font-size: 12px;
  font-weight: 650;
}
.filter-query > div {
  display: flex;
  align-items: center;
  gap: 7px;
  height: 42px;
  padding-inline: 10px;
  border: 1px solid #d6e3f7;
  border-radius: 10px;
  background: #fbfdff;
}
.filter-query > div:focus-within { border-color: var(--commerce); box-shadow: 0 0 0 3px #0058ff0d; }
.filter-query .icon { width: 17px; height: 17px; color: #7187ad; }
.filter-query input {
  flex: 1;
  width: 80px;
  height: 100%;
  min-width: 0;
  padding: 0;
  border: 0;
  outline-offset: 2px;
  border-radius: 5px;
  background: transparent;
  color: var(--navy);
  font-size: 12px;
}
.filter-query input::placeholder { color: #7183a1; }
.filter-group { border-bottom: 1px solid #e9eff8; padding-block: 14px; }
.filter-group:last-of-type { border-bottom: 0; padding-bottom: 2px; }
.filter-group summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 28px;
  list-style: none;
  cursor: pointer;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 700;
}
.filter-group summary::-webkit-details-marker { display: none; }
.filter-group summary > span { display: flex; align-items: center; gap: 8px; }
.filter-group summary > span .icon { color: var(--commerce); width: 18px; height: 18px; }
.filter-group summary > .icon { width: 15px; height: 15px; color: #647caa; transition: transform .15s ease; }
.filter-group[open] summary > .icon { transform: rotate(180deg); }
.filter-group fieldset { min-width: 0; margin: 10px 0 0; padding: 0; border: 0; }
.catalog-reference .filters .filter-group select {
  width: 100%;
  height: 43px;
  margin-top: 10px;
  padding-inline: 10px;
  border-color: #d1e0f7;
  border-radius: 10px;
  background: #fff;
  color: var(--navy);
  font-size: 12px;
}
.filter-choices { display: flex; flex-wrap: wrap; gap: 7px; }
.filter-choices-categories { display: grid; grid-template-columns: 1fr; gap: 4px; max-height: 315px; overflow-y: auto; scrollbar-width: thin; }
.catalog-reference .filters .filter-choice {
  position: relative;
  display: block;
  grid-row: auto;
  grid-column: auto;
  min-width: 0;
  margin: 0;
  cursor: pointer;
  font-size: 12px;
  font-weight: 500;
}
.catalog-reference .filters .filter-choice input[type=radio] {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  opacity: 0;
  cursor: pointer;
}
.filter-choice-content {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 38px;
  padding: 8px 12px;
  border: 1px solid #dce6f6;
  border-radius: 9px;
  background: #fff;
  color: #40577f;
  line-height: 1.3;
}
.filter-choice:hover .filter-choice-content { border-color: #9abaff; background: #f6f9ff; }
.filter-choice:has(input:checked) .filter-choice-content { color: #fff; background: var(--commerce); border-color: var(--commerce); font-weight: 650; }
.filter-choice:has(input:focus-visible) .filter-choice-content { outline: 3px solid #154aa6; outline-offset: 3px; }
.filter-choices-categories .filter-choice-content { justify-content: flex-start; padding: 9px 10px; min-height: 40px; border-color: transparent; }
.filter-choices-categories .filter-choice-content > .icon:first-child { width: 19px; height: 19px; color: #7183a6; }
.filter-choices-categories .filter-choice:has(input:checked) .filter-choice-content { color: var(--commerce); background: #edf4ff; border-color: #c1d6ff; }
.filter-choices-categories .filter-choice:has(input:checked) .filter-choice-content > .icon { color: var(--commerce); }
.filter-choice-check { width: 15px; height: 15px; margin-left: auto; opacity: 0; }
.filter-choice:has(input:checked) .filter-choice-check { opacity: 1; }
.filter-swatch { width: 15px; height: 15px; flex-shrink: 0; border: 1px solid #ffffffa0; border-radius: 50%; box-shadow: 0 0 0 1px #15335a24; }
.swatch-blue { background: #1859e5; }.swatch-sky { background: #70c7ed; }.swatch-green { background: #32945d; }
.swatch-red { background: #dc4545; }.swatch-pink { background: #e8a0bd; }.swatch-yellow { background: #f5ce4b; }
.swatch-orange { background: #fa9c39; }.swatch-black { background: #272b36; }.swatch-white { background: #fff; }
.swatch-gray { background: #989ea9; }.swatch-purple { background: #9361bd; }.swatch-beige { background: #dfc7a5; }
.swatch-brown { background: #966849; }.swatch-unknown { background: repeating-linear-gradient(135deg,#e1e7f0 0 3px,#fff 3px 6px); }
.filter-panel-actions { padding: 16px 18px; flex-shrink: 0; border-top: 1px solid #e2eafa; background: #fff; box-shadow: 0 -5px 18px #17377803; }
.catalog-reference .filters .filter-panel-actions .button { margin: 0; min-height: 44px; border-radius: 10px; background: var(--commerce); border-color: var(--commerce); }
.catalog-reference .filters .filter-panel-actions .button:hover { background: var(--commerce-dark); }
.catalog-reference .filters .filter-panel-actions .button > .icon { width: 18px; height: 18px; }
.catalog-reference .filters .clear-filter { margin: 9px 0 0; padding: 6px 0; font-size: 12px; font-weight: 500; }
.filter-draft-note { display: flex; align-items: center; gap: 6px; font-size: 11px; color: #9b5c00; margin: 0 0 10px; }
.filter-draft-note:before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: #f59b18; }
.filter-draft-note[hidden] { display: none; }
.active-filter-bar { padding: 15px 17px; margin-bottom: 18px; background: #ffffffd9; border: 1px solid #e0eafa; border-radius: 15px; }
.active-filter-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 11px; }
.active-filter-heading > span { display: flex; align-items: center; gap: 7px; font-size: 12px; font-weight: 650; }
.active-filter-heading .icon { width: 17px; height: 17px; color: var(--commerce); }
.active-filter-heading b { display: grid; place-items: center; min-width: 20px; height: 20px; border-radius: 6px; background: #e8f0ff; color: var(--commerce); font-size: 11px; }
.active-filter-heading > a { color: #526d9e; font-size: 11px; text-decoration: underline; text-underline-offset: 3px; }
.catalog-reference .applied-filters { gap: 8px; margin: 0; min-height: 0; }
.catalog-reference .applied-filters a { min-height: 42px; padding: 7px 9px 7px 11px; gap: 14px; border: 1px solid #bed3fa; border-radius: 10px; background: #f0f6ff; color: var(--navy); }
.catalog-reference .applied-filters a > span { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 650; }
.catalog-reference .applied-filters small { font-size: 10px; font-weight: 400; color: #5d75a0; }
.catalog-reference .applied-filters a > .icon { width: 17px; height: 17px; color: var(--commerce); }
.catalog-reference .applied-filters a:hover { background: #e2eeff; border-color: #7ca7f9; }
.catalog-reference .results-bar { gap: 13px; padding: 0; margin-bottom: 19px; min-height: 49px; border: 0; align-items: center; flex-wrap: wrap; }
.catalog-results-copy { margin-right: auto; }
.catalog-results-copy h2 { font-size: 18px; font-weight: 650; margin: 0; line-height: 1.4; letter-spacing: -.02em; }
.catalog-results-copy h2:focus { outline: none; }
.catalog-results-copy h2 > strong { color: var(--commerce); font-size: 22px; }
.catalog-results-copy p { color: var(--muted); font-size: 12px; margin-top: 3px; }
.catalog-reference .sort-control { margin-left: 0; font-size: 12px; gap: 8px; }
.catalog-reference .sort-control select { min-width: 155px; height: 42px; border-color: #ceddf5; border-radius: 10px; background: white; padding-inline: 10px; font-size: 12px; }
.catalog-reference .view-switch { margin-left: 0; border-color: #d3e0f6; border-radius: 10px; }
.catalog-reference .view-switch button { display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 40px; width: auto; padding: 9px 12px; color: #7386a8; white-space: nowrap; }
.catalog-reference .view-switch button > span { display: inline; font-size: 11px; }
.catalog-reference .view-switch button[aria-pressed=true] { background: var(--commerce); color: #fff; }
#store-products { scroll-margin-top: 20px; }
body:has(#catalog-filter-panel:modal) { overflow: hidden; }
@media (max-width: 1100px) {
  .catalog-reference .view-switch button { width: 40px; padding: 9px; }
  .catalog-reference .view-switch button > span { display: none; }
}
@media (max-width: 1100px) and (min-width: 901px) {
  .catalog-layout.catalog-reference { grid-template-columns: 262px minmax(0,1fr); gap: 20px; }
  .catalog-reference .sort-control { margin-right: auto; }
  .catalog-results-copy { flex-basis: 100%; }
}
@media (min-width: 901px) {
  .catalog-reference .filter-toggle { display: none; }
}
@media (max-width: 900px) {
  .catalog-layout.catalog-reference { display: block; }
  .catalog-reference .filters { position: static; margin-bottom: 17px; }
  .catalog-reference .filters > .filter-toggle.button {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 10px;
    width: 100%;
    min-height: 51px;
    padding: 12px 15px;
    border: 1px solid #b9d0fa;
    border-radius: 12px;
    margin: 0;
    background: #fff;
    color: var(--navy);
    box-shadow: 0 4px 17px #0058ff06;
  }
  .filter-toggle > .icon:first-child { color: var(--commerce); }
  .filter-toggle > strong { font-size: 13px; }
  .filter-toggle > span { font-size: 11px; margin-left: auto; color: #63789b; }
  .filter-toggle > .icon:last-child { width: 16px; height: 16px; color: #63789b; }
  .filter-panel[open]:not(:modal) { display: none; }
  .filter-panel:modal {
    position: fixed;
    inset: auto 0 0;
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 600px;
    max-height: min(90dvh, 850px);
    margin: 0 auto;
    padding: 0;
    border-radius: 22px 22px 0 0;
    border: 1px solid #d7e3fa;
    box-shadow: 0 -15px 60px #07175024;
    animation: filter-panel-enter .18s ease-out;
  }
  .filter-panel::backdrop { background: #07175077; backdrop-filter: blur(3px); }
  .filter-panel-heading { padding: 19px 20px 17px; }
  .filter-close { display: grid; place-items: center; flex-shrink: 0; width: 40px; height: 40px; margin-left: auto; border: 1px solid #dde7f8; border-radius: 50%; background: #f4f8ff; color: var(--navy); }
  .filter-count + .filter-close { margin-left: 0; }
  .filter-panel-body { padding: 18px 20px 10px; }
  .catalog-reference .filters form { display: flex; margin: 0; }
  .filter-choices-categories { max-height: none; }
  .filter-panel-actions { padding: 16px 20px max(16px, env(safe-area-inset-bottom)); }
  .catalog-reference .filters .filter-panel-actions .button { min-height: 47px; }
  .catalog-reference .filters .filter-choice { font-size: 13px; }
  .filter-choice-content { min-height: 42px; }
  .filter-query input { font-size: 16px; }
  .filter-query > div { height: 45px; }
  .catalog-reference .filters .filter-group select { font-size: 16px; height: 45px; }
  .catalog-reference .results-bar { margin-top: 2px; }
  .store-catalog .store-about { margin-top: 24px; }
  #store-products { scroll-margin-top: 15px; }
}
@media (max-width: 540px) {
  .filter-toggle > span { font-size: 10px; }
  .filter-toggle > strong { font-size: 12px; }
  .catalog-results-copy { flex-basis: 100%; }
  .catalog-results-copy h2 { font-size: 17px; }
  .catalog-reference .sort-control { margin-right: auto; font-size: 11px; }
  .catalog-reference .sort-control select { min-width: 142px; font-size: 11px; }
  .active-filter-bar { padding: 13px; }
  .catalog-reference .applied-filters a { gap: 9px; }
  .catalog-reference .applied-filters a > span { flex-wrap: wrap; gap: 3px 6px; font-size: 11px; }
  .filter-count { margin-left: auto; }
}
@keyframes filter-panel-enter { from { opacity: .7; transform: translateY(14px); } to { opacity: 1; transform: translateY(0); } }
