:root {
  --primary-accent: var(--tsi-blue-bright);
  --secondary-accent: var(--tsi-yellow);
  --ocean-dark: var(--tsi-blue-deep);
  --ocean-medium: var(--tsi-blue-mid);
  --ocean-light: var(--tsi-blue-bright);
  --text-light: var(--tsi-text-on-dark);
  --text-dark: #333333;
  --gradient-blue: linear-gradient(135deg, var(--ocean-dark), var(--ocean-light));
  --ease-out-soft: cubic-bezier(0.22, 1, 0.36, 1);
  --transition-motion: 0.45s var(--ease-out-soft);
  --transition-standard: opacity var(--transition-motion), transform var(--transition-motion), filter var(--transition-motion), box-shadow var(--transition-motion), color var(--transition-motion), background-color var(--transition-motion), fill var(--transition-motion), border-color var(--transition-motion);
  --backdrop-blur: blur(8px);
  --r-1: 2rem;
  --c-1-code: 44, 71, 125;
  --c-1: rgb(var(--c-1-code));
  --c-1-1: rgba(var(--c-1-code), 0.10);
  --c-1-2: rgba(var(--c-1-code), 0.20);
  --c-1-3: rgba(var(--c-1-code), 0.30);
  --c-1-4: rgba(var(--c-1-code), 0.40);
  --grid-space: 0.5rem;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--ocean-medium) !important;
  margin: 0;
  padding: 0;
}

#welcome-video-dialog {
  background-color: #ffffff;
  border-radius: var(--r-1);
  opacity: 0;
  transform: scale(0.9);
  transition: all 0s;
  display: block !important;
  pointer-events: none;
  padding: 3vh;
  z-index: 10000;
}

/* display:block keeps the closed dialog laid out for the open animation, which
   left its close button and iframe in the Tab order. visibility removes them
   from focus and the accessibility tree; it flips instantly in both directions
   (closing is already 0s), so the open fade/scale still plays. */
#welcome-video-dialog:not([open]) {
  visibility: hidden;
}

#welcome-video-dialog::backdrop {
  background-color: rgba(0, 0, 0, 0.7);
  backdrop-filter: var(--backdrop-blur);
}

#welcome-video-dialog[open] {
  opacity: 1 !important;
  transform: scale(1);
  pointer-events: auto;
  display: block !important;
  transition: opacity 0.35s var(--ease-out-soft), transform 0.35s var(--ease-out-soft);
}

#welcome-video-dialog form {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}

#welcome-video-dialog iframe {
  border-radius: var(--tsi-radius-img-md);
  width: 75vw;
  height: calc((315 / 560) * 75vw);
  max-height: 69vh;
}

#welcome-video-dialog .close-button {
  display: flex;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  margin-bottom: 1rem;
}

#welcome-video-dialog .close-button svg {
  width: 2rem;
  height: 2rem;
  fill: var(--text-light);
  transition: var(--transition-standard);
}

#welcome-video-dialog .close-button:hover svg {
  fill: var(--secondary-accent);
  transform: rotate(90deg);
}

#welcome-video-button {
  --c-white: rgba(255, 255, 255, 1);
  position: relative;
  z-index: 10;
  padding: 0;
  background: transparent;
  border: none;
  cursor: pointer;
  transition: var(--transition-standard);
}

#welcome-video-button svg {
  height: 10rem;
  max-width: 80vw;
  filter: drop-shadow(0 4px 6px rgba(0,0,0,0.3));
}

#welcome-video-button:hover {
  transform: scale(1.05);
}

#welcome-video-button:hover svg g {
  transition: all 0.2s;
  opacity: 1;
}

#welcome-video-button:hover svg circle {
  transition: all 0.2s;
  fill: var(--secondary-accent);
}

#welcome-video-button:hover svg path {
  transition: all 0.2s;
}

#welcome-video-button:focus {
  outline: none;
}

#welcome-video-button:focus-visible {
  outline: 2px solid var(--tsi-yellow, #ffd700);
  outline-offset: 4px;
}

.homepage__content {
  --horizon: 32rem;
  --surface: 30vh;
  min-height: 100vh;
  position: relative;
}

.fixed-background-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  z-index: -1;
  overflow: hidden;
}

.video-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 0;
}

.lazy-video {
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.85s var(--ease-out-soft), visibility 0.85s var(--ease-out-soft);
}

