/* ============================================================
   Lambe — link-in-bio
   Dark minimal + verde lime neon
   ============================================================ */

:root {
  --bg: #08080a;
  --card: rgba(16, 18, 14, 0.62);
  --text: #f4f7ee;
  --muted: #9aa88f;
  --line: rgba(255, 255, 255, 0.08);
  --lime: #a3e635;
  --lime-soft: #e4ff9a;
  --green: #22c55e;
  --teal: #22d3ee;
  --grad: linear-gradient(120deg, #f7ffcf 0%, #d9f99d 20%, #bef264 42%, #a3e635 68%, #84cc16 100%);
  --radius: 28px;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-head: "Outfit", "Inter", system-ui, sans-serif;
}

*,
*::before,
*::after { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: 32px 18px;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(85px);
  opacity: 0.5;
  will-change: transform;
}

.blob--1 {
  width: 46vmax;
  height: 46vmax;
  left: -12vmax;
  top: -14vmax;
  background: radial-gradient(circle at 30% 30%, #a3e635, transparent 65%);
  animation: drift1 22s ease-in-out infinite alternate;
}

.blob--2 {
  width: 40vmax;
  height: 40vmax;
  right: -10vmax;
  bottom: -12vmax;
  background: radial-gradient(circle at 60% 60%, #65a30d, transparent 65%);
  animation: drift2 26s ease-in-out infinite alternate;
}

.blob--3 {
  width: 32vmax;
  height: 32vmax;
  right: 16%;
  top: 6%;
  background: radial-gradient(circle at 50% 50%, #bef264, transparent 65%);
  opacity: 0.38;
  animation: drift3 30s ease-in-out infinite alternate;
}

@keyframes drift1 {
  to { transform: translate3d(12vmax, 8vmax, 0) scale(1.15); }
}
@keyframes drift2 {
  to { transform: translate3d(-12vmax, -8vmax, 0) scale(1.1); }
}
@keyframes drift3 {
  to { transform: translate3d(-8vmax, 10vmax, 0) scale(0.9); }
}

/* particelle luminose */
.particles {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.9;
}

.grain {
  position: absolute;
  inset: -50%;
  opacity: 0.055;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: overlay;
}

/* ---------- card ---------- */
.card {
  position: relative;
  z-index: 1;
  width: min(100%, 430px);
  padding: 38px 30px 26px;
  border-radius: var(--radius);
  background: var(--card);
  border: 1px solid var(--line);
  backdrop-filter: blur(22px) saturate(140%);
  -webkit-backdrop-filter: blur(22px) saturate(140%);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.06) inset,
    0 30px 80px -30px rgba(0, 0, 0, 0.9),
    0 0 90px -40px rgba(163, 230, 53, 0.35);
  overflow: hidden;
  animation: rise 0.9s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

/* bordo gradiente */
.card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(150deg, rgba(217, 249, 157, 0.9), rgba(163, 230, 53, 0.45) 35%, transparent 60%, rgba(132, 204, 22, 0.55));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

/* alone che segue il cursore */
.card__glow {
  position: absolute;
  width: 360px;
  height: 360px;
  left: 50%;
  top: 0;
  translate: -50% -50%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(163, 230, 53, 0.18), transparent 60%);
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
  will-change: left, top;
}
.card:hover .card__glow { opacity: 1; }

@keyframes rise {
  from { opacity: 0; transform: translateY(18px) scale(0.985); }
  to { opacity: 1; transform: none; }
}

/* ---------- testa ---------- */
.head {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  animation: rise 0.9s 0.08s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.avatar {
  position: relative;
  width: 108px;
  height: 108px;
  display: grid;
  place-items: center;
}

.avatar__ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: conic-gradient(from 0deg, #a3e635, #d9f99d, #bef264, #84cc16, #d9f99d, #a3e635);
  animation: spin 7s linear infinite;
  filter: blur(0.3px);
  opacity: 0.95;
}

@keyframes spin { to { transform: rotate(360deg); } }

.avatar__inner {
  position: relative;
  width: 96px;
  height: 96px;
  border-radius: 50%;
  overflow: hidden;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at 30% 25%, #22261c, #0e100c);
  box-shadow: 0 0 0 3px #0b0b0f, 0 0 0 4px rgba(255, 255, 255, 0.06);
}

.avatar__inner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.avatar__initials {
  font-family: var(--font-head);
  font-size: 40px;
  font-weight: 800;
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.avatar__status {
  position: absolute;
  right: 9px;
  bottom: 9px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #34d399;
  border: 3px solid #0b0b0f;
  box-shadow: 0 0 12px rgba(52, 211, 153, 0.85);
  animation: statusPulse 2.4s ease-in-out infinite;
}

@keyframes statusPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.55); }
  50% { box-shadow: 0 0 0 6px rgba(52, 211, 153, 0); }
}

.name {
  margin: 18px 0 4px;
  font-family: var(--font-head);
  font-size: clamp(2.1rem, 8vw, 2.6rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.05;
  background: var(--grad);
  background-size: 220% 220%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: shimmer 6s ease-in-out infinite;
}

.name span {
  display: inline-block;
  animation: letterIn 0.75s cubic-bezier(0.2, 0.9, 0.25, 1.2) both;
  animation-delay: calc(0.18s + var(--i, 0) * 0.055s);
}

@keyframes letterIn {
  from { opacity: 0; transform: translateY(20px) rotate(7deg); filter: blur(7px); }
  to { opacity: 1; transform: none; filter: blur(0); }
}

@keyframes shimmer {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

.handle {
  margin: 0;
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.bio {
  margin: 20px auto 26px;
  max-width: 32ch;
  text-align: center;
  font-size: 0.95rem;
  line-height: 1.6;
  color: #c6cfba;
  animation: rise 0.9s 0.16s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

/* ---------- link ---------- */
.links {
  display: flex;
  flex-direction: column;
  gap: 10px;
  animation: rise 0.9s 0.24s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.link {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 13px 16px;
  border-radius: 16px;
  text-decoration: none;
  color: var(--text);
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(255, 255, 255, 0.07);
  transition: transform 0.25s ease, background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
  overflow: hidden;
}

/* riflesso che attraversa il link */
.link::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(105deg, transparent 30%, rgba(217, 249, 157, 0.16) 50%, transparent 70%);
  transform: translateX(-130%);
  pointer-events: none;
}
.link:hover::before,
.link:focus-visible::before {
  transform: translateX(130%);
  transition: transform 0.75s ease;
}

.link > * { position: relative; z-index: 1; }

.link:hover,
.link:focus-visible {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(163, 230, 53, 0.4);
  box-shadow:
    0 10px 30px -12px rgba(163, 230, 53, 0.5),
    0 0 0 1px rgba(163, 230, 53, 0.16);
  outline: none;
}

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

.link__icon {
  flex: 0 0 38px;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.06);
  color: #e8efdc;
  transition: color 0.25s ease, background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

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

.link:hover .link__icon {
  color: #fff;
  background: rgba(163, 230, 53, 0.16);
  border-color: rgba(163, 230, 53, 0.35);
  box-shadow: 0 0 18px -4px rgba(163, 230, 53, 0.6);
}

.link__label {
  flex: 1;
  font-size: 0.98rem;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.link__arrow {
  width: 18px;
  height: 18px;
  color: var(--muted);
  opacity: 0.6;
  transform: translate(-2px, 2px);
  transition: transform 0.25s ease, opacity 0.25s ease, color 0.25s ease;
}

.link:hover .link__arrow {
  transform: translate(0, 0);
  opacity: 1;
  color: var(--lime-soft);
}

/* ---------- footer ---------- */
.foot {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  color: #79856e;
}

.foot__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--grad);
  box-shadow: 0 0 10px rgba(163, 230, 53, 0.9);
  animation: pulse 2.4s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.8); }
}

/* ---------- pulsante musica ---------- */
.music {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 5;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  cursor: pointer;
  color: var(--lime-soft);
  background: rgba(16, 20, 12, 0.72);
  border: 1px solid rgba(163, 230, 53, 0.4);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 10px 30px -12px rgba(0, 0, 0, 0.8);
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.music::after {
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 1px solid rgba(163, 230, 53, 0.5);
  animation: nudge 2.6s ease-out infinite;
  pointer-events: none;
}

@keyframes nudge {
  0% { transform: scale(0.92); opacity: 0.8; }
  70%, 100% { transform: scale(1.28); opacity: 0; }
}

.music:hover {
  transform: translateY(-2px) scale(1.05);
  border-color: rgba(163, 230, 53, 0.8);
  box-shadow: 0 0 30px -6px rgba(163, 230, 53, 0.55);
}

.music:focus-visible {
  outline: 2px solid var(--lime);
  outline-offset: 3px;
}

.music__play {
  width: 18px;
  height: 18px;
  margin-left: 2px;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.music__bars {
  position: absolute;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 2px;
  height: 18px;
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
}

.music__bars i {
  width: 2.5px;
  height: 100%;
  border-radius: 2px;
  background: var(--lime-soft);
  transform: scaleY(0.15);
  transform-origin: bottom;
  transition: transform 0.08s linear;
}

/* stato in riproduzione */
.music.is-playing { border-color: rgba(163, 230, 53, 0.85); box-shadow: 0 0 24px -6px rgba(163, 230, 53, 0.6); }
.music.is-playing .music__play { opacity: 0; transform: scale(0.6); }
.music.is-playing .music__bars { opacity: 1; }
.music.is-playing::after { animation: none; opacity: 0; }

/* ---------- accessibilità / motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  .name span { opacity: 1; }
}

@media (max-width: 380px) {
  .card { padding: 30px 20px 20px; border-radius: 22px; }
  .avatar { width: 92px; height: 92px; }
  .avatar__inner { width: 82px; height: 82px; }
}
