:root {
    color-scheme: dark;
    --color_dull_red: rgba(149, 38, 27, 1.0);
    --color_black_40: rgba(0,0,0, 0.4);
    --text_color:     rgba(16, 16, 16, 1.0);
    --text_shadow_color: #cc8b45;
    --color_light:    rgba(250, 250, 250, 1.0);
    --color_gray_70:  rgba(120, 120, 120, 0.7);
    --right_page_img: url('../img/page_right.webp');
    --left_page_img:  url('../img/page_left.webp');
    --book_img:       url('../img/book_bg.webp');
    --solo_bage_img:  url('../img/page_solo.webp');
}

*, *::before, *::after {
    box-sizing: inherit;
}


body{
    background-color: black;  
    font-family: garamond;
    font-size: 24px;
    text-shadow: 1px 1px 4px var(--text_shadow_color);
    margin: 0;
    padding: 0;
    color: var(--text_color);
    overscroll-behavior-y: contain;
}  

h1{
    text-align: center;
    padding: 0;
    margin: -50px 0px -90px 0px;
    font-size: 225%;
    pointer-events: none;
    font-family: "cinzel";
    font-weight: 600;
}
h1::before{
    content: 'm';
    font-family: ornaments;
    font-weight: normal;
    font-size: 140%;
    display: block;
    translate: 0 0.3em;
}
h1::after{
    content: 'n';
    font-family: ornaments;
    font-weight: normal;
    font-size: 145%;
    display: block;
    translate: 0 -0.4em;
}

h2{
    text-align: center;
    font-size: 120%;
    pointer-events: none;
    font-family: "cinzel";
    font-weight: 600;
    letter-spacing: -1px;
}
h2::before{
    content: 'N';
    font-family: ornaments;
    font-weight: normal;
    font-size: 80%;
    padding-inline: 9px;
}
h2::after{
    content: 'N';
    font-family: ornaments;
    font-weight: normal;
    font-size: 80%;
    display: inline-block;
    scale: -1 1;
    padding-inline: 9px;
}
p{
    font-size: 32px;
    line-height: 1;
    font-weight: 900;
}
.fancy_first::first-letter {
    font-family: fancy;
    font-size: 275%;
    float: left;
    text-transform: uppercase;
    margin: 0;
    padding: 0;
    line-height: 59px;
    font-weight: 100;
}  

.error{
    position: absolute;
    top: 0;
    width: 100%;
    font-family: monospace;
    color: white;
    background-color: red;
    margin-inline: auto;
    outline: 1px white;
    text-shadow: 0px 0px 2px black; 
                  
}
.error_div{
    border: 1px solid white;
    padding: 5px;
    margin-block: 1px;
}
.clear_error_button{
    font-family: "icons"; 
    cursor: pointer;
    user-select: none; 
    padding-inline: 5px;  
}
@media (hover: hover) {
    .clear_error_button:hover {
        text-shadow: 0px 0px 2px black;
    }                  
}

.clear_error_button:active{
    color: lightgray;   
}

.button_disabled {
    font-family: "cinzel";
    font-weight: 600;
    color: var(--color_gray_70);
    text-align: center;
    font-size: 150%;
    user-select: none;
    outline: 3px solid currentColor;
    display: block;
    padding: 0 20px;
    border-radius: 8px;
    margin-block: 15px;
    /* pointer-events: none; */
    text-shadow: none;
    cursor: not-allowed;
}
.button_disabled::before{
    content: 'q';
    font-family: ornaments;
    font-weight: normal;
    position: absolute;
    left: 61px;
    font-size: 80%;
    text-shadow: none;
}
.button_disabled::after{
    content: 'r';
    font-family: ornaments;
    font-weight: normal;
    position: absolute;
    font-size: 80%;
    text-shadow: none;
    right: 62px;
}
.button{
    font-family: "cinzel";
    font-weight: 600;
    text-align: center;
    font-size: 150%;
    cursor: pointer;
    user-select: none;
    outline: 3px solid currentColor;
    display: block;
    padding: 0 20px;
    border-radius: 8px;
    margin-block: 15px;    
}

