@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;600&display=swap');

:root {
  --bg-0: #101030;
  --bg-1: #050515;
  --blob-1: rgb(220, 145, 255);
  --blob-2: rgb(29, 83, 245);
  --blob-3: rgb(0, 255, 255);
  --blob-4: rgb(255, 48, 131);
  /* --blob-1: #dc91ff;
  --blob-2: #1d53f5;
  --blob-3: #00ffff;
  --blob-4: #ff3083; */
  --light-gray: #999;
}

html,
body {
  height: 100%;
  width: 100%;
  margin: 0;
  padding: 0;
  background: #000;
  display: flex;
  justify-content: center;
  align-items: center;
  color: #fff;
  font-family: "Poppins", "Helvetica Neue", Helvetica, sans-serif;
  background: var(--bg-1);
}

a {
  text-decoration: underline;
  color: inherit;
}

.container {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 95%;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;

}

.content-wrapper {
  height: 90%;
  width: 90%;
  max-width: 700px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 25px;
  margin: 0 auto;
}

.headline-wrapper {
  flex: 0 0 10%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  font-size: 2rem;
  margin: 0;
  text-align: center;
}

.headline {
  letter-spacing: -5px;
  line-height: 1;
  text-transform: uppercase;
}

.headline h1 {
  margin: 1rem auto 0;
}

.headline h1 span {
  color: var(--blob-4);
}

.subhead {
  font-size: 1.5rem;
  font-weight: 400;
}

.small-text {
  font-size: 0.95rem;
}

.caption-box {
  margin: 3rem 0 0;
  height: 100%;
  flex-grow: 1;
  bottom: 0;
  font-size: 1.2rem;
  font-weight: 400;
  text-align: center;
  color: white;
  position: relative;
  width: 100%;
  overflow: hidden;
  touch-action: none;
}

.caption-box::before,
.caption-box::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  height: 40px;
  pointer-events: none;
  z-index: 2;
}

.caption-box::before {
  top: 0;
  background: linear-gradient(to bottom, rgba(5, 5, 21, 1), rgba(0, 0, 0, 0));
}

.caption-box::after {
  bottom: 0;
  background: linear-gradient(to top, rgba(5, 5, 21, 1), rgba(0, 0, 0, 0));
}

.caption-scroll {
  position: relative;
  top: 0;
  left: 0;
  width: 100%;
  white-space: pre-line;
  z-index: 1;
  background: transparent;
  color: var(--light-gray);
  will-change: transform;
}

.caption-scroll div span {
  display: block;
  margin: 2rem 0 0;
}

.caption-scroll .bold-caption {
  font-weight: 600;
  color: var(--blob-4);
}

/* CSS keyframes removed; JS drives transform translateY for smooth control */

.blobs {
  position: relative;
  cursor: pointer;
  width: auto;
  height: 100%;
  aspect-ratio: 1 / 1;
  max-width: 100%;
  margin: 2rem auto;
}

.blob {
  --scale: 1;
  --border-thickness: 6px;
  position: absolute;
  top: 50%;
  left: 50%;
  width: var(--w);
  height: 100%;
  transform-origin: 50% 50%;
  transform: translate(-50%, -50%) scale(var(--scale));
  border-radius: 50%;
  border: var(--border-thickness) solid var(--blob-color);
  mix-blend-mode: color-dodge;
  filter: brightness(1) blur(7px) drop-shadow(0 0 0 var(--blob-color));
  animation: rotate-blob var(--rot) linear infinite;
  z-index: 1;
}

@keyframes rotate-blob {
  from {
    transform: translate(-50%, -50%) scale(var(--scale)) rotate(0deg);
  }

  to {
    transform: translate(-50%, -50%) scale(var(--scale)) rotate(360deg);
  }
}

.blob-1 {
  --w: 100%;
  --rot: 22s;
  --blob-color: var(--blob-1);
}

.blob-2 {
  --w: 95%;
  --rot: 30s;
  --blob-color: var(--blob-2);
  transform: rotate(-12deg);
  animation-direction: reverse;
}

.blob-3 {
  --w: 90%;
  --rot: 10s;
  --blob-color: var(--blob-3);
}

.blob-4 {
  --w: 80%;
  --rot: 30s;
  --border-thickness: 25px;
  --blob-color: var(--blob-4);
  animation-direction: reverse;
}

.play-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 100;
  width: 80px;
  height: 80px;
  background: transparent;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  mix-blend-mode: screen;
  overflow: visible;
}

.play-icon svg {
  width: 100%;
  height: 100%;
  /* stroke: rgba(255, 255, 255, 0.95); */
  stroke: var(--blob-4);
  filter: drop-shadow(0 0 6px var(--blob-4));
  stroke-width: 6px;
  fill: none;
  overflow: visible;
}

.play-icon .play-triangle {
  transform-origin: 50% 50%;
  transform: rotate(90deg);
}

.play-icon .play-triangle,
.play-icon .pause-bars {
  opacity: 0;
  transition: opacity 250ms ease;
}

.play-icon.play .play-triangle {
  opacity: 1;
}

.play-icon.play .pause-bars {
  opacity: 0;
}

.play-icon.pause .play-triangle {
  opacity: 0;
}

.play-icon.pause .pause-bars {
  opacity: 1;
}

.time-counter {
  flex: 0 0 auto;
  text-align: center;
  line-height: 1;
  white-space: nowrap;
  pointer-events: none;
  color: var(--light-gray);
  padding: .5rem 0;
}

