Same caveat applies to the "checkbox hack" or any other pure CSS solution. You cannot create accessible versions of most complex controls like tabs without JavaScript.
(That first example could be created semantically and accessibly with <details> / <summary> though!)
for "accessible", do you mean getting focused when pressing TAB key?
what about, make it work in pure html and css, and enrich it with js to make it accessible?
rather than not working at all with js disabled