@import url("https://fonts.googleapis.com/css2?family=Vazirmatn:wght@100..900&display=swap");

/* تنظیمات پایه صفحه */
body {
  background-color: #f2f7fe;
  color: #333;
  margin: 0;
  padding: 0;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  height: 100vh;
  direction: rtl;
}

* {
  font-family: Vazirmatn, "Arial", sans-serif;
  font-weight: bold;
}

h2 {
  font-size: 32px;
  color: #4a90e2;
  margin-top: 50px;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 2px;
  text-shadow: 1px 1px 5px rgba(0, 0, 0, 0.2);
}

/* ورودی نام کاربری */
input[type="text"],
input[type="file"] {
  padding: 15px;
  font-size: 18px;
  border: 2px solid #ddd;
  border-radius: 30px;
  width: 80%;
  max-width: 400px;
  margin-top: 20px;
  margin-bottom: 30px;
  background: #fff;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

input[type="text"]:focus,
input[type="file"]:focus {
  border-color: #2563eb;
  box-shadow: 0 0 15px rgba(37, 99, 235, 0.5);
}

/* دکمه */
button {
  padding: 12px 30px;
  font-size: 18px;
  background: linear-gradient(135deg, #2563eb, #4f8af1);
  color: white;
  border: none;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.3s ease-in-out;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

button:hover {
  background: linear-gradient(135deg, #1e40af, #4f8af1);
  transform: translateY(-3px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2);
}

/* نتیجه */
#result {
  font-size: 20px;
  font-weight: bold;
  margin-top: 30px;
  padding: 12px;
  border-radius: 8px;
  background: #f1f9fe;
  color: #333;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

#result.success {
  background: #d4f7d2;
  color: #2f7b3b;
}

#result.error {
  background: #f7d2d2;
  color: #e53e3e;
}

#output {
  direction: ltr !important;
  text-align: left;
  font-family: monospace;
  font-size: large;
}

/* لینک */
a {
  display: inline-block;
  margin-top: 30px;
  font-size: 18px;
  text-decoration: none;
  color: #2563eb;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: color 0.3s ease, transform 0.3s ease;
}

a:hover {
  color: #1e40af;
  transform: scale(1.1);
}

/* انیمیشن‌ها */
@keyframes fadeIn {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

/* اضافه کردن انیمیشن به متن‌ها */
h2,
input[type="text"],
input[type="file"],
button,
a {
  animation: fadeIn 1s ease-in-out;
}

/* برای دستگاه‌های کوچک‌تر */
@media (max-width: 600px) {
  h2 {
    font-size: 24px;
  }

  input[type="text"],
  input[type="file  "] {
    width: 90%;
  }

  button {
    width: 90%;
  }
}
