/* Login and registration visual layer. Authentication behavior stays in index.php. */
body.app-skin.auth-redesign {
    --auth-bg: #06110d;
    --auth-surface: #0b1813;
    --auth-border: #263832;
    --auth-surface: #111113;
    --auth-border: #262629;
    --auth-text: #e8e8ea;
    --auth-muted: #8a8a8f;
    --auth-green: #39ff6a;
    --auth-green-dark: #04220f;
    min-height: 100vh;
    background: var(--auth-bg) !important;
    color: var(--auth-text) !important;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
}

body.auth-redesign::before,
body.auth-redesign::after {
    display: none !important;
}

body.auth-redesign .auth-wrapper {
    display: block !important;
    width: 100% !important;
    min-height: 100vh !important;
    padding: 112px 24px 80px !important;
    background: transparent !important;
}

body.auth-redesign .auth-card {
    position: relative !important;
    width: min(100%, 612px) !important;
    max-width: 612px !important;
    min-height: 0 !important;
    margin: 0 auto !important;
    padding: 72px 0 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    overflow: visible !important;
}

body.auth-redesign .auth-card::before,
body.auth-redesign .auth-card::after,
body.auth-redesign .login-showcase {
    display: none !important;
}

body.auth-redesign .theme-switch {
    position: fixed !important;
    z-index: 5;
    top: 42px !important;
    right: max(24px, calc((100vw - 612px) / 2)) !important;
}

body.auth-redesign .language-switch {
    position: fixed !important;
    z-index: 6;
    top: 34px !important;
    left: max(24px, calc((100vw - 612px) / 2)) !important;
}

body.auth-redesign .theme-toggle,
body.auth-redesign .language-trigger {
    display: grid !important;
    place-items: center !important;
    width: 50px !important;
    height: 50px !important;
    padding: 0 !important;
    border: 1px solid var(--auth-border) !important;
    border-radius: 50% !important;
    background: #0b1713 !important;
    color: var(--auth-text) !important;
    box-shadow: inset 0 0 0 5px rgba(255,255,255,.015) !important;
}

body.auth-redesign .theme-toggle span,
body.auth-redesign .language-trigger i {
    display: none !important;
}

body.auth-redesign .theme-toggle i {
    font-size: 22px !important;
    color: var(--auth-text) !important;
}

body.auth-redesign .language-trigger #currentLanguage {
    font-size: 12px !important;
    font-weight: 600 !important;
    color: var(--auth-green) !important;
}

body.auth-redesign .language-menu {
    top: 60px !important;
    left: 0 !important;
    right: auto !important;
    width: 190px !important;
    padding: 8px !important;
    border: 1px solid var(--auth-border) !important;
    border-radius: 12px !important;
    background: #0b1511 !important;
    box-shadow: 0 18px 40px rgba(0,0,0,.35) !important;
}

body.auth-redesign .language-option {
    border-radius: 8px !important;
    color: var(--auth-muted) !important;
}

body.auth-redesign .language-option.active {
    color: var(--auth-green) !important;
    background: rgba(57,255,106,.08) !important;
}

