/* === ALLERGEN FILTER – RENSAD VERSION === */

#af-allergen-filter {}

.af-search {
  position: relative;
  text-align: center;
  margin-bottom: 12px;
  display: flex;
  justify-content: center;
}

/* 🔍 Själva sökrutan */
#af-search {
  width: 60%;
  max-width: 420px;
  padding: 8px 12px;
  border-radius: 6px;
  border: 1px solid #ccc;
  font-size: 15px;
  box-sizing: border-box;
  background-color: #fff;
}

#af-search::-webkit-search-cancel-button{
	-webkit-appearance: auto;
}

/* === FILTER === */
.af-filters {
  text-align: center;
  margin-bottom: 12px;
}
.af-filters label {
  margin-right: 12px;
}

/* === RESTAURANGFILTER === */
.af-restaurant-filter {
  text-align: center;
  margin-bottom: 10px;
}
.af-restaurant-filter label {
  margin-right: 15px;
  cursor: pointer;
}

/* === PRODUKTKORT === */
.af-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 12px;
}

.af-card {
  background: #fff;
  border-radius: 8px;
  padding: 12px;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.06);
  cursor: pointer;
  transition: transform 0.08s ease, box-shadow 0.08s ease;
}
.af-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
}
.af-card-title {
  margin: 0 0 8px 0;
  font-size: 16px;
}
.af-card-ingredients {
  font-size: 13px;
  color: #444;
  margin-top: 6px;
  line-height: 1.3;
  white-space: pre-line;
}

/* === BADGES === */
.af-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
  align-items: center;
}

.af-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 12px;
  background: #f2f2f2;
  color: #222;
  box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.02);
}

/* === INGA RESULTAT === */
.af-no-results {
  grid-column: 1 / -1;
  padding: 16px;
  text-align: center;
  color: #666;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.03);
}

/* === MODAL === */
.af-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  justify-content: center;
  align-items: center;
  z-index: 9999;
}
.af-modal-content {
  background: #fff;
  padding: 20px;
  border-radius: 12px;
  max-width: 500px;
  width: 90%;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}
.af-close {
  float: right;
  font-size: 24px;
  cursor: pointer;
}
.af-modal-allergens {
  margin-top: 16px;
  display: grid;
  gap: 6px;
}

/* === ALLERGEN-FÄRGER === */
.af-allergen {
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 14px;
}
.af-gluten { background: #ffe0b2; color: #e65100; }
.af-gluten-free { background: #e8f5e9; color: #1b5e20; }
.af-laktos { background: #bbdefb; color: #0d47a1; }
.af-laktos-free { background: #e8f5e9; color: #1b5e20; }
.af-notter { background: #d7ccc8; color: #4e342e; }
.af-notter-free { background: #e8f5e9; color: #1b5e20; }
.af-vegan { background: #c8e6c9; color: #1b5e20; }
.af-not-vegan { background: #ffcdd2; color: #b71c1c; }
.af-agg { background:#fff9c4; color:#795548; }
.af-agg-free { background:#e8f5e9; color:#1b5e20; }
.af-mjolkprotein { background:#c5cae9; color:#283593; }
.af-mjolkprotein-free { background:#e8f5e9; color:#1b5e20; }


/* === INGREDIENS-HIGHLIGHT === */
.af-ingredient-highlight {
  font-weight: bold;
}
