/* --- 酷炫科技风 CSS 变量 --- */
:root {
    --color-dark-bg: #0d0d12; /* 更深的背景 */
    --color-primary-neon: #00e0ff; /* 主色：霓虹蓝 */
    --color-secondary-accent: #ff0077; /* 副色：品红 */
    --color-text-light: #e0e0e0;
    --font-family-tech: 'Roboto Mono', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    /* 数据流颜色 */
    --color-flow-good: #4CAF50; /* 绿色 */
    --color-flow-alert: #FFC107; /* 黄色 */
    --color-flow-risk: #F44336; /* 红色 */
    --glow-primary: 0 0 10px rgba(0, 224, 255, 0.7);
    --glow-secondary: 0 0 10px rgba(255, 0, 119, 0.7);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-family-tech);
    background-color: var(--color-dark-bg);
    color: var(--color-text-light);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
}

/* --- 粒子背景 --- */
#particles-js {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

/* --- 科技网格背景 --- */
.tech-grid-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(to right, rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 30px 30px;
    opacity: 0.5;
    z-index: -1;
}

/* --- 头部导航栏 --- */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 5%;
    background: rgba(13, 13, 18, 0.8);
    backdrop-filter: blur(8px);
    position: sticky;
    top: 0;
    z-index: 10;
    border-bottom: 1px solid rgba(0, 224, 255, 0.3);
}

.logo {
    font-size: 1.5em;
    font-weight: bold;
    color: var(--color-primary-neon);
    text-shadow: var(--glow-primary);
}

nav a {
    color: var(--color-text-light);
    text-decoration: none;
    margin-left: 30px;
    padding: 8px 15px;
    transition: color 0.3s, text-shadow 0.3s;
}

nav a:hover {
    color: var(--color-primary-neon);
    text-shadow: 0 0 8px var(--color-primary-neon);
}

.cta-button {
    background-color: var(--color-secondary-accent);
    border: none;
    border-radius: 5px;
    padding: 10px 20px;
    text-shadow: none;
    transition: background-color 0.3s, box-shadow 0.3s;
    font-weight: bold;
}

.cta-button:hover {
    background-color: #ff3399;
    box-shadow: 0 0 15px var(--color-secondary-accent);
}

/* --- 通用按钮和排版 --- */
.primary-cta {
    background: linear-gradient(90deg, var(--color-primary-neon), #00aaff);
    color: var(--color-dark-bg);
    border: none;
    padding: 15px 30px;
    font-size: 1.1em;
    font-weight: bold;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
    text-transform: uppercase;
}

.primary-cta:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0, 224, 255, 0.6);
}

h1, h2 {
    text-align: center;
    margin-bottom: 20px;
    text-transform: uppercase;
    font-weight: 700;
}

h2 {
    font-size: 2.5em;
    color: var(--color-primary-neon);
    text-shadow: var(--glow-primary);
    margin-top: 60px;
}

.subtitle {
    color: #999;
    margin-bottom: 50px;
}

/* --- 网站介绍区 (Hero) --- */
.hero-section {
    height: 90vh;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 0 5%;
}

