/* ==========================================================================
   HOMEPAGE MODERNE - REFONTE COMPLÈTE 2025
   Design créatif avec animations, glassmorphism et effets modernes
   ========================================================================== */

/* Variables & Configuration */
:root {
    --hero-gradient-start: #0d2149;
    --hero-gradient-end: #1a3a6b;
    --accent-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --glass-bg: rgba(255, 255, 255, 0.1);
    --glass-border: rgba(255, 255, 255, 0.18);
}

.homepage-modern {
    overflow-x: hidden;
}

/* HERO SECTION AVEC PARALLAX */
.hero-parallax {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: linear-gradient(135deg, var(--hero-gradient-start) 0%, var(--hero-gradient-end) 100%);
}

.hero-parallax__bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 120%;
    z-index: 1;
    will-change: transform;
}

.hero-bg-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1s ease-in-out;
}

.hero-bg-slide.active {
    opacity: 1;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(13, 33, 73, 0.4) 0%, rgba(26, 58, 107, 0.35) 100%);
    z-index: 2;
}

.hero-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 3;
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 10;
    width: 100%;
    padding: 2rem 0;
    will-change: transform;
}

.hero-content-wrapper {
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
}

/* Badge animé */
.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 0.5rem 1.5rem;
    border-radius: 50px;
    color: white;
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 2rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.badge-icon {
    font-size: 1.2rem;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

/* Titre principal */
.hero-title {
    font-family: 'Lora', serif;
    font-size: 3.5rem;
    font-weight: 700;
    color: white;
    margin-bottom: 1.5rem;
    line-height: 1.2;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.6), 0 2px 8px rgba(0, 0, 0, 0.8);
}

.highlight-gradient {
    color: #ffd700;
    font-weight: 800;
    text-shadow: 0 0 30px rgba(255, 215, 0, 0.8), 
                 0 0 15px rgba(255, 193, 7, 0.6),
                 0 4px 20px rgba(0, 0, 0, 0.6),
                 0 2px 8px rgba(0, 0, 0, 0.8);
    position: relative;
}

.hero-subtitle {
    font-size: 1.3rem;
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: 2.5rem;
    line-height: 1.6;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.6), 0 1px 4px rgba(0, 0, 0, 0.8);
}

/* Boutons CTA */
.hero-cta-group {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 3rem;
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1.1rem;
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.4);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 40px rgba(102, 126, 234, 0.5);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: white;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-2px);
}

.btn-icon {
    transition: transform 0.3s ease;
}

.btn-primary:hover .btn-icon {
    transform: translateX(5px);
}

/* Statistiques */
.hero-stats {
    display: flex;
    justify-content: center;
    gap: 3rem;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    margin-top: 2rem;
}

.stat-item {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
    color: #ffd700;
    line-height: 1;
    margin-bottom: 0.5rem;
    text-shadow: 0 0 30px rgba(255, 215, 0, 0.8), 
                 0 0 15px rgba(255, 193, 7, 0.6),
                 0 4px 20px rgba(0, 0, 0, 0.6),
                 0 2px 8px rgba(0, 0, 0, 0.8);
}

.stat-label {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.9);
    text-transform: uppercase;
    letter-spacing: 1px;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.stat-divider {
    width: 1px;
    background: rgba(255, 255, 255, 0.2);
}

/* Contrôles slider */
.hero-slider-controls {
    position: absolute;
    bottom: 3rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 15;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.slider-arrow {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.slider-arrow:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

.slider-dots {
    display: flex;
    gap: 0.5rem;
}

.slider-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
}

.slider-dot.active {
    background: white;
    width: 30px;
    border-radius: 5px;
}

/* Indicateur de scroll */
.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 15;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    color: white;
    opacity: 0.7;
    animation: bounce 2s infinite;
}

.scroll-text {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.scroll-arrow {
    width: 2px;
    height: 30px;
    background: white;
    border-radius: 2px;
    position: relative;
}

.scroll-arrow::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 8px;
    height: 8px;
    border-right: 2px solid white;
    border-bottom: 2px solid white;
    transform: translateX(-50%) rotate(45deg);
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateX(-50%) translateY(0); }
    40% { transform: translateX(-50%) translateY(-10px); }
    60% { transform: translateX(-50%) translateY(-5px); }
}

/* Animations */
.animate-fade-in {
    animation: fadeIn 1s ease-out forwards;
    opacity: 0;
}

.animate-slide-up {
    animation: slideUp 1s ease-out forwards;
    opacity: 0;
}

.delay-1 { animation-delay: 0.2s; }
.delay-2 { animation-delay: 0.4s; }
.delay-3 { animation-delay: 0.6s; }

