/* Saeed Shokouh - Custom Glass Login Page for Nader */

body.login,
body.login * {
    box-sizing: border-box;
    font-family: "IranSans", Tahoma, Arial, sans-serif;
}

.dashicons,
.dashicons-before:before {
    font-family: dashicons !important;
}

html,
body.login {
    min-height: 100%;
}

body.login {
    min-height: 100svh;
    margin: 0;
    direction: rtl;
    color: #fff;
    background-image: var(--ss-login-bg-image);
    background-size: cover !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;
    background-attachment: fixed !important;
    overflow-x: hidden;
}

body.login::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background:
        radial-gradient(circle at 50% 22%, rgba(62, 28, 210, 0.24), transparent 34%),
        linear-gradient(115deg, rgba(4, 8, 16, var(--ss-login-overlay, 0.72)) 0%, rgba(15, 27, 41, 0.70) 46%, rgba(4, 8, 16, var(--ss-login-overlay, 0.72)) 100%);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
}

body.login::after {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background: rgba(0, 0, 0, 0.14);
}

body.login .ss-login-topbar,
body.login #login {
    position: relative;
    z-index: 2;
}

/* Top glass menu */
.ss-login-topbar {
    width: min(1120px, calc(100vw - 48px));
    margin: 20px auto 0;
}

.ss-login-topbar-inner {
    min-height: 68px;
    padding: 10px 16px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 24px;
    background: rgba(22, 34, 52, 0.56);
    box-shadow: 0 20px 70px rgba(0, 0, 0, 0.25);
    backdrop-filter: blur(18px) saturate(150%);
    -webkit-backdrop-filter: blur(18px) saturate(150%);
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 24px;
}

.ss-login-brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: #fff !important;
    text-decoration: none !important;
    min-width: max-content;
    order: 0;
}

.ss-login-brand img {
    width: 52px;
    height: 52px;
    object-fit: contain;
    border-radius: 14px;
    filter: drop-shadow(0 10px 22px rgba(0, 0, 0, 0.35));
}

.ss-login-brand strong {
    display: block;
    font-size: 17px;
    line-height: 1.4;
    font-weight: 800;
}

.ss-login-brand small {
    display: block;
    margin-top: 1px;
    font-size: 11px;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.72);
}

.ss-login-menu {
    flex: 1 1 auto;
    order: 1;
}

.ss-login-menu-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
}

.ss-login-menu-list li {
    margin: 0;
    padding: 0;
}

.ss-login-menu-list a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 36px;
    padding: 7px 14px;
    border-radius: 999px;
    color: rgba(255, 255, 255, 0.86) !important;
    background: transparent !important;
    text-decoration: none !important;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.4;
    transition: color 0.22s ease, background-color 0.22s ease, transform 0.22s ease;
}

.ss-login-menu-list a:hover {
    color: #fff !important;
    background: rgba(255, 255, 255, 0.10) !important;
    transform: translateY(-1px);
}

.ss-login-menu-list .current-menu-item > a,
.ss-login-menu-list .current_page_item > a,
.ss-login-menu-list .current-menu-ancestor > a,
.ss-login-menu-list .current-menu-parent > a {
    background: transparent !important;
    color: rgba(255, 255, 255, 0.86) !important;
}

/* Main glass card */
body.login #login {
    width: min(430px, calc(100vw - 34px));
    margin: 30px auto 0;
    padding: 26px 34px 22px;
    border-radius: 30px;
    border: 1px solid rgba(255, 255, 255, 0.23);
    background:
        linear-gradient(145deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0.07)),
        rgba(20, 26, 46, 0.42);
    box-shadow:
        0 30px 90px rgba(0, 0, 0, 0.42),
        inset 0 1px 0 rgba(255, 255, 255, 0.28);
    backdrop-filter: blur(22px) saturate(155%);
    -webkit-backdrop-filter: blur(22px) saturate(155%);
}

body.login #login h1 {
    margin: 0 0 10px;
    padding: 0;
}

body.login #login h1 a {
    width: 60px !important;
    height: 60px !important;
    margin: 0 auto !important;
    padding: 0 !important;
    background-image: var(--ss-login-logo-image) !important;
    background-size: contain !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;
    border-radius: 18px;
    opacity: 0.94;
    filter: drop-shadow(0 12px 26px rgba(0, 0, 0, 0.38));
    text-indent: -9999px;
    overflow: hidden;
}

