/* === Variables: adserving.ru-inspired palette === */
:root {
  --color-primary: #0055ff;
  --color-primary-dark: #0040c2;
  --color-bg: #f5f7fb;
  --color-text: #1a1d29;
  --color-text-muted: #5b6172;
  --color-card-bg: #f7f9ff;
  --shadow-card: 0 20px 60px rgba(0, 85, 255, 0.12);
  --radius: 20px;

  /* Sequential reveal: block #1 -> #2 -> #3 (delays cut to 1/3 of the original 1s spread) */
  --reveal-duration: 0.3s;
  --reveal-delay-1: 0s;
  --reveal-delay-2: 0.117s;
  --reveal-delay-3: 0.233s;
}

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

html, body {
  height: 100%;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: linear-gradient(160deg, #eef2fb 0%, #ffffff 60%);
  color: var(--color-text);
  min-height: 100vh;
}

#app {
  min-height: 100vh;
  display: flex;
}

/* One-shot entrance animation, shared by all 3 blocks. Using `animation`
   (not `transition`) keeps it from interfering with the separate Vue
   `transition="fade"` that later animates the cookie banner's removal. */
@keyframes reveal-in {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

.page {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 32px;
  padding: 24px;
  padding-bottom: 220px;
  opacity: 0;
}

.page--visible {
  animation: reveal-in var(--reveal-duration) ease var(--reveal-delay-1) forwards;
}

.card {
  position: relative;
  width: 100%;
  max-width: 720px;
  background: var(--color-card-bg);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  padding: 48px 32px;
  text-align: center;
  overflow: hidden;
}

/* Gloss sweep across the whole card.
   Card background is white, so a plain white highlight would be invisible —
   the sweep is tinted with the brand blue instead, framed by a bright core. */
.card__shine {
  position: absolute;
  top: 0;
  left: -120%;
  width: 45%;
  height: 100%;
  background: linear-gradient(
    100deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(0, 85, 255, 0.08) 35%,
    rgba(255, 255, 255, 1) 50%,
    rgba(0, 85, 255, 0.08) 65%,
    rgba(255, 255, 255, 0) 100%
  );
  transform: skewX(-20deg);
  animation: card-shine 3.5s ease-in-out infinite;
  animation-delay: var(--reveal-delay-1);
  pointer-events: none;
}

@keyframes card-shine {
  0% { left: -120%; }
  30% { left: 130%; }
  100% { left: 130%; }
}

/* === Domain heading with shine/gloss effect === */
.domain {
  position: relative;
  display: inline-block;
  font-size: clamp(28px, 6vw, 52px);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: var(--color-primary);
  margin-bottom: 24px;
  overflow: hidden;
}

.domain__text {
  position: relative;
  z-index: 1;
}

.domain__shine {
  position: absolute;
  top: 0;
  left: -150%;
  width: 60%;
  height: 100%;
  background: linear-gradient(
    100deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.75) 50%,
    rgba(255, 255, 255, 0) 100%
  );
  transform: skewX(-20deg);
  animation: shine 2.25s ease-in-out infinite;
  pointer-events: none;
}

@keyframes shine {
  0% { left: -150%; }
  35% { left: 150%; }
  100% { left: 150%; }
}

.description {
  font-size: clamp(15px, 2vw, 18px);
  line-height: 1.7;
  color: var(--color-text-muted);
}

.description strong {
  color: var(--color-text);
  font-weight: 600;
}

/* === Timer === */
.timer {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 14px;
  color: var(--color-text-muted);
  background: rgba(0, 85, 255, 0.06);
  border: 1px solid rgba(0, 85, 255, 0.15);
  border-radius: 999px;
  padding: 10px 20px;
  overflow: hidden;
  opacity: 0;
}

.timer.is-visible {
  animation: reveal-in var(--reveal-duration) ease var(--reveal-delay-3) forwards;
}

.timer__shine {
  position: absolute;
  top: 0;
  left: -120%;
  width: 45%;
  height: 100%;
  background: linear-gradient(
    100deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(0, 85, 255, 0.08) 35%,
    rgba(255, 255, 255, 1) 50%,
    rgba(0, 85, 255, 0.08) 65%,
    rgba(255, 255, 255, 0) 100%
  );
  transform: skewX(-20deg);
  animation: card-shine 3.5s ease-in-out infinite;
  animation-delay: var(--reveal-delay-3);
  pointer-events: none;
}

.timer__value {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  height: 28px;
  font-weight: 700;
  color: var(--color-primary);
  background: rgba(0, 85, 255, 0.1);
  border-radius: 999px;
  padding: 0 8px;
}

/* === Mobile first base already applied above; refine for larger screens === */
@media (min-width: 480px) {
  .card {
    padding: 56px 48px;
  }
}

/* === Bottom stack: cookie banner (top) + timer (bottom) ===
   Both share one fixed, centered column so the timer always renders
   beneath the cookie banner instead of being covered by it. */
.bottom-stack {
  position: fixed;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  width: calc(100% - 32px);
  max-width: 560px;
}

@media (min-width: 768px) {
  .bottom-stack {
    bottom: 24px;
  }
}

/* === Cookie consent banner === */
.cookie-banner {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 16px;
  background: var(--color-card-bg);
  border: 1px solid rgba(0, 85, 255, 0.15);
  border-radius: 16px;
  box-shadow: 0 12px 40px rgba(0, 85, 255, 0.18);
  padding: 20px;
  overflow: hidden;
  opacity: 0;
}

.cookie-banner.is-visible {
  animation: reveal-in var(--reveal-duration) ease var(--reveal-delay-2) forwards;
}

.cookie-banner__shine {
  position: absolute;
  top: 0;
  left: -120%;
  width: 45%;
  height: 100%;
  background: linear-gradient(
    100deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(0, 85, 255, 0.08) 35%,
    rgba(255, 255, 255, 1) 50%,
    rgba(0, 85, 255, 0.08) 65%,
    rgba(255, 255, 255, 0) 100%
  );
  transform: skewX(-20deg);
  animation: card-shine 3.5s ease-in-out infinite;
  animation-delay: var(--reveal-delay-2);
  pointer-events: none;
}

.cookie-banner__text {
  font-size: 13px;
  line-height: 1.6;
  color: var(--color-text-muted);
}

.cookie-banner__link {
  color: var(--color-primary);
  font-weight: 600;
  text-decoration: underline;
}

.cookie-banner__link:hover {
  color: var(--color-primary-dark);
}

.cookie-banner__button {
  align-self: flex-end;
  border: none;
  background: var(--color-primary);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  padding: 10px 24px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.2s ease;
}

.cookie-banner__button:hover {
  background: var(--color-primary-dark);
}

@media (min-width: 600px) {
  .cookie-banner {
    flex-direction: row;
    align-items: center;
  }

  .cookie-banner__button {
    align-self: center;
    flex-shrink: 0;
  }
}

/* fade transition used by Vue <transition name="fade"> */
.fade-enter-active,
.fade-leave-active {
  transition: opacity 0.4s ease;
}

.fade-enter-from,
.fade-leave-to {
  opacity: 0;
}
