* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  background: #0a0a0a;
  color: #fff;
  overflow-x: hidden;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Animated Background */
.background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
/*    background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 50%, #16213e 100%);*/
    background-image: url("/Icons_Transcation/Icons/LoginImage.svg");
    background-size: cover; /* Optional: Scale the background image to cover the entire element */
    background-position: center; /* Optional: Center the background image */
    background-repeat: no-repeat; /* Optional: Prevent the image from repeating */
}

.car-animation {
  position: absolute;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.road {
  position: absolute;
  bottom: 20%;
  width: 200%;
  height: 4px;
  background: repeating-linear-gradient(
    90deg,
    #444 0,
    #444 50px,
    transparent 50px,
    transparent 100px
  );
  animation: road-move 2s linear infinite;
}

@keyframes road-move {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(-100px);
  }
}

.car-icon {
  position: absolute;
  bottom: 22%;
  left: -100px;
  font-size: 60px;
  color: #ff6b6b;
  animation: car-drive 15s linear infinite;
  filter: drop-shadow(0 0 20px rgba(255, 107, 107, 0.5));
}

@keyframes car-drive {
  0% {
    left: -100px;
  }

  100% {
    left: 110%;
  }
}

/* Floating particles */
.particle {
  position: absolute;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  animation: float 15s infinite ease-in-out;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }

  50% {
    transform: translateY(-100px) rotate(180deg);
  }
}

/* Login Container */
.login-container {
    position: relative;
    background: rgba(0, 0, 0, 0.59);
    backdrop-filter: blur(20px);
    border-radius: 30px;
    padding: 50px;
    width: 100%;
    max-width: 500px;
    box-shadow: 0 25px 45px rgba(0, 0, 0, 0.2), 0 0 100px rgba(255, 107, 107, 0.1), inset 0 0 30px rgba(255, 255, 255, 0.05) border: 1px solid rgba(255, 255, 255, 0.1);
    animation: container-entrance 0.8s ease-out;
}

@keyframes container-entrance {
  0% {
    opacity: 0;
    transform: translateY(50px) scale(0.9);
  }

  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Logo and Title */
.logo-section {
  text-align: center;
  margin-bottom: 40px;
}

.car-logo {
  font-size: 80px;
  color: #ff6b6b;
  margin-bottom: 20px;
  animation: logo-pulse 2s ease-in-out infinite;
  filter: drop-shadow(0 0 30px rgba(255, 107, 107, 0.6));
}

@keyframes logo-pulse {
  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.05);
  }
}

.title {
  font-size: 32px;
  font-weight: bold;
  background: linear-gradient(135deg, #ff6b6b, #ff8e53);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 10px;
}

.subtitle {
  font-size: 16px;
  color: rgba(255, 255, 255, 0.7);
}

/* Form Styles */
.form-group {
  position: relative;
  margin-bottom: 30px;
}

.form-input {
  width: 100%;
  padding: 15px 50px;
  background: rgba(255, 255, 255, 0.05);
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-radius: 15px;
  color: #fff;
  font-size: 16px;
  transition: all 0.3s ease;
  outline: none;
  text-align: right;
  direction: rtl;
}

/* LTR styles for form inputs */
html[dir="ltr"] .form-input,
body[dir="ltr"] .form-input {
  text-align: left;
  direction: ltr;
}

.form-input:focus {
  border-color: #ff6b6b;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 0 20px rgba(255, 107, 107, 0.3);
}

.form-icon {
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  color: rgba(255, 255, 255, 0.5);
  font-size: 20px;
  transition: all 0.3s ease;
}

/* LTR styles for form icons */
html[dir="ltr"] .form-icon,
body[dir="ltr"] .form-icon {
  right: auto;
  left: 20px;
}

.form-input:focus ~ .form-icon {
  color: #ff6b6b;
}

/* Animated placeholder */
.form-label {
  position: absolute;
  right: 50px;
  top: 50%;
  transform: translateY(-50%);
  color: rgba(255, 255, 255, 0.5);
  font-size: 16px;
  pointer-events: none;
  transition: all 0.3s ease;
}

.form-input:focus ~ .form-label,
.form-input:not(:placeholder-shown) ~ .form-label {
  top: -10px;
  right: 15px;
  font-size: 12px;
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
  padding: 0 10px;
  color: #ff6b6b;
}

/* Remember me checkbox */
.remember-section {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 30px;
}

.checkbox-wrapper {
  display: flex;
  align-items: center;
  gap: 10px;
}

html[dir="ltr"] .checkbox-wrapper,
body[dir="ltr"] .checkbox-wrapper {
  flex-direction: row-reverse;
}

.checkbox-input {
  display: none;
}

.checkbox-label {
  position: relative;
  padding-right: 35px;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.8);
  user-select: none;
}

