.viewer-cosmetic-avatar {
    --viewer-avatar-rarity: #8e3cff;

    position: relative;
    z-index: 1;

    display: block;
    flex: 0 0 auto;

    isolation: isolate;
}

.viewer-cosmetic-avatar--header {
    width: 34px;
    height: 34px;

    border-radius: 50%;
}

.viewer-cosmetic-avatar--sidebar {
    width: 42px;
    height: 42px;

    border-radius: 10px;
}

.viewer-cosmetic-avatar__base {
    position: absolute;
    inset: 0;
    z-index: 1;

    overflow: hidden;

    display: grid;
    place-items: center;

    border: 1px solid
        color-mix(
            in srgb,
            var(--viewer-avatar-rarity) 62%,
            rgba(255, 255, 255, .16)
        );
    border-radius: inherit;

    color: #fff;
    background:
        linear-gradient(
            135deg,
            #7040dc,
            #b53cff
        );

    box-shadow:
        0 0 15px
        color-mix(
            in srgb,
            var(--viewer-avatar-rarity) 28%,
            transparent
        );

    font-weight: 900;
}

.viewer-cosmetic-avatar--header.has-frame
.viewer-cosmetic-avatar__base {
    inset: 3px;
}

.viewer-cosmetic-avatar--sidebar.has-frame
.viewer-cosmetic-avatar__base {
    inset: 4px;
}

.viewer-cosmetic-avatar__base > img {
    width: 100%;
    height: 100%;

    display: block;
    object-fit: cover;
}

.viewer-cosmetic-avatar--header
.viewer-cosmetic-avatar__base > span {
    font-size: 12px;
}

.viewer-cosmetic-avatar--sidebar
.viewer-cosmetic-avatar__base > span {
    font-size: 15px;
}

.viewer-cosmetic-avatar__frame {
    position: absolute;
    inset: -2px;
    z-index: 3;

    width: calc(100% + 4px);
    height: calc(100% + 4px);

    display: block;
    object-fit: contain;

    pointer-events: none;

    filter:
        drop-shadow(
            0 0 7px
            color-mix(
                in srgb,
                var(--viewer-avatar-rarity) 46%,
                transparent
            )
        );
}

.community-header-bell {
    position: relative;
    text-decoration: none;
    cursor: pointer;
}

.community-header-bell:hover,
.profile-community-bell:hover {
    border-color: rgba(145, 75, 245, .46);
    color: #b896ef;
}

.community-unread-badge {
    position: absolute;
    top: -5px;
    right: -5px;

    min-width: 19px;
    height: 19px;
    padding: 0 5px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    border: 2px solid #070a14;
    border-radius: 999px;

    color: #fff;
    background: #8f43f5;

    font-size: 7px;
    font-weight: 900;
    line-height: 1;
}

.community-sidebar-count {
    min-width: 19px;
    height: 18px;
    padding: 0 5px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    border-radius: 999px;

    color: #e9dcff !important;
    background: rgba(132, 67, 232, .18);

    font-size: 6px !important;
}

.profile-header-actions {
    gap: 7px;
}

.profile-community-bell {
    position: relative;

    width: 42px;
    height: 42px;

    display: grid;
    place-items: center;

    border: 1px solid rgba(85, 77, 136, .44);
    border-radius: 9px;

    color: #8069a7;
    background: rgba(8, 11, 22, .96);

    text-decoration: none;
}

.profile-community-bell > span {
    font-size: 13px;
}

.profile-community-bell > small {
    position: absolute;
    top: -5px;
    right: -5px;

    min-width: 19px;
    height: 19px;
    padding: 0 5px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    border: 2px solid #070a14;
    border-radius: 999px;

    color: #fff;
    background: #8f43f5;

    font-size: 7px;
    font-weight: 900;
}

.account-future-grid > .community-live-tile {
    min-height: 88px;
    padding: 11px;

    display: grid;
    place-items: center;
    align-content: center;
    gap: 5px;

    border: 1px solid rgba(132, 93, 201, .28);
    border-radius: 8px;

    color: #7f6ba5;
    background:
        radial-gradient(
            circle at 50% 0%,
            rgba(132, 67, 232, .08),
            transparent 70%
        ),
        rgba(5, 8, 17, .62);

    text-align: center;
    text-decoration: none;
}

.account-future-grid > .community-live-tile:hover {
    border-color: rgba(145, 75, 245, .48);
    transform: translateY(-1px);
}

.account-future-grid > .community-live-tile > span {
    color: #a96bff;
    font-size: 17px;
}

.account-future-grid > .community-live-tile strong {
    color: #c7bdd7;
}

.account-future-grid > .community-live-tile small {
    color: #8f59d5;
}

.community-page {
    display: grid;
    gap: 14px;
}

.community-hero {
    padding: 18px;

    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 18px;

    border: 1px solid rgba(125, 79, 213, .20);
    border-radius: 11px;

    background:
        radial-gradient(
            circle at 88% 0%,
            rgba(91, 59, 193, .12),
            transparent 36%
        ),
        linear-gradient(
            145deg,
            rgba(10, 15, 29, .97),
            rgba(7, 10, 20, .97)
        );
}

