/* ===== ProjexHub - Authentication Pages Styles ===== */

.auth-body {
  font-family: "Tajawal", sans-serif;
  background: var(--bg-primary);
  min-height: 100vh;
  margin: 0;
  padding: 0;
}

.auth-container {
  display: flex;
  min-height: 100vh;
  max-width: 1400px;
  margin: 0 auto;
  background: var(--bg-primary);
}

/* Visual Section */
.auth-visual {
  flex: 1;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: white;
  padding: 3rem;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.auth-visual::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Ccircle cx='30' cy='30' r='2'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E")
    repeat;
}

.visual-content {
  position: relative;
  z-index: 2;
  width: 100%;
}

.logo-section {
  margin-bottom: 3rem;
}

.auth-logo {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 2rem;
  font-weight: var(--font-black);
  margin-bottom: 2rem;
}

.auth-logo i {
  font-size: 2.5rem;
  color: white;
}

.logo-section h1 {
  font-size: 2.5rem;
  font-weight: var(--font-black);
  margin-bottom: 1rem;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  color: white;
}

.logo-section p {
  font-size: 1.2rem;
  opacity: 0.9;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.9);
}

/* إعادة تصميم المربعات الإحصائية لتظهر بشكل عمودي منفصل */
.visual-stats {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 3rem;
  margin-right: 10rem;
  max-width: 300px;
  justify-content: flex-start;
}

.stat-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  background: rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-xl);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: all var(--transition-fast);
}

.stat-item:hover {
  background: rgba(255, 255, 255, 0.15);
  transform: translateX(-5px);
}

.stat-icon {
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  flex-shrink: 0;
}

.stat-icon i {
  font-size: 1.2rem;
}

.stat-content {
  flex: 1;
}

.stat-number {
  font-size: 1.5rem;
  font-weight: var(--font-black);
  color: white;
  margin-bottom: 0.25rem;
  line-height: 1;
}

.stat-label {
  font-size: 0.85rem;
  opacity: 0.8;
  color: rgba(255, 255, 255, 0.8);
  line-height: 1;
}

/* Benefits List */
.benefits-list {
  margin-bottom: 3rem;
  justify-content: flex-start;
}

.benefit-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
  margin-right: 10rem;
  padding: 0.75rem;
  background: rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-xl);
  backdrop-filter: blur(10px);
  width: 300px;
}

.benefit-item i {
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
}

/* تحسين البطاقات العائمة لتظهر بعيداً عن المربعات الإحصائية */
.visual-decoration {
  position: absolute;
  top: 40%;
  right: -1px;
  pointer-events: none;
}

.floating-card {
  position: absolute;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-xl);
  padding: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  animation: float 6s ease-in-out infinite;
  color: white;
  width: 100px;
}

.floating-card:nth-child(1) {
  top: 0px;
  right: 0px;
  animation-delay: 0s;
}

.floating-card:nth-child(2) {
  top: 100px;
  right: -20px;
  animation-delay: 2s;
}

.floating-card:nth-child(3) {
  top: 190px;
  right: 0px;
  animation-delay: 4s;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-20px);
  }
}

/* Form Section */
.auth-form-section {
  flex: 1;
  padding: 3rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
  background: var(--bg-primary);
}

.form-container {
  max-width: 500px;
  margin: 0 auto;
  width: 100%;
}

.form-header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.form-header h2 {
  font-size: 2rem;
  font-weight: var(--font-black);
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

.form-header p {
  color: var(--text-secondary);
  font-size: 1rem;
}

/* Form Styles */
.auth-form {
  width: 100%;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  font-weight: var(--font-semibold);
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
}

.input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.input-wrapper i {
  position: absolute;
  right: 1rem;
  color: var(--text-muted);
  z-index: 2;
}

.input-wrapper input,
.input-wrapper select {
  width: 100%;
  padding: 1rem 3.5rem 1rem 1rem; /* Adjusted padding for RTL */
  border: 2px solid var(--border-light);
  border-radius: var(--radius-xl);
  font-size: 1rem;
  transition: all var(--transition-fast);
  background: var(--bg-secondary);
  color: var(--text-primary);
}
#university,
#major,
#graduation-year {
  padding-right: 3.5rem; /* Adjusted padding for RTL */
  width: 500px;
}

.input-wrapper input::placeholder {
  color: var(--text-muted);
}

.input-wrapper input:focus,
.input-wrapper select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.1);
  background: var(--bg-secondary);
}

.input-wrapper input:focus + i,
.input-wrapper select:focus + i {
  color: var(--primary);
}

