*,
*::before,
*::after {
  margin: 0;
  padding: 0;
}

/* width */
::-webkit-scrollbar {
  width: 10px;
  z-index: 300;
  scrollbar-width: thin;
}

/* Track */
::-webkit-scrollbar-track {
  background: hsl(120, 92%, 90%);
  border-radius: 7px;
}

/* Handle */
::-webkit-scrollbar-thumb {
  background: hsl(30, 75%, 80%);
  border: hsl(30, 83%, 25%) 2px solid;
  border-radius: 6px;
}

/* Handle on hover */
::-webkit-scrollbar-thumb:hover {
  background: hsl(41, 100%, 45%);
}


body {
  display: flex;
  flex-direction: column;
  height: 100vh;
  justify-content: center;
  align-items: center;
  background-repeat: no-repeat;
  background-attachment: fixed;
  background-size: cover;
  background-position: center;
  font-family: Arial, Helvetica, sans-serif;
  /*  The image itself is loaded with JS  */
}

body,
html {
  overflow: hidden;
  /*   No part of the window needs to be highlighted/copied   */
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;

  --card-height: 260px;
  --card-width: 450px;

  --main-background: hsl(30, 67%, 92%);
  --border: 2px solid hsl(30, 64%, 33%);
  --border-color: hsl(30, 64%, 33%);
  --bright-green: hsl(120, 100%, 44%);
}

#loadingAssets {
  position: absolute;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  width: 100vw;
  height: 100vh;
  background: aquamarine;
  transition: opacity 0.3s;
  z-index: 500;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 24px;
  text-align: center;
}

#loadingAssets span {
  position: relative;
  transition: 0.2s;
}

#main {
  position: relative;
  perspective: 2000px;
  transform-style: preserve-3d;
}

#innerMain,
#innerBackMain {
  position: relative;
  transform-style: preserve-3d;
  backface-visibility: hidden;
}

#innerMain {
  z-index: -1;
}

#innerBackMain {
  position: absolute;
  transform: rotateY(180deg);
  top: 0;
  left: 0;
  background: hsl(30, 100%, 90%);
  height: 100%;
  width: 100%;
  border: var(--border);
  border-radius: 10px;
  z-index: 200;
}

#instructionMenuContainer {
  position: absolute;
  width: 65%;
  height: 320px;
  top: 20px;
  right: 30px;
  margin: auto;
  box-sizing: border-box;
  border: var(--border);
  border-radius: 10px;
  color: transparent;
  z-index: 300;
  transform: scale(0);
  transition: all 0.5s;
  transform-origin: top right;
}

#instructionMenuContainer.active {
  transition: all 0.5s;
  transform: scale(1) translate(-55px, 70px);
}

aj-burger {
  position: absolute;
  top: 10px;
  right: 20px;
  z-index: 350;
  transition: all 0.55s;
}

aj-burger.active {
  top: 100px;
  right: 95px;
}

#instructionsMenu {
  position: absolute;
  border-radius: 10px;
  width: 100%;
  height: 100%;
  left: 0;
  right: 0;
  padding: 10px;
  box-sizing: border-box;
  background-color: hsl(30, 64%, 80%);
  color: transparent;
  z-index: 300;
}

#instructionsMenu li {
  width: fit-content;
  margin: 5px auto;
}

#instructionsMenu li a {
  text-decoration: none;
  color: green;
  font-family: 'Patrick Hand';
  font-weight: bold;
  letter-spacing: 1px;
  font-size: 20px;
}

#instructionsMenu li a:hover {
  color: var(--bright-green);
}

.instructionTitle {
  letter-spacing: 1px;
  font-size: 30px;
  font-family: 'Covered By Your Grace';
  text-align: center;
  color: green;
  margin-top: 10px;
  margin-right: 10px;
}

/* This is where the actual pages are */
#userInstructions {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  margin: 50px auto 0;
  width: 97%;
  height: calc(100% - 70px);
  border-radius: 10px;
  overflow-y: scroll;
  scroll-behavior: smooth !important;
  z-index: 200;

  scrollbar-width: thin;
  scrollbar-color: hsl(30, 75%, 80%) hsl(120, 92%, 90%);

  /*
        hsl(30, 75%, 80%)  --  lighter
        hsl(30, 83%, 25%)  --  darker
  */
}

