/* ==========================================================================
   Главный экран до входа (Guest Landing Experience).
   Анимированный кинематографичный фон (7 артов ArcheAge со слайдером),
   плавный параллакс-эффект при скролле и интерактивная презентация проекта.
   Всё работает только при html[data-auth="guest"].
   ========================================================================== */

:root {
  --font-fantasy: 'Philosopher', 'Cinzel', 'Trajan Pro', Georgia, serif;
  --font-hero: 'Cinzel', 'Philosopher', 'Trajan Pro', Georgia, serif;
  --font-ui: 'Montserrat', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-body: 'Montserrat', 'Inter', -apple-system, sans-serif;
}

:root[data-auth="guest"] .header,
:root[data-auth="guest"] .site-footer,
:root[data-auth="guest"] body > footer,
:root[data-auth="guest"] .main > footer,
:root[data-auth="guest"] .bg-glow { display: none !important; }

:root[data-auth="guest"] body {
  overflow-y: auto !important;
  overflow-x: hidden !important;
  scroll-behavior: smooth;
  background-color: #04070e;
  font-family: var(--font-body);
}

:root[data-auth="guest"] .main,
:root[data-auth="guest"] .main.container {
  padding: 0;
  max-width: none;
}

/* Основной контейнер экрана гостей */
.guest-screen {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  color: #e8edf6;
  z-index: 5;
  font-family: var(--font-body);
}

/* --------------------------------------------------------------------------
   Кинематографичный слайдер фона (фиксирован на весь экран)
   -------------------------------------------------------------------------- */
.guest-scene {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.guest-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(1.05);
  transition: opacity 1.4s cubic-bezier(0.4, 0, 0.2, 1), transform 10s ease-out;
  will-change: opacity, transform;
}

.guest-slide.is-active {
  opacity: 1;
  transform: scale(1);
}

.guest-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 38%;
  filter: saturate(0.92) contrast(1.06);
}

/* Затемняющий градиент: читаемость текста и мягкая виньетка */
.guest-scene::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(105deg, rgba(4,7,14,0.95) 0%, rgba(4,7,14,0.86) 38%, rgba(4,7,14,0.45) 68%, rgba(4,7,14,0.78) 100%),
    radial-gradient(120% 90% at 50% 120%, rgba(0,0,0,0.85), transparent 60%);
  transition: background 0.4s ease;
}

/* Индикаторы слайдов */
.guest-slide-dots {
  position: absolute;
  right: clamp(20px, 4vw, 50px);
  bottom: 34px;
  z-index: 4;
  display: flex;
  gap: 8px;
  pointer-events: auto;
  transition: opacity 0.2s linear;
}

.guest-dot {
  width: 24px;
  height: 6px;
  border-radius: 4px;
  border: 0;
  padding: 0;
  background: rgba(255, 255, 255, 0.25);
  cursor: pointer;
  transition: background 0.3s, width 0.3s, transform 0.2s;
}

.guest-dot:hover {
  background: rgba(245, 158, 11, 0.7);
  transform: scaleY(1.3);
}

.guest-dot.is-active {
  background: #f59e0b;
  width: 38px;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.6);
}

/* --------------------------------------------------------------------------
   Главный экран (Hero Section)
   -------------------------------------------------------------------------- */
.guest-hero {
  position: relative;
  z-index: 2;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  max-width: 1500px;
  margin: 0 auto;
  padding: 60px clamp(24px, 7vw, 110px) 90px;
  box-sizing: border-box;
  pointer-events: none;
}

.guest-hero-inner,
.guest-scroll-indicator,
.guest-slide-dots {
  pointer-events: auto;
}

.guest-hero-inner {
  max-width: 860px;
  will-change: transform, opacity, filter;
  transition: transform 0.08s linear, opacity 0.08s linear, filter 0.08s linear;
}

.guest-mark {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 24px;
}

.guest-mark img {
  width: 48px;
  height: 48px;
  filter: drop-shadow(0 6px 18px rgba(0,0,0,.6));
}

.guest-mark span {
  font: 700 12px/1 var(--font-ui);
  letter-spacing: 4px;
  text-transform: uppercase;
  color: #a0aec0;
}

.guest-title {
  margin: 0;
  font-family: var(--font-hero);
  font-weight: 800;
  font-size: clamp(48px, 7.8vw, 104px);
  line-height: .92;
  letter-spacing: 3px;
  text-shadow: 0 14px 50px rgba(0,0,0,.85), 0 2px 10px rgba(0,0,0,0.5);
  color: #f8fafc;
}

