/* =========================================================
 * novotechnik诺我（诺沃泰克）位移传感器静态展示页 - 样式
 * 纯CSS，无外部依赖，响应式设计 + H5 移动端适配
 * ========================================================= */

/* ---------- 基础重置 ---------- */
*,
*::before,
*::after {
    box-sizing: border-box;
}

/* ---------- H5 移动端适配增强 ---------- */
html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    -webkit-tap-highlight-color: rgba(185, 28, 28, 0.1);
    text-size-adjust: 100%;
}

body {
    margin: 0;
    padding: 0;
    padding-bottom: env(safe-area-inset-bottom);
    font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Helvetica, Arial,
        "Hiragino Sans GB", "Heiti SC", sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: #1f2937;
    background-color: #ffffff;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: #1e40af;
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover,
a:focus {
    color: #b91c1c;
    text-decoration: underline;
}

h1, h2, h3, h4 {
    margin: 0 0 0.5em;
    line-height: 1.3;
    color: #0f172a;
    font-weight: 700;
}

p {
    margin: 0 0 1em;
}

ul {
    padding-left: 1.5em;
}

button {
    font-family: inherit;
    cursor: pointer;
    /* 禁用 iOS WebKit 默认按钮样式 */
    -webkit-appearance: none;
    appearance: none;
}

/* 输入框禁用 iOS 默认外观与自动大写 */
input,
select,
textarea {
    -webkit-appearance: none;
    appearance: none;
    border-radius: 0;
}

/* ---------- 通用容器 ---------- */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
}

/* ---------- 按钮 ---------- */
.btn {
    display: inline-block;
    padding: 12px 26px;
    border-radius: 4px;
    font-weight: 600;
    font-size: 15px;
    text-align: center;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.2s ease;
    text-decoration: none;
    line-height: 1.2;
    /* H5 触摸友好：最小可点击区域 */
    min-height: 44px;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
    -webkit-user-select: none;
}

.btn:hover,
.btn:focus {
    text-decoration: none;
}

.btn-primary {
    background-color: #b91c1c;
    color: #ffffff;
    border-color: #b91c1c;
}

.btn-primary:hover,
.btn-primary:focus {
    background-color: #991b1b;
    border-color: #991b1b;
    color: #ffffff;
}

.btn-secondary {
    background-color: #ffffff;
    color: #1e40af;
    border-color: #1e40af;
}

.btn-secondary:hover,
.btn-secondary:focus {
    background-color: #1e40af;
    color: #ffffff;
    text-decoration: none;
}

.btn-sm {
    padding: 8px 18px;
    font-size: 14px;
}

/* ---------- 顶部条 ---------- */
.topbar {
    background-color: #0f172a;
    color: #e2e8f0;
    font-size: 13px;
    padding: 8px 0;
}

.topbar-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.topbar-text {
    color: #cbd5e1;
}

.topbar-link {
    color: #fbbf24;
    font-weight: 600;
}

.topbar-link:hover {
    color: #fde68a;
}

/* ---------- 站点头 ---------- */
.site-header {
    background-color: #ffffff;
    border-bottom: 1px solid #e5e7eb;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 14px;
    padding-bottom: 14px;
    gap: 20px;
}

.brand {
    display: flex;
    align-items: center;
    text-decoration: none;
    gap: 12px;
    line-height: 1.2;
}

.brand:hover {
    text-decoration: none;
}

.brand-logo {
    height: 50px;
    width: auto;
    max-width: 200px;
    object-fit: contain;
    display: block;
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.brand-cn {
    font-size: 18px;
    font-weight: 800;
    color: #0f172a;
    letter-spacing: 0.3px;
}

.brand-en {
    font-size: 11px;
    color: #b91c1c;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    margin-top: 4px;
}

.primary-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
}

