/*
 * Mobile-only styles - loaded only on phone devices
 * This file is conditionally loaded for screens < 768px
 *
 * ⚠️  TOUTES les règles mobile doivent être ici, PAS dans styles.css
 *
 * En production, Vite charge styles.css APRÈS ce fichier.
 * Si un même sélecteur existe dans les deux fichiers avec des valeurs
 * différentes, styles.css gagnera en production → bug visible uniquement
 * sur le site déployé, pas en dev.
 */

/* Hide back button on article pages */
.back-button,
.nav-link.back-button,
.nav-links .back-button,
.nav-links a.back-button,
a[href="../index.html"].back-button {
  display: none;
}

/* Hide nav-links div if it only contains back button */
.nav-links:has(.back-button):not(:has(:not(.back-button))) {
  display: none;
}

/* Additional mobile optimizations when JS detects mobile device */
body.is-mobile-device {
  /* Optimize touch interactions */
  -webkit-tap-highlight-color: transparent;
  touch-action: pan-y;
}

/* Hide all desktop-specific sections on mobile */
@media screen and (max-width: 767px) {
  /* Calendar mobile adjustments */
  .calendar-popup-overlay {
    padding: 2vw;
    box-sizing: border-box;
  }

  .calendar-popup {
    max-width: calc(100vw - 4vw);
    margin: 0 auto;
    width: calc(100vw - 4vw);
    box-sizing: border-box;
    border-radius: 3vw;
  }

  .calendar-popup .popup-content {
    flex-direction: column;
    padding: 2vw;
    padding-bottom: 4vw;
    box-sizing: border-box;
    width: 100%;
  }

  .calendar-popup .submit-btn {
    margin-bottom: 3vw;
  }

  .calendar-left,
  .calendar-right {
    width: 100%;
    padding: 0;
    box-sizing: border-box;
    border: none;
    border-right: none;
    border-bottom: none;
    border-top: none;
  }

  .calendar-left h2,
  #calendarPopupTitle {
    padding-top: 12vw;
    margin-top: 0;
  }

  .calendar-popup .popup-close,
  .contact-popup .popup-close {
    top: 3vw;
    right: 3vw;
    width: 10vw;
    height: 10vw;
    font-size: 0;
  }

  .calendar-popup .popup-close::before,
  .calendar-popup .popup-close::after,
  .contact-popup .popup-close::before,
  .contact-popup .popup-close::after {
    width: 4vw;
  }

  .calendar-container {
    padding: 1vw;
    margin: 0;
    width: 100%;
    box-sizing: border-box;
  }

  .calendar-weekdays,
  .calendar-days {
    width: 100%;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    gap: 0.5vw;
  }

  .calendar-weekdays div {
    font-size: 2.5vw;
    padding: 1vw 0;
    text-align: center;
  }

  .calendar-day {
    font-size: 3vw;
    padding: 1vw;
    width: auto;
    min-width: auto;
    max-width: auto;
    text-align: center;
  }

  .calendar-header {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 4vw;
  }

  .calendar-header h3 {
    font-size: 5vw;
    min-width: 50vw;
    text-align: center;
  }

  .calendar-nav {
    width: 10vw;
    height: 10vw;
    font-size: 5vw;
  }

  .calendar-view-container {
    width: 100%;
    display: flex;
    justify-content: center;
    box-sizing: border-box;
    overflow: hidden;
  }

  .calendar-view-container > * {
    width: 100%;
    box-sizing: border-box;
  }

  /* Hide honeypot and hidden fields completely on mobile */
  input[name="website"],
  input[type="hidden"] {
    display: none;
    visibility: hidden;
    position: absolute;
    left: -9999px;
    top: -9999px;
    width: 0;
    height: 0;
    opacity: 0;
    border: none;
    margin: 0;
    padding: 0;
    line-height: 0;
    font-size: 0;
  }

  /* Remove any borders or lines from form elements */
  .calendar-right .contact-form,
  .calendar-popup .contact-form {
    border-top: none;
    padding-top: 2vw;
  }

  .calendar-right .form-row:first-of-type,
  .contact-form .form-row:first-of-type,
  .calendar-popup .form-row:first-of-type {
    border-top: none;
    margin-top: 0;
    padding-top: 0;
  }

  /* Ensure first visible input has no line above */
  input[name="name"] {
    border-top: 0.25vw solid #e0e0e0;
    margin-top: 0;
  }

  .form-row:first-of-type input:first-child {
    margin-top: 0;
  }

  .calendar-right::before,
  .contact-form::before {
    display: none;
  }

  /* Fix reCAPTCHA alignment on mobile */
  .g-recaptcha {
    transform: scale(0.77);
    transform-origin: 0 0;
    margin: 0;
    display: block;
    width: fit-content;
    max-width: 100%;
  }

  .form-row:has(.g-recaptcha),
  #contactRecaptcha,
  #calendarRecaptcha {
    display: flex;
    justify-content: center;
    width: 100%;
    padding: 0;
    margin: 0 auto;
  }

  /* Navbar mobile adjustments - full width flush to top, twice bigger */
  body .navbar,
  html body .navbar,
  nav.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    height: auto;
    padding: 3.5vw !important; /* Match offre.html navbar - !important needed due to Vite CSS load order */
    padding-top: calc(
      3.5vw + env(safe-area-inset-top)
    ) !important; /* Account for notch/status bar */
    margin: 0;
    margin-top: 0;
    border: none;
    border-radius: 0;
    background-color: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(0.1875rem);
    -webkit-backdrop-filter: blur(0.1875rem);
    /* Ignore any safe area or viewport insets for positioning */
    transform: translateY(0);
    /* Override any inherited top value */
    inset-block-start: 0;
  }

  /* Override any body/html padding that might push content down */
  body {
    padding-top: 0;
    margin-top: 0;
  }

  html {
    padding-top: 0;
    margin-top: 0;
  }

  /* Hide original nav-actions (inside navbar, broken by backdrop-filter containing block) */
  .nav-actions {
    display: none !important;
  }

  /* Hide "Commencer" button on mobile - use floating button instead */
  .nav-button.nav-cta {
    display: none;
  }

  /* Floating nav buttons outside navbar — fixed bottom-left */
  .mobile-floating-nav {
    display: flex !important;
    position: fixed;
    bottom: 5vw;
    left: 5vw;
    z-index: 10001;
    align-items: center;
    gap: 0;
  }

  .mobile-float-icon {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border: 0.25vw solid #000;
    border-radius: 0;
    cursor: pointer;
    color: #000;
  }

  .mobile-float-icon:first-child {
    border-right: none;
  }

  .mobile-float-icon svg {
    stroke: #000;
  }

  /* Hide floating buttons when menu or search is open */
  body.menu-open .mobile-floating-nav,
  body.search-open .mobile-floating-nav {
    display: none !important;
  }

  body.menu-open .mobile-contact-button,
  body.search-open .mobile-contact-button {
    display: none !important;
  }

  /* Mobile: ne montrer que 2 suggestions populaires (Multi-Agents + Ontologie) */
  .search-link-desktop {
    display: none;
  }

  /* Search: tout sur une ligne (label + 2 liens) */
  .search-suggestions {
    flex-wrap: nowrap !important;
    gap: 1.5vw !important;
  }

  .search-label {
    font-size: 0.79rem !important;
  }

  .search-link {
    font-size: 1.056rem !important;
  }

  .nav-icon-button svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
  }

  /* Boutons fixes: toujours blanc avec bordure noire, independant du scroll */
  .navbar.past-video .nav-icon-button,
  .nav-actions .nav-icon-button {
    background: #fff;
    border-color: #000;
    color: #000;
  }

  .navbar.past-video .nav-icon-button svg,
  .nav-actions .nav-icon-button svg {
    stroke: #000;
  }

  .nav-logo a {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.6rem !important;
  }

  .nav-logo a span {
    display: inline;
    font-size: 1.6rem !important;
    font-weight: 400;
  }

  .nav-logo img {
    width: 40px !important;
    height: 40px !important;
  }
  /* Hide desktop carousel */
  .carousel-section {
    display: none;
  }

  /* Hide desktop mission statement */
  .mission-statement {
    display: none;
  }

  /* Hide desktop interactive features */
  .interactive-features {
    display: none;
  }

  /* Mobile Carousel Section — Palantir style */
  .carousel-section-mobile {
    display: block;
    min-height: auto;
    height: auto;
    padding: 2vw 0 4vw;
    background: #f0f0f0;
    position: relative;
    width: 100vw;
    overflow: hidden;
  }

  .carousel-mobile-container {
    position: relative;
    width: 100vw;
    height: auto;
    display: flex;
    flex-direction: column;
    gap: 0;
    cursor: grab;
    user-select: none;
    overflow: visible;
  }

  .carousel-mobile-track {
    position: relative;
    display: flex;
    width: 100%;
    height: auto;
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    will-change: transform;
    gap: 2vw;
    padding: 0;
    margin: 0 auto;
  }

  .carousel-mobile-slide {
    flex: 0 0 90vw;
    width: 90vw;
    height: auto;
    position: relative;
    transition: opacity 0.35s ease, transform 0.35s ease;
    opacity: 1;
    transform: scale(1);
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    gap: 0;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
  }

  .carousel-mobile-slide:active {
    transform: scale(0.98);
  }

  .carousel-mobile-slide.active {
    opacity: 1;
    transform: scale(1);
  }

  .carousel-item {
    width: 100%;
    height: 60vw;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border-radius: 1.5vw;
    position: relative;
    overflow: hidden;
    box-shadow: none;
    order: 1;
    flex-shrink: 0;
  }

  .carousel-item::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
      to bottom,
      rgba(0, 0, 0, 0) 40%,
      rgba(0, 0, 0, 0.15) 100%
    );
  }

  .carousel-mobile-text {
    padding: 0;
    text-align: center;
    display: contents;
  }

  /* Titre au-dessus de la photo - plus foncé */
  .carousel-mobile-text h3 {
    font-size: 4vw;
    font-weight: 500;
    color: #1a1a1a;
    margin: 0;
    padding: 3vw 0 1.5vw;
    letter-spacing: 0;
    order: 0;
    text-align: center;
  }

  /* Sous-titre sous la photo - gris, plus petit */
  .carousel-mobile-subtitle {
    display: block;
    font-size: 3.2vw;
    font-weight: 400;
    color: #999;
    text-align: center;
    padding: 2vw 0 0;
    margin: 0;
    order: 2;
    letter-spacing: 0.02em;
  }

  .carousel-mobile-text p {
    font-size: 3.5vw;
    color: #1a1a1a;
    line-height: 1.35;
    max-width: 100%;
    margin: 0;
    padding: 1.5vw 0 0;
    font-weight: 600;
    order: 3;
    text-align: center;
  }

  .carousel-mobile-text p::after {
    content: " →";
    color: #1a1a1a;
  }

  /* Bouton - même rondeur que les photos (border-radius: 1.5vw) */
  .carousel-mobile-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    color: #704ab5;
    padding: 1.5vw 4vw;
    border-radius: 0.7vw;
    border: 0.25vw solid #1a1a1a;
    text-decoration: none;
    font-weight: 700;
    font-size: 3vw;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    transition: all 0.3s ease;
    margin: 5vw auto 0;
    width: fit-content;
    text-align: center;
    box-shadow: none;
    order: 5;
  }

  /* Pagination dots for carousel */
  .carousel-dots {
    display: none;
  }

  .carousel-dot {
    width: 1.5vw;
    height: 1.5vw;
    min-width: 0.375rem;
    min-height: 0.375rem;
    border-radius: 50%;
    background: #d0d0d0;
    transition: all 0.3s ease;
    cursor: pointer;
    opacity: 0.6;
  }

  .carousel-dot.active {
    width: 5vw;
    height: 1.5vw;
    min-width: 1.25rem;
    min-height: 0.375rem;
    border-radius: 0.75vw;
    background: #999;
    opacity: 1;
  }

  .see-all-button-mobile {
    align-items: center;
    justify-content: center;
    background: transparent;
    color: #1a1a1a;
    padding: 2.5vw 7vw;
    border-radius: 6vw;
    border: 0.25vw solid #1a1a1a;
    text-decoration: none;
    font-weight: 500;
    font-size: 3.2vw;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    transition: all 0.3s ease;
    position: relative;
    margin: 8vw auto 0;
    display: block;
    width: fit-content;
    min-width: 0;
    text-align: center;
    box-shadow: none;
  }

  .see-all-button-mobile:hover {
    background: #1a1a1a;
    color: #fff;
    box-shadow: none;
  }

  /* Hide the arrow SVG in the button */
  .see-all-button-mobile svg {
    display: none;
  }

  /* Carousel navigation arrows — hidden in Palantir style (swipe only) */
  .carousel-arrow {
    display: none;
  }

  /* Mobile Mission Statement */
  .mission-statement-mobile {
    padding: 10vw 4vw;
    background-color: #fff;
    max-width: 100vw;
    overflow: hidden;
    min-height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .mission-text-mobile {
    font-size: 4.7vw;
    font-weight: 600;
    line-height: 1.15;
    text-align: center;
    color: #444;
    max-width: 100%;
    margin: 0 auto;
    letter-spacing: -0.02em;
    -webkit-font-smoothing: auto;
    -moz-osx-font-smoothing: auto;
  }

  .mission-text-mobile br {
    display: block;
    content: "";
    margin-top: 2vw;
  }

  .mission-text-mobile .ai-driven {
    color: #bbb;
    font-weight: inherit;
    font-size: inherit;
    line-height: inherit;
    position: relative;
    display: inline;
  }

  .mission-text-mobile .ai-driven::after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: #fff;
    animation: none;
  }

  .mission-text-mobile .ai-driven.typing::after {
    animation: revealTextMobile 0.8s steps(17, end) forwards;
  }

  .mission-text-mobile .four-pillar {
    color: #999;
    font-weight: inherit;
    font-size: inherit;
    line-height: inherit;
    position: relative;
    display: inline;
  }

  .mission-text-mobile .four-pillar::after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: #fff;
    animation: none;
  }

  .mission-text-mobile .four-pillar.typing::after {
    animation: revealTextMobile 1s steps(20, end) forwards;
  }

  @keyframes revealTextMobile {
    from {
      left: 0;
    }
    to {
      left: 100%;
    }
  }

  /* Mobile Interactive Features */
  .interactive-features-mobile {
    display: block;
    background-color: #fff;
    padding: 0 0 1rem;
  }

  /* Mobile Features Title */
  .features-title-mobile {
    font-size: 4.5vw;
    font-weight: 400;
    color: #444;
    margin: 0 4vw;
    padding: 3vw 0 4vw;
    border-bottom: 0.25vw solid #e0e0e0;
  }

  .features-title-text-mobile {
    position: relative;
    display: inline;
  }

  .features-title-text-mobile::after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: #fff;
    animation: none;
  }

  .features-title-text-mobile.typing::after {
    animation: revealText 0.8s steps(14, end) forwards;
  }

  .features-mobile-container {
    padding: 0 4vw;
  }

  .feature-mobile-item {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    padding: 3vw 4vw 4vw 0;
    border-bottom: 0.25vw solid #f0f0f0;
    text-decoration: none;
    color: inherit;
    transition: background 0.3s ease;
    position: relative;
    touch-action: pan-y;
    -webkit-user-select: none;
    user-select: none;
  }

  /* Visual hint for swipe */
  .feature-mobile-item::before {
    content: "";
    position: absolute;
    left: -100%;
    top: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
      90deg,
      transparent 0%,
      rgba(0, 0, 0, 0.02) 100%
    );
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
  }

  .feature-mobile-item:active::before {
    opacity: 1;
  }

  .feature-mobile-item:first-child {
    border-top: none;
  }

  .feature-mobile-item:last-child {
    border-bottom: none;
  }

  .feature-mobile-item:hover {
    background: transparent;
  }

  .feature-mobile-title {
    font-size: 15vw;
    font-weight: 600;
    color: #1a1a1a;
    margin-top: 0;
    margin-bottom: 0.5vw;
    letter-spacing: -0.02em;
    line-height: 0.85;
    flex: 1;
    order: 1;
  }

  /* Letter by letter typing animation */
  .features-title-mobile .letter,
  .feature-mobile-title .letter {
    opacity: 0;
    display: inline-block;
  }

  .features-title-mobile.typing .letter,
  .feature-mobile-title.typing .letter {
    animation: letterAppear 0.06s ease forwards;
  }

  @keyframes letterAppear {
    from {
      opacity: 0;
    }
    to {
      opacity: 1;
    }
  }

  .feature-mobile-description {
    font-size: 3.8vw;
    line-height: 1.25;
    color: #444;
    font-weight: 600;
    margin-top: 5vw;
    margin-bottom: 2vw;
    width: 100%;
    order: 3;
  }

  .feature-mobile-number {
    font-size: 3vw;
    color: #999;
    font-weight: 500;
    order: 2;
    line-height: 1;
    margin-top: 0;
  }

  /* Adjust other mobile-specific elements */
  .hero {
    margin-top: 0;
    height: 100vh;
    min-height: 100vh;
  }

  .hero-title {
    font-size: 6.8vw !important;
    white-space: nowrap;
  }

  .hero-subtitle {
    font-size: 4vw;
  }

  .build-section {
    padding: 2vw 4vw;
    background-color: #ececec;
  }

  .build-section .container {
    padding: 0;
    max-width: 100%;
  }

  .build-content {
    flex-direction: column;
    gap: 13vw;
    align-items: stretch;
  }

  .build-image {
    width: 100%;
    height: 90vw;
    min-height: 60vw;
    max-height: 60vw;
    max-width: 100%;
    border-radius: 2vw;
    overflow: hidden;
  }

  .build-image img {
    width: 100%;
    height: 90vw;
    object-fit: cover;
  }

  .build-text {
    height: 72vw;
    min-height: 72vw;
    max-height: 72vw;
    padding: 10vw;
    text-align: center;
    max-width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2vw;
    background-color: #f9f9f9;
    border-radius: 2vw;
  }

  .build-text h2 {
    font-size: 6.25vw !important;
    margin: 0 0 1vw;
    line-height: 1.2;
    font-weight: 450;
  }


  .build-text p {
    font-size: 3.7vw !important;
    line-height: 1.35;
    margin: 0 0 0.5vw;
    color: #555;
  }

  .build-text p.build-text-mobile-only {
    margin-bottom: 5vw;
  }

  .build-section .build-text .learn-more-btn,
  .build-text a.learn-more-btn,
  a.learn-more-btn,
  .learn-more-btn {
    margin-top: 4vw;
    padding: 6px 12px;
    font-size: 0.91rem;
    border-radius: 4px;
    display: inline-block;
    min-width: auto;
    width: auto;
    color: #3e3e3e;
    border-color: #787878;
  }

  /* Hide desktop testimonials on mobile */
  .testimonials-section {
    display: none;
  }

  /* Mobile Testimonials Section - Complete Rework */
  .testimonials-section-mobile {
    display: block;
    padding: 6vw 0;
    background: #fff;
    overflow: hidden;
  }

  .testimonials-mobile-title {
    font-size: 7vw;
    font-weight: 400;
    text-align: left;
    color: #1a1a1a;
    margin: 0 0 6vw;
    padding: 0 4vw;
    line-height: 1.35;
    display: block;
  }

  .testimonials-mobile-title .line1,
  .testimonials-mobile-title .line2 {
    display: block;
    position: relative;
    overflow: hidden;
    width: fit-content;
  }

  .testimonials-mobile-title .line1 {
    margin-bottom: 1.2vw;
  }

  .testimonials-mobile-title .line1::after,
  .testimonials-mobile-title .line2::after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: #fff;
    transform: translateX(0);
    animation: none;
    will-change: transform;
  }

  .testimonials-mobile-title.typing .line1::after {
    animation: revealText1 0.5s linear forwards;
  }

  .testimonials-mobile-title.typing .line2::after {
    animation: revealText2 0.4s linear 0.5s forwards;
  }

  @keyframes revealText1 {
    0% {
      transform: translateX(0);
    }
    100% {
      transform: translateX(100%);
    }
  }

  @keyframes revealText2 {
    0% {
      transform: translateX(0);
    }
    100% {
      transform: translateX(100%);
    }
  }

  .testimonials-mobile-container {
    position: relative;
    width: 100%;
    padding: 0 3vw;
  }

  .testimonials-mobile-track {
    position: relative;
    width: 100%;
    overflow: visible;
  }

  .testimonial-mobile-slide {
    display: none;
    width: 100%;
    position: static;
    opacity: 1;
    padding: 0;
    margin: 0;
  }

  .testimonial-mobile-slide.active {
    display: block;
  }

  /* Reset any inherited styles */
  .testimonial-mobile-slide * {
    position: static;
    transform: none;
    opacity: 1;
    text-indent: 0;
  }

  .testimonial-mobile-card {
    background: #fff;
    border: 0.25vw solid #e0e0e0;
    border-radius: 3vw;
    padding: 5vw 4vw;
    width: 100%;
    box-shadow: 0 0.25vw 0.75vw rgba(0, 0, 0, 0.1);
    display: block;
    min-height: 75vw;
  }

  .testimonial-mobile-card .company-name {
    font-size: 3vw;
    font-weight: 700;
    letter-spacing: 0.1em;
    color: #666;
    text-transform: uppercase;
    margin: 0 0 4vw;
    padding: 0 0 0 2.5vw;
    display: block;
    clear: both;
    text-align: left;
    /* Override desktop styles (styles.css sets position:absolute for hover card layout) */
    position: static;
    top: auto;
    left: auto;
    right: auto;
  }

  .testimonial-mobile-card .testimonial-text {
    font-size: 4vw;
    line-height: 1.65;
    color: #1a1a1a;
    margin: 0 0 4vw;
    padding: 0 2.5vw;
    display: block;
    position: static;
    clear: both;
    text-align: left;
    text-indent: 0;
    left: auto;
    transform: none;
  }

  /* Remove any quote decoration */
  .testimonial-mobile-card .testimonial-text::before,
  .testimonial-mobile-card .testimonial-text::after {
    display: none;
    content: none;
  }

  .testimonial-mobile-card .testimonial-author {
    border-top: 0.25vw solid #f0f0f0;
    padding: 2.5vw 2.5vw 0;
    margin: 0;
    display: block;
    clear: both;
    /* Override desktop styles (styles.css sets opacity:0 + absolute for hover effect) */
    opacity: 1;
    position: static;
    transform: none;
  }

  .testimonial-mobile-card .author-name {
    font-size: 3.6vw;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 0.75vw;
    padding: 0;
    display: block;
  }

  .testimonial-mobile-card .author-title {
    font-size: 3.2vw;
    color: #666;
    line-height: 1.4;
    margin: 0;
    padding: 0;
    display: block;
  }

  /* Dots indicator */
  .testimonials-mobile-dots {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1vw;
    margin-top: 4vw;
    padding: 1.25vw;
  }

  .testimonials-mobile-dots .dot {
    width: 1.5vw;
    height: 1.5vw;
    border-radius: 50%;
    background: #d0d0d0;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    padding: 0;
  }

  .testimonials-mobile-dots .dot.active {
    background: #333;
    width: 5vw;
    height: 1.5vw;
    border-radius: 0.75vw;
  }

  .testimonials-title {
    font-size: 7vw;
    padding: 0 4vw;
  }

  .testimonial-card {
    min-width: 85vw;
  }

  /* CTA section mobile */
  .cta-section {
    padding: 8vw 0;
  }

  .cta-buttons {
    flex-direction: column;
    gap: 2.5vw;
  }

  .cta-box {
    width: 100%;
    padding: 4vw 4vw 4vw 3vw;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    border-radius: 1vw;
  }

  .cta-text {
    font-weight: 400;
    font-size: 6.5vw !important;
    text-align: left;
    letter-spacing: -0.05em;
    line-height: 1.1;
  }

  .cta-arrow {
    position: absolute;
    right: 3vw;
    top: 50%;
    transform: translateY(-50%);
    font-size: 8vw;
  }

  /* Footer mobile */
  .footer {
    padding: 6vw 4.5vw;
  }

  .footer-content {
    flex-direction: column;
    gap: 3vw;
    text-align: center;
  }

  /* Floating contact button at bottom right - meme hauteur que nav-icon-button (44px) */
  .mobile-contact-button {
    position: fixed;
    bottom: 5vw;
    right: 5vw;
    background-color: #fff;
    color: #000;
    height: 44px;
    padding: 0 3.5vw;
    border-radius: 0;
    text-decoration: none;
    font-size: 3.4vw;
    font-weight: 600;
    box-shadow: 0 1vw 3vw rgba(0, 0, 0, 0.25);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    border: 0.25vw solid #000;
  }

  .mobile-contact-button:hover {
    background-color: #f5f5f5;
    box-shadow: 0 1.5vw 4vw rgba(0, 0, 0, 0.35);
    transform: translateY(-0.5vw);
  }

  .mobile-contact-button:active {
    transform: translateY(0);
  }
}

