/* ========================================
   テンプレートの一覧ページ kurorabo.com/templates/（決定#4081）
   見た目はサイトテンプレートの一覧（kurorabo-template-gallery/gallery.css）に合わせた。色・角丸・余白・カードの並びは同じ値。
   カードは1枚ごとに丸ごと1つのリンク。PC は3列、920px 以下は2列、560px 以下は1列。
   下の別枠は AnimHub（決定#4105）。
   ======================================== */

#kr-templates {
  --paper: #fff;
  --ink: #171d2c;
  --muted: #525d73;
  --line: #e8edf5;
  --key: #2b64d6;
  --tint: #f2f6ff;
  --hover-line: #c9d7f2;

  margin: 0;
  color: var(--ink);
  background: var(--paper);

  & #kr-main .wrap {
    max-width: 1248px;
    margin-inline: auto;
    padding-inline: 24px;

    @media (max-width: 560px) { padding-inline: 16px; }
  }
  & .title_area {
    padding-block: 64px 36px;
    text-align: center;

    @media (max-width: 560px) { padding-block: 36px 24px; }

    & h1 {
      color: var(--ink);
      font-size: 40px;
      font-weight: 800;
      line-height: 1.4;
      text-wrap: balance;

      @media (max-width: 920px) { font-size: 36px; }
      @media (max-width: 560px) { font-size: 28px; }
    }
    & p { max-width: 640px; margin: 14px auto 0; color: var(--muted); line-height: 1.85; text-wrap: pretty; }
  }
  & .catalog { padding-block: 12px 56px; }
  & .catalog_heading {
    margin-bottom: 18px;
    display: flex;
    align-items: baseline;
    gap: 12px;

    & h2 { font-size: 20px; line-height: 1.5; font-weight: 700; }
    & p { color: var(--muted); font-size: 14px; }
  }
  & .cards {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;

    @media (max-width: 920px) { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
    @media (max-width: 560px) { grid-template-columns: minmax(0, 1fr); }
  }
  & .card {
    min-width: 0;
    display: flex;

    & > a {
      width: 100%;
      display: flex;
      flex-direction: column;
      border: 1px solid var(--line);
      border-radius: 20px;
      color: inherit;
      background: var(--paper);
      text-decoration: none;
      transition: border-color .2s ease, box-shadow .2s ease;

      &:hover { border-color: var(--hover-line); box-shadow: 0 8px 24px rgb(19 35 68 / 8%); }
      &:hover .go { background: #e5edff; }
      &:focus-visible { outline: 2px solid var(--key); outline-offset: 3px; }

      @media (prefers-reduced-motion: reduce) { transition: none; }
    }
    & .thumbnail {
      border-bottom: 1px solid var(--line);
      border-radius: 19px 19px 0 0;
      overflow: hidden;
      background: #f5f7fb;

      & img { display: block; width: 100%; height: auto; aspect-ratio: 900 / 634; object-fit: cover; }
    }
    & .body {
      padding: 17px 18px 18px;
      display: flex;
      flex: 1;
      flex-direction: column;
      gap: 6px;
    }
    & h3 { font-size: 18px; font-weight: 700; line-height: 1.55; overflow-wrap: anywhere; }
    & .count { color: var(--key); font-size: 14px; font-weight: 700; }
    & .note { padding-bottom: 8px; color: var(--muted); font-size: 14px; line-height: 1.7; }
    & .go { margin-top: auto; align-self: flex-start; }
  }
  & .go {
    min-height: 44px;
    padding: 8px 16px;
    display: inline-flex;
    flex: none;
    align-items: center;
    border-radius: 24px;
    color: #2354b8;
    background: var(--tint);
    font-size: 14px;
    font-weight: 700;
  }
  & .more {
    padding-block: 0 72px;

    @media (max-width: 560px) { padding-block: 0 48px; }

    & h2 { margin-bottom: 14px; font-size: 20px; font-weight: 700; line-height: 1.5; }
  }
  & .more_link {
    padding: 18px 20px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px 24px;
    border: 1px solid var(--line);
    border-radius: 16px;
    color: inherit;
    text-decoration: none;
    transition: border-color .2s ease;

    &:hover { border-color: var(--hover-line); }
    &:hover .go { background: #e5edff; }
    &:focus-visible { outline: 2px solid var(--key); outline-offset: 3px; }

    @media (prefers-reduced-motion: reduce) { transition: none; }

    & .more_body { min-width: 0; }
    & .more_name { display: block; font-size: 18px; font-weight: 700; line-height: 1.55; }
    & .more_note { display: block; margin-top: 2px; color: var(--muted); font-size: 14px; line-height: 1.7; }
  }
}

/* 最終更新: 2026-11-30 */
