/* Shared loading skeleton for private and public profiles. */

.profile-skeleton-content {
    display: grid;
}

.profile-skeleton-avatar,
.profile-skeleton-identity span,
.profile-skeleton-bio span,
.profile-skeleton-stats span,
.profile-skeleton-section-title,
.profile-skeleton-review span,
.profile-skeleton-posters span {
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0.055),
        rgba(198, 139, 93, 0.16),
        rgba(255, 255, 255, 0.055)
    );
    background-size: 220% 100%;
    animation: profile-skeleton-shimmer 1400ms ease-in-out infinite;
}

.profile-skeleton-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 18px;
}

.profile-skeleton-avatar {
    width: 70px;
    height: 70px;
    flex: 0 0 auto;
    border-radius: 50%;
}

.profile-skeleton-identity {
    flex: 1;
    display: grid;
    gap: 9px;
}

.profile-skeleton-identity span,
.profile-skeleton-bio span,
.profile-skeleton-review span,
.profile-skeleton-section-title {
    display: block;
    border-radius: 999px;
}

.profile-skeleton-name {
    width: min(150px, 68%);
    height: 18px;
}

.profile-skeleton-username {
    width: min(96px, 48%);
    height: 11px;
}

.profile-skeleton-bio {
    display: grid;
    justify-items: center;
    gap: 8px;
    margin-bottom: 24px;
}

.profile-skeleton-bio span {
    width: min(280px, 84%);
    height: 10px;
}

.profile-skeleton-bio span:last-child {
    width: min(190px, 58%);
}

.profile-skeleton-stats {
    display: flex;
    gap: 8px;
    margin-bottom: 28px;
}

.profile-skeleton-stats span {
    width: 76px;
    height: 26px;
    border-radius: 999px;
}

.profile-skeleton-section + .profile-skeleton-section {
    margin-top: 26px;
}

.profile-skeleton-section-title {
    width: 92px;
    height: 12px;
    margin-bottom: 12px;
}

.profile-skeleton-review {
    min-height: 92px;
    display: grid;
    align-content: center;
    gap: 10px;
    padding: 14px 15px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.025);
}

.profile-skeleton-review span {
    width: 62%;
    height: 11px;
}

.profile-skeleton-review span:nth-child(2) {
    width: 100%;
}

.profile-skeleton-review span:last-child {
    width: 78%;
}

.profile-skeleton-posters {
    display: flex;
    gap: 12px;
    overflow: hidden;
}

.profile-skeleton-posters span {
    width: 112px;
    aspect-ratio: 2 / 3;
    flex: 0 0 auto;
    border-radius: 14px;
}

@keyframes profile-skeleton-shimmer {
    0% {
        background-position: 100% 0;
    }

    100% {
        background-position: -100% 0;
    }
}

@media (max-width: 420px) {
    .profile-skeleton-avatar {
        width: 64px;
        height: 64px;
    }

    .profile-skeleton-posters span {
        width: 104px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .profile-skeleton-avatar,
    .profile-skeleton-identity span,
    .profile-skeleton-bio span,
    .profile-skeleton-stats span,
    .profile-skeleton-section-title,
    .profile-skeleton-review span,
    .profile-skeleton-posters span {
        animation: none;
    }
}
