/* Pointerkeep. Locked dark theme: near-black zinc surfaces, one lime accent.
   The artwork (cursor thumbnails) carries the color; the chrome stays quiet. */

@font-face {
  font-family: "Space Grotesk";
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url("/assets/fonts/space-grotesk-latin.woff2") format("woff2");
}

:root {
  --bg: #0c0c0e;
  --surface: #141417;
  --surface-2: #1b1b1f;
  --border: #26262c;
  --border-strong: #35353d;
  --text: #ececef;
  --text-dim: #9c9ca6;
  --text-faint: #6d6d78;
  --accent: #bef264;
  --accent-ink: #16200a;
  --radius: 10px;
  --display: "Space Grotesk", system-ui, sans-serif;
  --body: system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: ui-monospace, "Cascadia Mono", "JetBrains Mono", monospace;
}

* { box-sizing: border-box; }

html { color-scheme: dark; }

body {
  margin: 0;
  background:
    radial-gradient(ellipse 900px 420px at 70% -80px,
      rgb(190 242 100 / .055), transparent 70%),
    radial-gradient(#161619 1px, transparent 1.5px) 0 0 / 26px 26px,
    var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

img { max-width: 100%; }

/* ------------------------------------------------------------------ icons */

.icon {
  display: inline-block;
  width: 16px;
  height: 16px;
  background: currentColor;
  mask-size: contain;
  mask-repeat: no-repeat;
  mask-position: center;
  -webkit-mask-size: contain;
  -webkit-mask-repeat: no-repeat;
  -webkit-mask-position: center;
  flex: none;
}
.icon-search   { mask-image: url(/assets/icons/magnifying-glass.svg); -webkit-mask-image: url(/assets/icons/magnifying-glass.svg); }
.icon-download { mask-image: url(/assets/icons/download-simple.svg);  -webkit-mask-image: url(/assets/icons/download-simple.svg); }
.icon-star     { mask-image: url(/assets/icons/star-fill.svg);        -webkit-mask-image: url(/assets/icons/star-fill.svg); }
.icon-back     { mask-image: url(/assets/icons/arrow-left.svg);       -webkit-mask-image: url(/assets/icons/arrow-left.svg); }
.icon-tag      { mask-image: url(/assets/icons/tag.svg);              -webkit-mask-image: url(/assets/icons/tag.svg); }
.icon-x        { mask-image: url(/assets/icons/x.svg);                -webkit-mask-image: url(/assets/icons/x.svg); }
.icon-click    { mask-image: url(/assets/icons/cursor-click.svg);     -webkit-mask-image: url(/assets/icons/cursor-click.svg); }
.icon-film     { mask-image: url(/assets/icons/film-strip.svg);       -webkit-mask-image: url(/assets/icons/film-strip.svg); }

/* -------------------------------------------------------------------- nav */

.nav {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 20px;
  height: 64px;
  padding: 0 24px;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--display);
  font-weight: 600;
  font-size: 17px;
  letter-spacing: -0.02em;
  text-decoration: none;
  flex: none;
}

.nav-mark {
  width: 22px;
  height: 22px;
  background: var(--accent);
  mask-image: url(/assets/icons/cursor-click.svg);
  -webkit-mask-image: url(/assets/icons/cursor-click.svg);
  mask-size: contain;
  -webkit-mask-size: contain;
}

.nav-search {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  max-width: 420px;
  padding: 0 12px;
  height: 38px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text-dim);
  transition: border-color .2s;
}
.nav-search:focus-within { border-color: var(--border-strong); color: var(--text); }
.nav-search input {
  flex: 1;
  min-width: 0;
  background: none;
  border: 0;
  outline: 0;
  color: var(--text);
  font: inherit;
}
.nav-search input::placeholder { color: var(--text-faint); }

.nav-links {
  margin-left: auto;
  display: flex;
  gap: 4px;
}
.nav-links a {
  padding: 7px 14px;
  border-radius: 999px;
  text-decoration: none;
  color: var(--text-dim);
  font-weight: 500;
  transition: color .15s, background .15s;
}
.nav-links a:hover { color: var(--text); background: var(--surface-2); }
.nav-links a.active { color: var(--text); background: var(--surface-2); }

