/*--------------------------------------------------------------
# Modern Split-Screen Login Page
--------------------------------------------------------------*/

/* Reset and Base Styles */
.login-main {
  margin: 0;
  padding: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f6f9ff;
  font-family: "Inter", sans-serif;
}

.login-container {
  display: flex;
  width: 100%;
  max-width: 1200px;
  min-height: 600px;
  background: #ffffff;
  border-radius: 20px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
  overflow: hidden;
  margin: 20px;
}

/*--------------------------------------------------------------
# Left Panel - Branded Side
--------------------------------------------------------------*/
.login-left-panel {
  flex: 1;
  background: linear-gradient(135deg, #d3131d 0%, #a80a17 100%);
  padding: 60px 50px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: #ffffff;
  position: relative;
  overflow: hidden;
}

/* Decorative wave effect */
.login-left-panel::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 500px;
  height: 500px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
}

.login-left-panel::after {
  content: '';
  position: absolute;
  bottom: -30%;
  left: -10%;
  width: 400px;
  height: 400px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 50%;
}

.login-branding {
  position: relative;
  z-index: 2;
}

.brand-logo {
  display: flex;
  align-items: center;
  margin-bottom: 40px;
}

.brand-logo img {
  height: 100px;
  width: auto;
  margin-right: 15px;
  background: #ffffff;
  padding: 8px;
  border-radius: 10px;
}

.brand-logo h2 {
  font-size: 28px;
  font-weight: 700;
  margin: 0;
  color: #ffffff;
  font-family: "Inter", sans-serif;
}

.login-branding h3 {
  font-size: 18px;
  font-weight: 400;
  margin-bottom: 10px;
  opacity: 0.9;
}

.login-branding h1 {
  font-size: 42px;
  font-weight: 700;
  margin-bottom: 20px;
  line-height: 1.2;
}

.login-branding p {
  font-size: 16px;
  line-height: 1.6;
  opacity: 0.9;
  max-width: 400px;
}

.login-footer-links {
  position: relative;
  z-index: 2;
  font-size: 14px;
  font-family: "Inter", sans-serif;
}

.login-footer-links a {
  color: #ffffff;
  text-decoration: none;
  opacity: 0.8;
  transition: opacity 0.3s ease;
}

.login-footer-links a:hover {
  opacity: 1;
}

.login-footer-links span {
  margin: 0 10px;
  opacity: 0.6;
}

/*--------------------------------------------------------------
# Right Panel - Login Form
--------------------------------------------------------------*/
.login-right-panel {
  flex: 1;
  padding: 60px 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
}

.login-form-container {
  width: 100%;
  max-width: 400px;
}

.login-form-header {
  margin-bottom: 20px;
}

.login-form-header h2 {
  font-size: 1.4rem;
  font-weight: 700;
  color: #111112;
  margin-bottom: 5px;
}

.login-form-header p {
  font-size: 14px;
  color: #4b5563;
  margin: 0;
}

/* Form Styles */
.login-form .form-group {
  margin-bottom: 10px;
}

.login-form label {
  display: block;
  font-size: 14px;
  font-weight: 500;
  color: #111112;
  margin-bottom: 2px;
}

.login-form .form-control {
  width: 100%;
  padding: 14px 16px;
  font-size: 16px;
  border: 1px solid #dddfe2;
  border-radius: 12px;
  transition: all 0.3s ease;
  font-family: "Inter", sans-serif;
}

.login-form .form-control:focus {
  outline: none;
  border-color: #111112;
  box-shadow: none;
}

.login-form .form-control::placeholder {
  color: rgba(0, 0, 0, 0.65);
}

/* Password Input Wrapper */
.password-input-wrapper {
  position: relative;
}

.password-toggle {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  cursor: pointer;
  color: #6c757d;
  font-size: 18px;
  transition: color 0.3s ease;
}

.password-toggle:hover {
  color: #d3131d;
}

/* Form Options */
.form-options {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.remember-me {
  display: flex;
  align-items: center;
}

.remember-me input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin-right: 8px;
  cursor: pointer;
  accent-color: #d3131d;
}

.remember-me label {
  font-size: 14px;
  font-weight: 400;
  color: #495057;
  margin: 0;
  cursor: pointer;
  font-family: "Inter", sans-serif;
}

