/* ============================================================
   elements.css — typographic element base + per-page deltas

   Source: live computed styles, 2026-11-16, https://10.0.0.185:5112
   Header and footer excluded from every measurement.

       /                                 -> lh-home
       /hydraulic-products/piston-pumps   -> lh-group-series
       /hydraulic-products/f1-series      -> lh-series
       /product/{id}                      -> lh-product

   NAMESPACE
       .lh-      every class in this file
       .lh-<el>          the base for an element
       .lh-<el>--<role>  the role that element plays

   Both classes sit on the SAME element, base first:

       <h1 class="lh-h1 lh-h1--section">Piston Pumps</h1>

   A variant names a ROLE, never a page. A page-named class
   (.lh-home-h2, .lh-product-p) needs inventing for every new page and
   lets each page drift again — that shape was retired with the h1 pass
   and the last eight instances were removed 2026-11-17. A page that does
   not differ gets no modifier. Absent, not empty.

   WIRED: App.razor links this file after main.css and before the scoped
   bundles. Current adoption (2026-11-18): breadcrumbs are used site-wide
   through BreadCrumb.razor, the H1 group is applied across the public
   pages, and the TITLE roles render on /, /industries, /trading-cards,
   /contact-us and the product page. The HR group is adopted on all 27 bare
   <hr> sites, replacing Bootstrap's default hairline (owner-chosen 12%,
   2026-11-18); BAND is adopted by the two /trading-cards full-bleed
   sections; RAIL by both product-page rails; GALLERY by the two promotion
   components. The P group is defined but has no consumer, and there is no
   TABLE group: .spec-table only ever arrives as CMS-injected raw HTML, so
   its markup cannot take a class.

   NAMESPACE COLLISION — Bootstrap already uses `.lh-` for its line-height
   utilities (`.lh-1`, `.lh-sm`, `.lh-base`, `.lh-lg`, all `!important`).
   No name in this file collides today, but never introduce a class here
   called `.lh-1`, `.lh-sm`, `.lh-base` or `.lh-lg`: Bootstrap's
   `!important` would silently win.

   SPACING RULE — classes here set typography and colour, never margin.
   Not because of load order: Bootstrap's spacing utilities are `!important`
   (`mb-3 { margin-bottom: 1rem !important }`), so a margin here can never
   override them. The real hazard is that a margin here DOES override
   Bootstrap's element defaults — `h1..h6 { margin-bottom: .5rem }`,
   `p { margin-bottom: 1rem }` — for every element that adopts the class,
   so spacing disappears from adopters with no utility in sight to explain
   it. Margin belongs to the page or the utility class.

   Four exceptions, all self-contained rather than page spacing, and all
   overridable from a later layer: `.lh-breadcrumb`'s own placement (the two
   CMS templates do override it to 0), the 3px bar offset inside
   `.lh-h1--display::after`, `.lh-badge`'s inline packing — a span has no
   element default margin, so that one cannot trigger the hazard above — and
   `.lh-band`'s negative -50vw margin, which IS the full-bleed definition
   rather than page spacing (owner-approved 2026-11-18).
   ============================================================ */

/* No custom properties are declared here. Every token in the app lives in
   main.css:root — one home, so `:root` is somewhere you can grep and read in
   full. This sheet consumes --color-text, --color-brand, --color-link,
   --color-link-hover, --line-height-display and the --letter-spacing-* values
   from there. Do not reintroduce a local --color-ink (#111): it was a
   near-duplicate of --color-text that the heading colour drifted away from,
   and the owner removed it on 2026-11-18. */


/* ============================================================
   H1 — page titles

   One base plus three role modifiers. ROLE, not page: a page-named class
   (the previous .lh-home-h1 / .lh-group-series-h1 shape) needs inventing
   for every new page and lets each page drift again.

   Measured 2026-11-17 across 45 files / 47 <h1> elements; the pre-change
   editorial range was 28–56px with weights 500–700, most of it Bootstrap's
   untouched h1 default leaking through.
   ============================================================ */

