/*
 Theme Name:   Hello World !
 Description:  A child theme from Html5blank
 Author:       César for ___
 Template:     html5blank-stable
 Version:      1.0.0
*/

:root{
  /* Font stacks */
  --font-body: "Rubik", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  --font-title: "Rubik", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  --lh-body: 1.6;
  --lh-title: 1.1;
  --wp--preset--font-size--medium: 1rem;
}






/* =========================================
   GLOBAL: full-width + dark
========================================= */

html, body {
  margin: 0;
  padding: 0;
  background: #000;
  color: #fff;
}

html { 
    font-size: 17px; 
}

body {
  overflow-x: hidden;

  font-family: var(--font-body);
  font-weight: 300;
  line-height: var(--lh-body);
}

h1, h2, h3, h4, h5, h6{
  font-family: var(--font-title);
  font-weight: 500;
  line-height: var(--lh-title);
}

h1
{
font-size:  54px;
text-transform: uppercase;
letter-spacing: 0.15em;
}

h2
{
  font-size:  22px;
  font-weight:  200;
  text-transform: uppercase;
  letter-spacing: 0.15em;
}

p, a{
    font-size:  1rem;
}

/* Assure que la home prend bien le thème dark */
.home {
  background: #000;
  color: #fff;
}

/* Container: limite de lecture, mais le site reste full width */
.container {
  width: calc(100% - 48px);
  margin-inline: auto;
}

/* Liens */
.home a {
  color: inherit;
  text-decoration: none;
}

/* =========================================
   COVER ONLY
========================================= */

.home-cover {
  position: relative;
  min-height: 90vh;
  display: grid;
  align-items: end;
  overflow: hidden;
  background: #000;
}

/* Vidéo (<video>) */
.home-cover__media {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover; /* essentiel pour la vidéo */
}

/* Fallback image (div background-image) */
.home-cover__media--img {
  background-size: cover;
  background-position: center;
}

/* Overlay sombre pour lisibilité du titre */
.home-cover__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(0,0,0,.85),
    rgba(0,0,0,.25) 55%,
    rgba(0,0,0,.60)
  );
}

/* Contenu (titre + bouton) */
.home-cover__content {
  position: relative;
  padding: 96px 0 72px;
}

.home-cover__kicker {
  margin: 0 0 12px;
  opacity: .75;
  letter-spacing: .04em;
  text-transform: uppercase;
  font-size: .85rem;
  padding: 10px 0 40px;
}

.home-cover__title {
  margin: 0 0;
  font-size: clamp(40px, 6vw, 84px);
  line-height: 1.02;
  color: #fff;
}

/* Responsive léger cover */
@media (max-width: 560px) {
  .home-cover {
    min-height: 80vh;
  }

  .home-cover__content {
    padding: 72px 0 56px;
  }

  .home-cover__title {
    font-size: clamp(34px, 9vw, 56px);
  }
}