@keyframes fadeIn {
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* SECTION ÉVÉNEMENTS & ACTUALITÉS */
.events-news-section {
    padding: 0;
    background: linear-gradient(to bottom, #f8f9fa 0%, #ffffff 100%);
}

.container-fluid {
    max-width: 100%;
    padding: 0;
}

.split-grid {
    display: grid;
    grid-template-columns: 1fr;
    min-height: 600px;
}

@media (min-width: 992px) {
    .split-grid {
        grid-template-columns: 40% 60%;
    }
}

/* Calendrier Événements */
.event-calendar-wrapper {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    position: relative;
    overflow: hidden;
}

.event-calendar-bg-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    z-index: 0;
}

.event-calendar-bg-image.active {
    opacity: 1;
}

.event-calendar-wrapper::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, 
        rgba(102, 126, 234, 0.3) 0%, 
        rgba(118, 75, 162, 0.4) 100%);
    z-index: 1;
}

.calendar-icon-bg {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1;
}

.split-item-inner {
    position: relative;
    z-index: 2;
    text-align: center;
    color: white;
    width: 100%;
    max-width: 500px;
}

#event-calendar-card {
    padding: 2rem;
}

.calendar-header {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    opacity: 0.95;
    margin-bottom: 2rem;
    text-shadow: 0 3px 12px rgba(0, 0, 0, 0.6), 0 1px 3px rgba(0, 0, 0, 0.8);
    font-weight: 700;
}

.calendar-date-display {
    margin: 2rem 0;
}

.calendar-day {
    font-size: 5rem;
    font-weight: 700;
    line-height: 1;
    display: block;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.6), 0 2px 8px rgba(0, 0, 0, 0.8);
}

.calendar-month {
    font-size: 2rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-top: 0.5rem;
    display: block;
    text-shadow: 0 3px 15px rgba(0, 0, 0, 0.6), 0 1px 4px rgba(0, 0, 0, 0.8);
}

.calendar-event-info {
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(20px);
    border-radius: 15px;
    padding: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.4);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.calendar-event-type {
    background: rgba(255, 255, 255, 0.95);
    color: #667eea;
    font-size: 0.8rem;
    font-weight: 700;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    display: inline-block;
    margin-bottom: 1rem;
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.2);
}

.calendar-event-title {
    font-size: 1.3rem;
    font-weight: 600;
    margin: 1rem 0;
    line-height: 1.4;
    text-shadow: 0 3px 15px rgba(0, 0, 0, 0.6), 0 1px 4px rgba(0, 0, 0, 0.8);
}

.calendar-view-all {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: white;
    text-decoration: none;
    font-weight: 600;
    margin-top: 1.5rem;
    opacity: 0.95;
    transition: all 0.3s ease;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.calendar-view-all:hover {
    opacity: 1;
    transform: translateX(5px);
}

/* Actualités */
.news-featured-wrapper {
    padding: 3rem;
    background: white;
}

.split-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.section-title-modern {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 2rem;
    font-weight: 700;
    color: var(--color-text-dark);
}

.title-icon {
    font-size: 2rem;
}

.view-all-modern {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.view-all-modern:hover {
    gap: 0.75rem;
    color: #764ba2;
}

.news-cards-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .news-cards-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.news-card-compact {
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    height: 320px;
}

.news-card-compact:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.news-card-compact:hover .news-card-image {
    transform: scale(1.1);
}

.news-card-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.news-card-body {
    position: relative;
    z-index: 2;
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    background: linear-gradient(to bottom, 
        transparent 0%, 
        rgba(0, 0, 0, 0.3) 40%,
        rgba(0, 0, 0, 0.85) 100%);
    text-align: right;
    direction: rtl;
    transition: background 0.4s ease;
}

.news-card-body.fr {
    text-align: left;
    direction: ltr;
}

.news-card-compact:hover .news-card-body {
    background: linear-gradient(to bottom, 
        rgba(0, 0, 0, 0.2) 0%, 
        rgba(0, 0, 0, 0.6) 30%,
        rgba(0, 0, 0, 0.95) 100%);
}

.news-card-category {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    display: inline-block;
    width: fit-content;
    margin-left: auto;
    box-shadow: 0 3px 12px rgba(102, 126, 234, 0.4);
    align-self: flex-start;
}

.news-card-content-bottom {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.news-card-title {
    font-size: 1.25rem;
    font-weight: 800;
    line-height: 1.3;
    color: white;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-shadow: 0 3px 15px rgba(0, 0, 0, 0.6), 0 1px 3px rgba(0, 0, 0, 0.8);
    letter-spacing: -0.02em;
    transition: all 0.3s ease;
    order: 2;
}

.news-card-compact:hover .news-card-title {
    transform: translateY(-3px);
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.7), 0 2px 4px rgba(0, 0, 0, 0.9);
}

.news-card-excerpt {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.95);
    line-height: 1.6;
    margin-bottom: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
    max-height: 0;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    order: 3;
}

.news-card-compact:hover .news-card-excerpt {
    max-height: 100px;
    opacity: 1;
    transform: translateY(0);
}

.news-card-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.9);
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    direction: ltr;
    gap: 0.5rem;
    order: 1;
}