.page {
  scroll-margin: 7px;
  width: 95%;
  min-height: 200px;
  height: fit-content;
  background: whitesmoke;
  margin-bottom: 1rem;
  padding: 20px;
  box-shadow: 4px 4px 8px 2px #808080aa;
  box-sizing: border-box;
  margin-left: 5px;
}

.page p {
  margin-bottom: 1rem;
  font-size: 0.9rem;
  letter-spacing: 0.05rem;
}

.page p a {
  color: green;
  text-decoration: none;
  font-weight: bold;
}

.page p a:hover {
  color: var(--bright-green);
}

.page .pageHeading {
  text-align: center;
  text-decoration: underline;
  margin-bottom: 20px;
}

.page ol {
  margin-left: 10px;
}

.page ol ol {
  list-style-type: lower-alpha;
  margin-left: 20px;
}

.page li {
  margin-top: 10px;
}

#cssExample table {
  width: 95%;
  margin: auto;
  font-size: inherit;
}

#cssExample th:first-of-type,
#cssExample td:first-of-type {
  width: 40%;
}

#cssExample th:nth-child(2),
#cssExample td:nth-child(2) {
  width: 25%;
  text-align: left;
}

#cssExample th:last-of-type,
#cssExample td:last-of-type {
  white-space: nowrap;
}

#cssExample th {
  text-align: left;
}

.spinBackward {
  position: absolute;
  top: 20px;
  left: 10px;
  color: green;
  transform-style: preserve-3d;
}

.spinBackward:hover {
  color: red;
  backface-visibility: hidden;
}

.card-container {
  position: relative;
  height: var(--card-height);
  width: var(--card-width);
  margin-bottom: 20px;
  transform-style: preserve-3d;
  backface-visibility: hidden;
}

#files,
.card-front,
.card-back {
  transform-style: preserve-3d;
  backface-visibility: hidden;
  border: var(--border);
  box-sizing: border-box;
  width: var(--card-width);
  font-size: 21px;
  border-radius: 10px;
  overflow: hidden;
}

aj-checkbox {
  cursor: pointer;
  backface-visibility: hidden;
}

/* .example, */

.card-front,
.card-back {
  position: absolute;
  height: 100%;
  width: 100%;

  transform-style: preserve-3d;
  backface-visibility: hidden;
  background-color: white;

  transition: transform 3s;
}

.card-front,
.alignAndJustify {
  display: flex;
  justify-content: space-between;
  flex-direction: column;
  text-align: center;
}

.card-back {
  display: grid;
  /* grid-template: 2.8fr 0.5fr 1.2fr 1fr 0.4fr 1.2fr repeat(3, 1.3fr) 0.5fr 2.8fr / repeat(13, 1fr); */
  grid-template: 2.8fr 0.4fr 1.2fr repeat(3, 1.3fr) 0.5fr 2.8fr / repeat(13,
      1fr
    );
  grid-gap: 3px;

  font-size: 14px;
  justify-content: center;
  transform: rotateX(180deg);
}

/* top line when entering new text */
.instructionsContainer {
  margin-top: 10px;
}

.settingsTitle,
.question-1,
.downloadFile,
.onlyCopyLinkAddress,
.question-2,
.resetSettingsYes,
.resetSettingsNo,
.saveToStorage {
  display: flex;
  justify-content: center;
  align-items: center;
}

.settingsTitle {
  grid-area: 1 / 1 / span 1 / span 14;
  align-items: flex-end;
  font-size: 25px;
  font-weight: 700;
  box-sizing: border-box;
  padding-bottom: 8px;
  text-decoration: underline;
  background: var(--main-background);
  color: green;
}

/* .question-1 {
  grid-area: 3 / 4 / span 1 / span 7;
  line-height: 1.2;
}

.downloadFile {
  grid-area: 4 / 5 / span 1 / span 2;
}

.onlyCopyLinkAddress {
  grid-area: 4 / 8 / span 1 / span 3;
} */

.question-2 {
  /* grid-area: 6 / 3 / span 1 / span 10; */
  grid-area: 3 / 3 / span 1 / span 10;
  line-height: 1.2;
}

.question-2 span {
  padding-right: 17px;
}

.line1,
.line2,
.line3 {
  display: flex;
  justify-content: space-between;
}

/* .line1 {
  grid-area: 7 / 4 / span 1 / span 7;
}

.line2 {
  grid-area: 8 / 4 / span 1 / span 7;
}

.line3 {
  grid-area: 9 / 4 / span 1 / span 7;
} */

