/* ── Animated login background ────────────────────────────────────────────── */

@keyframes ani-login-bg {
    0% {
        --ln-x-0: 20%;
        --ln-y-0: 30%;
        --ln-s0: 5%;
        --ln-e0: 55%;
        --ln-c-0: hsla(210, 70%, 82%, 1);
        --ln-x-1: 80%;
        --ln-y-1: 70%;
        --ln-s1: 8%;
        --ln-e1: 60%;
        --ln-c-1: hsla(205, 58%, 76%, 1);
        --ln-x-2: 55%;
        --ln-y-2: 10%;
        --ln-s2: 3%;
        --ln-e2: 45%;
        --ln-c-2: hsla(200, 65%, 87%, 1);
        --ln-x-3: 10%;
        --ln-y-3: 85%;
        --ln-s3: 5%;
        --ln-e3: 40%;
        --ln-c-3: hsla(153, 42%, 82%, 1);
        --ln-x-4: 75%;
        --ln-y-4: 18%;
        --ln-s4: 8%;
        --ln-e4: 50%;
        --ln-c-4: hsla(24, 55%, 86%, 1);
    }
    100% {
        --ln-x-0: 85%;
        --ln-y-0: 62%;
        --ln-s0: 10%;
        --ln-e0: 60%;
        --ln-c-0: hsla(210, 65%, 80%, 1);
        --ln-x-1: 15%;
        --ln-y-1: 22%;
        --ln-s1: 5%;
        --ln-e1: 65%;
        --ln-c-1: hsla(205, 62%, 78%, 1);
        --ln-x-2: 68%;
        --ln-y-2: 88%;
        --ln-s2: 8%;
        --ln-e2: 50%;
        --ln-c-2: hsla(200, 55%, 85%, 1);
        --ln-x-3: 42%;
        --ln-y-3: 48%;
        --ln-s3: 3%;
        --ln-e3: 38%;
        --ln-c-3: hsla(153, 36%, 80%, 1);
        --ln-x-4: 28%;
        --ln-y-4: 78%;
        --ln-s4: 12%;
        --ln-e4: 45%;
        --ln-c-4: hsla(24, 50%, 84%, 1);
    }
}

@property --ln-x-0 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 20%
}

@property --ln-y-0 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 30%
}

@property --ln-s0 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 5%
}

@property --ln-e0 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 55%
}

@property --ln-c-0 {
    syntax: '<color>';
    inherits: false;
    initial-value: hsla(210, 70%, 82%, 1)
}

@property --ln-x-1 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 80%
}

@property --ln-y-1 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 70%
}

@property --ln-s1 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 8%
}

@property --ln-e1 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 60%
}

@property --ln-c-1 {
    syntax: '<color>';
    inherits: false;
    initial-value: hsla(205, 58%, 76%, 1)
}

@property --ln-x-2 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 55%
}

@property --ln-y-2 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 10%
}

@property --ln-s2 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 3%
}

@property --ln-e2 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 45%
}

@property --ln-c-2 {
    syntax: '<color>';
    inherits: false;
    initial-value: hsla(200, 65%, 87%, 1)
}

@property --ln-x-3 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 10%
}

@property --ln-y-3 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 85%
}

@property --ln-s3 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 5%
}

@property --ln-e3 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 40%
}

@property --ln-c-3 {
    syntax: '<color>';
    inherits: false;
    initial-value: hsla(153, 42%, 82%, 1)
}

@property --ln-x-4 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 75%
}

@property --ln-y-4 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 18%
}

@property --ln-s4 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 8%
}

@property --ln-e4 {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 50%
}

@property --ln-c-4 {
    syntax: '<color>';
    inherits: false;
    initial-value: hsla(24, 55%, 86%, 1)
}

body {
    margin: 0;
    font-family: 'Arial', 'Segoe UI', -apple-system, BlinkMacSystemFont, 'Liberation Sans', sans-serif;
    background-color: hsla(210, 55%, 90%, 1);
    background-image: radial-gradient(circle at var(--ln-x-0) var(--ln-y-0), var(--ln-c-0) var(--ln-s0), transparent var(--ln-e0)),
    radial-gradient(circle at var(--ln-x-1) var(--ln-y-1), var(--ln-c-1) var(--ln-s1), transparent var(--ln-e1)),
    radial-gradient(circle at var(--ln-x-2) var(--ln-y-2), var(--ln-c-2) var(--ln-s2), transparent var(--ln-e2)),
    radial-gradient(circle at var(--ln-x-3) var(--ln-y-3), var(--ln-c-3) var(--ln-s3), transparent var(--ln-e3)),
    radial-gradient(circle at var(--ln-x-4) var(--ln-y-4), var(--ln-c-4) var(--ln-s4), transparent var(--ln-e4));
    background-attachment: fixed;
    animation: ani-login-bg 12s linear infinite alternate;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100dvh;
}

.login-container {
    position: relative;
    z-index: 1;
    background: rgba(255, 255, 255, 0.45);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    padding: 40px 36px;
    border-radius: 16px;
    width: 100%;
    max-width: 380px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.10);
}

.login-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    margin-bottom: 32px;
}

.login-brand img {
    height: 70px;
    width: auto;
}

.login-brand span {
    font-size: 2.4rem;
    font-weight: 700;
    color: #26547C;
    letter-spacing: -0.01em;
}

input[type="text"],
input[type="password"] {
    width: 100%;
    padding: 12px 14px;
    margin-bottom: 12px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    font-size: 1rem;
    font-family: inherit;
    background: #f8fafc;
    box-sizing: border-box;
    transition: border-color 0.15s;
}

input[type="text"]:focus,
input[type="password"]:focus {
    outline: none;
    border-color: #26547C;
    background: #fff;
}

.forgot-password {
    display: block;
    text-align: right;
    margin: -4px 0 20px;
    font-size: 0.85rem;
    color: #718096;
    text-decoration: none;
}

.forgot-password:hover {
    color: #26547C;
    text-decoration: underline;
}

.login-error {
    color: #c53030;
    font-size: 0.9rem;
    margin-bottom: 12px;
    display: none;
}

.login-btn {
    width: auto;
    justify-content: center;
}

.login-btn-row {
    display: flex;
    gap: 10px;
}

.login-btn-row .login-btn {
    width: auto;
    flex: 1;
}

.login-input-wrapper {
    position: relative;
    margin-bottom: 12px;
}

.login-input-wrapper input {
    width: 100%;
    box-sizing: border-box;
    padding-right: 76px;
    margin-bottom: 0;
}

.login-input-wrapper .btn {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    padding: 5px 10px;
    font-size: 0.8rem;
    line-height: 1;
}

.login-reveal {
    overflow: hidden;
    max-height: 0;
    opacity: 0;
    transition: max-height 0.3s ease, opacity 0.25s ease;
}

.login-reveal--visible {
    max-height: 200px;
    opacity: 1;
}

input[readonly] {
    opacity: 0.65;
    cursor: default;
}

.login-info {
    font-size: 0.9rem;
    color: #4a5568;
    margin: 0 0 16px;
    line-height: 1.5;
}

@media (max-width: 480px) {
    .login-container {
        background: none;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        box-shadow: none;
        border-radius: 0;
        padding: 24px 20px;
    }
}

.bg-decoration {
    position: fixed;
    bottom: 0;
    left: 0;
    min-height: 100%;
    opacity: 1;
    pointer-events: none;
    user-select: none;
    display: block;
    z-index: 0;
}