.primary-nav a {
    display: block;
    padding: 10px 14px;
    color: #1f2937;
    font-weight: 500;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.primary-nav a:hover,
.primary-nav a:focus {
    color: #b91c1c;
    background-color: #fef2f2;
    text-decoration: none;
}

/* 移动端菜单按钮 */
.nav-toggle {
    display: none;
    background: transparent;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    width: 42px;
    height: 42px;
    padding: 0;
    position: relative;
}

.nav-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background-color: #0f172a;
    margin: 4px auto;
    transition: all 0.3s ease;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
    transform: translateY(6px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
    opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
    transform: translateY(-6px) rotate(-45deg);
}

/* ---------- Hero 首屏 ---------- */
.hero {
    background: linear-gradient(135deg, #1e3a8a 0%, #0f172a 100%);
    color: #ffffff;
    padding: 60px 0;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(circle at 20% 30%, rgba(185, 28, 28, 0.18) 0, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(30, 64, 175, 0.25) 0, transparent 50%);
    pointer-events: none;
}

.hero-inner {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 50px;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-text h1 {
    color: #ffffff;
    font-size: 38px;
    line-height: 1.25;
    margin-bottom: 18px;
}

.hero-subtitle {
    font-size: 16px;
    line-height: 1.75;
    color: #e2e8f0;
    margin-bottom: 28px;
}

.hero-subtitle strong {
    color: #fbbf24;
    font-weight: 700;
}

.hero-cta {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    margin-bottom: 28px;
}

.hero-cta .btn-secondary {
    background-color: transparent;
    color: #ffffff;
    border-color: #fbbf24;
}

.hero-cta .btn-secondary:hover,
.hero-cta .btn-secondary:focus {
    background-color: #fbbf24;
    color: #0f172a;
    border-color: #fbbf24;
}

.hero-points {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px 18px;
}

.hero-points li {
    position: relative;
    padding-left: 22px;
    font-size: 14px;
    color: #cbd5e1;
}

.hero-points li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #fbbf24;
    font-weight: 700;
}

.hero-image {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 18px;
    text-align: center;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
}

.hero-image img {
    border-radius: 8px;
    width: 100%;
    max-width: 480px;
    margin: 0 auto;
}

/* ---------- 关键词条带 ---------- */
.keyword-strip {
    background-color: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    padding: 20px 0;
}

.keyword-strip ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
}

.keyword-strip li {
    background-color: #ffffff;
    border: 1px solid #cbd5e1;
    color: #1e40af;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.2s ease;
}

.keyword-strip li:hover {
    background-color: #b91c1c;
    color: #ffffff;
    border-color: #b91c1c;
}

/* ---------- Section 通用 ---------- */
.section {
    padding: 70px 0;
}

.section-categories,
.section-applications {
    background-color: #f8fafc;
}

.section-products,
.section-advantages,
.section-download,
.section-faq,
.section-contact {
    background-color: #ffffff;
}

.section-title {
    font-size: 32px;
    text-align: center;
    color: #0f172a;
    margin-bottom: 12px;
    position: relative;
    padding-bottom: 16px;
}

.section-title::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background-color: #b91c1c;
    border-radius: 2px;
}

.section-subtitle {
    text-align: center;
    color: #64748b;
    font-size: 16px;
    margin-bottom: 50px;
}

/* ---------- 产品分类卡片 ---------- */
.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.category-card {
    background-color: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 26px 24px;
    transition: all 0.3s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.category-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
    border-color: #b91c1c;
}

.category-card h3 {
    font-size: 20px;
    color: #0f172a;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 2px solid #fbbf24;
    display: inline-block;
}

.category-card p {
    color: #475569;
    font-size: 14px;
    line-height: 1.7;
}

.category-models {
    background-color: #f1f5f9;
    color: #1e40af;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 13px !important;
    margin-top: 12px;
    word-break: break-word;
}

.card-link {
    display: inline-block;
    margin-top: 14px;
    color: #b91c1c;
    font-weight: 600;
    font-size: 14px;
}

.card-link:hover {
    color: #991b1b;
    text-decoration: underline;
}

/* ---------- 产品列表 ---------- */
.product-filter {
    text-align: center;
    margin-bottom: 30px;
}

