/* MOCKUP — aesthetic link-in-bio (e-z.bio style) */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  height: 100%;
  background: var(--bg-void);
  color: var(--text-primary);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

body {
  min-height: 100dvh;
  cursor: auto;
  /* stacking: bg layer must stay ABOVE body paint (never negative z-index) */
  isolation: isolate;
}

/* —— Background —— */
.stage {
  position: relative;
  z-index: 10;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2.5rem 1.25rem 2rem;
  isolation: isolate;
}

/* Fullscreen background — z-index 0 (NOT negative: negative hides behind body fill) */
.bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  background-color: var(--onyx);
  background-repeat: no-repeat;
  background-position: center center;
  background-size: cover;
  pointer-events: none;
}

.bg-gradient {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% 18%, rgba(var(--candy-blue-rgb), 0.16), transparent 55%),
    radial-gradient(ellipse 70% 50% at 80% 80%, rgba(var(--candy-blue-rgb), 0.08), transparent 50%),
    radial-gradient(ellipse 60% 40% at 15% 70%, rgba(var(--candy-blue-rgb), 0.1), transparent 45%),
    linear-gradient(180deg, #050505 0%, var(--onyx) 50%, #000000 100%);
  background-size: cover;
  animation: bg-shift 18s ease-in-out infinite alternate;
  z-index: 0;
}

/* When media is set: hide solid gradient so image/video is visible */
body[data-bg-mode="image"] .bg-gradient,
body[data-bg-mode="video"] .bg-gradient,
.bg.has-media .bg-gradient {
  opacity: 0;
  visibility: hidden;
  animation: none;
  pointer-events: none;
}

body[data-bg-mode="image"] .orbs,
body[data-bg-mode="video"] .orbs,
.bg.has-media ~ .orbs {
  opacity: 0.2;
}

.bg-media {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  z-index: 1;
  display: block;
  /* animated GIFs: keep GPU-friendly full-bleed */
  image-rendering: auto;
}

/* Prefer <img> layer for GIFs so animation stays smooth */
.bg.is-gif .bg-media.bg-image {
  z-index: 2;
}

.bg-media[hidden] {
  display: none !important;
}

.bg-video {
  min-width: 100%;
  min-height: 100%;
}

/* Blurred full-bleed clone — fills pillarbox when main video is contain */
.bg-video-blur {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  z-index: 1;
  pointer-events: none;
  border: 0;
  /* Scale past edges so blur softens, no hard crop line */
  transform: scale(1.14);
  filter: blur(32px) brightness(0.52) saturate(1.15);
  opacity: 1;
}

.bg-video-blur[hidden] {
  display: none !important;
}

/*
 * Video fill modes (MP4/WebM):
 * cover  = fill screen, crop edges (default landscape)
 * contain = full frame sharp in center + blurred cover behind (no black bars)
 * auto is resolved in JS → sets cover or contain on body
 */
body[data-bg-video-fit="contain"] .bg-media.bg-video {
  object-fit: contain;
  object-position: center center;
  min-width: 0;
  min-height: 0;
  width: 100%;
  height: 100%;
  background: transparent;
  z-index: 2;
}

body[data-bg-video-fit="cover"] .bg-media.bg-video {
  object-fit: cover;
  min-width: 100%;
  min-height: 100%;
  z-index: 1;
}

body[data-bg-video-fit="cover"] .bg-video-blur {
  display: none !important;
}

/* YouTube as pure background: crop player chrome hard (controls, logo, bars) */
.bg-youtube-wrap {
  position: absolute;
  inset: 0;
  z-index: 1;
  overflow: hidden;
  pointer-events: none;
}

.bg-youtube-wrap[hidden] {
  display: none !important;
}

/* Soft edge masks — remaining YouTube UI at top/bottom stays off the visible stage */
.bg-youtube-wrap::before,
.bg-youtube-wrap::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  z-index: 3;
  pointer-events: none;
}

.bg-youtube-wrap::before {
  top: 0;
  height: min(14vh, 110px);
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.72), transparent);
}

.bg-youtube-wrap::after {
  bottom: 0;
  height: min(20vh, 140px);
  background: linear-gradient(to top, rgba(0, 0, 0, 0.78), transparent);
}

