/* how to use for hiccup by input

    [:div {:class "openbox"}
     [:label {:for 1 :class "openboxsw"}
      [:div "label"]]
     [:input {:id 1 :class "inputcss" :type "checkbox"}]
     [:span {:class "boxshow"}
      [:div "hidden text"]]]
*/

/*

*/


.openbox input[type="checkbox"] {
    display: none; /* チェックボックスを隠す */
}
.openbox .boxshow {
    height: 0;
    opacity: 0; /* 折り畳んだ時に中を透明にする */
    display: none;/* 閉じた時に中身の要素をなくす */
}
.inputcss:checked + .boxshow {
    height: auto;
    opacity: 1; /*クリックやタップで中を表示させる*/
    display: block;/* 折り畳みになるように */
    border: solid 1px #f9fbba;
    background: white;
}
label.openboxsw {
    display: block;
    background: #f9fbba;
    padding: 3px 3px;
}
div.menu {
    font-size: 12px;
    padding: 3px 20px;
}
div.type {
    font-size: 10px;
    padding: 3px 5px;
}


.accordion  {
  margin: 30px auto;
}

.accordion_title {
  position: relative;
  border: none;
  display: block;
  list-style: none;
  width: 100%;
  cursor: pointer;
  background: #ffffff;
  border: 2px solid #d8d8d8;
  padding: 1.4em 1.6em 1.4em;
  line-height: 1.6em;
}

summary.accordion_title::-webkit-details-marker {
  display:none;
}

.accordion_title:after {
  content: "+";
  position: absolute;
  top: calc(50% - 0.5em);
  right: 20px;
  line-height: 1;
  padding: 0;
  pointer-events: none;
}

.accordion::details-content {
  opacity: 0;
  block-size: 0;
  transition: .3s;
  transition-property: display, opacity, block-size, padding;
  transition-behavior: allow-discrete;
  line-height: 1.6em;
}


.accordion .accordion_content {
  padding: 0 2em 0 3em;
}

.accordion .accordion_content > *:first-of-type {
  margin-top: 0;
}

.accordion .accordion_content > *:last-of-type {
  margin-bottom: 0;
}

.accordion[open]::details-content {
  opacity: 1;
  block-size: auto;
  block-size: calc-size(auto, size);
}

.accordion[open] .accordion_content {
  padding: 1.4em 2em 1.4em 3em;
}

.accordion[open] .accordion_title:after {
  content: "-";
}
