﻿
/* =========================================
   GROUPS PAGE
========================================= */
.groups-page {
    width: 100%;
    min-height: calc(100vh - 80px);
    background: #f8f9fc;
    padding: 28px 24px 40px;
}


.groups-container {
    max-width: 1450px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 285px minmax(0, 1fr);
    gap: 22px;
    align-items: start;
}


/* =========================================
   LEFT SIDEBAR
========================================= */

.groups-sidebar {
    background: #ffffff;
    border: 1px solid #e9e7f2;
    border-radius: 18px;
    padding: 18px;
    box-shadow: 0 5px 25px rgba(43, 32, 90, 0.05);
    position: sticky;
    top: 20px;
}


.groups-sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
}


    .groups-sidebar-header h3 {
        margin: 0;
        font-size: 19px;
        font-weight: 700;
        color: #182052;
    }


.create-group-small {
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 11px;
    background: linear-gradient( 135deg, #6846ff, #9b45e9 );
    color: white;
    font-size: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 5px 15px rgba(104, 70, 255, .25);
    transition: .2s ease;
}


    .create-group-small:hover {
        transform: translateY(-2px);
        box-shadow: 0 8px 18px rgba(104, 70, 255, .32);
    }


/* =========================================
   GROUP LIST
========================================= */

/*.groups-list {
    display: flex;
    flex-direction: column;
    gap: 7px;
}
.groups-list {
    max-height: 300px;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 5px;
    scrollbar-width: thin;
}
.groups-list {
    max-height: calc(70px * 5);
    overflow-y: auto;
    overflow-x: hidden;
}

.group-sidebar-item {
    position: relative;
    width: 100%;
    min-height: 70px;
    border: 1px solid transparent;
    border-radius: 13px;
    background: transparent;
    padding: 9px 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    text-align: left;
    cursor: pointer;
    transition: all .2s ease;
    color: #172052;
}


    .group-sidebar-item:hover {
        background: #f6f3ff;
        border-color: #ebe4ff;
    }


    .group-sidebar-item.selected {
        background: linear-gradient( 135deg, #f2edff, #faf6ff );
        border-color: #dcd0ff;
    }


.group-sidebar-image {
    width: 46px;
    height: 46px;
    flex-shrink: 0;
    border-radius: 13px;
    overflow: hidden;
    background: #eee;
}


    .group-sidebar-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }


.group-sidebar-info {
    min-width: 0;
    flex: 1;
}


.group-sidebar-name {
    font-size: 14px;
    font-weight: 700;
    color: #172052;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}


.group-sidebar-meta {
    margin-top: 5px;
    font-size: 12px;
    color: #777895;
}


.selected-group-indicator {
    width: 4px;
    height: 32px;
    border-radius: 4px;
    background: linear-gradient( 180deg, #7047ff, #ec4da8 );
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
}*/


/* =========================================
   CREATE GROUP BUTTON
========================================= */

/*.create-group-button {
    width: 100%;
    height: 45px;
    margin-top: 18px;
    border: 1px solid #8b6cff;
    border-radius: 11px;*/
    /*background: white;*/
    /*background: #5b21d6;
    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    transition: all .2s ease;
}


    .create-group-button:hover {
        background: #7047ff;
        color: white;
        box-shadow: 0 6px 15px rgba(112, 71, 255, .2);
    }*/


/* =========================================
   SECURITY CARD
========================================= */

/*.group-security-card {
    margin-top: 18px;
    padding: 16px;
    border-radius: 14px;
    background: linear-gradient( 135deg, #f7f2ff, #fff6fb );
    display: flex;
    gap: 12px;
}


.security-icon {
    width: 40px;
    height: 40px;
    flex-shrink: 0;
    border-radius: 12px;
    background: #ebe2ff;
    color: #7047ff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 19px;
}


.group-security-card strong {
    display: block;
    font-size: 13px;
    color: #7047ff;
}


.group-security-card p {
    margin: 5px 0 0;
    font-size: 11px;
    line-height: 1.5;
    color: #696981;
}*/

/* =========================================================
   GROUP SIDEBAR
   ========================================================= */

/* =========================================================
   GROUPS SIDEBAR
   ========================================================= */

/*.groups-sidebar {
    width: 310px;
    min-width: 310px;*/
    /*
       Important:
       Sidebar itself should NOT scroll.
       Only the individual group lists should scroll.
    */
    /*height: 100%;
    min-height: 0;
    background: #ffffff;
    border: 1px solid #ececf3;
    border-radius: 0 18px 18px 0;
    display: flex;
    flex-direction: column;
    padding: 18px;
    box-sizing: border-box;*/
    /*
       This prevents the sidebar from being squeezed
       when the main panel is displayed beside it.
    */
    /*flex: 0 0 310px;*/
    /*
       Creates space between sidebar and main panel.
    */
    /*margin-right: 16px;
    overflow: hidden;
}*/


/* =========================================================
   HEADER
   ========================================================= */

.groups-sidebar-header {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

    .groups-sidebar-header h3 {
        margin: 0;
        font-size: 21px;
        font-weight: 700;
        color: #18204a;
    }


.create-group-small {
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    border: 0;
    border-radius: 11px;
    background: #6d28d9;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 21px;
    cursor: pointer;
    transition: transform 0.2s ease, background 0.2s ease;
}

    .create-group-small:hover {
        transform: translateY(-1px);
        background: #5b21b6;
    }


/* =========================================================
   GROUP SECTIONS
   ========================================================= */

.groups-section {
    flex: 0 0 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    border: 1px solid #ece7ff;
    border-radius: 16px;
    margin-bottom: 10px;
    overflow: hidden;
    background: #ffffff;
}


/* =========================================================
   MY GROUPS
   ========================================================= */

.my-groups-section {
    background: linear-gradient( to bottom, #fbf9ff, #ffffff );
}


/* =========================================================
   JOINED GROUPS
   ========================================================= */

.joined-groups-section {
    background: linear-gradient( to bottom, #f9fcff, #ffffff );
    border-color: #dfeeff;
}


/* =========================================================
   SECTION HEADER
   ========================================================= */

.groups-section-header {
    flex: 0 0 65px;
    min-height: 65px;
    padding: 10px 12px;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid #eeeef5;
}


.groups-section-title {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}


    .groups-section-title > div:last-child {
        display: flex;
        flex-direction: column;
        min-width: 0;
    }


    .groups-section-title strong {
        font-size: 14px;
        font-weight: 700;
        color: #4f20c9;
        white-space: nowrap;
    }


.joined-groups-section .groups-section-title strong {
    color: #2563eb;
}


.groups-section-title span {
    margin-top: 2px;
    font-size: 11px;
    color: #8b8fa5;
    white-space: nowrap;
}


/* =========================================================
   SECTION ICON
   ========================================================= */

.groups-section-icon {
    width: 35px;
    height: 35px;
    flex: 0 0 35px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
}


.owner-icon {
    background: #eee8ff;
    color: #6d28d9;
}


.joined-icon {
    background: #e7f1ff;
    color: #3b82f6;
}


/* =========================================================
   GROUP COUNT
   ========================================================= */

.groups-count {
    min-width: 25px;
    height: 25px;
    padding: 0 7px;
    box-sizing: border-box;
    border-radius: 20px;
    background: #eee8ff;
    color: #6d28d9;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    flex-shrink: 0;
}


.joined-count {
    background: #e7f1ff;
    color: #3b82f6;
}


/* =========================================================
   INDEPENDENT GROUP SCROLL AREA
   ========================================================= */

.groups-section-scroll {
    /*
       3 group cards:

       70px card
       + 6px margin
       = 76px

       3 × 76 = 228px

       Add padding for a comfortable fit.
    */

    flex: 0 0 auto;
    height: auto;
    max-height: 230px;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 7px;
    box-sizing: border-box;
    scrollbar-width: thin;
    scrollbar-color: #6610f2 transparent;
}
    /* =========================================================
   CHROME / EDGE SCROLLBAR
   ========================================================= */

    .groups-section-scroll::-webkit-scrollbar {
        width: 6px;
    }

    .groups-section-scroll::-webkit-scrollbar-track {
        background: transparent;
    }

    .groups-section-scroll::-webkit-scrollbar-thumb {
        background: #6610f2;
        border-radius: 10px;
    }

        .groups-section-scroll::-webkit-scrollbar-thumb:hover {
            background: #92929a;
        }


/* =========================================================
   GROUP ITEM
   ========================================================= */

.group-sidebar-item {
    width: 100%;
    min-height: 70px;
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 10px;
    margin-bottom: 6px;
    border: 1px solid #e8e8ef;
    border-radius: 14px;
    background: #ffffff;
    cursor: pointer;
    text-align: left;
    box-sizing: border-box;
    transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}


    .group-sidebar-item:last-child {
        margin-bottom: 0;
    }


    .group-sidebar-item:hover {
        background: #faf9ff;
        border-color: #d8ccff;
    }


    .group-sidebar-item.selected {
        background: #faf7ff;
        border-color: #cdbbff;
        box-shadow: 0 2px 8px rgba(109, 40, 217, 0.07);
    }


/* =========================================================
   GROUP IMAGE
   ========================================================= */

.group-sidebar-image {
    width: 43px;
    height: 43px;
    min-width: 43px;
    position: relative;
    flex: 0 0 43px;
}


    .group-sidebar-image img {
        width: 43px;
        height: 43px;
        object-fit: cover;
        border-radius: 50%;
        border: 2px solid #eeeeee;
        display: block;
        box-sizing: border-box;
    }


/* =========================================================
   OWNER BADGE
   ========================================================= */

.group-owner-badge {
    position: absolute;
    right: -3px;
    bottom: -3px;
    width: 17px;
    height: 17px;
    border-radius: 50%;
    background: #fbbf24;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #ffffff;
    font-size: 8px;
    box-sizing: border-box;
}


/* =========================================================
   GROUP INFO
   ========================================================= */

.group-sidebar-info {
    min-width: 0;
    flex: 1 1 auto;
    overflow: hidden;
}


.group-sidebar-name {
    font-size: 13px;
    font-weight: 700;
    color: #18204a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}


.group-sidebar-meta {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-top: 4px;
    font-size: 11px;
    color: #8b8fa5;
    white-space: nowrap;
    overflow: hidden;
}


/* =========================================================
   MEMBER BADGE
   ========================================================= */

.group-member-badge {
    flex: 0 0 auto;
    padding: 4px 8px;
    border-radius: 20px;
    background: #edf5ff;
    color: #3983e8;
    font-size: 10px;
    font-weight: 600;
    white-space: nowrap;
}


/* =========================================================
   SELECTED INDICATOR
   ========================================================= */

.selected-group-indicator {
    position: absolute;
    right: 5px;
    top: 50%;
    width: 4px;
    height: 32px;
    transform: translateY(-50%);
    border-radius: 5px;
    background: linear-gradient( to bottom, #6d28d9, #ec4899 );
}


/* =========================================================
   EMPTY STATE
   ========================================================= */

.groups-empty-section {
    min-height: 110px;
    padding: 18px 10px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #9a9bad;
}


    .groups-empty-section > i {
        font-size: 25px;
        margin-bottom: 7px;
        color: #b6b0ce;
    }


    .groups-empty-section span {
        font-size: 11px;
        line-height: 1.4;
    }


    .groups-empty-section button {
        margin-top: 8px;
        padding: 0;
        border: 0;
        background: transparent;
        color: #6d28d9;
        font-size: 11px;
        font-weight: 600;
        cursor: pointer;
    }


/* =========================================================
   BOTTOM ACTIONS
   ========================================================= */

.groups-sidebar-actions {
    flex: 0 0 auto;
    padding-top: 4px;
    margin-top: 0;
}


/* =========================================================
   CREATE / JOIN BUTTONS
   ========================================================= */

.create-group-button,
.join-group-sidebar-button {
    width: 100%;
    height: 44px;
    border-radius: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    box-sizing: border-box;
    transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}


.create-group-button {
    border: 0;
    background: #5b21d6;
    color: #ffffff;
    margin-bottom: 8px;
}


    .create-group-button:hover {
        background: #4c1db5;
        transform: translateY(-1px);
    }


.join-group-sidebar-button {
    border: 1px solid #6d28d9;
    background: #ffffff;
    color: #6d28d9;
}


    .join-group-sidebar-button:hover {
        background: #faf7ff;
        transform: translateY(-1px);
    }


/* =========================================================
   SECURITY CARD
   ========================================================= */

.group-security-card {
    flex: 0 0 auto;
    width: 100%;
    margin-top: 10px;
    padding: 11px 12px;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid #e6e1ff;
    border-radius: 13px;
    background: linear-gradient( 135deg, #faf8ff, #f7faff );
}


/* =========================================================
   SECURITY ICON
   ========================================================= */

.security-icon {
    width: 35px;
    height: 35px;
    min-width: 35px;
    border-radius: 10px;
    background: #eee8ff;
    color: #6d28d9;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
}


/* =========================================================
   SECURITY CONTENT
   ========================================================= */

.security-content {
    min-width: 0;
}


.group-security-card strong {
    display: block;
    font-size: 11px;
    font-weight: 700;
    color: #40316d;
}


.group-security-card p {
    margin: 3px 0 0;
    font-size: 10px;
    line-height: 1.35;
    color: #85849a;
}


/* =========================================================
   IMPORTANT:
   PREVENT FLEX CHILDREN FROM OVERFLOWING
   ========================================================= */

.groups-sidebar > * {
    min-width: 0;
}


/* =========================================================
   MAIN CONTENT GAP
   ========================================================= */

/*
   If your sidebar and main panel are direct children
   of the same flex container, this gives them a clean
   16px separation.
*/

.groups-sidebar + * {
    min-width: 0;
}


/*
   If your main layout has a wrapper, use this class
   on that wrapper:

   .groups-layout {
       display: flex;
       gap: 16px;
   }
*/


/* =========================================================
   TABLET
   ========================================================= */

@media (max-width: 1000px) {

    .groups-sidebar {
        width: 290px;
        min-width: 290px;
        flex-basis: 290px;
        margin-right: 12px;
        padding: 15px;
    }

    .groups-sidebar-header h3 {
        font-size: 19px;
    }

    .groups-section-header {
        min-height: 60px;
        flex-basis: 60px;
    }

    .group-sidebar-item {
        min-height: 66px;
        padding: 8px;
    }

    .group-sidebar-image {
        width: 40px;
        height: 40px;
        min-width: 40px;
        flex-basis: 40px;
    }

        .group-sidebar-image img {
            width: 40px;
            height: 40px;
        }
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 768px) {

    .groups-sidebar {
        width: 290px;
        min-width: 290px;
        flex: 0 0 290px;
        margin-right: 0;
        padding: 14px;
        /*
           Mobile sidebar should remain a complete panel.
        */
        border-radius: 16px;
    }

    /*
       Keep the action buttons visible on mobile.
    */
    .groups-sidebar-actions {
        padding-top: 4px;
    }

    .group-security-card {
        margin-top: 8px;
        padding: 9px 10px;
    }

    .security-icon {
        width: 32px;
        height: 32px;
        min-width: 32px;
    }

    .group-security-card strong {
        font-size: 10px;
    }

    .group-security-card p {
        font-size: 9px;
    }
}


/* =========================================================
   SMALL MOBILE
   ========================================================= */

@media (max-width: 500px) {

    .groups-sidebar {
        width: 100%;
        min-width: 0;
        flex: 1 1 auto;
        margin-right: 0;
    }

    .groups-section {
        /*
           Give both sections usable space on small screens.
        */
        /*min-height: 150px;*/
        min-height: 0px;
    }

    .group-sidebar-item {
        min-height: 64px;
    }

    .groups-section-header {
        min-height: 58px;
        flex-basis: 58px;
    }

    .groups-section-title strong {
        font-size: 13px;
    }

    .groups-section-title span {
        font-size: 10px;
    }
}
/*images touch and zoom css*/
.gallery-touch-area {
    touch-action: pan-y pinch-zoom;
}

.modal-img {
    touch-action: pinch-zoom;
    user-select: none;
    -webkit-user-select: none;
    -webkit-touch-callout: none;
}




















/* =========================================
   MAIN AREA
========================================= */

.group-main {
    min-width: 0;
    background: white;
    border: 1px solid #e9e7f2;
    border-radius: 20px;
    box-shadow: 0 5px 25px rgba(43, 32, 90, 0.05);
    overflow: hidden;
}


/* =========================================
   NO GROUP SELECTED
========================================= */

.group-no-selection {
    min-height: 650px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #777895;
}


.no-selection-icon {
    width: 70px;
    height: 70px;
    border-radius: 22px;
    background: #f1edff;
    color: #7047ff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    margin-bottom: 18px;
}


.group-no-selection h2 {
    margin: 0;
    color: #172052;
    font-size: 24px;
}


.group-no-selection p {
    margin-top: 8px;
    font-size: 14px;
}


/* =========================================
   GROUP HEADER
========================================= */

.group-header {
    padding: 28px 30px;
    display: flex;
    justify-content: space-between;
    gap: 25px;
    border-bottom: 1px solid #eeeef5;
}


.group-header-left {
    display: flex;
    gap: 20px;
    min-width: 0;
}


.group-large-image {
    width: 90px;
    height: 90px;
    flex-shrink: 0;
    border-radius: 22px;
    overflow: hidden;
    border: 3px solid #f1ecff;
    box-shadow: 0 5px 15px rgba(100, 70, 200, .12);
}


    .group-large-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }


.group-header-info {
    min-width: 0;
}


.group-title-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}


    .group-title-row h1 {
        margin: 0;
        color: #14204e;
        font-size: 25px;
        font-weight: 750;
    }


.private-badge,
.public-badge {
    padding: 6px 10px;
    border-radius: 9px;
    font-size: 11px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}


.private-badge {
    background: #f0eaff;
    color: #6945f5;
}


.public-badge {
    background: #eaf8ef;
    color: #219653;
}


.group-description {
    margin: 9px 0 13px;
    max-width: 650px;
    color: #646783;
    font-size: 14px;
    line-height: 1.5;
}


.group-statistics {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 22px;
}


.group-stat {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 12px;
    color: #666984;
}


    .group-stat i {
        color: #7047ff;
        font-size: 14px;
    }


.group-settings-button {
    height: 42px;
    padding: 0 16px;
    flex-shrink: 0;
    border: 1px solid #987cff;
    border-radius: 10px;
    background: white;
    color: #6945f5;
    font-size: 13px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 7px;
    cursor: pointer;
    transition: .2s ease;
}


    .group-settings-button:hover {
        background: #7047ff;
        color: white;
    }


/* =========================================
   TABS
========================================= */

.group-tabs {
    height: 58px;
    padding: 0 25px;
    display: flex;
    align-items: stretch;
    gap: 25px;
    border-bottom: 1px solid #eeeeF4;
}


.group-tab {
    position: relative;
    border: none;
    background: transparent;
    color: #656984;
    padding: 0 8px;
    font-size: 13px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 7px;
    cursor: pointer;
}


    .group-tab:hover {
        color: #7047ff;
    }


    .group-tab.active {
        color: #7047ff;
        font-weight: 650;
    }


        .group-tab.active::after {
            content: "";
            position: absolute;
            bottom: -1px;
            left: 0;
            right: 0;
            height: 3px;
            border-radius: 3px 3px 0 0;
            background: linear-gradient( 90deg, #7047ff, #e94fa5 );
        }


/* =========================================
   CONTENT
========================================= */

.group-content {
    padding: 24px 28px 30px;
    min-height: 450px;
}


.group-placeholder-card {
    min-height: 350px;
    border: 1px dashed #ddd9eb;
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #777895;
}


    .group-placeholder-card i {
        font-size: 34px;
        color: #7047ff;
        margin-bottom: 12px;
    }


    .group-placeholder-card h3 {
        margin: 0;
        color: #172052;
    }


    .group-placeholder-card p {
        margin-top: 8px;
        font-size: 13px;
    }


/* =========================================
   RESPONSIVE
========================================= */

@media (max-width: 1000px) {

    .groups-container {
        grid-template-columns: 230px minmax(0, 1fr);
    }

    .group-header {
        flex-direction: column;
    }

    .group-settings-button {
        width: fit-content;
    }
}


@media (max-width: 750px) {

    .groups-page {
        padding: 15px;
    }

    .groups-container {
        grid-template-columns: 1fr;
    }

    .groups-sidebar {
        position: static;
    }

    .groups-list {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .group-header {
        padding: 20px;
    }

    .group-content {
        padding: 18px;
    }
}


@media (max-width: 500px) {

    .groups-list {
        grid-template-columns: 1fr;
    }

    .group-header-left {
        flex-direction: column;
    }

    .group-tabs {
        overflow-x: auto;
        gap: 12px;
    }

    .group-statistics {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
}

/* ==========================================
   CREATE GROUP MODAL
========================================== */

.create-group-overlay {
    position: fixed;
    inset: 0;
    background: rgba(20, 18, 40, 0.48);
    backdrop-filter: blur(3px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    z-index: 5000;
}


.create-group-modal {
    width: 100%;
    max-width: 480px;
    background: #ffffff;
    border-radius: 22px;
    box-shadow: 0 25px 70px rgba(30, 20, 80, .25);
    overflow: hidden;
    animation: createGroupModalIn .2s ease-out;
}


@keyframes createGroupModalIn {

    from {
        opacity: 0;
        transform: translateY(15px) scale(.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}


/* HEADER */

.create-group-modal-header {
    padding: 24px 25px 18px;
    display: flex;
    justify-content: space-between;
    gap: 15px;
    border-bottom: 1px solid #eeeeF5;
}


    .create-group-modal-header h2 {
        margin: 0;
        font-size: 22px;
        color: #182052;
        font-weight: 750;
    }


    .create-group-modal-header p {
        margin: 7px 0 0;
        color: #777895;
        font-size: 13px;
        line-height: 1.5;
    }


.modal-close-button {
    width: 34px;
    height: 34px;
    flex-shrink: 0;
    border: none;
    border-radius: 10px;
    background: #f5f4f9;
    color: #65667a;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}


    .modal-close-button:hover {
        background: #eeeaf8;
        color: #7047ff;
    }


/* BODY */

.create-group-modal-body {
    padding: 24px 25px;
}


.form-group {
    margin-bottom: 20px;
}


    .form-group label {
        display: block;
        margin-bottom: 8px;
        font-size: 13px;
        font-weight: 650;
        color: #252950;
    }


.group-form-input {
    width: 100%;
    height: 46px;
    box-sizing: border-box;
    padding: 0 13px;
    border: 1px solid #deddeb;
    border-radius: 11px;
    background: #ffffff;
    color: #252950;
    font-size: 13px;
    outline: none;
    transition: .2s ease;
}


    .group-form-input:focus {
        border-color: #7047ff;
        box-shadow: 0 0 0 3px rgba(112, 71, 255, .10);
    }


.form-help {
    display: block;
    margin-top: 6px;
    color: #9292a5;
    font-size: 11px;
}


/* GROUP IMAGE */

.group-image-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 8px 0 4px;
}


.group-image-preview {
    width: 92px;
    height: 92px;
    border-radius: 50%;
    background: linear-gradient( 135deg, #eee8ff, #fbeaf5 );
    border: 3px solid #eee7ff;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    color: #7047ff;
    font-size: 34px;
}


    .group-image-preview img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }


.change-group-image-button {
    margin-top: 10px;
    border: none;
    background: transparent;
    color: #7047ff;
    font-size: 12px;
    font-weight: 650;
    cursor: pointer;
}


    .change-group-image-button:hover {
        text-decoration: underline;
    }


.group-image-section small {
    margin-top: 3px;
    color: #9999aa;
    font-size: 10px;
}


/* FOOTER */

.create-group-modal-footer {
    padding: 17px 25px 22px;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    border-top: 1px solid #eeeeF5;
}


.cancel-group-button {
    height: 43px;
    padding: 0 18px;
    border: 1px solid #dedbea;
    border-radius: 10px;
    background: white;
    color: #65667a;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}


    .cancel-group-button:hover {
        background: #f7f6fa;
    }


.create-group-submit {
    height: 43px;
    min-width: 140px;
    padding: 0 20px;
    border: none;
    border-radius: 10px;
    background: linear-gradient( 135deg, #6742f5, #9345e9 );
    color: white;
    font-size: 13px;
    font-weight: 650;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    cursor: pointer;
    box-shadow: 0 6px 15px rgba(103, 66, 245, .22);
}


    .create-group-submit:hover {
        transform: translateY(-1px);
        box-shadow: 0 8px 18px rgba(103, 66, 245, .28);
    }


    .create-group-submit:disabled {
        opacity: .65;
        cursor: not-allowed;
        transform: none;
    }


.create-spinner {
    width: 15px;
    height: 15px;
    border: 2px solid rgba(255,255,255,.4);
    border-top-color: white;
    border-radius: 50%;
    animation: createSpinner .7s linear infinite;
}


@keyframes createSpinner {

    to {
        transform: rotate(360deg);
    }
}

/* Success popup CSS */
.group-created-modal {
    width: 100%;
    max-width: 430px;
    background: white;
    border-radius: 22px;
    overflow: hidden;
    box-shadow: 0 25px 70px rgba(30,20,80,.28);
}


.group-created-success {
    padding: 25px 20px 30px;
    text-align: center;
    background: linear-gradient( 135deg, #5f28d8, #8b3ee9 );
    color: white;
}


.success-check {
    width: 52px;
    height: 52px;
    margin: 0 auto 10px;
    border-radius: 50%;
    background: #3bd487;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    box-shadow: 0 5px 15px rgba(0,0,0,.15);
}


.group-created-success h2 {
    margin: 0;
    font-size: 19px;
}


.created-group-body {
    padding: 25px;
    text-align: center;
}


.created-group-image {
    width: 90px;
    height: 90px;
    margin: -58px auto 14px;
    border-radius: 50%;
    background: linear-gradient( 135deg, #f6d5e7, #ddd2ff );
    border: 5px solid white;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #7047ff;
    font-size: 35px;
    position: relative;
}


.created-group-body h3 {
    margin: 5px 0 15px;
    font-size: 20px;
    color: #172052;
}


.group-id-label {
    display: block;
    font-size: 11px;
    color: #777895;
    margin-bottom: 6px;
}


.group-id-box {
    padding: 11px;
    border: 1px dashed #8d6cff;
    border-radius: 10px;
    background: #faf8ff;
    color: #633de8;
    font-size: 16px;
    font-weight: 700;
    letter-spacing: .5px;
}


.group-created-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 13px;
}


    .group-created-actions button {
        height: 40px;
        border: 1px solid #9a80ff;
        border-radius: 9px;
        background: white;
        color: #6945f5;
        font-size: 12px;
        font-weight: 600;
        cursor: pointer;
    }


        .group-created-actions button:hover {
            background: #f5f1ff;
        }


.view-created-group-button {
    width: 100%;
    height: 43px;
    margin-top: 14px;
    border: none;
    border-radius: 10px;
    background: linear-gradient( 135deg, #6742f5, #9345e9 );
    color: white;
    font-size: 13px;
    font-weight: 650;
    cursor: pointer;
}

/* second session css code */

/* ================================================================
       Groups page - responsive/mobile support
       Desktop styles are intentionally not changed.
       ================================================================ */

.groups-page,
.groups-container,
.group-main {
    max-width: 100%;
    min-width: 0;
}

.groups-page {
    width: 100%;
    overflow-x: hidden;
}

.groups-container {
    width: 100%;
    overflow-x: hidden;
}

.mobile-groups-toolbar,
.groups-mobile-backdrop {
    display: none;
}

@media (max-width: 768px) {
    .groups-page {
        width: 100%;
        max-width: 100vw;
        margin: 0;
        padding: 0;
        overflow-x: hidden;
    }

    .groups-container {
        position: relative;
        display: block !important;
        width: 100%;
        max-width: 100vw;
        min-height: calc(100dvh - 60px);
        overflow-x: hidden;
    }
    /* ------------------------------------------------------------
           My Groups becomes a slide-out drawer on phones/tablets.
           ------------------------------------------------------------ */
    .groups-sidebar {
        position: fixed !important;
        top: 0;
        left: 0;
        bottom: 0;
        z-index: 1100;
        width: min(86vw, 340px) !important;
        max-width: 340px !important;
        height: 100dvh;
        margin: 0 !important;
        background: #fff;
        overflow-x: hidden;
        overflow-y: auto;
        box-shadow: 8px 0 28px rgba(0, 0, 0, .18);
        transform: translateX(-105%);
        transition: transform .25s ease;
        padding-bottom: 20px;
    }

    .groups-sidebar.mobile-open {
        transform: translateX(0);
    }

    .groups-sidebar.mobile-closed {
        transform: translateX(-105%);
    }

    .groups-sidebar-header {
        position: sticky;
        top: 0;
        z-index: 2;
        background: #fff;
    }

    .groups-list {
        max-height: none !important;
        overflow-y: visible !important;
    }

    /* Dark transparent layer behind the drawer. */
    .groups-mobile-backdrop {
        display: block;
        position: fixed;
        inset: 0;
        z-index: 1090;
        width: 100%;
        height: 100%;
        padding: 0;
        border: 0;
        background: rgba(0, 0, 0, .38);
        cursor: pointer;
    }
    /* ------------------------------------------------------------
           Main content takes the whole phone width.
           ------------------------------------------------------------ */
    .group-main {
        display: block !important;
        width: 100% !important;
        max-width: 100vw !important;
        min-width: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow-x: hidden !important;
    }

    .mobile-groups-toolbar {
        display: flex;
        align-items: center;
        width: 100%;
        min-height: 50px;
        box-sizing: border-box;
        padding: 7px 10px;
        background: #fff;
        border-bottom: 1px solid rgba(0, 0, 0, .08);
        position: sticky;
        top: 0;
        z-index: 100;
    }

    .mobile-groups-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 7px;
        min-height: 38px;
        padding: 7px 12px;
        border: 1px solid rgba(0, 0, 0, .12);
        border-radius: 9px;
        background: #fff;
        color: inherit;
        font-size: .92rem;
        font-weight: 600;
        cursor: pointer;
    }

        .mobile-groups-toggle i {
            font-size: 1.15rem;
        }
    /* ------------------------------------------------------------
           Header: shrink/reflow instead of causing horizontal scroll.
           ------------------------------------------------------------ */
    .group-header {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        box-sizing: border-box;
        padding: 14px 12px !important;
        overflow: hidden;
    }

    .group-header-left {
        width: 100%;
        min-width: 0;
        display: flex;
        align-items: flex-start;
        gap: 10px;
    }

    .group-large-image {
        flex: 0 0 auto;
    }

        .group-large-image img {
            width: 58px;
            height: 58px;
            max-width: 58px;
            object-fit: cover;
            border-radius: 12px;
        }

    .group-header-info {
        flex: 1 1 auto;
        width: 0;
        min-width: 0;
    }

    .group-title-row {
        width: 100%;
        min-width: 0;
        display: flex;
        align-items: flex-start;
        flex-wrap: wrap;
        gap: 6px;
    }

        .group-title-row h1 {
            flex: 1 1 auto;
            min-width: 0;
            max-width: 100%;
            margin: 0;
            font-size: clamp(1.1rem, 5vw, 1.5rem);
            line-height: 1.25;
            overflow-wrap: anywhere;
            word-break: break-word;
        }

    .private-badge {
        flex: 0 0 auto;
        white-space: nowrap;
    }

    .group-description {
        width: 100%;
        max-width: 100%;
        margin: 6px 0;
        overflow-wrap: anywhere;
        word-break: break-word;
    }

    .group-statistics {
        width: 100%;
        max-width: 100%;
        display: flex;
        flex-wrap: wrap;
        gap: 6px 10px;
    }

    .group-stat {
        min-width: 0;
        max-width: 100%;
        overflow-wrap: anywhere;
        word-break: break-word;
    }

    .group-settings-button {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        justify-content: center;
    }
    /* ------------------------------------------------------------
           Tabs can scroll horizontally on very small screens.
           They will never widen the page.
           ------------------------------------------------------------ */
    .group-tabs {
        width: 100% !important;
        max-width: 100vw !important;
        min-width: 0 !important;
        box-sizing: border-box;
        display: flex;
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        white-space: nowrap;
        padding-left: 8px !important;
        padding-right: 8px !important;
    }

        .group-tabs::-webkit-scrollbar {
            display: none;
        }

        .group-tabs button {
            flex: 0 0 auto !important;
            white-space: nowrap;
        }

    .group-content {
        width: 100% !important;
        max-width: 100vw !important;
        min-width: 0 !important;
        box-sizing: border-box;
        overflow-x: hidden !important;
        padding: 10px !important;
    }

    .group-no-selection,
    .group-placeholder-card {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }
    /* ------------------------------------------------------------
           Create group modal fits phones without changing its desktop UI.
           ------------------------------------------------------------ */
    .create-group-overlay {
        padding: 10px !important;
        overflow-y: auto !important;
        box-sizing: border-box;
    }

    .create-group-modal,
    .group-created-modal {
        width: 100% !important;
        max-width: 520px !important;
        max-height: calc(100dvh - 20px);
        box-sizing: border-box;
        overflow-y: auto;
        overflow-x: hidden;
    }

    .create-group-modal-body,
    .created-group-body {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }

    .group-form-input {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }

    .group-id-box,
    .group-id-box * {
        max-width: 100%;
        overflow-wrap: anywhere;
        word-break: break-word;
    }
    /* Long images/content must not force horizontal scrolling. */
    .group-main img,
    .group-content img {
        max-width: 100%;
    }
}

@media (max-width: 480px) {
    .groups-sidebar {
        width: 88vw !important;
    }

    .group-header {
        padding: 11px 10px !important;
    }

    .group-large-image img {
        width: 52px;
        height: 52px;
        max-width: 52px;
        border-radius: 11px;
    }

    .group-statistics {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 6px;
    }

    .group-stat:last-child {
        grid-column: 1 / -1;
    }

    .group-content {
        padding: 8px !important;
    }
}

/* ================================================================
   FINAL MOBILE OVERRIDES
   These rules intentionally come AFTER the previous responsive rules
   so they also override any layout rules coming from the existing
   Groups page CSS.
   ================================================================ */
@media (max-width: 768px) {
    /* Never allow the group page itself to become wider than the viewport. */
    .groups-page,
    .groups-container,
    .group-main,
    .group-header,
    .group-tabs,
    .group-content {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        box-sizing: border-box !important;
    }

    .groups-page,
    .groups-container,
    .group-main {
        overflow-x: hidden !important;
    }
    /* ------------------------------------------------------------
       GROUP HEADER
       Force a single-column header. The old desktop layout can
       otherwise squeeze the title into a very narrow column.
       ------------------------------------------------------------ */
    .group-header {
        display: block !important;
        position: relative !important;
        padding: 14px 12px !important;
        margin: 0 !important;
        overflow: visible !important;
    }

    .group-header-left {
        display: grid !important;
        grid-template-columns: 58px minmax(0, 1fr) !important;
        align-items: start !important;
        column-gap: 12px !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        box-sizing: border-box !important;
    }

    .group-large-image {
        width: 58px !important;
        min-width: 58px !important;
        max-width: 58px !important;
        flex: none !important;
    }

        .group-large-image img {
            display: block !important;
            width: 58px !important;
            height: 58px !important;
            max-width: 58px !important;
            min-width: 58px !important;
            object-fit: cover !important;
        }

    .group-header-info {
        display: block !important;
        width: auto !important;
        max-width: none !important;
        min-width: 0 !important;
        flex: none !important;
        overflow: visible !important;
    }

    .group-title-row {
        display: flex !important;
        flex-direction: row !important;
        align-items: flex-start !important;
        justify-content: flex-start !important;
        flex-wrap: wrap !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        gap: 6px !important;
    }

        .group-title-row h1 {
            display: block !important;
            width: auto !important;
            max-width: 100% !important;
            min-width: 0 !important;
            margin: 0 !important;
            padding: 0 !important;
            font-size: 1.35rem !important;
            line-height: 1.25 !important;
            white-space: normal !important;
            word-break: normal !important;
            overflow-wrap: anywhere !important;
            writing-mode: horizontal-tb !important;
            text-orientation: mixed !important;
        }

    .private-badge {
        display: inline-flex !important;
        align-items: center !important;
        flex: 0 0 auto !important;
        width: auto !important;
        max-width: 100% !important;
        white-space: nowrap !important;
    }

    .group-description {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        margin: 7px 0 !important;
        white-space: normal !important;
        word-break: normal !important;
        overflow-wrap: anywhere !important;
        writing-mode: horizontal-tb !important;
    }

    .group-statistics {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: wrap !important;
        align-items: center !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        gap: 6px 12px !important;
    }

    .group-stat {
        display: inline-flex !important;
        align-items: center !important;
        width: auto !important;
        max-width: 100% !important;
        min-width: 0 !important;
        white-space: normal !important;
        overflow-wrap: anywhere !important;
        writing-mode: horizontal-tb !important;
    }
    /* Settings must sit BELOW the header information on phones. */
    .group-settings-button {
        display: flex !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        margin: 12px 0 0 !important;
        box-sizing: border-box !important;
        justify-content: center !important;
        white-space: nowrap !important;
    }
    /* ------------------------------------------------------------
       TABS
       ------------------------------------------------------------ */
    .group-tabs {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap !important;
        align-items: stretch !important;
        overflow-x: auto !important;
        overflow-y: hidden !important;
        -webkit-overflow-scrolling: touch !important;
        scrollbar-width: none !important;
        white-space: nowrap !important;
    }

        .group-tabs::-webkit-scrollbar {
            display: none !important;
        }

        .group-tabs > button {
            display: inline-flex !important;
            flex: 0 0 auto !important;
            width: auto !important;
            min-width: max-content !important;
            white-space: nowrap !important;
        }
    /* ------------------------------------------------------------
       CONTENT
       ------------------------------------------------------------ */
    .group-content {
        display: block !important;
        padding: 10px !important;
        overflow-x: hidden !important;
    }

        .group-content > * {
            width: 100% !important;
            max-width: 100% !important;
            min-width: 0 !important;
            box-sizing: border-box !important;
        }

    .group-placeholder-card,
    .group-no-selection {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        box-sizing: border-box !important;
    }
    /* Prevent text in cards/tables from creating horizontal overflow. */
    .group-main h1,
    .group-main h2,
    .group-main h3,
    .group-main h4,
    .group-main p,
    .group-main span,
    .group-main div {
        max-width: 100%;
        overflow-wrap: anywhere;
    }
}

@media (max-width: 480px) {
    .group-header {
        padding: 12px 10px !important;
    }

    .group-header-left {
        grid-template-columns: 52px minmax(0, 1fr) !important;
        column-gap: 10px !important;
    }

    .group-large-image,
    .group-large-image img {
        width: 52px !important;
        min-width: 52px !important;
        max-width: 52px !important;
        height: 52px !important;
    }

    .group-title-row h1 {
        font-size: 1.2rem !important;
    }

    .group-statistics {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 6px !important;
    }

    .group-stat:last-child {
        grid-column: 1 / -1 !important;
    }

    .group-content {
        padding: 8px !important;
    }
}

/* join button css */
/* =========================================
   EMPTY STATE ACTIONS
   ========================================= */

.no-selection-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
    max-width: 300px;
    margin: 24px auto 0;
}


/* =========================================
   JOIN GROUP BUTTON
   ========================================= */

.join-group-empty-button {
    width: 100%;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 18px;
    border: 1px solid #5b21d6;
    border-radius: 8px;
    background: #ffffff;
    color: #5b21d6;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
}

    .join-group-empty-button i {
        font-size: 16px;
    }

    .join-group-empty-button:hover {
        background: #f5f0ff;
        box-shadow: 0 3px 10px rgba(91, 33, 214, 0.15);
    }

    .join-group-empty-button:active {
        transform: scale(0.98);
    }


/* =========================================
   CREATE GROUP BUTTON
   ========================================= */

.create-group-empty-button {
    width: 100%;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 18px;
    border: none;
    border-radius: 8px;
    background: #5b21d6;
    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
}

    .create-group-empty-button i {
        font-size: 16px;
    }

    .create-group-empty-button:hover {
        background: #4c1bb5;
        box-shadow: 0 3px 10px rgba(91, 33, 214, 0.2);
    }

    .create-group-empty-button:active {
        transform: scale(0.98);
    }

.no-selection-actions {
    width: 100%;
    max-width: 300px;
}

.join-group-sidebar-button {
    width: 100%;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 8px;
    padding: 10px 18px;
    border: 1px solid #5b21d6;
    border-radius: 8px;
    background: #ffffff;
    color: #5b21d6;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

    .join-group-sidebar-button i {
        font-size: 16px;
    }

    .join-group-sidebar-button:hover {
        background: #f5f0ff;
        box-shadow: 0 3px 10px rgba(91, 33, 214, 0.15);
    }

    .join-group-sidebar-button:active {
        transform: scale(0.98);
    }

/* over view tab css */
/* =========================================
   GROUP OVERVIEW
   ========================================= */

.group-overview {
    width: 100%;
    padding: 20px;
    box-sizing: border-box;
}


/* Summary */

.overview-summary-card {
    width: 100%;
    padding: 20px;
    margin-bottom: 16px;
    background: #fff;
    border: 1px solid #eee;
    border-radius: 14px;
}

.overview-summary-header {
    display: flex;
    align-items: center;
    gap: 16px;
}

.overview-summary-image img {
    width: 72px;
    height: 72px;
    object-fit: cover;
    border-radius: 14px;
}

.overview-summary-info h2 {
    margin: 0 0 5px;
    font-size: 21px;
    font-weight: 700;
}

.overview-summary-info p {
    margin: 0;
    color: #777;
    font-size: 14px;
}


/* Statistics */

.overview-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 18px;
}

.overview-stat-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    background: #fff;
    border: 1px solid #eee;
    border-radius: 12px;
}

.overview-stat-icon {
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: #f4efff;
    color: #5b21d6;
    font-size: 18px;
}

.overview-stat-info {
    display: flex;
    flex-direction: column;
}

    .overview-stat-info strong {
        font-size: 17px;
        font-weight: 700;
    }

    .overview-stat-info span {
        color: #777;
        font-size: 12px;
    }


/* Sections */

.overview-section {
    margin-bottom: 18px;
    padding: 18px;
    background: #fff;
    border: 1px solid #eee;
    border-radius: 14px;
}

.overview-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

    .overview-section-header h3 {
        margin: 0;
        font-size: 17px;
        font-weight: 700;
    }

    .overview-section-header span {
        display: block;
        margin-top: 3px;
        color: #888;
        font-size: 12px;
    }

.overview-view-button {
    border: 0;
    background: transparent;
    color: #5b21d6;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}


/* Members */

.overview-members {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
}

.overview-member {
    width: 70px;
    text-align: center;
}

    .overview-member img {
        width: 54px;
        height: 54px;
        object-fit: cover;
        border-radius: 50%;
        display: block;
        margin: 0 auto 6px;
    }

.overview-member-name {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    font-size: 12px;
    font-weight: 600;
}

.overview-member-role {
    display: block;
    margin-top: 2px;
    color: #777;
    font-size: 10px;
}


/* Information */

.overview-information {
    display: flex;
    flex-direction: column;
}

.overview-information-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
}

    .overview-information-row:last-child {
        border-bottom: 0;
    }

    .overview-information-row span {
        display: flex;
        align-items: center;
        gap: 8px;
        color: #777;
        font-size: 13px;
    }

    .overview-information-row strong {
        font-size: 13px;
    }


/* Admin */

.overview-admin-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    padding: 18px;
    background: #f8f5ff;
    border: 1px solid #e8defc;
    border-radius: 14px;
}

    .overview-admin-card h3 {
        margin: 0 0 4px;
        font-size: 16px;
    }

    .overview-admin-card p {
        margin: 0;
        color: #777;
        font-size: 13px;
    }

.overview-settings-button {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 9px 14px;
    border: 0;
    border-radius: 8px;
    background: #5b21d6;
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}


/* Empty */

.overview-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 25px;
    color: #999;
    font-size: 13px;
}
/* over view mobile css */
@media (max-width: 600px) {

    .group-overview {
        padding: 12px;
    }

    .overview-stats {
        grid-template-columns: 1fr;
    }

    .overview-summary-card {
        padding: 15px;
    }

    .overview-summary-image img {
        width: 58px;
        height: 58px;
    }

    .overview-summary-info h2 {
        font-size: 18px;
    }

    .overview-section {
        padding: 14px;
    }

    .overview-members {
        gap: 14px;
    }

    .overview-information-row {
        align-items: flex-start;
        gap: 12px;
    }

        .overview-information-row strong {
            text-align: right;
            max-width: 55%;
            word-break: break-word;
        }

    .overview-admin-card {
        align-items: flex-start;
        flex-direction: column;
    }

    .overview-settings-button {
        width: 100%;
        justify-content: center;
    }
}

/* setting tab css */
.group-settings-content {
    width: 100%;
    max-width: 750px;
    /* margin: 0 auto; */
    padding: 20px;
    box-sizing: border-box;
}

.settings-header {
    margin-bottom: 25px;
}

    .settings-header h3 {
        margin: 0 0 5px;
        font-size: 20px;
        font-weight: 700;
    }

    .settings-header p {
        margin: 0;
        color: #777;
        font-size: 14px;
    }

.group-setting-section {
    margin-bottom: 22px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.group-setting-label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 600;
}

.group-settings-image img {
    width: 90px;
    height: 90px;
    object-fit: cover;
    border-radius: 14px;
    border: 1px solid #eee;
}

.group-icon-setting {
    display: flex;
    align-items: center;
    gap: 18px;
}

.group-icon-actions {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.change-group-icon-button {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 9px 14px;
    border: 1px solid #5b21d6;
    border-radius: 8px;
    background: #fff;
    color: #5b21d6;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}

.group-icon-actions small,
.group-setting-help {
    color: #888;
    font-size: 11px;
}

.group-setting-input,
.group-setting-textarea,
.group-setting-readonly {
    width: 100%;
    box-sizing: border-box;
    padding: 11px 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
}

    .group-setting-input:focus,
    .group-setting-textarea:focus {
        outline: none;
        border-color: #5b21d6;
    }

.group-setting-textarea {
    min-height: 100px;
    resize: vertical;
}

.group-setting-readonly {
    background: #f7f7f7;
    color: #555;
}

.group-code-container {
    display: flex;
    gap: 8px;
}

.group-code-input {
    flex: 1;
    background: #f7f7f7;
    font-weight: 600;
    letter-spacing: .5px;
}

.copy-group-code-button {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: #fff;
    color: #444;
    font-weight: 600;
    cursor: pointer;
}

.group-settings-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 25px;
}

.save-group-settings-button {
    padding: 11px 20px;
    border: 0;
    border-radius: 8px;
    background: #5b21d6;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

    .save-group-settings-button:disabled {
        opacity: .6;
        cursor: not-allowed;
    }

/* Mobile css */
@media (max-width: 600px) {

    .group-settings-content {
        padding: 14px;
    }

    .group-icon-setting {
        align-items: flex-start;
    }

    .group-code-container {
        flex-direction: column;
    }

    .copy-group-code-button {
        width: 100%;
        justify-content: center;
    }

    .group-settings-actions {
        justify-content: stretch;
    }

    .save-group-settings-button {
        width: 100%;
    }
}

.no-selection-content {
    margin: 20px;
}

/*Groups and Members */

/* =========================================
   JOIN REQUESTS TAB
   ========================================= */
.group-content-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 4px 4px 20px;
    border-bottom: 1px solid #e9ecef;
    margin-bottom: 20px;
}

.group-content-header h3 {
    margin: 0 0 5px;
    font-size: 20px;
    font-weight: 700;
    color: #212529;
}

.group-content-header p {
    margin: 0;
    font-size: 14px;
    line-height: 1.5;
    color: #6c757d;
}


/* =========================================
   REQUEST LIST
   ========================================= */

.group-requests-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}


/* =========================================
   REQUEST CARD
   ========================================= */

.group-request-card {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    padding: 14px 16px;
    background: #ffffff;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    transition: box-shadow 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

    .group-request-card:hover {
        border-color: #dfe3e8;
        box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06);
    }


/* =========================================
   USER IMAGE
   ========================================= */

.group-member-image {
    flex: 0 0 auto;
    width: 52px;
    height: 52px;
}

    .group-member-image img {
        display: block;
        width: 52px;
        height: 52px;
        object-fit: cover;
        border-radius: 50%;
        border: 2px solid #f1f3f5;
        background: #f8f9fa;
    }


/* =========================================
   REQUEST INFORMATION
   ========================================= */

.group-request-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    flex: 1;
    min-width: 0;
}

    .group-request-info strong {
        display: block;
        margin-bottom: 4px;
        color: #212529;
        font-size: 15px;
        font-weight: 600;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .group-request-info span {
        display: block;
        color: #6c757d;
        font-size: 13px;
        line-height: 1.4;
    }


/* =========================================
   ACTION BUTTONS
   ========================================= */

.group-request-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.approve-request-button,
.reject-request-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 36px;
    padding: 7px 13px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.15s ease;
}

    .approve-request-button i,
    .reject-request-button i {
        font-size: 14px;
    }


/* Approve */

.approve-request-button {
    color: #198754;
    background: #eaf7ef;
    border: 1px solid #cfe9d8;
}

    .approve-request-button:hover {
        color: #ffffff;
        background: #198754;
        border-color: #198754;
    }

    .approve-request-button:active {
        transform: scale(0.97);
    }


/* Reject */

.reject-request-button {
    color: #dc3545;
    background: #fff0f1;
    border: 1px solid #f5c6cb;
}

    .reject-request-button:hover {
        color: #ffffff;
        background: #dc3545;
        border-color: #dc3545;
    }

    .reject-request-button:active {
        transform: scale(0.97);
    }


/* =========================================
   EMPTY STATE
   ========================================= */

.group-empty-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 260px;
    padding: 40px 20px;
    text-align: center;
    background: #fafbfc;
    border: 1px dashed #dee2e6;
    border-radius: 14px;
}

    .group-empty-content > i {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 64px;
        height: 64px;
        margin-bottom: 16px;
        color: #6c757d;
        background: #f1f3f5;
        border-radius: 50%;
        font-size: 28px;
    }

    .group-empty-content h3 {
        margin: 0 0 7px;
        color: #343a40;
        font-size: 17px;
        font-weight: 600;
    }

    .group-empty-content p {
        margin: 0;
        color: #868e96;
        font-size: 14px;
    }


/* =========================================
   TABLET
   ========================================= */

@media (max-width: 768px) {

    .group-content-header {
        padding-bottom: 16px;
        margin-bottom: 16px;
    }

        .group-content-header h3 {
            font-size: 18px;
        }

        .group-content-header p {
            font-size: 13px;
        }

    .group-request-card {
        padding: 13px;
        gap: 12px;
    }

    .group-member-image,
    .group-member-image img {
        width: 48px;
        height: 48px;
    }

    .group-request-actions {
        gap: 6px;
    }

    .approve-request-button,
    .reject-request-button {
        padding: 7px 10px;
    }
}


/* =========================================
   MOBILE
   ========================================= */

@media (max-width: 576px) {

    .group-content-header {
        display: block;
        padding: 2px 2px 14px;
        margin-bottom: 14px;
    }

        .group-content-header h3 {
            font-size: 18px;
        }

        .group-content-header p {
            max-width: 100%;
            font-size: 13px;
        }

    .group-requests-list {
        gap: 10px;
    }

    .group-request-card {
        display: grid;
        grid-template-columns: 46px minmax(0, 1fr);
        gap: 10px 12px;
        padding: 12px;
        border-radius: 10px;
    }

    .group-member-image,
    .group-member-image img {
        width: 46px;
        height: 46px;
    }

    .group-request-info {
        align-self: center;
    }

        .group-request-info strong {
            font-size: 14px;
        }

        .group-request-info span {
            font-size: 12px;
        }

    .group-request-actions {
        grid-column: 1 / -1;
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px;
        width: 100%;
        padding-top: 2px;
    }

    .approve-request-button,
    .reject-request-button {
        width: 100%;
        min-height: 38px;
        padding: 8px 10px;
        font-size: 13px;
    }

    .group-empty-content {
        min-height: 220px;
        padding: 30px 15px;
    }

        .group-empty-content > i {
            width: 58px;
            height: 58px;
            font-size: 25px;
        }
}


/* =========================================
   VERY SMALL MOBILE
   ========================================= */

@media (max-width: 380px) {

    .group-request-card {
        grid-template-columns: 42px minmax(0, 1fr);
        padding: 10px;
    }

    .group-member-image,
    .group-member-image img {
        width: 42px;
        height: 42px;
    }

    .approve-request-button,
    .reject-request-button {
        font-size: 12px;
    }

        .approve-request-button i,
        .reject-request-button i {
            font-size: 13px;
        }
}

.group-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    z-index: 9999;
}

.reject-request-modal {
    width: 100%;
    max-width: 520px;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25);
    overflow: hidden;
}

.group-modal-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 15px;
    padding: 20px;
    border-bottom: 1px solid #eee;
}

    .group-modal-header h3 {
        margin: 0;
        font-size: 20px;
    }

    .group-modal-header p {
        margin: 6px 0 0;
        color: #777;
        font-size: 14px;
    }

.group-modal-close {
    border: none;
    background: transparent;
    font-size: 18px;
    cursor: pointer;
}

.group-modal-body {
    padding: 20px;
}

.group-form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
}

.optional-text {
    font-weight: 400;
    color: #888;
    font-size: 13px;
}

.reject-request-modal textarea {
    width: 100%;
    resize: vertical;
    box-sizing: border-box;
}

.reject-reason-count {
    text-align: right;
    margin-top: 5px;
    font-size: 12px;
    color: #888;
}

.group-modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 16px 20px;
    border-top: 1px solid #eee;
}

.group-modal-cancel {
    padding: 9px 18px;
    border: 1px solid #ddd;
    background: #fff;
    border-radius: 8px;
    cursor: pointer;
}

.reject-request-confirm-button {
    padding: 9px 18px;
    border: none;
    background: #dc3545;
    color: white;
    border-radius: 8px;
    cursor: pointer;
}

    .reject-request-confirm-button:disabled,
    .group-modal-cancel:disabled {
        opacity: 0.6;
        cursor: not-allowed;
    }

/* Members tab css */
/* ================================
   GROUP MEMBERS
   ================================ */

.group-members-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 16px;
    margin-top: 20px;
}

.group-member-card {
    position: relative;
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 15px;
    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 14px;
    transition: all 0.2s ease;
}

    .group-member-card:hover {
        border-color: #d5d5d5;
        box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06);
    }

.group-member-image {
    width: 52px;
    height: 52px;
    min-width: 52px;
    border-radius: 50%;
    overflow: hidden;
    background: #f1f1f1;
}

    .group-member-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

.group-member-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
    flex: 1;
}

    .group-member-info strong {
        font-size: 15px;
        font-weight: 600;
        color: #222;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

.member-role-badge {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    margin-top: 5px;
    padding: 3px 9px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
}

    .member-role-badge.owner {
        background: #fff3cd;
        color: #856404;
    }

    .member-role-badge.admin {
        background: #e8f0ff;
        color: #3158a6;
    }

    .member-role-badge.member {
        background: #f1f3f5;
        color: #666;
    }

/* manage button css */
.member-role-actions {
    position: relative;
    align-self: flex-start;
}

.member-manage-button {
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: transparent;
    border-radius: 50%;
    color: #777;
    cursor: pointer;
    transition: all 0.2s ease;
}

    .member-manage-button:hover {
        background: #f1f1f1;
        color: #222;
    }

    .member-manage-button i {
        font-size: 18px;
    }
/* role menu css */
.member-role-menu {
    position: absolute;
    top: 40px;
    right: 0;
    z-index: 100;
    width: 180px;
    padding: 7px;
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

.member-role-menu-title {
    padding: 8px 10px 6px;
    font-size: 11px;
    font-weight: 600;
    color: #999;
    text-transform: uppercase;
}

.member-role-menu button {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 10px;
    border: none;
    background: transparent;
    border-radius: 8px;
    color: #333;
    font-size: 14px;
    text-align: left;
    cursor: pointer;
}

    .member-role-menu button:hover {
        background: #f5f5f5;
    }

    .member-role-menu button i {
        font-size: 16px;
    }
/* mobile css */
@media (max-width: 600px) {

    .group-members-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .group-member-card {
        padding: 13px;
    }

    .group-member-image {
        width: 46px;
        height: 46px;
        min-width: 46px;
    }

    .member-role-menu {
        right: 0;
    }
}

/* Group Post Css */
/* ================================
   Group New Post Button
   ================================ */

.group-new-post-button {
    /* display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    padding: 10px 18px;
    min-height: 42px;

    border: none;
    border-radius: 10px;

    background: #5b21d6;
    color: #ffffff;

    font-size: 14px;
    font-weight: 600;
    line-height: 1;

    cursor: pointer;
    text-decoration: none;

    transition:
        background-color 0.2s ease,
        transform 0.15s ease,
        box-shadow 0.2s ease; */

    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    height: 42px;
    padding: 0 16px;
    flex-shrink: 0;
    border: 1px solid #987cff;
    border-radius: 10px;
    background: #5b21d6;
    color: #ffffff;
    font-size: 13px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 7px;
    cursor: pointer;
    transition: .2s ease;
}

    .group-new-post-button:hover {
        background: #7047ff;
        color: #ffffff;
        transform: translateY(-1px);
        box-shadow: 0 4px 10px rgba(37, 99, 235, 0.25);
    }

    .group-new-post-button:active {
        transform: translateY(0);
        box-shadow: none;
    }

    .group-new-post-button:focus {
        outline: none;
        box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.2);
    }

    .group-new-post-button:disabled {
        opacity: 0.6;
        cursor: not-allowed;
        transform: none;
        box-shadow: none;
    }

    /* Icon inside the button */
    .group-new-post-button i,
    .group-new-post-button svg {
        font-size: 16px;
    }

/* Mobile */
@media (max-width: 576px) {
    .group-new-post-button {
        width: 100%;
        padding: 11px 16px;
        min-height: 44px;
        margin-top: 10px;
    }
}

.group-post-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(15, 23, 42, 0.55);
    backdrop-filter: blur(3px);
}

