What does the `protected` access modifier do in Java?
The `protected` modifier allows access to a variable or method only within the same class and package.
You're partially correct, but `protected` also allows access in subclasses, even if they are in different packages.
Can you describe how `protected` works with inheritance and why it's not as restrictive as `private`?