.community-kicker,
.community-panel__head span,
.community-stats span,
.community-field > span {
    color: #795ba7;
    font-size: 8px;
    font-weight: 900;
    letter-spacing: 1.05px;
}

.community-hero h1 {
    margin: 5px 0 0;
    color: #f5f6ff;
    font-size: 25px;
    line-height: 1.05;
}

.community-hero p {
    max-width: 760px;
    margin: 7px 0 0;
    color: #7f899f;
    font-size: 9px;
    line-height: 1.6;
}

.community-button,
.community-link-button {
    border: 0;
    font: inherit;
    cursor: pointer;
}

.community-button {
    min-height: 38px;
    padding: 0 13px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    border: 1px solid rgba(147, 75, 246, .48);
    border-radius: 8px;

    color: #fff;
    background:
        linear-gradient(
            135deg,
            rgba(126, 60, 230, .96),
            rgba(92, 61, 206, .96)
        );

    font-size: 8px;
    font-weight: 850;
    text-decoration: none;
}

.community-button--secondary {
    border-color: rgba(255, 255, 255, .075);
    color: #a8b0c4;
    background: rgba(255, 255, 255, .02);
}

.community-button--danger {
    border-color: rgba(255, 91, 125, .20);
    color: #ff9caf;
    background: rgba(255, 91, 125, .05);
}

.community-link-button {
    padding: 0;
    color: #9a74cd;
    background: transparent;
    font-size: 8px;
    font-weight: 800;
}

.community-alert {
    padding: 11px 13px;

    border: 1px solid rgba(255, 255, 255, .07);
    border-radius: 8px;

    color: #929bb0;
    background: rgba(255, 255, 255, .025);

    font-size: 8px;
    line-height: 1.55;
}

.community-alert.is-success {
    color: #86ddb6;
    border-color: rgba(85, 230, 165, .18);
    background: rgba(85, 230, 165, .045);
}

.community-alert.is-error {
    color: #ff98ac;
    border-color: rgba(255, 91, 125, .20);
    background: rgba(255, 91, 125, .05);
}

.community-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 9px;
}

.community-stats article,
.community-panel {
    border: 1px solid rgba(255, 255, 255, .06);
    border-radius: 10px;

    background:
        linear-gradient(
            145deg,
            rgba(10, 15, 29, .96),
            rgba(7, 10, 20, .96)
        );

    box-shadow: 0 18px 44px rgba(0, 0, 0, .20);
}

.community-stats article {
    min-height: 95px;
    padding: 14px;

    display: grid;
    align-content: center;
    gap: 7px;
}

.community-stats strong {
    color: #f4f6ff;
    font-size: 21px;
}

.community-panel {
    padding: 16px;
}

.community-panel__head {
    margin-bottom: 13px;

    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.community-panel__head > div {
    display: grid;
    gap: 4px;
}

.community-panel__head h2 {
    margin: 0;
    color: #edf0f8;
    font-size: 14px;
}

.community-panel__head > small {
    color: #69738a;
    font-size: 7px;
}

.community-empty {
    min-height: 145px;

    display: grid;
    place-items: center;
    align-content: center;
    gap: 5px;

    color: #68728a;
    text-align: center;
}

.community-empty--compact {
    min-height: 110px;
}

.community-empty strong {
    color: #9ba4b7;
    font-size: 10px;
}

.community-empty span {
    font-size: 8px;
}

.community-notification-list {
    display: grid;
    gap: 8px;
}

.community-notification {
    padding: 12px;

    display: grid;
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 10px;

    border: 1px solid rgba(255, 255, 255, .045);
    border-radius: 9px;

    background: rgba(4, 7, 15, .55);
}

.community-notification.is-unread {
    border-color: rgba(142, 72, 244, .25);
    background: rgba(112, 58, 198, .055);
}

.community-notification.is-system {
    box-shadow:
        inset 3px 0 0 rgba(157, 89, 255, .48);
}

.community-notification__marker {
    width: 34px;
    height: 34px;

    display: grid;
    place-items: center;

    border: 1px solid rgba(140, 76, 232, .18);
    border-radius: 9px;

    color: #a16add;
    background: rgba(117, 61, 210, .045);

    font-size: 11px;
}

.community-notification__body {
    min-width: 0;
    display: grid;
    gap: 7px;
}

.community-notification__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;

    color: #657087;
    font-size: 7px;
}

.community-notification__meta b {
    padding: 3px 5px;

    border: 1px solid rgba(145, 75, 245, .16);
    border-radius: 5px;

    color: #a878e5;
    background: rgba(117, 61, 210, .045);

    font-size: 5px;
    letter-spacing: .5px;
}

.community-notification__meta time {
    margin-left: auto;
}

.community-notification h3 {
    margin: 0;
    color: #e6e9f2;
    font-size: 10px;
}

