/* 全局样式 */
:root {
    --primary-color: #4285f4;
    --secondary-color: #34a853;
    --accent-color: #ea4335;
    --text-color: #333333;
    --light-bg: #f8f9fa;
    --card-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    --transition-speed: 0.3s;
}

body {
    font-family: 'Helvetica Neue', Arial, sans-serif;
    color: var(--text-color);
    line-height: 1.6;
}

/* 主题元素样式 */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color var(--transition-speed);
}

a:hover {
    color: #1a73e8;
}

.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover, .btn-primary:focus {
    background-color: #1a73e8;
    border-color: #1a73e8;
}

.btn-outline-primary {
    color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-outline-primary:hover, .btn-outline-primary:focus {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

/* 导航栏样式 */
.navbar {
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    padding: 1rem 0;
}

.navbar-brand {
    font-weight: 600;
    color: var(--primary-color);
}

.nav-link {
    font-weight: 500;
    padding: 0.5rem 1rem;
    transition: color var(--transition-speed);
}

.nav-link:hover {
    color: var(--primary-color);
}

/* 卡片样式 */
.card {
    border: none;
    border-radius: 10px;
    box-shadow: var(--card-shadow);
    transition: transform var(--transition-speed);
}

.card:hover {
    transform: translateY(-5px);
}

.feature-card {
    transition: transform var(--transition-speed), box-shadow var(--transition-speed);
    border-radius: 8px;
}

.feature-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--card-shadow);
}

.icon-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 60px;
    width: 60px;
    border-radius: 50%;
    background-color: rgba(66, 133, 244, 0.1);
}

/* 页脚样式 */
footer {
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}

/* 表单样式 */
.form-control {
    padding: 0.75rem 1rem;
    border-radius: 8px;
    border: 1px solid #dee2e6;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(66, 133, 244, 0.25);
}

label {
    font-weight: 500;
    margin-bottom: 0.5rem;
}

/* 练习模块特定样式 */
.practice-form {
    background-color: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--card-shadow);
}

.feedback-card {
    border-left: 4px solid var(--primary-color);
    padding: 1rem;
    background-color: rgba(66, 133, 244, 0.05);
    margin-bottom: 1rem;
    border-radius: 0 8px 8px 0;
}

.score-display {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 80px;
    width: 80px;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: white;
    font-size: 1.5rem;
    font-weight: bold;
    margin: 0 auto 1rem;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .display-4 {
        font-size: 2.5rem;
    }
    
    .container {
        padding-left: 1.5rem;
        padding-right: 1.5rem;
    }
    
    .btn-lg {
        padding: 0.5rem 1rem;
        font-size: 1rem;
    }
}

/* 动画效果 */
.fade-in {
    animation: fadeIn 0.5s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 卡片展示页面样式 */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
}

.case-card {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.case-card .card-body {
    flex: 1;
}

.case-tag {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-right: 0.5rem;
    margin-bottom: 0.5rem;
}

.tag-authority {
    background-color: rgba(66, 133, 244, 0.1);
    color: var(--primary-color);
}

.tag-equal {
    background-color: rgba(52, 168, 83, 0.1);
    color: var(--secondary-color);
}

.tag-mixed {
    background-color: rgba(234, 67, 53, 0.1);
    color: var(--accent-color);
}

/* 历史记录页面样式 */
.history-item {
    border-left: 4px solid #ddd;
    padding-left: 1rem;
    margin-bottom: 1.5rem;
    position: relative;
}

.history-item:before {
    content: '';
    position: absolute;
    left: -0.5rem;
    top: 0;
    height: 1rem;
    width: 1rem;
    border-radius: 50%;
    background-color: var(--primary-color);
}

.history-date {
    font-size: 0.875rem;
    color: #6c757d;
    margin-bottom: 0.5rem;
}

.history-score {
    font-weight: bold;
    color: var(--primary-color);
}

/* 热力图样式 */
.heatmap-container {
    margin: 2rem 0;
    padding: 1rem;
    background-color: white;
    border-radius: 8px;
    box-shadow: var(--card-shadow);
}

.heatmap-cell {
    width: 15px;
    height: 15px;
    margin: 2px;
    border-radius: 2px;
    display: inline-block;
}

/* 登录和注册页面样式 */
.auth-container {
    max-width: 500px;
    margin: 3rem auto;
    padding: 2rem;
    background-color: white;
    border-radius: 12px;
    box-shadow: var(--card-shadow);
}

.auth-title {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-form {
    margin-bottom: 1.5rem;
}

.auth-link {
    display: block;
    text-align: center;
    margin-top: 1rem;
}

/* 案例卡片页面样式 */
.filter-btn {
    transition: all 0.3s ease;
    font-weight: 500;
}

.filter-btn:hover {
    transform: translateY(-2px);
}

.filter-btn.active {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    font-weight: 600;
}

.cards-container {
    min-height: 300px;
}

.card-item {
    transition: all 0.3s ease;
}

.card-item:hover {
    transform: translateY(-5px);
}

.card-item .card-title {
    font-size: 1.1rem;
    font-weight: 600;
    min-height: 2.5rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

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

/* 案例详情模态框样式 */
.modal-content {
    border-radius: 12px;
    border: none;
    overflow: hidden;
}

.modal-header.bg-danger,
.modal-header.bg-success,
.modal-header.bg-warning,
.modal-header.bg-primary {
    color: white;
}

.case-context {
    background-color: rgba(0, 0, 0, 0.03);
    border-left: 4px solid #dee2e6;
}

/* 角色徽章样式 */
.badge.bg-danger, 
.badge.bg-success, 
.badge.bg-warning, 
.badge.bg-primary {
    font-weight: 500;
    padding: 0.5em 0.8em;
    border-radius: 50px;
}

/* 返回顶部按钮 */
#backToTop {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0.8;
    transition: all 0.3s ease;
}

#backToTop:hover {
    opacity: 1;
    transform: translateY(-3px);
}

/* NVC文本样式 */
.text-primary.fw-bold, 
.text-danger.fw-bold, 
.text-success.fw-bold, 
.text-warning.fw-bold {
    padding: 0px 3px;
    display: inline-block;
    border-radius: 3px;
}

.text-primary.fw-bold {
    background-color: rgba(66, 133, 244, 0.1);
}

.text-danger.fw-bold {
    background-color: rgba(234, 67, 53, 0.1);
}

.text-success.fw-bold {
    background-color: rgba(52, 168, 83, 0.1);
}

.text-warning.fw-bold {
    background-color: rgba(251, 188, 5, 0.1);
}

/* 没有结果提示样式 */
#noResultsMessage {
    opacity: 0.8;
    padding: 2rem;
}

/* 搜索框样式 */
#searchInput {
    border-radius: 0;
    height: 45px;
}

#searchButton {
    height: 45px;
    min-width: 100px;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .filter-btn {
        font-size: 0.85rem;
        padding: 0.375rem 0.5rem;
    }
    
    .card-item .card-title {
        min-height: 3rem;
    }
} 