/* Core layout for explanation pages */
.explainer-wrapper {
  max-width: 960px;
  margin: 0 auto;
  padding: 2rem 1rem;
  font-family: 'Merriweather', serif;
  font-size: 1.05rem;
  line-height: 1.7;
  color: #3b2f2f;
}

/* Headings */
.explainer-wrapper h2 {
  font-family: 'Playfair Display', serif;
  font-size: 1.6rem;
  color: #5a2a27;
  margin-top: 2rem;
  margin-bottom: 1rem;
  text-align: left;
}

/* Lists */
.explainer-wrapper ul {
  list-style: disc inside;
  margin: 1rem 0;
  padding-left: 1rem;
}

.explainer-wrapper li {
  margin-bottom: 0.5rem;
}

/* Callout box for important notes */
.callout {
  background-color: #fdfaf5;
  border-left: 4px solid #c5a94f;
  padding: 1rem;
  margin: 1.5rem 0;
  font-size: 0.98rem;
  line-height: 1.6;
}

/* Contact section styled to match explainer */
.explainer-contact {
  background-color: #fdfaf5;
  padding: 2rem 0;
  border-top: 1px solid rgba(197,169,79,0.35);
}

.explainer-contact h2 {
  text-align: center;
  margin-bottom: 0.5rem;
}

.explainer-contact p {
  text-align: center;
  margin-bottom: 1.5rem;
}

.light-form {
  background-color: #fdfaf5;
  border-radius: 8px;
  padding: 0rem;
max-width: 700px;
max-height: 458px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.1);
}

/* Showcase layout */
.custom-showcase {
  display: flex;
  flex-direction: column;
  gap: 3rem;
  margin: 2rem 0;
}

.showcase-item {
  position: relative;
  display: flex;
  align-items: center;
  gap: 2rem;
  padding: 1.25rem;
  border-radius: 8px;
  overflow: hidden;
}
/* Add above to put examples in a subtle box:
  background-color: #fdfaf5; 
  box-shadow: 0 2px 40px rgba(0,0,0,0.08); 

Add below to enhance the same subltle box:
  background: radial-gradient(circle at 20% 20%, rgba(197,169,79,0.05), transparent 90%);
*/

/* Subtle gold accent wash */
.showcase-item::before {
  content: "";
  position: absolute;
  top: -20%;
  left: -10%;
  width: 140%;
  height: 140%;
  z-index: 0;
}
.showcase-item.reverse {
  flex-direction: row-reverse;
}

.showcase-text, .showcase-image {
  position: relative;
  z-index: 1;
}

.showcase-text {
  flex: 1;
}

.showcase-text h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.3rem;
  color: #5a2a27;
  margin-bottom: 0.5rem;
}

.showcase-text p {
  font-size: 1rem;
  line-height: 1.6;
}

.showcase-image {
  flex: 1;
  text-align: center;
}

.showcase-image img {
  max-width: 100%;
  border-radius: 6px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.15);
  transition: 1.0s ease;
}

.showcase-image img:hover {
  transform: scale(1.0);
}
.image-hover {
  position: relative;
  display: inline-block;
  overflow: hidden;
}

.image-hover img {
  display: block;
  width: 100%;
  height: auto;
  transition: opacity 0.7s ease-in-out;
}

.image-hover .after {
  position: absolute;
  top: 0;
  left: 0;
  opacity: 0; /* hidden initially */
}

.image-hover:hover .after {
  opacity: 1; /* fade in on hover */
}

.image-hover:hover .before {
  opacity: 0; /* fade out on hover */
}

/* Mobile adjustments */
@media (max-width: 768px) {
  .explainer-wrapper {
    padding: 1.5rem 1rem;
    font-size: 1rem;
  }

  .explainer-wrapper h2 {
    font-size: 1.4rem;
  }

  .showcase-item,
  .showcase-item.reverse {
    flex-direction: column;
    text-align: center;
    padding: 1rem;
  }

  /* Thumbnail sizing */
  .showcase-image {
    position: relative;
    display: inline-block;
    margin: 0.5rem auto;
    max-width: 45%;
    transition: max-width 0.7s ease-in-out; /* enlarge/shrink */
  }

  .showcase-image img {
    display: block;
    width: 100%;
    height: auto;
    transition: opacity 0.9s ease-in-out; /* fade */
  }

  .showcase-image .after {
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
  }

  /* Hover/active state: enlarge first, then fade */
  .showcase-image:hover {
    max-width: 85%;
  }

  .showcase-image:hover .after {
    opacity: 1;
    transition-delay: 0.3s; /* wait until enlarge finishes */
  }

  .showcase-image:hover .before {
    opacity: 0;
    transition-delay: 0.3s;
  }
}

@media (max-width: 480px) {
  .showcase-image {
    max-width: 40%;
  }
}
