/* 2.4.6 — literal sweep: a literal whose value IS a token became it; the rest is a value this
   file paints by hand and is counted in the report. The names are global-2026.css's own aliases (2.4.2); a value only the system holds is written --pui-*. */
/* =========================================================================
   PAGE: BLOG HUB (/blog) — page-specific CSS.
   Linked from public/blog/index-new.blade.php @section('css'). All rules
   scoped under .page-blog. Design tokens (--color-*, --fs-*, --radius-*),
   the global .page-eyebrow, the global .arrow-link, the .footer-2026 block
   and the nav all live in /css/new/global-2026.css — NOT duplicated here.

   This file holds:
     1. Anti-cascade overrides (defeat layout.min.css + bootstrap.min.css)
     2. Page layout / sticky footer / search-filter / card grid
     3. The shared BLOG COMPONENTS (.blog-feature, .blog-card, .badge) —
        promoted here scoped to .page-blog (the blog-article page keeps its
        own copy when it is ported).

   Breakpoints: mobile <768 · tablet 768..1023 · desktop >=1024 (content 1320).
   ========================================================================= */

/* ---------- Anti-cascade overrides (defeat layout.min.css + bootstrap.min.css) ---------- */
/* 2.4.2 — guard: the page's anti-cascade resets (`button`, `a:link…`) outrank a one-class component (0,1,1 / 0,2,1 over
   0,1,0); they now skip any element carrying a pui- class (inside :where(), so their specificity is unchanged — D60) and the package paints its own. */
.page-blog a:where(:not([class*="pui-"])):link,
.page-blog a:where(:not([class*="pui-"])):visited,
.page-blog a:where(:not([class*="pui-"])):hover,
.page-blog a:where(:not([class*="pui-"])):focus,
.page-blog a:where(:not([class*="pui-"])):active { color: inherit; text-decoration: none; }

.page-blog button:where(:not([class*="pui-"])) {
  font-family: inherit;
  border: 0;
  background: transparent;
  padding: 0;
  cursor: pointer;
}

.page-blog ul { list-style: none; padding: 0; margin: 0; }
.page-blog img { display: block; max-width: 100%; }

.page-blog .container {
  width: 1320px;
  max-width: 1320px;
  padding-left: var(--pui-space-12);
  padding-right: var(--pui-space-12);
  margin-left: auto;
  margin-right: auto;
  position: relative;
}


/* ---------- Sticky footer ----------
   Footer comes from @include('blocks.footer-2026') (a .footer-2026 wrapper
   placed inside .blog-main), not the prototype's old .footer-wrap.
   margin-top:auto pushes it to the bottom; the global .footer-2026 already
   provides the 24px bottom margin + the blob that extends 30px below. */