.lazy-video.video-loading {
  opacity: 0;
  visibility: hidden;
}

.lazy-video.video-loaded {
  opacity: 1;
  visibility: visible;
}

.lazy-video.video-error {
  opacity: 0;
  visibility: hidden;
}

.video-background video {
  position: absolute;
  top: 50%;
  left: 50%;
  min-width: 100%;
  min-height: 100%;
  width: auto;
  height: auto;
  transform: translateX(-50%) translateY(-50%);
  object-fit: cover;
  z-index: -1;
}

.video-background .hero-poster {
  position: absolute;
  top: 50%;
  left: 50%;
  min-width: 100%;
  min-height: 100%;
  width: auto;
  height: auto;
  transform: translateX(-50%) translateY(-50%);
  object-fit: cover;
  z-index: -2;
  pointer-events: none;
}

.video-background.video-background--end {
  position: absolute;
  width: 100%;
  height: 100%;
}

.video-background.video-background--end video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/*
 * Hero → fixed video junction: overlap crossfade.
 * Soft-fade-to-solid-blue failed because the footer video is a different
 * hue (turquoise); opaque mid-blue at the hero edge just became a hard seam.
 * Instead the hero video bleeds below the section and dissolves to transparent
 * so the fixed underwater video shows through over a long blend.
 */
.homepage__content .section#section-0 {
  overflow: visible;
  z-index: 1;
}

.homepage__content .section#section-1 {
  position: relative;
  z-index: 2;
}

.video-background.video-background--start {
  top: 0;
  bottom: auto;
  height: calc(100% + 38vh);
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
  contain: layout paint;
  background-color: var(--tsi-blue-deep, #063636);
  background-image: var(--hero-poster);
  background-size: cover;
  background-position: center;
  -webkit-mask-image: linear-gradient(
    to bottom,
    #000 0%,
    #000 42%,
    rgba(0, 0, 0, 0.85) 58%,
    rgba(0, 0, 0, 0.45) 72%,
    rgba(0, 0, 0, 0.15) 86%,
    transparent 100%
  );
  mask-image: linear-gradient(
    to bottom,
    #000 0%,
    #000 42%,
    rgba(0, 0, 0, 0.85) 58%,
    rgba(0, 0, 0, 0.45) 72%,
    rgba(0, 0, 0, 0.15) 86%,
    transparent 100%
  );
}

.video-background.video-background--start video {
  /* Mask lives on the container so the whole stack (video + tint) dissolves together */
  -webkit-mask-image: none;
  mask-image: none;
}

.video-background.video-background--start::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    to bottom,
    color-mix(in srgb, var(--tsi-blue-deep) 30%, transparent) 0%,
    color-mix(in srgb, var(--tsi-blue-mid) 18%, transparent) 40%,
    transparent 78%
  );
  z-index: 0;
  pointer-events: none;
}

.fixed-background-container::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(
    to bottom,
    color-mix(in srgb, var(--tsi-blue-deep) 45%, transparent) 0%,
    color-mix(in srgb, var(--tsi-blue-mid) 20%, transparent) 28%,
    transparent 55%
  );
}

.video-background .overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.homepage__content .homepage__button {
  transition: var(--transition-standard);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  gap: 1rem;
  text-decoration: none;
  position: relative;
  overflow: visible;
  border-radius: var(--r-1);
  padding: 1.5rem;
}

.homepage__content .homepage__button:hover {
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.22);
}

.homepage__content .homepage__button picture {
  display: block;
  max-width: 100%;
}

.homepage__content .homepage__button img {
  max-width: 100%;
  width: auto;
  height: auto;
  max-height: 50vh;
  object-fit: contain;
  transition: transform var(--transition-motion), filter var(--transition-motion);
  filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.2));
  position: relative;
  z-index: 1;
  transform-origin: center center;
}

.homepage__content .homepage__button:hover img {
  transform: scale(1.04);
  filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.28));
}

.homepage__content .homepage__button p {
  align-self: center;
  margin: 0;
  transition: transform var(--transition-motion), text-shadow var(--transition-motion);
  text-align: center;
  font-weight: 500;
  position: relative;
  z-index: 1;
}

.homepage__content .homepage__button:hover p {
  transform: translateY(-4px);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
}

