/* Porter marketing site: calm dark liquid glass */
:root {
  --bg: #12151a;
  --bg-deep: #0b0d11;
  --ink: #e7eaee;
  --muted: #9aa3ae;
  --line: rgba(255, 255, 255, 0.1);
  --accent: #7eb8a8;
  --accent-2: #a5d4c8;
  --accent-soft: rgba(126, 184, 168, 0.16);
  --accent-rgb: 126, 184, 168;
  --danger: #e07a7a;
  --glass: rgba(255, 255, 255, 0.06);
  --glass-strong: rgba(255, 255, 255, 0.1);
  --glass-edge: rgba(255, 255, 255, 0.22);
  --shadow: 0 22px 50px rgba(0, 0, 0, 0.35);
  --radius: 20px;
  --radius-sm: 12px;
  --font: "Plus Jakarta Sans", "Segoe UI", system-ui, sans-serif;
  --display: "Fraunces", Georgia, "Times New Roman", serif;
  --nav-w: 236px;
  --max: 1120px;
  --pad: clamp(16px, 4vw, 40px);
  --mx: 50%;
  --my: 20%;
  --ease-spring: cubic-bezier(0.175, 0.885, 0.32, 2.2);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  scroll-behavior: smooth;
  color-scheme: dark;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  line-height: 1.55;
  background: radial-gradient(1200px 700px at 50% -10%, #1a222c 0%, var(--bg) 46%, var(--bg-deep) 100%);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  position: relative;
}

/* Soft atmosphere — muted sage, no neon purple */
.ambient {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
  background:
    radial-gradient(900px 520px at 8% 0%, rgba(126, 184, 168, 0.12), transparent 58%),
    radial-gradient(760px 480px at 96% 12%, rgba(110, 140, 170, 0.1), transparent 52%),
    radial-gradient(640px 420px at 40% 100%, rgba(80, 100, 120, 0.14), transparent 55%);
}

.ambient .orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(56px);
  opacity: 0.55;
  will-change: transform;
  animation: orb-drift 26s ease-in-out infinite;
}

.ambient .orb-a {
  width: min(52vw, 420px);
  height: min(52vw, 420px);
  left: -10%;
  top: 16%;
  background: rgba(126, 184, 168, 0.28);
}

.ambient .orb-b {
  width: min(44vw, 360px);
  height: min(44vw, 360px);
  right: -8%;
  top: 40%;
  background: rgba(100, 130, 160, 0.22);
  animation-duration: 32s;
  animation-direction: reverse;
}

.ambient .orb-c {
  width: min(38vw, 300px);
  height: min(38vw, 300px);
  left: 36%;
  bottom: -6%;
  background: rgba(90, 110, 130, 0.25);
  animation-duration: 28s;
  animation-delay: -6s;
}

@keyframes orb-drift {
  0%,
  100% {
    transform: translate3d(0, 0, 0) scale(1);
  }
  33% {
    transform: translate3d(2.5%, -3%, 0) scale(1.05);
  }
  66% {
    transform: translate3d(-3%, 2.5%, 0) scale(0.97);
  }
}

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

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--accent-2);
}

.skip {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--ink);
  color: var(--bg);
  padding: 8px 12px;
  z-index: 1000;
}

.skip:focus {
  left: 8px;
  top: 8px;
}

/* Simple frosted panels (no SVG liquid distortion) */
.glass {
  position: relative;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  backdrop-filter: blur(16px) saturate(1.25);
  -webkit-backdrop-filter: blur(16px) saturate(1.25);
  box-shadow:
    var(--shadow),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.glass-strong {
  background: rgba(255, 255, 255, 0.1);
}

/* Layout shell */
.shell {
  display: grid;
  grid-template-columns: var(--nav-w) minmax(0, 1fr);
  gap: 0;
  min-height: 100vh;
}

.side-nav {
  position: sticky;
  top: 0;
  align-self: start;
  height: 100vh;
  padding: 24px 14px 20px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  border-right: 1px solid var(--line);
  background: rgba(10, 12, 16, 0.72);
  backdrop-filter: blur(18px) saturate(1.25);
  -webkit-backdrop-filter: blur(18px) saturate(1.25);
  z-index: 40;
}

.side-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: inherit;
  text-decoration: none;
  padding: 4px 6px;
}

.side-brand img {
  width: 40px;
  height: 40px;
  border-radius: 10px;
}

