@charset "UTF-8";
:root {
  --color-content: hsl(0 0% 0%);
  --color-background: hsl(0 0% 100%);
  --color-button-background: var(--color-background);
  --color-button-content: var(--color-content);
  --color-button-content-hover: var(--color-background);
  --color-button-background-hover: var(--color-content);
  --color-button-content-active: var(--color-background);
  --color-button-background-active: hsl(0 0% 30%);
  --ease-out: cubic-bezier(0.4, 0, 0, 1);
}

html {
  font-family: "Inter", "Noto Sans JP", sans-serif;
  line-height: 1.75;
  font-size: 16px;
}

body {
  color: var(--color-content);
  background-color: var(--color-background);
  padding-bottom: 5rem;
}

a {
  color: hsl(210, 100%, 45%);
  margin-inline: 0.15em;
  text-decoration: underline;
}
@media (hover: hover) {
  a {
    text-decoration: none;
  }
  a:hover {
    text-decoration: underline;
  }
}

b {
  font-weight: bold;
}

h1, .sample__h1,
h2,
h3,
h4,
h5,
h6 {
  display: block;
  font-weight: bold;
  line-height: 1.4;
  margin: 2em -1rem 0.5em -1rem;
  padding-left: 0.5em;
}

h1, .sample__h1,
h2,
h3,
h4,
h5 {
  font-feature-settings: "palt" 1;
  word-break: keep-all;
}

h1, .sample__h1 {
  border: none;
  display: flex;
  align-items: center;
  font-size: clamp(2rem, 6vw, 4rem);
  margin: 1.25em auto 0.25em;
  padding: 0;
  position: relative;
  width: 100%;
}
h1::before, .sample__h1::before {
  background-color: var(--color-content);
  content: "";
  display: block;
  height: 1px;
  margin-right: 0.4em;
  position: absolute;
  right: 100%;
  width: calc((100vw - 60rem) / 2 - 0.4em);
}

h2,
h3 {
  border-left: 0.15em solid currentColor;
}

h4,
h5,
h6 {
  margin-left: 0;
  margin-right: 0;
  padding-left: 0;
}

h2 {
  font-size: clamp(1.7rem, 3.3333333333vw, 2.5rem);
  letter-spacing: 0.01em;
  border-bottom: solid 1px currentColor;
  padding-bottom: 0.2em;
  margin-bottom: 0.5em;
  margin-top: 2em;
}

h3 {
  font-size: clamp(1.6rem, 2.4vw, 1.8rem);
  letter-spacing: 0.02em;
}

h4 {
  font-size: clamp(1.4rem, 2vw, 1.6rem);
  letter-spacing: 0.035em;
}

h5 {
  font-size: clamp(1.1rem, 1.4666666667vw, 1.3rem);
  letter-spacing: 0.05em;
}

hr {
  border-top: solid 1px hsla(0, 0%, 70%, 0.5);
  margin: 2em 0;
}

p {
  text-indent: 0.5em;
}

ul,
ol {
  margin: 0.75em 0;
  padding: 0 0.5em;
}
ul li,
ol li {
  margin-left: clamp(1em, 6vw, 2em);
}

ul {
  list-style-type: disc;
}

ol {
  list-style-type: decimal;
}

li p:last-of-type {
  margin-bottom: 0.5em;
}

nav {
  margin-bottom: 2rem;
}
nav ul {
  margin: 0;
}
nav ul ul {
  margin-left: -0.5em;
}

kbd {
  font-family: "SF Mono", monospace;
  display: inline-block;
  border: solid 1px currentColor;
  border-bottom-width: 2px;
  border-radius: 0.15em;
  line-height: 1;
  text-indent: 0;
  padding: 0.3em 0.4em;
  margin: 0.05em 0.15em;
  background-color: var(--color-background);
  color: var(--color-content);
}

video {
  width: 100%;
}

pre {
  text-wrap: wrap;
  position: relative;
}
pre::before {
  content: "unknown language";
  color: white;
  display: block;
  font-style: italic;
  font-size: 0.6rem;
  letter-spacing: 0.05em;
  line-height: 1;
  margin: 0.5em 0.4em;
  position: absolute;
  top: 0%;
  text-align: right;
  right: 0;
  opacity: 0.5;
}
pre:has(code) {
  margin: 1em 0;
}
pre:has(code.language-html)::before {
  content: "HTML";
}
pre:has(code.language-css)::before {
  content: "CSS";
}
pre:has(code.language-javascript)::before {
  content: "JavaScript";
}

pre code {
  border: solid 1px hsla(0, 0%, 60%, 0.2);
  line-height: 1.5;
  text-wrap: nowrap;
  overflow-x: auto;
  margin-inline: 0;
}

code {
  font-family: "SF Mono", "Noto Sans JP", monospace;
  border: solid 1px hsla(0, 0%, 60%, 0.7);
  padding: 0.15em 0.25em;
  margin-inline: 0.35em;
  line-height: 1.5;
}

