/* =========================================================================
   Shared marketing hero — base + three flag-selectable variants.
   Variant is chosen by the `landing_hero_variant` feature flag and applied
   as a modifier class (`hero--centered` | `hero--editorial` | `hero--left`)
   on `.hero-section`. Each page supplies its own photo via the `--hero-image`
   custom property set in that page's scoped .razor.css.
   ========================================================================= */

/* ---- Base structure (shared by all variants) ---- */
.hero-section {
    position: relative;
    min-height: 100vh;
    background: var(--hero-image) center / cover no-repeat;
    display: flex;
    padding: 0 1.5rem;
}

.hero-overlay {
    position: absolute;
    inset: 0;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 1100px;
    margin: 0 auto;
    width: 100%;
    display: flex;
}

.hero-card {
    background: transparent;
    border-radius: 0;
    padding: 0;
    max-width: 760px;
    width: 100%;
    box-shadow: none;
    display: flex;
    flex-direction: column;
}

.hero-title {
    font-family: var(--font-display);
    font-weight: 600;
    color: var(--text-inverse);
    margin-bottom: 1.25rem;
    line-height: 1.05;
    letter-spacing: -0.02em;
    font-optical-sizing: auto;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.55);
}

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.2rem);
    color: var(--text-on-dark);
    line-height: 1.6;
    margin-bottom: 2rem;
    max-width: 580px;
    text-shadow: 0 1px 8px rgba(0, 0, 0, 0.45);
}

.hero-benefits {
    display: flex;
    gap: 1.25rem;
    flex-wrap: wrap;
    margin-bottom: 2rem;
    padding: 1.25rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    width: 100%;
}

.benefit-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-inverse);
    font-weight: 600;
}

.benefit-item i {
    font-size: 1.25rem;
    color: var(--text-inverse);
    flex-shrink: 0;
    opacity: 0.9;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Buttons — both naming sets (Home uses .btn-hero-*, sub-pages use .btn-*).
   The bottom-CTA band reuses the same dark-on-light treatment as the hero. */
.btn-hero-primary,
.btn-hero-secondary,
.hero-actions .btn-primary,
.hero-actions .btn-secondary,
.bottom-cta-actions .btn-primary,
.bottom-cta-actions .btn-secondary {
    padding: 0.9rem 2rem;
    border-radius: 12px;
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    line-height: 1.5;
    white-space: nowrap;
    min-width: 180px;
}

.btn-hero-primary,
.hero-actions .btn-primary,
.bottom-cta-actions .btn-primary {
    background: var(--surface-raised);
    color: var(--text-primary);
    border: 1.5px solid var(--surface-raised);
}

.btn-hero-primary:hover,
.hero-actions .btn-primary:hover,
.bottom-cta-actions .btn-primary:hover {
    background: var(--background-light);
    color: var(--text-primary);
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}

.btn-hero-secondary,
.hero-actions .btn-secondary,
.bottom-cta-actions .btn-secondary {
    background: transparent;
    color: var(--text-inverse);
    border: 1.5px solid rgba(255, 255, 255, 0.85);
}

.btn-hero-secondary:hover,
.hero-actions .btn-secondary:hover,
.bottom-cta-actions .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.12);
    color: var(--text-inverse);
    transform: translateY(-1px);
    border-color: var(--text-inverse);
}

/* Photo caption — rendered only by the editorial variant */
.hero-caption {
    position: absolute;
    z-index: 2;
    display: none;
    flex-direction: column;
    color: var(--text-inverse);
    text-shadow: 0 1px 8px rgba(0, 0, 0, 0.6);
}

.hero-caption-name {
    font-weight: 600;
    font-size: 0.95rem;
}

.hero-caption-location {
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.7rem;
    opacity: 0.85;
}

/* =========================================================================
   Variant: centered (default) — refined version of the original hero.
   ========================================================================= */
.hero-section.hero--centered {
    align-items: center;
    justify-content: center;
}

.hero--centered .hero-content {
    justify-content: center;
}

.hero--centered .hero-card {
    align-items: center;
    text-align: center;
}

