:root {
  --color-primary: #0B5CF0;
  --color-primary-deep: #0947C8;
  --color-accent: #00D4FF;
  --color-accent-glow: rgba(0, 212, 255, 0.35);
  --color-bg: #F4F7FB;
  --color-surface: #FFFFFF;
  --color-text: #1A2332;
  --color-text-secondary: #5A6B7C;
  --color-border: #E2E8F0;
  --color-header-bg: rgba(244, 247, 251, 0.92);
  --font-stack: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --shadow-card: 0 4px 16px rgba(11, 92, 240, 0.08);
  --shadow-hover: 0 8px 24px rgba(11, 92, 240, 0.14);
  --space-section: clamp(3rem, 6vw, 5.5rem);
  --container-max: 1160px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-stack);
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.85;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3, h4 { line-height: 1.25; font-weight: 700; color: var(--color-text); margin-bottom: 0.8em; }
h1 { font-size: clamp(2.4rem, 5vw, 3.6rem); text-wrap: balance; letter-spacing: -0.02em; }
h2 { font-size: clamp(1.8rem, 3.2vw, 2.4rem); margin-top: 0.4em; }
h3 { font-size: clamp(1.15rem, 1.6vw, 1.35rem); }
p { margin-bottom: 1rem; max-width: 72ch; }
a { color: var(--color-primary); transition: color 0.2s ease; }
a:hover { color: var(--color-primary-deep); }

img, svg { display: block; max-width: 100%; height: auto; }

.container { width: 100%; max-width: var(--container-max); margin: 0 auto; padding: 0 1.25rem; }
section { padding: var(--space-section) 0; }

/* Header & Nav */
.site-header { position: sticky; top: 0; background: var(--color-header-bg); backdrop-filter: blur(12px); border-bottom: 1px solid var(--color-border); z-index: 100; }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: flex; align-items: center; gap: 0.7rem; }
.brand img { width: 34px; height: 34px; object-fit: contain; }
.brand-name { font-weight: 700; font-size: 1.1rem; letter-spacing: 0.5px; color: var(--color-text); }
nav ul { display: flex; list-style: none; gap: 1.4rem; }
nav a { font-size: 0.95rem; font-weight: 500; color: var(--color-text-secondary); padding: 0.4rem 0; border-bottom: 2px solid transparent; transition: all 0.2s; }
nav a:hover, nav a[aria-current="page"] { color: var(--color-primary); border-color: var(--color-primary); }

