/* Enhanced Manuscript Submission Form Styles */

/* Fixed Submission Button */
.submit-manuscript-btn {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background-color: #2c5282;
  color: white;
  border: none;
  border-radius: 50px;
  padding: 12px 24px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  z-index: 1000;
  display: flex;
  align-items: center;
  transition: all 0.3s ease;
}

.submit-manuscript-btn i {
  margin-right: 8px;
}

.submit-manuscript-btn:hover {
  background-color: #1a365d;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

/* Modal Styles */
.manuscript-modal {
  display: none;
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(5px);
}

.manuscript-modal-content {
  background-color: #fff;
  margin: 2% auto;
  width: 85%;
  max-width: 1000px;
  border-radius: 8px;
  box-shadow: 0 5px 25px rgba(0, 0, 0, 0.2);
  position: relative;
  max-height: 96vh;
  overflow-y: auto;
  padding: 0;
}

.manuscript-modal-header {
  background-color: #f9f9f9;
  padding: 20px 30px;
  border-bottom: 1px solid #eaeaea;
  border-radius: 8px 8px 0 0;
}

.manuscript-modal-header h2 {
  margin: 0 0 10px 0;
  color: #2c5282;
  display: flex;
  align-items: center;
  font-size: 24px;
}

.manuscript-modal-header h2 i {
  margin-right: 10px;
  color: #2c5282;
}

.manuscript-modal-header p {
  margin: 0 0 20px 0;
  color: #666;
  line-height: 1.5;
}

.manuscript-close {
  position: absolute;
  top: 20px;
  right: 25px;
  color: #666;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
  z-index: 10;
  transition: color 0.3s;
}

.manuscript-close:hover {
  color: #2c5282;
}

/* Form Styles */
.manuscript-form {
  padding: 30px;
}

.manuscript-form h3 {
  margin: 0 0 20px 0;
  color: #2c5282;
  font-size: 20px;
  border-bottom: 2px solid #eaeaea;
  padding-bottom: 10px;
}

.manuscript-form-group {
  margin-bottom: 20px;
}

.manuscript-form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: #333;
}

.manuscript-form-group input[type='text'],
.manuscript-form-group input[type='email'],
.manuscript-form-group input[type='number'],
.manuscript-form-group select,
.manuscript-form-group textarea {
  width: 100%;
  padding: 12px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 16px;
  transition: border-color 0.3s;
}

.manuscript-form-group input:focus,
.manuscript-form-group select:focus,
.manuscript-form-group textarea:focus {
  border-color: #2c5282;
  outline: none;
  box-shadow: 0 0 0 2px rgba(44, 82, 130, 0.2);
}

.manuscript-form-group .help-text {
  margin-top: 5px;
  font-size: 14px;
  color: #666;
}

.required-field::after {
  content: '*';
  color: #e53e3e;
  margin-left: 4px;
}

.manuscript-form-group input.invalid,
.manuscript-form-group select.invalid,
.manuscript-form-group textarea.invalid {
  border-color: #e53e3e;
}

.form-row {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.form-col {
  flex: 1;
  min-width: 250px;
}

/* File Input Styling */
.file-input-wrapper {
  margin-bottom: 5px;
}

.file-input-label {
  display: inline-block;
  background-color: #2c5282;
  color: white;
  padding: 10px 15px;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.3s;
  font-weight: 600;
}

.file-input-label:hover {
  background-color: #1a365d;
}

.file-input-label i {
  margin-right: 8px;
}

.file-input {
  position: absolute;
  width: 0.1px;
  height: 0.1px;
  opacity: 0;
  overflow: hidden;
  z-index: -1;
}

.file-name {
  margin-top: 8px;
  font-size: 14px;
  color: #666;
  display: block;
}

.file-info {
  display: flex;
  align-items: center;
  gap: 5px;
}

.file-info i {
  color: #2c5282;
}

.file-count {
  margin-bottom: 8px;
  font-weight: 600;
}

.file-list {
  max-height: 120px;
  overflow-y: auto;
  border: 1px solid #eaeaea;
  border-radius: 4px;
  padding: 8px;
  background: #f9f9f9;
}

.file-item {
  padding: 4px 8px;
  display: flex;
  align-items: center;
  gap: 5px;
}

.file-item:not(:last-child) {
  border-bottom: 1px solid #eaeaea;
}

/* Steps Navigation */
.submission-steps {
  display: flex;
  justify-content: space-between;
  margin-top: 20px;
  position: relative;
}

.submission-steps::before {
  content: '';
  position: absolute;
  top: 16px;
  left: 20px;
  right: 20px;
  height: 3px;
  background-color: #eaeaea;
  z-index: 1;
}

.step {
  text-align: center;
  position: relative;
  z-index: 2;
  flex: 1;
}

.step-number {
  width: 35px;
  height: 35px;
  border-radius: 50%;
  background-color: #eaeaea;
  color: #666;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 8px;
  font-weight: bold;
  transition: all 0.3s;
}

.step-label {
  font-size: 14px;
  color: #666;
  font-weight: 600;
  white-space: nowrap;
}

.step.active .step-number {
  background-color: #2c5282;
  color: white;
}

.step.active .step-label {
  color: #2c5282;
}

.step.completed .step-number {
  background-color: #38a169;
  color: white;
}

.step.completed .step-number::after {
  content: '✓';
}

/* Co-Author Styles */
.co-author-item {
  background-color: #f9f9f9;
  border: 1px solid #eaeaea;
  border-radius: 6px;
  padding: 15px;
  margin-bottom: 15px;
}

.co-author-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
}