.bg-youtube {
  border: 0;
  pointer-events: none !important;
  /* Fill cover + strong scale: pushes YT transport/logo outside the crop box */
  width: 100vw;
  height: 56.25vw;
  min-height: 100vh;
  min-width: 177.78vh;
  top: 50%;
  left: 50%;
  right: auto;
  bottom: auto;
  transform: translate(-50%, -50%) scale(1.65);
  transform-origin: center center;
  object-fit: unset;
}

/* Hide public chrome while in dashboard */
body[data-view="dashboard"] .public-only,
body[data-view="dashboard"] #view-public {
  display: none !important;
}

.bg-dim {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background:
    radial-gradient(ellipse 70% 55% at 50% 40%, rgba(0, 0, 0, 0.12), rgba(0, 0, 0, 0.42) 100%),
    linear-gradient(180deg, rgba(0, 0, 0, 0.28) 0%, transparent 32%, rgba(0, 0, 0, 0.4) 100%);
}

/* Photo / video backgrounds: strength comes from the dashboard slider
   (--bg-dim-strength, 0–1). The first layer is a soft scrim directly behind
   the content column — without it the middle stays the brightest spot on
   screen, which is exactly where name + avatar sit. */
body[data-bg-mode="image"] .bg-dim,
body[data-bg-mode="video"] .bg-dim {
  background:
    radial-gradient(
      ellipse 38% 46% at 50% 48%,
      rgba(0, 0, 0, calc(0.62 * var(--bg-dim-strength))),
      transparent 72%
    ),
    radial-gradient(
      ellipse 65% 50% at 50% 42%,
      rgba(0, 0, 0, calc(0.30 * var(--bg-dim-strength))),
      rgba(0, 0, 0, calc(0.68 * var(--bg-dim-strength))) 100%
    ),
    linear-gradient(
      180deg,
      rgba(0, 0, 0, calc(0.42 * var(--bg-dim-strength))) 0%,
      rgba(0, 0, 0, calc(0.18 * var(--bg-dim-strength))) 35%,
      rgba(0, 0, 0, calc(0.55 * var(--bg-dim-strength))) 100%
    );
}

.bg-debug {
  position: fixed;
  bottom: 1rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 60;
  max-width: min(420px, 92vw);
  padding: 0.65rem 0.9rem;
  border-radius: 12px;
  background: rgba(2, 2, 2, 0.9);
  border: 1px solid rgba(var(--candy-blue-rgb), 0.35);
  color: var(--candy-blue);
  font-size: 0.75rem;
  text-align: center;
  line-height: 1.4;
}

.bg::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.06'/%3E%3C/svg%3E");
  opacity: 0.35;
  pointer-events: none;
  mix-blend-mode: overlay;
}

/* Top-left: mute + volume slider */
.audio-dock {
  position: fixed;
  top: max(1rem, env(safe-area-inset-top, 0px));
  left: max(1rem, env(safe-area-inset-left, 0px));
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 0;
  pointer-events: auto;
  padding-right: 0.35rem;
}

.audio-dock .mute-fab {
  position: relative;
  top: auto;
  left: auto;
  flex-shrink: 0;
}

/* Volume pill: hidden until hover / focus on dock (desktop) */
.public-volume {
  display: flex;
  align-items: center;
  margin: 0;
  max-width: 0;
  opacity: 0;
  overflow: hidden;
  padding: 0.35rem 0;
  border-radius: 999px;
  background: rgba(2, 2, 2, 0.45);
  border: 1px solid transparent;
  backdrop-filter: blur(14px) saturate(1.2);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  box-shadow: none;
  transform: translateX(-6px);
  pointer-events: none;
  transition:
    max-width 0.28s var(--ease-out),
    opacity 0.22s ease,
    padding 0.28s var(--ease-out),
    border-color 0.22s ease,
    box-shadow 0.22s ease,
    transform 0.28s var(--ease-out),
    margin 0.28s var(--ease-out);
}

.public-volume input[type="range"] {
  width: min(120px, 28vw);
  min-width: min(120px, 28vw);
  height: 4px;
  margin: 0;
  accent-color: var(--candy-blue);
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.18s ease 0.05s;
}

