/* Production search UI refinements. */
.smart-filter-token,
.smart-filter-clear{
  width:auto!important;
  min-height:32px;
  padding:6px 11px!important;
  border-radius:999px!important;
  font-size:12px!important;
  line-height:1.1;
}
.smart-active-filters{
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:6px;
  margin:8px 0 2px;
}
.smart-active-filters[hidden]{display:none!important}
.smart-filter-token{
  border:1px solid rgba(150,87,143,.24)!important;
  background:rgba(249,235,247,.82)!important;
  color:#70416c!important;
  font-weight:700!important;
}
.smart-filter-clear{
  border:0!important;
  background:transparent!important;
  color:#746a79!important;
  text-decoration:underline;
  text-underline-offset:2px;
}
@media(max-width:700px){
    .smart-filter-token,.smart-filter-clear{min-height:31px;padding:6px 9px!important;font-size:11px!important}
}

/* Canonical flat filter layout: the grid cell is layout-only; the native
   field surface remains on the select/control itself. */
body[data-design-edition="v5"][data-design-variant="v4"] .search-panel>.grid>div{
  box-sizing:border-box;
  min-width:0;
  padding:0!important;
  border:0!important;
  border-radius:0!important;
  background:transparent!important;
  box-shadow:none!important;
  transform:none!important;
}

body[data-design-edition="v5"][data-design-variant="v4"] .search-panel>.grid>div>label{
  display:block;
  margin:0 2px 5px!important;
  color:#716379;
  font-size:11px!important;
  font-weight:760;
  letter-spacing:.015em;
}

body[data-design-edition="v5"][data-design-variant="v4"] .search-panel>.grid select{
  appearance:none;
  -webkit-appearance:none;
  width:100%!important;
  max-width:100%!important;
  min-height:38px!important;
  margin:0!important;
  padding:7px 38px 7px 10px!important;
  border:1px solid rgba(118,92,137,.12)!important;
  border-radius:10px!important;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 18 18'%3E%3Cpath d='M5 6.5 9 10.5 13 6.5' fill='none' stroke='%23708096' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") right 10px center/18px 18px no-repeat,
    rgba(255,255,255,.74)!important;
  color:#403647;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.92),
    0 1px 4px rgba(60,47,71,.025);
  font-weight:620;
}

body[data-design-edition="v5"][data-design-variant="v4"] .search-panel>.grid select:hover{
  border-color:rgba(131,78,143,.22)!important;
  background-color:rgba(255,255,255,.9)!important;
}

body[data-design-edition="v5"][data-design-variant="v4"] .search-panel>.grid select:focus{
  outline:none!important;
  border-color:rgba(142,72,141,.42)!important;
  box-shadow:0 0 0 3px rgba(151,82,146,.10)!important;
}

body[data-design-edition="v5"][data-design-variant="v4"] .search-panel>.grid select.is-filter-active{
  border-color:rgba(154,81,143,.30)!important;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 18 18'%3E%3Cpath d='M5 6.5 9 10.5 13 6.5' fill='none' stroke='%23708096' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") right 10px center/18px 18px no-repeat,
    rgba(250,235,248,.92)!important;
  color:#5f365f!important;
}

body[data-design-edition="v5"][data-design-variant="v4"] .search-panel>.grid .two{
  gap:7px!important;
}
body[data-design-edition="v5"][data-design-variant="v4"] .search-panel>.grid .two select{
  min-width:0;
}


body[data-design-edition="v5"][data-design-variant="v4"] .panel.search-panel.v4-filters-open>.actions{
  justify-content:flex-end;
  margin-top:9px!important;
}
body[data-design-edition="v5"][data-design-variant="v4"] .panel.search-panel.v4-filters-open>.actions #resetBtn{
  width:auto;
  min-height:34px;
  padding:7px 12px;
  border-radius:999px;
  border-color:rgba(121,91,139,.14);
  background:rgba(255,255,255,.52);
}

@media(max-width:700px){
  body[data-design-edition="v5"][data-design-variant="v4"] .search-panel>.grid>div{
    padding:8px 7px 9px;
    border-radius:12px;
  }
  body[data-design-edition="v5"][data-design-variant="v4"] .search-panel>.grid select{
    min-height:40px!important;
    font-size:16px!important;
  }
}

