/* 全局样式 */
body {
    font-family: 'Noto Sans SC', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: #333;
    background-color: #f8f9fa;
}

.navbar-logo {
    height: 28px;
}

/* 导航样式 */
.navbar-brand {
    display: flex;
    align-items: center;
    gap: 0.2rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.navbar-dark .navbar-nav .nav-link {
    color: rgba(255, 255, 255, 0.8);
    font-weight: 500;
    padding: 0.5rem 1rem;
    transition: color 0.2s ease;
}

.navbar-dark .navbar-nav .nav-link:hover {
    color: #fff;
}

.navbar-dark .navbar-nav .nav-link.active {
    color: #fff;
    border-bottom: 2px solid #fff;
}

/* Banner 样式 */
.banner-container {
    width: 100%;
    overflow: hidden;
    margin-bottom: 2rem;
}

.banner-slide {
    width: 100%;
}

.carousel-caption {
    background-color: rgba(0, 0, 0, 0.6);
    border-radius: 1rem;
    padding: 1rem;
}

/* 卡片样式 */
.card {
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    border: 1px solid rgba(0, 0, 0, 0.08);
    overflow: hidden;
    margin-bottom: 1.5rem;
    border-radius: 0.5rem;
}

.card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.card-header {
    border-bottom: none;
    font-weight: 600;
    padding: 1rem 1.25rem;
}

.card-body {
    padding: 1.25rem;
}

.card-footer {
    background-color: transparent;
    padding: 1rem 1.25rem;
}

/* 群组卡片样式 */
.group-card {
    height: 100%;
}

.group-card .card-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.group-card .group-description {
    height: 3rem;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    color: #6c757d;
}

.group-meta {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.75rem;
    font-size: 0.875rem;
    color: #6c757d;
}

/* 标签样式 */
.badge {
    font-weight: 500;
    padding: 0.35rem 0.65rem;
    border-radius: 0.25rem;
}

.badge.bg-info {
    background-color: #17a2b8 !important;
}

.badge.bg-success {
    background-color: #28a745 !important;
}

/* 按钮样式 */
.btn {
    font-weight: 500;
    border-radius: 0.25rem;
    padding: 0.375rem 1rem;
    transition: all 0.2s ease;
}

.btn-primary {
    background-color: #0d6efd;
    border-color: #0d6efd;
}

.btn-primary:hover {
    background-color: #0b5ed7;
    border-color: #0a58ca;
}

.btn-outline-primary {
    color: #0d6efd;
    border-color: #0d6efd;
}

.btn-outline-primary:hover {
    background-color: #0d6efd;
    color: #fff;
}

/* 用户资料页面样式 */
.profile-header {
    padding: 2rem 0;
    background-color: #f1f5f9;
    margin-bottom: 2rem;
    border-radius: 0.5rem;
}

.profile-avatar {
    width: 120px;
    height: 120px;
    object-fit: cover;
    border-radius: 50%;
    border: 5px solid #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* 用户中心侧边栏 */
.user-sidebar {
    background-color: #fff;
    border-radius: 0.5rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.user-sidebar .nav-link {
    color: #495057;
    border-radius: 0;
    padding: 0.75rem 1.25rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.user-sidebar .nav-link:hover {
    background-color: #f8f9fa;
}

.user-sidebar .nav-link.active {
    color: #0d6efd;
    background-color: #e9f0ff;
    border-left: 3px solid #0d6efd;
}

/* 表单样式 */
.form-label {
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.form-control {
    border-radius: 0.25rem;
    padding: 0.5rem 0.75rem;
    border: 1px solid #ced4da;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-control:focus {
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

.form-select {
    border-radius: 0.25rem;
    padding: 0.5rem 2.25rem 0.5rem 0.75rem;
    border: 1px solid #ced4da;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-select:focus {
    border-color: #86b7fe;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

.form-check-input:checked {
    background-color: #0d6efd;
    border-color: #0d6efd;
}

/* 登录与注册页面 */
.auth-form {
    max-width: 400px;
    margin: 0 auto;
    padding: 2rem;
    background-color: #fff;
    border-radius: 0.5rem;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.auth-form .card-title {
    text-align: center;
    margin-bottom: 1.5rem;
    font-weight: 600;
}

.auth-form .btn-primary {
    width: 100%;
    padding: 0.75rem;
    margin-top: 1rem;
}

/* 页脚样式 */
footer {
    margin-top: 3rem;
    padding-top: 3rem;
    padding-bottom: 3rem;
    background-color: #343a40;
    color: #f8f9fa;
}

footer h5 {
    font-weight: 600;
    margin-bottom: 1.25rem;
}

footer ul li {
    margin-bottom: 0.5rem;
}

footer a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.2s ease;
}

footer a:hover {
    color: #fff;
    text-decoration: underline;
}

footer hr {
    border-color: rgba(255, 255, 255, 0.2);
    margin: 2rem 0;
}

/* 社交媒体图标样式 */
.social-icons {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 1.5rem;
}

.social-icon {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.1);
    color: #fff;
    font-size: 1.25rem;
    transition: all 0.3s ease;
    text-decoration: none;
}

.social-icon:hover {
    background-color: #fff;
    color: #212529;
    transform: translateY(-3px);
    text-decoration: none;
}

.social-icon i {
    line-height: 1;
}

/* 首页频道列表 */
.channel-list-item {
    display: flex;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid #e9ecef;
}

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

.channel-icon {
    width: 32px;
    height: 32px;
    margin-right: 0.75rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #e9ecef;
}

/* 搜索结果样式 */
.search-highlight {
    background-color: rgba(255, 247, 66, 0.3);
    padding: 0.1rem 0.2rem;
    border-radius: 0.2rem;
}

/* 响应式设计 */
@media (max-width: 991.98px) {
    .navbar-dark .navbar-nav .nav-link.active {
        border-bottom: none;
        background-color: rgba(255, 255, 255, 0.1);
    }
    
    .navbar-collapse {
        padding: 1rem 0;
    }
}

@media (max-width: 767.98px) {
    .banner-slide {
        height: 300px !important;
    }
    
    .display-4 {
        font-size: 2rem;
    }
    
    .lead {
        font-size: 1rem;
    }
    
    .profile-header {
        text-align: center;
    }
    
    .profile-avatar {
        width: 100px;
        height: 100px;
        margin-bottom: 1rem;
    }
    
    .user-sidebar {
        margin-bottom: 1.5rem;
    }
    
    .user-sidebar .nav {
        display: flex;
        flex-wrap: nowrap;
        overflow-x: auto;
    }
    
    .user-sidebar .nav-link {
        white-space: nowrap;
        padding: 0.5rem 1rem;
    }
    
    .user-sidebar .nav-link.active {
        border-left: none;
        border-bottom: 2px solid #0d6efd;
    }
}

/* 简化的表单验证样式 */
.form-control:focus {
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

/* 只在提交后显示验证状态 */
.was-validated .form-control:invalid {
    border-color: #dc3545;
}

.was-validated .form-control:valid {
    border-color: #198754;
}

/* 禁用浏览器默认验证气泡 */
input:invalid {
    box-shadow: none;
}

/* 简单的错误提示文本 */
.invalid-feedback {
    display: none;
    width: 100%;
    margin-top: 0.25rem;
    font-size: 0.875em;
    color: #dc3545;
}

.was-validated .form-control:invalid ~ .invalid-feedback,
.form-control.is-invalid ~ .invalid-feedback {
    display: block;
}

/* 修复input-group中的验证反馈样式 */
.input-group ~ .invalid-feedback {
    display: none;
}

.input-group.is-invalid ~ .invalid-feedback,
.was-validated .input-group:invalid ~ .invalid-feedback {
    display: block;
}

/* 修复input-group中表单控件的验证样式 */
.was-validated .input-group .form-control:invalid,
.input-group .form-control.is-invalid {
    z-index: 1;
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
    border-right: 0;
}

.was-validated .input-group .form-control:valid,
.input-group .form-control.is-valid {
    z-index: 1;
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
    border-right: 0;
}

/* 推广内容样式 */
.promoted-card {
    border: 2px solid #ffc107;
    box-shadow: 0 4px 8px rgba(255, 193, 7, 0.2);
    transition: all 0.3s ease;
}

.promoted-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(255, 193, 7, 0.3);
}

.promoted-card .card-title {
    color: #856404;
}

/* 推广标识动画 */
.badge.bg-warning {
    animation: pulse-warning 2s infinite;
}

@keyframes pulse-warning {
    0% {
        box-shadow: 0 0 0 0 rgba(255, 193, 7, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(255, 193, 7, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(255, 193, 7, 0);
    }
}

/* 推广群主页卡片样式 */
.border-warning {
    border-color: #ffc107 !important;
}

.bg-warning.bg-opacity-25 {
    background-color: rgba(255, 193, 7, 0.25) !important;
}

.bg-warning.bg-opacity-10 {
    background-color: rgba(255, 193, 7, 0.1) !important;
}

/* 推广内容提示样式 */
.promoted-content-notice {
    font-size: 0.75rem;
    color: #6c757d;
    font-style: italic;
}

/* 推广区域标题样式 */
.promoted-section-title {
    background: linear-gradient(45deg, #ffc107, #ffca2c);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: bold;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .promoted-card {
        margin-bottom: 1rem;
    }
    
    .promoted-card .card-body {
        padding: 1rem;
    }
    
    .promoted-card .card-footer {
        padding: 0.75rem 1rem;
    }
} 