/*color pallet*/
:root {
    --black: #333;
    --dark-neutral: #866C5A;
    --dark-color: #3D4E0D;
    --light-neutral: #FFFBF4;
    --light-color: #F3EAD8;
    --accent-light: #A47195;
    --accent-dark: #3E0A2E;
}

html, body {
    width:100%;
    padding:0;
    margin:0;
    background-color: var(--light-color);
    color:#333;
}

#header-menu {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    font-size: 1.25rem;
    padding: 1rem;
    position: absolute;
    top: 3rem;
    background-color: #fff;
    list-style-type: none;
}

#header-menu a {
  text-decoration: none;
  color:#333;
}

#header-menu a.selected {
  color:#000;
  font-weight: bold;
}

html, body {
  margin: 0 auto;
  width:100%;
}

body {
  width:100%;
  font-family: 'Roboto', sans-serif;
}

body > header {
  grid-area: header;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow:2px 0px 1px 2px #ccc;
  background-color: var(--light-neutral);
  height:4rem;
  width:100%;
}

body > header > h1 {
  margin:0;
}

body > header h1 > a {
  text-decoration: none;
  color:#333;
  font-family: 'Times New Roman', Times, serif;
  padding-left:1rem;
}

body > main {
  max-width: 900px;
  margin: 0 auto;
}

header > div > nav {
  display: flex;
  width:100%;
  flex-direction: row;
  justify-content: right;
  gap:2rem;
  align-items: center;
  font-family: 'Roboto', sans-serif;
  max-width: 192px;
}

header > div > nav > a {
  display:flex;
  flex-direction: column;
  text-decoration: none;
  color:var(--black);
  align-content: center;
  gap:0.125rem;
}

header > div > nav > a > i {
  font-size:2rem;
}

header > div > nav > a > * {
  text-align: center;
}


content {
  display: grid;
  grid-template-columns: 250px 800px 250px;
  justify-content: center;
  justify-items: center;
  max-width: 1380px;
  margin: 0 auto;
}

#user-menu > ul {
  border-radius: 0.5rem;
  margin-top: 1rem;
  list-style-type: none;
  padding: 2rem 0rem;
  background-color: var(--light-neutral);
}

.header-avatar {
  width:2.2rem;
  height:2.2rem;
  border-radius: 5rem;
  display: block;
  margin: 0 auto;
}

.badge:after {
  content: attr(value);
  font-size: .75rem;
  color: #fff;
  background: var(--accent-light);
  border-radius: 50%;
  padding: 0.15rem 0.35rem;
  position: relative;
  left: -8px;
  top: -1.125rem;
  opacity: 0.9;
  font-family: 'Roboto';
  font-weight: 700;
}

#shopping-basket-icon.badge:after {
  left:-6ch;
}

.ui-button {
  display: grid;
  grid-template-columns: 1fr 4fr;
  text-align: center;
  background-color: var(--accent-light);
  color:#efefef;
  font-size: 1rem;
  padding: 0.75rem 1rem;
  border:none;
  border-radius: 5rem;
  cursor: pointer;
  transition-property: box-shadow, color;
  transition-duration: 0.3s, 0.01s;
  align-items: center;
  gap: 1rem;
}

.ui-button.no-grid {
  display:inline-block;
}

.ui-button.accent {
  background-color: var(--accent-dark);

}

.ui-button.error {
    box-shadow: 0px 0px 8px red;
}

.ui-button.cancel {
    color:#333;
    background-color: #ddd;
}

.ui-button:hover {
  box-shadow: 2px 2px 3px #BBB;
}

.ui-button:active {
    box-shadow: none;
    color:var(--accent-light);
}

.ui-button.disabled {
    background-color:var(--accent-light);
    opacity: 80%;
    cursor: default;
}

.ui-button.disabled:hover {
    box-shadow: none;
}

.ui-button.disabled:active {
    box-shadow: none;
    color:var(--light-neutral);
}

