:root {
  --bg: #f7f3eb;
  --panel: rgba(255, 255, 255, 0.82);
  --text: #1f2933;
  --muted: #52606d;
  --line: rgba(31, 41, 51, 0.12);

  --accent-1: #0e9f8b;
  --accent-2: #f97316;
  --accent-3: #2563eb;

  --radius-lg: 28px;
  --radius-md: 16px;
  --shadow: 0 30px 60px rgba(31, 41, 51, 0.18);
}

* {
  box-sizing: border-box;
}

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

body {
  font-family: "Sora", "Segoe UI", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 15% 15%, rgba(14, 159, 139, 0.16), transparent 45%),
    radial-gradient(circle at 80% 20%, rgba(37, 99, 235, 0.12), transparent 40%),
    radial-gradient(circle at 65% 85%, rgba(249, 115, 22, 0.16), transparent 45%),
    linear-gradient(135deg, #fffdf8 0%, #f7f3eb 100%);
  overflow-x: hidden;
}

.page {
  width: min(92vw, 860px);
  margin: 0 auto;
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 36px 0;
}

.profile-card {
  width: min(92vw, 540px);
  background: var(--panel);
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
  padding: 28px;
  position: relative;
  z-index: 1;
  overflow: hidden;
}

.profile-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(31, 41, 51, 0.03) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(31, 41, 51, 0.03) 1px, transparent 1px);
  background-size: 26px 26px;
  opacity: 0.55;
  pointer-events: none;
}

.profile-header,
.link-item,
.footer {
  position: relative;
  z-index: 1;
}

.avatar {
  width: 86px;
  height: 86px;
  border-radius: 50%;
  border: 2px solid rgba(31, 41, 51, 0.12);
  display: grid;
  place-items: center;
  font-family: "Space Grotesk", "Segoe UI", sans-serif;
  font-size: 1.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #ffffff;
  background: linear-gradient(145deg, var(--accent-1), var(--accent-3));
}

.handle {
  margin: 14px 0 4px;
  color: var(--muted);
  font-size: 0.95rem;
}

.name {
  margin: 0;
  font-family: "Space Grotesk", "Segoe UI", sans-serif;
  font-size: clamp(1.7rem, 5vw, 2.4rem);
  line-height: 1.08;
}

.bio {
  margin: 10px 0 20px;
  color: var(--muted);
  line-height: 1.5;
}

.link-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 12px;
}

.link-item {
  opacity: 0;
  transform: translateY(20px);
  animation: rise 580ms cubic-bezier(.2, .72, .2, 1) forwards;
  animation-delay: calc(220ms + (var(--i, 0) * 90ms));
}

.link {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: #ffffff;
  padding: 14px 15px;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.link:hover,
.link:focus-visible {
  transform: translateY(-2px);
  border-color: var(--accent-color, var(--accent-3));
  box-shadow: 0 14px 28px rgba(31, 41, 51, 0.12);
}

.link-text {
  min-width: 0;
}

.link-title {
  margin: 0;
  font-weight: 600;
  font-size: 1rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.link-url {
  margin: 3px 0 0;
  font-size: 0.84rem;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
}

.link-arrow {
  color: var(--accent-color, var(--accent-3));
  font-size: 1.1rem;
  font-weight: 700;
}

.footer {
  margin-top: 18px;
  font-size: 0.84rem;
  color: var(--muted);
}

.reveal {
  opacity: 0;
  transform: translateY(12px);
  animation: appear 680ms ease forwards;
}

.footer.reveal {
  animation-delay: 620ms;
}

.bg-shape {
  position: fixed;
  border-radius: 999px;
  filter: blur(8px);
  pointer-events: none;
  z-index: 0;
  opacity: 0.5;
}

.bg-shape-a {
  width: 220px;
  height: 220px;
  background: radial-gradient(circle at 30% 30%, rgba(14, 159, 139, 0.34), rgba(14, 159, 139, 0));
  top: 8%;
  left: 5%;
  animation: drift 8s ease-in-out infinite alternate;
}

.bg-shape-b {
  width: 280px;
  height: 280px;
  background: radial-gradient(circle at 60% 40%, rgba(249, 115, 22, 0.3), rgba(249, 115, 22, 0));
  bottom: 4%;
  right: 3%;
  animation: drift 9s ease-in-out infinite alternate-reverse;
}

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

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

@keyframes drift {
  from {
    transform: translate(0, 0);
  }
  to {
    transform: translate(16px, -12px);
  }
}

@media (max-width: 540px) {
  .profile-card {
    padding: 22px;
    border-radius: 20px;
  }

  .avatar {
    width: 74px;
    height: 74px;
    font-size: 1.42rem;
  }

  .link {
    padding: 13px;
  }

  .link-title {
    font-size: 0.95rem;
  }
}
