.image-text-new-wrapper {
    padding: 0px;
    position: relative;
    overflow: hidden;
}
.image-text-new-wrapper::after {
  background-color: #534340;
  content: "";
  background-image: url('https://www.highchaparral.se/wp-content/uploads/2025/01/paper-texture-web.jpg');
  background-size: cover; /* Ensures the image covers the entire background */
  background-position: center; /* Centers the image */
  background-repeat: no-repeat; /* Prevents the image from repeating */
  background-blend-mode: multiply;
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  z-index: -1;
}

.image-text-new {
    display: flex;
    background-color: transparent;
    max-width: 1200px;
    margin: 50px auto;
    overflow: hidden;
    z-index: 3;
    position: relative;
}

.image-text-corner-tl {
    position: absolute;
    top: 20px;
    left: 20px;
    width: 50px;
    height: auto; 
    z-index: 2;
    pointer-events: none;
}
.image-text-corner-tr {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 50px;
    height: auto; 
    z-index: 2;
    pointer-events: none;
}
.image-text-corner-bl {
    position: absolute;
    bottom: 20px;
    left: 20px;
    width: 50px;
    height: auto; 
    z-index: 2;
    pointer-events: none;
}
.image-text-corner-br {
    position: absolute;
    bottom: 20px;
    right: 20px;
    width: 50px;
    height: auto; 
    z-index: 2;
    pointer-events: none;
}
.image-text-new__text {
    flex: 1;
    padding: 50px;
    background: transparent;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    position: relative;
}

.image-text-new__text h2 {
    font-size: 2rem;
    margin-bottom: 10px;
    margin-top: 0;
    color: #f7f2e7;
}

.image-text-new__text p {
    font-size: 1.1rem;
    line-height: 1.5;
    margin-bottom: 20px;
    color: #f7f2e7;
}

.image-text-new__image {
    flex: 1;
    position: relative;
      /* Apply mask from 4 ripped edge images */
      -webkit-mask-image: url('https://www.highchaparral.se/wp-content/themes/hc-theme/img/ripped-paper-mask.png');
      mask-image: url('https://www.highchaparral.se/wp-content/themes/hc-theme/img/ripped-paper-mask.png');
    
      /* Optional: control positioning and size */
      -webkit-mask-repeat: no-repeat;
      mask-repeat: no-repeat;
    
      -webkit-mask-size: 100% 100%;
      mask-size: 100% 100%;
    
      /* Optional: improve performance and rendering */
      -webkit-mask-position: center;
      mask-position: center;
}
.image-text-new-rip {
    width: 40px;
    height: auto;
    position: absolute;
    left: -20px;
    top: -100px;
}

.image-text-new__image .image-text-new-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.image-text-Dirt_dark-top {
    position: absolute;
    top: -4px;
    left: 0;
    width: 100%;
    height: auto;
    opacity: .035;
    pointer-events: none; /* decorative, do not intercept mouse/focus */
}
.image-text-Dirt_dark-left  {
    position: absolute;
    bottom: 0;
    left: 0;
    width: auto;
    height: 100%;
    opacity: .035;
    pointer-events: none; /* decorative */
}
.image-text-Dirt_dark-right  {
    position: absolute;
    bottom: 0;
    right: 0;
    width: auto;
    height: 100%;
    opacity: .035;
    pointer-events: none; /* decorative */
}
.image-text-Dirt_dark-bottom {
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 100%;
    height: auto;
    opacity: .035;
    pointer-events: none; /* decorative */
}
  
.image-text-new-wrapper.style-dark .button--primary {
  background-color: #fff;
  color: #222;
}
  
.image-text-new-wrapper.style-accent {
  background-color: #ffe0b2;
  color: #4e2600;
}
  
.image-text-new-wrapper.style-accent .button--primary {
  background-color: #ff9800;
  color: #fff;
}
  
.image-text-new-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 2rem auto;
  max-width: 90%;
}
  
.image-text-new-divider .divider-left,
.image-text-new-divider .divider-right {
  flex: 2;
  max-width: 400px;
}
  
.image-text-new-divider .divider-icon {
  max-width: 200px;
  flex: 1;
  margin: 0 1rem;
}

/* ================================
   WCAG 2.2 ADDITIONS
   - focus visibility & not obscured
   - minimum target size
   - visually-hidden utility
   - reduced motion guard
================================== */

/* Visually hidden utility (for screen-reader-only hints like “opens in a new tab”) */
.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

/* Focus visible: ensure strong outlines */
.image-text-new-wrapper .button--primary:focus-visible,
.image-text-new-wrapper a:focus-visible {
  outline: 3px solid currentColor;
  outline-offset: 3px;
  scroll-margin: 1rem; /* helps when sticky headers exist */
}

/* Target size ≥ 44x44 for interactive controls */
.image-text-new-wrapper .button--primary,
.image-text-new-wrapper a.button {
  min-height: 44px;
  min-width: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Reduced motion: if animations/transitions are later added here */
@media (prefers-reduced-motion: reduce) {
  .image-text-new,
  .image-text-new__image,
  .image-text-new__image .image-text-new-img,
  .image-text-Dirt_dark-top,
  .image-text-Dirt_dark-left,
  .image-text-Dirt_dark-right,
  .image-text-Dirt_dark-bottom {
    animation: none !important;
    transition: none !important;
  }
}

@media (max-width: 768px) {
    .image-text-new {
        flex-direction: column-reverse;
        max-width: 100%;
        margin: 25px;
    }
    .image-text-new-rip {
        display: none;
    }    
    .image-text-new__text {
        padding: 30px 0px;
    }
    .image-text-new__text h2{
        font-size: 1.7rem;
    }
    .image-text-new__text p {
        font-size: 1rem;
    }
    .image-text-corner-tl, .image-text-corner-tr, .image-text-corner-bl, .image-text-corner-br {
        display: none;
    }
}
