@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=Space+Grotesk:wght@500;600;700&display=swap");

:root {
  --bf-page-bg: #ffffff;
  --bf-text: #18181b;
  --bf-card-bg: #ffffff;
  --bf-card-border: rgb(212 212 216);
  --bf-card-shadow: 0 12px 32px rgba(11, 11, 12, 0.08);
  --bf-field-bg: #ffffff;
  --bf-field-border: rgb(212 212 216);
  --bf-text-muted: #71717a;
  --bf-text-subtle: #52525b;
  --bf-surface-hover: #f4f4f5;
  --bf-divider: rgb(228 228 231);
  --bf-cream-surface: #fffaf1;
  --bf-primary: #0b0b0c;
  --bf-primary-hover: #15110f;
  --bf-ember: #ff6a1a;
  --bf-ember-soft: rgba(255, 106, 26, 0.12);
  --bf-radius-button: 0.75rem;
  --bf-radius-card: 2rem;
  --bf-font-body: "Inter", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --bf-font-display: "Space Grotesk", "Inter", ui-sans-serif, system-ui, sans-serif;
  --bf-font-code: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bf-page-bg);
  color: var(--bf-text);
  font-family: var(--bf-font-body);
  font-size: 15px;
}

.bf-header {
  align-items: center;
  backdrop-filter: blur(18px);
  background: color-mix(in srgb, var(--bf-page-bg) 94%, transparent);
  border-bottom: 1px solid var(--bf-divider);
  display: grid;
  grid-template-columns: minmax(12rem, 1fr) minmax(20rem, 42rem) minmax(12rem, 1fr);
  gap: 1rem;
  height: 4rem;
  padding: 0 1.25rem;
  position: sticky;
  top: 0;
  z-index: 20;
}

.bf-header > * { min-width: 0; }
.bf-brand { align-items: center; display: inline-flex; width: max-content; }
.bf-brand img {
  display: block;
  height: 3.35rem;
  width: auto;
}
.bf-sr-only {
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  height: 1px;
  overflow: hidden;
  position: absolute;
  white-space: nowrap;
  width: 1px;
}
.bf-repo {
  align-items: center;
  background: var(--bf-primary);
  border: 1px solid var(--bf-primary);
  border-radius: var(--bf-radius-button);
  color: #fff;
  display: inline-flex;
  font-size: 0.78rem;
  font-weight: 700;
  gap: 0.5rem;
  justify-self: end;
  padding: 0.72rem 0.9rem;
  text-decoration: none;
}
.bf-repo svg {
  display: block;
  flex: 0 0 auto;
}
.bf-repo:hover { background: var(--bf-primary-hover); }

.bf-search { position: relative; width: 100%; }
.bf-search__label {
  height: 1px;
  overflow: hidden;
  position: absolute;
  white-space: nowrap;
  width: 1px;
}
.bf-search input {
  background: var(--bf-field-bg);
  border: 1px solid var(--bf-field-border);
  border-radius: var(--bf-radius-button);
  color: var(--bf-text);
  font: 500 0.84rem var(--bf-font-body);
  height: 2.65rem;
  outline: none;
  padding: 0 1rem;
  width: 100%;
}
.bf-search input:focus {
  border-color: var(--bf-primary);
  box-shadow: 0 0 0 2px var(--bf-primary);
}
.bf-search__results {
  background: var(--bf-card-bg);
  border: 1px solid var(--bf-card-border);
  border-radius: 1rem;
  box-shadow: 0 18px 44px rgba(11, 11, 12, 0.14);
  left: 0;
  max-height: min(30rem, calc(100vh - 6rem));
  overflow: auto;
  position: absolute;
  right: 0;
  top: calc(100% + 0.5rem);
  z-index: 40;
}
.bf-search__meta {
  border-bottom: 1px solid var(--bf-divider);
  color: var(--bf-text-muted);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  padding: 0.72rem 0.9rem;
  text-transform: uppercase;
}
.bf-search__result {
  border-bottom: 1px solid var(--bf-divider);
  color: var(--bf-text);
  display: block;
  padding: 0.8rem 0.9rem;
  text-decoration: none;
}
.bf-search__result:last-child { border-bottom: 0; }
.bf-search__result:hover,
.bf-search__result:focus { background: var(--bf-surface-hover); outline: none; }
.bf-search__result strong {
  display: block;
  font-family: var(--bf-font-display);
  font-size: 0.82rem;
  line-height: 1.25;
}
.bf-search__result span {
  color: var(--bf-text-subtle);
  display: block;
  font-size: 0.72rem;
  line-height: 1.45;
  margin-top: 0.25rem;
}

