/* ============================================================================
   Modern Login Page - APX Stream
   ============================================================================ */

/* ============================================================================
   BASE & CONTAINER
   ============================================================================ */

.login-page {
  margin: 0;
  padding: 0;
  overflow-x: hidden;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', sans-serif;
}

.login-container {
  display: flex;
  min-height: 100vh;
  opacity: 0;
  transform: scale(0.98);
  transition: all 0.4s ease;
}

  .login-container.loaded {
    opacity: 1;
    transform: scale(1);
  }

/* ============================================================================
   LEFT SIDE - CAROUSEL
   ============================================================================ */

.login-left {
  flex: 1;
  position: relative;
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
  overflow: hidden;
}

.carousel-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(2, 132, 199, 0.85) 0%, rgba(3, 105, 161, 0.9) 100%);
  z-index: 1;
}

.carousel.slide {
  height: 100vh;
}

.carousel-inner {
  height: 100%;
}

.carousel-item {
  height: 100vh;
  position: relative;
}

.carousel-bg-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.4);
  z-index: 0;
}

.carousel-content {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 4rem;
  color: white;
  max-width: 700px;
}

.carousel-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  border-radius: 9999px;
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 1.5rem;
  width: fit-content;
}

.carousel-content h2 {
  font-size: 2.5rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1rem;
  color: white;
}

.carousel-content p {
  font-size: 1.125rem;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 2rem;
}

.carousel-link {
  display: inline-flex;
  align-items: center;
  color: white;
  font-weight: 600;
  text-decoration: none;
  padding: 0.75rem 1.5rem;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  border-radius: 8px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  transition: all 0.2s ease;
  width: fit-content;
}

  .carousel-link:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateX(4px);
    color: white;
    text-decoration: none;
  }

/* Carousel Indicators */
.carousel-indicators {
  z-index: 3;
  bottom: 2rem;
}

  .carousel-indicators li {
    width: 40px;
    height: 4px;
    border-radius: 2px;
    background-color: rgba(255, 255, 255, 0.3);
    border: none;
    transition: all 0.3s ease;
  }

  .carousel-indicators .active {
    background-color: white;
    width: 60px;
  }

/* Carousel Controls */
.carousel-control-prev,
.carousel-control-next {
  width: 60px;
  height: 60px;
  top: 50%;
  transform: translateY(-50%);
  opacity: 0;
  transition: all 0.3s ease;
  z-index: 3;
}

.login-left:hover .carousel-control-prev,
.login-left:hover .carousel-control-next {
  opacity: 0.5;
}

.carousel-control-prev:hover,
.carousel-control-next:hover {
  opacity: 1 !important;
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
  width: 40px;
  height: 40px;
  background-color: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
  border-radius: 50%;
}

/* Carousel Branding */
.carousel-branding {
  position: absolute;
  top: 2rem;
  left: 2rem;
  z-index: 3;
}

.carousel-logo {
  height: 40px;
  width: auto;
  filter: brightness(0) invert(1);
}

/* ============================================================================
   RIGHT SIDE - LOGIN FORM
   ============================================================================ */

.login-right {
  flex: 0 0 500px;
  display: flex;
  flex-direction: column;
  background: white;
  position: relative;
}

.login-form-container {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem 2rem;
}

#loginContent {
  width: 100%;
  max-width: 400px;
}

/* Logo Mobile (Hidden on Desktop) */
.login-logo-mobile {
  display: none;
  text-align: center;
  margin-bottom: 2rem;
}

  .login-logo-mobile img {
    height: 50px;
    width: auto;
  }

/* ============================================================================
   FORM STYLING
   ============================================================================ */

.login-form-title {
  font-size: 1.875rem;
  font-weight: 700;
  color: #171717;
  margin-bottom: 0.5rem;
}

.login-form-subtitle {
  font-size: 1rem;
  color: #737373;
  margin-bottom: 2rem;
}

.form-group {
  margin-bottom: 1.5rem;
}

  .form-group label {
    display: block;
    font-weight: 600;
    color: #404040;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
  }

.form-control {
  width: 100%;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  border: 2px solid #e5e5e5;
  border-radius: 8px;
  transition: all 0.2s ease;
  background-color: #fafafa;
}

  .form-control:focus {
    outline: none;
    border-color: #0284c7;
    background-color: white;
    box-shadow: 0 0 0 4px rgba(2, 132, 199, 0.1);
  }

  .form-control.is-invalid {
    border-color: #ef4444;
    background-color: #fef2f2;
  }

  .form-control.is-valid {
    border-color: #10b981;
    background-color: #f0fdf4;
  }

/* Password Toggle */
.field-icon {
  position: absolute;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  cursor: pointer;
  color: #737373;
  z-index: 2;
  transition: color 0.2s ease;
}

  .field-icon:hover {
    color: #0284c7;
  }

.password-wrapper {
  position: relative;
}

/* Buttons */
.btn {
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  border-radius: 8px;
  border: none;
  transition: all 0.2s ease;
  font-size: 1rem;
}

