{{define "cardlinks"}}
<div class="project-card">
    <div class="project-card-content">
      <h2 class="project-card-title">{{.Name}}</h2>

      {{if .Description}}
        <p class="project-card-description">{{.Description}}</p>
      {{end}}

      {{if .Date}}
        <p class="project-card-date">
          <div class="flex flex-row flex-wrap items-center gap-1 text-md">
            <svg xmlns="http://www.w3.org/2000/svg" width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-clock-4"><circle cx="12" cy="12" r="10"/><polyline points="12 6 12 12 16 14"/></svg>
            {{.Date}}
          </div>
        </p>
      {{end}}

      {{if .Tags}}
        <div class="project-card-tags">
          {{range .Tags}}
            <span class="project-tag">#{{.}}</span>
          {{end}}
        </div>
      {{end}}

      {{if .Href}}
        <div class="project-card-link">
            {{if eq true .Internal}}
              <a
              role="button"
              href={{.Href}}
              aria-label={{.Name}}
              class="project-link-button"
              preload="mouseover"
              >
                <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-arrow-right"><path d="M5 12h14"/><path d="m12 5 7 7-7 7"/></svg>
              </a>
            {{else}}
              <a
              role="button"
              href={{.Href}}
              aria-label={{.Name}}
              class="project-link-button"
              target="_blank"
              rel="noopener noreferrer"
              >
                <svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-link"><path d="M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71"/><path d="M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71"/></svg>
              </a>
            {{end}}
        </div>
      {{end}}
    </div>
</div>
{{end}}