/*
 * Desktop: only while mouse is over the dock. No :focus-within (that kept
 * the slider open until an outside click blurred the range input).
 */
@media (hover: hover) and (pointer: fine) {
  .audio-dock:hover .public-volume,
  .audio-dock.is-volume-open .public-volume {
    max-width: 160px;
    opacity: 1;
    margin-left: 0.55rem;
    padding: 0.35rem 0.65rem 0.35rem 0.45rem;
    border-color: rgba(var(--candy-blue-rgb), 0.22);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    transform: translateX(0);
    pointer-events: auto;
  }

  .audio-dock:hover .public-volume input[type="range"],
  .audio-dock.is-volume-open .public-volume input[type="range"] {
    opacity: 1;
  }
}

@media (hover: none), (pointer: coarse) {
  .public-volume {
    max-width: 160px;
    opacity: 1;
    margin-left: 0.55rem;
    padding: 0.35rem 0.65rem 0.35rem 0.45rem;
    border-color: rgba(var(--candy-blue-rgb), 0.22);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    transform: none;
    pointer-events: auto;
  }
  .public-volume input[type="range"] {
    opacity: 1;
  }
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.views-row {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  margin: 0.15rem 0 1.1rem;
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: rgba(var(--theme-meta-rgb), var(--theme-meta-alpha));
  text-shadow:
    0 1px 3px rgba(0, 0, 0, 0.85),
    0 0 14px rgba(var(--theme-meta-rgb), 0.35);
}

.meta-brand-corner {
  position: fixed;
  bottom: max(1.35rem, env(safe-area-inset-bottom, 0px));
  right: max(1.25rem, env(safe-area-inset-right, 0px));
  z-index: 30;
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: rgba(var(--theme-meta-rgb), var(--theme-meta-alpha));
  text-shadow:
    0 1px 3px rgba(0, 0, 0, 0.85),
    0 0 14px rgba(var(--theme-meta-rgb), 0.35);
  pointer-events: none;
  user-select: none;
}

.meta-brand-corner[hidden] {
  display: none !important;
}

/* e-z style mute control — glass pill + candy blue glow when playing */
.mute-fab {
  position: fixed;
  top: max(1rem, env(safe-area-inset-top, 0px));
  left: max(1rem, env(safe-area-inset-left, 0px));
  z-index: 40;
  width: 48px;
  height: 48px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: var(--text-primary);
  display: grid;
  place-items: center;
  cursor: pointer;
  isolation: isolate;
  transition: transform 0.18s var(--ease-out);
}

.mute-fab-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1px solid rgba(var(--candy-blue-rgb), 0.22);
  background: rgba(2, 2, 2, 0.45);
  backdrop-filter: blur(14px) saturate(1.2);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  box-shadow:
    0 4px 20px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  transition:
    border-color 0.2s,
    box-shadow 0.2s,
    background 0.2s,
    transform 0.2s;
}

.mute-fab-inner {
  position: relative;
  z-index: 1;
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
}

.mute-fab svg {
  width: 22px;
  height: 22px;
  display: block;
  grid-area: 1 / 1;
  transition: opacity 0.15s, transform 0.15s, color 0.15s;
}

.mute-fab:hover {
  transform: scale(1.06);
}

