/* ============================================
   SERVICES À LA CARTE - CSS
   ============================================ */

/* ============================================
   HERO SECTION
   ============================================ */
.services-hero {
    background: linear-gradient(135deg, var(--vert-persil) 0%, #1a4a24 100%);
    min-height: 50vh;
    padding: 8rem 5% 5rem;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.services-hero .hero-decoration {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.services-hero .floating-sticker {
    position: absolute;
    opacity: 0.15;
}

.services-hero .sticker-1 {
    width: 120px;
    top: 15%;
    right: 10%;
    animation: float 6s ease-in-out infinite;
}

.services-hero .sticker-2 {
    width: 150px;
    bottom: 20%;
    left: 5%;
    animation: float 8s ease-in-out infinite reverse;
}

.services-hero .sticker-3 {
    width: 80px;
    top: 60%;
    right: 20%;
    animation: float 7s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(5deg); }
}

.hero-content-services {
    max-width: 900px;
    text-align: center;
    position: relative;
    z-index: 2;
}

.hero-content-services h1 {
    font-size: 3rem;
    color: var(--creme-fouettee);
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.hero-content-services .hero-description {
    font-size: 1.15rem;
    color: rgba(255, 241, 220, 0.9);
    line-height: 1.7;
    margin-bottom: 1rem;
}

.hero-content-services .hero-description strong {
    color: var(--jaune-oeuf);
}

/* ============================================
   NAVIGATION CATÉGORIES
   ============================================ */
.categories-nav {
    background: white;
    padding: 1rem 5%;
    position: sticky;
    z-index: 50;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

/* État compact/transparent de la nav catégories */
.categories-nav.compact {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    padding: 0.5rem 5%;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.categories-nav.compact .categories-container {
    gap: 0.5rem;
}

.categories-nav.compact .category-pill {
    padding: 0.4rem 0.8rem;
    font-size: 0.75rem;
}

/* Bouton toggle pour réduire la nav */
.nav-toggle-btn {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    background: var(--jaune-oeuf);
    color: var(--noir-olive);
    border: 3px solid var(--vert-persil);
    border-radius: 12px;
    width: 38px;
    height: 38px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer !important;
    pointer-events: auto !important;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 51;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    display:none;
}

.nav-toggle-btn::before {
    content: '';
    position: absolute;
    top: 3px;
    left: 5px;
    right: 5px;
    height: 6px;
    background: rgba(255, 255, 255, 0.4);
    border-radius: 3px;
}

.nav-toggle-btn:hover {
    background: var(--rouge-tomate);
    color: white;
    border-color: var(--rouge-tomate);
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 6px 20px rgba(218, 77, 27, 0.35);
}

.nav-toggle-btn:active {
    transform: translateY(-50%) scale(0.95);
}

.categories-nav.compact .nav-toggle-btn {
    background: var(--vert-persil);
    color: white;
    border-color: var(--vert-persil);
    display:none;
}

.categories-nav.compact .nav-toggle-btn::before {
    background: rgba(255, 255, 255, 0.2);
}

.categories-nav.compact .nav-toggle-btn:hover {
    background: var(--jaune-oeuf);
    color: var(--noir-olive);
    border-color: var(--jaune-oeuf);
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 6px 20px rgba(255, 200, 87, 0.4);
}

/* Animation de l'icône toggle */
.nav-toggle-btn .toggle-icon {
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.categories-nav.compact .nav-toggle-btn .toggle-icon {
    transform: rotate(180deg);
}

.categories-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
    justify-content: center;
}

.category-pill {
    padding: 0.6rem 1.2rem;
    background: var(--creme-fouettee);
    border: 2px solid transparent;
    border-radius: 30px;
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    font-size: 0.85rem;
    color: var(--noir-olive);
    text-decoration: none;
    transition: all 0.3s ease;
}

.category-pill:hover {
    background: var(--vert-persil);
    color: white;
    transform: translateY(-2px);
}

/* ============================================
   INTRO SECTION
   ============================================ */
.intro-section {
    padding: 5rem 5%;
    background: var(--creme-fouettee);
}

.intro-container {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 250px;
    gap: 4rem;
    align-items: center;
}

.intro-content h2 {
    font-size: 2.2rem;
    color: var(--vert-persil);
    margin-bottom: 1.5rem;
}

.intro-content p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--noir-olive);
    margin-bottom: 1rem;
}

.intro-content a {
    color: var(--rouge-tomate);
    text-decoration: underline;
}

.intro-visual {
    display: flex;
    justify-content: center;
}

.intro-hand {
    width: 200px;
    animation: float 6s ease-in-out infinite;
}

/* ============================================
   PATTERN DIVIDERS
   ============================================ */
.pattern-divider-services {
    height: 80px;
    background-image: url('/assets/motifs/carreauxverts.png');
    background-size: 300px;
    background-repeat: repeat;
}

.pattern-divider-services.pattern-red {
    background-image: url('/assets/motifs/carreauxrouges.png');
}

/* ============================================
   SERVICE CATEGORY SECTIONS
   ============================================ */
.service-category {
    padding: 5rem 5%;
    background: var(--vert-persil);
    position: relative;
}

.service-category.category-alt {
    background: var(--jaune-oeuf);
}

/* Titres et textes adaptés aux fonds colorés */
.service-category .category-number {
    color: rgba(255, 255, 255, 0.3);
}

.service-category .category-titles h2 {
    color: var(--creme-fouettee);
}

.service-category .category-titles h3 {
    color: rgba(255, 241, 220, 0.8);
}

.service-category .category-description {
    color: rgba(255, 241, 220, 0.9);
}

/* Styles pour la variante alt (jaune) */
.service-category.category-alt .category-number {
    color: rgba(0, 0, 0, 0.15);
}

.service-category.category-alt .category-titles h2 {
    color: var(--noir-olive);
}

.service-category.category-alt .category-titles h3 {
    color: var(--rouge-tomate);
}

.service-category.category-alt .category-description {
    color: var(--noir-olive);
}

/* Tagline adapté */
.service-category .category-tagline {
    background: rgba(255, 255, 255, 0.15);
    color: var(--creme-fouettee);
    border-left-color: var(--creme-fouettee);
}

.service-category.category-alt .category-tagline {
    background: rgba(0, 0, 0, 0.08);
    color: var(--noir-olive);
    border-left-color: var(--rouge-tomate);
}

.category-container {
    max-width: 1200px;
    margin: 0 auto;
}

/* Category Header */
.category-header {
    display: flex;
    align-items: flex-start;
    gap: 2rem;
    margin-bottom: 2rem;
}

.category-number {
    font-family: 'Montserrat', sans-serif;
    font-weight: 800;
    font-size: 3.5rem;
    color: var(--jaune-oeuf);
    line-height: 1;
    opacity: 0.6;
}

.category-titles h2 {
    font-size: 2rem;
    color: var(--vert-persil);
    margin-bottom: 0.5rem;
}

.category-titles h3 {
    font-size: 1.2rem;
    color: var(--rouge-tomate);
    font-weight: 500;
    font-family: 'Libre Baskerville', serif;
    font-style: italic;
}

.category-description {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--noir-olive);
    max-width: 800px;
    margin-bottom: 2.5rem;
}

/* ============================================
   SERVICES SLIDER
   ============================================ */
.slider-wrapper {
    position: relative;
    margin: 0 -5%;
}

.services-slider {
    overflow-x: auto;
    padding: 1rem 5% 2rem;
    cursor: grab;
    scrollbar-width: none;
    -ms-overflow-style: none;
    scroll-behavior: smooth;
}

.services-slider::-webkit-scrollbar {
    display: none;
}

.services-slider.active {
    cursor: grabbing;
}

.services-track {
    display: flex;
    gap: 1.5rem;
    padding-bottom: 0.5rem;
}

/* Navigation Arrows */
.slider-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 65px;
    height: 65px;
    background: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
    transition: all 0.3s ease;
    font-size: 2.2rem;
    font-weight: 300;
    color: var(--vert-persil);
}

.slider-nav:hover {
    background: var(--vert-persil);
    color: white;
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
}

.slider-nav:active {
    transform: translateY(-50%) scale(0.95);
}

.slider-nav.prev {
    left: 1%;
}

.slider-nav.next {
    right: 1%;
}

.slider-nav.hidden {
    opacity: 0;
    pointer-events: none;
}

/* Alt category arrows */
.category-alt .slider-nav {
    color: var(--rouge-tomate);
}

.category-alt .slider-nav:hover {
    background: var(--rouge-tomate);
    color: white;
}

/* Service Cards - Nouvelles cartes avec images de fond */
.service-card {
    flex: 0 0 auto;
    width: 320px;
    min-height: 280px;
    border-radius: 20px;
    padding: 0;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    position: relative;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    border: none;
    overflow: hidden;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* Overlay gradient sur les cartes */
.service-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(0, 0, 0, 0.1) 0%,
        rgba(0, 0, 0, 0.4) 50%,
        rgba(0, 0, 0, 0.8) 100%
    );
    z-index: 1;
    transition: background 0.4s ease;
}

