/* ==========================================================================
   Home (website_v2) — solution-company landing
   Extends design tokens from style.css
   ========================================================================== */

.section-lead {
    text-align: center;
    max-width: 720px;
    margin: -20px auto 40px;
    color: var(--color-text-muted);
    font-size: var(--fs-body);
    line-height: 1.7;
}

.section-title--start {
    text-align: left;
}

.section-title--start::after {
    left: 0;
    transform: none;
}

.section-lead--start {
    text-align: left;
    margin-left: 0;
    margin-right: 0;
    max-width: 720px;
}

.btn-outline {
    background: transparent;
    color: var(--color-primary);
    border: 1.5px solid var(--color-primary);
}

.btn-outline:hover {
    background: var(--color-primary-soft);
    color: var(--color-primary-dark);
    box-shadow: none;
}

.btn-outline-light {
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.9);
    border: 1.5px solid rgba(255, 255, 255, 0.5);
    border-radius: var(--radius-pill);
}

.btn-outline-light:hover {
    background: rgba(255, 255, 255, 0.16);
    color: #fff;
    box-shadow: none;
    transform: translateY(-2px);
}

/* —— Hero (Figma Home — Desktop 1440, taller band + single HubLink) —— */
.home-hero {
    position: relative;
    box-sizing: border-box;
    height: auto;
    min-height: var(--home-banner-height, 520px);
    max-height: none;
    display: flex;
    align-items: center;
    padding: 56px 0;
    margin: 0;
    overflow: hidden;
    /* Solid fallback first: avoids white canvas if gradient/vars fail */
    background-color: #0F172A;
    background-image: linear-gradient(90deg, var(--color-ink, #0F172A) 0%, var(--color-primary, #0891B2) 100%);
    color: #fff;
}

.home-hero__bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 55% 70% at 92% 20%, rgba(34, 211, 238, 0.28), transparent 60%);
    pointer-events: none;
}

.home-hero__inner {
    position: relative;
    z-index: 1;
    max-width: 800px;
}

.home-hero__brand {
    font-size: var(--fs-sm);
    font-weight: 500;
    letter-spacing: 2px;
    margin-bottom: 18px;
    line-height: 1.3;
    color: var(--color-accent, #22D3EE);
    animation: homeFadeUp 0.7s ease both;
}

.home-hero__title {
    font-size: var(--fs-display, 2.5rem);
    font-weight: 700;
    color: #fff;
    margin-bottom: 16px;
    line-height: var(--lh-tight, 1.25);
    letter-spacing: var(--tracking-tight, -0.02em);
    animation: homeFadeUp 0.7s ease 0.08s both;
}

.home-hero__lead {
    font-size: var(--fs-body, 1rem);
    color: rgba(255, 255, 255, 0.85);
    max-width: 680px;
    margin-bottom: 28px;
    line-height: var(--lh-snug, 1.45);
    animation: homeFadeUp 0.7s ease 0.16s both;
}

.home-hero__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    animation: homeFadeUp 0.7s ease 0.22s both;
}

.home-hero__hint {
    margin-top: 22px;
    font-size: var(--fs-sm, 0.9375rem);
    color: rgba(236, 254, 255, 0.75);
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    animation: homeFadeUp 0.7s ease 0.28s both;
}

.home-hero__hint a {
    color: #fff;
    text-decoration: underline;
    text-underline-offset: 3px;
    opacity: 0.9;
}

.home-hero__hint a:hover {
    opacity: 1;
    color: var(--color-accent);
}

.home-hero__actions .btn {
    box-shadow: none;
    border-radius: var(--radius-pill);
    padding: 13px 28px;
}

/* Figma primary CTA: accent fill + ink text */
.home-hero__actions .btn:not(.btn-outline-light):not(.btn-ghost) {
    background: var(--color-accent);
    color: var(--color-ink);
    border-color: transparent;
}

.home-hero__actions .btn:not(.btn-outline-light):not(.btn-ghost):hover {
    background: #67e8f9;
    color: var(--color-ink);
    box-shadow: 0 8px 20px rgba(34, 211, 238, 0.35);
}