.guest-title em {
  display: block;
  margin-top: 18px;
  font-style: normal;
  font-family: var(--font-fantasy);
  font-weight: 700;
  font-size: clamp(22px, 2.6vw, 36px);
  letter-spacing: 0.24em;
  text-transform: uppercase;
  background: linear-gradient(135deg, #fef08a 0%, #f59e0b 50%, #d97706 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 4px 18px rgba(245,158,11,.45));
}

.guest-tagline {
  margin: 24px 0 0;
  font: 400 clamp(15px, 1.25vw, 17.5px)/1.7 var(--font-body);
  color: #e2e8f0;
  max-width: 720px;
  text-shadow: 0 2px 12px rgba(0,0,0,0.9);
  letter-spacing: 0.01em;
}

.guest-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 44px;
}

.guest-btn {
  height: 52px;
  padding: 0 30px;
  border: 0;
  border-radius: 10px;
  cursor: pointer;
  font: 700 13.5px/1 var(--font-ui);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  transition: transform .2s, box-shadow .2s, border-color .2s, background .2s;
}

.guest-btn:active {
  transform: scale(0.98);
}

.guest-btn-main {
  color: #fff;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  box-shadow: 0 14px 38px rgba(37,99,235,.42);
}

.guest-btn-main:hover {
  box-shadow: 0 18px 48px rgba(37,99,235,.58);
  transform: translateY(-2px);
}

.guest-btn-ghost {
  color: #e8edf6;
  background: rgba(12,18,30,.65);
  border: 1px solid rgba(159,176,200,.35);
  backdrop-filter: blur(8px);
}

.guest-btn-ghost:hover {
  border-color: rgba(245,158,11,.75);
  color: #fff;
  background: rgba(20,28,45,.8);
  transform: translateY(-2px);
}

.guest-btn-explore {
  color: #cbd5e1;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.18);
  backdrop-filter: blur(8px);
}

.guest-btn-explore:hover {
  border-color: #f59e0b;
  color: #f59e0b;
  background: rgba(245,158,11,0.12);
  transform: translateY(-2px);
}

.guest-week {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 36px 0 0;
  font: 600 13px/1.5 var(--font-ui);
  letter-spacing: .4px;
  color: #9fb0c8;
}

.guest-week::before {
  content: '';
  display: block;
  width: 34px;
  height: 1px;
  flex: none;
  background: linear-gradient(90deg, #f59e0b, transparent);
}

.guest-week b {
  color: #f59e0b;
  font-weight: 700;
}

.guest-week[hidden] {
  display: none;
}

/* Индикатор скролла вниз */
.guest-scroll-indicator {
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  background: transparent;
  border: 0;
  color: #94a3b8;
  cursor: pointer;
  padding: 8px;
  transition: color 0.25s, transform 0.25s, opacity 0.2s;
}

.guest-scroll-indicator:hover {
  color: #f59e0b;
  transform: translateX(-50%) translateY(3px);
}

.guest-scroll-mouse {
  width: 22px;
  height: 34px;
  border-radius: 12px;
  border: 2px solid currentColor;
  display: flex;
  justify-content: center;
  padding-top: 6px;
  box-sizing: border-box;
}

.guest-scroll-wheel {
  width: 3px;
  height: 7px;
  border-radius: 2px;
  background: currentColor;
  animation: scrollWheelAnim 1.8s infinite ease-in-out;
}

@keyframes scrollWheelAnim {
  0% { transform: translateY(0); opacity: 1; }
  70% { transform: translateY(8px); opacity: 0; }
  100% { transform: translateY(0); opacity: 0; }
}

.guest-scroll-text {
  font: 700 11px/1 var(--font-ui);
  letter-spacing: 2.5px;
  text-transform: uppercase;
}

.guest-scroll-arrow {
  animation: bounceArrow 1.8s infinite ease-in-out;
}

@keyframes bounceArrow {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(4px); }
}

/* --------------------------------------------------------------------------
   Секция презентации всех возможностей проекта
   -------------------------------------------------------------------------- */
.guest-showcase {
  position: relative;
  z-index: 2;
  padding: 100px 0 70px;
  background: linear-gradient(180deg, rgba(4,7,14,0.65) 0%, rgba(4,7,14,0.94) 180px, rgba(4,7,14,0.99) 100%);
  backdrop-filter: blur(10px);
}

