:root{--nav:#003e7b;--primary:#003E7B;--success:#198754;--warning:#FFC107;--info:#0DCAF0;--accent:#FAAA16;--danger:#DC3545;--bg:#f4f6fa;--border:#dce1ea;--text:#202633;--muted:#687083;--ok:#198754;--warn:#FFC107}*{box-sizing:border-box}body{margin:0;font-family:Arial,sans-serif;background:var(--bg);color:var(--text)}a{color:var(--primary);text-decoration:none}.sidebar{position:fixed;inset:0 auto 0 0;width:230px;background:var(--nav);padding:24px 16px;display:flex;flex-direction:column;gap:7px}.sidebar .brand{color:#fff;font-size:22px;font-weight:700;padding:8px 12px 25px}.sidebar a{color:#dfe5f2;padding:12px;border-radius:8px}.sidebar a:hover{background:rgba(255,255,255,.14)}.admin-main{margin-left:230px;padding:32px;min-height:100vh}.public-main{min-height:100vh}.page-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:25px}.page-head h1,.narrow h1{margin:0 0 5px}.page-head p,.narrow>p{margin:0;color:var(--muted)}.button,button{border:1px solid var(--info);background:var(--info);color:#073642;padding:10px 16px;border-radius:8px;font-weight:700;cursor:pointer;display:inline-block}.button:hover,button:hover{filter:brightness(.96)}.primary{background:var(--primary);border-color:var(--primary);color:#fff}.success{background:var(--success)!important;border-color:var(--success)!important;color:#fff!important}.warning{background:var(--warning)!important;border-color:var(--warning)!important;color:#342600!important}.info{background:var(--info)!important;border-color:var(--info)!important;color:#073642!important}.accent{background:var(--accent)!important;border-color:var(--accent)!important;color:#342600!important}.cancel,.danger-button{background:var(--danger)!important;border-color:var(--danger)!important;color:#fff!important}.wide{width:100%}.large{padding:14px 22px;font-size:16px}.stats{display:grid;grid-template-columns:repeat(4,1fr);gap:16px;margin-bottom:24px}.stat,.panel,.doc-card,.login-card,.complete-card{background:#fff;border:1px solid var(--border);border-radius:12px;box-shadow:0 4px 14px rgba(25,34,55,.05)}.stat{padding:20px}.stat b{font-size:30px;display:block}.stat span{color:var(--muted);text-transform:capitalize}.panel{padding:22px}.panel h2{margin-top:0}.table-wrap{overflow:auto}table{width:100%;border-collapse:collapse}th,td{text-align:left;padding:13px;border-bottom:1px solid var(--border)}th{font-size:13px;color:var(--muted)}.status{padding:5px 9px;border-radius:999px;font-size:12px;font-weight:700;background:#edf0f5}.status.completed{background:#def5e7;color:#13713e}.status.viewed{background:#fff3cc;color:#7d5c00}.status.sent{background:#e9e4ff;color:var(--primary)}.card-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(250px,1fr));gap:18px}.doc-card{padding:20px}.pdf-icon{width:50px;height:60px;background:#e84b4b;color:#fff;display:grid;place-items:center;font-weight:700;border-radius:6px}.doc-card p{color:var(--muted);font-size:14px}.narrow{max-width:850px;margin:0 auto}.form-stack{display:flex;flex-direction:column;gap:18px;margin-top:22px}label{display:flex;flex-direction:column;gap:7px;font-weight:700;font-size:14px}input,textarea,select{width:100%;border:1px solid #cfd5df;border-radius:7px;padding:11px;font:inherit;background:#fff}.two{display:grid;grid-template-columns:1fr 1fr;gap:16px}.notice{background:#e8f2fb;border-left:4px solid var(--primary);padding:13px}.check{flex-direction:row;align-items:center;font-weight:400}.check input{width:auto}.select-doc{flex-direction:row;padding:13px;border:1px solid var(--border);border-radius:8px;align-items:flex-start;margin-bottom:8px}.select-doc input{width:auto}.select-doc span{display:flex;flex-direction:column}.select-doc small,.field-row small,.line-item small{color:var(--muted)}.split{display:grid;grid-template-columns:minmax(480px,1fr) minmax(420px,1fr);gap:22px}.split.equal{grid-template-columns:1fr 1fr}.field-list{max-height:calc(100vh - 110px);overflow:auto;position:sticky;top:20px}.field-row{display:grid;grid-template-columns:1fr 1.3fr auto auto;gap:10px;align-items:center;padding:12px 0;border-bottom:1px solid var(--border)}.field-row>div{display:flex;flex-direction:column}.preview-stack img{width:100%;display:block;margin-bottom:18px;box-shadow:0 2px 12px rgba(0,0,0,.15)}.copy-box{display:flex}.copy-box input{border-radius:7px 0 0 7px}.copy-box button{border-radius:0 7px 7px 0}.line-item{display:flex;justify-content:space-between;padding:11px 0;border-bottom:1px solid var(--border)}.timeline>div{border-left:3px solid var(--primary);padding:0 0 20px 14px;display:grid}.timeline span,.timeline small{color:var(--muted);font-size:12px}.login-card{max-width:430px;margin:10vh auto;padding:34px}.login-card form{display:flex;flex-direction:column;gap:16px;margin:25px 0}.login-card small{color:var(--muted)}.alert{margin:0 0 18px;padding:13px;border-radius:8px}.alert.success{background:#dff4e8;color:#145d35}.alert.danger{background:#fde3e3;color:#8b2424}.sign-header{height:66px;background:#fff;border-bottom:1px solid var(--border);display:flex;justify-content:space-between;align-items:center;padding:0 24px;position:sticky;top:0;z-index:10}.sign-header>div:first-child{display:flex;gap:16px;align-items:center}.sign-header b{font-size:22px;color:var(--primary)}.sign-header span{color:var(--muted)}.sign-layout{display:grid;grid-template-columns:220px 1fr;max-width:1300px;margin:auto}.doc-nav{position:sticky;top:66px;height:calc(100vh - 66px);padding:24px 18px;background:#fff;border-right:1px solid var(--border);display:flex;flex-direction:column;gap:10px}.doc-nav a{padding:10px;border-radius:7px}.doc-nav a:hover{background:#e8f2fb}.documents{padding:28px;max-width:950px}.welcome{background:#fff;border:1px solid var(--border);padding:20px;border-radius:10px;margin-bottom:24px}.documents article>h2{margin-top:35px}.pdf-page{position:relative;background:#fff;margin:0 auto 24px;box-shadow:0 3px 16px rgba(0,0,0,.18);line-height:0}.pdf-page>img{width:100%;display:block}.pdf-field{position:absolute;line-height:normal}.pdf-field input,.signature-trigger{height:100%;min-height:25px;padding:2px 6px;border:2px solid var(--primary);background:rgba(225,238,250,.94);border-radius:3px;font-size:12px}.pdf-field.required input,.pdf-field.required .signature-trigger{border-color:#e8a100;background:rgba(255,247,207,.95)}.pdf-field.checkbox{display:grid;place-items:center}.pdf-field.checkbox input{width:20px;height:20px}.signature-trigger{width:100%;color:var(--primary);padding:0}.final-step{background:#fff;border:1px solid var(--border);padding:28px;border-radius:12px;margin:35px 0}.final-step label{margin:20px 0}.consent{font-size:15px}.modal{position:fixed;inset:0;background:rgba(12,18,30,.7);z-index:100;display:none;align-items:center;justify-content:center}.modal.open{display:flex}.modal-card{background:#fff;border-radius:12px;padding:24px;width:min(700px,92vw)}canvas{width:100%;height:200px;border:1px solid #aeb7c6;touch-action:none;background:#fff}.modal-actions{display:flex;gap:10px;margin-top:14px;justify-content:flex-end}.complete-card{max-width:600px;margin:12vh auto;text-align:center;padding:48px}.tick{width:75px;height:75px;border-radius:50%;background:#dcf5e5;color:var(--ok);display:grid;place-items:center;font-size:42px;margin:0 auto 20px}@media(max-width:900px){.sidebar{position:static;width:auto;flex-direction:row;overflow:auto}.admin-main{margin-left:0;padding:18px}.stats{grid-template-columns:1fr 1fr}.split,.split.equal{grid-template-columns:1fr}.field-list{position:static;max-height:none}.sign-layout{grid-template-columns:1fr}.doc-nav{display:none}.documents{padding:12px}.two{grid-template-columns:1fr}.field-row{grid-template-columns:1fr}.sign-header span{display:none}}
.status.not_interacted{background:#edf0f5;color:#4d5668}.status.signature_pending{background:#fff3cc;color:#7d5c00}.status.id_pending{background:#dcecff;color:#174c86}.help-text{color:var(--muted);font-size:13px;margin-top:-8px}.output-option{font-weight:700;margin:12px 0}.date-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:14px;margin-bottom:22px}.date-grid>div{background:#fff;border:1px solid var(--border);border-radius:10px;padding:16px;display:flex;flex-direction:column;gap:6px}.date-grid small{color:var(--muted)}.download-row{display:flex;justify-content:space-between;align-items:center;padding:13px 0;border-bottom:1px solid var(--border)}.download-row>div{display:flex;flex-direction:column;gap:4px}.download-row small{color:var(--muted)}.metadata-panel{margin-top:22px}.public-shell{max-width:930px;margin:0 auto;padding:28px}.review-shell{max-width:1050px}.public-card{background:#fff;border:1px solid var(--border);border-radius:14px;padding:28px;box-shadow:0 4px 16px rgba(25,34,55,.06)}.public-card>h1{margin-top:0}.stepper{display:flex;gap:8px;margin:0 0 20px;flex-wrap:wrap}.stepper span{background:#e9edf4;color:#657084;padding:9px 14px;border-radius:999px;font-size:13px;font-weight:700}.stepper span.active{background:var(--primary);color:#fff}.stepper span.done{background:#def5e7;color:#13713e}.customer-doc-fields{border:1px solid var(--border);border-radius:10px;padding:18px;display:grid;grid-template-columns:1fr 1fr;gap:16px}.customer-doc-fields legend{font-size:17px;font-weight:700;padding:0 8px}.required-mark,.optional-mark{font-size:11px;margin-left:7px;padding:3px 6px;border-radius:999px}.required-mark{background:#fff0ca;color:#7d5c00}.optional-mark{background:#edf0f5;color:#687083}.choice-line{display:flex;gap:8px;align-items:center;height:42px}.choice-line input{width:auto}.review-document{margin-top:28px}.review-page{width:100%;display:block;margin:0 auto 22px;box-shadow:0 3px 16px rgba(0,0,0,.18)}.review-actions{position:sticky;bottom:0;background:rgba(255,255,255,.96);border-top:1px solid var(--border);padding:16px 0;display:flex;justify-content:flex-end;gap:12px}.signature-sheet{position:fixed;inset:0;background:rgba(12,18,30,.58);z-index:100;display:none;align-items:flex-end}.signature-sheet.open{display:flex}.sheet-inner{background:#fff;width:100%;padding:22px max(24px,calc((100vw - 900px)/2));border-radius:18px 18px 0 0;box-shadow:0 -8px 30px rgba(0,0,0,.25)}.sheet-handle{position:absolute;bottom:calc(min(520px,85vh) - 14px);left:50%;transform:translateX(-50%);width:60px;height:5px;background:#c9ced8;border-radius:99px}.sheet-inner canvas{width:100%;height:220px;border:2px solid #9fa8b8;border-radius:8px;background:#fff;touch-action:none}.sheet-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:15px}.sheet-open{overflow:hidden}.id-card{max-width:680px;margin:0 auto}.complete-card{max-width:720px}.completion-downloads{margin-top:25px;text-align:left}@media(max-width:900px){.date-grid{grid-template-columns:1fr}.customer-doc-fields{grid-template-columns:1fr}.public-shell{padding:12px}.public-card{padding:18px}.sheet-inner{padding:20px 14px}.sheet-inner canvas{height:180px}}

.nav-heading{padding:22px 20px 7px;font-size:11px;text-transform:uppercase;letter-spacing:.12em;opacity:.65}.table-wrap{overflow:auto}.table-wrap table{width:100%;border-collapse:collapse}.table-wrap th,.table-wrap td{padding:13px 12px;border-bottom:1px solid #e5e7eb;text-align:left;white-space:nowrap}.button.small{padding:7px 11px;font-size:13px}.extended{grid-template-columns:minmax(150px,1fr) minmax(180px,1.2fr) minmax(180px,1.2fr) auto auto;align-items:end}.wide-form{max-width:1050px}.checkbox-card{align-self:end;min-height:45px;border:1px solid #d7dce3;border-radius:8px;padding:12px}.compact-docs{padding:14px}.document-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}.document-select{display:flex;align-items:center;justify-content:space-between;gap:16px;border:1px solid #e2e6eb;border-radius:8px;padding:10px 12px}.document-select small{display:block;margin-top:3px}.document-select label{width:86px;font-size:12px}.document-select input{padding:8px}.preview-full{max-width:900px;margin:auto}.email-layout{grid-template-columns:minmax(350px,.8fr) minmax(500px,1.2fr)}@media(max-width:900px){.document-grid{grid-template-columns:1fr}.extended{grid-template-columns:1fr}.email-layout{grid-template-columns:1fr}}
.filter-panel{margin-bottom:20px}.filter-grid{display:grid;grid-template-columns:repeat(4,minmax(150px,1fr)) auto;gap:12px;align-items:end}.filter-actions{display:flex;gap:8px}.actions-cell{display:flex;gap:12px;align-items:center}.actions-cell form{margin:0}.link-button{border:0;background:none;color:var(--primary);padding:0;font-weight:700}.template-lines{display:flex;flex-direction:column;gap:8px}.template-line{display:flex;align-items:center;justify-content:space-between;border:1px solid var(--border);border-radius:8px;padding:11px 13px}.template-check{flex-direction:row;align-items:center;gap:10px}.template-check input{width:auto}.template-check span{display:flex;flex-direction:column}.template-check small{color:var(--muted);margin-top:3px}.quantity-wrap{display:none;width:100px}.quantity-wrap.show{display:flex}.tabs{display:flex;gap:8px;margin-bottom:16px;border-bottom:1px solid var(--border)}.tab{border:0;border-radius:8px 8px 0 0;background:#e9edf4;color:#4f596c}.tab.active{background:var(--primary);color:#fff}.tab-panel{display:none}.tab-panel.active{display:block}.static-list{position:static;max-height:none}.field-admin-row{grid-template-columns:minmax(145px,1fr) minmax(160px,1fr) minmax(160px,1fr) repeat(4,minmax(115px,auto));align-items:end}.preview-tab{max-width:950px;margin:auto}.preview-tab img{width:100%;display:block;margin-bottom:18px;box-shadow:0 2px 12px rgba(0,0,0,.15)}
@media(max-width:1100px){.filter-grid{grid-template-columns:1fr 1fr}.field-admin-row{grid-template-columns:1fr 1fr}}@media(max-width:700px){.filter-grid,.field-admin-row{grid-template-columns:1fr}.template-line{align-items:flex-start;gap:12px}.actions-cell{align-items:flex-start;flex-direction:column}}

/* Responsive review and management refinements */
.template-editor-layout{display:grid;grid-template-columns:280px minmax(0,1fr);gap:20px;align-items:start}.template-settings-panel{position:sticky;top:20px;display:flex;flex-direction:column;gap:16px}.template-settings-panel h2{font-size:17px;margin:8px 0 0}.setting-check{padding:12px;border:1px solid var(--border);border-radius:9px;background:#fafbfc}.template-editor-main{min-width:0}.responsive-field-list{display:flex;flex-direction:column;gap:10px}.field-config-card{display:grid;grid-template-columns:minmax(210px,1.1fr) minmax(190px,1fr) minmax(190px,1fr);gap:14px;align-items:end;border:1px solid var(--border);border-radius:10px;padding:15px;background:#fff}.field-config-title{display:flex;flex-direction:column;gap:5px}.field-config-title small,.table-subtext{display:block;color:var(--muted);font-size:12px;margin-top:4px}.preset-card{grid-template-columns:minmax(200px,1fr) minmax(180px,1fr) minmax(180px,1fr) minmax(220px,1.2fr)}.hidden-field{visibility:hidden;pointer-events:none}.danger-button{color:#a22727;border-color:#efcaca;background:#fff7f7}.panel fieldset{min-width:0}.compact-docs legend{font-weight:700;padding:0 8px}.public-card,.panel{overflow:hidden}.review-page{height:auto;object-fit:contain;background:#fff}.customer-doc-fields label{min-width:0}.customer-doc-fields input,.customer-doc-fields select{min-width:0}.table-wrap form{margin:0}
@media(max-width:1100px){.template-editor-layout{grid-template-columns:1fr}.template-settings-panel{position:static;display:grid;grid-template-columns:1fr 1fr}.template-settings-panel>label:first-child,.template-settings-panel h2,.template-settings-panel .help-text,.template-settings-panel button{grid-column:1/-1}.field-config-card,.preset-card{grid-template-columns:1fr 1fr}.field-config-title{grid-column:1/-1}}
@media(max-width:760px){.sidebar{padding:10px;gap:4px}.sidebar .brand{padding:8px 10px;font-size:18px}.sidebar a{padding:9px 10px;white-space:nowrap}.nav-heading{display:none}.admin-main{padding:12px}.page-head{align-items:flex-start;gap:12px;flex-direction:column}.page-head .button{width:100%;text-align:center}.stats{grid-template-columns:1fr 1fr;gap:8px}.stat{padding:14px}.stat b{font-size:24px}.panel{padding:14px;border-radius:10px}.tabs{overflow-x:auto;white-space:nowrap}.tab{flex:0 0 auto}.template-settings-panel{display:flex}.field-config-card,.preset-card{grid-template-columns:1fr}.field-config-title{grid-column:auto}.hidden-field{display:none}.template-line{flex-direction:column}.quantity-wrap.show{width:100%}.public-shell{padding:8px}.public-card{padding:14px;border-radius:10px}.sign-header{height:auto;min-height:58px;padding:12px 14px}.sign-header>div:last-child{font-size:13px}.stepper{gap:5px}.stepper span{padding:7px 9px;font-size:11px}.review-actions{flex-direction:column-reverse}.review-actions .button,.review-actions button{width:100%;text-align:center}.sheet-actions{display:grid;grid-template-columns:1fr 1fr}.sheet-actions .primary{grid-column:1/-1}.two{grid-template-columns:1fr}.table-wrap th,.table-wrap td{padding:10px 8px}.complete-card{margin:20px 10px;padding:24px 16px}}
@media(max-width:430px){.stats{grid-template-columns:1fr}.sidebar{flex-wrap:wrap}.sidebar .brand{width:100%}.customer-doc-fields{padding:12px}.public-card h1{font-size:23px}.review-document h2{font-size:18px}}
.customer-search{display:flex;gap:12px;align-items:end;flex-wrap:wrap}.customer-search label{flex:1;min-width:240px}.section-head{display:flex;justify-content:space-between;align-items:center;gap:16px;margin-bottom:16px}.three{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px}.customer-picker{border:1px solid #d8dee9;border-radius:10px;max-height:320px;overflow:auto}.customer-option{display:flex;align-items:center;gap:12px;padding:12px 14px;border-bottom:1px solid #edf0f5;cursor:pointer}.customer-option:last-child{border-bottom:0}.customer-option:hover{background:#f7f9fc}.customer-option input{width:auto}.customer-option span{display:flex;flex-direction:column}.customer-option small{color:#667085;margin-top:3px}.required{font-size:.72rem;color:#b42318;font-weight:700}.form-actions{display:flex;justify-content:flex-end;gap:10px}@media(max-width:800px){.three,.two{grid-template-columns:1fr}.section-head{align-items:stretch;flex-direction:column}.section-head .primary{width:100%}.customer-search{align-items:stretch;flex-direction:column}.customer-search label{min-width:0}.customer-picker{max-height:420px}.table-wrap table{min-width:900px}}
.editor-grid{display:grid;grid-template-columns:1fr 1fr;gap:18px;margin-bottom:18px}.html-toolbar{display:flex;gap:6px;padding:7px;background:#f4f6f9;border:1px solid var(--border);border-bottom:0;border-radius:8px 8px 0 0}.html-toolbar button{padding:6px 10px;min-width:38px}.html-editor{min-height:150px;border:1px solid var(--border);border-radius:0 0 8px 8px;padding:12px;background:#fff;overflow:auto}.sign-disclaimer{padding:12px 14px;border:1px solid var(--border);border-radius:8px;background:#f8fafc;margin:12px 0;font-size:14px}.sign-disclaimer a{color:var(--primary);text-decoration:underline}.consent-list{display:flex;flex-direction:column;gap:9px;margin:14px 0}.consent-check{display:flex;flex-direction:row;align-items:flex-start;gap:10px;padding:10px 12px;border:1px solid var(--border);border-radius:8px;background:#fff}.consent-check input{width:auto;margin-top:3px}@media(max-width:760px){.editor-grid{grid-template-columns:1fr}.html-editor{min-height:120px}}
/* Compact template/customer management update */
.field-table-wrap{overflow:auto}.field-management-table{min-width:1180px}.field-management-table th{vertical-align:bottom}.field-management-table input,.field-management-table select{min-width:155px;margin:0}.field-management-table td{vertical-align:top}.disclaimer-layout{display:grid;grid-template-columns:minmax(0,1fr) minmax(300px,.7fr);gap:18px}.disclaimer-preview-panel{position:sticky;top:18px;align-self:start}.signature-preview{border:1px solid var(--border,#d8dee8);border-radius:12px;padding:18px;background:#fff}.fake-signature-box{height:130px;border:2px dashed #b7c0cf;border-radius:10px;display:grid;place-items:center;color:#6a7483;margin:16px 0}.preview-check{display:flex;gap:8px;align-items:flex-start;margin:10px 0}.compact-selector{padding:18px}.selector-head{display:flex;justify-content:space-between;gap:16px;align-items:end}.selector-head h2{margin-bottom:2px}.selector-controls{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.selector-controls input[type=search]{width:min(340px,45vw)}.filter-buttons{display:flex;gap:8px;margin:12px 0}.filter-buttons .active{background:#e8eefb;border-color:#8aa5df}.compact-list{border:1px solid #dfe4ec;border-radius:10px;overflow:hidden}.compact-row{min-height:48px;padding:8px 12px;border-bottom:1px solid #e8ebf0;align-items:center;gap:12px;background:#fff}.compact-row:last-child{border-bottom:0}.customer-option{display:grid;grid-template-columns:auto minmax(170px,1.2fr) minmax(180px,1fr) minmax(100px,.5fr);cursor:pointer}.customer-option input{margin:0}.template-category{margin-top:16px}.template-category h3{font-size:1rem;margin:0 0 7px}.template-option{display:grid;grid-template-columns:minmax(220px,1.4fr) minmax(90px,.4fr) minmax(110px,.5fr) 90px}.template-option>label:first-child{display:flex;align-items:center;gap:8px}.inline-quantity{display:none;align-items:center;gap:6px}.inline-quantity.show{display:flex}.inline-quantity input{width:58px;margin:0}.list-footer{display:flex;justify-content:space-between;align-items:center;margin-top:10px}.request-options{display:flex;align-items:end;justify-content:space-between;gap:20px}.request-options label{max-width:420px;width:100%}
@media(max-width:900px){.disclaimer-layout{grid-template-columns:1fr}.disclaimer-preview-panel{position:static}.selector-head{align-items:stretch;flex-direction:column}.selector-controls input[type=search]{width:100%}.customer-option{grid-template-columns:auto 1fr}.customer-option span,.customer-option small{grid-column:2}.template-option{grid-template-columns:1fr auto}.template-option>span{grid-column:1}.inline-quantity{grid-column:2;grid-row:1/3}.request-options{align-items:stretch;flex-direction:column}.request-options label{max-width:none}}
@media(max-width:600px){.filter-buttons,.selector-controls{display:grid;grid-template-columns:1fr 1fr}.selector-controls input[type=search]{grid-column:1/-1}.compact-row{padding:10px}.customer-option{font-size:.9rem}.template-option{font-size:.9rem}.list-footer{align-items:flex-start;gap:8px;flex-direction:column}.field-management-table{min-width:1050px}}

/* July 2026 compact admin and rich disclaimer update */
.dashboard-filters{grid-template-columns:minmax(150px,1fr) minmax(150px,1fr) minmax(145px,.8fr) minmax(145px,.8fr) minmax(150px,1fr) auto}.compact-head{margin-bottom:10px}.settings-two{display:grid;grid-template-columns:1fr 110px;gap:10px}.settings-two small{display:block;color:var(--muted);font-size:11px;margin-top:4px}.code-editor{font-family:Consolas,"Courier New",monospace;font-size:12px;line-height:1.45;min-height:190px;white-space:pre;tab-size:2}.preview-heading{display:flex;justify-content:space-between;align-items:flex-start;gap:12px}.disclaimer-preview-frame{width:100%;height:680px;border:1px solid var(--border);border-radius:10px;background:#fff}.disclaimer-html{overflow-x:auto}.disclaimer-html .form-block{border:1px solid var(--border);border-radius:10px;padding:15px;margin:12px 0;background:#fff}.disclaimer-html .form-block-head h3{margin:0 0 4px}.disclaimer-html .fee-table-wrap{overflow-x:auto}.disclaimer-html table{width:100%;border-collapse:collapse}.disclaimer-html th,.disclaimer-html td{padding:9px;border:1px solid var(--border);text-align:left}.disclaimer-html th{background:#f4f6f9}.disclaimer-html .consent{display:flex;gap:9px;align-items:flex-start;padding:10px;border:1px solid var(--border);border-radius:8px;margin:8px 0}.disclaimer-html input[type=checkbox]{width:auto;margin-top:3px}.disclaimer-html .sign-wrap,.disclaimer-html .form-actions,.disclaimer-html .form-secure-note,.disclaimer-html canvas,.disclaimer-html .sign-pad,.disclaimer-html button[type=submit]{display:none!important}.compact-controls{justify-content:flex-end}.inline-control{display:flex;flex-direction:row;align-items:center;gap:6px;font-size:13px}.inline-control select{width:82px}.filter-toolbar{display:flex;justify-content:space-between;gap:10px;align-items:center;margin:10px 0}.segmented{display:flex;gap:6px}.compact-table-list{overflow-x:auto}.compact-list-head{display:grid;min-width:680px;padding:8px 12px;background:#f4f6f9;border-bottom:1px solid var(--border);font-size:12px;font-weight:700;color:#596273}.customer-grid{grid-template-columns:32px minmax(170px,1.1fr) minmax(210px,1.2fr) minmax(100px,.6fr)}.customer-option.customer-grid{min-width:680px}.template-grid{grid-template-columns:minmax(240px,1.5fr) 70px 90px 90px}.template-option.template-grid,.template-list .compact-list-head{min-width:600px}.category-heading{display:flex;justify-content:space-between;align-items:center;margin:15px 0 6px}.category-heading h3{margin:0}.category-heading small{color:var(--muted)}.template-option .inline-quantity{display:block}.template-option .inline-quantity input{width:64px}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.empty-state{padding:16px}
@media(max-width:1150px){.dashboard-filters{grid-template-columns:repeat(3,minmax(150px,1fr))}.dashboard-filters .filter-actions{grid-column:1/-1}.disclaimer-layout{grid-template-columns:1fr}.disclaimer-preview-panel{position:static}.disclaimer-preview-frame{height:560px}}
@media(max-width:760px){.dashboard-filters{grid-template-columns:1fr 1fr}.settings-two{grid-template-columns:1fr}.filter-toolbar{align-items:stretch;flex-direction:column}.filter-toolbar>div{display:flex;flex-wrap:wrap}.compact-controls{width:100%}.compact-controls>*{flex:1}.disclaimer-preview-frame{height:500px}.request-options{position:sticky;bottom:0;z-index:5;box-shadow:0 -4px 18px rgba(15,23,42,.08)}}
@media(max-width:480px){.dashboard-filters{grid-template-columns:1fr}.segmented,.filter-toolbar>div{display:grid;grid-template-columns:1fr 1fr;width:100%}.segmented .button:first-child{grid-column:1/-1}.compact-controls{display:grid;grid-template-columns:1fr}.inline-control{justify-content:space-between}.disclaimer-preview-frame{height:440px}}

/* Compact signature request layout and admin navigation */
.admin-nav-box{border:2px solid #d92d20;border-radius:9px;padding:5px;margin:3px 0;display:flex;flex-direction:column;gap:2px}.admin-nav-box .nav-heading{color:#b42318;padding:4px 9px 2px;margin:0;font-weight:800}.admin-nav-box a{margin:0;padding:8px 9px}
.tight-head{align-items:center;margin-bottom:10px}.selector-title{display:flex;align-items:center;gap:10px}.selector-title h2{margin:0}.selection-badge{display:inline-flex;align-items:center;min-height:26px;padding:3px 8px;border-radius:999px;background:#f1f4f8;color:#475467;font-size:12px;font-weight:700;white-space:nowrap}.selector-controls{gap:6px}.compact-search{width:210px!important;min-height:34px!important;height:34px!important;padding:6px 9px!important;font-size:13px}.selector-controls .button.small,.selector-controls select,.inline-control{min-height:34px;height:34px}.inline-control select{padding:4px 24px 4px 7px}.compact-row{min-height:38px;padding:5px 10px}.customer-grid{grid-template-columns:28px minmax(170px,1.05fr) minmax(210px,1.2fr) minmax(100px,.55fr)}.template-grid{grid-template-columns:minmax(260px,1.6fr) 130px 80px 82px}.template-option.template-grid,.template-list .compact-list-head{min-width:610px}.template-name-cell{display:flex!important;align-items:center;gap:8px;min-width:0}.template-name-cell b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.template-option .inline-quantity{display:flex;align-items:center}.template-option .inline-quantity input{height:30px;min-height:30px;padding:4px 6px;width:56px}.preview-template{height:30px;min-height:30px;padding:4px 9px}.category-heading{margin:10px 0 5px}.category-heading h3{font-size:14px}.request-options{padding:13px 16px}.request-options select{height:36px;min-height:36px}.request-options .primary{min-height:36px;padding:7px 16px}.modal-backdrop{position:fixed;inset:0;background:rgba(15,23,42,.62);z-index:2000;padding:24px;display:grid;place-items:center}.modal-backdrop[hidden]{display:none}.preview-modal{width:min(1050px,96vw);height:min(860px,92vh);background:#fff;border-radius:12px;box-shadow:0 22px 70px rgba(0,0,0,.28);display:flex;flex-direction:column;overflow:hidden}.preview-modal-head{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 14px;border-bottom:1px solid var(--border);background:#f8fafc}.preview-modal-head h2{font-size:17px;margin:0}.preview-modal iframe{width:100%;height:100%;border:0;background:#eef2f6}.modal-open{overflow:hidden}
@media(max-width:900px){.tight-head{align-items:stretch}.selector-title{justify-content:space-between}.customer-controls,.template-controls{display:flex;flex-wrap:wrap}.compact-search{width:100%!important;flex:1 0 100%}.template-grid{grid-template-columns:minmax(220px,1fr) 115px 70px 76px}}
@media(max-width:600px){.admin-nav-box{width:100%}.admin-nav-box a{display:block}.selector-controls .button.small,.selector-controls select,.inline-control{height:34px;min-height:34px}.modal-backdrop{padding:8px}.preview-modal{width:100%;height:95vh}.selection-badge{font-size:11px}}

/* Signature disclaimer mobile readability and scrolling */
.signature-sheet .sheet-inner{max-height:94vh;overflow-y:auto;overscroll-behavior:contain}
.signature-sheet .sign-disclaimer{max-height:42vh;overflow:auto;-webkit-overflow-scrolling:touch;word-break:normal}
.signature-sheet .disclaimer-html table{min-width:520px}
.signature-sheet .consent,.signature-sheet .consent-check{font-size:14px;line-height:1.45}
@media(max-width:760px){
  .signature-sheet .sheet-inner{padding:14px 12px;max-height:96vh}
  .signature-sheet .sign-disclaimer{max-height:36vh;padding:10px;font-size:13px}
  .signature-sheet .disclaimer-html{overflow:auto}
  .signature-sheet .disclaimer-html table{font-size:12px}
  .signature-sheet .disclaimer-html th,.signature-sheet .disclaimer-html td{padding:7px}
  .signature-sheet .consent,.signature-sheet .consent-check{font-size:13px;padding:9px}
  .sheet-actions{position:sticky;bottom:-14px;background:#fff;padding:10px 0 4px;z-index:2}
}

/* July 2026 public signing mobile correction */
.public-main{width:100%;overflow-x:hidden}
.public-shell{width:min(1120px,100%);margin:0 auto;padding:18px}
.public-card{width:100%;max-width:100%}
.signature-sheet .sheet-inner{width:min(920px,100%);margin:0 auto}
.signature-sheet form{min-width:0}
.signature-sheet .disclaimer-html,.signature-sheet .sign-disclaimer{max-width:100%}
.signature-sheet .disclaimer-html *{max-width:100%}
.signature-sheet .disclaimer-html img{height:auto!important}
.signature-sheet .disclaimer-html input[type="checkbox"],
.signature-sheet .consent-check input[type="checkbox"]{width:18px!important;height:18px!important;min-width:18px!important;min-height:18px!important;transform:none!important;flex:0 0 18px}
.signature-sheet canvas{display:block;width:100%!important;height:150px!important;max-width:100%;border:1px solid var(--border);border-radius:8px;background:#fff;touch-action:none}

@media(max-width:760px){
  .sign-header{padding:9px 11px!important;min-height:50px!important;gap:8px}
  .sign-header b{font-size:16px!important}
  .sign-header span,.sign-header>div:last-child{font-size:11px!important}
  .public-shell{padding:7px!important}
  .public-card{padding:11px!important;border-radius:8px!important}
  .public-card h1{font-size:19px!important;line-height:1.2!important;margin:0 0 7px!important}
  .public-card h2,.review-document h2{font-size:15px!important;line-height:1.25!important}
  .public-card p{font-size:13px!important;line-height:1.42!important;margin:6px 0 10px!important}
  .stepper{display:flex!important;overflow-x:auto!important;white-space:nowrap!important;padding:5px 0!important;gap:4px!important;scrollbar-width:none}
  .stepper::-webkit-scrollbar{display:none}
  .stepper span{flex:0 0 auto!important;padding:5px 7px!important;font-size:10px!important;border-radius:6px!important}
  .review-document{margin:9px 0!important;padding:8px!important}
  .review-page{width:100%!important;max-width:100%!important;margin:6px 0!important}
  .review-actions{gap:7px!important;margin-top:10px!important}
  .review-actions .button,.review-actions button,.form-stack>.primary.large,.id-card button{min-height:38px!important;height:auto!important;padding:8px 11px!important;font-size:13px!important;border-radius:7px!important}

  .signature-sheet{padding:0!important;align-items:flex-end!important}
  .signature-sheet .sheet-inner{width:100%!important;max-width:none!important;max-height:96dvh!important;border-radius:14px 14px 0 0!important;padding:9px 10px 7px!important;overflow-y:auto!important;overflow-x:hidden!important}
  .signature-sheet h2{font-size:17px!important;margin:2px 0 7px!important}
  .signature-sheet .sign-disclaimer{max-height:31dvh!important;overflow:auto!important;padding:7px!important;margin:7px 0!important;font-size:11px!important;line-height:1.35!important;border-radius:6px!important}
  .signature-sheet .disclaimer-html .form-block{padding:8px!important;margin:7px 0!important;border-radius:7px!important}
  .signature-sheet .disclaimer-html .form-block-head{margin:0 0 5px!important}
  .signature-sheet .disclaimer-html h1{font-size:17px!important}
  .signature-sheet .disclaimer-html h2{font-size:15px!important}
  .signature-sheet .disclaimer-html h3{font-size:13px!important;line-height:1.25!important;margin:0 0 3px!important}
  .signature-sheet .disclaimer-html h4{font-size:12px!important}
  .signature-sheet .disclaimer-html p,
  .signature-sheet .disclaimer-html li,
  .signature-sheet .disclaimer-html label,
  .signature-sheet .disclaimer-html td,
  .signature-sheet .disclaimer-html th{font-size:11px!important;line-height:1.35!important}
  .signature-sheet .disclaimer-html p{margin:5px 0!important}
  .signature-sheet .disclaimer-html .fee-table-wrap{width:100%!important;overflow-x:auto!important;-webkit-overflow-scrolling:touch!important}
  .signature-sheet .disclaimer-html table{width:max-content!important;min-width:460px!important;max-width:none!important}
  .signature-sheet .disclaimer-html th,.signature-sheet .disclaimer-html td{padding:5px!important;white-space:normal!important}
  .signature-sheet .disclaimer-html .consent,
  .signature-sheet .consent-check{gap:7px!important;padding:7px!important;margin:5px 0!important;font-size:11px!important;line-height:1.35!important;border-radius:6px!important}
  .signature-sheet canvas{height:118px!important;margin:6px 0!important}
  .consent-list{gap:5px!important;margin:7px 0!important}
  .sheet-actions{display:grid!important;grid-template-columns:1fr 1fr!important;gap:6px!important;position:sticky!important;bottom:-7px!important;margin:7px -2px 0!important;padding:7px 2px 2px!important;background:#fff!important}
  .sheet-actions button{min-height:36px!important;height:36px!important;padding:6px 8px!important;font-size:12px!important;border-radius:7px!important}
  .sheet-actions .primary{grid-column:1/-1!important}
}

@media(max-width:390px){
  .signature-sheet .sign-disclaimer{max-height:29dvh!important;font-size:10.5px!important}
  .signature-sheet .disclaimer-html p,.signature-sheet .disclaimer-html label,.signature-sheet .disclaimer-html td,.signature-sheet .disclaimer-html th{font-size:10.5px!important}
  .signature-sheet canvas{height:105px!important}
}

/* Mobile-first public signature request and disclaimer */
@media (max-width: 760px) {
  body.sheet-open { overflow: hidden !important; }
  .public-main { width: 100%; min-width: 0; }
  .sign-header { padding: 8px 10px !important; min-height: 48px !important; gap: 8px; }
  .sign-header b { font-size: 15px !important; }
  .sign-header span, .sign-header > div:last-child { font-size: 11px !important; line-height: 1.25 !important; }
  .public-shell, .review-shell { width: 100%; max-width: 100%; padding: 6px !important; }
  .public-card { padding: 10px !important; border-radius: 8px !important; }
  .public-card > h1 { font-size: 20px !important; line-height: 1.2 !important; margin-bottom: 6px !important; }
  .public-card > p { font-size: 13px !important; line-height: 1.4 !important; }
  .review-document { margin-top: 14px !important; }
  .review-document h2 { font-size: 15px !important; margin: 8px 0 !important; }
  .review-page { margin-bottom: 10px !important; box-shadow: 0 1px 8px rgba(0,0,0,.15) !important; }
  .review-actions { padding: 8px 0 !important; gap: 7px !important; }
  .review-actions .button, .review-actions button { min-height: 38px !important; height: 38px !important; padding: 7px 10px !important; font-size: 13px !important; }

  .signature-sheet { align-items: stretch !important; background: #fff !important; }
  .signature-sheet.open { display: block !important; }
  .signature-sheet .sheet-handle { display: none !important; }
  .signature-sheet .sheet-inner {
    width: 100% !important;
    height: 100dvh !important;
    max-height: 100dvh !important;
    padding: 8px !important;
    border-radius: 0 !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    box-shadow: none !important;
  }
  .signature-sheet form { width: 100% !important; max-width: 100% !important; }
  .signature-sheet h1, .signature-sheet h2, .signature-sheet h3, .signature-sheet h4 {
    font-size: 16px !important;
    line-height: 1.25 !important;
    margin: 7px 0 !important;
  }
  .signature-sheet p, .signature-sheet li, .signature-sheet label, .signature-sheet span,
  .signature-sheet td, .signature-sheet th, .signature-sheet a, .signature-sheet div {
    font-size: 12px !important;
    line-height: 1.35 !important;
    max-width: 100% !important;
  }
  .signature-sheet .sign-disclaimer {
    width: 100% !important;
    max-width: 100% !important;
    max-height: 34dvh !important;
    padding: 7px !important;
    margin: 6px 0 !important;
    border-radius: 6px !important;
    overflow: auto !important;
    overflow-wrap: anywhere !important;
    -webkit-overflow-scrolling: touch;
  }
  .signature-sheet .disclaimer-html .form-block {
    padding: 7px !important;
    margin: 6px 0 !important;
    border-radius: 6px !important;
  }
  .signature-sheet .disclaimer-html .form-block-head,
  .signature-sheet .disclaimer-html .form-grid,
  .signature-sheet .disclaimer-html .field,
  .signature-sheet .disclaimer-html .consent {
    width: 100% !important;
    display: block !important;
    margin: 5px 0 !important;
    padding: 6px !important;
  }
  .signature-sheet .disclaimer-html .consent { display: grid !important; grid-template-columns: 20px minmax(0,1fr) !important; gap: 5px !important; }
  .signature-sheet .disclaimer-html input[type="checkbox"],
  .signature-sheet .consent-check input[type="checkbox"] {
    width: 17px !important;
    height: 17px !important;
    min-width: 17px !important;
    margin: 1px 0 0 !important;
  }
  .signature-sheet .disclaimer-html .fee-table-wrap { width: 100% !important; overflow-x: auto !important; }
  .signature-sheet .disclaimer-html table {
    width: 100% !important;
    min-width: 430px !important;
    table-layout: auto !important;
    font-size: 10px !important;
  }
  .signature-sheet .disclaimer-html th, .signature-sheet .disclaimer-html td {
    padding: 4px !important;
    font-size: 10px !important;
    white-space: normal !important;
  }
  .signature-sheet .disclaimer-html img { max-width: 100% !important; height: auto !important; }
  .signature-sheet canvas#signatureCanvas {
    width: 100% !important;
    height: 120px !important;
    min-height: 120px !important;
    border-width: 1px !important;
    margin: 5px 0 !important;
  }
  .signature-sheet .consent-list { gap: 5px !important; margin: 7px 0 !important; }
  .signature-sheet .consent-check {
    display: grid !important;
    grid-template-columns: 20px minmax(0,1fr) !important;
    gap: 5px !important;
    padding: 6px !important;
    border-radius: 6px !important;
  }
  .signature-sheet .sheet-actions {
    position: sticky !important;
    bottom: -8px !important;
    display: grid !important;
    grid-template-columns: 1fr 1fr 1.25fr !important;
    gap: 5px !important;
    margin-top: 6px !important;
    padding: 7px 0 2px !important;
    background: #fff !important;
    z-index: 10 !important;
  }
  .signature-sheet .sheet-actions button {
    width: 100% !important;
    min-width: 0 !important;
    min-height: 36px !important;
    height: 36px !important;
    padding: 6px 5px !important;
    font-size: 12px !important;
    line-height: 1 !important;
  }
}

@media (max-width: 390px) {
  .signature-sheet .sign-disclaimer { max-height: 31dvh !important; }
  .signature-sheet canvas#signatureCanvas { height: 105px !important; min-height: 105px !important; }
  .signature-sheet .sheet-actions button { font-size: 11px !important; }
}

/* Mobile-first public signature request and disclaimer */
@media (max-width: 760px) {
  body.sheet-open { overflow: hidden !important; }
  .public-main { width: 100%; min-width: 0; }
  .sign-header { padding: 8px 10px !important; min-height: 48px !important; gap: 8px; }
  .sign-header b { font-size: 15px !important; }
  .sign-header span, .sign-header > div:last-child { font-size: 11px !important; line-height: 1.25 !important; }
  .public-shell, .review-shell { width: 100%; max-width: 100%; padding: 6px !important; }
  .public-card { padding: 10px !important; border-radius: 8px !important; }
  .public-card > h1 { font-size: 20px !important; line-height: 1.2 !important; margin-bottom: 6px !important; }
  .public-card > p { font-size: 13px !important; line-height: 1.4 !important; }
  .review-document { margin-top: 14px !important; }
  .review-document h2 { font-size: 15px !important; margin: 8px 0 !important; }
  .review-page { margin-bottom: 10px !important; box-shadow: 0 1px 8px rgba(0,0,0,.15) !important; }
  .review-actions { padding: 8px 0 !important; gap: 7px !important; }
  .review-actions .button, .review-actions button { min-height: 38px !important; height: 38px !important; padding: 7px 10px !important; font-size: 13px !important; }

  .signature-sheet { align-items: stretch !important; background: #fff !important; }
  .signature-sheet.open { display: block !important; }
  .signature-sheet .sheet-handle { display: none !important; }
  .signature-sheet .sheet-inner {
    width: 100% !important;
    height: 100dvh !important;
    max-height: 100dvh !important;
    padding: 8px !important;
    border-radius: 0 !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    box-shadow: none !important;
  }
  .signature-sheet form { width: 100% !important; max-width: 100% !important; }
  .signature-sheet h1, .signature-sheet h2, .signature-sheet h3, .signature-sheet h4 {
    font-size: 16px !important;
    line-height: 1.25 !important;
    margin: 7px 0 !important;
  }
  .signature-sheet p, .signature-sheet li, .signature-sheet label, .signature-sheet span,
  .signature-sheet td, .signature-sheet th, .signature-sheet a, .signature-sheet div {
    font-size: 12px !important;
    line-height: 1.35 !important;
    max-width: 100% !important;
  }
  .signature-sheet .sign-disclaimer {
    width: 100% !important;
    max-width: 100% !important;
    max-height: 34dvh !important;
    padding: 7px !important;
    margin: 6px 0 !important;
    border-radius: 6px !important;
    overflow: auto !important;
    overflow-wrap: anywhere !important;
    -webkit-overflow-scrolling: touch;
  }
  .signature-sheet .disclaimer-html .form-block {
    padding: 7px !important;
    margin: 6px 0 !important;
    border-radius: 6px !important;
  }
  .signature-sheet .disclaimer-html .form-block-head,
  .signature-sheet .disclaimer-html .form-grid,
  .signature-sheet .disclaimer-html .field,
  .signature-sheet .disclaimer-html .consent {
    width: 100% !important;
    margin: 5px 0 !important;
    padding: 6px !important;
  }
  .signature-sheet .disclaimer-html .form-grid { display: block !important; }
  .signature-sheet .disclaimer-html .consent { display: grid !important; grid-template-columns: 20px minmax(0,1fr) !important; gap: 5px !important; }
  .signature-sheet .disclaimer-html input[type="checkbox"],
  .signature-sheet .consent-check input[type="checkbox"] {
    width: 17px !important;
    height: 17px !important;
    min-width: 17px !important;
    margin: 1px 0 0 !important;
  }
  .signature-sheet .disclaimer-html .fee-table-wrap { width: 100% !important; overflow-x: auto !important; }
  .signature-sheet .disclaimer-html table {
    width: 100% !important;
    min-width: 430px !important;
    table-layout: auto !important;
    font-size: 10px !important;
  }
  .signature-sheet .disclaimer-html th, .signature-sheet .disclaimer-html td {
    padding: 4px !important;
    font-size: 10px !important;
    white-space: normal !important;
  }
  .signature-sheet .disclaimer-html img { max-width: 100% !important; height: auto !important; }
  .signature-sheet canvas#signatureCanvas {
    width: 100% !important;
    height: 120px !important;
    min-height: 120px !important;
    border-width: 1px !important;
    margin: 5px 0 !important;
  }
  .signature-sheet .consent-list { gap: 5px !important; margin: 7px 0 !important; }
  .signature-sheet .consent-check {
    display: grid !important;
    grid-template-columns: 20px minmax(0,1fr) !important;
    gap: 5px !important;
    padding: 6px !important;
    border-radius: 6px !important;
  }
  .signature-sheet .sheet-actions {
    position: sticky !important;
    bottom: -8px !important;
    display: grid !important;
    grid-template-columns: 1fr 1fr 1.25fr !important;
    gap: 5px !important;
    margin-top: 6px !important;
    padding: 7px 0 2px !important;
    background: #fff !important;
    z-index: 10 !important;
  }
  .signature-sheet .sheet-actions button {
    width: 100% !important;
    min-width: 0 !important;
    min-height: 36px !important;
    height: 36px !important;
    padding: 6px 5px !important;
    font-size: 12px !important;
    line-height: 1 !important;
  }
}

@media (max-width: 390px) {
  .signature-sheet .sign-disclaimer { max-height: 31dvh !important; }
  .signature-sheet canvas#signatureCanvas { height: 105px !important; min-height: 105px !important; }
  .signature-sheet .sheet-actions button { font-size: 11px !important; }
}

/* Final balanced signing layout: compact on desktop and mobile */
.signature-sheet .sheet-inner {
  width: min(920px, calc(100vw - 32px)) !important;
  max-height: 92vh !important;
  padding: 16px 18px !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
}
.signature-sheet .sheet-inner form { max-width: 100% !important; }
.signature-sheet .sheet-inner h2 { font-size: 19px !important; line-height: 1.25 !important; margin: 0 0 8px !important; }
.signature-sheet .sign-disclaimer {
  max-height: 34vh !important;
  overflow-y: auto !important;
  overflow-x: auto !important;
  padding: 10px !important;
  margin: 8px 0 !important;
  font-size: 12.5px !important;
  line-height: 1.4 !important;
}
.signature-sheet .disclaimer-html h1 { font-size: 19px !important; }
.signature-sheet .disclaimer-html h2 { font-size: 17px !important; }
.signature-sheet .disclaimer-html h3 { font-size: 15px !important; }
.signature-sheet .disclaimer-html h4,
.signature-sheet .disclaimer-html h5,
.signature-sheet .disclaimer-html h6 { font-size: 13px !important; }
.signature-sheet .disclaimer-html p,
.signature-sheet .disclaimer-html li,
.signature-sheet .disclaimer-html label,
.signature-sheet .disclaimer-html span,
.signature-sheet .disclaimer-html div,
.signature-sheet .disclaimer-html a { font-size: 12.5px !important; line-height: 1.4 !important; }
.signature-sheet .disclaimer-html .form-block { padding: 10px !important; margin: 8px 0 !important; }
.signature-sheet .disclaimer-html .form-block-head { padding: 8px !important; margin: 0 0 7px !important; }
.signature-sheet .disclaimer-html table { font-size: 11.5px !important; }
.signature-sheet .disclaimer-html th,
.signature-sheet .disclaimer-html td { padding: 6px 7px !important; font-size: 11.5px !important; }
.signature-sheet canvas#signatureCanvas { width: 100% !important; height: 155px !important; min-height: 155px !important; margin: 8px 0 !important; }
.signature-sheet .consent-list { gap: 6px !important; margin: 8px 0 !important; }
.signature-sheet .consent-check { padding: 7px 9px !important; font-size: 12.5px !important; }
.signature-sheet .sheet-actions { gap: 8px !important; padding-top: 9px !important; }
.signature-sheet .sheet-actions button { min-height: 38px !important; height: 38px !important; padding: 7px 12px !important; font-size: 13px !important; }

@media (max-width: 760px) {
  .signature-sheet .sheet-inner {
    width: 100% !important;
    height: 100dvh !important;
    max-height: 100dvh !important;
    padding: 8px 9px !important;
  }
  .signature-sheet .sheet-inner h2 { font-size: 16px !important; margin-bottom: 5px !important; }
  .signature-sheet .sign-disclaimer {
    max-height: 36dvh !important;
    padding: 6px !important;
    margin: 5px 0 !important;
    font-size: 11px !important;
    line-height: 1.32 !important;
  }
  .signature-sheet .disclaimer-html h1,
  .signature-sheet .disclaimer-html h2,
  .signature-sheet .disclaimer-html h3 { font-size: 13px !important; line-height: 1.25 !important; margin: 5px 0 !important; }
  .signature-sheet .disclaimer-html h4,
  .signature-sheet .disclaimer-html h5,
  .signature-sheet .disclaimer-html h6 { font-size: 12px !important; }
  .signature-sheet .disclaimer-html p,
  .signature-sheet .disclaimer-html li,
  .signature-sheet .disclaimer-html label,
  .signature-sheet .disclaimer-html span,
  .signature-sheet .disclaimer-html div,
  .signature-sheet .disclaimer-html a { font-size: 11px !important; line-height: 1.32 !important; }
  .signature-sheet .disclaimer-html .form-block { padding: 6px !important; margin: 5px 0 !important; }
  .signature-sheet .disclaimer-html .form-block-head { padding: 5px !important; margin-bottom: 4px !important; }
  .signature-sheet .disclaimer-html table { min-width: 390px !important; font-size: 9.5px !important; }
  .signature-sheet .disclaimer-html th,
  .signature-sheet .disclaimer-html td { padding: 3px 4px !important; font-size: 9.5px !important; line-height: 1.2 !important; }
  .signature-sheet canvas#signatureCanvas { height: 108px !important; min-height: 108px !important; margin: 5px 0 !important; }
  .signature-sheet .consent-check { padding: 5px 6px !important; font-size: 11px !important; line-height: 1.3 !important; }
  .signature-sheet .sheet-actions { gap: 5px !important; margin-top: 5px !important; padding: 6px 0 2px !important; }
  .signature-sheet .sheet-actions button { min-height: 34px !important; height: 34px !important; padding: 5px !important; font-size: 11px !important; }
}

/* Request builder alignment and responsive signing backdrop */
.template-grid{grid-template-columns:32px minmax(220px,1fr) 130px 82px 78px!important;align-items:center!important}.template-option>.template-checkbox{justify-self:center;margin:0!important}.template-document-name{text-align:left;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.request-options{display:flex!important;align-items:flex-end!important;justify-content:space-between!important;gap:12px!important}.request-option-fields{display:grid;grid-template-columns:minmax(240px,360px) minmax(240px,360px);gap:12px;flex:1}.request-option-fields label{min-width:0}.request-option-fields select{width:100%;min-width:0;height:38px!important;padding:6px 34px 6px 10px!important;line-height:1.2!important}.signature-sheet{background:rgba(15,23,42,.58)!important;backdrop-filter:blur(1px)}
@media(max-width:760px){body.sheet-open{overflow:hidden!important}.signature-sheet{align-items:flex-end!important;padding-top:11dvh!important;background:rgba(15,23,42,.48)!important}.signature-sheet .sheet-inner{height:89dvh!important;max-height:89dvh!important;border-radius:14px 14px 0 0!important}.review-shell{filter:none!important}.template-grid{grid-template-columns:28px minmax(150px,1fr) 92px 64px!important}.template-grid .preview-template{grid-column:2/5;justify-self:start;margin-top:3px}.compact-list-head.template-grid span:last-child{display:none}.request-options{align-items:stretch!important;flex-direction:column!important}.request-option-fields{grid-template-columns:1fr!important;width:100%}.request-options>.primary{width:100%}}
@media(max-width:560px){.template-grid{grid-template-columns:26px minmax(120px,1fr) 76px 58px!important;font-size:11px}.template-option{min-height:38px!important;padding:5px 6px!important}.template-document-name{font-size:11.5px}.template-option .inline-quantity input{height:30px!important}.signature-sheet .sheet-inner{height:88dvh!important;max-height:88dvh!important}.signature-sheet .sign-disclaimer{font-size:10.5px!important}.signature-sheet .disclaimer-html p,.signature-sheet .disclaimer-html li,.signature-sheet .disclaimer-html label,.signature-sheet .disclaimer-html td,.signature-sheet .disclaimer-html th{font-size:10.5px!important}}
/* Customer signing-link audit separation */
.section-help{margin:-5px 0 12px;color:#64748b;font-size:12px}.admin-audit>div span{color:#64748b}.customer-audit-panel{border:2px solid #dc2626!important;box-shadow:0 0 0 3px rgba(220,38,38,.07)!important}.customer-audit-heading{display:flex;align-items:center;justify-content:space-between;gap:10px;border-bottom:1px solid #fecaca;padding-bottom:10px;margin-bottom:10px}.customer-audit-heading h2{margin:0;color:#991b1b}.customer-audit-heading span{background:#fee2e2;color:#991b1b;border:1px solid #fecaca;border-radius:999px;padding:4px 9px;font-size:11px;font-weight:700}.customer-audit>div{border-left:3px solid #dc2626;background:#fff7f7}.audit-user-agent{word-break:break-word;color:#64748b}.customer-audit-panel .metadata-panel{margin-top:16px;padding-top:14px;border-top:1px solid #fecaca}.customer-audit-panel .metadata-panel h3{margin:0 0 10px;color:#991b1b}@media(max-width:700px){.customer-audit-heading{align-items:flex-start;flex-direction:column}.customer-audit-panel{border-width:2px!important}.customer-audit-panel .table-wrap{overflow:auto}}

/* Compact matching dashboard actions and merged customer audit highlighting */
.table-action{display:inline-flex;align-items:center;justify-content:center;min-width:58px;height:30px;padding:0 10px;border:1px solid #cfd5dd;border-radius:6px;background:#fff;color:#273243;font:inherit;font-size:13px;font-weight:600;text-decoration:none;cursor:pointer;line-height:1}
button.table-action:hover,a.table-action:hover{background:#f4f6f8;border-color:#9ca7b5}
.customer-audit-event{border:2px solid #d63b3b!important;background:#fff8f8!important;border-radius:7px;padding:11px!important}
.customer-audit-event .audit-user-agent{color:#8e2c2c}
.muted{color:#8a919b}

/* Signature Request details: left signing/documents, right audit, metadata below */
.signature-detail-layout{display:grid;grid-template-columns:minmax(0,0.9fr) minmax(360px,1.1fr);gap:18px;align-items:start;margin-bottom:18px}
.signature-detail-left{display:grid;gap:18px;min-width:0}
.signature-detail-audit{min-width:0;max-height:760px;overflow:auto}
.signature-detail-audit .timeline{margin-top:8px}
@media(max-width:980px){.signature-detail-layout{grid-template-columns:1fr}.signature-detail-audit{max-height:none}}

/* Signature flow: disclaimer and signature pad share one continuous scroll area. */
.signature-sheet .sheet-inner {
  overflow-y: auto !important;
  overscroll-behavior: contain;
}
.signature-sheet .signature-scroll-content {
  display: block;
  min-width: 0;
}
.signature-sheet .sign-disclaimer {
  max-height: none !important;
  overflow-y: visible !important;
  overflow-x: auto !important;
}
.signature-sheet .signature-pad-section {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 0;
}
.signature-sheet .signature-pad-section h3 {
  margin: 0 0 4px;
  font-size: 15px;
}
.signature-sheet .signature-pad-help {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 12px;
}
.signature-sheet .sheet-actions {
  position: static !important;
  margin-top: 10px !important;
}
@media (max-width:760px) {
  .signature-sheet .sign-disclaimer {
    max-height: none !important;
    overflow-y: visible !important;
  }
  .signature-sheet .signature-pad-section {
    margin-top: 10px;
    padding-top: 10px;
  }
  .signature-sheet .signature-pad-help { font-size: 10.5px; }
}

/* Final workflow refinements */
.signing-link-head{align-items:center;margin-bottom:10px}.signing-link-head h2{margin:0}.header-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.header-actions form{margin:0}.compact-modal{width:min(620px,calc(100vw - 28px))}.upload-form{display:grid;gap:12px;margin-top:16px}.modal{position:fixed;inset:0;background:rgba(15,23,42,.55);display:none;place-items:center;padding:14px;z-index:1000}.modal.open{display:grid}.modal-card{background:#fff;border-radius:12px;padding:18px;box-shadow:0 20px 60px rgba(0,0,0,.22);max-height:90vh;overflow:auto}
.multi-select-filter{position:relative;min-width:0}.multi-select-filter .field-label{display:block;font-weight:600;font-size:12px;margin-bottom:5px}.multi-select-trigger{width:100%;height:38px;display:flex;align-items:center;justify-content:space-between;padding:0 10px;border:1px solid var(--border);background:#fff;border-radius:7px;color:var(--text);font:inherit;overflow:hidden}.multi-select-trigger span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.multi-select-menu{display:none;position:absolute;top:calc(100% + 5px);left:0;right:0;max-height:260px;overflow:auto;background:#fff;border:1px solid var(--border);border-radius:8px;box-shadow:0 12px 30px rgba(15,23,42,.15);z-index:50;padding:6px}.multi-select-menu.open{display:block}.multi-select-menu label{display:flex;align-items:flex-start;gap:7px;padding:7px 8px;border-radius:5px;font-weight:400;font-size:13px}.multi-select-menu label:hover{background:#f3f6fa}.multi-select-menu input{width:auto;margin-top:2px}
.html-toolbar{display:flex;align-items:center;gap:6px;flex-wrap:wrap;padding:8px;background:#f5f7fa;border:1px solid var(--border);border-bottom:0;border-radius:8px 8px 0 0}.html-toolbar button,.html-toolbar select,.html-toolbar input[type=color]{height:30px;font-size:12px}.html-toolbar button{border:1px solid var(--border);background:#fff;border-radius:5px;padding:0 9px}.html-toolbar label{display:flex;flex-direction:row;align-items:center;gap:5px;font-size:12px}.code-editor.short{min-height:150px;border-radius:0 0 8px 8px}.legacy-checkboxes{margin-top:10px}.formatted-confirmations{margin:8px 0}
/* The complete signing form scrolls as one unit; below-signature content follows the pad. */
.signature-sheet .sheet-inner{overflow:hidden!important}.signature-sheet .signature-scroll-content{max-height:min(88vh,820px);overflow-y:auto;overflow-x:hidden;overscroll-behavior:contain;padding-right:4px}.signature-sheet .sign-disclaimer{max-height:none!important;overflow:visible!important}.signature-sheet .sheet-actions{position:static!important}.signature-sheet .signature-pad-section{margin-top:14px}.signature-sheet .below{margin-top:14px}
@media(max-width:760px){.signing-link-head{align-items:flex-start}.signing-link-head .header-actions{width:100%}.signing-link-head .header-actions>*{flex:1}.signature-sheet .signature-scroll-content{max-height:calc(92dvh - 18px);padding-right:2px}.multi-select-menu{position:fixed;left:12px;right:12px;top:18%;max-height:62vh}.page-head>.header-actions{width:100%}.page-head>.header-actions>*{flex:1}}

/* Dashboard request selection and compact document filtering */
.dashboard-filters{grid-template-columns:repeat(7,minmax(120px,1fr)) auto}
.dashboard-document-filter{width:100%;max-width:230px;align-self:end}
.dashboard-document-filter .multi-select-trigger{max-width:230px}
.dashboard-document-filter .multi-select-menu{width:330px;right:auto}
.dashboard-document-filter .multi-select-menu label{min-width:0;align-items:center}
.dashboard-document-filter .multi-select-menu label span{display:block;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.page-size-filter{max-width:85px}.select-column{width:38px;text-align:center}.select-column input{width:auto}
.bulk-resend{min-width:112px}.dashboard-pagination{display:flex;justify-content:space-between;align-items:center;padding-top:14px;gap:12px}.dashboard-pagination>div{display:flex;gap:8px}
@media(max-width:1250px){.dashboard-filters{grid-template-columns:repeat(4,minmax(130px,1fr))}.dashboard-document-filter{max-width:none}.dashboard-document-filter .multi-select-trigger{max-width:none}}
@media(max-width:760px){.dashboard-filters{grid-template-columns:1fr 1fr}.dashboard-document-filter{max-width:none}.dashboard-document-filter .multi-select-menu{width:min(330px,calc(100vw - 40px))}.dashboard-pagination{align-items:flex-start;flex-direction:column}}
@media(max-width:480px){.dashboard-filters{grid-template-columns:1fr}.page-size-filter{max-width:none}}


/* Dashboard document filter must float above the requests panel. */
.filter-panel{position:relative;z-index:40;overflow:visible!important}
.filter-panel + .panel{position:relative;z-index:1}
.dashboard-document-filter{position:relative;z-index:45}
.dashboard-document-filter .multi-select-menu{z-index:1000!important}
.actions-cell form,.header-actions form{display:inline-flex;margin:0}.actions-cell{white-space:nowrap}.actions-cell>*{margin-right:5px}.danger-button{border-color:#d92d20!important;color:#b42318!important;background:#fff!important}.page-heading>.header-actions{justify-content:flex-end}.user-role-note{font-size:12px;color:var(--muted)}

/* Dashboard analytics and Signature Request list */
.dashboard-date-form{display:flex;align-items:end;gap:12px;flex-wrap:wrap}.dashboard-date-form label{min-width:180px}.dashboard-date-form .filter-actions{display:flex;gap:8px}.dashboard-stats{grid-template-columns:repeat(5,minmax(150px,1fr))}.analytics-panel{margin-top:22px}.chart-wrap{position:relative;overflow-x:auto;min-height:350px}.chart-wrap canvas{border:0;height:340px;background:#fff}.chart-legend{display:flex;gap:22px;flex-wrap:wrap;margin:4px 0 14px;color:var(--muted);font-size:13px}.chart-legend span{display:flex;align-items:center;gap:7px}.chart-legend i{width:22px;height:3px;border-radius:3px}.legend-sent{background:#6d4aff}.legend-signed{background:#198754}.legend-id{background:#df7b16}.chart-empty{padding:70px 20px;text-align:center;color:var(--muted)}.bulk-request-actions{display:flex;gap:8px;align-items:center}.role-badge{display:inline-block;padding:5px 9px;border-radius:999px;font-size:12px;font-weight:700}.role-badge.admin{background:#efe9ff;color:#5531c5}.role-badge.signature{background:#e7f3ff;color:#17639b}.role-help{display:grid;grid-template-columns:100px 1fr;gap:8px 12px;background:#f7f8fb;border:1px solid var(--border);border-radius:8px;padding:14px}.role-help span{color:var(--muted)}
@media(max-width:1050px){.dashboard-stats{grid-template-columns:repeat(3,1fr)}}
@media(max-width:760px){.dashboard-date-form{align-items:stretch}.dashboard-date-form label{min-width:0;flex:1 1 100%}.dashboard-date-form .filter-actions{width:100%}.dashboard-date-form .filter-actions>*{flex:1;text-align:center}.dashboard-stats{grid-template-columns:1fr 1fr}.bulk-request-actions{width:100%;flex-wrap:wrap}.bulk-request-actions .button{flex:1}.role-help{grid-template-columns:1fr}.chart-wrap{min-height:300px}}
@media(max-width:430px){.dashboard-stats{grid-template-columns:1fr}}

/* July 2026 final template, dashboard and request-builder refinements */
@media(min-width:901px){
  .sidebar{width:270px;padding-left:14px;padding-right:14px}
  .sidebar a{white-space:nowrap;font-size:14px}
  .admin-main{margin-left:270px}
}
.chart-wrap{position:relative;overflow-x:auto}
.chart-tooltip{position:absolute;z-index:8;min-width:155px;padding:8px 10px;border-radius:7px;background:#172033;color:#fff;box-shadow:0 6px 18px rgba(0,0,0,.2);pointer-events:none;font-size:12px;display:flex;flex-direction:column;gap:3px}
.chart-tooltip[hidden]{display:none}
.disclaimer-editor-box{border:1px solid var(--border);border-radius:10px;padding:14px;margin:0 0 16px;background:#fbfcfe}
.disclaimer-editor-box h3{margin:0 0 9px}
.disclaimer-editor-box .html-toolbar{margin-bottom:8px}
.muted{color:var(--muted);font-size:12px}
.confirmation-modal{width:min(820px,96vw);max-height:90vh;background:#fff;border-radius:12px;box-shadow:0 22px 70px rgba(0,0,0,.28);display:flex;flex-direction:column;overflow:hidden}
.confirmation-body{padding:18px;overflow:auto}
.confirmation-grid{display:grid;grid-template-columns:1fr 1fr;gap:16px}
.confirmation-grid section{border:1px solid var(--border);border-radius:9px;padding:12px}
.confirmation-grid h3{margin:0 0 8px}
.confirmation-grid ul{margin:0;padding-left:20px}
.confirmation-grid li{margin:6px 0}
.confirmation-grid small{display:block;color:var(--muted)}
.confirmation-options{margin-top:14px;padding:12px;background:#f5f7fb;border-radius:8px;line-height:1.7}
.confirmation-actions{display:flex;justify-content:flex-end;gap:9px;padding:12px 16px;border-top:1px solid var(--border);background:#f8fafc}
@media(max-width:700px){.confirmation-grid{grid-template-columns:1fr}.confirmation-actions{display:grid;grid-template-columns:1fr 1fr}.confirmation-actions button{width:100%}}

.dynamic-customer-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.dynamic-customer-grid .wide-field{grid-column:1/-1}.reference-banner{display:flex;align-items:center;justify-content:space-between;border:1px solid #d9deea;background:#f7f9fc;padding:12px 14px;border-radius:8px}.reference-banner b{display:block;font-size:20px;letter-spacing:2px}.sort-input{width:76px!important}.results-popup{background:#f4f6fa;padding:12px}.results-list{display:grid;gap:8px}.result-row{display:grid;grid-template-columns:220px 1fr;gap:10px;padding:10px;border:1px solid #dfe4ed;border-radius:6px;background:#fff}.result-row small{grid-column:1/-1;color:#687386}.signature-preview-box{border:2px dashed #8a94a6;padding:34px;text-align:center;margin:18px 0}.preview-select-row{display:flex;align-items:end;gap:8px}.preview-select-row label{min-width:280px}.modal-backdrop iframe{width:100%;height:72vh;border:0}.results-popup h1{font-size:20px}@media(max-width:700px){.dynamic-customer-grid{grid-template-columns:1fr}.reference-banner{align-items:flex-start;flex-direction:column}.result-row{grid-template-columns:1fr}.preview-select-row{align-items:stretch;flex-direction:column}.preview-select-row label{min-width:0}}

/* Field-aware controls and category selection */
.category-heading{display:flex;align-items:center;justify-content:space-between;gap:10px}.category-actions{display:flex;gap:6px}.autofill-search-wrap{display:grid;gap:4px;min-width:210px}.autofill-search{height:30px!important;padding:4px 8px!important;font-size:12px!important}.radio-options{display:grid;gap:6px}.radio-options .choice-line{margin:0}.field-management-table select,.field-management-table input{min-height:32px}
@media(max-width:760px){.category-heading{align-items:flex-start;flex-direction:column}.category-actions{width:100%}.category-actions .button{flex:1}.autofill-search-wrap{min-width:170px}}
.customer-detail-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:12px}.detail-item{border:1px solid #e3e7ec;border-radius:7px;padding:10px 12px;background:#fafbfc;min-width:0}.detail-item small{display:block;color:#657080;margin-bottom:3px}.detail-item b{display:block;overflow-wrap:anywhere}.row-actions{display:flex;gap:6px;align-items:center;white-space:nowrap}
.status.agent_draft{background:#f2e8ff;color:#6930a8}.primary-action{background:var(--primary)!important;color:#fff!important;border-color:var(--primary)!important}.document-count{position:relative;display:inline-flex;align-items:center;white-space:nowrap;padding:5px 9px;border:1px solid var(--border);border-radius:999px;background:#f7f8fb;font-size:12px;font-weight:700;cursor:help}.document-tooltip{display:none;position:absolute;left:0;top:calc(100% + 7px);z-index:80;min-width:260px;max-width:420px;max-height:240px;overflow:auto;padding:9px;background:#172033;color:#fff;border-radius:8px;box-shadow:0 8px 24px rgba(0,0,0,.22);white-space:normal;font-weight:400}.document-tooltip span{display:block;padding:6px 7px;border-bottom:1px solid rgba(255,255,255,.15)}.document-tooltip span:last-child{border-bottom:0}.document-count:hover .document-tooltip,.document-count:focus .document-tooltip{display:block}

/* Agent Fill radio-group alignment */
.agent-fill-form,.agent-fields,.agent-field{ text-align:left; }
.agent-fields{display:grid;gap:16px;}
.agent-field{display:block;width:100%;}
.agent-field-label{font-weight:700;margin-bottom:7px;}
.agent-radio-options{display:grid;gap:8px;justify-items:start;}
.agent-choice-line{display:flex!important;align-items:flex-start!important;justify-content:flex-start!important;gap:9px;width:100%;min-height:26px;margin:0;text-align:left;font-weight:400;}
.agent-choice-line input[type="radio"],.agent-choice-line input[type="checkbox"]{flex:0 0 auto;width:17px!important;height:17px!important;margin:2px 0 0!important;}
.agent-choice-line span{display:block;line-height:1.4;text-align:left;}
.radio-autofill-select{min-width:130px;}

/* Signing workflow alignment and persistent actions */
.sign-header{position:fixed!important;top:0;left:0;right:0;width:100%;z-index:120;height:66px}
.sign-header + .sign-public-shell{padding-top:94px}
.sign-public-shell.review-shell{padding-bottom:94px}
.review-actions{position:fixed!important;left:0;right:0;bottom:0;z-index:90;margin:0!important;padding:12px max(18px,calc((100vw - 1050px)/2))!important;background:rgba(255,255,255,.98)!important;box-shadow:0 -5px 18px rgba(20,30,50,.12);border-top:1px solid var(--border);display:flex;align-items:center;justify-content:flex-end;gap:10px}
.customer-field-block{display:flex;flex-direction:column;gap:7px;min-width:0}
.customer-field-heading{font-weight:700;font-size:14px;display:flex;align-items:center;flex-wrap:wrap;gap:5px}
.choice-line,.radio-choice,.agent-choice-line{display:flex!important;flex-direction:row!important;align-items:center!important;justify-content:flex-start!important;gap:9px!important;width:100%;height:auto!important;min-height:28px;margin:0!important;text-align:left!important;font-weight:400!important}
.choice-line input[type="radio"],.choice-line input[type="checkbox"],.agent-choice-line input[type="radio"],.agent-choice-line input[type="checkbox"]{display:block!important;flex:0 0 auto!important;width:17px!important;height:17px!important;min-width:17px!important;margin:0!important;padding:0!important;vertical-align:middle!important}
.choice-line span,.agent-choice-line span{display:inline!important;line-height:1.35!important;text-align:left!important;margin:0!important}
.checkbox-choice,.agent-checkbox-only{width:max-content!important}
.radio-options,.agent-radio-options{display:grid!important;gap:8px!important;justify-items:stretch!important;align-items:start!important;width:100%}
@media(max-width:760px){
  .sign-header{height:58px;padding:9px 12px}
  .sign-header + .sign-public-shell{padding-top:76px}
  .sign-public-shell.review-shell{padding-bottom:82px}
  .review-actions{padding:9px 10px!important;display:flex!important;flex-direction:row!important;justify-content:flex-end!important}
  .review-actions .button,.review-actions button{width:auto!important;min-height:42px;margin:0!important}
  .review-actions .primary{flex:1 1 auto}
}

.dashboard-stats .stat{display:flex;align-items:center;gap:14px;min-height:104px}.stat-icon{width:46px;height:46px;min-width:46px;border-radius:12px;background:#e5f0fb;color:var(--primary);display:grid;place-items:center}.stat-icon svg{width:25px;height:25px;fill:currentColor}.stat-copy{min-width:0}.stat-copy b{line-height:1}.stat-copy span{display:block;margin-top:7px}.dashboard-stats .stat:nth-child(2) .stat-icon{background:#e2f3e9;color:var(--success)}.dashboard-stats .stat:nth-child(3) .stat-icon{background:#fff3cd;color:#8a6500}.dashboard-stats .stat:nth-child(4) .stat-icon{background:#d9f5fb;color:#08788f}.dashboard-stats .stat:nth-child(5) .stat-icon{background:#fff0d1;color:#9a6100}

.document-count{cursor:pointer!important;position:relative;z-index:2}.document-count:hover,.document-count:focus{z-index:1002;outline:none}.document-tooltip{position:fixed!important;left:auto!important;top:auto!important;z-index:10000!important;min-width:280px;max-width:min(440px,calc(100vw - 32px));max-height:260px;overflow:auto;transform:translate(-12px,34px);pointer-events:auto}.table-wrap:has(.document-count:hover),.table-wrap:has(.document-count:focus){overflow:visible}.panel:has(.document-count:hover),.panel:has(.document-count:focus){position:relative;z-index:1001;overflow:visible}@media(max-width:700px){.document-tooltip{position:absolute!important;left:0!important;top:calc(100% + 7px)!important;transform:none;min-width:min(300px,calc(100vw - 48px))}}

/* Final interface alignment and workflow refinements */
.sidebar a{display:flex;align-items:center;gap:10px;white-space:nowrap}
.nav-icon{display:inline-flex;align-items:center;justify-content:center;width:22px;min-width:22px;height:22px;font-size:15px;line-height:1;color:#fff}
.admin-nav-box .nav-icon{font-size:14px}

/* Consistent control dimensions */
:where(button,.button,input:not([type="checkbox"]):not([type="radio"]),select){min-height:38px}
:where(button,.button){display:inline-flex;align-items:center;justify-content:center;padding:8px 14px;line-height:1.2}
:where(input:not([type="checkbox"]):not([type="radio"]),select){padding:8px 10px;line-height:1.2}
.button.small,button.small,.table-action,.compact-action{min-height:34px;height:34px;padding:6px 10px;font-size:12px}
.standard-action{min-height:40px;height:40px;padding:8px 16px;font-size:14px}
.review-actions .button,.review-actions button{min-width:112px;min-height:40px;height:40px;padding:8px 14px;font-size:14px}

/* Agent Fill */
.agent-fill-form,.agent-fields,.agent-field,.agent-radio-options{text-align:left}
.agent-document-panel h2{margin-bottom:14px}
.agent-choice-line{display:flex!important;flex-direction:row!important;align-items:center!important;justify-content:flex-start!important;gap:9px!important;text-align:left!important}
.agent-choice-line input[type="radio"],.agent-choice-line input[type="checkbox"]{margin:0!important;vertical-align:middle!important}
.agent-choice-line span{display:inline-block!important;line-height:1.35!important;text-align:left!important}
.section-title-row{display:flex;align-items:center;justify-content:space-between;gap:16px}
.section-title-row h2{margin:0 0 4px}.section-title-row p{margin:0;color:var(--muted);font-size:13px}
.quantity-list{display:grid;gap:7px;margin-top:14px}.quantity-row{display:grid;grid-template-columns:minmax(0,1fr) 76px;align-items:center;gap:12px;padding:7px 0;border-top:1px solid var(--border);font-weight:600}.quantity-row input{height:34px;min-height:34px;padding:5px 8px}.empty-agent-fields{margin:0;color:var(--muted);font-size:13px}

/* Customer Fill: field-only documents and fixed review action */
#customerForm{padding-bottom:82px}
.client-fill-sticky-action{position:fixed;left:0;right:0;bottom:0;z-index:115;display:flex;justify-content:center;padding:10px 16px;background:rgba(255,255,255,.96);border-top:1px solid var(--border);box-shadow:0 -4px 16px rgba(15,23,42,.08);backdrop-filter:blur(5px)}
.client-fill-sticky-action button{width:min(520px,100%)}

@media(max-width:760px){
  .section-title-row{align-items:stretch;flex-direction:column}.section-title-row .compact-action{width:100%}
  .quantity-row{grid-template-columns:minmax(0,1fr) 68px}
  :where(button,.button){min-height:38px}
  .review-actions .button,.review-actions button,.client-fill-sticky-action button{min-height:40px;height:40px;font-size:13px}
}

/* Agent Fill tabs */
.agent-fill-tabs{display:flex;gap:6px;margin:16px 0 12px;border-bottom:1px solid #d9e1e8}
.agent-tab-button{border:1px solid #c8d2dc;border-bottom:0;background:#eef3f7;color:#243746;padding:9px 16px;min-height:38px;border-radius:7px 7px 0 0;font-weight:700;cursor:pointer}
.agent-tab-button.active{background:#fff;color:#003e7b;border-color:#003e7b;box-shadow:inset 0 3px 0 #003e7b}
.agent-tab-panel[hidden]{display:none!important}
.agent-field-label{display:flex;align-items:center;justify-content:space-between;gap:12px;width:100%;margin-bottom:6px}
.agent-required-label{margin-left:auto;color:#dc3545;font-size:.82rem;font-weight:700;white-space:nowrap}
.quantity-update-form .quantity-row{display:grid;grid-template-columns:minmax(0,1fr) 90px;align-items:center;gap:12px}
@media(max-width:640px){.agent-fill-tabs{overflow-x:auto}.agent-tab-button{white-space:nowrap;flex:1}.agent-field-label{align-items:flex-start}.quantity-update-form .section-title-row{align-items:flex-start;flex-direction:column}}
/* Compact field layout and signing controls */
.compact-fields{display:grid;gap:8px}.compact-field-row{display:grid;grid-template-columns:minmax(190px,36%) minmax(0,1fr);align-items:center;gap:14px;padding:8px 0;border-bottom:1px solid #edf0f4}.compact-field-row:last-child{border-bottom:0}.compact-field-name{display:flex;align-items:center;justify-content:space-between;gap:8px;font-size:13px;font-weight:600}.compact-field-input>*{width:100%;margin:0}.compact-field-input input,.compact-field-input select,.compact-field-input textarea{min-height:38px}.compact-field-row.multiline-row{align-items:start}.compact-field-row.multiline-row .compact-field-name{padding-top:9px}.inline-choice-list{display:grid;gap:7px}.inline-choice{display:flex!important;align-items:flex-start!important;justify-content:flex-start!important;gap:8px!important;text-align:left!important;width:100%!important;margin:0!important}.inline-choice input[type=radio],.inline-choice input[type=checkbox]{width:17px!important;height:17px!important;min-height:17px!important;flex:0 0 17px!important;margin:2px 0 0!important}.inline-choice span{line-height:1.35;text-align:left}.agent-required-label{margin-left:auto}.signature-settings-box,.fixed-signatures{margin:12px 0;padding:12px;border:1px solid #dce3eb;border-radius:8px;background:#f8fafc}.fixed-signature-head,.fixed-signature-row{display:grid;grid-template-columns:55px 65px 65px 70px 1fr;gap:6px;align-items:center}.fixed-signature-head{font-size:11px;font-weight:700;color:#596579;margin-bottom:4px}.fixed-signature-row{margin-bottom:5px}.fixed-signature-row input,.fixed-signature-row select{min-width:0;padding:6px;height:34px}.party-two-panel{margin-bottom:12px}@media(max-width:700px){.compact-field-row{grid-template-columns:1fr;gap:5px}.compact-field-name{align-items:flex-start}.fixed-signature-head{display:none}.fixed-signature-row{grid-template-columns:repeat(2,1fr)}.fixed-signature-row select{grid-column:1/-1}}

/* Template signature management and restrained global UI refinement */
.detected-signatures{margin-top:14px;padding-top:12px;border-top:1px solid var(--border)}
.detected-signatures h4{display:flex;align-items:center;gap:8px;margin:0 0 8px;font-size:13px}
.count-badge{display:inline-flex;align-items:center;justify-content:center;min-width:24px;height:22px;padding:0 7px;border-radius:999px;background:#003e7b;color:#fff;font-size:11px}
.detected-signature-card{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:9px 10px;margin:6px 0;border:1px solid #dce3eb;border-radius:8px;background:#fff}
.detected-signature-card b,.detected-signature-card small{display:block}.detected-signature-card small{margin-top:2px;color:var(--muted);font-size:11px}
.signature-field-meta{display:flex;gap:6px;flex-wrap:wrap;justify-content:flex-end}.signature-field-meta span{padding:4px 7px;border-radius:6px;background:#eef4f9;color:#34475a;font-size:11px;white-space:nowrap}
.fixed-signatures{overflow:visible}.fixed-signature-list{display:grid;gap:8px;margin-top:12px}.fixed-signature-card{border:1px solid #dce3eb;border-radius:9px;background:#fff;padding:10px}
.fixed-signature-card-head{display:flex;align-items:center;justify-content:space-between;gap:10px}.fixed-signature-card-head>div{display:flex;gap:5px}
.fixed-signature-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin-top:10px;padding-top:10px;border-top:1px solid #edf1f5}
.fixed-signature-fields label{font-size:11px;font-weight:700;color:#465568}.fixed-signature-fields input,.fixed-signature-fields select{width:100%;height:34px;min-height:34px;margin-top:3px;padding:5px 7px}
.fixed-signature-fields label:last-child{grid-column:1/-1}.compact-empty{padding:10px;margin:0;font-size:12px}
/* Consistent rhythm across existing HTML pages */
.page-head{align-items:center;margin-bottom:14px}.page-head h1{letter-spacing:-.02em}.panel{border-radius:10px}.panel>h2:first-child,.panel>h3:first-child{margin-top:0}
.table-wrap table{border-collapse:separate;border-spacing:0}.table-wrap th{font-size:11px;text-transform:none;letter-spacing:.01em}.table-wrap td{vertical-align:middle}
label>input,label>select,label>textarea{margin-top:5px}.button,button,input,select,textarea{max-width:100%}
.modal-card,.panel,.compact-list{box-shadow:0 2px 10px rgba(20,45,70,.045)}
@media(max-width:760px){.detected-signature-card{align-items:flex-start;flex-direction:column}.signature-field-meta{justify-content:flex-start}.fixed-signature-card-head{align-items:flex-start}.fixed-signature-card-head>div{flex-wrap:wrap;justify-content:flex-end}.fixed-signature-fields{grid-template-columns:1fr 1fr}.page-head{align-items:stretch;flex-direction:column}.page-head>.button,.page-head>div+.button{width:100%}}
@media(max-width:430px){.fixed-signature-fields{grid-template-columns:1fr}.fixed-signature-fields label:last-child{grid-column:auto}.fixed-signature-card-head{flex-direction:column}.fixed-signature-card-head>div{width:100%}.fixed-signature-card-head .button{flex:1}}

/* 2026-07 template tabs, agent fill and management refinements */
.template-editor-layout.single-column{display:block}.template-settings-tab{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:16px;align-items:start}.template-settings-tab>label:first-child,.template-settings-tab>.settings-two,.template-settings-tab>h2,.template-settings-tab>.signature-settings-box,.template-settings-tab>.fixed-signatures,.template-settings-tab>hr,.template-settings-tab>h2:last-of-type,.template-settings-tab>.help-text,.template-settings-tab>input[type=file]{grid-column:1/-1}.template-settings-tab>.setting-check{margin:0}.template-settings-tab>.wide{width:auto;min-width:180px}.tabs{overflow-x:auto;white-space:nowrap}.archive-search{display:flex;gap:8px;align-items:center;margin-bottom:16px}.archive-search input{max-width:480px}.status-rule-box{display:grid;grid-template-columns:1fr 1fr;gap:8px;border:1px solid var(--border);border-radius:9px;padding:12px}.status-rule-box legend{font-weight:700;padding:0 6px}.small-code{font-size:12px;color:var(--muted)}.email-html-preview{width:100%;height:420px;border:1px solid var(--border);background:#fff;margin-top:12px}.agent-customer-sticky{position:sticky;top:0;z-index:25;display:flex;justify-content:space-between;align-items:center;gap:18px;margin-bottom:12px;border-top:4px solid var(--primary);box-shadow:0 5px 18px rgba(20,35,60,.12)}.agent-customer-sticky h1{margin:0 0 4px}.agent-customer-sticky p{margin:0;color:var(--muted)}.agent-customer-summary{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:7px 14px;font-size:13px}.agent-customer-summary span{white-space:nowrap}.radio-option-list{display:flex;flex-direction:column;align-items:flex-start;gap:7px}.radio-option{display:grid!important;grid-template-columns:18px minmax(0,1fr)!important;align-items:start!important;gap:8px!important}.radio-option input[type=radio]{grid-column:1!important;margin:2px 0 0!important;position:static!important}.radio-option span{grid-column:2!important;margin:0!important;line-height:1.35!important}.admin-nav-box a{white-space:nowrap}
@media(max-width:800px){.template-settings-tab{grid-template-columns:1fr}.template-settings-tab>*{grid-column:1!important}.agent-customer-sticky{position:sticky;top:0;align-items:flex-start;flex-direction:column}.agent-customer-summary{justify-content:flex-start}.status-rule-box{grid-template-columns:1fr}.archive-search{align-items:stretch;flex-direction:column}.archive-search input{max-width:none}}
/* Joint-template controls */
.joint-template-check{margin:4px 0 0!important}.joint-template-help{margin:0 0 12px!important;line-height:1.45}.signature-settings-box>label{display:flex;flex-direction:column;gap:6px}.signature-settings-box>.joint-template-check{display:flex;flex-direction:row;align-items:center;gap:8px}.party-two-panel .section-title-row{margin-bottom:6px}

/* Compact explanation tooltips */
.info-tip{display:inline-flex;align-items:center;justify-content:center;width:19px;height:19px;border-radius:50%;background:#003e7b;color:#fff;font-weight:700;font-size:12px;cursor:help;position:relative;flex:0 0 19px;margin-left:6px;vertical-align:middle}
.info-tip::after{content:attr(data-tip);position:absolute;left:50%;top:calc(100% + 8px);transform:translateX(-50%);width:min(320px,75vw);padding:9px 11px;background:#172033;color:#fff;border-radius:6px;font-size:12px;font-weight:400;line-height:1.35;white-space:normal;box-shadow:0 8px 24px rgba(0,0,0,.22);opacity:0;pointer-events:none;z-index:10000;text-align:left}
.info-tip:hover::after,.info-tip:focus::after{opacity:1}
.signature-party-select{display:flex;align-items:center;gap:6px;margin:0;font-size:12px}.signature-party-select select{height:32px;min-width:92px;padding:4px 28px 4px 8px}
.joint-template-party-list{display:grid;gap:8px}.joint-template-party-list .compact-field-row{margin:0}
@media(max-width:700px){.info-tip::after{position:fixed;left:12px;right:12px;top:auto;bottom:16px;transform:none;width:auto}.detected-signature-card{align-items:flex-start}.signature-field-meta{align-items:flex-start}}
/* Category management and compact template list additions */
.template-list-tools{padding:12px 16px;margin-bottom:12px}.compact-search{display:grid;grid-template-columns:minmax(170px,260px) minmax(240px,520px);align-items:center;gap:12px;margin:0}.compact-search input{margin:0}.page-actions{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.modal-backdrop{position:fixed;inset:0;background:rgba(15,23,42,.55);z-index:5000;display:grid;place-items:center;padding:20px}.modal-backdrop[hidden]{display:none}.modal-card{width:min(760px,100%);max-height:88vh;overflow:auto;background:#fff;border-radius:12px;box-shadow:0 24px 70px rgba(0,0,0,.25);padding:18px}.modal-head{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:14px}.modal-head h2{margin:0}.icon-button{border:0;background:transparent;font-size:28px;line-height:1;cursor:pointer}.category-management-list{display:grid;gap:8px}.category-management-row{display:grid;grid-template-columns:minmax(220px,1fr) 100px auto;align-items:end;gap:10px;padding:10px;border:1px solid #dbe2ea;border-radius:8px}.category-management-row label,.add-category-form label{margin:0}.category-sort-field input{width:100%}.category-delete-button{margin-bottom:1px}.add-category-form{display:grid;grid-template-columns:minmax(220px,1fr) 100px auto;gap:10px;align-items:end}.modal-actions{display:flex;justify-content:flex-end;margin-top:14px}.modal-open{overflow:hidden}@media(max-width:700px){.compact-search{grid-template-columns:1fr}.category-management-row,.add-category-form{grid-template-columns:1fr}.category-delete-button,.add-category-form .button{width:100%}}

/* Final professional UI consistency pass */
:root{--control-h:38px;--radius:8px;--shadow:0 4px 14px rgba(15,38,68,.06)}
body{font-size:14px;line-height:1.45}
.admin-main{padding:24px 28px}
.page-head{gap:16px;margin-bottom:18px;align-items:flex-start}
.page-head h1{font-size:26px;line-height:1.2}.page-head p{font-size:13px;max-width:760px}
.panel,.stat,.doc-card,.login-card,.complete-card{border-radius:10px;box-shadow:var(--shadow)}
.panel{padding:18px}.panel+.panel{margin-top:16px}
.section-head,.section-title-row,.preview-heading,.modal-head{display:flex;align-items:center;justify-content:space-between;gap:12px}
h1,h2,h3,h4{color:#15253a}h2{font-size:20px}h3{font-size:16px}
.button,button,input:not([type=checkbox]):not([type=radio]):not([type=color]),select{min-height:var(--control-h);height:var(--control-h);border-radius:var(--radius)}
.button,button{display:inline-flex;align-items:center;justify-content:center;gap:6px;padding:0 14px;line-height:1;white-space:nowrap;font-size:13px}
.button.small,button.small{min-height:32px;height:32px;padding:0 10px;font-size:12px}
textarea{border-radius:var(--radius);padding:10px;min-height:92px;resize:vertical}
input,textarea,select{border-color:#cbd5e1;transition:border-color .15s,box-shadow .15s}
input:focus,textarea:focus,select:focus{outline:0;border-color:#4b82b8;box-shadow:0 0 0 3px rgba(0,62,123,.12)}
label{gap:5px;margin:0}.form-stack{gap:14px}.two,.settings-two{gap:12px}
.page-actions,.selector-controls,.modal-actions,.sheet-actions,.review-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.table-wrap{border:1px solid var(--border);border-radius:9px;background:#fff}table{font-size:13px}th{background:#f7f9fc;font-weight:700;color:#455468;white-space:nowrap}th,td{padding:10px 12px;vertical-align:middle}tbody tr:hover{background:#fafcff}
.tabs{display:flex;gap:4px;border-bottom:1px solid var(--border);padding:0 2px;margin-bottom:16px}.tab{border:0;border-radius:7px 7px 0 0;background:transparent;color:#526174;padding:0 13px;height:38px}.tab.active{background:#003e7b;color:#fff}
.compact-row{padding:6px 10px;min-height:40px}.compact-list-head{min-height:36px;background:#f7f9fc;font-size:12px;font-weight:700;color:#526174}
.status,.selection-badge,.count-badge{white-space:nowrap}
.form-toolbar{display:flex;align-items:center;gap:6px;flex-wrap:wrap;padding:8px;border:1px solid var(--border);border-bottom:0;border-radius:8px 8px 0 0;background:#f8fafc}.form-toolbar button,.form-toolbar select,.form-toolbar input{height:30px;min-height:30px;font-size:12px}
.code-editor{border-radius:0 0 8px 8px}
.modal-card{border-radius:12px}.modal-head{position:sticky;top:-18px;background:#fff;z-index:2;padding:6px 0 10px}
.sidebar{width:260px;padding:18px 14px}.admin-main{margin-left:260px}.sidebar .brand{padding:8px 10px 18px}.sidebar a{min-height:40px;padding:9px 10px;display:flex;align-items:center;gap:9px;font-size:13px}.sidebar .nav-icon{width:20px;text-align:center;flex:0 0 20px}.admin-nav-box{padding:5px}.admin-nav-box a{padding:8px 7px}

/* Portal-based explanation tooltip: never clipped and no question-mark cursor */
.info-tip{display:inline-flex!important;align-items:center!important;justify-content:center!important;width:18px!important;height:18px!important;min-width:18px!important;border-radius:50%!important;background:#003e7b!important;color:#fff!important;font:700 12px/18px Arial,sans-serif!important;cursor:pointer!important;position:relative!important;vertical-align:middle!important;margin:0 0 0 6px!important;flex:0 0 18px!important;border:0!important;box-shadow:none!important}
.info-tip::after{display:none!important}
.info-tooltip-portal{position:fixed;z-index:50000;width:min(340px,calc(100vw - 24px));max-height:min(320px,60vh);overflow:auto;padding:10px 12px;background:#172033;color:#fff;border-radius:8px;box-shadow:0 12px 34px rgba(0,0,0,.3);font-size:12px;font-weight:400;line-height:1.45;text-align:left;pointer-events:none;opacity:0;transform:translateY(3px);transition:opacity .12s,transform .12s}
.info-tooltip-portal.open{opacity:1;transform:none}
.info-label-row{display:inline-flex;align-items:center;gap:4px;min-width:0}.section-title-row .info-tip,.preview-heading .info-tip{margin-left:4px!important}

/* Template-management alignment */
.template-settings-tab{gap:14px}.signature-settings-box{display:grid;gap:10px}.signature-settings-box>.section-title-row{margin-bottom:0}.signature-settings-box label{min-width:0}.joint-template-check{min-height:38px;padding:8px 10px;border:1px solid var(--border);border-radius:8px;background:#f9fbfd}.detected-signature-card{align-items:center;gap:12px}.fixed-signature-card{border:1px solid var(--border);border-radius:9px;padding:12px;background:#fbfcfe}.fixed-signature-card .button{align-self:center}

@media(max-width:900px){.sidebar{width:auto}.admin-main{margin-left:0;padding:16px}.page-head{flex-direction:column}.page-actions{width:100%}.page-actions .button,.page-actions button{flex:1 1 auto}.section-head,.section-title-row,.preview-heading{align-items:flex-start}.table-wrap{overflow:auto}.template-settings-tab{grid-template-columns:1fr!important}}
@media(max-width:600px){.panel{padding:13px}.button,button{min-height:38px;height:38px}.button.small,button.small{min-height:34px;height:34px}.page-head h1{font-size:22px}.tabs{overflow-x:auto}.tab{flex:0 0 auto}.info-tooltip-portal{left:12px!important;right:12px!important;bottom:12px!important;top:auto!important;width:auto!important}.two,.settings-two{grid-template-columns:1fr!important}}

/* ================================================================
   2026 interface redesign
   A clean workspace layout with a light navigation rail, compact
   controls, stronger hierarchy and consistent responsive behaviour.
   ================================================================ */
:root{
  --ui-primary:#003e7b;
  --ui-primary-2:#075aa5;
  --ui-success:#198754;
  --ui-warning:#ffc107;
  --ui-info:#0dcaf0;
  --ui-accent:#faaa16;
  --ui-danger:#dc3545;
  --ui-canvas:#edf2f7;
  --ui-surface:#ffffff;
  --ui-surface-soft:#f7f9fc;
  --ui-line:#d7e0ea;
  --ui-text:#182230;
  --ui-muted:#64748b;
  --ui-shadow:0 10px 28px rgba(22,45,73,.08);
  --ui-radius:14px;
  --ui-control-height:40px;
}
html{background:var(--ui-canvas)}
body{background:var(--ui-canvas);color:var(--ui-text);font-family:Inter,Segoe UI,Arial,sans-serif;line-height:1.45}

/* New light navigation rail */
.sidebar{
  width:274px;
  padding:18px 14px;
  gap:5px;
  background:#fff;
  border-right:1px solid var(--ui-line);
  box-shadow:8px 0 24px rgba(30,58,88,.05);
  overflow-y:auto;
  z-index:50;
}
.sidebar .brand{
  margin:-18px -14px 13px;
  padding:22px 22px;
  min-height:74px;
  display:flex;
  align-items:center;
  color:#fff;
  background:linear-gradient(135deg,var(--ui-primary),var(--ui-primary-2));
  font-size:23px;
  letter-spacing:.2px;
  border-radius:0;
}
.sidebar>a,.sidebar .admin-nav-box>a{
  min-height:42px;
  display:flex;
  align-items:center;
  gap:11px;
  padding:9px 11px;
  color:#334155;
  border:1px solid transparent;
  border-radius:10px;
  white-space:nowrap;
  font-size:14px;
  font-weight:650;
  transition:background .16s ease,border-color .16s ease,color .16s ease,transform .16s ease;
}
.sidebar>a:hover,.sidebar .admin-nav-box>a:hover{
  color:var(--ui-primary);
  background:#eef6ff;
  border-color:#d5e7f8;
  transform:translateX(2px);
}
.sidebar .nav-icon{
  width:26px;height:26px;min-width:26px;
  display:grid;place-items:center;
  border-radius:7px;
  background:#eaf3fc;
  color:var(--ui-primary);
  font-size:14px;
  line-height:1;
}
.admin-nav-box{
  margin:9px 0;
  padding:9px;
  border:1px solid #f0b8bd;
  background:#fff8f8;
  border-radius:12px;
}
.admin-nav-box .nav-heading{
  padding:2px 7px 7px;
  color:#9f2933;
  font-size:11px;
  font-weight:800;
  letter-spacing:.1em;
  text-transform:uppercase;
}
.admin-main{margin-left:274px;padding:26px 30px 42px;min-height:100vh}

/* Page structure */
.page-head{
  min-height:68px;
  margin:0 0 20px;
  padding:0 2px;
  gap:18px;
}
.page-head h1,.narrow h1{font-size:27px;line-height:1.2;letter-spacing:-.02em;color:#102a43}
.page-head p,.narrow>p{font-size:14px;color:var(--ui-muted)}
.section-head,.preview-heading,.compact-head{
  display:flex;align-items:center;justify-content:space-between;gap:14px;flex-wrap:wrap;
}
.panel,.stat,.doc-card,.login-card,.complete-card,.public-card,.welcome,.final-step{
  border:1px solid var(--ui-line);
  border-radius:var(--ui-radius);
  background:var(--ui-surface);
  box-shadow:var(--ui-shadow);
}
.panel{padding:20px}
.panel h2{font-size:19px;color:#15324e;margin:0 0 14px}
.panel h3{color:#183b56}

/* Completely revised metric cards */
.stats{gap:14px;grid-template-columns:repeat(5,minmax(0,1fr));margin-bottom:20px}
.stat{position:relative;min-height:112px;padding:19px 18px 16px;overflow:hidden}
.stat::after{content:"";position:absolute;right:-26px;bottom:-34px;width:100px;height:100px;border-radius:50%;background:rgba(0,62,123,.06)}
.stat b{font-size:29px;line-height:1;color:#102f4c;margin:7px 0 8px}
.stat span{font-size:12px;letter-spacing:.035em;font-weight:750;color:var(--ui-muted)}
.stat .stat-icon,.stat>i:first-child{position:relative;z-index:1;width:30px;height:30px;display:grid;place-items:center;border-radius:9px;background:#eaf3fc;color:var(--ui-primary)}

/* Uniform controls */
.button,button,input:not([type="checkbox"]):not([type="radio"]),select,textarea{
  font-family:inherit;
}
.button,button{
  min-height:var(--ui-control-height);
  height:var(--ui-control-height);
  padding:0 14px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:7px;
  border-radius:9px;
  font-size:13px;
  line-height:1;
  font-weight:750;
  white-space:nowrap;
  box-shadow:none;
}
.button.small,button.small,.table-action{min-height:34px;height:34px;padding:0 11px;font-size:12px;border-radius:8px}
.button.large,button.large{height:46px;min-height:46px;padding:0 20px;font-size:14px}
input:not([type="checkbox"]):not([type="radio"]),select{
  height:var(--ui-control-height);
  min-height:var(--ui-control-height);
  padding:7px 11px;
  border:1px solid #cbd7e3;
  border-radius:9px;
  color:var(--ui-text);
  background:#fff;
  font-size:13px;
  outline:none;
}
textarea{min-height:108px;padding:10px 11px;border:1px solid #cbd7e3;border-radius:9px;color:var(--ui-text);background:#fff;font-size:13px;outline:none;resize:vertical}
input:focus,select:focus,textarea:focus{border-color:#4c91cf;box-shadow:0 0 0 3px rgba(0,62,123,.11)}
label{font-size:13px;color:#334155;gap:6px}
.check{min-height:32px}
.check input,.choice-line input,input[type="checkbox"],input[type="radio"]{accent-color:var(--ui-primary)}

/* Tables and lists */
.table-wrap{border:1px solid var(--ui-line);border-radius:12px;background:#fff;overflow:auto;position:relative}
table{border-collapse:separate;border-spacing:0}
th{position:sticky;top:0;z-index:2;padding:11px 12px;background:#f4f7fb;color:#536578;font-size:11px;text-transform:uppercase;letter-spacing:.045em;border-bottom:1px solid var(--ui-line)}
td{padding:11px 12px;font-size:13px;border-bottom:1px solid #e8edf3;vertical-align:middle}
tbody tr:last-child td{border-bottom:0}
tbody tr:hover td{background:#f8fbfe}
.status{display:inline-flex;align-items:center;min-height:25px;padding:4px 9px;border-radius:999px;font-size:11px}

/* Tabs */
.tabs,.tab-list,.template-tabs{display:flex;align-items:center;gap:6px;flex-wrap:wrap;padding:5px;background:#e9eff6;border:1px solid #d6e0ea;border-radius:12px;margin-bottom:18px}
.tab-button,.tab-link,[data-tab]{min-height:36px;height:36px;padding:0 13px;border:0;border-radius:8px;background:transparent;color:#526579;font-size:13px;font-weight:750}
.tab-button.active,.tab-link.active,[data-tab].active{background:#fff;color:var(--ui-primary);box-shadow:0 2px 8px rgba(28,55,83,.09)}

/* Forms and compact field layouts */
.form-stack{gap:14px;margin-top:18px}
.two,.settings-two{gap:14px}
.field-row,.compact-field-row{padding:10px 0;gap:10px}
.customer-doc-fields{padding:15px;gap:11px;border-radius:11px;background:#fbfcfe}
.required-mark{background:#fff1f2;color:#b42331}.optional-mark{background:#edf3f8;color:#536578}

/* Modals */
.modal{backdrop-filter:blur(3px);background:rgba(15,32,49,.58)}
.modal-card{width:min(760px,calc(100vw - 30px));max-height:calc(100vh - 34px);overflow:auto;padding:21px;border-radius:16px;border:1px solid rgba(255,255,255,.55);box-shadow:0 24px 70px rgba(9,30,52,.28)}

/* Explanation icons: always orange, truly inline and never clipped */
.info-tip{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  flex:0 0 18px!important;
  width:18px!important;
  height:18px!important;
  min-width:18px!important;
  margin-left:6px!important;
  padding:0!important;
  vertical-align:middle!important;
  position:relative!important;
  top:-1px!important;
  border:0!important;
  border-radius:50%!important;
  background:var(--ui-accent)!important;
  color:#3d2a00!important;
  font:800 12px/18px Arial,sans-serif!important;
  text-align:center!important;
  cursor:pointer!important;
  user-select:none!important;
  box-shadow:0 0 0 2px rgba(250,170,22,.16)!important;
}
.info-tip:hover,.info-tip:focus{background:#ffbd38!important;box-shadow:0 0 0 4px rgba(250,170,22,.22)!important;outline:none!important}
.label-title-row,.heading-with-tip,.inline-tip-row{display:inline-flex!important;align-items:center!important;gap:0!important;min-width:0!important;max-width:100%!important}
.label-title-row{font-weight:700;line-height:1.3;margin-bottom:1px}
.info-tooltip-portal{
  position:fixed!important;
  z-index:2147483647!important;
  display:none;
  max-width:360px;
  max-height:310px;
  overflow:auto;
  padding:10px 12px;
  color:#fff;
  background:#172b3d;
  border:1px solid rgba(255,255,255,.12);
  border-radius:10px;
  box-shadow:0 14px 38px rgba(0,0,0,.28);
  font-size:12px;
  line-height:1.45;
  pointer-events:none;
  white-space:normal;
}
.info-tooltip-portal.open{display:block}

/* Public signing experience */
.sign-header{height:58px;padding:0 20px;border-bottom:1px solid var(--ui-line);box-shadow:0 3px 16px rgba(23,50,77,.06)}
.sign-header b{font-size:19px}
.public-shell{padding:20px;max-width:980px}
.public-card{padding:22px}
.stepper{gap:6px}.stepper span{padding:7px 12px;font-size:12px}
.review-actions{padding:11px 0;gap:9px}

/* Responsive redesign */
@media(max-width:1180px){.stats{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:900px){
  .sidebar{position:sticky;top:0;width:100%;height:auto;max-height:none;flex-direction:row;align-items:center;padding:8px 10px;gap:5px;border-right:0;border-bottom:1px solid var(--ui-line);overflow-x:auto;overflow-y:hidden}
  .sidebar .brand{position:sticky;left:-10px;z-index:3;min-width:118px;min-height:42px;margin:-8px 5px -8px -10px;padding:9px 14px;font-size:17px}
  .sidebar>a,.sidebar .admin-nav-box>a{min-width:max-content;min-height:36px;height:36px;padding:5px 9px;font-size:12px}
  .sidebar .nav-icon{width:23px;height:23px;min-width:23px}
  .admin-nav-box{display:flex;align-items:center;gap:4px;margin:0;padding:3px;border-radius:9px;min-width:max-content}
  .admin-nav-box .nav-heading{display:none}
  .admin-main{margin-left:0;padding:16px}
  .stats{grid-template-columns:repeat(2,minmax(0,1fr))}
  .page-head{align-items:flex-start;flex-direction:column;min-height:0;gap:10px}
  .page-head>div:last-child{width:100%;display:flex;flex-wrap:wrap;gap:7px}
  .panel{padding:15px}
}
@media(max-width:600px){
  :root{--ui-control-height:38px}
  .admin-main{padding:11px}
  .stats{grid-template-columns:1fr 1fr;gap:9px}.stat{min-height:96px;padding:14px}.stat b{font-size:24px}
  .page-head h1,.narrow h1{font-size:23px}
  .panel{padding:13px;border-radius:11px}
  .button,button{padding:0 11px;font-size:12px}
  .section-head,.preview-heading,.compact-head{align-items:flex-start}
  .section-head>div:last-child,.bulk-request-actions{width:100%;display:flex;gap:6px;flex-wrap:wrap}
  .public-shell{padding:8px}.public-card{padding:13px}
  .info-tooltip-portal{left:10px!important;right:10px!important;top:auto!important;bottom:10px!important;width:auto!important;max-width:none!important;max-height:42vh}
}

/* 2026-07 customer management and request-selection refinements */
@media(min-width:901px){
  .sidebar{width:330px}
  .admin-main{margin-left:330px}
}
.customer-all-fields-table table{min-width:max-content}
.customer-all-fields-table th,.customer-all-fields-table td{max-width:260px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.customer-all-fields-table td:hover{white-space:normal;overflow:visible}
.compact-filter-panel{margin-bottom:16px}
.filter-row{display:flex;align-items:flex-end;gap:8px;flex-wrap:wrap}
.filter-row label{flex:1 1 320px;margin:0}
.template-option{cursor:pointer}
.template-option:hover{background:#f3f8fd}
.template-option:has(.template-checkbox:checked){background:#eaf4ff;box-shadow:inset 3px 0 0 var(--ui-primary)}
.selector-title{display:flex!important;align-items:center!important;gap:12px!important;line-height:1!important}
.selector-title h2{margin:0!important;line-height:26px!important}
.selection-badge{display:inline-flex!important;align-items:center!important;gap:4px!important;height:26px!important;min-height:26px!important;margin:0!important;vertical-align:middle!important}
.selection-badge span{display:inline-block!important;line-height:1!important}
@media(max-width:900px){.customer-all-fields-table th,.customer-all-fields-table td{max-width:210px}}
/* Final consistency and workflow corrections */
.dashboard-six-grid{grid-template-columns:repeat(3,minmax(220px,1fr));max-width:1120px;margin:0 auto 24px}.dashboard-stat-link{color:inherit;text-decoration:none;transition:transform .15s ease,box-shadow .15s ease}.dashboard-stat-link:hover{transform:translateY(-2px);box-shadow:0 10px 24px rgba(0,62,123,.12)}.dashboard-filter-panel{overflow:visible}.dashboard-filter-panel .dashboard-filters{grid-template-columns:repeat(3,minmax(190px,1fr));align-items:end}.dashboard-document-filter{position:relative;z-index:30}.dashboard-document-filter .multi-select-menu{z-index:6000}
.joint-template-check{display:flex!important;align-items:center!important;gap:9px!important}.joint-template-check .joint-help-tip{margin-left:auto!important}.joint-template-check input{flex:0 0 auto}.joint-template-check span:not(.info-tip){flex:1}
.autofill-picker-wrap{display:flex;align-items:center;gap:7px}.visually-hidden-select{position:absolute!important;width:1px!important;height:1px!important;opacity:0!important;pointer-events:none}.autofill-picker-button{width:100%;justify-content:flex-start;text-align:left;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.autofill-picker-options{display:grid;gap:6px;margin-top:12px;max-height:55vh;overflow:auto}.autofill-option-button{width:100%;text-align:left;background:#fff;color:#1f2937;border:1px solid #dbe3ec}.autofill-option-button:hover,.autofill-option-button.selected{border-color:#003e7b;background:#edf5fc;color:#003e7b}
.inline-choice-list,.radio-option-list{display:grid!important;gap:8px!important}.inline-choice,.radio-option{display:grid!important;grid-template-columns:18px minmax(0,1fr)!important;align-items:start!important;gap:8px!important;margin:0!important;text-align:left!important}.inline-choice input[type=radio],.inline-choice input[type=checkbox]{grid-column:1;width:17px!important;height:17px!important;margin:2px 0 0!important}.inline-choice span{grid-column:2;line-height:1.35!important}
.customer-doc-fields,.agent-document-panel{border:1px solid #dce4ed;border-radius:12px;padding:14px;margin:0 0 12px;background:#fff}.customer-doc-fields legend{padding:0 7px;font-weight:700;color:#003e7b}.compact-field-row{min-height:52px}.compact-field-input input,.compact-field-input select,.compact-field-input textarea{width:100%}
.review-actions .button,.review-actions button{width:124px!important;min-width:124px!important;height:42px!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;padding:8px 12px!important}.signature-pad-section canvas{border:1px solid #bcc8d5;border-radius:10px;background:#fff;touch-action:none}
.app-dialog-backdrop{position:fixed;inset:0;background:rgba(15,32,49,.58);z-index:10000;display:grid;place-items:center;padding:18px}.app-dialog{width:min(440px,100%);background:#fff;border-radius:14px;border:1px solid #dce4ed;box-shadow:0 24px 70px rgba(0,0,0,.25);padding:20px}.app-dialog h2{margin:0 0 9px;color:#003e7b}.app-dialog p{margin:0 0 18px;line-height:1.5}.app-dialog-actions{display:flex;justify-content:flex-end;gap:8px}
@media(max-width:900px){.dashboard-six-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.dashboard-filter-panel .dashboard-filters{grid-template-columns:1fr 1fr}}
@media(max-width:620px){.dashboard-six-grid{grid-template-columns:1fr}.dashboard-filter-panel .dashboard-filters{grid-template-columns:1fr}.compact-field-row{grid-template-columns:1fr;gap:6px}.review-actions .button,.review-actions button{width:auto!important;min-width:0!important;flex:1}}

/* July 2026 targeted layout fixes */
@media (min-width:1180px){.dashboard-filters{display:grid!important;grid-template-columns:1.05fr 1fr .9fr .9fr .9fr 1.35fr auto!important;align-items:end;gap:10px}.dashboard-filters .filter-actions{display:flex;flex-wrap:nowrap;align-items:center}.dashboard-filter-panel{overflow:visible}}
.document-filter-menu{min-width:360px;max-width:480px;padding:8px!important}.document-category-heading{display:block;color:#003e7b;padding:10px 10px 5px;border-bottom:1px solid #dfe5ec}.document-filter-option{display:flex!important;align-items:center!important;gap:10px!important;min-height:38px;padding:7px 10px!important;white-space:normal}.document-filter-option input{width:20px!important;height:20px!important;flex:0 0 20px;margin:0!important}.document-filter-option span{line-height:1.3;min-width:0}.document-upload-actions{display:grid;grid-template-columns:auto minmax(220px,1fr) auto;gap:10px;align-items:end}.fixed-signature-fields{grid-template-columns:repeat(5,minmax(75px,1fr))!important;gap:8px!important}.fixed-signature-card{padding:10px!important}.asset-form{display:grid;grid-template-columns:1fr 1.4fr 1.2fr auto;gap:12px;align-items:end}.asset-list{display:grid;gap:12px}.asset-card{display:grid;grid-template-columns:1fr 1.4fr 1.1fr auto auto;gap:10px;align-items:end;border:1px solid #dfe5ec;border-radius:12px;padding:12px}.slug-control{display:flex;align-items:center;border:1px solid #cfd7e3;border-radius:8px;overflow:hidden;background:#f6f8fb}.slug-control span{padding:0 8px;font-size:12px;color:#667085;white-space:nowrap}.slug-control input{border:0!important;border-radius:0!important;min-width:100px}.customer-doc-fields{border:1px solid #dfe5ec!important;border-radius:12px!important;padding:14px!important;margin-bottom:14px!important;background:#fff}.customer-doc-fields legend{font-weight:700;color:#003e7b;padding:0 6px}.compact-field-row{display:grid!important;grid-template-columns:minmax(180px,34%) minmax(0,1fr)!important;gap:16px!important;align-items:center!important;padding:10px 0!important;border-bottom:1px solid #edf1f5}.compact-field-row:last-child{border-bottom:0}.compact-field-row.multiline-row{align-items:start!important}.compact-field-name{display:flex!important;justify-content:space-between!important;align-items:center!important;gap:10px!important}.inline-choice-list{display:grid!important;gap:8px!important}.inline-choice{display:flex!important;align-items:center!important;gap:8px!important;text-align:left!important}.inline-choice input{margin:0!important;flex:0 0 auto}.inline-choice span{line-height:1.3}.template-settings-tab .setting-check{margin-top:10px}.signature-party-select{min-width:150px}.multi-select-filter{position:relative;z-index:30}.multi-select-menu{z-index:9999!important}
@media(max-width:900px){.dashboard-filters,.asset-form,.asset-card,.document-upload-actions{grid-template-columns:1fr!important}.compact-field-row{grid-template-columns:1fr!important;gap:6px!important}.fixed-signature-fields{grid-template-columns:1fr 1fr!important}.document-filter-menu{min-width:min(360px,calc(100vw - 36px));max-width:calc(100vw - 36px)}}
/* Customer list and profile refinements */
.customer-list-table table{min-width:900px}.sortable-heading{display:inline-flex;align-items:center;gap:6px;color:inherit;text-decoration:none;white-space:nowrap}.sortable-heading:hover{color:#003e7b}.customer-profile{display:grid;gap:20px}.customer-detail-section{border-top:1px solid #e3e8ef;padding-top:16px}.customer-detail-section:first-of-type{border-top:0;padding-top:0}.customer-detail-section h3{margin:0 0 12px;color:#003e7b;font-size:1rem}.customer-detail-list{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px 28px;margin:0}.customer-detail-list>div{display:grid;grid-template-columns:minmax(130px,.8fr) minmax(0,1.2fr);gap:12px;padding:7px 0;border-bottom:1px solid #eef1f5}.customer-detail-list dt{font-weight:600;color:#5e6877}.customer-detail-list dd{margin:0;overflow-wrap:anywhere}.joint-link-input{min-width:320px;max-width:520px}
@media(max-width:900px){.customer-detail-list{grid-template-columns:1fr}.joint-link-input{min-width:0;width:100%}}
/* Joint signing and Signature Request detail refinements */
.link-copy-row,.joint-link-actions,.document-actions,.joint-record-actions{display:flex;align-items:center;gap:8px;min-width:0}.link-copy-row input,.joint-link-actions input{flex:1;min-width:0}.joint-signer-card{display:grid;grid-template-columns:minmax(210px,.8fr) minmax(300px,1.2fr);gap:12px 18px;align-items:center;padding:14px 0;border-bottom:1px solid var(--border)}.joint-signer-summary{display:flex;flex-direction:column;gap:4px;min-width:0}.joint-record-actions{grid-column:2}.document-actions{flex-wrap:nowrap}.document-actions .button{margin:0;white-space:nowrap}.customer-audit-event.party-colour-0{border-color:#003e7b!important;background:#eef6ff!important}.customer-audit-event.party-colour-1{border-color:#198754!important;background:#effaf4!important}.customer-audit-event.party-colour-2{border-color:#FAAA16!important;background:#fff8e9!important}.customer-audit-event.party-colour-3{border-color:#0DCAF0!important;background:#effcff!important}.customer-audit-event.party-colour-4{border-color:#7b3fb4!important;background:#f7f0fc!important}@media(max-width:900px){.joint-signer-card{grid-template-columns:1fr}.joint-record-actions{grid-column:1}.joint-link-actions{width:100%}.download-row{align-items:flex-start}.document-actions{width:auto}}


/* 2026-07-16 customer, signing and choice alignment refinements */
.customer-profile-professional{padding:0!important;overflow:hidden}.customer-profile-heading{display:flex;justify-content:space-between;align-items:center;gap:18px;padding:20px 22px;background:linear-gradient(135deg,#f4f8fc,#fff);border-bottom:1px solid var(--border)}.customer-profile-heading h2{margin:0 0 4px}.customer-profile-heading p{margin:0;color:#687386}.customer-reference-chip{display:inline-flex;align-items:center;justify-content:center;min-height:38px;padding:0 14px;border-radius:999px;background:#003e7b;color:#fff;font-weight:700;letter-spacing:.04em}.customer-profile-professional>.customer-detail-section{padding:18px 22px;margin:0;border-top:1px solid #e7ecf2}.customer-profile-professional>.customer-detail-section h3{display:flex;align-items:center;margin:0 0 13px;font-size:15px}.customer-profile-professional .customer-detail-list{grid-template-columns:repeat(2,minmax(0,1fr));gap:0 34px}.customer-profile-professional .customer-detail-list>div{grid-template-columns:minmax(145px,.8fr) minmax(0,1.2fr);padding:9px 0}.customer-profile-professional .customer-detail-list dt{font-size:12px;text-transform:uppercase;letter-spacing:.035em}.customer-profile-professional .customer-detail-list dd{font-weight:600;color:#263445}
.customer-grid{grid-template-columns:42px minmax(210px,1.2fr) minmax(190px,.9fr) minmax(220px,1fr)!important}.customer-option>span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.customer-option small{font-weight:500;color:#667085}
.inline-choice-list,.radio-option-list{display:grid!important;gap:8px!important}.inline-choice,.radio-option,.consent-check{display:flex!important;flex-direction:row!important;align-items:flex-start!important;justify-content:flex-start!important;gap:9px!important;width:100%!important;margin:0!important;text-align:left!important}.inline-choice input[type=radio],.inline-choice input[type=checkbox],.radio-option input[type=radio],.consent-check input[type=checkbox]{display:block!important;position:static!important;width:18px!important;height:18px!important;min-width:18px!important;min-height:18px!important;flex:0 0 18px!important;margin:1px 0 0!important}.inline-choice span,.radio-option span,.consent-check span{display:block!important;flex:1!important;line-height:1.4!important;margin:0!important;text-align:left!important}.compact-field-input .inline-choice-list{width:100%}
.download-row{display:flex!important;align-items:center!important;justify-content:space-between!important;gap:14px!important}.document-actions{display:inline-flex!important;flex-direction:row!important;align-items:center!important;gap:8px!important;flex-wrap:nowrap!important}.document-actions .button{display:inline-flex!important;align-items:center!important;justify-content:center!important;min-width:104px!important;margin:0!important}.main-record-actions,.joint-record-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-top:10px}.main-signing-link-panel .signing-link-head>div:first-child{display:flex;align-items:center;gap:10px;flex-wrap:wrap}.joint-link-actions{display:flex!important;align-items:center!important;gap:8px!important}.joint-link-actions input{flex:1!important;min-width:0!important}.joint-link-actions .button{flex:0 0 auto!important}
@media(max-width:760px){.customer-profile-heading{align-items:flex-start;flex-direction:column}.customer-profile-professional .customer-detail-list{grid-template-columns:1fr}.customer-grid{grid-template-columns:38px minmax(180px,1fr) minmax(150px,.8fr) minmax(190px,1fr)!important}.download-row{align-items:flex-start!important}.document-actions{width:100%;justify-content:flex-end}.main-signing-link-panel .signing-link-head{align-items:flex-start}.link-copy-row{width:100%}}
/* Final requested layout refinements */
.joint-signer-card{grid-template-columns:minmax(220px,.8fr) minmax(360px,1.2fr)!important}.joint-link-content{display:grid;gap:7px;min-width:0}.joint-record-actions{grid-column:auto!important;margin-top:0!important}.complete-card-wide{max-width:900px}.completion-section{margin-top:22px;text-align:left}.party-completion-row{display:grid;grid-template-columns:minmax(180px,.7fr) minmax(260px,1.2fr) auto;align-items:center;gap:10px;padding:12px 0;border-bottom:1px solid var(--border)}.party-completion-row>div:first-child{display:flex;flex-direction:column;gap:3px}.template-output-options{grid-column:1/-1;display:flex;gap:12px;flex-wrap:wrap;align-items:center}.template-output-options .setting-check{min-width:260px}.document-tooltip{visibility:hidden;opacity:0;display:block!important;transform:none!important}.document-count:hover .document-tooltip,.document-count:focus .document-tooltip{visibility:visible;opacity:1}.autofill-option-button[hidden]{display:none!important}.autofill-option-button{text-align:left!important;justify-content:flex-start!important}.form-actions .button.large,.form-actions button.large{min-width:150px;height:46px;display:inline-flex;align-items:center;justify-content:center}.sms-preview-frame{width:100%;height:340px;border:0}.row-actions{display:flex;gap:7px;align-items:center;flex-wrap:nowrap}.info-button{background:#0DCAF0!important;border-color:#0DCAF0!important;color:#073642!important}
@media(max-width:800px){.party-completion-row{grid-template-columns:1fr}.joint-signer-card{grid-template-columns:1fr!important}.template-output-options{display:grid;grid-template-columns:1fr}.template-output-options .setting-check{min-width:0}}

/* Latest joint request and compact layout fixes */
.reference-inline{display:flex;align-items:center;gap:6px;min-width:0;white-space:nowrap}.reference-inline small{overflow:hidden;text-overflow:ellipsis}
.party-badge{display:inline-flex;align-items:center;justify-content:center;min-width:54px;padding:4px 8px;border-radius:999px;font-size:11px;font-weight:800}.party-badge.main{background:#e8f2ff;color:#003e7b}.party-badge.joint{background:#fff3d6;color:#8a5900}.status.awaiting_main_signature{background:#eef1f5;color:#596273}
.joint-signer-card{grid-template-columns:minmax(210px,.85fr) minmax(0,1.15fr)!important}.joint-link-actions{width:100%;min-width:0}.joint-link-input{width:100%!important;min-width:0!important;max-width:none!important}.joint-link-actions .button{margin-left:0}
.document-status-line{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.document-status-line strong{font-size:11px;color:#8a5900}
.metadata-party-row{border-left:4px solid transparent}.metadata-party-row.party-colour-0{border-left-color:#003e7b;background:#eef6ff}.metadata-party-row.party-colour-1{border-left-color:#198754;background:#effaf4}.metadata-party-row.party-colour-2{border-left-color:#FAAA16;background:#fff8e9}.metadata-party-row.party-colour-3{border-left-color:#0DCAF0;background:#effcff}.metadata-party-row.party-colour-4{border-left-color:#7b3fb4;background:#f7f0fc}
.document-list-button{border:0;background:#eef4fb;color:#003e7b;border-radius:999px;padding:6px 10px;font-weight:700;cursor:pointer}.document-list-button:hover{background:#dceafb}.document-list-modal{width:min(520px,92vw)}.customer-documents-list{margin:0;padding-left:20px;display:grid;gap:9px}.customer-documents-list li{padding-bottom:8px;border-bottom:1px solid #edf0f4}
@media(max-width:760px){.document-status-line{max-width:230px}.joint-signer-card{grid-template-columns:1fr!important}}

/* Final request-filter and reference alignment fixes */
.reference-inline{display:flex!important;align-items:center!important;gap:6px!important;white-space:nowrap!important;min-width:0}.reference-inline>*{display:inline!important;white-space:nowrap!important}.document-filter-option{display:flex!important;flex-direction:row!important;align-items:center!important;gap:10px!important}.document-filter-option input[type=checkbox]{display:block!important;flex:0 0 20px!important;width:20px!important;height:20px!important;margin:0!important}.document-filter-option span{display:block!important;line-height:20px!important;text-align:left!important}.document-category-heading{font-weight:800!important;text-align:left!important}.signature-request-filters{display:grid!important;grid-template-columns:repeat(9,minmax(110px,1fr)) auto!important;align-items:end!important;gap:8px!important}.signature-request-filters .filter-actions{display:flex!important;flex-wrap:nowrap!important;gap:6px!important;white-space:nowrap!important}.signature-request-filters .dashboard-document-filter .multi-select-trigger{max-width:none!important}.signature-request-filters .page-size-filter{min-width:72px!important}
@media (max-width:1500px){.signature-request-filters{overflow-x:auto!important;grid-template-columns:repeat(9,minmax(125px,1fr)) minmax(160px,auto)!important;padding-bottom:5px!important}.signature-request-filters>*{min-width:0!important}}
@media (max-width:900px){.signature-request-filters{display:grid!important;grid-template-columns:1fr 1fr!important;overflow:visible!important}.signature-request-filters .filter-actions{grid-column:1/-1!important}}
@media (max-width:560px){.signature-request-filters{grid-template-columns:1fr!important}.signature-request-filters .filter-actions{grid-column:auto!important}}

/* Compact customer references: reference and internal reference must remain on one line. */
.customer-option.customer-grid{min-height:38px!important;height:auto!important;padding-top:5px!important;padding-bottom:5px!important}
.customer-option .reference-inline{display:flex!important;align-items:center!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;line-height:1.2!important}
.customer-option .reference-inline b{display:block!important;overflow:hidden!important;text-overflow:ellipsis!important;white-space:nowrap!important;font-size:12px!important}

/* Customer picker: keep headings exactly aligned with their row columns. */
#customerPicker .customer-grid{
  display:grid!important;
  grid-template-columns:42px minmax(210px,1.2fr) minmax(190px,.9fr) minmax(220px,1fr)!important;
  align-items:center!important;
  column-gap:12px!important;
}
#customerPicker .compact-list-head.customer-grid>span,
#customerPicker .customer-option.customer-grid>*{
  min-width:0;
  text-align:left;
}
#customerPicker .compact-list-head.customer-grid>span:first-child,
#customerPicker .customer-option.customer-grid>input:first-child{
  justify-self:center;
}

/* Latest signing refinements: keep disclaimer checkboxes and text on one row. */
.inline-disclaimer-checkbox,
.inline-disclaimer-checkbox-row,
.signature-sheet .disclaimer-html label:has(> input[type="checkbox"]) {
  display:flex!important;
  flex-direction:row!important;
  align-items:flex-start!important;
  gap:9px!important;
  width:100%!important;
}
.inline-disclaimer-checkbox input[type="checkbox"],
.inline-disclaimer-checkbox-row input[type="checkbox"],
.signature-sheet .disclaimer-html label:has(> input[type="checkbox"]) > input[type="checkbox"] {
  flex:0 0 18px!important;
  width:18px!important;
  height:18px!important;
  margin:1px 0 0!important;
}
.inline-disclaimer-checkbox-row > label,
.inline-disclaimer-checkbox > span {
  flex:1 1 auto!important;
  min-width:0!important;
}
.agent-optional-label{margin-left:auto;font-size:12px;}

/* Signing disclaimer: no divider between the upper disclaimer and signature pad. */
.signature-sheet .signature-pad-section{border-top:0!important;padding-top:0!important;}


/* Communication-template and per-document default controls */
.communication-defaults-panel{margin-top:18px;background:#f8fafc;border:1px solid #dbe4ee}
.communication-defaults-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}
.communication-default-group{background:#fff;border:1px solid #dbe4ee;border-radius:10px;padding:16px;display:grid;gap:12px}
.communication-default-group h4{margin:0;color:#003e7b}
.communication-list-head{display:flex;justify-content:space-between;align-items:end;gap:16px;margin-bottom:14px}
.compact-filter{display:flex;align-items:center;gap:8px;margin:0}.compact-filter input{width:280px}
.communication-table th:last-child,.communication-table td:last-child{white-space:nowrap}
.status-use-text{font-size:12px;color:#44546a}
.wide-modal{width:min(920px,calc(100vw - 32px))}
.communication-edit-form{display:grid;gap:16px}
.horizontal-field{display:grid;grid-template-columns:180px minmax(0,1fr);gap:16px;align-items:center}
.horizontal-field>label{font-weight:700;color:#27364a}
.dynamic-field-list{display:flex;flex-wrap:wrap;gap:7px}.dynamic-field-list span{background:#e8f1fa;border:1px solid #c5d9ed;color:#003e7b;border-radius:5px;padding:5px 8px;font-size:12px;font-weight:700}
.editor-tabs{display:flex;gap:6px;border-bottom:1px solid #dbe4ee}.editor-tabs .tab{border-radius:8px 8px 0 0}
.email-html-preview{width:100%;min-height:560px;border:1px solid #dbe4ee;border-radius:8px;background:#fff}
@media(max-width:800px){.communication-defaults-grid{grid-template-columns:1fr}.communication-list-head{align-items:stretch;flex-direction:column}.compact-filter{align-items:stretch;flex-direction:column}.compact-filter input{width:100%}.horizontal-field{grid-template-columns:1fr;gap:6px}}
.communication-list-filters{display:flex;gap:12px;align-items:end;flex-wrap:wrap}.compact-filter select{min-width:150px}.status-pill.muted{background:#e8ebf0;color:#596273}.preview-action{justify-content:flex-start;margin-top:12px}.dynamic-field-list{max-height:190px;overflow:auto}.communication-table td{vertical-align:middle}@media(max-width:800px){.communication-list-filters{width:100%}.compact-filter{flex:1;min-width:160px}}

/* Template Management: document left, default communications right */
.template-management-columns{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:18px;align-items:start;grid-column:1/-1}
.template-management-columns>.panel{margin:0;min-width:0}
.template-document-panel .document-upload-actions{grid-template-columns:1fr;align-items:stretch}
.template-document-panel .document-upload-actions .button,.template-document-panel .document-upload-actions button{width:100%;justify-content:center}
.previous-documents-section{margin-top:20px;padding-top:16px;border-top:1px solid var(--border)}
.previous-documents-section h4{margin:0 0 10px}
.previous-documents-table th:last-child,.previous-documents-table td:last-child{width:110px;text-align:right}
@media(max-width:900px){.template-management-columns{grid-template-columns:1fr}}