.hero--centered .hero-title {
    font-size: clamp(2.5rem, 6.5vw, 4.5rem);
}

.hero--centered .hero-benefits {
    justify-content: center;
}

.hero--centered .hero-actions {
    justify-content: center;
}

/* Light top band keeps the floating logo/nav legible; a soft center vignette
   lifts the headline off the photo. */
.hero--centered .hero-overlay {
    background:
        linear-gradient(to bottom, rgba(0, 0, 0, 0.5) 0%, rgba(0, 0, 0, 0) 45%),
        radial-gradient(ellipse at center, rgba(0, 0, 0, 0.32) 0%, rgba(0, 0, 0, 0) 72%);
}

/* =========================================================================
   Variant: editorial — content anchored lower-left, caption lower-right.
   ========================================================================= */
.hero-section.hero--editorial {
    align-items: flex-end;
    justify-content: flex-start;
    padding-bottom: 4rem;
}

.hero--editorial .hero-content {
    justify-content: flex-start;
}

.hero--editorial .hero-card {
    align-items: flex-start;
    text-align: left;
    max-width: 860px;
}

.hero--editorial .hero-title {
    font-size: clamp(2.75rem, 7vw, 5rem);
    font-weight: 700;
}

.hero--editorial .hero-benefits {
    justify-content: flex-start;
}

.hero--editorial .hero-actions {
    justify-content: flex-start;
}

/* Top band for nav legibility + strong bottom-up scrim under the anchored copy. */
.hero--editorial .hero-overlay {
    background:
        linear-gradient(to bottom, rgba(0, 0, 0, 0.45) 0%, rgba(0, 0, 0, 0) 120px),
        linear-gradient(to top, rgba(0, 0, 0, 0.78) 0%, rgba(0, 0, 0, 0.32) 32%, rgba(0, 0, 0, 0) 62%);
}

.hero--editorial .hero-caption {
    display: flex;
    right: 1.5rem;
    bottom: 4rem;
    align-items: flex-end;
    text-align: right;
}

/* =========================================================================
   Variant: left — content on the left edge, vertically centered. No caption.
   ========================================================================= */
.hero-section.hero--left {
    align-items: center;
    justify-content: flex-start;
}

.hero--left .hero-content {
    justify-content: flex-start;
}

.hero--left .hero-card {
    align-items: flex-start;
    text-align: left;
}

.hero--left .hero-title {
    font-size: clamp(2.5rem, 6.5vw, 4.75rem);
}

.hero--left .hero-benefits {
    justify-content: flex-start;
}

.hero--left .hero-actions {
    justify-content: flex-start;
}

.hero--left .hero-overlay {
    background:
        linear-gradient(to bottom, rgba(0, 0, 0, 0.45) 0%, rgba(0, 0, 0, 0) 120px),
        linear-gradient(to right, rgba(0, 0, 0, 0.65) 0%, rgba(0, 0, 0, 0.2) 40%, rgba(0, 0, 0, 0) 70%);
}

/* =========================================================================
   Responsive — collapse anchored variants toward a comfortable mobile layout.
   ========================================================================= */
@media (max-width: 991px) {
    /* Hero starts below the sticky header — size to content, not full viewport. */
    .hero-section {
        min-height: auto;
        height: auto;
        padding: 2rem 1.25rem 2.5rem;
        align-items: flex-end;
    }

    .hero--left .hero-content,
    .hero--editorial .hero-content,
    .hero--centered .hero-content {
        align-items: stretch;
    }

    .hero-card {
        max-width: 100%;
    }

    .trust-strip-section,
    .content-section,
    .how-it-works-section {
        position: relative;
        z-index: 1;
    }
}

@media (max-width: 768px) {
    .hero-section.hero--editorial {
        padding-bottom: 3rem;
    }

    .hero--editorial .hero-caption {
        display: none; /* avoid colliding with anchored copy on small screens */
    }

    .hero-actions {
        width: 100%;
    }

    .btn-hero-primary,
    .btn-hero-secondary,
    .hero-actions .btn-primary,
    .hero-actions .btn-secondary {
        flex: 1 1 auto;
    }
}
