@import "/css/normalize.css";
@import "/fontawesome/css/fontawesome.css";
@import "/fontawesome/css/regular.css";
@import "https://fonts.cdnfonts.com/css/fivo-sans";
@import "https://fonts.googleapis.com/css2?family=Source+Sans+3:ital,wght@0,200..900;1,200..900";

:root {
  --font-display: 'Fivo Sans', sans-serif;
  --font-body: 'Source Sans 3', sans-serif;
  --color-teal: rgb(0, 130, 130);
  --color-teal-lightened: rgb(43, 148, 145); /* 80% teal 20% cream */
  --color-deepsea: rgb(30 45 80);
  --color-sunny: rgb(225 215 130);
  --color-cream: rgb(227 225 210);
  --color-clam: rgb(25 20 45);
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--color-cream);
  font-family: var(--font-body);
  font-size: 18px;
  font-weight: 400;
  color: var(--color-deepsea);
}

a {
  color: var(--color-deepsea);
  text-decoration: underline;
  font-style: normal;
}
a, summary {
  cursor: pointer;
}
a:hover, summary:hover {
  color: var(--color-teal);
}

/* Ensure consistent styling */
summary {
  display: block;
}
summary::before {
  margin-right: 1ch;
  font-size: 0.8em;
  display: inline-block;
  /* right triangle followed by unicode variation selector FE0E */
  content: '▶︎';
  transition: 0.2s;
}
details[open] > summary::before {
  transform: rotate(90deg);
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--color-deepsea);
  line-height: 1;
  margin-block-start: 1.25em;
  margin-block-end: -0.25em;
}

.visual-break::after {
  content: "\a";
  white-space: pre;
}

main {
  flex: 1;
  line-height: 1.25em;
  width: 100%;
  padding: 1em;
}

header {
  padding: 2em;
  width: 100%;
  background: var(--color-teal);
  background: linear-gradient(0deg, var(--color-teal) 0%, var(--color-teal-lightened) 100%);
}

article {
  max-width: 45em;
  margin: 0 auto;
}

hr {
  height: 0;
  max-width: 154px;
  padding: 2em 0;
  border: none;
  background-image: url("/images/squiggly-line.svg");
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
}

.site-title {
  text-decoration: none;
  font-size: 1.5em;
}
.site-title h1 {
  color: var(--color-cream)
}
.site-title em {
  font-style: normal;
  color: var(--color-sunny)
}

.error-page {
  text-align: center;
}

.centered {
  text-align: center;
}

.hero {
  text-align: center;
  font-size: 2em;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.hero-title,
.hero-subtitle {
  margin: 0;
  line-height: 0.95;
  display: block;
}

.hero-title {
  font-size: 2em;
  color: var(--color-cream);
}

.hero-subtitle {
  margin-top: -.1em;
  font-size: 1.6em;
  color: var(--color-sunny);
}

.hero-dates,
.hero-location {
  font-size: 1em;
  margin: 0;
}

.hero-dates {
  margin-top: 1em;
  color: var(--color-sunny);
}
.hero-location {
  color: var(--color-cream);
}

.mail-link {
  margin-top: 1em;
  color: var(--color-deepsea);
}
.mail-link:hover {
  color: var(--color-sunny);
}

/* Carousel Styles */
.carousel {
  position: relative;
  width: 100%;
  margin: 2em auto;
}

.carousel-track-container {
  overflow: hidden;
  border-radius: 10px;
}

.carousel-track {
  display: flex;
  transition: transform 0.5s ease-in-out;
  user-select: none;
  -webkit-user-select: none;
  touch-action: pan-y pinch-zoom;
}

.carousel-slide {
  min-width: 100%;
  position: relative;
}

.carousel-slide img {
  width: 100%;
  height: auto;
  display: block;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: var(--color-deepsea);
}

.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: var(--color-cream);
  opacity: 0.1;
  border: none;
  color: var(--color-deepsea);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
  transition: all 0.3s ease;
}

.carousel-btn:hover {
  opacity: 0.4;
  transform: translateY(-50%) scale(1.1);
}

.carousel-btn-prev {
  left: 20px;
}

.carousel-btn-next {
  right: 20px;
}

.carousel-indicators {
  position: relative;
  display: flex;
  justify-content: center;
  gap: 8px;
  top: -30px;
}

.carousel-indicator {
  width: 12px;
  height: 12px;
  padding: 0;
  border-radius: 50%;
  border: none;
  background: var(--color-cream);
  opacity: 0.4;
  cursor: pointer;
  transition: all 0.3s ease;
}

.carousel-indicator:hover {
  opacity: 0.75;
}

.carousel-indicator.active {
  opacity: 0.75;
  transform: scale(1.3);
}

@media screen and (max-width: 640px) {
  .carousel {
    width: 100vw;
    left: -1em;
  }

  .carousel-track-container {
    border-radius: 0;
  }

  .carousel-btn-prev,
  .carousel-btn-next {
    display: none
  }
}