.home-cover .btn {
  display: none;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.home-cover__logo {
    display: block;
    width: clamp(200px, 40vw, 500px); /* à adapter selon ton layout */
    height: auto;
}

/* =========================================
   COVER — titre + sous-titre (ordre inversé)
========================================= */

.home-cover__content {
  display: flex;
  flex-direction: column-reverse;
  gap: 12px; /* espace entre titre et sous-titre */
}

/* Sous-titre sous le titre */
.home-cover__kicker {
  margin: 0;
  opacity: .8;
  letter-spacing: .04em;
  text-transform: uppercase;
  font-size: .85rem;
}

@media (min-width:  800px) {
  .home-cover__kicker {
    max-width:  50%;
  }
}




/* ----------------------------------------- FOOTER */

.footer-widgets {
    padding: 48px 48px 48px 24px ;
    background-color: #050505;
    color: #fff;
}

.footer-widget {
    margin-bottom: 20px;
}

.footer-widget-title {
    font-size: 14px;
    text-transform: uppercase;
    margin-bottom: 10px;
}

footer p, footer a
{
  color: white;
  margin:  0;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing:  0.15em;
}

.footer-contact {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-contact-label {
  margin: 0;
  text-transform: uppercase;
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  opacity: 0.4;
}

.footer-contact-icons {
  display: flex;
  flex-direction: row;
  gap: 16px;
}

.footer-contact-link {
  display: inline-flex;
  opacity: 0.4;
  transition: opacity .3s ease, transform .3s ease;
}

.footer-contact-link:hover {
  opacity: 1;
  transform: translateY(-3px); /* légère montée plutôt que translateX, plus naturel pour des icônes côte à côte */
}

.footer-contact-icon {
  width: 28px;
  height: 28px;
  object-fit: contain;
  flex-shrink: 0;
}

@media (min-width: 801px) {
  .footer-contact {
    align-items: flex-end;
  }
}

.footer-widgets .wp-block-image img {
  width: auto !important;
  height: auto !important;
  max-width: 100%;
  max-height: 24px;
  object-fit: contain;
}

@media (max-width: 800px) {
  .footer-widgets .wp-block-image {
    margin-bottom: 24px;
  }
}

@media (max-width: 800px) {
  .footer-widgets .wp-block-columns .wp-block-column:nth-child(2) {
    margin-bottom: 24px;
  }
}

/* ----------------------------------------- OVERWRITING */

.wrapper,
.site,
#wrapper,
#container,
main {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0;
}


/* =========================================
   HEADER / NAV (desktop + base)
========================================= */

.site-header{
  position: fixed;
  top: 0; left: 0;
  width: 100%;
  z-index: 1000;

  background: transparent;     /* <-- plus de bandeau */
  backdrop-filter: none;       /* <-- plus de blur */
  border-bottom: none;         /* <-- plus de ligne */

  transition: background .3s ease;
}

.site-header.nav--solid {
  background: #000;
}

.site-nav{
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
}

.site-nav__brand a{
  font-weight: 700;
  color: #fff;
  text-decoration: none;
  letter-spacing: .08em;
  text-transform: uppercase;
}

/* Desktop menu */
.site-nav__menu{
  list-style: none;
  margin: 0;
  padding: 0;

  display: flex;
  align-items: center;
  gap: 24px;
}

.site-nav__menu a{
  color: rgba(255,255,255,.85);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: .04em;
  font-size: .9rem;
}

.site-nav__menu a:hover{
  color: #fff;
}

/* Active item */
.site-nav__menu .current-menu-item > a,
.site-nav__menu .current_page_item > a{
  color: #fff;
}

@media (max-width: 800px){
  .site-nav__brand{
    display: none; /* cache DA PROD dans le header en mobile */
  }
}

/* =========================================
   BURGER (mobile)
========================================= */

.nav-toggle{
  display: none; /* visible seulement sur mobile */
  position: fixed;
  top: 14px;
  right: 16px;
  z-index: 1200;

  width: 44px;
  height: 44px;

  border: none;
  border-radius: 0;
  background: transparent;
  backdrop-filter: none;

  /* Agrandissement sans décaler la position */
  transform: scale(1.6);
  transform-origin: top right;

  cursor: pointer;
}

/* Burger icon */
.nav-toggle__icon{
  position: absolute;
  top: 50%;
  left: 50%;

  width: 18px;
  height: 2px;

  background: #fff;
  transform: translate(-50%, -50%);
  transition: background .2s ease;
}

.nav-toggle__icon::before,
.nav-toggle__icon::after{
  content: "";
  position: absolute;
  left: 0;

  width: 18px;
  height: 2px;

  background: #fff;
  transition:
    transform .2s ease,
    top .2s ease,
    opacity .2s ease;
}

.nav-toggle__icon::before{
  top: -6px;
}

.nav-toggle__icon::after{
  top: 6px;
}

/* Open state → cross */
body.nav-open .nav-toggle__icon{
  background: transparent;
}

body.nav-open .nav-toggle__icon::before{
  top: 0;
  transform: rotate(45deg);
}

body.nav-open .nav-toggle__icon::after{
  top: 0;
  transform: rotate(-45deg);
}

/* =========================================
   MOBILE NAV OVERLAY (slide right)
========================================= */

.mobile-nav{
  position: fixed;
  inset: 0;
  z-index: 1100;
  pointer-events: none; /* activé seulement quand ouvert */
}

.mobile-nav__backdrop{
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.55);
  opacity: 0;
  transition: opacity .25s ease;
}

.mobile-nav__panel{
  position: absolute;
  top: 0;
  right: 0;
  width: min(88vw, 360px);
  height: 100%;
  background: #000;
  border-left: 1px solid rgba(255,255,255,.10);

  transform: translateX(100%);
  transition: transform .25s ease;

  padding: 18px 18px 28px;

  display: flex;
  flex-direction: column;
}

/* Head en haut : DA PROD à gauche + close à droite */
.mobile-nav__head{
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}

.mobile-nav__brand{
  color: #fff;
  text-decoration: none;
  letter-spacing: .08em;
  text-transform: uppercase;
}

/* Menu centré verticalement dans l'espace restant */
.mobile-nav__menu{
  list-style: none;
  margin: 0;
  padding: 0;

  flex: 1;                 /* prend tout l'espace restant sous le head */
  display: flex;
  flex-direction: column;
  justify-content: center; /* centre verticalement */
  gap: 12px;

  /* option si tu veux centrer aussi horizontalement :
  align-items: center;
  */
}

.mobile-nav__menu a{
  display: block;
  padding: 12px 10px;
  border-radius: 12px;
  color: rgba(255,255,255,.9);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: .04em;
  font-size: .95rem;

  /* option si tu centres horizontalement :
  text-align: center;
  */
}

.mobile-nav__menu a:hover{
  background: rgba(255,255,255,.06);
  color: #fff;
}

/* Ouvert */
body.nav-open .mobile-nav{
  pointer-events: auto;
}
body.nav-open .mobile-nav__backdrop{
  opacity: 1;
}
body.nav-open .mobile-nav__panel{
  transform: translateX(0);
}

/* Bloque le scroll quand ouvert */
body.nav-open{
  overflow: hidden;
}






.site-nav__logo{
  display: inline-flex;
  align-items: center;
}

.site-nav__logo img{
  height: 18px;      /* ajuste ici */
  width: auto;
  display: block;

  transform: translateY(4px); /* ← ajuste ici */
}

.mobile-nav__brand img{
  height: 32px;     /* même hauteur que desktop ou un peu plus grand (24px) */
  width: auto;
  display: block;
}



/* =========================================
   Language switch (custom)
========================================= */

.lang-switch{
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-transform: uppercase;
  letter-spacing: .06em;
  user-select: none;
}

.lang-switch__link{
  text-decoration: none;
  color: rgba(255,255,255,.85);
  font-size: .72rem; /* plus petit que les liens */
}

.lang-switch__link:hover,
.lang-switch__link:focus-visible{
  color: #fff;
}

.lang-switch__link.is-current{
  color: #bbb;
  pointer-events: none;
  font-style: italic;
}

.lang-switch__sep{
  opacity: .35;
}

/* Desktop: aligné avec le menu */
.site-nav__desktop{
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 64px;
}

/* Mobile: sous la liste, sur une seule ligne */
.mobile-nav__panel .lang-switch{
  margin-top: 14px;
  justify-content: flex-start; /* option: centré */
  padding-left:  12px;
}

/* =========================================
   RESPONSIVE SWITCH
========================================= */

@media (max-width: 800px){
  .site-nav__desktop{
    display: none;
  }
  .nav-toggle{
    display: inline-block;
  }

  /* padding nav un peu plus compact en mobile */
  .site-nav{
    padding: 16px 18px;
  }
}


/* =========================
   PROJECTS — Layout / Mosaic
========================= */

/* 1) Sécurité : éviter que le contenu passe sous la nav */
main.page-projects {
  width: calc(100% - 48px);
  margin-inline: auto;
  padding-left: 0;
  padding-right: 0;
  padding-top: 48px;
}

/* 2) Wrapper de boucles */
.projects-loop {
  width: 100%;
  margin-left: 0;
  margin-right: 0;
  margin-top: 18px;
  margin-bottom: 18px;
}

/* 3) La grille (ul) */
.projects-grid {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

/* Mobile = 1 colonne */
@media (max-width: 800px) {
  .projects-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }
}

/* 4) Tile (li) */
.projects-grid > li.wp-block-post {
  position: relative;
  overflow: hidden;
  border-radius: 0;
  background: #000;
}

/* 5) Image plein cadre */
.projects-grid > li .wp-block-post-featured-image {
  margin: 0;
  height: 0;
  padding-top: 66%;
  position: relative;
}

.projects-grid > li .wp-block-post-featured-image a {
  position: absolute;
  inset: 0;
  display: block;
}

.projects-grid > li .wp-block-post-featured-image img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.02);
  transition: transform .35s ease;
}