.mute-fab:hover .mute-fab-ring {
  border-color: rgba(var(--candy-blue-rgb), 0.55);
  box-shadow:
    0 0 22px rgba(var(--candy-blue-rgb), 0.25),
    0 4px 20px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.mute-fab:active {
  transform: scale(0.96);
}

/* Music playing */
.mute-fab:not(.is-muted) {
  color: var(--onyx);
}

.mute-fab:not(.is-muted) .mute-fab-ring {
  border-color: rgba(var(--candy-blue-rgb), 0.65);
  background: linear-gradient(
    145deg,
    rgba(var(--candy-blue-rgb), 0.95),
    rgba(143, 196, 216, 0.88)
  );
  box-shadow:
    0 0 0 3px rgba(var(--candy-blue-rgb), 0.15),
    0 0 28px rgba(var(--candy-blue-rgb), 0.4),
    0 4px 16px rgba(0, 0, 0, 0.3);
  animation: mute-pulse 2.4s ease-in-out infinite;
}

.mute-fab:not(.is-muted):hover .mute-fab-ring {
  box-shadow:
    0 0 0 4px rgba(var(--candy-blue-rgb), 0.2),
    0 0 34px rgba(var(--candy-blue-rgb), 0.5),
    0 4px 16px rgba(0, 0, 0, 0.3);
}

/* Muted */
.mute-fab.is-muted {
  color: rgba(var(--candy-blue-rgb), 0.75);
}

.mute-fab.is-muted .mute-fab-ring {
  background: rgba(2, 2, 2, 0.55);
  border-color: rgba(255, 255, 255, 0.14);
}

@keyframes mute-pulse {
  0%,
  100% {
    box-shadow:
      0 0 0 3px rgba(var(--candy-blue-rgb), 0.12),
      0 0 22px rgba(var(--candy-blue-rgb), 0.32),
      0 4px 16px rgba(0, 0, 0, 0.3);
  }
  50% {
    box-shadow:
      0 0 0 5px rgba(var(--candy-blue-rgb), 0.18),
      0 0 32px rgba(var(--candy-blue-rgb), 0.48),
      0 4px 16px rgba(0, 0, 0, 0.3);
  }
}

@media (prefers-reduced-motion: reduce) {
  .mute-fab:not(.is-muted) .mute-fab-ring {
    animation: none;
  }
}

.mockup-banner a {
  color: var(--neon-hot);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.public-meta {
  margin-top: 1.5rem;
  width: 100%;
  max-width: var(--col-max);
}

.vignette {
  position: fixed;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  background:
    radial-gradient(ellipse 55% 50% at 50% 42%, transparent 20%, rgba(0, 0, 0, 0.55) 100%),
    linear-gradient(180deg, rgba(0, 0, 0, 0.35) 0%, transparent 25%, transparent 70%, rgba(0, 0, 0, 0.65) 100%);
}

/* floating orbs */
.orbs {
  position: fixed;
  inset: 0;
  z-index: 2;
  overflow: hidden;
  pointer-events: none;
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.45;
  animation: float 12s ease-in-out infinite;
}

.orb-1 {
  width: 280px;
  height: 280px;
  background: var(--neon-primary);
  top: 8%;
  left: 50%;
  transform: translateX(-50%);
  opacity: 0.22;
}

.orb-2 {
  width: 180px;
  height: 180px;
  background: var(--neon-cyan);
  bottom: 18%;
  right: -40px;
  animation-delay: -4s;
  opacity: 0.15;
}

.orb-3 {
  width: 140px;
  height: 140px;
  background: var(--neon-hot);
  bottom: 30%;
  left: -30px;
  animation-delay: -7s;
  opacity: 0.18;
}

/* particles */
.particles {
  position: fixed;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  overflow: hidden;
}

.particle {
  position: absolute;
  width: 2px;
  height: 2px;
  background: rgba(255, 255, 255, 0.55);
  border-radius: 50%;
  box-shadow: 0 0 6px rgba(var(--theme-sparkle-rgb), 0.75);
  animation: rise linear infinite;
}

/* —— Splash (e-z.bio style: solid dark so gold sparkles read clearly) —— */
.splash {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  /* solid void — not glass/blur, so cursor trail stays crisp like e-z */
  background: #000000;
  cursor: pointer;
  transition: opacity 0.5s var(--ease-out), visibility 0.5s;
}

.splash.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.splash-label {
  position: relative;
  z-index: 2;
  font-family: var(--font-display);
  font-size: clamp(0.95rem, 2.2vw, 1.15rem);
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: none;
  color: #ffffff;
  text-shadow: 0 0 20px rgba(255, 255, 255, 0.15);
  animation: pulse-text 2.8s ease-in-out infinite;
  pointer-events: none;
}

.splash-hint {
  display: none; /* e-z.bio: only "Click Anywhere" */
}

/* —— Profile —— */
.profile {
  width: 100%;
  max-width: var(--col-max);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  animation: enter 0.8s var(--ease-out) both;
}

.avatar-wrap {
  position: relative;
  width: 108px;
  height: 108px;
  margin-bottom: 1.15rem;
}

.avatar-ring {
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  background: conic-gradient(
    from 180deg,
    var(--theme-avatar-ring),
    var(--theme-avatar-mid),
    var(--theme-avatar-soft),
    var(--theme-avatar-deep),
    var(--theme-avatar-ring)
  );
  animation: spin 8s linear infinite;
  filter: blur(0.3px);
}

.avatar-ring::after {
  content: "";
  position: absolute;
  inset: 3px;
  border-radius: 50%;
  background: var(--bg-void);
}

.avatar {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  overflow: hidden;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 35% 30%, rgba(var(--theme-avatar-rgb), 0.22), transparent 45%),
    linear-gradient(145deg, #0a0e10 0%, var(--onyx) 50%, #0c1215 100%);
  border: 2px solid rgba(var(--theme-avatar-rgb), 0.28);
  box-shadow:
    0 0 0 1px rgba(var(--theme-avatar-rgb), 0.25),
    0 0 40px var(--theme-glow),
    0 0 64px rgba(var(--theme-avatar-rgb), 0.22),
    0 8px 32px rgba(0, 0, 0, 0.5);
  font-family: var(--font-display);
  font-size: 2.4rem;
  font-weight: 700;
  color: var(--text-primary);
  text-shadow: 0 0 20px var(--theme-glow);
  animation: breathe 3.5s ease-in-out infinite;
}

.avatar.has-photo {
  text-shadow: none;
  background: #0a0a0a;
}

.avatar.has-photo .avatar-letter {
  display: none;
}

.avatar-letter {
  position: relative;
  z-index: 1;
}

.avatar-photo,
.avatar img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  z-index: 2;
}

.avatar-photo[hidden] {
  display: none !important;
}

.name {
  font-family: var(--font-display);
  font-size: 1.85rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.15;
  background: linear-gradient(
    120deg,
    #ffffff 0%,
    var(--theme-text) 40%,
    var(--theme-text-mid) 70%,
    var(--theme-text-soft) 100%
  );
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  /* Glow = theme text only (no leftover brand lime) */
  filter: drop-shadow(0 0 14px var(--theme-glow-text))
    drop-shadow(0 0 28px rgba(var(--theme-text-rgb), 0.28));
}

.handle {
  margin-top: 0.35rem;
  font-family: var(--font-display);
  font-size: 0.88rem;
  font-weight: 500;
  color: rgba(var(--theme-text-rgb), 0.78);
  letter-spacing: 0.04em;
}

.bio {
  margin-top: 0.55rem;
  max-width: 280px;
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 500;
  line-height: 1.45;
  color: rgba(var(--theme-text-rgb), 0.72);
}

/* —— Social —— */
.socials {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.65rem;
  margin: 1.35rem 0 1.5rem;
  list-style: none;
}

.socials a {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(var(--theme-icon-rgb-a), 0.08);
  border: 1px solid rgba(var(--theme-icon-rgb-a), 0.5);
  backdrop-filter: blur(var(--blur-glass));
  -webkit-backdrop-filter: blur(var(--blur-glass));
  color: var(--text-primary);
  transition: transform 0.18s var(--ease-out), box-shadow 0.18s, border-color 0.18s, background 0.18s;
  text-decoration: none;
}

.socials a:hover,
.socials a:focus-visible {
  transform: scale(1.12) translateY(-2px);
  border-color: rgba(var(--theme-icon-rgb-b), 0.85);
  background: rgba(var(--theme-icon-rgb-b), 0.16);
  box-shadow: 0 0 20px rgba(var(--theme-icon-rgb-b), 0.45);
  outline: none;
}

.socials svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

/* —— Links —— */
.links {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

a.link-btn.is-link-hidden,
a.link-btn[hidden] {
  display: none !important;
}

.link-btn {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  width: 100%;
  min-height: 52px;
  padding: 0.85rem 1.1rem;
  border-radius: var(--radius-card);
  background: rgba(var(--theme-icon-rgb), 0.07);
  border: 1px solid rgba(var(--theme-icon-rgb), 0.32);
  backdrop-filter: blur(var(--blur-glass));
  -webkit-backdrop-filter: blur(var(--blur-glass));
  color: var(--text-primary);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  transition: transform 0.18s var(--ease-out), box-shadow 0.2s, border-color 0.2s, background 0.2s;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.2);
}

.link-btn:hover,
.link-btn:focus-visible,
.link-btn.is-hover {
  transform: translateY(-2px);
  border-color: rgba(var(--candy-blue-rgb), 0.5);
  background: var(--glass-strong);
  box-shadow:
    0 0 0 1px rgba(var(--candy-blue-rgb), 0.18),
    0 8px 32px rgba(0, 0, 0, 0.35),
    0 0 28px var(--neon-glow-hot);
  outline: none;
}

.link-btn:active {
  transform: translateY(0) scale(0.99);
}

.link-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  flex-shrink: 0;
  font-size: 0.95rem;
  overflow: visible;
  isolation: isolate; /* avoid glass/backdrop eating half the glyph */
}

