/* ==========================================================
   InnoxSofty — light-first design system.
   Monochrome shell; colour comes from whichever app is on screen.
   ========================================================== */

:root {
  --bg: #f5f6f8;
  --card: #ffffff;
  --card-2: #fafbfc;
  --ink: #0c0e13;
  --ink-2: #565d6e;
  --ink-3: #8c92a2;
  --line: #e4e7ee;
  --line-2: #cfd4df;
  --shadow-s: 0 1px 2px rgba(12, 14, 25, .05);
  --shadow-l: 0 2px 6px rgba(12, 14, 25, .04), 0 22px 48px -24px rgba(12, 14, 35, .28);
  --screen: #f1f2f6;
  --accent: #0c0e13;
  /* release-state colours. Semantic, so they stay put while --accent
     changes from slide to slide. */
  --ok: #18a06a;
  --soon: #b0790f;
  /* strength of the drifting app background, per colour scheme */
  --aura: 22;
  /* text that sits on top of --accent; app.js recomputes it per slide */
  --on-accent: #ffffff;

  --display: "Segoe UI Variable Display", "SF Pro Display", -apple-system,
             "Helvetica Neue", Helvetica, Arial, sans-serif;
  --body: "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, Arial, sans-serif;
  --mono: "Cascadia Mono", "Cascadia Code", Consolas, "SF Mono", ui-monospace, monospace;

  --rail: 84px;
  --ease: cubic-bezier(.16, 1, .3, 1);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0b0c10;
    --card: #14161d;
    --card-2: #181a22;
    --ink: #f3f4f7;
    --ink-2: #a1a7b6;
    --ink-3: #747b8c;
    --line: #252832;
    --line-2: #333845;
    --shadow-s: 0 1px 2px rgba(0, 0, 0, .5);
    --shadow-l: 0 2px 6px rgba(0, 0, 0, .5), 0 22px 48px -24px rgba(0, 0, 0, .9);
    --screen: #0e1015;
    --accent: #f3f4f7;
    --ok: #35c48d;
    --soon: #e0a93c;
    --aura: 38;
  }
}

:root[data-theme="dark"] {
  --bg: #0b0c10;
  --card: #14161d;
  --card-2: #181a22;
  --ink: #f3f4f7;
  --ink-2: #a1a7b6;
  --ink-3: #747b8c;
  --line: #252832;
  --line-2: #333845;
  --shadow-s: 0 1px 2px rgba(0, 0, 0, .5);
  --shadow-l: 0 2px 6px rgba(0, 0, 0, .5), 0 22px 48px -24px rgba(0, 0, 0, .9);
  --screen: #0e1015;
  --accent: #f3f4f7;
  --ok: #35c48d;
  --soon: #e0a93c;
  --aura: 38;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--body);
  font-size: 1rem;
  line-height: 1.6;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--display);
  font-weight: 700;
  line-height: 1.02;
  letter-spacing: -.035em;
  text-wrap: balance;
  margin: 0;
}

p { margin: 0; }
a { color: inherit; }
img { max-width: 100%; display: block; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 3px;
}

.mono {
  font-family: var(--mono);
  font-size: .6875rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ink-3);
}

/* ---------- the sliding deck ---------- */
.deck {
  display: flex;
  height: 100dvh;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  overscroll-behavior-x: contain;
}

.deck::-webkit-scrollbar { display: none; }

.panel {
  /* every slide states its own accent, so a slide without one in content.js
     falls back to ink instead of inheriting the previous slide's colour */
  --accent: var(--ink);
  flex: 0 0 100%;
  grid-template-columns: minmax(0, 1fr);
  width: 100%;
  height: 100%;
  scroll-snap-align: start;
  overflow-y: auto;
  display: grid;
  align-content: center;
  padding: 5.5rem clamp(1.25rem, 4vw, 3.5rem) 6.5rem;
  padding-left: calc(var(--rail) + clamp(1.25rem, 3vw, 2.5rem));
}