.forgot-password {
  font-size: 14px;
  color: #d3131d;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease;
  font-family: "Inter", sans-serif;
}

.forgot-password:hover {
  color: #a80a17;
}

/* Sign In Button */
.btn-signin {
  width: 100%;
  margin-top: 5px;
  padding: 14px;
  font-size: 14px;
  font-weight: 500;
  color: #ffffff;
  background: #d3131d;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-signin:hover {
  background: #a80a17;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(211, 19, 29, 0.3);
}

.btn-signin:active {
  transform: translateY(0);
}

/* Signup Prompt */
.signup-prompt {
  text-align: center;
  margin-top: 30px;
}

.signup-prompt p {
  font-size: 14px;
  color: #6c757d;
  margin: 0;
  font-family: "Inter", sans-serif;
}

.signup-prompt a {
  color: #d3131d;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.3s ease;
  font-family: "Inter", sans-serif;
}

.signup-prompt a:hover {
  color: #a80a17;
}

/*--------------------------------------------------------------
# Responsive Design
--------------------------------------------------------------*/

/* Large Desktop (1200px+) */
@media (min-width: 1200px) {
  .login-container {
    max-width: 1100px;
  }
}

/* Tablet and below (991px and down) */
@media (max-width: 991px) {
  .login-container {
    flex-direction: column;
    max-width: 600px;
    margin: 20px;
  }
  
  .login-left-panel {
    padding: 40px 30px;
    min-height: 300px;
  }
  
  .brand-logo img {
    height: 80px;
  }
  
  .brand-logo h2 {
    font-size: 24px;
  }
  
  .login-branding h1 {
    font-size: 32px;
  }
  
  .login-branding p {
    font-size: 14px;
  }
  
  .login-right-panel {
    padding: 40px 30px;
  }
  
  .login-form-header h2 {
    font-size: 1.4rem;
  }
}

/* Mobile (576px and down) */
@media (max-width: 576px) {
  .login-container {
    margin: 10px;
    border-radius: 15px;
    min-height: auto;
  }
  
  /* Completely hide the left panel on mobile */
  .login-left-panel {
    display: none;
  }
  
  /* Make the login form take full width */
  .login-right-panel {
    padding: 30px 20px;
    width: 100%;
  }
  
  .login-form-header {
    margin-bottom: 20px;
  }
  
  .login-form-header h2 {
    font-size: 1.4rem;
  }
  
  .form-options {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
}

/* Extra Small Mobile (375px and down) */
@media (max-width: 375px) {
  .login-right-panel {
    padding: 25px 15px;
  }
  
  .login-form .form-control {
    padding: 10px 14px;
    font-size: 14px;
  }
  
  .btn-signin {
    padding: 12px;
    font-size: 14px;
  }
}

/*--------------------------------------------------------------
# Google-style Error State
--------------------------------------------------------------*/
.form-group {
    position: relative;
}

.form-group.has-error label {
    color: #d93025 !important;
}

.form-group.has-error .form-control {
    border-color: #d93025 !important;
    padding-right: 40px; /* Space for exclamation icon */
}

.form-group.has-error .form-control:focus {
    border-color: #111112 !important;
    box-shadow: none !important;
}

.error-message {
    color: #d93025;
    font-size: 11.5px;
    margin-top: 5px;
    font-weight: 500;
    display: none;
    align-items: center;
    gap: 4px;
}

.form-group.has-error .error-message {
    display: flex;
}

.error-icon {
    font-size: 14px;
    color: #d93025;
    display: inline-block;
    vertical-align: middle;
}

/* Adjust for password field where eye toggle is present */
.password-input-wrapper .error-icon {
    right: 45px; 
}

/* Landscape Mobile */
@media (max-height: 600px) and (orientation: landscape) {
  .login-container {
    flex-direction: row;
    margin: 10px;
  }
  
  .login-left-panel {
    min-height: auto;
    padding: 30px 25px;
  }
  
  .login-branding h1 {
    font-size: 28px;
  }
  
  .login-branding p {
    display: none;
  }
  
  .login-right-panel {
    padding: 30px 25px;
  }
  
  .login-form-header {
    margin-bottom: 20px;
  }
  
  .login-form .form-group {
    margin-bottom: 16px;
  }
}
