/**
 * Auto-hiding sticky header styles.
 *
 * Targets the existing sticky header markup (header.wp-block-template-part
 * containing a .is-position-sticky group) without touching theme files.
 * The selector is intentionally scoped to elements that are already
 * position: sticky so we never affect non-sticky headers.
 */
.tct-auto-hide-header.is-position-sticky {
	transition: transform 0.3s ease-in-out;
	will-change: transform;
}

.tct-auto-hide-header.tct-header--hidden {
	transform: translateY(-100%);
}

/* Always show the header again once any of its content receives focus,
 * e.g. keyboard navigation through the menu, so it stays accessible. */
.tct-auto-hide-header.tct-header--hidden:focus-within {
	transform: translateY(0);
}

/* Respect users who prefer reduced motion. */
@media (prefers-reduced-motion: reduce) {
	.tct-auto-hide-header {
		transition: none;
	}
}
