/* Decilo search system: global modal + WooCommerce shop sidebar. */
:root {
  --der-search-ink: #171512;
  --der-search-cream: #f6f1e8;
  --der-search-yellow: #f4c542;
  --der-search-red: #b42318;
  --der-search-border: rgba(23, 21, 18, .14);
}

/* Header search trigger */
.der-global-search-menu-item {
  display: flex;
  align-items: center;
}

.main-navigation .der-global-search-trigger,
.der-global-search-trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 44px;
  min-height: 44px;
  margin: 0;
  padding: 0 10px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #fffaf0;
  cursor: pointer;
}

.der-global-search-trigger:hover,
.der-global-search-trigger:focus-visible {
  border-color: transparent;
  background: var(--der-search-yellow);
  color: #171512;
  outline: none;
}

.der-global-search-trigger svg,
.der-global-search__input-icon svg {
  width: 23px;
  height: 23px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
}

.site-header .primary-menu-container #primary-menu > li.der-global-search-menu-item {
  margin-left: 8px;
  display: flex;
  align-items: center;
}

.site-header .primary-menu-container #primary-menu > li.der-global-search-menu-item > button {
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  margin: 0;
  padding: 0 !important;
  border: 1px solid rgba(17, 24, 39, .14);
  border-radius: 999px;
  background: rgba(255, 250, 240, .08) !important;
  color: #fffaf0 !important;
  border-color: rgba(255, 250, 240, .20) !important;
  box-shadow: 0 10px 28px rgba(0, 0, 0, .18) !important;
  transition: color .18s ease, background-color .18s ease, border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

.site-header .primary-menu-container #primary-menu > li.der-global-search-menu-item > button svg {
  width: 20px;
  height: 20px;
}

.site-header .primary-menu-container #primary-menu > li.der-global-search-menu-item > button:hover,
.site-header .primary-menu-container #primary-menu > li.der-global-search-menu-item > button:focus-visible {
  border-color: transparent !important;
  background: var(--der-header-yellow, #f5c542) !important;
  color: #171512 !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 12px 24px rgba(245, 197, 66, .28) !important;
}

.site-header .primary-menu-container #primary-menu > li.der-global-search-menu-item > button:focus-visible {
  outline: none !important;
}

.site-header .primary-menu-container #primary-menu > li.decilo-header-icon > a:hover,
.site-header .primary-menu-container #primary-menu > li.decilo-header-icon > a:focus-visible {
  border-color: transparent !important;
  background: var(--der-header-yellow, #f5c542) !important;
  color: #171512 !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 12px 24px rgba(245, 197, 66, .28) !important;
}

.site-header .primary-menu-container #primary-menu > li.decilo-header-icon > a:focus-visible {
  outline: none !important;
}

.der-global-search-trigger__text {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* Global modal */
body.der-global-search-open,
body.der-shop-filters-open {
  overflow: hidden;
}

.der-global-search {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: grid;
  place-items: start center;
  padding: clamp(18px, 7vh, 72px) 18px 18px;
}

.der-global-search[hidden] {
  display: none;
}

.der-global-search__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 9, 8, .74);
  backdrop-filter: blur(8px);
}

.der-global-search__dialog {
  position: relative;
  width: min(920px, 100%);
  max-height: calc(100vh - 36px);
  overflow: auto;
  padding: clamp(20px, 4vw, 38px);
  border: 1px solid rgba(255, 255, 255, .15);
  border-radius: 26px;
  background: #fffdf8;
  color: var(--der-search-ink);
  box-shadow: 0 28px 90px rgba(0, 0, 0, .32);
}

.der-global-search__topbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 22px;
}

.der-global-search__eyebrow,
.der-shop-filters__eyebrow {
  margin: 0 0 5px;
  color: var(--der-search-red);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.der-global-search__topbar h2,
.der-shop-filters__header h2 {
  margin: 0;
  color: var(--der-search-ink);
  font-size: clamp(24px, 4vw, 36px);
  font-weight: 950;
  letter-spacing: -.04em;
}

.der-global-search__close,
.der-shop-filters__close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--der-search-border);
  border-radius: 999px;
  background: var(--der-search-cream);
  color: var(--der-search-ink);
  font-size: 27px;
  line-height: 1;
  cursor: pointer;
}

