* {
  box-sizing: border-box;
}

html {
  font-size: 16px;
  font-family: Inter, sans-serif;
}

body {
  background: var(--light);
  color: #333333;
  position: relative;
  padding: 0;
  margin: 0;
  min-width: 300px;
}

h1, h2, h3 {
  color: #333333;
}

a, a:visited {
  color: var(--primary);
}
a:hover, a:visited:hover {
  color: var(--dark);
}

a.btn {
  border-radius: 1rem 1rem;
  padding: 1rem 3rem;
  font-size: larger;
  background: var(--primary);
  color: #f0f0f0 !important;
  text-decoration: none;
  font-weight: bold;
}

input[type=checkbox].toggle {
  font-size: 1.1rem;
  appearance: none;
  width: 3.5em;
  height: 1.5em;
  background: var(--primary);
  border-radius: 3em;
  position: relative;
  cursor: pointer;
  outline: none;
  transition: all 0.2s ease-in-out;
  border: 1px solid var(--dark);
}
input[type=checkbox].toggle:checked {
  background: var(--light);
}
input[type=checkbox].toggle:after {
  position: absolute;
  content: "";
  width: 1.5em;
  height: 1.5em;
  border-radius: 50%;
  background: url("/gen/img/icon/heart-primary.svg") no-repeat 50% 50% #f0f0f0;
  background-size: 50% 50%;
  border: solid 1px var(--dark);
  box-shadow: 0 0 0.25em rgba(51, 51, 51, 0.3);
  transform: translateY(-2px);
  left: -0.25em;
  transition: all 0.2s ease-in-out;
}
input[type=checkbox].toggle:checked:after {
  left: calc(100% - 1.25em);
  background-color: var(--light);
}

/* Common to all Bardsly */
body .installer {
  display: none;
}

body.install .installer {
  display: block;
}

main p.loading, main p.sorry, main > section {
  display: none;
}
main[data-selected=none] p.loading {
  display: block;
}
main[data-selected=none] > section {
  display: none;
}
main[data-selected=empty] p.sorry {
  display: block;
}
main[data-selected=empty] nav section.top {
  display: none;
}
main[data-selected=artists] > section#artists, main[data-selected=shows] > section#shows, main[data-selected=about] > section#about, main[data-selected=tickets] > section#tickets, main[data-selected=map] > section#map {
  display: flex;
}
main p.loading {
  font-size: 4rem;
  max-width: 50rem;
  margin: 20dvh auto;
  text-align: center;
}
main p.sorry {
  font-size: 2rem;
  line-height: 1.75;
  max-width: 50rem;
  margin: 20dvh auto;
  text-align: center;
}
main nav {
  padding: env(safe-area-inset-top) env(safe-area-inset-right) 0 env(safe-area-inset-left);
  position: fixed;
  width: 100%;
  height: 6rem;
  background: var(--primary);
  z-index: 1;
  display: flex;
  justify-content: space-between;
  gap: 1rem;
}
main nav h1 {
  padding: 0;
  margin: 0;
  display: inline-block;
}
main nav h1 span {
  display: none;
}
main nav ul {
  display: inline-block;
  list-style: none;
  padding: 0;
  margin: 0 auto;
}
main nav ul li {
  padding: 0;
  margin: 0;
  display: inline-block;
  text-transform: uppercase;
  line-height: 6rem;
}
main nav ul li a, main nav ul li a[href] {
  text-decoration: none;
  padding: 0.5rem 0.5rem;
  color: #f0f0f0;
  font-weight: bold;
  font-size: 85%;
}
main nav ul li a:hover, main nav ul li a:active, main nav ul li a.current, main nav ul li a[href]:hover, main nav ul li a[href]:active, main nav ul li a[href].current {
  background: var(--medium-light);
  color: var(--dark);
  border-radius: 0.25rem 0.25rem;
}
main nav .watching {
  margin: 0 1rem;
  display: flex;
  justify-content: center;
  align-items: center;
}
main > section {
  gap: 1rem;
  max-width: 100%;
  padding: calc(env(safe-area-inset-top) + 6rem) 0 calc(env(safe-area-inset-bottom) + 1rem) 0;
}
main > section > h2 {
  background: var(--medium-light);
  color: #333333;
  width: 100%;
  text-align: center;
  padding: 0.5rem;
  margin: 0 0 0.5rem 0;
  position: sticky;
  top: 6rem;
  z-index: 2;
  height: 2.75rem;
}
main > section#shows {
  flex-wrap: wrap;
}
main > section#shows article {
  width: 100%;
  height: 100%;
  overflow-x: scroll;
  margin: 0 1rem;
}
main > section#shows article > header ul {
  list-style: none;
  display: block;
  margin: 0;
  padding: 0 0 0.25rem 0;
  white-space: nowrap;
}
main > section#shows article > header ul li {
  width: 8rem;
  line-height: 1.5;
  font-size: 0.65rem;
  margin: 0 1rem 0 0;
  padding: 0.1rem;
  display: inline-block;
  text-align: center;
  color: #333333;
  border: solid 2px black;
  overflow: hidden;
  text-overflow: ellipsis;
}
main > section#shows article div.day {
  position: relative;
  width: 100%;
  background: repeating-linear-gradient(var(--medium-light), var(--medium-light) calc(10rem - 1px), var(--light) 10rem, var(--light) 20rem);
}
main > section#shows article div.day span.time-bug {
  position: absolute;
  width: 8rem;
  opacity: 20%;
  font-size: 1.5rem;
  margin-top: 0.5rem;
  color: var(--dark);
  text-align: center;
}
main > section#shows article div.day span.time-bug.current {
  color: var(--primary);
  opacity: 70%;
}
main > section#shows article div.day div.show {
  box-sizing: border-box;
  padding: 0;
  width: 8rem;
  border: solid 1px var(--dark);
  box-shadow: 2px 2px 4px #333333;
  overflow: hidden;
  position: absolute;
  font-size: 0.85rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