.community-notification p {
    margin: 0;
    color: #7b859c;
    font-size: 8px;
    line-height: 1.55;
}

.community-notification__actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.community-read-state {
    color: #59647a;
    font-size: 7px;
}

.community-pagination {
    margin-top: 12px;
    min-height: 48px;

    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 12px;

    border-top: 1px solid rgba(255, 255, 255, .05);

    color: #778199;
    font-size: 8px;
}

.community-pagination a,
.community-pagination > span {
    width: fit-content;
    padding: 7px 9px;

    border: 1px solid rgba(255, 255, 255, .055);
    border-radius: 7px;

    color: #8f79b5;
    background: rgba(255, 255, 255, .018);

    text-decoration: none;
}

.community-pagination > *:last-child {
    justify-self: end;
}

.community-pagination .is-disabled {
    opacity: .42;
}

.community-pagination strong {
    color: #717b91;
    font-size: 8px;
}

.community-grid--blacklist {
    display: grid;
    grid-template-columns:
        minmax(300px, .7fr)
        minmax(0, 1.3fr);
    gap: 12px;
}

.community-form {
    display: grid;
    gap: 11px;
}

.community-field {
    display: grid;
    gap: 6px;
}

.community-field > span small {
    color: #626c82;
    font-size: 6px;
    font-weight: 700;
    letter-spacing: 0;
}

.community-field input,
.community-field textarea {
    width: 100%;
    padding: 0 11px;

    border: 1px solid rgba(255, 255, 255, .07);
    border-radius: 8px;
    outline: 0;

    color: #e1e5ef;
    background: rgba(4, 7, 15, .72);

    font-size: 9px;
}

.community-field input {
    min-height: 40px;
}

.community-field textarea {
    min-height: 92px;
    padding-top: 10px;
    resize: vertical;
}

.community-field input:focus,
.community-field textarea:focus {
    border-color: rgba(145, 75, 245, .46);
    box-shadow: 0 0 0 3px rgba(125, 59, 226, .06);
}

.community-foundation-note {
    margin-top: 13px;
    padding: 11px;

    border: 1px solid rgba(126, 86, 226, .12);
    border-radius: 8px;

    background: rgba(116, 58, 205, .025);
}

.community-foundation-note strong {
    color: #b79ada;
    font-size: 8px;
}

.community-foundation-note p {
    margin: 5px 0 0;
    color: #667089;
    font-size: 7px;
    line-height: 1.55;
}

.community-blacklist-list {
    display: grid;
    gap: 7px;
}

.community-blacklist-row {
    padding: 10px;

    display: grid;
    grid-template-columns:
        40px
        minmax(0, 1fr)
        auto;
    align-items: center;
    gap: 10px;

    border: 1px solid rgba(255, 255, 255, .045);
    border-radius: 8px;

    background: rgba(4, 7, 15, .55);
}

.community-avatar {
    width: 40px;
    height: 40px;

    display: grid;
    place-items: center;

    border-radius: 10px;

    color: #fff;
    background:
        linear-gradient(
            135deg,
            #7040dc,
            #b53cff
        );

    font-size: 13px;
    font-weight: 900;
}

.community-blacklist-row__copy {
    min-width: 0;
    display: grid;
    gap: 3px;
}

.community-blacklist-row__copy a {
    width: fit-content;
    color: #ddd5ea;
    font-size: 9px;
    font-weight: 850;
    text-decoration: none;
}

.community-blacklist-row__copy a:hover {
    color: #b88af0;
}

.community-blacklist-row__copy span {
    color: #626d83;
    font-size: 7px;
}

.community-blacklist-row__copy p {
    margin: 2px 0 0;
    color: #7a849a;
    font-size: 7px;
    line-height: 1.45;
}