iframe {
  width: 100%;
}

strong ~ pre {
  margin-top: 0.25em;
}

div:has(strong ~ pre) {
  margin-top: 1rem;
}

img {
  display: block;
  margin-block: 1.5rem;
  margin-inline: auto;
  width: min(100%, 35rem);
}

.content-area {
  margin: 2rem auto;
  width: min(60rem, 100vw - clamp(2rem, 8vw, 6rem));
}

.content {
  margin: 0 clamp(0.5rem, 3vw, 1rem);
}

.visually-hidden {
  position: fixed !important;
  /* keep it on viewport */
  top: 0px !important;
  left: 0px !important;
  /* give it non-zero size, VoiceOver on Safari requires at least 2 pixels
     before allowing buttons to be activated. */
  width: 4px !important;
  height: 4px !important;
  /* visually hide it with overflow and opacity */
  opacity: 0 !important;
  overflow: hidden !important;
  /* remove any margin or padding */
  border: none !important;
  margin: 0 !important;
  padding: 0 !important;
  /* ensure no other style sets display to none */
  display: block !important;
  visibility: visible !important;
}

.supplement {
  font-size: max(80%, 0.7rem);
  margin: auto -0.1em;
}
.supplement--no-kerning {
  font-size: max(80%, 0.7rem);
  margin: 0;
}

.note {
  font-size: 70%;
  text-indent: -2em;
  padding: 1em 1.5em;
  padding-left: 3.5em;
  margin: 0.5em 0 1em;
  border: solid 1px hsla(0, 0%, 70%, 0.5);
  border-radius: 0.5em;
}
.note::before {
  content: "注：";
}

.event-date {
  display: block;
  text-align: right;
  margin: 0.5em 0 1em;
  font-size: 90%;
  line-height: 1.25;
}
.event-date time {
  display: block;
}

.change-theme-button, .accordion label, .button-like-anchor {
  cursor: pointer;
  align-items: center;
  background-color: var(--color-button-background);
  border: solid 1px currentColor;
  color: var(--color-button-content);
  display: flex;
  justify-content: center;
  margin: 0.5em auto;
  padding: 0.75em 1.5em;
  text-decoration: none;
  transition: background 0.3s var(--ease-out), color 0.3s var(--ease-out);
  width: -moz-fit-content;
  width: fit-content;
}
@media (hover: hover) {
  .change-theme-button:hover, .accordion label:hover, .button-like-anchor:hover {
    background-color: var(--color-button-background-hover);
    color: var(--color-button-content-hover);
  }
}
.change-theme-button:active, .accordion label:active, .button-like-anchor:active {
  transition: background 0s, color 0s;
  background-color: var(--color-button-background-active);
  color: var(--color-button-content-active);
}
.change-theme-button:focus, .accordion label:focus, .button-like-anchor:focus {
  outline-offset: 0.25rem;
}

@media (hover: hover) {
  .dark .change-theme-button:hover, .dark .accordion label:hover, .accordion .dark label:hover, .dark .button-like-anchor:hover {
    color: var(--color-button-content-hover);
  }
}
.dark .change-theme-button:active, .dark .accordion label:active, .accordion .dark label:active, .dark .button-like-anchor:active {
  transition: background 0s, color 0s;
  color: var(--color-button-content-active);
}

.button-like-anchor {
  margin: 0.5em -1rem 0.5em auto;
}
.button-like-anchor::after {
  border: solid 0.25em transparent;
  border-right-color: currentColor;
  border-top-color: currentColor;
  content: "";
  display: block;
  margin-left: 0.5em;
  transform: scaleX(1.5) rotate(45deg);
}

.subsection {
  padding-left: 1em;
}

.color-picker-example {
  display: flex;
  justify-content: center;
  margin: 2em 0;
}

.accordion {
  margin: 1em 0;
}
.accordion input {
  all: revert;
}
.accordion label {
  display: flex;
  flex-direction: column;
  outline: solid 2px transparent;
  outline-offset: 0.25rem;
}
.accordion label > span {
  display: inline-block;
  width: 100%;
  text-align: center;
}
.accordion label > span:last-of-type {
  visibility: hidden;
  height: 0;
}
.accordion label:has(input:checked) > span:last-of-type {
  visibility: visible;
  height: auto;
}
.accordion label:has(input:checked) > span:first-of-type {
  visibility: hidden;
  height: 0;
}
.accordion label:has(input:focus-visible) {
  outline-color: var(--color-content);
}
.accordion__container {
  display: grid;
  grid-template-rows: 0fr;
  position: relative;
  transition: grid-template-rows 0.5s var(--ease-out);
}
.accordion__container::after {
  content: "";
  display: block;
  height: 3em;
  width: 100%;
  background: linear-gradient(to bottom, var(--color-content), transparent);
  position: absolute;
  top: 0;
  z-index: -1;
  transition: opacity 0.5s var(--ease-out);
}
.accordion__container:has(~ * > input:checked) {
  grid-template-rows: 1fr;
}
.accordion__item {
  overflow: hidden;
  height: 100%;
}