.homepage__content .homepage__row {
  position: relative;
  height: 100vh;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  box-sizing: border-box;
}

.homepage__content .homepage__row.row--hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0;
  position: relative;
  overflow: visible;
  z-index: 1;
  min-height: 100vh;
  min-height: 100dvh;
}

.homepage__content .homepage__row.row--hero h1 {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-top: 0;
  z-index: 5;
  text-align: center;
  position: relative;
  font-size: 1.1vw;
  /* Reserve headline box so fade-in does not shift layout. */
  min-height: 3.3em;
}

.homepage__content .homepage__row.row--hero h1 span {
  font-family: "Tusker Grotesk 3600";
  font-style: normal;
  font-weight: 600;
  font-size: 15em;
  line-height: 1.1em;
  text-transform: uppercase;
  color: var(--text-light);
  opacity: 0;
  animation: fadeIn 1.15s var(--ease-out-soft) forwards;
  text-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes fadeInSoft {
  from { opacity: 0; }
  to { opacity: 0.8; }
}

.homepage__content .homepage__row.row--hero h1 span.hero__header__row-1 {
  font-family: "Tusker Grotesk 5500";
  font-weight: 500;
  font-size: 2.9em;
  animation-name: fadeInSoft;
  animation-delay: 0.28s;
}

.homepage__content .homepage__row.row--hero h1 span.hero__header__row-2 {
  font-size: 6.6em;
  color: var(--secondary-accent);
  /* Yellow into a slightly deeper gold for weight on bright video frames. */
  background: linear-gradient(180deg, var(--secondary-accent) 30%, #e0a800 85%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  /* text-shadow would paint through the transparent fill; drop-shadow
     shadows the clipped glyphs instead. */
  text-shadow: none;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
  animation-delay: 0.55s;
}

.homepage__content .row--video {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.homepage__content .row--video .homepage__col {
  align-items: center;
}

.homepage__content .row--video h2 {
  font-family: "Tusker Grotesk 5500";
  margin: 2rem 0 0 0;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 1rem;
  font-size: 4rem;
}

@media screen and (max-width: 1100px) {
  .homepage__content .row--video h2 {
    letter-spacing: 0.12em;
    padding-inline: 1rem;
    box-sizing: border-box;
    max-width: 100%;
  }
}

.homepage__content .row--video #welcome-video-button {
  margin-bottom: 1.5rem;
}

.homepage__content .row--video .col__text p {
  text-align: center;
  max-width: 80ch;
}

.homepage__content h2 {
  font-size: 2rem;
  font-weight: 600;
  line-height: 1.3;
  color: var(--text-light);
  margin-bottom: 1.5rem;
  text-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.homepage__content .row__content {
  display: flex;
  width: 100%;
  max-width: 1200px;
  gap: 2rem;
  z-index: 3;
  position: relative;
  justify-content: center;
}

.homepage__content .homepage__col {
  padding: 2rem;
  border-radius: var(--r-1);
  transition: var(--transition-standard);
  position: relative;
  z-index: 4;
  display: flex;
  align-items: flex-start;
  flex-direction: column;
  justify-content: center;
  flex: 1;
  gap: 2rem !important;
}

.homepage__content .col--half {
  flex: 0 0 calc(50% - 2rem);
  max-width: calc(50% - 2rem);
  width: calc(50% - 2rem);
}

.homepage__content .col--third {
  flex: 0 0 calc(33.33% - 2rem);
  max-width: calc(33.33% - 2rem);
  width: calc(33.33% - 2rem);
  align-items: center;
}

.homepage__content .col--full {
  flex: 0 0 100%;
  max-width: 100%;
  width: 100%;
}

.homepage__content .col__text {
  color: var(--text-light);
  font-family: var(--tsi-font-ui);
}

.homepage__content .col__text p,
.homepage__content .col__text h2,
.homepage__content .col__text h3 {
  font-family: var(--tsi-font-ui);
}

.homepage__content .col__text p {
  max-width: 60ch !important;
  font-size: 1.1rem;
  line-height: 1.6;
  margin-bottom: 0;
}

.homepage__content .col__text h3 {
  font-size: 1.8rem;
  margin-bottom: 1rem;
  color: var(--secondary-accent);
}

.homepage__content .row--video .col__text p {
  font-family: var(--tsi-font-ui);
}

.homepage__content .col__image img {
  border-radius: var(--r-1);
  max-width: 100%;
  height: auto;
}

.homepage__content .col__image .homepage__button img {
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.homepage__content .row--from-right,
.homepage__content .row--from-left {
  position: relative;
  overflow: visible;
}

.homepage__content .row--from-right::before,
.homepage__content .row--from-left::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 0;
}

.homepage__content .row--post .col--post {
  width: 100%;
}

.homepage__content .col--post a {
  display: flex;
  gap: 2rem;
  align-items: center;
  padding: 2rem;
  border-radius: var(--r-1);
  backdrop-filter: var(--backdrop-blur);
  transition: var(--transition-standard);
  text-decoration: none;
  color: var(--text-light);
  width: 100%;
  justify-content: space-between;
  position: relative;
  overflow: visible;
}

.homepage__content .col--post a .col__text {
  flex: 1;
  max-width: 50%;
  text-align: right !important;
  position: relative;
  z-index: 1;
}

.homepage__content .col--post a .col__image {
  flex: 1;
  max-width: 50%;
  position: relative;
  z-index: 1;
}

.homepage__content .col--post a .col__image img {
  width: 100%;
  height: auto;
  object-fit: cover;
  border-radius: var(--r-1);
  transition: transform var(--transition-motion), filter var(--transition-motion);
  transform-origin: center center;
}

.homepage__content .col--post a h2 {
  margin: 0;
  transition: var(--transition-standard);
}

.homepage__content .col--post a h2 time,
.homepage__content .col--post a h2 date {
  font-family: var(--tsi-font-ui);
  font-weight: 500;
  font-size: 1.2rem;
  color: var(--tsi-text-on-dark);
  display: block;
  margin-bottom: 0.5rem;
  transition: var(--transition-standard);
}

.homepage__content .col--post a h2 span {
  font-family: var(--tsi-font-reading);
  font-weight: 700;
  font-size: 1.8rem;
  line-height: 1.2;
  color: var(--text-light);
  display: block;
  transition: var(--transition-standard);
}

.homepage__content .col--post a:hover {
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.22);
}

.homepage__content .col--post a:hover .col__image img {
  transform: scale(1.04);
  filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.28));
}

