/* ==========================================================================
   Block: Hero Video
   Full-height hero with Vidyard background video and text tile overlay
   ========================================================================== */

.hero-video {
    position: relative;
}

.hv-wrapper {
    position: relative;
    height: 80vh;
    overflow: hidden;
    background-color: var(--color-black);
}

@media (max-width: 767px) {
    .hv-wrapper {
        height: auto;
        display: flex;
        flex-direction: column;
    }
}

/* Tile overlay — sits on top of video */
.hv-tile-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 10;
    pointer-events: none;
}

@media (max-width: 767px) {
    .hv-tile-overlay {
        position: relative;
        height: auto;
    }
}

.hv-tile-wrapper {
    display: flex;
    align-items: flex-start;
    height: 100%;
    padding-top: 56px;
    max-width: var(--max-w-wrapper);
    margin: 0 auto;
    padding-left: 24px;
    padding-right: 24px;
}

@media (max-width: 767px) {
    .hv-tile-wrapper {
        height: auto;
        padding: 0 24px;
    }
}

@media (min-width: 1024px) {
    .hv-tile-wrapper {
        padding-top: var(--sticky-top);
        padding-left: 80px;
        padding-right: 80px;
    }
}

.hv-tile-container {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    column-gap: 24px;
}

.hv-tile {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 20px 20px 30px;
    margin-left: -16px;
    color: var(--color-white);
    background-color: var(--color-black);
    pointer-events: all;
    clip-path: polygon(0 0, 100% 0, 100% calc(100% - 40px), calc(100% - 40px) 100%, 0 100%);
    grid-column: span 12;
}

@media (min-width: 1024px) {
    .hv-tile {
        grid-column: span 6;
        margin-left: 0;
        padding: 40px 32px 48px;
    }
}

.hv-eyebrow {
    font-size: var(--font-h5-size);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin: 0;
}

.hv-title {
    font-size: var(--font-h3-size);
    font-weight: var(--font-h2-weight);
    line-height: var(--font-h2-line);
    letter-spacing: var(--font-h2-letter);
    margin: 0;
}

@media (min-width: 768px) {
    .hv-title {
        font-size: var(--font-h2-size);
    }
}

.hv-link {
    align-self: flex-start;
}

/* Video background */
.hv-video-wrapper {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 105%;
    height: calc(100% + 50px);
    z-index: 0;
}

.hv-video-wrapper .vidyard-player-container {
    width: auto !important;
    height: 100% !important;
}

.hv-video-wrapper .vidyard-player-container > div {
    height: 100% !important;
    max-width: none !important;
    aspect-ratio: 16/9;
}

.hv-video-wrapper > img{
	display: none !important;
}

@media (max-width: 767px) {
    .hv-video-wrapper {
        position: relative;
        top: auto;
        left: auto;
        transform: none;
        width: 100%;
        height: auto;
		padding-bottom: 0;
    }

    .hv-video-wrapper .vidyard-player-container {
        width: 100% !important;
        height: auto !important;
    }

    .hv-video-wrapper .vidyard-player-container > div {
        height: auto !important;
        aspect-ratio: unset;
    }
}

/* Fallback background image */
.hv-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
}

.hv-title-line { display: block; }
.hv-title-accent { color: var(--color-coral); }

.hero-video--type .hv-tile-overlay::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0,0,0,.72) 0%, rgba(0,0,0,.42) 38%, rgba(0,0,0,0) 65%);
    z-index: -1;
}
.hero-video--type .hv-tile-wrapper {
    align-items: flex-end;
    padding-bottom: 72px;
}
@media (min-width: 1024px) {
    .hero-video--type .hv-tile-wrapper {
        max-width: none;
        padding-left: 56px;
        padding-right: 56px;
        padding-bottom: 72px;
    }
}
@media (min-width: 1300px) {
    .hero-video--type .hv-tile-wrapper {
        max-width: var(--max-w-wrapper);
        padding-left: 80px;
        padding-right: 80px;
    }
}
.hero-video--type .hv-tile {
    background: none;
    clip-path: none;
    padding: 0;
    margin-left: 0;
    gap: 24px;
}
.hero-video--type .hv-title {
    font-size: clamp(44px, 6vw, 88px);
    line-height: .95;
    letter-spacing: -.02em;
	text-shadow: 0 2px 24px rgba(0,0,0,.35);
}

.hero-video--type .hv-title-accent { font-weight: 500; }

@media (min-width: 1024px) {
    .hero-video--type .hv-tile { grid-column: span 8; }
}
@media (max-width: 767px) {
    .hero-video--type .hv-tile-overlay::before { display: none; }
    .hero-video--type .hv-tile-wrapper { padding: 32px 24px; }
}
@media (prefers-reduced-motion: no-preference) {
    .hero-video--type .hv-title-line { animation: hv-rise .7s cubic-bezier(.2,.7,.2,1) both; }
    .hero-video--type .hv-title-accent { animation-delay: .12s; }
}
@keyframes hv-rise {
    from { opacity: 0; transform: translateY(24px); }
    to   { opacity: 1; transform: none; }
}

.hero-video--type .hv-wrapper {
    height: clamp(420px, 62vh, 640px);
}

@media (max-width: 767px) {
    .hero-video--type .hv-wrapper { height: auto; }
}

@media (min-width: 768px) {
    .hero-video--type .hv-video-wrapper .vidyard-player-container {
        position: relative;
        width: 100% !important;
    }
    .hero-video--type .hv-video-wrapper .vidyard-player-container > div {
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        width: max(100%, calc((clamp(420px, 62vh, 640px) + 50px) * 16 / 9)) !important;
        height: auto !important;
        aspect-ratio: 16 / 9;
    }
}

.hv-title[data-connect] .hv-title-accent {
    display: flex;
    width: max-content;
    position: relative;
    white-space: nowrap;
}
.hv-piece {
    display: inline-block;
    will-change: transform;
}
.hv-title[data-connect] .hv-piece + .hv-piece { transform: translateX(.45em); }
.hv-title[data-connect] .hv-piece + .hv-piece + .hv-piece { transform: translateX(.9em); }
.hv-connect-rule {
    position: absolute;
    left: 0;
    right: 0;
    bottom: -.14em;
    height: 2px;
    background: var(--color-coral);
    transform-origin: left;
    transform: scaleX(0);
}