.link-icon svg {
  width: 18px;
  height: 18px;
  display: block;
  overflow: visible;
  flex-shrink: 0;
}

.link-icon svg path {
  /* force full paint — some browsers half-clip translucent fills over video */
  fill: inherit;
}

.link-icon--discord {
  /* solid tile so Clyde never looks half-transparent over BG video */
  background: #5865f2;
  border-color: rgba(255, 255, 255, 0.12);
  color: #ffffff;
}

.link-icon--discord svg,
.link-icon--discord svg path {
  fill: #ffffff !important;
}

.link-icon--github {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.16);
  color: #f0f6fc;
}

.link-icon--github svg {
  fill: #e6edf3;
}

.link-icon--tracker {
  background: rgba(255, 70, 85, 0.14);
  border-color: rgba(255, 70, 85, 0.35);
}

.link-icon--tracker svg {
  fill: #ff4655;
}

.link-icon--x {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.16);
}

.link-icon--x svg {
  fill: #ffffff;
}

.link-icon--steam {
  background: rgba(27, 40, 56, 0.85);
  border-color: rgba(102, 192, 244, 0.35);
}

.link-icon--steam svg {
  fill: #66c0f4;
}

.link-label {
  flex: 1;
  text-align: left;
}

.link-arrow {
  opacity: 0.4;
  font-size: 0.85rem;
  transition: opacity 0.15s, transform 0.15s;
}

