export function getEmailVerifiedFromClaims(claims) {
  if (!claims) return false;
  // Keycloak/OIDC standard:
  if (typeof claims.email_verified === "boolean") return claims.email_verified;
  // Some apps mistakenly use camelCase:
  if (typeof claims.emailVerified === "boolean") return claims.emailVerified;
  // Rare: string "true"/"false"
  if (typeof claims.email_verified === "string") return claims.email_verified === "true";
  if (typeof claims.emailVerified === "string") return claims.emailVerified === "true";
  return false;
}