.homepage__content .col--post a:hover h2 span {
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
}

.homepage__content .col--post a:hover h2 time,
.homepage__content .col--post a:hover h2 date {
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
}

.homepage__content .row--boxes .homepage__col {
  padding: 2rem;
  text-align: center;
}

.homepage__content .row--members {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.homepage__content .row--members .row__content {
  width: 100%;
  justify-content: space-between;
}

.homepage__content .row--members .homepage__col {
  align-items: flex-start;
  justify-content: flex-start;
}

.homepage__content .row--members .homepage__col a {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  transition: var(--transition-standard);
  position: relative;
  overflow: visible;
  border-radius: var(--r-1);
  padding: 1.5rem;
  color: var(--text-light);
  justify-content: center;
}

.homepage__content .row--members .homepage__col a .col__text {
  transition: transform var(--transition-motion), text-shadow var(--transition-motion);
  position: relative;
  z-index: 1;
}

.homepage__content .row--members .homepage__col a img {
  position: relative;
  z-index: 1;
  transition: transform var(--transition-motion), filter var(--transition-motion);
  transform-origin: center center;
}

.homepage__content .row--members .homepage__col a:hover {
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.22);
}

.homepage__content .row--members .homepage__col a:hover .col__text {
  transform: translateY(-4px);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
}

.homepage__content .row--members .homepage__col a:hover img {
  transform: scale(1.04);
  filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.28));
}

.homepage__content .row--members .members {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 2rem;
  width: 100%;
  padding: 0;
  list-style: none;
}

.homepage__content .row--members .members img {
  width: 160px;
  height: 160px;
  object-fit: cover;
  object-position: center center;
  border-radius: 2rem;
  background: white;
  transition: var(--transition-standard);
}

.footer-container {
  height: 50px;
  width: 100%;
  position: relative;
  z-index: 1;
  background: var(--ocean-medium);
}

footer.site-footer {
  /* Homepage needs the footer above the fixed video layer; colors come from footer.css */
  margin-top: 0;
  position: relative;
  z-index: 1;
  display: block;
  transition: opacity 0.8s ease-in-out;
}

