@tailwind base;
@tailwind components;
@tailwind utilities;
@plugin "daisyui";

:root {
    /* Palette projet (valeurs deja definies dans le theme actuel) */
    --vp-primary: #061B70;
    --vp-secondary: #ffc300;
    --vp-accent: #FFFCF9;
    --vp-accent-content: #81667A;
    --vp-base-100: #ffffff;
    --vp-base-200: #f8f9fa;
    --vp-base-300: #e9ecef;
    --vp-base-content: #1f2937;

    /* Alias de nommage */
    --vp-color-bleu: var(--vp-primary);
    --vp-color-rouge: var(--vp-secondary);

    /* Transition */
    --vp-transition-fast: 0.35s cubic-bezier(0.4, 0, 0.2, 1);

    /* Bootstrap (uniquement sur couleurs existantes) */
    --bs-primary: var(--vp-primary);
    --bs-primary-rgb: 6, 27, 112;
    --bs-secondary: var(--vp-secondary);
    --bs-secondary-rgb: 255, 195, 0;
    --bs-light: var(--vp-base-200);
    --bs-light-rgb: 248, 249, 250;
    --bs-dark: var(--vp-base-content);
    --bs-dark-rgb: 31, 41, 55;
    --bs-body-color: var(--vp-base-content);
    --bs-body-bg: var(--vp-base-100);

    /* Tailwind / DaisyUI */
    --color-primary: var(--vp-primary);
    --color-primary-content: #FFFFFF;
    --color-secondary: var(--vp-secondary);
    --color-accent: var(--vp-accent);
    --color-accent-content: var(--vp-accent-content);
    --color-base-100: var(--vp-base-100);
    --color-base-200: var(--vp-base-200);
    --color-base-300: var(--vp-base-300);
    --color-base-content: var(--vp-base-content);
    --color-secondary-content: var(--color-base-content);
    color-scheme: light;

    /* Couleur de theme RGB (hero/overlays) */
    --vp-color-theme-rgb: 6 27 112;
}


@layer base {

  h1, h2, h3, button {
    font-family: "Archivo", system-ui, sans-serif;
  }

  html {
    font-family: "Inter", system-ui, sans-serif;
  }

  .kristi-font {
    font-family: "Kristi", cursive;
    font-weight: 400;
  }

  /* Hero home : grille 1fr/auto/1fr → titre centré verticalement sans bouger à l’ouverture */
  .hero-title-col {
    width: 100%;
    container-type: inline-size;
    container-name: hero-title;
  }

  .hero-notif-slot {
    display: none;
  }

  @media (width >= 1500px) {
    .hero-page--with-video {
      align-items: stretch;
      justify-items: stretch;
    }

    .hero-home-content.hero-content {
      align-self: stretch;
      width: 100%;
      max-width: none;
      display: flex;
    }

    .hero-home-container {
      display: grid;
      grid-template-columns: minmax(0, 1fr) 28rem;
      grid-template-rows: 1fr auto 1fr;
      column-gap: 3rem;
      width: 100%;
      min-height: 70vh;
      align-items: start;
    }

    .hero-title-col {
      grid-column: 1;
      grid-row: 2;
    }

    /* Fermée : même rangée que le titre (alignée en haut avec lui) */
    .hero-notif-slot {
      display: block;
      grid-column: 2;
      grid-row: 2;
      align-self: start;
      width: 28rem;
      z-index: 5;
    }

    /* Ouverte : occupe toute la hauteur du hero et se recentre ; le titre reste en row 2 */
    .hero-notif-slot:has(.hero-notif-card.is-expanded) {
      grid-row: 1 / -1;
      align-self: stretch;
      display: flex;
      align-items: center;
    }
  }

  /* Script : une ligne sur desktop ; deux lignes sur mobile.
     Padding + clip-path élargi : Kristi déborde de la boîte (trait final du n). */
  .hero-script-title {
    display: block;
    font-size: clamp(3.75rem, 8.6cqi, 7.5rem);
    line-height: 0.92;
    letter-spacing: 0.01em;
    padding-block: 0.18em 0.28em;
    padding-inline: 0.08em 0.45em;
    white-space: nowrap;
    max-width: 100%;
    overflow: visible;
  }

  .hero-script-title-line + .hero-script-title-line::before {
    content: "\00a0";
  }

  @media (max-width: 639px) {
    .hero-script-title {
      white-space: normal;
      line-height: 1.08;
      font-size: clamp(2.75rem, 14vw, 3.75rem);
    }

    .hero-script-title-line {
      display: block;
    }

    .hero-script-title-line + .hero-script-title-line::before {
      content: none;
    }
  }

  /* Fallback si pas de container queries */
  @supports not (font-size: 1cqi) {
    .hero-script-title {
      font-size: clamp(3.75rem, 9vw, 7.5rem);
    }
  }

  /* Correction pour Safari - poids de police en gras plus léger */
  * {
    font-synthesis: none !important;
  }
   
}