.line1 {
  grid-area: 4 / 4 / span 1 / span 7;
}

.line2 {
  grid-area: 5 / 4 / span 1 / span 7;
}

.line3 {
  grid-area: 6 / 4 / span 1 / span 7;
}

label {
  margin-left: 3px;
}

aj-checkbox {
  box-sizing: border-box;
  display: inline-block;
  height: fit-content;
}

.resetSettings {
  padding-left: 12px;
  display: flex;
  height: 100%;
  align-items: center;
}

.saveToStorage {
  /* grid-area: 11 / 1 / span 1 / span 13; */
  grid-area: 8 / 1 / span 1 / span 13;
  display: flex;
  justify-content: space-evenly;
  align-items: center;
  width: 100%;
  height: 100%;
  background: var(--main-background);
  color: green;
  border-color: green;
  font-size: 15px;
  font-weight: 700;
}

.saveToStorage>* {
  display: inline-block;
  width: fit-content;
  white-space: nowrap;
}

#saveSettingsLocally {
  /* position: absolute; */
  width: fit-content;
  border-color: green;
}

/*   Buttons for card flipping   */

.seeInst,
i {
  position: absolute;
  cursor: pointer;
}

.seeInst {
  font-size: 22px;
  top: 6px;
  left: 25px;
  font-family: Amaranth;
  font-weight: 600;
}

i {
  top: 17px;
  right: 20px;
}

i:hover,
.seeInst:hover {
  color: var(--bright-green);
}

.spinBackward,
.flipBackward,
.uploadBtn {
  position: absolute;
  top: 10px;
  font-weight: 900;
  color: green;
  border: none;
  outline: none;
  background: transparent;
  backface-visibility: hidden;
}

.spinBackward {
  left: 20px;
}

.flipBackward {
  right: 15px;
}

.uploadBtn {
  left: 15px;
}

.spinBackward:hover,
.flipBackward:hover,
.uploadBtn:hover {
  color: var(--bright-green);
  cursor: pointer;
}

/*    Vertical spin    */

@keyframes flip_1a {
  0% {
    transform: rotateX(0deg);
  }

  100% {
    transform: rotateX(180deg);
  }
}

@keyframes flip_1b {
  0% {
    transform: rotateX(0deg);
  }

  100% {
    transform: rotateX(-180deg);
  }
}

@keyframes flip_2a {
  0% {
    transform: rotateX(180deg);
  }

  100% {
    transform: rotateX(360deg);
  }
}

@keyframes flip_2b {
  0% {
    transform: rotateX(180deg);
  }

  100% {
    transform: rotateX(0deg);
  }
}

/*    Horizontal Spin    */

@keyframes spin_1a {
  0% {
    transform: rotateY(0deg);
  }

  100% {
    transform: rotateY(-180deg);
  }
}

@keyframes spin_1b {
  0% {
    transform: rotateY(0deg);
  }

  100% {
    transform: rotateY(180deg);
  }
}

@keyframes spin_2a {
  0% {
    transform: rotateY(-180deg);
  }

  100% {
    transform: rotateY(-360deg);
  }
}

@keyframes spin_2b {
  0% {
    transform: rotateY(-180deg);
  }

  100% {
    transform: rotateY(0deg);
  }
}

#fontType {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  height: 15%;
  padding: 10px;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 27px;
  color: green;
  background: var(--main-background);
  border-radius: 10px 10px 0 0;
}

#fontName {
  margin-top: 5px;
}

.sampleTextContainer {
  height: 65%;
  overflow: hidden;
}

#sampleText {
  /* font-size is set at beginning of JS */
  display: flex;
  position: relative;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  overflow: hidden;
  font-family: 'Times New Roman', Times, serif;
  transition: 0.1s linear;
  --margin: 0px;
  --letterSpacing: 0px;
  --wordSpacing: 0px;
  --fontSize: 30px;
}

#sampleText div {
  margin: 0;
  padding: 0;
  white-space: nowrap;
  letter-spacing: var(--letterSpacing);
  word-spacing: var(--wordSpacing);
  font-size: var(--fontSize);
}

#sampleText div:not(:first-child) {
  margin-top: var(--margin);
}

