* {
  box-sizing: border-box;
}

:root {
  --maroon-900: #4a0d22;
  --maroon-800: #61122c;
  --maroon-700: #7b1e3a;
  --maroon-600: #95254a;
  --maroon-100: #fdecef;
  --maroon-50: #fff7f9;
  --ink: #1f1a1c;
}

body {
  margin: 0;
  font-family: Tahoma, "IRANSans", sans-serif;
  background:
    radial-gradient(circle at top right, #f9d8e1 0, transparent 35%),
    radial-gradient(circle at bottom left, #fbe9ee 0, transparent 40%),
    #f8f3f5;
  color: var(--ink);
}

.page-wrap {
  min-height: 100vh;
  padding: 24px;
}

.card {
  max-width: 1050px;
  margin: 0 auto;
  background: #fff;
  border: 1px solid #f2d7df;
  border-radius: 24px;
  padding: 24px;
  box-shadow: 0 20px 60px rgba(97, 18, 44, 0.13);
}

.head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  border-bottom: 1px solid #f2d7df;
  padding-bottom: 20px;
  margin-bottom: 20px;
}

.head h1 {
  margin: 0;
  font-size: clamp(21px, 2.8vw, 30px);
  line-height: 1.9;
  color: var(--maroon-800);
  font-weight: 800;
}

.logo-box {
  min-width: 170px;
  height: 90px;
  border: 2px dashed var(--maroon-600);
  color: var(--maroon-700);
  display: grid;
  place-items: center;
  border-radius: 16px;
  background: var(--maroon-50);
  font-weight: 800;
  text-align: center;
  padding: 6px;
}

.intro-text {
  background: linear-gradient(180deg, #fff, #fffafb);
  border: 1px solid #f4dbe3;
  border-radius: 16px;
  padding: 16px;
  line-height: 2;
  margin-bottom: 16px;
}

.notice {
  border: 1px solid #f4c8d6;
  background: linear-gradient(90deg, #fff5f8, #fff);
  border-radius: 14px;
  padding: 12px 14px;
  margin-bottom: 16px;
  font-weight: 700;
  line-height: 1.9;
  color: var(--maroon-800);
}

.messages {
  margin-bottom: 14px;
}

.message {
  padding: 10px 12px;
  border-radius: 10px;
  margin-bottom: 8px;
  font-weight: 700;
}

.message.success {
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  color: #065f46;
}

.message.error {
  background: #fff1f2;
  border: 1px solid #fecdd3;
  color: #9f1239;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

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

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

label {
  font-weight: 800;
  font-size: 14px;
  color: var(--maroon-800);
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid #e9c7d3;
  border-radius: 12px;
  padding: 11px 12px;
  font-size: 14px;
  background: #fff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--maroon-600);
  box-shadow: 0 0 0 4px rgba(149, 37, 74, 0.12);
  outline: none;
}

ul.errorlist {
  margin: 0;
  padding: 0;
  list-style: none;
  color: #b91c1c;
  font-size: 12px;
  font-weight: 700;
}

.submit-btn {
  grid-column: 1 / -1;
  border: none;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--maroon-700), var(--maroon-600));
  color: white;
  font-size: 16px;
  font-weight: 800;
  padding: 12px;
  cursor: pointer;
  transition: transform 0.15s ease, opacity 0.2s ease, filter 0.2s ease;
}

.submit-btn:hover {
  filter: brightness(1.03);
  transform: translateY(-1px);
}

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

.help-box {
  margin-top: 18px;
  background: #fff7f9;
  border: 1px solid #f4c8d6;
  border-radius: 14px;
  padding: 12px;
  line-height: 2;
  font-weight: 700;
}

.help-box a {
  color: var(--maroon-700);
  text-decoration-thickness: 2px;
}

.file-hint {
  margin: 6px 0 0;
  color: #475569;
  font-size: 12px;
  font-weight: 700;
}

.upload-progress {
  margin-top: 4px;
}

.progress-track {
  width: 100%;
  height: 10px;
  border-radius: 999px;
  background: #f2d7df;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  width: 0%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--maroon-600), #bb3f66);
  transition: width 0.25s ease;
}

.progress-text {
  margin: 8px 0 0;
  font-size: 13px;
  font-weight: 700;
  color: var(--maroon-700);
}

@media (max-width: 900px) {
  .head {
    flex-direction: column;
    align-items: flex-start;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }
}