.btn-primary {
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
  color: white;
  box-shadow: 0 2px 4px rgba(2, 132, 199, 0.2);
}

  .btn-primary:hover {
    background: linear-gradient(135deg, #0369a1 0%, #075985 100%);
    box-shadow: 0 4px 8px rgba(2, 132, 199, 0.3);
    transform: translateY(-1px);
  }

  .btn-primary:active {
    transform: translateY(0);
  }

.btn-secondary {
  background-color: #f5f5f5;
  color: #404040;
  border: 2px solid #e5e5e5;
}

  .btn-secondary:hover {
    background-color: #e5e5e5;
    color: #171717;
  }

.btn-block {
  width: 100%;
  display: block;
}

/* Links */
.login-link {
  color: #0284c7;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s ease;
}

  .login-link:hover {
    color: #0369a1;
    text-decoration: underline;
  }

.pointer {
  cursor: pointer;
  color: #0284c7;
  text-decoration: none;
  font-size: 0.875rem;
  transition: color 0.2s ease;
}

  .pointer:hover {
    color: #0369a1;
    text-decoration: underline;
  }

/* Divider */
.login-divider {
  display: flex;
  align-items: center;
  text-align: center;
  margin: 1.5rem 0;
  color: #737373;
  font-size: 0.875rem;
}

  .login-divider::before,
  .login-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid #e5e5e5;
  }

  .login-divider span {
    padding: 0 1rem;
  }

/* ============================================================================
   FOOTER
   ============================================================================ */

.login-footer {
  padding: 1.5rem 2rem;
  text-align: center;
  border-top: 1px solid #e5e5e5;
  background-color: #fafafa;
}

  .login-footer p {
    margin: 0;
    font-size: 0.875rem;
    color: #737373;
    margin-bottom: 0.5rem;
  }

.login-footer-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  font-size: 0.875rem;
}

  .login-footer-links a {
    color: #0284c7;
    text-decoration: none;
    transition: color 0.2s ease;
  }

    .login-footer-links a:hover {
      color: #0369a1;
      text-decoration: underline;
    }

  .login-footer-links span {
    color: #d4d4d4;
  }

/* ============================================================================
   LOADING SPINNER
   ============================================================================ */

#loading {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
}

.loading-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
}

.loading-spinner {
  position: relative;
  z-index: 2;
  background: white;
  padding: 2rem 3rem;
  border-radius: 12px;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
  text-align: center;
}

  .loading-spinner p {
    margin: 0;
    color: #737373;
    font-weight: 500;
  }

/* ============================================================================
   RESPONSIVE DESIGN
   ============================================================================ */

@media (max-width: 1024px) {
  .login-left {
    display: none;
  }

  .login-right {
    flex: 1;
  }

  .login-logo-mobile {
    display: block;
  }
}

@media (max-width: 640px) {
  .login-right {
    flex: 1;
  }

  .login-form-container {
    padding: 2rem 1.5rem;
  }

  .carousel-content {
    padding: 2rem;
  }

    .carousel-content h2 {
      font-size: 2rem;
    }

    .carousel-content p {
      font-size: 1rem;
    }

  .login-form-title {
    font-size: 1.5rem;
  }
}

/* ============================================================================
   ANIMATIONS
   ============================================================================ */

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

#loginContent > * {
  animation: fadeInUp 0.4s ease;
}

/* ============================================================================
   TOASTR CUSTOMIZATION
   ============================================================================ */

.toast {
  border-radius: 8px;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.toast-success {
  background-color: #10b981;
}

.toast-error {
  background-color: #ef4444;
}

.toast-info {
  background-color: #0284c7;
}

/* ============================================================================
   COMPATIBILITY STYLES - For existing _Login.cshtml partial
   ============================================================================ */

/* Center the form content */
#Data {
  width: 100%;
  max-width: 400px;
}

/* Logo styling */
.navbar-brand {
  display: block;
  text-align: center;
  margin-bottom: 2rem;
}

.logo {
  height: 60px;
  width: auto;
}

/* Form horizontal compatibility */
.form-horizontal {
  width: 100%;
}

/* Style the form labels */
.control-label {
  display: block;
  font-weight: 600;
  color: #404040;
  margin-bottom: 0.5rem;
  font-size: 0.875rem;
}

/* Ensure form controls are styled */
#Data .form-control {
  width: 100%;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  border: 2px solid #e5e5e5;
  border-radius: 8px;
  transition: all 0.2s ease;
  background-color: #fafafa;
}

  #Data .form-control:focus {
    outline: none;
    border-color: #0284c7;
    background-color: white;
    box-shadow: 0 0 0 4px rgba(2, 132, 199, 0.1);
  }

/* Password field wrapper */
#Data .d-block {
  position: relative;
}

/* Style buttons in the form */
#Data .btn {
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  border-radius: 8px;
  border: none;
  transition: all 0.2s ease;
  font-size: 1rem;
  margin-right: 0.5rem;
}

#Data .btn-primary {
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
  color: white;
  box-shadow: 0 2px 4px rgba(2, 132, 199, 0.2);
}

  #Data .btn-primary:hover {
    background: linear-gradient(135deg, #0369a1 0%, #075985 100%);
    box-shadow: 0 4px 8px rgba(2, 132, 199, 0.3);
    transform: translateY(-1px);
  }

