.paid-cost-panel{margin-top:14px;padding:18px;border:1px solid #c8ddf5;border-radius:16px;background:linear-gradient(145deg,#f7fbff,#eef6ff);color:#18314e}
.paid-cost-head{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:14px}
.paid-cost-head .card-title{color:#102c51}
.paid-cost-head .module-subcopy{max-width:670px;margin:5px 0 0;line-height:1.45}
.paid-cost-head button{flex-shrink:0}
.paid-cost-list{display:grid;grid-template-columns:minmax(0,1fr);gap:8px;min-width:0}
.paid-cost-location{min-width:0;max-width:100%;padding:12px 14px;background:#fff;border:1px solid #d8e7f6;border-radius:10px;font-size:13px}
.paid-cost-location-main{display:flex;align-items:center;justify-content:space-between;gap:12px;min-width:0}
.paid-cost-location-main>strong{min-width:120px;color:#173861}
.paid-cost-counts{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:6px;min-width:0}
.paid-cost-counts span{padding:6px 9px;background:#eff6ff;border-radius:999px;color:#315372;white-space:nowrap}
.paid-cost-counts b{color:#153d72;font-variant-numeric:tabular-nums}
.paid-cost-pending{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-end;gap:7px;line-height:1.4;min-width:0}
.paid-cost-pending>span:not(.paid-cost-warning){padding:5px 8px;border-radius:999px;background:#eff6ff;color:#365979}
.paid-cost-warning{color:#87571c;line-height:1.4}
.paid-cost-history{min-width:0;max-width:100%;overflow:hidden;margin-top:9px;border-top:1px solid #e3edf7;padding-top:9px}
.paid-cost-history summary{cursor:pointer;color:#1d5c9b;font-weight:700;outline-offset:3px}
.paid-cost-history p{margin:8px 0;color:#536d86;font-size:12px;line-height:1.45}
.paid-cost-history-scroll{max-width:100%;overflow-x:auto}
.paid-cost-history table{width:100%;border-collapse:collapse;min-width:560px;font-size:12px}
.paid-cost-history th,.paid-cost-history td{padding:8px;text-align:left;border-bottom:1px solid #e5edf6;vertical-align:top}
.paid-cost-history th{color:#375c80;background:#f5f9fd}
.paid-cost-empty{margin:0;color:#526b85}
.paid-cost-foot{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:12px;color:#526b85;font-size:12px;line-height:1.45}
.paid-cost-foot button{flex-shrink:0}
.paid-cost-modal{width:min(640px,calc(100vw - 24px))!important;max-width:640px!important}
.paid-cost-modal .modal-body{overflow-y:auto;max-height:calc(100dvh - 220px)}
.paid-cost-modal .modal-footer{flex-wrap:wrap}
.paid-cost-intro{margin:0 0 16px;padding:12px 14px;border-radius:10px;background:#eef6ff;color:#254e76;font-size:13px;line-height:1.5}
.paid-cost-uncertain{margin:0 0 16px;padding:12px 14px;border-radius:10px;background:#fff3e7;color:#835019;font-size:13px;line-height:1.5}
.paid-cost-form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.paid-cost-form-grid label{display:flex;flex-direction:column;gap:6px;min-width:0;color:#29445e;font-size:12px;font-weight:700}
.paid-cost-form-grid [data-purchase-fx][hidden]{display:none}
.paid-cost-form-grid [data-purchase-dux-confirm-row][hidden]{display:none}
.paid-cost-form-grid [data-purchase-dux-confirm-row] span{display:flex;align-items:flex-start;gap:8px;line-height:1.45}
.paid-cost-form-grid [data-purchase-dux-confirm-row] input[type=checkbox]{width:auto;min-height:0;margin:2px 0 0;flex:none}
.paid-cost-form-grid input,.paid-cost-form-grid select{width:100%;min-width:0;min-height:42px;padding:9px 11px;border:1px solid #b9cde1;border-radius:9px;background:#fff;color:#142f4e;font:inherit;font-size:14px}
.paid-cost-form-grid input:focus-visible,.paid-cost-form-grid select:focus-visible{outline:2px solid #367bc3;outline-offset:2px}
.paid-cost-wide,.paid-cost-evidence{grid-column:1/-1}
.paid-cost-evidence{padding:10px 12px;border-radius:9px;background:#f4f8fd;color:#365979;font-size:12px;line-height:1.45}
.paid-cost-form-error{margin:12px 0 0;padding:10px 12px;border-radius:9px;background:#fff3e7;color:#835019;font-size:13px;line-height:1.45}
.paid-cost-form-error[hidden],#paidCostExchangeRow[hidden]{display:none}
@media(max-width:640px){
  .paid-cost-panel{padding:14px;margin-top:12px}
  .paid-cost-head,.paid-cost-location-main,.paid-cost-foot{align-items:stretch;flex-direction:column}
  .paid-cost-head button,.paid-cost-foot button{width:100%;min-height:44px}
  .paid-cost-counts{justify-content:flex-start}
  .paid-cost-pending{justify-content:flex-start}
  .paid-cost-counts span{white-space:normal}
  .paid-cost-modal .modal-body{max-height:calc(100dvh - 190px);padding:14px}
  .paid-cost-modal .modal-footer{padding-bottom:max(12px,env(safe-area-inset-bottom))}
  .paid-cost-modal .modal-footer button{flex:1 1 140px;min-height:44px}
  .paid-cost-form-grid{grid-template-columns:1fr}
  .paid-cost-history table{min-width:0}
  .paid-cost-history thead{display:none}
  .paid-cost-history tbody,.paid-cost-history tr,.paid-cost-history td{display:block}
  .paid-cost-history tr{margin-top:8px;padding:8px;border:1px solid #e1ebf5;border-radius:8px;background:#f9fbfe}
  .paid-cost-history td{border:0;padding:4px 0;overflow-wrap:anywhere}
  .paid-cost-history td::before{content:attr(data-label);display:block;margin-bottom:2px;color:#58738e;font-size:11px;font-weight:700}
}
.cost-basis-summary{padding:14px 0;border-bottom:1px solid #dae4ef;margin-bottom:12px}.cost-basis-summary h3{font-size:16px;margin:0 0 10px}.cost-basis-summary ul{padding:0;list-style:none}.cost-basis-record{padding:12px 0;border-bottom:1px solid #e7edf5;display:flex;align-items:flex-start;justify-content:space-between;gap:12px}.cost-basis-record>div:first-child{display:grid;gap:5px}.cost-basis-record span{font-size:12px;color:#55708b;overflow-wrap:anywhere}.cost-basis-actions{display:flex;gap:8px;flex-wrap:wrap}.cost-basis-summary details{margin-top:10px}.paid-cost-form-grid [hidden]{display:none!important}.paid-cost-form-grid textarea{min-height:80px;resize:vertical}.paid-cost-form-grid [data-revision-error]{color:#a43d31;grid-column:1/-1}.paid-cost-form-grid [data-tax-preview]{grid-column:1/-1}
@media(max-width:600px){.cost-basis-record{flex-direction:column}.cost-basis-actions{width:100%}}

.paid-cost-form-grid [data-cost-operation]{grid-column:1/-1}.paid-cost-form-grid [data-tax-preview]:empty{display:none}
