/* ================= 极致极客风格变量 ================= */
:root {
    /* 核心背景改为深邃的科技蓝 */
    --bg-dark: #050b14;         /* 原来是 #030305，改为深海军蓝 */
    --bg-darker: #02060e;       /* 新增：用于页脚等更深的区域 */
    
    /* 面板改为带透明度、微微发蓝的颜色 */
    --bg-panel: rgba(10, 25, 47, 0.7); 
    
    /* 霓虹主色调微调，让青色更偏蓝一点 */
    --neon-cyan: #00d4ff;       /* 原来的 #00f0ff，改为更纯正的科技蓝青色 */
    --neon-purple: #8b5cf6;     /* 紫色也稍微调柔和，避免在蓝底上太突兀 */
    
    /* 文字颜色保持高对比度 */
    --text-main: #e2e8f0;
    --text-dim: #94a3b8;        /* 稍微调亮一点暗文字，保证在蓝底上的可读性 */
    --border-color: rgba(0, 212, 255, 0.2);
}

/* ================= 基础重置 ================= */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
      /* 英文数字用极客字体 Orbitron，中文用思源黑体/微软雅黑 */
    font-family: 'Orbitron', 'Source Han Sans SC', 'Microsoft YaHei', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-main);
    overflow-x: hidden;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    /* 修改这里的径向渐变，让整体散发深海蓝色的光晕 */
    background-image: 
        radial-gradient(circle at 50% 0%, rgba(0, 100, 255, 0.15) 0%, transparent 60%),
        radial-gradient(circle at 100% 100%, rgba(0, 212, 255, 0.1) 0%, transparent 50%);
}

/* 全息扫描线覆盖层 */
body::after {
    content: ''; position: fixed; top: 0; left: 0; width: 100vw; height: 100vh;
    background: repeating-linear-gradient(
        0deg,
        rgba(0, 0, 0, 0.15),
        rgba(0, 0, 0, 0.15) 1px,
        transparent 1px,
        transparent 3px
    );
    pointer-events: none; z-index: 9998; opacity: 0.6;
    animation: scanline 10s linear infinite;
}
@keyframes scanline {
    0% { background-position: 0 0; }
    100% { background-position: 0 100vh; }
}
/* 顶部发光滚动进度条 */
.scroll-progress {
    position: fixed; top: 0; left: 0; height: 2px; width: 0%;
    background: linear-gradient(90deg, var(--neon-cyan), var(--neon-purple));
    z-index: 10000; box-shadow: 0 0 10px var(--neon-cyan);
    transition: width 0.1s;
}

a { text-decoration: none; color: inherit; }
ul { list-style: none; }

/* 背景 canvas 画布 (粒子) */
#bg-canvas {
    position: fixed; top: 0; left: 0; width: 100vw; height: 100vh;
    z-index: -1; pointer-events: none;
}

/* 通用容器 */
.container { max-width: 1280px; margin: 0 auto; padding: 0 24px; position: relative; z-index: 10; }

