/* ══════════════════════════════════════════════════════════════
   Главная страница
   ══════════════════════════════════════════════════════════════ */

/* ── Hero ─────────────────────────────────────────────────────────── */
.hero {
  position: relative;
  overflow: hidden;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: transparent;
}

/* Обёртка для заголовка + соцсетей — поверх люмена, смещена чуть выше центра */
.hero-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 34px;
  margin-top: -6vh;
}

/* SVG-заголовок — нельзя перетаскивать */
.hero-title-img {
  width: min(740px, 90vw);
  height: auto;
  pointer-events: none;
  -webkit-user-drag: none;
  user-select: none;
}

/* Нижняя панель: подпись + стрелка — прибита к низу первого экрана */
.hero-bottom {
  position: absolute;
  bottom: 32px;
  left: 0; right: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  z-index: 1;
}

/* Социальные иконки */
.hero-socials {
  display: flex; align-items: center; justify-content: center;
  gap: 24px;
}
.hero-social {
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  opacity: 0.80;
  transition: opacity 0.2s, transform 0.2s;
}
.hero-social:hover { opacity: 1; transform: translateY(-2px); }
.hero-social img {
  width: 20px; height: 20px;
  object-fit: contain;
  filter: brightness(0) invert(1);
}
/* VK PNG имеет больше воздуха вокруг иконки — чуть больше размер */
.hero-social--vk img { width: 24px; height: 24px; }

/* Подзаголовок */
.hero-sub {
  font-size: 13px;
  color: rgba(255,255,255,0.55);
  line-height: 1.6;
  max-width: 320px;
  text-align: center;
}

/* Стрелка вниз (SVG-шеврон) */
.hero-arrow {
  display: block;
  animation: bounce 2s ease-in-out infinite;
}
@keyframes bounce {
  0%,100% { transform: translateY(0); }
  50%      { transform: translateY(7px); }
}

