/* Lumi site: "Lumi is the light".
   The pages are dark and monochrome. Lumi is the only warm light source:
   it lights the type it floats past, and each page opens out of it.
   Link after tokens.css. Lumi is the one allowed exception to the
   no-bounce, no-loop, no-glow rules; everything else eases out and settles. */

@view-transition { navigation: auto; }

:root {
  color-scheme: dark;
  --bg: var(--ink-950);
  --bg-2: #111111;
  --bg-3: #181818;
  --fg: var(--ink-25);
  --mid: var(--ink-300);
  --dim: var(--ink-400);
  --line: rgba(255, 255, 255, 0.10);
  --line-2: rgba(255, 255, 255, 0.22);
  --gut: clamp(20px, 4vw, 56px);
  --max: 1360px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  /* Lumi's character palette (owner sign-off pending for tokens.css). */
  --lumi-body-hi: #fffefa;
  --lumi-body: #fff6e6;
  --lumi-body-edge: #f4d9aa;
  --lumi-glow: #ffbd5e;
  --lumi-ray: #fff0d0;
  --lumi-ink: #17120c;
  --lumi-catch: #ffffff;
  --lumi-blush: rgba(255, 122, 96, 0.55);
  --lumi-sweat: #d7ecff;

  /* Written every frame by light.js: where the light is and how strong. */
  --lx: 72vw; --ly: 42vh; --lr: 420px; --lg: 0.7;
  --vt-dir: 1;
}

*, *::before, *::after { box-sizing: border-box; }
html { background: var(--bg); -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100svh; background: var(--bg); color: var(--fg);
  font-family: var(--font-sans); font-size: 17px; line-height: 1.55;
  -webkit-font-smoothing: antialiased; overflow-x: clip;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--fg); outline-offset: 3px; border-radius: 4px; }
::selection { background: var(--lumi-body); color: var(--lumi-ink); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: fixed; left: 12px; top: -60px; z-index: 100; background: var(--fg); color: var(--bg); padding: 10px 14px; border-radius: 6px; text-decoration: none; }
.skip:focus { top: 12px; }