.inner {
  width: 100%;
  min-width: 0;
  max-width: 1240px;
  margin-inline: auto;
}

/* children stagger in when their slide lands */
.panel .st {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .75s var(--ease), transform .75s var(--ease);
}

.panel.live .st {
  opacity: 1;
  transform: none;
  transition-delay: var(--d, 0s);
}

/* ---------- left rail ---------- */
.rail {
  position: fixed;
  inset: 0 auto 0 0;
  width: var(--rail);
  z-index: 30;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem 0;
  border-right: 1px solid var(--line);
  background: var(--card);
}

/* the logo: inline SVG in index.html, tinted by whichever app is on screen */
.mark {
  width: 34px;
  height: 34px;
  color: var(--accent);
  transition: color .6s var(--ease);
}

.mark svg { width: 100%; height: 100%; display: block; }

.rail-word {
  writing-mode: vertical-rl;
  font-family: var(--mono);
  font-size: .6875rem;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.rail-count {
  font-family: var(--mono);
  font-size: .75rem;
  letter-spacing: .1em;
  color: var(--ink-3);
  font-variant-numeric: tabular-nums;
}

.rail-count b { color: var(--ink); }

/* ---------- top bar ---------- */
.topbar {
  position: fixed;
  top: 0;
  left: var(--rail);
  right: 0;
  z-index: 25;
  display: flex;
  align-items: center;
  gap: 1.25rem;
  min-height: 64px;
  padding-inline: clamp(1.25rem, 4vw, 3.5rem);
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(14px);
}

.brand {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.0625rem;
  letter-spacing: -.03em;
  text-decoration: none;
  margin-right: auto;
  display: flex;
  align-items: center;
  gap: .5rem;
}

.brand .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  transition: background .6s var(--ease);
}

.tabs { display: flex; gap: .25rem; }

.tab {
  appearance: none;
  border: 0;
  background: transparent;
  font: inherit;
  font-size: .8125rem;
  color: var(--ink-2);
  padding: .45rem .75rem;
  border-radius: 7px;
  cursor: pointer;
  white-space: nowrap;
  transition: background .25s, color .25s;
}

.tab:hover { background: var(--card); color: var(--ink); }
.tab[aria-current="true"] { background: var(--ink); color: var(--bg); }

/* ---------- pager ---------- */
.pager {
  position: fixed;
  bottom: clamp(1rem, 3vw, 1.75rem);
  left: 50%;
  transform: translateX(-50%);
  z-index: 30;
  display: flex;
  align-items: center;
  gap: .25rem;
  padding: .375rem;
  border-radius: 100px;
  border: 1px solid var(--line);
  background: var(--card);
  box-shadow: var(--shadow-l);
}

.arrow {
  appearance: none;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--ink);
  font-size: 1rem;
  cursor: pointer;
  transition: background .25s, opacity .25s;
}

.arrow:hover { background: var(--card-2); }
.arrow:disabled { opacity: .25; cursor: default; }

.dots { display: flex; gap: .3rem; padding-inline: .4rem; }

.dots button {
  appearance: none;
  border: 0;
  width: 7px;
  height: 7px;
  padding: 0;
  border-radius: 50%;
  background: var(--line-2);
  cursor: pointer;
  transition: width .45s var(--ease), background .35s;
}

.dots button[aria-current="true"] {
  width: 22px;
  border-radius: 4px;
  background: var(--accent);
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  padding: .8rem 1.25rem;
  border-radius: 10px;
  border: 1px solid var(--accent);
  background: var(--accent);
  color: var(--on-accent);
  font: inherit;
  font-size: .875rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  transform: translate(var(--mag-x, 0px), calc(var(--mag-y, 0px) + var(--lift, 0px)));
  transition: transform .25s var(--ease), box-shadow .25s var(--ease);
}

.btn:hover {
  --lift: -2px;
  box-shadow: 0 10px 24px -12px color-mix(in srgb, var(--accent) 70%, transparent);
}

.btn .arr { transition: transform .3s var(--ease); }
.btn:hover .arr { transform: translateX(3px); }

