/* ============================================================
   K4 Group — Immersive Portal
   Dark, cinematic shell. Strictly monochrome UI; photography
   carries all the colour. Built on the K4 design tokens.
   ============================================================ */

:root {
  --p-black:   #050608;
  --p-ink:     #0A0C11;
  --p-slate:   #2F3543;
  --p-line:    rgba(255,255,255,0.14);
  --p-line-2:  rgba(255,255,255,0.28);
  --p-dim:     rgba(255,255,255,0.55);
  --p-dim-2:   rgba(255,255,255,0.40);
  --p-ease:    cubic-bezier(0.22, 0.61, 0.36, 1);   /* @kind other */
  --p-ease-io: cubic-bezier(0.65, 0, 0.35, 1);       /* @kind other */
  --p-cine:    cubic-bezier(0.76, 0, 0.24, 1);       /* @kind other */
}

* { box-sizing: border-box; }

html, body {
  margin: 0; padding: 0;
  background: var(--p-black);
  color: #fff;
  font-family: var(--k4-font-body, 'Montserrat', system-ui, sans-serif);
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}

#root { width: 100vw; height: 100vh; }

/* ---- shared type helpers ---- */
.p-eyebrow {
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--p-dim);
}
.p-mono {
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
}

/* ---- film grain overlay ---- */
.p-grain {
  position: fixed; inset: 0; pointer-events: none; z-index: 60;
  opacity: 0.05; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---- persistent brand chrome ---- */
.p-brandbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 26px 34px;
  pointer-events: none;
}
.p-brandbar > * { pointer-events: auto; }
.p-logo { height: 30px; width: auto; display: block; opacity: 0.96; }
.p-brand-right {
  text-align: right;
  display: flex; align-items: center; gap: 18px;
}
.p-tag {
  font-weight: 600; font-size: 11px; letter-spacing: 0.34em;
  text-transform: uppercase; color: rgba(255,255,255,0.7);
}

/* ---- the "fly into world" overlay ---- */
.p-warp {
  position: fixed; inset: 0; z-index: 90;
  pointer-events: none; opacity: 0;
}
.p-warp.is-on { pointer-events: all; }
.p-warp-img {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  transform: scale(1);
}
.p-warp-veil { position: absolute; inset: 0; background: #fff; opacity: 0; }
.p-warp-label {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 16px; text-align: center;
}
.p-warp-name {
  font-weight: 800; letter-spacing: -0.02em;
  font-size: clamp(40px, 8vw, 120px); line-height: 1; color: #fff;
}
.p-warp-sub {
  font-weight: 600; font-size: 12px; letter-spacing: 0.34em;
  text-transform: uppercase; color: rgba(255,255,255,0.85);
  display: inline-flex; align-items: center; gap: 10px;
}

/* dot spinner */
.p-load { display: inline-flex; gap: 6px; }
.p-load span {
  width: 5px; height: 5px; border-radius: 999px; background: #fff;
  animation: p-bounce 1s var(--p-ease-io) infinite;
}
.p-load span:nth-child(2) { animation-delay: 0.15s; }
.p-load span:nth-child(3) { animation-delay: 0.3s; }
@keyframes p-bounce { 0%,100%{ opacity: 0.25; transform: translateY(0);} 50%{ opacity: 1; transform: translateY(-4px);} }

/* ============================================================
   DIRECTION C — MONOLITH responsive content padding
   ============================================================ */
.mono-content {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: clamp(18px, 2.8vw, 48px);
  display: flex; flex-direction: column;
}
@media (max-width: 600px) {
  /* keep bottom-row names clear of the centred switcher pill */
  .mono-content--bottom { padding-bottom: 92px; }
}
@media (max-width: 380px) {
  .mono-content--bottom { padding-bottom: 84px; }
}

/* respect reduced motion: kill long ambient loops */
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.001ms !important; transition-duration: 80ms !important; }
}
