/* =====================================================================
   GeoTech Design Consultants — smoothness layer (loaded last on every page)
   Goal: no stutter while scrolling, calmer animations, smooth anchors.
   ===================================================================== */

/* ---------- 1. Smooth anchor / back-to-top scrolling ---------- */
html { scroll-behavior: smooth; scroll-padding-top: 100px; }

/* ---------- 2. Gentle page fade-in (opacity only, no layout cost) ---------- */
@keyframes gdcPageIn { from { opacity: 0; } to { opacity: 1; } }
body { animation: gdcPageIn .45s ease-out backwards; }

/* ---------- 3. Sticky header: short, tidy slide instead of a 1-second "all" transition ---------- */
.sticky-top { transition: top .4s ease, box-shadow .3s ease; }

/* ---------- 4. Remove effects that force a full repaint on every scroll frame ---------- */
/* fixed background images (parallax) re-paint the whole banner while scrolling */
@media (min-width: 992px) { .bg-breadcrumb { background-attachment: scroll !important; } }
/* blur behind sticky bars / plain dark footer cards is costly and invisible there */
.sv-rail, .svp-nav, .sx-nav, .footer .footer-card {
    -webkit-backdrop-filter: none !important; backdrop-filter: none !important;
}
.sv-rail, .svp-nav, .sx-nav { background: rgba(255, 255, 255, .985) !important; }

/* ---------- 5. GeoTech Advantage moving background — same look, GPU-cheap ----------
   The gradient used to animate background-size/position (re-paints the whole section every frame).
   It now lives on a wide layer (injected by js/smooth.js) that only translates. */
.gt-adv { isolation: isolate; background: #f1f4fa !important; animation: none !important; }
.gt-adv-bg {
    position: absolute; top: 0; bottom: 0; left: 0; width: 300%; z-index: -1; pointer-events: none;
    background: linear-gradient(90deg, #f4f6fa, #e8edf8, #fdf1ea, #eaeef5, #f4f6fa, #e8edf8, #fdf1ea, #eaeef5, #f4f6fa);
    will-change: transform;
    animation: gdcAdvSlide 30s ease-in-out infinite alternate;
}
@keyframes gdcAdvSlide { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(-66.6667%, 0, 0); } }
/* dot-grid drift: transform only (was also animating background-position) */
@keyframes gdcOrbs {
    0%   { transform: translate3d(0, 0, 0); }
    100% { transform: translate3d(1.5%, -2%, 0); }
}

/* ---------- 6. Pause infinite animations while they are off-screen ---------- */
.gt-adv.gt-off .gt-adv-bg, .gt-adv.gt-off::before, .gt-adv.gt-off::after,
.india-map:not(.map-live) .map-pin .pin-icon,
.india-map:not(.map-live) .map-pin::before,
.india-map:not(.map-live) .map-hq-glow { animation-play-state: paused; }

/* ---------- 7. FAQ "Read more" reveal (home / about / service pages) ---------- */
@keyframes gdcFaqIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.gu-faq .accordion.gu-open .gu-faq-extra,
.sx-acc.open .sx-extra,
.bp-faq.bp-open .bp-faq-extra { animation: gdcFaqIn .35s ease both; }

/* ---------- 8. Blog FAQ: same Read more behaviour and button as the home page ---------- */
.bp-faq .bp-faq-extra { display: none; }
.bp-faq.bp-open .bp-faq-extra { display: block; }
.bp-faq-more-wrap { text-align: center; margin-top: 1.2rem; }
.bp-faq-more {
    background: #001659; color: #fff; border: 0; border-radius: 50px;
    padding: .65rem 1.8rem; font-weight: 700; transition: background .25s;
}
.bp-faq-more:hover { background: #ff5e14; }
.bp-faq-more i { transition: transform .25s; }
.bp-faq-more.open i { transform: rotate(180deg); }

/* ---------- 9. Respect "reduce motion" ---------- */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    body { animation: none; }
    .gt-adv-bg, .gt-adv::before, .gt-adv::after { animation: none !important; }
    .gu-faq .accordion.gu-open .gu-faq-extra, .sx-acc.open .sx-extra, .bp-faq.bp-open .bp-faq-extra { animation: none; }
}
