:root {
  --bg: #222054;
  --accent: #a78df9;
  --accent-strong: #8c52ff;
  --block-bg: rgba(167, 141, 249, 0.15);
  --block-bg-hover: rgba(167, 141, 249, 0.24);
  --font: "Nunito", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
}

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

* {
  margin: 0;
}

html {
  background: var(--bg);
  -webkit-text-size-adjust: 100%;
}

body {
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--accent);
  font-family: var(--font);
  font-size: 16px;
  font-weight: 700;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a {
  color: inherit;
  -webkit-tap-highlight-color: transparent;
}

img,
svg {
  display: block;
}

button,
a {
  font: inherit;
}

[hidden] {
  display: none !important;
}

::selection {
  background: var(--accent-strong);
  color: #fff;
}

.page {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 560px;
  min-height: 100vh;
  min-height: 100dvh;
  margin: 0 auto;
  padding: 48px 16px 30px;
}

.profile {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  text-align: center;
}

.avatar-wrap {
  position: relative;
  width: 100px;
  height: 100px;
  border-radius: 50%;
}

.avatar-fallback,
.avatar {
  width: 100%;
  height: 100%;
  border-radius: 50%;
}

.avatar-fallback {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: var(--block-bg);
  color: var(--accent);
  font-size: 40px;
  font-weight: 900;
  line-height: 1;
  user-select: none;
}

.avatar {
  position: relative;
  z-index: 1;
  object-fit: cover;
  object-position: center;
}

.name {
  margin-top: 12px;
  color: var(--accent);
  font-size: 20px;
  font-weight: 900;
  letter-spacing: 0;
  line-height: 1.25;
}

.bio {
  margin-top: 13px;
  color: var(--accent);
  font-size: 16px;
  font-weight: 700;
  line-height: 1.4;
}

.socials {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 22px;
  min-height: 28px;
  margin-top: 18px;
}

.social {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  color: var(--accent-strong);
  text-decoration: none;
  transition: color 0.18s ease, transform 0.18s ease;
}

.social svg {
  width: 28px;
  height: 28px;
}

.social:hover {
  color: var(--accent);
  transform: translateY(-1px);
}

.links {
  display: grid;
  gap: 24px;
  width: 100%;
  margin-top: 18px;
}

.link-item {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 52px;
  padding: 8px 15px;
  border: 2px solid var(--accent-strong);
  border-radius: 10px;
  background: var(--block-bg);
  color: var(--accent);
  text-decoration: none;
  transition: background 0.18s ease, border-color 0.18s ease;
}

.link-item:hover {
  border-color: var(--accent);
  background: var(--block-bg-hover);
}

.link-icon {
  display: grid;
  flex: none;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
}

.link-icon svg {
  width: 20px;
  height: 20px;
}

.link-item.is-youtube .link-icon {
  background: transparent;
}

.link-item.is-youtube .link-icon svg {
  width: 32px;
  height: 32px;
}

.link-label {
  position: absolute;
  left: 50%;
  max-width: calc(100% - 104px);
  overflow: hidden;
  color: var(--accent);
  font-size: 16px;
  font-weight: 800;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
  transform: translateX(-50%);
}

.link-item:focus-visible,
.social:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.footer {
  margin-top: auto;
  padding-top: 56px;
  padding-bottom: 6px;
  color: rgba(167, 141, 249, 0.5);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.4;
  text-align: center;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition-duration: 0.001ms !important;
  }
}