.input-wrapper select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
  background-position: left 1rem center;
  background-repeat: no-repeat;
  background-size: 1.5em 1.5em;
  padding-left: 3rem;
}

/* Dark theme select arrow */
.dark-theme .input-wrapper select {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%23ffffff' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
}

/* Password Toggle - Centered vertically and placed on the LEFT (RTL: end side) */
.password-toggle {
position: absolute;
  left: 1rem; /* Changed from right to left for RTL */
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0.5rem;
  z-index: 3;
  transition: color var(--transition-fast);
  font-size: 1.2rem;
}

.password-toggle:hover {
  color: var(--primary);
}

/* Password Strength */
.password-strength {
  margin-top: 0.5rem;
}

.strength-bar {
  width: 100%;
  height: 4px;
  background: var(--border-light);
  border-radius: 2px;
  overflow: hidden;
  margin-bottom: 0.25rem;
}

.strength-fill {
  height: 100%;
  width: 0%;
  transition: all var(--transition-fast);
  border-radius: 2px;
}

.strength-text {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Form Options */
.form-options {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
}

.checkbox-label {
  display: flex;
  align-items: center;
  cursor: pointer;
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.checkbox-label input[type="checkbox"] {
  display: none;
}

/* Increased checkmark size for better visibility */
.checkmark {
  width: 22px;
  height: 22px;
  border: 2px solid var(--border-light);
  border-radius: var(--radius-sm);
  margin-left: 0.5rem;
  position: relative;
  transition: all var(--transition-fast);
  flex-shrink: 0;
  background: var(--bg-primary);
}

.checkbox-label input[type="checkbox"]:checked + .checkmark {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  border-color: var(--primary);
}

.checkbox-label input[type="checkbox"]:checked + .checkmark::after {
  content: "✓";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  font-weight: var(--font-bold);
  font-size: 0.9rem;
}

.checkbox-label a {
  color: var(--primary);
  text-decoration: none;
}

.checkbox-label a:hover {
  text-decoration: underline;
}

.forgot-password {
  color: var(--primary);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: var(--font-medium);
  transition: color var(--transition-fast);
}

.forgot-password:hover {
  color: var(--primary-dark);
  text-decoration: underline;
}

/* حذف اللون الأزرق من الأزرار واستخدام الألوان المتغيرة */
.auth-btn {
  width: 100%;
  padding: 1rem 1.5rem;
  border: none;
  border-radius: var(--radius-xl);
  font-size: 1rem;
  font-weight: var(--font-semibold);
  cursor: pointer;
  transition: all var(--transition-fast);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  text-decoration: none;
}

.auth-btn.primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: white;
}

.auth-btn.primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.auth-btn.secondary {
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 2px solid var(--border-light);
}

.auth-btn.secondary:hover {
  background: var(--bg-primary);
  border-color: var(--primary);
  color: var(--primary);
}

/* Social Login */
.divider {
  text-align: center;
  margin: 2rem 0;
  position: relative;
  color: var(--text-muted);
}

.divider::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--border-light);
}

.divider span {
  background: var(--bg-primary);
  padding: 0 1rem;
  position: relative;
  z-index: 2;
}

.social-login {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 2rem;
}

.social-btn {
  width: 100%;
  padding: 1rem;
  border: 2px solid var(--border-light);
  border-radius: var(--radius-xl);
  background: var(--bg-secondary);
  color: var(--text-secondary);
  font-weight: var(--font-medium);
  cursor: pointer;
  transition: all var(--transition-fast);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
}

.social-btn:hover {
  border-color: var(--primary);
  background: var(--bg-primary);
  transform: translateY(-1px);
  color: var(--primary);
}

