/* 
   =============================================================================
   ESTABRAQ ACADEMY - AUTHENTICATION PAGES (SPLIT SCREEN LAYOUT)
   ============================================================================= 
*/

.auth-layout-wrapper {
    display: flex;
    min-height: 100vh;
    width: 100%;
    background-color: var(--ea-white);
}

/* ── Form Side (Right/Left) ─────────────────────────────────── */
.auth-form-side {
    width: 55%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: var(--space-3xl) var(--space-xl);
    position: relative;
}

.auth-form-content {
    width: 100%;
    max-width: 420px;
    animation: fadeUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* ── Sidebar Side (Left/Right) ──────────────────────────────── */
.auth-sidebar-side {
    width: 45%;
    background-color: var(--ea-primary);
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(212, 175, 55, 0.15) 0%, transparent 20%),
        radial-gradient(circle at 90% 80%, rgba(212, 175, 55, 0.15) 0%, transparent 20%);
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: var(--space-4xl);
    color: var(--ea-white);
    overflow: hidden;
}

/* Add subtle Islamic pattern overlay */
.auth-sidebar-side::after {
    content: '';
    position: absolute;
    inset: 0;
    opacity: 0.05;
    background-image: url('data:image/svg+xml,%3Csvg width="60" height="60" viewBox="0 0 60 60" xmlns="http://www.w3.org/2000/svg"%3E%3Cpath d="M54.627 0l.83.83-5.542 5.542V18h11.626l5.543-5.542.83.83-6.372 6.372v10.68H54.627V19.66h-11.626V8.032l5.542-5.544.83-.83L54.627 0z" fill="%23FFFFFF" fill-opacity="1" fill-rule="evenodd"/%3E%3C/svg%3E');
    pointer-events: none;
}

.auth-sidebar-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 400px;
}

.auth-sidebar-icon {
    font-size: 4rem;
    color: var(--ea-gold);
    margin-bottom: var(--space-xl);
}

.auth-sidebar-title {
    font-family: var(--font-heading-ar);
    font-size: clamp(2rem, 3vw, 2.5rem);
    margin-bottom: var(--space-md);
    color: var(--ea-white);
    line-height: 1.3;
}

.auth-sidebar-text {
    font-size: 1.125rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.85);
}

/* ── Top Navigation (Logo & Back) ───────────────────────────── */
.auth-top-nav {
    position: absolute;
    top: var(--space-xl);
    left: var(--space-2xl);
    right: var(--space-2xl);
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 10;
}

.auth-back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--ea-gray-600);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

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

/* ── Form Components ────────────────────────────────────────── */
.auth-heading {
    margin-bottom: var(--space-xs);
    font-size: 2rem;
    font-family: var(--font-heading-en);
}
[lang="ar"] .auth-heading, [dir="rtl"] .auth-heading {
    font-family: var(--font-heading-ar);
}

.auth-subheading {
    color: var(--ea-gray-500);
    margin-bottom: var(--space-2xl);
    font-size: 1rem;
}

.auth-form-group {
    margin-bottom: var(--space-lg);
}

.auth-form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--ea-gray-800);
    font-size: 0.9rem;
}

.auth-form-input {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 1px solid var(--ea-gray-300);
    border-radius: var(--radius-lg);
    background-color: var(--ea-gray-50);
    color: var(--ea-gray-900);
    font-family: inherit;
    transition: all 0.2s ease;
    outline: none;
}

.auth-form-input:focus {
    border-color: var(--ea-primary);
    background-color: var(--ea-white);
    box-shadow: 0 0 0 4px var(--ea-primary-10);
}

.auth-form-input::placeholder {
    color: var(--ea-gray-400);
}

.auth-form-checkbox-wrapper {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.auth-form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-xl);
    font-size: 0.9rem;
}

.auth-forgot-password {
    color: var(--ea-primary);
    text-decoration: none;
    font-weight: 500;
}

.auth-forgot-password:hover {
    text-decoration: underline;
}

.auth-submit-btn {
    width: 100%;
    padding: 1rem;
    border-radius: var(--radius-lg);
    font-size: 1rem;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
}

.auth-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: var(--space-xl) 0;
    color: var(--ea-gray-400);
    font-size: 0.875rem;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid var(--ea-gray-200);
}

.auth-divider::before { margin-right: 1em; }
.auth-divider::after { margin-left: 1em; }
[dir="rtl"] .auth-divider::before { margin-left: 1em; margin-right: 0; }
[dir="rtl"] .auth-divider::after { margin-right: 1em; margin-left: 0; }

.auth-alt-text {
    text-align: center;
    margin-top: var(--space-xl);
    font-size: 0.95rem;
    color: var(--ea-gray-600);
}

.auth-alt-link {
    color: var(--ea-primary);
    font-weight: 600;
    text-decoration: none;
}

.auth-alt-link:hover {
    text-decoration: underline;
}

/* Password Input Wrapper for toggle icon */
.auth-password-wrapper {
    position: relative;
}

.auth-password-toggle {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    right: 1rem;
    color: var(--ea-gray-400);
    cursor: pointer;
    background: transparent;
    border: none;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}
[dir="rtl"] .auth-password-toggle {
    right: auto;
    left: 1rem;
}

.auth-password-toggle:hover {
    color: var(--ea-gray-600);
}

/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 991px) {
    .auth-sidebar-side {
        display: none; /* Hide sidebar completely on mobile/tablet */
    }
    
    .auth-form-side {
        width: 100%;
        padding: var(--space-xl);
    }
    
    .auth-top-nav {
        left: var(--space-xl);
        right: var(--space-xl);
    }
}