@media screen and (max-width: 768px) {
  .homepage__content,
  .homepage-slider-container,
  .homepage__content .homepage__row,
  .section {
    width: 100% !important;
    max-width: 100% !important;
  }

  html {
    scroll-snap-type: none !important;
  }

  .section {
    scroll-snap-align: none;
  }

  .homepage__content .homepage__row.row--hero h1 span {
    font-size: clamp(3rem, 12vw, 5rem);
    word-break: break-word;
  }

  .homepage__content .homepage__row.row--hero h1 span.hero__header__row-1,
  .homepage__content .homepage__row.row--hero h1 span.hero__header__row-2 {
    font-size: clamp(1.5rem, 4.5vw, 2.25rem);
  }

  .homepage__content .row__content {
    flex-direction: column;
    gap: 2rem;
  }

  .homepage__content .col--half,
  .homepage__content .col--third {
    flex: 0 0 100%;
    max-width: 100%;
    width: 100%;
  }

  .homepage__content .col--post a {
    flex-direction: column;
    align-items: flex-start;
  }

  .homepage__content .col--post a .col__text,
  .homepage__content .col--post a .col__image {
    flex: 0 0 100%;
    max-width: 100%;
  }

  .homepage__content .col--post a .col__image {
    margin-top: 1rem;
  }

  .homepage__content .row--members .homepage__col {
    margin-bottom: 2rem;
  }

  .homepage__content .homepage__row {
    height: auto;
    min-height: auto;
    overflow: visible;
    padding-top: 4rem;
    padding-bottom: 4rem;
  }

  .homepage__content .homepage__row.row--hero {
    min-height: 100vh;
  }

  .homepage__content .homepage__row.row--two-columns {
    padding-top: 5rem;
    padding-bottom: 5rem;
    min-height: auto;
  }

  .section {
    overflow: visible !important;
    height: auto !important;
    min-height: auto;
  }

  .section#section-0 {
    min-height: 100vh;
  }

  .section.row--two-columns {
    min-height: auto !important;
    height: auto !important;
    padding-bottom: 3rem;
  }

  .section .row__content {
    margin-top: 2rem;
    margin-bottom: 2rem;
  }

  footer.site-footer {
    width: 100% !important;
    max-width: 100% !important;
  }
}

@media screen and (max-width: 550px) {
  .homepage__content .homepage__row.row--hero h1 {
    font-size: 3rem;
    gap: 1rem;
    padding: 1.5rem;
    max-width: calc(100% - 1rem);
    box-sizing: border-box;
  }
  .homepage__content .homepage__row.row--hero h1 span {
    font-size: clamp(3rem, 15vw, 6rem);
    align-self: flex-start;
    word-break: break-word;
  }

  .homepage__content .homepage__row.row--hero h1 span.hero__header__row-1 {
    font-size: clamp(1.5rem, 5vw, 2rem);
    text-align: right;
    align-self: flex-end;
  }

  .homepage__content .homepage__row.row--hero h1 span.hero__header__row-2 {
    font-family: "Tusker Grotesk 5500";
    font-size: clamp(1.5rem, 5vw, 2rem);
    text-align: right;
    align-self: flex-end;
  }

  .homepage__content .row__content {
    gap: 1rem;
  }

  .homepage__content .homepage__col {
    padding: 1.5rem;
    margin-bottom: 1rem;
  }

  .homepage__content .col--half {
    width: 100% !important;
    margin-bottom: 2rem;
  }

  .homepage__content .col--third {
    width: 100% !important;
    margin-bottom: 2rem;
  }

  .homepage__content .row--members .members {
    margin: 0;
  }

  .homepage__content .col--post a h2 time,
  .homepage__content .col--post a h2 date {
    font-size: 1rem;
  }

  .homepage__content .col--post a h2 span {
    font-size: 1.2rem;
  }

  #welcome-video-button svg {
    height: 7rem;
  }

  .homepage__content .row--video h2 {
    font-size: clamp(1.2rem, 6vw, 4rem);
    letter-spacing: 0.15rem;
    padding: 0 0.5rem;
    box-sizing: border-box;
    max-width: 100%;
    word-break: break-word;
  }

  .homepage__content .homepage__row {
    padding-top: 3rem;
    padding-bottom: 3rem;
  }

  .homepage__content .row--two-columns {
    padding-top: 4rem;
    padding-bottom: 5rem;
    margin-bottom: 2rem;
  }

  footer.site-footer {
    opacity: 1 !important;
    visibility: visible !important;
  }
}

