.fcap-login-shell,.fcap-portal{font-family:inherit;box-sizing:border-box}.fcap-login-shell *,.fcap-portal *{box-sizing:border-box}.fcap-login-shell{display:flex;justify-content:center;align-items:center;min-height:65vh;padding:30px}.fcap-login-card{width:min(100%,430px);padding:34px;background:#fff;border:1px solid #e2e8f0;border-radius:18px;box-shadow:0 18px 55px rgba(15,23,42,.10);text-align:center}.fcap-brand-mark{display:inline-flex;align-items:center;justify-content:center;width:58px;height:58px;border-radius:17px;background:#111827;color:#fff;font-weight:800;font-size:22px}.fcap-login-card h2{margin:18px 0 7px}.fcap-login-card>p{color:#64748b;margin:0 0 24px}.fcap-login-card label{display:block;text-align:right;font-weight:600;margin-bottom:6px}.fcap-login-card input[type=text],.fcap-login-card input[type=password]{width:100%;min-height:46px;border:1px solid #cbd5e1;border-radius:9px;padding:8px 12px}.fcap-login-card .login-remember{text-align:right}.fcap-login-card .login-submit input{width:100%;min-height:46px;border:0;border-radius:9px;background:#111827;color:#fff;font-weight:700;cursor:pointer}.fcap-login-links{margin-top:17px}.fcap-portal{max-width:1500px;margin:30px auto;padding:0 18px;color:#0f172a}.fcap-portal-header{display:flex;justify-content:space-between;align-items:center;gap:20px;padding:25px 28px;border-radius:18px;background:#111827;color:#fff;margin-bottom:18px}.fcap-portal-header h1{color:#fff;margin:3px 0 4px;font-size:30px}.fcap-portal-header p{margin:0;color:#cbd5e1}.fcap-eyebrow{font-size:12px;letter-spacing:.08em;color:#93c5fd}.fcap-logout,.fcap-button{display:inline-flex;align-items:center;justify-content:center;padding:10px 18px;border-radius:9px;background:#fff;color:#111827;text-decoration:none;font-weight:700}.fcap-portal-layout{display:grid;grid-template-columns:235px minmax(0,1fr);gap:18px}.fcap-portal-nav{background:#fff;border:1px solid #e2e8f0;border-radius:15px;padding:10px;height:max-content;position:sticky;top:20px}.fcap-nav-link{display:flex;align-items:center;gap:10px;padding:12px 14px;border-radius:10px;color:#334155;text-decoration:none;margin:3px 0}.fcap-nav-link:hover,.fcap-nav-link.is-active{background:#eef2ff;color:#1e3a8a}.fcap-portal-main{min-height:520px;background:#f8fafc;border:1px solid #e2e8f0;border-radius:15px;padding:25px}.fcap-section-heading h2{margin:0 0 5px}.fcap-section-heading p{margin:0 0 22px;color:#64748b}.fcap-stat-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px}.fcap-stat-card{display:flex;flex-direction:column;gap:8px;background:#fff;border:1px solid #e2e8f0;border-radius:14px;padding:18px}.fcap-stat-card span{color:#64748b}.fcap-stat-card strong{font-size:25px}.fcap-stat-card small{color:#94a3b8;line-height:1.45}.fcap-action-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;margin-top:20px}.fcap-action-card{display:flex;align-items:flex-start;gap:14px;background:#fff;border:1px solid #dbeafe;border-radius:14px;padding:18px;text-decoration:none;color:#0f172a}.fcap-action-card>.dashicons{font-size:28px;width:28px;height:28px;color:#2563eb}.fcap-action-card strong,.fcap-action-card small{display:block}.fcap-action-card small{margin-top:5px;color:#64748b;line-height:1.4}.fcap-empty-state{background:#fff;border:1px dashed #cbd5e1;border-radius:15px;padding:44px 25px;text-align:center}.fcap-empty-state>.dashicons{font-size:42px;width:42px;height:42px;color:#64748b}.fcap-empty-state h3{margin:14px 0 7px}.fcap-empty-state p{color:#64748b;max-width:720px;margin:8px auto}.fcap-profile-card{background:#fff;border:1px solid #e2e8f0;border-radius:14px;padding:22px}.fcap-profile-card dl{display:grid;grid-template-columns:180px 1fr;margin:0}.fcap-profile-card dt,.fcap-profile-card dd{padding:12px;border-bottom:1px solid #eef2f7;margin:0}.fcap-profile-card dt{font-weight:700}.fcap-notice-box{max-width:650px;margin:40px auto;padding:25px;border:1px solid #e2e8f0;border-radius:14px;background:#fff;text-align:center}.fcap-notice-box .fcap-button{background:#111827;color:#fff;margin-top:8px}@media(max-width:1050px){.fcap-stat-grid{grid-template-columns:repeat(2,1fr)}.fcap-action-grid{grid-template-columns:1fr}.fcap-portal-layout{grid-template-columns:1fr}.fcap-portal-nav{position:static;display:flex;overflow:auto}.fcap-nav-link{white-space:nowrap}}@media(max-width:620px){.fcap-login-shell{padding:15px}.fcap-login-card{padding:24px}.fcap-portal{padding:0 10px}.fcap-portal-header{align-items:flex-start;padding:20px}.fcap-portal-header h1{font-size:24px}.fcap-portal-main{padding:17px}.fcap-stat-grid{grid-template-columns:1fr}.fcap-profile-card dl{grid-template-columns:1fr}.fcap-profile-card dt{padding-bottom:3px;border-bottom:0}.fcap-profile-card dd{padding-top:3px}.fcap-nav-link .dashicons{display:none}}
.fcap-button{border:0;cursor:pointer;background:#111827;color:#fff}.fcap-button-secondary{background:#fff;color:#111827;border:1px solid #cbd5e1}.fcap-customer-search{display:flex;gap:10px;margin-bottom:14px}.fcap-customer-search input[type=search]{flex:1;min-height:46px;border:1px solid #cbd5e1;border-radius:10px;padding:8px 14px;background:#fff}.fcap-results-summary{margin:0 0 12px;color:#64748b;font-size:14px}.fcap-customer-list{display:flex;flex-direction:column;gap:10px}.fcap-customer-row{display:grid;grid-template-columns:minmax(210px,1.35fr) minmax(220px,1.4fr) minmax(125px,.7fr) minmax(120px,.65fr) auto;align-items:center;gap:16px;background:#fff;border:1px solid #e2e8f0;border-radius:13px;padding:15px 17px}.fcap-customer-main,.fcap-customer-contact,.fcap-customer-agent,.fcap-customer-balance{display:flex;flex-direction:column;gap:4px;min-width:0}.fcap-customer-main strong{font-size:16px}.fcap-customer-main span,.fcap-customer-contact span,.fcap-customer-agent small,.fcap-customer-balance small{color:#64748b;font-size:13px;overflow-wrap:anywhere}.fcap-customer-agent strong,.fcap-customer-balance strong{font-size:14px}.fcap-row-action{display:inline-flex;justify-content:center;align-items:center;white-space:nowrap;padding:9px 13px;border-radius:8px;background:#eef2ff;color:#1e3a8a;text-decoration:none;font-weight:700}.fcap-pagination{display:flex;justify-content:center;align-items:center;gap:6px;margin-top:20px}.fcap-pagination a,.fcap-pagination span{display:inline-flex;align-items:center;justify-content:center;min-width:36px;height:36px;border-radius:8px;background:#fff;border:1px solid #e2e8f0;color:#334155;text-decoration:none}.fcap-pagination a.is-current{background:#111827;color:#fff;border-color:#111827}.fcap-card-toolbar{display:flex;justify-content:space-between;align-items:center;gap:16px;margin-bottom:14px}.fcap-back-link{color:#334155;text-decoration:none;font-weight:600}.fcap-card-actions{display:flex;gap:8px}.fcap-customer-hero{display:flex;justify-content:space-between;align-items:center;gap:20px;background:#111827;color:#fff;border-radius:16px;padding:24px 26px;margin-bottom:16px}.fcap-customer-hero h2{color:#fff;margin:5px 0}.fcap-customer-hero p{margin:0;color:#cbd5e1}.fcap-hero-balance{display:flex;flex-direction:column;align-items:flex-end;gap:5px;min-width:190px}.fcap-hero-balance span,.fcap-hero-balance small{color:#cbd5e1}.fcap-hero-balance strong{font-size:28px}.fcap-detail-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}.fcap-detail-card,.fcap-notes-card{background:#fff;border:1px solid #e2e8f0;border-radius:14px;padding:20px}.fcap-detail-card h3,.fcap-notes-card h3{margin:0 0 14px}.fcap-detail-card dl{display:grid;grid-template-columns:150px 1fr;margin:0}.fcap-detail-card dt,.fcap-detail-card dd{margin:0;padding:9px 0;border-bottom:1px solid #f1f5f9}.fcap-detail-card dt{font-weight:700;color:#475569}.fcap-detail-card dd{overflow-wrap:anywhere}.fcap-notes-card{margin-top:14px}.fcap-notes-card>div{line-height:1.65;color:#334155}@media(max-width:1180px){.fcap-customer-row{grid-template-columns:1fr 1fr}.fcap-row-action{justify-self:start}.fcap-customer-agent,.fcap-customer-balance{align-self:start}}@media(max-width:760px){.fcap-customer-search{flex-direction:column}.fcap-customer-row{grid-template-columns:1fr}.fcap-detail-grid{grid-template-columns:1fr}.fcap-customer-hero{align-items:flex-start;flex-direction:column}.fcap-hero-balance{align-items:flex-start}.fcap-card-toolbar{align-items:flex-start;flex-direction:column}.fcap-card-actions{width:100%;flex-wrap:wrap}.fcap-card-actions .fcap-button{flex:1}.fcap-detail-card dl{grid-template-columns:1fr}.fcap-detail-card dt{padding-bottom:2px;border-bottom:0}.fcap-detail-card dd{padding-top:2px}}
.fcap-order-start{display:flex;justify-content:space-between;align-items:center;gap:20px;background:#fff;border:1px solid #dbeafe;border-radius:14px;padding:18px 20px;margin-bottom:18px}.fcap-order-start strong{font-size:17px}.fcap-order-start p{margin:5px 0 0;color:#64748b}.fcap-order-list{display:flex;flex-direction:column;gap:10px}.fcap-order-row{display:grid;grid-template-columns:minmax(190px,1.3fr) minmax(150px,.9fr) minmax(120px,.7fr) minmax(120px,.7fr) auto;align-items:center;gap:16px;background:#fff;border:1px solid #e2e8f0;border-radius:13px;padding:15px 17px}.fcap-order-row>div{display:flex;flex-direction:column;gap:4px}.fcap-order-row span,.fcap-order-row small{color:#64748b}.fcap-order-status{font-weight:700;color:#1e3a8a!important}.fcap-order-customer-summary,.fcap-order-detail-hero{display:flex;justify-content:space-between;align-items:center;gap:20px;background:#111827;color:#fff;border-radius:16px;padding:23px 26px;margin-bottom:16px}.fcap-order-customer-summary h2,.fcap-order-detail-hero h2{color:#fff;margin:4px 0}.fcap-order-customer-summary p,.fcap-order-detail-hero p{margin:0;color:#cbd5e1}.fcap-order-customer-terms,.fcap-order-detail-hero>div:last-child{display:flex;flex-direction:column;align-items:flex-end;gap:5px}.fcap-order-customer-terms small,.fcap-order-detail-hero small{color:#cbd5e1}.fcap-order-customer-terms strong,.fcap-order-detail-hero>div:last-child strong{font-size:18px}.fcap-order-detail-hero>div:last-child span{font-size:24px;font-weight:800}.fcap-order-builder{display:flex;flex-direction:column;gap:14px}.fcap-order-panel{background:#fff;border:1px solid #e2e8f0;border-radius:14px;padding:20px}.fcap-order-panel h3{margin:0 0 16px}.fcap-product-search-wrap{display:flex;gap:10px}.fcap-product-search-wrap input{flex:1;min-height:46px;border:1px solid #cbd5e1;border-radius:10px;padding:8px 14px}.fcap-product-results{margin-top:10px;border:1px solid #dbe3ef;border-radius:12px;overflow:hidden;max-height:420px;overflow-y:auto;background:#fff}.fcap-product-result{width:100%;display:grid;grid-template-columns:54px minmax(0,1fr) minmax(120px,.45fr) 28px;align-items:center;gap:13px;border:0;border-bottom:1px solid #eef2f7;background:#fff;padding:12px;text-align:right;cursor:pointer;color:#0f172a}.fcap-product-result:last-child{border-bottom:0}.fcap-product-result:hover{background:#f8fafc}.fcap-product-result img{width:54px;height:54px;object-fit:cover;border-radius:8px;background:#f1f5f9}.fcap-product-result-main,.fcap-product-result-price{display:flex;flex-direction:column;gap:4px}.fcap-product-result-main small,.fcap-product-result-price small{color:#64748b}.fcap-product-result-price{text-align:left}.fcap-product-result>.dashicons{color:#2563eb}.fcap-product-result-empty{padding:18px;color:#64748b}.fcap-product-result-empty.is-error{color:#b91c1c}.fcap-order-lines{display:flex;flex-direction:column;gap:9px}.fcap-order-lines-empty{text-align:center;color:#64748b;padding:25px;border:1px dashed #cbd5e1;border-radius:11px}.fcap-order-line{display:grid;grid-template-columns:58px minmax(180px,1.5fr) 100px 130px 130px 38px;align-items:center;gap:13px;border:1px solid #e2e8f0;border-radius:12px;padding:11px}.fcap-order-line>img{width:58px;height:58px;object-fit:cover;border-radius:8px;background:#f1f5f9}.fcap-order-line-main,.fcap-line-price,.fcap-line-total{display:flex;flex-direction:column;gap:4px}.fcap-order-line-main small,.fcap-line-price small,.fcap-line-total small,.fcap-order-line label span{font-size:12px;color:#64748b}.fcap-order-line label{display:flex;flex-direction:column;gap:4px}.fcap-order-line input{width:100%;height:40px;border:1px solid #cbd5e1;border-radius:8px;padding:6px 8px}.fcap-remove-line{border:0;background:#fee2e2;color:#b91c1c;width:36px;height:36px;border-radius:8px;cursor:pointer}.fcap-order-summary{display:flex;justify-content:flex-end;align-items:center;gap:18px;margin-top:14px;padding-top:14px;border-top:1px solid #e2e8f0}.fcap-order-summary span{color:#64748b}.fcap-order-summary strong{font-size:22px}.fcap-order-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}.fcap-order-fields label{display:flex;flex-direction:column;gap:6px}.fcap-order-fields label>span{font-weight:700;color:#334155}.fcap-order-fields input,.fcap-order-fields select,.fcap-order-fields textarea{width:100%;border:1px solid #cbd5e1;border-radius:9px;padding:10px 12px;background:#fff}.fcap-order-field-full,.fcap-checkbox-field{grid-column:1/-1}.fcap-checkbox-field{flex-direction:row!important;align-items:center}.fcap-checkbox-field input{width:auto}.fcap-checkbox-field span{font-weight:500!important}.fcap-inline-note{margin:14px 0 0;padding:11px 13px;border-radius:9px;background:#fff7ed;color:#9a3412}.fcap-create-order-button{margin-top:17px;min-width:190px}.fcap-order-message{margin-top:15px;padding:14px;border-radius:10px;display:flex;flex-direction:column;gap:8px}.fcap-order-message.is-error{background:#fef2f2;color:#991b1b;border:1px solid #fecaca}.fcap-order-message.is-success{background:#ecfdf5;color:#065f46;border:1px solid #a7f3d0}.fcap-created-order-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:5px}.fcap-payment-link-box{display:flex;align-items:flex-end;gap:15px;background:#eff6ff;border:1px solid #bfdbfe;border-radius:14px;padding:17px;margin-bottom:14px}.fcap-payment-link-box>div{flex:1;display:flex;flex-direction:column;gap:7px}.fcap-payment-link-box input{width:100%;direction:ltr;text-align:left;border:1px solid #93c5fd;border-radius:8px;padding:10px;background:#fff}.fcap-order-detail-items{display:flex;flex-direction:column}.fcap-order-detail-item{display:grid;grid-template-columns:minmax(0,1fr) 90px 140px;align-items:center;gap:14px;padding:12px 0;border-bottom:1px solid #eef2f7}.fcap-order-detail-item>div{display:flex;flex-direction:column;gap:4px}.fcap-order-detail-item small{color:#64748b}.fcap-order-totals{display:flex;justify-content:flex-end;margin-top:15px}.fcap-order-totals dl{display:grid;grid-template-columns:170px minmax(130px,auto);margin:0;min-width:330px}.fcap-order-totals dt,.fcap-order-totals dd{padding:7px;margin:0;border-bottom:1px solid #eef2f7}.fcap-order-totals dt{font-weight:700}.fcap-order-totals dd{text-align:left}@media(max-width:1180px){.fcap-order-row{grid-template-columns:1fr 1fr}.fcap-order-line{grid-template-columns:54px minmax(0,1fr) 90px}.fcap-line-price,.fcap-line-total{grid-column:auto}.fcap-remove-line{justify-self:end}}@media(max-width:760px){.fcap-order-start,.fcap-order-customer-summary,.fcap-order-detail-hero,.fcap-payment-link-box{align-items:flex-start;flex-direction:column}.fcap-order-customer-terms,.fcap-order-detail-hero>div:last-child{align-items:flex-start}.fcap-order-row{grid-template-columns:1fr}.fcap-product-search-wrap{flex-direction:column}.fcap-product-result{grid-template-columns:48px 1fr 24px}.fcap-product-result-price{grid-column:2;text-align:right}.fcap-order-line{grid-template-columns:48px 1fr}.fcap-order-line>img{width:48px;height:48px}.fcap-order-line label,.fcap-line-price,.fcap-line-total{grid-column:1/-1}.fcap-remove-line{grid-column:2;justify-self:end}.fcap-order-fields{grid-template-columns:1fr}.fcap-order-field-full,.fcap-checkbox-field{grid-column:auto}.fcap-order-detail-item{grid-template-columns:1fr}.fcap-order-totals{justify-content:stretch}.fcap-order-totals dl{min-width:0;width:100%;grid-template-columns:1fr 1fr}}
.fcap-catalog-tools{display:grid;grid-template-columns:minmax(0,1.4fr) minmax(280px,.8fr);gap:12px}.fcap-category-browser{display:flex;gap:10px}.fcap-category-browser select{flex:1;min-height:46px;border:1px solid #cbd5e1;border-radius:10px;padding:8px 12px;background:#fff}.fcap-catalog-help{margin:10px 0 0;color:#64748b;font-size:13px}.fcap-result-category{color:#94a3b8!important}.fcap-product-pagination{display:flex;justify-content:center;align-items:center;gap:6px;flex-wrap:wrap;margin-top:12px}.fcap-product-pagination button{min-width:38px;height:38px;border:1px solid #cbd5e1;border-radius:8px;background:#fff;color:#334155;cursor:pointer}.fcap-product-pagination button.is-current{background:#111827;color:#fff;border-color:#111827}.fcap-product-pagination button:disabled{opacity:.45;cursor:not-allowed}.fcap-field-help{display:block;margin-top:2px;color:#64748b;font-weight:400!important}.fcap-custom-shipping-fields{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;padding:14px;border:1px solid #dbeafe;border-radius:11px;background:#f8fbff}.fcap-custom-shipping-fields[hidden]{display:none}.fcap-custom-shipping-fields label{min-width:0}@media(max-width:900px){.fcap-catalog-tools{grid-template-columns:1fr}.fcap-custom-shipping-fields{grid-template-columns:1fr}}@media(max-width:760px){.fcap-category-browser{flex-direction:column}}

/* v0.5.0 — full-width compact catalog rows */
.fcap-order-panel-catalog{width:100%;padding:16px}
.fcap-order-panel-catalog .fcap-catalog-tools,.fcap-order-panel-catalog .fcap-product-results,.fcap-order-panel-catalog .fcap-product-pagination{width:100%;max-width:none}
.fcap-order-panel-catalog .fcap-product-results{max-height:590px;margin-top:9px}
.fcap-order-panel-catalog .fcap-product-result{grid-template-columns:40px minmax(0,1fr) minmax(105px,145px) 24px;gap:9px;min-height:52px;padding:6px 10px}
.fcap-order-panel-catalog .fcap-product-result img{width:40px;height:40px;border-radius:6px}
.fcap-order-panel-catalog .fcap-product-result-main{min-width:0;gap:2px}
.fcap-order-panel-catalog .fcap-product-result-main strong{font-size:14px;line-height:1.25;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden}
.fcap-order-panel-catalog .fcap-product-result-main small{font-size:11.5px;line-height:1.25;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.fcap-order-panel-catalog .fcap-product-result-price{gap:1px;white-space:nowrap}
.fcap-order-panel-catalog .fcap-product-result-price strong{font-size:14px;line-height:1.2}
.fcap-order-panel-catalog .fcap-product-result-price small{font-size:11px;line-height:1.2}
.fcap-order-panel-catalog .fcap-product-result>.dashicons{font-size:19px;width:19px;height:19px}
@media(max-width:760px){.fcap-order-panel-catalog{padding:12px}.fcap-order-panel-catalog .fcap-product-result{grid-template-columns:36px minmax(0,1fr) 22px;padding:7px 8px}.fcap-order-panel-catalog .fcap-product-result img{width:36px;height:36px}.fcap-order-panel-catalog .fcap-product-result-price{grid-column:2;text-align:right;flex-direction:row;align-items:center;gap:7px}.fcap-order-panel-catalog .fcap-product-result-main small{white-space:normal;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2}}

/* v0.6.0 — live customers, wide catalog rows, matrix/stock/shipping badges, quick view */
.fcap-customer-search{position:relative}.fcap-customer-search.is-loading input{background-image:linear-gradient(90deg,transparent,rgba(37,99,235,.05),transparent);background-size:200% 100%;animation:fcap-search-loading 1s linear infinite}.fcap-customer-live-status{min-height:22px;margin:4px 0 8px;color:#64748b;font-size:13px}.fcap-customer-live-status .is-error{color:#b91c1c}@keyframes fcap-search-loading{to{background-position:-200% 0}}

.fcap-order-panel-catalog .fcap-product-results{max-height:720px;overflow:auto}
.fcap-order-panel-catalog .fcap-product-result{display:grid;grid-template-columns:76px minmax(0,1fr);gap:14px;width:100%;min-height:108px;padding:10px 12px;border:0;border-bottom:1px solid #e7edf5;background:#fff;text-align:right;color:#0f172a;cursor:default}
.fcap-order-panel-catalog .fcap-product-result:last-child{border-bottom:0}.fcap-order-panel-catalog .fcap-product-result:hover{background:#fbfdff}
.fcap-product-result-image{display:flex;align-items:flex-start;justify-content:center}.fcap-order-panel-catalog .fcap-product-result-image img{width:72px;height:72px;object-fit:contain;border-radius:8px;background:#f8fafc;border:1px solid #eef2f7}
.fcap-product-result-content{min-width:0;display:flex;flex-direction:column;gap:5px}.fcap-product-result-heading{display:flex;align-items:baseline;gap:9px;flex-wrap:wrap;min-width:0}.fcap-product-result-heading strong{font-size:14.5px;line-height:1.3;color:#111827}.fcap-result-sku,.fcap-result-matrix-parent{font-size:12px;color:#64748b}.fcap-result-matrix-parent{color:#475569}
.fcap-product-result-badges{display:flex;gap:5px;align-items:center;flex-wrap:wrap}.fcap-result-badge{display:inline-flex;align-items:center;min-height:23px;padding:2px 8px;border-radius:999px;font-size:11px;font-weight:700;line-height:1.3}.fcap-result-badge:not(.fc-dp-badge){background:#f1f5f9;color:#475569}.fcap-result-stock.is-in{background:#ecfdf5;color:#047857}.fcap-result-stock.is-backorder{background:#fffbeb;color:#b45309}.fcap-result-stock.is-out{background:#fef2f2;color:#b91c1c}.fcap-result-matrix{background:#f5f3ff;color:#6d28d9}
.fcap-product-result-bottom{display:flex;align-items:flex-end;justify-content:space-between;gap:18px;margin-top:auto}.fcap-product-result-price{display:flex!important;flex-direction:row!important;align-items:baseline;gap:7px!important;text-align:right!important;flex-wrap:wrap}.fcap-product-result-price strong{font-size:15px!important;color:#0f172a}.fcap-product-result-price small{font-size:11px!important;color:#64748b}.fcap-result-regular-price{font-size:12.5px;color:#94a3b8;text-decoration-thickness:1px}
.fcap-product-result-actions{display:flex;gap:6px;align-items:center;flex-shrink:0}.fcap-result-action{display:inline-flex;align-items:center;justify-content:center;gap:5px;min-height:34px;border:1px solid #cbd5e1;border-radius:8px;padding:5px 10px;background:#fff;color:#334155;font:inherit;font-size:12px;font-weight:700;cursor:pointer}.fcap-result-action:hover{border-color:#2563eb;color:#1d4ed8;background:#eff6ff}.fcap-result-add{background:#111827;border-color:#111827;color:#fff}.fcap-result-add:hover{background:#1e293b;color:#fff;border-color:#1e293b}.fcap-result-action .dashicons{font-size:17px;width:17px;height:17px}
.fcap-order-summary span{display:flex;gap:5px;align-items:baseline}.fcap-order-summary span small{font-size:12px;color:#64748b;font-weight:500}

body.fcap-qv-open{overflow:hidden}.fcap-qv-overlay{position:fixed;z-index:999999;inset:0;background:rgba(15,23,42,.58);display:flex;align-items:center;justify-content:center;padding:22px}.fcap-qv-modal{position:relative;width:min(980px,96vw);max-height:92vh;overflow:auto;background:#fff;border-radius:18px;box-shadow:0 25px 80px rgba(15,23,42,.28);padding:24px;direction:rtl}.fcap-qv-close{position:absolute;top:10px;left:10px;z-index:2;width:38px;height:38px;border:0;border-radius:50%;background:#f1f5f9;color:#334155;cursor:pointer}.fcap-qv-grid{display:grid;grid-template-columns:minmax(240px,38%) minmax(0,1fr);gap:28px;align-items:start}.fcap-qv-image img{display:block;width:100%;max-height:520px;object-fit:contain;border-radius:12px;background:#f8fafc}.fcap-qv-info{display:flex;flex-direction:column;gap:11px}.fcap-qv-info h2{margin:0;font-size:24px;line-height:1.3}.fcap-qv-sku{margin:0;color:#64748b}.fcap-qv-price{display:flex;align-items:baseline;gap:10px}.fcap-qv-price strong{font-size:22px}.fcap-qv-price small{color:#64748b}.fcap-qv-status{display:flex;gap:7px;flex-wrap:wrap}.fcap-stock-pill{display:inline-flex;padding:5px 10px;border-radius:999px;font-size:12px;font-weight:700;background:#ecfdf5;color:#047857}.fcap-special-shipping-pill{display:inline-flex}.fcap-qv-matrix{display:flex;flex-direction:column;gap:3px;padding:10px 12px;border-radius:10px;background:#f5f3ff;color:#5b21b6}.fcap-qv-branch{font-size:13px}.fcap-qv-description{max-height:220px;overflow:auto;color:#334155;line-height:1.55}.fcap-qv-description p:first-child{margin-top:0}.fcap-qv-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:4px}

@media(min-width:1200px){.fcap-portal{width:calc(100% - 24px);max-width:1900px}.fcap-portal-main{max-width:none}.fcap-order-panel-catalog{padding-left:18px;padding-right:18px}.fcap-order-panel-catalog .fcap-product-result{grid-template-columns:86px minmax(0,1fr);padding:10px 16px}.fcap-order-panel-catalog .fcap-product-result-image img{width:82px;height:82px}}
@media(max-width:760px){.fcap-order-panel-catalog .fcap-product-result{grid-template-columns:58px minmax(0,1fr);gap:9px;padding:9px 8px}.fcap-order-panel-catalog .fcap-product-result-image img{width:56px;height:56px}.fcap-product-result-heading{gap:4px}.fcap-product-result-heading strong{width:100%}.fcap-product-result-bottom{align-items:flex-start;flex-direction:column;gap:8px}.fcap-product-result-actions{width:100%}.fcap-result-action{flex:1}.fcap-result-action span:last-child{display:inline}.fcap-qv-overlay{padding:8px}.fcap-qv-modal{padding:18px 14px 14px;border-radius:14px}.fcap-qv-grid{grid-template-columns:1fr;gap:14px}.fcap-qv-image img{max-height:310px}.fcap-qv-info h2{font-size:19px}}

/* v0.6.1 — unified stock, shipping info popover, richer quick view */
.fcap-product-result-badges{overflow:visible}
.fcap-product-result-badges .fcap-stock-combined,
.fcap-qv-status .fcap-stock-combined{position:relative;margin:0!important;font-size:11px;font-weight:700;line-height:1.3;color:#475569}
.fcap-product-result-badges details.fcap-stock-combined,
.fcap-qv-status details.fcap-stock-combined{display:inline-block}
.fcap-stock-combined>summary{list-style:none;display:inline-flex!important;align-items:center;gap:5px;min-height:23px;padding:2px 9px!important;margin:0!important;border:0;border-radius:999px;cursor:pointer;user-select:none;font:inherit;color:inherit;background:#f1f5f9}
.fcap-qv-status .fcap-stock-combined>summary{min-height:28px;padding:4px 11px!important;font-size:12px}
.fcap-stock-combined>summary::-webkit-details-marker{display:none}.fcap-stock-combined>summary::marker{display:none;content:""}
.fcap-stock-combined>summary:after{content:"⌄";font-size:11px;line-height:1;opacity:.75;transition:transform .15s ease}.fcap-stock-combined[open]>summary:after{transform:rotate(180deg)}
.fcap-stock-combined.fc-branch-stock-compact-static{display:inline-flex!important;align-items:center;min-height:23px;padding:2px 9px!important;margin:0!important;border-radius:999px;font:inherit;background:#f1f5f9}
.fcap-qv-status .fcap-stock-combined.fc-branch-stock-compact-static{min-height:28px;padding:4px 11px!important;font-size:12px}
.fcap-stock-combined.is-in>summary,.fcap-stock-combined.is-in.fc-branch-stock-compact-static{background:#ecfdf5;color:#047857}
.fcap-stock-combined.is-backorder>summary,.fcap-stock-combined.is-backorder.fc-branch-stock-compact-static{background:#fffbeb;color:#b45309}
.fcap-stock-combined.is-out>summary,.fcap-stock-combined.is-out.fc-branch-stock-compact-static{background:#fef2f2;color:#b91c1c}
.fcap-stock-combined .fc-branch-stock-panel{position:absolute!important;z-index:1000050;top:calc(100% + 7px);right:0;width:max-content;min-width:230px;max-width:min(330px,82vw);padding:11px 12px!important;margin:0!important;border:1px solid #dbe2ea;border-radius:11px;background:#fff;color:#334155;box-shadow:0 14px 38px rgba(15,23,42,.16);font-size:12px;font-weight:500;line-height:1.45}
.fcap-stock-combined .fc-branch-stock-panel :is(.fc-branch-stock-row,.stock-row){display:flex;align-items:center;gap:6px;padding:4px 0}
.fcap-stock-combined .fc-branch-stock-panel .stock-dot{flex:0 0 auto}
.fcap-qv-status .fcap-stock-combined .fc-branch-stock-panel{position:relative!important;top:auto;right:auto;margin-top:7px!important;min-width:min(300px,75vw)}

.fcap-special-shipping-trigger{appearance:none;-webkit-appearance:none;border:0!important;font-family:inherit;cursor:pointer;gap:5px}.fcap-special-shipping-trigger:hover{filter:brightness(.98)}
.fcap-shipping-info-icon{display:inline-flex;align-items:center;justify-content:center;width:16px;height:16px;border:1px solid currentColor;border-radius:50%;font-size:10px;font-weight:800;line-height:1}
.fcap-shipping-popover{position:fixed;z-index:1000100;width:min(350px,calc(100vw - 20px));padding:15px 16px 14px 16px;border:1px solid #cbd5e1;border-radius:12px;background:#fff;color:#334155;box-shadow:0 18px 55px rgba(15,23,42,.22);direction:rtl;text-align:right}
.fcap-shipping-popover-close{position:absolute;top:7px;left:8px;width:28px;height:28px;border:0;border-radius:50%;background:#f1f5f9;color:#475569;font-size:20px;line-height:1;cursor:pointer}.fcap-shipping-popover-title{display:block;padding-left:30px;margin-bottom:7px;color:#1d4ed8;font-size:15px}.fcap-shipping-popover-text{font-size:13px;line-height:1.55}.fcap-shipping-popover-code{display:block;margin-top:8px;color:#94a3b8;font-size:11px}

.fcap-qv-meta-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px 10px}.fcap-qv-meta-grid>div{display:flex;align-items:baseline;gap:6px;min-width:0;padding:7px 9px;border:1px solid #edf1f5;border-radius:8px;background:#fbfdff}.fcap-qv-meta-grid span{flex:0 0 auto;color:#64748b;font-size:11.5px}.fcap-qv-meta-grid strong{min-width:0;color:#334155;font-size:12.5px;font-weight:700;overflow-wrap:anywhere}
.fcap-qv-attributes{display:flex;flex-direction:column;gap:7px}.fcap-qv-attributes>strong,.fcap-qv-section-title{font-size:13px;color:#334155}.fcap-qv-attribute-list{display:flex;flex-wrap:wrap;gap:6px}.fcap-qv-attribute{display:inline-flex;align-items:baseline;gap:5px;padding:5px 8px;border:1px solid #e2e8f0;border-radius:8px;background:#f8fafc}.fcap-qv-attribute small{color:#64748b;font-size:10.5px}.fcap-qv-attribute b{color:#334155;font-size:11.5px}
.fcap-qv-price del{color:#94a3b8;font-size:15px}.fcap-qv-price del .amount{color:inherit}.fcap-qv-status{align-items:flex-start;overflow:visible}.fcap-qv-description{padding-top:3px;border-top:1px solid #eef2f7}.fcap-qv-description .fcap-qv-section-title{display:block;margin:7px 0 5px}

@media(max-width:760px){.fcap-qv-meta-grid{grid-template-columns:1fr}.fcap-shipping-popover{width:calc(100vw - 20px)}.fcap-stock-combined .fc-branch-stock-panel{max-width:calc(100vw - 40px)}}
/* Keep branch details in normal document flow inside the agent catalog so the scroll container cannot clip them. */
.fcap-product-result .fcap-stock-combined .fc-branch-stock-panel{position:relative!important;top:auto;right:auto;margin-top:7px!important}
/* Strong portal overrides against the site's general regional-stock CSS. */
.fcap-product-result-badges details.fcap-stock-combined,.fcap-qv-status details.fcap-stock-combined{display:inline-block!important;width:auto!important;max-width:100%!important;align-self:flex-start!important}
.fcap-stock-combined.is-in>summary,.fcap-stock-combined.is-in.fc-branch-stock-compact-static{background:#ecfdf5!important;color:#047857!important}
.fcap-stock-combined.is-backorder>summary,.fcap-stock-combined.is-backorder.fc-branch-stock-compact-static{background:#fffbeb!important;color:#b45309!important}
.fcap-stock-combined.is-out>summary,.fcap-stock-combined.is-out.fc-branch-stock-compact-static{background:#fef2f2!important;color:#b91c1c!important}

/* v0.6.3 — מחיר משלוח מיוחד בתוך חלונית המידע */
.fcap-shipping-popover-price{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:10px;padding:10px 11px;border:1px solid #e2e8f0;border-radius:9px;background:#f8fafc;font-size:12px;line-height:1.35}
.fcap-shipping-popover-price strong{font-size:14px;color:#0f172a;white-space:nowrap}
.fcap-shipping-popover-price.is-loading strong{color:#64748b;font-size:12px;font-weight:600}

/* v0.7.0 — Matritza parents, exact delivery badges, richer QV and cart notices */
.fcap-product-result-badges .fc-dp-badge,
.fcap-qv-status .fc-dp-badge,
.fcap-line-shipping-note .fc-dp-badge{display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:5px!important;width:auto!important;min-width:0!important;max-width:100%!important;min-height:23px!important;margin:0!important;padding:2px 9px!important;border-radius:999px!important;font-family:inherit!important;font-size:11px!important;font-weight:700!important;line-height:1.3!important;white-space:nowrap!important;cursor:pointer!important;box-sizing:border-box!important}
.fcap-qv-status .fc-dp-badge{min-height:28px!important;padding:4px 11px!important;font-size:12px!important}
.fcap-line-shipping-note .fc-dp-badge{min-height:21px!important;padding:2px 8px!important;font-size:10.5px!important}
.fcap-product-result-badges .fc-dp-badge__info,
.fcap-qv-status .fc-dp-badge__info,
.fcap-line-shipping-note .fc-dp-badge__info{display:inline-flex!important;align-items:center!important;justify-content:center!important;width:16px!important;height:16px!important;min-width:16px!important;border:1px solid currentColor!important;border-radius:50%!important;font-size:10px!important;font-weight:800!important;line-height:1!important}

.fcap-matrix-picker{display:grid;grid-template-columns:repeat(2,minmax(150px,1fr));gap:8px 10px;width:100%;margin:7px 0 2px;padding:10px;border:1px solid #dbe3ee;border-radius:10px;background:#f8fafc}
.fcap-matrix-picker label{display:flex;flex-direction:column;gap:4px;min-width:0;margin:0;font-size:11px;font-weight:700;color:#475569}
.fcap-matrix-picker select{width:100%;min-height:38px;margin:0;padding:5px 9px;border:1px solid #cbd5e1;border-radius:8px;background:#fff;color:#0f172a;font:inherit}
.fcap-matrix-picker small{grid-column:1/-1;color:#64748b;font-size:11px;line-height:1.35}
.fcap-product-result [data-fcap-add-matrix]:disabled,.fcap-qv-actions [data-fcap-qv-add]:disabled{opacity:.5;cursor:not-allowed}
.fcap-product-result[data-fcap-matrix-card="1"] .fcap-product-result-content{gap:5px}

.fcap-line-shipping-note{display:flex;align-items:center;flex-wrap:wrap;gap:6px;margin-top:5px}
.fcap-line-shipping-note>small{color:#9a3412!important;font-weight:700}

.fcap-qv-modal{width:min(1180px,calc(100vw - 28px));max-width:1180px}
.fcap-qv-additional{padding-top:8px;border-top:1px solid #eef2f7;overflow-x:auto}
.fcap-qv-additional .shop_attributes,.fcap-qv-additional-table{width:100%;border-collapse:collapse;margin:6px 0 0}
.fcap-qv-additional .shop_attributes th,.fcap-qv-additional .shop_attributes td,.fcap-qv-additional-table th,.fcap-qv-additional-table td{padding:6px 8px;border-bottom:1px solid #edf1f5;text-align:right;vertical-align:top;font-size:12px}
.fcap-qv-additional .shop_attributes th,.fcap-qv-additional-table th{width:34%;color:#475569;font-weight:700}
.fcap-qv-related-section{margin-top:14px;padding-top:13px;border-top:1px solid #e2e8f0}
.fcap-qv-related-section>.fcap-qv-section-title{display:block;margin-bottom:8px;font-size:15px}
.fcap-qv-related-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.fcap-qv-related-item{display:grid;grid-template-columns:62px minmax(0,1fr) auto;gap:9px;align-items:center;padding:8px;border:1px solid #e2e8f0;border-radius:10px;background:#fff}
.fcap-qv-related-item>img{width:62px;height:62px;object-fit:contain;border-radius:7px;background:#f8fafc}
.fcap-qv-related-item>div:nth-child(2){display:flex;flex-direction:column;gap:2px;min-width:0}
.fcap-qv-related-item>div:nth-child(2)>strong{font-size:12px;line-height:1.3}
.fcap-qv-related-item>div:nth-child(2)>small{font-size:10.5px;color:#64748b}
.fcap-qv-related-item>div:nth-child(2)>span{font-size:12px;font-weight:800}
.fcap-qv-related-actions{display:flex;flex-direction:column;gap:5px}
.fcap-qv-related-actions .fcap-result-action{min-height:31px;padding:5px 8px;font-size:10.5px;white-space:nowrap}

@media(max-width:760px){.fcap-matrix-picker{grid-template-columns:1fr}.fcap-qv-related-list{grid-template-columns:1fr}.fcap-qv-related-item{grid-template-columns:54px minmax(0,1fr)}.fcap-qv-related-item>img{width:54px;height:54px}.fcap-qv-related-actions{grid-column:1/-1;flex-direction:row}.fcap-qv-related-actions .fcap-result-action{flex:1}}

/* =========================================================
 * v0.8.0 — open orders + agent payment requests
 * ========================================================= */
.fcap-order-group{margin-top:22px}
.fcap-order-group-heading{display:flex;align-items:center;gap:9px;margin:0 0 10px}
.fcap-order-group-heading h3{margin:0;font-size:17px}
.fcap-count-pill{display:inline-flex;align-items:center;justify-content:center;min-width:25px;height:25px;padding:0 8px;border-radius:999px;background:#eff6ff;color:#1d4ed8;font-size:12px;font-weight:800}
.fcap-open-orders{padding:15px;border:1px solid #bfdbfe;border-radius:14px;background:#f8fbff}
.fcap-open-orders .fcap-order-row{background:#fff}
.fcap-empty-state-compact{padding:18px!important;min-height:0!important}
.fcap-empty-state-compact h3{font-size:14px!important;margin:4px 0 0!important}

.fcap-payment-balance-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-bottom:14px}
.fcap-payment-balance-card{display:flex;flex-direction:column;align-items:flex-start;gap:8px;padding:17px 18px;border:1px solid #dbeafe;border-radius:13px;background:#f8fbff}
.fcap-payment-balance-card>span{font-size:12px;color:#64748b}
.fcap-payment-balance-card>strong{font-size:22px;line-height:1.1;color:#0f172a}
.fcap-payment-request-builder .fcap-order-fields{margin-top:6px}
.fcap-payment-created-link{margin-top:12px;padding:13px;border:1px solid #a7f3d0;border-radius:10px;background:#ecfdf5;color:#065f46}
.fcap-payment-created-link>strong{display:block;margin-bottom:8px}
.fcap-payment-created-link-row{display:flex;gap:7px;align-items:center}
.fcap-payment-created-link input{flex:1;min-width:0;direction:ltr;text-align:left;border:1px solid #86efac;border-radius:8px;padding:9px;background:#fff}
.fcap-payment-request-list{display:flex;flex-direction:column;gap:9px}
.fcap-payment-request-row{display:grid;grid-template-columns:minmax(190px,1.25fr) minmax(150px,.8fr) minmax(110px,.65fr) minmax(110px,.65fr) minmax(270px,1.25fr);align-items:center;gap:13px;padding:14px 15px;border:1px solid #e2e8f0;border-radius:12px;background:#fff}
.fcap-payment-request-row>div{display:flex;flex-direction:column;gap:3px;min-width:0}
.fcap-payment-request-row small,.fcap-payment-request-row span{color:#64748b}
.fcap-payment-status{display:inline-flex!important;width:max-content;padding:3px 8px;border-radius:999px;background:#f1f5f9;color:#475569!important;font-size:11px;font-weight:800}
.fcap-payment-status.is-pending{background:#fff7ed;color:#c2410c!important}
.fcap-payment-status.is-paid{background:#ecfdf5;color:#047857!important}
.fcap-payment-request-actions{display:grid!important;grid-template-columns:minmax(0,1fr) auto auto;gap:6px!important;align-items:center}
.fcap-payment-request-actions input{min-width:0;width:100%;direction:ltr;text-align:left;border:1px solid #cbd5e1;border-radius:7px;padding:7px 8px;background:#f8fafc;font-size:11px}
.fcap-payment-request-actions .fcap-result-action{white-space:nowrap}

.fcap-result-action:disabled,.fcap-button:disabled{opacity:.45;cursor:not-allowed!important}

@media(max-width:1180px){
  .fcap-payment-request-row{grid-template-columns:1fr 1fr}
  .fcap-payment-request-actions{grid-column:1/-1}
}
@media(max-width:760px){
  .fcap-payment-balance-grid{grid-template-columns:1fr}
  .fcap-payment-request-row{grid-template-columns:1fr}
  .fcap-payment-request-actions{grid-column:auto;grid-template-columns:1fr 1fr}
  .fcap-payment-request-actions input{grid-column:1/-1}
  .fcap-payment-created-link-row{flex-direction:column;align-items:stretch}
}
.fcap-order-message .fcap-payment-created-link{display:flex;gap:7px;align-items:center;margin-top:10px;padding:0;border:0;background:transparent}
.fcap-order-message .fcap-payment-created-link input{flex:1;min-width:0;direction:ltr;text-align:left;border:1px solid #86efac;border-radius:8px;padding:9px;background:#fff}
@media(max-width:760px){.fcap-order-message .fcap-payment-created-link{flex-direction:column;align-items:stretch}}

/* v0.8.1 — server-side agent order drafts */
.fcap-order-drafts{margin-top:22px}
.fcap-order-drafts .fcap-draft-row{border-color:#fde68a;background:#fffbeb}
.fcap-draft-actions{display:flex!important;flex-direction:row!important;align-items:center;justify-content:flex-end;gap:8px;flex-wrap:wrap}
.fcap-row-action-danger{border:1px solid #fecaca;background:#fff1f2;color:#b91c1c;cursor:pointer;font:inherit}
.fcap-row-action-danger:hover{background:#fee2e2}
@media(max-width:1180px){.fcap-draft-actions{justify-content:flex-start}}

/* =========================================================
 * v0.9.0 - Customer ledger and ledger-based payment requests
 * ========================================================= */
.fcap-ledger-panel {
    margin-top: 24px;
    padding: 22px;
    border: 1px solid #dfe5ec;
    border-radius: 16px;
    background: #fff;
}

.fcap-ledger-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 18px;
}

.fcap-ledger-heading h3 {
    margin: 3px 0 5px;
    font-size: 24px;
}

.fcap-ledger-heading p {
    margin: 0;
    color: #667085;
}

.fcap-ledger-balance {
    min-width: 210px;
    padding: 14px 16px;
    border-radius: 12px;
    background: #f7f9fc;
    text-align: center;
}

.fcap-ledger-balance small,
.fcap-ledger-balance span {
    display: block;
    color: #667085;
}

.fcap-ledger-balance strong {
    display: block;
    margin: 3px 0;
    font-size: 22px;
}

.fcap-ledger-toolbar {
    display: flex;
    align-items: end;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

.fcap-ledger-toolbar label {
    display: grid;
    gap: 5px;
    min-width: 170px;
}

.fcap-ledger-toolbar label span {
    font-size: 13px;
    font-weight: 600;
}

.fcap-ledger-toolbar input[type="date"] {
    min-height: 42px;
    border: 1px solid #cfd7e3;
    border-radius: 9px;
    padding: 6px 10px;
    background: #fff;
}

.fcap-ledger-placeholder {
    min-height: 170px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 7px;
    border: 1px dashed #d6dde8;
    border-radius: 12px;
    color: #667085;
    background: #fafbfc;
}

.fcap-ledger-placeholder .dashicons {
    width: 30px;
    height: 30px;
    font-size: 30px;
}

.fcap-ledger-placeholder.is-loading .dashicons {
    animation: fcap-ledger-spin 1s linear infinite;
}

@keyframes fcap-ledger-spin {
    to { transform: rotate(360deg); }
}

.fcap-ledger-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin: 0 0 14px;
}

.fcap-ledger-summary > div {
    padding: 11px 13px;
    border: 1px solid #e1e7ef;
    border-radius: 10px;
    background: #f9fafb;
}

.fcap-ledger-summary small,
.fcap-ledger-summary strong {
    display: block;
}

.fcap-ledger-summary small {
    color: #667085;
    margin-bottom: 3px;
}

.fcap-ledger-summary strong {
    font-size: 17px;
}

.fcap-ledger-select-tools {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    padding: 10px 12px;
    margin-bottom: 10px;
    border-radius: 10px;
    background: #f5f8ff;
    color: #344054;
}

.fcap-ledger-select-tools label {
    font-weight: 700;
    cursor: pointer;
}

.fcap-ledger-table-wrap {
    overflow-x: auto;
    border: 1px solid #e1e7ef;
    border-radius: 12px;
}

.fcap-ledger-table {
    width: 100%;
    min-width: 1050px;
    border-collapse: collapse;
    background: #fff;
    font-size: 13px;
}

.fcap-ledger-table th,
.fcap-ledger-table td {
    padding: 9px 10px;
    border-bottom: 1px solid #edf0f4;
    text-align: right;
    vertical-align: middle;
    white-space: nowrap;
}

.fcap-ledger-table th {
    position: sticky;
    top: 0;
    background: #f7f9fc;
    z-index: 1;
    color: #475467;
    font-size: 12px;
}

.fcap-ledger-table tr:last-child td {
    border-bottom: 0;
}

.fcap-ledger-table tr.is-open-debit {
    background: #fffdf7;
}

.fcap-ledger-table tr.has-payment-request {
    background: #f8fbff;
}

.fcap-ledger-check-col {
    width: 66px;
    text-align: center !important;
}

.fcap-ledger-movement-check {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.fcap-ledger-reference {
    font-weight: 700;
    direction: ltr;
    display: inline-block;
}

.fcap-ledger-details {
    min-width: 180px;
    white-space: normal !important;
    line-height: 1.45;
}

.fcap-ledger-details small {
    display: block;
    margin-top: 4px;
    color: #667085;
}

.fcap-money-cell {
    direction: ltr;
    text-align: left !important;
    font-variant-numeric: tabular-nums;
}

.fcap-money-cell.is-debit {
    color: #b42318;
}

.fcap-money-cell.is-credit {
    color: #067647;
}

.fcap-money-cell.is-neutral {
    color: #475467;
    font-weight: 600;
}

.fcap-money-cell .fcap-ledger-neutral-note,
.fcap-ledger-neutral-note {
    display: block;
    margin-top: 2px;
    color: #667085;
    font-size: 11px;
    direction: rtl;
}

.fcap-ledger-row.is-neutral {
    background: #f8fafc;
}

.fcap-ledger-status.is-neutral {
    background: #f2f4f7;
    color: #475467;
}

.fcap-ledger-status {
    display: inline-flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    padding: 5px 8px;
    border-radius: 999px;
    background: #f2f4f7;
    color: #475467;
    line-height: 1.15;
}

.fcap-ledger-status small {
    font-size: 10px;
    opacity: .8;
}

.fcap-ledger-status.is-open {
    background: #fff3cd;
    color: #7a4d00;
}

.fcap-ledger-status.is-requested {
    background: #eaf2ff;
    color: #175cd3;
}

.fcap-ledger-status.is-paid,
.fcap-ledger-status.is-closed {
    background: #ecfdf3;
    color: #067647;
}

.fcap-ledger-status.is-credit {
    background: #f4ebff;
    color: #6941c6;
}

.fcap-ledger-selection {
    margin-top: 16px;
    padding: 16px;
    border: 1px solid #cddcff;
    border-radius: 12px;
    background: #f7f9ff;
}

.fcap-ledger-selection-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 14px;
}

.fcap-ledger-selection-summary small,
.fcap-ledger-selection-summary strong {
    display: block;
}

.fcap-ledger-selection-summary small {
    color: #667085;
    margin-bottom: 3px;
}

.fcap-ledger-selection-summary strong {
    font-size: 18px;
}

.fcap-ledger-payment-fields {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    margin-bottom: 12px;
}

.fcap-ledger-payment-fields textarea {
    width: 100%;
}

@media (max-width: 900px) {
    .fcap-ledger-heading {
        flex-direction: column;
    }
    .fcap-ledger-balance {
        width: 100%;
    }
    .fcap-ledger-summary {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .fcap-ledger-select-tools,
    .fcap-ledger-selection-summary {
        align-items: flex-start;
        flex-direction: column;
    }
}

@media (max-width: 520px) {
    .fcap-ledger-panel {
        padding: 14px;
    }
    .fcap-ledger-toolbar label,
    .fcap-ledger-toolbar .fcap-button {
        width: 100%;
    }
    .fcap-ledger-summary {
        grid-template-columns: 1fr;
    }
}


/* v0.9.1 — full-width desktop + ledger refinements */
@media (min-width: 1200px) {
    .fcap-portal {
        width: calc(100vw - 24px);
        max-width: none;
        margin: 24px calc(50% - 50vw + 12px);
        padding-left: 0;
        padding-right: 0;
    }
    .fcap-portal-main {
        width: 100%;
        max-width: none;
    }
}
.fcap-ledger-open-only{display:flex!important;align-items:center;gap:8px;min-height:42px;padding:0 10px;margin:0;font-weight:700;color:#334155;white-space:nowrap;flex-wrap:wrap}.fcap-ledger-open-only small{width:100%;font-size:11px;font-weight:500;color:#64748b}.fcap-ledger-date-help{display:block;margin-top:3px;color:#94a3b8;font-size:11px;font-weight:500}.fcap-ledger-panel.is-open-only .fcap-ledger-date-help:after{content:" · ריק = ללא הגבלה"}.fcap-ledger-open-only input{margin:0}.fcap-ledger-table tr.is-open-credit{background:#f0fdf4}.fcap-ledger-document-link{border:0;background:none;padding:0;color:#1d4ed8;text-decoration:underline;font:inherit;font-weight:800;cursor:pointer}.fcap-ledger-document-link:hover{color:#1e40af}.fcap-document-open{overflow:hidden}.fcap-ledger-document-modal[hidden]{display:none!important}.fcap-ledger-document-modal{position:fixed;inset:0;z-index:999999;display:flex;align-items:center;justify-content:center;padding:24px}.fcap-ledger-document-backdrop{position:absolute;inset:0;background:rgba(15,23,42,.62)}.fcap-ledger-document-dialog{position:relative;z-index:1;width:min(1180px,96vw);max-height:92vh;overflow:auto;background:#fff;border-radius:16px;box-shadow:0 28px 80px rgba(15,23,42,.35);padding:28px}.fcap-ledger-document-close{position:sticky;top:0;float:left;z-index:3;border:0;background:#0f172a;color:#fff;width:38px;height:38px;border-radius:50%;font-size:28px;line-height:1;cursor:pointer}.fcap-document-view{clear:both;padding-top:4px}.fcap-document-head{display:flex;align-items:flex-start;justify-content:space-between;gap:20px;padding-bottom:18px;border-bottom:1px solid #e2e8f0}.fcap-document-head h3{margin:4px 0 2px;font-size:26px}.fcap-document-head p{margin:0;color:#64748b}.fcap-document-total{text-align:left;background:#f8fafc;border:1px solid #e2e8f0;border-radius:12px;padding:12px 16px}.fcap-document-total small,.fcap-document-total strong{display:block}.fcap-document-total strong{font-size:22px;margin-top:3px}.fcap-document-customer{display:grid;grid-template-columns:1.2fr 1.5fr 1fr;gap:16px;padding:18px 0}.fcap-document-customer>div{display:flex;flex-direction:column;gap:4px}.fcap-document-customer span{color:#64748b}.fcap-document-allocation{direction:ltr;text-align:right;word-break:break-all}.fcap-document-items-wrap{overflow:auto;border:1px solid #e2e8f0;border-radius:12px}.fcap-document-items{width:100%;border-collapse:collapse;min-width:900px}.fcap-document-items th,.fcap-document-items td{padding:10px 12px;border-bottom:1px solid #eef2f7;text-align:right;vertical-align:top}.fcap-document-items th{background:#f8fafc;white-space:nowrap}.fcap-document-items tr:last-child td{border-bottom:0}.fcap-document-totals{width:min(420px,100%);margin:18px 0 0 auto;background:#f8fafc;border:1px solid #e2e8f0;border-radius:12px;padding:12px 16px}.fcap-document-totals>div{display:flex;justify-content:space-between;gap:20px;padding:7px 0;border-bottom:1px solid #e2e8f0}.fcap-document-totals>div:last-child{border-bottom:0}.fcap-document-totals .is-grand{font-size:18px}.fcap-document-totals .is-grand strong{font-size:21px}@media(max-width:760px){.fcap-ledger-document-modal{padding:8px}.fcap-ledger-document-dialog{width:100%;max-height:96vh;padding:18px}.fcap-document-head{flex-direction:column}.fcap-document-total{width:100%;text-align:right}.fcap-document-customer{grid-template-columns:1fr}.fcap-ledger-toolbar{align-items:stretch}.fcap-ledger-open-only{padding:8px 0}}

/* v1.3.1 — responsive ledger cards on mobile (agent portal). */
@media (max-width: 767px) {
    .fcap-ledger-table-wrap {
        overflow: visible;
        border: 0;
        border-radius: 0;
        background: transparent;
    }
    .fcap-ledger-table {
        display: block;
        min-width: 0;
        width: 100%;
        background: transparent;
    }
    .fcap-ledger-table thead {
        display: none;
    }
    .fcap-ledger-table tbody {
        display: grid;
        gap: 12px;
        width: 100%;
    }
    .fcap-ledger-table tr.fcap-ledger-row {
        display: block;
        width: 100%;
        padding: 10px 14px;
        border: 1px solid #e1e7ef;
        border-radius: 12px;
        background: #fff;
        box-sizing: border-box;
        box-shadow: 0 2px 8px rgba(15, 23, 42, .04);
    }
    .fcap-ledger-table tr.fcap-ledger-row.is-open-debit { background: #fffdf7; }
    .fcap-ledger-table tr.fcap-ledger-row.is-open-credit { background: #f0fdf4; }
    .fcap-ledger-table tr.fcap-ledger-row.is-neutral { background: #f8fafc; }
    .fcap-ledger-table tr.fcap-ledger-row.has-payment-request { border-color: #bfd4ff; }
    .fcap-ledger-table td,
    .fcap-ledger-table td.fcap-money-cell,
    .fcap-ledger-table td.fcap-ledger-check-col {
        display: grid;
        grid-template-columns: minmax(92px, 36%) minmax(0, 1fr);
        align-items: start;
        gap: 10px;
        width: 100%;
        min-width: 0;
        padding: 8px 0;
        border: 0;
        border-bottom: 1px solid #edf0f4;
        text-align: right !important;
        white-space: normal;
        box-sizing: border-box;
        direction: rtl;
    }
    .fcap-ledger-table td:last-child { border-bottom: 0; }
    .fcap-ledger-table td::before {
        content: attr(data-label);
        color: #667085;
        font-size: 12px;
        font-weight: 700;
        line-height: 1.45;
    }
    .fcap-ledger-table td > * { min-width: 0; }
    .fcap-ledger-table td.fcap-money-cell,
    .fcap-ledger-table td.fcap-money-cell strong {
        font-variant-numeric: tabular-nums;
    }
    .fcap-ledger-table td.fcap-money-cell > strong,
    .fcap-ledger-table td.fcap-money-cell > span,
    .fcap-ledger-table td.fcap-money-cell:not(:has(> strong)):not(:has(> span)) {
        text-align: right;
    }
    .fcap-ledger-table .fcap-ledger-document-link,
    .fcap-ledger-table .fcap-ledger-reference {
        justify-self: start;
        white-space: normal;
        direction: rtl;
        text-align: right;
    }
    .fcap-ledger-table .fcap-ledger-status {
        justify-self: start;
        max-width: 100%;
        white-space: normal;
    }
    .fcap-ledger-table .fcap-ledger-details {
        line-height: 1.55;
    }
    .fcap-ledger-check-col .fcap-ledger-movement-check {
        justify-self: start;
    }
}

/* v1.3.35 — customer negative-balance filter */
.fcap-customer-filter{display:inline-flex;align-items:center;gap:7px;min-height:46px;padding:0 12px;border:1px solid #cbd5e1;border-radius:10px;background:#fff;color:#334155;font-size:13px;font-weight:600;white-space:nowrap;cursor:pointer;box-sizing:border-box}
.fcap-customer-filter input{margin:0;flex:0 0 auto}
@media(max-width:760px){.fcap-customer-filter{width:100%;justify-content:flex-start}}


/* v1.3.36 — agent customer quick actions + payment ledger */
.fcap-customer-row-actions{display:flex;flex-direction:column;gap:6px;align-items:stretch;min-width:128px}
.fcap-customer-row-actions .fcap-row-action{width:100%;box-sizing:border-box}
.fcap-row-action-order{background:#ecfdf5;color:#047857}
.fcap-row-action-payment{background:#fff7ed;color:#9a3412}
.fcap-payment-request-builder{margin-top:16px}
.fcap-payment-balance-grid + .fcap-ledger-panel{margin-top:16px}
@media(max-width:1180px){.fcap-customer-row-actions{flex-direction:row;flex-wrap:wrap;grid-column:1/-1}.fcap-customer-row-actions .fcap-row-action{width:auto}}
@media(max-width:760px){.fcap-customer-row-actions{flex-direction:column}.fcap-customer-row-actions .fcap-row-action{width:100%}}


/* v1.3.39 — unified ledger/payment request builder */
.fcap-ledger-payment-context-hint {
    margin: 10px 0 0;
    color: #667085;
    font-size: 13px;
}
.fcap-payment-request-builder input[data-fcap-ledger-locked="1"] {
    background: #f7f9fc;
    cursor: default;
}


/* v1.3.39 — agent UPS PickUP selector */
.fcap-agent-pickup-selector {
    border: 1px solid #d9e3f5;
    border-radius: 14px;
    padding: 14px;
    background: #f8fbff;
}
.fcap-agent-pickup-heading {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
}
.fcap-agent-pickup-heading span { color: #667085; font-size: 12px; }
.fcap-agent-pickup-points { display: grid; gap: 8px; margin-top: 10px; }
.fcap-agent-pickup-point {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 12px;
    border: 1px solid #d0d5dd;
    border-radius: 10px;
    background: #fff;
    cursor: pointer;
}
.fcap-agent-pickup-point.is-selected { border-color: #344054; box-shadow: 0 0 0 1px #344054 inset; }
.fcap-agent-pickup-point input { margin-top: 4px; }
.fcap-agent-pickup-point span { display: grid; gap: 3px; }
.fcap-agent-pickup-point small { color: #667085; }

/* v1.3.40 — full PickUP map action in agent order builder */
.fcap-agent-pickup-map-actions {
    margin-top: 12px;
    display: flex;
    justify-content: flex-start;
}
.fcap-agent-pickup-map-link {
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 3px;
    cursor: pointer;
}
