/* ==================== MODAL SOLICITAR SERVIÇOS ==================== */
/* Porte do modal-solicitar.component.css do frontend Angular. */

/* ==================== MODAL FUNDO ==================== */
.modal-fundo {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  z-index: 1040;
  padding: 80px 16px 20px;
}

.modal-fundo[hidden] {
  display: none;
}

/* ==================== CAIXA ==================== */
.modal-caixa {
  background: var(--white);
  border-radius: 16px;
  width: 100%;
  max-width: 420px;
  max-height: calc(100vh - 100px);
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-xl);
  overflow: hidden;
  animation: modalSolicitarFadeIn 0.25s ease;
}

/* ==================== ANIMAÇÃO ==================== */
@keyframes modalSolicitarFadeIn {
  from {
    opacity: 0;
    transform: translateY(10px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* ==================== CABEÇALHO ==================== */
.modal-cabecalho {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 16px 24px;
  position: relative;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  flex-shrink: 0;
}

.modal-cabecalho h5 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--white);
  margin: 0;
  text-align: center;
}

/* ==================== BOTÃO FECHAR ==================== */
.btn-fechar {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.2);
  border: none;
  font-size: 14px;
  cursor: pointer;
  color: var(--white);
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.btn-fechar:hover {
  background: rgba(255, 255, 255, 0.35);
}

/* ==================== CORPO ==================== */
.modal-corpo {
  padding: 16px 20px;
  overflow-y: auto;
  flex: 1;
}

/* ==================== FORM ==================== */
.modal-corpo .form-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--gray-700);
  margin-bottom: 4px;
}

.modal-corpo .form-control,
.modal-corpo .form-select {
  border-radius: 8px;
  border: 1px solid var(--gray-300);
  font-size: 0.875rem;
  padding: 8px 12px;
  color: var(--gray-800);
  transition: all 0.2s ease;
}

.modal-corpo .form-control:focus,
.modal-corpo .form-select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(197, 48, 48, 0.1);
  outline: none;
}

.modal-corpo textarea.form-control {
  resize: vertical;
  min-height: 80px;
}

/* ==================== BOTÃO ==================== */
.modal-corpo .btn-primary {
  background-color: var(--primary);
  border-color: var(--primary);
  border-radius: 8px;
  padding: 10px;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--white);
  margin-top: 8px;
  transition: all 0.2s ease;
}

.modal-corpo .btn-primary:hover {
  background-color: var(--primary-dark);
  border-color: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.modal-corpo .btn-primary:disabled {
  opacity: 0.7;
  transform: none;
  box-shadow: none;
}

/* ==================== ERROS ==================== */
.modal-corpo .text-danger {
  font-size: 0.75rem;
}

/* ==================== SUCESSO ==================== */
.modal-sucesso {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 24px 16px;
  gap: 12px;
}

.modal-sucesso[hidden] {
  display: none;
}

.modal-sucesso i {
  font-size: 3rem;
  color: #28a745;
}

.modal-sucesso p {
  font-size: 0.95rem;
  color: var(--gray-700);
  margin: 0;
}

/* ==================== RESPONSIVO ==================== */
@media (max-width: 480px) {
  .modal-caixa {
    max-width: 100%;
    border-radius: 12px;
  }

  .modal-cabecalho h5 {
    font-size: 0.9rem;
  }
}