main > section#shows article div.day div.show.semi-hidden {
  opacity: 40%;
}
main > section#shows article div.day div.show header, main > section#shows article div.day div.show footer {
  background: rgba(0, 0, 0, 0.5019607843);
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  align-items: center;
}
main > section#shows article div.day div.show header {
  padding: 0.25rem;
}
main > section#shows article div.day div.show header img.star {
  width: 2rem;
}
main > section#shows article div.day div.show header h3 {
  font-weight: normal;
  margin: 0;
  line-height: 1.25;
  font-size: 0.85em;
  color: #f0f0f0;
}
main > section#shows article div.day div.show footer {
  font-size: 0.75rem;
  padding: 0.1rem;
}
main > section#shows article div.day div.show footer span {
  padding: 0.15rem;
  color: #f0f0f0;
}
main > section#shows article div.day div.show footer span.venue {
  text-align: right;
  background: var(--light);
  color: var(--dark);
}
main > section#artists {
  justify-content: center;
  flex-wrap: wrap;
}
main > section#about {
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
}
main > section#about p {
  max-width: 50rem;
  width: 100%;
  font-size: 1rem;
  line-height: 1.25;
  margin: 0.5rem 0;
  text-align: justify;
}
main > section#about p img.right {
  max-height: 4rem;
  float: right;
  margin: 0.25rem 0 1rem 2rem;
}
main > section#about p img.left {
  max-height: 4rem;
  float: left;
  margin: 0.25rem 2rem 1rem 0;
}
main > section#tickets {
  padding: calc(env(safe-area-inset-top) + 6rem) 1rem calc(env(safe-area-inset-bottom) + 1rem) 1rem;
  flex-direction: column;
  gap: 3rem;
  justify-content: center;
  align-items: center;
  height: min(100dvh - 4rem, 20rem);
}
main > section#tickets h2, main > section#tickets p, main > section#tickets a.btn {
  margin: 0;
}
main > section#map {
  padding: calc(env(safe-area-inset-top) + 6rem) 0 calc(env(safe-area-inset-bottom) + 1rem) 0;
  flex-direction: column;
  gap: 1rem;
  justify-content: center;
  align-items: center;
}
main > section#map img {
  max-width: calc(100% - 2rem);
  margin: 0 1rem;
}

