/* WalesMap page transitions — entry fade + departure overlay */

/* Entry: very soft fade-in on page load — removes the hard flash, not a
   noticeable animation. 0.28s is short enough to feel instant on fast
   connections while eliminating the snapshot-swap feel on slower ones. */
@keyframes wm-enter {
    from { opacity: 0; }
    to   { opacity: 1; }
}

body {
    animation: wm-enter 0.28s ease-out both;
}

/* Departure overlay: full-screen dark surface that fades in before the
   browser navigates, giving a cinematic warm-to-dark exit. */
.wm-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: var(--ink, #071615);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    will-change: opacity;
}

.wm-overlay.is-active {
    opacity: 1;
    pointer-events: all;
}

/* Reduced motion: remove all animation; links navigate instantly */
@media (prefers-reduced-motion: reduce) {
    body {
        animation: none;
    }

    .wm-overlay {
        transition: none;
    }
}
