/* Aginx official site — dark protocol aesthetic, no frameworks */

:root {
  --bg: #070a10;
  --bg-alt: #0b0f16;
  --panel: #0e141e;
  --line: #1b2433;
  --text: #dbe4f0;
  --text-dim: #8b98ab;
  --accent: #4dd0ff;
  --accent-dim: #2a8db3;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

.wrap { max-width: 1080px; margin: 0 auto; padding: 0 24px; }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

code {
  font-family: var(--mono);
  font-size: 0.9em;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 1px 6px;
}

/* ---------- nav ---------- */

.nav {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(7, 10, 16, 0.82);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 700;
  font-size: 18px;
  letter-spacing: 0.02em;
}
.brand:hover { text-decoration: none; }
.brand-mark { width: 26px; height: 26px; }

.nav-links { display: flex; gap: 26px; }
.nav-links a {
  color: var(--text-dim);
  font-size: 14.5px;
}
.nav-links a:hover { color: var(--text); text-decoration: none; }

/* ---------- hero ---------- */

.hero {
  padding: 96px 0 72px;
  text-align: center;
  background:
    radial-gradient(ellipse 70% 45% at 50% -8%, rgba(77, 208, 255, 0.13), transparent 70%),
    var(--bg);
}

.kicker {
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin-bottom: 22px;
}

.hero h1 {
  font-size: clamp(30px, 7.2vw, 58px);
  line-height: 1.22;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.hero-sub {
  margin: 26px auto 0;
  max-width: 640px;
  color: var(--text-dim);
  font-size: 17px;
}

.addr-bar {
  margin: 44px auto 0;
  max-width: 560px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--mono);
  font-size: clamp(13px, 3.4vw, 19px);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px 22px;
  min-height: 58px;
  white-space: nowrap;
  overflow: hidden;
  box-shadow: 0 0 0 1px rgba(77, 208, 255, 0.06), 0 12px 40px rgba(0, 0, 0, 0.45);
}

.addr-scheme { color: var(--accent-dim); }

.caret {
  display: inline-block;
  width: 9px;
  height: 1.25em;
  margin-left: 2px;
  background: var(--accent);
  vertical-align: text-bottom;
  animation: blink 1.05s steps(1) infinite;
}

@keyframes blink { 50% { opacity: 0; } }

.hero-actions {
  margin-top: 34px;
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}
.hero-actions.center { margin-top: 28px; }

.btn {
  display: inline-block;
  padding: 11px 26px;
  border-radius: 10px;
  font-size: 15.5px;
  font-weight: 600;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }

.btn-primary {
  background: var(--accent);
  color: #04121b;
}
.btn-primary:hover { background: #6cd9ff; }

.btn-ghost {
  color: var(--text);
  border: 1px solid var(--line);
  background: transparent;
}
.btn-ghost:hover { border-color: var(--accent-dim); }

.hero-stats {
  margin: 56px auto 0;
  padding: 0;
  list-style: none;
  display: flex;
  justify-content: center;
  gap: 48px;
  flex-wrap: wrap;
}
.hero-stats li { display: flex; flex-direction: column; gap: 2px; }
.hero-stats strong {
  font-family: var(--mono);
  font-size: 17px;
  color: var(--text);
}
.hero-stats span {
  font-size: 13px;
  color: var(--text-dim);
}

/* ---------- sections ---------- */

.section { padding: 84px 0; }
.section-alt {
  background: var(--bg-alt);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.section h2 {
  font-size: clamp(26px, 3.4vw, 34px);
  font-weight: 800;
  text-align: center;
}

.section-sub {
  max-width: 680px;
  margin: 16px auto 0;
  text-align: center;
  color: var(--text-dim);
  font-size: 16px;
}

/* ---------- flow diagram ---------- */

.flow {
  margin-top: 56px;
  display: flex;
  align-items: stretch;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.flow-node {
  flex: 1 1 170px;
  max-width: 230px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 18px 18px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.flow-node i {
  font-style: normal;
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--text-dim);
}
.flow-node b { font-size: 16.5px; }
.flow-node s {
  text-decoration: none;
  font-size: 13px;
  color: var(--text-dim);
  line-height: 1.5;
}

.node-relay { border-color: rgba(77, 208, 255, 0.28); }
.node-gw { border-color: rgba(77, 208, 255, 0.45); box-shadow: 0 0 24px rgba(77, 208, 255, 0.07); }
.node-body { border-color: rgba(122, 162, 247, 0.35); }

.flow-arrow {
  align-self: center;
  font-family: var(--mono);
  font-size: 12.5px;
  color: var(--accent);
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 8px;
}
.flow-arrow .g { display: inline-block; }

/* ---------- analogy table ---------- */

.analogy { margin-top: 56px; overflow-x: auto; }

.analogy table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14.5px;
  min-width: 560px;
}
.analogy th, .analogy td {
  text-align: left;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
}
.analogy th {
  color: var(--text-dim);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.06em;
}
.analogy td:first-child { font-family: var(--mono); color: var(--accent); white-space: nowrap; }
.analogy td:nth-child(2) { font-family: var(--mono); color: var(--text-dim); white-space: nowrap; }

/* ---------- product cards ---------- */

.grid {
  margin-top: 52px;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
}

.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 26px 26px 22px;
  transition: border-color 0.18s ease, transform 0.18s ease;
}
.card:hover {
  border-color: rgba(77, 208, 255, 0.4);
  transform: translateY(-2px);
}

.card-tag {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  color: var(--accent);
  margin-bottom: 10px;
}

.card h3 { font-size: 20px; margin-bottom: 10px; }

.card p {
  color: var(--text-dim);
  font-size: 14.5px;
}
.card p b, .card p strong { color: var(--text); }

.card-meta {
  margin-top: 14px;
  font-family: var(--mono);
  font-size: 12.5px !important;
  color: var(--text-dim) !important;
}

.card-wide { grid-column: span 2; }

/* ---------- principles ---------- */

.principles {
  margin-top: 52px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.principle {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 24px 22px 20px;
  background: var(--bg-alt);
}
.principle h3 { font-size: 17px; margin-bottom: 8px; }
.principle p { font-size: 14px; color: var(--text-dim); }

/* ---------- roadmap ---------- */

.stages {
  margin-top: 52px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.stage {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 26px 24px 22px;
  background: var(--panel);
}

.stage-done { border-color: rgba(77, 208, 255, 0.45); }

.stage-no {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  color: var(--accent);
  margin-bottom: 8px;
}

.stage h3 { font-size: 19px; margin-bottom: 10px; }
.stage p { font-size: 14px; color: var(--text-dim); }

.stage-state {
  margin-top: 14px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

.stage-done .stage-state { color: var(--accent); }

/* ---------- cta / footer ---------- */

.cta {
  padding: 96px 0;
  text-align: center;
  background:
    radial-gradient(ellipse 60% 60% at 50% 110%, rgba(77, 208, 255, 0.12), transparent 70%),
    var(--bg);
}
.cta h2 { font-size: clamp(28px, 4vw, 40px); font-weight: 800; }

.footer {
  border-top: 1px solid var(--line);
  padding: 40px 0 28px;
  background: var(--bg-alt);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.footer-brand { display: flex; align-items: center; gap: 12px; }
.footer-brand .brand-mark { width: 30px; height: 30px; }
.footer-brand b { display: block; font-size: 15px; }
.footer-brand span { display: block; font-size: 12.5px; color: var(--text-dim); }

.footer-links { display: flex; gap: 22px; flex-wrap: wrap; }
.footer-links a {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--text-dim);
}
.footer-links a:hover { color: var(--accent); }

.footer-legal {
  margin-top: 28px;
  font-size: 12.5px;
  color: #5b6879;
  font-family: var(--mono);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.footer-legal a { color: #5b6879; }
.footer-legal a:hover { color: var(--accent); text-decoration: none; }

/* ---------- responsive ---------- */

@media (max-width: 860px) {
  .grid { grid-template-columns: 1fr; }
  .card-wide { grid-column: span 1; }
  .principles { grid-template-columns: 1fr; }
  .stages { grid-template-columns: 1fr; }
  .hero { padding: 64px 0 56px; }
  .hero h1 br { display: none; }
  .flow { flex-direction: column; align-items: center; }
  .flow-node { max-width: 420px; width: 100%; }
  .flow-arrow { flex-direction: column; gap: 2px; }
  .flow-arrow .g { transform: rotate(90deg); }
  .nav-links { gap: 16px; }
  .nav-links a { font-size: 13.5px; }
  .hero-stats { gap: 26px; }
}