/* ------------------------------------------------------------------- view */

.view {
  max-width: 1280px;
  margin: 0 auto;
  padding: 28px 24px 80px;
  min-height: 70vh;
}

.page-head { margin: 8px 0 22px; }
.page-head h1 {
  font-family: var(--display);
  font-size: clamp(26px, 4vw, 38px);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin: 0 0 6px;
}
.page-head .sub { color: var(--text-dim); margin: 0; max-width: 62ch; }
.page-head .sub strong { color: var(--text); font-weight: 600; }

/* ---------------------------------------------------------------- toolbar */

.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-bottom: 20px;
}

.toolbar select {
  appearance: none;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 999px;
  padding: 8px 32px 8px 14px;
  font: inherit;
  font-size: 14px;
  cursor: pointer;
  background-image: linear-gradient(45deg, transparent 50%, var(--text-dim) 50%),
                    linear-gradient(135deg, var(--text-dim) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%;
  background-size: 5px 5px;
  background-repeat: no-repeat;
}
.toolbar select:hover { border-color: var(--border-strong); }

.toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 14px;
  color: var(--text-dim);
  cursor: pointer;
  user-select: none;
  transition: color .15s, border-color .15s;
}
.toggle:hover { border-color: var(--border-strong); }
.toggle input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.toggle.on {
  color: var(--accent-ink);
  background: var(--accent);
  border-color: var(--accent);
  font-weight: 600;
}

.chip-clear {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  color: var(--text);
  font-size: 14px;
  cursor: pointer;
}
.chip-clear:hover { border-color: var(--text-faint); }

.result-count {
  margin-left: auto;
  color: var(--text-faint);
  font-family: var(--mono);
  font-size: 13px;
}

/* ------------------------------------------------------------------- grid */

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(275px, 1fr));
  gap: 16px;
}

.card {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  text-decoration: none;
  transition: border-color .15s, transform .15s;
}
.card:hover { border-color: var(--border-strong); transform: translateY(-2px); }
.card:active { transform: translateY(0) scale(0.99); }

.card-thumb {
  aspect-ratio: 4 / 3;
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(ellipse at 50% 120%, #1d1d22 0%, transparent 70%),
    var(--surface-2);
  padding: 20px;
}
.card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  /* Cursor art is pixel art; upscale it crisp instead of blurry. */
  image-rendering: pixelated;
  filter: drop-shadow(0 4px 10px rgb(0 0 0 / .45));
}
.card-thumb .no-thumb {
  width: 34px; height: 34px;
  color: var(--text-faint);
}

.card-body { padding: 12px 14px 13px; }
.card-name {
  font-family: var(--display);
  font-weight: 500;
  font-size: 15px;
  letter-spacing: -0.01em;
  line-height: 1.25;
  margin: 0 0 7px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.card-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px 12px;
  color: var(--text-faint);
  font-size: 12.5px;
  font-family: var(--mono);
}
.card-meta .m { display: inline-flex; align-items: center; gap: 5px; }
.card-meta .icon { width: 13px; height: 13px; }
.card-meta .m-rating { color: var(--text-dim); }
.badge-ani {
  margin-left: auto;
  padding: 2px 8px;
  border-radius: 999px;
  border: 1px solid var(--border-strong);
  color: var(--text-dim);
  font-size: 11px;
  letter-spacing: .02em;
}

/* skeletons */
.card.skel { pointer-events: none; }
.skel .card-thumb, .skel .sk-line {
  position: relative;
  overflow: hidden;
  background: var(--surface-2);
}
.sk-line { height: 13px; border-radius: 6px; margin: 4px 14px; }
.sk-line.short { width: 55%; margin-bottom: 14px; }
@media (prefers-reduced-motion: no-preference) {
  .skel .card-thumb::after, .sk-line::after {
    content: "";
    position: absolute;
    inset: 0;
    transform: translateX(-100%);
    background: linear-gradient(90deg, transparent, rgb(255 255 255 / .04), transparent);
    animation: shimmer 1.4s infinite;
  }
  @keyframes shimmer { to { transform: translateX(100%); } }
}