/* Ensure desktop sections are visible on larger screens */
@media screen and (min-width: 768px) {
  .carousel-section-mobile,
  .mission-statement-mobile,
  .interactive-features-mobile,
  .testimonials-section-mobile,
  .mobile-contact-button,
  .mobile-floating-nav {
    display: none;
  }

  .carousel-section,
  .mission-statement,
  .interactive-features {
    display: block;
  }
}

/* Adjustments for larger phones (iPhone Pro Max, etc.) */
@media screen and (min-width: 414px) and (max-width: 767px) {
  .carousel-mobile-slide {
    flex: 0 0 90vw;
    width: 90vw;
  }
}

/* Extra small screens (below 375px) - ensure proper calendar padding */
@media screen and (max-width: 374px) {
  .calendar-popup-overlay {
    padding: 1vw;
  }

  .calendar-popup {
    max-width: calc(100vw - 2vw);
    width: calc(100vw - 2vw);
  }

  .calendar-popup .popup-content {
    padding: 1vw;
  }

  .calendar-container {
    padding: 0.5vw;
  }

  .calendar-weekdays div {
    font-size: 2.2vw;
    padding: 0.5vw 0;
  }

  .calendar-day {
    font-size: 2.8vw;
    padding: 0.8vw;
  }
}

/* Phone-specific optimizations for very small screens */
@media screen and (max-width: 375px) {
  .hero-title {
    font-size: 6.2vw !important;
  }

  .mission-text-mobile {
    font-size: 1.5rem;
  }

  .feature-mobile-title {
    font-size: 2rem;
  }

  .carousel-mobile-text h3 {
    font-size: 1.25rem;
  }

  .carousel-mobile-text p {
    font-size: 0.875rem;
  }
}

