:root {
  --bg-1: #05020b;
  --bg-2: #120824;
  --ink: #f4eeff;
  --muted: #bdaed8;
  --purple-1: #8b5cf6;
  --purple-2: #a78bfa;
  --purple-3: #ec4899;
  --line: rgba(255, 255, 255, 0.14);
  --panel: rgba(13, 10, 24, 0.34);
  --ok: #a7f3d0;
  --error: #fda4af;
  --glass-surface: rgba(16, 14, 30, 0.2);
  --glass-border: rgba(210, 192, 255, 0.3);
  --glass-inner: rgba(255, 255, 255, 0.14);
}

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

html,
body {
  width: 100%;
  min-height: 100%;
}

body {
  font-family: "Manrope", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 15% 10%, rgba(139, 92, 246, 0.2), transparent 38%),
    radial-gradient(circle at 85% 90%, rgba(236, 72, 153, 0.16), transparent 42%),
    linear-gradient(145deg, var(--bg-1) 0%, #090412 40%, var(--bg-2) 100%);
  overflow: hidden;
  overflow-x: hidden;
}

.bg-orb {
  position: fixed;
  border-radius: 999px;
  filter: blur(80px);
  z-index: 0;
  animation: orbFloat 16s ease-in-out infinite alternate;
}

.orb-a {
  width: 34rem;
  height: 34rem;
  top: -11rem;
  left: -10rem;
  background: rgba(139, 92, 246, 0.34);
}

.orb-b {
  width: 29rem;
  height: 29rem;
  right: -8rem;
  bottom: -9rem;
  background: rgba(236, 72, 153, 0.22);
  animation-duration: 20s;
}

.bg-grid {
  position: fixed;
  inset: 0;
  z-index: 0;
  opacity: 0.17;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.07) 1px, transparent 1px);
  background-size: 38px 38px;
  mask-image: radial-gradient(circle at center, black 35%, transparent 85%);
}

.meme-stream {
  position: fixed;
  inset: -12vh 0 -12vh 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
  min-height: 120vh;
  column-count: 5;
  column-gap: 0.24rem;
  padding: 0.24rem;
  transform: translate3d(0, 0, 0);
  will-change: transform;
  content-visibility: auto;
  contain: layout paint style;
}

.meme-stream::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(5, 2, 11, 0.28) 0%,
    rgba(7, 4, 14, 0.14) 45%,
    rgba(10, 5, 16, 0.26) 100%
  );
  z-index: 1;
}

.meme-row {
  display: contents;
}

.meme-tile {
  width: 100%;
  margin: 0 0 0.24rem;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid rgba(173, 135, 255, 0.24);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  break-inside: avoid;
  opacity: 0.24;
  animation: none;
  will-change: transform;
  background: rgba(12, 10, 18, 0.6);
}

.meme-tile img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  filter: saturate(0.96) contrast(0.95) brightness(0.84);
}

.stage {
  min-height: 100vh;
  padding: 2rem;
  display: grid;
  place-items: center;
  position: relative;
  z-index: 1;
}

.panel {
  width: min(840px, 100%);
  max-width: 100%;
  padding: 3.6rem 2.8rem;
  border-radius: 28px;
  border: 1px solid var(--line);
  background: rgba(16, 14, 30, 0.16);
  backdrop-filter: blur(16px) saturate(1.14);
  -webkit-backdrop-filter: blur(16px) saturate(1.14);
  text-align: center;
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.56),
    inset 0 0 0 1px rgba(255, 255, 255, 0.32),
    0 0 96px -42px rgba(167, 139, 250, 0.45);
  position: relative;
  overflow: hidden;
  animation: panelIn 850ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

.panel::before {
  content: "";
  position: absolute;
  inset: -130% -55%;
  background: linear-gradient(
    120deg,
    transparent 40%,
    rgba(255, 255, 255, 0.08) 50%,
    transparent 60%
  );
  transform: rotate(9deg);
  opacity: 0.14;
  animation: sheen 9s ease-in-out infinite;
}

.panel::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.06) 1px, transparent 1px);
  background-size: 34px 34px;
  opacity: 0.22;
  pointer-events: none;
}

.panel > * {
  position: relative;
  z-index: 1;
}

.logo {
  font-family: "Irish Grover", cursive;
  font-size: clamp(2.2rem, 8vw, 5.5rem);
  line-height: 1;
  letter-spacing: 0.01em;
  background: linear-gradient(135deg, #ffffff 0%, #d8c7ff 45%, #a78bfa 75%, #8b5cf6 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 28px rgba(167, 139, 250, 0.25);
}

.fonts-loading .logo {
  visibility: hidden;
}

.fonts-ready .logo {
  visibility: visible;
}

.logo .dot {
  font-size: 0.54em;
}

.description {
  max-width: 62ch;
  margin: 1.25rem auto 2.2rem;
  color: #dbcfef;
  line-height: 1.78;
  font-size: 1.02rem;
}

.platform-glimpse {
  max-width: 700px;
  margin: 0 auto 1.65rem;
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02)),
    var(--glass-surface);
  padding: 0.8rem;
  overflow: hidden;
  box-shadow:
    inset 0 0 0 1px var(--glass-inner),
    0 12px 32px rgba(0, 0, 0, 0.24);
}

