/* ---------------------------------------------------------
   @not.freakk — editorial index
   Design tokens
--------------------------------------------------------- */
* { box-sizing: border-box; }

:root {
  --ink:        #08070b;
  --ink-2:      #100e17;
  --ink-3:      #17131f;
  --paper:      #efedf2;
  --paper-dim:  #a7a3b5;
  --muted:      #837ea1;
  --violet:      #9b8cf0;
  --violet-soft: rgba(155, 140, 240, .18);
  --indigo:     #6f6ad6;
  --blue:       #5f7fd6;
  --line:       rgba(239, 237, 242, .10);
  --line-soft:  rgba(239, 237, 242, .05);

  --display: "Fraunces", ui-serif, Georgia, serif;
  --body:    "Inter", ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --mono:    "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  --ease: cubic-bezier(.19,1,.22,1);
  --ease-spring: cubic-bezier(.34,1.56,.64,1);
}

html, body { min-height: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(620px 480px at 14% -4%, rgba(130, 105, 224, .07), transparent 62%),
    radial-gradient(700px 560px at 100% 6%, rgba(90, 70, 190, .06), transparent 60%),
    radial-gradient(520px 460px at 88% 46%, rgba(70, 90, 200, .05), transparent 62%),
    radial-gradient(640px 520px at 6% 62%, rgba(110, 70, 200, .055), transparent 60%),
    radial-gradient(760px 600px at 60% 96%, rgba(80, 60, 170, .06), transparent 62%),
    radial-gradient(900px 720px at 50% 42%, rgba(30, 24, 56, .5), transparent 72%),
    linear-gradient(180deg, #09080d 0%, #07060a 45%, #050409 100%);
  background-attachment: fixed;
  color: var(--paper);
  font-family: var(--body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body::before {
  content: "";
  position: fixed;
  inset: -12%;
  z-index: -1;
  background:
    radial-gradient(640px 520px at 28% 18%, rgba(155,140,240,.05), transparent 60%),
    radial-gradient(560px 480px at 78% 84%, rgba(95,127,214,.05), transparent 60%);
  animation: ambientDrift 26s ease-in-out infinite alternate;
  pointer-events: none;
}

@keyframes ambientDrift {
  0%   { transform: translate(0, 0) scale(1); }
  100% { transform: translate(2.5%, -2.5%) scale(1.06); }
}

body::after {
  content: "";
  position: fixed;
  inset: -12%;
  z-index: -1;
  background:
    radial-gradient(500px 420px at 85% 12%, rgba(111,106,214,.045), transparent 62%),
    radial-gradient(460px 400px at 12% 88%, rgba(155,140,240,.04), transparent 62%);
  animation: ambientDrift2 32s ease-in-out infinite alternate;
  pointer-events: none;
}

@keyframes ambientDrift2 {
  0%   { transform: translate(0, 0) scale(1.04); }
  100% { transform: translate(-3%, 2%) scale(1); }
}

button, a { -webkit-tap-highlight-color: transparent; }

::selection { background: var(--violet); color: var(--ink); }

/* ---------------------------------------------------------
   Focus visibility — one consistent keyboard-focus treatment
   for every interactive element that doesn't already define
   its own (components below can override with their own ring).
--------------------------------------------------------- */
a:focus-visible,
button:focus-visible,
input:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--violet);
  outline-offset: 3px;
  border-radius: 4px;
}

.page {
  width: min(100%, 620px);
  margin: 0 auto;
  padding: 64px 26px 80px;
}

/* ---------------------------------------------------------
   Reveal-on-load motion
--------------------------------------------------------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(14px);
  animation: reveal .7s var(--ease) forwards;
}
.profile-header [data-reveal]:nth-of-type(1) { animation-delay: .02s; }
.profile-header [data-reveal]:nth-of-type(2) { animation-delay: .1s; }
.profile-header [data-reveal]:nth-of-type(3) { animation-delay: .18s; }
.profile-header [data-reveal]:nth-of-type(4) { animation-delay: .24s; }
.profile-header [data-reveal]:nth-of-type(5) { animation-delay: .3s; }
.profile-header [data-reveal]:nth-of-type(6) { animation-delay: .36s; }
.profile-header [data-reveal]:nth-of-type(7) { animation-delay: .42s; }
.links-section [data-reveal] { animation-delay: .44s; }

@keyframes reveal {
  to { opacity: 1; transform: translateY(0); }
}

.avatar-wrap[data-reveal] {
  animation: revealPop .85s var(--ease-spring) forwards, avatarGlow 5.5s .85s ease-in-out infinite;
  animation-delay: .02s, .87s;
}

@keyframes revealPop {
  from { opacity: 0; transform: translateY(14px) scale(.8); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

@media (prefers-reduced-motion: reduce) {
  [data-reveal] { animation: none; opacity: 1; transform: none; }
  * { transition-duration: .001ms !important; animation-duration: .001ms !important; }
}

/* ---------------------------------------------------------
   Header
--------------------------------------------------------- */
.profile-header { text-align: center; }

.eyebrow {
  margin: 0 0 30px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--muted);
}

