/* The arrows between the five pages (page-arrows.js): the smoky glass of the video controls in a
   small circle, at the middle of each side of the screen. */

.pa {
  position: fixed;
  top: 50%;
  z-index: 35;
  display: none;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  width: 40px;
  height: 40px;
  margin: 0;
  padding: 0;
  border: 1px solid rgba(255, 235, 205, .4);
  border-radius: 50%;
  background: rgba(18, 10, 5, .34);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  color: #FFF8EE;
  cursor: pointer;
  transform: translateY(-50%);
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  transition: background-color .3s ease, border-color .3s ease;
}
body.has-nav .pa { display: flex; }
body.has-nav .pa[hidden] { display: none; }
.pa--prev { left: calc(env(safe-area-inset-left, 0px) + 14px); }
.pa--next { right: calc(env(safe-area-inset-right, 0px) + 14px); }
.pa svg { width: 18px; height: 18px; filter: drop-shadow(0 1px 1px rgba(18, 10, 5, .55)); }
.pa:hover { background: rgba(18, 10, 5, .58); border-color: rgba(217, 165, 91, .8); }
.pa:focus-visible { outline: 1px solid #FFF8EE; outline-offset: 2px; }

/* A page's first visit: one soft movement outward and back. */
.pa--prev.is-nudging { --pa-out: -4px; animation: pa-nudge 1.5s ease-in-out .5s 2; }
.pa--next.is-nudging { --pa-out: 4px; animation: pa-nudge 1.5s ease-in-out .5s 2; }
@keyframes pa-nudge {
  0%, 100% { translate: 0; opacity: 1; }
  50% { translate: var(--pa-out) 0; opacity: .72; }
}

.pa-hint { display: none; }

@media (max-width: 720px) {
  .pa { width: 32px; height: 32px; }
  .pa svg { width: 16px; height: 16px; }
  .pa::after { content: ""; position: absolute; inset: -7px; border-radius: 50%; } /* a 44px touch area */

  /* Above the video controls, clear of the countdown. */
  .pa-hint {
    position: fixed;
    left: 0;
    right: 0;
    bottom: calc(var(--nav-h, 47px) + env(safe-area-inset-bottom, 0px) + 116px);
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin: 0;
    font: 500 9px/1 "Archivo", system-ui, sans-serif;
    letter-spacing: .3em;
    text-transform: uppercase;
    color: #FFF8EE;
    text-shadow: 0 1px 3px rgba(18, 10, 5, .7);
    pointer-events: none;
    opacity: 0;
    animation: pa-hint 4.5s ease 1.5s both;
  }
  .pa-hint span { font-size: 13px; letter-spacing: 0; }
}
@keyframes pa-hint {
  0%, 100% { opacity: 0; }
  15%, 80% { opacity: .85; }
}

@media (prefers-reduced-motion: reduce) {
  .pa.is-nudging { animation: none; }
  .pa { transition: none; }
}
