/*=================================
    Styles WeAreBrand 
    - Animations fluides
    - Effets de texte
    - Transitions modernes
==================================*/

/* ===== SCROLL PROGRESS BAR ===== */
.scroll-progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #fff, rgba(255,255,255,0.6));
    transform-origin: left center;
    transform: scaleX(0);
    z-index: 9999;
    box-shadow: 0 0 10px rgba(255,255,255,0.5);
    pointer-events: none;
}

/* ===== HERO STYLES ===== */
.hero-style1 {
    position: relative;
    z-index: 2;
    overflow: visible;
}

.hero-big {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: -1;
    width: 100%;
    text-align: center;
    pointer-events: none;
}

.hero-big_text {
    font-size: clamp(80px, 15vw, 250px);
    font-weight: 900;
    line-height: 1;
    color: rgba(255, 255, 255, 0.05);
    text-transform: uppercase;
    letter-spacing: -0.02em;
    white-space: nowrap;
}

.hero-title {
    font-size: clamp(40px, 8vw, 120px);
    font-weight: 900;
    line-height: 1.1;
    margin-bottom: 30px;
    color: white;
    position: relative;
    overflow: hidden;
}

.hero-title .char {
    transform: translateY(100px) rotateX(-90deg);
    transform-origin: center bottom;
}

/* ===== SECTION TITLES ===== */
.sec-title {
    font-size: clamp(32px, 5vw, 60px);
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 25px;
    overflow: hidden;
    position: relative;
}

.sec-title .char {
    display: inline-block;
    transform: translateY(50px);
}

/* ===== SUB TITLES ===== */
.sub-title.style1 {
    display: inline-block;
    padding: 8px 20px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 50px;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.4s ease;
}

.sub-title.style1:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

/* ===== CARDS ENHANCED ===== */
.course-card,
.service-box,
.th-team {
    position: relative;
    overflow: hidden;
    border-radius: 20px;
    transition: all 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
    will-change: transform;
}

.course-card::before,
.service-box::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0) 100%);
    opacity: 0;
    transition: opacity 0.6s ease;
    z-index: 1;
    pointer-events: none;
}

.course-card:hover::before,
.service-box:hover::before {
    opacity: 1;
}

.course-card_img,
.service-box_icon {
    overflow: hidden;
    border-radius: 15px;
}

.course-card_img img {
    transition: transform 0.8s cubic-bezier(0.165, 0.84, 0.44, 1);
    will-change: transform;
}

/* ===== BUTTONS ENHANCED ===== */
.th-btn,
.line-btn {
    position: relative;
    overflow: hidden;
    transition: all 0.4s ease;
    will-change: transform;
}

.th-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.th-btn:hover::before {
    width: 300px;
    height: 300px;
}

.th-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
}

.line-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.line-btn i {
    transition: transform 0.3s ease;
}

.line-btn:hover i {
    transform: translateX(5px);
}

/* ===== IMAGES ENHANCED ===== */
.img-box1 {
    position: relative;
}

.img-box1 .img1,
.img-box1 .img2 {
    overflow: hidden;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

/* Support pour .global-img et .global-image */
.global-img,
.global-image {
    position: relative;
    overflow: hidden;
}

.global-img::after,
.global-image::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(255, 255, 255, 0.3), 
        transparent
    );
    transition: left 0.8s ease;
    pointer-events: none;
}

.global-img.active::after,
.global-image.active::after {
    left: 100%;
}

/* ===== HEADER ENHANCED ===== */
.sticky-wrapper {
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    backdrop-filter: blur(10px);
}

.sticky-wrapper.sticky {
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    background: rgba(128, 0, 128, 0.95) !important;
}

/* ===== CURSOR CUSTOM ===== */
.cursor,
.cursor2 {
    position: fixed;
    border-radius: 50%;
    pointer-events: none;
    z-index: 9999;
    mix-blend-mode: difference;
}

.cursor {
    width: 40px;
    height: 40px;
    border: 2px solid white;
    transition: transform 0.3s cubic-bezier(0.165, 0.84, 0.44, 1),
                opacity 0.2s ease;
}

.cursor2 {
    width: 8px;
    height: 8px;
    background-color: white;
    transition: transform 0.15s ease,
                width 0.3s ease,
                height 0.3s ease;
    transform: translate(-50%, -50%);
}

.cursor.hover {
    transform: scale(1.5);
    opacity: 0.6;
}

.cursor.click {
    transform: scale(0.8);
}

/* ===== SMOOTH TRANSITIONS ===== */
* {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

section,
.th-hero-wrapper {
    will-change: transform, opacity;
}

/* ===== INFO BOX ENHANCED ===== */
.info-box {
    position: relative;
    padding: 30px;
    border-radius: 15px;
    transition: all 0.4s ease;
    background: rgba(255, 255, 255, 0.05) !important;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.info-box:hover {
    transform: translateY(-10px);
    background: rgba(255, 255, 255, 0.1) !important;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
}

.info-box_icon {
    transition: all 0.6s ease;
}

.info-box:hover .info-box_icon {
    transform: scale(1.1) rotate(5deg);
}

/* ===== SLIDER ARROWS ENHANCED ===== */
.slider-arrow {
    position: relative;
    overflow: hidden;
    transition: all 0.4s ease;
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.1) !important;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.slider-arrow::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.slider-arrow:hover::before {
    width: 200%;
    height: 200%;
}

.slider-arrow:hover {
    transform: scale(1.1);
    border-color: rgba(255, 255, 255, 0.4);
}

/* ===== BADGE ANIMATION ===== */
.badge {
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.4);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 0 0 10px rgba(255, 255, 255, 0);
    }
}