#sampleText textarea {
  font-size: inherit;
  font-family: inherit;
  font-weight: inherit;
  white-space: nowrap;
  height: 100%;
  width: 100%;
  height: min-content;
  max-height: 100%;
  padding: 40px 30px;
  overflow: hidden;
  border: none;
  outline: none;
  text-align: center;
  background-color: inherit;
}

.showSize {
  position: absolute;
  cursor: pointer;
  font-size: 16px;
  box-sizing: content-box;
  width: max-content;
  height: fit-content;
  background: transparent;
  visibility: hidden;
  right: 0;
  bottom: calc(15% + 8px);
}

.sizeInPx {
  padding: 10px 15px;
  background: white;
  opacity: 0.9;
  z-index: 99;
  border-radius: 7px;
}

#buttons {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 15%;
  padding: 0 15px 5px;
  background: var(--main-background);
  font-family: Arial, Helvetica, sans-serif;
  cursor: context-menu;
  box-sizing: border-box;
  border-radius: 0 0 10px 10px;
}

#buttons>* {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  width: min-content;
  height: 100%;
  font-size: 16px;
  font-weight: 700;
  margin: 10px auto 0;
  border: none;
  outline: black;
  cursor: default;
  white-space: nowrap;
}

.navSpaces {
  cursor: default;
}

.navBtn {
  font-weight: inherit;
}

#fontWeightBtn,
#minusBtn,
#plusBtn,
#styleBtn,
#newTextBtn,
#copyCssToClipBtn,
#copyHtmlToClipBtn,
#downloadFileBtn {
  width: min-content;
  cursor: pointer;
  background-color: transparent;
  color: green;
  text-decoration: none;
}

#fontWeightBtn:hover,
#minusBtn:hover,
#plusBtn:hover,
#styleBtn:hover,
#newTextBtn:hover,
#copyCssToClipBtn:hover,
#copyHtmlToClipBtn:hover,
#downloadFileBtn:hover {
  color: var(--bright-green);
}

#styleBtn {
  /* 
      This is needed to keep the button from changing
       size and then throwing off the other buttons
  */
  justify-content: flex-end;
  text-align: center;
  padding-right: 5px;
  width: 50px;
}

#minusBtn,
#plusBtn {
  font-size: 30px;
  margin-bottom: 5px;
}

#minusBtn {
  margin-bottom: 8px;
}

#buttons span:not(#fontWeightBtn) {
  font-family: impact;
  font-size: 27px;
}

#weightBtns {
  display: flex;
  align-items: center;
}

#weightBtns span#fontWeightBtn {
  font-family: Arial, Helvetica, sans-serif;
  display: inline-block;
  font-weight: 700;
  width: 35px;
}

/*




















*/

/* 
    For most of the tooltips, the element is the container, EXCEPT...
    the three weight buttons all have a single 'outer' container.
*/
.tooltip,
.tooltipContainer {
  position: relative;
  --scale: 0;
  --arrow-size: 10px;
  --tooltip-background: rgb(242, 217, 191);
  --tooltip-color: hsl(30, 64%, 33%);
  color: var(--tooltip-color);
  --translate-y: calc(-100% - var(--arrow-size));
  --transition: 500ms;
  --delay: 1s;
  --tooltip-fontSize: 14px;
}

/*  Say what the button does  */
.tooltip::before,
.tooltip::after {
  position: absolute;
  top: 1rem;
  left: 50%;
  transform: translate(-50%, var(--translate-y)) scale(var(--scale));
  transition: var(--transition) 0s;
  transform-origin: bottom center;
  font-weight: normal;
  font-family: Arial, Helvetica, sans-serif;
  /* font-size: 17px; */
  font-size: var(--tooltip-fontSize);
}

/*  text area  */
.tooltip::before {
  content: attr(data-tooltip);
  /* font-weight: bold; */
  padding: 0.2rem 0.4rem;
  text-align: center;
  /*
      fit-content does not work for width because
        it does not account for the line breaks
  */
  height: fit-content;
  background: var(--tooltip-background);
  white-space: pre-wrap;
  /* CSS3 */
  white-space: -moz-pre-wrap;
  /* Firefox */
  white-space: -pre-wrap;
  /* Opera <7 */
  white-space: -o-pre-wrap;
  /* Opera 7 */
  word-wrap: break-word;
  /* IE */
  line-height: 1.2rem;
  border: var(--border);
  border-radius: 10px;
  z-index: 10;
}

