@Override
		public void paintBorder( Component c, Graphics g, int x, int y, int width, int height ) {
			Window window = SwingUtilities.windowForComponent( c );
			boolean active = window != null && window.isActive();
			boolean dark = FlatLaf.isLafDark();

			g.setColor( active
				? (activeColor != null ? activeColor : (dark ? activeDarkColor : activeLightColor))
				: (dark ? inactiveDarkColor : inactiveLightColor) );
			HiDPIUtils.paintAtScale1x( (Graphics2D) g, x, y, width, height, this::paintImpl );
		}
Window top border used on Windows 10.
No longer needed since Windows 11.
flatlaf-core/src/main/java/com/formdev/flatlaf/ui/FlatNativeWindowBorder.java