/**
 * Deferred CSS for Fast Single Service Page
 * Below-the-fold and animation styles
 */

/* ========================================
   HERO ANIMATIONS
   ======================================== */
.service-hero .tagline,
.service-hero .page-heading span,
.service-hero .desc,
.service-hero .service-button,
.scroll-icon {
    opacity: 0;
}

/* GSAP will handle the actual animations */

/* ========================================
   SWIPER STYLES
   ======================================== */
.swiper {
    overflow: hidden;
}

.swiper-wrapper {
    display: flex;
    transition-property: transform;
}

.swiper-slide {
    flex-shrink: 0;
}

/* Info carousel specific */
.info-swiper {
    overflow: visible;
}

.info-swiper .swiper-slide {
    width: 382px;
    margin-right: 30px;
}

/* Process carousel */
.process-swiper .swiper-slide {
    width: 100%;
}

/* ========================================
   PROCESS SECTION ANIMATIONS
   ======================================== */
.process-section .process-info,
.process-section .process-image {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.process-section.swiper-slide-active .process-info,
.process-section.swiper-slide-active .process-image {
    opacity: 1;
    transform: translateY(0);
}

.process-section.swiper-slide-active .process-image {
    transition-delay: 0.2s;
}

/* Process image hover */
.process-image img {
    transition: transform 0.3s ease;
}

.process-image:hover img {
    transform: scale(1.02);
}

/* ========================================
   STATS COUNTER ANIMATION
   ======================================== */
.stat-number {
    transition: color 0.3s ease;
}

.stat-item:hover .stat-number {
    color: #1a5bb3;
}

/* Divider between stats */
.stat-item {
    position: relative;
}

.stat-item::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: -17px;
    height: 1px;
    background: #206DD1;
    max-width: 212px;
}

/* ========================================
   MODEL CARDS EFFECTS
   ======================================== */
.model-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.model-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

/* Background patterns for model cards */
.model-card:nth-child(1) {
    background-image: url('/wp-content/uploads/2025/01/clip-1.svg');
}

.model-card:nth-child(2) {
    background-image: url('/wp-content/uploads/2025/01/clip-offshore.svg');
}

.model-card:nth-child(3) {
    background-image: url('/wp-content/uploads/2025/01/clip-dedicated.svg');
}

/* ========================================
   TECHNOLOGY TABS ANIMATIONS
   ======================================== */
.tech-item {
    opacity: 0;
    transform: translateY(15px);
    animation: fadeInTech 0.4s ease forwards;
}

.tech-panel.active .tech-item {
    animation-play-state: running;
}

.tech-item:nth-child(1) { animation-delay: 0.05s; }
.tech-item:nth-child(2) { animation-delay: 0.1s; }
.tech-item:nth-child(3) { animation-delay: 0.15s; }
.tech-item:nth-child(4) { animation-delay: 0.2s; }
.tech-item:nth-child(5) { animation-delay: 0.25s; }
.tech-item:nth-child(6) { animation-delay: 0.3s; }
.tech-item:nth-child(7) { animation-delay: 0.35s; }
.tech-item:nth-child(8) { animation-delay: 0.4s; }
.tech-item:nth-child(9) { animation-delay: 0.45s; }
.tech-item:nth-child(10) { animation-delay: 0.5s; }

@keyframes fadeInTech {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.tech-item img {
    transition: transform 0.3s ease;
}

.tech-item:hover img {
    transform: scale(1.1);
}

.tech-item span {
    transition: color 0.2s ease;
}

.tech-item:hover span {
    color: #206DD1;
}

/* ========================================
   INFO SECTION SLIDE EFFECTS
   ======================================== */
.info-swiper .slide-content {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.info-swiper .slide-content:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

/* ========================================
   SCROLL INDICATOR
   ======================================== */
.scroll-icon {
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    40% {
        transform: translateX(-50%) translateY(-10px);
    }
    60% {
        transform: translateX(-50%) translateY(-5px);
    }
}

/* ========================================
   BREADCRUMB HOVER EFFECTS
   ======================================== */
.breadcrumbs a {
    position: relative;
}

.breadcrumbs a::before {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background: #fff;
    transition: width 0.2s ease;
}

.breadcrumbs a:hover::before {
    width: calc(100% - 20px);
}

/* ========================================
   BUTTON EFFECTS
   ======================================== */
.service-button {
    position: relative;
    overflow: hidden;
}

.service-button::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.4s ease, height 0.4s ease;
}

.service-button:hover::after {
    width: 300px;
    height: 300px;
}

/* ========================================
   ACCESSIBILITY FOCUS STATES
   ======================================== */
.tech-tab:focus-visible,
.carousel-controls button:focus-visible {
    outline: 2px solid #206DD1;
    outline-offset: 2px;
}

.service-button:focus-visible {
    outline: 2px solid #fff;
    outline-offset: 2px;
    box-shadow: 0 0 0 4px #206DD1;
}

/* ========================================
   PRINT STYLES
   ======================================== */
@media print {
    .service-hero,
    .process-progress,
    .scroll-icon,
    .carousel-controls {
        display: none !important;
    }

    .service-hero-mobile {
        display: block !important;
    }

    .process-wrap {
        min-height: auto;
    }

    .process-section {
        min-height: auto;
        page-break-inside: avoid;
        margin-bottom: 40px;
    }
}

/* ========================================
   REDUCED MOTION
   ======================================== */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .service-hero *,
    .service-hero *::before,
    .service-hero *::after,
    .service-hero-mobile *,
    .service-hero-mobile *::before,
    .service-hero-mobile *::after,
    .scroll-icon,
    .scroll-icon-mb {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .process-section .process-info,
    .process-section .process-image {
        opacity: 1;
        transform: none;
    }
}
