/* Sections with two photo columns and one text column: from 769px to 1279px the three columns sat side by
   side and squeezed the text into a narrow strip. There, put the two photos side by side on top and the
   text full width underneath. The photos are background images with no height of their own, so give
   their columns one. */
@media (min-width: 769px) and (max-width: 1279px) {
  [data-photo-text-row] { flex-wrap: wrap !important; }
  [data-photo-text-row] > [data-photo-col] { order: 0; width: 50% !important; max-width: 50% !important; flex: 0 0 50% !important; min-height: clamp(320px, 50vw, 560px); }
  [data-photo-text-row] > [data-text-col] { order: 1; width: 100% !important; max-width: 100% !important; flex: 0 0 100% !important; }
  /* Photo / text / photo sections (bathroom, whole-house "Designed Specifically For You"): first photo with
     the text beside it, second photo full width underneath */
  [data-photo-text-row]:has(> [data-text-col]:nth-child(2)) > [data-photo-col]:first-child { order: 0; }
  [data-photo-text-row]:has(> [data-text-col]:nth-child(2)) > [data-text-col] { order: 1; width: 50% !important; max-width: 50% !important; flex: 0 0 50% !important; display: flex; flex-direction: column; justify-content: center; }
  [data-photo-text-row]:has(> [data-text-col]:nth-child(2)) > [data-photo-col]:last-child { order: 2; width: 100% !important; max-width: 100% !important; flex: 0 0 100% !important; min-height: clamp(320px, 45vw, 520px); }
  /* Two-column sections that read better as one column here: kitchen remodeling process steps; whole-house
     "Looking For a Professional Contractor" text; home additions "The Process of Building Home Additions"
     (heading and photos, then the steps); whole-house services and "Our Unique Process" (photo on top,
     text underneath); Tributer Bay "The Cutalong Lifestyle" (text, then video) and "Custom Homes Designed for the Cutalong
     Lifestyle" (photo on top) */
  [data-stack-tablet] { flex-wrap: wrap !important; }
  [data-stack-tablet] > * { width: 100% !important; max-width: 100% !important; flex: 0 0 100% !important; }
  /* a stacked background photo (whole-house services and "Our Unique Process"; home additions "Is Your Current
     Home Not Working For You?" and "Second-Story Home Addition"
     and "Master Bedroom Addition") goes first, with a height of its own */
  [data-stack-tablet] > [data-photo-col] { order: -1; min-height: clamp(320px, 45vw, 520px); }
  /* stacked media (Tributer Bay "The Cutalong Lifestyle" video, "Building in a Premier Lake Anna Community"
     photos) goes after the text, as on phones. A video is shown at 16:9 rather than the square box the theme
     gives it, which would be taller than the screen at full width */
  [data-stack-tablet] > [data-media-col] { order: 1; }
  [data-stack-tablet] > [data-media-col] :has(> iframe) { aspect-ratio: 16 / 9 !important; height: auto !important; }
  [data-stack-tablet] > [data-media-col] iframe { width: 100%; height: 100% !important; }
  /* sections with no bottom padding here (Tributer Bay "Custom Homes Designed for the Cutalong Lifestyle"):
     90px, as from 1280px */
  [data-pad-bottom-tablet] { padding-bottom: 90px !important; }
  /* Three columns where the last one moves to its own full-width row (Fine Details "We Aren't Just Building
     a House": heading and first text side by side, second text underneath) */
  [data-wrap-last-tablet] { flex-wrap: wrap !important; }
  [data-wrap-last-tablet] > :not(:last-child) { width: 50% !important; max-width: 50% !important; flex: 0 0 50% !important; }
  [data-wrap-last-tablet] > :last-child { width: 100% !important; max-width: 100% !important; flex: 0 0 100% !important; }
}
