/* =================
   通用基础样式
   ================= */

/* 基础重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    height: 100%;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, "Microsoft YaHei", sans-serif;
    background: #f5f7fa;
    color: #333;
    min-height: 100%;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}

/* 容器 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* 通用按钮样式 */
.btn {
    display: inline-block;
    padding: 8px 16px;
    border-radius: 4px;
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
    border: none;
    font-size: 14px;
}

.btn-primary {
    background: #4E8EF7;
    color: white;
}

.btn-primary:hover {
    background: #3d7ae0;
    color: white;
    text-decoration: none;
}

/* 通用卡片样式 */
.card {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 12px rgba(0,0,0,.08);
    transition: all 0.3s;
}

.card:hover {
    box-shadow: 0 4px 20px rgba(0,0,0,.12);
    transform: translateY(-2px);
}

/* 通用标题样式 */
.section-title {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 3px solid #667eea;
    color: #333;
    display: inline-block;
}

.main-title {
    text-align: center;
    font-size: 32px;
    font-weight: bold;
    color: #333;
    margin: 50px 0 15px;
}

.subtitle {
    text-align: center;
    font-size: 16px;
    color: #666;
    margin-bottom: 40px;
}

/* 响应式辅助类 */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.d-flex { display: flex; }
.align-items-center { align-items: center; }
.justify-content-between { justify-content: space-between; }
.justify-content-center { justify-content: center; }

.mb-10 { margin-bottom: 10px; }
.mb-15 { margin-bottom: 15px; }
.mb-20 { margin-bottom: 20px; }
.mb-30 { margin-bottom: 30px; }

.mt-10 { margin-top: 10px; }
.mt-15 { margin-top: 15px; }
.mt-20 { margin-top: 20px; }
.mt-30 { margin-top: 30px; }

/* 返回顶部按钮 */
.back-to-top {
    position: fixed;
    right: 30px;
    bottom: 30px;
    width: 50px;
    height: 50px;
    background: #4E8EF7;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 2px 12px rgba(78,142,247,.4);
    transition: all 0.3s;
    opacity: 0;
    visibility: hidden;
    z-index: 999;
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background: #3d7ae0;
    transform: translateY(-5px);
    box-shadow: 0 4px 20px rgba(78,142,247,.5);
}

.back-to-top i {
    font-size: 24px;
    color: white;
    font-style: normal;
    line-height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}
