/* Variables */
:root {
  --header-link-color: #6e2700;
  --link-color: #923200;
  --link-color-lighten: #be7d5a;
  --link-color-lighter: #e5c9ba;
  --highlight: #E97B30;
  --highlight-lighten: #f8ceb2;
  --highlight-lighter: #f8e2d3;
  --warning-color-light: rgb(255, 227, 219);

  --positive-color: rgb(87, 134, 10);
  --negative-color: #af1d0a;

  --info-yellow: rgb(255, 238, 0);
  --info-yellow-lighten: rgb(247, 218, 165);

  --dark: #2f2c25;
}

/*-----------*/

body.template {
  background-color: #FFF;
  color: #000;
}

* {
  font-family: sans-serif;
  font-size: 12pt;
}

.hider {
  display: none;
}

a {
  color: var(--link-color);
}

h1, h4, h5 {
  font-family: "bezumnoe-neue";
  font-weight: normal;
}

h2, h2 > * {
  font-size: 16pt;
}

h3 {
  font-size: 14pt;
}

h2, h3 {
  margin: 0;
  padding: 0;
  font-weight: 500;
}

h5 {
  font-size: 1.3rem;
  font-weight: bold;
  margin: 20px 0 0 0;
}

h6 {
  font-size: 1rem;
  font-weight: 100;
  margin: 10px 0 0 0;
}

li {
  padding: 0 0 6px 0;
}

button.btn-image {
  border: 0;
  outline: none;
  background-color: transparent;
  cursor: pointer;
  padding: 0;
}

.clean {
  margin-left: 0 !important;
  margin-right: 0 !important;
  padding-left: 0;
}

.mandatory:after {
  display: inline-block;
  position: relative;
  bottom: 8px;
  left: 2px;
  font-size: 0.5rem;
  color: var(--negative-color);
  content: "★";
}

.errors {
  border: solid 1px red;
  color: red;
  background-color: var(--warning-color-light);
  border-radius: 6px;
  margin-bottom: 10px;
  padding: 8px;
  font-size: 0.9rem;

  ul {
    margin: 0;
    padding-left: 20px;

    li:last-child {
      padding-bottom: 0;
    }
  }
}

.errors:empty {
  display: none;
}

span.count {
  display: inline-block;
  border-radius: 8px;
  padding: 0px 6px;
  background-color: var(--link-color-lighten);
  color: #FFF;
  font-weight: bold;
  font-size: 60%;
}

cite {
  display: block;
  padding: 8px;
  background-color: rgba(0, 0, 0, 0.07);
  border-left: solid 1px #AAA;
}

.tip {
  font-style: italic;
  font-weight: 200;
}

.top {
  width: 80vw;
  margin: 0 auto;
  min-height: 200px;
}

.top > header {
  display: flex;
  flex-direction: row;
  margin-top: 15px;
  padding: 0 50px;
}

header > * {
  align-self: center;
}

header > h1 {
  flex: 1 1 50%;
  text-align: left;
  font-size: 3vw;
  padding-left: 10px;
  font-weight: normal;
  margin: 0;
}

header > a {
  flex: 1 1 5vw;
  border: 0;
  min-width: 30px;
}

header > a img {
  width: 100%;
}

header > div {
  flex: 1 1 50%;
  text-align: right;
}

.sub-header {
  margin-top: 10px;
}

.logged {
  white-space: nowrap;
}

.logged u {
  display: inline-block;
  width: 20px;
  height: 20px;
  background: url("/img/icons/user-icon.png") no-repeat;
  background-size: contain;
  vertical-align: middle;
}

.top > .middle {
  display: flex;
  text-align: left;
  min-height: 500px;
}

.middle > .even {
  flex: 1 1;
}

.middle .tiny {
  flex: 0 0 50px;
}

.middle > .narrow {
  flex: 1 0 150px;
  padding: 0 15px 0 0;
}

.middle > .narrow.alt {
  flex: 1 0 300px;
  padding: 0 15px 0 0;
}

.narrow > div:nth-child(n + 2):before {
  content: "";
  display: block;
  height: 25px;
  background: url("/img/t/div1.svg") repeat-x top left;
}

.narrow > div:nth-child(2n):before {
  background: url("/img/t/div2.svg") repeat-x top left;
}