.btn-line {
  background: var(--card);
  color: var(--ink);
  border-color: var(--line-2);
}

.btn-line:hover {
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: var(--shadow-s);
}

/* ---------- intro slide ---------- */
.intro { display: grid; gap: clamp(2rem, 4vw, 3rem); }
.intro-head { display: grid; gap: 1.25rem; justify-items: start; }

.intro h1 {
  font-size: clamp(2.5rem, 7.2vw, 5.75rem);
  max-width: min(18ch, 100%);
}

/* class, not a bare `span`: the headline's words get wrapped in spans of
   their own for the hover effect, and must not inherit the muted colour */
.intro h1 .muted { color: var(--ink-3); }

.intro .lede {
  font-size: clamp(1.0625rem, 1.5vw, 1.25rem);
  color: var(--ink-2);
  max-width: min(48ch, 100%);
}

.chips {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr));
  gap: .75rem;
}

.chip {
  display: flex;
  align-items: center;
  gap: .875rem;
  padding: 1rem 1.125rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--card);
  text-align: left;
  font: inherit;
  color: inherit;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transform: translate(var(--mag-x, 0px), calc(var(--mag-y, 0px) + var(--lift, 0px)));
  transition: transform .3s var(--ease), border-color .3s, box-shadow .3s;
}

.chip:hover {
  --lift: -3px;
  border-color: var(--ch);
  box-shadow: var(--shadow-l);
}

.chip-sq {
  width: 38px;
  height: 38px;
  flex: none;
  border-radius: 11px;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: color-mix(in srgb, var(--ch) 14%, transparent);
  color: var(--ch);
  font-family: var(--display);
  font-weight: 700;
  font-size: 1rem;
}

.chip-sq img { width: 100%; height: 100%; object-fit: cover; }

.chip-txt {
  display: flex;
  flex-direction: column;
  line-height: 1.3;
  min-width: 0;
}

.chip-txt b { font-size: .9375rem; letter-spacing: -.01em; }
.chip-txt span { font-size: .75rem; color: var(--ink-3); }
.chip .go { margin-left: auto; color: var(--ink-3); font-size: .875rem; }

/* ---------- app slide ---------- */
.app {
  display: grid;
  grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}

.app-copy {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1.125rem;
  align-items: start;
}

.app-badge {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  font-family: var(--mono);
  font-size: .625rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--state, var(--accent));
  background: color-mix(in srgb, var(--state, var(--accent)) 11%, transparent);
  border: 1px solid transparent;
  border-radius: 100px;
  padding: .35rem .7rem;
}

.app-badge[data-status="live"] { --state: var(--ok); }

/* unreleased reads as outlined-and-pending rather than filled-and-done */
.app-badge[data-status="soon"] {
  --state: var(--soon);
  background: transparent;
  border-color: color-mix(in srgb, var(--soon) 40%, transparent);
  border-style: dashed;
}

.app-badge::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--state, var(--accent));
}

.app-badge[data-status="soon"]::before {
  animation: breathe 2.6s ease-in-out infinite;
}

@keyframes breathe {
  50% { opacity: .3; transform: scale(.72); }
}

/* "Soon" flag beside the app name on the overview card */
.chip-flag {
  font-family: var(--mono);
  font-style: normal;
  font-size: .5625rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  vertical-align: 1.5px;
  margin-left: .35rem;
  padding: .1rem .35rem;
  border-radius: 4px;
  color: var(--soon);
  background: color-mix(in srgb, var(--soon) 14%, transparent);
}

/* a link that has nowhere to go yet */
.btn.is-disabled {
  cursor: default;
  color: var(--ink-3);
  border-style: dashed;
  border-color: var(--line-2);
  background: transparent;
  box-shadow: none;
  transform: none;
}

.app-id { display: flex; align-items: center; gap: 1rem; }

.app-icon {
  position: relative;
  width: 62px;
  height: 62px;
  flex: none;
  border-radius: 17px;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: var(--accent);
  color: var(--on-accent);
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.75rem;
  box-shadow: 0 12px 28px -14px color-mix(in srgb, var(--accent) 85%, transparent);
}