/* 6) Titre overlay — base commune */
.projects-grid > li .wp-block-post-title {
  position: absolute;
  inset: 0;
  margin: 0;
  padding: 14px;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: transparent;
  text-transform: uppercase !important;

}

/* Lien titre */
.projects-grid > li .wp-block-post-title a {
  color: #fff;
  text-decoration: none;
  display: inline-block;
  text-transform: uppercase !important;
  font-weight: 400;
  letter-spacing: .15em;
  font-size: clamp(0.7rem, 2vw, 1.5rem);
}

.projects-grid > li .wp-block-post-title a::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 3;
}

/* ─── DESKTOP ─── */
@media (min-width: 801px) {
  /* Overlay noir sur la tuile entière via pseudo-élément */
  .projects-grid > li::after {
    pointer-events: none;
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, .55);
    opacity: 0;
    transition: opacity .25s ease;
    z-index: 1;
  }

  .projects-grid > li .wp-block-post-title {
    opacity: 0;
    transform: translateY(6px);
    transition: opacity .25s ease, transform .25s ease;
  }

  .projects-grid > li:hover::after,
  .projects-grid > li:focus-within::after {
    opacity: 1;
  }

  .projects-grid > li:hover .wp-block-post-title,
  .projects-grid > li:focus-within .wp-block-post-title {
    opacity: 1;
    transform: translateY(0);
  }

  .projects-grid > li:hover img,
  .projects-grid > li:focus-within img {
    transform: scale(1.06);
  }
}

