/* =========================================================
   NeoQub — κινηματογραφική εισαγωγή (προσχέδιο)
   Χιλιάδες κουκκίδες συναρμολογούνται στον κύβο του σήματος,
   ενώ μια σύντομη ιστορία προχωράει με το scroll.
   ========================================================= */

html:not(.js) .intro { display: none; }

.intro {
  position: relative;
  z-index: 2;
  height: 250vh;
  background: #04040a;
}

/* Ομαλή μετάβαση από το μαύρο της εισαγωγής στο site */
.intro::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  height: 16vh;
  pointer-events: none;
  background: linear-gradient(#04040a, rgba(4, 4, 10, 0));
}

.intro-stage {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
}

.intro-stage canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

/* Βινιέτα: σκοταδι στις άκρες, όπως σε κινηματογραφικό κάδρο */
.intro-stage::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(120% 90% at 50% 45%, transparent 55%, rgba(0, 0, 0, 0.7) 100%);
}

.intro-lines {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 13vh;
  height: 8.5em;
  z-index: 2;
  pointer-events: none;
  font-size: clamp(1.55rem, 3.3vw, 3rem);
}

.intro-line {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  margin: 0 auto;
  padding-inline: 24px;
  max-width: 26ch;
  box-sizing: content-box;
  text-wrap: balance;
  text-align: center;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1em;
  line-height: 1.14;
  letter-spacing: -0.025em;
  color: var(--text);
  opacity: 0;
  will-change: opacity, transform, filter;
}

.intro-line .soft { color: var(--muted); font-weight: 500; }

/* Το τελικό «Neo Qub» στο κέντρο, πάνω από τον κύβο που σβήνει */
.intro-mark {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 18px;
  pointer-events: none;
  opacity: 0;
  text-align: center;
}
.intro-mark .word {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(3rem, 10vw, 8.5rem);
  letter-spacing: -0.035em;
  line-height: 1;
}
.intro-mark .word b {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.intro-mark .tag {
  font-size: clamp(1rem, 1.6vw, 1.3rem);
  color: var(--muted);
}

.intro-cue {
  position: absolute;
  left: 50%;
  bottom: 32px;
  z-index: 2;
  transform: translateX(-50%);
  display: grid;
  justify-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--dim);
  pointer-events: none;
}
.intro-cue i {
  position: relative;
  display: block;
  width: 1px;
  height: 44px;
  background: var(--line-2);
  overflow: hidden;
}
.intro-cue i::after {
  content: "";
  position: absolute;
  left: 0;
  top: -40%;
  width: 1px;
  height: 40%;
  background: var(--violet-2);
  animation: intro-cue 2.2s cubic-bezier(0.65, 0, 0.35, 1) infinite;
}
@keyframes intro-cue { to { top: 100%; } }

/* Η μπάρα πλοήγησης κρύβεται όσο παίζει η εισαγωγή */
.nav { transition: padding 0.4s var(--ease), opacity 0.6s var(--ease), transform 0.6s var(--ease); }
.in-intro .nav { opacity: 0; transform: translateY(-12px); pointer-events: none; }
.in-intro .progress { opacity: 0; }
/* Με το πληκτρολόγιο (Tab) η μπάρα εμφανίζεται αμέσως */
.in-intro .nav:focus-within { opacity: 1; transform: none; pointer-events: auto; }

@media (max-width: 720px) {
  .intro { height: 220vh; }
  .intro-lines { bottom: 16vh; }
}

/* Όποιος έχει ζητήσει λιγότερη κίνηση, πάει κατευθείαν στο site */
@media (prefers-reduced-motion: reduce) {
  .intro { display: none; }
}
