.work-section {
  padding: 60px 20px;
}

.work-container {
  max-width: 600px;
  margin: 0 auto;
  background: var(--color-background-light);
  border-radius: var(--radius-large);
  box-shadow: var(--shadow-medium);
  padding: 40px;
}

.work-title {
  font-size: 2rem;
  color: var(--text-heading);
  text-align: center;
  font-weight: bold;
  margin: 0;
}

.work-underline {
  display: block;
  width: 300px;
  margin: 4px auto 20px auto;
  height: 3px;
  background-color: var(--color-primary-light);
  border-radius: var(--radius-small);
  margin-top: 4px;
}

.work-description {
  text-align: center;
  color: var(--text-main);
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 30px;
}

.work-description p {
  margin: 0;
}

/* Form */
.work-form .form-group {
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
}

.work-form label {
  font-weight: bold;
  color: var(--text-main);
  margin-bottom: 6px;
}

.work-form input {
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: var(--radius-medium);
  font-size: 16px;
  cursor: pointer;
  background: #f4f4f4;
  font-family: var(--font-main);
}

.work-form input[type='file'] {
  background: #f4f4f4;
}

.work-form input::placeholder {
  font-size: 1rem;
  font-family: var(--font-main);
  color: var(--text-main);
  opacity: 0.8;
}

.work-form input:focus {
  outline: none;
  border-color: var(--color-primary-light);
  box-shadow: 0 0 6px rgba(122, 158, 126, 0.6);
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
  background: var(--color-background-light);
}

/* --- STILE CHECKBOX PRIVACY --- */
.privacy-group {
  margin: 15px 0 25px 0; /* Spazio tra l'ultimo input e il bottone */
  text-align: left;
}

.checkbox-container {
  display: flex;
  align-items: flex-start; /* Allinea la spunta in alto se il testo va su più righe */
  gap: 12px;
  cursor: pointer;
  font-size: 0.95rem;
  color: var(--text-main);
  line-height: 1.5;
}

.checkbox-container input[type='checkbox'] {
  width: 18px;
  height: 18px;
  margin-top: 2px; /* Centra la spunta con la prima riga di testo */
  cursor: pointer;
  accent-color: var(--color-primary); /* Usa il tuo verde principale */
}

.checkbox-container a {
  color: var(--color-primary);
  text-decoration: underline;
  font-weight: 600;
}

.checkbox-container a:hover {
  color: var(--color-primary-dark);
}

.work-button {
  width: 100%;
  padding: 14px;
  background-color: var(--color-primary);
  color: var(--text-light);
  border: none;
  border-radius: var(--radius-large);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease,
    background-color 0.3s ease;
  margin-top: 10px;
}

.work-button:hover {
  transform: scale(1.03);
  box-shadow: var(--shadow-light);
  background-color: var(--color-primary-dark);
}

/* Container dei messaggi flash */
.flash-messages {
  margin: 20px 0;
  padding: 0;
  list-style: none;
}

/* Stile base per tutti i messaggi */
.flash {
  padding: 15px 20px;
  border-radius: 6px;
  margin-bottom: 15px;
  font-size: 16px;
  color: #fff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
  opacity: 0;
  transform: translateY(-10px);
  animation: flashFadeIn 0.5s forwards;
}

/* Messaggio di successo */
.flash.success {
  background-color: #4caf50; /* verde */
  border: 1px solid #45a049;
}

/* Messaggio di errore */
.flash.error {
  background-color: #f44336; /* rosso */
  border: 1px solid #e53935;
}

/* Messaggio informativo */
.flash.info {
  background-color: #2196f3; /* blu */
  border: 1px solid #1976d2;
}

/* Animazione di comparsa */
@keyframes flashFadeIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Opzionale: sparizione automatica dopo 5 secondi */
.flash-messages .flash {
  animation: flashFadeIn 0.5s forwards, flashFadeOut 0.5s 5s forwards;
}

@keyframes flashFadeOut {
  from {
    opacity: 1;
    transform: translateY(0);
  }
  to {
    opacity: 0;
    transform: translateY(-10px);
  }
}
