/**
 * Inner page hero — product categories and single product pages.
 *
 * Visual language is the storefront's existing industrial layer (graphite
 * photo, Poppins display type, single action red, 5px card radius) so the two
 * conversion entry points no longer fall back to a bare white page.
 *
 * Component-scoped tokens live in the :root block below; brand colour and
 * radius are consumed from the industrial B2B token set
 * (--fcdc-b2b-red / --fcdc-b2b-red-dark / --fcdc-b2b-radius).
 *
 * Contrast (measured on the prototype, plate sampling per text node):
 * eyebrow 6.18–7.15, H1 4.98–15.78, lead 9.83–11.38, badge 12.59–14.01,
 * ghost CTA 11.24–12.89, primary CTA on #d62b27 = 4.96 — all above
 * 4.5:1 (3:1 for the large H1).
 *
 * @package Weline_Motor
 * @version 1.0.0
 */

:root {
    --weline-hero-ink: #0c1219;
    --weline-hero-kicker: #ff8f84;
    --weline-hero-text: #ffffff;
    --weline-hero-text-soft: rgba(255, 255, 255, 0.88);
    --weline-hero-badge-bg: rgba(12, 18, 25, 0.78);
    --weline-hero-badge-border: rgba(255, 255, 255, 0.28);
    --weline-hero-ghost-bg: rgba(255, 255, 255, 0.06);
    --weline-hero-ghost-border: rgba(255, 255, 255, 0.55);
    --weline-hero-category-h: 340px;
    --weline-hero-product-h: 300px;
    --weline-hero-mobile-h: 220px;
    --weline-hero-radius: var(--fcdc-b2b-radius, 5px);
    /* CTA 用控件圆角（3px），和全站按钮一致；hero 容器本身仍按卡片圆角 5px */
    --weline-hero-cta-radius: var(--fcdc-b2b-radius-btn, 3px);
    --weline-hero-content-w: 1320px;
    --weline-hero-scrim:
        linear-gradient(90deg, rgba(12, 18, 25, 0.9) 0%, rgba(12, 18, 25, 0.86) 46%, rgba(12, 18, 25, 0.55) 72%, rgba(12, 18, 25, 0.12) 100%),
        linear-gradient(0deg, rgba(12, 18, 25, 0.45) 0%, rgba(12, 18, 25, 0) 42%);
    --weline-hero-scrim-mobile:
        linear-gradient(90deg, rgba(12, 18, 25, 0.94) 0%, rgba(12, 18, 25, 0.9) 60%, rgba(12, 18, 25, 0.82) 100%),
        linear-gradient(0deg, rgba(12, 18, 25, 0.5) 0%, rgba(12, 18, 25, 0) 50%);
}

.weline-inner-hero {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    display: block;
    margin: 0 0 28px;
    border-radius: var(--weline-hero-radius);
    background-color: var(--weline-hero-ink);
    color: var(--weline-hero-text);
}

.weline-inner-hero--category {
    min-height: var(--weline-hero-category-h);
}

.weline-inner-hero--product {
    min-height: var(--weline-hero-product-h);
}

.weline-inner-hero__media {
    position: absolute;
    inset: 0;
    z-index: -2;
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
    object-position: center 42%;
}

.weline-inner-hero--product .weline-inner-hero__media {
    filter: blur(8px) saturate(1.02);
    transform: scale(1.06);
}

.weline-inner-hero__scrim {
    position: absolute;
    inset: 0;
    z-index: -1;
    display: block;
    background: var(--weline-hero-scrim);
}

.weline-inner-hero__inner {
    width: min(100% - 64px, var(--weline-hero-content-w));
    margin: 0 auto;
    padding: 40px 0 36px;
    min-height: inherit;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 12px;
    box-sizing: border-box;
}

.weline-inner-hero__eyebrow {
    margin: 0;
    font-family: Inter, Arial, sans-serif;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.5;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--weline-hero-kicker);
}