.app-icon img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.app-copy h2 { font-size: clamp(2.125rem, 4.6vw, 3.5rem); }
.app-tag { color: var(--accent); font-weight: 600; font-size: .9375rem; }
.app-copy p.desc { color: var(--ink-2); max-width: min(46ch, 100%); }

.feats {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: .5rem;
  font-size: .9375rem;
}

.feats li { display: flex; gap: .625rem; align-items: baseline; }

.feats li::before {
  content: "";
  width: 5px;
  height: 5px;
  flex: none;
  border-radius: 50%;
  background: var(--accent);
  transform: translateY(-3px);
}

.spec {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(108px, 1fr));
  gap: .875rem 1.25rem;
  width: 100%;
  margin: 0;
  padding: 1rem 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.spec div { display: flex; flex-direction: column; gap: .15rem; }

.spec dt {
  font-family: var(--mono);
  font-size: .625rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.spec dd { margin: 0; font-size: .875rem; font-weight: 600; }

.app-actions { display: flex; flex-wrap: wrap; gap: .625rem; }

/* ---------- screenshot stage ---------- */
.stage {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  /* room for the captions, which hang below each frame */
  gap: 2.75rem;
  padding: 1rem .25rem;
}

.shots {
  display: flex;
  gap: clamp(.5rem, 1.6vw, 1.25rem);
  justify-content: center;
  align-items: flex-end;
}

.stage::before {
  content: "";
  position: absolute;
  inset: 12% 2% 10%;
  border-radius: 28px;
  background: radial-gradient(ellipse at 50% 60%,
    color-mix(in srgb, var(--accent) 16%, transparent), transparent 70%);
  filter: blur(14px);
  pointer-events: none;
}

/* one frame = one Play Store screenshot */
.phone {
  appearance: none;
  font: inherit;
  color: inherit;
  position: relative;
  flex: none;
  /* sized by height so three frames always fit the panel, whatever its width */
  height: clamp(200px, 40dvh, 330px);
  width: auto;
  aspect-ratio: 9 / 16;
  border-radius: 26px;
  padding: 6px;
  background: var(--card);
  border: 1px solid var(--line-2);
  box-shadow: var(--shadow-l);
  cursor: zoom-in;
  transform:
    translateY(var(--lift, 0px))
    rotate(var(--rot, 0deg))
    perspective(900px)
    rotateX(var(--tilt-x, 0deg))
    rotateY(var(--tilt-y, 0deg));
  transition: transform .55s var(--ease);
}

.phone:nth-child(odd) { --rot: -2deg; --lift: 14px; }
.phone:nth-child(even) { --rot: 0deg; --lift: 0px; }
.phone:nth-child(3) { --rot: 2deg; }
.phone:hover, .phone:focus-visible { --lift: -6px; --rot: 0deg; z-index: 4; }

.phone::after {
  content: "";
  position: absolute;
  top: 13px;
  left: 50%;
  transform: translateX(-50%);
  width: 34px;
  height: 4px;
  border-radius: 3px;
  background: var(--line-2);
  z-index: 3;
}

.screen {
  display: block;
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 21px;
  overflow: hidden;
  background: var(--screen);
}

.screen img { width: 100%; height: 100%; object-fit: fill; }

/* shown when the image file isn't there yet */
.phone.no-shot .screen {
  display: grid;
  place-content: center;
  gap: .35rem;
  padding: .75rem;
  text-align: center;
  border: 1px dashed var(--line-2);
  background: color-mix(in srgb, var(--accent) 5%, var(--screen));
}

.phone.no-shot .screen::before {
  content: attr(data-ph);
  font-family: var(--mono);
  font-size: .5rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-3);
  line-height: 1.5;
}

.phone.no-shot .screen::after {
  content: attr(data-file);
  font-family: var(--mono);
  font-size: .4375rem;
  color: var(--ink-3);
  opacity: .7;
  word-break: break-all;
}

