/* PrairieOps — grouped-picker.css
   Mirrors the signed-off Field Logs FL-UI4 equipment picker: trigger that
   inline-expands into a search box + collapsible type categories (count
   badge, gold match highlight, gold check on selected). Main-app dark tokens. */

.gp { position: relative; }

.gp-trigger {
  width: 100%; box-sizing: border-box;
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  min-height: 44px; padding: 11px 12px;
  border: 1px solid var(--border); border-radius: var(--radius-md);
  background: var(--bg-surface); color: var(--text-primary);
  font-size: 15px; font-family: inherit; text-align: left; cursor: pointer;
}
.gp-trigger.is-open { border-color: rgba(196, 144, 96, 0.55); }
.gp-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gp-label.is-empty { color: var(--text-muted); }
.gp-trigger-right { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }
.gp-clear { color: var(--text-muted); font-size: 14px; padding: 0 2px; cursor: pointer; }
.gp-chev { color: var(--text-muted); font-size: 16px; line-height: 1; transition: transform .25s ease; }
.gp-trigger.is-open .gp-chev { transform: rotate(180deg); }

/* Inline expand (grid-rows trick, same as FL). */
.gp-panel { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .30s cubic-bezier(.22, 1, .36, 1); }
.gp-panel.is-open { grid-template-rows: 1fr; }
.gp-panel-inner { overflow: hidden; min-height: 0; }
.gp-card {
  margin-top: 8px; overflow: hidden;
  background: var(--bg-surface); border: 1px solid var(--border); border-radius: var(--radius-md);
}
.gp-search {
  width: 100%; box-sizing: border-box; padding: 12px 14px;
  background: var(--bg-elevated); border: none; border-bottom: 1px solid var(--border);
  color: var(--text-primary); font-size: 15px; font-family: inherit; outline: none;
}
.gp-search::placeholder { color: var(--text-muted); }
.gp-list { max-height: 320px; overflow-y: auto; -webkit-overflow-scrolling: touch; }

.gp-cathead {
  display: flex; align-items: center; gap: 8px; padding: 12px 14px;
  cursor: pointer; user-select: none; border-bottom: 1px solid var(--bg-elevated);
}
.gp-cat-label { font-size: 12px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: var(--text-secondary); }
.gp-cat-count {
  font-size: 11px; color: var(--text-muted);
  background: var(--bg-elevated); border: 1px solid var(--border);
  border-radius: 999px; padding: 1px 8px;
}
.gp-cat-chev { margin-left: auto; color: var(--text-muted); font-size: 20px; line-height: 1; transform: rotate(-90deg); transition: transform .25s ease; }
.gp-cat.is-open .gp-cat-chev { transform: rotate(0deg); }
.gp-catbody { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .25s ease; }
.gp-cat.is-open .gp-catbody { grid-template-rows: 1fr; }
.gp-catbody-inner { overflow: hidden; min-height: 0; }

.gp-item {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 12px 14px 12px 26px; cursor: pointer;
  border-bottom: 1px solid var(--bg-elevated);
  font-size: 14px; color: var(--text-secondary);
}
.gp-item.is-selected { color: var(--brand, #c49060); }
.gp-check { color: var(--brand, #c49060); font-weight: 700; flex: 0 0 auto; }
.gp-mark { color: var(--brand, #c49060); font-weight: 600; }
.gp-empty { padding: 18px 14px; text-align: center; font-size: 13px; color: var(--text-muted); }
