:root{color:#1d2530;font-synthesis:none;text-rendering:optimizelegibility;background:#f5f7f2;font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,sans-serif;line-height:1.5}*{box-sizing:border-box}body{background:linear-gradient(#ffffffc2,#f5f7f2f0),#f5f7f2;min-width:320px;min-height:100vh;margin:0}button,input,select{font:inherit}button{color:#fff;cursor:pointer;background:#256d5a;border:0;border-radius:7px;min-height:38px;padding:0 14px;transition:background .16s,transform .16s,box-shadow .16s}button:hover:not(:disabled){background:#1d5c4c;transform:translateY(-1px);box-shadow:0 8px 20px #256d5a24}button:disabled{cursor:not-allowed;opacity:.45}input,select{color:#18222d;background:#fff;border:1px solid #c7d1cc;border-radius:7px;width:100%;min-height:40px;padding:8px 10px}input:focus,select:focus{border-color:#256d5a;outline:3px solid #256d5a24}label{gap:6px;display:grid}label span{color:#52605b;font-size:.86rem;font-weight:700}.app-shell{width:min(1180px,100% - 32px);margin:0 auto;padding:30px 0 54px;position:relative}.app-shell[aria-busy=true]:after{content:"正在连接 Supabase...";z-index:10;color:#25443c;pointer-events:auto;background:#f5f7f2d1;place-items:start center;padding-top:120px;font-weight:800;display:grid;position:absolute;inset:0}.app-header{border-bottom:1px solid #dbe2de;justify-content:space-between;align-items:flex-end;gap:20px;margin-bottom:20px;padding-bottom:18px;display:flex}.eyebrow{color:#6c5a2f;margin:0 0 4px;font-size:.78rem;font-weight:800}h1,h2,h3,p{margin-top:0}h1{color:#17212b;margin-bottom:0;font-size:clamp(2rem,5vw,3.4rem);line-height:1}h2{color:#1b2834;margin-bottom:0;font-size:1.2rem}h3{margin-bottom:0;font-size:1rem}.header-actions,.row-actions,.form-actions{flex-wrap:wrap;gap:8px;display:flex}.storage-status{color:#53635d;align-self:center;font-size:.82rem;font-weight:800}.row-actions{flex-wrap:nowrap;gap:6px}.file-input{display:none}.notice{color:#4e421e;background:#fff8d9;border:1px solid #d6cda4;border-radius:7px;margin:0 0 16px;padding:10px 12px}.error-notice{color:#7e281e;background:#fff0ed;border-color:#efb1a8}.target-section,.selected-summary-section{background:#ffffffc7;border:1px solid #d8e0dc;border-radius:8px;margin-top:18px;overflow:hidden}.target-body,.selected-summary-body{gap:14px;padding:16px 18px 18px;display:grid}.profile-summary{grid-template-columns:repeat(2,minmax(0,160px));gap:10px;display:grid}.profile-summary div,.target-metric{background:#fff;border:1px solid #dce4e0;border-radius:8px}.profile-summary div{gap:2px;padding:10px 12px;display:grid}.profile-summary span,.target-metric span,.target-metric small{color:#62706c;font-size:.82rem;font-weight:800}.profile-summary strong{color:#17212b;font-size:1rem}.target-grid,.selected-total-grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;display:grid}.target-metric{gap:4px;min-height:104px;padding:12px;display:grid}.target-metric strong{color:#15231f;font-size:1.3rem;line-height:1.1}.target-metric small{color:#6c5a2f}.selected-items{flex-wrap:wrap;gap:7px;display:flex}.selected-items span{color:#25443c;background:#e7f0ec;border-radius:999px;padding:4px 9px;font-size:.86rem;font-weight:800}.table-section{background:#ffffffc7;border:1px solid #d8e0dc;border-radius:8px;margin-top:18px;overflow:hidden}.section-title{border-bottom:1px solid #e0e6e2;justify-content:space-between;align-items:center;gap:12px;padding:16px 18px;display:flex}.section-title span{color:#687773;font-size:.9rem;font-weight:700}.section-title-actions{flex-wrap:wrap;justify-content:flex-end;align-items:center;gap:10px;display:flex}.table-wrap{width:100%;overflow-x:auto}table{border-collapse:collapse;width:100%;min-width:860px}th,td{text-align:left;vertical-align:top;border-bottom:1px solid #e8ece9;padding:12px 14px}th{color:#53635d;white-space:nowrap;background:#f0f4ef;font-size:.82rem;font-weight:800}td{color:#27333d}tbody tr{transition:transform .18s,background .16s,opacity .16s}tbody tr:last-child td{border-bottom:0}.dragging-row{opacity:.72;background:#eef4f1}.drag-ghost{opacity:0;pointer-events:none;width:1px;height:1px;position:fixed;top:-100px;left:-100px}.drop-before td{box-shadow:inset 0 3px #256d5a}.drop-after td{box-shadow:inset 0 -3px #256d5a}.compound-row.drop-before:before,.compound-row.drop-after:after{content:"";background:#256d5a;border-radius:999px;height:3px;position:absolute;left:0;right:0}.compound-row.drop-before:before{top:-7px}.compound-row.drop-after:after{bottom:-7px}.utility-cell{text-align:center;vertical-align:middle;width:46px;padding-left:10px;padding-right:6px}.drag-handle{color:#52605b;cursor:grab;background:#fff;border:1px solid #c7d1cc;border-radius:7px;width:30px;min-height:30px;padding:0;position:relative}.drag-handle:before,.drag-handle:after{content:"";background:currentColor;border-radius:50%;width:3px;height:3px;position:absolute;top:8px;box-shadow:0 6px,0 12px}.drag-handle:before{left:10px}.drag-handle:after{right:10px}.drag-handle:active{cursor:grabbing}.drag-handle:hover:not(:disabled){color:#25443c;box-shadow:none;background:#eef4f1;transform:none}.row-checkbox{accent-color:#256d5a;cursor:pointer;width:20px;min-height:20px}.name-cell{color:#101820;min-width:150px;font-weight:800}.empty-cell,.empty-note{color:#687773}.empty-cell{text-align:center;padding:26px 14px}.secondary-button{color:#1c332d;background:#fff;border:1px solid #bac7c1}.secondary-button:hover:not(:disabled){color:#12241f;box-shadow:none;background:#eef4f1}.danger-button{color:#fff;background:#b24436}.danger-button:hover:not(:disabled){background:#963528;box-shadow:0 8px 20px #b2443624}.row-icon-button{place-items:center;width:36px;min-height:36px;padding:0;display:inline-grid}.button-icon{fill:none;stroke:currentColor;stroke-linecap:round;stroke-linejoin:round;stroke-width:2px;width:18px;height:18px}.compact-button{align-self:end;min-width:64px}.ingredients{flex-wrap:wrap;gap:6px;max-width:360px;display:flex}.ingredients span{color:#25443c;white-space:nowrap;background:#e7f0ec;border-radius:999px;padding:3px 8px;font-size:.86rem;font-weight:700}.editor-backdrop{z-index:10;background:#0f1c2270;place-items:center;padding:18px;display:grid;position:fixed;inset:0}.editor-panel{background:#fff;border-radius:8px;flex-direction:column;width:min(760px,100%);max-height:min(88vh,760px);display:flex;overflow:hidden;box-shadow:0 24px 80px #1220273d}.editor-head{border-bottom:1px solid #e3e8e5;justify-content:space-between;align-items:center;gap:16px;padding:18px 20px;display:flex}.icon-button{color:#25332f;background:#eef3f0;width:38px;min-height:38px;padding:0;font-size:1.2rem;line-height:1}.icon-button:hover:not(:disabled){color:#14211d;box-shadow:none;background:#dfe8e4}.editor-form{scrollbar-gutter:stable;gap:18px;min-height:0;padding:20px;display:grid;overflow:auto}.form-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;display:grid}.compound-header{grid-template-columns:minmax(220px,1fr) minmax(240px,auto);align-items:end;gap:16px;display:grid}.totals-preview{flex-wrap:wrap;gap:7px;display:flex}.totals-preview span{color:#2d413b;background:#f7faf8;border:1px solid #d5ded9;border-radius:999px;padding:6px 10px;font-size:.86rem;font-weight:800}.compound-items{border:1px solid #e1e7e3;border-radius:8px;gap:12px;padding:14px;display:grid}.compound-items-header{justify-content:space-between;align-items:center;gap:12px;display:flex}.item-picker{min-width:0;position:relative}.picker-button{color:#18222d;text-align:left;background:#fff;border:1px solid #c7d1cc;border-radius:7px;grid-template-columns:minmax(0,1fr) auto auto;align-items:center;column-gap:10px;width:100%;min-height:40px;padding:8px 10px;display:grid}.picker-button:after{content:"";border-bottom:2px solid #52605b;border-right:2px solid #52605b;width:8px;height:8px;transform:translateY(-2px)rotate(45deg)}.picker-button:hover:not(:disabled){box-shadow:none;background:#fff}.picker-button span{text-overflow:ellipsis;white-space:nowrap;min-width:0;overflow:hidden}.picker-button small{color:#687773;white-space:nowrap;font-size:.78rem;font-weight:800}.picker-menu{z-index:30;background:#fff;border:1px solid #c7d1cc;border-radius:8px;gap:8px;padding:10px;display:grid;position:fixed;overflow:auto;box-shadow:0 18px 44px #14222933}.picker-search{min-height:38px}.picker-group{gap:4px;display:grid}.picker-group-title{color:#6c5a2f;padding:6px 4px 2px;font-size:.76rem;font-weight:900}.picker-option{color:#1c332d;text-align:left;background:#fff;border-radius:6px;justify-content:flex-start;align-items:center;min-height:36px;padding:7px 8px;display:flex}.picker-option:hover:not(:disabled),.picker-option.selected{color:#12241f;box-shadow:none;background:#eef4f1;transform:none}.picker-empty{color:#687773;margin:0;padding:10px 4px}.compound-list{gap:10px;display:grid}.compound-row{grid-template-columns:32px minmax(260px,1fr) minmax(110px,150px) auto;align-items:end;gap:10px;transition:transform .18s,background .16s,opacity .16s;display:grid;position:relative}.compound-drag-cell{align-self:end;place-items:center;display:grid}.form-error{color:#7e281e;background:#fff0ed;border:1px solid #efb1a8;border-radius:7px;margin:0;padding:10px 12px}@media (width<=720px){.app-shell{width:min(100% - 20px,1180px);padding-top:18px}.app-header{flex-direction:column;align-items:stretch}.header-actions button{flex:130px}.section-title{flex-direction:column;align-items:stretch}.section-title-actions{justify-content:space-between}.section-title-actions button{flex:none}.profile-summary,.target-grid,.selected-total-grid,.form-grid,.compound-header,.compound-row{grid-template-columns:1fr}.compact-button{justify-self:start}}