.filter-label {
    display: block;
    font-weight: 600;
    color: #0f172a;
    margin-bottom: 10px;
    font-size: 15px;
}

#productSearch {
    width: 100%;
    max-width: 480px;
    padding: 12px 16px;
    border: 2px solid #cbd5e1;
    border-radius: 4px;
    font-size: 15px;
    transition: border-color 0.2s ease;
    font-family: inherit;
}

#productSearch:focus {
    outline: none;
    border-color: #b91c1c;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

.product-card {
    background-color: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1);
    border-color: #b91c1c;
}

.product-media {
    display: block;
    background-color: #f8fafc;
    padding: 18px;
    border-bottom: 1px solid #e2e8f0;
}

.product-media img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.product-card:hover .product-media img {
    transform: scale(1.05);
}

.product-body {
    padding: 18px 20px 22px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.product-body h3 {
    font-size: 17px;
    line-height: 1.4;
    color: #0f172a;
    margin-bottom: 8px;
}

.product-meta {
    font-size: 13px;
    color: #b91c1c;
    font-weight: 600;
    margin-bottom: 10px;
}

.product-desc {
    color: #475569;
    font-size: 14px;
    line-height: 1.65;
    flex: 1;
    margin-bottom: 14px;
}

.product-body .btn-sm {
    margin-right: 8px;
    margin-bottom: 6px;
}

.no-results {
    text-align: center;
    color: #94a3b8;
    font-size: 16px;
    padding: 30px 0;
}

/* ---------- 更多产品类型入口 ---------- */
.more-products {
    margin-top: 50px;
    padding: 40px 30px;
    text-align: center;
    background: linear-gradient(135deg, #fef2f2 0%, #ffffff 100%);
    border: 2px dashed #b91c1c;
    border-radius: 12px;
    position: relative;
}

.more-products::before {
    content: "⮕";
    position: absolute;
    top: -22px;
    left: 50%;
    transform: translateX(-50%);
    background-color: #b91c1c;
    color: #ffffff;
    width: 44px;
    height: 44px;
    line-height: 44px;
    border-radius: 50%;
    font-size: 20px;
    font-weight: 700;
    box-shadow: 0 4px 14px rgba(185, 28, 28, 0.25);
}

.more-products-title {
    font-size: 24px;
    color: #0f172a;
    margin-bottom: 12px;
    font-weight: 700;
}

.more-products-desc {
    color: #475569;
    font-size: 15px;
    line-height: 1.75;
    max-width: 720px;
    margin: 0 auto 24px;
}

.more-products .btn-lg {
    padding: 14px 32px;
    font-size: 16px;
    box-shadow: 0 4px 14px rgba(185, 28, 28, 0.25);
}

.more-products .btn-lg:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(185, 28, 28, 0.35);
}

.more-products-hint {
    margin-top: 14px;
    color: #64748b;
    font-size: 13px;
}

.more-products-hint strong {
    color: #b91c1c;
}

/* ---------- 品牌优势 ---------- */
.advantage-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
}

.advantage-item {
    background-color: #f8fafc;
    border-left: 4px solid #b91c1c;
    padding: 24px 22px;
    border-radius: 0 6px 6px 0;
    transition: all 0.3s ease;
}

.advantage-item:hover {
    background-color: #fef2f2;
    transform: translateX(4px);
}

.advantage-item h3 {
    color: #0f172a;
    font-size: 18px;
    margin-bottom: 10px;
}

.advantage-item p {
    color: #475569;
    font-size: 14px;
    line-height: 1.7;
    margin: 0;
}

.advantage-item strong {
    color: #1e40af;
}

/* ---------- 应用领域 ---------- */
.application-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 14px;
}

.application-list li {
    background-color: #ffffff;
    border: 1px solid #e2e8f0;
    padding: 14px 18px 14px 44px;
    border-radius: 6px;
    position: relative;
    color: #334155;
    font-size: 15px;
    transition: all 0.2s ease;
}