.der-global-search__close:hover,
.der-global-search__close:focus-visible,
.der-shop-filters__close:hover,
.der-shop-filters__close:focus-visible {
  border-color: var(--der-search-ink);
  background: var(--der-search-ink);
  color: #fffaf0;
  outline: 3px solid rgba(244, 197, 66, .4);
  outline-offset: 2px;
}

.der-global-search__form {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.der-global-search__form input[type="search"] {
  width: 100%;
  height: 58px;
  margin: 0;
  padding: 0 58px;
  border: 2px solid var(--der-search-ink);
  border-radius: 18px;
  background: #fff;
  color: var(--der-search-ink);
  font-size: clamp(16px, 2vw, 19px);
  font-weight: 750;
  box-shadow: none;
}

.der-global-search__input-icon {
  position: absolute;
  top: 17px;
  left: 18px;
  z-index: 1;
  color: rgba(23, 21, 18, .58);
}

.der-global-search__form button,
.der-shop-filters__actions button {
  min-height: 58px;
  padding: 0 24px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--der-search-yellow);
  color: var(--der-search-ink);
  font-weight: 900;
  cursor: pointer;
}

.der-global-search__form button:hover,
.der-global-search__form button:focus-visible,
.der-shop-filters__actions button:hover,
.der-shop-filters__actions button:focus-visible {
  border-color: transparent;
  background: #ffd75a;
  color: var(--der-search-ink);
  outline: 3px solid rgba(23, 21, 18, .22);
  outline-offset: 2px;
}

.der-global-search__help {
  margin: 9px 2px 0;
  color: rgba(23, 21, 18, .65);
  font-size: 13px;
}

.der-global-search__results {
  display: grid;
  gap: 22px;
  margin-top: 26px;
}

.der-global-search__results.is-loading {
  min-height: 100px;
  opacity: .55;
}