.link-btn:hover .link-arrow {
  opacity: 0.9;
  transform: translateX(2px);
}

/* —— Music + views —— */
.footer-widgets {
  width: 100%;
  margin-top: 1.35rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

/* Unified music card */
.music-card {
  width: 100%;
  border-radius: 18px;
  background: linear-gradient(
    155deg,
    rgba(var(--candy-blue-rgb), 0.1) 0%,
    rgba(var(--onyx-rgb), 0.92) 100%
  );
  border: 1px solid rgba(var(--candy-blue-rgb), 0.18);
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(var(--blur-glass));
  -webkit-backdrop-filter: blur(var(--blur-glass));
  overflow: hidden;
}

.player {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 0.85rem 1rem 0.75rem;
  background: transparent;
}

.music-divider {
  height: 1px;
  margin: 0 1rem;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(var(--candy-blue-rgb), 0.3),
    rgba(255, 255, 255, 0.08),
    rgba(var(--candy-blue-rgb), 0.22),
    transparent
  );
}

.music-controls {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.55rem;
  align-items: end;
  padding: 0.75rem 1rem 0.9rem;
}

.music-field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  text-align: left;
  min-width: 0;
}

.music-field-label {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-faint);
  font-weight: 500;
}

.music-field-label svg {
  width: 11px;
  height: 11px;
  opacity: 0.75;
  fill: var(--neon-primary);
}

.music-select-wrap {
  position: relative;
}

.music-select {
  width: 100%;
  appearance: none;
  -webkit-appearance: none;
  padding: 0.7rem 2.25rem 0.7rem 0.9rem;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 0.84rem;
  font-weight: 500;
  cursor: pointer;
  outline: none;
  transition: border-color 0.18s, box-shadow 0.18s, background 0.18s;
}