@media (max-width: 880px) {
    .community-hero {
        align-items: flex-start;
        flex-direction: column;
    }

    .community-grid--blacklist {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 650px) {
    .community-stats {
        grid-template-columns: 1fr;
    }

    .community-notification {
        grid-template-columns: 1fr;
    }

    .community-notification__meta time {
        width: 100%;
        margin-left: 0;
    }

    .community-blacklist-row {
        grid-template-columns: 40px minmax(0, 1fr);
    }

    .community-blacklist-row > form {
        grid-column: 1 / -1;
    }

    .community-blacklist-row > form .community-button {
        width: 100%;
    }

    .community-pagination {
        grid-template-columns: 1fr;
        justify-items: start;
        padding: 12px 0 0;
    }

    .community-pagination > *:last-child {
        justify-self: start;
    }
}


/* ================================================================
   Notifications UX v2
   ================================================================ */

.community-notification-center {
    position: relative;
    flex: 0 0 auto;
}

.community-notification-trigger {
    position: relative;
    cursor: pointer;
}

.community-notification-trigger .community-notification-bell {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.7;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.community-notification-new-dot {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 7px;
    height: 7px;
    border: 2px solid #070a14;
    border-radius: 999px;
    background: #9a4dff;
    box-shadow:
        0 0 0 2px rgba(154, 77, 255, .08),
        0 0 9px rgba(154, 77, 255, .72);
}

.community-notification-center--home
.community-notification-new-dot {
    top: 7px;
    right: 7px;
}

.community-notification-center--site
.profile-community-bell {
    border: 1px solid rgba(85, 77, 136, .44);
}

.community-notification-center--site
.profile-community-bell:hover,
.community-notification-center--account
.community-header-bell:hover {
    border-color: rgba(145, 75, 245, .46);
    color: #b896ef;
}

.community-notification-dropdown {
    position: absolute;
    z-index: 1200;
    top: calc(100% + 11px);
    right: 0;
    width: min(390px, calc(100vw - 24px));
    max-height: min(590px, calc(100vh - 100px));
    overflow: hidden;
    border: 1px solid rgba(135, 81, 221, .26);
    border-radius: 12px;
    background:
        radial-gradient(
            circle at 88% 0%,
            rgba(123, 62, 222, .13),
            transparent 38%
        ),
        rgba(7, 10, 20, .985);
    box-shadow:
        0 26px 70px rgba(0, 0, 0, .54),
        0 0 0 1px rgba(255, 255, 255, .018);
    backdrop-filter: blur(18px);
}

.community-notification-dropdown[hidden] {
    display: none !important;
}

.community-notification-dropdown__head {
    min-height: 66px;
    padding: 13px 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, .055);
}

.community-notification-dropdown__head > div {
    min-width: 0;
    display: grid;
    gap: 3px;
}

.community-notification-dropdown__head span {
    color: #795ba7;
    font-size: 7px;
    font-weight: 900;
    letter-spacing: 1px;
}

.community-notification-dropdown__head strong {
    color: #f0f2f8;
    font-size: 12px;
}

.community-notification-dropdown__head small {
    padding: 5px 7px;
    border: 1px solid rgba(145, 75, 245, .15);
    border-radius: 999px;
    color: #ad82df;
    background: rgba(120, 72, 240, .045);
    font-size: 6px;
    font-weight: 850;
}

.community-notification-dropdown__list {
    max-height: 255px;
    overflow-y: auto;
}

.community-notification-preview {
    margin: 0;
    border: 0;
    border-bottom: 1px solid rgba(255, 255, 255, .045);
}

.community-notification-preview:last-child {
    border-bottom: 0;
}

.community-notification-preview__button {
    width: 100%;
    padding: 11px 12px;
    display: grid;
    grid-template-columns: 32px minmax(0, 1fr) 16px;
    align-items: center;
    gap: 9px;
    border: 0;
    color: inherit;
    background: rgba(255, 255, 255, .004);
    text-align: left;
    cursor: pointer;
}

.community-notification-preview__button:hover {
    background: rgba(127, 67, 220, .07);
}

.community-notification-preview.is-unread
.community-notification-preview__button {
    background: rgba(127, 67, 220, .045);
}

.community-notification-preview__icon {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(141, 76, 235, .17);
    border-radius: 8px;
    color: #aa72e9;
    background: rgba(117, 61, 210, .045);
    font-size: 9px;
}

.community-notification-preview__copy {
    min-width: 0;
    display: grid;
    gap: 3px;
}

.community-notification-preview__meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    color: #626d84;
    font-size: 6px;
}