.modal {
    display: none; /* Hidden by default */
    position: fixed; /* Stay in place */
    z-index: 1; /* Sit on top */
    left: 0;
    top: 0;
    width: 100%; /* Full width */
    height: 100%; /* Full height */
    overflow: auto; /* Enable scroll if needed */
    background-color: rgb(0,0,0); /* Fallback color */
    background-color: rgba(0,0,0,0.6); /* Black w/ opacity */
    grid-template-columns: 1fr;
    align-items: center;
    justify-items: center;
  }

  /* Modal Content/Box */
.modal-content {
    background-color: #fefefe;
    padding: 20px;
    border: 1px solid #888;
    width: 90%;
    max-width: 80ch;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    border-radius: 1rem;
    position: relative;
    font-family: "Roboto", sans-serif;
  }

  .modal-content > header {
    text-align: left;
    font-size: 1.2rem;
  }

  .modal-content > header > p {
    margin-top: .1rem;
    margin-block-end: 0;
  }

  .modal-content > header > h2 {
    font-size: 1.25em;
    margin: 1rem 0;
  }

  .modal-content > main > form {
    display: flex;
    flex-direction: column;
  }

  .modal-content > main > form label {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
  }

  .modal-content > footer {
    display: flex;
    gap: 1rem;
    justify-content: space-around;
  }

  .modal-content select, .modal-content input[type="date"] {
    padding: 0.5rem;
    background-color: #eee;
    border-radius: .25rem;
    border: none;
    color: #333;
    font-size: 1.2rem;
    margin:1rem 0;
  }
 
  /* The Close Button */
  .close {
    color: #aaa;
    font-size: 28px;
    font-weight: bold;
    position: absolute;
    right: 10px;
    top: 5px;
  }
  
  .close:hover,
  .close:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
  }

  #links-container {
    display: flex;
    gap: 5px;
    margin-bottom: 5px;
  }

  .social-link {
    padding: 10px;
    font-size: 20px;
    width: 30px;
    text-align: center;
    color:#fff;
  }

  .social-link.instagram {
    background-color: #c32aa3;
  }
  .social-link.tiktok {
    background-color: #ee1d52;
  }
  .social-link.facebook {
    background-color: #1877f2;
  }
  .social-link.twitter {
    background-color: #1da1f2;
  }
  .social-link.youtube {
    background-color: #ff0000;
  }
  .social-link.linkedin {
    background-color: #0a66c2;
  }
  .social-link.reddit {
    background-color: #ff4500;
  }
  .social-link.twitch {
    background-color: #9146ff;
  }
  .social-link.discord {
    background-color: #5865f2;
  }
  .social-link.mastadon {
    background-color: #6364ff;
  }
  .social-link.spotify {
    background-color: #1ed760;
  }
  .social-link.amazon {
    background-color: #ff9900;
  }
  .social-link.audible {
    background-color: #fe9802;
  }
  .social-link.medium {
    background-color: #02b875;
  }
  .social-link.goodreads {
    background-color: #845625;
  }
  .social-link.email,.social-link.custom {
    background-color: #555;
  }
  .social-link.tumblr {
    background-color: #36465D;
  }
  .social-link.threads {
    background-color: #111;
  }

  .gap-1rem {
    gap:1rem;
  }
.grid-2-columns {
    display: grid;
    grid-template-columns: repeat(2, minmax(0,1fr));
}

.grid-3-columns {
    display: grid;
    grid-template-columns: repeat(3, minmax(0,1fr));
}

.grid-4-columns {
    display: grid;
    grid-template-columns: repeat(4, minmax(0,1fr));
}

.grid-5-columns {
    display: grid;
    grid-template-columns: repeat(5, minmax(0,1fr));
}

.column-gap {
    column-gap:1em;
}

.item-preview {
    padding-top:1em;
    text-align: center;
    background-color: #fefefe;
    max-width: 300px;
    justify-self: center;
}

