/* =========================================================
   陈子昂 · 个人网站样式表
   风格：浅色温暖 3D 插画风 / 参考 David Heckhoff 作品集
   关键词：米白背景、圆润卡片、柔和阴影、橙色主按钮、友好感
   ========================================================= */

/* 1) 颜色与基础变量 */
:root {
  --bg-page: #f5f0e8;            /* 温暖奶油色背景 */
  --bg-cream: #faf7f1;           /* 更浅的奶油色 */
  --bg-card: #ffffff;            /* 纯白卡片 */
  --bg-card-soft: #fffdfa;       /* 微暖白 */
  --text: #1e293b;               /* 深蓝灰主文字 */
  --text-muted: #64748b;         /* 次要文字 */
  --primary: #f4a261;            /* 暖橙色 */
  --primary-hover: #e76f51;      /* 深一点的橙 */
  --primary-soft: rgba(244, 162, 97, 0.12);
  --accent: #2a9d8f;             /* 青绿点缀 */
  --accent-soft: rgba(42, 157, 143, 0.10);
  --border: rgba(30, 41, 59, 0.08);
  --border-strong: rgba(30, 41, 59, 0.14);
  --radius: 24px;
  --radius-sm: 16px;
  --radius-pill: 999px;
  --max-width: 1140px;
  --shadow-soft: 0 4px 20px rgba(30, 41, 59, 0.06);
  --shadow-card: 0 12px 40px rgba(30, 41, 59, 0.10);
  --shadow-float: 0 20px 60px rgba(30, 41, 59, 0.14);
}

/* 2) 基础重置 */
* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: "DM Sans", "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont,
    "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background: var(--bg-page);
  line-height: 1.7;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

/* 3) 通用容器 */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* 4) 顶部导航 — 简洁圆润 */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(245, 240, 232, 0.86);
  backdrop-filter: saturate(160%) blur(16px);
  border-bottom: 1px solid var(--border);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 22px;
  font-weight: 800;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -0.5px;
}
.brand::before {
  content: "";
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: var(--primary);
  box-shadow: 0 4px 14px rgba(244, 162, 97, 0.35);
}
.brand span { color: var(--primary-hover); }
.nav-links { display: flex; gap: 36px; }
.nav-links a {
  position: relative;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 15px;
  font-weight: 700;
  padding: 8px 0;
  transition: color .2s;
}
.nav-links a::after {
  content: "";
  position: absolute;
  bottom: 2px;
  left: 0;
  width: 0;
  height: 3px;
  border-radius: 3px;
  background: var(--primary);
  transition: width .25s;
}
.nav-links a:hover,
.nav-links a.active { color: var(--text); }
.nav-links a:hover::after,
.nav-links a.active::after { width: 100%; }

/* 5) 英雄区 / 个人介绍 */
.hero { padding: 60px 0 40px; }
.hero-inner {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 48px;
  align-items: center;
}
.hero-content { min-width: 0; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: var(--primary-hover);
  background: var(--primary-soft);
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  margin-bottom: 24px;
}
.eyebrow::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--primary);
}

.hero h1 {
  font-size: 56px;
  line-height: 1.1;
  font-weight: 800;
  letter-spacing: -2px;
  margin-bottom: 18px;
  color: var(--text);
}
.hero h1 .greet {
  display: block;
  font-size: 22px;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: -0.5px;
  margin-bottom: 6px;
}
.hero-sub {
  font-size: 20px;
  color: var(--text-muted);
  font-weight: 500;
  margin-bottom: 26px;
  max-width: 520px;
}
.hero-desc {
  font-size: 16px;
  color: var(--text-muted);
  max-width: 560px;
  margin-bottom: 28px;
}

/* 主视觉图 */
.hero-avatar {
  justify-self: end;
  width: 100%;
  max-width: 560px;
}
.hero-avatar img {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  box-shadow: var(--shadow-float);
  background: var(--bg-card);
}

/* 联系信息小药丸 */
.contact-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  list-style: none;
  margin: 0 0 28px;
}
.contact-chips li {
  font-size: 14px;
  color: var(--text-muted);
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 9px 16px;
  border-radius: var(--radius-pill);
  font-weight: 600;
  transition: transform .2s, box-shadow .2s, border-color .2s;
}
.contact-chips li:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-soft);
  border-color: var(--primary);
}

/* 按钮 */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 30px;
  background: var(--primary);
  color: #fff;
  text-decoration: none;
  border-radius: var(--radius-pill);
  font-weight: 700;
  font-size: 15px;
  box-shadow: 0 8px 24px rgba(244, 162, 97, 0.32);
  transition: transform .2s, box-shadow .2s, background .2s;
}
.btn:hover {
  transform: translateY(-3px);
  background: var(--primary-hover);
  box-shadow: 0 12px 32px rgba(244, 162, 97, 0.42);
}

/* 6) 通用区块 */
.section { padding: 72px 0; }
.section-alt {
  background: var(--bg-cream);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.section-title {
  font-size: 34px;
  font-weight: 800;
  letter-spacing: -1px;
  margin-bottom: 12px;
}
.section-lead {
  color: var(--text-muted);
  max-width: 720px;
  margin-bottom: 38px;
}

/* 7) 工作经历卡片 — 圆润白卡片 */
.experience-list { display: flex; flex-direction: column; gap: 28px; }
.experience {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow-card);
  transition: transform .25s, box-shadow .25s;
}
.experience:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-float);
}

