/* Homepage — hero hub cards, below-fold */

@keyframes hub-pulse {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.45);
  }
  50% {
    box-shadow: 0 0 0 6px rgba(52, 211, 153, 0);
  }
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Hero: fills space under header without stacking min-height + 100dvh */
.hero {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  width: 100%;
  min-height: 0;
}

.hero__inner {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: 100%;
  min-height: calc(100svh - 5.75rem);
  padding-top: clamp(0.5rem, 2.5vw, 1.25rem);
  padding-bottom: clamp(1rem, 4vw, 2rem);
  text-align: center;
  gap: clamp(0.25rem, 2vw, 0.75rem);
}

.hero__head {
  text-align: center;
  padding-bottom: 0;
  max-width: 32rem;
  margin-inline: auto;
}

.hero__head h1 {
  margin: 0 0 0.35rem;
  padding: 0;
  font-size: clamp(1.65rem, 4.5vw, 2.35rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.15;
  color: var(--text);
  text-align: center;
}

.hero__tagline {
  margin: 0 auto;
  max-width: 36ch;
  font-size: 1rem;
  color: var(--text-muted);
  text-align: center;
}

.hero__body {
  flex: 0 1 auto;
  width: 100%;
}

/* Hero hub: two columns at every width (standard hero pairing) */
.hero__cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(0.45rem, 2vw, 1.15rem);
  width: 100%;
  max-width: min(100%, 22rem);
  margin-inline: auto;
  align-items: stretch;
}

@media (min-width: 400px) {
  .hero__cards {
    max-width: min(100%, 26rem);
    gap: clamp(0.55rem, 2.2vw, 1rem);
  }
}

@media (min-width: 480px) {
  .hero__cards {
    max-width: min(100%, 30rem);
    gap: 1rem;
  }
}

@media (min-width: 640px) {
  .hero__cards {
    max-width: min(100%, 34rem);
    gap: 1.25rem;
  }
}

/* Card links: whole card is one anchor — no underline / link colors on children */
a.hub-card,
a.hub-card:visited {
  color: var(--text);
  text-decoration: none;
}

a.hub-card:hover,
a.hub-card:focus-visible {
  color: var(--text);
  text-decoration: none;
}

a.hub-card *,
a.hub-card *::before,
a.hub-card *::after {
  text-decoration: none;
}

a.hub-card .hub-card__title {
  color: var(--text);
}

.hub-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  text-align: center;
  width: 100%;
  min-width: 0;
  min-height: 0;
  aspect-ratio: 1;
  padding: clamp(0.85rem, 3.2vw, 1.4rem) clamp(0.4rem, 1.8vw, 0.65rem) clamp(0.55rem, 2vw, 0.75rem);
  background: linear-gradient(165deg, rgba(255, 255, 255, 0.08) 0%, var(--bg-card) 50%);
  border: 1px solid var(--border-subtle);
  border-radius: clamp(14px, 3.5vw, 18px);
  box-shadow: var(--shadow);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
  overflow: hidden;
  gap: 0.15rem;
}

.hub-card__logo {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 0;
  width: 100%;
  margin: 0;
}

.hub-card__logo-svg {
  display: block;
  width: min(44%, 5rem);
  height: auto;
}

.hub-card__logo-svg--telegram {
  color: #2aabee;
  filter: drop-shadow(0 4px 20px rgba(42, 171, 238, 0.45));
}

.hub-card__logo-svg--discord {
  color: #5865f2;
  filter: drop-shadow(0 4px 20px rgba(88, 101, 242, 0.45));
}

.hub-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  opacity: 0.9;
}

.hub-card--telegram::before {
  background: linear-gradient(90deg, #229ed9, #2aabee, #4dc4ff);
}

.hub-card--discord::before {
  background: linear-gradient(90deg, #4752c4, #5865f2, #7289da);
}

.hub-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.55);
}

.hub-card--telegram:hover {
  border-color: rgba(42, 171, 238, 0.45);
}

.hub-card--discord:hover {
  border-color: rgba(88, 101, 242, 0.45);
}

.hub-card:focus-visible {
  outline: 2px solid var(--accent-tg-hover);
  outline-offset: 3px;
}

