:root{
  --bg:#f3f5ef;--surface:#ffffff;--surface-2:#f8faf6;--ink:#183229;--muted:#6e7d75;--line:#dfe7df;
  --brand:#173f32;--brand-2:#2f765b;--brand-soft:#eaf2ed;--accent:#b7893f;--accent-soft:#f7efe0;
  --danger:#b94d42;--danger-soft:#fff3f0;--success:#287153;--shadow:0 16px 50px rgba(18,56,43,.08);
  --sidebar:286px;--radius:22px
}
*{box-sizing:border-box}html{background:var(--bg);scroll-behavior:smooth}body{margin:0;font-family:"Hind Siliguri","Noto Sans Bengali",system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;background:var(--bg);color:var(--ink);line-height:1.5}a{color:inherit;text-decoration:none}button,input,select,textarea{font:inherit}button{color:inherit}.app-shell{min-height:100vh}.sidebar{position:fixed;inset:0 auto 0 0;width:var(--sidebar);background:#11352a;color:#fff;padding:20px 16px;display:flex;flex-direction:column;z-index:80;box-shadow:18px 0 60px rgba(13,45,34,.12)}.brand{display:flex;align-items:center;gap:12px;padding:4px 5px 18px;border-bottom:1px solid rgba(255,255,255,.1)}.brand-mark{width:44px;height:44px;border-radius:15px;background:linear-gradient(145deg,#d9b878,#a67631);display:grid;place-items:center;color:#153d31;font-weight:900;font-size:20px;box-shadow:inset 0 1px 0 #fff7}.brand-mark.big{width:58px;height:58px;border-radius:18px;margin:auto}.brand-copy{min-width:0;display:grid}.brand-copy strong{font-size:15px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.brand-copy span{font-size:11px;color:#aac2b7;margin-top:2px}.drawer-close{display:none;margin-left:auto;width:36px;height:36px;border:0;border-radius:11px;background:rgba(255,255,255,.1);color:#fff;font-size:24px}.side-nav{padding:15px 0;overflow:auto;scrollbar-width:none}.side-nav::-webkit-scrollbar{display:none}.nav-home,.nav-parent{width:100%;display:flex;align-items:center;gap:11px;border:0;background:transparent;color:#c8d8d1;border-radius:14px;padding:11px 12px;text-align:left;font-weight:750;cursor:pointer}.nav-home:hover,.nav-parent:hover{background:rgba(255,255,255,.06);color:#fff}.nav-home.active{background:#fff;color:var(--brand);box-shadow:0 10px 28px rgba(0,0,0,.12)}.nav-icon{width:28px;height:28px;border-radius:9px;display:grid;place-items:center;background:rgba(255,255,255,.08);color:#c9d9d2}.ui-icon{width:18px;height:18px;display:block}.nav-icon .ui-icon{width:16px;height:16px}.nav-parent,.nav-home{color:#c8d8d1}.nav-parent .nav-icon,.nav-home .nav-icon{color:currentColor}.nav-home.active .nav-icon{background:var(--brand-soft)}.nav-parent b{margin-left:auto;color:#91aa9f;transition:.2s}.nav-group.open .nav-parent b{transform:rotate(180deg)}.nav-children{display:none;padding:3px 0 8px 38px}.nav-group.open .nav-children{display:grid}.nav-children a{position:relative;padding:8px 10px 8px 10px;color:#a9beb5;border-radius:10px;font-size:13px;font-weight:650;display:flex;align-items:center;gap:9px}.child-icon{width:20px;height:20px;display:grid;place-items:center;color:currentColor}.child-icon .ui-icon{width:14px;height:14px}.nav-children a:before{display:none}.nav-children a:hover{color:#fff}.nav-children a.active{color:#fff;background:rgba(255,255,255,.08)}.nav-children a.active:before{background:#d6b36b}.sidebar-foot{margin-top:auto;border-top:1px solid rgba(255,255,255,.1);padding:14px 4px 0;display:flex;align-items:center;justify-content:space-between;gap:10px}.sidebar-foot>a{font-size:12px;color:#c6d7d0}.user-mini{display:flex;align-items:center;gap:8px;min-width:0}.user-mini>div:last-child{display:grid;min-width:0}.user-mini b{font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.user-mini span{font-size:10px;color:#9ab2a7}.avatar{width:42px;height:42px;border-radius:14px;background:#e8efe9;color:var(--brand);display:grid;place-items:center;font-weight:900;border:1px solid #d7e1da}.avatar.small{width:34px;height:34px;border-radius:11px;background:rgba(255,255,255,.12);color:#fff;border-color:rgba(255,255,255,.08)}.main{margin-left:var(--sidebar);min-height:100vh}.topbar{height:92px;display:flex;align-items:center;justify-content:space-between;padding:18px 30px;border-bottom:1px solid rgba(23,63,50,.08);background:rgba(243,245,239,.86);backdrop-filter:blur(16px);position:sticky;top:0;z-index:45}.topbar-left{display:flex;align-items:center;gap:12px}.eyebrow{font-size:12px;color:var(--muted);font-weight:700;margin-bottom:2px}.topbar h1{margin:0;font-size:27px;letter-spacing:-.02em}.top-actions{display:flex;align-items:center;gap:11px}.quick-add{border:0;border-radius:15px;background:var(--brand);color:white;padding:10px 14px;display:flex;align-items:center;gap:8px;font-weight:800;cursor:pointer;box-shadow:0 10px 26px rgba(23,63,50,.16)}.quick-add span{font-size:18px}.menu-btn{display:none;width:44px;height:44px;border:1px solid var(--line);background:#fff;border-radius:13px;padding:0;align-items:center;justify-content:center;box-shadow:0 6px 18px rgba(23,63,50,.08);cursor:pointer}.menu-btn .ui-icon{width:23px;height:23px;color:var(--brand)}.page-wrap{padding:25px 30px 46px;max-width:1600px;margin:0 auto}.demo-banner{display:flex;align-items:center;justify-content:space-between;gap:15px;background:linear-gradient(135deg,#fff7e8,#f6ead1);border:1px solid #ead6ae;border-radius:17px;padding:12px 14px;margin-bottom:16px}.demo-banner>div{display:grid}.demo-banner b{font-size:13px}.demo-banner span{font-size:11px;color:#816a43}.demo-banner a{font-size:12px;font-weight:800;color:#6f5527;background:#fff8;padding:7px 10px;border-radius:10px}.page-intro{display:flex;align-items:center;justify-content:space-between;gap:18px;margin:0 0 18px;background:var(--surface);border:1px solid var(--line);border-radius:18px;padding:14px 16px;box-shadow:0 6px 24px rgba(26,68,51,.04)}.page-intro p{margin:0;color:var(--muted);font-size:13px;max-width:950px}.stats-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin-bottom:18px}.stats-grid.compact .stat-card{min-height:126px}.stat-card{background:var(--surface);border:1px solid var(--line);border-radius:20px;padding:18px;min-height:136px;display:flex;flex-direction:column;justify-content:space-between;box-shadow:0 7px 25px rgba(24,50,41,.04)}.stat-card>span{font-size:12px;color:var(--muted);font-weight:750}.stat-card strong{font-size:26px;line-height:1.15;margin:11px 0 6px;letter-spacing:-.03em}.stat-card small{font-size:11px;color:#8a9790}.panel{background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);padding:21px;box-shadow:var(--shadow);margin-bottom:18px}.panel h2{margin:0 0 15px;font-size:20px;letter-spacing:-.02em}.panel-top{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;margin-bottom:16px}.panel-top h2{margin:2px 0 0}.kicker{font-size:10px;text-transform:uppercase;letter-spacing:.08em;color:var(--accent);font-weight:900}.hero-grid{display:grid;grid-template-columns:1.35fr .9fr;gap:18px}.chart-grid,.two-col{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}.narrow-left{max-width:900px}.form-focus{align-items:start}.soft-panel{background:linear-gradient(145deg,#f7faf7,#eef4ef)}.danger-soft{background:linear-gradient(145deg,#fff8f6,#fff1ee);border-color:#f1d8d3}.recovery-card{background:linear-gradient(135deg,#173f32,#245944);color:#fff;border-color:transparent}.recovery-card .kicker{color:#e1bd75}.recovery-card h2{color:#fff}.recovery-main{display:flex;align-items:center;gap:26px}.donut{--p:0;width:154px;aspect-ratio:1;border-radius:50%;background:conic-gradient(#ddb766 calc(var(--p)*1%),rgba(255,255,255,.14) 0);display:grid;place-items:center;position:relative;flex:0 0 auto}.donut:after{content:"";position:absolute;width:112px;aspect-ratio:1;border-radius:50%;background:#1a4738}.donut>div{position:relative;z-index:1;text-align:center}.donut strong{display:block;font-size:26px}.donut span{font-size:10px;color:#bdd2c8}.recovery-list{display:grid;gap:10px;flex:1}.recovery-list>div,.money-stack>div{display:flex;justify-content:space-between;gap:16px;align-items:center;padding:10px 0;border-bottom:1px solid var(--line)}.recovery-card .recovery-list>div{border-color:rgba(255,255,255,.12)}.recovery-list span,.money-stack span{font-size:12px;color:var(--muted)}.recovery-card .recovery-list span{color:#bdd2c8}.recovery-list b,.money-stack b{font-size:14px}.money-stack .total{border-bottom:0;background:var(--surface-2);padding:12px 13px;border-radius:13px;margin-top:6px}.money-stack .total span,.money-stack .total b{color:var(--ink)}.recovery-card .card-link{color:#fff}.assumption{display:flex;flex-wrap:wrap;gap:8px;margin-top:18px}.assumption span{font-size:10px;background:rgba(255,255,255,.09);padding:6px 8px;border-radius:999px;color:#d8e6df}.toggle-form{display:flex;align-items:center;gap:8px}.toggle-form small{font-size:10px;color:#c8dbd3}.switch{position:relative;width:42px;height:23px}.switch input{display:none}.switch span{position:absolute;inset:0;background:#ffffff2b;border-radius:20px;cursor:pointer}.switch span:after{content:"";position:absolute;width:17px;height:17px;border-radius:50%;background:#fff;left:3px;top:3px;transition:.2s}.switch input:checked+span{background:#d2ad63}.switch input:checked+span:after{transform:translateX(19px)}.quick-cards{display:grid;grid-template-columns:repeat(2,1fr);gap:10px}.quick-cards a,.three-link-grid a,.stock-link-grid a,.link-list a{border:1px solid var(--line);border-radius:16px;background:var(--surface-2);padding:14px;transition:.18s}.quick-cards a:hover,.three-link-grid a:hover,.stock-link-grid a:hover,.link-list a:hover{transform:translateY(-1px);border-color:#b8c9bd;background:#fff}.quick-cards b,.three-link-grid b,.link-list b{display:block;font-size:13px}.quick-cards span,.three-link-grid span,.link-list span,.stock-link-grid small{font-size:11px;color:var(--muted)}.three-link-grid,.stock-link-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:13px;margin-bottom:18px}.stock-link-grid a{display:grid;gap:5px}.stock-link-grid strong{font-size:22px}.link-list{display:grid;gap:10px}.link-list a{display:flex;align-items:center;justify-content:space-between;gap:12px}.link-list a span{text-align:right}.card-link,.mini-link{display:inline-flex;margin-top:14px;font-size:12px;font-weight:850;color:var(--brand-2)}.mini-link{margin:0}.sparkline{width:100%;height:180px;color:var(--brand-2);background:linear-gradient(180deg,#f2f7f3,#fff);border-radius:16px;padding:14px}.empty-chart{height:180px;display:grid;place-items:center;background:var(--surface-2);border-radius:16px;color:var(--muted);font-size:12px}.chart-caption{display:flex;justify-content:space-between;margin-top:11px;color:var(--muted);font-size:11px}.chart-caption b{color:var(--ink)}.form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}.form-grid.one{grid-template-columns:1fr}.span-2{grid-column:span 2}.form-grid label,.filter-row label,.simulator label{display:grid;gap:6px;color:#5f6e65;font-size:12px;font-weight:750}.form-grid input,.form-grid select,.form-grid textarea,.filter-row input,.filter-row select,.simulator input{width:100%;border:1px solid var(--line);background:#fbfcfa;color:var(--ink);border-radius:13px;padding:11px 12px;outline:none;transition:.2s}.form-grid input:focus,.form-grid select:focus,.filter-row input:focus,.filter-row select:focus,.simulator input:focus{border-color:#84a393;box-shadow:0 0 0 4px rgba(31,98,73,.06)}.btn{border:0;border-radius:13px;padding:11px 15px;font-weight:850;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;gap:6px}.btn.primary{background:var(--brand);color:#fff}.btn.secondary{background:#e8f0ea;color:var(--brand)}.btn.ghost{background:transparent;border:1px solid var(--line);color:var(--brand)}.btn.danger{background:var(--danger);color:#fff}.small-btn{padding:8px 11px;font-size:11px}.feature-list{display:grid;gap:10px}.feature-list>div{display:grid;grid-template-columns:145px 1fr;gap:12px;padding:11px 0;border-bottom:1px solid var(--line)}.feature-list>div:last-child{border-bottom:0}.feature-list b{font-size:12px}.feature-list span{font-size:12px;color:var(--muted)}.big-stock{font-size:44px;font-weight:900;letter-spacing:-.04em;margin-top:18px}.big-stock small{font-size:13px;color:var(--muted);margin-left:6px}.formula-copy,.calculation-note{color:var(--muted);font-size:12px}.table-wrap{overflow:auto;border:1px solid var(--line);border-radius:16px}table{width:100%;border-collapse:collapse;min-width:760px}th,td{text-align:left;padding:12px 13px;border-bottom:1px solid var(--line);white-space:nowrap}th{background:#f7f9f6;color:#68766d;font-size:11px;position:sticky;top:0}td{font-size:12px}tr:last-child td{border-bottom:0}.inline-form{display:inline}.text-danger{border:0;background:none;color:var(--danger);cursor:pointer;font-weight:800;font-size:11px}.table-empty{text-align:center;padding:18px;color:var(--muted);white-space:normal}.demo-badge,.source-pill,.stock-pill,.mode-pill{display:inline-flex;align-items:center;border-radius:999px;padding:4px 7px;font-size:9px;font-weight:900;vertical-align:middle}.demo-badge{background:#fff1d5;color:#7d5b1d;margin-left:5px}.source-pill{background:#eaf2ed;color:var(--brand-2)}.stock-pill{background:#e8f3ec;color:#1f6749}.mode-pill{background:var(--accent-soft);color:#765b2a}.pos{color:var(--success);font-weight:850}.neg{color:var(--danger);font-weight:850}.toast{padding:12px 14px;border-radius:14px;margin-bottom:14px;border:1px solid;font-size:12px}.toast-ok{background:#eef8f2;color:#1d6246;border-color:#d2eadb}.toast-error{background:#fff2ef;color:#98443a;border-color:#f1d5d0}.filter-panel{padding:16px}.filter-row{display:grid;grid-template-columns:1.15fr 1fr 1fr auto auto;gap:11px;align-items:end}.filter-row.compact-filter{grid-template-columns:1fr 1.4fr auto;max-width:760px}.check-line{display:flex!important;align-items:center!important;gap:8px;padding:10px 0}.check-line input{width:auto!important}.report-range{font-size:11px;color:var(--muted);margin:-5px 0 14px 3px}.break-result{margin-top:8px;border-radius:18px;background:var(--accent-soft);padding:18px;display:grid;gap:3px}.break-result span,.break-result small{color:#796343}.break-result strong{font-size:27px}.simulator{display:grid;grid-template-columns:repeat(4,1fr) 1.25fr;gap:14px;align-items:end}.sim-result{border-radius:18px;background:var(--brand);color:white;padding:16px;display:grid}.sim-result span,.sim-result small{font-size:10px;color:#bfd4ca}.sim-result b{font-size:18px}.sim-result strong{font-size:24px}.break-explain{display:grid;grid-template-columns:repeat(4,1fr);gap:13px}.break-explain>div{padding:14px;border-radius:15px;background:var(--surface-2);display:grid;gap:5px}.break-explain b{font-size:12px}.break-explain span{font-size:11px;color:var(--muted)}.muted{color:var(--muted)}.empty-state{display:grid;gap:9px;justify-items:start;padding:10px 0}.empty-state span{font-size:12px;color:var(--muted)}.success-note{padding:12px 14px;border-radius:13px;background:#eef8f2;color:#276147;font-size:12px}.modal{position:fixed;inset:0;z-index:120;display:none}.modal.open{display:block}.modal-backdrop{position:absolute;inset:0;background:rgba(6,28,22,.68);backdrop-filter:blur(4px)}.sheet{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);width:min(600px,calc(100% - 30px));background:#fff;border-radius:26px;padding:20px;box-shadow:0 30px 100px rgba(0,0,0,.28)}.sheet-handle{display:none}.sheet-head{display:flex;justify-content:space-between;align-items:flex-start}.sheet-head h3{margin:2px 0 0}.close-btn{width:38px;height:38px;border:0;border-radius:12px;background:#f0f3ef;font-size:24px;color:var(--brand);cursor:pointer}.quick-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:10px;margin-top:18px}.quick-grid a{padding:14px;border-radius:15px;background:var(--surface-2);font-weight:700;border:1px solid var(--line);display:grid}.quick-grid a b{font-size:12px}.quick-grid a span{font-size:10px;color:var(--muted);margin-top:2px}.drawer-backdrop{display:none}.drawer-backdrop.show{display:block;position:fixed;inset:0;background:rgba(7,25,19,.58);z-index:70;backdrop-filter:blur(3px)}
.auth-body{min-height:100vh;display:grid;place-items:center;background:radial-gradient(circle at top left,#1d5c45 0,#123d2e 32%,#f3f5ef 32.1%);padding:24px}.auth-wrap{width:min(100%,440px)}.auth-brand{text-align:center;margin-bottom:20px}.auth-brand h1{margin:12px 0 2px}.auth-brand p{margin:0;color:var(--muted)}.auth-card{background:white;border-radius:26px;padding:28px;border:1px solid var(--line);box-shadow:0 28px 80px #0a2a2030}.auth-card h2{margin:10px 0 5px}.auth-card>p{color:var(--muted);margin-top:0}.badge{font-size:10px;padding:6px 9px;border-radius:999px;background:var(--accent-soft);color:#7a5f2e;font-weight:800}
@media(max-width:1180px){.stats-grid{grid-template-columns:repeat(2,1fr)}.hero-grid{grid-template-columns:1fr}.simulator{grid-template-columns:repeat(2,1fr)}.sim-result{grid-column:span 2}.break-explain{grid-template-columns:repeat(2,1fr)}}
@media(max-width:900px){:root{--sidebar:0px}.main{margin-left:0}.sidebar{transform:translateX(-105%);transition:transform .24s ease;width:min(86vw,300px)}body.drawer-open .sidebar{transform:translateX(0)}.drawer-close,.menu-btn{display:block}.topbar{height:78px;padding:12px 15px}.topbar h1{font-size:21px}.eyebrow{font-size:10px}.page-wrap{padding:16px 13px 36px}.top-actions .avatar{display:none}.quick-add b{display:none}.quick-add{width:42px;height:42px;padding:0;justify-content:center}.two-col,.chart-grid{grid-template-columns:1fr}.filter-row{grid-template-columns:repeat(2,1fr)}.panel{padding:18px;border-radius:20px}.sheet{left:0;right:0;top:auto;bottom:0;transform:none;width:100%;border-radius:28px 28px 0 0;padding:14px 17px 26px}.sheet-handle{display:block;width:42px;height:4px;background:#d7ddd8;border-radius:10px;margin:0 auto 15px}.drawer-backdrop.show{display:block}}
@media(max-width:620px){.stats-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}.stat-card{padding:14px;min-height:108px}.stat-card strong{font-size:19px}.stat-card small{font-size:9px}.page-intro{display:grid}.page-intro .btn{justify-self:start}.recovery-main{display:grid}.donut{margin:auto;width:138px}.recovery-list{width:100%}.quick-cards,.three-link-grid,.stock-link-grid{grid-template-columns:1fr 1fr}.form-grid{grid-template-columns:1fr}.span-2{grid-column:span 1}.filter-row,.filter-row.compact-filter,.simulator{grid-template-columns:1fr}.sim-result{grid-column:span 1}.feature-list>div{grid-template-columns:1fr;gap:3px}.break-explain{grid-template-columns:1fr}.demo-banner{align-items:flex-start}.demo-banner a{white-space:nowrap}.panel-top{align-items:center}.table-wrap{border-radius:13px}.quick-grid{grid-template-columns:1fr 1fr}.auth-body{background:linear-gradient(160deg,#123d2e 0,#123d2e 23%,#f3f5ef 23.1%)}.auth-card{padding:22px}.big-stock{font-size:38px}}
@media(max-width:420px){.quick-cards,.three-link-grid,.stock-link-grid{grid-template-columns:1fr}.stats-grid{grid-template-columns:1fr 1fr}.topbar h1{font-size:19px}.demo-banner{display:grid}.quick-grid{grid-template-columns:1fr 1fr}}

.trend-chart-wrap{width:100%;overflow-x:auto;padding-bottom:2px}.trend-chart{width:100%;min-width:620px;height:230px;display:block;background:linear-gradient(180deg,#f6faf7,#fff);border-radius:16px}.trend-grid{stroke:#dfe8e1;stroke-width:1}.trend-line{fill:none;stroke:var(--brand-2);stroke-width:3.2;stroke-linecap:round;stroke-linejoin:round}.trend-dot{fill:#fff;stroke:var(--brand-2);stroke-width:2.3}.trend-axis{fill:#7b8a81;font-size:10px;font-family:inherit}.monthly-charts .panel{min-width:0}@media(max-width:900px){.menu-btn{display:flex!important;flex:0 0 44px}.topbar-left{min-width:0}.topbar-left>div{min-width:0}.topbar h1{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:58vw}.trend-chart{min-width:680px}}

@media(max-width:900px){body.drawer-open{overflow:hidden}.drawer-backdrop.show{display:block}}


/* v2.5 usability polish */
.row-actions{display:flex;align-items:center;gap:10px;white-space:nowrap}.text-edit,.text-danger{border:0;background:transparent;padding:5px 3px;font-weight:800;font-size:12px;cursor:pointer}.text-edit{color:var(--brand-2)}.text-danger{color:var(--danger)}
.trend-chart-wrap{width:100%;overflow:hidden;padding-bottom:0}.trend-chart{width:100%;min-width:0!important;height:auto;aspect-ratio:760/230;max-height:240px}.dashboard-kpis{grid-template-columns:repeat(4,minmax(0,1fr))}
.smart-select{position:relative}.smart-select>select{position:absolute!important;opacity:0!important;pointer-events:none!important;width:1px!important;height:1px!important}.smart-select-button{width:100%;min-height:46px;border:1px solid var(--line);background:#fff;border-radius:13px;padding:11px 42px 11px 13px;text-align:left;position:relative;cursor:pointer;color:var(--ink)}.smart-select-button:after{content:'⌄';position:absolute;right:14px;top:50%;transform:translateY(-50%);color:var(--muted);font-size:18px}.smart-select-popup{position:fixed;z-index:10020;width:min(520px,calc(100vw - 24px));max-height:min(520px,70vh);background:#fff;border:1px solid var(--line);border-radius:18px;box-shadow:0 24px 70px rgba(18,56,43,.20);padding:12px;display:none;overflow:hidden}.smart-select-popup.open{display:block}.smart-select-search{width:100%;height:46px;border:1px solid var(--line);border-radius:13px;padding:0 13px;margin-bottom:8px;outline:none}.smart-select-options{max-height:390px;overflow:auto;display:grid;gap:4px;overscroll-behavior:contain}.smart-select-option{border:0;background:transparent;border-radius:12px;padding:11px 12px;text-align:left;cursor:pointer;color:var(--ink)}.smart-select-option:hover,.smart-select-option.active{background:var(--brand-soft);color:var(--brand);font-weight:750}.smart-select-empty{padding:18px;text-align:center;color:var(--muted)}
@media(max-width:900px){.dashboard-kpis{grid-template-columns:repeat(2,minmax(0,1fr))}.menu-btn{width:44px!important;height:44px!important;border-radius:13px!important;display:grid!important;place-items:center!important}.menu-btn .ui-icon{width:23px!important;height:23px!important}.smart-select-popup{left:12px!important;right:12px!important;bottom:12px!important;top:auto!important;width:auto!important;max-height:72vh;border-radius:24px}.smart-select-options{max-height:52vh}}
@media(max-width:520px){.dashboard-kpis{grid-template-columns:repeat(2,minmax(0,1fr))}.dashboard-kpis .stat-card{padding:14px 12px}.dashboard-kpis .stat-card strong{font-size:21px}.chart-grid{grid-template-columns:1fr!important}.monthly-charts .panel{padding:15px}.trend-axis{font-size:9px}}

/* ===== native-feel header and quick entry ===== */
.topbar{position:sticky;display:grid;grid-template-columns:1fr auto 1fr;align-items:center}
.topbar-left{justify-self:start;min-width:44px}
.topbar-center{grid-column:2;text-align:center;min-width:0;max-width:min(620px,52vw)}
.topbar-center .eyebrow{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.topbar-center h1{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.top-actions{justify-self:end}
.quick-add{border:0}
.quick-add .ui-icon{width:18px;height:18px}
.dashboard-kpis .profit-card{border-color:#cfe8da;background:linear-gradient(145deg,#ffffff,#f1faf5)}
.dashboard-kpis .profit-card strong{color:var(--success)}
.dashboard-kpis .loss-card{border-color:#f1d7d1;background:linear-gradient(145deg,#ffffff,#fff5f2)}
.dashboard-kpis .loss-card strong{color:var(--danger)}

@media(max-width:900px){
  .topbar{grid-template-columns:48px minmax(0,1fr) 48px;padding:10px 13px;height:76px;gap:7px}
  .topbar-left{grid-column:1;justify-self:start}
  .topbar-center{grid-column:2;max-width:100%;width:100%;text-align:center}
  .topbar-center .eyebrow{font-size:9px;margin-bottom:1px}
  .topbar-center h1{font-size:19px;max-width:100%}
  .top-actions{grid-column:3;justify-self:end;gap:0}
  .top-actions .avatar{display:none}
  .quick-add{width:42px;height:42px;padding:0;display:grid;place-items:center;border-radius:13px}
  .quick-add b{display:none}
  .quick-add .ui-icon{width:21px;height:21px}
}
@media(max-width:420px){
  .topbar-center h1{font-size:18px}
  .topbar-center .eyebrow{font-size:8.5px}
}

/* ===== v2.9 feed purchase + stable mobile selector ===== */
.smart-select-backdrop{position:fixed;inset:0;z-index:10010;background:rgba(9,31,24,.42);backdrop-filter:blur(2px);opacity:0;visibility:hidden;pointer-events:none;transition:opacity .14s ease,visibility .14s ease}
.smart-select-backdrop.open{opacity:1;visibility:visible;pointer-events:auto}
.smart-select-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:8px}.smart-select-head b{font-size:13px}.smart-select-close{width:36px;height:36px;border:0;border-radius:11px;background:var(--surface-2);color:var(--brand);font-size:22px;display:grid;place-items:center;cursor:pointer;touch-action:manipulation}
.smart-select-button,.smart-select-option{touch-action:manipulation;-webkit-tap-highlight-color:transparent}.smart-select-button:focus-visible{outline:0;border-color:#84a393;box-shadow:0 0 0 4px rgba(31,98,73,.07)}
.smart-select-option{min-height:46px;display:flex;align-items:center;width:100%}.smart-select-options{-webkit-overflow-scrolling:touch;overscroll-behavior:contain}
.form-grid select:not([data-smart-select]),.filter-row select:not([data-smart-select]),.purchase-head-fields select:not([data-smart-select]){appearance:none;-webkit-appearance:none;background-image:linear-gradient(45deg,transparent 50%,var(--muted) 50%),linear-gradient(135deg,var(--muted) 50%,transparent 50%);background-position:calc(100% - 18px) 50%,calc(100% - 13px) 50%;background-size:5px 5px,5px 5px;background-repeat:no-repeat;padding-right:38px!important}
.feed-purchase-panel{max-width:1100px}.multi-purchase-form{display:grid;gap:16px}.purchase-head-fields{display:grid;grid-template-columns:minmax(220px,340px);gap:14px}.purchase-head-fields label,.purchase-item-row label{display:grid;gap:6px;color:#5f6e65;font-size:12px;font-weight:750}.purchase-head-fields input,.purchase-item-row input{width:100%;border:1px solid var(--line);background:#fbfcfa;color:var(--ink);border-radius:13px;padding:11px 12px;outline:none}.purchase-items{display:grid;gap:10px}.purchase-item-row{position:relative;display:grid;grid-template-columns:minmax(250px,1.55fr) minmax(120px,.58fr) minmax(130px,.62fr) minmax(118px,.48fr) 38px;gap:10px;align-items:end;border:1px solid var(--line);background:var(--surface-2);border-radius:17px;padding:12px}.purchase-item-main{min-width:0}.purchase-line-total{min-height:46px;border:1px solid var(--line);background:#fff;border-radius:13px;padding:7px 11px;display:grid;align-content:center}.purchase-line-total span{font-size:9px;color:var(--muted);font-weight:750}.purchase-line-total strong{font-size:14px;color:var(--brand)}.purchase-remove{width:38px;height:38px;border:0;border-radius:11px;background:var(--danger-soft);color:var(--danger);font-size:22px;cursor:pointer;touch-action:manipulation;margin-bottom:4px}.purchase-actions{display:flex;align-items:center;justify-content:space-between;gap:14px}.purchase-grand-total{display:grid;text-align:right}.purchase-grand-total span{font-size:10px;color:var(--muted)}.purchase-grand-total strong{font-size:23px;color:var(--brand)}.purchase-save{justify-self:end;min-width:240px}
@media(max-width:900px){
  body.smart-select-open{overflow:hidden;overscroll-behavior:none}.smart-select-backdrop{z-index:10018;background:rgba(9,31,24,.36);backdrop-filter:none}.smart-select-popup{z-index:10020;left:8px!important;right:8px!important;bottom:max(8px,env(safe-area-inset-bottom))!important;top:auto!important;width:auto!important;max-height:min(76dvh,640px)!important;border-radius:22px!important;padding:12px!important;transform:none!important;animation:none!important;box-shadow:0 18px 55px rgba(18,56,43,.24)}.smart-select-search-wrap{position:sticky;top:0;background:#fff;z-index:2;padding-bottom:8px}.smart-select-search{font-size:16px!important;height:48px!important;margin-bottom:0!important;touch-action:manipulation}.smart-select-options{max-height:calc(min(76dvh,640px) - 108px)!important;padding-bottom:max(4px,env(safe-area-inset-bottom));scrollbar-gutter:stable}.smart-select-option{min-height:50px;padding:12px 13px;font-size:14px}.smart-select-button{min-height:48px;background:#fbfcfa;font-size:16px;line-height:1.35}.smart-select-head{margin-bottom:9px;position:sticky;top:0;background:#fff;z-index:3}.smart-select-close{flex:0 0 auto}
  .form-grid select:not([data-smart-select]),.filter-row select:not([data-smart-select]),.purchase-head-fields select:not([data-smart-select]),select{font-size:16px;min-height:48px}
  .purchase-item-row{grid-template-columns:1fr 1fr;padding:12px}.purchase-item-main{grid-column:1/-1}.purchase-line-total{grid-column:1/2}.purchase-remove{grid-column:2/3;justify-self:end;align-self:center;margin:0}.purchase-head-fields{grid-template-columns:1fr}.purchase-actions{align-items:stretch;flex-direction:column}.purchase-grand-total{text-align:left;border:1px solid var(--line);border-radius:14px;background:var(--surface-2);padding:11px 13px}.purchase-save{justify-self:stretch;width:100%}
}
@media(max-width:520px){.purchase-item-row{grid-template-columns:1fr}.purchase-item-main,.purchase-line-total,.purchase-remove{grid-column:1}.purchase-remove{position:absolute;right:10px;top:10px}.purchase-item-row{padding-top:45px}.purchase-item-row:first-child{padding-top:12px}.purchase-item-row:first-child .purchase-remove{display:none}.purchase-actions .btn{width:100%}}

/* ===== v2.10 header alignment + floating quick entry ===== */
.topbar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:18px;
}
.topbar-center{
  order:1;
  flex:1 1 auto;
  max-width:none;
  min-width:0;
  text-align:left;
}
.topbar-left{display:none}
.top-actions{
  order:2;
  margin-left:auto;
  flex:0 0 auto;
  display:flex;
  align-items:center;
  gap:10px;
}
.quick-add-floating{
  position:fixed;
  right:92px;
  bottom:calc(22px + env(safe-area-inset-bottom));
  z-index:108;
  width:58px;
  height:58px;
  padding:0;
  border-radius:19px;
  display:grid;
  place-items:center;
  box-shadow:0 16px 42px rgba(17,53,42,.22);
  transition:transform .16s ease,box-shadow .16s ease,opacity .12s ease;
}
.quick-add-floating b{display:none}
.quick-add-floating .ui-icon{width:24px;height:24px}
.quick-add-floating:hover{transform:translateY(-2px);box-shadow:0 20px 48px rgba(17,53,42,.28)}
.quick-add-floating:active{transform:scale(.96)}
body.drawer-open .quick-add-floating,
body.drawer-open .qf-ai-launcher,
body.drawer-open .qf-ai-window{
  opacity:0!important;
  visibility:hidden!important;
  pointer-events:none!important;
}
@media(min-width:901px){
  .menu-btn{display:none!important}
}
@media(max-width:900px){
  .topbar{
    display:flex;
    height:76px;
    padding:10px 13px;
    gap:10px;
  }
  .topbar-center{
    order:1;
    flex:1 1 auto;
    width:auto;
    text-align:left;
    min-width:0;
  }
  .topbar-center h1{max-width:100%;font-size:19px}
  .topbar-center .eyebrow{font-size:9px;margin-bottom:1px}
  .top-actions{order:2;margin-left:auto;gap:0}
  .top-actions .avatar{display:none}
  .menu-btn{display:flex!important;flex:0 0 44px;width:44px;height:44px}
  .quick-add-floating{
    right:78px;
    bottom:calc(16px + env(safe-area-inset-bottom));
    width:54px;
    height:54px;
    border-radius:17px;
  }
}
@media(max-width:420px){
  .topbar-center h1{font-size:18px}
  .topbar-center .eyebrow{font-size:8.5px}
}
@media(prefers-reduced-motion:reduce){
  .quick-add-floating{transition:none}
}


/* ===== v2.11 Hind Siliguri + unified selection design ===== */
html,body,button,input,select,textarea{font-family:"Hind Siliguri","Noto Sans Bengali",system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}
.smart-select-popup{border:1px solid #d7e1da;background:#fff}
.smart-select-options{gap:7px;padding:2px}
.smart-select-option{border:1px solid #e0e7e2!important;background:#fbfcfa!important;border-radius:13px!important;padding:11px 13px!important;transition:border-color .12s ease,background .12s ease,box-shadow .12s ease,color .12s ease;box-shadow:0 1px 0 rgba(23,63,50,.02)}
.smart-select-option:hover{border-color:#b8cbbf!important;background:#f4f8f5!important;color:var(--brand)!important}
.smart-select-option.active{border-color:#8fb4a1!important;background:var(--brand-soft)!important;color:var(--brand)!important;font-weight:700;box-shadow:0 0 0 2px rgba(31,98,73,.06)}
.smart-select-button{background:#fbfcfa;border-color:#dbe4de}
.smart-select-button:hover{border-color:#b9cbbf;background:#fff}
.smart-select-search{background:#fbfcfa;border-color:#dbe4de}
.smart-select-search:focus{border-color:#90aa9c;box-shadow:0 0 0 3px rgba(31,98,73,.07)}
.smart-select-head b{font-weight:700}
@media(max-width:900px){
  .smart-select-option{min-height:52px!important;padding:12px 14px!important;border-radius:14px!important}
  .smart-select-options{gap:8px!important}
}

/* ===== v2.14 vendor + invoice cards + left quick action ===== */
.quick-add-floating{left:calc(var(--sidebar) + 24px)!important;right:auto!important}
.panel-actions{display:flex;align-items:center;gap:12px;flex-wrap:wrap}
.purchase-head-fields-invoice{grid-template-columns:minmax(170px,.7fr) minmax(210px,.9fr) minmax(260px,1.2fr)}
.invoice-card-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}
.purchase-invoice-card{border:1px solid var(--line);border-radius:18px;background:linear-gradient(145deg,#fff,#f8faf7);padding:16px;display:grid;gap:13px;box-shadow:0 6px 22px rgba(24,50,41,.04)}
.invoice-card-head{display:flex;justify-content:space-between;gap:16px;align-items:flex-start;padding-bottom:11px;border-bottom:1px solid var(--line)}
.invoice-card-head span,.invoice-meta span,.invoice-vendor span{display:block;font-size:10px;color:var(--muted);font-weight:700}.invoice-card-head h3{margin:2px 0 0;font-size:18px}.invoice-card-head>strong{font-size:20px;color:var(--brand)}
.invoice-meta{display:grid;grid-template-columns:.75fr 1.25fr;gap:12px}.invoice-meta>div{display:grid;gap:2px}.invoice-meta b{font-size:13px}.invoice-meta small{font-size:10px;color:var(--muted)}
.invoice-lines{display:grid;gap:7px}.invoice-line{display:flex;align-items:center;justify-content:space-between;gap:14px;border:1px solid #e1e8e3;background:#fff;border-radius:12px;padding:9px 11px}.invoice-line>div{display:grid;gap:2px;min-width:0}.invoice-line b{font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.invoice-line span{font-size:10px;color:var(--muted)}.invoice-line>strong{font-size:12px;white-space:nowrap}
.invoice-card-actions{display:flex;gap:8px;flex-wrap:wrap;padding-top:2px}.btn.compact{padding:8px 11px;font-size:11px;border-radius:11px}
.invoice-document{max-width:1050px;margin-left:auto;margin-right:auto}.invoice-doc-head{display:flex;justify-content:space-between;gap:20px;align-items:flex-start;border-bottom:1px solid var(--line);padding-bottom:18px}.invoice-doc-head h2{margin:3px 0 2px}.invoice-doc-head p{margin:0;color:var(--muted);font-size:12px}.invoice-doc-total{text-align:right}.invoice-doc-total span{display:block;font-size:10px;color:var(--muted)}.invoice-doc-total strong{font-size:28px;color:var(--brand)}
.invoice-vendor{display:grid;grid-template-columns:1fr auto;gap:22px;padding:18px 0}.invoice-vendor h3{margin:3px 0;font-size:18px}.invoice-vendor p{margin:2px 0;font-size:12px;color:var(--muted)}.invoice-vendor>div:last-child{text-align:right}.invoice-table table{min-width:680px}.invoice-table td small{display:block;color:var(--muted);font-size:10px;margin-top:2px}.invoice-summary{display:flex;justify-content:flex-end;align-items:baseline;gap:16px;padding:18px 4px}.invoice-summary span{font-size:12px;color:var(--muted)}.invoice-summary strong{font-size:25px}.invoice-doc-actions{display:flex;justify-content:flex-end;gap:9px;flex-wrap:wrap}
@media(max-width:900px){
  .quick-add-floating{left:16px!important;right:auto!important}
  .purchase-head-fields-invoice{grid-template-columns:1fr}
  .invoice-card-grid{grid-template-columns:1fr}.purchase-invoice-card{padding:14px}.invoice-card-actions .btn{flex:1 1 auto}
  .invoice-doc-head{gap:12px}.invoice-doc-total strong{font-size:22px}.invoice-vendor{grid-template-columns:1fr}.invoice-vendor>div:last-child{text-align:left}
}
@media print{
  .sidebar,.topbar,.demo-banner,.toast,.quick-add-floating,.no-print,.drawer-backdrop{display:none!important}
  .main{margin:0!important}.page-wrap{padding:0!important}.invoice-document{box-shadow:none!important;border:0!important;margin:0!important;max-width:none!important}.table-wrap{overflow:visible!important}
}

/* v2.15 navigation + recipe/production */
.quick-add-floating{right:24px!important;left:auto!important}
.recipe-lines{display:grid;gap:12px;margin:16px 0}.recipe-line{grid-template-columns:minmax(250px,1.5fr) minmax(180px,.7fr) auto}.recipe-line .purchase-item-main{min-width:0}
@media(max-width:900px){.quick-add-floating{right:16px!important;left:auto!important}.recipe-line{grid-template-columns:1fr}.recipe-line .remove-purchase-row{justify-self:end}}


/* ===== v2.16 selector/search/recipe input polish ===== */
.smart-select-popup{display:none;grid-template-rows:auto auto minmax(0,1fr);overflow:hidden}
.smart-select-popup.open{display:grid}
.smart-select-options{min-height:0;max-height:390px;overflow-y:auto!important;overflow-x:hidden!important;-webkit-overflow-scrolling:touch;touch-action:pan-y;overscroll-behavior:contain;scrollbar-gutter:stable;padding:3px 2px 6px}
.smart-select-option{flex:0 0 auto;white-space:normal;line-height:1.35;word-break:break-word}
.smart-select-search-wrap{min-width:0}
.smart-select-search{-webkit-appearance:none;appearance:none}
.smart-select-search::-webkit-search-cancel-button{cursor:pointer}
.recipe-qty-label{display:grid;align-content:start;gap:6px}
.recipe-qty-control{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;border:1px solid #dbe4de;background:#fbfcfa;border-radius:13px;overflow:hidden;min-height:48px;transition:border-color .12s ease,box-shadow .12s ease,background .12s ease}
.recipe-qty-control:focus-within{border-color:#90aa9c;box-shadow:0 0 0 3px rgba(31,98,73,.07);background:#fff}
.recipe-qty-control input{width:100%;min-width:0;height:46px;border:0!important;outline:0!important;box-shadow:none!important;background:transparent!important;padding:10px 12px!important;font-size:16px;font-weight:650;color:var(--ink)}
.recipe-qty-control span{align-self:stretch;display:grid;place-items:center;padding:0 13px;border-left:1px solid #e2e9e4;background:#f3f7f4;color:var(--muted);font-size:12px;font-weight:750;white-space:nowrap}
.recipe-line{align-items:end}
@media(max-width:900px){
  .smart-select-popup{grid-template-rows:auto auto minmax(0,1fr)!important;max-height:min(82dvh,680px)!important}
  .smart-select-options{max-height:none!important;height:100%!important;min-height:180px;padding-bottom:max(10px,env(safe-area-inset-bottom))!important}
  .smart-select-option{min-height:54px!important}
  .recipe-qty-control{min-height:50px}
  .recipe-qty-control input{height:48px}
}

/* ===== v2.17 recent purchase invoices ===== */
.recent-invoice-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}
.recent-invoice-card{display:block;min-width:0;padding:14px;border:1px solid rgba(23,63,50,.14);border-radius:16px;background:#fff;color:inherit;text-decoration:none;box-shadow:0 4px 14px rgba(20,45,36,.045);transition:border-color .16s ease,box-shadow .16s ease,transform .16s ease}
.recent-invoice-card:hover{border-color:rgba(23,63,50,.32);box-shadow:0 7px 20px rgba(20,45,36,.08);transform:translateY(-1px)}
.recent-invoice-card-top{display:flex;flex-direction:column;gap:3px}.recent-invoice-card-top span,.recent-invoice-card-total span{font-size:12px;color:var(--muted,#718079)}
.recent-invoice-card-top strong{font-size:17px;color:var(--brand,#173f32);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.recent-invoice-card-meta{display:flex;flex-direction:column;gap:2px;margin-top:10px;font-size:12px;color:var(--muted,#718079)}
.recent-invoice-card-total{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:12px;padding-top:10px;border-top:1px solid rgba(23,63,50,.09)}
.recent-invoice-card-total b{font-size:15px;color:var(--text,#23352f)}
@media(max-width:900px){.recent-invoice-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:560px){.recent-invoice-grid{grid-template-columns:1fr}.recent-invoice-card{padding:13px 14px}.recent-invoice-card:hover{transform:none}}

/* v2.19 Recipe ingredient row: selector + quantity + remove stay on one row */
.recipe-line{
  display:grid!important;
  grid-template-columns:minmax(0,1fr) minmax(150px,190px) 40px!important;
  gap:10px!important;
  align-items:end!important;
}
.recipe-line .purchase-item-main,
.recipe-line .recipe-qty-label{min-width:0!important;margin:0!important}
.recipe-line .remove-purchase-row{
  width:40px!important;
  height:48px!important;
  min-width:40px!important;
  align-self:end!important;
  justify-self:end!important;
  margin:0!important;
  border-radius:12px!important;
  display:grid!important;
  place-items:center!important;
  line-height:1!important;
}
@media(max-width:900px){
  .recipe-line{
    grid-template-columns:minmax(0,1fr) minmax(116px,132px) 40px!important;
    gap:8px!important;
    padding:11px!important;
  }
  .recipe-line .purchase-item-main{grid-column:auto!important}
  .recipe-line .remove-purchase-row{justify-self:end!important;align-self:end!important}
  .recipe-line .smart-select-button{padding-left:11px!important;padding-right:34px!important;font-size:14px!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .recipe-line .recipe-qty-label{font-size:11px!important}
  .recipe-line .recipe-qty-control{min-height:48px!important}
  .recipe-line .recipe-qty-control input{height:46px!important;padding:9px 8px!important;font-size:15px!important}
  .recipe-line .recipe-qty-control span{padding:0 8px!important;font-size:10px!important}
}
@media(max-width:430px){
  .recipe-line{
    grid-template-columns:minmax(0,1fr) 108px 38px!important;
    gap:7px!important;
    padding:10px!important;
  }
  .recipe-line .remove-purchase-row{width:38px!important;height:48px!important;min-width:38px!important}
  .recipe-line .smart-select-button{font-size:13px!important;padding-left:9px!important;padding-right:30px!important}
  .recipe-line .smart-select-button:after{right:10px!important}
  .recipe-line .recipe-qty-control input{padding:8px 6px!important;font-size:14px!important}
  .recipe-line .recipe-qty-control span{padding:0 6px!important;font-size:9px!important}
}


/* ===== v2.20 stock totals, production live calculation, grouped KPI, history paging ===== */
tfoot .stock-grand-row th,tfoot .stock-grand-value th{background:#f6f9f7;border-top:1px solid #dce5df;font-weight:750}
tfoot .stock-grand-value th{background:#edf5f0;color:var(--brand);font-size:13px}
.production-live{border:1px solid #dce6df;border-radius:18px;background:#fbfcfa;padding:14px;min-width:0}
.production-live-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:10px}.production-live-head h3{margin:2px 0 0;font-size:16px}.production-calc-table td small{display:block;color:var(--muted);font-size:10px;margin-top:2px}.production-calc-table tfoot th{background:#eef5f0}.stock-short-row td{background:#fff7f5!important}.stock-warning{display:block;color:var(--danger);font-size:10px;font-weight:700;margin-top:3px}.stock-pill.danger{background:#fff0ed;color:var(--danger);border-color:#f2c7bd}.btn:disabled{opacity:.5;cursor:not-allowed}
.dashboard-kpi-sections{display:grid;gap:14px;margin-bottom:16px}.kpi-section{border:1px solid var(--line);background:rgba(255,255,255,.55);border-radius:20px;padding:13px}.kpi-section-head{display:flex;align-items:center;gap:8px;margin:0 0 9px;padding:0 2px}.kpi-section-head span{font-size:12px;font-weight:800;color:var(--brand);letter-spacing:.02em}.kpi-section .stats-grid{margin:0}
.history-view-more-wrap{display:flex;justify-content:center;padding:14px 0 0}.history-view-more{border:1px solid #cfdcd4;background:#fff;color:var(--brand);border-radius:12px;padding:9px 16px;font-weight:700;cursor:pointer}.history-hidden{display:none!important}.text-view{border:0;background:none;color:#44675a;font:inherit;font-weight:700;font-size:11px;padding:0;cursor:pointer}.record-view-modal{position:fixed;inset:0;z-index:10020;display:none;place-items:center;padding:20px;background:rgba(8,24,18,.38)}.record-view-modal.open{display:grid}.record-view-card{width:min(620px,100%);max-height:min(80dvh,700px);overflow:auto;background:#fff;border-radius:22px;box-shadow:0 24px 70px rgba(10,28,21,.22);padding:18px}.record-view-head{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:12px}.record-view-head h3{margin:0}.record-view-close{width:36px;height:36px;border:0;border-radius:11px;background:#f0f4f1;font-size:22px;cursor:pointer}.record-view-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}.record-view-field{border:1px solid #e1e8e3;border-radius:13px;padding:10px}.record-view-field span{display:block;color:var(--muted);font-size:10px;margin-bottom:3px}.record-view-field b{font-size:13px;word-break:break-word}
@media(max-width:700px){.record-view-grid{grid-template-columns:1fr}.production-live{padding:10px}.production-calc-table{min-width:690px}.kpi-section{padding:10px}.kpi-section .dashboard-kpis{grid-template-columns:repeat(2,minmax(0,1fr))}}

.danger-outline{border:1px solid #efc8c0!important;color:var(--danger)!important;background:#fff7f5!important}.invoice-history-grid .history-hidden-card{display:none!important}

/* v2.21 dashboard compact KPI grid */
.dashboard-kpis{grid-template-columns:repeat(5,minmax(0,1fr))!important;gap:9px!important}
.dashboard-kpis .stat-card{min-height:98px!important;padding:12px 11px!important;border-radius:16px!important}
.dashboard-kpis .stat-card>span{font-size:10.5px!important;line-height:1.25}
.dashboard-kpis .stat-card strong{font-size:20px!important;margin:7px 0 4px!important;line-height:1.08}
.dashboard-kpis .stat-card small{font-size:9px!important;line-height:1.3}
@media(max-width:900px){.dashboard-kpis{grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:7px!important}.dashboard-kpis .stat-card{min-height:92px!important;padding:10px 8px!important}.dashboard-kpis .stat-card>span{font-size:9.5px!important}.dashboard-kpis .stat-card strong{font-size:17px!important}.dashboard-kpis .stat-card small{font-size:8px!important}}
@media(max-width:380px){.dashboard-kpis .stat-card{padding:9px 6px!important}.dashboard-kpis .stat-card strong{font-size:15px!important}.dashboard-kpis .stat-card>span{font-size:8.8px!important}.dashboard-kpis .stat-card small{font-size:7.5px!important}}

/* v2.22 mobile readability */
@media(max-width:389px){.dashboard-kpis{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:7px!important}.dashboard-kpis .stat-card{min-height:92px!important;padding:10px 9px!important}.dashboard-kpis .stat-card>span{font-size:10px!important}.dashboard-kpis .stat-card strong{font-size:17px!important}.dashboard-kpis .stat-card small{font-size:8.5px!important}}

/* v2.22 final audit polish */
.recipe-rename-warning{margin:0 0 12px;padding:10px 12px;border:1px solid #e8c873;background:#fff9e8;color:#705716;border-radius:12px;font-size:12px;line-height:1.5}
@media(max-width:389px){
  .topbar{gap:8px}
  .topbar-title{min-width:0}
  .topbar-title strong{font-size:15px}
  .topbar-title small{font-size:10px}
  .dashboard-section-title{font-size:13px}
}

/* v2.23 recipe form compact spacing + ingredient/quantity balance */
#recipeForm .multi-purchase-footer{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  margin:8px 0 8px;
}
#recipeForm .multi-purchase-footer .purchase-grand-total{
  text-align:right;
  padding:0;
  border:0;
  background:transparent;
}
#recipeForm .multi-purchase-footer .purchase-grand-total span{font-size:10px;line-height:1.2}
#recipeForm .multi-purchase-footer .purchase-grand-total strong{font-size:18px;line-height:1.2}
#recipeForm > .btn.primary[type="submit"]{margin-top:0}

/* Give the ingredient selector more room than the quantity field */
.recipe-line{
  grid-template-columns:minmax(0,1fr) minmax(126px,154px) 40px!important;
}

@media(max-width:900px){
  .recipe-line{
    grid-template-columns:minmax(0,1fr) 104px 38px!important;
    gap:7px!important;
  }
  .recipe-line .recipe-qty-control span{padding:0 6px!important}
}

@media(max-width:560px){
  #recipeForm .multi-purchase-footer{
    margin:6px 0 6px;
    gap:7px;
  }
  #recipeForm .multi-purchase-footer .btn{
    padding:9px 11px;
    min-height:38px;
    font-size:12px;
  }
  #recipeForm .multi-purchase-footer .purchase-grand-total{
    display:flex;
    align-items:center;
    justify-content:flex-end;
    gap:6px;
    min-width:0;
  }
  #recipeForm .multi-purchase-footer .purchase-grand-total span{
    font-size:9px;
    white-space:nowrap;
  }
  #recipeForm .multi-purchase-footer .purchase-grand-total strong{
    font-size:14px;
    white-space:nowrap;
  }
  #recipeForm > .btn.primary[type="submit"]{
    width:100%;
    margin-top:0;
  }
  .recipe-line{
    grid-template-columns:minmax(0,1fr) 92px 36px!important;
    gap:6px!important;
    padding:9px!important;
  }
  .recipe-line .remove-purchase-row{
    width:36px!important;
    min-width:36px!important;
    height:46px!important;
  }
  .recipe-line .recipe-qty-label{
    font-size:9px!important;
    line-height:1.15!important;
  }
  .recipe-line .recipe-qty-control{
    min-height:46px!important;
  }
  .recipe-line .recipe-qty-control input{
    height:44px!important;
    padding:8px 4px!important;
    font-size:14px!important;
  }
  .recipe-line .recipe-qty-control span{
    padding:0 4px!important;
    font-size:8px!important;
  }
}

@media(max-width:360px){
  .recipe-line{
    grid-template-columns:minmax(0,1fr) 84px 34px!important;
    gap:5px!important;
  }
  .recipe-line .remove-purchase-row{
    width:34px!important;
    min-width:34px!important;
  }
  #recipeForm .multi-purchase-footer .btn{padding:8px 9px;font-size:11px}
  #recipeForm .multi-purchase-footer .purchase-grand-total strong{font-size:13px}
}

/* ===== v2.24 mobile UI cleanup from real-device screenshot ===== */
.panel-top>*{min-width:0}
.panel-top h2,.invoice-card-head h3{overflow-wrap:anywhere;word-break:break-word}
.smart-select-button{width:100%;min-width:0}

/* Recipe ingredient rows: selector gets the space, amount stays compact. */
.recipe-line{
  grid-template-columns:minmax(0,1fr) 112px 36px!important;
  gap:7px!important;
  padding:10px!important;
  align-items:end!important;
}
.recipe-line .purchase-item-main>label,
.recipe-line .recipe-qty-label{
  min-width:0!important;
  display:grid!important;
  grid-template-rows:auto 48px!important;
  gap:5px!important;
  align-content:end!important;
}
.recipe-line .purchase-item-main>label{font-size:12px!important}
.recipe-line .recipe-qty-label{font-size:10px!important;line-height:1.15!important}
.recipe-line .smart-select-button{height:48px!important;min-height:48px!important;padding:9px 30px 9px 10px!important;font-size:14px!important;border-radius:13px!important}
.recipe-line .recipe-qty-control{height:48px!important;min-height:48px!important;border-radius:13px!important;grid-template-columns:minmax(0,1fr) 30px!important}
.recipe-line .recipe-qty-control input{height:46px!important;padding:8px 6px!important;font-size:14px!important;font-weight:700!important;text-align:center!important}
.recipe-line .recipe-qty-control span{padding:0 4px!important;font-size:9px!important}
.recipe-line .remove-purchase-row{width:36px!important;min-width:36px!important;height:48px!important;border-radius:12px!important;font-size:18px!important}

/* Keep recipe action/ratio/save area visually tight. */
#recipeForm .recipe-lines{margin:12px 0 8px!important;gap:8px!important}
#recipeForm .multi-purchase-footer{margin:4px 0 5px!important;gap:7px!important}
#recipeForm .multi-purchase-footer .btn{min-height:40px;padding:8px 11px!important;border-radius:13px!important}
#recipeForm .multi-purchase-footer .purchase-grand-total{min-width:0;display:flex;align-items:baseline;justify-content:flex-end;gap:7px;flex-wrap:wrap}
#recipeForm .multi-purchase-footer .purchase-grand-total span{font-size:10px!important;white-space:nowrap}
#recipeForm .multi-purchase-footer .purchase-grand-total strong{font-size:16px!important;white-space:nowrap}
#recipeForm>.btn.primary[type="submit"]{margin-top:0!important;min-height:48px!important}

/* Recipe/history cards should never collide with their right-side badges/actions. */
.purchase-invoice-card{min-width:0;overflow:hidden}
.invoice-card-head>div{min-width:0;flex:1 1 auto}
.invoice-card-head h3{max-width:100%;font-size:17px;line-height:1.32}
.invoice-card-head>strong{flex:0 0 auto;font-size:13px!important;line-height:1.2;padding:6px 8px;border:1px solid #dce6df;background:#f4f8f5;border-radius:10px;white-space:nowrap}
.invoice-line>div{min-width:0}.invoice-line b{max-width:100%}

@media(max-width:900px){
  .page-wrap{padding-bottom:92px!important}
  .quick-add-floating{width:50px!important;height:50px!important;right:12px!important;bottom:calc(12px + env(safe-area-inset-bottom))!important;border-radius:16px!important}
  .quick-add-floating .ui-icon{width:21px!important;height:21px!important}
}

@media(max-width:560px){
  .page-wrap{padding:14px 11px 92px!important}
  .panel{padding:14px!important;border-radius:18px!important;margin-bottom:14px!important}
  .panel-top{gap:9px!important;margin-bottom:12px!important;align-items:flex-start!important}
  .panel-top h2{font-size:18px!important;line-height:1.25!important;margin-top:1px!important}
  .panel-top .mini-link{font-size:11px!important;white-space:nowrap!important;flex:0 0 auto}
  .form-grid{gap:11px!important}
  .form-grid label{min-width:0}
  .form-grid input,.form-grid textarea{min-width:0}
  .recipe-line{grid-template-columns:minmax(0,1fr) 92px 34px!important;gap:6px!important;padding:8px!important}
  .recipe-line .purchase-item-main>label,.recipe-line .recipe-qty-label{grid-template-rows:auto 46px!important;gap:4px!important}
  .recipe-line .purchase-item-main>label{font-size:11px!important}
  .recipe-line .recipe-qty-label{font-size:8.8px!important}
  .recipe-line .smart-select-button{height:46px!important;min-height:46px!important;font-size:13px!important;padding-left:9px!important;padding-right:27px!important}
  .recipe-line .recipe-qty-control{height:46px!important;min-height:46px!important;grid-template-columns:minmax(0,1fr) 27px!important}
  .recipe-line .recipe-qty-control input{height:44px!important;font-size:13px!important;padding:7px 4px!important}
  .recipe-line .recipe-qty-control span{font-size:8px!important;padding:0 3px!important}
  .recipe-line .remove-purchase-row{width:34px!important;min-width:34px!important;height:46px!important;font-size:17px!important}
  #recipeForm .multi-purchase-footer{align-items:center!important;margin:3px 0 5px!important}
  #recipeForm .multi-purchase-footer .btn{font-size:11px!important;padding:7px 9px!important;min-height:38px!important;white-space:nowrap!important}
  #recipeForm .multi-purchase-footer .purchase-grand-total{gap:5px!important;flex-wrap:nowrap!important}
  #recipeForm .multi-purchase-footer .purchase-grand-total span{font-size:9px!important}
  #recipeForm .multi-purchase-footer .purchase-grand-total strong{font-size:14px!important}
  .invoice-card-grid{gap:10px!important}
  .purchase-invoice-card{padding:12px!important;border-radius:16px!important}
  .invoice-card-head{gap:8px!important;padding-bottom:9px!important}
  .invoice-card-head h3{font-size:16px!important;line-height:1.3!important}
  .invoice-card-head>strong{font-size:11px!important;padding:5px 7px!important}
  .invoice-line{gap:8px!important;padding:8px 9px!important}
  .invoice-line b{font-size:11px!important;white-space:normal!important;overflow:visible!important;text-overflow:clip!important;line-height:1.25!important}
  .invoice-line>strong{font-size:11px!important}
}

@media(max-width:380px){
  .recipe-line{grid-template-columns:minmax(0,1fr) 86px 32px!important;gap:5px!important;padding:7px!important}
  .recipe-line .remove-purchase-row{width:32px!important;min-width:32px!important}
  #recipeForm .multi-purchase-footer .btn{font-size:10px!important}
  #recipeForm .multi-purchase-footer .purchase-grand-total span{display:none}
}

/* v2.31 clean app-shell + recipe feedback */
.app-nav-busy body{cursor:progress}.is-saving{pointer-events:none;opacity:.78}.recipe-auto-footer{align-items:center!important}.recipe-auto-hint{font-size:11px;line-height:1.35;color:var(--muted);max-width:58%}.recipe-form-error{margin:6px 0 10px;padding:10px 12px;border-radius:12px;background:#fff0ef;border:1px solid #efc7c2;color:#8b2d24;font-size:12px;font-weight:650}.purchase-grand-total strong.is-complete{color:var(--brand)}
@media(max-width:560px){.recipe-auto-footer{display:flex!important;justify-content:space-between!important;gap:8px!important}.recipe-auto-hint{max-width:54%;font-size:9.5px}.recipe-auto-footer .purchase-grand-total{margin-left:auto!important}}

/* ===== v2.31 clean static UI: no decorative motion ===== */
html{scroll-behavior:auto!important}
*,*::before,*::after{animation:none!important;transition:none!important}
.motion-enter,.motion-reveal,.motion-in{opacity:1!important;transform:none!important}
.qf-ripple{display:none!important}
.stat-card:hover,.panel:hover,.purchase-invoice-card:hover,.recent-invoice-card:hover,
.quick-grid a:hover,.quick-cards a:hover,.three-link-grid a:hover,.stock-link-grid a:hover,.link-list a:hover,
.dashboard-kpi-sections .kpi-section:hover,.quick-add-floating:hover,
.btn:active,.quick-add:active,.menu-btn:active,.drawer-close:active,.close-btn:active,.record-view-close:active,
.history-view-more:active,.smart-select-button:active,.smart-select-option:active,
.stat-card:active,.purchase-invoice-card:active,.recent-invoice-card:active,.quick-grid a:active,.stock-link-grid a:active,
.form-grid input:focus,.form-grid textarea:focus,.filter-row input:focus,.simulator input:focus,.smart-select-button[aria-expanded="true"]{transform:none!important}
.quick-add-floating:active{transform:none!important}
/* v2.32 recipe decimal/100kg input helper */
.recipe-qty-help{display:block;margin-top:4px;color:var(--muted);font-size:10px;line-height:1.2;font-weight:500}
@media(max-width:560px){.recipe-qty-help{font-size:9px;margin-top:3px}}

/* ===== v2.33 focused app-like motion ===== */
/* Only the requested transitions are enabled; all other UI remains clean/static. */
.page-wrap{
  opacity:1;
  transform:translate3d(0,0,0);
  transition:opacity .16s ease,transform .18s cubic-bezier(.22,.61,.36,1)!important;
  will-change:opacity,transform;
}
.page-wrap.qf-page-leave{opacity:0!important;transform:translate3d(-8px,0,0)!important}
.page-wrap.qf-page-enter{opacity:0!important;transform:translate3d(10px,0,0)!important}

#quickModal.modal{
  display:block!important;
  visibility:hidden;
  pointer-events:none;
  opacity:0;
  transition:opacity .22s ease,visibility 0s linear .28s!important;
}
#quickModal.modal .modal-backdrop{opacity:0;transition:opacity .24s ease!important}
#quickModal.modal .sheet{
  opacity:0;
  transform:translate(-50%,-48%) scale(.985);
  transition:transform .28s cubic-bezier(.22,.61,.36,1),opacity .2s ease!important;
  will-change:transform,opacity;
}
#quickModal.modal.open{
  visibility:visible;
  pointer-events:auto;
  opacity:1;
  transition:opacity .22s ease!important;
}
#quickModal.modal.open .modal-backdrop{opacity:1}
#quickModal.modal.open .sheet{opacity:1;transform:translate(-50%,-50%) scale(1)}

@media(max-width:900px){
  .sidebar{
    transition:transform .3s cubic-bezier(.22,.61,.36,1)!important;
    will-change:transform;
  }
  .drawer-backdrop{
    display:block!important;
    visibility:hidden;
    pointer-events:none;
    opacity:0;
    background:rgba(7,25,19,.58);
    position:fixed;inset:0;z-index:70;
    transition:opacity .25s ease,visibility 0s linear .3s!important;
  }
  .drawer-backdrop.show{
    visibility:visible;
    pointer-events:auto;
    opacity:1;
    transition:opacity .25s ease!important;
  }
  body.drawer-closing .sidebar{transform:translateX(-105%)!important}

  #quickModal.modal .sheet{
    left:0;right:0;top:auto;bottom:0;width:100%;
    opacity:1;
    transform:translate3d(0,105%,0);
    border-radius:28px 28px 0 0;
    transition:transform .32s cubic-bezier(.2,.78,.24,1)!important;
    will-change:transform;
  }
  #quickModal.modal.open .sheet{transform:translate3d(0,0,0)!important}
  #quickModal.modal.closing .sheet{transform:translate3d(0,105%,0)!important}
  #quickModal.modal.open .modal-backdrop{opacity:1}
  body.quick-open{overflow:hidden}

  .page-wrap{transition:opacity .16s ease,transform .24s cubic-bezier(.22,.61,.36,1)!important}
  .page-wrap.qf-page-leave{opacity:0!important;transform:translate3d(-16px,0,0)!important}
  .page-wrap.qf-page-enter{opacity:0!important;transform:translate3d(18px,0,0)!important}
}

@media(prefers-reduced-motion:reduce){
  .page-wrap,.sidebar,.drawer-backdrop,#quickModal.modal,#quickModal.modal .modal-backdrop,#quickModal.modal .sheet{transition:none!important}
  .page-wrap.qf-page-leave,.page-wrap.qf-page-enter{opacity:1!important;transform:none!important}
}

/* v2.34 — stock table emphasis */
.stock-current-head,
.stock-current-cell{
  background:rgba(29,122,82,.075)!important;
}
.stock-value-head,
.stock-value-cell{
  background:rgba(184,134,11,.10)!important;
}
.stock-current-head,
.stock-value-head{
  font-weight:800!important;
  white-space:nowrap;
}
.stock-current-cell{
  color:#135d43;
  font-weight:750;
}
.stock-value-cell{
  color:#7a5600;
  font-weight:800;
}
.stock-current-cell .stock-pill{
  background:rgba(29,122,82,.12)!important;
  border-color:rgba(29,122,82,.18)!important;
}
@media(max-width:700px){
  .stock-current-head,.stock-current-cell,.stock-value-head,.stock-value-cell{
    box-shadow:inset 2px 0 0 rgba(0,0,0,.035);
  }
}

/* ===== v2.35 purchase auto-row, recipe capacity and mobile-only header motion ===== */
.purchase-auto-actions{align-items:center}
.purchase-auto-hint{max-width:62%;font-size:11px;line-height:1.35;color:var(--muted);font-weight:600}

.recipe-capacity-panel{overflow:hidden}
.recipe-capacity-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:10px}
.recipe-capacity-card{display:grid;gap:10px;border:1px solid var(--line);background:var(--surface-2);border-radius:16px;padding:13px;min-width:0}
.recipe-capacity-card.can-make{border-color:rgba(29,122,82,.24);background:rgba(29,122,82,.045)}
.recipe-capacity-card.cannot-make{border-color:rgba(163,70,56,.18);background:rgba(163,70,56,.035)}
.recipe-capacity-head{display:flex;justify-content:space-between;gap:10px;align-items:flex-start;min-width:0}
.recipe-capacity-head>div{min-width:0}.recipe-capacity-head span{display:block;font-size:9px;color:var(--muted);font-weight:750;text-transform:uppercase;letter-spacing:.04em}
.recipe-capacity-head h3{margin:2px 0 0;font-size:15px;line-height:1.25;overflow-wrap:anywhere}.recipe-capacity-head small{flex:0 0 auto;font-size:9px;color:var(--muted);background:#fff;border:1px solid var(--line);border-radius:999px;padding:4px 7px}
.recipe-capacity-card>strong{font-size:23px;line-height:1.1;color:var(--brand)}
.recipe-capacity-card.cannot-make>strong{color:#8b4b41}
.recipe-capacity-limit{display:grid;gap:2px;border-top:1px solid var(--line);padding-top:9px}.recipe-capacity-limit span{font-size:9px;color:var(--muted)}.recipe-capacity-limit b{font-size:12px}.recipe-capacity-limit small{font-size:10px;line-height:1.3;color:var(--muted)}

/* Desktop/tablet-wide view stays fully static. */
@media(min-width:901px){
  .page-wrap,.page-wrap.qf-page-leave,.page-wrap.qf-page-enter,
  #quickModal.modal,#quickModal.modal .modal-backdrop,#quickModal.modal .sheet,
  .topbar-center,.topbar-center .eyebrow,.topbar-center h1{animation:none!important;transition:none!important}
  .page-wrap,.page-wrap.qf-page-leave,.page-wrap.qf-page-enter,.topbar-center,.topbar-center .eyebrow,.topbar-center h1{transform:none!important}
  .page-wrap.qf-page-leave,.page-wrap.qf-page-enter{opacity:1!important}
  #quickModal.modal .sheet,#quickModal.modal.open .sheet{transform:translate(-50%,-50%)!important}
}

/* Motion is deliberately limited to mobile navigation/header only. */
@keyframes qfHeaderMetaIn{from{opacity:0;transform:translate3d(10px,-2px,0)}to{opacity:1;transform:translate3d(0,0,0)}}
@keyframes qfHeaderTitleIn{from{opacity:0;transform:translate3d(14px,0,0)}to{opacity:1;transform:translate3d(0,0,0)}}
@media(max-width:900px){
  .topbar-center .eyebrow{animation:qfHeaderMetaIn .28s ease-out both!important}
  .topbar-center h1{animation:qfHeaderTitleIn .34s cubic-bezier(.22,.61,.36,1) .035s both!important}
}
@media(max-width:680px){
  .purchase-auto-actions{display:flex!important;flex-direction:row!important;justify-content:space-between!important;gap:8px!important}
  .purchase-auto-hint{max-width:57%;font-size:9.5px;line-height:1.3}
  .purchase-auto-actions .purchase-grand-total{margin-left:auto;min-width:116px;text-align:right!important;padding:8px 10px!important}
  .recipe-capacity-grid{grid-template-columns:1fr}
  .recipe-capacity-card{padding:11px 12px}.recipe-capacity-card>strong{font-size:20px}
}
@media(prefers-reduced-motion:reduce){
  .topbar-center .eyebrow,.topbar-center h1{animation:none!important}
}


/* ===== v2.36 clean top recipe-capacity dashboard ===== */
.recipe-capacity-panel{margin-bottom:14px!important;padding:15px!important;background:var(--surface)!important;border:1px solid var(--line)!important;box-shadow:none!important}
.recipe-capacity-top{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;margin-bottom:12px}
.recipe-capacity-top h2{margin:0;font-size:17px;line-height:1.25;color:var(--text)}
.recipe-capacity-top p{margin:4px 0 0;font-size:11px;line-height:1.4;color:var(--muted)}
.recipe-capacity-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:9px}
.recipe-capacity-card,.recipe-capacity-card.can-make,.recipe-capacity-card.cannot-make{gap:8px;padding:12px;border:1px solid var(--line);border-radius:14px;background:var(--surface-2);box-shadow:none}
.recipe-capacity-card.can-make{border-color:rgba(29,122,82,.19)}
.recipe-capacity-card.cannot-make{border-color:rgba(163,70,56,.16)}
.recipe-capacity-head{display:flex;align-items:center;justify-content:space-between;gap:10px}
.recipe-capacity-head h3{margin:0;font-size:14px;line-height:1.3;font-weight:700;min-width:0;overflow-wrap:anywhere}
.recipe-capacity-head small{font-size:9px;color:var(--muted);background:transparent;border:0;border-radius:0;padding:0;white-space:nowrap}
.recipe-capacity-output{display:flex;align-items:baseline;gap:5px;min-width:0}
.recipe-capacity-output strong{font-size:23px;line-height:1;color:var(--brand);font-weight:700}
.recipe-capacity-card.cannot-make .recipe-capacity-output strong{color:#8b4b41}
.recipe-capacity-output span{font-size:11px;color:var(--muted);font-weight:600}
.recipe-capacity-limit{display:flex;align-items:center;gap:5px;flex-wrap:wrap;border-top:1px solid var(--line);padding-top:8px}
.recipe-capacity-limit span{font-size:9px;color:var(--muted)}
.recipe-capacity-limit b{font-size:11px;color:var(--text)}
.recipe-capacity-limit small{width:100%;font-size:9.5px;line-height:1.35;color:var(--muted)}
@media(max-width:700px){
  .recipe-capacity-panel{padding:12px!important;margin-bottom:11px!important}
  .recipe-capacity-top{align-items:center;margin-bottom:10px}
  .recipe-capacity-top h2{font-size:15px}
  .recipe-capacity-top p{font-size:10px}
  .recipe-capacity-grid{grid-template-columns:1fr;gap:7px}
  .recipe-capacity-card,.recipe-capacity-card.can-make,.recipe-capacity-card.cannot-make{padding:10px 11px;border-radius:12px}
  .recipe-capacity-output strong{font-size:20px}
}


/* ===== v2.37 focused capacity neon + quick-action icons ===== */
@property --qf-capacity-angle{
  syntax:"<angle>";
  inherits:false;
  initial-value:0deg;
}
.recipe-capacity-panel{
  position:relative;
  isolation:isolate;
  border-color:rgba(31,207,151,.32)!important;
  overflow:hidden;
}
.recipe-capacity-panel::before{
  content:"";
  position:absolute;
  inset:-1px;
  z-index:3;
  pointer-events:none;
  border-radius:inherit;
  padding:1px;
  background:conic-gradient(from var(--qf-capacity-angle),
    rgba(54,255,193,0) 0deg,
    rgba(54,255,193,.08) 205deg,
    rgba(64,255,198,.95) 256deg,
    rgba(228,190,104,.86) 286deg,
    rgba(54,255,193,.10) 318deg,
    rgba(54,255,193,0) 360deg);
  -webkit-mask:linear-gradient(#000 0 0) content-box,linear-gradient(#000 0 0);
  -webkit-mask-composite:xor;
  mask-composite:exclude;
}
.recipe-capacity-panel>.recipe-capacity-grid,
.recipe-capacity-panel>.table-empty{position:relative;z-index:1}

.quick-grid a{
  grid-template-columns:38px minmax(0,1fr);
  align-items:center;
  column-gap:11px;
}
.quick-grid a>div{display:grid;min-width:0}
.quick-action-icon{
  width:38px;
  height:38px;
  border-radius:12px;
  display:grid;
  place-items:center;
  background:var(--brand-soft);
  color:var(--brand);
  border:1px solid rgba(23,63,50,.08);
  font-style:normal;
  flex:0 0 auto;
}
.quick-action-icon .ui-icon{width:18px;height:18px}

/* Preserve the existing rule: decorative motion is mobile-only. */
@media(max-width:900px){
  @keyframes qfCapacityNeonOrbit{to{--qf-capacity-angle:360deg}}
  .recipe-capacity-panel::before{animation:qfCapacityNeonOrbit 4.2s linear infinite}
}
@media(min-width:901px){
  .recipe-capacity-panel::before{animation:none!important;--qf-capacity-angle:278deg}
}
@media(max-width:420px){
  .quick-grid a{grid-template-columns:34px minmax(0,1fr);column-gap:9px;padding:11px}
  .quick-action-icon{width:34px;height:34px;border-radius:10px}
  .quick-action-icon .ui-icon{width:16px;height:16px}
}
@media(prefers-reduced-motion:reduce){
  .recipe-capacity-panel::before{animation:none!important}
}


/* ===== v2.38 capacity cards only neon wrapper ===== */
.recipe-capacity-panel{
  padding:0!important;
  background:transparent!important;
  border:0!important;
  box-shadow:none!important;
  overflow:visible!important;
}
.recipe-capacity-panel::before{display:none!important;content:none!important}
.recipe-capacity-grid{gap:10px}
.recipe-capacity-card,
.recipe-capacity-card.can-make,
.recipe-capacity-card.cannot-make{
  position:relative;
  isolation:isolate;
  overflow:hidden;
  background:var(--surface)!important;
  border:1px solid rgba(31,207,151,.22)!important;
  border-radius:18px;
  padding:14px;
  box-shadow:none!important;
}
.recipe-capacity-card::before{
  content:"";
  position:absolute;
  inset:-1px;
  z-index:0;
  pointer-events:none;
  border-radius:inherit;
  padding:1px;
  background:conic-gradient(from var(--qf-capacity-angle),
    rgba(54,255,193,0) 0deg,
    rgba(54,255,193,.05) 208deg,
    rgba(64,255,198,.92) 258deg,
    rgba(228,190,104,.82) 286deg,
    rgba(54,255,193,.08) 318deg,
    rgba(54,255,193,0) 360deg);
  -webkit-mask:linear-gradient(#000 0 0) content-box,linear-gradient(#000 0 0);
  -webkit-mask-composite:xor;
  mask-composite:exclude;
}
.recipe-capacity-card > *{position:relative;z-index:1}
.recipe-capacity-card.cannot-make::before{
  background:conic-gradient(from var(--qf-capacity-angle),
    rgba(248,120,91,0) 0deg,
    rgba(248,120,91,.06) 205deg,
    rgba(248,120,91,.88) 258deg,
    rgba(228,190,104,.70) 288deg,
    rgba(248,120,91,.08) 318deg,
    rgba(248,120,91,0) 360deg);
}
@media(max-width:900px){
  .recipe-capacity-card::before{animation:qfCapacityNeonOrbit 4.2s linear infinite}
}
@media(min-width:901px){
  .recipe-capacity-card::before{animation:none!important;--qf-capacity-angle:278deg}
}
@media(max-width:640px){
  .recipe-capacity-card,
  .recipe-capacity-card.can-make,
  .recipe-capacity-card.cannot-make{padding:12px;border-radius:16px}
}
@media(prefers-reduced-motion:reduce){
  .recipe-capacity-card::before{animation:none!important}
}


/* ===== v2.40 capacity cards standard border ===== */
.recipe-capacity-panel{
  padding:0!important;
  background:transparent!important;
  border:0!important;
  box-shadow:none!important;
  overflow:visible!important;
}
.recipe-capacity-panel::before,
.recipe-capacity-card::before,
.recipe-capacity-card.can-make::before,
.recipe-capacity-card.cannot-make::before{
  display:none!important;
  content:none!important;
  animation:none!important;
}
.recipe-capacity-card,
.recipe-capacity-card.can-make,
.recipe-capacity-card.cannot-make{
  position:relative;
  overflow:hidden;
  background:var(--surface-2)!important;
  border:1px solid var(--line)!important;
  border-radius:14px!important;
  box-shadow:none!important;
}

/* ===== v2.41 compact egg entry forms + price history chart ===== */
.egg-mobile-form{display:grid;gap:12px}
.egg-inline-row{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.egg-placeholder-field,.egg-date-field{display:grid;gap:6px;color:#5f6e65;font-size:12px;font-weight:750;min-width:0}
.egg-placeholder-field input,.egg-date-field input{width:100%;min-width:0;border:1px solid var(--line);background:#fbfcfa;color:var(--ink);border-radius:13px;padding:11px 12px;outline:none}
.egg-placeholder-field input:focus,.egg-date-field input:focus{border-color:#84a393;box-shadow:0 0 0 4px rgba(31,98,73,.06)}
.egg-damage-toggle{width:100%;border:0;background:transparent;color:var(--brand);display:flex;align-items:center;justify-content:space-between;padding:5px 2px;font-weight:800;cursor:pointer;text-align:left}
.egg-damage-toggle-icon{font-size:18px;line-height:1;transform:rotate(0deg)}
.egg-damage-toggle.is-open .egg-damage-toggle-icon{transform:rotate(180deg)}
.egg-damage-reveal{display:grid;grid-template-rows:0fr;opacity:0;overflow:hidden}
.egg-damage-reveal>.damage-field{min-height:0;overflow:hidden}
.egg-damage-reveal.is-open{grid-template-rows:1fr;opacity:1}
.egg-save-btn{width:100%}
.egg-buyer-field{width:100%}
.egg-price-chart-panel .trend-chart-wrap{margin-top:4px}

@media(max-width:620px){
  .egg-entry-panel{padding:15px!important}
  .egg-entry-panel h2{font-size:18px;margin-bottom:12px}
  .egg-mobile-form{gap:10px}
  .egg-inline-row{grid-template-columns:minmax(0,1.12fr) minmax(0,.88fr);gap:8px}
  .egg-placeholder-field .field-label{display:none}
  .egg-placeholder-field input{min-height:50px;padding:12px 11px;font-size:16px}
  .egg-placeholder-field input::placeholder{color:#78867e;opacity:1;font-weight:650;font-size:13px}
  .egg-damage-toggle{padding:7px 2px 5px;font-size:13px;border-bottom:1px solid var(--line)}
  .egg-damage-reveal{transition:grid-template-rows .22s ease,opacity .18s ease}
  .egg-damage-toggle-icon{transition:transform .22s ease}
  .egg-date-field{gap:5px;font-size:11px}
  .egg-date-field input{min-height:48px;font-size:16px}
  .egg-save-btn{min-height:49px;margin-top:1px}
  .egg-buyer-field{margin-top:0}
  .egg-price-chart-panel{padding:14px!important}
  .egg-price-chart-panel .panel-top{margin-bottom:8px}
  .egg-price-chart-panel .panel-top h2{font-size:16px}
}
@media(prefers-reduced-motion:reduce){
  .egg-damage-reveal,.egg-damage-toggle-icon{transition:none!important}
}

/* ===== v2.44 Production dashboard, recipe status, multi-feed usage ===== */
.qf-production-hero{background:linear-gradient(120deg,#103b2e 0%,#205745 70%,#356c55 100%);border-radius:22px;padding:24px 26px;color:#fff;display:flex;align-items:center;justify-content:space-between;gap:18px;overflow:hidden;position:relative}
.qf-production-hero:before{content:'';position:absolute;width:240px;height:240px;border:1px solid #ffffff17;border-radius:50%;right:-70px;top:-110px;pointer-events:none}
.qf-production-hero .kicker{color:#b3d9c3}.qf-production-hero h2{font-size:27px;line-height:1.2;margin:5px 0 8px;letter-spacing:-.02em}.qf-production-hero p{margin:0;font-size:13px;color:#d3e7dc;max-width:560px}
.qf-production-hero-stats{display:flex;gap:10px;z-index:1}.qf-production-hero-stats>div{display:grid;gap:1px;background:#ffffff15;border:1px solid #ffffff2b;border-radius:15px;min-width:85px;padding:11px 14px}.qf-production-hero-stats b{font-size:24px;line-height:1.2}.qf-production-hero-stats span{font-size:11px;color:#d3e7dc}
.qf-production-overview{display:grid;gap:13px;margin-top:20px;margin-bottom:20px}.qf-section-heading{display:flex;align-items:end;justify-content:space-between;gap:12px}.qf-section-heading h3{margin:3px 0 0;font-size:19px}.qf-section-heading .kicker{color:var(--muted)}
.qf-recipe-overview-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}
.qf-recipe-overview-card{display:grid;grid-template-rows:auto auto 1fr auto auto;gap:14px;background:var(--surface);border:1px solid var(--line);border-radius:19px;padding:17px;transition:transform .16s ease,border-color .16s ease,box-shadow .16s ease;min-width:0;cursor:pointer;box-shadow:0 4px 15px rgba(12,49,32,.03)}
.qf-recipe-overview-card:hover,.qf-recipe-overview-card:focus-visible{transform:translateY(-2px);border-color:#85b09a;box-shadow:0 12px 32px rgba(10,56,31,.1);outline:none}
.qf-recipe-overview-card.is-selected{border-color:#2f765b;box-shadow:0 0 0 3px #2f765b16}
.qf-recipe-overview-card.is-inactive{background:#f5f7f5;color:#586b60}.qf-recipe-overview-card h3{margin:0;font-size:16px;line-height:1.4;min-height:42px;overflow-wrap:anywhere}
.qf-overview-top{display:flex;align-items:center;justify-content:space-between;gap:10px}.qf-recipe-icon{width:42px;height:42px;border-radius:13px;background:var(--brand-soft);color:var(--brand-2);display:grid;place-items:center}.qf-recipe-icon .ui-icon{width:23px;height:23px}
.qf-status-pill{border-radius:100px;padding:5px 10px;display:inline-flex;align-items:center;font-size:11px;line-height:1.35;font-weight:800;white-space:nowrap}.qf-status-pill.is-active{background:#e8f5ec;color:#286343}.qf-status-pill.is-inactive{background:#e8ebe9;color:#66766e}
.qf-overview-metric{background:#f3f7f3;border-radius:14px;padding:13px;display:grid;gap:4px;align-content:center}.qf-overview-metric span{font-size:11px;color:#65776c}.qf-overview-metric strong{font-size:30px;letter-spacing:-.03em;line-height:1.25;color:#173f32;font-variant-numeric:tabular-nums}.qf-overview-metric strong small{font-size:12px;color:#698076;font-weight:750;letter-spacing:normal}.is-inactive .qf-overview-metric{background:#ecefec}.is-inactive .qf-overview-metric strong{color:#6c7a70}
.qf-overview-bottom{border-top:1px solid var(--line);padding-top:12px;display:flex;align-items:center;justify-content:space-between;gap:8px;color:var(--muted);font-size:11px}.qf-overview-arrow{font-size:18px;font-weight:800;color:var(--brand-2)}.qf-card-note{color:var(--brand-2);font-size:11px;min-height:15px}.qf-card-note.is-alert{color:#bc6651}
.qf-capacity-disclaimer{font-size:12px;color:var(--muted);margin:0;line-height:1.6}
.qf-production-editor{scroll-margin-top:100px;max-width:1100px}.qf-editor-subtitle{font-size:13px;color:var(--muted);margin:5px 0 0}.qf-editor-quick{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:11px 14px;background:var(--brand-soft);border:1px solid #cfe2d6;border-radius:13px;font-size:12px;color:#315641}.qf-editor-quick b{font-size:14px;color:#164c35}
.qf-recipe-head-tags{display:flex;align-items:center;flex-wrap:wrap;justify-content:flex-end;gap:8px}.qf-recipe-card-actions{flex-wrap:wrap;gap:8px}.qf-inactive-recipe{opacity:.8}.qf-recipe-card-actions form{margin:0}
.qf-usage-panel{max-width:1150px}.qf-usage-form{display:grid;gap:16px}.qf-usage-dates{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.qf-usage-dates label{display:grid;gap:6px;color:var(--muted);font-size:12px;font-weight:750}.qf-usage-dates input{padding:12px;border:1px solid var(--line);border-radius:12px;min-width:0;background:#fbfcfa;color:var(--ink);width:100%}
.qf-usage-lines-title{display:flex;align-items:end;justify-content:space-between;border-bottom:1px solid var(--line);padding-bottom:8px}.qf-usage-lines-title b{font-size:14px}.qf-usage-lines-title span{font-size:11px;color:var(--muted)}.qf-usage-rows{display:grid;gap:11px}.qf-usage-row{display:grid;grid-template-columns:minmax(0,1.6fr) minmax(150px,.8fr) 36px;align-items:end;gap:10px;background:var(--surface-2);border:1px solid var(--line);border-radius:16px;padding:13px;position:relative}
.qf-usage-row label{display:grid;gap:6px;min-width:0;font-size:12px;font-weight:750;color:#64756a}.qf-usage-row input,.qf-usage-row select{min-width:0;width:100%;background:white;border:1px solid var(--line);border-radius:12px;padding:11px;color:var(--ink);height:45px}
.qf-usage-remove{width:36px;height:36px;background:#feefed;color:#bd4c44;border:0;border-radius:10px;font-size:22px;line-height:1;cursor:pointer;margin-bottom:4px}.qf-usage-row:only-child .qf-usage-remove{opacity:.35;cursor:default}
.qf-usage-stock-label{grid-column:1/-1;font-size:11px;color:#567362;min-height:12px}.qf-usage-stock-label.is-alert{color:var(--danger);font-weight:750}.qf-usage-toolbar{display:flex;align-items:center;justify-content:space-between;gap:15px;flex-wrap:wrap}.qf-usage-totals{display:flex;gap:20px;color:var(--muted);font-size:12px}.qf-usage-totals strong{color:var(--brand);font-size:15px}.qf-form-error{background:#fff2ed;border:1px solid #f2cac0;border-radius:12px;color:#a94a3f;padding:10px 13px;font-size:12px}.qf-form-error[hidden]{display:none}.qf-usage-submit{justify-self:end;min-width:245px}
@media(max-width:1100px){.qf-recipe-overview-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:640px){.qf-production-hero{border-radius:18px;padding:18px;align-items:stretch;flex-direction:column}.qf-production-hero h2{font-size:23px}.qf-production-hero-stats>div{min-width:0;flex:1}.qf-production-hero-stats b{font-size:20px}.qf-recipe-overview-grid{grid-template-columns:1fr;gap:10px}.qf-recipe-overview-card{grid-template-columns:1fr;gap:10px;padding:14px}.qf-recipe-overview-card h3{min-height:0}.qf-overview-metric strong{font-size:27px}.qf-section-heading h3{font-size:17px}.qf-section-heading .btn{font-size:11px}.qf-editor-quick{align-items:flex-start;flex-direction:column}.qf-usage-dates{grid-template-columns:1fr 1fr;gap:8px}.qf-usage-dates input{font-size:13px;padding:11px 8px}.qf-usage-row{grid-template-columns:minmax(0,1fr) 36px;gap:8px;padding:11px}.qf-usage-item-label{grid-column:1/-1}.qf-usage-amount-label{grid-column:1}.qf-usage-remove{grid-column:2}.qf-usage-stock-label{grid-column:1/-1}.qf-usage-totals{justify-content:space-between;width:100%}.qf-usage-toolbar .btn{width:100%}.qf-usage-submit{width:100%;min-width:0}}

/* v2.45: compact recipe listing / separate batch & production history */
.qf-recipe-summary{display:flex;justify-content:space-between;align-items:center;gap:18px;flex-wrap:wrap;margin-bottom:16px;padding:21px 24px;background:linear-gradient(112deg,#f2f8f4,#fff);border:1px solid #e0eae1;border-radius:20px}
.qf-recipe-summary h2{font-size:23px;margin:5px 0}.qf-recipe-summary p{font-size:12px;margin:5px 0 0;color:var(--muted);max-width:600px}
.qf-recipe-summary-actions{display:flex;flex-wrap:wrap;align-items:center;gap:12px}.qf-recipe-count{font-size:12px;font-weight:700;color:#466b57}
.qf-recipe-table-panel{padding:6px 16px 12px}.qf-recipe-table{width:100%;min-width:680px}.qf-recipe-table td{vertical-align:middle;padding-top:13px;padding-bottom:13px}.qf-recipe-table th{font-size:12px}.qf-recipe-name-cell a{color:inherit;text-decoration:none}.qf-recipe-name-cell a:hover{color:var(--brand-2)}.qf-recipe-name-cell b{font-size:14px}
.qf-recipe-actions{display:flex;align-items:center;gap:6px;white-space:nowrap}.qf-recipe-actions .inline-form{display:inline-flex;margin:0}.qf-action-btn{border:1px solid transparent;border-radius:9px;padding:7px 9px;font:inherit;font-size:11px;font-weight:700;line-height:1.25;text-decoration:none;cursor:pointer;white-space:nowrap;display:inline-flex;align-items:center;justify-content:center;transition:background .18s ease,transform .18s ease}.qf-action-btn:hover{transform:translateY(-1px)}
.qf-action-view{color:#17604b;background:#e9f4ed;border-color:#cbe5d4}.qf-action-edit{color:#315a89;background:#ecf2fb;border-color:#d6e4f6}.qf-action-delete{color:#a33333;background:#fff0f0;border-color:#f7d8d8}.qf-action-inactive{color:#965d17;background:#fff7e8;border-color:#f1e1bf}.qf-action-active{color:#0c694a;background:#e8f7ec;border-color:#c5e6cc}
.qf-recipe-price-hint{font-size:11px;color:var(--muted);margin:10px 8px 0}.qf-page-links{display:flex;align-items:center;gap:16px;flex-wrap:wrap;margin:0 0 15px}.qf-page-links a{color:var(--brand-2);font-size:13px;font-weight:700;text-decoration:none}.qf-page-links a:hover{text-decoration:underline}
.qf-recipe-detail-stats{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin:19px 0}.qf-recipe-detail-stats>div{padding:16px;border:1px solid var(--line);border-radius:14px;background:#f8faf8;display:grid;gap:4px}.qf-recipe-detail-stats span{font-size:12px;color:var(--muted)}.qf-recipe-detail-stats strong{font-size:21px;color:#164d39}.qf-recipe-detail-table{min-width:740px}.qf-recipe-detail-table td{vertical-align:middle}.qf-recipe-detail-table td small{display:block;font-size:10px;color:var(--muted);margin-top:2px}.qf-recipe-detail-table tfoot{background:#f2f8f4}.qf-recipe-detail-table tfoot th{font-weight:800}.qf-detail-actions{display:flex;gap:10px;flex-wrap:wrap;margin-top:19px}.qf-muted-copy{font-size:12px;color:var(--muted);margin:5px 0}
.qf-production-editor-only{margin-top:0}.qf-selected-recipe-input{display:flex;align-items:center;min-height:44px;padding:11px 13px;background:#f0f7f3;border:1px solid #cfe2d6;border-radius:11px;font-size:13px;font-weight:700;color:#205d44}.qf-heading-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.qf-production-overview{margin-top:16px}.qf-recipe-overview-card{grid-template-rows:auto auto 1fr auto auto}
@media(max-width:780px){.qf-recipe-summary{padding:16px}.qf-recipe-table-panel{padding:8px 10px}.qf-recipe-table-wrap{overflow-x:auto;-webkit-overflow-scrolling:touch}.qf-recipe-detail-stats{gap:7px}.qf-recipe-detail-stats>div{padding:11px}.qf-recipe-detail-stats strong{font-size:15px}.qf-heading-actions .btn{font-size:10px;padding:8px 10px}}
@media(max-width:440px){.qf-recipe-summary h2{font-size:21px}.qf-recipe-summary-actions{width:100%;justify-content:space-between}.qf-detail-actions .btn{width:100%}.qf-recipe-detail-stats span{font-size:10px}.qf-recipe-detail-stats strong{font-size:13px}}

/* v2.47 live ingredient deficit and ready-feed stock runway */
.production-calc-table .production-shortage-cell{white-space:nowrap;font-variant-numeric:tabular-nums}
.production-shortage-cell .is-short,#productionTotalShortage.is-short{color:#ba4439;font-weight:800}
.production-shortage-cell .is-ok{color:#21845c;font-weight:800}
.production-shortage-summary{margin-top:11px;padding:12px 14px;border:1px solid #dce7de;background:#f3f8f4;color:#275443;border-radius:12px;font-size:12px;font-weight:700;line-height:1.65;overflow-wrap:anywhere}
.production-shortage-summary.is-short{color:#9c3d31;border-color:#f1d4ce;background:#fff2ef}
.production-shortage-summary.is-ok{color:#1d7650;border-color:#d1eadb;background:#edf9f2}
.qf-production-stock-note{font-size:10px;color:var(--muted);margin:8px 2px 0}
.production-calc-table{min-width:840px}
.dashboard-kpis .stat-card.ready-runway-soon{background:linear-gradient(140deg,#fff,#fffaed);border-color:#f0dea9}
.dashboard-kpis .stat-card.ready-runway-soon strong{color:#965d16}
.qf-ready-forecast{padding:16px!important;margin-bottom:15px!important}
.qf-ready-forecast .panel-top{align-items:flex-start;flex-wrap:wrap;gap:10px}
.qf-ready-forecast .panel-top h2{margin:2px 0 4px;font-size:17px}
.qf-forecast-caption,.qf-forecast-footnote{font-size:11px;color:var(--muted);line-height:1.6;margin:0;max-width:950px}
.qf-forecast-overview{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:9px;margin:11px 0 14px}
.qf-forecast-overview>div{background:var(--surface-2);border:1px solid var(--line);padding:11px;border-radius:12px;min-width:0;display:grid;gap:4px}
.qf-forecast-overview span{font-size:10px;color:var(--muted)}
.qf-forecast-overview strong{font-size:15px;line-height:1.4;overflow-wrap:anywhere}
.qf-forecast-table{min-width:820px}
.qf-forecast-table td,.qf-forecast-table th{white-space:normal;min-width:90px}
.qf-forecast-table td:first-child{min-width:150px;max-width:240px;overflow-wrap:anywhere}
.qf-forecast-table .qf-forecast-muted{display:block;color:var(--muted);font-size:10px;margin-top:3px}
.qf-forecast-status{display:inline-flex;padding:4px 8px;border-radius:20px;font-size:10px;font-weight:800;white-space:nowrap;background:#ecf6ef;color:#187449}
.qf-forecast-status.is-empty,.qf-forecast-status.is-urgent{background:#fff0ed;color:#a53e33}
.qf-forecast-status.is-plan{background:#fff7e3;color:#955e17}
.qf-forecast-status.is-no_data{background:#f0f2f0;color:#65766d}
.qf-forecast-footnote{margin-top:12px}
@media(max-width:600px){.qf-forecast-overview{grid-template-columns:1fr 1fr}.qf-forecast-overview>div:last-child{grid-column:1/-1}.qf-ready-forecast{padding:12px!important}}

/* v2.48: compact aggregate stock forecast, above dashboard KPIs */
.qf-forecast-simple{grid-template-columns:repeat(4,minmax(0,1fr));margin-bottom:10px}
.qf-forecast-simple .qf-forecast-highlight{background:var(--surface-2);border-color:var(--line)}
.qf-forecast-simple .qf-forecast-highlight strong{font-size:19px}
@media(max-width:720px){.qf-forecast-simple{grid-template-columns:repeat(2,minmax(0,1fr))}.qf-forecast-simple>div:last-child{grid-column:auto}}
