@font-face {
  font-family: "NumPlex";
  src: url("/res/kit/num-400.woff2") format("woff2");
  font-weight: 100 500;
  font-display: swap;
  unicode-range: U+0025, U+002B-002F, U+0030-0039, U+00D7, U+00F7, U+2013;
}

@font-face {
  font-family: "NumPlex";
  src: url("/res/kit/num-600.woff2") format("woff2");
  font-weight: 600 900;
  font-display: swap;
  unicode-range: U+0025, U+002B-002F, U+0030-0039, U+00D7, U+00F7, U+2013;
}

:root {
  --ink: #1d1b26;
  --ink-sub: #5f5c6e;
  --violet: #5b3fc4;
  --violet-dark: #4429a8;
  --mist: #f3f2f8;
  --marker: #ffe27a;
  --paper: #ffffff;
  --line: 2px solid var(--ink);
  --shadow: 4px 4px 0 var(--ink);
  --radius: 6px;
  --font: "NumPlex", "Yu Gothic Medium", "游ゴシック Medium", YuGothic, "游ゴシック体",
    "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.85;
  font-variant-numeric: tabular-nums;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: var(--violet);
  text-underline-offset: 3px;
}

a:hover {
  color: var(--violet-dark);
}

h1,
h2,
h3 {
  line-height: 1.45;
  font-weight: 800;
}

/* ---------- header ---------- */
.site_head {
  border-top: 6px solid var(--violet);
  border-bottom: var(--line);
  padding: 28px 16px 22px;
  text-align: center;
}

.site_home {
  color: var(--ink);
  text-decoration: none;
}

.site_home:hover {
  color: var(--ink);
}

.site_name {
  margin: 0;
  font-size: clamp(22px, 4.2vw, 30px);
  font-weight: 800;
  letter-spacing: 0.04em;
  line-height: 1.3;
}

.site_sub {
  display: block;
  margin-top: 4px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--violet);
}

.site_copy {
  display: inline-block;
  margin: 12px 0 0;
  padding: 0 4px;
  font-size: 14px;
  color: var(--ink-sub);
  background: linear-gradient(transparent 60%, var(--marker) 60%);
}

/* ---------- top ---------- */
.top_wrap {
  max-width: 1120px;
  margin: 0 auto;
  padding: 40px 16px 64px;
}

.top_grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 32px 28px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.tile_link {
  display: flex;
  flex-direction: column;
  height: 100%;
  border: var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: var(--shadow);
  color: var(--ink);
  text-decoration: none;
  overflow: hidden;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.tile_link:hover {
  color: var(--ink);
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 var(--violet);
}

.tile_media {
  position: relative;
  aspect-ratio: 3 / 2;
  border-bottom: var(--line);
  background: var(--mist);
}

.tile_media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tile_num {
  position: absolute;
  top: 0;
  left: 0;
  padding: 4px 12px;
  background: var(--violet);
  color: #fff;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.4;
  border-bottom-right-radius: var(--radius);
}

.tile_text {
  padding: 16px 18px 20px;
}

.tile_date {
  font-size: 13px;
  color: var(--ink-sub);
}

.tile_title {
  margin: 4px 0 8px;
  font-size: 17px;
}

.tile_excerpt {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.75;
  color: var(--ink-sub);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ---------- article ---------- */
.doc_hero {
  background: var(--ink);
  color: #fff;
  padding: 24px 16px 104px;
}

.doc_hero_in {
  max-width: 1040px;
  margin: 0 auto;
}

.crumb ol {
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 12.5px;
  color: #c9c5da;
}

.crumb li {
  display: inline;
}

.crumb li + li::before {
  content: "＞";
  margin: 0 8px;
  color: var(--marker);
}

.crumb a {
  color: #fff;
}

.doc_title {
  margin: 14px 0 10px;
  font-size: clamp(22px, 3.6vw, 32px);
  max-width: 820px;
}

.doc_date {
  margin: 0;
  font-size: 13px;
  color: #c9c5da;
}

.doc_date time {
  margin-left: 8px;
  color: #fff;
}

.doc_cols {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  grid-template-areas:
    "eye toc"
    "body toc";
  column-gap: 48px;
  max-width: 1072px;
  margin: -80px auto 0;
  padding: 0 16px;
}

.doc_eye {
  grid-area: eye;
  margin: 0 0 40px;
  width: fit-content;
  max-width: 100%;
  border: var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  background: var(--mist);
}

.doc_eye img {
  width: 640px;
  aspect-ratio: 3 / 2;
  object-fit: cover;
}

.doc_toc {
  grid-area: toc;
  align-self: start;
  position: sticky;
  top: 24px;
  margin-top: 104px;
  border: var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  padding: 16px 18px;
}

.doc_toc_head {
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.2em;
  color: var(--violet);
}

.doc_toc ol {
  margin: 0;
  padding: 0;
  list-style: none;
  max-height: calc(100vh - 140px);
  overflow-y: auto;
}

.doc_toc li + li {
  border-top: 1px solid #dddbe7;
}

.doc_toc a {
  display: flex;
  gap: 10px;
  padding: 8px 0;
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--ink);
  text-decoration: none;
}

.doc_toc a:hover {
  color: var(--violet);
}

.toc_num {
  flex: none;
  color: var(--violet);
  font-weight: 700;
}

/* ---------- body text ---------- */
.doc_body {
  grid-area: body;
  max-width: 720px;
  font-size: 16.5px;
}

.doc_body p {
  margin: 0 0 1.4em;
}

.doc_body h2 {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin: 2.6em 0 1em;
  padding-top: 14px;
  border-top: var(--line);
  font-size: clamp(19px, 2.6vw, 23px);
  scroll-margin-top: 16px;
}

.doc_body h2:first-child {
  margin-top: 0;
}

.h2_num {
  flex: none;
  padding: 0 8px;
  border-radius: 4px;
  background: var(--violet);
  color: #fff;
  font-size: 15px;
  line-height: 1.7;
}

.doc_body h3 {
  position: relative;
  margin: 2em 0 0.7em;
  padding-left: 18px;
  font-size: 17.5px;
}

.doc_body h3::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 9px;
  height: 9px;
  background: var(--violet);
}

