/* Blog styles for 8085.ai - standalone (blog pages do not load the
   React bundle or site.css). Tokens copied from src/styles/globals.css;
   if the site palette changes, change it here too. */

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

@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/fonts/inter-var.woff2') format('woff2');
}

:root {
  --font-display: 'Space Grotesk', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --bg-cream: #F7F3EC;
  --ink: #16151A;
  --ink-soft: #4A4842;
  --orange: #B85320;
  --orange-deep: #9C4419;
  --teal: #1F7F74;
  --paper: #FFFDF9;
  --line: rgba(22, 21, 26, 0.12);
  --radius-card: 20px;
  --radius-pill: 999px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg-cream);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

.bshell { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.bshell--narrow { max-width: 760px; }

/* Header - the same floating pill bar as the landing page
   (.site-header in site.css); keep the two in sync. */
.bheader {
  position: fixed;
  inset: 16px 0 auto 0;
  z-index: 100;
  pointer-events: none;
}

.bheader__inner {
  pointer-events: auto;
  width: min(1240px, 100% - 32px);
  margin-inline: auto;
  display: flex;
  align-items: center;
  gap: 32px;
  height: 68px;
  padding-inline: 26px 12px;
  background: rgba(255, 253, 249, 0.94);
  backdrop-filter: blur(14px);
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  box-shadow: 0 4px 18px rgba(22, 21, 26, 0.06);
}

body { padding-top: 84px; }

.bbrand {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.35rem;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.bbrand em { font-style: normal; color: var(--orange); }

.bbrand--header {
  font-size: 1.8rem;
  letter-spacing: 0.04em;
  margin-right: auto;
}

.bnav { display: flex; gap: 28px; }

.bnav a {
  position: relative;
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
  color: var(--ink);
  padding-block: 6px;
}

.bnav a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 2px;
  border-radius: 2px;
  background: var(--orange);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 180ms ease-out;
}

.bnav a:hover::after { transform: scaleX(1); }

.bbtn {
  display: inline-block;
  background: var(--orange);
  color: var(--paper);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.9375rem;
  text-decoration: none;
  padding: 10px 20px;
  border-radius: var(--radius-pill);
}

.bbtn:hover { background: var(--orange-deep); }

/* Main */
.bmain { padding: clamp(40px, 7vw, 88px) 0 clamp(56px, 9vw, 128px); }

.beyebrow {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal);
  margin: 0 0 14px;
}

.beyebrow a { text-decoration: none; }

h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4.5vw, 3.25rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin: 0 0 16px;
  text-wrap: balance;
}

.blead { font-size: 1.25rem; color: var(--ink-soft); margin: 0 0 48px; }

.bbyline { color: var(--ink-soft); font-size: 0.9375rem; margin: 0 0 40px; }

/* Post body */
.bprose h2 {
  font-family: var(--font-display);
  font-size: 1.75rem;
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin: 44px 0 12px;
}

.bprose h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  margin: 32px 0 10px;
}

.bprose p { margin: 0 0 18px; }

.bprose a { color: var(--orange); text-decoration-thickness: 1px; }

.bprose ul, .bprose ol { padding-left: 24px; margin: 0 0 18px; }

.bprose li { margin-bottom: 8px; }

.bprose blockquote {
  margin: 24px 0;
  padding: 4px 0 4px 20px;
  border-left: 3px solid var(--orange);
  color: var(--ink-soft);
}

.bprose table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 12px;
  font-size: 0.9375rem;
}

.bprose th, .bprose td {
  text-align: left;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

.bprose th { font-family: var(--font-display); font-weight: 600; }

.bprose img { max-width: 100%; border-radius: 12px; }

.bprose code {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 1px 6px;
  font-size: 0.9em;
}

/* Author box + CTA */
.bauthor, .bcta {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  padding: 24px 28px;
  margin-top: 48px;
}

.bauthor__name { font-family: var(--font-display); font-weight: 600; margin: 0 0 8px; }

.bauthor p:last-child { margin: 0; color: var(--ink-soft); font-size: 0.9375rem; }

.bcta { text-align: center; }

.bcta p { margin: 0 0 18px; }

/* Resources hub: the two email offers are conversion blocks, not
   content cards - filled panels so they read as "do this", not
   "read this". */
.boffers {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin: 56px 0 0;
}

.boffer {
  border-radius: var(--radius-card);
  padding: 18px 22px;
  color: var(--paper);
}

.boffer__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255, 253, 249, 0.16);
  margin-bottom: 10px;
}

