/* Stili propri dell'area «customers» nel restyling come HubLEM (docs/restyle). */

/* --- Testate del telefono che mancavano (from-*-600 to-*-600) -------------- */
.hub-grad--lime-green { background: linear-gradient(90deg, #65a30d, #16a34a); }
.hub-grad--sky-blue { background: linear-gradient(90deg, #0284c7, #2563eb); }
.hub-grad--blue-cyan-fab { background: linear-gradient(135deg, #2563eb, #0891b2); }
.hub-grad--violet-purple { background: linear-gradient(90deg, #7c3aed, #9333ea); }
.hub-grad--indigo-purple-fab { background: linear-gradient(135deg, #4f46e5, #9333ea); }
.hub-grad--rose-pink { background: linear-gradient(90deg, #e11d48, #db2777); }
.hub-grad--emerald-tile { background: linear-gradient(135deg, #34d399, #059669); }

/* Bordo delle card del telefono per sezione. */
.customers-mcard--lime { border-color: #ecfccb; }
.customers-mcard--sky { border-color: #e0f2fe; }
.customers-mcard--orange { border-color: #ffedd5; }
.customers-mcard--teal { border-color: #ccfbf1; }
.customers-mcard--violet { border-color: #ede9fe; }
.customers-mcard--purple { border-color: #f3e8ff; }
.customers-mcard--cyan { border-color: #cffafe; }
.customers-mcard--indigo { border-color: #e0e7ff; }
.customers-mcard--rose { border-color: #ffe4e6; }
.customers-mcard--amber { border-color: #fef3c7; }

/* --- Anteprima «Invia Preventivo» ------------------------------------------ */
.customers-quote-preview { border: 2px solid #e5e7eb; border-radius: 1rem; overflow: hidden; background: #fff; }
.customers-quote-preview__band { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; background: linear-gradient(90deg, #111827, #374151); color: #fff; padding: 1rem 1.25rem; }
.customers-quote-preview__kicker { font-size: .7rem; font-weight: 900; letter-spacing: .15em; opacity: .75; }
.customers-quote-preview__body { padding: 1rem 1.25rem; }
.customers-quote-preview__offer { border: 2px solid #bbf7d0; background: #f0fdf4; border-radius: .9rem; padding: .75rem 1rem; text-align: center; color: #14532d; }
.customers-quote-preview__offer small { display: block; font-size: .65rem; font-weight: 900; letter-spacing: .08em; }
.customers-quote-preview__offer strong { font-size: 1.6rem; font-weight: 900; }

/* --- Clienti (Clienti.jsx) -------------------------------------------------- */
.customers-filters__search { max-width: 28rem; }
.customers-filters__wide { max-width: 16rem; }
.customers-grid.d-md-grid { display: none; }
@media (min-width: 768px) { .customers-grid.d-md-grid { display: grid; } }
.customers-card__body { padding-left: 1.1rem; }
.customers-card__line { font-size: .82rem; color: #4b5563; overflow-wrap: anywhere; }
.customers-card__others { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem; padding-top: .5rem; border-top: 1px solid #f1f2f4; }
.customers-card__others > span:first-child { font-size: .72rem; font-weight: 700; color: #4338ca; margin-right: .25rem; }
.customers-card__contract { font-size: .82rem; font-weight: 700; display: flex; gap: .35rem; align-items: center; }
.customers-card__contract a { text-decoration: none; }
.customers-card__actions { flex-wrap: nowrap; }
.customers-card__actions .btn, .customers-card__actions form { flex: 0 0 auto; }
.customers-card__actions .customers-card__grow { flex: 1 1 auto; }
.customers-card.is-selected { border-color: #93c5fd; box-shadow: 0 0 0 2px #bfdbfe; }
.customers-selbar { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; padding: 1rem; margin-bottom: .75rem; background: #fef2f2; border: 2px solid #fecaca; border-radius: .75rem; color: #7f1d1d; }
.customers-selbar form { margin: 0; }
.customers-empty { border: 2px solid #e5e7eb; border-radius: 1rem; background: #fff; padding: 3rem 1rem; text-align: center; color: #6b7280; }
.customers-empty .bi { font-size: 4rem; color: #d1d5db; display: block; margin-bottom: .75rem; }
.customers-pager { display: flex; justify-content: center; align-items: center; gap: 1rem; margin: 1.5rem 0; }
.customers-pager__label { border: 2px solid #e5e7eb; border-radius: .5rem; padding: .5rem 1rem; font-weight: 600; background: #fff; }

/* Telefono */
.customers-dot { width: .75rem; height: .75rem; border-radius: 50%; background: #d1d5db; flex: 0 0 .75rem; margin-top: .4rem; }
.customers-dot.is-on { background: #22c55e; }
.customers-nocontract { border: 1px solid #fecaca; background: #fef2f2; color: #dc2626; border-radius: .75rem; padding: .5rem; text-align: center; font-size: .7rem; font-weight: 900; }
.customers-sector-box { display: flex; flex-wrap: wrap; gap: .25rem .75rem; align-items: baseline; border: 1px solid #e5e7eb; border-radius: .75rem; padding: .45rem .65rem; margin-bottom: .4rem; font-size: .75rem; }
.customers-sector-box strong { font-weight: 900; }
.customers-mactions { display: flex; gap: .5rem; justify-content: flex-end; margin-top: .5rem; }
.customers-mactions form { margin: 0; }
.customers-micon { width: 2.75rem; height: 2.75rem; border-radius: .75rem; display: grid; place-items: center; background: #f3f4f6; color: #374151; border: 0; text-decoration: none; }
.customers-micon--blue { background: #eff6ff; color: #2563eb; }
.customers-micon--red { background: #fef2f2; color: #dc2626; }
.customers-box--orange { background: #fff7ed; border-color: #fed7aa; color: #7c2d12; }
.customers-box--orange small { color: #ea580c; }
.customers-box--gray { background: #f9fafb; border-color: #e5e7eb; color: #1f2937; }
.customers-box--indigo { background: #eef2ff; border-color: #c7d2fe; color: #312e81; }
.customers-box--indigo small { color: #4f46e5; }
.customers-box--fuchsia { background: #fdf4ff; border-color: #f5d0fe; color: #701a75; }
.customers-box--fuchsia small { color: #c026d3; }
.customers-box--cyan { background: #ecfeff; border-color: #a5f3fc; color: #164e63; }
.customers-box--cyan small { color: #0891b2; }
.customers-cta { background: linear-gradient(90deg, #2563eb, #0891b2, #0e7490); border: 0; }
.customers-form--phone .hub-step__num { background: #e0f2fe; color: #0284c7; }

/* Doppioni dell'importazione (DialogDoppioni.jsx) */
.customers-dup { border: 4px solid #fdba74; border-radius: 1rem; margin-bottom: 1rem; overflow: hidden; background: #fff; }
.customers-dup__head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5rem; padding: .6rem 1rem; color: #fff; background: linear-gradient(90deg, #f97316, #dc2626); }
.customers-dup__body { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; padding: 1rem; }
@media (max-width: 767.98px) { .customers-dup__body { grid-template-columns: 1fr; } }
.customers-dup__new { border: 2px solid #bfdbfe; border-radius: .75rem; padding: .75rem; background: #eff6ff; }
.customers-dup__old { border: 2px solid #fecaca; border-radius: .75rem; padding: .75rem; background: #fef2f2; }
.customers-dup__label { font-size: .7rem; font-weight: 900; letter-spacing: .05em; margin-bottom: .35rem; }
.customers-dup__street { background: #fff; border-radius: .5rem; padding: .35rem .5rem; margin: .35rem 0; font-size: .8rem; }
.customers-dup__street small { display: block; font-size: .6rem; font-weight: 900; color: #6b7280; }
.customers-dup__choices { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .5rem; }
.customers-dup__match { display: flex; justify-content: space-between; gap: .5rem; background: #fff; border-radius: .5rem; padding: .5rem; margin-bottom: .4rem; }
.customers-dup__summary { position: sticky; bottom: 0; display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; padding: .75rem 1rem; background: #fff; border: 2px solid #e5e7eb; border-radius: 1rem; box-shadow: 0 -6px 16px -8px rgba(0, 0, 0, .2); }

/* --- Pulsanti pieni di HubLEM che mancavano ------------------------------- */
.btn-purple { color: #fff; background: #9333ea; border-color: #9333ea; }
.btn-purple:hover { color: #fff; background: #7e22ce; border-color: #7e22ce; }
.btn-indigo { color: #fff; background: #4f46e5; border-color: #4f46e5; }
.btn-indigo:hover { color: #fff; background: #4338ca; border-color: #4338ca; }
.btn-cyan { color: #fff; background: #0891b2; border-color: #0891b2; }
.btn-cyan:hover { color: #fff; background: #0e7490; border-color: #0e7490; }
.btn-teal { color: #fff; background: #0d9488; border-color: #0d9488; }
.btn-teal:hover { color: #fff; background: #0f766e; border-color: #0f766e; }

/* --- Anagrafiche: trasportatori, destinatari, rappresentanti, fornitori ---- */
.customers-grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
@media (max-width: 991.98px) { .customers-grid-2 { grid-template-columns: 1fr; } }
.customers-title-lg { font-size: 1.1rem; }
.customers-title-xl { font-size: 1.25rem; }
.customers-square { flex: 0 0 2.75rem; height: 2.75rem; border-radius: .75rem; display: grid; place-items: center; font-size: 1.3rem; }
.customers-square--purple { background: #f3e8ff; color: #9333ea; }
.customers-square--indigo { background: #e0e7ff; color: #4f46e5; }
.customers-round { flex: 0 0 2.75rem; height: 2.75rem; border-radius: 50%; display: grid; place-items: center; font-size: 1.25rem; }
.customers-round--blue { background: #dbeafe; color: #2563eb; }
.customers-round--orange { background: #ffedd5; color: #ea580c; }
.customers-round--teal { background: #ccfbf1; color: #0d9488; }
.customers-round--lg { flex-basis: 3.5rem; width: 3.5rem; height: 3.5rem; font-size: 1.6rem; }
.customers-panel { border: 1px solid; border-radius: .75rem; padding: .6rem .8rem; font-size: .8rem; margin-top: .5rem; display: grid; gap: .15rem; }
.customers-panel > strong { font-size: .78rem; margin-bottom: .15rem; }
.customers-panel--cyan { background: #ecfeff; border-color: #a5f3fc; color: #164e63; }
.customers-panel--green { background: #f0fdf4; border-color: #bbf7d0; color: #14532d; }
.customers-panel--orange { background: #fff7ed; border-color: #fed7aa; color: #7c2d12; }
.customers-panel--yellow { background: #fefce8; border-color: #fef08a; color: #713f12; }
.customers-panel--indigo { background: #eef2ff; border-color: #c7d2fe; color: #312e81; }
.customers-route { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; background: #fff; border-radius: .5rem; padding: .3rem .5rem; }
.customers-route > b { margin-left: auto; }
.customers-chip { display: inline-flex; align-items: center; gap: .35rem; background: #fff; border: 1px solid #bbf7d0; border-radius: 999px; padding: .2rem .6rem; text-decoration: none; font-weight: 700; font-size: .78rem; }
.customers-searchbar { display: flex; gap: .5rem; align-items: center; max-width: 40rem; }
.customers-search-card { border: 2px solid #e5e7eb; border-radius: 1rem; overflow: hidden; background: #fff; }
.customers-search-card > header { padding: .65rem 1rem; font-weight: 700; }
.customers-search-card--purple > header { background: #faf5ff; color: #6b21a8; }
.customers-badge-outline--orange { background: #fff; color: #c2410c; border: 1px solid #fdba74; }
.customers-badge-outline--blue { background: #fff; color: #1d4ed8; border: 1px solid #93c5fd; }
.customers-thumb--orange { background: #fff7ed; color: #ea580c; border-color: #fed7aa; flex-basis: 3rem; width: 3rem; height: 3rem; font-size: 1.4rem; }
.customers-row--expired { border-color: #fed7aa; background: #fffbf5; }
.customers-history { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; border: 1px solid #e5e7eb; border-radius: .6rem; padding: .35rem .6rem; }
.customers-rep { align-items: flex-start; }

/* --- Contratti Costi Generali (GestioneContrattiFornitoriGenerali.jsx) ----- */
.customers-infocard { border: 2px solid #c7d2fe; border-radius: 1rem; overflow: hidden; background: #fff; }
.customers-infocard > header { background: #eef2ff; color: #3730a3; padding: .65rem 1rem; font-weight: 700; }
.customers-infocard > p { margin: 0; padding: .75rem 1rem; font-size: .85rem; color: #374151; }
.customers-split { border-radius: .9rem; padding: .75rem; background: linear-gradient(90deg, #f0fdf4, #fefce8, #eff6ff); border: 1px solid #e5e7eb; }
.customers-split > strong { font-size: .8rem; display: block; margin-bottom: .5rem; }
.customers-split__tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .5rem; }
.customers-split__tile { background: #fff; border: 2px solid; border-radius: .75rem; padding: .5rem; text-align: center; }
.customers-split__tile b { display: block; font-size: 1.25rem; font-weight: 800; }
.customers-split__tile span { font-size: .7rem; color: #4b5563; }
.customers-split__tile--green { border-color: #bbf7d0; } .customers-split__tile--green b { color: #16a34a; }
.customers-split__tile--yellow { border-color: #fef08a; } .customers-split__tile--yellow b { color: #ca8a04; }
.customers-split__tile--blue { border-color: #bfdbfe; } .customers-split__tile--blue b { color: #2563eb; }
.customers-split--form legend { float: none; width: auto; margin-bottom: .5rem; }

/* --- Report (trasportatori, destinatari, rappresentanti) ------------------- */
.customers-period { border: 2px solid #bfdbfe; background: #eff6ff; border-radius: 1rem; padding: .75rem 1rem; }
.customers-period > header { font-weight: 700; color: #1e40af; margin-bottom: .5rem; }
.customers-report-row { position: relative; display: grid; gap: .5rem; padding: 1rem 3rem 1rem 1rem; border-bottom: 1px solid #f1f2f4; }
.customers-report-row:last-child { border-bottom: 0; }
.customers-report-row:hover { background: #f9fafb; }
.customers-report-row__head { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.customers-report-row__grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: .5rem; }
.customers-report-row__grid small { display: block; font-size: .7rem; color: #6b7280; }
.customers-report-row__grid b { font-size: 1rem; }
@media (max-width: 991.98px) { .customers-report-row__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.customers-report-row__chevron { position: absolute; right: 1rem; top: 50%; transform: translateY(-50%); color: #9ca3af; font-size: 1.25rem; }
.customers-balance { border-radius: 1rem; padding: 1rem 1.25rem; color: #fff; display: grid; gap: .1rem; }
.customers-balance.is-positive { background: linear-gradient(90deg, #2563eb, #4f46e5); }
.customers-balance.is-negative { background: linear-gradient(90deg, #ea580c, #dc2626); }
.customers-balance small { font-size: .75rem; font-weight: 800; opacity: .85; }
.customers-balance strong { font-size: 2.25rem; font-weight: 900; line-height: 1.1; }
.customers-panel--red { background: #fef2f2; border-color: #fecaca; color: #7f1d1d; }

/* --- Giacenze Clienti (GiacenzeClienti.jsx) ------------------------------- */
.customers-grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
@media (max-width: 1199.98px) { .customers-grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 767.98px) { .customers-grid-3 { grid-template-columns: 1fr; } }
.customers-stock-card { display: grid; gap: .3rem; background: #fff; border: 2px solid #e5e7eb; border-radius: 1rem; padding: 1rem; text-decoration: none; color: #111827; transition: box-shadow .2s ease; }
.customers-stock-card:hover { box-shadow: 0 10px 20px -8px rgba(0, 0, 0, .2); color: #111827; }
.customers-stock-card strong { font-size: 1.05rem; }
.customers-stock-card small { color: #6b7280; }
.customers-stock-card__icon { width: 3rem; height: 3rem; border-radius: 1rem; display: grid; place-items: center; color: #fff; font-size: 1.4rem; }
.customers-grad--indigo { background: linear-gradient(135deg, #6366f1, #9333ea); }
.customers-stock-card__value { display: block; margin-top: .4rem; border-radius: .75rem; padding: .5rem .75rem; background: linear-gradient(90deg, #f0fdf4, #dcfce7); color: #14532d; font-weight: 800; font-size: 1.1rem; }
.customers-stock-card__value small { display: block; font-size: .6rem; font-weight: 900; color: #16a34a; }
.customers-stock-item { display: grid; gap: .35rem; background: #fff; border: 2px solid #e5e7eb; border-radius: 1rem; padding: 1rem; }

/* --- Obiettivi Clienti (ObiettiviClienti.jsx di HubEcology) ---------------- */
.customers-prospect.is-alert { border-color: #fdba74; background: #fffbf5; }
.customers-prospect__alert { background: #ffedd5; color: #9a3412; border-radius: .6rem; padding: .35rem .7rem; font-size: .78rem; font-weight: 800; }

/* --- Situazione Debitoria (SituazioneDebitoria.jsx) ----------------------- */
.customers-listcard { border: 2px solid #e5e7eb; border-radius: 1rem; background: #fff; overflow: hidden; }
.customers-listcard > header { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .75rem; padding: .75rem 1rem; border-bottom: 1px solid #f1f2f4; }
.customers-listcard > header .hub-tabs { margin: 0; }
.customers-listcard > .hub-pills { margin: .75rem; }
.customers-debt { display: flex; gap: 1rem; padding: 1rem; border-bottom: 1px solid #f1f2f4; }
.customers-debt:last-child { border-bottom: 0; }
.customers-debt__actions { display: flex; flex-direction: column; gap: .5rem; flex: 0 0 12rem; }
.customers-debt__actions form { margin: 0; }
@media (max-width: 767.98px) {
  .customers-debt { flex-wrap: wrap; }
  .customers-debt__actions { flex-basis: 100%; }
}

/* «Gestione Cassa» per autista come HubEcology (ADR-268, decisione 18) */
.cash-driver-card { border: 1px solid #e2e8f0; border-radius: .75rem; padding: .75rem; background: #fff; }
.cash-driver-card:hover { border-color: #a7f3d0; }
.cash-wallet-icon { flex: none; width: 3rem; height: 3rem; border-radius: .5rem; display: inline-flex; align-items: center; justify-content: center; font-size: 1.4rem; }
.cash-wallet-icon--cash { background: #fef3c7; color: #d97706; }
.cash-wallet-icon--card { background: #dbeafe; color: #2563eb; }
.cash-unassigned { background: #fff7ed; }
.cash-register-totals .hub-box { min-width: 6.5rem; text-align: center; }
