/* ============================================================
   仲子龙 · 个人主页
   ============================================================ */
:root {
  --navy-900: #0c1830;
  --navy-800: #122246;
  --navy-700: #1b3264;
  --blue-600: #2563eb;
  --blue-500: #3b82f6;
  --blue-100: #dbeafe;
  --bg: #f5f8fd;
  --card: #ffffff;
  --ink: #1f2a44;
  --ink-soft: #55607a;
  --line: #e4eaf4;
  --radius: 16px;
  --shadow: 0 10px 30px rgba(15, 34, 74, .08);
  --shadow-lg: 0 18px 44px rgba(15, 34, 74, .14);
  --font: "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB", "Noto Sans SC", "Source Han Sans SC", system-ui, -apple-system, "Segoe UI", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 78px; }
body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
.container { width: min(1120px, 92%); margin: 0 auto; }

/* ---------- 导航栏 ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  background: rgba(12, 24, 48, .82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(255, 255, 255, .08);
  transition: background .3s, box-shadow .3s;
}
.site-header.scrolled { background: rgba(12, 24, 48, .96); box-shadow: 0 6px 24px rgba(0, 0, 0, .25); }
.nav-wrap { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.brand { font-size: 1.35rem; font-weight: 800; color: #fff; letter-spacing: 2px; }
.brand span { color: var(--blue-400, #60a5fa); }
.main-nav { display: flex; gap: 6px; }
.nav-link {
  color: rgba(255, 255, 255, .78); font-size: .95rem; padding: 8px 14px;
  border-radius: 999px; transition: color .25s, background .25s;
}
.nav-link:hover { color: #fff; background: rgba(255, 255, 255, .1); }
.nav-link.active { color: #fff; background: var(--blue-500); }
.nav-toggle { display: none; flex-direction: column; gap: 5px; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav-toggle span { width: 24px; height: 2px; background: #fff; border-radius: 2px; transition: transform .3s, opacity .3s; }
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  position: relative; min-height: 100vh; display: flex; align-items: center;
  padding: 120px 0 90px; overflow: hidden; color: #fff;
  background: linear-gradient(150deg, #0a1428 0%, #10224a 55%, #14326b 100%);
}
.hero-bg { position: absolute; inset: 0; pointer-events: none; }
.hero-bg::before, .hero-bg::after {
  content: ""; position: absolute; border-radius: 50%; filter: blur(6px); opacity: .5;
}
.hero-bg::before { width: 420px; height: 420px; right: -120px; top: -120px; background: radial-gradient(circle, rgba(59,130,246,.55), transparent 70%); }
.hero-bg::after { width: 380px; height: 380px; left: -140px; bottom: -140px; background: radial-gradient(circle, rgba(96,165,250,.4), transparent 70%); }
.hero-inner { position: relative; text-align: center; display: flex; flex-direction: column; align-items: center; }

.avatar-ring {
  width: 150px; height: 150px; border-radius: 50%; padding: 6px;
  background: conic-gradient(from 210deg, #60a5fa, #2563eb, #93c5fd, #1d4ed8, #60a5fa);
  box-shadow: 0 16px 46px rgba(37, 99, 235, .45);
  animation: spin 14s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.avatar-core {
  width: 100%; height: 100%; border-radius: 50%; overflow: hidden; display: flex; align-items: center; justify-content: center;
  background: var(--navy-800);
  animation: spin 14s linear infinite reverse;
}
.avatar-photo { width: 100%; height: 100%; object-fit: cover; }
.hero-greeting { margin-top: 30px; font-size: 1.1rem; color: #93c5fd; letter-spacing: 4px; }
.hero-name { margin: 8px 0 4px; font-size: clamp(2.6rem, 7vw, 4.2rem); font-weight: 800; letter-spacing: 8px; }
.hero-role { font-size: clamp(1.05rem, 2.6vw, 1.35rem); color: #bfdbfe; min-height: 1.8em; }
.caret { display: inline-block; width: 2px; height: 1.15em; background: #60a5fa; margin-left: 4px; vertical-align: -2px; animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.hero-desc { margin-top: 12px; color: rgba(255, 255, 255, .75); font-size: 1rem; }
.hero-contacts { margin-top: 26px; display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.chip {
  display: inline-flex; align-items: center; gap: 8px; padding: 10px 18px; border-radius: 999px;
  background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .18);
  color: #fff; font-size: .95rem; transition: background .25s, transform .25s, border-color .25s;
}
a.chip:hover { background: rgba(255, 255, 255, .2); border-color: #60a5fa; transform: translateY(-2px); }
.hero-actions { margin-top: 34px; display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; }
.btn {
  display: inline-block; padding: 13px 30px; border-radius: 999px; font-size: 1rem; font-weight: 600;
  transition: transform .25s, box-shadow .25s, background .25s; cursor: pointer;
}
.btn-primary { background: var(--blue-500); color: #fff; box-shadow: 0 10px 26px rgba(37, 99, 235, .45); }
.btn-primary:hover { background: #2563eb; transform: translateY(-2px); }
.btn-ghost { border: 1.5px solid rgba(255, 255, 255, .45); color: #fff; }
.btn-ghost:hover { background: rgba(255, 255, 255, .12); transform: translateY(-2px); }
.scroll-hint { position: absolute; bottom: -46px; left: 50%; transform: translateX(-50%); }
.mouse { width: 26px; height: 42px; border: 2px solid rgba(255,255,255,.5); border-radius: 14px; display: block; position: relative; }
.wheel { position: absolute; left: 50%; top: 8px; width: 4px; height: 8px; margin-left: -2px; border-radius: 4px; background: #93c5fd; animation: wheel 1.6s ease-in-out infinite; }
@keyframes wheel { 0% { opacity: 1; transform: translateY(0); } 100% { opacity: 0; transform: translateY(14px); } }

/* ---------- 通用段落 ---------- */
.section { padding: 96px 0; }
.section-alt { background: #fff; }
.section-head { text-align: center; margin-bottom: 54px; }
.section-tag {
  display: inline-block; padding: 6px 16px; border-radius: 999px; font-size: .8rem; letter-spacing: 3px;
  color: var(--blue-600); background: var(--blue-100); font-weight: 700;
}
.section-head h2 { margin-top: 14px; font-size: clamp(1.7rem, 4vw, 2.3rem); font-weight: 800; letter-spacing: 2px; }
.section-sub { margin-top: 8px; color: var(--ink-soft); }

/* ---------- 关于我 ---------- */
.about-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.about-card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 34px 28px; box-shadow: var(--shadow); transition: transform .3s, box-shadow .3s;
}
.about-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.about-icon { font-size: 2rem; }
.about-card h3 { margin: 14px 0 10px; font-size: 1.15rem; }
.about-card p { color: var(--ink-soft); font-size: .95rem; }
.stat-bar {
  margin-top: 44px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px;
  background: var(--navy-800); border-radius: var(--radius); padding: 30px 24px; color: #fff; text-align: center;
  box-shadow: var(--shadow-lg);
}
.stat strong { display: block; font-size: 1.5rem; color: #93c5fd; }
.stat span { font-size: .88rem; color: rgba(255, 255, 255, .72); }

/* ---------- 技能 ---------- */
.skills-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.skill-group {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px 24px; box-shadow: var(--shadow); transition: transform .3s, box-shadow .3s;
}
.skill-group:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.skill-group h3 { display: flex; align-items: center; gap: 10px; font-size: 1.05rem; margin-bottom: 16px; }
.sg-icon { font-size: 1.35rem; }
.tags { display: flex; flex-wrap: wrap; gap: 10px; }
.tag {
  padding: 6px 14px; border-radius: 999px; font-size: .88rem; background: #eef3fc; color: #33508f;
  border: 1px solid #dfe9fb;
}
.tag-solid { background: var(--blue-100); color: var(--blue-600); border-color: transparent; font-weight: 600; }

/* ---------- 经历时间线 ---------- */
.timeline { position: relative; max-width: 860px; margin: 0 auto; padding-left: 30px; }
.timeline::before { content: ""; position: absolute; left: 8px; top: 8px; bottom: 8px; width: 2px; background: linear-gradient(#93c5fd, #2563eb); border-radius: 2px; }
.tl-item { position: relative; margin-bottom: 34px; }
.tl-dot {
  position: absolute; left: -30px; top: 26px; width: 16px; height: 16px; border-radius: 50%;
  background: var(--blue-500); border: 4px solid #fff; box-shadow: 0 0 0 3px var(--blue-500);
}
.tl-card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px 30px; box-shadow: var(--shadow); transition: transform .3s, box-shadow .3s;
}
.tl-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.tl-head { display: flex; justify-content: space-between; align-items: baseline; gap: 14px; flex-wrap: wrap; }
.tl-head h3 { font-size: 1.15rem; }
.tl-date { font-size: .85rem; color: var(--blue-600); font-weight: 600; white-space: nowrap; }
.tl-org { margin: 6px 0 12px; color: var(--ink-soft); font-size: .95rem; }
.tl-courses { color: var(--ink-soft); font-size: .92rem; }
.tl-list { margin-top: 4px; }
.tl-list li { position: relative; padding-left: 18px; color: var(--ink-soft); font-size: .95rem; margin-bottom: 6px; }
.tl-list li::before { content: "▸"; position: absolute; left: 0; color: var(--blue-500); }

/* ---------- 项目 ---------- */
.project-card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 38px; box-shadow: var(--shadow-lg); max-width: 920px; margin: 0 auto;
}
.project-head { display: flex; justify-content: space-between; align-items: baseline; gap: 14px; flex-wrap: wrap; margin-bottom: 8px; }
.project-head h3 { font-size: 1.45rem; }
.project-sub { color: var(--ink-soft); margin-top: 4px; font-size: .95rem; }
.project-meta { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin: 26px 0; }
.meta-block { background: #f7faff; border: 1px solid var(--line); border-radius: 12px; padding: 20px; }
.meta-block h4 { font-size: .95rem; color: var(--blue-600); margin-bottom: 8px; }
.meta-block p { font-size: .9rem; color: var(--ink-soft); }
.project-tags { display: flex; flex-wrap: wrap; gap: 10px; }

/* ---------- 荣誉 ---------- */
.awards-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.award-card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px 26px; box-shadow: var(--shadow); transition: transform .3s, box-shadow .3s;
}
.award-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.award-ico { font-size: 1.9rem; }
.award-card h3 { margin: 12px 0 8px; font-size: 1.08rem; }
.award-card p { color: var(--ink-soft); font-size: .92rem; }

/* ---------- 联系 ---------- */
.section-contact {
  background: linear-gradient(150deg, #0a1428, #14326b);
  color: #fff;
}
.section-contact .section-head h2 { color: #fff; }
.section-contact .section-sub { color: rgba(255, 255, 255, .72); }
.section-contact .section-tag { background: rgba(147, 197, 253, .16); color: #bfdbfe; }
.contact-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; max-width: 720px; margin: 0 auto; }
.contact-card {
  background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .16);
  border-radius: var(--radius); padding: 32px 26px; text-align: center;
  transition: transform .3s, background .3s, border-color .3s;
}
.contact-card:hover { background: rgba(255, 255, 255, .13); border-color: #60a5fa; transform: translateY(-4px); }
.contact-ico { font-size: 2rem; }
.contact-card h3 { margin: 10px 0 4px; color: #93c5fd; font-size: 1rem; }
.contact-card p { font-size: 1.05rem; word-break: break-all; }

/* ---------- 页脚 ---------- */
.site-footer { background: #081120; color: rgba(255, 255, 255, .55); text-align: center; padding: 26px 0; font-size: .9rem; }

/* ---------- 回到顶部 ---------- */
.to-top {
  position: fixed; right: 26px; bottom: 30px; width: 46px; height: 46px; border-radius: 50%;
  border: 0; cursor: pointer; background: var(--blue-500); color: #fff; font-size: 1.2rem;
  box-shadow: 0 10px 24px rgba(37, 99, 235, .4); opacity: 0; visibility: hidden; transform: translateY(12px);
  transition: opacity .3s, transform .3s, visibility .3s; z-index: 90;
}
.to-top.show { opacity: 1; visibility: visible; transform: translateY(0); }
.to-top:hover { background: #2563eb; }

/* ---------- 入场动画 ---------- */
html.js .reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s ease, transform .7s ease; }
html.js .reveal.visible { opacity: 1; transform: none; }

/* ---------- 响应式 ---------- */
@media (max-width: 960px) {
  .about-grid, .skills-grid, .awards-grid { grid-template-columns: repeat(2, 1fr); }
  .project-meta { grid-template-columns: 1fr; }
  .stat-bar { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 720px) {
  .nav-toggle { display: flex; }
  .main-nav {
    position: absolute; top: 72px; left: 0; right: 0;
    flex-direction: column; background: var(--navy-800); padding: 16px 24px; gap: 4px;
    border-bottom: 1px solid rgba(255, 255, 255, .1);
    transform: translateY(-12px); opacity: 0; visibility: hidden;
    transition: transform .3s, opacity .3s, visibility .3s;
  }
  .main-nav.open { transform: none; opacity: 1; visibility: visible; }
  .nav-link { padding: 12px 14px; }
  .section { padding: 72px 0; }
  .about-grid, .skills-grid, .awards-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .project-card { padding: 26px 22px; }
  .tl-card { padding: 22px 20px; }
  .hero { padding-top: 110px; }
}