.music-select-wrap::after {
  content: "";
  position: absolute;
  right: 12px;
  top: 50%;
  width: 7px;
  height: 7px;
  border-right: 1.5px solid var(--neon-primary);
  border-bottom: 1.5px solid var(--neon-primary);
  transform: translateY(-65%) rotate(45deg);
  pointer-events: none;
  opacity: 0.85;
}

.music-select:hover,
.music-select:focus-visible {
  border-color: rgba(var(--candy-blue-rgb), 0.5);
  background: rgba(var(--candy-blue-rgb), 0.08);
  box-shadow: 0 0 0 3px rgba(var(--candy-blue-rgb), 0.12);
}

.music-select option {
  background: var(--onyx);
  color: var(--text-primary);
}

.music-upload {
  display: flex;
  align-items: stretch;
}

.music-upload-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  min-height: 44px;
  padding: 0.65rem 0.95rem;
  border-radius: 12px;
  border: 1px solid rgba(var(--candy-blue-rgb), 0.35);
  background: linear-gradient(
    135deg,
    rgba(var(--candy-blue-rgb), 0.16),
    rgba(var(--candy-blue-rgb), 0.08)
  );
  color: var(--text-primary);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: border-color 0.18s, background 0.18s, box-shadow 0.18s, transform 0.15s;
  white-space: nowrap;
}

.music-upload-btn svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: var(--neon-primary);
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}

.music-upload:hover .music-upload-btn,
.music-upload:focus-within .music-upload-btn {
  border-color: rgba(var(--candy-blue-rgb), 0.6);
  background: linear-gradient(
    135deg,
    rgba(var(--candy-blue-rgb), 0.28),
    rgba(var(--candy-blue-rgb), 0.14)
  );
  box-shadow: 0 0 22px rgba(var(--candy-blue-rgb), 0.28);
  transform: translateY(-1px);
}

@media (max-width: 380px) {
  .music-controls {
    grid-template-columns: 1fr;
  }

  .music-upload-btn {
    width: 100%;
  }
}

.play-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: linear-gradient(135deg, var(--candy-blue), var(--neon-hot));
  color: var(--onyx);
  display: grid;
  place-items: center;
  cursor: pointer;
  flex-shrink: 0;
  box-shadow: 0 0 16px var(--neon-glow);
  transition: transform 0.15s;
  font-size: 0.75rem;
}

.play-btn:hover {
  transform: scale(1.06);
}

.player-meta {
  flex: 1;
  min-width: 0;
  text-align: left;
}

.player-title {
  font-size: 0.8rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.player-artist {
  font-size: 0.7rem;
  color: var(--text-faint);
  margin-top: 0.1rem;
}

.player-bars {
  display: flex;
  align-items: flex-end;
  gap: 2px;
  height: 18px;
  opacity: 0.85;
}

.player-bars span {
  width: 3px;
  background: var(--neon-cyan);
  border-radius: 2px;
  height: 30%;
  box-shadow: 0 0 6px var(--neon-glow-cyan);
}

.player.playing .player-bars span {
  animation: bar 0.9s ease-in-out infinite alternate;
}

.player.playing .player-bars span:nth-child(2) {
  animation-delay: 0.15s;
}
.player.playing .player-bars span:nth-child(3) {
  animation-delay: 0.3s;
}
.player.playing .player-bars span:nth-child(4) {
  animation-delay: 0.1s;
}

/* Footer meta: Views, brand mark, © — Outfit + dedicated theme-meta (dashboard) */
.meta-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 0.25rem;
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: rgba(var(--theme-meta-rgb), var(--theme-meta-alpha));
  text-shadow:
    0 1px 3px rgba(0, 0, 0, 0.85),
    0 0 14px rgba(var(--theme-meta-rgb), 0.35);
}

.meta-row .meta-brand {
  font-family: inherit;
  font-weight: 600;
  color: inherit;
}

.views {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-family: inherit;
  color: inherit;
}

