/* Attività DM v3.5 — form iPhone: corrige le righe con +Crea, inputs e overflow.
   CSS puro. Non modifica alcun dato o logica di sincronizzazione. */
#taskDialog .field-inline,
#taskDialog .section-row {min-width:0;}
#taskDialog .field-inline .input-label,
#taskDialog .section-row .field-title {min-width:0; line-height:1.4;}
#taskDialog #newAreaFromTask,
#taskDialog #newLabelFromTask {white-space:nowrap; flex-shrink:0;}
#taskDialog .two-col > div {min-width:0;}
#taskDialog .two-col select,
#taskDialog .two-col input {min-width:0; max-width:100%;}
/* Layout a colonna singola sui telefoni. Gli strumenti desktop restano affiancati. */
@media (max-width:520px) {
  #taskDialog .sheet-body {padding-left:18px; padding-right:18px;}
  #taskDialog .two-col {display:grid; grid-template-columns:minmax(0,1fr); gap:5px;}
  #taskDialog .field-inline {display:flex; flex-wrap:nowrap; align-items:center; justify-content:space-between; column-gap:14px;}
  #taskDialog .field-inline .input-label {flex:1 1 auto; margin:18px 0 8px;}
  #taskDialog .field-inline .text-link,
  #taskDialog .section-row .text-link {
    display:inline-flex; align-items:center; justify-content:center;
    width:auto; min-height:36px; padding:7px 12px;
    font-size:13px; line-height:1.2; font-weight:800;
    border:1px solid #cddaf7; border-radius:11px;
    background:#f0f5ff; color:#2055c7;
    flex:0 0 auto; white-space:nowrap;
  }
  #taskDialog .two-col .input-label {margin-top:14px; margin-bottom:8px;}
  #taskDialog .section-row {display:flex; flex-wrap:nowrap; align-items:center; justify-content:space-between; gap:12px; margin-top:20px;}
  #taskDialog .section-row .field-title {margin:0; flex:1 1 auto; overflow-wrap:break-word;}
  #taskDialog .category-hint {margin-top:10px; margin-bottom:12px;}
  #taskDialog .two-col input[type=time],
  #taskDialog .two-col input[type=date] {width:100%; max-width:100%; min-height:46px;}
}
@media (max-width:360px) {
  #taskDialog .sheet-body {padding-left:14px; padding-right:14px;}
  #taskDialog .section-row {gap:8px;}
  #taskDialog .section-row .field-title {font-size:13px;}
}
