/* Tapdeck official landing page.
   Apple-native precision utility aesthetic derived from Tapdeck's indigo/cyan/violet Force Touch icon.
   Supports automatic prefers-color-scheme light & dark modes plus manual data-theme override. */

@font-face {
  font-family: "Schibsted Grotesk";
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url("assets/fonts/schibsted-grotesk-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Schibsted Grotesk";
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url("assets/fonts/schibsted-grotesk-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  color-scheme: light dark;
  --bg: #F4F6FB;
  --bg-2: #E8EDF8;
  --surface: #FFFFFF;
  --surface-2: #F0F3FA;
  --text: #12172A;
  --muted: #4E5875;
  --line: rgba(18, 23, 42, .12);
  --line-strong: rgba(18, 23, 42, .22);
  --accent: #1E8FA3;
  --accent-text: #2E37A4;
  --accent-soft: rgba(59, 68, 184, .10);
  --cyan: #27A8BC;
  --violet: #684CE8;
  --button-bg: #3B44B8;
  --button-bg-hover: #2D3596;
  --button-text: #FFFFFF;
  --ground: #141936;
  --on-ground: #F2F5FF;
  --on-ground-muted: rgba(242, 245, 255, .78);
  --kbd-bg: #FFFFFF;
  --shot-shadow: 0 0 0 1px rgba(18, 23, 42, .10), 0 32px 64px -32px rgba(20, 28, 66, .35);
  --font: "Schibsted Grotesk", -apple-system, BlinkMacSystemFont, "Helvetica Neue", sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, monospace;
  --gutter: clamp(16px, 4vw, 40px);
  --wrap: 1180px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0B0E1A;
    --bg-2: #12172B;
    --surface: #161C34;
    --surface-2: #1D2442;
    --text: #F2F5FF;
    --muted: #A7B3D6;
    --line: rgba(242, 245, 255, .13);
    --line-strong: rgba(242, 245, 255, .24);
    --accent: #47E0F0;
    --accent-text: #7BE5F2;
    --accent-soft: rgba(71, 224, 240, .13);
    --cyan: #47E0F0;
    --violet: #9B80FF;
    --button-bg: #57D8E8;
    --button-bg-hover: #7BE5F2;
    --button-text: #0B0E1A;
    --ground: #0F142C;
    --kbd-bg: #1D2545;
    --shot-shadow: 0 0 0 1px rgba(242, 245, 255, .14), 0 34px 70px -28px rgba(0, 0, 0, .82);
  }
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0B0E1A;
  --bg-2: #12172B;
  --surface: #161C34;
  --surface-2: #1D2442;
  --text: #F2F5FF;
  --muted: #A7B3D6;
  --line: rgba(242, 245, 255, .13);
  --line-strong: rgba(242, 245, 255, .24);
  --accent: #47E0F0;
  --accent-text: #7BE5F2;
  --accent-soft: rgba(71, 224, 240, .13);
  --cyan: #47E0F0;
  --violet: #9B80FF;
  --button-bg: #57D8E8;
  --button-bg-hover: #7BE5F2;
  --button-text: #0B0E1A;
  --ground: #0F142C;
  --kbd-bg: #1D2545;
  --shot-shadow: 0 0 0 1px rgba(242, 245, 255, .14), 0 34px 70px -28px rgba(0, 0, 0, .82);
}

:root[data-theme="light"] {
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
a { color: var(--accent-text); text-underline-offset: .2em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--cyan); outline-offset: 3px; border-radius: 6px; }
button { font: inherit; color: inherit; }
h1, h2, h3 { margin: 0; font-weight: 760; }
p { margin: 0; }
code { font-family: var(--mono); font-size: .86em; }
.inline-code {
  padding: .08em .38em;
  border-radius: 6px;
  background: var(--bg-2);
  color: var(--text);
  font-size: .84em;
  border: 1px solid var(--line);
}
kbd {
  font-family: var(--mono);
  font-size: .82em;
  font-weight: 600;
  line-height: 1;
  display: inline-block;
  padding: .24em .48em .22em;
  border: 1px solid var(--line-strong);
  border-bottom-width: 2px;
  border-radius: 6px;
  background: var(--kbd-bg);
  color: var(--text);
  white-space: nowrap;
}

.skip { position: absolute; left: 16px; top: -60px; padding: 8px 14px; background: var(--text); color: var(--bg); border-radius: 8px; z-index: 20; }
.skip:focus { top: 12px; }

.wrap { width: 100%; max-width: calc(var(--wrap) + 2 * var(--gutter)); margin: 0 auto; padding-inline: var(--gutter); }

/* Header */
.top {
  position: sticky;
  top: 0;
  z-index: 30;
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}
.top-row { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding-block: 14px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); }
.brand-icon { width: 36px; height: 36px; border-radius: 9px; }
.brand-word { font-size: 1.2rem; font-weight: 800; letter-spacing: -.025em; }
.brand-beta {
  font-size: .74rem;
  font-weight: 700;
  letter-spacing: .01em;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-text);
  border: 1px solid color-mix(in srgb, var(--accent) 32%, transparent);
}
.nav { display: flex; gap: 24px; }
.nav a { color: var(--muted); text-decoration: none; font-weight: 560; font-size: .96rem; }
.nav a:hover { color: var(--text); }
.top-actions { display: flex; align-items: center; gap: 10px; }
.theme-toggle {
  width: 38px;
  height: 38px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--muted);
  transition: background .15s, color .15s, border-color .15s;
}
.theme-toggle:hover { color: var(--text); border-color: var(--line-strong); }
.theme-toggle svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.theme-toggle .icon-sun { display: none; }
.theme-toggle .icon-moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .icon-sun { display: block; }
  :root:not([data-theme="light"]) .theme-toggle .icon-moon { display: none; }
}
:root[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
:root[data-theme="dark"] .theme-toggle .icon-moon { display: none; }
:root[data-theme="light"] .theme-toggle .icon-sun { display: none; }
:root[data-theme="light"] .theme-toggle .icon-moon { display: block; }

.nav-cta {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0 16px;
  border-radius: 999px;
  background: var(--button-bg);
  color: var(--button-text);
  font-weight: 680;
  font-size: .92rem;
  text-decoration: none;
}
.nav-cta:hover { background: var(--button-bg-hover); }

/* Hero */
.hero { padding-top: clamp(32px, 5vw, 64px); }
.hero-pills { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 13px;
  border-radius: 999px;
  font-size: .86rem;
  font-weight: 620;
  background: var(--surface);
  color: var(--muted);
  border: 1px solid var(--line);
}
.pill-beta {
  background: var(--accent-soft);
  color: var(--accent-text);
  border-color: color-mix(in srgb, var(--accent) 35%, transparent);
}
.pill-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 8px var(--cyan); }

