:root {
    --primary-navy: #1a2744;
    --primary-gold: #c8992a;
    --primary-gold-light: #e8b84b;
    --bg-cream: #fdf8f0;
}

.custom-auth-page {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background-color: var(--primary-navy);
    display: flex;
    flex-direction: row-reverse; /* Swapped: Image on left, Form on right */
    min-height: 100vh;
    width: 100vw;
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    overflow-y: auto;
}

.auth-left {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 3rem;
    position: relative;
    z-index: 10;
    min-height: 100vh;
    background-color: white !important; /* White background for login area */
    border-left: 3px solid var(--primary-gold) !important; /* Golden middle line */
}

/* Decorative background patterns */
.auth-left::before {
    content: '';
    position: absolute;
    width: 1000px;
    height: 1000px;
    border: 1px solid rgba(200, 153, 42, 0.08);
    border-radius: 50%;
    top: -300px;
    left: -300px;
    z-index: -1;
}

.auth-right {
    display: none;
    flex: 2.6;
    position: relative;
    overflow: hidden;
    min-height: 100vh;
}

@media (min-width: 1024px) {
    .auth-right {
        display: flex;
    }
}

/* ── Static branded right panel ── */
.auth-right-static {
    width: 100%;
    min-height: 100vh;
    background: linear-gradient(145deg, #0d1a3a 0%, #1a2744 40%, #1e3060 70%, #0d1a3a 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 4rem 3.5rem;
    position: relative;
    overflow: hidden;
    font-family: 'DM Sans', sans-serif;
}

/* Decorative circles */
.auth-deco-circle {
    position: absolute;
    border-radius: 50%;
    border: 1px solid rgba(200, 153, 42, 0.15);
    pointer-events: none;
}
.auth-deco-circle-1 { width: 500px; height: 500px; top: -150px; right: -150px; }
.auth-deco-circle-2 { width: 350px; height: 350px; bottom: -80px; left: -80px; border-color: rgba(200,153,42,0.10); }
.auth-deco-circle-3 { width: 200px; height: 200px; top: 45%; left: 60%; border-color: rgba(200,153,42,0.08); }

/* Branding row */
.auth-right-brand {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 3.5rem;
}
.auth-right-logo-box {
    width: 52px;
    height: 52px;
    background: linear-gradient(135deg, #c8992a, #e8b84b);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    font-weight: 800;
    color: white !important;
    box-shadow: 0 8px 20px rgba(200,153,42,0.4);
    flex-shrink: 0;
    font-family: 'DM Sans', sans-serif;
}
.auth-right-brand-name {
    font-size: 1.4rem;
    font-weight: 800;
    color: #ffffff !important;
    letter-spacing: 0.3px;
    font-family: 'DM Sans', sans-serif;
}
.auth-right-brand-tag {
    font-size: 0.65rem;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    color: rgba(200,153,42,0.85) !important;
    margin-top: 2px;
    font-family: 'DM Sans', sans-serif;
    font-weight: 400 !important;
}

/* Headline */
.auth-right-headline {
    margin-bottom: 2.5rem;
}
.custom-auth-page .auth-right .auth-right-static .auth-right-headline h2 {
    font-family: 'Playfair Display', serif !important;
    font-size: 3rem !important;
    font-weight: 700 !important;
    color: #ffffff !important;
    line-height: 1.15 !important;
    margin-bottom: 1.25rem !important;
    letter-spacing: -0.3px !important;
    text-align: center !important;
}
.custom-auth-page .auth-right .auth-right-static .auth-right-gold {
    color: #e8b84b !important;
    font-family: 'Playfair Display', serif !important;
    font-style: italic;
}
.custom-auth-page .auth-right .auth-right-static .auth-right-sub {
    font-family: 'DM Sans', sans-serif !important;
    font-size: 1rem !important;
    color: rgba(255,255,255,0.62) !important;
    line-height: 1.75 !important;
    max-width: 380px;
    font-weight: 300 !important;
    text-align: center !important;
}

/* Stats row */
.auth-right-stats {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-top: 1rem;
}
.auth-stat {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.custom-auth-page .auth-right .auth-stat-num {
    font-family: 'Playfair Display', serif !important;
    font-size: 1.75rem !important;
    font-weight: 700 !important;
    color: #e8b84b !important;
    line-height: 1 !important;
}
.custom-auth-page .auth-right .auth-stat-label {
    font-family: 'DM Sans', sans-serif !important;
    font-size: 0.6rem !important;
    letter-spacing: 2px !important;
    text-transform: uppercase !important;
    color: rgba(255,255,255,0.40) !important;
    font-weight: 500 !important;
}
.auth-stat-divider {
    width: 1px;
    height: 40px;
    background: rgba(200,153,42,0.25);
}

.form-container {
    width: 100%;
    max-width: 420px;
    animation: slideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.brand-logo {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    margin-bottom: 8rem !important; /* Significantly increased to ensure separation */
}

.logo-box {
    width: 60px;
    height: 60px;
    background: var(--primary-gold);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.75rem;
    font-weight: 800;
    color: white;
    box-shadow: 0 10px 25px rgba(200, 153, 42, 0.4);
}

.brand-name {
    font-size: 1.75rem;
    font-weight: 800;
    color: white;
    line-height: 1.1;
}

.brand-tagline {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: rgba(255, 255, 255, 0.5);
    margin-top: 4px;
}

.custom-auth-page .fi-fo-text-input input,
.custom-auth-page input,
.custom-auth-page select,
.custom-auth-page textarea {
    background-color: #f9fafb !important;
    border: none !important; /* Remove individual borders */
    color: #000000 !important;
    border-radius: 12px !important;
    padding: 0.875rem 1rem !important;
}

/* Reset checkbox styling */
.custom-auth-page input[type="checkbox"] {
    width: 1.25rem !important;
    height: 1.25rem !important;
    padding: 0 !important;
    margin-right: 0.5rem !important;
    background-color: white !important;
    border: 1.5px solid #e5e7eb !important;
    border-radius: 4px !important;
    cursor: pointer !important;
    -webkit-appearance: checkbox !important;
    appearance: checkbox !important;
}

.custom-auth-page .fi-fo-checkbox-wrp label {
    font-weight: 500 !important;
    font-size: 0.875rem !important;
    cursor: pointer !important;
}

/* Target the Filament input wrapper group */
.custom-auth-page .fi-input-wrp {
    background-color: #f9fafb !important;
    border: 1.5px solid #e5e7eb !important;
    border-radius: 12px !important;
    box-shadow: none !important;
    transition: all 0.2s ease !important;
}

.custom-auth-page .fi-input-wrp:focus-within {
    border-color: var(--primary-gold) !important;
    box-shadow: 0 0 0 4px rgba(200, 153, 42, 0.15) !important;
}

.custom-auth-page input::placeholder {
    color: #9ca3af !important;
}

.custom-auth-page input:-webkit-autofill,
.custom-auth-page input:-webkit-autofill:hover, 
.custom-auth-page input:-webkit-autofill:focus, 
.custom-auth-page input:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 1000px #f9fafb inset !important;
    -webkit-text-fill-color: #000000 !important;
    transition: background-color 5000s ease-in-out 0s;
}

.custom-auth-page .fi-fo-text-input input:focus {
    border-color: var(--primary-gold) !important;
    box-shadow: 0 0 0 4px rgba(200, 153, 42, 0.15) !important;
    outline: none !important;
    background-color: #ffffff !important;
}

.auth-left label,
.auth-left .fi-fo-field-wrp-label,
.auth-left span:not(.text-red-500):not(.text-red-600):not(.text-danger),
.auth-left p,
.auth-left h1,
.auth-left h2,
.auth-left .otp-timer-text {
    color: #000000 !important;
    font-weight: 700 !important;
}

.auth-left .text-red-600,
.auth-left .text-red-500,
.auth-left .fi-fo-field-wrp-error-message,
.auth-left [class*="text-danger"],
.auth-left .error-message,
.auth-left .otp-timer-value {
    color: #dc2626 !important;
}

.custom-auth-page .fi-btn {
    background: linear-gradient(135deg, var(--primary-gold) 0%, var(--primary-gold-light) 100%) !important;
    border-radius: 12px !important;
    font-weight: 700 !important;
    padding: 1rem !important;
    color: white !important;
    width: 100% !important;
    border: none !important;
    box-shadow: 0 8px 20px rgba(200, 153, 42, 0.3) !important;
    margin-top: 4rem !important; /* Added clear separation from form fields */
}

.custom-auth-page .fi-link {
    color: var(--primary-gold) !important;
    font-weight: 600 !important;
}

.custom-auth-page h1, 
.custom-auth-page h2, 
.custom-auth-page p {
    color: #111827 !important; /* Dark text for white background */
}

.footer-text {
    margin-top: 4rem;
    color: #9ca3af;
    font-size: 0.8rem;
    text-align: center;
}