/*  arrow  */
.tooltip::after {
  --translate-y: calc(-1 * var(--arrow-size) - 1px);
  content: '';
  border: var(--arrow-size) solid transparent;
  border-top-color: var(--border-color);
  transform-origin: top center;
}

.tooltip:hover:not(.disabled)::before,
.tooltip:hover:not(.disabled)::after {
  --scale: 1;
  transform: translate(-50%, calc(var(--translate-y) - 1rem)) scale(var(--scale));
  transition: var(--transition) var(--delay);
  /* transition: transform 200ms 2s; */
  /* transition: transform 200ms 1s; */
}

#minusBtn::before,
#plusBtn::before {
  width: 70px;
  color: var(--tooltip-color);
}

#minusBtn::before,
#minusBtn::after {
  top: calc(3px + 1rem);
}

#minusBtn:hover::before {
  margin-left: 14px;
}

.button.file:hover::before {
  transform: translate(-57%, calc(var(--translate-y) - 1rem));
}

#plusBtn::before,
#plusBtn::after {
  top: calc(2px + 1rem);
}

#fontWeightBtn::before {
  width: 89px;
  color: var(--tooltip-color);
}

#fontWeightBtn::before,
#fontWeightBtn::after {
  top: calc(-7px + 1rem);
}

.style::before {
  width: 103px;
}

.newText::before {
  width: 78px;
}

.css::before {
  width: 82px;
}

.html::before {
  width: 91px;
}

.file::before {
  width: 65px;
}

#htmlCopied,
#cssCopied {
  position: absolute;
  top: -35px;
  left: 50%;
  transform: translateX(-50%);
  font-weight: normal;
  font-family: Arial, Helvetica, sans-serif;
  font-size: var(--tooltip-fontSize);

  font-weight: bold;
  padding: 0.3rem 0.5rem 0.2rem;
  text-align: center;
  width: min-content;
  height: min-content;
  border: var(--border);
  border-radius: 7px;
  white-space: pre-wrap;
  background-color: var(--tooltip-background);
  display: none;
}

/* 


*/

#weightsTable {
  position: absolute;
  display: none;
  top: 50px;
  left: 0px;
  width: fit-content;
  height: 175px;
  text-align: center;
  width: 120px;
  background-color: var(--main-background);
}

#weightsTable table {
  border-bottom: none;
  position: relative;
  font-size: 12px;
  padding: 5px;
  height: fit-content;
  width: 100%;
}

/*






















*/

#files {
  position: relative;
  height: min-content;
  max-height: calc(100vh - 350px);
  font-size: 22px;
  font-weight: 500;
  overflow-y: auto;
  overflow-x: hidden;
  background-color: transparent;
  padding: 20px;
  background-color: var(--main-background);
  text-align: center;
  z-index: -1;
  scrollbar-width: thin;
  scrollbar-color: hsl(30, 75%, 80%) hsl(120, 92%, 90%);

  /*
        hsl(30, 75%, 80%)  --  lighter
        hsl(30, 83%, 25%)  --  darker
  */
}

.font {
  cursor: pointer;
  padding: 10px 0;
  border-radius: 10px;
  box-sizing: border-box;
  border: white 1px dotted;
  background-color: white;
  margin-top: 10px;
  -webkit-user-select: text;
  -moz-user-select: text;
  -ms-user-select: text;
  user-select: text;
}

.font:hover {
  background-color: hsla(30, 67%, 47%, 0.12);
  border-color: hsl(30, 64%, 33%);
}

hr {
  width: 50%;
  background-color: black;
  margin: auto;
  display: none;
}

.bottomLine {
  display: flex;
  justify-content: space-between;
  width: calc(var(--card-width) - 70px);
  background: var(--main-background);
  background: hsl(30, 55%, 80%);
  /* background: hsl(29, 50%, 90%); */
  color: black;
  padding: 5px 20px;
  border-radius: 0 0 7px 7px;
  font-weight: bold;
}

.downloadApplication {
  --hover-color: var(--bright-green);
  color: green;
}

.downloadApplication span {
  position: relative;
  transition: all 0.1s;
  color: black;
  cursor: default;
}

.downloadApplication:hover {
  color: var(--hover-color);
  cursor: pointer;
}

/* .grandTotal {

  transform: translateX(calc((var(--card-width) / 2) - 30px));
} */