﻿/*
 * Hero Section — Full-Screen Industrial
 * Loaded after navigation.css. All rules scoped to .hero-section.
 */

/* ═══════════════════════════════════════════════════════════════
   KEYFRAMES
   ═══════════════════════════════════════════════════════════════ */

@keyframes heroFadeUp {
    from { opacity: 0; transform: translateY(32px); }
    to   { opacity: 1; transform: translateY(0);    }
}

@keyframes heroFadeRight {
    from { opacity: 0; transform: translateX(-24px); }
    to   { opacity: 1; transform: translateX(0);     }
}

@keyframes heroScaleIn {
    from { opacity: 0; transform: scale(0.92); }
    to   { opacity: 1; transform: scale(1);    }
}

@keyframes heroCardSlide {
    from { opacity: 0; transform: translateX(40px); }
    to   { opacity: 1; transform: translateX(0);    }
}

@keyframes heroPulse {
    0%, 100% { opacity: 1;   transform: scale(1);    }
    50%       { opacity: 0.6; transform: scale(0.85); }
}

@keyframes heroScrollLine {
    0%   { transform: scaleY(0); transform-origin: top; }
    50%  { transform: scaleY(1); transform-origin: top; }
    51%  { transform: scaleY(1); transform-origin: bottom; }
    100% { transform: scaleY(0); transform-origin: bottom; }
}

@keyframes heroRuleGrow {
    from { transform: scaleY(0); }
    to   { transform: scaleY(1); }
}

@keyframes isoConicRotate {
    100% { transform: rotate(1turn); }
}

@keyframes heroStatBorderSpin {
    100% { transform: rotate(1turn); }
}

@keyframes heroCornerGrow {
    from { width: 0; height: 0; }
    to   { width: 48px; height: 48px; }
}

@keyframes heroWatermark {
    from { opacity: 0; transform: translateX(40px); }
    to   { opacity: 1; transform: translateX(0); }
}

/* ═══════════════════════════════════════════════════════════════
   SECTION SHELL
   ═══════════════════════════════════════════════════════════════ */

.hero-section {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background-color: #f8fafc;
}

/* ── Background layers ───────────────────────────────────────── */

.hero-bg-image {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center 30%;
    background-repeat: no-repeat;
    transform: scale(1.03);
    transition: transform 8s ease;
}

.hero-section:hover .hero-bg-image {
    transform: scale(1);
}