.divider {
  flex: 0 0 50px;
  background: url("/img/t/vline.svg") repeat-y top center;
}

.divider.horizontal {
  background: url("/img/t/hline.svg") no-repeat center;
  background-size: cover 100%;
  width: 100%;
  height: 18px;
}

.divider.horizontal.alt {
  background-image: url("/img/t/hline2.svg");
}

.divider.horizontal.dotted {
  background: url("/img/t/div1.svg") repeat-x;
  height: 40px;
}

.divider.horizontal.dotted.alt {
  background-image: url("/img/t/div2.svg");
}

.middle > .wide {
  flex: 8 0;
  padding: 0 16px;
  overflow-wrap: anywhere;
}

.wide h1 {
  font-size: 1.6vw;
}

.wide > div > a {
  text-decoration: none;
}

.wide > div.big:before {
  content: "";
  display: block;
  height: 40px;
  background: url("/img/t/div1.svg") repeat-x top left;
}

.wide > div.big.reverse:before {
  background: url("/img/t/div2.svg") repeat-x top left;
}

.wide > div.big > a img {
  float: left;
  margin: 0 10px 10px 0;
}

.wide > div.big.reverse > a img {
  float: right;
  margin: 0 0 10px 10px;
}

.wide > div > a h4 {
  color: var(--header-link-color);
  margin: 0;
  font-size: 28px;
  vertical-align: top;
  font-weight: bold;
}

.wide > div.big.reverse > a h4 {
  text-align: right;
}

.middle > .logo {
  flex: 1 0 200px;
  text-align: center;
  padding-top: 20px;
}

/* .logo > img {
  width: 25vw;
  max-width: 187px;
  margin-left: auto;
} */

.logo form {
  padding: 30px 2vw;
}

.logo label {
  display: flex;
  margin-bottom: 10px;
  text-align: left;
}

.logo label span {
  flex: 1 0 70px;
}

.logo label input {
  width: 100%;
  flex: 1 1 100%;
}

.logo button {
  border: none;
  background: none;
  outline: none;
  display: block;
  margin: 12px 0 0 64px;;
}

.logo nav ul {
  margin-bottom: 40px;
  padding-left: 0;
}

.logo nav ul li {
  list-style: none;
  font-weight: 600;
  line-height: 1.6;
}

.top > footer {
  text-align: center;
  padding-bottom: 20px;
  margin-top: 10px;
}

footer > nav {
  width: 70%;
  display: inline-block;
}

footer nav ul {
  padding: 0;
}

footer nav ul li {
  list-style: none;
  display: inline-block;
  border-left: solid 1px var(--link-color-lighter);
  padding: 0 8px;
}

footer nav ul li:first-child {
  border: none;
}

ul.pager {
  padding: 0;
  text-align: center;
}

ul.pager li {
  list-style: none;
  display: inline-block;
  border-left: solid 1px var(--link-color-lighter);
  padding: 0 8px;
}

ul.pager li:first-child {
  border: none;
}

/* Individual sections */

.online ul.random {
  padding-left: 0;
  margin-left: 0;
  font-weight: 500;
}

.online h6 span {
  color: #FFF;
  background-color: var(--link-color-lighten);
  border-radius: 8px;
  padding: 2px 6px;
  font-size: 0.7rem;
}

/*---------------------*/

.news ul {
  padding: 0;
}

.news ul li {
  list-style: none;
  margin-bottom: 20px;
}

.news ul li h6 {
  font-weight: 600;
  margin: 0 0 4px 0;
}

.news ul li h6 time {
  font-size: 0.7rem;
  font-weight: 100;
  display: block;
}

/*---------------------*/

.photos ul.random {
  padding-left: 0;
  margin-left: 0;
  font-weight: 500;
}

.photos .preview {
  text-align: center;
}

.photos .preview img {
  border: solid 4px var(--highlight);
  border-radius: 6px;
}

.photos .preview a {
  display: block;
}

/*---------------------*/

.birthdays ul {
  padding: 0;
}

/*---------------------*/

.newcomers ul {
  padding-left: 0;
}

/*---------------------*/

ul.new-comments {
  padding-left: 0;
}

ul.new-comments li ul {
  padding-left: 10px;
}