@media(prefers-reduced-transparency:reduce){
  body[data-design-edition="v5"][data-design-variant="v4"] .panel.search-panel.v4-filters-open>.grid,
  body[data-design-edition="v5"][data-design-variant="v4"] .search-panel>.grid>div{
    background:#fff!important;
    -webkit-backdrop-filter:none;
    backdrop-filter:none;
  }
}


/* Flat expanded filter area. */
body[data-design-edition="v5"][data-design-variant="v4"] .panel.search-panel.v4-filters-open>.grid{
  margin-top:10px!important;
  padding:0!important;
  gap:8px 10px!important;
  border:0!important;
  border-radius:0!important;
  background:transparent!important;
  box-shadow:none!important;
  -webkit-backdrop-filter:none!important;
  backdrop-filter:none!important;
}
@media(max-width:700px){
  body[data-design-edition="v5"][data-design-variant="v4"] .panel.search-panel.v4-filters-open>.grid{
    gap:7px!important;
  }
}


/* Shared visual range controls. */
.difficulty-range,
.tone-range{
  display:grid;
  gap:7px;
  margin-top:2px;
}
.difficulty-range{--difficulty-left:0%;--difficulty-right:0%}
.tone-range{--tone-left:0%;--tone-right:0%}

.difficulty-range-head,
.tone-range-head{
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap:10px;
  min-height:20px;
}
.difficulty-range-head strong{
  color:#403647;
  font-size:14px;
  font-weight:780;
  letter-spacing:-.01em;
}
.difficulty-range-head span,
#toneRangeCount{
  color:#746a79;
  font-size:11px;
  font-weight:650;
  text-align:right;
}