/* Footer */
.site-footer { background: #0F172A; color: #94A3B8; padding: 3.5rem 0 2rem; margin-top: var(--space-section); }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 2.5rem; }
.footer-col h4 { color: #F8FAFC; margin-bottom: 1.2rem; font-size: 1.05rem; }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 0.6rem; }
.footer-col a { color: #CBD5E1; font-size: 0.92rem; }
.footer-col a:hover { color: #FFF; }
.copyright { text-align: center; margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1px solid #334155; font-size: 0.82rem; color: #64748B; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.6rem; padding: 0.85rem 1.7rem; border-radius: var(--radius-md); font-weight: 600; font-size: 1rem; cursor: pointer; border: none; transition: all 0.2s ease; text-decoration: none; }
.btn-primary { background: var(--color-primary); color: #FFF; box-shadow: 0 4px 12px rgba(11, 92, 240, 0.25); }
.btn-primary:hover { background: var(--color-primary-deep); transform: translateY(-2px); box-shadow: 0 6px 18px rgba(11, 92, 240, 0.35); }
.btn-outline { background: transparent; color: var(--color-primary); border: 2px solid var(--color-primary); }
.btn-outline:hover { background: rgba(11, 92, 240, 0.06); }

/* Cards & Grid */
.card { background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-lg); padding: 1.6rem; transition: transform 0.25s ease, box-shadow 0.25s ease; }
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); }
.bento-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.5rem; }
.feature-icon { width: 48px; height: 48px; border-radius: var(--radius-md); background: rgba(11, 92, 240, 0.08); color: var(--color-primary); margin-bottom: 1rem; }
.feature-icon svg { width: 100%; height: 100%; }
.news-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1.5rem; }
.tag { display: inline-block; padding: 0.2rem 0.6rem; background: #EEF2FF; color: var(--color-primary); font-size: 0.75rem; font-weight: 600; border-radius: 99px; margin-bottom: 0.8rem; }
.date { font-size: 0.82rem; color: var(--color-text-secondary); margin-bottom: 0.4rem; }
.related-list { list-style: none; columns: 2; column-gap: 2rem; }
.related-list li { margin-bottom: 1rem; break-inside: avoid; }
.related-list a { display: block; padding: 0.8rem 1rem; background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-md); transition: border-color 0.2s, box-shadow 0.2s; }
.related-list a:hover { border-color: var(--color-primary); box-shadow: var(--shadow-card); }
.related-title { font-weight: 600; color: var(--color-text); margin-bottom: 0.2rem; }
.related-desc { font-size: 0.9rem; color: var(--color-text-secondary); line-height: 1.6; }

/* Table */
.table-wrapper { overflow-x: auto; margin: 1.5rem 0; border: 1px solid var(--color-border); border-radius: var(--radius-md); }
table { width: 100%; border-collapse: collapse; min-width: 600px; }
th, td { padding: 0.9rem 1.2rem; border-bottom: 1px solid var(--color-border); text-align: left; }
th { background: #F8FAFC; font-weight: 600; color: var(--color-text); }
tr:last-child td { border-bottom: none; }
tr:hover td { background: #F1F5F9; }

/* FAQ */
details { margin-bottom: 1rem; border: 1px solid var(--color-border); border-radius: var(--radius-sm); overflow: hidden; background: var(--color-surface); }
summary { padding: 1rem 1.25rem; cursor: pointer; font-weight: 600; list-style: none; display: flex; justify-content: space-between; align-items: center; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; font-size: 1.2rem; color: var(--color-primary); transition: transform 0.2s; }
details[open] summary::after { content: "−"; transform: rotate(90deg); }
details > div { padding: 0 1.25rem 1.2rem; color: var(--color-text-secondary); line-height: 1.75; }

/* Progress/Steps */
.step-list { list-style: none; counter-reset: step-counter; }
.step-list li { counter-increment: step-counter; position: relative; padding-left: 2.8rem; margin-bottom: 1.5rem; }
.step-list li::before { content: counter(step-counter); position: absolute; left: 0; top: 0; width: 2rem; height: 2rem; background: var(--color-primary); color: #FFF; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 0.9rem; }
.step-list li:not(:last-child)::after { content: ""; position: absolute; left: 0.85rem; top: 2.2rem; bottom: -1.2rem; width: 2px; background: var(--color-border); }

/* Accessibility */
:focus-visible { outline: 3px solid var(--color-accent); outline-offset: 2px; border-radius: 4px; }
@media (max-width: 768px) {
  .header-inner { height: 56px; }
  nav ul { display: none; }
  .bento-grid, .news-grid { grid-template-columns: 1fr; }
  .related-list { columns: 1; }
}

/* SVG Animations */
.grid-node { fill: transparent; stroke: var(--color-primary); stroke-width: 2; transition: fill 0.5s ease, stroke-width 0.4s ease; }
.grid-line { stroke: var(--color-border); stroke-width: 1.5; opacity: 0.5; }
@keyframes node-ignite {
  0%, 100% { fill: transparent; stroke: var(--color-primary); stroke-width: 2; }
  30% { fill: var(--color-accent); stroke: var(--color-accent); stroke-width: 2.5; filter: drop-shadow(0 0 6px var(--color-accent-glow)); }
  60% { fill: transparent; stroke: var(--color-primary); stroke-width: 2; }
}
.node-animate { animation: node-ignite 6s ease-in-out infinite; }
.node-animate:nth-of-type(1) { animation-delay: 0s; }
.node-animate:nth-of-type(2) { animation-delay: 1.2s; }
.node-animate:nth-of-type(3) { animation-delay: 2.4s; }
.node-animate:nth-of-type(4) { animation-delay: 3.6s; }
.node-animate:nth-of-type(5) { animation-delay: 4.8s; }

@keyframes draw-flow {
  from { stroke-dashoffset: 1; }
  to { stroke-dashoffset: 0; }
}
.draw-path { pathLength: 1; stroke-dasharray: 1; stroke-dashoffset: 0; animation: draw-flow 3.5s ease forwards; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  .node-animate { animation: none; fill: transparent; stroke: var(--color-primary); }
  .draw-path { animation: none; stroke-dashoffset: 0; }
}
