* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 头部导航 */
header {
    background: #1a56db;
    color: white;
    padding: 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

header .container {
    max-width: 1400px;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
}

.logo {
    font-size: 24px;
    font-weight: bold;
    color: white;
    letter-spacing: 1px;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 35px;
    align-items: center;
    margin: 0;
    padding: 0;
}

nav ul li a {
    color: white;
    text-decoration: none;
    transition: all 0.3s;
    font-size: 15px;
    font-weight: 500;
    position: relative;
    padding: 5px 0;
}

nav ul li a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: white;
    transition: width 0.3s;
}

nav ul li a:hover,
nav ul li a.active {
    opacity: 0.9;
}

nav ul li a:hover::after {
    width: 100%;
}

/* 主要内容区域 */
main {
    min-height: calc(100vh - 200px);
    padding: 0;
    background: #ffffff;
}

/* 左侧固定客服侧边栏 */
.left-sidebar-fixed {
    position: fixed;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    background: #1a56db;
    color: white;
    padding: 20px 8px;
    border-radius: 0 8px 8px 0;
    z-index: 999;
    cursor: pointer;
    box-shadow: 2px 0 10px rgba(0,0,0,0.1);
    transition: all 0.3s;
}

.left-sidebar-fixed:hover {
    background: #1e40af;
    padding-left: 12px;
}

.sidebar-content {
    writing-mode: vertical-rl;
    text-orientation: mixed;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    font-weight: 500;
}

.sidebar-icon {
    font-size: 20px;
    margin-bottom: 10px;
}

.sidebar-triangle {
    width: 0;
    height: 0;
    border-left: 8px solid #1a56db;
    border-top: 6px solid transparent;
    border-bottom: 6px solid transparent;
    position: absolute;
    right: -8px;
    bottom: 20px;
}

/* 三栏布局 */
.main-content-wrapper {
    background: #f5f5f5;
    padding: 30px 0;
}

.three-column-layout {
    display: grid;
    grid-template-columns: 250px 1fr 280px;
    gap: 20px;
    align-items: start;
}

/* 左侧栏样式 */
.left-sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.sidebar-box {
    background: white;
    padding: 20px;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.sidebar-title {
    font-size: 18px;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #1a56db;
}

/* 搜索表单 */
.search-form {
    margin-bottom: 20px;
}

.search-input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    margin-bottom: 10px;
    box-sizing: border-box;
}

.search-btn {
    width: 100%;
    padding: 10px;
    background: #1a56db;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: background 0.3s;
}

.search-btn:hover {
    background: #1e40af;
}

/* 分类列表 */
.category-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.category-list li {
    margin-bottom: 8px;
}

.category-list li a {
    color: #475569;
    text-decoration: none;
    font-size: 14px;
    display: block;
    padding: 8px 10px;
    border-radius: 4px;
    transition: all 0.3s;
}

.category-list li a:hover {
    background: #f1f5f9;
    color: #1a56db;
    padding-left: 15px;
}

/* 联系方式 */
.contact-info {
    font-size: 13px;
    line-height: 1.8;
    color: #475569;
}

.contact-info p {
    margin-bottom: 12px;
    word-break: break-word;
}

.contact-info strong {
    color: #1e293b;
    display: inline-block;
    min-width: 60px;
}

