/**
 * Booking Modal Styles - Sistema di Prenotazione
 * Stili per il form di prenotazione modale
 */

.booking-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  visibility: hidden;
  opacity: 0;
  transition: all 0.3s ease;
}

.booking-modal.active {
  visibility: visible;
  opacity: 1;
}

.booking-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(5px);
}

.booking-modal-content {
  position: relative;
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  max-width: 600px;
  width: 90vw;
  max-height: 90vh;
  overflow-y: auto;
  transform: translateY(-20px);
  transition: transform 0.3s ease;
}

.booking-modal.active .booking-modal-content {
  transform: translateY(0);
}

.booking-modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-direction: column;
  padding: 2rem 2rem 1rem;
  border-bottom: 1px solid #eee;
}

.booking-modal-header h2 {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-text);
  margin: 0 0 0.5rem 0;
  width: 100%;
}

.booking-modal-subtitle {
  font-size: 0.9rem;
  color: #666;
  line-height: 1.4;
  margin: 0 0 1rem 0;
  max-width: calc(100% - 50px);
  font-style: italic;
}

.booking-modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: none;
  border: none;
  font-size: 1.2rem;
  color: #999;
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.booking-modal-close:hover {
  background: #f5f5f5;
  color: var(--color-text);
}

.booking-form {
  padding: 0 2rem 2rem;
}

.booking-form-section {
  margin-bottom: 2rem;
}

.booking-form-section h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--color-text);
  margin: 0 0 1rem 0;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--color-accent);
  display: inline-block;
}

.booking-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}

.booking-form-row.triple {
  grid-template-columns: 1fr 1fr 1fr;
}

.booking-form-field {
  display: flex;
  flex-direction: column;
}

.booking-form-field label {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--color-text);
  margin-bottom: 0.3rem;
}

.booking-form-field input,
.booking-form-field select,
.booking-form-field textarea {
  padding: 0.75rem;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  font-size: 1rem;
  transition: border-color 0.2s ease;
  font-family: var(--font-body);
}

.booking-form-field input:focus,
.booking-form-field select:focus,
.booking-form-field textarea:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.1);
}

.booking-form-field small {
  font-size: 0.8rem;
  color: #666;
  margin-top: 0.25rem;
}

.booking-form-field textarea {
  resize: vertical;
  min-height: 80px;
}

.booking-form-actions {
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid #eee;
}

.booking-btn-secondary {
  padding: 0.75rem 1.5rem;
  background: #f5f5f5;
  color: var(--color-text);
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: var(--font-body);
}

.booking-btn-secondary:hover {
  background: #e8e8e8;
  border-color: #ccc;
}

.booking-btn-primary {
  padding: 0.75rem 1.5rem;
  background: var(--color-accent);
  color: white;
  border: 2px solid var(--color-accent);
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: var(--font-body);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.booking-btn-primary:hover {
  background: var(--color-accent-dark);
  border-color: var(--color-accent-dark);
  transform: translateY(-1px);
}

.booking-btn-primary i {
  font-size: 1.1rem;
}

/* Success Message */
.booking-success {
  text-align: center;
  padding: 3rem 2rem;
}

.booking-success i {
  font-size: 4rem;
  color: #4CAF50;
  margin-bottom: 1rem;
}

.booking-success h3 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-text);
  margin: 0 0 1rem 0;
}

.booking-success p {
  font-size: 1rem;
  color: var(--color-text-light);
  margin: 0;
  line-height: 1.5;
}

/* Error Message */
.booking-error {
  text-align: center;
  padding: 3rem 2rem;
}

.booking-error i {
  font-size: 4rem;
  color: #ff6b6b;
  margin-bottom: 1rem;
}

.booking-error h3 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-text);
  margin: 0 0 1rem 0;
}

.booking-error p {
  font-size: 1rem;
  color: var(--color-text-light);
  margin: 0 0 1.5rem 0;
  line-height: 1.5;
}

.booking-error .booking-btn-primary {
  margin: 0 auto;
}

/* Responsive Design */
@media (max-width: 768px) {
  .booking-modal-content {
    width: 95vw;
    max-height: 95vh;
  }
  
  .booking-modal-header {
    padding: 1.5rem 1.5rem 1rem;
  }
  
  .booking-modal-header h2 {
    font-size: 1.3rem;
  }
  
  .booking-form {
    padding: 0 1.5rem 1.5rem;
  }
  
  .booking-form-row {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }
  
  .booking-form-row.triple {
    grid-template-columns: 1fr;
  }
  
  .booking-form-actions {
    flex-direction: column;
    gap: 0.75rem;
  }
  
  .booking-btn-secondary,
  .booking-btn-primary {
    justify-content: center;
    width: 100%;
  }
}

@media (max-width: 480px) {
  .booking-modal-content {
    border-radius: 12px;
  }
  
  .booking-modal-header {
    padding: 1rem 1rem 0.75rem;
  }
  
  .booking-form {
    padding: 0 1rem 1rem;
  }
  
  .booking-form-field input,
  .booking-form-field select,
  .booking-form-field textarea {
    padding: 0.6rem;
    font-size: 0.95rem;
  }
}

/* Animation for better UX */
.booking-form-field input:invalid {
  border-color: #ff6b6b;
}

.booking-form-field input:valid {
  border-color: #4CAF50;
}

/* Loading state */
.booking-btn-primary:disabled {
  background: #ccc;
  border-color: #ccc;
  cursor: not-allowed;
  transform: none;
}

.booking-btn-primary:disabled:hover {
  background: #ccc;
  border-color: #ccc;
  transform: none;
}
