.filters-desktop{
  position:sticky;
  top:114px;
  background:var(--panel);
  border:1px solid var(--line);
  border-radius:var(--radius);
  padding:16px;
  box-shadow:var(--shadow);
}

.filter-group{
  margin-bottom:18px;
  padding:13px;
  border:1px solid var(--line);
  border-radius:16px;
  background:var(--panel-2);
}

.filter-group:last-child{
  margin-bottom:0;
}

.filter-group h3{
  display:flex;
  align-items:center;
  gap:8px;
  margin:0 0 12px;
  font-size:.88rem;
  line-height:1.2;
  letter-spacing:.01em;
  text-transform:none;
}

.badge{
  display:inline-grid;
  place-items:center;
  min-width:22px;
  height:22px;
  padding:0 6px;
  border-radius:999px;
  background:rgba(255,255,255,.08);
  color:var(--muted);
  font-size:.74rem;
  font-weight:900;
}

/* Grundfarben als Plek-Icons */

.color-swatches{
  display:grid;
  grid-template-columns:repeat(5,46px);
  gap:10px;
  align-items:center;
}

.swatch{
  width:46px;
  height:46px;
  border:none;
  background:none;
  cursor:pointer;
  position:relative;
  padding:0;
}

.swatch img{
  width:100%;
  height:100%;
  object-fit:contain;
  display:block;
  filter:drop-shadow(0 2px 6px rgba(0,0,0,.42));
  transition:.18s ease;
}

.swatch:hover img{
  transform:translateY(-2px) scale(1.04);
}

