/* --- Layout --- */
.abstract-page {
  min-height: 100vh;
  padding-top: 120px;
  padding-bottom: 80px;
  background: linear-gradient(180deg, var(--ivory) 0%, var(--cream) 100%);
}

.abstract-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 24px;
}

/* --- Page Header --- */
.page-header {
  text-align: center;
  margin-bottom: 48px;
}

.header-ornament {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 24px;
}

.ornament-line {
  width: 60px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
}

.ornament-icon {
  color: var(--gold);
  font-size: 28px;
}

.page-title {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 6vw, 3.5rem);
  font-weight: 500;
  line-height: 1.1;
  color: var(--charcoal);
  margin-bottom: 16px;
}

.page-title span {
  font-style: italic;
  color: var(--ember);
}

.page-subtitle {
  font-family: var(--font-body);
  font-size: 16px;
  color: var(--muted);
}

/* --- Form Sections --- */
.form-section {
  margin-bottom: 40px;
}

.section-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--parchment);
}

.section-number {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 600;
  color: var(--ember);
  background: var(--cream);
  padding: 4px 12px;
  border-radius: 4px;
}

.section-title {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 500;
  color: var(--charcoal);
}

/* --- Form Card --- */
.form-card {
  background: var(--white);
  border: 1px solid var(--parchment);
  border-radius: 12px;
  padding: 32px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}

/* --- Form Groups --- */
.form-group {
  margin-bottom: 24px;
}

.form-group:last-child {
  margin-bottom: 0;
}

.form-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  color: var(--charcoal);
  margin-bottom: 8px;
}

.label-icon {
  font-size: 18px;
  color: var(--ember);
}

.label-badge {
  font-size: 11px;
  font-weight: 500;
  color: var(--muted);
  background: var(--cream);
  padding: 2px 8px;
  border-radius: 4px;
  margin-left: auto;
}

.form-input,
.form-textarea {
  width: 100%;
  padding: 14px 16px;
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--charcoal);
  background: var(--ivory);
  border: 1px solid var(--parchment);
  border-radius: 8px;
  transition: all 0.3s ease;
}

.form-input:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--ember);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(139, 26, 26, 0.08);
}

.form-input::placeholder,
.form-textarea::placeholder {
  color: var(--muted);
  opacity: 0.7;
}

.form-textarea {
  resize: vertical;
  min-height: 200px;
  line-height: 1.6;
}

.input-hint {
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--muted);
  margin-top: 6px;
}

/* --- Word Count --- */
.word-count {
  font-weight: 500;
  color: var(--ember);
}

.word-count.warning {
  color: #F59E0B;
}

.word-count.error {
  color: var(--ember);
}

/* --- Authors Section --- */
.authors-intro {
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--ink);
  margin-bottom: 24px;
  padding: 16px;
  background: var(--cream);
  border-radius: 8px;
  border-left: 3px solid var(--gold);
}

.authors-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.author-item {
  position: relative;
  background: var(--cream);
  border: 1px solid var(--parchment);
  border-radius: 10px;
  padding: 20px;
  padding-right: 48px;
  animation: slideIn 0.4s var(--ease-out-expo);
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideOut {
  from {
    opacity: 1;
    transform: translateY(0);
  }
  to {
    opacity: 0;
    transform: translateY(-10px);
  }
}

.author-item:first-child .author-remove {
  display: none;
}

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

.author-number {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 600;
  color: var(--ember);
}

.author-corresponding {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--muted);
  cursor: pointer;
}

.author-corresponding input {
  accent-color: var(--ember);
}

.author-remove {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid var(--parchment);
  border-radius: 6px;
  color: var(--muted);
  cursor: pointer;
  transition: all 0.2s ease;
}

.author-remove:hover {
  background: var(--ember);
  border-color: var(--ember);
  color: var(--white);
}

.author-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.author-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.author-field.full-width {
  grid-column: 1 / -1;
}

.author-field label {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 500;
  color: var(--muted);
}

.author-field input {
  padding: 10px 12px;
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--charcoal);
  background: var(--white);
  border: 1px solid var(--parchment);
  border-radius: 6px;
  transition: all 0.3s ease;
}

.author-field input:focus {
  outline: none;
  border-color: var(--ember);
  box-shadow: 0 0 0 3px rgba(139, 26, 26, 0.08);
}

/* --- Add Author Button --- */
.add-author-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 14px;
  margin-top: 16px;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  color: var(--ember);
  background: transparent;
  border: 2px dashed var(--ember);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.add-author-btn:hover {
  background: var(--ember);
  color: var(--white);
  border-style: solid;
}

.add-author-btn .material-symbols-outlined {
  font-size: 20px;
}

/* --- File Upload --- */
.file-upload {
  position: relative;
}

.file-upload input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.file-upload-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 32px;
  background: var(--cream);
  border: 2px dashed var(--parchment);
  border-radius: 10px;
  transition: all 0.3s ease;
}

.file-upload:hover .file-upload-content {
  border-color: var(--ember);
  background: var(--white);
}

.file-upload-icon {
  color: var(--muted);
}

.file-upload-icon .material-symbols-outlined {
  font-size: 40px;
}

.file-upload-text {
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--ink);
}

.file-upload-text span {
  color: var(--ember);
  font-weight: 500;
}

.file-upload-hint {
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--muted);
}

.file-name {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  color: var(--ember);
  margin-top: 8px;
}

/* --- Form Actions --- */
.form-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  padding: 32px;
  background: var(--cream);
  border-radius: 12px;
}

.actions-note {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--muted);
}

.actions-note .material-symbols-outlined {
  font-size: 18px;
}

.submit-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px 48px;
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  color: var(--white);
  background: var(--ember);
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.submit-btn:hover {
  background: var(--ember-deep);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(139, 26, 26, 0.25);
}

.submit-btn:active {
  transform: translateY(0);
}

.submit-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.submit-btn .material-symbols-outlined {
  font-size: 20px;
}

/* --- Responsive --- */

/* Tablet/Mobile below 1024px */
@media (max-width: 1023px) {
  .abstract-page {
    padding-top: 100px;
    padding-bottom: 60px;
  }

  .abstract-container {
    padding: 0 1.25rem;
  }

  .form-card {
    padding: 1.5rem;
  }

  .form-group {
    margin-bottom: 1.25rem;
  }

  .section-number {
    font-size: 12px;
    padding: 3px 10px;
  }

  .section-title {
    font-size: 1.35rem;
  }

  .authors-list {
    gap: 12px;
  }

  .author-item {
    padding: 16px;
    padding-right: 40px;
  }

  .author-fields {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .author-field input {
    padding: 8px 10px;
    font-size: 13px;
  }

  .form-textarea {
    min-height: 160px;
  }

  .form-actions {
    padding: 24px;
  }

  .submit-btn {
    padding: 14px 36px;
    font-size: 14px;
    width: 100%;
  }
}
  }

  .form-textarea {
    min-height: 160px;
  }

  .form-actions {
    padding: 24px;
  }

  .submit-btn {
    padding: 14px 36px;
    font-size: 14px;
  }
}

/* Mobile below 768px */
@media (max-width: 640px) {
  .abstract-container {
    padding: 0 16px;
  }

  .form-card {
    padding: 24px 20px;
  }

  .author-fields {
    grid-template-columns: 1fr;
  }

  .author-item {
    padding-right: 20px;
  }

  .author-remove {
    top: 12px;
    right: 12px;
  }

  .section-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .page-title {
    font-size: 2rem;
  }

  .submit-btn {
    width: 100%;
    padding: 16px 24px;
  }
}