.hero-title {
  font-size: clamp(2.5rem, 1rem + 5.2vw, 4.9rem);
  line-height: .96;
  letter-spacing: -.038em;
  font-weight: 820;
}
.hero-title span { display: block; }
.hero-title span + span { color: var(--muted); }

.hero-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 24px 56px;
  align-items: end;
  margin-top: clamp(20px, 3vw, 32px);
}
@media (min-width: 900px) {
  .hero-row { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); }
  .hero-side .hero-actions { margin-top: 0; }
}
.hero-lede {
  max-width: 48ch;
  font-size: clamp(1.08rem, .98rem + .45vw, 1.28rem);
  line-height: 1.52;
  color: var(--muted);
}
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 14px; margin-top: 8px; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 24px;
  background: var(--button-bg);
  color: var(--button-text);
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
  font-size: 1rem;
  border: 0;
  cursor: pointer;
  transition: background .15s, transform .12s;
}
.button:hover { background: var(--button-bg-hover); }
.button:active { transform: translateY(1px); }
.button-secondary {
  background: transparent;
  color: var(--text);
  box-shadow: inset 0 0 0 1.5px var(--line-strong);
}
.button-secondary:hover { background: var(--bg-2); }

.brew {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: 100%;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 4px 4px 16px;
  background: var(--surface);
}
.brew-cmd { font-size: .85rem; overflow-x: auto; white-space: nowrap; min-width: 0; scrollbar-width: none; }
.copy {
  border: 0;
  border-radius: 999px;
  padding: 6px 13px;
  background: transparent;
  color: var(--accent-text);
  font-weight: 680;
  cursor: pointer;
}
.copy:hover { background: var(--bg-2); }
.command-hint { flex-basis: 100%; color: var(--muted); font-size: .9rem; }
.command-reveal { flex-basis: 100%; }
html:not(.js) .js-only, html:not(.js) [data-pt-command] { display: none; }
.not-out { max-width: 46ch; padding: 12px 18px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); color: var(--muted); }
.not-out strong { color: var(--text); }

