I write server-side Kotlin at $DAYJOB, for several years.
Kotlin used to be a marked improvement over Java.
A series of large language changes, starting with JDK 16, have leveled the playing field somewhat.
Nowadays Java has Record types (data classes), sealed interfaces, pattern matching, etc.
Java's pattern matching actually got the ability to use guard clauses in match expressions BEFORE Kotlin implemented it:
https://kotlinlang.org/docs/whatsnew21.html#guard-conditions...
If Java had the ability to write free-floating functions outside of classes, and to declare function types succinctly like:
(String, Number) -> Number
It'd probably be on-par with Kotlin for me.