.page-blog {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.page-blog .blog-main {
  flex: 1 0 auto;
  display: flex;
  flex-direction: column;
  padding-top: var(--page-top);   /* the eyebrow's line — --page-top in global-2026.css (132 / 116 / 96), no per-breakpoint line */
  padding-bottom: 0;
}
.page-blog .blog-main > .footer-2026 { margin-top: auto; }

/* Eyebrow uses the global .page-eyebrow class. */

/* ---------- Featured banner — page SPACING only (the look is the shared
   .blog-feature component below). ---------- */
.page-blog .blog-feature--gradient { margin-bottom: var(--pui-space-24); }
.page-blog .blog-feature--light { margin-bottom: var(--pui-space-48); }

/* ===========================================================
   SEARCH / FILTER BLOCK
   Categories select + search field reuse the shared shadcn
   controls (.job-select + .job-search) — identical to careers,
   only the select is wider here. Pills are the category quick-filter.
   =========================================================== */
.page-blog .blog-filters {
  margin-bottom: var(--pui-space-24);
  display: flex;
  flex-direction: column;
  gap: var(--pui-space-24);
}
.page-blog .blog-filters__row {
  display: flex;
  align-items: center;
  gap: var(--pui-space-16);   /* C2 — Fedor, 2026-09-25: the dropdowns 16 apart, space/16 by name (B had put the row on space/24) */
}

/* ---- shadcn select (reused from careers; only width differs) ---- */
.page-blog .job-select {
  position: relative;
  flex: 0 0 345px;
  width: 345px;
}
.page-blog .pui-select {
  justify-content: space-between;
  width: 100%;
  text-align: left;
  /* R — request 19 shipped: the fill is .pui-select--filled */
  /* B — the trigger (36 tall — the site's 55, D41; padding 8 / 12 — the site's 10 / 8 / 10 / 16; surface/page — the site's surface/card tint, stated; a 1 px border/default line — the site's #e5e5e5; radius 8; 14 Regular; elevation/flat; hover border/strong, the ring on focus and while open) is .pui-select; `width: 100%`, the space-between and `text-align: left` stay */
}
.page-blog .pui-select__chevron {
  /* C2 — the chevron is the kit's 16 px glyph in text/muted (.pui-select__chevron); the site's 10 × 6 file size went with step C's swap (Fedor's find) — its turn on open stays */
  transition: transform var(--pui-motion-move) var(--pui-motion-easing);
}
.page-blog .job-select[data-state="open"] .pui-select__chevron { transform: rotate(180deg); }

.page-blog .pui-select-menu {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  z-index: 50;
  max-height: 280px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  transform-origin: top center;
  opacity: 0;
  transform: scale(0.95) translateY(-8px);
  visibility: hidden;
  pointer-events: none;
  transition:
    opacity var(--pui-motion-state) var(--pui-motion-easing),
    transform 0.15s var(--pui-motion-easing-enter),
    visibility 0s linear 0.15s;
  /* B — the menu (surface/page, border/default, radius 8, padding 4, elevation/floating — the site's shadcn 0 4 6 pair, stated; rows stacked at 0 — the site's gap 2) is .pui-select-menu; the placing (absolute, 4 px under the trigger), the 280 cap, the scroll, the column and the site's open/close motion stay */
}
.page-blog .job-select[data-state="open"] .pui-select-menu {
  opacity: 1;
  transform: scale(1) translateY(0);
  visibility: visible;
  pointer-events: auto;
  transition:
    opacity var(--pui-motion-state) var(--pui-motion-easing),
    transform 0.15s var(--pui-motion-easing-enter),
    visibility 0s;
}
@media (prefers-reduced-motion: reduce) {
  .page-blog .pui-select-menu,
  .page-blog .job-select[data-state="open"] .pui-select-menu {
    transition: visibility 0s;
    transform: none;
  }
}

/* ---- search field (reused from careers) ---- */
.page-blog :where(.blog-filters__row) .pui-input-group {
  flex: 1 1 0;
  min-width: 0;
  /* B — the box (36 min — the site's 55, D41; padding 3 / 3 / 3 / 11 — the site's 9.5 / 8 / 9.5 / 16; gap 8; surface/page; a 1 px border/default line — the site's neutral/300, stated; radius 8; elevation/flat; the ring on focus-within) is .pui-input-group; `flex` and `min-width` stay — the row's layout */
}
.page-blog :where(.pui-input-group) > .pui-button {
  flex: 0 0 auto;
  /* B — the button is the kit's small primary Button inside the group (28 tall at radius 4 with the 4 inset, D47; 12 Medium — the site's 14; action/primary/bg — the site's neutral/600 grey was no Button variant, stated: beside an input the button is the black one, D59) */
}
/* B — the hover is the kit's */

/* ---- category pills (quick filter) ---- */
/* B — the hover is the kit's (tint/neutral/bg — the site's neutral/200 is the same) */
/* Pills hidden by the "tags used in this category" filter drop out of the flow. */
.page-blog .pui-toggle[hidden] { display: none; }

/* ===========================================================
   CARD GRID (DYNAMIC) — 4 cols desktop. Cards are the shared
   .blog-card component; this only sets the grid layout.
   =========================================================== */
.page-blog .blog-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 42px 46px;          /* row-gap  column-gap */
  margin-bottom: var(--pui-space-48);
}

/* The case-study block lives INSIDE .blog-grid as a full-width member so the JS
   can re-seat it after the 8th visible card at any filter state. The grid's
   row-gap handles its spacing (so its own vertical margin is dropped). */
.page-blog .blog-grid > .blog-grid__case { grid-column: 1 / -1; margin: 0; }