.avatar-wrap {
  position: relative;
  width: 116px;
  height: 116px;
  margin: 0 auto 28px;
  border-radius: 50%;
  padding: 4px;
  border: 1px solid var(--line);
  overflow: hidden;
  background: linear-gradient(155deg, rgba(255,255,255,.06), rgba(255,255,255,.01));
  animation: avatarGlow 5.5s ease-in-out infinite;
}

.avatar-wrap.avatar-fallback {
  background: linear-gradient(155deg, rgba(155,140,240,.4), rgba(111,106,214,.28));
}

.avatar-wrap.avatar-fallback .avatar { visibility: hidden; }

.avatar-wrap.avatar-fallback::after {
  content: "M";
  position: absolute;
  inset: 4px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-family: var(--display);
  font-size: 44px;
  font-weight: 600;
  color: var(--paper);
}

@keyframes avatarGlow {
  0%, 100% { box-shadow: 0 0 22px 2px rgba(155,140,240,.08), inset 0 1px 0 rgba(255,255,255,.08); }
  50%      { box-shadow: 0 0 34px 8px rgba(155,140,240,.16), inset 0 1px 0 rgba(255,255,255,.12); }
}

.avatar {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  border-radius: 50%;
  display: block;
  background: var(--ink-3);
  transform: scale(1.12);
}

.handle {
  margin: 0;
  font-family: var(--body);
  font-size: clamp(32px, 7vw, 44px);
  line-height: 1.05;
  letter-spacing: -.02em;
  font-weight: 600;
  font-style: normal;
}

.handle-at { color: var(--violet); font-style: normal; font-weight: 600; }
.handle-rest { color: var(--paper); font-style: normal; }

.bio {
  margin: 14px 0 0;
  font-family: var(--display);
  font-style: italic;
  font-size: clamp(18px, 3vw, 21px);
  font-weight: 440;
  letter-spacing: -.01em;
  color: var(--paper-dim);
}

.rule {
  height: 1px;
  margin: 36px 0;
  background: linear-gradient(90deg, transparent, var(--line) 20%, var(--line) 80%, transparent);
}

/* ---------------------------------------------------------
   Socials
--------------------------------------------------------- */
.socials {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 14px;
}

.socials a,
.socials .icon-btn {
  width: 44px;
  height: 44px;
  color: var(--paper-dim);
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: linear-gradient(155deg, rgba(255,255,255,.05), rgba(255,255,255,.01));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.07);
  backdrop-filter: blur(6px) saturate(140%);
  -webkit-backdrop-filter: blur(6px) saturate(140%);
  overflow: hidden;
  transition: color .25s var(--ease), border-color .25s var(--ease), background .25s var(--ease), transform .25s var(--ease), box-shadow .25s var(--ease);
}

.socials .icon-btn {
  padding: 0;
  font: inherit;
  cursor: pointer;
}

.socials a:hover,
.socials a:focus-visible,
.socials .icon-btn:hover,
.socials .icon-btn:focus-visible {
  color: var(--violet);
  background: var(--violet-soft);
  border-color: color-mix(in srgb, var(--violet) 45%, transparent);
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(120,100,220,.14);
}

.socials a:focus-visible,
.socials .icon-btn:focus-visible {
  outline-offset: 2px;
}

.socials a:active,
.socials .icon-btn:active {
  transform: translateY(0) scale(.94);
}

.socials svg {
  width: 20px;
  height: 20px;
}

/* ---------------------------------------------------------
   Links — editorial index list
--------------------------------------------------------- */
.links-section { margin-top: 6px; }

.eyebrow--links {
  margin-bottom: 18px;
  text-align: left;
}

.links {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 6px 14px;
  border-radius: 22px;
  border: 1px solid rgba(255,255,255,.08);
  background: linear-gradient(165deg, rgba(255,255,255,.045), rgba(255,255,255,.008));
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.08),
    0 20px 50px rgba(0,0,0,.28);
  backdrop-filter: blur(14px) saturate(150%);
  -webkit-backdrop-filter: blur(14px) saturate(150%);
  overflow: hidden;
  isolation: isolate;
}

.links::before {
  content: "";
  position: absolute;
  inset: -40% -60%;
  z-index: -1;
  background: linear-gradient(115deg, transparent 42%, rgba(255,255,255,.05) 50%, transparent 58%);
  animation: panelSheen 9s ease-in-out infinite;
  pointer-events: none;
}

@keyframes panelSheen {
  0%, 100% { transform: translateX(-30%); }
  50%      { transform: translateX(30%); }
}