ul.new-comments li {
  list-style: none;
}

ul.new-comments li img {
  max-width: 100%;
  border: solid 6px var(--highlight);
  border-radius: 6px;
}

/*---------------------*/

ul.new_posts {
  padding-left: 10px;
}

ul.new_posts li a {
  font-weight: 100;
}

ul.new_posts li > a:first-child {
  font-weight: 600;
}

/*---------------------*/

.authenticated {
  border: solid 1px var(--link-color-lighten);
  background-color: var(--highlight-lighten);
  font-size: 0.8rem;
  padding: 10px;
  margin: 0 30px;
  text-align: center;
}

/*---------------------*/

li > div.button-on-right {
  display: inline-flex;
}

div.button-on-right {
  display: flex;
  align-items: center;

  h1, h2, h3, h5 {
    flex: 1 1 calc(100% - 150px);
    font-size: 16pt;
    font-weight: 500;
  }

  b {
    flex: 1 1;
    justify-self: right;
    font-weight: normal;

    button {
      background-color: #222;
      color: #FFF;
      border-radius: 6px;
      white-space: nowrap;
      padding: 4px 10px;
      cursor: pointer;
      transform: rotate(1deg);
    }
  }
}

button.new-thread {
  margin-top: 10px;
  float: right;
  border: 0;
  background-color: transparent;
  outline: none;
  cursor: pointer;
}

h2.forum.title a {
  font-size: 16pt;
  font-weight: 500;
}

ul.forum li a {
  font-weight: 500;
}

ul.forum li span {
  font-weight: 100;
  font-size: 90%;
}

ul.forum li.hidden a {
  font-weight: 100;
  text-decoration: line-through;
}

/*---------------------*/

ul.thread {
  padding-left: 0;
}

ul.thread li {
  list-style: none;
  margin-bottom: 10px;
}

ul.thread li.hidden {
  text-decoration: line-through;
  background-color: var(--warning-color-light);
}

ul.thread header {
  display: flex;
  background-color: rgba(0, 0, 0, 0.05);
  padding: 10px;
}

ul.thread header > a {
  flex: 0 0 64px;
  padding-right: 10px;
}

ul.thread header > a img {
  width: auto;
  max-width: 100%;
}

ul.thread header > div {
  text-align: left;
  padding: 0;
}

ul.thread header > div h3 {
  font-size: 14pt;
  font-weight: 500;
  margin-bottom: 4px;
}

ul.thread footer {
  text-align: right;
}

ul.thread footer > time {
  display: block;
  font-weight: 100;
  font-size: 90%;
  float: left;
}

ul.thread footer > button {
  margin-left: 10px;
  border: 0;
  background-color: transparent;
  outline: none;
  cursor: pointer;
  font-size: 90%;
}

/*---------------------*/
div#replyForm {
  background-color: #DDD;
  padding: 15px;
  margin-top: 15px;
}

div#replyForm label {
  margin-bottom: 10px;
}

div#replyForm label, div#replyForm label span {
  display: block;
}

div#replyForm input[type="text"], div#replyForm textarea {
  width: 100%;
  border: 0;
  padding: 0;
  outline: solid 1px #444;
}

/*---------------------*/

ul.new-comments {
  padding-left: 0;
}

ul.new-comments > li {
  list-style: none;
}

ul.new-comments > li ul {
  margin: 6px 0 10px 0;
}

ul.new-comments > li ul * {
  font-size: 0.95rem;
}

/*---------------------*/

.title-author > li {
  & > a:first-child {
    font-weight: 600;
  }

  & > a:nth-child(2), & > span:nth-child(2) {
    font-weight: 200;
  }

  & > a.Private {
    color: var(--highlight);
    font-weight: 200;
  }
}

/*---------------------*/

ol.rating {
  padding-left: 35px;
}

ol.rating.full {
  padding-left: 50px;
}

ol.rating li::marker {
  content: "+" counter(list-item) "  ";
  font-weight: 100;
}

ol.rating.full li::marker {
  content: counter(list-item) " ";
}

ol.rating.full li sup {
  display: inline-block;
  font-size: 0.8rem;
  width: 30px;
  font-weight: 600;
  color: var(--positive-color);
}

ol.rating.full li.negative sup {
  color: var(--negative-color);
}

