/* =========================================================
   matrix-preferences.css - V4.4 polish — Preference Board.

   Layout:
   1. Lane chooser ("Drop next tag into…") with three target chips
   2. Deck of tags grouped by editorial category
   3. Three lanes (Must / Nice / Hard No) always visible

   Design notes:
   - Single click on a deck tag drops it into the currently
     selected target lane. Click again while in the target lane
     to remove. No tap-to-cycle.
   - Hard No is visually distinct via red-tint border and bolder
     top edge.
   - Aria-labels are always human strings ("In-place income"),
     never raw enum values.
   ========================================================= */

/* ---- Lane chooser (target selector) ---- */
.preference-target {
  margin-bottom: 22px;
}

.preference-target-heading {
  font-family: "JetBrains Mono", sans-serif;
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--brass, #a67c52);
  margin: 0 0 10px;
}

.preference-target-list {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.preference-target-btn {
  background: transparent;
  border: 1px solid rgba(166, 124, 82, 0.40);
  color: var(--stone, #b6a98c);
  font-family: "JetBrains Mono", sans-serif;
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 7px 14px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.preference-target-btn:hover {
  border-color: var(--brass-bright, #c79c70);
  color: var(--ivory, #ece4d2);
}

.preference-target-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  background: rgba(166, 124, 82, 0.50);
}

.preference-target-btn-must_have .preference-target-dot { background: #B98852; }
.preference-target-btn-nice_to_have .preference-target-dot { background: #B98852; opacity: 0.6; }
.preference-target-btn-hard_no .preference-target-dot { background: #C97A66; }

.preference-target-btn[aria-pressed="true"] {
  border-color: var(--brass-bright, #c79c70);
  color: var(--ivory, #ece4d2);
  background: rgba(185, 136, 82, 0.10);
}

.preference-target-btn-hard_no[aria-pressed="true"] {
  border-color: rgba(201, 122, 102, 0.85);
  background: rgba(201, 122, 102, 0.10);
}

/* ---- Deck (grouped tags) ---- */
.preference-deck {
  margin-bottom: 28px;
  border: 1px solid rgba(166, 124, 82, 0.35);
  background: rgba(10, 18, 19, 0.40);
  padding: 16px 16px 14px;
}

.preference-deck-group {
  margin-bottom: 14px;
}

.preference-deck-group:last-of-type {
  margin-bottom: 0;
}

.preference-deck-group-heading {
  font-family: "JetBrains Mono", sans-serif;
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--brass, #a67c52);
  margin: 0 0 8px;
}

.preference-deck-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.preference-deck-tag {
  background: transparent;
  border: 1px solid rgba(166, 124, 82, 0.40);
  color: var(--stone, #b6a98c);
  font-family: "JetBrains Mono", sans-serif;
  font-size: 12px;
  letter-spacing: 0.04em;
  padding: 6px 10px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.preference-deck-tag:hover {
  border-color: var(--brass-bright, #c79c70);
  color: var(--ivory, #ece4d2);
  background: rgba(185, 136, 82, 0.05);
}

.preference-deck-tag-dot {
  display: inline-block;
  width: 5px;
  height: 5px;
}

.preference-deck-tag-dot.is-must_have { background: #B98852; }
.preference-deck-tag-dot.is-nice_to_have { background: #B98852; opacity: 0.55; }
.preference-deck-tag-dot.is-hard_no { background: #C97A66; }

.preference-deck-tag.is-in-must_have {
  border-color: rgba(185, 136, 82, 0.85);
  background: rgba(185, 136, 82, 0.10);
  color: var(--ivory, #ece4d2);
}

.preference-deck-tag.is-in-nice_to_have {
  border-color: rgba(166, 124, 82, 0.55);
  background: rgba(166, 124, 82, 0.06);
  color: var(--ivory, #ece4d2);
}

.preference-deck-tag.is-in-hard_no {
  border-color: rgba(201, 122, 102, 0.85);
  background: rgba(201, 122, 102, 0.10);
  color: var(--ivory, #ece4d2);
}

/* ---- Three-lane board ---- */
.preference-board {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
  margin-bottom: 12px;
}

@media (min-width: 800px) {
  .preference-board {
    grid-template-columns: repeat(3, 1fr);
  }
}

.preference-lane {
  border: 1px solid rgba(166, 124, 82, 0.35);
  background: rgba(16, 37, 30, 0.20);
  padding: 14px;
  min-height: 120px;
}

.preference-lane-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 12px;
}

.preference-lane-title {
  font-family: "JetBrains Mono", sans-serif;
  font-size: 12px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--brass-bright, #c79c70);
  margin: 0;
}

.preference-lane-count {
  font-family: "JetBrains Mono", sans-serif;
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--stone-dim, #7a7264);
}

.preference-hard_no {
  border-color: rgba(199, 80, 80, 0.55);
  background: rgba(45, 18, 12, 0.45);
  border-top-width: 2px;
  border-top-color: rgba(199, 80, 80, 0.85);
}

.preference-hard_no .preference-lane-title {
  color: var(--ivory, #ece4d2);
  letter-spacing: 0.18em;
}

.preference-hard_no .preference-tag {
  border-color: rgba(199, 80, 80, 0.40);
  background: rgba(60, 20, 14, 0.40);
}

.preference-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.preference-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 4px 4px 10px;
  border: 1px solid rgba(166, 124, 82, 0.40);
  background: rgba(16, 37, 30, 0.40);
  font-family: "Newsreader", Georgia, serif;
  font-size: 13px;
  color: var(--ivory, #ece4d2);
}

.preference-tag-label {
  line-height: 1.2;
}

.preference-tag-remove {
  background: transparent;
  border: 0;
  color: var(--stone, #b6a98c);
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
  padding: 2px 6px;
  letter-spacing: 0;
}

.preference-tag-remove:hover {
  color: var(--brass-bright, #c79c70);
}

.preference-empty {
  font-family: "Newsreader", Georgia, serif;
  font-style: italic;
  font-size: 13px;
  color: var(--stone-dim, #7a7264);
  margin: 0;
}
