body {
    margin: 0;
    padding: 2px;
    background-color: #ccc;
    font-family: Arial, Helvetica, sans-serif;
}
div#main {
    margin-top: 2px;
}
div.name.filtered {
    display: none;
}
.name-container.filtered {
    background-color: #ecc;
}
div.name {
    border: 2px solid black;
    display: inline-block;
    margin: 2px 0 2px 2px;
    background-color: white;
    border-radius: 5px;
    vertical-align: top;
    position: relative;
    min-height: 5em;
}
div.name-header {
    display: inline-block;
    vertical-align: top;
    max-width: 165px;
    border-right: 1px solid black;
    margin-right: -1px;
    padding-bottom: 0.5em;
}
div.category, div.place {
    width: 100%;
    font-size: 8pt;
    color: white;
    background-color: gray;
    margin: 0;
    border-bottom: 1px solid black;
}
.category-label, .place-label {
    padding-left: 2px;
}


div.name-id {
    position: absolute;
    bottom: 0;
    font-size: 8pt;
    padding: 0 4px 0 4px;
    color: gray;
    margin: -1px;
    border: 1px solid lightgray;
    border-bottom-color: black;
    border-left-color: black;
}
div.name-id > a {
    text-decoration: none;
    color: gray;
}
span.pin {
    padding-left: 1em;
}
div.name-header-top {
    padding: 0 1em;
}
div.name-header-top h2 {
    margin-top: 0.5em;
    margin-bottom: 0;
}
div.aka {
    padding-left: 1em;
    padding-bottom: 5px;
    text-indent: -1em;
    font-size: 90%;
}
.aka button {
    width: 2em;
    margin-right: 5px;
}
.aka a {
    /*white-space: nowrap;*/
}
.filter-pub {
    float: left;
    margin-left: 0.5em;
}
.kanji-alt {
    white-space: nowrap;
}
div.dates {
    font-style: italic;
}
div.name-header-middle {
    padding: 0 1em;
}
div.name-header-bottom {
    overflow-wrap: break-word;
    padding: 0 0.5em 0.5em 1.5em;
    text-indent: -1em;
}
.name div.name-header-bottom {
    padding-bottom: 1em;
}
div.name-header-bottom hr {
    width: 50%;
    border-style: solid;
    border-color: #ccc;
}
div.name-header-bottom ul {
    list-style-type: none;
    padding: 0;
    margin: 0 0 10px 0;
}
div.pubseal-refs {
    text-align: left;
}
div.pubseal-refs ul.refs {
    list-style-type: none;
    padding: 0;
    margin: 0 0 10px 0;
}
dl.pubseal-cf {
    text-align:left;
    font-size:80%
}
dl.pubseal-cf dd {
    margin-left: 0.5em;
    text-indent: -0.5em;
}
div.shapecodes {
    color: gray;
    font-size: 60%;
    text-align: right;
    padding-right: 5px;
}
a.outlink {
    padding-right: 13px;
    background-position: center right;
    background-repeat: no-repeat;
    background-image: url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 width=%2212%22 height=%2212%22%3E %3Cpath fill=%22%23fff%22 stroke=%22%2336c%22 d=%22M1.5 4.518h5.982V10.5H1.5z%22/%3E %3Cpath fill=%22%2336c%22 d=%22M5.765 1H11v5.39L9.427 7.937l-1.31-1.31L5.393 9.35l-2.69-2.688 2.81-2.808L4.2 2.544z%22/%3E %3Cpath fill=%22%23fff%22 d=%22M9.995 2.004l.022 4.885L8.2 5.07 5.32 7.95 4.09 6.723l2.882-2.88-1.85-1.852z%22/%3E %3C/svg%3E");
    /*font-size: 90%;*/
}
div.signature {
    border-left: 1px solid black;
    border-right: 1px solid black;
    margin-right: -1px;
    padding: 0.5em 0;
    display: inline-block;
    text-align: center;
    vertical-align: top;
}
div.sig-img-container {
    padding: 0 6px;
}
div.sig-kanji {
    display: inline-block;
    font-size: 20pt;
    width: 1em;
    line-height: 100%;
    margin-left: 0.25em;
    padding-top: 16px;
    padding-bottom: 0;
    font-family: "ヒラギノ角ゴ Pro W3", "Hiragino Kaku Gothic Pro", "游ゴシック体 Medium", "Yu GothicM", "メイリオ", "ＭＳ Ｐゴシック", "MS P Gothic", Arial, Helvetica, sans-serif;
    border-left: 1px solid lightgray;
    padding-left: 6px;
}
div.sig-text {
    padding: 0 7px;
}
div.sig-text hr {
    width: 50%;
}
div.sig-trans {
    font-size: 80%;
    color: gray;
    font-style: italic;
}
.sig-romaji {
    font-style: italic;
}
div.kanji-key {
    display: inline-block;
    vertical-align: top;
    font-size:48pt;
    width:1em;
    line-height:100%;
    padding-top: 16px;
    padding-bottom: 8px;
    font-family: "ヒラギノ角ゴ Pro W3", "Hiragino Kaku Gothic Pro", "游ゴシック体 Medium", "Yu GothicM", "メイリオ", "ＭＳ Ｐゴシック", "MS P Gothic", Arial, Helvetica, sans-serif;
}
div.kanji-full {
    display: inline-block;
    display: inline-block;
    font-size:20pt;
    width:1em;
    line-height:100%;
    padding-top: 16px;
    padding-bottom: 8px;
    padding-left: 5px;
    font-family: "ヒラギノ角ゴ Pro W3", "Hiragino Kaku Gothic Pro", "游ゴシック体 Medium", "Yu GothicM", "メイリオ", "ＭＳ Ｐゴシック", "MS P Gothic", Arial, Helvetica, sans-serif;
}
.romaji-full {
    font-style: italic;
}
.longkey {
    font-size: 80%;
}
hr { color: gray }
ul.links {
    padding-left: 1em;
    font-size: 90%;
}
.page-header {
    border: 2px solid black;
    border-radius: 5px;
    background-color: white;
    margin: 2px;
    padding: 0 0 0 1.5em;
    /*min-width: 700px;*/
}

