/* ============================================================
   PANDAVAZ - PERFORMANCE & SCROLL FIXES
   Added: 2026-06-05 | Updated: 2026-06-06 (removed SSC overrides)
   ============================================================ */

/* 1. PREVENT HORIZONTAL OVERFLOW */
html, body {
    overflow-x: clip;
}
main {
    float: none !important;
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: clip; /* clip (not hidden) — avoids creating a scroll container that breaks position:sticky */
    overflow-y: visible;
}
.home-refresh {
    overflow-x: clip;
    max-width: 100vw;
}
.home-projects-ultra,
.media-promo-gallery,
.vt-section,
.ssc-intro,
.testimonals-section,
.logo-marquee-section,
.our-people-section {
    max-width: 100%;
    overflow-x: clip;
}
.home-refresh .slider {
    overflow: hidden !important;
    max-width: 100vw;
}
.split {
    overflow: hidden;
    max-width: 100%;
}

/* 2. REMOVE NAV ARROW ICONS */
.hamburger-navigation > li > a::after {
    content: none !important;
    display: none !important;
}
.hamburger-navigation li ul li a::after {
    content: none !important;
    display: none !important;
}

/* 3. VIDEO TESTIMONIALS - FIX NAME/ROLE CLIPPING */
.vt-card__name {
    white-space: normal !important;
    overflow: hidden !important;
    text-overflow: clip !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-height: 1.3 !important;
    word-break: break-word;
}
.vt-card__role {
    white-space: normal !important;
    overflow: hidden !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-height: 1.3 !important;
    word-break: break-word;
}
.vt-card__person {
    min-width: 0;
    flex: 1 1 0%;
    gap: 3px;
    display: flex !important;
    flex-direction: column !important;
}
.vt-card__meta {
    overflow: visible !important;
    padding-bottom: 4px;
    align-items: flex-start !important;
    margin-top: 12px;
}
.vt-card__avatar {
    flex-shrink: 0 !important;
    align-self: flex-start;
    margin-top: 2px;
}
.vt-card {
    overflow: visible !important;
    display: flex;
    flex-direction: column;
}
@media (max-width: 767px) {
    .vt-card { max-height: none !important; overflow: visible !important; }
    .vt-card__thumb { max-height: 360px !important; }
    .vt-track { max-height: none !important; overflow-x: auto !important; overflow-y: visible !important; }
    .vt-carousel-wrap { overflow: visible !important; }
    .vt-section { overflow: visible !important; max-height: none !important; padding-bottom: 70px !important; }
}

/* 4. SCROLL PERFORMANCE */
.testimonial-card {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}
.client-logo-item {
    will-change: auto !important;
}
.logo-marquee-section.is-visible .client-logo-item {
    will-change: auto !important;
}

/* 5. INT-HERO FADE — REMOVED (2026-06-08) */
/* Hero plays normally, no scroll fade. */

/* 6. MARQUEE */
.marquee-container {
    overflow: hidden;
}

/* 7. FOOTER */
.footer {
    transform: translateZ(0);
    -webkit-transform: translateZ(0);
    will-change: auto;
}

/* 8. OVERSCROLL — removed (was fighting iOS momentum scroll) */


/* ============================================================
   SCROLL JITTER FIXES - iOS Safari (2026-06-06)
   overflow:clip does not create scroll containers.
   ============================================================ */

/* 1. Remove backface-visibility from page wrapper — forces entire
      homepage onto a single GPU layer, causing scroll jitter */
.home-refresh,
.career-refresh,
.contact-refresh,
.about-refresh,
.services-refresh,
.client-refresh,
.portfolio-refresh,
.servicedetail-refresh {
    backface-visibility: visible !important;
    -webkit-backface-visibility: visible !important;
}

/* 2. Client logos: remove will-change:transform (dynamic GPU layer) */
.home-refresh .client-logo-grid {
    will-change: auto !important;
}

.home-refresh .client-logo-grid {
    will-change: auto !important;
}

/* 3. Testimonials section: overflow:clip instead of hidden */
.testimonals-section {
    overflow: clip !important;
}
.testimonals-section .owl-carousel .owl-stage-outer {
    overflow: clip !important;
}

/* 4. Video testimonials track: remove deprecated -webkit-overflow-scrolling */
.vt-track {
    -webkit-overflow-scrolling: auto !important;
}

/* 5. Logo marquee: overflow:clip */
.logo-marquee-section {
    overflow: clip !important;
}
.home-refresh .logo-marquee-section {
    overflow: clip !important;
}

/* 6. Projects section: overflow-x only — overflow:clip breaks CSS Grid columns */
.home-projects-ultra {
    overflow-x: clip;
    overflow-y: visible;
}
.home-projects-grid {
    width: 100%;
}
.home-project-card {
    overflow: hidden;
}
.home-project-card__link {
    overflow: hidden;
}
.home-refresh .works figure {
    overflow: clip !important;
}
.home-refresh .works .grid-item-double {
    overflow: clip !important;
}

/* 7. Marquee container: overflow:clip (keep mask working) */
.marquee-container {
    overflow: clip !important;
}

/* 8. Video testimonial cards: overflow:clip */
.vt-card__thumb {
    overflow: clip !important;
}
.vt-card {
    overflow: visible !important;
}

/* 9. Perspective box: fix typo + remove preserve-3d jitter */
.perspective-box {
    backface-visibility: hidden !important;
    -webkit-backface-visibility: hidden !important;
}
