/**
 * NativeSelect 组件样式 - 100% 一比一复刻 MUI
 * 对应 MUI: packages/mui-material/src/NativeSelect/NativeSelect.js
 */

/* =============================================
   Root 基础样式
   ============================================= */
.MuiNativeSelect-root {
  position: relative;
}

/* =============================================
   Select 基础样式
   ============================================= */
.MuiNativeSelect-select {
  font-family: "Roboto", "Helvetica", "Arial", sans-serif;
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.4375em;
  letter-spacing: 0.00938em;
  color: rgba(0, 0, 0, 0.87);
  background-color: transparent;
  border: none;
  border-bottom: 1px solid rgba(0, 0, 0, 0.42);
  border-radius: 0;
  padding: 16.5px 14px;
  cursor: pointer;
  min-width: 16px;
  user-select: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  transition: border-bottom-color 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;
}

.MuiNativeSelect-select:focus {
  border-bottom-color: #1976d2;
  border-radius: 0;
  outline: none;
}

/* =============================================
   变体样式
   ============================================= */
.MuiNativeSelect-standard {
  padding-right: 24px;
}

.MuiNativeSelect-filled {
  padding-right: 32px;
  border-top-left-radius: 4px;
  border-top-right-radius: 4px;
  border: 1px solid rgba(0, 0, 0, 0.23);
  background-color: rgba(0, 0, 0, 0.06);
}

.MuiNativeSelect-outlined {
  padding-right: 32px;
  border: 1px solid rgba(0, 0, 0, 0.23);
  border-radius: 4px;
}

.MuiNativeSelect-outlined:focus {
  border-color: #1976d2;
  border-radius: 4px;
}

/* =============================================
   状态样式
   ============================================= */
.MuiNativeSelect-select.Mui-disabled {
  cursor: default;
  color: rgba(0, 0, 0, 0.42);
  border-bottom-style: dotted;
}

.MuiNativeSelect-select.Mui-error {
  border-bottom-color: #d32f2f;
}

.MuiNativeSelect-outlined.Mui-error {
  border-color: #d32f2f;
}

.MuiNativeSelect-filled.Mui-error {
  border-color: #d32f2f;
}

/* =============================================
   多选样式
   ============================================= */
.MuiNativeSelect-select[multiple] {
  height: auto;
  min-height: 1.4375em;
  padding: 8.5px 14px;
}

/* =============================================
   选项样式
   ============================================= */
.MuiNativeSelect-select:not([multiple]) option,
.MuiNativeSelect-select:not([multiple]) optgroup {
  background-color: #fff;
  color: rgba(0, 0, 0, 0.87);
}

/* =============================================
   图标样式
   ============================================= */
.MuiNativeSelect-icon {
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  color: rgba(0, 0, 0, 0.54);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  width: 24px;
  height: 24px;
}

.MuiNativeSelect-iconOpen {
  transform: translateY(-50%) rotate(180deg);
}

.MuiNativeSelect-iconFilled {
  right: 7px;
}

.MuiNativeSelect-iconOutlined {
  right: 7px;
}

.MuiNativeSelect-iconStandard {
  right: 0;
}

.MuiNativeSelect-icon.Mui-disabled {
  color: rgba(0, 0, 0, 0.26);
}

/* =============================================
   焦点样式
   ============================================= */
.MuiNativeSelect-root:focus {
  outline: none;
}

.MuiNativeSelect-select:focus-visible {
  outline: 2px solid #1976d2;
  outline-offset: -2px;
}

/* =============================================
   悬停样式
   ============================================= */
.MuiNativeSelect-select:hover:not(.Mui-disabled) {
  border-bottom-color: rgba(0, 0, 0, 0.87);
}

.MuiNativeSelect-outlined:hover:not(.Mui-disabled) {
  border-color: rgba(0, 0, 0, 0.87);
}

.MuiNativeSelect-filled:hover:not(.Mui-disabled) {
  border-color: rgba(0, 0, 0, 0.87);
  background-color: rgba(0, 0, 0, 0.09);
}
