/* Modal Recovery Form Styles - Clean Ledger Design */

/* Modal Container */
#recovery-modal .modal {
  max-width: 560px;
  width: 95%;
  margin: 2rem auto;
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
  padding: 0;
  overflow: hidden;
}

/* Modal Header */
#recovery-modal .modal-header {
  padding: 24px 32px;
  border-bottom: 1px solid #e5e5e5;
  background: #fafafa;
}

#recovery-modal .modal-header h3 {
  font-size: 20px;
  font-weight: 600;
  color: #1e1e1e;
  margin: 0;
}

#recovery-modal .modal-close {
  position: absolute;
  top: 24px;
  right: 24px;
  background: transparent;
  border: none;
  font-size: 24px;
  color: #666;
  cursor: pointer;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  transition: background 0.2s;
}

#recovery-modal .modal-close:hover {
  background: rgba(0, 0, 0, 0.05);
  color: #1e1e1e;
}

/* Form Container */
#recovery-modal form {
  padding: 32px;
}

/* Card Styling */
#recovery-modal .modal-card {
  border-radius: 12px;
  border: 1px solid #e5e5e5;
  background: #fafafa;
  overflow: hidden;
}

#recovery-modal .card-body {
  padding: 24px;
}

#recovery-modal .card-body h6 {
  margin-bottom: 20px;
  font-weight: 600;
  font-size: 15px;
  color: #1e1e1e;
}

/* Button Group (Radio Tabs) */
#recovery-modal .btn-group {
  display: flex;
  gap: 0;
  width: 100%;
  margin-bottom: 24px;
  background: #fff;
  border: 1px solid #e5e5e5;
  border-radius: 8px;
  overflow: hidden;
}

#recovery-modal .btn-check {
  display: none;
}

#recovery-modal .btn-outline-primary {
  flex: 1;
  padding: 12px 16px;
  background: transparent;
  border: none;
  border-right: 1px solid #e5e5e5;
  font-size: 13px;
  font-weight: 500;
  color: #666;
  cursor: pointer;
  transition: all 0.2s;
  text-align: center;
}

#recovery-modal .btn-outline-primary:last-child {
  border-right: none;
}

#recovery-modal .btn-check:checked + .btn-outline-primary {
  background: #142533;
  color: #ffffff;
  font-weight: 600;
}

#recovery-modal .btn-outline-primary:hover {
  background: rgba(20, 37, 51, 0.05);
}

#recovery-modal .btn-check:checked + .btn-outline-primary:hover {
  background: #0f1d28;
}

/* Form Controls */
#recovery-modal .form-label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: #333;
  margin-bottom: 8px;
}

#recovery-modal .form-control {
  width: 100%;
  border-radius: 8px;
  border: 1px solid #e5e5e5;
  background: #ffffff;
  font-family: "SF Mono", "Monaco", "Inconsolata", "Fira Code", monospace;
  font-size: 13px;
  padding: 12px 14px;
  color: #1e1e1e;
  transition: all 0.2s;
  resize: vertical;
}

#recovery-modal .form-control::placeholder {
  color: #999;
  font-family: "SF Mono", "Monaco", "Inconsolata", monospace;
}

#recovery-modal .form-control:focus {
  outline: none;
  border-color: #142533;
  box-shadow: 0 0 0 3px rgba(20, 37, 51, 0.08);
}

#recovery-modal .form-control.small-text {
  font-size: 11px;
  line-height: 1.5;
}

#recovery-modal input[type="password"].form-control {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0.5px;
}

/* Connection Input Sections */
#recovery-modal .connection-input {
  display: none;
  animation: fadeIn 0.2s ease-in;
}

#recovery-modal .connection-input.active {
  display: block;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(-5px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Helper Text */
#recovery-modal .text-muted {
  display: block;
  font-size: 12px;
  color: #666;
  margin-top: 8px;
  line-height: 1.5;
}

/* Spacing Utilities */
#recovery-modal .mt-2 {
  margin-top: 16px;
}

#recovery-modal .mt-3 {
  margin-top: 24px;
}

#recovery-modal .mb-2 {
  margin-bottom: 12px;
}

#recovery-modal .mb-3 {
  margin-bottom: 20px;
}

#recovery-modal .w-100 {
  width: 100%;
}

/* Buttons */
#recovery-modal .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 24px;
  font-size: 14px;
  font-weight: 600;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
  font-family: "Inter", sans-serif;
}

#recovery-modal .btn-primary {
  background: #142533;
  color: #ffffff;
}

#recovery-modal .btn-primary:hover {
  background: #0f1d28;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(20, 37, 51, 0.2);
}

#recovery-modal .btn-primary:active {
  transform: translateY(0);
}

#recovery-modal .btn-outline-secondary {
  background: transparent;
  color: #666;
  border: 1px solid #e5e5e5;
}

#recovery-modal .btn-outline-secondary:hover {
  background: #fafafa;
  border-color: #ccc;
  color: #1e1e1e;
}

#recovery-modal .btn-rounded {
  border-radius: 8px;
}

/* Icons in Buttons */
#recovery-modal .btn i {
  margin-right: 8px;
  font-size: 16px;
}

/* Focus States for Accessibility */
#recovery-modal .btn:focus-visible,
#recovery-modal .btn-outline-primary:focus-visible {
  outline: 2px solid #142533;
  outline-offset: 2px;
}

/* Form Validation Errors */
#recovery-modal .form-control.is-invalid {
  border-color: #ef4444;
  background: #fef2f2;
}

#recovery-modal .form-control.is-invalid:focus {
  border-color: #dc2626;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

#recovery-modal .invalid-feedback {
  display: none;
  color: #dc2626;
  font-size: 12px;
  margin-top: 6px;
  line-height: 1.4;
}

#recovery-modal .invalid-feedback.d-block {
  display: block;
}

/* Responsive */
@media (max-width: 640px) {
  #recovery-modal .modal {
    margin: 1rem;
    width: calc(100% - 2rem);
  }

  #recovery-modal form {
    padding: 24px 20px;
  }

  #recovery-modal .modal-header {
    padding: 20px 24px;
  }

  #recovery-modal .card-body {
    padding: 20px;
  }

  #recovery-modal .btn-outline-primary {
    font-size: 12px;
    padding: 10px 12px;
  }
}
