/* SENTOVRA — coming soon. Static, no build step. */

@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 200;
  font-display: swap;
  src: url("/fonts/ibm-plex-sans-latin-200-normal.woff2") format("woff2");
}
@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/ibm-plex-sans-latin-400-normal.woff2") format("woff2");
}

:root {
  --night: #04060c;        /* page ground: deeper, so the light has somewhere to fall from */
  --navy: #10182b;         /* brand navy, used as light on the ground */
  --ice: #cfe0f5;          /* signal line */
  --white: #f3f6fb;        /* headline, wordmark */
  --silver: #a3b1c6;       /* supporting line */

  /* The symbol is sized against the shorter viewport side so short landscape phones still fit. */
  --symbol-w: clamp(6.25rem, min(14.5vw, 25vh), 13.5rem);

  /* Reveal clock (seconds). signal.js reads the symbol's animation start to stay in step. */
  --t-symbol: 2.25s;
  --t-wordmark: 2.6s;
  --t-headline: 2.95s;
  --t-support: 3.4s;
  --t-soon: 4s;
  --t-sheen: 3.2s;
}

*,
*::before,
*::after { box-sizing: border-box; }

html {
  background: var(--night);
  color-scheme: dark;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--night);
  color: var(--white);
  font-family: "IBM Plex Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

.stage {
  position: relative;
  isolation: isolate;
  display: grid;
  place-items: center;
  min-height: 100vh;
  min-height: 100svh;
  padding-block: max(2.5rem, env(safe-area-inset-top)) max(2.5rem, env(safe-area-inset-bottom));
  padding-inline: max(1.5rem, env(safe-area-inset-left)) max(1.5rem, env(safe-area-inset-right));
  overflow: hidden;
  /* A pool of cold light behind the symbol, falling off into the ground. */
  background:
    radial-gradient(ellipse 120% 90% at 50% 42%, rgba(0, 0, 0, 0) 52%, rgba(0, 0, 0, 0.55) 100%),
    radial-gradient(ellipse 46vmax 30vmax at 50% 41%, rgba(52, 82, 146, 0.42), rgba(20, 32, 62, 0.22) 44%, rgba(4, 6, 12, 0) 72%),
    linear-gradient(180deg, #05080f 0%, var(--night) 58%, #020308 100%);
}

/* Fine static grain: keeps the dark gradient from banding. */
.stage::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.07;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.62' numOctaves='3' seed='4' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .8  0 0 0 0 .86  0 0 0 0 1  0 0 0 .55 0'/%3E%3C/filter%3E%3Crect width='240' height='240' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 240px 240px;
}

.signal {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  display: block;
  pointer-events: none;
}

.reveal {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  width: 100%;
  max-width: 46rem;
  /* Optical centre: the symbol sits a little above the middle of the screen. */
  margin-block-end: clamp(0rem, 5vh, 3.5rem);
}

.brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(1.5rem, 4.2vh, 2.75rem);
}

.symbol-wrap {
  position: relative;
  display: block;
  width: var(--symbol-w);
}

/* Static signal line through the listening slit. It is the picture when the script
   does not run; signal.js replaces it with the live canvas (html.signal-live). */
