/*
 * Colori più scuri per i controlli che Bootstrap 4.0 (caricato dalla CDN nel layout) disegna con un contrasto
 * inferiore a 4,5:1 (WCAG 2 AA, testo normale). BUG #1213.
 *
 *   blu   #007bff -> #0069d9   bianco su blu 3,98:1 -> 5,22:1
 *   verde #28a745 -> #1e7e34   bianco su verde 3,13:1 -> 5,14:1
 *
 * Cambia solo il colore: forma, dimensioni e margini restano quelli di Bootstrap. Caricato dopo Bootstrap nel layout.
 * Ogni coppia colore di testo / sfondo è verificata da tests/Unit/AccessibilityContrastTest.php.
 */

/* Link e testo "primary" */
a {
  color: #0069d9;
}
a:hover {
  color: #0056b3;
}
.text-primary {
  color: #0069d9 !important;
}
a.text-primary:hover,
a.text-primary:focus {
  color: #0056b3 !important;
}
.text-success {
  color: #1e7e34 !important;
}
a.text-success:hover,
a.text-success:focus {
  color: #19692c !important;
}

/* Pulsante blu: testo bianco su sfondo blu */
.btn-primary {
  color: #fff;
  background-color: #0069d9;
  border-color: #0062cc;
}
.btn-primary:hover {
  color: #fff;
  background-color: #0062cc;
  border-color: #005cbf;
}
.btn-primary:focus,
.btn-primary.focus {
  box-shadow: 0 0 0 0.2rem rgba(0, 105, 217, 0.5);
}
.btn-primary.disabled,
.btn-primary:disabled {
  background-color: #0069d9;
  border-color: #0062cc;
}
.btn-primary:not(:disabled):not(.disabled):active,
.btn-primary:not(:disabled):not(.disabled).active,
.show > .btn-primary.dropdown-toggle {
  color: #fff;
  background-color: #005cbf;
  border-color: #0056b3;
}
.btn-primary:not(:disabled):not(.disabled):active:focus,
.btn-primary:not(:disabled):not(.disabled).active:focus,
.show > .btn-primary.dropdown-toggle:focus {
  box-shadow: 0 0 0 0.2rem rgba(0, 105, 217, 0.5);
}

/* Pulsante blu con solo il contorno: testo blu su sfondo bianco */
.btn-outline-primary {
  color: #0069d9;
  border-color: #0069d9;
}
.btn-outline-primary:hover {
  color: #fff;
  background-color: #0069d9;
  border-color: #0069d9;
}
.btn-outline-primary:focus,
.btn-outline-primary.focus {
  box-shadow: 0 0 0 0.2rem rgba(0, 105, 217, 0.5);
}
.btn-outline-primary.disabled,
.btn-outline-primary:disabled {
  color: #0069d9;
  background-color: transparent;
}
.btn-outline-primary:not(:disabled):not(.disabled):active,
.btn-outline-primary:not(:disabled):not(.disabled).active,
.show > .btn-outline-primary.dropdown-toggle {
  color: #fff;
  background-color: #0069d9;
  border-color: #0069d9;
}

/* Pulsante verde: testo bianco su sfondo verde */
.btn-success {
  color: #fff;
  background-color: #1e7e34;
  border-color: #1c7430;
}
.btn-success:hover {
  color: #fff;
  background-color: #1c7430;
  border-color: #19692c;
}
.btn-success:focus,
.btn-success.focus {
  box-shadow: 0 0 0 0.2rem rgba(30, 126, 52, 0.5);
}
.btn-success.disabled,
.btn-success:disabled {
  background-color: #1e7e34;
  border-color: #1c7430;
}
.btn-success:not(:disabled):not(.disabled):active,
.btn-success:not(:disabled):not(.disabled).active,
.show > .btn-success.dropdown-toggle {
  color: #fff;
  background-color: #19692c;
  border-color: #155724;
}
.btn-success:not(:disabled):not(.disabled):active:focus,
.btn-success:not(:disabled):not(.disabled).active:focus,
.show > .btn-success.dropdown-toggle:focus {
  box-shadow: 0 0 0 0.2rem rgba(30, 126, 52, 0.5);
}