.player-controls {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  max-width: 640px;
  margin: 0 auto;
  padding: 8px 0;
}

.play {
  display: inline-grid;
  place-items: center;
  cursor: pointer;
  z-index: 5;
}

.info-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  width: 100%;
}

.visuals {
  display: none;
}

.progress-wrap {
  position: relative;
  flex: 1 1 auto;
  height: 4px;
  width: 100%;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.02);
  -webkit-tap-highlight-color: transparent;
  touch-action: none;
}

.progress-fill {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 0%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.2), var(--blob-4) 60%);
  box-shadow: 0 0 8px rgba(255, 48, 131, 0.12);
  transition: width 0.08s linear;
  touch-action: none;
}

.progress-head {
  position: absolute;
  top: 50%;
  left: 0%;
  transform: translate(-50%, -50%);
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--blob-4);
  border: 2px solid rgba(0, 0, 0, 0.12);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.35), 0 0 8px rgba(255, 48, 131, 0.12);
  filter: drop-shadow(0 0 6px var(--blob-4));
  cursor: grab;
  z-index: 6;
  touch-action: none;
  transition: transform 0.06s linear;
}

.progress-head:active {
  cursor: grabbing;
  transform: translate(-50%, -50%) scale(1.05);
}

.progress-head:focus {
  outline: none;
  box-shadow: 0 0 0 6px rgba(255, 48, 131, 0.08), 0 6px 14px rgba(0, 0, 0, 0.35);
}

.time-counter-display {
  font-size: 14px;
  color: #fff;
  line-height: 1;
  user-select: none;
}

.paused-animation .blob {
  animation-play-state: paused;
}

/* Footer */
.site-footer {
  width: 100%;
  height: 50px;
  max-width: 800px;
  display: flex;
  justify-content: space-evenly;
  align-items: center;
  text-align: center;
  font-size: 0.8rem;
  color: var(--light-gray);
  gap: 1rem;
}


.footer-donation {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  flex: 0 1 auto;
}

/* Contact panel */
.contact-panel {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  display: grid;
  place-items: center;
  z-index: 1000;
  /* Fade in/out controlled by .open class */
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 180ms ease-in-out, visibility 0s linear 180ms;
}

/* Ensure hidden state actually hides overlay regardless of other display rules */
.contact-panel[hidden] {
  display: none !important;
}

.contact-form[hidden] {
  display: none !important;
}

#contact-result[hidden] {
  display: none !important;
}

.contact-panel.open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition: opacity 180ms ease-in-out;
}

.contact-inner {
  width: min(640px, 92vw);
  background: var(--bg-1);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
  border-radius: 12px;
  padding: 16px;
  transform: translateY(8px) scale(0.98);
  transition: transform 180ms ease-in-out;
}

.contact-panel.open .contact-inner {
  transform: translateY(0) scale(1);
}

.contact-title {
  margin: 0 0 8px;
}

.contact-back {
  background: transparent;
  border: none;
  color: var(--light-gray);
  cursor: pointer;
  font-size: 0.9rem;
}

.contact-form {
  display: grid;
  gap: 12px;
}

.field {
  display: grid;
  gap: 6px;
}

.field input,
.field textarea {
  width: 100%;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(0, 0, 0, 0.2);
  color: #fff;
}

.checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
}

.actions {
  display: flex;
  gap: 10px;
}

.actions button {
  background: var(--blob-4);
  color: #fff;
  border: none;
  padding: 10px 14px;
  border-radius: 8px;
  cursor: pointer;
}

.form-error {
  color: #ff6b6b;
  font-size: 0.9rem;
}

.contact-result {
  font-size: 1rem;
  color: #fff;
}

/* Success-state back button styled like primary */
.contact-result .contact-back {
  display: inline-block;
  margin-top: 10px;
  background: var(--blob-4);
  color: #fff;
  border: none;
  padding: 10px 14px;
  border-radius: 8px;
  cursor: pointer;
}

.contact-result .contact-back:focus {
  outline: none;
  box-shadow: 0 0 0 6px rgba(255, 48, 131, 0.12), 0 6px 14px rgba(0, 0, 0, 0.35);
}

/* Honeypot field hidden visually */
.hp {
  position: absolute;
  left: -9999px;
  opacity: 0;
}

@media (max-width: 800px) {
  .site-footer {
    flex-direction: column;
    flex-flow: column-reverse;
    height: auto;
  }

  .footer-donation {
    flex-direction: column;
  }
}

@media (max-width: 480px) {
  .play {
    width: 44px;
    height: 44px;
  }

  .progress-wrap {
    height: 6px;
  }

  .progress-head {
    width: 14px;
    height: 14px;
  }

  .time-counter-display {
    font-size: 12px;
  }

  .time-counter {
    font-size: 0.9rem;
  }

  .headline {
    font-size: 1.1rem;
    padding: 0 1rem;
    letter-spacing: -4px;
  }

  .subhead {
    font-size: 1rem;
    padding: .5rem 0 0;
  }

  .caption-box {
    font-size: .8rem;
    padding: 0.5rem 0.75rem;
  }

  .play-icon {
    width: 64px;
    height: 64px;
  }

  .play-icon svg {
    stroke-width: 4px;
  }

  .blobs {
    max-width: 240px;
    max-height: 240px;
  }


}