/* ============================================================
   全站公共输入框样式 —— 同时兜底移动端交互细节
   ============================================================ */

/* 移动端点击不闪半透明方块（安卓 / 微信内置浏览器的 tap highlight） */
html,
button, a, input, select, textarea, label, summary, [onclick] {
    -webkit-tap-highlight-color: transparent;
}
/* 点完不留焦框，但键盘 Tab 聚焦时保留（无障碍） */
button:focus:not(:focus-visible),
a:focus:not(:focus-visible) { outline: none; }

/* 用户管理页面搜索框使用普通文本框格式 */
#userSearchInput {
    background: #fff !important;
    border-color: #E5E7EB !important;
    color: #333 !important;
}
#userSearchInput:focus {
    border-color: #1E3A5F !important;
    background: #fff !important;
}
#userSearchInput::placeholder {
    color: #9CA3AF !important;
}

/* ============================================
   全局文本输入框样式
   统一所有input/textarea/select的focus效果
   去掉box-shadow渲染，只保留深蓝色边框
   ============================================ */

/* 所有文本输入框基础样式 */
input[type="text"],
input[type="search"],
input[type="password"],
input[type="email"],
input[type="tel"],
input[type="number"],
input[type="date"],
input[type="datetime-local"],
input[type="url"],
input:not([type]),
textarea {
    background-color: #ffffff !important;
    border: 1px solid #D1D5DB !important;
    border-radius: 6px !important;
    transition: border-color 0.15s ease !important;
    outline: none !important;
    outline-width: 0 !important;
    box-shadow: none !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
}

/* 所有文本输入框focus样式：只保留深蓝色边框，去掉所有渲染效果 */
input[type="text"]:focus,
input[type="search"]:focus,
input[type="password"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus,
input[type="number"]:focus,
input[type="date"]:focus,
input[type="datetime-local"]:focus,
input[type="url"]:focus,
input:not([type]):focus,
textarea:focus,
input:focus,
textarea:focus {
    border-color: #1E3A5F !important;
    border-width: 1px !important;
    box-shadow: none !important;
    -webkit-box-shadow: none !important;
    -moz-box-shadow: none !important;
    outline: none !important;
    outline-width: 0 !important;
    -webkit-outline: none !important;
    background-color: #ffffff !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
}

/* focus-visible 也去掉渲染 */
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
    outline: none !important;
    box-shadow: none !important;
    border-color: #1E3A5F !important;
}

/* placeholder颜色 */
input::placeholder,
textarea::placeholder {
    color: #9CA3AF !important;
}

/* 禁用状态 */
input:disabled,
textarea:disabled,
select:disabled {
    background-color: #F8FAFC !important;
    color: #94A3B8 !important;
    cursor: not-allowed !important;
}

/* 只读状态 */
input[readonly],
textarea[readonly] {
    background-color: #F8FAFC !important;
    cursor: default !important;
}


/* ============================================
   导航栏搜索框保持深蓝色背景（和刷新按钮一致）
   必须放在最后，确保覆盖通用规则
   ============================================ */
.menu-search-input {
    background-color: rgba(255,255,255,0.08) !important;
    color: #fff !important;
    border: 1px solid rgba(255,255,255,0.25) !important;
    border-radius: 4px !important;
}
.menu-search-input:focus {
    background-color: rgba(255,255,255,0.08) !important;
    border-color: rgba(255,255,255,0.5) !important;
    color: #fff !important;
}
.menu-search-input::placeholder {
    color: rgba(255,255,255,0.6) !important;
}


/* ============================================
   复选框样式：选择时显示深蓝色背景
   ============================================ */
input[type="checkbox"] {
    -webkit-appearance: checkbox !important;
    -moz-appearance: checkbox !important;
    appearance: checkbox !important;
    width: 16px !important;
    height: 16px !important;
    cursor: pointer !important;
    accent-color: #1E3A5F !important;
}
input[type="checkbox"]:checked {
    background-color: #1E3A5F !important;
}

/* ============================================
   单选框样式：选择时显示深蓝色实心圆
   ============================================ */
input[type="radio"] {
    -webkit-appearance: radio !important;
    -moz-appearance: radio !important;
    appearance: radio !important;
    width: 16px !important;
    height: 16px !important;
    cursor: pointer !important;
    accent-color: #1E3A5F !important;
}
input[type="radio"]:focus {
    -webkit-appearance: radio !important;
    -moz-appearance: radio !important;
    appearance: radio !important;
    outline: none !important;
}


/* ============================================
   全局头像下拉菜单样式
   统一所有页面的头像下拉菜单和刷新下拉菜单
   ============================================ */

/* 头像下拉菜单容器 */
.head-dropdown {
    position: absolute !important;
    top: 100% !important;
    left: 0 !important;
    min-width: 160px !important;
    background: #1e3a5f !important;
    border-radius: 0 0 6px 6px !important;
    box-shadow: 0 8px 24px rgba(0,0,0,.3) !important;
    padding: 6px 0 !important;
    display: none !important;
    z-index: 9999 !important;
}

/* 头像下拉菜单hover时显示 */
.header-left.head-profile:hover .head-dropdown {
    display: flex !important;
    flex-direction: column !important;
}

/* 头像下拉菜单项 */
.head-dropdown .head-logout,
.head-dropdown a {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    gap: 8px !important;
    padding: 10px 16px !important;
    font-size: 14px !important;
    font-weight: 400 !important;
    color: rgba(255,255,255,0.75) !important;
    text-decoration: none !important;
    white-space: nowrap !important;
    background: none !important;
    border: none !important;
    border-radius: 0 !important;
    line-height: 1.5 !important;
    transition: all 0.15s ease !important;
}

/* 头像下拉菜单项hover效果 */
.head-dropdown .head-logout:hover,
.head-dropdown a:hover {
    background: rgba(255,255,255,.15) !important;
    color: #fff !important;
}

/* 刷新下拉菜单容器 */
.refresh-dropdown-menu {
    background: #1e3a5f !important;
    padding: 6px 0 !important;
    border-radius: 0 0 6px 6px !important;
    box-shadow: 0 8px 24px rgba(0,0,0,.3) !important;
}

/* 刷新下拉菜单项 */
.refresh-dropdown-item {
    padding: 10px 16px !important;
    font-size: 14px !important;
    font-weight: 400 !important;
    color: rgba(255,255,255,0.75) !important;
    line-height: 1.5 !important;
    transition: all 0.15s ease !important;
}

/* 刷新下拉菜单项hover效果 */
.refresh-dropdown-item:hover {
    background: rgba(255,255,255,.25) !important;
    color: #fff !important;
}

/* ===== 历史空壳类名补齐 =====
   .cs-enhance（32 处）与 .global-filter-select（43 处）在模板里被大量使用，
   但从未定义过样式 —— 这些下拉框一直显示为浏览器默认外观，与旁边的
   .global-select / .global-input 明显不一致。
   这里统一到全局下拉的外观；宽度用 auto，避免撑破紧凑的筛选栏布局。 */
.cs-enhance,
.global-filter-select {
    width: auto;
    max-width: 100%;
    height: 34px;
    padding: 0 10px;
    border: 1px solid #D1D5DB;
    border-radius: 6px;
    font-size: 13px;
    color: #374151;
    background: #fff;
    outline: none;
    cursor: pointer;
    font-family: inherit;
    box-sizing: border-box;
}

.cs-enhance:focus,
.global-filter-select:focus {
    border-color: #1E3A5F;
}

/* 已叠加 .global-select 的元素，宽度仍按全局规则撑满 */
.global-select.cs-enhance,
.global-select.global-filter-select {
    width: 100%;
}