/* 44px cap. The canonical page title. */
.lh-h1 {
    font-size: clamp(1.75rem, 4vw, 2.75rem);
    font-weight: 700;
    line-height: var(--line-height-display);
    letter-spacing: var(--letter-spacing-display);
    color: var(--color-text);
}

/* 56px cap plus a 2px rule under the title. Group-series landing pages and
   the CMS product page open a section rather than just naming a page, so
   they sit one tier above the base. */
.lh-h1--section {
    font-size: clamp(2.25rem, 4vw, 3.5rem);
    letter-spacing: normal;
    padding-block-end: var(--space-0-5);
}

/* Opt-in 2px rule under a section title. Only the group-series hero had one;
   the CMS product page deliberately did not, so this is a separate modifier
   rather than part of --section. */
.lh-h1--rule {
    border-block-end: 2px solid #000;
}

/* Branded display title: gradient ink plus a 3px bar. Careers, the promotion
   page and the KIN collection index carried three byte-identical copies of
   this recipe before it moved here. */
.lh-h1--display {
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    /* Both spellings are load-bearing: Chrome still only honours the
       -webkit- prefixed clip for text, the unprefixed one is the future. */
    background: linear-gradient(90deg, black 0%, #562563 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    position: relative;
    display: inline-block;
    padding: 0.25rem;
}

.lh-h1--display::after {
    content: "";
    display: block;
    width: 100%;
    height: 3px;
    background: #562563;
    margin-top: 0.25rem;
    border-radius: 2px;
}

/* The product page's h1 is the SKU: 40px cap and tighter leading than the
   base. Weight is 700 now — it previously inherited Bootstrap's 500, which
   was an omission rather than a decision. */
.lh-h1--sku {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.5px;
}


/* ============================================================
   TITLE — every title below the page h1, by role

   ROLE, not element. The 26 title classes in components.css sit on h2, h3,
   h4, p, a and div, but their declared sizes collapse into five tiers:
   48 / 32 / 20 / 16 / 14.4px. Naming the roles after the tag (.lh-h2--card)
   would be wrong on four of those six tags, so the class names the job and
   the tag stays semantic.

   Measured 2026-11-17 across components.css: font-size was declared 168
   times in 60 distinct values, font-weight 89 times in 9 values.
   ============================================================ */

/* 32px. The common job for an h2: names part of a page. */
.lh-title {
    font-size: var(--font-size-3xl);
    font-weight: 700;
    line-height: 1.2;
    color: var(--color-text);
}

/* 48px cap. Opens a page section rather than naming part of it, so it sits
   above the page h1 (44px) by design — owner-confirmed 2026-11-17. Keeps the
   source's clamp rather than a fixed size: the group-series section head is
   the only consumer and it shrinks with the viewport. */
.lh-title--hero {
    font-size: clamp(2rem, 4vw, var(--font-size-5xl));
    line-height: 1;
}

/* 20px. Card, tile and rail titles. */
.lh-title--card {
    font-size: var(--font-size-xl);
    line-height: 1.25;
}

/* 24px small-caps tile label: the industry tiles on /industries and on the
   category page, so the two finally agree. Owner-requested 2026-11-18; the
   home tile was 28px on a clamp and the category tile 16px before this. */
.lh-title--tile {
    font-size: var(--font-size-2xl);
    font-weight: 600;
    letter-spacing: var(--letter-spacing-section);
    text-transform: uppercase;
}

/* 14.4px. Compact rail title carried by a <p> or an <a>, e.g. the
   recent-articles and recent-videos rails. */
.lh-title--meta {
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-medium);
    line-height: var(--line-height-normal);
}

/* Label above a section, not a heading. Home uses this three times. */
.lh-title--eyebrow {
    font-size: var(--font-size-xs);
    font-weight: 400;
    letter-spacing: var(--letter-spacing-eyebrow);
    text-transform: uppercase;
    color: var(--color-text-muted);
}

/* Titles over photography. A colour role with no size of its own, so it
   stacks with any role above. */
.lh-title--on-dark {
    color: #fff;
}


/* ============================================================
   A — breadcrumb link
   ============================================================ */

