.filter-dropdown-wrap {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
}

/* 触发按钮 */
/* H5: px-3=12px→22rpx, py-2=8px→14rpx, bg-gray-50=#f9fafb, rounded-lg=8px→14rpx, border-gray-100=#f3f4f6 */
/* 增加 padding 匹配 H5 按钮高度 37.33px */
.filter-dropdown {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4rpx;
  padding: 16rpx 22rpx;
  background: #f9fafb;
  border-radius: 14rpx;
  border: 2rpx solid #f3f4f6;
  transition: border-color 0.2s, background-color 0.2s;
}

.filter-dropdown--active {
  border-color: var(--color-primary);
  background: var(--color-primary-light);
}

/* H5: text-sm=14px→24rpx, font-medium=500 for sort label */
.filter-label {
  font-size: 24rpx;
  color: var(--color-gray-12);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 500;
}

.filter-dropdown--active .filter-label {
  color: var(--color-primary);
  font-weight: 600;
}

/* 已选中筛选项 — 粗字体标记当前选择 */
.filter-dropdown--selected .filter-label {
  font-weight: 600;
}

/* 箭头旋转动画 */
.filter-arrow {
  transition: transform 0.25s ease;
  color: var(--color-gray-6);
}

.filter-arrow--up {
  transform: rotate(180deg);
  color: var(--color-primary);
}

/* 遮罩层 — 半透明黑色背景，忠于 H5 原型 */
.dropdown-mask {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 999;
}

/* 下拉面板 — 全屏宽度，固定定位，从筛选栏下方展开 */
.dropdown-panel {
  position: fixed;
  left: 0;
  right: 0;
  max-height: 60vh;
  overflow-y: auto;
  background: #ffffff;
  border-radius: 0 0 28rpx 28rpx;
  box-shadow: 0 16rpx 48rpx rgba(0, 0, 0, 0.15);
  z-index: 1000;
  opacity: 0;
  transform: translateY(-16rpx);
  transition: opacity 0.25s ease, transform 0.25s ease;
  pointer-events: none;
  padding: 16rpx 0;
}

.dropdown-panel--show {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

/* 选项项 — 更大的 padding，忠于 H5 原型 */
.dropdown-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 34rpx 32rpx;
  font-size: 28rpx;
  color: var(--color-gray-12, #2c2c2c);
  transition: background-color 0.15s;
}

.dropdown-item:active {
  background: var(--color-gray-1, #f3f3f3);
}

.dropdown-item--active {
  color: var(--color-primary, #0052d9);
  font-weight: 600;
}

.dropdown-item + .dropdown-item {
  border-top: 1rpx solid rgba(0, 0, 0, 0.03);
}