.shot-cap {
  position: absolute;
  bottom: -1.35rem;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--mono);
  font-size: .5625rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-3);
  white-space: nowrap;
}

.stage-hint {
  font-family: var(--mono);
  font-size: .5625rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-3);
  text-align: center;
  margin-top: .25rem;
}

/* ---------- about slide ---------- */
.closing { display: grid; gap: clamp(1.75rem, 4vw, 2.75rem); max-width: 68rem; }
.closing-head { display: grid; gap: 1.125rem; justify-items: start; }
.closing h2 { font-size: clamp(2.25rem, 6vw, 4.5rem); max-width: min(22ch, 100%); }
.closing p { color: var(--ink-2); max-width: min(52ch, 100%); }

.links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
  gap: .75rem;
}

.link-card {
  display: flex;
  flex-direction: column;
  gap: .35rem;
  padding: 1.125rem 1.25rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--card);
  text-decoration: none;
  position: relative;
  overflow: hidden;
  transform: translate(var(--mag-x, 0px), calc(var(--mag-y, 0px) + var(--lift, 0px)));
  transition: transform .3s var(--ease), border-color .3s, box-shadow .3s;
}

.link-card:hover {
  --lift: -3px;
  border-color: var(--ink);
  box-shadow: var(--shadow-l);
}

.link-card b { font-size: .9375rem; letter-spacing: -.01em; }

.link-card span {
  font-family: var(--mono);
  font-size: .6875rem;
  letter-spacing: .08em;
  color: var(--ink-3);
}

.legal { font-size: .8125rem; color: var(--ink-3); }

/* ---------- scroll hint ---------- */
.hint {
  position: fixed;
  right: clamp(1rem, 3vw, 2rem);
  bottom: clamp(1.25rem, 3vw, 2rem);
  z-index: 30;
  font-family: var(--mono);
  font-size: .625rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-3);
  pointer-events: none;
  transition: opacity .6s;
}

/* ---------- lightbox ---------- */
.lb {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(.5rem, 3vw, 2rem);
  padding: clamp(1rem, 4vw, 3rem);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(18px);
  animation: lbIn .3s var(--ease);
}

.lb[hidden] { display: none; }

@keyframes lbIn { from { opacity: 0; } }

.lb-figure {
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .875rem;
  min-width: 0;
}

.lb-figure img {
  max-height: 78dvh;
  width: auto;
  border-radius: 20px;
  border: 1px solid var(--line-2);
  box-shadow: var(--shadow-l);
  background: var(--screen);
}

.lb-figure figcaption {
  font-family: var(--mono);
  font-size: .6875rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-2);
}

.lb-btn {
  appearance: none;
  width: 44px;
  height: 44px;
  flex: none;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--card);
  color: var(--ink);
  font-size: 1.125rem;
  cursor: pointer;
  box-shadow: var(--shadow-s);
  transition: transform .25s var(--ease), border-color .25s;
}

.lb-btn:hover { transform: scale(1.08); border-color: var(--ink); }

.lb-close {
  position: absolute;
  top: clamp(1rem, 3vw, 2rem);
  right: clamp(1rem, 3vw, 2rem);
}

/* ==========================================================
   app icons
   The accent plate is the fallback look, behind a monogram. Once a real
   logo loads, app.js adds .has-icon and the plate backs off to a tint so
   the artwork — including transparent PNGs — reads on its own.
   ========================================================== */

[data-monogram].has-icon {
  /* --ch is the app's colour on an overview chip; --accent on an app slide */
  background: color-mix(in srgb, var(--ch, var(--accent)) 10%, transparent);
  color: transparent;            /* retires the monogram letter underneath */
  box-shadow: none;
}

[data-monogram].has-icon img {
  object-fit: contain;           /* never crop a logo */
}

.app-icon.has-icon img { padding: 6px; }

/* ==========================================================
   pointer flourishes
   All of these are driven by app.js, which only switches them on for a
   fine pointer (mouse/trackpad) when reduced motion is not requested.
   ========================================================== */