/* Empty state (filter) */
.page-blog :where(.blog-main) > .container > .pui-text--body-medium {
  margin: 0 0 var(--pui-space-48);
  padding: var(--pui-space-32) 0;
  color: var(--pui-text-subtle);
}
.page-blog :where(.blog-main) > .container > .pui-text--body-medium[hidden] { display: none; }

/* ---------- Load more (client-side paging: reveals +16 news cards per click) ---------- */
.page-blog .blog-loadmore {
  display: flex;
  justify-content: center;
  margin: var(--pui-space-8) 0 var(--pui-space-64);
}
.page-blog .blog-loadmore[hidden] { display: none; }
.page-blog :where(.blog-loadmore) > .pui-button {
  white-space: nowrap;
  /* A1 — Load more is .pui-button--large (44 tall, 16 px — the page's 48 with 12 / 36, stated) */
}
/* A1 — its hover, pressed and focus ring are the Button's */
/* A1 — its pressed state is the Button's */
/* A1 — its focus ring is the Button's (border/focus) */

/* =========================================================================
   SHARED BLOG COMPONENTS — featured banner, blog card, tag badge.
   Scoped to .page-blog so they win over Bootstrap's global .badge and never
   leak. The component LOOK lives here; page spacing/grid stays above.
   ========================================================================= */

/* ---- Featured banner: text + image. Variants: --gradient (purple→pink,
   white title) · --light (grey card + shadow) · --plain (grey card, no shadow). ---- */
.page-blog .blog-feature {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--pui-space-32);
  padding: var(--pui-space-32);
  border-radius: var(--pui-radius-32);          /* 32 */
}
.page-blog .blog-feature--gradient {
  background-image: linear-gradient(150.35deg,
    color-mix(in srgb, var(--pui-color-blue-400) 69%, transparent) 30.59%,
    rgba(242, 66, 136, 0.69) 125.66%);
}
.page-blog .blog-feature--light {
  background: var(--pui-surface-card);   /* #f2f2f7 */
  box-shadow: var(--pui-elevation-card);   /* Figma shadow_XL */
}
.page-blog .blog-feature--plain { background: var(--pui-surface-card); }   /* #f2f2f7, no shadow */

.page-blog .blog-feature__body {
  flex: 0 0 704px;          /* fixed so the title wraps like Figma; the gap to the
                              image is the space-between */
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--pui-space-24);
}
.page-blog .blog-feature--light .blog-feature__body { flex-basis: 711px; }

.page-blog .blog-feature__head {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--pui-space-8);
  width: 100%;
}


.page-blog .blog-feature__badges { display: flex; flex-wrap: wrap; gap: var(--pui-space-8); }

.page-blog .blog-feature__media {
  flex: 0 0 411px;
  align-self: center;
  aspect-ratio: 411 / 231;                  /* fixed Figma crop — don't let the source image dictate height */
  border-radius: var(--pui-radius-16);          /* 16 */
  overflow: hidden;
}
.page-blog .blog-feature--light .blog-feature__media {
  flex-basis: 459px;
  aspect-ratio: 459 / 226;
}
.page-blog .blog-feature__media img { width: 100%; height: 100%; object-fit: cover; }

/* read-more arrow-link tone per surface (the hub posts have one; the article hero doesn't) */
/* R — request 23: the gradient card's link is .pui-link--on-dark */

/* ---- Blog card (about-us/cases pattern): media → foot (title + badges + circular arrow). ---- */
.page-blog :where(.blog-grid) .pui-card {
  /* the inset and the clamp are the block's (preview-card--compact --clamp, global-2026.css) — 2026-10-05 */
  /* P2 — the white box, the 1 px border/default line and radius 16 are .pui-card--border — card.css names the blog card's line as its source. `padding: 12px 12px 0` STAYS: Card's is space/20 and the hub's grid is built on 12 (stated) */
}
.page-blog .pui-card__media {
  width: 100%;
  aspect-ratio: 265 / 147;
  /* P2 — the 8 radius and the crop are .pui-card__media; the 265/147 aspect stays — the package's is 16/9; the media well's surface/sunken shows while an image loads */
}

/* Full-title tooltip — a single floating element (built in JS) that follows the
   cursor, shown ~250ms after hovering a card whose title is truncated. Black
   frosted glass (semi-transparent + blur, like the nav). Appended to <body> so
   it's never clipped by the grid/page; positioned via JS. */