.glimpse-viewport {
  max-height: 260px;
  overflow: hidden;
  position: relative;
}

.glimpse-head {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  color: #c5b5e3;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 0.6rem;
}

.activity-pill {
  margin-left: auto;
  font-size: 0.58rem;
  letter-spacing: 0.12em;
  border: 1px solid rgba(167, 139, 250, 0.45);
  border-radius: 999px;
  padding: 0.28rem 0.45rem;
  color: #dfd2f6;
  background: rgba(167, 139, 250, 0.12);
  animation: tickerBlink 2.2s ease-in-out infinite;
}

.dot.live {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: #a78bfa;
  box-shadow: 0 0 0 0 rgba(167, 139, 250, 0.65);
  animation: livePulse 1.8s ease-out infinite;
}

.glimpse-track {
  display: flex;
  gap: 0.5rem;
  width: max-content;
  animation: previewSlide 64s linear infinite;
}

.platform-glimpse:hover .glimpse-track {
  animation-play-state: paused;
}

.preview-card {
  width: 198px;
  text-align: left;
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02)),
    rgba(14, 11, 28, 0.34);
  backdrop-filter: blur(14px) saturate(1.12);
  -webkit-backdrop-filter: blur(14px) saturate(1.12);
  box-shadow: inset 0 0 0 1px var(--glass-inner);
  padding: 0.62rem;
  animation: none;
  position: relative;
  overflow: hidden;
}

.preview-card::after {
  content: none;
  position: absolute;
  inset: -120% -70%;
  background: linear-gradient(
    118deg,
    transparent 44%,
    rgba(255, 255, 255, 0.09) 50%,
    transparent 56%
  );
  transform: rotate(8deg);
  animation: none;
  pointer-events: none;
}

.preview-user {
  font-size: 0.73rem;
  color: #c4b5fd;
  margin-bottom: 0.32rem;
}

.preview-text {
  font-size: 0.8rem;
  color: #ece5fb;
  line-height: 1.36;
  min-height: 2rem;
}

.preview-stats {
  margin-top: 0.45rem;
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  font-size: 0.63rem;
  color: #9d8fbc;
}

.notify-form {
  max-width: 660px;
  margin: 0 auto;
  border-radius: 999px;
  border: 1px solid var(--glass-border);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.015)),
    var(--glass-surface);
  display: flex;
  align-items: center;
  padding: 0.55rem;
  gap: 0.65rem;
  transition: border-color 220ms ease, box-shadow 220ms ease;
  box-shadow: inset 0 0 0 1px var(--glass-inner);
}

.notify-form:focus-within {
  border-color: rgba(220, 200, 255, 0.8);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.24),
    0 0 0 3px rgba(139, 92, 246, 0.22);
}

.notify-form input {
  flex: 1;
  min-width: 0;
  border: none;
  outline: none;
  background: transparent;
  color: #f8f4ff;
  font-size: 1rem;
  padding: 0 0.95rem;
}

.notify-form input::placeholder {
  color: #8f80af;
}

.notify-form button {
  border: none;
  border-radius: 999px;
  padding: 0.86rem 1.45rem;
  color: #fff;
  font-weight: 800;
  letter-spacing: 0.02em;
  cursor: pointer;
  background: linear-gradient(120deg, #8f63ff, #a78bfa, #df5fb2);
  background-size: 200% 200%;
  animation: buttonFlow 3.5s ease infinite;
  transition: transform 170ms ease;
}

.notify-form button:hover {
  transform: translateY(-1px);
  filter: brightness(1.04);
}

.form-message {
  min-height: 1.3rem;
  margin-top: 0.9rem;
  font-size: 0.9rem;
  color: #b9abd4;
  font-weight: 600;
}

.form-message.success {
  color: var(--ok);
}

.form-message.error {
  color: var(--error);
}

.footer-note {
  margin-top: 0.9rem;
  color: #ab9ec6;
  font-size: 0.82rem;
  letter-spacing: 0.05em;
}

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

@keyframes orbFloat {
  from {
    transform: translate3d(0, 0, 0) scale(1);
  }
  to {
    transform: translate3d(24px, -18px, 0) scale(1.08);
  }
}

@keyframes masonryDrift {
  0% {
    transform: translate3d(0, 0, 0);
  }
  100% {
    transform: translate3d(0, -10%, 0);
  }
}

@keyframes memeTileFloat {
  0%, 100% {
    transform: translate3d(0, 0, 0);
  }
  50% {
    transform: translate3d(0, -18px, 0);
  }
}

@keyframes panelIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes sheen {
  0% { transform: translateX(-45%) rotate(9deg); }
  36% { transform: translateX(-45%) rotate(9deg); }
  58% { transform: translateX(45%) rotate(9deg); }
  100% { transform: translateX(45%) rotate(9deg); }
}

@keyframes buttonFlow {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

@keyframes livePulse {
  0% {
    box-shadow: 0 0 0 0 rgba(167, 139, 250, 0.65);
  }
  80% {
    box-shadow: 0 0 0 9px rgba(167, 139, 250, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(167, 139, 250, 0);
  }
}

@keyframes previewSlide {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(calc(-50% - 0.3rem));
  }
}

@keyframes cardFloat {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-5px);
  }
}

