/* ==========================================================================
   Piixel: coming soon page
   Colours: Blue #3e50a1 | Light blue #b3bbdc | Black #1e1e1e
   ========================================================================== */

:root {
  --blue: #3e50a1;
  --blue-deep: #2b3a7d;
  --light-blue: #b3bbdc;
  --dark: #1e1e1e;
  --white: #ffffff;

  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  /* Screen height (svh = stable height on phones, ignores the address bar) */
  --screen-h: 100vh;

  /* Header height (changes per screen size, see media queries below) */
  --header-h: 109px;
  --logo-h: 56px;

  /* Banner = whatever is left of the screen under the header, so
     header + banner together fit exactly on one screen. */
  --banner-h: max(360px, calc(var(--screen-h) - var(--header-h)));

  /* The card is always at least a full screen tall so it covers the banner */
  --card-h: max(560px, var(--screen-h));
}

@supports (height: 100svh) {
  :root {
    --screen-h: 100svh;
  }
}

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

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--dark);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img {
  display: block;
  max-width: 100%;
}

/* --------------------------------------------------------------------------
   Header (logo centred)
   -------------------------------------------------------------------------- */
.site-header {
  display: flex;
  justify-content: center;
  align-items: center;
  height: var(--header-h);
  padding: 0 24px;
  background: var(--white);
  border-bottom: 1px solid #eceef8;
}

.logo-link {
  display: inline-flex;
}

.logo {
  height: var(--logo-h);
  width: auto;
}

/* --------------------------------------------------------------------------
   Stage: pinned banner + sliding card
   -------------------------------------------------------------------------- */
.stage {
  position: relative;
}

/* Banner: full width, no padding, no rounded corners */
.banner {
  position: sticky;
  top: 0;
  z-index: 1;
  height: var(--banner-h);
  overflow: hidden;
  background: #dfe2f4; /* matches the soft edge of the banner image */
  container-type: size;
  container-name: banner;
}

.banner-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transform: scale(var(--banner-scale, 1));
  transform-origin: center center;
  will-change: transform;
}

.banner-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 25% 50%; /* keeps the logo in the image visible on the left */
}

/* Where the image is cropped depends on the banner's own shape, so the big logo
   inside the picture is never cut in half:
   - tall banner (phones, tablets upright): show the laptop side
   - nearly square banner: show the logo side
   - wide banner: nearly the whole picture is visible */
@container banner (max-aspect-ratio: 1/1) {
  .banner-img { object-position: 80% 50%; }
}
@container banner (min-aspect-ratio: 1/1) and (max-aspect-ratio: 3/2) {
  .banner-img { object-position: 0% 50%; }
}

.banner-fade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(30, 30, 30, 0) 65%, rgba(30, 30, 30, 0.28) 100%);
}

.banner-shade {
  position: absolute;
  inset: 0;
  background: var(--dark);
  opacity: var(--banner-shade, 0);
  pointer-events: none;
}

.scroll-hint {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 28px;
  display: flex;
  justify-content: center;
  opacity: var(--hint-opacity, 1);
  pointer-events: none;
}

.scroll-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.85);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  color: var(--dark);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.02em;
  animation: bob 1.8s ease-in-out infinite;
}

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

/* --------------------------------------------------------------------------
   Card (slides over the banner)
   -------------------------------------------------------------------------- */
.card {
  position: relative;
  z-index: 2;
  min-height: var(--card-h);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 96px 24px 120px;
  text-align: center;
  overflow: hidden;
  border-radius: 40px 40px 0 0;
  background: linear-gradient(160deg, var(--blue) 0%, var(--blue) 40%, var(--blue-deep) 100%);
  box-shadow: 0 -30px 80px rgba(30, 30, 30, 0.28);
}

/* Pixel dot pattern (a nod to the name) */
.card-dots {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(179, 187, 220, 0.25) 1.2px, transparent 1.6px);
  background-size: 28px 28px;
  -webkit-mask-image: linear-gradient(180deg, #000 0%, transparent 80%);
  mask-image: linear-gradient(180deg, #000 0%, transparent 80%);
  pointer-events: none;
}

.card-glow {
  position: absolute;
  top: -180px;
  right: -140px;
  width: 520px;
  height: 520px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(179, 187, 220, 0.35) 0%, transparent 65%);
  pointer-events: none;
}