#ui {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  z-index: 3;
  height: 100%;
  width: 100%;
  padding: 1rem;
  background: var(--primary);
  color: #333333;
  border: #333333;
  overflow-y: scroll;
}
#ui h2 {
  width: 100%;
  text-align: center;
  color: #f0f0f0;
  font-size: 2rem;
  margin: 0 auto 2rem;
  padding: 0;
}
#ui ul {
  margin: 0;
  padding: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2rem 2rem;
  flex-wrap: wrap;
}
#ui ul li {
  list-style: none;
  border: solid 2px var(--dark);
  box-shadow: 2px 2px 4px #333333;
  max-width: 10rem;
  width: 20rem;
  background: var(--medium-light);
  color: #333333;
  border-radius: 1rem 1rem;
  margin: 0;
  padding: 0;
}
#ui ul li h4 {
  margin: 0;
  padding: 0.5rem;
  background: var(--dark);
  color: #f0f0f0;
  font-size: 1.5rem;
  font-weight: bold;
  text-align: center;
  border-top-left-radius: 1rem 1rem;
  border-top-right-radius: 1rem 1rem;
}
#ui ul li img {
  display: block;
  margin: 1rem auto;
  height: 3rem;
}
#ui ul li p {
  text-align: center;
  font-size: 0.85rem;
  margin: 0;
  padding: 0.5rem;
  height: 6rem;
}
#ui ul li:hover {
  background: #f0f0f0;
}

img.like, img.star {
  aspect-ratio: 1/1;
  opacity: 40%;
}
img.like.liked, img.like.starred, img.star.liked, img.star.starred {
  opacity: 100%;
  filter: drop-shadow(0.5px 0.5px var(--dark)) drop-shadow(-0.5px 0.5px var(--dark)) drop-shadow(0.5px -0.5px var(--dark)) drop-shadow(-0.5px -0.5px var(--dark));
}

aside.artist {
  position: relative;
  box-shadow: 2px 2px 4px #333333;
  width: 9rem;
  height: 9rem;
  z-index: 0;
  border-radius: 1rem 1rem;
  overflow: hidden;
}
aside.artist img.artist {
  width: 100%;
  aspect-ratio: 1/1;
  object-fit: cover;
  display: block;
  border-radius: 1rem 1rem;
}
aside.artist img.like {
  position: absolute;
  top: 0.25rem;
  right: 0.5rem;
  width: 3rem;
}
aside.artist h3 {
  background: var(--dark-glass);
  bottom: 0;
  color: white;
  line-height: 1.25;
  font-size: 0.85em;
  font-weight: normal;
  left: 0;
  margin: 0;
  padding: 0.25rem 0.5rem 0.5rem 0.5rem;
  overflow: hidden;
  position: absolute;
  text-align: center;
  text-overflow: ellipsis;
  width: 100%;
}

aside.panel {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100dvw;
  max-height: 100dvh;
  background: #f0f0f0;
  color: #333333;
  border: solid 1px #333333;
  padding: 0;
  overflow-y: scroll;
  overscroll-behavior: contain;
}
aside.panel header {
  position: fixed;
  height: 3rem;
  top: 0;
  width: 100%;
  background: var(--primary);
  color: #f0f0f0;
}
aside.panel header h2 {
  margin: 0;
  padding: 0.5rem 1rem;
  font-size: 1.25rem;
  font-weight: bold;
  width: 100%;
  max-width: calc(100svw - 3rem);
  line-height: 2rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: #f0f0f0;
}
aside.panel .details {
  width: 100%;
  padding: 4rem 1rem 1rem 1rem;
}