.ph {
    font-size: 1.25rem;
    line-height: 1;
}

/* Styles supprimés au profit de Tailwind/DaisyUI */

/* Animations modernes pour la page d'accueil */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes slideInFromTop {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
}

@keyframes glow {
    0%, 100% {
        box-shadow: 0 0 5px rgba(59, 130, 246, 0.5);
    }
    50% {
        box-shadow: 0 0 20px rgba(59, 130, 246, 0.8);
    }
}

/* Classes d'animation */
.animate-fade-in-up {
    animation: fadeInUp 2.0s ease-out forwards;
    opacity: 0;
}


.animate-slide-in-top {
    animation: slideInFromTop 2.0s ease-out forwards;
    opacity: 0;
}

/* Animation d'écriture pour texte caligraphique */
@keyframes writeText {
    0% {
        clip-path: polygon(0 0, 0 0, 0 100%, 0 100%);
        opacity: 0;
    }
    1% {
        opacity: 1;
    }
    100% {
        clip-path: polygon(-10% -45%, 115% -45%, 115% 145%, -10% 145%);
        opacity: 1;
    }
}

.animate-write-text {
    clip-path: polygon(0 0, 0 0, 0 100%, 0 100%);
    opacity: 0;
    animation: writeText 3s cubic-bezier(0.4, 0, 0.2, 1) 0.8s both;
}

.animate-pulse-slow {
    animation: pulse 2s infinite;
}

/* Indication de clic souris (carte notifications hero) */
@keyframes notif-click-move {
    0%, 100% {
        transform: translate(0, 0) scale(1);
    }
    35% {
        transform: translate(-2px, 3px) scale(0.92);
    }
    50% {
        transform: translate(-2px, 3px) scale(0.92);
    }
    70% {
        transform: translate(0, 0) scale(1);
    }
}

@keyframes notif-click-ripple {
    0%, 20% {
        transform: scale(0.4);
        opacity: 0;
    }
    35% {
        opacity: 0.55;
    }
    70%, 100% {
        transform: scale(1.6);
        opacity: 0;
    }
}

.notif-click-hint {
    pointer-events: none;
    position: absolute;
    right: -1.2rem;
    bottom: -0.55rem;
    width: 1.75rem;
    height: 1.75rem;
    z-index: 2;
}

.notif-click-hint__ripple {
    position: absolute;
    left: -0.3rem;
    top: 0.1rem;
    width: 0.95rem;
    height: 0.95rem;
    border-radius: 9999px;
    background: color-mix(in srgb, var(--vp-primary) 35%, transparent);
    animation: notif-click-ripple 1.8s ease-out infinite;
}

.notif-click-hint__cursor {
    position: absolute;
    inset: 0;
    color: var(--vp-primary);
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.18));
    animation: notif-click-move 1.8s ease-in-out infinite;
}