.name-container > .page-header {
    height: 80px;
}
.page-header {
    min-height: 80px;
}

div.about-container {
    border: 2px solid black;
    margin: 2px;
    background-color: white;
    border-radius: 5px;
    padding: 0.5em 1.5em;
    padding-bottom: 1em;
}
.page-header > h1 {
    margin-bottom: 0;
}
.name-container > .page-header > h1 {
    display: inline-block;
    float: left;
}
.page-header > h3 {
    margin-top: 0;
}
span.changes-container {
    display: inline-block;
    float: right;
    text-decoration: none;
    position: absolute;
    right: 16px;
    top: 68px;
    font-size: 10px;
}
.filter-group {
    margin: 0;
    padding: 0;
}
.filter-container {
    display: inline-block;
    vertical-align: middle;
    padding: 10px;
    border: 2px solid black;
    border-radius: 5px;
    background-color: white;
    margin: 4px 0 2px 2px;
    height: 5.5em;
}
.filter-container.pubseals {
    height: 3.5em;
}
#filter-reset {
    display: inline-block;
    vertical-align: middle;
    font-size: 120%;
    padding: 3px 14px;
    height: 5.5em;
    border-radius: 5px;
    background-color: white;
    margin: 4px 0 2px 4px;
    border: 2px solid black;
}
#filter-reset.pubseals {
    height: 3.5em;
}
#filter-reset button {
    margin: 3.5em 0;
}
button:hover {
    background-color: #eee;
}
.filter-line-1 {
    white-space: nowrap;
    font-size: 120%;
}
.filter-line-1 input {
    font-size: 120%;
}
.filter-line-2 {
    white-space: nowrap;
    margin: 6px 0;
}
#filter-radical {
    font-size: 120%;
}
#filter-char {
    font-size: 120%;
    width: 1em;
}
.filter-example {
    font-style: italic;
    color: #777;
    text-align: right;
}
button {
    width: 100%;
}
form {
    margin: 0;
    padding: 0;
}
.sig-source {
    font-size: 80%;
}
.acc {
    font-family: monospace, monospace;
}
.sig-note {
    color: gray;
    font-size: 90%;
}
.sig-cf {
    color: gray;
    font-size: 70%;
}
.sig-cf a {
    text-decoration: none;
}
.sig-seal {
    color: gray;
    font-size: 90%;
}
.sig-seal-ja {
    white-space: nowrap;
}
.sig-seal-ro {
    font-style: italic;
}
.name-note {
    color: gray;
    font-size: 90%;
}
div.research {
    font-size: 80%;
    position: absolute;
    bottom: 2px;
    left: 9em;
    text-align: right;
}
.refs {
    font-size: 80%;
}
.refs a {
    text-decoration: none;
    color: black;
}

