﻿/* R10 2026-10-27 - Cuisine Atlas: each cuisine on/off toggle takes its cuisine colour.
   --cuisine-color is set per toggle by js/atlas-cuisine-toggles-r10.js from
   WTE_CATALOG.PRIMARY_CUISINES[].color (same source as the dot and the pins).
   Overrides gui-fix-r4.css item 4 for [data-cui] toggles only; other toggles stay gold. */
#filterList .filter-row .toggle[data-cui] {
  --cc: var(--cuisine-color, #d4af37);
  position: relative;
  background: rgba(12, 10, 7, .72) !important;
  border: 1px solid color-mix(in srgb, var(--cc) 70%, transparent) !important;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, .55) !important;
  transition: background-color .18s ease, box-shadow .18s ease, border-color .18s ease;
}
#filterList .filter-row .toggle[data-cui]::after {
  background: color-mix(in srgb, var(--cc) 45%, #3a3428) !important;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, .35);
  opacity: .85;
}
#filterList .filter-row .toggle[data-cui][aria-pressed="true"] {
  background: linear-gradient(180deg, color-mix(in srgb, var(--cc) 88%, #fff) 0%, var(--cc) 100%) !important;
  border-color: color-mix(in srgb, var(--cc) 60%, #f3d77a) !important;
  box-shadow: 0 0 8px color-mix(in srgb, var(--cc) 45%, transparent), inset 0 1px 0 rgba(255, 255, 255, .25) !important;
}
#filterList .filter-row .toggle[data-cui][aria-pressed="true"]::after {
  background: linear-gradient(180deg, #fffaf0, #f3e2a6) !important;
  box-shadow: 0 0 0 1px rgba(212, 175, 55, .9), 0 1px 3px rgba(0, 0, 0, .45);
  opacity: 1;
}
/* dim the row's cuisine dot + label when that cuisine is off */
#filterList .filter-row[data-cui-row].r10-off .cui-atlas-mark { opacity: .4; filter: saturate(.6); }
#filterList .filter-row[data-cui-row].r10-off > span:nth-child(2) { color: rgba(245, 236, 210, .62); }
#filterList .filter-row .toggle[data-cui]:focus-visible {
  outline: 2px solid #d4af37 !important; outline-offset: 3px !important;
}
@media (prefers-reduced-motion: reduce) {
  #filterList .filter-row .toggle[data-cui], #filterList .filter-row .toggle[data-cui]::after { transition: none !important; }
}

/* track geometry: slim pill (the old content-box padding was lost when r4 used the
   background shorthand, which made the gold toggles look like tall blobs). Touch
   target kept >= 44px via ::before. */
#filterList .filter-row .toggle[data-cui] {
  box-sizing: border-box !important; width: 42px !important; height: 24px !important; padding: 0 !important;
  border-radius: 999px !important; flex: 0 0 auto; align-self: center;
}
#filterList .filter-row .toggle[data-cui]::before { content: ""; position: absolute; inset: -10px -4px; }
#filterList .filter-row .toggle[data-cui]::after {
  width: 18px !important; height: 18px !important; top: 2px !important; left: 2px !important; border-radius: 50%;
  transition: left .18s ease, background-color .18s ease;
}
#filterList .filter-row .toggle[data-cui][aria-pressed="true"]::after { left: 20px !important; }
