/* Shared, scoped corrections: no changes to unrelated tables or header sizes. */
html:root[data-interface] body.app-page[data-page="/customers/calendar"] .main-shell{padding:0 0 72px!important;width:100%!important;max-width:none!important}
html:root[data-interface] body.app-page[data-page="/customers/calendar"] .calendar-workspace-r24{margin:0!important;width:100%!important;max-width:none!important}
html:root[data-interface] body.app-page[data-page="/customers/calendar"] .calendar-primary-r24{min-width:0;width:100%}
html:root[data-interface] body.app-page[data-page="/customers/calendar"] .calendar-mobile-scope-r46:empty{display:none}
html:root[data-interface] body.app-page[data-page="/customers/calendar"] .agenda-scroll,html:root[data-interface] body.app-page[data-page="/customers/calendar"] .calendar-scroll{border-radius:0!important}
#calendar-settings-dialog .calendar-delivery-r46{margin:12px 0}
:root[data-interface=classic] body[data-page="/commercial/clients"] .desktop-topbar{display:flex;align-items:center;gap:12px;flex-wrap:wrap}
:root[data-interface=classic] body[data-page="/commercial/clients"] .desktop-page-heading{flex:1;min-width:220px}
:root[data-interface=classic] body[data-page="/commercial/clients"] .desktop-page-heading .portfolio-context{font-size:11px;margin:0}
:root[data-interface=classic] body[data-page="/commercial/clients"] .desktop-page-heading>strong{margin:0}
:root[data-interface=classic] body[data-page="/commercial/clients"] .desktop-topbar>.r101-more{flex:0 0 auto;width:auto}
body[data-page="/commercial/clients"] .r101-secondary-heading{display:none!important}
body[data-page="/commercial/clients"] .desktop-topbar>.r101-more{position:relative;margin:0;border:1px solid #dce2e8;border-radius:9px;background:white}
body[data-page="/commercial/clients"] .desktop-topbar>.r101-more>summary{padding:12px 14px;font-size:13px;cursor:pointer}
body[data-page="/commercial/clients"] .cw-primary-action-r131:empty{display:none}
body[data-page="/commercial/clients"] .main-shell>.portfolio-context{display:none}
@media(max-width:1000px){body[data-page="/commercial/clients"] .desktop-topbar{display:flex!important;flex-wrap:wrap;gap:12px}body[data-page="/commercial/clients"] .desktop-topbar>.desktop-page-heading{flex-basis:100%}}
:root[data-interface=new] .desktop-topbar.customer-header-r132>.desktop-page-heading>strong{white-space:normal!important;overflow:visible!important;text-overflow:clip!important;overflow-wrap:anywhere;line-height:1.25!important}
:root[data-interface=new] .desktop-topbar.customer-header-r132>.desktop-page-heading{flex-basis:32%!important}
:root[data-interface=new] body:has([data-customer-hub]) .desktop-topbar{position:static!important;top:auto!important}
:root[data-interface=new] .main-shell:has([data-customer-hub]){padding-top:0!important;overflow:visible!important}
:root[data-interface=new] [data-customer-hub]{max-width:none!important;overflow:visible!important}
:root[data-interface=new] [data-customer-hub]>.customer-section-nav{position:sticky!important;top:var(--customer-tabs-top,0px)!important;z-index:28;margin:0 calc(-1 * var(--customer-tabs-right,0px)) 18px calc(-1 * var(--customer-tabs-left,0px))!important;border-radius:0!important;border-inline:0!important;border-top:0!important;padding:0 14px!important;background:#fff!important;box-shadow:0 1px 0 #dce2e8;width:auto!important;max-width:none!important;display:flex;overflow-x:auto;flex-wrap:nowrap!important;scrollbar-width:thin}
:root[data-interface=new] [data-customer-hub]>.customer-section-nav a{flex:1 0 auto;min-height:48px;display:flex;align-items:center;justify-content:center;white-space:nowrap}
.customer-needs-history-list-r133{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:12px;margin-top:14px}
.customer-needs-history-list-r133 article{display:grid;gap:6px;padding:14px;border:1px solid #dce2e8;border-radius:8px;background:#f7f9fb}
.customer-needs-history-list-r133 small{color:#627084}
.customer-data-heading-r133{display:flex;justify-content:space-between;align-items:center;gap:16px;flex-wrap:wrap;margin-bottom:16px}
.customer-data-heading-r133 h3{margin:0!important}
.customer-data-grid-r133{display:grid;grid-template-columns:minmax(0,1.6fr) minmax(220px,1fr);gap:24px}
.customer-data-contacts-r133 .address-book-list{grid-template-columns:1fr}
.customer-data-contacts-r133 .address-person-card{border:0;border-bottom:1px solid #e0e3e8;border-radius:0;padding:0 0 16px}
.customer-data-contacts-r133 .address-channel-list{grid-template-columns:repeat(2,minmax(0,1fr))}
.customer-data-company-r133{margin:0;padding-left:24px;border-left:1px solid #e0e3e8;display:grid;gap:16px;align-content:start}
.customer-data-company-r133 dt{font-size:12px;color:#627084;margin-bottom:4px}
.customer-data-company-r133 dd{margin:0;font-size:14px;font-weight:600;overflow-wrap:anywhere}
.customer-data-company-r133 small{display:block;margin-top:4px;font-weight:400}
@media(max-width:1000px){.customer-data-grid-r133{grid-template-columns:1fr}.customer-data-company-r133{border-left:0;border-top:1px solid #e0e3e8;padding:16px 0 0;grid-template-columns:repeat(2,minmax(0,1fr))}.customer-data-contacts-r133 .address-channel-list{grid-template-columns:1fr}}
/* One compact data sheet, with contacts presented as rows instead of nested boxes. */
html:root body.app-page [data-customer-hub] .customer-data-grid-r133{display:flex;flex-direction:column;gap:18px}
html:root body.app-page [data-customer-hub] .customer-data-company-r133{order:-1;display:grid;grid-template-columns:minmax(180px,2fr) minmax(180px,1.7fr) repeat(2,minmax(115px,1fr)) minmax(100px,.8fr);gap:16px;margin:0;padding:14px 0 18px;border:0;border-bottom:1px solid #e0e3e8;background:none}
html:root body.app-page [data-customer-hub] .customer-data-contacts-r133 .address-person-card{padding:0!important;border:0!important;border-bottom:1px solid #e0e3e8!important;border-radius:0!important;background:none!important;box-shadow:none!important}
html:root body.app-page [data-customer-hub] .customer-data-contacts-r133 .address-person-card>header{margin:0!important;align-items:center;padding:8px 0}
html:root body.app-page [data-customer-hub] .customer-data-contacts-r133 .address-person-card>header>div{display:flex;align-items:baseline;gap:12px;flex-wrap:wrap}
html:root body.app-page [data-customer-hub] .customer-data-contacts-r133 .address-person-card h4{font-size:14px;margin:0!important}
html:root body.app-page [data-customer-hub] .customer-data-contacts-r133 .address-channel-list{grid-template-columns:1fr!important;gap:0!important}
html:root body.app-page [data-customer-hub] .customer-data-contacts-r133 .address-channel{border:0!important;border-top:1px solid #edf0f3!important;border-radius:0!important;padding:10px 0!important;background:none!important}
html:root body.app-page [data-customer-hub] .customer-data-contacts-r133 .address-channel>div{flex:1;display:grid;grid-template-columns:170px minmax(0,1fr) minmax(140px,.6fr);gap:12px;align-items:center}
html:root body.app-page [data-customer-hub] .customer-data-contacts-r133 .address-channel .address-value{font-weight:600}
@media(max-width:1000px){html:root body.app-page [data-customer-hub] .customer-data-company-r133{grid-template-columns:repeat(3,minmax(0,1fr))}html:root body.app-page [data-customer-hub] .customer-data-company-r133>div:first-child,html:root body.app-page [data-customer-hub] .customer-data-company-r133>div:nth-child(2){grid-column:span 3}html:root body.app-page [data-customer-hub] .customer-data-contacts-r133 .address-channel>div{grid-template-columns:120px minmax(0,1fr)}html:root body.app-page [data-customer-hub] .customer-data-contacts-r133 .address-origin{grid-column:2}}
@media(max-width:700px){html:root body.app-page [data-customer-hub] .customer-data-company-r133{order:1;grid-template-columns:repeat(2,minmax(0,1fr));border-top:1px solid #e0e3e8;border-bottom:0}html:root body.app-page [data-customer-hub] .customer-data-company-r133>div:first-child,html:root body.app-page [data-customer-hub] .customer-data-company-r133>div:nth-child(2){grid-column:1/-1}html:root body.app-page [data-customer-hub] .customer-data-contacts-r133 .address-channel>div{display:flex;flex-direction:column;align-items:flex-start;gap:4px}html:root body.app-page [data-customer-hub] .customer-data-heading-r133 .button{width:100%;min-height:44px}.customer-data-heading-r133{gap:12px}}
.cw-need-origin-r133{display:flex;flex-wrap:wrap;gap:10px 24px;margin:12px 0}
.cw-need-origin-r133 a{color:#26374c;text-decoration:none;padding:6px 10px;border:1px solid #dce2e8;border-radius:6px;background:white}
.cw-need-origin-r133 b{margin-left:10px}
.product-description-note-r133{display:block;font-size:12px;line-height:1.5;color:#536174;margin-top:4px;white-space:pre-line;overflow-wrap:anywhere}
.customer-last-items-r132 .product-context-r133{display:block;color:#536174;font-size:13px}
.oi-header-actions-r133{display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin-left:auto}
.oi-header-actions-r133 .button{min-height:42px;display:inline-flex;align-items:center;justify-content:center;padding:9px 12px;white-space:nowrap;font-size:13px}
.oi-header-actions-r133 .oi-create-order{background:#df1024!important;color:white!important;border-color:#df1024!important;font-weight:650}
.desktop-topbar:has(.oi-header-actions-r133){flex-wrap:wrap!important;gap:12px!important}
.oi-actions[aria-label="Test dimostrativi"]:empty{display:none}
html body.app-page .oi .oi-entry-table{table-layout:fixed!important;width:100%!important;min-width:1550px!important;max-width:none!important}
html body.app-page .oi .oi-entry-table th{white-space:normal!important;line-height:1.3!important;vertical-align:middle}
html body.app-page .oi .oi-entry-table col:nth-child(1){width:185px!important}
html body.app-page .oi .oi-entry-table col:nth-child(2){width:90px!important}
html body.app-page .oi .oi-entry-table col:nth-child(3){width:65px!important}
html body.app-page .oi .oi-entry-table col:nth-child(4){width:105px!important}
html body.app-page .oi .oi-entry-table col:nth-child(5){width:300px!important}
html body.app-page .oi .oi-entry-table col:nth-child(6){width:65px!important}
html body.app-page .oi .oi-entry-table col:nth-child(7){width:80px!important}
html body.app-page .oi .oi-entry-table col:nth-child(8){width:125px!important}
html body.app-page .oi .oi-entry-table col:nth-child(9){width:150px!important}
html body.app-page .oi .oi-entry-table col:nth-child(10){width:95px!important}
html body.app-page .oi .oi-entry-table col:nth-child(11){width:65px!important}
html body.app-page .oi .oi-entry-table col:nth-child(12){width:90px!important}
html body.app-page .oi .oi-entry-table col:nth-child(13){width:35px!important}
html body.app-page .oi .oi-entry-table .oi-variant{display:grid!important;grid-template-columns:66px minmax(100px,1fr) 62px 26px!important;gap:6px!important}
html body.app-page .oi .oi-entry-table :is(th,td){min-width:0!important;width:auto!important;max-width:none!important;word-break:normal!important;overflow-wrap:break-word}
html body.app-page .oi .oi-entry-table input[data-line-field=quantity][readonly]{font-weight:700;background:#eef2f5}
@media(max-width:700px){
 .appointment-context-grid-r132>.appointment-customer-r132{grid-template-columns:minmax(0,1fr)!important}
 .appointment-customer-r132>.work-inline{display:flex!important;width:100%;flex-wrap:nowrap!important}
 .appointment-customer-r132>.work-inline>button{flex:1;min-width:0}
 .appointment-customer-r132>#appointment-customer-results{top:68px}
 .desktop-topbar:has(.oi-header-actions-r133)>.desktop-page-heading{flex-basis:100%!important}
 .oi-header-actions-r133{width:100%;margin:0;gap:6px}
 .oi-header-actions-r133 .button{padding:8px;font-size:12px;flex:1}
 .customer-needs-history-list-r133{grid-template-columns:1fr}
 html body.app-page .oi .oi-entry-table{width:1550px!important}
 html body.app-page .oi .oi-entry-table th:first-child,html body.app-page .oi .oi-entry-table .oi-entry-name{position:static!important;box-shadow:none}
}