.bib-source {
    padding-bottom: 0.5em;
    padding-left: 2.5em;
    text-indent: -2em;
}
.bib-source span {
    padding-right: 0.3em;
}
.bib-title {
    font-style: italic;
}
.bib-extra {
    font-weight: bold;
}
table.sigsrc td {
    padding: 2px 8px;
}
table.sigsrc td:first-child {
    font-weight: bold;
}

div.about-container dt {
    font-weight: bold;
}
div.about-container dd {
    display: list-item;
    list-style-type: disc;
}

/* styles for genshoku.html */
.genshoku table {
    font-size: 16pt;
    white-space: nowrap;
    border-collapse: collapse;
    display: block;
    overflow-x: auto;
    border-top: 2px solid black;
    margin-top: 8px;
}
.genshoku tr.section-top {
    border-top: 1px solid #bbb;
}
.genshoku tr.section-top.dark {
    border-top: 1px solid #bbb;
}
.genshoku tr {
    border-top: 1px solid #e8e8e8;
}
.genshoku tr.dark {
    border-top: 1px solid #d8e8d8;
}
.genshoku th {
    padding: 0 0.5em;
}
.genshoku td {
    padding: 0 0.5em;
}


/* primary name */
.genshoku th:nth-child(3) {
    text-align: right;
    padding-right: 0.5em;
}
.genshoku td:nth-child(3) {
    text-align: right;
}

/* hiragana */
.genshoku td:nth-child(5) {
    font-size: 80%;
}

/* ref */
.genshoku td:nth-child(6) {
    font-style: italic;
    font-size: 80%;
    color: #aaa;
}
.genshoku td:nth-child(6) a {
    color: #aaa;
}

/* other names */
.genshoku td:nth-child(7) {
    white-space: normal;
}

.genshoku td .other {
    white-space: nowrap;
}
.genshoku thead {
    text-align: left;
}
.dark {
    background-color:#efe;
}
.main {
    font-size: 120%;
}
div.subhead {
    padding: 16px 16px 12px 24px;
    font-family: Arial, Helvetica, sans-serif;
}
div.subtitle {
    font-size: 24pt;
}
.genshoku a {
    color:black;
    text-decoration:none;
}
div.genshoku-container {
    border: 2px solid black;
    margin: 2px;
    background-color: white;
    border-radius: 5px;
    padding: 0;
}
/* c/p/m/ rule... needs cleanup */
.genshoku > .page-header {
    height: 80px;
}

/* styles for marks.html */
.marks .info a {
    color: revert;
    text-decoration: revert;
}
.marks div.info {
    margin-top: 5px;
}

.marks table.marks {
    font-size: 16pt;
    white-space: nowrap;
    border-collapse: collapse;
    display: block;
    overflow-x: auto;
    border-top: 2px solid black;
    margin-top: 8px;
}
.marks tr.section-top {
    border-top: 1px solid #bbb;
}
.marks tr.section-top.dark-main {
    border-top: 1px solid #bbb;
}
.marks tr.section-top.dark-unknown {
    border-top: 1px solid #bbb;
}
.marks tr {
    border-top: 1px solid #e8e8e8;
}
.marks tr.dark-main {
    border-top: 1px solid #d8e8d8;
    background-color: #efe;
}
.marks tr.dark-unknown {
    border-top: 1px solid #d8e8d8;
    background-color: #fee;
}
.marks th {
    padding: 0.25em 0.5em 0.25em 0.5em;
}
.marks td {
    padding: 0.1em 0.5em 0.1em 0.5em;
}