.der-global-search-group h3 {
  margin: 0 0 10px;
  color: rgba(23, 21, 18, .68);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.der-global-search-group__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.der-global-search-result {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  align-items: center;
  gap: 13px;
  min-height: 88px;
  padding: 7px;
  border: 1px solid var(--der-search-border);
  border-radius: 16px;
  background: #fff;
  color: var(--der-search-ink);
  text-decoration: none;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.der-global-search-result:hover,
.der-global-search-result:focus-visible {
  border-color: rgba(23, 21, 18, .42);
  color: var(--der-search-ink);
  outline: 3px solid rgba(244, 197, 66, .38);
  outline-offset: 1px;
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(23, 21, 18, .09);
}

.der-global-search-result__media {
  display: block;
  width: 74px;
  height: 74px;
  overflow: hidden;
  border-radius: 12px;
  background: var(--der-search-cream);
}

.der-global-search-result__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.der-global-search-result__copy {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 2px;
}

.der-global-search-result__meta {
  color: var(--der-search-red);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .07em;
  text-transform: uppercase;
}

.der-global-search-result__copy strong {
  overflow: hidden;
  font-size: 15px;
  line-height: 1.2;
  text-overflow: ellipsis;
}

.der-global-search-result__price {
  color: var(--der-search-red);
  font-size: 14px;
  font-weight: 900;
}

.der-global-search-result__excerpt {
  display: -webkit-box;
  overflow: hidden;
  color: rgba(23, 21, 18, .65);
  font-size: 12px;
  line-height: 1.35;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.der-global-search__empty {
  width: min(680px, 100%);
  box-sizing: border-box;
  justify-self: center;
  margin: 0;
  padding: clamp(20px, 4vw, 32px);
  border-radius: 18px;
  border: 1px solid var(--der-search-border);
  background: #fff;
  color: rgba(23, 21, 18, .7);
  text-align: center;
  box-shadow: 0 12px 30px rgba(23, 21, 18, .06);
  display: grid;
  justify-items: center;
  gap: 10px;
}

.der-global-search__empty-image {
  display: block;
  width: min(230px, 75vw);
  height: auto;
  margin: 0 auto;
}

.der-global-search__empty p {
  margin: 0;
  font-weight: 750;
}

.der-global-search__all {
  justify-self: center;
  padding: 5px 2px;
  color: var(--der-search-ink);
  font-weight: 900;
  text-decoration: underline;
  text-underline-offset: 5px;
}

/* Shop sidebar */
.der-shop-sidebar-active .content-bg,
.der-shop-sidebar-active .site-main {
  background: transparent;
}

.der-shop-catalog-grid {
  display: grid;
  grid-template-columns: minmax(220px, 270px) minmax(0, 1fr);
  align-items: start;
  gap: clamp(24px, 3vw, 38px);
  width: 100%;
}

.der-shop-catalog-results {
  min-width: 0;
}

body.der-shop-sidebar-active.der-product-card-system .der-shop-catalog-results > ul.products {
  width: 100%;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
}

.der-shop-filters {
  position: sticky;
  top: 104px;
  box-sizing: border-box;
  padding: 22px;
  border: 1px solid var(--der-search-border);
  border-radius: 22px;
  background: #fffdf8;
  color: var(--der-search-ink);
  box-shadow: 0 16px 36px rgba(23, 21, 18, .07);
}

.der-shop-filters__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 19px;
}

.der-shop-filters__header h2 {
  font-size: 24px;
}

.der-shop-filters__close,
.der-shop-filter-open,
.der-shop-filter-backdrop {
  display: none;
}

.der-shop-filter-section {
  min-width: 0;
  margin: 0;
  padding: 17px 0;
  border: 0;
  border-top: 1px solid rgba(23, 21, 18, .1);
}

.der-shop-filter-section:first-of-type {
  padding-top: 0;
  border-top: 0;
}

.der-shop-filter-section > label,
.der-shop-filter-section > legend {
  display: block;
  width: 100%;
  margin: 0 0 9px;
  padding: 0;
  color: rgba(23, 21, 18, .76);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .03em;
}

.der-shop-filter-section input[type="search"],
.der-shop-filter-section input[type="number"],
.der-shop-filter-section select {
  width: 100%;
  height: 46px;
  margin: 0;
  padding: 0 12px;
  border: 1px solid rgba(23, 21, 18, .2);
  border-radius: 12px;
  background: #fff;
  color: var(--der-search-ink);
  font-size: 13px;
  font-weight: 700;
  box-shadow: none;
}

.der-shop-filter-section input:focus,
.der-shop-filter-section select:focus {
  border-color: var(--der-search-ink);
  outline: 3px solid rgba(244, 197, 66, .34);
  outline-offset: 1px;
}

.der-shop-category-cascade select {
  padding-right: 38px;
  background-color: #fff;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23171512' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 14px 14px;
  appearance: none;
}

.der-shop-category-child {
  margin-top: 12px;
  padding: 0;
  border: 0;
  background: transparent;
}

.der-shop-category-child[hidden] {
  display: none !important;
}

.der-shop-category-child > label {
  display: block;
  margin: 0 0 9px;
  color: rgba(23, 21, 18, .76);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .03em;
}

.der-shop-price-currency {
  margin-left: 3px;
  color: rgba(23, 21, 18, .48);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .04em;
}

.der-shop-filter-search {
  position: relative;
}

.der-shop-filter-search > span {
  position: absolute;
  top: 50%;
  left: 13px;
  color: rgba(23, 21, 18, .5);
  font-size: 19px;
  transform: translateY(-52%);
  pointer-events: none;
}

.der-shop-filter-search input[type="search"] {
  padding-left: 38px;
}

.der-color-swatches {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.der-color-swatch {
  position: relative;
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  align-items: center;
  gap: 7px;
  min-width: 0;
  min-height: 40px;
  margin: 0;
  padding: 5px 7px;
  border: 1px solid rgba(23, 21, 18, .1);
  border-radius: 11px;
  background: #fff;
  cursor: pointer;
}

.der-color-swatch[hidden] {
  display: none !important;
}

.der-color-swatch:hover {
  border-color: rgba(23, 21, 18, .24);
  background: var(--der-search-cream);
}

.der-color-swatch input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.der-color-swatch__circle {
  width: 24px;
  height: 24px;
  border: 2px solid rgba(23, 21, 18, .24);
  border-radius: 50%;
  background: var(--der-swatch);
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .32);
}

.der-color-swatch__name {
  min-width: 0;
  overflow: hidden;
  color: var(--der-search-ink);
  font-size: 11px;
  font-weight: 800;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.der-color-swatch__check {
  position: absolute;
  top: 3px;
  right: 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--der-search-ink);
  color: #fffaf0;
  font-size: 10px;
  font-weight: 950;
  opacity: 0;
}

.der-color-swatch:has(input:checked) {
  border-color: var(--der-search-ink);
  background: var(--der-search-cream);
}

.der-color-swatch:has(input:focus-visible) {
  outline: 3px solid rgba(244, 197, 66, .45);
  outline-offset: 2px;
}

.der-color-swatch input:checked ~ .der-color-swatch__check {
  opacity: 1;
}

.der-color-swatches__toggle {
  width: 100%;
  min-height: 40px;
  margin: 10px 0 0;
  padding: 0 10px;
  border: 1px solid rgba(23, 21, 18, .18);
  border-radius: 10px;
  background: transparent;
  color: var(--der-search-ink);
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.der-color-swatches__toggle:hover,
.der-color-swatches__toggle:focus-visible {
  border-color: var(--der-search-ink);
  background: var(--der-search-yellow);
  color: var(--der-search-ink);
  outline: 0;
}

.der-color-swatches:has(.der-filter-extra:not([hidden])) {
  max-height: 360px;
  padding-right: 5px;
  overflow-y: auto;
  scrollbar-color: rgba(23, 21, 18, .35) transparent;
  scrollbar-width: thin;
}

.der-size-options {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.der-size-options label {
  position: relative;
  margin: 0;
  cursor: pointer;
}

.der-size-options input {
  position: absolute;
  opacity: 0;
}

.der-size-options span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  min-height: 40px;
  padding: 0 9px;
  border: 1px solid rgba(23, 21, 18, .2);
  border-radius: 10px;
  background: #fff;
  color: var(--der-search-ink);
  font-size: 12px;
  font-weight: 900;
}

.der-size-options input:checked + span {
  border-color: var(--der-search-ink);
  background: var(--der-search-ink);
  color: #fffaf0;
}

.der-size-options input:focus-visible + span {
  outline: 3px solid rgba(244, 197, 66, .45);
  outline-offset: 2px;
}

.der-shop-price-range {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.der-shop-price-range label {
  margin: 0;
}

.der-shop-price-range label span {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.der-shop-filters__actions {
  display: grid;
  gap: 10px;
  padding-top: 2px;
}

.der-shop-filters__actions button {
  min-height: 48px;
}

.der-shop-filters__actions a {
  justify-self: center;
  color: rgba(23, 21, 18, .72);
  font-size: 13px;
  font-weight: 800;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.der-shop-filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 17px;
  padding-top: 17px;
  border-top: 1px solid rgba(23, 21, 18, .1);
}

.der-shop-filter-chips a {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 8px;
  border-radius: 999px;
  background: var(--der-search-cream);
  color: var(--der-search-ink);
  font-size: 10px;
  font-weight: 850;
  text-decoration: none;
}

.der-shop-filter-chips a span {
  font-size: 14px;
}

.der-product-search-title {
  margin: 0 0 24px;
}

.der-product-search-title h1 {
  margin: 0;
  color: var(--der-search-ink);
  font-size: clamp(28px, 4vw, 44px);
  letter-spacing: -.04em;
}

.der-product-search-title h1 span {
  color: var(--der-search-red);
}

.der-shop-empty {
  width: min(760px, 100%);
  box-sizing: border-box;
  margin-inline: auto;
  padding: clamp(30px, 5vw, 56px);
  border-radius: 22px;
  background: #fff;
  text-align: center;
  box-shadow: 0 18px 44px rgba(23, 21, 18, .08);
}

.der-shop-empty__image {
  display: block;
  width: min(280px, 82%);
  height: auto;
  margin: 0 auto 18px;
}

.der-shop-empty > p:first-child {
  margin: 0 0 6px;
  color: var(--der-search-red);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.der-shop-empty h2 {
  margin: 0 auto 10px;
  max-width: 680px;
  color: var(--der-search-ink);
  font-size: clamp(25px, 4vw, 38px);
}

.der-shop-empty > p:not(:first-child) {
  margin: 0 auto 22px;
  color: rgba(23, 21, 18, .68);
}

@media (max-width: 900px) {
  .der-shop-catalog-grid {
    display: block;
  }

  body.der-shop-sidebar-active.der-product-card-system .der-shop-catalog-results > ul.products {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }

  .der-shop-filter-open {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    min-height: 50px;
    margin: 0 0 20px;
    padding: 0 18px;
    border: 1px solid transparent;
    border-radius: 999px;
    background: var(--der-search-ink);
    color: #fffaf0;
    font-size: 14px;
    font-weight: 900;
    cursor: pointer;
  }

  .der-shop-filter-open:hover,
  .der-shop-filter-open:focus-visible {
    border-color: transparent;
    background: #2a2724;
    color: var(--der-search-yellow);
    outline: 3px solid rgba(244, 197, 66, .5);
    outline-offset: 2px;
  }

  .der-shop-filter-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 26px;
    height: 26px;
    padding: 0 7px;
    border-radius: 999px;
    background: var(--der-search-yellow);
    color: var(--der-search-ink);
  }

  .der-shop-filter-backdrop:not([hidden]) {
    position: fixed;
    inset: 0;
    z-index: 100001;
    display: block;
    background: rgba(10, 9, 8, .66);
  }

  .der-shop-filters {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 100002;
    width: min(390px, 92vw);
    overflow-y: auto;
    border-radius: 22px 0 0 22px;
    box-shadow: -20px 0 60px rgba(0, 0, 0, .25);
    transform: translateX(105%);
    transition: transform .24s ease;
  }

  .der-shop-filters.is-open {
    transform: translateX(0);
  }

  .der-shop-filters__close {
    display: inline-flex;
  }
}

@media (max-width: 620px) {
  body.der-shop-sidebar-active.der-product-card-system .der-shop-catalog-results > ul.products {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  .der-global-search {
    place-items: stretch;
    padding: 0;
  }

  .der-global-search__dialog {
    width: 100%;
    height: 100%;
    max-height: none;
    padding: 20px 16px 30px;
    border: 0;
    border-radius: 0;
  }

  .der-global-search__topbar h2 {
    font-size: 26px;
  }

  .der-global-search__form {
    grid-template-columns: 1fr;
  }

  .der-global-search__form input[type="search"] {
    height: 54px;
    padding-right: 16px;
  }

  .der-global-search__form button {
    min-height: 48px;
  }

  .der-global-search-group__grid {
    grid-template-columns: 1fr;
  }

  .der-global-search-result {
    grid-template-columns: 64px minmax(0, 1fr);
    min-height: 76px;
  }

  .der-global-search-result__media {
    width: 64px;
    height: 64px;
  }

  .der-global-search-trigger__text {
    position: static;
    width: auto;
    height: auto;
    overflow: visible;
    clip-path: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .der-global-search *,
  .der-shop-filters,
  .der-global-search-result {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}