.hub-card__status {
  position: absolute;
  top: 0.45rem;
  right: 0.45rem;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.2rem 0.45rem 0.2rem 0.38rem;
  margin: 0;
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #a7f3d0;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(52, 211, 153, 0.4);
  border-radius: 999px;
}

@media (min-width: 400px) {
  .hub-card__status {
    top: 0.55rem;
    right: 0.55rem;
    font-size: 0.62rem;
    padding: 0.22rem 0.5rem 0.22rem 0.42rem;
  }
}

.hub-card__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #34d399;
  animation: hub-pulse 2.2s ease-out infinite;
}

@media (min-width: 400px) {
  .hub-card__dot {
    width: 7px;
    height: 7px;
  }
}

.hub-card__title {
  margin: 0 0 0.15rem;
  padding: 0;
  width: 100%;
  font-size: clamp(0.95rem, 3.8vw, 1.2rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
  line-height: 1.2;
  text-align: center;
}

.hub-card__desc {
  margin: 0 0 0.35rem;
  flex: 0 0 auto;
  width: 100%;
  font-size: clamp(0.65rem, 2.4vw, 0.78rem);
  line-height: 1.3;
  color: var(--text-muted);
  text-align: center;
}

.hub-card__cta {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  margin-top: auto;
  padding: 0.5rem 0.45rem;
  font-size: clamp(0.72rem, 2.6vw, 0.85rem);
  font-weight: 700;
  text-align: center;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(135deg, #229ed9, #2aabee);
  box-shadow: 0 4px 16px rgba(42, 171, 238, 0.35);
  transition: filter 0.15s ease, box-shadow 0.15s ease;
}

.hub-card:hover .hub-card__cta {
  filter: brightness(1.06);
  box-shadow: 0 6px 24px rgba(42, 171, 238, 0.45);
}

.hub-card__cta--discord {
  background: linear-gradient(135deg, #4752c4, #5865f2);
  box-shadow: 0 4px 18px rgba(88, 101, 242, 0.35);
}

.hub-card--discord:hover .hub-card__cta--discord {
  box-shadow: 0 6px 24px rgba(88, 101, 242, 0.45);
}

/* Narrow phones: keep two-up hero without clipping square tiles */
@media (max-width: 380px) {
  .hero__cards {
    gap: 0.4rem;
  }

  .hub-card {
    padding: 0.62rem 0.32rem 0.48rem;
    gap: 0.08rem;
    border-radius: 14px;
  }

  .hub-card__status {
    top: 0.32rem;
    right: 0.32rem;
    font-size: 0.52rem;
    padding: 0.15rem 0.35rem 0.15rem 0.3rem;
  }

  .hub-card__logo-svg {
    width: min(34%, 2.85rem);
  }

  .hub-card__title {
    font-size: 0.78rem;
    letter-spacing: -0.01em;
  }

  .hub-card__desc {
    font-size: 0.58rem;
    margin-bottom: 0.25rem;
  }

  .hub-card__cta {
    padding: 0.35rem 0.28rem;
    font-size: 0.65rem;
    border-radius: 10px;
  }
}

/* Below the fold */
.below-fold {
  padding: 2rem 0 3rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  text-align: center;
}

.bypass-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: 1.35rem 1.4rem;
  text-align: center;
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
}

@media (min-width: 640px) {
  .bypass-card {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1.25rem;
  }

  .bypass-card__btn {
    flex-shrink: 0;
  }
}

.bypass-card__text {
  width: 100%;
  max-width: 40rem;
  margin-inline: auto;
  text-align: center;
}

.bypass-card__title {
  margin: 0 0 0.35rem;
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text);
  text-align: center;
}

.bypass-card__lead {
  margin: 0 auto;
  font-size: 0.95rem;
  color: var(--text-muted);
  max-width: 52ch;
  text-align: center;
}

.note-card {
  margin-inline: auto;
  max-width: 40rem;
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.25);
  border-radius: var(--radius);
  padding: 1rem 1.15rem;
  font-size: 0.9rem;
  color: #fde68a;
  text-align: center;
}

.note-card strong {
  color: #fef3c7;
}

.note-card a {
  color: #fef9c3;
  font-weight: 600;
}

.note-card a:hover {
  color: #fff;
}
