/* 全局样式 */
:root {
    --primary-color: #0d6efd;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --light-color: #f8f9fa;
    --dark-color: #212529;
    --gray-color: #6c757d;
    --gray-light: #e9ecef;
    --border-radius: 12px;
    --box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Segoe UI', 'Microsoft YaHei', sans-serif;
    line-height: 1.7;
    color: var(--dark-color);
    background-color: var(--light-color);
    font-size: 16px;
}

/* 导航栏样式 */
.navbar {
    background-color: var(--primary-color) !important;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    padding: 0.8rem 0;
    transition: var(--transition);
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 700;
    color: #fff !important;
    letter-spacing: 0.5px;
}

.navbar-nav .nav-link {
    color: rgba(255, 255, 255, 0.9) !important;
    font-weight: 500;
    padding: 0.8rem 1.2rem !important;
    margin: 0 0.2rem;
    border-radius: 8px;
    transition: var(--transition);
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    color: #fff !important;
    background-color: rgba(255, 255, 255, 0.15);
}

/* 轮播图样式 */
.carousel {
    margin-bottom: 3rem;
}

.carousel-item {
    height: 500px;
    overflow: hidden;
    position: relative;
}

.carousel-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(rgba(0, 0, 0, 0.3), rgba(0, 0, 0, 0.5));
    z-index: 1;
}

.carousel-item img {
    object-fit: cover;
    height: 100%;
    width: 100%;
    transition: var(--transition);
}

.carousel-item:hover img {
    transform: scale(1.02);
}

.carousel-caption {
    z-index: 2;
    bottom: 30%;
    text-align: center;
}

.carousel-caption h5 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    animation: fadeInUp 0.8s ease-out;
}

.carousel-caption p {
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    animation: fadeInUp 1s ease-out 0.2s both;
}

/* 卡片样式 */
.card {
    background-color: #fff;
    border: none;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    overflow: hidden;
    height: 100%;
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.12);
}

.card-body {
    padding: 1.5rem;
}

.card-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.8rem;
    color: var(--dark-color);
    transition: var(--transition);
}

.card:hover .card-title {
    color: var(--primary-color);
}

.card-text {
    color: var(--gray-color);
    line-height: 1.6;
}

/* 按钮样式 */
.btn {
    padding: 0.6rem 1.5rem;
    font-weight: 500;
    border-radius: 8px;
    transition: var(--transition);
    border: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

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

.btn-primary:hover {
    background-color: #0b5ed7;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(13, 110, 253, 0.4);
}

.btn-outline-primary {
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    background-color: transparent;
}

.btn-outline-primary:hover {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

/* 页脚样式 */
footer {
    background-color: var(--dark-color);
    color: rgba(255, 255, 255, 0.8);
    padding: 3rem 0 1.5rem;
    margin-top: 4rem;
}

footer h5 {
    color: #fff;
    font-weight: 600;
    margin-bottom: 1.2rem;
    font-size: 1.1rem;
}

footer p,
footer li {
    font-size: 0.95rem;
    line-height: 1.8;
}

footer a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: var(--transition);
}

footer a:hover {
    color: #fff;
    margin-left: 3px;
}

footer ul {
    list-style: none;
    padding: 0;
}

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

footer .social-icons a {
    display: inline-block;
    width: 40px;
    height: 40px;
    line-height: 40px;
    text-align: center;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    margin-right: 0.8rem;
    font-size: 1.1rem;
    transition: var(--transition);
}

footer .social-icons a:hover {
    background-color: var(--primary-color);
    transform: translateY(-3px);
    margin-left: 0;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 1.5rem;
    margin-top: 2rem;
    text-align: center;
    font-size: 0.9rem;
}

/* 表单样式 */
form {
    background-color: #fff;
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

form:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.form-label {
    font-weight: 500;
    color: var(--dark-color);
    margin-bottom: 0.5rem;
}

.form-control {
    border: 2px solid var(--gray-light);
    border-radius: 8px;
    padding: 0.8rem 1rem;
    font-size: 1rem;
    transition: var(--transition);
    background-color: #fff;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.1);
    outline: none;
}

.form-select {
    border: 2px solid var(--gray-light);
    border-radius: 8px;
    padding: 0.8rem 1rem;
    font-size: 1rem;
    transition: var(--transition);
}

.form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.1);
    outline: none;
}

/* 标题样式 */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    color: var(--dark-color);
    line-height: 1.3;
}

h2 {
    color: var(--primary-color);
    margin-bottom: 2rem;
    font-size: 2rem;
    text-align: center;
    position: relative;
    padding-bottom: 1rem;
}

h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
}

/* 列表样式 */
ul {
    padding-left: 0;
}

li {
    margin-bottom: 0.8rem;
}

/* 容器样式 */
.container {
    max-width: 1200px;
}

/* 区块样式 */
section {
    padding: 4rem 0;
}

/* 背景区块 */
.bg-light {
    background-color: #f8fafc !important;
}

.bg-primary {
    background-color: var(--primary-color) !important;
}

/* 文本样式 */
.text-primary {
    color: var(--primary-color) !important;
}

.text-muted {
    color: var(--gray-color) !important;
}

/* 卡片网格 */
.row {
    margin-bottom: 2rem;
}

.col-md-4,
.col-md-6 {
    margin-bottom: 2rem;
}

/* 动画效果 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #0b5ed7;
}

/* 响应式调整 */
@media (max-width: 992px) {
    .navbar-nav .nav-link {
        padding: 0.6rem 1rem !important;
    }
    
    .carousel-caption h5 {
        font-size: 2rem;
    }
    
    .carousel-caption p {
        font-size: 1rem;
    }
}

@media (max-width: 768px) {
    .carousel-item {
        height: 350px;
    }
    
    .carousel-caption {
        bottom: 20%;
    }
    
    .carousel-caption h5 {
        font-size: 1.5rem;
    }
    
    .carousel-caption p {
        font-size: 0.9rem;
        display: none;
    }
    
    h2 {
        font-size: 1.8rem;
    }
    
    section {
        padding: 2.5rem 0;
    }
    
    .card-body {
        padding: 1.25rem;
    }
    
    form {
        padding: 1.5rem;
    }
}

@media (max-width: 576px) {
    .navbar-brand {
        font-size: 1.25rem;
    }
    
    .carousel-item {
        height: 280px;
    }
    
    .carousel-caption {
        bottom: 15%;
    }
    
    .carousel-caption h5 {
        font-size: 1.25rem;
    }
    
    h2 {
        font-size: 1.5rem;
    }
    
    .btn {
        padding: 0.5rem 1.2rem;
        font-size: 0.9rem;
    }
    
    section {
        padding: 2rem 0;
    }
}