@keyframes homeFadeUp {
    from { opacity: 0; transform: translateY(18px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Windows "减少动画" sets animation-duration: 0.01ms — fill-mode:both can leave opacity:0 */
@media (prefers-reduced-motion: reduce) {
    .home-hero__brand,
    .home-hero__title,
    .home-hero__lead,
    .home-hero__actions,
    .home-hero__hint {
        animation: none !important;
        opacity: 1 !important;
        transform: none !important;
    }
}

/* —— Pillars (Figma 我们是谁) —— */
.home-pillars {
    background: var(--color-bg-alt);
    padding: 56px 0;
}

.home-pillars__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.home-pillar {
    padding: 20px 22px;
    border-radius: var(--radius-md);
    border: none;
    border-left: 3px solid rgba(34, 211, 238, 0.4);
    background: var(--color-bg);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    transition: transform var(--ease), box-shadow var(--ease);
}

.home-pillar:hover {
    transform: var(--lift);
    box-shadow: var(--shadow-lg);
}

.home-pillar__num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    margin-bottom: 10px;
    border-radius: 15px;
    background: rgba(21, 165, 192, 0.12);
    font-family: "DM Sans", "Noto Sans SC", sans-serif;
    font-size: var(--fs-label);
    font-weight: 700;
    color: #15A5C0;
    letter-spacing: 1px;
}

.home-pillar h3 {
    font-size: var(--fs-body, 1rem);
    font-weight: 600;
    letter-spacing: var(--tracking-tight, -0.02em);
    color: var(--color-ink, #0F172A);
    margin-bottom: 8px;
}

.home-pillar p {
    font-size: var(--fs-sm, 0.9375rem);
    color: var(--color-text-muted, #64748B);
    line-height: 1.65;
    margin: 0;
}

/* —— Solutions —— */
.home-solutions {
    background: var(--color-bg-alt);
    padding: var(--section-pad) 0;
}

.home-sol {
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    gap: 40px;
    align-items: center;
    margin-bottom: 56px;
}

.home-sol:last-of-type {
    margin-bottom: 24px;
}

.home-sol--reverse .home-sol__media {
    order: 2;
}

.home-sol--reverse .home-sol__body {
    order: 1;
}

.home-sol__media {
    background: #fff;
    overflow: hidden;
    min-height: 260px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--color-border);
}

.home-sol__media picture,
.home-sol__img {
    width: 100%;
    height: 100%;
    max-height: 320px;
    object-fit: cover;
    display: block;
}

.home-sol__media--desk .home-sol__img {
    object-fit: contain;
    background: #fff;
}

.home-sol__code {
    font-size: var(--fs-label);
    font-weight: 700;
    letter-spacing: 0.06em;
    color: var(--color-primary);
    margin-bottom: 8px;
}

.home-sol__body h3 {
    font-size: var(--fs-h2);
    letter-spacing: var(--tracking-tight);
    color: var(--color-ink);
    margin-bottom: 12px;
}

.home-sol__body > p {
    color: var(--color-text-muted);
    margin-bottom: 16px;
    line-height: 1.7;
}

.home-sol__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.home-sol__tags li {
    font-size: var(--fs-label);
    padding: 4px 12px;
    background: rgba(var(--color-primary-rgb), 0.1);
    color: var(--color-primary-dark);
    border-radius: var(--radius-pill);
}

.home-sol__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.home-solutions__more {
    text-align: center;
    margin-top: 8px;
}

.home-solutions__more a {
    color: var(--color-primary);
    font-weight: 500;
}

.home-solutions__more a:hover {
    text-decoration: underline;
}

/* —— Hardware —— */
.home-hardware {
    background: #fff;
    padding: var(--section-pad) 0;
}

.home-hardware__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 28px;
}

.home-hw {
    padding: 28px;
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-left: 3px solid rgba(34, 211, 238, 0.55);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    transition: transform var(--ease), box-shadow var(--ease);
}

.home-hw:hover {
    transform: var(--lift);
    box-shadow: var(--shadow-lg);
}

.home-hw__visual {
    height: 340px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-bg-alt);
    border-radius: var(--radius-sm);
    overflow: hidden;
    padding: 0;
}

.home-hw__visual--icon {
    background: linear-gradient(135deg, #0891b2, #0e7490);
    color: #fff;
    font-size: 3.5rem;
    padding: 0;
}

.home-hw__visual picture {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}

.home-hw__img {
    width: 100%;
    height: 100%;
    max-width: none;
    max-height: none;
    object-fit: cover;
    object-position: center;
}

/* Portrait HubLink: show the whole unit, not a cropped fill */
.home-hw__visual--contain {
    height: 380px;
    padding: 20px;
}

.home-hw__visual--contain picture {
    width: 100%;
    height: 100%;
}

.home-hw__visual--contain .home-hw__img {
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.home-hw h3 {
    font-size: var(--fs-h3);
    letter-spacing: var(--tracking-tight);
    color: var(--color-ink);
    margin-bottom: 6px;
}

.home-hw__sub {
    font-size: var(--fs-xs);
    color: var(--color-primary);
    margin-bottom: 14px;
}

.home-hw ul {
    margin-bottom: 20px;
}

.home-hw li {
    position: relative;
    padding-left: 14px;
    margin-bottom: 8px;
    font-size: var(--fs-sm);
    color: var(--color-text-muted);
}

.home-hw li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.55em;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--color-primary);
}

/* —— Coop —— */
.home-coop {
    background: var(--color-bg-alt);
    padding: var(--section-pad) 0;
}

.home-coop__split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2px;
    overflow: hidden;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    background: rgba(34, 211, 238, 0.35);
}

.home-coop__side {
    padding: 36px 32px;
    color: #fff;
}