.exp-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}
.exp-head h3 { font-size: 21px; font-weight: 800; letter-spacing: -0.4px; }
.exp-meta {
  font-size: 14px;
  color: var(--text-muted);
  font-weight: 600;
}
.exp-summary {
  color: var(--text-muted);
  margin-bottom: 18px;
  font-size: 15px;
}

/* B端/C端 小标签 */
.role-label {
  display: inline-block;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: var(--accent);
  margin: 16px 0 10px;
  padding: 6px 12px;
  border-radius: 8px;
  background: var(--accent-soft);
}

/* STAR 工作亮点列表 */
.star-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.star-list li {
  position: relative;
  padding-left: 24px;
  font-size: 15px;
  color: var(--text);
}
.star-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 10px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--primary);
}
.star-list strong { color: var(--primary-hover); font-weight: 800; }
.star-list b { color: var(--text); font-weight: 800; }

.note {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px dashed var(--border);
}

/* 8) 价值板块卡片网格 */
.value-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}
.value-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px;
  box-shadow: var(--shadow-card);
  transition: transform .25s, box-shadow .25s;
}
.value-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-float);
}
.value-card h3 { font-size: 19px; font-weight: 800; margin-bottom: 10px; }
.value-card p { font-size: 15px; color: var(--text-muted); }

/* 9) 关于我：教育 & 技能 */
.info-block { margin-bottom: 40px; }
.info-block h3 {
  font-size: 19px;
  font-weight: 800;
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.info-block h3::before {
  content: "";
  width: 5px;
  height: 20px;
  border-radius: 3px;
  background: var(--primary);
}
.edu-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px 30px;
  box-shadow: var(--shadow-card);
}
.edu-item .school { font-size: 19px; font-weight: 800; }
.edu-item .degree { color: var(--text-muted); margin-top: 4px; font-weight: 500; }

/* 技能进度条（温暖风） */
.skill-bars { display: flex; flex-direction: column; gap: 18px; }
.skill-bar {
  display: grid;
  grid-template-columns: 130px 1fr auto;
  align-items: center;
  gap: 16px;
}
.skill-name {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
}
.skill-track {
  height: 10px;
  background: rgba(30, 41, 59, 0.08);
  border-radius: var(--radius-pill);
  overflow: hidden;
}
.skill-fill {
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--primary), var(--primary-hover));
  border-radius: var(--radius-pill);
  transition: width 1.2s cubic-bezier(.2, .8, .2, 1);
}
.skill-bars.in-view .skill-fill { width: var(--w, 0); }
.skill-value {
  font-size: 14px;
  color: var(--primary-hover);
  font-weight: 800;
  min-width: 40px;
  text-align: right;
}

/* 10) AI 助手区块 */
.ai-chat-wrap {
  margin-top: 28px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  background: var(--bg-card);
}
.ai-chat-wrap iframe {
  width: 100%;
  height: 640px;
  border: 0;
  display: block;
}

/* 11) 页脚 */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 40px 0;
  color: var(--text-muted);
  font-size: 14px;
  background: var(--bg-cream);
}
.footer-contact { margin-top: 6px; }

/* 12) 动效：首屏入场 / 滚动渐显 */
@keyframes hero-in {
  from { opacity: 0; transform: translateY(18px); }
  to   { opacity: 1; transform: none; }
}
.hero-content > * { animation: hero-in .7s ease both; }
.hero-content > *:nth-child(2) { animation-delay: .06s; }
.hero-content > *:nth-child(3) { animation-delay: .12s; }
.hero-content > *:nth-child(4) { animation-delay: .18s; }
.hero-content > *:nth-child(5) { animation-delay: .24s; }
.hero-avatar { animation: hero-in .7s ease .14s both; }

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .6s ease, transform .6s ease;
}
.reveal.visible { opacity: 1; transform: none; }

/* 滚动指示器（参考原站底部鼠标 icon） */
.scroll-hint {
  display: flex;
  justify-content: center;
  padding: 18px 0 8px;
}
.scroll-hint svg {
  width: 26px;
  height: 40px;
  color: var(--text-muted);
  opacity: .7;
}
@keyframes scroll-bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(6px); }
}
.scroll-hint svg .wheel { animation: scroll-bounce 1.6s ease-in-out infinite; }

/* 无障碍：尊重系统“减少动态效果”设置 */
@media (prefers-reduced-motion: reduce) {
  .hero-content > *, .hero-avatar { animation: none; opacity: 1; transform: none; }
  .reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
  .skill-fill { width: var(--w, 0) !important; }
  .scroll-hint svg .wheel { animation: none; }
  * { scroll-behavior: auto; }
}

/* 13) 手机端适配 */
@media (max-width: 720px) {
  .nav { height: 70px; }
  .nav-links { gap: 24px; }
  .hero { padding: 44px 0 32px; }
  .hero-inner {
    grid-template-columns: 1fr;
    justify-items: start;
    gap: 32px;
  }
  .hero-avatar { justify-self: start; max-width: 100%; }
  .hero h1 { font-size: 40px; }
  .hero h1 .greet { font-size: 18px; }
  .hero-sub { font-size: 17px; }
  .value-grid { grid-template-columns: 1fr; }
  .section-title { font-size: 28px; }
  .experience { padding: 24px; }
  .skill-bar { grid-template-columns: 90px 1fr auto; gap: 10px; }
  .ai-chat-wrap iframe { height: 560px; }
}