.group-post-modal {
    width: min(680px, 100%);
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.25);
}

Header.group-post-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 22px 24px 16px;
    border-bottom: 1px solid #eee;
}

.group-post-modal-header h3 {
    margin: 0;
    font-size: 22px;
    font-weight: 700;
    color: #172554;
}

.group-post-close-button {
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    border-radius: 50%;
    color: #555;
    cursor: pointer;
}

    .group-post-close-button:hover {
        background: #f3f4f6;
    }
/* Header */
.group-post-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 22px 24px 16px;
    border-bottom: 1px solid #eee;
}

    .group-post-modal-header h3 {
        margin: 0;
        font-size: 22px;
        font-weight: 700;
        color: #172554;
    }

.group-post-close-button {
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    border-radius: 50%;
    color: #555;
    cursor: pointer;
}

    .group-post-close-button:hover {
        background: #f3f4f6;
    }
/* Private information box */
.group-post-private-info {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 18px 24px;
    padding: 14px;
    background: #f5f0ff;
    border-radius: 12px;
}

.group-post-private-icon {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: #eee5ff;
    color: #6331e6;
}

.group-post-private-info strong {
    display: block;
    font-size: 14px;
    color: #222;
}

.group-post-private-info p {
    margin: 3px 0 0;
    font-size: 12px;
    color: #777;
}