.num_mark {
  font-weight: 700;
  padding: 0 0.08em;
  background: linear-gradient(transparent 58%, var(--marker) 58%);
  white-space: nowrap;
}

/* ---------- related ---------- */
.rel {
  max-width: 1072px;
  margin: 72px auto 0;
  padding: 32px 16px 64px;
  border-top: var(--line);
}

.rel_head {
  margin: 0 0 20px;
  font-size: 20px;
}

.rel_row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.rel_item a {
  position: relative;
  display: block;
  height: 100%;
  border: var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  color: var(--ink);
  text-decoration: none;
  box-shadow: var(--shadow);
}

.rel_item a:hover {
  box-shadow: 4px 4px 0 var(--violet);
}

.rel_item img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-bottom: var(--line);
}

.rel_num {
  position: absolute;
  top: 0;
  left: 0;
  padding: 2px 8px;
  background: var(--violet);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
}

.rel_title {
  display: block;
  padding: 10px 12px 14px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.6;
}

/* ---------- plain pages (privacy / 404) ---------- */
.plain_wrap {
  max-width: 760px;
  margin: 0 auto;
  padding: 40px 16px 72px;
}

.doc_hero + .plain_wrap {
  margin-top: -64px;
  background: var(--paper);
  border: var(--line);
  border-radius: var(--radius);
  padding: 32px clamp(18px, 4vw, 40px) 40px;
  margin-bottom: 64px;
}

.doc_hero:has(+ .plain_wrap) {
  padding-bottom: 88px;
}

.plain_date {
  margin-top: 2em;
  font-size: 14px;
  color: var(--ink-sub);
}

.miss_title {
  font-size: clamp(24px, 4vw, 30px);
  margin: 0 0 12px;
}

.miss_list {
  margin: 28px 0;
  padding: 8px 20px;
  list-style: none;
  border: var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.miss_list li + li {
  border-top: 1px solid #dddbe7;
}

.miss_list a {
  display: flex;
  gap: 12px;
  padding: 12px 0;
  color: var(--ink);
  text-decoration: none;
  font-weight: 700;
}

.miss_list a:hover {
  color: var(--violet);
}

/* ---------- footer ---------- */
.site_foot {
  background: var(--ink);
  color: #fff;
  padding: 36px 16px 20px;
}

.foot_in {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 24px;
  max-width: 1072px;
  margin: 0 auto;
}

.foot_name {
  margin: 0;
  font-weight: 800;
  font-size: 18px;
}

.foot_note {
  margin: 6px 0 0;
  font-size: 13px;
  color: #c9c5da;
}

.foot_links {
  display: flex;
  gap: 20px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 14px;
}

.foot_links a {
  color: #fff;
}

.foot_copy {
  max-width: 1072px;
  margin: 28px auto 0;
  padding-top: 14px;
  border-top: 1px solid #3a3746;
  font-size: 12px;
  color: #9d99b0;
}

/* ---------- responsive ---------- */
@media (max-width: 999px) {
  .top_grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .doc_cols {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "eye"
      "toc"
      "body";
    max-width: 752px;
  }

  .doc_eye {
    margin: 0 auto 28px;
  }

  .doc_toc {
    position: static;
    margin: 0 0 36px;
  }

  .doc_toc ol {
    max-height: none;
  }

  .rel_row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 639px) {
  .top_wrap {
    padding-top: 28px;
  }

  .top_grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
  }

  .doc_hero {
    padding-bottom: 72px;
  }

  .doc_cols {
    margin-top: -52px;
  }

  .doc_body {
    font-size: 16px;
  }

  .rel_row {
    gap: 14px;
  }

  .rel_title {
    font-size: 13px;
  }

  .foot_in {
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .tile_link {
    transition: none;
  }
}
