/* ====== Marco aanpassing Grammer Zoekbalk ====== */

/* Verberg de Ajax Search plugin balk */
.dgwt-wcas-search-wrapp {
  display: none !important;
}

/* Onze eigen zoekbalk in dezelfde container */
.marco-zoekbalk {
  display: flex;
  position: relative;
  width: 100%;
  max-width: 500px;
}

.marco-zoekbalk input[type="text"] {
  flex: 1;
  padding: 9px 36px 9px 14px;
  border: 2px solid #5a8fc2;
  border-right: none;
  border-radius: 4px 0 0 4px;
  font-size: 15px;
  outline: none;
  color: #333;
  background: #fff;
  transition: border-color 0.15s;
}

.marco-zoekbalk input[type="text"]:focus {
  border-color: #085096;
}

.marco-zoekbalk-wissen {
  display: none;
  align-items: center;
  justify-content: center;
  width: 34px;
  background: #fff;
  border: 2px solid #5a8fc2;
  border-left: none;
  border-right: none;
  color: #aaa;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  padding: 0;
  flex-shrink: 0;
  transition: color 0.15s;
}
.marco-zoekbalk-wissen:hover { color: #085096; }
.marco-zoekbalk-wissen.zichtbaar { display: flex; }

.marco-zoekbalk-knop {
  padding: 9px 20px;
  background: #085096;
  color: #fff;
  border: none;
  border-radius: 0 4px 4px 0;
  cursor: pointer;
  font-size: 15px;
  font-weight: 700;
  transition: background 0.15s;
  white-space: nowrap;
}
.marco-zoekbalk-knop:hover {
  background: #063d74;
}

/* Dropdown — positie wordt via JS gezet (fixed, body-level) */
.marco-zoekbalk-dropdown {
  display: none;
  background: #fff;
  border: 1px solid #ccc;
  border-top: none;
  border-radius: 0 0 4px 4px;
  box-shadow: 0 6px 16px rgba(0,0,0,0.12);
  z-index: 999999;
}
.marco-zoekbalk-dropdown.actief { display: block; }

/* Filterbar met checkboxes */
.marco-zoekbalk-filters {
  display: flex;
  gap: 6px;
  padding: 8px 12px;
  border-bottom: 1px solid #eee;
  background: #f8f8f8;
  flex-wrap: wrap;
}
.marco-filter-label {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  font-weight: 600;
  color: #555;
  cursor: pointer;
  padding: 3px 10px;
  border: 1px solid #ddd;
  border-radius: 12px;
  background: #fff;
  transition: background 0.15s, border-color 0.15s;
  user-select: none;
}
.marco-filter-label:hover {
  border-color: #085096;
  color: #085096;
}
.marco-filter-label input[type="checkbox"] {
  display: none;
}
.marco-filter-check {
  width: 13px;
  height: 13px;
  border: 1.5px solid #bbb;
  border-radius: 3px;
  display: inline-block;
  flex-shrink: 0;
  background: #fff;
  transition: background 0.15s, border-color 0.15s;
}
.marco-filter-label:has(input:checked) {
  background: #085096;
  border-color: #085096;
  color: #fff;
}
.marco-filter-label:has(input:checked) .marco-filter-check {
  background: #fff;
  border-color: #fff;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='11' height='9'%3E%3Cpath d='M1 4l3 3 6-6' stroke='%23085096' stroke-width='2' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
}
.marco-filter-aantal {
  color: #999;
  font-weight: 400;
}
.marco-filter-label:has(input:checked) .marco-filter-aantal {
  color: rgba(255,255,255,0.75);
}

.marco-zoekbalk-resultaten-wrap { position: relative; }

.marco-zoekbalk-resultaten-scroll {
  max-height: 380px;
  overflow-y: auto;
}

.marco-zoekbalk-resultaten-wrap::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 40px;
  background: linear-gradient(to bottom, rgba(255,255,255,0) 0%, rgba(255,255,255,0.95) 100%);
  pointer-events: none;
  transition: opacity 0.2s;
}
.marco-zoekbalk-resultaten-wrap.onderaan::after { opacity: 0; }

.marco-zoekbalk-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 9px 16px;
  border-bottom: 1px solid #eee;
  text-decoration: none;
  color: #333;
  transition: background 0.15s;
}
.marco-zoekbalk-item:hover { background: #f0f6fc; }
.marco-zoekbalk-item:last-child { border-bottom: none; }

.marco-zoekbalk-item img {
  width: 45px;
  height: 60px;
  object-fit: cover;
  object-position: center top;
  flex-shrink: 0;
  border-radius: 3px;
}
.marco-zoekbalk-item:hover img { mix-blend-mode: multiply; }

.marco-zoekbalk-naam {
  font-size: 14px;
  font-weight: 600;
  color: #085096;
  line-height: 1.3;
}
.marco-zoekbalk-cat {
  font-size: 12px;
  color: #888;
  margin-top: 2px;
}

.marco-zoekbalk-geen-resultaten {
  padding: 14px 16px;
  color: #888;
  font-size: 14px;
}

.marco-zoekbalk-alle {
  display: block;
  padding: 11px 16px;
  text-align: center;
  font-size: 14px;
  font-weight: 700;
  color: #085096;
  background: #f0f6fc;
  border-top: 2px solid #5a8fc2;
  cursor: pointer;
  transition: background 0.15s;
  text-decoration: none;
}
.marco-zoekbalk-alle:hover { background: #ddeaf7; }

/* Preview naast dropdown */
.marco-zoekbalk-preview {
  position: fixed;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  box-shadow: 0 8px 28px rgba(0,0,0,0.15);
  padding: 16px;
  width: 200px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease;
  z-index: 10000;
}
.marco-zoekbalk-preview.zichtbaar { opacity: 1; }
.marco-zoekbalk-preview img {
  width: 100%;
  height: 160px;
  object-fit: contain;
  display: block;
}
.marco-zoekbalk-preview-naam {
  margin-top: 10px;
  font-size: 13px;
  font-weight: 600;
  color: #333;
  text-align: center;
  line-height: 1.3;
}

/* ====== Einde Marco aanpassing Grammer Zoekbalk ====== */
