@font-face {
    font-family: "Montserrat";
    src: url("/fonts/montserrat.woff2");
    font-display: swap;
}

@font-face {
    font-family: "Montserrat";
    src: url("/fonts/montserrat-italic.woff2");
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: "Montserrat";
    src: url("/fonts/montserrat-bold.woff2");
    font-weight: bold;
    font-display: swap;
}

@font-face {
    font-family: "Montserrat";
    src: url("/fonts/montserrat-bold-italic.woff2");
    font-weight: bold;
    font-style: italic;
    font-display: swap;
}

body {
  margin: 0;
  background-color: #d5e5ff;
  background-image: url("/images/background.png");
  background-position: top;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
  
b {
  font-weight: bold;
}

i {
  font-style: italic;
}

s {
  text-decoration: line-through;
}

.wrapper {
  text-align: center;
  margin: 20px auto;
  padding: 0 1rem;
  font-family: "Montserrat";
  width: 100%;
  max-width: 55%;
  flex: 1;
  box-sizing: border-box;
  overflow: hidden;
}

/* For screen readers */
.sr-only {
  position: absolute;
  clip: rect(0, 0, 0, 0);
  clip-path: inset(50%);
  width: 1px;
  height: 1px;
  overflow: hidden;
  white-space: nowrap;
}

.logo {
  max-width:100%;
  height:auto;
  margin-bottom: 1rem;
}

.about-me-mythical {
  width: 47%;
  max-width: 400px;
  height: auto;
  aspect-ratio: 661 / 365;
  position: relative;
  top: 50px;
  margin-top: -5rem;
  z-index: -3;
  /*top: 2.2rem;
  margin-top: -3rem;
  z-index: 10;*/
}
  
.text-box {
  background-color: #ffaaaa;
  border: 5px solid #ff5555;
  border-radius: 10px;
  padding: 20px;
  text-align: left;
  margin-bottom: 2rem;
}

body>.text-box:last-of-type,
main>.text-box:last-of-type,
section:last-of-type>.text-box:last-of-type,
article:last-of-type>.text-box:last-of-type {
  margin-bottom: 0.5rem
}

.text-box:has(ul) {
  padding: 10px 20px;
}

.text-box a {
  color: #214478;
}

.text-box img {
  max-width: 100%;
  height: auto;
  aspect-ratio: attr(width) / attr(height);
}

.text-box p:first-child {
  margin-top: 0;
}

.text-box p:not(:last-child) {
  margin-bottom: 1em;
}

.text-box p:last-child {
  margin-bottom: 0;
}

.text-box.center {
  text-align: center;
}

.text-box:has(+.heart-grid) {
  margin-bottom: 0.5rem
}

.text-box-thumb {
  max-height: 250px;
  width: auto;
}

hr.space-break {
  border: none;
}

.colored-link {
  color: #214478;
}

.white-link {
  color: #ffffff;
}

h1, h2 {
  background-color: #ff5555;
  border-radius: 10px;
  padding: 10px;
  color: rgb(255, 255, 255);
  font-size: 1.25em;
  font-weight: bold;
  text-align: left;
  margin-top: 0;
  margin-bottom: 0.5rem;
}

h1 {
  font-size: 2em;
  text-align: center;
}

h2 {
  padding-left: 15px;
}

button {
  background-color: #fe80df;
  border: 3px solid #ff00bf;
  border-radius: 5px;
  padding: 2px 5px;
  color: black;
  font-size: 1em;
  font-family: 'Montserrat';
  cursor: pointer;
}

button:hover {
  background-color: #fd4ed1;
}

a.button {
  background-color: #fe80df;
  border: 3px solid #ff00bf;
  border-radius: 5px;
  padding: 2px 5px;
  color: black;
  text-decoration: none;
  font-size: 1em;
  font-family: 'Montserrat';
}

a.button:hover {
  background-color: #fd4ed1;
}
  
.heart-button-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(120px, max-content));
  justify-content: space-evenly;
  margin-top: 1rem;
  margin-bottom: 2rem;
}

.heart-button-container {
  position: relative;
}

.heart-button-container:hover {
  transform: scale(110%);
}

/*.heart-image {
  position: absolute; 
  top: 50%; 
  left: 50%; 
  transform: translateX(-50%) translateY(-50%);
}*/

