* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Visually hidden but accessible to screen readers and search engine crawlers.
   Used by the SEO content block at the bottom of <body>. */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

html, body {
  height: 100%;
  background: #000;
  color: #fff;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  position: relative;
}

/* ============ TOP BAR ============ */
.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 28px 48px;
  z-index: 100;
}

.logo-link {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.logo-link:hover {
  opacity: 0.85;
}

.logo {
  height: 42px;
  width: auto;
  display: block;
  /* Invert the dark "HOTA MEDIA" text to white while preserving rainbow icon hues */
  filter: invert(1) hue-rotate(180deg);
}

.nav {
  display: flex;
  align-items: center;
  gap: 32px;
}

.btn-join {
  position: relative;
  display: inline-block;
  padding: 13px 32px;
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2px;
  color: #fff;
  text-decoration: none;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 2px;
  transition: border-color 0.3s ease, color 0.3s ease;
  overflow: hidden;
}

.btn-join::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 2px;
  padding: 1px;
  background: linear-gradient(
    90deg,
    #ff2d8a, #ff7b00, #ffd000, #00d96e,
    #00b8ff, #8a2be2, #ff2d8a
  );
  background-size: 300% 100%;
  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.btn-join:hover {
  border-color: transparent;
}

.btn-join:hover::before {
  opacity: 1;
  animation: rainbow-shift 4s linear infinite;
}

@keyframes rainbow-shift {
  0%   { background-position: 0% 50%; }
  100% { background-position: 300% 50%; }
}

.btn-login {
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 2px;
  color: rgba(255, 255, 255, 0.65);
  text-decoration: none;
  transition: color 0.2s ease;
}

.btn-login:hover {
  color: #fff;
}

/* ============ HERO / CAROUSEL ============ */
.hero {
  position: relative;
  height: 100vh;
  width: 100%;
  overflow: hidden;
}

.carousel {
  position: absolute;
  inset: 0;
}

.slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.slide.active {
  opacity: 1;
}

.slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Vignettes for text legibility */
.vignette {
  position: absolute;
  left: 0;
  right: 0;
  pointer-events: none;
  z-index: 5;
}

.vignette-top {
  top: 0;
  height: 35%;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.65) 0%,
    rgba(0, 0, 0, 0.2) 60%,
    transparent 100%
  );
}

.vignette-bottom {
  bottom: 0;
  height: 40%;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.85) 0%,
    rgba(0, 0, 0, 0.3) 60%,
    transparent 100%
  );
}

/* Subtle backdrop behind the slogan, so it reads on bright images */
.slogan-backdrop {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80%;
  max-width: 1100px;
  height: 320px;
  background: radial-gradient(
    ellipse at center,
    rgba(0, 0, 0, 0.45) 0%,
    rgba(0, 0, 0, 0.15) 50%,
    transparent 75%
  );
  pointer-events: none;
  z-index: 7;
}

/* ============ HEADLINE (per-slide copy) ============ */
.headline {
  position: absolute;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-weight: 700;
  font-style: normal;
  font-size: clamp(1.6rem, 3.6vw, 3.4rem);
  letter-spacing: -0.012em;
  line-height: 1.1;
  color: #fff;
  text-shadow:
    0 2px 24px rgba(0, 0, 0, 0.6),
    0 0 60px rgba(0, 0, 0, 0.35);
  z-index: 10;
  max-width: min(85%, 1100px);
  pointer-events: none;
  opacity: 1;
  transition: opacity 0.45s ease;
}

.headline.fading {
  opacity: 0;
}

/* The slogan moment — slide 6 (the payoff) — single line, A24-style hierarchy via size, not weight */
.headline.is-final {
  font-weight: 700;
  font-size: clamp(1.4rem, 4.8vw, 4.8rem);
  letter-spacing: -0.02em;
  line-height: 1;
  white-space: nowrap;
  max-width: 95%;
}