.ss-login-intro {
    text-align: center;
    margin: 0 0 18px;
}

.ss-login-intro h2 {
    margin: 0 auto 12px;
    color: #fff;
    font-family: "Moraba", "Morabba", "Morabba FD", "IranSans", Tahoma, Arial, sans-serif;
    font-size: 24px;
    line-height: 1.36;
    font-weight: 800;
    letter-spacing: -0.3px;
    max-width: 350px;
}

.ss-login-intro p {
    margin: 0 auto;
    max-width: 330px;
    color: rgba(255, 255, 255, 0.78);
    font-size: 13px;
    line-height: 1.85;
    font-weight: 500;
}

/* WordPress form reset */
body.login #login form,
body.login form#loginform,
body.login form#lostpasswordform,
body.login form#resetpassform,
body.login form#registerform {
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    overflow: visible !important;
}

body.login #login form p {
    margin: 0 0 11px;
}

body.login #login label {
    display: inline-block;
    margin: 0 0 8px;
    color: rgba(255, 255, 255, 0.94);
    font-size: 13px;
    font-weight: 700;
    line-height: 1.9;
    cursor: pointer;
}

body.login #login input.input,
body.login #login input[type="text"],
body.login #login input[type="password"],
body.login #login input[type="email"],
body.login #login input[type="number"] {
    width: 100%;
    min-height: 48px;
    margin: 0 0 10px;
    padding: 0 16px;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.24);
    background: rgba(255, 255, 255, 0.12) !important;
    color: #fff;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.10);
    font-size: 16px;
    outline: none;
    transition: border-color 0.20s ease, background-color 0.20s ease, box-shadow 0.20s ease;
}

body.login #login input.input:focus,
body.login #login input[type="text"]:focus,
body.login #login input[type="password"]:focus,
body.login #login input[type="email"]:focus,
body.login #login input[type="number"]:focus {
    border-color: rgba(112, 76, 255, 0.88) !important;
    background: rgba(255, 255, 255, 0.16) !important;
    color: #fff;
    box-shadow: 0 0 0 4px rgba(62, 28, 210, 0.20), inset 0 1px 0 rgba(255, 255, 255, 0.16);
}

body.login #login input::placeholder {
    color: rgba(255, 255, 255, 0.55);
}

body.login #login .user-pass-wrap {
    margin-top: 2px;
}

body.login #login .wp-pwd {
    position: relative;
}

body.login #login .button.wp-hide-pw {
    height: 52px;
    min-width: 46px;
    top: 0;
    color: rgba(255, 255, 255, 0.72) !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
}

body.login #login .button.wp-hide-pw:hover {
    color: #fff !important;
}

body.login #login .forgetmenot {
    float: none !important;
    display: flex !important;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    width: 100%;
    margin: 6px 0 16px !important;
}

body.login #login .forgetmenot label {
    margin: 0;
    color: rgba(255, 255, 255, 0.80);
    font-size: 12px;
    font-weight: 500;
    line-height: 1.7;
}

body.login #login input[type="checkbox"] {
    width: 15px;
    height: 15px;
    margin: 0;
    border-radius: 5px;
    border: 1px solid rgba(255, 255, 255, 0.45);
    background: rgba(255, 255, 255, 0.12);
}

body.login #login p.submit {
    margin: 0 !important;
    padding: 0 !important;
}

body.login.wp-core-ui #login input#wp-submit.button.button-primary,
body.login #login .button-primary {
    width: 100% !important;
    min-height: 50px !important;
    padding: 0 16px !important;
    border: 0 !important;
    border-radius: 16px !important;
    background: linear-gradient(135deg, #3E1CD2 0%, #704CFF 100%) !important;
    color: #fff !important;
    font-size: 14px !important;
    font-weight: 800 !important;
    line-height: 50px !important;
    text-align: center;
    text-shadow: none !important;
    text-transform: none !important;
    box-shadow: 0 16px 38px rgba(62, 28, 210, 0.34) !important;
    transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

body.login.wp-core-ui #login input#wp-submit.button.button-primary:hover,
body.login.wp-core-ui #login input#wp-submit.button.button-primary:focus,
body.login #login .button-primary:hover,
body.login #login .button-primary:focus {
    background: linear-gradient(135deg, #3517B8 0%, #6442F4 100%) !important;
    transform: translateY(-1px);
    box-shadow: 0 20px 48px rgba(62, 28, 210, 0.44) !important;
}

/* Links */
body.login #login #nav {
    display: block !important;
    clear: both !important;
    margin: 0 !important;
    padding: 15px 0 0 !important;
    text-align: center !important;
    color: rgba(255, 255, 255, 0.54);
}