/* load more + states */
.load-wrap { display: flex; justify-content: center; padding: 30px 0 6px; }
.btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 11px 22px;
  border-radius: 999px;
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-weight: 600;
  font-size: 14.5px;
  cursor: pointer;
  text-decoration: none;
  transition: border-color .15s, transform .1s, background .15s;
}
.btn:hover { border-color: var(--text-faint); }
.btn:active { transform: translateY(1px); }
.btn-accent {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}
.btn-accent:hover { background: #cdf87e; border-color: #cdf87e; }

.state {
  padding: 70px 20px;
  text-align: center;
  color: var(--text-dim);
}
.state h2 {
  font-family: var(--display);
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--text);
  margin: 0 0 8px;
}
.state p { margin: 0 0 18px; }

/* ------------------------------------------------------------ pack detail */

.crumb {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--text-dim);
  text-decoration: none;
  font-size: 14px;
  margin-bottom: 18px;
}
.crumb:hover { color: var(--text); }

.pack-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 36px;
  align-items: start;
  margin-bottom: 20px;
}
.pack-main { min-width: 0; container-type: inline-size; }
.pack-main .pack-title { margin-bottom: 30px; }

.pack-title h1 {
  font-family: var(--display);
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.08;
  margin: 0 0 10px;
}
.pack-byline { color: var(--text-dim); margin: 0 0 16px; }
.pack-byline a { color: var(--text); text-decoration-color: var(--text-faint); }

.pack-desc { color: var(--text-dim); max-width: 64ch; margin: 0 0 18px; white-space: pre-line; }

.pack-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}
.fact {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text-dim);
  font-size: 13px;
}
.fact .icon { width: 14px; height: 14px; }
.fact b { color: var(--text); font-weight: 600; }

.pack-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.pack-actions .size { color: var(--text-faint); font-size: 13px; font-family: var(--mono); }

.pack-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.tag-chip {
  padding: 5px 12px;
  border-radius: 999px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text-dim);
  font-size: 13px;
  text-decoration: none;
}
.tag-chip:hover { color: var(--text); border-color: var(--border-strong); }

/* try bar — one horizontal strip sitting on top of the cursor list. Left half
   names the one cursor being previewed, and it only changes when you pick a
   different card; right half is the only place the pointer is swapped. */
.trybar {
  display: flex;
  align-items: stretch;
  gap: 16px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 14px;
  margin: 0 0 18px;
  transition: border-color .15s;
}
.trybar.live { border-color: var(--accent); }
/* One pulse when the selection changes, so a click on a far-away card is
   visibly answered up here. */
@keyframes trybar-pulse {
  from { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 20%, transparent); }
  to { box-shadow: 0 0 0 3px transparent; }
}
.trybar.pulse { animation: trybar-pulse .55s ease-out; }
@media (prefers-reduced-motion: reduce) { .trybar.pulse { animation: none; } }

.trybar-now {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: none;
  width: 400px;
  padding-right: 16px;
  border-right: 1px solid var(--border);
}
.trybar-chip {
  flex: none;
  width: 72px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface-2);
  border: 1px solid var(--accent);
  border-radius: 10px;
}
.trybar-read { flex: 1; min-width: 0; }
.trybar-steps { display: flex; gap: 6px; flex: none; }
.trybar-step {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: var(--surface-2);
  color: var(--text-dim);
  font: inherit;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
}
.trybar-step:hover { color: var(--text); border-color: var(--border-strong); }
.trybar-name { margin: 0; color: var(--text-dim); font-size: 14px; line-height: 1.4; }
.trybar-name b { color: var(--text); font-weight: 600; }
.trybar-file {
  margin: 3px 0 0;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--text-faint);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.trybar-stage {
  position: relative;
  flex: 1;
  min-width: 0;
  cursor: none;
  border: 1px dashed var(--border-strong);
  border-radius: 10px;
  background: var(--surface-2);
  padding: 14px;
  display: flex;
  align-items: stretch;
  gap: 10px;
  min-height: 92px;
  transition: border-color .15s;
}
.trybar.live .trybar-stage { border-color: var(--accent); border-style: solid; }
/* Legend riding the stage border, so the live area reads as a fenced zone. */
.trybar-tag {
  position: absolute;
  top: -9px;
  left: 14px;
  padding: 0 7px;
  background: var(--surface);
  color: var(--text-faint);
  font-family: var(--mono);
  font-size: 11.5px;
}
.trybar.live .trybar-tag { color: var(--accent); }
.trybar-stage, .trybar-stage * { cursor: none; }
/* Three backdrops: the same cursor against dark, light and a pattern, so you
   can judge it without the preview ever changing under you. */