.bf-shell {
  display: grid;
  grid-template-columns: minmax(13rem, 17rem) minmax(0, 1fr) minmax(12rem, 15rem);
  gap: clamp(1rem, 2vw, 2rem);
  margin: 0 auto;
  max-width: none;
  padding: 2rem clamp(1rem, 2vw, 2rem) 0;
  width: 100%;
}
.bf-sidebar,
.bf-toc {
  align-self: start;
  max-height: calc(100vh - 5.5rem);
  overflow: auto;
  position: sticky;
  top: 5rem;
}
.bf-nav-group { margin-bottom: 1.15rem; }
.bf-toc-section { margin-bottom: 1.25rem; }
.bf-nav-group h2,
.bf-toc h2 {
  color: var(--bf-text-muted);
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  margin: 0 0 0.45rem;
  text-transform: uppercase;
}
.bf-nav-group a,
.bf-toc a {
  border-radius: var(--bf-radius-button);
  color: var(--bf-text-subtle);
  display: block;
  font-size: 0.78rem;
  font-weight: 650;
  line-height: 1.25;
  margin-bottom: 0.18rem;
  padding: 0.65rem 0.75rem;
  text-decoration: none;
}
.bf-nav-group a:hover,
.bf-toc a:hover { background: var(--bf-surface-hover); color: var(--bf-text); }
.bf-nav-group a[aria-current="page"] {
  background: var(--bf-primary);
  color: #fff;
}
.bf-nav-parent.bf-nav-parent--active {
  color: var(--bf-text);
}
.bf-nav-children {
  border-left: 1px solid var(--bf-border);
  margin: 0.1rem 0 0.45rem 0.75rem;
  padding-left: 0.45rem;
}
.bf-nav-group a.bf-nav-child {
  font-size: 0.72rem;
  margin-bottom: 0.12rem;
  padding: 0.5rem 0.65rem;
}
.bf-toc .bf-toc-link--sub { font-size: 0.72rem; padding-left: 1.35rem; }
.bf-toc a[aria-current="true"] {
  background: var(--bf-primary);
  color: #fff;
}
.bf-muted { color: var(--bf-text-muted); font-size: 0.78rem; }