.side-brand span {
  font-family: var(--display);
  font-size: 1.55rem;
  line-height: 1;
  color: var(--ink);
}

.side-nav nav {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 2px;
  overflow: auto;
  flex: 1;
  min-height: 0;
  padding: 6px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.nav-indicator {
  position: absolute;
  left: 6px;
  right: 6px;
  top: 0;
  height: 36px;
  border-radius: 10px;
  background: rgba(var(--accent-rgb), 0.18);
  border: 1px solid rgba(var(--accent-rgb), 0.22);
  pointer-events: none;
  z-index: 0;
  opacity: 0;
  transform: translateY(0);
  transition:
    transform 0.28s var(--ease-out),
    height 0.22s ease,
    opacity 0.18s ease;
}

.side-nav nav.has-indicator .nav-indicator {
  opacity: 1;
}

.side-nav a[data-nav] {
  position: relative;
  z-index: 1;
  color: var(--muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  padding: 9px 12px;
  border-radius: 10px;
  background: transparent;
  transition: color 0.18s ease;
}

.side-nav a[data-nav]:hover,
.side-nav a[data-nav][aria-current="true"] {
  color: var(--ink);
}

.side-cta {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.side-cta .btn {
  width: 100%;
}

.side-nav a.btn-ghost {
  color: var(--ink);
}

.side-nav a.btn-primary,
.mobile-drawer-panel a.btn-primary,
a.btn-primary,
.btn-primary {
  color: #ffffff;
}

.main {
  min-width: 0;
  padding: 0 var(--pad) 64px;
}

.topbar-mobile {
  display: none;
  position: sticky;
  top: 0;
  z-index: 50;
  padding: 12px 16px;
  margin: 0 calc(-1 * var(--pad)) 12px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: rgba(12, 14, 18, 0.82);
  backdrop-filter: blur(16px) saturate(1.3);
  -webkit-backdrop-filter: blur(16px) saturate(1.3);
  border-bottom: 1px solid var(--line);
}

.menu-btn {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.08);
  color: var(--ink);
  border-radius: 999px;
  padding: 8px 14px;
  font: inherit;
  cursor: pointer;
}

.mobile-drawer {
  display: none;
}

body.nav-open .mobile-drawer {
  display: block;
  position: fixed;
  inset: 0;
  z-index: 60;
  background: rgba(0, 0, 0, 0.55);
}

.mobile-drawer[hidden] {
  display: none !important;
}

.mobile-drawer-panel {
  width: min(300px, 88vw);
  height: 100%;
  padding: 20px;
  background: rgba(18, 22, 28, 0.94);
  backdrop-filter: blur(22px) saturate(1.35);
  -webkit-backdrop-filter: blur(22px) saturate(1.35);
  display: flex;
  flex-direction: column;
  gap: 12px;
  border-right: 1px solid var(--line);
}

.mobile-drawer-panel nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.mobile-drawer-panel a {
  text-decoration: none;
  color: var(--ink);
  padding: 10px 12px;
  border-radius: 10px;
}

.mobile-drawer-panel a:hover {
  background: var(--accent-soft);
}

/* Typography */
.section {
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(48px, 8vw, 88px) 0;
}

.section h2 {
  font-family: var(--display);
  font-size: clamp(1.85rem, 3.5vw, 2.6rem);
  font-weight: 400;
  line-height: 1.15;
  margin: 0 0 12px;
  letter-spacing: -0.01em;
}

.section .lede {
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 58ch;
  margin: 0 0 28px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 12px;
}

/* Buttons — glowing fluid hover */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 18px;
  border-radius: 14px;
  border: 1px solid transparent;
  font: inherit;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  transition:
    transform 0.22s ease,
    background 0.22s ease,
    box-shadow 0.28s ease,
    border-color 0.22s ease,
    color 0.2s ease;
}

.btn::after {
  content: "";
  position: absolute;
  inset: -40% auto -40% -40%;
  width: 45%;
  background: linear-gradient(
    105deg,
    transparent 0%,
    rgba(255, 255, 255, 0.38) 48%,
    transparent 100%
  );
  transform: translateX(-130%) rotate(18deg);
  transition: transform 0.55s var(--ease-out);
  pointer-events: none;
  z-index: 1;
}

.btn:hover::after {
  transform: translateX(340%) rotate(18deg);
}

.btn:hover {
  transform: translateY(-2px);
}

a.btn-primary,
.btn-primary {
  background: linear-gradient(180deg, #6eab9c 0%, #4f8f80 100%);
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.16);
  box-shadow:
    0 10px 24px rgba(0, 0, 0, 0.28),
    0 0 0 1px rgba(var(--accent-rgb), 0.18);
}

a.btn-primary:hover,
.btn-primary:hover,
.side-nav a.btn-primary:hover,
.mobile-drawer-panel a.btn-primary:hover {
  color: #ffffff !important;
  background: linear-gradient(180deg, #7eb8a8 0%, #458576 100%);
  box-shadow:
    0 14px 32px rgba(0, 0, 0, 0.34),
    0 0 28px rgba(var(--accent-rgb), 0.45),
    0 0 0 1px rgba(var(--accent-rgb), 0.35);
}

a.btn-primary:visited,
.btn-primary:visited {
  color: #ffffff !important;
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.14);
  color: var(--ink);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.btn-ghost:hover {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(var(--accent-rgb), 0.45);
  box-shadow:
    0 10px 26px rgba(0, 0, 0, 0.22),
    0 0 22px rgba(var(--accent-rgb), 0.22);
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 0.82rem;
  background: rgba(var(--accent-rgb), 0.14);
  color: var(--accent-2);
  border: 1px solid rgba(var(--accent-rgb), 0.28);
}

/* Hero */
.hero {
  padding-top: clamp(36px, 6vw, 72px);
  text-align: center;
}

.hero-mark {
  width: 88px;
  height: 88px;
  margin: 0 auto 18px;
  border-radius: 22px;
  box-shadow:
    var(--shadow),
    0 0 0 1px rgba(255, 255, 255, 0.5);
}

.hero h1 {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(2.4rem, 6vw, 4.2rem);
  line-height: 1.05;
  margin: 0 0 8px;
  letter-spacing: -0.02em;
}

.hero .tagline {
  font-family: var(--display);
  font-size: clamp(1.25rem, 2.6vw, 1.75rem);
  color: var(--muted);
  max-width: 22em;
  margin: 0 auto 16px;
  line-height: 1.25;
}

.hero .sub {
  max-width: 42em;
  margin: 0 auto 24px;
  color: var(--muted);
}

.hero-visual {
  margin-top: 36px;
  padding: 12px;
  overflow: hidden;
}

.hero-visual img {
  width: 100%;
  border-radius: 14px;
  border: 1px solid var(--line);
}

.trust-line {
  margin-top: 14px;
  font-size: 0.9rem;
  color: var(--muted);
}

/* Compare cards */
.compare {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.compare article {
  padding: 22px;
  transition: transform 0.25s ease;
}

.compare article:hover {
  transform: translateY(-4px);
}

.compare h3 {
  font-family: var(--display);
  font-size: 1.45rem;
  margin: 0 0 10px;
  font-weight: 400;
}

.compare ul {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--muted);
}

.compare li + li {
  margin-top: 6px;
}

/* Filmstrip carousel */
.filmstrip-wrap {
  max-width: 100%;
  overflow: hidden;
  border-radius: var(--radius);
  mask-image: linear-gradient(90deg, transparent 0, #000 18px, #000 calc(100% - 18px), transparent 100%);
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 18px, #000 calc(100% - 18px), transparent 100%);
}

.filmstrip {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  padding: 4px 8px 14px;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  scrollbar-width: thin;
  scrollbar-color: rgba(126, 184, 168, 0.45) transparent;
}

/* Loop mode: keep snap off so pause/resume never jumps */
.filmstrip.filmstrip--loop {
  scroll-snap-type: none;
  scroll-behavior: auto;
}

.filmstrip.is-autoplaying {
  scrollbar-color: rgba(126, 184, 168, 0.28) transparent;
}

.filmstrip::-webkit-scrollbar {
  height: 6px;
}

.filmstrip::-webkit-scrollbar-thumb {
  background: rgba(126, 184, 168, 0.4);
  border-radius: 999px;
}

.shot {
  flex: 0 0 min(78vw, 520px);
  scroll-snap-align: start;
  padding: 10px;
  cursor: zoom-in;
  border: none;
  text-align: left;
  font: inherit;
  color: inherit;
  content-visibility: auto;
  contain: content;
}

/* Avoid paint flicker while the strip is continuously scrolling */
.filmstrip--loop .shot {
  content-visibility: visible;
  contain: layout style;
}

.filmstrip--loop .shot img {
  transform: translateZ(0);
  backface-visibility: hidden;
}

.shot img {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--line);
  aspect-ratio: 16 / 10;
  object-fit: cover;
  background: #1c222a;
}

.shot figcaption,
.shot .cap {
  margin-top: 10px;
  font-size: 0.88rem;
  color: var(--muted);
}

@media (max-width: 640px) {
  .filmstrip-wrap {
    mask-image: none;
    -webkit-mask-image: none;
  }
}

/* Steps */
.steps {
  display: grid;
  gap: 12px;
  counter-reset: step;
}

.step {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 16px;
  align-items: start;
  padding: 18px 20px;
}

.step::before {
  counter-increment: step;
  content: counter(step);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  font-size: 0.9rem;
}

.step h3 {
  margin: 0 0 4px;
  font-size: 1.05rem;
}

.step p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

/* Feature bento */
.bento {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 14px;
}

.feat {
  grid-column: span 4;
  padding: 20px;
  text-align: left;
  cursor: pointer;
  border: none;
  font: inherit;
  color: inherit;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.feat:hover,
.feat[aria-expanded="true"] {
  transform: translateY(-3px);
}

.feat:nth-child(1) {
  grid-column: span 7;
}

.feat:nth-child(2) {
  grid-column: span 5;
}

.feat h3 {
  font-family: var(--display);
  font-size: 1.35rem;
  margin: 0 0 8px;
  font-weight: 400;
}

.feat p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.feat .more {
  display: none;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  color: var(--ink);
  font-size: 0.92rem;
}

.feat[aria-expanded="true"] .more {
  display: block;
}

/* Matrix */
.matrix {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.matrix th,
.matrix td {
  text-align: left;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
}

.matrix th {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.matrix-wrap {
  overflow-x: auto;
  padding: 8px;
}

/* Locks */
.locks {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.lock {
  padding: 18px;
}

.lock strong {
  display: block;
  margin-bottom: 6px;
}

.lock span {
  color: var(--muted);
  font-size: 0.92rem;
}

/* Who it's for */
.audience-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.audience-card {
  padding: 0;
  display: flex;
  flex-direction: column;
  min-height: 100%;
}

.audience-card img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-bottom: 1px solid var(--line);
  background: #161a20;
}

.audience-card h3 {
  font-family: var(--display);
  font-weight: 400;
  font-size: 1.35rem;
  margin: 16px 18px 8px;
}

.audience-card p {
  margin: 0 18px 18px;
  color: var(--muted);
  font-size: 0.95rem;
  flex: 1;
}

.audience-card-not {
  border-color: rgba(224, 122, 122, 0.28);
}

.audience-card-not h3 {
  color: #f0b4b4;
}

/* Origin case study */
.story-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.15fr);
  gap: 0;
  padding: 0;
  overflow: hidden;
}

.story-art {
  width: 100%;
  height: 100%;
  min-height: 280px;
  object-fit: cover;
  border-right: 1px solid var(--line);
  background: #161a20;
}

.story-body {
  padding: 22px 24px 26px;
}

.story-body h3 {
  font-size: 0.82rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent-2);
  margin: 16px 0 6px;
  font-weight: 700;
}

.story-body h3:first-child {
  margin-top: 0;
}

.story-body p {
  margin: 0;
  color: var(--muted);
  font-size: 0.96rem;
}

.workshop-heading {
  font-family: var(--display);
  font-weight: 400;
  margin: 28px 0 12px;
}

/* Download */
.download-panel {
  padding: 28px;
  text-align: center;
}

.download-panel .ver {
  font-family: var(--display);
  font-size: 1.5rem;
  margin: 8px 0 18px;
}

.download-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  align-items: stretch;
}

.download-footnote {
  margin: 22px auto 0;
  max-width: 62ch;
  text-align: center;
  color: var(--muted);
  font-size: 0.92rem;
}

.download-footnote a,
.text-link {
  color: var(--accent);
}

button.text-link {
  appearance: none;
  background: none;
  border: 0;
  padding: 0;
  margin: 0 0 0 0.35em;
  font: inherit;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.platform-note {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  align-items: center;
  justify-content: center;
  margin: 14px auto 0;
  max-width: 46ch;
  color: var(--muted);
  font-size: 0.92rem;
}

.gate-steps {
  text-align: left;
  max-width: 42ch;
  margin: 22px auto 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.gate-steps ol {
  margin: 8px 0 0;
  padding-left: 1.2rem;
}

/* Download chooser modal */
.dl-modal {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.dl-modal[hidden] {
  display: none !important;
}

.dl-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(16, 24, 32, 0.72);
}

.dl-modal-panel {
  position: relative;
  z-index: 1;
  width: min(720px, 100%);
  padding: 28px 28px 22px;
  border-radius: 18px;
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.42);
}

.dl-modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
}

.dl-modal-panel .eyebrow {
  margin-bottom: 6px;
}

.dl-modal-panel h2 {
  margin: 0 0 8px;
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(1.6rem, 3vw, 2rem);
}

.dl-modal-lede {
  margin: 0 0 20px;
  color: var(--muted);
  max-width: 48ch;
}

.dl-modal-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.dl-option {
  padding: 18px 16px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  text-align: left;
}

.dl-option h3 {
  margin: 8px 0 4px;
  font-family: var(--display);
  font-weight: 400;
  font-size: 1.35rem;
}

.dl-option-meta {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 0.9rem;
}

.dl-option .btn-row {
  justify-content: flex-start;
}

.dl-modal-foot {
  margin: 18px 0 0;
  text-align: center;
  font-size: 0.9rem;
  color: var(--muted);
}

.dl-modal-foot a {
  color: var(--accent);
}

body.dl-open {
  overflow: hidden;
}

/* Changelog tree */
.changelog-tree {
  list-style: none;
  margin: 0;
  padding: 0 0 0 18px;
  border-left: 2px solid rgba(var(--accent-rgb), 0.28);
}

.changelog-tree > li {
  position: relative;
  padding: 0 0 22px 20px;
}

.changelog-tree > li::before {
  content: "";
  position: absolute;
  left: -25px;
  top: 6px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid #ffffff;
}

.changelog-tree time {
  display: block;
  font-size: 0.8rem;
  color: var(--muted);
}

.changelog-tree strong a {
  text-decoration: none;
  color: var(--ink);
  font-family: var(--display);
  font-size: 1.2rem;
  font-weight: 400;
}

.changelog-title {
  color: var(--muted);
  font-family: var(--font);
  font-size: 0.95rem;
  font-weight: 500;
}

.changelog-body {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.changelog-body p {
  margin: 0 0 8px;
  white-space: pre-wrap;
}

.changelog-body h4,
.changelog-body h5 {
  margin: 12px 0 6px;
  color: var(--ink);
  font-size: 0.95rem;
  font-weight: 600;
}

.changelog-body ul {
  margin: 0 0 10px;
  padding-left: 1.2rem;
}

.changelog-body li {
  margin: 0 0 4px;
  padding: 0;
}

.changelog-body li::before {
  display: none;
}

.changelog-details {
  margin-top: 4px;
}

.changelog-details summary {
  cursor: pointer;
  list-style: none;
  color: var(--ink);
}

.changelog-details summary::-webkit-details-marker {
  display: none;
}

.changelog-details summary::before {
  content: "▸ ";
  color: var(--accent-2);
  font-size: 0.85em;
}

.changelog-details[open] summary::before {
  content: "▾ ";
}

.changelog-preview {
  color: var(--muted);
  font-weight: 400;
  font-size: 0.9rem;
}

.changelog-details .changelog-body {
  margin-top: 10px;
}

/* How-to scroll stack */
.howto-section {
  max-width: none;
  padding-left: 0;
  padding-right: 0;
}

.howto-intro {
  max-width: var(--max);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--pad);
  padding-right: var(--pad);
}

/* Important limits callout */
.limits-card {
  max-width: var(--max);
  margin: 28px auto 0;
  padding: 20px 22px;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 16px 18px;
  align-items: start;
  background: rgba(224, 122, 122, 0.1) !important;
  border: 1px solid rgba(224, 122, 122, 0.38);
  box-shadow:
    0 18px 40px rgba(0, 0, 0, 0.28),
    0 0 0 1px rgba(224, 122, 122, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.limits-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: #f0b4b4;
  background: rgba(224, 122, 122, 0.16);
  border: 1px solid rgba(224, 122, 122, 0.35);
  flex-shrink: 0;
}

.limits-kicker {
  margin: 0 0 4px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #f0b4b4;
}

.limits-body h3 {
  font-family: var(--display);
  font-weight: 400;
  font-size: 1.45rem;
  margin: 0 0 8px;
  color: var(--ink);
}

.limits-body p {
  margin: 0;
  color: #c9b0b0;
  font-size: 1rem;
  line-height: 1.55;
  max-width: 62ch;
}

@media (max-width: 640px) {
  .limits-card {
    grid-template-columns: 1fr;
    justify-items: start;
  }
}

.howto-stack {
  --steps: 9;
  position: relative;
  height: calc(var(--steps) * 95vh);
  margin-top: 12px;
}

.howto-pin {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 16px;
  padding: 24px var(--pad);
  box-sizing: border-box;
}

.howto-stage {
  position: relative;
  width: min(1040px, 100%);
  margin: 0 auto;
  height: min(540px, 68vh);
  perspective: 1200px;
}

.howto-card {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.15fr);
  gap: 0;
  padding: 0;
  overflow: hidden;
  transform-origin: center 85%;
  will-change: transform, opacity;
  /* Solid surface so stacked cards stay readable */
  background: #171c24 !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  border: 1px solid rgba(255, 255, 255, 0.14);
  transition: box-shadow 0.25s ease, border-color 0.25s ease;
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.howto-card.is-active {
  background: #1b222c !important;
  border-color: rgba(var(--accent-rgb), 0.35);
  box-shadow:
    0 28px 70px rgba(0, 0, 0, 0.55),
    0 0 0 1px rgba(var(--accent-rgb), 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.howto-card-copy {
  padding: clamp(18px, 3vw, 28px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  z-index: 1;
  background: #171c24;
}

.howto-card.is-active .howto-card-copy {
  background: #1b222c;
}

.howto-step {
  display: inline-flex;
  width: fit-content;
  margin-bottom: 10px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent-2);
  background: rgba(var(--accent-rgb), 0.14);
  border: 1px solid rgba(var(--accent-rgb), 0.28);
}

.howto-card-copy h3 {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(1.35rem, 2.4vw, 1.85rem);
  margin: 0 0 10px;
  color: var(--ink);
}

.howto-card-copy p {
  margin: 0;
  color: #b7c0ca;
  font-size: 0.98rem;
  max-width: 38ch;
}

.howto-shot {
  border: none;
  padding: 12px;
  margin: 0;
  background: #12161d;
  cursor: zoom-in;
  display: grid;
  place-items: center;
  border-left: 1px solid var(--line);
}

.howto-shot img {
  width: 100%;
  height: 100%;
  max-height: min(500px, 60vh);
  object-fit: contain;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #0e1116;
}

.howto-shot-static {
  cursor: default;
  border-left: 1px solid var(--line);
  background:
    radial-gradient(500px 280px at 70% 30%, rgba(var(--accent-rgb), 0.18), transparent 60%),
    rgba(0, 0, 0, 0.28);
}

.howto-install-visual {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
  color: var(--ink);
  text-align: left;
}

.howto-install-visual img {
  border-radius: 22px;
  box-shadow: var(--shadow);
}

.howto-install-visual ol {
  margin: 0;
  padding-left: 1.2rem;
  color: var(--muted);
  font-weight: 600;
}

.howto-chrome {
  width: min(1040px, 100%);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 16px;
}

.howto-counter {
  margin: 0;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  color: var(--ink);
}

.howto-dots {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  flex: 1;
}

.howto-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.12);
  padding: 0;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.howto-dot[aria-current="true"] {
  background: var(--accent);
  border-color: var(--accent-2);
  transform: scale(1.25);
}

.howto-hint {
  margin: 0;
  font-size: 0.82rem;
  color: var(--muted);
}

@media (max-width: 860px) {
  .howto-stack {
    height: auto;
  }

  .howto-pin {
    position: relative;
    height: auto;
    padding-top: 8px;
    padding-bottom: 8px;
  }

  .howto-stage {
    height: auto;
    display: flex;
    flex-direction: column;
    gap: 14px;
    perspective: none;
  }

  .howto-card {
    position: relative;
    inset: auto;
    transform: none !important;
    opacity: 1 !important;
    grid-template-columns: 1fr;
  }

  .howto-shot,
  .howto-shot-static {
    border-left: none;
    border-top: 1px solid var(--line);
    min-height: 200px;
  }

  .howto-chrome {
    position: sticky;
    bottom: 8px;
    z-index: 5;
    padding: 10px 12px;
    border-radius: 14px;
    background: rgba(12, 14, 18, 0.88);
    backdrop-filter: blur(12px);
    border: 1px solid var(--line);
  }
}

@media (prefers-reduced-motion: reduce) {
  .howto-stack {
    height: auto;
  }

  .howto-pin {
    position: relative;
    height: auto;
  }

  .howto-stage {
    height: auto;
    display: flex;
    flex-direction: column;
    gap: 14px;
  }

  .howto-card {
    position: relative;
    inset: auto;
    transform: none !important;
    opacity: 1 !important;
  }
}

/* FAQ */
.faq details {
  padding: 14px 18px;
  margin-bottom: 10px;
}

.faq summary {
  cursor: pointer;
  font-weight: 600;
  list-style: none;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq details p {
  margin: 10px 0 0;
  color: var(--muted);
}

/* Maker */
.maker {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 22px;
  align-items: start;
  padding: 24px;
}

.maker img {
  width: 140px;
  height: 140px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid rgba(255, 255, 255, 0.7);
  box-shadow: var(--shadow);
}

.maker h3 {
  font-family: var(--display);
  font-size: 1.7rem;
  margin: 0 0 4px;
  font-weight: 400;
}

.maker .role {
  color: var(--accent);
  margin: 0 0 12px;
  font-size: 0.95rem;
}

.workshop {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
  margin-top: 18px;
}

.workshop a {
  display: block;
  padding: 14px;
  text-decoration: none;
  color: inherit;
  transition: transform 0.18s ease;
}

.workshop a:hover {
  transform: translateY(-2px);
  color: inherit;
}

.workshop strong {
  display: block;
  margin-bottom: 4px;
}

.workshop span {
  color: var(--muted);
  font-size: 0.88rem;
}

/* Support band */
.support-band {
  padding: 28px;
  text-align: center;
}

/* Footer */
.site-footer {
  max-width: var(--max);
  margin: 0 auto;
  padding: 28px 0 48px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.9rem;
  display: flex;
  flex-wrap: wrap;
  gap: 12px 20px;
  justify-content: space-between;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 16px;
}

.site-footer a {
  color: var(--muted);
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--accent);
}

/* Lightbox */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 80;
  background: rgba(16, 24, 32, 0.78);
  padding: 24px;
  align-items: center;
  justify-content: center;
}

.lightbox.open {
  display: flex;
}

.lightbox img {
  max-height: min(88vh, 900px);
  max-width: min(96vw, 1200px);
  border-radius: 12px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.4);
}

.lightbox-close {
  position: absolute;
  top: 16px;
  right: 16px;
}

/* Reveal + section motion */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition:
    opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal.in {
  opacity: 1;
  transform: none;
}

.reveal-stagger > * {
  opacity: 0;
  transform: translateY(18px);
  transition:
    opacity 0.55s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal.in .reveal-stagger > *:nth-child(1) {
  transition-delay: 0.04s;
}
.reveal.in .reveal-stagger > *:nth-child(2) {
  transition-delay: 0.1s;
}
.reveal.in .reveal-stagger > *:nth-child(3) {
  transition-delay: 0.16s;
}
.reveal.in .reveal-stagger > *:nth-child(4) {
  transition-delay: 0.22s;
}
.reveal.in .reveal-stagger > *:nth-child(5) {
  transition-delay: 0.28s;
}
.reveal.in .reveal-stagger > *:nth-child(6) {
  transition-delay: 0.34s;
}
.reveal.in .reveal-stagger > *:nth-child(n + 7) {
  transition-delay: 0.4s;
}

.reveal.in .reveal-stagger > * {
  opacity: 1;
  transform: none;
}

.hero-mark {
  animation: mark-float 5.5s ease-in-out infinite;
}

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

.hero-visual {
  animation: glass-rise 1s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes glass-rise {
  from {
    opacity: 0;
    transform: translateY(28px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .ambient .orb,
  .hero-mark,
  .hero-visual {
    animation: none !important;
  }

  .reveal,
  .reveal-stagger > * {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .nav-indicator {
    transition: none !important;
  }

  .side-nav nav,
  .side-nav nav:hover,
  .btn,
  .btn:hover {
    transition: none !important;
    transform: none !important;
  }

  .btn::after {
    display: none;
  }

  .btn:hover,
  .compare article:hover,
  .feat:hover,
  .workshop a:hover {
    transform: none;
  }
}

.glass-svg {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

/* Static doc pages (privacy, security, windows) */
.doc-page {
  max-width: 760px;
  margin: 0 auto;
  padding: 40px 20px 80px;
}

.doc-back a {
  color: var(--accent);
}

.doc-title {
  font-family: var(--display);
  font-weight: 400;
  margin: 0 0 12px;
}

.doc-lede {
  margin: 0 0 8px;
}

.doc-card {
  padding: 24px;
  margin-top: 16px;
}

.doc-card .chip {
  margin-bottom: 10px;
}

.doc-steps {
  margin: 8px 0 0;
  padding-left: 1.2rem;
  color: var(--text);
}

.doc-steps li + li {
  margin-top: 6px;
}

.doc-note {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.doc-more {
  margin: 0;
  color: var(--muted);
}

.doc-more a {
  color: var(--accent);
}

/* Scroll to top with fluid ring + percent */
.scroll-top {
  position: fixed;
  right: max(16px, env(safe-area-inset-right));
  bottom: max(16px, env(safe-area-inset-bottom));
  z-index: 70;
  width: 56px;
  height: 56px;
  border: none;
  border-radius: 50%;
  padding: 0;
  cursor: pointer;
  color: var(--ink);
  background: rgba(18, 22, 28, 0.88);
  box-shadow:
    0 12px 30px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: grid;
  place-items: center;
  transition: transform 0.22s ease, opacity 0.22s ease, box-shadow 0.22s ease;
}

.scroll-top[hidden] {
  display: none !important;
}

.scroll-top:hover {
  transform: translateY(-3px) scale(1.04);
  box-shadow:
    0 16px 36px rgba(0, 0, 0, 0.4),
    0 0 24px rgba(var(--accent-rgb), 0.28);
}

.scroll-top-ring {
  position: absolute;
  inset: 0;
  width: 56px;
  height: 56px;
  transform: rotate(-90deg);
}

.scroll-top-track,
.scroll-top-progress {
  fill: none;
  stroke-width: 3.5;
}

.scroll-top-track {
  stroke: rgba(255, 255, 255, 0.12);
}

.scroll-top-progress {
  stroke: var(--accent);
  stroke-linecap: round;
  stroke-dasharray: 150.8;
  stroke-dashoffset: 150.8;
  transition: stroke-dashoffset 0.12s linear;
  filter: drop-shadow(0 0 6px rgba(var(--accent-rgb), 0.55));
}

.scroll-top-pct {
  position: relative;
  z-index: 1;
  font-size: 0.72rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
  color: var(--accent-2);
}

@media (prefers-reduced-motion: reduce) {
  .scroll-top,
  .scroll-top-progress {
    transition: none;
  }
}

/* Responsive */
@media (max-width: 980px) {
  .shell {
    grid-template-columns: 1fr;
  }

  .side-nav {
    display: none;
  }

  .topbar-mobile {
    display: flex;
  }

  .compare {
    grid-template-columns: 1fr;
  }

  .locks {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .audience-grid {
    grid-template-columns: 1fr;
  }

  .story-layout {
    grid-template-columns: 1fr;
  }

  .story-art {
    min-height: 200px;
    max-height: 260px;
    border-right: none;
    border-bottom: 1px solid var(--line);
  }

  .feat,
  .feat:nth-child(1),
  .feat:nth-child(2) {
    grid-column: span 6;
  }
}

@media (max-width: 640px) {
  .maker {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }

  .maker .btn-row {
    justify-content: center;
  }

  .locks {
    grid-template-columns: 1fr;
  }

  .feat,
  .feat:nth-child(1),
  .feat:nth-child(2) {
    grid-column: span 12;
  }

  .shot {
    flex-basis: 88vw;
  }

  .hero-mark {
    width: 72px;
    height: 72px;
  }

  .btn-row {
    justify-content: center;
  }

  .download-grid,
  .dl-modal-grid {
    grid-template-columns: 1fr;
  }

  .dl-modal-panel {
    padding: 22px 18px 18px;
    max-height: min(92vh, 900px);
    overflow: auto;
  }
}