.try-panel { flex: 1; min-width: 0; border-radius: 8px; }
.try-panel.dark { background: #08080a; border: 1px solid var(--border); }
.try-panel.light { background: #ececed; }
.try-panel.checker {
  background-color: #7c7c88;
  background-image:
    linear-gradient(45deg, #43434d 25%, transparent 25%, transparent 75%, #43434d 75%),
    linear-gradient(45deg, #43434d 25%, transparent 25%, transparent 75%, #43434d 75%);
  background-size: 16px 16px;
  background-position: 0 0, 8px 8px;
}
.ghost-cursor {
  height: 48px;
  width: auto;
  image-rendering: pixelated;
  pointer-events: none;
  filter: drop-shadow(0 3px 6px rgb(0 0 0 / .5));
}
.ghost-cursor.idle { height: 46px; max-width: 60px; object-fit: contain; }
.ghost-cursor.follow {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 40;
}
/* Stack the two halves when the bar itself runs out of room — a squeezed
   main column beside the sidebar, or a narrow screen. */
@container (max-width: 660px) {
  .trybar { flex-direction: column; gap: 14px; }
  .trybar-now {
    width: auto;
    padding: 0 0 14px;
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }
}
@media (max-width: 720px) {
  .trybar { flex-direction: column; gap: 14px; }
  .trybar-now {
    width: auto;
    padding: 0 0 14px;
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }
}
/* cursor slots */
.slots-headrow {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin: 0 0 14px;
}
.slots-head {
  font-family: var(--display);
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 0;
}
.slots-hint { margin: 0; color: var(--text-faint); font-size: 13px; }
.slots {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
}
.slot {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 14px 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: border-color .15s, transform .15s;
}
.slot:hover { border-color: var(--border-strong); transform: translateY(-2px); }
/* The one card the bar is previewing. Hover never moves this — only a click. */
.slot.selected {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent);
}
.slot.selected .slot-img { background: color-mix(in srgb, var(--accent) 9%, var(--surface-2)); }
.slot-flag {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
  font-family: var(--mono);
  font-size: 10.5px;
  display: none;
}
.slot.selected .slot-flag { display: block; }
.slot-img {
  height: 84px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface-2);
  border-radius: 8px;
  padding: 10px;
}
.slot-img img {
  height: 100%;
  width: 100%;
  object-fit: contain;
  image-rendering: pixelated;
}
.slot-role {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--text);
  text-align: center;
}
.slot-file {
  font-size: 11.5px;
  color: var(--text-faint);
  text-align: center;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.slot-dl {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  color: var(--text-dim);
  text-decoration: none;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
}
.slot-dl:hover { color: var(--text); border-color: var(--border-strong); }
.slot-dl .icon { width: 12px; height: 12px; }

/* -------------------------------------------------------------- tag cloud */

.cloud { display: flex; flex-wrap: wrap; gap: 10px; }
.cloud a {
  display: inline-flex;
  align-items: baseline;
  gap: 7px;
  padding: 8px 16px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
  text-decoration: none;
  color: var(--text);
  transition: border-color .15s, transform .15s;
}
.cloud a:hover { border-color: var(--accent); transform: translateY(-1px); }
.cloud .n { color: var(--text-faint); font-family: var(--mono); font-size: 12px; }
.cloud .s3 { font-size: 19px; font-weight: 600; font-family: var(--display); }
.cloud .s2 { font-size: 16px; font-weight: 500; }
.cloud .s1 { font-size: 14px; }

/* ----------------------------------------------------------------- footer */

.footer {
  border-top: 1px solid var(--border);
  padding: 40px 24px 48px;
  color: var(--text-faint);
  font-size: 13.5px;
  background: color-mix(in srgb, var(--bg) 60%, var(--surface));
}
.footer-cols {
  max-width: 1280px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.4fr;
  gap: 32px;
}
.footer-col h3 {
  font-family: var(--display);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin: 0 0 10px;
}
.footer-col a {
  display: block;
  color: var(--text-dim);
  text-decoration: none;
  padding: 3px 0;
}
.footer-col a:hover { color: var(--text); }
.footer-col p { margin: 0; line-height: 1.6; }
.footer-about p { margin-top: 10px; }
.footer-about a { display: inline; color: var(--text-dim); }
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--display);
  font-weight: 600;
  font-size: 15px;
  color: var(--text);
}
.footer-brand .nav-mark { width: 18px; height: 18px; }