body.login #login #nav a {
    display: inline-block;
    color: rgba(255, 255, 255, 0.86) !important;
    font-size: 12px;
    font-weight: 500;
    text-decoration: none !important;
    margin-top: 15px !important;
}

body.login #login #nav a:hover {
    color: #fff !important;
}

body.login #backtoblog,
body.login .privacy-policy-page-link,
body.login .language-switcher {
    display: none !important;
}

/* Messages */
body.login #login .message,
body.login #login .notice,
body.login #login #login_error {
    margin: 0 0 18px;
    padding: 12px 14px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-right: 4px solid #704CFF;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.10);
    color: rgba(255, 255, 255, 0.90);
    box-shadow: none;
    font-size: 12px;
    line-height: 1.9;
}

body.login #login #login_error {
    border-right-color: #ff5d72;
}

body.login #login .message a,
body.login #login .notice a,
body.login #login #login_error a {
    color: #fff !important;
}

/* Nader / security captcha */
.aiowps-captcha-equation {
    direction: ltr;
}

.nader-captcha-container {
    margin: 15px 0;
    padding: 14px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.10);
}

.nader-captcha-container label {
    display: block;
    margin-bottom: 8px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.92);
}

.nader-captcha-image-container {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

#nader_captcha_image {
    border: 1px solid rgba(255, 255, 255, 0.24);
    border-radius: 8px;
    cursor: pointer;
}

.nader-captcha-refresh,
.nader-captcha-refresh-btn {
    border: 0;
    border-radius: 10px;
    background: rgba(62, 28, 210, 0.92);
    color: #fff;
    cursor: pointer;
}

.nader-captcha-refresh {
    padding: 6px 12px;
}

.nader-captcha-refresh:hover,
.nader-captcha-refresh-btn:hover {
    background: #3E1CD2;
}

#nader_captcha_code {
    width: 100%;
    padding: 8px;
    border: 1px solid rgba(255, 255, 255, 0.24);
    border-radius: 10px;
    box-sizing: border-box;
}

.nader-captcha-refresh-btn {
    font-size: 13px;
    padding: 10px;
}

/* Mobile */
@media (max-width: 760px) {
    body.login {
        background-attachment: scroll !important;
    }

    .ss-login-topbar {
        width: calc(100vw - 28px);
        margin-top: 14px;
    }

    .ss-login-topbar-inner {
        min-height: auto;
        padding: 12px;
        border-radius: 22px;
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }

    .ss-login-brand {
        justify-content: center;
    }

    .ss-login-brand img {
        width: 46px;
        height: 46px;
    }

    .ss-login-menu-list {
        justify-content: center;
        flex-wrap: wrap;
        gap: 6px;
    }

    .ss-login-menu-list a {
        min-height: 34px;
        padding: 6px 11px;
        font-size: 12px;
    }

    body.login #login {
        margin-top: 18px;
        padding: 24px 20px 22px;
        border-radius: 26px;
    }

    body.login #login h1 a {
        width: 56px !important;
        height: 56px !important;
    }

    .ss-login-intro h2 {
        font-size: 22px;
    }

    .ss-login-intro p {
        font-size: 12px;
        line-height: 1.75;
    }
}
/* Desktop layout fix - topbar out of document flow */
@media (min-width: 761px) {

    html,
    body.login.login-action-login {
        height: 100vh !important;
        min-height: 100vh !important;
        overflow-y: hidden !important;
    }

    body.login.login-action-login .ss-login-topbar {
        position: fixed !important;
        top: 18px !important;
        left: 50% !important;
        transform: translateX(-50%) !important;
        margin: 0 !important;
        z-index: 20 !important;
    }

    body.login.login-action-login #login {
        position: fixed !important;
        top: 124px !important;
        left: 50% !important;
        transform: translateX(-50%) !important;
        margin: 0 !important;
        z-index: 10 !important;
    }
}