/* trailing accent ring — rides behind the real cursor, never replaces it */
.ring {
  position: fixed;
  top: 0;
  left: 0;
  width: 26px;
  height: 26px;
  margin: -13px 0 0 -13px;
  border: 1.5px solid color-mix(in srgb, var(--accent) 50%, transparent);
  border-radius: 50%;
  pointer-events: none;
  z-index: 70;
  opacity: 0;
  will-change: transform;
  transition: opacity .35s, width .35s var(--ease), height .35s var(--ease),
              margin .35s var(--ease), background .35s, border-color .5s var(--ease);
}

.ring.on { opacity: 1; }

/* swells over anything clickable */
.ring.hot {
  width: 52px;
  height: 52px;
  margin: -26px 0 0 -26px;
  background: color-mix(in srgb, var(--accent) 9%, transparent);
  border-color: color-mix(in srgb, var(--accent) 70%, transparent);
}

/* headline words, wrapped by app.js so each can drift toward the cursor */
.w {
  display: inline-block;
  transform: translate(var(--wx, 0px), var(--wy, 0px));
  transition: transform .5s var(--ease);
  will-change: transform;
}

/* feature rows and spec cells answer the pointer too, in CSS alone */
.feats li { transition: transform .3s var(--ease); }
.feats li:hover { transform: translateX(6px); }

.feats li::before { transition: transform .3s var(--ease); }
.feats li:hover::before { transform: translateY(-3px) scale(1.7); }

.spec div { transition: transform .3s var(--ease); }
.spec div:hover { transform: translateY(-2px); }
.spec dt, .spec dd { transition: color .3s; }
.spec div:hover dt { color: var(--accent); }

/* the tagline picks up a little weight shift under the cursor */
.app-tag { transition: letter-spacing .4s var(--ease); }
.app-tag:hover { letter-spacing: .012em; }

/* ambient spotlight on the slide you're reading, tinted by its accent */
.panel.live::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: radial-gradient(560px circle at var(--px, 50%) var(--py, 40%),
    color-mix(in srgb, var(--accent) 9%, transparent), transparent 62%);
  opacity: 0;
  transition: opacity .7s var(--ease);
}

.fancy .panel.live::before { opacity: 1; }

/* keep slide content above the spotlight */
.inner { position: relative; z-index: 1; }

/* cards pick up a soft glow that follows the pointer across them */
.chip::after,
.link-card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background: radial-gradient(200px circle at var(--gx, 50%) var(--gy, 50%),
    color-mix(in srgb, var(--ch, var(--accent)) 15%, transparent), transparent 70%);
  opacity: 0;
  transition: opacity .35s;
}

.chip:hover::after,
.link-card:hover::after { opacity: 1; }

/* a sheen that slides across a phone frame as you move over it */
.phone::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  border-radius: inherit;
  pointer-events: none;
  background: radial-gradient(240px circle at var(--gx, 50%) var(--gy, 50%),
    rgba(255, 255, 255, .4), transparent 60%);
  opacity: 0;
  mix-blend-mode: overlay;
  transition: opacity .4s;
}

.phone:hover::before { opacity: 1; }

/* ==========================================================
   ambient app backgrounds
   Three accent-coloured clouds drift across the app slide on
   their own paths, speeds and tempo, so the background keeps
   moving instead of sitting there as a gradient. Markup comes
   from appSlide() in app.js; strength is --aura, which the
   light and dark palettes each set.
   ========================================================== */