.section {
  opacity: 1;
  visibility: visible !important;
}

.section .row__content,
.section .homepage__col,
.section .col__text,
.section .col__image {
  opacity: 1;
  visibility: visible !important;
}

.play-button-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.thumbnail-container img {
  border-radius: var(--r-1);
  width: min(15vw * (560 / 315), 560px);
  height: min(15vw, 315px);
  /* hqdefault.jpg is 4:3 with baked-in letterbox bars; crop them in the 16:9 box. */
  object-fit: cover;
}

@media screen and (max-width: 768px) {
  .thumbnail-container img {
    width: 80vw;
    max-width: 560px;
    height: auto;
    aspect-ratio: 560 / 315;
  }
}

.homepage__content .row--members .homepage__col a {
  gap: 2rem;
}

/* ==========================================================================
   Homepage intro (logo → video → chrome)
   ========================================================================== */

.homepage-intro {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--tsi-blue-mid);
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.7s var(--ease-out-soft),
    visibility 0.7s var(--ease-out-soft),
    background-color 0.7s var(--ease-out-soft);
}

.homepage-intro__brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
  text-align: center;
  opacity: 0;
  transform: translateY(12px) scale(0.96);
  transition:
    opacity 0.7s var(--ease-out-soft),
    transform 0.7s var(--ease-out-soft);
}

.homepage-intro__mark {
  width: clamp(72px, 12vw, 120px);
  height: auto;
  display: block;
  filter: drop-shadow(0 6px 16px rgba(0, 0, 0, 0.25));
}

.homepage-intro__wordmark {
  font-family: "Tusker Grotesk 5500", sans-serif;
  font-weight: 500;
  font-size: clamp(1.1rem, 2.4vw, 1.75rem);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--tsi-text-on-dark);
  margin: 0;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
}

html.homepage-intro-active .homepage-intro {
  opacity: 1;
  visibility: visible;
}

html.homepage-intro-active.homepage-intro--logo .homepage-intro__brand {
  opacity: 1;
  transform: translateY(0) scale(1);
}

html.homepage-intro-active.homepage-intro--video .homepage-intro,
html.homepage-intro-active.homepage-intro--chrome .homepage-intro {
  background-color: transparent;
}

html.homepage-intro-active.homepage-intro--video .homepage-intro__brand {
  opacity: 0;
  transform: translateY(-10px) scale(0.92);
}

html.homepage-intro-active.homepage-intro--chrome .homepage-intro,
html.homepage-intro-ready .homepage-intro {
  opacity: 0;
  visibility: hidden;
}

html.homepage-intro-active .header,
html.homepage-intro-active .sidebar {
  transition:
    opacity 0.65s var(--ease-out-soft),
    visibility 0.65s var(--ease-out-soft);
}