/* ---- The room: the warm pool around Lumi, and dust in the beam --------- */
body::before {
  content: ""; position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(circle calc(var(--lr) * 1.5) at var(--lx) var(--ly),
      rgb(255 189 94 / calc(var(--lg) * 0.17)), rgb(255 189 94 / calc(var(--lg) * 0.05)) 45%, rgb(255 189 94 / 0) 72%);
}
body::after { /* film grain keeps the dark from banding */
  content: ""; position: fixed; inset: -50%; z-index: 0; pointer-events: none; opacity: 0.05;
  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='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.dust { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
main, .bar, .foot { position: relative; z-index: 1; }

/* ---- The lamp: one Lumi that lives across every page -------------------- */
.lamp {
  position: fixed; left: 0; top: 0; z-index: 60; width: 160px; height: 160px;
  pointer-events: none; will-change: transform; contain: layout;
}
.lamp .lumi { width: 100%; height: 100%; overflow: visible; transform-origin: 50% 58%; transition: transform 520ms cubic-bezier(0.34, 1.56, 0.64, 1), opacity 160ms; }
.lamp.is-gone .lumi { transform: scale(0); opacity: 0; transition: transform 260ms cubic-bezier(0.5, 0, 0.75, 0), opacity 200ms 90ms; }
.lamp.is-gone .lumi * { pointer-events: none !important; }

/* Poof: a little cloud burst where Lumi leaves or arrives. */
.poof { position: fixed; z-index: 61; pointer-events: none; width: 0; height: 0; }
.poof--in { position: absolute; }
.poof i { position: absolute; left: 0; top: 0; width: var(--r); height: var(--r); margin: calc(var(--r) / -2) 0 0 calc(var(--r) / -2); border-radius: 50%;
  background: radial-gradient(circle at 40% 35%, #fffdf6, #ffeccc 55%, rgb(255 214 150 / 0.6)); box-shadow: 0 0 18px rgb(255 189 94 / 0.5);
  animation: puff 640ms cubic-bezier(0.22, 1, 0.36, 1) forwards; }
.poof b { position: absolute; left: 0; top: 0; width: 10px; height: 10px; margin: -5px 0 0 -5px; background: var(--lumi-ray);
  clip-path: polygon(50% 0, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0 50%, 38% 38%); animation: spark 720ms cubic-bezier(0.22, 1, 0.36, 1) forwards; }
@keyframes puff { 0% { transform: translate(0, 0) scale(0.2); opacity: 1; } 55% { opacity: 0.95; } 100% { transform: translate(var(--dx), var(--dy)) scale(1); opacity: 0; } }
@keyframes spark { 0% { transform: translate(0, 0) scale(0) rotate(0); opacity: 1; } 100% { transform: translate(var(--dx), var(--dy)) scale(1.2) rotate(120deg); opacity: 0; } }
.lamp .lumi-body, .lamp .lumi-rays { pointer-events: auto; cursor: pointer; }
.lumi-rays { filter: drop-shadow(0 0 6px rgb(255 189 94 / 0.7)); }
.lumi-prop-text { font-family: var(--font-sans); }
.lumi.is-pokeable { cursor: pointer; }

/* Pages open out of Lumi: the old page dims, the new one spreads from the light. */
/* Page to page: the content swipes sideways (left when you go forward through
   the nav, right when you go back), while the nav and Lumi stay exactly where
   they are. Lumi waves the pages along, then flies to its spot on the new page. */
.lamp { view-transition-name: lumi; }
.bar { view-transition-name: bar; }
::view-transition { background: var(--bg); }
::view-transition-old(root) { animation: vt-swipe-out 640ms cubic-bezier(0.65, 0, 0.35, 1) both; }
::view-transition-new(root) { animation: vt-swipe-in 640ms cubic-bezier(0.65, 0, 0.35, 1) both; }
::view-transition-group(lumi), ::view-transition-group(bar) { animation-duration: 640ms; }
::view-transition-old(bar), ::view-transition-new(bar) { animation-duration: 320ms; }
@keyframes vt-swipe-out { to { transform: translateX(calc(var(--vt-dir, 1) * -100%)); } }
@keyframes vt-swipe-in { from { transform: translateX(calc(var(--vt-dir, 1) * 100%)); } }

/* ---- Lit type: brightest nearest Lumi, readable grey everywhere else ---- */
.lit { color: #a3a3a3; padding: 0.06em 0 0.16em; margin: -0.06em 0 -0.16em; }
.js .lit {
  background-image: radial-gradient(circle var(--lr) at var(--mx, -2000px) var(--my, -2000px),
    #fffaf0 0, #ffe6bd 14%, #e9e4dc 34%, #a3a3a3 72%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
.lit--dim { color: #8f8f8f; }
.js .lit--dim { background-image: radial-gradient(circle var(--lr) at var(--mx, -2000px) var(--my, -2000px), #ffe9c4 0, #cfc8bd 26%, #8f8f8f 70%); }

/* ---- Bar ----------------------------------------------------------------- */
.bar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 40;
  display: flex; align-items: center; gap: 24px; padding: 18px var(--gut);
  background: none; isolation: isolate;
}
/* A deep fade behind the bar so content scrolling under it never collides with the nav. */
.bar::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; bottom: -120px; z-index: -1; pointer-events: none;
  background: linear-gradient(to bottom, rgb(10 10 10 / 0.68) 0%, rgb(10 10 10 / 0.6) 35%, rgb(10 10 10 / 0.36) 62%, rgb(10 10 10 / 0.14) 82%, rgb(10 10 10 / 0) 100%);
  -webkit-backdrop-filter: blur(7px); backdrop-filter: blur(7px);
  -webkit-mask-image: linear-gradient(to bottom, #000 30%, transparent); mask-image: linear-gradient(to bottom, #000 30%, transparent);
}
/* The Lumi lockup: Lumi's flat silhouette and "Lumi" in Sora. --h is the cap height.
   The footer credits Lumen with the official wordmark (cropped from the artwork, spokes removed). */
.brand { margin-right: auto; text-decoration: none; }
.brand, .lockup { --h: 19px; display: inline-flex; align-items: center; gap: calc(var(--h) * 0.34); }
.mark-name { font-family: var(--font-sans); font-weight: 600; font-size: calc(var(--h) * 1.36); line-height: 1; letter-spacing: -0.03em; color: var(--fg); }
.mark-lumi { flex: none; width: calc(var(--h) * 1.5); height: calc(var(--h) * 1.5); 
  --lumi-body-hi: #fff; --lumi-body: #fff; --lumi-body-edge: #fff; --lumi-glow: transparent; --lumi-ray: #fff; --lumi-ink: #0a0a0a; --lumi-catch: #0a0a0a; --lumi-blush: transparent; }
.mark-lumi .lumi { width: 100%; height: 100%; overflow: visible; }
.mark-lumi .lumi-rays { filter: none; }
.mark-lumen { flex: none; display: inline-block; width: calc(var(--h) * 339 / 93); height: var(--h); background: url("lumen-wordmark-white.png") no-repeat;
  background-size: calc(var(--h) * 512 / 93) auto; background-position: calc(var(--h) * -173 / 93) calc(var(--h) * -27 / 93); }
.foot-by { --h: 10px; display: inline-flex; align-items: center; flex-wrap: wrap; gap: 0 8px; }
.foot-by .mark-lumen { opacity: 0.62; }
.foot-dot { margin: 0 2px; }
.nav { display: flex; gap: 4px; }
.nav a { text-decoration: none; font-size: 14px; color: var(--mid); padding: 10px 14px; border-radius: 999px; transition: color 200ms, background-color 200ms; }
.nav a:hover { color: var(--fg); background: rgb(255 255 255 / 0.06); }
.nav a[aria-current="page"] { color: var(--fg); background: rgb(255 255 255 / 0.09); }
@media (max-width: 760px) {
  .bar { padding: 14px 16px; }
  .bar .btn { min-height: 40px; padding: 0 14px; font-size: 14px; }
  .nav {
    position: fixed; left: 50%; bottom: max(12px, env(safe-area-inset-bottom)); transform: translateX(-50%);
    background: rgb(24 24 24 / 0.86); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
    border: 1px solid var(--line); border-radius: 999px; padding: 4px; width: max-content; max-width: calc(100vw - 24px);
  }
  .nav a { padding: 10px 8px; font-size: 12.5px; white-space: nowrap; }
  .brand { --h: 16px; }
  .foot { padding-bottom: 96px; }
}

/* ---- Type and atoms ------------------------------------------------------ */
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--gut); }
.eyebrow { font-family: var(--font-sans); font-size: 14px; font-weight: 500; color: var(--dim); margin: 0; }
.mono { font-family: var(--font-sans); font-variant-numeric: tabular-nums; }
.d1 { font-size: clamp(42px, 6.6vw, 104px); line-height: 1.02; letter-spacing: -0.05em; font-weight: 600; margin: 0; }
.d2 { font-size: clamp(34px, 5vw, 80px); line-height: 1.04; letter-spacing: -0.045em; font-weight: 600; margin: 0; }
.d3 { font-size: clamp(28px, 3.4vw, 50px); line-height: 1.08; letter-spacing: -0.04em; font-weight: 600; margin: 0; }
.ln { display: block; }
.lede { font-size: clamp(17px, 1.5vw, 20px); line-height: 1.55; color: var(--mid); max-width: 34rem; margin: 0; }
.note { font-family: var(--font-sans); font-size: 13px; color: var(--dim); margin: 0; }
.note b { color: var(--mid); font-weight: 500; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 50px; padding: 0 24px;
  border-radius: 6px; font-weight: 500; font-size: 16px; text-decoration: none; cursor: pointer; border: 0;
  transition: transform 200ms var(--ease), background-color 200ms, color 200ms;
}
.btn:active { transform: scale(0.98); }
.btn--light { background: var(--fg); color: var(--bg); }
.btn--light:hover { background: #ffffff; }
.btn--ghost { background: transparent; color: var(--fg); box-shadow: inset 0 0 0 1px var(--line-2); }
.btn--ghost:hover { box-shadow: inset 0 0 0 1px var(--fg); }
.btn .arr { transition: transform 240ms var(--ease); }
.btn:hover .arr { transform: translateX(4px); }
.row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }

.seg { display: inline-flex; padding: 4px; gap: 2px; border-radius: 8px; background: var(--bg-2); box-shadow: inset 0 0 0 1px var(--line); }
.seg button { border: 0; background: none; color: var(--mid); padding: 8px 14px; min-height: 40px; border-radius: 6px; font-size: 14px; cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--fg); color: var(--bg); }

/* Spots are empty boxes in the layout where Lumi goes to sit. */
.spot { aspect-ratio: 1; width: 100%; pointer-events: none; }

/* Scroll reveals: ease out, no bounce. */
.js .rise { opacity: 0; transform: translateY(28px); transition: opacity 1s var(--ease), transform 1s var(--ease); transition-delay: calc(var(--i, 0) * 90ms); }
.js .rise.in { opacity: 1; transform: none; }

/* ---- Chat: shared by the home demo, Try it and A weekday ---------------- */
.chat { background: var(--bg-2); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; display: flex; flex-direction: column; box-shadow: 0 40px 120px -40px rgb(0 0 0 / 0.9); }
.chat-head { display: flex; align-items: center; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.chat-ava { width: 36px; height: 36px; border-radius: 50%; background: var(--bg-3); display: grid; place-items: center; overflow: hidden; }
.chat-ava .lumi { width: 46px; height: 46px; }
.chat-who { display: flex; flex-direction: column; line-height: 1.25; }
.chat-who b { font-weight: 600; font-size: 15px; }
.chat-who span { font-family: var(--font-sans); font-size: 13px; color: var(--dim); }
.chat-head .note { margin-left: auto; }
.chat-body { padding: 20px 16px; display: flex; flex-direction: column; gap: 10px; overflow-y: auto; }
.msg { max-width: 86%; padding: 11px 14px; border-radius: 14px; font-size: 15px; line-height: 1.45; animation: msg-in 520ms var(--ease) both; }
.msg p { margin: 0; }
.msg p + p, .msg p + .card, .msg .card + p { margin-top: 8px; }
.msg--me { align-self: flex-end; background: var(--fg); color: var(--bg); border-bottom-right-radius: 4px; }
.msg--lumi { align-self: flex-start; background: var(--bg-3); border: 1px solid var(--line); border-bottom-left-radius: 4px; }
@keyframes msg-in { from { opacity: 0; transform: translateY(10px) scale(0.98); } }
.card { display: flex; flex-direction: column; gap: 6px; padding: 12px; border-radius: 10px; background: var(--bg); border: 1px solid var(--line); }
.card .eyebrow { font-size: 13px; }
.card-t { font-weight: 600; }
.card-s { font-size: 13px; color: var(--mid); }
.card ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.card li { display: flex; justify-content: space-between; gap: 14px; font-size: 14px; }
.card li span:last-child { font-family: var(--font-sans); font-size: 12.5px; color: var(--mid); white-space: nowrap; }
.kv { display: grid; grid-template-columns: 76px minmax(0, 1fr); gap: 4px 10px; font-size: 13.5px; }
.kv dt { font-family: var(--font-sans); font-size: 13px; color: var(--dim); padding-top: 2px; }
.kv dd { margin: 0; overflow-wrap: anywhere; }
.btnrow { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.ib { min-height: 40px; padding: 0 14px; border-radius: 6px; border: 0; background: transparent; box-shadow: inset 0 0 0 1px var(--line-2); color: var(--fg); font-size: 14px; font-weight: 500; cursor: pointer; transition: background-color 200ms, box-shadow 200ms; }
.ib:hover { box-shadow: inset 0 0 0 1px var(--fg); }
.ib--yes { background: var(--fg); color: var(--bg); box-shadow: none; }
.ib--yes:hover { background: #fff; }
.record { font-family: var(--font-sans); font-size: 13px; color: var(--mid); margin: 6px 0 0; }
.record b { color: var(--fg); font-weight: 500; }
.typing { display: inline-flex; gap: 5px; padding: 14px 16px; }
.typing span { width: 6px; height: 6px; border-radius: 50%; background: var(--mid); animation: dot 1s infinite ease-in-out; }
.typing span:nth-child(2) { animation-delay: 0.15s; } .typing span:nth-child(3) { animation-delay: 0.3s; }
@keyframes dot { 50% { opacity: 0.25; transform: translateY(-3px); } }
.voice { display: flex; align-items: center; gap: 10px; }
.voice .play { width: 0; height: 0; border-left: 9px solid currentColor; border-top: 6px solid transparent; border-bottom: 6px solid transparent; }
.wave { display: flex; align-items: center; gap: 2px; height: 22px; }
.wave i { width: 3px; border-radius: 2px; background: currentColor; opacity: 0.8; }
.transcript { font-size: 13px; opacity: 0.7; }

/* ---- Big closing call, on every page ------------------------------------ */
.start { padding-top: clamp(120px, 18vh, 200px); padding-bottom: clamp(80px, 12vh, 140px); }
.start-in { display: grid; grid-template-columns: minmax(0, 1fr) minmax(140px, 280px); gap: 40px; align-items: center; }
.start .lede { margin-top: 24px; }
.start .row { margin-top: 36px; }
@media (max-width: 760px) { .start-in { grid-template-columns: 1fr; } .start-in .spot { max-width: 150px; order: -1; } }

.foot { border-top: 1px solid var(--line); padding: 32px 0 40px; }
.foot-in { display: flex; flex-wrap: wrap; gap: 16px 28px; align-items: center; font-size: 14px; color: var(--dim); }
.foot-in a { text-decoration: none; color: var(--mid); }
.foot-in a:hover { color: var(--fg); }
.foot-in .grow { margin-right: auto; }

@media (prefers-reduced-motion: reduce) {
  .poof { display: none; }
  .lamp .lumi, .lamp.is-gone .lumi { transition: opacity 200ms; transform: none; }
  ::view-transition-old(root), ::view-transition-new(root), ::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) { animation: none; }
  .js .rise { opacity: 1; transform: none; transition: none; }
  .msg { animation: none; }
  .typing span { animation: none; }
}
.passport { width: 160px; height: 104px; border-radius: 8px; background: linear-gradient(135deg, #2a2a2a, #1a1a1a); display: grid; grid-template-columns: 44px 1fr; gap: 6px 10px; padding: 12px; filter: blur(1.5px); }
.passport i { display: block; background: #3a3a3a; border-radius: 3px; height: 8px; }
.passport i:first-child { grid-row: span 4; height: auto; background: #444; }
.file { display: flex; align-items: center; gap: 12px; font-size: 14px; }
.cmd-i { font-variant-numeric: tabular-nums; padding: 1px 7px; border-radius: 5px; background: rgb(255 255 255 / 0.08); white-space: nowrap; font-weight: 500; }