.aura {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  opacity: 0;
  transition: opacity .9s var(--ease);
  /* the colour is held out to the edges: whatever drifts across the
     middle of the slide is masked away, so copy never reads over it */
  -webkit-mask-image: radial-gradient(ellipse 78% 68% at 46% 48%,
    transparent 30%, #000 100%);
  mask-image: radial-gradient(ellipse 78% 68% at 46% 48%,
    transparent 30%, #000 100%);
}

.panel.live .aura { opacity: 1; }

/* off-screen slides hold their position instead of burning frames */
.panel:not(.live) .aura i { animation-play-state: paused; }

.aura i {
  position: absolute;
  display: block;
  width: var(--size);
  height: var(--size);
  margin: calc(var(--size) / -2);
  border-radius: 50%;
  background: radial-gradient(circle at 50% 50%,
    color-mix(in srgb, var(--accent) calc(var(--aura) * 1%), transparent) 0%,
    color-mix(in srgb, var(--accent) calc(var(--aura) * .55%), transparent) 38%,
    transparent 72%);
  will-change: transform, opacity;
}

/* each cloud starts somewhere else and travels its own loop */
.aura i:nth-child(1) {
  --size: 62vmax;
  top: 26%;
  left: 24%;
  animation: auraA 17s ease-in-out infinite alternate;
}

.aura i:nth-child(2) {
  --size: 52vmax;
  top: 64%;
  left: 74%;
  animation: auraB 23s ease-in-out infinite alternate;
}

.aura i:nth-child(3) {
  --size: 44vmax;
  top: 92%;
  left: 48%;
  animation: auraC 13s ease-in-out infinite alternate;
}

@keyframes auraA {
  from { transform: translate3d(-16vw, -8vh, 0) scale(.85); opacity: .65; }
  50%  { transform: translate3d(6vw, 14vh, 0) scale(1.2); opacity: 1; }
  to   { transform: translate3d(20vw, -4vh, 0) scale(1); opacity: .8; }
}

@keyframes auraB {
  from { transform: translate3d(12vw, 10vh, 0) scale(1.1); opacity: .9; }
  50%  { transform: translate3d(-14vw, -12vh, 0) scale(.9); opacity: .6; }
  to   { transform: translate3d(-4vw, 12vh, 0) scale(1.25); opacity: 1; }
}

@keyframes auraC {
  from { transform: translate3d(-10vw, 6vh, 0) scale(1); opacity: .5; }
  50%  { transform: translate3d(14vw, -10vh, 0) scale(1.3); opacity: .95; }
  to   { transform: translate3d(2vw, -18vh, 0) scale(.95); opacity: .7; }
}

/* reduced motion keeps the colour, drops the drift */
@media (prefers-reduced-motion: reduce) {
  .aura i { animation: none; }
}
/* ==========================================================
   responsive
   ========================================================== */

/* tablet and down: stack the app slide, lose the rail */
@media (max-width: 1000px) {
  .app { grid-template-columns: minmax(0, 1fr); gap: 2rem; }
  .stage { padding-top: .5rem; }
}

@media (max-width: 860px) {
  .rail { display: none; }
  .topbar { left: 0; }
  .panel {
    padding: 4.75rem clamp(1.25rem, 4vw, 3.5rem) 6rem;
    align-content: start;
  }
  .hint { display: none; }
}

/* phones: tighter type, screenshots sized to fit three across */
@media (max-width: 680px) {
  .tabs { display: none; }
  .panel { padding-bottom: 5.5rem; }
  .app-icon { width: 52px; height: 52px; border-radius: 14px; font-size: 1.5rem; }
  .app-copy { gap: .875rem; }
  .spec { grid-template-columns: repeat(2, 1fr); }
  .app-actions { width: 100%; flex-direction: column; align-items: stretch; }
  .app-actions .btn { justify-content: center; white-space: normal; text-align: center; }
  .phone { height: clamp(170px, 26dvh, 240px); border-radius: 18px; padding: 4px; }
  .phone::after { top: 9px; width: 22px; height: 3px; }
  .screen { border-radius: 15px; }
  .lb-figure img { max-height: 70dvh; max-width: 100%; }
  .lb-btn { width: 38px; height: 38px; }
}

/* very short viewports (landscape phones): let the slide scroll */
@media (max-height: 560px) {
  .panel { align-content: start; }
}

@media (prefers-reduced-motion: reduce) {
  .deck { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001s !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001s !important;
  }
  .panel .st { opacity: 1; transform: none; }
}
