
/* Make the first section overlap the hero without creating a gap */
main.content > section:first-of-type {
  margin-top: 0 !important;        /* kill any layout gap */
  background: transparent !important;  /* do not paint white over hero */
  position: relative;
  z-index: 0;
}

/* Reveal animation: visual offset only (no layout gap) */
.reveal {
  opacity: 0;
  transform: translateY(64px);
  transition:
    transform 700ms cubic-bezier(.2,.7,0,1),
    opacity 500ms ease-out;
  will-change: transform, opacity;
  position: relative;
  z-index: 0;
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* While offset for reveal, ensure it doesn't sit above the hero */
.reveal:not(.in-view) {
  position: relative;
  z-index: 0 !important;   /* do not let it stack over the hero */
  background: transparent !important; /* don’t paint white while overlapping */
}





 /* Mobile-friendly stack 
 @media (max-width: 768px) {
     .book-content {
         flex-direction: column;
     }
 }
*/






/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  .book-image, .book-carousel {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}




/* Mobile: stack date above details 
@media (max-width: 768px) {
  .events-table .date { 
    width: auto; 
    text-align: left; 
    padding-right: 0; 
    margin-bottom: 0.25rem; 
    display: block; 
  }
  .events-table td { 
    display: block; 
    width: 100%; 
    padding: 1rem 0; 
  }

}
*/

@media (max-width: 640px) {
  .contact-form .row { flex-direction: column; }
  .subscribe-form { flex-direction: column; align-items: stretch; }
}








/* Mobile: stack date above details */
@media (max-width: 768px) {
  .events-table .date { 
    width: auto; 
    text-align: left; 
    padding-right: 0; 
    margin-bottom: 0.25rem; 
    display: block; 
  }
  .events-table td { 
    display: block; 
    width: 100%; 
    padding: 1rem 0; 
  }

}


@media (max-width: 640px) {
  .contact-form .row { flex-direction: column; }
  .subscribe-form { flex-direction: column; align-items: stretch; }
}


	
	
	/* Reveal: default upward */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: transform 560ms cubic-bezier(.2,.9,.2,1), opacity 420ms ease-out;
  will-change: transform, opacity;
  /* ensure layout doesn't jump */
  backface-visibility: hidden;
}

/* When in view */
.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* Book section: horizontal inward reveals */
/* Left column slides in from left */
.reveal--left {
  transform: translateX(-36px);
  transition: transform 560ms cubic-bezier(.2,.9,.2,1), opacity 420ms ease-out;
}

/* Right column slides in from right */
.reveal--right {
  transform: translateX(36px);
  transition: transform 560ms cubic-bezier(.2,.9,.2,1), opacity 420ms ease-out;
}

/* When revealed */
.reveal--left.in-view,
.reveal--right.in-view {
  transform: translateX(0);
  opacity: 1;
}

/* Keep upward + horizontal consistent when both are present */
.reveal.reveal--left.in-view,
.reveal.reveal--right.in-view { transform: translateX(0); }

/* Optional small responsive tweak: reduce travel on small screens */
@media (max-width: 640px) {
  .reveal { transform: translateY(12px); }
  .reveal--left, .reveal--right { transform: translateX(18px); }
}