:root{--ink:#19344d;--blue:#236f9c;--navy:#183855;--yellow:#ffd044;--line:#e3eaf1;--soft:#f1f5f9}
body{background:#f2f6fa;color:var(--ink);font-size:15px}
.ui-icon{flex-shrink:0;vertical-align:middle;display:inline-block}
.app-layout{grid-template-columns:228px minmax(0,1fr)}
.sidebar{background:linear-gradient(155deg,#183650,#214f73);padding:24px 16px;color:white}
.brand{display:block;padding:0 9px 23px}
.brand-logo{display:block;background:white;border-radius:9px;padding:9px 10px;border-bottom:3px solid var(--yellow)}
.brand-logo img{display:block;width:100%;height:auto}
.brand small{display:block;text-transform:uppercase;letter-spacing:2.2px;color:#9fbdd3;font-size:9px;margin:12px 3px 0}
.nav-caption{color:#8daec6;font-size:10px;letter-spacing:1.8px;padding:18px 12px 10px}
.nav{gap:7px}.nav a{padding:11px 12px;border-radius:10px;gap:12px;color:#d4e5f2}
.nav a.active{background:#ffffff17;box-shadow:inset 3px 0 var(--yellow);color:white}
.nav-symbol{display:grid;place-items:center;width:30px;height:30px;border-radius:8px;background:#ffffff0c;color:#79bde2}
.nav a[href='#quotes'] .nav-symbol{color:#ffdb65}.nav a[href='#jobs'] .nav-symbol{color:#bdabfa}.nav a[href='#documents'] .nav-symbol{color:#6fe0db}.nav a[href='#purchases'] .nav-symbol{color:#f5b3a2}.nav a[href='#stock'] .nav-symbol{color:#98dba9}.nav a[href='#catalog'] .nav-symbol{color:#aad6f6}
.topbar{height:64px;background:#ffffffdb;border-bottom:1px solid var(--line);font-size:12px}
.content{padding:30px 30px 54px;max-width:1700px}
.page-head{margin-bottom:26px}.page-head h1{font-size:29px;letter-spacing:-.8px}.eyebrow{font-size:10px;color:#8194a5;letter-spacing:1.5px}
.card{border:1px solid var(--line);border-radius:14px;box-shadow:0 5px 18px #23446305;padding:23px}
.card+.card{margin-top:18px}button,.button{border-radius:9px;border-color:#dce5ee;padding:9px 13px;font-size:13px;font-weight:600;transition:background .15s,border-color .15s,box-shadow .15s}
button:hover,.button:hover{box-shadow:0 3px 10px #27476009}button.primary,.button.primary{background:#246f9c;border-color:#246f9c;box-shadow:0 3px 8px #236f9c20}.primary:hover{background:#1b5b82}
.plain{border-color:transparent}.small{padding:5px 9px;font-size:12px}input,select,textarea{border-radius:8px;border-color:#dce5ee;background:#fcfdff;font-size:13px;padding:10px 11px}input:focus,textarea:focus,select:focus{background:white;border-color:#5b9fc4;box-shadow:0 0 0 3px #2c80ae14}
.metric{border-top:0;position:relative;overflow:hidden;padding:20px}.metric:before{content:'';height:4px;position:absolute;top:0;left:0;right:0;background:#68a9d1}.metric:nth-child(2):before{background:#a494da}.metric:nth-child(3):before{background:#6cbb9e}.metric:nth-child(4):before{background:#e8be5a}
.metric-value{font-size:33px;color:#1b405f}.metric-label{font-size:13px;font-weight:600;color:#60788e}.metric .subtext{font-size:12px}.metric-icon{float:right;color:#5b99bf;background:#edf5fb;border-radius:10px;padding:8px;margin-left:8px;line-height:0}.metric:nth-child(2) .metric-icon{color:#8c78b9;background:#f3effa}.metric:nth-child(3) .metric-icon{color:#4b9d81;background:#edf8f3}.metric:nth-child(4) .metric-icon{color:#b48d31;background:#fff8e5}
.notice{border-radius:10px;font-size:13px;line-height:1.6}.notice.info{background:#edf6fc;border-color:#d8eaf6;color:#476f8e}
.table th{background:#f4f7fb;color:#7690a6;font-size:11px;padding:13px 15px}.table td{padding:16px 15px;border-color:#edf1f5}.table .title-link{font-size:14px;color:#294e6b}.table tbody tr:hover{background:#f7fbfe}.table small{display:block;margin-top:4px}.pill{border-radius:7px;font-size:11px;padding:5px 9px}
.quote-header{padding:23px;margin-bottom:24px;border-top:3px solid #3c88b1}.quote-title-input{background:transparent;font-size:22px;font-weight:650;margin-bottom:20px;padding:0;line-height:1.5}.quote-top-fields{grid-template-columns:1.6fr .8fr 1fr}.pricing-fields{grid-template-columns:80px 1fr 100px 132px 95px 155px;gap:13px;align-items:end}
.labor-total{background:#f3f7ff;border-left:3px solid #9a9be1;border-radius:0 9px 9px 0;padding:10px 12px;min-height:68px;font-size:11px}.labor-total b{font-size:18px;margin-top:6px}.internal-tag{background:#e9eef5;color:#8190a2;border-radius:4px;font-size:10px;padding:2px 4px}
.editor-grid{grid-template-columns:138px minmax(0,1fr) 248px;gap:17px}.categories-nav .eyebrow{font-size:10px}.categories-nav a{font-size:12px}.categories-nav button{font-size:12px}.summary{padding:20px;border-top:3px solid #edc243}.summary-line{font-size:12px;margin:14px 0}.summary-line b{color:#254860}.summary-total{background:linear-gradient(130deg,#20476a,#1e628a);border-radius:11px;padding:16px;color:#d0e5f3;font-size:12px}.summary-total b{color:white;font-size:29px;letter-spacing:-.5px;margin-top:7px}.summary hr{border:0;border-top:1px solid #edf1f6;margin:20px 0}.summary .eyebrow{color:#56758e}
.category-card{border-radius:12px;border-color:#dfe8f0;box-shadow:0 4px 14px #23446303}.category-head{background:#fff;padding:13px 12px;border-bottom:1px solid #e7edf4}.category-head input{background:transparent;font-size:14px;font-weight:650}.category-total{font-size:12px;color:#2d658a}.items-table th{background:#f4f8fc;color:#7e94a6;font-size:10px;font-weight:500;padding-top:10px;padding-bottom:10px}.items-table td{padding-top:10px;padding-bottom:10px}.items-table input,.items-table textarea{font-size:12px;background:transparent}.items-table input:focus,.items-table textarea:focus{background:white}.items-table textarea.item-name{min-height:32px;height:36px;padding:2px 0}.item-meta{font-size:10px;line-height:1.5}.visibility-badge{font-size:10px;line-height:1.5;color:#567b94}.visibility-button{font-size:10px;padding:2px 0}.items-table .bundle-row{background:#edf7fd;border-left:3px solid #428cb7}.items-table .internal-row{background:#f3f5f8}.items-table .text-row td{background:#fffaf0}.items-table .quote-text-input{min-height:50px;height:58px;padding:5px 8px}.text-row-content .item-meta{color:#a0843c}.row-sum{font-variant-numeric:tabular-nums}.photo-placeholder{border-radius:7px;background:#f8fbfe;color:#91a8b9}.category-footer{background:#fff;padding:9px 12px;border-radius:0 0 12px 12px}.add-bar{border-radius:11px;color:#6490b0;border-color:#cedeea;background:#f7fafc}
.items-table td{padding-top:7px;padding-bottom:7px}.items-table .row-sum{padding-top:16px!important}.items-table .visibility-badge{margin-top:2px}.items-table th.pdf-visibility,.items-table td.pdf-visibility{text-align:center}.items-table .pdf-visibility .visibility-button{min-height:28px;min-width:52px;padding:3px 7px;font-size:11px;line-height:1.4;border-radius:6px;border:1px solid #c6dfd3;background:#edf7f1;color:#28654b}.items-table .pdf-visibility .is-hidden{border-color:#d6e0e9;background:#f5f7fa;color:#62758a}.items-table .pdf-visibility .visibility-button:hover{border-color:#87aebf;background:#e8f1f7;color:#244e70}.items-table .text-row-content{padding:0}.items-table .quote-text-input{min-height:48px;height:50px}
.items-table textarea.item-name{min-height:44px;height:44px}
@supports(field-sizing:content){.items-table textarea.item-name{field-sizing:content;min-height:24px;height:auto}}
.tabs{gap:7px;margin-bottom:20px}.tabs .button{background:#fff;border-color:#e1e8f0}.tabs .primary{background:#246f9c;color:white}.result{border-radius:9px}.result:hover{background:#f4f9fd}.modal-head{background:#f5f9fc;border-bottom:1px solid #e2ebf3}.modal-head h2{font-size:20px;color:#234867}dialog{border-radius:16px;border:1px solid #dce6ef;box-shadow:0 30px 90px #102a4536}.modal-footer{background:#f8fafc;border-top:1px solid #e4ebf1}.document-preview{border-top:3px solid #63b3b3}.pdf-canvas-host{background:#e9eff5;border-radius:10px;padding:12px}.auth-side{background:linear-gradient(145deg,#193752,#2e769f)}
@media(max-width:1450px){.editor-grid{grid-template-columns:minmax(0,1fr) 245px}.categories-nav{display:none}.pricing-fields{grid-template-columns:75px 1.2fr 90px 118px 90px 145px}.content{padding:27px 23px}.app-layout{grid-template-columns:210px minmax(0,1fr)}}
@media(max-width:1150px){.pricing-fields{grid-template-columns:repeat(3,1fr)}.app-layout{grid-template-columns:185px minmax(0,1fr)}.sidebar{padding:24px 10px}.brand{padding:0 6px 18px}.editor-grid{grid-template-columns:minmax(0,1fr)}.summary{position:static}.metrics{grid-template-columns:repeat(2,1fr)}}
@media(max-width:850px){.app-layout{display:block}.sidebar{display:none}.content{padding:24px 18px}.quote-top-fields{grid-template-columns:1fr 1fr}.topbar{padding:0 20px}.editor-grid{display:block}.summary{margin-top:18px}}
@media(max-width:650px){.content{padding:20px 12px}.quote-top-fields{grid-template-columns:1fr}.pricing-fields{grid-template-columns:1fr 1fr}.quote-header,.card{padding:17px}.page-head h1{font-size:26px}.metrics{gap:10px}.metric{padding:16px}.metric-value{font-size:29px}.editor-grid .summary{padding:20px}.quote-title-input{font-size:19px}}

.isdoc-original{padding:24px;background:white;text-align:left}.isdoc-original .result{align-items:flex-start;border-bottom:1px solid #e1e9f0;padding:12px 0}.isdoc-original strong{white-space:nowrap}.isdoc-summary{border-top:4px solid #2d769e}.isdoc-summary .notice{overflow-wrap:anywhere}

.document-source-details{display:grid;gap:.2rem;margin:.35rem 0 .8rem;overflow-wrap:anywhere}.document-source-details:empty{display:none}.document-source-details small{display:block}

.items-table .duplicate-item-row>td{background:#fff4dc;border-bottom-color:#eed6a6}.items-table .duplicate-item-row>.product-cell{box-shadow:inset 3px 0 #d89823}.duplicate-item-note{display:inline-block;margin-top:4px;padding:2px 6px;border-radius:5px;background:#ffe4ad;color:#7d4d09;font-size:10px;font-weight:600;line-height:1.5}

/* An import requiring attention remains visible until it is resolved. */
.table tr.intake-attention td {background:#fff4e5;border-bottom-color:#f2c376}.table tr.intake-attention td:first-child {border-left:4px solid #d88000}.table tr.intake-attention .button {margin:3px}

.pricing-fields{grid-template-columns:80px 150px 105px 155px;max-width:630px}.category-head .category-name{flex:1}.category-markup{display:grid;grid-template-columns:auto 62px auto;align-items:center;gap:5px;flex:none;font-size:11px;color:#60758a}.category-markup input{width:62px;padding:5px 7px!important;text-align:right;border:1px solid #cbd8e3!important;background:#fff!important;font-size:12px!important;font-weight:650!important}.category-markup b{font-size:11px}.category-pricing-legacy{padding:5px 8px;font-size:11px;color:#426985;background:#f3f7fa;border-color:#d8e3eb}@media(max-width:1150px){.pricing-fields{grid-template-columns:repeat(2,minmax(0,1fr));max-width:none}}

/* Supplier choices retain native form values while displaying locally cached website favicons. */
.supplier-field{display:grid;gap:7px;min-width:0;font-size:13px;color:#5b6f83}.modal-body .supplier-field{margin-bottom:12px}.supplier-field>select[hidden]{display:none}.supplier-field-label{cursor:default}.supplier-choice-trigger{display:flex;align-items:center;gap:10px;width:100%;min-width:0;min-height:42px;padding:9px 11px;text-align:left;font-weight:400;background:#fcfdff;color:#4e6980;border:1px solid #dce5ee;border-radius:8px}.supplier-choice-trigger:focus-visible,.supplier-choice-trigger[aria-expanded=true]{outline:0;background:#fff;border-color:#5b9fc4;box-shadow:0 0 0 3px #2c80ae14}.supplier-choice-trigger:disabled{opacity:.65;cursor:default}.supplier-choice-trigger[aria-invalid=true]{border-color:#bf4949}.supplier-choice-text{min-width:0;flex:1;line-height:1.45}.supplier-choice-trigger .supplier-choice-text{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.supplier-favicon,.supplier-choice-symbol{width:20px;height:20px;flex:0 0 20px;object-fit:contain}.supplier-choice-symbol{display:inline-flex;align-items:center;justify-content:center;color:#66869e}.supplier-choice-arrow{flex:none;color:#71899a}.supplier-choice-list{position:fixed;inset:auto;margin:0;padding:5px;box-sizing:border-box;max-width:calc(100vw - 24px);max-height:360px;overflow:auto;overscroll-behavior:contain;background:#fff;border:1px solid #ccdce8;border-radius:10px;box-shadow:0 12px 35px #163b5930;z-index:200;color:#244e70}.supplier-choice-list[hidden]{display:none}.supplier-choice-option{display:flex;align-items:center;gap:10px;padding:10px 9px;min-height:42px;font-size:13px;border-radius:6px;cursor:pointer}.supplier-choice-option:hover,.supplier-choice-option.is-active{background:#edf5fb}.supplier-choice-option[aria-selected=true]{background:#e9f4fb;font-weight:600}.supplier-choice-option[aria-disabled=true]{opacity:.5;cursor:default}.supplier-choice-check{width:16px;flex:0 0 16px;color:#246f9c}.supplier-choice-error[hidden]{display:none}

#settings-content>.section-head,#settings-content .card>.section-head{flex-wrap:wrap}#settings-content p{overflow-wrap:anywhere}

/* Product presentation: the same saved photos and descriptions as the customer PDF. */
.quote-header .quote-display-fields{grid-template-columns:120px minmax(240px,330px);max-width:470px;gap:18px}
.document-type-control{display:flex;align-items:center;gap:18px;flex-wrap:wrap;margin-bottom:20px}
.document-type-switch{display:flex;gap:3px;padding:4px;border:1px solid #d2e2ee;border-radius:10px;background:#f1f6fa;flex:none}
.document-type-switch button{border:0;background:transparent;padding:9px 19px;border-radius:7px;font-weight:650;box-shadow:none}
.document-type-switch button[aria-pressed="true"]{background:#226f9c;color:#fff;box-shadow:0 2px 5px #193f5a1a}
.document-type-control p{margin:0;flex:1;min-width:200px}
.offer-editor .product-presentation-editor .items-table{min-width:1032px}
.product-presentation-editor .items-table{min-width:1140px}
.product-presentation-editor .product-content{align-items:flex-start;gap:10px}
.product-presentation-editor .item-photo{width:76px;height:76px;max-width:76px;max-height:76px;object-fit:contain;background:white;border:1px solid #e3ebf1;border-radius:8px;padding:5px;flex:0 0 76px}
.product-presentation-editor .product-text{min-width:180px}
.product-description-field{display:block;margin:5px 0 8px}
.product-description-field>span{display:block;font-size:10px;color:#678098;margin-bottom:4px}
.items-table .product-description-field textarea.item-description{display:block;width:100%;min-height:72px;line-height:1.5;padding:7px 9px;background:#f8fbfe;border:1px solid #dce6ef;border-radius:7px;resize:vertical}
@supports(field-sizing:content){.items-table .product-description-field textarea.item-description{field-sizing:content;max-height:260px}}
@media(max-width:650px){.quote-header .quote-display-fields{grid-template-columns:1fr;max-width:none}.product-presentation-editor .items-table{min-width:1140px}}

.product-description-field label>span{display:block;font-size:10px;color:#678098;margin-bottom:4px}
.description-actions{display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin-top:5px}
.description-actions .visibility-button{font-size:10px;padding:2px 6px;border-radius:6px;border:1px solid #c6dfd3;background:#edf7f1;color:#28654b}
.description-actions .is-hidden{border-color:#d6e0e9;background:#f5f7fa;color:#62758a}
.description-excluded textarea{color:#8190a2!important}

/* Match the row and inclusion control to its current PDF visibility. */
.items-table tr[data-row]:not(.duplicate-item-row):has(>td.pdf-visibility>.is-visible)>td{background:#f1f9f4;border-bottom-color:#d8eadd}
.items-table tr[data-row]:not(.duplicate-item-row):has(>td.pdf-visibility>.is-hidden)>td{background:#fff2f3;border-bottom-color:#f0d6da}
.items-table .pdf-visibility .visibility-button.is-visible,.description-actions .visibility-button.is-visible{background:#e6f5ec;border-color:#b8dcc7;color:#216340}
.items-table .pdf-visibility .visibility-button.is-hidden,.description-actions .visibility-button.is-hidden{background:#fde8eb;border-color:#edbec6;color:#9b293b}
.items-table .pdf-visibility .visibility-button.is-visible:hover,.description-actions .visibility-button.is-visible:hover{background:#d8efe1;border-color:#8abfa0;color:#174e30}
.items-table .pdf-visibility .visibility-button.is-hidden:hover,.description-actions .visibility-button.is-hidden:hover{background:#fad9df;border-color:#d995a1;color:#7c1f2f}

/* Keep product text readable; scroll only the table when its columns no longer fit. */
.editor-grid>div,#category-list,.category-card{min-width:0;max-width:100%}
#category-list{--item-product-width:423px;--item-stock-width:108px;--item-cost-width:77px}
.offer-editor #category-list{--item-stock-width:0px}
#category-list.quote-cost-hidden{--item-cost-width:0px}
#category-list.product-presentation-editor{--item-product-width:463px}
#category-list .items-table{min-width:calc(var(--item-product-width) + 492px + var(--item-stock-width) + var(--item-cost-width))}
.category-card>.drop-zone{min-width:0;max-width:100%;overflow-x:auto;overscroll-behavior-x:contain}
.category-card .category-head{min-width:0;flex-wrap:wrap}
.category-head .category-name{min-width:0;flex:1 1 160px}
.category-head .category-total{margin-left:auto}
.categories-nav{min-width:0}
.categories-nav>a{min-width:0;gap:8px;overflow-wrap:anywhere}
.categories-nav>a>span{flex:none;margin-left:auto}
.categories-nav>button{width:100%;min-width:0;white-space:normal;overflow-wrap:anywhere;text-align:left;justify-content:flex-start;padding:8px 10px}
.items-table .product-content,.items-table .product-text{min-width:0;max-width:100%}
#category-list .photo-placeholder{width:34px;height:39px;flex:0 0 34px}
#category-list.product-presentation-editor .photo-placeholder{width:76px;height:76px;flex:0 0 76px}
.items-table .product-text,.items-table .fee-row-text{overflow-wrap:anywhere;white-space:normal}
.product-presentation-editor .fee-row-name{grid-template-columns:118px minmax(0,1fr)}
.items-table .item-meta{flex-wrap:wrap;gap:2px 5px;white-space:normal;overflow-wrap:anywhere}
.items-table .item-meta>a{min-width:0;overflow-wrap:anywhere}
.items-table th{white-space:nowrap}
.items-table th:nth-child(2),.items-table th:nth-child(3),.items-table td:nth-child(2),.items-table td:nth-child(3),.items-table td:nth-child(2)>input,.items-table td:nth-child(3)>input{text-align:center}
@media(max-width:1450px){.editor-grid{grid-template-columns:minmax(0,1fr)}.editor-grid>.summary{position:static}}
@media(max-width:650px){.toolbar>label{flex:1 1 130px;min-width:0;max-width:100%}.toolbar>.grow{flex-basis:100%;min-width:0}.page-footer{flex-wrap:wrap;gap:10px}}
.attachment-toolbar{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin:14px 0}
.attachment-list{display:grid;gap:10px;min-width:0}
.attachment-card{display:flex;gap:12px;padding:12px;border:1px solid var(--line,#dce5ee);border-radius:10px;min-width:0}
.attachment-picture{display:grid;place-items:center;flex:0 0 64px;width:64px;height:64px;overflow:hidden;border:1px solid var(--line,#dce5ee);border-radius:8px;background:#f2f7fb;text-decoration:none}
.attachment-picture img{display:block;max-width:100%;max-height:100%;object-fit:contain}
.attachment-picture span{font-size:28px}
.attachment-description{flex:1;min-width:0;overflow-wrap:anywhere}
.attachment-description>b,.attachment-description>small{display:block}
.attachment-description>small{margin:4px 0 8px;color:#6b8197;font-size:12px}

.customer-name-field{min-width:0}
.customer-name-field>label{display:block}
.customer-name-field>button{margin-top:4px}
.ares-ico-field{display:flex;align-items:flex-end;gap:8px;flex-wrap:wrap;margin-top:12px}
.ares-ico-field>label{flex:1 1 130px;min-width:0;margin:0}
.ares-ico-field>button{flex:0 0 auto}
.ares-result{min-width:0;overflow-wrap:anywhere}
.ares-result p{margin:8px 0}
.ares-result .actions{flex-wrap:wrap}

/* VAT labels wrap within the summary while monetary values stay on one line. */
.summary-line>span{min-width:0}.summary-line>b{flex-shrink:0;white-space:nowrap}