.marks td.light {
    background-color: white;
}
.marks td.dark-main {
    background-color: #efe;
}
.marks td.dark-unknown {
    background-color: #fee;
}
.marks td.num {
    text-align: right;
    font-size: 90%;
}
.marks td.page {
    border-right: 1px solid #d8e8d8;
    padding-right: 0.75em;
}
.marks td.alt-roma {
    border-left: 1px solid #d8e8d8;
}
.marks td.gudj {
    border-left: 1px solid #d8e8d8;
    font-size: 80%;
    /*text-align: right;*/
}
.marks td.gudj a {
    color: blue;
}
.marks td.note {
    font-style: italic;
    font-size: 80%;
    color: #888;
}
.marks td.ro-main {
    font-size: 90%;
}
.marks td.related-ro {
    font-size: 80%;
}
.marks td.related-ja {
    font-size: 90%;
}
.marks td.seals {
    border-left: 1px solid #d8e8d8;
    font-size: 80%;
}

.marks thead {
    text-align: left;
}
.marks a {
    color:black;
    text-decoration:none;
}
div.marks-container {
    border: 2px solid black;
    margin: 2px;
    background-color: white;
    border-radius: 5px;
    padding: 0;
}
/* c/p/m/ rule... needs cleanup */
.marks > .page-header {
    height: 80px;
}

table.reader {
    font-size: 14pt;
}

ul.indicies {
    font-size: 120%;
    line-height: 150%;
    list-style-type: none;
    padding-left: 0;
    margin-left: 0;
}

ul.indicies li {
    padding: 0.2em 0;
}

ul.indicies dl dd {
    padding-left: 2em;
    text-indent: -2em;
}

@font-face {
    font-family: "hentaigana";
    src: url("Uni1B000Historickana-0075.ttf") format('ttf');
}

.hentaigana {
    font-family: hentaigana;
}

a.xref {
    text-decoration: none;
    /* color: black; */
}

div.gallery-container {
    border: 2px solid black;
    margin: 2px;
    /*background-color: #888;*/
    background-color: white;
    border-radius: 5px;
    padding: 0.5em;
    padding-bottom: 1em;
}

.gallery-container .record {
    display: inline-block;
    background-color: white;
    /*width: 250px;*/
    vertical-align: top;
    border-bottom-right-radius: 5px;
    border-bottom-left-radius: 5px;
    /*border: 1px solid black;*/
    margin: 6px;
}
/*
.gallery-container .record.cnt-2 {
    width: 507px;
}
.gallery-container .record.cnt-3 {
    width: 507px;
}
*/
.record .thumbnail {
    display: inline-block;
    /*width: 100%;*/
    max-height: 400px;
}
/*
.record .thumbnail.cnt-2 {
    width: 50%;
}
.record .thumbnail.cnt-3 {
    width: 33.33333%;
}
*/

.record .thumbnail img {
    max-width: 100%;
    max-height: 100%;
    vertical-align: bottom;
    object-fit: scale-down;
}
.record .description {
    padding: 0.5em;
    /*border-top: 1px solid #ccc;*/
    color: #b81d28;
    /*font-style: italic;*/
}
.record .description > a {
    text-decoration: none;
    color: inherit;
}
.record .metadata {
    padding: 0.5em;
}
.record .title-en, .series-en, .title-ro, .series-ro {
    font-style: italic;
}
.record .date {
    text-indent: -1em;
    margin-left: 1em;
}

.object-title {
    color: #b81d28;
    font-size: 140%;
    margin: 1em 0;
}
.title-en {
    font-style: italic;
}
.title-ro {
    font-style: italic;
}
.title-ja {
    white-space: nowrap;
}
.title-ja-container {
    margin-top: 0.5em;
}