@keyframes cardShimmer {
  0% {
    transform: translateX(-62%) rotate(8deg);
  }
  100% {
    transform: translateX(62%) rotate(8deg);
  }
}

@keyframes tickerBlink {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.62;
  }
}

@media (max-width: 760px) {
  html,
  body {
    margin: 0;
    padding: 0;
    width: 100%;
    overflow-x: hidden;
  }

  main.stage {
    width: 100vw;
    min-width: 100vw;
    margin: 0;
  }

  body {
    overflow: auto;
  }

  .stage {
    padding-top: 0;
    padding-bottom: 0;
    padding-left: 0.6rem;
    padding-right: 0.6rem;
  }

  .panel {
    width: 100%;
    max-width: calc(100vw - 1.2rem);
    margin: 0;
    border-radius: 20px;
    border: 1px solid rgba(210, 192, 255, 0.32) !important;
    padding: 1.7rem 0.9rem;
    background: rgba(16, 14, 30, 0.1);
    backdrop-filter: blur(8px) saturate(1.04);
    -webkit-backdrop-filter: blur(8px) saturate(1.04);
    box-shadow:
      0 12px 24px rgba(0, 0, 0, 0.34),
      0 0 70px -40px rgba(167, 139, 250, 0.36);
  }

  .description {
    font-size: 0.93rem;
    margin-bottom: 1.4rem;
  }

  .platform-glimpse {
    margin-bottom: 1rem;
    padding: 0.6rem;
    overflow: hidden;
  }

  .activity-pill {
    display: none;
  }

  .meme-stream {
    column-count: 3;
    column-gap: 0.2rem;
    padding: 0.2rem;
    transform: translate3d(0, 0, 0);
    inset: -10vh 0 -10vh 0;
    min-height: 112vh;
  }

  .meme-stream::before {
    background: linear-gradient(
      180deg,
      rgba(5, 2, 11, 0.22) 0%,
      rgba(7, 4, 14, 0.12) 45%,
      rgba(10, 5, 16, 0.26) 100%
    );
  }

  .meme-row {
    display: contents;
  }

  .meme-tile {
    border-radius: 6px;
    margin-bottom: 0.2rem;
    opacity: 0.2;
    animation: none;
  }

  .meme-tile img {
    filter: saturate(1) contrast(0.98) brightness(0.92);
  }

  .glimpse-track {
    width: 100%;
    animation: mobileFeedRun 48s linear infinite;
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.55rem;
    overflow-x: hidden;
    padding-right: 0;
    will-change: transform;
  }

  .preview-card {
    width: 100%;
    min-width: 0;
    flex: initial;
    animation: none;
  }

  .preview-card::after {
    animation: none;
  }

  .notify-form {
    border-radius: 14px;
    flex-direction: column;
    gap: 0.55rem;
    padding: 0.7rem;
  }

  .notify-form input,
  .notify-form button {
    width: 100%;
    border-radius: 10px;
    padding: 0.9rem 1rem;
  }
}

@media (max-width: 420px) {
  .panel {
    max-width: calc(100vw - 1rem);
    width: calc(100vw - 1rem);
    margin: 0;
    border-radius: 16px;
    padding: 1.5rem 0.85rem;
  }

  .meme-stream {
    column-count: 2;
    column-gap: 0.16rem;
    padding: 0.16rem;
    inset: -8vh 0 -8vh 0;
    min-height: 108vh;
  }

  .meme-tile { margin-bottom: 0.16rem; }

  .logo {
    font-size: clamp(2rem, 14vw, 3rem);
  }

  .description {
    line-height: 1.62;
  }

  .preview-card {
    min-width: 100%;
    flex-basis: 100%;
    padding: 0.58rem;
  }
}

@keyframes mobileFeedRun {
  0% {
    transform: translateY(0);
  }
  100% {
    transform: translateY(calc(-50% - 0.28rem));
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