.button::before{
    content: 'q';
    font-family: ornaments;
    font-weight: normal;
    position: absolute;
    left: 61px;
    font-size: 80%;
    text-shadow: none;
}
.button::after{
    content: 'r';
    font-family: ornaments;
    font-weight: normal;
    position: absolute;
    font-size: 80%;
    text-shadow: none;
    right: 62px;
}
@media (hover: hover) {
    .button:hover{        
        background-color: #806d5442;        
    }
}

.button:active{
    text-shadow: 0px 0px 2px black;
    color: var(--color_dull_red);
}

.back_button{
    font-family: "cinzel";
    font-weight: 600;
    cursor: pointer;
    user-select: none;
    position: absolute;
    bottom: 0;
    padding-left: 50px;
}
.back_button::before{
      content: 'R';
      font-family: ornaments;
      font-weight: normal;
      font-size: 180%;
      position: absolute;
      bottom: -17px;
      left: 0px;
}

@media (hover: hover) {
    .back_button:hover{
        filter: drop-shadow(0px 0px 3px #e6e6e6);
    }
}
.next_button{
    font-family: "cinzel";    
    font-weight: 600;
    cursor: pointer;
    user-select: none;
    position: absolute;
    bottom: 0;
    padding-right: 140px;
    right: 0;
}
.next_button::after{
      content: 'Q';
    font-family: ornaments;
    font-weight: normal;
    font-size: 180%;
    position: absolute;
    bottom: -17px;
}

@media (hover: hover) {
    .next_button:hover{
        filter: drop-shadow(0px 0px 2px #e6e6e6);
    }
}

.main{
    scale: 1.0;
    transform-origin: top left;
}
.book {    
    background-image: var(--book_img);
    width: 1910px;
    height: 1080px;       
}    
.page{    
    transform-style: preserve-3d;
    transform-origin: left;
    width: 770px;
    height: 1080px;
    position: absolute;
    left: 940px;       
    transition: rotate 300ms;
    transition-timing-function: linear;

}
.page_front {
    background-image: var(--right_page_img);
    width: 770px;
    height: 1080px;
    position: absolute;
    left: 0;
    backface-visibility: hidden;
}
.page_back {
    background-image: var(--left_page_img);
    width: 770px;
    height: 1080px;
    position: absolute;
    left: 0;
    backface-visibility: hidden;
    rotate: y 180deg;   
}

.page_front_content{
    padding: 100px;
    transform: skew(0deg, -2deg);
    backface-visibility: hidden;    
    /*border: solid red 1px; */
    margin-top: 40px;    
    height: 678px;
}

.page_back_content{    
    padding: 140px 60px 0px 160px;
    transform: skew(0deg, 2deg);
    backface-visibility: hidden;
    height: 780px;
}

.illustration{
    width: 100%;
    -webkit-mask-image: radial-gradient(black 0%, transparent 70%);
    mask-image: radial-gradient(black 0%, transparent 70%);
    cursor: zoom-in;
}


@media (hover: hover) {
    .illustration:hover{
        -webkit-mask-image: none;
        mask-image: none;
        border-radius: 5px;
    }
}

.img_preview
{
    position: fixed;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    cursor: pointer;
    backdrop-filter: blur(20px);    
    display: flex;
    justify-content: center;
    background-color: rgba(0,0,0,0.6);
}

.img_big{   
    height: 1024px;
}

.options{
    position: absolute;
    top: 219px;
    left: 1743px;
    font-family: icons;
    font-size: 51px;
    text-shadow: none;
    user-select: none;
    cursor: pointer;
    color: rgba(0,0,0, 0.5);
}

@media (hover: hover) {
    .options:hover{
        color: black;
        filter: drop-shadow(0px 0px 3px #e6e6e6);
    }
}


.save{
    position: absolute;
    top: 583px;
    left: 1767px;
    font-family: icons;
    font-size: 45px;
    text-shadow: none;
    user-select: none;
    cursor: pointer;
    color: rgba(0,0,0, 0.5);
}

@media (hover: hover) {
    .save:hover{        
        color: black;
        filter: drop-shadow(0px 0px 3px #e6e6e6);
    }
}

.gallery{
      position: absolute;
      top: 415px;
      left: 1789px;
      font-family: icons;
      font-size: 45px;
      text-shadow: none;
      user-select: none;
      cursor: pointer;
      color: rgba(0,0,0, 0.5);
}

@media (hover: hover) {
    .gallery:hover{        
        color: black;
        filter: drop-shadow(0px 0px 3px #e6e6e6);
    }
}


.icon{
    font-family: icons;
    letter-spacing: 5px;
    font-weight: 100;
    min-height: 2ex;
}

.stats{
    position: absolute;
    bottom: 80px;
    pointer-events: none;
}

.icon_blink_plus{
    font-family: icons;
    letter-spacing: 5px;    
    font-weight: 100;
    min-height: 2ex;
}
.icon_blink_plus::after{
    content: '\F04D';
    color: transparent;
    position: absolute;
    margin-left: -29px;
    text-shadow: 0 0 8px #ffd700;
    mix-blend-mode: hard-light;
    animation-name: blink;
    animation-duration: 500ms;
    animation-fill-mode: forwards;
    scale: 0.1;
}

.icon_blink_minus{
    font-family: icons;
    letter-spacing: 5px;    
    font-weight: 100;
    min-height: 2ex;
}
.icon_blink_minus::after{
    content: '\F04D';
    color: transparent;
    position: absolute;
    margin-left: 12px;
    text-shadow: 0 0 8px transparent;
    mix-blend-mode: hard-light;
    animation-name: blink;
    animation-duration: 500ms;
    animation-fill-mode: forwards;
    scale: 0.1;
}



@keyframes blink {
  0% {text-shadow: 0 0 8px #ffd700; scale: 0.1;}
  50% {text-shadow: 0 0 28px #ffd700; scale: 5.0;}
  100% {text-shadow: 0 0 28px transparent; scale: 10.0;}
}


.modal_page{
    position: absolute;
    top: 0;
    background-image: var(--solo_bage_img);
    width: 1910px;
    height: 1080px;
    background-repeat: no-repeat;
    backdrop-filter: blur(10px) brightness(80%);
    background-position: center;   
}
.modal_page_content{
    width: 500px;
    margin-inline: auto;
    margin-top: 56px;
    transform-style: preserve-3d;
}

.button_options{
    font-family: "cinzel";
    font-weight: 600;
    text-align: center;
    font-size: 150%;
    cursor: pointer;
    user-select: none;
    outline: 3px solid currentColor;
    display: block;
    border-radius: 8px;
    margin-block: 15px;    
}

.button_options::before{
    content: 'q';
    font-family: ornaments;
    font-weight: normal;
    position: absolute;
    left: -39px;
    font-size: 80%;
    text-shadow: none;
}
.button_options::after{
    content: 'r';
    font-family: ornaments;
    font-weight: normal;
    position: absolute;
    font-size: 80%;
    text-shadow: none;
    right: -38px;
}
@media (hover: hover) {
    .button_options:hover{
        background-color: #806d5442; 
    }
}

.button_options:active{
    text-shadow: 0px 0px 2px black;
    color: var(--color_dull_red);
}

.slider {
    -webkit-appearance: none;
    width: 100%;
    height: 5px;
    background: #7b7b7b;
    outline: none;
    opacity: 0.6;
    -webkit-transition: .2s;
    transition: opacity .2s;
}

.slider:hover {
    opacity: 1;
}

.slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 39px;
    background: #000;
    cursor: pointer;
    border: none;
    border-radius: 5px;
}

.slider::-moz-range-thumb {
    width: 18px;
    height: 39px;
    background: #000;
    cursor: pointer;
    border: none;
    border-radius: 5px;
}

a.button_options {
  color: var(--text_color);
  text-decoration: none;
}

input[type="file"] {
    display: none;
}

.load_div{    
    width: 97%;
    height: 290px;
    overflow-y: scroll;
    padding: 0px 7px;
    border-radius: 10px;
    border: solid 1px rgba(0,0,0,0.3);
    margin-top: -26px;
}

.button_load{
    font-family: "cinzel";
    font-weight: 600;
    text-align: center;
    font-size: 120%;
    cursor: pointer;
    user-select: none;
    outline: 3px solid currentColor;
    display: block;
    border-radius: 8px;
    margin-block: 15px;
}

@media (hover: hover) {
    .button_load:hover{
        background-color: #806d5442; 
    }
}

.button_load:active{
    text-shadow: 0px 0px 2px black;
    color: var(--color_dull_red);
}

* {
    scrollbar-width: thin;
    scrollbar-color: var(--color_scroll1) #00000040;
}          
*::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
*::-webkit-scrollbar-track {
    background: var(--color_black_40);
}
*::-webkit-scrollbar-thumb {
    background-color: var(--color_dull_red);
    border-radius: 2px;
    border: none;
}
*::-webkit-scrollbar-corner {
    background-color: var(--color_black_40);
}  
.footer{
    position: absolute;
    color: #978773;
    font-size: 75%;
    text-shadow: none;
    left: 15%;
    margin-top: -40px;
}

.autofit{
    position: absolute;
    top:0;
    left:0;
    font-family: icons;
    color: white;
    text-shadow: 0 0 2px black;
    opacity: 70%;
    font-size: 14px;
    width: 136px;
    pointer-events: none;
}

.mods_div{
    width: 97%;
    height: 660px;
    overflow-y: scroll;
    padding: 0px 7px;
    border-radius: 10px;
}

.mod_div{
    border: solid black 1px;
    border-radius: 3px;
}


.buymeacoffee{
    background-color: #FFDD00;
    background-image: url('../img/bmc-button.svg');
    background-position: center;
    background-size: 100%;
    background-repeat: no-repeat;
    box-shadow: 0px 0px 5px var(--color_black90);
    border-radius: 0.8em;
    text-align: center;
    text-decoration: none;
    word-break: break-all;
    color: var(--color_black50);
    border: 2px solid black;
    cursor: pointer;
    animation-name: noticemesenpai;
    animation-delay: 2000ms;
    animation-duration: 4000ms;
    animation-iteration-count: infinite;
    animation-timing-function: ease-in-out;
    height: 88px;
    margin-top: 110px;
    width: 380px;
    font-size: 18px;
    margin-left: 110px;
    }
.buymeacoffee:hover{
    border: 3px solid black;
    box-shadow: 0px 2px 5px var(--color_black90);
}
.buymeacoffee:active{
    outline: 5px solid black;
}

@keyframes noticemesenpai{
  0%  {transform: rotate(0deg);}
  4%  {transform: rotate(2deg);}
  8%  {transform: rotate(-2deg);}
  12%  {transform: rotate(2deg);}
  16%  {transform: rotate(0deg);}
  100%  {transform: rotate(0deg);}
}


.elf{
    font-family: anyong;
    font-size: 28px;
    font-weight: 100;
}

.orc{
    font-family: capitalis_goreanis;
    font-size: 24px;
    font-weight: 100;
}

.common{
    font-family: pertho;
    font-size: 32px;
    font-variant-caps: small-caps;
    position: relative;   
    display: inline-flex; 
}

.common[data-txt]:hover{  
    color: transparent;    
}

.common[data-txt]:hover::after{
    content: attr(data-txt);
    font-family: garamond;
    font-size: 27px;   
    color: var(--text_color); 
    text-shadow: 1px 1px 4px var(--text_shadow_color);
    position: absolute;
    top: 0;
    line-height: 32px;
    letter-spacing: -0.3px;
}


.italic{
    font-style: italic;
    font-weight: 100;
}

.death{
    font-family: cinzel;
    font-weight: 600;
    font-size: 28px;
}

.scifi{
    font-family: spaceport;
    color: #1165d0;
    animation-name: lcd;
    animation-duration: 1400ms;
    animation-iteration-count: infinite;
    animation-direction: alternate;
    border: solid 3px;
    padding: 5px 15px;
    border-radius: 0px 10px 25px 10px;
    background: #3d6a9124;
    backdrop-filter: blur(4px);
    font-weight: 600;
    font-size: 85%;
    letter-spacing: 2px;
    line-height: 26px;
}
.scifi::before{
    content: '';
    background: currentColor;
    width: 190px;
    height: 21px;
    position: absolute;
    top: -22px;
    border-radius: 25px 5px 0px 0px;
    left: -3px;
}

@keyframes lcd {
  from {color: #1165d0;}
  to   {color: #7808d5;}
}

.gallery_div{
      width: 97%;
  height: 700px;
  overflow-y: scroll;
  padding: 0px 7px;
  border-radius: 10px;
  border: solid 1px rgba(0,0,0,0.3);
  margin-top: -26px;
}

.gallery_img{
    width: 230px;
    margin: 4px;
    cursor: zoom-in;
}

.gallery_img_hidden{
    width: 230px;
    margin: 4px;
    cursor: help;
    filter: blur(10px);
    
}