.service-card:hover::before {
    background: linear-gradient(
        180deg,
        rgba(0, 0, 0, 0.05) 0%,
        rgba(0, 0, 0, 0.3) 50%,
        rgba(0, 0, 0, 0.7) 100%
    );
}

/* Contenu des cartes */
.service-card-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 2rem;
    z-index: 2;
    transform: translateY(0);
    transition: transform 0.4s ease;
}

.service-card:hover .service-card-content {
    transform: translateY(-8px);
}

.category-alt .service-card {
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

.service-card:hover {
    transform: translateY(-12px) scale(1.02);
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.25);
}

.service-card-large {
    width: 400px;
    min-height: 320px;
}

.service-card h4 {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.25rem;
    font-weight: 700;
    color: white;
    margin-bottom: 0.8rem;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

.service-card p {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.6;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}

/* Images de fond Unsplash par service */
/* Stratégie - Chess/Strategy images */
.service-card[data-service="strategie-contenu"] {
    background: url('https://images.unsplash.com/photo-1552664730-d307ca884978?w=600&q=80') center/cover;
}
.service-card[data-service="calendrier-editorial"] {
    background: url('https://images.unsplash.com/photo-1506784983877-45594efa4cbe?w=600&q=80') center/cover;
}
.service-card[data-service="benchmark"] {
    background: url('https://images.unsplash.com/photo-1460925895917-afdab827c52f?w=600&q=80') center/cover;
}

/* Rédaction - Writing/Content images */
.service-card[data-service="articles-blog"] {
    background: url('https://images.unsplash.com/photo-1455390582262-044cdead277a?w=600&q=80') center/cover;
}
.service-card[data-service="posts-linkedin"] {
    background: url('https://images.unsplash.com/photo-1611944212129-29977ae1398c?w=600&q=80') center/cover;
}
.service-card[data-service="posts-instagram"] {
    background: url('https://images.unsplash.com/photo-1611162616475-46b635cb6868?w=600&q=80') center/cover;
}
.service-card[data-service="posts-facebook"] {
    background: url('https://images.unsplash.com/photo-1563986768494-4dee2763ff3f?w=600&q=80') center/cover;
}
.service-card[data-service="communique-presse"] {
    background: url('https://images.unsplash.com/photo-1504711434969-e33886168f5c?w=600&q=80') center/cover;
}
.service-card[data-service="livre-blanc"] {
    background: url('https://images.unsplash.com/photo-1456324504439-367cee3b3c32?w=600&q=80') center/cover;
}
.service-card[data-service="newsletter"] {
    background: url('https://images.unsplash.com/photo-1596526131083-e8c633c948d2?w=600&q=80') center/cover;
}

/* Graphisme - Design/Creative images */
.service-card[data-service="creation-logo"] {
    background: url('https://images.unsplash.com/photo-1626785774573-4b799315345d?w=600&q=80') center/cover;
}
.service-card[data-service="templates-reseaux"] {
    background: url('https://images.unsplash.com/photo-1561070791-2526d30994b5?w=600&q=80') center/cover;
}
.service-card[data-service="pack-templates"] {
    background: url('https://images.unsplash.com/photo-1558655146-d09347e92766?w=600&q=80') center/cover;
}
.service-card[data-service="banniere-linkedin"] {
    background: url('https://images.unsplash.com/photo-1611944212129-29977ae1398c?w=600&q=80') center/cover;
}
.service-card[data-service="fond-teams"] {
    background: url('https://images.unsplash.com/photo-1497366216548-37526070297c?w=600&q=80') center/cover;
}
.service-card[data-service="flyers"] {
    background: url('https://images.unsplash.com/photo-1586075010923-2dd4570fb338?w=600&q=80') center/cover;
}
.service-card[data-service="cartes-visite"] {
    background: url('https://images.unsplash.com/photo-1586281380117-5a60ae2050cc?w=600&q=80') center/cover;
}
.service-card[data-service="kakemono"] {
    background: url('https://images.unsplash.com/photo-1540575467063-178a50c2df87?w=600&q=80') center/cover;
}
.service-card[data-service="goodies"] {
    background: url('https://images.unsplash.com/photo-1513542789411-b6a5d4f31634?w=600&q=80') center/cover;
}

/* Vidéo - Video/Film images */
.service-card[data-service="creation-reel"] {
    background: url('https://images.unsplash.com/photo-1492724441997-5dc865305da7?w=600&q=80') center/cover;
}
.service-card[data-service="montage-reel"] {
    background: url('https://images.unsplash.com/photo-1574717024653-61fd2cf4d44d?w=600&q=80') center/cover;
}

/* Réseaux sociaux */
.service-card[data-service="optim-facebook"] {
    background: url('https://images.unsplash.com/photo-1563986768494-4dee2763ff3f?w=600&q=80') center/cover;
}
.service-card[data-service="optim-instagram"] {
    background: url('https://images.unsplash.com/photo-1611162617213-7d7a39e9b1d7?w=600&q=80') center/cover;
}
.service-card[data-service="optim-linkedin-perso"] {
    background: url('https://images.unsplash.com/photo-1560472355-536de3962603?w=600&q=80') center/cover;
}
.service-card[data-service="optim-linkedin-page"] {
    background: url('https://images.unsplash.com/photo-1611944212129-29977ae1398c?w=600&q=80') center/cover;
}
.service-card[data-service="creation-linkedin-page"] {
    background: url('https://images.unsplash.com/photo-1616469829581-73993eb86b02?w=600&q=80') center/cover;
}

/* Publicité */
.service-card[data-service="google-ads"] {
    background: url('https://images.unsplash.com/photo-1432888498266-38ffec3eaf0a?w=600&q=80') center/cover;
}
.service-card[data-service="meta-ads"] {
    background: url('https://images.unsplash.com/photo-1533750349088-cd871a92f312?w=600&q=80') center/cover;
}

/* SEO */
.service-card[data-service="optimisation-seo"] {
    background: url('https://images.unsplash.com/photo-1571721795195-a2ca2d3370a9?w=600&q=80') center/cover;
}

/* Sites */
.service-card[data-service="site-vitrine"] {
    background: url('https://images.unsplash.com/photo-1460925895917-afdab827c52f?w=600&q=80') center/cover;
}
.service-card[data-service="site-ecommerce"] {
    background: url('https://images.unsplash.com/photo-1556742049-0cfed4f6a45d?w=600&q=80') center/cover;
}
.service-card[data-service="landing-page"] {
    background: url('https://images.unsplash.com/photo-1467232004584-a241de8bcf5d?w=600&q=80') center/cover;
}
.service-card[data-service="application-web"] {
    background: url('https://images.unsplash.com/photo-1551288049-bebda4e38f71?w=600&q=80') center/cover;
}

/* Ateliers */
.service-card[data-service="atelier-chatgpt"] {
    background: url('https://images.unsplash.com/photo-1677442136019-21780ecad995?w=600&q=80') center/cover;
}
.service-card[data-service="atelier-personas"] {
    background: url('https://images.unsplash.com/photo-1552664730-d307ca884978?w=600&q=80') center/cover;
}

/* Fallback générique */
.service-card:not([data-service]) {
    background: linear-gradient(135deg, var(--vert-persil) 0%, #1a4a24 100%);
}

.category-alt .service-card:not([data-service]) {
    background: linear-gradient(135deg, var(--rouge-tomate) 0%, #a52828 100%);
}

/* Card Magnets */
.service-card .card-magnet {
    position: absolute;
    width: 55px;
    height: 55px;
    z-index: 15;
    transition: transform 0.4s ease;
    filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.25));
}

.service-card .card-magnet img {
    width: 100%;
    height: auto;
}

.service-card .magnet-top-right {
    top: -20px;
    right: -18px;
    transform: rotate(12deg);
}

.service-card .magnet-top-left {
    top: -20px;
    left: -18px;
    transform: rotate(-12deg);
}

.service-card:hover .card-magnet {
    transform: rotate(0deg) scale(1.15);
}

/* Card Animations - Background visible before animation */
.service-card.animate-card {
    transform: translateY(30px);
}

.service-card.animate-card .service-card-content {
    opacity: 0;
    transform: translateY(20px);
}

.service-card.animate-card.visible {
    transform: translateY(0);
    transition: transform 0.5s ease;
}

.service-card.animate-card.visible .service-card-content {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.5s ease 0.15s, transform 0.5s ease 0.15s;
}

/* ============================================
   CATEGORY TAGLINE & CTA
   ============================================ */
.category-tagline {
    font-family: 'Libre Baskerville', serif;
    font-style: italic;
    font-size: 1.2rem;
    color: var(--vert-persil);
    text-align: center;
    margin: 2.5rem 0 2rem;
    padding: 1.5rem;
    background: rgba(255, 200, 87, 0.15);
    border-radius: 12px;
    border-left: 4px solid var(--jaune-oeuf);
}

.category-cta {
    text-align: center;
    margin-top: 1.5rem;
}

/* ============================================
   CTA FINAL SECTION
   ============================================ */
.cta-services-section {
    padding: 6rem 5%;
    background: var(--noir-olive);
    position: relative;
    overflow: hidden;
}

.cta-services-container {
    max-width: 900px;
    margin: 0 auto;
    position: relative;
}

.cta-sticker {
    position: absolute;
    z-index: 10;
}

.cta-sticker-1 {
    width: 120px;
    top: -30px;
    left: -60px;
    transform: rotate(-15deg);
}

.cta-sticker-2 {
    width: 80px;
    bottom: -20px;
    right: -40px;
    transform: rotate(20deg);
}

.cta-services-card {
    background: white;
    border-radius: 24px;
    padding: 4rem;
    text-align: center;
    position: relative;
    z-index: 2;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.cta-services-card h2 {
    font-size: 2rem;
    color: var(--vert-persil);
    margin-bottom: 1.5rem;
}

.cta-services-card p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--noir-olive);
    margin-bottom: 1rem;
}

