/* ============================================================
   smartSchema.css — 表单插件管理器统一样式
   合并自 smartComponents.css / smartSelect.css / smartArea.css / smartImage.css
   覆盖：select / image / area 三插件 + 共用触发栏 + 错误气泡 + toast + 大图预览 + 响应式
   ============================================================ */

/* ---------- 盒模型（管理器下所有字段统一） ---------- */
.ys-cs, .ys-cs *,
.ys-area, .ys-area *,
.ys-img, .ys-img * {
    box-sizing: border-box;
}

/* ============================================================
   共用触发栏（select / area 用 .ys-cs-bar）
   ============================================================ */
.ys-cs, .ys-ts { position: relative; width: 100%; }
.ys-cs-bar, .ys-ts-bar {
    display: flex; align-items: center;
    border: 1px solid rgba(0,0,0,.14);
    border-radius: 9px;
    background: #fff;
    box-shadow: 0 1px 2px rgba(0,0,0,.04);
    transition: border-color .2s cubic-bezier(.4,0,.2,1), box-shadow .2s cubic-bezier(.4,0,.2,1);
    cursor: pointer;
    min-height: 32px;
    position: relative; width: 100%;
}
.ys-cs-bar:hover, .ys-ts-bar:hover {
    border-color: rgba(0,0,0,.26);
    box-shadow: 0 2px 6px rgba(0,0,0,.07);
}
.ys-cs.open .ys-cs-bar,
.ys-ts.open .ys-ts-bar,
.ys-area-sel.open .ys-cs-bar {
    border-color: #0a84ff;
    box-shadow: 0 0 0 3px rgba(10,132,255,.14);
}
.ys-cs-bar .ys-ico, .ys-ts-bar .ys-ico {
    position: absolute;
    left: 8px; top: 50%;
    transform: translateY(-50%);
    width: 15px; height: 15px;
    color: #a6a6ad;
    pointer-events: none;
    display: flex; align-items: center;
    transition: color .2s;
}
.ys-cs-bar .ys-ico svg, .ys-ts-bar .ys-ico svg { width: 100%; height: 100%; }
.ys-cs.open .ys-cs-bar .ys-ico,
.ys-ts.open .ys-ts-bar .ys-ico,
.ys-area-sel.open .ys-cs-bar .ys-ico { color: #0a84ff; }
.ys-cs-text, .ys-ts-text {
    flex: 1;
    padding: 0 28px 0 30px;
    font-size: 13px; color: #1d1d1f;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 32px;
    min-height: 32px;
}
.ys-cs-text.ph, .ys-ts-text.ph { color: #a6a6ad; }
.ys-cs-arr {
    position: absolute;
    right: 8px; top: 50%;
    transform: translateY(-50%);
    width: 14px; height: 14px;
    color: #a6a6ad;
    display: flex; align-items: center;
    transition: transform .25s cubic-bezier(.4,0,.2,1);
}
.ys-cs-arr svg { width: 100%; height: 100%; }
.ys-cs.open .ys-cs-arr,
.ys-ts.open .ys-cs-arr,
.ys-area-sel.open .ys-cs-arr { transform: translateY(-50%) rotate(180deg); }
.ys-ssel-x {
    position: absolute;
    right: 24px; top: 50%;
    transform: translateY(-50%);
    width: 28px; height: 28px;
    cursor: pointer;
    display: none;
    align-items: center; justify-content: center;
    border-radius: 50%;
    color: #a6a6ad; z-index: 2;
    transition: color .15s, background .15s;
}
.ys-ssel-x:hover { color: #ff453a; background: rgba(255,69,58,.12); }
.ys-ssel-x svg { width: 10px; height: 10px; }
.ys-cs-bar:hover .ys-ssel-x,
.ys-ts-bar:hover .ys-ssel-x { display: flex; }
/* 下拉禁用态 */
.ys-cs.ys-disabled .ys-cs-bar {
    opacity: .55;
    cursor: not-allowed;
    background: #f5f5f7;
    border-color: rgba(0,0,0,.08);
}
.ys-cs.ys-disabled .ys-cs-bar:hover { border-color: rgba(0,0,0,.08); box-shadow: none; }
.ys-cs.ys-disabled .ys-cs-panel { display: none !important; }

/* ============================================================
   下拉面板（select / area 共用 .ys-cs-panel）
   ============================================================ */
.ys-cs-panel {
    display: none;
    position: absolute;
    left: 0; top: calc(100% + 6px);
    width: 100%;
    background: rgba(255,255,255,.92);
    -webkit-backdrop-filter: saturate(180%) blur(22px);
    backdrop-filter: saturate(180%) blur(22px);
    border: 1px solid rgba(0,0,0,.08);
    border-radius: 12px;
    box-shadow: 0 12px 40px rgba(0,0,0,.16), 0 2px 10px rgba(0,0,0,.06);
    z-index: 9000;
    overflow: hidden;
    transform-origin: top center;
    animation: ysPanelIn .18s cubic-bezier(.4,0,.2,1);
}
@keyframes ysPanelIn {
    from { opacity: 0; transform: translateY(-5px) scale(.985); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}
/* 弹框/受限容器内向上翻转展开：当面板会超出可视区底部时由 JS 追加 .ys-up */
.ys-cs.ys-up .ys-cs-panel,
.ys-area-sel.ys-up .ys-cs-panel {
    top: auto; bottom: calc(100% + 6px);
    transform-origin: bottom center;
}
.ys-cs.ys-up .ys-cs-panel { animation-name: ysPanelInUp; }
.ys-area-sel.ys-up .ys-cs-panel { animation-name: ysPanelInUp; }
@keyframes ysPanelInUp {
    from { opacity: 0; transform: translateY(5px) scale(.985); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
    .ys-cs-panel { background: #fff; }
}
.ys-cs.open .ys-cs-panel,
.ys-area-sel.open .ys-cs-panel { display: block; }
/* datetime panel 强制 flex column，覆盖基类 display:block */
.ys-dt.open .ys-dt-panel { display: flex !important; flex-direction: column; }
.ys-cs-search-w { padding: 8px 12px 6px; border-bottom: 1px solid rgba(0,0,0,.05); }
.ys-cs-search {
    box-sizing: border-box;
    width: 100%; height: 30px; line-height: 30px;
    padding: 0 12px;
    font-size: 13px; color: #1d1d1f;
    border: none;
    outline: none;
    background: #f5f5f7;
    border-radius: 8px;
    font-family: inherit;
    transition: background .2s, box-shadow .2s;
}
.ys-cs-search::placeholder { color: #a6a6ad; }
.ys-cs-search:focus { background: #fff; box-shadow: 0 0 0 3px rgba(10,132,255,.16); }
.ys-cs-opts { max-height: 320px; overflow-y: auto; padding: 6px 8px; }
.ys-cs-opts::-webkit-scrollbar { width: 6px; }
.ys-cs-opts::-webkit-scrollbar-thumb { background: rgba(0,0,0,.18); border-radius: 3px; }
.ys-cs-opts::-webkit-scrollbar-track { background: transparent; }
.ys-cs-opt {
    display: flex; align-items: center;
    padding: 8px 12px;
    margin: 1px 0;
    font-size: 13px; color: #1d1d1f;
    cursor: pointer;
    border-radius: 8px;
    transition: background .15s cubic-bezier(.4,0,.2,1), color .15s;
    gap: 8px;
}
.ys-cs-opt:hover { background: rgba(0,0,0,.055); }
.ys-cs-opt.ks-focus { background: rgba(0,0,0,.055); }
.ys-cs-opt.sel { background: rgba(10,132,255,.10); color: #0a76e8; font-weight: 500; }
/* 单选选中项右侧对勾 */
.ys-cs:not(.multi) .ys-cs-opt.sel::after {
    content: '';
    flex-shrink: 0;
    width: 12px; height: 12px;
    margin-left: auto;
    background: currentColor;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6L9 17l-5-5'/%3E%3C/svg%3E") center/contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6L9 17l-5-5'/%3E%3C/svg%3E") center/contain no-repeat;
}
.ys-cs-opt-t { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ys-cs-empty { padding: 22px 12px; text-align: center; color: #a6a6ad; font-size: 13px; }
.ys-cs-more { padding: 9px 12px; margin-top: 4px; text-align: center; color: #0a76e8; font-size: 13px; cursor: pointer; border-radius: 4px; }
.ys-cs-more:hover { background: rgba(10,132,255,.08); }
.ys-cs-chk { display: flex; align-items: center; cursor: pointer; }
.ys-cs-chk input { display: none; }
.ys-cs-chk-icon {
    width: 17px; height: 17px;
    border: 1.5px solid rgba(0,0,0,.22);
    border-radius: 5px;
    display: flex; align-items: center; justify-content: center;
    transition: all .18s cubic-bezier(.4,0,.2,1);
    flex-shrink: 0;
}
.ys-cs-chk input:checked + .ys-cs-chk-icon { background: #0a84ff; border-color: #0a84ff; }
.ys-cs-chk input:checked + .ys-cs-chk-icon::after {
    content: '';
    display: block;
    width: 4px; height: 8px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    border-radius: 1px;
    transform: rotate(45deg) translateY(-1px);
}
/* select 多选底部操作栏 */
.ys-cs-foot, .ys-cs-acts {
    display: flex; justify-content: space-between;
    padding: 7px 12px;
    border-top: 1px solid rgba(0,0,0,.06);
}
.ys-cs-foot button, .ys-cs-acts button, .ys-cs-acts a {
    font-size: 12px; color: #0a84ff; cursor: pointer;
    padding: 3px 8px; border-radius: 6px;
    border: none; background: transparent;
    font-family: inherit;
    transition: background .15s, color .15s;
}
.ys-cs-foot button:hover, .ys-cs-acts button:hover, .ys-cs-acts a:hover {
    background: rgba(10,132,255,.10);
    color: #0a6ee0;
}

/* ============================================================
   省市区联动 area
   ============================================================ */
.ys-area {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    position: relative;
}
.ys-area-sel {
    flex: 1;
    min-width: 120px;
    position: relative;
}

/* ============================================================
   图片上传 image
   ============================================================ */
.ys-img { position: relative; }
.ys-img-box {
    position: relative;
    width: 100%; height: 100%;
    border-radius: 10px;
    overflow: hidden;
    background: #f5f5f7;
}
.ys-img-pic {
    display: none;
    width: 100%; height: 100%;
    object-fit: cover;
}
.ys-img-empty {
    position: absolute;
    left: 0; top: 0; right: 0; bottom: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    border: 1.5px dashed #d2d2d7;
    border-radius: 10px;
    color: #a6a6ad;
    font-size: 12px;
    cursor: pointer;
    transition: border-color .15s, color .15s;
}
.ys-img-empty svg { width: 20px; height: 20px; }
.ys-img-empty:hover { border-color: #0a84ff; color: #0a84ff; }
.ys-img.has .ys-img-empty { display: none; }
.ys-img.has .ys-img-pic { display: block; }
.ys-img-mask {
    position: absolute;
    left: 0; top: 0; right: 0; bottom: 0;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 6px;
    padding-bottom: 8px;
    background: linear-gradient(transparent 55%, rgba(0,0,0,.45));
    opacity: 0;
    transition: opacity .15s;
}
.ys-img.has:hover .ys-img-mask { opacity: 1; }
.ys-img-zoom,
.ys-img-rep {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 10px;
    border-radius: 999px;
    background: rgba(255,255,255,.92);
    color: #1d1d1f;
    font-size: 12px;
    cursor: pointer;
}
.ys-img-zoom svg,
.ys-img-rep svg { width: 12px; height: 12px; }
.ys-img-load {
    position: absolute;
    left: 0; top: 0; right: 0; bottom: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,.65);
}
.ys-img.loading .ys-img-load { display: flex; }
.ys-img-load i {
    width: 22px; height: 22px;
    border: 2.5px solid #d1d1d6;
    border-top-color: #0a84ff;
    border-radius: 50%;
    animation: ysSpin .7s linear infinite;
}
@keyframes ysSpin { to { transform: rotate(360deg); } }
.ys-img-file { display: none; }
/* 大图预览浮层 */
.ys-view {
    position: fixed;
    left: 0; top: 0; right: 0; bottom: 0;
    z-index: 99999999;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,.72);
}
.ys-view.on { display: flex; }
.ys-view img {
    max-width: 86vw;
    max-height: 86vh;
    border-radius: 8px;
    transform-origin: 0 0;
    will-change: transform;
    cursor: zoom-in;
}
.ys-view.zoomed img { cursor: zoom-out; }
.ys-view-x {
    position: absolute;
    top: 22px; right: 26px;
    width: 34px; height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255,255,255,.16);
    color: #fff;
    cursor: pointer;
}
.ys-view-x svg { width: 14px; height: 14px; }
/* image 禁用态 */
.ys-img.ys-disabled .ys-img-box {
    opacity: .55;
    cursor: not-allowed;
}
.ys-img.ys-disabled .ys-img-empty { pointer-events: none; }

/* ============================================================
   错误状态与错误气泡
   ============================================================ */
.ys-cs.ys-err .ys-cs-bar,
.ys-area.ys-err .ys-cs-bar,
.ys-img.ys-err .ys-img-box,
.ys-ts.ys-err .ys-ts-bar {
    border-color: #ff4d4f !important;
    box-shadow: 0 0 0 2px rgba(255,77,79,.1) !important;
}
.ys-err-tip {
    position: absolute;
    left: 0; top: 100%;
    z-index: 900;
    font-size: 12px;
    color: #fff;
    line-height: 1.2;
    padding: 6px 10px;
    margin-top: 4px;
    background: #ff4d4f;
    border-radius: 4px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-4px);
    transition: all .2s;
    pointer-events: none;
}
.ys-err-tip::before {
    content: '';
    position: absolute;
    left: 16px; top: -4px;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-bottom: 5px solid #ff4d4f;
}
.ys-err-tip.show { opacity: 1; visibility: visible; transform: translateY(0); }

/* ============================================================
   轻提示 toast
   ============================================================ */
.ys-toast {
    position: fixed;
    top: 24px; left: 50%;
    transform: translateX(-50%);
    z-index: 100000;
    padding: 9px 18px;
    border-radius: 10px;
    background: rgba(28,28,30,.88);
    color: #fff;
    font-size: 13px;
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s;
}
.ys-toast.on { opacity: 1; }

/* ============================================================
   datetime 日期时间选择器（集成 smartDateTimePicker 全功能样式）
   ============================================================ */
/* 触发栏 */
.ys-dtp { position: relative; width: 100%; }
.ys-dtp-bar {
    display: flex; align-items: center; height: 38px;
    border: 1px solid #e8e8e8; border-radius: 6px; padding: 0 12px;
    cursor: pointer; transition: border-color .2s; background: #fff;
}
.ys-dtp-bar:hover { border-color: #1890ff; }
.ys-dtp-bar .ys-ico { width: 16px; height: 16px; margin-right: 8px; color: #999; flex-shrink: 0; }
.ys-dtp-bar .ys-ico svg { width: 100%; height: 100%; display: block; }
.ys-dtp-text { flex: 1; font-size: 13px; color: #333; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.ys-dtp-text.ph { color: #bbb; }
.ys-dtp .ys-ssel-x { width: 16px; height: 16px; margin-left: 8px; color: #999; cursor: pointer; flex-shrink: 0; }
.ys-dtp .ys-ssel-x svg { width: 100%; height: 100%; display: block; }
.ys-dtp .ys-ssel-x:hover { color: #ff4d4f; }
.ys-dtp .ys-cs-arr { width: 14px; height: 14px; margin-left: 6px; color: #999; flex-shrink: 0; transition: transform .2s; }
.ys-dtp .ys-cs-arr svg { width: 100%; height: 100%; display: block; }

/* 禁用态 */
.ys-dtp.ys-disabled .ys-dtp-bar { opacity: .55; cursor: not-allowed; background: #f5f5f7; border-color: rgba(0,0,0,.08); }
.ys-dtp.ys-disabled .ys-dtp-bar:hover { border-color: rgba(0,0,0,.08); box-shadow: none; }

/* daterange 双输入（复用 smartSearch .ys-dr 结构，视觉对齐 .ys-dtp-bar） */
.ys-dtr .ys-dr { display: flex; align-items: center; }
.ys-dtr .ys-dr-i { flex: 1; position: relative; display: flex; align-items: center; min-width: 0; cursor: pointer; }
.ys-dtr .ys-dr-i .ys-ico {
    position: absolute; left: 10px; top: 50%; transform: translateY(-50%);
    width: 15px; height: 15px; color: #999; pointer-events: none; z-index: 1;
    display: flex; align-items: center;
}
.ys-dtr .ys-dr-i .ys-ico svg { width: 100%; height: 100%; }
.ys-dtr .ys-input {
    height: 38px; line-height: 38px; width: 100%;
    padding: 0 10px 0 30px; font-size: 13px; color: #333;
    border: 1px solid #e8e8e8; border-radius: 6px; outline: none;
    background: #fff; font-family: inherit; cursor: pointer;
    transition: border-color .2s;
}
.ys-dtr .ys-dr-i:first-child .ys-input { border-radius: 6px 0 0 6px; }
.ys-dtr .ys-dr-i:last-child .ys-input { border-radius: 0 6px 6px 0; }
.ys-dtr .ys-dr-i .ys-input:hover { border-color: #1890ff; }
.ys-dtr .ys-input::placeholder { color: #bbb; }
.ys-dtr .ys-dr-sep {
    height: 38px; line-height: 38px; padding: 0 8px;
    font-size: 12px; color: #999; background: #fafafa;
    border-top: 1px solid #e8e8e8; border-bottom: 1px solid #e8e8e8;
    white-space: nowrap; flex-shrink: 0;
}
.ys-dtr .ys-dr-i .ys-err-tip { font-size: 12px; }
.ys-dtr.ys-err .ys-dr-i .ys-input { border-color: #ff4d4f !important; box-shadow: 0 0 0 2px rgba(255,77,79,.1) !important; }
.ys-dtr .ys-dr-i.ys-err .ys-input { border-color: #ff4d4f !important; box-shadow: 0 0 0 2px rgba(255,77,79,.1) !important; }
.ys-dtr.ys-disabled .ys-dr-i { opacity: .55; cursor: not-allowed; }
.ys-dtr.ys-disabled .ys-dr-i .ys-input { background: #f5f5f7; }

/* 日历弹出层（共享单例，fixed 到 body） */
.ys-dp {
    position: fixed; z-index: 999999999;
    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 8px;
    box-shadow: 0 8px 28px rgba(0,0,0,.16);
    padding: 14px;
    width: 310px;
    animation: ysDpIn .15s ease;
    box-sizing: border-box;
    max-height: 88vh;
    overflow-y: auto;
}
@keyframes ysDpIn { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: translateY(0); } }
.ys-dp-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.ys-dp-nav {
    width: 30px; height: 30px;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer; border-radius: 50%;
    color: #666; font-size: 20px; font-weight: 600;
    transition: all .15s; user-select: none; text-decoration: none; line-height: 1;
}
.ys-dp-nav:hover { background: #f0f0f0; color: #333; }
.ys-dp-tt { font-size: 14px; font-weight: 600; color: #333; }
.ys-dp-wk { display: grid; grid-template-columns: repeat(7,1fr); margin-bottom: 4px; }
.ys-dp-wk span { text-align: center; font-size: 11px; color: #bbb; padding: 4px 0; font-weight: 500; }
.ys-dp-gd { display: grid; grid-template-columns: repeat(7,1fr); }
.ys-dp-d {
    text-align: center; height: 30px; line-height: 30px;
    font-size: 13px; color: #333;
    cursor: pointer; border-radius: 4px;
    transition: all .1s; user-select: none;
}
.ys-dp-d:hover:not(.off):not(.sel) { background: #f0f0f0; }
.ys-dp-d.off { color: #d9d9d9; cursor: default; }
.ys-dp-d.today { color: #1890ff; font-weight: 600; box-shadow: inset 0 0 0 1px #1890ff; }
.ys-dp-d.sel { background: #1890ff; color: #fff; font-weight: 500; box-shadow: none; }

/* 时间滚动选择器（iOS 式轮盘） */
.ys-dp-tp-wrap { border-top: 1px solid #f0f0f0; margin-top: 6px; padding-top: 6px; }
.ys-tp {
    display: flex; height: 160px;
    position: relative;
    border: 1px solid #f0f0f0;
    border-radius: 4px;
    overflow: hidden;
}
.ys-tp-col { flex: 1; position: relative; display: flex; flex-direction: column; border-right: 1px solid #f0f0f0; }
.ys-tp-col:last-child { border-right: none; }
.ys-tp-hd { text-align: center; font-size: 11px; color: #999; padding: 5px 0; border-bottom: 1px solid #f5f5f5; background: #fafafa; flex-shrink: 0; }
.ys-tp-sc {
    flex: 1; overflow-y: auto;
    scrollbar-width: none; position: relative;
    scroll-snap-type: y mandatory;
    -webkit-overflow-scrolling: touch;
}
.ys-tp-sc::-webkit-scrollbar { display: none; }
.ys-tp-pad { height: 64px; }
/* 蓝色指示器 */
.ys-tp-col::after {
    content: '';
    position: absolute;
    left: 2px; right: 2px;
    top: 50%;
    transform: translateY(calc(-50% + 12px));
    height: 32px;
    background: #1890ff;
    border-radius: 3px;
    pointer-events: none;
    z-index: 4;
    box-shadow: 0 0 10px rgba(24,144,255,.2);
}
.ys-tp-it {
    height: 32px; line-height: 32px;
    text-align: center;
    font-size: 14px;
    font-family: Menlo, Consolas, monospace;
    color: #333;
    cursor: pointer;
    user-select: none;
    position: relative;
    z-index: 5;
    background: #fff;
    transition: color .1s, background .1s;
    scroll-snap-align: center;
}
.ys-tp-it:hover { color: #1890ff; }
.ys-tp-it.sel { background: transparent; color: #fff; font-weight: 600; }
/* 渐变遮罩 */
.ys-tp-sc::before {
    content: '';
    position: -webkit-sticky;
    position: sticky;
    top: 0;
    display: block;
    height: 24px; width: 100%;
    background: linear-gradient(to bottom, rgba(255,255,255,.95), transparent);
    pointer-events: none;
    z-index: 7;
    margin-bottom: -24px;
}
.ys-tp-sc::after {
    content: '';
    position: -webkit-sticky;
    position: sticky;
    bottom: 0;
    display: block;
    height: 24px; width: 100%;
    background: linear-gradient(to top, rgba(255,255,255,.95), transparent);
    pointer-events: none;
    z-index: 7;
    margin-top: -24px;
}

/* 底部操作栏 */
.ys-dp-ft {
    display: flex; justify-content: space-between; align-items: center;
    margin-top: 8px; padding-top: 8px;
    border-top: 1px solid #f0f0f0;
}
.ys-dp-ftl { display: flex; gap: 10px; }
.ys-dp-ftl a { font-size: 12px; color: #1890ff; cursor: pointer; padding: 2px 6px; border-radius: 3px; transition: background .15s; text-decoration: none; }
.ys-dp-ftl a:hover { background: #e6f7ff; }
.ys-dp-ok { height: 28px; padding: 0 18px; font-size: 12px; background: #1890ff; color: #fff; border: none; border-radius: 4px; cursor: pointer; font-family: inherit; font-weight: 500; transition: background .15s; }
.ys-dp-ok:hover { background: #096dd9; }

/* 年/月快速选择 */
.ys-dp-yr, .ys-dp-mo { cursor: pointer; padding: 2px 6px; border-radius: 4px; transition: background .15s, color .15s; }
.ys-dp-yr:hover, .ys-dp-mo:hover { background: #e6f7ff; color: #1890ff; }
.ys-dp-ym-gd { display: grid; grid-template-columns: repeat(4,1fr); gap: 6px; padding: 8px 0; }
.ys-dp-ym-it { text-align: center; height: 36px; line-height: 36px; font-size: 13px; color: #333; cursor: pointer; border-radius: 4px; transition: all .1s; }
.ys-dp-ym-it:hover { background: #f0f5ff; color: #1890ff; }
.ys-dp-ym-it.cur { background: #1890ff; color: #fff; font-weight: 500; }

/* 月份选择模式 */
.ys-dp-month-wrap { padding: 10px 0; }
.ys-dp-month-title { text-align: center; font-size: 13px; color: #999; margin-bottom: 10px; }
.ys-dp-month-gd { display: grid; grid-template-columns: repeat(4,1fr); gap: 8px; }
.ys-dp-month-it { text-align: center; height: 40px; line-height: 40px; font-size: 13px; color: #333; cursor: pointer; border-radius: 4px; transition: all .15s; border: 1px solid #e8e8e8; }
.ys-dp-month-it:hover { background: #f0f5ff; color: #1890ff; border-color: #1890ff; }
.ys-dp-month-it.cur { background: #1890ff; color: #fff; border-color: #1890ff; font-weight: 500; }

/* ============================================================
   响应式（≤ 768px，移动端，iOS HIG 触控最小高度）
   ============================================================ */
@media (max-width: 768px) {
    .ys-input,
    .ys-cs-bar,
    .ys-ts-bar {
        height: 40px;
        line-height: 40px;
        font-size: 14px;
        padding-top: 0;
        padding-bottom: 0;
    }
    .ys-cs-text,
    .ys-ts-text {
        line-height: 40px;
        min-height: 40px;
        font-size: 14px;
    }
    .ys-cs-bar .ys-ico,
    .ys-ts-bar .ys-ico {
        width: 18px;
        height: 18px;
        left: 10px;
    }

    /* 下拉面板全屏 + 底部弹出 */
    .ys-cs-panel,
    .ys-ts-panel {
        position: fixed;
        left: 8px;
        right: 8px;
        bottom: 8px;
        top: auto;
        max-height: 60vh;
        width: auto;
        border-radius: 12px 12px 8px 8px;
        animation: ysPanelUp 0.2s ease;
        box-shadow: 0 -4px 20px rgba(0,0,0,0.15);
        border: none;
        padding-bottom: env(safe-area-inset-bottom);
    }
    @keyframes ysPanelUp {
        from { transform: translateY(20px); opacity: 0; }
        to   { transform: translateY(0); opacity: 1; }
    }

    /* 下拉搜索框 */
    .ys-cs-search,
    .ys-ts-search {
        height: 40px;
        line-height: 40px;
        font-size: 14px;
    }

    /* 下拉选项 */
    .ys-cs-opt {
        padding: 10px 14px;
        min-height: 44px;
        font-size: 15px;
    }
    .ys-cs-opt-t { font-size: 15px; }
    .ys-cs-chk-icon { width: 20px; height: 20px; }

    /* 全选/清空操作栏 */
    .ys-cs-acts { padding: 8px 12px; }
    .ys-cs-acts a { padding: 6px 12px; font-size: 14px; }

    /* 错误提示 */
    .ys-err-tip {
        font-size: 13px;
        padding: 6px 12px;
        white-space: normal;
        max-width: 90%;
        top: calc(100% + 2px);
        left: 50%;
        transform: translateX(-50%);
    }
    .ys-err-tip::before {
        left: 50%;
        margin-left: -5px;
    }

    /* 确保触控区域足够 */
    .ys-cs-bar,
    .ys-ts-bar,
    .ys-ssel-x,
    .ys-cs-opt {
        cursor: pointer;
        touch-action: manipulation;
    }

    /* 省市区纵向排列 */
    .ys-area { flex-direction: column; gap: 6px; }
    .ys-area-sel { min-width: 100%; }
}

/* ============================================================
   treeselect 树选择专用样式（合并自 smartTreeSelect.css）
   需配合 yTree.js 渲染的 .yTree 结构
   ============================================================ */
.ys-ts-panel {
    display: none;
    position: absolute;
    left: 0; top: calc(100% + 6px);
    width: 100%; min-width: 359px;
    background: rgba(255,255,255,.94);
    -webkit-backdrop-filter: saturate(180%) blur(22px);
    backdrop-filter: saturate(180%) blur(22px);
    border: 1px solid rgba(0,0,0,.08);
    border-radius: 12px;
    box-shadow: 0 12px 40px rgba(0,0,0,.16), 0 2px 10px rgba(0,0,0,.06);
    z-index: 9000;
    overflow: hidden;
    transform-origin: top center;
    animation: ysPanelIn .18s cubic-bezier(.4,0,.2,1);
    /* 最低高度：搜索结果少时保证条件筛选下拉可完整展示 */
    min-height: 220px;
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
    .ys-ts-panel { background: #fff; }
}
.ys-ts.open .ys-ts-panel { display: flex; flex-direction: column; }
.ys-ts-cond-sel {
    position: relative;
    flex-shrink: 0;
}
.ys-ts-cond-cur {
    display: flex; align-items: center; gap: 4px;
    height: 30px; padding: 0 10px;
    font-size: 12px; color: #1d1d1f;
    background: #f5f5f7;
    border-radius: 8px;
    cursor: pointer;
    white-space: nowrap;
    font-family: inherit;
    user-select: none;
    transition: background .2s, box-shadow .2s;
}
.ys-ts-cond-cur:hover { background: #fff; box-shadow: 0 0 0 3px rgba(10,132,255,.16); }
.ys-ts-cond-sel.open .ys-ts-cond-cur { background: #fff; box-shadow: 0 0 0 3px rgba(10,132,255,.16); }
.ys-ts-cond-arr {
    width: 12px; height: 12px;
    color: #8e8e93;
    display: flex; align-items: center;
    transition: transform .2s;
}
.ys-ts-cond-sel.open .ys-ts-cond-arr { transform: rotate(180deg); }
.ys-ts-cond-arr svg { width: 100%; height: 100%; }
.ys-ts-cond-list {
    display: none;
    position: absolute; top: calc(100% + 4px); left: 0;
    min-width: 100%;
    margin: 0; padding: 4px;
    list-style: none;
    background: rgba(255,255,255,.97);
    -webkit-backdrop-filter: saturate(180%) blur(22px);
    backdrop-filter: saturate(180%) blur(22px);
    border: 1px solid rgba(0,0,0,.08);
    border-radius: 8px;
    box-shadow: 0 8px 28px rgba(0,0,0,.14), 0 2px 8px rgba(0,0,0,.05);
    z-index: 9001;
    max-height: 220px; overflow-y: auto;
}
.ys-ts-cond-sel.open .ys-ts-cond-list { display: block; }
.ys-ts-cond-list li {
    padding: 6px 10px;
    font-size: 12px; color: #666;
    border-radius: 6px;
    cursor: pointer;
    white-space: nowrap;
    transition: all .15s;
}
.ys-ts-cond-list li:hover { color: #0a84ff; background: #f0f8ff; }
.ys-ts-cond-list li.selected {
    color: #fff; font-weight: 500;
    background: linear-gradient(135deg, #0a84ff, #0a6ee0);
    box-shadow: 0 1px 4px rgba(10,132,255,.3);
}
.ys-ts-srow { display: flex; gap: 6px; padding: 8px 10px; border-bottom: 1px solid rgba(0,0,0,.05); }
.ys-ts-search {
    flex: 1; height: 30px; line-height: 30px;
    padding: 0 10px;
    font-size: 13px;
    border: none;
    outline: none;
    background: #f5f5f7;
    border-radius: 8px;
    color: #1d1d1f;
    font-family: inherit;
    transition: background .2s, box-shadow .2s;
}
.ys-ts-search:focus { background: #fff; box-shadow: 0 0 0 3px rgba(10,132,255,.16); }
.ys-ts-sbtn {
    height: 30px; padding: 0 14px;
    font-size: 12px;
    background: linear-gradient(135deg, #0a84ff, #0a6ee0);
    color: #fff;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    display: flex; align-items: center; gap: 4px;
    font-family: inherit;
    transition: all .2s;
    white-space: nowrap;
    font-weight: 500;
    box-shadow: 0 1px 4px rgba(10,132,255,.3);
}
.ys-ts-sbtn:hover { box-shadow: 0 2px 8px rgba(24,144,255,.4); transform: translateY(-1px); }
.ys-ts-sbtn svg { width: 13px; height: 13px; }
.ys-ts-tree { max-height: 360px; overflow-y: auto; padding: 6px 0; }
.ys-ts-tree-wrap { position: relative; min-height: 120px; flex: 1 1 auto; }
.ys-ts-loading-box {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.92);
    z-index: 100;
    border-radius: 0 0 4px 4px;
}
.ys-ts-loading-box .ys-ts-spinner {
    width: 16px; height: 16px;
    border: 2px solid #e8e8e8;
    border-top-color: #1890ff;
    border-radius: 50%;
    animation: ys-ts-spin 0.6s linear infinite;
    margin-right: 8px;
    flex-shrink: 0;
}
.ys-ts-loading-box .ys-ts-loading-text {
    color: #1890ff;
    font-size: 13px;
    white-space: nowrap;
}
@keyframes ys-ts-spin {
    to { transform: rotate(360deg); }
}
.ys-ts-tip-box {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.95);
    z-index: 100;
    font-size: 13px;
    line-height: 1.8;
    text-align: center;
    padding: 16px;
}
.ys-ts-tip-box.warn { color: #faad14; }
.ys-ts-tip-box.info { color: #999; }
.yTree li a.no-data-node {
    color: #bbb;
    cursor: default;
    font-style: italic;
}
.yTree li a.no-data-node:hover { background: transparent; }

/* ============================================================
   search 搜索栏插件专属样式（源自 smartSearch.css，作用域限定 .ys-bar）
   覆盖：快捷时间 / 字段网格 / 原生输入 / 日期范围 / 数字范围 / 按钮 / 移动端
   ============================================================ */
.ys-bar,
.ys-bar *,
.ys-bar *::before,
.ys-bar *::after { box-sizing: border-box; }

.ys-bar {
    background: #fff;
    border-radius: 6px;
    margin-bottom: 14px;
}

/* 快捷时间 */
.ys-bar .ys-quick {
    display: flex; align-items: center;
    padding: 8px 16px 16px 3px;
    gap: 6px; flex-wrap: wrap;
}
.ys-bar .ys-qt-lbl {
    font-size: 12px; color: #999;
    display: flex; align-items: center; gap: 4px;
    white-space: nowrap; margin-right: 2px;
}
.ys-bar .ys-qt-lbl svg { width: 13px; height: 13px; color: #bbb; }
.ys-bar .ys-qt {
    height: 24px; line-height: 24px; padding: 0 10px; font-size: 12px;
    border: 1px solid #e8e8e8; border-radius: 12px;
    background: #fff; color: #666; cursor: pointer;
    transition: all .2s; white-space: nowrap; font-family: inherit;
}
.ys-bar .ys-qt:hover { border-color: #1890ff; color: #1890ff; }
.ys-bar .ys-qt.active { background: #1890ff; color: #fff; border-color: #1890ff; }

/* 字段网格（24列）+ 按钮同行（不换行，保证按钮始终与条件同一行） */
.ys-bar .ys-grid-row { display: flex; align-items: flex-end; gap: 12px; flex-wrap: nowrap; }
.ys-bar .ys-grid {
    flex: 1 1 0; min-width: 0;
    display: grid; grid-template-columns: repeat(24, 1fr);
    gap: 8px 12px;
}
.ys-bar .ys-item { display: flex; flex-direction: column; min-width: 0; }
.ys-bar .ys-lbl {
    font-size: 12px; color: #8c8c8c; margin-bottom: 8px;
    line-height: 1; display: flex; align-items: center; gap: 4px;
    white-space: nowrap;
}
.ys-bar .ys-lbl svg { width: 13px; height: 13px; color: #bfbfbf; flex-shrink: 0; }
.ys-bar .ys-req { color: #ff4d4f; font-style: normal; margin-left: 1px; font-size: 14px; }
.ys-bar .ys-fw { position: relative; }

/* 错误态（容器级 + daterange 单侧） */
.ys-bar .ys-item.ys-err .ys-input,
.ys-bar .ys-item.ys-err .ys-cs-bar,
.ys-bar .ys-item.ys-err .ys-ts-bar,
.ys-bar .ys-item.ys-err .ys-dr-i .ys-input { border-color: #ff4d4f !important; box-shadow: 0 0 0 2px rgba(255,77,79,.1) !important; }
.ys-bar .ys-dr-i.ys-err .ys-input { border-color: #ff4d4f !important; box-shadow: 0 0 0 2px rgba(255,77,79,.1) !important; }

/* 文本输入 */
.ys-bar .ys-iw { position: relative; display: flex; align-items: center; }
.ys-bar .ys-iw .ys-ico,
.ys-bar .ys-dr-i .ys-ico {
    position: absolute; left: 8px; top: 50%; transform: translateY(-50%);
    width: 15px; height: 15px; color: #bfbfbf;
    pointer-events: none; z-index: 1;
    display: flex; align-items: center; transition: color .2s;
}
.ys-bar .ys-iw .ys-ico svg,
.ys-bar .ys-dr-i .ys-ico svg { width: 100%; height: 100%; }
.ys-bar .ys-iw:focus-within .ys-ico { color: #1890ff; }
.ys-bar .ys-input {
    height: 32px; line-height: 32px; padding: 0 10px 0 30px; font-size: 13px;
    border: 1px solid #d9d9d9; border-radius: 4px; outline: none; color: #333;
    background: #fff; transition: border-color .2s, box-shadow .2s;
    width: 100%; font-family: inherit;
}
.ys-bar .ys-input:hover { border-color: #40a9ff; }
.ys-bar .ys-input:focus { border-color: #1890ff; box-shadow: 0 0 0 2px rgba(24,144,255,.08); }
.ys-bar .ys-input::placeholder { color: #bfbfbf; }
.ys-bar .ys-input[readonly] { cursor: pointer; background: #fff; }
.ys-bar .ys-input-flat { padding-left: 10px; }

/* 日期范围（search 原生，独立于 .ys-dtr 的 38px 版本） */
.ys-bar .ys-dr { display: flex; align-items: center; }
.ys-bar .ys-dr-i { flex: 1; position: relative; display: flex; align-items: center; min-width: 0; }
.ys-bar .ys-dr-i .ys-input { padding: 0 2px 0 24px; border-radius: 0; min-width: 0; }
.ys-bar .ys-dr-i:first-child .ys-input { border-radius: 4px 0 0 4px; }
.ys-bar .ys-dr-i:last-child .ys-input { border-radius: 0 4px 4px 0; }
.ys-bar .ys-dr-sep {
    height: 32px; line-height: 32px; padding: 0 8px; font-size: 12px; color: #bfbfbf;
    background: #fafafa; border-top: 1px solid #d9d9d9; border-bottom: 1px solid #d9d9d9;
    white-space: nowrap; flex-shrink: 0;
}

/* 数字范围 */
.ys-bar .ys-nr { display: flex; align-items: center; }
.ys-bar .ys-nr .ys-input { border-radius: 0; min-width: 64px; flex: 1 1 auto; padding-right: 4px; font-size: 12px; }
.ys-bar .ys-nr .ys-input:first-child { border-radius: 4px 0 0 4px; }
.ys-bar .ys-nr .ys-input:last-child { border-radius: 0 4px 4px 0; }
.ys-bar .ys-nr-sep {
    height: 32px; line-height: 32px; padding: 0 6px; font-size: 12px; color: #bfbfbf;
    background: #fafafa; border-top: 1px solid #d9d9d9; border-bottom: 1px solid #d9d9d9;
    flex-shrink: 0;
}

/* 子组件挂载点 */
.ys-bar .ys-sub { position: relative; min-width: 0; }

/* 按钮 */
.ys-bar .ys-footer { flex-shrink: 0; padding: 0; margin: 0; }
.ys-bar .ys-footer .ys-btns { display: flex; gap: 6px; align-items: flex-end; padding-bottom: 2px; }
.ys-bar .ys-btn {
    height: 32px; line-height: 32px; padding: 0 20px; font-size: 13px;
    border: none; border-radius: 4px; cursor: pointer;
    display: inline-flex; align-items: center; gap: 4px;
    transition: all .2s; white-space: nowrap; font-family: inherit;
}
.ys-bar .ys-btn svg { width: 14px; height: 14px; flex-shrink: 0; }
.ys-bar .ys-btn-go { background: #1890ff; color: #fff; box-shadow: 0 2px 6px rgba(24,144,255,.2); }
.ys-bar .ys-btn-go:hover { background: #096dd9; }
.ys-bar .ys-btn-go:hover svg { transform: scale(1.1); }
.ys-bar .ys-btn-clr { background: #fff; color: #595959; border: 1px solid #d9d9d9; }
.ys-bar .ys-btn-clr:hover { color: #1890ff; border-color: #1890ff; }
.ys-bar .ys-btn-clr:hover svg { transform: rotate(-180deg); }

/* 移动端（≤768px） */
@media (max-width: 768px) {
    .ys-bar { padding: 8px 6px; }
    .ys-bar .ys-quick { padding: 6px 4px 10px 4px; gap: 4px; }
    .ys-bar .ys-qt-lbl { font-size: 13px; margin-right: 4px; }
    .ys-bar .ys-qt { height: 34px; line-height: 34px; padding: 0 12px; font-size: 13px; border-radius: 17px; }
    .ys-bar .ys-lbl { font-size: 13px; margin-bottom: 4px; }
    .ys-bar .ys-lbl svg { width: 16px; height: 16px; }
    .ys-bar .ys-input,
    .ys-bar .ys-cs-bar,
    .ys-bar .ys-ts-bar,
    .ys-bar .ys-dr-i .ys-input { height: 40px; line-height: 40px; font-size: 14px; padding-top: 0; padding-bottom: 0; }
    .ys-bar .ys-dr-sep,
    .ys-bar .ys-nr-sep { height: 40px; line-height: 40px; }
    .ys-bar .ys-iw .ys-ico,
    .ys-bar .ys-dr-i .ys-ico { width: 18px; height: 18px; }
    .ys-bar .ys-btn { height: 40px; line-height: 40px; padding: 0 22px; font-size: 14px; }
}

/* 极窄屏（真正手机竖屏 ≤480px）才把查询条件与按钮纵向堆叠，481~768px 保持同行 */
@media (max-width: 480px) {
    .ys-bar .ys-grid-row { flex-direction: column; gap: 6px; padding: 0 4px 8px; align-items: stretch; }
    .ys-bar .ys-grid { grid-template-columns: 1fr !important; gap: 6px; }
    .ys-bar .ys-grid .ys-item { grid-column: span 1 !important; min-width: 0; }
}