.guest-showcase-shell {
  max-width: 1380px;
  margin: 0 auto;
  padding: 0 clamp(20px, 5vw, 60px);
}

.guest-section-header {
  text-align: center;
  max-width: 820px;
  margin: 0 auto 65px;
}

.guest-eyebrow {
  display: inline-block;
  font: 800 12px/1 var(--font-ui);
  letter-spacing: 4px;
  text-transform: uppercase;
  color: #f59e0b;
  margin-bottom: 14px;
}

.guest-section-title {
  margin: 0 0 16px;
  font-family: var(--font-fantasy);
  font-weight: 700;
  font-size: clamp(30px, 3.8vw, 48px);
  line-height: 1.18;
  color: #f8fafc;
  text-shadow: 0 4px 24px rgba(0,0,0,0.7);
  letter-spacing: 0.02em;
}

.guest-section-desc {
  margin: 0;
  font: 400 clamp(15px, 1.25vw, 17px)/1.7 var(--font-ui);
  color: #94a3b8;
}

/* Группировка разделов (главы экосистемы) */
.guest-showcase-groups {
  display: flex;
  flex-direction: column;
  gap: 52px;
  margin-bottom: 70px;
}

.guest-group {
  display: flex;
  flex-direction: column;
}

.guest-group-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 22px;
}

.guest-group-badge {
  font: 800 11px/1 var(--font-ui);
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 6px;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.35);
  color: #fbbf24;
  flex-shrink: 0;
}

.guest-group-title {
  margin: 0;
  font-family: var(--font-fantasy);
  font-weight: 700;
  font-size: clamp(20px, 2.2vw, 26px);
  color: #f1f5f9;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.guest-group-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, rgba(245, 158, 11, 0.4), rgba(148, 163, 184, 0.12) 65%, transparent);
}

/* Сетки карточек */
.guest-cards-grid {
  display: grid;
  gap: 22px;
}

.guest-grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
}

.guest-grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

/* Карточка инструмента (RPG Card Frame) */
.guest-card {
  position: relative;
  background: linear-gradient(180deg, rgba(14, 22, 38, 0.85) 0%, rgba(8, 13, 24, 0.94) 100%);
  border: 1px solid rgba(212, 163, 89, 0.22);
  border-radius: 14px;
  padding: 26px 24px 22px;
  backdrop-filter: blur(16px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1),
              border-color 0.3s ease,
              box-shadow 0.3s ease;
  overflow: hidden;
}

/* Внутреннее радиальное свечение и верхняя золотая окантовка */
.guest-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 14px;
  background: radial-gradient(circle at top left, var(--card-glow, rgba(245, 158, 11, 0.14)), transparent 60%);
  opacity: 0.6;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.guest-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: 20px;
  right: 20px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(245, 158, 11, 0.45), transparent);
  opacity: 0.6;
  transition: opacity 0.3s ease;
}

.guest-card:hover {
  transform: translateY(-6px);
  border-color: rgba(245, 158, 11, 0.55);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.7), 0 0 24px var(--card-glow, rgba(245, 158, 11, 0.2));
}

.guest-card:hover::before {
  opacity: 1;
}