.social-btn.google:hover {
  border-color: var(--brand-google, #ea4335);
  color: var(--brand-google, #ea4335);
}

.social-btn.microsoft:hover {
  border-color: var(--brand-microsoft, #0078d4);
  color: var(--brand-microsoft, #0078d4);
}

.social-btn i {
  font-size: 1.2rem;
}

/* Form Footer */
.form-footer {
  text-align: center;
  margin-top: 1.5rem;
}

.form-footer p {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.signup-link,
.login-link {
  color: var(--primary);
  text-decoration: none;
  font-weight: var(--font-semibold);
  transition: color var(--transition-fast);
}

.signup-link:hover,
.login-link:hover {
  color: var(--primary-dark);
  text-decoration: underline;
}

/* Back to Home */
.back-to-home {
  position: absolute;
  top: 2rem;
  left: 2rem;
}

.back-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: var(--font-medium);
  transition: color var(--transition-fast);
}

.back-link:hover {
  color: var(--primary);
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  z-index: 1000;
  backdrop-filter: blur(5px);
}

.modal.active {
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-content {
  background: var(--bg-primary);
  border: 2px solid var(--border-light);
  border-radius: var(--radius-3xl);
  max-width: 450px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(-50px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 2rem 2rem 1rem;
  border-bottom: 2px solid var(--border-light);
}

.modal-header h3 {
  font-size: 1.5rem;
  font-weight: var(--font-bold);
  color: var(--text-primary);
}

.modal-close {
  background: none;
  border: none;
  font-size: 2rem;
  color: var(--text-muted);
  cursor: pointer;
  transition: color var(--transition-fast);
}

.modal-close:hover {
  color: var(--text-primary);
}

.modal-body {
  padding: 2rem;
}

.modal-body p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  line-height: 1.6;
}

.form-actions {
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
  margin-top: 1.5rem;
}

.form-actions .auth-btn {
  width: auto;
  padding: 0.75rem 1.5rem;
}

/* Loading States */
.auth-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none !important;
}

.auth-btn .spinner {
  width: 20px;
  height: 20px;
  border: 2px solid transparent;
  border-top: 2px solid currentColor;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Error States */
.input-error {
  border-color: var(--danger) !important;
}

.error-message {
  color: var(--danger);
  font-size: 0.8rem;
  margin-top: 0.25rem;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.success-message {
  color: var(--success);
  font-size: 0.8rem;
  margin-top: 0.25rem;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

/* Password Strength Colors */
.strength-fill.weak {
  background: var(--danger);
  width: 25%;
}

.strength-fill.fair {
  background: var(--warning);
  width: 50%;
}

.strength-fill.good {
  background: var(--success);
  width: 75%;
}

.strength-fill.strong {
  background: var(--success-dark);
  width: 100%;
}

/* Light Theme Adjustments */
.light-theme .input-wrapper input:focus,
.light-theme .input-wrapper select:focus {
  box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.1);
}

/* Dark Theme Adjustments */
.dark-theme .input-wrapper input:focus,
.dark-theme .input-wrapper select:focus {
  box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.15);
}

/* إضافة متغيرات ألوان العلامات التجارية */
:root {
  --brand-google: #ea4335;
  --brand-microsoft: #0078d4;
  --brand-twitter: #1da1f2;
  --brand-linkedin: #0077b5;
  --brand-instagram: #e4405f;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .auth-container {
    flex-direction: column;
  }

  .auth-visual {
    min-height: 300px;
    padding: 2rem;
  }

  .visual-stats {
    max-width: none;
    flex-direction: row;
    justify-content: space-between;
    gap: 1rem;
  }

  .floating-card {
    display: none;
  }
}

@media (max-width: 768px) {
  .auth-form-section {
    padding: 2rem 1rem;
  }

  .form-container {
    max-width: none;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .form-options {
    flex-direction: column;
    gap: 1rem;
    align-items: flex-start;
  }

  .visual-stats {
    flex-direction: column;
    gap: 1rem;
    text-align: left;
    max-width: 300px;
  }

  .stat-item {
    justify-content: flex-start;
  }

  .benefits-list {
    display: none;
  }

  .logo-section h1 {
    font-size: 2rem;
  }

  .logo-section p {
    font-size: 1rem;
  }

  .back-to-home {
    position: static;
    margin-bottom: 2rem;
  }

  .modal-content {
    width: 95%;
    margin: 1rem;
  }

  .modal-header,
  .modal-body {
    padding: 1.5rem;
  }

  .form-actions {
    flex-direction: column;
  }
}

@media (max-width: 480px) {
  .auth-visual {
    padding: 1.5rem;
  }

  .auth-form-section {
    padding: 1.5rem 1rem;
  }

  .social-login {
    gap: 0.5rem;
  }

  .social-btn {
    padding: 0.875rem;
    font-size: 0.9rem;
  }

  .form-header h2 {
    font-size: 1.75rem;
  }

  .auth-logo {
    font-size: 1.75rem;
  }

  .logo-section h1 {
    font-size: 1.75rem;
  }
}

/* Print Styles */
@media print {
  .auth-visual,
  .back-to-home,
  .social-login {
    display: none;
  }

  .auth-container {
    flex-direction: column;
  }

  .auth-form-section {
    background: var(--bg-primary);
    color: var(--text-primary);
  }

  .form-header h2,
  .form-group label {
    color: var(--text-primary);
  }

  .input-wrapper input,
  .input-wrapper select {
    border: 1px solid var(--border-light);
    background: var(--bg-secondary);
    color: var(--text-primary);
  }
} 