.application-list li::before {
    content: "▸";
    position: absolute;
    left: 18px;
    top: 14px;
    color: #b91c1c;
    font-weight: 700;
}

.application-list li:hover {
    background-color: #fef2f2;
    border-color: #b91c1c;
    color: #0f172a;
}

/* ---------- 资料下载 ---------- */
.download-list {
    list-style: none;
    margin: 0;
    padding: 0;
    max-width: 900px;
    margin: 0 auto;
}

.download-list li {
    border-bottom: 1px solid #e2e8f0;
}

.download-list a {
    display: block;
    padding: 16px 18px 16px 44px;
    color: #1e40af;
    font-size: 15px;
    position: relative;
    transition: all 0.2s ease;
}

.download-list a::before {
    content: "📄";
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 18px;
}

.download-list a::after {
    content: "下载 →";
    position: absolute;
    right: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: #b91c1c;
    font-weight: 600;
    font-size: 14px;
}

.download-list a:hover {
    background-color: #fef2f2;
    color: #991b1b;
    text-decoration: none;
}

/* ---------- FAQ ---------- */
.section-faq details {
    max-width: 900px;
    margin: 0 auto 14px;
    background-color: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 0;
    transition: all 0.2s ease;
}

.section-faq details[open] {
    background-color: #ffffff;
    border-color: #b91c1c;
    box-shadow: 0 4px 14px rgba(185, 28, 28, 0.08);
}

.section-faq summary {
    padding: 16px 20px;
    cursor: pointer;
    font-weight: 600;
    color: #0f172a;
    font-size: 15px;
    list-style: none;
    position: relative;
    padding-right: 50px;
}

.section-faq summary::-webkit-details-marker {
    display: none;
}

.section-faq summary::after {
    content: "+";
    position: absolute;
    right: 18px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 22px;
    color: #b91c1c;
    font-weight: 400;
    transition: transform 0.2s ease;
}

.section-faq details[open] summary::after {
    content: "−";
}

.section-faq details p {
    padding: 0 20px 18px;
    margin: 0;
    color: #475569;
    line-height: 1.75;
    font-size: 14px;
}

/* ---------- 联系我们信息卡片 ---------- */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    max-width: 1100px;
    margin: 0 auto 40px;
}

.contact-card {
    background-color: #ffffff;
    border: 1px solid #e2e8f0;
    border-left: 4px solid #b91c1c;
    border-radius: 8px;
    padding: 22px 24px;
    transition: all 0.3s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.contact-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
    border-color: #b91c1c;
}

.contact-card h3 {
    font-size: 16px;
    color: #b91c1c;
    margin: 0 0 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid #f1f5f9;
    font-weight: 700;
}

.contact-card p {
    margin: 6px 0;
    color: #1f2937;
    font-size: 15px;
    line-height: 1.7;
    word-break: break-all;
}

.contact-card a {
    color: #1e40af;
    font-weight: 600;
    text-decoration: none;
}

.contact-card a:hover {
    color: #b91c1c;
    text-decoration: underline;
}

.contact-card-wide {
    grid-column: span 3;
}

/* ---------- 联系表单 ---------- */
.contact-form {
    max-width: 600px;
    margin: 0 auto;
    background-color: #f8fafc;
    padding: 30px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.form-title {
    text-align: center;
    font-size: 20px;
    color: #0f172a;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid #fbbf24;
    display: inline-block;
    width: 100%;
}

.form-row {
    margin-bottom: 18px;
}

.form-row label {
    display: block;
    margin-bottom: 6px;
    font-weight: 600;
    color: #0f172a;
    font-size: 14px;
}

.form-row input,
.form-row select,
.form-row textarea {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    font-size: 15px;
    font-family: inherit;
    background-color: #ffffff;
    transition: border-color 0.2s ease;
    /* H5：iOS 输入框字体不低于 16px 避免页面自动缩放 */
    min-height: 44px;
}

.form-row select {
    /* 自定义下拉箭头（覆盖 iOS 默认） */
    background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%2364748b' d='M6 8L0 0h12z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    background-size: 12px 8px;
    padding-right: 40px;
}

.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
    outline: none;
    border-color: #b91c1c;
    box-shadow: 0 0 0 3px rgba(185, 28, 28, 0.1);
}