.home-coop__side--partner {
    background:
        radial-gradient(ellipse 80% 70% at 0% 0%, rgba(34, 211, 238, 0.18), transparent 55%),
        linear-gradient(145deg, var(--color-ink, #0F172A) 0%, #155E75 100%);
}

.home-coop__side--grid {
    background:
        radial-gradient(ellipse 70% 60% at 100% 0%, rgba(236, 254, 255, 0.22), transparent 50%),
        linear-gradient(145deg, var(--color-primary, #0891B2) 0%, var(--color-primary-dark, #067089) 100%);
}

.home-coop__side h3 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: #fff;
    letter-spacing: var(--tracking-tight, -0.02em);
}

.home-coop__side--grid h3 {
    color: #ECFEFF;
}

.home-coop__side li {
    position: relative;
    padding-left: 18px;
    margin-bottom: 12px;
    font-size: var(--fs-sm);
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.92);
}

.home-coop__side li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.55em;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--color-accent, #22D3EE);
}

/* —— Stack —— */
.home-stack {
    background: #fff;
    padding: var(--section-pad) 0;
}

.home-stack__flow {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    list-style: none;
    counter-reset: stack;
    margin-bottom: 32px;
}

.home-stack__flow li {
    counter-increment: stack;
    padding: 24px 18px;
    background: linear-gradient(180deg, #f0f9ff 0%, #fff 100%);
    border: 1px solid var(--color-border);
    border-bottom: 3px solid var(--color-accent);
    border-radius: var(--radius-md);
    text-align: center;
    box-shadow: var(--shadow-sm);
}

.home-stack__flow li::before {
    content: counter(stack, decimal-leading-zero);
    display: block;
    font-family: "DM Sans", "Noto Sans SC", sans-serif;
    font-size: var(--fs-label);
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 10px;
    letter-spacing: 0.06em;
}

.home-stack__flow strong {
    display: block;
    font-size: var(--fs-sm);
    color: var(--color-ink);
    margin-bottom: 6px;
}

.home-stack__flow span {
    font-size: var(--fs-label);
    color: var(--color-text-muted);
}

.home-stack__actions {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
}

/* —— Partners —— */
.home-partners {
    background: var(--color-bg-alt);
    padding: var(--section-pad) 0;
}

.home-partners__grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.home-partner {
    background: #fff;
    padding: 24px 16px;
    text-align: center;
    border-radius: var(--radius-md);
    border: 1px solid var(--color-border);
    box-shadow: var(--shadow-md);
    transition: transform var(--ease), box-shadow var(--ease);
}

.home-partner:hover {
    transform: var(--lift);
    box-shadow: var(--shadow-lg);
}

.home-partner strong {
    display: block;
    font-size: 1.05rem;
    color: var(--color-ink);
    margin-bottom: 8px;
}

.home-partner span {
    font-size: 12px;
    color: var(--color-text-muted);
}

/* —— Products secondary CTA —— */
.home-products-link {
    background: #fff;
    padding: 48px 0;
    border-top: 1px solid var(--color-border);
}

.home-products-link__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
}

.home-products-link h2 {
    font-size: 1.35rem;
    color: var(--color-ink);
    margin-bottom: 8px;
}

.home-products-link p {
    color: var(--color-text-muted);
    margin: 0;
    max-width: 36em;
}

.home-products-link__actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* —— Responsive —— */
@media (max-width: 960px) {
    .home-pillars__grid,
    .home-hardware__grid,
    .home-coop__split,
    .home-stack__flow,
    .home-partners__grid {
        grid-template-columns: 1fr 1fr;
    }

    .home-sol,
    .home-sol--reverse {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .home-sol--reverse .home-sol__media,
    .home-sol--reverse .home-sol__body {
        order: unset;
    }
}

@media (max-width: 640px) {
    .home-hero {
        height: auto;
        min-height: var(--home-banner-height-sm, 380px);
        max-height: none;
        padding: 36px 0;
    }

    .home-pillars__grid,
    .home-hardware__grid,
    .home-coop__split,
    .home-stack__flow,
    .home-partners__grid {
        grid-template-columns: 1fr;
    }

    .home-hero__actions {
        flex-direction: column;
        align-items: stretch;
    }

    .home-hero__actions .btn {
        text-align: center;
    }
}

/* Home — taller band; keep 3-shot collage */
section.product-banner.product-banner--home {
    height: auto;
    min-height: var(--home-banner-height, 520px);
    max-height: none;
    padding: 56px 0;
}

section.product-banner.product-banner--home h1 {
    font-size: var(--fs-display);
}

section.product-banner.product-banner--home .product-banner__hint {
    padding-top: 16px;
}

@media (max-width: 960px) {
    section.product-banner.product-banner--home {
        min-height: var(--home-banner-height-md, 440px);
        padding: 40px 0;
    }
}

@media (max-width: 640px) {
    section.product-banner.product-banner--home {
        min-height: var(--home-banner-height-sm, 380px);
        padding: 36px 0;
    }
}
