
/* Custom CSS theme */
<!-- HTML for age verification pop-up -->
<div class="age-verification-container">
  <div class="age-verification">
    <h2>Are you over 18 years old?</h2>
    <button id="age-verification-yes">Yes</button>
    <button id="age-verification-no">No</button>
  </div>
</div>

<!-- CSS for age verification pop-up -->
<style>
  .age-verification-container {
    display: none;
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.4);
  } .age-verification{background-color:white;border:1px solid black;width:300px;margin:15% auto;padding:20px;text-align:center}
 
</style>
// JavaScript for age verification pop-up
const ageVerificationContainer = document.querySelector('.age-verification-container');
const ageVerificationYesButton = document.querySelector('#age-verification-yes');
const ageVerificationNoButton = document.querySelector('#age-verification-no');

ageVerificationYesButton.addEventListener('click', () => {
  // Set a cookie to remember that the user has passed the age verification check
  document.cookie = 'age_verified=true; expires=Fri, 31 Dec 9999 23:59:59 GMT';
  ageVerificationContainer.style.display = 'none';
} );

ageVerificationNoButton.addEventListener('click', () => {
  // Redirect the user to a different page
  window.location.href = 'https://example.com/age-restriction';
} );

 