.profiles {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  width: min(28rem, 100%);
  margin: 1.7rem auto 0;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.09), rgba(255, 255, 255, 0.018) 42%, rgba(0, 0, 0, 0.045)),
    color-mix(in srgb, var(--panel-background) 72%, transparent);
  border: 1px solid color-mix(in srgb, var(--panel-border) 72%, transparent);
  box-shadow:
    inset 0 1px rgba(255, 255, 255, 0.24),
    inset 0 -1px rgba(0, 0, 0, 0.11);
  backdrop-filter: blur(1.5px) saturate(1.12);
  -webkit-backdrop-filter: blur(1.5px) saturate(1.12);
  clip-path: polygon(3% 0, 97% 0, 100% 24%, 100% 100%, 0 100%, 0 24%);
}

.profiles::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    linear-gradient(118deg, rgba(255, 255, 255, 0.12), transparent 22% 78%, rgba(0, 0, 0, 0.035)),
    radial-gradient(ellipse at 12% 5%, rgba(255, 255, 255, 0.12), transparent 28%);
  pointer-events: none;
}

.profile-link {
  position: relative;
  z-index: 1;
  min-width: 0;
  padding: 0.72rem 0.75rem;
  overflow: visible;
  color: inherit;
  font-size: 0.86rem;
  font-weight: 650;
  text-decoration: none;
  background: transparent;
  border: 0;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  clip-path: none;
  transition:
    background-color 140ms ease,
    filter 140ms ease;
}

.profile-link::before {
  content: none;
}

.profile-link:not(:first-child)::after {
  content: "";
  position: absolute;
  top: 22%;
  bottom: 22%;
  left: 0;
  width: 1px;
  background: linear-gradient(
    180deg,
    transparent,
    color-mix(in srgb, currentColor 24%, transparent) 28% 72%,
    transparent
  );
  pointer-events: none;
}

.profile-link:hover,
.profile-link:focus-visible {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.025));
  filter: brightness(1.04);
  transform: none;
}

.profile-link:focus-visible {
  outline: 1px solid color-mix(in srgb, currentColor 52%, transparent);
  outline-offset: -4px;
}

@media (max-width: 34rem) {
  .profiles {
    gap: 0;
  }

  .profile-link {
    flex: initial;
    padding-inline: 0.5rem;
  }
}

@media print {
  .profiles {
    display: flex;
    width: auto;
    overflow: visible;
    background: transparent;
    border: 0;
    box-shadow: none;
    backdrop-filter: none;
    clip-path: none;
  }

  .profiles::before {
    display: none;
  }

  .profile-link:not(:first-child)::after {
    content: " (" attr(href) ")";
    position: static;
    display: inline;
    width: auto;
    background: none;
    font-weight: 400;
  }
}