.checkbox-custom {
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  background: rgba(255, 255, 255, 0.1);
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 5px;
  transition: all 0.3s ease;
}

.checkbox-input:checked ~ .checkbox-label .checkbox-custom {
  background: #ff6b6b;
  border-color: #ff6b6b;
}

.checkbox-custom::after {
  content: "✓";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0);
  color: #fff;
  font-size: 14px;
  transition: all 0.3s ease;
}

.checkbox-input:checked ~ .checkbox-label .checkbox-custom::after {
  transform: translate(-50%, -50%) scale(1);
}

.forgot-password {
  color: #ff6b6b;
  text-decoration: none;
  font-size: 14px;
  transition: all 0.3s ease;
}

.forgot-password:hover {
  color: #ff8e53;
  text-decoration: underline;
}

/* Submit Button */
.submit-btn {
  width: 100%;
  padding: 15px;
  background: linear-gradient(135deg, #ff6b6b, #ff8e53);
  border: none;
  border-radius: 15px;
  color: #fff;
  font-size: 18px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(255, 107, 107, 0.3);
}

.submit-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.3),
    transparent
  );
  transition: left 0.5s ease;
}

.submit-btn:hover::before {
  left: 100%;
}

.submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 15px 40px rgba(255, 107, 107, 0.4);
}

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

/* Loading animation */
.loading {
  display: none;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 30px;
  height: 30px;
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  0% {
    transform: translate(-50%, -50%) rotate(0deg);
  }

  100% {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

/* Demo Section */
.demo-section {
  margin-top: 40px;
  padding-top: 40px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.demo-title {
  text-align: center;
  font-size: 18px;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 20px;
}

.demo-buttons {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 15px;
}

.demo-btn {
  padding: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  color: #fff;
  text-decoration: none;
  text-align: center;
  transition: all 0.3s ease;
  font-size: 14px;
  position: relative;
  overflow: hidden;
}

.demo-btn::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(255, 107, 107, 0.3);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: all 0.5s ease;
}

.demo-btn:hover::before {
  width: 300px;
  height: 300px;
}

.demo-btn:hover {
  border-color: #ff6b6b;
  color: #ff6b6b;
  transform: translateY(-2px);
  z-index: 1;
}

.demo-btn span {
  position: relative;
  z-index: 1;
}

/* Responsive */
@media (max-width: 768px) {
  .login-container {
    padding: 30px;
    width: 95%;
  }

  .title {
    font-size: 24px;
  }

  .car-logo {
    font-size: 60px;
  }

  .demo-buttons {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Additional effects */
.glow {
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(
    circle,
    rgba(255, 107, 107, 0.1) 0%,
    transparent 70%
  );
  animation: glow-rotate 20s linear infinite;
  pointer-events: none;
}

@keyframes glow-rotate {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

/* Language Switcher */
.language-switcher {
  position: absolute;
  top: 20px;
  right: 20px;
  display: flex;
  gap: 10px;
  z-index: 1000;
}

html[dir="ltr"] .language-switcher,
body[dir="ltr"] .language-switcher {
  right: auto;
  left: 20px;
}

.lang-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  transition: all 0.3s ease;
  text-decoration: none;
  overflow: hidden;
}

.lang-btn:hover {
  background: rgba(255, 107, 107, 0.2);
  border-color: #ff6b6b;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(255, 107, 107, 0.3);
}

.lang-btn img {
  width: 24px;
  height: 24px;
  object-fit: cover;
}

.lang-btn.active {
  background: rgba(255, 107, 107, 0.3);
  border-color: #ff6b6b;
}