.link-row { border-bottom-color: rgba(255,255,255,.06); }
.links .link-row:last-child { border-bottom: none; }

.link-row {
  position: relative;
  display: grid;
  grid-template-columns: 30px 46px 1fr 20px 36px;
  align-items: center;
  gap: 16px;
  padding: 18px 4px;
  border-bottom: 1px solid var(--line);
  color: var(--paper);
  text-decoration: none;
  isolation: isolate;
  transition: background .3s var(--ease), padding-left .3s var(--ease), transform .3s var(--ease);
}

.link-row::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: 12px;
  background: radial-gradient(220px 90px at 0% 50%, rgba(150,130,230,.10), transparent 75%);
  opacity: 0;
  transition: opacity .35s var(--ease);
}

.link-row:hover,
.link-row:focus-visible {
  background: var(--line-soft);
  padding-left: 10px;
  transform: translateX(2px);
}

.link-row:hover::before,
.link-row:focus-visible::before {
  opacity: 1;
}

.link-row:active {
  transform: scale(.99);
}

/* Featured link — subtly elevated, not a CTA button */
.link-row--featured {
  border-bottom-color: rgba(155,140,240,.16);
}

.link-row--featured::after {
  content: "";
  position: absolute;
  left: -1px;
  top: 12px;
  bottom: 12px;
  width: 2px;
  border-radius: 2px;
  background: linear-gradient(180deg, transparent, var(--violet), transparent);
  opacity: .55;
}

.link-row--featured .link-title {
  color: var(--paper);
  font-weight: 600;
}

.link-row--featured .link-thumb {
  color: var(--violet);
  border-color: rgba(155,140,240,.3);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.16),
    0 0 0 1px rgba(155,140,240,.2),
    0 10px 26px rgba(120,100,220,.16);
}

.link-row--featured::before {
  background: radial-gradient(260px 110px at 0% 50%, rgba(155,140,240,.14), transparent 75%);
  opacity: .55;
}

.link-row--featured:hover::before,
.link-row--featured:focus-visible::before {
  opacity: 1;
}

.link-index {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted);
}

.link-thumb {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: var(--paper-dim);
  background: linear-gradient(155deg, rgba(255,255,255,.075), rgba(255,255,255,.015));
  border: 1px solid rgba(255,255,255,.08);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.12),
    inset 0 -10px 18px rgba(0,0,0,.22),
    0 8px 18px rgba(0,0,0,.22);
  backdrop-filter: blur(8px) saturate(150%);
  -webkit-backdrop-filter: blur(8px) saturate(150%);
  transition: transform .45s var(--ease), color .3s ease, border-color .35s ease, box-shadow .45s var(--ease);
}

.link-thumb svg {
  width: 21px;
  height: 21px;
  transition: transform .45s var(--ease);
}

.link-row:hover .link-thumb,
.link-row:focus-visible .link-thumb {
  color: var(--violet);
  border-color: rgba(155,140,240,.35);
  transform: scale(1.08) rotate(-3deg);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.18),
    inset 0 -10px 18px rgba(0,0,0,.18),
    0 12px 26px rgba(120,100,220,.22);
}

.link-row:hover .link-thumb svg,
.link-row:focus-visible .link-thumb svg {
  transform: scale(1.1);
}

.link-title {
  min-width: 0;
  font-size: clamp(17px, 2.6vw, 19px);
  font-weight: 500;
  letter-spacing: -.01em;
}

.link-arrow {
  width: 16px;
  height: 16px;
  color: var(--violet);
  opacity: 0;
  transform: translateX(-4px);
  transition: opacity .2s var(--ease), transform .2s var(--ease);
}

.link-row:hover .link-arrow,
.link-row:focus-visible .link-arrow {
  opacity: 1;
  transform: translateX(0);
}

.more-btn {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  border-radius: 8px;
  z-index: 2;
  justify-self: end;
  transition: color .2s ease, background .2s ease, transform .2s ease;
}

.more-btn svg { width: 16px; height: 16px; }

.more-btn:hover {
  background: var(--violet-soft);
  color: var(--violet);
  transform: translateY(-1px);
}

.context-menu {
  position: absolute;
  right: 4px;
  top: 56px;
  z-index: 5;
  min-width: 150px;
  padding: 6px;
  border-radius: 12px;
  background: rgba(20,17,28,.72);
  border: 1px solid rgba(255,255,255,.09);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.08), 0 16px 40px rgba(0,0,0,.5);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  transform-origin: top right;
  animation: menuIn .16s var(--ease);
}

.context-menu button {
  width: 100%;
  border: 0;
  background: transparent;
  padding: 9px 11px;
  border-radius: 7px;
  text-align: left;
  font: inherit;
  color: var(--paper);
  cursor: pointer;
}

.context-menu button:hover { background: var(--line-soft); }

