/* ============================================
   PROFESSIONELLES NEUER KANDIDAT MODAL
   ============================================ */

.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.2s ease-out;
}

.modal-container {
  background: white;
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  width: 90%;
  max-width: 800px;
  max-height: 90vh;
  overflow-y: auto;
  animation: slideUp 0.3s ease-out;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 32px;
  border-bottom: 1px solid #e5e7eb;
}

.modal-title {
  font-size: 24px;
  font-weight: 600;
  color: #1f2937;
  margin: 0;
}

.modal-close {
  background: none;
  border: none;
  color: #6b7280;
  font-size: 24px;
  cursor: pointer;
  padding: 4px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  transition: all 0.2s;
}

.modal-close:hover {
  background: #f3f4f6;
  color: #1f2937;
}

.modal-body {
  padding: 32px;
}

.form-section {
  margin-bottom: 32px;
}

.section-title {
  font-size: 16px;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 16px;
  padding-bottom: 8px;
  border-bottom: 2px solid #e5e7eb;
}

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

.form-group {
  display: flex;
  flex-direction: column;
}

.form-group.full-width {
  grid-column: 1 / -1;
}

.form-label {
  font-size: 12px;
  font-weight: 500;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}

.form-label.required::after {
  content: ' *';
  color: #ef4444;
}

.form-input {
  padding: 12px 16px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 14px;
  color: #1f2937;
  transition: all 0.2s;
  background: white;
  width: 100%;
}

.form-input:focus {
  outline: none;
  border-color: #2c5a66;
  box-shadow: 0 0 0 3px rgba(44, 90, 102, 0.1);
}

.form-input::placeholder {
  color: #9ca3af;
}

/* Select styling */
select.form-input {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%236b7280'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 20px;
  padding-right: 40px;
  cursor: pointer;
}

.form-input::placeholder {
  color: #9ca3af;
}

.input-with-button {
  position: relative;
  display: flex;
  gap: 8px;
}

.scrape-button {
  padding: 0 16px;
  background: white;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  color: #374151;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 6px;
}

.scrape-button:hover {
  background: #f9fafb;
  border-color: #2c5a66;
  color: #2c5a66;
}

.scrape-button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* CV Upload Area */
.cv-upload-area {
  border: 2px dashed #d1d5db;
  border-radius: 12px;
  padding: 48px;
  text-align: center;
  transition: all 0.3s;
  cursor: pointer;
  background: #fafafa;
  position: relative;
}

.cv-upload-area:hover {
  border-color: #2c5a66;
  background: #f0f7f9;
}

.cv-upload-area.drag-over {
  border-color: #2c5a66;
  background: #e6f3f6;
  transform: scale(1.02);
}

.cv-upload-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 16px;
  color: #9ca3af;
}

.cv-upload-text {
  font-size: 16px;
  color: #374151;
  margin-bottom: 8px;
  font-weight: 500;
}

.cv-upload-hint {
  font-size: 13px;
  color: #6b7280;
}

.cv-file-preview {
  display: none;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: #f0f7f9;
  border-radius: 8px;
  margin-top: 16px;
}

.cv-file-preview.active {
  display: flex;
}

.cv-file-icon {
  color: #2c5a66;
  font-size: 24px;
}

.cv-file-info {
  flex: 1;
}

.cv-file-name {
  font-size: 14px;
  font-weight: 500;
  color: #1f2937;
  margin-bottom: 4px;
}

.cv-file-size {
  font-size: 12px;
  color: #6b7280;
}

.cv-processing-status {
  display: none;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  background: #eff6ff;
  border-left: 4px solid #3b82f6;
  border-radius: 8px;
  margin-top: 16px;
}

.cv-processing-status.active {
  display: flex;
}

.cv-status-spinner {
  width: 20px;
  height: 20px;
  border: 2px solid #dbeafe;
  border-top-color: #3b82f6;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.cv-status-text {
  font-size: 14px;
  color: #1e40af;
  font-weight: 500;
}

/* Rating Badge (new system) */
.rating-stars {
  display: inline-flex;
  align-items: center;
}

/* Legacy rating-star styles (kept for backwards compat) */
.rating-star {
  display: none;
}

/* Status Select */
.status-select {
  padding: 12px 40px 12px 16px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 14px;
  color: #1f2937;
  background: white;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%236b7280'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 20px;
}

.status-select:focus {
  outline: none;
  border-color: #2c5a66;
  box-shadow: 0 0 0 3px rgba(44, 90, 102, 0.1);
}

/* Modal Footer */
.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  padding: 24px 32px;
  border-top: 1px solid #e5e7eb;
  background: #fafafa;
}

.btn {
  padding: 12px 24px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  border: none;
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-secondary {
  background: white;
  color: #374151;
  border: 1px solid #d1d5db;
}

.btn-secondary:hover {
  background: #f9fafb;
}

.btn-primary {
  background: #2c5a66;
  color: white;
}

.btn-primary:hover {
  background: #234650;
}

.btn-primary:disabled {
  background: #9ca3af;
  cursor: not-allowed;
}

.btn-icon {
  font-size: 16px;
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideUp {
  from {
    transform: translateY(20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Responsive */
@media (max-width: 768px) {
  .form-row {
    grid-template-columns: 1fr;
  }

  .modal-container {
    width: 95%;
    margin: 20px;
  }

  .cv-upload-area {
    padding: 32px 16px;
  }
}
