/* Real estate (plan.md, the niche pages). Layout F: the clip in a tall frame at the left (two calm clips in the kit's
   rotate), `fillcal` on glass over the frame's foot, under the faces, the words at the right. The outcomes, the tour,
   the questions and the close are shared (design\components.css, "the niche pages"). Tokens only. */

/* ---------- the header ---------- */
.reh { padding-block: clamp(1.5rem, 1rem + 2vh, 2.5rem) clamp(3.5rem, 2rem + 6vh, 6rem); }
.reh__grid { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); align-items: center; gap: clamp(2rem, 1rem + 4vw, 5rem); }
.reh__frame { position: relative; height: 600px; border-radius: var(--radius-l); background: var(--c-paper-alt); box-shadow: var(--shadow-l); }
.reh__media { position: absolute; inset: 0; overflow: hidden; border-radius: inherit; }

/* the kit's header (kit.md), as it gives it */
[data-kit-scene="rotate"] [data-kit-slide] { position: absolute; inset: 0; margin: 0; visibility: hidden; overflow: hidden; }
[data-kit-scene="rotate"] [data-kit-slide][data-kit-on] { visibility: visible; z-index: 2; opacity: var(--kit-move, 1); transform: translateX(var(--kit-glide, calc((1 - var(--kit-move, 1)) * 4%))); }
[data-kit-scene="rotate"]:not(:has([data-kit-slide][data-prev])) [data-kit-slide][data-kit-on] { transform: none; opacity: 1; }
[data-kit-scene="rotate"] [data-kit-slide][data-prev] { visibility: visible; z-index: 1; }
[data-kit-scene="rotate"] [data-kit-slide] video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: var(--pos, 50% 50%); }
[data-kit-scene="rotate"]:not(:has([data-kit-slide][data-kit-on])) [data-kit-slide]:not([data-kit-slide] ~ [data-kit-slide]) { visibility: visible; }
[data-kit-scene="rotate"] [data-kit-slide] video { inset: -1px; width: calc(100% + 2px); height: calc(100% + 2px); max-width: none; clip-path: inset(2px); }
[data-kit-scene="rotate"] [data-kit-slide] video[data-kit-shown] { clip-path: none; }
[data-kit-scene="rotate"] [data-kit-slide][data-prev] { opacity: clamp(0, (1 - var(--kit-move, 0)) * 1000, 1); }

/* the grade: one still layer, a soft navy toward the foot under the glass */
.reh__media::after { content: ""; position: absolute; inset: 0; z-index: 3; pointer-events: none; background: linear-gradient(180deg, transparent 45%, color-mix(in srgb, var(--c-brand) 28%, transparent) 100%); }
.reh__stop { top: 16px; right: 16px; }
/* the week filling with listing appointments, hanging off the frame's lower right corner (the faces end at 45% of
   the frame), into the gap before the words */
.scene.reh__scene { position: absolute; z-index: 4; right: -60px; bottom: -64px; width: 440px; }
.reh__frame { margin-bottom: 64px; }
.reh__words .ph__title { font-size: clamp(2.3rem, 1.5rem + 2.8vw, 3.9rem); }

/* ---------- the phone ---------- */
@media (max-width: 899.98px) {
  .reh__grid { grid-template-columns: minmax(0, 1fr); }
  .reh__frame { height: 520px; margin-bottom: 0; }
  .scene.reh__scene { left: 12px; right: 12px; bottom: 12px; width: auto; }
  /* the close: the family in a square photo, their faces high, the card under them */
  .re-close .closer__media, .re-close .closer__over { aspect-ratio: 1; }
  .re-close .closer__media { --pos: 80% 40% !important; }
}
@media (max-width: 759.98px) {
  .scene.reh__scene { left: 10px; right: 10px; bottom: 10px; }
}
@media (min-width: 900px) and (max-width: 1099.98px) {
  .scene.reh__scene { right: -40px; width: 380px; }
}