.heart-button-text{
  position: absolute; 
  /* Commented out until all heart buttons have images
  top: 60%; 
  left: 50%;
  transform: translateX(-50%);*/
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background-color: #fe80df;
  border: 3px solid #ff00bf;
  border-radius: 5px;
  padding: 2px;
  width: 125px;
  font-size: 1.05em;
  color: black;
  word-wrap: break-word;
}

.heart-button-text.longer {
  width: 150px;
}

.heart-button-grid.links {
  gap: 7px !important;
  grid-template-columns: repeat(auto-fit, minmax(65px, max-content)) !important;
}

.heart-link-icon {
  position: absolute;
  top: 43%; 
  left: 50%; 
  transform: translate(-50%, -50%);
  font-size: 27px;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
}

.heart-link-icon img {
  height: 27px;
  width: 27px;
  object-fit: contain;
  pointer-events: none;
}

/*Credit: https://stackoverflow.com/a/12216973/18758445*/
ul {
  list-style: none;
  margin-left: 0;
  padding-left: 0;
  line-height: 1.5;
}

li {
  padding-left: 1em;
  text-indent: -1em;
}

li:before {
  content: "❤︎";
  padding-right: 5px;
}

.article-select-section {
  text-align: center;
  color: #ff00bf;
  margin-bottom: 0.5rem;
}

.article-select {
  display: inline;
  color: #000000;
}

select {
  background-color: #ffffff;
  border: 1px solid #000000;
  padding-top: 2px;
  padding-bottom: 2px;
  font-size: 1em;
  font-family: 'Montserrat';
}

footer {
  margin-top: auto;
  margin-bottom: 0;
  background-color: #d40000;
  padding: 20px;
  text-align: center;
  font-family: "Montserrat";
  font-size: 12px;
  color: #ffffff;
  flex-shrink: 0;
}

footer a {
  color: #d5f6ff;
}

/* Mobile */  
@media only screen and (max-width: 767px) {
  .wrapper {
    max-width: 100%;
    padding: 0 0.5rem;
  }

  .about-me-mythical {
    width: 90%;
    max-width: none;
    /*top: 2.2rem;
    margin-top: -3rem;*/
  }

  .heart-text.longer {
    width: 145px;
  }

  .links-grid {
    gap: 9px;
    grid-template-columns: repeat(auto-fit, minmax(55px, max-content));
  }

  .link-heart-button {
    height: 55px;
    width: 60px;
  }

  .link-icon {
    font-size: 25px;
  }

  .link-icon img {
    height: 25px;
    width: 25px;
  }
}

/* Tablet */
@media only screen and (min-width: 768px) and (max-width: 1365px) {
  .wrapper {
    max-width: 67%;
  }

  .about-me-mythical {
    width: 75%;
    max-width: 360px;
    /*top: 2.2rem;
    margin-top: -3rem;*/
  }

  .heart-grid {
    gap: 25px;
    grid-template-columns: repeat(auto-fit, minmax(125px, max-content));
  }

  .heart-button {
    height: 115px;
    width: 125px;
  }

  .heart-text {
    font-size: 1.07em;
    width: 130px;
  }

  .links-grid {
    gap: 8px;
    grid-template-columns: repeat(auto-fit, minmax(57px, max-content));
  }

  .link-heart-button {
    height: 57px;
    width: 62px;
  }

  .link-icon {
    font-size: 26px;
  }

  .link-icon img {
    height: 26px;
    width: 26px;
  }
}

/* Particularly large monitors */
@media only screen and (min-width: 1920px) {
  .wrapper {
    max-width: 1000px;
  }

  .logo img {
    width: 450px;
    height: 127px;
  }

  .about-me-mythical {
    width: 50%;
    max-width: 500px;
    /*top: 2.2rem;
    margin-top: -3rem;*/
  }

  .heart-grid {
    gap: 30px;
    grid-template-columns: repeat(auto-fit, minmax(130px, max-content));
  }

  .heart-button {
    height: 120px;
    width: 130px;
  }

  .heart-text {
    font-size: 1.1em;
    width: 135px;
  }

  .links-grid {
    gap: 10px;
    grid-template-columns: repeat(auto-fit, minmax(65px, max-content));
  }

  .link-heart-button {
    height: 70px;
    width: 65px;
  }

  .link-icon {
    font-size: 28px;
  }

  .link-icon img {
    height: 28px;
    width: 28px;
  }
}