/* GroupSeries and Series render a byte-identical breadcrumb, so there is no
   .lh-group-series-a or .lh-series-a. The Product page renders none at all,
   so there is no .lh-product-a. This is the element with the strongest
   common definition and the weakest per-page variation. */
.lh-breadcrumb {
    display: flex;
    flex-wrap: wrap;
    margin: var(--space-2) 0 var(--space-1) var(--space-0-5);
    padding: 0;
    list-style: none;
    max-width: 100%;
    overflow-wrap: anywhere;
}

.lh-breadcrumb__item {
    position: relative;
    min-width: 0;
    margin-inline-end: var(--space-1);
    font-size: var(--font-size-xs);
    font-weight: 600;
    line-height: 1.5;
    overflow-wrap: anywhere;
}

/* Slash separator, absolutely placed so it does not affect item width. */
.lh-breadcrumb__item:not(:last-child)::after {
    content: "/";
    position: absolute;
    inset-inline-end: -0.6rem;
    color: currentColor;
}

.lh-a {
    font-size: var(--font-size-xs);
    font-weight: 600;
    line-height: 1.5;
    color: var(--color-text);
    text-decoration: none;
    overflow-wrap: anywhere;
}

/* Was var(--bs-btn-hover-color) — a Bootstrap token leaking into our sheet,
   which resolves blue and contradicts the palette. */
.lh-a:hover,
.lh-a:focus-visible {
    color: var(--color-brand);
    text-decoration: underline;
    text-underline-offset: 0.2em;
    text-decoration-thickness: 1px;
}

/* The current page is a bare <li>, not a link, so the brand colour belongs
   on the item and there is no .lh-a--current. Rendered #54245F today — a
   third purple, hardcoded in Breadcrumb.razor.css. Brand is the point of
   the token. */
.lh-breadcrumb__item--current {
    color: var(--color-brand);
    font-weight: 700;
}


/* ============================================================
   P — body copy
   ============================================================ */

.lh-p {
    font-size: var(--font-size-base);
    font-weight: 400;
    line-height: 1.5;
    color: var(--color-text);
}

/* .series renders <p> with no class in HeroSection.razor, which computes to
   exactly the base values — no page class needed. */


/* ============================================================
   HR — hairline rule
   ============================================================ */

/* Bootstrap renders hr as currentColor at opacity .25. This states the
   hairline as a token instead. `opacity: 1` is load-bearing: without it
   Bootstrap's .25 survives and renders rgba(0,0,0,.12) as rgba(0,0,0,.03),
   which is effectively invisible. The 1rem block margin is Bootstrap's own
   `hr { margin: 1rem 0 }`, so it is left alone. */
.lh-hr {
    height: 0;
    border: 0;
    border-block-start: 1px solid var(--color-border);
    opacity: 1;
}

/* Adopted 2026-11-18 on every reachable bare <hr>: 27 sites across 16 files.
   Bare <hr> rendered black at Bootstrap's opacity .25; the owner chose
   --color-border (12%) over that, so these separators are deliberately about
   half as dark and now agree with the .blog-table cell rules.

   Margin is NOT declared here, deliberately: a bare <hr> keeps Bootstrap's
   1rem block margin, and that is the no-margin layer rule working as designed.

   The product page's 3px centred rule at 93% width is a card ornament, not a
   page divider, so it lives with the card. */


/* ============================================================
   BAND — full-bleed section primitive

   Two live components (/trading-cards) declared this root recipe
   byte-identically: .how-to-use-bullet and .kin-promo. Their grids differ
   (2-column vs 3-column), so only the shell and the 16:9 thumbnail converge;
   columns, gaps and hover states stay with each component.

   This is the FOURTH documented margin exception. The negative -50vw margin
   IS the full-bleed definition, not page spacing, so it cannot fight a
   Bootstrap spacing utility the way ordinary margins would — the same
   reasoning as .lh-breadcrumb's placement.
   ============================================================ */

