.custom-scrollbar::-webkit-scrollbar { width: 4px; }
.custom-scrollbar::-webkit-scrollbar-track { background: transparent; }
.custom-scrollbar::-webkit-scrollbar-thumb { background-color: #e5e7eb; border-radius: 20px; }

.community-intro,
.community-discovery {
    background: linear-gradient(180deg, #ffffff 0%, #fbfcfe 100%);
}

.community-primary-action,
.community-secondary-action {
    display: inline-flex;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border-radius: 16px;
    padding: 0 16px;
    font-size: 11px;
    line-height: 1;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    transition: background-color 180ms ease, border-color 180ms ease, color 180ms ease, transform 180ms ease, box-shadow 180ms ease;
}

.community-primary-action {
    border: 1px solid #0f172a;
    background: #0f172a;
    color: #ffffff;
    box-shadow: 0 14px 28px rgba(15, 23, 42, 0.16);
}

.community-primary-action:hover {
    border-color: #f97316;
    background: #f97316;
    transform: translateY(-1px);
    box-shadow: 0 16px 34px rgba(249, 115, 22, 0.22);
}

.community-primary-action svg,
.community-secondary-action svg {
    width: 16px;
    height: 16px;
    flex: 0 0 auto;
}

.community-secondary-action {
    border: 1px solid #e5e7eb;
    background: #ffffff;
    color: #334155;
}

.community-secondary-action:hover {
    border-color: #fed7aa;
    color: #f97316;
    transform: translateY(-1px);
}

.community-search {
    position: relative;
    display: flex;
    align-items: center;
    min-height: 48px;
    border: 1px solid #e5e7eb;
    border-radius: 18px;
    background: #f8fafc;
    color: #94a3b8;
}

.community-search svg {
    position: absolute;
    left: 16px;
    width: 19px;
    height: 19px;
}

.community-search input {
    width: 100%;
    min-width: 0;
    border: 0;
    background: transparent;
    color: #0f172a;
    outline: 0;
    padding: 0 16px 0 46px;
    font-size: 14px;
    font-weight: 800;
}

.community-search input::placeholder {
    color: #94a3b8;
}

.community-sort {
    display: inline-flex;
    min-height: 48px;
    align-items: center;
    gap: 10px;
    border: 1px solid #e5e7eb;
    border-radius: 18px;
    background: #ffffff;
    padding: 0 12px 0 16px;
}

.community-sort span {
    color: #94a3b8;
    font-size: 10px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.community-sort select {
    border: 0;
    background: transparent;
    color: #0f172a;
    outline: 0;
    font-size: 13px;
    font-weight: 900;
    cursor: pointer;
}

.community-tabs {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: none;
}

.community-tabs::-webkit-scrollbar {
    display: none;
}

.community-tab {
    display: inline-flex;
    min-height: 38px;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    gap: 7px;
    border: 0;
    border-radius: 14px;
    background: #f8fafc;
    color: #475569;
    padding: 0 13px;
    font-size: 10px;
    line-height: 1;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    cursor: pointer;
    transition: background-color 180ms ease, color 180ms ease;
}

.community-tab:hover {
    background: #eef2f7;
    color: #0f172a;
}

.community-tab.is-active {
    background: #0f172a;
    color: #ffffff;
}

.community-tab span {
    min-width: 18px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.08);
    padding: 4px 6px;
    font-size: 9px;
    letter-spacing: 0;
}

.community-tab.is-active span {
    background: rgba(255, 255, 255, 0.16);
}

.community-card.is-hidden {
    display: none;
}

.community-card {
    display: flex;
    min-height: 620px;
    flex-direction: column;
    border-radius: 34px !important;
    background: #ffffff;
    box-shadow: 0 18px 46px rgba(15, 23, 42, 0.08);
}

.community-card__link {
    display: block;
    min-width: 0;
    color: inherit;
    text-decoration: none;
}

.community-card__media {
    position: relative;
    height: 236px;
    overflow: hidden;
    background: #111827;
    border-radius: 34px 34px 0 0;
}

.community-card__cover,
.community-card__fallback {
    width: 100%;
    height: 100%;
    display: block;
}

.community-card__cover {
    object-fit: cover;
    transition: transform 620ms ease;
}

.community-card:hover .community-card__cover {
    transform: scale(1.035);
}

.community-card__fallback {
    background:
        radial-gradient(circle at 78% 28%, rgba(249, 115, 22, 0.24), transparent 26%),
        radial-gradient(circle at 22% 18%, rgba(255, 255, 255, 0.08), transparent 24%),
        linear-gradient(145deg, #111827 0%, #1f2937 56%, #4a2214 100%);
}

.community-card__shade {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(to top, rgba(15, 23, 42, 0.42), rgba(15, 23, 42, 0.06) 58%, rgba(15, 23, 42, 0.0)),
        linear-gradient(135deg, rgba(255, 255, 255, 0.08), transparent 46%);
}

.community-card__badges {
    position: absolute;
    top: 18px;
    right: 18px;
    z-index: 2;
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.community-card__badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    max-width: 220px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    border-radius: 999px;
    padding: 10px 14px;
    font-size: 11px;
    line-height: 1;
    font-weight: 950;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    box-shadow: 0 10px 26px rgba(15, 23, 42, 0.12);
}

.community-card__badge--light {
    background: rgba(255, 255, 255, 0.92);
    color: #0f172a;
    backdrop-filter: blur(14px);
}

.community-card__status-dot {
    width: 10px;
    height: 10px;
    flex: 0 0 auto;
    border-radius: 999px;
    background: #22c55e;
    box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.14);
}

.community-card__body {
    padding: 0 28px 0;
}

.community-card__topline {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-top: -72px;
    margin-bottom: 26px;
    position: relative;
    z-index: 3;
}

.community-card__avatar {
    width: 116px;
    height: 116px;
    flex: 0 0 auto;
    overflow: hidden;
    border: 8px solid #ffffff;
    border-radius: 30px;
    background: #ffffff;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.14);
}

.community-card__avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.community-card__title {
    margin: 0;
    overflow: hidden;
    color: #0f172a;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    font-size: 30px;
    line-height: 1.03;
    font-weight: 950;
    letter-spacing: 0;
}

.community-card:hover .community-card__title {
    color: #f97316;
}

.community-card__description {
    min-height: 82px;
    margin: 14px 0 0;
    overflow: hidden;
    color: #64748b;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    font-size: 18px;
    line-height: 1.42;
    font-weight: 700;
}

.community-card__topics {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 26px;
}

.community-card__topic {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    min-width: 0;
    max-width: 100%;
    border-radius: 999px;
    background: #f4f6f8;
    color: #64748b;
    padding: 11px 16px;
    font-size: 13px;
    line-height: 1;
    font-weight: 900;
    white-space: nowrap;
}

.community-card__topic svg {
    width: 18px;
    height: 18px;
    flex: 0 0 auto;
}

.community-card__topic--official {
    background: #fff4eb;
    color: #a94d0d;
}

.community-card__stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0;
    margin-top: 30px;
    border-top: 1px solid #e5e7eb;
    border-bottom: 1px solid #e5e7eb;
    padding: 20px 0;
}

.community-card__stats span {
    display: grid;
    min-width: 0;
    grid-template-columns: auto minmax(0, 1fr);
    grid-template-rows: auto auto;
    column-gap: 12px;
    align-items: center;
    padding: 0 18px;
}

.community-card__stats span:first-child {
    padding-left: 0;
}

.community-card__stats span + span {
    border-left: 1px solid #e5e7eb;
}

.community-card__stats svg {
    grid-row: 1 / span 2;
    width: 32px;
    height: 32px;
    color: #64748b;
}

.community-card__stats span:nth-child(3) svg {
    color: #22c55e;
}

.community-card__stats b {
    overflow: hidden;
    color: #0f172a;
    font-size: 25px;
    line-height: 1;
    font-weight: 950;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.community-card__stats small {
    overflow: hidden;
    color: #64748b;
    font-size: 13px;
    line-height: 1.2;
    font-weight: 800;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.community-card__footer {
    display: flex;
    flex: 1;
    flex-direction: column;
    justify-content: flex-end;
    gap: 20px;
    padding: 28px;
}

.community-card__cta {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 76px;
    gap: 14px;
}

.community-card__open-icon {
    display: inline-flex;
    min-height: 62px;
    align-items: center;
    justify-content: center;
    border: 2px solid #e2e8f0;
    border-radius: 20px;
    background: #ffffff;
    color: #475569;
    transition: border-color 180ms ease, color 180ms ease, transform 180ms ease;
}

.community-card__open-icon:hover {
    border-color: #fed7aa;
    color: #f97316;
    transform: translateY(-1px);
}

.community-card__open-icon svg {
    width: 28px;
    height: 28px;
}

.community-card__members-strip {
    display: flex;
    align-items: center;
    gap: 20px;
    min-height: 72px;
    border-radius: 20px;
    background: #f8fafc;
    padding: 14px 18px;
}

.community-card__members {
    display: flex;
    min-width: 0;
    padding-left: 12px;
}

.community-card__members a {
    width: 42px;
    height: 42px;
    overflow: hidden;
    border: 3px solid #ffffff;
    border-radius: 999px;
    background: #f1f5f9;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.1);
    margin-left: -12px;
    transition: transform 180ms ease;
}

.community-card__members a:hover {
    transform: translateY(-2px);
}

.community-card__members img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.community-card__members-extra {
    display: inline-flex;
    width: 42px;
    height: 42px;
    align-items: center;
    justify-content: center;
    margin-left: -12px;
    border: 3px solid #ffffff;
    border-radius: 999px;
    background: #e9eef5;
    color: #475569;
    font-size: 15px;
    font-weight: 950;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.1);
}

.community-card__members-strip p {
    min-width: 0;
    margin: 0;
    overflow: hidden;
    color: #64748b;
    font-size: 15px;
    line-height: 1.25;
    font-weight: 800;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.community-join-btn {
    display: inline-flex;
    min-height: 62px;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 20px;
    background: linear-gradient(135deg, #ff7a1a, #ff5a11);
    color: #ffffff;
    padding: 0 22px;
    font-size: 16px;
    line-height: 1;
    font-weight: 950;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    cursor: pointer;
    text-align: center;
    text-decoration: none;
    box-shadow: 0 16px 30px rgba(249, 115, 22, 0.25);
    transition: filter 180ms ease, color 180ms ease, transform 180ms ease, box-shadow 180ms ease;
}

.community-join-btn:hover {
    filter: brightness(1.03);
    box-shadow: 0 18px 34px rgba(249, 115, 22, 0.32);
    transform: translateY(-1px);
}

.community-join-btn.is-joined {
    background: #0f172a;
    color: #ffffff;
    box-shadow: 0 16px 30px rgba(15, 23, 42, 0.16);
}

.community-join-btn.is-joined:hover {
    color: #ffffff;
    filter: brightness(1.08);
}

.community-empty-state {
    border: 1px dashed #e5e7eb;
    border-radius: 28px;
    background: #ffffff;
    padding: 44px 24px;
    text-align: center;
}

.community-empty-state__title {
    margin: 0;
    color: #0f172a;
    font-size: 18px;
    line-height: 1.25;
    font-weight: 950;
}

.community-empty-state__text {
    margin: 8px auto 0;
    max-width: 420px;
    color: #64748b;
    font-size: 13px;
    line-height: 1.45;
    font-weight: 700;
}

@media (max-width: 767px) {
    .community-search,
    .community-sort {
        min-height: 44px;
        border-radius: 16px;
    }

    .community-sort {
        width: 100%;
        justify-content: space-between;
    }

    .community-card {
        min-height: auto;
        border-radius: 28px !important;
    }

    .community-card__media {
        height: 190px;
        border-radius: 28px 28px 0 0;
    }

    .community-card__badges {
        top: 14px;
        right: 14px;
    }

    .community-card__badge {
        padding: 8px 11px;
        font-size: 9px;
    }

    .community-card__body {
        padding: 0 20px;
    }

    .community-card__topline {
        margin-top: -54px;
        margin-bottom: 18px;
    }

    .community-card__avatar {
        width: 88px;
        height: 88px;
        border-width: 6px;
        border-radius: 24px;
    }

    .community-card__title {
        font-size: 24px;
    }

    .community-card__description {
        min-height: 66px;
        font-size: 15px;
    }

    .community-card__topics {
        margin-top: 18px;
    }

    .community-card__topic {
        padding: 9px 12px;
        font-size: 11px;
    }

    .community-card__stats {
        margin-top: 22px;
        padding: 16px 0;
    }

    .community-card__stats span {
        grid-template-columns: 1fr;
        gap: 6px;
        padding: 0 10px;
    }

    .community-card__stats svg {
        width: 24px;
        height: 24px;
    }

    .community-card__stats b {
        font-size: 18px;
    }

    .community-card__stats small {
        font-size: 11px;
    }

    .community-card__footer {
        gap: 14px;
        padding: 20px;
    }

    .community-card__cta {
        grid-template-columns: minmax(0, 1fr) 58px;
        gap: 10px;
    }

    .community-join-btn,
    .community-card__open-icon {
        min-height: 52px;
        border-radius: 16px;
        font-size: 12px;
    }

    .community-card__open-icon svg {
        width: 23px;
        height: 23px;
    }

    .community-card__members-strip {
        min-height: 62px;
        gap: 14px;
        border-radius: 18px;
        padding: 12px 14px;
    }

    .community-card__members a,
    .community-card__members-extra {
        width: 36px;
        height: 36px;
    }

    .community-card__members-strip p {
        font-size: 13px;
    }
}

/* Page scale tuning: keep community UI aligned with the denser site layout. */
.community-page {
    margin-bottom: 64px !important;
}

.community-intro {
    border-radius: 26px !important;
    padding: 22px 24px !important;
    margin-bottom: 18px !important;
}

.community-intro h1 {
    max-width: 760px;
    font-size: 38px !important;
    line-height: 1.02 !important;
}

.community-intro p:not(:first-child) {
    max-width: 680px;
    font-size: 14px !important;
    line-height: 1.5 !important;
}

.community-discovery {
    border-radius: 24px !important;
    padding: 16px 18px !important;
    margin-bottom: 20px !important;
}

.community-primary-action,
.community-secondary-action {
    min-height: 40px;
    border-radius: 14px;
    padding: 0 14px;
    font-size: 10px;
}

.community-search,
.community-sort {
    min-height: 42px;
    border-radius: 15px;
}

.community-search input {
    font-size: 13px;
}

.community-tab {
    min-height: 34px;
    border-radius: 12px;
    padding: 0 11px;
    font-size: 9px;
}

.community-grid {
    gap: 18px !important;
}

.community-card {
    min-height: 500px;
    border-radius: 24px !important;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.07);
}

.community-card__media {
    height: 178px;
    border-radius: 24px 24px 0 0;
}

.community-card__badges {
    top: 12px;
    right: 12px;
}

.community-card__badge {
    gap: 6px;
    padding: 7px 10px;
    font-size: 9px;
}

.community-card__status-dot {
    width: 8px;
    height: 8px;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.14);
}

.community-card__body {
    padding: 0 20px;
}

.community-card__topline {
    margin-top: -48px;
    margin-bottom: 16px;
}

.community-card__avatar {
    width: 82px;
    height: 82px;
    border-width: 5px;
    border-radius: 20px;
    box-shadow: 0 12px 26px rgba(15, 23, 42, 0.12);
}

.community-card__title {
    font-size: 22px;
    line-height: 1.08;
}

.community-card__description {
    min-height: 58px;
    margin-top: 9px;
    font-size: 14px;
    line-height: 1.38;
    -webkit-line-clamp: 3;
}

.community-card__topics {
    gap: 7px;
    margin-top: 16px;
}

.community-card__topic {
    gap: 7px;
    padding: 7px 10px;
    font-size: 10px;
}

.community-card__topic svg {
    width: 14px;
    height: 14px;
}

.community-card__stats {
    margin-top: 18px;
    padding: 13px 0;
}

.community-card__stats span {
    column-gap: 8px;
    padding: 0 10px;
}

.community-card__stats svg {
    width: 22px;
    height: 22px;
}

.community-card__stats b {
    font-size: 18px;
}

.community-card__stats small {
    font-size: 10px;
}

.community-card__footer {
    gap: 13px;
    padding: 20px;
}

.community-card__cta {
    grid-template-columns: minmax(0, 1fr) 54px;
    gap: 10px;
}

.community-join-btn,
.community-card__open-icon {
    min-height: 46px;
    border-radius: 15px;
}

.community-join-btn {
    padding: 0 16px;
    font-size: 12px;
}

.community-card__open-icon svg {
    width: 21px;
    height: 21px;
}

.community-card__members-strip {
    min-height: 54px;
    gap: 12px;
    border-radius: 16px;
    padding: 9px 12px;
}

.community-card__members a,
.community-card__members-extra {
    width: 32px;
    height: 32px;
    border-width: 2px;
}

.community-card__members-extra {
    font-size: 12px;
}

.community-card__members-strip p {
    font-size: 12px;
}

@media (max-width: 767px) {
    .community-intro {
        border-radius: 0 !important;
        padding: 18px 16px !important;
    }

    .community-intro h1 {
        font-size: 28px !important;
    }

    .community-discovery {
        border-radius: 0 !important;
        padding: 14px 16px !important;
    }

    .community-card {
        min-height: auto;
        border-radius: 22px !important;
    }

    .community-card__media {
        height: 156px;
        border-radius: 22px 22px 0 0;
    }

    .community-card__avatar {
        width: 72px;
        height: 72px;
        border-radius: 18px;
    }

    .community-card__title {
        font-size: 20px;
    }

    .community-card__description {
        min-height: 54px;
        font-size: 13px;
    }
}

.community-card__avatar {
    position: relative;
    overflow: visible;
    border: 0;
    border-radius: 999px;
    padding: 5px;
    background: conic-gradient(#f97316 var(--community-card-level-progress, 0%), #eef2f7 0);
}

.community-card__avatar-inner {
    width: 100%;
    height: 100%;
    overflow: hidden;
    border: 5px solid #ffffff;
    border-radius: inherit;
    background: #ffffff;
}

.community-card__avatar img {
    border-radius: inherit;
}

.community-card__avatar > span {
    position: absolute;
    right: 3px;
    bottom: 3px;
    min-width: 30px;
    height: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 3px solid #ffffff;
    border-radius: 999px;
    background: #f97316;
    color: #ffffff;
    font-size: 11px;
    line-height: 1;
    font-weight: 950;
    box-shadow: 0 10px 22px rgba(249, 115, 22, 0.28);
}

.community-card__level {
    min-width: 0;
    display: grid;
    gap: 6px;
    border: 1px solid #fed7aa;
    border-radius: 18px;
    background: rgba(255, 247, 237, 0.95);
    padding: 12px 14px;
    box-shadow: 0 12px 24px rgba(249, 115, 22, 0.10);
}

.community-card__level strong,
.community-card__level span {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 1;
}

.community-card__level strong {
    color: #f97316;
    font-size: 12px;
    font-weight: 950;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.community-card__level span {
    color: #0f172a;
    font-size: 14px;
    font-weight: 950;
}

@media (max-width: 767px) {
    .community-card__avatar {
        border-radius: 999px;
        padding: 4px;
    }

    .community-card__avatar-inner {
        border-width: 3px;
    }

    .community-card__avatar > span {
        min-width: 25px;
        height: 25px;
        font-size: 9px;
    }

    .community-card__level {
        border-radius: 14px;
        padding: 9px 10px;
    }

    .community-card__level strong {
        font-size: 10px;
    }

    .community-card__level span {
        font-size: 12px;
    }
}

/* Mobile continuation: compact cards, sheets and no horizontal overflow. */
@media (max-width: 767px) {
    .community-page {
        width: 100%;
        max-width: 100%;
        overflow-x: hidden;
        padding-bottom: calc(108px + env(safe-area-inset-bottom, 0px)) !important;
        margin-bottom: 0 !important;
    }

    .community-page * {
        min-width: 0;
    }

    .community-intro,
    .community-discovery {
        width: 100%;
        max-width: 100%;
        border-left: 0 !important;
        border-right: 0 !important;
    }

    .community-intro .flex,
    .community-discovery .grid {
        gap: 12px !important;
    }

    .community-intro .shrink-0 {
        width: 100%;
    }

    .community-intro h1 {
        max-width: 100%;
        overflow-wrap: anywhere;
        font-size: 26px !important;
        line-height: 1.04 !important;
    }

    .community-intro p:not(:first-child) {
        font-size: 13px !important;
    }

    .community-primary-action,
    .community-secondary-action {
        min-height: 44px;
        border-radius: 15px;
        padding: 0 14px;
    }

    .community-intro .community-primary-action,
    .community-intro .community-secondary-action {
        flex: 1 1 calc(50% - 4px);
    }

    .community-search input,
    .community-sort select,
    #create-club-modal input,
    #create-club-modal textarea {
        font-size: 16px !important;
    }

    .community-search {
        background: #ffffff;
    }

    .community-sort {
        min-height: 44px;
        padding: 0 10px 0 13px;
    }

    .community-sort span {
        font-size: 9px;
    }

    .community-sort select {
        max-width: 56%;
        text-align: right;
    }

    .community-tabs {
        margin-left: -16px;
        margin-right: -16px;
        padding: 0 16px 4px;
        scroll-padding-inline: 16px;
    }

    .community-tab {
        min-height: 40px;
        border-radius: 999px;
        padding: 0 12px;
        letter-spacing: 0.04em;
    }

    .community-grid {
        grid-template-columns: minmax(0, 1fr) !important;
        gap: 14px !important;
    }

    .community-card {
        width: 100%;
        max-width: 100%;
        overflow: hidden;
        border-radius: 22px !important;
    }

    .community-card__media {
        height: 148px;
        border-radius: 22px 22px 0 0;
    }

    .community-card__badges {
        top: 10px;
        right: 10px;
    }

    .community-card__badge {
        max-width: 70vw;
    }

    .community-card__body {
        padding: 0 16px;
    }

    .community-card__topline {
        margin-top: -42px;
        margin-bottom: 14px;
        align-items: flex-end;
    }

    .community-card__avatar {
        width: 70px;
        height: 70px;
        box-shadow: 0 10px 24px rgba(15, 23, 42, 0.12);
    }

    .community-card__level {
        min-width: 0;
        max-width: calc(100% - 82px);
    }

    .community-card__title {
        font-size: 20px !important;
        line-height: 1.12;
        overflow-wrap: anywhere;
    }

    .community-card__description {
        min-height: 0 !important;
        font-size: 13px !important;
        line-height: 1.42;
    }

    .community-card__topics {
        display: flex;
        flex-wrap: nowrap;
        overflow-x: auto;
        margin-left: -16px;
        margin-right: -16px;
        padding: 0 16px 2px;
        scrollbar-width: none;
    }

    .community-card__topics::-webkit-scrollbar {
        display: none;
    }

    .community-card__topic {
        flex: 0 0 auto;
        max-width: 82vw;
    }

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

    .community-card__stats span {
        width: auto;
        min-width: 0;
        grid-template-columns: 1fr;
        justify-items: center;
        gap: 5px;
        padding: 0 5px;
        text-align: center;
    }

    .community-card__stats span + span {
        border-left: 1px solid #eef2f7;
    }

    .community-card__stats b,
    .community-card__stats small {
        max-width: 100%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .community-card__footer {
        gap: 10px;
        padding: 16px;
    }

    .community-card__cta {
        grid-template-columns: minmax(0, 1fr) 48px;
    }

    .community-join-btn,
    .community-card__open-icon {
        min-height: 46px;
        border-radius: 15px;
    }

    .community-card__members-strip {
        min-height: 50px;
        gap: 10px;
        padding: 8px 10px;
    }

    .community-card__members {
        max-width: 112px;
        overflow: hidden;
    }

    .community-card__members a,
    .community-card__members-extra {
        width: 30px;
        height: 30px;
    }

    .community-card__members-strip p {
        font-size: 11px;
        line-height: 1.25;
    }

    .community-empty-state {
        border-radius: 22px;
        padding: 32px 18px;
    }

    #create-club-modal:not(.hidden) {
        align-items: flex-end;
        padding: 0;
    }

    #create-club-modal > div {
        width: 100%;
        max-width: none;
        max-height: calc(92dvh - env(safe-area-inset-bottom, 0px));
        border-radius: 28px 28px 0 0 !important;
        padding: 22px 18px calc(18px + env(safe-area-inset-bottom, 0px)) !important;
    }

    #create-club-form {
        gap: 16px !important;
        padding-right: 0 !important;
    }

    #create-club-form > .flex.gap-3 {
        position: sticky;
        bottom: 0;
        z-index: 3;
        margin-left: -18px;
        margin-right: -18px;
        margin-bottom: calc(-18px - env(safe-area-inset-bottom, 0px));
        padding: 12px 18px calc(18px + env(safe-area-inset-bottom, 0px));
        background: linear-gradient(180deg, rgba(255,255,255,0.84), #fff 38%);
        backdrop-filter: blur(16px);
    }
}

@media (max-width: 374px) {
    .community-intro h1 {
        font-size: 23px !important;
    }

    .community-card__stats b {
        font-size: 15px;
    }

    .community-card__stats small,
    .community-card__members-strip p {
        font-size: 10px;
    }

    .community-card__level span {
        font-size: 11px;
    }
}
