/* —— 自定义表单控件（下拉 / 日期） —— */
.ctl{position:relative;display:block;width:100%;min-width:0}
.ctl-native{position:absolute!important;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0;pointer-events:none}
.ctl-btn{width:100%;min-height:44px;padding:0 38px 0 13px;border:1px solid #D9D3C6;border-radius:6px;background:#FFFDF8;font:inherit;font-size:13px;color:#2E2922;text-align:left;cursor:pointer;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23706A5C' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E");background-repeat:no-repeat;background-position:right 13px center;transition:border-color .15s,box-shadow .15s}
.ctl-btn:hover{border-color:#BFB7A5}
.ctl-btn:focus-visible{outline:none;border-color:#3F5D42;box-shadow:0 0 0 3px rgba(63,93,66,.16)}
.ctl-btn.empty{color:#9A9488}
.ctl.open>.ctl-btn{border-color:#3F5D42;box-shadow:0 0 0 3px rgba(63,93,66,.14)}
.ctl-panel{display:none;position:absolute;z-index:80;left:0;min-width:100%;max-height:280px;overflow:auto;top:calc(100% + 6px);background:#FFFEFA;border:1px solid #D8D2C4;border-radius:8px;box-shadow:0 16px 38px rgba(58,48,32,.18);padding:5px}
.ctl.open>.ctl-panel{display:block}
.ctl.right-align>.ctl-panel{left:auto;right:0}
.ctl-opt{display:block;width:100%;text-align:left;padding:9px 11px;border:0;border-radius:5px;background:transparent;font:inherit;font-size:13px;color:#2E2922;cursor:pointer;white-space:nowrap}
.ctl-opt:hover,.ctl-opt:focus-visible{background:#F3EEE2;outline:none}
.ctl-opt.sel{background:#E9F0E4;font-weight:600}
.ctl-date .cal-pop{display:none;position:absolute;z-index:80;left:0;top:calc(100% + 6px);width:272px;background:#FFFEFA;border:1px solid #D8D2C4;border-radius:10px;box-shadow:0 18px 44px rgba(58,48,32,.2);padding:12px}
.ctl-date.open>.cal-pop{display:block}
.ctl-date.right-align>.cal-pop{left:auto;right:0}
.cal-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:8px}
.cal-head b{font-size:13px;font-weight:600;color:#2E2922}
.cal-nav{width:30px;height:30px;border:1px solid #D8D2C4;border-radius:6px;background:#FFFDF8;font-size:15px;line-height:1;color:#4B4234;cursor:pointer}
.cal-nav:hover{background:#F3EEE2}
.cal-grid{display:grid;grid-template-columns:repeat(7,1fr);gap:2px}
.cal-week span{text-align:center;font-size:11px;color:#8A8474;padding:3px 0}
.cal-pad{height:32px}
.cal-day{height:32px;border:0;border-radius:5px;background:transparent;font:inherit;font-size:12.5px;color:#2E2922;cursor:pointer}
.cal-day:hover,.cal-day:focus-visible{background:#F3EEE2;outline:none}
.cal-day.off,.cal-day:disabled{color:#C7C0B2;background:transparent;cursor:default;text-decoration:line-through}
.cal-day.off:hover,.cal-day:disabled:hover{background:transparent}
.cal-day.sel{background:#3F5D42;color:#FFFDF8;font-weight:600}
.cal-foot{display:flex;justify-content:space-between;margin-top:9px;padding-top:9px;border-top:1px solid #EFEBE0}
.cal-foot button{border:0;background:none;font:inherit;font-size:12.5px;color:#3F5D42;cursor:pointer;padding:4px 6px}
.cal-foot button:hover{text-decoration:underline}
@media print{.ctl-panel,.cal-pop{display:none!important}.ctl-btn{border-color:#D9D3C6}}



/* Shared paper-and-ink components, including their active and error states. */
button,input,select,textarea{-webkit-appearance:none;appearance:none}
input[type="search"]::-webkit-search-cancel-button,input[type="search"]::-webkit-search-decoration{display:none}
input::placeholder,textarea::placeholder{color:#8d897e;opacity:1}
input,textarea{caret-color:#43563d}
input[aria-invalid="true"],textarea[aria-invalid="true"]{border-color:#a3493e;box-shadow:0 0 0 3px #a3493e0c}
.ctl-error{display:block;margin:7px 0 12px;color:#a3493e;font-size:12px;line-height:1.5}
.ctl-btn.empty{padding:0 38px 0 13px;text-align:left}
.ctl-opt.sel{position:relative;padding-right:30px}
.ctl-opt.sel::after{content:"";position:absolute;right:13px;top:13px;width:6px;height:10px;border-right:1.5px solid #43563d;border-bottom:1.5px solid #43563d;transform:rotate(40deg)}
.ctl-opt:disabled{opacity:.4;cursor:not-allowed}
.ctl.open{z-index:90}
.cal-day[aria-current="date"]:not(.sel){box-shadow:inset 0 0 0 1px #94a187}
.cal-day:focus-visible,.cal-nav:focus-visible,.cal-foot button:focus-visible{outline:2px solid #64765a;outline-offset:1px}
.cal-foot button:disabled{opacity:.4;cursor:not-allowed}
.search-field{display:block;position:relative;min-width:0;width:100%}
.search-field>input{width:100%;margin:0;padding-right:36px}
.search-clear{position:absolute;right:7px;top:50%;transform:translateY(-50%);display:grid;place-items:center;width:26px;height:26px;min-height:0;padding:0;border:0;border-radius:50%;background:#edf0e6;color:#526149}
.search-clear svg{width:16px;height:16px}
.search-clear:hover{background:#dfe5d4}
.search-clear[hidden]{display:none!important}
.file-drop{position:relative;border:1px dashed #b8c2ac;background:#f5f5ed;transition:border-color .15s,background-color .15s}
.file-drop:hover,.file-drop:focus-within{border-color:#526149;background:#edf0e6}
.file-drop:focus-within{outline:2px solid #64765a;outline-offset:3px}
.file-drop input[type="file"]{position:absolute;inset:0;width:100%;height:100%;margin:0;padding:0;opacity:0;cursor:pointer}
.file-drop input:disabled{cursor:wait}
.file-pick{display:grid;grid-template-columns:32px minmax(0,1fr);align-items:center;column-gap:12px;row-gap:4px;margin:18px 0 16px}
.file-pick svg{width:32px;height:32px;color:#64765a;grid-row:1/3}
.file-name{font-size:13px;font-weight:500;overflow-wrap:anywhere}
.file-action{font-size:11px;color:#64765a;font-weight:400}
.has-file .file-action{font-size:0}
.has-file .file-action::after{content:"重新选择 ↗";font-size:11px}
.file-drop.has-file{border-style:solid;background:#edf0e6}
.tool-fields>.ctl{width:150px;flex-shrink:0}
.tool-fields>.search-field{width:210px}
.tool-fields .search-field>input{width:100%}
.tool-fields .ctl-btn{min-height:36px;font-size:11px}
.follow-tools>.ctl{width:180px;font-size:12px}
.follow-tools>.search-field{flex:1;min-width:160px}
label>.ctl,label>.search-field{margin-top:8px}
.two-fields .ctl-btn{min-height:44px}
.ctl-btn:disabled{opacity:.5;cursor:not-allowed}
summary{list-style:none}
summary::-webkit-details-marker{display:none}
summary::marker{content:""}
.record-metadata summary::after{content:"";display:inline-block;margin:0 0 3px 10px;width:6px;height:6px;border-right:1px solid currentColor;border-bottom:1px solid currentColor;transform:rotate(45deg)}
.record-metadata[open] summary::after{transform:rotate(225deg);margin-bottom:0}
*{scrollbar-width:thin;scrollbar-color:#b8bdab transparent}
::-webkit-scrollbar{width:6px;height:6px}::-webkit-scrollbar-thumb{background:#b8bdab;border-radius:8px}::-webkit-scrollbar-track{background:transparent}
@media(max-width:600px){
 .tool-fields>.search-field{flex:1;width:0}.tool-fields>.ctl{width:138px}
 .follow-tools>.ctl{width:calc(50% - 4px)}.follow-tools>.search-field{flex:1 0 100%}
 input:not(.ctl-native),textarea{font-size:16px}
}
@media(prefers-reduced-motion:reduce){.ctl-btn,.file-drop{transition:none}}
@media print{.search-clear{display:none!important}}
[data-tooltip]{position:relative}
[data-tooltip]:hover::after,[data-tooltip]:focus-visible::after{content:attr(data-tooltip);position:absolute;left:50%;bottom:calc(100% + 9px);transform:translateX(-50%);z-index:100;padding:6px 10px;border:1px solid #d8d2c4;border-radius:5px;background:#fffdf7;color:#45362d;box-shadow:0 5px 20px #45362d15;font:11px/1.5 -apple-system,BlinkMacSystemFont,"PingFang SC",sans-serif;white-space:nowrap;pointer-events:none}
@media print{[data-tooltip]::after{display:none!important}}
