/* HighApps Blog. Standalone editorial design: shares only the brand font (Outfit), the
   brand blue and the logo with the studio site. Light and dark themes. */

:root {
  --paper: #fbfaf6;
  --paper-2: #f2f0e8;
  --card: #ffffff;
  --ink: #14161c;
  --ink-2: #353a46;
  --muted: #6a6f7d;
  --rule: #e5e1d5;
  --accent: #1c54e3;
  --accent-2: #1645c2;
  --accent-soft: rgba(28, 84, 227, 0.09);
  --on-accent: #ffffff;
  --mark: #ffd84c;
  --code-bg: #10141d;
  --code-head: #161b27;
  --code-ink: #dde3f1;
  --shadow: 0 20px 50px rgba(20, 22, 28, 0.1);
  --display: "Outfit", "Helvetica Neue", Arial, sans-serif;
  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --max: 1180px;
  --measure: 41rem;
  --bar: 64px;
  color-scheme: light;
}

:root[data-theme="dark"] {
  --paper: #0c0e13;
  --paper-2: #13161e;
  --card: #141822;
  --ink: #eef0f5;
  --ink-2: #c6cbd8;
  --muted: #8c93a5;
  --rule: #242a37;
  --accent: #7ea4ff;
  --accent-2: #a6c0ff;
  --accent-soft: rgba(126, 164, 255, 0.12);
  --on-accent: #0c0e13;
  --shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
  color-scheme: dark;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #0c0e13;
    --paper-2: #13161e;
    --card: #141822;
    --ink: #eef0f5;
    --ink-2: #c6cbd8;
    --muted: #8c93a5;
    --rule: #242a37;
    --accent: #7ea4ff;
    --accent-2: #a6c0ff;
    --accent-soft: rgba(126, 164, 255, 0.12);
  --on-accent: #0c0e13;
    --shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
    color-scheme: dark;
  }
}

*,
*::before,
*::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--bar) + 16px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--display);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  transition: background-color 0.25s, color 0.25s;
}
img, video { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); }
::selection { background: var(--mark); color: #14161c; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

.skip { position: absolute; left: -999px; }
.skip:focus { left: 12px; top: 12px; z-index: 100; background: var(--accent); color: var(--on-accent); padding: 8px 12px; border-radius: 8px; }

.container { width: min(var(--max), calc(100% - 40px)); margin: 0 auto; }

/* ---------- Masthead ---------- */
.bar {
  position: sticky;
  top: 0;
  z-index: 30;
  height: var(--bar);
  background: color-mix(in srgb, var(--paper) 86%, transparent);
  backdrop-filter: saturate(1.4) blur(14px);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid var(--rule);
}
.bar-inner { height: 100%; display: flex; align-items: center; gap: 20px; }
.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ink);
  font-weight: 700;
  font-size: 1.08rem;
  letter-spacing: -0.02em;
}
.wordmark img { width: 32px; height: 32px; }
.wordmark .slash { color: var(--muted); font-weight: 400; }
.wordmark .studio { color: var(--muted); font-weight: 500; }
.bar-topics { display: flex; gap: 4px; margin-left: 12px; }
.bar-topics a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.93rem;
  font-weight: 500;
  padding: 6px 10px;
  border-radius: 8px;
}
.bar-topics a:hover { color: var(--ink); background: var(--paper-2); }
.bar-end { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--ink-2);
  cursor: pointer;
  text-decoration: none;
}
.icon-btn:hover { background: var(--paper-2); border-color: var(--rule); color: var(--ink); }
.icon-btn svg { width: 19px; height: 19px; }
.theme-toggle .moon { display: none; }
:root[data-theme="dark"] .theme-toggle .sun { display: none; }
:root[data-theme="dark"] .theme-toggle .moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .sun { display: none; }
  :root:not([data-theme="light"]) .theme-toggle .moon { display: block; }
}
.studio-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: 6px;
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--paper);
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 600;
}
.studio-link:hover { background: var(--accent); color: var(--on-accent); }

.progress { position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; }
.progress span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--mark));
  transform-origin: 0 50%;
  transform: scaleX(0);
}