/* Landscape phone orientation adjustments */
@media screen and (max-width: 767px) and (orientation: landscape) {
  .carousel-section-mobile {
    height: auto;
    min-height: 100vh;
  }

  .carousel-mobile-track {
    height: 50vh;
  }

  .hero {
    min-height: 100vh;
    height: 100vh;
  }
}

/* ===== MOBILE MENU OVERLAY ===== */
@media screen and (max-width: 767px) {
  /* Full-screen overlay */
  .menu-overlay {
    background: #0a0a0a;
    display: flex;
    flex-direction: column;
  }

  .menu-overlay.active {
    display: flex;
  }

  /* Close button - top right */
  .mobile-close-btn {
    position: fixed !important;
    top: 4vw !important;
    right: 5vw !important;
    left: auto !important;
    width: 44px !important;
    height: 44px !important;
    font-size: 1.1rem !important;
    background: rgba(255, 255, 255, 0.08) !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    border-radius: 50% !important;
    color: rgba(255, 255, 255, 0.7) !important;
    z-index: 10001 !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    transition: background 0.3s ease, transform 0.2s ease;
  }

  .mobile-close-btn:active {
    transform: scale(0.9);
    background: rgba(255, 255, 255, 0.15) !important;
  }

  /* Container - vertical layout, overlay handles scroll */
  .menu-container {
    display: flex !important;
    flex-direction: column !important;
    padding: 16vw 6vw 30vw !important;
    gap: 8vw !important;
    overflow-y: visible !important;
  }

  /* Hide section labels and dividers on mobile */
  .menu-container .menu-divider,
  .menu-container .menu-label,
  .menu-container .menu-header {
    display: none !important;
  }

  /* ---- MOBILE MENU SECTION ORDER ---- */
  /* 1. Nav, 2. News, 3. Case Study, 4. Solutions, 5. Quick Links */
  .menu-col-nav { order: 1 !important; }
  .menu-col-news { order: 2 !important; }
  .menu-col-case { order: 3 !important; }
  .menu-col-solutions { order: 4 !important; }
  .menu-col-links { order: 5 !important; }

  /* ---- NAVIGATION ---- */
  .menu-col-nav {
    padding: 0 !important;
    margin-bottom: 2vw;
  }

  .menu-col-nav .menu-divider {
    margin-bottom: 4vw;
    height: 1px;
    background: linear-gradient(90deg, rgba(255,255,255,0.2), rgba(255,255,255,0.05)) !important;
  }

  .menu-col-nav .menu-label {
    font-size: 2.6vw !important;
    letter-spacing: 0.2em;
    color: rgba(255, 255, 255, 0.3);
    margin-bottom: 5vw !important;
    text-transform: uppercase;
  }

  .menu-nav {
    gap: 0 !important;
  }

  .menu-nav-item {
    padding: 3.5vw 0 !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: padding-left 0.3s ease !important;
  }

  .menu-nav-item:active {
    padding-left: 2vw !important;
  }

  .menu-nav-main {
    font-size: 8vw !important;
    font-weight: 300 !important;
    letter-spacing: -0.03em;
    line-height: 1.3;
    color: #fff !important;
  }

  .menu-nav-sub {
    font-size: 4.5vw !important;
    padding-left: 4vw !important;
    color: rgba(255, 255, 255, 0.45) !important;
    font-weight: 300 !important;
  }

  .menu-arrow {
    margin-right: 2vw;
    font-size: 3.5vw;
    color: rgba(255, 255, 255, 0.2);
  }

  /* ---- DROPDOWN NAVIGATION ---- */
  .menu-nav-dropdown {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  }

  .menu-dropdown-toggle {
    width: 100%;
    background: none;
    border: none;
    border-bottom: none !important;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    padding: 3.5vw 0 !important;
  }

  .menu-dropdown-arrow {
    font-size: 6vw;
    font-weight: 200;
    color: rgba(255, 255, 255, 0.4);
    transition: transform 0.3s ease;
  }

  .menu-nav-dropdown.open .menu-dropdown-arrow {
    transform: rotate(45deg);
  }

  .menu-dropdown-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
  }

  .menu-nav-dropdown.open .menu-dropdown-content {
    max-height: 50vh;
  }

  .menu-dropdown-content .menu-nav-sub {
    border-bottom: none !important;
  }

  /* ---- RIGHT CONTENT WRAPPER ---- */
  /* Flatten nested structure so all sections are direct children of menu-container for ordering */
  .menu-right-content,
  .menu-top-row,
  .menu-bottom-row {
    display: contents !important;
  }

  /* ---- NEWS SECTION - Show with images ---- */
  .menu-col-news {
    display: block !important;
    padding: 0 !important;
  }

  .menu-col-news .menu-divider {
    height: 1px;
    background: linear-gradient(90deg, rgba(255,255,255,0.2), rgba(255,255,255,0.05)) !important;
    margin-bottom: 3vw !important;
  }

  .menu-col-news .menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4vw;
  }

  .menu-col-news .menu-label {
    font-size: 2.6vw !important;
    letter-spacing: 0.2em;
    color: rgba(255, 255, 255, 0.3);
    text-transform: uppercase;
  }

  .menu-news-grid {
    display: flex !important;
    flex-direction: row !important;
    gap: 3vw !important;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
    padding-bottom: 2vw;
  }

  .menu-news-grid::-webkit-scrollbar {
    display: none;
  }

  .menu-news-item {
    flex: 0 0 42vw !important;
    scroll-snap-align: start;
    background: rgba(255, 255, 255, 0.04) !important;
    border-radius: 3vw !important;
    overflow: hidden;
    text-decoration: none !important;
    border: 1px solid rgba(255, 255, 255, 0.06);
    transition: transform 0.2s ease, border-color 0.3s ease;
    padding: 0 !important;
    display: flex !important;
    flex-direction: column !important;
  }

  .menu-news-item:active {
    transform: scale(0.97);
    border-color: rgba(255, 255, 255, 0.15);
  }

  .menu-news-source {
    display: block;
    padding: 3vw 3.5vw 1.5vw !important;
    font-size: 2.2vw !important;
    letter-spacing: 0.1em;
    color: rgba(255, 255, 255, 0.3) !important;
    text-transform: uppercase;
  }

  .menu-news-image {
    display: block !important;
    width: 100% !important;
    height: 28vw !important;
    background-size: cover !important;
    background-position: center !important;
    margin: 0 !important;
    border-radius: 0 !important;
  }

  .menu-news-item h4 {
    font-size: 3.8vw !important;
    font-weight: 500 !important;
    color: #fff !important;
    padding: 3vw 3.5vw 1vw !important;
    margin: 0 !important;
    line-height: 1.3;
    white-space: nowrap;
  }

  .menu-news-item p {
    font-size: 2.8vw !important;
    color: rgba(255, 255, 255, 0.45) !important;
    padding: 0 3.5vw 2vw !important;
    margin: 0 !important;
    line-height: 1.4 !important;
    display: block !important;
    -webkit-line-clamp: unset !important;
    overflow: visible !important;
  }

  .menu-news-link {
    display: block;
    margin-top: auto !important;
    padding: 2vw 3.5vw 3.5vw !important;
    font-size: 2.6vw !important;
    color: rgba(255, 255, 255, 0.35) !important;
    letter-spacing: 0.05em;
  }

  /* ---- CASE STUDY - Show with featured image ---- */
  .menu-col-case {
    display: block !important;
    padding: 0 !important;
  }

  .menu-col-case .menu-divider {
    height: 1px;
    background: linear-gradient(90deg, rgba(255,255,255,0.2), rgba(255,255,255,0.05)) !important;
    margin-bottom: 3vw !important;
  }

  .menu-col-case .menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4vw;
  }

  .menu-col-case .menu-label {
    font-size: 2.6vw !important;
    letter-spacing: 0.2em;
    color: rgba(255, 255, 255, 0.3);
    text-transform: uppercase;
  }

  .menu-case-study {
    display: block !important;
    border-radius: 3vw !important;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.06);
    background: rgba(255, 255, 255, 0.04);
    transition: transform 0.2s ease;
  }

  .menu-case-study:active {
    transform: scale(0.98);
  }

  .menu-case-label {
    display: block;
    padding: 3vw 4vw 2vw !important;
    font-size: 2.2vw !important;
    letter-spacing: 0.1em;
    color: rgba(255, 255, 255, 0.3) !important;
    text-transform: uppercase;
  }

  .menu-case-image {
    width: 100% !important;
    height: 40vw !important;
    background-size: cover !important;
    background-position: center !important;
    border-radius: 0 !important;
  }

  /* ---- SOLUTIONS ---- */
  .menu-col-solutions {
    padding: 0 !important;
    margin-top: -6vw !important;
  }

  .menu-col-solutions .menu-divider {
    height: 1px;
    background: linear-gradient(90deg, rgba(255,255,255,0.2), rgba(255,255,255,0.05)) !important;
    margin-bottom: 3vw;
  }

  .menu-col-solutions .menu-label {
    font-size: 2.6vw !important;
    letter-spacing: 0.2em;
    color: rgba(255, 255, 255, 0.3);
    margin-bottom: 3vw !important;
    text-transform: uppercase;
  }

  .menu-solutions-desc {
    font-size: 3.5vw !important;
    line-height: 1.6 !important;
    color: rgba(255, 255, 255, 0.5) !important;
    margin-bottom: 3vw;
  }

  .menu-solutions-link {
    display: inline-block;
    font-size: 3.2vw !important;
    color: rgba(255, 255, 255, 0.7) !important;
    padding: 2vw 4vw !important;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 6vw;
    transition: background 0.3s ease, border-color 0.3s ease;
  }

  .menu-solutions-link:active {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.3);
  }

  /* ---- QUICK LINKS ---- */
  .menu-col-links {
    padding: 0 !important;
  }

  .menu-col-links .menu-divider {
    height: 1px;
    background: linear-gradient(90deg, rgba(255,255,255,0.2), rgba(255,255,255,0.05)) !important;
    margin-bottom: 3vw;
  }

  .menu-col-links .menu-label {
    font-size: 2.6vw !important;
    letter-spacing: 0.2em;
    color: rgba(255, 255, 255, 0.3);
    margin-bottom: 4vw !important;
    text-transform: uppercase;
  }

  .menu-quick-links {
    display: grid !important;
    grid-template-columns: 1fr 1fr;
    gap: 1vw 4vw !important;
  }

  .menu-quick-links a {
    font-size: 3.3vw !important;
    color: rgba(255, 255, 255, 0.5) !important;
    padding: 2.5vw 0 !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    transition: color 0.2s ease;
  }

  .menu-quick-links a:active {
    color: rgba(255, 255, 255, 0.9) !important;
  }

  /* ---- SHARED SECTION STYLES ---- */
  .menu-header {
    margin-bottom: 3vw;
  }

  .menu-view-all {
    font-size: 2.6vw !important;
    color: rgba(255, 255, 255, 0.25) !important;
    letter-spacing: 0.05em;
  }

  .menu-divider {
    background: rgba(255, 255, 255, 0.08) !important;
    margin-bottom: 3vw !important;
  }

  /* Column animation - staggered entrance */
  .menu-column {
    transition: opacity 0.4s ease, transform 0.4s ease !important;
  }
}

/* ===== BUILD SECTION SPACING OVERRIDE - MUST BE LAST ===== */
/* Override all previous build-text spacing rules */
@media screen and (max-width: 767px) {
  .build-section .build-text,
  section.build-section .build-text {
    gap: 0;
    padding: 10.3vw 6vw !important;
  }

  .build-section .build-text h2,
  section.build-section .build-text h2 {
    margin: 0;
    margin-bottom: 6.6vw;
    padding: 0;
    line-height: 1.05;
  }

  .build-section .build-text p,
  section.build-section .build-text p {
    margin: 0;
    margin-bottom: 6.6vw;
    padding: 0 2vw;
    line-height: 1.15;
  }

  .build-section .build-text .learn-more-btn,
  .build-section .build-text a.learn-more-btn,
  .build-section .build-text a {
    margin: 0;
    margin-top: 0;
  }
}
