/* ==========================================================================
   Holiday home page: photo slideshow hero + guided photo walk (v2-house.js).
   Uses the v2 tokens only (v2.css). Loaded by v2/content/vakantiehuis.php.
   ========================================================================== */

/* ---------- Shared round control ---------- */
.v2-round { position: relative; display: inline-grid; place-items: center; width: 44px; height: 44px; padding: 0; border-radius: 50%; border: 1px solid rgba(255, 255, 255, 0.4); background: rgba(var(--scrim), 0.55); color: #fff; transition: background 200ms var(--ease), color 200ms var(--ease), border-color 200ms var(--ease), scale 200ms var(--ease); }
.v2-round:hover { background: #fff; color: var(--brand); border-color: #fff; }
.v2-round:active { scale: 0.94; }
.v2-round--lg { width: 56px; height: 56px; }
.v2-icon { width: 20px; height: 20px; }
.v2-round--lg .v2-icon { width: 24px; height: 24px; }

/* ---------- Hero slideshow ---------- */
.v2-hero--slides { padding-bottom: clamp(8rem, 12vw, 9.5rem); }
.v2-hero--slides::before {
    background:
        linear-gradient(90deg, rgba(var(--scrim), 0.72) 0%, rgba(var(--scrim), 0.38) 42%, rgba(var(--scrim), 0) 72%),
        linear-gradient(0deg, rgba(var(--scrim), 0.82) 0%, rgba(var(--scrim), 0.15) 40%, rgba(var(--scrim), 0) 62%, rgba(var(--scrim), 0.35) 100%);
}
.v2-slides { background: var(--brand); }
.v2-slide { position: absolute; inset: 0; margin: 0; opacity: 0; transition: opacity 1400ms var(--ease); }
.v2-slide.is-current { opacity: 1; }
.v2-slide img, .v2-slide picture { width: 100%; height: 100%; object-fit: cover; }
.v2-slide.is-current img { animation: v2-slide-settle 9s cubic-bezier(0.16, 1, 0.3, 1) both; }
@keyframes v2-slide-settle { from { scale: 1; } to { scale: 1.06; } }

@media (min-width: 701px) { body.v2 .v2-hero--slides h1 { letter-spacing: -0.03em; } }
.v2-hero--slides .v2-hero__bullets { gap: 0.4rem 0; }
.v2-hero--slides .v2-hero__bullets li { padding-right: 1.1rem; margin-right: 1.1rem; border-right: 1px solid rgba(255, 255, 255, 0.28); }
.v2-hero--slides .v2-hero__bullets li:last-child { border-right: 0; margin-right: 0; padding-right: 0; }
.v2-hero--slides .v2-hero__bullets li::before { display: none; }
.v2-hero--slides .v2-btn--ghost-light::after { content: none; }

.v2-slides__ui { position: absolute; inset: auto 0 0 0; z-index: 2; padding-bottom: clamp(1rem, 2.4vw, 1.75rem); color: #fff; }
.v2-slides__bar { display: flex; align-items: center; justify-content: flex-end; gap: 1.25rem; margin-bottom: 1rem; }
.v2-slides__caption { margin: 0 !important; font-size: 0.9rem; color: rgba(255, 255, 255, 0.86); text-align: right; text-wrap: balance; }
.v2-slides__count { margin-right: 0.6rem; color: #fff; font-weight: 500; }
.v2-slides__buttons { display: flex; gap: 0.5rem; }
[data-v2-slides-ui] [data-toggle] .v2-icon:last-child, [data-v2-slides-ui].is-paused [data-toggle] .v2-icon:first-child { display: none; }
[data-v2-slides-ui].is-paused [data-toggle] .v2-icon:last-child { display: block; }

/* One segment per photo; the running segment's fill is the slideshow's clock (v2-house.js waits for it). */
.v2-slides__progress { display: flex; gap: 0.4rem; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.v2-slides__progress button { flex: 1; display: flex; align-items: center; min-height: 24px; padding: 0; border: 0; background: none; }
.v2-slides__progress span { position: relative; flex: 1; height: 3px; border-radius: 3px; background: rgba(255, 255, 255, 0.3); overflow: hidden; transition: background 200ms var(--ease); }
.v2-slides__progress button:hover span { background: rgba(255, 255, 255, 0.55); }
.v2-slides__progress span::after { content: ''; position: absolute; inset: 0; background: #fff; transform-origin: left center; scale: 0 1; }
.v2-slides__progress .is-past span::after { scale: 1 1; }
.v2-slides__progress [aria-current="true"] span::after { animation: v2-slide-clock var(--v2-slide-ms, 6500ms) linear forwards; }
.is-paused .v2-slides__progress [aria-current="true"] span::after, .is-held .v2-slides__progress [aria-current="true"] span::after { animation-play-state: paused; }
@keyframes v2-slide-clock { from { scale: 0 1; } to { scale: 1 1; } }

/* ---------- Guided walk ---------- */
@property --v2-feather { syntax: '<percentage>'; inherits: false; initial-value: 0%; }
.v2-walk { --focus: #fff; background: var(--brand); color: #fff; padding: clamp(4.5rem, 9vw, 7rem) 0 clamp(3.5rem, 7vw, 5.5rem); overflow: hidden; }
.v2-walk__head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 1rem 3rem; }
body.v2 .v2-walk__head h2 { color: #fff; margin: 0; max-width: 14ch; }
.v2-walk__head p { margin: 0 !important; max-width: 46ch; color: rgba(255, 255, 255, 0.78); font-size: 1.0625rem; }

.v2-walk__stage { position: relative; width: min(100% - 2 * var(--gutter), 1440px); margin: clamp(2rem, 4vw, 3rem) auto 0; aspect-ratio: 3 / 2; max-height: calc(100svh - 8.5rem); scroll-margin-top: 1.25rem; /* html has scroll-padding-top: 6rem */ border-radius: var(--radius); overflow: hidden; background: #001b36; box-shadow: 0 40px 80px -40px rgba(0, 0, 0, 0.6); isolation: isolate; }
.v2-walk__stage:focus-visible { outline: 2px solid #fff; outline-offset: 4px; }
.v2-walk__stage::after { content: ''; position: absolute; inset: auto 0 0 0; height: 48%; z-index: 1; pointer-events: none; background: linear-gradient(0deg, rgba(0, 20, 41, 0.86) 0%, rgba(0, 20, 41, 0.35) 55%, rgba(0, 20, 41, 0) 100%); }
.v2-walk__scene { position: absolute; inset: 0; perspective: 1000px; perspective-origin: 50% 45%; overflow: hidden; touch-action: pan-y; cursor: grab; user-select: none; }
.v2-walk__scene:active { cursor: grabbing; }
.v2-walk__stop { position: absolute; inset: 0; margin: 0; opacity: 0; visibility: hidden; transform-style: preserve-3d; backface-visibility: hidden; }
.v2-walk__stop.is-current, .v2-walk__stop.is-moving { visibility: visible; }
.v2-walk__stop.is-current { opacity: 1; }
/* Pointer parallax lives on the frame, the WAAPI camera move on the stop, the slow push-in on the image. */
.v2-walk__frame { position: absolute; inset: -3%; transform: rotateX(var(--tilt-x, 0deg)) rotateY(var(--tilt-y, 0deg)); transition: transform 700ms var(--ease); }
.v2-walk__frame img, .v2-walk__frame picture { width: 100%; height: 100%; object-fit: cover; }
.v2-walk__stop.is-current .v2-walk__frame img { animation: v2-walk-drift 18s cubic-bezier(0.16, 1, 0.3, 1) both; }
@keyframes v2-walk-drift { from { scale: 1; } to { scale: 1.07; } }

.v2-walk__hud { position: absolute; z-index: 2; left: clamp(1.25rem, 3.5vw, 2.75rem); bottom: clamp(1.25rem, 3.5vw, 2.5rem); right: 7rem; max-width: 38rem; pointer-events: none; }
.v2-walk__hud.is-swap > * { animation: v2-hud-in 650ms cubic-bezier(0.16, 1, 0.3, 1) both; }
.v2-walk__hud.is-swap > :nth-child(2) { animation-delay: 60ms; }
.v2-walk__hud.is-swap > :nth-child(3) { animation-delay: 120ms; }
@keyframes v2-hud-in { from { opacity: 0; translate: 0 10px; } }
.v2-walk__chapter { margin: 0 0 0.35rem !important; font-size: 0.85rem; font-weight: 500; color: rgba(255, 255, 255, 0.72); }
.v2-walk__title { margin: 0 0 0.35rem !important; font-family: var(--display); font-weight: 500; font-size: clamp(1.6rem, 3.2vw, 2.75rem); line-height: 1.05; letter-spacing: -0.025em; color: #fff; text-wrap: balance; }
.v2-walk__caption { margin: 0 !important; font-size: 0.975rem; color: rgba(255, 255, 255, 0.84); text-wrap: pretty; }
.v2-walk__count { position: absolute; z-index: 2; top: clamp(1rem, 2.5vw, 1.5rem); left: clamp(1.25rem, 3.5vw, 2.75rem); margin: 0 !important; padding: 0.3rem 0.65rem; border-radius: 999px; background: rgba(var(--scrim), 0.55); font-size: 0.8125rem; font-weight: 500; }
.v2-walk__prev, .v2-walk__next { position: absolute; z-index: 2; top: 50%; translate: 0 -50%; }
.v2-walk__prev { left: clamp(0.75rem, 2vw, 1.5rem); }
.v2-walk__next { right: clamp(0.75rem, 2vw, 1.5rem); }
.v2-walk__full { position: absolute; z-index: 2; top: clamp(1rem, 2.5vw, 1.5rem); right: clamp(1rem, 2.5vw, 1.5rem); }
.v2-walk__full .v2-icon:last-child, .v2-walk__stage.is-full .v2-walk__full .v2-icon:first-child { display: none; }
.v2-walk__stage.is-full .v2-walk__full .v2-icon:last-child { display: block; }
.v2-walk__stage:fullscreen { width: 100vw; height: 100vh; max-height: none; aspect-ratio: auto; margin: 0; border-radius: 0; }

/* Route: every stop, grouped per chapter, as direct jumps. */
.v2-walk__route { margin-top: 1.5rem; }
.v2-walk__route > ol { display: flex; gap: 1.75rem; overflow-x: auto; padding: 0.5rem 0.25rem 1rem; list-style: none; scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, 0.35) transparent; overscroll-behavior-x: contain; mask-image: linear-gradient(90deg, #000 0, #000 calc(100% - 4rem), transparent); }
.v2-walk__leg { flex: none; list-style: none; }
.v2-walk__leg > p { margin: 0 0 0.6rem !important; font-size: 0.8125rem; font-weight: 500; color: rgba(255, 255, 255, 0.72); }
.v2-walk__leg ol { display: flex; gap: 0.5rem; list-style: none; }
.v2-walk__leg li { list-style: none; }
.v2-walk__route button { display: flex; flex-direction: column; gap: 0.4rem; width: 108px; padding: 0; border: 0; background: none; color: rgba(255, 255, 255, 0.78); font-size: 0.8125rem; line-height: 1.25; text-align: left; }
.v2-walk__route button picture, .v2-walk__route button img { display: block; width: 108px; height: 72px; object-fit: cover; border-radius: 8px; }
.v2-walk__route button img { opacity: 0.55; outline: 2px solid transparent; outline-offset: 2px; transition: opacity 250ms var(--ease), outline-color 250ms var(--ease); }
.v2-walk__route button:hover img { opacity: 0.85; }
.v2-walk__route button[aria-current="step"] { color: #fff; }
.v2-walk__route button[aria-current="step"] img { opacity: 1; outline-color: #fff; }
.v2-walk__route button:focus-visible { outline: 2px solid #fff; outline-offset: 4px; border-radius: 8px; }

/* ---------- Small screens ---------- */
@media (max-width: 700px) {
    .v2-slides__caption [data-caption] { display: none; }
    /* "Vakantiehuis Waterlelie" keeps one line on 375px phones (it had ~2px to spare at 2.6rem). */
    body.v2 .v2-hero--slides h1 { font-size: clamp(2.2rem, 9.6vw, 2.6rem); }
    .v2-slides__bar { justify-content: space-between; }
    .v2-hero--slides .v2-hero__bullets li { border-right: 0; margin-right: 0; padding-right: 0; }
    /* Phones: the photo keeps its landscape frame and the room text sits in a band below it, not over it. */
    .v2-walk__stage { aspect-ratio: auto; max-height: none; }
    .v2-walk__stage::after { display: none; }
    .v2-walk__scene { position: relative; aspect-ratio: 4 / 3; }
    .v2-walk__hud { position: relative; left: auto; right: auto; bottom: auto; min-height: 7rem; padding: 1rem 7.75rem 1.25rem 1.25rem; }
    .v2-walk__title { font-size: 1.45rem; }
    .v2-walk__caption { font-size: 0.9rem; }
    .v2-walk__prev, .v2-walk__next { top: auto; bottom: 1.25rem; translate: none; width: 48px; height: 48px; }
    .v2-walk__prev { left: auto; right: 4.6rem; }
    .v2-walk__next { right: 1rem; }
    .v2-walk__stage:fullscreen { display: flex; flex-direction: column; justify-content: center; }
    .v2-walk__route button, .v2-walk__route button picture, .v2-walk__route button img { width: 88px; }
    .v2-walk__route button picture, .v2-walk__route button img { height: 60px; }
}

/* ---------- Reduced motion: no drift, no camera moves (v2-house.js crossfades), no auto-advance ---------- */
@media (prefers-reduced-motion: reduce) {
    .v2-slide.is-current img, .v2-walk__stop.is-current .v2-walk__frame img, .v2-walk__hud.is-swap > * { animation: none; }
    .v2-walk__frame { transform: none; transition: none; }
}

/* ---------- Forced colors ---------- */
@media (forced-colors: active) {
    .v2-round { border: 1px solid ButtonText; }
    .v2-slides__progress span { background: GrayText; forced-color-adjust: none; }
    .v2-slides__progress span::after { background: CanvasText; }
}

/* ---------- Mobile sticky "book a boat" pill: out of the way while the walk is on screen ---------- */
body.v2.v2-walk-in-view .v2-sticky-book { transform: translateY(150%); }

/* ---------- Heerlijke Huisjes embed (shared component): no kicker, fallback link first, poster while loading ---------- */
.v2-house-embed .vh-section-eyebrow { display: none; }
.v2-house-embed .hh-booking-panel { display: flex; flex-direction: column; gap: 0.75rem; }
.v2-house-embed .hh-booking-panel-note { order: -1; margin: 0; }
.v2-house-embed iframe { background: linear-gradient(rgba(247, 242, 233, 0.5), rgba(247, 242, 233, 0.5)), url('/frontend/Images/Vakantiehuis/1-800w.webp') center / cover no-repeat, var(--paper-deep); }
.v2-house-embed .hh-booking-panel-note { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.25rem 0.75rem; }
.v2-house-embed .hh-booking-panel-note > a[data-house-outbound] { order: -1; font-weight: 500; }
.v2-house-embed .hh-booking-panel-sep { display: none; }
.v2-embed-loading { position: absolute; left: 50%; z-index: 1; translate: -50% -50%; margin: 0 !important; padding: 0.7rem 1.1rem; border-radius: 999px; background: var(--surface); box-shadow: var(--shadow); font-size: 0.95rem; font-weight: 500; color: var(--ink); pointer-events: none; }
