/* ===== Modern & Creative Auth Design ===== */

/* Main Container */
.containerlogin {
  max-width: 520px;
  width: 100%;
  background: #fff;
  margin: 80px auto;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(102, 126, 234, 0.15);
}

/* Sign In Section */
.sign-in {
  min-height: calc(100vh - 100px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
}

.signin-content {
  width: 100%;
}

/* Hide Image Section */
.signin-image {
  display: none !important;
}

/* Form Section - Full Width */
.signin-form,
.signup-form {
  padding: 60px 50px;
  background: #fff;
  position: relative;
}

/* Decorative Header */
.signin-form::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 5px;
  background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
}

.signin-form h2 {
  color: #2d3748;
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 10px;
  text-align: center;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.signin-form > p {
  color: #718096;
  text-align: center;
  margin-bottom: 35px;
  font-size: 15px;
}

/* Form Styles */
.register-form {
  margin-top: 35px;
}

.form-group {
  margin-bottom: 28px;
  position: relative;
}

/* Modern Input Design */
.form-control {
  width: 100%;
  height: 52px;
  border: 2px solid #e2e8f0;
  border-radius: 12px;
  padding: 15px 18px;
  font-size: 15px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  background: #f8fafc;
}

.form-control:hover {
  border-color: #cbd5e0;
  background: #fff;
}

.form-control:focus {
  outline: none;
  border-color: #667eea;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-control.is-invalid {
  border-color: #f56565;
  background: #fff5f5;
}

.form-control.is-invalid:focus {
  box-shadow: 0 0 0 3px rgba(245, 101, 101, 0.1);
}

/* Floating Labels - Modern */
.form-floating {
  position: relative;
}

.form-floating input {
  padding-top: 22px;
  padding-bottom: 10px;
}

.form-floating label {
  position: absolute;
  top: 16px;
  right: 18px;
  left: 18px;
  color: #a0aec0;
  font-size: 15px;
  font-weight: 500;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
  background: transparent;
}

.form-floating input:focus + label,
.form-floating input:not(:placeholder-shown) + label {
  top: 8px;
  font-size: 12px;
  color: #667eea;
  font-weight: 600;
}

/* Error Messages - Styled */
.invalid-feedback {
  display: block;
  color: #f56565;
  font-size: 13px;
  margin-top: 8px;
  padding-left: 6px;
  font-weight: 500;
}

/* Checkbox - Modern Design */
.agree-term {
  width: 20px;
  height: 20px;
  margin-right: 12px;
  cursor: pointer;
  accent-color: #667eea;
  vertical-align: middle;
}

.label-agree-term {
  display: flex;
  align-items: center;
  cursor: pointer;
  color: #4a5568;
  font-size: 14px;
  user-select: none;
  font-weight: 500;
}

.label-agree-term a {
  color: #667eea;
  text-decoration: none;
  margin-left: 4px;
  font-weight: 600;
}

.label-agree-term a:hover {
  color: #764ba2;
  text-decoration: underline;
}

/* Buttons - Modern & Gradient */
.btn {
  padding: 15px 40px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  letter-spacing: 0.3px;
}

.btn-primary {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: #fff;
  width: 100%;
  box-shadow: 0 10px 25px rgba(102, 126, 234, 0.3);
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 15px 35px rgba(102, 126, 234, 0.4);
}

.btn-primary:active {
  transform: translateY(-1px);
}

.btn-link {
  background: transparent;
  color: #667eea;
  padding: 10px 15px;
  text-decoration: none;
  width: auto;
  font-weight: 600;
}

.btn-link:hover {
  color: #764ba2;
  background: rgba(102, 126, 234, 0.05);
}

.form-button {
  text-align: center;
  margin-top: 30px;
}

/* Alerts - Modern Design */
.alert {
  border-radius: 12px;
  padding: 18px 22px;
  margin-bottom: 28px;
  border: none;
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 500;
}

.alert-success {
  background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
  color: #155724;
  border-left: 4px solid #28a745;
}

.alert-danger {
  background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%);
  color: #721c24;
  border-left: 4px solid #dc3545;
}

.alert-info {
  background: linear-gradient(135deg, #d1ecf1 0%, #bee5eb 100%);
  color: #0c5460;
  border-left: 4px solid #17a2b8;
}

/* Links */
a {
  color: #667eea;
  text-decoration: none;
  transition: color 0.2s ease;
  font-weight: 500;
}

a:hover {
  color: #764ba2;
}

/* Text Utilities */
.text-muted {
  color: #718096 !important;
  font-size: 14px;
}

.text-center {
  text-align: center;
}

/* Info Boxes - Creative */
.info-box,
div[style*="background-color: #f8f9fa"] {
  background: linear-gradient(135deg, #f7fafc 0%, #edf2f7 100%) !important;
  border-radius: 12px;
  padding: 20px 22px;
  border-left: 4px solid #667eea;
  margin-top: 28px;
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.08);
}

/* Icons - Better Sizing */
.bi {
  font-size: inherit;
  vertical-align: middle;
}

/* Social & Alternative Actions */
.social-login,
.alternative-actions {
  text-align: center;
  margin-top: 35px;
  padding-top: 35px;
  border-top: 2px solid #e2e8f0;
}

.social-login p,
.alternative-actions p {
  color: #718096;
  font-size: 14px;
  margin-bottom: 15px;
  font-weight: 500;
}

/* Select Dropdown */
select.form-control {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23667eea' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: left 18px center;
  background-size: 12px;
  padding-left: 45px;
  appearance: none;
  cursor: pointer;
}

[dir="rtl"] select.form-control {
  background-position: right 18px center;
  padding-left: 18px;
  padding-right: 45px;
}

/* Responsive Design */
@media (max-width: 767px) {
  .containerlogin {
    margin: 30px 15px;
    border-radius: 16px;
  }
  
  .sign-in {
    min-height: auto;
    padding: 20px 15px;
  }
  
  .signin-form,
  .signup-form {
    padding: 45px 30px;
  }
  
  .signin-form h2 {
    font-size: 28px;
  }
}

@media (max-width: 480px) {
  .signin-form,
  .signup-form {
    padding: 40px 25px;
  }
  
  .signin-form h2 {
    font-size: 26px;
  }
  
  .form-control {
    height: 50px;
    font-size: 14px;
  }
  
  .btn {
    padding: 14px 35px;
    font-size: 15px;
  }
  
  .form-group {
    margin-bottom: 24px;
  }
}

/* RTL Support */
[dir="rtl"] .form-floating label {
  right: 18px;
  left: 18px;
}

[dir="rtl"] .agree-term {
  margin-right: 0;
  margin-left: 12px;
}

[dir="rtl"] .info-box,
[dir="rtl"] div[style*="background-color: #f8f9fa"] {
  border-left: none;
  border-right: 4px solid #667eea;
}

/* Loading State */
.btn:disabled {
  opacity: 0.65;
  cursor: not-allowed;
  transform: none !important;
}

/* Focus Visible for Accessibility */
*:focus-visible {
  outline: 3px solid #667eea;
  outline-offset: 3px;
}

/* Signup Image Link - Enhanced */
.signup-image-link {
  display: inline-block;
  padding: 12px 30px;
  background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
  border-radius: 10px;
  color: #667eea;
  font-weight: 600;
  transition: all 0.3s ease;
  border: 2px solid transparent;
}

.signup-image-link:hover {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3);
}