.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translate(-50%, 20px);
  padding: 11px 18px;
  border-radius: 999px;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .04em;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s ease, transform .2s ease;
  z-index: 20;
}

.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

@keyframes menuIn {
  from { opacity: 0; transform: scale(.96); }
  to { opacity: 1; transform: scale(1); }
}

/* ---------------------------------------------------------
   Responsive
--------------------------------------------------------- */
@media (max-width: 600px) {
  .page { padding: 44px 18px 60px; }
  .rule { margin: 30px 0; }
  .socials { gap: 10px; }
  .socials a { width: 42px; height: 42px; }
  .link-row {
    grid-template-columns: 22px 40px 1fr 32px;
    gap: 12px;
    padding: 17px 4px;
  }
  .link-thumb { width: 40px; height: 40px; }
  .link-arrow { display: none; }
  .more-btn {
    width: 38px;
    height: 38px;
    color: var(--muted);
  }
}

@media (max-width: 360px) {
  .avatar-wrap { width: 100px; height: 100px; }
  .handle { font-size: 34px; }
}


/* ---------------------------------------------------------
   Manifesto — "Freak" statement block
--------------------------------------------------------- */
.manifesto {
  position: relative;
  overflow: hidden;
  margin-top: 30px;
  padding: 30px 24px 28px;
  border-radius: 22px;
  border: 1px solid rgba(255,255,255,.08);
  background: linear-gradient(165deg, rgba(255,255,255,.04), rgba(255,255,255,.006));
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.07),
    0 20px 50px rgba(0,0,0,.26);
  backdrop-filter: blur(14px) saturate(150%);
  -webkit-backdrop-filter: blur(14px) saturate(150%);
  isolation: isolate;
}

.manifesto::before {
  content: "";
  position: absolute;
  inset: -40% -60%;
  z-index: -1;
  background: linear-gradient(115deg, transparent 42%, rgba(255,255,255,.045) 50%, transparent 58%);
  animation: panelSheen 11s 1.5s ease-in-out infinite;
  pointer-events: none;
}

.manifesto-bgtype {
  position: absolute;
  left: -0.04em;
  top: -0.14em;
  z-index: -1;
  margin: 0;
  font-family: var(--display);
  font-weight: 600;
  font-style: normal;
  font-size: clamp(96px, 26vw, 190px);
  line-height: 1;
  letter-spacing: -.03em;
  color: var(--paper);
  opacity: .035;
  white-space: nowrap;
  user-select: none;
  pointer-events: none;
}

.manifesto-label {
  position: relative;
  margin: 0 0 22px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--muted);
}

.manifesto-label span {
  color: var(--violet);
}

.manifesto-mark {
  display: block;
  width: clamp(150px, 34vw, 210px);
  height: auto;
  margin: 0 0 22px;
  opacity: .92;
  animation: markFloat 6s ease-in-out infinite;
}

@keyframes markFloat {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-6px); }
}

.manifesto-body {
  position: relative;
}

.manifesto-body p {
  margin: 0 0 18px;
  font-family: var(--display);
  font-style: italic;
  font-weight: 440;
  font-size: clamp(16px, 2.6vw, 18px);
  line-height: 1.55;
  letter-spacing: -.005em;
  color: var(--paper-dim);
}

.manifesto-body p:last-child { margin-bottom: 0; }

/* ---------------------------------------------------------
   Footer — repeated socials + credit line
--------------------------------------------------------- */
.site-footer {
  margin-top: 30px;
  padding-bottom: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.socials--footer { margin-bottom: 22px; }

.footer-credit {
  margin: 0;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
}

@media (max-width: 600px) {
  .manifesto { margin-top: 24px; padding: 24px 18px 22px; }
  .site-footer { margin-top: 24px; }
}

/* ---------------------------------------------------------
   Fixed Spotify-inspired music player
   The player stays below the page content and above the UI.
--------------------------------------------------------- */
.music-player {
  position: fixed;
  left: 50%;
  bottom: 14px;
  transform: translateX(-50%) translateY(0);
  width: min(600px, calc(100% - 28px));
  min-height: 62px;
  z-index: 100;
  display: grid;
  grid-template-columns: 42px minmax(150px, 1fr) minmax(150px, 1.1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 8px 10px 8px 8px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(9,8,13,.86);
  box-shadow: 0 10px 30px rgba(0,0,0,.35);
  backdrop-filter: blur(16px) saturate(115%);
  -webkit-backdrop-filter: blur(16px) saturate(115%);
  overflow: hidden;
  isolation: isolate;
  transition: border-color .3s ease, box-shadow .3s ease, background .3s ease;
}

.music-player::before {
  content: "";
  position: absolute;
  top: 0;
  left: 14px;
  right: 14px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.22), transparent);
  pointer-events: none;
  z-index: 1;
}