/* Animation check succès abonnement notifications */
@keyframes notif-check-pop {
    0% {
        transform: scale(0.4);
        opacity: 0;
    }
    55% {
        transform: scale(1.12);
        opacity: 1;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.notif-check-pop {
    display: inline-block;
    animation: notif-check-pop 0.45s cubic-bezier(0.34, 1.45, 0.64, 1) forwards;
}

/* Délais d'animation */
.delay-100 {
    animation-delay: 0.1s;
}

.delay-200 {
    animation-delay: 0.2s;
}

.delay-300 {
    animation-delay: 0.3s;
}

.delay-600 {
    animation-delay: 0.6s;
}

/* Effets de survol */
.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.hover-glow {
    transition: box-shadow 0.3s ease;
}

.hover-glow:hover {
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.4);
}

@layer components {
  /* Éditeur WYSIWYG : hauteur fixe, contenu défilant à l'intérieur */
  .wysiwyg-editor-container {
    @apply h-96 overflow-hidden;
    display: flex;
    flex-direction: column;
  }

  .wysiwyg-editor-container .ql-toolbar.ql-snow {
    flex-shrink: 0;
  }

  .wysiwyg-editor-container .ql-container.ql-snow {
    flex: 1 1 auto;
    min-height: 0;
    height: auto !important;
    overflow: hidden;
  }

  .wysiwyg-editor-container .ql-editor {
    height: 100%;
    overflow-y: auto;
  }

  /* Hover de carte harmonise (inspire ServicesEquipmentSection) */
  .hover-feature-card {
      @apply transition-all duration-300 border border-transparent;
  }

  .hover-feature-card:hover {
      @apply bg-base-200 border-primary/20;
  }

  .hover-feature-card .hover-feature-card-icon {
      @apply transition-all duration-300 shadow-md;
  }

  .group:hover .hover-feature-card .hover-feature-card-icon {
      @apply shadow-lg scale-110;
  }

  .hover-feature-card .hover-feature-card-title {
      @apply transition-colors duration-300;
  }

  .group:hover .hover-feature-card .hover-feature-card-title {
      @apply text-primary/80;
  }

  .hover-feature-card .hover-feature-card-arrow {
      @apply opacity-60 transition-all duration-300;
  }

  .group:hover .hover-feature-card .hover-feature-card-arrow {
      @apply opacity-100 translate-x-1;
  }
}

@keyframes blink-caret {
    from, to {
        border-color: transparent;
    }
    50% {
        border-color: white;
    }
}

/* Animations d'entrée avec intersection observer */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Animation pour les cartes de destination */
.destination-card {
    transition: all 0.3s ease;
    opacity: 0;
    transform: translateY(20px);
}

.destination-card.animate {
    opacity: 1;
    transform: translateY(0);
}

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

/*Fonts*/
.lato-thin {
  font-family: "Lato", sans-serif;
  font-weight: 100;
  font-style: normal;
}

.lato-light {
  font-family: "Lato", sans-serif;
  font-weight: 300;
  font-style: normal;
}

.lato-regular {
  font-family: "Lato", sans-serif;
  font-weight: 400;
  font-style: normal;
}

.lato-bold {
  font-family: "Lato", sans-serif;
  font-weight: 700;
  font-style: normal;
}

.lato-black {
  font-family: "Lato", sans-serif;
  font-weight: 900;
  font-style: normal;
}

.lato-thin-italic {
  font-family: "Lato", sans-serif;
  font-weight: 100;
  font-style: italic;
}

.lato-light-italic {
  font-family: "Lato", sans-serif;
  font-weight: 300;
  font-style: italic;
}

.lato-regular-italic {
  font-family: "Lato", sans-serif;
  font-weight: 400;
  font-style: italic;
}

.lato-bold-italic {
  font-family: "Lato", sans-serif;
  font-weight: 700;
  font-style: italic;
}

.lato-black-italic {
  font-family: "Lato", sans-serif;
  font-weight: 900;
  font-style: italic;
}

.noto-sans-regular {
  font-family: "Noto Sans", sans-serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
  font-variation-settings:
    "wdth" 100;
}

.noto-sans-regular {
  font-family: "Noto Sans", sans-serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
  font-variation-settings:
    "wdth" 100;
}

.montserrat-regular {
  font-family: "Montserrat", sans-serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
}

/* .montserrat-regular {
  font-family: "Montserrat", sans-serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
}

.montserrat-bold {
  font-family: "Montserrat", sans-serif;
  font-weight: 700;
  font-style: normal;
} */

  /* Configuration alert-soft pour les alertes de base */
  /* .alert {
    @layer daisyui.style {
      color: var(--alert-color, var(--color-base-content));
      background: var(--alert-color, var(--color-base-content));
      @supports (color: color-mix(in lab, red, red)) {
        background: color-mix( in oklab, var(--alert-color, var(--color-base-content)) 8%, var(--color-base-100) );
      }
      --alert-border-color: var(--alert-color, var(--color-base-content));
      @supports (color: color-mix(in lab, red, red)) {
        --alert-border-color: color-mix(
          in oklab,
          var(--alert-color, var(--color-base-content)) 10%,
          var(--color-base-100)
        );
      }
      box-shadow: none;
      background-image: none;
    }
  } */

  /* Configuration badge-soft pour les badges de base */
  /* .badge {
    @layer daisyui.style {
      --badge-bg: var(--badge-color, var(--color-base-100));
      @supports (color: color-mix(in lab, red, red)) {
        --badge-bg: color-mix( in oklab, var(--badge-color, var(--color-base-content)) 8%, var(--color-base-100) );
      }
      background-color: var(--badge-bg);
      --badge-border-color: var(--badge-color, var(--color-base-200));
      @supports (color: color-mix(in lab, red, red)) {
        --badge-border-color: color-mix(
          in oklab,
          var(--badge-color, var(--color-base-content)) 10%,
          var(--color-base-100)
        );
      }
      border-color: var(--badge-border-color);
      box-shadow: none;
      background-image: none;
    }
  } */

/* Icônes SVG locales (contrôle sûreté — objets interdits) */
.prohibited-category-icon {
  display: block;
  width: 3rem;
  height: 3rem;
  margin-inline: auto;
  background-color: var(--color-secondary);
  mask-size: contain;
  mask-repeat: no-repeat;
  mask-position: center;
  -webkit-mask-size: contain;
  -webkit-mask-repeat: no-repeat;
  -webkit-mask-position: center;
}

.prohibited-category-icon--gun {
  mask-image: url(/icon/gun-solid-full.svg);
  -webkit-mask-image: url(/icon/gun-solid-full.svg);
}

.prohibited-category-icon--spray-can {
  mask-image: url(/icon/spray-can-solid-full.svg);
  -webkit-mask-image: url(/icon/spray-can-solid-full.svg);
}

/* Hero vidéo : fond sombre + vidéo visible (pas de gate JS opacity) */
.hero-page--with-video {
  background-color: #1c1917;
}

.hero-page--with-video::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image: url("/images/hero-aeroport-poster.jpg");
  background-size: cover;
  background-position: center;
  filter: blur(3px);
  transform: scale(1.02);
}

