.overdue-order-overlay{position:fixed;inset:0;z-index:10000;background:#08172ad9;overflow:auto;padding:16px}.overdue-order-overlay[hidden]{display:none}.overdue-order-panel{max-width:1000px;margin:auto;background:#f3f7fc;border-radius:18px;padding:18px;color:#102542}.overdue-order-panel>header,.overdue-order-head,.overdue-order-tools,.overdue-order-actions{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}.overdue-order-panel button{padding:10px 14px;border:1px solid #bed1e8;border-radius:9px;cursor:pointer}.overdue-order-panel button.primary{background:#1267df;color:white}.overdue-order-tools input{flex:1;min-width:220px;padding:12px;border:1px solid #bed1e8;border-radius:9px}.overdue-order-card{background:white;border:1px solid #d2e0f0;border-radius:15px;padding:16px;margin:12px 0}.overdue-order-head h3{margin:0}.overdue-order-head p{color:#627590}.overdue-order-summary{display:flex;gap:20px;flex-wrap:wrap;background:#ebf4ff;padding:12px;border-radius:10px}.overdue-order-invoices>div{display:flex;gap:12px;justify-content:space-between;flex-wrap:wrap;border-top:1px solid #dce7f3;padding:10px 0}.overdue-order-actions{justify-content:flex-start;margin-top:16px}.overdue-order-count{font-weight:bold;margin-top:14px}.overdue-ledger{position:absolute;inset:0;background:#08172add;padding:20px;overflow:auto}.overdue-ledger>section{max-width:850px;margin:auto;background:white;border-radius:14px;padding:20px}.overdue-ledger-rows{max-height:65vh;overflow:auto}.overdue-ledger-rows article{border-bottom:1px solid #ddd;padding:8px}
.overdue-order-manager-note{display:grid;gap:7px;margin-top:14px;padding-top:12px;border-top:1px solid #dce7f3}.overdue-order-manager-note textarea{min-height:70px;padding:9px;border:1px solid #bed1e8;border-radius:8px}.overdue-order-manager-note button{justify-self:start;background:#138066;color:#fff}
.overdue-order-description{overflow-wrap:anywhere;white-space:pre-wrap}

.overdue-order-balance{display:flex;flex-direction:column;gap:6px;max-width:340px}.overdue-balance-discrepancy{display:block;color:#c62828;font-weight:700;font-size:12px;line-height:1.8;overflow-wrap:anywhere}

.order-year-summary{padding:14px;border:1px solid #c8dcec;border-radius:12px;background:#f4f8fd;margin:14px 0}.order-year-summary h4{margin:0 0 8px}.order-year-summary>div{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin:12px 0}.order-year-summary article{display:flex;flex-direction:column;gap:9px;background:white;border:1px solid #d6e3ee;border-radius:10px;padding:14px}.order-year-summary article:first-child strong{color:#087a4a}.order-year-summary article:last-child strong{color:#b44235}.order-year-summary small{line-height:1.9;color:#516880}@media(max-width:480px){.order-year-summary>div{grid-template-columns:1fr}}

/* Compact order follow-up cards; retain typography and touch targets. */
.overdue-order-card{padding:12px;margin:8px 0}.overdue-order-head{gap:8px}.overdue-order-head p{margin:7px 0 10px}.overdue-order-card .overdue-order-summary{padding:9px 10px;gap:12px}.overdue-order-card .control-reasons{padding:10px;margin:0}.overdue-order-card .control-reasons p{margin:6px 0}.overdue-order-card .control-reasons small{display:block;margin-top:6px}.overdue-order-card .order-year-summary{padding:10px;margin:10px 0}.overdue-order-card .order-year-summary h4{margin:0 0 5px}.overdue-order-card .order-year-summary>div{gap:8px;margin:8px 0}.overdue-order-card .order-year-summary article{gap:5px;padding:10px}.overdue-order-card .order-year-summary article strong{display:flex;align-items:baseline;gap:8px;flex-wrap:wrap}.order-return-percent{font:inherit;white-space:nowrap}.overdue-order-card>h4{margin:10px 0 6px}.overdue-order-card .overdue-order-invoices>div{padding:8px 0;gap:8px}.overdue-order-card .overdue-order-actions{margin-top:8px;gap:8px}.overdue-order-card .overdue-order-manager-note{margin-top:8px;padding-top:8px;gap:5px}.overdue-order-card .overdue-order-manager-note textarea{min-height:54px;box-sizing:border-box}.overdue-order-card button{min-height:44px;padding:8px 12px}

.order-control-tabs{display:flex;gap:8px;margin:14px 0}.order-control-tabs button[aria-pressed=true]{background:#175b82;color:white;border-color:#175b82}#orderArchiveFilters{display:grid;grid-template-columns:repeat(4,minmax(120px,1fr));gap:10px;background:#eaf3fb;padding:12px;border-radius:12px}#orderArchiveFilters label{margin:0;font-size:11px}#orderArchiveFilters input,#orderArchiveFilters select{width:100%;padding:9px;margin-top:4px;border:1px solid #b9cede;border-radius:8px;font:inherit;background:white}#orderArchiveFilters>button{grid-column:1/-1;justify-self:start}.order-archive-note{font-size:11px;color:#6b8193;line-height:1.9}.order-archive-warning{background:#fff3d7;color:#8e5d18;padding:10px;border-radius:8px}.archive-order.reviewed{border-right:4px solid #1e9d75}.archive-order.unreviewed{border-right:4px solid #dba342}.archive-order details{background:#f4f8fc;padding:12px;border-radius:9px;margin:10px 0}.archive-order summary{cursor:pointer;font-weight:700}@media(max-width:650px){#orderArchiveFilters{grid-template-columns:repeat(2,minmax(0,1fr))}.order-control-tabs button{font-size:12px}}

.overdue-order-manager-note .order-note-presets{border:1px solid #cedeed;background:#f5f9ff;border-radius:12px;padding:12px;margin:12px 0}.overdue-order-manager-note .order-note-presets legend{font-weight:bold;color:#17395e;font-size:12px;padding:0 6px}.overdue-order-manager-note .order-note-presets label{display:flex;align-items:flex-start;gap:10px;padding:11px 8px;margin:5px 0;background:white;border-radius:8px;cursor:pointer;line-height:1.9}.overdue-order-manager-note .order-note-presets input[type=checkbox]{width:19px;min-width:19px;height:19px;margin:4px 0 0;accent-color:#1769d2;flex:none}.overdue-order-manager-note .order-note-presets label:has(input:checked){background:#e2efff;color:#123d73}.overdue-order-manager-note .order-note-presets span{min-width:0;overflow-wrap:anywhere}

.calendar-overlay.order-control-calendar{position:fixed!important;inset:0!important;z-index:20000!important;display:flex!important;align-items:center!important;justify-content:center!important;overflow:auto!important;margin:0!important;padding:16px!important;box-sizing:border-box;background:#07111ddd!important}.order-control-calendar .persian-calendar{margin:auto;max-height:calc(100dvh - 32px);overflow:auto;box-sizing:border-box}.order-archive-date-hint{color:#265c90;font-size:12px;line-height:1.8}.order-archive-date-hint[hidden]{display:none}#orderControlScope{padding:12px;background:#eaf2fc;border-radius:10px;line-height:1.9}
.archive-bulk-actions{display:grid;grid-template-columns:auto 1fr;gap:10px;align-items:center;background:#eff7ff;border:1px solid #b8d5ef;border-radius:11px;padding:12px;margin:10px 0}.archive-bulk-actions label{font-weight:700}.archive-bulk-actions input{width:19px;height:19px;vertical-align:middle}.archive-bulk-actions b{color:#175b82}.archive-bulk-actions div{grid-column:1/-1;display:flex;flex-wrap:wrap;gap:8px}.archive-bulk-actions button{border:0;border-radius:8px;padding:9px 12px;background:#1769d2;color:#fff;font:inherit;font-weight:700}.archive-bulk-actions button.danger{background:#b33e37}.archive-bulk-actions button:disabled{opacity:.5}.archive-bulk-actions small{grid-column:1/-1;color:#526b80}.archive-order-select{white-space:nowrap;font-size:12px}.archive-order-select input{width:18px;height:18px;vertical-align:middle}@media(max-width:650px){.archive-bulk-actions{grid-template-columns:1fr}.archive-bulk-actions div,.archive-bulk-actions small{grid-column:auto}}

.order-identity-note{padding:9px 12px;border:1px solid #ebca7e;border-radius:8px;background:#fff6df;color:#74520f;font-size:12px;line-height:1.9}
.order-identity-note{overflow-wrap:anywhere}.overdue-order-head>div{min-width:0;max-width:100%}

#orderArchiveFilters[hidden],#orderActiveFilters[hidden]{display:none!important}