.music-player::after {
  content: "";
  position: absolute;
  inset: -30% -50%;
  z-index: -1;
  background: linear-gradient(115deg, transparent 42%, rgba(255,255,255,.05) 50%, transparent 58%);
  animation: panelSheen 10s .8s ease-in-out infinite;
  pointer-events: none;
}

.music-player.is-playing {
  border-color: rgba(155,140,240,.14);
  background: rgba(11,10,16,.9);
}

.music-glow {
  position: absolute;
  width: 160px;
  height: 160px;
  right: 8%;
  top: -120px;
  background: radial-gradient(circle, rgba(120,100,220,.06), transparent 70%);
  filter: blur(10px);
  pointer-events: none;
  z-index: -1;
}

.music-hit {
  display: contents;
  cursor: pointer;
}

.music-cover-wrap {
  position: relative;
  width: 42px;
  height: 42px;
  flex: none;
  border-radius: 8px;
  overflow: visible;
}

.music-cover {
  width: 42px;
  height: 42px;
  display: block;
  border-radius: 8px;
  object-fit: cover;
  box-shadow: 0 5px 14px rgba(0,0,0,.4);
  transition: transform .35s var(--ease), filter .35s ease;
}

.music-player.is-playing .music-cover {
  transform: scale(.94);
  filter: saturate(1.08) brightness(1.05);
}

.music-playing-ring {
  position: absolute;
  inset: -3px;
  border-radius: 10px;
  border: 1px solid rgba(155,140,240,.4);
  opacity: 0;
  transition: opacity .25s ease;
  pointer-events: none;
}

.music-player.is-playing .music-playing-ring {
  opacity: 1;
}

.music-meta {
  min-width: 0;
  align-self: center;
}

.music-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.music-title {
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 13px;
  line-height: 1.2;
  font-weight: 600;
  color: var(--paper);
}