.community-notification-preview__meta b {
    overflow: hidden;
    color: #8f69bd;
    font-size: 6px;
    font-weight: 800;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.community-notification-preview__meta time {
    flex: 0 0 auto;
}

.community-notification-preview__copy > strong {
    overflow: hidden;
    color: #dfe3ed;
    font-size: 8px;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.community-notification-preview.is-unread
.community-notification-preview__copy > strong {
    color: #f3f0f9;
}

.community-notification-preview__body {
    display: -webkit-box;
    overflow: hidden;
    color: #778198;
    font-size: 7px;
    line-height: 1.42;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.community-notification-preview__copy > small {
    color: #69577e;
    font-size: 6px;
}

.community-notification-preview__arrow {
    color: #74579a;
    font-size: 10px;
}

.community-notification-dropdown__footer {
    min-height: 48px;
    padding: 8px 10px;
    display: flex;
    align-items: center;
    border-top: 1px solid rgba(255, 255, 255, .055);
}

.community-notification-dropdown__all {
    width: 100%;
    min-height: 32px;
    padding: 0 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 1px solid rgba(139, 76, 232, .14);
    border-radius: 7px;
    color: #a77bdc;
    background: rgba(117, 61, 210, .035);
    font-size: 7px;
    font-weight: 850;
    text-decoration: none;
}

.community-notification-dropdown__all:hover {
    border-color: rgba(145, 75, 245, .30);
    color: #c09dec;
}

.community-notification-dropdown__empty,
.community-notification-dropdown__guest {
    min-height: 145px;
    padding: 18px;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 6px;
    color: #69738a;
    text-align: center;
}

.community-notification-dropdown__empty strong,
.community-notification-dropdown__guest strong {
    color: #a7afc0;
    font-size: 9px;
}

.community-notification-dropdown__empty span,
.community-notification-dropdown__guest span {
    max-width: 240px;
    font-size: 7px;
    line-height: 1.5;
}

.community-notification-dropdown__guest
.community-notification-dropdown__all {
    width: auto;
    margin-top: 5px;
    padding: 0 18px;
}

/* Message Dropdown UX v2: three latest dialogs in the global header. */

.private-message-dropdown-preview
.community-notification-preview__button {
    text-decoration: none;
}

.private-message-dropdown-preview__avatar {
    color: #d7b8ff;
    background:
        linear-gradient(
            145deg,
            rgba(126, 59, 223, .25),
            rgba(50, 33, 91, .24)
        );
    font-size: 10px;
    font-weight: 900;
}

.private-message-dropdown-preview__state {
    width: fit-content;
    font-size: 6px;
    font-weight: 800;
}

.private-message-dropdown-preview__state.is-unread {
    color: #b989ef;
}

.private-message-dropdown-preview__state.is-read {
    color: #647087;
}

.private-message-dropdown-preview.is-unread
.private-message-dropdown-preview__avatar {
    border-color: rgba(161, 91, 255, .36);
    box-shadow: 0 0 16px rgba(126, 59, 223, .12);
}

/* Remove old literal dot / numeric badge presentation. */
.profile-community-bell > span,
.profile-community-bell > small,
.community-unread-badge {
    display: none !important;
}

@media (max-width: 650px) {
    .community-notification-dropdown {
        position: fixed;
        top: 68px;
        right: 12px;
        left: 12px;
        width: auto;
        max-height: calc(100vh - 86px);
    }

    .community-notification-dropdown__list {
        max-height: min(
            255px,
            calc(100vh - 230px)
        );
    }
}


/* ================================================================
   Friends Core v1
   ================================================================ */

.community-friends {
    scroll-behavior: smooth;
}

.community-friend-search__form {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    align-items: end;
    gap: 8px;
}

.community-friend-search__form .community-button {
    min-height: 40px;
}

.community-friend-search .community-friend-list {
    margin-top: 13px;
}

.community-friends-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.community-friend-list {
    display: grid;
    gap: 7px;
}

.community-friend-list--accepted {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.community-friend-row {
    min-width: 0;
    padding: 10px;
    display: grid;
    grid-template-columns: 40px minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    border: 1px solid rgba(255, 255, 255, .045);
    border-radius: 8px;
    background: rgba(4, 7, 15, .55);
}

.community-friend-row.is-focused {
    border-color: rgba(145, 75, 245, .44);
    box-shadow:
        0 0 0 3px rgba(125, 59, 226, .06),
        inset 3px 0 0 rgba(157, 89, 255, .48);
}

.community-friend-row__copy {
    min-width: 0;
    display: grid;
    gap: 4px;
}

.community-friend-row__copy a {
    width: fit-content;
    max-width: 100%;
    overflow: hidden;
    color: #e2dbea;
    font-size: 9px;
    font-weight: 850;
    text-decoration: none;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.community-friend-row__copy a:hover {
    color: #ba8ff0;
}

.community-friend-row__copy span,
.community-friend-state {
    color: #68738a;
    font-size: 7px;
}

.community-friend-row__actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 6px;
}

.community-friend-row__actions form {
    display: flex;
}

.community-friend-row__actions .community-button {
    min-height: 34px;
    padding: 0 10px;
}

@media (max-width: 1080px) {
    .community-friends-grid,
    .community-friend-list--accepted {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 720px) {
    .community-friend-search__form {
        grid-template-columns: 1fr;
    }

    .community-friend-row {
        grid-template-columns: 40px minmax(0, 1fr);
    }

    .community-friend-row__actions {
        grid-column: 1 / -1;
        justify-content: stretch;
    }

    .community-friend-row__actions form,
    .community-friend-row__actions .community-button {
        flex: 1 1 auto;
    }
}


/* ================================================================
   Global Header Wallet v1
   Always-visible Game Money / Coins / Donat with compact dropdown.
   ================================================================ */

.header-wallet-center {
    position: relative;
    z-index: 4;
    flex: 0 0 auto;
}

.header-wallet-trigger {
    min-width: 242px;
    min-height: 46px;
    padding: 4px 8px 4px 6px;
    display: grid;
    grid-template-columns: 30px minmax(0, 1fr) 12px;
    align-items: center;
    gap: 6px;
    border: 1px solid rgba(85, 77, 136, .44);
    border-radius: 10px;
    color: #d8ddec;
    background:
        radial-gradient(
            circle at 12% 50%,
            rgba(135, 54, 236, .11),
            transparent 38%
        ),
        rgba(8, 11, 22, .96);
    font: inherit;
    cursor: pointer;
    transition:
        border-color .15s ease,
        background .15s ease,
        box-shadow .15s ease;
}

.header-wallet-trigger:hover,
.header-wallet-trigger[aria-expanded="true"] {
    border-color: rgba(145, 75, 245, .52);
    background:
        radial-gradient(
            circle at 12% 50%,
            rgba(135, 54, 236, .17),
            transparent 42%
        ),
        rgba(11, 14, 28, .98);
    box-shadow:
        inset 0 0 22px rgba(131, 58, 231, .045),
        0 0 18px rgba(111, 45, 210, .07);
}

.header-wallet-trigger__mark {
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(151, 76, 248, .23);
    border-radius: 8px;
    color: #ae6cff;
    background: rgba(126, 55, 226, .08);
}

.header-wallet-trigger__mark svg {
    width: 17px;
    height: 17px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.65;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.header-wallet-trigger__balances {
    min-width: 0;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: center;
}

.header-wallet-mini {
    --header-wallet-accent: #9b65ef;
    min-width: 0;
    min-height: 27px;
    padding: 0 7px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    border-left: 1px solid rgba(255, 255, 255, .055);
    white-space: nowrap;
}

.header-wallet-mini:first-child {
    border-left: 0;
}

.header-wallet-mini.is-game-money {
    --header-wallet-accent: #a965ff;
}

.header-wallet-mini.is-coins {
    --header-wallet-accent: #ffc84f;
}

.header-wallet-mini.is-donat {
    --header-wallet-accent: #5da5ff;
}

.header-wallet-mini i {
    width: 14px;
    height: 14px;
    display: inline-grid;
    place-items: center;
    flex: 0 0 auto;
    border: 1px solid
        color-mix(
            in srgb,
            var(--header-wallet-accent) 42%,
            transparent
        );
    border-radius: 50%;
    color: var(--header-wallet-accent);
    background:
        color-mix(
            in srgb,
            var(--header-wallet-accent) 8%,
            transparent
        );
    font-size: 6px;
    font-style: normal;
    font-weight: 950;
    line-height: 1;
}

.header-wallet-mini.is-donat i {
    border: 0;
    border-radius: 0;
    background: transparent;
    font-size: 9px;
}

.header-wallet-mini b {
    min-width: 0;
    overflow: hidden;
    color: #e7eaf3;
    font-size: 8px;
    font-variant-numeric: tabular-nums;
    text-overflow: ellipsis;
}

.header-wallet-mini small {
    color: var(--header-wallet-accent);
    font-size: 6px;
    font-weight: 900;
}

.header-wallet-trigger__chevron {
    color: #6f7991;
    font-size: 10px;
    transition: transform .15s ease;
}

.header-wallet-trigger[aria-expanded="true"]
.header-wallet-trigger__chevron {
    color: #b485ed;
    transform: rotate(180deg);
}

.header-wallet-dropdown {
    position: absolute;
    z-index: 1300;
    top: calc(100% + 10px);
    right: 0;
    width: 322px;
    overflow: hidden;
    border: 1px solid rgba(135, 81, 221, .30);
    border-radius: 12px;
    background:
        radial-gradient(
            circle at 90% 0%,
            rgba(123, 62, 222, .15),
            transparent 40%
        ),
        rgba(7, 10, 20, .99);
    box-shadow:
        0 26px 70px rgba(0, 0, 0, .58),
        0 0 0 1px rgba(255, 255, 255, .018);
    backdrop-filter: blur(18px);
}

.header-wallet-dropdown[hidden] {
    display: none !important;
}

.header-wallet-dropdown__head {
    min-height: 66px;
    padding: 13px 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, .055);
}

.header-wallet-dropdown__head > div {
    min-width: 0;
    display: grid;
    gap: 3px;
}

.header-wallet-dropdown__head span {
    color: #795ba7;
    font-size: 7px;
    font-weight: 900;
    letter-spacing: 1px;
}

.header-wallet-dropdown__head strong {
    color: #f0f2f8;
    font-size: 12px;
}

.header-wallet-dropdown__head > small {
    padding: 5px 7px;
    border: 1px solid rgba(83, 211, 139, .16);
    border-radius: 999px;
    color: #66d799;
    background: rgba(83, 211, 139, .045);
    font-size: 6px;
    font-weight: 900;
}

.header-wallet-dropdown__list {
    padding: 4px 12px;
}

.header-wallet-row {
    --header-wallet-accent: #9b65ef;
    min-height: 58px;
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, .045);
}

.header-wallet-row:last-child {
    border-bottom: 0;
}

.header-wallet-row.is-game-money {
    --header-wallet-accent: #a965ff;
}

.header-wallet-row.is-coins {
    --header-wallet-accent: #ffc84f;
}

.header-wallet-row.is-donat {
    --header-wallet-accent: #5da5ff;
}

.header-wallet-row__icon {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border: 1px solid
        color-mix(
            in srgb,
            var(--header-wallet-accent) 32%,
            transparent
        );
    border-radius: 8px;
    color: var(--header-wallet-accent);
    background:
        color-mix(
            in srgb,
            var(--header-wallet-accent) 7%,
            transparent
        );
    font-size: 9px;
    font-weight: 950;
}

.header-wallet-row__copy {
    min-width: 0;
    display: grid;
    gap: 4px;
}

.header-wallet-row__copy strong {
    color: #dfe3ed;
    font-size: 9px;
}

.header-wallet-row__copy small {
    overflow: hidden;
    color: #626d84;
    font-size: 6px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.header-wallet-row > b {
    color: var(--header-wallet-accent);
    font-size: 11px;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.header-wallet-row > b small {
    color: #7d879d;
    font-size: 6px;
}

.header-wallet-dropdown__footer {
    min-height: 55px;
    padding: 8px 10px;
    display: flex;
    align-items: center;
    border-top: 1px solid rgba(255, 255, 255, .055);
}

.header-wallet-dropdown__footer a {
    width: 100%;
    min-height: 37px;
    padding: 0 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    border: 1px solid rgba(166, 92, 255, .40);
    border-radius: 8px;
    color: #fff;
    background:
        linear-gradient(
            135deg,
            rgba(118, 48, 231, .98),
            rgba(153, 61, 255, .98)
        );
    box-shadow: 0 9px 25px rgba(111, 43, 219, .16);
    font-size: 8px;
    font-weight: 900;
    text-decoration: none;
}

.header-wallet-dropdown__footer a:hover {
    filter: brightness(1.08);
}

@media (min-width: 1501px) {
    .home-header__inner {
        width: min(
            1660px,
            calc(100% - (var(--page-gutter) * 2))
        );
    }
}

@media (max-width: 1500px) and (min-width: 901px) {
    .header-search-button {
        display: none;
    }

    .header-wallet-trigger {
        min-width: 216px;
    }

    .header-wallet-trigger__mark {
        display: none;
    }

    .header-wallet-trigger {
        grid-template-columns: minmax(0, 1fr) 12px;
    }
}

@media (max-width: 1320px) and (min-width: 901px) {
    .account-menu__summary {
        min-width: 54px;
        grid-template-columns: 36px auto;
    }

    .account-menu__copy {
        display: none;
    }

    .header-wallet-trigger {
        min-width: 196px;
    }

    .header-wallet-mini {
        padding-inline: 5px;
    }
}

@media (max-width: 1080px) and (min-width: 901px) {
    .home-header__inner {
        grid-template-columns:
            190px
            minmax(0, 1fr)
            auto;
    }

    .brand__logo {
        width: 180px;
    }

    .header-wallet-trigger {
        min-width: 170px;
    }

    .header-wallet-mini small {
        display: none;
    }

    .header-wallet-mini b {
        font-size: 7px;
    }
}

@media (max-width: 900px) {
    .home-header__inner {
        grid-template-columns:
            minmax(0, 1fr)
            auto
            auto;
        gap: 8px;
    }

    .header-actions {
        display: flex;
        gap: 0;
    }

    .header-actions > :not(.header-wallet-center) {
        display: none !important;
    }

    .header-wallet-trigger {
        min-width: 164px;
        min-height: 42px;
        grid-template-columns: minmax(0, 1fr) 10px;
        padding-inline: 5px;
    }

    .header-wallet-trigger__mark,
    .header-wallet-mini small {
        display: none;
    }

    .header-wallet-mini {
        min-height: 25px;
        padding-inline: 4px;
        gap: 3px;
    }

    .header-wallet-mini b {
        font-size: 7px;
    }

    .header-wallet-dropdown {
        position: fixed;
        top: 68px;
        right: 12px;
        width: min(322px, calc(100vw - 24px));
    }
}

@media (max-width: 560px) {
    .brand__logo {
        width: min(100%, 166px);
    }

    .header-wallet-trigger {
        min-width: 142px;
    }

    .header-wallet-mini i {
        width: 12px;
        height: 12px;
        font-size: 5px;
    }

    .header-wallet-mini.is-donat i {
        font-size: 8px;
    }

    .header-wallet-mini b {
        font-size: 6.5px;
    }
}

@media (max-width: 420px) {
    .home-header__inner {
        width: calc(100% - 14px);
        gap: 5px;
    }

    .brand__logo {
        width: min(100%, 138px);
    }

    .header-wallet-trigger {
        min-width: 126px;
        border-radius: 8px;
    }

    .header-wallet-mini {
        padding-inline: 2px;
    }

    .header-wallet-mini i {
        display: none;
    }

    .header-wallet-mini b {
        font-size: 6.3px;
    }

    .mobile-menu-button {
        width: 40px;
        height: 40px;
    }
}

/* ================================================================
   Merged Account + Wallet Header v2
   ================================================================ */

.account-menu[data-header-wallet-center="v2"] {
    z-index: 5;
}

.account-menu[data-header-wallet-center="v2"] .account-menu__summary {
    min-width: 288px;
    min-height: 56px;
    padding: 5px 11px 5px 6px;
    grid-template-columns: 42px minmax(0, 1fr) 12px;
    gap: 10px;
}

.account-menu[data-header-wallet-center="v2"] .account-menu__copy {
    min-width: 0;
    display: grid;
    gap: 6px;
}

.account-menu[data-header-wallet-center="v2"] .account-menu__copy > strong {
    overflow: hidden;
    color: #f5f6fb;
    font-size: 12px;
    line-height: 1.05;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.account-menu__balances {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.account-balance-mini {
    --account-wallet-accent: #a965ff;
    min-width: 0;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: #a8b0c3;
    white-space: nowrap;
}

.account-balance-mini.is-coins { --account-wallet-accent: #ffc84f; }
.account-balance-mini.is-donat { --account-wallet-accent: #5da5ff; }

.account-balance-mini i {
    width: 16px;
    height: 16px;
    display: inline-grid;
    place-items: center;
    border: 1px solid color-mix(in srgb, var(--account-wallet-accent) 42%, transparent);
    border-radius: 50%;
    color: var(--account-wallet-accent);
    font-size: 7px;
    font-style: normal;
    font-weight: 950;
}

.account-balance-mini b { color: #eef1f8; font-size: 9px; font-variant-numeric: tabular-nums; line-height: 1; }
.account-balance-mini small { color: var(--account-wallet-accent); font-size: 7px; font-weight: 900; line-height: 1; }

.account-menu[data-header-wallet-center="v2"] .account-menu__dropdown {
    width: 306px;
    max-height: min(690px, calc(100vh - 82px));
    overflow-y: auto;
}

.account-wallet-summary {
    margin: 5px;
    padding: 10px;
    border: 1px solid rgba(143, 74, 236, .17);
    border-radius: 8px;
    background: radial-gradient(circle at 100% 0, rgba(133, 57, 229, .12), transparent 52%), rgba(5, 8, 17, .58);
}

.account-wallet-summary__head {
    padding-bottom: 8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, .055);
}

.account-wallet-summary__head span { color: #75599d; font-size: 6px; font-weight: 950; letter-spacing: 1px; }
.account-wallet-summary__head a { min-height: 0 !important; padding: 0 !important; border: 0 !important; color: #af73f5 !important; background: transparent !important; font-size: 6px !important; }

.account-wallet-row {
    --account-wallet-accent: #a965ff;
    min-height: 31px;
    display: grid;
    grid-template-columns: 20px minmax(0, 1fr) auto;
    align-items: center;
    gap: 7px;
    border-bottom: 1px solid rgba(255, 255, 255, .04);
}

.account-wallet-row:last-child { border-bottom: 0; }
.account-wallet-row.is-coins { --account-wallet-accent: #ffc84f; }
.account-wallet-row.is-donat { --account-wallet-accent: #5da5ff; }
.account-wallet-row > i { color: var(--account-wallet-accent); font-size: 7px; font-style: normal; font-weight: 950; text-align: center; }
.account-wallet-row > span { color: #8f99ae; font-size: 7px; }
.account-wallet-row > b { color: var(--account-wallet-accent); font-size: 8px; font-variant-numeric: tabular-nums; }
.account-wallet-row > b small { color: #68748b; font-size: 5px; }

@media (max-width: 1320px) and (min-width: 901px) {
    .account-menu[data-header-wallet-center="v2"] .account-menu__summary {
        min-width: 250px;
        grid-template-columns: 38px minmax(0, 1fr) 10px;
    }

    .account-menu[data-header-wallet-center="v2"] .account-menu__copy { display: grid; }
    .account-menu__balances { gap: 7px; }
    .account-balance-mini i { display: none; }
    .account-balance-mini b { font-size: 8px; }
    .account-balance-mini small { font-size: 6px; }
}

@media (max-width: 1080px) and (min-width: 901px) {
    .account-menu[data-header-wallet-center="v2"] .account-menu__summary { min-width: 215px; }
    .account-balance-mini small { display: none; }
}

@media (max-width: 900px) {
    .header-actions > :not(.account-menu) { display: none !important; }
    .header-actions > .account-menu { display: block !important; }
    .account-menu[data-header-wallet-center="v2"] .account-menu__summary { min-width: 190px; min-height: 46px; grid-template-columns: 34px minmax(0, 1fr) 9px; }
    .account-menu[data-header-wallet-center="v2"] .account-menu__copy { display: grid; }
    .account-balance-mini i, .account-balance-mini small { display: none; }
    .account-menu[data-header-wallet-center="v2"] .account-menu__dropdown { position: fixed; top: 66px; right: 12px; width: min(306px, calc(100vw - 24px)); }
}

@media (max-width: 560px) {
    .account-menu[data-header-wallet-center="v2"] .account-menu__summary { min-width: 166px; padding-right: 5px; gap: 6px; }
    .account-menu__balances { gap: 5px; }
    .account-balance-mini b { font-size: 7px; }
}

@media (max-width: 420px) {
    .account-menu[data-header-wallet-center="v2"] .account-menu__summary { min-width: 148px; grid-template-columns: 30px minmax(0, 1fr) 7px; }
    .account-menu[data-header-wallet-center="v2"] .account-menu__copy > strong { font-size: 8px; }
    .account-balance-mini b { font-size: 6.2px; }
}
