:root{font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#18352d;background:#f5f6f1;font-synthesis:none}*{box-sizing:border-box}body{margin:0}a{color:#235c47;text-underline-offset:4px}button,input{font:inherit}.app-shell{max-width:1440px;margin:auto;min-height:100vh;display:flex;flex-direction:column}.site-header{height:108px;padding:24px 6%;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid #e0e5dc}.brand{display:flex;align-items:center;gap:12px;color:#173f35;text-decoration:none;font-size:24px;font-weight:750;letter-spacing:-1px}.brand-mark{background:#173f35;color:white;border-radius:13px;width:46px;height:46px;display:grid;place-items:center;font-size:24px;letter-spacing:-2px}.brand small{display:block;font-size:9px;letter-spacing:2.6px;font-weight:600;margin-top:2px;color:#64776c}.header-note{font-size:13px;color:#6d7e73}.account-menu{display:flex;align-items:center;gap:18px;font-size:14px}main{flex:1}.site-footer{padding:26px 6%;font-size:12px;color:#758579}.eyebrow{font-size:10px;letter-spacing:2px;font-weight:750;color:#537260}h1,h2,p{margin-top:0}h1{font-size:clamp(34px,3.4vw,50px);line-height:1.14;letter-spacing:-2px;font-weight:650}h2{font-size:25px;letter-spacing:-.8px;font-weight:650}.muted{color:#708074;font-size:14px}.login-layout{padding:64px 10%;display:grid;grid-template-columns:1.15fr 1fr;gap:80px;align-items:center}.login-intro h1{margin:20px 0}.login-intro>p{line-height:1.8;font-size:15px;color:#687e6e}.card-visual{width:310px;max-width:100%;height:190px;background:linear-gradient(135deg,#245541,#0f3028);border-radius:18px;color:#f4f3dc;margin-top:36px;padding:22px 26px;box-shadow:0 18px 35px #14382a22;position:relative;transform:rotate(-5deg);overflow:hidden}.card-visual:after{content:"";position:absolute;width:230px;height:230px;border:1px solid #ffffff19;border-radius:50%;right:-125px;top:25px;box-shadow:0 0 0 22px #ffffff07,0 0 0 44px #ffffff05}.card-visual>span{font-size:18px;font-weight:650}.card-visual strong{display:block;font-size:17px;line-height:1.4;margin-top:24px;font-weight:500}.card-visual small{display:block;margin-top:14px;font-size:8px;letter-spacing:2px;color:#c1ceb5}.card-chip{position:absolute;right:28px;top:24px;width:29px;height:23px;background:#cabb8a;border-radius:5px;opacity:.9}.login-panel{background:#fff;padding:42px;border:1px solid #e4e8de;border-radius:20px;box-shadow:0 8px 32px #213c2c06}.login-panel h2{margin:14px 0 10px}.login-form{display:flex;flex-direction:column;margin-top:32px;gap:10px}.login-form label{font-size:12px;font-weight:650;margin-top:8px}.login-form input:not([type=hidden]){border:1px solid #d8e0d5;border-radius:8px;background:#fcfdfb;padding:13px 14px;color:#18352d;min-width:0;width:100%}.login-form input:focus{outline:3px solid #b9cebc;outline-offset:2px}.button{display:inline-flex;align-items:center;justify-content:center;gap:12px;border:0;border-radius:8px;padding:13px 18px;font-weight:600;font-size:14px;text-decoration:none;cursor:pointer}.button-primary{background:#173f35;color:#fff;margin-top:14px}.button-primary:hover{background:#245b45}.button-primary span{margin-left:auto}.button-quiet{background:#e8eee3;color:#294c3b;padding:9px 15px}.button:focus-visible,a:focus-visible{outline:3px solid #96b69e;outline-offset:4px}.support-note{margin:28px 0 0;padding-top:24px;border-top:1px solid #edf0e8;color:#768175;font-size:12px;line-height:1.8}.notice{border-radius:8px;padding:14px 16px;font-size:13px;line-height:1.5;margin:20px 0}.notice-error{background:#fff3ee;border:1px solid #f1d5c7;color:#844533}.dashboard{padding:58px 6%}.dashboard h1{margin:18px 0 14px;font-size:40px}.dashboard-subtitle{color:#6a7d70;font-size:15px}.stats-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:20px;margin:36px 0}.stat-card{background:#fff;border:1px solid #e0e6db;border-radius:14px;padding:26px}.stat-card>span{color:#6c7e70;font-size:13px}.stat-card strong{display:block;font-size:38px;font-weight:550;margin-top:14px;letter-spacing:-1px}.welcome-grid{display:grid;grid-template-columns:1.65fr 1fr;gap:20px}.welcome-panel,.profile-panel{padding:30px;border-radius:14px;background:#e7eedf}.welcome-panel h2{font-size:23px}.welcome-panel p,.profile-panel p{color:#5d7363;font-size:14px;line-height:1.7}.profile-panel{background:#fff;border:1px solid #e0e6db}.profile-panel h2{font-size:20px;margin:14px 0 5px}.role-badge{display:inline-flex;padding:6px 10px;border-radius:30px;background:#eaf0e4;font-size:11px;font-weight:600;color:#396047}.validation-message{color:#844533}#blazor-error-ui{display:none;background:#fff3ee;padding:14px;position:fixed;bottom:0;width:100%;z-index:1000}
@media(max-width:850px){.login-layout{padding:40px 6%;gap:36px;grid-template-columns:1fr 1fr}.login-panel{padding:28px}.card-visual{width:260px}.welcome-grid{grid-template-columns:1fr}.header-note{display:none}}@media(max-width:640px){.site-header{height:84px}.login-layout{display:flex;flex-direction:column;padding:32px 6%;gap:26px;align-items:stretch}.login-intro h1{font-size:35px}.login-intro>p{margin-bottom:0}.card-visual{display:none}.login-panel{padding:28px 24px}.login-panel h2{font-size:24px}.dashboard{padding-top:34px}.dashboard h1{font-size:32px}.stats-grid{gap:10px;margin:26px 0}.stat-card{padding:18px 12px}.stat-card strong{font-size:30px}.stat-card>span{font-size:11px}.site-footer{font-size:11px}.account-menu{gap:10px}.brand{font-size:21px}}

.site-header{height:auto;min-height:108px;flex-wrap:wrap;gap:16px}.main-nav{display:flex;gap:24px;width:100%;order:3;padding-top:8px}.main-nav a{text-decoration:none;font-size:13px;padding:6px 0;color:#657b6b;border-bottom:2px solid transparent}.main-nav a.active{color:#173f35;border-color:#173f35;font-weight:650}.account-menu>span{max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.page-heading{display:flex;justify-content:space-between;align-items:center;gap:24px}.page-heading .button{white-space:nowrap}.search-form{display:flex;gap:12px;margin:28px 0}.search-form input{width:min(100%,480px);border:1px solid #d8e0d5;background:white;border-radius:8px;padding:12px 14px}.table-wrap{border:1px solid #e0e6db;border-radius:14px;overflow-x:auto;background:#fff}.merchant-table{width:100%;border-collapse:collapse;text-align:left;min-width:600px}.merchant-table th{padding:16px 22px;font-size:11px;text-transform:uppercase;letter-spacing:1px;background:#edf1e7;color:#5f7465}.merchant-table td{padding:20px 22px;border-top:1px solid #edf0e8;font-size:14px}.merchant-table td strong,.merchant-table td small{display:block}.merchant-table td small{margin-top:7px;color:#6d7e73;font-size:12px}.merchant-table td a{white-space:nowrap;text-decoration:none;font-weight:600}.status-badge{display:inline-flex;font-size:11px;font-weight:600;padding:6px 10px;border-radius:20px}.status-badge.active{background:#e7f0e0;color:#38633b}.status-badge.inactive{background:#f3e9e2;color:#86563d}.pagination{display:flex;justify-content:space-between;align-items:center;gap:16px;margin-top:20px;font-size:13px;color:#64776c}.pagination>div{display:flex;gap:8px}.button:disabled{opacity:.5;cursor:not-allowed}.empty-panel{padding:50px 30px;background:white;border:1px dashed #cedac8;border-radius:14px;text-align:center}.empty-panel h2{font-size:24px}.empty-panel p{color:#6b7b6d;font-size:14px}.editor-page{max-width:1100px;margin:auto}.back-link{display:block;margin-bottom:24px;font-size:13px;text-decoration:none}.editor-panel{background:#fff;border:1px solid #e0e6db;border-radius:16px;padding:32px;margin:26px 0}.editor-panel fieldset{border:0;padding:0;margin:0;min-width:0}.editor-panel legend{font-size:23px;font-weight:650;letter-spacing:-.6px;padding:0;margin-bottom:26px}.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:22px}.field{display:flex;flex-direction:column;gap:9px;min-width:0}.field-wide{grid-column:1/-1}.field label,.file-label{font-size:13px;font-weight:650}.field input{border:1px solid #d8e0d5;border-radius:8px;background:#fcfdfb;padding:12px 14px;color:#18352d;width:100%;font:inherit}.field input:read-only{background:#f1f4ed;color:#6b7b6d}.field input:focus,.search-form input:focus{outline:3px solid #b9cebc;outline-offset:2px}.field small,.form-help{font-size:12px;color:#6e7e70;line-height:1.7}.section-title{font-size:22px;margin:34px 0 10px}.color-field{display:flex;gap:16px;align-items:center;color:#6b7b6d;font-size:13px}.color-field input[type=color]{width:58px;height:44px;padding:4px;cursor:pointer}.brand-preview{margin-top:26px;border-radius:14px;padding:25px;background:var(--preview-background);color:var(--preview-primary);border:1px solid #dfe5d9;display:flex;flex-direction:column;align-items:flex-start;gap:14px}.brand-preview>span:first-child{font-size:9px;letter-spacing:1.5px}.brand-preview strong{font-size:24px}.preview-pill{background:var(--preview-primary);color:var(--preview-background);border-radius:20px;padding:8px 16px;font-size:12px}.form-actions{display:flex;gap:12px;align-items:center;margin-top:24px}.form-actions .button{margin-top:0}.form-help{margin-top:20px}.switch-fields{display:flex;flex-wrap:wrap;gap:20px;margin-top:25px}.switch-fields label{display:flex;gap:10px;align-items:center;font-size:14px}.switch-fields input{accent-color:#173f35;width:18px;height:18px}.logo-panel h2{margin-bottom:12px}.logo-preview{height:150px;max-width:260px;background:#f3f6ef;border:1px dashed #d2ddcb;border-radius:12px;display:grid;place-items:center;margin:24px 0;color:#7b8b7b;font-size:13px}.logo-preview img{max-width:100%;max-height:145px;object-fit:contain;padding:12px}.file-label{display:block;margin-bottom:12px}input[type=file]{max-width:100%;font:inherit;font-size:13px}.notice-success{background:#eaf3e4;border:1px solid #c8ddbe;color:#345b30}.notice ul{margin:0;padding-left:18px}.validation-message{font-size:12px;line-height:1.5}.visually-hidden{position:absolute!important;width:1px;height:1px;padding:0;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
@media(max-width:640px){.site-header{min-height:84px;gap:12px}.main-nav{gap:20px}.account-menu>span{max-width:85px}.page-heading{align-items:flex-start;flex-direction:column;gap:0}.page-heading .button{margin:0 0 12px}.form-grid{grid-template-columns:1fr;gap:18px}.field-wide{grid-column:auto}.editor-panel{padding:24px 18px}.pagination{align-items:flex-start;flex-direction:column}.search-form input{min-width:0}.form-actions{flex-wrap:wrap}.dashboard .page-heading h1{font-size:32px}.brand-preview strong{font-size:20px}}

.dashboard h1,.brand-preview strong{overflow-wrap:anywhere}.merchant-table td strong,.merchant-table td small{overflow-wrap:anywhere}

.card-list {display:grid;gap:.75rem;margin:1.5rem 0}.card-list-item {display:flex;flex-wrap:wrap;justify-content:space-between;gap:.6rem 1rem;border:1px solid #dce5de;border-radius:12px;padding:1rem;color:inherit;text-decoration:none}.card-list-item:hover{background:#f2f6f1}.card-code{overflow-wrap:anywhere;font-family:monospace}.movement-row{display:flex;justify-content:space-between;flex-wrap:wrap;gap:1rem;padding:1rem 0;border-bottom:1px solid #dce5de;overflow-wrap:anywhere}.movement-row p{margin:.3rem 0}.print-card{padding:1rem;margin:1rem 0;border:2px solid #9b7536;overflow-wrap:anywhere}fieldset{min-width:0} .card-list-item strong{overflow-wrap:anywhere}

.attachment-upload{display:grid;gap:.75rem;padding:1rem 0}.attachment-upload .button{justify-self:start}.attachment-name{overflow-wrap:anywhere;word-break:break-word}.attachment-row{display:flex;align-items:center;justify-content:space-between;gap:1rem;padding:1rem 0;border-bottom:1px solid #dce5de}.attachment-row>div{min-width:0}.attachment-row .button{flex-shrink:0}.attachment-row p{margin:.35rem 0 0}@media(max-width:560px){.attachment-row{align-items:flex-start;flex-direction:column}.attachment-upload input[type=file]{max-width:100%}}

/* Area di lavoro del gestionale */
.app-shell{max-width:1600px;min-height:100vh;margin:0 auto;display:grid;grid-template-columns:248px minmax(0,1fr);background:#f5f6f1}.app-sidebar{position:sticky;top:0;height:100vh;min-height:620px;padding:28px 18px 22px;background:#173f35;color:#edf3e8;display:flex;flex-direction:column;gap:38px}.app-sidebar .brand{color:#fff;padding:0 8px}.app-sidebar .brand small{color:#b6c8ba}.app-sidebar .brand-mark{background:#e8efdf;color:#173f35}.main-nav{display:flex;flex-direction:column;gap:6px;width:auto;padding:0;border:0}.main-nav a{display:flex;align-items:center;gap:12px;padding:12px 14px;border:0;border-radius:10px;color:#d3e0d4;font-size:14px;text-decoration:none;white-space:nowrap}.main-nav a:hover{background:#ffffff12;color:#fff}.main-nav a.active{background:#e7eedf;color:#173f35;font-weight:700}.nav-icon{width:20px;text-align:center;font-size:17px;line-height:1}.sidebar-caption{margin-top:auto;padding:0 10px;color:#9db4a1;font-size:9px;letter-spacing:1.5px}.workspace-shell,.public-shell{min-width:0;min-height:100vh;display:flex;flex-direction:column}.site-header{height:74px;min-height:74px;padding:0 clamp(22px,4vw,56px);display:flex;align-items:center;justify-content:flex-end;border-bottom:1px solid #e0e5dc;background:#fbfcf8}.account-menu{gap:14px}.mobile-brand,.public-header{display:none}.main-content{flex:1;min-width:0}.site-footer{padding:22px clamp(22px,4vw,56px);border-top:1px solid #e6eae2}.public-shell{grid-column:1/-1}.public-header{display:flex;align-items:center;justify-content:space-between;padding:24px 6%;border-bottom:1px solid #e0e5dc}.workbench{display:grid;grid-template-columns:minmax(270px,360px) minmax(0,1fr);gap:20px;align-items:start}.resource-list-panel,.resource-editor-panel{min-width:0;background:#fff;border:1px solid #e0e6db;border-radius:14px;padding:20px}.resource-list-panel{position:sticky;top:18px;max-height:calc(100vh - 110px);overflow:auto}.resource-editor-panel{min-height:420px}.resource-panel-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:16px}.resource-panel-heading h2{margin:0;font-size:18px}.resource-items{display:grid;gap:8px}.resource-item{display:grid;gap:5px;padding:13px 14px;border:1px solid #e3e9e1;border-radius:10px;background:#fff;color:#18352d;text-decoration:none;min-width:0}.resource-item:hover{background:#f5f8f2;border-color:#cbd9ca}.resource-item.active{background:#edf3e9;border-color:#91ad91;box-shadow:inset 3px 0 #235c47}.resource-item strong,.resource-item span{overflow-wrap:anywhere}.resource-item span{font-size:12px;color:#6b7b6d}.resource-list-panel .search-form{display:grid;grid-template-columns:minmax(0,1fr) auto;margin:0 0 16px;gap:8px}.resource-list-panel .search-form input{width:100%;min-width:0}.resource-editor-panel>.editor-panel,.resource-editor-panel>.logo-panel{margin:0 0 14px}.resource-editor-panel>.editor-panel:last-child,.resource-editor-panel>.logo-panel:last-child{margin-bottom:0}.workbench-empty{height:100%;min-height:380px;display:grid;place-content:center;text-align:center;padding:30px;color:#718176}.workbench-empty strong{font-size:18px;color:#294c3b}.resource-editor-panel .back-link{display:none}
@media(max-width:900px){.app-shell{display:block}.app-sidebar{position:sticky;z-index:20;top:0;height:auto;min-height:0;padding:12px 18px 0;gap:12px;border-bottom:1px solid #dce5dc}.app-sidebar .brand{display:none}.main-nav{flex-direction:row;gap:6px;overflow-x:auto;scrollbar-width:thin;padding:0 0 10px}.main-nav a{padding:10px 12px;font-size:13px}.nav-icon{display:none}.sidebar-caption{display:none}.workspace-shell{min-height:calc(100vh - 54px)}.site-header{height:60px;min-height:60px;padding:0 20px}.mobile-brand{display:flex;align-items:center;gap:9px;margin-right:auto;color:#173f35;font-weight:700;font-size:17px}.mobile-brand .brand-mark{width:32px;height:32px;border-radius:9px;font-size:18px}.workbench{grid-template-columns:minmax(240px,320px) minmax(0,1fr);gap:14px}.resource-list-panel{top:140px;max-height:calc(100vh - 160px)}}
@media(max-width:680px){.app-sidebar{padding:8px 10px 0}.main-nav{gap:4px}.main-nav a{padding:9px 10px;font-size:12px}.account-menu>span{max-width:130px}.workbench{grid-template-columns:minmax(0,1fr)}.workbench.has-selection .resource-list-panel{display:none}.workbench:not(.has-selection) .resource-editor-panel{display:none}.resource-list-panel{position:static;max-height:none}.resource-editor-panel{padding:16px;min-height:0}.resource-editor-panel .back-link{display:block}.resource-editor-panel>.editor-panel,.resource-editor-panel>.logo-panel{padding:20px 14px}.site-footer{padding:18px 20px}.dashboard{padding:34px 20px}.workbench-empty{min-height:220px}}
.resource-items>button.resource-item{font:inherit;cursor:pointer;width:100%}.resource-items>button.resource-item:hover{color:#18352d}

/* Rifiniture layout responsive del gestionale */
.app-shell{width:100%;max-width:none;margin:0}
.editor-page{width:100%;max-width:none;margin:0}
.dashboard{padding-left:clamp(20px,3vw,52px);padding-right:clamp(20px,3vw,52px)}
.workbench{grid-template-columns:minmax(0,1.05fr) minmax(0,1fr)}
.mobile-menu-toggle{display:none}
.card-resource-item{grid-template-columns:minmax(90px,.72fr) minmax(0,1.28fr);align-items:center;gap:12px}
.card-resource-item>span{display:flex;flex-direction:column;gap:5px;min-width:0}
.card-resource-item .card-item-number strong,.card-resource-item .card-item-customer strong{font-size:15px;line-height:1.25;color:#18352d}
.card-resource-item small{font-size:12px;line-height:1.35;color:#6b7b6d;overflow-wrap:anywhere}
.card-summary{display:grid;grid-template-columns:minmax(0,1fr) auto auto;align-items:center;gap:20px;padding:18px 20px;margin:0 0 18px;background:#fff;border:1px solid #e0e6db;border-radius:14px}
.card-summary .eyebrow{display:block;margin-bottom:7px}
.card-summary .card-code{margin:0;font-size:17px}
.card-summary-balance{display:block;font-size:20px;white-space:nowrap}
.detail-tabs{display:flex;gap:6px;padding:6px;margin:0 0 18px;background:#e9eee5;border-radius:12px;overflow-x:auto}
.detail-tabs button{flex:1;min-width:max-content;padding:11px 16px;border:0;border-radius:8px;background:transparent;color:#526b5c;font:inherit;font-size:14px;font-weight:600;cursor:pointer}
.detail-tabs button.active{background:#fff;color:#173f35;box-shadow:0 1px 4px #173f3518}
.detail-tabs button:focus-visible,.mobile-menu-toggle:focus-visible{outline:3px solid #96b69e;outline-offset:2px}
.detail-tab-panel>.editor-panel{margin:0 0 14px}
.detail-tab-panel>.editor-panel h3{font-size:20px;margin-top:0}
.notification-workbench{display:grid;grid-template-columns:minmax(0,1.08fr) minmax(0,1fr);gap:20px;align-items:start}
.notification-history-panel,.notification-editor-panel{min-width:0;padding:22px;background:#fff;border:1px solid #e0e6db;border-radius:14px}
.resource-panel-heading{align-items:flex-start}
.resource-panel-heading .muted{margin:6px 0 0;font-size:12px}
.resource-panel-heading .button{margin:0;white-space:nowrap}
.notification-list{display:grid;gap:9px;margin-top:18px}
.notification-list-item{display:grid;gap:7px;width:100%;padding:14px;border:1px solid #e3e9e1;border-radius:10px;background:#fff;color:#526b5c;text-align:left;font:inherit;font-size:12px;cursor:pointer}
.notification-list-item:hover{background:#f5f8f2;border-color:#cbd9ca}
.notification-list-item.active{background:#edf3e9;border-color:#91ad91;box-shadow:inset 3px 0 #235c47}
.notification-list-heading{display:flex;justify-content:space-between;align-items:baseline;gap:10px;color:#18352d}
.notification-list-heading strong{font-size:15px;overflow-wrap:anywhere}
.notification-list-heading small,.notification-list-item>small{color:#718176}
.notification-compose,.notification-detail{margin:0;padding:24px}
.notification-compose legend{font-size:21px}
.notification-compose>p{color:#6b7b6d;font-size:13px;line-height:1.6}
.notification-compose .field{margin:0 0 17px}
.notification-compose .button-primary{margin-top:0}
.notification-detail h2{font-size:25px;margin:12px 0}
.notification-message{white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.7}
.notification-stats{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin-top:22px}
.notification-stats>div{display:flex;flex-direction:column;gap:4px;padding:14px;border-radius:10px;background:#f3f6ef}
.notification-stats strong{font-size:22px;color:#173f35}
.notification-stats span,.notification-footnote{font-size:11px;color:#6b7b6d}
.notification-footnote{display:block;margin-top:20px;line-height:1.5}
.notification-inbox{margin-top:22px}
@media(max-width:900px){
  .app-shell{display:block}
  .app-sidebar{display:none;position:fixed;z-index:35;top:60px;left:0;right:0;height:auto;min-height:0;padding:14px 16px 18px;gap:12px;border-bottom:1px solid #dce5dc;box-shadow:0 14px 28px #173f3520}
  .app-sidebar.nav-open{display:flex}
  .mobile-nav-state:checked~.app-sidebar{display:flex}
  .app-sidebar .brand,.sidebar-caption{display:none}
  .main-nav{flex-direction:column;gap:4px;padding:0;overflow:visible}
  .main-nav a{padding:12px;font-size:14px}
  .nav-icon{display:inline-block}
  .workspace-shell{min-height:100vh}
  .site-header{position:sticky;top:0;z-index:40;height:60px;min-height:60px;justify-content:flex-start;padding:0 18px}
  .mobile-menu-toggle{display:flex;flex-direction:column;justify-content:center;gap:5px;width:40px;height:40px;padding:9px;border:1px solid #dce5dc;border-radius:9px;background:#fff;cursor:pointer}
  .mobile-menu-toggle{flex-shrink:0}
  .mobile-nav-state:focus-visible~.workspace-shell .mobile-menu-toggle{outline:3px solid #8db5cf;outline-offset:2px}
  .mobile-nav-state:checked~.workspace-shell .mobile-menu-toggle{background:#e5f0f7}
  .mobile-menu-toggle span{display:block;width:20px;height:2px;background:#173f35;border-radius:2px}
  .mobile-brand{display:flex;align-items:center;gap:9px;margin-right:auto;color:#173f35;font-weight:700;font-size:17px}
  .mobile-brand .brand-mark{width:32px;height:32px;border-radius:9px;font-size:18px}
  .workbench{grid-template-columns:minmax(0,1.05fr) minmax(0,1fr);gap:14px}
  .resource-list-panel{top:76px;max-height:calc(100vh - 100px)}
}
@media(max-width:680px){
  .workbench,.notification-workbench{grid-template-columns:minmax(0,1fr)}
  .workbench.has-selection .resource-list-panel{display:none}
  .workbench:not(.has-selection) .resource-editor-panel{display:none}
  .resource-list-panel{position:static;max-height:none}
  .resource-editor-panel{padding:16px;min-height:0}
  .resource-editor-panel .back-link{display:block}
  .card-summary{grid-template-columns:minmax(0,1fr) auto;gap:12px;padding:14px}
  .card-summary>button{grid-column:1/-1;justify-self:start}
  .card-summary-balance{font-size:17px}
  .notification-history-panel,.notification-editor-panel{padding:15px}
  .notification-compose,.notification-detail{padding:20px 15px}
  .resource-panel-heading{flex-wrap:wrap}
  .resource-panel-heading .button{font-size:12px;padding:10px}
  .notification-inbox{margin:18px 20px}
  .site-footer{padding:18px 20px}
}

/* Tema azzurro pastello */
:root{color:#263d4c;background:#f3f7fa}
body{color:#263d4c;background:#f3f7fa}
a{color:#4b7898}
.app-shell{background:#f3f7fa}
.app-sidebar{background:#365f7b;color:#edf5fa}
.app-sidebar .brand-mark{background:#e5f0f7;color:#365f7b}
.app-sidebar .brand small{color:#c3d8e6}
.main-nav a{color:#d9e8f1}
.main-nav a:hover{background:#ffffff18;color:#fff}
.main-nav a.active{background:#e5f0f7;color:#365f7b}
.sidebar-caption{color:#bed2df}
.mobile-brand{color:#365f7b}
.mobile-brand .brand-mark{background:#dceaf3;color:#365f7b}
.button-primary{background:#4b7898;color:#fff}
.button-primary:hover{background:#3c6989}
.button-quiet{background:#e3edf4;color:#365f7b}
.button:focus-visible,a:focus-visible,.detail-tabs button:focus-visible,.mobile-menu-toggle:focus-visible{outline-color:#8db5cf}
.site-header{background:#fbfdfe;border-color:#dce7ee}
.site-footer{border-color:#e1eaf0;color:#718694}
.dashboard{color:#263d4c}
.dashboard-subtitle,.muted{color:#718694}
.eyebrow{color:#577b94}
.editor-page,.resource-list-panel,.resource-editor-panel,.notification-history-panel,.notification-editor-panel,.editor-panel,.table-wrap,.login-panel,.profile-panel{border-color:#dce7ee}
.resource-item{color:#263d4c;border-color:#dce7ee}
.resource-item:hover,.notification-list-item:hover{background:#f2f7fa;border-color:#bfd3e1}
.resource-item.active,.notification-list-item.active{background:#eaf3f8;border-color:#9dbed2;box-shadow:inset 3px 0 #4b7898}
.resource-item span,.card-resource-item small,.form-help,.notification-list-item,.notification-list-heading small,.notification-list-item>small{color:#718694}
.card-resource-item .card-item-number strong,.card-resource-item .card-item-customer strong,.notification-list-heading strong{color:#263d4c}
.detail-tabs{background:#e6eff5}
.detail-tabs button{color:#5a7588}
.detail-tabs button.active{color:#365f7b}
.card-summary,.notification-history-panel,.notification-editor-panel{background:#fff}
.notification-stats>div{background:#f0f6fa}
.notification-stats strong,.workbench-empty strong{color:#365f7b}
.workbench-empty{color:#718694}
.mobile-menu-toggle{border-color:#d5e3ec}
.mobile-menu-toggle span{background:#365f7b}
.main-nav a.active{color:#365f7b}
.search-form input,.field input{border-color:#d3e1ea;background:#fbfdfe;color:#263d4c}
.search-form input:focus,.field input:focus,.login-form input:focus{outline-color:#b7d1e1}
.merchant-table th{background:#e9f1f6;color:#5d788b}
.status-badge.active{background:#e5f0f7;color:#426c88}
.status-badge.inactive{background:#f3e9e2;color:#86563d}
.role-badge{background:#e5f0f7;color:#426c88}
.card-visual{background:linear-gradient(135deg,#4b7898,#2d506a);color:#f5f9fc}
.welcome-panel,.brand-preview{background-color:#e8f1f6}
.login-panel h2,.welcome-panel h2,.profile-panel h2{color:#263d4c}
.notification-list-item{border-color:#dce7ee}
.card-resource-item.active{box-shadow:inset 3px 0 #4b7898}
.generate-card-panel{display:grid;gap:24px;margin-top:20px;padding:24px;background:#f8fbfd;border:1px solid #dce7ee;border-radius:12px}
.generate-card-panel form fieldset{display:grid;gap:18px;border:0;padding:0;margin:0}
.generate-card-panel form legend{font-size:18px;font-weight:650;margin-bottom:2px}
.generate-card-panel form p{margin:0;color:#718694;font-size:13px;line-height:1.6}
.generate-merchant-search{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:end;gap:12px}
.generate-merchant-search .field{min-width:0}
.generate-merchant-search .button{margin:0}
@media(max-width:900px){.app-sidebar{border-color:#d5e3ec}.mobile-menu-toggle{background:#fff}}
@media(max-width:560px){.generate-card-panel{padding:18px 14px}.generate-merchant-search{grid-template-columns:minmax(0,1fr)}}

/* Mantiene il footer nel viewport e limita le aree di elenco all'altezza utile. */
.app-shell{height:100vh;height:100dvh;min-height:0;overflow:hidden}
.workspace-shell{height:100vh;height:100dvh;min-height:0;overflow:hidden}
.app-sidebar{height:100%;min-height:0}
.site-header,.site-footer{flex-shrink:0}
.main-content{min-height:0;overflow-y:auto;overscroll-behavior:contain}
.workspace-page{height:100%;min-height:0;display:flex;flex-direction:column;overflow:hidden}
.workspace-page>.workbench{flex:1 1 0;min-height:0;grid-template-rows:minmax(0,1fr);overflow:hidden}
.workspace-page>.workbench>.resource-list-panel,.workspace-page>.workbench>.resource-editor-panel{height:100%;min-height:0;max-height:none;position:relative;top:auto;overflow:auto;overscroll-behavior:contain}
.workspace-page>.workbench>.resource-editor-panel{display:block}
.workspace-page>.workbench>.resource-list-panel{display:block}
.notification-page{min-height:100%;}
.notification-workbench{min-height:0;align-items:stretch}
.notification-history-panel,.notification-editor-panel{max-height:calc(100dvh - 270px);overflow-y:auto;overscroll-behavior:contain}
@media(max-width:900px){
  .app-shell{height:100vh;height:100dvh;overflow:hidden}
  .workspace-shell{height:100vh;height:100dvh;min-height:0}
  .workspace-page>.workbench>.resource-list-panel,.workspace-page>.workbench>.resource-editor-panel{position:relative;top:auto}
}
@media(max-width:680px){
  .workspace-page>.workbench{grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,1fr)}
  .workspace-page>.workbench.has-selection>.resource-list-panel{display:none}
  .workspace-page>.workbench:not(.has-selection)>.resource-editor-panel{display:none}
  .notification-workbench{grid-template-rows:minmax(180px,.8fr) minmax(250px,1.2fr)}
  .notification-history-panel,.notification-editor-panel{max-height:none}
}
.resource-paginated-list{display:flex;flex-direction:column;overflow:hidden}
.workspace-page>.workbench>.resource-paginated-list{display:flex;flex-direction:column;overflow:hidden}
.resource-paginated-list>.resource-items{flex:1 1 auto;min-height:0;overflow-y:auto;overscroll-behavior:contain}
.resource-paginated-list>.resource-items{align-content:start;grid-auto-rows:max-content}
.resource-paginated-list>.pagination{position:static;flex:0 0 auto;margin-top:10px;padding:12px 0 0;border-top:1px solid #dce7ee;background:#fff}
.pagination,.pagination-controls{position:sticky;bottom:0;z-index:8;padding:12px 0;background:#ffffffed;backdrop-filter:blur(8px);border-top:1px solid #dce7ee;box-shadow:0 -8px 16px #263d4c0a}
.resource-paginated-list>.pagination{box-shadow:none}
.notification-history-panel>.pagination-controls,.notification-inbox>.pagination-controls{margin-top:16px}
.resource-list-panel .search-form:has(.button-clear-search){grid-template-columns:minmax(0,1fr) auto auto}
.button-clear-search{padding:9px 11px;background:#eef3f6;color:#5c7588}
.merchant-resource-item{grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:5px 12px}
.merchant-resource-item>strong{font-size:15px;color:#263d4c}
.merchant-resource-item>small{grid-column:1/-1;color:#718694;font-size:12px;overflow-wrap:anywhere}
.merchant-resource-item>.status-badge{white-space:nowrap}
.print-merchant-item,.print-batch-summary{grid-template-columns:minmax(0,1fr);text-align:left}
.print-merchant-item strong,.print-batch-summary strong{font-size:15px;color:#263d4c}
.print-merchant-item small,.print-batch-summary small{font-size:12px;color:#718694}
.print-card-items{align-content:start;grid-auto-rows:max-content}
.print-card-item{grid-template-columns:30px minmax(0,.8fr) minmax(0,1.2fr);align-items:center;gap:10px;padding:12px 14px}
.print-card-item>span{display:flex;flex-direction:column;gap:4px;min-width:0}
.print-card-item>span strong{font-size:14px;color:#263d4c;line-height:1.25}
.print-card-item>span small{font-size:11px;color:#718694}
.print-card-select{display:grid;place-items:center}
.print-card-select input{width:18px;height:18px;accent-color:#4b7898}
.print-card-item.active{background:#eaf3f8;border-color:#9dbed2}
.print-batch-list{align-content:start;grid-auto-rows:max-content}
.notification-list-item{font:inherit;cursor:pointer;text-align:left;grid-template-columns:minmax(0,1fr);gap:6px}
.notification-list-item .notification-list-heading{display:flex;justify-content:space-between;align-items:baseline;gap:12px}
.notification-list-item .notification-list-heading strong{font-size:15px;color:#263d4c}
.notification-list-item .notification-list-heading small,.notification-list-item>small{font-size:11px;color:#718694}
.notification-list-item>span:not(.notification-list-heading){font-size:12px;color:#577b94}
.inbox-notification-item{grid-template-columns:minmax(0,1fr) auto;gap:6px 12px;margin:10px 0}
.inbox-notification-item>strong{font-size:15px;color:#263d4c}
.inbox-notification-item>small{font-size:11px;color:#718694}
.inbox-notification-item>p{grid-column:1/-1;margin:3px 0 8px;white-space:pre-wrap;overflow-wrap:anywhere;font-size:13px;line-height:1.55;color:#526b7a}
.inbox-notification-item>.button{grid-column:1/-1;justify-self:start;margin:0}
.movement-row,.attachment-row{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:9px 0;padding:13px 14px;border:1px solid #dce7ee;border-radius:10px;background:#fff}
.movement-row>div,.attachment-row>div{min-width:0}
.movement-row>div>strong,.attachment-row .attachment-name{font-size:14px;color:#263d4c}
.movement-row p,.attachment-row p{margin:4px 0;font-size:12px;color:#718694}
.movement-row small{font-size:11px;color:#8495a0}
.movement-row>span{font-size:12px;color:#577b94;white-space:nowrap}
.attachment-row{align-items:center}
.attachment-row .button{flex-shrink:0}
.pagination,.pagination.pagination-controls{align-items:center;flex-direction:row}
@media(max-width:560px){
  .print-card-item{grid-template-columns:25px minmax(0,.8fr) minmax(0,1.2fr);gap:7px;padding:11px 9px}
  .movement-row,.attachment-row{align-items:flex-start}
  .movement-row>span{white-space:normal;text-align:right}
}