.credit {
  margin-top: 1.25rem;
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  color: rgba(var(--theme-meta-rgb), var(--theme-meta-alpha));
  text-transform: uppercase;
  text-shadow:
    0 1px 3px rgba(0, 0, 0, 0.85),
    0 0 14px rgba(var(--theme-meta-rgb), 0.3);
}

.mockup-banner {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 200;
  padding: 0.4rem 0.75rem;
  background: rgba(var(--candy-blue-rgb), 0.1);
  border-bottom: 1px solid rgba(var(--candy-blue-rgb), 0.25);
  backdrop-filter: blur(8px);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-align: center;
  color: var(--candy-blue);
  text-transform: uppercase;
}

/* —— Custom cursor —— */
/* Mouse sparkle trail (e-z.bio style) — above splash so also on "click anywhere" */
.cursor-trail {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 55;
}

body[data-view="dashboard"] .cursor-trail {
  display: none !important;
}

/* Normal system cursor; custom cursor elements stay hidden */
.cursor-dot,
.cursor-ring {
  display: none !important;
}

/* —— Phone frame (for 03-interactions desktop preview) —— */
.phone-frame {
  width: min(390px, 100%);
  min-height: 720px;
  border-radius: 36px;
  border: 2px solid rgba(255, 255, 255, 0.12);
  box-shadow:
    0 0 0 8px rgba(255, 255, 255, 0.04),
    0 40px 80px rgba(0, 0, 0, 0.55);
  overflow: hidden;
  position: relative;
  background: var(--bg-void);
}

.phone-frame .stage {
  min-height: 720px;
}

/* —— States for static mock screens —— */
body.state-splash .splash {
  opacity: 1;
  visibility: visible;
}

body.state-main .splash {
  display: none;
}

body.state-hover .splash {
  display: none;
}

body.state-hover .link-btn:nth-child(2) {
  transform: translateY(-2px);
  border-color: rgba(var(--candy-blue-rgb), 0.5);
  background: var(--glass-strong);
  box-shadow:
    0 0 0 1px rgba(var(--candy-blue-rgb), 0.18),
    0 8px 32px rgba(0, 0, 0, 0.35),
    0 0 28px var(--neon-glow-hot);
}

body.state-hover .link-btn:nth-child(2) .link-arrow {
  opacity: 0.9;
  transform: translateX(2px);
}

body.state-hover .socials a:nth-child(1) {
  transform: scale(1.12) translateY(-2px);
  border-color: rgba(var(--candy-blue-rgb), 0.55);
  box-shadow: 0 0 20px var(--neon-glow);
}

/* —— Animations —— */
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes breathe {
  0%,
  100% {
    box-shadow:
      0 0 0 1px rgba(var(--candy-blue-rgb), 0.25),
      0 0 36px var(--neon-glow),
      0 8px 32px rgba(0, 0, 0, 0.5);
  }
  50% {
    box-shadow:
      0 0 0 1px rgba(var(--candy-blue-rgb), 0.45),
      0 0 52px var(--neon-glow-hot),
      0 8px 32px rgba(0, 0, 0, 0.5);
  }
}

@keyframes pulse-text {
  0%,
  100% {
    opacity: 0.72;
  }
  50% {
    opacity: 1;
  }
}

@keyframes enter {
  from {
    opacity: 0;
    transform: translateY(16px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes float {
  0%,
  100% {
    transform: translate(0, 0);
  }
  50% {
    transform: translate(12px, -18px);
  }
}

@keyframes bg-shift {
  from {
    filter: hue-rotate(0deg);
  }
  to {
    filter: hue-rotate(12deg);
  }
}

@keyframes rise {
  0% {
    transform: translateY(100vh) scale(0.6);
    opacity: 0;
  }
  10% {
    opacity: 0.8;
  }
  90% {
    opacity: 0.5;
  }
  100% {
    transform: translateY(-10vh) scale(1);
    opacity: 0;
  }
}

@keyframes bar {
  from {
    height: 25%;
  }
  to {
    height: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .particles,
  .orbs {
    display: none;
  }
}

@media (min-width: 768px) {
  .stage {
    padding: 3rem 1.5rem;
  }

  .name {
    font-size: 2.05rem;
  }
}
