/* Medicare Corsi 1.0.121 - allineamento uniforme di campi e pulsanti.
   Caricato per ultimo. Specificita' pari a un semplice selettore di elemento
   (es. "input"): batte le regole generiche e perde contro i layout dedicati
   delle singole pagine, che restano invariati. */

/* 1. Tutti i campi hanno lo stesso margine: prima solo input type=text/search/
      password e select lo azzeravano; email, numero, data e input senza tipo
      restavano 7px piu' in basso dei menu accanto. */
:where(.portal-shell .system-page) :is(input, select, textarea):where(:not([type=checkbox], [type=radio], [type=hidden], [type=file], [type=range], [type=color], [type=submit], [type=button])){
  margin-top:0;margin-bottom:0;box-sizing:border-box}
:where(.portal-shell .system-page) :is(input, select):where(:not([type=checkbox], [type=radio], [type=hidden], [type=file], [type=range], [type=color], [type=submit], [type=button])){
  height:46px;min-height:46px}

/* 2. Etichetta sopra il campo: stessa distanza (7px) per ogni campo. */
:where(.portal-shell .system-page) label:where(:has(> :is(input:not([type=checkbox], [type=radio], [type=hidden]), select, textarea))){
  display:flex;flex-direction:column;gap:7px}

/* 3. "Inserisci azienda": la riga con la spunta occupa quanto il testo di
      un'etichetta, cosi' il campo azienda sta alla stessa altezza del codice fiscale. */
.portal-shell .system-page .training-company-option .training-company-toggle{
  min-height:0;height:16.5px;margin:0 0 7px;padding:0;align-items:center;line-height:16.5px}
.portal-shell .system-page .training-company-option .training-company-toggle input[type=checkbox]{
  width:16px;height:16px;min-height:0;margin:0;flex:0 0 16px}
.portal-shell .system-page .training-company-option .training-company-name{gap:0}

/* 4. Pulsanti nei moduli: stessa altezza dei campi, testo su una riga. */
.portal-shell .system-page form .system-button{min-height:46px;box-sizing:border-box;white-space:nowrap}
.portal-shell .system-page form .system-button.icon-only{min-width:46px;justify-content:center}

/* 5. Riga docente (menu + pulsante rimuovi): stessa base. */
.portal-shell .system-page .training-instructor-row{align-items:end}

/* 6. Pulsanti dei moduli e delle intestazioni: 46px come i campi (lo standard
      precedente imponeva 42px con !important anche accanto ai campi da 46px). */
.portal-shell .system-page form .system-button,
.portal-shell .system-page .system-head-actions .system-button{min-height:46px!important}
.portal-shell .system-page form .system-button.icon-only{height:46px!important;min-height:46px!important;min-width:46px}
.portal-shell .system-page .training-instructor-row .icon-only{height:46px!important}

/* 7. Posta: ricerca e azioni di gruppo sulla stessa altezza, testo su una riga. */
.portal-shell :is(.inbox-search, .sent-search) :is(input, select):not([type=checkbox], [type=radio], [type=hidden]){
  margin-top:0;height:42px;min-height:42px;box-sizing:border-box}
.portal-shell :is(.inbox-search, .sent-search) button{height:42px;min-height:42px;white-space:nowrap}
.portal-shell .sent-toolbar button,
.portal-shell .bulk-bar :is(button, .button-link){min-height:38px;height:38px;white-space:nowrap;box-sizing:border-box}

/* 8. Dashboard: campo "Cosa vuoi fare?" allineato al pulsante. */
.portal-shell .command-search input{margin-top:0}
.portal-shell .sent-toolbar .sent-search button,
.portal-shell .inbox-search button{height:42px;min-height:42px}
.portal-shell .sent-toolbar{align-items:center}
.portal-shell .sent-toolbar > *{align-self:center}
.portal-shell .command-search input{height:42px;min-height:42px;box-sizing:border-box}

/* 9. Etichette che per progetto stanno accanto al campo (non sopra). */
.portal-shell .certificate-editor-toolbar label,
.portal-shell .certificate-editor-margin-controls label{flex-direction:row;align-items:center;gap:8px}
.portal-shell .certificate-editor-margin-controls :is(input, select),
.portal-shell .certificate-editor-toolbar :is(input, select){margin:0}
.portal-shell label:has(> select[name="mailbox"]){flex-direction:row;align-items:center}

/* 10. Backup: pianificazione con campi e pulsante sulla stessa base
       (il margine globale di 14px sotto le etichette alzava i campi). */
.portal-shell .backup-plan-fields96 label{margin:0}