@media (max-width: 860px) {
  .footer-cols { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
  .footer-cols { grid-template-columns: 1fr; }
}

/* ----------------------------------------------------------------- mobile */

@media (max-width: 860px) {
  /* One column. The download card would land below every slot, so lift the
     sidebar between the pack info and the try bar. */
  /* align-items:start from the grid layout would shrink every row to its
     content width once the cross axis turns horizontal. */
  .pack-layout { display: flex; flex-direction: column; align-items: stretch; gap: 20px; }
  .pack-main { display: contents; }
  .pack-main .pack-title { order: 0; margin-bottom: 0; }
  .pack-side { order: 1; }
  .pack-main .trybar { order: 2; margin-bottom: 0; }
  .pack-main .slots-headrow { order: 3; }
  .pack-main .slots { order: 4; }
}

@media (max-width: 640px) {
  .nav { gap: 12px; padding: 0 14px; }
  .nav-links a { padding: 7px 10px; }
  .view { padding: 20px 14px 60px; }
  .grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; }
  .result-count { display: none; }
}

@media (max-width: 520px) {
  .nav { flex-wrap: wrap; height: auto; padding: 10px 14px; }
  .nav-search { order: 3; max-width: none; flex-basis: 100%; }
}

/* ------------------------------------------------------------------- hero */

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 40px;
  align-items: center;
  padding: 40px 0 56px;
}
.hero-copy h1 {
  font-family: var(--display);
  font-size: clamp(34px, 5vw, 56px);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.04;
  margin: 0 0 14px;
}
.hero-sub {
  color: var(--text-dim);
  font-size: 17px;
  max-width: 46ch;
  margin: 0 0 22px;
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.hero-stats {
  display: flex;
  gap: 34px;
  margin: 30px 0 0;
  padding-top: 22px;
  border-top: 1px solid var(--border);
  flex-wrap: wrap;
}
.hero-stats div { display: flex; flex-direction: column-reverse; }
.hero-stats dt { color: var(--text-faint); font-size: 12.5px; }
.hero-stats dd {
  margin: 0;
  font-family: var(--display);
  font-weight: 600;
  font-size: 26px;
  letter-spacing: -0.02em;
}

.hero-collage {
  position: relative;
  height: 420px;
}
.collage-item {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 12px;
  box-shadow: 0 12px 34px rgb(0 0 0 / .4);
  transition: border-color .2s, transform .2s;
}
.collage-item:hover { border-color: var(--accent); }
.collage-item img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  image-rendering: pixelated;
}
.collage-item:nth-child(1) { width: 190px; height: 140px; left: 6%;  top: 4%;   rotate: -4deg; }
.collage-item:nth-child(2) { width: 150px; height: 110px; left: 56%; top: 0;    rotate: 3deg; }
.collage-item:nth-child(3) { width: 170px; height: 125px; left: 30%; top: 30%;  rotate: 1deg; z-index: 2; }
.collage-item:nth-child(4) { width: 135px; height: 100px; left: 74%; top: 27%;  rotate: -3deg; }
.collage-item:nth-child(5) { width: 155px; height: 115px; left: 4%;  top: 46%;  rotate: 2deg; }
.collage-item:nth-child(6) { width: 175px; height: 130px; left: 52%; top: 55%;  rotate: -2deg; }
.collage-item:nth-child(7) { width: 130px; height: 95px;  left: 26%; top: 72%;  rotate: 4deg; }
.collage-item:nth-child(8) { width: 120px; height: 90px;  left: 82%; top: 66%;  rotate: -5deg; }
.collage-item:nth-child(9) { width: 105px; height: 80px;  left: 0;   top: 82%;  rotate: 3deg; }