/* 渐变文字 */
.gradient-text {
    background: linear-gradient(90deg, var(--neon-cyan), var(--neon-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* 滚动浮现 */
.reveal {
    opacity: 0; transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.active { opacity: 1; transform: translateY(0); }

/* ================= 导航栏 ================= */
header { position: fixed; top: 0; width: 100%; z-index: 100; transition: all 0.3s ease; }
header.scrolled {
    background: rgba(5, 11, 20, 0.85);
    backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-color);
}
.nav-inner { display: flex; justify-content: space-between; align-items: center; padding: 20px 0; transition: padding 0.3s; }
header.scrolled .nav-inner { padding: 15px 0; }

.logo { font-size: 22px; font-weight: 900; letter-spacing: 2px; display: flex; align-items: center; gap: 12px; }
.logo-img { height: 36px; width: auto; border-radius: 6px; box-shadow: 0 0 15px rgba(0, 240, 255, 0.4); object-fit: contain; background: #fff; }

.nav-links { display: flex; align-items: center; }
.nav-links a {
    color: var(--text-dim); margin-left: 40px; font-size: 14px;
    transition: all 0.3s; text-transform: uppercase; letter-spacing: 1px; position: relative;
}
.nav-links a::after {
    content: ''; position: absolute; bottom: -5px; left: 0; width: 0; height: 1px;
    background: var(--neon-cyan); transition: width 0.3s;
}
.nav-links a:hover { color: var(--neon-cyan); text-shadow: 0 0 8px rgba(0, 240, 255, 0.6); }
.nav-links a:hover::after { width: 100%; }

.btn-nav {
    padding: 10px 24px; border: 1px solid var(--neon-cyan); border-radius: 4px;
    color: var(--neon-cyan) !important; background: rgba(0, 240, 255, 0.05); transition: all 0.3s !important;
}
.btn-nav:hover { background: var(--neon-cyan); color: var(--bg-dark) !important; box-shadow: 0 0 20px rgba(0, 240, 255, 0.5); }
.btn-nav::after { display: none; }

/* 移动端菜单 */
.menu-toggle { display: none; background: none; border: none; cursor: pointer; flex-direction: column; gap: 5px; }
.menu-toggle span { display: block; width: 25px; height: 2px; background: var(--neon-cyan); transition: 0.3s; }
.mobile-nav {
    display: none; position: absolute; top: 100%; left: 0; width: 100%;
    background: rgba(3, 3, 5, 0.95); backdrop-filter: blur(16px);
    flex-direction: column; padding: 20px; border-bottom: 1px solid var(--border-color); gap: 20px; text-align: center;
}
.mobile-nav.active { display: flex; }
.mobile-nav a { color: var(--text-main); font-size: 16px; }

/* ================= 首屏 Hero ================= */
/* ================= 首屏 Hero (高级科幻风 - 保留数字雨) ================= */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    overflow: hidden;
}

/* 数字雨画布保持不变 */
#matrix-canvas {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    opacity: 0.15;
    z-index: 0;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 1200px;
    padding: 0 20px;
}

/* 主标题样式 */
/* ================= 首屏标题 (统一科技蓝 · 小米极简高级风) ================= */

.hero-title {
    /* 整体稍微往上提一点，给下方留出呼吸空间 */
    line-height: 1.1; /* 紧凑一点，两行字像一个整体 */
    margin-bottom: 50px; /* 标题和横线之间拉开距离 */
    font-family: 'PingFang SC', 'Microsoft YaHei', 'SimHei', sans-serif;
     /* 标题强制使用思源黑体（最硬朗的开源中文字体）或微软雅黑粗体 */
    font-family: 'Source Han Sans SC', 'Microsoft YaHei', 'SimHei', sans-serif;
    font-weight: 900; /* 必须非常粗才有力道 */
    /* 调整字间距，科技感很多时候是靠留白做出来的 */
    letter-spacing: 8px; 
    /* 稍微微调字与字的宽度，让字体看起来更扁平、像机甲 */
    transform: scaleY(0.95);
}


/* 第一行：大字号，亮色，作为视觉重心 */
/* 第一行：绝对的主角 */
.title-line1 {
    font-size: clamp(64px, 10vw, 130px); /* 从 9vw 提到 10vw，甚至更大 */
    letter-spacing: 12px; /* 字间距再拉大一点 */
    font-weight: 900;
    /* 加一个极细的描边，模拟全息投影的轮廓 */
    -webkit-text-stroke: 1px rgba(255, 255, 255, 0.3);
}

/* 第二行：稍微小一圈，作为底座 */
.title-line2 {
    font-size: clamp(48px, 7.5vw, 100px); /* 从 7vw 降到 7.5vw 左右，拉开差距 */
    letter-spacing: 8px;
    font-weight: 800;
    /* 第二行颜色深一点，让它有“退后”的层次感 */
    background: linear-gradient(180deg, #94a3b8 0%, #475569 50%, #0284c7 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 10px rgba(2, 132, 199, 0.3));
}

/* 英文副标题与发光横线 */
.hero-subtitle {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
     margin-bottom: 40px; /* 横线和下面的中文描述拉开距离 */
    font-size: 13px; /* 英文再小一点，更显精致 */
    letter-spacing: 4px; /* 英文间距拉大 */
}



.hero-subtitle .line-left, .hero-subtitle .line-right {
    height: 2px;
    width: 150px;
    position: relative;
}
.hero-subtitle .line-left {
    background: linear-gradient(90deg, transparent, #a855f7, #00d4ff);
    box-shadow: 0 0 10px #00d4ff;
}
.hero-subtitle .line-right {
    background: linear-gradient(90deg, #00d4ff, #a855f7, transparent);
    box-shadow: 0 0 10px #a855f7;
}
/* 横线中间的发光点 */
.hero-subtitle .line-left::after, .hero-subtitle .line-right::after {
    content: ''; position: absolute; top: -2px; width: 6px; height: 6px; border-radius: 50%;
    background: #fff; box-shadow: 0 0 10px #fff;
}
.hero-subtitle .line-left::after { right: 0; }
.hero-subtitle .line-right::after { left: 0; }

.text-en {
     font-family: 'Orbitron', 'Rajdhani', monospace; /* 强制使用极客字体 */
      font-weight: 600;
    text-transform: uppercase;
    font-size: 14px;
    letter-spacing: 3px;
    color: #e2e8f0;
    text-shadow: 0 0 8px rgba(0, 212, 255, 0.8);
}


/* 中文描述文字 (打字机) */
.hero-desc {
    font-size: 18px;
    color: #94a3b8;
    letter-spacing: 6px; /* 中文字间距拉开，这是高级感的秘诀 */
     margin-bottom: 60px; /* 中文描述和按钮拉开距离 */
    min-height: 30px;
    font-weight: 300;
}


.cursor {
    display: inline-block; width: 10px; height: 20px; background: var(--neon-cyan);
    animation: blink 1s infinite; vertical-align: middle; margin-left: 5px;
}
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }

/* 按钮组新样式 (科技感半透明填充) */
.hero-btns {
    display: flex;
    gap: 30px;
    justify-content: center;
}

.btn-hero {
    display: inline-block;
    padding: 16px 45px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    letter-spacing: 2px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    color: #fff;
    text-decoration: none;
}

/* 青色按钮 */
.btn-cyan {
    background: rgba(0, 212, 255, 0.1);
    border: 1px solid rgba(0, 212, 255, 0.6);
    box-shadow: inset 0 0 20px rgba(0, 212, 255, 0.1), 0 0 20px rgba(0, 212, 255, 0.1);
}
.btn-cyan:hover {
    background: rgba(0, 212, 255, 0.2);
    box-shadow: inset 0 0 30px rgba(0, 212, 255, 0.3), 0 0 40px rgba(0, 212, 255, 0.4);
    border-color: #00d4ff;
    transform: translateY(-3px);
}

/* 紫色按钮 */
.btn-purple {
    background: rgba(168, 85, 247, 0.1);
    border: 1px solid rgba(168, 85, 247, 0.6);
    box-shadow: inset 0 0 20px rgba(168, 85, 247, 0.1), 0 0 20px rgba(168, 85, 247, 0.1);
}
.btn-purple:hover {
    background: rgba(168, 85, 247, 0.2);
    box-shadow: inset 0 0 30px rgba(168, 85, 247, 0.3), 0 0 40px rgba(168, 85, 247, 0.4);
    border-color: #a855f7;
    transform: translateY(-3px);
}

/* ================= 通用区块 ================= */
.section { padding: 140px 0; position: relative; }
.section-title {
    font-size: 13px; letter-spacing: 4px; color: var(--neon-cyan); text-transform: uppercase;
    margin-bottom: 16px; font-weight: 600; display: flex; align-items: center; gap: 10px;
}
.section-title::before { content: ''; width: 20px; height: 1px; background: var(--neon-cyan); }
.section-heading { font-size: clamp(32px, 4vw, 42px); font-weight: 800; margin-bottom: 32px; letter-spacing: -1px; }

/* ================= 关于我们 ================= */
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.code-window { background: #0a1428; border: 1px solid var(--border-color); border-radius: 12px; overflow: hidden; box-shadow: 0 20px 50px rgba(0,0,0,0.5); }
.code-header { background: rgba(255,255,255,0.03); padding: 12px 20px; display: flex; align-items: center; gap: 8px; border-bottom: 1px solid var(--border-color); }
.code-dot { width: 12px; height: 12px; border-radius: 50%; }
.code-dot.red { background: #ff5f56; } .code-dot.yellow { background: #ffbd2e; } .code-dot.green { background: #27c93f; }
.code-title { margin-left: 10px; font-size: 12px; color: var(--text-dim); }
.code-body { padding: 30px; font-size: 14px; line-height: 1.8; color: #a6accd; overflow-x: auto; }
.code-keyword { color: var(--neon-purple); } .code-string { color: #c3e88d; } .code-comment { color: #546e7a; } .code-func { color: var(--neon-cyan); }

.stats-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.stat-item {
    background: var(--bg-panel); border: 1px solid var(--border-color); padding: 32px;
    border-radius: 8px; text-align: center; transition: all 0.3s; position: relative; overflow: hidden;
}
.stat-item::before {
    content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 2px;
    background: linear-gradient(90deg, var(--neon-cyan), var(--neon-purple));
    transform: scaleX(0); transition: transform 0.4s;
}
.stat-item:hover::before { transform: scaleX(1); }
.stat-item:hover { transform: translateY(-5px); box-shadow: 0 10px 30px rgba(0, 240, 255, 0.1); }
.stat-num { font-size: 40px; font-weight: 900; margin-bottom: 8px; background: linear-gradient(90deg, #fff, var(--neon-cyan)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.stat-label { font-size: 13px; color: var(--text-dim); letter-spacing: 1px; }

/* ================= 核心业务 ================= */
.services-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 30px; margin-top: 60px; }
.service-card {
    background: var(--bg-panel); border: 1px solid var(--border-color); border-radius: 16px;
    padding: 48px; position: relative; overflow: hidden; transition: all 0.4s ease; backdrop-filter: blur(10px);
}
.service-card::after {
    content: ''; position: absolute; bottom: 0; right: 0; width: 100px; height: 100px;
    background: radial-gradient(circle, rgba(0, 240, 255, 0.1), transparent 70%); opacity: 0; transition: opacity 0.4s;
}
.service-card:hover { transform: translateY(-5px); border-color: var(--neon-cyan); box-shadow: 0 0 40px rgba(0, 240, 255, 0.15); }
.service-card:hover::after { opacity: 1; }
.service-icon {
    width: 50px; height: 50px; background: rgba(0, 240, 255, 0.1); border: 1px solid var(--neon-cyan);
    border-radius: 8px; display: flex; align-items: center; justify-content: center;
    font-size: 24px; margin-bottom: 24px; color: var(--neon-cyan); transition: all 0.4s;
}
.service-card:hover .service-icon { background: var(--neon-cyan); color: var(--bg-dark); box-shadow: 0 0 20px rgba(0, 240, 255, 0.6); }
.service-card h3 { font-size: 22px; margin-bottom: 16px; font-weight: 700; color: #fff; }
.service-card p { color: var(--text-dim); font-size: 14px; margin-bottom: 24px; }
.service-tags { display: flex; flex-wrap: wrap; gap: 10px; }
.service-tags span {
    font-size: 11px; padding: 4px 12px; background: rgba(0, 240, 255, 0.05);
    border-radius: 4px; color: var(--neon-cyan); border: 1px solid rgba(0, 240, 255, 0.2);
}

/* ================= 软著产品矩阵 ================= */
.patent-section { background: rgba(0,0,0,0.4); border-top: 1px solid var(--border-color); border-bottom: 1px solid var(--border-color); }
.category-title {
    font-size: 18px; font-weight: 700; color: #fff; margin: 60px 0 30px 0;
    display: flex; align-items: center; gap: 15px; text-transform: uppercase; letter-spacing: 2px;
}
.category-title::after { content: ''; flex: 1; height: 1px; background: linear-gradient(90deg, var(--neon-cyan), transparent); }
.category-title span { font-size: 12px; color: var(--neon-purple); font-weight: 400; }
.patent-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 24px; }
.patent-card {
    background: var(--bg-panel); border: 1px solid var(--border-color); border-radius: 12px;
    overflow: hidden; position: relative; cursor: pointer; transition: all 0.3s ease; transform-style: preserve-3d;
}
.patent-card:hover { border-color: var(--neon-cyan); box-shadow: 0 0 30px rgba(0, 240, 255, 0.2); z-index: 10; }
.patent-img-wrapper { position: relative; overflow: hidden; height: 280px; background: #0a1428; display: flex; align-items: center; justify-content: center; }
.patent-img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s; }
.patent-card:hover .patent-img { transform: scale(1.05); }
.patent-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(180deg, transparent 50%, rgba(3,3,5,0.9) 100%);
    opacity: 0; transition: opacity 0.3s; display: flex; align-items: flex-end; justify-content: center; padding-bottom: 20px;
}
.patent-card:hover .patent-overlay { opacity: 1; }
.patent-overlay span {
    color: var(--neon-cyan); font-size: 13px; font-weight: 600; letter-spacing: 2px;
    border: 1px solid var(--neon-cyan); padding: 6px 16px; border-radius: 4px;
    background: rgba(0, 240, 255, 0.1); backdrop-filter: blur(4px); text-shadow: 0 0 10px rgba(0, 240, 255, 0.8);
}
.patent-info { padding: 16px; text-align: center; border-top: 1px solid var(--border-color); }
.patent-name { font-size: 13px; color: var(--text-main); font-weight: 500; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; line-height: 1.4; height: 38px; }
.patent-badge { display: inline-block; font-size: 10px; padding: 2px 8px; background: rgba(189, 0, 255, 0.1); color: var(--neon-purple); border-radius: 4px; margin-top: 8px; border: 1px solid rgba(189, 0, 255, 0.3); }

/* ================= 联系我们 ================= */
.contact-section { text-align: center; background: radial-gradient(circle at 50% 100%, rgba(0, 240, 255, 0.05) 0%, transparent 70%); }
.contact-info { display: flex; justify-content: center; gap: 80px; margin-top: 60px; margin-bottom: 60px; flex-wrap: wrap; }
.contact-item h4 { font-size: 13px; color: var(--neon-cyan); margin-bottom: 12px; letter-spacing: 2px; text-transform: uppercase; }
.contact-item p { font-size: 18px; font-weight: 500; color: #fff; }

/* ================= 页脚 ================= */
footer { padding: 40px 0; text-align: center; border-top: 1px solid var(--border-color); color: var(--text-dim); font-size: 12px; background: var(--bg-darker); }
footer p { margin-bottom: 8px; }

/* ================= 弹窗 Modal ================= */
.modal { display: none; position: fixed; z-index: 1000; left: 0; top: 0; width: 100%; height: 100%;  background-color: rgba(5, 11, 20, 0.95); backdrop-filter: blur(10px); align-items: center; justify-content: center; flex-direction: column; }
.modal-content { max-width: 85%; max-height: 85%; border-radius: 8px; border: 1px solid var(--neon-cyan); box-shadow: 0 0 60px rgba(0, 240, 255, 0.4); animation: zoomIn 0.3s ease; }
.modal-close { position: absolute; top: 30px; right: 40px; color: var(--neon-cyan); font-size: 40px; cursor: pointer; transition: all 0.3s; }
.modal-close:hover { text-shadow: 0 0 20px var(--neon-cyan); transform: rotate(90deg); }
@keyframes zoomIn { from { transform: scale(0.9); opacity: 0; } to { transform: scale(1); opacity: 1; } }

/* ================= 响应式 ================= */
@media (max-width: 992px) {
    .about-grid { gap: 40px; }
    .services-grid { gap: 20px; }
    .service-card { padding: 30px; }
}

@media (max-width: 768px) {
    .desktop-nav { display: none; }
    .menu-toggle { display: flex; }
    
    .hero h1 { font-size: 40px; }
    .hero p { font-size: 16px; height: auto; min-height: 40px; }
    .hero-btns { flex-direction: column; align-items: center; }
    .btn-primary, .btn-secondary { width: 100%; max-width: 300px; text-align: center; }
    
    .about-grid { grid-template-columns: 1fr; }
    .services-grid { grid-template-columns: 1fr; }
    .contact-info { flex-direction: column; gap: 30px; }
    .patent-grid { grid-template-columns: repeat(2, 1fr); }
    .patent-img-wrapper { height: 180px; }
    .logo-img { height: 28px; }
    .code-body { font-size: 12px; padding: 15px; }
}

@media (max-width: 480px) {
    .patent-grid { grid-template-columns: 1fr; }
    .stats-grid { grid-template-columns: 1fr; }
}


.cursor-glow {
    position: fixed; top: 0; left: 0; width: 400px; height: 400px;
     background: radial-gradient(circle, rgba(0, 150, 255, 0.15) 0%, transparent 70%);
    border-radius: 50%; pointer-events: none; z-index: 9999;
    transform: translate(-50%, -50%); transition: opacity 0.3s;
    mix-blend-mode: screen;
}

/* 卡片内部聚光效果 (需要配合JS) */
.service-card, .patent-card {
    position: relative;
}
.service-card::before, .patent-card::before {
    content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: radial-gradient(800px circle at var(--mouse-x) var(--mouse-y), rgba(0, 240, 255, 0.08), transparent 40%);
    opacity: 0; transition: opacity 0.3s; pointer-events: none; z-index: 1;
    border-radius: inherit;
}
.service-card:hover::before, .patent-card:hover::before { opacity: 1; }