/* ============ HEADLINE POSITIONS ============ */
.headline.pos-center {
  top: 50%; left: 50%; right: auto; bottom: auto;
  transform: translate(-50%, -50%);
  text-align: center;
}

.headline.pos-bottom-left {
  top: auto; right: auto; left: 7vw; bottom: 22vh;
  transform: none;
  text-align: left;
}

.headline.pos-center-left {
  top: 50%; right: auto; left: 7vw; bottom: auto;
  transform: translateY(-50%);
  text-align: left;
}

.headline.pos-top-center {
  top: 24vh; left: 50%; right: auto; bottom: auto;
  transform: translateX(-50%);
  text-align: center;
}

.headline.pos-bottom-center {
  top: auto; left: 50%; right: auto; bottom: 22vh;
  transform: translateX(-50%);
  text-align: center;
}

/* Lower-center — used by slide 6 slogan, sits at subject's waist level, above the dots */
.headline.pos-lower-center {
  top: auto; left: 50%; right: auto; bottom: 18vh;
  transform: translateX(-50%);
  text-align: center;
}

.headline.pos-top-right {
  top: 22vh; right: 7vw; left: auto; bottom: auto;
  transform: none;
  text-align: right;
}

/* ============ ARROWS ============ */
.arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.55);
  cursor: pointer;
  padding: 24px;
  z-index: 20;
  transition: color 0.2s ease, transform 0.2s ease;
}

.arrow svg {
  width: 36px;
  height: 36px;
  display: block;
}

.arrow:hover {
  color: #fff;
}

.arrow:active {
  transform: translateY(-50%) scale(0.92);
}

.arrow-left  { left: 28px; }
.arrow-right { right: 28px; }

/* ============ HERO BOTTOM (dots + caption) ============ */
.hero-bottom {
  position: absolute;
  bottom: 44px;
  left: 0;
  right: 0;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 0 48px;
  z-index: 15;
  gap: 24px;
}

.dots {
  display: flex;
  gap: 12px;
  justify-self: center;
  grid-column: 2;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.28);
  border: none;
  cursor: pointer;
  padding: 0;
  transition: background 0.25s ease, transform 0.2s ease;
}

.dot:hover {
  background: rgba(255, 255, 255, 0.6);
}

.dot.active {
  background: #fff;
  transform: scale(1.15);
}

.counter {
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 3px;
  color: rgba(255, 255, 255, 0.6);
  text-align: right;
  justify-self: end;
  grid-column: 3;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: color 0.3s ease;
}

#counter-current {
  color: #fff;
  min-width: 22px;
  display: inline-block;
  text-align: right;
}

.counter-divider {
  opacity: 0.5;
}

.counter-total {
  opacity: 0.6;
}

/* ============================================================
   JOIN US PAGE (join.html) — Region selection
   ============================================================ */

.join-body {
  overflow: auto;
}

.join-main {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 110px 48px 80px;
  gap: 56px;
}

.join-intro {
  text-align: center;
  max-width: 800px;
}

.join-title {
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: clamp(2rem, 5vw, 4.5rem);
  letter-spacing: -0.02em;
  line-height: 1;
  color: #fff;
  margin: 0;
}

.join-subtitle {
  margin-top: 18px;
  font-family: 'Inter', sans-serif;
  font-size: clamp(0.85rem, 1.2vw, 1rem);
  font-weight: 400;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
}

.region-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(140px, 200px));
  gap: 20px;
  width: 100%;
  max-width: 1200px;
  justify-content: center;
}

.region-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  aspect-ratio: 3 / 4;
  padding: 28px 16px;
  text-decoration: none;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 4px;
  overflow: hidden;
  transition: border-color 0.3s ease, transform 0.3s ease;
  cursor: pointer;
}

.region-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 4px;
  padding: 1px;
  background: linear-gradient(
    135deg,
    #ff2d8a, #ff7b00, #ffd000, #00d96e,
    #00b8ff, #8a2be2, #ff2d8a
  );
  background-size: 300% 300%;
  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.region-card:hover {
  border-color: transparent;
  transform: translateY(-4px);
}