@media (prefers-reduced-motion: no-preference) {
  .collage-item { animation: drift 7s ease-in-out infinite alternate; }
  .collage-item:nth-child(2n)  { animation-duration: 8.5s; animation-delay: -2s; }
  .collage-item:nth-child(3n)  { animation-duration: 9.5s; animation-delay: -4s; }
  .collage-item:nth-child(3n+1){ animation-delay: -6s; }
  @keyframes drift {
    from { transform: translateY(-6px); }
    to   { transform: translateY(8px); }
  }
}

@media (max-width: 960px) {
  .hero { grid-template-columns: 1fr; padding-top: 16px; }
  .hero-collage { display: none; }
}

/* ------------------------------------------------------------------ tiles */

.tiles-section { margin: 10px 0 8px; }
.tiles {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}
.tile {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 16px 12px 12px;
  text-decoration: none;
  transition: border-color .15s, transform .15s;
}
.tile:hover { border-color: var(--accent); transform: translateY(-2px); }
.tile-collage {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  width: 68px;
  flex: none;
}
.tile-collage img {
  width: 32px;
  height: 32px;
  object-fit: contain;
  background: var(--surface-2);
  border-radius: 6px;
  padding: 3px;
}
.tile-label { display: flex; flex-direction: column; min-width: 0; }
.tile-name {
  font-family: var(--display);
  font-weight: 600;
  font-size: 15.5px;
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.tile-count { color: var(--text-faint); font-size: 12.5px; font-family: var(--mono); }

@media (max-width: 960px) { .tiles { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .tiles { grid-template-columns: 1fr; } }

/* ------------------------------------------------------------------- rails */

.rail { margin: 40px 0; }
.rail-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}
.rail-head h2 {
  font-family: var(--display);
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 0;
}
.rail-more {
  color: var(--text-dim);
  font-size: 14px;
  text-decoration: none;
  border-bottom: 1px solid var(--border-strong);
  padding-bottom: 1px;
}
.rail-more:hover { color: var(--accent); border-color: var(--accent); }
.grid-rail {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.grid-rail .card:nth-child(n+9) { display: none; }
@media (max-width: 1100px) {
  .grid-rail { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .grid-rail .card:nth-child(n+7) { display: none; }
}
@media (max-width: 860px) {
  .grid-rail { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-rail .card:nth-child(n+5) { display: none; }
}

/* ------------------------------------------------------------ about split */

.about-split {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  gap: 40px;
  margin: 56px 0 20px;
  padding: 34px 0 0;
  border-top: 1px solid var(--border);
}
.about-text h2 {
  font-family: var(--display);
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 0 0 12px;
}
.about-text p { color: var(--text-dim); max-width: 62ch; margin: 0 0 12px; }
.about-text a { color: var(--text); }
.about-licenses h3 {
  font-family: var(--display);
  font-size: 15px;
  font-weight: 600;
  margin: 4px 0 12px;
}
.license-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 14px;
  margin-bottom: 8px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  text-decoration: none;
  color: var(--text-dim);
  font-size: 13.5px;
  transition: border-color .15s;
}
.license-row:hover { border-color: var(--border-strong); color: var(--text); }
.license-count { font-family: var(--mono); color: var(--text-faint); }
@media (max-width: 860px) { .about-split { grid-template-columns: 1fr; gap: 24px; } }

/* ------------------------------------------------------------ breadcrumbs */

.crumbs {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  color: var(--text-faint);
  font-size: 13.5px;
  margin-bottom: 18px;
}
.crumbs a { color: var(--text-dim); text-decoration: none; }
.crumbs a:hover { color: var(--text); }
.crumb-sep { color: var(--text-faint); }
.crumb-here {
  color: var(--text-faint);
  max-width: 40ch;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* -------------------------------------------------------------- pagination */

.pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
  margin: 34px 0 8px;
}
.pager-num, .pager-arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 12px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-dim);
  text-decoration: none;
  font-size: 14px;
  font-family: var(--mono);
}
.pager-arrow { font-family: var(--body); }
.pager-num:hover, .pager-arrow:hover { border-color: var(--border-strong); color: var(--text); }
.pager-num.current {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
  font-weight: 700;
}
.pager-gap { color: var(--text-faint); padding: 0 2px; }

/* --------------------------------------------------------- pack side card */

.pack-side {
  display: flex;
  flex-direction: column;
  gap: 16px;
  position: sticky;
  top: 84px;
}
@media (max-width: 860px) {
  .pack-side { position: static; }
}
.side-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.side-thumb {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface-2);
  border-radius: 8px;
  padding: 16px;
  min-height: 120px;
}
.side-thumb img { max-height: 130px; width: auto; max-width: 100%; object-fit: contain; }
.btn-block { justify-content: center; width: 100%; }
.side-meta {
  margin: 0;
  text-align: center;
  color: var(--text-faint);
  font-family: var(--mono);
  font-size: 12.5px;
}
.side-license { margin: 0; color: var(--text-dim); font-size: 13.5px; }
.side-license a { color: var(--text); }
.side-source {
  color: var(--text-faint);
  font-size: 13px;
  text-decoration: none;
  border-bottom: 1px solid var(--border-strong);
  align-self: flex-start;
}
.side-source:hover { color: var(--text); }