.music-artist {
  margin-top: 4px;
  font-size: 11px;
  line-height: 1.2;
  color: rgba(239,237,242,.54);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.music-time {
  margin-top: 5px;
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: .03em;
  color: rgba(239,237,242,.42);
}

.music-time #musicCurrent { color: #9b8cf0; }

.music-eq {
  display: inline-flex;
  align-items: end;
  gap: 2px;
  height: 12px;
  opacity: 0;
  transition: opacity .2s ease;
}

.music-player.is-playing .music-eq { opacity: 1; }

.music-eq i {
  display: block;
  width: 2px;
  height: 4px;
  border-radius: 2px;
  background: #9b8cf0;
  animation: eq 650ms ease-in-out infinite alternate;
}
.music-eq i:nth-child(2) { height: 8px; animation-delay: -220ms; }
.music-eq i:nth-child(3) { height: 11px; animation-delay: -430ms; }
.music-eq i:nth-child(4) { height: 6px; animation-delay: -120ms; }

@keyframes eq {
  from { transform: scaleY(.35); }
  to { transform: scaleY(1); }
}

.music-progress-area {
  min-width: 0;
  display: flex;
  align-items: center;
}

.music-seek {
  --progress: 0%;
  width: 100%;
  height: 4px;
  margin: 0;
  padding: 0;
  appearance: none;
  -webkit-appearance: none;
  border-radius: 99px;
  background: linear-gradient(90deg, #9b8cf0 0 var(--progress), rgba(255,255,255,.12) var(--progress) 100%);
  cursor: pointer;
  outline: none;
}

.music-seek::-webkit-slider-thumb {
  width: 11px;
  height: 11px;
  appearance: none;
  -webkit-appearance: none;
  border: 2px solid #9b8cf0;
  border-radius: 50%;
  background: #0b0b0d;
  box-shadow: 0 0 0 3px rgba(155,140,240,.14);
  opacity: 0;
  transition: opacity .18s ease, transform .18s ease;
}

.music-seek:hover::-webkit-slider-thumb,
.music-seek:focus-visible::-webkit-slider-thumb {
  opacity: 1;
}

.music-seek::-moz-range-thumb {
  width: 8px;
  height: 8px;
  border: 2px solid #9b8cf0;
  border-radius: 50%;
  background: #0b0b0d;
  opacity: 0;
}
.music-seek:hover::-moz-range-thumb,
.music-seek:focus-visible::-moz-range-thumb { opacity: 1; }

.music-controls {
  display: flex;
  align-items: center;
  gap: 5px;
}

.music-btn {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  color: rgba(239,237,242,.72);
  background: transparent;
  cursor: pointer;
  transition: color .18s ease, background .18s ease, transform .18s ease;
}

.music-btn:hover,
.music-btn:focus-visible {
  color: #fff;
  background: rgba(255,255,255,.06);
  transform: scale(1.05);
}

.music-btn:focus-visible { outline-offset: 1px; }

.music-btn svg { width: 16px; height: 16px; }

.music-play {
  width: 36px;
  height: 36px;
  color: #0b0b0d;
  background: #ece9f2;
  box-shadow: 0 3px 12px rgba(0,0,0,.24);
}

.music-play:hover,
.music-play:focus-visible {
  color: #0b0b0d;
  background: #fff;
  transform: scale(1.06);
}

.icon-pause,
.icon-muted { display: none; }
.music-player.is-playing .icon-play,
.music-expanded.is-playing .icon-play { display: none; }
.music-player.is-playing .icon-pause,
.music-expanded.is-playing .icon-pause { display: block; }
.music-player.is-muted .icon-volume,
.music-expanded.is-muted .icon-volume { display: none; }
.music-player.is-muted .icon-muted,
.music-expanded.is-muted .icon-muted { display: block; }

@media (max-width: 640px) {
  .music-player {
    width: calc(100% - 16px);
    bottom: 8px;
    min-height: 58px;
    grid-template-columns: 38px minmax(0, 1fr) auto;
    gap: 10px;
    padding: 8px;
    border-radius: 14px;
  }

  .music-cover-wrap,
  .music-cover {
    width: 38px;
    height: 38px;
  }

  .music-progress-area {
    position: absolute;
    left: 56px;
    right: 8px;
    bottom: 5px;
  }

  .music-seek { height: 3px; }

  .music-controls { gap: 2px; }
  .music-small { display: none; }
  .music-play { width: 34px; height: 34px; }

  /* Prioritize title + progress over secondary metadata */
  .music-artist { display: none; }
  .music-title { font-size: 12.5px; }
  .music-time { font-size: 8px; margin-top: 3px; }

  .page { padding-bottom: 92px; }
}

@media (prefers-reduced-motion: reduce) {
  .music-eq i { animation: none; }
}

/* ---------------------------------------------------------
   Expanded "now playing" sheet — opens from the mini player
--------------------------------------------------------- */
html.has-expanded-player,
html.has-expanded-player body {
  overflow: hidden;
  height: 100%;
}

.music-expanded {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: grid;
  place-items: center;
  padding: 20px;
  visibility: hidden;
}

.music-expanded.is-open { visibility: visible; }

.music-expanded-scrim {
  position: absolute;
  inset: 0;
  background: rgba(3,9,8,.72);
  backdrop-filter: blur(10px) saturate(120%);
  -webkit-backdrop-filter: blur(10px) saturate(120%);
  opacity: 0;
  transition: opacity .4s var(--ease);
}

.music-expanded.is-open .music-expanded-scrim { opacity: 1; }

.music-expanded-sheet {
  position: relative;
  z-index: 1;
  width: min(400px, 100%);
  max-height: min(86vh, 680px);
  overflow-y: auto;
  padding: 16px 28px 30px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  border-radius: 24px;
  border: 1px solid rgba(255,255,255,.07);
  background:
    radial-gradient(ellipse 300px 190px at 50% -6%, rgba(120,100,220,.09), transparent 62%),
    linear-gradient(165deg, rgba(18,16,29,.94), rgba(6,5,11,.98));
  box-shadow: 0 40px 100px rgba(0,0,0,.55), 0 0 0 1px rgba(255,255,255,.02) inset;
  transform: translateY(28px) scale(.97);
  opacity: 0;
  transition: transform .4s var(--ease), opacity .3s var(--ease);
}

.music-expanded.is-open .music-expanded-sheet {
  transform: translateY(0) scale(1);
  opacity: 1;
}

.music-expanded-handle {
  width: 36px;
  height: 4px;
  margin: 0 0 10px;
  border-radius: 99px;
  background: rgba(255,255,255,.14);
}

.music-expanded-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  color: rgba(239,237,242,.6);
  background: rgba(255,255,255,.05);
  cursor: pointer;
  transition: color .18s ease, background .18s ease, transform .18s ease;
}

.music-expanded-close:hover,
.music-expanded-close:focus-visible {
  color: #fff;
  background: rgba(255,255,255,.1);
  transform: scale(1.06);
}

.music-expanded-close svg { width: 16px; height: 16px; }

.music-expanded-art-wrap {
  position: relative;
  width: 216px;
  height: 216px;
  margin: 30px 0 24px;
}

.music-expanded-art {
  width: 100%;
  height: 100%;
  display: block;
  border-radius: 20px;
  object-fit: cover;
  box-shadow: 0 30px 70px rgba(0,0,0,.55);
  transform: scale(.92);
  opacity: 0;
  transition: transform .5s .08s var(--ease), opacity .4s .08s ease;
}

.music-expanded.is-open .music-expanded-art {
  transform: scale(1);
  opacity: 1;
}

.music-expanded-ring {
  position: absolute;
  inset: -9px;
  border-radius: 25px;
  border: 1px solid rgba(155,140,240,.45);
  opacity: 0;
  transform: scale(.94);
  transition: opacity .3s ease, transform .4s var(--ease);
  pointer-events: none;
}

.music-expanded.is-playing .music-expanded-ring {
  opacity: 1;
  transform: scale(1);
  animation: expandedRingPulse 1.8s ease-in-out infinite;
}

@keyframes expandedRingPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(155,140,240,0); }
  50%      { box-shadow: 0 0 0 10px rgba(155,140,240,.08); }
}