/* ===== TEXT GRADIENT EFFECT ===== */
.hero-title,
.sec-title {
    background: linear-gradient(135deg, #ffffff 0%, rgba(255,255,255,0.7) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ===== SMOOTH SCROLL ===== */
html {
    scroll-behavior: smooth;
}

body {
    overflow-x: hidden;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 991px) {
    .hero-big_text {
        font-size: clamp(50px, 12vw, 150px);
    }
    
    .hero-title {
        font-size: clamp(30px, 6vw, 80px);
    }
    
    /* Désactiver les effets parallaxe sur mobile */
    .th-hero-bg,
    .course-card_img img {
        transform: none !important;
    }
}

@media (max-width: 767px) {
    /* Simplifier les animations sur très petits écrans */
    .cursor,
    .cursor2 {
        display: none;
    }
}

/* ===== LOADING STATES ===== */
.split-animated .char {
    opacity: 0;
    transform: translateY(50px);
}

/* ===== ADDITIONAL HOVER EFFECTS ===== */
.course-card_content,
.service-box_content {
    transition: all 0.4s ease;
}

.course-card:hover .course-card_content,
.service-box:hover .service-box_content {
    transform: translateY(-5px);
}

/* ===== GLASS MORPHISM EFFECT ===== */
.course-card,
.service-box {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.course-card:hover,
.service-box:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.4);
}

/* ===== ANIMATED BORDERS ===== */
.course-card::after,
.service-box::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 20px;
    padding: 2px;
    background: linear-gradient(135deg, 
        rgba(255,255,255,0.4), 
        rgba(255,255,255,0) 50%, 
        rgba(255,255,255,0.4)
    );
    -webkit-mask: 
        linear-gradient(#fff 0 0) content-box, 
        linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.6s ease;
}

.course-card:hover::after,
.service-box:hover::after {
    opacity: 1;
}

/* ===== TEXT REVEAL CLIP ===== */
.about-desc,
.sub-title {
    clip-path: inset(0 0 0 0);
}

/* ===== FLOATING ANIMATION ===== */
.jump {
    will-change: transform;
}

/* ===== ICON ROTATION ===== */
.service-box_icon,
.info-box_icon {
    will-change: transform;
}

/* ===== BACKDROP BLUR EFFECTS ===== */
.th-hero-wrapper {
    position: relative;
}

.th-hero-bg {
    position: relative;
    will-change: transform;
    transition: transform 0.3s ease-out;
}

/* ===== SMOOTH OPACITY TRANSITIONS ===== */
.course-card,
.service-box,
.th-team,
.about-desc,
.info-box {
    opacity: 1;
    will-change: transform, opacity;
}

/* ===== BUTTON EFFECTS ===== */
.th-btn {
    position: relative;
    z-index: 1;
    will-change: transform;
}

.line-btn {
    position: relative;
    transition: all 0.3s ease;
}

.line-btn::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: currentColor;
    transition: width 0.4s ease;
}

.line-btn:hover::after {
    width: 100%;
}

/* ===== STAGGER ITEMS ===== */
.swiper-slide,
.checklist li {
    will-change: transform, opacity;
}

/* ===== ENHANCED SHADOWS ===== */
.has-shadow .swiper-slide > * {
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.2);
    transition: box-shadow 0.4s ease;
}

.has-shadow .swiper-slide > *:hover {
    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.35);
}

/* ===== RESPONSIVE ADJUSTMENTS ===== */
@media (max-width: 1199px) {
    .hero-big_text {
        font-size: clamp(60px, 12vw, 180px);
    }
}

@media (max-width: 575px) {
    .hero-big_text {
        opacity: 0.03;
    }
    
    .scroll-progress-bar {
        height: 2px;
    }
}

/* ===== PERFORMANCE OPTIMIZATIONS ===== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    
    .cursor,
    .cursor2 {
        display: none;
    }
}

/* ===== LOADING ANIMATION ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 1s ease-out forwards;
}

/* ===== MAGNETIC BUTTON AREA ===== */
.th-btn,
.line-btn,
.icon-btn,
.slider-arrow {
    will-change: transform;
}

/* ===== SECTION BACKGROUNDS ===== */
section {
    position: relative;
    isolation: isolate;
}

/* ===== CAROUSEL ENHANCED ===== */
.carousel-item {
    transition: transform 0.8s cubic-bezier(0.165, 0.84, 0.44, 1),
                opacity 0.8s ease;
}

/* ===== FOOTER ENHANCED ===== */
.footer-wrapper {
    position: relative;
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* ===== GLOW EFFECTS ===== */
.hero-title,
.sec-title {
    text-shadow: 0 0 30px rgba(255, 255, 255, 0.1);
}

/* ===== Z-INDEX MANAGEMENT ===== */
.hero-big {
    z-index: -1;
}

.hero-style1 {
    z-index: 2;
}

/* ===== OVERFLOW HANDLING ===== */
.overflow-hidden {
    overflow: hidden;
}

.overflow-visible {
    overflow: visible !important;
}