/* ── Секция карточек ──────────────────────────────────────────────── */
.cards-section {
  padding: 16px 20px 48px;  /* верх уменьшен — карточка имеет свой отступ */
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

/* ── Карточка музея ───────────────────────────────────────────────── */
.card-museum {
  width: min(520px, 100%);
  background: linear-gradient(170deg, #7B4FFF 0%, #6B42F5 45%, #5835E8 100%);
  border-radius: 34px;
  /* равный паддинг → заголовок по центру карточки */
  padding: 36px 22px 36px;
  min-height: 112px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: filter 0.18s;
  text-decoration: none;
  color: #fff;
  position: relative;
  overflow: visible;
  margin-top: 36px;
  margin-bottom: 32px; /* 25px выступ пилюли + отступ */
  box-shadow:
    inset 0 2px 3px rgba(255,255,255,0.48),
    inset 0 -8px 8px rgba(0,0,0,0.58),
    0 14px 48px rgba(0,0,0,0.55);
}
.card-museum:hover { filter: brightness(0.93); }

/* Логотип М — торчит над верхним краем карточки */
.card-museum__logo {
  position: absolute;
  top: -36px;
  left: 50%;
  transform: translateX(-50%);
  height: 64px;
  width: auto;
  filter: brightness(0) invert(1);
  pointer-events: none;
}

.card-museum__title {
  font-family: "Actay Wide", sans-serif;
  font-size: clamp(18px, 5.5vw, 36px);
  font-weight: 700;
  text-align: center;
  letter-spacing: 0.03em;
  line-height: 1.1;
  white-space: nowrap;
}

/* Обёртка — центрирована по горизонтали, ширина по контенту (уже карточки) */
.card-museum__sub {
  position: absolute;
  bottom: -25px;
  left: 50%;
  transform: translateX(-50%);
  width: max-content;
  max-width: calc(100% - 44px); /* не выходить за паддинги карточки */
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Длинная пилюля — ширина по тексту */
.card-museum__sub-text {
  height: 50px;
  display: flex;
  align-items: center;
  padding: 3px 22px 0; /* 3px сверху → текст чуть ниже оптического центра */
  background: linear-gradient(135deg, #3DE8C4 0%, #28C9A8 100%);
  border-radius: 9999px;
  font-size: 13px;
  color: #0A1F1A;
  white-space: nowrap;
  font-weight: 500;
  box-shadow:
    inset 0 2px 4px rgba(255,255,255,0.40),
    inset 0 -3px 7px rgba(0,0,0,0.18),
    0 6px 18px rgba(0,0,0,0.38);
}

/* Отдельная круглая пилюля-стрелка — такой же высоты */
.card-museum__sub-arrow {
  width: 50px; height: 50px;
  flex-shrink: 0;
  background: linear-gradient(170deg, #52EDD5 0%, #3DE8C4 50%, #28C9A8 100%);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  padding-top: 3px; /* стрелка чуть ниже оптического центра */
  font-size: 18px; color: #0A1F1A;
  font-weight: 700;
  box-shadow:
    inset 0 2px 4px rgba(255,255,255,0.55),
    inset 0 -3px 7px rgba(0,0,0,0.22),
    0 6px 18px rgba(0,0,0,0.38);
}

/* ── Плашка порталов: две кнопки на одной полупрозрачной плашке ────── */
.portals-panel {
  width: min(520px, 100%);
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 14px;
  /* концентричные углы: радиус_внешнего = радиус_внутреннего(30) + отступ(14) */
  border-radius: 44px;
  background: rgba(26, 19, 58, 0.50);
  border: 1px solid rgba(255,255,255,0.08);
  -webkit-backdrop-filter: blur(6px);
          backdrop-filter: blur(6px);
  box-shadow:
    inset 0 2px 2px rgba(255,255,255,0.12),
    inset 0 -9px 9px rgba(0,0,0,0.46),
    0 16px 44px rgba(0,0,0,0.45);
}
.portals-panel .card-portal { width: 100%; }

/* ── Карточки порталов ────────────────────────────────────────────── */
.card-portal {
  width: min(520px, 100%);
  border-radius: 30px;
  padding: 28px 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: filter 0.18s;
  text-decoration: none;
  color: #fff;
}
.card-portal:hover { filter: brightness(0.92); }

.card-portal--purple {
  background: linear-gradient(175deg, #7A4FFF 0%, #6C41FF 50%, #5835E8 100%);
  box-shadow:
    inset 0 2px 3px rgba(255,255,255,0.52),
    inset 0 -8px 8px rgba(0,0,0,0.60),
    0 12px 40px rgba(0,0,0,0.50);
}

.card-portal--teal {
  background: linear-gradient(175deg, #52EDD5 0%, #3DE8C4 50%, #28C9A8 100%);
  color: #0A1F1A;
  box-shadow:
    inset 0 2px 3px rgba(255,255,255,0.74),
    inset 0 -8px 8px rgba(0,0,0,0.34),
    0 12px 40px rgba(0,0,0,0.45);
}

.card-portal__title {
  font-family: "Actay Wide", sans-serif;
  font-size: clamp(17px, 4.6vw, 26px);
  font-weight: 700;
  text-align: center;
  white-space: nowrap;   /* строго одна строка */
}

/* ── ОГБИ — PNG-кнопка ────────────────────────────────────────────── */
.ogbi-section {
  padding: 0 20px 56px;
  display: flex;
  justify-content: center;
}

.ogbi-link {
  display: block;
  width: min(520px, 100%);
  border-radius: 20px;
  overflow: hidden;
  margin-left: -16px;
  /* сброс для использования как <button> */
  background: none; border: none; padding: 0; font: inherit;
  cursor: pointer;
  transition: filter 0.2s, transform 0.15s;
}
.ogbi-link:hover  { filter: brightness(0.92); }
.ogbi-link:active { transform: scale(0.98); }

.ogbi-img {
  width: 100%;
  height: auto;
  display: block;
  pointer-events: none;
  user-select: none;
  -webkit-user-drag: none;
}

/* ── Мобильная адаптация ──────────────────────────────────────────── */
@media (max-width: 480px) {
  .hero-content {
    gap: 16px;
    margin-top: -4vh;
  }
  .hero-title-img {
    width: min(340px, 88vw);
  }
  .hero-bottom {
    bottom: 20px;
    gap: 6px;
  }
  .hero-sub {
    font-size: 13px;
  }
  .cards-section {
    padding: 36px 16px 36px;
  }
  .ogbi-section {
    padding: 0 16px 40px;
  }
  /* Музей: меньше паддинг + более компактные пилюли */
  .card-museum {
    padding: 28px 18px 28px;
    min-height: 88px;
    margin-bottom: 24px;
  }
  .card-museum__sub {
    bottom: -18px;
  }
  .card-museum__sub-text {
    height: 36px;
    font-size: 11px;
    padding: 3px 14px 0;
  }
  .card-museum__sub-arrow {
    width: 36px;
    height: 36px;
    font-size: 14px;
    padding-top: 3px;
  }
}