.sample {
  border: solid 1px hsla(0, 0%, 50%, 0.5);
  padding: 1rem;
  margin-bottom: 1rem;
}
.sample__h1 {
  margin: 0.5rem 0;
}
.sample__h1::before {
  display: none;
}

.error {
  background-color: hsla(350, 100%, 80%, 0.2);
  font-size: 85%;
  padding: 1em 1.25em;
  border-radius: 0.5em;
  text-indent: 0;
  margin: 1rem 0;
}
.error::before {
  content: "エラー内容：";
  font-weight: bold;
}

.important {
  display: block;
  background-color: hsla(210, 100%, 85%, 0.2);
  padding: 1em 1.25em;
  text-indent: 0;
  border-radius: 0.5em;
  margin: 0.5rem 0;
}

.math {
  margin-inline: 0.25em;
  font-family: serif;
}

.change-theme-button {
  position: fixed;
  top: clamp(1rem, 2vw, 2rem);
  right: clamp(0.75rem, 2vw, 2rem);
  z-index: 1000;
  width: 2.25em;
  height: 2.25em;
  border-radius: 50%;
  box-shadow: 0 0 0.1rem currentColor;
  border: none;
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 0;
  padding: 0;
  cursor: pointer;
  transition: background-color 0.3s var(--ease-out), color 0.3s var(--ease-out);
}
@media (hover: hover) {
  .change-theme-button:hover .theme-icon--dark {
    filter: invert(0);
  }
  .change-theme-button:hover .theme-icon--light {
    filter: invert(1);
  }
}
.change-theme-button:active .theme-icon--dark {
  filter: invert(0);
}
.change-theme-button:active .theme-icon--light {
  filter: invert(1);
}

.theme-icon {
  width: 1rem;
  height: 1rem;
  display: inline-block;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  transition: filter 0.3s var(--ease-out);
}
.theme-icon--light {
  background-image: url("./image/icon-theme-light.svg");
}
.theme-icon--dark {
  background-image: url("./image/icon-theme-dark.svg");
  filter: invert(1);
}

.github-code-button {
  display: inline-flex;
  align-items: center;
  background-color: #238636;
  border: solid 1px rgba(255, 255, 255, 0.1490196078);
  border-radius: 0.5em;
  color: white;
  line-height: 1;
  font-weight: 500;
  font-size: 14px;
  padding: 0.6em 1.1em 0.6em 0.8em;
  margin-inline: 0.5em;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
}
@media (min-width: 540px) {
  .github-code-button::before {
    display: inline-block;
    content: "";
    width: 1.1em;
    height: 1.1em;
    background-image: url("./image/github-code-icon.svg");
    background-size: cover;
    background-repeat: no-repeat;
  }
}
.github-code-button::after {
  display: inline-block;
  content: "";
  border: solid 0.3em transparent;
  border-top-color: white;
  transform: translateY(0.2em);
  margin-left: 0.7em;
}

.vscode-button, .vscode-button--small {
  font-family: Segoe WPC, Segoe UI, -apple-system, sans-serif;
  background-color: #0078d4;
  color: white;
  font-size: 14px;
  padding: 0.4em 0.6em;
  border-radius: 0.2em;
  margin-inline: 0.25em;
}
.vscode-button--small {
  font-size: 14px;
  padding: 0.15em 0.5em;
}

@font-face {
  font-family: "SF Mono";
  font-weight: 400;
  src: local("SF Mono"), url("./fonts/SF-Mono-Regular.otf") format("opentype");
}
@font-face {
  font-family: "SF Mono";
  font-weight: 700;
  src: local("SF Mono Bold"), url("./fonts/SF-Mono-Bold.otf") format("opentype");
}
:root {
  font-feature-settings: "liga" 1, "calt" 1; /* fix for Chrome */
}

/* @supports (font-variation-settings: normal) {
  :root {
    font-family: InterVariable, sans-serif;
  }
} */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  word-break: auto-phrase;
  overflow-wrap: break-word;
  text-spacing-trim: trim-start;
}

.dark {
  --color-content: hsl(0 0% 90%);
  --color-background: hsl(0 0% 0%);
  --color-button-background: var(--color-background);
  --color-button-content: var(--color-content);
  --color-button-content-hover: var(--color-background);
  --color-button-background-hover: var(--color-content);
  --color-button-content-active: var(--color-background);
  --color-button-background-active: hsl(0 0% 75%);
}
.dark a {
  color: hsl(210, 100%, 70%);
}
.dark .button-like-anchor {
  color: var(--color-content);
}