.item-preview.author {
    background-color: rgba(255,255,255,0);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.item-preview.book {
    display: grid;
    grid-template-rows: .25fr 3fr .5fr;
    cursor: pointer;
}

.item-preview.book > figure > img {
    max-width: 188px;
}
.item-preview > header, .list-preview > header {
    font-weight: bold;
    text-wrap: balance;
    display: flex;
    flex-direction: column;
}

.item-preview .book-subtitle {
    font-size: smaller;
    color: #666;
}

.item-meta {
    display:grid;
    grid-template-columns: 1fr 7ch;
    grid-template-rows: 2ch 2ch;
    padding: 5px 10px;
}

.item-meta > p {
    margin:0;
    padding:0;
}

.item-meta > p:nth-child(odd) {
    text-align: left;
    text-transform: capitalize;
}

.item-meta > p:nth-child(even) {
    text-align: right;
}

.star {
    color:goldenrod;
}

.item-preview > img {
    width: 100px;
    margin:10px auto;
}

.item-preview.author > .image-container {
    height: 100px;
    width:100px;
    background-position: center center;
    background-repeat: no-repeat;
    background-size: cover;
}

.circle {
    border-radius:50%;
}

.tags-input {
    display: inline-block;
    position: relative;
    border: 1px solid #ccc;
    border-radius: 0.25rem;
    padding: 0.275rem;
    width: 80%;
}

.tags-input ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.tags-input li, .book-tag {
    display: inline-block;
    background-color: #f2f2f2;
    color: #333;
    border-radius: 1.2rem;
    padding: .25rem .5rem;
    margin-right: .25rem;
    margin-bottom: .25rem;
}

.book-tag {
  cursor: pointer;
  background-color: var(--light-neutral);
  text-decoration: none;
}

.tags-input input[type="text"] {
    border: none;
    outline: none;
    padding: .25rem;
    width: calc(100% - 0.5rem);
}

.tags-input input[type="text"]:focus {
    outline: none;
}

.tags-input .delete-button {
    background-color: transparent;
    border: none;
    color: #999;
    cursor: pointer;
    margin-left: 5px;
}

#loader-container {
  margin:10px auto;
  width:100px;
}

.lds-ellipsis {
  display: inline-block;
  position: relative;
  width: 80px;
  height: 80px;
}
.lds-ellipsis div {
  position: absolute;
  top: 33px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: #0A979Cff;
  animation-timing-function: cubic-bezier(0, 1, 1, 0);
}
.lds-ellipsis div:nth-child(1) {
  left: 8px;
  animation: lds-ellipsis1 0.6s infinite;
}
.lds-ellipsis div:nth-child(2) {
  left: 8px;
  animation: lds-ellipsis2 0.6s infinite;
}
.lds-ellipsis div:nth-child(3) {
  left: 32px;
  animation: lds-ellipsis2 0.6s infinite;
}
.lds-ellipsis div:nth-child(4) {
  left: 56px;
  animation: lds-ellipsis3 0.6s infinite;
}

.animate-zoom {
  -webkit-animation: animatezoom 0.6s;
  animation: animatezoom 0.6s
}

input[type="text"], textarea, .input-span, input[type="number"], input[type="file"], input[type="password"] {
  padding: 0.5rem;
  font-size: 1rem;
  border: 1px solid #ccc;
  border-radius: 0.5rem;
  background-color: #fefefe;
  font-family: 'Roboto', sans-serif;
}

input[type="text"].error, select.error, textarea.error, .input-span.error, input[type="number"].error, input[type="password"].error {
  border:1px solid rgba(255,0,0,0.8);
  border-radius: .25rem;
  padding:.25rem;
  background-color: rgba(255,0,0,0.2);
}

.input-container label {
  font-size: 1.2rem;
  font-weight: 400;
  font-family: 'Roboto', sans-serif;
  margin-bottom: 0.75rem;
}

#login-modal > div > main > form {
  gap:1rem;
}

#login-modal > div > main > form > div {
  display: flex;
  flex-direction: column;
}

#login-modal .help-text {
  margin-top:0.5rem;
}

.flex-center {
  display: flex;
  justify-content: space-evenly;
}

#message-slider {
  position: fixed;
  width: 100%;
  color:#333;
  left: 0;
  text-align: center;
  align-items: center;
  justify-content: center;
  display:flex;
  top:-2rem;
  height:2rem;
  transition: 0.5s;
  z-index: 2;
}

#message-slider.success {
  background-color: lightgreen;
}

#message-slider.error {
  background-color: lightpink;
}