/* ---------- Shared bits ---------- */
.eyebrow {
  font-family: var(--mono);
  font-size: 0.76rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.topic {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--accent);
  text-decoration: none;
}
.topic + .topic::before { content: "·"; color: var(--muted); margin: 0 8px; }
.meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 0; color: var(--muted); font-size: 0.9rem; }
.meta > * + *::before { content: "·"; margin: 0 9px; }
.mark {
  background: linear-gradient(transparent 62%, var(--mark) 62%, var(--mark) 90%, transparent 90%);
  padding: 0 0.06em;
}
:root[data-theme="dark"] .mark { color: var(--ink); background: linear-gradient(transparent 62%, rgba(255, 216, 76, 0.45) 62%, rgba(255, 216, 76, 0.45) 90%, transparent 90%); }
.arrow-link { font-weight: 600; color: var(--accent); text-decoration: none; }
.arrow-link::after { content: "→"; display: inline-block; margin-left: 6px; transition: transform 0.2s; }
.arrow-link:hover::after { transform: translateX(4px); }
.pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 18px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.93rem;
  text-decoration: none;
  background: var(--accent);
  color: var(--on-accent);
  border: 1px solid transparent;
}
.pill-btn:hover { background: var(--accent-2); }
.pill-btn.ghost { background: transparent; color: var(--ink); border-color: var(--rule); }
.pill-btn.ghost:hover { border-color: var(--ink); }
.prose .pill-btn { color: var(--on-accent); text-decoration: none; }
.prose .pill-btn.ghost { color: var(--ink); }
.pill-btn svg { width: 17px; height: 17px; }

/* ---------- Listing ---------- */
.intro {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 20rem);
  align-items: end;
  gap: 24px 56px;
  padding: 72px 0 44px;
  border-bottom: 1px solid var(--rule);
}
.intro h1 {
  font-size: clamp(2.8rem, 7.6vw, 6rem);
  line-height: 0.95;
  letter-spacing: -0.05em;
  font-weight: 700;
  margin: 14px 0 0;
}
.intro-side { font-family: var(--serif); font-size: 1.12rem; line-height: 1.6; color: var(--ink-2); }
.intro-side p { margin: 0 0 18px; }

.lead-story {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  gap: 40px;
  align-items: center;
  padding: 48px 0;
  text-decoration: none;
  color: inherit;
  border-bottom: 1px solid var(--rule);
}
.lead-story .shot {
  border-radius: 20px;
  overflow: hidden;
  background: var(--paper-2);
  box-shadow: var(--shadow);
}
.lead-story .shot img { width: 100%; aspect-ratio: 1200 / 630; object-fit: cover; transition: transform 0.6s cubic-bezier(.2, .7, .2, 1); }
.lead-story:hover .shot img { transform: scale(1.035); }
.lead-story h2 {
  font-size: clamp(1.8rem, 3.4vw, 2.7rem);
  line-height: 1.06;
  letter-spacing: -0.035em;
  margin: 12px 0 16px;
}
.lead-story:hover h2 { color: var(--accent); }
.lead-story p { font-family: var(--serif); font-size: 1.12rem; line-height: 1.6; color: var(--ink-2); margin: 0 0 20px; }
.lead-story .meta { margin-bottom: 22px; }
.new-badge {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: var(--mark);
  color: #14161c;
  padding: 3px 8px;
  border-radius: 6px;
  margin-right: 10px;
  vertical-align: 2px;
}

.shelf-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px 24px;
  padding: 44px 0 20px;
}
.shelf-head h2 { margin: 0; font-size: 1.5rem; letter-spacing: -0.03em; }
.tabs { display: flex; flex-wrap: wrap; gap: 4px 22px; border-bottom: 1px solid var(--rule); }
.tab {
  font: inherit;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--muted);
  background: none;
  border: 0;
  border-bottom: 2px solid transparent;
  padding: 8px 0 10px;
  margin-bottom: -1px;
  cursor: pointer;
}
.tab:hover { color: var(--ink); }
.tab[aria-pressed="true"] { color: var(--ink); border-bottom-color: var(--ink); }
.tab .count { font-family: var(--mono); font-size: 0.75rem; color: var(--muted); margin-left: 4px; }

.shelf {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 36px 28px;
  padding: 28px 0 8px;
}
.story { text-decoration: none; color: inherit; display: flex; flex-direction: column; gap: 10px; }
.story .shot { border-radius: 14px; overflow: hidden; background: var(--paper-2); }
.story .shot img { width: 100%; aspect-ratio: 1200 / 630; object-fit: cover; transition: transform 0.5s cubic-bezier(.2, .7, .2, 1); }
.story:hover .shot img { transform: scale(1.04); }
.story h3 { margin: 4px 0 0; font-size: 1.22rem; line-height: 1.2; letter-spacing: -0.02em; }
.story:hover h3 { color: var(--accent); }
.story p { margin: 0; font-family: var(--serif); color: var(--ink-2); line-height: 1.55; }
.story-soon {
  border: 1.5px dashed var(--rule);
  border-radius: 14px;
  padding: 26px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 8px;
  min-height: 220px;
}
.story-soon b { font-size: 1.15rem; letter-spacing: -0.02em; }
.story-soon p { margin: 0; font-family: var(--serif); color: var(--muted); }
.story-soon ul { margin: 4px 0 0; padding-left: 18px; color: var(--ink-2); font-family: var(--serif); }
.filter-empty { color: var(--muted); font-family: var(--serif); }