.swatch[aria-pressed="true"] img{
  transform:scale(1.08);
  filter:
    drop-shadow(0 0 0 2px #e14b4b)
    drop-shadow(0 5px 14px rgba(0,0,0,.55));
}

.swatch[aria-pressed="true"]::after{
  content:"✓";
  position:absolute;
  inset:0;
  display:grid;
  place-items:center;
  color:#fff;
  font-weight:900;
  font-size:1.02rem;
  text-shadow:0 1px 5px #000;
}

.swatch.is-zero{
  opacity:.28;
  filter:grayscale(.8);
}

.swatch-count,
.ink-dot-count{
  position:absolute;
  right:-7px;
  bottom:-5px;
  min-width:18px;
  height:18px;
  padding:0 4px;
  border-radius:999px;
  background:var(--panel);
  border:1px solid var(--line);
  color:var(--text);
  display:grid;
  place-items:center;
  font-size:.66rem;
  font-weight:900;
  line-height:1;
  pointer-events:none;
  opacity:1;
}

/* Schriftfarben als kleine Punkte */

.ink-dots{
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:11px;
  padding:2px 0 4px;
}

.ink-dot{
  width:27px;
  height:27px;
  position:relative;
  display:grid;
  place-items:center;
  border:0;
  background:transparent;
  padding:0;
  cursor:pointer;
}

.ink-dot-color{
  width:24px;
  height:24px;
  display:block;
  border-radius:999px;
  background:var(--ink-style);
  border:1px solid rgba(255,255,255,.35);
  box-shadow:
    inset 0 1px 2px rgba(255,255,255,.28),
    inset 0 -3px 6px rgba(0,0,0,.35),
    0 4px 10px rgba(0,0,0,.3);
  transition:.16s ease;
}

.ink-dot:hover .ink-dot-color{
  transform:translateY(-1px) scale(1.08);
}

.ink-dot[aria-pressed="true"] .ink-dot-color,
.ink-dot.active .ink-dot-color{
  transform:scale(1.12);
  box-shadow:
    0 0 0 2px #e14b4b,
    0 0 0 5px rgba(225,75,75,.18),
    inset 0 1px 2px rgba(255,255,255,.28),
    inset 0 -3px 6px rgba(0,0,0,.35),
    0 5px 14px rgba(0,0,0,.45);
}

.ink-dot[aria-pressed="true"]::after,
.ink-dot.active::after{
  content:"";
  position:absolute;
  right:0;
  bottom:0;
  width:8px;
  height:8px;
  border-radius:999px;
  background:#e14b4b;
  border:1px solid var(--panel-2);
}

.ink-dot.is-zero{
  opacity:.32;
  filter:grayscale(.85);
}

/* Suchfelder */

.filter-search{
  width:100%;
  padding:9px 10px;
  margin-bottom:10px;
  border-radius:11px;
  border:1px solid var(--line);
  background:var(--panel);
  color:var(--text);
  font-size:.88rem;
}

.filter-search::placeholder{
  color:var(--muted);
}

/* Aufdruck als Bildauswahl */

.print-grid{
  display:grid;
  grid-template-columns:repeat(2, minmax(0,1fr));
  gap:8px;
  max-height:400px;
  overflow:auto;
  padding-right:2px;
  scrollbar-width:thin;
}

.print-chip{
  display:grid;
  grid-template-rows:auto auto;
  align-items:center;
  justify-items:center;
  gap:6px;
  min-height:78px;
  padding:8px 7px;
  border-radius:12px;
  border:1px solid var(--line);
  background:rgba(255,255,255,.04);
  color:var(--text);
  cursor:pointer;
  text-align:center;
  transition:.15s ease;
}

.print-chip:hover{
  background:rgba(255,255,255,.075);
  transform:translateY(-1px);
}

.print-chip-top{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:7px;
  width:100%;
}

.print-thumb-wrap{
  width:34px;
  height:34px;
  display:grid;
  place-items:center;
  border-radius:9px;
  background:rgba(255,255,255,.055);
  overflow:hidden;
  flex:0 0 auto;
}

.print-chip img{
  width:100%;
  height:100%;
  object-fit:contain;
  display:block;
  filter:drop-shadow(0 2px 5px rgba(0,0,0,.4));
}

.print-count{
  min-width:22px;
  height:22px;
  padding:0 6px;
  border-radius:999px;
  background:var(--panel);
  border:1px solid var(--line);
  color:var(--text);
  display:grid;
  place-items:center;
  font-size:.7rem;
  font-weight:900;
  line-height:1;
  flex:0 0 auto;
}

.print-label{
  width:100%;
  min-width:0;
  white-space:normal;
  overflow:visible;
  text-overflow:clip;
  overflow-wrap:anywhere;
  hyphens:auto;
  font-size:.72rem;
  font-weight:750;
  line-height:1.15;
  color:var(--text);
}

.print-chip.active,
.print-chip[aria-pressed="true"]{
  border-color:#e14b4b;
  background:rgba(225,75,75,.13);
  box-shadow:0 0 0 2px rgba(225,75,75,.16);
}

.print-chip.active .print-thumb-wrap,
.print-chip[aria-pressed="true"] .print-thumb-wrap{
  outline:2px solid #e14b4b;
  outline-offset:1px;
}

.print-chip.is-zero{
  opacity:.34;
  filter:grayscale(.8);
}

.print-chip.missing-print .print-thumb-wrap::before{
  content:"?";
  color:var(--muted);
  font-weight:900;
}

.print-chip.missing-print img{
  display:none;
}

/* Alte Checkboxen bleiben als Fallback, falls noch irgendwo genutzt */

.filter-options{
  display:grid;
  gap:6px;
  max-height:280px;
  overflow:auto;
  padding-right:2px;
  scrollbar-width:thin;
}

.check{
  display:flex;
  align-items:center;
  gap:9px;
  padding:8px 9px;
  border-radius:11px;
  border:1px solid var(--line);
  background:rgba(255,255,255,.04);
  cursor:pointer;
  user-select:none;
  min-height:38px;
  font-size:.88rem;
}

.check:hover{
  background:rgba(255,255,255,.08);
}

.check input{
  width:16px;
  height:16px;
  accent-color:#e14b4b;
  flex:0 0 auto;
}

.check .label-text{
  min-width:0;
  overflow-wrap:anywhere;
  font-weight:700;
}

.check .count{
  margin-left:auto;
  color:var(--muted);
  font-size:.78rem;
  white-space:nowrap;
}

.check.is-zero{
  opacity:.42;
}

.check.active{
  border-color:#e14b4b;
  background:rgba(225,75,75,.12);
}

/* Aktive Filter-Chips + Reset direkt daneben */

.active-filter-bar{
  display:flex;
  align-items:center;
  gap:9px;
  flex-wrap:wrap;
  margin-bottom:18px;
}

.chips{
  display:flex;
  align-items:center;
  gap:9px;
  flex-wrap:wrap;
}

.chip{
  display:inline-flex;
  align-items:center;
  gap:7px;
  padding:7px 10px;
  border-radius:999px;
  border:1px solid var(--line);
  background:rgba(255,255,255,.06);
  color:var(--text);
  font-size:.86rem;
  font-weight:750;
}

.chip-remove{
  border:0;
  background:transparent;
  color:#e14b4b;
  font-size:1rem;
  line-height:1;
  font-weight:900;
  cursor:pointer;
  padding:0;
}

.chip-remove:hover{
  color:#ff6b6b;
}

.chip-reset{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:7px 12px;
  border-radius:999px;
  border:1px solid rgba(225,75,75,.75);
  background:#e14b4b;
  color:#fff;
  font-size:.86rem;
  font-weight:900;
  cursor:pointer;
}

.chip-reset:hover{
  background:#f05a5a;
}

#reset-top{
  display:none !important;
}

/* Mobile */

.filters-mobile .is-zero{
  display:none !important;
}

@media (max-width:768px){
  .filter-group h3{
    font-size:.9rem;
  }

  .color-swatches{
    grid-template-columns:repeat(4,50px);
    gap:10px;
  }

  .swatch{
    width:50px;
    height:50px;
  }

  .ink-dots{
    gap:13px;
  }

  .ink-dot{
    width:30px;
    height:30px;
  }

  .ink-dot-color{
    width:27px;
    height:27px;
  }

  .print-grid{
    grid-template-columns:1fr;
    max-height:none;
  }

  .print-chip{
    min-height:82px;
    padding:9px;
  }

  .print-thumb-wrap{
    width:38px;
    height:38px;
  }

  .print-label{
    font-size:.76rem;
  }

  .chip-reset{
    width:100%;
    margin-top:2px;
  }
}