.group-post-private-badge {
    margin-left: auto;
    padding: 6px 10px;
    border-radius: 20px;
    background: #e8f8ed;
    color: #278a4a;
    font-size: 12px;
    font-weight: 600;
}

/* upload box */
.group-post-upload {
    position: relative;
    margin: 0 24px 16px;
    min-height: 150px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    border: 1.5px dashed #b99cff;
    border-radius: 14px;
    background: #fcfaff;
    color: #555;
    text-align: center;
    cursor: pointer;
}

    .group-post-upload > i {
        font-size: 38px;
        color: #6831e8;
    }

    .group-post-upload strong {
        font-size: 15px;
        color: #333;
    }

    .group-post-upload span {
        font-size: 13px;
        color: #777;
    }

    .group-post-upload small {
        font-size: 11px;
        color: #999;
    }

    .group-post-upload input[type="file"] {
        position: absolute;
        inset: 0;
        width: 100%;
        height: 100%;
        opacity: 0;
        cursor: pointer;
    }
/* description */
.group-post-description {
    position: relative;
    margin: 0 24px 14px;
}

    .group-post-description textarea {
        min-height: 90px;
        resize: vertical;
        padding: 14px;
        border: 1px solid #ddd;
        border-radius: 12px;
        font-size: 14px;
    }

        .group-post-description textarea:focus {
            border-color: #7436ed;
            box-shadow: 0 0 0 3px rgba(116, 54, 237, 0.08);
        }
        .group-post-description input:focus {
            border-color: #7436ed;
            box-shadow: 0 0 0 3px rgba(116, 54, 237, 0.08);
        }

