*{
    margin:0;
    padding:0;
    box-sizing:border-box;
    font-family:'Segoe UI',sans-serif;
}

/* Forgot password page */
.forgot-card .forgot-hidden{display:none;}
.forgot-back{margin-top:14px;text-align:center;}
.forgot-back a{color:#5a6fff;text-decoration:none;font-size:12px;font-weight:600;}
.forgot-back a:hover{text-decoration:underline;}
.login-hidden{display:none!important;}

.totp-user-card{
    display:flex;
    align-items:center;
    gap:12px;
    margin:2px 0 18px;
    padding:10px 12px;
    border-radius:14px;
    background:rgba(255,255,255,0.46);
    border:1px solid rgba(180,195,255,0.34);
}

.totp-avatar{
    width:46px;
    height:46px;
    border-radius:14px;
    overflow:hidden;
    display:flex;
    align-items:center;
    justify-content:center;
    color:#70809f;
    background:rgba(255,255,255,0.86);
    box-shadow:0 4px 18px rgba(80,100,200,0.10);
    flex:0 0 auto;
}

.totp-avatar img{
    width:100%;
    height:100%;
    object-fit:cover;
    display:block;
}

.totp-avatar svg{
    width:60%;
    height:60%;
}

.totp-user-name{
    color:#121935;
    font-size:14px;
    font-weight:800;
    line-height:1.2;
}

.totp-user-sub{
    margin-top:2px;
    color:#7180a4;
    font-size:11.5px;
    font-weight:500;
}

.otp-boxes{
    display:grid;
    grid-template-columns:repeat(6, 1fr);
    gap:1px;
    height:46px;
    overflow:hidden;
    border-radius:4px;
    background:rgba(255,255,255,0.78);
    border:1px solid rgba(210,218,238,0.78);
}

.otp-digit{
    min-width:0;
    width:100%;
    height:46px;
    border:0;
    border-right:1px solid rgba(210,218,238,0.9);
    outline:none;
    background:rgba(248,250,255,0.88);
    color:#101730;
    text-align:center;
    font-size:18px;
    font-weight:800;
    font-family:'Segoe UI',sans-serif;
}

.otp-digit:last-child{
    border-right:0;
}

.otp-digit:focus{
    background:#fff;
    box-shadow:inset 0 0 0 2px rgba(90,110,255,0.32);
}

html,body{
    width:100%;
    min-height:100%;
    overflow-x:hidden;
}

body{
    min-height:100vh;
    display:flex;
    justify-content:center;
    align-items:center;
    padding:80px 20px;
    position:relative;
    color:#1a1f36;

    background:
        radial-gradient(ellipse at 20% 20%, rgba(180,200,255,0.55) 0%, transparent 45%),
        radial-gradient(ellipse at 80% 80%, rgba(200,175,255,0.45) 0%, transparent 45%),
        radial-gradient(ellipse at 60% 10%, rgba(150,220,255,0.35) 0%, transparent 40%),
        linear-gradient(135deg, #dde8ff 0%, #eae4ff 40%, #d8eeff 100%);

    background-repeat:no-repeat;
    background-size:cover;
    background-attachment:fixed;
}

/* gloss overlay */
body::after{
    content:"";
    position:fixed;
    inset:0;
    background:
        radial-gradient(ellipse at 50% 0%, rgba(255,255,255,0.6) 0%, transparent 60%);
    pointer-events:none;
    z-index:0;
}

/* subtle grid texture */
body::before{
    content:"";
    position:fixed;
    inset:0;
    background:
        repeating-linear-gradient(
            90deg,
            rgba(100,130,255,.04) 0px,
            rgba(100,130,255,.04) 1px,
            transparent 1px,
            transparent 70px
        ),
        repeating-linear-gradient(
            0deg,
            rgba(100,130,255,.04) 0px,
            rgba(100,130,255,.04) 1px,
            transparent 1px,
            transparent 70px
        );
    pointer-events:none;
    z-index:0;
}

/* glow blobs */
.glow{
    position:fixed;
    border-radius:50%;
    filter:blur(120px);
    pointer-events:none;
    z-index:0;
}

.glow1{
    width:550px;
    height:550px;
    background:rgba(100,140,255,0.3);
    top:-200px;
    left:-150px;
}

.glow2{
    width:450px;
    height:450px;
    background:rgba(160,100,255,0.25);
    right:-120px;
    bottom:-150px;
}

.glow3{
    width:350px;
    height:350px;
    background:rgba(80,200,255,0.2);
    top:30%;
    right:15%;
}

/* logo */
.top-logo{
    position:fixed;
    top:22px;
    left:24px;
    display:flex;
    align-items:center;
    gap:14px;
    z-index:100;
}

.logo-box{
    width:50px;
    height:50px;
    border-radius:10px;
    overflow:hidden;
    background:rgba(255,255,255,0.7);
    border:1px solid rgba(255,255,255,0.9);
    backdrop-filter:blur(10px);
    box-shadow:0 4px 20px rgba(80,100,255,0.12);
}

.logo-box img{
    width:100%;
    height:100%;
    object-fit:cover;
}

.logo-text{
    font-size:20px;
    font-weight:600;
    color:#1a2040;
}

.logo-text .red{
    color:#e03030;
}

/* login card */
.login-card{
    width:100%;
    max-width:390px;
    padding:36px 32px;
    border-radius:28px;

    background:rgba(255,255,255,0.55);
    border:1px solid rgba(255,255,255,0.85);
    backdrop-filter:blur(28px);

    box-shadow:
        0 8px 40px rgba(80,100,200,0.13),
        0 2px 0 rgba(255,255,255,0.9) inset,
        0 -1px 0 rgba(180,190,255,0.2) inset;

    position:relative;
    z-index:10;
}

/* top gloss strip on card */
.login-card::before{
    content:"";
    position:absolute;
    top:0; left:10%; right:10%;
    height:1px;
    background:linear-gradient(90deg, transparent, rgba(255,255,255,1), transparent);
    border-radius:50%;
}

.login-card h1{
    font-size:30px;
    line-height:1.15;
    margin-bottom:4px;
    font-weight:800;
    color:#0f1535;
}

.login-card h1 span{
    background:linear-gradient(90deg,#4060ff,#8b3fff);
    -webkit-background-clip:text;
    -webkit-text-fill-color:transparent;
    background-clip:text;
}

.subtitle{
    color:#6b7a9e;
    font-size:13.5px;
    line-height:1.65;
    margin-bottom:28px;
}

.input-group{
    margin-bottom:18px;
}

label{
    display:block;
    margin-bottom:8px;
    font-size:12.5px;
    font-weight:600;
    color:#3a4268;
    letter-spacing:.3px;
}

.row{
    display:flex;
    justify-content:space-between;
    align-items:center;
    margin-bottom:10px;
}

.forgot{
    color:#5a6fff;
    text-decoration:none;
    font-size:12px;
    font-weight:500;
}

/* inputs */
.input-box{
    width:100%;
    height:50px;
    padding:14px 18px;
    border:none;
    outline:none;
    border-radius:14px;
    background:rgba(255,255,255,0.7);
    border:1.5px solid rgba(180,195,255,0.5);
    color:#1a2040;
    font-size:13px;
    font-weight:500;
    transition:.25s;
    box-shadow:0 2px 8px rgba(80,100,200,0.06) inset;
}

.input-box:focus{
    border:1.5px solid rgba(90,110,255,0.6);
    box-shadow:0 0 0 4px rgba(90,110,255,0.1);
    background:rgba(255,255,255,0.9);
}

.input-box::placeholder{
    color:#9aa5c4;
    font-size:11.5px;
    font-weight:400;
    letter-spacing:.2px;
}

/* button */
.login-btn{
    width:100%;
    height:50px;
    border:none;
    border-radius:14px;
    background:linear-gradient(90deg,#4f6dff,#943cff);
    color:white;
    font-size:15px;
    font-weight:700;
    cursor:pointer;
    transition:.25s;
    box-shadow:
        0 10px 30px rgba(100,80,255,0.3),
        0 1px 0 rgba(255,255,255,0.25) inset;
    letter-spacing:.3px;
    position:relative;
    overflow:hidden;
}

.login-btn::before{
    content:"";
    position:absolute;
    top:0; left:0; right:0;
    height:50%;
    background:rgba(255,255,255,0.12);
    border-radius:14px 14px 50% 50%;
}

.login-btn:hover{
    transform:translateY(-2px);
    box-shadow:0 16px 40px rgba(100,80,255,0.4);
}

.login-btn:disabled{
    cursor:not-allowed;
    transform:none;
}

.login-btn-content{
    position:relative;
    z-index:1;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    gap:8px;
}

.login-spinner{
    width:16px;
    height:16px;
    border-radius:50%;
    border:2px solid rgba(255,255,255,0.35);
    border-top-color:#fff;
    display:none;
    animation:loginSpin .75s linear infinite;
}

.login-check{
    display:none;
    width:18px;
    height:18px;
    align-items:center;
    justify-content:center;
    animation:loginCheck .28s ease-out;
}

.login-btn.is-loading .login-spinner{
    display:inline-block;
}

.login-btn.is-success .login-check{
    display:inline-flex;
}

@keyframes loginSpin{to{transform:rotate(360deg)}}
@keyframes loginCheck{from{opacity:0;transform:scale(.7)}to{opacity:1;transform:scale(1)}}

.login-message{
    margin-top:12px;
    text-align:center;
    font-size:12px;
    font-weight:600;
    line-height:1.45;
    color:#d93232;
    opacity:0;
    transform:translateY(-4px);
    transition:opacity .25s, transform .25s;
    pointer-events:none;
}

.login-message.show{
    opacity:1;
    transform:translateY(0);
}

.login-message.success{
    color:#315cff;
}

.login-message .full-name{
    display:block;
    margin-top:2px;
    color:#1a2040;
    font-weight:700;
}

/* footer */
.footer{
    position:fixed;
    left:0;
    bottom:0;
    width:100%;
    padding:13px 24px;
    background:rgba(230,235,255,0.72);
    border-top:1px solid rgba(180,195,255,0.45);
    backdrop-filter:blur(20px);
    z-index:100;
}

.footer-row{
    display:flex;
    justify-content:space-between;
    align-items:center;
    gap:20px;
}

.footer-left{
    display:flex;
    flex-wrap:wrap;
    align-items:center;
    gap:10px;
    color:#4a5580;
    font-size:12px;
}

.footer-right{
    white-space:nowrap;
    font-size:12px;
    color:#4a5580;
}

.footer-right strong{
    color:#1a2040;
}

.sep{
    color:#aab0cc;
}

.footer-val{
    transition:opacity .3s;
}

.footer-val.loading{
    opacity:.35;
}

/* responsive */
@media(max-width:768px){
    body{ padding:90px 16px 80px; }
    .top-logo{ top:18px; left:16px; }
    .logo-box{ width:42px; height:42px; }
    .logo-text{ font-size:17px; }
    .login-card{ max-width:100%; padding:26px 20px; border-radius:22px; }
    .login-card h1{ font-size:26px; }
    .subtitle{ font-size:13px; margin-bottom:20px; }
    .input-box{ height:46px; font-size:12px; }
    .input-box::placeholder{ font-size:10.5px; }
    .login-btn{ height:46px; font-size:14px; }
    .footer{ padding:10px 14px; }
    .footer-left{ font-size:10px; gap:6px; max-width:72%; }
    .footer-right{ font-size:10px; text-align:right; }
}
