/* 公共样式 - Common Styles */

/* 颜色变量 */
:root {
    --primary-color: #FF7F24;
    --primary-hover: #E67018;
    --secondary-color: #0078D4;
    --secondary-dark: #005a9e;
    --bg-light: #F5F5F5;
    --bg-white: #FFFFFF;
    --accent-yellow: #FACC15;
    --text-main: #333333;
    --text-gray: #666666;
    --text-light: #999999;
    --border-color: #E5E5E5;
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    --shadow-hover: 0 8px 24px rgba(0, 0, 0, 0.15);
}

/* 容器 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 顶部TOP栏 */
.top-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: #c5def1;
    color: #0a406a;
    padding: 10px 0;
    font-size: 14px;
    border-bottom: 3px solid #1057d1;
}

.top-bar .container {
    display: flex;
    justify-content: flex-start;
    align-items: center;
}

.top-bar .top-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.top-bar .top-left span {
    font-weight: 500;
}

.top-bar .contact-tel {
    display: flex;
    align-items: center;
    gap: 10px;
}

.top-bar .contact-tel a {
    color: #fff;
    font-weight: bold;
}

.top-bar .contact-tel a:hover {
    color: #00e5ff;
}

/* 头部 */
.header {
    background: #FFFFFF;
    padding: 20px 0;
    position: sticky;
    top: 42px;
    z-index: 999;
    box-shadow: var(--shadow);
}

.header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-icon {
    width: 48px;
    height: 48px;
    display: block;
    object-fit: contain;
}

.logo-text {
    font-size: 24px;
    font-weight: bold;
    color: #fab30a;
}

.logo-text span {
    color: #fab30a;
}

/* 导航 */
.nav ul {
    display: flex;
    gap: 15px;
}

.nav > ul > li {
    position: relative;
}

.nav a {
    color: var(--text-main);
    font-size: 16px;
    padding: 8px 15px;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.nav a:hover,
.nav a.active {
    background-color: #003c6b;
    color: #fff;
}

/* 下拉菜单 */
.dropdown .subnav {
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--bg-white);
    min-width: 180px;
    box-shadow: var(--shadow);
    border-radius: 4px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
}

.dropdown:hover .subnav {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown .subnav li a {
    color: var(--text-main);
    display: block;
    padding: 12px 20px;
    border-radius: 0;
}

.dropdown .subnav li a:hover {
    background: #003c6b;
    color: #fff;
}

/* 联系方式 */
.contact-info {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    color: var(--text-main);
    font-size: 14px;
}

.contact-info span {
    white-space: nowrap;
}

.contact-info a {
    color: var(--primary-color);
    font-weight: bold;
    margin-left: 5px;
}

.contact-info a:hover {
    text-decoration: underline;
}

/* 页面标题区域 */
.page-banner {
    background: linear-gradient(135deg, var(--secondary-color), var(--secondary-dark));
    padding: 60px 0;
    text-align: center;
    color: #fff;
}

.page-banner h1 {
    font-size: 36px;
    margin-bottom: 15px;
}

.page-banner p {
    font-size: 18px;
    opacity: 0.9;
}

/* 主内容区 */
.main {
    min-height: 500px;
    padding: 40px 0;
}

/* 底部 */
.footer {
    background: linear-gradient(135deg, #003c6b, #00284f);
    color: #fff;
    padding: 40px 0 20px;
}

.footer .copyright {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    font-size: 14px;
    opacity: 0.8;
}

/* 按钮样式 */
.btn {
    display: inline-block;
    padding: 12px 30px;
    background: var(--primary-color);
    color: #fff;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    border: none;
    transition: all 0.3s ease;
}

.btn:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.btn-secondary {
    background: var(--secondary-color);
}

.btn-secondary:hover {
    background: var(--secondary-dark);
}

/* 卡片通用样式 */
.card {
    background: var(--bg-white);
    border-radius: 8px;
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: all 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.card-img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background: linear-gradient(135deg, #f0f0f0, #e0e0e0);
}

.card-body {
    padding: 20px;
}

.card-title {
    font-size: 18px;
    color: var(--text-main);
    margin-bottom: 10px;
}

.card-text {
    color: var(--text-gray);
    font-size: 14px;
    line-height: 1.8;
}

/* 区块标题 */
.section-title {
    text-align: center;
    margin-bottom: 40px;
}

.section-title h2 {
    font-size: 32px;
    color: #003c6b;
    margin-bottom: 15px;
    position: relative;
    display: inline-block;
}

.section-title h2::after {
    content: "";
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: var(--primary-color);
    border-radius: 2px;
}

.section-title p {
    color: var(--text-gray);
    font-size: 16px;
}

/* 客服悬浮窗 */
.floating-contact {
    position: fixed;
    right: 20px;
    bottom: 100px;
    z-index: 999;
}

.floating-contact .contact-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
}

.floating-contact .contact-btn:hover {
    background: var(--primary-hover);
    transform: scale(1.1);
}

.floating-contact .contact-list {
    position: absolute;
    right: 60px;
    bottom: 0;
    background: var(--bg-white);
    border-radius: 8px;
    box-shadow: var(--shadow);
    padding: 15px;
    width: 180px;
    opacity: 0;
    visibility: hidden;
    transform: translateX(10px);
    transition: all 0.3s ease;
}

.floating-contact:hover .contact-list {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
}

.floating-contact .contact-list p {
    font-size: 14px;
    color: var(--text-main);
    margin: 8px 0;
}

.floating-contact .contact-list a {
    color: var(--primary-color);
    font-weight: bold;
}

/* 响应式 */
@media (max-width: 768px) {
    .header .container {
        flex-direction: column;
        gap: 15px;
    }
    
    .nav ul {
        flex-wrap: wrap;
        justify-content: center;
        gap: 10px;
    }
    
    .contact-info {
        flex-wrap: wrap;
        justify-content: center;
        text-align: center;
    }
    
    .page-banner {
        padding: 40px 0;
    }
    
    .page-banner h1 {
        font-size: 28px;
    }
    
    .section-title h2 {
        font-size: 24px;
    }
    
    .floating-contact {
        right: 10px;
        bottom: 20px;
    }
}