.form-row textarea {
    resize: vertical;
    min-height: 100px;
}

.form-status {
    margin-top: 14px;
    padding: 10px 14px;
    border-radius: 4px;
    font-size: 14px;
    display: none;
}

.form-status.success {
    display: block;
    background-color: #d1fae5;
    color: #065f46;
    border: 1px solid #6ee7b7;
}

.form-status.error {
    display: block;
    background-color: #fee2e2;
    color: #991b1b;
    border: 1px solid #fca5a5;
}

/* ---------- 页脚 ---------- */
.site-footer {
    background-color: #0f172a;
    color: #cbd5e1;
    padding-top: 50px;
    margin-top: 50px;
}

.footer-inner {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 30px;
    padding-bottom: 40px;
}

.footer-col h3 {
    color: #ffffff;
    font-size: 16px;
    margin-bottom: 16px;
    padding-bottom: 10px;
    border-bottom: 1px solid #334155;
}

.footer-col p {
    color: #94a3b8;
    font-size: 14px;
    line-height: 1.7;
}

.footer-col strong {
    color: #fbbf24;
}

.footer-col ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-col li {
    margin-bottom: 6px;
}

.footer-col a {
    color: #94a3b8;
    font-size: 14px;
}

.footer-col a:hover {
    color: #fbbf24;
    text-decoration: none;
}

.footer-company {
    color: #fbbf24 !important;
    font-weight: 600;
    margin-top: 12px !important;
}

.footer-contact li {
    margin-bottom: 8px;
    color: #cbd5e1;
    font-size: 13px;
    line-height: 1.6;
}

.footer-contact a {
    color: #cbd5e1;
    word-break: break-all;
}

.footer-contact a:hover {
    color: #fbbf24;
}

.footer-bottom {
    border-top: 1px solid #1e293b;
    padding: 20px 0;
    text-align: center;
}

.footer-bottom p {
    margin: 4px 0;
    color: #64748b;
    font-size: 13px;
}

.footer-copyright {
    color: #94a3b8 !important;
    font-weight: 500;
    margin-bottom: 6px !important;
}

.footer-icp {
    margin: 4px 0 !important;
    color: #64748b;
    font-size: 12px;
}