.region-card:hover::before {
  opacity: 1;
  animation: rainbow-shift 4s linear infinite;
}

.region-flag {
  font-size: clamp(2.4rem, 4vw, 3.4rem);
  line-height: 1;
  margin-bottom: 12px;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.4));
}

.region-code {
  font-family: 'Inter', sans-serif;
  font-size: clamp(1.8rem, 2.6vw, 2.4rem);
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #fff;
  line-height: 1;
}

.region-name {
  margin-top: 10px;
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 2.5px;
  color: rgba(255, 255, 255, 0.55);
  text-align: center;
  transition: color 0.3s ease;
}

.region-card:hover .region-name {
  color: rgba(255, 255, 255, 0.9);
}

.join-footer {
  width: 100%;
  max-width: 1200px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 8px;
}

.back-link {
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 3px;
  color: rgba(255, 255, 255, 0.55);
  text-decoration: none;
  transition: color 0.2s ease;
}

.back-link:hover {
  color: #fff;
}

.join-counter {
  position: static;
  text-align: right;
}

.join-counter .counter-total {
  color: #fff;
  opacity: 1;
}

/* ============ MOBILE ============ */
@media (max-width: 768px) {
  .topbar {
    padding: 18px 20px;
  }
  .logo {
    height: 30px;
  }
  .nav {
    gap: 14px;
  }
  .btn-join {
    padding: 10px 18px;
    font-size: 10px;
    letter-spacing: 1.5px;
  }
  .btn-login {
    font-size: 10px;
    letter-spacing: 1.5px;
  }
  .headline {
    font-size: clamp(1.25rem, 6vw, 2.2rem);
    max-width: 86%;
  }
  .headline.is-final {
    font-size: clamp(1.1rem, 6.4vw, 2.4rem);
  }
  /* On mobile, soften extreme positions so text doesn't crash into edges */
  .headline.pos-bottom-left,
  .headline.pos-center-left {
    left: 6vw;
  }
  .headline.pos-top-right {
    right: 6vw;
  }
  .headline.pos-bottom-left,
  .headline.pos-bottom-center {
    bottom: 18vh;
  }
  .headline.pos-lower-center {
    bottom: 14vh;
  }
  .headline.pos-top-center,
  .headline.pos-top-right {
    top: 18vh;
  }
  .slogan-backdrop {
    height: 240px;
  }
  .arrow {
    padding: 14px;
  }
  .arrow svg {
    width: 26px;
    height: 26px;
  }
  .arrow-left  { left: 4px; }
  .arrow-right { right: 4px; }
  .hero-bottom {
    bottom: 28px;
    padding: 0 24px;
    grid-template-columns: 1fr;
    grid-template-rows: auto auto;
    gap: 14px;
  }
  .dots {
    grid-row: 1;
    grid-column: 1;
    justify-self: center;
  }
  .counter {
    grid-row: 2;
    grid-column: 1;
    text-align: center;
    justify-self: center;
    font-size: 10px;
    letter-spacing: 2px;
  }

  /* Join page mobile */
  .join-main {
    padding: 80px 20px 40px;
    gap: 36px;
    justify-content: flex-start;
  }
  .join-subtitle {
    margin-top: 12px;
    letter-spacing: 3px;
  }
  .region-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
  .region-card {
    aspect-ratio: 1 / 1;
    padding: 18px 8px;
  }
  .region-flag {
    font-size: 2rem;
    margin-bottom: 6px;
  }
  .region-code {
    font-size: 1.4rem;
  }
  .region-name {
    margin-top: 6px;
    font-size: 10px;
    letter-spacing: 1.8px;
  }
  .join-footer {
    flex-direction: column;
    gap: 16px;
    padding: 0;
  }
  .join-counter {
    font-size: 10px;
    letter-spacing: 2px;
  }
}