.music-expanded-meta {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .4s .14s ease, transform .4s .14s var(--ease);
}

.music-expanded.is-open .music-expanded-meta {
  opacity: 1;
  transform: translateY(0);
}

.music-expanded-now {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 10px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--muted);
}

.music-expanded-now .dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--violet);
  opacity: .5;
}

.music-expanded.is-playing .music-expanded-now .dot {
  opacity: 1;
  animation: nowDotPulse 1.8s ease-in-out infinite;
}

@keyframes nowDotPulse {
  0%, 100% { opacity: .5; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.3); }
}

.music-expanded-title {
  font-family: var(--display);
  font-size: 22px;
  font-weight: 560;
  letter-spacing: -.01em;
  color: var(--paper);
}

.music-expanded-artist {
  margin-top: 6px;
  font-size: 13px;
  color: var(--paper-dim);
}

.music-expanded-progress {
  width: 100%;
  margin-top: 26px;
  opacity: 0;
  transition: opacity .4s .18s ease;
}

.music-expanded.is-open .music-expanded-progress { opacity: 1; }

.music-seek-expanded { height: 5px; }

.music-expanded-times {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  font-family: var(--mono);
  font-size: 11px;
  color: rgba(239,237,242,.5);
}

.music-expanded-times .music-current { color: #9b8cf0; }

.music-expanded-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 22px;
  margin-top: 22px;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .4s .22s ease, transform .4s .22s var(--ease);
}

.music-expanded.is-open .music-expanded-controls {
  opacity: 1;
  transform: translateY(0);
}

.music-expanded-btn {
  width: 42px;
  height: 42px;
}

.music-expanded-btn svg { width: 20px; height: 20px; }

.music-expanded-play {
  width: 58px;
  height: 58px;
  color: var(--ink);
  background: radial-gradient(circle at 32% 28%, #c9bff9, var(--violet) 70%);
  box-shadow: 0 8px 24px rgba(155,140,240,.26);
}

.music-expanded-play svg { width: 24px; height: 24px; }

.music-expanded-play:hover,
.music-expanded-play:focus-visible {
  background: radial-gradient(circle at 32% 28%, #d6cdfb, var(--violet) 70%);
  transform: scale(1.06);
}

.music-spotify-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  margin-top: 26px;
  padding: 13px 22px;
  width: 100%;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 600;
  font-size: 12.5px;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--paper-dim);
  border: 1px solid var(--line);
  background: rgba(255,255,255,.02);
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .4s .26s ease, transform .35s .26s var(--ease), border-color .2s ease, color .2s ease, background .2s ease;
}

.music-expanded.is-open .music-spotify-btn {
  opacity: 1;
  transform: translateY(0);
}

.music-spotify-btn:hover,
.music-spotify-btn:focus-visible {
  color: #1db954;
  border-color: rgba(29,185,84,.35);
  background: rgba(29,185,84,.08);
}

.music-spotify-btn svg { width: 18px; height: 18px; }

@media (max-width: 480px) {
  .music-expanded { padding: 0; align-items: end; }
  .music-expanded-sheet {
    width: 100%;
    max-height: 92vh;
    border-radius: 24px 24px 0 0;
    padding-top: 12px;
    transform: translateY(100%);
  }
  .music-expanded.is-open .music-expanded-sheet { transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  .music-expanded,
  .music-expanded-sheet,
  .music-expanded-art,
  .music-expanded-ring,
  .music-expanded-meta,
  .music-expanded-progress,
  .music-expanded-controls,
  .music-expanded-play,
  .music-spotify-btn {
    transition: none !important;
    animation: none !important;
  }
}

/* ---------------------------------------------------------
   Entry overlay — "Enter with music" welcome gate
--------------------------------------------------------- */
html.has-entry-overlay,
html.has-entry-overlay body {
  overflow: hidden;
  height: 100%;
}

.entry-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(ellipse 900px 560px at 50% -8%, rgba(120,100,220,.10), transparent 60%),
    radial-gradient(ellipse 700px 520px at 92% 10%, rgba(70,55,150,.11), transparent 55%),
    radial-gradient(ellipse 620px 500px at -6% 92%, rgba(120,100,220,.07), transparent 55%),
    linear-gradient(160deg, #0a0810 0%, #08070b 55%, #050409 100%);
  animation: overlayIn .5s var(--ease) both;
}

.entry-overlay.hide {
  animation: overlayOut .55s cubic-bezier(.5,0,.75,0) forwards;
  pointer-events: none;
}

@keyframes overlayIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes overlayOut {
  0%   { opacity: 1; filter: blur(0); }
  100% { opacity: 0; filter: blur(6px); }
}

.entry-card {
  position: relative;
  width: min(100%, 360px);
  padding: 46px 30px 36px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  border-radius: 24px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(26,22,40,.6), rgba(7,6,11,.75));
  box-shadow:
    0 30px 90px rgba(0,0,0,.55),
    0 0 0 1px rgba(255,255,255,.02) inset;
  backdrop-filter: blur(22px) saturate(150%);
  -webkit-backdrop-filter: blur(22px) saturate(150%);
  overflow: hidden;
  isolation: isolate;
  animation: cardIn .7s .1s var(--ease) both;
}