/* Lightbox Styles */
.lightbox {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 9999;
  background-color: rgba(0, 0, 0, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  align-items: center;
  justify-content: center;
  animation: lightbox-fade-in 0.3s ease-out;
}

.lightbox.active {
  display: flex;
}

@keyframes lightbox-fade-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.lightbox-image {
  max-width: 95%;
  max-height: 95%;
  object-fit: contain;
  animation: lightbox-image-zoom-in 0.3s ease-out;
}

@keyframes lightbox-image-zoom-in {
  from {
    transform: scale(0.9);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: rgba(255, 255, 255, 0.1);
  border: 2px solid rgba(255, 255, 255, 0.3);
  color: white;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  z-index: 10000;
}

.lightbox-close:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.5);
  transform: scale(1.1);
}

.carousel-slide img {
  cursor: pointer;
}

@media screen and (max-width: 640px) {
  .lightbox-close {
    top: 10px;
    right: 10px;
    width: 40px;
    height: 40px;
    font-size: 1.2rem;
  }
}

@keyframes wave {
  0% {
    transform: translate(0px, 0px) rotate(0deg);
  }
  13% {
    transform: translate(3px, 3px) rotate(4deg);
  }
  38% {
    transform: translate(-8px, 6px) rotate(-5deg);
  }
  63% {
    transform: translate(3px, 3px) rotate(5deg);
  }
  88% {
    transform: translate(-3px, -5px) rotate(-4deg);
  }
  100% {
    transform: translate(0px, 0px) rotate(0deg);
  }
}

.animate-wave {
  transform-origin: 50% 130%;
  animation: wave 25s cubic-bezier(0.37, 0, 0.63, 1) 0s infinite;
}

.animated-squiggly-line {
  margin-top: 1em;
  max-width: 10em;
}

.squiggly-line {
  fill: none;
  stroke: var(--color-deepsea);
  stroke-width: 4;
}

@keyframes squiggle1 { to { stroke-dashoffset: 500; } }
.animated-squiggly-line .line1 {
  stroke-dasharray: 250;
  animation: squiggle1 3s linear infinite reverse;
}

@keyframes squiggle2 { to { stroke-dashoffset: 400; } }
.animated-squiggly-line .line2 {
  stroke-dasharray: 200;
  animation: squiggle2 5s linear infinite reverse;
}

@keyframes squiggle3 { to { stroke-dashoffset: 1000; } }
.animated-squiggly-line .line3 {
  stroke-dasharray: 500;
  animation: squiggle3 7s linear infinite reverse;
}

.play-button {
  position: absolute;
  top: 2rem;
  right: 2rem;
  background: none;
  border: none;
  padding: none;
  cursor: pointer;
  color: var(--color-deepsea);
  font-size: 2rem;
}
@media screen and (max-width: 640px) {
  .play-button {
    top: 1rem;
    right: 1rem;
  }
}
.play-button:hover {
  color: var(--color-sunny);
}
.play-button--playing {
  display: none;
}
.play-button--paused {
  opacity: 0.7;
}
.play-button.playing .play-button--playing {
  display: initial;
}
.play-button.playing .play-button--paused {
  display: none;
}

.members-link {
  display: inline-block;
  margin-top: 2em;
  font-size: 1.25rem;
  text-decoration: none;
}

ul.timeline {
  --stroke: 3px;
  --dot-size: 17px;

  display: flex;
  list-style: none;
  padding: 0 1em;
  margin: 2em 0;

  li {
    flex: 1;
    position: relative;

    &::before { /* dots on the line */
      content: '';
      position: absolute;
      z-index: 1;
      width: var(--dot-size);
      height: var(--dot-size);
      background-color: var(--color-teal);
      border: var(--stroke) solid var(--color-deepsea);
      border-radius: 50%;
    }
  }
}

/* SMALL SCREEN: vertical timeline */
ul.timeline {
  --vertical-gap: 20px;
  flex-direction: column;

  li {
    border-left: var(--stroke) solid var(--color-teal);
    padding-left: calc(1em + var(--dot-size));
    padding-top: calc(var(--vertical-gap)/2);
    padding-bottom: calc(var(--vertical-gap)/2);

    &::before { /* dots on the line */
      top: calc(var(--vertical-gap)/2);
      left: calc(0px - var(--dot-size)/2 - var(--stroke)*1.5);
    }
  }
}


@media screen and (min-width: 641px) {
  ul.timeline {
    flex-direction: row;

    li {
      border: none;
      border-top: var(--stroke) solid var(--color-teal);
      padding: 0;
      padding-top: calc(0.5em + var(--stroke)/2 + var(--dot-size)/2);
      text-align: center;

      &::before { /* dots on the line */
        top: calc(0px - var(--dot-size)/2 - var(--stroke)*1.5);
        left: calc(50% - var(--dot-size) / 2 - var(--stroke));
      }
    }
  }
}