.weline-inner-hero__title {
    margin: 0;
    max-width: 900px;
    font-family: Poppins, Inter, sans-serif;
    font-weight: 600;
    letter-spacing: -0.01em;
    color: var(--weline-hero-text);
}

.weline-inner-hero--category .weline-inner-hero__title {
    font-size: 44px;
    line-height: 1.12;
}

.weline-inner-hero--product .weline-inner-hero__title {
    font-size: 40px;
    line-height: 1.14;
}

.weline-inner-hero__lead {
    margin: 0;
    max-width: 620px;
    font-family: Inter, Arial, sans-serif;
    font-size: 15px;
    line-height: 1.6;
    color: var(--weline-hero-text-soft);
}

.weline-inner-hero__actions {
    margin-top: 8px;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.weline-inner-hero__cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 48px;
    padding: 0 24px;
    border: 1px solid var(--fcdc-b2b-red, #d62b27);
    border-radius: var(--weline-hero-cta-radius, 3px);
    background: var(--fcdc-b2b-red, #d62b27);
    color: var(--weline-hero-text);
    font-family: Inter, Arial, sans-serif;
    font-size: 15px;
    font-weight: 600;
    line-height: 1;
    text-decoration: none;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.weline-inner-hero__cta:hover,
.weline-inner-hero__cta:focus {
    background: var(--fcdc-b2b-red-dark, #ad1f1c);
    border-color: var(--fcdc-b2b-red-dark, #ad1f1c);
    color: var(--weline-hero-text);
    text-decoration: none;
}

.weline-inner-hero__cta--ghost {
    background: var(--weline-hero-ghost-bg);
    border-color: var(--weline-hero-ghost-border);
}

.weline-inner-hero__cta--ghost:hover,
.weline-inner-hero__cta--ghost:focus {
    background: rgba(255, 255, 255, 0.16);
    border-color: rgba(255, 255, 255, 0.8);
}

.weline-inner-hero__badge {
    position: absolute;
    right: 24px;
    bottom: 20px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border: 1px solid var(--weline-hero-badge-border);
    border-radius: 999px;
    background: var(--weline-hero-badge-bg);
    color: rgba(255, 255, 255, 0.92);
    font-family: Inter, Arial, sans-serif;
    font-size: 12px;
    line-height: 1.2;
    text-decoration: none;
}

.weline-inner-hero__badge:hover,
.weline-inner-hero__badge:focus {
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.5);
    text-decoration: none;
}

.weline-inner-hero__badge svg {
    flex: none;
}

/* Keyboard focus stays visible on the dark surface. */
.weline-inner-hero__cta:focus-visible,
.weline-inner-hero__badge:focus-visible {
    outline: 3px solid var(--fcdc-b2b-focus, #ffb4ae);
    outline-offset: 3px;
}

@media (max-width: 860px) {
    .weline-inner-hero {
        margin-bottom: 20px;
    }

    .weline-inner-hero--category,
    .weline-inner-hero--product {
        min-height: var(--weline-hero-mobile-h);
    }

    .weline-inner-hero__scrim {
        background: var(--weline-hero-scrim-mobile);
    }

    .weline-inner-hero__inner {
        width: min(100% - 32px, var(--weline-hero-content-w));
        padding: 16px 0 14px;
        gap: 6px;
    }

    .weline-inner-hero--category .weline-inner-hero__title,
    .weline-inner-hero--product .weline-inner-hero__title {
        font-size: 26px;
        line-height: 1.18;
    }

    .weline-inner-hero__lead {
        max-width: 100%;
        font-size: 14px;
    }

    .weline-inner-hero__actions {
        margin-top: 4px;
    }

    .weline-inner-hero__cta {
        height: 44px;
        padding: 0 16px;
        font-size: 14px;
    }

    .weline-inner-hero__cta--ghost,
    .weline-inner-hero__badge {
        display: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .weline-inner-hero__cta {
        transition: none;
    }
}