/*---------------------*/

ul.socials {
  padding: 0;
  margin: 15px 0 0 0;
}

ul.socials * {
  vertical-align: top !important;
}

ul.socials li {
  list-style: none;
  display: inline-block;
  margin-right: 10px;
}

/*---------------------*/

div.authorship {
  text-align: right;
  font-style: italic;
}

div.authorship > time {
  font-weight: 100;
}

/*---------------------*/

#auth-form input {
  display: block;
  width: 100%;
  margin: 0 0 10px 0;
  padding: 0;
  border: 0;
}

/*---------------------*/

.register {
  form {
    display: block;
    width: 60%;
    min-width: 400px;
    margin: 0 auto;
  }

  label {
    margin-bottom: 15px;
  }

  label {
    &, input[type=text], input[type=password], input[type=password], input[type=range] {
      width: 100%;
      display: block;
    }

    div.test {
      position: relative;
      padding: 4px 0;

      input {
        background-color: transparent;
      }

      &::before {
        content: "";
        inset: 0 5px 0 9px;

        position: absolute;
        background-image: var(--bg);
        background-repeat: repeat-y;
        background-size: contain;
        z-index: -1;
      }
    }
  }

  .inline label {
    display: inline-block;
    width: auto;
  }

  button {
    border: 0;
    outline: none;
    background-color: transparent;
  }

  .buttons {
    text-align: center;

    &.black button {
      background-color: #000;
      color: #FFF;
      border-radius: 6px;
      padding: 4px 10px;
      margin: 0;
      border: solid 1px black;
    }
  }
}


/*---------------------*/

ul.galleries > li, ul.galleries > li > a {
  font-size: 1.1rem;
  font-weight: 500;
}

ul.galleries > li, ul.galleries > li > span:nth-child(2) {
  font-weight: 100;
}

.gallery.row {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
}

.gallery.row > figure {
  flex: 1 1 15%;
  justify-content: center;
}

.gallery.row > figure {
  text-align: center;
}

.gallery.row > figure img, .gallery-photo .wide img, .profiles .wide img {
  margin-bottom: 6px;
  border: solid 4px var(--highlight);
  border-radius: 6px;
}

.gallery-photo {
  display: flex;
  flex-direction: row;
}

.gallery-photo .tiny {
  align-self: center;
  font-size: 40pt;
}

.gallery-photo .tiny a {
  font-size: 20pt;
  text-decoration: none;
}

.gallery-photo .wide {
  flex-grow: 1;
  text-align: center;
}

.gallery-photo .wide img {
  text-align: center;
}

/*---------------------*/

.profiles button.btn-search {
  vertical-align: middle;
}

.profiles a.selected {
  color: #000;
  font-weight: 700;
}

.profiles .wide {
  text-align: center;
}

.profiles figure {
  margin: 0;
}

.profiles .wide {
  padding-top: 15px;
}

.profiles .wide figure:after {
  content: "";
  display: block;
  background: url("/img/t/div1.svg") repeat-x;
  width: 100%;
  height: 40px;
}

.profiles .wide figure:nth-child(even):after {
  background: url("/img/t/div2.svg") repeat-x;
}

.profiles .wide figure:last-child:after {
  background: none;
}

/*---------------------*/

.info {
  background-color: #000;
  color: #FFF;
  padding: 15px 25px 15px 15px;
}

.info a {
  color: var(--highlight);
}

.info > h1 {
  font-size: 32pt;
  margin: 0;
  color: var(--info-yellow);
}

.info > h6 {
  font-size: 0.9rem;
  color: var(--info-yellow-border);
}

.info dl {
  display: flex;
  flex-wrap: wrap;
  width: 80%;
  min-width: 500px;
  margin: 10px auto;
}

.info dl dt {
  flex: 1 1 170px;
  text-align: right;
  font-weight: 100;
  /* color: var(--info-yellow-lighten); */
}

.info dl dt:after {
  content: ":";
}

.info dl dd {
  flex: 2 1;
  min-width: 300px;
  margin-left: 20px;
}

.info ul {
  margin: 0;
}

.info ul li {
  list-style: none;
}

.info div.frame {
  display: flex;
  flex-wrap: wrap;
}

.info div.photo {
  flex: 1 0 400px;
}

