/* =========================================================
   WORKORDER-TECHNICIAN-PICKER.CSS
   Focused technician picker polish using the new theme system.

   This file intentionally patches only the technician picker area.
========================================================= */

/* =========================================================
   1. PICKER PANEL
========================================================= */
.workorder-picker-panel {
  max-height: 190px;
  overflow: hidden;
  padding: 0.6rem !important;
}

/* =========================================================
   2. TECHNICIAN GRID
========================================================= */
.technician-picker {
  display: grid !important;
  gap: 0.4rem !important;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)) !important;
  max-height: 160px;
  overflow-y: auto;
  padding: 0.1rem 0.35rem 0.1rem 0.1rem;
  scrollbar-gutter: stable;
}

/* =========================================================
   3. TECHNICIAN BUTTONS
========================================================= */
.technician-picker-option {
  align-items: center;
  background: var(--app-surface) !important;
  border: 1px solid var(--app-border) !important;
  border-radius: var(--radius-md) !important;
  box-shadow: var(--shadow-sm);
  color: var(--app-text) !important;
  display: inline-flex;
  gap: 0.4rem;
  justify-content: flex-start;
  min-height: 34px;
  min-width: 0;
  overflow: hidden;
  padding: 0.32rem 0.5rem !important;
  text-align: left;
  transition:
    background-color var(--transition-fast),
    border-color var(--transition-fast),
    box-shadow var(--transition-fast),
    transform var(--transition-fast);
  width: 100%;
}

.technician-picker-option:hover:not(:disabled):not(.is-selected) {
  background: color-mix(in srgb, var(--app-primary), transparent 94%) !important;
  border-color: color-mix(in srgb, var(--app-primary), transparent 55%) !important;
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.technician-picker-option.is-selected {
  background: var(--app-primary) !important;
  border-color: var(--app-primary) !important;
  box-shadow: var(--shadow-primary);
  color: var(--app-text-inverse) !important;
}

.technician-picker-option.is-selected:hover:not(:disabled) {
  background: var(--app-primary-hover) !important;
  border-color: var(--app-primary-hover) !important;
}

.technician-picker-icon {
  flex: 0 0 auto;
}

.technician-picker-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* =========================================================
   4. MOBILE
========================================================= */
@media (max-width: 767.98px) {
  .workorder-picker-panel {
    max-height: none;
  }

  .technician-picker {
    grid-template-columns: 1fr !important;
    max-height: 300px;
  }
}