/* ─── MOBILE ─── */
/* ─── MOBILE ─── */
@media (max-width: 800px) {
  .projects-grid > li .wp-block-post-title {
    opacity: 1;
    transform: none;
    align-items: flex-end;
    padding-bottom: 14px;
  }

  .projects-grid > li .wp-block-post-title a {
    background: transparent;
    padding: 4px 10px;
    border-radius: 0;
    text-shadow: 0 1px 6px rgba(0, 0, 0, .9);
  }

  .projects-grid > li::before {
    content: '';
    position: absolute;
    inset: auto 0 0 0;
    height: 50%;
    background: linear-gradient(to top, rgba(0,0,0,.6), rgba(0,0,0,0));
    z-index: 1;
    pointer-events: none;
  }
}

/* 7) Excerpt vide : on le neutralise */
.projects-grid > li .wp-block-post-excerpt {
  display: none;
}


/* =========================
   SINGLE / PAGES
========================= */

main.single-page, main.page-main {
  padding-left: 24px;
  padding-right: 24px;
  padding-top: 48px;
}


/* =========================
   CAROUSEL - HOME
========================= */

.home .projects-grid {
  grid-template-columns: none;
  display: flex;
  overflow-x: scroll;
  scroll-snap-type: x mandatory;
  gap: 14px;
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE */
  padding-bottom: 4px;
}

.home .projects-grid::-webkit-scrollbar {
  display: none; /* Chrome/Safari */
}

.home .projects-grid > li.wp-block-post {
  flex: 0 0 calc((100% - 28px) / 3); /* 3 tuiles visibles */
  scroll-snap-align: start;
}

/* Mobile : 1 tuile + aperçu de la suivante */
@media (max-width: 800px) {
  .home .projects-grid > li.wp-block-post {
    flex: 0 0 85%;
  }
}

.home-carousel-wrapper {
  position: relative;
}