.bf-content { min-width: 0; }
.bf-article {
  color: var(--bf-text-subtle);
  font-size: 0.95rem;
  line-height: 1.68;
  max-width: none;
}
.bf-article h1,
.bf-article h2,
.bf-article h3,
.bf-article h4 {
  color: var(--bf-text);
  font-family: var(--bf-font-display);
  letter-spacing: 0;
}
.bf-article h1 {
  font-size: clamp(2.35rem, 5vw, 4rem);
  line-height: 1;
  margin: 0 0 1rem;
}
.bf-article h2 {
  border-top: 1px solid var(--bf-divider);
  font-size: 1.45rem;
  margin: 2.8rem 0 0.9rem;
  padding-top: 1.35rem;
}
.bf-article h3 { font-size: 1.05rem; margin-top: 2rem; }
.bf-article a { color: var(--bf-ember); font-weight: 700; }
.bf-article code {
  background: var(--bf-field-bg);
  border: 1px solid var(--bf-field-border);
  border-radius: 0.48rem;
  color: var(--bf-text);
  font-family: var(--bf-font-code);
  font-size: 0.84em;
  padding: 0.08rem 0.3rem;
}
.bf-code {
  background: #080a0f;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 1.2rem;
  box-shadow: 0 18px 50px rgba(11, 11, 12, 0.18);
  margin: 1.35rem 0;
  overflow: hidden;
}
.bf-code__bar {
  align-items: center;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  display: flex;
  gap: 0.4rem;
  height: 2.1rem;
  justify-content: space-between;
  min-width: 0;
  padding: 0 0.9rem;
}
.bf-code__dots {
  display: inline-flex;
  flex: 0 0 auto;
  gap: 0.4rem;
}
.bf-code__dots span {
  background: var(--bf-ember);
  border-radius: 999px;
  height: 0.55rem;
  width: 0.55rem;
}
.bf-code__dots span:nth-child(2) { background: #fdba3b; }
.bf-code__dots span:nth-child(3) { background: rgba(255,255,255,0.55); }
.bf-code__actions {
  align-items: center;
  display: flex;
  flex: 1 1 auto;
  gap: 0.5rem;
  justify-content: flex-end;
  min-width: 0;
}
.bf-code__bar strong {
  color: rgba(248,250,252,0.58);
  flex: 1 1 auto;
  font-family: var(--bf-font-display);
  font-size: 0.62rem;
  min-width: 0;
  overflow: hidden;
  text-align: right;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}
.bf-code__copy {
  align-items: center;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 0.55rem;
  color: rgba(248,250,252,0.76);
  cursor: pointer;
  display: inline-flex;
  flex: 0 0 auto;
  font: 700 0.64rem var(--bf-font-body);
  gap: 0.35rem;
  height: 1.55rem;
  padding: 0 0.48rem;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease, transform 160ms ease;
}
.bf-code__copy:hover,
.bf-code__copy:focus {
  background: rgba(255,255,255,0.12);
  border-color: rgba(255,255,255,0.28);
  color: #fff;
  outline: none;
}
.bf-code__copy:focus-visible {
  box-shadow: 0 0 0 2px var(--bf-ember);
}
.bf-code__copy svg {
  display: block;
}
.bf-code__copy.is-copied {
  background: var(--bf-ember);
  border-color: var(--bf-ember);
  color: #fff;
  animation: bf-copy-pop 360ms ease;
}
.bf-code__copy.is-error {
  background: rgba(255, 106, 26, 0.2);
  border-color: rgba(255, 106, 26, 0.7);
  color: #fff;
}
.bf-code__copy-label {
  line-height: 1;
}
@keyframes bf-copy-pop {
  0% { transform: scale(1); }
  45% { transform: scale(1.06); }
  100% { transform: scale(1); }
}
@media (prefers-reduced-motion: reduce) {
  .bf-code__copy { transition: none; }
  .bf-code__copy.is-copied { animation: none; }
}
.bf-code pre {
  margin: 0;
  overflow: auto;
  padding: 1rem;
}
.bf-code code {
  background: transparent;
  border: 0;
  color: #f8fafc;
  display: block;
  font-size: 0.82rem;
  line-height: 1.55;
  padding: 0;
  tab-size: 4;
  white-space: pre;
}
.bf-table-wrap {
  border: 1px solid var(--bf-card-border);
  border-radius: 1.15rem;
  box-shadow: var(--bf-card-shadow);
  margin: 1.3rem 0;
  overflow: auto;
}
table { border-collapse: collapse; min-width: 100%; }
th, td {
  border-bottom: 1px solid var(--bf-divider);
  padding: 0.72rem 0.85rem;
  text-align: left;
  vertical-align: top;
}
th {
  background: var(--bf-field-bg);
  color: var(--bf-text);
  font-size: 0.68rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
td { color: var(--bf-text-subtle); font-size: 0.82rem; }
tr:last-child td { border-bottom: 0; }

.bf-docs-hero {
  background: var(--bf-cream-surface);
  border: 1px solid var(--bf-card-border);
  border-radius: 2rem;
  box-shadow: var(--bf-card-shadow);
  margin-bottom: 1.6rem;
  padding: clamp(1.2rem, 3vw, 2rem);
}
.bf-docs-hero--home {
  background: #f3edf7;
  border: 0;
  box-shadow: none;
  color: #111827;
  display: grid;
  gap: clamp(1.5rem, 4vw, 3.5rem);
  grid-template-columns: minmax(0, 0.82fr) minmax(20rem, 1.18fr);
  overflow: hidden;
  padding: clamp(2.4rem, 6vw, 5.4rem) clamp(1.4rem, 4vw, 3rem);
  position: relative;
}
.bf-docs-fireplace-cta {
  margin: -0.6rem -0.6rem 2rem;
  min-height: clamp(28rem, 50vw, 40rem);
}
.bf-docs-hero--home > * {
  position: relative;
  z-index: 1;
}
.bf-docs-hero--home .bf-eyebrow {
  color: #111827;
  font-family: var(--bf-font-code);
  font-size: 0.63rem;
  font-weight: 800;
  letter-spacing: 0.48em;
  margin-bottom: clamp(1.6rem, 3vw, 2.4rem);
  text-transform: uppercase;
}
.bf-docs-hero--home h1 {
  color: #111827;
  font-family: var(--bf-font-display);
  font-size: clamp(3.1rem, 6.9vw, 6.4rem);
  letter-spacing: -0.075em;
  line-height: 0.9;
  margin-bottom: 1.25rem;
  max-width: 7.2ch;
}
.bf-fireplace-copy {
  align-self: center;
  z-index: 2;
}
.bf-hero-lead {
  color: #1f2937;
  font-size: clamp(0.92rem, 1.25vw, 1.08rem);
  line-height: 1.55;
  max-width: 36rem;
}
.bf-fireplace-actions {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 0.95rem;
  margin-top: 1.55rem;
}
.bf-fireplace-actions code {
  background: rgba(255, 255, 255, 0.58);
  border: 1px solid rgba(17, 24, 39, 0.1);
  border-radius: 0.68rem;
  color: #111827;
  font-family: var(--bf-font-code);
  font-size: 0.82rem;
  padding: 0.78rem 0.95rem;
}
.bf-fireplace-actions code::before {
  color: #ff6a1a;
  content: "$ ";
}
.bf-fireplace-visual {
  align-self: center;
  display: flex;
  justify-content: flex-end;
  margin: 0;
  min-width: 0;
}
.bf-fireplace-visual img {
  filter: drop-shadow(0 28px 36px rgba(17, 24, 39, 0.12));
  height: auto;
  max-height: clamp(22rem, 48vw, 38rem);
  max-width: min(100%, 45rem);
  object-fit: contain;
  width: 100%;
}
.bf-install-card {
  background: #0b0b0c;
  border: 1px solid rgba(11, 11, 12, 0.16);
  border-radius: 1.2rem;
  box-shadow: 0 22px 60px rgba(11, 11, 12, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.1);
  margin-top: 0.4rem;
  max-width: 46rem;
  overflow: hidden;
}
.bf-install-card__header {
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  gap: 1rem;
  justify-content: space-between;
  padding: 0.75rem 0.85rem;
}
.bf-install-card__header > span {
  color: rgba(255, 255, 255, 0.74);
  font-family: var(--bf-font-code);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.bf-install-tabs {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 0.75rem;
  display: flex;
  gap: 0.2rem;
  padding: 0.2rem;
}
.bf-install-tabs button {
  appearance: none;
  background: transparent;
  border: 0;
  border-radius: 0.55rem;
  color: rgba(255, 255, 255, 0.72);
  cursor: pointer;
  font-family: var(--bf-font-code);
  font-size: 0.68rem;
  font-weight: 800;
  padding: 0.42rem 0.62rem;
}
.bf-install-tabs button.is-active {
  background: #fffaf1;
  color: #080a0f;
}
.bf-install-tabs button:focus-visible {
  outline: 2px solid #ffcf67;
  outline-offset: 2px;
}
.bf-install-card pre {
  margin: 0;
  overflow-x: auto;
  padding: 1.05rem 1.15rem 1.2rem;
}
.bf-install-card code {
  background: transparent;
  border: 0;
  border-radius: 0;
  color: #fff;
  display: block;
  font-family: var(--bf-font-code);
  font-size: clamp(0.88rem, 1.55vw, 1.05rem);
  font-weight: 400;
  line-height: 1.4;
  padding: 0;
  white-space: pre;
}
.bf-install-card code::before {
  color: #ff6a1a;
  content: "$ ";
}
.bf-docs-actions--hero {
  grid-template-columns: repeat(2, minmax(10rem, 1fr));
  margin-top: 1.35rem;
  max-width: 34rem;
}
.bf-docs-hero--home .bf-docs-button {
  backdrop-filter: blur(12px);
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.18);
  box-shadow: none;
  color: #fff;
}
.bf-docs-hero--home .bf-docs-button:hover {
  background: rgba(255, 255, 255, 0.15);
}
.bf-docs-hero--home .bf-docs-button--primary {
  background: #fff;
  border-color: #fff;
  color: #080a0f;
}
.bf-spark-card {
  align-self: center;
  background: rgba(8, 10, 15, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 1.5rem;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.32), inset 0 1px 0 rgba(255, 255, 255, 0.12);
  min-height: 23rem;
  overflow: hidden;
  padding: 1rem;
  position: relative;
}
.bf-spark-card::before {
  background: linear-gradient(135deg, rgba(255, 106, 26, 0.25), rgba(142, 124, 195, 0.22), rgba(9, 17, 31, 0));
  content: "";
  inset: 0;
  pointer-events: none;
  position: absolute;
}
.bf-spark-card > * {
  position: relative;
  z-index: 1;
}
.bf-spark-card__bar {
  display: flex;
  gap: 0.4rem;
  padding: 0.15rem 0.1rem 0.9rem;
}
.bf-spark-card__bar span {
  background: rgba(255, 255, 255, 0.56);
  border-radius: 999px;
  height: 0.55rem;
  width: 0.55rem;
}
.bf-spark-card__bar span:first-child { background: #ff6a1a; }
.bf-spark-card__bar span:nth-child(2) { background: #ffcf67; }
.bf-spark-card__bar span:nth-child(3) { background: #8e7cc3; }
.bf-spark-mark {
  display: grid;
  gap: 0.55rem;
  grid-template-columns: repeat(3, 1fr);
  margin: 1.9rem auto 1.45rem;
  max-width: 16rem;
}
.bf-spark-mark span {
  aspect-ratio: 1;
  background: linear-gradient(135deg, #ffcf67 0%, #ff6a1a 46%, #8e7cc3 100%);
  border: 1px solid rgba(255, 255, 255, 0.22);
  box-shadow: 0 12px 26px rgba(255, 106, 26, 0.18);
}
.bf-spark-mark span:nth-child(2),
.bf-spark-mark span:nth-child(4),
.bf-spark-mark span:nth-child(6) {
  background: linear-gradient(135deg, #8e7cc3 0%, #172140 52%, #ff6a1a 140%);
}
.bf-spark-card__prompt {
  color: #ffcf67;
  font-family: var(--bf-font-code);
  font-size: 0.9rem;
  font-weight: 800;
  margin: 0 0 1rem;
}
.bf-spark-card__prompt::before {
  color: #ff6a1a;
  content: "$ ";
}
.bf-spark-flow {
  display: grid;
  gap: 0.45rem;
  grid-template-columns: repeat(5, minmax(0, 1fr));
}
.bf-spark-flow span {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: rgba(255, 255, 255, 0.84);
  font-family: var(--bf-font-code);
  font-size: 0.62rem;
  font-weight: 800;
  overflow: hidden;
  padding: 0.55rem 0.35rem;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.bf-eyebrow {
  color: var(--bf-ember);
  font-family: var(--bf-font-code);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.bf-docs-actions,
.bf-docs-grid {
  display: grid;
  gap: 0.85rem;
  grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr));
  margin: 1rem 0;
}
.bf-docs-button,
.bf-docs-card {
  background: var(--bf-card-bg);
  border: 1px solid var(--bf-card-border);
  border-radius: 1.2rem;
  box-shadow: var(--bf-card-shadow);
  color: var(--bf-text);
  display: block;
  padding: 1rem;
  text-decoration: none;
}
.bf-docs-button { text-align: center; }
.bf-docs-button:hover,
.bf-docs-card:hover {
  border-color: rgba(255, 106, 26, 0.42);
  transform: translateY(-1px);
}
.bf-docs-card,
.bf-docs-button {
  transition: background 160ms ease, border-color 160ms ease, transform 160ms ease;
}
.bf-docs-grid--featured .bf-docs-card {
  background:
    radial-gradient(circle at 92% 12%, rgba(255, 106, 26, 0.16), transparent 28%),
    linear-gradient(180deg, #111113 0%, #050506 100%);
  border-color: rgba(255, 255, 255, 0.12);
  border-radius: 1.05rem;
  box-shadow: 0 18px 44px rgba(5, 5, 6, 0.22);
  color: #ffffff;
  min-height: 9.5rem;
  overflow: hidden;
  padding: 1.15rem 1.15rem 1.1rem;
  position: relative;
}
.bf-docs-grid--featured .bf-docs-card::before {
  background: linear-gradient(90deg, var(--bf-ember), rgba(255, 207, 103, 0.72), transparent);
  content: "";
  height: 2px;
  left: 1rem;
  position: absolute;
  right: 1rem;
  top: 0;
}
.bf-docs-grid--featured .bf-docs-card::after {
  color: rgba(255, 255, 255, 0.5);
  content: "→";
  font-family: var(--bf-font-display);
  font-size: 1.1rem;
  font-weight: 800;
  position: absolute;
  right: 1rem;
  top: 0.85rem;
  transition: color 160ms ease, transform 160ms ease;
}
.bf-docs-grid--featured .bf-docs-card:hover {
  background:
    radial-gradient(circle at 92% 12%, rgba(255, 106, 26, 0.24), transparent 30%),
    linear-gradient(180deg, #151518 0%, #070708 100%);
  border-color: rgba(255, 106, 26, 0.45);
  box-shadow: 0 22px 54px rgba(5, 5, 6, 0.28);
  transform: translateY(-2px);
}
.bf-docs-card strong {
  display: block;
  font-family: var(--bf-font-display);
  margin-bottom: 0.3rem;
}
.bf-docs-grid--featured .bf-docs-card:hover::after {
  color: #ffffff;
  transform: translateX(2px);
}
.bf-docs-grid--featured .bf-docs-card strong {
  color: #ffffff;
  font-size: 1.02rem;
  font-weight: 850;
  letter-spacing: 0;
  line-height: 1.15;
  max-width: calc(100% - 1.6rem);
}
.bf-docs-grid--featured .bf-docs-card span {
  color: rgba(255, 255, 255, 0.72);
  display: block;
  font-size: 0.86rem;
  line-height: 1.45;
  margin-top: 0.75rem;
}
.bf-docs-card span { color: var(--bf-text-subtle); font-size: 0.82rem; }
.bf-doc-image {
  background: var(--bf-card-bg);
  border: 1px solid var(--bf-card-border);
  border-radius: 1.15rem;
  box-shadow: var(--bf-card-shadow);
  display: block;
  margin: 1.35rem 0;
  max-width: 100%;
  padding: 0.35rem;
}
.bf-figure-gallery {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 1.4rem 0 2.1rem;
}
.bf-figure-card {
  background: var(--bf-card-bg);
  border: 1px solid var(--bf-card-border);
  border-radius: 0.9rem;
  box-shadow: var(--bf-card-shadow);
  display: flex;
  flex-direction: column;
  margin: 0;
  min-width: 0;
  overflow: hidden;
}
.bf-figure-card img {
  background: #ffffff;
  border-bottom: 1px solid var(--bf-divider);
  display: block;
  height: auto;
  max-width: 100%;
  object-fit: contain;
  width: 100%;
}
.bf-figure-card figcaption {
  color: var(--bf-text-subtle);
  display: block;
  font-size: 0.82rem;
  line-height: 1.55;
  min-width: 0;
  overflow-wrap: anywhere;
  padding: 0.85rem 0.95rem 1rem;
}
.bf-figure-card figcaption strong {
  color: var(--bf-text);
  display: block;
  font-size: 0.9rem;
  line-height: 1.35;
  margin-bottom: 0.25rem;
}
.bf-footer {
  background: var(--bf-page-bg);
  border-top: 1px solid var(--bf-divider);
  color: var(--bf-text-subtle);
  margin-top: 4rem;
  padding: 1.65rem 1.25rem 1.9rem;
}
.bf-footer__inner {
  align-items: center;
  display: grid;
  gap: 1.2rem;
  grid-template-columns: minmax(0, 1fr) minmax(16rem, auto);
  margin: 0 auto;
  max-width: 96rem;
}
.bf-footer__brand {
  align-items: center;
  display: flex;
  gap: 0.9rem;
  min-width: 0;
}
.bf-footer__brand img {
  display: block;
  height: 2.65rem;
  width: auto;
}
.bf-footer__brand p {
  color: var(--bf-primary);
  font-family: var(--bf-font-display);
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.15;
  margin: 0;
  min-width: 0;
}
.bf-footer__brand p span:first-child { color: var(--bf-primary); }
.bf-footer__brand p span:last-child { color: var(--bf-ember); display: block; }
.bf-footer__note {
  color: var(--bf-text-subtle);
  font-family: var(--bf-font-code);
  font-size: 0.76rem;
  justify-self: end;
  line-height: 1.5;
  margin: 0;
  max-width: 34rem;
  text-align: right;
}

.bf-search__code {
  background: #080a0f;
  border-radius: 0.75rem;
  color: #f8fafc;
  display: block;
  font-family: var(--bf-font-code);
  font-size: 0.68rem;
  line-height: 1.45;
  margin-top: 0.48rem;
  overflow-x: auto;
  padding: 0.55rem 0.65rem;
  white-space: pre;
}
.bf-search mark {
  background: var(--bf-ember-soft);
  border-radius: 0.25rem;
  color: inherit;
  padding: 0 0.12rem;
}

@media (max-width: 1100px) {
  .bf-header { grid-template-columns: auto minmax(12rem, 1fr) auto; }
  .bf-shell { grid-template-columns: 14rem minmax(0,1fr); }
  .bf-toc { display: none; }
  .bf-docs-hero--home { grid-template-columns: 1fr; }
  .bf-docs-fireplace-cta { min-height: auto; }
  .bf-fireplace-visual { justify-content: center; }
  .bf-fireplace-visual img { max-height: 28rem; max-width: min(100%, 35rem); }
  .bf-spark-card { min-height: auto; }
}
@media (max-width: 920px) {
  .bf-header {
    grid-template-columns: auto minmax(0, 1fr);
    height: auto;
    padding: 0.75rem 1rem;
  }
  .bf-brand img { height: 3rem; }
  .bf-repo { display: none; }
  .bf-shell {
    display: block;
    padding: 0 1rem;
  }
  .bf-sidebar {
    background: color-mix(in srgb, var(--bf-page-bg) 96%, transparent);
    border-bottom: 1px solid var(--bf-divider);
    margin: 0 -1rem 1.2rem;
    max-height: 10.5rem;
    overflow: auto;
    padding: 0.85rem 1rem;
    position: sticky;
    top: 4.15rem;
    z-index: 14;
  }
  .bf-sidebar::-webkit-scrollbar { height: 0.45rem; width: 0.45rem; }
  .bf-nav-group {
    display: inline-block;
    margin: 0 0.75rem 0 0;
    max-width: 14rem;
    vertical-align: top;
    white-space: normal;
    width: 13.5rem;
  }
  .bf-nav-group h2 {
    margin-bottom: 0.35rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .bf-nav-group a {
    font-size: 0.74rem;
    margin-bottom: 0.14rem;
    padding: 0.5rem 0.6rem;
  }
  .bf-nav-children {
    margin: 0.1rem 0 0.35rem 0.4rem;
    padding-left: 0.35rem;
  }
  .bf-content { margin-top: 1.2rem; }
  .bf-docs-fireplace-cta {
    margin-left: 0;
    margin-right: 0;
  }
  .bf-docs-hero--home {
    gap: 1.2rem;
    padding: 2.2rem clamp(1rem, 5vw, 2rem);
  }
  .bf-docs-hero--home h1 {
    font-size: clamp(2.8rem, 11vw, 5rem);
    max-width: 8ch;
  }
  .bf-fireplace-visual img {
    max-height: 24rem;
    max-width: min(100%, 30rem);
  }
}
@media (max-width: 760px) {
  .bf-header {
    grid-template-columns: 1fr;
    height: auto;
    padding: 0.8rem 1rem;
  }
  .bf-brand img { height: 2.75rem; }
  .bf-footer__brand img { height: 2.35rem; }
  .bf-repo { display: none; }
  .bf-shell {
    display: block;
    padding: 0 1rem 1rem;
  }
  .bf-sidebar {
    top: 7.35rem;
  }
  .bf-content { margin-top: 1.5rem; }
  .bf-article {
    font-size: 0.9rem;
    line-height: 1.62;
  }
  .bf-article h1 { font-size: clamp(2rem, 12vw, 2.7rem); }
  .bf-article h2 { font-size: 1.25rem; margin-top: 2.1rem; }
  .bf-figure-gallery { grid-template-columns: 1fr; }
  .bf-docs-hero--home {
    margin-left: 0;
    margin-right: 0;
    padding: 1.7rem 1rem;
  }
  .bf-docs-hero--home .bf-eyebrow {
    font-size: 0.56rem;
    letter-spacing: 0.28em;
    margin-bottom: 1.1rem;
  }
  .bf-docs-hero--home h1 {
    font-size: clamp(2.35rem, 13vw, 3.5rem);
    letter-spacing: -0.045em;
    line-height: 0.94;
  }
  .bf-hero-lead { font-size: 0.9rem; }
  .bf-fireplace-visual img { max-height: 18rem; }
  .bf-fireplace-actions { align-items: stretch; flex-direction: column; }
  .bf-fireplace-actions code { justify-content: center; width: 100%; }
  .bf-docs-actions--hero { grid-template-columns: 1fr; }
  .bf-spark-flow { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .bf-install-card__header {
    align-items: flex-start;
    flex-direction: column;
  }
  .bf-install-tabs { width: 100%; }
  .bf-install-tabs button { flex: 1; }
  .bf-footer {
    margin-top: 2.5rem;
    padding: 1.25rem 1rem 1.45rem;
  }
  .bf-footer__inner { display: block; }
  .bf-footer__note { margin-top: 1rem; max-width: none; text-align: left; }
}
@media (max-width: 520px) {
  .bf-search__results {
    left: 1rem;
    max-height: min(24rem, calc(100vh - 8.5rem));
    position: fixed;
    right: 1rem;
    top: 7.1rem;
  }
  .bf-sidebar {
    max-height: 8.7rem;
    top: 7.2rem;
  }
  .bf-nav-group {
    max-width: 12rem;
    width: 11.5rem;
  }
  .bf-docs-grid {
    grid-template-columns: 1fr;
  }
  .bf-table-wrap {
    border-radius: 0.9rem;
    margin-left: -0.2rem;
    margin-right: -0.2rem;
  }
  th, td { padding: 0.62rem 0.68rem; }
  .bf-code { border-radius: 0.95rem; margin-left: -0.1rem; margin-right: -0.1rem; }
  .bf-code pre { padding: 0.85rem; }
  .bf-docs-hero--home h1 { max-width: 7.5ch; }
  .bf-fireplace-visual img { max-height: 14.5rem; }
  .bf-footer__brand {
    align-items: flex-start;
  }
}