.info div.data {
  flex: 4 1;
}

.info div.photo > img {
  border: solid 6px var(--highlight);
  border-radius: 6px;
  margin: 15px auto 5px auto;
  max-width: 100%;
  width: auto;
  display: block;
}

.info .thin {
  font-weight: 100;
  font-size: 0.8rem;
}

.info sup {
  font-size: 0.7rem;
  margin-left: 2px;
}

/*---------------------*/

#tree button {
  background-color: transparent;
  font-size: 9pt;

  position: absolute;
  display: block;

  border-radius: 6px;
  padding: 0px 5px;
  margin: 0;
  border: solid 1px black;

  white-space: nowrap;
  z-index: 10;
}

#tree p {
  position: absolute;
  padding: 0;
  margin: 0;
  font-size: 1px;
  line-height: 0;
  border: 0;
  background-color: #000;
}

#tree h4 {
  position: absolute;
  color: #F0F0F0;
  font-family: "bezumnoe2", "arial narrow", "arial";
  font-size: 120pt;
  z-index: -1;
  padding: 0;
  margin: 0;
}

/* Journal */
.wide.journal-post p img {
  max-width: 100% !important;
  height: auto !important;
}

/* Common */
ul.random {
  margin-left: 10px;

  & > li {
    --size: 0.3em;
    list-style: none;

    &:before {
      content: "";
      display: inline-block;
      width: var(--size);
      height: var(--size);
      background-color: var(--dark);
      vertical-align: middle;

      margin-right: 10px;
      clip-path: polygon(10% 0%, 100% 20%, 80% 100%, 0 90%);
    }

    &:nth-child(1),
    &:nth-child(4),
    &:nth-child(8),
    &:nth-child(13),
    &:nth-child(17),
    &:nth-child(24) {
      &:before {
        clip-path: polygon(30% 5%, 75% 20%, 100% 90%, 0 100%);
      }
    }

    &:nth-child(2),
    &:nth-child(6),
    &:nth-child(10),
    &:nth-child(14),
    &:nth-child(19),
    &:nth-child(21) {
      &:before {
        clip-path: polygon(0% 10%, 100% 0%, 80% 90%, 20% 100%);
      }
    }

    &:nth-child(3),
    &:nth-child(5),
    &:nth-child(11),
    &:nth-child(16),
    &:nth-child(20),
    &:nth-child(22) {
      &:before {
        clip-path: polygon(0% 20%, 80% 10%, 100% 70%, 20% 100%);
      }
    }

    &:nth-child(1),
    &:nth-child(4),
    &:nth-child(7),
    &:nth-child(10),
    &:nth-child(13),
    &:nth-child(16) {
      &:before {
        margin-left: 4px;
        margin-right: 12px;
      }
    }

    &:nth-child(2),
    &:nth-child(5),
    &:nth-child(8),
    &:nth-child(11),
    &:nth-child(14),
    &:nth-child(17) {
      &:before {
        margin-left: 6px;
        margin-right: 8px;
      }
    }
  }
}

ul.listed > li {
  display: inline-block;
  margin-bottom: 4px;
}

ul.listed > li:not(:last-child):after {
  content: ",";
  position: relative;
  right: 3px;
}


@font-face {
  font-family: "bezumnoe";
  font-style: normal;
  font-weight: normal;
  src: local("bezumnoe"), url("/fonts/bezumnoe.ttf") format("truetype");
}

@font-face {
  font-family: "bezumnoe-neue";
  /* src: url("/fonts/BezumnoeNeue-Regular.ttf") format("truetype"); */
  src: url("/fonts/BezumnoeNeue-Regular.woff") format("woff");
  font-style: normal;
  font-weight: normal;
}

@media screen {
  .narrow:not(.shown), .divider, .wide.hidden, .news, .birthdays, .photos {
    display: none;
  }
}

@media screen and (min-width: 900px) {
  .wide.hidden, .news, .photos, .divider {
    display: block;
  }
}

@media screen and (min-width: 440px) {
  .narrow, .birthdays, .divider.horizontal {
    display: block;
  }
}

@media screen and (min-width: 440px) {
  .narrow, .birthdays, .divider.horizontal, .divider.shown {
    display: block !important;
  }
}