.shake {
  animation: shake 0.2s ease-in-out 0s 2;
}

#scroll-target {
  font-size: 3rem;
  width: 100%;
  text-align: center;
}

.grid-right-button {
  display: grid;
  width: 100%;
  grid-template-columns: auto 100px;
  gap: 1rem;
}

.book-preview-description {
  overflow: hidden;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 6;
}

.post-attachment-container {
  display:grid;
  width:100%;
  gap:0.5rem;
}

.post-attachment-container.grid-1 {
  grid-template-columns: 1fr;
  aspect-ratio: 1;
}

.post-attachment-container.grid-2 {
  grid-template-columns: 1fr 1fr;
  aspect-ratio: 2;
}

.post-attachment-container.grid-3 {
  grid-template-columns: 1fr 1fr 1fr;
  aspect-ratio: 3;
}

.post-attachment-container.grid-4 {
  grid-template-columns: 1fr 1fr;
  grid-row: auto auto;
  aspect-ratio: 1;
}

.post-attachment-container div {
  background-repeat: no-repeat;
  background-position: center;
  background-size: cover;
  width:100%;
  height:100%;
}

#slideshow-modal {
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0; 
  right: 0;
  background-color: rgba(0,0,0,0.9);
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
}

#slideshow-modal > span {
  color:#fff;
  font-size:2rem;
  position:absolute;
  top:1rem;
  right:1rem;
  position: absolute;
  cursor: pointer;
}

#slideshow-content {
  width:80%;
  display:flex;
  flex-direction: column;
  color:#fefefe;
  align-items: center;
  gap: 1rem;
}

#slideshow-content img {
  width:100%;
}

.arrow {
  position: fixed;
  top: 50%;
  margin-top: -32px;
  font-size: 64px;
  color: #E2E2E2;
  font-family: arial, sans-serif;
  font-weight: bold;
  cursor: pointer;
  -webkit-user-select: none;
  -moz-user-select: none;
  user-select: none;
  text-decoration: none;
}

.arrow:hover, .navlink:hover {
  color: #777;
}

.arrow:active, .navlink:hover {
  color: #000;
}

#prev {
  left: 0.5rem;
  z-index: 2;
}

#next {
  right: 0.5rem;
  z-index: 2;
}

.link-btn {
  background: none!important;
  border: none;
  padding: 0!important;
  color: #069;
  text-decoration: underline;
  cursor: pointer;
}


@-webkit-keyframes animatezoom {
  from {-webkit-transform: scale(0)} 
  to {-webkit-transform: scale(1)}
}
  
@keyframes animatezoom {
  from {transform: scale(0)} 
  to {transform: scale(1)}
}

@keyframes lds-ellipsis1 {
  0% {
    transform: scale(0);
  }
  100% {
    transform: scale(1);
  }
}
@keyframes lds-ellipsis3 {
  0% {
    transform: scale(1);
  }
  100% {
    transform: scale(0);
  }
}
@keyframes lds-ellipsis2 {
  0% {
    transform: translate(0, 0);
  }
  100% {
    transform: translate(24px, 0);
  }
}

@keyframes shake {
  0% {
    margin-left: 0rem;
  }
  25% {
    margin-left: 0.5rem;
  }
  75% {
    margin-left: -0.5rem;
  }
  100% {
    margin-left: 0rem;
  }
}

header > div > nav {
  gap: 0.9rem;
}

.badge {
  position: relative;
  left: 0.5rem;
}

#search-container {
  flex-grow:1;
  position: relative;
  display: flex;
  justify-content: center;
}

#search-container-mobile {
  display: none;
  height:4rem;
  z-index: 1;
}

#search-input-wrapper, #search-input-wrapper-mobile {
  width: calc(100% - 2rem);
  max-width: 45ch;
  margin: 0 auto;
  display: flex;
  align-items: center;
}

#header-search-input, #header-search-input-mobile {
  width: 100%;
  border-radius: 5rem;
}
#search-results-container, #search-results-container-mobile {
  display: none;
  position: absolute;
  background-color: #fefefe;
  padding: .1rem 0.5rem;
  border-radius: .5rem;
  z-index: 2;
  box-shadow: 1px 1px 3px #ccc;
}