aside#artist-panel {
  z-index: 5;
}
aside#artist-panel .details {
  display: grid;
  grid-template-columns: auto 1fr 1fr;
  grid-template-rows: auto auto auto auto;
  gap: 1rem 2rem;
  grid-template-areas: "big description description" "big location    genres" "big socials     socials" "big shows       shows";
}
aside#artist-panel .details div.big {
  grid-area: big;
  position: relative;
  width: fit-content;
  height: fit-content;
}
aside#artist-panel .details div.big img.artist {
  max-width: 40rem;
  border-radius: 1rem 1rem;
}
aside#artist-panel .details div.big img.like {
  width: 4rem;
  position: absolute;
  top: 1rem;
  right: 1rem;
}
aside#artist-panel .details .description {
  grid-area: description;
  font-size: 1.25rem;
}
aside#artist-panel .details .location {
  grid-area: location;
  color: #333333;
  padding: 0.25rem 0;
  text-align: left;
}
aside#artist-panel .details .genres {
  grid-area: genres;
  padding: 0.25rem 0.5rem;
  color: var(--primary);
  text-align: right;
  vertical-align: middle;
}
aside#artist-panel .details .genres span {
  color: #333333;
}
aside#artist-panel .details .socials {
  grid-area: socials;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
}
aside#artist-panel .details .socials img.social {
  width: 7rem;
  border-radius: 1rem 1rem;
}
aside#artist-panel .details .shows {
  grid-area: shows;
}
aside#artist-panel .details .shows h3 {
  margin: 0 0 0.5rem 0;
  font-size: 1.25rem;
  color: var(--primary);
  font-weight: bold;
}
aside#artist-panel .details .shows h4 {
  margin: 0.25rem 0;
  font-size: 1rem;
  font-weight: bold;
  color: #333333;
}

aside#show-panel {
  z-index: 4;
}
aside#show-panel .details .description {
  font-size: 1.25rem;
  text-align: center;
}
aside#show-panel .details .description p {
  margin: 1rem auto;
  max-width: 60rem;
}
aside#show-panel .details .artists {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
}
aside#show-panel .details .featuring {
  display: block;
  text-align: center;
}
aside#show-panel .details .featuring h4 {
  margin: 1rem auto 0.25rem auto;
}
aside#show-panel .details .featuring p {
  margin: 0.25rem auto 1rem auto;
}
aside#show-panel .details .map {
  margin-top: 1rem;
  width: 100%;
  text-align: center;
}
aside#show-panel .details .map img {
  width: 100%;
  max-width: 640px;
  max-height: calc(100svh - 4rem);
  margin: 0 auto;
}

#overlay-blur {
  display: none;
  width: 100dvw;
  height: 100dvh;
  overflow: auto;
  z-index: 2;
  position: fixed;
  top: 0;
  left: 0;
  backdrop-filter: blur(5px);
  overscroll-behavior: contain;
}

#close {
  display: none;
  position: fixed;
  top: 0.5rem;
  right: 1rem;
  height: 2rem;
  width: 2rem;
  z-index: 6;
}

html.inert {
  overflow: hidden;
}

@media screen and (max-width: 1000px) {
  main img.like {
    width: 2rem;
  }
  main > section {
    padding-left: 0.5rem;
    padding-right: 0.5rem;
  }
  aside#artist-panel .details {
    display: block;
  }
  aside#artist-panel .details div.big {
    width: 100%;
    max-width: 100%;
  }
  aside#artist-panel .details div.big img.artist {
    width: 100%;
    max-width: 100%;
    max-height: 100%;
    margin-left: auto;
    margin-right: auto;
    display: block;
  }
  aside#artist-panel .details .description, aside#artist-panel .details .location, aside#artist-panel .details .genres, aside#artist-panel .details .socials, aside#artist-panel .details .shows {
    width: 100%;
    margin-top: 1rem;
    margin-bottom: 0;
  }
  aside#artist-panel .details .location {
    float: left;
  }
  aside#artist-panel .details .genres {
    float: right;
  }
  aside#artist-panel .details .location, aside#artist-panel .details .genres {
    width: fit-content;
    margin-bottom: 1rem;
  }
}
@media screen and (max-width: 500px) {
  main > section {
    padding-left: 0.25rem;
    padding-right: 0.25rem;
    gap: 0.5rem;
  }
  main nav {
    gap: 0.25rem;
  }
  #open, #close {
    right: 0.5rem;
  }
  aside#artist-panel .details .socials img.social {
    width: 7rem;
  }
  aside.artist {
    height: 7rem;
    width: 7rem;
  }
  aside.artist h3 {
    font-size: 0.75rem;
    padding: 0.25rem;
  }
  aside.panel header h2 {
    max-width: calc(100svw - 2rem);
  }
}
