/* 
 * 上海育佳信息科技有限公司门户网站
 * 主样式表
 */

/* 重置样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f9f9f9;
}

/* 全局h1样式 */
h1 {
    color: #fff !important;
}

a {
    text-decoration: none;
    color: var(--primary-color);
}

a:hover {
    color: var(--primary-light);
}

ul, ol {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* 头部样式 */
header {
    background-color: #fff;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    height: 50px;
    margin-right: 10px;
}

:root {
    --primary-color: #133953;    /* 公司主色调 */
    --primary-light: #1e5580;    /* 主色调的亮色版本，用于悬停效果 */
    --primary-dark: #0b2230;     /* 主色调的暗色版本 */
}

.logo h1 {
    font-size: 1.5rem;
    color: var(--primary-color) !important; /* 使用公司主色调 */
    margin: 0;
}

/* 导航样式 */
nav ul {
    display: flex;
}

nav ul li {
    margin-left: 20px;
}

nav ul li a {
    color: #333;
    font-weight: 500;
    padding: 5px 10px;
    transition: all 0.3s ease;
}

nav ul li a:hover, 
nav ul li a.active {
    color: var(--primary-color);
    border-bottom: 2px solid var(--primary-color);
}

.mobile-menu-btn {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* 主内容区域 */
main {
    margin-top: 80px;
    min-height: calc(100vh - 80px - 100px); /* 减去header和footer的高度 */
    padding: 30px 0;
}

/* 页面标题 */
.page-title {
    text-align: center;
    margin-bottom: 40px;
}

.page-title h2 {
    font-size: 2rem;
    color: var(--primary-color);
    position: relative;
    display: inline-block;
    padding-bottom: 10px;
}

.page-title h2:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background-color: var(--primary-color);
}

/* 首页轮播图 */
.banner {
    position: relative;
    height: 500px;
    overflow: hidden;
    margin-bottom: 40px;
}

.banner-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-align: center;
    opacity: 0; /* 默认隐藏所有幻灯片 */
}

.banner-content {
    background-color: rgba(0, 0, 0, 0.5);
    padding: 20px;
    border-radius: 5px;
    max-width: 600px;
}

.banner-content h2 {
    font-size: 2.5rem;
    margin-bottom: 15px;
    color: var(--white) !important; /* 强制使用白色，覆盖theme.css中的设置 */
}

.banner-content p {
    font-size: 1.2rem;
    margin-bottom: 20px;
    color: var(--white); /* 使用白色 */
}

.banner-content .btn {
    color: var(--white); /* 确保按钮文字也是白色 */
}

/* About Banner样式 */
.about-banner {
    position: relative;
    height: 300px;
    overflow: hidden;
    margin-bottom: 40px;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background-color: rgba(0, 0, 0, 0.5);
}

.about-banner h1 {
    color: #fff !important; /* 直接使用白色 */
    font-size: 2.5rem;
    padding: 20px 40px;
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 5px;
}

.btn {
    display: inline-block;
    padding: 10px 20px;
    background-color: var(--primary-color);
    color: #fff;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.btn:hover {
    background-color: var(--primary-light);
    color: #fff;
}

/* 公司简介部分 */
.about-section {
    background-color: #fff;
    padding: 40px 0;
    margin-bottom: 40px;
}

.about-content {
    display: flex;
    align-items: center;
    gap: 30px;
}

.about-text {
    flex: 1;
}

.about-image {
    flex: 1;
}

/* 产品展示部分 */
.products-section {
    padding: 40px 0;
    margin-bottom: 40px;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
}

.product-card {
    background-color: #fff;
    border-radius: 5px;
    overflow: hidden;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.product-image {
    height: 200px;
    background-size: cover;
    background-position: center;
}

.product-info {
    padding: 20px;
}

.product-info h3 {
    margin-bottom: 10px;
    color: var(--primary-color);
}

/* 案例展示部分 */
.cases-section {
    background-color: #f0f5ff;
    padding: 40px 0;
    margin-bottom: 40px;
}

.case-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

.case-card {
    background-color: #fff;
    border-radius: 5px;
    overflow: hidden;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
}

.case-image {
    height: 200px;
    background-size: cover;
    background-position: center;
}

.case-info {
    padding: 20px;
}

.case-info h3 {
    margin-bottom: 10px;
    color: var(--primary-color);
}

/* 联系我们部分 */
.contact-section {
    padding: 40px 0;
}

.contact-container {
    display: flex;
    gap: 30px;
}

.contact-info {
    flex: 1;
}

.contact-info h3 {
    margin-bottom: 20px;
    color: var(--primary-color);
}

.contact-info p {
    margin-bottom: 10px;
}

.contact-form {
    flex: 1;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
}

.form-group textarea {
    height: 150px;
}

/* 页脚样式 */
footer {
    background-color: #333;
    color: #fff;
    padding: 30px 0;
}

.footer-container {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
}

.footer-section {
    flex: 1;
    min-width: 200px;
    margin-bottom: 20px;
}

.footer-section h3 {
    margin-bottom: 15px;
    position: relative;
    padding-bottom: 10px;
    color: #fff; /* 页脚标题使用白色，以便在深色背景上清晰可见 */
}

.footer-section h3:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 2px;
    background-color: #fff; /* 页脚标题下划线使用白色，以便在深色背景上清晰可见 */
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section ul li a {
    color: #ccc;
}

.footer-section ul li a:hover {
    color: #fff;
}

.copyright {
    text-align: center;
    padding-top: 20px;
    margin-top: 20px;
    border-top: 1px solid #fffbfb;
}