.lh-band {
    position: relative;
    left: 50%;
    right: 50%;
    /* 100vw INCLUDES the scrollbar width, so a naive full-bleed block sits
       about 15px too wide and produces a horizontal scrollbar. The custom
       property is that fudge factor, zeroed below the sm breakpoint. It is a
       technique value scoped to this element, not a design token, which is
       why it does not live in main.css:root. */
    --scrollbar-compensation: 15px;
    width: calc(100vw - var(--scrollbar-compensation, 0px));
    margin-left: calc(-50vw + var(--scrollbar-compensation, 0px) / 2);
    margin-right: calc(-50vw + var(--scrollbar-compensation, 0px) / 2);
    background-color: var(--color-bg-alt);
    overflow-x: clip;
    padding: 1rem;
}

@media (max-width: 575.98px) {
    .lh-band {
        --scrollbar-compensation: 0px;
    }
}

/* 16:9 video thumbnail inside a band. The border was the literal
   rgba(0,0,0,.12) in both components, which is exactly --color-border. */
.lh-band__thumb {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border: 1px solid var(--color-border);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.35) inset;
}


/* ============================================================
   RAIL — horizontally scrolling card rail

   .recent-articles and .recent-videos declare four of these recipes
   byte-identically: the scroll container, its hidden webkit scrollbar, the
   media image and the empty placeholder. What differs is per-component and
   stays there: the card flex-basis (6-per-row vs 4-per-row), the aspect
   ratio (4/3 vs 16/9), the wrapper background, and the titles' `margin: 0`.

   The title pair was deliberately NOT converged. Its only leftover
   declaration is `margin: 0`, and minting a margin exception in this layer
   for one reset is not worth the hazard the no-margin rule guards against.
   ============================================================ */

.lh-rail {
    display: flex;
    gap: var(--space-1-5);
    overflow-x: auto;
    scrollbar-width: none;
    padding-bottom: var(--space-0-5);
}

.lh-rail::-webkit-scrollbar {
    display: none;
}

.lh-rail__media {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.lh-rail__placeholder {
    width: 100%;
    height: 100%;
    background: var(--color-bg-alt);
}


/* ============================================================
   GALLERY — main image plus thumbnail strip

   .product-card and .detail-gallery agree on two recipes. Their thumbnail
   BASES deliberately do not converge (80x80 object-fit contain vs 100x100
   cover), and neither does the zoom trigger: the card zooms on card hover at
   1.05, the gallery on image hover at 1.1.

   `.thumbnail.selected`'s 2px brand border is also left in components.css:
   the selected state is emitted from a ternary inside the class attribute,
   so converging it would mean editing render logic for a single declaration.
   ============================================================ */

.lh-gallery__main {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease-in-out;
}

.lh-gallery__thumb:hover {
    transform: scale(1.1);
    transition: transform 0.2s ease-in-out;
}


/* ============================================================
   BADGE — inline tag chip
   ============================================================ */

/* Three live components declared this recipe byte-identically under an
   anchored `.tag-badge` (blog cards, featured, home); a fourth copy is inert
   behind the commented-out block at BlogPostsSeries.razor:20-25. One element,
   one job, no per-page variation. Owner-approved 2026-11-18.

   The old name collided three ways: Tags.razor:467 declares its own
   `.tag-badge` inline as a 0.7rem pill inside a chip, and
   VideoCard.razor.css scopes a third design. That is why the fold had to
   anchor every blog copy to a container. A distinct class retires the
   workaround, and those two local designs are left alone.

   `margin` is declared here, which the layer otherwise avoids. The hazard
   that rule guards against — silently overriding Bootstrap's heading and
   paragraph defaults — cannot occur on a <span>, which has no element default
   margin to fight. The 0.4rem is the chip's own inline packing: the tag rows
   are inline flow, not flex with a gap, so nothing else supplies it. */
.lh-badge {
    display: inline-block;
    padding: 0.22rem 0.5rem;
    font-size: var(--font-size-2xs);
    font-weight: var(--font-weight-medium);
    color: #4a5560;
    background: #eef1f5;
    border-radius: var(--radius-sm);
    margin: 0 0.4rem 0.4rem 0;
}