#search-results-container {
    margin: 0.25rem 0 0 0;
    width: calc(100% - 2rem);
    max-width: 60ch;
    margin-top: 2.2rem;
}

#search-results-inner {
  padding: 0 1rem;
}

#search-results-container-mobile {
  margin:4rem auto 0 auto;
  width: 100%;
  padding:0;
  border-radius: 0;
}
.search-results-list {
  list-style-type: none;
  padding: 0;
  margin: 0;
}
.search-results-list > li {
  margin:.1rem 0;
}

#search-close, #search-close-mobile {
  background-color: #999;
  border-radius: 5rem;
  width: 1rem;
  display: none;
  height: 1rem;
  justify-content: center;
  align-items: center;
  color: #fff;
  cursor: pointer;
  margin-left: -1.5rem;
}

.search-result-item {
  width:100%;
  padding:0.25rem 0;
  border-radius: 1rem;
}

.search-result-item > a {
  width:100%;
  display:grid;
  grid-template-columns: 1fr 4fr;
  gap:0.1rem;
  cursor: pointer;
  text-decoration: none;
  color:#333;
}

span.badge {
  left:0;
}

.search-result-item:hover {
  background-color: var(--light-neutral);
}

.search-result-cover-area, .search-result-avatar-area {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.search-result-cover-area > img {
  width:50px;
}

.search-result-metadata {
  display: flex;
  flex-direction: column;
  gap:0.1rem;
  position:relative;
}

#see-all-link, #see-all-link-mobile {
  color:#027bff;
  width: 100%;
  text-align: right;
  display: block;
  text-decoration: none;
  margin-top: .2rem;
}

.results-label {
  text-transform: uppercase;
  font-size: 1rem;
  font-weight: bold;
  color: #999;
  padding: 0 0 .5rem 1.5rem;
}

.results-count {
  font-size: smaller;
  font-weight: bold;
  padding: .1rem .25rem;
  background-color: #eee;
  border-radius: 2rem;
  margin-left: 0.5rem;
  color: #666;
  position: relative;
  top: -.1rem;
}

.search-result-title {
  color:#333;
}

.search-term-highlight {
  font-weight: bold;
  text-decoration: underline;
}

.search-result-author {
  font-weight: 400;
  color:#555;
  margin-top:0.5rem;
}

.search-result-series {
  font-weight: 500;
  color:#999;
}

.autocomplete-item {
  cursor: pointer;
}

.tags-list > li {
  cursor: default;
  display: inline-flex;
}

.smaller {
  font-size:smaller;
}

input[type='checkbox'] {
  -webkit-appearance:none;
  width:30px;
  height:30px;
  background:white;
  border-radius:5px;
  border:2px solid #555;
  display: flex;
  align-items: self-end;
  justify-content: center;
}
input[type='checkbox']:checked {
  background: #007aff;
  color:white;
  font-size:1.5rem;
}
input[type='checkbox']:checked::before {
  content: '\2713';
}

.flex-div {
  display: flex;
  align-items: center;
}

#header-search-button {
  display:none;

}

content > main {
  width:100%;
  max-width: 800px;
  margin: 0 auto;
}

@media  (max-width: calc(1200px + 3rem)) {
  content {
    display: block;
    padding:0 1rem;
  }

  content > #user-menu {
    display: none;
  }


}