.boffer__icon .bicon {
  width: 20px;
  height: 20px;
  margin: 0;
}

.boffer--teal { background: var(--teal); }

.boffer--orange { background: var(--orange); }

.boffer__label {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  opacity: 0.85;
  margin: 0 0 12px;
}

.boffer h2 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  line-height: 1.2;
  margin: 0 0 8px;
  color: var(--paper);
}

.boffer p:not(.boffer__label) {
  margin: 0 0 14px;
  font-size: 0.875rem;
  opacity: 0.92;
}

.boffer__btn {
  display: inline-block;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.9375rem;
  text-decoration: none;
  padding: 10px 20px;
  border-radius: var(--radius-pill);
}

.boffer__btn:hover { background: var(--bg-cream); }

@media (max-width: 640px) {
  .boffers { grid-template-columns: 1fr; }
}

/* Typewriter heading on the hub - the typed span keeps its full text
   in the raw HTML, so crawlers always see the complete h1. */
.btype { color: var(--orange); }

.bcaret {
  display: inline-block;
  width: 3px;
  height: 0.9em;
  margin-left: 6px;
  vertical-align: -0.05em;
  border-radius: 2px;
  background: var(--orange);
  animation: bcaret-blink 1s steps(1) infinite;
}

@keyframes bcaret-blink { 50% { opacity: 0; } }

@media (prefers-reduced-motion: reduce) {
  .bcaret { animation: none; }
}

/* Resources hub: stat row under the lead */
.bhub-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: -28px 0 8px;
}

.bhub-stats span {
  font-family: var(--font-display);
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--ink-soft);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  padding: 6px 14px;
}

/* Automation library panel - layout says "collection", not "article" */
.blibrary {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  padding: 28px 32px;
}

.blibrary__copy h2 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  line-height: 1.2;
  margin: 0 0 10px;
}

.blibrary__copy h2 a { text-decoration: none; }

.blibrary__copy h2 a:hover { color: var(--orange); }

.blibrary__copy p { margin: 0 0 18px; color: var(--ink-soft); }

.blibrary__chips { display: flex; flex-wrap: wrap; gap: 8px 0; margin: 0 0 22px; }

/* Resources hub section headings */
.bhub-heading {
  font-family: var(--font-display);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal);
  margin: 48px 0 16px;
}

/* Tag pills */
.btag {
  display: inline-block;
  margin-left: 8px;
  padding: 2px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--teal);
  text-decoration: none;
  background: var(--bg-cream);
}

a.btag:hover { border-color: var(--teal); }

.btag--static { margin-left: 0; margin-right: 8px; }

/* Index cards */
.bcard {
  display: flex;
  gap: 20px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  padding: 28px 32px;
  margin-bottom: 20px;
  transition: border-color 160ms ease, transform 160ms ease;
}

.bcard:hover { border-color: var(--orange); transform: translateY(-2px); }

.bcard__body { min-width: 0; }

.bcard__num {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--orange);
  padding-top: 4px;
}

.bcard__meta { color: var(--ink-soft); font-size: 0.875rem; margin: 0 0 10px; }

.bcard h2 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  line-height: 1.2;
  margin: 0 0 10px;
}

.bcard h2 a { text-decoration: none; }

.bcard h2 a:hover { color: var(--orange); }

.bcard p { margin: 0 0 14px; color: var(--ink-soft); }

.bcard__more {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.9375rem;
  color: var(--orange);
  text-decoration: none;
}

/* Footer */
.bfooter { border-top: 1px solid var(--line); padding: 48px 0 24px; }