.meta-block {
    margin-top: 0.75em;
}
.meta-block-header {
    font-size: 120%;
    font-weight: bold;
    text-transform: uppercase;
}
.meta-block-image {
    display: inline-block;
    padding-left: 0.3em;
    margin: 0.2em 0;
    vertical-align: bottom;
}
.meta-block-text {
    display: inline-block;
    width: 50%;
    margin: 0.5em;
}
.meta-block-text .object-title {
    font-size: 110%;
}
.meta-block-record {
    padding-left: 0.3em;
    margin: 0.2em 0;
}
.meta-block-record:nth-child(2) {
    margin-top: 0.3em;
}
.meta-block-record:last-child {
    margin-bottom: 0.3em;
}
.cf-note {
    font-style: italic;
}
.meta-literal {
    font-style: italic;
}
.main-image-container {
    padding: 1em;
}
.main-image {
    display: block;
    margin-left: auto;
    margin-right: auto;
}
.metadata-container {
    padding: 1em 2em;
}
.metadata-artist-pub-date {
    font-size: 115%;
}

.metadata-container hr {
    margin: 1.5em 0;
}

.cached-image-container {
    font-size: 80%;
}

.seal-dates {
    font-size: 80%;
}

/* menubar styling: adapted from "Simple Responsive Menu" */
/* http://cssmenumaker.com/menu/simple-responsive-menu*/
#cssmenu {
  background: white;
  width: auto;
  border: 2px solid black;
  margin: 2px;
  border-radius: 5px;
}
#cssmenu ul {
  list-style: none;
  margin: 0;
  padding: 0;
  line-height: 1;
  display: block;
  zoom: 1;
}
#cssmenu ul:after {
  content: " ";
  display: block;
  font-size: 0;
  height: 0;
  clear: both;
  visibility: hidden;
}
#cssmenu ul li {
  display: inline-block;
  padding: 0;
  margin: 0;
}
#cssmenu.align-right ul li {
  float: right;
}
#cssmenu.align-center ul {
  text-align: center;
}
#cssmenu ul li a {
  color: #888;
  text-decoration: none;
  display: block;
  padding: 15px 25px;
  font-family: 'Open Sans', sans-serif;
  font-weight: 700;
  text-transform: uppercase;
  font-size: 14px;
  position: relative;
  -webkit-transition: color .25s;
  -moz-transition: color .25s;
  -ms-transition: color .25s;
  -o-transition: color .25s;
  transition: color .25s;
}
#cssmenu ul li a:hover {
  color: #333333;
}
#cssmenu ul li a:hover:before {
  width: 100%;
}
#cssmenu ul li a:after {
  content: "";
  display: block;
  position: absolute;
  right: -3px;
  top: 19px;
  height: 6px;
  width: 6px;
  background: #ffffff;
  opacity: .5;
}
#cssmenu ul li a:before {
  content: "";
  display: block;
  position: absolute;
  left: 0;
  bottom: 0;
  height: 3px;
  width: 0;
  background: #333333;
  -webkit-transition: width .25s;
  -moz-transition: width .25s;
  -ms-transition: width .25s;
  -o-transition: width .25s;
  transition: width .25s;
}
#cssmenu ul li.last > a:after,
#cssmenu ul li:last-child > a:after {
  display: none;
}
#cssmenu ul li.active a {
  color: #333333;
}
#cssmenu ul li.active a:before {
  width: 100%;
}
#cssmenu.align-right li.last > a:after,
#cssmenu.align-right li:last-child > a:after {
  display: block;
}
#cssmenu.align-right li:first-child a:after {
  display: none;
}
@media screen and (max-width: 768px) {
  #cssmenu ul li {
    float: none;
    display: block;
  }
  #cssmenu ul li a {
    width: 100%;
    -moz-box-sizing: border-box;
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
    border-bottom: 1px solid #fb998c;
  }
  #cssmenu ul li.last > a,
  #cssmenu ul li:last-child > a {
    border: 0;
  }
  #cssmenu ul li a:after {
    display: none;
  }
  #cssmenu ul li a:before {
    display: none;
  }
}