/* 中间内容区域 */
.main-content {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.content-box {
    background: white;
    padding: 25px;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.content-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #e2e8f0;
}

.content-title {
    font-size: 20px;
    font-weight: 600;
    color: #1e293b;
    margin: 0;
}

.more-link {
    color: #1a56db;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color 0.3s;
}

.more-link:hover {
    color: #1e40af;
}

/* 新闻列表简化样式 */
.news-list-simple {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.news-item-simple {
    padding: 12px 0;
    border-bottom: 1px solid #f1f5f9;
}

.news-item-simple:last-child {
    border-bottom: none;
}

.news-item-simple a {
    color: #475569;
    text-decoration: none;
    font-size: 14px;
    display: block;
    transition: all 0.3s;
    padding-left: 20px;
    position: relative;
}

.news-item-simple a::before {
    content: '•';
    position: absolute;
    left: 0;
    color: #1a56db;
}

.news-item-simple a:hover {
    color: #1a56db;
    padding-left: 25px;
}

/* 产品网格内联样式 */
.products-grid-inline {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
}

.product-item-inline {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    overflow: hidden;
    transition: all 0.3s;
}

.product-item-inline:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    border-color: #1a56db;
}

.product-image-wrapper {
    width: 100%;
    height: 150px;
    background: white;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-caption {
    padding: 10px;
    font-size: 13px;
    color: #475569;
    text-align: center;
    background: white;
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 右侧栏 */
.right-sidebar {
    display: flex;
    flex-direction: column;
}

.about-content {
    font-size: 14px;
    line-height: 1.7;
    color: #475569;
}

/* 首页轮播图区域 */
.hero {
    position: relative;
    background: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 50%, #60a5fa 100%);
    color: white;
    padding: 80px 0;
    text-align: center;
    overflow: hidden;
    margin-bottom: 0;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="100" height="100" patternUnits="userSpaceOnUse"><path d="M 100 0 L 0 0 0 100" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.5;
}

.hero .container {
    position: relative;
    z-index: 1;
}

.hero h1 {
    font-size: 42px;
    margin-bottom: 15px;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
    letter-spacing: 1px;
    line-height: 1.3;
}

.hero p {
    font-size: 18px;
    margin-bottom: 0;
    opacity: 0.95;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

/* 公司优势区域 */
.advantages-section {
    background: #f8fafc;
    padding: 80px 0;
    margin-top: 0;
}

.advantages-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 40px;
    margin-top: 50px;
}

.advantage-item {
    text-align: center;
    padding: 40px 20px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    transition: transform 0.3s, box-shadow 0.3s;
}

.advantage-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 30px rgba(0,0,0,0.12);
}

.advantage-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 25px;
    background: linear-gradient(135deg, #1a56db, #3b82f6);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    color: white;
    box-shadow: 0 4px 15px rgba(26, 86, 219, 0.3);
}

.advantage-item h3 {
    font-size: 22px;
    color: #1e293b;
    margin-bottom: 15px;
    font-weight: 600;
}

.advantage-item p {
    color: #64748b;
    line-height: 1.7;
    font-size: 15px;
}

.btn {
    display: inline-block;
    padding: 14px 35px;
    background: #1a56db;
    color: white;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.3s;
    font-weight: 500;
    font-size: 16px;
    box-shadow: 0 4px 15px rgba(26, 86, 219, 0.3);
    border: none;
    cursor: pointer;
}

.btn:hover {
    background: #1e40af;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(26, 86, 219, 0.4);
}

.btn-secondary {
    background: white;
    color: #1a56db;
    border: 2px solid #1a56db;
    box-shadow: none;
}

.btn-secondary:hover {
    background: #1a56db;
    color: white;
}

/* 产品展示 */
.products-section {
    padding: 80px 0;
    background: white;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 35px;
    margin-top: 50px;
}

.product-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    transition: all 0.3s;
    border: 1px solid #f0f0f0;
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 30px rgba(0,0,0,0.15);
}

.product-card .image-wrapper {
    position: relative;
    overflow: hidden;
    height: 250px;
    background: #f8fafc;
}

.product-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.product-card:hover img {
    transform: scale(1.1);
}

.product-card .info {
    padding: 25px;
}

.product-card h3 {
    margin-bottom: 12px;
    color: #1e293b;
    font-size: 20px;
    font-weight: 600;
    line-height: 1.4;
}

.product-card p {
    color: #64748b;
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 15px;
    min-height: 42px;
}

.product-card .price {
    color: #1a56db;
    font-size: 24px;
    font-weight: bold;
    margin-top: 15px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.product-card .price::before {
    content: '$';
    font-size: 18px;
}

/* 新闻列表 */
.news-section {
    padding: 80px 0;
    background: #f8fafc;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.news-item {
    background: white;
    padding: 0;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    overflow: hidden;
    transition: all 0.3s;
    border: 1px solid #f0f0f0;
}

.news-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(0,0,0,0.12);
}

.news-item .news-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background: #e2e8f0;
}

.news-item .news-content {
    padding: 25px;
}

.news-item h3 {
    color: #1e293b;
    margin-bottom: 12px;
    font-size: 20px;
    font-weight: 600;
    line-height: 1.4;
}