.cta-services-card a:not(.btn) {
    color: var(--rouge-tomate);
    text-decoration: underline;
}

.cta-conclusion {
    font-size: 1.15rem;
    padding: 1.5rem;
    background: var(--creme-fouettee);
    border-radius: 12px;
    margin: 2rem 0;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 2rem;
}

/* ============================================
   ANIMATIONS
   ============================================ */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(40px);
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 900px) {
    .services-hero {
        min-height: 40vh;
        padding: 6rem 5% 4rem;
    }

    .hero-content-services h1 {
        font-size: 2.2rem;
    }

    .intro-container {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }

    .intro-visual {
        order: -1;
    }

    .intro-hand {
        width: 150px;
    }

    .category-header {
        flex-direction: column;
        gap: 1rem;
    }

    .category-number {
        font-size: 2.5rem;
    }

    .category-titles h2 {
        font-size: 1.6rem;
    }

    .cta-services-card {
        padding: 2.5rem 1.5rem;
    }

    .cta-services-card h2 {
        font-size: 1.6rem;
    }
}

@media (max-width: 600px) {
    .categories-nav {
        padding: 1rem 3%;
    }

    .category-pill {
        padding: 0.5rem 0.9rem;
        font-size: 0.75rem;
    }

    .service-card {
        width: 280px;
        min-height: 240px;
    }

    .service-card-content {
        padding: 1.5rem;
    }

    .service-card h4 {
        font-size: 1.1rem;
    }

    .service-card p {
        font-size: 0.9rem;
    }

    .service-card-large {
        width: 320px;
        min-height: 280px;
    }

    .pattern-divider-services {
        height: 60px;
        background-size: 200px;
    }

    .category-tagline {
        font-size: 1rem;
        padding: 1rem;
    }

    .cta-buttons {
        flex-direction: column;
    }

    .cta-buttons .btn {
        width: 100%;
    }
}

/* ============================================
   RESPONSIVE ARROWS
   ============================================ */
@media (max-width: 768px) {
    .slider-nav {
        width: 50px;
        height: 50px;
        font-size: 1.6rem;
    }
}

@media (max-width: 480px) {
    .slider-nav {
        width: 42px;
        height: 42px;
        font-size: 1.4rem;
    }
}