/* ---------- Article ---------- */
.post-head { max-width: 52rem; margin: 0 auto; padding: 64px 0 36px; text-align: center; }
.post-head .crumbs { margin-bottom: 22px; }
.crumbs { font-size: 0.86rem; color: var(--muted); }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--ink); }
.crumbs span[aria-hidden] { margin: 0 8px; opacity: 0.6; }
.post-head h1 {
  font-size: clamp(2.2rem, 5.6vw, 4rem);
  line-height: 1.02;
  letter-spacing: -0.045em;
  font-weight: 700;
  margin: 14px 0 20px;
}
.dek {
  font-family: var(--serif);
  font-size: clamp(1.15rem, 2vw, 1.38rem);
  line-height: 1.5;
  color: var(--ink-2);
  max-width: 40rem;
  margin: 0 auto 30px;
}
.byline { display: inline-flex; align-items: center; gap: 12px; text-align: left; }
.avatar {
  flex: none;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 0.95rem;
  color: #fff;
  background: conic-gradient(from 210deg, #1c54e3, #6f9bff, #ffd84c, #1c54e3);
}
.byline strong { display: block; font-weight: 600; }
.avatar.logo { background: #e6efec; overflow: hidden; }
.avatar.logo img { width: 100%; height: 100%; }
.byline .meta { font-size: 0.86rem; }

.post-cover { max-width: 1100px; margin: 0 auto; }
.post-cover img { width: 100%; aspect-ratio: 1200 / 630; object-fit: cover; border-radius: 24px; box-shadow: var(--shadow); }

.post-grid {
  display: grid;
  grid-template-columns: minmax(0, 13rem) minmax(0, var(--measure)) minmax(0, 13rem);
  justify-content: center;
  gap: 56px;
  padding: 56px 0 24px;
}
.rail { position: sticky; top: calc(var(--bar) + 28px); align-self: start; font-size: 0.88rem; }
.rail-title { font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin: 0 0 12px; }
.toc ol { list-style: none; margin: 0; padding: 0; counter-reset: toc; }
.toc li { counter-increment: toc; }
.toc a {
  display: grid;
  grid-template-columns: 1.8rem 1fr;
  padding: 6px 0;
  color: var(--muted);
  text-decoration: none;
  line-height: 1.35;
  transition: color 0.15s;
}
.toc a::before { content: counter(toc, decimal-leading-zero); font-family: var(--mono); font-size: 0.72rem; padding-top: 2px; opacity: 0.7; }
.toc a:hover { color: var(--ink); }
.toc a.active { color: var(--ink); font-weight: 600; }
.toc a.active::before { color: var(--accent); opacity: 1; }
.rail-share { display: flex; flex-direction: column; gap: 6px; }

.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font: inherit;
  font-size: 0.86rem;
  color: var(--ink-2);
  background: transparent;
  border: 1px solid var(--rule);
  border-radius: 10px;
  padding: 7px 11px;
  text-decoration: none;
  cursor: pointer;
}
.share-btn:hover { border-color: var(--ink-2); color: var(--ink); }
.share-btn svg { width: 15px; height: 15px; flex: none; }

.toc-inline { display: none; border: 1px solid var(--rule); border-radius: 14px; padding: 2px 18px; margin-bottom: 32px; background: var(--card); }
.toc-inline summary { cursor: pointer; padding: 12px 0; font-family: var(--display); font-weight: 600; }
.toc-inline ol { margin: 0 0 14px; padding-left: 22px; font-family: var(--display); }
.toc-inline a { color: var(--ink-2); text-decoration: none; line-height: 2; }

/* Prose */
.prose { font-family: var(--serif); font-size: 1.17rem; line-height: 1.75; color: var(--ink-2); }
.prose > * { margin: 0 0 1.2em; }
.prose h2,
.prose h3 { font-family: var(--display); color: var(--ink); scroll-margin-top: calc(var(--bar) + 20px); position: relative; }
.prose h2 { font-size: clamp(1.6rem, 2.8vw, 2.05rem); line-height: 1.12; letter-spacing: -0.035em; margin: 2.3em 0 0.6em; }
.prose h3 { font-size: 1.32rem; line-height: 1.25; letter-spacing: -0.02em; margin: 1.9em 0 0.5em; }
.prose .anchor { position: absolute; left: -1.1em; color: var(--muted); text-decoration: none; opacity: 0; font-weight: 400; }
.prose h2:hover .anchor,
.prose h3:hover .anchor,
.prose .anchor:focus-visible { opacity: 0.6; }
.prose strong { color: var(--ink); font-weight: 600; }
.prose a { color: var(--ink); text-decoration-color: var(--accent); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.prose a:hover { color: var(--accent); }
.prose ul,
.prose ol { padding-left: 1.25em; }
.prose li { margin: 0.4em 0; padding-left: 0.2em; }
.prose li::marker { color: var(--accent); }
.prose :not(pre) > code {
  font-family: var(--mono);
  font-size: 0.8em;
  background: var(--accent-soft);
  color: var(--ink);
  padding: 0.14em 0.38em;
  border-radius: 6px;
  word-break: break-word;
}
.prose .opener::first-letter {
  float: left;
  font-family: var(--display);
  font-weight: 700;
  font-size: 4.1em;
  line-height: 0.82;
  margin: 0.06em 0.09em 0 0;
  color: var(--accent);
}
.pull {
  font-family: var(--display);
  font-size: clamp(1.35rem, 2.5vw, 1.7rem);
  line-height: 1.3;
  letter-spacing: -0.025em;
  color: var(--ink);
  border-left: 3px solid var(--mark);
  padding: 4px 0 4px 22px;
  margin: 1.8em 0 !important;
}

.summary {
  font-family: var(--display);
  font-size: 1rem;
  line-height: 1.6;
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: 18px;
  padding: 22px 24px;
}
.summary .eyebrow { margin: 0 0 10px; }
.summary ul { margin: 0; padding-left: 1.1em; }
.summary li { margin: 0.35em 0; }

.note {
  display: flex;
  gap: 14px;
  font-family: var(--display);
  font-size: 1rem;
  line-height: 1.6;
  background: var(--accent-soft);
  border-radius: 14px;
  padding: 16px 18px;
  color: var(--ink);
}
.note svg { flex: none; width: 22px; height: 22px; color: var(--accent); margin-top: 1px; }
.note p { margin: 0; }

/* Code */
.code { font-family: var(--mono); background: var(--code-bg); border-radius: 14px; overflow: hidden; border: 1px solid #1d2433; font-size: 0.82rem; }
.code-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 7px 8px 7px 14px;
  background: var(--code-head);
  border-bottom: 1px solid #1f2738;
  color: #8a95ae;
  font-size: 0.74rem;
}
.code-head .dots { display: inline-flex; gap: 6px; margin-right: 10px; vertical-align: -1px; }
.code-head .dots i { width: 9px; height: 9px; border-radius: 50%; background: #2c3549; display: inline-block; }
.copy-btn {
  font: inherit;
  color: #c9d2e6;
  background: #222a3c;
  border: 1px solid #2e3850;
  border-radius: 7px;
  padding: 3px 10px;
  cursor: pointer;
}
.copy-btn:hover { color: #fff; background: #2b3550; }
.copy-btn.done { color: #8ff0b0; border-color: #2f6b49; }
.code pre { margin: 0; padding: 16px 18px 18px; overflow-x: auto; color: var(--code-ink); line-height: 1.7; tab-size: 4; }
.tok-k { color: #ff8fb3; }
.tok-s { color: #a8e6a1; }
.tok-c { color: #6c7894; font-style: italic; }
.tok-n { color: #ffc178; }
.tok-a { color: #ffd84c; }
.tok-f { color: #7fb7ff; }
.tok-t { color: #8fe3e8; }

/* Media */
.phone {
  width: 100%;
  max-width: 250px;
  margin: 0 auto;
  background: #07080b;
  border-radius: 30px;
  padding: 7px;
  box-shadow: 0 18px 40px rgba(10, 12, 18, 0.22), inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}
.phone video,
.phone img { width: 100%; aspect-ratio: 340 / 710; object-fit: cover; border-radius: 24px; background: #1a1d24; }
.clips { display: grid; grid-template-columns: repeat(var(--n, 2), minmax(0, 1fr)); gap: 22px; margin: 2em 0 2.2em !important; }
.clips.bleed { margin-left: -8% !important; margin-right: -8% !important; }
.clips figure { margin: 0; text-align: center; }
.clips figcaption { margin-top: 12px; font-family: var(--display); font-size: 0.86rem; line-height: 1.45; color: var(--muted); }
.clips figcaption code { font-size: 0.8rem !important; }

/* Live demo */
.demo {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  align-items: center;
  gap: 32px;
  margin: 2.2em -8% !important;
  padding: 34px;
  border-radius: 26px;
  font-family: var(--display);
  color: #fff;
  background:
    radial-gradient(500px 300px at 90% 0%, rgba(255, 216, 76, 0.22), transparent 60%),
    radial-gradient(600px 400px at 0% 100%, rgba(10, 30, 110, 0.7), transparent 70%),
    linear-gradient(135deg, #1c54e3, #0e2c8c);
  overflow: hidden;
}
.demo .eyebrow { color: rgba(255, 255, 255, 0.7); }
.demo h3 { color: #fff; font-size: 1.7rem; letter-spacing: -0.03em; line-height: 1.1; margin: 10px 0 12px; }
.demo p { color: rgba(255, 255, 255, 0.86); font-size: 1rem; line-height: 1.6; margin: 0 0 20px; }
.demo .pill-btn { background: #fff; color: #1c54e3; }
.demo .pill-btn:hover { background: var(--mark); color: #14161c; }
.demo .pill-btn.ghost { background: rgba(255, 255, 255, 0.12); color: #fff; border-color: rgba(255, 255, 255, 0.3); }
.demo .pill-btn.ghost:hover { background: rgba(255, 255, 255, 0.22); }
.demo-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.demo .phone { max-width: 280px; box-shadow: 0 30px 60px rgba(0, 0, 0, 0.4), inset 0 0 0 1px rgba(255, 255, 255, 0.1); }
.stage { position: relative; aspect-ratio: 340 / 710; border-radius: 24px; overflow: hidden; background: #1a1d24; }
.stage img { position: absolute; inset: 0; height: 100%; border-radius: 0; filter: brightness(0.5) saturate(0.9); }
.stage iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.stage-play {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 12px;
  border: 0;
  background: none;
  color: #fff;
  font: 600 0.95rem var(--display);
  cursor: pointer;
}
.stage-play .ring {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--mark);
  color: #14161c;
  box-shadow: 0 0 0 0 rgba(255, 216, 76, 0.5);
  animation: pulse 2.2s infinite;
}
.stage-play .ring svg { width: 26px; height: 26px; margin-left: 3px; }
@keyframes pulse { 70% { box-shadow: 0 0 0 18px rgba(255, 216, 76, 0); } 100% { box-shadow: 0 0 0 0 rgba(255, 216, 76, 0); } }
.demo-hint { font-size: 0.78rem; color: rgba(255, 255, 255, 0.7); text-align: center; margin: 12px 0 0 !important; }

/* Feature list */
.features { list-style: none; padding: 0 !important; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0; border-top: 1px solid var(--rule); font-family: var(--display); counter-reset: f; }
.features li { counter-increment: f; margin: 0; padding: 18px 18px 18px 0; border-bottom: 1px solid var(--rule); font-size: 0.98rem; line-height: 1.55; color: var(--ink-2); }
.features li:nth-child(odd) { padding-right: 26px; border-right: 1px solid var(--rule); }
.features li:nth-child(even) { padding-left: 26px; }
.features li::before { content: counter(f, decimal-leading-zero); display: block; font-family: var(--mono); font-size: 0.72rem; color: var(--accent); margin-bottom: 6px; }
.features b { display: block; color: var(--ink); font-size: 1.05rem; margin-bottom: 3px; letter-spacing: -0.01em; }

/* Table */
.table-wrap { overflow-x: auto; border: 1px solid var(--rule); border-radius: 14px; background: var(--card); }
.prose table { width: 100%; border-collapse: collapse; font-family: var(--display); font-size: 0.93rem; line-height: 1.5; }
.prose th,
.prose td { text-align: left; vertical-align: top; padding: 12px 16px; border-bottom: 1px solid var(--rule); }
.prose th { color: var(--ink); font-weight: 600; background: var(--paper-2); }
.prose tr:last-child td { border-bottom: 0; }

/* End of post */
.endcap {
  font-family: var(--display);
  text-align: center;
  padding: 40px 28px;
  margin-top: 2.6em !important;
  border-radius: 24px;
  background: var(--card);
  border: 1px solid var(--rule);
}
.endcap h2 { margin: 6px 0 10px !important; font-size: 1.9rem !important; }
.endcap p { color: var(--ink-2); max-width: 30rem; margin: 0 auto 22px; font-size: 1.02rem; line-height: 1.6; }
.endcap .actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }

.author {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  font-family: var(--display);
  padding: 26px 0;
  margin-top: 2.4em !important;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}
.author .avatar { width: 58px; height: 58px; font-size: 1.15rem; }
.author .eyebrow { margin: 0 0 2px; }
.author strong { font-size: 1.1rem; }
.author p { margin: 6px 0 0; color: var(--ink-2); font-size: 0.98rem; line-height: 1.6; }
.share-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-family: var(--display); }
.share-row .label { color: var(--muted); font-size: 0.88rem; margin-right: 6px; }

/* ---------- Footer ---------- */
.foot { margin-top: 72px; border-top: 1px solid var(--rule); background: var(--paper-2); }
.foot-top {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: 32px 56px;
  padding: 52px 0 36px;
}
.foot h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); line-height: 1.08; letter-spacing: -0.035em; margin: 10px 0 12px; }
.foot-top p { font-family: var(--serif); font-size: 1.05rem; color: var(--ink-2); margin: 0 0 20px; max-width: 30rem; }
.foot-top p.eyebrow { font-family: var(--mono); font-size: 0.76rem; color: var(--muted); margin: 0; }
.foot-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.foot-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.foot-cols ul { list-style: none; margin: 10px 0 0; padding: 0; }
.foot-cols li { margin: 7px 0; }
.foot-cols a { color: var(--ink-2); text-decoration: none; font-size: 0.95rem; }
.foot-cols a:hover { color: var(--accent); }
.foot-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; padding: 18px 0 30px; border-top: 1px solid var(--rule); color: var(--muted); font-size: 0.86rem; }

/* ---------- Responsive ---------- */
@media (max-width: 1180px) {
  .post-grid { grid-template-columns: minmax(0, 12rem) minmax(0, var(--measure)); gap: 48px; }
  .post-grid > .rail-right { display: none; }
  .clips.bleed, .demo { margin-left: 0 !important; margin-right: 0 !important; }
}
@media (max-width: 960px) {
  .post-grid { grid-template-columns: minmax(0, var(--measure)); gap: 0; padding-top: 40px; }
  .post-grid > .rail { display: none; }
  .toc-inline { display: block; }
  .intro { grid-template-columns: 1fr; padding-top: 48px; }
  .lead-story { grid-template-columns: 1fr; gap: 24px; }
  .shelf { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .demo { grid-template-columns: 1fr; text-align: center; }
  .demo-actions { justify-content: center; }
  .foot-top { grid-template-columns: 1fr; }
  .bar-topics { display: none; }
}
@media (max-width: 620px) {
  :root { --bar: 58px; }
  .container { width: calc(100% - 32px); }
  .wordmark .studio, .wordmark .slash { display: none; }
  .studio-link span { display: none; }
  .studio-link { padding: 9px; }
  .post-head { padding-top: 36px; text-align: left; }
  .post-head h1 { font-size: 1.95rem; letter-spacing: -0.035em; }
  .post-head h1, .lead-story h2, .story h3 { overflow-wrap: anywhere; }
  .lead-story h2 { font-size: 1.6rem; }
  .dek { margin-left: 0; }
  .post-cover img { border-radius: 16px; }
  .prose { font-size: 1.08rem; }
  .prose .anchor { display: none; }
  .clips { --n: 2 !important; gap: 12px; }
  .clips.three { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .clips.three .phone { padding: 4px; border-radius: 16px; }
  .clips.three .phone video { border-radius: 12px; }
  .clips.three figcaption { font-size: 0.7rem; }
  .clips.three figcaption code { font-size: 0.66rem !important; padding: 0.1em 0.3em; }
  .demo { padding: 24px 18px; border-radius: 20px; }
  .features { grid-template-columns: 1fr; }
  .features li:nth-child(odd), .features li:nth-child(even) { padding: 16px 0; border-right: 0; }
  .shelf { grid-template-columns: 1fr; }
  .author { flex-direction: column; }
  .foot-cols { grid-template-columns: 1fr 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}
.social-item { display: inline-flex; align-items: center; gap: 7px; }
.social-item svg { width: 16px; height: 16px; flex: none; }