.news-item .date {
    color: #94a3b8;
    font-size: 14px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.news-item .date::before {
    content: '📅';
    font-size: 14px;
}

.news-item p {
    color: #64748b;
    line-height: 1.7;
    margin-bottom: 20px;
    font-size: 15px;
}

/* 联系表单 */
.contact-form {
    max-width: 600px;
    margin: 40px auto;
    background: white;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    color: #2c3e50;
    font-weight: bold;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
}

.form-group textarea {
    height: 150px;
    resize: vertical;
}

/* 页脚 */
footer {
    background: #1e293b;
    color: #cbd5e1;
    padding: 50px 0 30px;
    margin-top: 0;
}

footer .container {
    max-width: 1400px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 30px;
}

.footer-section h4 {
    color: white;
    font-size: 18px;
    margin-bottom: 20px;
    font-weight: 600;
}

.footer-section p,
.footer-section a {
    color: #94a3b8;
    text-decoration: none;
    line-height: 1.8;
    font-size: 14px;
    transition: color 0.3s;
}

.footer-section a:hover {
    color: #60a5fa;
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid #334155;
    color: #94a3b8;
    font-size: 14px;
}

/* 页面标题 */
.page-title {
    text-align: center;
    margin-bottom: 20px;
    color: #1e293b;
    font-size: 42px;
    font-weight: 700;
    position: relative;
    padding-bottom: 20px;
}

.page-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, #1a56db, #3b82f6);
    border-radius: 2px;
}

.section-subtitle {
    text-align: center;
    color: #64748b;
    font-size: 18px;
    margin-bottom: 50px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* 新闻图片样式 */
.news-item .news-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background: linear-gradient(135deg, #e2e8f0, #cbd5e1);
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }
    
    .news-grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    }
}

@media (max-width: 1024px) {
    .three-column-layout {
        grid-template-columns: 220px 1fr 240px;
        gap: 15px;
    }
    
    .products-grid-inline {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .left-sidebar-fixed {
        display: none;
    }
    
    .hero {
        padding: 60px 0;
    }
    
    .hero h1 {
        font-size: 32px;
    }
    
    .hero p {
        font-size: 16px;
        padding: 0 20px;
    }
    
    nav {
        flex-direction: column;
        gap: 15px;
        padding: 15px 0;
    }
    
    nav ul {
        gap: 10px;
        flex-wrap: wrap;
        justify-content: center;
        font-size: 14px;
    }
    
    .logo {
        font-size: 22px;
    }
    
    .three-column-layout {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .left-sidebar,
    .right-sidebar {
        order: 2;
    }
    
    .main-content {
        order: 1;
    }
    
    .products-grid-inline {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .products-grid,
    .news-grid,
    .advantages-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .page-title {
        font-size: 28px;
        padding: 0 20px;
    }
    
    .section-subtitle {
        padding: 0 20px;
        font-size: 16px;
    }
    
    .advantages-section,
    .products-section,
    .news-section {
        padding: 40px 0;
    }
    
    .advantage-item {
        padding: 25px 15px;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 25px;
        text-align: center;
    }
    
    .btn-secondary {
        margin-left: 0 !important;
        margin-top: 10px;
        display: inline-block;
    }
    
    .sidebar-box {
        padding: 15px;
    }
    
    .content-box {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .hero {
        padding: 50px 0;
    }
    
    .hero h1 {
        font-size: 24px;
    }
    
    .hero p {
        font-size: 14px;
    }
    
    .page-title {
        font-size: 24px;
    }
    
    .advantage-icon {
        width: 60px;
        height: 60px;
        font-size: 28px;
    }
    
    .products-grid-inline {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
    
    .product-image-wrapper {
        height: 120px;
    }
    
    .product-caption {
        font-size: 12px;
        padding: 8px 5px;
    }
    
    .main-content-wrapper {
        padding: 20px 0;
    }
    
    .content-box {
        padding: 15px;
    }
}

/* 后台管理样式 */
.admin-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

.admin-header {
    background: #34495e;
    color: white;
    padding: 20px;
    border-radius: 5px;
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.admin-table th,
.admin-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

.admin-table th {
    background: #34495e;
    color: white;
}

.admin-table tr:hover {
    background: #f5f5f5;
}

.btn-small {
    padding: 6px 12px;
    font-size: 14px;
    margin-right: 5px;
}

.btn-danger {
    background: #e74c3c;
}

.btn-danger:hover {
    background: #c0392b;
}

.btn-success {
    background: #27ae60;
}

.btn-success:hover {
    background: #229954;
}

.form-container {
    max-width: 600px;
    margin: 20px auto;
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.alert {
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 5px;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}