body.auth-redesign .brand-logo {
body.auth-redesign .brand-word {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 280px !important;
    height: 132px !important;
    margin: 0 auto 18px !important;
    width: auto !important;
    height: auto !important;
    margin: 0 auto 44px !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #fff !important;
    font-size: 34px !important;
    line-height: 1 !important;
    font-weight: 500 !important;
    letter-spacing: -1.3px !important;
}

body.auth-redesign .brand-logo img {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    object-fit: contain !important;
    filter: grayscale(1) brightness(3) !important;
body.auth-redesign .brand-word span {
    color: var(--auth-green) !important;
}

body.auth-redesign .brand-title {
    display: block !important;
    margin: 0 0 60px !important;
    color: var(--auth-text) !important;
    font-size: clamp(30px, 6vw, 42px) !important;
    line-height: 1.2 !important;
    font-weight: 400 !important;
    letter-spacing: -.8px !important;
    text-align: center !important;
}

body.auth-redesign .auth-subtitle,
body.auth-redesign .brand-title .main,
body.auth-redesign .brand-title .trust,
body.auth-redesign .auth-toggle {
    display: none !important;
}

body.auth-redesign .tab-content,
body.auth-redesign .tab-pane,
body.auth-redesign form {
    width: 100% !important;
}

body.auth-redesign form.mt-2 {
    margin-top: 0 !important;
}

body.auth-redesign form .mb-3 {
    margin-bottom: 28px !important;
}

body.auth-redesign .form-label {
    display: block !important;
    margin: 0 0 13px !important;
    color: #b6b8b7 !important;
    font-size: 17px !important;
    line-height: 1.35 !important;
    font-weight: 500 !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
}

body.auth-redesign .auth-field {
    display: flex !important;
    align-items: center !important;
    min-height: 72px !important;
    padding: 0 20px !important;
    border: 1px solid var(--auth-border) !important;
    border-radius: 36px !important;
    border: 1px solid #262629 !important;
    border-radius: 10px !important;
    background: var(--auth-surface) !important;
    box-shadow: inset 0 2px 5px rgba(255,255,255,.025) !important;
    background-image: none !important;
    box-shadow: none !important;
    overflow: hidden !important;
    transition: border-color .16s ease, box-shadow .16s ease !important;
}

body.auth-redesign .auth-field:focus-within {
    border-color: var(--auth-green) !important;
    box-shadow: inset 0 0 0 1px rgba(57,255,106,.16) !important;
}

body.auth-redesign .auth-field-icon {
    position: static !important;
    display: inline-flex !important;
    flex: 0 0 auto !important;
    margin-right: 17px !important;
    color: #14c987 !important;
    font-size: 25px !important;
    transform: none !important;
}

body.auth-redesign .auth-field .form-control {
    flex: 1 1 auto !important;
    width: 100% !important;
    height: 70px !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    border-radius: 0 !important;
    background: #111113 !important;
    background-color: #111113 !important;
    background-image: none !important;
    box-shadow: none !important;
    color: var(--auth-text) !important;
    font-size: 19px !important;
    font-weight: 400 !important;
}

body.auth-redesign .auth-field .form-control:-webkit-autofill,
body.auth-redesign .auth-field .form-control:-webkit-autofill:hover,
body.auth-redesign .auth-field .form-control:-webkit-autofill:focus {
    border: 0 !important;
    -webkit-text-fill-color: var(--auth-text) !important;
    caret-color: var(--auth-text) !important;
    -webkit-box-shadow: 0 0 0 1000px #111113 inset !important;
    box-shadow: 0 0 0 1000px #111113 inset !important;
    transition: background-color 99999s ease-out 0s !important;
}

body.auth-redesign .auth-field .form-control::placeholder {
    color: #656b68 !important;
    opacity: 1 !important;
}

body.auth-redesign .password-toggle {
    position: static !important;
    flex: 0 0 auto !important;
    width: 42px !important;
    height: 42px !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    background: #111113 !important;
    color: #14c987 !important;
    font-size: 23px !important;
}

body.auth-redesign .form-check {
    display: flex !important;
    align-items: center !important;
    gap: 13px !important;
    min-height: 34px !important;
    padding-left: 0 !important;
    color: #b6b8b7 !important;
    font-size: 16px !important;
}

body.auth-redesign .form-check-input {
    flex: 0 0 auto !important;
    width: 27px !important;
    height: 27px !important;
    margin: 0 !important;
    border: 1.5px solid #14c987 !important;
    border-radius: 50% !important;
    background: transparent !important;
    box-shadow: none !important;
}

body.auth-redesign .form-check-input:checked {
    border-color: var(--auth-green) !important;
    background-color: var(--auth-green) !important;
}

body.auth-redesign .auth-submit {
    width: 100% !important;
    min-height: 72px !important;
    padding: 14px 24px !important;
    border: 1px solid #65ff8c !important;
    border-radius: 36px !important;
    background: var(--auth-green) !important;
    box-shadow: inset 0 2px 0 rgba(255,255,255,.22) !important;
    color: var(--auth-green-dark) !important;
    font-size: 21px !important;
    line-height: 1.2 !important;
    font-weight: 500 !important;
}

body.auth-redesign .auth-submit:hover {
    background: #65ff8c !important;
    transform: none !important;
}

body.auth-redesign .small-text.text-secondary {
    margin-top: 52px !important;
    color: #a8adaa !important;
    font-size: 17px !important;
}

body.auth-redesign .link-accent {
    color: #72eaaa !important;
    font-weight: 500 !important;
}

body.auth-redesign .alert,
body.auth-redesign .inviter-card {
    border: 1px solid var(--auth-border) !important;
    border-radius: 12px !important;
    background: var(--auth-surface) !important;
    color: var(--auth-text) !important;
}

body.auth-redesign .mono,
body.auth-redesign code {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace !important;
    font-variant-numeric: tabular-nums !important;
}

body.auth-redesign.clear-mode {
    background: var(--auth-bg) !important;
    color: var(--auth-text) !important;
}

body.app-skin.auth-redesign.clear-mode .auth-field,
body.app-skin.auth-redesign.clear-mode .auth-field .form-control,
body.app-skin.auth-redesign.clear-mode .password-toggle {
    border-color: #262629 !important;
    background: #111113 !important;
    background-color: #111113 !important;
    background-image: none !important;
    color: var(--auth-text) !important;
    box-shadow: none !important;
}

body.app-skin.auth-redesign.clear-mode .auth-field-icon,
body.app-skin.auth-redesign.clear-mode .password-toggle {
    color: #14c987 !important;
}

body.app-skin.auth-redesign.clear-mode .form-label {
    color: #b6b8b7 !important;
}

body.app-skin.auth-redesign.clear-mode .auth-field .form-control::placeholder {
    color: #656b68 !important;
}

@media (max-width: 640px) {
    body.auth-redesign .auth-wrapper {
        padding: 94px 24px 60px !important;
    }

    body.auth-redesign .auth-card {
        padding-top: 50px !important;
    }

    body.auth-redesign .brand-logo {
        width: 220px !important;
        height: 104px !important;
        margin-bottom: 16px !important;
    body.auth-redesign .brand-word {
        margin-bottom: 38px !important;
    }

    body.auth-redesign .brand-title {
        margin-bottom: 48px !important;
    }

    body.auth-redesign .auth-field,
    body.auth-redesign .auth-submit {
        min-height: 64px !important;
        border-radius: 32px !important;
    }

    body.auth-redesign .auth-field {
        min-height: 64px !important;
        border-radius: 10px !important;
    }

    body.auth-redesign .auth-field .form-control {
        height: 62px !important;
        font-size: 17px !important;
    }

    body.auth-redesign .theme-switch { right: 24px !important; }
    body.auth-redesign .language-switch { left: 24px !important; }
}

@media (max-width: 380px) {
    body.auth-redesign .auth-wrapper { padding-inline: 18px !important; }
    body.auth-redesign .auth-field { padding-inline: 16px !important; }
    body.auth-redesign .auth-field-icon { margin-right: 12px !important; }
}

@media (prefers-reduced-motion: reduce) {
    body.auth-redesign * { transition: none !important; animation: none !important; }
}