{{ define "main" }}
<section class="hero card">
  <span class="eyebrow">Personal site</span>
  <h1>{{ .Title }}</h1>
  <div class="prose">{{ .Content }}</div>
</section>

<section class="grid three-up">
  <article class="card section-card">
    <h2><a href="{{ "/ai-daily/" | relURL }}">AI 每日简报</a></h2>
    <p>RobotDaily 的 Markdown 归档区，按日期沉淀每日精选。</p>
  </article>
  <article class="card section-card">
    <h2><a href="{{ "/blog/" | relURL }}">Blog</a></h2>
    <p>技术随笔、项目记录、日常输出都放这里。</p>
  </article>
  <article class="card section-card">
    <h2><a href="{{ "/resume/" | relURL }}">简历</a></h2>
    <p>个人经历、项目摘要、技能栈单独收纳。</p>
  </article>
</section>

<section class="card">
  <div class="section-head">
    <h2>最新 AI 简报</h2>
    <a href="{{ "/ai-daily/" | relURL }}">查看全部 →</a>
  </div>
  <div class="post-list">
    {{ range first 5 (where .Site.RegularPages.ByDate.Reverse "Section" "ai-daily") }}
      <article class="post-item">
        <h3><a href="{{ .RelPermalink }}">{{ .Title }}</a></h3>
        <p class="meta">{{ .Date.Format "2006-01-02" }}</p>
        <p>{{ with .Summary }}{{ . | plainify }}{{ else }}{{ .Params.summary }}{{ end }}</p>
      </article>
    {{ else }}
      <p>还没有导入日报内容。</p>
    {{ end }}
  </div>
</section>
{{ end }}