.card-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 28px;
  width: 100%;
  max-width: 860px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid rgba(179, 187, 220, 0.35);
  background: rgba(255, 255, 255, 0.08);
  color: var(--light-blue);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--light-blue);
  animation: pulse 1.8s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.35; transform: scale(1.3); }
}

.heading {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  column-gap: 0.28em;
  row-gap: 0.04em;
  margin: 0;
  /* grows with the screen width, but never taller than the screen allows */
  font-size: clamp(34px, min(8.5vw, 13vh), 72px);
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: -0.04em;
  color: var(--white);
}

.word {
  display: inline-block;
  will-change: transform, opacity, filter;
}

.word.accent {
  color: var(--light-blue);
}

.subtext {
  max-width: 560px;
  margin: 0;
  text-wrap: balance;
  font-size: 18px;
  line-height: 1.6;
  letter-spacing: 0.005em;
  color: var(--light-blue);
}

.card-footer {
  position: absolute;
  left: 24px;
  right: 24px;
  bottom: 28px;
  padding-top: 20px;
  border-top: 1px solid rgba(179, 187, 220, 0.2);
  font-size: 13px;
  letter-spacing: 0.02em;
  color: rgba(179, 187, 220, 0.7);
}

.card-footer p {
  margin: 0;
}

/* ==========================================================================
   RESPONSIVE: every screen size
   ========================================================================== */

/* Large and ultra-wide screens (big monitors, TVs) */
@media (min-width: 1800px) {
  :root { --header-h: 124px; --logo-h: 64px; }
  .heading { font-size: clamp(34px, min(8.5vw, 13vh), 96px); }
  .subtext { font-size: 21px; max-width: 660px; }
  .eyebrow { font-size: 13px; padding: 10px 18px; }
  .card-content { max-width: 1100px; }
}

/* Laptops and small desktops */
@media (max-width: 1280px) {
  :root { --header-h: 100px; --logo-h: 52px; }
}

/* Tablets */
@media (max-width: 1024px) {
  :root { --header-h: 92px; --logo-h: 48px; }
  .card { padding: 88px 28px 120px; }
}

/* Portrait screens (tablets and phones held upright):
   a tall screen cannot show the whole wide banner, so the banner
   is a shorter, wider band and the image is centred on the laptop. */
@media (max-aspect-ratio: 1/1) {
  :root {
    --banner-h: clamp(360px, 112vw, calc(var(--screen-h) - var(--header-h)));
  }
}

/* Phones */
@media (max-width: 600px) {
  :root { --header-h: 76px; --logo-h: 40px; }
  .site-header { padding: 0 16px; }
  .scroll-hint { bottom: 20px; }
  .card { border-radius: 28px 28px 0 0; padding: 80px 20px 120px; }
  .card-content { gap: 24px; }
  .subtext { font-size: 16px; }
  .card-footer { left: 20px; right: 20px; }
}

/* Small phones */
@media (max-width: 360px) {
  :root { --header-h: 68px; --logo-h: 34px; }
  .eyebrow { font-size: 11px; padding: 7px 13px; }
  .subtext { font-size: 15px; }
}

/* Phones held sideways / very short screens */
@media (max-height: 520px) and (orientation: landscape) {
  :root {
    --header-h: 60px;
    --logo-h: 32px;
    --banner-h: calc(var(--screen-h) - var(--header-h));
  }
  .site-header { padding: 0 16px; }
  .scroll-hint { bottom: 12px; }
  .scroll-pill { padding: 7px 13px; font-size: 12px; }
  .card { min-height: var(--screen-h); padding: 56px 24px 84px; }
  .card-content { gap: 16px; }
  .subtext { font-size: 15px; }
  .card-footer { bottom: 14px; padding-top: 12px; }
}

/* --------------------------------------------------------------------------
   Respect "reduce motion": no animation, everything simply visible
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .scroll-pill,
  .pulse-dot {
    animation: none;
  }
}