html.homepage-intro-active.homepage-intro--logo .header,
html.homepage-intro-active.homepage-intro--logo .sidebar,
html.homepage-intro-active.homepage-intro--video .header,
html.homepage-intro-active.homepage-intro--video .sidebar {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

html.homepage-intro-active.homepage-intro--chrome .header,
html.homepage-intro-active.homepage-intro--chrome .sidebar {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

html.homepage-intro-active.homepage-intro--logo .video-background--start .lazy-video {
  opacity: 0 !important;
}

html.homepage-intro-active .homepage__content .homepage__row.row--hero h1 span {
  animation: none !important;
  opacity: 0;
  transform: none;
}

html.homepage-intro-ready .homepage__content .homepage__row.row--hero h1 span {
  animation: fadeIn 1.15s var(--ease-out-soft) forwards;
}

html.homepage-intro-ready .homepage__content .homepage__row.row--hero h1 span.hero__header__row-1 {
  animation-name: fadeInSoft;
  animation-delay: 0.28s;
}

html.homepage-intro-ready .homepage__content .homepage__row.row--hero h1 span.hero__header__row-2 {
  animation-delay: 0.55s;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .lazy-video,
  .homepage__content .homepage__button,
  .homepage__content .homepage__button img,
  .homepage__content .homepage__button p,
  .homepage__content .col--post a,
  .homepage__content .col--post a .col__image img,
  .homepage__content .row--members .homepage__col a,
  .homepage__content .row--members .homepage__col a img,
  .homepage__content .row--members .homepage__col a .col__text,
  #welcome-video-dialog,
  #welcome-video-button,
  .homepage-intro,
  .homepage-intro__brand,
  .header,
  .sidebar {
    transition: none !important;
  }

  .homepage__content .homepage__row.row--hero h1 span,
  html.homepage-intro-ready .homepage__content .homepage__row.row--hero h1 span {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }

  .homepage__content .homepage__row.row--hero h1 span.hero__header__row-1 {
    opacity: 0.8 !important;
  }

  .homepage__content .homepage__button:hover,
  .homepage__content .homepage__button:hover img,
  .homepage__content .homepage__button:hover p,
  .homepage__content .col--post a:hover,
  .homepage__content .col--post a:hover .col__image img,
  .homepage__content .row--members .homepage__col a:hover,
  .homepage__content .row--members .homepage__col a:hover img,
  .homepage__content .row--members .homepage__col a:hover .col__text,
  #welcome-video-button:hover {
    transform: none !important;
  }

  .homepage-intro {
    display: none !important;
  }
}

/* --------------------------------------------------------------------------
   Hero scroll cue — mono label over a hairline with a slow yellow pulse.
   Fades in after the headline, then fades out with the scroll.
   -------------------------------------------------------------------------- */

.homepage__content .row--hero .hero__scroll {
  position: absolute;
  left: 50%;
  bottom: calc(1.75rem + env(safe-area-inset-bottom, 0px));
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  padding: 0.5rem 0.75rem;
  color: var(--tsi-text-on-dark, #fff);
  text-decoration: none;
  transform: translateX(-50%);
  opacity: 0;
  animation: heroScrollIn 0.9s var(--ease-out-soft, ease-out) 1.6s forwards;
  transition: color 0.2s ease;
}

.homepage__content .row--hero .hero__scroll__label {
  font-family: var(--tsi-font-ui, 'Source Code Pro', monospace);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.32em;
  /* letter-spacing trails the last glyph; pull it back so the word centers */
  margin-right: -0.32em;
  text-transform: uppercase;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.45);
}

.homepage__content .row--hero .hero__scroll__line {
  position: relative;
  display: block;
  width: 1px;
  height: 3rem;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.35);
}

.homepage__content .row--hero .hero__scroll__line::after {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 40%;
  background: var(--tsi-yellow, #ffd700);
  transform: translateY(-100%);
  animation: heroScrollPulse 2.4s cubic-bezier(0.65, 0, 0.35, 1) 2.5s infinite;
}

.homepage__content .row--hero .hero__scroll:hover,
.homepage__content .row--hero .hero__scroll:focus-visible {
  color: var(--tsi-yellow, #ffd700);
}

.homepage__content .row--hero .hero__scroll:focus-visible {
  outline: 2px solid var(--tsi-yellow, #ffd700);
  outline-offset: 4px;
}

/* Scroll-linked fade (--cue-fade, set by homepage-slider.js). Applied to the
   children so it multiplies with the entrance animation on the link itself. */
.homepage__content .row--hero .hero__scroll > * {
  opacity: var(--cue-fade, 1);
}

.homepage__content .row--hero .hero__scroll.is-retired {
  visibility: hidden;
  pointer-events: none;
}

html.homepage-intro-active .homepage__content .row--hero .hero__scroll {
  animation: none;
  opacity: 0;
}

@keyframes heroScrollIn {
  from { opacity: 0; transform: translate(-50%, 0.5rem); }
  to { opacity: 1; transform: translate(-50%, 0); }
}

@keyframes heroScrollPulse {
  0% { transform: translateY(-100%); }
  60%, 100% { transform: translateY(250%); }
}

@media (max-width: 768px) {
  .homepage__content .row--hero .hero__scroll {
    bottom: calc(1.25rem + env(safe-area-inset-bottom, 0px));
  }

  .homepage__content .row--hero .hero__scroll__line {
    height: 2.25rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .homepage__content .row--hero .hero__scroll {
    animation: none;
    opacity: 1;
  }

  .homepage__content .row--hero .hero__scroll__line::after {
    animation: none;
    transform: none;
  }
}