.entry-card::before {
  content: "";
  position: absolute;
  inset: -40% -60%;
  z-index: -1;
  background: linear-gradient(115deg, transparent 42%, rgba(255,255,255,.06) 50%, transparent 58%);
  animation: panelSheen 8s ease-in-out infinite;
  pointer-events: none;
}

.entry-overlay.hide .entry-card {
  animation: cardOut .5s cubic-bezier(.5,0,.75,0) forwards;
}

@keyframes cardIn {
  from { opacity: 0; transform: translateY(22px) scale(.94); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes cardOut {
  to { opacity: 0; transform: translateY(-14px) scale(.92); }
}

.entry-rings {
  position: relative;
  width: 128px;
  height: 128px;
  margin-bottom: 30px;
  display: grid;
  place-items: center;
}

.entry-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1px solid var(--line);
}

.entry-ring-2 { inset: 14px; border-color: rgba(155,140,240,.16); }
.entry-ring-1 { inset: 28px; border-color: rgba(155,140,240,.24); }

.entry-ring-3 { animation: ringBreathe 3.2s ease-in-out infinite; }
.entry-ring-2 { animation: ringBreathe 3.2s .25s ease-in-out infinite; }
.entry-ring-1 { animation: ringBreathe 3.2s .5s ease-in-out infinite; }

@keyframes ringBreathe {
  0%, 100% { transform: scale(1); opacity: .55; }
  50%      { transform: scale(1.06); opacity: 1; }
}

.entry-play {
  position: relative;
  z-index: 2;
  width: 62px;
  height: 62px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--ink);
  background: radial-gradient(circle at 32% 28%, #c9bff9, var(--violet) 70%);
  box-shadow:
    0 0 0 0 rgba(155,140,240,.45),
    0 10px 30px rgba(155,140,240,.30);
  animation: playPulse 2.4s ease-in-out infinite;
}

.entry-play svg {
  width: 24px;
  height: 24px;
  transform: translateX(1px);
}

@keyframes playPulse {
  0%   { box-shadow: 0 0 0 0 rgba(155,140,240,.4), 0 10px 30px rgba(155,140,240,.30); }
  70%  { box-shadow: 0 0 0 16px rgba(155,140,240,0), 0 10px 30px rgba(155,140,240,.30); }
  100% { box-shadow: 0 0 0 0 rgba(155,140,240,0), 0 10px 30px rgba(155,140,240,.30); }
}

.entry-welcome {
  margin: 0 0 28px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--muted);
}

.entry-welcome span { color: var(--paper-dim); }

.entry-btn {
  position: relative;
  width: 100%;
  padding: 16px 20px;
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  overflow: hidden;
  font-family: var(--body);
  font-weight: 600;
  font-size: 14px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--ink);
  background: linear-gradient(135deg, #c9bff9, var(--violet) 60%, #6f5fd0);
  box-shadow: 0 14px 34px rgba(155,140,240,.24);
  transition: transform .22s var(--ease), box-shadow .22s var(--ease);
}

.entry-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: -60%;
  width: 40%;
  height: 100%;
  background: linear-gradient(115deg, transparent, rgba(255,255,255,.55), transparent);
  transform: skewX(-18deg);
  animation: entryShine 2.6s ease-in-out .6s infinite;
}

@keyframes entryShine {
  0%   { left: -60%; }
  35%  { left: 130%; }
  100% { left: 130%; }
}

.entry-btn:hover,
.entry-btn:focus-visible {
  transform: translateY(-2px) scale(1.015);
  box-shadow: 0 18px 42px rgba(155,140,240,.35);
}

.entry-btn:active {
  transform: translateY(0) scale(.98);
}

.entry-btn-label {
  position: relative;
  z-index: 1;
}

@media (prefers-reduced-motion: reduce) {
  .entry-overlay,
  .entry-card,
  .entry-ring,
  .entry-play,
  .entry-btn::before {
    animation: none !important;
  }
}
