/* ======================================
   小组页面 - 简洁轻便设计
   矩形卡片头部，Banner 背景填充
   ====================================== */

/* 覆盖 Bootstrap container，与系统头部保持一致 */
.group-show-page .container {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 0 20px;
}

/* 头部卡片 */
.group-header-card {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    margin: 2rem 0;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}

.group-card-bg {
    position: absolute;
    inset: 0;
    z-index: 1;
}

.group-card-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.group-card-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0.5) 50%, rgba(0,0,0,0.6) 100%);
    z-index: 2;
}

.group-card-content {
    position: relative;
    z-index: 3;
    padding: 2.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
    min-height: 240px;
}

.group-card-info {
    display: flex;
    gap: 1.5rem;
    flex: 1;
    min-width: 0;
    align-items: flex-start;
    align-self: flex-start;
}

.group-avatar {
    width: 90px;
    height: 90px;
    border-radius: 16px;
    border: 3px solid rgba(255,255,255,0.3);
    box-shadow: 0 4px 16px rgba(0,0,0,0.3);
    flex-shrink: 0;
    object-fit: cover;
}

.group-details {
    flex: 1;
    min-width: 0;
}

.group-details h1 {
    margin: 0 0 0.75rem;
    font-size: 2rem;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.group-details p {
    margin: 0 0 1rem;
    color: rgba(255,255,255,0.95);
    line-height: 1.6;
    font-size: 1rem;
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

.group-meta {
    display: flex;
    gap: 1.5rem;
    font-size: 0.9rem;
    color: rgba(255,255,255,0.9);
    flex-wrap: wrap;
}

.group-meta span {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.group-meta span::before {
    content: '•';
    color: rgba(255,255,255,0.5);
}

.group-meta span:first-child::before {
    content: '';
}

.group-card-actions {
    display: flex;
    flex-direction: row;
    gap: 0.75rem;
    flex-shrink: 0;
    flex-wrap: wrap;
    align-items: center;
    margin-left: auto;
}

.btn-action {
    padding: 0.625rem 1.5rem;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    border: 2px solid;
    transition: all 0.2s;
    white-space: nowrap;
    text-align: center;
    min-width: 120px;
    display: inline-block;
}

.btn-primary {
    background: rgba(255,255,255,0.95);
    border-color: rgba(255,255,255,0.95);
    color: var(--main-color, #008b8b);
}

.btn-primary:hover {
    background: #fff;
    border-color: #fff;
    color: var(--main-color, #008b8b);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.btn-secondary {
    background: transparent;
    border-color: rgba(255,255,255,0.6);
    color: #fff;
}

.btn-secondary:hover {
    background: rgba(255,255,255,0.1);
    border-color: rgba(255,255,255,0.9);
    color: #fff;
}

.btn-danger {
    background: transparent;
    border-color: rgba(220,53,69,0.8);
    color: rgba(255,255,255,0.95);
}

.btn-danger:hover {
    background: #dc3545;
    border-color: #dc3545;
    color: #fff;
}

/* 主内容区布局 */
.group-layout {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 2rem;
    margin-bottom: 2rem;
}

/* 话题列表 */
.topic-list {
    min-width: 0;
}

.topic-filters {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid #f0f0f0;
}

.filter-link {
    padding: 0.5rem 1rem;
    border-radius: 6px;
    text-decoration: none;
    color: #666;
    font-weight: 500;
    font-size: 0.875rem;
    transition: all 0.2s;
}

.filter-link:hover {
    color: var(--main-color, #008b8b);
    background: rgba(0, 139, 139, 0.05);
}

.filter-link.active {
    color: #fff;
    background: var(--main-color, #008b8b);
}

.topic-items {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.topic-item {
    display: flex;
    gap: 1rem;
    padding: 1.25rem;
    background: #fff;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    transition: all 0.2s;
}

.topic-item:hover {
    border-color: #ddd;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.topic-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    flex-shrink: 0;
}

.topic-content {
    flex: 1;
    min-width: 0;
}

.topic-content h2 {
    margin: 0 0 0.5rem;
    font-size: 1.125rem;
    font-weight: 600;
    line-height: 1.4;
}

.topic-content h2 a {
    color: #1a1a1a;
    text-decoration: none;
}

.topic-content h2 a:hover {
    color: var(--main-color, #008b8b);
}

.topic-meta {
    margin: 0;
    font-size: 0.8125rem;
    color: #888;
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.topic-meta span::before {
    content: '• ';
    color: #ddd;
    margin-right: 0.25rem;
}

.topic-meta span:first-child {
    font-weight: 500;
    color: #666;
}

.topic-meta span:first-child::before {
    content: '';
    margin: 0;
}

.empty-tip {
    text-align: center;
    padding: 3rem 1rem;
    color: #999;
}

.pagination-wrap {
    margin-top: 1.5rem;
}

/* 侧边栏 */
.group-sidebar {
    min-width: 0;
}

.sidebar-card {
    background: #fff;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    overflow: hidden;
}

.sidebar-card h3 {
    margin: 0;
    padding: 1rem 1.25rem;
    font-size: 1rem;
    font-weight: 600;
    background: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
}

.member-list {
    display: flex;
    flex-direction: column;
}

.member-item {
    display: flex;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.2s;
}

.member-item:last-child {
    border-bottom: none;
}

.member-item:hover {
    background: #f8f9fa;
}

.member-item img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    flex-shrink: 0;
}

.member-info {
    flex: 1;
    min-width: 0;
}

.member-info a {
    display: block;
    font-weight: 500;
    color: #1a1a1a;
    text-decoration: none;
    margin-bottom: 0.25rem;
}

.member-info a:hover {
    color: var(--main-color, #008b8b);
}

.member-info p {
    margin: 0;
    font-size: 0.8125rem;
    color: #888;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* 响应式设计 */
@media (max-width: 992px) {
    .group-layout {
        grid-template-columns: 1fr;
    }
    
    .group-sidebar {
        order: -1;
    }
    
    .sidebar-card {
        max-width: 500px;
        margin: 0 auto;
    }
    
    .group-show-page .container {
        padding: 0 16px;
    }
}

@media (max-width: 768px) {
    .group-show-page .container {
        padding: 0 16px;
    }
    
    .group-header-card {
        margin: 1.5rem 0;
    }
    
    .group-card-content {
        padding: 2rem 1.5rem;
        flex-direction: column;
        align-items: stretch;
        min-height: auto;
    }
    
    .group-card-info {
        flex-direction: column;
        align-items: center;
        text-align: center;
        width: 100%;
    }
    
    .group-avatar {
        width: 80px;
        height: 80px;
    }
    
    .group-details h1 {
        font-size: 1.5rem;
    }
    
    .group-meta {
        justify-content: center;
        font-size: 0.85rem;
    }
    
    .group-card-actions {
        width: 100%;
        margin-left: 0;
        justify-content: center;
    }
    
    .btn-action {
        flex: 0 1 auto;
        min-width: 100px;
    }
    
    .topic-item {
        padding: 1rem;
    }
    
    .topic-avatar {
        width: 36px;
        height: 36px;
    }
    
    .topic-content h2 {
        font-size: 1rem;
    }
    
    .filter-link {
        padding: 0.375rem 0.75rem;
        font-size: 0.8125rem;
    }
}

@media (max-width: 576px) {
    .group-show-page .container {
        padding: 0 12px;
    }
    
    .group-header-card {
        margin: 1rem 0;
        border-radius: 8px;
    }
    
    .group-card-content {
        padding: 1.5rem 1rem;
    }
    
    .group-avatar {
        width: 70px;
        height: 70px;
    }
    
    .group-details h1 {
        font-size: 1.375rem;
    }
    
    .group-details p {
        font-size: 0.9rem;
    }
    
    .group-meta {
        flex-direction: column;
        gap: 0.5rem;
        font-size: 0.8rem;
    }
    
    .group-card-actions {
        width: 100%;
        margin-left: 0;
        justify-content: center;
    }
    
    .btn-action {
        flex: 0 1 auto;
        min-width: 90px;
        font-size: 0.8125rem;
        padding: 0.5rem 1rem;
    }
}