/* Boutons prev/next — desktop uniquement */
@media (min-width: 801px) {
  .carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    background: transparent;
    color: #fff;
    border: none;
    cursor: pointer;
    font-size: 2.5rem;
    font-weight: 200;
    line-height: 1;
    padding: 0 16px;
    height: 100%;
    display: flex;
    align-items: center;
    transition: opacity .3s ease, background .3s ease;
  }

  .carousel-btn--prev {
    left: 0;
  }

  .carousel-btn--next {
    right: 0;
  }

  /* Dégradé latéral sur la flèche active */
  .carousel-btn--prev:not([style*="pointer-events: none"]) {
    background: linear-gradient(to right, rgba(0,0,0,.5), rgba(0,0,0,0));
  }

  .carousel-btn--next:not([style*="pointer-events: none"]) {
    background: linear-gradient(to left, rgba(0,0,0,.5), rgba(0,0,0,0));
  }

  .carousel-btn--prev {
    left: -48px; /* <- supprimer cette ligne */
    left: 0;
  }

  .carousel-btn--next {
    right: -48px; /* <- supprimer cette ligne */
    right: 0;
  }

  .carousel-btn:not([style*="pointer-events: none"]):hover {
    background-color: rgba(0, 0, 0, 0.6);
    opacity: 1;
  }
}

@media (max-width: 800px) {
  .carousel-btn {
    display: none;
  }
}

.home-projects-link {
  display: inline-block;
  color: #fff;
  text-decoration: none;
  text-transform: uppercase;
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  opacity: 0.4;
  transition: opacity .3s ease, transform .3s ease;
}

.home-projects-link:hover {
  opacity: 1;
  transform: translateX(4px);
}




/* =========================
   OVERRIDE
========================= */


.wp-block-columns {
  gap: 80px !important;
}

@media (max-width: 1200px) {
  .wp-block-columns {
    flex-direction: column;
    gap: 0 !important;
  }

  .wp-block-column {
    flex-basis: 100% !important;
  }
}

main.single-page {
  padding-left: 24px;
  padding-right: 24px;
  padding-top: 48px;
  padding-bottom: 200px;
}

/* ─── GALERIE SINGLE ─── */
.single .wp-block-gallery {
  display: block !important;
  margin-top: 24px;
  margin-bottom: 24px;
}

.single .wp-block-gallery .gallery-grid {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.single .wp-block-gallery .gallery-block {
  display: grid;
  gap: 14px;
}

.single .wp-block-gallery .gallery-cell {
  background: #000;
}

.single .wp-block-gallery .gallery-cell img {
  width: 100%;
  height: auto;
  display: block;
}

.single .wp-block-gallery .gallery-cell--full {
  width: 100%;
}

/* Image seule */
.single .wp-block-gallery .gallery-cell--alone {
  max-width: 40%;
  margin-inline: auto;
}

/* ─── MOBILE ─── */
@media (max-width: 800px) {
  .single .wp-block-gallery {
    display: flex !important;
    flex-direction: column;
    gap: 14px;
  }

  .single .wp-block-gallery .wp-block-image {
    width: 100%;
  }

  .single .wp-block-gallery .wp-block-image img {
    width: 100%;
    height: auto;
    display: block;
  }

  .single .wp-block-gallery figure.wp-block-image {
    width: 100% !important;
    margin: 0 !important;
  }
}

/* =============================================
   LIENS — Effet soulignement animé
   Exclut : navigation principale + liens images
   ============================================= */

a:not(nav a):not(.main-nav a):not(#site-navigation a):not(.wp-block-navigation a):not(:has(img)):not(.footer-contact-link):not(.wp-block-post-title a):not(.home-projects-link),
a:not(nav a):not(.main-nav a):not(#site-navigation a):not(.wp-block-navigation a):not(:has(img)):not(.footer-contact-link):not(.wp-block-post-title a):not(.home-projects-link):hover {
  color: inherit;
  position: relative;
  text-decoration: none;
}

a:not(nav a):not(.main-nav a):not(#site-navigation a):not(.wp-block-navigation a):not(:has(img)):not(.footer-contact-link):not(.wp-block-post-title a):not(.home-projects-link)::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 100%;
  height: 1px;
  background-color: currentColor;
}

a:not(nav a):not(.main-nav a):not(#site-navigation a):not(.wp-block-navigation a):not(:has(img)):not(.footer-contact-link):not(.wp-block-post-title a):not(.home-projects-link):hover::after {
  height: 4px;
}