

:root{
  --key-color: #999999;
  --dark-color: #333333;
  --column1-1-color100: #a5b50f;
  --column1-1-color: #c7d53d;
 	--footnote-bg: #383838;
  margin: 0;
  padding: 0;
}


html{font-size: 16px;}

body{
  font-family: sans-serif;
  line-height: 1.8;
  padding: 20px;
  max-width: 840px;
  margin: 0 auto;
  font-size: 0.9rem;
  color: #333;
  background-color: #f9f9f9;

  h1{font-size: 1.4rem;}

  :where(section.contents){
    height: 100vh;
    min-height: 66vh;
  }

  h2{font-size: 1rem;}
  &:has(span[style="anchor-name: --n1"]:hover) .footnote[style= "position-anchor: --n1"],
  &:has(span[style="anchor-name: --n2"]:hover) .footnote[style= "position-anchor: --n2"],
  &:has(span[style="anchor-name: --n3"]:hover) .footnote[style= "position-anchor: --n3"]
  {
    position: fixed;/* 親子関係じゃないのでfixedを使用 */
    top: calc(4px + anchor(bottom));
    left: anchor(left);
    position-try-fallbacks:flip-inline;

    /* デザイン */
    display: inline-block;
    max-width: 280px;
    min-width: 120px;
    padding: 1rem;
    color: #fff;
    background: #383838;
    border-radius: .3rem;
    box-shadow: 0 .3rem 1rem rgb(0 0 0 / .2);
    z-index: 100;
    box-sizing: border-box;

    b{display: block;}
  }
  
}

&:has(span[style="anchor-name: --n1"]:hover) .ft_arrow[style= "position-anchor: --n1"],
&:has(span[style="anchor-name: --n2"]:hover) .ft_arrow[style= "position-anchor: --n2"],
&:has(span[style="anchor-name: --n3"]:hover) .ft_arrow[style= "position-anchor: --n3"]
{
  position: fixed;/* 親子関係じゃないのでfixedを使用 */
  top: calc(anchor(bottom) - 8px);
  left: calc(.6rem + anchor(left));
  position-try-fallbacks:flip-inline;
  transform: unset;
  border-bottom-color: var(--footnote-bg);
  border-left-width: 12px;
  border-right-width: 12px;
}

  
.anchor-note {
  color: #06c;
  text-decoration: underline;
  text-decoration-style: dotted;
  text-decoration-color: currentColor;
  text-decoration-thickness: .08em;
  text-underline-offset: .18em;
  cursor: help;
  /* 改行挟んだときに見栄えを維持するお守り */
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

.endnote{
  position: fixed;
  left: 0;
  bottom: 0px;
  width: 100vw;
  padding: 20px;
  background: #e6e6e6;
  .footnote{
    display: block;
    b{display: inline-block;}
  }
  box-sizing: border-box;
}

/* 追加 */

.ft_arrow{
  content: '';
  display: inline-block;

  margin-left: -8px;
  width: 0;
  border-top: 6px solid transparent;
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
  border-bottom: rgb(17, 100, 177) solid 10px;
  height: 0;
  transform: rotate(90deg);
  position: relative;
  bottom: -4px;
  left: 4px;
}