.footer-icp a {
    color: #94a3b8;
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-icp a:hover {
    color: #fbbf24;
    text-decoration: underline;
}

.footer-divider {
    color: #475569;
    margin: 0 8px;
    font-weight: 300;
}

.footer-keywords {
    color: #475569 !important;
    font-size: 12px !important;
    letter-spacing: 0.5px;
}

/* ---------- 回到顶部 ---------- */
.back-to-top {
    position: fixed;
    right: 24px;
    bottom: 24px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background-color: #b91c1c;
    color: #ffffff;
    border: none;
    font-size: 22px;
    line-height: 1;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 14px rgba(185, 28, 28, 0.3);
    transition: all 0.2s ease;
    z-index: 99;
}

.back-to-top:hover,
.back-to-top:focus {
    background-color: #991b1b;
    transform: translateY(-2px);
}

.back-to-top.show {
    display: flex;
}

/* =========================================================
 * 响应式 - 平板
 * ========================================================= */
@media (max-width: 992px) {
    .hero-inner {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .hero-text h1 {
        font-size: 30px;
    }

    .hero-image {
        max-width: 360px;
        margin: 0 auto;
    }

    .footer-inner {
        grid-template-columns: 1fr 1fr;
    }

    .contact-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .contact-card-wide {
        grid-column: span 2;
    }
}

/* =========================================================
 * 响应式 - 手机
 * ========================================================= */
@media (max-width: 768px) {
    body {
        font-size: 15px;
    }

    .topbar {
        font-size: 12px;
        padding: 6px 0;
    }

    .topbar-inner {
        justify-content: center;
        text-align: center;
    }

    .header-inner {
        padding-top: 10px;
        padding-bottom: 10px;
    }

    .brand-cn {
        font-size: 18px;
    }

    .brand-en {
        font-size: 11px;
    }

    /* 移动端导航 */
    .nav-toggle {
        display: block;
    }

    .primary-nav {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background-color: #ffffff;
        border-top: 1px solid #e5e7eb;
        border-bottom: 1px solid #e5e7eb;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
    }

    .primary-nav.open {
        max-height: 500px;
    }

    .primary-nav ul {
        flex-direction: column;
        gap: 0;
        padding: 10px 0;
    }

    .primary-nav a {
        padding: 12px 20px;
        border-radius: 0;
        border-bottom: 1px solid #f1f5f9;
    }

    /* Hero */
    .hero {
        padding: 40px 0;
    }

    .hero-text h1 {
        font-size: 24px;
    }

    .hero-subtitle {
        font-size: 15px;
    }

    .hero-points {
        grid-template-columns: 1fr;
    }

    /* Sections */
    .section {
        padding: 50px 0;
    }

    .section-title {
        font-size: 24px;
    }

    .section-subtitle {
        font-size: 14px;
        margin-bottom: 30px;
    }

    /* Footer */
    .footer-inner {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    /* Contact cards */
    .contact-grid {
        grid-template-columns: 1fr;
    }

    .contact-card-wide {
        grid-column: span 1;
    }

    .more-products {
        padding: 30px 18px;
        margin-top: 30px;
    }

    .more-products-title {
        font-size: 18px;
    }

    .more-products .btn-lg {
        padding: 12px 24px;
        font-size: 15px;
    }

    .brand-logo {
        height: 38px;
    }

    .brand-cn {
        font-size: 15px;
    }

    .brand-en {
        font-size: 10px;
    }

    /* Buttons */
    .btn {
        padding: 10px 20px;
        font-size: 14px;
    }

    .hero-cta {
        flex-direction: column;
    }

    .hero-cta .btn {
        width: 100%;
    }

    /* Filter */
    #productSearch {
        max-width: 100%;
    }

    /* Contact form */
    .contact-form {
        padding: 20px;
    }

    .back-to-top {
        width: 42px;
        height: 42px;
        right: 14px;
        bottom: 14px;
        font-size: 18px;
    }
}

@media (max-width: 480px) {
    .hero-text h1 {
        font-size: 22px;
        line-height: 1.3;
    }

    .hero-subtitle {
        font-size: 14px;
    }

    .keyword-strip ul {
        gap: 6px;
    }

    .keyword-strip li {
        font-size: 12px;
        padding: 4px 10px;
    }

    .section-title {
        font-size: 22px;
    }

    .section-subtitle {
        font-size: 13px;
        margin-bottom: 24px;
    }

    .category-card,
    .contact-card,
    .product-card .product-body {
        padding: 18px 16px;
    }

    .category-card h3,
    .contact-card h3 {
        font-size: 16px;
    }

    .product-body h3 {
        font-size: 15px;
    }

    .product-desc {
        font-size: 13px;
    }

    .application-list li {
        font-size: 14px;
        padding: 12px 14px 12px 38px;
    }

    .topbar {
        font-size: 11px;
    }

    .topbar-text {
        display: block;
        width: 100%;
        text-align: center;
    }

    .more-products {
        padding: 26px 14px;
    }

    .more-products-title {
        font-size: 17px;
    }

    .more-products-desc {
        font-size: 14px;
    }

    .footer-icp {
        font-size: 11px;
    }
}

/* iPhone X 等全面屏：底部安全区 */
@supports (padding: max(0px)) {
    .site-header {
        padding-left: max(0px, env(safe-area-inset-left));
        padding-right: max(0px, env(safe-area-inset-right));
    }

    .back-to-top {
        bottom: max(14px, env(safe-area-inset-bottom));
    }
}