#Data .btn-secondary {
  background-color: #f5f5f5;
  color: #404040;
  border: 2px solid #e5e5e5;
}

  #Data .btn-secondary:hover {
    background-color: #e5e5e5;
    color: #171717;
  }

/* Footer in form */
#Data .footer {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid #e5e5e5;
  text-align: center;
  font-size: 0.875rem;
  color: #737373;
}

/* Forgot password link */
#Data .pointer {
  display: block;
  margin-top: 1rem;
  color: #0284c7;
  cursor: pointer;
  font-size: 0.875rem;
  text-decoration: none;
}

  #Data .pointer:hover {
    color: #0369a1;
    text-decoration: underline;
  }

/* Validation messages */
#Data .text-danger {
  color: #ef4444;
  font-size: 0.875rem;
  margin-top: 0.25rem;
  display: block;
}

/* Border danger for validation */
#Data .border-danger {
  border-color: #ef4444 !important;
  background-color: #fef2f2 !important;
}

/* Form groups spacing */
#Data .form-group {
  margin-bottom: 1.5rem;
}

/* Add smooth fade-in animation */
#Data {
  animation: fadeInUp 0.4s ease;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}
/* ============================================================================
   LOGIN PAGE POLISH - Add this to login-modern.css
   ============================================================================ */

/* Fix the large logo */
#Data .logo {
  height: 50px !important;
  max-height: 50px;
  width: auto;
  object-fit: contain;
}

/* Better centering of login form */
.login-form-container {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 100px);
}

/* Add some top padding to the form */
#Data {
  padding-top: 2rem;
}

  /* Make the form inputs full width */
  #Data .d-block {
    width: 100%;
  }

  /* Better button spacing */
  #Data .form-group.mt-2 {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
  }

    #Data .form-group.mt-2 .btn {
      flex: 1;
      min-width: 120px;
    }

  /* Adjust footer position */
  #Data .footer {
    position: relative;
    bottom: auto;
  }

  /* Better password toggle position */
  #Data .field-icon {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: #737373;
    z-index: 2;
  }

  /* Add some breathing room */
  #Data .form-horizontal {
    padding: 0 0.5rem;
  }
/* ============================================================================
   MODERN LOADING SPINNER - Replace the old loading styles
   Add this to login-modern.css
   ============================================================================ */

/* Modern loading overlay */
#loading {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
}

/* Smooth backdrop with blur */
.loading-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  animation: fadeIn 0.2s ease;
}

/* Loading card */
.loading-spinner {
  position: relative;
  z-index: 2;
  background: white;
  padding: 2.5rem 3rem;
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  text-align: center;
  animation: scaleIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

  /* Modern spinner - Three dots pulse */
  .loading-spinner .spinner-border {
    display: none; /* Hide default Bootstrap spinner */
  }

  /* Create modern dot spinner */
  .loading-spinner::before {
    content: '';
    display: block;
    width: 60px;
    height: 60px;
    margin: 0 auto 1.5rem;
    border: 4px solid #e5e5e5;
    border-top-color: #0284c7;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
  }

  .loading-spinner p {
    margin: 0;
    color: #525252;
    font-weight: 500;
    font-size: 1rem;
  }

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Alternative: Three dot pulse spinner */
/* Uncomment this if you prefer dots over circle */
/*
.loading-spinner::before {
  content: '';
  display: inline-block;
  width: 12px;
  height: 12px;
  margin: 0 auto 1.5rem;
  background: #0284c7;
  border-radius: 50%;
  animation: dotPulse 1.4s infinite ease-in-out both;
}

.loading-spinner::after {
  content: '';
  display: inline-block;
  width: 12px;
  height: 12px;
  margin: 0 6px 1.5rem;
  background: #0284c7;
  border-radius: 50%;
  animation: dotPulse 1.4s infinite ease-in-out both;
  animation-delay: 0.16s;
}

@keyframes dotPulse {
  0%, 80%, 100% {
    transform: scale(0);
    opacity: 0.5;
  }
  40% {
    transform: scale(1);
    opacity: 1;
  }
}
*/
/* ============================================================================
   OPTION 1: HIDE CAROUSEL ARROWS COMPLETELY
   Add this to the END of login-modern.css
   ============================================================================ */

/* Just hide them - carousel will auto-play and users can use dots */
.carousel-control-prev,
.carousel-control-next {
  display: none !important;
}

/* Make the indicators (dots) more prominent since no arrows */
.carousel-indicators {
  bottom: 3rem;
}

  .carousel-indicators li {
    width: 50px;
    height: 4px;
    border-radius: 2px;
    background-color: rgba(255, 255, 255, 0.4);
    border: none;
    transition: all 0.3s ease;
    cursor: pointer;
  }

  .carousel-indicators .active {
    background-color: white;
    width: 70px;
  }

  .carousel-indicators li:hover {
    background-color: rgba(255, 255, 255, 0.6);
  }