.symbol-wrap::before {
  content: "";
  position: absolute;
  inset-block-start: 50%;
  inset-inline-start: 50%;
  width: 100vw;
  height: 1px;
  transform: translate(-50%, -50%);
  background: linear-gradient(90deg,
    rgba(207, 224, 245, 0) 0%,
    rgba(207, 224, 245, 0.3) 18%,
    rgba(207, 224, 245, 0.85) 50%,
    rgba(207, 224, 245, 0.3) 82%,
    rgba(207, 224, 245, 0) 100%);
  /* The line pauses where the symbol stands; .thread carries it through the slit as a wave. */
  -webkit-mask-image: linear-gradient(90deg, #000 calc(50% - var(--symbol-w) * 0.66), transparent 0, transparent calc(50% + var(--symbol-w) * 0.66), #000 0);
  mask-image: linear-gradient(90deg, #000 calc(50% - var(--symbol-w) * 0.66), transparent 0, transparent calc(50% + var(--symbol-w) * 0.66), #000 0);
  pointer-events: none;
}

/* The same line inside the symbol: it bends into the wave of the slit and straightens again
   just outside it (0.16 of the symbol's width on each side, the hole left in the line above). */
.thread {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
  pointer-events: none;
}
.thread path {
  fill: none;
  stroke: rgba(207, 224, 245, 0.85);
  stroke-width: 1px;
  vector-effect: non-scaling-stroke;
}
.signal-live .symbol-wrap::before,
.signal-live .thread { display: none; }

.symbol {
  position: relative;
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}

.wordmark {
  display: block;
  width: clamp(6.75rem, calc(var(--symbol-w) * 0.74), 9.5rem);
  height: auto;
  color: var(--white);
}

.headline {
  margin: clamp(2.25rem, 7vh, 4.5rem) 0 0;
  font-size: clamp(1.85rem, 0.95rem + 3.7vw, 4rem);
  font-weight: 200;
  line-height: 1.08;
  letter-spacing: -0.03em;
  color: var(--white);
  text-wrap: balance;
}

.support {
  margin: clamp(0.9rem, 2.2vh, 1.35rem) 0 0;
  font-size: clamp(1rem, 0.94rem + 0.3vw, 1.1875rem);
  line-height: 1.5;
  letter-spacing: 0.012em;
  color: var(--silver);
  text-wrap: balance;
}

/* The closing line, set apart at the foot of the screen like a title card. */
.soon {
  position: absolute;
  z-index: 2;
  inset-inline: 0;
  inset-block-end: max(1.75rem, env(safe-area-inset-bottom));
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.1rem;
  font-size: 0.875rem;
  letter-spacing: 0.16em;
  color: var(--silver);
  white-space: nowrap;
}
.soon::before,
.soon::after {
  content: "";
  width: clamp(1.75rem, 6vw, 4.5rem);
  height: 1px;
  background: linear-gradient(90deg, rgba(163, 177, 198, 0), rgba(163, 177, 198, 0.55));
}
.soon::after { transform: scaleX(-1); }

/* Light on the symbol. The glint is moved by signal.js; the sheen crosses once, after the reveal. */
.glint { opacity: 0.55; }
.sheen { opacity: 0; transform: translateX(0) skewX(-18deg); }

/* Short landscape screens: tighten the column so nothing scrolls. */
@media (max-height: 30rem) {
  .brand { gap: 1rem; }
  .soon { inset-block-end: 0.6rem; font-size: 0.75rem; }
  .headline { margin-block-start: 1.25rem; font-size: clamp(1.4rem, 5.6vh, 2rem); }
  .support { margin-block-start: 0.5rem; font-size: 0.95rem; }
  .reveal { margin-block-end: 0; }
}

/* ── The reveal ─────────────────────────────────────────────────────────────
   Pure CSS, so the logo and the headline arrive even if the script never runs.
   Opacity only on the symbol: the canvas draws the same shape underneath it. */
@media (prefers-reduced-motion: no-preference) {
  .symbol-wrap::before { animation: line-in 1.6s 0.3s both cubic-bezier(0.22, 0.61, 0.36, 1); }
  .thread { animation: appear 0.9s 1s both ease-out; }
  .symbol { animation: appear 0.55s var(--t-symbol) both ease-out; }
  .wordmark { animation: focus-in 1s var(--t-wordmark) both cubic-bezier(0.22, 0.61, 0.36, 1); }
  .headline { animation: focus-in 1.2s var(--t-headline) both cubic-bezier(0.22, 0.61, 0.36, 1); }
  .support { animation: focus-in 1.2s var(--t-support) both cubic-bezier(0.22, 0.61, 0.36, 1); }
  .soon { animation: appear 1.6s var(--t-soon) both ease-out; }
  .sheen { animation: sheen 1.7s var(--t-sheen) both cubic-bezier(0.4, 0, 0.2, 1); }
}

@keyframes appear {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes sheen {
  0% { opacity: 0; transform: translateX(0) skewX(-18deg); }
  18%, 82% { opacity: 1; }
  100% { opacity: 0; transform: translateX(68px) skewX(-18deg); }
}
@keyframes focus-in {
  from { opacity: 0; filter: blur(10px); transform: translateY(0.35rem); }
  to { opacity: 1; filter: blur(0); transform: none; }
}
@keyframes line-in {
  from { opacity: 0; transform: translate(-50%, -50%) scaleX(0.2); }
  to { opacity: 1; transform: translate(-50%, -50%) scaleX(1); }
}

::selection { background: rgba(45, 212, 191, 0.3); color: #fff; }