.bfooter__inner {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 32px;
  align-items: flex-start;
}

.bfooter__brand p { color: var(--ink-soft); font-size: 0.9375rem; margin: 8px 0 0; max-width: 260px; }

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

.bfooter__head {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink);
  margin: 0 0 2px;
}

.bfooter__col a {
  color: var(--ink-soft);
  font-size: 0.9375rem;
  text-decoration: none;
}

.bfooter__col a:hover { color: var(--orange); }

@media (max-width: 720px) {
  .bfooter__inner { grid-template-columns: 1fr 1fr; }
  .bfooter__brand { grid-column: 1 / -1; }
}

.bfooter__bottom { margin-top: 32px; }

.bfooter__bottom p { color: var(--ink-soft); font-size: 0.875rem; }

/* Icons (inline SVG from scripts/blog-icons.mjs) */
.bicon {
  width: 1.05em;
  height: 1.05em;
  vertical-align: -0.18em;
  margin-right: 8px;
  flex-shrink: 0;
}

/* Reading progress - CSS scroll-driven animation, no JS. Browsers
   without support simply never show the bar. */
.bprogress { display: none; }

@supports (animation-timeline: scroll()) {
  .bprogress {
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 20;
    width: 100%;
    height: 3px;
    background: var(--orange);
    transform-origin: 0 50%;
    transform: scaleX(0);
    animation: bprogress-grow linear;
    animation-timeline: scroll(root);
  }

  @keyframes bprogress-grow {
    from { transform: scaleX(0); }
    to { transform: scaleX(1); }
  }
}

/* "The short version" takeaways box. The accent is an inset pill,
   not a border-left - a colored border bends around the corner
   radius and looks unfinished. */
.btakeaways {
  position: relative;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 20px 24px 20px 28px;
  margin: 0 0 28px;
}

.btakeaways::before {
  content: '';
  position: absolute;
  left: 10px;
  top: 18px;
  bottom: 18px;
  width: 3px;
  border-radius: 999px;
  background: var(--orange);
}

.btakeaways__label {
  display: flex;
  align-items: center;
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--orange);
  margin: 0 0 10px;
}

.btakeaways ul { margin: 0; padding-left: 20px; }

.btakeaways li { margin-bottom: 6px; }

.btakeaways li:last-child { margin-bottom: 0; }

/* "On this page" table of contents */
.btoc {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 18px 24px;
  margin: 0 0 32px;
  font-size: 0.9375rem;
}

.btoc__label {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal);
  margin: 0 0 8px;
}

.btoc ul { margin: 0; padding-left: 20px; }

.btoc li { margin-bottom: 4px; }

.btoc a { color: var(--ink-soft); text-decoration-thickness: 1px; }

.btoc a:hover { color: var(--orange); }

/* Heading anchor links - visible on hover, tap targets on touch */
.banchor {
  margin-left: 8px;
  color: var(--line);
  text-decoration: none;
  font-weight: 400;
}

.bprose h2:hover .banchor, .bprose h3:hover .banchor, .banchor:focus { color: var(--orange); }

/* Callouts (:::note / :::tip / :::warning) - same inset-pill accent
   as the takeaways box */
.bcallout {
  position: relative;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px 22px 16px 26px;
  margin: 24px 0;
}

.bcallout::before {
  content: '';
  position: absolute;
  left: 10px;
  top: 16px;
  bottom: 16px;
  width: 3px;
  border-radius: 999px;
}

.bcallout--note::before { background: var(--teal); }

.bcallout--tip::before { background: var(--orange); }

.bcallout--warning::before { background: var(--orange-deep); }

.bcallout__label {
  display: flex;
  align-items: center;
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin: 0 0 8px;
}

.bcallout--note .bcallout__label { color: var(--teal); }

.bcallout--tip .bcallout__label, .bcallout--warning .bcallout__label { color: var(--orange); }

.bcallout__body p { margin: 0 0 12px; }

.bcallout__body p:last-child { margin: 0; }