@media screen and (max-width: 600px) {

   .ui-button {
    padding:0.5rem .75rem;
   }

    .hamburger-menu {
      top: 0.5rem;
      left: 0.25rem;
    }

    .grid-2-columns {
        grid-template-columns: 1fr;
    }

    .social-link {
      padding: 5px;
      font-size: 15px;
      width: 20px;

    }

    .arrow {
      position: inherit;
      display: none;
    }

    /*body > header > h1 {
      margin:0.5rem;
      display: flex;
    }

    body > header h1 > a {
      font-size:1rem;
    }*/

    body > header {
      position: sticky;
      z-index: 1;
      top:0;
      box-shadow:1px 0px 1px 1px #ccc;
    }

    #main-content {
      margin-top:2rem;
    }

    body > header.mobile-search-open {
      border-bottom:none;
      box-shadow:none;
      z-index: 2;
    }

    /*header > div > nav {
      gap:0.2rem;
      height:2rem;
    }
    
    header > div > nav > a > i {
      font-size:1rem;
    }
    header > div > nav > a {
      font-size:0.5rem;
    }

    #search-container > input {
      font-size: .75rem;
      padding: 0.25rem;
    }

    body > header h1 > a {
      padding-left:.25rem;
      padding-right:.25rem;

    }

    .badge::after {
      font-size: 0.5rem;
      border-radius: 50%;
      padding: 0.09rem 0.25rem;
      left: -8px;
      top: -0.5rem;
    }*/

    #search-container {
      display: none;
    }

    #search-container-mobile {
      display: flex;
      position: absolute;
      top: 4rem;
      left: 0;
      right: 0;
      background-color: var(--light-neutral);
      box-shadow:1px 0px 1px 1px #ccc;
      padding: 0.25rem 0;
      transform: translateY(-4rem);
      transition: transform 0.75s ease;
      z-index: -1;
    }

    #search-container-mobile.open {
      transform: translateY(0);
      z-index: 1;
    }

    #header-search-button {
      width:2rem;
      height:2rem;
      border-radius: 5rem;
      display:inline-block;
      border:none;
      background-color: var(--light-neutral);
      cursor: pointer;
      font-size: 1.5rem;
    }
}

@media print {
  body > header {
    display:none;
  }
}


#menu__toggle {
  opacity: 0;
}
#menu__toggle:checked + .menu__btn > span {
  transform: rotate(45deg);
}
#menu__toggle:checked + .menu__btn > span::before {
  top: 0;
  transform: rotate(0deg);
}
#menu__toggle:checked + .menu__btn > span::after {
  top: 0;
  transform: rotate(90deg);
}
#menu__toggle:checked ~ .menu__box {
  right: 0 !important;
}
.menu__btn {
  position: absolute;
  left: 0px;
  top: 0.5rem;
  width: 26px;
  height: 26px;
  cursor: pointer;
  z-index: 1;
}
.menu__btn > span,
.menu__btn > span::before,
.menu__btn > span::after {
  display: block;
  position: absolute;
  width: 100%;
  height: 2px;
  background-color: #616161;
  transition-duration: .25s;
}
.menu__btn > span::before {
  content: '';
  top: -8px;
}
.menu__btn > span::after {
  content: '';
  top: 8px;
}
.menu__box {
  display: block;
  position: fixed;
  top: 0;
  right: -100%;
  width: 300px;
  height: 100%;
  margin: 0;
  padding: 80px 0;
  list-style: none;
  background-color: var(--light-neutral);
  box-shadow: 2px 2px 6px rgba(0, 0, 0, .4);
  transition-duration: .25s;
}
.menu__item {
  display: grid;
  grid-template-columns: 2rem auto;
  padding: 12px 24px;
  color: #333;
  font-family: 'Roboto', sans-serif;
  font-size: 20px;
  font-weight: 600;
  text-decoration: none;
  transition-duration: .25s;
}
.menu__item:hover {
  background-color: #CFD8DC;
}

.hamburger-menu {
  z-index: 2;
  position: relative;
}

#user-menu > .menu__box {
  display: block;
  position: sticky;
  top: 1rem;
  right: -100%;
  width: 300px;
  height: auto;
}

#user-menu {
  position: sticky;
  top: 0;
  left: 0;
  align-self: start;
}

#user-menu .menu-item {
  background-color: var(--light-neutral);
  border-radius: 10rem;
  padding: 1rem 1.5rem;
  text-align: center;
  font-family: 'Roboto', sans-serif;
  text-transform: capitalize;
  font-size: 1.3rem;
  border: 1px solid #ccc;
  cursor: pointer;
  transition: .25s;
  text-decoration: none;
  color:#333;
}

#user-menu .menu-item:hover {
  box-shadow: 2px 2px 3px #BBB;
}

#user-menu .selected {
  background-color: var(--accent-light);
  color: #fefefe;
}

#user-menu .selected:hover {
  box-shadow: none;
}