/* Raft Flow: full-height version of the home page's Raft message panel.
   Same Paper Dithering shader + rotating phrase (dither-banner.js); the
   headline styling comes from .raft-message-text in styles.css. */
/* Opt in to the cross-document view transition from the home page panel. */
@view-transition { navigation: auto; }

.flow-panel {
  view-transition-name: raft-panel;
  position: relative;
  height: 100svh;
  overflow: hidden;
}

.flow-panel > [data-dither] {
  position: absolute;
  inset: 0;
}

/* The shared rule makes the text absolute-centred; reset h1 defaults. */
.flow-panel .raft-message-text {
  font-family: inherit;
}

/* Site URL sign-off (Paper: 36px / 900, centred, ~86% down the 951px frame). */
.flow-url {
  position: absolute;
  left: 50%;
  top: 86%;
  transform: translate(-50%, -50%);
  margin: 0;
  white-space: nowrap;
  text-transform: uppercase;
  font-size: min(36px, 4.4vw);
  font-weight: 900;
  line-height: 1.2;
  color: var(--bg-canvas);
}

/* Music pause/play: dark disc with a lime glyph so it reads on any part of the shader. */
.flow-audio-toggle {
  position: absolute;
  right: 24px;
  bottom: 24px;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid var(--text-accent);
  border-radius: 50%;
  background: var(--bg-canvas);
  color: var(--text-accent);
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.flow-audio-toggle:hover,
.flow-audio-toggle:focus-visible {
  background: var(--text-accent);
  color: var(--bg-canvas);
}

.flow-audio-toggle:focus-visible {
  outline: 2px solid var(--bg-canvas);
  outline-offset: 2px;
}

.flow-audio-icon--play,
.flow-audio-toggle.is-paused .flow-audio-icon--pause {
  display: none;
}

.flow-audio-toggle.is-paused .flow-audio-icon--play {
  display: block;
}

/* SoundCloud iframe stays off-screen; the site's own button controls it. */
.flow-audio-frame {
  position: absolute;
  left: -9999px;
  width: 300px;
  height: 166px;
  border: 0;
  opacity: 0;
  pointer-events: none;
}

/* Credit link required by the embed, kept small and tucked beside the button. */
.flow-audio-credit {
  position: absolute;
  right: 84px;
  bottom: 24px;
  height: 48px;
  margin: 0;
  display: flex;
  align-items: center;
  font-size: 12px;
  line-height: 1.2;
  color: var(--text-accent);
}

.flow-audio-credit a {
  color: inherit;
  text-decoration: none;
  padding: 4px 8px;
  border-radius: 999px;
  background: var(--bg-canvas);
}

.flow-audio-credit a:hover,
.flow-audio-credit a:focus-visible {
  text-decoration: underline;
}

/* The URL sign-off links home; keep it looking like type, underline on hover/focus. */
.flow-url a {
  color: inherit;
  text-decoration: none;
}

.flow-url a:hover,
.flow-url a:focus-visible {
  text-decoration: underline;
  text-decoration-thickness: 3px;
  text-underline-offset: 6px;
}

/* Minimize: mirror of the home panel's expand button, top-right. */
.flow-minimize {
  position: absolute;
  right: 24px;
  top: 24px;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border: 1.5px solid var(--text-accent);
  border-radius: 50%;
  background: var(--bg-canvas);
  color: var(--text-accent);
  transition: transform 0.15s, background 0.15s, color 0.15s;
}

.flow-minimize:hover,
.flow-minimize:focus-visible {
  transform: scale(1.08);
  background: var(--text-accent);
  color: var(--bg-canvas);
}