/* Pull quote - one big statement per post */
.bprose .bpull {
  border: none;
  padding: 8px 0;
  margin: 32px 0;
  font-family: var(--font-display);
  font-size: 1.5rem;
  line-height: 1.3;
  letter-spacing: -0.01em;
  color: var(--ink);
}

/* Inline diagrams */
.bdiagram {
  margin: 32px 0;
  padding: 24px 20px 16px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
}

.bdiagram svg { display: block; width: 100%; height: auto; }

.bdiagram figcaption {
  margin-top: 12px;
  text-align: center;
  font-size: 0.875rem;
  color: var(--ink-soft);
}

/* Mid-post micro-CTA */
.bcta-mini {
  display: flex;
  align-items: flex-start;
  gap: 4px;
  background: var(--paper);
  border: 1px dashed var(--orange);
  border-radius: 12px;
  padding: 16px 22px;
  margin: 28px 0;
  font-size: 0.9375rem;
}

.bcta-mini .bicon { color: var(--orange); margin-top: 4px; }

.bcta-mini p { margin: 0; color: var(--ink-soft); }

.bcta-mini a { color: var(--orange); }

/* Closing CTA refinements (stage-dependent blocks) */
.bcta__lead { margin: 0 0 18px; }

.bcta__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin: 0 0 16px;
}

.bcta__actions .bbtn { display: inline-flex; align-items: center; }

.bcta__micro { margin: 0; font-size: 0.875rem; color: var(--ink-soft); }

.bcta__micro a { color: var(--orange); }

.bbtn--ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--ink);
}

.bbtn--ghost:hover { background: var(--ink); color: var(--paper); }

/* Previous / next navigation between guides and workflows */
.bpn {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 32px;
}

.bpn__item {
  display: block;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px 20px;
  text-decoration: none;
}

.bpn__item:hover { border-color: var(--orange); }

.bpn__item--next { text-align: right; }

.bpn__dir {
  display: block;
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--teal);
  margin-bottom: 4px;
}

.bpn__title {
  display: block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.9375rem;
  color: var(--ink);
}

.bpn__item:hover .bpn__title { color: var(--orange); }

@media (max-width: 640px) {
  .bpn { grid-template-columns: 1fr; }
  .bpn__item--next { text-align: left; }
}

/* Author page hero */
.bauthor-hero {
  display: flex;
  align-items: center;
  gap: 28px;
  margin: 0 0 32px;
}

.bauthor-hero__mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background: var(--orange);
  color: var(--paper);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 2rem;
  letter-spacing: -0.02em;
  flex-shrink: 0;
}

.bauthor-hero h1 { margin: 0 0 6px; font-size: clamp(1.75rem, 3.5vw, 2.5rem); }

.bauthor-hero .bbyline { margin: 0 0 14px; }

.bauthor-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0;
}

.bauthor-hero__actions .bbtn { display: inline-flex; align-items: center; }

@media (max-width: 640px) {
  .bauthor-hero { flex-direction: column; align-items: flex-start; gap: 16px; }
}

/* "Keep reading" related posts */
.bkeepreading { margin-top: 48px; }

.bkeepreading__label {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal);
  margin: 0 0 14px;
}

.bkeepreading__item {
  display: block;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px 22px;
  margin-bottom: 12px;
  text-decoration: none;
}

.bkeepreading__item:hover { border-color: var(--orange); }

.bkeepreading__title {
  display: block;
  font-family: var(--font-display);
  font-weight: 600;
  margin-bottom: 4px;
}

.bkeepreading__item:hover .bkeepreading__title { color: var(--orange); }

.bkeepreading__desc { display: block; font-size: 0.9375rem; color: var(--ink-soft); }

@media (max-width: 640px) {
  .bnav { display: none; }
  .bheader__inner { justify-content: space-between; }
  /* keep diagram labels readable: scroll sideways instead of shrinking */
  .bdiagram { padding: 16px 10px 12px; overflow-x: auto; }
  .bdiagram svg { min-width: 640px; }
  .bcta__actions { flex-direction: column; align-items: center; }
}
