/* product-picker.css - cascade product type selector */
.ptp { position: relative; width: 100%; }
.ptp-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 12px;
  border: 1px solid var(--border, #e5e5e5);
  border-radius: var(--radius-sm, 6px);
  font-size: 13px;
  color: var(--text, #1a1a1a);
  background: var(--bg, #fff);
  cursor: pointer;
  text-align: left;
  font-family: inherit;
  transition: border-color var(--transition, 150ms ease);
}
.ptp-trigger:hover { border-color: var(--border-hover, #d4d4d4); }
.ptp.open .ptp-trigger { border-color: var(--primary, #0d9488); box-shadow: 0 0 0 3px rgba(13,148,136,0.06); }
.ptp-trigger-text {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ptp-trigger-text.placeholder { color: var(--text-faint, #9ca3af); }
.ptp-chevron {
  flex-shrink: 0;
  font-size: 12px;
  color: var(--text-faint, #9ca3af);
  transition: transform .2s;
}
.ptp.open .ptp-chevron { transform: rotate(180deg); }

.ptp-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  z-index: 200;
  background: var(--bg, #fff);
  border: 1px solid var(--border, #e5e5e5);
  border-radius: var(--radius, 8px);
  box-shadow: 0 4px 20px rgba(0,0,0,.08);
  overflow: hidden;
}
.ptp-search {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border, #e5e5e5);
  background: #f8fafb;
}
.ptp-search-icon { font-size: 14px; color: var(--text-faint, #9ca3af); flex-shrink: 0; }
.ptp-search input {
  flex: 1;
  border: none;
  background: transparent;
  padding: 0;
  font-size: 13px;
  outline: none;
}
.ptp-search input::placeholder { color: var(--text-faint, #9ca3af); }

.ptp-body {
  display: flex;
  min-height: 220px;
  max-height: 320px;
}
.ptp-col {
  list-style: none;
  margin: 0;
  padding: 6px 0;
  overflow-y: auto;
  flex: 1;
}
.ptp-col-cat {
  flex: 0 0 42%;
  max-width: 42%;
  border-right: 1px solid var(--border, #e5e5e5);
  background: #f8fafb;
}
.ptp-col-item { flex: 1; background: var(--bg, #fff); }

.ptp-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding: 8px 12px;
  font-size: 13px;
  color: var(--text, #1a1a1a);
  cursor: pointer;
  line-height: 1.35;
  transition: background var(--transition, 150ms ease);
}
.ptp-item:hover { background: #f3f4f6; }
.ptp-item.active {
  background: var(--primary-light, #f0fdfa);
  color: var(--primary, #0d9488);
  font-weight: 500;
}
.ptp-item.selected {
  color: var(--primary, #0d9488);
  font-weight: 500;
}
.ptp-item-arrow {
  font-size: 11px;
  color: var(--text-faint, #9ca3af);
  flex-shrink: 0;
}
.ptp-item-label {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ptp-empty {
  padding: 24px 12px;
  text-align: center;
  font-size: 13px;
  color: var(--text-faint, #9ca3af);
}

@media (max-width: 520px) {
  .ptp-body { min-height: 200px; max-height: 280px; }
  .ptp-col-cat { flex: 0 0 38%; max-width: 38%; }
  .ptp-item { padding: 10px 10px; font-size: 12px; }
}