.hero-bg-placeholder {
    background-image:
        linear-gradient(135deg, #f0f4f8 0%, #e8f0f8 40%, #f8fafc 70%, #f0f4f8 100%);
}

/* Background slideshow — cross-fades between slides every 6s (see main.js) */
.hero-slideshow {
    position: absolute;
    inset: 0;
}

.hero-slide {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center 30%;
    background-repeat: no-repeat;
    opacity: 0;
    transition: opacity 1.2s ease;
}

.hero-slide.is-active {
    opacity: 1;
}

/* Flat white wash — keeps slideshow images subtle, text readable */
.hero-overlay {
    position: absolute;
    inset: 0;
    background: rgba(248,250,252,0.78);
}

.hero-glow {
    position: absolute;
    bottom: -10%;
    left: -5%;
    width: 60%;
    height: 70%;
    background: radial-gradient(
        ellipse at 30% 80%,
        rgba(249,115,22,0.08) 0%,
        rgba(249,115,22,0.03) 35%,
        transparent 70%
    );
    pointer-events: none;
}

/* ── Decorative geometry ─────────────────────────────────────── */

/* Left vertical orange rule */
.hero-rule-left {
    position: absolute;
    top: 0;
    left: 0;
    width: 3px;
    height: 100%;
    background: linear-gradient(
        to bottom,
        transparent 0%,
        #f97316 15%,
        #f97316 85%,
        transparent 100%
    );
    transform-origin: top;
    animation: heroRuleGrow 1.2s cubic-bezier(0.4,0,0.2,1) 0.3s both;
}

/* Top-right corner bracket */
.hero-corner-tr {
    position: absolute;
    top: 2rem;
    right: 2rem;
    width: 48px;
    height: 48px;
    opacity: 0;
    animation: heroFadeUp 0.6s ease 1.4s both;
}
.hero-corner-tr .hero-corner-h {
    position: absolute;
    top: 0; right: 0;
    width: 100%;
    height: 2px;
    background: rgba(249,115,22,0.4);
}
.hero-corner-tr .hero-corner-v {
    position: absolute;
    top: 0; right: 0;
    width: 2px;
    height: 100%;
    background: rgba(249,115,22,0.4);
}

/* Bottom-left corner bracket */
.hero-corner-bl {
    position: absolute;
    bottom: 80px;
    left: 2rem;
    width: 40px;
    height: 40px;
    opacity: 0;
    animation: heroFadeUp 0.6s ease 1.5s both;
}
.hero-corner-bl .hero-corner-h {
    position: absolute;
    bottom: 0; left: 0;
    width: 100%;
    height: 2px;
    background: rgba(249,115,22,0.3);
}
.hero-corner-bl .hero-corner-v {
    position: absolute;
    bottom: 0; left: 0;
    width: 2px;
    height: 100%;
    background: rgba(249,115,22,0.3);
}

/* Watermark large number */
.hero-watermark {
    position: absolute;
    right: -0.5rem;
    top: 50%;
    transform: translateY(-50%);
    font-family: var(--font-heading, 'Barlow Condensed', sans-serif);
    font-size: clamp(8rem, 18vw, 20rem);
    font-weight: 900;
    line-height: 1;
    color: rgba(15,23,42,0.04);
    user-select: none;
    pointer-events: none;
    letter-spacing: -0.05em;
    opacity: 0;
    animation: heroWatermark 1.5s ease 0.8s both;
}

/* Bottom diagonal cut */
.hero-diagonal-cut {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 80px;
    background: inherit;
    clip-path: polygon(0 100%, 100% 0, 100% 100%);
    background-color: rgba(249,115,22,0.025);
    pointer-events: none;
}

/* ═══════════════════════════════════════════════════════════════
   CONTENT WRAPPER
   ═══════════════════════════════════════════════════════════════ */

.hero-content-wrap {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding-top: calc(var(--header-h, 72px) + var(--topbar-h, 0px) + 4rem);
    padding-bottom: calc(80px + 3rem);
}

@media (min-width: 1024px) {
    .hero-content-wrap {
        padding-top: calc(var(--header-h, 72px) + var(--topbar-h, 0px) + 5rem);
        padding-bottom: calc(80px + 4rem);
    }
}

/* ── Main content column ─────────────────────────────────────── */

.hero-content {
    max-width: 860px;
    width: 100%;
    text-align: center;
    margin: 0 auto;
}

/* ── Badge pill ──────────────────────────────────────────────── */

.hero-badge-wrap {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #f97316;
    border: 1px solid rgba(249,115,22,0.3);
    background: rgba(249,115,22,0.08);
    padding: 0.4375rem 0.875rem;
    margin-bottom: 1.25rem;
}

.hero-badge-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #f97316;
    display: block;
    animation: heroPulse 2s ease infinite;
}

/* ── Eyebrow ─────────────────────────────────────────────────── */

.hero-eyebrow {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: #0f172a;
    margin-bottom: 0.875rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
}

.hero-eyebrow::before,
.hero-eyebrow::after {
    content: '';
    display: block;
    width: 2rem;
    height: 2px;
    background: #f97316;
    flex-shrink: 0;
}

/* ── Headline ────────────────────────────────────────────────── */

.hero-heading {
    font-family: var(--font-heading, 'Barlow Condensed', sans-serif);
    font-weight: 900;
    text-transform: uppercase;
    line-height: 0.92;
    letter-spacing: -0.02em;
    margin-bottom: 1.5rem;
}

.hero-heading-line1 {
    display: block;
    color: #0f172a;
    font-size: clamp(2.75rem, 6.5vw, 5.5rem);
}

