/* ══════════════════════════════════════════════════════════════════
   BLOG INDEX, v3
   Direction: compact intro, one large full width featured banner, then a
   visual article grid that dominates the page. The grid is the content.

   Loads after home-v2.css and service-v2.css, which supply tokens, .wrap,
   .sig, .ovl, .btn and the section background classes.

   Every article has a real 1200x628 featured image, so there are no CSS
   editorial covers here and no stock imagery. Square editorial framing,
   thin rules, no shadows, no gradients, no floating cards.
   ══════════════════════════════════════════════════════════════════ */

/* ── 1. Compact intro ────────────────────────────────────────────── */

/* home-v2.css already gives a section 140px of top padding to clear the fixed
   header, and .bintro was adding its own on top of that, so the label sat
   155px below a 71px header. The section pad is zeroed here and .bintro owns
   the whole distance, which keeps it to one number instead of two stacked. */
.bintro-sec{padding-top:0}
.bintro{padding:132px 0 46px}
@media(max-width:760px){.bintro{padding:112px 0 32px}}
.bintro h1{font-size:clamp(30px,4.4vw,50px);line-height:1.08;letter-spacing:-.03em;font-weight:600;margin:14px 0 0;max-width:19ch}
.bintro p{font-size:clamp(14.5px,1.4vw,16.5px);line-height:1.65;color:var(--gray,#6B6B6B);margin:18px 0 0;max-width:60ch}
.bintro-n{font-family:var(--mono);font-size:10.5px;letter-spacing:.16em;text-transform:uppercase;color:var(--gray,#6B6B6B);margin:26px 0 0;display:flex;align-items:center;gap:10px}
.bintro-n::before{content:"";width:26px;height:1px;background:var(--black,#0A0A0A)}

/* ── 2. Filter tabs ──────────────────────────────────────────────── */

.bfbar{display:flex;align-items:flex-end;justify-content:space-between;gap:26px;flex-wrap:wrap;
  padding-bottom:16px;border-bottom:1px solid var(--ll,rgba(10,10,10,.16))}
.bfbar h2{font-family:var(--mono);font-size:11px;letter-spacing:.18em;text-transform:uppercase;
  color:var(--black,#0A0A0A);font-weight:500;margin:0}
.bftabs{display:flex;flex-wrap:wrap;gap:4px 0}
.bftabs button{appearance:none;background:none;border:0;cursor:pointer;position:relative;
  font-family:var(--mono);font-size:11px;letter-spacing:.13em;text-transform:uppercase;color:var(--gray,#6B6B6B);
  padding:7px 16px 9px;transition:color var(--t-fast,150ms)}
.bftabs button::after{content:"";position:absolute;left:16px;right:16px;bottom:-17px;height:2px;background:transparent;transition:background var(--t-fast,150ms)}
.bftabs button:hover{color:var(--black,#0A0A0A)}
.bftabs button[aria-pressed="true"]{color:var(--black,#0A0A0A)}
.bftabs button[aria-pressed="true"]::after{background:var(--acid,#E9FF5C)}
.bftabs button:focus-visible{outline:2px solid var(--black,#0A0A0A);outline-offset:-1px}
.bfcount{font-family:var(--mono);font-size:10.5px;letter-spacing:.14em;text-transform:uppercase;color:var(--gray,#6B6B6B);margin:20px 0 0}
@media(max-width:700px){
  .bfbar{align-items:flex-start;gap:14px}
  .bftabs button{padding:7px 14px 9px;font-size:10px}
  .bftabs button::after{left:14px;right:14px}
}

/* ── 3. Article grid ─────────────────────────────────────────────── */

.bgrid{display:grid;grid-template-columns:1fr;gap:44px 28px;margin-top:44px;list-style:none;padding:0}
@media(min-width:700px){.bgrid{grid-template-columns:repeat(2,1fr);gap:52px 28px}}
@media(min-width:1080px){.bgrid{grid-template-columns:repeat(3,1fr);gap:60px 30px}}

.bcard{position:relative;display:flex;flex-direction:column;min-width:0}
.bcard[hidden]{display:none}
/* ratio matches the 1200x628 source exactly, so cover has nothing to crop
   and the baked in artwork text is never cut */
.bcard-img{position:relative;overflow:hidden;aspect-ratio:1200/628;background:var(--black,#0A0A0A);
  border:1px solid var(--ll,rgba(10,10,10,.16))}
.bcard-img img{display:block;width:100%;height:100%;object-fit:cover;transition:transform var(--t-slow,400ms) ease}
.bcard:hover .bcard-img img{transform:scale(1.015)}
/* acid rule that appears under the image on hover, the only colour accent */
.bcard-img::after{content:"";position:absolute;left:0;right:0;bottom:0;height:3px;background:var(--acid,#E9FF5C);
  transform:scaleX(0);transform-origin:0 50%;transition:transform var(--t-base,250ms)}
.bcard:hover .bcard-img::after{transform:scaleX(1)}
.bcard-c{font-family:var(--mono);font-size:10px;letter-spacing:.15em;text-transform:uppercase;color:var(--gray,#6B6B6B);margin-top:20px;display:block}
.bcard h3{font-size:clamp(19px,1.6vw,23px);line-height:1.25;letter-spacing:-.018em;font-weight:600;margin:11px 0 0}
.bcard h3 a{color:inherit;text-decoration:none;border-bottom:0}
/* one link per card, stretched over the whole tile */
.bcard h3 a::after{content:"";position:absolute;inset:0}
.bcard:hover h3{text-decoration:underline;text-underline-offset:4px;text-decoration-thickness:1px}
.bcard h3 a:focus-visible{outline:2px solid var(--black,#0A0A0A);outline-offset:4px}
.bcard p{font-size:14.5px;line-height:1.65;color:var(--gray,#6B6B6B);margin:11px 0 0;
  display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}
/* p.bcard-m, not .bcard-m. The excerpt rule .bcard p is (0,1,1) and sets
   -webkit-box with a line clamp, which beat a bare .bcard-m at (0,1,0) and
   collapsed the meta row so the reading time and arrow sat on top of each
   other. Matching the element raises this to (0,1,1) and it loads later. */
p.bcard-m{display:flex;align-items:center;gap:14px;margin-top:16px;padding-top:14px;
  border-top:1px solid var(--ll,rgba(10,10,10,.14));-webkit-line-clamp:none;overflow:visible}
.bcard-t{font-family:var(--mono);font-size:10.5px;letter-spacing:.13em;text-transform:uppercase;color:var(--gray,#6B6B6B)}
.bcard-a{margin-left:auto;font-size:16px;line-height:1;color:var(--gray,#6B6B6B);transition:transform var(--t-base,250ms),color var(--t-base,250ms)}
.bcard:hover .bcard-a{transform:translateX(4px);color:var(--black,#0A0A0A)}

/* Seven non featured articles leave a single orphan in a 3 column grid.
   The last visible one becomes a deliberate wide tile instead, image beside
   copy, so the final row reads as a design decision rather than a gap.
   .is-last is applied by the filter script, because which card is last
   changes when a filter is applied and a stale wide tile breaks the grid. */
@media(min-width:700px){
  .bcard.is-last{grid-column:1 / -1;display:grid;grid-template-columns:minmax(0,1.15fr) minmax(0,1fr);
    gap:34px;align-items:center}
  .bcard.is-last .bcard-img{aspect-ratio:1200/628}
  .bcard.is-last .bcard-c{margin-top:0}
  .bcard.is-last h3{font-size:clamp(22px,2vw,28px)}
  .bcard.is-last p{-webkit-line-clamp:4}
}

.bempty{font-family:var(--mono);font-size:11.5px;letter-spacing:.08em;color:var(--gray,#6B6B6B);padding:56px 0;text-align:center}
.bgrid-foot{display:flex;align-items:center;gap:16px;margin-top:56px;padding-top:20px;border-top:1px solid var(--ll,rgba(10,10,10,.16));
  font-family:var(--mono);font-size:10.5px;letter-spacing:.14em;text-transform:uppercase;color:var(--gray,#6B6B6B)}
.bgrid-foot button{appearance:none;background:none;border:0;cursor:pointer;margin-left:auto;
  font-family:var(--mono);font-size:10.5px;letter-spacing:.14em;text-transform:uppercase;color:var(--black,#0A0A0A);
  border-bottom:1px solid var(--black,#0A0A0A);padding:0 0 3px}
.bgrid-foot button[hidden]{display:none}
.bgrid-foot button:focus-visible{outline:2px solid var(--black,#0A0A0A);outline-offset:3px}

/* ── 4. Shared CTA partial, v2 override ──────────────────────────
   cta-section.html is authored against the legacy globals/blog-post stack and
   uses --yellow, --off-white, --font-mono and --radius-btn, none of which
   exist in the v2 token set. Without this block the partial renders completely
   unstyled on any v2 page. Ported from dist/css/pages/blog-post.css so the
   index matches the article pages exactly.
   ───────────────────────────────────────────────────────────────── */

.cta-section{background:var(--black,#0A0A0A);padding:96px 0}
@media(max-width:860px){.cta-section{padding:68px 0}}
/* the legacy partial ships decorative grid and glow layers, which the current
   design language does not use */
.cta-bg-grid,.cta-bg-glow-top,.cta-bg-glow-corner{display:none}

.cta-section .container{max-width:1180px;margin:0 auto;padding:0 24px}
@media(min-width:1280px){.cta-section .container{padding:0 32px}}
.cta-card{background:none;border:0;padding:0;max-width:640px;position:relative}
.cta-content{position:relative}

.cta-section .label-tag{font-family:var(--mono);font-size:11px;font-weight:500;text-transform:uppercase;
  letter-spacing:.1em;color:var(--acid,#E9FF5C);display:inline-block;background:none;border:0;padding:0;margin:0}
.cta-headline{font-family:var(--sans);font-size:clamp(27px,3vw,40px);font-weight:600;color:var(--paper,#FAF9F5);
  letter-spacing:-.025em;line-height:1.15;margin:16px 0 18px}
.cta-headline .gradient-text{color:var(--acid,#E9FF5C);background:none;-webkit-text-fill-color:currentColor}
.cta-subtext{font-family:var(--sans);font-size:16px;color:rgba(250,249,245,.65);line-height:1.7;
  max-width:56ch;margin:0 0 32px}

.cta-group{display:flex;align-items:center;gap:14px;flex-wrap:wrap;margin-bottom:20px}
.cta-section .btn{display:inline-flex;align-items:center;gap:8px;font-family:var(--sans);font-size:15px;
  font-weight:600;padding:16px 32px;border-radius:8px;text-decoration:none;border:2px solid transparent;
  white-space:nowrap;cursor:pointer;
  transition:background-color var(--t-fast,150ms),border-color var(--t-fast,150ms),color var(--t-fast,150ms),transform var(--t-fast,150ms)}
.cta-section .btn-primary{background:var(--acid,#E9FF5C);color:var(--black,#0A0A0A)}
.cta-section .btn-primary:hover{transform:translateY(-2px);color:var(--black,#0A0A0A)}
.cta-section .btn-secondary{background:transparent;color:var(--paper,#FAF9F5);border:1.5px solid rgba(250,249,245,.22)}
.cta-section .btn-secondary:hover{border-color:var(--acid,#E9FF5C);color:var(--acid,#E9FF5C)}
.cta-section .btn:focus-visible{outline:2px solid var(--acid,#E9FF5C);outline-offset:3px}

.cta-fine-print{font-family:var(--sans);font-size:13px;color:rgba(250,249,245,.38);line-height:1.5;margin:0;max-width:none}

@media(max-width:639px){
  .cta-headline{margin-top:12px}
  .cta-group{flex-direction:column;align-items:stretch}
  .cta-section .btn{justify-content:center}
}

/* ── Reduced motion ──────────────────────────────────────────────── */

@media(prefers-reduced-motion:reduce){
  .bcard-img img,.bcard-img::after,.bcard-a,.bftabs button::after{transition:none}
  .bcard:hover .bcard-img img{transform:none}
  .bcard:hover .bcard-img::after{transform:scaleX(1)}
  .bcard:hover .bcard-a{transform:none}
}
