/* تنسيقات إضافية لصفحة تسجيل الدخول */

/* تنسيق الحاوية الرئيسية */
.login-container {
  background-image: url('/img/bg-pattern.svg'), linear-gradient(135deg, var(--primary-light), var(--primary-dark));
  background-size: cover;
  background-position: center;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0;
  position: relative;
  overflow: hidden;
  animation: gradientAnimation 15s ease infinite;
}

@keyframes gradientAnimation {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* شاشة السبلاش */
.splash-screen {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--primary-dark), var(--primary-color));
  z-index: 1000;
  /* تم إزالة التأثير الحركي للظهور والاختفاء */
}

/* حاوية مكون Loader في شاشة السبلاش */
.splash-loader-container {
  margin-top: 40px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.splash-logo {
  display: flex;
  justify-content: center;
  align-items: center;
  /* تم إزالة تأثير النبض */
}

.splash-logo-img {
  width: 300px;
  height: auto;
  /* تعديل لجعل الشعار أبيض بالكامل */
  filter: brightness(0) invert(1);
  -webkit-filter: brightness(0) invert(1);
}

/* تم تعديل تأثيرات الحركة لتكون ثابتة */
@keyframes fadeIn {
  from { opacity: 1; }
  to { opacity: 1; }
}

@keyframes fadeInScale {
  from { 
    opacity: 1; 
    transform: scale(1);
  }
  to { 
    opacity: 1; 
    transform: scale(1);
  }
}

@keyframes pulse {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1);
  }
  100% {
    transform: scale(1);
  }
}

/* تنسيق صندوق تسجيل الدخول */
.login-box {
  background-color: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 20px;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
  padding: 30px;
  width: 100%;
  max-width: 400px;
  max-height: 90vh;
  text-align: center;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.2);
  transform: translateY(0);
  transition: transform 0.5s ease, box-shadow 0.5s ease;
  animation: fadeIn 0.8s ease-out forwards;
}

.login-box:hover {
  
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

@keyframes fadeIn {
  from { opacity: 0;  }
  to { opacity: 1; transform: translateY(0); }
}

/* تنسيق الشعار */
.login-box .logo {
  margin-bottom: 15px;
  position: relative;
}

.login-box .logo::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background: linear-gradient(to right, var(--primary-light), var(--primary-dark), var(--primary-light));
  border-radius: 3px;
}

.login-box .logo img {
  margin-bottom: 20px;
  transition: all 0.5s ease;
  filter: drop-shadow(0 8px 20px rgba(142, 68, 173, 0.5));
  /* تم إزالة الحركة لجعل الأيقونة ثابتة */
  transform: scale(1.1);
}

.login-box .logo img:hover {
  transform: scale(1.05);
  filter: drop-shadow(0 8px 20px rgba(142, 68, 173, 0.5));
}

.login-logo {
  width: 320px;
  height: auto;
  max-height: 200px;
  object-fit: contain;
  filter: drop-shadow(0 10px 25px rgba(142, 68, 173, 0.7));
  transform: scale(1.05);
}

.login-box .logo h2 {
  color: var(--primary-color);
  font-weight: 700;
  font-size: 32px;
  margin-bottom: 8px;
  text-shadow: 0 3px 5px rgba(0, 0, 0, 0.15);
  background: linear-gradient(to right, var(--primary-color), var(--primary-dark));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: 0.5px;
}

/* تنسيق نص الترحيب */
.welcome-text {
  color: var(--text-light);
  margin-bottom: 20px;
  font-size: 16px;
  position: relative;
  padding-bottom: 5px;
  font-weight: 500;
  animation: fadeInUp 0.8s ease-out forwards;
  animation-delay: 0.2s;
  opacity: 0;
}

@keyframes fadeInUp {
  from { opacity: 0;  }
  to { opacity: 1; transform: translateY(0); }
}

/* تنسيق حقول الإدخال مع الأيقونات */
.input-with-icon {
  position: relative;
  margin-bottom: 15px;
  animation: fadeInUp 0.8s ease-out forwards;
  animation-delay: 0.3s;
  opacity: 0;
}