.hero-page--with-video .hero-overlay,
.hero-page--with-video .hero-content {
  visibility: visible;
  opacity: 1;
}

.hero-page--with-video .hero-page-bg {
  opacity: 1;
}

.hero-home-video.hero-page-bg {
  filter: blur(3px);
  transform: scale(1.02); /* évite les bords flous vides */
}

.hero-home-video::-webkit-media-controls,
.hero-home-video::-webkit-media-controls-enclosure,
.hero-home-video::-webkit-media-controls-overlay-play-button,
.hero-home-video::-webkit-media-controls-start-playback-button {
  display: none !important;
  appearance: none;
  -webkit-appearance: none;
  opacity: 0;
  pointer-events: none;
  width: 0;
  height: 0;
}

.hero-video-toggle {
  display: none;
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  z-index: 20;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  padding: 0;
  border: 0;
  border-radius: 9999px;
  color: #fff;
  background-color: rgba(0, 0, 0, 0.4);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(4px);
  cursor: pointer;
}

.hero-video-toggle:hover,
.hero-video-toggle:focus-visible {
  background-color: rgba(0, 0, 0, 0.55);
}

.hero-video-toggle:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 2px;
}

.hero-video-toggle i {
  margin: 0;
  line-height: 1;
}

.hero-video-toggle [data-hero-video-pause] {
  display: none;
}

.hero-video-toggle.is-playing [data-hero-video-play] {
  display: none;
}

.hero-video-toggle.is-playing [data-hero-video-pause] {
  display: inline;
}

.hero-page--with-video.is-manual-play .hero-video-toggle {
  display: inline-flex;
}

.hero-page--with-video.is-manual-play .hero-home-video.hero-page-bg:not(.is-playing) {
  opacity: 0;
  visibility: hidden;
}

/* Hero accueil — cadrage vidéo décalé à droite sur mobile */
@media (max-width: 767px) {
  .hero-page--with-video::before {
    background-position: 59% center;
  }

  .hero-home-video.hero-page-bg {
    object-position: 59% center;
  }

  .hero-video-toggle {
    display: inline-flex;
  }

  .hero-page--with-video .hero-home-video.hero-page-bg:not(.is-playing) {
    opacity: 0;
    visibility: hidden;
  }
}

/* Footer — titre + flèche en flex (évite le chevauchement type « Professionnels ») */
footer .footer-collapse > .footer-collapse-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding-inline-end: 0.75rem;
}

footer .footer-collapse > .footer-collapse-title > .footer-collapse-label {
  min-width: 0;
  flex: 1 1 auto;
  line-height: 1.25;
  overflow-wrap: normal;
  word-break: keep-all;
  hyphens: none;
}

footer .footer-collapse > .footer-collapse-title > .footer-collapse-caret {
  flex: 0 0 auto;
  font-size: 1rem;
  line-height: 1;
  transition: transform 0.2s ease;
}

footer .footer-collapse:has(> input:checked) > .footer-collapse-title > .footer-collapse-caret {
  transform: rotate(180deg);
}

/* Footer mobile — aligner les collapses avec le reste du contenu */
@media (max-width: 767px) {
  footer .footer-collapse {
    background-color: transparent;
    border-radius: 0;
  }

  footer .footer-collapse > input[type="checkbox"],
  footer .footer-collapse > .footer-collapse-title {
    padding-inline-start: 0;
    padding-block: 0.25rem;
    min-height: unset;
  }

  footer .footer-collapse > .collapse-content {
    padding-inline: 0;
    padding-bottom: 0.5rem;
  }
}

