/* ===== 欧莱新材检测分析中心 - 全站样式 v2 ===== */
:root {
    --primary: #1a3a6b;
    --primary-dark: #0f2447;
    --primary-light: #2b5ea7;
    --accent: #c9a84c;
    --accent-light: #f5e6a3;
    --text: #2d3748;
    --text-light: #718096;
    --bg: #f0f4f8;
    --white: #fff;
    --border: #e2e8f0;
    --shadow: 0 2px 16px rgba(15,36,71,.06);
    --shadow-lg: 0 8px 32px rgba(15,36,71,.1);
    --radius: 8px;
    --font: 'PingFang SC','Microsoft YaHei','Helvetica Neue',Arial,sans-serif;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: var(--font); color: var(--text); background: var(--bg); line-height: 1.7; min-height: 100vh; }
a { text-decoration: none; color: inherit; transition: color .25s; }
ul { list-style: none; }
img { max-width: 100%; height: auto; display: block; }

/* ===== 统一页面容器 - 所有页面固定1200px ===== */
.page-wrap { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
body:not(.home-page) .page-wrap,
.page-wrap { padding-top: 36px; padding-bottom: 40px; }

/* ===== 顶部导航 ===== */
.site-header {
    background: var(--white);
    box-shadow: 0 1px 4px rgba(0,0,0,.08);
    position: sticky;
    top: 0;
    z-index: 1000;
}
.header-inner {
    max-width: 1200px; margin: 0 auto;
    display: flex; align-items: center; justify-content: space-between;
    padding: 0 20px; height: 72px;
}
.header-logo { height: 40px; width: auto; display: block; }

.header-nav { display: flex; align-items: center; gap: 4px; }
.header-nav > li { position: relative; }
.header-nav > li > a {
    display: block; padding: 10px 16px;
    font-size: 14px; font-weight: 500; color: var(--text);
    border-radius: 4px; transition: all .25s;
}
.header-nav > li > a:hover,
.header-nav > li > a.active { color: var(--primary); background: #f0f4f8; }
.header-nav > li > a .en { display: block; font-size: 10px; font-weight: 400; color: #999; letter-spacing: .5px; }

/* Dropdown 二级菜单 */
.header-nav > li.has-sub:hover .sub-menu { display: block; }
.sub-menu {
    display: none; position: absolute; top: 100%; left: 0;
    background: var(--white); border-radius: 6px;
    box-shadow: 0 8px 30px rgba(0,0,0,.12);
    padding: 8px 0; min-width: 180px; z-index: 100;
}
.sub-menu li a {
    display: block; padding: 8px 20px;
    font-size: 13px; color: var(--text);
    transition: all .2s;
}
.sub-menu li a:hover { background: #f0f4f8; color: var(--primary); }

/* ===== 移动端导航 ===== */
.nav-toggle { display: none; font-size: 22px; cursor: pointer; color: var(--primary); padding: 4px; margin-left: auto; }
.mobile-nav { display: none; }

/* ===== Hero Banner ===== */
.hero-section {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 50%, var(--primary-light) 100%);
    padding: 60px 20px;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.hero-section:before {
    content: ''; position: absolute; top: -50%; left: -50%;
    width: 200%; height: 200%;
    background: radial-gradient(circle at 30% 50%, rgba(201,168,76,.08) 0%, transparent 50%);
}
.hero-section .hero-content { position: relative; z-index: 1; max-width: 800px; margin: 0 auto; }
.hero-section .hero-badge {
    display: inline-block; background: rgba(255,255,255,.1);
    border: 1px solid rgba(255,255,255,.2);
    padding: 4px 16px; border-radius: 20px;
    font-size: 12px; color: var(--accent); margin-bottom: 16px;
}
.hero-section h1 { font-size: 36px; font-weight: 700; color: #fff; margin-bottom: 12px; letter-spacing: 2px; }
.hero-section p { font-size: 15px; color: rgba(255,255,255,.8); line-height: 1.8; margin-bottom: 24px; }
.hero-section .hero-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.hero-section .hero-actions .btn-hero {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 12px 28px; border-radius: 6px; font-size: 14px; font-weight: 500;
    transition: all .3s; cursor: pointer; border: none;
}
.hero-section .hero-actions .btn-primary-action {
    background: var(--accent); color: var(--primary-dark);
}
.hero-section .hero-actions .btn-primary-action:hover { background: #b89530; }
.hero-section .hero-actions .btn-outline-action {
    background: transparent; color: #fff; border: 1.5px solid rgba(255,255,255,.4);
}
.hero-section .hero-actions .btn-outline-action:hover { border-color: #fff; background: rgba(255,255,255,.08); }

/* ===== 栏目标题 ===== */
.section-header { text-align: center; margin-bottom: 36px; }
.section-header .section-line {
    width: 50px; height: 3px; background: var(--accent);
    margin: 0 auto 12px; border-radius: 2px;
}
.section-header h2 { font-size: 26px; font-weight: 700; color: var(--primary-dark); margin-bottom: 8px; }
.section-header p { font-size: 14px; color: var(--text-light); max-width: 600px; margin: 0 auto; }

/* ===== 栏目区块通用 ===== */
.section-block { padding: 60px 20px; }
.section-block.bg-white { background: var(--white); }
.section-block.bg-gray { background: var(--bg); }

/* ===== 服务卡片网格 ===== */
.card-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; max-width: 1200px; margin: 0 auto; }
.service-card {
    background: var(--white); border-radius: 8px; overflow: hidden;
    box-shadow: var(--shadow); transition: all .3s;
    border: 1px solid var(--border);
}
.service-card:hover { transform: translateY(-4px); box-shadow: 0 8px 30px rgba(0,0,0,.1); }
.service-card .card-img {
    height: 200px; background: var(--primary);
    display: flex; align-items: center; justify-content: center;
    font-size: 42px; color: rgba(255,255,255,.3);
}
.service-card .card-body { padding: 24px; }
.service-card .card-body h3 { font-size: 18px; font-weight: 600; color: var(--primary); margin-bottom: 8px; }
.service-card .card-body p { font-size: 13px; color: var(--text-light); line-height: 1.7; margin-bottom: 14px; }
.service-card .card-body .more-link {
    font-size: 13px; color: var(--primary); font-weight: 500;
    display: inline-flex; align-items: center; gap: 4px;
}
.service-card .card-body .more-link:hover { color: var(--accent); }

/* ===== 设备展示（小图网格） ===== */
.equip-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; max-width: 1200px; margin: 0 auto; }
.equip-item {
    background: var(--white); border-radius: 8px; padding: 20px;
    box-shadow: var(--shadow); text-align: center;
    border: 1px solid var(--border); transition: all .3s;
}
.equip-item:hover { border-color: var(--primary); transform: translateY(-2px); }
.equip-item .equip-icon { font-size: 32px; margin-bottom: 10px; opacity: .7; }
.equip-item h4 { font-size: 14px; font-weight: 600; color: var(--primary); margin-bottom: 4px; }
.equip-item p { font-size: 12px; color: var(--text-light); }

/* ===== 数据大字报 ===== */
.stats-bar { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; max-width: 1000px; margin: 0 auto; }
.stat-item { text-align: center; padding: 20px; }
.stat-item .num { font-size: 36px; font-weight: 700; color: var(--primary); }
.stat-item .num small { font-size: 16px; font-weight: 400; }
.stat-item .label { font-size: 13px; color: var(--text-light); margin-top: 4px; }

/* ===== 联系我们 CTA ===== */
.cta-section {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary));
    padding: 48px 20px; text-align: center; color: #fff;
}
.cta-section h2 { font-size: 24px; font-weight: 700; margin-bottom: 8px; }
.cta-section p { font-size: 14px; color: rgba(255,255,255,.8); margin-bottom: 20px; }
.cta-section .cta-contact { display: flex; justify-content: center; gap: 24px; flex-wrap: wrap; font-size: 14px; }
.cta-section .cta-contact span { display: inline-flex; align-items: center; gap: 6px; }

/* ===== Footer ===== */
.site-footer { background: var(--primary-dark); color: rgba(255,255,255,.7); padding: 40px 20px 0; }
.footer-inner { max-width: 1200px; margin: 0 auto; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 30px; padding-bottom: 30px; border-bottom: 1px solid rgba(255,255,255,.1); }
.footer-grid h4 { font-size: 14px; font-weight: 600; color: #fff; margin-bottom: 12px; }
.footer-grid p, .footer-grid li { font-size: 13px; line-height: 2; }
.footer-grid a:hover { color: var(--accent); }
.footer-grid .footer-brand .flogo { height: 32px; margin-bottom: 10px; }
.footer-grid .footer-brand p { font-size: 12px; color: rgba(255,255,255,.5); }
.footer-bottom { text-align: center; padding: 16px 0; font-size: 12px; color: rgba(255,255,255,.4); }

/* ===== 统一内页Banner（全站子页面统一风格） ===== */
.page-banner {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 50%, var(--primary-light) 100%);
    padding: 44px 24px;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.page-banner::before {
    content: ''; position: absolute; inset: 0;
    background: radial-gradient(ellipse at 20% 50%, rgba(201,168,76,.08) 0%, transparent 50%);
}
.page-banner .banner-content { position: relative; z-index: 1; max-width: 800px; margin: 0 auto; }
.page-banner h1 { font-size: 26px; font-weight: 700; color: #fff; margin-bottom: 8px; letter-spacing: 3px; }
.page-banner p { font-size: 14px; color: rgba(255,255,255,.75); line-height: 1.7; max-width: 600px; margin: 0 auto; }

/* ===== 委托单卡片（重写原有） ===== */
.inspection-card { max-width: 1200px; margin: -20px auto 30px; position: relative; z-index: 2; background: #fff; border-radius: 8px; box-shadow: 0 4px 24px rgba(0,0,0,.1); }
.inspection-card .form-title {
    text-align: center; font-size: 22px; font-weight: 700; letter-spacing: 6px;
    padding: 20px 0; border-bottom: 3px double var(--primary); margin-bottom: 20px; color: var(--primary-dark);
}
.inspection-card .form-body { padding: 20px 28px; }
.section-title {
    background: #f0f4f8; padding: 8px 14px; font-weight: 600;
    font-size: 14px; margin-bottom: 12px; border-radius: 4px; color: var(--primary);
    border-left: 3px solid var(--primary);
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-size: 13px; font-weight: 500; margin-bottom: 4px; color: var(--text); }
.form-group label .required { color: #d00; }
.form-control {
    width: 100%; padding: 9px 12px; border: 1.5px solid var(--border);
    border-radius: 4px; font-size: 14px; transition: border-color .2s; background: #fff;
}
.form-control:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(0,51,102,.08); }

.items-table { width: 100%; border-collapse: collapse; margin-bottom: 12px; }
.items-table th { background: var(--bg); padding: 8px 10px; border: 1px solid var(--border); font-size: 13px; text-align: center; font-weight: 600; }
.items-table td { padding: 4px 6px; border: 1px solid var(--border); }
.items-table td .form-control { border: none; padding: 6px 8px; font-size: 13px; }
.items-table td .form-control:focus { box-shadow: none; border: 1px solid var(--primary); }

.option-row { display: flex; align-items: center; gap: 20px; padding: 6px 0; flex-wrap: wrap; }
.option-row label { font-size: 14px; display: flex; align-items: center; gap: 6px; cursor: pointer; }

.terms-box { background: #f8fafc; border: 1px solid var(--border); border-radius: 6px; padding: 14px 16px; font-size: 13px; line-height: 1.8; color: var(--text); margin-bottom: 12px; }
.terms-box ol { padding-left: 20px; }
.terms-box ol li { margin-bottom: 4px; }

.form-footer-contact { text-align: center; padding: 16px 0 4px; font-size: 13px; color: var(--text-light); line-height: 2; }
.form-footer-contact span { display: inline-block; margin: 0 12px; }

/* ===== 查询页 ===== */
.tab-btn { padding: 10px 20px; border: none; background: transparent; font-size: 14px; cursor: pointer; color: var(--text-light); border-bottom: 2px solid transparent; margin-bottom: -2px; transition: all .2s; font-weight: 500; }
.tab-btn:hover { color: var(--primary); }
.tab-btn.active { color: var(--primary); border-bottom-color: var(--primary); }

/* ===== 卡片通用 ===== */
.card { background: var(--white); border-radius: 8px; box-shadow: var(--shadow); padding: 24px; margin-bottom: 20px; border: 1px solid var(--border); }
.card-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; padding-bottom: 12px; border-bottom: 2px solid var(--bg); }
.card-header h2 { font-size: 18px; font-weight: 600; color: var(--primary-dark); }

.data-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.data-table th { background: var(--bg); padding: 10px 12px; text-align: left; font-weight: 600; color: var(--text); border-bottom: 2px solid var(--border); white-space: nowrap; }
.data-table td { padding: 10px 12px; border-bottom: 1px solid #e5e7eb; vertical-align: middle; }

.badge { display: inline-block; padding: 3px 10px; border-radius: 12px; font-size: 12px; font-weight: 500; }
.badge-pending { background: #fef3cd; color: #856404; }
.badge-accepted { background: #cce5ff; color: #004085; }
.badge-testing { background: #d4edda; color: #155724; }
.badge-completed { background: #d1ecf1; color: #0c5460; }
.badge-cancelled { background: #f8d7da; color: #721c24; }

.pagination { display: flex; justify-content: center; gap: 6px; margin-top: 20px; flex-wrap: wrap; }
.pagination a, .pagination span {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 36px; height: 36px; padding: 0 10px; border-radius: 6px;
    font-size: 14px; text-decoration: none; border: 1px solid var(--border); color: var(--text); transition: all .2s;
}
.pagination a:hover { border-color: var(--primary); color: var(--primary); }
.pagination .active { background: var(--primary); color: #fff; border-color: var(--primary); }

.detail-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px 20px; }
.detail-grid .item { display: flex; font-size: 14px; }
.detail-grid .item .label { color: #999; min-width: 90px; flex-shrink: 0; }
.detail-grid .item .value { color: var(--text); font-weight: 500; }
.detail-section { margin-bottom: 20px; }
.detail-section h3 { font-size: 15px; font-weight: 600; color: var(--primary); margin-bottom: 10px; padding-bottom: 6px; border-bottom: 2px solid var(--bg); }

.btn {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 9px 20px; border-radius: 6px; border: none;
    font-size: 14px; font-weight: 500; cursor: pointer;
    text-decoration: none; transition: all .2s; white-space: nowrap;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-outline { background: transparent; color: var(--primary); border: 1.5px solid var(--primary); }
.btn-outline:hover { background: var(--primary); color: #fff; }
.btn-sm { padding: 5px 12px; font-size: 13px; }
.btn-success { background: #28a745; color: #fff; border: none; }
.btn-success:hover { background: #218838; }

/* ===== 打印 ===== */
@media print {
    .site-header, .site-footer, .btn, .tab-btn, .no-print, .page-banner, .search-form, .hero-section, .section-block, .cta-section { display: none !important; }
    .card { box-shadow: none; border: 1px solid #ddd; page-break-inside: avoid; }
    body { background: #fff; }
}

/* ===== 响应式 ===== */
@media (max-width: 900px) {
    .card-grid, .equip-grid { grid-template-columns: 1fr 1fr; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .stats-bar { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
    .header-inner { height: 56px; }
    .header-logo { height: 30px; }
    .header-nav { display: none; }
    .nav-toggle { display: block; }
    .mobile-nav { display: none; position: absolute; top: 56px; left: 0; right: 0; background: var(--white); box-shadow: 0 4px 16px rgba(0,0,0,.1); z-index: 999; padding: 12px 0; }
    .mobile-nav.show { display: block; }
    .mobile-nav a { display: block; padding: 12px 20px; font-size: 14px; color: var(--text); border-bottom: 1px solid var(--border); }
    .mobile-nav a:last-child { border: none; }
    .mobile-nav a:hover, .mobile-nav a.active { background: #f0f4f8; color: var(--primary); }

    .hero-section { padding: 36px 16px; }
    .hero-section h1 { font-size: 24px; }
    .hero-section p { font-size: 13px; }
    .card-grid, .equip-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; text-align: center; }
    .stats-bar { grid-template-columns: 1fr 1fr; gap: 10px; }
    .stat-item .num { font-size: 28px; }
    .form-row { grid-template-columns: 1fr; }
    .inspection-card .form-body { padding: 12px 14px; }
    .inspection-card .form-title { font-size: 18px; }

    .detail-grid { grid-template-columns: 1fr; }
    .section-block { padding: 36px 12px; }
    .section-header h2 { font-size: 20px; }
    .cta-section .cta-contact { flex-direction: column; gap: 6px; }

    .items-table, .items-table thead, .items-table tbody, .items-table tr, .items-table th, .items-table td { display: block; }
    .items-table thead { display: none; }
    .items-table tbody tr { background: var(--bg); border-radius: 8px; padding: 10px; margin-bottom: 10px; position: relative; border: 1px solid var(--border); }
    .items-table td { border: none !important; padding: 4px 0 !important; display: flex; align-items: center; gap: 6px; }
    .items-table td:before { content: attr(data-label); font-weight: 600; color: #999; min-width: 60px; font-size: 12px; flex-shrink: 0; }
    .items-table td:first-child { position: absolute; top: 6px; right: 36px; background: var(--primary); color: #fff; width: 22px; height: 22px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; padding: 0 !important; }
    .items-table td:first-child:before { display: none; }
    .items-table td:last-child { position: absolute; top: 4px; right: 4px; padding: 0 !important; border: none !important; }
    .items-table td .form-control { flex: 1; min-width: 0; font-size: 13px; padding: 6px 8px; }
    .form-footer-contact span { display: block; margin: 2px 0; }
}
@media (max-width: 480px) {
    .stats-bar { grid-template-columns: 1fr 1fr; }
    .hero-section .hero-actions { flex-direction: column; align-items: stretch; }
    .hero-section .hero-actions .btn-hero { justify-content: center; }
}