/* Balcony platform scroll cue - a small "Scroll down" at the foot of a
   template's hero, telling a guest the invitation carries on below the first
   screen. Shown and hidden by _platform/scroll-cue.js.

   Markup, inside the (positioned) hero:
     <div class="scroll-cue" aria-hidden="true" data-after-cover data-delay="900">
       <span class="scroll-cue__text">Scroll down</span>
       <svg class="scroll-cue__arrow" viewBox="0 0 24 24" aria-hidden="true"><path d="M5 9l7 7 7-7"/></svg>
     </div>

   Light italic label over one bold, rounded chevron, straight on the
   picture - no panel behind it. A soft dark shadow keeps both legible over
   the light parts of a photo. A template sets its own look with:
     --scroll-cue-ink     text + chevron (default: warm white)
     --scroll-cue-shadow  the label's shadow, as text-shadow values
     --scroll-cue-arrow-shadow  the chevron's, as a filter value
     --scroll-cue-font    the label's face
     --scroll-cue-z       stacking within the hero
     --scroll-cue-gap     distance from the bottom edge */

.scroll-cue {
    --scroll-cue-shadow-default: 0 1px 2px rgb(0 0 0 / 0.35), 0 0 14px rgb(0 0 0 / 0.3);
    position: absolute;
    z-index: var(--scroll-cue-z, 9);
    left: 50%;
    /* At the hero's foot - but never below the first screen's. A hero can run
     past the fold (royale's wide still is as tall as its picture), and a cue
     there is one nobody sees until they have already scrolled. top: 100% is
     the hero's own height; min() takes whichever ends first. */
    top: calc(min(100%, 100vh) - var(--scroll-cue-gap, 22px));
    top: calc(min(100%, 100svh) - var(--scroll-cue-gap, 22px));
    transform: translate(-50%, -100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    color: var(--scroll-cue-ink, #fff8ee);
    font-family: var(--scroll-cue-font, "Cormorant Garamond", Georgia, serif);
    font-size: 23px;
    font-style: italic;
    font-weight: 600;
    line-height: 1;
    letter-spacing: 0.01em;
    white-space: nowrap;
    text-shadow: var(--scroll-cue-shadow, var(--scroll-cue-shadow-default));
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.6s ease;
}

.scroll-cue.is-shown {
    opacity: 1;
}

/* After .is-shown, so a guest who scrolled before the cue arrived never sees
   it at all. */

.scroll-cue.is-gone {
    opacity: 0;
}

/* The chevron, drawn rather than built from borders so its ends and corner
   are round, like a drawn stroke. drop-shadow() reads the same shadow the
   label carries - text-shadow does not reach an SVG, so it has its own
   --scroll-cue-arrow-shadow (a filter value; `none` to drop it). */

.scroll-cue__arrow {
    width: 30px;
    height: 30px;
    fill: none;
    stroke: currentColor;
    stroke-width: 3;
    stroke-linecap: round;
    stroke-linejoin: round;
    filter: var(--scroll-cue-arrow-shadow, drop-shadow(0 1px 2px rgb(0 0 0 / 0.35)) drop-shadow(0 0 6px rgb(0 0 0 / 0.25)));
    animation: scroll-cue-nudge 1.8s ease-in-out infinite;
}

/* A slow nudge downward - the direction it is asking the guest to go. */

@keyframes scroll-cue-nudge {
    0%,
    100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(5px);
    }
}

@media (prefers-reduced-motion: reduce) {
    .scroll-cue__arrow {
        animation: none;
    }
}