.form-group {
  margin-bottom: 15px;
  text-align: right;
}

.form-group label {
  display: block;
  margin-bottom: 5px;
  font-weight: 600;
  color: var(--text-dark);
  font-size: 14px;
  transition: all 0.3s ease;
  text-align: right;
}

.input-with-icon i {
  position: absolute;
  right: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--primary-color);
  font-size: 18px;
  transition: all 0.3s ease;
  opacity: 0.7;
}

.input-with-icon:hover i {
  opacity: 1;
  transform: translateY(-50%) scale(1.1);
}

.input-with-icon input {
  width: 100%;
  padding: 10px 40px 10px 15px;
  border: 2px solid rgba(142, 68, 173, 0.2);
  border-radius: 10px;
  font-size: 14px;
  transition: all 0.3s ease;
  background-color: rgba(255, 255, 255, 0.8);
}

.input-with-icon input:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 15px rgba(142, 68, 173, 0.3);
  background-color: rgba(255, 255, 255, 1);
  outline: none;
}

.input-with-icon input::placeholder {
  color: #aaa;
  transition: all 0.3s ease;
}

.input-with-icon input:focus::placeholder {
  opacity: 0.5;
  transform: translateX(-5px);
}

/* تنسيق خيارات النموذج */
.form-options {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  margin: 10px 0 15px;
  font-size: 14px;
  animation: fadeInUp 0.8s ease-out forwards;
  animation-delay: 0.4s;
  opacity: 0;
}

.remember-me {
  display: flex;
  align-items: center;
}

.remember-me input[type="checkbox"] {
  position: relative;
  margin-left: 8px;
  width: 18px;
  height: 18px;
  -webkit-appearance: none;
  appearance: none;
  border: 2px solid var(--primary-color);
  border-radius: 4px;
  outline: none;
  transition: all 0.3s ease;
  cursor: pointer;
}

.remember-me input[type="checkbox"]:checked {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
}

.remember-me input[type="checkbox"]:checked::before {
  content: '✓';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  font-size: 12px;
}

.remember-me label {
  cursor: pointer;
  user-select: none;
  font-weight: 500;
}

/* تم إزالة تنسيقات زر نسيت كلمة المرور */

/* إضافة نص حقوق الملكية */
.copyright-text {
  position: absolute;
  bottom: 15px;
  left: 20px;
  color: white;
  font-size: 16px;
  font-weight: 500;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
  z-index: 10;
  animation: fadeInUp 0.8s ease-out forwards;
  animation-delay: 1.2s;
  opacity: 0;
  background-color: rgba(0, 0, 0, 0.2);
  padding: 8px 15px;
  border-radius: 10px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

@media (max-width: 480px) {
  .copyright-text {
    font-size: 12px;
    padding: 6px 10px;
    left: 10px;
    bottom: 10px;
  }
}

/* تنسيق زر تسجيل الدخول */
.btn-primary.btn-block {
  background: linear-gradient(45deg, var(--primary-color), var(--primary-dark));
  border: none;
  padding: 12px;
  font-size: 16px;
  font-weight: 600;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: 10px;
  position: relative;
  overflow: hidden;
  z-index: 1;
  letter-spacing: 1px;
  animation: fadeInUp 0.8s ease-out forwards;
  animation-delay: 0.5s;
  opacity: 0;
}

.btn-primary.btn-block::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(45deg, var(--primary-dark), var(--primary-color));
  z-index: -1;
  transition: opacity 0.5s ease;
  opacity: 0;
}

.btn-primary.btn-block:hover {
  
  box-shadow: 0 7px 20px rgba(142, 68, 173, 0.4);
}

.btn-primary.btn-block:hover::before {
  opacity: 1;
}

.btn-primary.btn-block:active {
  
  box-shadow: 0 3px 10px rgba(142, 68, 173, 0.3);
}

