
.langsw { position: relative; display: inline-flex; align-items: center; }
.langsw-trigger {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 6px 12px; border: 1.5px solid #eee; border-radius: 50px;
    background: #fff; color: #333; font-family: "Outfit", sans-serif;
    font-size: 14px; font-weight: 500; cursor: pointer; line-height: 1;
    transition: border-color .2s, background .2s; white-space: nowrap;
}
.langsw-trigger:hover { border-color: #FF8A3D; background: #FFF8F0; }
.langsw-trigger .fi { width: 18px; height: 13px; border-radius: 2px; flex-shrink: 0; }
.langsw-code { font-size: 13px; font-weight: 600; letter-spacing: .03em; }
.langsw-chevron { width: 10px; height: 10px; flex-shrink: 0; transition: transform .2s; color: #999; }
.langsw.open .langsw-chevron { transform: rotate(180deg); }
.langsw-panel {
    display: none; position: absolute; top: calc(100% + 8px); right: 0;
    background: #fff; border: 1px solid #eee; border-radius: 14px;
    box-shadow: 0 8px 28px rgba(0,0,0,.10); min-width: 170px;
    z-index: 2000; padding: 6px; max-height: 340px; overflow-y: auto;
}
.langsw.open .langsw-panel { display: block; }
.langsw-item {
    display: flex; align-items: center; gap: 9px; padding: 8px 10px;
    border-radius: 8px; font-size: 14px; color: #333;
    text-decoration: none; transition: background .15s; white-space: nowrap;
}
.langsw-item:hover { background: #FFF8F0; }
.langsw-item-active { background: #FFF8F0; font-weight: 600; color: #FF8A3D; }
.langsw-item .fi { width: 20px; height: 15px; border-radius: 2px; flex-shrink: 0; }
@media (max-width: 900px) {
    .langsw-panel { right: auto; left: 0; }
}
        :root {
            --ink: #1B1A2E;
            --ink-2: #4A4860;
            --ink-3: #8A8799;
            --line: #E8E4DC;
            --field: #E2D6C8;
            --cream: #FAF7F2;
            --orange: #FF8A3D;
            --orange-deep: #E8742A;
            --orange-soft: #FFF3E9;
            --head: 'Outfit', system-ui, sans-serif;
            --logo: 'Bricolage Grotesque', system-ui, sans-serif;
            --body: 'DM Sans', system-ui, sans-serif;
        }
        * { margin: 0; padding: 0; box-sizing: border-box; }
        html, body { min-height: 100%; }
        body { font-family: var(--body); font-size: 16px; line-height: 1.55; color: var(--ink); background: #fff; }
        a { color: inherit; }

        
        .auth-page { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
        .auth-main { display: flex; flex-direction: column; padding: 24px clamp(20px, 5vw, 64px) 28px; }
        .auth-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
        .brand { display: inline-flex; align-items: center; gap: 10px; white-space: nowrap; text-decoration: none; font-family: var(--head); font-weight: 800; font-size: 21px; letter-spacing: -0.01em; }
        .brand img { width: 36px; height: 36px; }
        .top-signup { font-size: 15px; color: var(--ink-2); text-align: end; }
        .top-signup a { color: var(--ink); font-weight: 700; }

        .auth-center { flex: 1; display: flex; align-items: center; justify-content: center; padding: 36px 0; }
        .login-container { width: 100%; max-width: 420px; }

        .login-header { margin-bottom: 26px; }
        .login-title { font-family: var(--head); font-weight: 800; font-size: clamp(34px, 3.4vw, 46px); line-height: 1.05; letter-spacing: -0.03em; }
        .login-subtitle { margin-top: 10px; font-size: 18px; color: var(--ink-2); }

        
        .alert { padding: 13px 16px; border-radius: 14px; margin-bottom: 18px; font-size: 15px; border: 1.5px solid; }
        .alert-success { background: #ECF7EE; color: #1F5F2E; border-color: #B9DFC1; }
        .alert-danger, .alert-error { background: var(--cream); color: #C2410C; border-color: #F6C3A3; }
        .alert-warning { background: #FFF4D6; color: #7A5200; border-color: #F2D58A; }
        .alert-info { background: var(--cream); color: var(--ink-2); border-color: var(--field); }

        
        .social-login .border-top { border: 0 !important; margin: 0 !important; padding: 0 !important; }
        .social-login .border-top > br { display: none; }
        .social-login a.social-icon,
        .btn-social {
            display: flex !important; align-items: center !important; justify-content: center !important; gap: 12px;
            width: 100% !important; height: auto !important; min-height: 54px; padding: 12px 18px !important;
            border-radius: 14px !important; border: 1.5px solid var(--line) !important;
            background: #fff !important; color: var(--ink) !important;
            font-family: var(--body); font-weight: 700; font-size: 16px; text-decoration: none;
            box-shadow: none !important; cursor: pointer;
            transition: transform .12s ease, box-shadow .12s ease, background .15s ease !important;
        }
        .social-login a.social-icon:hover, .btn-social:hover { background: var(--cream) !important; transform: translateY(-1px); box-shadow: none !important; }
        .social-login a.social-icon:active, .btn-social:active { transform: none; box-shadow: none !important; }
        .social-login a.social-icon i { display: none !important; }
        .social-login a.social-icon::before { content: ''; width: 20px; height: 20px; flex: none; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48'%3E%3Cpath fill='%23FFC107' d='M43.6 20.5H42V20H24v8h11.3C33.7 32.7 29.2 36 24 36c-6.6 0-12-5.4-12-12s5.4-12 12-12c3.1 0 5.8 1.2 7.9 3.1l5.7-5.7C34 6.1 29.3 4 24 4 12.9 4 4 12.9 4 24s8.9 20 20 20 20-8.9 20-20c0-1.3-.1-2.4-.4-3.5z'/%3E%3Cpath fill='%23FF3D00' d='m6.3 14.7 6.6 4.8C14.7 15.1 19 12 24 12c3.1 0 5.8 1.2 7.9 3.1l5.7-5.7C34 6.1 29.3 4 24 4 16.3 4 9.7 8.3 6.3 14.7z'/%3E%3Cpath fill='%234CAF50' d='M24 44c5.2 0 9.9-2 13.4-5.2l-6.2-5.2C29.2 35.1 26.7 36 24 36c-5.2 0-9.6-3.3-11.3-7.9l-6.5 5C9.5 39.6 16.2 44 24 44z'/%3E%3Cpath fill='%231976D2' d='M43.6 20.5H42V20H24v8h11.3c-.8 2.2-2.2 4.2-4.1 5.6l6.2 5.2C37 39.2 44 34 44 24c0-1.3-.1-2.4-.4-3.5z'/%3E%3C/svg%3E") center / contain no-repeat; }
        .btn-social i { font-size: 18px; color: var(--ink); }

        .divider { display: flex; align-items: center; gap: 14px; margin: 22px 0; color: var(--ink-3); font-size: 14px; }
        .divider::before, .divider::after { content: ''; flex: 1; height: 1px; background: var(--line); }

        
        .email-login-form { display: none; }
        .email-login-form.show { display: block; animation: slideDown .25s ease; }
        @keyframes slideDown { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }

        .back-to-options { margin-bottom: 18px; }
        .back-link { display: inline-flex; align-items: center; gap: 8px; font-size: 15px; font-weight: 700; color: var(--orange-deep); text-decoration: none; }
        .back-link:hover { text-decoration: underline; }
        [dir="rtl"] .back-link i { transform: scaleX(-1); }

        .form-group { margin-bottom: 16px; }
        .form-label { display: block; margin-bottom: 6px; font-size: 14px; font-weight: 700; color: var(--ink-2); }
        .form-control { width: 100%; min-height: 52px; padding: 13px 16px; border: 1.5px solid var(--field); border-radius: 12px; background: #FFFCF8; font-family: var(--body); font-size: 16px; color: var(--ink); transition: border-color .15s, box-shadow .15s, background .15s; }
        .form-control::placeholder { color: #9A8F84; }
        .form-control:focus { outline: none; border-color: var(--ink); background: #fff; box-shadow: 0 0 0 4px var(--orange-soft); }

        .password-wrapper { position: relative; }
        .password-wrapper .form-control { padding-inline-end: 52px; }
        .password-toggle { position: absolute; inset-inline-end: 6px; top: 50%; transform: translateY(-50%); width: 42px; height: 42px; border: 0; border-radius: 10px; background: none; color: var(--ink-3); cursor: pointer; font-size: 16px; }
        .password-toggle:hover { color: var(--ink); background: var(--cream); }

        .remember-forgot { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin: 4px 0 22px; font-size: 15px; }
        .remember-me { display: flex; align-items: center; gap: 8px; }
        .remember-me input[type="checkbox"] { width: 18px; height: 18px; accent-color: var(--orange); cursor: pointer; }
        .remember-me label { color: var(--ink-2); cursor: pointer; }
        .forgot-link { color: var(--orange-deep); font-weight: 700; text-decoration: none; }
        .forgot-link:hover { text-decoration: underline; }

        .btn { width: 100%; min-height: 56px; padding: 14px 20px; display: flex; align-items: center; justify-content: center; gap: 10px; border-radius: 14px; font-family: var(--head); font-weight: 800; font-size: 19px; cursor: pointer; transition: transform .12s ease, box-shadow .12s ease, background .15s ease; }
        .btn-primary { background: var(--orange); color: #fff; border: 0; box-shadow: none; }
        .btn-primary:hover { background: #FF9A55; transform: translateY(-1px); box-shadow: none; }
        .btn-primary:active { transform: none; box-shadow: none; }
        .btn-loading { opacity: .75; pointer-events: none; }
        .spinner { width: 18px; height: 18px; border: 2.5px solid rgba(27, 26, 46,.25); border-top-color: var(--ink); border-radius: 50%; animation: spin .8s linear infinite; }
        @keyframes spin { to { transform: rotate(360deg); } }

        .signup-link { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); font-size: 15px; color: var(--ink-2); }
        .signup-link a { color: var(--ink); font-weight: 700; }
        .signup-link a:hover { color: var(--orange-deep); }

        
        .auth-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-start; gap: 10px 18px; font-size: 14px; color: var(--ink-3); }
        .footer-links { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
        .footer-links a { color: var(--ink-3); text-decoration: none; }
        .footer-links a:hover { color: var(--ink); text-decoration: underline; }
        .footer-links .sep { opacity: .5; }

        
        .lang-wrap { position: relative; z-index: 50; }
        .lang-wrap > * { position: relative; }
        .lang-wrap ul, .lang-wrap ol,
        .lang-wrap [class*="dropdown"], .lang-wrap [class*="menu"], .lang-wrap [class*="list"],
        .lang-wrap [class*="options"], .lang-wrap [class*="panel"] {
            top: auto !important; bottom: calc(100% + 8px) !important;
            max-height: min(50vh, 320px) !important; overflow-y: auto !important;
            z-index: 9999 !important; box-shadow: 0 -10px 24px -6px rgb(0 0 0 / .18) !important;
        }
        .lang-dropup-fix { top: auto !important; bottom: calc(100% + 8px) !important; max-height: min(50vh, 320px) !important; overflow-y: auto !important; z-index: 9999 !important; }

        
        .auth-side { position: relative; margin: 16px; margin-inline-start: 0; border-radius: 32px; overflow: hidden; background: linear-gradient(180deg, #FFD9B8 0%, #FFE9D6 55%, #FFF7EF 100%); }
        .side-cols { position: absolute; inset: -40px 30px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
        .side-col { overflow: hidden; }
        .side-track { display: flex; flex-direction: column; gap: 18px; animation: colUp 140s linear infinite; }
        .side-col:nth-child(2) .side-track { animation-name: colDown; animation-duration: 160s; }
        .side-col:nth-child(3) .side-track { animation-duration: 180s; }
        .side-track img { width: 100%; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 5px 12px 12px 5px; box-shadow: 0 22px 34px -20px rgba(27, 26, 46, .55); display: block; background: #fff; }
        .auth-side:hover .side-track { animation-play-state: paused; }
        @keyframes colUp { to { transform: translateY(-50%); } }
        @keyframes colDown { from { transform: translateY(-50%); } to { transform: translateY(0); } }

        @media (prefers-reduced-motion: reduce) {
            .side-track { animation: none !important; }
        }

        @media (max-width: 1100px) {
            .auth-page { grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); }
            .side-cols { inset: -40px 20px; gap: 14px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
            .side-col:nth-child(3) { display: none; }
            .side-track { gap: 14px; }
        }
        @media (max-width: 860px) {
            .auth-page { grid-template-columns: minmax(0, 1fr); }
            .auth-main { min-width: 0; }
            .auth-side { display: none; }
            .auth-main { padding: 18px 20px 24px; }
            .auth-page { background: linear-gradient(180deg, #FFE9D6 0, #FFF7EF 220px, #fff 420px); }
            .auth-center { align-items: flex-start; padding: 40px 0 34px; }
            .brand { font-size: 17px; white-space: nowrap; gap: 8px; }
            .brand img { width: 30px; height: 30px; }
            .auth-foot { justify-content: center; text-align: center; flex-direction: column; }
            .footer-links { justify-content: center; }
            .sep-c { display: none; }
            .copyright { flex-basis: 100%; }
        }
    
        
        body { background: #fff; }
        .sidebar-logo, .brand { font-family: var(--logo); letter-spacing: -0.02em; }
        .btn.primary { color: #fff; border: 0; }
        .cr-num { border-color: rgba(27, 26, 46, .1); }
        :root { --field: #ECE7DF; }
        .form-control { background: #fff; }
        .form-control:focus { border-color: var(--orange); }
        .btn-primary .spinner { border-color: rgba(255, 255, 255, .35); border-top-color: #fff; }
        .auth-page { background: #fff !important; }
    
        
        :root { --head: 'Bricolage Grotesque', system-ui, sans-serif; --field: #D9D4CA; }
        .login-title { font-family: var(--head); letter-spacing: -.03em; }
        .login-title em { font-style: normal; color: var(--orange-deep); }
        .social-login a.social-icon, .btn-social { border: 2px solid var(--ink) !important; }
        .social-login a.social-icon:hover, .btn-social:hover { background: var(--orange-soft) !important; }
        .form-control { border: 1.5px solid var(--field); background: #fff; }
        .form-control:focus { border-color: var(--ink); box-shadow: 0 0 0 4px var(--orange-soft); }
        .btn-primary { background: var(--orange); color: var(--ink); border: 2px solid var(--ink); box-shadow: 0 5px 0 -1px var(--ink); font-family: var(--body); font-weight: 800; }
        .btn-primary:hover { background: var(--orange); transform: translateY(-2px); box-shadow: 0 7px 0 -1px var(--ink); }
        .btn-primary:active { transform: translateY(2px); box-shadow: 0 2px 0 -1px var(--ink); }
        .ls-av { border: 1.5px solid #F6C3A3; }
        .login-card, .signup-card, .forgot-card { border: 2px solid var(--ink) !important; box-shadow: 0 8px 0 -2px var(--ink), 0 30px 60px -36px rgba(27,26,46,.35) !important; }
        
        .auth-side { border: 2px solid var(--ink); background: linear-gradient(180deg, #FFE9DA 0%, #FFF4EC 100%); }
        .side-track img { border-radius: 6px; box-shadow: 2px 2px 0 rgba(27,26,46,.22), 0 14px 24px -14px rgba(27,26,46,.45); }
    
        
        .auth-top .lang-wrap ul, .auth-top .lang-wrap ol,
        .auth-top .lang-wrap [class*="dropdown"], .auth-top .lang-wrap [class*="menu"], .auth-top .lang-wrap [class*="list"],
        .auth-top .lang-wrap [class*="options"], .auth-top .lang-wrap [class*="panel"] {
            top: calc(100% + 8px) !important; bottom: auto !important; right: 0 !important; left: auto !important;
            max-height: min(60vh, 360px) !important; box-shadow: 0 14px 30px -10px rgb(0 0 0 / .2) !important;
        }
