.journal-sheet.pf2e-av .journal-page-content {
  /*General Dropshadow*/

  .shadow {
    filter: drop-shadow(-5px -5px 5px rgba(0, 0, 0, .40));
  }

  /*Code blocks*/

  code {
    justify-content: center;
    border: 2px solid var(--av-green);
    border-radius: 10px;
    background: rgba(75, 125, 0, .15);
    padding: 5px;
  }
  /*Separated Header*/
  div.split{
    display:flex;
    justify-content: space-between;
    margin: 0 5px;
  }
  /*Images and Image Variants*/

  figure {

    margin: 20px 20px 25px 20px;

    img {
      border: none;
    
    }

    &.flipx {
      transform: scaleX(-1);
    }

    &.head {
      margin: 10px 20px 25px 20px;
    }

    &.box {
      border: 2px solid var(--av-green);
      background: var(--av-green-light);
      border-radius: 10px;
    }

    &.right {
      float: right;
      margin: 0.25rem 0 0.25rem .5rem;

      figcaption {
        font-family: var(--main-font);
        font-size: var(--body-font-size);
        color: var(--av-green)
      }

    }

    &.flipx {
      transform: scaleX(-1);
    }

    &.left {
      float: left;
      margin: 0.25rem .5rem 0.25rem 0;
figure {
  figcaption {
    color: var(--av-green)
  }

  &.square {
    flex-basis: 150px;
  }
}
    }
  }

  img {

    //The light writer is a cutting edge invention, first created in Absalom in late 4721...
    &.light-writer {
      border-radius: 25px;
      filter: opacity(0.8) sepia(.9);
      transition: 0.5s;
    }

    &.light-writer:hover {
      border-radius: 25px;
      filter: opacity(0.8) sepia(0);
    }

    &.flipx {
      transform: scaleX(-1);
    }  
  
  }

  /* Lists */

  ul {
    font-family: var(--main-font);
    font-size: var(--body-font-size);
    margin: 5px 0 5px 0;
    padding: 0 0 0 10px;
    list-style: none;

    &.traits{
      list-style-type: none;
      display: flex;
      gap: 5px;
      line-height: initial;
      margin-bottom: 2px;

      li {
        border-left: 5px solid var(--av-gold);
        border-right: 5px solid var(--av-gold);
        background: var(--pf2e-red);
        color: white;
        padding: 3px 8px 2px 8px;
        text-transform: uppercase;
        font-family: 'Good OT Cond Bold', Serif;
        max-height: 24px;
        &.blue {
          background: #566193;
        }
        &.green {
          background: #3a7a58;
        }
        }
      }
  }

li {
  margin: 0 0 7px 0;
}

  dl {
    margin: 0px 10px;
    padding: 5px;
    background: var(--cora-blue);
    border-top: 2px solid var(--cora-blue-dark);
    border-bottom: 2px solid var(--cora-blue-dark);
    dt {
      color: var(--cora-blue-dark);
      font-family: var(--h2-font);
      font-size: var(--h3-font-size);
    }
    dd {

        color: black;
        line-height: 1.25rem;
        font-family: var(--main-font);
        font-size: .9rem;
      a.entity-link, a.entity-link.broken, a.content-link, a.inline-roll {
        font-weight: bold;
        font-size: 0.8rem;
        padding: 2px;
        background: var(--cora-blue-dark);
        color: var(--av-green-light);
        margin-right: 1px;
        border-color: var(--cora-blue);
        line-height: 0.8rem;
      }
    }
  }

  /* Tables */

  table {
    max-width: 95%;
    margin-left: auto;
    margin-right: auto;
    border: unset;
    font-size: .95rem;

    td, th {
      min-width: 10rem;
      padding-left: 0.5rem;
      padding-right: 0.5rem;
    }

    //Paizo Red Table Header
    th {
      text-align: left;
      font-family: 'Good OT Bold', serif;
      background: var(--pf2e-red);
      color: var(--av-white);
    }

    //Handle alternating colors to match Paizo styling
    tr {
      background: var(--av-table);
    }

    tr:nth-child(even) {
      background: var(--av-table-light);
    }
  }

  /* Special block just for the Advancement journal entry */
  section.advancement {
    display: flex;
    flex-direction: column;
    border-top: 2px solid var(--av-green);

    h2 {
      font-family: var(--h1-font);
      font-size: 4.5rem;
      color: var(--av-green-light);
      -webkit-text-stroke: 2px var(--av-green);
      padding: 20px;
      flex-basis: 100px;
      text-align: center;
    }

    article {
      display: flex;
      flex-direction: row;
      align-items: center;
      border-bottom: 2px solid var(--av-green);

      div {
        flex-basis: 75%;
      }
    }
  }
  /* Special blocks for Otari Locations */
  section {
    &.location-head {
      margin: 0 10px 15px 10px;
      border-bottom: 2px solid var(--av-green);
      header {
        display: flex;
        justify-content: space-between;
        }

      article {
        display: flex;
        justify-content: space-between;
        align-items: flex-end;
          p {
            margin: initial;
          }
      }
    }

    &.npc {
      display: flex;
      p.stats {
        color: var(--av-green);
        font-weight: bold;
        font-style: italic;
      }
      article {
        flex-basis: 80%
      }
    figure {
      margin: auto;
      display: block;
      figcaption {
        color: var(--av-green);
      }
    }
    }
  }
  /* Box-text callouts */
  .box-text {
    display: flex;
    border: 2px solid black;
    margin: 1rem;
    gap: 10px;
    &.instruction {
      display: block;
      width: 375px;
      height: max-content;
      background: url(./assets/sidebar-back.webp);
      background-size: calc(100% - 50px) calc(100% - 60px);
      background-repeat: no-repeat no-repeat;
      background-position: center;
      border-radius: 125px;
      padding: 0.5rem;
      font: var(--h2-font);
      color: var(--av-white);
      filter: drop-shadow(2px 2px 4px black);
      border: unset;
      scrollbar-color: var(--pf2e-gold);

      p {
        font-family: var(--narrative-font);
        text-align: justify;
        line-height: 1.1rem;
      }
    }
    > .box-border {
      min-height: 300px;
      background: url(./assets/sidebar-top.webp), url(./assets/sidebar-bottom.webp);
      background-repeat: no-repeat, no-repeat;
      background-position: right top, bottom left;
      background-size: 97% 210px, 97% 210px;
      padding: 2.5rem;
      > .box-content {
        min-height: 220px;
        margin: 0.5rem 0.15rem 1rem;
        h2 {
          font-family: var(--h2-sidebar);
          font-size: var(--h2-sidebar-font-size);
        }
        > h1, h2, h3 {
          color: var(--av-white);
          margin-top: 0;
        }
      }
    }

    &.narrative {
      display: block;
      background: rgba(255, 255, 255, .4);
      box-shadow: 0 5px 13px -7px var(--color-shadow-dark);
      font-size: 1.10rem;
      font-family: var(--narrative-font);
      border-top: 2px ridge var(--av-green);
      border-bottom: 2px ridge var(--av-green);
      border-left: none;
      border-right: none;
      color: var(--av-green);
      //padding: 5px 10px 5px 5px;
      padding: .5rem;
      &.half {
        width: 50%;
      }

      &.first {
        margin-top: 0px
      }
    }

    /* Encounter Callout */

    &.encounter {
      display: block;
      border: 2px solid black;
      border-radius: 40px 8px 8px 8px;
      background: rgba(0, 0, 0, .15);
      header {
        position: relative;
        min-height: 80px;
        padding-left: 100px;
        color: white;
        background: url(./assets/green-back.webp);
        background-size: cover;
        border-bottom: 2px solid black;
        border-radius: 40px 6px 0 40px;

        img {
          height: 96px;
          width: 96px;
          position: absolute;
          left: -8px;
          top: -10px;
          border: none;
          filter: drop-shadow(2px 2px 4px black);
          object-fit: cover;
          border-radius: 50px;
        }

        h1, h2, p.pf2e-av-threat {
          font-family: var(--h2-font);
          font-size: var(--h2-font-size);
          color: white;
          margin: 0;
          padding: 0.5rem 0;
          text-transform: uppercase;
          line-height: initial;
        }

        section {
          display: flex;
          justify-content: space-between;
          padding-right: 20px;
        }
      }
      article {
        padding: 1rem 1rem 0.5rem;

        h3 {
          color: var(--pf2e-red);
          border-top: 2px solid var(--pf2e-red);
          margin: 0.5rem 0 0;
          padding-top: 0.5rem;

          &:first-child {
            margin-top: 0;
            padding-top: 0;
            border-top: none;
          }
        }
      }

      a.entity-link, a.inline-roll, a.content-link {
        background: var(--pf2e-red);
        border-color: var(--pf2e-gold);
        color: var(--av-green-light);
        padding: 2px;
        line-height: 0.8rem;
        font-weight: bold;

        i {
          color: var(--av-green-light);
        }
      }

      [data-pf2-repost], [data-pf2-check], [data-pf2-check]:not([data-pf2-show-dc=gm]), [data-pf2-effect-area]:not([data-pf2-show-dc=gm]) {
        background: var(--pf2e-red);
        border-color: var(--pf2e-gold);
        color: var(--av-green-light);
        padding: 4px 2px 2px 2px;
        line-height: 0.8rem;
        font-weight: bold;

        i {
          color: var(--av-green-light);
        }
      }
    }

    /* FVTT Instructional Callout*/

    &.fvtt {
      display: block;
      border: 2px solid black;
      border-radius: 40px 8px 8px 8px;
      box-shadow: 0 10px 13px -7px var(--color-shadow-dark);

      header {
        position: relative;
        min-height: 80px;
        padding-left: 100px;
        color: white;
        //noinspection CssUnknownTarget
        background: url("../../../ui/denim075.png") repeat;
        //background: linear-gradient(180deg, #ff6400 20%, #602600 100%);
        border-bottom: 2px solid black;
        border-radius: 40px 6px 0 40px;

        img {
          height: 96px;
          width: 96px;
          position: absolute;
          left: -8px;
          top: -10px;
          border: none;
          filter: drop-shadow(2px 2px 4px black);
        }

        h1, h2 {
          //color: white;
          margin: 0;
          padding: 0.5rem 0;
          margin: 0;
          padding: 0.5rem 0;
          color: #ff6400;
        }
      }

      article {
        padding: 1rem 1rem 0.5rem;

        h3 {
          color: var(--color-text-hyperlink);
          border-top: 2px solid var(--color-text-hyperlink);
          margin: 0.5rem 0 0;
          padding-top: 0.5rem;

          &:first-child {
            margin-top: 0;
            padding-top: 0;
            border-top: none;
          }
        }
      }

      a.entity-link, a.content-link, a.inline-roll {
        background: rgba(0, 0, 0, 0.5);
        border-color: black;
        color: white;
        text-decoration: none;
        padding: 2px;
        line-height: 0.8rem;
        font-weight: bold;

        i {
          color: white;
        }
      }

      [data-pf2-repost], [data-pf2-check], [data-pf2-check]:not([data-pf2-show-dc=gm]) {
        background: rgba(0, 0, 0, 0.5);
        border-color: black;
        padding: 4px 2px 2px 2px;
        line-height: 0.8rem;
        font-weight: bold;

        i {
          color: white;
        }
      }
    }

    /* Investigation Callout */

    &.investigation {
      display: block;
      border: 2px solid black;
      border-radius: 40px 8px 8px 8px;
      background: rgba(137, 149, 120, .25);

      header {
        position: relative;
        min-height: 80px;
        padding-left: 100px;
        color: white;
        background: url(./assets/green-back-light.webp);
        background-size: cover;
        border-bottom: 2px solid black;
        border-radius: 40px 6px 0 40px;

        img {
          height: 96px;
          width: 96px;
          position: absolute;
          left: -8px;
          top: -10px;
          border: none;
          filter: drop-shadow(2px 2px 4px black);
          object-fit: cover;
          border-radius: 50px;
        }

        h1, h2 {
          color: white;
          margin: 0;
          padding: 0.5rem 0;
        }
      }

      article {
        padding: 1rem 1rem 0.5rem;

        h3 {
          color: var(--av-green);
          border-top: 2px solid var(--av-green);
          margin: 0.5rem 0 0;
          padding-top: 0.5rem;

          &:first-child {
            margin-top: 0;
            padding-top: 0;
            border-top: none;
          }
        }
      }

      a.entity-link, a.inline-roll, a.content-link {
        background: var(--av-green);
        border-color: var(--av-green-light);

        i {
          color: var(--av-green-light);
        }
      }

      [data-pf2-repost], [data-pf2-check], [data-pf2-check]:not([data-pf2-show-dc=gm]) {
        background: var(--av-green);
        border-color: var(--av-green-light);

        i {
          color: var(--av-green-light);
        }
      }
    }

    &.treasure {
      display: block;
      border: 2px solid black;
      border-radius: 40px 8px 8px 8px;
      background: rgb(149 120 120 / 25%);
      header {
        position: relative;
        min-height: 80px;
        padding-left: 100px;
        color: white;
        background: url(./assets/red-back-light.webp);
        background-size: cover;
        border-bottom: 2px solid black;
        border-radius: 40px 6px 0 40px;

        img {
          height: 96px;
          width: 96px;
          position: absolute;
          left: -8px;
          top: -10px;
          border: none;
          filter: drop-shadow(2px 2px 4px black);
          object-fit: cover;
          border-radius: 50px;
        }

        h1, h2 {
          color: white;
          margin: 0;
          padding: 0.5rem 0;
        }
      }

      article {
        padding: 1rem 1rem 0.5rem;

        h3 {
          color: var(--pf2e-red);
          border-top: 2px solid var(--pf2e-red);
          margin: 0.5rem 0 0;
          padding-top: 0.5rem;

          &:first-child {
            margin-top: 0;
            padding-top: 0;
            border-top: none;
          }
        }
      }

      a.entity-link, a.inline-roll, a.content-link {
        background: var(--pf2e-red);
        border-color: var(--pf2e-gold);

        i {
          color: var(--av-green-light);
        }
      }

      [data-pf2-repost], [data-pf2-check], [data-pf2-check]:not([data-pf2-show-dc=gm]) {
        background: var(--paizo-blue-dark);
        border-color: var(--pf2e-gold);

        i {
          color: var(--av-green-light);
        }
      }
    }


    &.right {
      float: right;
      margin: initial;//0 0 1rem 1rem
    }

    &.left {
      float: left;
      margin: initial;//0 1rem 1rem 0rem;
    }

    > .box-content {
      min-height: 400px;
      max-height: 600px;
      margin: 2rem .75rem 3rem;
      padding-right: 1rem;
      overflow: hidden scroll;

      h2 {
        font-family: var(--h2-sidebar);
        font-size: var(--h2-sidebar-font-size);
      }

      > h1, h2, h3 {
        color: var(--av-white);
        margin-top: 0;
      }
    }

    ::-webkit-scrollbar-thumb {
      background: var(--av-gold-dark);
      border: 1px solid var(--av-gold);
    }

    /*img {
      max-width: 64px;
      max-height: 64px;
      border-radius: 12px;
      margin-top: 10px;
    }*/

    &.narrative {
      font-size: 1.10rem;
      font-family: var(--narrative-font);
      border-top: 2px ridge var(--av-tan);
      border-bottom: 2px ridge var(--av-tan);
      border-left: none;
      border-right: none;
      color: var(--av-tan);
      padding: 5px 10px 5px 5px;
      margin-right: 3%;
      margin-left: 3%;
    }

    /*&.location {

      flex-direction: column;

      .flexrow {
        display: flex;
        justify-content: space-between;
        border-bottom: 1px solid;

        :nth-child(even) {
          text-align: right;
        }
      }

      ul.traits {
        list-style-type: none;
        display: flex;
        margin: unset;
        padding: unset;
      }

      .subflex {
        display: flex;
        justify-content: space-between;
        align-items: flex-start;

        ul {
          flex-basis: 60%;
        }

        li {
          border-left: 5px solid var(--av-gold);
          border-right: 5px solid var(--av-gold);
          background: var(--pf2e-red);
          color: white;
          padding: 6px 8px 2px 8px;
          text-transform: uppercase;
          font-family: 'Good OT Cond Bold';
        }

        .p {
          flex-basis: 30%
        }
      }

      a.entity-link {
        font-weight: bold;
        line-height: unset;
        background: var(--pf2e-red);
        color: var(--av-gold);
        padding: 6px 4px 4px 4px;
        border: 2px solid var(--av-gold);

        i {
          color: var(--av-gold)
        }
      ;
      }
    }*/
  }

  /* Non-callout block quotes, for example the green text poem in Chapter 1 */

  blockquote {
    border: unset;

    p {
      font-family: 'Sabon LT', serif;

    }

    &.av-quote {
      color: var(--av-green);
    }
  }

  /* The former character-creation stylings from beginner box*/

  .compartment {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin: 1rem;
    article {
      background: var(--cora-blue);
      flex-basis: 49%;
      padding: 5px;
      border: 2px solid var(--cora-blue-dark);
      border-radius: 10px;
      margin-bottom: 5px;
      
      ul {
      font-weight: bold;
      font-size: .9rem;
      }

      &.full {
        flex-basis: 100%;
        ul {
          display: flex;
          flex-wrap: wrap;
          align-content: space-between;
        }
      }
      h1, h2, h3, h4 {
        color: var(--cora-blue-dark);
      }
      h3 {

        border-bottom: 3px dotted var(--cora-blue-dark);
        margin-bottom: 1rem;
        &.half {
          width:50%;
        }
        &.third{
          width:33%;
        }
      }
      h4 {
        font-family: var(--h1-font);
        color: var(--cora-blue-dark);
      }

      section {
        display: flex;
        justify-content: space-around;
        margin: 1rem 0;

        img {
          border: none;
          filter: drop-shadow(2px 4px 6px black);
        }

        font-family: var(--main-font);
        font-size: var(--body-font-size);

      }
    }
    .box-text{
      &.narrative{
        color: var(--cora-blue-dark)
      }
    }
  }

  /* Character Gallery, for showcasing who's who. */

  .character-gallery {
    justify-content: space-around;
    margin: 1rem 0;
    background: var(--av-green-light);
    border: 2px solid var(--av-green);
    border-radius: 10px;

    figure {
      flex: 0 0 160px;
      margin: 0.25rem;

      img {
        border: none;
      }

      figcaption {
        font-family: var(--main-font);
        font-size: var(--body-font-size);
      }
    }
  }

  /* Blocks for handling chapter summary content */

  aside {
    &.right {
      float: right;
      margin: initial; //0 0 1rem 1rem
    }

    &.av-sidebar {
      border-left: 3px solid;
      flex-basis: 37%;
      margin-left: 10px;
      padding-left: 20px;

      ul {
        font-size: .80rem;
      }
    }

    &.av-float-block {
      float: right;
      margin: 0 5px 10px 10px;
      width: 280px;
      padding: 10px 10px 0;
      background: rgba(0,0,0,0.1);
      border: initial;
      border-left: 2px solid black;
      color: black;
      &.left {
        float: left;
        border-left: initial;
        border-right: 2px solid black;
        margin: 0 10px 10px 5px;
      }
      h2 {
        font-family: var(--h1-font);
        color: var(--av-green);
        font-weight: normal;

        &:first-child {
          margin-top: 0;
        }
      }
      h3 {
        text-align: left;
        border: none;
        color: var(--av-green);
        display: block;
        margin: 0.15rem 0 0 0.15rem;
      }
      h4 {
        font-size: 1.25rem;
        color: var(--av-green);
        margin-bottom: 0;
      }

      ul {
        list-style: none;
        line-height: 1.5rem;
        padding-left: 10px;
      }

    }
  }
}