.facts {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  margin: 18px 0 0;
  padding: 0;
  color: var(--muted);
  font-size: .92rem;
}
@media (min-width: 601px) {
  .facts { gap: 6px 0; }
  .facts li + li { border-left: 1px solid var(--line); margin-left: 14px; padding-left: 14px; }
}

/* Interactive Trackpad Command Deck Stage */
.stage-wrap { margin-top: clamp(32px, 5vw, 52px); }
.stage { margin: 0; }
.deck-stage {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 20px;
  padding: clamp(16px, 2.4vw, 26px);
  border-radius: clamp(16px, 2vw, 24px);
  background:
    radial-gradient(60% 70% at 88% 18%, rgba(71, 224, 240, .18), transparent 65%),
    radial-gradient(55% 75% at 12% 90%, rgba(117, 89, 245, .24), transparent 65%),
    linear-gradient(155deg, #121734 0%, #0C1024 60%, #111834 100%);
  color: #F2F5FF;
  border: 1px solid rgba(138, 168, 255, .22);
  box-shadow: 0 36px 80px -36px rgba(10, 14, 34, .72);
}
@media (min-width: 960px) {
  .deck-stage { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); align-items: stretch; }
}

/* Left Miniature macOS Desktop */
.mini-mac {
  display: flex;
  flex-direction: column;
  border-radius: 14px;
  overflow: hidden;
  background:
    radial-gradient(65% 70% at 75% 22%, rgba(87, 216, 232, .22), transparent 65%),
    linear-gradient(145deg, #1E2554, #131838 55%, #1A224B);
  border: 1px solid rgba(255, 255, 255, .14);
  min-height: 290px;
}
.mac-menubar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 6px 12px;
  background: rgba(8, 11, 24, .65);
  border-bottom: 1px solid rgba(255, 255, 255, .08);
  font-size: .74rem;
  color: rgba(242, 245, 255, .86);
}
.mac-apple { width: 9px; height: 9px; border-radius: 50%; background: rgba(242, 245, 255, .85); }
.mac-mb-right { margin-left: auto; display: inline-flex; align-items: center; gap: 6px; color: #7BE5F2; font-weight: 600; white-space: nowrap; }
.mac-mb-td { width: 7px; height: 7px; border-radius: 50%; background: #47E0F0; box-shadow: 0 0 8px #47E0F0; }

.mac-desktop {
  position: relative;
  flex: 1;
  padding: 16px;
  min-height: 256px;
  overflow: hidden;
}

.mc-spaces {
  position: absolute;
  left: 16px;
  right: 16px;
  top: 12px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  opacity: 0;
  transform: translateY(-10px);
  transition: opacity .32s ease, transform .32s ease;
  pointer-events: none;
}
.mc-space {
  padding: 8px 10px;
  border-radius: 8px;
  background: rgba(15, 21, 48, .85);
  border: 1px solid rgba(255, 255, 255, .16);
  font-size: .72rem;
  font-weight: 600;
  text-align: center;
  color: #C7D2F5;
}
.mc-space.is-current { border-color: #47E0F0; color: #FFFFFF; background: rgba(71, 224, 240, .18); }

.mac-win {
  position: absolute;
  left: 22px;
  top: 20px;
  width: calc(100% - 44px);
  height: calc(100% - 76px);
  border-radius: 10px;
  overflow: hidden;
  background: #141A33;
  border: 1px solid rgba(255, 255, 255, .16);
  box-shadow: 0 18px 36px rgba(0, 0, 0, .48);
  transition: left .36s cubic-bezier(.2, .8, .2, 1), top .36s cubic-bezier(.2, .8, .2, 1), width .36s cubic-bezier(.2, .8, .2, 1), height .36s cubic-bezier(.2, .8, .2, 1), transform .36s cubic-bezier(.2, .8, .2, 1);
}
.stage[data-gesture="swipe"] .mac-win {
  left: 14px;
  top: 14px;
  width: calc(52% - 14px);
  height: calc(100% - 28px);
  border-color: rgba(71, 224, 240, .55);
  box-shadow: 0 0 0 1px rgba(71, 224, 240, .35), 0 18px 38px rgba(0, 0, 0, .52);
}
.stage[data-gesture="corner"] .mc-spaces { opacity: 1; transform: translateY(0); }
.stage[data-gesture="corner"] .mac-win {
  top: 56px;
  left: 34px;
  width: calc(100% - 68px);
  height: calc(100% - 114px);
}
.stage[data-gesture="force"] .mac-win {
  border-color: rgba(240, 108, 198, .55);
}

.mac-win-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 10px;
  background: #1C2344;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}
.traffic { display: inline-flex; gap: 5px; }
.traffic i { width: 8px; height: 8px; border-radius: 50%; background: #FF5F57; }
.traffic i:nth-child(2) { background: #FEBC2E; }
.traffic i:nth-child(3) { background: #28C840; }
.mac-tabs { display: flex; gap: 4px; overflow: hidden; }
.mac-tab {
  font-size: .7rem;
  padding: 3px 8px;
  border-radius: 6px;
  color: #93A2CC;
  white-space: nowrap;
  transition: background .2s, color .2s;
}
.mac-tab.is-active { background: rgba(71, 224, 240, .18); color: #F2F5FF; font-weight: 650; }

.mac-win-body { display: grid; grid-template-columns: 78px minmax(0, 1fr); height: calc(100% - 31px); }
.mac-sidebar {
  padding: 12px 10px;
  background: rgba(10, 14, 30, .42);
  border-right: 1px solid rgba(255, 255, 255, .06);
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.mac-sidebar i { display: block; height: 6px; width: var(--w); border-radius: 3px; background: rgba(167, 179, 214, .26); }
.mac-editor {
  padding: 12px 14px;
  font-family: var(--mono);
  font-size: .72rem;
  line-height: 1.65;
  color: #D2DBFA;
  display: flex;
  flex-direction: column;
}
.code-line { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.code-line.indent { padding-left: 14px; }
.code-line em { font-style: normal; }
.code-line .kw { color: #B494FF; }
.code-line .ty { color: #57D8E8; }

.mac-launcher {
  position: absolute;
  left: 50%;
  top: 44%;
  transform: translate(-50%, -50%) scale(.92);
  width: min(88%, 340px);
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(14, 19, 42, .94);
  border: 1px solid rgba(155, 128, 255, .58);
  box-shadow: 0 22px 46px rgba(0, 0, 0, .65);
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: .8rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity .26s ease, transform .26s ease;
}
.stage[data-gesture="tap4"] .mac-launcher { opacity: 1; transform: translate(-50%, -50%) scale(1); }
.launcher-dot { width: 10px; height: 10px; border-radius: 50%; background: #9B80FF; box-shadow: 0 0 10px #9B80FF; flex: none; }
.launcher-text { flex: 1; font-weight: 600; color: #F2F5FF; }
.mac-launcher kbd { background: rgba(255, 255, 255, .10); border-color: rgba(255, 255, 255, .24); color: #F2F5FF; font-size: .72rem; }

.mac-hud {
  position: absolute;
  right: 14px;
  bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 13px;
  border-radius: 12px;
  background: rgba(10, 14, 30, .92);
  border: 1px solid rgba(71, 224, 240, .42);
  box-shadow: 0 12px 30px rgba(0, 0, 0, .55);
  max-width: calc(100% - 28px);
}
.hud-icon {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: rgba(71, 224, 240, .18);
  color: #57D8E8;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: .9rem;
  flex: none;
}
.hud-copy { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }
.hud-copy strong { font-size: .8rem; font-weight: 700; color: #FFFFFF; }
.hud-copy small { font-size: .72rem; color: #A7B3D6; }
.hud-latency {
  font-family: var(--mono);
  font-size: .7rem;
  font-weight: 650;
  padding: 3px 7px;
  border-radius: 999px;
  background: rgba(52, 211, 153, .16);
  color: #6EE7B7;
  flex: none;
}

/* Right Interactive Force Touch Trackpad */
.pad-panel { display: flex; flex-direction: column; gap: 10px; }
.pad-header { display: flex; align-items: center; justify-content: space-between; font-size: .78rem; color: #A7B3D6; padding-inline: 2px; }
.pad-label { font-weight: 700; color: #DCE4FF; letter-spacing: .01em; }
.pad-coords { font-family: var(--mono); font-size: .72rem; color: #7BE5F2; }

.trackpad {
  position: relative;
  flex: 1;
  aspect-ratio: 125 / 77;
  min-height: 210px;
  border-radius: 18px;
  background:
    radial-gradient(75% 75% at 50% 45%, rgba(64, 80, 146, .34), rgba(16, 22, 46, .92)),
    linear-gradient(180deg, #1E264A, #121833);
  border: 1.5px solid rgba(142, 170, 255, .34);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .14), 0 16px 36px rgba(0, 0, 0, .42);
  overflow: hidden;
  cursor: crosshair;
  touch-action: pan-y;
}

.tp-zone {
  position: absolute;
  width: 19%;
  height: 22%;
  border: 1px dashed rgba(245, 166, 91, .35);
  background: rgba(245, 166, 91, .06);
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--mono);
  font-size: .64rem;
  font-weight: 700;
  color: rgba(245, 186, 120, .75);
  pointer-events: none;
  transition: background .25s, border-color .25s, color .25s;
}
.tp-tl { left: 8px; top: 8px; }
.tp-tr { right: 8px; top: 8px; }
.tp-bl { left: 8px; bottom: 32px; }
.tp-br { right: 8px; bottom: 32px; }
.stage[data-gesture="corner"] .tp-br {
  border-color: #FFB454;
  background: rgba(255, 180, 84, .26);
  color: #FFF4E2;
}

.tp-split {
  position: absolute;
  left: 10px;
  right: 10px;
  top: 46%;
  border-top: 1px dashed rgba(155, 128, 255, .32);
  pointer-events: none;
}
.tp-split span {
  position: absolute;
  right: 4px;
  top: -10px;
  font-family: var(--mono);
  font-size: .6rem;
  color: rgba(180, 162, 255, .8);
  background: #171E3E;
  padding: 1px 5px;
  border-radius: 4px;
}

.tp-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: calc(100% - 26px);
  pointer-events: none;
}

.tp-swipe-guides { opacity: 0; transition: opacity .25s; }
.stage[data-gesture="swipe"] .tp-swipe-guides { opacity: 1; }
.tp-trail { fill: none; stroke: rgba(71, 224, 240, .5); stroke-width: 3; stroke-dasharray: 6 6; stroke-linecap: round; }
.tp-arrow { fill: none; stroke: #47E0F0; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }

.tp-ring {
  fill: none;
  stroke: rgba(71, 224, 240, .48);
  stroke-width: 2;
  transform-box: fill-box;
  transform-origin: center;
  animation: tp-pulse 2.2s ease-out infinite;
}
.tp-ring.r2 { stroke: rgba(155, 128, 255, .36); animation-delay: .35s; }
.stage[data-gesture="force"] .tp-ring.r1 { stroke: rgba(244, 114, 182, .75); stroke-width: 2.8; }
.stage[data-gesture="force"] .tp-ring.r2 { stroke: rgba(71, 224, 240, .65); stroke-width: 2.2; }
.stage[data-gesture="corner"] .tp-ring.r1 { stroke: rgba(255, 180, 84, .82); }

@keyframes tp-pulse {
  0% { transform: scale(.7); opacity: .9; }
  70% { transform: scale(1.25); opacity: .22; }
  100% { transform: scale(1.4); opacity: 0; }
}

.tp-finger {
  transition: transform .42s cubic-bezier(.25, .8, .25, 1), opacity .24s ease;
}
.tp-finger ellipse {
  fill: rgba(71, 224, 240, .24);
  stroke: #57D8E8;
  stroke-width: 2.2;
}
.tp-finger circle { fill: #E6FDFF; }
.tp-finger.is-anchor ellipse {
  fill: rgba(155, 128, 255, .26);
  stroke: #A88BFF;
}
.tp-finger.is-tapper ellipse {
  fill: rgba(71, 224, 240, .38);
  stroke: #6CEEFF;
  animation: tap-pop 1.3s ease-in-out infinite;
  transform-box: fill-box;
  transform-origin: center;
}
.tp-finger.is-force ellipse {
  fill: rgba(244, 114, 182, .32);
  stroke: #F472B6;
}
.tp-finger.is-corner ellipse {
  fill: rgba(255, 180, 84, .34);
  stroke: #FFB454;
}
.tp-finger.is-hidden { opacity: 0; }

@keyframes tap-pop {
  0%, 100% { transform: scale(.86); opacity: .55; }
  45% { transform: scale(1.16); opacity: 1; }
}

.tp-live-touch { opacity: 0; transition: opacity .15s; }
.tp-live-touch.is-on { opacity: 1; }
.live-ellipse { fill: rgba(71, 224, 240, .32); stroke: #7BE5F2; stroke-width: 2; }
.live-ripple { fill: none; stroke: rgba(71, 224, 240, .55); stroke-width: 1.6; }

.tp-pressure {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 26px;
  padding: 0 12px;
  background: rgba(8, 12, 26, .74);
  border-top: 1px solid rgba(255, 255, 255, .08);
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .68rem;
  color: #A7B3D6;
}
.tp-pressure-track {
  flex: 1;
  height: 5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .12);
  overflow: hidden;
}
.tp-pressure-fill {
  display: block;
  height: 100%;
  width: 48%;
  border-radius: inherit;
  background: linear-gradient(90deg, #47E0F0, #8A6BFF);
  transition: width .35s ease, background .35s ease;
}
.stage[data-gesture="force"] .tp-pressure-fill {
  width: 88%;
  background: linear-gradient(90deg, #47E0F0, #8A6BFF 52%, #F472B6);
}
.stage[data-gesture="tap4"] .tp-pressure-fill,
.stage[data-gesture="tiptap"] .tp-pressure-fill { width: 24%; }
.stage[data-gesture="corner"] .tp-pressure-fill { width: 56%; }
.stage[data-gesture="swipe"] .tp-pressure-fill { width: 52%; }
.tp-pressure-stage { font-family: var(--mono); font-weight: 650; color: #7BE5F2; min-width: 58px; text-align: right; }

/* Gesture Pills & Caption Bar */
.stage-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 18px;
  margin-top: 18px;
}
.gesture-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.g-pill {
  border: 1px solid var(--line-strong);
  background: var(--surface);
  color: var(--text);
  padding: 8px 14px;
  border-radius: 999px;
  font-size: .9rem;
  font-weight: 640;
  cursor: pointer;
  transition: background .15s, color .15s, border-color .15s;
}
.g-pill:hover { background: var(--bg-2); }
.g-pill[aria-pressed="true"] {
  background: var(--button-bg);
  color: var(--button-text);
  border-color: transparent;
}
.stage-caption {
  flex: 1 1 280px;
  color: var(--muted);
  font-size: .95rem;
  line-height: 1.45;
}

/* Sections */
section { scroll-margin-top: 84px; }
.section-eyebrow {
  font-size: .82rem;
  font-weight: 760;
  text-transform: uppercase;
  letter-spacing: .09em;
  color: var(--accent-text);
  margin-bottom: 10px;
}
.eyebrow-on-dark { color: #7BE5F2; }
.section-title {
  font-size: clamp(1.95rem, 1.25rem + 2.4vw, 3.15rem);
  line-height: 1.03;
  letter-spacing: -.032em;
  font-weight: 800;
  text-wrap: balance;
}
.section-lede { margin-top: 14px; max-width: 58ch; color: var(--muted); font-size: 1.08rem; }

/* Features */
.features { padding-top: clamp(80px, 10vw, 132px); }
.feature-list { display: grid; gap: clamp(72px, 9vw, 120px); margin-top: clamp(44px, 6vw, 72px); }
.feature { display: grid; gap: 28px 52px; align-items: center; }
.feature-eyebrow {
  font-size: .8rem;
  font-weight: 740;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--accent-text);
  margin-bottom: 8px;
}
.feature h3 {
  font-size: clamp(1.5rem, 1.15rem + 1.2vw, 2.15rem);
  line-height: 1.08;
  letter-spacing: -.025em;
  font-weight: 780;
}
.feature-summary { margin-top: 14px; font-size: 1.08rem; color: var(--muted); max-width: 50ch; }
.points { list-style: none; margin: 18px 0 0; padding: 0; color: var(--muted); max-width: 54ch; }
.points li { position: relative; padding-left: 24px; margin-top: 10px; }
.points li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: .72em;
  width: 12px;
  height: 2.5px;
  border-radius: 2px;
  background: var(--cyan);
}
.shot { margin: 0; justify-self: center; width: 100%; max-width: var(--shot-w); }
.shot-chrome {
  border-radius: 14px;
  overflow: hidden;
  box-shadow: var(--shot-shadow);
  background: var(--surface);
}
.shot img { width: 100%; display: block; }

@media (min-width: 920px) {
  .feature.has-shot { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
  .feature.has-shot:nth-child(even) { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
  .feature.has-shot:nth-child(even) .feature-text { order: 2; }
  .feature-wide.has-shot,
  .feature-wide.has-shot:nth-child(even) { grid-template-columns: minmax(0, 1fr); }
  .feature-wide .feature-text {
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
    gap: 16px 52px;
    align-items: start;
  }
  .feature-wide .feature-text .points { margin-top: 6px; }
  .feature-wide.has-shot:nth-child(even) .feature-text { order: 0; }
}

/* Gesture Families Matrix & Superpower Actions */
.matrix-section {
  margin-top: clamp(88px, 11vw, 136px);
  padding-block: clamp(64px, 8vw, 104px);
  background: var(--bg-2);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.matrix-head {
  display: grid;
  gap: 18px 48px;
  align-items: end;
}
@media (min-width: 900px) {
  .matrix-head { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); }
  .matrix-head .section-lede { margin-top: 0; }
}

.family-grid {
  margin: clamp(32px, 4vw, 48px) 0 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
}
.family-card {
  padding: 20px 22px;
  border-radius: 16px;
  background: var(--surface);
  border: 1px solid var(--line);
}
.family-card dt {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}
.family-name { font-weight: 750; font-size: 1.05rem; }
.family-count {
  font-family: var(--mono);
  font-size: .78rem;
  font-weight: 650;
  color: var(--accent-text);
  background: var(--accent-soft);
  padding: 2px 8px;
  border-radius: 999px;
  white-space: nowrap;
}
.family-card dd { margin: 10px 0 0; color: var(--muted); font-size: .95rem; line-height: 1.5; }

.powers-block { margin-top: clamp(48px, 6vw, 72px); }
.sub-heading { font-size: clamp(1.35rem, 1.1rem + .8vw, 1.75rem); letter-spacing: -.02em; }
.power-grid {
  list-style: none;
  margin: 22px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 16px;
}
.power-card {
  padding: 22px;
  border-radius: 16px;
  background: var(--surface);
  border: 1px solid var(--line);
}
.power-badge {
  display: inline-block;
  font-family: var(--mono);
  font-size: .76rem;
  font-weight: 700;
  color: var(--accent-text);
  background: var(--accent-soft);
  padding: 3px 9px;
  border-radius: 999px;
  margin-bottom: 10px;
}
.power-card h3 { font-size: 1.12rem; font-weight: 740; letter-spacing: -.015em; }
.power-card p { margin-top: 8px; color: var(--muted); font-size: .95rem; line-height: 1.52; }

/* Privacy Band (Full-bleed dark indigo) */
.privacy {
  padding-block: clamp(68px, 9vw, 112px);
  background: var(--ground);
  color: var(--on-ground);
}
.privacy .section-title { color: var(--on-ground); }
.privacy-list {
  list-style: none;
  margin: clamp(32px, 5vw, 52px) 0 0;
  padding: 0;
  display: grid;
  gap: 32px 44px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.privacy-list h3 {
  font-size: 1.25rem;
  line-height: 1.25;
  font-weight: 740;
  padding-top: 16px;
  border-top: 3px solid #47E0F0;
}
.privacy-list p { margin-top: 10px; color: var(--on-ground-muted); font-size: .98rem; }

/* Permissions Transparency */
.perms { padding-top: clamp(76px, 10vw, 128px); }
.perms-grid { display: grid; gap: 32px 64px; align-items: start; }
@media (min-width: 900px) { .perms-grid { grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); } }
.perm-list { margin: 0; display: grid; gap: 24px; }
.perm { padding-top: 18px; border-top: 1px solid var(--line); }
.perm dt { font-size: 1.35rem; font-weight: 750; }
.perm dd { margin: 8px 0 0; }
.perm dd p { color: var(--muted); }
.perm dd p + p { margin-top: 6px; }
.perm dd strong { color: var(--text); font-weight: 680; }

/* Install */
.install { padding-top: clamp(76px, 10vw, 128px); }
.install-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.not-out-large { margin-top: 28px; font-size: 1.1rem; }
.install-ways { display: grid; gap: 24px; margin-top: 32px; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.way {
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.way h3 { font-size: 1.35rem; font-weight: 760; }
.steps { margin: 16px 0 22px; padding-left: 1.3em; color: var(--muted); }
.steps li { margin-top: 7px; padding-left: 4px; }
.steps li::marker { color: var(--accent-text); font-weight: 750; }
.way-lede { margin: 16px 0 22px; color: var(--muted); }
.way-note { margin-top: 16px; color: var(--muted); font-size: .92rem; }
.way-sha { margin-top: 14px; font-size: .8rem; color: var(--muted); word-break: break-all; }
.brew-block { display: flex; margin-top: 16px; border-radius: 14px; }
.way .command-reveal { margin-top: 14px; width: 100%; }

/* FAQ */
.faq { padding-block: clamp(76px, 10vw, 128px); }
.faq-grid { display: grid; gap: 28px 64px; align-items: start; }
@media (min-width: 900px) { .faq-grid { grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); } }
.faq-list details { border-top: 1px solid var(--line); }
.faq-list details:last-child { border-bottom: 1px solid var(--line); }
.faq-list summary {
  list-style: none;
  cursor: pointer;
  padding: 18px 40px 18px 0;
  position: relative;
  font-size: 1.1rem;
  font-weight: 660;
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after {
  content: "";
  position: absolute;
  right: 8px;
  top: 50%;
  width: 10px;
  height: 10px;
  margin-top: -7px;
  border: solid var(--accent-text);
  border-width: 0 2.2px 2.2px 0;
  transform: rotate(45deg);
  transition: transform .2s;
}
.faq-list details[open] summary::after { transform: rotate(-135deg); margin-top: -2px; }
.faq-list details p { padding: 0 0 20px; color: var(--muted); max-width: 64ch; }

/* Footer */
.foot { border-top: 1px solid var(--line); background: var(--surface-2); }
.foot-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px 24px;
  padding-block: 26px;
  color: var(--muted);
  font-size: .92rem;
}
.foot-brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; color: var(--text); }
.foot-brand img { border-radius: 6px; }
.foot-links { display: flex; flex-wrap: wrap; gap: 10px 20px; }
.foot-links a { color: var(--muted); text-decoration: none; font-weight: 560; }
.foot-links a:hover { color: var(--text); }
.foot-copy { font-weight: 560; }

/* Responsive Mobile (<= 640px) */
@media (max-width: 640px) {
  .nav, .nav-cta { display: none; }
  .hero-title { letter-spacing: -.03em; }
  .brew { width: 100%; }
  .brew-cmd { flex: 1; min-width: 0; }
  .mac-menubar > span:not(.mac-apple):not(.mac-mb-right) { display: none; }
  .mac-sidebar { display: none; }
  .mac-win-body { grid-template-columns: minmax(0, 1fr); }
  .mac-tabs { gap: 2px; }
  .mac-tab:nth-child(3) { display: none; }
  .gesture-pills { gap: 6px; }
  .g-pill { padding: 7px 11px; font-size: .84rem; }
  .family-grid, .power-grid, .install-ways { grid-template-columns: minmax(0, 1fr); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