.hero-heading-line2 {
    display: block;
    font-size: clamp(2.75rem, 6.5vw, 5.5rem);
    -webkit-text-stroke: 2px #f97316;
    color: transparent;
    background: linear-gradient(135deg, #f97316 0%, #fb923c 50%, #f97316 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    -webkit-text-stroke: 0;
}

/* ── Subtitle ────────────────────────────────────────────────── */

.hero-subtitle {
    font-size: clamp(0.9375rem, 1.5vw, 1.0625rem);
    color: #0f172a;
    line-height: 1.75;
    max-width: 640px;
    margin: 0 auto 2.25rem;
}

/* ── CTA row ─────────────────────────────────────────────────── */

.hero-ctas {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

.hero-cta-primary {
    position: relative;
    overflow: hidden;
    z-index: 0;
}

.hero-cta-primary::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #ea580c, #f97316, #fb923c);
    z-index: -1;
    transition: opacity 300ms ease;
}

.hero-cta-primary:hover::before {
    opacity: 0.85;
}

/* Dark navy secondary CTA (overrides btn-primary orange) */
.hero-cta-dark,
.hero-cta-dark:hover {
    background: #0f172a;
    border-color: #0f172a;
    color: #ffffff;
}
.hero-cta-dark:hover {
    background: #1e293b;
    border-color: #1e293b;
}

/* Ghost button with play icon */
.hero-cta-ghost {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0;
    font-size: 0.8125rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #0f172a;
    text-decoration: none;
    transition: color 200ms ease;
    background: none;
    border: none;
    cursor: pointer;
}

.hero-cta-ghost:hover {
    color: var(--color-sky, #0ea5e9);
}

.hero-cta-play {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1.5px solid rgba(15,23,42,0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #0f172a;
    padding-left: 2px;
    transition: border-color 200ms ease, background 200ms ease, color 200ms ease;
}

.hero-cta-ghost:hover .hero-cta-play {
    border-color: var(--color-sky, #0ea5e9);
    background: rgba(14,165,233,0.12);
    color: var(--color-sky, #0ea5e9);
}

/* ── Trust row ───────────────────────────────────────────────── */

.hero-trust {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.5rem 0.75rem;
    font-size: 0.75rem;
    color: #0f172a;
}

.hero-trust-label {
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #0f172a;
    margin-right: 0.25rem;
}

.hero-trust-item {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    color: #0f172a;
}

.hero-trust-item svg {
    color: var(--color-sky, #0ea5e9);
    flex-shrink: 0;
    opacity: 0.9;
}

.hero-trust-dot {
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: rgba(255,255,255,0.2);
    display: block;
}

/* ═══════════════════════════════════════════════════════════════
   FLOATING CARDS (desktop right column)
   ═══════════════════════════════════════════════════════════════ */

.hero-cards {
    display: none;
    flex-direction: column;
    gap: 0.875rem;
    align-items: flex-end;
}

@media (min-width: 1024px) {
    .hero-cards {
        display: flex;
    }
}

.hero-card {
    background: rgba(255,255,255,0.9);
    border: 1px solid rgba(15,23,42,0.1);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    padding: 1rem 1.25rem;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
    transition: border-color 300ms ease, transform 300ms ease;
}

.hero-card:hover {
    border-color: rgba(249,115,22,0.35);
    transform: translateX(-4px);
}

/* ISO card — static border on octagon shape, 25% smaller */
.hero-card.hero-card-iso {
    background: transparent;
    border: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    box-shadow: none;
    padding: 5px;
    position: relative;
    z-index: 0;
    overflow: hidden;
    display: block;
    width: 75%;
    /* Octagon clip — crops the entire card (and its pseudo-elements) to the badge shape */
    clip-path: polygon(29% 0%, 71% 0%, 100% 29%, 100% 71%, 71% 100%, 29% 100%, 0% 71%, 0% 29%);
}

.hero-card.hero-card-iso::before {
    display: none;
}

/* No ::after — the image itself covers the inner gradient; only the 5px ring shows */

.hero-card.hero-card-iso:hover {
    border-color: transparent;
    transform: none;
}

.hero-card-icon {
    width: 44px;
    height: 44px;
    background: rgba(249,115,22,0.12);
    border: 1px solid rgba(249,115,22,0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #f97316;
}

.hero-card-label {
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #0f172a;
    margin-bottom: 0.25rem;
}

.hero-card-value {
    font-family: var(--font-heading, 'Barlow Condensed', sans-serif);
    font-size: 1.0625rem;
    font-weight: 900;
    text-transform: uppercase;
    color: #0f172a;
    letter-spacing: 0.04em;
}

/* Experience card */
.hero-card-exp {
    text-align: right;
    min-width: 160px;
}

.hero-card-big {
    font-family: var(--font-heading, 'Barlow Condensed', sans-serif);
    font-size: 3rem;
    font-weight: 900;
    line-height: 1;
    color: #f97316;
    letter-spacing: -0.03em;
}

.hero-card-big span {
    font-size: 1.75rem;
    color: rgba(249,115,22,0.6);
}

/* Live indicator card */
.hero-card-live {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #0f172a;
    min-width: 200px;
    border-left: 2px solid rgba(34,197,94,0.5);
    padding-left: 0.875rem;
    background: rgba(34,197,94,0.06);
}

.hero-live-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #22c55e;
    flex-shrink: 0;
    animation: heroPulse 1.8s ease infinite;
    box-shadow: 0 0 8px rgba(34,197,94,0.5);
}

/* ═══════════════════════════════════════════════════════════════
   STAT BAR
   ═══════════════════════════════════════════════════════════════ */

.hero-stat-bar {
    position: relative;
    z-index: 2;
    background: #ffffff;
    box-shadow: 0 -4px 20px rgba(0,0,0,0.06);
    overflow: hidden;
}

/* Spinning conic-gradient border — same technique as services-promo-strip */
.hero-stat-bar::before {
    content: '';
    position: absolute;
    inset: -2px;
    background: conic-gradient(
        from 0deg,
        transparent  0deg,
        rgba(249,115,22,0.9)  60deg,
        rgba(14,165,233,0.7) 120deg,
        transparent 180deg
    );
    animation: heroStatBorderSpin 6s linear infinite;
    z-index: 0;
}

/* Inner white fill — keeps the bar's background solid */
.hero-stat-bar::after {
    content: '';
    position: absolute;
    inset: 2px;
    background: #ffffff;
    z-index: 1;
}

.hero-stat-inner {
    display: flex;
    align-items: center;
    gap: 0;
    min-height: 80px;
    flex-wrap: wrap;
    position: relative;
    z-index: 2; /* above the ::after fill */
}

.hero-stat {
    flex: 1;
    min-width: 120px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1.125rem 1rem;
    text-align: center;
}

.hero-stat-divider {
    width: 1px;
    height: 36px;
    background: rgba(15,23,42,0.12);
    flex-shrink: 0;
}

.hero-stat-number {
    display: block;
    font-family: var(--font-heading, 'Barlow Condensed', sans-serif);
    font-size: clamp(1.375rem, 2.5vw, 1.875rem);
    font-weight: 900;
    color: #f97316;
    line-height: 1;
    letter-spacing: -0.02em;
    margin-bottom: 0.25rem;
}

.hero-stat-label {
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #0f172a;
}

/* Scroll cue inside stat bar */
.hero-scroll-cue {
    display: none;
    flex-direction: column;
    align-items: center;
    gap: 0.375rem;
    padding: 1rem 1.5rem;
    font-size: 0.625rem;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #0f172a;
    border-left: 1px solid rgba(15,23,42,0.1);
}

@media (min-width: 1024px) {
    .hero-scroll-cue { display: flex; }
}

.hero-scroll-line {
    width: 1px;
    height: 28px;
    background: linear-gradient(to bottom, #f97316, transparent);
    animation: heroScrollLine 1.8s ease infinite;
}

/* ═══════════════════════════════════════════════════════════════
   ENTRANCE ANIMATIONS
   ═══════════════════════════════════════════════════════════════ */

.hero-anim {
    opacity: 0;
    animation-fill-mode: both;
    animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
    animation-duration: 0.75s;
    animation-name: heroFadeUp;
}

.hero-anim-1  { animation-delay: 0.15s; }
.hero-anim-2  { animation-delay: 0.25s; }
.hero-anim-3  { animation-delay: 0.38s; }
.hero-anim-4  { animation-delay: 0.52s; }
.hero-anim-5  { animation-delay: 0.64s; }
.hero-anim-6  { animation-delay: 0.74s; }
.hero-anim-7  { animation-delay: 0.55s; animation-name: heroCardSlide; }
.hero-anim-8  { animation-delay: 0.70s; animation-name: heroCardSlide; }
.hero-anim-9  { animation-delay: 0.82s; animation-name: heroCardSlide; }

@media (prefers-reduced-motion: reduce) {
    .hero-stat-bar::before { animation: none; }
    .hero-stat-bar { border-top: 1px solid rgba(15,23,42,0.08); }

    .hero-anim {
        animation: none;
        opacity: 1;
    }
    .hero-rule-left,
    .hero-corner-tr,
    .hero-corner-bl,
    .hero-watermark,
    .hero-badge-dot,
    .hero-live-dot,
    .hero-scroll-line {
        animation: none;
        opacity: 1;
        transform: none;
    }
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE ADJUSTMENTS
   ═══════════════════════════════════════════════════════════════ */

@media (max-width: 639px) {
    .hero-content-wrap {
        padding-top: calc(var(--header-h, 72px) + var(--topbar-h, 0px) + 2.5rem);
        padding-bottom: calc(80px + 2rem);
    }

    .hero-ctas {
        flex-direction: column;
        align-items: flex-start;
    }

    .hero-cta-ghost {
        margin-left: 0;
    }

    .hero-stat-inner {
        gap: 0;
    }

    .hero-stat {
        min-width: 100px;
    }
}

@media (min-width: 640px) and (max-width: 1023px) {
    .hero-content-wrap {
        padding-top: calc(var(--header-h, 72px) + var(--topbar-h, 0px) + 3.5rem);
    }
}