.group-post-character-count {
    position: absolute;
    right: 12px;
    bottom: 8px;
    font-size: 11px;
    color: #999;
}
/* Visibility and group target */
.group-post-visibility,
.group-post-target {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 24px 10px;
    padding: 12px 14px;
    border: 1px solid #e5e7eb;
    border-radius: 11px;
}

.group-post-visibility-icon,
.group-post-target-icon {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 9px;
    background: #f5f3ff;
    color: #6331e6;
}

.group-post-visibility strong,
.group-post-target strong {
    display: block;
    font-size: 13px;
}

.group-post-visibility span,
.group-post-target span {
    display: block;
    margin-top: 2px;
    font-size: 11px;
    color: #777;
}

.group-post-visibility > i {
    margin-left: auto;
    color: #777;
}

/* Footer */

.group-post-modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 18px 24px 22px;
}

.group-post-cancel-button,
.group-post-submit-button {
    min-height: 42px;
    padding: 0 18px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

.group-post-cancel-button {
    border: 1px solid #ddd;
    background: #fff;
    color: #555;
}

.group-post-submit-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: none;
    background: #6327e8;
    color: #fff;
}

    .group-post-submit-button:hover {
        background: #5420cc;
    }

    .group-post-submit-button:disabled,
    .group-post-cancel-button:disabled {
        opacity: .6;
        cursor: not-allowed;
    }
/* mobile */
@media (max-width: 600px) {

    .group-post-modal-overlay {
        align-items: flex-end;
        padding: 0;
    }

    .group-post-modal {
        width: 100%;
        max-height: 92vh;
        border-radius: 20px 20px 0 0;
    }

    .group-post-modal-header {
        padding: 18px;
    }

    .group-post-private-info,
    .group-post-upload,
    .group-post-description,
    .group-post-visibility,
    .group-post-target {
        margin-left: 18px;
        margin-right: 18px;
    }

    .group-post-private-badge {
        display: none;
    }

    .group-post-modal-footer {
        padding: 14px 18px 18px;
    }

    .group-post-cancel-button,
    .group-post-submit-button {
        flex: 1;
    }
}