.co-author-header h4 {
  margin: 0;
  color: #2c5282;
}

.remove-co-author {
  background: none;
  border: none;
  color: #e53e3e;
  cursor: pointer;
  font-size: 18px;
  padding: 0;
}

/* Navigation Buttons */
.form-nav {
  display: flex;
  justify-content: space-between;
  margin-top: 30px;
}

.btn-prev,
.btn-next,
.btn-secondary,
.btn-primary {
  padding: 10px 20px;
  border-radius: 4px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  display: flex;
  align-items: center;
  transition: all 0.3s;
}

.btn-prev {
  background-color: #f7fafc;
  color: #2c5282;
  border: 1px solid #2c5282;
}

.btn-prev i {
  margin-right: 8px;
}

.btn-next {
  background-color: #2c5282;
  color: white;
}

.btn-next i {
  margin-left: 8px;
}

.btn-secondary {
  background-color: #edf2f7;
  color: #2d3748;
  border: 1px solid #e2e8f0;
}

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

.btn-prev:hover,
.btn-secondary:hover {
  background-color: #edf2f7;
}

.btn-next:hover,
.btn-primary:hover {
  background-color: #1a365d;
}

/* Submit Button */
.manuscript-form-submit {
  background-color: #38a169;
  color: white;
  border: none;
  border-radius: 4px;
  padding: 12px 30px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.3s;
}

.manuscript-form-submit:hover {
  background-color: #2f855a;
}

/* Review Step */
.review-section {
  background-color: #f9f9f9;
  border: 1px solid #eaeaea;
  border-radius: 6px;
  padding: 20px;
  margin-bottom: 20px;
}

.review-section h4 {
  margin: 0 0 15px 0;
  color: #2c5282;
  font-size: 18px;
  border-bottom: 1px solid #eaeaea;
  padding-bottom: 8px;
}

.review-content p {
  margin: 8px 0;
}

.review-content strong {
  font-weight: 600;
  color: #4a5568;
}

.review-content ul {
  margin: 8px 0;
  padding-left: 20px;
}

/* Checkbox styling */
.manuscript-form-group input[type='checkbox'] {
  margin-right: 10px;
}

.manuscript-form-group label[for^='original'],
.manuscript-form-group label[for^='ethical'],
.manuscript-form-group label[for^='conflict'],
.manuscript-form-group label[for^='publishing'],
.manuscript-form-group label[for^='data'] {
  font-weight: normal;
  display: flex;
  align-items: flex-start;
}

.manuscript-form-group label[for^='original'] input,
.manuscript-form-group label[for^='ethical'] input,
.manuscript-form-group label[for^='conflict'] input,
.manuscript-form-group label[for^='publishing'] input,
.manuscript-form-group label[for^='data'] input {
  margin-top: 3px;
}

/* Success Message */
.success-message {
  display: none;
  text-align: center;
  padding: 40px 30px;
}

.success-message i {
  font-size: 60px;
  color: #38a169;
  margin-bottom: 20px;
}

.success-message h3 {
  color: #38a169;
  margin: 0 0 15px 0;
  font-size: 24px;
}

.success-message p {
  font-size: 16px;
  color: #4a5568;
  margin-bottom: 20px;
  line-height: 1.6;
}

.submission-details {
  background-color: #f9f9f9;
  border: 1px solid #eaeaea;
  border-radius: 6px;
  padding: 15px;
  margin: 20px auto;
  max-width: 500px;
  text-align: left;
}

.success-buttons {
  margin-top: 30px;
  display: flex;
  justify-content: center;
  gap: 15px;
}

/* Loading Spinner */
.spinner {
  display: none;
  text-align: center;
  padding: 40px 30px;
}

.spinner i {
  font-size: 60px;
  color: #2c5282;
  animation: spin 2s linear infinite;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.spinner p {
  margin-top: 20px;
  font-size: 18px;
  color: #4a5568;
}

/* Word Count */
.word-count-exceeded {
  color: #e53e3e;
  font-weight: bold;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .manuscript-modal-content {
    width: 95%;
    margin: 10px auto;
  }

  .form-row {
    flex-direction: column;
    gap: 0;
  }

  .form-col {
    min-width: 100%;
  }

  .submission-steps {
    flex-wrap: wrap;
  }

  .step {
    flex-basis: 50%;
    margin-bottom: 15px;
  }

  .step-label {
    font-size: 12px;
  }

  .submit-manuscript-btn {
    bottom: 20px;
    right: 20px;
    padding: 10px 16px;
    font-size: 14px;
  }

  .form-nav {
    flex-direction: column;
    gap: 10px;
  }

  .btn-prev,
  .btn-next,
  .manuscript-form-submit {
    width: 100%;
    justify-content: center;
  }
}

/* Font Awesome icons (adding standard icons from a CDN) */
@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css');