.chip-n { color: var(--text-faint); font-family: var(--mono); font-size: 11.5px; }
.siblings { margin-top: 40px; }
.siblings h2 {
  font-family: var(--display);
  font-size: 18px;
  font-weight: 600;
  margin: 0 0 12px;
}

/* ------------------------------------------------------------------ guide */

.guide { max-width: 760px; }
.steps {
  list-style: none;
  counter-reset: step;
  margin: 26px 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.step {
  counter-increment: step;
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px 18px 66px;
}
.step::before {
  content: counter(step);
  position: absolute;
  left: 18px;
  top: 18px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--accent);
  color: var(--accent-ink);
  font-family: var(--display);
  font-weight: 700;
  font-size: 15px;
}
.step h2 {
  font-family: var(--display);
  font-size: 17px;
  font-weight: 600;
  margin: 4px 0 6px;
}
.step p { margin: 0; color: var(--text-dim); }

.guide-tip {
  border: 1px solid var(--border-strong);
  border-left: 3px solid var(--accent);
  border-radius: 8px;
  padding: 16px 20px;
  margin: 26px 0;
}
.guide-tip h2 { font-family: var(--display); font-size: 16px; margin: 0 0 6px; }
.guide-tip p { margin: 0; color: var(--text-dim); }
.guide-tip code {
  font-family: var(--mono);
  background: var(--surface-2);
  padding: 1px 6px;
  border-radius: 5px;
  font-size: 13px;
}

.faq { margin: 36px 0; }
.faq h2 {
  font-family: var(--display);
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 0 0 14px;
}
.faq details {
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  margin-bottom: 8px;
  padding: 0 18px;
}
.faq summary {
  cursor: pointer;
  padding: 14px 0;
  font-weight: 600;
  font-family: var(--display);
  font-size: 15px;
  list-style: none;
  position: relative;
  padding-right: 28px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  position: absolute;
  right: 2px;
  top: 50%;
  translate: 0 -50%;
  color: var(--text-faint);
  font-size: 19px;
}
.faq details[open] summary::after { content: "-"; }
.faq details p { margin: 0 0 16px; color: var(--text-dim); }

.guide-cta {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 22px 0 0;
  border-top: 1px solid var(--border);
}
.guide-cta p { margin: 0; font-family: var(--display); font-weight: 600; font-size: 17px; }

.state-tall { padding: 120px 20px; }

/* ---------------------------------------------------------------- marquee */

.marquee {
  overflow: hidden;
  margin: 0 0 40px;
  padding: 14px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
}
.marquee-track {
  display: flex;
  gap: 14px;
  width: max-content;
}
.marquee-item {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 96px;
  height: 68px;
  flex: none;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 8px;
  transition: border-color .15s;
}
.marquee-item:hover { border-color: var(--accent); }
.marquee-item img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  image-rendering: pixelated;
}
@media (prefers-reduced-motion: no-preference) {
  .marquee-track {
    animation: marquee 45s linear infinite;
  }
  .marquee:hover .marquee-track { animation-play-state: paused; }
  @keyframes marquee {
    to { transform: translateX(-50%); }
  }
}
@media (prefers-reduced-motion: reduce) {
  .marquee { overflow-x: auto; }
}