.blog-card-tip {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 9999;
  max-width: 300px;
  padding: 9px 13px;
  background: color-mix(in srgb, var(--pui-color-neutral-1000) 62%, transparent);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  color: var(--pui-color-neutral-0);
  font-family: 'Poppins', sans-serif;
  font-weight: var(--pui-font-weight-400);
  font-size: var(--pui-font-size-13);
  line-height: 1.45;
  border-radius: 10px;
  border: 1px solid color-mix(in srgb, var(--pui-color-neutral-0) 12%, transparent);
  box-shadow: var(--pui-elevation-card);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.12s ease;
}
.blog-card-tip.is-visible { opacity: 1; }

/* 2.4.2 — the tag badge (2 / 4, radius 4, 12 Regular, the four tints) is .pui-badge--small + its tone — badge.css quotes these lines */
/* ---- Featured banner responsive (component-level; page margins stay page-side) ---- */
@media (max-width: 1023px) {
  .page-blog .blog-feature__body { flex: 1 1 auto; }
  .page-blog .blog-feature__media { flex: 0 0 327px; }
  .page-blog .blog-feature--light .blog-feature__media { flex-basis: 303px; }
}
@media (max-width: 767px) {
  .page-blog .blog-feature {
    flex-direction: column;
    align-items: stretch;
    gap: var(--pui-space-16);
    padding: var(--pui-space-24);
  }
  .page-blog .blog-feature__body,
  .page-blog .blog-feature--light .blog-feature__body {
    flex: 0 0 auto;
    order: 2;
    gap: var(--pui-space-16);
  }
  .page-blog .blog-feature__media,
  .page-blog .blog-feature--light .blog-feature__media {
    flex: 0 0 auto;
    order: 1;
    width: 100%;
  }
  .page-blog .blog-feature__media { aspect-ratio: 327 / 184; }
  .page-blog .blog-feature--light .blog-feature__media { aspect-ratio: 322 / 159; }
}

/* =========================================================================
   TABLET — 768 .. 1023  (3-col grid; the banner responsive is above)
   ========================================================================= */
@media (max-width: 1023px) {
  .page-blog .container {
    width: 100%;
    max-width: 100%;
    padding-left: var(--pui-space-32);
    padding-right: var(--pui-space-32);
  }
  .page-blog .blog-grid { grid-template-columns: repeat(3, 1fr); gap: var(--pui-space-24) var(--pui-space-16); }
}

/* =========================================================================
   MOBILE — <768  (search stacks, 1-col grid)
   ========================================================================= */
@media (max-width: 767px) {
  .page-blog .container { padding-left: var(--pui-space-16); padding-right: var(--pui-space-16); }

  /* Search/filter stacks: select full-width, search full-width, pills wrap. */
  .page-blog .blog-filters__row {
    flex-direction: column;
    align-items: stretch;
    gap: var(--pui-space-16);
  }
  .page-blog .job-select {
    flex: 1 1 auto;
    width: 100%;
  }

  .page-blog .blog-grid { grid-template-columns: 1fr; gap: var(--pui-space-16); }
}

/* STEP 12 (2026-09-28) — a design-system part carries the design system's classes only; this page reaches a part through the block that holds it
   and states only what is the page's (a width in a row, a place in a grid, a picture's ratio). */
/* THE FEATURE BANNER'S TITLE — a role as a class (headline/medium on the gradient and the plain banner, headline/small on the light one);
   the page states its weight, its ink and its tracking by name, and below 1024 — where the banner is narrow — the size of a smaller role. */
.page-blog .blog-feature__body > :is(.pui-text--headline-medium, .pui-text--headline-small) {
  margin: 0;
  color: var(--pui-text-default);
}
.page-blog .blog-feature--gradient .blog-feature__body > .pui-text--headline-medium { color: var(--pui-text-on-accent); }
@media (max-width: 1023px) {
  .page-blog .blog-feature__body > .pui-text--headline-small { font-size: var(--pui-type-body-large-font-size); }
  .page-blog .blog-feature__body > .pui-text--headline-medium { font-size: var(--pui-type-title-small-font-size); }   /* the size pin stays (request 61) — restored 2026-10-05 */
}
/* STEP 12 · TOKENS — the site's alias names became the design system's; a typed value that equals a token is the token */