/* SECTION SERVICES NUMÉRIQUES */
.digital-services-section {
    padding: 5rem 0;
    background: white;
    position: relative;
    overflow: hidden;
}

.digital-services-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 300px;
    background: linear-gradient(to bottom, #f8f9fa, white);
    z-index: 1;
}

.section-header-center {
    text-align: center;
    margin-bottom: 4rem;
    position: relative;
    z-index: 2;
}

.section-label {
    display: inline-block;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-size: 0.85rem;
    font-weight: 600;
    padding: 0.5rem 1.5rem;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1rem;
}

.section-title-xl {
    font-size: 2.8rem;
    font-weight: 700;
    color: var(--color-text-dark);
    margin-bottom: 1rem;
}

.section-description {
    font-size: 1.1rem;
    color: var(--color-text-light);
    max-width: 600px;
    margin: 0 auto;
}

.services-modern-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
    position: relative;
    z-index: 2;
}

.service-card-modern {
    background: white;
    border-radius: 20px;
    padding: 2rem;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid transparent;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
}

.service-card-modern::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, 
        hsla(var(--card-hue), 70%, 60%, 0.05) 0%, 
        hsla(var(--card-hue), 70%, 50%, 0.1) 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 1;
}

.service-card-modern:hover::before {
    opacity: 1;
}

.service-card-modern:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
    border-color: hsla(var(--card-hue), 70%, 60%, 0.3);
}

.service-card-icon {
    position: relative;
    width: 70px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 15px;
    background: linear-gradient(135deg, 
        hsla(var(--card-hue), 70%, 95%, 1) 0%, 
        hsla(var(--card-hue), 70%, 90%, 1) 100%);
    z-index: 2;
    transition: all 0.4s ease;
}

.service-card-modern:hover .service-card-icon {
    transform: scale(1.1) rotate(-5deg);
}

.icon-emoji {
    font-size: 2rem;
    position: relative;
    z-index: 2;
}

.icon-glow {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 15px;
    background: linear-gradient(135deg, 
        hsla(var(--card-hue), 70%, 60%, 0.3) 0%, 
        hsla(var(--card-hue), 70%, 50%, 0.5) 100%);
    filter: blur(20px);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 1;
}

.service-card-modern:hover .icon-glow {
    opacity: 0.8;
}

.service-card-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--color-text-dark);
    margin: 0;
    position: relative;
    z-index: 2;
}

.service-card-desc {
    font-size: 0.95rem;
    color: var(--color-text-light);
    line-height: 1.5;
    margin: 0;
    flex-grow: 1;
    position: relative;
    z-index: 2;
}

.service-card-arrow {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: hsla(var(--card-hue), 70%, 95%, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: hsla(var(--card-hue), 70%, 50%, 1);
    transition: all 0.4s ease;
    position: relative;
    z-index: 2;
    align-self: flex-end;
}

.service-card-modern:hover .service-card-arrow {
    background: hsla(var(--card-hue), 70%, 50%, 1);
    color: white;
    transform: translateX(5px);
}

/* SECTION FORMATIONS - TABS DESIGN */
.formations-showcase-section {
    padding: 5rem 0;
    background: linear-gradient(to bottom, white 0%, #f8f9fa 100%);
}

/* Navigation par Tabs */
.formations-tabs-nav {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-bottom: 3rem;
}

@media (min-width: 768px) {
    .formations-tabs-nav {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
}

@media (min-width: 1200px) {
    .formations-tabs-nav {
        grid-template-columns: repeat(4, 1fr);
        gap: 1.5rem;
    }
}

.tab-button {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem;
    background: white;
    border: 2px solid #e0e7ff;
    border-radius: 16px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
    position: relative;
    overflow: hidden;
}

.tab-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    transform: translateX(-100%);
    transition: transform 0.3s ease;
}

.tab-button:hover::before {
    transform: translateX(0);
}

.tab-button:hover {
    border-color: #667eea;
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.15);
    transform: translateY(-2px);
}

.tab-button.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-color: #667eea;
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.3);
}

.tab-button.active::before {
    transform: translateX(0);
}

.tab-button.active .tab-icon {
    color: white;
}

