/* Video Container - Responsive 16:9 */
.video-container {
    position: relative;
    padding-bottom: 56.25%;
    /* 16:9 aspect ratio */
    height: 0;
    overflow: hidden;
    max-width: 100%;
    background: #000;
    border-radius: var(--radius-lg);
}

.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* Poster fallback: shows YouTube thumbnail (or any image) while the
   iframe is still negotiating the consent prompt / loading the player.
   The thumbnail URL is set inline via style="background-image:..." */
.video-container--poster {
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.video-container--poster::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0,0,0,0.25) 0%, rgba(0,0,0,0.55) 100%);
    pointer-events: none;
    transition: opacity 0.3s;
}

.video-container--poster:hover::after {
    opacity: 0.7;
}

/* ----- YouTube facade (lazy-load placeholder) ----- */
.yt-facade {
    position: relative;
    display: block;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 */
    height: 0;
    overflow: hidden;
    border-radius: var(--radius-lg);
    cursor: pointer;
    background: #000;
}

.yt-facade__thumb {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: filter 0.3s ease, transform 0.3s ease;
}

.yt-facade::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0,0,0,0.0) 30%, rgba(0,0,0,0.55) 100%);
    z-index: 1;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.yt-facade__play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: transparent;
    border: 0;
    padding: 0;
    cursor: pointer;
    z-index: 2;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.yt-facade__play svg {
    display: block;
    filter: drop-shadow(0 4px 12px rgba(0,0,0,0.5));
}

.yt-facade:hover .yt-facade__thumb,
.yt-facade:focus-visible .yt-facade__thumb {
    filter: brightness(0.85);
    transform: scale(1.02);
}

.yt-facade:hover .yt-facade__play,
.yt-facade:focus-visible .yt-facade__play {
    transform: translate(-50%, -50%) scale(1.08);
}

.yt-facade:hover .yt-facade__play svg path:first-child,
.yt-facade:focus-visible .yt-facade__play svg path:first-child {
    fill: var(--accent-primary, #00d9ff);
    opacity: 0.95;
}

.yt-facade:focus-visible {
    outline: 3px solid var(--accent-primary, #00d9ff);
    outline-offset: 3px;
}

.yt-facade--activated iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.yt-facade--activated::before,
.yt-facade--activated .yt-facade__play {
    display: none;
}

/* Costellazione CTA Section */
.costellazione-cta {
    text-align: center;
    background: #ffffffee;
    color: #000000;
    padding: var(--space-xxl) 0;
}

.costellazione-cta .cta-content {
    max-width: 800px;
    margin: 0 auto;
}

.costellazione-cta h2 {
    font-size: var(--font-size-4xl);
    margin-bottom: var(--space-md);
    color: #000000;
}

.costellazione-cta .lead {
    font-size: var(--font-size-lg);
    margin-bottom: var(--space-xl);
    color: #000000;
}

.costellazione-cta .infographic-fullwidth {
    width: 100%;
    max-width: 100%;
    height: auto;
    display: block;
    margin: var(--space-xl) 0;
}

/* Hero Video Section - Full Width */
.hero-video-section .video-container {
    max-width: 100%;
    border-radius: 0;
}

/* Testimonials Section */
.testimonials-section {
    background: var(--bg-secondary);
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-xxl);
    margin-top: var(--space-xl);
}

@media (max-width: 768px) {
    .testimonials-grid {
        grid-template-columns: 1fr;
    }
}

.testimonial-item {
    background: var(--bg-primary);
    padding: var(--space-lg);
    border-radius: var(--radius-lg);
}

.testimonial-item h3 {
    margin-bottom: var(--space-sm);
    font-size: var(--font-size-md);
}