.hero-content h1 {
    font-size: 4.5em;
    margin-bottom: 20px;
    background: linear-gradient(45deg, var(--color-primary-neon), var(--color-text-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: var(--glow-primary);
}

.hero-content p {
    font-size: 1.6em;
    margin-bottom: 40px;
    color: #ababab;
}

/* --- 风险中枢展示区 (Risk Hub) --- */
.risk-hub-section {
    padding: 80px 5%;
    background: #181818;
    text-align: center;
    border-top: 5px solid var(--color-secondary-accent);
}

.risk-display-container {
    position: relative;
    width: 80%;
    max-width: 1000px;
    height: 400px;
    margin: 40px auto;
    border: 2px solid rgba(0, 224, 255, 0.5);
    border-radius: 15px;
    background: rgba(30, 30, 30, 0.8);
    overflow: hidden;
    box-shadow: 0 0 30px rgba(0, 224, 255, 0.3);
}

/* 核心风险指数 Box (AI 核心处理器样式) */
.risk-index-box {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: radial-gradient(#333, #151515);
    border: 5px solid var(--color-flow-risk);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 5;
    box-shadow: 0 0 40px var(--color-flow-risk);
    transition: all 0.5s ease-in-out;
    animation: pulse-core 2s infinite alternate;
}

@keyframes pulse-core {
    from { box-shadow: 0 0 15px rgba(244, 67, 54, 0.7); }
    to { box-shadow: 0 0 40px rgba(244, 67, 54, 1); }
}

.risk-index-box span {
    font-size: 1em;
    color: #ccc;
}

#risk-value {
    font-size: 4em;
    font-weight: bold;
    color: var(--color-flow-risk);
    text-shadow: 0 0 15px var(--color-flow-risk);
}

/* 数据流标签 */
.flow-labels div {
    color: var(--color-primary-neon);
    text-shadow: var(--glow-primary);
    font-size: 1.2em;
    font-weight: bold;
}
.flow-labels .flow-center-label {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    color: var(--color-secondary-accent);
    text-shadow: var(--glow-secondary);
    top: -50px;
}

/* 风险功能卡片 */
.risk-features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 60px;
}

.risk-feature-card {
    background: rgba(30, 30, 30, 0.8);
    border: 1px solid rgba(255, 0, 119, 0.2);
    border-radius: 10px;
    padding: 30px;
    text-align: left;
    transition: background 0.3s, border-color 0.3s, box-shadow 0.3s;
    will-change: transform;
}

.risk-feature-card:hover {
    background: rgba(40, 40, 40, 1);
    border-color: var(--color-secondary-accent);
    box-shadow: 0 0 20px rgba(255, 0, 119, 0.5);
}

.risk-feature-card i {
    font-size: 2.5em;
    color: var(--color-secondary-accent);
    text-shadow: var(--glow-secondary);
    margin-bottom: 15px;
}


/* --- 智慧财务展示区 (Smart Finance) --- */
.smart-finance-section {
    padding: 80px 5%;
    background: #0d0d12;
    text-align: center;
    border-top: 5px solid var(--color-primary-neon);
}

.finance-metrics-dashboard {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin: 40px auto 60px;
}

.metric-box {
    background: rgba(30, 30, 30, 0.9);
    border: 1px solid rgba(255, 0, 119, 0.3);
    border-radius: 10px;
    padding: 20px 30px;
    text-align: center;
    flex: 1;
    max-width: 300px;
    box-shadow: 0 0 10px rgba(255, 0, 119, 0.1);
}

.metric-box span {
    display: block;
    font-size: 0.9em;
    color: #aaa;
    margin-bottom: 5px;
}

.metric-box p {
    font-size: 2.5em;
    font-weight: bold;
    color: var(--color-primary-neon);
    text-shadow: 0 0 5px var(--color-primary-neon);
}

.compliance-metric p {
    color: var(--color-flow-good);
}

.alert-metric p {
    color: var(--color-flow-risk);
    animation: pulse-red 1.5s infinite;
}

@keyframes pulse-red {
    0% { box-shadow: 0 0 5px var(--color-flow-risk); }
    50% { box-shadow: 0 0 20px var(--color-flow-risk); }
    100% { box-shadow: 0 0 5px var(--color-flow-risk); }
}

/* 资金流向容器 */
.finance-flow-container {
    position: relative;
    width: 90%;
    max-width: 1200px;
    height: 350px;
    margin: 40px auto;
    border: 1px dashed rgba(255, 0, 119, 0.6);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 0 15px rgba(255, 0, 119, 0.3);
}

#finance-flow-canvas {
    position: absolute;
    width: 100%;
    height: 100%;
}

.flow-labels-finance {
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 0 50px;
    font-weight: bold;
    color: var(--color-text-light);
    z-index: 5;
    pointer-events: none;
}
.flow-labels-finance .flow-center {
    color: var(--color-primary-neon);
    text-shadow: var(--glow-primary);
}

/* --- 模态框 (登录/注册) --- */
.modal-container {
    display: none;
    position: fixed;
    z-index: 100;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(3px);
}

.modal {
    background-color: #1a1a1f;
    margin: 15% auto;
    padding: 40px;
    border: 1px solid var(--color-primary-neon);
    width: 80%;
    max-width: 400px;
    border-radius: 10px;
    position: relative;
    box-shadow: 0 0 40px rgba(0, 224, 255, 0.5);
}

.modal h3 {
    color: var(--color-primary-neon);
    margin-bottom: 25px;
    text-align: center;
}

.modal input {
    width: 100%;
    padding: 12px;
    margin-bottom: 15px;
    border: 1px solid #555;
    background-color: #2a2a30;
    color: var(--color-text-light);
    border-radius: 5px;
}

.modal .primary-cta {
    width: 100%;
    margin-top: 10px;
    padding: 12px;
}

.modal p {
    text-align: center;
    margin-top: 15px;
}

.modal a {
    color: var(--color-secondary-accent);
    text-decoration: none;
}

.close-btn {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    position: absolute;
    top: 10px;
    right: 20px;
    cursor: pointer;
}