.difficulty-range-shell,
.tone-range-shell{
  position:relative;
  height:34px;
  margin:0 15px;
  touch-action:none;
  overscroll-behavior:contain;
  -webkit-user-select:none;
  user-select:none;
}
.difficulty-range-track,
.difficulty-range-selected,
.tone-range-track,
.tone-range-selected{
  position:absolute;
  top:15px;
  height:4px;
  border-radius:999px;
}
.difficulty-range-track,
.tone-range-track{
  left:0;
  right:0;
  background:rgba(90,92,112,.16);
}
.difficulty-range-selected{
  left:var(--difficulty-left);
  right:var(--difficulty-right);
  background:linear-gradient(90deg,#a9d5ea 0%,#2d6596 100%);
}
.tone-range-selected{
  left:var(--tone-left);
  right:var(--tone-right);
  background:linear-gradient(90deg,#cdebf8 0%,#2d6596 100%);
}

.difficulty-range-handle,
.tone-range-handle{
  position:absolute;
  top:3px;
  width:28px;
  height:28px;
  min-width:28px;
  min-height:28px;
  padding:0;
  border:2px solid rgba(255,255,255,.98)!important;
  border-radius:50%!important;
  box-shadow:0 2px 9px rgba(51,66,84,.24),0 0 0 1px rgba(61,91,119,.08)!important;
  color:transparent!important;
  appearance:none;
  -webkit-appearance:none;
  pointer-events:auto;
  touch-action:none;
  cursor:grab;
  z-index:8;
  -webkit-tap-highlight-color:transparent;
}
.difficulty-range-handle-min,
.tone-range-handle-min{
  transform:translateX(-50%);
  background:#eef9fe!important;
}
.difficulty-range-handle-max,
.tone-range-handle-max{
  transform:translateX(50%);
  background:#2d6596!important;
}
.difficulty-range-handle-min{left:var(--difficulty-left)}
.difficulty-range-handle-max{right:var(--difficulty-right)}
.tone-range-handle-min{left:var(--tone-left)}
.tone-range-handle-max{right:var(--tone-right)}

.difficulty-range-handle:focus-visible,
.tone-range-handle:focus-visible{
  outline:3px solid rgba(79,120,159,.22);
  outline-offset:3px;
}
.difficulty-range-handle:active,
.tone-range-handle:active{cursor:grabbing}
.difficulty-range-handle-min:active,
.tone-range-handle-min:active{transform:translateX(-50%) scale(1.06)}
.difficulty-range-handle-max:active,
.tone-range-handle-max:active{transform:translateX(50%) scale(1.06)}

.difficulty-range-scale,
.tone-range-scale{
  display:flex;
  justify-content:space-between;
  gap:12px;
  color:#7b7180;
  font-size:10px;
  line-height:1.2;
}
.difficulty-range-note,
.tone-range-note{
  display:block;
  color:#8a808e;
  font-size:10px;
  line-height:1.35;
}
.difficulty-range-note.is-active,
.tone-range-note.is-active{
  padding:7px 9px;
  border:1px solid rgba(76,112,147,.14);
  border-radius:9px;
  background:rgba(235,246,252,.72);
  color:#526b80;
  font-weight:650;
}
/* Difficulty histogram and compatibility inputs. */
.difficulty-histogram{
  height:42px;
  display:grid;
  grid-template-columns:repeat(10,minmax(0,1fr));
  align-items:end;
  gap:3px;
  padding:0 2px;
}
.difficulty-histogram-bar{
  display:block;
  height:var(--difficulty-bar-height,8%);
  min-height:3px;
  border-radius:4px 4px 2px 2px;
  background:rgba(113,156,191,.72);
  transition:height .18s ease,opacity .18s ease,transform .18s ease;
}
.difficulty-histogram-bar:nth-child(1){background:rgba(174,211,232,.92)}
.difficulty-histogram-bar:nth-child(2){background:rgba(159,201,226,.92)}
.difficulty-histogram-bar:nth-child(3){background:rgba(145,192,220,.92)}
.difficulty-histogram-bar:nth-child(4){background:rgba(130,181,213,.92)}
.difficulty-histogram-bar:nth-child(5){background:rgba(113,168,204,.92)}
.difficulty-histogram-bar:nth-child(6){background:rgba(96,154,194,.92)}
.difficulty-histogram-bar:nth-child(7){background:rgba(80,139,182,.93)}
.difficulty-histogram-bar:nth-child(8){background:rgba(65,124,169,.94)}
.difficulty-histogram-bar:nth-child(9){background:rgba(53,108,154,.95)}
.difficulty-histogram-bar:nth-child(10){background:rgba(41,91,138,.96)}
.difficulty-histogram-bar.is-outside{opacity:.22}

.difficulty-range-shell input[type="range"]{
  position:absolute;
  inset:0;
  width:100%;
  height:34px;
  margin:0;
  padding:0;
  border:0;
  background:transparent;
  appearance:none;
  -webkit-appearance:none;
  pointer-events:none;
  opacity:0;
}
.difficulty-range-shell input[type="range"]::-webkit-slider-runnable-track{
  height:4px;
  background:transparent;
}
.difficulty-range-shell input[type="range"]::-webkit-slider-thumb{
  width:24px;
  height:24px;
  margin-top:-10px;
  border:0;
  border-radius:50%;
  background:transparent;
  box-shadow:none;
  opacity:.001;
  -webkit-appearance:none;
  pointer-events:auto;
  cursor:grab;
}
.difficulty-range-shell input[type="range"]::-moz-range-track{
  height:4px;
  background:transparent;
}
.difficulty-range-shell input[type="range"]::-moz-range-thumb{
  width:24px;
  height:24px;
  border:0;
  border-radius:50%;
  background:transparent;
  box-shadow:none;
  opacity:.001;
  pointer-events:auto;
  cursor:grab;
}

.tone-range-value-sr{
  position:absolute!important;
  width:1px!important;
  height:1px!important;
  padding:0!important;
  margin:-1px!important;
  overflow:hidden!important;
  clip:rect(0,0,0,0)!important;
  white-space:nowrap!important;
  border:0!important;
}
.tone-filter-notation{
  display:block;
  width:132px;
  max-width:62%;
  min-height:52px;
  line-height:0;
  color:#332c42;
}
.tone-filter-notation svg{
  display:block;
  width:100%;
  height:auto;
  overflow:visible;
}
.tone-filter-staff{
  fill:none;
  stroke:#afa7ba;
  stroke-width:1;
}
.tone-filter-ledger{
  fill:none;
  stroke:#514a59;
  stroke-width:.9;
}
.tone-filter-connector{
  fill:none;
  stroke:#7fa9c4;
  stroke-width:1.7;
  stroke-linecap:round;
  opacity:.72;
}
.tone-filter-clef{
  fill:#51405e;
  font-family:"Noto Music","Apple Symbols","Segoe UI Symbol",serif;
  font-size:65px;
  font-weight:400;
  opacity:.86;
}
.tone-filter-head{
  stroke-width:1.45;
}
.tone-filter-head-low{
  fill:#eef9fe;
  stroke:#78abc5;
}
.tone-filter-head-high{
  fill:#2d6596;
  stroke:#2d6596;
}
.tone-filter-head-single{
  fill:#5d91b6;
  stroke:#416f93;
}
.tone-filter-accidental{
  font-family:"Apple Symbols","Noto Music","Segoe UI Symbol",serif;
  font-size:19px;
  font-weight:500;
}
.tone-filter-accidental-low{fill:#78abc5}
.tone-filter-accidental-high{fill:#2d6596}
.tone-filter-accidental-single{fill:#416f93}
.tone-histogram{
  height:42px;
  display:grid;
  grid-template-columns:repeat(43,minmax(0,1fr));
  align-items:end;
  gap:1px;
  padding:0 2px;
}
.tone-histogram-bar{
  display:block;
  height:var(--tone-bar-height,6%);
  min-height:2px;
  border-radius:3px 3px 1px 1px;
  background:hsl(203 58% var(--tone-lightness,65%));
  transition:height .18s ease,opacity .18s ease;
}
.tone-histogram-bar.is-outside{opacity:.20}
@media(max-width:700px){
  .difficulty-histogram,.tone-histogram{height:38px}
  .tone-histogram{gap:1px}
  .difficulty-range-shell,.tone-range-shell{height:38px;margin-inline:16px}
  .difficulty-range-shell input[type="range"]{height:38px}
  .difficulty-range-track,.difficulty-range-selected,
  .tone-range-track,.tone-range-selected{top:17px}
  .difficulty-range-handle,.tone-range-handle{
    top:3px;width:30px;height:30px;min-width:30px;min-height:30px
  }
  .difficulty-range-head strong{font-size:15px}
  .tone-range-head{
    display:grid;
    grid-template-columns:minmax(0,1fr) auto;
    align-items:start;
    gap:4px;
  }
  .tone-filter-notation{
    width:100%;
    max-width:none;
    min-width:0;
    min-height:50px;
  }
  #toneRangeCount{
    align-self:start;
    padding-top:2px;
    white-space:nowrap;
    line-height:1.15;
  }
}


/* Compact collapsible shells for the two large visual filters. */
.special-filter-details{
  width:100%;
  margin:0;
  min-height:38px;
  border:1px solid rgba(118,92,137,.12);
  border-radius:10px;
  background:rgba(255,255,255,.74);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.92),
    0 1px 4px rgba(60,47,71,.025);
  transition:background .18s ease,border-color .18s ease,box-shadow .18s ease;
}
.special-filter-details:hover{
  border-color:rgba(131,78,143,.22);
  background:rgba(255,255,255,.9);
}
.special-filter-details[open]{
  background:rgba(255,255,255,.82);
  border-color:rgba(118,92,137,.16);
}
.special-filter-details>summary{
  list-style:none;
}
.special-filter-details>summary::-webkit-details-marker{
  display:none;
}
.special-filter-summary{
  position:relative;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  min-height:38px;
  margin:0;
  padding:7px 38px 7px 10px;
  cursor:pointer;
  user-select:none;
  -webkit-user-select:none;
  color:#55495e;
  font-size:12px;
  font-weight:780;
  letter-spacing:.01em;
  -webkit-tap-highlight-color:transparent;
}
.special-filter-summary:focus-visible{
  outline:3px solid rgba(79,120,159,.16);
  outline-offset:3px;
  border-radius:8px;
}
.special-filter-chevron,
.search-panel .epoch-filter-arrow{
  position:absolute;
  right:10px;
  top:50%;
  width:18px;
  height:18px;
  transform:translateY(-50%);
}
.special-filter-chevron::before,
.search-panel .epoch-filter-arrow::before{
  content:"";
  position:absolute;
  left:5px;
  top:5px;
  width:7px;
  height:7px;
  border-right:1.8px solid #708096;
  border-bottom:1.8px solid #708096;
  transform:rotate(45deg);
  transition:transform .18s ease,top .18s ease;
}
.special-filter-details[open] .special-filter-chevron::before,
.search-panel .epoch-filter-trigger[aria-expanded="true"] .epoch-filter-arrow::before{
  transform:rotate(225deg);
}
.special-filter-details[open]>.difficulty-range,
.special-filter-details[open]>.tone-range{
  margin:7px 10px 10px;
}
@media(max-width:700px){
  .special-filter-details{
    min-height:40px;
  }
  .special-filter-summary{
    min-height:40px;
    padding:8px 38px 8px 10px;
    font-size:12px;
  }
}


/* Final flat filter composition: the grid cells are layout-only, never cards.
   Interaction state belongs to the actual controls, not their outer wrappers. */
body[data-design-edition="v5"][data-design-variant="v4"] .search-panel>.grid>div,
body[data-design-edition="v5"][data-design-variant="v4"] .search-panel>.grid>div:hover,
body[data-design-edition="v5"][data-design-variant="v4"] .search-panel>.grid>div:focus-within{
  padding:0!important;
  border:0!important;
  border-radius:0!important;
  background:none!important;
  box-shadow:none!important;
  -webkit-backdrop-filter:none!important;
  backdrop-filter:none!important;
  transform:none!important;
}

/* Highest tone and difficulty use the same label + field hierarchy as the
   other filters. Closed: "Alle". Open: only the visual selection UI. */
body[data-design-edition="v5"][data-design-variant="v4"] .search-panel>.grid>div:has(.special-filter-details)>label{
  display:block!important;
  margin:0 2px 5px!important;
}
.special-filter-details[open]>.special-filter-summary{
  min-height:38px;
  padding:7px 38px 7px 10px;
}
.special-filter-details[open] .special-filter-summary-title{
  visibility:hidden;
}
.special-filter-details[open]>.difficulty-range,
.special-filter-details[open]>.tone-range{
  margin:7px 10px 10px;
}


/* Sticky compact search rail.
   The panel stays in normal document flow until it reaches the viewport top.
   Once pinned, only the essential search row remains prominent; the existing
   filter toggle can expand the full criteria again at any time. */
body[data-design-edition="v5"][data-design-variant="v4"] .search-panel.search-sticky-ready{
  position:sticky;
  top:env(safe-area-inset-top,0px);
  z-index:40;
}
body[data-design-edition="v5"][data-design-variant="v4"] .search-sticky-sentinel{
  display:block;
  width:1px;
  height:0;
  margin:0;
  padding:0;
  pointer-events:none;
}
body[data-design-edition="v5"][data-design-variant="v4"] .search-panel.search-panel-stuck{
  padding:12px 18px!important;
  border-radius:0 0 16px 16px!important;
  box-shadow:0 8px 24px rgba(35,29,43,.12)!important;
  background:rgba(255,255,255,.96)!important;
  -webkit-backdrop-filter:blur(14px);
  backdrop-filter:blur(14px);
}
body[data-design-edition="v5"][data-design-variant="v4"] .search-panel.search-panel-stuck>h2{
  display:none!important;
}
body[data-design-edition="v5"][data-design-variant="v4"] .search-panel.search-panel-stuck>#q{
  height:48px!important;
  padding-left:50px!important;
  padding-right:58px!important;
}
body[data-design-edition="v5"][data-design-variant="v4"] .search-panel.search-panel-stuck::before{
  left:33px!important;
  top:25px!important;
  width:15px!important;
  height:15px!important;
  border-width:2px!important;
}
body[data-design-edition="v5"][data-design-variant="v4"] .search-panel.search-panel-stuck::after{
  left:46px!important;
  top:40px!important;
  width:8px!important;
  height:2px!important;
}
body[data-design-edition="v5"][data-design-variant="v4"] .search-panel.search-panel-stuck>.v4-filter-toggle{
  top:17px!important;
  right:24px!important;
  width:38px!important;
  height:38px!important;
  min-width:38px!important;
}
body[data-design-edition="v5"][data-design-variant="v4"] .search-panel.search-panel-stuck>.smart-active-filters{
  display:flex!important;
  flex-wrap:nowrap;
  gap:5px;
  margin:7px 0 0;
  overflow-x:auto;
  overflow-y:hidden;
  scrollbar-width:none;
  -webkit-overflow-scrolling:touch;
}
body[data-design-edition="v5"][data-design-variant="v4"] .search-panel.search-panel-stuck>.smart-active-filters::-webkit-scrollbar{
  display:none;
}
body[data-design-edition="v5"][data-design-variant="v4"] .search-panel.search-panel-stuck>.smart-active-filters .smart-filter-token,
body[data-design-edition="v5"][data-design-variant="v4"] .search-panel.search-panel-stuck>.smart-active-filters .smart-filter-clear{
  flex:0 0 auto;
}
@media(max-width:700px){
  body[data-design-edition="v5"][data-design-variant="v4"] .search-panel.search-panel-stuck>.smart-active-filters{
    margin-top:6px;
  }
}
@media(max-width:700px){
  body[data-design-edition="v5"][data-design-variant="v4"] .search-panel.search-panel-stuck{
    padding:9px 12px!important;
    border-radius:0 0 14px 14px!important;
  }
  body[data-design-edition="v5"][data-design-variant="v4"] .search-panel.search-panel-stuck>#q{
    height:44px!important;
    padding-left:44px!important;
    padding-right:52px!important;
    font-size:16px!important;
  }
  body[data-design-edition="v5"][data-design-variant="v4"] .search-panel.search-panel-stuck::before{
    left:25px!important;
    top:21px!important;
    width:14px!important;
    height:14px!important;
  }
  body[data-design-edition="v5"][data-design-variant="v4"] .search-panel.search-panel-stuck::after{
    left:37px!important;
    top:35px!important;
    width:7px!important;
  }
  body[data-design-edition="v5"][data-design-variant="v4"] .search-panel.search-panel-stuck>.v4-filter-toggle{
    top:12px!important;
    right:17px!important;
    width:36px!important;
    height:36px!important;
    min-width:36px!important;
  }
}
@media(prefers-reduced-transparency:reduce){
  body[data-design-edition="v5"][data-design-variant="v4"] .search-panel.search-panel-stuck{
    background:#fff!important;
    -webkit-backdrop-filter:none;
    backdrop-filter:none;
  }
}

/* Jumu age-group multi-select */
.search-panel .jumu-age-filter-select[hidden]{display:none!important}
.search-panel .jumu-age-filter-options{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:4px;margin-top:0;min-width:0}
.search-panel .jumu-age-filter-option{position:relative;display:flex;align-items:center;justify-content:center;box-sizing:border-box;min-width:0;height:38px;min-height:38px;margin:0;padding:0 3px;border:1px solid rgba(52,66,88,.18);border-radius:10px;background:rgba(255,255,255,.72);font-size:.82rem;font-weight:650;line-height:1;cursor:pointer;user-select:none;white-space:nowrap}
.search-panel .jumu-age-filter-option input{position:absolute;inline-size:1px;block-size:1px;opacity:0;pointer-events:none}
.search-panel .jumu-age-filter-option:has(input:checked){border-color:#6e8baa;background:#eef5fb;color:#2f6389}
.search-panel .jumu-age-filter-option:has(input:focus-visible){outline:2px solid #2f6389;outline-offset:2px}
@media (hover:hover) and (pointer:fine){.search-panel .jumu-age-filter-option:hover{border-color:rgba(47,99,137,.45);background:rgba(238,245,251,.72)}}
@media(max-width:700px){
  .search-panel .jumu-age-filter-options{gap:2px}
  .search-panel .jumu-age-filter-option{height:40px;min-height:40px;padding:0 1px;font-size:10px;letter-spacing:-.02em}
}

/* Combined epoch multi-select control */
.search-panel .epoch-filter-select[hidden]{display:none!important}
.search-panel .epoch-filter-widget{position:relative;width:100%;min-width:0;margin:0}
.search-panel .epoch-filter-trigger{position:relative;display:flex;align-items:center;justify-content:space-between;gap:10px;box-sizing:border-box;width:100%;height:38px;min-height:38px;padding:7px 38px 7px 10px;border:1px solid rgba(118,92,137,.12);border-radius:10px;background:rgba(255,255,255,.78);color:#40384a;font:inherit;font-weight:650;text-align:left;cursor:pointer}
.search-panel .epoch-filter-widget[data-active="1"] .epoch-filter-trigger{border-color:#6e8baa;background:#eef5fb;color:#2f6389}
.search-panel .epoch-filter-trigger:focus-visible{outline:2px solid #4b84aa;outline-offset:2px}
.search-panel .epoch-filter-trigger[aria-expanded="true"]{border-radius:10px 10px 0 0}
.search-panel .epoch-filter-panel{margin-top:-1px;padding:9px;border:1px solid rgba(92,79,110,.13);border-top:0;border-radius:0 0 10px 10px;background:rgba(255,255,255,.78);box-shadow:none}
.search-panel .epoch-filter-panel[hidden]{display:none!important}
.search-panel .epoch-filter-choices{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:4px}
.search-panel .epoch-filter-choice{display:flex;align-items:center;justify-content:center;box-sizing:border-box;min-width:0;height:38px;min-height:38px;padding:0 3px;border:1px solid rgba(52,66,88,.18);border-radius:10px;background:rgba(255,255,255,.72);color:#433a4b;font:inherit;font-size:.82rem;font-weight:650;line-height:1.05;text-align:center;white-space:normal;overflow-wrap:normal;word-break:normal;cursor:pointer}
.search-panel .epoch-filter-choice[aria-pressed="true"]{border-color:#6e8baa;background:#eef5fb;color:#2f6389}
.search-panel .epoch-filter-choice:focus-visible{outline:2px solid #4b84aa;outline-offset:2px}
@media (hover:hover) and (pointer:fine){.search-panel .epoch-filter-choice:hover{border-color:rgba(47,99,137,.45);background:rgba(238,245,251,.72)}}
@media(max-width:700px){
  .search-panel .epoch-filter-trigger{height:40px;min-height:40px}
  .search-panel .epoch-filter-panel{padding:7px}
  .search-panel .epoch-filter-choices{grid-template-columns:repeat(12,minmax(0,1fr));gap:5px}
  .search-panel .epoch-filter-choice{height:40px;min-height:40px;padding:0 1px;font-size:10px;line-height:1.05}
  .search-panel .epoch-filter-choice:nth-child(-n+4){grid-column:span 3}
  .search-panel .epoch-filter-choice:nth-child(n+5){grid-column:span 4}
}

/* Keep the global V4/V5 button theme from overriding epoch selection states. */
body[data-design-variant="v4"] .search-panel .epoch-filter-trigger,
body[data-design-edition="v5"] .search-panel .epoch-filter-trigger{
  background:rgba(255,255,255,.82)!important;
  color:#40384a!important;
  border:1px solid rgba(92,79,110,.16)!important;
  box-shadow:none!important;
}
body[data-design-variant="v4"] .search-panel .epoch-filter-widget[data-active="1"] .epoch-filter-trigger,
body[data-design-edition="v5"] .search-panel .epoch-filter-widget[data-active="1"] .epoch-filter-trigger{
  background:#eef5fb!important;
  color:#2f6389!important;
  border-color:#6e8baa!important;
}
body[data-design-variant="v4"] .search-panel .epoch-filter-choice,
body[data-design-edition="v5"] .search-panel .epoch-filter-choice{
  background:rgba(255,255,255,.82)!important;
  color:#433a4b!important;
  border:1px solid rgba(52,66,88,.16)!important;
  box-shadow:none!important;
}
body[data-design-variant="v4"] .search-panel .epoch-filter-choice[aria-pressed="true"],
body[data-design-edition="v5"] .search-panel .epoch-filter-choice[aria-pressed="true"]{
  background:#eef5fb!important;
  color:#2f6389!important;
  border-color:#6e8baa!important;
}