.tab-button.active .tab-title,
.tab-button.active .tab-subtitle {
    color: white;
}

.tab-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #667eea;
    transition: all 0.3s ease;
}

.tab-button:hover .tab-icon {
    transform: scale(1.1);
}

.tab-text {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    text-align: left;
    flex: 1;
}

.tab-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #0d2149;
    line-height: 1.3;
    transition: color 0.3s ease;
}

.tab-subtitle {
    font-size: 0.85rem;
    color: #6b7280;
    font-weight: 500;
    transition: color 0.3s ease;
}

/* Contenu des Tabs */
.formations-tabs-content {
    position: relative;
    min-height: 400px;
}

.tab-panel {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.tab-panel.active {
    position: relative;
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.tab-panel-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    background: white;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08);
}

@media (min-width: 992px) {
    .tab-panel-layout {
        grid-template-columns: 400px 1fr;
        gap: 3rem;
    }
}

.tab-panel-image {
    position: relative;
    width: 100%;
    height: 300px;
    overflow: hidden;
}

@media (min-width: 992px) {
    .tab-panel-image {
        height: 100%;
        min-height: 500px;
    }
}

.tab-panel-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.tab-panel.active .tab-panel-image img {
    transform: scale(1.05);
}

.tab-panel-badge {
    position: absolute;
    top: 1.5rem;
    left: 1.5rem;
    padding: 0.75rem 1.5rem;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 700;
    color: #667eea;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.tab-panel-links {
    padding: 3rem 2rem;
}

@media (min-width: 992px) {
    .tab-panel-links {
        padding: 3rem 3rem 3rem 0;
    }
}

.tab-panel-title {
    font-size: 2rem;
    font-weight: 700;
    color: #0d2149;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.tab-panel-desc {
    font-size: 1.05rem;
    color: #6b7280;
    margin-bottom: 2.5rem;
    line-height: 1.6;
}

.links-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

@media (min-width: 768px) {
    .links-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.25rem;
    }
}

.resource-link {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem;
    background: #f8f9fa;
    border: 2px solid transparent;
    border-radius: 16px;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.resource-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, #667eea 0%, #764ba2 100%);
    transform: translateX(-4px);
    transition: transform 0.3s ease;
}

.resource-link:hover::before {
    transform: translateX(0);
}

.resource-link:hover {
    background: white;
    border-color: #667eea;
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.12);
    transform: translateX(5px);
}

.resource-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    transition: all 0.3s ease;
}

.resource-link:hover .resource-icon {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.2);
}

.resource-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.resource-title {
    font-size: 1rem;
    font-weight: 700;
    color: #0d2149;
    line-height: 1.3;
    transition: color 0.3s ease;
}

.resource-link:hover .resource-title {
    color: #667eea;
}

.resource-subtitle {
    font-size: 0.85rem;
    color: #6b7280;
    font-weight: 500;
}

.resource-arrow {
    flex-shrink: 0;
    font-size: 1.5rem;
    color: #667eea;
    font-weight: 700;
    opacity: 0;
    transform: translateX(-10px);
    transition: all 0.3s ease;
}

.resource-link:hover .resource-arrow {
    opacity: 1;
    transform: translateX(0);
}

/* RESPONSIVE DESIGN */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .hero-stats {
        gap: 1.5rem;
        flex-wrap: wrap;
    }
    
    .stat-number {
        font-size: 2rem;
    }
    
    .stat-divider {
        display: none;
    }
    
    .hero-cta-group {
        flex-direction: column;
        align-items: stretch;
    }
    
    .btn-large {
        width: 100%;
        justify-content: center;
    }
    
    .section-title-xl {
        font-size: 2rem;
    }
    
    .services-modern-grid {
        grid-template-columns: 1fr;
    }
    
    .formations-grid {
        grid-template-columns: 1fr;
    }
    
    .split-grid {
        grid-template-columns: 1fr;
    }
    
    .news-featured-wrapper,
    .event-calendar-wrapper {
        padding: 2rem 1rem;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .section-title-xl {
        font-size: 1.8rem;
    }
    
    .formation-card {
        height: 350px;
    }
    
    .calendar-day {
        font-size: 4rem;
    }
    
    .calendar-month {
        font-size: 1.5rem;
    }
}

@media (min-width: 768px) and (max-width: 1199px) {
    .formation-card {
        height: 380px;
    }
}

/* UTILITAIRES */
.fade-in-up {
    animation: fadeInUp 0.8s ease-out forwards;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease-out;
}

.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

* {
    scroll-behavior: smooth;
}

.formation-toggle-btn:focus,
.slider-arrow:focus,
.formation-menu-close:focus {
    outline: 2px solid white;
    outline-offset: 2px;
}
