/* Experiments page: title and intro (match other category pages) */

.page-title {
  margin: 0 0 0.5rem 0;
  color: var(--color-heading);
  font-size: 1.5rem;
  font-weight: 600;
}

body.light-mode .page-title {
  color: var(--color-heading-light);
}

.page-intro {
  margin: 0 0 1rem 0;
  color: var(--color-subheading);
  font-size: 1rem;
  line-height: 1.6;
  max-width: 64rem;
  text-align: justify;
  text-justify: inter-word;
}

body.light-mode .page-intro {
  color: var(--color-subheading-light);
}

.experiments-subheading {
  margin: 1rem 0 0.5rem 0;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #ffffff;
}

body.light-mode .experiments-subheading {
  color: #1a1a1a;
}

.experiments-prompt {
  margin: 0 0 2rem 0;
  margin-left: calc((100% - 64rem) / 2);
  margin-right: auto;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  line-height: 1.5;
  color: var(--color-heading);
  width: fit-content;
  align-self: flex-start;
  background: rgba(255, 255, 255, 0.08);
  border: 0.0625rem solid rgba(255, 255, 255, 0.35);
  border-radius: 0.375rem;
}

body.light-mode .experiments-prompt {
  color: var(--color-heading-light);
  background: rgba(0, 0, 0, 0.06);
  border-color: rgba(0, 0, 0, 0.2);
}

.experiments-videos {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  margin-top: 2rem;
  max-width: 64rem;
}

.experiments-video-wrap {
  margin: 0;
}

.experiments-video {
  display: block;
  width: 100%;
  max-width: 64rem;
  border-radius: 0.375rem;
  background: #1a1a1a;
}

.experiments-video-caption {
  margin: 0 0 0.5rem 0;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #ffffff;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.experiments-video-caption .experiments-video-link {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: none;
  color: rgba(255, 255, 255, 0.85);
  text-decoration: underline;
}

.experiments-video-caption .experiments-video-link:hover {
  color: #ffffff;
}

body.light-mode .experiments-video-caption {
  color: #1a1a1a;
}

body.light-mode .experiments-video-caption .experiments-video-link {
  color: rgba(0, 0, 0, 0.75);
}

body.light-mode .experiments-video-caption .experiments-video-link:hover {
  color: #1a1a1a;
}

/* Back to top button */
.back-to-top {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  z-index: 1000;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 999rem;
  border: 0.0625rem solid rgba(255, 255, 255, 0.18);
  background: rgba(30, 30, 30, 0.92);
  backdrop-filter: blur(2rem) saturate(180%);
  -webkit-backdrop-filter: blur(2rem) saturate(180%);
  box-shadow: 0 0.5rem 2rem rgba(0, 0, 0, 0.3), inset 0 0.0625rem 0 rgba(255, 255, 255, 0.1);
  color: #ffffff;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  line-height: 1;
  opacity: 0;
  pointer-events: none;
  transform: translateY(0.25rem);
  transition: opacity 0.2s ease, transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.back-to-top.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.back-to-top:hover {
  background: rgba(30, 30, 30, 0.98);
  border-color: rgba(255, 255, 255, 0.24);
}

.back-to-top:focus-visible {
  outline: 0.125rem solid rgba(255, 255, 255, 0.9);
  outline-offset: 0.1875rem;
}

body.light-mode .back-to-top {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(2rem) saturate(180%);
  -webkit-backdrop-filter: blur(2rem) saturate(180%);
  border-color: rgba(0, 0, 0, 0.18);
  box-shadow: 0 0.5rem 2rem rgba(0, 0, 0, 0.1), inset 0 0.0625rem 0 rgba(255, 255, 255, 0.5);
  color: #1a1a1a;
}

body.light-mode .back-to-top:hover {
  background: rgba(255, 255, 255, 0.98);
  border-color: rgba(0, 0, 0, 0.24);
}

body.light-mode .back-to-top:focus-visible {
  outline-color: rgba(0, 0, 0, 0.85);
}

@media (max-width: 1280px) {
  .page-title {
    font-size: 1.25rem;
  }

  .page-intro {
    font-size: 0.875rem;
  }

  .experiments-prompt {
    font-size: 0.9375rem;
  }

  .back-to-top {
    bottom: 6.5rem;
  }
}
