.login-card {
    width: 100%;
    max-width: 420px;
    position: relative;
    overflow: hidden;
    border-radius: 22px;
    padding: 24px;
}

.login-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 82% 12%, rgba(174, 216, 255, 0.14), transparent 34%),
        radial-gradient(circle at 12% 8%, rgba(0, 146, 135, 0.22), transparent 32%);
    pointer-events: none;
}

.login-card > * {
    position: relative;
    z-index: 1;
}

.login-orbit {
    position: absolute;
    top: -96px;
    right: -86px;
    width: 178px;
    height: 178px;
    border: 1px solid rgba(174, 216, 255, 0.20);
    border-radius: 50%;
    opacity: 0.9;
}

.login-orbit span {
    position: absolute;
    border-radius: 50%;
    background: var(--primary);
    box-shadow: 0 0 26px rgba(0, 146, 135, 0.45);
}

.login-orbit span:nth-child(1) {
    width: 10px;
    height: 10px;
    top: 36px;
    left: 22px;
}

.login-orbit span:nth-child(2) {
    width: 7px;
    height: 7px;
    right: 34px;
    bottom: 28px;
    background: var(--atom-blue);
}

.login-orbit span:nth-child(3) {
    width: 5px;
    height: 5px;
    left: 78px;
    bottom: 10px;
    background: var(--warning-gold);
}

.login-header {
    text-align: left;
    margin-bottom: 16px;
}

.logo-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}

.logo-mark {
    width: 38px;
    height: 38px;
    border-radius: 13px;
    display: grid;
    place-items: center;
    background: var(--primary-gradient);
    color: #FFFFFF;
    font-size: 19px;
    font-weight: 800;
    box-shadow: 0 14px 26px rgba(0, 146, 135, 0.22);
}

.login-header .logo {
    font-size: 25px;
    font-weight: 800;
    color: var(--primary);
    letter-spacing: 0;
}

.login-header .subtitle {
    width: fit-content;
    color: var(--primary-light);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: uppercase;
    padding: 5px 9px;
    border-radius: 999px;
    border: 1px solid rgba(0, 146, 135, 0.28);
    background: rgba(0, 146, 135, 0.10);
    margin-bottom: 10px;
}

.login-header h1 {
    margin: 0;
    color: var(--heading-text);
    font-size: clamp(23px, 3vw, 30px);
    line-height: 1.08;
    letter-spacing: 0;
}

.login-copy {
    margin-top: 8px;
    color: var(--secondary-text);
    font-size: 13px;
    line-height: 1.4;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.login-form .input-field,
.login-form .btn-primary,
.login-form .btn-secondary,
.app-download-btn {
    height: 46px;
    border-radius: 14px;
}

.login-form .btn-primary,
.login-form .btn-secondary,
.app-download-btn {
    font-size: 15px;
    padding: 0 18px;
}

.login-form .form-label {
    font-size: 13px;
}

.login-form .forgot-link {
    text-align: right;
    margin-top: -12px;
}

.login-footer {
    text-align: center;
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid var(--block-stroke);
}

.login-footer p {
    color: var(--secondary-text);
    font-size: 12px;
    line-height: 1.35;
}

.app-download-btn {
    margin-top: 8px;
    text-decoration: none;
}

[data-theme="light"] .login-card::before {
    background:
        radial-gradient(circle at 82% 12%, rgba(77, 163, 255, 0.12), transparent 34%),
        radial-gradient(circle at 12% 8%, rgba(0, 146, 135, 0.14), transparent 32%);
}

@media (prefers-reduced-motion: no-preference) {
    .login-card {
        animation: loginCardIn 0.42s cubic-bezier(.2, .8, .2, 1) both;
    }

    .login-orbit {
        animation: orbitDrift 5.8s ease-in-out infinite alternate;
    }
}

@keyframes loginCardIn {
    from {
        opacity: 0;
        transform: translateY(14px) scale(0.985);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes orbitDrift {
    from { transform: rotate(-5deg) translateY(0); }
    to { transform: rotate(7deg) translateY(8px); }
}

@media (max-width: 480px) {
    .main-content {
        min-height: 100svh;
        padding: 12px;
    }

    .theme-toggle {
        top: 10px;
        right: 10px;
        width: 38px;
        height: 38px;
    }

    .login-card {
        max-width: 100%;
        padding: 18px 16px;
        border-radius: 18px;
    }

    .login-header {
        margin-bottom: 14px;
    }

    .login-header h1 {
        font-size: 21px;
    }

    .login-copy {
        font-size: 12px;
    }

    .login-form {
        gap: 10px;
    }

    .login-form .input-field,
    .login-form .btn-primary,
    .login-form .btn-secondary,
    .app-download-btn {
        height: 40px;
    }
}

@media (max-height: 700px) {
    .main-content {
        align-items: flex-start;
        padding-top: 10px;
        padding-bottom: 10px;
    }

    .login-card {
        padding-top: 16px;
        padding-bottom: 16px;
    }

    .logo-wrap {
        margin-bottom: 8px;
    }

    .login-header .subtitle {
        margin-bottom: 8px;
    }

    .login-copy {
        display: none;
    }

    .login-footer {
        margin-top: 10px;
        padding-top: 10px;
    }
}

@media (max-width: 380px), (max-height: 620px) {
    .login-header .subtitle,
    .login-footer p {
        display: none;
    }

    .login-header h1 {
        font-size: 20px;
    }

    .login-footer {
        border-top: 0;
        padding-top: 0;
    }
}