.guest-card:hover::after {
  opacity: 1;
  background: linear-gradient(90deg, transparent, #fbbf24, transparent);
}

/* Выделенные флагманские карточки */
.guest-card-featured {
  background: linear-gradient(180deg, rgba(18, 28, 50, 0.9) 0%, rgba(9, 15, 28, 0.96) 100%);
  border: 1px solid rgba(245, 158, 11, 0.35);
}

/* Шапка карточки */
.guest-card-head {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 16px;
}

/* Эмблема с реальной иконкой игры */
.guest-card-emblem {
  position: relative;
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background: radial-gradient(circle, rgba(28, 38, 56, 0.95) 0%, rgba(13, 19, 32, 1) 100%);
  border: 1px solid rgba(245, 158, 11, 0.35);
  box-shadow: inset 0 0 14px rgba(0,0,0,0.65), 0 4px 10px rgba(0,0,0,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.guest-card-game-icon {
  width: 36px;
  height: 36px;
  object-fit: contain;
  filter: drop-shadow(0 2px 6px rgba(0,0,0,0.7));
}

.guest-card-meta {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.guest-card-category {
  font: 700 11px/1 var(--font-ui);
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #f59e0b;
  opacity: 0.9;
}

.guest-card-title {
  margin: 0;
  font-family: var(--font-fantasy);
  font-weight: 700;
  font-size: 21px;
  line-height: 1.25;
  color: #f8fafc;
  letter-spacing: 0.015em;
}

/* Текст описания карточки */
.guest-card-desc {
  margin: 0 0 18px;
  font: 400 14px/1.65 var(--font-ui);
  color: #cbd5e1;
  flex: 1;
}

/* Игровой виджет характеристик вместо банальных тегов */
.guest-card-glance {
  background: rgba(4, 8, 17, 0.6);
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 8px;
  padding: 11px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: auto;
}

.guest-glance-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font: 500 12px/1.35 var(--font-ui);
}

.guest-glance-k {
  color: #94a3b8;
  flex-shrink: 0;
}

.guest-glance-v {
  color: #e2e8f0;
  font-weight: 600;
  text-align: right;
}

.guest-glance-v.guest-gold {
  color: #fbbf24;
}

.guest-glance-v.guest-accent {
  color: #60a5fa;
}

/* --------------------------------------------------------------------------
   CTA Блок (Call-To-Action)
   -------------------------------------------------------------------------- */
.guest-cta {
  position: relative;
  background: linear-gradient(135deg, rgba(24, 34, 52, 0.88) 0%, rgba(12, 18, 32, 0.96) 100%);
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-radius: 16px;
  padding: clamp(36px, 6vw, 56px) clamp(24px, 5vw, 50px);
  text-align: center;
  margin: 40px 0 70px;
  backdrop-filter: blur(16px);
  box-shadow: 0 20px 50px rgba(0,0,0,0.6), 0 0 30px rgba(245,158,11,0.12);
  overflow: hidden;
}

.guest-cta-glow {
  position: absolute;
  top: -100px;
  left: 50%;
  transform: translateX(-50%);
  width: 340px;
  height: 220px;
  background: radial-gradient(circle, rgba(245, 158, 11, 0.28), transparent 70%);
  filter: blur(40px);
  pointer-events: none;
}

.guest-cta-title {
  margin: 0 0 14px;
  font-family: var(--font-fantasy);
  font-weight: 700;
  font-size: clamp(26px, 3.4vw, 38px);
  color: #f8fafc;
  letter-spacing: 0.02em;
}

.guest-cta-text {
  max-width: 640px;
  margin: 0 auto 32px;
  font: 400 15px/1.7 var(--font-ui);
  color: #cbd5e1;
}

.guest-cta-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
}

/* --------------------------------------------------------------------------
   Гостевой футер
   -------------------------------------------------------------------------- */
.guest-footer {
  border-top: 1px solid rgba(148, 163, 184, 0.14);
  padding: 36px 0 50px;
  text-align: center;
}


.guest-footer-copy {
  margin: 0;
  font: 400 12px/1.6 var(--font-ui);
  color: #64748b;
  max-width: 700px;
  margin: 0 auto;
}

/* --------------------------------------------------------------------------
   Адаптивность (Mobile & Tablet)
   -------------------------------------------------------------------------- */
@media (max-width: 768px) {
  .guest-hero {
    padding: 40px 20px 80px;
  }
  .guest-actions {
    gap: 12px;
  }
  .guest-actions .guest-btn {
    flex: 1 1 100%;
  }
  .guest-week {
    margin-top: 24px;
    font-size: 12px;
  }
  .guest-grid-2,
  .guest-grid-3 {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .guest-group-header {
    flex-wrap: wrap;
    gap: 10px;
  }
  .guest-group-line {
    display: none;
  }
  .guest-card {
    padding: 22px 18px;
  }
  .guest-cta-actions .guest-btn {
    flex: 1 1 100%;
  }
  .guest-scroll-indicator {
    bottom: 46px;
  }
  .guest-slide-dots {
    right: auto;
    left: 50%;
    transform: translateX(-50%);
    bottom: 16px;
  }
}

/* --------------------------------------------------------------------------
   Служебные стили формы авторизации (сохранены из оригинального файла)
   -------------------------------------------------------------------------- */
#loginForm .registration-entry { margin-top: 12px; font-size: 13px; color: var(--primary); }
#loginForm .registration-entry:hover { text-decoration: underline; }
#loginForm > .link-btn:not(.registration-entry) { margin-top: 10px; font-size: 11.5px; font-weight: 500; }
#loginForm > .registration-entry + .link-btn { margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--border-color); }
.registration-form [data-resend] { margin-top: 14px; }
