/* === Container Grid for the Choices === */
.image-radio-grid .gfield_radio {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
  list-style: none; /* May not be needed but safe to include */
  padding: 0;
  margin: 0;
}

/* === Each Choice Wrapper === */
.image-radio-grid .gchoice {
  flex: 0 1 calc(50% - 20px); /* Two columns on desktop/tablet */
  box-sizing: border-box;
  text-align: center;
  cursor: pointer;
}

/* === Hide Native Radio Button === */
.image-radio-grid input[type="radio"] {
  display: none;
}

/* === Style the Labels as Image Tiles === */
.image-radio-grid label {
  display: block;
  border: 2px solid transparent;
  border-radius: 10px;
  padding: 10px;
  aspect-ratio: 1 / 1;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  transition: border 0.3s ease, box-shadow 0.3s ease;
}

/* === Assign Background Images via nth-child === */
.image-radio-grid .gchoice:nth-child(1) label {
  background-image: url('/wp-content/themes/divi-child/quote-images/window.png');
}

.image-radio-grid .gchoice:nth-child(2) label {
  background-image: url('/wp-content/themes/divi-child/quote-images/door.png');
}

/* === Active Selection Styling === */
.image-radio-grid input[type="radio"]:checked + label {
  border: 2px solid #0073e6;
  box-shadow: 0 0 10px rgba(0, 115, 230, 0.4);
}

/* === Mobile Stacking (≤768px) === */
@media (max-width: 767px) {
  .image-radio-grid .gchoice {
	flex: 0 1 100%;
  }
}