.btn-primary.btn-block:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* تنسيق رسالة الخطأ */
.alert-danger {
  background-color: rgba(231, 76, 60, 0.1);
  border-right: 4px solid #e74c3c;
  color: #e74c3c;
  padding: 12px 15px 12px 12px;
  border-radius: 8px;
  margin-bottom: 20px;
  font-size: 14px;
  text-align: right;
  position: relative;
  animation: shake 0.5s ease-in-out;
  display: flex;
  align-items: center;
  box-shadow: 0 3px 10px rgba(231, 76, 60, 0.1);
}

.alert-danger::before {
  content: '\f071';
  font-family: 'Font Awesome 5 Free';
  font-weight: 900;
  margin-left: 10px;
  font-size: 16px;
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
  20%, 40%, 60%, 80% { transform: translateX(5px); }
}

/* تأثيرات إضافية */
.login-box::before {
  content: '';
  position: absolute;
  top: -80px;
  left: -80px;
  width: 150px;
  height: 150px;
  background: linear-gradient(135deg, var(--primary-light), var(--primary-color));
  border-radius: 50%;
  z-index: 0;
  opacity: 0.1;
  animation: pulse 8s infinite alternate;
}

.login-box::after {
  content: '';
  position: absolute;
  bottom: -80px;
  right: -80px;
  width: 150px;
  height: 150px;
  background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
  border-radius: 50%;
  z-index: 0;
  opacity: 0.1;
  animation: pulse 8s infinite alternate-reverse;
}

/* عناصر زخرفية إضافية */
.login-container::before {
  content: '';
  position: absolute;
  top: 20%;
  left: 15%;
  width: 100px;
  height: 100px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  animation: float 10s infinite linear;
}

.login-container::after {
  content: '';
  position: absolute;
  bottom: 15%;
  right: 10%;
  width: 150px;
  height: 150px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
  animation: morph 15s infinite alternate;
}

@keyframes pulse {
  0% { transform: scale(1); opacity: 0.1; }
  50% { transform: scale(1.1); opacity: 0.15; }
  100% { transform: scale(1); opacity: 0.1; }
}

@keyframes morph {
  0% { border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%; }
  25% { border-radius: 58% 42% 75% 25% / 76% 46% 54% 24%; }
  50% { border-radius: 50% 50% 33% 67% / 55% 27% 73% 45%; }
  75% { border-radius: 33% 67% 58% 42% / 63% 68% 32% 37%; }
  100% { border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%; }
}

/* تحسينات للأجهزة المحمولة */
@media (max-width: 480px) {
  .login-box {
    padding: 20px 15px;
    margin: 0 10px;
    max-height: 85vh;
  }
  
  .form-options {
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
  }
  
  .login-box .logo img {
    width: 120px;
    height: 120px;
  }
  
  .login-box .logo h2 {
    font-size: 26px;
  }
  
  .welcome-text {
    font-size: 16px;
  }
  
  .input-with-icon input {
    padding: 12px 40px 12px 12px;
    font-size: 15px;
  }
  
  .login-container::before,
  .login-container::after {
    display: none;
  }
  
  .footer-credit {
    font-size: 12px;
    padding: 6px 10px;
    right: 10px;
    bottom: 10px;
  }
  
  .footer-credit img {
    height: 50px;
  }
}

/* تذييل الصفحة - حقوق الملكية */
.footer-credit {
  position: absolute;
  bottom: 10px;
  right: 15px;
  text-align: right;
  color: white;
  font-size: 14px;
  opacity: 0.95;
  font-weight: 600;
  text-shadow: 0 2px 3px rgba(0, 0, 0, 0.4);
  z-index: 10;
  animation: fadeInUp 0.8s ease-out forwards;
  animation-delay: 1s;
  opacity: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  background-color: rgba(0, 0, 0, 0.2);
  padding: 5px 10px;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.footer-credit img {
  height: 40px;
  width: auto;
  vertical-align: middle;
  margin-right: 5px;
  margin-left: 5px;
  filter: brightness(0) invert(1) drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3)); /* تحويل الشعار للون الأبيض مع إضافة ظل */
  transition: transform 0.3s ease;
}

.footer-credit:hover {
  opacity: 1;
}

.footer-credit:hover img {
  transform: scale(1.1);
}